@web-utils/component 2.0.9 → 2.0.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (172) hide show
  1. package/dist/chunks/3d28cc08.js +57 -0
  2. package/dist/chunks/{41a066be.js → 44b78389.js} +8 -8
  3. package/dist/chunks/5d33812d.js +147 -0
  4. package/dist/chunks/{61ad06b2.js → 822300f3.js} +3 -3
  5. package/dist/chunks/9d848bf6.js +99 -0
  6. package/dist/chunks/a0bb327b.js +96 -0
  7. package/dist/chunks/a8891d2c.js +30 -0
  8. package/dist/chunks/c69d5628.js +248 -0
  9. package/dist/chunks/de9fe802.js +24 -0
  10. package/dist/chunks/{5a78e0db.js → e1939731.js} +6 -5
  11. package/dist/components/address-input/index.js +56 -43
  12. package/dist/components/address-input/style.css +15 -1
  13. package/dist/components/aside-menu/index.js +36 -30
  14. package/dist/components/aside-menu/style.css +9 -1
  15. package/dist/components/awesome-button/index.js +35 -32
  16. package/dist/components/base.css +66 -1
  17. package/dist/components/capsule-tab/index.js +33 -27
  18. package/dist/components/capsule-tab/style.css +32 -1
  19. package/dist/components/chunk-file-uploader/index.js +88 -54
  20. package/dist/components/chunk-file-uploader/style.css +4 -1
  21. package/dist/components/chunk-file-uploader-button/index.js +31 -25
  22. package/dist/components/chunk-file-uploader-button/style.css +17 -1
  23. package/dist/components/chunk-file-uploader-drop/index.js +42 -28
  24. package/dist/components/chunk-file-uploader-drop/style.css +12 -1
  25. package/dist/components/chunk-file-uploader-file/index.js +212 -134
  26. package/dist/components/chunk-file-uploader-file/style.css +125 -1
  27. package/dist/components/chunk-file-uploader-files/index.js +34 -28
  28. package/dist/components/chunk-file-uploader-files/style.css +9 -1
  29. package/dist/components/chunk-file-uploader-list/index.js +35 -29
  30. package/dist/components/chunk-file-uploader-list/style.css +9 -1
  31. package/dist/components/chunk-file-uploader-un-support/index.js +38 -30
  32. package/dist/components/chunk-file-uploader-un-support/style.css +6 -1
  33. package/dist/components/code-mirror-editor/index.js +181 -153
  34. package/dist/components/code-mirror-editor/style.css +17 -1
  35. package/dist/components/color-picker/index.js +68 -49
  36. package/dist/components/confirm-button/index.js +21 -19
  37. package/dist/components/confirmable/index.js +19 -18
  38. package/dist/components/context-menu/index.js +130 -108
  39. package/dist/components/context-menu/style.css +88 -1
  40. package/dist/components/custom-scrollbar/index.js +67 -49
  41. package/dist/components/data-table-picker/index.js +81 -62
  42. package/dist/components/dynamic-table/index.js +113 -89
  43. package/dist/components/dynamic-table/style.css +30 -1
  44. package/dist/components/e-charts/index.js +201 -120
  45. package/dist/components/e-charts/style.css +10 -1
  46. package/dist/components/editable-progress/index.js +93 -60
  47. package/dist/components/editable-progress/style.css +37 -1
  48. package/dist/components/editable-tree/index.js +638 -423
  49. package/dist/components/editable-tree/style.css +82 -1
  50. package/dist/components/egd-collapse/index.js +46 -33
  51. package/dist/components/egd-collapse-item/index.js +76 -60
  52. package/dist/components/element-dialog/index.js +147 -95
  53. package/dist/components/element-dialog/style.css +102 -1
  54. package/dist/components/empty-view/index.js +34 -28
  55. package/dist/components/empty-view/style.css +17 -1
  56. package/dist/components/error-view/index.js +32 -26
  57. package/dist/components/error-view/style.css +17 -1
  58. package/dist/components/flex-column/index.js +40 -25
  59. package/dist/components/flex-item/index.js +57 -29
  60. package/dist/components/flex-row/index.js +40 -25
  61. package/dist/components/flex-scroller/index.js +32 -26
  62. package/dist/components/flex-scroller/style.css +20 -1
  63. package/dist/components/form-button/index.js +38 -34
  64. package/dist/components/form-cascader/index.js +81 -71
  65. package/dist/components/form-checkbox-group/index.js +113 -88
  66. package/dist/components/form-checkbox-group/style.css +51 -1
  67. package/dist/components/form-date-picker/index.js +132 -70
  68. package/dist/components/form-holder/index.js +39 -32
  69. package/dist/components/form-input/index.js +62 -56
  70. package/dist/components/form-input-email/index.js +60 -48
  71. package/dist/components/form-input-id-card/index.js +59 -53
  72. package/dist/components/form-input-number/index.js +68 -61
  73. package/dist/components/form-input-number/style.css +12 -1
  74. package/dist/components/form-input-phone-number/index.js +55 -49
  75. package/dist/components/form-input-time/index.js +59 -53
  76. package/dist/components/form-item/index.js +123 -80
  77. package/dist/components/form-item/style.css +11 -1
  78. package/dist/components/form-item-config-provider/index.js +26 -25
  79. package/dist/components/form-item-group/index.js +111 -85
  80. package/dist/components/form-item-group/style.css +30 -1
  81. package/dist/components/form-radio-group/index.js +104 -85
  82. package/dist/components/form-radio-group/style.css +53 -1
  83. package/dist/components/form-select/index.js +91 -76
  84. package/dist/components/form-switch/index.js +57 -51
  85. package/dist/components/form-textarea/index.js +57 -51
  86. package/dist/components/form-view/index.js +232 -165
  87. package/dist/components/form-view/style.css +158 -1
  88. package/dist/components/guide-steps/index.js +58 -44
  89. package/dist/components/guide-steps/style.css +34 -1
  90. package/dist/components/icon-card/index.js +35 -29
  91. package/dist/components/icon-card/style.css +56 -1
  92. package/dist/components/iframe-window/index.js +35 -29
  93. package/dist/components/iframe-window/style.css +20 -1
  94. package/dist/components/image-viewer/index.js +66 -48
  95. package/dist/components/image-viewer/style.css +21 -1
  96. package/dist/components/input-number/index.js +193 -127
  97. package/dist/components/input-number/style.css +15 -1
  98. package/dist/components/input-number-range/index.js +57 -45
  99. package/dist/components/input-number-range/style.css +12 -1
  100. package/dist/components/j-s-x-component/index.js +4 -4
  101. package/dist/components/keep-view-alive/index.js +120 -73
  102. package/dist/components/loading-view/index.js +32 -26
  103. package/dist/components/loading-view/style.css +17 -1
  104. package/dist/components/nav-bar/index.js +37 -27
  105. package/dist/components/nav-bar/style.css +17 -1
  106. package/dist/components/not-implement/index.js +31 -23
  107. package/dist/components/not-implement/style.css +15 -1
  108. package/dist/components/page/index.js +28 -22
  109. package/dist/components/page/style.css +12 -1
  110. package/dist/components/page-header/index.js +36 -30
  111. package/dist/components/page-header/style.css +14 -1
  112. package/dist/components/page-index/index.js +83 -62
  113. package/dist/components/page-index/style.css +23 -1
  114. package/dist/components/page-index-top/index.js +68 -53
  115. package/dist/components/page-skeleton/index.js +37 -31
  116. package/dist/components/page-skeleton/style.css +23 -1
  117. package/dist/components/page-skeleton-new/index.js +48 -42
  118. package/dist/components/page-skeleton-new/style.css +42 -1
  119. package/dist/components/pageable-table/index.js +253 -186
  120. package/dist/components/pageable-table/style.css +72 -1
  121. package/dist/components/pageable-view/index.js +199 -129
  122. package/dist/components/pageable-view/style.css +69 -1
  123. package/dist/components/photo-swipe/index.js +151 -110
  124. package/dist/components/photo-swipe/style.css +20 -1
  125. package/dist/components/resize-observer/index.js +68 -34
  126. package/dist/components/resize-observer/style.css +31 -1
  127. package/dist/components/search-popover/index.js +211 -153
  128. package/dist/components/search-popover/style.css +93 -1
  129. package/dist/components/sign-panel/index.js +142 -92
  130. package/dist/components/sign-panel/style.css +97 -1
  131. package/dist/components/split-pane/index.js +162 -101
  132. package/dist/components/split-pane/style.css +100 -1
  133. package/dist/components/stateful/index.js +34 -31
  134. package/dist/components/stateful/style.css +33 -1
  135. package/dist/components/static-pageable-table/index.js +44 -37
  136. package/dist/components/static-pageable-table/style.css +9 -1
  137. package/dist/components/swiper/index.js +150 -85
  138. package/dist/components/swiper/style.css +43 -1
  139. package/dist/components/tab/index.js +72 -54
  140. package/dist/components/tab/style.css +122 -1
  141. package/dist/components/tab-item/index.js +35 -30
  142. package/dist/components/table-column/index.js +32 -30
  143. package/dist/components/table-view/index.js +227 -156
  144. package/dist/components/table-view/style.css +95 -1
  145. package/dist/components/tag-render/index.js +58 -44
  146. package/dist/components/tag-render/style.css +33 -1
  147. package/dist/components/tinymce-editor/index.js +95 -79
  148. package/dist/components/tinymce-editor/style.css +43 -1
  149. package/dist/components/tinymce-wrapper/index.js +121 -92
  150. package/dist/components/tinymce-wrapper/style.css +36 -1
  151. package/dist/components/toolbar/index.js +84 -63
  152. package/dist/components/toolbar/style.css +39 -1
  153. package/dist/components/toolbar-button/index.js +48 -41
  154. package/dist/components/toolbar-button/style.css +21 -1
  155. package/dist/components/trigger/index.js +36 -29
  156. package/dist/components/vue-tags-input/index.js +308 -188
  157. package/dist/components/vue-tags-input/style.css +682 -1
  158. package/dist/components/watermark/index.js +37 -25
  159. package/dist/components/watermark/style.css +11 -1
  160. package/dist/components/x-dialog/index.js +93 -67
  161. package/dist/components/x-dialog/style.css +15 -1
  162. package/dist/index.css +1105 -193
  163. package/dist/index.es.js +7242 -4789
  164. package/package.json +2 -1
  165. package/web-types.json +1 -1
  166. package/dist/chunks/3a79781b.js +0 -75
  167. package/dist/chunks/5d4282fb.js +0 -30
  168. package/dist/chunks/76680a03.js +0 -24
  169. package/dist/chunks/8c0142e0.js +0 -81
  170. package/dist/chunks/97652d86.js +0 -26
  171. package/dist/chunks/b4acd3a6.js +0 -126
  172. package/dist/chunks/f71045fc.js +0 -184
@@ -1,6 +1,6 @@
1
1
  import "tinymce/skins/lightgray/skin.min.css";
2
- import d from "tinymce";
3
- import c from "@tinymce/tinymce-vue";
2
+ import tinymce from "tinymce";
3
+ import Editor from "@tinymce/tinymce-vue";
4
4
  import "tinymce/themes/modern/theme";
5
5
  import "tinymce/plugins/contextmenu";
6
6
  import "tinymce/plugins/wordcount";
@@ -8,9 +8,9 @@ import "tinymce/plugins/image";
8
8
  import "tinymce/plugins/fullscreen";
9
9
  import "tinymce/plugins/preview";
10
10
  import "tinymce/plugins/imagetools";
11
- import { guid as u } from "@web-utils/core";
12
- import { n as p } from "../../chunks/5d4282fb.js";
13
- const m = {
11
+ import { guid } from "@web-utils/core";
12
+ import { n as normalizeComponent } from "../../chunks/3d28cc08.js";
13
+ const zhCN = {
14
14
  Redo: "重做",
15
15
  Undo: "撤销",
16
16
  Cut: "剪切",
@@ -400,51 +400,55 @@ const m = {
400
400
  Caption: "标题",
401
401
  "Insert template": "插入模板"
402
402
  };
403
- var g = function() {
404
- var e = this, a = e.$createElement, i = e._self._c || a;
405
- return e.show ? i("div", {
403
+ var render = function() {
404
+ var _vm = this;
405
+ var _h = _vm.$createElement;
406
+ var _c = _vm._self._c || _h;
407
+ return _vm.show ? _c("div", {
406
408
  class: ["tinymce-editor", {
407
- "none-resize": !e.resize
409
+ "none-resize": !_vm.resize
408
410
  }]
409
- }, [i("Editor", {
411
+ }, [_c("Editor", {
410
412
  ref: "editor",
411
413
  attrs: {
412
- disabled: e.inputDisabled,
414
+ "disabled": _vm.inputDisabled,
413
415
  "model-events": "change input undo redo SetContent",
414
- init: e.init
416
+ "init": _vm.init
415
417
  },
416
418
  model: {
417
- value: e.val,
418
- callback: function(r) {
419
- e.val = r;
419
+ value: _vm.val,
420
+ callback: function($$v) {
421
+ _vm.val = $$v;
420
422
  },
421
423
  expression: "val"
422
424
  }
423
- }), i("ElUpload", {
425
+ }), _c("ElUpload", {
424
426
  ref: "uploader",
425
427
  staticStyle: {
426
- display: "none"
428
+ "display": "none"
427
429
  },
428
430
  attrs: {
429
- action: e.action,
430
- headers: e.headers,
431
- "before-upload": e.beforeUploadFile,
432
- "on-success": e.onFileUploadSuccess,
433
- "show-file-list": !1,
434
- data: {
435
- unid: e.guid(),
436
- type: e.fileLabel
431
+ "action": _vm.action,
432
+ "headers": _vm.headers,
433
+ "before-upload": _vm.beforeUploadFile,
434
+ "on-success": _vm.onFileUploadSuccess,
435
+ "show-file-list": false,
436
+ "data": {
437
+ unid: _vm.guid(),
438
+ type: _vm.fileLabel
437
439
  },
438
440
  "auto-upload": "",
439
- accept: ".jpg,.jpeg,.png,.gif,.bmp"
441
+ "accept": ".jpg,.jpeg,.png,.gif,.bmp"
440
442
  }
441
- }, [i("span")])], 1) : e._e();
442
- }, h = [];
443
- d.addI18n("zh_CN", m);
444
- const f = {
443
+ }, [_c("span")])], 1) : _vm._e();
444
+ };
445
+ var staticRenderFns = [];
446
+ const TinymceWrapper_vue_vue_type_style_index_0_lang = "";
447
+ tinymce.addI18n("zh_CN", zhCN);
448
+ const __vue2_script = {
445
449
  name: "TinymceWrapper",
446
450
  components: {
447
- Editor: c
451
+ Editor
448
452
  },
449
453
  inject: {
450
454
  elForm: {
@@ -462,11 +466,11 @@ const f = {
462
466
  resize: Boolean,
463
467
  disabled: {
464
468
  type: Boolean,
465
- default: !1
469
+ default: false
466
470
  },
467
471
  showTypes: {
468
472
  type: Boolean,
469
- default: !0
473
+ default: true
470
474
  },
471
475
  plugins: {
472
476
  type: [String, Array],
@@ -489,53 +493,67 @@ const f = {
489
493
  imageUrl: String
490
494
  },
491
495
  data() {
492
- const a = ["fullscreen", "image", "wordcount"].join(","), i = this.buttons || [];
493
- let r = this.toolbar || " | ";
494
- return r = `bold italic underline | alignleft aligncenter alignright alignjustify | fontselect fontsizeselect | removeformat | | ${r}`, i && (r += ` ${i.map((o) => o.name).join(" ")}`), r += " | fullscreen", {
496
+ const plugins = ["fullscreen", "image", "wordcount"];
497
+ const defaultPlugins = plugins.join(",");
498
+ const buttons = this.buttons || [];
499
+ let toolbar = this.toolbar || " | ";
500
+ const defaultToolbar = "bold italic underline | alignleft aligncenter alignright alignjustify | fontselect fontsizeselect | removeformat | ";
501
+ toolbar = `${defaultToolbar} | ${toolbar}`;
502
+ if (buttons) {
503
+ toolbar += ` ${buttons.map((value) => value.name).join(" ")}`;
504
+ }
505
+ toolbar += " | fullscreen";
506
+ return {
495
507
  val: "",
496
- show: !0,
508
+ show: true,
497
509
  init: {
498
- setup: (o) => {
499
- o.settings.dialog_title = this.dialogTitle, o.settings.show_types = this.showTypes, o.on("PreInit", (t) => {
500
- t.target.dom.doc.body.style.fontFamily = "微软雅黑";
501
- }), o.on("Blur", (t) => {
502
- this.$emit("on-blur", t);
503
- }), o.on("DialogShow", (t) => {
504
- this.$emit("dialog-show", t);
505
- }), o.on("DialogHide", (t) => {
506
- this.$emit("dialog-hide", t);
507
- }), i.forEach((t) => {
508
- t.icon = ` ${t.icon}`;
509
- const { onclick: s } = t;
510
- o.addButton(t.name, {
511
- ...t,
512
- onclick: () => s(o)
510
+ setup: (editor) => {
511
+ editor.settings.dialog_title = this.dialogTitle;
512
+ editor.settings.show_types = this.showTypes;
513
+ editor.on("PreInit", (event) => {
514
+ event.target.dom.doc.body.style.fontFamily = "微软雅黑";
515
+ });
516
+ editor.on("Blur", (event) => {
517
+ this.$emit("on-blur", event);
518
+ });
519
+ editor.on("DialogShow", (event) => {
520
+ this.$emit("dialog-show", event);
521
+ });
522
+ editor.on("DialogHide", (event) => {
523
+ this.$emit("dialog-hide", event);
524
+ });
525
+ buttons.forEach((btn) => {
526
+ btn.icon = ` ${btn.icon}`;
527
+ const { onclick } = btn;
528
+ editor.addButton(btn.name, {
529
+ ...btn,
530
+ onclick: () => onclick(editor)
513
531
  });
514
532
  });
515
- const n = {
533
+ const uploadButton = {
516
534
  icon: " el-icon-picture",
517
535
  name: "uploadImage",
518
536
  title: "上传图片",
519
537
  onclick: this.upload
520
538
  };
521
- o.addButton(n.name, {
522
- ...n,
523
- onclick: () => n.onclick(o)
539
+ editor.addButton(uploadButton.name, {
540
+ ...uploadButton,
541
+ onclick: () => uploadButton.onclick(editor)
524
542
  });
525
543
  },
526
- toolbar: r,
544
+ toolbar,
527
545
  placeholder: "在这里输入文字",
528
546
  content_style: "*{margin:0;padding:0} body{font-family: 微软雅黑, sans-serif;padding:10px; font-size: 18px} .template-tag {font-style: italic;color: #1e90ff;margin: 0 10px;font-weight: bold;cursor: help !important;font-family: 黑体,serif;}",
529
547
  fontname: "宋体",
530
548
  fontFamily: "宋体",
531
- branding: !1,
549
+ branding: false,
532
550
  query_params: this.queryParams,
533
- skin: !1,
551
+ skin: false,
534
552
  dialog_title: "",
535
- menubar: !1,
553
+ menubar: false,
536
554
  height: "100%",
537
- elementpath: !1,
538
- plugins: `${a},${this.plugins}`,
555
+ elementpath: false,
556
+ plugins: `${defaultPlugins},${this.plugins}`,
539
557
  font_formats: '微软雅黑="微软雅黑";宋体="宋体";黑体="黑体";仿宋="仿宋";楷体="楷体";隶书="隶书";幼圆="幼圆";Arial="Arial";'
540
558
  }
541
559
  };
@@ -545,42 +563,51 @@ const f = {
545
563
  return this.disabled || (this.elForm || {}).disabled;
546
564
  },
547
565
  fileLabel() {
548
- return this.prop ? this.prop : this.elFormItem ? this.elFormItem.prop : "";
566
+ if (this.prop) {
567
+ return this.prop;
568
+ } else if (this.elFormItem) {
569
+ return this.elFormItem.prop;
570
+ } else {
571
+ return "";
572
+ }
549
573
  },
550
574
  action() {
551
- var e;
552
- return (e = this.getUploadUrl) == null ? void 0 : e.call(this);
575
+ var _a;
576
+ return (_a = this.getUploadUrl) == null ? void 0 : _a.call(this);
553
577
  },
554
578
  headers() {
555
- var e;
556
- return (e = this.getHeader) == null ? void 0 : e.call(this);
579
+ var _a;
580
+ return (_a = this.getHeader) == null ? void 0 : _a.call(this);
557
581
  }
558
582
  },
559
583
  watch: {
560
584
  value: {
561
- immediate: !0,
562
- handler(e) {
563
- this.val = e;
585
+ immediate: true,
586
+ handler(newVal) {
587
+ this.val = newVal;
564
588
  }
565
589
  },
566
- dialogTitle(e) {
567
- this.getEditor() && (this.getEditor().settings.dialog_title = e);
590
+ dialogTitle(newVal) {
591
+ if (this.getEditor()) {
592
+ this.getEditor().settings.dialog_title = newVal;
593
+ }
568
594
  },
569
- val(e) {
570
- this.elForm && this.elFormItem && this.elForm.clearValidate([this.elFormItem.prop]), this.$emit("input", e);
595
+ val(newVal) {
596
+ this.elForm && this.elFormItem && this.elForm.clearValidate([this.elFormItem.prop]);
597
+ this.$emit("input", newVal);
571
598
  }
572
599
  },
573
600
  deactivated() {
574
- this.show = !1;
601
+ this.show = false;
575
602
  },
576
603
  activated() {
577
- this.show = !0;
604
+ this.show = true;
578
605
  },
579
606
  methods: {
580
607
  getEditor() {
581
608
  return this.$refs.editor.editor;
582
609
  },
583
- guid: u,
610
+ guid,
584
611
  focus() {
585
612
  this.getEditor().focus();
586
613
  },
@@ -589,30 +616,32 @@ const f = {
589
616
  },
590
617
  beforeUploadFile() {
591
618
  },
592
- onFileUploadSuccess(e) {
619
+ onFileUploadSuccess(res) {
593
620
  this.getEditor().insertContent(
594
- `<img alt="图片" src="${e.data.filePath.replace("/var/local/data/merge", this.imageUrl || "")}"/>`
621
+ `<img alt="图片" src="${res.data.filePath.replace("/var/local/data/merge", this.imageUrl || "")}"/>`
595
622
  );
596
623
  }
597
624
  }
598
- }, l = {};
599
- var y = /* @__PURE__ */ p(
600
- f,
601
- g,
602
- h,
603
- !1,
604
- w,
625
+ };
626
+ const __cssModules = {};
627
+ var __component__ = /* @__PURE__ */ normalizeComponent(
628
+ __vue2_script,
629
+ render,
630
+ staticRenderFns,
631
+ false,
632
+ __vue2_injectStyles,
605
633
  null,
606
634
  null,
607
635
  null
608
636
  );
609
- function w(e) {
610
- for (let a in l)
611
- this[a] = l[a];
637
+ function __vue2_injectStyles(context) {
638
+ for (let o in __cssModules) {
639
+ this[o] = __cssModules[o];
640
+ }
612
641
  }
613
- const D = /* @__PURE__ */ function() {
614
- return y.exports;
642
+ const TinymceWrapper = /* @__PURE__ */ function() {
643
+ return __component__.exports;
615
644
  }();
616
645
  export {
617
- D as default
646
+ TinymceWrapper as default
618
647
  };
@@ -1 +1,36 @@
1
- .tinymce-editor{height:100%}.tinymce-editor.none-resize .mce-resizehandle{display:none}.tinymce-editor .mce-tinymce{flex:1;height:calc(100% - 4px)}.tinymce-editor .mce-tinymce .mce-menubtn.mce-fixed-width span{width:60px}.tinymce-editor .mce-tinymce>.mce-container-body{display:flex;flex-direction:column;height:100%}.tinymce-editor .mce-tinymce>.mce-container-body>.mce-edit-area{flex:1}.tinymce-editor .fa-icon{font: 14px/1 FontAwesome!important}.tinymce-editor .el-icon{font-family:element-icons,serif!important}.tinymce-editor .mce-label{display:none}
1
+ /* 全局公共颜色配置 */ /* 全局公共尺寸配置 */
2
+ /* 应用头部高度 */
3
+ /* 页面宽度 */
4
+ /* 侧栏宽度 */
5
+ /* 标签高度 */
6
+ /* 页面头部工具条高度 */
7
+ .tinymce-editor {
8
+ height: 100%;
9
+ }
10
+ .tinymce-editor.none-resize .mce-resizehandle {
11
+ display: none;
12
+ }
13
+ .tinymce-editor .mce-tinymce {
14
+ flex: 1;
15
+ height: calc(100% - 4px);
16
+ }
17
+ .tinymce-editor .mce-tinymce .mce-menubtn.mce-fixed-width span {
18
+ width: 60px;
19
+ }
20
+ .tinymce-editor .mce-tinymce > .mce-container-body {
21
+ display: flex;
22
+ flex-direction: column;
23
+ height: 100%;
24
+ }
25
+ .tinymce-editor .mce-tinymce > .mce-container-body > .mce-edit-area {
26
+ flex: 1;
27
+ }
28
+ .tinymce-editor .fa-icon {
29
+ font: normal normal normal 14px/1 FontAwesome !important;
30
+ }
31
+ .tinymce-editor .el-icon {
32
+ font-family: element-icons, serif !important;
33
+ }
34
+ .tinymce-editor .mce-label {
35
+ display: none;
36
+ }
@@ -1,6 +1,6 @@
1
- import { NOOP as h } from "@web-utils/core";
2
- import { n as b } from "../../chunks/5d4282fb.js";
3
- const p = {
1
+ import { NOOP } from "@web-utils/core";
2
+ import { n as normalizeComponent } from "../../chunks/3d28cc08.js";
3
+ const builtinButtons = {
4
4
  back: {
5
5
  label: "返回",
6
6
  type: "primary",
@@ -93,9 +93,10 @@ const p = {
93
93
  search: {
94
94
  label: "搜索",
95
95
  icon: "el-icon-search",
96
- separateLine: !1
96
+ separateLine: false
97
97
  }
98
- }, f = {
98
+ };
99
+ const __vue2_script = {
99
100
  name: "Toolbar",
100
101
  provide() {
101
102
  return {
@@ -126,92 +127,112 @@ const p = {
126
127
  },
127
128
  methods: {
128
129
  goBack() {
129
- const e = this.$route.path;
130
- this.$bus("closeTab", e, this);
130
+ const path = this.$route.path;
131
+ this.$bus("closeTab", path, this);
131
132
  },
132
- fire(e, t) {
133
- this.emitter === "parent" ? this.$parent && this.$parent.$emit(e, t, this) : this.$emit(e, t, this);
133
+ fire(type, event) {
134
+ if (this.emitter === "parent") {
135
+ this.$parent && this.$parent.$emit(type, event, this);
136
+ } else {
137
+ this.$emit(type, event, this);
138
+ }
134
139
  },
135
- createButton(e, {
136
- label: t,
137
- icon: o,
138
- type: i,
139
- separateLine: a = !0
140
+ createButton(key, {
141
+ label,
142
+ icon,
143
+ type,
144
+ separateLine = true
140
145
  }) {
141
- var r;
142
- const n = this.$createElement;
143
- let l;
144
- const s = ((r = this.label) == null ? void 0 : r[e]) || t;
145
- return ["back", "cancel"].includes(e) ? l = this.goBack : l = (c) => (this.$listeners[e] || h)(c), n("ToolbarButton", {
146
- attrs: {
147
- "separate-line": a,
148
- icon: o,
149
- label: s,
150
- footer: this.footer,
151
- type: i
146
+ var _a;
147
+ const h = this.$createElement;
148
+ let handler;
149
+ const buttonLabel = ((_a = this.label) == null ? void 0 : _a[key]) || label;
150
+ if (!["back", "cancel"].includes(key)) {
151
+ handler = (e) => (this.$listeners[key] || NOOP)(e);
152
+ } else {
153
+ handler = this.goBack;
154
+ }
155
+ return h("ToolbarButton", {
156
+ "attrs": {
157
+ "separate-line": separateLine,
158
+ "icon": icon,
159
+ "label": buttonLabel,
160
+ "footer": this.footer,
161
+ "type": type
152
162
  },
153
- on: {
154
- click: l
163
+ "on": {
164
+ "click": handler
155
165
  }
156
166
  });
157
167
  },
158
168
  getLeftButtons() {
159
- var o, i;
169
+ var _a, _b;
160
170
  const {
161
- createButton: e
171
+ createButton
162
172
  } = this;
163
- return ((i = (o = this.$scopedSlots)["toolbar-left"]) == null ? void 0 : i.call(o)) || this.buttons.map((a) => {
164
- var l, s, r, c;
165
- const n = p[a];
166
- return n ? ((s = (l = this.$scopedSlots)[a]) == null ? void 0 : s.call(l)) || e(a, n) : a === "slot" ? ((c = (r = this.$scopedSlots).default) == null ? void 0 : c.call(r, {
167
- buttons: this.buttons,
168
- footer: this.footer
169
- })) ?? null : null;
173
+ const toolbarLeft = (_b = (_a = this.$scopedSlots)["toolbar-left"]) == null ? void 0 : _b.call(_a);
174
+ return toolbarLeft || this.buttons.map((key) => {
175
+ var _a2, _b2, _c, _d;
176
+ const button = builtinButtons[key];
177
+ if (button) {
178
+ const vNodes = (_b2 = (_a2 = this.$scopedSlots)[key]) == null ? void 0 : _b2.call(_a2);
179
+ return vNodes || createButton(key, button);
180
+ } else if (key === "slot") {
181
+ return ((_d = (_c = this.$scopedSlots).default) == null ? void 0 : _d.call(_c, {
182
+ buttons: this.buttons,
183
+ footer: this.footer
184
+ })) ?? null;
185
+ } else {
186
+ return null;
187
+ }
170
188
  });
171
189
  },
172
190
  getRightButtons() {
173
- var t, o;
174
- return ((o = (t = this.$scopedSlots)["toolbar-right"]) == null ? void 0 : o.call(t)) || this.getSearchButton();
191
+ var _a, _b;
192
+ const vNodes = (_b = (_a = this.$scopedSlots)["toolbar-right"]) == null ? void 0 : _b.call(_a);
193
+ return vNodes || this.getSearchButton();
175
194
  },
176
195
  getSearchButton() {
177
196
  const {
178
- createButton: e
197
+ createButton
179
198
  } = this;
180
- return this.searchable ? e("search", p.search) : null;
199
+ return this.searchable ? createButton("search", builtinButtons.search) : null;
181
200
  }
182
201
  },
183
202
  render() {
184
- const e = arguments[0];
185
- return this.footer ? e("div", {
186
- class: "footer-bar"
187
- }, [this.getLeftButtons()]) : e("div", {
188
- class: "toolbar"
189
- }, [e("div", {
190
- class: "toolbar-left"
191
- }, [this.getLeftButtons()]), e("div", {
192
- class: "toolbar-right"
203
+ const h = arguments[0];
204
+ return this.footer ? h("div", {
205
+ "class": "footer-bar"
206
+ }, [this.getLeftButtons()]) : h("div", {
207
+ "class": "toolbar"
208
+ }, [h("div", {
209
+ "class": "toolbar-left"
210
+ }, [this.getLeftButtons()]), h("div", {
211
+ "class": "toolbar-right"
193
212
  }, [this.getRightButtons()])]);
194
213
  }
195
214
  };
196
- let d, y;
197
- const u = {};
198
- var m = /* @__PURE__ */ b(
199
- f,
200
- d,
201
- y,
202
- !1,
203
- _,
215
+ const Toolbar_vue_vue_type_style_index_0_lang = "";
216
+ let __vue2_render, __vue2_staticRenderFns;
217
+ const __cssModules = {};
218
+ var __component__ = /* @__PURE__ */ normalizeComponent(
219
+ __vue2_script,
220
+ __vue2_render,
221
+ __vue2_staticRenderFns,
222
+ false,
223
+ __vue2_injectStyles,
204
224
  null,
205
225
  null,
206
226
  null
207
227
  );
208
- function _(e) {
209
- for (let t in u)
210
- this[t] = u[t];
228
+ function __vue2_injectStyles(context) {
229
+ for (let o in __cssModules) {
230
+ this[o] = __cssModules[o];
231
+ }
211
232
  }
212
- const $ = /* @__PURE__ */ function() {
213
- return m.exports;
233
+ const Toolbar = /* @__PURE__ */ function() {
234
+ return __component__.exports;
214
235
  }();
215
236
  export {
216
- $ as default
237
+ Toolbar as default
217
238
  };
@@ -1 +1,39 @@
1
- .toolbar{display:flex;height:40px;padding:0 10px;line-height:40px;background-color:#fff;border-bottom:1px solid #e5e9ec}.toolbar .toolbar-left{flex:1 1 auto}.toolbar .toolbar-left>.form-toolbar-button:last-child .separate-line{display:none}.toolbar .toolbar-left [class*=" el-icon-"],.toolbar .toolbar-left [class^=el-icon-],.toolbar .toolbar-left i.fa{margin-top:-1px;color:#1989fa;font-size:15px}.toolbar .toolbar-right .el-button{display:inline-flex;align-items:center}.footer-bar{display:flex;flex-direction:row;align-items:center;justify-content:center;padding-top:10px}.footer-bar .el-button{padding:10px 40px}
1
+ /* 全局公共颜色配置 */ /* 全局公共尺寸配置 */
2
+ /* 应用头部高度 */
3
+ /* 页面宽度 */
4
+ /* 侧栏宽度 */
5
+ /* 标签高度 */
6
+ /* 页面头部工具条高度 */
7
+ .toolbar {
8
+ display: flex;
9
+ height: 40px;
10
+ padding: 0 10px;
11
+ line-height: 40px;
12
+ background-color: #fff;
13
+ border-bottom: 1px solid #e5e9ec;
14
+ }
15
+ .toolbar .toolbar-left {
16
+ flex: 1 1 auto;
17
+ }
18
+ .toolbar .toolbar-left > .form-toolbar-button:last-child .separate-line {
19
+ display: none;
20
+ }
21
+ .toolbar .toolbar-left [class*=" el-icon-"], .toolbar .toolbar-left [class^=el-icon-], .toolbar .toolbar-left i.fa {
22
+ margin-top: -1px;
23
+ color: #1989fa;
24
+ font-size: 15px;
25
+ }
26
+ .toolbar .toolbar-right .el-button {
27
+ display: inline-flex;
28
+ align-items: center;
29
+ }
30
+ .footer-bar {
31
+ display: flex;
32
+ flex-direction: row;
33
+ align-items: center;
34
+ justify-content: center;
35
+ padding-top: 10px;
36
+ }
37
+ .footer-bar .el-button {
38
+ padding: 10px 40px;
39
+ }