vcomp-test 0.0.4 → 0.0.5

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.
package/README.md CHANGED
@@ -1,6 +1,3 @@
1
- # vue-comp-test
1
+ # frontend-builder
2
2
 
3
- Two components:
4
-
5
- * BtnComp1: 一个按钮组件
6
- * BtnComp100: 一个按钮组件
3
+ This template should help get you started developing with Vue 3 in Vite.
package/dist/index.d.ts CHANGED
@@ -1,3 +1,2 @@
1
- import { default as BtnComp1 } from './TestComp.vue';
2
- import { default as BtnComp100 } from './BtnComp.vue';
3
- export { BtnComp1, BtnComp100 };
1
+ declare function hello(): void;
2
+ export { hello };
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"}),exports.hello=function(){console.log("hello")};
@@ -0,0 +1 @@
1
+ function o(){console.log("hello")}export{o as hello};
package/package.json CHANGED
@@ -1,11 +1,8 @@
1
1
  {
2
2
  "name": "vcomp-test",
3
- "version": "0.0.4",
3
+ "version": "0.0.5",
4
4
  "private": false,
5
5
  "type": "module",
6
- "engines": {
7
- "node": "^20.19.0 || >=22.12.0"
8
- },
9
6
  "scripts": {
10
7
  "dev": "vite",
11
8
  "build": "run-p type-check \"build-only {@}\" --",
@@ -18,45 +15,38 @@
18
15
  "files": [
19
16
  "dist"
20
17
  ],
18
+ "exports": {
19
+ ".": {
20
+ "types": "./dist/index.d.ts",
21
+ "import": "./dist/vcomp-test.es.js",
22
+ "require": "./dist/vcomp-test.cjs.js"
23
+ }
24
+ },
25
+ "dependencies": {
26
+ "vue": "^3.5.26"
27
+ },
21
28
  "devDependencies": {
22
- "@intlify/unplugin-vue-i18n": "^11.0.3",
23
- "@tailwindcss/vite": "^4.1.18",
24
- "@tsconfig/node24": "^24.0.3",
25
- "@types/node": "^24.10.4",
29
+ "@tsconfig/node24": "^24.0.4",
30
+ "@types/node": "^24.10.9",
26
31
  "@vitejs/plugin-vue": "^6.0.3",
27
32
  "@vitejs/plugin-vue-jsx": "^5.1.3",
28
- "@vue/eslint-config-prettier": "^10.2.0",
29
33
  "@vue/eslint-config-typescript": "^14.6.0",
30
34
  "@vue/tsconfig": "^0.8.1",
31
- "element-plus": "^2.13.1",
35
+ "change-case": "^5.4.4",
32
36
  "eslint": "^9.39.2",
33
- "eslint-plugin-vue": "~10.6.2",
37
+ "eslint-config-prettier": "^10.1.8",
38
+ "eslint-plugin-vue": "~10.7.0",
34
39
  "jiti": "^2.6.1",
35
40
  "npm-run-all2": "^8.0.4",
36
- "pinia": "^3.0.4",
37
- "prettier": "3.7.4",
38
- "tailwindcss": "^4.1.17",
41
+ "prettier": "3.8.1",
42
+ "terser": "^5.46.0",
39
43
  "typescript": "~5.9.3",
40
- "unplugin-auto-import": "^20.3.0",
41
- "unplugin-element-plus": "^0.11.2",
42
- "unplugin-vue-components": "^30.0.0",
43
- "vite": "^7.3.0",
44
+ "vite": "^7.3.1",
44
45
  "vite-plugin-dts": "^4.5.4",
45
- "vite-plugin-env-helper": "^1.1.0",
46
46
  "vite-plugin-vue-devtools": "^8.0.5",
47
- "vite-svg-loader": "^5.1.0",
48
- "vue-tsc": "^3.2.1"
49
- },
50
- "peerDependencies": {
51
- "element-plus": "*",
52
- "vue": "^3.0.0"
47
+ "vue-tsc": "^3.2.2"
53
48
  },
54
- "exports": {
55
- ".": {
56
- "types": "./dist/index.d.ts",
57
- "import": "./dist/vcomp.es.js",
58
- "require": "./dist/vcomp.cjs.js"
59
- },
60
- "./style.css": "./dist/vcomp.css"
49
+ "engines": {
50
+ "node": "^20.19.0 || >=22.12.0"
61
51
  }
62
52
  }
package/dist/vcomp.css DELETED
@@ -1 +0,0 @@
1
- @charset "UTF-8";:root{--el-color-white:#ffffff;--el-color-black:#000000;--el-color-primary-rgb:64,158,255;--el-color-success-rgb:103,194,58;--el-color-warning-rgb:230,162,60;--el-color-danger-rgb:245,108,108;--el-color-error-rgb:245,108,108;--el-color-info-rgb:144,147,153;--el-font-size-extra-large:20px;--el-font-size-large:18px;--el-font-size-medium:16px;--el-font-size-base:14px;--el-font-size-small:13px;--el-font-size-extra-small:12px;--el-font-family:"Helvetica Neue",Helvetica,"PingFang SC","Hiragino Sans GB","Microsoft YaHei","微软雅黑",Arial,sans-serif;--el-font-weight-primary:500;--el-font-line-height-primary:24px;--el-index-normal:1;--el-index-top:1000;--el-index-popper:2000;--el-border-radius-base:4px;--el-border-radius-small:2px;--el-border-radius-round:20px;--el-border-radius-circle:100%;--el-transition-duration:.3s;--el-transition-duration-fast:.2s;--el-transition-function-ease-in-out-bezier:cubic-bezier(.645,.045,.355,1);--el-transition-function-fast-bezier:cubic-bezier(.23,1,.32,1);--el-transition-all:all var(--el-transition-duration) var(--el-transition-function-ease-in-out-bezier);--el-transition-fade:opacity var(--el-transition-duration) var(--el-transition-function-fast-bezier);--el-transition-md-fade:transform var(--el-transition-duration) var(--el-transition-function-fast-bezier),opacity var(--el-transition-duration) var(--el-transition-function-fast-bezier);--el-transition-fade-linear:opacity var(--el-transition-duration-fast) linear;--el-transition-border:border-color var(--el-transition-duration-fast) var(--el-transition-function-ease-in-out-bezier);--el-transition-box-shadow:box-shadow var(--el-transition-duration-fast) var(--el-transition-function-ease-in-out-bezier);--el-transition-color:color var(--el-transition-duration-fast) var(--el-transition-function-ease-in-out-bezier);--el-component-size-large:40px;--el-component-size:32px;--el-component-size-small:24px;color-scheme:light;--el-color-primary:#409eff;--el-color-primary-light-3:rgb(121,187,255);--el-color-primary-light-5:rgb(160,207,255);--el-color-primary-light-7:rgb(198,226,255);--el-color-primary-light-8:rgb(217,236,255);--el-color-primary-light-9:rgb(236,245,255);--el-color-primary-dark-2:rgb(51,126,204);--el-color-success:#67c23a;--el-color-success-light-3:rgb(149,212,117);--el-color-success-light-5:rgb(179,225,157);--el-color-success-light-7:rgb(209,237,196);--el-color-success-light-8:rgb(225,243,216);--el-color-success-light-9:rgb(240,249,235);--el-color-success-dark-2:rgb(82,155,46);--el-color-warning:#e6a23c;--el-color-warning-light-3:rgb(238,190,119);--el-color-warning-light-5:rgb(243,209,158);--el-color-warning-light-7:rgb(248,227,197);--el-color-warning-light-8:rgb(250,236,216);--el-color-warning-light-9:rgb(253,246,236);--el-color-warning-dark-2:rgb(184,130,48);--el-color-danger:#f56c6c;--el-color-danger-light-3:rgb(248,152,152);--el-color-danger-light-5:rgb(250,182,182);--el-color-danger-light-7:rgb(252,211,211);--el-color-danger-light-8:rgb(253,226,226);--el-color-danger-light-9:rgb(254,240,240);--el-color-danger-dark-2:rgb(196,86,86);--el-color-error:#f56c6c;--el-color-error-light-3:rgb(248,152,152);--el-color-error-light-5:rgb(250,182,182);--el-color-error-light-7:rgb(252,211,211);--el-color-error-light-8:rgb(253,226,226);--el-color-error-light-9:rgb(254,240,240);--el-color-error-dark-2:rgb(196,86,86);--el-color-info:#909399;--el-color-info-light-3:rgb(177,179,184);--el-color-info-light-5:rgb(200,201,204);--el-color-info-light-7:rgb(222,223,224);--el-color-info-light-8:rgb(233,233,235);--el-color-info-light-9:rgb(244,244,245);--el-color-info-dark-2:rgb(115,118,122);--el-bg-color:#ffffff;--el-bg-color-page:#f2f3f5;--el-bg-color-overlay:#ffffff;--el-text-color-primary:#303133;--el-text-color-regular:#606266;--el-text-color-secondary:#909399;--el-text-color-placeholder:#a8abb2;--el-text-color-disabled:#c0c4cc;--el-border-color:#dcdfe6;--el-border-color-light:#e4e7ed;--el-border-color-lighter:#ebeef5;--el-border-color-extra-light:#f2f6fc;--el-border-color-dark:#d4d7de;--el-border-color-darker:#cdd0d6;--el-fill-color:#f0f2f5;--el-fill-color-light:#f5f7fa;--el-fill-color-lighter:#fafafa;--el-fill-color-extra-light:#fafcff;--el-fill-color-dark:#ebedf0;--el-fill-color-darker:#e6e8eb;--el-fill-color-blank:#ffffff;--el-box-shadow:0px 12px 32px 4px rgba(0,0,0,.04),0px 8px 20px rgba(0,0,0,.08);--el-box-shadow-light:0px 0px 12px rgba(0,0,0,.12);--el-box-shadow-lighter:0px 0px 6px rgba(0,0,0,.12);--el-box-shadow-dark:0px 16px 48px 16px rgba(0,0,0,.08),0px 12px 32px rgba(0,0,0,.12),0px 8px 16px -8px rgba(0,0,0,.16);--el-disabled-bg-color:var(--el-fill-color-light);--el-disabled-text-color:var(--el-text-color-placeholder);--el-disabled-border-color:var(--el-border-color-light);--el-overlay-color:rgba(0,0,0,.8);--el-overlay-color-light:rgba(0,0,0,.7);--el-overlay-color-lighter:rgba(0,0,0,.5);--el-mask-color:rgba(255,255,255,.9);--el-mask-color-extra-light:rgba(255,255,255,.3);--el-border-width:1px;--el-border-style:solid;--el-border-color-hover:var(--el-text-color-disabled);--el-border:var(--el-border-width) var(--el-border-style) var(--el-border-color);--el-svg-monochrome-grey:var(--el-border-color)}.fade-in-linear-enter-active,.fade-in-linear-leave-active{transition:var(--el-transition-fade-linear)}.fade-in-linear-enter-from,.fade-in-linear-leave-to{opacity:0}.el-fade-in-linear-enter-active,.el-fade-in-linear-leave-active{transition:var(--el-transition-fade-linear)}.el-fade-in-linear-enter-from,.el-fade-in-linear-leave-to{opacity:0}.el-fade-in-enter-active,.el-fade-in-leave-active{transition:all var(--el-transition-duration) cubic-bezier(.55,0,.1,1)}.el-fade-in-enter-from,.el-fade-in-leave-active{opacity:0}.el-zoom-in-center-enter-active,.el-zoom-in-center-leave-active{transition:all var(--el-transition-duration) cubic-bezier(.55,0,.1,1)}.el-zoom-in-center-enter-from,.el-zoom-in-center-leave-active{opacity:0;transform:scaleX(0)}.el-zoom-in-top-enter-active,.el-zoom-in-top-leave-active{opacity:1;transform:scaleY(1);transform-origin:center top;transition:var(--el-transition-md-fade)}.el-zoom-in-top-enter-active[data-popper-placement^=top],.el-zoom-in-top-leave-active[data-popper-placement^=top]{transform-origin:center bottom}.el-zoom-in-top-enter-from,.el-zoom-in-top-leave-active{opacity:0;transform:scaleY(0)}.el-zoom-in-bottom-enter-active,.el-zoom-in-bottom-leave-active{opacity:1;transform:scaleY(1);transform-origin:center bottom;transition:var(--el-transition-md-fade)}.el-zoom-in-bottom-enter-from,.el-zoom-in-bottom-leave-active{opacity:0;transform:scaleY(0)}.el-zoom-in-left-enter-active,.el-zoom-in-left-leave-active{opacity:1;transform:scale(1);transform-origin:top left;transition:var(--el-transition-md-fade)}.el-zoom-in-left-enter-from,.el-zoom-in-left-leave-active{opacity:0;transform:scale(.45)}.collapse-transition{transition:var(--el-transition-duration) height ease-in-out,var(--el-transition-duration) padding-top ease-in-out,var(--el-transition-duration) padding-bottom ease-in-out}.el-collapse-transition-enter-active,.el-collapse-transition-leave-active{transition:var(--el-transition-duration) max-height ease-in-out,var(--el-transition-duration) padding-top ease-in-out,var(--el-transition-duration) padding-bottom ease-in-out}.horizontal-collapse-transition{transition:var(--el-transition-duration) width ease-in-out,var(--el-transition-duration) padding-left ease-in-out,var(--el-transition-duration) padding-right ease-in-out}.el-list-enter-active,.el-list-leave-active{transition:all 1s}.el-list-enter-from,.el-list-leave-to{opacity:0;transform:translateY(-30px)}.el-list-leave-active{position:absolute!important}.el-opacity-transition{transition:opacity var(--el-transition-duration) cubic-bezier(.55,0,.1,1)}.el-icon--right{margin-left:5px}.el-icon--left{margin-right:5px}@keyframes rotating{0%{transform:rotate(0)}to{transform:rotate(1turn)}}.el-icon{--color:inherit;align-items:center;color:var(--color);display:inline-flex;fill:currentColor;font-size:inherit;height:1em;justify-content:center;line-height:1em;position:relative;width:1em}.el-icon.is-loading{animation:rotating 2s linear infinite}.el-icon svg{height:1em;width:1em}.el-button{--el-button-font-weight:var(--el-font-weight-primary);--el-button-border-color:var(--el-border-color);--el-button-bg-color:var(--el-fill-color-blank);--el-button-text-color:var(--el-text-color-regular);--el-button-disabled-text-color:var(--el-disabled-text-color);--el-button-disabled-bg-color:var(--el-fill-color-blank);--el-button-disabled-border-color:var(--el-border-color-light);--el-button-divide-border-color:rgba(255,255,255,.5);--el-button-hover-text-color:var(--el-color-primary);--el-button-hover-bg-color:var(--el-color-primary-light-9);--el-button-hover-border-color:var(--el-color-primary-light-7);--el-button-active-text-color:var(--el-button-hover-text-color);--el-button-active-border-color:var(--el-color-primary);--el-button-active-bg-color:var(--el-button-hover-bg-color);--el-button-outline-color:var(--el-color-primary-light-5);--el-button-hover-link-text-color:var(--el-text-color-secondary);--el-button-active-color:var(--el-text-color-primary);align-items:center;-webkit-appearance:none;background-color:var(--el-button-bg-color);border:var(--el-border);border-color:var(--el-button-border-color);box-sizing:border-box;color:var(--el-button-text-color);cursor:pointer;display:inline-flex;font-weight:var(--el-button-font-weight);height:32px;justify-content:center;line-height:1;outline:none;text-align:center;transition:.1s;-webkit-user-select:none;-moz-user-select:none;user-select:none;vertical-align:middle;white-space:nowrap}.el-button:hover{background-color:var(--el-button-hover-bg-color);border-color:var(--el-button-hover-border-color);color:var(--el-button-hover-text-color);outline:none}.el-button:active{background-color:var(--el-button-active-bg-color);border-color:var(--el-button-active-border-color);color:var(--el-button-active-text-color);outline:none}.el-button:focus-visible{outline:2px solid var(--el-button-outline-color);outline-offset:1px;transition:outline-offset 0s,outline 0s}.el-button>span{align-items:center;display:inline-flex}.el-button+.el-button{margin-left:12px}.el-button{border-radius:var(--el-border-radius-base);font-size:var(--el-font-size-base)}.el-button,.el-button.is-round{padding:8px 15px}.el-button::-moz-focus-inner{border:0}.el-button [class*=el-icon]+span{margin-left:6px}.el-button [class*=el-icon] svg{vertical-align:bottom}.el-button.is-plain{--el-button-hover-text-color:var(--el-color-primary);--el-button-hover-bg-color:var(--el-fill-color-blank);--el-button-hover-border-color:var(--el-color-primary)}.el-button.is-active{background-color:var(--el-button-active-bg-color);border-color:var(--el-button-active-border-color);color:var(--el-button-active-text-color);outline:none}.el-button.is-disabled,.el-button.is-disabled:hover{background-color:var(--el-button-disabled-bg-color);background-image:none;border-color:var(--el-button-disabled-border-color);color:var(--el-button-disabled-text-color);cursor:not-allowed}.el-button.is-loading{pointer-events:none;position:relative}.el-button.is-loading:before{background-color:var(--el-mask-color-extra-light);border-radius:inherit;content:"";inset:-1px;pointer-events:none;position:absolute;z-index:1}.el-button.is-round{border-radius:var(--el-border-radius-round)}.el-button.is-circle{border-radius:50%;padding:8px;width:32px}.el-button.is-text{background-color:transparent;border:0 solid transparent;color:var(--el-button-text-color)}.el-button.is-text.is-disabled{background-color:transparent!important;color:var(--el-button-disabled-text-color)}.el-button.is-text:not(.is-disabled):hover{background-color:var(--el-fill-color-light)}.el-button.is-text:not(.is-disabled):focus-visible{outline:2px solid var(--el-button-outline-color);outline-offset:1px;transition:outline-offset 0s,outline 0s}.el-button.is-text:not(.is-disabled):active{background-color:var(--el-fill-color)}.el-button.is-text:not(.is-disabled).is-has-bg{background-color:var(--el-fill-color-light)}.el-button.is-text:not(.is-disabled).is-has-bg:hover{background-color:var(--el-fill-color)}.el-button.is-text:not(.is-disabled).is-has-bg:active{background-color:var(--el-fill-color-dark)}.el-button__text--expand{letter-spacing:.3em;margin-right:-.3em}.el-button.is-link{background:transparent;border-color:transparent;color:var(--el-button-text-color);height:auto;padding:2px}.el-button.is-link:hover{color:var(--el-button-hover-link-text-color)}.el-button.is-link.is-disabled{background-color:transparent!important;border-color:transparent!important;color:var(--el-button-disabled-text-color)}.el-button.is-link:not(.is-disabled):active,.el-button.is-link:not(.is-disabled):hover{background-color:transparent;border-color:transparent}.el-button.is-link:not(.is-disabled):active{color:var(--el-button-active-color)}.el-button--text{background:transparent;border-color:transparent;color:var(--el-color-primary);padding-left:0;padding-right:0}.el-button--text.is-disabled{background-color:transparent!important;border-color:transparent!important;color:var(--el-button-disabled-text-color)}.el-button--text:not(.is-disabled):hover{background-color:transparent;border-color:transparent;color:var(--el-color-primary-light-3)}.el-button--text:not(.is-disabled):active{background-color:transparent;border-color:transparent;color:var(--el-color-primary-dark-2)}.el-button__link--expand{letter-spacing:.3em;margin-right:-.3em}.el-button--primary{--el-button-text-color:var(--el-color-white);--el-button-bg-color:var(--el-color-primary);--el-button-border-color:var(--el-color-primary);--el-button-outline-color:var(--el-color-primary-light-5);--el-button-active-color:var(--el-color-primary-dark-2);--el-button-hover-text-color:var(--el-color-white);--el-button-hover-link-text-color:var(--el-color-primary-light-5);--el-button-hover-bg-color:var(--el-color-primary-light-3);--el-button-hover-border-color:var(--el-color-primary-light-3);--el-button-active-bg-color:var(--el-color-primary-dark-2);--el-button-active-border-color:var(--el-color-primary-dark-2);--el-button-disabled-text-color:var(--el-color-white);--el-button-disabled-bg-color:var(--el-color-primary-light-5);--el-button-disabled-border-color:var(--el-color-primary-light-5)}.el-button--primary.is-link,.el-button--primary.is-plain,.el-button--primary.is-text{--el-button-text-color:var(--el-color-primary);--el-button-bg-color:var(--el-color-primary-light-9);--el-button-border-color:var(--el-color-primary-light-5);--el-button-hover-text-color:var(--el-color-white);--el-button-hover-bg-color:var(--el-color-primary);--el-button-hover-border-color:var(--el-color-primary);--el-button-active-text-color:var(--el-color-white)}.el-button--primary.is-link.is-disabled,.el-button--primary.is-link.is-disabled:active,.el-button--primary.is-link.is-disabled:focus,.el-button--primary.is-link.is-disabled:hover,.el-button--primary.is-plain.is-disabled,.el-button--primary.is-plain.is-disabled:active,.el-button--primary.is-plain.is-disabled:focus,.el-button--primary.is-plain.is-disabled:hover,.el-button--primary.is-text.is-disabled,.el-button--primary.is-text.is-disabled:active,.el-button--primary.is-text.is-disabled:focus,.el-button--primary.is-text.is-disabled:hover{background-color:var(--el-color-primary-light-9);border-color:var(--el-color-primary-light-8);color:var(--el-color-primary-light-5)}.el-button--success{--el-button-text-color:var(--el-color-white);--el-button-bg-color:var(--el-color-success);--el-button-border-color:var(--el-color-success);--el-button-outline-color:var(--el-color-success-light-5);--el-button-active-color:var(--el-color-success-dark-2);--el-button-hover-text-color:var(--el-color-white);--el-button-hover-link-text-color:var(--el-color-success-light-5);--el-button-hover-bg-color:var(--el-color-success-light-3);--el-button-hover-border-color:var(--el-color-success-light-3);--el-button-active-bg-color:var(--el-color-success-dark-2);--el-button-active-border-color:var(--el-color-success-dark-2);--el-button-disabled-text-color:var(--el-color-white);--el-button-disabled-bg-color:var(--el-color-success-light-5);--el-button-disabled-border-color:var(--el-color-success-light-5)}.el-button--success.is-link,.el-button--success.is-plain,.el-button--success.is-text{--el-button-text-color:var(--el-color-success);--el-button-bg-color:var(--el-color-success-light-9);--el-button-border-color:var(--el-color-success-light-5);--el-button-hover-text-color:var(--el-color-white);--el-button-hover-bg-color:var(--el-color-success);--el-button-hover-border-color:var(--el-color-success);--el-button-active-text-color:var(--el-color-white)}.el-button--success.is-link.is-disabled,.el-button--success.is-link.is-disabled:active,.el-button--success.is-link.is-disabled:focus,.el-button--success.is-link.is-disabled:hover,.el-button--success.is-plain.is-disabled,.el-button--success.is-plain.is-disabled:active,.el-button--success.is-plain.is-disabled:focus,.el-button--success.is-plain.is-disabled:hover,.el-button--success.is-text.is-disabled,.el-button--success.is-text.is-disabled:active,.el-button--success.is-text.is-disabled:focus,.el-button--success.is-text.is-disabled:hover{background-color:var(--el-color-success-light-9);border-color:var(--el-color-success-light-8);color:var(--el-color-success-light-5)}.el-button--warning{--el-button-text-color:var(--el-color-white);--el-button-bg-color:var(--el-color-warning);--el-button-border-color:var(--el-color-warning);--el-button-outline-color:var(--el-color-warning-light-5);--el-button-active-color:var(--el-color-warning-dark-2);--el-button-hover-text-color:var(--el-color-white);--el-button-hover-link-text-color:var(--el-color-warning-light-5);--el-button-hover-bg-color:var(--el-color-warning-light-3);--el-button-hover-border-color:var(--el-color-warning-light-3);--el-button-active-bg-color:var(--el-color-warning-dark-2);--el-button-active-border-color:var(--el-color-warning-dark-2);--el-button-disabled-text-color:var(--el-color-white);--el-button-disabled-bg-color:var(--el-color-warning-light-5);--el-button-disabled-border-color:var(--el-color-warning-light-5)}.el-button--warning.is-link,.el-button--warning.is-plain,.el-button--warning.is-text{--el-button-text-color:var(--el-color-warning);--el-button-bg-color:var(--el-color-warning-light-9);--el-button-border-color:var(--el-color-warning-light-5);--el-button-hover-text-color:var(--el-color-white);--el-button-hover-bg-color:var(--el-color-warning);--el-button-hover-border-color:var(--el-color-warning);--el-button-active-text-color:var(--el-color-white)}.el-button--warning.is-link.is-disabled,.el-button--warning.is-link.is-disabled:active,.el-button--warning.is-link.is-disabled:focus,.el-button--warning.is-link.is-disabled:hover,.el-button--warning.is-plain.is-disabled,.el-button--warning.is-plain.is-disabled:active,.el-button--warning.is-plain.is-disabled:focus,.el-button--warning.is-plain.is-disabled:hover,.el-button--warning.is-text.is-disabled,.el-button--warning.is-text.is-disabled:active,.el-button--warning.is-text.is-disabled:focus,.el-button--warning.is-text.is-disabled:hover{background-color:var(--el-color-warning-light-9);border-color:var(--el-color-warning-light-8);color:var(--el-color-warning-light-5)}.el-button--danger{--el-button-text-color:var(--el-color-white);--el-button-bg-color:var(--el-color-danger);--el-button-border-color:var(--el-color-danger);--el-button-outline-color:var(--el-color-danger-light-5);--el-button-active-color:var(--el-color-danger-dark-2);--el-button-hover-text-color:var(--el-color-white);--el-button-hover-link-text-color:var(--el-color-danger-light-5);--el-button-hover-bg-color:var(--el-color-danger-light-3);--el-button-hover-border-color:var(--el-color-danger-light-3);--el-button-active-bg-color:var(--el-color-danger-dark-2);--el-button-active-border-color:var(--el-color-danger-dark-2);--el-button-disabled-text-color:var(--el-color-white);--el-button-disabled-bg-color:var(--el-color-danger-light-5);--el-button-disabled-border-color:var(--el-color-danger-light-5)}.el-button--danger.is-link,.el-button--danger.is-plain,.el-button--danger.is-text{--el-button-text-color:var(--el-color-danger);--el-button-bg-color:var(--el-color-danger-light-9);--el-button-border-color:var(--el-color-danger-light-5);--el-button-hover-text-color:var(--el-color-white);--el-button-hover-bg-color:var(--el-color-danger);--el-button-hover-border-color:var(--el-color-danger);--el-button-active-text-color:var(--el-color-white)}.el-button--danger.is-link.is-disabled,.el-button--danger.is-link.is-disabled:active,.el-button--danger.is-link.is-disabled:focus,.el-button--danger.is-link.is-disabled:hover,.el-button--danger.is-plain.is-disabled,.el-button--danger.is-plain.is-disabled:active,.el-button--danger.is-plain.is-disabled:focus,.el-button--danger.is-plain.is-disabled:hover,.el-button--danger.is-text.is-disabled,.el-button--danger.is-text.is-disabled:active,.el-button--danger.is-text.is-disabled:focus,.el-button--danger.is-text.is-disabled:hover{background-color:var(--el-color-danger-light-9);border-color:var(--el-color-danger-light-8);color:var(--el-color-danger-light-5)}.el-button--info{--el-button-text-color:var(--el-color-white);--el-button-bg-color:var(--el-color-info);--el-button-border-color:var(--el-color-info);--el-button-outline-color:var(--el-color-info-light-5);--el-button-active-color:var(--el-color-info-dark-2);--el-button-hover-text-color:var(--el-color-white);--el-button-hover-link-text-color:var(--el-color-info-light-5);--el-button-hover-bg-color:var(--el-color-info-light-3);--el-button-hover-border-color:var(--el-color-info-light-3);--el-button-active-bg-color:var(--el-color-info-dark-2);--el-button-active-border-color:var(--el-color-info-dark-2);--el-button-disabled-text-color:var(--el-color-white);--el-button-disabled-bg-color:var(--el-color-info-light-5);--el-button-disabled-border-color:var(--el-color-info-light-5)}.el-button--info.is-link,.el-button--info.is-plain,.el-button--info.is-text{--el-button-text-color:var(--el-color-info);--el-button-bg-color:var(--el-color-info-light-9);--el-button-border-color:var(--el-color-info-light-5);--el-button-hover-text-color:var(--el-color-white);--el-button-hover-bg-color:var(--el-color-info);--el-button-hover-border-color:var(--el-color-info);--el-button-active-text-color:var(--el-color-white)}.el-button--info.is-link.is-disabled,.el-button--info.is-link.is-disabled:active,.el-button--info.is-link.is-disabled:focus,.el-button--info.is-link.is-disabled:hover,.el-button--info.is-plain.is-disabled,.el-button--info.is-plain.is-disabled:active,.el-button--info.is-plain.is-disabled:focus,.el-button--info.is-plain.is-disabled:hover,.el-button--info.is-text.is-disabled,.el-button--info.is-text.is-disabled:active,.el-button--info.is-text.is-disabled:focus,.el-button--info.is-text.is-disabled:hover{background-color:var(--el-color-info-light-9);border-color:var(--el-color-info-light-8);color:var(--el-color-info-light-5)}.el-button--large{--el-button-size:40px;height:var(--el-button-size)}.el-button--large [class*=el-icon]+span{margin-left:8px}.el-button--large{border-radius:var(--el-border-radius-base);font-size:var(--el-font-size-base);padding:12px 19px}.el-button--large.is-round{padding:12px 19px}.el-button--large.is-circle{padding:12px;width:var(--el-button-size)}.el-button--small{--el-button-size:24px;height:var(--el-button-size)}.el-button--small [class*=el-icon]+span{margin-left:4px}.el-button--small{border-radius:calc(var(--el-border-radius-base) - 1px);font-size:12px;padding:5px 11px}.el-button--small.is-round{padding:5px 11px}.el-button--small.is-circle{padding:5px;width:var(--el-button-size)}.el-badge{--el-badge-bg-color:var(--el-color-danger);--el-badge-radius:10px;--el-badge-font-size:12px;--el-badge-padding:6px;--el-badge-size:18px;display:inline-block;position:relative;vertical-align:middle;width:-moz-fit-content;width:fit-content}.el-badge__content{align-items:center;background-color:var(--el-badge-bg-color);border:1px solid var(--el-bg-color);border-radius:var(--el-badge-radius);color:var(--el-color-white);display:inline-flex;font-size:var(--el-badge-font-size);height:var(--el-badge-size);justify-content:center;padding:0 var(--el-badge-padding);white-space:nowrap}.el-badge__content.is-fixed{position:absolute;right:calc(1px + var(--el-badge-size)/2);top:0;transform:translateY(-50%) translate(100%);z-index:var(--el-index-normal)}.el-badge__content.is-fixed.is-dot{right:5px}.el-badge__content.is-dot{border-radius:50%;height:8px;padding:0;right:0;width:8px}.el-badge__content.is-hide-zero{display:none}.el-badge__content--primary{background-color:var(--el-color-primary)}.el-badge__content--success{background-color:var(--el-color-success)}.el-badge__content--warning{background-color:var(--el-color-warning)}.el-badge__content--info{background-color:var(--el-color-info)}.el-badge__content--danger{background-color:var(--el-color-danger)}.el-message{--el-message-bg-color:var(--el-color-info-light-9);--el-message-border-color:var(--el-border-color-lighter);--el-message-padding:11px 15px;--el-message-close-size:16px;--el-message-close-icon-color:var(--el-text-color-placeholder);--el-message-close-hover-color:var(--el-text-color-secondary);align-items:center;background-color:var(--el-message-bg-color);border-color:var(--el-message-border-color);border-radius:var(--el-border-radius-base);border-style:var(--el-border-style);border-width:var(--el-border-width);box-sizing:border-box;display:flex;gap:8px;max-width:calc(100% - 32px);padding:var(--el-message-padding);position:fixed;transition:opacity var(--el-transition-duration),transform .4s,top .4s,bottom .4s;width:-moz-fit-content;width:fit-content}.el-message.is-left{left:16px}.el-message.is-right{right:16px}.el-message.is-center{left:0;margin:0 auto;right:0}.el-message.is-plain{background-color:var(--el-bg-color-overlay);border-color:var(--el-bg-color-overlay);box-shadow:var(--el-box-shadow-light)}.el-message p{margin:0}.el-message--primary{--el-message-bg-color:var(--el-color-primary-light-9);--el-message-border-color:var(--el-color-primary-light-8);--el-message-text-color:var(--el-color-primary)}.el-message--primary .el-message__content{color:var(--el-message-text-color);overflow-wrap:break-word}.el-message .el-message-icon--primary{color:var(--el-message-text-color)}.el-message--success{--el-message-bg-color:var(--el-color-success-light-9);--el-message-border-color:var(--el-color-success-light-8);--el-message-text-color:var(--el-color-success)}.el-message--success .el-message__content{color:var(--el-message-text-color);overflow-wrap:break-word}.el-message .el-message-icon--success{color:var(--el-message-text-color)}.el-message--info{--el-message-bg-color:var(--el-color-info-light-9);--el-message-border-color:var(--el-color-info-light-8);--el-message-text-color:var(--el-color-info)}.el-message--info .el-message__content{color:var(--el-message-text-color);overflow-wrap:break-word}.el-message .el-message-icon--info{color:var(--el-message-text-color)}.el-message--warning{--el-message-bg-color:var(--el-color-warning-light-9);--el-message-border-color:var(--el-color-warning-light-8);--el-message-text-color:var(--el-color-warning)}.el-message--warning .el-message__content{color:var(--el-message-text-color);overflow-wrap:break-word}.el-message .el-message-icon--warning{color:var(--el-message-text-color)}.el-message--error{--el-message-bg-color:var(--el-color-error-light-9);--el-message-border-color:var(--el-color-error-light-8);--el-message-text-color:var(--el-color-error)}.el-message--error .el-message__content{color:var(--el-message-text-color);overflow-wrap:break-word}.el-message .el-message-icon--error{color:var(--el-message-text-color)}.el-message .el-message__badge{position:absolute;right:-8px;top:-8px}.el-message__content{font-size:14px;line-height:1;padding:0}.el-message__content:focus{outline-width:0}.el-message .el-message__closeBtn{color:var(--el-message-close-icon-color);cursor:pointer;font-size:var(--el-message-close-size)}.el-message .el-message__closeBtn:focus{outline-width:0}.el-message .el-message__closeBtn:hover{color:var(--el-message-close-hover-color)}.el-message-fade-enter-from,.el-message-fade-leave-to{opacity:0;transform:translateY(-100%)}.el-message-fade-enter-from.is-bottom,.el-message-fade-leave-to.is-bottom{transform:translateY(100%)}
package/dist/vcomp.es.js DELETED
@@ -1,1072 +0,0 @@
1
- import { getCurrentInstance as Z, inject as w, ref as E, computed as h, unref as g, warn as Bt, defineComponent as I, createElementBlock as P, openBlock as S, mergeProps as lt, renderSlot as R, createElementVNode as At, watch as Et, useSlots as Ht, Text as Ct, createBlock as B, resolveDynamicComponent as G, withCtx as V, createCommentVNode as tt, Fragment as It, normalizeClass as W, provide as Rt, reactive as Vt, toRef as et, createTextVNode as ft, toDisplayString as dt } from "vue";
2
- import { ElMessage as ht } from "element-plus";
3
- const Pt = /* @__PURE__ */ Symbol(), D = "el", Tt = "is-", N = (t, r, e, n, a) => {
4
- let o = `${t}-${r}`;
5
- return e && (o += `-${e}`), n && (o += `__${n}`), a && (o += `--${a}`), o;
6
- }, Ot = /* @__PURE__ */ Symbol("namespaceContextKey"), zt = (t) => {
7
- const r = Z() ? w(Ot, E(D)) : E(D);
8
- return h(() => g(r) || D);
9
- }, F = (t, r) => {
10
- const e = zt();
11
- return {
12
- namespace: e,
13
- b: (c = "") => N(e.value, t, c, "", ""),
14
- e: (c) => c ? N(e.value, t, "", c, "") : "",
15
- m: (c) => c ? N(e.value, t, "", "", c) : "",
16
- be: (c, d) => c && d ? N(e.value, t, c, d, "") : "",
17
- em: (c, d) => c && d ? N(e.value, t, "", c, d) : "",
18
- bm: (c, d) => c && d ? N(e.value, t, c, "", d) : "",
19
- bem: (c, d, u) => c && d && u ? N(e.value, t, c, d, u) : "",
20
- is: (c, ...d) => {
21
- const u = d.length >= 1 ? d[0] : !0;
22
- return c && u ? `${Tt}${c}` : "";
23
- },
24
- cssVar: (c) => {
25
- const d = {};
26
- for (const u in c)
27
- c[u] && (d[`--${e.value}-${u}`] = c[u]);
28
- return d;
29
- },
30
- cssVarName: (c) => `--${e.value}-${c}`,
31
- cssVarBlock: (c) => {
32
- const d = {};
33
- for (const u in c)
34
- c[u] && (d[`--${e.value}-${t}-${u}`] = c[u]);
35
- return d;
36
- },
37
- cssVarBlockName: (c) => `--${e.value}-${t}-${c}`
38
- };
39
- };
40
- process.env.NODE_ENV !== "production" && Object.freeze({});
41
- process.env.NODE_ENV !== "production" && Object.freeze([]);
42
- const Ft = () => {
43
- }, jt = Object.prototype.hasOwnProperty, rt = (t, r) => jt.call(t, r), Y = (t) => typeof t == "string", gt = (t) => t !== null && typeof t == "object";
44
- function Gt(t) {
45
- for (var r = -1, e = t == null ? 0 : t.length, n = {}; ++r < e; ) {
46
- var a = t[r];
47
- n[a[0]] = a[1];
48
- }
49
- return n;
50
- }
51
- const Dt = (t) => typeof t == "number", Kt = (t) => Y(t) ? !Number.isNaN(Number(t)) : !1;
52
- class Lt extends Error {
53
- constructor(r) {
54
- super(r), this.name = "ElementPlusError";
55
- }
56
- }
57
- function vt(t, r) {
58
- if (process.env.NODE_ENV !== "production") {
59
- const e = Y(t) ? new Lt(`[${t}] ${r}`) : t;
60
- console.warn(e);
61
- }
62
- }
63
- const pt = "__epPropKey", j = (t) => t, qt = (t) => gt(t) && !!t[pt], bt = (t, r) => {
64
- if (!gt(t) || qt(t))
65
- return t;
66
- const { values: e, required: n, default: a, type: o, validator: i } = t, f = {
67
- type: o,
68
- required: !!n,
69
- validator: e || i ? (m) => {
70
- let v = !1, _ = [];
71
- if (e && (_ = Array.from(e), rt(t, "default") && _.push(a), v || (v = _.includes(m))), i && (v || (v = i(m))), !v && _.length > 0) {
72
- const H = [...new Set(_)].map((C) => JSON.stringify(C)).join(", ");
73
- Bt(
74
- `Invalid prop: validation failed${r ? ` for prop "${r}"` : ""}. Expected one of [${H}], got value ${JSON.stringify(
75
- m
76
- )}.`
77
- );
78
- }
79
- return v;
80
- } : void 0,
81
- [pt]: !0
82
- };
83
- return rt(t, "default") && (f.default = a), f;
84
- }, mt = (t) => Gt(
85
- Object.entries(t).map(([r, e]) => [
86
- r,
87
- bt(e, r)
88
- ])
89
- ), Wt = ["", "default", "small", "large"], Ut = bt({
90
- type: String,
91
- values: Wt,
92
- required: !1
93
- }), Jt = /* @__PURE__ */ Symbol("size"), Zt = () => {
94
- const t = w(Jt, {});
95
- return h(() => g(t.size) || "");
96
- }, nt = E();
97
- function Yt(t, r = void 0) {
98
- const e = Z() ? w(Pt, nt) : nt;
99
- return h(() => {
100
- var n, a;
101
- return (a = (n = e.value) == null ? void 0 : n[t]) != null ? a : r;
102
- });
103
- }
104
- var Q = (t, r) => {
105
- const e = t.__vccOpts || t;
106
- for (const [n, a] of r)
107
- e[n] = a;
108
- return e;
109
- };
110
- const yt = (t, r) => {
111
- if (t.install = (e) => {
112
- for (const n of [t, ...Object.values(r ?? {})])
113
- e.component(n.name, n);
114
- }, r)
115
- for (const [e, n] of Object.entries(r))
116
- t[e] = n;
117
- return t;
118
- }, Qt = (t) => (t.install = Ft, t), Xt = "utils/dom/style";
119
- function te(t, r = "px") {
120
- if (!t && t !== 0)
121
- return "";
122
- if (Dt(t) || Kt(t))
123
- return `${t}${r}`;
124
- if (Y(t))
125
- return t;
126
- vt(Xt, "binding value must be a string or number");
127
- }
128
- const ee = mt({
129
- size: {
130
- type: j([Number, String])
131
- },
132
- color: {
133
- type: String
134
- }
135
- }), re = I({
136
- name: "ElIcon",
137
- inheritAttrs: !1,
138
- __name: "icon",
139
- props: ee,
140
- setup(t) {
141
- const r = t, e = F("icon"), n = h(() => {
142
- const { size: a, color: o } = r, i = te(a);
143
- return !i && !o ? {} : {
144
- fontSize: i,
145
- "--color": o
146
- };
147
- });
148
- return (a, o) => (S(), P(
149
- "i",
150
- lt({
151
- class: g(e).b(),
152
- style: n.value
153
- }, a.$attrs),
154
- [
155
- R(a.$slots, "default")
156
- ],
157
- 16
158
- ));
159
- }
160
- });
161
- var ne = /* @__PURE__ */ Q(re, [["__file", "/home/runner/work/element-plus/element-plus/packages/components/icon/src/icon.vue"]]);
162
- const at = yt(ne);
163
- var ae = /* @__PURE__ */ I({
164
- name: "Loading",
165
- __name: "loading",
166
- setup(t) {
167
- return (r, e) => (S(), P("svg", {
168
- xmlns: "http://www.w3.org/2000/svg",
169
- viewBox: "0 0 1024 1024"
170
- }, [
171
- At("path", {
172
- fill: "currentColor",
173
- d: "M512 64a32 32 0 0 1 32 32v192a32 32 0 0 1-64 0V96a32 32 0 0 1 32-32m0 640a32 32 0 0 1 32 32v192a32 32 0 1 1-64 0V736a32 32 0 0 1 32-32m448-192a32 32 0 0 1-32 32H736a32 32 0 1 1 0-64h192a32 32 0 0 1 32 32m-640 0a32 32 0 0 1-32 32H96a32 32 0 0 1 0-64h192a32 32 0 0 1 32 32M195.2 195.2a32 32 0 0 1 45.248 0L376.32 331.008a32 32 0 0 1-45.248 45.248L195.2 240.448a32 32 0 0 1 0-45.248m452.544 452.544a32 32 0 0 1 45.248 0L828.8 783.552a32 32 0 0 1-45.248 45.248L647.744 692.992a32 32 0 0 1 0-45.248M828.8 195.264a32 32 0 0 1 0 45.184L692.992 376.32a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0m-452.544 452.48a32 32 0 0 1 0 45.248L240.448 828.8a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0"
174
- })
175
- ]));
176
- }
177
- }), oe = ae;
178
- const ot = j([
179
- String,
180
- Object,
181
- Function
182
- ]), X = /* @__PURE__ */ Symbol("formContextKey"), _t = /* @__PURE__ */ Symbol("formItemContextKey"), ie = () => {
183
- const t = w(X, void 0), r = w(_t, void 0);
184
- return {
185
- form: t,
186
- formItem: r
187
- };
188
- }, St = (t) => {
189
- const r = Z();
190
- return h(() => {
191
- var e, n;
192
- return (n = (e = r?.proxy) == null ? void 0 : e.$props) == null ? void 0 : n[t];
193
- });
194
- }, se = (t, r = {}) => {
195
- const e = E(void 0), n = r.prop ? e : St("size"), a = r.global ? e : Zt(), o = r.form ? { size: void 0 } : w(X, void 0), i = r.formItem ? { size: void 0 } : w(_t, void 0);
196
- return h(
197
- () => n.value || g(t) || i?.size || o?.size || a.value || ""
198
- );
199
- }, xt = (t) => {
200
- const r = St("disabled"), e = w(X, void 0);
201
- return h(() => {
202
- var n, a, o;
203
- return (o = (a = (n = r.value) != null ? n : g(t)) != null ? a : e?.disabled) != null ? o : !1;
204
- });
205
- }, kt = /* @__PURE__ */ Symbol(
206
- "buttonGroupContextKey"
207
- ), ce = ({ from: t, replacement: r, scope: e, version: n, ref: a, type: o = "API" }, i) => {
208
- Et(
209
- () => g(i),
210
- (s) => {
211
- s && vt(
212
- e,
213
- `[${o}] ${t} is about to be deprecated in version ${n}, please use ${r} instead.
214
- For more detail, please visit: ${a}
215
- `
216
- );
217
- },
218
- {
219
- immediate: !0
220
- }
221
- );
222
- }, ue = (t, r) => {
223
- ce(
224
- {
225
- from: "type.text",
226
- replacement: "link",
227
- version: "3.0.0",
228
- scope: "props",
229
- ref: "https://element-plus.org/en-US/component/button.html#button-attributes"
230
- },
231
- h(() => t.type === "text")
232
- );
233
- const e = w(kt, void 0), n = Yt("button"), { form: a } = ie(), o = se(h(() => e?.size)), i = xt(), s = E(), f = Ht(), m = h(
234
- () => {
235
- var u;
236
- return t.type || e?.type || ((u = n.value) == null ? void 0 : u.type) || "";
237
- }
238
- ), v = h(
239
- () => {
240
- var u, l, b;
241
- return (b = (l = t.autoInsertSpace) != null ? l : (u = n.value) == null ? void 0 : u.autoInsertSpace) != null ? b : !1;
242
- }
243
- ), _ = h(
244
- () => {
245
- var u, l, b;
246
- return (b = (l = t.plain) != null ? l : (u = n.value) == null ? void 0 : u.plain) != null ? b : !1;
247
- }
248
- ), H = h(
249
- () => {
250
- var u, l, b;
251
- return (b = (l = t.round) != null ? l : (u = n.value) == null ? void 0 : u.round) != null ? b : !1;
252
- }
253
- ), C = h(() => {
254
- var u, l, b;
255
- return (b = (l = t.text) != null ? l : (u = n.value) == null ? void 0 : u.text) != null ? b : !1;
256
- }), T = h(() => t.tag === "button" ? {
257
- ariaDisabled: i.value || t.loading,
258
- disabled: i.value || t.loading,
259
- autofocus: t.autofocus,
260
- type: t.nativeType
261
- } : {}), c = h(() => {
262
- var u;
263
- const l = (u = f.default) == null ? void 0 : u.call(f);
264
- if (v.value && l?.length === 1) {
265
- const b = l[0];
266
- if (b?.type === Ct) {
267
- const Nt = b.children;
268
- return new RegExp("^\\p{Unified_Ideograph}{2}$", "u").test(Nt.trim());
269
- }
270
- }
271
- return !1;
272
- });
273
- return {
274
- _disabled: i,
275
- _size: o,
276
- _type: m,
277
- _ref: s,
278
- _props: T,
279
- _plain: _,
280
- _round: H,
281
- _text: C,
282
- shouldAddSpace: c,
283
- handleClick: (u) => {
284
- if (i.value || t.loading) {
285
- u.stopPropagation();
286
- return;
287
- }
288
- t.nativeType === "reset" && a?.resetFields(), r("click", u);
289
- }
290
- };
291
- }, le = [
292
- "default",
293
- "primary",
294
- "success",
295
- "warning",
296
- "info",
297
- "danger",
298
- "text",
299
- ""
300
- ], fe = ["button", "submit", "reset"], U = mt({
301
- size: Ut,
302
- disabled: {
303
- type: Boolean,
304
- default: void 0
305
- },
306
- type: {
307
- type: String,
308
- values: le,
309
- default: ""
310
- },
311
- icon: {
312
- type: ot
313
- },
314
- nativeType: {
315
- type: String,
316
- values: fe,
317
- default: "button"
318
- },
319
- loading: Boolean,
320
- loadingIcon: {
321
- type: ot,
322
- default: () => oe
323
- },
324
- plain: {
325
- type: Boolean,
326
- default: void 0
327
- },
328
- text: {
329
- type: Boolean,
330
- default: void 0
331
- },
332
- link: Boolean,
333
- bg: Boolean,
334
- autofocus: Boolean,
335
- round: {
336
- type: Boolean,
337
- default: void 0
338
- },
339
- circle: Boolean,
340
- color: String,
341
- dark: Boolean,
342
- autoInsertSpace: {
343
- type: Boolean,
344
- default: void 0
345
- },
346
- tag: {
347
- type: j([String, Object]),
348
- default: "button"
349
- }
350
- }), de = {
351
- click: (t) => t instanceof MouseEvent
352
- };
353
- function p(t, r) {
354
- he(t) && (t = "100%");
355
- var e = ge(t);
356
- return t = r === 360 ? t : Math.min(r, Math.max(0, parseFloat(t))), e && (t = parseInt(String(t * r), 10) / 100), Math.abs(t - r) < 1e-6 ? 1 : (r === 360 ? t = (t < 0 ? t % r + r : t % r) / parseFloat(String(r)) : t = t % r / parseFloat(String(r)), t);
357
- }
358
- function O(t) {
359
- return Math.min(1, Math.max(0, t));
360
- }
361
- function he(t) {
362
- return typeof t == "string" && t.indexOf(".") !== -1 && parseFloat(t) === 1;
363
- }
364
- function ge(t) {
365
- return typeof t == "string" && t.indexOf("%") !== -1;
366
- }
367
- function wt(t) {
368
- return t = parseFloat(t), (isNaN(t) || t < 0 || t > 1) && (t = 1), t;
369
- }
370
- function z(t) {
371
- return t <= 1 ? "".concat(Number(t) * 100, "%") : t;
372
- }
373
- function A(t) {
374
- return t.length === 1 ? "0" + t : String(t);
375
- }
376
- function ve(t, r, e) {
377
- return {
378
- r: p(t, 255) * 255,
379
- g: p(r, 255) * 255,
380
- b: p(e, 255) * 255
381
- };
382
- }
383
- function it(t, r, e) {
384
- t = p(t, 255), r = p(r, 255), e = p(e, 255);
385
- var n = Math.max(t, r, e), a = Math.min(t, r, e), o = 0, i = 0, s = (n + a) / 2;
386
- if (n === a)
387
- i = 0, o = 0;
388
- else {
389
- var f = n - a;
390
- switch (i = s > 0.5 ? f / (2 - n - a) : f / (n + a), n) {
391
- case t:
392
- o = (r - e) / f + (r < e ? 6 : 0);
393
- break;
394
- case r:
395
- o = (e - t) / f + 2;
396
- break;
397
- case e:
398
- o = (t - r) / f + 4;
399
- break;
400
- }
401
- o /= 6;
402
- }
403
- return { h: o, s: i, l: s };
404
- }
405
- function K(t, r, e) {
406
- return e < 0 && (e += 1), e > 1 && (e -= 1), e < 1 / 6 ? t + (r - t) * (6 * e) : e < 1 / 2 ? r : e < 2 / 3 ? t + (r - t) * (2 / 3 - e) * 6 : t;
407
- }
408
- function pe(t, r, e) {
409
- var n, a, o;
410
- if (t = p(t, 360), r = p(r, 100), e = p(e, 100), r === 0)
411
- a = e, o = e, n = e;
412
- else {
413
- var i = e < 0.5 ? e * (1 + r) : e + r - e * r, s = 2 * e - i;
414
- n = K(s, i, t + 1 / 3), a = K(s, i, t), o = K(s, i, t - 1 / 3);
415
- }
416
- return { r: n * 255, g: a * 255, b: o * 255 };
417
- }
418
- function st(t, r, e) {
419
- t = p(t, 255), r = p(r, 255), e = p(e, 255);
420
- var n = Math.max(t, r, e), a = Math.min(t, r, e), o = 0, i = n, s = n - a, f = n === 0 ? 0 : s / n;
421
- if (n === a)
422
- o = 0;
423
- else {
424
- switch (n) {
425
- case t:
426
- o = (r - e) / s + (r < e ? 6 : 0);
427
- break;
428
- case r:
429
- o = (e - t) / s + 2;
430
- break;
431
- case e:
432
- o = (t - r) / s + 4;
433
- break;
434
- }
435
- o /= 6;
436
- }
437
- return { h: o, s: f, v: i };
438
- }
439
- function be(t, r, e) {
440
- t = p(t, 360) * 6, r = p(r, 100), e = p(e, 100);
441
- var n = Math.floor(t), a = t - n, o = e * (1 - r), i = e * (1 - a * r), s = e * (1 - (1 - a) * r), f = n % 6, m = [e, i, o, o, s, e][f], v = [s, e, e, i, o, o][f], _ = [o, o, s, e, e, i][f];
442
- return { r: m * 255, g: v * 255, b: _ * 255 };
443
- }
444
- function ct(t, r, e, n) {
445
- var a = [
446
- A(Math.round(t).toString(16)),
447
- A(Math.round(r).toString(16)),
448
- A(Math.round(e).toString(16))
449
- ];
450
- return n && a[0].startsWith(a[0].charAt(1)) && a[1].startsWith(a[1].charAt(1)) && a[2].startsWith(a[2].charAt(1)) ? a[0].charAt(0) + a[1].charAt(0) + a[2].charAt(0) : a.join("");
451
- }
452
- function me(t, r, e, n, a) {
453
- var o = [
454
- A(Math.round(t).toString(16)),
455
- A(Math.round(r).toString(16)),
456
- A(Math.round(e).toString(16)),
457
- A(ye(n))
458
- ];
459
- return a && o[0].startsWith(o[0].charAt(1)) && o[1].startsWith(o[1].charAt(1)) && o[2].startsWith(o[2].charAt(1)) && o[3].startsWith(o[3].charAt(1)) ? o[0].charAt(0) + o[1].charAt(0) + o[2].charAt(0) + o[3].charAt(0) : o.join("");
460
- }
461
- function ye(t) {
462
- return Math.round(parseFloat(t) * 255).toString(16);
463
- }
464
- function ut(t) {
465
- return y(t) / 255;
466
- }
467
- function y(t) {
468
- return parseInt(t, 16);
469
- }
470
- function _e(t) {
471
- return {
472
- r: t >> 16,
473
- g: (t & 65280) >> 8,
474
- b: t & 255
475
- };
476
- }
477
- var J = {
478
- aliceblue: "#f0f8ff",
479
- antiquewhite: "#faebd7",
480
- aqua: "#00ffff",
481
- aquamarine: "#7fffd4",
482
- azure: "#f0ffff",
483
- beige: "#f5f5dc",
484
- bisque: "#ffe4c4",
485
- black: "#000000",
486
- blanchedalmond: "#ffebcd",
487
- blue: "#0000ff",
488
- blueviolet: "#8a2be2",
489
- brown: "#a52a2a",
490
- burlywood: "#deb887",
491
- cadetblue: "#5f9ea0",
492
- chartreuse: "#7fff00",
493
- chocolate: "#d2691e",
494
- coral: "#ff7f50",
495
- cornflowerblue: "#6495ed",
496
- cornsilk: "#fff8dc",
497
- crimson: "#dc143c",
498
- cyan: "#00ffff",
499
- darkblue: "#00008b",
500
- darkcyan: "#008b8b",
501
- darkgoldenrod: "#b8860b",
502
- darkgray: "#a9a9a9",
503
- darkgreen: "#006400",
504
- darkgrey: "#a9a9a9",
505
- darkkhaki: "#bdb76b",
506
- darkmagenta: "#8b008b",
507
- darkolivegreen: "#556b2f",
508
- darkorange: "#ff8c00",
509
- darkorchid: "#9932cc",
510
- darkred: "#8b0000",
511
- darksalmon: "#e9967a",
512
- darkseagreen: "#8fbc8f",
513
- darkslateblue: "#483d8b",
514
- darkslategray: "#2f4f4f",
515
- darkslategrey: "#2f4f4f",
516
- darkturquoise: "#00ced1",
517
- darkviolet: "#9400d3",
518
- deeppink: "#ff1493",
519
- deepskyblue: "#00bfff",
520
- dimgray: "#696969",
521
- dimgrey: "#696969",
522
- dodgerblue: "#1e90ff",
523
- firebrick: "#b22222",
524
- floralwhite: "#fffaf0",
525
- forestgreen: "#228b22",
526
- fuchsia: "#ff00ff",
527
- gainsboro: "#dcdcdc",
528
- ghostwhite: "#f8f8ff",
529
- goldenrod: "#daa520",
530
- gold: "#ffd700",
531
- gray: "#808080",
532
- green: "#008000",
533
- greenyellow: "#adff2f",
534
- grey: "#808080",
535
- honeydew: "#f0fff0",
536
- hotpink: "#ff69b4",
537
- indianred: "#cd5c5c",
538
- indigo: "#4b0082",
539
- ivory: "#fffff0",
540
- khaki: "#f0e68c",
541
- lavenderblush: "#fff0f5",
542
- lavender: "#e6e6fa",
543
- lawngreen: "#7cfc00",
544
- lemonchiffon: "#fffacd",
545
- lightblue: "#add8e6",
546
- lightcoral: "#f08080",
547
- lightcyan: "#e0ffff",
548
- lightgoldenrodyellow: "#fafad2",
549
- lightgray: "#d3d3d3",
550
- lightgreen: "#90ee90",
551
- lightgrey: "#d3d3d3",
552
- lightpink: "#ffb6c1",
553
- lightsalmon: "#ffa07a",
554
- lightseagreen: "#20b2aa",
555
- lightskyblue: "#87cefa",
556
- lightslategray: "#778899",
557
- lightslategrey: "#778899",
558
- lightsteelblue: "#b0c4de",
559
- lightyellow: "#ffffe0",
560
- lime: "#00ff00",
561
- limegreen: "#32cd32",
562
- linen: "#faf0e6",
563
- magenta: "#ff00ff",
564
- maroon: "#800000",
565
- mediumaquamarine: "#66cdaa",
566
- mediumblue: "#0000cd",
567
- mediumorchid: "#ba55d3",
568
- mediumpurple: "#9370db",
569
- mediumseagreen: "#3cb371",
570
- mediumslateblue: "#7b68ee",
571
- mediumspringgreen: "#00fa9a",
572
- mediumturquoise: "#48d1cc",
573
- mediumvioletred: "#c71585",
574
- midnightblue: "#191970",
575
- mintcream: "#f5fffa",
576
- mistyrose: "#ffe4e1",
577
- moccasin: "#ffe4b5",
578
- navajowhite: "#ffdead",
579
- navy: "#000080",
580
- oldlace: "#fdf5e6",
581
- olive: "#808000",
582
- olivedrab: "#6b8e23",
583
- orange: "#ffa500",
584
- orangered: "#ff4500",
585
- orchid: "#da70d6",
586
- palegoldenrod: "#eee8aa",
587
- palegreen: "#98fb98",
588
- paleturquoise: "#afeeee",
589
- palevioletred: "#db7093",
590
- papayawhip: "#ffefd5",
591
- peachpuff: "#ffdab9",
592
- peru: "#cd853f",
593
- pink: "#ffc0cb",
594
- plum: "#dda0dd",
595
- powderblue: "#b0e0e6",
596
- purple: "#800080",
597
- rebeccapurple: "#663399",
598
- red: "#ff0000",
599
- rosybrown: "#bc8f8f",
600
- royalblue: "#4169e1",
601
- saddlebrown: "#8b4513",
602
- salmon: "#fa8072",
603
- sandybrown: "#f4a460",
604
- seagreen: "#2e8b57",
605
- seashell: "#fff5ee",
606
- sienna: "#a0522d",
607
- silver: "#c0c0c0",
608
- skyblue: "#87ceeb",
609
- slateblue: "#6a5acd",
610
- slategray: "#708090",
611
- slategrey: "#708090",
612
- snow: "#fffafa",
613
- springgreen: "#00ff7f",
614
- steelblue: "#4682b4",
615
- tan: "#d2b48c",
616
- teal: "#008080",
617
- thistle: "#d8bfd8",
618
- tomato: "#ff6347",
619
- turquoise: "#40e0d0",
620
- violet: "#ee82ee",
621
- wheat: "#f5deb3",
622
- white: "#ffffff",
623
- whitesmoke: "#f5f5f5",
624
- yellow: "#ffff00",
625
- yellowgreen: "#9acd32"
626
- };
627
- function Se(t) {
628
- var r = { r: 0, g: 0, b: 0 }, e = 1, n = null, a = null, o = null, i = !1, s = !1;
629
- return typeof t == "string" && (t = we(t)), typeof t == "object" && (k(t.r) && k(t.g) && k(t.b) ? (r = ve(t.r, t.g, t.b), i = !0, s = String(t.r).substr(-1) === "%" ? "prgb" : "rgb") : k(t.h) && k(t.s) && k(t.v) ? (n = z(t.s), a = z(t.v), r = be(t.h, n, a), i = !0, s = "hsv") : k(t.h) && k(t.s) && k(t.l) && (n = z(t.s), o = z(t.l), r = pe(t.h, n, o), i = !0, s = "hsl"), Object.prototype.hasOwnProperty.call(t, "a") && (e = t.a)), e = wt(e), {
630
- ok: i,
631
- format: t.format || s,
632
- r: Math.min(255, Math.max(r.r, 0)),
633
- g: Math.min(255, Math.max(r.g, 0)),
634
- b: Math.min(255, Math.max(r.b, 0)),
635
- a: e
636
- };
637
- }
638
- var xe = "[-\\+]?\\d+%?", ke = "[-\\+]?\\d*\\.\\d+%?", $ = "(?:".concat(ke, ")|(?:").concat(xe, ")"), L = "[\\s|\\(]+(".concat($, ")[,|\\s]+(").concat($, ")[,|\\s]+(").concat($, ")\\s*\\)?"), q = "[\\s|\\(]+(".concat($, ")[,|\\s]+(").concat($, ")[,|\\s]+(").concat($, ")[,|\\s]+(").concat($, ")\\s*\\)?"), x = {
639
- CSS_UNIT: new RegExp($),
640
- rgb: new RegExp("rgb" + L),
641
- rgba: new RegExp("rgba" + q),
642
- hsl: new RegExp("hsl" + L),
643
- hsla: new RegExp("hsla" + q),
644
- hsv: new RegExp("hsv" + L),
645
- hsva: new RegExp("hsva" + q),
646
- hex3: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,
647
- hex6: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,
648
- hex4: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,
649
- hex8: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/
650
- };
651
- function we(t) {
652
- if (t = t.trim().toLowerCase(), t.length === 0)
653
- return !1;
654
- var r = !1;
655
- if (J[t])
656
- t = J[t], r = !0;
657
- else if (t === "transparent")
658
- return { r: 0, g: 0, b: 0, a: 0, format: "name" };
659
- var e = x.rgb.exec(t);
660
- return e ? { r: e[1], g: e[2], b: e[3] } : (e = x.rgba.exec(t), e ? { r: e[1], g: e[2], b: e[3], a: e[4] } : (e = x.hsl.exec(t), e ? { h: e[1], s: e[2], l: e[3] } : (e = x.hsla.exec(t), e ? { h: e[1], s: e[2], l: e[3], a: e[4] } : (e = x.hsv.exec(t), e ? { h: e[1], s: e[2], v: e[3] } : (e = x.hsva.exec(t), e ? { h: e[1], s: e[2], v: e[3], a: e[4] } : (e = x.hex8.exec(t), e ? {
661
- r: y(e[1]),
662
- g: y(e[2]),
663
- b: y(e[3]),
664
- a: ut(e[4]),
665
- format: r ? "name" : "hex8"
666
- } : (e = x.hex6.exec(t), e ? {
667
- r: y(e[1]),
668
- g: y(e[2]),
669
- b: y(e[3]),
670
- format: r ? "name" : "hex"
671
- } : (e = x.hex4.exec(t), e ? {
672
- r: y(e[1] + e[1]),
673
- g: y(e[2] + e[2]),
674
- b: y(e[3] + e[3]),
675
- a: ut(e[4] + e[4]),
676
- format: r ? "name" : "hex8"
677
- } : (e = x.hex3.exec(t), e ? {
678
- r: y(e[1] + e[1]),
679
- g: y(e[2] + e[2]),
680
- b: y(e[3] + e[3]),
681
- format: r ? "name" : "hex"
682
- } : !1)))))))));
683
- }
684
- function k(t) {
685
- return !!x.CSS_UNIT.exec(String(t));
686
- }
687
- var Me = (
688
- /** @class */
689
- (function() {
690
- function t(r, e) {
691
- r === void 0 && (r = ""), e === void 0 && (e = {});
692
- var n;
693
- if (r instanceof t)
694
- return r;
695
- typeof r == "number" && (r = _e(r)), this.originalInput = r;
696
- var a = Se(r);
697
- this.originalInput = r, this.r = a.r, this.g = a.g, this.b = a.b, this.a = a.a, this.roundA = Math.round(100 * this.a) / 100, this.format = (n = e.format) !== null && n !== void 0 ? n : a.format, this.gradientType = e.gradientType, this.r < 1 && (this.r = Math.round(this.r)), this.g < 1 && (this.g = Math.round(this.g)), this.b < 1 && (this.b = Math.round(this.b)), this.isValid = a.ok;
698
- }
699
- return t.prototype.isDark = function() {
700
- return this.getBrightness() < 128;
701
- }, t.prototype.isLight = function() {
702
- return !this.isDark();
703
- }, t.prototype.getBrightness = function() {
704
- var r = this.toRgb();
705
- return (r.r * 299 + r.g * 587 + r.b * 114) / 1e3;
706
- }, t.prototype.getLuminance = function() {
707
- var r = this.toRgb(), e, n, a, o = r.r / 255, i = r.g / 255, s = r.b / 255;
708
- return o <= 0.03928 ? e = o / 12.92 : e = Math.pow((o + 0.055) / 1.055, 2.4), i <= 0.03928 ? n = i / 12.92 : n = Math.pow((i + 0.055) / 1.055, 2.4), s <= 0.03928 ? a = s / 12.92 : a = Math.pow((s + 0.055) / 1.055, 2.4), 0.2126 * e + 0.7152 * n + 0.0722 * a;
709
- }, t.prototype.getAlpha = function() {
710
- return this.a;
711
- }, t.prototype.setAlpha = function(r) {
712
- return this.a = wt(r), this.roundA = Math.round(100 * this.a) / 100, this;
713
- }, t.prototype.isMonochrome = function() {
714
- var r = this.toHsl().s;
715
- return r === 0;
716
- }, t.prototype.toHsv = function() {
717
- var r = st(this.r, this.g, this.b);
718
- return { h: r.h * 360, s: r.s, v: r.v, a: this.a };
719
- }, t.prototype.toHsvString = function() {
720
- var r = st(this.r, this.g, this.b), e = Math.round(r.h * 360), n = Math.round(r.s * 100), a = Math.round(r.v * 100);
721
- return this.a === 1 ? "hsv(".concat(e, ", ").concat(n, "%, ").concat(a, "%)") : "hsva(".concat(e, ", ").concat(n, "%, ").concat(a, "%, ").concat(this.roundA, ")");
722
- }, t.prototype.toHsl = function() {
723
- var r = it(this.r, this.g, this.b);
724
- return { h: r.h * 360, s: r.s, l: r.l, a: this.a };
725
- }, t.prototype.toHslString = function() {
726
- var r = it(this.r, this.g, this.b), e = Math.round(r.h * 360), n = Math.round(r.s * 100), a = Math.round(r.l * 100);
727
- return this.a === 1 ? "hsl(".concat(e, ", ").concat(n, "%, ").concat(a, "%)") : "hsla(".concat(e, ", ").concat(n, "%, ").concat(a, "%, ").concat(this.roundA, ")");
728
- }, t.prototype.toHex = function(r) {
729
- return r === void 0 && (r = !1), ct(this.r, this.g, this.b, r);
730
- }, t.prototype.toHexString = function(r) {
731
- return r === void 0 && (r = !1), "#" + this.toHex(r);
732
- }, t.prototype.toHex8 = function(r) {
733
- return r === void 0 && (r = !1), me(this.r, this.g, this.b, this.a, r);
734
- }, t.prototype.toHex8String = function(r) {
735
- return r === void 0 && (r = !1), "#" + this.toHex8(r);
736
- }, t.prototype.toHexShortString = function(r) {
737
- return r === void 0 && (r = !1), this.a === 1 ? this.toHexString(r) : this.toHex8String(r);
738
- }, t.prototype.toRgb = function() {
739
- return {
740
- r: Math.round(this.r),
741
- g: Math.round(this.g),
742
- b: Math.round(this.b),
743
- a: this.a
744
- };
745
- }, t.prototype.toRgbString = function() {
746
- var r = Math.round(this.r), e = Math.round(this.g), n = Math.round(this.b);
747
- return this.a === 1 ? "rgb(".concat(r, ", ").concat(e, ", ").concat(n, ")") : "rgba(".concat(r, ", ").concat(e, ", ").concat(n, ", ").concat(this.roundA, ")");
748
- }, t.prototype.toPercentageRgb = function() {
749
- var r = function(e) {
750
- return "".concat(Math.round(p(e, 255) * 100), "%");
751
- };
752
- return {
753
- r: r(this.r),
754
- g: r(this.g),
755
- b: r(this.b),
756
- a: this.a
757
- };
758
- }, t.prototype.toPercentageRgbString = function() {
759
- var r = function(e) {
760
- return Math.round(p(e, 255) * 100);
761
- };
762
- return this.a === 1 ? "rgb(".concat(r(this.r), "%, ").concat(r(this.g), "%, ").concat(r(this.b), "%)") : "rgba(".concat(r(this.r), "%, ").concat(r(this.g), "%, ").concat(r(this.b), "%, ").concat(this.roundA, ")");
763
- }, t.prototype.toName = function() {
764
- if (this.a === 0)
765
- return "transparent";
766
- if (this.a < 1)
767
- return !1;
768
- for (var r = "#" + ct(this.r, this.g, this.b, !1), e = 0, n = Object.entries(J); e < n.length; e++) {
769
- var a = n[e], o = a[0], i = a[1];
770
- if (r === i)
771
- return o;
772
- }
773
- return !1;
774
- }, t.prototype.toString = function(r) {
775
- var e = !!r;
776
- r = r ?? this.format;
777
- var n = !1, a = this.a < 1 && this.a >= 0, o = !e && a && (r.startsWith("hex") || r === "name");
778
- return o ? r === "name" && this.a === 0 ? this.toName() : this.toRgbString() : (r === "rgb" && (n = this.toRgbString()), r === "prgb" && (n = this.toPercentageRgbString()), (r === "hex" || r === "hex6") && (n = this.toHexString()), r === "hex3" && (n = this.toHexString(!0)), r === "hex4" && (n = this.toHex8String(!0)), r === "hex8" && (n = this.toHex8String()), r === "name" && (n = this.toName()), r === "hsl" && (n = this.toHslString()), r === "hsv" && (n = this.toHsvString()), n || this.toHexString());
779
- }, t.prototype.toNumber = function() {
780
- return (Math.round(this.r) << 16) + (Math.round(this.g) << 8) + Math.round(this.b);
781
- }, t.prototype.clone = function() {
782
- return new t(this.toString());
783
- }, t.prototype.lighten = function(r) {
784
- r === void 0 && (r = 10);
785
- var e = this.toHsl();
786
- return e.l += r / 100, e.l = O(e.l), new t(e);
787
- }, t.prototype.brighten = function(r) {
788
- r === void 0 && (r = 10);
789
- var e = this.toRgb();
790
- return e.r = Math.max(0, Math.min(255, e.r - Math.round(255 * -(r / 100)))), e.g = Math.max(0, Math.min(255, e.g - Math.round(255 * -(r / 100)))), e.b = Math.max(0, Math.min(255, e.b - Math.round(255 * -(r / 100)))), new t(e);
791
- }, t.prototype.darken = function(r) {
792
- r === void 0 && (r = 10);
793
- var e = this.toHsl();
794
- return e.l -= r / 100, e.l = O(e.l), new t(e);
795
- }, t.prototype.tint = function(r) {
796
- return r === void 0 && (r = 10), this.mix("white", r);
797
- }, t.prototype.shade = function(r) {
798
- return r === void 0 && (r = 10), this.mix("black", r);
799
- }, t.prototype.desaturate = function(r) {
800
- r === void 0 && (r = 10);
801
- var e = this.toHsl();
802
- return e.s -= r / 100, e.s = O(e.s), new t(e);
803
- }, t.prototype.saturate = function(r) {
804
- r === void 0 && (r = 10);
805
- var e = this.toHsl();
806
- return e.s += r / 100, e.s = O(e.s), new t(e);
807
- }, t.prototype.greyscale = function() {
808
- return this.desaturate(100);
809
- }, t.prototype.spin = function(r) {
810
- var e = this.toHsl(), n = (e.h + r) % 360;
811
- return e.h = n < 0 ? 360 + n : n, new t(e);
812
- }, t.prototype.mix = function(r, e) {
813
- e === void 0 && (e = 50);
814
- var n = this.toRgb(), a = new t(r).toRgb(), o = e / 100, i = {
815
- r: (a.r - n.r) * o + n.r,
816
- g: (a.g - n.g) * o + n.g,
817
- b: (a.b - n.b) * o + n.b,
818
- a: (a.a - n.a) * o + n.a
819
- };
820
- return new t(i);
821
- }, t.prototype.analogous = function(r, e) {
822
- r === void 0 && (r = 6), e === void 0 && (e = 30);
823
- var n = this.toHsl(), a = 360 / e, o = [this];
824
- for (n.h = (n.h - (a * r >> 1) + 720) % 360; --r; )
825
- n.h = (n.h + a) % 360, o.push(new t(n));
826
- return o;
827
- }, t.prototype.complement = function() {
828
- var r = this.toHsl();
829
- return r.h = (r.h + 180) % 360, new t(r);
830
- }, t.prototype.monochromatic = function(r) {
831
- r === void 0 && (r = 6);
832
- for (var e = this.toHsv(), n = e.h, a = e.s, o = e.v, i = [], s = 1 / r; r--; )
833
- i.push(new t({ h: n, s: a, v: o })), o = (o + s) % 1;
834
- return i;
835
- }, t.prototype.splitcomplement = function() {
836
- var r = this.toHsl(), e = r.h;
837
- return [
838
- this,
839
- new t({ h: (e + 72) % 360, s: r.s, l: r.l }),
840
- new t({ h: (e + 216) % 360, s: r.s, l: r.l })
841
- ];
842
- }, t.prototype.onBackground = function(r) {
843
- var e = this.toRgb(), n = new t(r).toRgb(), a = e.a + n.a * (1 - e.a);
844
- return new t({
845
- r: (e.r * e.a + n.r * n.a * (1 - e.a)) / a,
846
- g: (e.g * e.a + n.g * n.a * (1 - e.a)) / a,
847
- b: (e.b * e.a + n.b * n.a * (1 - e.a)) / a,
848
- a
849
- });
850
- }, t.prototype.triad = function() {
851
- return this.polyad(3);
852
- }, t.prototype.tetrad = function() {
853
- return this.polyad(4);
854
- }, t.prototype.polyad = function(r) {
855
- for (var e = this.toHsl(), n = e.h, a = [this], o = 360 / r, i = 1; i < r; i++)
856
- a.push(new t({ h: (n + i * o) % 360, s: e.s, l: e.l }));
857
- return a;
858
- }, t.prototype.equals = function(r) {
859
- return this.toRgbString() === new t(r).toRgbString();
860
- }, t;
861
- })()
862
- );
863
- function M(t, r = 20) {
864
- return t.mix("#141414", r).toString();
865
- }
866
- function $e(t) {
867
- const r = xt(), e = F("button");
868
- return h(() => {
869
- let n = {}, a = t.color;
870
- if (a) {
871
- const o = a.match(/var\((.*?)\)/);
872
- o && (a = window.getComputedStyle(window.document.documentElement).getPropertyValue(o[1]));
873
- const i = new Me(a), s = t.dark ? i.tint(20).toString() : M(i, 20);
874
- if (t.plain)
875
- n = e.cssVarBlock({
876
- "bg-color": t.dark ? M(i, 90) : i.tint(90).toString(),
877
- "text-color": a,
878
- "border-color": t.dark ? M(i, 50) : i.tint(50).toString(),
879
- "hover-text-color": `var(${e.cssVarName("color-white")})`,
880
- "hover-bg-color": a,
881
- "hover-border-color": a,
882
- "active-bg-color": s,
883
- "active-text-color": `var(${e.cssVarName("color-white")})`,
884
- "active-border-color": s
885
- }), r.value && (n[e.cssVarBlockName("disabled-bg-color")] = t.dark ? M(i, 90) : i.tint(90).toString(), n[e.cssVarBlockName("disabled-text-color")] = t.dark ? M(i, 50) : i.tint(50).toString(), n[e.cssVarBlockName("disabled-border-color")] = t.dark ? M(i, 80) : i.tint(80).toString());
886
- else {
887
- const f = t.dark ? M(i, 30) : i.tint(30).toString(), m = i.isDark() ? `var(${e.cssVarName("color-white")})` : `var(${e.cssVarName("color-black")})`;
888
- if (n = e.cssVarBlock({
889
- "bg-color": a,
890
- "text-color": m,
891
- "border-color": a,
892
- "hover-bg-color": f,
893
- "hover-text-color": m,
894
- "hover-border-color": f,
895
- "active-bg-color": s,
896
- "active-border-color": s
897
- }), r.value) {
898
- const v = t.dark ? M(i, 50) : i.tint(50).toString();
899
- n[e.cssVarBlockName("disabled-bg-color")] = v, n[e.cssVarBlockName("disabled-text-color")] = t.dark ? "rgba(255, 255, 255, 0.5)" : `var(${e.cssVarName("color-white")})`, n[e.cssVarBlockName("disabled-border-color")] = v;
900
- }
901
- }
902
- }
903
- return n;
904
- });
905
- }
906
- const Ne = I({
907
- name: "ElButton",
908
- __name: "button",
909
- props: U,
910
- emits: de,
911
- setup(t, { expose: r, emit: e }) {
912
- const n = t, a = e, o = $e(n), i = F("button"), {
913
- _ref: s,
914
- _size: f,
915
- _type: m,
916
- _disabled: v,
917
- _props: _,
918
- _plain: H,
919
- _round: C,
920
- _text: T,
921
- shouldAddSpace: c,
922
- handleClick: d
923
- } = ue(n, a), u = h(() => [
924
- i.b(),
925
- i.m(m.value),
926
- i.m(f.value),
927
- i.is("disabled", v.value),
928
- i.is("loading", n.loading),
929
- i.is("plain", H.value),
930
- i.is("round", C.value),
931
- i.is("circle", n.circle),
932
- i.is("text", T.value),
933
- i.is("link", n.link),
934
- i.is("has-bg", n.bg)
935
- ]);
936
- return r({
937
- ref: s,
938
- size: f,
939
- type: m,
940
- disabled: v,
941
- shouldAddSpace: c
942
- }), (l, b) => (S(), B(G(l.tag), lt({
943
- ref_key: "_ref",
944
- ref: s
945
- }, g(_), {
946
- class: u.value,
947
- style: g(o),
948
- onClick: g(d)
949
- }), {
950
- default: V(() => [
951
- l.loading ? (S(), P(
952
- It,
953
- { key: 0 },
954
- [
955
- l.$slots.loading ? R(l.$slots, "loading", { key: 0 }) : (S(), B(g(at), {
956
- key: 1,
957
- class: W(g(i).is("loading"))
958
- }, {
959
- default: V(() => [
960
- (S(), B(G(l.loadingIcon)))
961
- ]),
962
- _: 1
963
- }, 8, ["class"]))
964
- ],
965
- 64
966
- )) : l.icon || l.$slots.icon ? (S(), B(g(at), { key: 1 }, {
967
- default: V(() => [
968
- l.icon ? (S(), B(G(l.icon), { key: 0 })) : R(l.$slots, "icon", { key: 1 })
969
- ]),
970
- _: 3
971
- })) : tt("v-if", !0),
972
- l.$slots.default ? (S(), P(
973
- "span",
974
- {
975
- key: 2,
976
- class: W({ [g(i).em("text", "expand")]: g(c) })
977
- },
978
- [
979
- R(l.$slots, "default")
980
- ],
981
- 2
982
- )) : tt("v-if", !0)
983
- ]),
984
- _: 3
985
- }, 16, ["class", "style", "onClick"]));
986
- }
987
- });
988
- var Be = /* @__PURE__ */ Q(Ne, [["__file", "/home/runner/work/element-plus/element-plus/packages/components/button/src/button.vue"]]);
989
- const Ae = {
990
- size: U.size,
991
- type: U.type,
992
- direction: {
993
- type: j(String),
994
- values: ["horizontal", "vertical"],
995
- default: "horizontal"
996
- }
997
- }, Ee = I({
998
- name: "ElButtonGroup",
999
- __name: "button-group",
1000
- props: Ae,
1001
- setup(t) {
1002
- const r = t;
1003
- Rt(
1004
- kt,
1005
- Vt({
1006
- size: et(r, "size"),
1007
- type: et(r, "type")
1008
- })
1009
- );
1010
- const e = F("button");
1011
- return (n, a) => (S(), P(
1012
- "div",
1013
- {
1014
- class: W([g(e).b("group"), g(e).bm("group", r.direction)])
1015
- },
1016
- [
1017
- R(n.$slots, "default")
1018
- ],
1019
- 2
1020
- ));
1021
- }
1022
- });
1023
- var Mt = /* @__PURE__ */ Q(Ee, [["__file", "/home/runner/work/element-plus/element-plus/packages/components/button/src/button-group.vue"]]);
1024
- const $t = yt(Be, {
1025
- ButtonGroup: Mt
1026
- });
1027
- Qt(Mt);
1028
- const Ie = /* @__PURE__ */ I({
1029
- __name: "TestComp",
1030
- setup(t) {
1031
- const r = E(0);
1032
- function e() {
1033
- r.value = r.value + 1, ht({
1034
- message: `第次${r.value}点击!`,
1035
- type: "success"
1036
- });
1037
- }
1038
- return (n, a) => {
1039
- const o = $t;
1040
- return S(), B(o, { onClick: e }, {
1041
- default: V(() => [
1042
- ft(dt(g(r)), 1)
1043
- ]),
1044
- _: 1
1045
- });
1046
- };
1047
- }
1048
- }), Re = /* @__PURE__ */ I({
1049
- __name: "BtnComp",
1050
- setup(t) {
1051
- const r = E(0);
1052
- function e() {
1053
- r.value = r.value + 100, ht({
1054
- message: `第次${r.value / 100}点击!`,
1055
- type: "warning"
1056
- });
1057
- }
1058
- return (n, a) => {
1059
- const o = $t;
1060
- return S(), B(o, { onClick: e }, {
1061
- default: V(() => [
1062
- ft(dt(g(r)), 1)
1063
- ]),
1064
- _: 1
1065
- });
1066
- };
1067
- }
1068
- });
1069
- export {
1070
- Ie as BtnComp1,
1071
- Re as BtnComp100
1072
- };