diff --git a/README.md b/README.md index be86390..969ef4e 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -123456 +12345678 说明:本系统为django-vue-lyadmin专业版,专业版与基础版大体框架一样,只是功能有增加,因此文档可以参考基础版 注意:使用专业版开发时,请使用superadmin/123456超级管理员登录系统,方便测试和调试(避免菜单权限问题) @@ -7,7 +7,7 @@ [![img](https://img.shields.io/badge/python-%3E=3.9.x-green.svg)](https://python.org/) [![PyPI - Django Version badge](https://img.shields.io/badge/django%20versions-4.x-blue)](https://docs.djangoproject.com/zh-hans/4.0/) [![img](https://img.shields.io/badge/node-%3E%3D%2012.0.0-brightgreen)](https://nodejs.org/zh-cn/) [![img](https://gitee.com/lybbn/django-vue-lyadmin/badge/star.svg?theme=dark)](https://gitee.com/lybbn/django-vue-lyadmin) -[QQ群聊](https://jq.qq.com/?_wv=1027&k=StAkGqk5) | [在线体验(admin/123456)](http://django-vue3-lyadmin.lybbn.cn) | [开发文档](https://gitee.com/lybbn/django-vue-lyadmin/wikis/pages?sort_id=5264002&doc_id=2214316) | [在线课程](https://gitee.com/lybbn/django-vue-lyadmin/wikis/pages?sort_id=5476409&doc_id=2214316) | [捐赠](https://gitee.com/lybbn/django-vue-lyadmin/wikis/pages?sort_id=5264497&doc_id=2214316) +[QQ群聊](https://jq.qq.com/?_wv=1027&k=StAkGqk5) | [在线体验(admin/123456)](http://django-vue3-lyadmin.lybbn.cn) | [开发文档](https://gitee.com/lybbn/django-vue-lyadmin/wikis/pages?sort_id=5264002&doc_id=2214316) | [在线课程](https://gitee.com/lybbn/django-vue-lyadmin/wikis/pages?sort_id=5476409&doc_id=2214316) | [捐赠](https://gitee.com/lybbn/django-vue-lyadmin/wikis/pages?sort_id=5264497&doc_id=2214316) ## slogon @@ -54,9 +54,9 @@ eleunipy系统是结合 补充:如果想找到1.x版本(vue2)标准模块(不带商城功能)的,可前往 [正式版v1.0.20](https://gitee.com/lybbn/django-vue-lyadmin/releases/v1.0.20) 版本进行下载 ## 交流 -- 开发者WX号:laoyanyj -- QQ群号:755277564 django-vue-lyadmin交流01群 +- 开发者WX号:laoyanyj +- QQ群号:755277564 `django-vue-lyadmin交流01群``` - 二维码: @@ -67,26 +67,26 @@ gitee地址(主推):https://gitee.com/lybbn/django-vue-lyadmin ## 内置功能 -01. DashBoard: 数据分析查看 -02. CRUD: 面向配置的crud功能 -03. 计划任务(定时任务,运维能力),django-celery-beat 定时任务 -04. 服务器监控面板(运维能力),支持windows和linux服务器的实时服务器资源状态监控 -05. 终端服务webssh(运维能力),支持基于channels的websocket与xterm的webssh(实现websocket的simple-jwt认证,并实现请求方法和接口地址的权限控制) -06. 部门管理:配置系统组织机构(公司、部门、角色),树结构展现支持数据权限。 -07. 菜单管理:配置系统菜单,操作权限,按钮权限标识、后端接口权限等。 -08. 角色管理:角色菜单权限、数据权限、设置角色按部门进行数据范围权限划分。 -09. 权限管理:授权角色的权限范围。 -10. 地区管理:国内省市区管理。 -11. 管理员管理:主要管理系统管理员账号。 -12. 用户管理:主要管理前端用户。 -13. 个人中心:主要设置登录系统的个人昵称、密码等账号信息。 -14. 操作日志:系统正常操作日志记录和查询;系统异常信息日志记录和查询。 -15. 平台设置:系统设置如字典参数、轮播图 -16. 意见反馈:配合前端接口收集用户的反馈信息 -17. 商品管理:支持多规格、单规格添加商品、提供对应的支付接口和前端商品详情接口供参考 -18. 订单管理:主要为商品订单的管理有发货、统计...... -19. 财务统计:平台订单等财务统计 -20. 其他功能:内置微信登录、小程序登录、短信登录、密码登录、微信企业到零钱、微信支付、支付宝支付、极光推送等API。 +1. DashBoard: 数据分析查看 +2. CRUD: 面向配置的crud功能 +3. 计划任务(定时任务,运维能力),django-celery-beat 定时任务 +4. 服务器监控面板(运维能力),支持windows和linux服务器的实时服务器资源状态监控 +5. 终端服务webssh(运维能力),支持基于channels的websocket与xterm的webssh(实现websocket的simple-jwt认证,并实现请求方法和接口地址的权限控制) +6. 部门管理:配置系统组织机构(公司、部门、角色),树结构展现支持数据权限。 +7. 菜单管理:配置系统菜单,操作权限,按钮权限标识、后端接口权限等。 +8. 角色管理:角色菜单权限、数据权限、设置角色按部门进行数据范围权限划分。 +9. 权限管理:授权角色的权限范围。 +10. 地区管理:国内省市区管理。 +11. 管理员管理:主要管理系统管理员账号。 +12. 用户管理:主要管理前端用户。 +13. 个人中心:主要设置登录系统的个人昵称、密码等账号信息。 +14. 操作日志:系统正常操作日志记录和查询;系统异常信息日志记录和查询。 +15. 平台设置:系统设置如字典参数、轮播图 +16. 意见反馈:配合前端接口收集用户的反馈信息 +17. 商品管理:支持多规格、单规格添加商品、提供对应的支付接口和前端商品详情接口供参考 +18. 订单管理:主要为商品订单的管理有发货、统计...... +19. 财务统计:平台订单等财务统计 +20. 其他功能:内置微信登录、小程序登录、短信登录、密码登录、微信企业到零钱、微信支付、支付宝支付、极光推送等API。 ## django-vue-lyadmin项目启动视频讲解 @@ -94,7 +94,7 @@ gitee地址(主推):https://gitee.com/lybbn/django-vue-lyadmin ## lyadmin后端 -~~~bash +```bash 1. 进入项目目录 2. 在 config.py 中配置数据库信息 @@ -125,7 +125,7 @@ gitee地址(主推):https://gitee.com/lybbn/django-vue-lyadmin python manage.py runserver 127.0.0.1:8000 或使用 daphne (使用【终端服务】的需要使用此asgi方式部署来支持websocket): daphne -b 0.0.0.0 -p 8000 --proxy-headers application.asgi:application - + 使用celery【计划任务】需要额外启动celery 和 beat(调度器) mac/linux: celery -A application worker -B -l info @@ -135,11 +135,11 @@ gitee地址(主推):https://gitee.com/lybbn/django-vue-lyadmin 9. 线上linux部署启动项目(需修改gunicorn_restart.sh中gunicorn命令安装目录) sh gunicorn_restart.sh -~~~ +``` #### docker-compose 部署 -~~~bash +```bash 1、先安装docker环境 2、pip install docker-compose 安装docker-compose 3、切换到项目根目录运行 docker-compose build 创建环境 @@ -159,17 +159,18 @@ docker-compose restart docker-compose up -d --build 7、说明:默认docker端口mysql:3306\redis:6379\前端:8080\后台:8000 如果端口冲突会造成启动docker失败情况 -~~~ +``` ## 其他说明 1、使用本项目记得要更改application-->settings-->SECRET_KEY -~~~bash + +```bash 可以运行python manage.py shell from django.core.management import utils utils.get_random_secret_key() 获取生成的新SECRET_KEY替换原来的老KEY -~~~ +``` ## lyadmin前端 @@ -179,7 +180,6 @@ django-vue-lyadmin 是一套前后端分离的前端后台管理框架,是适 #### 软件架构 - ``` 1、vue3 2、elementplus @@ -189,25 +189,22 @@ django-vue-lyadmin 是一套前后端分离的前端后台管理框架,是适 #### 安装教程 - ``` cd frontend npm install --registry=https://registry.npmmirror.com ``` - #### 使用说明 -调试开发直接运行(development): +调试开发直接运行(development): ``` npm start ``` - #### 打包 -线上部署(production): +线上部署(production): ``` npm run build @@ -217,11 +214,11 @@ npm run build ## 线上部署注意事项 -~~~bash +```bash 1、前端打包前修改frontend\src\api\url里面的线上服务器ip或域名 2、前端打包的dist里面的静态文件放到backend\frontend\目录 3、运行python manage.py collectstatic收集静态文件到django -~~~ +``` ## 演示图 @@ -258,4 +255,4 @@ npm run build - \ No newline at end of file + diff --git a/backend/frontend/index.html b/backend/frontend/index.html index 7a4bc8f..3bfe844 100644 --- a/backend/frontend/index.html +++ b/backend/frontend/index.html @@ -16,7 +16,7 @@ } }
加载中
\ No newline at end of file diff --git a/backend/frontend/static/js/app.c999728a.js b/backend/frontend/static/js/app.c999728a.js new file mode 100644 index 0000000..6637dfe --- /dev/null +++ b/backend/frontend/static/js/app.c999728a.js @@ -0,0 +1,56529 @@ +/*! For license information please see app.c999728a.js.LICENSE.txt */ +/******/(function(){// webpackBootstrap +/******/var __webpack_modules__={ +/***/235: +/***/function(e,t,n){"use strict"; +// ESM COMPAT FLAG +n.r(t), +// EXPORTS +n.d(t,{default:function(){/* binding */return a}}); +// EXTERNAL MODULE: ./node_modules/vue/dist/vue.esm-bundler.js + 5 modules +var r=n(61431),o=n(90517),i=n(69713); +// EXTERNAL MODULE: ./src/store/lyFormBuilder.js +/* harmony default export */var a={__name:"alert-widget-ly",props:{field:Object,parentWidget:Object,parentList:Array,indexOfParentList:Number,designState:{type:Boolean,default:!1}},setup(e,{expose:t}){const{proxy:n}=(0,r.getCurrentInstance)(),a=e,l=((0,o/* useBuilderStore */.k)(),(0,r.ref)(null));let s=(0,r.ref)([]),c=(0,r.inject)("refList",null),{createFieldRules:u}=(0,i/* default */.A)();return(0,r.watch)((()=>a.field.options.defaultValue),((e,t)=>{l.value=e})),(0,r.onMounted)((()=>{a.field.formItemFlag&&(l.value=a.field.options.defaultValue),null!=c&&null!=c.value&&a.field.options.name&&(c.value[a.field.options.name]=n)})),t({getWidgetRef:function(e){return null!=c&&null!=c.value?c.value[e]:null},getValue:function(){return l.value},setValue:function(e){l.value=e; +// updateFormModel(newValue) +// handleFieldValidation(getPropName(props)) +},setHidden:function(e){a.field.options.hidden=e,e?a.field.formItemFlag&&s.value.splice(0,s.value.length):u(a.field,s.value)}}),(t,n)=>{const o=(0,r.resolveComponent)("el-alert"),i=(0,r.resolveComponent)("static-content-wrapper-ly");return(0,r.openBlock)(),(0,r.createBlock)(i,{field:e.field,rules:(0,r.unref)(s),"design-state":e.designState,"parent-widget":e.parentWidget,"parent-list":e.parentList,"index-of-parent-list":e.indexOfParentList},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(o,{ref:"lyfieldEditor",title:e.field.options.title,type:e.field.options.type,description:e.field.options.description,closable:e.field.options.closable,center:e.field.options.center,"close-text":e.field.options.closeText,"show-icon":e.field.options.showIcon,effect:e.field.options.effect},null,8,["title","type","description","closable","center","close-text","show-icon","effect"])])),_:1},8,["field","rules","design-state","parent-widget","parent-list","index-of-parent-list"])}}}; +/***/}, +/***/241: +/***/function(e,t,n){"use strict"; +/* harmony import */var r=n(41917).A.Symbol; +/** Built-in value references. */ +/* harmony default export */t.A=r}, +/***/539: +/***/function(e,t,n){var r=n(28966),o=n(40481),i=n(658),a=n(16626) +/** + * 将数值四舍五入并格式化为固定小数位的字符串 + * + * @param {string|number} num 数值 + * @param {number} digits 小数保留位数 + * @return {String} + */;e.exports=function(e,t){var n=o(r(e,t|=0)).split("."),l=n[0],s=n[1]||"",c=t-s.length;return t?c>0?l+"."+s+i("0",c):l+a(s,Math.abs(c)):l} +/***/}, +/***/655: +/***/function(e,t,n){"use strict";var r=n(36955),o=String;e.exports=function(e){if("Symbol"===r(e))throw new TypeError("Cannot convert a Symbol value to a string");return o(e)}}, +/***/658: +/***/function(e,t,n){var r=n(63982);e.exports=function(e,t){if(e.repeat)return e.repeat(t);var n=isNaN(t)?[]:new Array(r(t));return n.join(e)+(n.length>0?e:"")} +/***/}, +/***/668: +/***/function(){ +/** + * Copyright (c) Tiny Technologies, Inc. All rights reserved. + * Licensed under the LGPL or a commercial license. + * For LGPL see License.txt in the project root for license information. + * For commercial licenses see https://www.tiny.cloud/ + * + * Version: 5.10.2 (2021-11-17) + */ +!function(){"use strict";var e=tinymce.util.Tools.resolve("tinymce.PluginManager"),t=tinymce.util.Tools.resolve("tinymce.dom.DOMUtils"),n=tinymce.util.Tools.resolve("tinymce.util.Tools"),r=function(e){return e.getParam("save_enablewhendirty",!0)},o=function(e,t){e.notificationManager.open({text:t,type:"error"})},i=function(e){e.addCommand("mceSave",(function(){!function(e){var n=t.DOM.getParent(e.id,"form");if(!r(e)||e.isDirty()){if(e.save(),function(e){return!!e.getParam("save_onsavecallback")}(e))return e.execCallback("save_onsavecallback",e),void e.nodeChanged();n?(e.setDirty(!1),n.onsubmit&&!n.onsubmit()||("function"==typeof n.submit?n.submit():o(e,"Error: Form submit field collision.")),e.nodeChanged()):o(e,"Error: No form element found.")}}(e)})),e.addCommand("mceCancel",(function(){!function(e){var t=n.trim(e.startContent);!function(e){return!!e.getParam("save_oncancelcallback")}(e)?e.resetContent(t):e.execCallback("save_oncancelcallback",e)}(e)}))},a=function(e){return function(t){var n=function(){t.setDisabled(r(e)&&!e.isDirty())};return n(),e.on("NodeChange dirty",n),function(){return e.off("NodeChange dirty",n)}}};e.add("save",(function(e){!function(e){e.ui.registry.addButton("save",{icon:"save",tooltip:"Save",disabled:!0,onAction:function(){return e.execCommand("mceSave")},onSetup:a(e)}),e.ui.registry.addButton("cancel",{icon:"cancel",tooltip:"Cancel",disabled:!0,onAction:function(){return e.execCommand("mceCancel")},onSetup:a(e)}),e.addShortcut("Meta+S","","mceSave")}(e),i(e)}))}(); +/***/}, +/***/798: +/***/function(e,t,n){"use strict";var r=n(2237),o=n(96430),i=n(35657),a=n(53848),l=n(24993),s=function(){};function c(e){return l(r,e)}var u="3.7.4";s.VERSION=u,s.version=u,s.mixin=function(){o(arguments,(function(e){i(e,(function(e,t){s[t]=a(e)?function(){var t=e.apply(s.$context,arguments);return s.$context=null,t}:e}))}))},s.setup=c,s.setConfig=c,s.getConfig=function(){return r},e.exports=s +/***/}, +/***/838: +/***/function(e,t,n){"use strict"; +/* harmony export */n.d(t,{ +/* harmony export */SN:function(){/* binding */return l}, +/* harmony export */mU:function(){/* binding */return a}, +/* harmony export */wC:function(){/* binding */return s} +/* harmony export */}); +/* unused harmony export useSizeProps */ +/* harmony import */var r=n(61431),o=n(50819),i=n(18472); +/* harmony import */const a=(0,o/* .buildProp */.Y8)({type:String,values:i/* .componentSizes */.I,required:!1}),l=Symbol("size"),s=()=>{const e=(0,r.inject)(l,{});return(0,r.computed)((()=>(0,r.unref)(e.size)||""))}}, +/***/1397: +/***/function(e,t,n){"use strict"; +// ESM COMPAT FLAG +n.r(t), +// EXPORTS +n.d(t,{default:function(){/* binding */return m}}); +// EXTERNAL MODULE: ./node_modules/vue/dist/vue.esm-bundler.js + 5 modules +var r=n(61431);// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/views/adminManage/adminManage.vue?vue&type=template&id=73060d5a +const o={class:"tableSelect",ref:"tableSelect"},i={class:"table"},a=["textContent"],l={style:{display:"flex","justify-content":"space-between","align-items":"center"}},s=["onClick"],c=["onClick"];// ./src/views/adminManage/adminManage.vue?vue&type=template&id=73060d5a +// EXTERNAL MODULE: ./src/views/adminManage/components/addAdmin.vue + 6 modules +var u=n(41636),d=n(10594),f=n(37741),h=n(40412),p={components:{Pagination:d/* default */.A,addAdmin:u.default},name:"adminManage",data(){return{isFull:!1,visible:!1,tableHeight:500,loadingPage:!1,isDialogVisible:!1,formInline:{page:1,limit:10},pageparm:{page:1,limit:10,total:0},statusList:[{id:1,name:"正常"},{id:0,name:"禁用"}],timers:[],tableData:[]}},methods:{ +// 表格序列号 +getIndex(e){ +// (当前页 - 1) * 当前显示数据条数 + 当前行数据的索引 + 1 +return(this.pageparm.page-1)*this.pageparm.limit+e+1},setFull(){this.isFull=!this.isFull,window.dispatchEvent(new Event("resize"))},handleAddClick(){this.isDialogVisible=!0,this.$nextTick((()=>{this.$refs.addAdminFlag.handleOpen(null,"新增")}))},handleEdit(e,t){if("edit"==t)this.isDialogVisible=!0,this.$nextTick((()=>{this.$refs.addAdminFlag.handleOpen(e,"编辑")}));else if("delete"==t){let t=this;t.$confirm("您确定要删除选中的管理员?",{closeOnClickModal:!1}).then((n=>{(0,h.apiSystemUserDelte)({id:e.id}).then((e=>{2e3==e.code?(t.$message.success(e.msg),t.search()):t.$message.warning(e.msg)}))})).catch((()=>{}))}else"reset"==t&&(this.formInline={page:1,limit:10},this.pageparm={page:1,limit:10,total:0},this.getData())},callFather(e){this.formInline.page=e.page,this.formInline.limit=e.limit,this.getData()},search(){this.formInline.page=1,this.formInline.limit=10,this.getData()}, +//获取列表 +async getData(){this.loadingPage=!0,(0,h.apiSystemUser)(this.formInline).then((e=>{this.loadingPage=!1,2e3==e.code&&(this.tableData=e.data.data,this.pageparm.page=e.data.page,this.pageparm.limit=e.data.limit,this.pageparm.total=e.data.total)}))},timeChange(e){e?(this.formInline.beginAt=(0,f.dateFormats)(e[0],"yyyy-MM-dd hh:mm:ss"),this.formInline.endAt=(0,f.dateFormats)(e[1],"yyyy-MM-dd hh:mm:ss")):(this.formInline.beginAt=null,this.formInline.endAt=null),this.search()}, +// 计算搜索栏的高度 +listenResize(){this.$nextTick((()=>{this.getTheTableHeight()}))},getTheTableHeight(){let e=this.$refs.tableSelect?this.$refs.tableSelect.offsetHeight:0;e=this.isFull?e-110:e,this.tableHeight=(0,f.getTableHeight)(e)}},created(){this.getData()},mounted(){ +// 监听页面宽度变化搜索框的高度 +window.addEventListener("resize",this.listenResize),this.$nextTick((()=>{this.getTheTableHeight()}))},unmounted(){ +// 页面销毁,去掉监听事件 +window.removeEventListener("resize",this.listenResize)}}; +// EXTERNAL MODULE: ./src/components/Pagination.vue + 4 modules +/* harmony default export */var m=(0,n(66262).A)(p,[["render",function(e,t,n,u,d,f){const h=(0,r.resolveComponent)("el-input"),p=(0,r.resolveComponent)("el-form-item"),m=(0,r.resolveComponent)("el-option"),g=(0,r.resolveComponent)("el-select"),v=(0,r.resolveComponent)("el-button"),A=(0,r.resolveComponent)("el-form"),y=(0,r.resolveComponent)("el-table-column"),b=(0,r.resolveComponent)("el-tag"),O=(0,r.resolveComponent)("full-screen"),w=(0,r.resolveComponent)("el-icon"),x=(0,r.resolveComponent)("el-tooltip"),_=(0,r.resolveComponent)("el-table"),C=(0,r.resolveComponent)("Pagination"),k=(0,r.resolveComponent)("add-admin"),S=(0,r.resolveDirective)("loading");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:(0,r.normalizeClass)({"ly-is-full":d.isFull})},[(0,r.createElementVNode)("div",o,[(0,r.createVNode)(A,{inline:!0,model:d.formInline,"label-position":"left"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(p,{label:"管理员名称:"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(h,{modelValue:d.formInline.name,"onUpdate:modelValue":t[0]||(t[0]=e=>d.formInline.name=e),modelModifiers:{trim:!0},maxlength:"60",clearable:"",placeholder:"管理员名称",onChange:f.search,style:{width:"150px"}},null,8,["modelValue","onChange"])])),_:1}),(0,r.createVNode)(p,{label:"管理员账号:"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(h,{modelValue:d.formInline.username,"onUpdate:modelValue":t[1]||(t[1]=e=>d.formInline.username=e),modelModifiers:{trim:!0},maxlength:"60",clearable:"",placeholder:"管理员账号",onChange:f.search,style:{width:"150px"}},null,8,["modelValue","onChange"])])),_:1}),(0,r.createVNode)(p,{label:"状态:"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(g,{modelValue:d.formInline.is_active,"onUpdate:modelValue":t[2]||(t[2]=e=>d.formInline.is_active=e),placeholder:"请选择",clearable:"",style:{width:"120px"},onChange:f.search},{default:(0,r.withCtx)((()=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(d.statusList,(e=>((0,r.openBlock)(),(0,r.createBlock)(m,{key:e.id,label:e.name,value:e.id},null,8,["label","value"])))),128))])),_:1},8,["modelValue","onChange"])])),_:1}),(0,r.createVNode)(p,{label:""},{default:(0,r.withCtx)((()=>[(0,r.withDirectives)((0,r.createVNode)(v,{onClick:f.search,type:"primary",icon:"Search"},{default:(0,r.withCtx)((()=>t[6]||(t[6]=[(0,r.createTextVNode)("查询")]))),_:1},8,["onClick"]),[[r.vShow,e.hasPermission(this.$route.name,"Search")]])])),_:1}),(0,r.createVNode)(p,{label:""},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(v,{onClick:t[3]||(t[3]=e=>f.handleEdit("","reset")),icon:"Refresh"},{default:(0,r.withCtx)((()=>t[7]||(t[7]=[(0,r.createTextVNode)("重置")]))),_:1})])),_:1}),(0,r.createVNode)(p,{label:""},{default:(0,r.withCtx)((()=>[(0,r.withDirectives)((0,r.createVNode)(v,{icon:"Plus",onClick:f.handleAddClick,type:"primary"},{default:(0,r.withCtx)((()=>t[8]||(t[8]=[(0,r.createTextVNode)("新增")]))),_:1},8,["onClick"]),[[r.vShow,e.hasPermission(this.$route.name,"Create")]])])),_:1})])),_:1},8,["model"])],512),(0,r.createElementVNode)("div",i,[(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createBlock)(_,{height:"calc("+d.tableHeight+"px)",border:"",data:d.tableData,ref:"tableref",style:{width:"100%"}},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(y,{type:"index",width:"60",align:"center",label:"序号"},{default:(0,r.withCtx)((e=>[(0,r.createElementVNode)("span",{textContent:(0,r.toDisplayString)(f.getIndex(e.$index))},null,8,a)])),_:1}),(0,r.createVNode)(y,{"min-width":"120",prop:"name",label:"管理员名称"}),(0,r.createVNode)(y,{"min-width":"150",prop:"username",label:"管理员账号"}),(0,r.createVNode)(y,{width:"160",prop:"deptName",label:"部门"},{default:(0,r.withCtx)((e=>[e.row.deptName?((0,r.openBlock)(),(0,r.createBlock)(b,{key:0},{default:(0,r.withCtx)((()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.row.deptName),1)])),_:2},1024)):(0,r.createCommentVNode)("",!0)])),_:1}),(0,r.createVNode)(y,{"min-width":"100",prop:"roleNames",label:"角色"},{default:(0,r.withCtx)((e=>[e.row.roleNames?((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,{key:0},(0,r.renderList)(e.row.roleNames,((e,t)=>((0,r.openBlock)(),(0,r.createBlock)(b,{key:t},{default:(0,r.withCtx)((()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e),1)])),_:2},1024)))),128)):(0,r.createCommentVNode)("",!0)])),_:1}),(0,r.createVNode)(y,{"min-width":"100",label:"状态"},{default:(0,r.withCtx)((e=>[e.row.is_active?((0,r.openBlock)(),(0,r.createBlock)(b,{key:0},{default:(0,r.withCtx)((()=>t[9]||(t[9]=[(0,r.createTextVNode)("正常")]))),_:1})):((0,r.openBlock)(),(0,r.createBlock)(b,{key:1,type:"danger"},{default:(0,r.withCtx)((()=>t[10]||(t[10]=[(0,r.createTextVNode)("禁用")]))),_:1}))])),_:1}),(0,r.createVNode)(y,{"min-width":"150",prop:"create_datetime",label:"创建时间"}),(0,r.createVNode)(y,{label:"操作",fixed:"right",width:"120"},{header:(0,r.withCtx)((()=>[(0,r.createElementVNode)("div",l,[t[11]||(t[11]=(0,r.createElementVNode)("div",null,"操作",-1)),(0,r.createElementVNode)("div",{onClick:t[4]||(t[4]=(...e)=>f.setFull&&f.setFull(...e))},[(0,r.createVNode)(x,{content:"全屏",placement:"bottom"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(w,null,{default:(0,r.withCtx)((()=>[(0,r.createVNode)(O)])),_:1})])),_:1})])])])),default:(0,r.withCtx)((t=>[(0,r.withDirectives)((0,r.createElementVNode)("span",{class:"table-operate-btn",onClick:e=>f.handleEdit(t.row,"edit")},"编辑",8,s),[[r.vShow,e.hasPermission(this.$route.name,"Update")]]),(0,r.withDirectives)((0,r.createElementVNode)("span",{class:"table-operate-btn",onClick:e=>f.handleEdit(t.row,"delete")},"删除",8,c),[[r.vShow,e.hasPermission(this.$route.name,"Delete")]])])),_:1})])),_:1},8,["height","data"])),[[S,d.loadingPage]])]),(0,r.createVNode)(C,{"child-msg":d.pageparm,onCallFather:f.callFather},null,8,["child-msg","onCallFather"]),d.isDialogVisible?((0,r.openBlock)(),(0,r.createBlock)(k,{key:0,ref:"addAdminFlag",onRefreshData:f.getData,onClosed:t[5]||(t[5]=e=>d.isDialogVisible=!1)},null,8,["onRefreshData"])):(0,r.createCommentVNode)("",!0)],2)}]]); +/***/}, +/***/1400: +/***/function(e,t,n){var r=n(95654),o=n(96430),i=n(24993);function a(e,t,n,r,l,s,c,u,d){var f,h,p,m,g,v=[],A=d.original,y=d.data,b=d.mapChildren||u,O=d.isEvery;return o(n,(function(o,w){f=s.concat([""+w]),h=c.concat([o]),m=e&&!O||r.call(l,o,w,n,f,t,h),g=u&&o[u],m||g?(A?p=o:(p=i({},o),y&&(p[y]=o)),p[b]=a(m,o,o[u],r,l,f,h,u,d),(m||p[b].length)&&v.push(p)):m&&v.push(p)})),v} +/** + * 从树结构中根据回调查找数据 + * + * @param {Object} obj 对象/数组 + * @param {Function} iterate(item, index, items, path, parent, nodes) 回调 + * @param {Object} options {children: 'children'} + * @param {Object} context 上下文 + * @return {Array} + */var l=r((function(e,t,n,r,o,i,l,s){return a(0,e,t,n,r,o,i,l,s)}));e.exports=l +/***/}, +/***/1548: +/***/function(e,t,n){"use strict";var r=n(44576),o=n(79039),i=n(39519),a=n(84215),l=r.structuredClone;e.exports=!!l&&!o((function(){ +// prevent V8 ArrayBufferDetaching protector cell invalidation and performance degradation +// https://github.com/zloirock/core-js/issues/679 +if("DENO"===a&&i>92||"NODE"===a&&i>94||"BROWSER"===a&&i>97)return!1;var e=new ArrayBuffer(8),t=l(e,{transfer:[e]});return 0!==e.byteLength||8!==t.byteLength}))}, +/***/1625: +/***/function(e,t,n){"use strict";var r=n(79504);e.exports=r({}.isPrototypeOf)}, +/***/1668: +/***/function(e,t,n){"use strict"; +// EXPORTS +n.d(t,{A:function(){/* binding */return d}}); +/* harmony default export */var r=// ./node_modules/lodash-es/_baseHasIn.js +/** + * The base implementation of `_.hasIn` without support for deep paths. + * + * @private + * @param {Object} [object] The object to query. + * @param {Array|string} key The key to check. + * @returns {boolean} Returns `true` if `key` exists, else `false`. + */ +function(e,t){return null!=e&&t in Object(e)},o=n(81094),i=n(52274),a=n(92049),l=n(25353),s=n(5254),c=n(30901); +// EXTERNAL MODULE: ./node_modules/lodash-es/_castPath.js + 4 modules +/* harmony default export */var u=// ./node_modules/lodash-es/_hasPath.js +/** + * Checks if `path` exists on `object`. + * + * @private + * @param {Object} object The object to query. + * @param {Array|string} path The path to check. + * @param {Function} hasFunc The function to check properties. + * @returns {boolean} Returns `true` if `path` exists, else `false`. + */ +function(e,t,n){for(var r=-1,u=(t=(0,o/* default */.A)(t,e)).length,d=!1;++r true + * + * _.hasIn(object, 'a.b'); + * // => true + * + * _.hasIn(object, ['a', 'b']); + * // => true + * + * _.hasIn(object, 'b'); + * // => false + */ +function(e,t){return null!=e&&u(e,t,r)}; +/***/}, +/***/1767: +/***/function(e){"use strict"; +// `GetIteratorDirect(obj)` abstract operation +// https://tc39.es/proposal-iterator-helpers/#sec-getiteratordirect +e.exports=function(e){return{iterator:e,next:e.next,done:!1}}}, +/***/1769: +/***/function(e,t,n){var r=n(73971) +/* eslint-disable valid-typeof */,o=typeof location===r?0:location;e.exports=o +/***/}, +/***/1968: +/***/function(e){e.exports=function(e,t){return e===t} +/***/}, +/***/1982: +/***/function(e,t,n){"use strict"; +// ESM COMPAT FLAG +n.r(t), +// EXPORTS +n.d(t,{default:function(){/* binding */return l}}); +// EXTERNAL MODULE: ./node_modules/vue/dist/vue.esm-bundler.js + 5 modules +var r=n(61431),o=n(90517),i=n(69713),a={__name:"date-range-widget-ly",props:{field:Object,parentWidget:Object,parentList:Array,indexOfParentList:Number,designState:{type:Boolean,default:!1}},setup(e,{expose:t}){const{proxy:n}=(0,r.getCurrentInstance)(),a=e,l=((0,o/* useBuilderStore */.k)(),(0,r.ref)(null));let s=(0,r.ref)([]);const c=(0,r.computed)((()=>a.field.options.size||"default"));function u(e){if(a.field.options.onFocus){new Function("event",a.field.options.onFocus).call(n,e)}}function d(e){if(a.field.options.onBlur){new Function("event",a.field.options.onBlur).call(n,e)}}let{createFieldRules:f,getPropName:h,handleFieldValidation:p}=(0,i/* default */.A)();const m=(0,r.inject)("globalFormModel",null);let g=(0,r.inject)("refList",null);function v(e){if(a.designState)return;let t=h(a);m.value[t]=e}function A(e){if(v(e),p(h(a)),a.field.options.onChange){new Function("value",a.field.options.onChange).call(n,e)}}return(0,r.watch)((()=>a.field.options.defaultValue),((e,t)=>{l.value=e})),(0,r.onMounted)((()=>{a.field.formItemFlag&&(m?void 0===m.value[a.field.options.name]&&void 0!==a.field.options.defaultValue?l.value=a.field.options.defaultValue:void 0===m.value[a.field.options.name]?m.value[a.field.options.name]=null:l.value=m.value[a.field.options.name]:l.value=a.field.options.defaultValue),null!=g&&null!=g.value&&a.field.options.name&&(g.value[a.field.options.name]=n),f(a.field,s.value)})),t({getWidgetRef:function(e){return null!=g&&null!=g.value?g.value[e]:null},getValue:function(){return l.value},setValue:function(e){l.value=e,v(e),p(h(a))},setHidden:function(e){a.field.options.hidden=e,e?a.field.formItemFlag&&s.value.splice(0,s.value.length):f(a.field,s.value)}}),(t,n)=>{const o=(0,r.resolveComponent)("el-date-picker"),i=(0,r.resolveComponent)("form-item-wrapper-ly");return(0,r.openBlock)(),(0,r.createBlock)(i,{field:e.field,rules:(0,r.unref)(s),"design-state":e.designState,"parent-widget":e.parentWidget,"parent-list":e.parentList,"index-of-parent-list":e.indexOfParentList},{default:(0,r.withCtx)((()=>[(0,r.createElementVNode)("div",{class:(0,r.normalizeClass)([e.field.options.autoFullWidth?"lyfullwidth":""])},[(0,r.createVNode)(o,{ref:"lyfieldEditor",type:e.field.options.type,modelValue:l.value,"onUpdate:modelValue":n[0]||(n[0]=e=>l.value=e),readonly:e.field.options.readonly,disabled:e.field.options.disabled,size:c.value,clearable:e.field.options.clearable,editable:e.field.options.editable,format:e.field.options.format,"value-format":e.field.options.valueFormat,placeholder:e.field.options.placeholder||"选择日期","start-placeholder":e.field.options.startPlaceholder||"开始日期","end-placeholder":e.field.options.endPlaceholder||"结束日期",onFocus:u,onBlur:d,onChange:A},null,8,["type","modelValue","readonly","disabled","size","clearable","editable","format","value-format","placeholder","start-placeholder","end-placeholder"])],2)])),_:1},8,["field","rules","design-state","parent-widget","parent-list","index-of-parent-list"])}}}; +// EXTERNAL MODULE: ./src/store/lyFormBuilder.js +/* harmony default export */var l=(0,n(66262).A)(a,[["__scopeId","data-v-52010bd4"]]); +/***/}, +/***/2025: +/***/function(e,t,n){ +// Exports the "print" plugin for usage with module loaders +// Usage: +// CommonJS: +// require('tinymce/plugins/print') +// ES2015: +// import 'tinymce/plugins/print' +n(33174); +/***/}, +/***/2121: +/***/function(e,t,n){var r=n(75526) +/** + * 判断是否RegExp对象 + * + * @param {Object} obj 对象 + * @return {Boolean} + */("RegExp");e.exports=r +/***/}, +/***/2154: +/***/function(e,t,n){"use strict"; +/* harmony export */n.d(t,{ +/* harmony export */Et:function(){/* binding */return l}, +/* harmony export */Hp:function(){/* binding */return d}, +/* harmony export */Im:function(){/* binding */return s}, +/* harmony export */Lm:function(){/* binding */return a}, +/* harmony export */Xj:function(){/* binding */return u}, +/* harmony export */b0:function(){/* binding */return i}, +/* harmony export */l6:function(){/* binding */return f}, +/* harmony export */vq:function(){/* binding */return c} +/* harmony export */}); +/* harmony import */var r=n(90033),o=n(97859); +/* harmony import */const i=e=>void 0===e,a=e=>"boolean"==typeof e,l=e=>"number"==typeof e,s=e=>!e&&0!==e||(0,r/* .isArray */.cy)(e)&&0===e.length||(0,r/* .isObject */.Gv)(e)&&!Object.keys(e).length,c=e=>"undefined"!=typeof Element&&e instanceof Element,u=e=>(0,o/* ["default"] */.A)(e),d=e=>!!(0,r/* .isString */.Kg)(e)&&!Number.isNaN(Number(e)),f=e=>e===window +//# sourceMappingURL=types.mjs.map +/***/}, +/***/2237: +/***/function(e){"use strict";e.exports={keyId:1,cookies:{path:"/"},treeOptions:{parentKey:"parentId",key:"id",children:"children"},parseDateFormat:"yyyy-MM-dd HH:mm:ss",firstDayOfWeek:1} +/***/}, +/***/2250: +/***/function(e,t,n){"use strict"; +/* harmony export */n.d(t,{ +/* harmony export */D$:function(){/* binding */return s}, +/* harmony export */Od:function(){/* binding */return l}, +/* harmony export */ro:function(){/* binding */return c} +/* harmony export */}); +/* unused harmony export buttonNativeTypes */ +/* harmony import */var r=n(48548),o=n(50819),i=n(838),a=n(25343); +/* harmony import */const l=["default","primary","success","warning","info","danger","text",""],s=(0,o/* .buildProps */.b_)({size:i/* .useSizeProp */.mU,disabled:Boolean,type:{type:String,values:l,default:""},icon:{type:a/* .iconPropType */.Ze},nativeType:{type:String,values:["button","submit","reset"],default:"button"},loading:Boolean,loadingIcon:{type:a/* .iconPropType */.Ze,default:()=>r.Loading},plain:Boolean,text:Boolean,link:Boolean,bg:Boolean,autofocus:Boolean,round:Boolean,circle:Boolean,color:String,dark:Boolean,autoInsertSpace:{type:Boolean,default:void 0},tag:{type:(0,o/* .definePropType */.jq)([String,Object]),default:"button"}}),c={click:e=>e instanceof MouseEvent}}, +/***/2301: +/***/function(e,t,n){"use strict";n.r(t); +/* harmony import */var r=n(12897),o=n.n(r),i=n(55042),a=n.n(i),l=new(o())({id:"icon-slider-field",use:"icon-slider-field-usage",viewBox:"0 0 1024 1024",content:''}); +/* harmony import */a().add(l); +/* harmony default export */t.default=l}, +/***/2360: +/***/function(e,t,n){"use strict"; +/* global ActiveXObject -- old IE, WSH */var r,o=n(28551),i=n(96801),a=n(88727),l=n(30421),s=n(20397),c=n(4055),u=n(66119),d="prototype",f="script",h=u("IE_PROTO"),p=function(){/* empty */},m=function(e){return"<"+f+">"+e+""},g=function(e){e.write(m("")),e.close();var t=e.parentWindow.Object; +// eslint-disable-next-line no-useless-assignment -- avoid memory leak +return e=null,t},v=function(){try{r=new ActiveXObject("htmlfile")}catch(e){/* ignore */}var e,t,n;v="undefined"!=typeof document?document.domain&&r?g(r):(t=c("iframe"),n="java"+f+":",t.style.display="none",s.appendChild(t), +// https://github.com/zloirock/core-js/issues/475 +t.src=String(n),(e=t.contentWindow.document).open(),e.write(m("document.F=Object")),e.close(),e.F):g(r);for(// WSH +var o=a.length;o--;)delete v[d][a[o]];return v()};l[h]=!0, +// `Object.create` method +// https://tc39.es/ecma262/#sec-object.create +// eslint-disable-next-line es/no-object-create -- safe +e.exports=Object.create||function(e,t){var n;return null!==e?(p[d]=o(e),n=new p,p[d]=null, +// add "__proto__" for Object.getPrototypeOf polyfill +n[h]=e):n=v(),void 0===t?n:i.f(n,t)}}, +/***/2400: +/***/function(e,t,n){"use strict"; +/* harmony export */n.d(t,{ +/* harmony export */P:function(){/* binding */return l}, +/* harmony export */Z:function(){/* binding */return a} +/* harmony export */}); +/* harmony import */var r=n(34253),o=n(83412),i=n(10992); +/* harmony import */ +/* +* Licensed to the Apache Software Foundation (ASF) under one +* or more contributor license agreements. See the NOTICE file +* distributed with this work for additional information +* regarding copyright ownership. The ASF licenses this file +* to you under the Apache License, Version 2.0 (the +* "License"); you may not use this file except in compliance +* with the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, +* software distributed under the License is distributed on an +* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +* KIND, either express or implied. See the License for the +* specific language governing permissions and limitations +* under the License. +*/ +/** + * AUTO-GENERATED FILE. DO NOT MODIFY. + */ +/* +* Licensed to the Apache Software Foundation (ASF) under one +* or more contributor license agreements. See the NOTICE file +* distributed with this work for additional information +* regarding copyright ownership. The ASF licenses this file +* to you under the Apache License, Version 2.0 (the +* "License"); you may not use this file except in compliance +* with the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, +* software distributed under the License is distributed on an +* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +* KIND, either express or implied. See the License for the +* specific language governing permissions and limitations +* under the License. +*/ +// @ts-nocheck +/** + * Layout list like component. + * It will box layout each items in group of component and then position the whole group in the viewport + * @param {module:zrender/group/Group} group + * @param {module:echarts/model/Component} componentModel + * @param {module:echarts/ExtensionAPI} + */ +function a(e,t,n){var o=t.getBoxLayoutParams(),i=t.get("padding"),a={width:n.getWidth(),height:n.getHeight()},l=(0,r/* .getLayoutRect */.dV)(o,a,i);(0,r/* .box */.aP)(t.get("orient"),e,t.get("itemGap"),l.width,l.height),(0,r/* .positionElement */.m$)(e,o,a,i)}function l(e,t){var n=o/* .normalizeCssArray */.QX(t.get("padding")),r=t.getItemStyle(["color","opacity"]); +// FIXME +// `subPixelOptimizeRect` may bring some gap between edge of viewpart +// and background rect when setting like `left: 0`, `top: 0`. +// graphic.subPixelOptimizeRect(rect); +return r.fill=t.get("backgroundColor"),e=new i/* ["default"] */.A({shape:{x:e.x-n[3],y:e.y-n[0],width:e.width+n[1]+n[3],height:e.height+n[0]+n[2],r:t.get("borderRadius")},style:r,silent:!0,z2:-1})} +/***/}, +/***/2553: +/***/function(){ +/** + * Copyright (c) Tiny Technologies, Inc. All rights reserved. + * Licensed under the LGPL or a commercial license. + * For LGPL see License.txt in the project root for license information. + * For commercial licenses see https://www.tiny.cloud/ + * + * Version: 5.10.2 (2021-11-17) + */ +!function(){"use strict";var e,t=tinymce.util.Tools.resolve("tinymce.PluginManager"),n=(e=void 0,function(t){return e===t}),r=tinymce.util.Tools.resolve("tinymce.util.Delay"),o=tinymce.util.Tools.resolve("tinymce.util.LocalStorage"),i=tinymce.util.Tools.resolve("tinymce.util.Tools"),a=function(e,t){var n=e||t,r=/^(\d+)([ms]?)$/.exec(""+n);return(r[2]?{s:1e3,m:6e4}[r[2]]:1)*parseInt(n,10)},l=function(e){var t=document.location;return e.getParam("autosave_prefix","tinymce-autosave-{path}{query}{hash}-{id}-").replace(/{path}/g,t.pathname).replace(/{query}/g,t.search).replace(/{hash}/g,t.hash).replace(/{id}/g,e.id)},s=function(e,t){if(n(t))return e.dom.isEmpty(e.getBody());var r=i.trim(t);if(""===r)return!0;var o=(new DOMParser).parseFromString(r,"text/html");return e.dom.isEmpty(o)},c=function(e){var t=parseInt(o.getItem(l(e)+"time"),10)||0;return!((new Date).getTime()-t>function(e){return a(e.getParam("autosave_retention"),"20m")}(e))||(u(e,!1),!1)},u=function(e,t){var n=l(e);o.removeItem(n+"draft"),o.removeItem(n+"time"),!1!==t&&function(e){e.fire("RemoveDraft")}(e)},d=function(e){var t=l(e);!s(e)&&e.isDirty()&&(o.setItem(t+"draft",e.getContent({format:"raw",no_events:!0})),o.setItem(t+"time",(new Date).getTime().toString()),function(e){e.fire("StoreDraft")}(e))},f=function(e){var t=l(e);c(e)&&(e.setContent(o.getItem(t+"draft"),{format:"raw"}),function(e){e.fire("RestoreDraft")}(e))},h=function(e){var t=function(e){return a(e.getParam("autosave_interval"),"30s")}(e);r.setEditorInterval(e,(function(){d(e)}),t)},p=function(e){e.undoManager.transact((function(){f(e),u(e)})),e.focus()},m=tinymce.util.Tools.resolve("tinymce.EditorManager"),g=function(e){return function(t){t.setDisabled(!c(e));var n=function(){return t.setDisabled(!c(e))};return e.on("StoreDraft RestoreDraft RemoveDraft",n),function(){return e.off("StoreDraft RestoreDraft RemoveDraft",n)}}};t.add("autosave",(function(e){return function(e){e.editorManager.on("BeforeUnload",(function(e){var t;i.each(m.get(),(function(e){e.plugins.autosave&&e.plugins.autosave.storeDraft(),!t&&e.isDirty()&&function(e){return e.getParam("autosave_ask_before_unload",!0)}(e)&&(t=e.translate("You have unsaved changes are you sure you want to navigate away?"))})),t&&(e.preventDefault(),e.returnValue=t)}))}(e),function(e){h(e),e.ui.registry.addButton("restoredraft",{tooltip:"Restore last draft",icon:"restore-draft",onAction:function(){p(e)},onSetup:g(e)}),e.ui.registry.addMenuItem("restoredraft",{text:"Restore last draft",icon:"restore-draft",onAction:function(){p(e)},onSetup:g(e)})}(e),e.on("init",(function(){(function(e){return e.getParam("autosave_restore_when_empty",!1)})(e)&&e.dom.isEmpty(e.getBody())&&f(e)})),function(e){return{hasDraft:function(){return c(e)},storeDraft:function(){return d(e)},restoreDraft:function(){return f(e)},removeDraft:function(t){return u(e,t)},isEmpty:function(t){return s(e,t)}}}(e)}))}(); +/***/}, +/***/2609: +/***/function(e){"use strict";e.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAAAyCAYAAAAeP4ixAAAACXBIWXMAAAsTAAALEwEAmpwYAAAF8WlUWHRYTUw6Y29tLmFkb2JlLnhtcAAAAAAAPD94cGFja2V0IGJlZ2luPSLvu78iIGlkPSJXNU0wTXBDZWhpSHpyZVN6TlRjemtjOWQiPz4gPHg6eG1wbWV0YSB4bWxuczp4PSJhZG9iZTpuczptZXRhLyIgeDp4bXB0az0iQWRvYmUgWE1QIENvcmUgNi4wLWMwMDIgNzkuMTY0NDg4LCAyMDIwLzA3LzEwLTIyOjA2OjUzICAgICAgICAiPiA8cmRmOlJERiB4bWxuczpyZGY9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkvMDIvMjItcmRmLXN5bnRheC1ucyMiPiA8cmRmOkRlc2NyaXB0aW9uIHJkZjphYm91dD0iIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtbG5zOmRjPSJodHRwOi8vcHVybC5vcmcvZGMvZWxlbWVudHMvMS4xLyIgeG1sbnM6cGhvdG9zaG9wPSJodHRwOi8vbnMuYWRvYmUuY29tL3Bob3Rvc2hvcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RFdnQ9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZUV2ZW50IyIgeG1wOkNyZWF0b3JUb29sPSJBZG9iZSBQaG90b3Nob3AgMjIuMCAoV2luZG93cykiIHhtcDpDcmVhdGVEYXRlPSIyMDI0LTAyLTI5VDIxOjAxOjA2KzA4OjAwIiB4bXA6TW9kaWZ5RGF0ZT0iMjAyNC0wMi0yOVQyMToyMjo0NiswODowMCIgeG1wOk1ldGFkYXRhRGF0ZT0iMjAyNC0wMi0yOVQyMToyMjo0NiswODowMCIgZGM6Zm9ybWF0PSJpbWFnZS9wbmciIHBob3Rvc2hvcDpDb2xvck1vZGU9IjMiIHBob3Rvc2hvcDpJQ0NQcm9maWxlPSJzUkdCIElFQzYxOTY2LTIuMSIgeG1wTU06SW5zdGFuY2VJRD0ieG1wLmlpZDo2YWIxZmRmMS02OTRmLTE0NGItODA5ZS04NzEzOTYxMDc3N2IiIHhtcE1NOkRvY3VtZW50SUQ9ImFkb2JlOmRvY2lkOnBob3Rvc2hvcDo2NDRmYjM5Yy0zZTc5LTZmNDktYWRhYS0wMTUyYzRhMjQ5NzUiIHhtcE1NOk9yaWdpbmFsRG9jdW1lbnRJRD0ieG1wLmRpZDo3ZDlkMjczNi1lYTI1LTBjNDUtYThkNy0wMmVlZTMxNjQzMTciPiA8eG1wTU06SGlzdG9yeT4gPHJkZjpTZXE+IDxyZGY6bGkgc3RFdnQ6YWN0aW9uPSJjcmVhdGVkIiBzdEV2dDppbnN0YW5jZUlEPSJ4bXAuaWlkOjdkOWQyNzM2LWVhMjUtMGM0NS1hOGQ3LTAyZWVlMzE2NDMxNyIgc3RFdnQ6d2hlbj0iMjAyNC0wMi0yOVQyMTowMTowNiswODowMCIgc3RFdnQ6c29mdHdhcmVBZ2VudD0iQWRvYmUgUGhvdG9zaG9wIDIyLjAgKFdpbmRvd3MpIi8+IDxyZGY6bGkgc3RFdnQ6YWN0aW9uPSJzYXZlZCIgc3RFdnQ6aW5zdGFuY2VJRD0ieG1wLmlpZDo2YWIxZmRmMS02OTRmLTE0NGItODA5ZS04NzEzOTYxMDc3N2IiIHN0RXZ0OndoZW49IjIwMjQtMDItMjlUMjE6MjI6NDYrMDg6MDAiIHN0RXZ0OnNvZnR3YXJlQWdlbnQ9IkFkb2JlIFBob3Rvc2hvcCAyMi4wIChXaW5kb3dzKSIgc3RFdnQ6Y2hhbmdlZD0iLyIvPiA8L3JkZjpTZXE+IDwveG1wTU06SGlzdG9yeT4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz6SeIasAAAKCUlEQVRo3u2ae3BU9RXHP797dzdvEgKESCQQDAYiiIoC2iBQB9T6mFaU0alWrVVqtVUEpzOt+kdtqa/iOIjtKD4pilpsVXyM2CAqVkRQHuWh8oogJSGPTbKbfdz7O/3j3uzefUSiCDoOO3Nnd/a+zvec8z3ne373+kSE78PHx/fkcxTIUSBHEohSqtcX6DPoOAIFxRz4dB19h9RSWn0yecVl+PIK+XjxnTlZTomNuPBGiYWCtOzYQNvO9RQOrCIe6STW2drjfQKmMKi8gJ0N7QCkF6lvMiIFwARgIjAYGDj26rl9USqAiBIR0dq2dDwWjIXamoADwErg30DHdyW1Ljjjxvm3lg47aaIy/Yi20dpGtEZEI1qjRSNaHE+KIMDguktuPrBt9YrdK56+DXjv2wYyefy19zxv5BbldLa34lMaywa/aSRAiBYHiGhExP1PIwj9ayZMye9fuXTDotvOBjZ8W0DU8Kk/u8XML86Jtzdxw6Qh1A4p47l3t/Lm1hZy/aZjeDoIkcQWD3eQUzygvPrcmQ9vfv6uKUDXNw6kuGI4Zk4ewc+3IaKz8qKofNgJoVCIumGlTK+rBeDXPzqRNdvrCdkGBhotAloAyQQmGivaRUF59bicon6jgDXeG0Ta9nP77NO5Z/4H30xEBo87jz1r30j/22/4/D7RNuGoBWjAoD0cJW67hiIgGkGjtQvC5UriWwSUUmZOfpn34tL++eFJrVMuv521T9yOMv2Je2mtJc9nsHZ3G79/ciUnVfVn2brPCdsmfiO70T1tKJWoqbqtga/QBb4mR0SDMrrruYEIPtPH2ztD1H/Sht80CZgK7RJaRNCSBER3EUikmdsXpDsSDUeO7C5nbKVURCAu4JDbVK73tXscIiKmiDYRT/lN2bobnBBvbcBnqiMCxAQMQJQy4huW3HWZ8vlzEYcRjlcd40BAJNxvxOnXHzP2nOusaBdIN1fS+JLs1Mq1S9zfFolYHTqQcuAK4Ky6WxYOVMownAanxY5FoqK1JL2rExFxy63tyyuqtONRJ6W8VSuNN10RSx6ZO+n+KWfX/FDCcVGGYn9zOPzq8h3vAfOAvYcC5IKJsx6+t6RyZI1t22gr6uS+TjVaa2+fSAWjLQttx53fWoNbjpOgkjw6tqKwtqqm32hCMRCoqillwqTBE86bNmTqZde++lNg49cBMmnCdfc94y8oLoiFO1xjvUZ6vZokcMZx3vRJMd7d58mceFxHidoQtZ1yHtUgNuMnV4z+w+xT77jipvpLAfurAPENn3bVbwNFfQtioWAaOR2vZgPh9XDGpt3mmH6tjDorILZTHbFBa2gOcfmM6unzH9s4CajvFZA+FdUAE8tH1U2Ld3V6+oD2eLYHw3UWnng6OSmRSlMLWkTbWsBOAun+tmwo9qlLzh9yYa+BlI0YD3CmGcgzY+Ggm7/akRluNLRIpn5yPS6e45L7UqOgPSAUCtu2LENHI/375gzAioNYTiSwHU6JDXGhpqpw5Iwb3mHOH3sBJL9/BcDxWtueJiYIOrNsakkB4wBINz5VNOq0ocjwB2jes/Pj4yskd8yJZaOIxEB7Usu9JjGb2urCaqAMaDwokI3P3cfYq+4sk24g6aUyI216kh06qzzBA8T05xILh4INrz02a8m80Tfl9wsU0h5JphUuCO1EpHJQTuXQY/OrewUEKPYXFA/Utp3m1TTDPSmlTBNl+NC2hXLnD0RjaEkMVmgBQ6MSfQ+aGz5dt+vNRbNvuLTPuEtmjLyIjojLC08kSPLEn4+voix3QK84YvgCffz5xcXatjIkd4IvCfIKRk4erQ2fbNmzbuXSzpb9n4nWEQGFq5+cji8p7VkppZQVjg0tOtD+0O+qL73+FyfNxLLAjnui4E0tNzqGYsSwgqJeARHRWuy4Tk2ldE44Zimfn+1vvbAwvPGfD46tzR186g/KR/n8hl/1KCo0iIhpqsComvKRZ00aP6WkorAf7RGXF93cSAORiI4iP9dVrAcDoq14a6S9uTm/bMjQjObliYTy+dn86hN3D2h58+XXX7x40aiTB42mR8EnaUbZYFnQFYNgOHNfelolzlE0fNEV7W1DDMdC7U24qjSlbLqcMEw/zTs2r4/896WnX6y/8oXhJw86jmC0Z9nf3diyGYdLZnQmIDwphoYuzbZdnY29AjLiwl8R7WzZ7zaplM6d6A9KsWv18qfmzBxz0fCxFcfRGulFFNIqUU8GSw/7fcKunZ17P9vdtb1XQEKNDQCbBElZxunWRQLEwyGL9p2bp19wxp+I2NmIRmqH1qmyI8NYL0g3eqSB8SvWbQ6uBxp6BaT50w8BVsZCwTjK9IvYqaUXsK14vCDP8JWU5BZhp0mNjBzvwfBsZPZGLH2/YbBqbXDldRcP7J36DTfvA1jfuGnVG8eMnXaeHe5IEYVJ7oDW6OyplC0SWbiA7hmo2EluBWDfjlDj4lealgL85Suo31jDf/41r7TmtCmmPy/f0hFPxcpcez146njAfGl1ynKuEij0c/cjex8Ctn+deaR+05K5M0f8ZNYDgcLSUqfqOosFhlZ5SikzeUMrOxjtkJQ8Izmwdi80pHwrz9Y93CpnsraEJYv3vfzXZ//3wKFMiH9ft3DOh8WDayfnlJRVIeJ3OGJH4+Fgg1KYDgg7O5AAbFx/YNujz21/xk09RWK2191zPSAU5RsFPhPHOQgoRTiqO1av71izck1wecBvRA91Zt/qbqm5F2rrowz8aBu0laWE2iAKbVsx27KalBIQj8ul2/WCUsL9T+558NafVx44omu/nZtfQynDcGSFlSRuOj+6NGNG9xk9f9wpC1I5YCWPUw531m7q2L38vZZlU08vOTJAghuWpZbaFI2URbnGtDODJypX1JkORaOwwHBWfyzbWQx77d1Wzq0rObxA2rwgAIWtHO9a2cttOnd0BMs3FFUxy9n/xb2Y1nYwAihFQqi9vqqNc+r6Hh4gLR+9lEUo22l9w/5SKSJ2GCk9H1/RGACskh9D459BBYhbqUv+L7/Vwlm9TLNeA2na/G5Wqmza2vzJ4OEFlUSsLIZ7xKK3ANgdnvYTAlMRi9qxppZ4hvRY8koTVcfmHvYHPfYd8zbMnTppwGRfAB8R+yDd2kYZORiti4mJMymawWegbxGP/23vPxr2Rbdku0nDvugRefS24uqb3795wdwxd/UpCxTSaUHc7qF7C2BgEsJsWwC5BhTmseipxhdn37trjlv2vtWHoQumzHhny2+uqfrltAklZx5TmeOouriA5VlsMAzwKTB8RFuN6NvvtH/w7LI9zz66dP/jBXlm+LvywkA9UH/i+auGTKsrnTL5tOK6E6rzastKfHmmgU9At3Xa0R17I3tWrA6uXvF+8K0tO8IfXTN9YOywvTBwKG8MXXkLu4En3C3zqRdwcdp/C4++wnEUyHf383/kqDdaGYVo/AAAAABJRU5ErkJggg=="}, +/***/2721: +/***/function(e,t,n){var r=n(21607) +/** + * 将数值向上舍入 + * + * @param {string|number} num 数值 + * @param {number} digits 小数保留位数 + * @return {number} + */("ceil");e.exports=r +/***/}, +/***/2801: +/***/function(e){e.exports= +/** + * 判断是否为Null + * + * @param {Object} obj 对象 + * @return {Boolean} + */ +function(e){return null===e} +/***/}, +/***/2876: +/***/function(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict"; +/* unused harmony export getRegExp */ +/* harmony import */var _utils_util__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(37741);const getRegExp=function(e){return{number:"/^[-]?\\d+(\\.\\d+)?$/",letter:"/^[A-Za-z]+$/",letterAndNumber:"/^[A-Za-z0-9]+$/",mobilePhone:"/^[1][3-9][0-9]{9}$/",letterStartNumberIncluded:"/^[A-Za-z]+[A-Za-z\\d]*$/",noChinese:"/^[^一-龥]+$/",chinese:"/^[一-龥]+$/",email:"/^([-_A-Za-z0-9.]+)@([_A-Za-z0-9]+\\.)+[A-Za-z0-9]{2,3}$/",url:"/^([hH][tT]{2}[pP]:\\/\\/|[hH][tT]{2}[pP][sS]:\\/\\/)(([A-Za-z0-9-~]+)\\.)+([A-Za-z0-9-~\\/])+$/"}[e]},validateFn=function(validatorName,rule,value,callback,defaultErrorMsg){if((0,_utils_util__WEBPACK_IMPORTED_MODULE_0__.isNull)(value)||value.length<=0)return void callback();const reg=eval(getRegExp(validatorName));if(reg.test(value))callback();else{let e=rule.errorMsg||defaultErrorMsg;callback(new Error(e))}},FormValidators={ +/* 数字 */ +number(e,t,n){validateFn("number",e,t,n,"["+e.label+"]包含非数字字符")}, +/* 字母 */ +letter(e,t,n){validateFn("letter",e,t,n,"["+e.label+"]包含非字母字符")}, +/* 字母和数字 */ +letterAndNumber(e,t,n){validateFn("letterAndNumber",e,t,n,"["+e.label+"]只能输入字母或数字")}, +/* 手机号码 */ +mobilePhone(e,t,n){validateFn("mobilePhone",e,t,n,"["+e.label+"]手机号码格式有误")}, +/* 禁止空白字符开头 */ +noBlankStart(e,t,n){ +//暂未实现 +}, +/* 禁止空白字符结尾 */ +noBlankEnd(e,t,n){ +//暂未实现 +}, +/* 字母开头,仅可包含数字 */ +letterStartNumberIncluded(e,t,n){validateFn("letterStartNumberIncluded",e,t,n,"["+e.label+"]必须以字母开头,可包含数字")}, +/* 禁止中文输入 */ +noChinese(e,t,n){validateFn("noChinese",e,t,n,"["+e.label+"]不可输入中文字符")}, +/* 必须中文输入 */ +chinese(e,t,n){validateFn("chinese",e,t,n,"["+e.label+"]只能输入中文字符")}, +/* 电子邮箱 */ +email(e,t,n){validateFn("email",e,t,n,"["+e.label+"]邮箱格式有误")}, +/* URL网址 */ +url(e,t,n){validateFn("url",e,t,n,"["+e.label+"]URL格式有误")}, +/*测试 + test(rule, value, callback, errorMsg) { + //空值不校验 + if (isNull(value) || (value.length <= 0)) { + callback() + return + } + if (value < 100) { + callback(new Error('[' + rule.label + ']不能小于100')) + } else { + callback() + } + }, + */ +regExp(rule,value,callback){ +//空值不校验 +if((0,_utils_util__WEBPACK_IMPORTED_MODULE_0__.isNull)(value)||value.length<=0)return void callback();const pattern=eval(rule.regExp);if(pattern.test(value))callback();else{let e=rule.errorMsg||"["+rule.label+"]invalid value";callback(new Error(e))}}}; +/* harmony default export */__webpack_exports__.A=FormValidators}, +/***/2950: +/***/function(e,t,n){var r=n(61249),o=n(19042),i=n(69821) +/** + * 检查键、路径是否是该对象的属性 + * + * @param {Object/Array} data 对象 + * @param {String/Function} property 键、路径 + * @return {Boolean} + */;e.exports=function(e,t){if(e){if(i(e,t))return!0;var n,a,l,s,c,u,d=o(t),f=0,h=d.length;for(c=e;f=0||(d.push(e),(0,s.isFunction)(e)&&(e={install:e}),e.install(f))} +/***/}, +/***/3145: +/***/function(e,t,n){"use strict"; +// ESM COMPAT FLAG +n.r(t), +// EXPORTS +n.d(t,{default:function(){/* binding */return h}}); +// EXTERNAL MODULE: ./node_modules/vue/dist/vue.esm-bundler.js + 5 modules +var r=n(61431),o=n(77918),i=n(20163),a=n(37741),l=n(91452),s=n(75220); +// EXTERNAL MODULE: ./node_modules/element-plus/es/components/message-box/index.mjs + 3 modules +// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/views/systemManage/workflowManage/lyWorkflowManage.vue?vue&type=script&setup=true&lang=js +const c={class:"table"},u={style:{display:"flex","justify-content":"space-between","align-items":"center"}},d=["onClick"],f=["onClick"]; +/* harmony default export */var h={__name:"lyWorkflowManage",setup(e,{expose:t}){let n=(0,r.getCurrentInstance)().appContext.config.globalProperties.$Api;// 声明$Api +const h=(0,r.ref)(!0),p=(0,s/* useRoute */.lq)();(0,r.ref)([]);let m=(0,r.ref)({}),g=((0,r.ref)(!1),(0,r.ref)(500)),v=(0,r.ref)(null),A=(0,r.ref)([{label:"流程名称",prop:"name",minWidth:"130"},{label:"版本",prop:"version",width:"90"},{label:"状态",prop:"status",width:"100"},{label:"创建时间",prop:"create_datetime",minWidth:"180"}]),y=(0,r.ref)(!1),b=(0,r.ref)(null);function O(){y.value=!0,(0,r.nextTick)((()=>{b.value.handleOpen(null,"新建流程")}))}function w(e,t){"edit"==t?(y.value=!0,(0,r.nextTick)((()=>{b.value.handleOpen(e,"编辑流程")}))):"delete"==t?o/* ElMessageBox */.s.confirm("您确定要删除选中的数据吗?","警告",{closeOnClickModal:!1,type:"warning"}).then((t=>{n.lyworkflowDelete({id:e.id}).then((e=>{2e3==e.code?(i/* ElMessage */.nk.success(e.msg),k()):i/* ElMessage */.nk.warning(e.msg)}))})).catch((()=>{})):"reset"==t&&(m.value={},k())} +// 计算搜索栏的高度 +function x(){(0,r.nextTick)((()=>{_()}))}function _(){let e=v.value?v.value.offsetHeight:0;e=V.value?e-110:e,g.value=(0,a.getTableHeight)(e,!1)-125}let C=(0,r.ref)(null);function k(){C.value.reload(m.value)} +//获取列表 +async function S(){C.value.getData()}let V=(0,r.ref)(!1);function B(){V.value=!V.value,window.dispatchEvent(new Event("resize"))}return t({setFull:B}),(0,r.onMounted)((()=>{ +// 监听页面宽度变化搜索框的高度 +window.addEventListener("resize",x),(0,r.nextTick)((()=>{_()})),setTimeout((()=>{h.value=!1}),100)}// 适当调整延迟时间,以确保初始化完成后再取消标志位 +)),(0,r.onUnmounted)((()=>{ +// 页面销毁,去掉监听事件 +window.removeEventListener("resize",x)})),(e,t)=>{const a=(0,r.resolveComponent)("el-input"),s=(0,r.resolveComponent)("el-form-item"),x=(0,r.resolveComponent)("el-button"),_=(0,r.resolveComponent)("el-form"),T=(0,r.resolveComponent)("el-tag"),N=(0,r.resolveComponent)("el-switch"),E=(0,r.resolveComponent)("full-screen"),P=(0,r.resolveComponent)("el-icon"),Q=(0,r.resolveComponent)("el-tooltip"),M=(0,r.resolveComponent)("el-table-column"),D=(0,r.resolveComponent)("ly-table");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:(0,r.normalizeClass)({"ly-is-full":(0,r.unref)(V)})},[(0,r.createElementVNode)("div",{class:"tableSelect",ref_key:"tableSelect",ref:v},[(0,r.createVNode)(_,{inline:!0,model:(0,r.unref)(m),"label-position":"left"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(s,{label:"流程名称:"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(a,{modelValue:(0,r.unref)(m).name,"onUpdate:modelValue":t[0]||(t[0]=e=>(0,r.unref)(m).name=e),modelModifiers:{trim:!0},maxlength:"60",clearable:"",placeholder:"流程名称",onChange:k,style:{width:"160px"}},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(s,{label:""},{default:(0,r.withCtx)((()=>[(0,r.withDirectives)((0,r.createVNode)(x,{onClick:k,type:"primary",icon:"Search"},{default:(0,r.withCtx)((()=>t[3]||(t[3]=[(0,r.createTextVNode)("查询")]))),_:1},512),[[r.vShow,e.hasPermission((0,r.unref)(p).name,"Search")]])])),_:1}),(0,r.createVNode)(s,{label:""},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(x,{onClick:t[1]||(t[1]=e=>w("","reset")),icon:"Refresh"},{default:(0,r.withCtx)((()=>t[4]||(t[4]=[(0,r.createTextVNode)("重置")]))),_:1})])),_:1}),(0,r.createVNode)(s,{label:""},{default:(0,r.withCtx)((()=>[(0,r.withDirectives)((0,r.createVNode)(x,{onClick:O,type:"primary",icon:"Plus"},{default:(0,r.withCtx)((()=>t[5]||(t[5]=[(0,r.createTextVNode)("新建流程")]))),_:1},512),[[r.vShow,e.hasPermission((0,r.unref)(p).name,"Create")]])])),_:1})])),_:1},8,["model"])],512),(0,r.createElementVNode)("div",c,[(0,r.createVNode)(D,{tableName:"lyWorkflowManageTable",height:(0,r.unref)(g),pageSize:10,apiObj:e.$Api.lyworkflow,params:(0,r.unref)(m),ref_key:"tableref",ref:C,column:(0,r.unref)(A),showSequence:""},{version:(0,r.withCtx)((e=>[(0,r.createVNode)(T,null,{default:(0,r.withCtx)((()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.row.version),1)])),_:2},1024)])),status:(0,r.withCtx)((e=>[(0,r.createVNode)(N,{modelValue:e.row.status,"onUpdate:modelValue":t=>e.row.status=t,"active-value":1,"inactive-value":0,style:{"--el-switch-on-color":"#13ce66","--el-switch-off-color":"#ff4949"},onChange:t=>function(e){ +//避免:active-value="1" :inactive-value="0"在初始化时触发 change 事件 +if(h.value)return;let t=e.status;e.status=1==e.status?e.status=0:e.status=1,o/* ElMessageBox */.s.confirm("确定修改状态吗?","提醒",{closeOnClickModal:!1,type:"warning"}).then((r=>{n.lyworkflowOpstatus({id:e.id}).then((n=>{2e3==n.code?(e.status=1==t?0:1,i/* ElMessage */.nk.success(n.msg),S()):i/* ElMessage */.nk.warning(n.msg)}))})).catch((()=>{}))}(e.row)},null,8,["modelValue","onUpdate:modelValue","onChange"])])),default:(0,r.withCtx)((()=>[(0,r.createVNode)(M,{label:"操作",fixed:"right",width:"180"},{header:(0,r.withCtx)((()=>[(0,r.createElementVNode)("div",u,[t[6]||(t[6]=(0,r.createElementVNode)("div",null,"操作",-1)),(0,r.createElementVNode)("div",{onClick:B},[(0,r.createVNode)(Q,{content:"全屏",placement:"bottom"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(P,null,{default:(0,r.withCtx)((()=>[(0,r.createVNode)(E)])),_:1})])),_:1})])])])),default:(0,r.withCtx)((t=>[(0,r.withDirectives)((0,r.createElementVNode)("span",{class:"table-operate-btn",onClick:e=>w(t.row,"edit")},"编辑",8,d),[[r.vShow,e.hasPermission((0,r.unref)(p).name,"Update")]]),(0,r.withDirectives)((0,r.createElementVNode)("span",{class:"table-operate-btn",onClick:e=>w(t.row,"delete")},"删除",8,f),[[r.vShow,e.hasPermission((0,r.unref)(p).name,"Delete")]])])),_:1})])),_:1},8,["height","apiObj","params","column"])]),(0,r.unref)(y)?((0,r.openBlock)(),(0,r.createBlock)(l.default,{key:0,ref_key:"moduleWorkflowFlag",ref:b,onRefreshData:S,onClosed:t[2]||(t[2]=e=>(0,r.isRef)(y)?y.value=!1:y=!1)},null,512)):(0,r.createCommentVNode)("",!0)],2)}}}; +/***/}, +/***/3238: +/***/function(e,t,n){"use strict";var r=n(44576),o=n(77811),i=n(67394),a=r.DataView;e.exports=function(e){if(!o||0!==i(e))return!1;try{ +// eslint-disable-next-line no-new -- thrower +return new a(e),!1}catch(e){return!0}}}, +/***/3293: +/***/function(e){var t=Object.prototype.toString;e.exports=t +/***/}, +/***/3354: +/***/function(e,t,n){var r=n(13908) +/** + * 接收一个函数作为累加器,数组中的每个值(从左到右)开始合并,最终为一个值。 + * + * @param {Array} array 数组 + * @param {Function} callback 方法 + * @param {Object} initialValue 初始值 + * @return {Number} + */;e.exports=function(e,t,n){if(e){var o,i,a=0,l=n,s=arguments.length>2,c=r(e);if(e.length&&e.reduce)return i=function(){return t.apply(null,arguments)},s?e.reduce(i,l):e.reduce(i);for(s&&(a=1,l=e[c[0]]),o=c.length;a-1){var n=(0,o.parse)(e);n&&(e="rgb("+n[0]+","+n[1]+","+n[2]+")",t=n[3])}}else e="none";return{color:e,opacity:null==t?1:t}}var s=1e-4;function c(e){return e-s}function u(e){return a(1e3*e)/1e3}function d(e){return a(1e4*e)/1e4}function f(e){return"matrix("+u(e[0])+","+u(e[1])+","+u(e[2])+","+u(e[3])+","+d(e[4])+","+d(e[5])+")"}var h={left:"start",right:"end",center:"middle",middle:"middle"};function p(e,t,n){return"top"===n?e+=t/2:"bottom"===n&&(e-=t/2),e}function m(e){return e&&(e.shadowBlur||e.shadowOffsetX||e.shadowOffsetY)}function g(e){var t=e.style,n=e.getGlobalScale();return[t.shadowColor,(t.shadowBlur||0).toFixed(2),(t.shadowOffsetX||0).toFixed(2),(t.shadowOffsetY||0).toFixed(2),n[0],n[1]].join(",")}function v(e){return e&&!!e.image}function A(e){return v(e)||function(e){return e&&!!e.svgElement}(e)}function y(e){return"linear"===e.type}function b(e){return"radial"===e.type}function O(e){return e&&("linear"===e.type||"radial"===e.type)}function w(e){return"url(#"+e+")"}function x(e){var t=e.getGlobalScale(),n=Math.max(t[0],t[1]);return Math.max(Math.ceil(Math.log(n)/Math.log(10)),1)}function _(e){var t=e.x||0,n=e.y||0,o=(e.rotation||0)*r.RADIAN_TO_DEGREE,i=(0,r.retrieve2)(e.scaleX,1),l=(0,r.retrieve2)(e.scaleY,1),s=e.skewX||0,c=e.skewY||0,u=[];return(t||n)&&u.push("translate("+t+"px,"+n+"px)"),o&&u.push("rotate("+o+")"),1===i&&1===l||u.push("scale("+i+","+l+")"),(s||c)&&u.push("skew("+a(s*r.RADIAN_TO_DEGREE)+"deg, "+a(c*r.RADIAN_TO_DEGREE)+"deg)"),u.join(" ")}var C=i/* ["default"] */.A.hasGlobalWindow&&(0,r.isFunction)(window.btoa)?function(e){return window.btoa(unescape(encodeURIComponent(e)))}:"undefined"!=typeof Buffer?function(e){return Buffer.from(e).toString("base64")}:function(e){return null}; +/***/}, +/***/3486: +/***/function(e,t,n){"use strict"; +/* harmony export */n.d(t,{ +/* harmony export */m:function(){/* binding */return s} +/* harmony export */}); +/* harmony import */var r=n(24326),o=n(74562),i=n(50626),a=n(67071),l=Math.log; +/* harmony import */function s(e,t,n){var s=o/* ["default"] */.A.prototype,c=s.getTicks.call(n),u=s.getTicks.call(n,!0),d=c.length-1,f=s.getInterval.call(n),h=(0,i/* .getScaleExtent */.Rx)(e,t),p=h.extent,m=h.fixMin,g=h.fixMax; +// NOTE: There is a precondition for log scale here: +// In log scale we store _interval and _extent of exponent value. +// So if we use the method of InternalScale to set/get these data. +// It process the exponent value, which is linear and what we want here. +if("log"===e.type){var v=l(e.base);p=[l(p[0])/v,l(p[1])/v]}e.setExtent(p[0],p[1]),e.calcNiceExtent({splitNumber:d,fixMin:m,fixMax:g});var A=s.getExtent.call(e); +// Need to update the rawExtent. +// Because value in rawExtent may be not parsed. e.g. 'dataMin', 'dataMax' +m&&(p[0]=A[0]),g&&(p[1]=A[1]);var y=s.getInterval.call(e),b=p[0],O=p[1];if(m&&g) +// User set min, max, divide to get new interval +y=(O-b)/d;else if(m) +// User set min, expand extent on the other side +for(O=p[0]+y*d;Op[0]&&isFinite(b)&&isFinite(p[0]);)y=(0,a/* .increaseInterval */.kH)(y),b=p[1]-y*d;else{e.getTicks().length-1>d&&(y=(0,a/* .increaseInterval */.kH)(y));var w=y*d;O=Math.ceil(p[1]/y)*y, +// Not change the result that crossing zero. +(b=(0,r/* .round */.LI)(O-w))<0&&p[0]>=0?(b=0,O=(0,r/* .round */.LI)(w)):O>0&&p[1]<=0&&(O=0,b=-(0,r/* .round */.LI)(w))} +// Adjust min, max based on the extent of alignTo. When min or max is set in alignTo scale +var x=(c[0].value-u[0].value)/f,_=(c[d].value-u[d].value)/f; +// NOTE: Must in setExtent -> setInterval -> setNiceExtent order. +s.setExtent.call(e,b+y*x,O+y*_),s.setInterval.call(e,y),(x||_)&&s.setNiceExtent.call(e,b+y,O-y)} +/***/}, +/***/3609: +/***/function(e,t,n){"use strict";n.r(t); +/* harmony import */var r=n(12897),o=n.n(r),i=n(55042),a=n.n(i),l=new(o())({id:"icon-button",use:"icon-button-usage",viewBox:"0 0 1024 1024",content:''}); +/* harmony import */a().add(l); +/* harmony default export */t.default=l}, +/***/3686: +/***/function(e,t,n){"use strict"; +/* harmony export */n.d(t,{ +/* harmony export */DA:function(){/* binding */return m}, +/* harmony export */MU:function(){/* binding */return g}, +/* harmony export */T8:function(){/* binding */return f}, +/* harmony export */Tc:function(){/* binding */return p}, +/* harmony export */_F:function(){/* binding */return h}, +/* harmony export */bY:function(){/* binding */return d}, +/* harmony export */cU:function(){/* binding */return v}, +/* harmony export */u7:function(){/* binding */return A} +/* harmony export */}); +/* harmony import */var r=n(98026),o=n(43199),i=n(45558),a=n(83412),l=n(45587),s=n(50626),c=n(89598),u=n(89632); +/* harmony import */ +/* +* Licensed to the Apache Software Foundation (ASF) under one +* or more contributor license agreements. See the NOTICE file +* distributed with this work for additional information +* regarding copyright ownership. The ASF licenses this file +* to you under the Apache License, Version 2.0 (the +* "License"); you may not use this file except in compliance +* with the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, +* software distributed under the License is distributed on an +* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +* KIND, either express or implied. See the License for the +* specific language governing permissions and limitations +* under the License. +*/ +/** + * AUTO-GENERATED FILE. DO NOT MODIFY. + */ +/* +* Licensed to the Apache Software Foundation (ASF) under one +* or more contributor license agreements. See the NOTICE file +* distributed with this work for additional information +* regarding copyright ownership. The ASF licenses this file +* to you under the Apache License, Version 2.0 (the +* "License"); you may not use this file except in compliance +* with the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, +* software distributed under the License is distributed on an +* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +* KIND, either express or implied. See the License for the +* specific language governing permissions and limitations +* under the License. +*/ +function d(e){var t,n=e.get("type"),r=e.getModel(n+"Style");return"line"===n?(t=r.getLineStyle()).fill=null:"shadow"===n&&((t=r.getAreaStyle()).stroke=null),t} +/** + * @param {Function} labelPos {align, verticalAlign, position} + */function f(e,t,n,r,o){var l=h(n.get("value"),t.axis,t.ecModel,n.get("seriesDataIndices"),{precision:n.get(["label","precision"]),formatter:n.get(["label","formatter"])}),s=n.getModel("label"),c=a/* .normalizeCssArray */.QX(s.get("padding")||0),d=s.getFont(),f=i/* .getBoundingRect */.NO(l,d),p=o.position,m=f.width+c[1]+c[3],g=f.height+c[0]+c[2],v=o.align;"right"===v&&(p[0]-=m),"center"===v&&(p[0]-=m/2);var A=o.verticalAlign;"bottom"===A&&(p[1]-=g),"middle"===A&&(p[1]-=g/2), +// Not overflow ec container +// Do not overflow ec container +function(e,t,n,r){var o=r.getWidth(),i=r.getHeight();e[0]=Math.min(e[0]+t,o)-t,e[1]=Math.min(e[1]+n,i)-n,e[0]=Math.max(e[0],0),e[1]=Math.max(e[1],0)}(p,m,g,r);var y=s.get("backgroundColor");y&&"auto"!==y||(y=t.get(["axisLine","lineStyle","color"])),e.label={ +// shape: {x: 0, y: 0, width: width, height: height, r: labelModel.get('borderRadius')}, +x:p[0],y:p[1],style:(0,u/* .createTextStyle */.VB)(s,{text:l,font:d,fill:s.getTextColor(),padding:c,backgroundColor:y}), +// Label should be over axisPointer. +z2:10}}function h(e,t,n,o,i){e=t.scale.parse(e);var a=t.scale.getLabel({value:e},{ +// If `precision` is set, width can be fixed (like '12.00500'), which +// helps to debounce when when moving label. +precision:i.precision}),l=i.formatter;if(l){var c={value:s/* .getAxisRawValue */.Dt(t,{value:e}),axisDimension:t.dim,axisIndex:t.index,seriesData:[]};r.each(o,(function(e){var t=n.getSeriesByIndex(e.seriesIndex),r=e.dataIndexInside,o=t&&t.getDataParams(r);o&&c.seriesData.push(o)})),r.isString(l)?a=l.replace("{value}",a):r.isFunction(l)&&(a=l(c))}return a}function p(e,t,n){var r=l.create();return l.rotate(r,r,n.rotation),l.translate(r,r,n.position),o.applyTransform([e.dataToCoord(t),(n.labelOffset||0)+(n.labelDirection||1)*(n.labelMargin||0)],r)}function m(e,t,n,r,o,i){ +// @ts-ignore +var a=c/* ["default"] */.A.innerTextLayout(n.rotation,0,n.labelDirection);n.labelMargin=o.get(["label","margin"]),f(t,r,o,i,{position:p(r.axis,e,n),align:a.textAlign,verticalAlign:a.textVerticalAlign})}function g(e,t,n){return{x1:e[n=n||0],y1:e[1-n],x2:t[n],y2:t[1-n]}}function v(e,t,n){return{x:e[n=n||0],y:e[1-n],width:t[n],height:t[1-n]}}function A(e,t,n,r,o,i){return{cx:e,cy:t,r0:n,r:r,startAngle:o,endAngle:i,clockwise:!0}} +/***/}, +/***/3753: +/***/function(e,t,n){ +// Exports the "textpattern" plugin for usage with module loaders +// Usage: +// CommonJS: +// require('tinymce/plugins/textpattern') +// ES2015: +// import 'tinymce/plugins/textpattern' +n(22454); +/***/}, +/***/3805: +/***/function(e,t,n){"use strict";e.exports=n.p+"static/img/avatar02.c1aa8008.jpg"}, +/***/3939: +/***/function(e,t,n){"use strict"; +// ESM COMPAT FLAG +n.r(t), +// EXPORTS +n.d(t,{default:function(){/* binding */return v}}); +// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.push.js +n(44114),n(18111),n(22489); +// EXTERNAL MODULE: ./node_modules/core-js/modules/es.iterator.constructor.js +var r=n(61431),o=n(7277),i=n(48404),a=n(20163),l=n(37741);// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/views/systemManage/files/components/moduleUpload.vue?vue&type=script&setup=true&lang=js +const s={key:1,class:"handle-button"},c={class:"handle-drag"},u={key:0},d={key:1},f={key:1,style:{color:"green"}},h={key:2,style:{color:"red"}},p={key:0},m={class:"uploadfooterbt"}; +/* harmony default export */var g={__name:"moduleUpload",emits:["refreshData","closed"],setup(e,{expose:t,emit:n}){const g=n;let v=(0,r.ref)(!1),A=(0,r.ref)(!1),y=(0,r.ref)(""),b=(0,r.ref)(""),O=(0,r.ref)([]),w=(0,r.ref)(""),x=(0,r.ref)(0),_=(0,r.ref)(null),C=(0,r.ref)("file"),k=(0,r.ref)(null),S=(0,r.ref)(null),V=(0,r.ref)(!1),B=(0,r.ref)(0),T=(0,r.ref)("");function N(){g("refreshData"),g("closed")}function E(){V.value=!1,O.value=[],B.value=0,T.value="",Q()}function P(e){C.value=e,k.value.webkitdirectory="file"!=e,_.value.$el.querySelector("input").click()}function Q(){_.value.clearFiles()}function M(e){e.preventDefault()}function D(e){e.preventDefault();const t=e.dataTransfer.items;if(t)for(let e=0;e{O.value.push(function(e,t){const n=Date.now(),r=new File([e],e.name,{type:e.type,lastModified:e.lastModified});r.uid=n;let o=e.name;""!=t&&(o=t+e.name);return{name:o,size:e.size,status:"ready",uid:n,raw:r}}(e,t))}));else if(e.isDirectory){e.createReader().readEntries((n=>{for(let r=0;rt.name===e.name));if(n!=t.findLastIndex((t=>t.name===e.name))&&e.raw.webkitRelativePath==t[n].raw.webkitRelativePath&&(a/* ElMessage */.nk.error(e.name+" 文件已存在"),t.pop()),64==e.size||0==e.size){O.value=t;const n=new FileReader;n.readAsDataURL(e.raw),n.onload=async()=>{},n.onerror=()=>{O.value=O.value.filter((t=>t.uid!==e.uid)),a/* ElMessage */.nk.error({message:`【${e.name}】文件类型错误或为空文件夹`,type:"error",showClose:!0,duration:3e3})}}else O.value=t;!async function(){(0,r.nextTick)((()=>{ +// let tableBodyHeight = tableContainer.value.scrollBarRef.wrapRef.offsetHeight +// tableContainer.value.scrollBarRef.setScrollTop(tableBodyHeight) +// let tableBodyHeight = tableContainer.value.scrollBarRef.wrapRef.offsetHeight +// tableContainer.value.scrollBarRef.setScrollTop(tableBodyHeight) +(0,r.nextTick)((()=>{S.value.setScrollTop(38*O.value.length)}))}))}()}function I(e){_.value.clearFiles();for(let t=0;t{S.value.setScrollTop(38*e)}))}function H(e){return e?e.split("/").slice(0,-1).join("/"):e}function W(e){let t=0;for(let e=0;e{ +// uploadPrecent.value = Math.round((progress.loaded / progress.total) * 100); +O.value[n].percentage=Math.round(e.loaded/e.total*100)})).then((e=>{ +// 文件上传成功处理 +2e3===e.code?(F.value++,O.value[n].status="success"):(F.value++,O.value[n].status=e.msg)})).catch((e=>{ +// 处理错误 +// 处理错误 +(0,a/* ElMessage */.nk)({message:e,grouping:!0,type:"warning"}),F.value++,O.value[n].status=e}))}else{ +// const chunkSize = 1024 * 1024 * 5; +const e=5242880,t=Math.ceil(i/e);let l=0;x.value=0;for(let s=0;s{ +// uploadPrecent.value = Math.round( +// ((uploadedChunkCount + progress.loaded / progress.total) * 100) / chunkCount, +// ); +O.value[n].percentage=Math.round(100*(l+e.loaded/e.total)/t)})).then((e=>{ +// 文件上传成功处理 +2e3===e.code?h=!0:(O.value[n].status=e.msg,h=!1)})).catch((e=>{ +// 处理错误 +// 处理错误 +(0,a/* ElMessage */.nk)({message:e,grouping:!0,type:"warning"}),O.value[n].status=e,h=!1})),!h)break;if(l++,l==t){F.value++,O.value[n].status="success";break}}}if(n==t.length-1&&(A.value=!1,w.value="",V.value=!0,F.value==t.length)){const t=(new Date-e)/1e3;// 转换为秒 +B.value=t.toFixed(2),T.value=W(B.value)} +// starttop= starttop+40 +// await scrollTop(starttop) +await U(n+1)}A.value=!1}return t({handleOpen:function(e,t){y.value=t,v.value=!0;let n=(0,l.deepClone)(e);b.value=n.path,(0,r.nextTick)((()=>{k.value=document.querySelector(".el-upload__input")}))}}),(e,t)=>{const n=(0,r.resolveComponent)("el-alert"),o=(0,r.resolveComponent)("el-button"),a=(0,r.resolveComponent)("upload-filled"),g=(0,r.resolveComponent)("el-icon"),b=(0,r.resolveComponent)("el-text"),x=(0,r.resolveComponent)("el-upload"),C=(0,r.resolveComponent)("el-table-column"),k=(0,r.resolveComponent)("el-progress"),z=(0,r.resolveComponent)("el-table");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[(0/* default */,r.createVNode)(i.A,{modelValue:(0,r.unref)(v),"onUpdate:modelValue":t[4]||(t[4]=e=>(0,r.isRef)(v)?v.value=e:v=e),title:(0,r.unref)(y),width:"690px","before-close":N},{footer:(0,r.withCtx)((()=>[(0,r.createElementVNode)("div",m,[(0,r.createElementVNode)("div",null,"共"+(0,r.toDisplayString)((0,r.unref)(O).length)+"个",1),(0,r.createElementVNode)("div",null,[(0,r.createVNode)(o,{onClick:N,loading:(0,r.unref)(A)},{default:(0,r.withCtx)((()=>t[9]||(t[9]=[(0,r.createTextVNode)("关闭")]))),_:1},8,["loading"]),(0,r.unref)(V)?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createBlock)(o,{key:0,type:"primary",onClick:j,loading:(0,r.unref)(A),disabled:(0,r.unref)(O).length<1},{default:(0,r.withCtx)((()=>t[10]||(t[10]=[(0,r.createTextVNode)("确认上传")]))),_:1},8,["loading","disabled"]))])])])),default:(0,r.withCtx)((()=>[(0,r.unref)(V)?((0,r.openBlock)(),(0,r.createBlock)(n,{key:0,style:{"margin-bottom":"10px"},title:"上传成功"+(0,r.unref)(F)+"个,耗时"+(0,r.unref)(B)+"秒,平均速度"+(0,r.unref)(T),type:"success",onClick:E},null,8,["title"])):(0,r.createCommentVNode)("",!0),(0,r.unref)(V)?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createElementBlock)("div",s,[(0,r.createElementVNode)("div",null,[(0,r.createVNode)(o,{type:"primary",onClick:t[0]||(t[0]=e=>P("file"))},{default:(0,r.withCtx)((()=>t[5]||(t[5]=[(0,r.createTextVNode)("上传文件")]))),_:1}),(0,r.createVNode)(o,{type:"primary",onClick:t[1]||(t[1]=e=>P("dir"))},{default:(0,r.withCtx)((()=>t[6]||(t[6]=[(0,r.createTextVNode)("上传目录")]))),_:1})]),(0,r.createElementVNode)("div",null,[(0,r.createVNode)(o,{onClick:Q},{default:(0,r.withCtx)((()=>t[7]||(t[7]=[(0,r.createTextVNode)("清空列表")]))),_:1})])])),(0,r.createElementVNode)("div",null,[(0,r.createElementVNode)("div",{class:"el-upload-dragger",onDragover:M,onDrop:D,onDragleave:$},[(0,r.createElementVNode)("div",c,[(0,r.createElementVNode)("div",null,[(0,r.createVNode)(g,{class:"el-icon--upload"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(a)])),_:1}),t[8]||(t[8]=(0,r.createElementVNode)("div",{class:"el-upload__text"}," 请拖拽需要上传的文件/目录到此处 ",-1))])])],32)]),(0,r.createVNode)(x,{ref_key:"lyUploadRef",ref:_,"show-file-list":!1,multiple:"","file-list":(0,r.unref)(O),"onUpdate:fileList":t[2]||(t[2]=e=>(0,r.isRef)(O)?O.value=e:O=e),action:"#","auto-upload":!1,"on-change":R,"on-exceed":I,"on-success":L},{tip:(0,r.withCtx)((()=>[(0,r.createVNode)(b,null,{default:(0,r.withCtx)((()=>[(0,r.createTextVNode)((0,r.toDisplayString)((0,r.unref)(w)),1)])),_:1})])),_:1},8,["file-list"]),(0,r.createVNode)(z,{ref_key:"tableContainer",ref:S,data:(0,r.unref)(O),"table-layout":"auto","max-height":"300px","scrollbar-always-on":!0},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(C,{prop:"name","min-width":"200",label:"文件名","show-overflow-tooltip":""},{default:(0,r.withCtx)((e=>[""!=e.row.raw.webkitRelativePath?((0,r.openBlock)(),(0,r.createElementBlock)("span",u,(0,r.toDisplayString)(e.row.raw.webkitRelativePath),1)):((0,r.openBlock)(),(0,r.createElementBlock)("span",d,(0,r.toDisplayString)(e.row.name),1))])),_:1}),(0,r.createVNode)(C,{prop:"size","min-width":"100",label:"大小","show-overflow-tooltip":""},{default:(0,r.withCtx)((e=>[(0,r.createTextVNode)((0,r.toDisplayString)((0,r.unref)(l.formatUnitSize)(e.row.size)),1)])),_:1}),(0,r.createVNode)(C,{prop:"status","min-width":"90",label:"状态","show-overflow-tooltip":""},{default:(0,r.withCtx)((e=>["ready"==e.row.status?((0,r.openBlock)(),(0,r.createBlock)(k,{key:0,duration:0,"text-inside":"","stroke-width":15,percentage:e.row.percentage},null,8,["percentage"])):"success"==e.row.status?((0,r.openBlock)(),(0,r.createElementBlock)("span",f,"上传成功")):((0,r.openBlock)(),(0,r.createElementBlock)("span",h,(0,r.toDisplayString)(e.row.status),1))])),_:1}),(0,r.createVNode)(C,{width:"45",fixed:"right"},{default:(0,r.withCtx)((n=>["success"==n.row.status||(0,r.unref)(A)?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createElementBlock)("span",p,[(0,r.createVNode)(o,{type:"primary",link:"",onClick:t[3]||(t[3]=t=>{return n=e.index,void O.value.splice(n,1);var n}),icon:"Close"})]))])),_:1})])),_:1},8,["data"])])),_:1},8,["modelValue","title"])])}}}; +/* harmony default export */var v=(0,n(66262).A)(g,[["__scopeId","data-v-0058dea6"]]); +/***/}, +/***/3961: +/***/function(e,t,n){"use strict"; +/* harmony export */n.d(t,{ +/* harmony export */CO:function(){/* binding */return x}, +/* harmony export */Qx:function(){/* binding */return h}, +/* harmony export */Yu:function(){/* binding */return y}, +/* harmony export */aw:function(){/* binding */return w}, +/* harmony export */lb:function(){/* binding */return _} +/* harmony export */}); +/* harmony import */var r=n(44265),o=n(83412),i=n(98026),a=n(31825),l=n(24326),s="line-height:1"; +/* harmony import */function c(e){var t=e.lineHeight;return null==t?s:"line-height:"+(0,r/* .encodeHTML */.Me)(t+"")+"px"} +// TODO: more textStyle option +function u(e,t){var n=e.color||"#6e7079",o=e.fontSize||12,i=e.fontWeight||"400",a=e.color||"#464646",l=e.fontSize||14,s=e.fontWeight||"900";return"html"===t?{ +// eslint-disable-next-line max-len +nameStyle:"font-size:"+(0,r/* .encodeHTML */.Me)(o+"")+"px;color:"+(0,r/* .encodeHTML */.Me)(n)+";font-weight:"+(0,r/* .encodeHTML */.Me)(i+""), +// eslint-disable-next-line max-len +valueStyle:"font-size:"+(0,r/* .encodeHTML */.Me)(l+"")+"px;color:"+(0,r/* .encodeHTML */.Me)(a)+";font-weight:"+(0,r/* .encodeHTML */.Me)(s+"")}:{nameStyle:{fontSize:o,fill:n,fontWeight:i},valueStyle:{fontSize:l,fill:a,fontWeight:s}}} +// See `TooltipMarkupLayoutIntent['innerGapLevel']`. +// (value from UI design) +var d=[0,10,20,30],f=["","\n","\n\n","\n\n\n"]; +// eslint-disable-next-line max-len +function h(e,t){return t.type=e,t}function p(e){return"section"===e.type}function m(e){return p(e)?v:A}function g(e){if(p(e)){var t=0,n=e.blocks.length,r=n>1||n>0&&!e.noHeader;return(0,i.each)(e.blocks,(function(e){var n=g(e); +// If the some of the sub-blocks have some gaps (like 10px) inside, this block +// should use a larger gap (like 20px) to distinguish those sub-blocks. +n>=t&&(t=n+ +(r&&( +// 0 always can not be readable gap level. +!n||p(e)&&!e.noHeader)))})),t}return 0}function v(e,t,n,l){var s,h=t.noHeader,p=(s=g(t),{html:d[s],richText:f[s]}),v=[],A=t.blocks||[];(0,i.assert)(!A||(0,i.isArray)(A)),A=A||[];var y=e.orderMode;if(t.sortBlocks&&y){A=A.slice();var w={valueAsc:"asc",valueDesc:"desc"};if((0,i.hasOwn)(w,y)){var x=new a/* .SortOrderComparator */.Fl(w[y],null);A.sort((function(e,t){return x.evaluate(e.sortParam,t.sortParam)}))} +// FIXME 'seriesDesc' necessary? +else"seriesDesc"===y&&A.reverse()}(0,i.each)(A,(function(n,r){var o=t.valueFormatter,a=m(n)( +// Inherit valueFormatter +o?(0,i.extend)((0,i.extend)({},e),{valueFormatter:o}):e,n,r>0?p.html:0,l);null!=a&&v.push(a)}));var _="richText"===e.renderMode?v.join(p.richText):b(l,v.join(""),h?n:p.html);if(h)return _;var C=(0,o/* .makeValueReadable */.yC)(t.header,"ordinal",e.useUTC),k=u(l,e.renderMode).nameStyle,S=c(l);return"richText"===e.renderMode?O(e,C,k)+p.richText+_:b(l,'
'+(0,r/* .encodeHTML */.Me)(C)+"
"+_,n)}function A(e,t,n,a){var l=e.renderMode,s=t.noName,c=t.noValue,d=!t.markerType,f=t.name,h=e.useUTC,p=t.valueFormatter||e.valueFormatter||function(e){return e=(0,i.isArray)(e)?e:[e],(0,i.map)(e,(function(e,t){return(0,o/* .makeValueReadable */.yC)(e,(0,i.isArray)(v)?v[t]:v,h)}))};if(!s||!c){var m=d?"":e.markupStyleCreator.makeTooltipMarker(t.markerType,t.markerColor||"#333",l),g=s?"":(0,o/* .makeValueReadable */.yC)(f,"ordinal",h),v=t.valueType,A=c?[]:p(t.value,t.dataIndex),y=!d||!s,w=!d&&s,x=u(a,l),_=x.nameStyle,C=x.valueStyle;return"richText"===l?(d?"":m)+(s?"":O(e,g,_))+(c?"":function(e,t,n,r,o){var a=[o],l=r?10:20; +// Value has commas inside, so use ' ' as delimiter for multiple values. +return n&&a.push({padding:[0,0,0,l],align:"right"}),e.markupStyleCreator.wrapRichTextStyle((0,i.isArray)(t)?t.join(" "):t,a)}(e,A,y,w,C)):b(a,(d?"":m)+(s?"":function(e,t,n){return''+(0,r/* .encodeHTML */.Me)(e)+""}(g,!d,_))+(c?"":function(e,t,n,o){ +// Do not too close to marker, considering there are multiple values separated by spaces. +var a=n?"10px":"20px",l=t?"float:right;margin-left:"+a:"";return e=(0,i.isArray)(e)?e:[e],''+(0,i.map)(e,(function(e){return(0,r/* .encodeHTML */.Me)(e)})).join("  ")+""}(A,y,w,C)),n)}} +/** + * @return markupText. null/undefined means no content. + */function y(e,t,n,r,o,i){if(e)return m(e)({useUTC:o,renderMode:n,orderMode:r,markupStyleCreator:t,valueFormatter:e.valueFormatter},e,0,i)}function b(e,t,n){return'
'+t+'
'}function O(e,t,n){return e.markupStyleCreator.wrapRichTextStyle(t,n)}function w(e,t){var n=e.getData().getItemVisual(t,"style")[e.visualDrawType];return(0,o/* .convertToColorString */.he)(n)}function x(e,t){var n=e.get("padding");return null!=n?n:"richText"===t?[8,10]:10} +/** + * The major feature is generate styles for `renderMode: 'richText'`. + * But it also serves `renderMode: 'html'` to provide + * "renderMode-independent" API. + */var _=/** @class */function(){function e(){this.richTextStyles={}, +// Notice that "generate a style name" usually happens repeatedly when mouse is moving and +// a tooltip is displayed. So we put the `_nextStyleNameId` as a member of each creator +// rather than static shared by all creators (which will cause it increase to fast). +this._nextStyleNameId=(0,l/* .getRandomIdBase */.IH)()}return e.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},e.prototype.makeTooltipMarker=function(e,t,n){var r="richText"===n?this._generateStyleName():null,a=(0,o/* .getTooltipMarker */.qg)({color:t,type:e,renderMode:n,markerId:r});return(0,i.isString)(a)?a:(this.richTextStyles[r]=a.style,a.content)}, +/** + * @usage + * ```ts + * const styledText = markupStyleCreator.wrapRichTextStyle([ + * // The styles will be auto merged. + * { + * fontSize: 12, + * color: 'blue' + * }, + * { + * padding: 20 + * } + * ]); + * ``` + */ +e.prototype.wrapRichTextStyle=function(e,t){var n={};(0,i.isArray)(t)?(0,i.each)(t,(function(e){return(0,i.extend)(n,e)})):(0,i.extend)(n,t);var r=this._generateStyleName();return this.richTextStyles[r]=n,"{"+r+"|"+e+"}"},e}(); +/***/}, +/***/3992: +/***/function(e,t,n){ +/* eslint-disable valid-typeof */ +var r=n(73971) +/** + * 判断是否Map对象 + * + * @param {Object} obj 对象 + * @return {Boolean} + */,o=typeof Map!==r;e.exports=function(e){return o&&e instanceof Map} +/***/}, +/***/4037: +/***/function(e,t,n){"use strict"; +// EXPORTS +n.d(t,{A:function(){/* binding */return i}}); +// EXTERNAL MODULE: ./node_modules/core-js/modules/es.iterator.constructor.js +n(18111),n(7588); +// EXTERNAL MODULE: ./node_modules/core-js/modules/es.iterator.for-each.js +var r=n(61431),o=n(37741); +/* harmony default export */var i={__name:"index",props:{formJson:{ +//prop传入的表单JSON配置 +type:Object,default:()=>(0,o.buildDefaultFormJson)()},formData:{ +//prop传入的表单数据 +type:Object,default:()=>({})},previewState:{ +//是否表单预览状态 +type:Boolean,default:!1}},setup(e,{expose:t}){const n=e;let i=(0,r.getCurrentInstance)().appContext.config.globalProperties.$Bus;// 声明$Bus +const{proxy:a}=(0,r.getCurrentInstance)();let l=(0,r.ref)(n.formJson),s=(0,r.ref)({}),c=(0,r.ref)({});function u(e){return e.type+"-widget-ly"}function d(e){return e.type+"-widget-ly"} +//响应式传递父组件数据到子组件 +//响应式传递父组件数据到子组件 +(0,r.provide)("globalFormModel",s),(0,r.provide)("refList",c);const f=(0,r.computed)((()=>l.value.formConfig)),h=(0,r.computed)((()=>l.value.widgetList)),p=(0,r.computed)((()=>f.value&&f.value.labelPosition?f.value.labelPosition:"left")),m=(0,r.computed)((()=>f.value&&f.value.labelWidth?f.value.labelWidth:"auto")),g=(0,r.computed)((()=>f.value&&f.value.size?f.value.size:"default")),v=(0,r.computed)((()=>f.value&&f.value.customClass?f.value.customClass:""));let A=(0,r.ref)(null);//表单唯一Id,用于区分页面上的多个render组件!! +function y(e=!0){A.value="lyRender"+(0,o.randomId)(),e&&function(){f.value&&f.value.cssCode&&(0,o.insertCustomCssToHead)(f.value.cssCode,n.previewState?"":A.value);f.value&&f.value.functions&&(0,o.insertGlobalFunctionsToHtml)(f.value.functions,n.previewState?"":A.value)}(),i.off("fieldValidation"),//移除原有事件监听 +i.on("fieldValidation",(e=>{b.value&&b.value.validateField(e)})),function(){if(f.value&&f.value.onFormMounted){new Function(f.value.onFormMounted).call()}}(),c.value.lyformbuilder_ref=a}let b=(0,r.ref)(null); +//触发表单指定的单个动态组件表单验证,用于清除可能存在的校验错误提示 +//递归获取组件widgetList中的form的model字段 +function O(e){if("container"===e.category)"grid"===e.type?e.cols&&e.cols.length>0&&e.cols.forEach((e=>{O(e)})):"table"===e.type?e.rows&&e.rows.length>0&&e.rows.forEach((e=>{e.cols&&e.cols.length>0&&e.cols.forEach((e=>{O(e)}))})):"tab"===e.type?e.tabs&&e.tabs.length>0&&e.tabs.forEach((e=>{e.widgetList&&e.widgetList.length>0&&e.widgetList.forEach((e=>{O(e)}))})):"grid-col"!==e.type&&"table-cell"!==e.type||e.widgetList&&e.widgetList.length>0&&e.widgetList.forEach((e=>{O(e)}));else if(e.formItemFlag)if(n.formData.hasOwnProperty(e.options.name)){let t=n.formData[e.options.name];s.value[e.options.name]=(0,o.deepClone)(t)}else s.value[e.options.name]=(0,o.deepClone)(e.options.defaultValue)} +//初始化映射获取formJson下widgetList组件中form的model字段 +//设置表单数据 +function w(e){ +//存不存在皆赋值 +s.value=(0,o.deepClone)(e); +// 存在组件才赋值 +// Object.keys(globalFormModel.value).forEach(pName => { +// if (!!formData && formData.hasOwnProperty(pName)) { +// globalFormModel.value[pName] = deepClone(formData[pName]) +// } +// }) +} +//获取表单数据 +//created执行 +return l.value=n.formJson,"{}"==JSON.stringify(n.formData)||0==Object.keys(n.formData).length? +//添加模式 +function(e){! +//清除表单model数据 +function(){for(let e in s.value)delete s.value[e]}(),e&&e.length>0&&e.forEach((e=>{O(e)}))}(l.value?l.value.widgetList:null): +//编辑模式 +w(n.formData),(0,r.onMounted)((()=>{y()})),t({setFormData:w,getFormData:function(e=!0){if(!e)return s.value;let t=function(){},n=new window.Promise((function(e,n){t=function(t,r){r?n(r):e(t)}}));return b.value.validate((e=>{e?t(s.value):t(s.value,"表单数据校验失败")})),n} +//获取表单ref +,getFormRef:function(){return b.value} +//设置表单下拉组件option的选项值 +,setFormJsonSelectOption:function(e,t){function r(e,t,n){e.formItemFlag? +// if(item.type === "select" && item.options.useForeignData && item.options.name === name){ +"select"===e.type&&e.options.name===t&&(e.options.optionItems=n):"container"===e.category&&("grid"===e.type?e.cols&&e.cols.length>0&&e.cols.forEach((e=>{r(e,t,n)})):"table"===e.type?e.rows&&e.rows.length>0&&e.rows.forEach((e=>{e.cols&&e.cols.length>0&&e.cols.forEach((e=>{r(e,t,n)}))})):"tab"===e.type?e.tabs&&e.tabs.length>0&&e.tabs.forEach((e=>{e.widgetList&&e.widgetList.length>0&&e.widgetList.forEach((e=>{r(e,t,n)}))})):"grid-col"!==e.type&&"table-cell"!==e.type||e.widgetList&&e.widgetList.length>0&&e.widgetList.forEach((e=>{r(e,t,n)})))}for(var o=0;o{const n=(0,r.resolveComponent)("el-form");return(0,r.openBlock)(),(0,r.createBlock)(n,{"label-position":p.value,size:g.value,class:(0,r.normalizeClass)([[v.value],"lyrenderform"]),disabled:f.value.disabled,"label-width":m.value,"validate-on-rule-change":!1,model:(0,r.unref)(s),ref_key:"lyrenderForm",ref:b,onSubmit:t[0]||(t[0]=(0,r.withModifiers)((()=>{}),["prevent"]))},{default:(0,r.withCtx)((()=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(h.value,((e,t)=>((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,null,["container"===e.category?((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(u(e)),{widget:e,key:e.id,"parent-list":h.value,"index-of-parent-list":t,"parent-widget":null,"design-state":!1},null,8,["widget","parent-list","index-of-parent-list"])):((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(d(e)),{"form-config":f.value,field:e,"design-state":!1,key:e.id,"parent-list":h.value,"index-of-parent-list":t,"parent-widget":null},null,8,["form-config","field","parent-list","index-of-parent-list"]))],64)))),256))])),_:1},8,["label-position","size","class","disabled","label-width","model"])}}}; +/***/}, +/***/4055: +/***/function(e,t,n){"use strict";var r=n(44576),o=n(20034),i=r.document,a=o(i)&&o(i.createElement);e.exports=function(e){return a?i.createElement(e):{}}}, +/***/4094: +/***/function(e,t,n){var r=n(41982),o=n(13908);e.exports=function(e,t,n){r(o(e),(function(r){t.call(n,e[r],r,e)}))} +/***/}, +/***/4213: +/***/function(e,t,n){var r,o,i;o=[],void 0===(i="function"==typeof(r=function(){"use strict";function t(e,t){return void 0===t?t={autoBom:!1}:"object"!=typeof t&&(t={autoBom:!t}),t.autoBom&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(e.type)?new Blob(["\ufeff",e],{type:e.type}):e}function r(e,t,n){var r=new XMLHttpRequest;r.open("GET",e),r.responseType="blob",r.onload=function(){s(r.response,t,n)},r.onerror=function(){},r.send()}function o(e){var t=new XMLHttpRequest;t.open("HEAD",e,!1);try{t.send()}catch(e){}return 200<=t.status&&299>=t.status}function i(e){try{e.dispatchEvent(new MouseEvent("click"))}catch(n){var t=document.createEvent("MouseEvents");t.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),e.dispatchEvent(t)}}var a="object"==typeof window&&window.window===window?window:"object"==typeof self&&self.self===self?self:"object"==typeof n.g&&n.g.global===n.g?n.g:void 0,l=a.navigator&&/Macintosh/.test(navigator.userAgent)&&/AppleWebKit/.test(navigator.userAgent)&&!/Safari/.test(navigator.userAgent),s=a.saveAs||("object"!=typeof window||window!==a?function(){}:"download"in HTMLAnchorElement.prototype&&!l?function(e,t,n){var l=a.URL||a.webkitURL,s=document.createElement("a");t=t||e.name||"download",s.download=t,s.rel="noopener","string"==typeof e?(s.href=e,s.origin===location.origin?i(s):o(s.href)?r(e,t,n):i(s,s.target="_blank")):(s.href=l.createObjectURL(e),setTimeout((function(){l.revokeObjectURL(s.href)}),4e4),setTimeout((function(){i(s)}),0))}:"msSaveOrOpenBlob"in navigator?function(e,n,a){if(n=n||e.name||"download","string"!=typeof e)navigator.msSaveOrOpenBlob(t(e,a),n);else if(o(e))r(e,n,a);else{var l=document.createElement("a");l.href=e,l.target="_blank",setTimeout((function(){i(l)}))}}:function(e,t,n,o){if((o=o||open("","_blank"))&&(o.document.title=o.document.body.innerText="downloading..."),"string"==typeof e)return r(e,t,n);var i="application/octet-stream"===e.type,s=/constructor/i.test(a.HTMLElement)||a.safari,c=/CriOS\/[\d]+/.test(navigator.userAgent);if((c||i&&s||l)&&"undefined"!=typeof FileReader){var u=new FileReader;u.onloadend=function(){var e=u.result;e=c?e:e.replace(/^data:[^;]*;/,"data:attachment/file;"),o?o.location.href=e:location=e,o=null},u.readAsDataURL(e)}else{var d=a.URL||a.webkitURL,f=d.createObjectURL(e);o?o.location=f:location.href=f,o=null,setTimeout((function(){d.revokeObjectURL(f)}),4e4)}});a.saveAs=s.saveAs=s,e.exports=s})?r.apply(t,o):r)||(e.exports=i)}, +/***/4235: +/***/function(e,t,n){"use strict"; +/* harmony export */n.d(t,{ +/* harmony export */J:function(){/* binding */return l} +/* harmony export */}); +/* harmony import */var r=n(98026),o=n(3961),i=n(58267),a=n(48170); +/* harmony import */ +/* +* Licensed to the Apache Software Foundation (ASF) under one +* or more contributor license agreements. See the NOTICE file +* distributed with this work for additional information +* regarding copyright ownership. The ASF licenses this file +* to you under the Apache License, Version 2.0 (the +* "License"); you may not use this file except in compliance +* with the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, +* software distributed under the License is distributed on an +* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +* KIND, either express or implied. See the License for the +* specific language governing permissions and limitations +* under the License. +*/ +/** + * AUTO-GENERATED FILE. DO NOT MODIFY. + */ +/* +* Licensed to the Apache Software Foundation (ASF) under one +* or more contributor license agreements. See the NOTICE file +* distributed with this work for additional information +* regarding copyright ownership. The ASF licenses this file +* to you under the Apache License, Version 2.0 (the +* "License"); you may not use this file except in compliance +* with the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, +* software distributed under the License is distributed on an +* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +* KIND, either express or implied. See the License for the +* specific language governing permissions and limitations +* under the License. +*/ +function l(e){var t,n,l,s,c=e.series,u=e.dataIndex,d=e.multipleSeries,f=c.getData(),h=f.mapDimensionsAll("defaultedTooltip"),p=h.length,m=c.getRawValue(u),g=(0,r.isArray)(m),v=(0,o/* .retrieveVisualColorForTooltipMarker */.aw)(c,u);if(p>1||g&&!p){var A=function(e,t,n,a,l){ +// check: category-no-encode-has-axis-data in dataset.html +var s=t.getData(),c=(0,r.reduce)(e,(function(e,t,n){var r=s.getDimensionInfo(n);return e||r&&!1!==r.tooltip&&null!=r.displayName}),!1),u=[],d=[],f=[];function h(e,t){var n=s.getDimensionInfo(t); +// If `dimInfo.tooltip` is not set, show tooltip. +n&&!1!==n.otherDims.tooltip&&(c?f.push((0,o/* .createTooltipMarkup */.Qx)("nameValue",{markerType:"subItem",markerColor:l,name:n.displayName,value:e,valueType:n.type})):(u.push(e),d.push(n.type)))}return a.length?(0,r.each)(a,(function(e){h((0,i/* .retrieveRawValue */.QE)(s,n,e),e)})):(0,r.each)(e,h),{inlineValues:u,inlineValueTypes:d,blocks:f}} +/***/(m,c,u,h,v);t=A.inlineValues,n=A.inlineValueTypes,l=A.blocks, +// Only support tooltip sort by the first inline value. It's enough in most cases. +s=A.inlineValues[0]}else if(p){var y=f.getDimensionInfo(h[0]);s=t=(0,i/* .retrieveRawValue */.QE)(f,u,h[0]),n=y.type}else s=t=g?m[0]:m; +// Do not show generated series name. It might not be readable. +var b=(0,a/* .isNameSpecified */.O0)(c),O=b&&c.name||"",w=f.getName(u),x=d?O:w;return(0,o/* .createTooltipMarkup */.Qx)("section",{header:O, +// When series name is not specified, do not show a header line with only '-'. +// This case always happens in tooltip.trigger: 'item'. +noHeader:d||!b,sortParam:s,blocks:[(0,o/* .createTooltipMarkup */.Qx)("nameValue",{markerType:"item",markerColor:v, +// Do not mix display seriesName and itemName in one tooltip, +// which might confuses users. +name:x, +// name dimension might be auto assigned, where the name might +// be not readable. So we check trim here. +noName:!(0,r.trim)(x),value:t,valueType:n,dataIndex:u})].concat(l||[])})}}, +/***/4390: +/***/function(e,t,n){"use strict"; +// ESM COMPAT FLAG +n.r(t), +// EXPORTS +n.d(t,{default:function(){/* binding */return l}}); +// EXTERNAL MODULE: ./node_modules/vue/dist/vue.esm-bundler.js + 5 modules +var r=n(61431);// ./src/views/systemManage/button/components/addButton.vue?vue&type=template&id=6b4d7bea +// EXTERNAL MODULE: ./node_modules/core-js/modules/es.iterator.constructor.js +n(18111),n(22489); +// EXTERNAL MODULE: ./node_modules/core-js/modules/es.iterator.filter.js +var o=n(40412),i=n(37741),a={components:{LyDialog:n(48404).A},emits:["refreshData"],name:"addButton",data(){return{dialogVisible:!1,loadingSave:!1,dialogTitle:"",formData:{name:"",value:""},rules:{name:[{required:!0,message:"请输入名称",trigger:"blur"}],value:[{required:!0,message:"请输入key值",trigger:"blur"}]},buttonList:[]}},methods:{getName(e){this.formData.value=e,this.formData.name=this.buttonList.filter((t=>t.value==e))[0].name},handleClose(){this.dialogVisible=!1,this.formData={name:"",value:""},this.$emit("refreshData")},addButtonFn(e,t,n){this.dialogVisible=!0,this.dialogTitle=t,e&&(this.formData=(0,i.deepClone)(e))},submitData(){let e={...this.formData};this.$refs.rulesForm.validate((t=>{t&&(this.loadingSave=!0,this.formData.id?(0,o.systemButtonEdit)(e).then((e=>{this.loadingSave=!1,2e3==e.code?(this.$message.success(e.msg),this.handleClose()):this.$message.warning(e.msg)})):(0,o.systemButtonAdd)(e).then((e=>{this.loadingSave=!1,2e3==e.code?(this.$message.success(e.msg),this.handleClose()):this.$message.warning(e.msg)})))}))}}}; +/* harmony default export */var l=(0,n(66262).A)(a,[["render",// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/views/systemManage/button/components/addButton.vue?vue&type=template&id=6b4d7bea +function(e,t,n,o,i,a){const l=(0,r.resolveComponent)("el-input"),s=(0,r.resolveComponent)("el-form-item"),c=(0,r.resolveComponent)("el-form"),u=(0,r.resolveComponent)("el-button"),d=(0,r.resolveComponent)("ly-dialog");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[(0,r.createVNode)(d,{modelValue:i.dialogVisible,"onUpdate:modelValue":t[2]||(t[2]=e=>i.dialogVisible=e),title:i.dialogTitle,width:"560px","before-close":a.handleClose},{footer:(0,r.withCtx)((()=>[(0,r.createVNode)(u,{onClick:a.handleClose,loading:i.loadingSave},{default:(0,r.withCtx)((()=>t[3]||(t[3]=[(0,r.createTextVNode)("关闭")]))),_:1},8,["onClick","loading"]),(0,r.createVNode)(u,{type:"primary",onClick:a.submitData,loading:i.loadingSave},{default:(0,r.withCtx)((()=>t[4]||(t[4]=[(0,r.createTextVNode)("保存")]))),_:1},8,["onClick","loading"])])),default:(0,r.withCtx)((()=>[(0,r.createVNode)(c,{inline:!0,model:i.formData,rules:i.rules,ref:"rulesForm","label-position":"right","label-width":"auto"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(s,{label:"名称:",prop:"name",style:{width:"100%"}},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(l,{modelValue:i.formData.name,"onUpdate:modelValue":t[0]||(t[0]=e=>i.formData.name=e),modelModifiers:{trim:!0}},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(s,{label:"key值:",prop:"value",style:{width:"100%"}},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(l,{modelValue:i.formData.value,"onUpdate:modelValue":t[1]||(t[1]=e=>i.formData.value=e),modelModifiers:{trim:!0}},null,8,["modelValue"])])),_:1})])),_:1},8,["model","rules"])])),_:1},8,["modelValue","title","before-close"])])}]]); +/***/}, +/***/4495: +/***/function(e,t,n){"use strict"; +/* eslint-disable es/no-symbol -- required for testing */var r=n(39519),o=n(79039),i=n(44576).String; +// eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing +e.exports=!!Object.getOwnPropertySymbols&&!o((function(){var e=Symbol("symbol detection"); +// Chrome 38 Symbol has incorrect toString conversion +// `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances +// nb: Do not call `String` directly to avoid this being optimized out to `symbol+''` which will, +// of course, fail. +return!i(e)||!(Object(e)instanceof Symbol)|| +// Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances +!Symbol.sham&&r&&r<41}))}, +/***/4934: +/***/function(e,t,n){ +/** + * Copyright (c) Tiny Technologies, Inc. All rights reserved. + * Licensed under the LGPL or a commercial license. + * For LGPL see License.txt in the project root for license information. + * For commercial licenses see https://www.tiny.cloud/ + * + * Version: 5.10.2 (2021-11-17) + */ +!function(){"use strict";var e=function(e){return function(t){return function(e){var t=typeof e;return null===e?"null":"object"===t&&(Array.prototype.isPrototypeOf(e)||e.constructor&&"Array"===e.constructor.name)?"array":"object"===t&&(String.prototype.isPrototypeOf(e)||e.constructor&&"String"===e.constructor.name)?"string":t}(t)===e}},t=function(e){return function(t){return typeof t===e}},r=function(e){return function(t){return e===t}},o=e("string"),i=e("object"),a=e("array"),l=r(null),s=t("boolean"),c=r(void 0),u=function(e){return null==e},d=function(e){return!u(e)},f=t("function"),h=t("number"),p=function(e,t){if(a(e)){for(var n=0,r=e.length;n-1},I=function(e,t){for(var n=0,r=e.length;n=0;n--)t(e[n],n)}(e,(function(e,r){n=t(n,e,r)})),n},X=function(e,t,n){return H(e,(function(e,r){n=t(n,e,r)})),n},Y=function(e,t){return function(e,t,n){for(var r=0,o=e.length;r=0&&t=t.length&&e.substr(n,n+t.length)===t},Se=function(e,t){return-1!==e.indexOf(t)},Ve=function(e,t){return ke(e,t,0)},Be=function(e,t){return ke(e,t,e.length-t.length)},Te=function(e){return function(t){return t.replace(e,"")}}(/^\s+|\s+$/g),Ne=function(e){return e.length>0},Ee=function(e){return void 0!==e.style&&f(e.style.getPropertyValue)},Pe=function(e){if(null==e)throw new Error("Node cannot be null or undefined");return{dom:e}},Qe={fromHtml:function(e,t){var n=(t||document).createElement("div");if(n.innerHTML=e,!n.hasChildNodes()||n.childNodes.length>1)throw new Error("HTML must have a single root node");return Pe(n.childNodes[0])},fromTag:function(e,t){var n=(t||document).createElement(e);return Pe(n)},fromText:function(e,t){var n=(t||document).createTextNode(e);return Pe(n)},fromDom:Pe,fromPoint:function(e,t,n){return Q.from(e.dom.elementFromPoint(t,n)).map(Pe)}};"undefined"!=typeof window?window:Function("return this;")();var Me,De=function(e){return e.dom.nodeName.toLowerCase()},$e=function(e){return function(t){return function(e){return e.dom.nodeType}(t)===e}},ze=$e(1),Re=$e(3),Ie=$e(9),Le=$e(11),Fe=function(e){var t,n=!1;return function(){for(var r=[],o=0;o0&&t0}))},on=function(e){var t={},n=e.dom;if(Ee(n))for(var r=0;ro?t-o:0}}},un=cn("height",(function(e){var t=e.dom;return It(e)?t.getBoundingClientRect().height:t.offsetHeight})),dn=function(e){return un.get(e)},fn=function(e){return un.getOuter(e)},hn=function(e,t){return{left:e,top:t,translate:function(n,r){return hn(e+n,t+r)}}},pn=hn,mn=function(e,t){return void 0!==e?e:void 0!==t?t:0},gn=function(e){var t=e.dom.ownerDocument,n=t.body,r=t.defaultView,o=t.documentElement;if(n===e.dom)return pn(n.offsetLeft,n.offsetTop);var i=mn(null==r?void 0:r.pageYOffset,o.scrollTop),a=mn(null==r?void 0:r.pageXOffset,o.scrollLeft),l=mn(o.clientTop,n.clientTop),s=mn(o.clientLeft,n.clientLeft);return vn(e).translate(a-s,i-l)},vn=function(e){var t=e.dom,n=t.ownerDocument.body;return n===t?pn(n.offsetLeft,n.offsetTop):It(e)?function(e){var t=e.getBoundingClientRect();return pn(t.left,t.top)}(t):pn(0,0)},An=cn("width",(function(e){return e.dom.offsetWidth})),yn=function(e){return An.get(e)},bn=function(e){return An.getOuter(e)},On=function(e){var t=Qe.fromDom(function(e){if(Qt()&&d(e.target)){var t=Qe.fromDom(e.target);if(ze(t)&&Rt(t)&&e.composed&&e.composedPath){var n=e.composedPath();if(n)return ae(n)}}return Q.from(e.target)}(e).getOr(e.target)),n=function(){return e.stopPropagation()},r=function(){return e.preventDefault()},o=g(r,n);return function(e,t,n,r,o,i,a){return{target:e,x:t,y:n,stop:r,prevent:o,kill:i,raw:a}}(t,e.clientX,e.clientY,n,r,o,e)},wn=function(e,t,n,r,o){var i=function(e,t){return function(n){e(n)&&t(On(n))}}(n,r);return e.dom.addEventListener(t,i,o),{unbind:b(xn,e,t,i,o)}},xn=function(e,t,n,r){e.dom.removeEventListener(t,n,r)},_n=function(e,t){kt(e).each((function(n){n.dom.insertBefore(t.dom,e.dom)}))},Cn=function(e,t){var n=function(e){return Q.from(e.dom.nextSibling).map(Qe.fromDom)}(e);n.fold((function(){kt(e).each((function(e){Sn(e,t)}))}),(function(e){_n(e,t)}))},kn=function(e,t){var n=function(e){return Bt(e,0)}(e);n.fold((function(){Sn(e,t)}),(function(n){e.dom.insertBefore(t.dom,n.dom)}))},Sn=function(e,t){e.dom.appendChild(t.dom)},Vn=function(e,t){H(t,(function(t){Sn(e,t)}))},Bn=function(e){e.dom.textContent="",H(Vt(e),(function(e){Tn(e)}))},Tn=function(e){var t=e.dom;null!==t.parentNode&&t.parentNode.removeChild(t)},Nn=function(e){var t,n=Vt(e);n.length>0&&(t=e,H(n,(function(e){_n(t,e)}))),Tn(e)},En=function(e){var t=void 0!==e?e.dom:document,n=t.body.scrollLeft||t.documentElement.scrollLeft,r=t.body.scrollTop||t.documentElement.scrollTop;return pn(n,r)},Pn=function(e,t,n){var r=(void 0!==n?n.dom:document).defaultView;r&&r.scrollTo(e,t)},Qn=function(e,t,n,r){return{x:e,y:t,width:n,height:r,right:e+n,bottom:t+r}},Mn=function(e){var t=void 0===e?window:e,n=t.document,r=En(Qe.fromDom(n));return function(e){var t=void 0===e?window:e;return gt().browser.isFirefox()?Q.none():Q.from(t.visualViewport)}(t).fold((function(){var e=t.document.documentElement,n=e.clientWidth,o=e.clientHeight;return Qn(r.left,r.top,n,o)}),(function(e){return Qn(Math.max(e.pageLeft,r.left),Math.max(e.pageTop,r.top),e.width,e.height)}))},Dn=function(e,t){return e.view(t).fold(v([]),(function(t){var n=e.owner(t),r=Dn(e,n);return[t].concat(r)}))},$n=Object.freeze({__proto__:null,view:function(e){var t;return(e.dom===document?Q.none():Q.from(null===(t=e.dom.defaultView)||void 0===t?void 0:t.frameElement)).map(Qe.fromDom)},owner:function(e){return wt(e)}}),zn=function(e){var t=Qe.fromDom(document),n=En(t),r=function(e,t){var n=t.owner(e),r=Dn(t,n);return Q.some(r)}(e,$n);return r.fold(b(gn,e),(function(t){var r=vn(e),o=q(t,(function(e,t){var n=vn(t);return{left:e.left+n.left,top:e.top+n.top}}),{left:0,top:0});return pn(o.left+r.left+n.left,o.top+r.top+n.top)}))},Rn=function(e,t,n,r){return{x:e,y:t,width:n,height:r,right:e+n,bottom:t+r}},In=function(e){var t=gn(e),n=bn(e),r=fn(e);return Rn(t.left,t.top,n,r)},Ln=function(e){var t=zn(e),n=bn(e),r=fn(e);return Rn(t.left,t.top,n,r)},Fn=function(){return Mn(window)},Un=function(e){return{isValue:_,isError:x,getOr:v(e),getOrThunk:v(e),getOrDie:v(e),or:function(t){return Un(e)},orThunk:function(t){return Un(e)},fold:function(t,n){return n(e)},map:function(t){return Un(t(e))},mapError:function(t){return Un(e)},each:function(t){t(e)},bind:function(t){return t(e)},exists:function(t){return t(e)},forall:function(t){return t(e)},toOptional:function(){return Q.some(e)}}},Hn=function(e){return{isValue:x,isError:_,getOr:A,getOrThunk:function(e){return e()},getOrDie:function(){return w(String(e))()},or:A,orThunk:function(e){return e()},fold:function(t,n){return t(e)},map:function(t){return Hn(e)},mapError:function(t){return Hn(t(e))},each:m,bind:function(t){return Hn(e)},exists:x,forall:_,toOptional:Q.none}},Wn={value:Un,error:Hn,fromOption:function(e,t){return e.fold((function(){return Hn(t)}),Un)}};!function(e){e[e.Error=0]="Error",e[e.Value=1]="Value"}(Me||(Me={}));var jn=function(e,t,n){return e.stype===Me.Error?t(e.serror):n(e.svalue)},qn=function(e){return{stype:Me.Value,svalue:e}},Xn=function(e){return{stype:Me.Error,serror:e}},Yn=function(e){return e.fold(Xn,qn)},Gn=function(e){return jn(e,Wn.error,Wn.value)},Zn=qn,Kn=function(e){var t=[],n=[];return H(e,(function(e){jn(e,(function(e){return n.push(e)}),(function(e){return t.push(e)}))})),{values:t,errors:n}},Jn=Xn,er=function(e,t){return e.stype===Me.Value?t(e.svalue):e},tr=function(e,t){return e.stype===Me.Error?t(e.serror):e},nr=function(e,t){return e.stype===Me.Value?{stype:Me.Value,svalue:t(e.svalue)}:e},rr=function(e,t){return e.stype===Me.Error?{stype:Me.Error,serror:t(e.serror)}:e},or=jn,ir=function(e,t,n,r){return{tag:"field",key:e,newKey:t,presence:n,prop:r}},ar=function(e,t,n){switch(e.tag){case"field":return t(e.key,e.newKey,e.presence,e.prop);case"custom":return n(e.newKey,e.instantiator)}},lr=function(e){return function(){for(var t=[],n=0;n0?hr(t.errors):Zn(t.values)},mr=function(e){return i(e)&&ue(e).length>100?" removed due to size":JSON.stringify(e,null,2)},gr=function(e,t){return Jn([{path:e,getErrorInfo:t}])},vr=function(e){return{extract:function(t,n){return tr(e(n),(function(e){return function(e,t){return gr(e,v(t))}(t,e)}))},toString:v("val")}},Ar=vr(Zn),yr=function(e,t,n,r){return ye(t,n).fold((function(){return function(e,t,n){return gr(e,(function(){return'Could not find valid *required* value for "'+t+'" in '+mr(n)}))}(e,n,t)}),r)},br=function(e,t,n,r){return r(ye(e,t).getOrThunk((function(){return n(e)})))},Or=function(e,t,n,r,o){var i=function(e){return o.extract(t.concat([r]),e)},a=function(e){return e.fold((function(){return Zn(Q.none())}),(function(e){var n=o.extract(t.concat([r]),e);return nr(n,Q.some)}))};switch(e.tag){case"required":return yr(t,n,r,i);case"defaultedThunk":return br(n,r,e.process,i);case"option":return function(e,t,n){return n(ye(e,t))}(n,r,a);case"defaultedOptionThunk":return function(e,t,n,r){return r(ye(e,t).map((function(t){return!0===t?n(e):t})))}(n,r,e.process,a);case"mergeWithThunk":return br(n,r,v({}),(function(t){var r=sr(e.process(n),t);return i(r)}))}},wr=function(e){return{extract:function(t,n){return e().extract(t,n)},toString:function(){return e().toString()}}},xr=function(e){return ue(me(e,d))},_r=function(e){var t=Cr(e),n=q(e,(function(e,t){return ar(t,(function(t){var n;return sr(e,((n={})[t]=!0,n))}),v(e))}),{});return{extract:function(e,r){var o=s(r)?[]:xr(r),i=j(o,(function(e){return!Oe(n,e)}));return 0===i.length?t.extract(e,r):function(e,t){return gr(e,(function(){return"There are unsupported fields: ["+t.join(", ")+"] specified"}))}(e,i)},toString:t.toString}},Cr=function(e){return{extract:function(t,n){return function(e,t,n){for(var r={},o=[],i=0,a=n;i0?Jn(o):Zn(r)}(t,n,e)},toString:function(){var t=U(e,(function(e){return ar(e,(function(e,t,n,r){return e+" -> "+r.toString()}),(function(e,t){return"state("+e+")"}))}));return"obj{\n"+t.join("\n")+"}"}}},kr=function(e){return{extract:function(t,n){var r=U(n,(function(n,r){return e.extract(t.concat(["["+r+"]"]),n)}));return pr(r)},toString:function(){return"array("+e.toString()+")"}}},Sr=function(e){return{extract:function(t,n){for(var r=[],o=0,i=e;o10?t.slice(0,10).concat([{path:[],getErrorInfo:v("... (only showing first ten failures)")}]):t,U(n,(function(e){return"Failed path: ("+e.path.join(" > ")+")\n"+e.getErrorInfo()}))).join("\n")+"\n\nInput object: "+mr(e.input);var t,n},jr=function(e,t){return Rr(e,he(t,Cr))},qr=ir,Xr=function(e,t){return{tag:"custom",newKey:e,instantiator:t}},Yr=function(e){return Ir((function(t){return R(e,t)?Wn.value(t):Wn.error('Unsupported value: "'+t+'", choose one of "'+e.join(", ")+'".')}))},Gr=function(e){return qr(e,e,{tag:"required",process:{}},Tr())},Zr=function(e,t){return qr(e,e,{tag:"required",process:{}},t)},Kr=function(e){return Zr(e,Er)},Jr=function(e){return Zr(e,Pr)},eo=function(e,t){return qr(e,e,{tag:"required",process:{}},Yr(t))},to=function(e){return Zr(e,Mr)},no=function(e,t){return qr(e,e,{tag:"required",process:{}},Cr(t))},ro=function(e,t){return qr(e,e,{tag:"required",process:{}},Br(t))},oo=function(e,t){return qr(e,e,{tag:"required",process:{}},kr(t))},io=function(e){return qr(e,e,{tag:"option",process:{}},Tr())},ao=function(e,t){return qr(e,e,{tag:"option",process:{}},t)},lo=function(e){return ao(e,Er)},so=function(e){return ao(e,Pr)},co=function(e){return ao(e,Mr)},uo=function(e,t){return ao(e,kr(t))},fo=function(e,t){return ao(e,Cr(t))},ho=function(e,t){return qr(e,e,dr(t),Tr())},po=function(e,t,n){return qr(e,e,dr(t),n)},mo=function(e,t){return po(e,t,Er)},go=function(e,t){return po(e,t,Pr)},vo=function(e,t,n){return po(e,t,Yr(n))},Ao=function(e,t){return po(e,t,Qr)},yo=function(e,t){return po(e,t,Mr)},bo=function(e,t,n){return po(e,t,kr(n))},Oo=function(e,t,n){return po(e,t,Cr(n))},wo=function(e){var t=e;return{get:function(){return t},set:function(e){t=e}}},xo=function(e){if(!a(e))throw new Error("cases must be an array");if(0===e.length)throw new Error("there must be at least one case");var t=[],n={};return H(e,(function(r,o){var i=ue(r);if(1!==i.length)throw new Error("one and only one name per case");var l=i[0],s=r[l];if(void 0!==n[l])throw new Error("duplicate key detected:"+l);if("cata"===l)throw new Error("cannot have a case named cata (sorry)");if(!a(s))throw new Error("case arguments must be an array");t.push(l),n[l]=function(){for(var n=[],r=0;r0?(n=r.errors,Wn.error(Z(n))):function(e,t){return 0===e.length?Wn.value(t):Wn.value(sr(t,cr.apply(void 0,e)))}(r.values,t)},Bo=function(e){return f(e)?e:x},To=function(e,t,n){for(var r=e.dom,o=Bo(n);r.parentNode;){r=r.parentNode;var i=Qe.fromDom(r),a=t(i);if(a.isSome())return a;if(o(i))break}return Q.none()},No=function(e,t,n){var r=t(e),o=Bo(n);return r.orThunk((function(){return o(e)?Q.none():To(e,t,o)}))},Eo=function(e,t){return yt(e.element,t.event.target)},Po={can:_,abort:x,run:m},Qo=function(e){if(!Oe(e,"can")&&!Oe(e,"abort")&&!Oe(e,"run"))throw new Error("EventHandler defined by: "+JSON.stringify(e,null,2)+" does not have can, abort, or run!");return k(k({},Po),e)},Mo=function(e){var t=function(e,t){return function(){for(var n=[],r=0;r1?j(t[n],(function(t){return I(e,(function(e){return e.name===t}))})).join(" > "):e[0].name;return ko(n,function(e,t){return{handler:e,purpose:t}}(o,i))}))}));return Vo(n,{})},Na="alloy.base.behaviour",Ea=Cr([qr("dom","dom",{tag:"required",process:{}},Cr([Gr("tag"),ho("styles",{}),ho("classes",[]),ho("attributes",{}),io("value"),io("innerHtml")])),Gr("components"),Gr("uid"),ho("events",{}),ho("apis",{}),qr("eventOrder","eventOrder",function(e){return fr(v(e))}((_o={},_o[ci()]=["disabling",Na,"toggling","typeaheadevents"],_o[ii()]=[Na,"focusing","keying"],_o[mi()]=[Na,"disabling","toggling","representing"],_o[Go()]=[Na,"representing","streaming","invalidating"],_o[Oi()]=[Na,"representing","item-events","tooltipping"],_o[Lo()]=["focusing",Na,"item-type-events"],_o[$o()]=["focusing",Na,"item-type-events"],_o[Wo()]=["item-type-events","tooltipping"],_o[si()]=["receiving","reflecting","tooltipping"],_o)),Tr()),io("domModification")]),Pa=function(e){return e.events},Qa=function(e,t){var n=jt(e,t);return void 0===n||""===n?[]:n.split(" ")},Ma=function(e){return void 0!==e.dom.classList},Da=function(e,t){return function(e,t,n){var r=Qa(e,t).concat([n]);return Ht(e,t,r.join(" ")),!0}(e,"class",t)},$a=function(e,t){return function(e,t,n){var r=j(Qa(e,t),(function(e){return e!==n}));return r.length>0?Ht(e,t,r.join(" ")):Yt(e,t),!1}(e,"class",t)},za=function(e,t){Ma(e)?e.dom.classList.add(t):Da(e,t)},Ra=function(e){var t=Ma(e)?e.dom.classList:function(e){return Qa(e,"class")}(e);0===t.length&&Yt(e,"class")},Ia=function(e,t){Ma(e)?e.dom.classList.remove(t):$a(e,t);Ra(e)},La=function(e,t){return Ma(e)&&e.dom.classList.contains(t)},Fa=function(e,t){H(t,(function(t){za(e,t)}))},Ua=function(e,t){H(t,(function(t){Ia(e,t)}))},Ha=function(e){return e.dom.value},Wa=function(e,t){if(void 0===t)throw new Error("Value.set was undefined");e.dom.value=t},ja=function(e,t){return function(e,t){var n=U(t,(function(e){return fo(e.name(),[Gr("config"),ho("state",Oa)])})),r=Fr("component.behaviours",Cr(n),e.behaviours).fold((function(t){throw new Error(Wr(t)+"\nComplete spec:\n"+JSON.stringify(e,null,2))}),A);return{list:t,data:he(r,(function(e){var t=e.map((function(e){return{config:e.config,state:e.state.init(e.config)}}));return v(t)}))}}(e,t)},qa=function(e){var t=function(e){var t=ye(e,"behaviours").getOr({});return K(ue(t),(function(e){var n=t[e];return d(n)?[n.me]:[]}))}(e);return ja(e,t)},Xa=function(e,t,n){var r,o,i,a=k(k({},(r=e).dom),{uid:r.uid,domChildren:U(r.components,(function(e){return e.element}))}),l=function(e){return e.domModification.fold((function(){return _a({})}),_a)}(e),s={"alloy.base.modification":l},c=t.length>0?function(e,t,n,r){var o=k({},t);H(n,(function(t){o[t.name()]=t.exhibit(e,r)}));var i=xa(o,(function(e,t){return{name:e,modification:t}})),a=function(e){return q(e,(function(e,t){return k(k({},t.modification),e)}),{})},l=q(i.classes,(function(e,t){return t.modification.concat(e)}),[]),s=a(i.attributes),c=a(i.styles);return _a({classes:l,attributes:s,styles:c})}(n,s,t,a):l;return i=c,k(k({},o=a),{attributes:k(k({},o.attributes),i.attributes),styles:k(k({},o.styles),i.styles),classes:o.classes.concat(i.classes)})},Ya=function(e,t,n){var r={"alloy.base.behaviour":Pa(e)};return function(e,t,n,r){var o=Sa(e,n,r);return Ta(o,t)}(n,e.eventOrder,t,r).getOrDie()},Ga=function(e){var t=function(){return u},n=wo(ma),r=Ur(function(e){return Fr("custom.definition",Ea,e)}(e)),o=qa(e),i=function(e){return e.list}(o),a=function(e){return e.data}(o),l=function(e){var t=Qe.fromTag(e.tag);Wt(t,e.attributes),Fa(t,e.classes),Jt(t,e.styles),e.innerHtml.each((function(e){return Ki(t,e)}));var n=e.domChildren;return Vn(t,n),e.value.each((function(e){Wa(t,e)})),e.uid,ua(t,e.uid),t}(Xa(r,i,a)),s=Ya(r,i,a),c=wo(r.components),u={uid:e.uid,getSystem:n.get,config:function(t){var n=a;return(f(n[t.name()])?n[t.name()]:function(){throw new Error("Could not find "+t.name()+" in "+JSON.stringify(e,null,2))})()},hasConfigured:function(e){return f(a[e.name()])},spec:e,readState:function(e){return a[e]().map((function(e){return e.state.readState()})).getOr("not enabled")},getApis:function(){return r.apis},connect:function(e){n.set(e)},disconnect:function(){n.set(pa(t))},element:l,syncComponents:function(){var e=Vt(l),t=K(e,(function(e){return n.get().getByDom(e).fold((function(){return[]}),re)}));c.set(t)},components:c.get,events:s};return u},Za=function(e){var t=ha(e),n=t.events,r=S(t,["events"]),o=function(e){var t=ye(e,"components").getOr([]);return U(t,tl)}(r),i=k(k({},r),{events:k(k({},ra),n),components:o});return Wn.value(Ga(i))},Ka=function(e){var t=Qe.fromText(e);return Ja({element:t})},Ja=function(e){var t=Hr("external.component",_r([Gr("element"),io("uid")]),e),n=wo(pa()),r=t.uid.getOrThunk((function(){return fa("external")}));ua(t.element,r);var o={uid:r,getSystem:n.get,config:Q.none,hasConfigured:x,connect:function(e){n.set(e)},disconnect:function(){n.set(pa((function(){return o})))},getApis:function(){return{}},element:t.element,spec:e,readState:v("No state"),syncComponents:m,components:v([]),events:{}};return ya(o)},el=fa,tl=function(e){return function(e){return ye(e,Aa)}(e).getOrThunk((function(){var t=function(e){return be(e,"uid")}(e)?e:k({uid:el("")},e);return Za(t).getOrDie()}))},nl=ya;function rl(e,t,n,r,o){return e(n,r)?Q.some(n):f(o)&&o(n)?Q.none():t(n,r,o)}var ol,il=function(e,t,n){for(var r=e.dom,o=f(n)?n:x;r.parentNode;){r=r.parentNode;var i=Qe.fromDom(r);if(t(i))return Q.some(i);if(o(i))break}return Q.none()},al=function(e,t,n){return rl((function(e,t){return t(e)}),il,e,t,n)},ll=function(e,t,n){return al(e,t,n).isSome()},sl=function(e,t,n){return il(e,(function(e){return vt(e,t)}),n)},cl=function(e,t){return function(e,t){return Y(e.dom.childNodes,(function(e){return t(Qe.fromDom(e))})).map(Qe.fromDom)}(e,(function(e){return vt(e,t)}))},ul=function(e,t){return function(e,t){var n=void 0===t?document:t.dom;return At(n)?Q.none():Q.from(n.querySelector(e)).map(Qe.fromDom)}(t,e)},dl=function(e,t,n){return rl((function(e,t){return vt(e,t)}),sl,e,t,n)},fl=function(){var e=ia("aria-owns");return{id:e,link:function(t){Ht(t,"aria-owns",e)},unlink:function(e){Yt(e,"aria-owns")}}},hl=function(e,t){return function(e){var t=al(e,(function(e){if(!ze(e))return!1;var t=jt(e,"id");return void 0!==t&&t.indexOf("aria-owns")>-1}));return t.bind((function(e){var t=jt(e,"id"),n=Mt(e);return ul(n,'[aria-owns="'+t+'"]')}))}(t).exists((function(t){return pl(e,t)}))},pl=function(e,t){return ll(t,(function(t){return yt(t,e.element)}),x)||hl(e,t)},ml="unknown";!function(e){e[e.STOP=0]="STOP",e[e.NORMAL=1]="NORMAL",e[e.LOGGING=2]="LOGGING"}(ol||(ol={}));var gl=wo({}),vl=function(e,t,n){switch(ye(gl.get(),e).orThunk((function(){var t=ue(gl.get());return ce(t,(function(t){return e.indexOf(t)>-1?Q.some(gl.get()[t]):Q.none()}))})).getOr(ol.NORMAL)){case ol.NORMAL:return n(bl());case ol.LOGGING:var r=function(e){var t=[];return(new Date).getTime(),{logEventCut:function(e,n,r){t.push({outcome:"cut",target:n,purpose:r})},logEventStopped:function(e,n,r){t.push({outcome:"stopped",target:n,purpose:r})},logNoParent:function(e,n,r){t.push({outcome:"no-parent",target:n,purpose:r})},logEventNoHandlers:function(e,n){t.push({outcome:"no-handlers-left",target:n})},logEventResponse:function(e,n,r){t.push({outcome:"response",purpose:r,target:n})},write:function(){(new Date).getTime(),R(["mousemove","mouseover","mouseout",mi()],e)}}}(e),o=n(r);return r.write(),o;case ol.STOP:return!0}},Al=["alloy/data/Fields","alloy/debugging/Debugging"],yl=function(e,t,n){return vl(e,0,n)},bl=v({logEventCut:m,logEventStopped:m,logNoParent:m,logEventNoHandlers:m,logEventResponse:m,write:m}),Ol=v([Gr("menu"),Gr("selectedMenu")]),wl=v([Gr("item"),Gr("selectedItem")]);v(Cr(wl().concat(Ol())));var xl=v(Cr(wl())),_l=no("initSize",[Gr("numColumns"),Gr("numRows")]),Cl=function(){return no("markers",[Gr("backgroundMenu")].concat(Ol()).concat(wl()))},kl=function(e){return no("markers",U(e,Gr))},Sl=function(e,t,n){return function(){var e=new Error;if(void 0!==e.stack){var t=e.stack.split("\n");return Y(t,(function(e){return e.indexOf("alloy")>0&&!I(Al,(function(t){return e.indexOf(t)>-1}))})).getOr(ml)}}(),qr(t,t,n,Ir((function(e){return Wn.value((function(){for(var t=[],n=0;nr?n:o=n&&a<=o&&l>=r&&l<=i,sizeInBounds:s<=o&&s>=n&&c<=i&&c>=r,visibleW:Math.min(u,a>=n?o-a:s-n),visibleH:Math.min(d,l>=r?i-l:c-r)}}(c,a),d=u.originInBounds,f=u.sizeInBounds,h=u.visibleW,p=u.visibleH,m=d&&f,g=m?c:function(e,t){var n=t.x,r=t.y,o=t.right,i=t.bottom,a=e.x,l=e.y,s=e.width,c=e.height,u=Math.max(n,o-s),d=Math.max(r,i-c),f=jl(a,n,u),h=jl(l,r,d),p=Math.min(f+s,o)-f,m=Math.min(h+c,i)-h;return Rn(f,h,p,m)}(c,a),A=g.width>0&&g.height>0,y=function(e,t,n){var r=v(t.bottom-n.y),o=v(n.bottom-t.y),i=function(e,t,n,r){return e.fold(t,t,r,r,t,r,n,n)}(e,o,o,r),a=v(t.right-n.x),l=v(n.right-t.x),s=function(e,t,n,r){return e.fold(t,r,t,r,n,n,t,r)}(e,l,l,a);return{maxWidth:s,maxHeight:i}}(e.direction,g,r),b=y.maxWidth,O={rect:g,maxHeight:y.maxHeight,maxWidth:b,direction:e.direction,placement:e.placement,classes:{on:o.classesOn,off:o.classesOff},layout:e.label,testY:s};return m||e.alwaysFit?Ys.fit(O):Ys.nofit(O,h,p,A)},Zs=function(e){var t=wo(Q.none()),n=function(){return t.get().each(e)};return{clear:function(){n(),t.set(Q.none())},isSet:function(){return t.get().isSome()},get:function(){return t.get()},set:function(e){n(),t.set(Q.some(e))}}},Ks=function(){return Zs((function(e){return e.destroy()}))},Js=function(){return Zs((function(e){return e.unbind()}))},ec=function(){var e=Zs(m);return k(k({},e),{on:function(t){return e.get().each(t)}})},tc=_,nc=function(e,t,n){return function(e,t,n,r){return wn(e,t,n,r,!1)}(e,t,tc,n)},rc=function(e,t,n){return function(e,t,n,r){return wn(e,t,n,r,!0)}(e,t,tc,n)},oc=On,ic=["top","bottom","right","left"],ac="data-alloy-transition-timer",lc=function(e,t){return function(e,t){return J(t,(function(t){return La(e,t)}))}(e,t.classes)},sc=function(e,t){var n=function(e){return parseFloat(e).toFixed(3)};return ve(t,(function(t,r){var o,i,a,l=e[r].map(n),s=t.map(n);return void 0===a&&(a=y),!_e(o=l,i=s,a).getOr(o.isNone()&&i.isNone())})).isSome()},cc=function(e,t){var n,r=Js(),i=Js(),a=function(t){var n,r=null!==(n=t.raw.pseudoElement)&&void 0!==n?n:"";return yt(t.target,e)&&!Ne(r)&&R(ic,t.raw.propertyName)},l=function(o){if(u(o)||a(o)){r.clear(),i.clear();var l=null==o?void 0:o.raw.type;(u(l)||l===ei())&&(clearTimeout(n),Yt(e,ac),Ua(e,t.classes))}},s=function(){r.set(nc(e,ei(),l)),i.set(nc(e,Jo(),l))};if("ontransitionstart"in e.dom)var c=nc(e,ti(),(function(e){a(e)&&(c.unbind(),s())}));else s();var d=function(e){var t=function(t){var n=tn(e,t),r=o(n)?n.split(/\s*,\s*/):[];return j(r,Ne)},n=function(e){if(o(e)&&/^[\d.]+/.test(e)){var t=parseFloat(e);return Be(e,"ms")?t:1e3*t}return 0},r=t("transition-delay"),i=t("transition-duration");return X(i,(function(e,t,o){var i=n(r[o])+n(t);return Math.max(e,i)}),0)}(e);requestAnimationFrame((function(){n=setTimeout(l,d+17),Ht(e,ac,n)}))},uc=function(e,t,n,r,o,i){var a=function(e,t,n){return n.exists((function(n){var r=e.mode;return"all"===r||n[r]!==t[r]}))}(r,o,i);if(a||lc(e,r)){Kt(e,"position",n.position);var l=Is(t,e),s=Rs(t,k(k({},o),{rect:l})),c=ne(ic,(function(e){return s[e]}));sc(n,c)&&(en(e,c),a&&function(e,t){Fa(e,t.classes),qt(e,ac).each((function(t){clearTimeout(parseInt(t,10)),Yt(e,ac)})),cc(e,t)}(e,r),sn(e))}else Ua(e,r.classes)},dc=function(e,t,n,r){ln(t,"max-height"),ln(t,"max-width");var o,i={width:bn(o=t),height:fn(o)};return function(e,t,n,r,o,i){var a=r.width,l=r.height,s=function(t,s,c,u,d){var f=t(n,r,o,e,i),h=Gs(f,a,l,i);return h.fold(v(h),(function(e,t,n,r){return(d===r?n>u||t>c:!d&&r)?h:Ys.nofit(s,c,u,d)}))},c=X(t,(function(e,t){var n=b(s,t);return e.fold(v(e),n)}),Ys.nofit({rect:n,maxHeight:r.height,maxWidth:r.width,direction:$l(),placement:"southeast",classes:{on:[],off:[]},layout:"none",testY:n.y},-1,-1,!1));return c.fold(A,A)}(t,r.preference,e,i,n,r.bounds)},fc=function(e,t){!function(e,t){Ht(e,qs,t)}(e,t.placement)},hc=function(e,t){!function(e,t){var n=un.max(e,t,["margin-top","border-top-width","padding-top","padding-bottom","border-bottom-width","margin-bottom"]);Kt(e,"max-height",n+"px")}(e,Math.floor(t))},pc=v((function(e,t){hc(e,t),Jt(e,{"overflow-x":"hidden","overflow-y":"auto"})})),mc=v((function(e,t){hc(e,t)})),gc=function(e,t,n){return void 0===e[t]?n:e[t]},vc=function(e,t,n,r){var o=dc(e,t,n,r);return function(e,t,n){var r=Rs(n.origin,t);n.transition.each((function(o){uc(e,n.origin,r,o,t,n.lastPlacement)})),Ds(e,r)}(t,o,r),fc(t,o),function(e,t){var n=t.classes;Ua(e,n.off),Fa(e,n.on)}(t,o),function(e,t,n){(0,n.maxHeightFunction)(e,t.maxHeight)}(t,o,r),function(e,t,n){(0,n.maxWidthFunction)(e,t.maxWidth)}(t,o,r),{layout:o.layout,placement:o.placement}},Ac=["valignCentre","alignLeft","alignRight","alignCentre","top","bottom","left","right","inset"],yc=function(e,t,n,r){void 0===r&&(r=1);var o=e*r,i=t*r,a=function(e){return ye(n,e).getOr([])},l=function(e,t,n){var r=te(Ac,n);return{offset:pn(e,t),classesOn:K(n,a),classesOff:K(r,a)}};return{southeast:function(){return l(-e,t,["top","alignLeft"])},southwest:function(){return l(e,t,["top","alignRight"])},south:function(){return l(-e/2,t,["top","alignCentre"])},northeast:function(){return l(-e,-t,["bottom","alignLeft"])},northwest:function(){return l(e,-t,["bottom","alignRight"])},north:function(){return l(-e/2,-t,["bottom","alignCentre"])},east:function(){return l(e,-t/2,["valignCentre","left"])},west:function(){return l(-e,-t/2,["valignCentre","right"])},insetNortheast:function(){return l(o,i,["top","alignLeft","inset"])},insetNorthwest:function(){return l(-o,i,["top","alignRight","inset"])},insetNorth:function(){return l(-o/2,i,["top","alignCentre","inset"])},insetSoutheast:function(){return l(o,-i,["bottom","alignLeft","inset"])},insetSouthwest:function(){return l(-o,-i,["bottom","alignRight","inset"])},insetSouth:function(){return l(-o/2,-i,["bottom","alignCentre","inset"])},insetEast:function(){return l(-o,-i/2,["valignCentre","right","inset"])},insetWest:function(){return l(o,-i/2,["valignCentre","left","inset"])}}},bc=function(){return yc(0,0,{})},Oc=A,wc=function(e,t){return function(n){return"rtl"===xc(n)?t:e}},xc=function(e){return"rtl"===tn(e,"direction")?"rtl":"ltr"};!function(e){e.TopToBottom="toptobottom",e.BottomToTop="bottomtotop"}(Us||(Us={}));var _c="data-alloy-vertical-dir",Cc=function(e){return ll(e,(function(e){return ze(e)&&jt(e,"data-alloy-vertical-dir")===Us.BottomToTop}))},kc=function(){return fo("layouts",[Gr("onLtr"),Gr("onRtl"),io("onBottomLtr"),io("onBottomRtl")])},Sc=function(e,t,n,r,o,i,a){var l=a.map(Cc).getOr(!1),s=t.layouts.map((function(t){return t.onLtr(e)})),c=t.layouts.map((function(t){return t.onRtl(e)})),u=l?t.layouts.bind((function(t){return t.onBottomLtr.map((function(t){return t(e)}))})).or(s).getOr(o):s.getOr(n),d=l?t.layouts.bind((function(t){return t.onBottomRtl.map((function(t){return t(e)}))})).or(c).getOr(i):c.getOr(r);return wc(u,d)(e)},Vc=[Gr("hotspot"),io("bubble"),ho("overrides",{}),kc(),El("placement",(function(e,t,n){var r=t.hotspot,o=Is(n,r.element),i=Sc(e.element,t,hs(),ps(),ds(),fs(),Q.some(t.hotspot.element));return Q.some(Oc({anchorBox:o,bubble:t.bubble.getOr(bc()),overrides:t.overrides,layouts:i,placer:Q.none()}))}))],Bc=[Gr("x"),Gr("y"),ho("height",0),ho("width",0),ho("bubble",bc()),ho("overrides",{}),kc(),El("placement",(function(e,t,n){var r=Fs(n,t.x,t.y),o=Rn(r.left,r.top,t.width,t.height),i=Sc(e.element,t,cs(),us(),cs(),us(),Q.none());return Q.some(Oc({anchorBox:o,bubble:t.bubble,overrides:t.overrides,layouts:i,placer:Q.none()}))}))],Tc=xo([{screen:["point"]},{absolute:["point","scrollLeft","scrollTop"]}]),Nc=function(e){return e.fold(A,(function(e,t,n){return e.translate(-t,-n)}))},Ec=function(e){return e.fold(A,A)},Pc=function(e){return X(e,(function(e,t){return e.translate(t.left,t.top)}),pn(0,0))},Qc=function(e){var t=U(e,Ec);return Pc(t)},Mc=Tc.screen,Dc=Tc.absolute,$c=function(e,t,n){var r=wt(e.element),o=En(r),i=function(e,t,n){var r=Ct(n.root).dom;return Q.from(r.frameElement).map(Qe.fromDom).filter((function(t){var n=wt(t),r=wt(e.element);return yt(n,r)})).map(gn)}(e,0,n).getOr(o);return Dc(i,o.left,o.top)},zc=function(e,t,n,r){var o=Mc(pn(e,t));return Q.some(function(e,t,n){return{point:e,width:t,height:n}}(o,n,r))},Rc=function(e,t,n,r,o){return e.map((function(e){var i,a,l,s=[t,e.point],c=(i=function(){return Qc(s)},a=function(){return Qc(s)},l=function(){return function(e){var t=U(e,Nc);return Pc(t)}(s)},r.fold(i,a,l)),u=function(e,t,n,r){return{x:e,y:t,width:n,height:r}}(c.left,c.top,e.width,e.height),d=n.showAbove?ds():hs(),f=n.showAbove?fs():ps(),h=Sc(o,n,d,f,d,f,Q.none());return Oc({anchorBox:u,bubble:n.bubble.getOr(bc()),overrides:n.overrides,layouts:h,placer:Q.none()})}))},Ic=[Gr("node"),Gr("root"),io("bubble"),kc(),ho("overrides",{}),ho("showAbove",!1),El("placement",(function(e,t,n){var r=$c(e,0,t);return t.node.filter(It).bind((function(o){var i=o.dom.getBoundingClientRect(),a=zc(i.left,i.top,i.width,i.height),l=t.node.getOr(e.element);return Rc(a,r,t,n,l)}))}))],Lc=function(e,t,n,r){return{start:e,soffset:t,finish:n,foffset:r}},Fc=xo([{before:["element"]},{on:["element","offset"]},{after:["element"]}]),Uc=(Fc.before,Fc.on,Fc.after,function(e){return e.fold(A,A,A)}),Hc=xo([{domRange:["rng"]},{relative:["startSitu","finishSitu"]},{exact:["start","soffset","finish","foffset"]}]),Wc={domRange:Hc.domRange,relative:Hc.relative,exact:Hc.exact,exactFromRange:function(e){return Hc.exact(e.start,e.soffset,e.finish,e.foffset)},getWin:function(e){var t=function(e){return e.match({domRange:function(e){return Qe.fromDom(e.startContainer)},relative:function(e,t){return Uc(e)},exact:function(e,t,n,r){return e}})}(e);return Ct(t)},range:Lc},jc=function(e,t,n){var r,o=e.document.createRange();return r=o,t.fold((function(e){r.setStartBefore(e.dom)}),(function(e,t){r.setStart(e.dom,t)}),(function(e){r.setStartAfter(e.dom)})),function(e,t){t.fold((function(t){e.setEndBefore(t.dom)}),(function(t,n){e.setEnd(t.dom,n)}),(function(t){e.setEndAfter(t.dom)}))}(o,n),o},qc=function(e,t,n,r,o){var i=e.document.createRange();return i.setStart(t.dom,n),i.setEnd(r.dom,o),i},Xc=function(e){return{left:e.left,top:e.top,right:e.right,bottom:e.bottom,width:e.width,height:e.height}},Yc=xo([{ltr:["start","soffset","finish","foffset"]},{rtl:["start","soffset","finish","foffset"]}]),Gc=function(e,t,n){return t(Qe.fromDom(n.startContainer),n.startOffset,Qe.fromDom(n.endContainer),n.endOffset)},Zc=function(e,t){var n=function(e,t){return t.match({domRange:function(e){return{ltr:v(e),rtl:Q.none}},relative:function(t,n){return{ltr:Fe((function(){return jc(e,t,n)})),rtl:Fe((function(){return Q.some(jc(e,n,t))}))}},exact:function(t,n,r,o){return{ltr:Fe((function(){return qc(e,t,n,r,o)})),rtl:Fe((function(){return Q.some(qc(e,r,o,t,n))}))}}})}(e,t);return function(e,t){var n=t.ltr();return n.collapsed?t.rtl().filter((function(e){return!1===e.collapsed})).map((function(e){return Yc.rtl(Qe.fromDom(e.endContainer),e.endOffset,Qe.fromDom(e.startContainer),e.startOffset)})).getOrThunk((function(){return Gc(0,Yc.ltr,n)})):Gc(0,Yc.ltr,n)}(0,n)},Kc=function(e,t){return Zc(e,t).match({ltr:function(t,n,r,o){var i=e.document.createRange();return i.setStart(t.dom,n),i.setEnd(r.dom,o),i},rtl:function(t,n,r,o){var i=e.document.createRange();return i.setStart(r.dom,o),i.setEnd(t.dom,n),i}})};Yc.ltr,Yc.rtl;var Jc,eu=function(e,t){var n=function(t){return e(t)?Q.from(t.dom.nodeValue):Q.none()};return{get:function(r){if(!e(r))throw new Error("Can only get "+t+" value of a "+t+" node");return n(r).getOr("")},getOption:n,set:function(n,r){if(!e(n))throw new Error("Can only set raw "+t+" value of a "+t+" node");n.dom.nodeValue=r}}}(Re,"text"),tu=function(e){return eu.getOption(e)},nu=["img","br"],ru=function(e){var t=tu(e).filter((function(e){return 0!==e.trim().length||e.indexOf(" ")>-1})).isSome();return t||R(nu,De(e))},ou=function(e,t){var n=function(e){for(var r=Vt(e),o=r.length-1;o>=0;o--){var i=r[o];if(t(i))return Q.some(i);var a=n(i);if(a.isSome())return a}return Q.none()};return n(e)},iu=function(e,t){return function(e,t){var n=void 0===t?document:t.dom;return At(n)?[]:U(n.querySelectorAll(e),Qe.fromDom)}(t,e)},au=function(e,t,n,r){var o=function(e,t,n,r){var o=wt(e).dom.createRange();return o.setStart(e.dom,t),o.setEnd(n.dom,r),o}(e,t,n,r),i=yt(e,n)&&t===r;return o.collapsed&&!i},lu=function(e){if(e.rangeCount>0){var t=e.getRangeAt(0),n=e.getRangeAt(e.rangeCount-1);return Q.some(Lc(Qe.fromDom(t.startContainer),t.startOffset,Qe.fromDom(n.endContainer),n.endOffset))}return Q.none()},su=function(e){if(null===e.anchorNode||null===e.focusNode)return lu(e);var t=Qe.fromDom(e.anchorNode),n=Qe.fromDom(e.focusNode);return au(t,e.anchorOffset,n,e.focusOffset)?Q.some(Lc(t,e.anchorOffset,n,e.focusOffset)):lu(e)},cu=function(e){return function(e){return Q.from(e.getSelection())}(e).filter((function(e){return e.rangeCount>0})).bind(su)},uu=function(e,t){return function(e){var t=e.getClientRects(),n=t.length>0?t[0]:e.getBoundingClientRect();return n.width>0||n.height>0?Q.some(n).map(Xc):Q.none()}(Kc(e,t))},du=function(e,t){return function(e){var t=e.getBoundingClientRect();return t.width>0||t.height>0?Q.some(t).map(Xc):Q.none()}(Kc(e,t))},fu=function(e,t){return{element:e,offset:t}},hu=function(e,t){var n=Vt(e);if(0===n.length)return fu(e,t);if(t"})),Tr()),qd=Xr("schema",(function(){return[io("preprocess")]})),Xd=ho("defaults",v({})),Yd=ho("overrides",v({})),Gd=Cr([Ud,Hd,Wd,jd,Xd,Yd]),Zd=Cr([Ud,Hd,Wd,Xd,Yd]),Kd=Cr([Ud,Hd,Wd,jd,Xd,Yd]),Jd=Cr([Ud,qd,Wd,Gr("unit"),jd,Xd,Yd]),ef=function(e){return e.fold(Q.some,Q.none,Q.some,Q.some)},tf=function(e){var t=function(e){return e.name};return e.fold(t,t,t,t)},nf=function(e,t){return function(n){var r=Hr("Converting part type",t,n);return e(r)}},rf=nf(Fd.required,Gd),of=nf(Fd.external,Zd),af=nf(Fd.optional,Kd),lf=nf(Fd.group,Jd),sf=v("entirety"),cf=Object.freeze({__proto__:null,required:rf,external:of,optional:af,group:lf,asNamedPart:ef,name:tf,asCommon:function(e){return e.fold(A,A,A,A)},original:sf}),uf=function(e,t,n,r){return sr(t.defaults(e,n,r),n,{uid:e.partUids[t.name]},t.overrides(e,n,r))},df=function(e,t){var n={};return H(t,(function(t){ef(t).each((function(t){var r=ff(e,t.pname);n[t.name]=function(n){var o=Hr("Part: "+t.name+" in "+e,Cr(t.schema),n);return k(k({},r),{config:n,validated:o})}}))})),n},ff=function(e,t){return{uiType:Ld(),owner:e,name:t}},hf=function(e,t,n){return{uiType:Ld(),owner:e,name:t,config:n,validated:{}}},pf=function(e){return K(e,(function(e){return e.fold(Q.none,Q.some,Q.none,Q.none).map((function(e){return no(e.name,e.schema.concat([Pl(sf())]))})).toArray()}))},mf=function(e){return U(e,tf)},gf=function(e,t,n){return function(e,t,n){var r={},o={};return H(n,(function(e){e.fold((function(e){r[e.pname]=Rd(!0,(function(t,n,r){return e.factory.sketch(uf(t,e,n,r))}))}),(function(e){var n=t.parts[e.name];o[e.name]=v(e.factory.sketch(uf(t,e,n[sf()]),n))}),(function(e){r[e.pname]=Rd(!1,(function(t,n,r){return e.factory.sketch(uf(t,e,n,r))}))}),(function(e){r[e.pname]=Id(!0,(function(t,n,r){var o=t[e.name];return U(o,(function(n){return e.factory.sketch(sr(e.defaults(t,n,r),n,e.overrides(t,n)))}))}))}))})),{internals:v(r),externals:v(o)}}(0,t,n)},vf=function(e,t,n){return zd(Q.some(e),t,t.components,n)},Af=function(e,t,n){var r=t.partUids[n];return e.getSystem().getByUid(r).toOptional()},yf=function(e,t,n){return Af(e,t,n).getOrDie("Could not find part: "+n)},bf=function(e,t,n){var r={},o=t.partUids,i=e.getSystem();return H(n,(function(e){r[e]=v(i.getByUid(o[e]))})),r},Of=function(e,t){var n=e.getSystem();return he(t.partUids,(function(e,t){return v(n.getByUid(e))}))},wf=function(e){return ue(e.partUids)},xf=function(e,t,n){var r={},o=t.partUids,i=e.getSystem();return H(n,(function(e){r[e]=v(i.getByUid(o[e]).getOrDie())})),r},_f=function(e,t){var n=mf(t);return So(U(n,(function(t){return{key:t,value:e+"-"+t}})))},Cf=function(e){return qr("partUids","partUids",fr((function(t){return _f(t.uid,e)})),Tr())},kf=Object.freeze({__proto__:null,generate:df,generateOne:hf,schemas:pf,names:mf,substitutes:gf,components:vf,defaultUids:_f,defaultUidsSchema:Cf,getAllParts:Of,getAllPartNames:wf,getPart:Af,getPartOrDie:yf,getParts:bf,getPartsOrDie:xf}),Sf=function(e,t,n,r,o){var i=function(e,t){return(e.length>0?[no("parts",e)]:[]).concat([Gr("uid"),ho("dom",{}),ho("components",[]),Pl("originalSpec"),ho("debug.sketcher",{})]).concat(t)}(r,o);return Hr(e+" [SpecSchema]",_r(i.concat(t)),n)},Vf=function(e,t,n,r,o){var i=Bf(o),a=pf(n),l=Cf(n),s=Sf(e,t,i,a,[l]),c=gf(0,s,n);return r(s,vf(e,s,c.internals()),i,c.externals())},Bf=function(e){return function(e){return be(e,"uid")}(e)?e:k(k({},e),{uid:fa("uid")})},Tf=_r([Gr("name"),Gr("factory"),Gr("configFields"),ho("apis",{}),ho("extraApis",{})]),Nf=_r([Gr("name"),Gr("factory"),Gr("configFields"),Gr("partFields"),ho("apis",{}),ho("extraApis",{})]),Ef=function(e){var t=Hr("Sketcher for "+e.name,Tf,e),n=he(t.apis,ba),r=he(t.extraApis,(function(e,t){return va(e,t)}));return k(k({name:t.name,configFields:t.configFields,sketch:function(e){return function(e,t,n,r){var o=Bf(r);return n(Sf(e,t,o,[],[]),o)}(t.name,t.configFields,t.factory,e)}},n),r)},Pf=function(e){var t=Hr("Sketcher for "+e.name,Nf,e),n=df(t.name,t.partFields),r=he(t.apis,ba),o=he(t.extraApis,(function(e,t){return va(e,t)}));return k(k({name:t.name,partFields:t.partFields,configFields:t.configFields,sketch:function(e){return Vf(t.name,t.configFields,t.partFields,t.factory,e)},parts:n},r),o)},Qf=function(e){return"input"===De(e)&&"radio"!==jt(e,"type")||"textarea"===De(e)},Mf=Object.freeze({__proto__:null,getCurrent:function(e,t,n){return t.find(e)}}),Df=[Gr("find")],$f=xs({fields:Df,name:"composing",apis:Mf}),zf=["input","button","textarea","select"],Rf=function(e,t,n){(t.disabled()?Wf:jf)(e,t)},If=function(e,t){return!0===t.useNative&&R(zf,De(e.element))},Lf=function(e){Ht(e.element,"disabled","disabled")},Ff=function(e){Yt(e.element,"disabled")},Uf=function(e){Ht(e.element,"aria-disabled","true")},Hf=function(e){Ht(e.element,"aria-disabled","false")},Wf=function(e,t,n){t.disableClass.each((function(t){za(e.element,t)})),(If(e,t)?Lf:Uf)(e),t.onDisabled(e)},jf=function(e,t,n){t.disableClass.each((function(t){Ia(e.element,t)})),(If(e,t)?Ff:Hf)(e),t.onEnabled(e)},qf=function(e,t){return If(e,t)?function(e){return Xt(e.element,"disabled")}(e):function(e){return"true"===jt(e.element,"aria-disabled")}(e)},Xf=Object.freeze({__proto__:null,enable:jf,disable:Wf,isDisabled:qf,onLoad:Rf,set:function(e,t,n,r){(r?Wf:jf)(e,t)}}),Yf=Object.freeze({__proto__:null,exhibit:function(e,t){return _a({classes:t.disabled()?t.disableClass.toArray():[]})},events:function(e,t){return Di([$i(ci(),(function(t,n){return qf(t,e)})),vs(e,t,Rf)])}}),Gf=[yo("disabled",x),ho("useNative",!0),io("disableClass"),Vl("onDisabled"),Vl("onEnabled")],Zf=xs({fields:Gf,name:"disabling",active:Yf,apis:Xf}),Kf=function(e,t,n,r){var o=iu(e.element,"."+t.highlightClass);H(o,(function(n){I(r,(function(e){return e.element===n}))||(Ia(n,t.highlightClass),e.getSystem().getByDom(n).each((function(n){t.onDehighlight(e,n),Ti(n,Bi())})))}))},Jf=function(e,t,n,r){Kf(e,t,0,[r]),eh(e,t,n,r)||(za(r.element,t.highlightClass),t.onHighlight(e,r),Ti(r,Vi()))},eh=function(e,t,n,r){return La(r.element,t.highlightClass)},th=function(e,t,n,r){var o=iu(e.element,"."+t.itemClass);return Q.from(o[r]).fold((function(){return Wn.error(new Error("No element found with index "+r))}),e.getSystem().getByDom)},nh=function(e,t,n){return ul(e.element,"."+t.itemClass).bind((function(t){return e.getSystem().getByDom(t).toOptional()}))},rh=function(e,t,n){var r=iu(e.element,"."+t.itemClass);return(r.length>0?Q.some(r[r.length-1]):Q.none()).bind((function(t){return e.getSystem().getByDom(t).toOptional()}))},oh=function(e,t,n,r){var o=iu(e.element,"."+t.itemClass),i=G(o,(function(e){return La(e,t.highlightClass)}));return i.bind((function(t){var n=Wl(t,r,0,o.length-1);return e.getSystem().getByDom(o[n]).toOptional()}))},ih=function(e,t,n){var r=iu(e.element,"."+t.itemClass);return xe(U(r,(function(t){return e.getSystem().getByDom(t).toOptional()})))},ah=Object.freeze({__proto__:null,dehighlightAll:function(e,t,n){return Kf(e,t,0,[])},dehighlight:function(e,t,n,r){eh(e,t,n,r)&&(Ia(r.element,t.highlightClass),t.onDehighlight(e,r),Ti(r,Bi()))},highlight:Jf,highlightFirst:function(e,t,n){nh(e,t).each((function(r){Jf(e,t,n,r)}))},highlightLast:function(e,t,n){rh(e,t).each((function(r){Jf(e,t,n,r)}))},highlightAt:function(e,t,n,r){th(e,t,n,r).fold((function(e){throw e}),(function(r){Jf(e,t,n,r)}))},highlightBy:function(e,t,n,r){var o=ih(e,t);Y(o,r).each((function(r){Jf(e,t,n,r)}))},isHighlighted:eh,getHighlighted:function(e,t,n){return ul(e.element,"."+t.highlightClass).bind((function(t){return e.getSystem().getByDom(t).toOptional()}))},getFirst:nh,getLast:rh,getPrevious:function(e,t,n){return oh(e,t,0,-1)},getNext:function(e,t,n){return oh(e,t,0,1)},getCandidates:ih}),lh=[Gr("highlightClass"),Gr("itemClass"),Vl("onHighlight"),Vl("onDehighlight")],sh=xs({fields:lh,name:"highlighting",apis:ah}),ch=[8],uh=[9],dh=[13],fh=[27],hh=[32],ph=[37],mh=[38],gh=[39],vh=[40],Ah=function(e,t,n){var r=ee(e.slice(0,t)),o=ee(e.slice(t+1));return Y(r.concat(o),n)},yh=function(e,t,n){var r=ee(e.slice(0,t));return Y(r,n)},bh=function(e,t,n){var r=e.slice(0,t),o=e.slice(t+1);return Y(o.concat(r),n)},Oh=function(e,t,n){var r=e.slice(t+1);return Y(r,n)},wh=function(e){return function(t){var n=t.raw;return R(e,n.which)}},xh=function(e){return function(t){return J(e,(function(e){return e(t)}))}},_h=function(e){return!0===e.raw.shiftKey},Ch=function(e){return!0===e.raw.ctrlKey},kh=O(_h),Sh=function(e,t){return{matches:e,classification:t}},Vh=function(e,t,n){t.exists((function(e){return n.exists((function(t){return yt(t,e)}))}))||Ni(e,_i(),{prevFocus:t,newFocus:n})},Bh=function(){var e=function(e){return Ps(e.element)};return{get:e,set:function(t,n){var r=e(t);t.getSystem().triggerFocus(n,t.element);var o=e(t);Vh(t,r,o)}}},Th=function(){var e=function(e){return sh.getHighlighted(e).map((function(e){return e.element}))};return{get:e,set:function(t,n){var r=e(t);t.getSystem().getByDom(n).fold(m,(function(e){sh.highlight(t,e)}));var o=e(t);Vh(t,r,o)}}};!function(e){e.OnFocusMode="onFocus",e.OnEnterOrSpaceMode="onEnterOrSpace",e.OnApiMode="onApi"}(Jc||(Jc={}));var Nh,Eh=function(e,t,n,r,o){var i=function(e,t,n,r,o){var i,a,l,s=n(e,t,r,o);return(i=s,a=t.event,l=Y(i,(function(e){return e.matches(a)})),l.map((function(e){return e.classification}))).bind((function(n){return n(e,t,r,o)}))},a={schema:function(){return e.concat([ho("focusManager",Bh()),po("focusInside","onFocus",Ir((function(e){return R(["onFocus","onEnterOrSpace","onApi"],e)?Wn.value(e):Wn.error("Invalid value for focusInside")}))),El("handler",a),El("state",t),El("sendFocusIn",o)])},processKey:i,toEvents:function(e,t){var a=e.focusInside!==Jc.OnFocusMode?Q.none():o(e).map((function(n){return Ri(ii(),(function(r,o){n(r,e,t),o.stop()}))})),l=[Ri(Xo(),(function(r,a){i(r,a,n,e,t).fold((function(){!function(n,r){var i=wh(hh.concat(dh))(r.event);e.focusInside===Jc.OnEnterOrSpaceMode&&i&&Eo(n,r)&&o(e).each((function(o){o(n,e,t),r.stop()}))}(r,a)}),(function(e){a.stop()}))})),Ri(Yo(),(function(n,o){i(n,o,r,e,t).each((function(e){o.stop()}))}))];return Di(a.toArray().concat(l))}};return a},Ph=function(e){var t=[io("onEscape"),io("onEnter"),ho("selector",'[data-alloy-tabstop="true"]:not(:disabled)'),ho("firstTabstop",0),ho("useTabstopAt",_),io("visibilitySelector")].concat([e]),n=function(e,t){var n=e.visibilitySelector.bind((function(e){return dl(t,e)})).getOr(t);return dn(n)>0},r=function(e,t,r){(function(e,t){var r=iu(e.element,t.selector),o=j(r,(function(e){return n(t,e)}));return Q.from(o[t.firstTabstop])})(e,t).each((function(n){t.focusManager.set(e,n)}))},o=function(e,t,r,o,i){return i(t,r,(function(e){return function(e,t){return n(e,t)&&e.useTabstopAt(t)}(o,e)})).fold((function(){return o.cyclic?Q.some(!0):Q.none()}),(function(t){return o.focusManager.set(e,t),Q.some(!0)}))},i=function(e,t,n,r){var i=iu(e.element,n.selector);return function(e,t){return t.focusManager.get(e).bind((function(e){return dl(e,t.selector)}))}(e,n).bind((function(t){return G(i,b(yt,t)).bind((function(t){return o(e,i,t,n,r)}))}))},a=v([Sh(xh([_h,wh(uh)]),(function(e,t,n){var r=n.cyclic?Ah:yh;return i(e,0,n,r)})),Sh(wh(uh),(function(e,t,n){var r=n.cyclic?bh:Oh;return i(e,0,n,r)})),Sh(wh(fh),(function(e,t,n){return n.onEscape.bind((function(n){return n(e,t)}))})),Sh(xh([kh,wh(dh)]),(function(e,t,n){return n.onEnter.bind((function(n){return n(e,t)}))}))]),l=v([]);return Eh(t,Oa.init,a,l,(function(){return Q.some(r)}))},Qh=Ph(Xr("cyclic",x)),Mh=Ph(Xr("cyclic",_)),Dh=function(e,t,n){return Qf(n)&&wh(hh)(t.event)?Q.none():function(e,t,n){return Pi(e,n,ci()),Q.some(!0)}(e,0,n)},$h=function(e,t){return Q.some(!0)},zh=[ho("execute",Dh),ho("useSpace",!1),ho("useEnter",!0),ho("useControlEnter",!1),ho("useDown",!1)],Rh=function(e,t,n){return n.execute(e,t,e.element)},Ih=Eh(zh,Oa.init,(function(e,t,n,r){var o=n.useSpace&&!Qf(e.element)?hh:[],i=n.useEnter?dh:[],a=n.useDown?vh:[],l=o.concat(i).concat(a);return[Sh(wh(l),Rh)].concat(n.useControlEnter?[Sh(xh([Ch,wh(dh)]),Rh)]:[])}),(function(e,t,n,r){return n.useSpace&&!Qf(e.element)?[Sh(wh(hh),$h)]:[]}),(function(){return Q.none()})),Lh=function(){var e=ec();return wa({readState:function(){return e.get().map((function(e){return{numRows:String(e.numRows),numColumns:String(e.numColumns)}})).getOr({numRows:"?",numColumns:"?"})},setGridSize:function(t,n){e.set({numRows:t,numColumns:n})},getNumRows:function(){return e.get().map((function(e){return e.numRows}))},getNumColumns:function(){return e.get().map((function(e){return e.numColumns}))}})},Fh=Object.freeze({__proto__:null,flatgrid:Lh,init:function(e){return e.state(e)}}),Uh=function(e){return function(t,n,r,o){var i=e(t.element);return qh(i,t,n,r,o)}},Hh=function(e,t){var n=wc(e,t);return Uh(n)},Wh=function(e,t){var n=wc(t,e);return Uh(n)},jh=function(e){return function(t,n,r,o){return qh(e,t,n,r,o)}},qh=function(e,t,n,r,o){return r.focusManager.get(t).bind((function(n){return e(t.element,n,r,o)})).map((function(e){return r.focusManager.set(t,e),!0}))},Xh=jh,Yh=jh,Gh=jh,Zh=function(e){return!function(e){return e.offsetWidth<=0&&e.offsetHeight<=0}(e.dom)},Kh=function(e,t,n){var r=iu(e,n);return function(e,t){return G(e,t).map((function(t){return{index:t,candidates:e}}))}(j(r,Zh),(function(e){return yt(e,t)}))},Jh=function(e,t){return G(e,(function(e){return yt(t,e)}))},ep=function(e,t,n,r){return r(Math.floor(t/n),t%n).bind((function(t){var r=t.row*n+t.column;return r>=0&&r1?Q.some(e.slice(1)):Q.none()}))},lookupMenu:l,lookupItem:s,otherMenus:function(e){var t=o.get();return te(ue(t),e)},getPrimary:function(){return r.get().bind(a)},getMenus:function(){return t.get()},clear:function(){e.set({}),t.set({}),n.set({}),r.clear()},isClear:function(){return r.get().isNone()},getTriggeringPath:function(e,t){var o=j(s(e).toArray(),(function(e){return a(e).isSome()}));return ye(n.get(),e).bind((function(e){var n=ee(o.concat(e));return function(e){for(var t=[],n=0;n0||t.timeout<0),a=function(){o(),Km.hide(s)},l=tl(Eg.sketch({text:t.text,level:R(["success","error","warning","warn","info"],t.type)?t.type:void 0,progress:!0===t.progressBar,icon:Q.from(t.icon),closeButton:!i,onAction:a,iconProvider:r.providers.icons,translationProvider:r.providers.translate})),s=tl(Km.sketch(k({dom:{tag:"div",classes:["tox-notifications-container"]},lazySink:r.getSink,fireDismissalEventInstead:{}},r.header.isPositionedAtTop()?{}:{fireRepositionEventInstead:{}})));n.add(s),t.timeout>0&&Ag.setTimeout((function(){a()}),t.timeout);var c=function(){var t=In(Qe.fromDom(e.getContentAreaContainer())),n=Fn(),r=jl(n.x,t.x,t.right),o=jl(n.y,t.y,t.bottom),i=Math.max(t.right,n.right),a=Math.max(t.bottom,n.bottom);return Q.some(Rn(r,o,i-r,a-o))};return{close:a,moveTo:function(e,t){Km.showAt(s,nl(l),{anchor:{type:"makeshift",x:e,y:t}})},moveRel:function(e,t){var n=nl(l),o={maxHeightFunction:mc()};if("banner"!==t&&d(e)){var i=function(e){switch(e){case"bc-bc":return dg;case"tc-tc":return ug;case"tc-bc":return is;default:return as}}(t),a={type:"node",root:Lt(),node:Q.some(Qe.fromDom(e)),overrides:o,layouts:{onRtl:function(){return[i]},onLtr:function(){return[i]}}};Km.showWithinBounds(s,n,{anchor:a},c)}else{var u=k(k({},r.anchors.banner()),{overrides:o});Km.showWithinBounds(s,n,{anchor:u},c)}},text:function(e){Eg.updateText(l,e)},settings:t,getEl:function(){return l.element.dom},progressBar:{value:function(e){Eg.updateProgress(l,e)}}}},close:function(e){e.close()},reposition:function(e){e.length>0&&H(e,(function(t,n){0===n?t.moveRel(null,"banner"):t.moveRel(e[n-1].getEl(),"bc-tc")}))},getArgs:function(e){return e.settings}}}var Qg,Mg=function(e,t){var n=null,r=function(){l(n)||(clearTimeout(n),n=null)};return{cancel:r,throttle:function(){for(var o=[],i=0;i',e.getDoc());return Sn(n,Qe.fromDom(t.extractContents())),t.insertNode(n.dom),kt(n).each((function(e){return e.dom.normalize()})),function(e){return ou(e,ru)}(n).map((function(t){e.selection.setCursorLocation(t.dom,function(e){return"img"===De(e)?1:tu(e).fold((function(){return Vt(e).length}),(function(e){return e.length}))}(t))})),n}))},Rg=function(e){return dl(e,"[data-mce-autocompleter]")},Ig=function(e){return e.toString().replace(/\u00A0/g," ").replace(/\uFEFF/g,"")},Lg=function(e){return""!==e&&-1!=="  \f\n\r\t\v".indexOf(e)},Fg=function(e,t){return e.substring(t.length)},Ug=function(e,t,n,r){if(void 0===r&&(r=0),!(o=t).collapsed||3!==o.startContainer.nodeType)return Q.none();var o,i=e.getParent(t.startContainer,e.isBlock)||e.getRoot();return $g(e,t.startContainer,t.startOffset,(function(e,t,r){return function(e,t,n){var r;for(r=t-1;r>=0;r--){var o=e.charAt(r);if(Lg(o))return Q.none();if(o===n)break}return Q.some(r)}(r,t,n).getOr(t)}),i).bind((function(e){var o=t.cloneRange();if(o.setStart(e.container,e.offset),o.setEnd(t.endContainer,t.endOffset),o.collapsed)return Q.none();var i=Ig(o);return 0!==i.lastIndexOf(n)||Fg(i,n).length0?Xg(t[t.length-1]):qg(e,t.length)},Yg=function(e,t){var n=e.childNodes;return n.length>0&&t0&&function(e){return 1===e.nodeType}(e)&&n.length===t?Xg(n[n.length-1]):qg(e,t)},Gg=function(e){return function(t){var n=Yg(t.startContainer,t.startOffset);return!function(e,t){return $g(e,t.container,t.offset,(function(e,t){return 0===t?-1:t}),e.getRoot()).filter((function(e){var t=e.container.data.charAt(e.offset-1);return!Lg(t)})).isSome()}(e,n)}},Zg=function(e,t){var n=t(),r=e.selection.getRng();return function(e,t,n){return ce(n.triggerChars,(function(n){return Hg(e,t,n)}))}(e.dom,r,n).bind((function(n){return Kg(e,t,n)}))},Kg=function(e,t,n,r){void 0===r&&(r={});var o=t(),i=e.selection.getRng().startContainer.nodeValue,a=j(o.lookupByChar(n.triggerChar),(function(t){return n.text.length>=t.minChars&&t.matches.getOrThunk((function(){return Gg(e.dom)}))(n.range,i,n.text)}));if(0===a.length)return Q.none();var l=jg.all(U(a,(function(e){return e.fetch(n.text,e.maxResults,r).then((function(t){return{matchText:n.text,items:t,columns:e.columns,onAction:e.onAction,highlightOn:e.highlightOn}}))})));return Q.some({lookupData:l,context:n})},Jg=Cr([Jr("type"),so("text")]),ev=Cr([ho("type","autocompleteitem"),ho("active",!1),ho("disabled",!1),ho("meta",{}),Jr("value"),so("text"),so("icon")]),tv=Cr([Jr("type"),Jr("ch"),mo("minChars",1),ho("columns",1),mo("maxResults",10),co("matches"),to("fetch"),to("onAction"),bo("highlightOn",[],Pr)]),nv=[Ao("disabled",!1),so("tooltip"),so("icon"),so("text"),yo("onSetup",(function(){return m}))],rv=Cr([Jr("type"),to("onAction")].concat(nv)),ov=function(e){return Fr("toolbarbutton",rv,e)},iv=[Ao("active",!1)].concat(nv),av=Cr(iv.concat([Jr("type"),to("onAction")])),lv=function(e){return Fr("ToggleButton",av,e)},sv=[yo("predicate",x),vo("scope","node",["node","editor"]),vo("position","selection",["node","selection","line"])],cv=nv.concat([ho("type","contextformbutton"),ho("primary",!1),to("onAction"),Xr("original",A)]),uv=iv.concat([ho("type","contextformbutton"),ho("primary",!1),to("onAction"),Xr("original",A)]),dv=nv.concat([ho("type","contextformbutton")]),fv=iv.concat([ho("type","contextformtogglebutton")]),hv=jr("type",{contextformbutton:cv,contextformtogglebutton:uv}),pv=Cr([ho("type","contextform"),yo("initValue",v("")),so("label"),oo("commands",hv),ao("launch",jr("type",{contextformbutton:dv,contextformtogglebutton:fv}))].concat(sv)),mv=Cr([ho("type","contexttoolbar"),Jr("items")].concat(sv)),gv=function(e){var t=e.ui.registry.getAll().popups,n=he(t,(function(e){return(t=e,Fr("Autocompleter",tv,t)).fold((function(e){throw new Error(Wr(e))}),A);var t})),r=function(e){var t={};return H(e,(function(e){t[e]={}})),ue(t)}(ge(n,(function(e){return e.ch}))),o=Ae(n);return{dataset:n,triggerChars:r,lookupByChar:function(e){return j(o,(function(t){return t.ch===e}))}}};!function(e){e[e.CLOSE_ON_EXECUTE=0]="CLOSE_ON_EXECUTE",e[e.BUBBLE_TO_SANDBOX=1]="BUBBLE_TO_SANDBOX"}(Qg||(Qg={}));var vv,Av=Qg,yv="tox-menu-nav__js",bv="tox-collection__item",Ov="tox-swatch",wv={normal:yv,color:Ov},xv="tox-collection__item--enabled",_v="tox-collection__item-icon",Cv="tox-collection__item-label",kv="tox-collection__item-caret",Sv="tox-collection__item--active",Vv="tox-collection__item-container",Bv="tox-collection__item-container--row",Tv=function(e){return ye(wv,e).getOr(yv)},Nv=function(e){return"color"===e?"tox-swatches":"tox-menu"},Ev=function(e){return{backgroundMenu:"tox-background-menu",selectedMenu:"tox-selected-menu",selectedItem:"tox-collection__item--active",hasIcons:"tox-menu--has-icons",menu:Nv(e),tieredMenu:"tox-tiered-menu"}},Pv=function(e){var t=Ev(e);return{backgroundMenu:t.backgroundMenu,selectedMenu:t.selectedMenu,menu:t.menu,selectedItem:t.selectedItem,item:Tv(e)}},Qv=function(e,t,n){var r=Ev(n);return{tag:"div",classes:Z([[r.menu,"tox-menu-"+t+"-column"],e?[r.hasIcons]:[]])}},Mv=[Wm.parts.items({})],Dv=function(e,t,n){var r=Ev(n);return{dom:{tag:"div",classes:Z([[r.tieredMenu]])},markers:Pv(n)}},$v=function(e,t){return function(n){var r=F(n,t);return U(r,(function(t){return{dom:e,components:t}}))}},zv=function(e,t){var n=[],r=[];return H(e,(function(e,o){t(e,o)?(r.length>0&&n.push(r),r=[],be(e.dom,"innerHtml")&&r.push(e)):r.push(e)})),r.length>0&&n.push(r),U(n,(function(e){return{dom:{tag:"div",classes:["tox-collection__group"]},components:e}}))},Rv=function(e,t,n){return{dom:{tag:"div",classes:["tox-menu","tox-collection"].concat(1===e?["tox-collection--list"]:["tox-collection--grid"])},components:[Wm.parts.items({preprocess:function(n){return"auto"!==e&&e>1?$v({tag:"div",classes:["tox-collection__group"]},e)(n):zv(n,(function(e,n){return"separator"===t[n].type}))}})]}},Iv=function(e){return I(e,(function(e){return"icon"in e&&void 0!==e.icon}))},Lv=function(e){return Q.none()},Fv=function(e,t,n,r,o){var i,a=(i=n,{dom:{tag:"div",classes:["tox-collection","tox-collection--horizontal"]},components:[Wm.parts.items({preprocess:function(e){return zv(e,(function(e,t){return"separator"===i[t].type}))}})]});return{value:e,dom:a.dom,components:a.components,items:n}},Uv=function(e,t,n,r,o){if("color"===o){var i=function(e){return{dom:{tag:"div",classes:["tox-menu","tox-swatches-menu"]},components:[{dom:{tag:"div",classes:["tox-swatches"]},components:[Wm.parts.items({preprocess:"auto"!==e?$v({tag:"div",classes:["tox-swatches__row"]},e):A})]}]}}(r);return{value:e,dom:i.dom,components:i.components,items:n}}if("normal"===o&&"auto"===r)return{value:e,dom:(i=Rv(r,n)).dom,components:i.components,items:n};if("normal"===o&&1===r)return{value:e,dom:(i=Rv(1,n)).dom,components:i.components,items:n};if("normal"===o)return{value:e,dom:(i=Rv(r,n)).dom,components:i.components,items:n};if("listpreview"===o&&"auto"!==r){i=function(e){return{dom:{tag:"div",classes:["tox-menu","tox-collection","tox-collection--toolbar","tox-collection--toolbar-lg"]},components:[Wm.parts.items({preprocess:$v({tag:"div",classes:["tox-collection__group"]},e)})]}}(r);return{value:e,dom:i.dom,components:i.components,items:n}}return{value:e,dom:Qv(t,r,o),components:Mv,items:n}},Hv=[Jr("type"),Jr("src"),so("alt"),bo("classes",[],Pr)],Wv=Cr(Hv),jv=[Jr("type"),Jr("text"),so("name"),bo("classes",["tox-collection__item-label"],Pr)],qv=Cr(jv),Xv=wr((function(){return Rr("type",{cardimage:Wv,cardtext:qv,cardcontainer:Yv})})),Yv=Cr([Jr("type"),go("direction","horizontal"),go("align","left"),go("valign","middle"),oo("items",Xv)]),Gv=[Ao("disabled",!1),so("text"),so("shortcut"),qr("value","value",ur((function(){return ia("menuitem-value")})),Tr()),ho("meta",{})],Zv=Cr([Jr("type"),so("label"),oo("items",Xv),yo("onSetup",(function(){return m})),yo("onAction",m)].concat(Gv)),Kv=Cr([Jr("type"),Ao("active",!1),so("icon")].concat(Gv)),Jv=[Jr("type"),Jr("fancytype"),yo("onAction",m)],eA=[ho("initData",{})].concat(Jv),tA=[Oo("initData",{},[Ao("allowCustomColors",!0),uo("colors",Tr())])].concat(Jv),nA=jr("fancytype",{inserttable:eA,colorswatch:tA}),rA=Cr([Jr("type"),yo("onSetup",(function(){return m})),yo("onAction",m),so("icon")].concat(Gv)),oA=Cr([Jr("type"),to("getSubmenuItems"),yo("onSetup",(function(){return m})),so("icon")].concat(Gv)),iA=Cr([Jr("type"),so("icon"),Ao("active",!1),yo("onSetup",(function(){return m})),to("onAction")].concat(Gv)),aA=function(e,t,n){var r=iu(e.element,"."+n);if(r.length>0){var o=G(r,(function(e){var n=e.dom.getBoundingClientRect().top,o=r[0].dom.getBoundingClientRect().top;return Math.abs(n-o)>t})).getOr(r.length);return Q.some({numColumns:o,numRows:Math.ceil(r.length/o)})}return Q.none()},lA=function(e,t){return Os([um(e,t)])},sA=function(e){return lA(ia("unnamed-events"),e)},cA=ia("tooltip.exclusive"),uA=ia("tooltip.show"),dA=ia("tooltip.hide"),fA=function(e,t,n){e.getSystem().broadcastOn([cA],{})},hA=Object.freeze({__proto__:null,hideAllExclusive:fA,setComponents:function(e,t,n,r){n.getTooltip().each((function(e){e.getSystem().isConnected()&&cm.set(e,r)}))}}),pA=Object.freeze({__proto__:null,events:function(e,t){var n=function(n){t.getTooltip().each((function(r){ju(r),e.onHide(n,r),t.clearTooltip()})),t.clearTimer()};return Di(Z([[Ri(uA,(function(n){t.resetTimer((function(){!function(n){if(!t.isShowing()){fA(n);var r=e.lazySink(n).getOrDie(),o=n.getSystem().build({dom:e.tooltipDom,components:e.tooltipComponents,events:Di("normal"===e.mode?[Ri(Wo(),(function(e){Ti(n,uA)})),Ri(Uo(),(function(e){Ti(n,dA)}))]:[]),behaviours:Os([cm.config({})])});t.setTooltip(o),Uu(r,o),e.onShow(n,o),zu.position(r,o,{anchor:e.anchor(n)})}}(n)}),e.delay)})),Ri(dA,(function(r){t.resetTimer((function(){n(r)}),e.delay)})),Ri(si(),(function(e,t){var r=t;r.universal||R(r.channels,cA)&&n(e)})),Xi((function(e){n(e)}))],"normal"===e.mode?[Ri(jo(),(function(e){Ti(e,uA)})),Ri(ai(),(function(e){Ti(e,dA)})),Ri(Wo(),(function(e){Ti(e,uA)})),Ri(Uo(),(function(e){Ti(e,dA)}))]:[Ri(Vi(),(function(e,t){Ti(e,uA)})),Ri(Bi(),(function(e){Ti(e,dA)}))]]))}}),mA=[Gr("lazySink"),Gr("tooltipDom"),ho("exclusive",!0),ho("tooltipComponents",[]),ho("delay",300),vo("mode","normal",["normal","follow-highlight"]),ho("anchor",(function(e){return{type:"hotspot",hotspot:e,layouts:{onLtr:v([as,is,ts,rs,ns,os]),onRtl:v([as,is,ts,rs,ns,os])}}})),Vl("onHide"),Vl("onShow")],gA=xs({fields:mA,name:"tooltipping",active:pA,state:Object.freeze({__proto__:null,init:function(){var e=ec(),t=ec(),n=function(){e.on(clearTimeout)},r=v("not-implemented");return wa({getTooltip:t.get,isShowing:t.isSet,setTooltip:t.set,clearTooltip:t.clear,clearTimer:n,resetTimer:function(t,r){n(),e.set(setTimeout(t,r))},readState:r})}}),apis:hA}),vA=tinymce.util.Tools.resolve("tinymce.dom.DOMUtils"),AA=tinymce.util.Tools.resolve("tinymce.EditorManager"),yA=function(e){return e.getParam("height",Math.max(e.getElement().offsetHeight,200))},bA=function(e){return e.getParam("width",vA.DOM.getStyle(e.getElement(),"width"))},OA=function(e){return Q.from(e.getParam("min_width")).filter(h)},wA=function(e){return Q.from(e.getParam("min_height")).filter(h)},xA=function(e){return Q.from(e.getParam("max_width")).filter(h)},_A=function(e){return Q.from(e.getParam("max_height")).filter(h)},CA=function(e){return!1!==e.getParam("menubar",!0,"boolean")},kA=function(e){var t=e.getParam("toolbar",!0),n=!0===t,r=o(t),i=a(t)&&t.length>0;return!VA(e)&&(i||r||n)},SA=function(e){var t=L(9,(function(t){return e.getParam("toolbar"+(t+1),!1,"string")})),n=j(t,(function(e){return"string"==typeof e}));return n.length>0?Q.some(n):Q.none()},VA=function(e){return SA(e).fold((function(){return e.getParam("toolbar",[],"string[]").length>0}),_)};!function(e){e.default="wrap",e.floating="floating",e.sliding="sliding",e.scrolling="scrolling"}(vv||(vv={}));var BA,TA=function(e){return e.getParam("toolbar_mode","","string")};!function(e){e.auto="auto",e.top="top",e.bottom="bottom"}(BA||(BA={}));var NA,EA,PA=function(e){return e.getParam("toolbar_location",BA.auto,"string")},QA=function(e){return PA(e)===BA.bottom},MA=function(e){if(!e.inline)return Q.none();var t=function(e){return e.getParam("fixed_toolbar_container","","string")}(e);if(t.length>0)return ul(Lt(),t);var n=function(e){return e.getParam("fixed_toolbar_container_target")}(e);return d(n)?Q.some(Qe.fromDom(n)):Q.none()},DA=function(e){return e.inline&&MA(e).isSome()},$A=function(e){return MA(e).getOrThunk((function(){return Dt(Mt(Qe.fromDom(e.getElement())))}))},zA=function(e){return e.inline&&!CA(e)&&!kA(e)&&!VA(e)},RA=function(e){return(e.getParam("toolbar_sticky",!1,"boolean")||e.inline)&&!DA(e)&&!zA(e)},IA=function(e){var t=e.getParam("menu");return t?he(t,(function(e){return k(k({},e),{items:e.items})})):{}},LA=function(e){return e.getParam("menubar")},FA=function(e){return e.getParam("anchor_top","#top")},UA=function(e){return e.getParam("anchor_bottom","#bottom")},HA="silver.readonly",WA=Cr([(NA="readonly",Zr(NA,Qr))]),jA=function(e,t){var n=e.outerContainer.element;t&&(e.mothership.broadcastOn([sd()],{target:n}),e.uiMothership.broadcastOn([sd()],{target:n})),e.mothership.broadcastOn([HA],{readonly:t}),e.uiMothership.broadcastOn([HA],{readonly:t})},qA=function(e,t){e.on("init",(function(){e.mode.isReadOnly()&&jA(t,!0)})),e.on("SwitchMode",(function(){return jA(t,e.mode.isReadOnly())})),function(e){return e.getParam("readonly",!1,"boolean")}(e)&&e.setMode("readonly")},XA=function(){var e;return Ss.config({channels:(e={},e[HA]={schema:WA,onReceive:function(e,t){Zf.set(e,t.readonly)}},e)})},YA=function(e){return Zf.config({disabled:e,disableClass:"tox-collection__item--state-disabled"})},GA=function(e){return Zf.config({disabled:e})},ZA=function(e){return Zf.config({disabled:e,disableClass:"tox-tbtn--disabled"})},KA=function(e){return Zf.config({disabled:e,disableClass:"tox-tbtn--disabled",useNative:!1})},JA=function(e,t){var n=e.getApi(t);return function(e){e(n)}},ey=function(e,t){return qi((function(n){JA(e,n)((function(n){var r=e.onSetup(n);f(r)&&t.set(r)}))}))},ty=function(e,t){return Xi((function(n){return JA(e,n)(t.get())}))},ny=function(e,t){return Gi((function(n,r){JA(e,n)(e.onAction),e.triggersSubmenu||t!==Av.CLOSE_ON_EXECUTE||(Ti(n,hi()),r.stop())}))},ry=((EA={})[ci()]=["disabling","alloy.base.behaviour","toggling","item-events"],EA),oy=xe,iy=function(e,t,n,r){var o=wo(m);return{type:"item",dom:t.dom,components:oy(t.optComponents),data:e.data,eventOrder:ry,hasSubmenu:e.triggersSubmenu,itemBehaviours:Os([um("item-events",[ny(e,n),ey(e,o),ty(e,o)]),YA((function(){return e.disabled||r.isDisabled()})),XA(),cm.config({})].concat(e.itemBehaviours))}},ay=function(e){return{value:e.value,meta:k({text:e.text.getOr("")},e.meta)}},ly=tinymce.util.Tools.resolve("tinymce.Env"),sy=function(e){var t=ly.mac?{alt:"⌥",ctrl:"⌃",shift:"⇧",meta:"⌘",access:"⌃⌥"}:{meta:"Ctrl",access:"Shift+Alt"},n=e.split("+"),r=U(n,(function(e){var n=e.toLowerCase().trim();return be(t,n)?t[n]:e}));return ly.mac?r.join(""):r.join("+")},cy=function(e,t,n){return void 0===n&&(n=[_v]),Tg(e,{tag:"div",classes:n},t)},uy=function(e){return{dom:{tag:"div",classes:[Cv]},components:[Ka(Og.translate(e))]}},dy=function(e,t){return{dom:{tag:"div",classes:t,innerHtml:e}}},fy=function(e,t){return{dom:{tag:"div",classes:[Cv]},components:[{dom:{tag:e.tag,styles:e.styles},components:[Ka(Og.translate(t))]}]}},hy=function(e){return{dom:{tag:"div",classes:["tox-collection__item-accessory"],innerHtml:sy(e)}}},py=function(e){return cy("checkmark",e,["tox-collection__item-checkmark"])},my=function(e,t,n){var r,o,i,a,l=e.ariaLabel,s=e.value,c=e.iconContent.map((function(e){return function(e,t,n){var r=t();return kg(e,r).or(n).getOrThunk(_g(r))}(e,t.icons,n)}));return{dom:(r=Ov,o=c.getOr(""),i=l.map((function(e){return{title:t.translate(e)}})).getOr({}),a={tag:"div",attributes:i,classes:[r]},k(k({},a),"custom"===s?{tag:"button",classes:V(V([],a.classes,!0),["tox-swatches__picker-btn"],!1),innerHtml:o}:"remove"===s?{classes:V(V([],a.classes,!0),["tox-swatch--remove"],!1),innerHtml:o}:{attributes:k(k({},a.attributes),{"data-mce-color":s}),styles:{"background-color":s}})),optComponents:[]}},gy=function(e){var t=e.map((function(e){return{attributes:{title:Og.translate(e)}}})).getOr({});return k({tag:"div",classes:[yv,bv]},t)},vy=function(e,t,n,r){return void 0===r&&(r=Q.none()),"color"===e.presets?my(e,t,r):function(e,t,n,r){var o={tag:"div",classes:[_v]},i=n?e.iconContent.map((function(e){return Tg(e,o,t.icons,r)})).orThunk((function(){return Q.some({dom:o})})):Q.none(),a=e.checkMark,l=Q.from(e.meta).fold((function(){return uy}),(function(e){return be(e,"style")?b(fy,e.style):uy})),s=e.htmlContent.fold((function(){return e.textContent.map(l)}),(function(e){return Q.some(dy(e,[Cv]))}));return{dom:gy(e.ariaLabel),optComponents:[i,s,e.shortcutContent.map(hy),a,e.caret]}}(e,t,n,r)},Ay=function(e,t){return ye(e,"tooltipWorker").map((function(e){return[gA.config({lazySink:t.getSink,tooltipDom:{tag:"div",classes:["tox-tooltip-worker-container"]},tooltipComponents:[],anchor:function(e){return{type:"submenu",item:e,overrides:{maxHeightFunction:mc}}},mode:"follow-highlight",onShow:function(t,n){e((function(e){gA.setComponents(t,[Ja({element:Qe.fromDom(e)})])}))}})]})).getOr([])},yy=function(e,t){var n=function(e){return vA.DOM.encode(e)}(Og.translate(e));if(t.length>0){var r=new RegExp(function(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}(t),"gi");return n.replace(r,(function(e){return''+e+""}))}return n},by=function(e,t){return U(e,(function(e){switch(e.type){case"cardcontainer":return function(e,t){var n="vertical"===e.direction?"tox-collection__item-container--column":Bv,r="left"===e.align?"tox-collection__item-container--align-left":"tox-collection__item-container--align-right";return{dom:{tag:"div",classes:[Vv,n,r,function(){switch(e.valign){case"top":return"tox-collection__item-container--valign-top";case"middle":return"tox-collection__item-container--valign-middle";case"bottom":return"tox-collection__item-container--valign-bottom"}}()]},components:t}}(e,by(e.items,t));case"cardimage":return function(e,t,n){return{dom:{tag:"img",classes:t,attributes:{src:e,alt:n.getOr("")}}}}(e.src,e.classes,e.alt);case"cardtext":var n=e.name.exists((function(e){return R(t.cardText.highlightOn,e)})),r=n?Q.from(t.cardText.matchText).getOr(""):"";return dy(yy(e.text,r),e.classes)}}))},Oy=df(zm(),Rm()),wy=function(e){return{value:e}},xy=/^#?([a-f\d])([a-f\d])([a-f\d])$/i,_y=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i,Cy=function(e){return xy.test(e)||_y.test(e)},ky=function(e){return function(e,t){return Ve(e,t)?function(e,t){return e.substring(t)}(e,t.length):e}(e,"#").toUpperCase()},Sy=function(e){var t=function(e){var t=e.value.replace(xy,(function(e,t,n,r){return t+t+n+n+r+r}));return{value:t}}(e),n=_y.exec(t.value);return null===n?["FFFFFF","FF","FF","FF"]:n},Vy=function(e){var t=e.toString(16);return(1===t.length?"0"+t:t).toUpperCase()},By=function(e){var t=Vy(e.red)+Vy(e.green)+Vy(e.blue);return wy(t)},Ty=Math.min,Ny=Math.max,Ey=Math.round,Py=/^rgb\((\d+),\s*(\d+),\s*(\d+)\)/,Qy=/^rgba\((\d+),\s*(\d+),\s*(\d+),\s*(\d?(?:\.\d+)?)\)/,My=function(e,t,n,r){return{red:e,green:t,blue:n,alpha:r}},Dy=function(e){var t=parseInt(e,10);return t.toString()===e&&t>=0&&t<=255},$y=function(e){var t,n,r,o=(e.hue||0)%360,i=e.saturation/100,a=e.value/100;if(i=Ny(0,Ty(i,1)),a=Ny(0,Ty(a,1)),0===i)return t=n=r=Ey(255*a),My(t,n,r,1);var l=o/60,s=a*i,c=s*(1-Math.abs(l%2-1)),u=a-s;switch(Math.floor(l)){case 0:t=s,n=c,r=0;break;case 1:t=c,n=s,r=0;break;case 2:t=0,n=s,r=c;break;case 3:t=0,n=c,r=s;break;case 4:t=c,n=0,r=s;break;case 5:t=s,n=0,r=c;break;default:t=n=r=0}return t=Ey(255*(t+u)),n=Ey(255*(n+u)),r=Ey(255*(r+u)),My(t,n,r,1)},zy=function(e){var t=Sy(e),n=parseInt(t[1],16),r=parseInt(t[2],16),o=parseInt(t[3],16);return My(n,r,o,1)},Ry=function(e,t,n,r){var o=parseInt(e,10),i=parseInt(t,10),a=parseInt(n,10),l=parseFloat(r);return My(o,i,a,l)},Iy=function(e){if("transparent"===e)return Q.some(My(0,0,0,0));var t=Py.exec(e);if(null!==t)return Q.some(Ry(t[1],t[2],t[3],"1"));var n=Qy.exec(e);return null!==n?Q.some(Ry(n[1],n[2],n[3],n[4])):Q.none()},Ly=function(e){return"rgba("+e.red+","+e.green+","+e.blue+","+e.alpha+")"},Fy=My(255,0,0,1),Uy=function(e,t){return e.fire("ResizeContent",t)},Hy=function(e,t,n){return{hue:e,saturation:t,value:n}},Wy=function(e){var t,n=0,r=0,o=e.red/255,i=e.green/255,a=e.blue/255,l=Math.min(o,Math.min(i,a)),s=Math.max(o,Math.max(i,a));return l===s?Hy(0,0,100*(r=l)):(n=60*((n=o===l?3:a===l?1:5)-(o===l?i-a:a===l?o-i:a-o)/(s-l)),t=(s-l)/s,r=s,Hy(Math.round(n),Math.round(100*t),Math.round(100*r)))},jy=function(e){return By($y(e))},qy=function(e){return(t=e,Cy(t)?Q.some({value:ky(t)}):Q.none()).orThunk((function(){return Iy(e).map(By)})).getOrThunk((function(){var t=document.createElement("canvas");t.height=1,t.width=1;var n=t.getContext("2d");n.clearRect(0,0,t.width,t.height),n.fillStyle="#FFFFFF",n.fillStyle=e,n.fillRect(0,0,1,1);var r=n.getImageData(0,0,1,1).data,o=r[0],i=r[1],a=r[2],l=r[3];return By(My(o,i,a,l))}));var t},Xy=tinymce.util.Tools.resolve("tinymce.util.LocalStorage"),Yy="tinymce-custom-colors";var Gy,Zy="choiceitem",Ky=[{type:Zy,text:"Light Green",value:"#BFEDD2"},{type:Zy,text:"Light Yellow",value:"#FBEEB8"},{type:Zy,text:"Light Red",value:"#F8CAC6"},{type:Zy,text:"Light Purple",value:"#ECCAFA"},{type:Zy,text:"Light Blue",value:"#C2E0F4"},{type:Zy,text:"Green",value:"#2DC26B"},{type:Zy,text:"Yellow",value:"#F1C40F"},{type:Zy,text:"Red",value:"#E03E2D"},{type:Zy,text:"Purple",value:"#B96AD9"},{type:Zy,text:"Blue",value:"#3598DB"},{type:Zy,text:"Dark Turquoise",value:"#169179"},{type:Zy,text:"Orange",value:"#E67E23"},{type:Zy,text:"Dark Red",value:"#BA372A"},{type:Zy,text:"Dark Purple",value:"#843FA1"},{type:Zy,text:"Dark Blue",value:"#236FA1"},{type:Zy,text:"Light Gray",value:"#ECF0F1"},{type:Zy,text:"Medium Gray",value:"#CED4D9"},{type:Zy,text:"Gray",value:"#95A5A6"},{type:Zy,text:"Dark Gray",value:"#7E8C8D"},{type:Zy,text:"Navy Blue",value:"#34495E"},{type:Zy,text:"Black",value:"#000000"},{type:Zy,text:"White",value:"#ffffff"}],Jy=function(e){void 0===e&&(e=10);var t,n=Xy.getItem(Yy),r=o(n)?JSON.parse(n):[],i=e-(t=r).length<0?t.slice(0,e):t,a=function(e){i.splice(e,1)};return{add:function(t){(function(e,t){var n=z(e,t);return-1===n?Q.none():Q.some(n)})(i,t).each(a),i.unshift(t),i.length>e&&i.pop(),Xy.setItem(Yy,JSON.stringify(i))},state:function(){return i.slice(0)}}}(10),eb=function(e){return!1!==e.getParam("custom_colors")},tb=function(e){var t=function(e){return e.getParam("color_map")}(e);return void 0!==t?function(e){for(var t=[],n=0;n0?c(n,h,i,p):h.text.length-n.matchLength>=10?l():a()}}))}))}))},d={onKeypress:Mg((function(e){27!==e.which&&u()}),50),cancelIfNecessary:l,isMenuOpen:function(){return Km.isOpen(o)},isActive:i,isProcessingAction:r.get,getView:function(){return Km.getContent(o)}};!1===e.hasPlugin("rtc")&&Wg(d,e)},Mb=function(e,t,n){return dl(e,t,n).isSome()},Db=function(e,t){var n=null;return{cancel:function(){null!==n&&(clearTimeout(n),n=null)},schedule:function(){for(var r=[],o=0;o5||r>5})(e,n)&&t.clear()}))})),Q.none()}},{key:Ro(),value:function(o){r.cancel();return t.get().filter((function(e){return yt(e.target,o.target)})).map((function(t){return n.get()?(o.prevent(),!1):e.triggerEvent(di(),o)}))}}]);return{fireIfReady:function(e,t){return ye(o,t).bind((function(t){return t(e)}))}}},Rb=function(){return gt().browser.isFirefox()},Ib=function(e,t){var n=k({stopBackspace:!0},t),r=zb(n),o=U(["touchstart","touchmove","touchend","touchcancel","gesturestart","mousedown","mouseup","mouseover","mousemove","mouseout","click"].concat(["selectstart","input","contextmenu","change","transitionend","transitioncancel","drag","dragstart","dragend","dragenter","dragleave","dragover","drop","keyup"]),(function(t){return nc(e,t,(function(e){r.fireIfReady(e,t).each((function(t){t&&e.kill()})),n.triggerEvent(t,e)&&e.kill()}))})),i=ec(),a=nc(e,"paste",(function(e){r.fireIfReady(e,"paste").each((function(t){t&&e.kill()})),n.triggerEvent("paste",e)&&e.kill(),i.set(setTimeout((function(){n.triggerEvent(li(),e)}),0))})),l=nc(e,"keydown",(function(e){n.triggerEvent("keydown",e)?e.kill():n.stopBackspace&&function(e){return e.raw.which===ch[0]&&!R(["input","textarea"],De(e.target))&&!Mb(e.target,'[contenteditable="true"]')}(e)&&e.prevent()})),s=function(e,t){return Rb()?rc(e,"focus",t):nc(e,"focusin",t)}(e,(function(e){n.triggerEvent("focusin",e)&&e.kill()})),c=ec(),u=function(e,t){return Rb()?rc(e,"blur",t):nc(e,"focusout",t)}(e,(function(e){n.triggerEvent("focusout",e)&&e.kill(),c.set(setTimeout((function(){n.triggerEvent(ai(),e)}),0))}));return{unbind:function(){H(o,(function(e){e.unbind()})),l.unbind(),s.unbind(),u.unbind(),a.unbind(),i.on(clearTimeout),c.on(clearTimeout)}}},Lb=function(e,t){var n=ye(e,"target").getOr(t);return wo(n)},Fb=xo([{stopped:[]},{resume:["element"]},{complete:[]}]),Ub=function(e,t,n,r,o,i){var a=e(t,r),l=function(e,t){var n=wo(!1),r=wo(!1);return{stop:function(){n.set(!0)},cut:function(){r.set(!0)},isStopped:n.get,isCut:r.get,event:e,setSource:t.set,getSource:t.get}}(n,o);return a.fold((function(){return i.logEventNoHandlers(t,r),Fb.complete()}),(function(e){var n=e.descHandler;return Ca(n)(l),l.isStopped()?(i.logEventStopped(t,e.element,n.purpose),Fb.stopped()):l.isCut()?(i.logEventCut(t,e.element,n.purpose),Fb.complete()):kt(e.element).fold((function(){return i.logNoParent(t,e.element,n.purpose),Fb.complete()}),(function(r){return i.logEventResponse(t,e.element,n.purpose),Fb.resume(r)}))}))},Hb=function(e,t,n,r,o,i){return Ub(e,t,n,r,o,i).fold(_,(function(r){return Hb(e,t,n,r,o,i)}),x)},Wb=function(e,t,n){var r=function(e){var t=wo(!1);return{stop:function(){t.set(!0)},cut:m,isStopped:t.get,isCut:x,event:e,setSource:w("Cannot set source of a broadcasted event"),getSource:w("Cannot get source of a broadcasted event")}}(t);return H(e,(function(e){var t=e.descHandler;Ca(t)(r)})),r.isStopped()},jb=function(e,t,n,r,o){var i=Lb(n,r);return Hb(e,t,n,r,i,o)},qb=function(){var e={};return{registerId:function(t,n,r){fe(r,(function(r,o){var i=void 0!==e[o]?e[o]:{};i[n]=function(e,t){return n=b.apply(void 0,[e.handler].concat(t)),r=e.purpose,{cHandler:n,purpose:r};var n,r}(r,t),e[o]=i}))},unregisterId:function(t){fe(e,(function(e,n){be(e,t)&&delete e[t]}))},filterByType:function(t){return ye(e,t).map((function(e){return ge(e,(function(e,t){return function(e,t){return{id:e,descHandler:t}}(t,e)}))})).getOr([])},find:function(t,n,r){return ye(e,n).bind((function(e){return No(r,(function(t){return function(e,t){return da(t).bind((function(t){return ye(e,t)})).map((function(e){return function(e,t){return{element:e,descHandler:t}}(t,e)}))}(e,t)}),t)}))}}},Xb=function(){var e=qb(),t={},n=function(e){var t=e.element;return da(t).getOrThunk((function(){return function(e,t){var n=ia(sa+e);return ua(t,n),n}("uid-",e.element)}))},r=function(n){da(n.element).each((function(n){delete t[n],e.unregisterId(n)}))};return{find:function(t,n,r){return e.find(t,n,r)},filter:function(t){return e.filterByType(t)},register:function(o){var i=n(o);Oe(t,i)&&function(e,n){var o=t[n];if(o!==e)throw new Error('The tagId "'+n+'" is already used by: '+ta(o.element)+"\nCannot use it for: "+ta(e.element)+"\nThe conflicting element is"+(It(o.element)?" ":" not ")+"already in the DOM");r(e)}(o,i);var a=[o];e.registerId(a,i,o.events),t[i]=o},unregister:r,getById:function(e){return ye(t,e)}}},Yb=Ef({name:"Container",factory:function(e){var t=e.dom,n=t.attributes,r=S(t,["attributes"]);return{uid:e.uid,dom:k({tag:"div",attributes:k({role:"presentation"},n)},r),components:e.components,behaviours:Bd(e.containerBehaviours),events:e.events,domModification:e.domModification,eventOrder:e.eventOrder}},configFields:[ho("components",[]),Vd("containerBehaviours",[]),ho("events",{}),ho("domModification",{}),ho("eventOrder",{})]}),Gb=function(e){var t=function(t){return kt(e.element).fold(_,(function(e){return yt(t,e)}))},n=Xb(),r=function(e,r){return n.find(t,e,r)},o=Ib(e.element,{triggerEvent:function(e,t){return yl(e,t.target,(function(n){return function(e,t,n,r){return jb(e,t,n,n.target,r)}(r,e,t,n)}))}}),i={debugInfo:v("real"),triggerEvent:function(e,t,n){yl(e,0,(function(o){return jb(r,e,n,t,o)}))},triggerFocus:function(e,t){da(e).fold((function(){Ts(e)}),(function(n){yl(ii(),0,(function(n){return function(e,t,n,r,o){var i=Lb(n,r);Ub(e,t,n,r,i,o)}(r,ii(),{originator:t,kill:m,prevent:m,target:e},e,n),!1}))}))},triggerEscape:function(e,t){i.triggerEvent("keydown",e.element,t.event)},getByUid:function(e){return p(e)},getByDom:function(e){return g(e)},build:tl,addToGui:function(e){s(e)},removeFromGui:function(e){c(e)},addToWorld:function(e){a(e)},removeFromWorld:function(e){l(e)},broadcast:function(e){d(e)},broadcastOn:function(e,t){f(e,t)},broadcastEvent:function(e,t){h(e,t)},isConnected:_},a=function(e){e.connect(i),Re(e.element)||(n.register(e),H(e.components(),a),i.triggerEvent(mi(),e.element,{target:e.element}))},l=function(e){Re(e.element)||(H(e.components(),l),n.unregister(e)),e.disconnect()},s=function(t){Uu(e,t)},c=function(e){ju(e)},u=function(e){var t=n.filter(si());H(t,(function(t){var n=t.descHandler;Ca(n)(e)}))},d=function(e){u({universal:!0,data:e})},f=function(e,t){u({universal:!1,channels:e,data:t})},h=function(e,t){var r=n.filter(e);return Wb(r,t)},p=function(e){return n.getById(e).fold((function(){return Wn.error(new Error('Could not find component with uid: "'+e+'" in system.'))}),Wn.value)},g=function(e){var t=da(e).getOr("not found");return p(t)};return a(e),{root:e,element:e.element,destroy:function(){o.unbind(),Tn(e.element)},add:s,remove:c,getByUid:p,getByDom:g,addToWorld:a,removeFromWorld:l,broadcast:d,broadcastOn:f,broadcastEvent:h}},Zb=v([ho("prefix","form-field"),Vd("fieldBehaviours",[$f,Sd])]),Kb=v([af({schema:[Gr("dom")],name:"label"}),af({factory:{sketch:function(e){return{uid:e.uid,dom:{tag:"span",styles:{display:"none"},attributes:{"aria-hidden":"true"},innerHtml:e.text}}}},schema:[Gr("text")],name:"aria-descriptor"}),rf({factory:{sketch:function(e){var t=Co(e,["factory"]);return e.factory.sketch(t)}},schema:[Gr("factory")],name:"field"})]),Jb=Pf({name:"FormField",configFields:Zb(),partFields:Kb(),factory:function(e,t,n,r){var o=Td(e.fieldBehaviours,[$f.config({find:function(t){return Af(t,e,"field")}}),Sd.config({store:{mode:"manual",getValue:function(e){return $f.getCurrent(e).bind(Sd.getValue)},setValue:function(e,t){$f.getCurrent(e).each((function(e){Sd.setValue(e,t)}))}}})]),i=Di([qi((function(t,n){var r=bf(t,e,["label","field","aria-descriptor"]);r.field().each((function(t){var n=ia(e.prefix);r.label().each((function(e){Ht(e.element,"for",n),Ht(t.element,"id",n)})),r["aria-descriptor"]().each((function(n){var r=ia(e.prefix);Ht(n.element,"id",r),Ht(t.element,"aria-describedby",r)}))}))}))]),a={getField:function(t){return Af(t,e,"field")},getLabel:function(t){return Af(t,e,"label")}};return{uid:e.uid,dom:e.dom,components:t,behaviours:o,events:i,apis:a}},apis:{getField:function(e,t){return e.getField(t)},getLabel:function(e,t){return e.getLabel(t)}}}),eO=Object.freeze({__proto__:null,exhibit:function(e,t){return _a({attributes:So([{key:t.tabAttr,value:"true"}])})}}),tO=[ho("tabAttr","data-alloy-tabstop")],nO=xs({fields:tO,name:"tabstopping",active:eO}),rO=tinymce.util.Tools.resolve("tinymce.html.Entities"),oO=function(e,t,n,r){var o=iO(e,t,n,r);return Jb.sketch(o)},iO=function(e,t,n,r){return{dom:aO(n),components:e.toArray().concat([t]),fieldBehaviours:Os(r)}},aO=function(e){return{tag:"div",classes:["tox-form__group"].concat(e)}},lO=function(e,t){return Jb.parts.label({dom:{tag:"label",classes:["tox-label"],innerHtml:t.translate(e)}})},sO=ia("form-component-change"),cO=ia("form-close"),uO=ia("form-cancel"),dO=ia("form-action"),fO=ia("form-submit"),hO=ia("form-block"),pO=ia("form-unblock"),mO=ia("form-tabchange"),gO=ia("form-resize"),vO=function(e,t){var n,r,o,i=e.label.map((function(e){return lO(e,t)})),a=function(e){return function(t,n){dl(n.event.target,"[data-collection-item-value]").each((function(r){e(t,n,r,jt(r,"data-collection-item-value"))}))}},l=a((function(n,r,o,i){r.stop(),t.isDisabled()||Ni(n,dO,{name:e.name,value:i})})),s=[Ri(Wo(),a((function(e,t,n){Ts(n)}))),Ri(Ko(),l),Ri(di(),l),Ri(jo(),a((function(e,t,n){ul(e.element,"."+Sv).each((function(e){Ia(e,Sv)})),za(n,Sv)}))),Ri(qo(),a((function(e){ul(e.element,"."+Sv).each((function(e){Ia(e,Sv)}))}))),Gi(a((function(t,n,r,o){Ni(t,dO,{name:e.name,value:o})})))],c=function(e,t){return U(iu(e.element,".tox-collection__item"),t)},u=Jb.parts.field({dom:{tag:"div",classes:["tox-collection"].concat(1!==e.columns?["tox-collection--grid"]:["tox-collection--list"])},components:[],factory:{sketch:A},behaviours:Os([Zf.config({disabled:t.isDisabled,onDisabled:function(e){c(e,(function(e){za(e,"tox-collection__item--state-disabled"),Ht(e,"aria-disabled",!0)}))},onEnabled:function(e){c(e,(function(e){Ia(e,"tox-collection__item--state-disabled"),Yt(e,"aria-disabled")}))}}),XA(),cm.config({}),Sd.config({store:{mode:"memory",initialValue:[]},onSetValue:function(n,r){!function(n,r){var o=U(r,(function(n){var r=Og.translate(n.text),o=1===e.columns?'
'+r+"
":"",i='
'+n.icon+"
",a={_:" "," - ":" ","-":" "},l=r.replace(/\_| \- |\-/g,(function(e){return a[e]}));return'
'+i+o+"
"})),i="auto"!==e.columns&&e.columns>1?F(o,e.columns):[o],a=U(i,(function(e){return'
'+e.join("")+"
"}));Ki(n.element,a.join(""))}(n,r),"auto"===e.columns&&aA(n,5,"tox-collection__item").each((function(e){var t=e.numRows,r=e.numColumns;rm.setGridSize(n,t,r)})),Ti(n,gO)}}),nO.config({}),rm.config((r=e.columns,o="normal",1===r?{mode:"menu",moveOnTab:!1,selector:".tox-collection__item"}:"auto"===r?{mode:"flatgrid",selector:".tox-collection__item",initSize:{numColumns:1,numRows:1}}:{mode:"matrix",selectors:{row:"color"===o?".tox-swatches__row":".tox-collection__group",cell:"color"===o?"."+Ov:"."+bv}})),um("collection-events",s)]),eventOrder:(n={},n[ci()]=["disabling","alloy.base.behaviour","collection-events"],n)});return oO(i,u,["tox-form__group--collection"],[])},AO=v([io("data"),ho("inputAttributes",{}),ho("inputStyles",{}),ho("tag","input"),ho("inputClasses",[]),Vl("onSetValue"),ho("styles",{}),ho("eventOrder",{}),Vd("inputBehaviours",[Sd,mm]),ho("selectOnFocus",!0)]),yO=function(e){return Os([mm.config({onFocus:e.selectOnFocus?function(e){var t=e.element,n=Ha(t);t.dom.setSelectionRange(0,n.length)}:m})])},bO=function(e){return k(k({},yO(e)),Td(e.inputBehaviours,[Sd.config({store:k(k({mode:"manual"},e.data.map((function(e){return{initialValue:e}})).getOr({})),{getValue:function(e){return Ha(e.element)},setValue:function(e,t){Ha(e.element)!==t&&Wa(e.element,t)}}),onSetValue:e.onSetValue})]))},OO=function(e){return{tag:e.tag,attributes:k({type:"text"},e.inputAttributes),styles:e.inputStyles,classes:e.inputClasses}},wO=Ef({name:"Input",configFields:AO(),factory:function(e,t){return{uid:e.uid,dom:OO(e),components:[],behaviours:bO(e),eventOrder:e.eventOrder}}}),xO={},_O={exports:xO};!function(e,t,r){!function(n,o){"object"==typeof t&&void 0!==r?r.exports=o():"function"==typeof e&&e.amd?e(o):(n="undefined"!=typeof globalThis?globalThis:n||self).EphoxContactWrapper=o()}(this,(function(){var e="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==n.g?n.g:"undefined"!=typeof self?self:{},t={exports:{}};!function(t){!function(e){var n=setTimeout;function r(){}function o(e){if("object"!=typeof this)throw new TypeError("Promises must be constructed via new");if("function"!=typeof e)throw new TypeError("not a function");this._state=0,this._handled=!1,this._value=void 0,this._deferreds=[],u(e,this)}function i(e,t){for(;3===e._state;)e=e._value;0!==e._state?(e._handled=!0,o._immediateFn((function(){var n=1===e._state?t.onFulfilled:t.onRejected;if(null!==n){var r;try{r=n(e._value)}catch(e){return void l(t.promise,e)}a(t.promise,r)}else(1===e._state?a:l)(t.promise,e._value)}))):e._deferreds.push(t)}function a(e,t){try{if(t===e)throw new TypeError("A promise cannot be resolved with itself.");if(t&&("object"==typeof t||"function"==typeof t)){var n=t.then;if(t instanceof o)return e._state=3,e._value=t,void s(e);if("function"==typeof n)return void u((r=n,i=t,function(){r.apply(i,arguments)}),e)}e._state=1,e._value=t,s(e)}catch(t){l(e,t)}var r,i}function l(e,t){e._state=2,e._value=t,s(e)}function s(e){2===e._state&&0===e._deferreds.length&&o._immediateFn((function(){e._handled||o._unhandledRejectionFn(e._value)}));for(var t=0,n=e._deferreds.length;tn?n:e===t?t-1:Math.max(t,e-r)},ax=function(e,t,n,r){return e>n?e:ef)return m;var g=function(e,t,n){return Math.min(n,Math.max(e,t))-t}(o,d,f),v=lx(g/h*r+t,p,m);return a&&v>=t&&v<=n?function(e,t,n,r,o){return o.fold((function(){var o=e-t,i=Math.round(o/r)*r;return lx(t+i,t-1,n+1)}),(function(t){var o=(e-t)%r,i=Math.round(o/r),a=Math.floor((e-t)/r),l=Math.floor((n-t)/r),s=t+Math.min(l,a+i)*r;return Math.max(t,s)}))}(v,t,n,i,l):s?Math.round(v):v},cx=function(e){var t=e.min,n=e.max,r=e.range,o=e.value,i=e.hasMinEdge,a=e.hasMaxEdge,l=e.maxBound,s=e.maxOffset,c=e.centerMinEdge,u=e.centerMaxEdge;return on?a?l:u:(o-t)/r*s},ux="top",dx="right",fx="bottom",hx="left",px=function(e){return e.element.dom.getBoundingClientRect()},mx=function(e,t){return e[t]},gx=function(e){var t=px(e);return mx(t,hx)},vx=function(e){var t=px(e);return mx(t,dx)},Ax=function(e){var t=px(e);return mx(t,ux)},yx=function(e){var t=px(e);return mx(t,fx)},bx=function(e){var t=px(e);return mx(t,"width")},Ox=function(e){var t=px(e);return mx(t,"height")},wx=function(e,t,n){return(e+t)/2-n},xx=function(e,t){var n=px(e),r=px(t),o=mx(n,hx),i=mx(n,dx),a=mx(r,hx);return wx(o,i,a)},_x=function(e,t){var n=px(e),r=px(t),o=mx(n,ux),i=mx(n,fx),a=mx(r,ux);return wx(o,i,a)},Cx=function(e,t){Ni(e,Tw(),{value:t})},kx=function(e){return{x:e}},Sx=function(e,t,n){var r={min:Ew(t),max:Dw(t),range:Lw(t),value:n,step:Ww(t),snap:jw(t),snapStart:qw(t),rounded:Xw(t),hasMinEdge:Gw(t),hasMaxEdge:Zw(t),minBound:gx(e),maxBound:vx(e),screenRange:bx(e)};return sx(r)},Vx=function(e){return function(t,n){return function(e,t,n){var r=(e>0?ax:ix)(ex(n).x,Ew(n),Dw(n),Ww(n));return Cx(t,kx(r)),Q.some(r)}(e,t,n).map(_)}},Bx=function(e,t,n,r,o,i){var a=function(e,t,n,r,o){var i=bx(e),a=r.bind((function(t){return Q.some(xx(t,e))})).getOr(0),l=o.bind((function(t){return Q.some(xx(t,e))})).getOr(i),s={min:Ew(t),max:Dw(t),range:Lw(t),value:n,hasMinEdge:Gw(t),hasMaxEdge:Zw(t),minBound:gx(e),minOffset:0,maxBound:vx(e),maxOffset:i,centerMinEdge:a,centerMaxEdge:l};return cx(s)}(t,i,n,r,o);return gx(t)-gx(e)+a},Tx=Vx(-1),Nx=Vx(1),Ex=Q.none,Px=Q.none,Qx={"top-left":Q.none(),top:Q.none(),"top-right":Q.none(),right:Q.some((function(e,t){ox(e,tx(zw(t)))})),"bottom-right":Q.none(),bottom:Q.none(),"bottom-left":Q.none(),left:Q.some((function(e,t){ox(e,tx(Qw(t)))}))},Mx=Object.freeze({__proto__:null,setValueFrom:function(e,t,n){var r=Sx(e,t,n),o=kx(r);return Cx(e,o),r},setToMin:function(e,t){var n=Ew(t);Cx(e,kx(n))},setToMax:function(e,t){var n=Dw(t);Cx(e,kx(n))},findValueOfOffset:Sx,getValueFromEvent:function(e){return Nw(e).map((function(e){return e.left}))},findPositionOfValue:Bx,setPositionFromValue:function(e,t,n,r){var o=ex(n),i=Bx(e,r.getSpectrum(e),o.x,r.getLeftEdge(e),r.getRightEdge(e),n),a=yn(t.element)/2;Kt(t.element,"left",i-a+"px")},onLeft:Tx,onRight:Nx,onUp:Ex,onDown:Px,edgeActions:Qx}),Dx=function(e,t){Ni(e,Tw(),{value:t})},$x=function(e){return{y:e}},zx=function(e,t,n){var r={min:Pw(t),max:$w(t),range:Fw(t),value:n,step:Ww(t),snap:jw(t),snapStart:qw(t),rounded:Xw(t),hasMinEdge:Kw(t),hasMaxEdge:Jw(t),minBound:Ax(e),maxBound:yx(e),screenRange:Ox(e)};return sx(r)},Rx=function(e){return function(t,n){return function(e,t,n){var r=(e>0?ax:ix)(ex(n).y,Pw(n),$w(n),Ww(n));return Dx(t,$x(r)),Q.some(r)}(e,t,n).map(_)}},Ix=function(e,t,n,r,o,i){var a=function(e,t,n,r,o){var i=Ox(e),a=r.bind((function(t){return Q.some(_x(t,e))})).getOr(0),l=o.bind((function(t){return Q.some(_x(t,e))})).getOr(i),s={min:Pw(t),max:$w(t),range:Fw(t),value:n,hasMinEdge:Kw(t),hasMaxEdge:Jw(t),minBound:Ax(e),minOffset:0,maxBound:yx(e),maxOffset:i,centerMinEdge:a,centerMaxEdge:l};return cx(s)}(t,i,n,r,o);return Ax(t)-Ax(e)+a},Lx=Q.none,Fx=Q.none,Ux=Rx(-1),Hx=Rx(1),Wx={"top-left":Q.none(),top:Q.some((function(e,t){ox(e,nx(Mw(t)))})),"top-right":Q.none(),right:Q.none(),"bottom-right":Q.none(),bottom:Q.some((function(e,t){ox(e,nx(Rw(t)))})),"bottom-left":Q.none(),left:Q.none()},jx=Object.freeze({__proto__:null,setValueFrom:function(e,t,n){var r=zx(e,t,n),o=$x(r);return Dx(e,o),r},setToMin:function(e,t){var n=Pw(t);Dx(e,$x(n))},setToMax:function(e,t){var n=$w(t);Dx(e,$x(n))},findValueOfOffset:zx,getValueFromEvent:function(e){return Nw(e).map((function(e){return e.top}))},findPositionOfValue:Ix,setPositionFromValue:function(e,t,n,r){var o=ex(n),i=Ix(e,r.getSpectrum(e),o.y,r.getTopEdge(e),r.getBottomEdge(e),n),a=dn(t.element)/2;Kt(t.element,"top",i-a+"px")},onLeft:Lx,onRight:Fx,onUp:Ux,onDown:Hx,edgeActions:Wx}),qx=function(e,t){Ni(e,Tw(),{value:t})},Xx=function(e,t){return{x:e,y:t}},Yx=function(e,t){return function(n,r){return function(e,t,n,r){var o=e>0?ax:ix,i=t?ex(r).x:o(ex(r).x,Ew(r),Dw(r),Ww(r)),a=t?o(ex(r).y,Pw(r),$w(r),Ww(r)):ex(r).y;return qx(n,Xx(i,a)),Q.some(i)}(e,t,n,r).map(_)}},Gx=Yx(-1,!1),Zx=Yx(1,!1),Kx=Yx(-1,!0),Jx=Yx(1,!0),e_={"top-left":Q.some((function(e,t){ox(e,rx(Qw(t),Mw(t)))})),top:Q.some((function(e,t){ox(e,rx(Uw(t),Mw(t)))})),"top-right":Q.some((function(e,t){ox(e,rx(zw(t),Mw(t)))})),right:Q.some((function(e,t){ox(e,rx(zw(t),Hw(t)))})),"bottom-right":Q.some((function(e,t){ox(e,rx(zw(t),Rw(t)))})),bottom:Q.some((function(e,t){ox(e,rx(Uw(t),Rw(t)))})),"bottom-left":Q.some((function(e,t){ox(e,rx(Qw(t),Rw(t)))})),left:Q.some((function(e,t){ox(e,rx(Qw(t),Hw(t)))}))},t_=Object.freeze({__proto__:null,setValueFrom:function(e,t,n){var r=Sx(e,t,n.left),o=zx(e,t,n.top),i=Xx(r,o);return qx(e,i),i},setToMin:function(e,t){var n=Ew(t),r=Pw(t);qx(e,Xx(n,r))},setToMax:function(e,t){var n=Dw(t),r=$w(t);qx(e,Xx(n,r))},getValueFromEvent:function(e){return Nw(e)},setPositionFromValue:function(e,t,n,r){var o=ex(n),i=Bx(e,r.getSpectrum(e),o.x,r.getLeftEdge(e),r.getRightEdge(e),n),a=Ix(e,r.getSpectrum(e),o.y,r.getTopEdge(e),r.getBottomEdge(e),n),l=yn(t.element)/2,s=dn(t.element)/2;Kt(t.element,"left",i-l+"px"),Kt(t.element,"top",a-s+"px")},onLeft:Gx,onRight:Zx,onUp:Kx,onDown:Jx,edgeActions:e_}),n_=Pf({name:"Slider",configFields:[ho("stepSize",1),ho("onChange",m),ho("onChoose",m),ho("onInit",m),ho("onDragStart",m),ho("onDragEnd",m),ho("snapToGrid",!1),ho("rounded",!0),io("snapStart"),Zr("model",jr("mode",{x:[ho("minX",0),ho("maxX",100),Xr("value",(function(e){return wo(e.mode.minX)})),Gr("getInitialValue"),El("manager",Mx)],y:[ho("minY",0),ho("maxY",100),Xr("value",(function(e){return wo(e.mode.minY)})),Gr("getInitialValue"),El("manager",jx)],xy:[ho("minX",0),ho("maxX",100),ho("minY",0),ho("maxY",100),Xr("value",(function(e){return wo({x:e.mode.minX,y:e.mode.minY})})),Gr("getInitialValue"),El("manager",t_)]})),Vd("sliderBehaviours",[rm,Sd]),Xr("mouseIsDown",(function(){return wo(!1)}))],partFields:Bw,factory:function(e,t,n,r){var o,i=function(t){return yf(t,e,"thumb")},a=function(t){return yf(t,e,"spectrum")},l=function(t){return Af(t,e,"left-edge")},s=function(t){return Af(t,e,"right-edge")},c=function(t){return Af(t,e,"top-edge")},u=function(t){return Af(t,e,"bottom-edge")},d=e.model,f=d.manager,h=function(t,n){f.setPositionFromValue(t,n,e,{getLeftEdge:l,getRightEdge:s,getTopEdge:c,getBottomEdge:u,getSpectrum:a})},p=function(e,t){d.value.set(t);var n=i(e);h(e,n)},m=function(t){var n=e.mouseIsDown.get();e.mouseIsDown.set(!1),n&&Af(t,e,"thumb").each((function(n){var r=d.value.get();e.onChoose(t,n,r)}))},g=function(t,n){n.stop(),e.mouseIsDown.set(!0),e.onDragStart(t,i(t))},v=function(t,n){n.stop(),e.onDragEnd(t,i(t)),m(t)};return{uid:e.uid,dom:e.dom,components:t,behaviours:Td(e.sliderBehaviours,[rm.config({mode:"special",focusIn:function(t){return Af(t,e,"spectrum").map(rm.focusIn).map(_)}}),Sd.config({store:{mode:"manual",getValue:function(e){return d.value.get()}}}),Ss.config({channels:(o={},o[ud()]={onReceive:m},o)})]),events:Di([Ri(Tw(),(function(t,n){!function(t,n){p(t,n);var r=i(t);e.onChange(t,r,n),Q.some(!0)}(t,n.event.value)})),qi((function(t,n){var r=d.getInitialValue();d.value.set(r);var o=i(t);h(t,o);var l=a(t);e.onInit(t,o,l,d.value.get())})),Ri($o(),g),Ri(Ro(),v),Ri(Lo(),g),Ri(Ho(),v)]),apis:{resetToMin:function(t){f.setToMin(t,e)},resetToMax:function(t){f.setToMax(t,e)},setValue:p,refresh:h},domModification:{styles:{position:"relative"}}}},apis:{setValue:function(e,t,n){e.setValue(t,n)},resetToMin:function(e,t){e.resetToMin(t)},resetToMax:function(e,t){e.resetToMax(t)},refresh:function(e,t){e.refresh(t)}}}),r_=ia("rgb-hex-update"),o_=ia("slider-update"),i_=ia("palette-update"),a_="form",l_=[Vd("formBehaviours",[Sd])],s_=function(e){return""},c_=function(e,t){return{uid:e.uid,dom:e.dom,components:t,behaviours:Td(e.formBehaviours,[Sd.config({store:{mode:"manual",getValue:function(t){var n=Of(t,e);return he(n,(function(e,t){return e().bind((function(e){var n,r,o=$f.getCurrent(e);return n=o,r=new Error("Cannot find a current component to extract the value from for form part '"+t+"': "+ta(e.element)),n.fold((function(){return Wn.error(r)}),Wn.value)})).map(Sd.getValue)}))},setValue:function(t,n){fe(n,(function(n,r){Af(t,e,r).each((function(e){$f.getCurrent(e).each((function(e){Sd.setValue(e,n)}))}))}))}}})]),apis:{getField:function(t,n){return Af(t,e,n).bind($f.getCurrent)}}}},u_={getField:ba((function(e,t,n){return e.getField(t,n)})),sketch:function(e){var t=function(){var e=[];return{field:function(t,n){return e.push(t),hf(a_,s_(t),n)},record:v(e)}}(),n=e(t),r=t.record(),o=U(r,(function(e){return rf({name:e,pname:s_(e)})}));return Vf(a_,l_,o,c_,n)}},d_=ia("valid-input"),f_=ia("invalid-input"),h_=ia("validating-input"),p_="colorcustom.rgb.",m_=function(e,t,n,r){var o=function(n,r){return FO.config({invalidClass:t("invalid"),notify:{onValidate:function(e){Ni(e,h_,{type:n})},onValid:function(e){Ni(e,d_,{type:n,value:Sd.getValue(e)})},onInvalid:function(e){Ni(e,f_,{type:n,value:Sd.getValue(e)})}},validator:{validate:function(t){var n=Sd.getValue(t),o=r(n)?Wn.value(!0):Wn.error(e("aria.input.invalid"));return EO(o)},validateOnLoad:!1}})},i=function(n,r,i,a,l){var s=e(p_+"range"),c=Jb.parts.label({dom:{tag:"label",innerHtml:i,attributes:{"aria-label":a}}}),u=Jb.parts.field({data:l,factory:wO,inputAttributes:k({type:"text"},"hex"===r?{"aria-live":"polite"}:{}),inputClasses:[t("textfield")],inputBehaviours:Os([o(r,n),nO.config({})]),onSetValue:function(e){FO.isInvalid(e)&&FO.run(e).get(m)}}),d=[c,u],f="hex"!==r?[Jb.parts["aria-descriptor"]({text:s})]:[];return{dom:{tag:"div",attributes:{role:"presentation"}},components:d.concat(f)}},a=function(e,t){var n=t.red,r=t.green,o=t.blue;Sd.setValue(e,{red:n,green:r,blue:o})},l=bg({dom:{tag:"div",classes:[t("rgba-preview")],styles:{"background-color":"white"},attributes:{role:"presentation"}}}),s=function(e,t){l.getOpt(e).each((function(e){Kt(e.element,"background-color","#"+t.value)}))},c=Ef({factory:function(){var o={red:wo(Q.some(255)),green:wo(Q.some(255)),blue:wo(Q.some(255)),hex:wo(Q.some("ffffff"))},c=function(e){return o[e].get()},u=function(e,t){o[e].set(t)},d=function(e){var t=e.red,n=e.green,r=e.blue;u("red",Q.some(t)),u("green",Q.some(n)),u("blue",Q.some(r))},f=function(e,t){var n=t.event;"hex"!==n.type?u(n.type,Q.none()):r(e)},h=function(e,t,n){var r=parseInt(n,10);u(t,Q.some(r)),c("red").bind((function(e){return c("green").bind((function(t){return c("blue").map((function(n){return My(e,t,n,1)}))}))})).each((function(t){var n=function(e,t){var n=By(t);return u_.getField(e,"hex").each((function(t){mm.isFocused(t)||Sd.setValue(e,{hex:n.value})})),n}(e,t);Ni(e,r_,{hex:n}),s(e,n)}))},p=function(e,t){var r=t.event;!function(e){return"hex"===e.type}(r)?h(e,r.type,r.value):function(e,t){n(e);var r=wy(t);u("hex",Q.some(t));var o=zy(r);a(e,o),d(o),Ni(e,r_,{hex:r}),s(e,r)}(e,r.value)},m=function(t){return{label:e(p_+t+".label"),description:e(p_+t+".description")}},g=m("red"),v=m("green"),A=m("blue"),y=m("hex");return sr(u_.sketch((function(n){return{dom:{tag:"form",classes:[t("rgb-form")],attributes:{"aria-label":e("aria.color.picker")}},components:[n.field("red",Jb.sketch(i(Dy,"red",g.label,g.description,255))),n.field("green",Jb.sketch(i(Dy,"green",v.label,v.description,255))),n.field("blue",Jb.sketch(i(Dy,"blue",A.label,A.description,255))),n.field("hex",Jb.sketch(i(Cy,"hex",y.label,y.description,"ffffff"))),l.asSpec()],formBehaviours:Os([FO.config({invalidClass:t("form-invalid")}),um("rgb-form-events",[Ri(d_,p),Ri(f_,f),Ri(h_,f)])])}})),{apis:{updateHex:function(e,t){Sd.setValue(e,{hex:t.value}),function(e,t){var n=zy(t);a(e,n),d(n)}(e,t),s(e,t)}}})},name:"RgbForm",configFields:[],apis:{updateHex:function(e,t,n){e.updateHex(t,n)}},extraApis:{}});return c},g_=function(e,t){var n=n_.parts.spectrum({dom:{tag:"canvas",attributes:{role:"presentation"},classes:[t("sv-palette-spectrum")]}}),r=n_.parts.thumb({dom:{tag:"div",attributes:{role:"presentation"},classes:[t("sv-palette-thumb")],innerHtml:"'}}),o=function(e,t){var n=e.width,r=e.height,o=e.getContext("2d");if(null!==o){o.fillStyle=t,o.fillRect(0,0,n,r);var i=o.createLinearGradient(0,0,n,0);i.addColorStop(0,"rgba(255,255,255,1)"),i.addColorStop(1,"rgba(255,255,255,0)"),o.fillStyle=i,o.fillRect(0,0,n,r);var a=o.createLinearGradient(0,0,0,r);a.addColorStop(0,"rgba(0,0,0,0)"),a.addColorStop(1,"rgba(0,0,0,1)"),o.fillStyle=a,o.fillRect(0,0,n,r)}},i=Ef({factory:function(e){var i=v({x:0,y:0}),a=Os([$f.config({find:Q.some}),mm.config({})]);return n_.sketch({dom:{tag:"div",attributes:{role:"presentation"},classes:[t("sv-palette")]},model:{mode:"xy",getInitialValue:i},rounded:!1,components:[n,r],onChange:function(e,t,n){Ni(e,i_,{value:n})},onInit:function(e,t,n,r){o(n.element.dom,Ly(Fy))},sliderBehaviours:a})},name:"SaturationBrightnessPalette",configFields:[],apis:{setHue:function(e,t,n){!function(e,t){var n=e.components()[0].element.dom,r=Hy(t,100,100),i=$y(r);o(n,Ly(i))}(t,n)},setThumb:function(e,t,n){!function(e,t){var n=Wy(zy(t));n_.setValue(e,{x:n.saturation,y:100-n.value})}(t,n)}},extraApis:{}});return i},v_=function(e,t){var n=Ef({name:"ColourPicker",configFields:[Gr("dom"),ho("onValidHex",m),ho("onInvalidHex",m)],factory:function(n){var r,o=m_(e,t,n.onValidHex,n.onInvalidHex),i=g_(0,t),a=function(e){return 100-e/360*100},l={paletteRgba:wo(Fy),paletteHue:wo(0)},s=bg(function(e,t){var n=n_.parts.spectrum({dom:{tag:"div",classes:[t("hue-slider-spectrum")],attributes:{role:"presentation"}}}),r=n_.parts.thumb({dom:{tag:"div",classes:[t("hue-slider-thumb")],attributes:{role:"presentation"}}});return n_.sketch({dom:{tag:"div",classes:[t("hue-slider")],attributes:{role:"presentation"}},rounded:!1,model:{mode:"y",getInitialValue:v({y:0})},components:[n,r],sliderBehaviours:Os([mm.config({})]),onChange:function(e,t,n){Ni(e,o_,{value:n})}})}(0,t)),c=bg(i.sketch({})),u=bg(o.sketch({})),d=function(e,t,n){c.getOpt(e).each((function(e){i.setHue(e,n)}))},f=function(e,t){u.getOpt(e).each((function(e){o.updateHex(e,t)}))},h=function(e,t,n){s.getOpt(e).each((function(e){n_.setValue(e,{y:a(n)})}))},p=function(e,t){c.getOpt(e).each((function(e){i.setThumb(e,t)}))},m=function(e,t,n,r){!function(e,t){var n=zy(e);l.paletteRgba.set(n),l.paletteHue.set(t)}(t,n),H(r,(function(r){r(e,t,n)}))};return{uid:n.uid,dom:n.dom,components:[c.asSpec(),s.asSpec(),u.asSpec()],behaviours:Os([um("colour-picker-events",[Ri(r_,(r=[d,h,p],function(e,t){var n=t.event.hex,o=function(e){return Wy(zy(e))}(n);m(e,n,o.hue,r)})),Ri(i_,function(){var e=[f];return function(t,n){var r=n.event.value,o=l.paletteHue.get(),i=Hy(o,r.x,100-r.y),a=jy(i);m(t,a,o,e)}}()),Ri(o_,function(){var e=[d,f];return function(t,n){var r=function(e){return(100-e)/100*360}(n.event.value.y),o=l.paletteRgba.get(),i=Wy(o),a=Hy(r,i.saturation,i.value),s=jy(a);m(t,s,r,e)}}())]),$f.config({find:function(e){return u.getOpt(e)}}),rm.config({mode:"acyclic"})])}}});return n},A_=function(){return $f.config({find:Q.some})},y_=function(e){return $f.config({find:e.getOpt})},b_=function(e){return $f.config({find:function(t){return Bt(t.element,e).bind((function(e){return t.getSystem().getByDom(e).toOptional()}))}})},O_={"colorcustom.rgb.red.label":"R","colorcustom.rgb.red.description":"Red component","colorcustom.rgb.green.label":"G","colorcustom.rgb.green.description":"Green component","colorcustom.rgb.blue.label":"B","colorcustom.rgb.blue.description":"Blue component","colorcustom.rgb.hex.label":"#","colorcustom.rgb.hex.description":"Hex color code","colorcustom.rgb.range":"Range 0 to 255","colorcustom.sb.saturation":"Saturation","colorcustom.sb.brightness":"Brightness","colorcustom.sb.picker":"Saturation and Brightness Picker","colorcustom.sb.palette":"Saturation and Brightness Palette","colorcustom.sb.instructions":"Use arrow keys to select saturation and brightness, on x and y axes","colorcustom.hue.hue":"Hue","colorcustom.hue.slider":"Hue Slider","colorcustom.hue.palette":"Hue Palette","colorcustom.hue.instructions":"Use arrow keys to select a hue","aria.color.picker":"Color Picker","aria.input.invalid":"Invalid input"},w_=function(e){return function(e){return O_[e]}(e)},x_=tinymce.util.Tools.resolve("tinymce.Resource"),__=tinymce.util.Tools.resolve("tinymce.util.Tools"),C_=Cr([ho("preprocess",A),ho("postprocess",A)]),k_=function(e,t,n){return Sd.config(sr({store:{mode:"manual",getValue:t,setValue:n}},e.map((function(e){return{store:{initialValue:e}}})).getOr({})))},S_=function(e,t,n){return k_(e,(function(e){return t(e.element)}),(function(e,t){return n(e.element,t)}))},V_=function(e,t){var n=Hr("RepresentingConfigs.memento processors",C_,t);return Sd.config({store:{mode:"manual",getValue:function(t){var r=e.get(t),o=Sd.getValue(r);return n.postprocess(o)},setValue:function(t,r){var o=n.preprocess(r),i=e.get(t);Sd.setValue(i,o)}}})},B_=k_,T_=function(e){return S_(e,Zi,Ki)},N_=function(e){return Sd.config({store:{mode:"memory",initialValue:e}})},E_=function(e,t){var n=function(e,t){t.stop()},r=function(e){return function(t,n){H(e,(function(e){e(t,n)}))}},o=function(e,t){if(!Zf.isDisabled(e)){var n=t.event.raw;a(e,n.dataTransfer.files)}},i=function(e,t){var n=t.event.raw.target;a(e,n.files)},a=function(n,r){Sd.setValue(n,function(e,t){var n=__.explode(t.getSetting("images_file_types","jpeg,jpg,jpe,jfi,jif,jfif,png,gif,bmp,webp","string"));return j(se(e),(function(e){return I(n,(function(t){return Be(e.name.toLowerCase(),"."+t.toLowerCase())}))}))}(r,t)),Ni(n,sO,{name:e.name})},l=bg({dom:{tag:"input",attributes:{type:"file",accept:"image/*"},styles:{display:"none"}},behaviours:Os([um("input-file-events",[Hi(Ko()),Hi(di())])])}),s=e.label.map((function(e){return lO(e,t)})),c=Jb.parts.field({factory:{sketch:function(e){return{uid:e.uid,dom:{tag:"div",classes:["tox-dropzone-container"]},behaviours:Os([N_([]),A_(),Zf.config({}),Sm.config({toggleClass:"dragenter",toggleOnExecute:!1}),um("dropzone-events",[Ri("dragenter",r([n,Sm.toggle])),Ri("dragleave",r([n,Sm.toggle])),Ri("dragover",n),Ri("drop",r([n,o])),Ri(Zo(),i)])]),components:[{dom:{tag:"div",classes:["tox-dropzone"],styles:{}},components:[{dom:{tag:"p",innerHtml:t.translate("Drop an image here")}},yg.sketch({dom:{tag:"button",innerHtml:t.translate("Browse for an image"),styles:{position:"relative"},classes:["tox-button","tox-button--secondary"]},components:[l.asSpec()],action:function(e){l.get(e).element.dom.click()},buttonBehaviours:Os([nO.config({}),GA(t.isDisabled),XA()])})]}]}}}});return oO(s,c,["tox-form__group--stretched"],[])},P_=ia("alloy-fake-before-tabstop"),Q_=ia("alloy-fake-after-tabstop"),M_=function(e){return{dom:{tag:"div",styles:{width:"1px",height:"1px",outline:"none"},attributes:{tabindex:"0"},classes:e},behaviours:Os([mm.config({ignore:!0}),nO.config({})])}},D_=function(e){return{dom:{tag:"div",classes:["tox-navobj"]},components:[M_([P_]),e,M_([Q_])],behaviours:Os([b_(1)])}},$_=function(e,t){Ni(e,Xo(),{raw:{which:9,shiftKey:t}})},z_=function(e,t){var n=t.element;La(n,P_)?$_(e,!0):La(n,Q_)&&$_(e,!1)},R_=function(e){return Mb(e,["."+P_,"."+Q_].join(","),x)},I_=!(gt().browser.isIE()||gt().browser.isEdge()),L_=function(e,t){var n=I_&&e.sandboxed,r=k(k({},e.label.map((function(e){return{title:e}})).getOr({})),n?{sandbox:"allow-scripts allow-same-origin"}:{}),o=function(e){var t=wo("");return{getValue:function(e){return t.get()},setValue:function(n,r){if(e)Ht(n.element,"srcdoc",r);else{Ht(n.element,"src","javascript:''");var o=n.element.dom.contentWindow.document;o.open(),o.write(r),o.close()}t.set(r)}}}(n),i=e.label.map((function(e){return lO(e,t)})),a=Jb.parts.field({factory:{sketch:function(e){return D_({uid:e.uid,dom:{tag:"iframe",attributes:r},behaviours:Os([nO.config({}),mm.config({}),B_(Q.none(),o.getValue,o.setValue)])})}}});return oO(i,a,["tox-form__group--stretched"],[])},F_=function(e,t){return W_(document.createElement("canvas"),e,t)},U_=function(e){var t=F_(e.width,e.height);return H_(t).drawImage(e,0,0),t},H_=function(e){return e.getContext("2d")},W_=function(e,t,n){return e.width=t,e.height=n,e},j_=function(e){return e.naturalWidth||e.width},q_=function(e){return e.naturalHeight||e.height},X_=function(e){return new kO((function(t,n){(function(e){var t=e.split(","),n=/data:([^;]+)/.exec(t[0]);if(!n)return Q.none();for(var r=n[1],o=t[1],i=1024,a=atob(o),l=a.length,s=Math.ceil(l/i),c=new Array(s),u=0;un?r=n:rn?e=n:e2)&&(i=i<.5?.5:2,l=!0),(a<.5||a>2)&&(a=a<.5?.5:2,l=!0);var s=mC(e,i,a);return l?s.then((function(e){return pC(e,t,n)})):s},mC=function(e,t,n){return new kO((function(r){var o=j_(e),i=q_(e),a=Math.floor(o*t),l=Math.floor(i*n),s=F_(a,l);H_(s).drawImage(e,0,0,o,i,0,0,a,l),r(s)}))},gC=function(e,t){void 0===t&&(t=2);var n=Math.pow(10,t),r=Math.round(e*n);return Math.ceil(r/n)},vC=function(e,t,n){var r=(n<0?360+n:n)*Math.PI/180,o=e.width,i=e.height,a=Math.sin(r),l=Math.cos(r),s=gC(Math.abs(o*l)+Math.abs(i*a)),c=gC(Math.abs(o*a)+Math.abs(i*l)),u=F_(s,c),d=H_(u);return d.translate(s/2,c/2),d.rotate(r),d.drawImage(e,-o/2,-i/2),eC(u,t)},AC=function(e,t,n){var r=F_(e.width,e.height),o=H_(r);return"v"===n?(o.scale(1,-1),o.drawImage(e,0,-r.height)):(o.scale(-1,1),o.drawImage(e,-r.width,0)),eC(r,t)},yC=function(e,t,n,r,o,i){var a=F_(o,i);return H_(a).drawImage(e,-n,-r),eC(a,t)},bC=function(e){return sC(e)},OC=function(e){return fC(e)},wC=function(e,t){return hC(e,t)},xC=function(e,t){return cC(e,t)},_C=function(e,t){return uC(e,t)},CC=function(e,t){return function(e,t){return e.toCanvas().then((function(n){return AC(n,e.getType(),t)}))}(e,t)},kC=function(e,t,n,r,o){return function(e,t,n,r,o){return e.toCanvas().then((function(i){return yC(i,e.getType(),t,n,r,o)}))}(e,t,n,r,o)},SC=function(e,t,n){return function(e,t,n){return e.toCanvas().then((function(r){return pC(r,t,n).then((function(t){return eC(t,e.getType())}))}))}(e,t,n)},VC=function(e,t){return function(e,t){return e.toCanvas().then((function(n){return vC(n,e.getType(),t)}))}(e,t)},BC=function(e,t,n){return Tg(e,{tag:"span",classes:["tox-icon","tox-tbtn__icon-wrap"],behaviours:n},t)},TC=function(e,t){return BC(e,t,[])},NC=function(e,t){return BC(e,t,[cm.config({})])},EC=function(e,t,n){return{dom:{tag:"span",innerHtml:n.translate(e),classes:[t+"__select-label"]},behaviours:Os([cm.config({})])}},PC=ia("toolbar.button.execute"),QC=((ZO={})[ci()]=["disabling","alloy.base.behaviour","toggling","toolbar-button-events"],ZO),MC=ia("update-menu-text"),DC=ia("update-menu-icon"),$C=function(e,t,n){var r=wo(m),o=e.text.map((function(e){return bg(EC(e,t,n.providers))})),i=e.icon.map((function(e){return bg(NC(e,n.providers.icons))})),a=function(e,t){var n=Sd.getValue(e);return mm.focus(n),Ni(n,"keydown",{raw:t.event.raw}),uw.close(n),Q.some(!0)},l=e.role.fold((function(){return{}}),(function(e){return{role:e}})),s=e.tooltip.fold((function(){return{}}),(function(e){var t=n.providers.translate(e);return{title:t,"aria-label":t}})),c=Tg("chevron-down",{tag:"div",classes:[t+"__select-chevron"]},n.providers.icons);return bg(uw.sketch(k(k(k({},e.uid?{uid:e.uid}:{}),l),{dom:{tag:"button",classes:[t,t+"--select"].concat(U(e.classes,(function(e){return t+"--"+e}))),attributes:k({},s)},components:oy([i.map((function(e){return e.asSpec()})),o.map((function(e){return e.asSpec()})),Q.some(c)]),matchWidth:!0,useMinWidth:!0,dropdownBehaviours:Os(V(V([],e.dropdownBehaviours,!0),[GA((function(){return e.disabled||n.providers.isDisabled()})),XA(),fw.config({}),cm.config({}),um("dropdown-events",[ey(e,r),ty(e,r)]),um("menubutton-update-display-text",[Ri(MC,(function(e,t){o.bind((function(t){return t.getOpt(e)})).each((function(e){cm.set(e,[Ka(n.providers.translate(t.event.text))])}))})),Ri(DC,(function(e,t){i.bind((function(t){return t.getOpt(e)})).each((function(e){cm.set(e,[NC(t.event.icon,n.providers.icons)])}))}))])],!1)),eventOrder:sr(QC,{mousedown:["focusing","alloy.base.behaviour","item-type-events","normal-dropdown-events"]}),sandboxBehaviours:Os([rm.config({mode:"special",onLeft:a,onRight:a})]),lazySink:n.getSink,toggleClass:t+"--active",parts:{menu:Dv(0,e.columns,e.presets)},fetch:function(t){return NO(b(e.fetch,t))}}))).asSpec()},zC=function(e){return"separator"===e.type},RC={type:"separator"},IC=function(e,t){var n=X(e,(function(e,n){return function(e){return o(e)}(n)?""===n?e:"|"===n?e.length>0&&!zC(e[e.length-1])?e.concat([RC]):e:be(t,n.toLowerCase())?e.concat([t[n.toLowerCase()]]):e:e.concat([n])}),[]);return n.length>0&&zC(n[n.length-1])&&n.pop(),n},LC=function(e,t){return function(e){return be(e,"getSubmenuItems")}(e)?function(e,t){var n=e.getSubmenuItems(),r=FC(n,t);return{item:e,menus:sr(r.menus,ko(e.value,r.items)),expansions:sr(r.expansions,ko(e.value,e.value))}}(e,t):{item:e,menus:{},expansions:{}}},FC=function(e,t){var n=IC(o(e)?e.split(" "):e,t);return q(n,(function(e,n){var r=function(e){if(zC(e))return e;var t=ye(e,"value").getOrThunk((function(){return ia("generated-menu-item")}));return sr({value:t},e)}(n),o=LC(r,t);return{menus:sr(e.menus,o.menus),items:[o.item].concat(e.items),expansions:sr(e.expansions,o.expansions)}}),{menus:{},expansions:{},items:[]})},UC=function(e,t,n,r){var o=ia("primary-menu"),i=FC(e,n.shared.providers.menuItems());if(0===i.items.length)return Q.none();var a=Eb(o,i.items,t,n,r),l=he(i.menus,(function(e,r){return Eb(r,e,t,n,!1)})),s=sr(l,ko(o,a));return Q.from(Zm.tieredData(o,s,i.expansions))},HC=function(e){return{isDisabled:function(){return Zf.isDisabled(e)},setDisabled:function(t){return Zf.set(e,t)},setActive:function(t){var n=e.element;t?(za(n,"tox-tbtn--enabled"),Ht(n,"aria-pressed",!0)):(Ia(n,"tox-tbtn--enabled"),Yt(n,"aria-pressed"))},isActive:function(){return La(e.element,"tox-tbtn--enabled")}}},WC=function(e,t,n,r){return $C({text:e.text,icon:e.icon,tooltip:e.tooltip,role:r,fetch:function(t,r){e.fetch((function(e){r(UC(e,Av.CLOSE_ON_EXECUTE,n,!1))}))},onSetup:e.onSetup,getApi:HC,columns:1,presets:"normal",classes:[],dropdownBehaviours:[nO.config({})]},t,n.shared)},jC=function(e,t,n){var r=function(e){return function(r){var o=!r.isActive();r.setActive(o),e.storage.set(o),n.shared.getSink().each((function(n){t().getOpt(n).each((function(t){Ts(t.element),Ni(t,dO,{name:e.name,value:e.storage.get()})}))}))}},o=function(e){return function(t){t.setActive(e.storage.get())}};return function(t){t(U(e,(function(e){var t=e.text.fold((function(){return{}}),(function(e){return{text:e}}));return k(k({type:e.type,active:!1},t),{onAction:r(e),onSetup:o(e)})})))}},qC=function(e,t,n,r,o,i){void 0===n&&(n=[]);var a=t.fold((function(){return{}}),(function(e){return{action:e}})),l=k({buttonBehaviours:Os([GA((function(){return e.disabled||i.isDisabled()})),XA(),nO.config({}),um("button press",[zi("click"),zi("mousedown")])].concat(n)),eventOrder:{click:["button press","alloy.base.behaviour"],mousedown:["button press","alloy.base.behaviour"]}},a),s=sr(l,{dom:r});return sr(s,{components:o})},XC=function(e,t,n,r){void 0===r&&(r=[]);var o={tag:"button",classes:["tox-tbtn"],attributes:e.tooltip.map((function(e){return{"aria-label":n.translate(e),title:n.translate(e)}})).getOr({})},i=e.icon.map((function(e){return TC(e,n.icons)})),a=oy([i]);return qC(e,t,r,o,a,n)},YC=function(e,t,n,r){void 0===r&&(r=[]);var o=XC(e,Q.some(t),n,r);return yg.sketch(o)},GC=function(e,t,n,r,o){void 0===r&&(r=[]),void 0===o&&(o=[]);var i=n.translate(e.text),a=e.icon?e.icon.map((function(e){return TC(e,n.icons)})):Q.none(),l=a.isSome()?oy([a]):[],s=a.isSome()?{}:{innerHtml:i},c=V(V(V(V([],e.primary||e.borderless?["tox-button"]:["tox-button","tox-button--secondary"],!0),a.isSome()?["tox-button--icon"]:[],!0),e.borderless?["tox-button--naked"]:[],!0),o,!0),u=k(k({tag:"button",classes:c},s),{attributes:{title:i}});return qC(e,t,r,u,l,n)},ZC=function(e,t,n,r,o){void 0===r&&(r=[]),void 0===o&&(o=[]);var i=GC(e,Q.some(t),n,r,o);return yg.sketch(i)},KC=function(e,t){return function(n){"custom"===t?Ni(n,dO,{name:e,value:{}}):"submit"===t?Ti(n,fO):"cancel"===t&&Ti(n,uO)}},JC=function(e,t,n){if(function(e,t){return"menu"===t}(0,t)){var r=e,o=k(k({},e),{onSetup:function(t){return t.setDisabled(e.disabled),m},fetch:jC(r.items,(function(){return i}),n)}),i=bg(WC(o,"tox-tbtn",n,Q.none()));return i.asSpec()}if(function(e,t){return"custom"===t||"cancel"===t||"submit"===t}(0,t)){var a=KC(e.name,t),l=k(k({},e),{borderless:!1});return ZC(l,a,n.shared.providers,[])}},ek=function(e,t){var n,r,o=KC(e.name,"custom");return n=Q.none(),r=Jb.parts.field(k({factory:yg},GC(e,Q.some(o),t,[N_(""),A_()]))),oO(n,r,[],[])},tk=v([ho("field1Name","field1"),ho("field2Name","field2"),Tl("onLockedChange"),kl(["lockClass"]),ho("locked",!1),Nd("coupledFieldBehaviours",[$f,Sd])]),nk=function(e,t){return rf({factory:Jb,name:e,overrides:function(e){return{fieldBehaviours:Os([um("coupled-input-behaviour",[Ri(Go(),(function(n){(function(e,t,n){return Af(e,t,n).bind($f.getCurrent)})(n,e,t).each((function(t){Af(n,e,"lock").each((function(r){Sm.isOn(r)&&e.onLockedChange(n,t,r)}))}))}))])])}}})},rk=v([nk("field1","field2"),nk("field2","field1"),rf({factory:yg,schema:[Gr("dom")],name:"lock",overrides:function(e){return{buttonBehaviours:Os([Sm.config({selected:e.locked,toggleClass:e.markers.lockClass,aria:{mode:"pressed"}})])}}})]),ok=Pf({name:"FormCoupledInputs",configFields:tk(),partFields:rk(),factory:function(e,t,n,r){return{uid:e.uid,dom:e.dom,components:t,behaviours:Ed(e.coupledFieldBehaviours,[$f.config({find:Q.some}),Sd.config({store:{mode:"manual",getValue:function(t){var n,r=xf(t,e,["field1","field2"]);return(n={})[e.field1Name]=Sd.getValue(r.field1()),n[e.field2Name]=Sd.getValue(r.field2()),n},setValue:function(t,n){var r=xf(t,e,["field1","field2"]);Oe(n,e.field1Name)&&Sd.setValue(r.field1(),n[e.field1Name]),Oe(n,e.field2Name)&&Sd.setValue(r.field2(),n[e.field2Name])}}})]),apis:{getField1:function(t){return Af(t,e,"field1")},getField2:function(t){return Af(t,e,"field2")},getLock:function(t){return Af(t,e,"lock")}}}},apis:{getField1:function(e,t){return e.getField1(t)},getField2:function(e,t){return e.getField2(t)},getLock:function(e,t){return e.getLock(t)}}}),ik=function(e){var t=/^\s*(\d+(?:\.\d+)?)\s*(|cm|mm|in|px|pt|pc|em|ex|ch|rem|vw|vh|vmin|vmax|%)\s*$/.exec(e);if(null!==t){var n=parseFloat(t[1]),r=t[2];return Wn.value({value:n,unit:r})}return Wn.error(e)},ak=function(e,t){var n={"":96,px:96,pt:72,cm:2.54,pc:12,mm:25.4,in:1},r=function(e){return be(n,e)};return e.unit===t?Q.some(e.value):r(e.unit)&&r(t)?n[e.unit]===n[t]?Q.some(e.value):Q.some(e.value/n[e.unit]*n[t]):Q.none()},lk=function(e){return Q.none()},sk=function(e,t){var n=ik(e).toOptional(),r=ik(t).toOptional();return _e(n,r,(function(e,t){return ak(e,t.unit).map((function(e){return t.value/e})).map((function(e){return function(e,t){return function(n){return ak(n,t).map((function(n){return{value:n*e,unit:t}}))}}(e,t.unit)})).getOr(lk)})).getOr(lk)},ck=function(e,t){var n=lk,r=ia("ratio-event"),o=function(e){return Tg(e,{tag:"span",classes:["tox-icon","tox-lock-icon__"+e]},t.icons)},i=ok.parts.lock({dom:{tag:"button",classes:["tox-lock","tox-button","tox-button--naked","tox-button--icon"],attributes:{title:t.translate(e.label.getOr("Constrain proportions"))}},components:[o("lock"),o("unlock")],buttonBehaviours:Os([Zf.config({disabled:function(){return e.disabled||t.isDisabled()}}),XA(),nO.config({})])}),a=function(e){return{dom:{tag:"div",classes:["tox-form__group"]},components:e}},l=function(n){return Jb.parts.field({factory:wO,inputClasses:["tox-textfield"],inputBehaviours:Os([Zf.config({disabled:function(){return e.disabled||t.isDisabled()}}),XA(),nO.config({}),um("size-input-events",[Ri(jo(),(function(e,t){Ni(e,r,{isField1:n})})),Ri(Zo(),(function(t,n){Ni(t,sO,{name:e.name})}))])]),selectOnFocus:!1})},s=function(e){return{dom:{tag:"label",classes:["tox-label"],innerHtml:t.translate(e)}}},c=ok.parts.field1(a([Jb.parts.label(s("Width")),l(!0)])),u=ok.parts.field2(a([Jb.parts.label(s("Height")),l(!1)]));return ok.sketch({dom:{tag:"div",classes:["tox-form__group"]},components:[{dom:{tag:"div",classes:["tox-form__controls-h-stack"]},components:[c,u,a([s(" "),i])]}],field1Name:"width",field2Name:"height",locked:!0,markers:{lockClass:"tox-locked"},onLockedChange:function(e,t,r){ik(Sd.getValue(e)).each((function(e){n(e).each((function(e){Sd.setValue(t,function(e){var t,n={"":0,px:0,pt:1,mm:1,pc:2,ex:2,em:2,ch:2,rem:2,cm:3,in:4,"%":4},r=e.value.toFixed((t=e.unit)in n?n[t]:1);return-1!==r.indexOf(".")&&(r=r.replace(/\.?0*$/,"")),r+e.unit}(e))}))}))},coupledFieldBehaviours:Os([Zf.config({disabled:function(){return e.disabled||t.isDisabled()},onDisabled:function(e){ok.getField1(e).bind(Jb.getField).each(Zf.disable),ok.getField2(e).bind(Jb.getField).each(Zf.disable),ok.getLock(e).each(Zf.disable)},onEnabled:function(e){ok.getField1(e).bind(Jb.getField).each(Zf.enable),ok.getField2(e).bind(Jb.getField).each(Zf.enable),ok.getLock(e).each(Zf.enable)}}),XA(),um("size-input-events2",[Ri(r,(function(e,t){var r=t.event.isField1,o=r?ok.getField1(e):ok.getField2(e),i=r?ok.getField2(e):ok.getField1(e),a=o.map(Sd.getValue).getOr(""),l=i.map(Sd.getValue).getOr("");n=sk(a,l)}))])])})},uk={undo:v(ia("undo")),redo:v(ia("redo")),zoom:v(ia("zoom")),back:v(ia("back")),apply:v(ia("apply")),swap:v(ia("swap")),transform:v(ia("transform")),tempTransform:v(ia("temp-transform")),transformApply:v(ia("transform-apply"))},dk=v("save-state"),fk=v("disable"),hk=v("enable"),pk={formActionEvent:dO,saveState:dk,disable:fk,enable:hk},mk=function(e,t){var n=function(e,n,r,o){return bg(ZC({name:e,text:e,disabled:r,primary:o,icon:Q.none(),borderless:!1},n,t))},r=function(e,n,r,o){return bg(YC({name:e,icon:Q.some(e),tooltip:Q.some(n),disabled:o,primary:!1,borderless:!1},r,t))},o=function(e,t){e.map((function(e){var n=e.get(t);n.hasConfigured(Zf)&&Zf.disable(n)}))},i=function(e,t){e.map((function(e){var n=e.get(t);n.hasConfigured(Zf)&&Zf.enable(n)}))},a={tag:"div",classes:["tox-image-tools__toolbar","tox-image-tools-edit-panel"]},l=m,s=function(e,t,n){Ni(e,t,n)},c=function(e){return Ti(e,pk.disable())},u=function(e){return Ti(e,pk.enable())},d=function(e,t){c(e),s(e,uk.transform(),{transform:t}),u(e)},f=function(e){return function(){ee.getOpt(e).each((function(e){cm.set(e,[K])}))}},h=function(e,t){c(e),s(e,uk.transformApply(),{transform:t,swap:f(e)}),u(e)},p=function(){return n("Back",(function(e){return s(e,uk.back(),{swap:f(e)})}),!1,!1)},g=function(){return bg({dom:{tag:"div",classes:["tox-spacer"]},behaviours:Os([Zf.config({})])})},A=function(){return n("Apply",(function(e){return s(e,uk.apply(),{swap:f(e)})}),!0,!0)},y=[p(),g(),n("Apply",(function(t){var n=function(t){var n=e.getRect();return kC(t,n.x,n.y,n.w,n.h)};h(t,n),e.hideCrop()}),!1,!0)],b=Yb.sketch({dom:a,components:y.map((function(e){return e.asSpec()})),containerBehaviours:Os([um("image-tools-crop-buttons-events",[Ri(pk.disable(),(function(e,t){o(y,e)})),Ri(pk.enable(),(function(e,t){i(y,e)}))])])}),O=bg(ck({name:"size",label:Q.none(),constrain:!0,disabled:!1},t)),w=[p(),g(),O,g(),n("Apply",(function(e){O.getOpt(e).each((function(t){var n=Sd.getValue(t),r=function(e,t){return function(n){return SC(n,e,t)}}(parseInt(n.width,10),parseInt(n.height,10));h(e,r)}))}),!1,!0)],x=Yb.sketch({dom:a,components:w.map((function(e){return e.asSpec()})),containerBehaviours:Os([um("image-tools-resize-buttons-events",[Ri(pk.disable(),(function(e,t){o(w,e)})),Ri(pk.enable(),(function(e,t){i(w,e)}))])])}),_=function(e,t){return function(n){return e(n,t)}},C=_(CC,"h"),k=_(CC,"v"),S=_(VC,-90),V=_(VC,90),B=function(e,t){!function(e,t){c(e),s(e,uk.tempTransform(),{transform:t}),u(e)}(e,t)},T=[p(),g(),r("flip-horizontally","Flip horizontally",(function(e){B(e,C)}),!1),r("flip-vertically","Flip vertically",(function(e){B(e,k)}),!1),r("rotate-left","Rotate counterclockwise",(function(e){B(e,S)}),!1),r("rotate-right","Rotate clockwise",(function(e){B(e,V)}),!1),g(),A()],N=Yb.sketch({dom:a,components:T.map((function(e){return e.asSpec()})),containerBehaviours:Os([um("image-tools-fliprotate-buttons-events",[Ri(pk.disable(),(function(e,t){o(T,e)})),Ri(pk.enable(),(function(e,t){i(T,e)}))])])}),E=function(e,n,r,o,i){var a=n_.parts.label({dom:{tag:"label",classes:["tox-label"],innerHtml:t.translate(e)}}),l=n_.parts.spectrum({dom:{tag:"div",classes:["tox-slider__rail"],attributes:{role:"presentation"}}}),s=n_.parts.thumb({dom:{tag:"div",classes:["tox-slider__handle"],attributes:{role:"presentation"}}});return bg(n_.sketch({dom:{tag:"div",classes:["tox-slider"],attributes:{role:"presentation"}},model:{mode:"x",minX:r,maxX:i,getInitialValue:v({x:o})},components:[a,l,s],sliderBehaviours:Os([mm.config({})]),onChoose:n}))},P=function(e,t,n,r,o){return E(e,(function(e,n,r){var o=_(t,r.x/100);d(e,o)}),n,r,o)},M=function(e,t,n,r,l){var s=function(e,t,n,r,o){return[p(),P(e,t,n,r,o),A()]}(e,t,n,r,l);return Yb.sketch({dom:a,components:s.map((function(e){return e.asSpec()})),containerBehaviours:Os([um("image-tools-filter-panel-buttons-events",[Ri(pk.disable(),(function(e,t){o(s,e)})),Ri(pk.enable(),(function(e,t){i(s,e)}))])])})},D=[p(),g(),A()],$=Yb.sketch({dom:a,components:D.map((function(e){return e.asSpec()}))}),z=M("Brightness",xC,-100,0,100),R=M("Contrast",_C,-100,0,100),I=M("Gamma",wC,-100,0,100),L=function(e,t,n){return function(r){return function(e,t,n,r){return dC(e,t,n,r)}(r,e,t,n)}},F=function(e){return E(e,(function(e,t,n){var r=U.getOpt(e),o=W.getOpt(e),i=H.getOpt(e);r.each((function(t){o.each((function(n){i.each((function(r){var o=Sd.getValue(t).x/100,i=Sd.getValue(r).x/100,a=Sd.getValue(n).x/100,l=L(o,i,a);d(e,l)}))}))}))}),0,100,200)},U=F("R"),H=F("G"),W=F("B"),j=[p(),U,H,W,A()],q=Yb.sketch({dom:a,components:j.map((function(e){return e.asSpec()}))}),X=function(e,t,n){return function(r){s(r,uk.swap(),{transform:t,swap:function(){ee.getOpt(r).each((function(t){cm.set(t,[e]),n(t)}))}})}},Y=Q.some(OC),G=Q.some(bC),Z=[r("crop","Crop",X(b,Q.none(),(function(t){e.showCrop()})),!1),r("resize","Resize",X(x,Q.none(),(function(t){O.getOpt(t).each((function(t){var n=e.getMeasurements(),r=n.width,o=n.height;Sd.setValue(t,{width:r,height:o})}))})),!1),r("orientation","Orientation",X(N,Q.none(),l),!1),r("brightness","Brightness",X(z,Q.none(),l),!1),r("sharpen","Sharpen",X($,Y,l),!1),r("contrast","Contrast",X(R,Q.none(),l),!1),r("color-levels","Color levels",X(q,Q.none(),l),!1),r("gamma","Gamma",X(I,Q.none(),l),!1),r("invert","Invert",X($,G,l),!1)],K=Yb.sketch({dom:a,components:Z.map((function(e){return e.asSpec()}))}),J=Yb.sketch({dom:{tag:"div"},components:[K],containerBehaviours:Os([cm.config({})])}),ee=bg(J);return{memContainer:ee,getApplyButton:function(e){return ee.getOpt(e).map((function(e){var t=e.components()[0];return t.components()[t.components().length-1]}))}}},gk=tinymce.util.Tools.resolve("tinymce.geom.Rect"),vk=tinymce.util.Tools.resolve("tinymce.util.Observable"),Ak=tinymce.util.Tools.resolve("tinymce.util.VK"),yk=function(e){if(function(e){return d(e.changedTouches)}(e))for(var t="screenX screenY pageX pageY clientX clientY".split(" "),n=0;n=1?r.set(1):r.set(l)}))}(e,o),l(e,o)}))}))},c=Yb.sketch({dom:{tag:"div",classes:["tox-image-tools__image"]},components:[n.asSpec(),{dom:{tag:"img",attributes:{src:e}}},{dom:{tag:"div"},behaviours:Os([um("image-panel-crop-events",[qi((function(e){u.getOpt(e).each((function(e){var t=e.element.dom,n=wk({x:10,y:10,w:100,h:100},{x:0,y:0,w:200,h:200},{x:0,y:0,w:200,h:200},t,m);n.toggleVisibility(!1),n.on("updateRect",(function(e){var t=e.rect,n=r.get(),o={x:Math.round(t.x/n),y:Math.round(t.y/n),w:Math.round(t.w/n),h:Math.round(t.h/n)};i.set(o)})),o.set(n)}))})),Xi((function(){o.clear()}))])])}],containerBehaviours:Os([cm.config({}),um("image-panel-events",[qi((function(t){s(t,e)}))])])}),u=bg(c);return{memContainer:u,updateSrc:s,zoom:function(e,t){var n=r.get(),o=t>0?Math.min(2,n+.1):Math.max(.1,n-.1);r.set(o),u.getOpt(e).each((function(e){var t=e.components()[1].element;l(e,t)}))},showCrop:function(){o.run((function(e){e.toggleVisibility(!0)}))},hideCrop:function(){o.run((function(e){e.toggleVisibility(!1)}))},getRect:function(){return i.get()},getMeasurements:function(){var e=a.get();return{width:e.w,height:e.h}}}},_k=function(e,t,n,r,o){return YC({name:e,icon:Q.some(t),disabled:n,tooltip:Q.some(e),primary:!1,borderless:!1},r,o)},Ck=function(e,t){t?Zf.enable(e):Zf.disable(e)};var kk,Sk=function(e){var t,n,r,o,i=wo(e),a=ec(),l=(n=-1,{data:t=[],add:function(e){var r=t.splice(++n);return t.push(e),{state:e,removed:r}},undo:function(){if(r())return t[--n]},redo:function(){if(o())return t[++n]},canUndo:r=function(){return n>0},canRedo:o=function(){return-1!==n&&n=e.minChars){var i=$f.getCurrent(o).bind((function(e){return sh.getHighlighted(e).map(Sd.getValue)}));e.previewing.set(!0);JO(e,a(t),t,o,r,(function(t){$f.getCurrent(o).each((function(t){i.fold((function(){e.model.selectsOver&&sh.highlightFirst(t)}),(function(e){sh.highlightBy(t,(function(t){return Sd.getValue(t).value===e.value})),sh.getHighlighted(t).orThunk((function(){return sh.highlightFirst(t),Q.none()}))}))}))}),CO.HighlightFirst).get(m)}},cancelEvent:pi()}),rm.config({mode:"special",onDown:function(e,t){return o(e,t,sh.highlightFirst),Q.some(!0)},onEscape:function(e){var t=jO.getCoupled(e,"sandbox");return ld.isOpen(t)?(ld.close(t),Q.some(!0)):Q.none()},onUp:function(e,t){return o(e,t,sh.highlightLast),Q.some(!0)},onEnter:function(t){var n=jO.getCoupled(t,"sandbox"),r=ld.isOpen(n);if(r&&!e.previewing.get())return $f.getCurrent(n).bind((function(e){return sh.getHighlighted(e)})).map((function(e){return Ni(t,Hk(),{item:e}),!0}));var o=Sd.getValue(t);return Ti(t,pi()),e.onExecute(n,t,o),r&&ld.close(n),Q.some(!0)}}),Sm.config({toggleClass:e.markers.openClass,aria:{mode:"expanded"}}),jO.config({others:{sandbox:function(t){return iw(e,t,{onOpen:function(){return Sm.on(t)},onClose:function(){return Sm.off(t)}})}}}),um("typeaheadevents",[Gi((function(t){var n=m;tw(e,a(t),t,r,n,CO.HighlightFirst).get(m)})),Ri(Hk(),(function(t,n){var r=jO.getCoupled(t,"sandbox");Ik(e.model,t,n.event.item),Ti(t,pi()),e.onItemExecute(t,r,n.event.item,Sd.getValue(t)),ld.close(r),Fk(t)}))].concat(e.dismissOnBlur?[Ri(ai(),(function(e){var t=jO.getCoupled(e,"sandbox");Ps(t.element).isNone()&&ld.close(t)}))]:[]))];return{uid:e.uid,dom:OO(sr(e,{inputAttributes:{role:"combobox","aria-autocomplete":"list","aria-haspopup":"true"}})),behaviours:k(k({},i),Td(e.typeaheadBehaviours,l)),eventOrder:e.eventOrder}}}),Xk=function(e){return k(k({},e),{toCached:function(){return Xk(e.toCached())},bindFuture:function(t){return Xk(e.bind((function(e){return e.fold((function(e){return EO(Wn.error(e))}),(function(e){return t(e)}))})))},bindResult:function(t){return Xk(e.map((function(e){return e.bind(t)})))},mapResult:function(t){return Xk(e.map((function(e){return e.map(t)})))},mapError:function(t){return Xk(e.map((function(e){return e.mapError(t)})))},foldResult:function(t,n){return e.map((function(e){return e.fold(t,n)}))},withTimeout:function(t,n){return Xk(NO((function(r){var o=!1,i=setTimeout((function(){o=!0,r(Wn.error(n()))}),t);e.get((function(e){o||(clearTimeout(i),r(e))}))})))}})},Yk=function(e){return Xk(NO(e))},Gk=Yk,Zk={type:"separator"},Kk=function(e){return{type:"menuitem",value:e.url,text:e.title,meta:{attach:e.attach},onAction:m}},Jk=function(e,t){return{type:"menuitem",value:t,text:e,meta:{attach:void 0},onAction:m}},eS=function(e,t){return function(e){return U(e,Kk)}(function(e,t){return j(t,(function(t){return t.type===e}))}(e,t))},tS=function(e){return eS("header",e.targets)},nS=function(e){return eS("anchor",e.targets)},rS=function(e){return Q.from(e.anchorTop).map((function(e){return Jk("",e)})).toArray()},oS=function(e){return Q.from(e.anchorBottom).map((function(e){return Jk("",e)})).toArray()},iS=function(e,t){var n=e.toLowerCase();return j(t,(function(e){var t=void 0!==e.meta&&void 0!==e.meta.text?e.meta.text:e.text;return Se(t.toLowerCase(),n)||Se(e.value.toLowerCase(),n)}))},aS=function(e,t,n){var r=Sd.getValue(t),o=void 0!==r.meta.text?r.meta.text:r.value;return n.getLinkInformation().fold((function(){return[]}),(function(t){var r,i=iS(o,function(e){return U(e,(function(e){return Jk(e,e)}))}(n.getHistory(e)));return"file"===e?(r=[i,iS(o,tS(t)),iS(o,Z([rS(t),nS(t),oS(t)]))],X(r,(function(e,t){return 0===e.length||0===t.length?e.concat(t):e.concat(Zk,t)}),[])):i}))},lS=ia("aria-invalid"),sS=function(e){return function(t,n,r){return ye(n,"name").fold((function(){return e(n,r)}),(function(o){return t.field(o,e(n,r))}))}},cS={bar:sS((function(e,t){return function(e,t){return{dom:{tag:"div",classes:["tox-bar","tox-form__controls-h-stack"]},components:U(e.items,t.interpreter)}}(e,t.shared)})),collection:sS((function(e,t){return vO(e,t.shared.providers)})),alertbanner:sS((function(e,t){return function(e,t){return Yb.sketch({dom:{tag:"div",attributes:{role:"alert"},classes:["tox-notification","tox-notification--in","tox-notification--"+e.level]},components:[{dom:{tag:"div",classes:["tox-notification__icon"]},components:[yg.sketch({dom:{tag:"button",classes:["tox-button","tox-button--naked","tox-button--icon"],innerHtml:Sg(e.icon,t.icons),attributes:{title:t.translate(e.iconTooltip)}},action:function(t){Ni(t,dO,{name:"alert-banner",value:e.url})},buttonBehaviours:Os([Vg()])})]},{dom:{tag:"div",classes:["tox-notification__body"],innerHtml:t.translate(e.text)}}]})}(e,t.shared.providers)})),input:sS((function(e,t){return function(e,t){return Qk({name:e.name,multiline:!1,label:e.label,inputMode:e.inputMode,placeholder:e.placeholder,flex:!1,disabled:e.disabled,classname:"tox-textfield",validation:Q.none(),maximized:e.maximized},t)}(e,t.shared.providers)})),textarea:sS((function(e,t){return function(e,t){return Qk({name:e.name,multiline:!0,label:e.label,inputMode:Q.none(),placeholder:e.placeholder,flex:!0,disabled:e.disabled,classname:"tox-textarea",validation:Q.none(),maximized:e.maximized},t)}(e,t.shared.providers)})),label:sS((function(e,t){return function(e,t){var n={dom:{tag:"label",innerHtml:t.providers.translate(e.label),classes:["tox-label"]}},r=U(e.items,t.interpreter);return{dom:{tag:"div",classes:["tox-form__group"]},components:[n].concat(r),behaviours:Os([A_(),cm.config({}),T_(Q.none()),rm.config({mode:"acyclic"})])}}(e,t.shared)})),iframe:function(e){return function(t,n,r){var o=sr(n,{source:"dynamic"});return sS(e)(t,o,r)}}((function(e,t){return L_(e,t.shared.providers)})),button:sS((function(e,t){return ek(e,t.shared.providers)})),checkbox:sS((function(e,t){return function(e,t){var n=Sd.config({store:{mode:"manual",getValue:function(e){return e.element.dom.checked},setValue:function(e,t){e.element.dom.checked=t}}}),r=function(e){return e.element.dom.click(),Q.some(!0)},o=Jb.parts.field({factory:{sketch:A},dom:{tag:"input",classes:["tox-checkbox__input"],attributes:{type:"checkbox"}},behaviours:Os([A_(),Zf.config({disabled:function(){return e.disabled||t.isDisabled()}}),nO.config({}),mm.config({}),n,rm.config({mode:"special",onEnter:r,onSpace:r,stopSpaceKeyup:!0}),um("checkbox-events",[Ri(Zo(),(function(t,n){Ni(t,sO,{name:e.name})}))])])}),i=Jb.parts.label({dom:{tag:"span",classes:["tox-checkbox__label"],innerHtml:t.translate(e.label)},behaviours:Os([fw.config({})])}),a=function(e){return Tg("checked"===e?"selected":"unselected",{tag:"span",classes:["tox-icon","tox-checkbox-icon__"+e]},t.icons)},l=bg({dom:{tag:"div",classes:["tox-checkbox__icons"]},components:[a("checked"),a("unchecked")]});return Jb.sketch({dom:{tag:"label",classes:["tox-checkbox"]},components:[o,l.asSpec(),i],fieldBehaviours:Os([Zf.config({disabled:function(){return e.disabled||t.isDisabled()},disableClass:"tox-checkbox--disabled",onDisabled:function(e){Jb.getField(e).each(Zf.disable)},onEnabled:function(e){Jb.getField(e).each(Zf.enable)}}),XA()])})}(e,t.shared.providers)})),colorinput:sS((function(e,t){return gw(e,t.shared,t.colorinput)})),colorpicker:sS((function(e){var t=function(e){return"tox-"+e},n=v_(w_,t),r=bg(n.sketch({dom:{tag:"div",classes:[t("color-picker-container")],attributes:{role:"presentation"}},onValidHex:function(e){Ni(e,dO,{name:"hex-valid",value:!0})},onInvalidHex:function(e){Ni(e,dO,{name:"hex-valid",value:!1})}}));return{dom:{tag:"div"},components:[r.asSpec()],behaviours:Os([Sd.config({store:{mode:"manual",getValue:function(e){var t=r.get(e);return $f.getCurrent(t).bind((function(e){return Sd.getValue(e).hex})).map((function(e){return"#"+e})).getOr("")},setValue:function(e,t){var n=/^#([a-fA-F0-9]{3}(?:[a-fA-F0-9]{3})?)/.exec(t),o=r.get(e);$f.getCurrent(o).fold((function(){}),(function(e){Sd.setValue(e,{hex:Q.from(n[1]).getOr("")}),u_.getField(e,"hex").each((function(e){Ti(e,Go())}))}))}}}),A_()])}})),dropzone:sS((function(e,t){return E_(e,t.shared.providers)})),grid:sS((function(e,t){return function(e,t){return{dom:{tag:"div",classes:["tox-form__grid","tox-form__grid--"+e.columns+"col"]},components:U(e.items,t.interpreter)}}(e,t.shared)})),listbox:sS((function(e,t){return function(e,t){var n=t.shared.providers,r=ae(e.items).filter(Bk),o=e.label.map((function(e){return lO(e,n)})),i=Jb.parts.field({dom:{},factory:{sketch:function(n){return $C({uid:n.uid,text:r.map((function(e){return e.text})),icon:Q.none(),tooltip:e.label,role:Q.none(),fetch:function(n,r){var o=Nk(n,e.name,e.items,Sd.getValue(n));r(UC(o,Av.CLOSE_ON_EXECUTE,t,!1))},onSetup:v(m),getApi:v({}),columns:1,presets:"normal",classes:[],dropdownBehaviours:[nO.config({}),Sd.config({store:{mode:"manual",initialValue:r.map((function(e){return e.value})).getOr(""),getValue:function(e){return jt(e.element,Tk)},setValue:function(t,n){Ek(e.items,n).each((function(e){Ht(t.element,Tk,e.value),Ni(t,MC,{text:e.text})}))}}})]},"tox-listbox",t.shared)}}}),a={dom:{tag:"div",classes:["tox-listboxfield"]},components:[i]};return Jb.sketch({dom:{tag:"div",classes:["tox-form__group"]},components:Z([o.toArray(),[a]]),fieldBehaviours:Os([Zf.config({disabled:v(e.disabled),onDisabled:function(e){Jb.getField(e).each(Zf.disable)},onEnabled:function(e){Jb.getField(e).each(Zf.enable)}})])})}(e,t)})),selectbox:sS((function(e,t){return function(e,t){var n=U(e.items,(function(e){return{text:t.translate(e.text),value:e.value}})),r=e.label.map((function(e){return lO(e,t)})),o=Jb.parts.field({dom:{},selectAttributes:{size:e.size},options:n,factory:Pk,selectBehaviours:Os([Zf.config({disabled:function(){return e.disabled||t.isDisabled()}}),nO.config({}),um("selectbox-change",[Ri(Zo(),(function(t,n){Ni(t,sO,{name:e.name})}))])])}),i=e.size>1?Q.none():Q.some(Tg("chevron-down",{tag:"div",classes:["tox-selectfield__icon-js"]},t.icons)),a={dom:{tag:"div",classes:["tox-selectfield"]},components:Z([[o],i.toArray()])};return Jb.sketch({dom:{tag:"div",classes:["tox-form__group"]},components:Z([r.toArray(),[a]]),fieldBehaviours:Os([Zf.config({disabled:function(){return e.disabled||t.isDisabled()},onDisabled:function(e){Jb.getField(e).each(Zf.disable)},onEnabled:function(e){Jb.getField(e).each(Zf.enable)}}),XA()])})}(e,t.shared.providers)})),sizeinput:sS((function(e,t){return ck(e,t.shared.providers)})),urlinput:sS((function(e,t){return function(e,t,n){var r,o=t.shared.providers,i=function(t){var r=Sd.getValue(t);n.addToHistory(r.value,e.filetype)},a=Jb.parts.field({factory:qk,dismissOnBlur:!0,inputClasses:["tox-textfield"],sandboxClasses:["tox-dialog__popups"],inputAttributes:{"aria-errormessage":lS,type:"url"},minChars:0,responseTime:0,fetch:function(r){var o=aS(e.filetype,r,n),i=UC(o,Av.BUBBLE_TO_SANDBOX,t,!1);return EO(i)},getHotspot:function(e){return f.getOpt(e)},onSetValue:function(e,t){e.hasConfigured(FO)&&FO.run(e).get(m)},typeaheadBehaviours:Os(Z([n.getValidationHandler().map((function(t){return FO.config({getRoot:function(e){return kt(e.element)},invalidClass:"tox-control-wrap--status-invalid",notify:{onInvalid:function(e,t){s.getOpt(e).each((function(e){Ht(e.element,"title",o.translate(t))}))}},validator:{validate:function(n){var r=Sd.getValue(n);return Gk((function(n){t({type:e.filetype,url:r.value},(function(e){if("invalid"===e.status){var t=Wn.error(e.message);n(t)}else{var r=Wn.value(e.message);n(r)}}))}))},validateOnLoad:!1}})})).toArray(),[Zf.config({disabled:function(){return e.disabled||o.isDisabled()}}),nO.config({}),um("urlinput-events",Z(["file"===e.filetype?[Ri(Go(),(function(t){Ni(t,sO,{name:e.name})}))]:[],[Ri(Zo(),(function(t){Ni(t,sO,{name:e.name}),i(t)})),Ri(li(),(function(t){Ni(t,sO,{name:e.name}),i(t)}))]]))]])),eventOrder:(r={},r[Go()]=["streaming","urlinput-events","invalidating"],r),model:{getDisplayText:function(e){return e.value},selectsOver:!1,populateFromBrowse:!1},markers:{openClass:"tox-textfield--popup-open"},lazySink:t.shared.getSink,parts:{menu:Dv(0,0,"normal")},onExecute:function(e,t,n){Ni(t,fO,{})},onItemExecute:function(t,n,r,o){i(t),Ni(t,sO,{name:e.name})}}),l=e.label.map((function(e){return lO(e,o)})),s=bg(function(e,t,n,r){return void 0===n&&(n=e),void 0===r&&(r=e),Tg(n,{tag:"div",classes:["tox-icon","tox-control-wrap__status-icon-"+e],attributes:k({title:o.translate(r),"aria-live":"polite"},t.fold((function(){return{}}),(function(e){return{id:e}})))},o.icons)}("invalid",Q.some(lS),"warning")),c=bg({dom:{tag:"div",classes:["tox-control-wrap__status-icon-wrap"]},components:[s.asSpec()]}),u=n.getUrlPicker(e.filetype),d=ia("browser.url.event"),f=bg({dom:{tag:"div",classes:["tox-control-wrap"]},components:[a,c.asSpec()],behaviours:Os([Zf.config({disabled:function(){return e.disabled||o.isDisabled()}})])}),h=bg(ZC({name:e.name,icon:Q.some("browse"),text:e.label.getOr(""),disabled:e.disabled,primary:!1,borderless:!0},(function(e){return Ti(e,d)}),o,[],["tox-browse-url"]));return Jb.sketch({dom:aO([]),components:l.toArray().concat([{dom:{tag:"div",classes:["tox-form__controls-h-stack"]},components:Z([[f.asSpec()],u.map((function(){return h.asSpec()})).toArray()])}]),fieldBehaviours:Os([Zf.config({disabled:function(){return e.disabled||o.isDisabled()},onDisabled:function(e){Jb.getField(e).each(Zf.disable),h.getOpt(e).each(Zf.disable)},onEnabled:function(e){Jb.getField(e).each(Zf.enable),h.getOpt(e).each(Zf.enable)}}),XA(),um("url-input-events",[Ri(d,(function(t){$f.getCurrent(t).each((function(n){var r=Sd.getValue(n),o=k({fieldname:e.name},r);u.each((function(r){r(o).get((function(r){Sd.setValue(n,r),Ni(t,sO,{name:e.name})}))}))}))}))])])})}(e,t,t.urlinput)})),customeditor:sS((function(e){var t=ec(),n=bg({dom:{tag:e.tag}}),r=ec();return{dom:{tag:"div",classes:["tox-custom-editor"]},behaviours:Os([um("custom-editor-events",[qi((function(o){n.getOpt(o).each((function(n){(!function(e){return be(e,"init")}(e)?x_.load(e.scriptId,e.scriptUrl).then((function(t){return t(n.element.dom,e.settings)})):e.init(n.element.dom)).then((function(e){r.on((function(t){e.setValue(t)})),r.clear(),t.set(e)}))}))}))]),Sd.config({store:{mode:"manual",getValue:function(){return t.get().fold((function(){return r.get().getOr("")}),(function(e){return e.getValue()}))},setValue:function(e,n){t.get().fold((function(){r.set(n)}),(function(e){return e.setValue(n)}))}}}),A_()]),components:[n.asSpec()]}})),htmlpanel:sS((function(e){return"presentation"===e.presets?Yb.sketch({dom:{tag:"div",classes:["tox-form__group"],innerHtml:e.html}}):Yb.sketch({dom:{tag:"div",classes:["tox-form__group"],innerHtml:e.html,attributes:{role:"document"}},containerBehaviours:Os([nO.config({}),mm.config({})])})})),imagetools:sS((function(e,t){return Vk(e,t.shared.providers)})),table:sS((function(e,t){return function(e,t){var n,r,o=function(e){return{dom:{tag:"th",innerHtml:t.translate(e)}}},i=function(e){return{dom:{tag:"td",innerHtml:t.translate(e)}}},a=function(e){return{dom:{tag:"tr"},components:U(e,i)}};return{dom:{tag:"table",classes:["tox-dialog__table"]},components:[(r=e.header,{dom:{tag:"thead"},components:[{dom:{tag:"tr"},components:U(r,o)}]}),(n=e.cells,{dom:{tag:"tbody"},components:U(n,a)})],behaviours:Os([nO.config({}),mm.config({})])}}(e,t.shared.providers)})),panel:sS((function(e,t){return function(e,t){return{dom:{tag:"div",classes:e.classes},components:U(e.items,t.shared.interpreter)}}(e,t)}))},uS={field:function(e,t){return t}},dS=function(e,t,n){var r=sr(n,{shared:{interpreter:function(t){return fS(e,t,r)}}});return fS(e,t,r)},fS=function(e,t,n){return ye(cS,t.type).fold((function(){return t}),(function(r){return r(e,t,n)}))},hS={valignCentre:[],alignCentre:[],alignLeft:[],alignRight:[],right:[],left:[],bottom:[],top:[]},pS=function(e,t,n){var r={maxHeightFunction:mc()};return function(){return n()?{type:"node",root:Dt(e()),node:Q.from(e()),bubble:yc(12,12,hS),layouts:{onRtl:function(){return[cg]},onLtr:function(){return[sg]}},overrides:r}:{type:"hotspot",hotspot:t(),bubble:yc(-12,12,hS),layouts:{onRtl:function(){return[ts]},onLtr:function(){return[ns]}},overrides:r}}},mS=function(e,t,n){return function(){return n()?{type:"node",root:Dt(e()),node:Q.from(e()),layouts:{onRtl:function(){return[ug]},onLtr:function(){return[ug]}}}:{type:"hotspot",hotspot:t(),layouts:{onRtl:function(){return[as]},onLtr:function(){return[as]}}}}},gS=function(e,t){return function(){return{type:"selection",root:t(),getSelection:function(){var t=e.selection.getRng();return Q.some(Wc.range(Qe.fromDom(t.startContainer),t.startOffset,Qe.fromDom(t.endContainer),t.endOffset))}}}},vS=function(e){return function(t){return{type:"node",root:e(),node:t}}},AS=function(e,t,n){var r=DA(e),o=function(){return Qe.fromDom(e.getBody())},i=function(){return Qe.fromDom(e.getContentAreaContainer())},a=function(){return r||!n()};return{inlineDialog:pS(i,t,a),banner:mS(i,t,a),cursor:gS(e,o),node:vS(o)}},yS=function(e){return function(t,n){fb(e)(t,n)}},bS=function(e){return function(){return eb(e)}},OS=function(e){return function(){return tb(e)}},wS=function(e){return function(){return ob(e)}},xS=function(e){return{colorPicker:yS(e),hasCustomColors:bS(e),getColors:OS(e),getColorCols:wS(e)}},_S=function(e){return function(){return function(e){return e.getParam("draggable_modal",!1,"boolean")}(e)}},CS=function(e){return{isDraggableModal:_S(e)}},kS=[{title:"Headings",items:[{title:"Heading 1",format:"h1"},{title:"Heading 2",format:"h2"},{title:"Heading 3",format:"h3"},{title:"Heading 4",format:"h4"},{title:"Heading 5",format:"h5"},{title:"Heading 6",format:"h6"}]},{title:"Inline",items:[{title:"Bold",format:"bold"},{title:"Italic",format:"italic"},{title:"Underline",format:"underline"},{title:"Strikethrough",format:"strikethrough"},{title:"Superscript",format:"superscript"},{title:"Subscript",format:"subscript"},{title:"Code",format:"code"}]},{title:"Blocks",items:[{title:"Paragraph",format:"p"},{title:"Blockquote",format:"blockquote"},{title:"Div",format:"div"},{title:"Pre",format:"pre"}]},{title:"Align",items:[{title:"Left",format:"alignleft"},{title:"Center",format:"aligncenter"},{title:"Right",format:"alignright"},{title:"Justify",format:"alignjustify"}]}],SS=function(e){return X(e,(function(e,t){if(be(t,"items")){var n=SS(t.items);return{customFormats:e.customFormats.concat(n.customFormats),formats:e.formats.concat([{title:t.title,items:n.formats}])}}if(function(e){return be(e,"inline")}(t)||function(e){return be(e,"block")}(t)||function(e){return be(e,"selector")}(t)){var r="custom-"+(o(t.name)?t.name:t.title.toLowerCase());return{customFormats:e.customFormats.concat([{name:r,format:t}]),formats:e.formats.concat([{title:t.title,format:r,icon:t.icon}])}}return k(k({},e),{formats:e.formats.concat(t)})}),{customFormats:[],formats:[]})},VS=function(e){return function(e){return Q.from(e.getParam("style_formats")).filter(a)}(e).map((function(t){var n=function(e,t){var n=SS(t),r=function(t){H(t,(function(t){e.formatter.has(t.name)||e.formatter.register(t.name,t.format)}))};return e.formatter?r(n.customFormats):e.on("init",(function(){r(n.customFormats)})),n.formats}(e,t);return function(e){return e.getParam("style_formats_merge",!1,"boolean")}(e)?kS.concat(n):n})).getOr(kS)},BS=function(e,t,n){var r={type:"formatter",isSelected:t(e.format),getStylePreview:n(e.format)};return sr(e,r)},TS=function(e,t,n,r){var i=function(t){return U(t,(function(t){var a=ue(t);if(Oe(t,"items")){var l=i(t.items);return sr(function(e){return sr(e,{type:"submenu"})}(t),{getStyleItems:v(l)})}return Oe(t,"format")?function(e){return BS(e,n,r)}(t):1===a.length&&R(a,"title")?sr(t,{type:"separator"}):function(t){var i=o(t.name)?t.name:ia(t.title),a="custom-"+i,l={type:"formatter",format:a,isSelected:n(a),getStylePreview:r(a)},s=sr(t,l);return e.formatter.register(i,s),s}(t)}))};return i(t)},NS=function(e){var t=function(t){return function(){return e.formatter.match(t)}},n=function(t){return function(){var n=e.formatter.get(t);return void 0!==n?Q.some({tag:n.length>0&&(n[0].inline||n[0].block)||"div",styles:e.dom.parseStyle(e.formatter.getCssText(t))}):Q.none()}},r=function(e){var t=e.items;return void 0!==t&&t.length>0?K(t,r):[e.format]},o=wo([]),i=wo([]),a=wo([]),l=wo([]),s=wo(!1);e.on("PreInit",(function(a){var l=VS(e),s=TS(e,l,t,n);o.set(s),i.set(K(s,r))})),e.on("addStyleModifications",(function(o){var i=TS(e,o.items,t,n);a.set(i),s.set(o.replace),l.set(K(i,r))}));return{getData:function(){var e=s.get()?[]:o.get(),t=a.get();return e.concat(t)},getFlattenedKeys:function(){var e=s.get()?[]:i.get(),t=l.get();return e.concat(t)}}},ES=__.trim,PS=function(e){return function(t){if(function(e){return d(e)&&1===e.nodeType}(t)){if(t.contentEditable===e)return!0;if(t.getAttribute("data-mce-contenteditable")===e)return!0}return!1}},QS=PS("true"),MS=PS("false"),DS=function(e,t,n,r,o){return{type:e,title:t,url:n,level:r,attach:o}},$S=function(e){return e.innerText||e.textContent},zS=function(e){return function(e){return e&&"A"===e.nodeName&&void 0!==(e.id||e.name)}(e)&&IS(e)},RS=function(e){return e&&/^(H[1-6])$/.test(e.nodeName)},IS=function(e){return function(e){for(;e=e.parentNode;){var t=e.contentEditable;if(t&&"inherit"!==t)return QS(e)}return!1}(e)&&!MS(e)},LS=function(e){return RS(e)&&IS(e)},FS=function(e){var t=function(e){return e.id?e.id:ia("h")}(e);return DS("header",$S(e),"#"+t,function(e){return RS(e)?parseInt(e.nodeName.substr(1),10):0}(e),(function(){e.id=t}))},US=function(e){var t=e.id||e.name,n=$S(e);return DS("anchor",n||"#"+t,"#"+t,0,m)},HS=function(e){var t,n,r=(t="h1,h2,h3,h4,h5,h6,a:not([href])",n=e,U(iu(Qe.fromDom(n),t),(function(e){return e.dom})));return r},WS=function(e){return ES(e.title).length>0},jS=function(e){var t=HS(e);return j(function(e){return U(j(e,LS),FS)}(t).concat(function(e){return U(j(e,zS),US)}(t)),WS)},qS="tinymce-url-history",XS=function(e){return o(e)&&/^https?/.test(e)},YS=function(e){return i(e)&&ve(e,(function(e){return!(a(t=e)&&t.length<=5&&J(t,XS));var t})).isNone()},GS=function(){var e,t=Xy.getItem(qS);if(null===t)return{};try{e=JSON.parse(t)}catch(e){if(e instanceof SyntaxError)return{};throw e}return YS(e)?e:{}},ZS=function(e){var t=GS();return ye(t,e).getOr([])},KS=function(e,t){if(XS(e)){var n=GS(),r=ye(n,t).getOr([]),o=j(r,(function(t){return t!==e}));n[t]=[e].concat(o).slice(0,5),function(e){if(!YS(e))throw new Error("Bad format for history:\n"+JSON.stringify(e));Xy.setItem(qS,JSON.stringify(e))}(n)}},JS=function(e){return!!e},eV=function(e){return he(__.makeMap(e,/[, ]/),JS)},tV=function(e){return Q.from(function(e){return e.getParam("file_picker_callback")}(e)).filter(f)},nV=function(e,t){var n=function(e){var t=Q.some(function(e){return e.getParam("file_picker_types")}(e)).filter(JS),n=Q.some(function(e){return e.getParam("file_browser_callback_types")}(e)).filter(JS),r=t.or(n).map(eV);return tV(e).fold(x,(function(e){return r.fold(_,(function(e){return ue(e).length>0&&e}))}))}(e);return s(n)?n?tV(e):Q.none():n[t]?tV(e):Q.none()},rV=function(e){return Q.from(e).filter(o).getOrUndefined()},oV=function(e){return{getHistory:ZS,addToHistory:KS,getLinkInformation:function(){return function(e){return function(e){return!1===e.getParam("typeahead_urls")}(e)?Q.none():Q.some({targets:jS(e.getBody()),anchorTop:rV(FA(e)),anchorBottom:rV(UA(e))})}(e)},getValidationHandler:function(){return function(e){return Q.from(function(e){var t=e.getParam("file_picker_validator_handler",void 0,"function");return void 0===t?e.getParam("filepicker_validator_handler",void 0,"function"):t}(e))}(e)},getUrlPicker:function(t){return function(e,t){return nV(e,t).map((function(n){return function(r){return NO((function(a){var l=k({filetype:t,fieldname:r.fieldname},Q.from(r.meta).getOr({}));n.call(e,(function(e,t){if(!o(e))throw new Error("Expected value to be string");if(void 0!==t&&!i(t))throw new Error("Expected meta to be a object");a({value:e,meta:t})}),r.value,l)}))}}))}(e,t)}}},iV=function(e,t,n){var r=wo(!1),o=function(e){var t=wo(QA(e)?"bottom":"top");return{isPositionedAtTop:function(){return"top"===t.get()},getDockingMode:t.get,setDockingMode:t.set}}(t),i={shared:{providers:{icons:function(){return t.ui.registry.getAll().icons},menuItems:function(){return t.ui.registry.getAll().menuItems},translate:Og.translate,isDisabled:function(){return t.mode.isReadOnly()||t.ui.isDisabled()},getSetting:t.getParam.bind(t)},interpreter:function(e){return function(e,t){return fS(uS,e,t)}(e,i)},anchors:AS(t,n,o.isPositionedAtTop),header:o,getSink:function(){return Wn.value(e)}},urlinput:oV(t),styleselect:NS(t),colorinput:xS(t),dialog:CS(t),isContextMenuOpen:function(){return r.get()},setContextMenuState:function(e){return r.set(e)}};return i},aV=kf,lV=cf,sV=v([ho("shell",!1),Gr("makeItem"),ho("setupItem",m),Nd("listBehaviours",[cm])]),cV=af({name:"items",overrides:function(){return{behaviours:Os([cm.config({})])}}}),uV=v([cV]),dV=v("CustomList"),fV=Pf({name:dV(),configFields:sV(),partFields:uV(),factory:function(e,t,n,r){var o=e.shell?{behaviours:[cm.config({})],components:[]}:{behaviours:[],components:t},i=function(t){return e.shell?Q.some(t):Af(t,e,"items")};return{uid:e.uid,dom:e.dom,components:o.components,behaviours:Td(e.listBehaviours,o.behaviours),apis:{setItems:function(t,n){i(t).fold((function(){throw new Error("Custom List was defined to not be a shell, but no item container was specified in components")}),(function(r){var o=cm.contents(r),i=n.length,a=i-o.length,l=a>0?L(a,(function(){return e.makeItem()})):[],s=o.slice(i);H(s,(function(e){return cm.remove(r,e)})),H(l,(function(e){return cm.append(r,e)}));var c=cm.contents(r);H(c,(function(r,o){e.setupItem(t,r,n[o],o)}))}))}}}},apis:{setItems:function(e,t,n){e.setItems(t,n)}}}),hV=v([Gr("dom"),ho("shell",!0),Vd("toolbarBehaviours",[cm])]),pV=v([af({name:"groups",overrides:function(){return{behaviours:Os([cm.config({})])}}})]),mV=Pf({name:"Toolbar",configFields:hV(),partFields:pV(),factory:function(e,t,n,r){var o=function(t){return e.shell?Q.some(t):Af(t,e,"groups")},i=e.shell?{behaviours:[cm.config({})],components:[]}:{behaviours:[],components:t};return{uid:e.uid,dom:e.dom,components:i.components,behaviours:Td(e.toolbarBehaviours,i.behaviours),apis:{setGroups:function(e,t){o(e).fold((function(){throw new Error("Toolbar was defined to not be a shell, but no groups container was specified in components")}),(function(e){cm.set(e,t)}))}},domModification:{attributes:{role:"group"}}}},apis:{setGroups:function(e,t,n){e.setGroups(t,n)}}}),gV=m,vV=x,AV=v([]),yV=Object.freeze({__proto__:null,setup:gV,isDocked:vV,getBehaviours:AV}),bV=function(e){return(we(rn(e,"position"),"fixed")?Q.none():St(e)).orThunk((function(){var t=Qe.fromTag("span");return kt(e).bind((function(e){Sn(e,t);var n=St(t);return Tn(t),n}))}))},OV=function(e){return bV(e).map(gn).getOrThunk((function(){return pn(0,0)}))},wV=xo([{static:[]},{absolute:["positionCss"]},{fixed:["positionCss"]}]),xV=function(e,t){var n=e.element;za(n,t.transitionClass),Ia(n,t.fadeOutClass),za(n,t.fadeInClass),t.onShow(e)},_V=function(e,t){var n=e.element;za(n,t.transitionClass),Ia(n,t.fadeInClass),za(n,t.fadeOutClass),t.onHide(e)},CV=function(e,t,n){return J(e,(function(e){switch(e){case"bottom":return function(e,t){return e.bottom<=t.bottom}(t,n);case"top":return function(e,t){return e.y>=t.y}(t,n)}}))},kV=function(e,t){return t.getInitialPos().map((function(t){return Rn(t.bounds.x,t.bounds.y,yn(e),dn(e))}))},SV=function(e,t,n){return n.getInitialPos().bind((function(r){switch(n.clearInitialPos(),r.position){case"static":return Q.some(wV.static());case"absolute":var o=bV(e).map(In).getOrThunk((function(){return In(Lt())}));return Q.some(wV.absolute(Ms("absolute",ye(r.style,"left").map((function(e){return t.x-o.x})),ye(r.style,"top").map((function(e){return t.y-o.y})),ye(r.style,"right").map((function(e){return o.right-t.right})),ye(r.style,"bottom").map((function(e){return o.bottom-t.bottom})))));default:return Q.none()}}))},VV=function(e,t,n){var r=In(e);if(CV(n.getModes(),r,t))return Q.none();!function(e,t,n){n.setInitialPos({style:on(e),position:tn(e,"position")||"static",bounds:t})}(e,r,n);var o=Fn(),i=r.x-o.x,a=t.y-o.y,l=o.bottom-t.bottom,s=r.y<=t.y;return Q.some(wV.fixed(Ms("fixed",Q.some(i),s?Q.some(a):Q.none(),Q.none(),s?Q.none():Q.some(l))))},BV=function(e,t,n){var r=e.element;return we(rn(r,"position"),"fixed")?function(e,t,n){return kV(e,n).filter((function(e){return CV(n.getModes(),e,t)})).bind((function(t){return SV(e,t,n)}))}(r,t,n):VV(r,t,n)},TV=function(e,t,n){n.setDocked(!1),H(["left","right","top","bottom","position"],(function(t){return ln(e.element,t)})),t.onUndocked(e)},NV=function(e,t,n,r){var o="fixed"===r.position;n.setDocked(o),Ds(e.element,r),(o?t.onDocked:t.onUndocked)(e)},EV=function(e,t,n,r,o){void 0===o&&(o=!1),t.contextual.each((function(t){t.lazyContext(e).each((function(i){var a=function(e,t){return e.yt.y}(i,r);a!==n.isVisible()&&(n.setVisible(a),o&&!a?(Fa(e.element,[t.fadeOutClass]),t.onHide(e)):(a?xV:_V)(e,t))}))}))},PV=function(e,t,n){var r=e.element;n.setDocked(!1),function(e,t){var n=e.element;return kV(n,t).bind((function(e){return SV(n,e,t)}))}(e,n).each((function(r){r.fold((function(){return TV(e,t,n)}),(function(r){return NV(e,t,n,r)}),m)})),n.setVisible(!0),t.contextual.each((function(t){Ua(r,[t.fadeInClass,t.fadeOutClass,t.transitionClass]),t.onShow(e)})),QV(e,t,n)},QV=function(e,t,n){e.getSystem().isConnected()&&function(e,t,n){var r=t.lazyViewport(e);n.isDocked()&&EV(e,t,n,r),BV(e,r,n).each((function(o){o.fold((function(){return TV(e,t,n)}),(function(r){return NV(e,t,n,r)}),(function(o){EV(e,t,n,r,!0),NV(e,t,n,o)}))}))}(e,t,n)},MV=function(e,t,n){n.isDocked()&&PV(e,t,n)},DV=Object.freeze({__proto__:null,refresh:QV,reset:MV,isDocked:function(e,t,n){return n.isDocked()},getModes:function(e,t,n){return n.getModes()},setModes:function(e,t,n,r){return n.setModes(r)}}),$V=Object.freeze({__proto__:null,events:function(e,t){return Di([ji(ei(),(function(n,r){e.contextual.each((function(e){La(n.element,e.transitionClass)&&(Ua(n.element,[e.transitionClass,e.fadeInClass]),(t.isVisible()?e.onShown:e.onHidden)(n));r.stop()}))})),Ri(Ai(),(function(n,r){QV(n,e,t)})),Ri(yi(),(function(n,r){MV(n,e,t)}))])}}),zV=[fo("contextual",[Jr("fadeInClass"),Jr("fadeOutClass"),Jr("transitionClass"),to("lazyContext"),Vl("onShow"),Vl("onShown"),Vl("onHide"),Vl("onHidden")]),yo("lazyViewport",Fn),bo("modes",["top","bottom"],Pr),Vl("onDocked"),Vl("onUndocked")],RV=xs({fields:zV,name:"docking",active:$V,apis:DV,state:Object.freeze({__proto__:null,init:function(e){var t=wo(!1),n=wo(!0),r=ec(),o=wo(e.modes);return wa({isDocked:t.get,setDocked:t.set,getInitialPos:r.get,setInitialPos:r.set,clearInitialPos:r.clear,isVisible:n.get,setVisible:n.set,getModes:o.get,setModes:o.set,readState:function(){return"docked: "+t.get()+", visible: "+n.get()+", modes: "+o.get().join(",")}})}})}),IV=v(ia("toolbar-height-change")),LV={fadeInClass:"tox-editor-dock-fadein",fadeOutClass:"tox-editor-dock-fadeout",transitionClass:"tox-editor-dock-transition"},FV="tox-tinymce--toolbar-sticky-on",UV="tox-tinymce--toolbar-sticky-off",HV=function(e,t){return R(RV.getModes(e),t)},WV=function(e){var t=e.element;kt(t).each((function(n){var r="padding-"+RV.getModes(e)[0];if(RV.isDocked(e)){var o=yn(n);Kt(t,"width",o+"px"),Kt(n,r,function(e){return fn(e)+(parseInt(tn(e,"margin-top"),10)||0)+(parseInt(tn(e,"margin-bottom"),10)||0)}(t)+"px")}else ln(t,"width"),ln(n,r)}))},jV=function(e,t){t?(Ia(e,LV.fadeOutClass),Fa(e,[LV.transitionClass,LV.fadeInClass])):(Ia(e,LV.fadeInClass),Fa(e,[LV.fadeOutClass,LV.transitionClass]))},qV=function(e,t){var n=Qe.fromDom(e.getContainer());t?(za(n,FV),Ia(n,UV)):(za(n,UV),Ia(n,FV))},XV=function(e,t){var n=ec(),r=t.getSink,o=function(e){r().each((function(t){return e(t.element)}))},i=function(t){e.inline||WV(t),qV(e,RV.isDocked(t)),t.getSystem().broadcastOn([cd()],{}),r().each((function(e){return e.getSystem().broadcastOn([cd()],{})}))},a=e.inline?[]:function(){var e;return[Ss.config({channels:(e={},e[IV()]={onReceive:WV},e)})]}();return V([mm.config({}),RV.config({contextual:k({lazyContext:function(t){var n=fn(t.element),r=e.inline?e.getContentAreaContainer():e.getContainer(),o=In(Qe.fromDom(r)),i=o.height-n,a=o.y+(HV(t,"top")?0:n);return Q.some(Rn(o.x,a,o.width,i))},onShow:function(){o((function(e){return jV(e,!0)}))},onShown:function(e){o((function(e){return Ua(e,[LV.transitionClass,LV.fadeInClass])})),n.get().each((function(t){var r,o,i;r=e.element,i=wt(o=t),Es(i).filter((function(e){return!yt(o,e)})).filter((function(e){return yt(e,Qe.fromDom(i.dom.body))||Ot(r,e)})).each((function(){return Ts(o)})),n.clear()}))},onHide:function(e){(function(e,t){return Ps(e).orThunk((function(){return t().toOptional().bind((function(e){return Ps(e.element)}))}))})(e.element,r).fold(n.clear,n.set),o((function(e){return jV(e,!1)}))},onHidden:function(){o((function(e){return Ua(e,[LV.transitionClass])}))}},LV),lazyViewport:function(t){var n=Fn(),r=function(e){return e.getParam("toolbar_sticky_offset",0,"number")}(e),o=n.y+(HV(t,"top")?r:0),i=n.height-(HV(t,"bottom")?r:0);return Rn(n.x,o,n.width,i)},modes:[t.header.getDockingMode()],onDocked:i,onUndocked:i})],a,!0)},YV=Object.freeze({__proto__:null,setup:function(e,t,n){e.inline||(t.header.isPositionedAtTop()||e.on("ResizeEditor",(function(){n().each(RV.reset)})),e.on("ResizeWindow ResizeEditor",(function(){n().each(WV)})),e.on("SkinLoaded",(function(){n().each((function(e){RV.isDocked(e)?RV.reset(e):RV.refresh(e)}))})),e.on("FullscreenStateChanged",(function(){n().each(RV.reset)}))),e.on("AfterScrollIntoView",(function(e){n().each((function(t){RV.refresh(t);var n=t.element;Zh(n)&&function(e,t){var n=wt(t),r=n.dom.defaultView.innerHeight,o=En(n),i=Qe.fromDom(e.elm),a=Ln(i),l=dn(i),s=a.y,c=s+l,u=gn(t),d=dn(t),f=u.top,h=f+d,p=Math.abs(f-o.top)<2,m=Math.abs(h-(o.top+r))<2;if(p&&sf){var g=s-r+l+d;Pn(o.left,g,n)}}(e,n)}))})),e.on("PostRender",(function(){qV(e,!1)}))},isDocked:function(e){return e().map(RV.isDocked).getOr(!1)},getBehaviours:XV}),GV=Cr([Jr("type"),Zr("items",Sr([Br([Jr("name"),oo("items",Pr)]),Pr]))].concat(nv)),ZV=[so("text"),so("tooltip"),so("icon"),to("fetch"),yo("onSetup",(function(){return m}))],KV=Cr(V([Jr("type")],ZV,!0)),JV=function(e){return Fr("menubutton",KV,e)},eB=Cr([Jr("type"),so("tooltip"),so("icon"),so("text"),co("select"),to("fetch"),yo("onSetup",(function(){return m})),vo("presets","normal",["normal","color","listpreview"]),ho("columns",1),to("onAction"),to("onItemAction")]),tB=Ef({factory:function(e,t){var n={focus:rm.focusIn,setMenus:function(e,n){var r=U(n,(function(e){var n={type:"menubutton",text:e.text,fetch:function(t){t(e.getItems())}},r=JV(n).mapError((function(e){return Wr(e)})).getOrDie();return WC(r,"tox-mbtn",t.backstage,Q.some("menuitem"))}));cm.set(e,r)}};return{uid:e.uid,dom:e.dom,components:[],behaviours:Os([cm.config({}),um("menubar-events",[qi((function(t){e.onSetup(t)})),Ri(Wo(),(function(e,t){ul(e.element,".tox-mbtn--active").each((function(n){dl(t.event.target,".tox-mbtn").each((function(t){yt(n,t)||e.getSystem().getByDom(n).each((function(n){e.getSystem().getByDom(t).each((function(e){uw.expand(e),uw.close(n),mm.focus(e)}))}))}))}))})),Ri(_i(),(function(e,t){t.event.prevFocus.bind((function(t){return e.getSystem().getByDom(t).toOptional()})).each((function(n){t.event.newFocus.bind((function(t){return e.getSystem().getByDom(t).toOptional()})).each((function(e){uw.isOpen(n)&&(uw.expand(e),uw.close(n))}))}))}))]),rm.config({mode:"flow",selector:".tox-mbtn",onEscape:function(t){return e.onEscape(t),Q.some(!0)}}),nO.config({})]),apis:n,domModification:{attributes:{role:"menubar"}}}},name:"silver.Menubar",configFields:[Gr("dom"),Gr("uid"),Gr("onEscape"),Gr("backstage"),ho("onSetup",m)],apis:{focus:function(e,t){e.focus(t)},setMenus:function(e,t,n){e.setMenus(t,n)}}}),nB=function(e,t){return t.getAnimationRoot.fold((function(){return e.element}),(function(t){return t(e)}))},rB=function(e){return e.dimension.property},oB=function(e,t){return e.dimension.getDimension(t)},iB=function(e,t){var n=nB(e,t);Ua(n,[t.shrinkingClass,t.growingClass])},aB=function(e,t){Ia(e.element,t.openClass),za(e.element,t.closedClass),Kt(e.element,rB(t),"0px"),sn(e.element)},lB=function(e,t){Ia(e.element,t.closedClass),za(e.element,t.openClass),ln(e.element,rB(t))},sB=function(e,t,n,r){n.setCollapsed(),Kt(e.element,rB(t),oB(t,e.element)),sn(e.element),iB(e,t),aB(e,t),t.onStartShrink(e),t.onShrunk(e)},cB=function(e,t,n,r){var o=r.getOrThunk((function(){return oB(t,e.element)}));n.setCollapsed(),Kt(e.element,rB(t),o),sn(e.element);var i=nB(e,t);Ia(i,t.growingClass),za(i,t.shrinkingClass),aB(e,t),t.onStartShrink(e)},uB=function(e,t,n){var r=oB(t,e.element);("0px"===r?sB:cB)(e,t,n,Q.some(r))},dB=function(e,t,n){var r=nB(e,t),o=La(r,t.shrinkingClass),i=oB(t,e.element);lB(e,t);var a=oB(t,e.element);(o?function(){Kt(e.element,rB(t),i),sn(e.element)}:function(){aB(e,t)})(),Ia(r,t.shrinkingClass),za(r,t.growingClass),lB(e,t),Kt(e.element,rB(t),a),n.setExpanded(),t.onStartGrow(e)},fB=function(e,t,n){var r=nB(e,t);return!0===La(r,t.growingClass)},hB=function(e,t,n){var r=nB(e,t);return!0===La(r,t.shrinkingClass)},pB=Object.freeze({__proto__:null,refresh:function(e,t,n){if(n.isExpanded()){ln(e.element,rB(t));var r=oB(t,e.element);Kt(e.element,rB(t),r)}},grow:function(e,t,n){n.isExpanded()||dB(e,t,n)},shrink:function(e,t,n){n.isExpanded()&&uB(e,t,n)},immediateShrink:function(e,t,n){n.isExpanded()&&sB(e,t,n)},hasGrown:function(e,t,n){return n.isExpanded()},hasShrunk:function(e,t,n){return n.isCollapsed()},isGrowing:fB,isShrinking:hB,isTransitioning:function(e,t,n){return fB(e,t)||hB(e,t)},toggleGrow:function(e,t,n){(n.isExpanded()?uB:dB)(e,t,n)},disableTransitions:iB}),mB=Object.freeze({__proto__:null,exhibit:function(e,t,n){var r=t.expanded;return _a(r?{classes:[t.openClass],styles:{}}:{classes:[t.closedClass],styles:ko(t.dimension.property,"0px")})},events:function(e,t){return Di([ji(ei(),(function(n,r){r.event.raw.propertyName===e.dimension.property&&(iB(n,e),t.isExpanded()&&ln(n.element,e.dimension.property),(t.isExpanded()?e.onGrown:e.onShrunk)(n))}))])}}),gB=[Gr("closedClass"),Gr("openClass"),Gr("shrinkingClass"),Gr("growingClass"),io("getAnimationRoot"),Vl("onShrunk"),Vl("onStartShrink"),Vl("onGrown"),Vl("onStartGrow"),ho("expanded",!1),Zr("dimension",jr("property",{width:[El("property","width"),El("getDimension",(function(e){return yn(e)+"px"}))],height:[El("property","height"),El("getDimension",(function(e){return dn(e)+"px"}))]}))],vB=xs({fields:gB,name:"sliding",active:mB,apis:pB,state:Object.freeze({__proto__:null,init:function(e){var t=wo(e.expanded);return wa({isExpanded:function(){return!0===t.get()},isCollapsed:function(){return!1===t.get()},setCollapsed:b(t.set,!1),setExpanded:b(t.set,!0),readState:function(){return"expanded: "+t.get()}})}})}),AB="container",yB=[Vd("slotBehaviours",[])],bB=function(e){return""},OB=function(e,t){var n,r=function(t){return wf(e)},o=function(t,n){return function(r,o){return Af(r,e,o).map((function(e){return t(e,o)})).getOr(n)}},i=function(e,t){return"true"!==jt(e.element,"aria-hidden")},a=o(i,!1),l=o((function(e,t){if(i(e)){var n=e.element;Kt(n,"display","none"),Ht(n,"aria-hidden","true"),Ni(e,Ci(),{name:t,visible:!1})}})),s=(n=l,function(e,t){H(t,(function(t){return n(e,t)}))}),c=o((function(e,t){if(!i(e)){var n=e.element;ln(n,"display"),Yt(n,"aria-hidden"),Ni(e,Ci(),{name:t,visible:!0})}})),u={getSlotNames:r,getSlot:function(t,n){return Af(t,e,n)},isShowing:a,hideSlot:l,hideAllSlots:function(e){return s(e,r())},showSlot:c};return{uid:e.uid,dom:e.dom,components:t,behaviours:Bd(e.slotBehaviours),apis:u}},wB=he({getSlotNames:function(e,t){return e.getSlotNames(t)},getSlot:function(e,t,n){return e.getSlot(t,n)},isShowing:function(e,t,n){return e.isShowing(t,n)},hideSlot:function(e,t,n){return e.hideSlot(t,n)},hideAllSlots:function(e,t){return e.hideAllSlots(t)},showSlot:function(e,t,n){return e.showSlot(t,n)}},(function(e){return ba(e)})),xB=k(k({},wB),{sketch:function(e){var t=function(){var e=[];return{slot:function(t,n){return e.push(t),hf(AB,bB(t),n)},record:v(e)}}(),n=e(t),r=t.record(),o=U(r,(function(e){return rf({name:e,pname:bB(e)})}));return Vf(AB,yB,o,OB,n)}}),_B=Cr([so("icon"),so("tooltip"),yo("onShow",m),yo("onHide",m),yo("onSetup",(function(){return m}))]),CB=function(e){return{element:function(){return e.element.dom}}},kB=function(e,t){var n=U(ue(t),(function(e){var n=t[e],r=Ur(function(e){return Fr("sidebar",_B,e)}(n));return{name:e,getApi:CB,onSetup:r.onSetup,onShow:r.onShow,onHide:r.onHide}}));return U(n,(function(t){var r=wo(m);return e.slot(t.name,{dom:{tag:"div",classes:["tox-sidebar__pane"]},behaviours:sA([ey(t,r),ty(t,r),Ri(Ci(),(function(e,t){var r=t.event,o=Y(n,(function(e){return e.name===r.name}));o.each((function(t){(r.visible?t.onShow:t.onHide)(t.getApi(e))}))}))])})}))},SB=function(e){return xB.sketch((function(t){return{dom:{tag:"div",classes:["tox-sidebar__pane-container"]},components:kB(t,e),slotBehaviours:sA([qi((function(e){return xB.hideAllSlots(e)}))])}}))},VB=function(e){return $f.getCurrent(e).bind((function(e){return vB.isGrowing(e)||vB.hasGrown(e)?$f.getCurrent(e).bind((function(e){return Y(xB.getSlotNames(e),(function(t){return xB.isShowing(e,t)}))})):Q.none()}))},BB=ia("FixSizeEvent"),TB=ia("AutoSizeEvent"),NB=Object.freeze({__proto__:null,block:function(e,t,n,r){Ht(e.element,"aria-busy",!0);var o=t.getRoot(e).getOr(e),i=Os([rm.config({mode:"special",onTab:function(){return Q.some(!0)},onShiftTab:function(){return Q.some(!0)}}),mm.config({})]),a=r(o,i),l=o.getSystem().build(a);cm.append(o,nl(l)),l.hasConfigured(rm)&&t.focus&&rm.focusIn(l),n.isBlocked()||t.onBlock(e),n.blockWith((function(){return cm.remove(o,l)}))},unblock:function(e,t,n){Yt(e.element,"aria-busy"),n.isBlocked()&&t.onUnblock(e),n.clear()}}),EB=[yo("getRoot",Q.none),Ao("focus",!0),Vl("onBlock"),Vl("onUnblock")],PB=xs({fields:EB,name:"blocking",apis:NB,state:Object.freeze({__proto__:null,init:function(){var e=Ks();return wa({readState:e.isSet,blockWith:function(t){e.set({destroy:t})},clear:e.clear,isBlocked:e.isSet})}})}),QB=function(e){var t=Qe.fromHtml(e),n=Vt(t),r=function(e){var t=void 0!==e.dom.attributes?e.dom.attributes:[];return X(t,(function(e,t){var n;return"class"===t.name?e:k(k({},e),((n={})[t.name]=t.value,n))}),{})}(t),o=function(e){return Array.prototype.slice.call(e.dom.classList,0)}(t),i=0===n.length?{}:{innerHtml:Zi(t)};return k({tag:De(t),classes:o,attributes:r},i)},MB=function(e){return $f.getCurrent(e).each((function(e){return Ts(e.element)}))},DB=function(e,t,n,r){var o=t.element;if(function(e,t){var n="tabindex",r="data-mce-"+n;Q.from(e.iframeElement).map(Qe.fromDom).each((function(e){t?(qt(e,n).each((function(t){return Ht(e,r,t)})),Ht(e,n,-1)):(Yt(e,n),qt(e,r).each((function(t){Ht(e,n,t),Yt(e,r)})))}))}(e,n),n)PB.block(t,function(e){return function(t,n){return{dom:{tag:"div",attributes:{"aria-label":e.translate("Loading..."),tabindex:"0"},classes:["tox-throbber__busy-spinner"]},components:[{dom:QB('
')}]}}}(r)),ln(o,"display"),Yt(o,"aria-hidden"),e.hasFocus()&&MB(t);else{var i=$f.getCurrent(t).exists((function(e){return Ns(e.element)}));PB.unblock(t),Kt(o,"display","none"),Ht(o,"aria-hidden","true"),i&&e.focus()}},$B=function(e,t,n){var r=wo(!1),o=ec(),i=function(n){var o;!r.get()||function(e){return"focusin"===e.type}(o=n)&&(o.composed?ae(o.composedPath()):Q.from(o.target)).map(Qe.fromDom).filter(ze).exists((function(e){return La(e,"mce-pastebin")}))||(n.preventDefault(),MB(t()),e.editorManager.setActive(e))};e.inline||e.on("PreInit",(function(){e.dom.bind(e.getWin(),"focusin",i),e.on("BeforeExecCommand",(function(e){"mcefocus"===e.command.toLowerCase()&&!0!==e.value&&i(e)}))}));var a=function(o){o!==r.get()&&(r.set(o),DB(e,t(),o,n.providers),e.fire("AfterProgressState",{state:o}))};e.on("ProgressState",(function(t){if(o.on(Ag.clearTimeout),h(t.time)){var n=Ag.setEditorTimeout(e,(function(){return a(t.state)}),t.time);o.set(n)}else a(t.state),o.clear()}))},zB=function(e,t,n){return{within:e,extra:t,withinWidth:n}},RB=function(e,t,n){var r=function(e,t){var n=X(e,(function(e,n){return t(n,e.len).fold(v(e),(function(t){return{len:t.finish,list:e.list.concat([t])}}))}),{len:0,list:[]});return n.list}(e,(function(e,t){var r=n(e);return Q.some({element:e,start:t,finish:t+r,width:r})})),o=j(r,(function(e){return e.finish<=t})),i=q(o,(function(e,t){return e+t.width}),0);return{within:o,extra:r.slice(o.length),withinWidth:i}},IB=function(e){return U(e,(function(e){return e.element}))},LB=function(e,t,n,r){var o=function(e,t,n){var r=RB(t,e,n);return 0===r.extra.length?Q.some(r):Q.none()}(e,t,n).getOrThunk((function(){return RB(t,e-n(r),n)})),i=o.within,a=o.extra,l=o.withinWidth;return 1===a.length&&a[0].width<=n(r)?function(e,t,n){var r=IB(e.concat(t));return zB(r,[],n)}(i,a,l):a.length>=1?function(e,t,n,r){var o=IB(e).concat([n]);return zB(o,IB(t),r)}(i,a,r,l):function(e,t,n){return zB(IB(e),[],n)}(i,0,l)},FB=function(e,t){var n=U(t,(function(e){return nl(e)}));mV.setGroups(e,n)},UB=function(e,t,n){var r=t.builtGroups.get();if(0!==r.length){var o=yf(e,t,"primary"),i=jO.getCoupled(e,"overflowGroup");Kt(o.element,"visibility","hidden");var a=r.concat([i]),l=ce(a,(function(e){return Ps(e.element).bind((function(t){return e.getSystem().getByDom(t).toOptional()}))}));n([]),FB(o,a);var s=yn(o.element),c=LB(s,t.builtGroups.get(),(function(e){return yn(e.element)}),i);0===c.extra.length?(cm.remove(o,i),n([])):(FB(o,c.within),n(c.extra)),ln(o.element,"visibility"),sn(o.element),l.each(mm.focus)}},HB=v([Vd("splitToolbarBehaviours",[jO]),Xr("builtGroups",(function(){return wo([])}))]),WB=v([kl(["overflowToggledClass"]),co("getOverflowBounds"),Gr("lazySink"),Xr("overflowGroups",(function(){return wo([])}))].concat(HB())),jB=v([rf({factory:mV,schema:hV(),name:"primary"}),of({schema:hV(),name:"overflow"}),of({name:"overflow-button"}),of({name:"overflow-group"})]),qB=v((function(e,t){!function(e,t){var n=An.max(e,t,["margin-left","border-left-width","padding-left","padding-right","border-right-width","margin-right"]);Kt(e,"max-width",n+"px")}(e,Math.floor(t))})),XB=v([kl(["toggledClass"]),Gr("lazySink"),to("fetch"),co("getBounds"),fo("fireDismissalEventInstead",[ho("event",wi())]),kc()]),YB=v([of({name:"button",overrides:function(e){return{dom:{attributes:{"aria-haspopup":"true"}},buttonBehaviours:Os([Sm.config({toggleClass:e.markers.toggledClass,aria:{mode:"expanded"},toggleOnExecute:!1})])}}}),of({factory:mV,schema:hV(),name:"toolbar",overrides:function(e){return{toolbarBehaviours:Os([rm.config({mode:"cyclic",onEscape:function(t){return Af(t,e,"button").each(mm.focus),Q.none()}})])}}})]),GB=function(e,t){var n=jO.getCoupled(e,"toolbarSandbox");ld.isOpen(n)?ld.close(n):ld.open(n,t.toolbar())},ZB=function(e,t,n,r){var o=n.getBounds.map((function(e){return e()})),i=n.lazySink(e).getOrDie();zu.positionWithinBounds(i,t,{anchor:{type:"hotspot",hotspot:e,layouts:r,overrides:{maxWidthFunction:qB()}}},o)},KB=function(e,t,n,r,o){mV.setGroups(t,o),ZB(e,t,n,r),Sm.on(e)},JB=Pf({name:"FloatingToolbarButton",factory:function(e,t,n,r){return k(k({},yg.sketch(k(k({},r.button()),{action:function(e){GB(e,r)},buttonBehaviours:Ed({dump:r.button().buttonBehaviours},[jO.config({others:{toolbarSandbox:function(t){return function(e,t,n){var r=fl();return{dom:{tag:"div",attributes:{id:r.id}},behaviours:Os([rm.config({mode:"special",onEscape:function(e){return ld.close(e),Q.some(!0)}}),ld.config({onOpen:function(o,i){n.fetch().get((function(o){KB(e,i,n,t.layouts,o),r.link(e.element),rm.focusIn(i)}))},onClose:function(){Sm.off(e),mm.focus(e),r.unlink(e.element)},isPartOf:function(t,n,r){return pl(n,r)||pl(e,r)},getAttachPoint:function(){return n.lazySink(e).getOrDie()}}),Ss.config({channels:k(k({},fd(k({isExtraPart:x},n.fireDismissalEventInstead.map((function(e){return{fireEventInstead:{event:e.event}}})).getOr({})))),pd({doReposition:function(){ld.getState(jO.getCoupled(e,"toolbarSandbox")).each((function(r){ZB(e,r,n,t.layouts)}))}}))})])}}(t,n,e)}}})])}))),{apis:{setGroups:function(t,r){ld.getState(jO.getCoupled(t,"toolbarSandbox")).each((function(o){KB(t,o,e,n.layouts,r)}))},reposition:function(t){ld.getState(jO.getCoupled(t,"toolbarSandbox")).each((function(r){ZB(t,r,e,n.layouts)}))},toggle:function(e){GB(e,r)},getToolbar:function(e){return ld.getState(jO.getCoupled(e,"toolbarSandbox"))},isOpen:function(e){return ld.isOpen(jO.getCoupled(e,"toolbarSandbox"))}}})},configFields:XB(),partFields:YB(),apis:{setGroups:function(e,t,n){e.setGroups(t,n)},reposition:function(e,t){e.reposition(t)},toggle:function(e,t){e.toggle(t)},getToolbar:function(e,t){return e.getToolbar(t)},isOpen:function(e,t){return e.isOpen(t)}}}),eT=v([Gr("items"),kl(["itemSelector"]),Vd("tgroupBehaviours",[rm])]),tT=v([lf({name:"items",unit:"item"})]),nT=Pf({name:"ToolbarGroup",configFields:eT(),partFields:tT(),factory:function(e,t,n,r){return{uid:e.uid,dom:e.dom,components:t,behaviours:Td(e.tgroupBehaviours,[rm.config({mode:"flow",selector:e.markers.itemSelector})]),domModification:{attributes:{role:"toolbar"}}}}}),rT=function(e){return U(e,(function(e){return nl(e)}))},oT=function(e,t,n){UB(e,n,(function(r){n.overflowGroups.set(r),t.getOpt(e).each((function(e){JB.setGroups(e,rT(r))}))}))},iT=Pf({name:"SplitFloatingToolbar",configFields:WB(),partFields:jB(),factory:function(e,t,n,r){var o=bg(JB.sketch({fetch:function(){return NO((function(t){t(rT(e.overflowGroups.get()))}))},layouts:{onLtr:function(){return[ns,ts]},onRtl:function(){return[ts,ns]},onBottomLtr:function(){return[os,rs]},onBottomRtl:function(){return[rs,os]}},getBounds:n.getOverflowBounds,lazySink:e.lazySink,fireDismissalEventInstead:{},markers:{toggledClass:e.markers.overflowToggledClass},parts:{button:r["overflow-button"](),toolbar:r.overflow()}}));return{uid:e.uid,dom:e.dom,components:t,behaviours:Td(e.splitToolbarBehaviours,[jO.config({others:{overflowGroup:function(){return nT.sketch(k(k({},r["overflow-group"]()),{items:[o.asSpec()]}))}}})]),apis:{setGroups:function(t,n){e.builtGroups.set(U(n,t.getSystem().build)),oT(t,o,e)},refresh:function(t){return oT(t,o,e)},toggle:function(e){o.getOpt(e).each((function(e){JB.toggle(e)}))},isOpen:function(e){return o.getOpt(e).map(JB.isOpen).getOr(!1)},reposition:function(e){o.getOpt(e).each((function(e){JB.reposition(e)}))},getOverflow:function(e){return o.getOpt(e).bind(JB.getToolbar)}},domModification:{attributes:{role:"group"}}}},apis:{setGroups:function(e,t,n){e.setGroups(t,n)},refresh:function(e,t){e.refresh(t)},reposition:function(e,t){e.reposition(t)},toggle:function(e,t){e.toggle(t)},isOpen:function(e,t){return e.isOpen(t)},getOverflow:function(e,t){return e.getOverflow(t)}}}),aT=v([kl(["closedClass","openClass","shrinkingClass","growingClass","overflowToggledClass"]),Vl("onOpened"),Vl("onClosed")].concat(HB())),lT=v([rf({factory:mV,schema:hV(),name:"primary"}),rf({factory:mV,schema:hV(),name:"overflow",overrides:function(e){return{toolbarBehaviours:Os([vB.config({dimension:{property:"height"},closedClass:e.markers.closedClass,openClass:e.markers.openClass,shrinkingClass:e.markers.shrinkingClass,growingClass:e.markers.growingClass,onShrunk:function(t){Af(t,e,"overflow-button").each((function(e){Sm.off(e),mm.focus(e)})),e.onClosed(t)},onGrown:function(t){rm.focusIn(t),e.onOpened(t)},onStartGrow:function(t){Af(t,e,"overflow-button").each(Sm.on)}}),rm.config({mode:"acyclic",onEscape:function(t){return Af(t,e,"overflow-button").each(mm.focus),Q.some(!0)}})])}}}),of({name:"overflow-button",overrides:function(e){return{buttonBehaviours:Os([Sm.config({toggleClass:e.markers.overflowToggledClass,aria:{mode:"pressed"},toggleOnExecute:!1})])}}}),of({name:"overflow-group"})]),sT=function(e,t){Af(e,t,"overflow-button").bind((function(){return Af(e,t,"overflow")})).each((function(n){cT(e,t),vB.toggleGrow(n)}))},cT=function(e,t){Af(e,t,"overflow").each((function(n){UB(e,t,(function(e){var t=U(e,(function(e){return nl(e)}));mV.setGroups(n,t)})),Af(e,t,"overflow-button").each((function(e){vB.hasGrown(n)&&Sm.on(e)})),vB.refresh(n)}))},uT=Pf({name:"SplitSlidingToolbar",configFields:aT(),partFields:lT(),factory:function(e,t,n,r){var o="alloy.toolbar.toggle";return{uid:e.uid,dom:e.dom,components:t,behaviours:Td(e.splitToolbarBehaviours,[jO.config({others:{overflowGroup:function(e){return nT.sketch(k(k({},r["overflow-group"]()),{items:[yg.sketch(k(k({},r["overflow-button"]()),{action:function(t){Ti(e,o)}}))]}))}}}),um("toolbar-toggle-events",[Ri(o,(function(t){sT(t,e)}))])]),apis:{setGroups:function(t,n){!function(t,n){var r=U(n,t.getSystem().build);e.builtGroups.set(r)}(t,n),cT(t,e)},refresh:function(t){return cT(t,e)},toggle:function(t){return sT(t,e)},isOpen:function(t){return function(e,t){return Af(e,t,"overflow").map(vB.hasGrown).getOr(!1)}(t,e)}},domModification:{attributes:{role:"group"}}}},apis:{setGroups:function(e,t,n){e.setGroups(t,n)},refresh:function(e,t){e.refresh(t)},toggle:function(e,t){e.toggle(t)},isOpen:function(e,t){return e.isOpen(t)}}}),dT=function(e){var t=e.title.fold((function(){return{}}),(function(e){return{attributes:{title:e}}}));return{dom:k({tag:"div",classes:["tox-toolbar__group"]},t),components:[nT.parts.items({})],items:e.items,markers:{itemSelector:"*:not(.tox-split-button) > .tox-tbtn:not([disabled]), .tox-split-button:not([disabled]), .tox-toolbar-nav-js:not([disabled])"},tgroupBehaviours:Os([nO.config({}),mm.config({})])}},fT=function(e){return nT.sketch(dT(e))},hT=function(e,t){var n=qi((function(t){var n=U(e.initGroups,fT);mV.setGroups(t,n)}));return Os([KA(e.providers.isDisabled),XA(),rm.config({mode:t,onEscape:e.onEscape,selector:".tox-toolbar__group"}),um("toolbar-events",[n])])},pT=function(e){var t=e.cyclicKeying?"cyclic":"acyclic";return{uid:e.uid,dom:{tag:"div",classes:["tox-toolbar-overlord"]},parts:{"overflow-group":dT({title:Q.none(),items:[]}),"overflow-button":XC({name:"more",icon:Q.some("more-drawer"),disabled:!1,tooltip:Q.some("More..."),primary:!1,borderless:!1},Q.none(),e.providers)},splitToolbarBehaviours:hT(e,t)}},mT=function(e){var t=pT(e),n=iT.parts.primary({dom:{tag:"div",classes:["tox-toolbar__primary"]}});return iT.sketch(k(k({},t),{lazySink:e.getSink,getOverflowBounds:function(){var t=e.moreDrawerData.lazyHeader().element,n=Ln(t),r=_t(t),o=Ln(r),i=Math.max(r.dom.scrollHeight,o.height);return Rn(n.x+4,o.y,n.width-8,i)},parts:k(k({},t.parts),{overflow:{dom:{tag:"div",classes:["tox-toolbar__overflow"],attributes:e.attributes}}}),components:[n],markers:{overflowToggledClass:"tox-tbtn--enabled"}}))},gT=function(e){var t=uT.parts.primary({dom:{tag:"div",classes:["tox-toolbar__primary"]}}),n=uT.parts.overflow({dom:{tag:"div",classes:["tox-toolbar__overflow"]}}),r=pT(e);return uT.sketch(k(k({},r),{components:[t,n],markers:{openClass:"tox-toolbar__overflow--open",closedClass:"tox-toolbar__overflow--closed",growingClass:"tox-toolbar__overflow--growing",shrinkingClass:"tox-toolbar__overflow--shrinking",overflowToggledClass:"tox-tbtn--enabled"},onOpened:function(e){e.getSystem().broadcastOn([IV()],{type:"opened"})},onClosed:function(e){e.getSystem().broadcastOn([IV()],{type:"closed"})}}))},vT=function(e){var t=e.cyclicKeying?"cyclic":"acyclic";return mV.sketch({uid:e.uid,dom:{tag:"div",classes:["tox-toolbar"].concat(e.type===vv.scrolling?["tox-toolbar--scrolling"]:[])},components:[mV.parts.groups({})],toolbarBehaviours:hT(e,t)})},AT=lV.optional({factory:tB,name:"menubar",schema:[Gr("backstage")]}),yT=lV.optional({factory:{sketch:function(e){return fV.sketch({uid:e.uid,dom:e.dom,listBehaviours:Os([rm.config({mode:"acyclic",selector:".tox-toolbar"})]),makeItem:function(){return vT({type:e.type,uid:ia("multiple-toolbar-item"),cyclicKeying:!1,initGroups:[],providers:e.providers,onEscape:function(){return e.onEscape(),Q.some(!0)}})},setupItem:function(e,t,n,r){mV.setGroups(t,n)},shell:!0})}},name:"multiple-toolbar",schema:[Gr("dom"),Gr("onEscape")]}),bT=lV.optional({factory:{sketch:function(e){var t=function(e){return e.type===vv.sliding?gT:e.type===vv.floating?mT:vT}(e);return t({type:e.type,uid:e.uid,onEscape:function(){return e.onEscape(),Q.some(!0)},cyclicKeying:!1,initGroups:[],getSink:e.getSink,providers:e.providers,moreDrawerData:{lazyToolbar:e.lazyToolbar,lazyMoreButton:e.lazyMoreButton,lazyHeader:e.lazyHeader},attributes:e.attributes})}},name:"toolbar",schema:[Gr("dom"),Gr("onEscape"),Gr("getSink")]}),OT=lV.optional({factory:{sketch:function(e){var t=e.editor,n=e.sticky?XV:AV;return{uid:e.uid,dom:e.dom,components:e.components,behaviours:Os(n(t,e.sharedBackstage))}}},name:"header",schema:[Gr("dom")]}),wT=lV.optional({name:"socket",schema:[Gr("dom")]}),xT=lV.optional({factory:{sketch:function(e){return{uid:e.uid,dom:{tag:"div",classes:["tox-sidebar"],attributes:{role:"complementary"}},components:[{dom:{tag:"div",classes:["tox-sidebar__slider"]},components:[],behaviours:Os([nO.config({}),mm.config({}),vB.config({dimension:{property:"width"},closedClass:"tox-sidebar--sliding-closed",openClass:"tox-sidebar--sliding-open",shrinkingClass:"tox-sidebar--sliding-shrinking",growingClass:"tox-sidebar--sliding-growing",onShrunk:function(e){$f.getCurrent(e).each(xB.hideAllSlots),Ti(e,TB)},onGrown:function(e){Ti(e,TB)},onStartGrow:function(e){Ni(e,BB,{width:rn(e.element,"width").getOr("")})},onStartShrink:function(e){Ni(e,BB,{width:yn(e.element)+"px"})}}),cm.config({}),$f.config({find:function(e){var t=cm.contents(e);return ae(t)}})])}],behaviours:Os([b_(0),um("sidebar-sliding-events",[Ri(BB,(function(e,t){Kt(e.element,"width",t.event.width)})),Ri(TB,(function(e,t){ln(e.element,"width")}))])])}}},name:"sidebar",schema:[Gr("dom")]}),_T=lV.optional({factory:{sketch:function(e){return{uid:e.uid,dom:{tag:"div",attributes:{"aria-hidden":"true"},classes:["tox-throbber"],styles:{display:"none"}},behaviours:Os([cm.config({}),PB.config({focus:!1}),$f.config({find:function(e){return ae(e.components())}})]),components:[]}}},name:"throbber",schema:[Gr("dom")]}),CT=Pf({name:"OuterContainer",factory:function(e,t,n){var r={getSocket:function(t){return aV.getPart(t,e,"socket")},setSidebar:function(t,n){aV.getPart(t,e,"sidebar").each((function(e){return function(e,t){$f.getCurrent(e).each((function(e){return cm.set(e,[SB(t)])}))}(e,n)}))},toggleSidebar:function(t,n){aV.getPart(t,e,"sidebar").each((function(e){return function(e,t){$f.getCurrent(e).each((function(e){$f.getCurrent(e).each((function(n){vB.hasGrown(e)?xB.isShowing(n,t)?vB.shrink(e):(xB.hideAllSlots(n),xB.showSlot(n,t)):(xB.hideAllSlots(n),xB.showSlot(n,t),vB.grow(e))}))}))}(e,n)}))},whichSidebar:function(t){return aV.getPart(t,e,"sidebar").bind(VB).getOrNull()},getHeader:function(t){return aV.getPart(t,e,"header")},getToolbar:function(t){return aV.getPart(t,e,"toolbar")},setToolbar:function(t,n){aV.getPart(t,e,"toolbar").each((function(e){e.getApis().setGroups(e,n)}))},setToolbars:function(t,n){aV.getPart(t,e,"multiple-toolbar").each((function(e){fV.setItems(e,n)}))},refreshToolbar:function(t){aV.getPart(t,e,"toolbar").each((function(e){return e.getApis().refresh(e)}))},toggleToolbarDrawer:function(t){aV.getPart(t,e,"toolbar").each((function(e){var t,n;t=e.getApis().toggle,n=function(t){return t(e)},null!=t?Q.some(n(t)):Q.none()}))},isToolbarDrawerToggled:function(t){return aV.getPart(t,e,"toolbar").bind((function(e){return Q.from(e.getApis().isOpen).map((function(t){return t(e)}))})).getOr(!1)},getThrobber:function(t){return aV.getPart(t,e,"throbber")},focusToolbar:function(t){aV.getPart(t,e,"toolbar").orThunk((function(){return aV.getPart(t,e,"multiple-toolbar")})).each((function(e){rm.focusIn(e)}))},setMenubar:function(t,n){aV.getPart(t,e,"menubar").each((function(e){tB.setMenus(e,n)}))},focusMenubar:function(t){aV.getPart(t,e,"menubar").each((function(e){tB.focus(e)}))}};return{uid:e.uid,dom:e.dom,components:t,apis:r,behaviours:e.behaviours}},configFields:[Gr("dom"),Gr("behaviours")],partFields:[OT,AT,bT,yT,wT,xT,_T],apis:{getSocket:function(e,t){return e.getSocket(t)},setSidebar:function(e,t,n){e.setSidebar(t,n)},toggleSidebar:function(e,t,n){e.toggleSidebar(t,n)},whichSidebar:function(e,t){return e.whichSidebar(t)},getHeader:function(e,t){return e.getHeader(t)},getToolbar:function(e,t){return e.getToolbar(t)},setToolbar:function(e,t,n){var r=U(n,(function(e){return fT(e)}));e.setToolbar(t,r)},setToolbars:function(e,t,n){var r=U(n,(function(e){return U(e,fT)}));e.setToolbars(t,r)},refreshToolbar:function(e,t){return e.refreshToolbar(t)},toggleToolbarDrawer:function(e,t){e.toggleToolbarDrawer(t)},isToolbarDrawerToggled:function(e,t){return e.isToolbarDrawerToggled(t)},getThrobber:function(e,t){return e.getThrobber(t)},setMenubar:function(e,t,n){e.setMenubar(t,n)},focusMenubar:function(e,t){e.focusMenubar(t)},focusToolbar:function(e,t){e.focusToolbar(t)}}}),kT={file:{title:"File",items:"newdocument restoredraft | preview | export print | deleteallconversations"},edit:{title:"Edit",items:"undo redo | cut copy paste pastetext | selectall | searchreplace"},view:{title:"View",items:"code | visualaid visualchars visualblocks | spellchecker | preview fullscreen | showcomments"},insert:{title:"Insert",items:"image link media addcomment pageembed template codesample inserttable | charmap emoticons hr | pagebreak nonbreaking anchor toc | insertdatetime"},format:{title:"Format",items:"bold italic underline strikethrough superscript subscript codeformat | formats blockformats fontformats fontsizes align lineheight | forecolor backcolor | language | removeformat"},tools:{title:"Tools",items:"spellchecker spellcheckerlanguage | a11ycheck code wordcount"},table:{title:"Table",items:"inserttable | cell row column | advtablesort | tableprops deletetable"},help:{title:"Help",items:"help"}},ST=function(e){return"string"==typeof e?e.split(" "):e},VT=function(e,t){var n=k(k({},kT),t.menus),r=ue(t.menus).length>0,o=void 0===t.menubar||!0===t.menubar?ST("file edit view insert format tools table help"):ST(!1===t.menubar?"":t.menubar),i=j(o,(function(e){var n=be(kT,e);return r?n||ye(t.menus,e).exists((function(e){return be(e,"items")})):n})),a=U(i,(function(r){var o=n[r];return function(e,t,n){var r=function(e){return e.getParam("removed_menuitems","")}(n).split(/[ ,]/);return{text:e.title,getItems:function(){return K(e.items,(function(e){var n=e.toLowerCase();return 0===n.trim().length||I(r,(function(e){return e===n}))?[]:"separator"===n||"|"===n?[{type:"separator"}]:t.menuItems[n]?[t.menuItems[n]]:[]}))}}}({title:o.title,items:ST(o.items)},t,e)}));return j(a,(function(e){return e.getItems().length>0&&I(e.getItems(),(function(e){return"separator"!==e.type}))}))},BT=function(e){var t=function(){e._skinLoaded=!0,function(e){e.fire("SkinLoaded")}(e)};return function(){e.initialized?t():e.on("init",t)}},TT=function(e,t,n){return new jg((function(r,o){n.load(t,r,o),e.on("remove",(function(){return n.unload(t)}))}))},NT=function(e,t){return TT(e,t+"/skin.min.css",e.ui.styleSheetLoader)},ET=function(e,t){var n;return(n=Qe.fromDom(e.getElement()),$t(n).isSome())?TT(e,t+"/skin.shadowdom.min.css",vA.DOM.styleSheetLoader):jg.resolve()},PT=function(e,t){var n=function(e){var t=e.getParam("skin"),n=e.getParam("skin_url");if(!1!==t){var r=t||"oxide";n=n?e.documentBaseURI.toAbsolute(n):AA.baseURL+"/skins/ui/"+r}return n}(t);n&&t.contentCSS.push(n+(e?"/content.inline":"/content")+".min.css"),!1===function(e){return!1===e.getParam("skin")}(t)&&o(n)?jg.all([NT(t,n),ET(t,n)]).then(BT(t),function(e,t){return function(){return function(e,t){return e.fire("SkinLoadError",t)}(e,{message:t})}}(t,"Skin could not be loaded")):BT(t)()},QT=b(PT,!1),MT=b(PT,!0),DT=function(e,t){return function(n){var r=Js(),o=function(){n.setActive(e.formatter.match(t));var o=e.formatter.formatChanged(t,n.setActive);r.set(o)};return e.initialized?o():e.once("init",o),function(){e.off("init",o),r.clear()}}},$T=function(e,t,n){return function(r){var o=function(){return n(r)},i=function(){n(r),e.on(t,o)};return e.initialized?i():e.once("init",i),function(){e.off("init",i),e.off(t,o)}}},zT=function(e){return function(t){return function(){e.undoManager.transact((function(){e.focus(),e.execCommand("mceToggleFormat",!1,t.format)}))}}},RT=function(e,t){return function(){return e.execCommand(t)}},IT=function(e,t,n){var r=function(e,r,i,a){var l=t.shared.providers.translate(e.title);if("separator"===e.type)return Q.some({type:"separator",text:l});if("submenu"===e.type){var s=K(e.getStyleItems(),(function(e){return o(e,r,a)}));return 0===r&&s.length<=0?Q.none():Q.some({type:"nestedmenuitem",text:l,disabled:s.length<=0,getSubmenuItems:function(){return K(e.getStyleItems(),(function(e){return o(e,r,a)}))}})}return Q.some(k({type:"togglemenuitem",text:l,icon:e.icon,active:e.isSelected(a),disabled:i,onAction:n.onAction(e)},e.getStylePreview().fold((function(){return{}}),(function(e){return{meta:{style:e}}}))))},o=function(e,t,o){var i="formatter"===e.type&&n.isInvalid(e);return 0===t?i?[]:r(e,t,!1,o).toArray():r(e,t,i,o).toArray()},i=function(e){var t=n.getCurrentValue(),r=n.shouldHide?0:1;return K(e,(function(e){return o(e,r,t)}))};return{validateItems:i,getFetch:function(e,t){return function(n,r){var o=t(),a=i(o);r(UC(a,Av.CLOSE_ON_EXECUTE,e,!1))}}}},LT=function(e,t,n){var r=n.dataset,o="basic"===r.type?function(){return U(r.data,(function(e){return BS(e,n.isSelectedFor,n.getPreviewFor)}))}:r.getData;return{items:IT(0,t,n),getStyleItems:o}},FT=function(e,t,n){var r=LT(0,t,n),o=r.items,i=r.getStyleItems,a=$T(e,"NodeChange",(function(e){var t=e.getComponent();n.updateText(t)}));return $C({text:n.icon.isSome()?Q.none():n.text,icon:n.icon,tooltip:Q.from(n.tooltip),role:Q.none(),fetch:o.getFetch(t,i),onSetup:a,getApi:function(e){return{getComponent:v(e)}},columns:1,presets:"normal",classes:n.icon.isSome()?[]:["bespoke"],dropdownBehaviours:[]},"tox-tbtn",t.shared)};!function(e){e[e.SemiColon=0]="SemiColon",e[e.Space=1]="Space"}(kk||(kk={}));var UT,HT,WT,jT,qT,XT=function(e,t,n,r){var o=function(e){return U(e,(function(e){var t=e,n=e,r=e.split("=");return r.length>1&&(t=r[0],n=r[1]),{title:t,format:n}}))}(function(e,t){return t===kk.SemiColon?e.replace(/;$/,"").split(";"):e.split(" ")}(e.getParam(t,n,"string"),r));return{type:"basic",data:o}},YT=[{title:"Left",icon:"align-left",format:"alignleft",command:"JustifyLeft"},{title:"Center",icon:"align-center",format:"aligncenter",command:"JustifyCenter"},{title:"Right",icon:"align-right",format:"alignright",command:"JustifyRight"},{title:"Justify",icon:"align-justify",format:"alignjustify",command:"JustifyFull"}],GT=function(e){var t={type:"basic",data:YT};return{tooltip:"Align",text:Q.none(),icon:Q.some("align-left"),isSelectedFor:function(t){return function(){return e.formatter.match(t)}},getCurrentValue:Q.none,getPreviewFor:function(e){return Q.none},onAction:function(t){return function(){return Y(YT,(function(e){return e.format===t.format})).each((function(t){return e.execCommand(t.command)}))}},updateText:function(t){var n=Y(YT,(function(t){return e.formatter.match(t.format)})),r=n.fold(v("left"),(function(e){return e.title.toLowerCase()}));Ni(t,DC,{icon:"align-"+r})},dataset:t,shouldHide:!1,isInvalid:function(t){return!e.formatter.canApply(t.format)}}},ZT=["-apple-system","Segoe UI","Roboto","Helvetica Neue","sans-serif"],KT=function(e){var t=e.split(/\s*,\s*/);return U(t,(function(e){return e.replace(/^['"]+|['"]+$/g,"")}))},JT=function(e){var t="System Font",n=function(){var n=function(e){return e?KT(e)[0]:""},o=e.queryCommandValue("FontName"),i=r.data,a=o?o.toLowerCase():"",l=Y(i,(function(e){var t=e.format;return t.toLowerCase()===a||n(t).toLowerCase()===n(a).toLowerCase()})).orThunk((function(){return Ce(function(e){var t;return 0===e.indexOf("-apple-system")&&(t=KT(e.toLowerCase()),J(ZT,(function(e){return t.indexOf(e.toLowerCase())>-1})))}(a),{title:t,format:a})}));return{matchOpt:l,font:o}},r=XT(e,"font_formats","Andale Mono=andale mono,monospace;Arial=arial,helvetica,sans-serif;Arial Black=arial black,sans-serif;Book Antiqua=book antiqua,palatino,serif;Comic Sans MS=comic sans ms,sans-serif;Courier New=courier new,courier,monospace;Georgia=georgia,palatino,serif;Helvetica=helvetica,arial,sans-serif;Impact=impact,sans-serif;Symbol=symbol;Tahoma=tahoma,arial,helvetica,sans-serif;Terminal=terminal,monaco,monospace;Times New Roman=times new roman,times,serif;Trebuchet MS=trebuchet ms,geneva,sans-serif;Verdana=verdana,geneva,sans-serif;Webdings=webdings;Wingdings=wingdings,zapf dingbats",kk.SemiColon);return{tooltip:"Fonts",text:Q.some(t),icon:Q.none(),isSelectedFor:function(e){return function(t){return t.exists((function(t){return t.format===e}))}},getCurrentValue:function(){return n().matchOpt},getPreviewFor:function(e){return function(){return Q.some({tag:"div",styles:-1===e.indexOf("dings")?{"font-family":e}:{}})}},onAction:function(t){return function(){e.undoManager.transact((function(){e.focus(),e.execCommand("FontName",!1,t.format)}))}},updateText:function(e){var t=n(),r=t.matchOpt,o=t.font,i=r.fold(v(o),(function(e){return e.title}));Ni(e,MC,{text:i})},dataset:r,shouldHide:!1,isInvalid:x}},eN={"8pt":"1","10pt":"2","12pt":"3","14pt":"4","18pt":"5","24pt":"6","36pt":"7"},tN={"xx-small":"7pt","x-small":"8pt",small:"10pt",medium:"12pt",large:"14pt","x-large":"18pt","xx-large":"24pt"},nN=function(e,t){return/[0-9.]+px$/.test(e)?function(e,t){var n=Math.pow(10,t);return Math.round(e*n)/n}(72*parseInt(e,10)/96,t||0)+"pt":ye(tN,e).getOr(e)},rN=function(e){var t=function(){var t=Q.none(),n=r.data,o=e.queryCommandValue("FontSize");if(o)for(var i=function(e){var r=nN(o,e),i=function(e){return ye(eN,e).getOr("")}(r);t=Y(n,(function(e){return e.format===o||e.format===r||e.format===i}))},a=3;t.isNone()&&a>=0;a--)i(a);return{matchOpt:t,size:o}},n=v(Q.none),r=XT(e,"fontsize_formats","8pt 10pt 12pt 14pt 18pt 24pt 36pt",kk.Space);return{tooltip:"Font sizes",text:Q.some("12pt"),icon:Q.none(),isSelectedFor:function(e){return function(t){return t.exists((function(t){return t.format===e}))}},getPreviewFor:n,getCurrentValue:function(){return t().matchOpt},onAction:function(t){return function(){e.undoManager.transact((function(){e.focus(),e.execCommand("FontSize",!1,t.format)}))}},updateText:function(e){var n=t(),r=n.matchOpt,o=n.size,i=r.fold(v(o),(function(e){return e.title}));Ni(e,MC,{text:i})},dataset:r,shouldHide:!1,isInvalid:x}},oN=function(e,t){var n=t(),r=U(n,(function(e){return e.format}));return Q.from(e.formatter.closest(r)).bind((function(e){return Y(n,(function(t){return t.format===e}))})).orThunk((function(){return Ce(e.formatter.match("p"),{title:"Paragraph",format:"p"})}))},iN=function(e){var t="Paragraph",n=XT(e,"block_formats","Paragraph=p;Heading 1=h1;Heading 2=h2;Heading 3=h3;Heading 4=h4;Heading 5=h5;Heading 6=h6;Preformatted=pre",kk.SemiColon);return{tooltip:"Blocks",text:Q.some(t),icon:Q.none(),isSelectedFor:function(t){return function(){return e.formatter.match(t)}},getCurrentValue:Q.none,getPreviewFor:function(t){return function(){var n=e.formatter.get(t);return Q.some({tag:n.length>0&&(n[0].inline||n[0].block)||"div",styles:e.dom.parseStyle(e.formatter.getCssText(t))})}},onAction:zT(e),updateText:function(r){var o=oN(e,(function(){return n.data})).fold(v(t),(function(e){return e.title}));Ni(r,MC,{text:o})},dataset:n,shouldHide:!1,isInvalid:function(t){return!e.formatter.canApply(t.format)}}},aN=function(e,t){var n="Paragraph";return{tooltip:"Formats",text:Q.some(n),icon:Q.none(),isSelectedFor:function(t){return function(){return e.formatter.match(t)}},getCurrentValue:Q.none,getPreviewFor:function(t){return function(){var n=e.formatter.get(t);return void 0!==n?Q.some({tag:n.length>0&&(n[0].inline||n[0].block)||"div",styles:e.dom.parseStyle(e.formatter.getCssText(t))}):Q.none()}},onAction:zT(e),updateText:function(t){var r=function(e){var t=e.items;return void 0!==t&&t.length>0?K(t,r):[{title:e.title,format:e.format}]},o=K(VS(e),r),i=oN(e,v(o)).fold(v(n),(function(e){return e.title}));Ni(t,MC,{text:i})},shouldHide:e.getParam("style_formats_autohide",!1,"boolean"),isInvalid:function(t){return!e.formatter.canApply(t.format)},dataset:t}},lN=Object.freeze({__proto__:null,events:function(e,t){var n=function(n,r){e.updateState.each((function(e){var o=e(n,r);t.set(o)})),e.renderComponents.each((function(e){var o=e(r,t.get()),i=U(o,n.getSystem().build);Fu(n,i)}))};return Di([Ri(si(),(function(t,r){var o=r;if(!o.universal){var i=e.channel;R(o.channels,i)&&n(t,o.data)}})),qi((function(t,r){e.initialData.each((function(e){n(t,e)}))}))])}}),sN=Object.freeze({__proto__:null,getState:function(e,t,n){return n}}),cN=[Gr("channel"),io("renderComponents"),io("updateState"),io("initialData")],uN=Object.freeze({__proto__:null,init:function(){var e=wo(Q.none());return{readState:function(){return e.get().getOr("none")},get:e.get,set:e.set,clear:function(){return e.set(Q.none())}}}}),dN=xs({fields:cN,name:"reflecting",active:lN,apis:sN,state:uN}),fN=v([Gr("toggleClass"),Gr("fetch"),Tl("onExecute"),ho("getHotspot",Q.some),ho("getAnchorOverrides",v({})),kc(),Tl("onItemExecute"),io("lazySink"),Gr("dom"),Vl("onOpen"),Vd("splitDropdownBehaviours",[jO,rm,mm]),ho("matchWidth",!1),ho("useMinWidth",!1),ho("eventOrder",{}),io("role")].concat(lw())),hN=rf({factory:yg,schema:[Gr("dom")],name:"arrow",defaults:function(){return{buttonBehaviours:Os([mm.revoke()])}},overrides:function(e){return{dom:{tag:"span",attributes:{role:"presentation"}},action:function(t){t.getSystem().getByUid(e.uid).each(Ei)},buttonBehaviours:Os([Sm.config({toggleOnExecute:!1,toggleClass:e.toggleClass})])}}}),pN=rf({factory:yg,schema:[Gr("dom")],name:"button",defaults:function(){return{buttonBehaviours:Os([mm.revoke()])}},overrides:function(e){return{dom:{tag:"span",attributes:{role:"presentation"}},action:function(t){t.getSystem().getByUid(e.uid).each((function(n){e.onExecute(n,t)}))}}}}),mN=v([hN,pN,af({factory:{sketch:function(e){return{uid:e.uid,dom:{tag:"span",styles:{display:"none"},attributes:{"aria-hidden":"true"},innerHtml:e.text}}}},schema:[Gr("text")],name:"aria-descriptor"}),of({schema:[Cl()],name:"menu",defaults:function(e){return{onExecute:function(t,n){t.getSystem().getByUid(e.uid).each((function(r){e.onItemExecute(r,t,n)}))}}}}),XO()]),gN=Pf({name:"SplitDropdown",configFields:fN(),partFields:mN(),factory:function(e,t,n,r){var o,i=function(e){$f.getCurrent(e).each((function(e){sh.highlightFirst(e),rm.focusIn(e)}))},a=function(t){tw(e,A,t,r,i,CO.HighlightFirst).get(m)},l=function(t){var n=yf(t,e,"button");return Ei(n),Q.some(!0)},s=k(k({},Di([qi((function(t,n){Af(t,e,"aria-descriptor").each((function(e){var n=ia("aria");Ht(e.element,"id",n),Ht(t.element,"aria-describedby",n)}))}))])),Bm(Q.some(a))),c={repositionMenus:function(e){Sm.isOn(e)&&aw(e)}};return{uid:e.uid,dom:e.dom,components:t,apis:c,eventOrder:k(k({},e.eventOrder),(o={},o[ci()]=["disabling","toggling","alloy.base.behaviour"],o)),events:s,behaviours:Td(e.splitDropdownBehaviours,[jO.config({others:{sandbox:function(t){var n=yf(t,e,"arrow");return iw(e,t,{onOpen:function(){Sm.on(n),Sm.on(t)},onClose:function(){Sm.off(n),Sm.off(t)}})}}}),rm.config({mode:"special",onSpace:l,onEnter:l,onDown:function(e){return a(e),Q.some(!0)}}),mm.config({}),Sm.config({toggleOnExecute:!1,aria:{mode:"expanded"}})]),domModification:{attributes:{role:e.role.getOr("button"),"aria-haspopup":!0}}}},apis:{repositionMenus:function(e,t){return e.repositionMenus(t)}}}),vN=function(e){return{isDisabled:function(){return Zf.isDisabled(e)},setDisabled:function(t){return Zf.set(e,t)}}},AN=function(e){return{setActive:function(t){Sm.set(e,t)},isActive:function(){return Sm.isOn(e)},isDisabled:function(){return Zf.isDisabled(e)},setDisabled:function(t){return Zf.set(e,t)}}},yN=function(e,t){return e.map((function(e){return{"aria-label":t.translate(e),title:t.translate(e)}})).getOr({})},bN=ia("focus-button"),ON=function(e,t,n,r,o,i){var a;return{dom:{tag:"button",classes:["tox-tbtn"].concat(t.isSome()?["tox-tbtn--select"]:[]),attributes:yN(n,i)},components:oy([e.map((function(e){return TC(e,i.icons)})),t.map((function(e){return EC(e,"tox-tbtn",i)}))]),eventOrder:(a={},a[Lo()]=["focusing","alloy.base.behaviour","common-button-display-events"],a),buttonBehaviours:Os([KA(i.isDisabled),XA(),um("common-button-display-events",[Ri(Lo(),(function(e,t){t.event.prevent(),Ti(e,bN)}))])].concat(r.map((function(n){return dN.config({channel:n,initialData:{icon:e,text:t},renderComponents:function(e,t){return oy([e.icon.map((function(e){return TC(e,i.icons)})),e.text.map((function(e){return EC(e,"tox-tbtn",i)}))])}})})).toArray()).concat(o.getOr([])))}},wN=function(e,t,n){var r,o=wo(m),i=ON(e.icon,e.text,e.tooltip,Q.none(),Q.none(),n);return yg.sketch({dom:i.dom,components:i.components,eventOrder:QC,buttonBehaviours:Os([um("toolbar-button-events",[(r={onAction:e.onAction,getApi:t.getApi},Gi((function(e,t){JA(r,e)((function(t){Ni(e,PC,{buttonApi:t}),r.onAction(t)}))}))),ey(t,o),ty(t,o)]),KA((function(){return e.disabled||n.isDisabled()})),XA()].concat(t.toolbarButtonBehaviours))})},xN=function(e,t,n){return wN(e,{toolbarButtonBehaviours:[].concat(n.length>0?[um("toolbarButtonWith",n)]:[]),getApi:vN,onSetup:e.onSetup},t)},_N=function(e,t,n){return sr(wN(e,{toolbarButtonBehaviours:[cm.config({}),Sm.config({toggleClass:"tox-tbtn--enabled",aria:{mode:"pressed"},toggleOnExecute:!1})].concat(n.length>0?[um("toolbarToggleButtonWith",n)]:[]),getApi:AN,onSetup:e.onSetup},t))},CN=function(e,t,n){return function(r){return NO((function(e){return t.fetch(e)})).map((function(o){return Q.from(Pb(sr(hb(ia("menu-value"),o,(function(n){t.onItemAction(e(r),n)}),t.columns,t.presets,Av.CLOSE_ON_EXECUTE,t.select.getOr(x),n),{movement:mb(t.columns,t.presets),menuBehaviours:sA("auto"!==t.columns?[]:[qi((function(e,n){aA(e,4,Tv(t.presets)).each((function(t){var n=t.numRows,r=t.numColumns;rm.setGridSize(e,n,r)}))}))])})))}))}},kN=[{name:"history",items:["undo","redo"]},{name:"styles",items:["styleselect"]},{name:"formatting",items:["bold","italic"]},{name:"alignment",items:["alignleft","aligncenter","alignright","alignjustify"]},{name:"indentation",items:["outdent","indent"]},{name:"permanent pen",items:["permanentpen"]},{name:"comments",items:["addcomment"]}],SN=function(e,t){return function(n,r,o){var i=e(n).mapError((function(e){return Wr(e)})).getOrDie();return t(i,r,o)}},VN={button:SN(ov,(function(e,t){return n=e,r=t.backstage.shared.providers,xN(n,r,[]);var n,r})),togglebutton:SN(lv,(function(e,t){return n=e,r=t.backstage.shared.providers,_N(n,r,[]);var n,r})),menubutton:SN(JV,(function(e,t){return WC(e,"tox-tbtn",t.backstage,Q.none())})),splitbutton:SN((function(e){return Fr("SplitButton",eB,e)}),(function(e,t){return function(e,t){var n,r=ia("channel-update-split-dropdown-display"),o=function(e){return{isDisabled:function(){return Zf.isDisabled(e)},setDisabled:function(t){return Zf.set(e,t)},setIconFill:function(t,n){ul(e.element,'svg path[id="'+t+'"], rect[id="'+t+'"]').each((function(e){Ht(e,"fill",n)}))},setIconStroke:function(t,n){ul(e.element,'svg path[id="'+t+'"], rect[id="'+t+'"]').each((function(e){Ht(e,"stroke",n)}))},setActive:function(t){Ht(e.element,"aria-pressed",t),ul(e.element,"span").each((function(n){e.getSystem().getByDom(n).each((function(e){return Sm.set(e,t)}))}))},isActive:function(){return ul(e.element,"span").exists((function(t){return e.getSystem().getByDom(t).exists(Sm.isOn)}))}}},i=wo(m),a={getApi:o,onSetup:e.onSetup};return gN.sketch({dom:{tag:"div",classes:["tox-split-button"],attributes:k({"aria-pressed":!1},yN(e.tooltip,t.providers))},onExecute:function(t){e.onAction(o(t))},onItemExecute:function(e,t,n){},splitDropdownBehaviours:Os([ZA(t.providers.isDisabled),XA(),um("split-dropdown-events",[Ri(bN,mm.focus),ey(a,i),ty(a,i)]),fw.config({})]),eventOrder:(n={},n[bi()]=["alloy.base.behaviour","split-dropdown-events"],n),toggleClass:"tox-tbtn--enabled",lazySink:t.getSink,fetch:CN(o,e,t.providers),parts:{menu:Dv(0,e.columns,e.presets)},components:[gN.parts.button(ON(e.icon,e.text,Q.none(),Q.some(r),Q.some([Sm.config({toggleClass:"tox-tbtn--enabled",toggleOnExecute:!1})]),t.providers)),gN.parts.arrow({dom:{tag:"button",classes:["tox-tbtn","tox-split-button__chevron"],innerHtml:Sg("chevron-down",t.providers.icons)},buttonBehaviours:Os([ZA(t.providers.isDisabled),XA(),Vg()])}),gN.parts["aria-descriptor"]({text:t.providers.translate("To open the popup, press Shift+Enter")})]})}(e,t.backstage.shared)})),grouptoolbarbutton:SN((function(e){return Fr("GroupToolbarButton",GV,e)}),(function(e,t,n){var r,o=n.ui.registry.getAll().buttons,i=((r={})[_c]=t.backstage.shared.header.isPositionedAtTop()?Us.TopToBottom:Us.BottomToTop,r);if(TA(n)===vv.floating)return function(e,t,n,r){var o=t.shared;return JB.sketch({lazySink:o.getSink,fetch:function(){return NO((function(t){t(U(n(e.items),fT))}))},markers:{toggledClass:"tox-tbtn--enabled"},parts:{button:ON(e.icon,e.text,e.tooltip,Q.none(),Q.none(),o.providers),toolbar:{dom:{tag:"div",classes:["tox-toolbar__overflow"],attributes:r}}}})}(e,t.backstage,(function(e){return EN(n,{buttons:o,toolbar:e,allowToolbarGroups:!1},t,Q.none())}),i);throw new Error("Toolbar groups are only supported when using floating toolbar mode")})),styleSelectButton:function(e,t){return function(e,t){var n=k({type:"advanced"},t.styleselect);return FT(e,t,aN(e,n))}(e,t.backstage)},fontsizeSelectButton:function(e,t){return function(e,t){return FT(e,t,rN(e))}(e,t.backstage)},fontSelectButton:function(e,t){return function(e,t){return FT(e,t,JT(e))}(e,t.backstage)},formatButton:function(e,t){return function(e,t){return FT(e,t,iN(e))}(e,t.backstage)},alignMenuButton:function(e,t){return function(e,t){return FT(e,t,GT(e))}(e,t.backstage)}},BN={styleselect:VN.styleSelectButton,fontsizeselect:VN.fontsizeSelectButton,fontselect:VN.fontSelectButton,formatselect:VN.formatButton,align:VN.alignMenuButton},TN=function(e){var t,n=e.toolbar,r=e.buttons;return!1===n?[]:void 0===n||!0===n?function(e){var t=U(kN,(function(t){var n=j(t.items,(function(t){return be(e,t)||be(BN,t)}));return{name:t.name,items:n}}));return j(t,(function(e){return e.items.length>0}))}(r):o(n)?(t=n.split("|"),U(t,(function(e){return{items:e.trim().split(" ")}}))):function(e){return p(e,(function(e){return be(e,"name")&&be(e,"items")}))}(n)?n:[]},NN=function(e,t,n,r,o,i){return ye(t,n.toLowerCase()).orThunk((function(){return i.bind((function(e){return ce(e,(function(e){return ye(t,e+n.toLowerCase())}))}))})).fold((function(){return ye(BN,n.toLowerCase()).map((function(t){return t(e,o)})).orThunk((function(){return Q.none()}))}),(function(t){return"grouptoolbarbutton"!==t.type||r?function(e,t,n){return ye(VN,e.type).fold((function(){return Q.none()}),(function(r){return Q.some(r(e,t,n))}))}(t,o,e):Q.none()}))},EN=function(e,t,n,r){var o=TN(t),i=U(o,(function(o){var i=K(o.items,(function(o){return 0===o.trim().length?[]:NN(e,t.buttons,o,t.allowToolbarGroups,n,r).toArray()}));return{title:Q.from(e.translate(o.name)),items:i}}));return j(i,(function(e){return e.items.length>0}))},PN=function(e,t,n,r){var i=t.outerContainer,a=n.toolbar,l=n.buttons;if(p(a,o)){var s=a.map((function(t){var o={toolbar:t,buttons:l,allowToolbarGroups:n.allowToolbarGroups};return EN(e,o,{backstage:r},Q.none())}));CT.setToolbars(i,s)}else CT.setToolbar(i,EN(e,n,{backstage:r},Q.none()))},QN=gt(),MN=QN.os.isiOS()&&QN.os.version.major<=12,DN=Object.freeze({__proto__:null,render:function(e,t,n,r,o){var i=wo(0),a=t.outerContainer;QT(e);var s=Qe.fromDom(o.targetNode),c=Dt(Mt(s));!function(e,t){Yu(e,t,Cn)}(s,t.mothership),Xu(c,t.uiMothership),e.on("PostRender",(function(){PN(e,t,n,r),i.set(e.getWin().innerWidth),CT.setMenubar(a,VT(e,n)),CT.setSidebar(a,n.sidebar),function(e,t){var n=e.dom,r=e.getWin(),o=e.getDoc().documentElement,i=wo(pn(r.innerWidth,r.innerHeight)),a=wo(pn(o.offsetWidth,o.offsetHeight)),l=function(){var t=i.get();t.left===r.innerWidth&&t.top===r.innerHeight||(i.set(pn(r.innerWidth,r.innerHeight)),Uy(e))},s=function(){var t=e.getDoc().documentElement,n=a.get();n.left===t.offsetWidth&&n.top===t.offsetHeight||(a.set(pn(t.offsetWidth,t.offsetHeight)),Uy(e))},c=function(t){return function(e,t){return e.fire("ScrollContent",t)}(e,t)};n.bind(r,"resize",l),n.bind(r,"scroll",c);var u=rc(Qe.fromDom(e.getBody()),"load",s),d=t.uiMothership.element;e.on("hide",(function(){Kt(d,"display","none")})),e.on("show",(function(){ln(d,"display")})),e.on("NodeChange",s),e.on("remove",(function(){u.unbind(),n.unbind(r,"resize",l),n.unbind(r,"scroll",c),r=null}))}(e,t)}));var u,d,f,h=CT.getSocket(a).getOrDie("Could not find expected socket element");if(MN){Jt(h.element,{overflow:"scroll","-webkit-overflow-scrolling":"touch"});var p=(u=function(){e.fire("ScrollContent")},d=20,f=null,{cancel:function(){l(f)||(clearTimeout(f),f=null)},throttle:function(){for(var e=[],t=0;tt}));return r.or(o).getOr(e)},IN=function(e){var t=function(e){var t=yA(e),n=wA(e),r=_A(e);return $N(t).map((function(e){return RN(e,n,r)}))}(e);return t.getOr(yA(e))},LN=function(e){var t=bA(e),n=OA(e),r=xA(e);return $N(t).map((function(e){return RN(e,n,r)}))},FN=function(e,t,n,r,o){var i=n.uiMothership,a=n.outerContainer,l=vA.DOM,s=DA(e),c=RA(e),u=xA(e).or(LN(e)),d=r.shared.header,f=d.isPositionedAtTop,h=TA(e),p=h===vv.sliding||h===vv.floating,m=wo(!1),g=function(){return m.get()&&!e.removed},A=function(e){return p?e.fold(v(0),(function(e){return e.components().length>1?dn(e.components()[1].element):0})):0},y=function(){i.broadcastOn([cd()],{})},b=function(e){if(void 0===e&&(e=!1),g()){var n;if(s||(n=u.getOrThunk((function(){var e=$N(tn(Lt(),"margin-left")).getOr(0);return yn(Lt())-gn(t).left+e})),Kt(o.get().element,"max-width",n+"px")),p&&CT.refreshToolbar(a),s||function(){var e=CT.getToolbar(a),n=A(e),r=In(t),i=f()?Math.max(r.y-dn(o.get().element)+n,0):r.bottom;Jt(a.element,{position:"absolute",top:Math.round(i)+"px",left:Math.round(r.x)+"px"})}(),c){var r=o.get();e?RV.reset(r):RV.refresh(r)}y()}},O=function(n){if(void 0===n&&(n=!0),!s&&c&&g()){var r=d.getDockingMode(),i=function(n){switch(PA(e)){case BA.auto:var r=CT.getToolbar(a),o=A(r),i=dn(n.element)-o,l=In(t);if(l.y>i)return"top";var s=_t(t),c=Math.max(s.dom.scrollHeight,dn(s));return l.bottom=n&&e.bottom-t.y>=n},ZN=function(e){var t=function(e){var t=e.getBoundingClientRect();if(t.height<=0&&t.width<=0){var n=Nt(Qe.fromDom(e.startContainer),e.startOffset).element;return(Re(n)?kt(n):Q.some(n)).filter(ze).map((function(e){return e.dom.getBoundingClientRect()})).getOr(t)}return t}(e.selection.getRng());if(e.inline){var n=En();return Rn(n.left+t.left,n.top+t.top,t.width,t.height)}var r=Ln(Qe.fromDom(e.getBody()));return Rn(r.x+t.left,r.y+t.top,t.width,t.height)},KN=function(e,t,n,r){void 0===r&&(r=0);var o=Mn(window),i=In(Qe.fromDom(e.getContentAreaContainer())),a=CA(e)||kA(e)||VA(e),l=function(e,t,n){var r=Math.max(e.x+n,t.x);return{x:r,width:Math.min(e.right-n,t.right)-r}}(i,o,r),s=l.x,c=l.width;if(e.inline&&!a)return Rn(s,o.y,c,o.height);var u=function(e,t,n,r,o,i){var a=Qe.fromDom(e.getContainer()),l=ul(a,".tox-editor-header").getOr(a),s=In(l),c=s.y>=t.bottom,u=r&&!c;if(e.inline&&u)return{y:Math.max(s.bottom+i,n.y),bottom:n.bottom};if(e.inline&&!u)return{y:n.y,bottom:Math.min(s.y-i,n.bottom)};var d="line"===o?In(a):t;return u?{y:Math.max(s.bottom+i,n.y),bottom:Math.min(d.bottom-i,n.bottom)}:{y:Math.max(d.y+i,n.y),bottom:Math.min(s.y-i,n.bottom)}}(e,i,o,t.header.isPositionedAtTop(),n,r),d=u.y,f=u.bottom;return Rn(s,d,c,f-d)},JN={valignCentre:[],alignCentre:[],alignLeft:["tox-pop--align-left"],alignRight:["tox-pop--align-right"],right:["tox-pop--right"],left:["tox-pop--left"],bottom:["tox-pop--bottom"],top:["tox-pop--top"],inset:["tox-pop--inset"]},eE={maxHeightFunction:mc(),maxWidthFunction:qB()},tE=function(e){return"node"===e},nE=function(e,t,n,r,o){var i=ZN(e),a=r.lastElement().exists((function(e){return yt(n,e)}));return function(e,t){var n=e.selection.getRng(),r=Nt(Qe.fromDom(n.startContainer),n.startOffset);return n.startContainer===n.endContainer&&n.startOffset===n.endOffset-1&&yt(r.element,t)}(e,n)?a?mg:ug:a?function(e,t,n){var r=rn(e,"position");Kt(e,"position",t);var o=n(e);return r.each((function(t){return Kt(e,"position",t)})),o}(t,r.getMode(),(function(){return GN(i,In(t))&&!r.isReposition()?vg:mg})):("fixed"===r.getMode()?o.y+En().top:o.y)+(dn(t)+12)<=i.y?ug:dg},rE=function(e,t,n,r){var o=function(t){return function(r,o,i,a,l){var s=nE(e,a,t,n,l),c=k(k({},r),{y:l.y,height:l.height});return k(k({},s(c,o,i,a,l)),{alwaysFit:!0})}},i=function(e){return tE(r)?[o(e)]:[]};return t?{onLtr:function(e){return[as,ts,ns,rs,os,is].concat(i(e))},onRtl:function(e){return[as,ns,ts,os,rs,is].concat(i(e))}}:{onLtr:function(e){return[is,as,rs,ts,os,ns].concat(i(e))},onRtl:function(e){return[is,as,os,ns,rs,ts].concat(i(e))}}},oE=function(e,t){var n=j(t,(function(t){return t.predicate(e.dom)})),r=W(n,(function(e){return"contexttoolbar"===e.type}));return{contextToolbars:r.pass,contextForms:r.fail}},iE=function(e,t,n){var r=oE(e,t);if(r.contextForms.length>0)return Q.some({elem:e,toolbars:[r.contextForms[0]]});var o=oE(e,n);if(o.contextForms.length>0)return Q.some({elem:e,toolbars:[o.contextForms[0]]});if(r.contextToolbars.length>0||o.contextToolbars.length>0){var i=function(e){if(e.length<=1)return e;var t=function(t){return I(e,(function(e){return e.position===t}))},n=function(t){return j(e,(function(e){return e.position===t}))},r=t("selection"),o=t("node");if(r||o){if(o&&r){var i=n("node"),a=U(n("selection"),(function(e){return k(k({},e),{position:"node"})}));return i.concat(a)}return n(r?"selection":"node")}return n("line")}(r.contextToolbars.concat(o.contextToolbars));return Q.some({elem:e,toolbars:i})}return Q.none()},aE=function(e,t,n){return e(t)?Q.none():To(t,(function(e){if(ze(e)){var t=oE(e,n.inNodeScope),r=t.contextToolbars,o=t.contextForms,i=o.length>0?o:function(e){if(e.length<=1)return e;var t=function(t){return Y(e,(function(e){return e.position===t}))},n=t("selection").orThunk((function(){return t("node")})).orThunk((function(){return t("line")})).map((function(e){return e.position}));return n.fold((function(){return[]}),(function(t){return j(e,(function(e){return e.position===t}))}))}(r);return i.length>0?Q.some({elem:e,toolbars:i}):Q.none()}return Q.none()}),e)},lE=function(e,t){var n={},r=[],o=[],i={},a={},l=function(e,l){var s=Ur(Fr("ContextForm",pv,l));n[e]=s,s.launch.map((function(n){i["form:"+e]=k(k({},l.launch),{type:"contextformtogglebutton"===n.type?"togglebutton":"button",onAction:function(){t(s)}})})),"editor"===s.scope?o.push(s):r.push(s),a[e]=s},s=function(e,t){var n;(n=t,Fr("ContextToolbar",mv,n)).each((function(n){"editor"===t.scope?o.push(n):r.push(n),a[e]=n}))},c=ue(e);return H(c,(function(t){var n=e[t];"contextform"===n.type?l(t,n):"contexttoolbar"===n.type&&s(t,n)})),{forms:n,inNodeScope:r,inEditorScope:o,lookupTable:a,formNavigators:i}},sE=ia("forward-slide"),cE=ia("backward-slide"),uE=ia("change-slide-event"),dE="tox-pop--resizing",fE="tox-pop--transition",hE=function(e,t,n,r){var o,i,a=r.backstage,l=a.shared,s=gt().deviceType.isTouch,c=ec(),u=ec(),d=ec(),f=tl((o={sink:n,onEscape:function(){return e.focus(),Q.some(!0)}},i=wo([]),Km.sketch({dom:{tag:"div",classes:["tox-pop"]},fireDismissalEventInstead:{event:"doNotDismissYet"},onShow:function(e){i.set([]),Km.getContent(e).each((function(e){ln(e.element,"visibility")})),Ia(e.element,dE),ln(e.element,"width")},inlineBehaviours:Os([um("context-toolbar-events",[ji(ei(),(function(e,t){"width"===t.event.raw.propertyName&&(Ia(e.element,dE),ln(e.element,"width"))})),Ri(uE,(function(e,t){var n=e.element;ln(n,"width");var r=yn(n);Km.setContent(e,t.event.contents),za(n,dE);var o=yn(n);Kt(n,"width",r+"px"),Km.getContent(e).each((function(e){t.event.focus.bind((function(e){return Ts(e),Ps(n)})).orThunk((function(){return rm.focusIn(e),Es(Mt(n))}))})),Ag.setTimeout((function(){Kt(e.element,"width",o+"px")}),0)})),Ri(sE,(function(e,t){Km.getContent(e).each((function(t){i.set(i.get().concat([{bar:t,focus:Es(Mt(e.element))}]))})),Ni(e,uE,{contents:t.event.forwardContents,focus:Q.none()})})),Ri(cE,(function(e,t){le(i.get()).each((function(t){i.set(i.get().slice(0,i.get().length-1)),Ni(e,uE,{contents:nl(t.bar),focus:t.focus})}))}))]),rm.config({mode:"special",onEscape:function(e){return le(i.get()).fold((function(){return o.onEscape()}),(function(t){return Ti(e,cE),Q.some(!0)}))}})]),lazySink:function(){return Wn.value(o.sink)}}))),h=function(){var t=d.get().getOr("node"),n=tE(t)?1:0;return KN(e,l,t,n)},p=function(){return!(e.removed||s()&&a.isContextMenuOpen())},g=function(){if(p()){var t=h(),n=we(d.get(),"node")?function(e,t){return t.filter(It).map(Ln).getOrThunk((function(){return ZN(e)}))}(e,c.get()):ZN(e);return t.height<=0||!GN(n,t)}return!0},v=function(){c.clear(),u.clear(),d.clear(),Km.hide(f)},A=function(){if(Km.isOpen(f)){var e=f.element;ln(e,"display"),g()?Kt(e,"display","none"):(u.set(0),Km.reposition(f))}},y=function(t){return{dom:{tag:"div",classes:["tox-pop__dialog"]},components:[t],behaviours:Os([rm.config({mode:"acyclic"}),um("pop-dialog-wrap-events",[qi((function(t){e.shortcuts.add("ctrl+F9","focus statusbar",(function(){return rm.focusIn(t)}))})),Xi((function(t){e.shortcuts.remove("ctrl+F9")}))])])}},b=Fe((function(){return lE(t,(function(e){var t=O([e]);Ni(f,sE,{forwardContents:y(t)})}))})),O=function(t){var n=e.ui.registry.getAll().buttons,o=b(),i=k(k({},n),o.formNavigators),a=TA(e)===vv.scrolling?vv.scrolling:vv.default,s=Z(U(t,(function(t){return"contexttoolbar"===t.type?function(t,n){return EN(e,{buttons:t,toolbar:n.items,allowToolbarGroups:!1},r,Q.some(["form:"]))}(i,t):function(e,t){return YN(e,t)}(t,l.providers)})));return vT({type:a,uid:ia("context-toolbar"),initGroups:s,onEscape:Q.none,cyclicKeying:!0,providers:l.providers})},w=function(t,r){var o="node"===t?l.anchors.node(r):l.anchors.cursor(),i=function(e,t,n,r){return"line"===t?{bubble:yc(12,0,JN),layouts:{onLtr:function(){return[ls]},onRtl:function(){return[ss]}},overrides:eE}:{bubble:yc(0,12,JN,1/12),layouts:rE(e,n,r,t),overrides:eE}}(e,t,s(),{lastElement:c.get,isReposition:function(){return we(u.get(),0)},getMode:function(){return zu.getMode(n)}});return sr(o,i)},x=function(e,t){if(_.cancel(),p()){var r=O(e),o=e[0].position,i=w(o,t);d.set(o),u.set(1);var a=f.element;ln(a,"display"),function(e){return we(_e(e,c.get(),yt),!0)}(t)||(Ia(a,fE),zu.reset(n,f)),Km.showWithinBounds(f,y(r),{anchor:i,transition:{classes:[fE],mode:"placement"}},(function(){return Q.some(h())})),t.fold(c.clear,c.set),g()&&Kt(a,"display","none")}},_=Mg((function(){e.hasFocus()&&!e.removed&&(La(f.element,fE)?_.throttle():function(e,t){var n=Qe.fromDom(t.getBody()),r=function(e){return yt(e,n)},o=Qe.fromDom(t.selection.getNode());return function(e){return!r(e)&&!Ot(n,e)}(o)?Q.none():iE(o,e.inNodeScope,e.inEditorScope).orThunk((function(){return aE(r,o,e)}))}(b(),e).fold(v,(function(e){x(e.toolbars,Q.some(e.elem))})))}),17);e.on("init",(function(){e.on("remove",v),e.on("ScrollContent ScrollWindow ObjectResized ResizeEditor longpress",A),e.on("click keyup focus SetContent",_.throttle),e.on(WN,v),e.on("contexttoolbar-show",(function(t){var n=b();ye(n.lookupTable,t.toolbarKey).each((function(n){x([n],Ce(t.target!==e,t.target)),Km.getContent(f).each(rm.focusIn)}))})),e.on("focusout",(function(t){Ag.setEditorTimeout(e,(function(){Ps(n.element).isNone()&&Ps(f.element).isNone()&&v()}),0)})),e.on("SwitchMode",(function(){e.mode.isReadOnly()&&v()})),e.on("AfterProgressState",(function(t){t.state?v():e.hasFocus()&&_.throttle()})),e.on("NodeChange",(function(e){Ps(f.element).fold(_.throttle,m)}))}))},pE={unsupportedLength:["em","ex","cap","ch","ic","rem","lh","rlh","vw","vh","vi","vb","vmin","vmax","cm","mm","Q","in","pc","pt","px"],fixed:["px","pt"],relative:["%"],empty:[""]},mE=(HT="[eE][+-]?"+(UT="[0-9]+"),WT=function(e){return"(?:"+e+")?"},jT=["Infinity",UT+"\\."+WT(UT)+WT(HT),"\\."+UT+WT(HT),UT+WT(HT)].join("|"),new RegExp("^([+-]?(?:"+jT+"))(.*)$")),gE=function(e,t){return Q.from(mE.exec(e)).bind((function(e){var n=Number(e[1]),r=e[2];return function(e,t){return I(t,(function(t){return I(pE[t],(function(t){return e===t}))}))}(r,t)?Q.some({value:n,unit:r}):Q.none()}))},vE=function(e,t){var n=function(){var n=t.getOptions(e),r=t.getCurrent(e).map(t.hash),o=ec();return U(n,(function(n){return{type:"togglemenuitem",text:t.display(n),onSetup:function(i){var a=function(e){e&&(o.on((function(e){return e.setActive(!1)})),o.set(i)),i.setActive(e)};a(we(r,t.hash(n)));var l=t.watcher(e,n,a);return function(){o.clear(),l()}},onAction:function(){return t.setCurrent(e,n)}}}))};e.ui.registry.addMenuButton(t.name,{tooltip:t.text,icon:t.icon,fetch:function(e){return e(n())},onSetup:t.onToolbarSetup}),e.ui.registry.addNestedMenuItem(t.name,{type:"nestedmenuitem",text:t.text,getSubmenuItems:n,onSetup:t.onMenuSetup})},AE={name:"lineheight",text:"Line height",icon:"line-height",getOptions:function(e){return e.getParam("lineheight_formats","1 1.1 1.2 1.3 1.4 1.5 2","string").split(" ")},hash:function(e){return function(e,t){return gE(e,t).map((function(e){return e.value+e.unit}))}(e,["fixed","relative","empty"]).getOr(e)},display:A,watcher:function(e,t,n){return e.formatter.formatChanged("lineheight",n,!1,{value:t}).unbind},getCurrent:function(e){return Q.from(e.queryCommandValue("LineHeight"))},setCurrent:function(e,t){return e.execCommand("LineHeight",!1,t)}},yE=function(e){vE(e,AE),function(e){var t=Q.from(function(e){return e.getParam("content_langs",void 0,"array")}(e));return t.map((function(t){return{name:"language",text:"Language",icon:"language",getOptions:v(t),hash:function(e){return c(e.customCode)?e.code:e.code+"/"+e.customCode},display:function(e){return e.title},watcher:function(e,t,n){return e.formatter.formatChanged("lang",n,!1,{value:t.code,customValue:t.customCode}).unbind},getCurrent:function(e){var t=Qe.fromDom(e.selection.getNode());return No(t,(function(e){return Q.some(e).filter(ze).bind((function(e){return qt(e,"lang").map((function(t){return{code:t,customCode:qt(e,"data-mce-lang").getOrUndefined(),title:""}}))}))}))},setCurrent:function(e,t){return e.execCommand("Lang",!1,t)},onToolbarSetup:function(t){var n=Js();return t.setActive(e.formatter.match("lang",{},void 0,!0)),n.set(e.formatter.formatChanged("lang",t.setActive,!0)),n.clear}}}))}(e).each((function(t){return vE(e,t)}))},bE=function(e,t){!function(e,t){var n=LT(0,t,GT(e));e.ui.registry.addNestedMenuItem("align",{text:t.shared.providers.translate("Align"),getSubmenuItems:function(){return n.items.validateItems(n.getStyleItems())}})}(e,t),function(e,t){var n=LT(0,t,JT(e));e.ui.registry.addNestedMenuItem("fontformats",{text:t.shared.providers.translate("Fonts"),getSubmenuItems:function(){return n.items.validateItems(n.getStyleItems())}})}(e,t),function(e,t){var n=k({type:"advanced"},t.styleselect),r=LT(0,t,aN(e,n));e.ui.registry.addNestedMenuItem("formats",{text:"Formats",getSubmenuItems:function(){return r.items.validateItems(r.getStyleItems())}})}(e,t),function(e,t){var n=LT(0,t,iN(e));e.ui.registry.addNestedMenuItem("blockformats",{text:"Blocks",getSubmenuItems:function(){return n.items.validateItems(n.getStyleItems())}})}(e,t),function(e,t){var n=LT(0,t,rN(e));e.ui.registry.addNestedMenuItem("fontsizes",{text:"Font sizes",getSubmenuItems:function(){return n.items.validateItems(n.getStyleItems())}})}(e,t)},OE=function(e){return $T(e,"NodeChange",(function(t){t.setDisabled(!e.queryCommandState("outdent"))}))},wE=function(e){!function(e){e.ui.registry.addButton("outdent",{tooltip:"Decrease indent",icon:"outdent",onSetup:OE(e),onAction:RT(e,"outdent")}),e.ui.registry.addButton("indent",{tooltip:"Increase indent",icon:"indent",onAction:RT(e,"indent")})}(e)},xE=function(e,t){return function(){e.execCommand("mceToggleFormat",!1,t)}},_E=function(e){!function(e){__.each([{name:"bold",text:"Bold",icon:"bold"},{name:"italic",text:"Italic",icon:"italic"},{name:"underline",text:"Underline",icon:"underline"},{name:"strikethrough",text:"Strikethrough",icon:"strike-through"},{name:"subscript",text:"Subscript",icon:"subscript"},{name:"superscript",text:"Superscript",icon:"superscript"}],(function(t,n){e.ui.registry.addToggleButton(t.name,{tooltip:t.text,icon:t.icon,onSetup:DT(e,t.name),onAction:xE(e,t.name)})}));for(var t=1;t<=6;t++){var n="h"+t;e.ui.registry.addToggleButton(n,{text:n.toUpperCase(),tooltip:"Heading "+t,onSetup:DT(e,n),onAction:xE(e,n)})}}(e),function(e){__.each([{name:"cut",text:"Cut",action:"Cut",icon:"cut"},{name:"copy",text:"Copy",action:"Copy",icon:"copy"},{name:"paste",text:"Paste",action:"Paste",icon:"paste"},{name:"help",text:"Help",action:"mceHelp",icon:"help"},{name:"selectall",text:"Select all",action:"SelectAll",icon:"select-all"},{name:"newdocument",text:"New document",action:"mceNewDocument",icon:"new-document"},{name:"removeformat",text:"Clear formatting",action:"RemoveFormat",icon:"remove-formatting"},{name:"remove",text:"Remove",action:"Delete",icon:"remove"}],(function(t){e.ui.registry.addButton(t.name,{tooltip:t.text,icon:t.icon,onAction:RT(e,t.action)})}))}(e),function(e){__.each([{name:"blockquote",text:"Blockquote",action:"mceBlockQuote",icon:"quote"}],(function(t){e.ui.registry.addToggleButton(t.name,{tooltip:t.text,icon:t.icon,onAction:RT(e,t.action),onSetup:DT(e,t.name)})}))}(e)},CE=function(e){_E(e),function(e){__.each([{name:"bold",text:"Bold",action:"Bold",icon:"bold",shortcut:"Meta+B"},{name:"italic",text:"Italic",action:"Italic",icon:"italic",shortcut:"Meta+I"},{name:"underline",text:"Underline",action:"Underline",icon:"underline",shortcut:"Meta+U"},{name:"strikethrough",text:"Strikethrough",action:"Strikethrough",icon:"strike-through",shortcut:""},{name:"subscript",text:"Subscript",action:"Subscript",icon:"subscript",shortcut:""},{name:"superscript",text:"Superscript",action:"Superscript",icon:"superscript",shortcut:""},{name:"removeformat",text:"Clear formatting",action:"RemoveFormat",icon:"remove-formatting",shortcut:""},{name:"newdocument",text:"New document",action:"mceNewDocument",icon:"new-document",shortcut:""},{name:"cut",text:"Cut",action:"Cut",icon:"cut",shortcut:"Meta+X"},{name:"copy",text:"Copy",action:"Copy",icon:"copy",shortcut:"Meta+C"},{name:"paste",text:"Paste",action:"Paste",icon:"paste",shortcut:"Meta+V"},{name:"selectall",text:"Select all",action:"SelectAll",icon:"select-all",shortcut:"Meta+A"}],(function(t){e.ui.registry.addMenuItem(t.name,{text:t.text,icon:t.icon,shortcut:t.shortcut,onAction:RT(e,t.action)})})),e.ui.registry.addMenuItem("codeformat",{text:"Code",icon:"sourcecode",onAction:xE(e,"code")})}(e)},kE=function(e,t){return $T(e,"Undo Redo AddUndo TypingUndo ClearUndos SwitchMode",(function(n){n.setDisabled(e.mode.isReadOnly()||!e.undoManager[t]())}))},SE=function(e){!function(e){e.ui.registry.addMenuItem("undo",{text:"Undo",icon:"undo",shortcut:"Meta+Z",onSetup:kE(e,"hasUndo"),onAction:RT(e,"undo")}),e.ui.registry.addMenuItem("redo",{text:"Redo",icon:"redo",shortcut:"Meta+Y",onSetup:kE(e,"hasRedo"),onAction:RT(e,"redo")})}(e),function(e){e.ui.registry.addButton("undo",{tooltip:"Undo",icon:"undo",disabled:!0,onSetup:kE(e,"hasUndo"),onAction:RT(e,"undo")}),e.ui.registry.addButton("redo",{tooltip:"Redo",icon:"redo",disabled:!0,onSetup:kE(e,"hasRedo"),onAction:RT(e,"redo")})}(e)},VE=function(e){return $T(e,"VisualAid",(function(t){t.setActive(e.hasVisual)}))},BE=function(e){!function(e){e.ui.registry.addButton("visualaid",{tooltip:"Visual aids",text:"Visual aids",onAction:RT(e,"mceToggleVisualAid")})}(e),function(e){e.ui.registry.addToggleMenuItem("visualaid",{text:"Visual aids",onSetup:VE(e),onAction:RT(e,"mceToggleVisualAid")})}(e)},TE=function(e,t){!function(e){H([{name:"alignleft",text:"Align left",cmd:"JustifyLeft",icon:"align-left"},{name:"aligncenter",text:"Align center",cmd:"JustifyCenter",icon:"align-center"},{name:"alignright",text:"Align right",cmd:"JustifyRight",icon:"align-right"},{name:"alignjustify",text:"Justify",cmd:"JustifyFull",icon:"align-justify"}],(function(t){e.ui.registry.addToggleButton(t.name,{tooltip:t.text,icon:t.icon,onAction:RT(e,t.cmd),onSetup:DT(e,t.name)})})),e.ui.registry.addButton("alignnone",{tooltip:"No alignment",icon:"align-none",onAction:RT(e,"JustifyNone")})}(e),CE(e),bE(e,t),SE(e),function(e){!function(e){e.addCommand("mceApplyTextcolor",(function(t,n){!function(e,t,n){e.undoManager.transact((function(){e.focus(),e.formatter.apply(t,{value:n}),e.nodeChanged()}))}(e,t,n)})),e.addCommand("mceRemoveTextcolor",(function(t){!function(e,t){e.undoManager.transact((function(){e.focus(),e.formatter.remove(t,{value:null},null,!0),e.nodeChanged()}))}(e,t)}))}(e);var t=wo(rb),n=wo(rb);ub(e,"forecolor","forecolor","Text color",t),ub(e,"backcolor","hilitecolor","Background color",n),db(e,"forecolor","forecolor","Text color"),db(e,"backcolor","hilitecolor","Background color")}(e),BE(e),wE(e),yE(e)},NE=function(e,t){return{type:"makeshift",x:e,y:t}},EE=function(e){return"longpress"===e.type||0===e.type.indexOf("touch")},PE=function(e,t){var n=vA.DOM.getPos(e);return function(e,t,n){return NE(e.x+t,e.y+n)}(t,n.x,n.y)},QE=function(e,t){return"contextmenu"===t.type||"longpress"===t.type?e.inline?function(e){if(EE(e)){var t=e.touches[0];return NE(t.pageX,t.pageY)}return NE(e.pageX,e.pageY)}(t):PE(e.getContentAreaContainer(),function(e){if(EE(e)){var t=e.touches[0];return NE(t.clientX,t.clientY)}return NE(e.clientX,e.clientY)}(t)):ME(e)},ME=function(e){return{type:"selection",root:Qe.fromDom(e.selection.getNode())}},DE=function(e,t,n){switch(n){case"node":return function(e){return{type:"node",node:Q.some(Qe.fromDom(e.selection.getNode())),root:Qe.fromDom(e.getBody())}}(e);case"point":return QE(e,t);case"selection":return ME(e)}},$E=function(e,t,n,r,o,i){var a=n(),l=DE(e,t,i);UC(a,Av.CLOSE_ON_EXECUTE,r,!1).map((function(e){t.preventDefault(),Km.showMenuAt(o,{anchor:l},{menu:{markers:Pv("normal")},data:e})}))},zE={onLtr:function(){return[as,ts,ns,rs,os,is,ug,dg,cg,lg,sg,ag]},onRtl:function(){return[as,ns,ts,os,rs,is,ug,dg,sg,ag,cg,lg]}},RE={valignCentre:[],alignCentre:[],alignLeft:["tox-pop--align-left"],alignRight:["tox-pop--align-right"],right:["tox-pop--right"],left:["tox-pop--left"],bottom:["tox-pop--bottom"],top:["tox-pop--top"]},IE=function(e,t,n,r,o,i,a){var l=function(e,t,n){var r=DE(e,t,n);return k({bubble:yc(0,"point"===n?12:0,RE),layouts:zE,overrides:{maxWidthFunction:qB(),maxHeightFunction:mc()}},r)}(e,t,i);UC(n,Av.CLOSE_ON_EXECUTE,r,!0).map((function(n){t.preventDefault(),Km.showMenuWithinBounds(o,{anchor:l},{menu:{markers:Pv("normal"),highlightImmediately:a},data:n,type:"horizontal"},(function(){return Q.some(KN(e,r.shared,"node"===i?"node":"selection"))})),e.fire(WN)}))},LE=function(e,t,n,r,o,i){var a=gt(),l=a.os.isiOS(),s=a.os.isOSX(),c=a.os.isAndroid(),u=a.deviceType.isTouch(),d=function(){var a=n();IE(e,t,a,r,o,i,!(c||l||s&&u))};if((s||l)&&"node"!==i){var f=function(){!function(e){var t=e.selection.getRng(),n=function(){Ag.setEditorTimeout(e,(function(){e.selection.setRng(t)}),10),i()};e.once("touchend",n);var r=function(e){e.preventDefault(),e.stopImmediatePropagation()};e.on("mousedown",r,!0);var o=function(){return i()};e.once("longpresscancel",o);var i=function(){e.off("touchend",n),e.off("longpresscancel",o),e.off("mousedown",r)}}(e),d()};!function(e,t){var n=e.selection;if(n.isCollapsed()||t.touches.length<1)return!1;var r=t.touches[0],o=n.getRng();return uu(e.getWin(),Wc.domRange(o)).exists((function(e){return e.left<=r.clientX&&e.right>=r.clientX&&e.top<=r.clientY&&e.bottom>=r.clientY}))}(e,t)?(e.once("selectionchange",f),e.once("touchend",(function(){return e.off("selectionchange",f)}))):f()}else d()},FE=function(e){return"string"==typeof e?e.split(/[ ,]/):e},UE=function(e){return e.getParam("contextmenu_never_use_native",!1,"boolean")},HE=function(e){return function(e,t,n){var r=e.ui.registry.getAll().contextMenus;return Q.from(e.getParam(t)).map(FE).getOrThunk((function(){return j(FE(n),(function(e){return be(r,e)}))}))}(e,"contextmenu","link linkchecker image imagetools table spellchecker configurepermanentpen")},WE=function(e){return o(e)?"|"===e:"separator"===e.type},jE={type:"separator"},qE=function(e){var t,n=function(e){return{text:e.text,icon:e.icon,disabled:e.disabled,shortcut:e.shortcut}};if(o(e))return e;switch(e.type){case"separator":return jE;case"submenu":return k(k({type:"nestedmenuitem"},n(e)),{getSubmenuItems:function(){var t=e.getSubmenuItems();return o(t)?t:U(t,qE)}});default:return k(k({type:"menuitem"},n(e)),{onAction:(t=e.onAction,function(){return t()})})}},XE=function(e,t){if(0===t.length)return e;var n=le(e).filter((function(e){return!WE(e)})),r=n.fold((function(){return[]}),(function(e){return[jE]}));return e.concat(r).concat(t).concat([jE])},YE=function(e,t){return"longpress"!==t.type&&(2!==t.button||t.target===e.getBody()&&""===t.pointerType)},GE=function(e,t){return YE(e,t)?e.selection.getStart(!0):t.target},ZE=function(e,t,n){var r=gt().deviceType.isTouch,i=tl(Km.sketch({dom:{tag:"div"},lazySink:t,onEscape:function(){return e.focus()},onShow:function(){return n.setContextMenuState(!0)},onHide:function(){return n.setContextMenuState(!1)},fireDismissalEventInstead:{},inlineBehaviours:Os([um("dismissContextMenu",[Ri(wi(),(function(t,n){ld.close(t),e.focus()}))])])})),a=function(e){return Km.hide(i)},l=function(t){if(UE(e)&&t.preventDefault(),!function(e,t){return t.ctrlKey&&!UE(e)}(e,t)&&!function(e){return!1===e.getParam("contextmenu")}(e)){var a=function(e,t){var n=function(e){return e.getParam("contextmenu_avoid_overlap","","string")}(e),r=YE(e,t)?"selection":"point";if(Ne(n)){var o=GE(e,t);return Mb(Qe.fromDom(o),n)?"node":r}return r}(e,t);(r()?LE:$E)(e,t,(function(){var n=GE(e,t),r=e.ui.registry.getAll(),i=HE(e);return function(e,t,n){var r=X(t,(function(t,r){return ye(e,r.toLowerCase()).map((function(e){var r=e.update(n);if(o(r))return XE(t,r.split(" "));if(r.length>0){var i=U(r,qE);return XE(t,i)}return t})).getOrThunk((function(){return t.concat([r])}))}),[]);return r.length>0&&WE(r[r.length-1])&&r.pop(),r}(r.contextMenus,i,n)}),n,i,a)}};e.on("init",(function(){var t="ResizeEditor ScrollContent ScrollWindow longpresscancel"+(r()?"":" ResizeWindow");e.on(t,a),e.on("longpress contextmenu",l)}))},KE=xo([{offset:["x","y"]},{absolute:["x","y"]},{fixed:["x","y"]}]),JE=function(e){return function(t){return t.translate(-e.left,-e.top)}},eP=function(e){return function(t){return t.translate(e.left,e.top)}},tP=function(e){return function(t,n){return X(e,(function(e,t){return t(e)}),pn(t,n))}},nP=function(e,t,n){return e.fold(tP([eP(n),JE(t)]),tP([JE(t)]),tP([]))},rP=function(e,t,n){return e.fold(tP([eP(n)]),tP([]),tP([eP(t)]))},oP=function(e,t,n){return e.fold(tP([]),tP([JE(n)]),tP([eP(t),JE(n)]))},iP=function(e,t,n){var r=e.fold((function(e,t){return{position:Q.some("absolute"),left:Q.some(e+"px"),top:Q.some(t+"px")}}),(function(e,t){return{position:Q.some("absolute"),left:Q.some(e-n.left+"px"),top:Q.some(t-n.top+"px")}}),(function(e,t){return{position:Q.some("fixed"),left:Q.some(e+"px"),top:Q.some(t+"px")}}));return k({right:Q.none(),bottom:Q.none()},r)},aP=function(e,t,n,r){var o=function(e,o){return function(i,a){var l=e(t,n,r);return o(i.getOr(l.left),a.getOr(l.top))}};return e.fold(o(oP,lP),o(rP,sP),o(nP,cP))},lP=KE.offset,sP=KE.absolute,cP=KE.fixed,uP=function(e,t){var n=jt(e,t);return c(n)?NaN:parseInt(n,10)},dP=function(e,t,n,r){return function(e,t){var n=e.element,r=uP(n,t.leftAttr),o=uP(n,t.topAttr);return isNaN(r)||isNaN(o)?Q.none():Q.some(pn(r,o))}(e,t).fold((function(){return n}),(function(e){return cP(e.left+r.left,e.top+r.top)}))},fP=function(e,t,n,r,o,i){var a=dP(e,t,n,r),l=t.mustSnap?mP(e,t,a,o,i):gP(e,t,a,o,i),s=nP(a,o,i);return function(e,t,n){var r=e.element;Ht(r,t.leftAttr,n.left+"px"),Ht(r,t.topAttr,n.top+"px")}(e,t,s),l.fold((function(){return{coord:cP(s.left,s.top),extra:Q.none()}}),(function(e){return{coord:e.output,extra:e.extra}}))},hP=function(e,t){!function(e,t){var n=e.element;Yt(n,t.leftAttr),Yt(n,t.topAttr)}(e,t)},pP=function(e,t,n,r){return ce(e,(function(e){var o=e.sensor,i=function(e,t,n,r,o,i){var a=rP(e,o,i),l=rP(t,o,i);return Math.abs(a.left-l.left)<=n&&Math.abs(a.top-l.top)<=r}(t,o,e.range.left,e.range.top,n,r);return i?Q.some({output:aP(e.output,t,n,r),extra:e.extra}):Q.none()}))},mP=function(e,t,n,r,o){var i=t.getSnapPoints(e);return pP(i,n,r,o).orThunk((function(){var e=X(i,(function(e,t){var i=t.sensor,a=function(e,t,n,r,o,i){var a=rP(e,o,i),l=rP(t,o,i),s=Math.abs(a.left-l.left),c=Math.abs(a.top-l.top);return pn(s,c)}(n,i,t.range.left,t.range.top,r,o);return e.deltas.fold((function(){return{deltas:Q.some(a),snap:Q.some(t)}}),(function(n){return(a.left+a.top)/2<=(n.left+n.top)/2?{deltas:Q.some(a),snap:Q.some(t)}:e}))}),{deltas:Q.none(),snap:Q.none()});return e.snap.map((function(e){return{output:aP(e.output,n,r,o),extra:e.extra}}))}))},gP=function(e,t,n,r,o){var i=t.getSnapPoints(e);return pP(i,n,r,o)},vP=Object.freeze({__proto__:null,snapTo:function(e,t,n,r){var o=t.getTarget(e.element);if(t.repositionTarget){var i=wt(e.element),a=En(i),l=OV(o),s=function(e,t,n){return{coord:aP(e.output,e.output,t,n),extra:e.extra}}(r,a,l),c=iP(s.coord,0,l);en(o,c)}}}),AP="data-initial-z-index",yP=function(e,t){e.getSystem().addToGui(t),function(e){kt(e.element).filter(ze).each((function(t){rn(t,"z-index").each((function(e){Ht(t,AP,e)})),Kt(t,"z-index",tn(e.element,"z-index"))}))}(t)},bP=function(e){!function(e){kt(e.element).filter(ze).each((function(e){qt(e,AP).fold((function(){return ln(e,"z-index")}),(function(t){return Kt(e,"z-index",t)})),Yt(e,AP)}))}(e),e.getSystem().removeFromGui(e)},OP=function(e,t,n){return e.getSystem().build(Yb.sketch({dom:{styles:{left:"0px",top:"0px",width:"100%",height:"100%",position:"fixed","z-index":"1000000000000000"},classes:[t]},events:n}))},wP=fo("snaps",[Gr("getSnapPoints"),Vl("onSensor"),Gr("leftAttr"),Gr("topAttr"),ho("lazyViewport",Fn),ho("mustSnap",!1)]),xP=[ho("useFixed",x),Gr("blockerClass"),ho("getTarget",A),ho("onDrag",m),ho("repositionTarget",!0),ho("onDrop",m),yo("getBounds",Fn),wP],_P=function(e){return(t=rn(e,"left"),n=rn(e,"top"),r=rn(e,"position"),o=function(e,t,n){return("fixed"===n?cP:lP)(parseInt(e,10),parseInt(t,10))},t.isSome()&&n.isSome()&&r.isSome()?Q.some(o(t.getOrDie(),n.getOrDie(),r.getOrDie())):Q.none()).getOrThunk((function(){var t=gn(e);return sP(t.left,t.top)}));var t,n,r,o},CP=function(e,t,n,r,o,i,a){return function(e,t,n,r,o){var i=o.bounds,a=rP(t,n,r),l=jl(a.left,i.x,i.x+i.width-o.width),s=jl(a.top,i.y,i.y+i.height-o.height),c=sP(l,s);return t.fold((function(){var e=oP(c,n,r);return lP(e.left,e.top)}),v(c),(function(){var e=nP(c,n,r);return cP(e.left,e.top)}))}(0,t.fold((function(){var e,t,a,l=(e=n,t=i.left,a=i.top,e.fold((function(e,n){return lP(e+t,n+a)}),(function(e,n){return sP(e+t,n+a)}),(function(e,n){return cP(e+t,n+a)}))),s=nP(l,r,o);return cP(s.left,s.top)}),(function(t){var a=fP(e,t,n,i,r,o);return a.extra.each((function(n){t.onSensor(e,n)})),a.coord})),r,o,a)},kP=function(e,t){return{bounds:e.getBounds(),height:fn(t.element),width:bn(t.element)}},SP=function(e,t,n,r,o){var i=n.update(r,o),a=n.getStartData().getOrThunk((function(){return kP(t,e)}));i.each((function(n){!function(e,t,n,r){var o=t.getTarget(e.element);if(t.repositionTarget){var i=wt(e.element),a=En(i),l=OV(o),s=_P(o),c=CP(e,t.snaps,s,a,l,r,n),u=iP(c,0,l);en(o,u)}t.onDrag(e,o,r)}(e,t,a,n)}))},VP=function(e,t,n,r){t.each(bP),n.snaps.each((function(t){hP(e,t)}));var o=n.getTarget(e.element);r.reset(),n.onDrop(e,o)},BP=function(e){return function(t,n){var r=function(e){n.setStartData(kP(t,e))};return Di(V([Ri(Ai(),(function(e){n.getStartData().each((function(){return r(e)}))}))],e(t,n,r),!0))}},TP=Object.freeze({__proto__:null,getData:function(e){return Q.from(pn(e.x,e.y))},getDelta:function(e,t){return pn(t.left-e.left,t.top-e.top)}}),NP=function(e,t,n){return[Ri(Lo(),(function(r,o){if(0===o.event.raw.button){o.stop();var i=function(){return VP(r,Q.some(s),e,t)},a=Db(i,200),l={drop:i,delayDrop:a.schedule,forceDrop:i,move:function(n){a.cancel(),SP(r,e,t,TP,n)}},s=OP(r,e.blockerClass,function(e){return Di([Ri(Lo(),e.forceDrop),Ri(Ho(),e.drop),Ri(Fo(),(function(t,n){e.move(n.event)})),Ri(Uo(),e.delayDrop)])}(l));n(r),yP(r,s)}}))]},EP=V(V([],xP,!0),[El("dragger",{handlers:BP(NP)})],!1),PP=Object.freeze({__proto__:null,getData:function(e){var t=e.raw.touches;return 1===t.length?function(e){var t=e[0];return Q.some(pn(t.clientX,t.clientY))}(t):Q.none()},getDelta:function(e,t){return pn(t.left-e.left,t.top-e.top)}}),QP=function(e,t,n){var r=ec(),o=function(n){VP(n,r.get(),e,t),r.clear()};return[Ri($o(),(function(i,a){a.stop();var l=function(){return o(i)},s={drop:l,delayDrop:m,forceDrop:l,move:function(n){SP(i,e,t,PP,n)}},c=OP(i,e.blockerClass,function(e){return Di([Ri($o(),e.forceDrop),Ri(Ro(),e.drop),Ri(Io(),e.drop),Ri(zo(),(function(t,n){e.move(n.event)}))])}(s));r.set(c);n(i),yP(i,c)})),Ri(zo(),(function(n,r){r.stop(),SP(n,e,t,PP,r.event)})),Ri(Ro(),(function(e,t){t.stop(),o(e)})),Ri(Io(),o)]},MP=EP,DP=V(V([],xP,!0),[El("dragger",{handlers:BP(QP)})],!1),$P=V(V([],xP,!0),[El("dragger",{handlers:BP((function(e,t,n){return V(V([],NP(e,t,n),!0),QP(e,t,n),!0)}))})],!1),zP=Object.freeze({__proto__:null,mouse:MP,touch:DP,mouseOrTouch:$P}),RP=Object.freeze({__proto__:null,init:function(){var e=Q.none(),t=Q.none(),n=v({});return wa({readState:n,reset:function(){e=Q.none(),t=Q.none()},update:function(t,n){return t.getData(n).bind((function(n){return function(t,n){var r=e.map((function(e){return t.getDelta(e,n)}));return e=Q.some(n),r}(t,n)}))},getStartData:function(){return t},setStartData:function(e){t=Q.some(e)}})}}),IP=Cs({branchKey:"mode",branches:zP,name:"dragging",active:{events:function(e,t){return e.dragger.handlers(e,t)}},extra:{snap:function(e){return{sensor:e.sensor,range:e.range,output:e.output,extra:Q.from(e.extra)}}},state:RP,apis:vP}),LP=function(e,t,n,r,o,i){return e.fold((function(){return IP.snap({sensor:sP(n-20,r-20),range:pn(o,i),output:sP(Q.some(n),Q.some(r)),extra:{td:t}})}),(function(e){var o=n-20,i=r-20,a=e.element.dom.getBoundingClientRect();return IP.snap({sensor:sP(o,i),range:pn(40,40),output:sP(Q.some(n-a.width/2),Q.some(r-a.height/2)),extra:{td:t}})}))},FP=function(e,t,n){return{getSnapPoints:e,leftAttr:"data-drag-left",topAttr:"data-drag-top",onSensor:function(e,r){var o=r.td;(function(e,t){return e.exists((function(e){return yt(e,t)}))})(t.get(),o)||(t.set(o),n(o))},mustSnap:!0}},UP=function(e){return bg(yg.sketch({dom:{tag:"div",classes:["tox-selector"]},buttonBehaviours:Os([IP.config({mode:"mouseOrTouch",blockerClass:"blocker",snaps:e}),fw.config({})]),eventOrder:{mousedown:["dragging","alloy.base.behaviour"],touchstart:["dragging","alloy.base.behaviour"]}}))},HP=function(e,t){var n=wo([]),r=wo([]),o=wo(!1),i=ec(),a=ec(),l=function(e){var n=Ln(e);return LP(d.getOpt(t),e,n.x,n.y,n.width,n.height)},s=function(e){var n=Ln(e);return LP(f.getOpt(t),e,n.right,n.bottom,n.width,n.height)},c=FP((function(){return U(n.get(),(function(e){return l(e)}))}),i,(function(t){a.get().each((function(n){e.fire("TableSelectorChange",{start:t,finish:n})}))})),u=FP((function(){return U(r.get(),(function(e){return s(e)}))}),a,(function(t){i.get().each((function(n){e.fire("TableSelectorChange",{start:n,finish:t})}))})),d=UP(c),f=UP(u),h=tl(d.asSpec()),p=tl(f.asSpec()),m=function(t,n,r,o){var i=r(n);IP.snapTo(t,i);!function(t,n,r,o){var i=n.dom.getBoundingClientRect();ln(t.element,"display");var a=Ct(Qe.fromDom(e.getBody())).dom.innerHeight,l=r(i),s=o(i,a);(l||s)&&Kt(t.element,"display","none")}(t,n,(function(e){return e[o]<0}),(function(e,t){return e[o]>t}))},g=function(e){return m(h,e,l,"top")},v=function(e){return m(p,e,s,"bottom")};gt().deviceType.isTouch()&&(e.on("TableSelectionChange",(function(e){o.get()||(Uu(t,h),Uu(t,p),o.set(!0)),i.set(e.start),a.set(e.finish),e.otherCells.each((function(t){n.set(t.upOrLeftCells),r.set(t.downOrRightCells),g(e.start),v(e.finish)}))})),e.on("ResizeEditor ResizeWindow ScrollContent",(function(){i.get().each(g),a.get().each(v)})),e.on("TableSelectionClear",(function(){o.get()&&(ju(h),ju(p),o.set(!1)),i.clear(),a.clear()})))},WP=function(e){if(1===e.nodeType){if("BR"===e.nodeName||e.getAttribute("data-mce-bogus"))return!0;if("bookmark"===e.getAttribute("data-mce-type"))return!0}return!1},jP=function(e,t,n){t.delimiter||(t.delimiter="»");return{dom:{tag:"div",classes:["tox-statusbar__path"],attributes:{role:"navigation"}},behaviours:Os([rm.config({mode:"flow",selector:"div[role=button]"}),Zf.config({disabled:n.isDisabled}),XA(),nO.config({}),cm.config({}),um("elementPathEvents",[qi((function(r,o){e.shortcuts.add("alt+F11","focus statusbar elementpath",(function(){return rm.focusIn(r)})),e.on("NodeChange",(function(o){var i,a,l=function(t){for(var n=[],r=t.length;r-- >0;){var o=t[r];if(1===o.nodeType&&!WP(o)){var i=e.fire("ResolveName",{name:o.nodeName.toLowerCase(),target:o});if(i.isDefaultPrevented()||n.push({name:i.name,element:o}),i.isPropagationStopped())break}}return n}(o.parents);l.length>0?cm.set(r,(i=U(l||[],(function(t,r){return yg.sketch({dom:{tag:"div",classes:["tox-statusbar__path-item"],attributes:{role:"button","data-index":r,"tab-index":-1,"aria-level":r+1},innerHtml:t.name},action:function(n){e.focus(),e.selection.select(t.element),e.nodeChanged()},buttonBehaviours:Os([GA(n.isDisabled),XA()])})})),a={dom:{tag:"div",classes:["tox-statusbar__path-divider"],attributes:{"aria-hidden":!0},innerHtml:" "+t.delimiter+" "}},X(i.slice(1),(function(e,t){var n=e;return n.push(a),n.push(t),n}),[i[0]]))):cm.set(r,[])}))}))])]),components:[]}};!function(e){e[e.None=0]="None",e[e.Both=1]="Both",e[e.Vertical=2]="Vertical"}(qT||(qT={}));var qP=function(e,t,n){var r=Qe.fromDom(e.getContainer()),o=function(e,t,n,r,o){var i={};return i.height=RN(r+t.top,wA(e),_A(e)),n===qT.Both&&(i.width=RN(o+t.left,OA(e),xA(e))),i}(e,t,n,dn(r),yn(r));fe(o,(function(e,t){return Kt(r,t,zN(e))})),function(e){e.fire("ResizeEditor")}(e)},XP=function(e,t,n,r){var o=pn(20*n,20*r);return qP(e,o,t),Q.some(!0)},YP=function(e,t){var n=function(e){var t=!e.hasPlugin("autoresize"),n=e.getParam("resize",t);return!1===n?qT.None:"both"===n?qT.Both:qT.Vertical}(e);return n===qT.None?Q.none():Q.some(Tg("resize-handle",{tag:"div",classes:["tox-statusbar__resize-handle"],attributes:{title:t.translate("Resize")},behaviours:[IP.config({mode:"mouse",repositionTarget:!1,onDrag:function(t,r,o){return qP(e,o,n)},blockerClass:"tox-blocker"}),rm.config({mode:"special",onLeft:function(){return XP(e,n,-1,0)},onRight:function(){return XP(e,n,1,0)},onUp:function(){return XP(e,n,0,-1)},onDown:function(){return XP(e,n,0,1)}}),nO.config({}),mm.config({})]},t.icons))},GP=function(e,t){var n=function(){var n,r=[];return e.getParam("elementpath",!0,"boolean")&&r.push(jP(e,{},t)),e.hasPlugin("wordcount")&&r.push(function(e,t){var n,r=function(e,n,r){return cm.set(e,[Ka(t.translate(["{0} "+r,n[r]]))])};return yg.sketch({dom:{tag:"button",classes:["tox-statusbar__wordcount"]},components:[],buttonBehaviours:Os([GA(t.isDisabled),XA(),nO.config({}),cm.config({}),Sd.config({store:{mode:"memory",initialValue:{mode:"words",count:{words:0,characters:0}}}}),um("wordcount-events",[Gi((function(e){var t=Sd.getValue(e),n="words"===t.mode?"characters":"words";Sd.setValue(e,{mode:n,count:t.count}),r(e,t.count,n)})),qi((function(t){e.on("wordCountUpdate",(function(e){var n=Sd.getValue(t).mode;Sd.setValue(t,{mode:n,count:e.wordCount}),r(t,e.wordCount,n)}))}))])]),eventOrder:(n={},n[ci()]=["disabling","alloy.base.behaviour","wordcount-events"],n)})}(e,t)),e.getParam("branding",!0,"boolean")&&r.push({dom:{tag:"span",classes:["tox-statusbar__branding"],innerHtml:''+n+""}}),r.length>0?[{dom:{tag:"div",classes:["tox-statusbar__text-container"]},components:r}]:[]};return{dom:{tag:"div",classes:["tox-statusbar"]},components:function(){var r=n(),o=YP(e,t);return r.concat(o.toArray())}()}},ZP=function(e){var t,n,r,o,i=e.inline,a=i?HN:DN,l=RA(e)?YV:yV,s=Q.none(),c=gt(),u=c.browser.isIE()?["tox-platform-ie"]:[],d=c.deviceType.isTouch()?["tox-platform-touch"]:[],f=QA(e),h=$A(e),p=Og.isRtl()?{attributes:{dir:"rtl"}}:{},g={attributes:(t={},t[_c]=f?Us.BottomToTop:Us.TopToBottom,t)},v=function(){return s.bind(CT.getHeader)},A=function(){Kt(j.element,"width",document.body.clientWidth+"px")},y=tl((n=yt(Lt(),h)&&"grid"===tn(h,"display"),r={dom:k({tag:"div",classes:["tox","tox-silver-sink","tox-tinymce-aux"].concat(u).concat(d)},p),behaviours:Os([zu.config({useFixed:function(){return l.isDocked(v)}})])},o={dom:{styles:{width:document.body.clientWidth+"px"}},events:Di([Ri(yi(),A)])},sr(r,n?o:{}))),b=function(){return Wn.value(y)},O=bg({dom:{tag:"div",classes:["tox-anchorbar"]}}),w=function(){return s.bind((function(e){return CT.getThrobber(e)})).getOrDie("Could not find throbber element")},x=iV(y,e,(function(){return s.bind((function(e){return O.getOpt(e)})).getOrDie("Could not find a anchor bar element")})),_=CT.parts.menubar({dom:{tag:"div",classes:["tox-menubar"]},backstage:x,onEscape:function(){e.focus()}}),C=TA(e),S=CT.parts.toolbar(k({dom:{tag:"div",classes:["tox-toolbar"]},getSink:b,providers:x.shared.providers,onEscape:function(){e.focus()},type:C,lazyToolbar:function(){return s.bind((function(e){return CT.getToolbar(e)})).getOrDie("Could not find more toolbar element")},lazyHeader:function(){return v().getOrDie("Could not find header element")}},g)),V=CT.parts["multiple-toolbar"]({dom:{tag:"div",classes:["tox-toolbar-overlord"]},providers:x.shared.providers,onEscape:function(){e.focus()},type:C}),B=CT.parts.socket({dom:{tag:"div",classes:["tox-edit-area"]}}),T=CT.parts.sidebar({dom:{tag:"div",classes:["tox-sidebar"]}}),N=CT.parts.throbber({dom:{tag:"div",classes:["tox-throbber"]},backstage:x}),E=e.getParam("statusbar",!0,"boolean")&&!i?Q.some(GP(e,x.shared.providers)):Q.none(),P={dom:{tag:"div",classes:["tox-sidebar-wrap"]},components:[B,T]},M=VA(e),D=kA(e),$=CA(e),z=CT.parts.header({dom:k({tag:"div",classes:["tox-editor-header"]},g),components:Z([$?[_]:[],M?[V]:D?[S]:[],DA(e)?[]:[O.asSpec()]]),sticky:RA(e),editor:e,sharedBackstage:x.shared}),R=Z([f?[]:[z],i?[]:[P],f?[z]:[]]),I=Z([[{dom:{tag:"div",classes:["tox-editor-container"]},components:R}],i?[]:E.toArray(),[N]]),L=zA(e),F=k(k({role:"application"},Og.isRtl()?{dir:"rtl"}:{}),L?{"aria-hidden":"true"}:{}),U=tl(CT.sketch({dom:{tag:"div",classes:["tox","tox-tinymce"].concat(i?["tox-tinymce-inline"]:[]).concat(f?["tox-tinymce--toolbar-bottom"]:[]).concat(d).concat(u),styles:k({visibility:"hidden"},L?{opacity:"0",border:"0"}:{}),attributes:F},components:I,behaviours:Os([XA(),Zf.config({disableClass:"tox-tinymce--disabled"}),rm.config({mode:"cyclic",selector:".tox-menubar, .tox-toolbar, .tox-toolbar__primary, .tox-toolbar__overflow--open, .tox-sidebar__overflow--open, .tox-statusbar__path, .tox-statusbar__wordcount, .tox-statusbar__branding a, .tox-statusbar__resize-handle"})])}));s=Q.some(U),e.shortcuts.add("alt+F9","focus menubar",(function(){CT.focusMenubar(U)})),e.shortcuts.add("alt+F10","focus toolbar",(function(){CT.focusToolbar(U)})),e.addCommand("ToggleToolbarDrawer",(function(){CT.toggleToolbarDrawer(U)})),e.addQueryStateHandler("ToggleToolbarDrawer",(function(){return CT.isToolbarDrawerToggled(U)}));var W=Gb(U),j=Gb(y);!function(e,t,n){var r=function(e,r){H([t,n],(function(t){t.broadcastEvent(e,r)}))},o=function(e,r){H([t,n],(function(t){t.broadcastOn([e],r)}))},i=function(e){return o(sd(),{target:e.target})},a=Bs(),l=nc(a,"touchstart",i),s=nc(a,"touchmove",(function(e){return r(gi(),e)})),c=nc(a,"touchend",(function(e){return r(vi(),e)})),u=nc(a,"mousedown",i),d=nc(a,"mouseup",(function(e){0===e.raw.button&&o(ud(),{target:e.target})})),f=function(e){return o(sd(),{target:Qe.fromDom(e.target)})},h=function(e){0===e.button&&o(ud(),{target:Qe.fromDom(e.target)})},p=function(){H(e.editorManager.get(),(function(t){e!==t&&t.fire("DismissPopups",{relatedTarget:e})}))},m=function(e){return r(Ai(),oc(e))},g=function(e){o(cd(),{}),r(yi(),oc(e))},v=function(){return o(cd(),{})},A=function(t){t.state&&o(sd(),{target:Qe.fromDom(e.getContainer())})},y=function(e){o(sd(),{target:Qe.fromDom(e.relatedTarget.getContainer())})};e.on("PostRender",(function(){e.on("click",f),e.on("tap",f),e.on("mouseup",h),e.on("mousedown",p),e.on("ScrollWindow",m),e.on("ResizeWindow",g),e.on("ResizeEditor",v),e.on("AfterProgressState",A),e.on("DismissPopups",y)})),e.on("remove",(function(){e.off("click",f),e.off("tap",f),e.off("mouseup",h),e.off("mousedown",p),e.off("ScrollWindow",m),e.off("ResizeWindow",g),e.off("ResizeEditor",v),e.off("AfterProgressState",A),e.off("DismissPopups",y),u.unbind(),l.unbind(),s.unbind(),c.unbind(),d.unbind()})),e.on("detach",(function(){Gu(t),Gu(n),t.destroy(),n.destroy()}))}(e,W,j);var q=function(){var t=zN(IN(e)),n=zN(function(e){return LN(e).getOr(bA(e))}(e));return e.inline||(an("div","width",n)&&Kt(U.element,"width",n),an("div","height",t)?Kt(U.element,"height",t):Kt(U.element,"height","200px")),t};return{mothership:W,uiMothership:j,backstage:x,renderUI:function(){l.setup(e,x.shared,v),TE(e,x),ZE(e,b,x),function(e){var t=e.ui.registry.getAll().sidebars;H(ue(t),(function(n){var r=t[n],o=function(){return we(Q.from(e.queryCommandValue("ToggleSidebar")),n)};e.ui.registry.addToggleButton(n,{icon:r.icon,tooltip:r.tooltip,onAction:function(t){e.execCommand("ToggleSidebar",!1,n),t.setActive(o())},onSetup:function(t){var n=function(){return t.setActive(o())};return e.on("ToggleSidebar",n),function(){e.off("ToggleSidebar",n)}}})}))}(e),$B(e,w,x.shared),he(function(e){return e.getParam("toolbar_groups",{},"object")}(e),(function(t,n){e.ui.registry.addGroupToolbarButton(n,t)}));var t=e.ui.registry.getAll(),n=t.buttons,r=t.menuItems,o=t.contextToolbars,i=t.sidebars,s=SA(e),c={menuItems:r,menus:IA(e),menubar:LA(e),toolbar:s.getOrThunk((function(){return function(e){return e.getParam("toolbar",!0)}(e)})),allowToolbarGroups:C===vv.floating,buttons:n,sidebar:i};hE(e,o,y,{backstage:x}),HP(e,y);var u=e.getElement(),d=q(),f={mothership:W,uiMothership:j,outerContainer:U},h={targetNode:u,height:d};return a.render(e,f,c,x,h)},getUi:function(){return{channels:{broadcastAll:j.broadcast,broadcastOn:j.broadcastOn,register:m}}}}},KP=v([Gr("lazySink"),io("dragBlockClass"),yo("getBounds",Fn),ho("useTabstopAt",_),ho("eventOrder",{}),Vd("modalBehaviours",[rm]),Bl("onExecute"),Nl("onEscape")]),JP={sketch:A},eQ=v([af({name:"draghandle",overrides:function(e,t){return{behaviours:Os([IP.config({mode:"mouse",getTarget:function(e){return sl(e,'[role="dialog"]').getOr(e)},blockerClass:e.dragBlockClass.getOrDie(new Error("The drag blocker class was not specified for a dialog with a drag handle: \n"+JSON.stringify(t,null,2)).message),getBounds:e.getDragBounds})])}}}),rf({schema:[Gr("dom")],name:"title"}),rf({factory:JP,schema:[Gr("dom")],name:"close"}),rf({factory:JP,schema:[Gr("dom")],name:"body"}),af({factory:JP,schema:[Gr("dom")],name:"footer"}),of({factory:{sketch:function(e,t){return k(k({},e),{dom:t.dom,components:t.components})}},schema:[ho("dom",{tag:"div",styles:{position:"fixed",left:"0px",top:"0px",right:"0px",bottom:"0px"}}),ho("components",[])],name:"blocker"})]),tQ=Pf({name:"ModalDialog",configFields:KP(),partFields:eQ(),factory:function(e,t,n,r){var o,i=ec(),a=ia("modal-events"),l=k(k({},e.eventOrder),((o={})[bi()]=[a].concat(e.eventOrder["alloy.system.attached"]||[]),o));return{uid:e.uid,dom:e.dom,components:t,apis:{show:function(t){i.set(t);var n=e.lazySink(t).getOrDie(),o=r.blocker(),a=n.getSystem().build(k(k({},o),{components:o.components.concat([nl(t)]),behaviours:Os([mm.config({}),um("dialog-blocker-events",[ji(jo(),(function(){rm.focusIn(t)}))])])}));Uu(n,a),rm.focusIn(t)},hide:function(e){i.clear(),kt(e.element).each((function(t){e.getSystem().getByDom(t).each((function(e){ju(e)}))}))},getBody:function(t){return yf(t,e,"body")},getFooter:function(t){return yf(t,e,"footer")},setIdle:function(e){PB.unblock(e)},setBusy:function(e,t){PB.block(e,t)}},eventOrder:l,domModification:{attributes:{role:"dialog","aria-modal":"true"}},behaviours:Td(e.modalBehaviours,[cm.config({}),rm.config({mode:"cyclic",onEnter:e.onExecute,onEscape:e.onEscape,useTabstopAt:e.useTabstopAt}),PB.config({getRoot:i.get}),um(a,[qi((function(t){var n,r,o,i,a,l;n=t.element,r=yf(t,e,"title").element,o=qt(n,"id").fold((function(){var e=ia("dialog-label");return Ht(r,"id",e),e}),A),Ht(n,"aria-labelledby",o),i=t.element,a=yf(t,e,"body").element,l=Q.from(jt(i,"id")).fold((function(){var e=ia("dialog-describe");return Ht(a,"id",e),e}),A),Ht(i,"aria-describedby",l)}))])])}},apis:{show:function(e,t){e.show(t)},hide:function(e,t){e.hide(t)},getBody:function(e,t){return e.getBody(t)},getFooter:function(e,t){return e.getFooter(t)},setBusy:function(e,t,n){e.setBusy(t,n)},setIdle:function(e,t){e.setIdle(t)}}}),nQ=Cr([Jr("type"),Jr("name")].concat(Gv)),rQ=Qr,oQ=[qr("name","name",ur((function(){return ia("button-name")})),Pr),so("icon"),vo("align","end",["start","end"]),Ao("primary",!1),Ao("disabled",!1)],iQ=V(V([],oQ,!0),[Jr("text")],!1),aQ=V([eo("type",["submit","cancel","custom"])],iQ,!0),lQ=V([eo("type",["menu"]),so("text"),so("tooltip"),so("icon"),oo("items",nQ)],oQ,!0),sQ=jr("type",{submit:aQ,cancel:aQ,custom:aQ,menu:lQ}),cQ=[Jr("type"),Jr("text"),eo("level",["info","warn","error","success"]),Jr("icon"),ho("url","")],uQ=Cr(cQ),dQ=[Jr("type"),Jr("text"),Ao("disabled",!1),Ao("primary",!1),qr("name","name",ur((function(){return ia("button-name")})),Pr),so("icon"),Ao("borderless",!1)],fQ=Cr(dQ),hQ=[Jr("type"),Jr("name"),Jr("label"),Ao("disabled",!1)],pQ=Cr(hQ),mQ=Qr,gQ=[Jr("type"),Jr("name")],vQ=gQ.concat([so("label")]),AQ=vQ.concat([ho("columns","auto")]),yQ=Cr(AQ),bQ=Br([Jr("value"),Jr("text"),Jr("icon")]),OQ=Cr(vQ),wQ=Pr,xQ=Cr(vQ),_Q=Pr,CQ=gQ.concat([go("tag","textarea"),Jr("scriptId"),Jr("scriptUrl"),function(e,t){return po(e,t,$r)}("settings",void 0)]),kQ=gQ.concat([go("tag","textarea"),to("init")]),SQ=Ir((function(e){return Fr("customeditor.old",_r(kQ),e).orThunk((function(){return Fr("customeditor.new",_r(CQ),e)}))})),VQ=Pr,BQ=Cr(vQ),TQ=kr(Ar),NQ=function(e){return[Jr("type"),Kr("columns"),e]},EQ=[Jr("type"),Jr("html"),vo("presets","presentation",["presentation","document"])],PQ=Cr(EQ),QQ=vQ.concat([Ao("sandboxed",!0)]),MQ=Cr(QQ),DQ=Pr,$Q=vQ.concat([Zr("currentState",Cr([Gr("blob"),Jr("url")]))]),zQ=Cr($Q),RQ=vQ.concat([so("inputMode"),so("placeholder"),Ao("maximized",!1),Ao("disabled",!1)]),IQ=Cr(RQ),LQ=Pr,FQ=function(e){return[Jr("type"),Jr("label"),e]},UQ=[Jr("text"),Jr("value")],HQ=[Jr("text"),oo("items",function(e,t){return n=Fe(t),{extract:function(e,t){return n().extract(e,t)},toString:function(){return n().toString()}};var n}(0,(function(){return WQ})))],WQ=Sr([Cr(UQ),Cr(HQ)]),jQ=vQ.concat([oo("items",WQ),Ao("disabled",!1)]),qQ=Cr(jQ),XQ=Pr,YQ=vQ.concat([ro("items",[Jr("text"),Jr("value")]),mo("size",1),Ao("disabled",!1)]),GQ=Cr(YQ),ZQ=Pr,KQ=vQ.concat([Ao("constrain",!0),Ao("disabled",!1)]),JQ=Cr(KQ),eM=Cr([Jr("width"),Jr("height")]),tM=[Jr("type"),oo("header",Pr),oo("cells",kr(Pr))],nM=Cr(tM),rM=vQ.concat([so("placeholder"),Ao("maximized",!1),Ao("disabled",!1)]),oM=Cr(rM),iM=Pr,aM=vQ.concat([vo("filetype","file",["image","media","file"]),ho("disabled",!1)]),lM=Cr(aM),sM=Cr([Jr("value"),ho("meta",{})]),cM=function(e){return qr("items","items",{tag:"required",process:{}},kr(Ir((function(t){return Fr("Checking item of "+e,uM,t).fold((function(e){return Wn.error(Wr(e))}),(function(e){return Wn.value(e)}))}))))},uM=wr((function(){return Rr("type",{alertbanner:uQ,bar:Cr((e=cM("bar"),[Jr("type"),e])),button:fQ,checkbox:pQ,colorinput:OQ,colorpicker:xQ,dropzone:BQ,grid:Cr(NQ(cM("grid"))),iframe:MQ,input:IQ,listbox:qQ,selectbox:GQ,sizeinput:JQ,textarea:oM,urlinput:lM,customeditor:SQ,htmlpanel:PQ,imagetools:zQ,collection:yQ,label:Cr(FQ(cM("label"))),table:nM,panel:fM});var e})),dM=[Jr("type"),ho("classes",[]),oo("items",uM)],fM=Cr(dM),hM=[qr("name","name",ur((function(){return ia("tab-name")})),Pr),Jr("title"),oo("items",uM)],pM=[Jr("type"),ro("tabs",hM)],mM=Cr(pM),gM=iQ,vM=sQ,AM=Cr([Jr("title"),Zr("body",Rr("type",{panel:fM,tabpanel:mM})),go("size","normal"),oo("buttons",vM),ho("initialData",{}),yo("onAction",m),yo("onChange",m),yo("onSubmit",m),yo("onClose",m),yo("onCancel",m),ho("onTabChange",m)]),yM=Cr(V([eo("type",["cancel","custom"])],gM,!0)),bM=Cr([Jr("title"),Jr("url"),lo("height"),lo("width"),uo("buttons",yM),yo("onAction",m),yo("onCancel",m),yo("onClose",m),yo("onMessage",m)]),OM=function(e){return i(e)?[e].concat(K(Ae(e),OM)):a(e)?K(e,OM):[]},wM=function(e){return o(e.type)&&o(e.name)},xM={checkbox:mQ,colorinput:wQ,colorpicker:_Q,dropzone:TQ,input:LQ,iframe:DQ,sizeinput:eM,selectbox:ZQ,listbox:XQ,size:eM,textarea:iM,urlinput:sM,customeditor:VQ,collection:bQ,togglemenuitem:rQ},_M=function(e){var t=function(e){return j(OM(e),wM)}(e),n=K(t,(function(e){return function(e){return Q.from(xM[e.type])}(e).fold((function(){return[]}),(function(t){return[Zr(e.name,t)]}))}));return Cr(n)},CM=function(e){return{internalDialog:Ur(Fr("dialog",AM,e)),dataValidator:_M(e),initialData:e.initialData}},kM={open:function(e,t){var n=CM(t);return e(n.internalDialog,n.initialData,n.dataValidator)},openUrl:function(e,t){return e(Ur(Fr("dialog",bM,t)))},redial:function(e){return CM(e)}},SM=function(e){var t=[],n={};return fe(e,(function(e,r){e.fold((function(){t.push(r)}),(function(e){n[r]=e}))})),t.length>0?Wn.error(t):Wn.value(n)},VM=function(e,t){var n=bg(u_.sketch((function(n){return{dom:{tag:"div",classes:["tox-form"].concat(e.classes)},components:U(e.items,(function(e){return dS(n,e,t)}))}})));return{dom:{tag:"div",classes:["tox-dialog__body"]},components:[{dom:{tag:"div",classes:["tox-dialog__body-content"]},components:[n.asSpec()]}],behaviours:Os([rm.config({mode:"acyclic",useTabstopAt:O(R_)}),y_(n),V_(n,{postprocess:function(e){return SM(e).fold((function(e){return{}}),A)}})])}},BM=Ef({name:"TabButton",configFields:[ho("uid",void 0),Gr("value"),qr("dom","dom",fr((function(){return{attributes:{role:"tab",id:ia("aria"),"aria-selected":"false"}}})),Tr()),io("action"),ho("domModification",{}),Vd("tabButtonBehaviours",[mm,rm,Sd]),Gr("view")],factory:function(e,t){return{uid:e.uid,dom:e.dom,components:e.components,events:Bm(e.action),behaviours:Td(e.tabButtonBehaviours,[mm.config({}),rm.config({mode:"execution",useSpace:!0,useEnter:!0}),Sd.config({store:{mode:"memory",initialValue:e.value}})]),domModification:e.domModification}}}),TM=v([Gr("tabs"),Gr("dom"),ho("clickToDismiss",!1),Vd("tabbarBehaviours",[sh,rm]),kl(["tabClass","selectedClass"])]),NM=lf({factory:BM,name:"tabs",unit:"tab",overrides:function(e){var t=function(e,t){sh.dehighlight(e,t),Ni(e,Si(),{tabbar:e,button:t})},n=function(e,t){sh.highlight(e,t),Ni(e,ki(),{tabbar:e,button:t})};return{action:function(r){var o=r.getSystem().getByUid(e.uid).getOrDie(),i=sh.isHighlighted(o,r);(i&&e.clickToDismiss?t:i?m:n)(o,r)},domModification:{classes:[e.markers.tabClass]}}}}),EM=v([NM]),PM=Pf({name:"Tabbar",configFields:TM(),partFields:EM(),factory:function(e,t,n,r){return{uid:e.uid,dom:e.dom,components:t,"debug.sketcher":"Tabbar",domModification:{attributes:{role:"tablist"}},behaviours:Td(e.tabbarBehaviours,[sh.config({highlightClass:e.markers.selectedClass,itemClass:e.markers.tabClass,onHighlight:function(e,t){Ht(t.element,"aria-selected","true")},onDehighlight:function(e,t){Ht(t.element,"aria-selected","false")}}),rm.config({mode:"flow",getInitial:function(e){return sh.getHighlighted(e).map((function(e){return e.element}))},selector:"."+e.markers.tabClass,executeOnMove:!0})])}}}),QM=Ef({name:"Tabview",configFields:[Vd("tabviewBehaviours",[cm])],factory:function(e,t){return{uid:e.uid,dom:e.dom,behaviours:Td(e.tabviewBehaviours,[cm.config({})]),domModification:{attributes:{role:"tabpanel"}}}}}),MM=v([ho("selectFirst",!0),Vl("onChangeTab"),Vl("onDismissTab"),ho("tabs",[]),Vd("tabSectionBehaviours",[])]),DM=rf({factory:PM,schema:[Gr("dom"),no("markers",[Gr("tabClass"),Gr("selectedClass")])],name:"tabbar",defaults:function(e){return{tabs:e.tabs}}}),$M=rf({factory:QM,name:"tabview"}),zM=v([DM,$M]),RM=Pf({name:"TabSection",configFields:MM(),partFields:zM(),factory:function(e,t,n,r){var o=function(t,n){Af(t,e,"tabbar").each((function(e){n(e).each(Ei)}))};return{uid:e.uid,dom:e.dom,components:t,behaviours:Bd(e.tabSectionBehaviours),events:Di(Z([e.selectFirst?[qi((function(e,t){o(e,sh.getFirst)}))]:[],[Ri(ki(),(function(t,n){!function(t){var n=Sd.getValue(t);Af(t,e,"tabview").each((function(r){var o=Y(e.tabs,(function(e){return e.value===n}));o.each((function(n){var o=n.view();qt(t.element,"id").each((function(e){Ht(r.element,"aria-labelledby",e)})),cm.set(r,o),e.onChangeTab(r,t,o)}))}))}(n.event.button)})),Ri(Si(),(function(t,n){var r=n.event.button;e.onDismissTab(t,r)}))]])),apis:{getViewItems:function(t){return Af(t,e,"tabview").map((function(e){return cm.contents(e)})).getOr([])},showTab:function(e,t){o(e,(function(e){var n=sh.getCandidates(e);return Y(n,(function(e){return Sd.getValue(e)===t})).filter((function(t){return!sh.isHighlighted(e,t)}))}))}}}},apis:{getViewItems:function(e,t){return e.getViewItems(t)},showTab:function(e,t,n){e.showTab(t,n)}}}),IM=function(e,t){Kt(e,"height",t+"px"),gt().browser.isIE()?ln(e,"flex-basis"):Kt(e,"flex-basis",t+"px")},LM=function(e,t,n){sl(e,'[role="dialog"]').each((function(e){ul(e,'[role="tablist"]').each((function(r){n.get().map((function(n){return Kt(t,"height","0"),Kt(t,"flex-basis","0"),Math.min(n,function(e,t,n){var r,o=_t(e).dom,i=sl(e,".tox-dialog-wrap").getOr(e);r="fixed"===tn(i,"position")?Math.max(o.clientHeight,window.innerHeight):Math.max(o.offsetHeight,o.scrollHeight);var a=dn(t),l=t.dom.offsetLeft>=n.dom.offsetLeft+yn(n)?Math.max(dn(n),a):a,s=parseInt(tn(e,"margin-top"),10)||0,c=parseInt(tn(e,"margin-bottom"),10)||0;return r-(dn(e)+s+c-l)}(e,t,r))})).each((function(e){IM(t,e)}))}))}))},FM=function(e){return ul(e,'[role="tabpanel"]')},UM=function(e){var t,n,r=(t=ec(),n=[qi((function(n){var r=n.element;FM(r).each((function(o){Kt(o,"visibility","hidden"),n.getSystem().getByDom(o).toOptional().each((function(n){var r=function(e,t,n){return U(e,(function(r,o){cm.set(n,e[o].view());var i=t.dom.getBoundingClientRect();return cm.set(n,[]),i.height}))}(e,o,n),i=function(e){return ae(oe(e,(function(e,t){return e>t?-1:ee}))?(t.set(i),LM(r,e,t)):o.each((function(t){IM(e,t)})),ln(e,"visibility"),n.each(Ts)}))}))],{extraEvents:n,selectFirst:!1});return{smartTabHeight:r,naiveTabHeight:{extraEvents:[],selectFirst:!0}}},HM="send-data-to-section",WM="send-data-to-view",jM=function(e,t){var n=wo({}),r=function(e){var t=Sd.getValue(e),r=SM(t).getOr({}),o=n.get(),i=sr(o,r);n.set(i)},o=function(e){var t=n.get();Sd.setValue(e,t)},i=wo(null),a=U(e.tabs,(function(e){return{value:e.name,dom:{tag:"div",classes:["tox-dialog__body-nav-item"],innerHtml:t.shared.providers.translate(e.title)},view:function(){return[u_.sketch((function(n){return{dom:{tag:"div",classes:["tox-form"]},components:U(e.items,(function(e){return dS(n,e,t)})),formBehaviours:Os([rm.config({mode:"acyclic",useTabstopAt:O(R_)}),um("TabView.form.events",[qi(o),Xi(r)]),Ss.config({channels:So([{key:HM,value:{onReceive:r}},{key:WM,value:{onReceive:o}}])})])}}))]}}})),l=UM(a).smartTabHeight;return RM.sketch({dom:{tag:"div",classes:["tox-dialog__body"]},onChangeTab:function(e,t,n){var r=Sd.getValue(t);Ni(e,mO,{name:r,oldName:i.get()}),i.set(r)},tabs:a,components:[RM.parts.tabbar({dom:{tag:"div",classes:["tox-dialog__body-nav"]},components:[PM.parts.tabs({})],markers:{tabClass:"tox-tab",selectedClass:"tox-dialog__body-nav-item--active"},tabbarBehaviours:Os([nO.config({})])}),RM.parts.tabview({dom:{tag:"div",classes:["tox-dialog__body-content"]}})],selectFirst:l.selectFirst,tabSectionBehaviours:Os([um("tabpanel",l.extraEvents),rm.config({mode:"acyclic"}),$f.config({find:function(e){return ae(RM.getViewItems(e))}}),Sd.config({store:{mode:"manual",getValue:function(e){return e.getSystem().broadcastOn([HM],{}),n.get()},setValue:function(e,t){n.set(t),e.getSystem().broadcastOn([WM],{})}}})])})},qM=ia("update-dialog"),XM=ia("update-title"),YM=ia("update-body"),GM=ia("update-footer"),ZM=ia("body-send-message"),KM=function(e,t,n,r){return{dom:{tag:"div",classes:["tox-dialog__content-js"],attributes:k(k({},t.map((function(e){return{id:e}})).getOr({})),r?{"aria-live":"polite"}:{})},components:[],behaviours:Os([b_(0),dN.config({channel:YM,updateState:function(e,t){return Q.some({isTabPanel:function(){return"tabpanel"===t.body.type}})},renderComponents:function(e){return"tabpanel"===e.body.type?[jM(e.body,n)]:[VM(e.body,n)]},initialData:e})])}},JM=ly.deviceType.isTouch(),eD=function(e,t){return{dom:{tag:"div",styles:{display:"none"},classes:["tox-dialog__header"]},components:[e,t]}},tD=function(e,t){return tQ.parts.close(yg.sketch({dom:{tag:"button",classes:["tox-button","tox-button--icon","tox-button--naked"],attributes:{type:"button","aria-label":t.translate("Close")}},action:e,buttonBehaviours:Os([nO.config({})])}))},nD=function(){return tQ.parts.title({dom:{tag:"div",classes:["tox-dialog__title"],innerHtml:"",styles:{display:"none"}}})},rD=function(e,t){return tQ.parts.body({dom:{tag:"div",classes:["tox-dialog__body"]},components:[{dom:{tag:"div",classes:["tox-dialog__body-content"]},components:[{dom:QB("

"+t.translate(e)+"

")}]}]})},oD=function(e){return tQ.parts.footer({dom:{tag:"div",classes:["tox-dialog__footer"]},components:e})},iD=function(e,t){return[Yb.sketch({dom:{tag:"div",classes:["tox-dialog__footer-start"]},components:e}),Yb.sketch({dom:{tag:"div",classes:["tox-dialog__footer-end"]},components:t})]},aD=function(e){var t,n="tox-dialog",r=n+"-wrap",o=r+"__backdrop",i=n+"__disable-scroll";return tQ.sketch({lazySink:e.lazySink,onEscape:function(t){return e.onEscape(t),Q.some(!0)},useTabstopAt:function(e){return!R_(e)},dom:{tag:"div",classes:[n].concat(e.extraClasses),styles:k({position:"relative"},e.extraStyles)},components:V([e.header,e.body],e.footer.toArray(),!0),parts:{blocker:{dom:QB('
'),components:[{dom:{tag:"div",classes:JM?[o,o+"--opaque"]:[o]}}]}},dragBlockClass:r,modalBehaviours:Os(V([mm.config({}),um("dialog-events",e.dialogEvents.concat([ji(jo(),(function(e,t){rm.focusIn(e)}))])),um("scroll-lock",[qi((function(){za(Lt(),i)})),Xi((function(){Ia(Lt(),i)}))])],e.extraBehaviours,!0)),eventOrder:k((t={},t[ci()]=["dialog-events"],t[bi()]=["scroll-lock","dialog-events","alloy.base.behaviour"],t[Oi()]=["alloy.base.behaviour","dialog-events","scroll-lock"],t),e.eventOrder)})},lD=function(e){return yg.sketch({dom:{tag:"button",classes:["tox-button","tox-button--icon","tox-button--naked"],attributes:{type:"button","aria-label":e.translate("Close"),title:e.translate("Close")}},components:[Tg("close",{tag:"div",classes:["tox-icon"]},e.icons)],action:function(e){Ti(e,uO)}})},sD=function(e,t,n){var r=function(e){return[Ka(n.translate(e.title))]};return{dom:{tag:"div",classes:["tox-dialog__title"],attributes:k({},t.map((function(e){return{id:e}})).getOr({}))},components:r(e),behaviours:Os([dN.config({channel:XM,renderComponents:r})])}},cD=function(){return{dom:QB('
')}},uD=function(e,t){return function(e,t){var n=tQ.parts.title(sD(e,Q.none(),t)),r=tQ.parts.draghandle(cD()),o=tQ.parts.close(lD(t)),i=[n].concat(e.draggable?[r]:[]).concat([o]);return Yb.sketch({dom:QB('
'),components:i})}({title:t.shared.providers.translate(e),draggable:t.dialog.isDraggableModal()},t.shared.providers)},dD=function(e,t,n){return{dom:{tag:"div",classes:["tox-dialog__busy-spinner"],attributes:{"aria-label":n.translate(e)},styles:{left:"0px",right:"0px",bottom:"0px",top:"0px",position:"absolute"}},behaviours:t,components:[{dom:QB('
')}]}},fD=function(e,t,n){return{onClose:function(){return n.closeWindow()},onBlock:function(n){tQ.setBusy(e(),(function(e,r){return dD(n.message,r,t)}))},onUnblock:function(){tQ.setIdle(e())}}},hD=function(e,t,n,r){var o;return tl(aD(k(k({},e),{lazySink:r.shared.getSink,extraBehaviours:V([dN.config({channel:qM,updateState:function(e,t){return Q.some(t)},initialData:t}),N_({})],e.extraBehaviours,!0),onEscape:function(e){Ti(e,uO)},dialogEvents:n,eventOrder:(o={},o[si()]=[dN.name(),Ss.name()],o[bi()]=["scroll-lock",dN.name(),"messages","dialog-events","alloy.base.behaviour"],o[Oi()]=["alloy.base.behaviour","dialog-events","messages",dN.name(),"scroll-lock"],o)})))},pD=function(e){return U(e,(function(e){return"menu"===e.type?function(e){var t=U(e.items,(function(e){var t=wo(!1);return k(k({},e),{storage:t})}));return k(k({},e),{items:t})}(e):e}))},mD=function(e){return X(e,(function(e,t){return"menu"===t.type?X(t.items,(function(e,t){return e[t.name]=t.storage,e}),e):e}),{})},gD=function(e,t){return[Ui(jo(),z_),e(cO,(function(e,n){t.onClose(),n.onClose()})),e(uO,(function(e,t,n,r){t.onCancel(e),Ti(r,cO)})),Ri(pO,(function(e,n){return t.onUnblock()})),Ri(hO,(function(e,n){return t.onBlock(n.event)}))]},vD=function(e,t){var n=function(t,n){return Ri(t,(function(t,o){r(t,(function(r,i){n(e(),r,o.event,t)}))}))},r=function(e,t){dN.getState(e).get().each((function(n){t(n,e)}))};return V(V([],gD(n,t),!0),[n(dO,(function(e,t,n){t.onAction(e,{name:n.name})}))],!1)},AD=function(e,t,n){var r=function(t,n){return Ri(t,(function(t,r){o(t,(function(o,i){n(e(),o,r.event,t)}))}))},o=function(e,t){dN.getState(e).get().each((function(n){t(n.internalDialog,e)}))};return V(V([],gD(r,t),!0),[r(fO,(function(e,t){return t.onSubmit(e)})),r(sO,(function(e,t,n){t.onChange(e,{name:n.name})})),r(dO,(function(e,t,r,o){var i=function(){return rm.focusIn(o)},a=function(e){return Xt(e,"disabled")||qt(e,"aria-disabled").exists((function(e){return"true"===e}))},l=Mt(o.element),s=Es(l);t.onAction(e,{name:r.name,value:r.value}),Es(l).fold(i,(function(e){a(e)||s.exists((function(t){return Ot(e,t)&&a(t)}))?i():n().toOptional().filter((function(t){return!Ot(t.element,e)})).each(i)}))})),r(mO,(function(e,t,n){t.onTabChange(e,{newTabName:n.name,oldTabName:n.oldName})})),Xi((function(t){var n=e();Sd.setValue(t,n.getData())}))],!1)},yD=function(e,t){var n=t.map((function(e){return e.footerButtons})).getOr([]),r=W(n,(function(e){return"start"===e.align})),o=function(e,t){return Yb.sketch({dom:{tag:"div",classes:["tox-dialog__footer-"+e]},components:U(t,(function(e){return e.memento.asSpec()}))})};return[o("start",r.pass),o("end",r.fail)]},bD=function(e,t){return{dom:QB(''),components:[],behaviours:Os([dN.config({channel:GM,initialData:e,updateState:function(e,n){var r=U(n.buttons,(function(e){var n=bg(function(e,t){return JC(e,e.type,t)}(e,t));return{name:e.name,align:e.align,memento:n}}));return Q.some({lookupByName:function(e,t){return function(e,t,n){return Y(t,(function(e){return e.name===n})).bind((function(t){return t.memento.getOpt(e)}))}(e,r,t)},footerButtons:r})},renderComponents:yD})])}},OD=function(e,t){return tQ.parts.footer(bD(e,t))},wD=function(e,t){if(e.getRoot().getSystem().isConnected()){var n=$f.getCurrent(e.getFormWrapper()).getOr(e.getFormWrapper());return u_.getField(n,t).fold((function(){var r=e.getFooter();return dN.getState(r).get().bind((function(e){return e.lookupByName(n,t)}))}),(function(e){return Q.some(e)}))}return Q.none()},xD=function(e,t,n){var r=function(t){var n=e.getRoot();n.getSystem().isConnected()&&t(n)},i={getData:function(){var t=e.getRoot(),r=t.getSystem().isConnected()?e.getFormWrapper():t,o=Sd.getValue(r),i=he(n,(function(e){return e.get()}));return k(k({},o),i)},setData:function(t){r((function(r){var o=i.getData(),a=k(k({},o),t),l=function(e,t){var n=e.getRoot();return dN.getState(n).get().map((function(e){return Ur(Fr("data",e.dataValidator,t))})).getOr(t)}(e,a),s=e.getFormWrapper();Sd.setValue(s,l),fe(n,(function(e,t){be(a,t)&&e.set(a[t])}))}))},disable:function(t){wD(e,t).each(Zf.disable)},enable:function(t){wD(e,t).each(Zf.enable)},focus:function(t){wD(e,t).each(mm.focus)},block:function(e){if(!o(e))throw new Error("The dialogInstanceAPI.block function should be passed a blocking message of type string as an argument");r((function(t){Ni(t,hO,{message:e})}))},unblock:function(){r((function(e){Ti(e,pO)}))},showTab:function(t){r((function(n){var r=e.getBody();dN.getState(r).get().exists((function(e){return e.isTabPanel()}))&&$f.getCurrent(r).each((function(e){RM.showTab(e,t)}))}))},redial:function(e){r((function(n){var r=t(e);n.getSystem().broadcastOn([qM],r),n.getSystem().broadcastOn([XM],r.internalDialog),n.getSystem().broadcastOn([YM],r.internalDialog),n.getSystem().broadcastOn([GM],r.internalDialog),i.setData(r.initialData)}))},close:function(){r((function(e){Ti(e,cO)}))}};return i},_D=function(e,t,n){var r=uD(e.internalDialog.title,n),o=function(e,t){var n=KM(e,Q.none(),t,!1);return tQ.parts.body(n)}({body:e.internalDialog.body},n),i=pD(e.internalDialog.buttons),a=mD(i),l=OD({buttons:i},n),s=AD((function(){return h}),fD((function(){return d}),n.shared.providers,t),n.shared.getSink),c=function(e){switch(e){case"large":return["tox-dialog--width-lg"];case"medium":return["tox-dialog--width-md"];default:return[]}}(e.internalDialog.size),u={header:r,body:o,footer:Q.some(l),extraClasses:c,extraBehaviours:[],extraStyles:{}},d=hD(u,e,s,n),f={getRoot:v(d),getBody:function(){return tQ.getBody(d)},getFooter:function(){return tQ.getFooter(d)},getFormWrapper:function(){var e=tQ.getBody(d);return $f.getCurrent(e).getOr(e)}},h=xD(f,t.redial,a);return{dialog:d,instanceApi:h}},CD=function(e,t,n,r){var o,i,a,l,s,c=ia("dialog-label"),u=ia("dialog-content"),d=bg((a={title:e.internalDialog.title,draggable:!0},l=c,s=n.shared.providers,Yb.sketch({dom:QB('
'),components:[sD(a,Q.some(l),s),cD(),lD(s)],containerBehaviours:Os([IP.config({mode:"mouse",blockerClass:"blocker",getTarget:function(e){return dl(e,'[role="dialog"]').getOrDie()},snaps:{getSnapPoints:function(){return[]},leftAttr:"data-drag-left",topAttr:"data-drag-top"}})])}))),f=bg(function(e,t,n,r){return KM(e,Q.some(t),n,r)}({body:e.internalDialog.body},u,n,r)),h=pD(e.internalDialog.buttons),p=mD(h),m=bg(function(e,t){return bD(e,t)}({buttons:h},n)),g=AD((function(){return y}),{onBlock:function(e){PB.block(A,(function(t,r){return dD(e.message,r,n.shared.providers)}))},onUnblock:function(){PB.unblock(A)},onClose:function(){return t.closeWindow()}},n.shared.getSink),A=tl({dom:{tag:"div",classes:["tox-dialog","tox-dialog-inline"],attributes:(o={role:"dialog"},o["aria-labelledby"]=c,o["aria-describedby"]=u,o)},eventOrder:(i={},i[si()]=[dN.name(),Ss.name()],i[ci()]=["execute-on-form"],i[bi()]=["reflecting","execute-on-form"],i),behaviours:Os([rm.config({mode:"cyclic",onEscape:function(e){return Ti(e,cO),Q.some(!0)},useTabstopAt:function(e){return!R_(e)&&("button"!==De(e)||"disabled"!==jt(e,"disabled"))}}),dN.config({channel:qM,updateState:function(e,t){return Q.some(t)},initialData:e}),mm.config({}),um("execute-on-form",g.concat([ji(jo(),(function(e,t){rm.focusIn(e)}))])),PB.config({getRoot:function(){return Q.some(A)}}),cm.config({}),N_({})]),components:[d.asSpec(),f.asSpec(),m.asSpec()]}),y=xD({getRoot:v(A),getFooter:function(){return m.get(A)},getBody:function(){return f.get(A)},getFormWrapper:function(){var e=f.get(A);return $f.getCurrent(e).getOr(e)}},t.redial,p);return{dialog:A,instanceApi:y}},kD=tinymce.util.Tools.resolve("tinymce.util.URI"),SD=["insertContent","setContent","execCommand","close","block","unblock"],VD=function(e){return i(e)&&-1!==SD.indexOf(e.mceAction)},BD=function(e,t,n,r){var a,l,c,u=uD(e.title,r),d=function(e){var t={dom:{tag:"div",classes:["tox-dialog__content-js"]},components:[{dom:{tag:"div",classes:["tox-dialog__body-iframe"]},components:[D_({dom:{tag:"iframe",attributes:{src:e.url}},behaviours:Os([nO.config({}),mm.config({})])})]}],behaviours:Os([rm.config({mode:"acyclic",useTabstopAt:O(R_)})])};return tQ.parts.body(t)}(e),f=e.buttons.bind((function(e){return 0===e.length?Q.none():Q.some(OD({buttons:e},r))})),h=vD((function(){return w}),fD((function(){return b}),r.shared.providers,t)),p=k(k({},e.height.fold((function(){return{}}),(function(e){return{height:e+"px","max-height":e+"px"}}))),e.width.fold((function(){return{}}),(function(e){return{width:e+"px","max-width":e+"px"}}))),m=e.width.isNone()&&e.height.isNone()?["tox-dialog--width-lg"]:[],g=new kD(e.url,{base_uri:new kD(window.location.href)}),v=g.protocol+"://"+g.host+(g.port?":"+g.port:""),A=Js(),y=[um("messages",[qi((function(){var t=nc(Qe.fromDom(window),"message",(function(t){if(g.isSameOrigin(new kD(t.raw.origin))){var r=t.raw.data;VD(r)?function(e,t,n){switch(n.mceAction){case"insertContent":e.insertContent(n.content);break;case"setContent":e.setContent(n.content);break;case"execCommand":var r=!!s(n.ui)&&n.ui;e.execCommand(n.cmd,r,n.value);break;case"close":t.close();break;case"block":t.block(n.message);break;case"unblock":t.unblock()}}(n,w,r):function(e){return!VD(e)&&i(e)&&be(e,"mceAction")}(r)&&e.onMessage(w,r)}}));A.set(t)})),Xi(A.clear)]),Ss.config({channels:(a={},a[ZM]={onReceive:function(e,t){ul(e.element,"iframe").each((function(e){e.dom.contentWindow.postMessage(t,v)}))}},a)})],b=hD({header:u,body:d,footer:f,extraClasses:m,extraBehaviours:y,extraStyles:p},e,h,r),w=(l=b,c=function(e){l.getSystem().isConnected()&&e(l)},{block:function(e){if(!o(e))throw new Error("The urlDialogInstanceAPI.block function should be passed a blocking message of type string as an argument");c((function(t){Ni(t,hO,{message:e})}))},unblock:function(){c((function(e){Ti(e,pO)}))},close:function(){c((function(e){Ti(e,cO)}))},sendMessage:function(e){c((function(t){t.getSystem().broadcastOn([ZM],e)}))}});return{dialog:b,instanceApi:w}},TD=function(e,t,n){return t&&n?[]:[RV.config({contextual:{lazyContext:function(){return Q.some(In(Qe.fromDom(e.getContentAreaContainer())))},fadeInClass:"tox-dialog-dock-fadein",fadeOutClass:"tox-dialog-dock-fadeout",transitionClass:"tox-dialog-dock-transition"},modes:["top"]})]},ND=function(e){var t=e.backstage,n=e.editor,r=RA(n),o=function(e){var t=e.backstage.shared;return{open:function(n,r){var o=function(){tQ.hide(s),r()},i=bg(JC({name:"close-alert",text:"OK",primary:!0,align:"end",disabled:!1,icon:Q.none()},"cancel",e.backstage)),a=nD(),l=tD(o,t.providers),s=tl(aD({lazySink:function(){return t.getSink()},header:eD(a,l),body:rD(n,t.providers),footer:Q.some(oD(iD([],[i.asSpec()]))),onEscape:o,extraClasses:["tox-alert-dialog"],extraBehaviours:[],extraStyles:{},dialogEvents:[Ri(uO,o)],eventOrder:{}}));tQ.show(s);var c=i.get(s);mm.focus(c)}}}(e),i=function(e){var t=e.backstage.shared;return{open:function(n,r){var o=function(e){tQ.hide(c),r(e)},i=bg(JC({name:"yes",text:"Yes",primary:!0,align:"end",disabled:!1,icon:Q.none()},"submit",e.backstage)),a=JC({name:"no",text:"No",primary:!1,align:"end",disabled:!1,icon:Q.none()},"cancel",e.backstage),l=nD(),s=tD((function(){return o(!1)}),t.providers),c=tl(aD({lazySink:function(){return t.getSink()},header:eD(l,s),body:rD(n,t.providers),footer:Q.some(oD(iD([],[a,i.asSpec()]))),onEscape:function(){return o(!1)},extraClasses:["tox-confirm-dialog"],extraBehaviours:[],extraStyles:{},dialogEvents:[Ri(uO,(function(){return o(!1)})),Ri(fO,(function(){return o(!0)}))],eventOrder:{}}));tQ.show(c);var u=i.get(c);mm.focus(u)}}}(e),a=function(e,r){return kM.openUrl((function(e){var o=BD(e,{closeWindow:function(){tQ.hide(o.dialog),r(o.instanceApi)}},n,t);return tQ.show(o.dialog),o.instanceApi}),e)},l=function(e,n){return kM.open((function(e,r,o){var i=r,a=_D({dataValidator:o,initialData:i,internalDialog:e},{redial:kM.redial,closeWindow:function(){tQ.hide(a.dialog),n(a.instanceApi)}},t);return tQ.show(a.dialog),a.instanceApi.setData(i),a.instanceApi}),e)},s=function(e,o,i,a){return kM.open((function(e,l,s){var c=Ur(Fr("data",s,l)),u=ec(),d=t.shared.header.isPositionedAtTop(),f=function(){return u.on((function(e){Km.reposition(e),RV.refresh(e)}))},h=CD({dataValidator:s,initialData:c,internalDialog:e},{redial:kM.redial,closeWindow:function(){u.on(Km.hide),n.off("ResizeEditor",f),u.clear(),i(h.instanceApi)}},t,a),p=tl(Km.sketch(k(k({lazySink:t.shared.getSink,dom:{tag:"div",classes:[]},fireDismissalEventInstead:{}},d?{}:{fireRepositionEventInstead:{}}),{inlineBehaviours:Os(V([um("window-manager-inline-events",[Ri(wi(),(function(e,t){Ti(h.dialog,uO)}))])],TD(n,r,d),!0)),isExtraPart:function(e,t){return function(e){return Mb(e,".tox-alert-dialog")||Mb(e,".tox-confirm-dialog")}(t)}})));return u.set(p),Km.showWithin(p,nl(h.dialog),{anchor:o},Q.some(Lt())),r&&d||(RV.refresh(p),n.on("ResizeEditor",f)),h.instanceApi.setData(c),rm.focusIn(h.dialog),h.instanceApi}),e)};return{open:function(e,n,r){return void 0!==n&&"toolbar"===n.inline?s(e,t.shared.anchors.inlineDialog(),r,n.ariaAttrs):void 0!==n&&"cursor"===n.inline?s(e,t.shared.anchors.cursor(),r,n.ariaAttrs):l(e,r)},openUrl:function(e,t){return a(e,t)},alert:function(e,t){o.open(e,(function(){t()}))},close:function(e){e.close()},confirm:function(e,t){i.open(e,(function(e){t(e)}))}}};C.add("silver",(function(e){var t=ZP(e),n=t.uiMothership,r=t.backstage,o=t.renderUI,i=t.getUi;Qb(e,r.shared);var a=ND({editor:e,backstage:r});return{renderUI:o,getWindowManagerImpl:v(a),getNotificationManagerImpl:function(){return Pg(e,{backstage:r},n)},ui:i()}}))}(); +/***/}, +/***/5070: +/***/function(e,t,n){"use strict"; +// EXPORTS +n.d(t,{MW:function(){/* binding */return S},Ay:function(){/* binding */return T}}); +// UNUSED EXPORTS: DEFAULT_PATH_ANIMATION_PROPS +// EXTERNAL MODULE: ./node_modules/tslib/tslib.es6.js +var r=n(15215),o=n(71519),i=n(68717),a=n(57043),l=n(89259); +// EXTERNAL MODULE: ./node_modules/zrender/lib/graphic/Displayable.js +// ./node_modules/zrender/lib/contain/cubic.js +function s(e,t,n,r,o,i,a,s,c,u,d){if(0===c)return!1;var f=c;return!(d>t+f&&d>r+f&&d>i+f&&d>s+f||de+f&&u>n+f&&u>o+f&&u>a+f||un||f+co&&(o+=d);var p=Math.atan2(s,l);return p<0&&(p+=d),p>=r&&p<=o||p+d>=r&&p+d<=o} +// EXTERNAL MODULE: ./node_modules/zrender/lib/contain/windingLine.js +var h=n(76873),p=i/* default */.A.CMD,m=2*Math.PI;var g=[-1,-1,-1],v=[-1,-1];function A(e,t,n,r,o,i,a,s,c,u){if(u>t&&u>r&&u>i&&u>s||u1&&(d=void 0,d=v[0],v[0]=v[1],v[1]=d),m=l/* cubicAt */.Yb(t,r,i,s,v[0]),p>1&&(A=l/* cubicAt */.Yb(t,r,i,s,v[1]))),2===p?bt&&s>r&&s>i||s=0&&u<=1){for(var d=0,f=l/* quadraticAt */.k3(t,r,i,u),h=0;hn||l<-n)return 0;var s=Math.sqrt(n*n-l*l);g[0]=-s,g[1]=s;var c=Math.abs(r-o);if(c<1e-4)return 0;if(c>=m-1e-4){r=0,o=m;var u=i?1:-1;return a>=g[0]+e&&a<=g[1]+e?u:0}if(r>o){var d=r;r=o,o=d}r<0&&(r+=m,o+=m);for(var f=0,h=0;h<2;h++){var p=g[h];if(p+e>a){var v=Math.atan2(l,p);u=i?1:-1;v<0&&(v=m+v),(v>=r&&v<=o||v+m>=r&&v+m<=o)&&(v>Math.PI/2&&v<1.5*Math.PI&&(u=-u),f+=u)}}return f}function O(e,t,n,r,o){for(var i,l,u,d,m=e.data,g=e.len(),v=0,O=0,w=0,x=0,_=0,C=0;C1&&(n||(v+=(0,h/* default */.A)(O,w,x,_,r,o))),S&&(x=O=m[C],_=w=m[C+1]),k){case p.M:O=x=m[C++],w=_=m[C++];break;case p.L:if(n){if(a/* containStroke */.l(O,w,m[C],m[C+1],t,r,o))return!0}else v+=(0,h/* default */.A)(O,w,m[C],m[C+1],r,o)||0;O=m[C++],w=m[C++];break;case p.C:if(n){if(s(O,w,m[C++],m[C++],m[C++],m[C++],m[C],m[C+1],t,r,o))return!0}else v+=A(O,w,m[C++],m[C++],m[C++],m[C++],m[C],m[C+1],r,o)||0;O=m[C++],w=m[C++];break;case p.Q:if(n){if(c/* containStroke */.l(O,w,m[C++],m[C++],m[C],m[C+1],t,r,o))return!0}else v+=y(O,w,m[C++],m[C++],m[C],m[C+1],r,o)||0;O=m[C++],w=m[C++];break;case p.A:var V=m[C++],B=m[C++],T=m[C++],N=m[C++],E=m[C++],P=m[C++];C+=1;var Q=!!(1-m[C++]);i=Math.cos(E)*T+V,l=Math.sin(E)*N+B,S?(x=i,_=l):v+=(0,h/* default */.A)(O,w,i,l,r,o);var M=(r-V)*N/T+V;if(n){if(f(V,B,N,E,E+P,Q,t,M,o))return!0}else v+=b(V,B,N,E,E+P,Q,M,o);O=Math.cos(E+P)*T+V,w=Math.sin(E+P)*N+B;break;case p.R:if(x=O=m[C++],_=w=m[C++],i=x+m[C++],l=_+m[C++],n){if(a/* containStroke */.l(x,_,i,_,t,r,o)||a/* containStroke */.l(i,_,i,l,t,r,o)||a/* containStroke */.l(i,l,x,l,t,r,o)||a/* containStroke */.l(x,l,x,_,t,r,o))return!0}else v+=(0,h/* default */.A)(i,_,i,l,r,o),v+=(0,h/* default */.A)(x,l,x,_,r,o);break;case p.Z:if(n){if(a/* containStroke */.l(O,w,x,_,t,r,o))return!0}else v+=(0,h/* default */.A)(O,w,x,_,r,o);O=x,w=_}}return n||(u=w,d=_,Math.abs(u-d)<1e-4)||(v+=(0,h/* default */.A)(O,w,x,_,r,o)||0),0!==v} +// EXTERNAL MODULE: ./node_modules/zrender/lib/core/util.js +var w=n(98026),x=n(47698),_=n(73098),C=n(56448),k=n(92836),S=(0,w.defaults)({fill:"#000",stroke:null,strokePercent:1,fillOpacity:1,strokeOpacity:1,lineDashOffset:0,lineWidth:1,lineCap:"butt",miterLimit:10,strokeNoScale:!1,strokeFirst:!1},o/* DEFAULT_COMMON_STYLE */.oN),V={style:(0,w.defaults)({fill:!0,stroke:!0,strokePercent:!0,fillOpacity:!0,strokeOpacity:!0,lineDashOffset:!0,lineWidth:!0,miterLimit:!0},o/* DEFAULT_COMMON_ANIMATION_PROPS */.sW.style)},B=k/* TRANSFORMABLE_PROPS */.Wx.concat(["invisible","culling","z","z2","zlevel","parent"]),T=function(e){function t(t){return e.call(this,t)||this}var n;return(0,r/* __extends */.C6)(t,e),t.prototype.update=function(){var n=this;e.prototype.update.call(this);var r=this.style;if(r.decal){var o=this._decalEl=this._decalEl||new t;o.buildPath===t.prototype.buildPath&&(o.buildPath=function(e){n.buildPath(e,n.shape)}),o.silent=!0;var i=o.style;for(var a in r)i[a]!==r[a]&&(i[a]=r[a]);i.fill=r.fill?r.decal:null,i.decal=null,i.shadowColor=null,r.strokeFirst&&(i.stroke=null);for(var l=0;l.5?_/* DARK_LABEL_COLOR */._S:t>.2?_/* LIGHTER_LABEL_COLOR */.tY:_/* LIGHT_LABEL_COLOR */.el}if(e)return _/* LIGHT_LABEL_COLOR */.el}return _/* DARK_LABEL_COLOR */._S},t.prototype.getInsideTextStroke=function(e){var t=this.style.fill;if((0,w.isString)(t)){var n=this.__zr;if(!(!n||!n.isDarkMode())===(0,x.lum)(e,0)<_/* DARK_MODE_THRESHOLD */.ps)return t}},t.prototype.buildPath=function(e,t,n){},t.prototype.pathUpdated=function(){this.__dirty&=~C/* SHAPE_CHANGED_BIT */.Dl},t.prototype.getUpdatedPathProxy=function(e){return!this.path&&this.createPathProxy(),this.path.beginPath(),this.buildPath(this.path,this.shape,e),this.path},t.prototype.createPathProxy=function(){this.path=new i/* default */.A(!1)},t.prototype.hasStroke=function(){var e=this.style,t=e.stroke;return!(null==t||"none"===t||!(e.lineWidth>0))},t.prototype.hasFill=function(){var e=this.style.fill;return null!=e&&"none"!==e},t.prototype.getBoundingRect=function(){var e=this._rect,t=this.style,n=!e;if(n){var r=!1;this.path||(r=!0,this.createPathProxy());var o=this.path;(r||this.__dirty&C/* SHAPE_CHANGED_BIT */.Dl)&&(o.beginPath(),this.buildPath(o,this.shape,!1),this.pathUpdated()),e=o.getBoundingRect()}if(this._rect=e,this.hasStroke()&&this.path&&this.path.len()>0){var i=this._rectStroke||(this._rectStroke=e.clone());if(this.__dirty||n){i.copy(e);var a=t.strokeNoScale?this.getLineScale():1,l=t.lineWidth;if(!this.hasFill()){var s=this.strokeContainThreshold;l=Math.max(l,null==s?4:s)}a>1e-10&&(i.width+=l/a,i.height+=l/a,i.x-=l/a/2,i.y-=l/a/2)}return i}return e},t.prototype.contain=function(e,t){var n=this.transformCoordToLocal(e,t),r=this.getBoundingRect(),o=this.style;if(e=n[0],t=n[1],r.contain(e,t)){var i=this.path;if(this.hasStroke()){var a=o.lineWidth,l=o.strokeNoScale?this.getLineScale():1;if(l>1e-10&&(this.hasFill()||(a=Math.max(a,this.strokeContainThreshold)),function(e,t,n,r){return O(e,t,!0,n,r)}(i,a/l,e,t)))return!0}if(this.hasFill())return function(e,t,n){return O(e,0,!1,t,n)}(i,e,t)}return!1},t.prototype.dirtyShape=function(){this.__dirty|=C/* SHAPE_CHANGED_BIT */.Dl,this._rect&&(this._rect=null),this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},t.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},t.prototype.animateShape=function(e){return this.animate("shape",e)},t.prototype.updateDuringAnimation=function(e){"style"===e?this.dirtyStyle():"shape"===e?this.dirtyShape():this.markRedraw()},t.prototype.attrKV=function(t,n){"shape"===t?this.setShape(n):e.prototype.attrKV.call(this,t,n)},t.prototype.setShape=function(e,t){var n=this.shape;return n||(n=this.shape={}),"string"==typeof e?n[e]=t:(0,w.extend)(n,e),this.dirtyShape(),this},t.prototype.shapeChanged=function(){return!!(this.__dirty&C/* SHAPE_CHANGED_BIT */.Dl)},t.prototype.createStyle=function(e){return(0,w.createObject)(S,e)},t.prototype._innerSaveToNormal=function(t){e.prototype._innerSaveToNormal.call(this,t);var n=this._normalState;t.shape&&!n.shape&&(n.shape=(0,w.extend)({},this.shape))},t.prototype._applyStateObj=function(t,n,r,o,i,a){e.prototype._applyStateObj.call(this,t,n,r,o,i,a);var l,s=!(n&&o);if(n&&n.shape?i?o?l=n.shape:(l=(0,w.extend)({},r.shape),(0,w.extend)(l,n.shape)):(l=(0,w.extend)({},o?this.shape:r.shape),(0,w.extend)(l,n.shape)):s&&(l=r.shape),l)if(i){this.shape=(0,w.extend)({},this.shape);for(var c={},u=(0,w.keys)(l),d=0;d'}); +/* harmony import */a().add(l); +/* harmony default export */t.default=l}, +/***/5202: +/***/function(e,t,n){"use strict"; +// EXPORTS +n.d(t,{A:function(){/* binding */return v}}); +// EXTERNAL MODULE: ./node_modules/zrender/lib/core/env.js +var r=n(38123),o=n(30693),i=(0,n(32944).A)([["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]]),a=/** @class */function(){function e(){}return e.prototype.getAreaStyle=function(e,t){return i(this,e,t)},e}(),l=n(89632),s=n(32322),c=["textStyle","color"],u=["fontStyle","fontWeight","fontSize","fontFamily","padding","lineHeight","rich","width","height","overflow"],d=new s/* default */.Ay,f=/** @class */function(){function e(){} +/** + * Get color property or get color from option.textStyle.color + */ +// TODO Callback +return e.prototype.getTextColor=function(e){var t=this.ecModel;return this.getShallow("color")||(!e&&t?t.get(c):null)}, +/** + * Create font string from fontStyle, fontWeight, fontSize, fontFamily + * @return {string} + */ +e.prototype.getFont=function(){return(0,l/* getFont */.c8)({fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily")},this.ecModel)},e.prototype.getTextRect=function(e){for(var t={text:e,verticalAlign:this.getShallow("verticalAlign")||this.getShallow("baseline")},n=0;n` +// getModel(path: string | string[], parentModel?: Model): Model; +// TODO 'a.b.c' is deprecated +e.prototype.getModel=function(t,n){var r=null!=t,o=r?this.parsePath(t):null;return new e(r?this._doGet(o):this.option,n=n||this.parentModel&&this.parentModel.getModel(this.resolveParentPath(o)),this.ecModel)}, +/** + * If model has option + */ +e.prototype.isEmpty=function(){return null==this.option},e.prototype.restoreData=function(){}, +// Pending +e.prototype.clone=function(){return new(0,this.constructor)((0,m.clone)(this.option))}, +// setReadOnly(properties): void { +// clazzUtil.setReadOnly(this, properties); +// } +// If path is null/undefined, return null/undefined. +e.prototype.parsePath=function(e){return"string"==typeof e?e.split("."):e}, +// Resolve path for parent. Perhaps useful when parent use a different property. +// Default to be a identity resolver. +// Can be modified to a different resolver. +e.prototype.resolveParentPath=function(e){return e}, +// FIXME:TS check whether put this method here +e.prototype.isAnimationEnabled=function(){if(!r/* default */.A.node&&this.option){if(null!=this.option.animation)return!!this.option.animation;if(this.parentModel)return this.parentModel.isAnimationEnabled()}},e.prototype._doGet=function(e,t){var n=this.option;if(!e)return n;for(var r=0;r true + * + * _.isLength(Number.MIN_VALUE); + * // => false + * + * _.isLength(Infinity); + * // => false + * + * _.isLength('3'); + * // => false + */ +function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991}}, +/***/5316: +/***/function(e,t,n){"use strict"; +// ESM COMPAT FLAG +n.r(t), +// EXPORTS +n.d(t,{default:function(){/* binding */return a}}); +// EXTERNAL MODULE: ./node_modules/vue/dist/vue.esm-bundler.js + 5 modules +var r=n(61431),o=n(90517); +// EXTERNAL MODULE: ./src/store/lyFormBuilder.js +// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/lyform-builder/lyform-design/lyfield-widget/statistic-widget-ly.vue?vue&type=script&setup=true&lang=js +const i={style:{display:"inline-flex","align-items":"center"}}; +/* harmony default export */ +/* harmony default export */var a={__name:"statistic-widget-ly",props:{field:Object,parentWidget:Object,parentList:Array,indexOfParentList:Number,designState:{type:Boolean,default:!1}},setup(e){const t=e,n=((0,o/* useBuilderStore */.k)(),(0,r.ref)(null));let a=(0,r.ref)([]);(0,r.computed)((()=>t.field.options.size||"default"));return(0,r.watch)((()=>t.field.options.defaultValue),((e,t)=>{n.value=e})),(0,r.onMounted)((()=>{t.field.formItemFlag&&(n.value=t.field.options.defaultValue)})),(t,n)=>{const o=(0,r.resolveComponent)("el-statistic"),l=(0,r.resolveComponent)("static-content-wrapper-ly");return(0,r.openBlock)(),(0,r.createBlock)(l,{field:e.field,rules:(0,r.unref)(a),"design-state":e.designState,"parent-widget":e.parentWidget,"parent-list":e.parentList,"index-of-parent-list":e.indexOfParentList},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(o,{ref:"lyfieldEditor",value:e.field.options.value,"decimal-separator":e.field.options.decimalSeparator,"group-separator":e.field.options.groupSeparator,precision:e.field.options.precision},(0,r.createSlots)({title:(0,r.withCtx)((()=>[(0,r.createElementVNode)("div",i,(0,r.toDisplayString)(e.field.options.title),1)])),_:2},[e.field.options.prefix?{name:"prefix",fn:(0,r.withCtx)((()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.field.options.prefix),1)])),key:"0"}:void 0,e.field.options.suffix?{name:"suffix",fn:(0,r.withCtx)((()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.field.options.suffix),1)])),key:"1"}:void 0]),1032,["value","decimal-separator","group-separator","precision"])])),_:1},8,["field","rules","design-state","parent-widget","parent-list","index-of-parent-list"])}}}; +/***/}, +/***/5638: +/***/function(e,t,n){"use strict"; +/* harmony export */n.d(t,{ +/* harmony export */Jw:function(){/* binding */return i}, +/* harmony export */LR:function(){/* binding */return c}, +/* harmony export */LW:function(){/* binding */return s}, +/* harmony export */Nz:function(){/* binding */return u}, +/* harmony export */Xr:function(){/* binding */return p}, +/* harmony export */ap:function(){/* binding */return h}, +/* harmony export */oi:function(){/* binding */return l}, +/* harmony export */t5:function(){/* binding */return f} +/* harmony export */}); +/* unused harmony export transitionStore */ +/* harmony import */var r=n(98026),o=(0,n(48170).$r)(); +/* harmony import */ +/** + * Return null if animation is disabled. + */ +function i(e,t,n, +// Extra opts can override the option in animatable model. +o, +// TODO It's only for pictorial bar now. +i){var a; +// Check if there is global animation configuration from dataZoom/resize can override the config in option. +// If animation is enabled. Will use this animation config in payload. +// If animation is disabled. Just ignore it. +if(t&&t.ecModel){var l=t.ecModel.getUpdatePayload();a=l&&l.animation}var s="update"===e;if(t&&t.isAnimationEnabled()){var c=void 0,u=void 0,d=void 0;return o?(c=(0,r.retrieve2)(o.duration,200),u=(0,r.retrieve2)(o.easing,"cubicOut"),d=0):(c=t.getShallow(s?"animationDurationUpdate":"animationDuration"),u=t.getShallow(s?"animationEasingUpdate":"animationEasing"),d=t.getShallow(s?"animationDelayUpdate":"animationDelay")), +// animation from payload has highest priority. +a&&(null!=a.duration&&(c=a.duration),null!=a.easing&&(u=a.easing),null!=a.delay&&(d=a.delay)),(0,r.isFunction)(d)&&(d=d(n,i)),(0,r.isFunction)(c)&&(c=c(n)),{duration:c||0,delay:d,easing:u}}return null}function a(e,t,n,o,a,l,s){var c,u=!1;(0,r.isFunction)(a)?(s=l,l=a,a=null):(0,r.isObject)(a)&&(l=a.cb,s=a.during,u=a.isFrom,c=a.removeOpt,a=a.dataIndex);var d="leave"===e;d|| +// Must stop the remove animation. +t.stopAnimation("leave");var f=i(e,o,a,d?c||{}:null,o&&o.getAnimationDelayParams?o.getAnimationDelayParams(t,a):null);if(f&&f.duration>0){var h={duration:f.duration,delay:f.delay||0,easing:f.easing,done:l,force:!!l||!!s, +// Set to final state in update/init animation. +// So the post processing based on the path shape can be done correctly. +setToFinal:!d,scope:e,during:s};u?t.animateFrom(n,h):t.animateTo(n,h)}else t.stopAnimation(), +// If `isFrom`, the props is the "from" props. +!u&&t.attr(n), +// Call during at least once. +s&&s(1),l&&l()} +/** + * Update graphic element properties with or without animation according to the + * configuration in series. + * + * Caution: this method will stop previous animation. + * So do not use this method to one element twice before + * animation starts, unless you know what you are doing. + * @example + * graphic.updateProps(el, { + * position: [100, 100] + * }, seriesModel, dataIndex, function () { console.log('Animation done!'); }); + * // Or + * graphic.updateProps(el, { + * position: [100, 100] + * }, seriesModel, function () { console.log('Animation done!'); }); + */function l(e,t, +// TODO: TYPE AnimatableModel +n,r,o,i){a("update",e,t,n,r,o,i)} +/** + * Init graphic element properties with or without animation according to the + * configuration in series. + * + * Caution: this method will stop previous animation. + * So do not use this method to one element twice before + * animation starts, unless you know what you are doing. + */function s(e,t,n,r,o,i){a("enter",e,t,n,r,o,i)} +/** + * If element is removed. + * It can determine if element is having remove animation. + */function c(e){if(!e.__zr)return!0;for(var t=0;t} + * @private + */ +this._availableNames=n; +// If legend.data is not specified in option, use availableNames as data, +// which is convenient for user preparing option. +var r=this.get("data")||t,o=i.createHashMap(),s=i.map(r,(function(e){ +// Can be string or number +return(i.isString(e)||i.isNumber(e))&&(e={name:e}),o.get(e.name)?null:(o.set(e.name,!0),new a/* default */.A(e,this,this.ecModel))}),this); +/** + * @type {Array.} + * @private + */ +this._data=i.filter(s,(function(e){return!!e}))},t.prototype.getData=function(){return this._data},t.prototype.select=function(e){var t=this.option.selected;if("single"===this.get("selectedMode")){var n=this._data;i.each(n,(function(e){t[e.get("name")]=!1}))}t[e]=!0},t.prototype.unSelect=function(e){"single"!==this.get("selectedMode")&&(this.option.selected[e]=!1)},t.prototype.toggleSelected=function(e){var t=this.option.selected; +// Default is true +t.hasOwnProperty(e)||(t[e]=!0),this[t[e]?"unSelect":"select"](e)},t.prototype.allSelect=function(){var e=this._data,t=this.option.selected;i.each(e,(function(e){t[e.get("name",!0)]=!0}))},t.prototype.inverseSelect=function(){var e=this._data,t=this.option.selected;i.each(e,(function(e){var n=e.get("name",!0); +// Initially, default value is true +t.hasOwnProperty(n)||(t[n]=!0),t[n]=!t[n]}))},t.prototype.isSelected=function(e){var t=this.option.selected;return!(t.hasOwnProperty(e)&&!t[e])&&i.indexOf(this._availableNames,e)>=0},t.prototype.getOrient=function(){return"vertical"===this.get("orient")?{index:1,name:"vertical"}:{index:0,name:"horizontal"}},t.type="legend.plain",t.dependencies=["series"],t.defaultOption={ +// zlevel: 0, +z:4,show:!0,orient:"horizontal",left:"center", +// right: 'center', +top:0, +// bottom: null, +align:"auto",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemGap:10,itemWidth:25,itemHeight:14,symbolRotate:"inherit",symbolKeepAspect:!0,inactiveColor:"#ccc",inactiveBorderColor:"#ccc",inactiveBorderWidth:"auto",itemStyle:{color:"inherit",opacity:"inherit",borderColor:"inherit",borderWidth:"auto",borderCap:"inherit",borderJoin:"inherit",borderDashOffset:"inherit",borderMiterLimit:"inherit"},lineStyle:{width:"auto",color:"inherit",inactiveColor:"#ccc",inactiveWidth:2,opacity:"inherit",type:"inherit",cap:"inherit",join:"inherit",dashOffset:"inherit",miterLimit:"inherit"},textStyle:{color:"#333"},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:"sans-serif",color:"#666",borderWidth:1,borderColor:"#666"},emphasis:{selectorLabel:{show:!0,color:"#eee",backgroundColor:"#666"}},selectorPosition:"auto",selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1}},t}(s/* default */.A),u=c,d=n(47698),f=n(43870),h=n(32322),p=n(10992),m=n(43199),g=n(34833),v=n(89632),A=n(2400),y=n(34253),b=n(59109),O=n(62103),w=n(76868),x=n(69622),_=i.curry,C=i.each,k=f/* default */.A,S=/** @class */function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n.newlineDisabled=!1,n}return(0,o/* __extends */.C6)(t,e),t.prototype.init=function(){this.group.add(this._contentGroup=new k),this.group.add(this._selectorGroup=new k),this._isFirstRender=!0}, +/** + * @protected + */ +t.prototype.getContentGroup=function(){return this._contentGroup}, +/** + * @protected + */ +t.prototype.getSelectorGroup=function(){return this._selectorGroup}, +/** + * @override + */ +t.prototype.render=function(e,t,n){var r=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),e.get("show",!0)){var o=e.get("align"),a=e.get("orient");o&&"auto"!==o||(o="right"===e.get("left")&&"vertical"===a?"right":"left"); +// selector has been normalized to an array in model +var l=e.get("selector",!0),s=e.get("selectorPosition",!0);!l||s&&"auto"!==s||(s="horizontal"===a?"end":"start"),this.renderInner(o,e,t,n,l,a,s); +// Perform layout. +var c=e.getBoxLayoutParams(),u={width:n.getWidth(),height:n.getHeight()},d=e.get("padding"),f=y/* getLayoutRect */.dV(c,u,d),h=this.layoutInner(e,o,f,r,l,s),p=y/* getLayoutRect */.dV(i.defaults({width:h.width,height:h.height},c),u,d);this.group.x=p.x-h.x,this.group.y=p.y-h.y,this.group.markRedraw(), +// Render background after group is layout. +this.group.add(this._backgroundEl=(0,A/* makeBackground */.P)(h,e))}},t.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},t.prototype.renderInner=function(e,t,n,r,o,a,l){var s=this.getContentGroup(),c=i.createHashMap(),u=t.get("selectedMode"),f=[];n.eachRawSeries((function(e){!e.get("legendHoverLink")&&f.push(e.id)})),C(t.getData(),(function(o,a){var l=o.get("name"); +// Use empty string or \n as a newline string +if(!this.newlineDisabled&&(""===l||"\n"===l)){var h=new k; +// @ts-ignore +return h.newline=!0,void s.add(h)} +// Representitive series. +var p=n.getSeriesByName(l)[0];if(!c.get(l)){ +// Legend to control series. +if(p){var m=p.getData(),g=m.getVisual("legendLineStyle")||{},v=m.getVisual("legendIcon"),A=m.getVisual("style"),y=this._createItem(p,l,a,o,t,e,g,A,v,u,r);y.on("click",_(V,l,null,r,f)).on("mouseover",_(T,p.name,null,r,f)).on("mouseout",_(N,p.name,null,r,f)),n.ssr&&y.eachChild((function(e){var t=(0,x/* getECData */.z)(e);t.seriesIndex=p.seriesIndex,t.dataIndex=a,t.ssrType="legend"})),c.set(l,!0)}else +// Legend to control data. In pie and funnel. +n.eachRawSeries((function(s){ +// In case multiple series has same data name +if(!c.get(l)&&s.legendVisualProvider){var h=s.legendVisualProvider;if(!h.containName(l))return;var p=h.indexOfName(l),m=h.getItemVisual(p,"style"),g=h.getItemVisual(p,"legendIcon"),v=(0,d.parse)(m.fill); +// Color may be set to transparent in visualMap when data is out of range. +// Do not show nothing. +v&&0===v[3]&&(v[3]=.2, +// TODO color is set to 0, 0, 0, 0. Should show correct RGBA +m=i.extend(i.extend({},m),{fill:(0,d.stringify)(v,"rgba")}));var A=this._createItem(s,l,a,o,t,e,{},m,g,u,r); +// FIXME: consider different series has items with the same name. +A.on("click",_(V,null,l,r,f)).on("mouseover",_(T,null,l,r,f)).on("mouseout",_(N,null,l,r,f)),n.ssr&&A.eachChild((function(e){var t=(0,x/* getECData */.z)(e);t.seriesIndex=s.seriesIndex,t.dataIndex=a,t.ssrType="legend"})),c.set(l,!0)}}),this);0}}),this),o&&this._createSelector(o,t,r,a,l)},t.prototype._createSelector=function(e,t,n,r,o){var i=this.getSelectorGroup();C(e,(function(e){var r=e.type,o=new h/* default */.Ay({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){n.dispatchAction({type:"all"===r?"legendAllSelect":"legendInverseSelect",legendId:t.id})}});i.add(o);var a=t.getModel("selectorLabel"),l=t.getModel(["emphasis","selectorLabel"]);(0,v/* setLabelStyle */.qM)(o,{normal:a,emphasis:l},{defaultText:e.title}),(0,g/* enableHoverEmphasis */.iJ)(o)}))},t.prototype._createItem=function(e,t,n,r,o,a,l,s,c,u,d){var f=e.visualDrawType,A=o.get("itemWidth"),y=o.get("itemHeight"),b=o.isSelected(t),x=r.get("symbolRotate"),_=r.get("symbolKeepAspect"),S=r.get("icon"),V=function(e,t,n,r,o,i,a){ +/** + * Use series style if is inherit; + * elsewise, use legend style + */ +function l(e,t){ +// If lineStyle.width is 'auto', it is set to be 2 if series has border +"auto"===e.lineWidth&&(e.lineWidth=t.lineWidth>0?2:0),C(e,(function(n,r){"inherit"===e[r]&&(e[r]=t[r])}))} +// itemStyle +var s=t.getModel("itemStyle"),c=s.getItemStyle(),u=0===e.lastIndexOf("empty",0)?"fill":"stroke",d=s.getShallow("decal");c.decal=d&&"inherit"!==d?(0,w/* createOrUpdatePatternFromDecal */.w)(d,a):r.decal,"inherit"===c.fill&&( +/** + * Series with visualDrawType as 'stroke' should have + * series stroke as legend fill + */ +c.fill=r[o]);"inherit"===c.stroke&&( +/** + * icon type with "emptyXXX" should use fill color + * in visual style + */ +c.stroke=r[u]);"inherit"===c.opacity&&( +/** + * Use lineStyle.opacity if drawType is stroke + */ +c.opacity=("fill"===o?r:n).opacity);l(c,r); +// lineStyle +var f=t.getModel("lineStyle"),h=f.getLineStyle();if(l(h,n), +// Fix auto color to real color +"auto"===c.fill&&(c.fill=r.fill),"auto"===c.stroke&&(c.stroke=r.fill),"auto"===h.stroke&&(h.stroke=r.fill),!i){var p=t.get("inactiveBorderWidth"),m=c[u]; +/** + * Since stroke is set to be inactiveBorderColor, it may occur that + * there is no border in series but border in legend, so we need to + * use border only when series has border if is set to be auto + */c.lineWidth="auto"===p?r.lineWidth>0&&m?2:0:c.lineWidth,c.fill=t.get("inactiveColor"),c.stroke=t.get("inactiveBorderColor"),h.stroke=f.get("inactiveColor"),h.lineWidth=f.get("inactiveWidth")}return{itemStyle:c,lineStyle:h}}(c=S||c||"roundRect",r,l,s,f,b,d),B=new k,T=r.getModel("textStyle");if(!i.isFunction(e.getLegendIcon)||S&&"inherit"!==S){ +// Use default legend icon policy for most series +var N="inherit"===S&&e.getData().getVisual("symbol")?"inherit"===x?e.getData().getVisual("symbolRotate"):x:0;// No rotation for no icon +B.add(function(e){var t=e.icon||"roundRect",n=(0,O/* createSymbol */.v5)(t,0,0,e.itemWidth,e.itemHeight,e.itemStyle.fill,e.symbolKeepAspect);n.setStyle(e.itemStyle),n.rotation=(e.iconRotate||0)*Math.PI/180,n.setOrigin([e.itemWidth/2,e.itemHeight/2]),t.indexOf("empty")>-1&&(n.style.stroke=n.style.fill,n.style.fill="#fff",n.style.lineWidth=2);return n}({itemWidth:A,itemHeight:y,icon:c,iconRotate:N,itemStyle:V.itemStyle,lineStyle:V.lineStyle,symbolKeepAspect:_}))}else +// Series has specific way to define legend icon +B.add(e.getLegendIcon({itemWidth:A,itemHeight:y,icon:c,iconRotate:x,itemStyle:V.itemStyle,lineStyle:V.lineStyle,symbolKeepAspect:_}));var E="left"===a?A+5:-5,P=a,Q=o.get("formatter"),M=t;i.isString(Q)&&Q?M=Q.replace("{name}",null!=t?t:""):i.isFunction(Q)&&(M=Q(t));var D=b?T.getTextColor():r.get("inactiveColor");B.add(new h/* default */.Ay({style:(0,v/* createTextStyle */.VB)(T,{text:M,x:E,y:y/2,fill:D,align:P,verticalAlign:"middle"},{inheritColor:D})})); +// Add a invisible rect to increase the area of mouse hover +var $=new p/* default */.A({shape:B.getBoundingRect(),style:{ +// Cannot use 'invisible' because SVG SSR will miss the node +fill:"transparent"}}),z=r.getModel("tooltip");return z.get("show")&&m.setTooltipConfig({el:$,componentModel:o,itemName:t,itemTooltipOption:z.option}),B.add($),B.eachChild((function(e){e.silent=!0})),$.silent=!u,this.getContentGroup().add(B),(0,g/* enableHoverEmphasis */.iJ)(B), +// @ts-ignore +B.__legendDataIndex=n,B},t.prototype.layoutInner=function(e,t,n,r,o,i){var a=this.getContentGroup(),l=this.getSelectorGroup(); +// Place items in contentGroup. +y/* box */.aP(e.get("orient"),a,e.get("itemGap"),n.width,n.height);var s=a.getBoundingRect(),c=[-s.x,-s.y];if(l.markRedraw(),a.markRedraw(),o){ +// Place buttons in selectorGroup +y/* box */.aP( +// Buttons in selectorGroup always layout horizontally +"horizontal",l,e.get("selectorItemGap",!0));var u=l.getBoundingRect(),d=[-u.x,-u.y],f=e.get("selectorButtonGap",!0),h=e.getOrient().index,p=0===h?"width":"height",m=0===h?"height":"width",g=0===h?"y":"x";"end"===i?d[h]+=s[p]+f:c[h]+=u[p]+f, +// Always align selector to content as 'middle' +d[1-h]+=s[m]/2-u[m]/2,l.x=d[0],l.y=d[1],a.x=c[0],a.y=c[1];var v={x:0,y:0};return v[p]=s[p]+f+u[p],v[m]=Math.max(s[m],u[m]),v[g]=Math.min(0,u[g]+d[1-h]),v}return a.x=c[0],a.y=c[1],this.group.getBoundingRect()}, +/** + * @protected + */ +t.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},t.type="legend.plain",t}(b/* default */.A); +// EXTERNAL MODULE: ./node_modules/tslib/tslib.es6.js +function V(e,t,n,r){ +// downplay before unselect +N(e,t,n,r),n.dispatchAction({type:"legendToggleSelect",name:null!=e?e:t}), +// highlight after select +// TODO highlight immediately may cause animation loss. +T(e,t,n,r)}function B(e){for(var t,n=e.getZr().storage.getDisplayList(),r=0,o=n.length;rn[o],g=[-f.x,-f.y]; +// Remain contentPos when scroll animation perfroming. +// If first rendering, `contentGroup.position` is [0, 0], which +// does not make sense and may cause unexepcted animation if adopted. +t||(g[r]=c[s]); +// Layout container group based on 0. +var v=[0,0],A=[-h.x,-h.y],b=i.retrieve2(e.get("pageButtonGap",!0),e.get("itemGap",!0)); +// Place containerGroup and controllerGroup and contentGroup. +m&&( +// controller is on the right / bottom. +"end"===e.get("pageButtonPosition",!0)?A[r]+=n[o]-h[o]:v[r]+=h[o]+b); +// Always align controller to content as 'middle'. +A[1-r]+=f[a]/2-h[a]/2,c.setPosition(g),u.setPosition(v),d.setPosition(A); +// Calculate `mainRect` and set `clipPath`. +// mainRect should not be calculated by `this.group.getBoundingRect()` +// for sake of the overflow. +var O={x:0,y:0}; +// Consider content may be overflow (should be clipped). +if(O[o]=m?n[o]:f[o],O[a]=Math.max(f[a],h[a]), +// `containerRect[yx] + containerPos[1 - orientIdx]` is 0. +O[l]=Math.min(0,h[l]+A[1-r]),u.__rectSize=n[o],m){var w={x:0,y:0};w[o]=Math.max(n[o]-h[o]-b,0),w[a]=O[a],u.setClipPath(new p/* default */.A({shape:w})), +// Consider content may be larger than container, container rect +// can not be obtained from `containerGroup.getBoundingRect()`. +u.__rectSize=w[o]}else +// Do not remove or ignore controller. Keep them set as placeholders. +d.eachChild((function(e){e.attr({invisible:!0,silent:!0})})); +// Content translate animation. +var x=this._getPageInfo(e);return null!=x.pageIndex&&L/* updateProps */.oi(c,{x:x.contentPosition[0],y:x.contentPosition[1]}, +// When switch from "show controller" to "not show controller", view should be +// updated immediately without animation, otherwise causes weird effect. +m?e:null),this._updatePageInfoView(e,x),O},t.prototype._pageGo=function(e,t,n){var r=this._getPageInfo(t)[e];null!=r&&n.dispatchAction({type:"legendScroll",scrollDataIndex:r,legendId:t.id})},t.prototype._updatePageInfoView=function(e,t){var n=this._controllerGroup;i.each(["pagePrev","pageNext"],(function(r){var o=null!=t[r+"DataIndex"],i=n.childOfName(r);i&&(i.setStyle("fill",o?e.get("pageIconColor",!0):e.get("pageIconInactiveColor",!0)),i.cursor=o?"pointer":"default")}));var r=n.childOfName("pageText"),o=e.get("pageFormatter"),a=t.pageIndex,l=null!=a?a+1:0,s=t.pageCount;r&&o&&r.setStyle("text",i.isString(o)?o.replace("{current}",null==l?"":l+"").replace("{total}",null==s?"":s+""):o({current:l,total:s}))}, +/** + * contentPosition: Array., null when data item not found. + * pageIndex: number, null when data item not found. + * pageCount: number, always be a number, can be 0. + * pagePrevDataIndex: number, null when no previous page. + * pageNextDataIndex: number, null when no next page. + * } + */ +t.prototype._getPageInfo=function(e){var t=e.get("scrollDataIndex",!0),n=this.getContentGroup(),r=this._containerGroup.__rectSize,o=e.getOrient().index,i=U[o],a=H[o],l=this._findTargetItemIndex(t),s=n.children(),c=s[l],u=s.length,d=u?1:0,f={contentPosition:[n.x,n.y],pageCount:d,pageIndex:d-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!c)return f;var h=A(c);f.contentPosition[o]=-h.s; +// Strategy: +// (1) Always align based on the left/top most item. +// (2) It is user-friendly that the last item shown in the +// current window is shown at the begining of next window. +// Otherwise if half of the last item is cut by the window, +// it will have no chance to display entirely. +// (3) Consider that item size probably be different, we +// have calculate pageIndex by size rather than item index, +// and we can not get page index directly by division. +// (4) The window is to narrow to contain more than +// one item, we should make sure that the page can be fliped. +for(var p=l+1,m=h,g=h,v=null;p<=u;++p) +// Half of the last item is out of the window. +(!(v=A(s[p]))&&g.e>m.s+r||v&&!y(v,m.s))&&(m=g.i>m.i?g:v)&&(null==f.pageNextDataIndex&&(f.pageNextDataIndex=m.i),++f.pageCount),g=v;for(p=l-1,m=h,g=h,v=null;p>=-1;--p) +// If the the end item does not intersect with the window started +// from the current item, a page can be settled. +(v=A(s[p]))&&y(g,v.s)||!(m.i=t&&e.s<=t+r}},t.prototype._findTargetItemIndex=function(e){return this._showController?(this.getContentGroup().eachChild((function(r,o){var i=r.__legendDataIndex; +// FIXME +// If the given targetDataIndex (from model) is illegal, +// we use defaultIndex. But the index on the legend model and +// action payload is still illegal. That case will not be +// changed until some scenario requires. +null==n&&null!=i&&(n=o),i===e&&(t=o)})),null!=t?t:n):0;var t,n},t.type="legend.scroll",t}(E),j=W; +// EXTERNAL MODULE: ./node_modules/echarts/lib/animation/basicTransition.js +// ./node_modules/echarts/lib/component/legend/installLegendScroll.js +/* +* Licensed to the Apache Software Foundation (ASF) under one +* or more contributor license agreements. See the NOTICE file +* distributed with this work for additional information +* regarding copyright ownership. The ASF licenses this file +* to you under the Apache License, Version 2.0 (the +* "License"); you may not use this file except in compliance +* with the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, +* software distributed under the License is distributed on an +* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +* KIND, either express or implied. See the License for the +* specific language governing permissions and limitations +* under the License. +*/ +/** + * AUTO-GENERATED FILE. DO NOT MODIFY. + */ +/* +* Licensed to the Apache Software Foundation (ASF) under one +* or more contributor license agreements. See the NOTICE file +* distributed with this work for additional information +* regarding copyright ownership. The ASF licenses this file +* to you under the Apache License, Version 2.0 (the +* "License"); you may not use this file except in compliance +* with the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, +* software distributed under the License is distributed on an +* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +* KIND, either express or implied. See the License for the +* specific language governing permissions and limitations +* under the License. +*/ +function q(e){(0,r/* use */.Y)(D),e.registerComponentModel(I),e.registerComponentView(j),// ./node_modules/echarts/lib/component/legend/scrollableLegendAction.js +/* +* Licensed to the Apache Software Foundation (ASF) under one +* or more contributor license agreements. See the NOTICE file +* distributed with this work for additional information +* regarding copyright ownership. The ASF licenses this file +* to you under the Apache License, Version 2.0 (the +* "License"); you may not use this file except in compliance +* with the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, +* software distributed under the License is distributed on an +* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +* KIND, either express or implied. See the License for the +* specific language governing permissions and limitations +* under the License. +*/ +/** + * AUTO-GENERATED FILE. DO NOT MODIFY. + */ +/* +* Licensed to the Apache Software Foundation (ASF) under one +* or more contributor license agreements. See the NOTICE file +* distributed with this work for additional information +* regarding copyright ownership. The ASF licenses this file +* to you under the Apache License, Version 2.0 (the +* "License"); you may not use this file except in compliance +* with the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, +* software distributed under the License is distributed on an +* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +* KIND, either express or implied. See the License for the +* specific language governing permissions and limitations +* under the License. +*/ +function(e){ +/** + * @event legendScroll + * @type {Object} + * @property {string} type 'legendScroll' + * @property {string} scrollDataIndex + */ +e.registerAction("legendScroll","legendscroll",(function(e,t){var n=e.scrollDataIndex;null!=n&&t.eachComponent({mainType:"legend",subType:"scroll",query:e},(function(e){e.setScrollDataIndex(n)}))}))}(e)}// ./node_modules/echarts/lib/component/legend/install.js +/* +* Licensed to the Apache Software Foundation (ASF) under one +* or more contributor license agreements. See the NOTICE file +* distributed with this work for additional information +* regarding copyright ownership. The ASF licenses this file +* to you under the Apache License, Version 2.0 (the +* "License"); you may not use this file except in compliance +* with the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, +* software distributed under the License is distributed on an +* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +* KIND, either express or implied. See the License for the +* specific language governing permissions and limitations +* under the License. +*/ +/** + * AUTO-GENERATED FILE. DO NOT MODIFY. + */ +/* +* Licensed to the Apache Software Foundation (ASF) under one +* or more contributor license agreements. See the NOTICE file +* distributed with this work for additional information +* regarding copyright ownership. The ASF licenses this file +* to you under the Apache License, Version 2.0 (the +* "License"); you may not use this file except in compliance +* with the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, +* software distributed under the License is distributed on an +* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +* KIND, either express or implied. See the License for the +* specific language governing permissions and limitations +* under the License. +*/ +function X(e){(0,r/* use */.Y)(D),(0,r/* use */.Y)(q)} +/***/}, +/***/5786: +/***/function(e,t,n){"use strict"; +// EXPORTS +n.d(t,{a:function(){/* binding */return O}}); +// EXTERNAL MODULE: ./node_modules/zrender/lib/core/util.js +var r=n(98026),o=n(41025),i=n(31825),a={value:"eq", +// PENDING: not good for literal semantic? +"<":"lt","<=":"lte",">":"gt",">=":"gte","=":"eq","!=":"ne","<>":"ne"},l=/** @class */function(){function e(e){if(null==(this._condVal=(0,r.isString)(e)?new RegExp(e):(0,r.isRegExp)(e)?e:null)){0,(0,o/* throwError */.$8)("")}}return e.prototype.evaluate=function(e){var t=typeof e;return(0,r.isString)(t)?this._condVal.test(e):!!(0,r.isNumber)(t)&&this._condVal.test(e+"")},e}(),s=/** @class */function(){function e(){}return e.prototype.evaluate=function(){return this.value},e}(),c=/** @class */function(){function e(){}return e.prototype.evaluate=function(){for(var e=this.children,t=0;t
'}; +/** + * Helpers + */ +function o(e,t,n){return en?n:e} +/** + * (Internal) converts a percentage (`0..1`) to a bar translateX + * percentage (`-100%..0%`). + */function i(e){return 100*(-1+e)} +/** + * (Internal) returns the correct CSS for changing the bar's + * position given an n percentage, and speed and ease from Settings + */function a(e,t,n){var o;return(o="translate3d"===r.positionUsing?{transform:"translate3d("+i(e)+"%,0,0)"}:"translate"===r.positionUsing?{transform:"translate("+i(e)+"%,0)"}:{"margin-left":i(e)+"%"}).transition="all "+t+"ms "+n,o} +/** + * (Internal) Queues a function to be executed. + */ +/** + * Updates configuration. + * + * NProgress.configure({ + * minimum: 0.1 + * }); + */ +n.configure=function(e){var t,n;for(t in e)void 0!==(n=e[t])&&e.hasOwnProperty(t)&&(r[t]=n);return this}, +/** + * Last number. + */ +n.status=null, +/** + * Sets the progress bar status, where `n` is a number from `0.0` to `1.0`. + * + * NProgress.set(0.4); + * NProgress.set(1.0); + */ +n.set=function(e){var t=n.isStarted();e=o(e,r.minimum,1),n.status=1===e?null:e;var i=n.render(!t),c=i.querySelector(r.barSelector),u=r.speed,d=r.easing;return i.offsetWidth,/* Repaint */ +l((function(t){ +// Set positionUsing if it hasn't already been set +""===r.positionUsing&&(r.positionUsing=n.getPositioningCSS()), +// Add transition +s(c,a(e,u,d)),1===e?( +// Fade out +s(i,{transition:"none",opacity:1}),i.offsetWidth,/* Repaint */ +setTimeout((function(){s(i,{transition:"all "+u+"ms linear",opacity:0}),setTimeout((function(){n.remove(),t()}),u)}),u)):setTimeout(t,u)})),this},n.isStarted=function(){return"number"==typeof n.status}, +/** + * Shows the progress bar. + * This is the same as setting the status to 0%, except that it doesn't go backwards. + * + * NProgress.start(); + * + */ +n.start=function(){n.status||n.set(0);var e=function(){setTimeout((function(){n.status&&(n.trickle(),e())}),r.trickleSpeed)};return r.trickle&&e(),this}, +/** + * Hides the progress bar. + * This is the *sort of* the same as setting the status to 100%, with the + * difference being `done()` makes some placebo effect of some realistic motion. + * + * NProgress.done(); + * + * If `true` is passed, it will show the progress bar even if its hidden. + * + * NProgress.done(true); + */ +n.done=function(e){return e||n.status?n.inc(.3+.5*Math.random()).set(1):this}, +/** + * Increments by a random amount. + */ +n.inc=function(e){var t=n.status;return t?("number"!=typeof e&&(e=(1-t)*o(Math.random()*t,.1,.95)),t=o(t+e,0,.994),n.set(t)):n.start()},n.trickle=function(){return n.inc(Math.random()*r.trickleRate)}, +/** + * Waits for all supplied jQuery promises and + * increases the progress as the promises resolve. + * + * @param $promise jQUery Promise + */ +e=0,t=0,n.promise=function(r){return r&&"resolved"!==r.state()?(0===t&&n.start(),e++,t++,r.always((function(){0==--t?(e=0,n.done()):n.set((e-t)/e)})),this):this}, +/** + * (Internal) renders the progress bar markup based on the `template` + * setting. + */ +n.render=function(e){if(n.isRendered())return document.getElementById("nprogress");u(document.documentElement,"nprogress-busy");var t=document.createElement("div");t.id="nprogress",t.innerHTML=r.template;var o,a=t.querySelector(r.barSelector),l=e?"-100":i(n.status||0),c=document.querySelector(r.parent);return s(a,{transition:"all 0 linear",transform:"translate3d("+l+"%,0,0)"}),r.showSpinner||(o=t.querySelector(r.spinnerSelector))&&h(o),c!=document.body&&u(c,"nprogress-custom-parent"),c.appendChild(t),t}, +/** + * Removes the element. Opposite of render(). + */ +n.remove=function(){d(document.documentElement,"nprogress-busy"),d(document.querySelector(r.parent),"nprogress-custom-parent");var e=document.getElementById("nprogress");e&&h(e)}, +/** + * Checks if the progress bar is rendered. + */ +n.isRendered=function(){return!!document.getElementById("nprogress")}, +/** + * Determine which positioning CSS rule to use. + */ +n.getPositioningCSS=function(){ +// Sniff on document.body.style +var e=document.body.style,t="WebkitTransform"in e?"Webkit":"MozTransform"in e?"Moz":"msTransform"in e?"ms":"OTransform"in e?"O":""; +// Sniff prefixes +return t+"Perspective"in e?"translate3d":t+"Transform"in e?"translate":"margin"};var l=function(){var e=[];function t(){var n=e.shift();n&&n(t)}return function(n){e.push(n),1==e.length&&t()}}(),s=function(){var e=["Webkit","O","Moz","ms"],t={};function n(e){return e.replace(/^-ms-/,"ms-").replace(/-([\da-z])/gi,(function(e,t){return t.toUpperCase()}))}function r(t){var n=document.body.style;if(t in n)return t;for(var r,o=e.length,i=t.charAt(0).toUpperCase()+t.slice(1);o--;)if((r=e[o]+i)in n)return r;return t}function o(e){return e=n(e),t[e]||(t[e]=r(e))}function i(e,t,n){t=o(t),e.style[t]=n}return function(e,t){var n,r,o=arguments;if(2==o.length)for(n in t)void 0!==(r=t[n])&&t.hasOwnProperty(n)&&i(e,n,r);else i(e,o[1],o[2])}}(); +/** + * (Internal) Applies css properties to an element, similar to the jQuery + * css method. + * + * While this helper does assist with vendor prefixed property names, it + * does not perform any manipulation of values prior to setting styles. + */ +/** + * (Internal) Determines if an element or space separated list of class names contains a class name. + */ +function c(e,t){return("string"==typeof e?e:f(e)).indexOf(" "+t+" ")>=0} +/** + * (Internal) Adds a class to an element. + */function u(e,t){var n=f(e),r=n+t;c(n,t)||( +// Trim the opening space. +e.className=r.substring(1))} +/** + * (Internal) Removes a class from an element. + */function d(e,t){var n,r=f(e);c(e,t)&&( +// Replace the class name. +n=r.replace(" "+t+" "," "), +// Trim the opening and closing spaces. +e.className=n.substring(1,n.length-1))} +/** + * (Internal) Gets a space separated list of the class names on the element. + * The list is wrapped with a single space on each end to facilitate finding + * matches within the list. + */function f(e){return(" "+(e.className||"")+" ").replace(/\s+/gi," ")} +/** + * (Internal) Removes an element from the DOM. + */function h(e){e&&e.parentNode&&e.parentNode.removeChild(e)}return n},void 0===(o="function"==typeof r?r.call(t,n,t,e):r)||(e.exports=o)}, +/***/5951: +/***/function(e,t,n){"use strict"; +// ESM COMPAT FLAG +n.r(t), +// EXPORTS +n.d(t,{default:function(){/* binding */return f}}); +// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.push.js +n(44114); +// EXTERNAL MODULE: ./node_modules/vue/dist/vue.esm-bundler.js + 5 modules +var r=n(61431),o=n(90517),i=n(45057),a=n(92492),l=n(28829),s=n(48404);// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/lyform-builder/lysetting-pannel/lywidget-setting/checkbox-setting-ly.vue?vue&type=script&setup=true&lang=js +const c={class:"col-item"},u={style:{display:"flex","align-items":"center"}}; +/* harmony default export */var d={__name:"checkbox-setting-ly",props:{selectedWidget:Object,optionModel:Object,builderConfig:{type:Object,default:{showHeader:!0, +//是否显示头部信息 +showFormTemplates:!0, +//是否显示表单模板 +showEventCollapse:!0, +//是否显示组件事件属性折叠面板 +showDocumentButton:!0, +//是否显示文档按钮 +clearDesignerButton:!0, +//是否显示清空设计器按钮 +previewFormButton:!0, +//是否显示预览表单按钮 +exportJsonButton:!0, +//是否显示导出JSON器按钮 +exportCodeButton:!0, +//是否显示导出代码按钮 +importJsonButton:!0, +//是否显示导入代码按钮 +showFullButton:!0, +//是否显示全屏按钮 +openNewWindowButton:!0, +//是否显示新窗口按钮 +saveFormButton:!0, +//是否保存表单按钮 +showCrudSettings:!0}}},setup(e){const t=(0,r.defineAsyncComponent)((()=>Promise.resolve().then(n.bind(n,55866)))),d=e,f=(0,o/* useBuilderStore */.k)();function h(e){f.saveCurrentHistoryStep()}let p=(0,r.ref)(["lyws01","lyws02","lyws03"]);const m=(0,r.ref)([{label:"default",value:""},{label:"large",value:"large"},{label:"small",value:"small"}]);function g(){return void 0===f.builderConfig.showEventCollapse||!!f.builderConfig.showEventCollapse}let v=(0,r.ref)(""),A=(0,r.ref)(""),y=(0,r.ref)(!1),b=(0,r.ref)("");//编辑选中当前事件名称 +function O(){y.value=!1}function w(){f.selectedWidget.options[v.value]=b.value,f.saveCurrentHistoryStep(),y.value=!1}return(n,o)=>{const x=(0,r.resolveComponent)("el-input"),_=(0,r.resolveComponent)("el-form-item"),C=(0,r.resolveComponent)("el-switch"),k=(0,r.resolveComponent)("el-radio"),S=(0,r.resolveComponent)("el-radio-group"),V=(0,r.resolveComponent)("el-option"),B=(0,r.resolveComponent)("el-select"),T=(0,r.resolveComponent)("el-divider"),N=(0,r.resolveComponent)("Rank"),E=(0,r.resolveComponent)("el-icon"),P=(0,r.resolveComponent)("el-button"),Q=(0,r.resolveComponent)("el-checkbox"),M=(0,r.resolveComponent)("draggable"),D=(0,r.resolveComponent)("el-checkbox-group"),$=(0,r.resolveComponent)("el-collapse-item"),z=(0,r.resolveComponent)("QuestionFilled"),R=(0,r.resolveComponent)("el-tooltip"),I=(0,r.resolveComponent)("el-collapse"),L=(0,r.resolveComponent)("el-alert"),F=(0,r.resolveComponent)("el-form");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[(0,r.createVNode)(F,{size:"small","label-position":"left","label-width":"100px",class:"lywidgetsetting",onSubmit:o[20]||(o[20]=(0,r.withModifiers)((()=>{}),["prevent"]))},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(I,{modelValue:(0,r.unref)(p),"onUpdate:modelValue":o[17]||(o[17]=e=>(0,r.isRef)(p)?p.value=e:p=e),class:"lyformsetting-collapse"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)($,{name:"lyws01",title:"组件属性"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(_,{label:"字段标识"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(x,{modelValue:e.optionModel.name,"onUpdate:modelValue":o[0]||(o[0]=t=>e.optionModel.name=t),modelModifiers:{trim:!0},onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(_,{label:"隐藏"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(C,{modelValue:e.optionModel.hidden,"onUpdate:modelValue":o[1]||(o[1]=t=>e.optionModel.hidden=t),onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(_,{label:"禁用"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(C,{modelValue:e.optionModel.disabled,"onUpdate:modelValue":o[2]||(o[2]=t=>e.optionModel.disabled=t),onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(_,{label:"显示样式"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(S,{modelValue:e.optionModel.displayStyle,"onUpdate:modelValue":o[3]||(o[3]=t=>e.optionModel.displayStyle=t),onChange:h},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(k,{value:"inline"},{default:(0,r.withCtx)((()=>o[21]||(o[21]=[(0,r.createTextVNode)("行内")]))),_:1}),(0,r.createVNode)(k,{value:"block"},{default:(0,r.withCtx)((()=>o[22]||(o[22]=[(0,r.createTextVNode)("块级")]))),_:1})])),_:1},8,["modelValue"])])),_:1}),(0,r.createVNode)(_,{label:"显示为按钮"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(C,{modelValue:e.optionModel.buttonStyle,"onUpdate:modelValue":o[4]||(o[4]=t=>e.optionModel.buttonStyle=t),onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(_,{label:"显示边框"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(C,{modelValue:e.optionModel.border,"onUpdate:modelValue":o[5]||(o[5]=t=>e.optionModel.border=t),onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(_,{label:"标签文本"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(x,{modelValue:e.optionModel.label,"onUpdate:modelValue":o[6]||(o[6]=t=>e.optionModel.label=t),style:{width:"100%"},onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(_,{label:"标签宽度"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(x,{modelValue:e.optionModel.labelWidth,"onUpdate:modelValue":o[7]||(o[7]=t=>e.optionModel.labelWidth=t),style:{width:"100%"},onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(_,{label:"隐藏字段标签"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(C,{modelValue:e.optionModel.labelHidden,"onUpdate:modelValue":o[8]||(o[8]=t=>e.optionModel.labelHidden=t),onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(_,{label:"默认值"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(x,{modelValue:e.optionModel.defaultValue,"onUpdate:modelValue":o[9]||(o[9]=t=>e.optionModel.defaultValue=t),style:{width:"100%"},onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(_,{label:"组件大小"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(B,{modelValue:e.optionModel.size,"onUpdate:modelValue":o[10]||(o[10]=t=>e.optionModel.size=t),onChange:h},{default:(0,r.withCtx)((()=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(m.value,(e=>((0,r.openBlock)(),(0,r.createBlock)(V,{key:e.value,label:e.label,value:e.value},null,8,["label","value"])))),128))])),_:1},8,["modelValue"])])),_:1}),(0,r.createVNode)(_,{label:"必填字段"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(C,{modelValue:e.optionModel.required,"onUpdate:modelValue":o[11]||(o[11]=t=>e.optionModel.required=t),onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(_,{label:"必填校验提示"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(x,{modelValue:e.optionModel.requiredHint,"onUpdate:modelValue":o[12]||(o[12]=t=>e.optionModel.requiredHint=t),style:{width:"100%"},onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)((0/* default */,r.unref)(i.A),{"selected-widget":e.selectedWidget,"option-model":e.optionModel},null,8,["selected-widget","option-model"]),(0,r.createVNode)(_,{label:"校验失败提示"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(x,{modelValue:e.optionModel.validationHint,"onUpdate:modelValue":o[13]||(o[13]=t=>e.optionModel.validationHint=t),style:{width:"100%"},onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)((0/* default */,r.unref)(a.A),{"selected-widget":e.selectedWidget,"option-model":e.optionModel},null,8,["selected-widget","option-model"]),(0,r.createVNode)(_,{"label-width":"0"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(T,null,{default:(0,r.withCtx)((()=>o[23]||(o[23]=[(0,r.createTextVNode)("选项设置")]))),_:1})])),_:1}),(0,r.createVNode)(_,{"label-width":"0",class:"panes-setting"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(D,{modelValue:e.optionModel.defaultValue,"onUpdate:modelValue":o[14]||(o[14]=t=>e.optionModel.defaultValue=t),onChange:h},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(M,(0,r.mergeProps)({tag:"ul",list:e.optionModel.optionItems,"item-key":"id"},{group:"optionsGroup",ghostClass:"ghost",handle:".drag-option"}),{item:(0,r.withCtx)((({element:e,index:t})=>[(0,r.createElementVNode)("li",c,[(0,r.createVNode)(E,{class:"drag-option",size:"18"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(N)])),_:1}),(0,r.createVNode)(Q,{value:e.value},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(x,{modelValue:e.value,"onUpdate:modelValue":t=>e.value=t,size:"small",style:{width:"90px"}},null,8,["modelValue","onUpdate:modelValue"]),(0,r.createVNode)(x,{type:"text",modelValue:e.label,"onUpdate:modelValue":t=>e.label=t,style:{width:"100px"}},null,8,["modelValue","onUpdate:modelValue"]),(0,r.createVNode)(P,{circle:"",plain:"",size:"small",type:"danger",onClick:e=>{return n=t,d.optionModel.optionItems.splice(n,1),void f.emitHistoryChange();var n},icon:"SemiSelect",class:"col-delete-button"},null,8,["onClick"])])),_:2},1032,["value"])])])),_:1},16,["list"])])),_:1},8,["modelValue"]),(0,r.createElementVNode)("div",null,[(0,r.createVNode)(P,{link:"",type:"primary",onClick:o[15]||(o[15]=e=>function(){let e=d.optionModel.optionItems.length+1;d.optionModel.optionItems.push({value:e,label:"new option"}),f.emitHistoryChange()}()),icon:"plus"},{default:(0,r.withCtx)((()=>o[24]||(o[24]=[(0,r.createTextVNode)("增加选项")]))),_:1})])])),_:1})])),_:1}),g?((0,r.openBlock)(),(0,r.createBlock)($,{key:0,name:"lyws02",title:"事件属性"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(_,{label:"onChange","label-width":"150px"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(P,{type:"info",icon:"edit",plain:"",round:"",onClick:o[16]||(o[16]=e=>{return t="onChange",n=["value"], +//flag事件名、eventParamsName事件回调参数名使用数组[] +v.value=t,A.value=`${d.optionModel.name}.${t}(${n.join(", ")}) {`,b.value=d.selectedWidget.options[t]||"",void(y.value=!0);var t,n})},{default:(0,r.withCtx)((()=>o[25]||(o[25]=[(0,r.createTextVNode)("编写代码")]))),_:1})])),_:1})])),_:1})):(0,r.createCommentVNode)("",!0),e.builderConfig.showCrudSettings?((0,r.openBlock)(),(0,r.createBlock)($,{key:1,name:"lyws03",title:"CRUD属性"},{title:(0,r.withCtx)((()=>[(0,r.createElementVNode)("div",u,[o[26]||(o[26]=(0,r.createTextVNode)(" CRUD属性 ")),(0,r.createVNode)(R,{effect:"dark",content:"后端自动生成CRUD代码,用于控制是否列表显示、可查询、可空、可编辑等属性",placement:"top-start"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(E,null,{default:(0,r.withCtx)((()=>[(0,r.createVNode)(z)])),_:1})])),_:1})])])),default:(0,r.withCtx)((()=>[(0,r.createVNode)((0/* default */,r.unref)(l.A),{"selected-widget":e.selectedWidget,"option-model":e.optionModel},null,8,["selected-widget","option-model"])])),_:1})):(0,r.createCommentVNode)("",!0)])),_:1},8,["modelValue"]),(0,r.createVNode)((0/* default */,r.unref)(s.A),{modelValue:(0,r.unref)(y),"onUpdate:modelValue":o[19]||(o[19]=e=>(0,r.isRef)(y)?y.value=e:y=e),title:"组件事件",width:"60%",top:"20px","before-close":O},{footer:(0,r.withCtx)((()=>[(0,r.createVNode)(P,{onClick:O,size:"default"},{default:(0,r.withCtx)((()=>o[27]||(o[27]=[(0,r.createTextVNode)("关闭")]))),_:1}),(0,r.createVNode)(P,{type:"primary",onClick:w,size:"default"},{default:(0,r.withCtx)((()=>o[28]||(o[28]=[(0,r.createTextVNode)("确定")]))),_:1})])),default:(0,r.withCtx)((()=>[(0,r.createElementVNode)("div",null,[(0,r.createVNode)(L,{title:(0,r.unref)(A),type:"info",closable:!1},null,8,["title"]),(0,r.createVNode)((0,r.unref)(t),{ref:"lyFormEditCss",modelValue:(0,r.unref)(b),"onUpdate:modelValue":o[18]||(o[18]=e=>(0,r.isRef)(b)?b.value=e:b=e),mode:"javascript",height:"600","read-only":!1},null,8,["modelValue"]),(0,r.createVNode)(L,{title:"}",closable:!1,type:"info"})])])),_:1},8,["modelValue"])])),_:1})])}}}; +/* harmony default export */var f=(0,n(66262).A)(d,[["__scopeId","data-v-18965ecb"]]); +/***/}, +/***/6006: +/***/function(e,t,n){"use strict"; +/* harmony import */var r,o,i,a,l,s,c,u=n(98026),d=n(5202),f=n(16563),h=n(58267),p=n(29756),m=n(22759),g=n(13430),v=n(48170),A=n(69622),y=n(34310),b=n(70250),O=n(73632),w=u.isObject,x=u.map,_="undefined"==typeof Int32Array?Array:Int32Array,C=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_dimSummary","userOutput","_rawData","_dimValueGetter","_nameDimIdx","_idDimIdx","_nameRepeatCount"],k=["_approximateExtent"],S=/** @class */function(){ +/** + * @param dimensionsInput.dimensions + * For example, ['someDimName', {name: 'someDimName', type: 'someDimType'}, ...]. + * Dimensions should be concrete names like x, y, z, lng, lat, angle, radius + */ +function e(e,t){var n;this.type="list",this._dimOmitted=!1,this._nameList=[],this._idList=[], +// Models of data option is stored sparse for optimizing memory cost +// Never used yet (not used yet). +// private _optionModels: Model[] = []; +// Global visual properties after visual coding +this._visual={}, +// Global layout properties. +this._layout={}, +// Item visual properties after visual coding +this._itemVisuals=[], +// Item layout properties after layout +this._itemLayouts=[], +// Graphic elements +this._graphicEls=[], +// key: dim, value: extent +this._approximateExtent={},this._calculationInfo={}, +// Having detected that there is data item is non primitive type +// (in type `OptionDataItemObject`). +// Like `data: [ { value: xx, itemStyle: {...} }, ...]` +// At present it only happen in `SOURCE_FORMAT_ORIGINAL`. +this.hasItemOption=!1, +// Methods that create a new list based on this list should be listed here. +// Notice that those method should `RETURN` the new list. +this.TRANSFERABLE_METHODS=["cloneShallow","downSample","minmaxDownSample","lttbDownSample","map"], +// Methods that change indices of this list should be listed here. +this.CHANGABLE_METHODS=["filterSelf","selectRange"],this.DOWNSAMPLE_METHODS=["downSample","minmaxDownSample","lttbDownSample"];var r=!1;(0,O/* .isSeriesDataSchema */.fg)(e)?(n=e.dimensions,this._dimOmitted=e.isDimensionOmitted(),this._schema=e):(r=!0,n=e),n=n||["x","y"];for(var o={},i=[],a={},l=!1,s={},c=0;c=t)){var n=this._store.getProvider();this._updateOrdinalMeta();var o=this._nameList,i=this._idList; +// Each data item is value +// [1, 2] +// 2 +// Bar chart, line chart which uses category axis +// only gives the 'y' value. 'x' value is the indices of category +// Use a tempValue to normalize the value to be a (x, y) value +// If dataItem is {name: ...} or {id: ...}, it has highest priority. +// This kind of ids and names are always stored `_nameList` and `_idList`. +if(n.getSource().sourceFormat===g/* .SOURCE_FORMAT_ORIGINAL */.mK&&!n.pure)for(var a=[],l=e;l0}, +/** + * Make sure itemVisual property is unique + */ +// TODO: use key to save visual to reduce memory. +e.prototype.ensureUniqueItemVisual=function(e,t){var n=this._itemVisuals,r=n[e];r||(r=n[e]={});var o=r[t];return null==o&&(o=this.getVisual(t), +// TODO Performance? +u.isArray(o)?o=o.slice():w(o)&&(o=u.extend({},o)),r[t]=o),o}, +// eslint-disable-next-line +e.prototype.setItemVisual=function(e,t,n){var r=this._itemVisuals[e]||{};this._itemVisuals[e]=r,w(t)?u.extend(r,t):r[t]=n}, +/** + * Clear itemVisuals and list visual. + */ +e.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},e.prototype.setLayout=function(e,t){w(e)?u.extend(this._layout,e):this._layout[e]=t}, +/** + * Get layout property. + */ +e.prototype.getLayout=function(e){return this._layout[e]}, +/** + * Get layout of single data item + */ +e.prototype.getItemLayout=function(e){return this._itemLayouts[e]}, +/** + * Set layout of single data item + */ +e.prototype.setItemLayout=function(e,t,n){this._itemLayouts[e]=n?u.extend(this._itemLayouts[e]||{},t):t}, +/** + * Clear all layout of single data item + */ +e.prototype.clearItemLayouts=function(){this._itemLayouts.length=0}, +/** + * Set graphic element relative to data. It can be set as null + */ +e.prototype.setItemGraphicEl=function(e,t){var n=this.hostModel&&this.hostModel.seriesIndex;(0,A/* .setCommonECData */.a)(n,this.dataType,e,t),this._graphicEls[e]=t},e.prototype.getItemGraphicEl=function(e){return this._graphicEls[e]},e.prototype.eachItemGraphicEl=function(e,t){u.each(this._graphicEls,(function(n,r){n&&e&&e.call(t,n,r)}))}, +/** + * Shallow clone a new list except visual and layout properties, and graph elements. + * New list only change the indices. + */ +e.prototype.cloneShallow=function(t){return t||(t=new e(this._schema?this._schema:x(this.dimensions,this._getDimInfo,this),this.hostModel)),l(t,this),t._store=this._store,t}, +/** + * Wrap some method to add more feature + */ +e.prototype.wrapMethod=function(e,t){var n=this[e];u.isFunction(n)&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(e),this[e]=function(){var e=n.apply(this,arguments);return t.apply(this,[e].concat(u.slice(arguments)))})}, +// ---------------------------------------------------------- +// A work around for internal method visiting private member. +// ---------------------------------------------------------- +e.internalField=(r=function(e){var t=e._invertedIndicesMap;u.each(t,(function(n,r){var o=e._dimInfos[r],i=o.ordinalMeta,a=e._store; +// Currently, only dimensions that has ordinalMeta can create inverted indices. +if(i){n=t[r]=new _(i.categories.length); +// The default value of TypedArray is 0. To avoid miss +// mapping to 0, we should set it as INDEX_NOT_FOUND. +for(var l=0;l1&&(s+="__ec__"+u),r[t]=s}})),e}(); +/* harmony import */ +/* harmony default export */t.A=S}, +/***/6060: +/***/function(e,t,n){var r=n(75526) +/** + * 判断是否Date对象 + * + * @param {Object} obj 对象 + * @return {Boolean} + */("Date");e.exports=r +/***/}, +/***/6393: +/***/function(e,t,n){"use strict"; +// EXPORTS +n.d(t,{AH:function(){/* binding */return P},Yk:function(){/* binding */return E}}); +// UNUSED EXPORTS: cssCompletionSource, defineCSSCompletionSource +// EXTERNAL MODULE: ./node_modules/@lezer/lr/dist/index.js +var r=n(48820),o=n(43720); +// EXTERNAL MODULE: ./node_modules/@lezer/highlight/dist/index.js +// ./node_modules/@lezer/css/dist/index.js +// This file was generated by lezer-generator. You probably shouldn't edit it. +const i=[9,10,11,12,13,32,133,160,5760,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8232,8233,8239,8287,12288]; +/* Hand-written tokenizers for CSS tokens that can't be + expressed by Lezer's built-in tokenizer. */function a(e){return e>=65&&e<=90||e>=97&&e<=122||e>=161}function l(e){return e>=48&&e<=57}const s=new r/* ExternalTokenizer */.Lu(((e,t)=>{for(let n=!1,r=0,o=0;;o++){let{next:i}=e;if(a(i)||45==i||95==i||n&&l(i))!n&&(45!=i||o>0)&&(n=!0),r===o&&45==i&&r++,e.advance();else{if(92!=i||10==e.peek(1)){n&&e.acceptToken(40==i?101:2==r&&t.canShift(2)?2:102);break}e.advance(),e.next>-1&&e.advance(),n=!0}}})),c=new r/* ExternalTokenizer */.Lu((e=>{if(i.includes(e.peek(-1))){let{next:t}=e;(a(t)||95==t||35==t||46==t||91==t||58==t&&a(e.peek(1))||45==t||38==t)&&e.acceptToken(100)}})),u=new r/* ExternalTokenizer */.Lu((e=>{if(!i.includes(e.peek(-1))){let{next:t}=e;if(37==t&&(e.advance(),e.acceptToken(1)),a(t)){do{e.advance()}while(a(e.next)||l(e.next));e.acceptToken(1)}}})),d=(0,o/* styleTags */.pn)({"AtKeyword import charset namespace keyframes media supports":o/* tags */._A.definitionKeyword,"from to selector":o/* tags */._A.keyword,NamespaceName:o/* tags */._A.namespace,KeyframeName:o/* tags */._A.labelName,KeyframeRangeName:o/* tags */._A.operatorKeyword,TagName:o/* tags */._A.tagName,ClassName:o/* tags */._A.className,PseudoClassName:o/* tags */._A.constant(o/* tags */._A.className),IdName:o/* tags */._A.labelName,"FeatureName PropertyName":o/* tags */._A.propertyName,AttributeName:o/* tags */._A.attributeName,NumberLiteral:o/* tags */._A.number,KeywordQuery:o/* tags */._A.keyword,UnaryQueryOp:o/* tags */._A.operatorKeyword,"CallTag ValueName":o/* tags */._A.atom,VariableName:o/* tags */._A.variableName,Callee:o/* tags */._A.operatorKeyword,Unit:o/* tags */._A.unit,"UniversalSelector NestingSelector":o/* tags */._A.definitionOperator,MatchOp:o/* tags */._A.compareOperator,"ChildOp SiblingOp, LogicOp":o/* tags */._A.logicOperator,BinOp:o/* tags */._A.arithmeticOperator,Important:o/* tags */._A.modifier,Comment:o/* tags */._A.blockComment,ColorLiteral:o/* tags */._A.color,"ParenthesizedContent StringLiteral":o/* tags */._A.string,":":o/* tags */._A.punctuation,"PseudoOp #":o/* tags */._A.derefOperator,"; ,":o/* tags */._A.separator,"( )":o/* tags */._A.paren,"[ ]":o/* tags */._A.squareBracket,"{ }":o/* tags */._A.brace}),f={__proto__:null,lang:34,"nth-child":34,"nth-last-child":34,"nth-of-type":34,"nth-last-of-type":34,dir:34,"host-context":34,url:62,"url-prefix":62,domain:62,regexp:62,selector:140},h={__proto__:null,"@import":120,"@media":144,"@charset":148,"@namespace":152,"@keyframes":158,"@supports":170},p={__proto__:null,not:134,only:134},m=r/* LRParser */.U1.deserialize({version:14,states:":jQYQ[OOO#_Q[OOP#fOWOOOOQP'#Cd'#CdOOQP'#Cc'#CcO#kQ[O'#CfO$_QXO'#CaO$fQ[O'#CiO$qQ[O'#DUO$vQ[O'#DXOOQP'#En'#EnO${QdO'#DhO%jQ[O'#DuO${QdO'#DwO%{Q[O'#DyO&WQ[O'#D|O&`Q[O'#ESO&nQ[O'#EUOOQS'#Em'#EmOOQS'#EX'#EXQYQ[OOO&uQXO'#CdO'jQWO'#DdO'oQWO'#EsO'zQ[O'#EsQOQWOOP(UO#tO'#C_POOO)C@])C@]OOQP'#Ch'#ChOOQP,59Q,59QO#kQ[O,59QO(aQ[O'#E]O({QWO,58{O)TQ[O,59TO$qQ[O,59pO$vQ[O,59sO(aQ[O,59vO(aQ[O,59xO(aQ[O,59yO)`Q[O'#DcOOQS,58{,58{OOQP'#Cl'#ClOOQO'#DS'#DSOOQP,59T,59TO)gQWO,59TO)lQWO,59TOOQP'#DW'#DWOOQP,59p,59pOOQO'#DY'#DYO)qQ`O,59sOOQS'#Cq'#CqO${QdO'#CrO)yQvO'#CtO+ZQtO,5:SOOQO'#Cy'#CyO)lQWO'#CxO+oQWO'#CzO+tQ[O'#DPOOQS'#Ep'#EpOOQO'#Dk'#DkO+|Q[O'#DrO,[QWO'#EtO&`Q[O'#DpO,jQWO'#DsOOQO'#Eu'#EuO)OQWO,5:aO,oQpO,5:cOOQS'#D{'#D{O,wQWO,5:eO,|Q[O,5:eOOQO'#EO'#EOO-UQWO,5:hO-ZQWO,5:nO-cQWO,5:pOOQS-E8V-E8VO-kQdO,5:OO-{Q[O'#E_O.YQWO,5;_O.YQWO,5;_POOO'#EW'#EWP.eO#tO,58yPOOO,58y,58yOOQP1G.l1G.lO/[QXO,5:wOOQO-E8Z-E8ZOOQS1G.g1G.gOOQP1G.o1G.oO)gQWO1G.oO)lQWO1G.oOOQP1G/[1G/[O/iQ`O1G/_O0SQXO1G/bO0jQXO1G/dO1QQXO1G/eO1hQWO,59}O1mQ[O'#DTO1tQdO'#CpOOQP1G/_1G/_O${QdO1G/_O1{QpO,59^OOQS,59`,59`O${QdO,59bO2TQWO1G/nOOQS,59d,59dO2YQ!bO,59fOOQS'#DQ'#DQOOQS'#EZ'#EZO2eQ[O,59kOOQS,59k,59kO2mQWO'#DkO2xQWO,5:WO2}QWO,5:^O&`Q[O,5:YO&`Q[O'#E`O3VQWO,5;`O3bQWO,5:[O(aQ[O,5:_OOQS1G/{1G/{OOQS1G/}1G/}OOQS1G0P1G0PO3sQWO1G0PO3xQdO'#EPOOQS1G0S1G0SOOQS1G0Y1G0YOOQS1G0[1G0[O4TQtO1G/jOOQO1G/j1G/jOOQO,5:y,5:yO4kQ[O,5:yOOQO-E8]-E8]O4xQWO1G0yPOOO-E8U-E8UPOOO1G.e1G.eOOQP7+$Z7+$ZOOQP7+$y7+$yO${QdO7+$yOOQS1G/i1G/iO5TQXO'#ErO5[QWO,59oO5aQtO'#EYO6XQdO'#EoO6cQWO,59[O6hQpO7+$yOOQS1G.x1G.xOOQS1G.|1G.|OOQS7+%Y7+%YOOQS1G/Q1G/QO6pQWO1G/QOOQS-E8X-E8XOOQS1G/V1G/VO${QdO1G/rOOQO1G/x1G/xOOQO1G/t1G/tO6uQWO,5:zOOQO-E8^-E8^O7TQXO1G/yOOQS7+%k7+%kO7[QYO'#CtOOQO'#ER'#ERO7gQ`O'#EQOOQO'#EQ'#EQO7rQWO'#EaO7zQdO,5:kOOQS,5:k,5:kO8VQtO'#E^O${QdO'#E^O9WQdO7+%UOOQO7+%U7+%UOOQO1G0e1G0eO9kQpO<PAN>PO;]QdO,5:vOOQO-E8Y-E8YOOQO<T![;'S%^;'S;=`%o<%lO%^l;TUp`Oy%^z!Q%^!Q![;g![;'S%^;'S;=`%o<%lO%^l;nYp`#e[Oy%^z!Q%^!Q![;g![!g%^!g!h<^!h#X%^#X#Y<^#Y;'S%^;'S;=`%o<%lO%^l[[p`#e[Oy%^z!O%^!O!P;g!P!Q%^!Q![>T![!g%^!g!h<^!h#X%^#X#Y<^#Y;'S%^;'S;=`%o<%lO%^n?VSu^Oy%^z;'S%^;'S;=`%o<%lO%^l?hWkWOy%^z!O%^!O!P;O!P!Q%^!Q![>T![;'S%^;'S;=`%o<%lO%^n@VUZQOy%^z!Q%^!Q![;g![;'S%^;'S;=`%o<%lO%^~@nTkWOy%^z{@}{;'S%^;'S;=`%o<%lO%^~AUSp`#]~Oy%^z;'S%^;'S;=`%o<%lO%^lAg[#e[Oy%^z!O%^!O!P;g!P!Q%^!Q![>T![!g%^!g!h<^!h#X%^#X#Y<^#Y;'S%^;'S;=`%o<%lO%^bBbU^QOy%^z![%^![!]Bt!];'S%^;'S;=`%o<%lO%^bB{S_Qp`Oy%^z;'S%^;'S;=`%o<%lO%^nC^S!Z^Oy%^z;'S%^;'S;=`%o<%lO%^dCoS}SOy%^z;'S%^;'S;=`%o<%lO%^bDQU!PQOy%^z!`%^!`!aDd!a;'S%^;'S;=`%o<%lO%^bDkS!PQp`Oy%^z;'S%^;'S;=`%o<%lO%^bDzWOy%^z!c%^!c!}Ed!}#T%^#T#oEd#o;'S%^;'S;=`%o<%lO%^bEk[!]Qp`Oy%^z}%^}!OEd!O!Q%^!Q![Ed![!c%^!c!}Ed!}#T%^#T#oEd#o;'S%^;'S;=`%o<%lO%^nFfSr^Oy%^z;'S%^;'S;=`%o<%lO%^nFwSq^Oy%^z;'S%^;'S;=`%o<%lO%^bGWUOy%^z#b%^#b#cGj#c;'S%^;'S;=`%o<%lO%^bGoUp`Oy%^z#W%^#W#XHR#X;'S%^;'S;=`%o<%lO%^bHYS!cQp`Oy%^z;'S%^;'S;=`%o<%lO%^bHiUOy%^z#f%^#f#gHR#g;'S%^;'S;=`%o<%lO%^fIQS!UUOy%^z;'S%^;'S;=`%o<%lO%^nIcS!T^Oy%^z;'S%^;'S;=`%o<%lO%^fItU!SQOy%^z!_%^!_!`6y!`;'S%^;'S;=`%o<%lO%^`JZP;=`<%l$}",tokenizers:[c,u,s,1,2,3,4,new r/* LocalTokenGroup */.uC("m~RRYZ[z{a~~g~aO#_~~dP!P!Qg~lO#`~~",28,106)],topRules:{StyleSheet:[0,4],Styles:[1,87]},specialized:[{term:101,get:e=>f[e]||-1},{term:59,get:e=>h[e]||-1},{term:102,get:e=>p[e]||-1}],tokenPrec:1219}); +// EXTERNAL MODULE: ./node_modules/@codemirror/language/dist/index.js +var g=n(15874),v=n(90365); +// EXTERNAL MODULE: ./node_modules/@lezer/common/dist/index.js +// ./node_modules/@codemirror/lang-css/dist/index.js +let A=null;function y(){if(!A&&"object"==typeof document&&document.body){let{style:e}=document.body,t=[],n=new Set;for(let r in e)"cssText"!=r&&"cssFloat"!=r&&"string"==typeof e[r]&&(/[A-Z]/.test(r)&&(r=r.replace(/[A-Z]/g,(e=>"-"+e.toLowerCase()))),n.has(r)||(t.push(r),n.add(r)));A=t.sort().map((e=>({type:"property",label:e,apply:e+": "})))}return A||[]}const b=["active","after","any-link","autofill","backdrop","before","checked","cue","default","defined","disabled","empty","enabled","file-selector-button","first","first-child","first-letter","first-line","first-of-type","focus","focus-visible","focus-within","fullscreen","has","host","host-context","hover","in-range","indeterminate","invalid","is","lang","last-child","last-of-type","left","link","marker","modal","not","nth-child","nth-last-child","nth-last-of-type","nth-of-type","only-child","only-of-type","optional","out-of-range","part","placeholder","placeholder-shown","read-only","read-write","required","right","root","scope","selection","slotted","target","target-text","valid","visited","where"].map((e=>({type:"class",label:e}))),O=["above","absolute","activeborder","additive","activecaption","after-white-space","ahead","alias","all","all-scroll","alphabetic","alternate","always","antialiased","appworkspace","asterisks","attr","auto","auto-flow","avoid","avoid-column","avoid-page","avoid-region","axis-pan","background","backwards","baseline","below","bidi-override","blink","block","block-axis","bold","bolder","border","border-box","both","bottom","break","break-all","break-word","bullets","button","button-bevel","buttonface","buttonhighlight","buttonshadow","buttontext","calc","capitalize","caps-lock-indicator","caption","captiontext","caret","cell","center","checkbox","circle","cjk-decimal","clear","clip","close-quote","col-resize","collapse","color","color-burn","color-dodge","column","column-reverse","compact","condensed","contain","content","contents","content-box","context-menu","continuous","copy","counter","counters","cover","crop","cross","crosshair","currentcolor","cursive","cyclic","darken","dashed","decimal","decimal-leading-zero","default","default-button","dense","destination-atop","destination-in","destination-out","destination-over","difference","disc","discard","disclosure-closed","disclosure-open","document","dot-dash","dot-dot-dash","dotted","double","down","e-resize","ease","ease-in","ease-in-out","ease-out","element","ellipse","ellipsis","embed","end","ethiopic-abegede-gez","ethiopic-halehame-aa-er","ethiopic-halehame-gez","ew-resize","exclusion","expanded","extends","extra-condensed","extra-expanded","fantasy","fast","fill","fill-box","fixed","flat","flex","flex-end","flex-start","footnotes","forwards","from","geometricPrecision","graytext","grid","groove","hand","hard-light","help","hidden","hide","higher","highlight","highlighttext","horizontal","hsl","hsla","hue","icon","ignore","inactiveborder","inactivecaption","inactivecaptiontext","infinite","infobackground","infotext","inherit","initial","inline","inline-axis","inline-block","inline-flex","inline-grid","inline-table","inset","inside","intrinsic","invert","italic","justify","keep-all","landscape","large","larger","left","level","lighter","lighten","line-through","linear","linear-gradient","lines","list-item","listbox","listitem","local","logical","loud","lower","lower-hexadecimal","lower-latin","lower-norwegian","lowercase","ltr","luminosity","manipulation","match","matrix","matrix3d","medium","menu","menutext","message-box","middle","min-intrinsic","mix","monospace","move","multiple","multiple_mask_images","multiply","n-resize","narrower","ne-resize","nesw-resize","no-close-quote","no-drop","no-open-quote","no-repeat","none","normal","not-allowed","nowrap","ns-resize","numbers","numeric","nw-resize","nwse-resize","oblique","opacity","open-quote","optimizeLegibility","optimizeSpeed","outset","outside","outside-shape","overlay","overline","padding","padding-box","painted","page","paused","perspective","pinch-zoom","plus-darker","plus-lighter","pointer","polygon","portrait","pre","pre-line","pre-wrap","preserve-3d","progress","push-button","radial-gradient","radio","read-only","read-write","read-write-plaintext-only","rectangle","region","relative","repeat","repeating-linear-gradient","repeating-radial-gradient","repeat-x","repeat-y","reset","reverse","rgb","rgba","ridge","right","rotate","rotate3d","rotateX","rotateY","rotateZ","round","row","row-resize","row-reverse","rtl","run-in","running","s-resize","sans-serif","saturation","scale","scale3d","scaleX","scaleY","scaleZ","screen","scroll","scrollbar","scroll-position","se-resize","self-start","self-end","semi-condensed","semi-expanded","separate","serif","show","single","skew","skewX","skewY","skip-white-space","slide","slider-horizontal","slider-vertical","sliderthumb-horizontal","sliderthumb-vertical","slow","small","small-caps","small-caption","smaller","soft-light","solid","source-atop","source-in","source-out","source-over","space","space-around","space-between","space-evenly","spell-out","square","start","static","status-bar","stretch","stroke","stroke-box","sub","subpixel-antialiased","svg_masks","super","sw-resize","symbolic","symbols","system-ui","table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row","table-row-group","text","text-bottom","text-top","textarea","textfield","thick","thin","threeddarkshadow","threedface","threedhighlight","threedlightshadow","threedshadow","to","top","transform","translate","translate3d","translateX","translateY","translateZ","transparent","ultra-condensed","ultra-expanded","underline","unidirectional-pan","unset","up","upper-latin","uppercase","url","var","vertical","vertical-text","view-box","visible","visibleFill","visiblePainted","visibleStroke","visual","w-resize","wait","wave","wider","window","windowframe","windowtext","words","wrap","wrap-reverse","x-large","x-small","xor","xx-large","xx-small"].map((e=>({type:"keyword",label:e}))).concat(["aliceblue","antiquewhite","aqua","aquamarine","azure","beige","bisque","black","blanchedalmond","blue","blueviolet","brown","burlywood","cadetblue","chartreuse","chocolate","coral","cornflowerblue","cornsilk","crimson","cyan","darkblue","darkcyan","darkgoldenrod","darkgray","darkgreen","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dodgerblue","firebrick","floralwhite","forestgreen","fuchsia","gainsboro","ghostwhite","gold","goldenrod","gray","grey","green","greenyellow","honeydew","hotpink","indianred","indigo","ivory","khaki","lavender","lavenderblush","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgray","lightgreen","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","lightsteelblue","lightyellow","lime","limegreen","linen","magenta","maroon","mediumaquamarine","mediumblue","mediumorchid","mediumpurple","mediumseagreen","mediumslateblue","mediumspringgreen","mediumturquoise","mediumvioletred","midnightblue","mintcream","mistyrose","moccasin","navajowhite","navy","oldlace","olive","olivedrab","orange","orangered","orchid","palegoldenrod","palegreen","paleturquoise","palevioletred","papayawhip","peachpuff","peru","pink","plum","powderblue","purple","rebeccapurple","red","rosybrown","royalblue","saddlebrown","salmon","sandybrown","seagreen","seashell","sienna","silver","skyblue","slateblue","slategray","snow","springgreen","steelblue","tan","teal","thistle","tomato","turquoise","violet","wheat","white","whitesmoke","yellow","yellowgreen"].map((e=>({type:"constant",label:e})))),w=["a","abbr","address","article","aside","b","bdi","bdo","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","dd","del","details","dfn","dialog","div","dl","dt","em","figcaption","figure","footer","form","header","hgroup","h1","h2","h3","h4","h5","h6","hr","html","i","iframe","img","input","ins","kbd","label","legend","li","main","meter","nav","ol","output","p","pre","ruby","section","select","small","source","span","strong","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","tr","u","ul"].map((e=>({type:"type",label:e}))),x=["@charset","@color-profile","@container","@counter-style","@font-face","@font-feature-values","@font-palette-values","@import","@keyframes","@layer","@media","@namespace","@page","@position-try","@property","@scope","@starting-style","@supports","@view-transition"].map((e=>({type:"keyword",label:e}))),_=/^(\w[\w-]*|-\w[\w-]*|)$/,C=/^-(-[\w-]*)?$/;const k=new v/* NodeWeakMap */.RY,S=["Declaration"];function V(e){for(let t=e;;){if(t.type.isTop)return t;if(!(t=t.parent))return e}}function B(e,t,n){if(t.to-t.from>4096){let r=k.get(t);if(r)return r;let o=[],i=new Set,a=t.cursor(v/* IterMode */.Qj.IncludeAnonymous);if(a.firstChild())do{for(let t of B(e,a.node,n))i.has(t.label)||(i.add(t.label),o.push(t))}while(a.nextSibling());return k.set(t,o),o}{let r=[],o=new Set;return t.cursor().iterate((t=>{var i;if(n(t)&&t.matchContext(S)&&":"==(null===(i=t.node.nextSibling)||void 0===i?void 0:i.name)){let n=e.sliceString(t.from,t.to);o.has(n)||(o.add(n),r.push({label:n,type:"variable"}))}})),r}} +/** +Create a completion source for a CSS dialect, providing a +predicate for determining what kind of syntax node can act as a +completable variable. This is used by language modes like Sass and +Less to reuse this package's completion logic. +*/const T=e=>t=>{let{state:n,pos:r}=t,o=(0,g/* syntaxTree */.mv)(n).resolveInner(r,-1),i=o.type.isError&&o.from==o.to-1&&"-"==n.doc.sliceString(o.from,o.to);if("PropertyName"==o.name||(i||"TagName"==o.name)&&/^(Block|Styles)$/.test(o.resolve(o.to).name))return{from:o.from,options:y(),validFor:_};if("ValueName"==o.name)return{from:o.from,options:O,validFor:_};if("PseudoClassName"==o.name)return{from:o.from,options:b,validFor:_};if(e(o)||(t.explicit||i)&&function(e,t){var n;if(("("==e.name||e.type.isError)&&(e=e.parent||e),"ArgList"!=e.name)return!1;let r=null===(n=e.parent)||void 0===n?void 0:n.firstChild;return"Callee"==(null==r?void 0:r.name)&&"var"==t.sliceString(r.from,r.to)}(o,n.doc))return{from:e(o)||i?o.from:r,options:B(n.doc,V(o),e),validFor:C};if("TagName"==o.name){for(let{parent:e}=o;e;e=e.parent)if("Block"==e.name)return{from:o.from,options:y(),validFor:_};return{from:o.from,options:w,validFor:_}}if("AtKeyword"==o.name)return{from:o.from,options:x,validFor:_};if(!t.explicit)return null;let a=o.resolve(r),l=a.childBefore(r);return l&&":"==l.name&&"PseudoClassSelector"==a.name?{from:r,options:b,validFor:_}:l&&":"==l.name&&"Declaration"==a.name||"ArgList"==a.name?{from:r,options:O,validFor:_}:"Block"==a.name||"Styles"==a.name?{from:r,options:y(),validFor:_}:null} +/** +CSS property, variable, and value keyword completion source. +*/,N=T((e=>"VariableName"==e.name)),E=g/* LRLanguage */.bj.define({name:"css",parser:m.configure({props:[ +g/* indentNodeProp */.Oh.add({Declaration:(0,g/* continuedIndent */.mz)()}), +g/* foldNodeProp */.b_.add({"Block KeyframeList":g/* foldInside */.yd})]}),languageData:{commentTokens:{block:{open:"/*",close:"*/"}},indentOnInput:/^\s*\}$/,wordChars:"-"}}); +/** +Language support for CSS. +*/ +function P(){return new g/* LanguageSupport */.Yy(E,E.data.of({autocomplete:N}))} +/***/}, +/***/6423: +/***/function(e,t,n){"use strict"; +// ESM COMPAT FLAG +n.r(t), +// EXPORTS +n.d(t,{default:function(){/* binding */return d}}); +// EXTERNAL MODULE: ./node_modules/core-js/modules/es.iterator.constructor.js +n(18111),n(81148); +// EXTERNAL MODULE: ./node_modules/core-js/modules/es.iterator.every.js +var r=n(61431),o=n.p+"static/img/cronexpress.03676134.png";// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/views/monitorManage/crontab/components/crontabModule.vue?vue&type=template&id=1c71c54b +const i={style:{display:"flex","align-items":"center"}};// ./src/views/monitorManage/crontab/components/crontabModule.vue?vue&type=template&id=1c71c54b +// EXTERNAL MODULE: ./src/api/api.js +var a=n(40412),l=n(48404),s=n(57192),c=n(37741),u={name:"crontabModule",components:{cronExpression:s.default,LyDialog:l/* default */.A},emits:["refreshData"],data(){return{dialogVisible:!1,loadingSave:!1,loadingTitle:"",formData:{type:0,name:"",crontab:"",task:"",interval:{every:null,period:null},one_off:!1,enabled:!1,args:"[]",description:""},rules:{name:[{required:!0,message:"请输入任务名称",trigger:"blur"}], +// crontab: [ +// {required: true, message: '请输入cron表达式',trigger: 'blur'} +// ], +task:[{required:!0,message:"请输入celery任务方法",trigger:"blur"}]},taskList:[],cronPopover:!1,intervalList:[{id:"days",name:"天"},{id:"hours",name:"小时"},{id:"minutes",name:"分钟"},{id:"seconds",name:"秒"},{id:"microseconds",name:"微秒"}]}},methods:{handleClose(){this.dialogVisible=!1,this.loadingSave=!1,this.formData={type:0,name:"",crontab:"",task:"",interval:{every:null,period:null},one_off:!1,enabled:!1,args:"[]",description:""},this.cronPopover=!1},addModuleFn(e,t){this.loadingTitle=t,this.dialogVisible=!0,this.getTasklist(),e&&(this.formData=(0,c.deepClone)(e))},getTasklist(){(0,a.crontabPeriodictaskMethodlist)().then((e=>{2e3==e.code&&(this.taskList=e.data.data)}))},togglePopover(e){this.cronPopover=e},changeCron(e){if("string"!=typeof e)return!1;this.formData.crontab=e},submitData(){this.$refs.rulesForm.validate((e=>{if(e){this.loadingSave=!0;let e={...this.formData}; +// if(param.type === '0'){ +// if(param.password == ""){ +// this.loadingSave=false +// this.$message.warning("密码不能为空") +// return +// } +// } +if(1===e.type&&""==e.crontab)return this.loadingSave=!1,void this.$message.warning("执行时间不能为空");if(0===e.type&&(null==e.interval.every||""==e.interval.every||null==e.interval.period||""==e.interval.period))return this.loadingSave=!1,void this.$message.warning("执行时间不能为空");this.formData.id?(0,a.crontabPeriodictaskEdit)(e).then((e=>{this.loadingSave=!1,2e3==e.code?(this.$message.success(e.msg),this.handleClose(),this.$emit("refreshData")):this.$message.warning(e.msg)})):(0,a.crontabPeriodictaskAdd)(e).then((e=>{this.loadingSave=!1,2e3==e.code?(this.$message.success(e.msg),this.handleClose(),this.$emit("refreshData")):this.$message.warning(e.msg)}))}}))},imgBeforeUpload(e){const t="image/jpeg"===e.type||"image/png"===e.type;return t||(this.$message.error("图片只能是 JPG/PNG 格式!"),!1)},async imgUploadRequest(e){let t=await(0,a.platformsettingsUploadPlatformImg)(e);if(2e3==t.code){let e="";e=t.data.data[0].indexOf("://")>=0?t.data.data[0]:url.split("/api")[0]+t.data.data[0],this.formData.avatar=e}else this.$message.warning(res.msg)},imgUploadSuccess(){this.$refs.uploadDefaultImage.clearFiles()}}}; +// EXTERNAL MODULE: ./src/components/dialog/dialog.vue + 6 modules +/* harmony default export */var d=(0,n(66262).A)(u,[["render",function(e,t,n,a,l,s){const c=(0,r.resolveComponent)("el-input"),u=(0,r.resolveComponent)("el-form-item"),d=(0,r.resolveComponent)("el-radio-button"),f=(0,r.resolveComponent)("el-radio-group"),h=(0,r.resolveComponent)("el-input-number"),p=(0,r.resolveComponent)("el-option"),m=(0,r.resolveComponent)("el-select"),g=(0,r.resolveComponent)("el-row"),v=(0,r.resolveComponent)("Clock"),A=(0,r.resolveComponent)("el-icon"),y=(0,r.resolveComponent)("el-button"),b=(0,r.resolveComponent)("el-alert"),O=(0,r.resolveComponent)("cron-expression"),w=(0,r.resolveComponent)("el-drawer"),x=(0,r.resolveComponent)("QuestionFilled"),_=(0,r.resolveComponent)("el-tooltip"),C=(0,r.resolveComponent)("el-switch"),k=(0,r.resolveComponent)("el-form"),S=(0,r.resolveComponent)("ly-dialog");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[(0,r.createVNode)(S,{modelValue:l.dialogVisible,"onUpdate:modelValue":t[13]||(t[13]=e=>l.dialogVisible=e),title:l.loadingTitle,width:"750px","before-close":s.handleClose},{footer:(0,r.withCtx)((()=>[(0,r.createVNode)(y,{onClick:s.handleClose,loading:l.loadingSave},{default:(0,r.withCtx)((()=>t[20]||(t[20]=[(0,r.createTextVNode)("取消")]))),_:1},8,["onClick","loading"]),(0,r.createVNode)(y,{type:"primary",onClick:s.submitData,loading:l.loadingSave},{default:(0,r.withCtx)((()=>t[21]||(t[21]=[(0,r.createTextVNode)("确定")]))),_:1},8,["onClick","loading"])])),default:(0,r.withCtx)((()=>[(0,r.createVNode)(k,{inline:!1,model:l.formData,rules:l.rules,ref:"rulesForm","label-position":"right","label-width":"auto"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(u,{label:"任务名称:",prop:"name"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(c,{modelValue:l.formData.name,"onUpdate:modelValue":t[0]||(t[0]=e=>l.formData.name=e),disabled:"编辑"===l.loadingTitle},null,8,["modelValue","disabled"])])),_:1}),(0,r.createVNode)(u,{label:"任务类型:",prop:"type"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(f,{modelValue:l.formData.type,"onUpdate:modelValue":t[1]||(t[1]=e=>l.formData.type=e),disabled:"编辑"==l.loadingTitle},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(d,{value:0},{default:(0,r.withCtx)((()=>t[14]||(t[14]=[(0,r.createTextVNode)("间隔任务")]))),_:1}),(0,r.createVNode)(d,{value:1},{default:(0,r.withCtx)((()=>t[15]||(t[15]=[(0,r.createTextVNode)("周期任务")]))),_:1})])),_:1},8,["modelValue","disabled"])])),_:1}),0==l.formData.type?((0,r.openBlock)(),(0,r.createBlock)(u,{key:0,label:"执行时间:",class:"is-required"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(g,null,{default:(0,r.withCtx)((()=>[t[16]||(t[16]=(0,r.createTextVNode)(" 每隔 ")),(0,r.createVNode)(h,{modelValue:l.formData.interval.every,"onUpdate:modelValue":t[2]||(t[2]=e=>l.formData.interval.every=e),min:0,style:{margin:"0 5px 0 5px"}},null,8,["modelValue"]),(0,r.createVNode)(m,{modelValue:l.formData.interval.period,"onUpdate:modelValue":t[3]||(t[3]=e=>l.formData.interval.period=e),style:{width:"150px"}},{default:(0,r.withCtx)((()=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(l.intervalList,(e=>((0,r.openBlock)(),(0,r.createBlock)(p,{key:e.id,label:e.name,value:e.id},null,8,["label","value"])))),128))])),_:1},8,["modelValue"])])),_:1})])),_:1})):(0,r.createCommentVNode)("",!0),1==l.formData.type?((0,r.openBlock)(),(0,r.createBlock)(u,{key:1,label:"执行时间:",prop:"crontab",class:"is-required"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(c,{modelValue:l.formData.crontab,"onUpdate:modelValue":t[5]||(t[5]=e=>l.formData.crontab=e),placeholder:"* * * * *"},{append:(0,r.withCtx)((()=>[(0,r.createVNode)(y,{type:"primary",onClick:t[4]||(t[4]=e=>s.togglePopover(!0))},{default:(0,r.withCtx)((()=>[t[17]||(t[17]=(0,r.createTextVNode)("生成表达式")),(0,r.createVNode)(A,null,{default:(0,r.withCtx)((()=>[(0,r.createVNode)(v)])),_:1})])),_:1})])),_:1},8,["modelValue"]),(0,r.createVNode)(b,{type:"info"},{default:(0,r.withCtx)((()=>t[18]||(t[18]=[(0,r.createElementVNode)("img",{src:o,style:{width:"100%"}},null,-1)]))),_:1}),(0,r.createVNode)(w,{modelValue:l.cronPopover,"onUpdate:modelValue":t[7]||(t[7]=e=>l.cronPopover=e),title:"cron表达式辅助工具",size:"35%","show-close":!1},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(O,{onChange:s.changeCron,onClose:t[6]||(t[6]=e=>s.togglePopover(!1)),"max-height":"400px",i18n:"cn"},null,8,["onChange"])])),_:1},8,["modelValue"])])),_:1})):(0,r.createCommentVNode)("",!0),(0,r.createVNode)(u,{label:"执行方法:",prop:"task"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(m,{modelValue:l.formData.task,"onUpdate:modelValue":t[8]||(t[8]=e=>l.formData.task=e),placeholder:"请输入或选择","allow-create":"",filterable:"",clearable:"",style:{width:"100%"}},{default:(0,r.withCtx)((()=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(l.taskList,(e=>((0,r.openBlock)(),(0,r.createBlock)(p,{key:e.label,label:e.label,value:e.value},null,8,["label","value"])))),128))])),_:1},8,["modelValue"]),(0,r.createVNode)(b,{title:"Celery任务调用示例:apps.lycrontab.tasks.lytask_test",type:"info","show-icon":""})])),_:1}),(0,r.createVNode)(u,{label:"任务参数:",prop:"args"},{label:(0,r.withCtx)((()=>[(0,r.createElementVNode)("span",i,[t[19]||(t[19]=(0,r.createTextVNode)(" 任务参数: ")),(0,r.createVNode)(_,{effect:"dark",content:'参数若为空则填入[],需要传递参数则直接在数组写值即可:如["a","b"]',placement:"top-start"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(A,null,{default:(0,r.withCtx)((()=>[(0,r.createVNode)(x)])),_:1})])),_:1})])])),default:(0,r.withCtx)((()=>[(0,r.createVNode)(c,{modelValue:l.formData.args,"onUpdate:modelValue":t[9]||(t[9]=e=>l.formData.args=e),placeholder:'参数为数组形式,如:["a","b"]'},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(u,{label:"一次性任务:",prop:"enabled"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(C,{modelValue:l.formData.one_off,"onUpdate:modelValue":t[10]||(t[10]=e=>l.formData.one_off=e),"active-text":"是","inactive-text":"否","active-color":"#13ce66","inactive-color":"#ff4949"},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(u,{label:"状态:",prop:"enabled"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(C,{modelValue:l.formData.enabled,"onUpdate:modelValue":t[11]||(t[11]=e=>l.formData.enabled=e),"active-text":"正常","inactive-text":"停止","active-color":"#13ce66","inactive-color":"#ff4949"},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(u,{label:"备注:",prop:"description"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(c,{modelValue:l.formData.description,"onUpdate:modelValue":t[12]||(t[12]=e=>l.formData.description=e),type:"textarea",rows:2},null,8,["modelValue"])])),_:1})])),_:1},8,["model","rules"])])),_:1},8,["modelValue","title","before-close"])])}]]); +/***/}, +/***/6666: +/***/function(e,t,n){"use strict"; +/* harmony import */var r=n(98026),o=n(43870),i=n(12616),a=n(30693),l=n(48170),s=n(34833),c=n(49431),u=n(87582),d=n(43199),f=l/* .makeInner */.$r(),h=(0,u/* ["default"] */.A)(),p=/** @class */function(){function e(){this.group=new o/* ["default"] */.A,this.uid=i/* .getUID */.$Q("viewChart"),this.renderTask=(0,c/* .createTask */.U)({plan:v,reset:A}),this.renderTask.context={view:this}}return e.prototype.init=function(e,t){},e.prototype.render=function(e,t,n,r){0}, +/** + * Highlight series or specified data item. + */ +e.prototype.highlight=function(e,t,n,r){var o=e.getData(r&&r.dataType);o&&g(o,r,"emphasis")}, +/** + * Downplay series or specified data item. + */ +e.prototype.downplay=function(e,t,n,r){var o=e.getData(r&&r.dataType);o&&g(o,r,"normal")}, +/** + * Remove self. + */ +e.prototype.remove=function(e,t){this.group.removeAll()}, +/** + * Dispose self. + */ +e.prototype.dispose=function(e,t){},e.prototype.updateView=function(e,t,n,r){this.render(e,t,n,r)}, +// FIXME never used? +e.prototype.updateLayout=function(e,t,n,r){this.render(e,t,n,r)}, +// FIXME never used? +e.prototype.updateVisual=function(e,t,n,r){this.render(e,t,n,r)}, +/** + * Traverse the new rendered elements. + * + * It will traverse the new added element in progressive rendering. + * And traverse all in normal rendering. + */ +e.prototype.eachRendered=function(e){(0,d.traverseElements)(this.group,e)},e.markUpdateMethod=function(e,t){f(e).updateMethod=t},e.protoInitialize=void(e.prototype.type="chart"),e}(); +/* harmony import */ +/** + * Set state of single element + */ +function m(e,t,n){e&&(0,s/* .isHighDownDispatcher */.u6)(e)&&("emphasis"===t?s/* .enterEmphasis */.HY:s/* .leaveEmphasis */.SD)(e,n)}function g(e,t,n){var o=l/* .queryDataIndex */.le(e,t),i=t&&null!=t.highlightKey?(0,s/* .getHighlightDigit */._n)(t.highlightKey):null;null!=o?(0/* .normalizeToArray */,r.each)(l.qB(o),(function(t){m(e.getItemGraphicEl(t),n,i)})):e.eachItemGraphicEl((function(e){m(e,n,i)}))}function v(e){return h(e.model)}function A(e){var t=e.model,n=e.ecModel,r=e.api,o=e.payload,i=t.pipelineContext.progressiveRender,a=e.view,l=o&&f(o).updateMethod,s=i?"incrementalPrepareRender":l&&a[l]?l:"render";return"render"!==s&&a[s](t,n,r,o),y[s]}a/* .enableClassExtend */.gq(p,["dispose"]),a/* .enableClassManagement */.tQ(p);var y={incrementalPrepareRender:{progress:function(e,t){t.view.incrementalRender(e,t.model,t.ecModel,t.api,t.payload)}},render:{ +// Put view.render in `progress` to support appendData. But in this case +// view.render should not be called in reset, otherwise it will be called +// twise. Use `forceFirstProgress` to make sure that view.render is called +// in any cases. +forceFirstProgress:!0,progress:function(e,t){t.view.render(t.model,t.ecModel,t.api,t.payload)}}}; +/* harmony default export */t.A=p}, +/***/6756: +/***/function(e,t,n){"use strict"; +// EXPORTS +n.d(t,{a:function(){/* binding */return G}}); +// EXTERNAL MODULE: ./node_modules/zrender/lib/core/util.js +var r=n(98026),o=n(62536),i=n(37959),a=n(15215),l=n(98908),s=n(40446),c=n(12616),u=/** @class */function(e){function t(){var n=null!==e&&e.apply(this,arguments)||this;return n.type=t.type,n}return(0,a/* __extends */.C6)(t,e),t.prototype.getInitialData=function(){return(0,s/* default */.A)(null,this,{useEncodeDefaulter:!0,createInvertedIndices:!!this.get("realtimeSort",!0)||null})}, +/** + * @override + */ +t.prototype.getProgressive=function(){ +// Do not support progressive in normal mode. +return!!this.get("large")&&this.get("progressive")}, +/** + * @override + */ +t.prototype.getProgressiveThreshold=function(){ +// Do not support progressive in normal mode. +var e=this.get("progressiveThreshold"),t=this.get("largeThreshold");return t>e&&(e=t),e},t.prototype.brushSelector=function(e,t,n){return n.rect(t.getItemLayout(e))},t.type="series.bar",t.dependencies=["grid","polar"],t.defaultOption=(0/* default */,c/* inheritDefaultOption */.G_)(l.A.defaultOption,{ +// If clipped +// Only available on cartesian2d +clip:!0,roundCap:!1,showBackground:!1,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)",borderColor:null,borderWidth:0,borderType:"solid",borderRadius:0,shadowBlur:0,shadowColor:null,shadowOffsetX:0,shadowOffsetY:0,opacity:1},select:{itemStyle:{borderColor:"#212121"}},realtimeSort:!1}),t}(l/* default */.A),d=u,f=n(5070),h=n(43870),p=n(43199),m=n(5638),g=n(10992),v=n(59975),A=n(69622),y=n(34833),b=n(89632),O=n(24711),w=n(95235),x=n(84618),_=n(6666),C=n(41849),k=n(44532),S=n(45558); +// EXTERNAL MODULE: ./node_modules/echarts/lib/layout/barGrid.js +function V(e,t,n){return t*Math.sin(e)*(n?-1:1)}function B(e,t,n){return t*Math.cos(e)*(n?1:-1)} +// EXTERNAL MODULE: ./node_modules/echarts/lib/chart/helper/sectorHelper.js +var T=n(79446),N=Math.max,E=Math.min;var P=/** @class */function(e){function t(){var n=e.call(this)||this;return n.type=t.type,n._isFirstFrame=!0,n}return(0,a/* __extends */.C6)(t,e),t.prototype.render=function(e,t,n,r){this._model=e,this._removeOnRenderedListener(n),this._updateDrawMode(e);var o=e.get("coordinateSystem");("cartesian2d"===o||"polar"===o)&&( +// Clear previously rendered progressive elements. +this._progressiveEls=null,this._isLargeDraw?this._renderLarge(e,t,n):this._renderNormal(e,t,n,r))},t.prototype.incrementalPrepareRender=function(e){this._clear(),this._updateDrawMode(e), +// incremental also need to clip, otherwise might be overlow. +// But must not set clip in each frame, otherwise all of the children will be marked redraw. +this._updateLargeClip(e)},t.prototype.incrementalRender=function(e,t){ +// Reset +this._progressiveEls=[], +// Do not support progressive in normal mode. +this._incrementalRenderLarge(e,t)},t.prototype.eachRendered=function(e){(0,p.traverseElements)(this._progressiveEls||this.group,e)},t.prototype._updateDrawMode=function(e){var t=e.pipelineContext.large;null!=this._isLargeDraw&&t===this._isLargeDraw||(this._isLargeDraw=t,this._clear())},t.prototype._renderNormal=function(e,t,n,r){var o,i=this.group,a=e.getData(),l=this._data,s=e.coordinateSystem,c=s.getBaseAxis();"cartesian2d"===s.type?o=c.isHorizontal():"polar"===s.type&&(o="angle"===c.dim);var u=e.isAnimationEnabled()?e:null,d=function(e,t){var n=e.get("realtimeSort",!0),r=t.getBaseAxis();0;if(n&&"category"===r.type&&"cartesian2d"===t.type)return{baseAxis:r,otherAxis:t.getOtherAxis(r)}}(e,s);d&&this._enableRealtimeSort(d,a,n);var f=e.get("clip",!0)||d,p=function(e,t){var n=e.getArea&&e.getArea();if((0,C/* isCoordinateSystemType */.g)(e,"cartesian2d")){var r=e.getBaseAxis(); +// When boundaryGap is false or using time axis. bar may exceed the grid. +// We should not clip this part. +// See test/bar2.html +if("category"!==r.type||!r.onBand){var o=t.getLayout("bandWidth");r.isHorizontal()?(n.x-=o,n.width+=2*o):(n.y-=o,n.height+=2*o)}}return n}(s,a); +// If there is clipPath created in large mode. Remove it. +i.removeClipPath(); +// We don't use clipPath in normal mode because we needs a perfect animation +// And don't want the label are clipped. +var A=e.get("roundCap",!0),y=e.get("showBackground",!0),O=e.getModel("backgroundStyle"),w=O.get("borderRadius")||0,x=[],_=this._backgroundEls,k=r&&r.isInitSort,S=r&&"changeAxisOrder"===r.type;function V(e){var t=L[s.type](a,e),n=function(e,t,n){var r="polar"===e.type?v/* default */.A:g/* default */.A;return new r({shape:X(t,n,e),silent:!0,z2:0})} +/* harmony default export */(s,o,t);return n.useStyle(O.getItemStyle()), +// Only cartesian2d support borderRadius. +"cartesian2d"===s.type?n.setShape("r",w):n.setShape("cornerRadius",w),x[e]=n,n}a.diff(l).add((function(t){var n=a.getItemModel(t),r=L[s.type](a,t,n); +// If dataZoom in filteMode: 'empty', the baseValue can be set as NaN in "axisProxy". +if(y&&V(t),a.hasValue(t)&&I[s.type](r)){var l=!1;f&&( +// Clip will modify the layout params. +// And return a boolean to determine if the shape are fully clipped. +l=Q[s.type](p,r));var h=M[s.type](e,a,t,r,o,u,c.model,!1,A);d&&( +/** + * Force label animation because even if the element is + * ignored because it's clipped, it may not be clipped after + * changing order. Then, if not using forceLabelAnimation, + * the label animation was never started, in which case, + * the label will be the final value and doesn't have label + * animation. + */ +h.forceLabelAnimation=!0),U(h,a,t,n,r,e,o,"polar"===s.type),k?h.attr({shape:r}):d?D(d,u,h,r,t,o,!1,!1):(0,m/* initProps */.LW)(h,{shape:r},e,t),a.setItemGraphicEl(t,h),i.add(h),h.ignore=l}})).update((function(t,n){var r=a.getItemModel(t),h=L[s.type](a,t,r);if(y){var g=void 0;0===_.length?g=V(n):((g=_[n]).useStyle(O.getItemStyle()), +// Only cartesian2d support borderRadius. +"cartesian2d"===s.type?g.setShape("r",w):g.setShape("cornerRadius",w),x[t]=g);var v=L[s.type](a,t),C=X(o,v,s);(0,m/* updateProps */.oi)(g,{shape:C},u,t)}var B=l.getItemGraphicEl(n);if(a.hasValue(t)&&I[s.type](h)){var T=!1;if(f&&(T=Q[s.type](p,h))&&i.remove(B),B?(0,m/* saveOldStyle */.ap)(B):B=M[s.type](e,a,t,h,o,u,c.model,!!B,A),d&&(B.forceLabelAnimation=!0),S){var N=B.getTextContent();if(N){var E=(0,b/* labelInner */.Lu)(N);null!=E.prevValue&&( +/** + * Set preValue to be value so that no new label + * should be started, otherwise, it will take a full + * `animationDurationUpdate` time to finish the + * animation, which is not expected. + */ +E.prevValue=E.value)}} +// Not change anything if only order changed. +// Especially not change label. +else U(B,a,t,r,h,e,o,"polar"===s.type);k?B.attr({shape:h}):d?D(d,u,B,h,t,o,!0,S):(0,m/* updateProps */.oi)(B,{shape:h},e,t,null),a.setItemGraphicEl(t,B),B.ignore=T,i.add(B)}else i.remove(B)})).remove((function(t){var n=l.getItemGraphicEl(t);n&&(0,m/* removeElementWithFadeOut */.t5)(n,e,t)})).execute();var B=this._backgroundGroup||(this._backgroundGroup=new h/* default */.A);B.removeAll();for(var T=0;Ti)return!0;i=c}return!1}, +/* + * Consider the case when A and B changed order, whose representing + * bars are both out of sight, we don't wish to trigger reorder action + * as long as the order in the view doesn't change. + */ +t.prototype._isOrderDifferentInView=function(e,t){for(var n=t.scale,r=n.getExtent(),o=Math.max(0,r[0]),i=Math.min(r[1],n.getOrdinalMeta().categories.length-1);o<=i;++o)if(e.ordinalNumbers[o]!==n.getRawOrdinalNumber(o))return!0},t.prototype._updateSortWithinSameData=function(e,t,n,r){if(this._isOrderChangedWithinSameData(e,t,n)){var o=this._dataSort(e,n,t);this._isOrderDifferentInView(o,n)&&(this._removeOnRenderedListener(r),r.dispatchAction({type:"changeAxisOrder",componentType:n.dim+"Axis",axisId:n.index,sortInfo:o}))}},t.prototype._dispatchInitSort=function(e,t,n){var r=t.baseAxis,o=this._dataSort(e,r,(function(n){return e.get(e.mapDimension(t.otherAxis.dim),n)}));n.dispatchAction({type:"changeAxisOrder",componentType:r.dim+"Axis",isInitSort:!0,axisId:r.index,sortInfo:o})},t.prototype.remove=function(e,t){this._clear(this._model),this._removeOnRenderedListener(t)},t.prototype.dispose=function(e,t){this._removeOnRenderedListener(t)},t.prototype._removeOnRenderedListener=function(e){this._onRendered&&(e.getZr().off("rendered",this._onRendered),this._onRendered=null)},t.prototype._clear=function(e){var t=this.group,n=this._data;e&&e.isAnimationEnabled()&&n&&!this._isLargeDraw?(this._removeBackground(),this._backgroundEls=[],n.eachItemGraphicEl((function(t){(0,m/* removeElementWithFadeOut */.t5)(t,e,(0,A/* getECData */.z)(t).dataIndex)}))):t.removeAll(),this._data=null,this._isFirstFrame=!0},t.prototype._removeBackground=function(){this.group.remove(this._backgroundGroup),this._backgroundGroup=null},t.type="bar",t}(_/* default */.A),Q={cartesian2d:function(e,t){var n=t.width<0?-1:1,r=t.height<0?-1:1; +// Needs positive width and height +n<0&&(t.x+=t.width,t.width=-t.width),r<0&&(t.y+=t.height,t.height=-t.height);var o=e.x+e.width,i=e.y+e.height,a=N(t.x,e.x),l=E(t.x+t.width,o),s=N(t.y,e.y),c=E(t.y+t.height,i),u=lo?l:a,t.y=d&&s>i?c:s,t.width=u?0:l-a,t.height=d?0:c-s, +// Reverse back +n<0&&(t.x+=t.width,t.width=-t.width),r<0&&(t.y+=t.height,t.height=-t.height),u||d},polar:function(e,t){var n=t.r0<=t.r?1:-1; +// Make sure r is larger than r0 +if(n<0){var r=t.r;t.r=t.r0,t.r0=r}var o=E(t.r,e.r),i=N(t.r0,e.r0);t.r=o,t.r0=i;var a=o-i<0; +// Reverse back +if(n<0){r=t.r;t.r=t.r0,t.r0=r}return a}},M={cartesian2d:function(e,t,n,o,i,a,l,s,c){var u=new g/* default */.A({shape:(0,r.extend)({},o),z2:1});(u.__dataIndex=n,u.name="item",a)&&(u.shape[i?"height":"width"]=0);return u},polar:function(e,t,n,r,o,i,a,l,s){var c=!o&&s?x/* default */.A:v/* default */.A,u=new c({shape:r,z2:1});u.name="item";var d,f,h,p=F(o); +// Animation +if(u.calculateTextPosition=(d=p,f={isRoundCap:c===x/* default */.A},h=(f=f||{}).isRoundCap,function(e,t,n){var r=t.position;if(!r||r instanceof Array)return(0,S/* calculateTextPosition */.X4)(e,t,n);var o=d(r),i=null!=t.distance?t.distance:5,a=this.shape,l=a.cx,s=a.cy,c=a.r,u=a.r0,f=(c+u)/2,p=a.startAngle,m=a.endAngle,g=(p+m)/2,v=h?Math.abs(c-u)/2:0,A=Math.cos,y=Math.sin,b=l+c*A(p),O=s+c*y(p),w="left",x="top";switch(o){case"startArc":b=l+(u-i)*A(g),O=s+(u-i)*y(g),w="center",x="top";break;case"insideStartArc":b=l+(u+i)*A(g),O=s+(u+i)*y(g),w="center",x="bottom";break;case"startAngle":b=l+f*A(p)+V(p,i+v,!1),O=s+f*y(p)+B(p,i+v,!1),w="right",x="middle";break;case"insideStartAngle":b=l+f*A(p)+V(p,-i+v,!1),O=s+f*y(p)+B(p,-i+v,!1),w="left",x="middle";break;case"middle":b=l+f*A(g),O=s+f*y(g),w="center",x="middle";break;case"endArc":b=l+(c+i)*A(g),O=s+(c+i)*y(g),w="center",x="bottom";break;case"insideEndArc":b=l+(c-i)*A(g),O=s+(c-i)*y(g),w="center",x="top";break;case"endAngle":b=l+f*A(m)+V(m,i+v,!0),O=s+f*y(m)+B(m,i+v,!0),w="left",x="middle";break;case"insideEndAngle":b=l+f*A(m)+V(m,-i+v,!0),O=s+f*y(m)+B(m,-i+v,!0),w="right",x="middle";break;default:return(0,S/* calculateTextPosition */.X4)(e,t,n)}return(e=e||{}).x=b,e.y=O,e.align=w,e.verticalAlign=x,e}),i){var g=o?"r":"endAngle",A={};u.shape[g]=o?r.r0:r.startAngle,A[g]=r[g],(l?m/* updateProps */.oi:m/* initProps */.LW)(u,{shape:A},i)}return u}};function D(e,t,n,r,o,i,a,l){var s,c;i?(c={x:r.x,width:r.width},s={y:r.y,height:r.height}):(c={y:r.y,height:r.height},s={x:r.x,width:r.width}),l|| +// Keep the original growth animation if only axis order changed. +// Not start a new animation. +(a?m/* updateProps */.oi:m/* initProps */.LW)(n,{shape:s},t,o,null);var u=t?e.baseAxis.model:null;(a?m/* updateProps */.oi:m/* initProps */.LW)(n,{shape:c},u,o)}function $(e,t){for(var n=0;n0?1:-1,a=r.height>0?1:-1;return{x:r.x+i*o/2,y:r.y+a*o/2,width:r.width-i*o,height:r.height-a*o}},polar:function(e,t,n){var r=e.getItemLayout(t);return{cx:r.cx,cy:r.cy,r0:r.r0,r:r.r,startAngle:r.startAngle,endAngle:r.endAngle,clockwise:r.clockwise}}};function F(e){return function(e){var t=e?"Arc":"Angle";return function(e){switch(e){case"start":case"insideStart":case"end":case"insideEnd":return e+t;default:return e}}}(e)}function U(e,t,n,o,i,a,l,s){var c=t.getItemVisual(n,"style");if(s){if(!a.get("roundCap")){var u=e.shape,d=(0,T/* getSectorCornerRadius */.i)(o.getModel("itemStyle"),u,!0);(0,r.extend)(u,d),e.setShape(u)}}else{var f=o.get(["itemStyle","borderRadius"])||0;e.setShape("r",f)}e.useStyle(c);var h=o.getShallow("cursor");h&&e.attr("cursor",h);var p=s?l?i.r>=i.r0?"endArc":"startArc":i.endAngle>=i.startAngle?"endAngle":"startAngle":l?i.height>=0?"bottom":"top":i.width>=0?"right":"left",m=(0,b/* getLabelStatesModels */.lx)(o);(0,b/* setLabelStyle */.qM)(e,m,{labelFetcher:a,labelDataIndex:n,defaultText:(0,k/* getDefaultLabel */.i)(a.getData(),n),inheritColor:c.fill,defaultOpacity:c.opacity,defaultOutsidePosition:p});var g=e.getTextContent();if(s&&g){var v=o.get(["label","position"]);e.textConfig.inside="middle"===v||null,function(e,t,n,o){if((0,r.isNumber)(o)) +// user-set rotation +e.setTextConfig({rotation:o});else if((0,r.isArray)(t)) +// user-set position, use 0 as auto rotation +e.setTextConfig({rotation:0});else{var i,a=e.shape,l=a.clockwise?a.startAngle:a.endAngle,s=a.clockwise?a.endAngle:a.startAngle,c=(l+s)/2,u=n(t);switch(u){case"startArc":case"insideStartArc":case"middle":case"insideEndArc":case"endArc":i=c;break;case"startAngle":case"insideStartAngle":i=l;break;case"endAngle":case"insideEndAngle":i=s;break;default:return void e.setTextConfig({rotation:0})}var d=1.5*Math.PI-i; +/** + * TODO: labels with rotate > Math.PI / 2 should be rotate another + * half round flipped to increase readability. However, only middle + * position supports this for now, because in other positions, the + * anchor point is not at the center of the text, so the positions + * after rotating is not as expected. + */"middle"===u&&d>Math.PI/2&&d<1.5*Math.PI&&(d-=Math.PI),e.setTextConfig({rotation:d})}}(e,"outside"===v?p:v,F(l),o.get(["label","rotate"]))}(0,b/* setLabelValueAnimation */.Oh)(g,m,a.getRawValue(n),(function(e){return(0,k/* getDefaultInterpolatedLabel */.T)(t,e)}));var A=o.getModel(["emphasis"]);(0,y/* toggleHoverEmphasis */.Lm)(e,A.get("focus"),A.get("blurScope"),A.get("disabled")),(0,y/* setStatesStylesFromModel */.Mx)(e,o),function(e){return null!=e.startAngle&&null!=e.endAngle&&e.startAngle===e.endAngle}(i)&&(e.style.fill="none",e.style.stroke="none",(0,r.each)(e.states,(function(e){e.style&&(e.style.fill=e.style.stroke="none")})))}var H=function(){},W=/** @class */function(e){function t(t){var n=e.call(this,t)||this;return n.type="largeBar",n}return(0,a/* __extends */.C6)(t,e),t.prototype.getDefaultShape=function(){return new H},t.prototype.buildPath=function(e,t){for( +// Drawing lines is more efficient than drawing +// a whole line or drawing rects. +var n=t.points,r=this.baseDimIdx,o=1-this.baseDimIdx,i=[],a=[],l=this.barWidth,s=0;s=l[0]&&t<=l[0]+s[0]&&n>=l[1]&&n<=l[1]+s[1])return a[u]}return-1}(this,e.offsetX,e.offsetY);(0,A/* getECData */.z)(this).dataIndex=t>=0?t:null}),30,!1);function X(e,t,n){if((0,C/* isCoordinateSystemType */.g)(n,"cartesian2d")){var r=t,o=n.getArea();return{x:e?r.x:o.x,y:e?o.y:r.y,width:e?r.width:o.width,height:e?o.height:r.height}}var i=t;return{cx:(o=n.getArea()).cx,cy:o.cy,r0:e?o.r0:i.r0,r:e?o.r:i.r,startAngle:e?i.startAngle:0,endAngle:e?i.endAngle:2*Math.PI}}var Y=P;// ./node_modules/echarts/lib/chart/bar/install.js +/* +* Licensed to the Apache Software Foundation (ASF) under one +* or more contributor license agreements. See the NOTICE file +* distributed with this work for additional information +* regarding copyright ownership. The ASF licenses this file +* to you under the Apache License, Version 2.0 (the +* "License"); you may not use this file except in compliance +* with the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, +* software distributed under the License is distributed on an +* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +* KIND, either express or implied. See the License for the +* specific language governing permissions and limitations +* under the License. +*/ +/** + * AUTO-GENERATED FILE. DO NOT MODIFY. + */ +/* +* Licensed to the Apache Software Foundation (ASF) under one +* or more contributor license agreements. See the NOTICE file +* distributed with this work for additional information +* regarding copyright ownership. The ASF licenses this file +* to you under the Apache License, Version 2.0 (the +* "License"); you may not use this file except in compliance +* with the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, +* software distributed under the License is distributed on an +* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +* KIND, either express or implied. See the License for the +* specific language governing permissions and limitations +* under the License. +*/ +function G(e){e.registerChartView(Y),e.registerSeriesModel(d),e.registerLayout(e.PRIORITY.VISUAL.LAYOUT,r.curry(o/* layout */.Zp,"bar")), +// Do layout after other overall layout, which can prepare some information. +e.registerLayout(e.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,(0,o/* createProgressiveLayout */.KF)("bar")), +// Down sample after filter +e.registerProcessor(e.PRIORITY.PROCESSOR.STATISTIC,(0,i/* default */.A)("bar")), +/** + * @payload + * @property {string} [componentType=series] + * @property {number} [dx] + * @property {number} [dy] + * @property {number} [zoom] + * @property {number} [originX] + * @property {number} [originY] + */ +e.registerAction({type:"changeAxisOrder",event:"changeAxisOrder",update:"update"},(function(e,t){var n=e.componentType||"series";t.eachComponent({mainType:n,query:e},(function(t){e.sortInfo&&t.axis.setCategorySortInfo(e.sortInfo)}))}))} +/***/}, +/***/6980: +/***/function(e){"use strict";e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}}, +/***/7040: +/***/function(e,t,n){"use strict"; +/* eslint-disable es/no-symbol -- required for testing */var r=n(4495);e.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol.iterator}, +/***/7277: +/***/function(e,t,n){"use strict"; +/* harmony export */n.d(t,{ +/* harmony export */Ap:function(){/* binding */return A}, +/* harmony export */Fx:function(){/* binding */return x}, +/* harmony export */KZ:function(){/* binding */return y}, +/* harmony export */M$:function(){/* binding */return m}, +/* harmony export */PE:function(){/* binding */return O}, +/* harmony export */PP:function(){/* binding */return v}, +/* harmony export */QM:function(){/* binding */return k}, +/* harmony export */d_:function(){/* binding */return b}, +/* harmony export */hW:function(){/* binding */return p}, +/* harmony export */qG:function(){/* binding */return g}, +/* harmony export */rz:function(){/* binding */return w}, +/* harmony export */wi:function(){/* binding */return C} +/* harmony export */}); +/* unused harmony exports ajaxPatch, reqExpost */ +/* harmony import */n(14603),n(47566),n(98721) +/* harmony import */;var r=n(94335),o=n(77918),i=n(20163),a=n(94945),l=(n(39325),n(37741)),s=n(34642),c=n.n(s),u=n(65084),d=n(64370),f=r/* ["default"] */.A.create({timeout:c().TIMEOUT});function h(e,t){var n,r=(0,l.getToken)(); +// var timestamp=new Date().getTime(); +if(e.params?( +//对传入的参数进行深拷贝,防止传入的参数对象被页面上其他逻辑改变,导致签名错误 +// 不是formdata类型 +n="[object FormData]"!=Object.prototype.toString.call(e.params)?JSON.parse(JSON.stringify(e.params)):e.params,"GET"==t&&(n={...n})):n={},"PUT"==t||"DELETE"==t){var o={url:a/* .url */.O+e.url+n.id+"/",method:t,headers:{Authorization:"JWT "+r}};return n.id||(o={url:a/* .url */.O+e.url,method:t,headers:{Authorization:"JWT "+r}}),"PUT"===t&&(o.params=n),new Promise(((e,a)=>{f({url:o.url,method:t,headers:{Authorization:"JWT "+r},data:n}).then((t=>{e(t.data)})).catch((e=>{i/* .ElMessage */.nk.error("请求失败"),a(e)}))}))}if("GET2"==t){var s={url:a/* .url */.O+e.url+n.id+"/",method:"GET",headers:{Authorization:"JWT "+r}};return n.id||(s={url:a/* .url */.O+e.url,method:"GET",headers:{Authorization:"JWT "+r}}),new Promise(((e,t)=>{ +// console.log(config,'config') +f({url:s.url,method:"GET",headers:{Authorization:"JWT "+r},data:n}).then((t=>{e(t.data)})).catch((e=>{i/* .ElMessage */.nk.error("请求失败"),t(e)}))}))}if("excel"==t){var c={url:a/* .url */.O+e.url,method:"POST",headers:{Authorization:"JWT "+r},responseType:"blob"};return c.data=n,new Promise(((e,t)=>{f(c).then((t=>{e(t)})).catch((t=>{i/* .ElMessage */.nk.error("请求失败"),e(t)}))}))}var u={url:a/* .url */.O+e.url,method:t,headers:{Authorization:"JWT "+r}};return"GET"===t&&(u.params=n),"POST"===t&&(u.data=n),"PATCH"===t&&(u.data=n),new Promise(((e,t)=>{f(u).then((t=>{e(t.data)})).catch((e=>{i/* .ElMessage */.nk.error("请求失败"),t(e)}))}))}function p(e){return h(e,"GET")}function m(e){return h(e,"PUT")}function g(e){return h(e,"DELETE")}function v(e){return h(e,"POST")} +// 单例详情获取get /api/test/12xxxxxxxx/ +function A(e){return h(e,"GET2")} +// 下载excel文件流(blob) +function y(e){return h(e,"excel")}function b(e){const t=new URLSearchParams(e.params);let n=a/* .url */.O+e.url;n+="?"+t.toString(),window.location.href=n}function O(e){let t=(0,l.getToken)();return(0,r/* ["default"] */.A)({method:"post",url:a/* .url */.O+e.url,headers:{Authorization:"JWT "+t},data:JSON.parse(JSON.stringify(e.params)),responseType:"blob"}).then((e=>e))} +//websocket获取jwt请求token +function w(){return"JWTlybbn"+(0,l.getToken)()} +// 上传图片 +function x(e){let t=new FormData;t.append("file",e.params.file);let n=(0,l.getToken)();return(0,r/* ["default"] */.A)({method:"post",url:a/* .url */.O+e.url,headers:{"Content-Type":"multipart/form-data",Authorization:"JWT "+n},data:t,onUploadProgress:t=>{ +// progressEvent.loaded:已上传文件大小 +// progressEvent.total:被上传文件的总大小 +let n=t.loaded/t.total*100;e.params.onProgress&&e.params.onProgress({percent:n}); +// console.info(progressEvent.loaded) +// console.info(progressEvent.total) +}}).then((e=>e.data))} +// 请求定义v2 +f.interceptors.request.use((e=>{const t=(0,d/* .cancelRequestState */.r)();return e.cancelToken=new r/* ["default"] */.A.CancelToken((e=>{t.addCancelToken(e)})),e})), +// http response 拦截器 +f.interceptors.response.use((e=>{const t=(0,u/* .useMutitabsStore */.M)();return 4001===e.data.code?(o/* .ElMessageBox */.s.alert("登录信息失效,请重新登录!","登录失效",{confirmButtonText:"确定",type:"warning",callback:e=>{ +//跳转登录页 callback点击确定按钮后的回调函数 +t.logout(),i/* .ElMessage */.nk.success("已退出登录!"),window.location.href="/"}}),e):e}));var _={ +/** get 请求 + * @param {string} url 接口地址 + * @param {object} params 请求参数 + * @param {object} config 参数 + */ +get:function(e,t={},n={}){let o="JWT "+(0,l.getToken)();return new Promise(((i,a)=>{(0,r/* ["default"] */.A)({method:"get",url:e,headers:{Authorization:o},params:t,...n}).then((e=>{i(e.data)})).catch((e=>{a(e)}))}))}, +/** post 请求 + * @param {string} url 接口地址 + * @param {object} data 请求参数 + * @param {object} config 参数 + */ +post:function(e,t={},n={}){let o="JWT "+(0,l.getToken)();return new Promise(((i,a)=>{(0,r/* ["default"] */.A)({method:"post",url:e,headers:{Authorization:o},data:t,...n}).then((e=>{i(e.data)})).catch((e=>{a(e)}))}))}, +/** put 请求 + * @param {string} url 接口地址 + * @param {object} data 请求参数 + * @param {object} config 参数 + */ +put:function(e,t={},n={}){let o="JWT "+(0,l.getToken)();return new Promise(((i,a)=>{(0,r/* ["default"] */.A)({method:"put",url:e,headers:{Authorization:o},data:t,...n}).then((e=>{i(e.data)})).catch((e=>{a(e)}))}))}, +/** patch 请求 + * @param {string} url 接口地址 + * @param {object} data 请求参数 + * @param {object} config 参数 + */ +patch:function(e,t={},n={}){let o="JWT "+(0,l.getToken)();return new Promise(((i,a)=>{(0,r/* ["default"] */.A)({method:"patch",url:e,headers:{Authorization:o},data:t,...n}).then((e=>{i(e.data)})).catch((e=>{a(e)}))}))}, +/** delete 请求 + * @param {string} url 接口地址 + * @param {object} data 请求参数 + * @param {object} config 参数 + */ +delete:function(e,t={},n={}){let o="JWT "+(0,l.getToken)();return new Promise(((i,a)=>{(0,r/* ["default"] */.A)({method:"delete",url:e,headers:{Authorization:o},data:t,...n}).then((e=>{i(e.data)})).catch((e=>{a(e)}))}))}}; +// 上传图片 v2 +async function C(e){let t=a/* .url */.O+e.url,n=e.params,r=e.params.config||{};//请求API +//额外配置 +return await _.post(t,n,r)}function k(e,t){const n=(0,l.getToken)();return new Promise(((o,i)=>{(0,r/* ["default"] */.A)({method:"post",url:a/* .url */.O+e.url,headers:{"Content-Type":"multipart/form-data",Authorization:c().TOKEN_PREFIX+n},data:e.formData,onUploadProgress:e=>{t&&t(e)}}).then((e=>{o(e.data)})).catch((e=>{i(e)}))}))} +/***/}, +/***/7416: +/***/function(e,t,n){"use strict"; +// ESM COMPAT FLAG +n.r(t), +// EXPORTS +n.d(t,{default:function(){/* binding */return c}}); +// EXTERNAL MODULE: ./node_modules/vue/dist/vue.esm-bundler.js + 5 modules +var r=n(61431),o=n(90517),i=(n(45057),n(92492)),a=n(28829); +// EXTERNAL MODULE: ./src/store/lyFormBuilder.js +// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/lyform-builder/lysetting-pannel/lywidget-setting/picture-upload-setting-ly.vue?vue&type=script&setup=true&lang=js +const l={style:{display:"flex","align-items":"center"}}; +/* harmony default export */var s={__name:"picture-upload-setting-ly",props:{selectedWidget:Object,optionModel:Object,builderConfig:{type:Object,default:{showHeader:!0, +//是否显示头部信息 +showFormTemplates:!0, +//是否显示表单模板 +showEventCollapse:!0, +//是否显示组件事件属性折叠面板 +showDocumentButton:!0, +//是否显示文档按钮 +clearDesignerButton:!0, +//是否显示清空设计器按钮 +previewFormButton:!0, +//是否显示预览表单按钮 +exportJsonButton:!0, +//是否显示导出JSON器按钮 +exportCodeButton:!0, +//是否显示导出代码按钮 +importJsonButton:!0, +//是否显示导入代码按钮 +showFullButton:!0, +//是否显示全屏按钮 +openNewWindowButton:!0, +//是否显示新窗口按钮 +saveFormButton:!0, +//是否保存表单按钮 +showCrudSettings:!0}}},setup(e){const t=(0,o/* useBuilderStore */.k)();function n(e){t.saveCurrentHistoryStep()}let s=(0,r.ref)(["lyws01","lyws02","lyws03"]);(0,r.ref)([{label:"default",value:""},{label:"large",value:"large"},{label:"small",value:"small"}]);return(t,o)=>{const c=(0,r.resolveComponent)("el-input"),u=(0,r.resolveComponent)("el-form-item"),d=(0,r.resolveComponent)("el-switch"),f=(0,r.resolveComponent)("el-divider"),h=(0,r.resolveComponent)("el-input-number"),p=(0,r.resolveComponent)("el-collapse-item"),m=(0,r.resolveComponent)("QuestionFilled"),g=(0,r.resolveComponent)("el-icon"),v=(0,r.resolveComponent)("el-tooltip"),A=(0,r.resolveComponent)("el-collapse"),y=(0,r.resolveComponent)("el-form");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[(0,r.createVNode)(y,{size:"small","label-position":"left","label-width":"100px",class:"lywidgetsetting",onSubmit:o[16]||(o[16]=(0,r.withModifiers)((()=>{}),["prevent"]))},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(A,{modelValue:(0,r.unref)(s),"onUpdate:modelValue":o[15]||(o[15]=e=>(0,r.isRef)(s)?s.value=e:s=e),class:"lyformsetting-collapse"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(p,{name:"lyws01",title:"组件属性"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(u,{label:"字段标识"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(c,{modelValue:e.optionModel.name,"onUpdate:modelValue":o[0]||(o[0]=t=>e.optionModel.name=t),modelModifiers:{trim:!0},onChange:n},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(u,{label:"隐藏"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(d,{modelValue:e.optionModel.hidden,"onUpdate:modelValue":o[1]||(o[1]=t=>e.optionModel.hidden=t),onChange:n},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(u,{label:"禁用"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(d,{modelValue:e.optionModel.disabled,"onUpdate:modelValue":o[2]||(o[2]=t=>e.optionModel.disabled=t),onChange:n},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(u,{label:"标签文本"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(c,{modelValue:e.optionModel.label,"onUpdate:modelValue":o[3]||(o[3]=t=>e.optionModel.label=t),style:{width:"100%"},onChange:n},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(u,{label:"标签宽度"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(c,{modelValue:e.optionModel.labelWidth,"onUpdate:modelValue":o[4]||(o[4]=t=>e.optionModel.labelWidth=t),style:{width:"100%"},onChange:n},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(u,{label:"隐藏字段标签"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(d,{modelValue:e.optionModel.labelHidden,"onUpdate:modelValue":o[5]||(o[5]=t=>e.optionModel.labelHidden=t),onChange:n},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(u,{label:"必填字段"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(d,{modelValue:e.optionModel.required,"onUpdate:modelValue":o[6]||(o[6]=t=>e.optionModel.required=t),onChange:n},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(u,{label:"必填校验提示"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(c,{modelValue:e.optionModel.requiredHint,"onUpdate:modelValue":o[7]||(o[7]=t=>e.optionModel.requiredHint=t),style:{width:"100%"},onChange:n},null,8,["modelValue"])])),_:1}),(0,r.createVNode)((0/* default */,r.unref)(i.A),{"selected-widget":e.selectedWidget,"option-model":e.optionModel},null,8,["selected-widget","option-model"]),(0,r.createVNode)(u,{"label-width":"0"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(f,null,{default:(0,r.withCtx)((()=>o[17]||(o[17]=[(0,r.createTextVNode)("上传参数设置")]))),_:1})])),_:1}),(0,r.createVNode)(u,{label:"可拖拽排序"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(d,{modelValue:e.optionModel.draggable,"onUpdate:modelValue":o[8]||(o[8]=t=>e.optionModel.draggable=t),onChange:n},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(u,{label:"文件可多选"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(d,{modelValue:e.optionModel.multipleSelect,"onUpdate:modelValue":o[9]||(o[9]=t=>e.optionModel.multipleSelect=t),onChange:n},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(u,{label:"上传提示内容"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(c,{modelValue:e.optionModel.uploadTip,"onUpdate:modelValue":o[10]||(o[10]=t=>e.optionModel.uploadTip=t),style:{width:"100%"},onChange:n},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(u,{label:"最大上传数量"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(h,{modelValue:e.optionModel.limit,"onUpdate:modelValue":o[11]||(o[11]=t=>e.optionModel.limit=t),min:1,max:100,style:{width:"100%"},onChange:n},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(u,{label:"大小限制(MB)"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(h,{modelValue:e.optionModel.fileMaxSize,"onUpdate:modelValue":o[12]||(o[12]=t=>e.optionModel.fileMaxSize=t),min:1,max:1e3,style:{width:"100%"},onChange:n},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(u,{label:"组件宽度(px)"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(h,{modelValue:e.optionModel.uploadWidth,"onUpdate:modelValue":o[13]||(o[13]=t=>e.optionModel.uploadWidth=t),min:1,max:1e4,style:{width:"100%"},onChange:n},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(u,{label:"组件高度(px)"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(h,{modelValue:e.optionModel.uploadHight,"onUpdate:modelValue":o[14]||(o[14]=t=>e.optionModel.uploadHight=t),min:1,max:1e4,style:{width:"100%"},onChange:n},null,8,["modelValue"])])),_:1})])),_:1}),e.builderConfig.showCrudSettings?((0,r.openBlock)(),(0,r.createBlock)(p,{key:0,name:"lyws03",title:"CRUD属性"},{title:(0,r.withCtx)((()=>[(0,r.createElementVNode)("div",l,[o[18]||(o[18]=(0,r.createTextVNode)(" CRUD属性 ")),(0,r.createVNode)(v,{effect:"dark",content:"后端自动生成CRUD代码,用于控制是否列表显示、可查询、可空、可编辑等属性",placement:"top-start"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(g,null,{default:(0,r.withCtx)((()=>[(0,r.createVNode)(m)])),_:1})])),_:1})])])),default:(0,r.withCtx)((()=>[(0,r.createVNode)((0/* default */,r.unref)(a.A),{"selected-widget":e.selectedWidget,"option-model":e.optionModel},null,8,["selected-widget","option-model"])])),_:1})):(0,r.createCommentVNode)("",!0)])),_:1},8,["modelValue"])])),_:1})])}}}; +/* harmony default export */var c=(0,n(66262).A)(s,[["__scopeId","data-v-1f6da5bc"]]); +/***/}, +/***/7442: +/***/function(e,t,n){"use strict"; +/* harmony export */n.d(t,{ +/* harmony export */S:function(){/* binding */return i}, +/* harmony export */a:function(){/* binding */return a} +/* harmony export */}); +/* harmony import */var r=n(98026),o=(0,r.createHashMap)(); +/* +* Licensed to the Apache Software Foundation (ASF) under one +* or more contributor license agreements. See the NOTICE file +* distributed with this work for additional information +* regarding copyright ownership. The ASF licenses this file +* to you under the Apache License, Version 2.0 (the +* "License"); you may not use this file except in compliance +* with the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, +* software distributed under the License is distributed on an +* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +* KIND, either express or implied. See the License for the +* specific language governing permissions and limitations +* under the License. +*/ +/** + * AUTO-GENERATED FILE. DO NOT MODIFY. + */ +/* +* Licensed to the Apache Software Foundation (ASF) under one +* or more contributor license agreements. See the NOTICE file +* distributed with this work for additional information +* regarding copyright ownership. The ASF licenses this file +* to you under the Apache License, Version 2.0 (the +* "License"); you may not use this file except in compliance +* with the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, +* software distributed under the License is distributed on an +* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +* KIND, either express or implied. See the License for the +* specific language governing permissions and limitations +* under the License. +*/function i(e,t){(0,r.assert)(null==o.get(e)&&t),o.set(e,t)}function a(e,t,n){var r=o.get(t);if(!r)return n;var i=r(e);return i?n.concat(i):n} +/***/}, +/***/7586: +/***/function(e,t,n){var r=n(43271),o=n(1968) +/** + * 深度比较两个对象之间的值是否相等 + * + * @param {Object} obj1 值1 + * @param {Object} obj2 值2 + * @return {Boolean} + */;e.exports=function(e,t){return r(e,t,o)} +/***/}, +/***/7588: +/***/function(e,t,n){"use strict";var r=n(46518),o=n(72652),i=n(79306),a=n(28551),l=n(1767); +// `Iterator.prototype.forEach` method +// https://tc39.es/ecma262/#sec-iterator.prototype.foreach +r({target:"Iterator",proto:!0,real:!0},{forEach:function(e){a(this),i(e);var t=l(this),n=0;o(t,(function(t){e(t,n++)}),{IS_RECORD:!0})}})}, +/***/7603: +/***/function(e,t,n){"use strict"; +// ESM COMPAT FLAG +n.r(t), +// EXPORTS +n.d(t,{default:function(){/* binding */return u}}); +// EXTERNAL MODULE: ./node_modules/vue/dist/vue.esm-bundler.js + 5 modules +var r=n(61431);// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/views/platformSettings/components/addCarouselModule.vue?vue&type=template&id=7e08a134&scoped=true +const o=["src"];// ./src/views/platformSettings/components/addCarouselModule.vue?vue&type=template&id=7e08a134&scoped=true +// EXTERNAL MODULE: ./src/api/api.js +var i=n(40412),a=n(94945),l=n(48404),s=n(37741),c={components:{LyDialog:l/* default */.A},emits:["refreshData"],name:"addModule",data(){return{dialogVisible:!1,loadingSave:!1,loadingTitle:"",peopleList:[],formData:{title:"",link:"",image:"",type:"",sort:0,status:!0},rules:{image:[{required:!0,message:"请上传图片",trigger:"blur"}],link:[{required:!0,message:"请输入链接",trigger:"blur"}],title:[{required:!0,message:"请输入标题",trigger:"blur"}]}}},methods:{handleClose(){this.dialogVisible=!1,this.loadingSave=!1,this.formData={title:"",link:"",image:"",type:"",sort:0,status:!0}},addModuleFn(e,t,n){this.loadingTitle=t,this.dialogVisible=!0,e&&(this.formData=(0,s.deepClone)(e)),this.formData.type=n},submitData(){this.$refs.rulesForm.validate((e=>{if(e){this.loadingSave=!0; +// let newimage = "" +// if (this.formData.image.indexOf("://")>=0){ +// newimage = this.formData.image.substring(this.formData.image.indexOf("/",8)) +// }else{ +// newimage = this.formData.image +// } +// this.formData.image = newimage +let e={...this.formData};this.formData.id?(0,i.platformsettingsLunboimgEdit)(e).then((e=>{this.loadingSave=!1,2e3==e.code?(this.$message.success(e.msg),this.handleClose(),this.$emit("refreshData")):this.$message.warning(e.msg)})):(0,i.platformsettingsLunboimgAdd)(e).then((e=>{this.loadingSave=!1,2e3==e.code?(this.$message.success(e.msg),this.handleClose(),this.$emit("refreshData")):this.$message.warning(e.msg)}))}}))},imgBeforeUpload(e){const t="image/jpeg"===e.type||"image/png"===e.type;return t||(this.$message.error("图片只能是 JPG/PNG 格式!"),!1)},async imgUploadRequest(e){let t=await(0,i.platformsettingsUploadPlatformImg)(e);if(2e3==t.code){let e="";e=t.data.data[0].indexOf("://")>=0?t.data.data[0]:a/* url */.O.split("/api")[0]+t.data.data[0],this.formData.image=e}else this.$message.warning(res.msg)},imgUploadSuccess(e){ +// if (res) { +// this.formData.image = res.url +// } +}}}; +// EXTERNAL MODULE: ./src/api/url.js +/* harmony default export */var u=(0,n(66262).A)(c,[["render",function(e,t,n,i,a,l){const s=(0,r.resolveComponent)("Plus"),c=(0,r.resolveComponent)("el-icon"),u=(0,r.resolveComponent)("el-upload"),d=(0,r.resolveComponent)("el-form-item"),f=(0,r.resolveComponent)("el-input"),h=(0,r.resolveComponent)("el-input-number"),p=(0,r.resolveComponent)("el-switch"),m=(0,r.resolveComponent)("el-form"),g=(0,r.resolveComponent)("el-button"),v=(0,r.resolveComponent)("ly-dialog");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[(0,r.createVNode)(v,{modelValue:a.dialogVisible,"onUpdate:modelValue":t[4]||(t[4]=e=>a.dialogVisible=e),title:a.loadingTitle,width:"560px","before-close":l.handleClose},{footer:(0,r.withCtx)((()=>[(0,r.createVNode)(g,{onClick:l.handleClose,loading:a.loadingSave},{default:(0,r.withCtx)((()=>t[5]||(t[5]=[(0,r.createTextVNode)("取消")]))),_:1},8,["onClick","loading"]),(0,r.createVNode)(g,{type:"primary",onClick:l.submitData,loading:a.loadingSave},{default:(0,r.withCtx)((()=>t[6]||(t[6]=[(0,r.createTextVNode)("确定")]))),_:1},8,["onClick","loading"])])),default:(0,r.withCtx)((()=>[(0,r.createVNode)(m,{inline:!1,model:a.formData,rules:a.rules,ref:"rulesForm","label-position":"right","label-width":"auto"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(d,{label:(a.formData.type,"图片:"),prop:"image"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(u,{class:"avatar-uploader",action:"","show-file-list":!1,"http-request":l.imgUploadRequest,"on-success":l.imgUploadSuccess,"before-upload":l.imgBeforeUpload},{default:(0,r.withCtx)((()=>[a.formData.image?((0,r.openBlock)(),(0,r.createElementBlock)("img",{key:0,src:a.formData.image,class:"avatar"},null,8,o)):((0,r.openBlock)(),(0,r.createBlock)(c,{key:1,class:"avatar-uploader-icon",size:"medium"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(s)])),_:1}))])),_:1},8,["http-request","on-success","before-upload"])])),_:1},8,["label"]),(0,r.createVNode)(d,{label:"标题:",prop:"title"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(f,{type:"text",modelValue:a.formData.title,"onUpdate:modelValue":t[0]||(t[0]=e=>a.formData.title=e),modelModifiers:{trim:!0}},null,8,["modelValue"])])),_:1}),1==a.formData.type||2==a.formData.type?((0,r.openBlock)(),(0,r.createBlock)(d,{key:0,label:"跳转链接:",prop:"link"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(f,{modelValue:a.formData.link,"onUpdate:modelValue":t[1]||(t[1]=e=>a.formData.link=e),modelModifiers:{trim:!0}},null,8,["modelValue"])])),_:1})):(0,r.createCommentVNode)("",!0),(0,r.createVNode)(d,{label:"排序:",prop:"sort"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(h,{modelValue:a.formData.sort,"onUpdate:modelValue":t[2]||(t[2]=e=>a.formData.sort=e),min:0,max:9999},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(d,{label:"状态:",prop:"status"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(p,{modelValue:a.formData.status,"onUpdate:modelValue":t[3]||(t[3]=e=>a.formData.status=e),"active-color":"#13ce66","inactive-color":"#ff4949"},null,8,["modelValue"])])),_:1})])),_:1},8,["model","rules"])])),_:1},8,["modelValue","title","before-close"])])}],["__scopeId","data-v-7e08a134"]]); +/***/}, +/***/7828: +/***/function(e,t,n){ +// Exports the "nonbreaking" plugin for usage with module loaders +// Usage: +// CommonJS: +// require('tinymce/plugins/nonbreaking') +// ES2015: +// import 'tinymce/plugins/nonbreaking' +n(83393); +/***/}, +/***/7845: +/***/function(e,t,n){"use strict"; +// ESM COMPAT FLAG +n.r(t), +// EXPORTS +n.d(t,{default:function(){/* binding */return m}}); +// EXTERNAL MODULE: ./node_modules/vue/dist/vue.esm-bundler.js + 5 modules +var r=n(61431);// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/views/mallManage/goodsType.vue?vue&type=template&id=4647e332 +const o={class:"tableSelect",ref:"tableSelect"},i={class:"table"},a=["textContent"],l={style:{display:"flex","justify-content":"space-between","align-items":"center"}},s=["onClick"],c=["onClick"];// ./src/views/mallManage/goodsType.vue?vue&type=template&id=4647e332 +// EXTERNAL MODULE: ./node_modules/core-js/modules/es.iterator.constructor.js +n(18111),n(61701); +// EXTERNAL MODULE: ./node_modules/core-js/modules/es.iterator.map.js +var u=n(10594),d=n(37741),f=n(40412),h=(n(78982),n(95789)),p={mixins:[n(24562).w],components:{AddModuleGoodsType:h.default,Pagination:u/* default */.A},name:"goodsType",data(){return{isFull:!1,loadingPage:!1,isDialogVisible:!1, +// 选项框选中数组 +ids:[], +// 选项框非单个禁用 +single:!0, +// 非多个禁用 +multiple:!0,formInline:{search:"",page:1,limit:100},pageparm:{page:1,limit:100,total:0},statusList:[{id:1,name:"正常"},{id:0,name:"禁用"}],timers:[],tableData:[],selectData:[]}},methods:{setFull(){this.isFull=!this.isFull,window.dispatchEvent(new Event("resize"))}, +// 表格序列号 +getIndex(e){ +// (当前页 - 1) * 当前显示数据条数 + 当前行数据的索引 + 1 +return(this.pageparm.page-1)*this.pageparm.limit+e+1}, +//多选项框被选中数据 +handleSelectionChange(e){this.ids=e.map((e=>e.id)),this.single=1!==e.length,this.multiple=!e.length}, +/** 批量删除按钮操作 */ +handleDelete(e){const t=this.ids;let n=this;n.$confirm("是否确认删除选中的数据项?","警告",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((function(){return(0,f.mallGoodstypeDelete)({id:t}).then((e=>{2e3==e.code?(n.$message.success(e.msg),n.search()):n.$message.warning(e.msg)}))}))},changeStatus(e){},handleAddClick(){this.isDialogVisible=!0,this.$nextTick((()=>{this.$refs.addModuleFlag.handleOpen(null,"新增")}))},handleEdit(e,t){if("detail"==t)this.isDialogVisible=!0,this.$nextTick((()=>{this.$refs.addModuleFlag.handleOpen(e,"详情")}));else if("edit"==t)this.isDialogVisible=!0,this.$nextTick((()=>{this.$refs.addModuleFlag.handleOpen(e,"编辑")}));else if("delete"==t){let t=this;t.$confirm("您确定要删除选中的数据吗?",{closeOnClickModal:!1}).then((n=>{(0,f.mallGoodstypeDelete)({id:e.id}).then((e=>{2e3==e.code?(t.$message.success(e.msg),t.search()):t.$message.warning(e.msg)}))})).catch((()=>{}))}else"reset"==t&&(this.formInline={page:1,limit:10},this.pageparm={page:1,limit:10,total:0},this.getData())},callFather(e){this.formInline.page=e.page,this.formInline.limit=e.limit,this.getData()},search(){this.formInline.page=1,this.formInline.limit=100,this.getData()}, +//获取列表 +async getData(){this.loadingPage=!0,(0,f.mallGoodstype)(this.formInline).then((e=>{this.loadingPage=!1,2e3==e.code&&(this.tableData=e.data.data, +// // 将列表数据转换为树形数据 +// this.tableData = XEUtils.toArrayTree(res.data.data, { parentKey: 'parent', strict: false }) +this.pageparm.page=e.data.page,this.pageparm.limit=e.data.limit,this.pageparm.total=e.data.total)}))},timeChange(e){e?(this.formInline.beginAt=(0,d.dateFormats)(e[0],"yyyy-MM-dd hh:mm:ss"),this.formInline.endAt=(0,d.dateFormats)(e[1],"yyyy-MM-dd hh:mm:ss")):(this.formInline.beginAt=null,this.formInline.endAt=null),this.search()}},created(){this.getData()}}; +/* harmony default export */var m=(0,n(66262).A)(p,[["render",function(e,t,n,u,d,f){const h=(0,r.resolveComponent)("el-input"),p=(0,r.resolveComponent)("el-form-item"),m=(0,r.resolveComponent)("el-button"),g=(0,r.resolveComponent)("el-form"),v=(0,r.resolveComponent)("el-table-column"),A=(0,r.resolveComponent)("el-image"),y=(0,r.resolveComponent)("full-screen"),b=(0,r.resolveComponent)("el-icon"),O=(0,r.resolveComponent)("el-tooltip"),w=(0,r.resolveComponent)("el-table"),x=(0,r.resolveComponent)("Pagination"),_=(0,r.resolveComponent)("add-module-goods-type"),C=(0,r.resolveDirective)("loading");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:(0,r.normalizeClass)({"ly-is-full":d.isFull})},[(0,r.createElementVNode)("div",o,[(0,r.createVNode)(g,{inline:!0,model:d.formInline,"label-position":"left"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(p,{label:"分类名称:"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(h,{modelValue:d.formInline.search,"onUpdate:modelValue":t[0]||(t[0]=e=>d.formInline.search=e),modelModifiers:{trim:!0},maxlength:"60",clearable:"",placeholder:"分类名称",onChange:f.search,style:{width:"200px"}},null,8,["modelValue","onChange"])])),_:1}),(0,r.createVNode)(p,{label:""},{default:(0,r.withCtx)((()=>[(0,r.withDirectives)((0,r.createVNode)(m,{onClick:f.search,type:"primary",icon:"Search"},{default:(0,r.withCtx)((()=>t[4]||(t[4]=[(0,r.createTextVNode)("查询")]))),_:1},8,["onClick"]),[[r.vShow,e.hasPermission(this.$route.name,"Search")]])])),_:1}),(0,r.createVNode)(p,{label:""},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(m,{onClick:t[1]||(t[1]=e=>f.handleEdit("","reset")),icon:"Refresh"},{default:(0,r.withCtx)((()=>t[5]||(t[5]=[(0,r.createTextVNode)("重置")]))),_:1})])),_:1}),(0,r.createVNode)(p,{label:""},{default:(0,r.withCtx)((()=>[(0,r.withDirectives)((0,r.createVNode)(m,{onClick:f.handleAddClick,type:"primary"},{default:(0,r.withCtx)((()=>t[6]||(t[6]=[(0,r.createTextVNode)("新增")]))),_:1},8,["onClick"]),[[r.vShow,e.hasPermission(this.$route.name,"Create")]])])),_:1}),(0,r.createVNode)(p,{label:""},{default:(0,r.withCtx)((()=>[(0,r.withDirectives)((0,r.createVNode)(m,{onClick:f.handleDelete,type:"danger",disabled:d.multiple},{default:(0,r.withCtx)((()=>t[7]||(t[7]=[(0,r.createTextVNode)("删除")]))),_:1},8,["onClick","disabled"]),[[r.vShow,e.hasPermission(this.$route.name,"Delete")]])])),_:1})])),_:1},8,["model"])],512),(0,r.createElementVNode)("div",i,[(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createBlock)(w,{height:e.tableHeight,border:"",data:d.tableData,style:{width:"100%"},ref:"tableref",onSelectionChange:f.handleSelectionChange,"row-key":"id","tree-props":{children:"children",hasChildren:"hasChildren"}},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(v,{type:"selection",width:"60",align:"center"}),(0,r.createVNode)(v,{type:"index",width:"60",align:"center",label:"序号"},{default:(0,r.withCtx)((e=>[(0,r.createElementVNode)("span",{textContent:(0,r.toDisplayString)(f.getIndex(e.$index))},null,8,a)])),_:1}),(0,r.createVNode)(v,{"min-width":"100",prop:"name",label:"分类名称"}),(0,r.createVNode)(v,{"min-width":"60",sortable:"",prop:"sort",label:"排序"}),(0,r.createVNode)(v,{"min-width":"80",prop:"default_image",label:"图标"},{default:(0,r.withCtx)((e=>[e.row.default_image?((0,r.openBlock)(),(0,r.createBlock)(A,{key:0,src:e.row.default_image,style:{width:"30px",height:"30px"},"preview-src-list":[e.row.default_image]},null,8,["src","preview-src-list"])):(0,r.createCommentVNode)("",!0)])),_:1}),(0,r.createVNode)(v,{"min-width":"150",prop:"create_datetime",label:"创建时间"}),(0,r.createVNode)(v,{label:"操作",width:"180"},{header:(0,r.withCtx)((()=>[(0,r.createElementVNode)("div",l,[t[8]||(t[8]=(0,r.createElementVNode)("div",null,"操作",-1)),(0,r.createElementVNode)("div",{onClick:t[2]||(t[2]=(...e)=>f.setFull&&f.setFull(...e))},[(0,r.createVNode)(O,{content:"全屏",placement:"bottom"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(b,null,{default:(0,r.withCtx)((()=>[(0,r.createVNode)(y)])),_:1})])),_:1})])])])),default:(0,r.withCtx)((t=>[(0,r.withDirectives)((0,r.createElementVNode)("span",{class:"table-operate-btn",onClick:e=>f.handleEdit(t.row,"edit")},"编辑",8,s),[[r.vShow,e.hasPermission(this.$route.name,"Update")]]),(0,r.withDirectives)((0,r.createElementVNode)("span",{class:"table-operate-btn",onClick:e=>f.handleEdit(t.row,"delete")},"删除",8,c),[[r.vShow,e.hasPermission(this.$route.name,"Delete")]])])),_:1})])),_:1},8,["height","data","onSelectionChange"])),[[C,d.loadingPage]])]),(0,r.createVNode)(x,{"child-msg":d.pageparm,onCallFather:f.callFather},null,8,["child-msg","onCallFather"]),d.isDialogVisible?((0,r.openBlock)(),(0,r.createBlock)(_,{key:0,ref:"addModuleFlag",onRefreshData:f.getData,onClosed:t[3]||(t[3]=e=>d.isDialogVisible=!1)},null,8,["onRefreshData"])):(0,r.createCommentVNode)("",!0)],2)}]]); +/***/}, +/***/7847: +/***/function(){ +/** + * Copyright (c) Tiny Technologies, Inc. All rights reserved. + * Licensed under the LGPL or a commercial license. + * For LGPL see License.txt in the project root for license information. + * For commercial licenses see https://www.tiny.cloud/ + * + * Version: 5.10.2 (2021-11-17) + */ +!function(){"use strict";var e=tinymce.util.Tools.resolve("tinymce.PluginManager"),t=function(e){return function(t){return r=typeof(n=t),(null===n?"null":"object"===r&&(Array.prototype.isPrototypeOf(n)||n.constructor&&"Array"===n.constructor.name)?"array":"object"===r&&(String.prototype.isPrototypeOf(n)||n.constructor&&"String"===n.constructor.name)?"string":r)===e;var n,r}},n=t("string"),r=t("array"),o=tinymce.util.Tools.resolve("tinymce.dom.DOMUtils"),i=tinymce.util.Tools.resolve("tinymce.EditorManager"),a=tinymce.util.Tools.resolve("tinymce.Env"),l=tinymce.util.Tools.resolve("tinymce.util.Tools"),s=function(e){return e.getParam("importcss_selector_converter")},c=function(e){return e.getParam("importcss_append")},u=Array.prototype.push,d=function(e,t){return function(e){for(var t=[],n=0,o=e.length;n0)l.each(n,(function(n){var r=a(e,n);r&&t.addItemToGroup(n.title,r)}));else{var o=a(e,null);o&&t.addItem(o)}}}));var u=t.toFormats();e.fire("addStyleModifications",{items:u,replace:!c(e)})}))};e.add("importcss",(function(e){return v(e),function(e){return{convertSelectorToFormat:function(t){return m(e,t)}}}(e)}))}(); +/***/}, +/***/7865: +/***/function(e,t,n){"use strict"; +// EXPORTS +n.d(t,{A:function(){/* binding */return j}}); +// EXTERNAL MODULE: ./node_modules/vue/dist/vue.esm-bundler.js + 5 modules +var r=n(61431),o=(n(44114),n(18111),n(22489),n(7588),n(61701),n(37708)),i=n(37741),a=n(90517),l=n(20163); +// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.push.js +// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/lyform-builder/lywidget-pannel/lyWidgetPannel.vue?vue&type=script&setup=true&lang=js +const s={class:"lywp-main"},c={class:"lycustom-tabs-label"},u=["title","onDblclick"],d={class:"lyflex-center lymarginleft2"},f=["title","onDblclick"],h={class:"lyflex-center lymarginleft2"},p=["title","onDblclick"],m={class:"lyflex-center lymarginleft2"},g=["title","onDblclick"],v={class:"lyflex-center lymarginleft2"},A={class:"lycustom-tabs-label"}; +/* harmony default export */var y={__name:"lyWidgetPannel",props:{isFull:{type:Boolean,default:!1},builder:Object,height:{type:String,default:"auto"}, +//设计器高度,auto自动 +builderConfig:{type:Object,default:{showHeader:!0, +//是否显示头部信息 +showFormTemplates:!0, +//是否显示表单模板 +showEventCollapse:!0, +//是否显示组件事件属性折叠面板 +showDocumentButton:!0, +//是否显示文档按钮 +clearDesignerButton:!0, +//是否显示清空设计器按钮 +previewFormButton:!0, +//是否显示预览表单按钮 +exportJsonButton:!0, +//是否显示导出JSON器按钮 +exportCodeButton:!0, +//是否显示导出代码按钮 +importJsonButton:!0, +//是否显示导入代码按钮 +showFullButton:!0, +//是否显示全屏按钮 +openNewWindowButton:!0, +//是否显示新窗口按钮 +saveFormButton:!0, +//是否保存表单按钮 +showCrudSettings:!0}}},setup(e){(0,r.useCssVars)((e=>({"03fa0660":(0,r.unref)(R)})));const t=e,n=(0,a/* useBuilderStore */.k)();n.builderConfig;let y=(0,r.ref)([]),b=(0,r.ref)("lyfirst"),O=(0,r.ref)([]),w=(0,r.ref)([]),x=(0,r.ref)([]),_=(0,r.ref)([]);function C(){"lythree"===b.value&&(Q.value.length=0,n.widgetList.forEach((e=>{P(e,Q.value)})),!n.selectedId|| +//同步当前选中组件到节点树!!! +//同步当前选中组件到节点树!!! +(0,r.nextTick)((()=>{M.value.setCurrentKey(n.selectedId)})))}function k(e){return n.cloneNewContainerWidget(e)}function S(e){return n.handleWidgetMove(e)}function V(e){}function B(e){n.addFieldByDbClick(e)}function T(e){return n.cloneNewFieldWidget(e)}function N(e){return n.handleFieldMove(e)}function E(e){}function P(e,t){let n={id:e.id,label:e.options.label||e.type};t.push(n),void 0!==e.category&&(n.children=[],"grid"===e.type?e.cols.map((t=>{let r={id:t.id,label:t.options.name||e.type,children:[]};n.children.push(r),t.widgetList.map((e=>{P(e,r.children)}))})):"table"===e.type? +//TODO: 需要考虑合并单元格!! +e.rows.map((e=>{let t={id:e.id,label:"table-row",selectable:!1,children:[]};n.children.push(t),e.cols.map((e=>{if(e.merged) +//跳过合并单元格!! +return;let n=t.children,r={id:e.id,label:"table-cell",children:[]};n.push(r),e.widgetList.map((e=>{P(e,r.children)}))}))})):"tab"===e.type?e.tabs.map((t=>{let r={id:t.id,label:t.options.name||e.type,selectable:!1,children:[]};n.children.push(r),t.widgetList.map((e=>{P(e,r.children)}))})):("sub-form"===e.type||"container"===e.category)&&e.widgetList.map((e=>{P(e,n.children)})))}let Q=(0,r.ref)([]);let M=(0,r.ref)(null);function D(e,t){e&&e.map((e=>{t(e),"grid"===e.type?e.cols.map((e=>{t(e),D(e.widgetList,t)})):"table"===e.type?e.rows.map((e=>{e.cols.map((e=>{t(e),D(e.widgetList,t)}))})):"tab"===e.type?e.tabs.map((e=>{D(e.widgetList,t)})):("sub-form"===e.type||"container"===e.category)&&D(e.widgetList,t)}))}function $(e){let t=null;return D(n.widgetList,(n=>{n.id===e&&(t=n)})),t}function z(e,t,r){if(void 0===e.selectable||e.selectable){const t=$(e.id);t&&n.setSelected(t)}else l/* ElMessage */.nk.info("当前组件节点不可选择")}let R=(0,r.ref)(0);function I(){let e=t.builderConfig.showHeader?49:0;t.isFull?R.value=window.innerHeight-e+"px":"auto"!=t.height?R.value=parseInt(t.height)-e+"px":R.value=window.innerHeight-113-e+"px"}function L(){(0,r.nextTick)((()=>{I()}))}return(0,r.watch)((()=>t.height),((e,t)=>{I()})),(0,r.watch)((()=>t.isFull),(e=>{L()})),(0,r.onMounted)((()=>{O=o/* lyContainers */.GP.map((e=>({key:(0,i.randomId)(),...e}))).filter((e=>!e.internal)),w=o/* lyBasicFields */.Nc.map((e=>({key:(0,i.randomId)(),...e}))),x=o/* lyAdvancedFields */.Dr.map((e=>({key:(0,i.randomId)(),...e}))),_=o/* lyCustomFields */.mi.map((e=>({key:(0,i.randomId)(),...e}))),L(),window.addEventListener("resize",L),y.value=["lywpc01","lywpc02","lywpc03","lywpc04"]})),(0,r.onBeforeUnmount)((()=>{window.removeEventListener("resize",L)})),(e,t)=>{const o=(0,r.resolveComponent)("SetUp"),i=(0,r.resolveComponent)("el-icon"),a=(0,r.resolveComponent)("svg-icon"),l=(0,r.resolveComponent)("draggable"),P=(0,r.resolveComponent)("el-collapse-item"),D=(0,r.resolveComponent)("el-collapse"),$=(0,r.resolveComponent)("el-tab-pane"),I=(0,r.resolveComponent)("el-tree"),L=(0,r.resolveComponent)("el-scrollbar"),F=(0,r.resolveComponent)("el-tabs");return(0,r.openBlock)(),(0,r.createElementBlock)("div",s,[(0,r.createVNode)(F,{modelValue:(0,r.unref)(b),"onUpdate:modelValue":t[1]||(t[1]=e=>(0,r.isRef)(b)?b.value=e:b=e),class:"lywp-first-tabs","tab-position":"left",onTabChange:C},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(L,{class:"lywp-scrow",style:(0,r.normalizeStyle)({height:(0,r.unref)(R)})},{default:(0,r.withCtx)((()=>[(0,r.createVNode)($,{name:"lyfirst"},{label:(0,r.withCtx)((()=>[(0,r.createElementVNode)("span",c,[(0,r.createVNode)(i,{size:"28"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(o)])),_:1}),t[2]||(t[2]=(0,r.createElementVNode)("span",null,"组件库",-1))])])),default:(0,r.withCtx)((()=>[(0,r.createVNode)(D,{class:"lywp-collapse",modelValue:(0,r.unref)(y),"onUpdate:modelValue":t[0]||(t[0]=e=>(0,r.isRef)(y)?y.value=e:y=e)},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(P,{name:"lywpc01",title:"容器"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(l,{tag:"ul",list:(0,r.unref)(O),"item-key":"key",group:{name:"lyDragGroup",pull:"clone",put:!1},clone:k,"ghost-class":"ghost",sort:!1,move:S,onEnd:V},{item:(0,r.withCtx)((({element:e})=>[(0,r.createElementVNode)("li",{class:"lycontainer-widget-item",title:e.displayName,onDblclick:t=>{return r=e,void n.addContainerByDbClick(r);var r}},[(0,r.createElementVNode)("span",d,[(0,r.createVNode)(a,{"icon-class":e.icon?e.icon:"Menu",style:{color:"var(--el-color-primary)","font-size":"16px"}},null,8,["icon-class"]),(0,r.createTextVNode)(" "+(0,r.toDisplayString)(e.displayName),1)])],40,u)])),_:1},8,["list"])])),_:1}),(0,r.createVNode)(P,{name:"lywpc02",title:"基础组件"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(l,{tag:"ul",list:(0,r.unref)(w),"item-key":"key",group:{name:"lyDragGroup",pull:"clone",put:!1},clone:T,"ghost-class":"ghost",sort:!1,move:N,onEnd:E},{item:(0,r.withCtx)((({element:e})=>[(0,r.createElementVNode)("li",{class:"lycontainer-widget-item",title:e.displayName,onDblclick:t=>B(e)},[(0,r.createElementVNode)("span",h,[(0,r.createVNode)(a,{"icon-class":e.icon?e.icon:"Menu",style:{color:"var(--el-color-primary)","font-size":"16px"}},null,8,["icon-class"]),(0,r.createTextVNode)(" "+(0,r.toDisplayString)(e.displayName),1)])],40,f)])),_:1},8,["list"])])),_:1}),(0,r.createVNode)(P,{name:"lywpc03",title:"高级组件"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(l,{tag:"ul",list:(0,r.unref)(x),"item-key":"key",group:{name:"lyDragGroup",pull:"clone",put:!1},clone:T,"ghost-class":"ghost",sort:!1,move:N,onEnd:E},{item:(0,r.withCtx)((({element:e})=>[(0,r.createElementVNode)("li",{class:"lycontainer-widget-item",title:e.displayName,onDblclick:t=>B(e)},[(0,r.createElementVNode)("span",m,[(0,r.createVNode)(a,{"icon-class":e.icon?e.icon:"Menu",style:{color:"var(--el-color-primary)","font-size":"16px"}},null,8,["icon-class"]),(0,r.createTextVNode)(" "+(0,r.toDisplayString)(e.displayName),1)])],40,p)])),_:1},8,["list"])])),_:1}),(0,r.createVNode)(P,{name:"lywpc04",title:"自定义组件"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(l,{tag:"ul",list:(0,r.unref)(_),"item-key":"key",group:{name:"lyDragGroup",pull:"clone",put:!1},clone:T,"ghost-class":"ghost",sort:!1,move:N,onEnd:E},{item:(0,r.withCtx)((({element:e})=>[(0,r.createElementVNode)("li",{class:"lycontainer-widget-item",title:e.displayName,onDblclick:t=>B(e)},[(0,r.createElementVNode)("span",v,[(0,r.createVNode)(a,{"icon-class":e.icon?e.icon:"Menu",style:{color:"var(--el-color-primary)","font-size":"16px"}},null,8,["icon-class"]),(0,r.createTextVNode)(" "+(0,r.toDisplayString)(e.displayName),1)])],40,g)])),_:1},8,["list"])])),_:1})])),_:1},8,["modelValue"])])),_:1}),(0,r.createVNode)($,{name:"lythree"},{label:(0,r.withCtx)((()=>[(0,r.createElementVNode)("span",A,[(0,r.createVNode)(a,{"icon-class":"lyicon-node-tree",style:{"font-size":"28px"}}),t[3]||(t[3]=(0,r.createElementVNode)("span",null,"结构树",-1))])])),default:(0,r.withCtx)((()=>[(0,r.createVNode)(I,{ref_key:"nodeTree",ref:M,data:(0,r.unref)(Q),"node-key":"id","default-expand-all":"","highlight-current":"",onNodeClick:z,class:"struct-tree"},null,8,["data"])])),_:1})])),_:1},8,["style"])])),_:1},8,["modelValue"])])}}},b=n(66262); +/* harmony default export */var O=(0,b/* default */.A)(y,[["__scopeId","data-v-42e1d86a"]]),w=(n(17642),n(58004),n(33853),n(45876),n(32475),n(15024),n(31698),n(48404)); +// EXTERNAL MODULE: ./node_modules/core-js/modules/es.set.difference.v2.js +// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/lyform-builder/lysetting-pannel/lyFormSetting.vue?vue&type=script&setup=true&lang=js +const x={style:{display:"flex","align-items":"center"}},_={style:{display:"flex","align-items":"center"}},C={style:{display:"flex","align-items":"center"}}; +/* harmony default export */var k={__name:"lyFormSetting",props:{formConfig:Object,builderConfig:{type:Object,default:{showHeader:!0, +//是否显示头部信息 +showFormTemplates:!0, +//是否显示表单模板 +showEventCollapse:!0, +//是否显示组件事件属性折叠面板 +showDocumentButton:!0, +//是否显示文档按钮 +clearDesignerButton:!0, +//是否显示清空设计器按钮 +previewFormButton:!0, +//是否显示预览表单按钮 +exportJsonButton:!0, +//是否显示导出JSON器按钮 +exportCodeButton:!0, +//是否显示导出代码按钮 +importJsonButton:!0, +//是否显示导入代码按钮 +showFullButton:!0, +//是否显示全屏按钮 +openNewWindowButton:!0, +//是否显示新窗口按钮 +saveFormButton:!0, +//是否保存表单按钮 +showCrudSettings:!0}}},setup(e){const t=(0,r.defineAsyncComponent)((()=>Promise.resolve().then(n.bind(n,55866)))),o=e;let l=(0,r.ref)([]);const s=(0,r.ref)([{label:"default",value:""},{label:"large",value:"large"},{label:"small",value:"small"}]);let c=(0,r.ref)([]),u=(0,r.ref)(""),d={onFormCreated:"onFormCreated() {",onFormMounted:"onFormMounted() {"};const f=(0,a/* useBuilderStore */.k)();function h(e){f.saveCurrentHistoryStep()}function p(){let e=m.value.match(/\..*{/g),t=[];e&&e.length>0&&e.forEach((e=>{let n=e.split(",");//切分逗号分割的多个class +n.length>0&&n.forEach((e=>{let n=e.trim();if(-1!==n.indexOf(".",1)){ +//查找第二个.位置 +let e=n.substring(n.indexOf(".")+1,n.indexOf(".",1));//仅截取第一、二个.号之间的class +e&&t.push(e.trim())}else if(-1!==n.indexOf(" ")){ +//查找第一个空格位置 +let e=n.substring(n.indexOf(".")+1,n.indexOf(" "));//仅截取第一、二个.号之间的class +e&&t.push(e.trim())}else if(-1!==n.indexOf("{")){ +//查找第一个{位置 +let e=n.substring(n.indexOf(".")+1,n.indexOf("{"));t.push(e.trim())}else{let e=n.substring(n.indexOf(".")+1);t.push(e.trim())}}))})),c.value.splice(0,c.value.length),//清除数组必须用splice,length=0不会响应式更新!! +c.value=Array.from(new Set(t))}let m=(0,r.ref)(""),g=(0,r.ref)(!1);function v(){m.value=f.formConfig.cssCode,g.value=!0}function A(){p(),f.formConfig.cssCode=m.value,(0,i.insertCustomCssToHead)(m.value),g.value=!1,f.setCssClassList(c.value),f.saveCurrentHistoryStep()}function y(){g.value=!1}let b=(0,r.ref)(!1),O=(0,r.ref)("");function k(){O.value=f.formConfig.functions,b.value=!0}function S(){f.formConfig.functions=O.value,(0,i.insertGlobalFunctionsToHtml)(O.value),f.saveCurrentHistoryStep(),b.value=!1}function V(){b.value=!1}let B=(0,r.ref)(!1),T=(0,r.ref)("");function N(){B.value=!1}function E(){f.formConfig[u.value]=T.value,f.saveCurrentHistoryStep(),B.value=!1}return(0,r.onMounted)((()=>{l.value=["lyfs01","lyfs02",,"lyfs03"],setTimeout((()=>{m.value=o.formConfig.cssCode,(0,i.insertCustomCssToHead)(m.value),p(),f.setCssClassList(c.value)}),600)})),(n,i)=>{const a=(0,r.resolveComponent)("el-option"),p=(0,r.resolveComponent)("el-select"),P=(0,r.resolveComponent)("el-form-item"),Q=(0,r.resolveComponent)("el-radio-button"),M=(0,r.resolveComponent)("el-radio-group"),D=(0,r.resolveComponent)("el-input"),$=(0,r.resolveComponent)("el-switch"),z=(0,r.resolveComponent)("el-button"),R=(0,r.resolveComponent)("el-divider"),I=(0,r.resolveComponent)("el-collapse-item"),L=(0,r.resolveComponent)("QuestionFilled"),F=(0,r.resolveComponent)("el-icon"),U=(0,r.resolveComponent)("el-tooltip"),H=(0,r.resolveComponent)("el-collapse"),W=(0,r.resolveComponent)("el-alert"),j=(0,r.resolveComponent)("el-form");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[(0,r.createVNode)(j,{model:e.formConfig,size:"small","label-position":"left","label-width":"105px",class:"lyformsetting",onSubmit:i[22]||(i[22]=(0,r.withModifiers)((()=>{}),["prevent"]))},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(H,{modelValue:(0,r.unref)(l),"onUpdate:modelValue":i[15]||(i[15]=e=>(0,r.isRef)(l)?l.value=e:l=e),class:"lyformsetting-collapse"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(I,{name:"lyfs01",title:"基本属性"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(P,{label:"表单尺寸"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(p,{modelValue:e.formConfig.size,"onUpdate:modelValue":i[0]||(i[0]=t=>e.formConfig.size=t),onChange:h},{default:(0,r.withCtx)((()=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(s.value,(e=>((0,r.openBlock)(),(0,r.createBlock)(a,{key:e.value,label:e.label,value:e.value},null,8,["label","value"])))),128))])),_:1},8,["modelValue"])])),_:1}),(0,r.createVNode)(P,{label:"标签位置"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(M,{modelValue:e.formConfig.labelPosition,"onUpdate:modelValue":i[1]||(i[1]=t=>e.formConfig.labelPosition=t),class:"radio-group-custom",onChange:h},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(Q,{value:"left"},{default:(0,r.withCtx)((()=>i[23]||(i[23]=[(0,r.createTextVNode)("左边")]))),_:1}),(0,r.createVNode)(Q,{value:"right"},{default:(0,r.withCtx)((()=>i[24]||(i[24]=[(0,r.createTextVNode)("右边")]))),_:1}),(0,r.createVNode)(Q,{value:"top"},{default:(0,r.withCtx)((()=>i[25]||(i[25]=[(0,r.createTextVNode)("顶部")]))),_:1})])),_:1},8,["modelValue"])])),_:1}),(0,r.createVNode)(P,{label:"标签宽度(px)"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(D,{modelValue:e.formConfig.labelWidth,"onUpdate:modelValue":i[2]||(i[2]=t=>e.formConfig.labelWidth=t),style:{width:"100%"},onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(P,{label:"禁用表单"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)($,{modelValue:e.formConfig.disabled,"onUpdate:modelValue":i[3]||(i[3]=t=>e.formConfig.disabled=t),onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(P,{label:"表单全局CSS"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(z,{type:"info",icon:"edit",plain:"",round:"",onClick:v},{default:(0,r.withCtx)((()=>i[26]||(i[26]=[(0,r.createTextVNode)("编写CSS")]))),_:1})])),_:1}),(0,r.createVNode)(P,{label:"自定义CSS样式"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(p,{modelValue:e.formConfig.customClass,"onUpdate:modelValue":i[4]||(i[4]=t=>e.formConfig.customClass=t),multiple:"",filterable:"","allow-create":"","default-first-option":""},{default:(0,r.withCtx)((()=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)((0,r.unref)(c),((e,t)=>((0,r.openBlock)(),(0,r.createBlock)(a,{key:t,label:e,value:e},null,8,["label","value"])))),128))])),_:1},8,["modelValue"])])),_:1}),(0,r.createVNode)(P,{label:"表单全局方法"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(z,{type:"info",icon:"edit",plain:"",round:"",onClick:k},{default:(0,r.withCtx)((()=>i[27]||(i[27]=[(0,r.createTextVNode)("编写代码")]))),_:1})])),_:1}),(0,r.createVNode)(P,{"label-width":"0"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(R,null,{default:(0,r.withCtx)((()=>i[28]||(i[28]=[(0,r.createTextVNode)("生成SFC设置")]))),_:1})])),_:1}),(0,r.createVNode)(P,{label:"数据对象名称"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(D,{modelValue:e.formConfig.modelName,"onUpdate:modelValue":i[5]||(i[5]=t=>e.formConfig.modelName=t),onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(P,{label:"引用名称"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(D,{modelValue:e.formConfig.refName,"onUpdate:modelValue":i[6]||(i[6]=t=>e.formConfig.refName=t),onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(P,{label:"验证规则名称"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(D,{modelValue:e.formConfig.rulesName,"onUpdate:modelValue":i[7]||(i[7]=t=>e.formConfig.rulesName=t),onChange:h},null,8,["modelValue"])])),_:1})])),_:1}),void 0===f.builderConfig.showEventCollapse||f.builderConfig.showEventCollapse?((0,r.openBlock)(),(0,r.createBlock)(I,{key:0,name:"lyfs02",title:"事件属性"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(P,{label:"onFormMounted","label-width":"150px"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(z,{type:"info",icon:"edit",plain:"",round:"",onClick:i[8]||(i[8]=e=>{return t="onFormMounted",u.value=t,T.value=o.formConfig[t],void(B.value=!0);var t})},{default:(0,r.withCtx)((()=>i[29]||(i[29]=[(0,r.createTextVNode)("编写代码")]))),_:1})])),_:1})])),_:1})):(0,r.createCommentVNode)("",!0),e.builderConfig.showCrudSettings?((0,r.openBlock)(),(0,r.createBlock)(I,{key:1,name:"lyfs03",title:"CRUD属性"},{title:(0,r.withCtx)((()=>[(0,r.createElementVNode)("div",x,[i[30]||(i[30]=(0,r.createTextVNode)(" CRUD属性 ")),(0,r.createVNode)(U,{effect:"dark",content:"用于自动生成后端model及crud功能",placement:"top-start"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(F,null,{default:(0,r.withCtx)((()=>[(0,r.createVNode)(L)])),_:1})])),_:1})])])),default:(0,r.withCtx)((()=>[(0,r.createVNode)(P,{label:"表中文名称"},{label:(0,r.withCtx)((()=>[(0,r.createElementVNode)("div",_,[i[31]||(i[31]=(0,r.createTextVNode)(" 表中文名称 ")),(0,r.createVNode)(U,{effect:"dark",content:"此名称会作为model类的verbose_name、菜单名称",placement:"top-start"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(F,null,{default:(0,r.withCtx)((()=>[(0,r.createVNode)(L)])),_:1})])),_:1})])])),default:(0,r.withCtx)((()=>[(0,r.createVNode)(D,{modelValue:e.formConfig.modelVerboseName,"onUpdate:modelValue":i[9]||(i[9]=t=>e.formConfig.modelVerboseName=t),placeholder:"请输入表中文名称",onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(P,{label:"类名(class)"},{label:(0,r.withCtx)((()=>[(0,r.createElementVNode)("div",C,[i[32]||(i[32]=(0,r.createTextVNode)(" 类名(class) ")),(0,r.createVNode)(U,{effect:"dark",content:"此名称会作为model的类名、后端路由前缀、前端路由通用名、前后端通用文件名",placement:"top-start"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(F,null,{default:(0,r.withCtx)((()=>[(0,r.createVNode)(L)])),_:1})])),_:1})])])),default:(0,r.withCtx)((()=>[(0,r.createVNode)(D,{modelValue:e.formConfig.modelClassName,"onUpdate:modelValue":i[10]||(i[10]=t=>e.formConfig.modelClassName=t),placeholder:"请输入Model模型类名",onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(P,{label:"表名(db_table)"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(D,{modelValue:e.formConfig.modelDbTable,"onUpdate:modelValue":i[11]||(i[11]=t=>e.formConfig.modelDbTable=t),placeholder:"请输入英文表名",onChange:h},null,8,["modelValue"])])),_:1}),(0,r.createVNode)(P,{label:"表单模板ID"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(D,{modelValue:(0,r.unref)(f).formTemplateID,"onUpdate:modelValue":i[12]||(i[12]=e=>(0,r.unref)(f).formTemplateID=e),placeholder:"表单模板ID",disabled:!0},null,8,["modelValue"])])),_:1}),e.formConfig.other_config?((0,r.openBlock)(),(0,r.createBlock)(P,{key:0,label:"启用批量删除"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)($,{modelValue:e.formConfig.other_config.mutiple_delete,"onUpdate:modelValue":i[13]||(i[13]=t=>e.formConfig.other_config.mutiple_delete=t),onChange:h},null,8,["modelValue"])])),_:1})):(0,r.createCommentVNode)("",!0),e.formConfig.other_config?((0,r.openBlock)(),(0,r.createBlock)(P,{key:1,label:"过滤查询"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)($,{modelValue:e.formConfig.other_config.create_datetime_filter,"onUpdate:modelValue":i[14]||(i[14]=t=>e.formConfig.other_config.create_datetime_filter=t),size:"default","inline-prompt":"",style:{"--el-switch-on-color":"#13ce66","--el-switch-off-color":"#ff4949",height:"auto"},"active-text":"启用create_datetime过滤","inactive-text":"关闭create_datetime过滤",onChange:h},null,8,["modelValue"])])),_:1})):(0,r.createCommentVNode)("",!0)])),_:1})):(0,r.createCommentVNode)("",!0)])),_:1},8,["modelValue"]),(0,r.createVNode)((0/* default */,r.unref)(w.A),{modelValue:(0,r.unref)(g),"onUpdate:modelValue":i[17]||(i[17]=e=>(0,r.isRef)(g)?g.value=e:g=e),title:"表单全局CSS",width:"60%",top:"20px","before-close":y},{footer:(0,r.withCtx)((()=>[(0,r.createVNode)(z,{onClick:y,size:"default"},{default:(0,r.withCtx)((()=>i[33]||(i[33]=[(0,r.createTextVNode)("关闭")]))),_:1}),(0,r.createVNode)(z,{type:"primary",onClick:A,size:"default"},{default:(0,r.withCtx)((()=>i[34]||(i[34]=[(0,r.createTextVNode)("确定")]))),_:1})])),default:(0,r.withCtx)((()=>[(0,r.createElementVNode)("div",null,[(0,r.createVNode)((0,r.unref)(t),{ref:"lyFormEditCss",modelValue:(0,r.unref)(m),"onUpdate:modelValue":i[16]||(i[16]=e=>(0,r.isRef)(m)?m.value=e:m=e),mode:"css",height:"600","read-only":!1},null,8,["modelValue"])])])),_:1},8,["modelValue"]),(0,r.createVNode)((0/* default */,r.unref)(w.A),{modelValue:(0,r.unref)(b),"onUpdate:modelValue":i[19]||(i[19]=e=>(0,r.isRef)(b)?b.value=e:b=e),title:"表单全局方法",width:"60%",top:"20px","before-close":V},{footer:(0,r.withCtx)((()=>[(0,r.createVNode)(z,{onClick:V,size:"default"},{default:(0,r.withCtx)((()=>i[35]||(i[35]=[(0,r.createTextVNode)("关闭")]))),_:1}),(0,r.createVNode)(z,{type:"primary",onClick:S,size:"default"},{default:(0,r.withCtx)((()=>i[36]||(i[36]=[(0,r.createTextVNode)("确定")]))),_:1})])),default:(0,r.withCtx)((()=>[(0,r.createElementVNode)("div",null,[(0,r.createVNode)(W,{title:"表单全局方法会被追加到window对象(script标签),因此命名上应考虑不会与其他全局函数名称冲突!!!",type:"info","show-icon":""}),(0,r.createVNode)((0,r.unref)(t),{ref:"lyFormEditCss",modelValue:(0,r.unref)(O),"onUpdate:modelValue":i[18]||(i[18]=e=>(0,r.isRef)(O)?O.value=e:O=e),mode:"javascript",height:"600","read-only":!1},null,8,["modelValue"])])])),_:1},8,["modelValue"]),(0,r.createVNode)((0/* default */,r.unref)(w.A),{modelValue:(0,r.unref)(B),"onUpdate:modelValue":i[21]||(i[21]=e=>(0,r.isRef)(B)?B.value=e:B=e),title:"表单事件",width:"60%",top:"20px","before-close":N},{footer:(0,r.withCtx)((()=>[(0,r.createVNode)(z,{onClick:N,size:"default"},{default:(0,r.withCtx)((()=>i[37]||(i[37]=[(0,r.createTextVNode)("关闭")]))),_:1}),(0,r.createVNode)(z,{type:"primary",onClick:E,size:"default"},{default:(0,r.withCtx)((()=>i[38]||(i[38]=[(0,r.createTextVNode)("确定")]))),_:1})])),default:(0,r.withCtx)((()=>[(0,r.createElementVNode)("div",null,[(0,r.createVNode)(W,{title:"form."+(0,r.unref)(d)[(0,r.unref)(u)],type:"info",closable:!1},null,8,["title"]),(0,r.createVNode)((0,r.unref)(t),{ref:"lyFormEditCss",modelValue:(0,r.unref)(T),"onUpdate:modelValue":i[20]||(i[20]=e=>(0,r.isRef)(T)?T.value=e:T=e),mode:"javascript",height:"600","read-only":!1},null,8,["modelValue"]),(0,r.createVNode)(W,{title:"}",closable:!1,type:"info"})])])),_:1},8,["modelValue"])])),_:1},8,["model"])])}}}; +/* harmony default export */var S=(0,b/* default */.A)(k,[["__scopeId","data-v-6ed4b063"]]);// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/lyform-builder/lysetting-pannel/lySettingPannel.vue?vue&type=script&setup=true&lang=js +const V={class:"lysp-main"}; +/* harmony default export */var B={__name:"lySettingPannel",props:{isFull:{type:Boolean,default:!1},selectedWidget:Object,formConfig:Object,height:{type:String,default:"auto"}, +//设计器高度,auto自动 +builderConfig:{type:Object,default:{showHeader:!0, +//是否显示头部信息 +showFormTemplates:!0, +//是否显示表单模板 +showEventCollapse:!0, +//是否显示组件事件属性折叠面板 +showDocumentButton:!0, +//是否显示文档按钮 +clearDesignerButton:!0, +//是否显示清空设计器按钮 +previewFormButton:!0, +//是否显示预览表单按钮 +exportJsonButton:!0, +//是否显示导出JSON器按钮 +exportCodeButton:!0, +//是否显示导出代码按钮 +importJsonButton:!0, +//是否显示导入代码按钮 +showFullButton:!0, +//是否显示全屏按钮 +openNewWindowButton:!0, +//是否显示新窗口按钮 +saveFormButton:!0, +//是否保存表单按钮 +showCrudSettings:!0}}},setup(e){const t=e,n=(0,a/* useBuilderStore */.k)(),o=(0,r.computed)({get:()=>t.selectedWidget.options,set:e=>{t.selectedWidget.options=e}});let i=(0,r.ref)("lytwo");let l=(0,r.ref)(0);function s(){let e=t.builderConfig.showHeader?49:0;t.isFull?l.value=window.innerHeight-40-e+"px":"auto"!=t.height?l.value=parseInt(t.height)-40-e+"px":l.value=window.innerHeight-153-e+"px"}function c(){(0,r.nextTick)((()=>{s()}))}return(0,r.watch)((()=>t.height),((e,t)=>{s()})),(0,r.watch)((()=>t.isFull),(e=>{c()})),(0,r.onMounted)((()=>{n.selectedWidget?i.value="lyfirst":i.value="lytwo",c(),window.addEventListener("resize",c)})),(0,r.onBeforeUnmount)((()=>{window.removeEventListener("resize",c)})),(t,a)=>{const s=(0,r.resolveComponent)("el-empty"),c=(0,r.resolveComponent)("el-scrollbar"),u=(0,r.resolveComponent)("el-tab-pane"),d=(0,r.resolveComponent)("el-tabs");return(0,r.openBlock)(),(0,r.createElementBlock)("div",V,[(0,r.createVNode)(d,{modelValue:(0,r.unref)(i),"onUpdate:modelValue":a[0]||(a[0]=e=>(0,r.isRef)(i)?i.value=e:i=e),stretch:""},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(u,{name:"lyfirst",label:"组件属性"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(c,{class:"lysp-scrow",style:(0,r.normalizeStyle)({height:(0,r.unref)(l)})},{default:(0,r.withCtx)((()=>{return[(0,r.unref)(n).selectedWidget?((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)((t=e.selectedWidget,t.type+"-setting-ly")),{key:e.selectedWidget.id,"selected-widget":e.selectedWidget,"option-model":o.value,builderConfig:e.builderConfig},null,8,["selected-widget","option-model","builderConfig"])):(0,r.createCommentVNode)("",!0),0==Object.keys((0,r.unref)(n).selectedWidget).length?((0,r.openBlock)(),(0,r.createBlock)(s,{key:1,class:"ly-empty-text",description:"请选择组件"})):(0,r.createCommentVNode)("",!0)];var t})),_:1},8,["style"])])),_:1}),(0,r.createVNode)(u,{name:"lytwo",label:"表单属性"},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(c,{class:"lysp-scrow",style:(0,r.normalizeStyle)({height:(0,r.unref)(l)})},{default:(0,r.withCtx)((()=>[(0,r.createVNode)((0,r.unref)(S),{"form-config":e.formConfig,builderConfig:e.builderConfig},null,8,["form-config","builderConfig"])])),_:1},8,["style"])])),_:1})])),_:1},8,["modelValue"])])}}}; +/* harmony default export */var T=(0,b/* default */.A)(B,[["__scopeId","data-v-181d7f17"]]),N={__name:"lyFormDesign",props:{isFull:{type:Boolean,default:!1},height:{type:String,default:"auto"}, +//设计器高度,auto自动 +builderConfig:{type:Object,default:{showHeader:!0, +//是否显示头部信息 +showFormTemplates:!0, +//是否显示表单模板 +showEventCollapse:!0, +//是否显示组件事件属性折叠面板 +showDocumentButton:!0, +//是否显示文档按钮 +clearDesignerButton:!0, +//是否显示清空设计器按钮 +previewFormButton:!0, +//是否显示预览表单按钮 +exportJsonButton:!0, +//是否显示导出JSON器按钮 +exportCodeButton:!0, +//是否显示导出代码按钮 +importJsonButton:!0, +//是否显示导入代码按钮 +showFullButton:!0, +//是否显示全屏按钮 +openNewWindowButton:!0, +//是否显示新窗口按钮 +saveFormButton:!0, +//是否保存表单按钮 +showCrudSettings:!0, +//是否显示组件和表单的crud属性配置 +showDesignAlert:!0}}},setup(e){const t=e,n=(0,a/* useBuilderStore */.k)(),o=(0,r.computed)((()=>n.formConfig&&n.formConfig.labelPosition?n.formConfig.labelPosition:"left")),i=(0,r.computed)((()=>n.formConfig.customClass||"")),l=(0,r.computed)((()=>n.formConfig&&n.formConfig.size?n.formConfig.size:"default")),s=(0,r.computed)((()=>n.formConfig&&n.formConfig.labelWidth&&"auto"!=n.formConfig.labelWidth?n.formConfig.labelWidth+"px":"auto"));function c(e){return e.type+"-widget-ly"}function u(e){}function d(e){const t=e.newIndex;n.widgetList[t]&&n.setSelected(n.widgetList[t]),n.emitHistoryChange()}function f(e){n.emitHistoryChange()}function h(e){n.handleWidgetMove(e)}let p=(0,r.ref)(0);function m(){let e=t.builderConfig.showHeader?49:0;t.isFull?p.value=window.innerHeight-e:"auto"!=t.height?p.value=parseInt(t.height)-e:p.value=window.innerHeight-113-e}function g(){(0,r.nextTick)((()=>{m()}))}return(0,r.watch)((()=>t.height),((e,t)=>{m()})),(0,r.watch)((()=>t.isFull),(e=>{g()})),(0,r.watch)((()=>[n.widgetList,n.formConfig]),((e,t)=>{}),{deep:!0}),(0,r.onMounted)((()=>{n.initBuilder(),-1!==navigator.userAgent.toLowerCase().indexOf("firefox")&&(document.body.ondrop=function(e){e.stopPropagation(),e.preventDefault()}),n.registerFormWidget(),g(),window.addEventListener("resize",g)})),(0,r.onBeforeUnmount)((()=>{window.removeEventListener("resize",g)})),(t,a)=>{const m=(0,r.resolveComponent)("el-alert"),g=(0,r.resolveComponent)("el-empty"),v=(0,r.resolveComponent)("draggable"),A=(0,r.resolveComponent)("el-form"),y=(0,r.resolveComponent)("el-scrollbar");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[(0,r.createVNode)(y,{class:"lyfd-scrow",style:(0,r.normalizeStyle)({height:(0,r.unref)(p)+"px"})},{default:(0,r.withCtx)((()=>[(0,r.createVNode)(A,{class:(0,r.normalizeClass)(["lyfd-form",[i.value]]),"validate-on-rule-change":!1,"label-position":o.value,disabled:(0,r.unref)(n).formConfig.disabled,size:l.value,"label-width":s.value},{default:(0,r.withCtx)((()=>[e.builderConfig.showDesignAlert?((0,r.openBlock)(),(0,r.createBlock)(m,{key:0,title:"默认继承CoreModel已含字段【id,creator,update_datetime,create_datetime】请勿重复设计!!!",type:"warning",style:{"z-index":"101"},"show-icon":""})):(0,r.createCommentVNode)("",!0),(0,r.createElementVNode)("div",{class:"lyfd-drag",style:(0,r.normalizeStyle)({minHeight:(0,r.unref)(p)-40+"px"})},[0===(0,r.unref)(n).widgetList.length?((0,r.openBlock)(),(0,r.createBlock)(g,{key:0,class:"ly-empty-text",description:"从左侧选择组件添加"})):(0,r.createCommentVNode)("",!0),(0,r.createVNode)(v,{list:(0,r.unref)(n).widgetList,"item-key":"id",tag:"transition-group",group:"lyDragGroup",ghostClass:"lyformbuilder-ghost",animation:"300","component-data":{name:"fade",type:"transition"},handle:".drag-handler",onEnd:u,onAdd:d,onUpdate:f,move:h},{item:(0,r.withCtx)((({element:e,index:t})=>[(0,r.createElementVNode)("div",null,["container"===e.category?((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(c(e)),{widget:e,key:e.id,"parent-list":(0,r.unref)(n).widgetList,"index-of-parent-list":t,"parent-widget":null,"design-state":!0},null,8,["widget","parent-list","index-of-parent-list"])):((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(c(e)),{field:e,key:e.id,"parent-list":(0,r.unref)(n).widgetList,"index-of-parent-list":t,"parent-widget":null,"design-state":!0},null,8,["field","parent-list","index-of-parent-list"]))])])),_:1},8,["list"])],4)])),_:1},8,["label-position","disabled","class","size","label-width"])])),_:1},8,["style"])])}}}; +/* harmony default export */var E=(0,b/* default */.A)(N,[["__scopeId","data-v-7580ec3a"]]),P=n(60358),Q=n(4037); +// EXTERNAL MODULE: ./src/components/lyform-builder/config.js +// ./src/components/lyform-builder/lygenerate/lycode-generate.js +const M=function(e){return`\n\n