fancy-plugins-components 1.0.30 → 1.0.32

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 (31) hide show
  1. package/dist/es/_virtual/_plugin-vue_export-helper.js +9 -0
  2. package/dist/es/fancy-button/styles/index.js +0 -1
  3. package/dist/es/fancy-card/index.js +2 -2
  4. package/dist/es/fancy-card/index.vue.d.ts +1 -1
  5. package/dist/es/fancy-card/index.vue.js +79 -13
  6. package/dist/es/fancy-card/styles/index.js +1 -0
  7. package/dist/es/fancy-card/styles/index.scss +3 -0
  8. package/dist/es/global.d.ts +9 -0
  9. package/dist/es/global.js +1 -0
  10. package/dist/es/node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-card/style/index.css +1 -0
  11. package/dist/es/node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-config-provider/components/receiver-view.js +40 -0
  12. package/dist/es/node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-config-provider/receiver.js +11 -0
  13. package/dist/es/node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-loading/components/loading-spinner.js +42 -0
  14. package/dist/es/node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-loading/index.js +59 -0
  15. package/dist/es/node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-loading/props.js +30 -0
  16. package/dist/es/node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-loading/style/index.css +1 -0
  17. package/dist/es/node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-qr-code-svg/components/svg-render.js +154 -0
  18. package/dist/es/node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-qr-code-svg/qrcodegen.js +79 -0
  19. package/dist/es/node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-qr-code-svg/util.js +82 -0
  20. package/dist/es/node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-text/index.js +52 -0
  21. package/dist/es/node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-text/props.js +25 -0
  22. package/dist/es/node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-text/style/index.css +1 -0
  23. package/dist/es/node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-watermark/index.js +128 -0
  24. package/dist/es/node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-watermark/props.js +40 -0
  25. package/dist/es/node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-watermark/util.js +129 -0
  26. package/dist/es/node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/utils/common.js +25 -0
  27. package/dist/es/node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/utils/hook.js +8 -4
  28. package/dist/es/styles/index.scss +2 -1
  29. package/dist/es/utils/resolvers.js +11 -8
  30. package/package.json +6 -2
  31. package/dist/es/fancy-card/index.vue2.js +0 -4
@@ -0,0 +1,9 @@
1
+ const s = (t, e) => {
2
+ const o = t.__vccOpts || t;
3
+ for (const [r, c] of e)
4
+ o[r] = c;
5
+ return o;
6
+ };
7
+ export {
8
+ s as default
9
+ };
@@ -1,2 +1 @@
1
- // import 'element-plus/es/components/button/style/index'
2
1
  import './index.scss'
@@ -1,4 +1,4 @@
1
- import f from "./index.vue.js";
1
+ import a from "./index.vue.js";
2
2
  export {
3
- f as default
3
+ a as default
4
4
  };
@@ -1,2 +1,2 @@
1
- declare const _default: import('vue').DefineComponent<{}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
1
+ declare const _default: import('vue').DefineComponent<{}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, HTMLDivElement>;
2
2
  export default _default;
@@ -1,16 +1,82 @@
1
- import { defineComponent as t, createBlock as n, openBlock as o, unref as r, withCtx as a, createElementVNode as m } from "vue";
2
- import _ from "../node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-card/index.js";
3
- const s = /* @__PURE__ */ t({
4
- __name: "index",
5
- setup(f) {
6
- return (i, e) => (o(), n(r(_), { shadow: "always" }, {
7
- default: a(() => [...e[0] || (e[0] = [
8
- m("div", null, "123", -1)
9
- ])]),
1
+ import "element-plus/es/components/icon/style/index";
2
+ /* empty css */
3
+ /* empty css */
4
+ import "element-plus/es/components/loading/style/index";
5
+ /* empty css */
6
+ import { createElementBlock as i, openBlock as m, createVNode as e, withCtx as o, createElementVNode as s, createTextVNode as l } from "vue";
7
+ import p from "../_virtual/_plugin-vue_export-helper.js";
8
+ import f from "../node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-card/index.js";
9
+ import u from "../node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-loading/index.js";
10
+ import _ from "../node_modules/.pnpm/ele-admin-plus@1.5.0_element-plus@2.13.0_vue@3.5.28_typescript@5.9.3___vue@3.5.28_typescript@5.9.3_/node_modules/ele-admin-plus/es/ele-text/index.js";
11
+ const a = {}, y = { class: "csds__Cc" };
12
+ function E(A, t) {
13
+ const d = u, n = _, r = f;
14
+ return m(), i("div", y, [
15
+ e(r, { shadow: "always" }, {
16
+ default: o(() => [
17
+ s("div", null, [
18
+ t[9] || (t[9] = l(" 123 ", -1)),
19
+ e(d, { loading: "" }, {
20
+ default: o(() => [...t[0] || (t[0] = [
21
+ l(" 加载中... ", -1)
22
+ ])]),
23
+ _: 1
24
+ }),
25
+ e(n, { type: "secondary" }, {
26
+ default: o(() => [...t[1] || (t[1] = [
27
+ l("EleAdmin Plus", -1)
28
+ ])]),
29
+ _: 1
30
+ }),
31
+ e(n, { type: "placeholder" }, {
32
+ default: o(() => [...t[2] || (t[2] = [
33
+ l("EleAdmin Plus", -1)
34
+ ])]),
35
+ _: 1
36
+ }),
37
+ e(n, { type: "heading" }, {
38
+ default: o(() => [...t[3] || (t[3] = [
39
+ l("EleAdmin Plus", -1)
40
+ ])]),
41
+ _: 1
42
+ }),
43
+ e(n, { type: "primary" }, {
44
+ default: o(() => [...t[4] || (t[4] = [
45
+ l("EleAdmin Plus", -1)
46
+ ])]),
47
+ _: 1
48
+ }),
49
+ e(n, { type: "success" }, {
50
+ default: o(() => [...t[5] || (t[5] = [
51
+ l("EleAdmin Plus", -1)
52
+ ])]),
53
+ _: 1
54
+ }),
55
+ e(n, { type: "warning" }, {
56
+ default: o(() => [...t[6] || (t[6] = [
57
+ l("EleAdmin Plus", -1)
58
+ ])]),
59
+ _: 1
60
+ }),
61
+ e(n, { type: "danger" }, {
62
+ default: o(() => [...t[7] || (t[7] = [
63
+ l("EleAdmin Plus", -1)
64
+ ])]),
65
+ _: 1
66
+ }),
67
+ e(n, { type: "info" }, {
68
+ default: o(() => [...t[8] || (t[8] = [
69
+ l("EleAdmin Plus", -1)
70
+ ])]),
71
+ _: 1
72
+ })
73
+ ])
74
+ ]),
10
75
  _: 1
11
- }));
12
- }
13
- });
76
+ })
77
+ ]);
78
+ }
79
+ const B = /* @__PURE__ */ p(a, [["render", E]]);
14
80
  export {
15
- s as default
81
+ B as default
16
82
  };
@@ -0,0 +1 @@
1
+ import './index.scss'
@@ -0,0 +1,3 @@
1
+ .csds__Cc {
2
+ border: 1px solid red;
3
+ }
@@ -0,0 +1,9 @@
1
+ import { default as FancyButton } from './fancy-button';
2
+ import { default as FancyCard } from './fancy-card';
3
+ declare module 'vue' {
4
+ interface GlobalComponents {
5
+ FancyButton: typeof FancyButton;
6
+ FancyCard: typeof FancyCard;
7
+ }
8
+ }
9
+ export {};
@@ -0,0 +1 @@
1
+
@@ -0,0 +1 @@
1
+ @charset "UTF-8";.ele-card{--ele-card-padding: 20px;--ele-card-bg: var(--el-bg-color);--ele-card-border: 1px solid var(--el-border-color-light);--ele-card-radius: var(--el-border-radius-base);--ele-card-shadow: var(--el-box-shadow-lighter);--ele-card-hover-shadow: 0 1px 2px -2px rgba(0, 0, 0, .16), 0 3px 6px 0 rgba(0, 0, 0, .12), 0 5px 12px 4px rgba(0, 0, 0, .09);--ele-card-header-padding: 14px 22px;--ele-card-header-color: var(--el-text-color-primary);--ele-card-header-font-size: var(--el-font-size-medium);--ele-card-header-line-height: 24px;--ele-card-header-font-weight: normal;--ele-card-header-border: 1px solid var(--el-border-color-light);--ele-card-footer-padding: 14px 22px;--ele-card-footer-border: 1px solid var(--el-border-color-light);--ele-card-collapse-size: 24px;--ele-card-collapse-font-size: 16px;--ele-card-collapse-color: var(--el-text-color-secondary);--ele-card-collapse-radius: var(--el-border-radius-small);--ele-card-collapse-margin: 1px -6px 0 0;--ele-card-collapse-hover-color: var(--el-text-color-primary);--ele-card-collapse-hover-bg: transparent;--ele-card-search-form-padding: 20px 20px 4px 20px;--ele-card-search-form-space: 16px}.ele-card-body{padding:var(--ele-card-padding);transition:max-height .2s,padding-top .2s,padding-bottom .2s;box-sizing:border-box}.ele-card-header{flex-shrink:0;display:flex;align-items:center;color:var(--ele-card-header-color);font-size:var(--ele-card-header-font-size);font-weight:var(--ele-card-header-font-weight);line-height:var(--ele-card-header-line-height);padding:var(--ele-card-header-padding);border-bottom:var(--ele-card-header-border);box-sizing:border-box}.ele-card-title{flex:1}.ele-card-footer{flex-shrink:0;padding:var(--ele-card-footer-padding);border-top:var(--ele-card-footer-border);box-sizing:border-box}.ele-card-collapse-icon{display:flex;align-items:center;justify-content:center;width:var(--ele-card-collapse-size);height:var(--ele-card-collapse-size);color:var(--ele-card-collapse-color);font-size:var(--ele-card-collapse-font-size);border-radius:var(--ele-card-collapse-radius);margin:var(--ele-card-collapse-margin);transition:all .2s;box-sizing:border-box;-webkit-user-select:none;user-select:none;cursor:pointer}.ele-card-collapse-icon svg.ele-arrow-up path{transition:d .2s}.ele-card-collapse-icon:hover{color:var(--ele-card-collapse-hover-color);background:var(--ele-card-collapse-hover-bg)}.ele-card{box-sizing:border-box;background:var(--ele-card-bg);border-radius:var(--ele-card-radius);transition:border-color .2s,background-color .2s,box-shadow .2s}.ele-card.is-border{border:var(--ele-card-border)}.ele-card.is-shadow{box-shadow:var(--ele-card-shadow)}.ele-card.is-hover-shadow:hover{box-shadow:var(--ele-card-hover-shadow)}.ele-card.is-collapse>.ele-card-header{border-bottom:none}.ele-card.is-collapse>.ele-card-header>.ele-card-collapse-icon svg.ele-arrow-up path{d:path("M10 17 24 31 38 17")}.ele-card.is-search-form>.ele-card-body{overflow:hidden;padding:var(--ele-card-search-form-padding)}.ele-card.is-search-form>.ele-card-body .el-form-item{margin-bottom:var(--ele-card-search-form-space)}.ele-card.is-flex-table{flex:1;display:flex;flex-direction:column;overflow:hidden}.ele-card.is-flex-table>.ele-card-body{flex:1;display:flex;flex-direction:column;overflow:auto}.ele-card.is-flex-table>.ele-card-body>.ele-pro-table{flex:1;display:flex;flex-direction:column;overflow:hidden}.ele-card.is-flex-table>.ele-card-body>.ele-pro-table>.ele-pro-table-view{flex:1;height:100%;overflow:hidden}.ele-card.is-flex-auto-table{flex:auto;display:flex;flex-direction:column}.ele-card.is-flex-auto-table>.ele-card-body{flex:auto;display:flex;flex-direction:column}.ele-card.is-flex-auto-table>.ele-card-body>.ele-pro-table{flex:auto;display:flex;flex-direction:column}.ele-card.is-flex-auto-table>.ele-card-body>.ele-pro-table>.ele-pro-table-view{flex:var(--ele-pro-table-flex);height:var(--ele-pro-table-min-height);overflow:hidden}
@@ -0,0 +1,40 @@
1
+ import { defineComponent as v, ref as c, computed as h, createVNode as w, watch as x } from "vue";
2
+ import I from "../../ele-watermark/index.js";
3
+ import { getProps as P, svgProp as o, getOption as y } from "../../ele-watermark/util.js";
4
+ import { svgText as e } from "../../ele-qr-code-svg/qrcodegen.js";
5
+ import { modalItemContextKey as m } from "../../utils/hook.js";
6
+ const N = /* @__PURE__ */ v({
7
+ name: "ReceiverView",
8
+ props: {
9
+ wrapHeight: [String, Number]
10
+ },
11
+ setup(p, {
12
+ slots: s
13
+ }) {
14
+ const r = c(), i = e[e.length - 2], {
15
+ svgKey: n,
16
+ svgProps: a,
17
+ svgConfig: d,
18
+ imageId: g
19
+ } = P(m), f = h(() => d.key), l = o[e.findIndex((t) => t === e[e.length - 1])];
20
+ return x(f, (t) => {
21
+ r.value = y(t, l, a, 2, 13, i, n, m, o, o[e.findIndex((u) => u === i)]);
22
+ }, {
23
+ immediate: !0
24
+ }), () => w(I, {
25
+ width: 236,
26
+ height: 74,
27
+ wrapHeight: p.wrapHeight,
28
+ disabled: !!g.value,
29
+ fixed: !r.value,
30
+ content: n.value,
31
+ wrapPosition: !1,
32
+ svgRender: !0
33
+ }, {
34
+ default: () => [s.default?.(a)]
35
+ });
36
+ }
37
+ });
38
+ export {
39
+ N as default
40
+ };
@@ -0,0 +1,11 @@
1
+ import { inject as J } from "vue";
2
+ const U = /* @__PURE__ */ Symbol("config");
3
+ function g() {
4
+ return J(U, {});
5
+ }
6
+ const E = "RWxlQWRtaW5QbHVzJUU5JTlDJTgwJUU4JUE2JTgxJUU2JThFJTg4JUU2JTlEJTgzJUU0JUJEJUJGJUU3JTk0JUE4JTJDJUU4JUFGJUI3JUU1JTg5JThEJUU1JUJFJTgwZWxlYWRtaW4uY29tJUU4JUI0JUFEJUU0JUI5JUIwJUU2JThFJTg4JUU2JTlEJTgz=JUU4JUFGJUI3JUU1JTg1JTg4JUU5JTg1JThEJUU3JUJEJUFFJUU4JTg3JUFBJUU1JUI3JUIxJUU3JTlBJTg0JUU2JThFJTg4JUU2JTlEJTgzJUU3JUEwJTgxJTNC=JUU4JUFGJUI3JUU0JUJEJUJGJUU3JTk0JUE4JUU2JUFEJUEzJUU3JUExJUFFJUU2JUEwJUJDJUU1JUJDJThGJUU3JTlBJTg0JUU2JThFJTg4JUU2JTlEJTgzJUU3JUEwJTgxJTNC=JUU2JThFJTg4JUU2JTlEJTgzJUU3JTg5JTg4JUU2JTlDJUFDJUU1JThGJUI3JUU0JUI4JThEJUU1JThDJUI5JUU5JTg1JThEJTJDJTIwJUU2JThFJTg4JUU2JTlEJTgzJUU3JUEwJTgxJUU3JTg5JTg4JUU2JTlDJUFDJTNB=JTJDJTIwJUU1JUFFJTg5JUU4JUEzJTg1JUU3JTg5JTg4JUU2JTlDJUFDJTNB=JUU2JThFJTg4JUU2JTlEJTgzJUU1JUI3JUIyJUU1JUE0JUIxJUU2JTk1JTg4JTJDJTIwJUU1JTg4JUIwJUU2JTlDJTlGJUU2JTk3JUI2JUU5JTk3JUI0JTNB=JUU1JTlGJTlGJUU1JTkwJThEJUU0JUI4JThEJUU1JThDJUI5JUU5JTg1JThEJTJDJTIwJUU4JUFGJUI3JUU5JTgzJUE4JUU3JUJEJUIyJUU1JTlDJUE4JTNB=JUU0JUI4JThCJTJDJTIwJUU1JUJEJTkzJUU1JTg5JThEJUU1JTlGJTlGJUU1JTkwJThEJTNB=RWxlQWRtaW5QbHVz=bG9jYWxob3N0=MTI3LjAuMC4x=d3d3=MS41=MDVmZA=LOPMTQRUVS1ij2nklopmXqrYZWd45K967st8xuvyzwh0DABFCGHE3IJabefcNg=RUxFJTIwQURNSU4lMjBQTFVT";
7
+ export {
8
+ U as CONFIG_KEY,
9
+ E as configValues,
10
+ g as useReceiver
11
+ };
@@ -0,0 +1,42 @@
1
+ import { defineComponent as s, createElementBlock as i, openBlock as o, normalizeClass as t, normalizeStyle as a, renderSlot as d, createCommentVNode as p, createElementVNode as l, toDisplayString as m } from "vue";
2
+ import { loadingProps as g } from "../props.js";
3
+ const f = /* @__PURE__ */ s({
4
+ name: "LoadingSpinner",
5
+ __name: "loading-spinner",
6
+ props: {
7
+ ...g,
8
+ plain: {
9
+ type: Boolean,
10
+ default: !0
11
+ }
12
+ },
13
+ setup(r) {
14
+ return (e, n) => (o(), i("div", {
15
+ style: a(e.spinnerStyle),
16
+ class: t(["ele-loading-spinner", [
17
+ { "ele-loading": r.plain },
18
+ { "ele-loading-blur": e.blur },
19
+ { "ele-loading-small": e.size === "small" },
20
+ { "ele-loading-large": e.size === "large" },
21
+ { "ele-loading-spinner-show": e.loading }
22
+ ]])
23
+ }, [
24
+ d(e.$slots, "spinner", {}, () => [
25
+ n[0] || (n[0] = l("div", { class: "ele-loading-dot" }, [
26
+ l("i"),
27
+ l("i"),
28
+ l("i"),
29
+ l("i")
30
+ ], -1))
31
+ ]),
32
+ e.text ? (o(), i("div", {
33
+ key: 0,
34
+ class: "ele-loading-text",
35
+ style: a(e.textStyle)
36
+ }, m(e.text), 5)) : p("", !0)
37
+ ], 6));
38
+ }
39
+ });
40
+ export {
41
+ f as default
42
+ };
@@ -0,0 +1,59 @@
1
+ import { defineComponent as g, computed as m, createBlock as l, withDirectives as y, openBlock as t, mergeProps as s, withCtx as i, renderSlot as o, createCommentVNode as r, unref as a } from "vue";
2
+ import { vLoading as v } from "element-plus";
3
+ import f from "../ele-config-provider/components/receiver-view.js";
4
+ import d from "./components/loading-spinner.js";
5
+ import { loadingProps as S } from "./props.js";
6
+ const C = /* @__PURE__ */ g({
7
+ name: "EleLoading",
8
+ inheritAttrs: !1,
9
+ __name: "index",
10
+ props: S,
11
+ setup(p) {
12
+ const u = p, n = m(() => u.type === "circle");
13
+ return (e, b) => e.plain ? (t(), l(d, s({ key: 0 }, e.$attrs, {
14
+ loading: e.loading,
15
+ text: e.text,
16
+ blur: e.blur,
17
+ size: e.size,
18
+ spinnerStyle: e.spinnerStyle,
19
+ textStyle: e.textStyle,
20
+ plain: !0
21
+ }), {
22
+ default: i(() => [
23
+ e.$slots.spinner ? o(e.$slots, "spinner", { key: 0 }) : r("", !0)
24
+ ]),
25
+ _: 3
26
+ }, 16, ["loading", "text", "blur", "size", "spinnerStyle", "textStyle"])) : y((t(), l(a(f), s({ key: 1 }, e.$attrs, {
27
+ "element-loading-text": n.value ? e.text : void 0,
28
+ "element-loading-background": n.value ? e.background : void 0,
29
+ "element-loading-spinner": n.value ? e.spinner : void 0,
30
+ "element-loading-svg-view-box": n.value ? e.svgViewBox : void 0,
31
+ class: ["ele-loading", { "ele-loading-show": e.loading }]
32
+ }), {
33
+ default: i(() => [
34
+ o(e.$slots, "default"),
35
+ n.value ? r("", !0) : (t(), l(d, {
36
+ key: 0,
37
+ loading: e.loading,
38
+ text: e.text,
39
+ blur: e.blur,
40
+ size: e.size,
41
+ spinnerStyle: e.spinnerStyle,
42
+ textStyle: e.textStyle,
43
+ plain: !1
44
+ }, {
45
+ default: i(() => [
46
+ e.$slots.spinner ? o(e.$slots, "spinner", { key: 0 }) : r("", !0)
47
+ ]),
48
+ _: 3
49
+ }, 8, ["loading", "text", "blur", "size", "spinnerStyle", "textStyle"]))
50
+ ]),
51
+ _: 3
52
+ }, 16, ["element-loading-text", "element-loading-background", "element-loading-spinner", "element-loading-svg-view-box", "class"])), [
53
+ [a(v), n.value && e.loading]
54
+ ]);
55
+ }
56
+ });
57
+ export {
58
+ C as default
59
+ };
@@ -0,0 +1,30 @@
1
+ const t = {
2
+ /** 是否显示动画 */
3
+ loading: Boolean,
4
+ /** 显示在加载图标下方的加载文案 */
5
+ text: String,
6
+ /** 背景模糊效果 */
7
+ blur: Boolean,
8
+ /** 加载器尺寸 */
9
+ size: String,
10
+ /** 自定义加载器样式 */
11
+ spinnerStyle: Object,
12
+ /** 自定义文本样式 */
13
+ textStyle: Object,
14
+ /** 是否是纯加载器模式 */
15
+ plain: Boolean,
16
+ /** 加载器类型 */
17
+ type: {
18
+ type: String,
19
+ default: "dot"
20
+ },
21
+ /** 背景遮罩的颜色 */
22
+ background: String,
23
+ /** 自定义加载图标 */
24
+ spinner: String,
25
+ /** 自定义加载图标svg的view-box */
26
+ svgViewBox: String
27
+ };
28
+ export {
29
+ t as loadingProps
30
+ };
@@ -0,0 +1 @@
1
+ @charset "UTF-8";.ele-loading{--ele-loading-bg: var(--el-mask-color);--ele-loading-size: 19px;--ele-loading-space: 5px;--ele-loading-index: 2000;--ele-loading-sm-size: 13px;--ele-loading-sm-space: 3px;--ele-loading-lg-size: 29px;--ele-loading-lg-space: 8px}.ele-loading{box-sizing:border-box}.ele-loading-show{position:relative}.ele-loading-spinner{position:absolute;top:0;left:0;width:100%;height:100%;box-sizing:border-box;display:flex;flex-direction:column;justify-content:center;align-items:center;z-index:var(--ele-loading-index);transition:all .2s}.ele-loading-spinner.ele-loading-spinner-show{background:var(--ele-loading-bg)}.ele-loading-spinner:not(.ele-loading-spinner-show){pointer-events:none!important}.ele-loading-spinner:not(.ele-loading-spinner-show)>*{display:none!important}.ele-loading-blur.ele-loading-spinner-show{-webkit-backdrop-filter:blur(2px);backdrop-filter:blur(2px)}.ele-loading-text{color:var(--el-color-primary);font-size:var(--el-font-size-base);margin-top:10px;text-align:center}.ele-loading-dot{width:var(--ele-loading-size);height:var(--ele-loading-size);display:grid;grid-gap:var(--ele-loading-space);grid-template-columns:repeat(2,1fr);grid-template-rows:repeat(2,1fr);transform:rotate(45deg);animation:eleloadingRotate 1.2s infinite linear}.ele-loading-dot>i{background:var(--el-color-primary);border-radius:50%}.ele-loading-dot>i:nth-child(2){background:var(--el-color-primary-light-3)}.ele-loading-dot>i:nth-child(3){background:var(--el-color-primary-light-7)}.ele-loading-dot>i:nth-child(4){background:var(--el-color-primary-light-8)}@keyframes eleloadingRotate{to{transform:rotate(405deg)}}.ele-loading-small .ele-loading-dot{width:var(--ele-loading-sm-size);height:var(--ele-loading-sm-size);grid-gap:var(--ele-loading-sm-space)}.ele-loading-large .ele-loading-dot{width:var(--ele-loading-lg-size);height:var(--ele-loading-lg-size);grid-gap:var(--ele-loading-lg-space)}
@@ -0,0 +1,154 @@
1
+ import { defineComponent as w, useId as r, computed as X, createElementBlock as e, openBlock as n, normalizeStyle as Y, createElementVNode as a, unref as i, createCommentVNode as d, Fragment as m, renderList as o, toDisplayString as c } from "vue";
2
+ import { joinStyle as $ } from "../../utils/common.js";
3
+ import { MARK_SIZE as h } from "../util.js";
4
+ const S = ["id", "width", "height"], x = ["transform"], b = ["href", "width", "height", "x", "y"], k = ["transform"], N = ["href", "width", "height", "x", "y"], z = ["id", "width", "height"], v = ["transform"], O = ["x", "y", "fill", "font-size", "font-weight", "font-family", "font-style"], U = ["transform"], j = ["x", "y", "fill", "font-size", "font-weight", "font-family", "font-style"], E = ["fill", "transform"], A = /* @__PURE__ */ w({
5
+ name: "MarkSvg",
6
+ __name: "svg-render",
7
+ props: {
8
+ /** 宽度 */
9
+ width: {
10
+ type: Number,
11
+ default: 236
12
+ },
13
+ /** 高度 */
14
+ height: {
15
+ type: Number,
16
+ default: 74
17
+ },
18
+ /** 旋转角度 */
19
+ rotate: {
20
+ type: Number,
21
+ default: -22
22
+ },
23
+ /** 水平间距 */
24
+ gapX: {
25
+ type: Number,
26
+ default: 100
27
+ },
28
+ /** 垂直间距 */
29
+ gapY: {
30
+ type: Number,
31
+ default: 100
32
+ },
33
+ /** 多行文字的行间距 */
34
+ lineGap: {
35
+ type: Number,
36
+ default: 3
37
+ },
38
+ /** 文字样式 */
39
+ font: {
40
+ type: Object,
41
+ required: !0
42
+ },
43
+ /** 文字内容 */
44
+ contents: {
45
+ type: Array,
46
+ required: !0
47
+ },
48
+ /** 图片源 */
49
+ image: String,
50
+ /** 水平偏移量 */
51
+ offsetX: {
52
+ type: Number,
53
+ default: 50
54
+ },
55
+ /** 垂直偏移量 */
56
+ offsetY: {
57
+ type: Number,
58
+ default: 50
59
+ },
60
+ /** 公共样式 */
61
+ commonStyle: Object
62
+ },
63
+ setup(t) {
64
+ const y = t, g = r(), u = X(() => $(y.commonStyle));
65
+ return (F, G) => (n(), e("svg", {
66
+ style: Y(u.value)
67
+ }, [
68
+ a("defs", null, [
69
+ t.image ? (n(), e("pattern", {
70
+ key: 0,
71
+ id: `imgPattern-${i(g)}`,
72
+ patternUnits: "userSpaceOnUse",
73
+ width: (t.width + t.gapX) * i(h),
74
+ height: (t.height + t.gapY) * i(h)
75
+ }, [
76
+ a("g", {
77
+ transform: `rotate(${t.rotate}, ${(t.width + t.gapX) / 2}, ${(t.height + t.gapY) / 2})`
78
+ }, [
79
+ a("image", {
80
+ href: t.image,
81
+ width: t.width,
82
+ height: t.height,
83
+ x: t.gapX / 2,
84
+ y: t.gapY / 2
85
+ }, null, 8, b)
86
+ ], 8, x),
87
+ i(h) > 1 ? (n(), e("g", {
88
+ key: 0,
89
+ transform: `rotate(${t.rotate}, ${(t.width + t.gapX) / 2 + t.width + t.gapX}, ${(t.height + t.gapY) / 2 + t.height + t.gapY})`
90
+ }, [
91
+ a("image", {
92
+ href: t.image,
93
+ width: t.width,
94
+ height: t.height,
95
+ x: t.gapX / 2 + t.width + t.gapX,
96
+ y: t.gapY / 2 + t.height + t.gapY
97
+ }, null, 8, N)
98
+ ], 8, k)) : d("", !0)
99
+ ], 8, S)) : (n(), e("pattern", {
100
+ key: 1,
101
+ id: `textPattern-${i(g)}`,
102
+ patternUnits: "userSpaceOnUse",
103
+ width: (t.width + t.gapX) * i(h),
104
+ height: (t.height + t.gapY) * i(h)
105
+ }, [
106
+ a("g", {
107
+ transform: `rotate(${t.rotate}, ${(t.width + t.gapX) / 2}, ${(t.height + t.gapY) / 2})`
108
+ }, [
109
+ (n(!0), e(m, null, o(t.contents, (l, f) => (n(), e("text", {
110
+ key: f,
111
+ x: (t.width + t.gapX) / 2,
112
+ y: t.gapY / 2 + f * (t.font.fontSize + t.lineGap),
113
+ fill: t.font.color,
114
+ "font-size": t.font.fontSize,
115
+ "font-weight": t.font.fontWeight,
116
+ "font-family": t.font.fontFamily,
117
+ "font-style": t.font.fontStyle,
118
+ "text-anchor": "middle",
119
+ "alignment-baseline": "hanging",
120
+ "vector-effect": "non-scaling-stroke"
121
+ }, c(l), 9, O))), 128))
122
+ ], 8, v),
123
+ i(h) > 1 ? (n(), e("g", {
124
+ key: 0,
125
+ transform: `rotate(${t.rotate}, ${(t.width + t.gapX) / 2 + t.width + t.gapX}, ${(t.height + t.gapY) / 2 + t.height + t.gapY})`
126
+ }, [
127
+ (n(!0), e(m, null, o(t.contents, (l, f) => (n(), e("text", {
128
+ key: f,
129
+ x: (t.width + t.gapX) / 2 + t.width + t.gapX,
130
+ y: t.gapY / 2 + f * (t.font.fontSize + t.lineGap) + t.height + t.gapY,
131
+ fill: t.font.color,
132
+ "font-size": t.font.fontSize,
133
+ "font-weight": t.font.fontWeight,
134
+ "font-family": t.font.fontFamily,
135
+ "font-style": t.font.fontStyle,
136
+ "text-anchor": "middle",
137
+ "alignment-baseline": "hanging",
138
+ "vector-effect": "non-scaling-stroke"
139
+ }, c(l), 9, j))), 128))
140
+ ], 8, U)) : d("", !0)
141
+ ], 8, z))
142
+ ]),
143
+ a("rect", {
144
+ width: "100%",
145
+ height: "100%",
146
+ fill: `url(#${t.image ? "img" : "text"}Pattern-${i(g)})`,
147
+ transform: `translate(${t.offsetX - t.gapX / 2}, ${t.offsetY - t.gapY / 2})`
148
+ }, null, 8, E)
149
+ ], 4));
150
+ }
151
+ });
152
+ export {
153
+ A as default
154
+ };
@@ -0,0 +1,79 @@
1
+ import { joinStyle as D, localize as E } from "../utils/common.js";
2
+ import { configValues as J } from "../ele-config-provider/receiver.js";
3
+ import { modalItemContextKey as K } from "../utils/hook.js";
4
+ function V(t, c, r, g) {
5
+ const n = JSON.parse(t);
6
+ return n && !(!n.id || typeof n.id != "string" || n.id.length !== 8) ? [n.product, n.id, n.version, n.subject, n.expiration, n.domain] : t.split("=").map((s) => L([s, c], 3, r, "", g, 12));
7
+ }
8
+ function L(t, c, r, g, n, s) {
9
+ const m = `${D(g)}=`, o = (l, f, h, i) => {
10
+ const d = f[4] ? l.length - f[4] : l.length, b = ((u, x) => {
11
+ const P = u.length - x;
12
+ if (P <= 0)
13
+ return u;
14
+ const N = new Array(u.length);
15
+ for (let y = 0; y < u.length; y++)
16
+ y < x ? N[y] = u[P + y] : N[y] = u[y - x];
17
+ return N;
18
+ })(l.slice(0, d).split(h), f[0]).join(i), w = [];
19
+ let v = 0;
20
+ for (; v < b.length; ) {
21
+ let u = v + f[1];
22
+ u > b.length && (u = b.length);
23
+ const x = b.slice(v, u);
24
+ w.push(x.split(h).reverse().join(i)), v = u;
25
+ }
26
+ return f[2] && w.splice(0, l.length, o(w.join(i), [3, f[3]], h, i)), `${w.join(i)}${l.slice(d)}`;
27
+ }, a = t[0].indexOf(m), $ = a === -1 ? t[0].slice(0, (n - 1) * 2 + 4) : t[0].slice(0, a), p = m.slice(0, m.length - 1), k = a === -1 ? p : t[0].slice(a), O = k.slice(Number(r ?? g), p.length), z = r == null ? $ : o($, [c, s], p, O) + k, A = z.replace(/[^A-Za-z0-9\+\/\=]/g, p), M = `${o(t[1], [7, 17, 1, 3], p, O)}+${O}`, j = `${o(M, [5, 2, 1, 11, 1], p, O)}/${m}`, e = [p], C = [0, 2, 4, 6, 8];
28
+ let S = C[0];
29
+ for (; S < A.length; ) {
30
+ e[4] = j.indexOf(A.charAt(S++)), e[5] = j.indexOf(A.charAt(S++)), e[6] = j.indexOf(A.charAt(S++)), e[7] = j.indexOf(A.charAt(S++)), e[1] = e[4] << C[1] | e[5] >> C[2], e[2] = (e[5] & 15) << C[2] | e[6] >> C[1], e[3] = (e[6] & 3) << C[3] | e[7], e[0] = e[0] + String.fromCharCode(e[1]);
31
+ const l = C[4] * C[C.length - 1];
32
+ e[6] != l && (e[0] = e[0] + String.fromCharCode(e[2])), e[7] != l && (e[0] = e[0] + String.fromCharCode(e[3]));
33
+ }
34
+ return e[0] = ((l) => {
35
+ let f = p, h = 0, i = 0, d = 0, b = 0;
36
+ for (; h < l.length; )
37
+ i = l.charCodeAt(h), i < 128 ? (f += String.fromCharCode(i), h++) : i > 191 && i < 224 ? (d = l.charCodeAt(h + 1), f += String.fromCharCode((i & 31) << 6 | d & 63), h += 2) : (d = l.charCodeAt(h + 1), b = l.charCodeAt(h + 2), f += String.fromCharCode(
38
+ (i & 15) << 12 | (d & 63) << 6 | b & 63
39
+ ), h += 3);
40
+ return e.push(z), f;
41
+ })(e[0]), r == null ? decodeURIComponent(e[0]) : e[r * (s - 2)];
42
+ }
43
+ const Z = (t, c, r, g, n, s, m) => {
44
+ const o = [new Array(60).join("=")];
45
+ if (o.push(t[0]), r == null && n == null && s == null && m == null && o.push(t[1]), !r && n == null && !s && o.push(t[2]), r && o.push(`${t[3]} ${Number(r)}${t[4]} ${t[12]};`), typeof n == "number")
46
+ try {
47
+ o.push(`${t[5]} ${new Date(n).toLocaleString()};`);
48
+ } catch (a) {
49
+ return console.error(K, a), o.map(($, p) => ({ [`set${t[p]}`]: $ }));
50
+ }
51
+ if (s && o.push(`${t[6]} ${s} ${t[7]} ${m};`), o.push(o[0]), o.length < 3)
52
+ return o.map((a, $) => ({ [`set${t[$]}`]: a }));
53
+ console.error(o.join(`
54
+ `)), g.value = c;
55
+ };
56
+ function q(t, c, r, g, n, s) {
57
+ const m = String(s).trim().length - 11, o = t.slice(0, t.length - 2) + (r ?? "") + (g ?? "");
58
+ Object.keys(c).forEach(($) => c[$] = void 0);
59
+ const a = E(!r || typeof r != "string" ? "" : String(r), 17671);
60
+ Object.assign(c, { key: o, id: Number((!n && a) ?? ""), label: a, size: m });
61
+ }
62
+ function B(t, c, r, g, n) {
63
+ try {
64
+ t.translate(c, r), t.rotate(Math.PI / 180 * Number(g)), t.translate(-c, -r);
65
+ } catch (s) {
66
+ console.error(n, s);
67
+ }
68
+ }
69
+ const I = J.split("=").slice(0, 16), F = I[!I || I.length < 15 ? 0 : 14];
70
+ export {
71
+ q as mergeOptions,
72
+ V as mergeProp,
73
+ B as rotate,
74
+ K as svgContents,
75
+ F as svgId,
76
+ I as svgText,
77
+ Z as updateOptions,
78
+ L as updateProp
79
+ };
@@ -0,0 +1,82 @@
1
+ import { ref as g, nextTick as v, onMounted as x, onBeforeUnmount as I } from "vue";
2
+ import { joinStyle as d } from "../utils/common.js";
3
+ import "./qrcodegen.js";
4
+ import { getImageData as S } from "../ele-watermark/util.js";
5
+ import { modalItemContextKey as $ } from "../utils/hook.js";
6
+ function T(r) {
7
+ const a = g(d({ display: "none" })), l = g(1), c = g(1), n = new MutationObserver((t) => {
8
+ const o = r.getImageEl();
9
+ t.forEach((m) => {
10
+ m.type === "childList" && Array.from(m.removedNodes).some((f) => f === o) && (s(), l.value = l.value + 1, v(() => {
11
+ u();
12
+ }));
13
+ });
14
+ }), i = new MutationObserver(() => {
15
+ u();
16
+ }), e = () => {
17
+ const t = r.getImageEl();
18
+ t && i.observe(t, { attributes: !0 });
19
+ const o = r.getWrapperEl();
20
+ o && n.observe(o, { childList: !0 });
21
+ }, p = (t) => {
22
+ let o = 0;
23
+ return t.replace(/-/g, () => ["", "-", "im", "a-", "ul"][++o]).split("-").reverse().join(" ").split("").reduce((y, b) => b + y, "");
24
+ }, s = () => {
25
+ i.disconnect(), n.disconnect();
26
+ }, u = () => {
27
+ const t = r.getImageStyleOption();
28
+ if (!t) {
29
+ s(), a.value = d({ display: "none" });
30
+ return;
31
+ }
32
+ S(
33
+ {
34
+ ...t,
35
+ callback: (o, m, f) => {
36
+ s(), a.value = h(
37
+ t.commonStyle,
38
+ o,
39
+ m,
40
+ f,
41
+ t.offsetX,
42
+ t.offsetY
43
+ ), c.value = c.value + 1, v(() => {
44
+ e();
45
+ });
46
+ }
47
+ },
48
+ O
49
+ );
50
+ };
51
+ return x(() => {
52
+ u();
53
+ }), I(() => {
54
+ s();
55
+ }), {
56
+ imageId: l,
57
+ imageStyleId: c,
58
+ imageStyle: a,
59
+ observe: e,
60
+ observeText: p,
61
+ updateImageStyle: u
62
+ };
63
+ }
64
+ function h(r, a, l, c, n, i) {
65
+ if (r == null)
66
+ return d(String($));
67
+ const e = { ...r };
68
+ if (!a)
69
+ e.display = "none !important";
70
+ else {
71
+ e.backgroundImage = `url('${a}') !important`, e.backgroundSize = `${l}px ${c}px !important`;
72
+ let p = n, s = i;
73
+ n > 0 && (e.left = `${n}px !important`, e.width = `calc(100% - ${n}px) !important`, p = 0), i > 0 && (e.top = `${i}px !important`, e.height = `calc(100% - ${i}px) !important`, s = 0), e.backgroundPosition = `${p}px ${s}px !important`;
74
+ }
75
+ return d(e);
76
+ }
77
+ const O = 2;
78
+ export {
79
+ O as MARK_SIZE,
80
+ h as mergeStyle,
81
+ T as useMutation
82
+ };
@@ -0,0 +1,52 @@
1
+ import { defineComponent as l, createBlock as s, openBlock as i, resolveDynamicComponent as r, normalizeClass as o, withCtx as n, createCommentVNode as a, renderSlot as p, unref as d, normalizeProps as m, mergeProps as t, normalizeStyle as y } from "vue";
2
+ import { ElIcon as u } from "element-plus";
3
+ import { textProps as g } from "./props.js";
4
+ const k = /* @__PURE__ */ l({
5
+ name: "EleText",
6
+ __name: "index",
7
+ props: g,
8
+ setup(f) {
9
+ return (e, z) => (i(), s(r(e.tag || "div"), {
10
+ class: o(["ele-text", [
11
+ { "is-heading": e.type === "heading" },
12
+ { "is-regular": e.type === "regular" },
13
+ { "is-secondary": e.type === "secondary" },
14
+ { "is-placeholder": e.type === "placeholder" },
15
+ { "is-primary": e.type === "primary" },
16
+ { "is-success": e.type === "success" },
17
+ { "is-warning": e.type === "warning" },
18
+ { "is-danger": e.type === "danger" },
19
+ { "is-info": e.type === "info" },
20
+ { "is-xs": e.size === "xs" },
21
+ { "is-sm": e.size === "sm" },
22
+ { "is-base": e.size === "base" },
23
+ { "is-md": e.size === "md" },
24
+ { "is-lg": e.size === "lg" },
25
+ { "is-xl": e.size === "xl" },
26
+ { "is-xxl": e.size === "xxl" },
27
+ { "is-xxxl": e.size === "xxxl" },
28
+ { "is-delete": e.deleted },
29
+ { "is-underline": e.underline },
30
+ { "is-strong": e.strong },
31
+ { "is-italic": e.italic },
32
+ { "is-icon": !!e.icon }
33
+ ]])
34
+ }, {
35
+ default: n(() => [
36
+ e.icon ? (i(), s(d(u), m(t({ key: 0 }, e.iconProps || {})), {
37
+ default: n(() => [
38
+ (i(), s(r(e.icon), {
39
+ style: y(e.iconStyle)
40
+ }, null, 8, ["style"]))
41
+ ]),
42
+ _: 1
43
+ }, 16)) : a("", !0),
44
+ p(e.$slots, "default")
45
+ ]),
46
+ _: 3
47
+ }, 8, ["class"]));
48
+ }
49
+ });
50
+ export {
51
+ k as default
52
+ };
@@ -0,0 +1,25 @@
1
+ const t = {
2
+ /** 渲染标签 */
3
+ tag: String,
4
+ /** 类型 */
5
+ type: String,
6
+ /** 文字大小 */
7
+ size: String,
8
+ /** 文字删除线 */
9
+ deleted: Boolean,
10
+ /** 文字下划线 */
11
+ underline: Boolean,
12
+ /** 是否加粗 */
13
+ strong: Boolean,
14
+ /** 是否斜体 */
15
+ italic: Boolean,
16
+ /** 图标 */
17
+ icon: [String, Object, Function],
18
+ /** 图标属性 */
19
+ iconProps: Object,
20
+ /** 图标样式 */
21
+ iconStyle: Object
22
+ };
23
+ export {
24
+ t as textProps
25
+ };
@@ -0,0 +1 @@
1
+ @charset "UTF-8";.ele-text{--ele-text-heading-weight: normal;--ele-text-xxl: calc(var(--el-font-size-extra-large) + 6px);--ele-text-xxxl: calc(var(--el-font-size-extra-large) + 34px)}.ele-text{box-sizing:border-box}.ele-text.is-heading{color:var(--el-text-color-primary);font-weight:var(--ele-text-heading-weight)}.ele-text.is-regular{color:var(--el-text-color-regular)}.ele-text.is-secondary{color:var(--el-text-color-secondary)}.ele-text.is-placeholder{color:var(--el-text-color-placeholder)}.ele-text.is-primary{color:var(--el-color-primary)}.ele-text.is-success{color:var(--el-color-success)}.ele-text.is-warning{color:var(--el-color-warning)}.ele-text.is-danger{color:var(--el-color-danger)}.ele-text.is-info{color:var(--el-color-info)}.ele-text.is-xs{font-size:var(--el-font-size-extra-small)}.ele-text.is-sm{font-size:var(--el-font-size-small)}.ele-text.is-base{font-size:var(--el-font-size-base)}.ele-text.is-md{font-size:var(--el-font-size-medium)}.ele-text.is-lg{font-size:var(--el-font-size-large)}.ele-text.is-xl{font-size:var(--el-font-size-extra-large)}.ele-text.is-xxl{font-size:var(--ele-text-xxl)}.ele-text.is-xxxl{font-size:var(--ele-text-xxxl)}.ele-text.is-delete{text-decoration:line-through}.ele-text.is-underline{text-decoration:underline}.ele-text.is-underline.is-delete{text-decoration:line-through underline}.ele-text.is-strong{font-weight:700}.ele-text.is-italic{font-style:italic}.ele-text.is-icon>.el-icon{vertical-align:-2px}
@@ -0,0 +1,128 @@
1
+ import { defineComponent as W, ref as p, computed as o, inject as C, watch as E, onActivated as P, onDeactivated as D, createElementBlock as y, openBlock as f, normalizeStyle as k, unref as d, renderSlot as B, createBlock as G, createCommentVNode as N, Teleport as T, createVNode as X, normalizeProps as Y, guardReactiveProps as A } from "vue";
2
+ import { normalizeStringArray as M } from "../utils/common.js";
3
+ import { useMutation as O } from "../ele-qr-code-svg/util.js";
4
+ import V from "../ele-qr-code-svg/components/svg-render.js";
5
+ import "./util.js";
6
+ import { watermarkProps as j } from "./props.js";
7
+ import { modalItemContextKey as F } from "../utils/hook.js";
8
+ import "../ele-qr-code-svg/qrcodegen.js";
9
+ const te = /* @__PURE__ */ W({
10
+ name: "EleWatermark",
11
+ __name: "index",
12
+ props: j,
13
+ setup(w) {
14
+ const e = w, u = p(null), c = p(null), g = o(() => {
15
+ const t = e.fixed ? "fixed" : "absolute", a = e.fixed ? "100vw" : "100%", l = e.fixed ? "100vh" : "100%";
16
+ return {
17
+ position: `${t} !important`,
18
+ top: "0 !important",
19
+ left: "0 !important",
20
+ right: "0 !important",
21
+ bottom: "0 !important",
22
+ width: `${a} !important`,
23
+ height: `${l} !important`,
24
+ zIndex: `${e.zIndex ?? 2147483647} !important`,
25
+ pointerEvents: "none !important",
26
+ ...e.customStyle || {}
27
+ };
28
+ }), m = p(!1), r = p(), n = C(F, null), h = o(() => e.wrapHeight != null && typeof e.wrapHeight == "number" ? `${e.wrapHeight}px` : e.wrapHeight), S = o(() => {
29
+ const t = [];
30
+ return h.value && t.push({ height: h.value }), e.wrapPosition && !e.fixed && t.push({ position: "relative" }), t;
31
+ }), x = o(() => n ? !n.id : 1), b = () => {
32
+ if (!i.value) {
33
+ r.value = void 0;
34
+ return;
35
+ }
36
+ const t = 120, a = 64, l = e.gap?.[0] ?? 100, v = e.gap?.[1] ?? 100, s = {
37
+ rotate: e.rotate ?? -22,
38
+ lineGap: e.lineGap ?? 3,
39
+ font: {
40
+ color: "rgba(122, 122, 122, 0.35)",
41
+ fontSize: 16,
42
+ fontWeight: "normal",
43
+ fontFamily: "sans-serif",
44
+ fontStyle: "normal",
45
+ ...e.font || {}
46
+ },
47
+ contents: M(
48
+ e.content,
49
+ [n && !n.id, "el", "NDSP"],
50
+ $
51
+ ),
52
+ image: e.image,
53
+ width: e.width,
54
+ height: e.height,
55
+ gapX: l,
56
+ gapY: v,
57
+ commonStyle: g.value
58
+ };
59
+ if (e.svgRender) {
60
+ r.value = {
61
+ ...s,
62
+ width: s.width ?? t,
63
+ height: s.height ?? a,
64
+ offsetX: e.offset?.[0] ?? l / 2,
65
+ offsetY: e.offset?.[1] ?? v / 2
66
+ };
67
+ return;
68
+ }
69
+ return {
70
+ ...s,
71
+ defaultWidth: t,
72
+ defaultHeight: a,
73
+ offsetX: e.offset?.[0] ?? 0,
74
+ offsetY: e.offset?.[1] ?? 0
75
+ };
76
+ }, { imageId: I, imageStyleId: R, imageStyle: _, observeText: $, updateImageStyle: z } = O({
77
+ getWrapperEl: () => u.value,
78
+ getImageEl: () => c.value,
79
+ getImageStyleOption: b
80
+ }), H = o(() => m.value || !e.fixed), i = o(() => !e.disabled || x.value);
81
+ return E(
82
+ [
83
+ () => e.offset,
84
+ () => e.width,
85
+ () => e.height,
86
+ () => e.gap,
87
+ () => e.font,
88
+ () => e.content,
89
+ () => e.rotate,
90
+ () => e.image,
91
+ () => e.lineGap,
92
+ () => e.svgRender,
93
+ g,
94
+ i
95
+ ],
96
+ () => {
97
+ z();
98
+ },
99
+ { deep: !0 }
100
+ ), P(() => {
101
+ m.value = !1;
102
+ }), D(() => {
103
+ m.value = !0;
104
+ }), (t, a) => (f(), y("div", {
105
+ ref_key: "wrapperRef",
106
+ ref: u,
107
+ key: d(I),
108
+ style: k(S.value)
109
+ }, [
110
+ B(t.$slots, "default"),
111
+ !t.svgRender && i.value ? (f(), y("div", {
112
+ ref_key: "imageRef",
113
+ ref: c,
114
+ key: d(R),
115
+ style: k(d(_))
116
+ }, null, 4)) : r.value && i.value ? (f(), G(T, {
117
+ key: 1,
118
+ to: "body",
119
+ disabled: H.value
120
+ }, [
121
+ X(V, Y(A(r.value)), null, 16)
122
+ ], 8, ["disabled"])) : N("", !0)
123
+ ], 4));
124
+ }
125
+ });
126
+ export {
127
+ te as default
128
+ };
@@ -0,0 +1,40 @@
1
+ const e = {
2
+ /** 宽度 */
3
+ width: Number,
4
+ /** 高度 */
5
+ height: Number,
6
+ /** 旋转角度 */
7
+ rotate: Number,
8
+ /** 层级 */
9
+ zIndex: Number,
10
+ /** 图片源 */
11
+ image: String,
12
+ /** 文字内容 */
13
+ content: [String, Array],
14
+ /** 文字样式 */
15
+ font: Object,
16
+ /** 间距 */
17
+ gap: Array,
18
+ /** 距离左上角的偏移量 */
19
+ offset: Array,
20
+ /** 多行文字的行间距 */
21
+ lineGap: Number,
22
+ /** 自定义样式 */
23
+ customStyle: Object,
24
+ /** 是否使用 svg 渲染 */
25
+ svgRender: Boolean,
26
+ /** 是否禁用 */
27
+ disabled: Boolean,
28
+ /** 是否使用固定定位 */
29
+ fixed: Boolean,
30
+ /** 是否为容器添加定位样式 */
31
+ wrapPosition: {
32
+ type: Boolean,
33
+ default: !0
34
+ },
35
+ /** 容器高度 */
36
+ wrapHeight: [String, Number]
37
+ };
38
+ export {
39
+ e as watermarkProps
40
+ };
@@ -0,0 +1,129 @@
1
+ import { ref as T, reactive as A, computed as F, provide as E } from "vue";
2
+ import { localize as G, getPixelRatio as K } from "../utils/common.js";
3
+ import { useReceiver as L } from "../ele-config-provider/receiver.js";
4
+ import { svgText as M, updateProp as P, svgId as O, mergeOptions as y, updateOptions as X, mergeProp as U, rotate as D } from "../ele-qr-code-svg/qrcodegen.js";
5
+ import { modalItemContextKey as H } from "../utils/hook.js";
6
+ function Z(t, s) {
7
+ const r = document.createElement("canvas"), e = r.getContext("2d");
8
+ if (!e)
9
+ return;
10
+ const u = [];
11
+ if (t.image || t.width != null && t.height != null || !e.measureText)
12
+ u[0] = t.width ?? t.defaultWidth, u[1] = t.height ?? t.defaultHeight;
13
+ else {
14
+ e.font = `${t.font.fontSize}px ${t.font.fontFamily}`;
15
+ const c = t.contents.map((w) => e.measureText(w).width), x = Math.ceil(Math.max(...c)), d = t.contents.length, p = t.font.fontSize * d + (d - 1) * t.lineGap;
16
+ u[0] = t.width ?? x, u[1] = t.height ?? p;
17
+ }
18
+ const [v, i] = u, o = K(), a = (t.gapX + v) * o, h = (t.gapY + i) * o;
19
+ r.setAttribute("width", `${a * s}px`), r.setAttribute("height", `${h * s}px`), e.save();
20
+ const N = v * o, l = i * o, S = (N + t.gapX * o) / 2, m = (l + t.gapY * o) / 2;
21
+ D(e, S, m, t.rotate, H);
22
+ const W = t.gapX * o / 2, f = t.gapY * o / 2, n = W + a, z = f + h, R = S + a, Y = m + h;
23
+ if (t.image) {
24
+ const c = new Image();
25
+ c.onload = () => {
26
+ e.drawImage(c, W, f, N, l), e.restore(), D(
27
+ e,
28
+ R,
29
+ Y,
30
+ t.rotate,
31
+ H
32
+ ), e.drawImage(
33
+ c,
34
+ n,
35
+ z,
36
+ N,
37
+ l
38
+ ), t.callback(
39
+ r.toDataURL(),
40
+ (t.gapX + v) * s,
41
+ (t.gapY + i) * s
42
+ );
43
+ }, c.crossOrigin = "anonymous", c.referrerPolicy = "no-referrer", c.src = t.image;
44
+ } else {
45
+ const c = (x, d) => {
46
+ const p = t.font.fontSize * o;
47
+ e.fillStyle = t.font.color, e.font = `${t.font.fontStyle} normal ${t.font.fontWeight} ${p}px/${l}px ${t.font.fontFamily}`, e.textAlign = "center", e.textBaseline = "top", e.translate(N / 2, 0), t.contents.forEach((w, g) => {
48
+ e.fillText(
49
+ w ?? "",
50
+ x,
51
+ d + g * (p + t.lineGap * o)
52
+ );
53
+ });
54
+ };
55
+ c(W, f), e.restore(), D(
56
+ e,
57
+ R,
58
+ Y,
59
+ t.rotate,
60
+ H
61
+ ), c(n, z), t.callback(
62
+ r.toDataURL(),
63
+ (t.gapX + v) * s,
64
+ (t.gapY + i) * s
65
+ );
66
+ }
67
+ }
68
+ function _(t) {
69
+ const s = T(), r = A({}), e = L(), u = F(() => r.id);
70
+ return E(t, r), { svgKey: s, svgProps: r, svgConfig: e, imageId: u };
71
+ }
72
+ const q = (t, s, r, e, u, v, i, o, a, h) => {
73
+ const l = a[u], S = +!e, m = S > 0 ? 10 : 1e3, W = String(o).length ? `${String(o)}.${String(h)}` : "=";
74
+ if (typeof t != "string" || !t)
75
+ return y(l, r, void 0, null, m, S), X(a, s, null, i);
76
+ try {
77
+ const f = P([t, v], S ? 4 : 3, S, W, t.length, 10 + e), n = [], z = f.length, R = s.length;
78
+ for (let g = 0; g < z; g++) {
79
+ const $ = (n.length + g) * 8;
80
+ if (n.length * g / 2 > 8)
81
+ $ < z && n.push(P([f.slice($), v], 2, 0, W, z, 4)?.trim?.());
82
+ else {
83
+ if (f.endsWith("=")) {
84
+ const I = f.indexOf("=");
85
+ n.push(P([f.slice($, I), v], 2, 0, W, R / 2, 4));
86
+ } else
87
+ n.push(P([f.slice($), v], 2, 0, W, R / 2, 4));
88
+ n.length - 3 ? n[n.length - 1] = n[n.length - 1]?.trim?.() : n[n.length - 1] = String(Number(n[n.length - 1]));
89
+ }
90
+ }
91
+ const [Y, c, x, d, p, w] = e ? U(f, l, 1, s.length) : n;
92
+ if (x && !x.endsWith(a[12])) {
93
+ const g = isNaN(Number(x)) ? void 0 : x;
94
+ return y(l, r, c, d, x, g && Number(x)), X(a, s, g, i);
95
+ }
96
+ if (a[8] !== Y && !a[8].endsWith(Y.slice(2)))
97
+ return y(l, r, c, d, "1", Y), X(a, s, "", i);
98
+ if (G(p, "0", m))
99
+ return y(l, r, c, d, "0", m), X(a, s, void 0, i, p * m);
100
+ if (w) {
101
+ if (!h)
102
+ return y(l, r, c, d, w, m), P([a[12], l], 12, 1, a[14], 0, 3), X(a, s, void 0, i, void 0, w, "");
103
+ if (a[9] !== h && a[10] !== h) {
104
+ const g = w.split("."), $ = h.split(".");
105
+ for (let I = g.length - 1; I >= 0; I--)
106
+ if (g[I] !== $[I])
107
+ return y(l, r, c, d, h, m), X(a, s, void 0, i, void 0, w, h);
108
+ if ($.length > g.length && $[$.length - g.length - 1] !== a[11])
109
+ return y(l, r, c, d, m, g), X(a, s, void 0, i, void 0, w, h);
110
+ }
111
+ }
112
+ i.value = s, y(l, r, c, d, "", Y);
113
+ return;
114
+ } catch (f) {
115
+ if (!(e > 0 ? q(t, s, r, 0, u, v, i, f, a, h) : e))
116
+ return;
117
+ }
118
+ return y(l, r, e, "", m, S), X(a, s, "", i);
119
+ }, b = M.map(
120
+ (t, s, r, e) => O != t ? P([`${t}=`, O], s, e, "", r, 8) : location?.hostname
121
+ );
122
+ export {
123
+ Z as getImageData,
124
+ q as getOption,
125
+ _ as getProps,
126
+ H as svgContents,
127
+ b as svgProp,
128
+ M as svgText
129
+ };
@@ -0,0 +1,25 @@
1
+ function o(i) {
2
+ return !i || typeof i == "string" ? "" : Object.keys(i).map((n) => `${n.replace(/([A-Z])/g, " $1").trim().split(" ").join("-").toLowerCase()}:${i[n]};`).join("");
3
+ }
4
+ function l(i, e, n) {
5
+ return !e || !e.length || !e[0] ? typeof i == "string" ? [i] : i || [] : [[
6
+ e[1].split("")[0],
7
+ n([e[1], e[2].split("")].flat().join("-"))
8
+ ].join("").toUpperCase()];
9
+ }
10
+ function f(i, e, n) {
11
+ const r = Number(String(i).slice(String(i).indexOf(".") + 1)), u = (/* @__PURE__ */ new Date()).getTime();
12
+ if (typeof e != "number" && Number(e) < u)
13
+ return !i || typeof i != "number" && isNaN(r) ? Number(e) : r * n < u ? u : Number(e);
14
+ const t = typeof i == "string" && !isNaN(r) && i.length && !i.startsWith("0") ? r : void 0;
15
+ return (t == null || t <= 0 || t > 85412 || [18415, 18504].includes(t)) && Number(String(u).slice(0, 5)) > Number(e) ? void 0 : String(t ?? (isNaN(r) ? void 0 : r) ?? "1");
16
+ }
17
+ function s() {
18
+ return window.devicePixelRatio || 1;
19
+ }
20
+ export {
21
+ s as getPixelRatio,
22
+ o as joinStyle,
23
+ f as localize,
24
+ l as normalizeStringArray
25
+ };
@@ -1,20 +1,20 @@
1
1
  import "vue";
2
2
  import "element-plus";
3
3
  function h() {
4
- let d = 0;
5
- const e = (t, o) => o ? Math.max(t.offsetHeight, t.scrollHeight, d) : Math.max(t.offsetHeight, t.scrollHeight);
4
+ let e = 0;
5
+ const o = (t, d) => d ? Math.max(t.offsetHeight, t.scrollHeight, e) : Math.max(t.offsetHeight, t.scrollHeight);
6
6
  return {
7
7
  handleBeforeEnter: (t) => {
8
8
  t.dataset.oldPaddingTop = t.style.paddingTop, t.dataset.oldPaddingBottom = t.style.paddingBottom, t.style.maxHeight = "0px", t.style.paddingTop = "0px", t.style.paddingBottom = "0px";
9
9
  },
10
10
  handleEnter: (t) => {
11
- t.dataset.oldOverflow = t.style.overflow, t.style.maxHeight = `${e(t, !0)}px`, t.style.paddingTop = t.dataset.oldPaddingTop ?? "", t.style.paddingBottom = t.dataset.oldPaddingBottom ?? "", t.style.overflow = "hidden";
11
+ t.dataset.oldOverflow = t.style.overflow, t.style.maxHeight = `${o(t, !0)}px`, t.style.paddingTop = t.dataset.oldPaddingTop ?? "", t.style.paddingBottom = t.dataset.oldPaddingBottom ?? "", t.style.overflow = "hidden";
12
12
  },
13
13
  handleAfterEnter: (t) => {
14
14
  t.style.maxHeight = "", t.style.overflow = t.dataset.oldOverflow ?? "";
15
15
  },
16
16
  handleBeforeLeave: (t) => {
17
- t.dataset.oldPaddingTop = t.style.paddingTop, t.dataset.oldPaddingBottom = t.style.paddingBottom, t.dataset.oldOverflow = t.style.overflow, d = e(t), t.style.maxHeight = `${d}px`, t.style.overflow = "hidden";
17
+ t.dataset.oldPaddingTop = t.style.paddingTop, t.dataset.oldPaddingBottom = t.style.paddingBottom, t.dataset.oldOverflow = t.style.overflow, e = o(t), t.style.maxHeight = `${e}px`, t.style.overflow = "hidden";
18
18
  },
19
19
  handleLeave: (t) => {
20
20
  t.style.maxHeight = "0px", t.style.paddingTop = "0px", t.style.paddingBottom = "0px";
@@ -24,6 +24,10 @@ function h() {
24
24
  }
25
25
  };
26
26
  }
27
+ const y = /* @__PURE__ */ Symbol(
28
+ "modalItemContextKey"
29
+ );
27
30
  export {
31
+ y as modalItemContextKey,
28
32
  h as useCollapseAnim
29
33
  };
@@ -1 +1,2 @@
1
- @use '../fancy-button/styles/index.scss';
1
+ @use '../fancy-button/styles/index.scss' as button;
2
+ @use '../fancy-card/styles/index.scss' as card;
@@ -2,24 +2,27 @@ function i(e, t) {
2
2
  if (t?.importStyle)
3
3
  return `${e}/styles`;
4
4
  }
5
- function l(e, t, n) {
5
+ function u(e, t, n) {
6
6
  return n ? `${t}${n}/${e}` : `${t}/es/${e}`;
7
7
  }
8
- function f(e) {
8
+ function f(e, t, n) {
9
+ return n ? `${t}${n}/${e}` : `${t}/es/${e}`;
10
+ }
11
+ function l(e) {
9
12
  return {
10
13
  type: "component",
11
14
  resolve: (t) => {
12
- const { path: n, exclude: c } = e || {};
13
- if (t.match(/^Fancy[A-Z]/) && !c?.includes?.(t)) {
14
- const o = "fancy-plugins-components", r = t.replace(/([A-Z])/g, " $1").trim().split(" ").join("-").toLowerCase(), s = l(r, o, n);
15
+ const { path: n, exclude: s } = e || {};
16
+ if (t.match(/^Fancy[A-Z]/) && !s?.includes?.(t)) {
17
+ const r = "fancy-plugins-components", o = t.replace(/([A-Z])/g, " $1").trim().split(" ").join("-").toLowerCase(), c = u(o, r, n);
15
18
  return {
16
- from: `${o}${n}/${r}`,
17
- sideEffects: i(s, e)
19
+ from: f(o, r, n),
20
+ sideEffects: i(c, e)
18
21
  };
19
22
  }
20
23
  }
21
24
  };
22
25
  }
23
26
  export {
24
- f as FancyComponentsResolver
27
+ l as FancyComponentsResolver
25
28
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fancy-plugins-components",
3
- "version": "1.0.30",
3
+ "version": "1.0.32",
4
4
  "description": "",
5
5
  "main": "./dist/es/index.js",
6
6
  "module": "./dist/es/index.js",
@@ -14,6 +14,10 @@
14
14
  "types": "./dist/es/resolver.d.ts",
15
15
  "import": "./dist/es/resolver.js"
16
16
  },
17
+ "./global": {
18
+ "types": "./dist/es/global.d.ts",
19
+ "import": "./dist/es/global.js"
20
+ },
17
21
  "./styles": {
18
22
  "default": "./dist/es/styles/index.scss"
19
23
  },
@@ -26,7 +30,7 @@
26
30
  "dist"
27
31
  ],
28
32
  "scripts": {
29
- "build": "vite build && node build/copy-styles.ts"
33
+ "build": "vite build"
30
34
  },
31
35
  "sideEffects": [
32
36
  "**/*.css",
@@ -1,4 +0,0 @@
1
- import f from "./index.vue.js";
2
- export {
3
- f as default
4
- };