@eturnity/eturnity_reusable_components 8.37.1-dev-03-elisee-8.37.3 → 8.40.0
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/dist/main.es12.js +2 -2
- package/dist/main.es13.js +5 -5
- package/dist/main.es14.js +2 -2
- package/dist/main.es15.js +248 -62
- package/dist/main.es17.js +62 -22
- package/dist/main.es18.js +19 -1051
- package/dist/main.es19.js +1044 -215
- package/dist/main.es20.js +196 -68
- package/dist/main.es21.js +72 -73
- package/dist/main.es22.js +74 -168
- package/dist/main.es23.js +194 -2
- package/dist/main.es24.js +2 -541
- package/dist/main.es25.js +532 -15
- package/dist/main.es26.js +19 -245
- package/dist/main.es383.js +1 -1
- package/dist/main.es386.js +1 -1
- package/dist/main.es5.js +1 -1
- package/dist/main.es6.js +2 -2
- package/dist/main.es742.js +21 -60
- package/dist/main.es743.js +60 -21
- package/dist/main.es9.js +4 -4
- package/package.json +1 -1
- package/src/components/buttons/buttonIcon/index.vue +12 -4
- package/src/components/buttons/mainButton/index.vue +0 -14
- package/src/components/inputs/checkbox/index.vue +1 -1
- package/src/components/inputs/inputText/index.vue +4 -1
- package/src/components/inputs/radioButton/index.vue +69 -94
- package/src/components/inputs/select/index.vue +1 -16
- package/src/components/inputs/textAreaInput/index.vue +0 -8
- package/src/components/spinner/index.vue +0 -2
- package/src/components/tag/conversionTag/index.vue +3 -3
package/dist/main.es26.js
CHANGED
|
@@ -1,252 +1,26 @@
|
|
|
1
|
-
import "./main.es3.js";
|
|
2
1
|
import styled from "./main.es7.js";
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import {
|
|
6
|
-
|
|
7
|
-
const _hoisted_1 = ["innerHTML"];
|
|
8
|
-
const _sfc_main = {
|
|
9
|
-
__name: "index",
|
|
10
|
-
props: {
|
|
11
|
-
disabled: {
|
|
12
|
-
required: false,
|
|
13
|
-
default: false,
|
|
14
|
-
type: Boolean
|
|
15
|
-
},
|
|
16
|
-
name: {
|
|
17
|
-
required: true,
|
|
18
|
-
type: String
|
|
19
|
-
},
|
|
20
|
-
color: {
|
|
21
|
-
required: false,
|
|
22
|
-
default: null,
|
|
23
|
-
type: String
|
|
24
|
-
},
|
|
25
|
-
hoveredColor: {
|
|
26
|
-
required: false,
|
|
27
|
-
default: null,
|
|
28
|
-
type: String
|
|
29
|
-
},
|
|
30
|
-
size: {
|
|
31
|
-
required: false,
|
|
32
|
-
default: "30px",
|
|
33
|
-
type: String
|
|
34
|
-
},
|
|
35
|
-
width: {
|
|
36
|
-
type: String,
|
|
37
|
-
required: false,
|
|
38
|
-
default: ""
|
|
39
|
-
},
|
|
40
|
-
height: {
|
|
41
|
-
type: String,
|
|
42
|
-
required: false,
|
|
43
|
-
default: ""
|
|
44
|
-
},
|
|
45
|
-
cursor: {
|
|
46
|
-
required: false,
|
|
47
|
-
default: null,
|
|
48
|
-
type: String
|
|
49
|
-
},
|
|
50
|
-
isStriked: {
|
|
51
|
-
required: false,
|
|
52
|
-
default: false,
|
|
53
|
-
type: Boolean
|
|
54
|
-
},
|
|
55
|
-
backgroundColor: {
|
|
56
|
-
required: false,
|
|
57
|
-
default: null,
|
|
58
|
-
type: String
|
|
59
|
-
},
|
|
60
|
-
count: {
|
|
61
|
-
required: false,
|
|
62
|
-
default: 0,
|
|
63
|
-
type: Number
|
|
64
|
-
},
|
|
65
|
-
animation: {
|
|
66
|
-
required: false,
|
|
67
|
-
default: "none",
|
|
68
|
-
type: String
|
|
69
|
-
},
|
|
70
|
-
fillType: {
|
|
71
|
-
required: false,
|
|
72
|
-
default: "fill",
|
|
73
|
-
type: String
|
|
74
|
-
},
|
|
75
|
-
disableHover: {
|
|
76
|
-
type: Boolean,
|
|
77
|
-
default: false
|
|
78
|
-
},
|
|
79
|
-
showCount: {
|
|
80
|
-
type: Boolean,
|
|
81
|
-
default: false
|
|
82
|
-
}
|
|
83
|
-
},
|
|
84
|
-
setup(__props) {
|
|
85
|
-
const props = __props;
|
|
86
|
-
const Wrapper = styled("div", {
|
|
87
|
-
height: String,
|
|
88
|
-
width: String,
|
|
89
|
-
disabled: Boolean,
|
|
90
|
-
cursor: String
|
|
91
|
-
})`
|
|
92
|
-
display: flex;
|
|
93
|
-
position: relative;
|
|
94
|
-
align-content: center;
|
|
95
|
-
justify-content: center;
|
|
96
|
-
width: ${(props2) => props2.width};
|
|
97
|
-
height: ${(props2) => props2.height};
|
|
98
|
-
min-width: ${(props2) => props2.width};
|
|
99
|
-
min-height: ${(props2) => props2.height};
|
|
100
|
-
cursor: ${(props2) => props2.disabled ? "not-allowed" : props2.cursor};
|
|
101
|
-
line-height: 0;
|
|
102
|
-
`;
|
|
103
|
-
const CountWrapper = styled("div")`
|
|
104
|
-
position: absolute;
|
|
105
|
-
top: -7px;
|
|
106
|
-
right: -7px;
|
|
107
|
-
background-color: ${({
|
|
108
|
-
theme
|
|
109
|
-
}) => theme.colors.red};
|
|
2
|
+
import "./main.es3.js";
|
|
3
|
+
import _export_sfc from "./main.es11.js";
|
|
4
|
+
import { resolveComponent, openBlock, createBlock, withCtx, createTextVNode } from "./main.es6.js";
|
|
5
|
+
const StarElement = styled.span`
|
|
110
6
|
color: ${({
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
border-radius: 100%;
|
|
114
|
-
width: 15px;
|
|
115
|
-
height: 15px;
|
|
116
|
-
display: flex;
|
|
117
|
-
justify-content: center;
|
|
118
|
-
align-items: center;
|
|
119
|
-
font-size: 10px;
|
|
7
|
+
theme
|
|
8
|
+
}) => theme.colors.red};
|
|
120
9
|
`;
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
position: absolute;
|
|
126
|
-
bottom: 0;
|
|
127
|
-
left: 0;
|
|
128
|
-
align-content: center;
|
|
129
|
-
justify-content: center;
|
|
130
|
-
width: 143%;
|
|
131
|
-
height: 8%;
|
|
132
|
-
background-color: ${({
|
|
133
|
-
theme,
|
|
134
|
-
color
|
|
135
|
-
}) => theme.colors[color] || color};
|
|
136
|
-
min-height: 0;
|
|
137
|
-
line-height: 0;
|
|
138
|
-
transform-origin: 0% 100%;
|
|
139
|
-
transform: rotate(-45deg);
|
|
140
|
-
`;
|
|
141
|
-
const IconImageAttrs = {
|
|
142
|
-
color: String,
|
|
143
|
-
backgroundColor: String,
|
|
144
|
-
hoveredColor: String,
|
|
145
|
-
animation: String,
|
|
146
|
-
fillType: String,
|
|
147
|
-
disableHover: Boolean,
|
|
148
|
-
showCount: Boolean
|
|
149
|
-
};
|
|
150
|
-
const IconImage = styled("div", IconImageAttrs)`
|
|
151
|
-
animation: ${(props2) => props2.animation};
|
|
152
|
-
width: 100%;
|
|
153
|
-
svg {
|
|
154
|
-
width: 100%;
|
|
155
|
-
height: 100%;
|
|
156
|
-
background-color: ${(props2) => props2.backgroundColor ? props2.backgroundColor : "transparent"};
|
|
157
|
-
padding: ${(props2) => props2.backgroundColor ? "3px" : "0"};
|
|
158
|
-
border-radius: ${(props2) => props2.showCount ? "8px 0 0 8px" : props2.backgroundColor ? "8px" : "0"};
|
|
159
|
-
}
|
|
160
|
-
svg path:not(.fix, .isStrokePath) {
|
|
161
|
-
${({
|
|
162
|
-
theme,
|
|
163
|
-
color,
|
|
164
|
-
fillType
|
|
165
|
-
}) => color && `${fillType}: ${theme.colors[color] || color};`}
|
|
166
|
-
}
|
|
167
|
-
svg .isStroke {
|
|
168
|
-
${({
|
|
169
|
-
theme,
|
|
170
|
-
color
|
|
171
|
-
}) => color && `stroke: ${theme.colors[color] || color};`}
|
|
172
|
-
}
|
|
173
|
-
svg .isFill {
|
|
174
|
-
${({
|
|
175
|
-
theme,
|
|
176
|
-
color
|
|
177
|
-
}) => color && `fill: ${theme.colors[color] || color};`}
|
|
178
|
-
}
|
|
179
|
-
svg .isStrokePath:not(.fix) {
|
|
180
|
-
${({
|
|
181
|
-
theme,
|
|
182
|
-
color
|
|
183
|
-
}) => color && `stroke: ${theme.colors[color] || color};`}
|
|
184
|
-
}
|
|
185
|
-
${(props2) => !props2.disableHover && `
|
|
186
|
-
&:hover svg path:not(.fix, .isStrokePath) {
|
|
187
|
-
${`${props2.fillType}: ${props2.theme.colors[props2.hoveredColor] || props2.color};`}
|
|
188
|
-
&:hover svg isStrokePath:not(.fix) {
|
|
189
|
-
${`stroke: ${props2.theme.colors[props2.hoveredColor] || props2.color};`}
|
|
190
|
-
}
|
|
191
|
-
&:hover + div {
|
|
192
|
-
background-color: ${props2.hoveredColor};
|
|
193
|
-
}
|
|
194
|
-
`}
|
|
195
|
-
|
|
196
|
-
@keyframes fade {
|
|
197
|
-
50% {
|
|
198
|
-
opacity: 0.3;
|
|
199
|
-
}
|
|
200
|
-
}
|
|
201
|
-
`;
|
|
202
|
-
const icon = reactive({
|
|
203
|
-
html: ""
|
|
204
|
-
});
|
|
205
|
-
const loadSvg = async () => {
|
|
206
|
-
icon.html = await fetchIcon(props.name.toLowerCase());
|
|
207
|
-
};
|
|
208
|
-
const counter = computed(() => props.count > 9 ? "9+" : props.count.toString());
|
|
209
|
-
onMounted(() => loadSvg());
|
|
210
|
-
watch(() => props.name, loadSvg);
|
|
211
|
-
return (_ctx, _cache) => {
|
|
212
|
-
return openBlock(), createBlock(Wrapper, {
|
|
213
|
-
cursor: __props.cursor,
|
|
214
|
-
"data-test-id": "icon_wrapper",
|
|
215
|
-
disabled: __props.disabled,
|
|
216
|
-
height: __props.height ? __props.height : __props.size,
|
|
217
|
-
width: __props.width ? __props.width : __props.size
|
|
218
|
-
}, {
|
|
219
|
-
default: withCtx(() => [createVNode(IconImage, {
|
|
220
|
-
animation: __props.animation,
|
|
221
|
-
"background-color": __props.backgroundColor,
|
|
222
|
-
color: __props.color,
|
|
223
|
-
"data-test-id": "icon_image",
|
|
224
|
-
"disable-hover": __props.disableHover,
|
|
225
|
-
"fill-type": __props.fillType,
|
|
226
|
-
"hovered-color": __props.hoveredColor,
|
|
227
|
-
"show-count": __props.showCount
|
|
228
|
-
}, {
|
|
229
|
-
default: withCtx(() => [createBaseVNode("i", {
|
|
230
|
-
"data-test-id": "icon_svg",
|
|
231
|
-
innerHTML: icon.html
|
|
232
|
-
}, null, 8, _hoisted_1)]),
|
|
233
|
-
_: 1
|
|
234
|
-
}, 8, ["animation", "background-color", "color", "disable-hover", "fill-type", "hovered-color", "show-count"]), createTextVNode(), __props.isStriked ? (openBlock(), createBlock(StrikedLine, {
|
|
235
|
-
key: 0,
|
|
236
|
-
color: __props.color,
|
|
237
|
-
"data-test-id": "icon_striked_line"
|
|
238
|
-
}, null, 8, ["color"])) : createCommentVNode("", true), createTextVNode(), __props.count > 0 ? (openBlock(), createBlock(CountWrapper, {
|
|
239
|
-
key: 1,
|
|
240
|
-
"data-test-id": "icon_count"
|
|
241
|
-
}, {
|
|
242
|
-
default: withCtx(() => [createTextVNode(toDisplayString(counter.value), 1)]),
|
|
243
|
-
_: 1
|
|
244
|
-
})) : createCommentVNode("", true)]),
|
|
245
|
-
_: 1
|
|
246
|
-
}, 8, ["cursor", "disabled", "height", "width"]);
|
|
247
|
-
};
|
|
10
|
+
const _sfc_main = {
|
|
11
|
+
name: "IsRequiredLabelStar",
|
|
12
|
+
components: {
|
|
13
|
+
StarElement
|
|
248
14
|
}
|
|
249
15
|
};
|
|
16
|
+
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
17
|
+
const _component_StarElement = resolveComponent("StarElement");
|
|
18
|
+
return openBlock(), createBlock(_component_StarElement, null, {
|
|
19
|
+
default: withCtx(() => [createTextVNode("*")]),
|
|
20
|
+
_: 1
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
const IsRequiredLabelStar = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
|
|
250
24
|
export {
|
|
251
|
-
|
|
25
|
+
IsRequiredLabelStar as default
|
|
252
26
|
};
|
package/dist/main.es383.js
CHANGED
package/dist/main.es386.js
CHANGED
package/dist/main.es5.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { isRuntimeOnly, warn, createRenderer, callWithAsyncErrorHandling } from "./main.es6.js";
|
|
2
2
|
import { Comment, Fragment, Static, Teleport, Text, callWithErrorHandling, cloneVNode, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createStaticVNode, createTextVNode, createVNode, defineComponent, devtools, getCurrentInstance, guardReactiveProps, h, handleError, initCustomFormatter, inject, isVNode, mergeProps, nextTick, onActivated, onBeforeMount, onBeforeUnmount, onBeforeUpdate, onDeactivated, onErrorCaptured, onMounted, onRenderTracked, onRenderTriggered, onServerPrefetch, onUnmounted, onUpdated, openBlock, provide, queuePostFlushCb, renderList, renderSlot, resolveComponent, resolveDynamicComponent, setBlockTracking, setDevtoolsHook, ssrContextKey, useSSRContext, version, watch, watchEffect, withCtx, withDirectives } from "./main.es6.js";
|
|
3
|
-
import { isFunction, isHTMLTag, isSVGTag, isString, looseToNumber, isArray, invokeArrayFns, hyphenate, extend, isOn, isModelListener, capitalize, isSpecialBooleanAttr, includeBooleanAttr } from "./main.
|
|
3
|
+
import { isFunction, isHTMLTag, isSVGTag, isString, looseToNumber, isArray, invokeArrayFns, hyphenate, extend, isOn, isModelListener, capitalize, isSpecialBooleanAttr, includeBooleanAttr } from "./main.es17.js";
|
|
4
4
|
import { camelize } from "./main.es16.js";
|
|
5
5
|
import { capitalize as capitalize2, normalizeClass, normalizeStyle, toDisplayString, toHandlerKey } from "./main.es16.js";
|
|
6
6
|
const svgNS = "http://www.w3.org/2000/svg";
|
package/dist/main.es6.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { isRef, toRaw, getCurrentScope, isShallow as isShallow$1, isReactive, ReactiveEffect, isProxy, computed as computed$1, pauseTracking, resetTracking, isReadonly, track, proxyRefs, markRaw, shallowReadonly, EffectScope, reactive, shallowReactive, trigger } from "./main.
|
|
2
|
-
import { readonly, ref, shallowRef, unref } from "./main.
|
|
1
|
+
import { isRef, toRaw, getCurrentScope, isShallow as isShallow$1, isReactive, ReactiveEffect, isProxy, computed as computed$1, pauseTracking, resetTracking, isReadonly, track, proxyRefs, markRaw, shallowReadonly, EffectScope, reactive, shallowReactive, trigger } from "./main.es19.js";
|
|
2
|
+
import { readonly, ref, shallowRef, unref } from "./main.es19.js";
|
|
3
3
|
import { isString, isFunction, getGlobalThis, isArray, NOOP, EMPTY_OBJ, normalizeClass, isObject, extend, normalizeStyle, isOn, isPromise, hasChanged, remove, isSet, isMap, isPlainObject, camelize, capitalize, toHandlerKey, hasOwn, EMPTY_ARR, NO, isBuiltInDirective, isReservedProp, invokeArrayFns, makeMap, looseToNumber, hyphenate, def, toRawType, isModelListener } from "./main.es16.js";
|
|
4
4
|
import { toDisplayString } from "./main.es16.js";
|
|
5
5
|
const stack = [];
|
package/dist/main.es742.js
CHANGED
|
@@ -1,64 +1,25 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
let supported;
|
|
2
|
+
let perf;
|
|
3
|
+
function isPerformanceSupported() {
|
|
4
|
+
var _a;
|
|
5
|
+
if (supported !== void 0) {
|
|
6
|
+
return supported;
|
|
6
7
|
}
|
|
7
|
-
|
|
8
|
+
if (typeof window !== "undefined" && window.performance) {
|
|
9
|
+
supported = true;
|
|
10
|
+
perf = window.performance;
|
|
11
|
+
} else if (typeof globalThis !== "undefined" && ((_a = globalThis.perf_hooks) === null || _a === void 0 ? void 0 : _a.performance)) {
|
|
12
|
+
supported = true;
|
|
13
|
+
perf = globalThis.perf_hooks.performance;
|
|
14
|
+
} else {
|
|
15
|
+
supported = false;
|
|
16
|
+
}
|
|
17
|
+
return supported;
|
|
18
|
+
}
|
|
19
|
+
function now() {
|
|
20
|
+
return isPerformanceSupported() ? perf.now() : Date.now();
|
|
8
21
|
}
|
|
9
|
-
!!(process.env.NODE_ENV !== "production") ? Object.freeze({}) : {};
|
|
10
|
-
!!(process.env.NODE_ENV !== "production") ? Object.freeze([]) : [];
|
|
11
|
-
const NOOP = () => {
|
|
12
|
-
};
|
|
13
|
-
const extend = Object.assign;
|
|
14
|
-
const hasOwnProperty = Object.prototype.hasOwnProperty;
|
|
15
|
-
const hasOwn = (val, key) => hasOwnProperty.call(val, key);
|
|
16
|
-
const isArray = Array.isArray;
|
|
17
|
-
const isMap = (val) => toTypeString(val) === "[object Map]";
|
|
18
|
-
const isFunction = (val) => typeof val === "function";
|
|
19
|
-
const isString = (val) => typeof val === "string";
|
|
20
|
-
const isSymbol = (val) => typeof val === "symbol";
|
|
21
|
-
const isObject = (val) => val !== null && typeof val === "object";
|
|
22
|
-
const objectToString = Object.prototype.toString;
|
|
23
|
-
const toTypeString = (value) => objectToString.call(value);
|
|
24
|
-
const toRawType = (value) => {
|
|
25
|
-
return toTypeString(value).slice(8, -1);
|
|
26
|
-
};
|
|
27
|
-
const isIntegerKey = (key) => isString(key) && key !== "NaN" && key[0] !== "-" && "" + parseInt(key, 10) === key;
|
|
28
|
-
const cacheStringFunction = (fn) => {
|
|
29
|
-
const cache = /* @__PURE__ */ Object.create(null);
|
|
30
|
-
return (str) => {
|
|
31
|
-
const hit = cache[str];
|
|
32
|
-
return hit || (cache[str] = fn(str));
|
|
33
|
-
};
|
|
34
|
-
};
|
|
35
|
-
const capitalize = cacheStringFunction(
|
|
36
|
-
(str) => str.charAt(0).toUpperCase() + str.slice(1)
|
|
37
|
-
);
|
|
38
|
-
const hasChanged = (value, oldValue) => !Object.is(value, oldValue);
|
|
39
|
-
const def = (obj, key, value) => {
|
|
40
|
-
Object.defineProperty(obj, key, {
|
|
41
|
-
configurable: true,
|
|
42
|
-
enumerable: false,
|
|
43
|
-
value
|
|
44
|
-
});
|
|
45
|
-
};
|
|
46
22
|
export {
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
def,
|
|
50
|
-
extend,
|
|
51
|
-
hasChanged,
|
|
52
|
-
hasOwn,
|
|
53
|
-
isArray,
|
|
54
|
-
isFunction,
|
|
55
|
-
isIntegerKey,
|
|
56
|
-
isMap,
|
|
57
|
-
isObject,
|
|
58
|
-
isString,
|
|
59
|
-
isSymbol,
|
|
60
|
-
makeMap,
|
|
61
|
-
objectToString,
|
|
62
|
-
toRawType,
|
|
63
|
-
toTypeString
|
|
23
|
+
isPerformanceSupported,
|
|
24
|
+
now
|
|
64
25
|
};
|
package/dist/main.es743.js
CHANGED
|
@@ -1,25 +1,64 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
return supported;
|
|
1
|
+
function makeMap(str, expectsLowerCase) {
|
|
2
|
+
const map = /* @__PURE__ */ Object.create(null);
|
|
3
|
+
const list = str.split(",");
|
|
4
|
+
for (let i = 0; i < list.length; i++) {
|
|
5
|
+
map[list[i]] = true;
|
|
7
6
|
}
|
|
8
|
-
|
|
9
|
-
supported = true;
|
|
10
|
-
perf = window.performance;
|
|
11
|
-
} else if (typeof globalThis !== "undefined" && ((_a = globalThis.perf_hooks) === null || _a === void 0 ? void 0 : _a.performance)) {
|
|
12
|
-
supported = true;
|
|
13
|
-
perf = globalThis.perf_hooks.performance;
|
|
14
|
-
} else {
|
|
15
|
-
supported = false;
|
|
16
|
-
}
|
|
17
|
-
return supported;
|
|
18
|
-
}
|
|
19
|
-
function now() {
|
|
20
|
-
return isPerformanceSupported() ? perf.now() : Date.now();
|
|
7
|
+
return expectsLowerCase ? (val) => !!map[val.toLowerCase()] : (val) => !!map[val];
|
|
21
8
|
}
|
|
9
|
+
!!(process.env.NODE_ENV !== "production") ? Object.freeze({}) : {};
|
|
10
|
+
!!(process.env.NODE_ENV !== "production") ? Object.freeze([]) : [];
|
|
11
|
+
const NOOP = () => {
|
|
12
|
+
};
|
|
13
|
+
const extend = Object.assign;
|
|
14
|
+
const hasOwnProperty = Object.prototype.hasOwnProperty;
|
|
15
|
+
const hasOwn = (val, key) => hasOwnProperty.call(val, key);
|
|
16
|
+
const isArray = Array.isArray;
|
|
17
|
+
const isMap = (val) => toTypeString(val) === "[object Map]";
|
|
18
|
+
const isFunction = (val) => typeof val === "function";
|
|
19
|
+
const isString = (val) => typeof val === "string";
|
|
20
|
+
const isSymbol = (val) => typeof val === "symbol";
|
|
21
|
+
const isObject = (val) => val !== null && typeof val === "object";
|
|
22
|
+
const objectToString = Object.prototype.toString;
|
|
23
|
+
const toTypeString = (value) => objectToString.call(value);
|
|
24
|
+
const toRawType = (value) => {
|
|
25
|
+
return toTypeString(value).slice(8, -1);
|
|
26
|
+
};
|
|
27
|
+
const isIntegerKey = (key) => isString(key) && key !== "NaN" && key[0] !== "-" && "" + parseInt(key, 10) === key;
|
|
28
|
+
const cacheStringFunction = (fn) => {
|
|
29
|
+
const cache = /* @__PURE__ */ Object.create(null);
|
|
30
|
+
return (str) => {
|
|
31
|
+
const hit = cache[str];
|
|
32
|
+
return hit || (cache[str] = fn(str));
|
|
33
|
+
};
|
|
34
|
+
};
|
|
35
|
+
const capitalize = cacheStringFunction(
|
|
36
|
+
(str) => str.charAt(0).toUpperCase() + str.slice(1)
|
|
37
|
+
);
|
|
38
|
+
const hasChanged = (value, oldValue) => !Object.is(value, oldValue);
|
|
39
|
+
const def = (obj, key, value) => {
|
|
40
|
+
Object.defineProperty(obj, key, {
|
|
41
|
+
configurable: true,
|
|
42
|
+
enumerable: false,
|
|
43
|
+
value
|
|
44
|
+
});
|
|
45
|
+
};
|
|
22
46
|
export {
|
|
23
|
-
|
|
24
|
-
|
|
47
|
+
NOOP,
|
|
48
|
+
capitalize,
|
|
49
|
+
def,
|
|
50
|
+
extend,
|
|
51
|
+
hasChanged,
|
|
52
|
+
hasOwn,
|
|
53
|
+
isArray,
|
|
54
|
+
isFunction,
|
|
55
|
+
isIntegerKey,
|
|
56
|
+
isMap,
|
|
57
|
+
isObject,
|
|
58
|
+
isString,
|
|
59
|
+
isSymbol,
|
|
60
|
+
makeMap,
|
|
61
|
+
objectToString,
|
|
62
|
+
toRawType,
|
|
63
|
+
toTypeString
|
|
25
64
|
};
|
package/dist/main.es9.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import styled from "./main.es7.js";
|
|
2
|
-
import _sfc_main$1 from "./main.
|
|
2
|
+
import _sfc_main$1 from "./main.es15.js";
|
|
3
3
|
import theme from "./main.es8.js";
|
|
4
4
|
import "./main.es3.js";
|
|
5
5
|
import _export_sfc from "./main.es11.js";
|
|
@@ -7,16 +7,16 @@ import { resolveComponent, openBlock, createBlock, withCtx, createVNode, createT
|
|
|
7
7
|
import { toDisplayString } from "./main.es16.js";
|
|
8
8
|
const TagContainer = styled.div`
|
|
9
9
|
display: inline-flex;
|
|
10
|
-
align-items:
|
|
10
|
+
align-items: center;
|
|
11
11
|
justify-content: center;
|
|
12
12
|
gap: 4px;
|
|
13
13
|
border-radius: 4px;
|
|
14
|
-
padding: 4px;
|
|
14
|
+
padding: 2px 4px;
|
|
15
15
|
background-color: ${(props) => props.theme.semanticColors.yellow[200]};
|
|
16
16
|
cursor: pointer;
|
|
17
17
|
`;
|
|
18
18
|
const TextContainer = styled.div`
|
|
19
|
-
font-size:
|
|
19
|
+
font-size: 10px;
|
|
20
20
|
font-weight: 700;
|
|
21
21
|
color: ${(props) => props.theme.semanticColors.teal[800]};
|
|
22
22
|
`;
|
package/package.json
CHANGED
|
@@ -23,13 +23,17 @@
|
|
|
23
23
|
<Icon
|
|
24
24
|
:color="
|
|
25
25
|
iconColor ||
|
|
26
|
-
|
|
26
|
+
(isDisabled
|
|
27
|
+
? theme.mainButton[appTheme][type][variant].disabled.textColor
|
|
28
|
+
: theme.mainButton[appTheme][type][variant].default.textColor)
|
|
27
29
|
"
|
|
28
30
|
:disable-hover="disableIconHover"
|
|
29
31
|
:fill-type="fillType"
|
|
30
32
|
:hovered-color="
|
|
31
33
|
iconColor ||
|
|
32
|
-
|
|
34
|
+
(isDisabled
|
|
35
|
+
? theme.mainButton[appTheme][type][variant].disabled.textColor
|
|
36
|
+
: theme.mainButton[appTheme][type][variant].default.textColor)
|
|
33
37
|
"
|
|
34
38
|
:name="iconName"
|
|
35
39
|
size="14px"
|
|
@@ -45,13 +49,17 @@
|
|
|
45
49
|
v-if="showCaret"
|
|
46
50
|
:color="
|
|
47
51
|
iconColor ||
|
|
48
|
-
|
|
52
|
+
(isDisabled
|
|
53
|
+
? theme.mainButton[appTheme][type][variant].disabled.textColor
|
|
54
|
+
: theme.mainButton[appTheme][type][variant].default.textColor)
|
|
49
55
|
"
|
|
50
56
|
data-test-id="button-icon-caret"
|
|
51
57
|
:disable-hover="disableIconHover"
|
|
52
58
|
:hovered-color="
|
|
53
59
|
iconColor ||
|
|
54
|
-
|
|
60
|
+
(isDisabled
|
|
61
|
+
? theme.mainButton[appTheme][type][variant].disabled.textColor
|
|
62
|
+
: theme.mainButton[appTheme][type][variant].default.textColor)
|
|
55
63
|
"
|
|
56
64
|
name="arrow_down"
|
|
57
65
|
size="8px"
|
|
@@ -16,9 +16,6 @@
|
|
|
16
16
|
:width="width"
|
|
17
17
|
>
|
|
18
18
|
<LabelComponent :has-icon="Boolean(icon)" :reverse-direction="iconLast">
|
|
19
|
-
<FlexSpinner v-if="isLoading">
|
|
20
|
-
<RCSpinner size="tiny" />
|
|
21
|
-
</FlexSpinner>
|
|
22
19
|
<Icon
|
|
23
20
|
v-if="icon"
|
|
24
21
|
:color="getIconColor"
|
|
@@ -47,7 +44,6 @@
|
|
|
47
44
|
// />
|
|
48
45
|
|
|
49
46
|
import styled from 'vue3-styled-components'
|
|
50
|
-
import RCSpinner from '../../spinner'
|
|
51
47
|
import Icon from '../../icon'
|
|
52
48
|
import theme from '../../../assets/theme'
|
|
53
49
|
|
|
@@ -178,10 +174,6 @@
|
|
|
178
174
|
transform: rotate(20deg);
|
|
179
175
|
cursor: ${(props) => (props.isDisabled ? 'not-allowed' : 'pointer')};
|
|
180
176
|
`
|
|
181
|
-
const FlexSpinner = styled('div')`
|
|
182
|
-
flex: 0;
|
|
183
|
-
margin-right: 8px;
|
|
184
|
-
`
|
|
185
177
|
|
|
186
178
|
export default {
|
|
187
179
|
name: 'MainButton',
|
|
@@ -191,8 +183,6 @@
|
|
|
191
183
|
PageContainer,
|
|
192
184
|
ButtonContainer,
|
|
193
185
|
BetaTag,
|
|
194
|
-
RCSpinner,
|
|
195
|
-
FlexSpinner,
|
|
196
186
|
},
|
|
197
187
|
props: {
|
|
198
188
|
type: {
|
|
@@ -295,10 +285,6 @@
|
|
|
295
285
|
type: Boolean,
|
|
296
286
|
default: false,
|
|
297
287
|
},
|
|
298
|
-
isLoading: {
|
|
299
|
-
type: Boolean,
|
|
300
|
-
default: false,
|
|
301
|
-
},
|
|
302
288
|
},
|
|
303
289
|
computed: {
|
|
304
290
|
theme() {
|
|
@@ -93,7 +93,7 @@
|
|
|
93
93
|
v-if="hasError && hasErrorMessage"
|
|
94
94
|
data-test-id="error_message_wrapper"
|
|
95
95
|
>
|
|
96
|
-
{{
|
|
96
|
+
{{ dynamicErrorMessage }}
|
|
97
97
|
</ErrorMessage>
|
|
98
98
|
</InputErrorWrapper>
|
|
99
99
|
</InputWrapper>
|
|
@@ -444,6 +444,9 @@
|
|
|
444
444
|
hasErrorMessage() {
|
|
445
445
|
return this.errorMessage && this.errorMessage.length > 0
|
|
446
446
|
},
|
|
447
|
+
dynamicErrorMessage() {
|
|
448
|
+
return this.errorMessage
|
|
449
|
+
},
|
|
447
450
|
},
|
|
448
451
|
watch: {
|
|
449
452
|
hasFocus(newVal) {
|