From acb60270ff78eb9571f79722ab65b4747d1d19d7 Mon Sep 17 00:00:00 2001 From: Bernardo Martinez Date: Fri, 1 May 2020 12:01:52 -0400 Subject: [PATCH 1/9] Added full-width boostrap block style --- dialogs/btbutton.js | 3 ++- lang/pt-br.js | 3 ++- lang/ru.js | 3 ++- lang/uk.js | 3 ++- 4 files changed, 8 insertions(+), 4 deletions(-) diff --git a/dialogs/btbutton.js b/dialogs/btbutton.js index 24bea1d..16e9363 100755 --- a/dialogs/btbutton.js +++ b/dialogs/btbutton.js @@ -44,7 +44,8 @@ CKEDITOR.dialog.add('btbutton', function (editor) { [lang.buttonSizeExSmall, 'btn-xs'], [lang.buttonSizeSmall, 'btn-sm'], [lang.buttonSizeNormal, ''], - [lang.buttonSizeLarge, 'btn-lg'] + [lang.buttonSizeLarge, 'btn-lg'], + [lang.buttonBlockSize, 'btn-block'] ], setup: function (widget) { this.setValue(widget.data.btnsize || ''); diff --git a/lang/pt-br.js b/lang/pt-br.js index 3459f68..a6a562c 100644 --- a/lang/pt-br.js +++ b/lang/pt-br.js @@ -20,6 +20,7 @@ CKEDITOR.plugins.setLang('btbutton', 'pt-br', { buttonSizeExSmall: 'Extra Pequeno', buttonSizeSmall: 'Pequeno', buttonSizeNormal: 'Normal', - buttonSizeLarge: 'Grande' + buttonSizeLarge: 'Grande', + buttonBlockSize: 'Full Width' }); diff --git a/lang/ru.js b/lang/ru.js index f894854..71f582a 100644 --- a/lang/ru.js +++ b/lang/ru.js @@ -20,5 +20,6 @@ CKEDITOR.plugins.setLang('btbutton', 'ru', { buttonSizeExSmall: 'Очень маленький (XS)', buttonSizeSmall: 'Маленький (S)', buttonSizeNormal: 'Обычный', - buttonSizeLarge: 'Большой (L)' + buttonSizeLarge: 'Большой (L)', + buttonBlockSize: 'Full Width' }); diff --git a/lang/uk.js b/lang/uk.js index bb6b324..a8a49f8 100644 --- a/lang/uk.js +++ b/lang/uk.js @@ -20,5 +20,6 @@ CKEDITOR.plugins.setLang('btbutton', 'uk', { buttonSizeExSmall: 'Дуже мала', buttonSizeSmall: 'Мала', buttonSizeNormal: 'Звичайна', - buttonSizeLarge: 'Велика' + buttonSizeLarge: 'Велика', + buttonBlockSize: 'Full Width' }); From 05cb042569db3b511417cacea97a7ed8e9814c26 Mon Sep 17 00:00:00 2001 From: Bernardo Martinez Date: Fri, 1 May 2020 12:19:22 -0400 Subject: [PATCH 2/9] full with button label --- lang/en.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lang/en.js b/lang/en.js index 6d5da3b..c5ab08b 100644 --- a/lang/en.js +++ b/lang/en.js @@ -20,5 +20,7 @@ CKEDITOR.plugins.setLang('btbutton', 'en', { buttonSizeExSmall: 'Extra Small', buttonSizeSmall: 'Small', buttonSizeNormal: 'Normal', - buttonSizeLarge: 'Large' + buttonSizeLarge: 'Large', + buttonBlockSize: 'Full Width' + }); From c0826c7714a58206667582fb7ceb743c8c4db5e1 Mon Sep 17 00:00:00 2001 From: Bernardo Martinez Date: Fri, 1 May 2020 12:37:28 -0400 Subject: [PATCH 3/9] updated javascript with btn-block --- plugin.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/plugin.js b/plugin.js index 14e75fd..aa19ad7 100644 --- a/plugin.js +++ b/plugin.js @@ -46,6 +46,8 @@ this.data.btnsize = "btn-sm"; } else if ($el.hasClass("btn-lg")) { this.data.btnsize = "btn-lg"; + } else if ($el.hasClass("btn-block")) { + this.data.btnsize = "btn-block"; } this.data.href = $el.attr('href'); @@ -93,7 +95,7 @@ $el.removeClass('btn-link btn-default btn-primary btn-info btn-success btn-warning btn-danger').addClass(this.data.btntype); } - $el.removeClass('btn-xs btn-sm btn-lg'); + $el.removeClass('btn-xs btn-sm btn-lg btn-block'); if (this.data.btnsize) { $el.addClass(this.data.btnsize); } From 47494da4c28073555d14077bd085a676e37353b0 Mon Sep 17 00:00:00 2001 From: Bernardo Martinez Date: Sun, 3 May 2020 10:39:58 -0400 Subject: [PATCH 4/9] Added blocksize as is own select element --- dialogs/btbutton.js | 21 ++++ lang/en.js | 3 +- lang/pt-br.js | 3 +- lang/ru.js | 3 +- lang/uk.js | 3 +- plugin.js | 276 ++++++++++++++++++++++---------------------- 6 files changed, 170 insertions(+), 139 deletions(-) diff --git a/dialogs/btbutton.js b/dialogs/btbutton.js index 16e9363..d7a58b8 100755 --- a/dialogs/btbutton.js +++ b/dialogs/btbutton.js @@ -56,6 +56,27 @@ CKEDITOR.dialog.add('btbutton', function (editor) { } ] }, + { + type: "hbox", + widths: ["50%"], + children: [ + { + id: 'btnblock', + type: 'select', + label: lang.buttonWidthLabel, + items: [ + [lang.buttonDefault, ''], + [lang.buttonBlockFullWidth, 'btn-block'] + ], + setup: function (widget) { + this.setValue(widget.data.btnblock || ''); + }, + commit: function (widget) { + widget.setData('btnblock', this.getValue()); + } + } + ] + }, { type: "hbox", widths: ["50%", "50%"], diff --git a/lang/en.js b/lang/en.js index c5ab08b..17088e2 100644 --- a/lang/en.js +++ b/lang/en.js @@ -7,6 +7,7 @@ CKEDITOR.plugins.setLang('btbutton', 'en', { tabIcons: 'Icons', buttonStyleLabel: 'Style', buttonSizeLabel: 'Size', + buttonWidthLabel: 'Width', buttonTextLabel: 'Text', buttonUrlLabel: 'URL', buttonTargetLabel: 'Target', @@ -21,6 +22,6 @@ CKEDITOR.plugins.setLang('btbutton', 'en', { buttonSizeSmall: 'Small', buttonSizeNormal: 'Normal', buttonSizeLarge: 'Large', - buttonBlockSize: 'Full Width' + buttonBlockFullWidth: 'Full Width' }); diff --git a/lang/pt-br.js b/lang/pt-br.js index a6a562c..54465f8 100644 --- a/lang/pt-br.js +++ b/lang/pt-br.js @@ -7,6 +7,7 @@ CKEDITOR.plugins.setLang('btbutton', 'pt-br', { tabIcons: 'Icones', buttonStyleLabel: 'Estilos', buttonSizeLabel: 'Tamanho', + buttonWidthLabel: 'Width', buttonTextLabel: 'Texto', buttonUrlLabel: 'URL', buttonTargetLabel: 'Target', @@ -21,6 +22,6 @@ CKEDITOR.plugins.setLang('btbutton', 'pt-br', { buttonSizeSmall: 'Pequeno', buttonSizeNormal: 'Normal', buttonSizeLarge: 'Grande', - buttonBlockSize: 'Full Width' + buttonBlockFullWidth: 'Full Width' }); diff --git a/lang/ru.js b/lang/ru.js index 71f582a..7a9c8ff 100644 --- a/lang/ru.js +++ b/lang/ru.js @@ -7,6 +7,7 @@ CKEDITOR.plugins.setLang('btbutton', 'ru', { tabIcons: 'Иконки', buttonStyleLabel: 'Стиль', buttonSizeLabel: 'Размер', + buttonWidthLabel: 'Width', buttonTextLabel: 'Текст', buttonUrlLabel: 'Ссылка (URL)', buttonTargetLabel: 'Цель', @@ -21,5 +22,5 @@ CKEDITOR.plugins.setLang('btbutton', 'ru', { buttonSizeSmall: 'Маленький (S)', buttonSizeNormal: 'Обычный', buttonSizeLarge: 'Большой (L)', - buttonBlockSize: 'Full Width' + buttonBlockFullWidth: 'Full Width' }); diff --git a/lang/uk.js b/lang/uk.js index a8a49f8..2a07ef0 100644 --- a/lang/uk.js +++ b/lang/uk.js @@ -7,6 +7,7 @@ CKEDITOR.plugins.setLang('btbutton', 'uk', { tabIcons: 'Іконки', buttonStyleLabel: 'Стиль', buttonSizeLabel: 'Розмір', + buttonWidthLabel: 'Width', buttonTextLabel: 'Текст', buttonUrlLabel: 'URL', buttonTargetLabel: 'Ціль', @@ -21,5 +22,5 @@ CKEDITOR.plugins.setLang('btbutton', 'uk', { buttonSizeSmall: 'Мала', buttonSizeNormal: 'Звичайна', buttonSizeLarge: 'Велика', - buttonBlockSize: 'Full Width' + buttonBlockFullWidth: 'Full Width' }); diff --git a/plugin.js b/plugin.js index aa19ad7..3734519 100644 --- a/plugin.js +++ b/plugin.js @@ -1,155 +1,161 @@ (function () { - CKEDITOR.plugins.add('btbutton', { - lang: 'en,ru,pt-br,uk', - requires: 'widget,dialog', - icons: 'btbutton', - init: function (editor) { - // Allow any attributes. - editor.config.extraAllowedContent = '*(*);*{*}'; - var lang = editor.lang.btbutton; - - CKEDITOR.dialog.add('btbutton', this.path + 'dialogs/btbutton.js'); - - // Add widget - editor.ui.addButton('btbutton', { - label: lang.buttonTitle, - command: 'btbutton', - icon: this.path + 'icons/btbutton.png' - }); - - editor.widgets.add('btbutton', { - dialog: 'btbutton', - - init: function () { + CKEDITOR.plugins.add('btbutton', { + lang: 'en,ru,pt-br,uk', + requires: 'widget,dialog', + icons: 'btbutton', + init: function (editor) { + // Allow any attributes. + editor.config.extraAllowedContent = '*(*);*{*}'; + var lang = editor.lang.btbutton; + + CKEDITOR.dialog.add('btbutton', this.path + 'dialogs/btbutton.js'); + + // Add widget + editor.ui.addButton('btbutton', { + label: lang.buttonTitle, + command: 'btbutton', + icon: this.path + 'icons/btbutton.png' + }); + + editor.widgets.add('btbutton', { + dialog: 'btbutton', + + init: function () { + var $el = jQuery(this.element.$); + + if ($el.hasClass("btn-link")) { + this.data.btntype = "btn-link"; + } else if ($el.hasClass("btn-default")) { + this.data.btntype = "btn-default"; + } else if ($el.hasClass("btn-primary")) { + this.data.btntype = "btn-primary"; + } else if ($el.hasClass("btn-info")) { + this.data.btntype = "btn-info"; + } else if ($el.hasClass("btn-success")) { + this.data.btntype = "btn-success"; + } else if ($el.hasClass("btn-warning")) { + this.data.btntype = "btn-warning"; + } else if ($el.hasClass("btn-danger")) { + this.data.btntype = "btn-danger"; + } + + if ($el.hasClass("btn-xs")) { + this.data.btnsize = "btn-xs"; + } else if ($el.hasClass("btn-sm")) { + this.data.btnsize = "btn-sm"; + } else if ($el.hasClass("btn-lg")) { + this.data.btnsize = "btn-lg"; + } + + if ($el.hasClass("btn-block")) { + this.data.btnblock = "btn-block"; + } + + this.data.href = $el.attr('href'); + + this.data.target = $el.attr('target'); + + this.data.text = jQuery('.text', $el).text(); + + var bs_icon_left = jQuery('.bs-icon-left', $el); + var bs_icon_right = jQuery('.bs-icon-right', $el); + var fa_icon_left = jQuery('.fa-icon-left', $el); + var fa_icon_right = jQuery('.fa-icon-right', $el); + + if (bs_icon_left.length > 0) { + bs_icon_left.removeClass('bs-icon-left').removeClass('glyphicon'); + this.data.bsiconleft = bs_icon_left.attr('class'); + bs_icon_left.addClass('bs-icon-left').addClass('glyphicon'); + } + + if (bs_icon_right.length > 0) { + bs_icon_right.removeClass('bs-icon-right').removeClass('glyphicon'); + this.data.bsiconright = bs_icon_right.attr('class'); + bs_icon_right.addClass('bs-icon-right').addClass('glyphicon'); + } + + if (fa_icon_left.length > 0) { + fa_icon_left.removeClass('fa-icon-left').removeClass('fa'); + this.data.faiconleft = fa_icon_left.attr('class'); + fa_icon_left.addClass('fa-icon-left').addClass('fa'); + } + + if (fa_icon_right.length > 0) { + fa_icon_right.removeClass('fa-icon-right').removeClass('fa'); + this.data.faiconright = fa_icon_right.attr('class'); + fa_icon_right.addClass('fa-icon-right').addClass('fa'); + } + }, + + template: '' + '' + '', + + data: function () { var $el = jQuery(this.element.$); - if ($el.hasClass("btn-link")) { - this.data.btntype = "btn-link"; - } else if ($el.hasClass("btn-default")) { - this.data.btntype = "btn-default"; - } else if ($el.hasClass("btn-primary")) { - this.data.btntype = "btn-primary"; - } else if ($el.hasClass("btn-info")) { - this.data.btntype = "btn-info"; - } else if ($el.hasClass("btn-success")) { - this.data.btntype = "btn-success"; - } else if ($el.hasClass("btn-warning")) { - this.data.btntype = "btn-warning"; - } else if ($el.hasClass("btn-danger")) { - this.data.btntype = "btn-danger"; + if (this.data.btntype) { + $el.removeClass('btn-link btn-default btn-primary btn-info btn-success btn-warning btn-danger').addClass(this.data.btntype); } - if ($el.hasClass("btn-xs")) { - this.data.btnsize = "btn-xs"; - } else if ($el.hasClass("btn-sm")) { - this.data.btnsize = "btn-sm"; - } else if ($el.hasClass("btn-lg")) { - this.data.btnsize = "btn-lg"; - } else if ($el.hasClass("btn-block")) { - this.data.btnsize = "btn-block"; + $el.removeClass('btn-xs btn-sm btn-lg'); + if (this.data.btnsize) { + $el.addClass(this.data.btnsize); + } + $el.removeClass('btn-block'); + if (this.data.btnblock) { + $el.addClass(this.data.btnblock); } - this.data.href = $el.attr('href'); - - this.data.target = $el.attr('target'); + if (this.data.href) { + $el.attr('href', this.data.href); + this.element.$.removeAttribute('data-cke-saved-href'); + } - this.data.text = jQuery('.text', $el).text(); + if (this.data.target && this.data.target != '') { + $el.attr('target', this.data.target); + } - var bs_icon_left = jQuery('.bs-icon-left', $el); - var bs_icon_right = jQuery('.bs-icon-right', $el); - var fa_icon_left = jQuery('.fa-icon-left', $el); - var fa_icon_right = jQuery('.fa-icon-right', $el); + if (this.data.text) { + jQuery('.text', $el).text(this.data.text); + } - if (bs_icon_left.length > 0) { - bs_icon_left.removeClass('bs-icon-left').removeClass('glyphicon'); - this.data.bsiconleft = bs_icon_left.attr('class'); - bs_icon_left.addClass('bs-icon-left').addClass('glyphicon'); + if (this.data.hasOwnProperty('bsiconleft')) { + jQuery('.bs-icon-left', $el).remove(); + if (this.data.bsiconleft) { + $el.prepend(' \n'); + } } - if (bs_icon_right.length > 0) { - bs_icon_right.removeClass('bs-icon-right').removeClass('glyphicon'); - this.data.bsiconright = bs_icon_right.attr('class'); - bs_icon_right.addClass('bs-icon-right').addClass('glyphicon'); + if (this.data.hasOwnProperty('bsiconright')) { + jQuery('.bs-icon-right', $el).remove(); + if (this.data.bsiconright) { + $el.append(' \n'); + } } - if (fa_icon_left.length > 0) { - fa_icon_left.removeClass('fa-icon-left').removeClass('fa'); - this.data.faiconleft = fa_icon_left.attr('class'); - fa_icon_left.addClass('fa-icon-left').addClass('fa'); + if (this.data.hasOwnProperty('faiconleft')) { + jQuery('.fa-icon-left', $el).remove(); + if (this.data.faiconleft) { + $el.prepend(' \n'); + } } - if (fa_icon_right.length > 0) { - fa_icon_right.removeClass('fa-icon-right').removeClass('fa'); - this.data.faiconright = fa_icon_right.attr('class'); - fa_icon_right.addClass('fa-icon-right').addClass('fa'); + if (this.data.hasOwnProperty('faiconright')) { + jQuery('.fa-icon-right', $el).remove(); + if (this.data.faiconright) { + $el.append(' \n'); + } } - }, - - template: '' + '' + '', - - data: function () { - var $el = jQuery(this.element.$); - - if (this.data.btntype) { - $el.removeClass('btn-link btn-default btn-primary btn-info btn-success btn-warning btn-danger').addClass(this.data.btntype); - } - - $el.removeClass('btn-xs btn-sm btn-lg btn-block'); - if (this.data.btnsize) { - $el.addClass(this.data.btnsize); - } - - if (this.data.href) { - $el.attr('href', this.data.href); - this.element.$.removeAttribute('data-cke-saved-href'); - } - - if (this.data.target && this.data.target != '') { - $el.attr('target', this.data.target); - } - - if (this.data.text) { - jQuery('.text', $el).text(this.data.text); - } - - if (this.data.hasOwnProperty('bsiconleft')) { - jQuery('.bs-icon-left', $el).remove(); - if (this.data.bsiconleft) { - $el.prepend(' \n'); - } - } - - if (this.data.hasOwnProperty('bsiconright')) { - jQuery('.bs-icon-right', $el).remove(); - if (this.data.bsiconright) { - $el.append(' \n'); - } - } - - if (this.data.hasOwnProperty('faiconleft')) { - jQuery('.fa-icon-left', $el).remove(); - if (this.data.faiconleft) { - $el.prepend(' \n'); - } - } - - if (this.data.hasOwnProperty('faiconright')) { - jQuery('.fa-icon-right', $el).remove(); - if (this.data.faiconright) { - $el.append(' \n'); - } - } - }, - - requiredContent: 'a(btn)', - - upcast: function (element) { - return element.name == 'a' && element.hasClass('btn'); - } - }); - } - } - ); + }, + + requiredContent: 'a(btn)', + + upcast: function (element) { + return element.name == 'a' && element.hasClass('btn'); + } + }); + } + } + ); })(); From faf09981c904b5d0a0224147058be9d26e4afffe Mon Sep 17 00:00:00 2001 From: Bernardo Martinez Date: Sun, 3 May 2020 10:51:34 -0400 Subject: [PATCH 5/9] Modified field order --- dialogs/btbutton.js | 64 ++++++++++++++++++++++----------------------- 1 file changed, 32 insertions(+), 32 deletions(-) diff --git a/dialogs/btbutton.js b/dialogs/btbutton.js index d7a58b8..b4b7827 100755 --- a/dialogs/btbutton.js +++ b/dialogs/btbutton.js @@ -12,6 +12,38 @@ CKEDITOR.dialog.add('btbutton', function (editor) { label: lang.tabInfo, accessKey: 'I', elements: [ + { + type: "hbox", + widths: ["50%", "50%"], + children: [ + { + id: 'text', + type: 'text', + width: '200px', + required: true, + label: lang.buttonTextLabel, + setup: function (widget) { + this.setValue(widget.data.text || 'A Button'); + }, + commit: function (widget) { + widget.setData('text', this.getValue()); + } + }, + { + id: 'href', + type: 'text', + width: '200px', + required: true, + label: lang.buttonUrlLabel, + setup: function (widget) { + this.setValue(widget.data.href || '#'); + }, + commit: function (widget) { + widget.setData('href', this.getValue()); + } + } + ] + }, { type: "hbox", widths: ["50%", "50%"], @@ -76,38 +108,6 @@ CKEDITOR.dialog.add('btbutton', function (editor) { } } ] - }, - { - type: "hbox", - widths: ["50%", "50%"], - children: [ - { - id: 'text', - type: 'text', - width: '200px', - required: true, - label: lang.buttonTextLabel, - setup: function (widget) { - this.setValue(widget.data.text || 'A Button'); - }, - commit: function (widget) { - widget.setData('text', this.getValue()); - } - }, - { - id: 'href', - type: 'text', - width: '200px', - required: true, - label: lang.buttonUrlLabel, - setup: function (widget) { - this.setValue(widget.data.href || '#'); - }, - commit: function (widget) { - widget.setData('href', this.getValue()); - } - } - ] } ] }, From aa4e68cc807dce79d7dec212dcb17571fdd96210 Mon Sep 17 00:00:00 2001 From: Bernardo Martinez Date: Sun, 3 May 2020 16:50:16 -0400 Subject: [PATCH 6/9] updated bt4 --- dialogs/btbutton.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/dialogs/btbutton.js b/dialogs/btbutton.js index b4b7827..9144fce 100755 --- a/dialogs/btbutton.js +++ b/dialogs/btbutton.js @@ -59,7 +59,10 @@ CKEDITOR.dialog.add('btbutton', function (editor) { [lang.buttonSuccess, 'btn-success'], [lang.buttonInfo, 'btn-info'], [lang.buttonWarning, 'btn-warning'], - [lang.buttonDanger, 'btn-danger'] + [lang.buttonDanger, 'btn-danger'], + [lang.buttonDark, 'btn-dark'], + [lang.buttonLight, 'btn-light'], + ], setup: function (widget) { this.setValue(widget.data.btntype || 'btn-default'); @@ -73,7 +76,6 @@ CKEDITOR.dialog.add('btbutton', function (editor) { type: 'select', label: lang.buttonSizeLabel, items: [ - [lang.buttonSizeExSmall, 'btn-xs'], [lang.buttonSizeSmall, 'btn-sm'], [lang.buttonSizeNormal, ''], [lang.buttonSizeLarge, 'btn-lg'], From f8bdb5535d20c4606f7e6af1d326b521e7aec100 Mon Sep 17 00:00:00 2001 From: Bernardo Martinez Date: Sun, 3 May 2020 16:54:42 -0400 Subject: [PATCH 7/9] Added new label for button dark and light --- lang/en.js | 2 ++ lang/pt-br.js | 2 ++ lang/ru.js | 2 ++ lang/uk.js | 2 ++ 4 files changed, 8 insertions(+) diff --git a/lang/en.js b/lang/en.js index 17088e2..bb02c5a 100644 --- a/lang/en.js +++ b/lang/en.js @@ -18,6 +18,8 @@ CKEDITOR.plugins.setLang('btbutton', 'en', { buttonSuccess: 'Success', buttonWarning: 'Warning', buttonDanger: 'Danger', + buttonDark: 'Dark', + buttonLight: 'Light', buttonSizeExSmall: 'Extra Small', buttonSizeSmall: 'Small', buttonSizeNormal: 'Normal', diff --git a/lang/pt-br.js b/lang/pt-br.js index 54465f8..f3685ee 100644 --- a/lang/pt-br.js +++ b/lang/pt-br.js @@ -18,6 +18,8 @@ CKEDITOR.plugins.setLang('btbutton', 'pt-br', { buttonSuccess: 'Success', buttonWarning: 'Warning', buttonDanger: 'Danger', + buttonDark: 'Dark', + buttonLight: 'Light', buttonSizeExSmall: 'Extra Pequeno', buttonSizeSmall: 'Pequeno', buttonSizeNormal: 'Normal', diff --git a/lang/ru.js b/lang/ru.js index 7a9c8ff..c1458b4 100644 --- a/lang/ru.js +++ b/lang/ru.js @@ -18,6 +18,8 @@ CKEDITOR.plugins.setLang('btbutton', 'ru', { buttonSuccess: 'Зеленая (success)', buttonWarning: 'Оранжевая (warning)', buttonDanger: 'Красная (danger)', + buttonDark: 'Dark', + buttonLight: 'Light', buttonSizeExSmall: 'Очень маленький (XS)', buttonSizeSmall: 'Маленький (S)', buttonSizeNormal: 'Обычный', diff --git a/lang/uk.js b/lang/uk.js index 2a07ef0..a931ea1 100644 --- a/lang/uk.js +++ b/lang/uk.js @@ -18,6 +18,8 @@ CKEDITOR.plugins.setLang('btbutton', 'uk', { buttonSuccess: 'Успіх', buttonWarning: 'Попередження', buttonDanger: 'Небезбека', + buttonDark: 'Dark', + buttonLight: 'Light', buttonSizeExSmall: 'Дуже мала', buttonSizeSmall: 'Мала', buttonSizeNormal: 'Звичайна', From 65c1eadde68ccb50dfb7ca04367c1f4e30f5fb07 Mon Sep 17 00:00:00 2001 From: Bernardo Martinez Date: Wed, 9 Sep 2020 12:06:30 -0400 Subject: [PATCH 8/9] updated fontawesome icones from fa to fas --- plugin.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/plugin.js b/plugin.js index 3734519..c0a2bbf 100644 --- a/plugin.js +++ b/plugin.js @@ -76,15 +76,15 @@ } if (fa_icon_left.length > 0) { - fa_icon_left.removeClass('fa-icon-left').removeClass('fa'); + fa_icon_left.removeClass('fa-icon-left').removeClass('fas'); this.data.faiconleft = fa_icon_left.attr('class'); fa_icon_left.addClass('fa-icon-left').addClass('fa'); } if (fa_icon_right.length > 0) { - fa_icon_right.removeClass('fa-icon-right').removeClass('fa'); + fa_icon_right.removeClass('fa-icon-right').removeClass('fas'); this.data.faiconright = fa_icon_right.attr('class'); - fa_icon_right.addClass('fa-icon-right').addClass('fa'); + fa_icon_right.addClass('fa-icon-right').addClass('fas'); } }, @@ -136,14 +136,14 @@ if (this.data.hasOwnProperty('faiconleft')) { jQuery('.fa-icon-left', $el).remove(); if (this.data.faiconleft) { - $el.prepend(' \n'); + $el.prepend(' \n'); } } if (this.data.hasOwnProperty('faiconright')) { jQuery('.fa-icon-right', $el).remove(); if (this.data.faiconright) { - $el.append(' \n'); + $el.append(' \n'); } } }, From 1a156d35353a58bece8c0e0b263018fa7a6dedbf Mon Sep 17 00:00:00 2001 From: Bernardo Martinez Date: Tue, 15 Sep 2020 14:17:41 -0400 Subject: [PATCH 9/9] updated fa to fas --- plugin.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugin.js b/plugin.js index c0a2bbf..2d3d6bf 100644 --- a/plugin.js +++ b/plugin.js @@ -78,7 +78,7 @@ if (fa_icon_left.length > 0) { fa_icon_left.removeClass('fa-icon-left').removeClass('fas'); this.data.faiconleft = fa_icon_left.attr('class'); - fa_icon_left.addClass('fa-icon-left').addClass('fa'); + fa_icon_left.addClass('fa-icon-left').addClass('fas'); } if (fa_icon_right.length > 0) {