PluginProbe
Translate and Go multilingual – Automatic AI translation – wpLingua / 2.12.1
Translate and Go multilingual – Automatic AI translation – wpLingua v2.12.1
2.16.7 2.16.6 2.16.5 2.16.4 2.16.3 2.16.2 2.16.1 2.16.0 2.15.2 2.15.1 2.15.0 2.14.3 2.14.2 2.14.1 2.14.0 2.13.1 2.13.0 2.12.3 2.12.2 2.12.1 trunk 1.0.3 1.0.4 1.0.5 1.1.0 All 112 releases
wplingua / assets / js / block-switcher.js

block-switcher.js in Translate and Go multilingual – Automatic AI translation – wpLingua 2.12.1, at assets/js/block-switcher.js

18 lines 4.4 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 /*!*
2 ** _ _
3 ** __ ___ __ | | (_)_ __ __ _ _ _ __ _
4 ** \ \ /\ / / '_ \| | | | '_ \ / _` | | | |/ _` |
5 ** \ V V /| |_) | |___| | | | | (_| | |_| | (_| |
6 ** \_/\_/ | .__/|_____|_|_| |_|\__, |\__,_|\__,_|
7 ** |_| |___/
8 **
9 ** -- wpLingua | WordPress plugin --
10 ** Translate and make your website multilingual
11 **
12 ** https://github.com/julien-jacob/wplingua
13 ** https://wordpress.org/plugins/wplingua/
14 ** https://wplingua.com/
15 **
16 **/
17 wp.blocks.registerBlockType("wplingua/languages-switcher",{title:wplngI18nGutenberg.label.title,description:wplngI18nGutenberg.label.description,icon:"translation",attributes:{style:{type:"string",default:""},title:{type:"string",default:""},flags:{type:"string",default:""},theme:{type:"string",default:""}},edit:function(l){return[wp.element.createElement(wp.serverSideRender,{block:"wplingua/languages-switcher",attributes:l.attributes}),wp.element.createElement(wp.blockEditor.InspectorControls,{key:"inspector"},wp.element.createElement("div",{className:"wplng-block-attributes"},wp.element.createElement(wp.components.SelectControl,{label:wplngI18nGutenberg.input.style,value:l.attributes.style,onChange:function(e){l.setAttributes({style:e})},options:[{value:"",label:wplngI18nGutenberg.label.default},{value:"list",label:wplngI18nGutenberg.style.list},{value:"block",label:wplngI18nGutenberg.style.block},{value:"dropdown",label:wplngI18nGutenberg.style.dropdown}]}),wp.element.createElement(wp.components.SelectControl,{label:wplngI18nGutenberg.input.title,value:l.attributes.title,onChange:function(e){l.setAttributes({title:e})},options:[{value:"",label:wplngI18nGutenberg.label.default},{value:"original",label:wplngI18nGutenberg.title.original},{value:"name",label:wplngI18nGutenberg.title.name},{value:"id",label:wplngI18nGutenberg.title.id},{value:"none",label:wplngI18nGutenberg.title.none}]}),wp.element.createElement(wp.components.SelectControl,{label:wplngI18nGutenberg.input.flags,value:l.attributes.flags,onChange:function(e){l.setAttributes({flags:e})},options:[{value:"",label:wplngI18nGutenberg.label.default},{value:"circle",label:wplngI18nGutenberg.flags.circle},{value:"rectangular",label:wplngI18nGutenberg.flags.rectangular},{value:"wave",label:wplngI18nGutenberg.flags.wave},{value:"none",label:wplngI18nGutenberg.flags.none}]}),wp.element.createElement(wp.components.SelectControl,{label:wplngI18nGutenberg.input.theme,value:l.attributes.theme,onChange:function(e){l.setAttributes({theme:e})},options:[{value:"",label:wplngI18nGutenberg.label.default},{value:"light-double-smooth",label:wplngI18nGutenberg.theme["light-double-smooth"]},{value:"light-double-square",label:wplngI18nGutenberg.theme["light-double-square"]},{value:"light-simple-smooth",label:wplngI18nGutenberg.theme["light-simple-smooth"]},{value:"light-simple-square",label:wplngI18nGutenberg.theme["light-simple-square"]},{value:"grey-double-smooth",label:wplngI18nGutenberg.theme["grey-double-smooth"]},{value:"grey-double-square",label:wplngI18nGutenberg.theme["grey-double-square"]},{value:"grey-simple-smooth",label:wplngI18nGutenberg.theme["grey-simple-smooth"]},{value:"grey-simple-square",label:wplngI18nGutenberg.theme["grey-simple-square"]},{value:"dark-double-smooth",label:wplngI18nGutenberg.theme["dark-double-smooth"]},{value:"dark-double-square",label:wplngI18nGutenberg.theme["dark-double-square"]},{value:"dark-simple-smooth",label:wplngI18nGutenberg.theme["dark-simple-smooth"]},{value:"dark-simple-square",label:wplngI18nGutenberg.theme["dark-simple-square"]},{value:"blurblack-double-smooth",label:wplngI18nGutenberg.theme["blurblack-double-smooth"]},{value:"blurblack-double-square",label:wplngI18nGutenberg.theme["blurblack-double-square"]},{value:"blurblack-simple-smooth",label:wplngI18nGutenberg.theme["blurblack-simple-smooth"]},{value:"blurblack-simple-square",label:wplngI18nGutenberg.theme["blurblack-simple-square"]},{value:"blurwhite-double-smooth",label:wplngI18nGutenberg.theme["blurwhite-double-smooth"]},{value:"blurwhite-double-square",label:wplngI18nGutenberg.theme["blurwhite-double-square"]},{value:"blurwhite-simple-smooth",label:wplngI18nGutenberg.theme["blurwhite-simple-smooth"]},{value:"blurwhite-simple-square",label:wplngI18nGutenberg.theme["blurwhite-simple-square"]}]})))]},save:function(){return null}});//# sourceMappingURL=block-switcher.js.map
18