diff --git a/amd/build/configuration.min.js.map b/amd/build/configuration.min.js.map index 0c1c4eb..62342e8 100644 --- a/amd/build/configuration.min.js.map +++ b/amd/build/configuration.min.js.map @@ -1 +1 @@ -{"version":3,"file":"configuration.min.js","sources":["../src/configuration.js"],"sourcesContent":["// This file is part of Moodle - https://moodle.org/\n//\n// Moodle is free software: you can redistribute it and/or modify\n// it under the terms of the GNU General Public License as published by\n// the Free Software Foundation, either version 3 of the License, or\n// (at your option) any later version.\n//\n// Moodle is distributed in the hope that it will be useful,\n// but WITHOUT ANY WARRANTY; without even the implied warranty of\n// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n// GNU General Public License for more details.\n//\n// You should have received a copy of the GNU General Public License\n// along with Moodle. If not, see .\n\n/**\n * Tiny tiny_fontcolor for Moodle.\n *\n * @module tiny_fontcolor\n * @copyright 2023 Luca Bösch \n * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later\n */\n\nimport {addMenubarItem, addQuickbarsToolbarItem, addToolbarButtons} from 'editor_tiny/utils';\nimport {forecolor, backcolor} from './common';\n\nconst configureToolbar = (toolbar) => {\n toolbar = addToolbarButtons(toolbar, 'formatting', [forecolor, backcolor]);\n return toolbar;\n};\n\nconst configureMenu = (menu) => {\n menu = addMenubarItem(menu, 'format', forecolor);\n menu = addMenubarItem(menu, 'format', backcolor);\n return menu;\n};\n\nconst configureQuickbarToolbar = (quickbar) => {\n quickbar = addQuickbarsToolbarItem(quickbar, '|', forecolor);\n quickbar = addQuickbarsToolbarItem(quickbar, '|', backcolor);\n return quickbar;\n};\n\nexport const configure = (instanceConfig) => {\n return {\n toolbar: configureToolbar(instanceConfig.toolbar),\n menu: configureMenu(instanceConfig.menu),\n quickbars_selection_toolbar: configureQuickbarToolbar(instanceConfig.quickbars_selection_toolbar),\n };\n};\n"],"names":["instanceConfig","toolbar","forecolor","backcolor","menu","quickbars_selection_toolbar","quickbar"],"mappings":"yNA2C0BA,uBACf,CACHC,SAnBkBA,QAmBQD,eAAeC,QAlB7CA,SAAU,4BAAkBA,QAAS,aAAc,CAACC,kBAAWC,qBAmB3DC,MAfeA,KAeKJ,eAAeI,KAdvCA,MAAO,yBAAeA,KAAM,SAAUF,mBACtCE,MAAO,yBAAeA,KAAM,SAAUD,oBAclCE,6BAV0BC,SAU4BN,eAAeK,4BATzEC,UAAW,kCAAwBA,SAAU,IAAKJ,mBAClDI,UAAW,kCAAwBA,SAAU,IAAKH,qBAFpBG,IAAAA,SANXF,KALGH"} \ No newline at end of file +{"version":3,"file":"configuration.min.js","sources":["../src/configuration.js"],"sourcesContent":["// This file is part of Moodle - https://moodle.org/\n//\n// Moodle is free software: you can redistribute it and/or modify\n// it under the terms of the GNU General Public License as published by\n// the Free Software Foundation, either version 3 of the License, or\n// (at your option) any later version.\n//\n// Moodle is distributed in the hope that it will be useful,\n// but WITHOUT ANY WARRANTY; without even the implied warranty of\n// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n// GNU General Public License for more details.\n//\n// You should have received a copy of the GNU General Public License\n// along with Moodle. If not, see .\n\n/**\n * Tiny tiny_fontcolor for Moodle.\n *\n * @module tiny_fontcolor\n * @copyright 2023 Luca Bösch \n * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later\n */\n\nimport {addMenubarItem, addQuickbarsToolbarItem, addToolbarButtons} from 'editor_tiny/utils';\nimport {forecolor, backcolor} from './common';\n\nconst configureToolbar = (toolbar) => {\n toolbar = addToolbarButtons(toolbar, 'formatting', [forecolor, backcolor]);\n return toolbar;\n};\n\nconst configureMenu = (menu) => {\n menu = addMenubarItem(menu, 'format', forecolor);\n menu = addMenubarItem(menu, 'format', backcolor);\n return menu;\n};\n\nconst configureQuickbarToolbar = (quickbar) => {\n quickbar = addQuickbarsToolbarItem(quickbar, '|', forecolor);\n quickbar = addQuickbarsToolbarItem(quickbar, '|', backcolor);\n return quickbar;\n};\n\nexport const configure = (instanceConfig) => {\n return {\n toolbar: configureToolbar(instanceConfig.toolbar),\n menu: configureMenu(instanceConfig.menu),\n // eslint-disable-next-line camelcase\n quickbars_selection_toolbar: configureQuickbarToolbar(instanceConfig.quickbars_selection_toolbar),\n };\n};\n"],"names":["instanceConfig","toolbar","forecolor","backcolor","menu","quickbars_selection_toolbar","quickbar"],"mappings":"yNA2C0BA,uBACf,CACHC,SAnBkBA,QAmBQD,eAAeC,QAlB7CA,SAAU,4BAAkBA,QAAS,aAAc,CAACC,kBAAWC,qBAmB3DC,MAfeA,KAeKJ,eAAeI,KAdvCA,MAAO,yBAAeA,KAAM,SAAUF,mBACtCE,MAAO,yBAAeA,KAAM,SAAUD,oBAelCE,6BAX0BC,SAW4BN,eAAeK,4BAVzEC,UAAW,kCAAwBA,SAAU,IAAKJ,mBAClDI,UAAW,kCAAwBA,SAAU,IAAKH,qBAFpBG,IAAAA,SANXF,KALGH"} \ No newline at end of file diff --git a/amd/src/configuration.js b/amd/src/configuration.js index 7420682..769f495 100644 --- a/amd/src/configuration.js +++ b/amd/src/configuration.js @@ -45,6 +45,7 @@ export const configure = (instanceConfig) => { return { toolbar: configureToolbar(instanceConfig.toolbar), menu: configureMenu(instanceConfig.menu), + // eslint-disable-next-line camelcase quickbars_selection_toolbar: configureQuickbarToolbar(instanceConfig.quickbars_selection_toolbar), }; };