DmitrMakeev commited on
Commit
227355b
·
verified ·
1 Parent(s): 66ae289

Update js/rus/rus.js

Browse files
Files changed (1) hide show
  1. js/rus/rus.js +42 -56
js/rus/rus.js CHANGED
@@ -9,6 +9,7 @@ editor.I18n.addMessages({
9
  'decorations': 'Оформление',
10
  'extra': 'Ещё больше',
11
  'flex': 'Flex',
 
12
  },
13
  properties: {
14
  'background-repeat': 'Повторение',
@@ -50,65 +51,50 @@ editor.I18n.addMessages({
50
  title: 'Импортировать шаблон',
51
  label: '<div style="margin-bottom: 10px; font-size: 13px;">Вставьте здесь ваш HTML/CSS и нажмите Импортировать</div>',
52
  }
53
- },
54
- commands: {
55
- 'grapesjs-tui-image-editor': {
56
- labelImageEditor: 'Редактор изображений'
57
- }
58
  }
59
  }
60
  });
61
-
62
- // Установка русского языка по умолчанию
63
- editor.I18n.setLocale('ru');
64
-
65
- // Удаление ненужных блоков
66
- const unwantedBlocks = ['video', 'link', 'image'];
67
- unwantedBlocks.forEach(blockId => {
68
- editor.BlockManager.remove(blockId);
69
- });
70
-
71
- // Добавление блока адаптивной картинки
72
- editor.BlockManager.add('responsive-image', {
73
- label: editor.I18n.t('blockManager.labels.responsive-image'),
74
- content: {
75
- type: 'image',
76
- style: {
77
- display: 'block',
78
- margin: 'auto',
79
- maxWidth: '100%',
80
- height: 'auto',
81
- objectFit: 'cover'
82
- },
83
- attributes: {
84
- alt: 'Responsive Image'
85
- }
86
- },
87
- attributes: {
88
- class: 'fa fa-image'
89
- }
90
- });
91
-
92
- // Добавление блока центрированного текста
93
- editor.BlockManager.add('centered-text', {
94
- label: editor.I18n.t('blockManager.labels.centered-text'),
95
- content: {
96
- type: 'text',
97
- style: {
98
- textAlign: 'center'
99
- },
100
- content: 'Centered Text'
101
- },
102
- attributes: {
103
- class: 'fa fa-align-center'
104
- }
105
- });
106
-
107
- // Добавление плагина редактора изображений
108
- editor.plugins.add('grapesjs-tui-image-editor', {
109
- label: editor.I18n.t('plugins.grapesjs-tui-image-editor.labelImageEditor'),
110
- // Другие настройки плагина
111
- });
112
 
113
 
114
 
 
9
  'decorations': 'Оформление',
10
  'extra': 'Ещё больше',
11
  'flex': 'Flex',
12
+
13
  },
14
  properties: {
15
  'background-repeat': 'Повторение',
 
51
  title: 'Импортировать шаблон',
52
  label: '<div style="margin-bottom: 10px; font-size: 13px;">Вставьте здесь ваш HTML/CSS и нажмите Импортировать</div>',
53
  }
 
 
 
 
 
54
  }
55
  }
56
  });
57
+ // Установка русского языка по умолчанию
58
+ editor.I18n.setLocale('ru');
59
+ // Удаление ненужных блоков
60
+ const unwantedBlocks = ['video', 'link', 'image'];
61
+ unwantedBlocks.forEach(blockId => {
62
+ editor.BlockManager.remove(blockId);
63
+ });
64
+ // Добавление блока адаптивной картинки
65
+ editor.BlockManager.add('responsive-image', {
66
+ label: editor.I18n.t('blockManager.labels.responsive-image'),
67
+ content: {
68
+ type: 'image',
69
+ style: {
70
+ display: 'block',
71
+ margin: 'auto',
72
+ maxWidth: '100%',
73
+ height: 'auto',
74
+ objectFit: 'cover'
75
+ },
76
+ attributes: {
77
+ alt: 'Responsive Image'
78
+ }
79
+ },
80
+ attributes: {
81
+ class: 'fa fa-image'
82
+ }
83
+ });
84
+ // Добавление блока центрированного текста
85
+ editor.BlockManager.add('centered-text', {
86
+ label: editor.I18n.t('blockManager.labels.centered-text'),
87
+ content: {
88
+ type: 'text',
89
+ style: {
90
+ textAlign: 'center'
91
+ },
92
+ content: 'Centered Text'
93
+ },
94
+ attributes: {
95
+ class: 'fa fa-align-center'
96
+ }
97
+ });
 
 
 
 
 
 
 
 
 
 
98
 
99
 
100