@idds/vue 1.3.3 → 1.4.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/components/Checkbox.vue.d.ts.map +1 -1
- package/dist/components/DatePicker.vue.d.ts.map +1 -1
- package/dist/components/Drawer.vue.d.ts.map +1 -1
- package/dist/components/MonthPicker.vue.d.ts.map +1 -1
- package/dist/components/TextArea.vue.d.ts.map +1 -1
- package/dist/components/TextField.vue.d.ts.map +1 -1
- package/dist/components/YearPicker.vue.d.ts.map +1 -1
- package/dist/index.cjs.js +5 -5
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.css +1 -1
- package/dist/index.es.js +198 -192
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +4 -4
- package/dist/index.umd.js.map +1 -1
- package/package.json +2 -2
package/dist/index.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent, inject, ref, computed, onMounted, onUnmounted, watch, createElementBlock, openBlock, normalizeClass, createElementVNode, renderSlot, createTextVNode, toDisplayString, createVNode, createCommentVNode, createBlock, resolveDynamicComponent, Transition, withCtx, provide, withModifiers, normalizeStyle, nextTick, h, unref, Fragment, renderList, mergeProps, withDirectives, vModelDynamic, withKeys, vModelText, Teleport, createStaticVNode, vModelRadio
|
|
1
|
+
import { defineComponent, inject, ref, computed, onMounted, onUnmounted, watch, createElementBlock, openBlock, normalizeClass, createElementVNode, renderSlot, createTextVNode, toDisplayString, createVNode, createCommentVNode, createBlock, resolveDynamicComponent, Transition, withCtx, provide, withModifiers, normalizeStyle, nextTick, h, unref, Fragment, renderList, mergeProps, useAttrs, withDirectives, vModelDynamic, withKeys, vModelText, Teleport, createStaticVNode, vModelRadio } from "vue";
|
|
2
2
|
const iddsColorTokens = {
|
|
3
3
|
// Neutral Colors
|
|
4
4
|
"neutral-25": "var(--ina-neutral-25)",
|
|
@@ -572,7 +572,7 @@ const _hoisted_7$j = {
|
|
|
572
572
|
key: 0,
|
|
573
573
|
class: "ina-accordion-card__subtitle"
|
|
574
574
|
};
|
|
575
|
-
const _hoisted_8$
|
|
575
|
+
const _hoisted_8$e = ["id", "aria-labelledby"];
|
|
576
576
|
const _hoisted_9$b = { class: "ina-accordion-card__body" };
|
|
577
577
|
const _sfc_main$N = /* @__PURE__ */ defineComponent({
|
|
578
578
|
__name: "AccordionCard",
|
|
@@ -667,7 +667,7 @@ const _sfc_main$N = /* @__PURE__ */ defineComponent({
|
|
|
667
667
|
createElementVNode("div", _hoisted_9$b, [
|
|
668
668
|
renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
669
669
|
])
|
|
670
|
-
], 8, _hoisted_8$
|
|
670
|
+
], 8, _hoisted_8$e)) : createCommentVNode("", true)
|
|
671
671
|
]),
|
|
672
672
|
_: 3
|
|
673
673
|
})
|
|
@@ -1694,7 +1694,7 @@ const _hoisted_6$i = {
|
|
|
1694
1694
|
class: "ina-card__avatar"
|
|
1695
1695
|
};
|
|
1696
1696
|
const _hoisted_7$h = ["src", "alt"];
|
|
1697
|
-
const _hoisted_8$
|
|
1697
|
+
const _hoisted_8$d = {
|
|
1698
1698
|
key: 0,
|
|
1699
1699
|
class: "ina-card__title"
|
|
1700
1700
|
};
|
|
@@ -1843,7 +1843,7 @@ const _sfc_main$D = /* @__PURE__ */ defineComponent({
|
|
|
1843
1843
|
])
|
|
1844
1844
|
])) : createCommentVNode("", true),
|
|
1845
1845
|
createElementVNode("div", null, [
|
|
1846
|
-
__props.title || _ctx.$slots.title ? (openBlock(), createElementBlock("h3", _hoisted_8$
|
|
1846
|
+
__props.title || _ctx.$slots.title ? (openBlock(), createElementBlock("h3", _hoisted_8$d, [
|
|
1847
1847
|
renderSlot(_ctx.$slots, "title", {}, () => [
|
|
1848
1848
|
createTextVNode(toDisplayString(__props.title), 1)
|
|
1849
1849
|
])
|
|
@@ -1990,6 +1990,9 @@ const _sfc_main$C = /* @__PURE__ */ defineComponent({
|
|
|
1990
1990
|
if (props.disabled) {
|
|
1991
1991
|
classes.push("ina-checkbox--disabled");
|
|
1992
1992
|
}
|
|
1993
|
+
if (props.subtext) {
|
|
1994
|
+
classes.push("ina-checkbox--with-subtext");
|
|
1995
|
+
}
|
|
1993
1996
|
return classes;
|
|
1994
1997
|
});
|
|
1995
1998
|
const boxClasses = computed(() => {
|
|
@@ -2054,11 +2057,12 @@ const _sfc_main$C = /* @__PURE__ */ defineComponent({
|
|
|
2054
2057
|
disabled: __props.disabled,
|
|
2055
2058
|
readonly: __props.readonly,
|
|
2056
2059
|
indeterminate: __props.indeterminate,
|
|
2057
|
-
class: "ina-checkbox__input peer"
|
|
2060
|
+
class: "ina-checkbox__input peer"
|
|
2061
|
+
}, _ctx.$attrs, {
|
|
2058
2062
|
onChange: handleChange,
|
|
2059
2063
|
onFocus: handleFocus,
|
|
2060
2064
|
onBlur: handleBlur
|
|
2061
|
-
}
|
|
2065
|
+
}), null, 16, _hoisted_2$v),
|
|
2062
2066
|
createElementVNode("div", {
|
|
2063
2067
|
class: normalizeClass(boxClasses.value)
|
|
2064
2068
|
}, [
|
|
@@ -2313,7 +2317,7 @@ const _hoisted_4$n = {
|
|
|
2313
2317
|
key: 0,
|
|
2314
2318
|
class: "ina-text-field__prefix-icon"
|
|
2315
2319
|
};
|
|
2316
|
-
const _hoisted_5$j = ["id", "type", "placeholder", "disabled", "readonly", "maxlength", "autocomplete", "spellcheck", "autocapitalize", "autocorrect", "inputmode", "dir"];
|
|
2320
|
+
const _hoisted_5$j = ["id", "name", "type", "placeholder", "disabled", "readonly", "maxlength", "autocomplete", "spellcheck", "autocapitalize", "autocorrect", "inputmode", "dir"];
|
|
2317
2321
|
const _hoisted_6$g = {
|
|
2318
2322
|
key: 1,
|
|
2319
2323
|
class: "ina-text-field__char-count"
|
|
@@ -2350,6 +2354,7 @@ const _sfc_main$B = /* @__PURE__ */ defineComponent({
|
|
|
2350
2354
|
setup(__props, { emit: __emit }) {
|
|
2351
2355
|
const props = __props;
|
|
2352
2356
|
const emit = __emit;
|
|
2357
|
+
const attrs = useAttrs();
|
|
2353
2358
|
const inputRef = ref();
|
|
2354
2359
|
const inputValue = ref(getInitialValue());
|
|
2355
2360
|
const debounceTimer = ref();
|
|
@@ -2363,9 +2368,20 @@ const _sfc_main$B = /* @__PURE__ */ defineComponent({
|
|
|
2363
2368
|
}
|
|
2364
2369
|
return value;
|
|
2365
2370
|
}
|
|
2366
|
-
const inputId = computed(
|
|
2367
|
-
|
|
2368
|
-
|
|
2371
|
+
const inputId = computed(() => {
|
|
2372
|
+
const providedId = attrs.id || attrs.name;
|
|
2373
|
+
if (providedId) {
|
|
2374
|
+
return String(providedId);
|
|
2375
|
+
}
|
|
2376
|
+
if (props.label) {
|
|
2377
|
+
return String(props.label).toLowerCase();
|
|
2378
|
+
}
|
|
2379
|
+
return `text-field-${Math.random().toString(36).substr(2, 9)}`;
|
|
2380
|
+
});
|
|
2381
|
+
const filteredAttrs = computed(() => {
|
|
2382
|
+
const { id, name, ...rest } = attrs;
|
|
2383
|
+
return rest;
|
|
2384
|
+
});
|
|
2369
2385
|
const wrapperClasses = computed(() => {
|
|
2370
2386
|
const classes = ["ina-text-field__wrapper"];
|
|
2371
2387
|
classes.push(`ina-text-field__wrapper--size-${props.size}`);
|
|
@@ -2534,11 +2550,12 @@ const _sfc_main$B = /* @__PURE__ */ defineComponent({
|
|
|
2534
2550
|
__props.prefixIcon ? (openBlock(), createElementBlock("div", _hoisted_4$n, [
|
|
2535
2551
|
(openBlock(), createBlock(resolveDynamicComponent(__props.prefixIcon), { size: 16 }))
|
|
2536
2552
|
])) : createCommentVNode("", true),
|
|
2537
|
-
withDirectives(createElementVNode("input", mergeProps(
|
|
2553
|
+
withDirectives(createElementVNode("input", mergeProps(filteredAttrs.value, {
|
|
2538
2554
|
id: inputId.value,
|
|
2539
2555
|
ref_key: "inputRef",
|
|
2540
2556
|
ref: inputRef,
|
|
2541
2557
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => inputValue.value = $event),
|
|
2558
|
+
name: unref(attrs).name || void 0,
|
|
2542
2559
|
type: __props.type,
|
|
2543
2560
|
placeholder: __props.placeholder,
|
|
2544
2561
|
disabled: __props.disabled,
|
|
@@ -3332,7 +3349,7 @@ const _hoisted_4$j = { class: "ina-file-upload__icon" };
|
|
|
3332
3349
|
const _hoisted_5$h = { class: "ina-file-upload__text" };
|
|
3333
3350
|
const _hoisted_6$f = { class: "ina-file-upload__title" };
|
|
3334
3351
|
const _hoisted_7$f = { class: "ina-file-upload__description" };
|
|
3335
|
-
const _hoisted_8$
|
|
3352
|
+
const _hoisted_8$c = ["disabled"];
|
|
3336
3353
|
const _hoisted_9$9 = { class: "ina-file-upload__files" };
|
|
3337
3354
|
const _hoisted_10$8 = { class: "ina-file-upload__file-indicator" };
|
|
3338
3355
|
const _hoisted_11$8 = {
|
|
@@ -3614,7 +3631,7 @@ const _sfc_main$v = /* @__PURE__ */ defineComponent({
|
|
|
3614
3631
|
class: "ina-file-upload__button",
|
|
3615
3632
|
disabled: __props.disabled,
|
|
3616
3633
|
onClick: withModifiers(triggerFileInput, ["stop"])
|
|
3617
|
-
}, " Pilih File ", 8, _hoisted_8$
|
|
3634
|
+
}, " Pilih File ", 8, _hoisted_8$c)
|
|
3618
3635
|
])
|
|
3619
3636
|
], 34),
|
|
3620
3637
|
files.value.length > 0 ? (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
@@ -3944,7 +3961,7 @@ const _hoisted_4$h = ["id"];
|
|
|
3944
3961
|
const _hoisted_5$g = ["aria-label"];
|
|
3945
3962
|
const _hoisted_6$e = { class: "ina-modal__body" };
|
|
3946
3963
|
const _hoisted_7$e = ["id"];
|
|
3947
|
-
const _hoisted_8$
|
|
3964
|
+
const _hoisted_8$b = {
|
|
3948
3965
|
key: 1,
|
|
3949
3966
|
class: "ina-modal__footer"
|
|
3950
3967
|
};
|
|
@@ -4080,7 +4097,7 @@ const _sfc_main$t = /* @__PURE__ */ defineComponent({
|
|
|
4080
4097
|
}, toDisplayString(__props.description), 9, _hoisted_7$e)) : createCommentVNode("", true),
|
|
4081
4098
|
renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
4082
4099
|
]),
|
|
4083
|
-
__props.showFooter ? (openBlock(), createElementBlock("div", _hoisted_8$
|
|
4100
|
+
__props.showFooter ? (openBlock(), createElementBlock("div", _hoisted_8$b, [
|
|
4084
4101
|
renderSlot(_ctx.$slots, "footer", {}, void 0, true)
|
|
4085
4102
|
])) : createCommentVNode("", true)
|
|
4086
4103
|
], 10, _hoisted_2$o)
|
|
@@ -4112,15 +4129,14 @@ const _hoisted_2$n = {
|
|
|
4112
4129
|
key: 0,
|
|
4113
4130
|
class: "ina-month-picker__required"
|
|
4114
4131
|
};
|
|
4115
|
-
const _hoisted_3$l =
|
|
4116
|
-
const _hoisted_4$g =
|
|
4117
|
-
const _hoisted_5$f = {
|
|
4132
|
+
const _hoisted_3$l = ["id", "disabled", "aria-expanded", "aria-labelledby"];
|
|
4133
|
+
const _hoisted_4$g = {
|
|
4118
4134
|
key: 0,
|
|
4119
4135
|
class: "ina-month-picker__prefix-icon"
|
|
4120
4136
|
};
|
|
4121
|
-
const
|
|
4122
|
-
const
|
|
4123
|
-
const
|
|
4137
|
+
const _hoisted_5$f = { class: "ina-month-picker__trigger-text" };
|
|
4138
|
+
const _hoisted_6$d = { class: "ina-month-picker__grid" };
|
|
4139
|
+
const _hoisted_7$d = ["disabled", "onClick", "onMouseenter"];
|
|
4124
4140
|
const _sfc_main$s = /* @__PURE__ */ defineComponent({
|
|
4125
4141
|
__name: "MonthPicker",
|
|
4126
4142
|
props: {
|
|
@@ -4140,6 +4156,7 @@ const _sfc_main$s = /* @__PURE__ */ defineComponent({
|
|
|
4140
4156
|
setup(__props, { emit: __emit }) {
|
|
4141
4157
|
const props = __props;
|
|
4142
4158
|
const emit = __emit;
|
|
4159
|
+
const containerRef = ref();
|
|
4143
4160
|
const triggerRef = ref();
|
|
4144
4161
|
const panelRef = ref();
|
|
4145
4162
|
const isOpen = ref(false);
|
|
@@ -4236,39 +4253,23 @@ const _sfc_main$s = /* @__PURE__ */ defineComponent({
|
|
|
4236
4253
|
let leftValue = void 0;
|
|
4237
4254
|
let rightValue = void 0;
|
|
4238
4255
|
if (isMobile) {
|
|
4239
|
-
const
|
|
4240
|
-
const
|
|
4241
|
-
|
|
4242
|
-
|
|
4243
|
-
|
|
4244
|
-
|
|
4245
|
-
|
|
4246
|
-
|
|
4247
|
-
|
|
4248
|
-
leftValue = `${triggerRect.left}px`;
|
|
4249
|
-
rightValue = void 0;
|
|
4250
|
-
} else if (Math.abs(triggerCenter - viewportCenter) < panelWidthValue / 2) {
|
|
4251
|
-
const panelLeft = triggerRect.left - (panelWidthValue - triggerRect.width) / 2;
|
|
4252
|
-
if (panelLeft < 0) {
|
|
4253
|
-
leftValue = "0";
|
|
4254
|
-
rightValue = void 0;
|
|
4255
|
-
} else if (panelLeft + panelWidthValue > viewportWidth) {
|
|
4256
|
-
rightValue = "0";
|
|
4257
|
-
leftValue = void 0;
|
|
4258
|
-
} else {
|
|
4259
|
-
leftValue = `${panelLeft}px`;
|
|
4260
|
-
rightValue = void 0;
|
|
4256
|
+
const panelCenterX = viewportWidth / 2;
|
|
4257
|
+
const panelLeftFromViewport = panelCenterX - panelWidthValue / 2;
|
|
4258
|
+
if (containerRef.value) {
|
|
4259
|
+
const containerRect = containerRef.value.getBoundingClientRect();
|
|
4260
|
+
const leftRelativeToContainer = panelLeftFromViewport - containerRect.left;
|
|
4261
|
+
let calculatedLeft = Math.max(0, leftRelativeToContainer);
|
|
4262
|
+
const maxLeft = viewportWidth - panelWidthValue - containerRect.left;
|
|
4263
|
+
if (leftRelativeToContainer > maxLeft) {
|
|
4264
|
+
calculatedLeft = Math.max(0, maxLeft);
|
|
4261
4265
|
}
|
|
4266
|
+
leftValue = `${calculatedLeft}px`;
|
|
4267
|
+
rightValue = void 0;
|
|
4262
4268
|
shouldUseRight = false;
|
|
4263
4269
|
} else {
|
|
4264
|
-
|
|
4265
|
-
|
|
4266
|
-
|
|
4267
|
-
leftValue = void 0;
|
|
4268
|
-
} else {
|
|
4269
|
-
leftValue = `${triggerRect.left}px`;
|
|
4270
|
-
rightValue = void 0;
|
|
4271
|
-
}
|
|
4270
|
+
leftValue = `${Math.max(0, panelLeftFromViewport)}px`;
|
|
4271
|
+
rightValue = void 0;
|
|
4272
|
+
shouldUseRight = false;
|
|
4272
4273
|
}
|
|
4273
4274
|
} else {
|
|
4274
4275
|
shouldUseRight = panelWidthValue > availableSpaceRight;
|
|
@@ -4373,6 +4374,8 @@ const _sfc_main$s = /* @__PURE__ */ defineComponent({
|
|
|
4373
4374
|
});
|
|
4374
4375
|
return (_ctx, _cache) => {
|
|
4375
4376
|
return openBlock(), createElementBlock("div", {
|
|
4377
|
+
ref_key: "containerRef",
|
|
4378
|
+
ref: containerRef,
|
|
4376
4379
|
class: normalizeClass(["ina-month-picker", containerClasses.value])
|
|
4377
4380
|
}, [
|
|
4378
4381
|
__props.label ? (openBlock(), createElementBlock("label", {
|
|
@@ -4383,94 +4386,92 @@ const _sfc_main$s = /* @__PURE__ */ defineComponent({
|
|
|
4383
4386
|
createTextVNode(toDisplayString(__props.label) + " ", 1),
|
|
4384
4387
|
__props.required ? (openBlock(), createElementBlock("span", _hoisted_2$n, "*")) : createCommentVNode("", true)
|
|
4385
4388
|
], 8, _hoisted_1$o)) : createCommentVNode("", true),
|
|
4386
|
-
createElementVNode("
|
|
4387
|
-
|
|
4388
|
-
|
|
4389
|
-
|
|
4390
|
-
|
|
4389
|
+
createElementVNode("button", {
|
|
4390
|
+
id: triggerId.value,
|
|
4391
|
+
ref_key: "triggerRef",
|
|
4392
|
+
ref: triggerRef,
|
|
4393
|
+
type: "button",
|
|
4394
|
+
class: normalizeClass(triggerClasses.value),
|
|
4395
|
+
disabled: __props.disabled || __props.readonly,
|
|
4396
|
+
"aria-expanded": isOpen.value,
|
|
4397
|
+
"aria-haspopup": true,
|
|
4398
|
+
"aria-labelledby": __props.label ? `${triggerId.value}-label` : void 0,
|
|
4399
|
+
onClick: togglePanel,
|
|
4400
|
+
onKeydown: handleKeydown
|
|
4401
|
+
}, [
|
|
4402
|
+
__props.showIcon ? (openBlock(), createElementBlock("div", _hoisted_4$g, [..._cache[1] || (_cache[1] = [
|
|
4403
|
+
createStaticVNode('<svg width="16" height="16" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" data-v-f53ade24><rect x="3" y="4" width="18" height="18" rx="2" ry="2" stroke="currentColor" stroke-width="2" data-v-f53ade24></rect><line x1="16" y1="2" x2="16" y2="6" stroke="currentColor" stroke-width="2" stroke-linecap="round" data-v-f53ade24></line><line x1="8" y1="2" x2="8" y2="6" stroke="currentColor" stroke-width="2" stroke-linecap="round" data-v-f53ade24></line><line x1="3" y1="10" x2="21" y2="10" stroke="currentColor" stroke-width="2" stroke-linecap="round" data-v-f53ade24></line></svg>', 1)
|
|
4404
|
+
])])) : createCommentVNode("", true),
|
|
4405
|
+
createElementVNode("span", _hoisted_5$f, toDisplayString(selectedMonthDisplay.value || __props.placeholder), 1),
|
|
4406
|
+
__props.showClearButton && selectedMonth.value !== void 0 && !__props.disabled && !__props.readonly ? (openBlock(), createElementBlock("button", {
|
|
4407
|
+
key: 1,
|
|
4391
4408
|
type: "button",
|
|
4392
|
-
class:
|
|
4393
|
-
|
|
4394
|
-
|
|
4395
|
-
"
|
|
4396
|
-
"aria-labelledby": __props.label ? `${triggerId.value}-label` : void 0,
|
|
4397
|
-
onClick: togglePanel,
|
|
4398
|
-
onKeydown: handleKeydown
|
|
4399
|
-
}, [
|
|
4400
|
-
__props.showIcon ? (openBlock(), createElementBlock("div", _hoisted_5$f, [..._cache[1] || (_cache[1] = [
|
|
4401
|
-
createStaticVNode('<svg width="16" height="16" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" data-v-452431d5><rect x="3" y="4" width="18" height="18" rx="2" ry="2" stroke="currentColor" stroke-width="2" data-v-452431d5></rect><line x1="16" y1="2" x2="16" y2="6" stroke="currentColor" stroke-width="2" stroke-linecap="round" data-v-452431d5></line><line x1="8" y1="2" x2="8" y2="6" stroke="currentColor" stroke-width="2" stroke-linecap="round" data-v-452431d5></line><line x1="3" y1="10" x2="21" y2="10" stroke="currentColor" stroke-width="2" stroke-linecap="round" data-v-452431d5></line></svg>', 1)
|
|
4402
|
-
])])) : createCommentVNode("", true),
|
|
4403
|
-
createElementVNode("span", _hoisted_6$d, toDisplayString(selectedMonthDisplay.value || __props.placeholder), 1),
|
|
4404
|
-
__props.showClearButton && selectedMonth.value !== void 0 && !__props.disabled && !__props.readonly ? (openBlock(), createElementBlock("button", {
|
|
4405
|
-
key: 1,
|
|
4406
|
-
type: "button",
|
|
4407
|
-
class: "ina-month-picker__clear-button",
|
|
4408
|
-
onClick: withModifiers(handleClear, ["stop"])
|
|
4409
|
-
}, [..._cache[2] || (_cache[2] = [
|
|
4410
|
-
createElementVNode("svg", {
|
|
4411
|
-
width: "16",
|
|
4412
|
-
height: "16",
|
|
4413
|
-
viewBox: "0 0 24 24",
|
|
4414
|
-
fill: "none",
|
|
4415
|
-
xmlns: "http://www.w3.org/2000/svg"
|
|
4416
|
-
}, [
|
|
4417
|
-
createElementVNode("path", {
|
|
4418
|
-
d: "M18 6L6 18M6 6L18 18",
|
|
4419
|
-
stroke: "currentColor",
|
|
4420
|
-
"stroke-width": "2",
|
|
4421
|
-
"stroke-linecap": "round",
|
|
4422
|
-
"stroke-linejoin": "round"
|
|
4423
|
-
})
|
|
4424
|
-
], -1)
|
|
4425
|
-
])])) : createCommentVNode("", true),
|
|
4426
|
-
(openBlock(), createElementBlock("svg", {
|
|
4427
|
-
class: normalizeClass(["ina-month-picker__chevron", { "ina-month-picker__chevron--open": isOpen.value }]),
|
|
4409
|
+
class: "ina-month-picker__clear-button",
|
|
4410
|
+
onClick: withModifiers(handleClear, ["stop"])
|
|
4411
|
+
}, [..._cache[2] || (_cache[2] = [
|
|
4412
|
+
createElementVNode("svg", {
|
|
4428
4413
|
width: "16",
|
|
4429
4414
|
height: "16",
|
|
4430
4415
|
viewBox: "0 0 24 24",
|
|
4431
4416
|
fill: "none",
|
|
4432
4417
|
xmlns: "http://www.w3.org/2000/svg"
|
|
4433
|
-
}, [
|
|
4418
|
+
}, [
|
|
4434
4419
|
createElementVNode("path", {
|
|
4435
|
-
d: "
|
|
4420
|
+
d: "M18 6L6 18M6 6L18 18",
|
|
4436
4421
|
stroke: "currentColor",
|
|
4437
4422
|
"stroke-width": "2",
|
|
4438
4423
|
"stroke-linecap": "round",
|
|
4439
4424
|
"stroke-linejoin": "round"
|
|
4440
|
-
}
|
|
4441
|
-
]
|
|
4442
|
-
]
|
|
4443
|
-
|
|
4444
|
-
|
|
4445
|
-
|
|
4446
|
-
|
|
4447
|
-
|
|
4448
|
-
|
|
4449
|
-
|
|
4450
|
-
|
|
4451
|
-
|
|
4452
|
-
|
|
4453
|
-
|
|
4454
|
-
|
|
4455
|
-
|
|
4456
|
-
|
|
4457
|
-
|
|
4458
|
-
|
|
4459
|
-
|
|
4460
|
-
|
|
4461
|
-
|
|
4462
|
-
|
|
4463
|
-
|
|
4464
|
-
|
|
4465
|
-
|
|
4466
|
-
|
|
4467
|
-
|
|
4468
|
-
|
|
4469
|
-
|
|
4470
|
-
|
|
4471
|
-
|
|
4472
|
-
|
|
4473
|
-
|
|
4425
|
+
})
|
|
4426
|
+
], -1)
|
|
4427
|
+
])])) : createCommentVNode("", true),
|
|
4428
|
+
(openBlock(), createElementBlock("svg", {
|
|
4429
|
+
class: normalizeClass(["ina-month-picker__chevron", { "ina-month-picker__chevron--open": isOpen.value }]),
|
|
4430
|
+
width: "16",
|
|
4431
|
+
height: "16",
|
|
4432
|
+
viewBox: "0 0 24 24",
|
|
4433
|
+
fill: "none",
|
|
4434
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
4435
|
+
}, [..._cache[3] || (_cache[3] = [
|
|
4436
|
+
createElementVNode("path", {
|
|
4437
|
+
d: "M6 9L12 15L18 9",
|
|
4438
|
+
stroke: "currentColor",
|
|
4439
|
+
"stroke-width": "2",
|
|
4440
|
+
"stroke-linecap": "round",
|
|
4441
|
+
"stroke-linejoin": "round"
|
|
4442
|
+
}, null, -1)
|
|
4443
|
+
])], 2))
|
|
4444
|
+
], 42, _hoisted_3$l),
|
|
4445
|
+
createVNode(Transition, { name: "panel" }, {
|
|
4446
|
+
default: withCtx(() => [
|
|
4447
|
+
isOpen.value ? (openBlock(), createElementBlock("div", {
|
|
4448
|
+
key: 0,
|
|
4449
|
+
ref_key: "panelRef",
|
|
4450
|
+
ref: panelRef,
|
|
4451
|
+
class: normalizeClass([
|
|
4452
|
+
"ina-month-picker__panel",
|
|
4453
|
+
{ "ina-month-picker__panel--open": isOpen.value },
|
|
4454
|
+
{ "ina-month-picker__panel--right-aligned": useRightPositioning.value }
|
|
4455
|
+
]),
|
|
4456
|
+
style: normalizeStyle(panelStyle.value)
|
|
4457
|
+
}, [
|
|
4458
|
+
createElementVNode("div", _hoisted_6$d, [
|
|
4459
|
+
(openBlock(), createElementBlock(Fragment, null, renderList(monthNames, (month, index2) => {
|
|
4460
|
+
return createElementVNode("button", {
|
|
4461
|
+
key: index2,
|
|
4462
|
+
type: "button",
|
|
4463
|
+
class: normalizeClass(getMonthClasses(index2)),
|
|
4464
|
+
disabled: props.disabled,
|
|
4465
|
+
onClick: ($event) => selectMonth(index2),
|
|
4466
|
+
onMouseenter: ($event) => !props.disabled && (hoveredMonth.value = index2),
|
|
4467
|
+
onMouseleave: _cache[0] || (_cache[0] = ($event) => hoveredMonth.value = null)
|
|
4468
|
+
}, toDisplayString(month), 43, _hoisted_7$d);
|
|
4469
|
+
}), 64))
|
|
4470
|
+
])
|
|
4471
|
+
], 6)) : createCommentVNode("", true)
|
|
4472
|
+
]),
|
|
4473
|
+
_: 1
|
|
4474
|
+
}),
|
|
4474
4475
|
__props.statusMessage ? (openBlock(), createElementBlock("div", {
|
|
4475
4476
|
key: 1,
|
|
4476
4477
|
class: normalizeClass(statusClasses.value)
|
|
@@ -4479,7 +4480,7 @@ const _sfc_main$s = /* @__PURE__ */ defineComponent({
|
|
|
4479
4480
|
};
|
|
4480
4481
|
}
|
|
4481
4482
|
});
|
|
4482
|
-
const MonthPicker = /* @__PURE__ */ _export_sfc(_sfc_main$s, [["__scopeId", "data-v-
|
|
4483
|
+
const MonthPicker = /* @__PURE__ */ _export_sfc(_sfc_main$s, [["__scopeId", "data-v-f53ade24"]]);
|
|
4483
4484
|
const _hoisted_1$n = {
|
|
4484
4485
|
key: 0,
|
|
4485
4486
|
class: "ina-multiple-choice-grid__title"
|
|
@@ -5584,6 +5585,7 @@ const _sfc_main$k = /* @__PURE__ */ defineComponent({
|
|
|
5584
5585
|
setup(__props, { emit: __emit }) {
|
|
5585
5586
|
const props = __props;
|
|
5586
5587
|
const emit = __emit;
|
|
5588
|
+
const containerRef = ref();
|
|
5587
5589
|
const triggerRef = ref();
|
|
5588
5590
|
const panelRef = ref();
|
|
5589
5591
|
const isOpen = ref(false);
|
|
@@ -5679,48 +5681,32 @@ const _sfc_main$k = /* @__PURE__ */ defineComponent({
|
|
|
5679
5681
|
const panelRect = panelRef.value.getBoundingClientRect();
|
|
5680
5682
|
const viewportWidth = window.innerWidth;
|
|
5681
5683
|
const viewportHeight = window.innerHeight;
|
|
5682
|
-
const
|
|
5684
|
+
const isMobile = viewportWidth <= 640;
|
|
5685
|
+
const defaultPanelWidth = isMobile ? 200 : 320;
|
|
5683
5686
|
const panelWidthValue = panelRect.width || defaultPanelWidth;
|
|
5684
5687
|
const availableSpaceRight = viewportWidth - triggerRect.right;
|
|
5685
5688
|
triggerRect.left;
|
|
5686
|
-
const isMobile = viewportWidth <= 640;
|
|
5687
5689
|
let shouldUseRight = false;
|
|
5688
5690
|
let leftValue = void 0;
|
|
5689
5691
|
let rightValue = void 0;
|
|
5690
5692
|
if (isMobile) {
|
|
5691
|
-
const
|
|
5692
|
-
const
|
|
5693
|
-
|
|
5694
|
-
|
|
5695
|
-
|
|
5696
|
-
|
|
5697
|
-
|
|
5698
|
-
|
|
5699
|
-
|
|
5700
|
-
leftValue = `${triggerRect.left}px`;
|
|
5701
|
-
rightValue = void 0;
|
|
5702
|
-
} else if (Math.abs(triggerCenter - viewportCenter) < panelWidthValue / 2) {
|
|
5703
|
-
const panelLeft = triggerRect.left - (panelWidthValue - triggerRect.width) / 2;
|
|
5704
|
-
if (panelLeft < 0) {
|
|
5705
|
-
leftValue = "0";
|
|
5706
|
-
rightValue = void 0;
|
|
5707
|
-
} else if (panelLeft + panelWidthValue > viewportWidth) {
|
|
5708
|
-
rightValue = "0";
|
|
5709
|
-
leftValue = void 0;
|
|
5710
|
-
} else {
|
|
5711
|
-
leftValue = `${panelLeft}px`;
|
|
5712
|
-
rightValue = void 0;
|
|
5693
|
+
const panelCenterX = viewportWidth / 2;
|
|
5694
|
+
const panelLeftFromViewport = panelCenterX - panelWidthValue / 2;
|
|
5695
|
+
if (containerRef.value) {
|
|
5696
|
+
const containerRect = containerRef.value.getBoundingClientRect();
|
|
5697
|
+
const leftRelativeToContainer = panelLeftFromViewport - containerRect.left;
|
|
5698
|
+
let calculatedLeft = Math.max(0, leftRelativeToContainer);
|
|
5699
|
+
const maxLeft = viewportWidth - panelWidthValue - containerRect.left;
|
|
5700
|
+
if (leftRelativeToContainer > maxLeft) {
|
|
5701
|
+
calculatedLeft = Math.max(0, maxLeft);
|
|
5713
5702
|
}
|
|
5703
|
+
leftValue = `${calculatedLeft}px`;
|
|
5704
|
+
rightValue = void 0;
|
|
5714
5705
|
shouldUseRight = false;
|
|
5715
5706
|
} else {
|
|
5716
|
-
|
|
5717
|
-
|
|
5718
|
-
|
|
5719
|
-
leftValue = void 0;
|
|
5720
|
-
} else {
|
|
5721
|
-
leftValue = `${triggerRect.left}px`;
|
|
5722
|
-
rightValue = void 0;
|
|
5723
|
-
}
|
|
5707
|
+
leftValue = `${Math.max(0, panelLeftFromViewport)}px`;
|
|
5708
|
+
rightValue = void 0;
|
|
5709
|
+
shouldUseRight = false;
|
|
5724
5710
|
}
|
|
5725
5711
|
} else {
|
|
5726
5712
|
shouldUseRight = panelWidthValue > availableSpaceRight;
|
|
@@ -5844,6 +5830,8 @@ const _sfc_main$k = /* @__PURE__ */ defineComponent({
|
|
|
5844
5830
|
});
|
|
5845
5831
|
return (_ctx, _cache) => {
|
|
5846
5832
|
return openBlock(), createElementBlock("div", {
|
|
5833
|
+
ref_key: "containerRef",
|
|
5834
|
+
ref: containerRef,
|
|
5847
5835
|
class: normalizeClass(["ina-year-picker", containerClasses.value])
|
|
5848
5836
|
}, [
|
|
5849
5837
|
__props.label ? (openBlock(), createElementBlock("label", {
|
|
@@ -5869,7 +5857,7 @@ const _sfc_main$k = /* @__PURE__ */ defineComponent({
|
|
|
5869
5857
|
onKeydown: handleKeydown
|
|
5870
5858
|
}, [
|
|
5871
5859
|
__props.showIcon ? (openBlock(), createElementBlock("div", _hoisted_5$9, [..._cache[1] || (_cache[1] = [
|
|
5872
|
-
createStaticVNode('<svg width="16" height="16" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" data-v-
|
|
5860
|
+
createStaticVNode('<svg width="16" height="16" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" data-v-6e7c1cdf><rect x="3" y="4" width="18" height="18" rx="2" ry="2" stroke="currentColor" stroke-width="2" data-v-6e7c1cdf></rect><line x1="16" y1="2" x2="16" y2="6" stroke="currentColor" stroke-width="2" stroke-linecap="round" data-v-6e7c1cdf></line><line x1="8" y1="2" x2="8" y2="6" stroke="currentColor" stroke-width="2" stroke-linecap="round" data-v-6e7c1cdf></line><line x1="3" y1="10" x2="21" y2="10" stroke="currentColor" stroke-width="2" stroke-linecap="round" data-v-6e7c1cdf></line></svg>', 1)
|
|
5873
5861
|
])])) : createCommentVNode("", true),
|
|
5874
5862
|
createElementVNode("span", _hoisted_6$8, toDisplayString(selectedYear.value || __props.placeholder), 1),
|
|
5875
5863
|
__props.showClearButton && selectedYear.value && !__props.disabled && !__props.readonly ? (openBlock(), createElementBlock("button", {
|
|
@@ -5953,7 +5941,7 @@ const _sfc_main$k = /* @__PURE__ */ defineComponent({
|
|
|
5953
5941
|
};
|
|
5954
5942
|
}
|
|
5955
5943
|
});
|
|
5956
|
-
const YearPicker = /* @__PURE__ */ _export_sfc(_sfc_main$k, [["__scopeId", "data-v-
|
|
5944
|
+
const YearPicker = /* @__PURE__ */ _export_sfc(_sfc_main$k, [["__scopeId", "data-v-6e7c1cdf"]]);
|
|
5957
5945
|
const _hoisted_1$g = ["for"];
|
|
5958
5946
|
const _hoisted_2$g = {
|
|
5959
5947
|
key: 0,
|
|
@@ -5978,13 +5966,15 @@ const _hoisted_15$2 = { class: "ina-date-picker__dropdown-container" };
|
|
|
5978
5966
|
const _hoisted_16$1 = { class: "ina-date-picker__dropdown-container" };
|
|
5979
5967
|
const _hoisted_17$1 = { class: "ina-date-picker__calendar-grid" };
|
|
5980
5968
|
const _hoisted_18$1 = ["disabled", "onClick"];
|
|
5981
|
-
const _hoisted_19$1 = { class: "ina-date-
|
|
5982
|
-
const _hoisted_20$1 = { class: "ina-date-
|
|
5983
|
-
const _hoisted_21$1 = { class: "ina-date-picker__next-month-
|
|
5984
|
-
const _hoisted_22 = { class: "ina-date-
|
|
5969
|
+
const _hoisted_19$1 = { class: "ina-date-picker__day-number" };
|
|
5970
|
+
const _hoisted_20$1 = { class: "ina-date-picker__calendar" };
|
|
5971
|
+
const _hoisted_21$1 = { class: "ina-date-picker__next-month-header" };
|
|
5972
|
+
const _hoisted_22 = { class: "ina-date-picker__next-month-controls" };
|
|
5985
5973
|
const _hoisted_23 = { class: "ina-date-picker__dropdown-container" };
|
|
5986
|
-
const _hoisted_24 = { class: "ina-date-
|
|
5987
|
-
const _hoisted_25 =
|
|
5974
|
+
const _hoisted_24 = { class: "ina-date-picker__dropdown-container" };
|
|
5975
|
+
const _hoisted_25 = { class: "ina-date-picker__calendar-grid" };
|
|
5976
|
+
const _hoisted_26 = ["disabled", "onClick"];
|
|
5977
|
+
const _hoisted_27 = { class: "ina-date-picker__day-number" };
|
|
5988
5978
|
const _sfc_main$j = /* @__PURE__ */ defineComponent({
|
|
5989
5979
|
__name: "DatePicker",
|
|
5990
5980
|
props: {
|
|
@@ -6008,7 +5998,7 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
|
|
|
6008
5998
|
disabledFutureDate: { type: Boolean },
|
|
6009
5999
|
disabledDateBefore: {},
|
|
6010
6000
|
disabledDateAfter: {},
|
|
6011
|
-
triggerWidth: { default: "
|
|
6001
|
+
triggerWidth: { default: "" },
|
|
6012
6002
|
panelMaxHeight: { default: void 0 },
|
|
6013
6003
|
panelClassName: { default: "" },
|
|
6014
6004
|
triggerClassname: { default: "" },
|
|
@@ -6937,12 +6927,14 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
|
|
|
6937
6927
|
class: normalizeClass(getDayClasses(day)),
|
|
6938
6928
|
disabled: isDayDisabled(day.date),
|
|
6939
6929
|
onClick: ($event) => selectDay(day)
|
|
6940
|
-
},
|
|
6930
|
+
}, [
|
|
6931
|
+
createElementVNode("span", _hoisted_19$1, toDisplayString(day.date.getDate()), 1)
|
|
6932
|
+
], 10, _hoisted_18$1);
|
|
6941
6933
|
}), 128))
|
|
6942
6934
|
])
|
|
6943
6935
|
]),
|
|
6944
|
-
createElementVNode("div",
|
|
6945
|
-
createElementVNode("div",
|
|
6936
|
+
createElementVNode("div", _hoisted_20$1, [
|
|
6937
|
+
createElementVNode("div", _hoisted_21$1, [
|
|
6946
6938
|
createElementVNode("button", {
|
|
6947
6939
|
type: "button",
|
|
6948
6940
|
class: "ina-date-picker__nav-button",
|
|
@@ -6953,8 +6945,8 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
|
|
|
6953
6945
|
class: "ina-date-picker__nav-icon"
|
|
6954
6946
|
})
|
|
6955
6947
|
]),
|
|
6956
|
-
createElementVNode("div",
|
|
6957
|
-
createElementVNode("div",
|
|
6948
|
+
createElementVNode("div", _hoisted_22, [
|
|
6949
|
+
createElementVNode("div", _hoisted_23, [
|
|
6958
6950
|
createVNode(MonthPicker, {
|
|
6959
6951
|
"model-value": nextMonth.value,
|
|
6960
6952
|
disabled: __props.disabled,
|
|
@@ -6963,7 +6955,7 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
|
|
|
6963
6955
|
"onUpdate:modelValue": handleNextMonthChange
|
|
6964
6956
|
}, null, 8, ["model-value", "disabled", "readonly"])
|
|
6965
6957
|
]),
|
|
6966
|
-
createElementVNode("div",
|
|
6958
|
+
createElementVNode("div", _hoisted_24, [
|
|
6967
6959
|
createVNode(YearPicker, {
|
|
6968
6960
|
"model-value": nextYear.value,
|
|
6969
6961
|
"min-year": 1900,
|
|
@@ -6987,7 +6979,7 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
|
|
|
6987
6979
|
})
|
|
6988
6980
|
])
|
|
6989
6981
|
]),
|
|
6990
|
-
createElementVNode("div",
|
|
6982
|
+
createElementVNode("div", _hoisted_25, [
|
|
6991
6983
|
(openBlock(), createElementBlock(Fragment, null, renderList(dayNames, (day) => {
|
|
6992
6984
|
return createElementVNode("div", {
|
|
6993
6985
|
key: `rh-${day}`,
|
|
@@ -7001,7 +6993,9 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
|
|
|
7001
6993
|
class: normalizeClass(getDayClasses(day)),
|
|
7002
6994
|
disabled: isDayDisabled(day.date),
|
|
7003
6995
|
onClick: ($event) => selectDay(day)
|
|
7004
|
-
},
|
|
6996
|
+
}, [
|
|
6997
|
+
createElementVNode("span", _hoisted_27, toDisplayString(day.date.getDate()), 1)
|
|
6998
|
+
], 10, _hoisted_26);
|
|
7005
6999
|
}), 128))
|
|
7006
7000
|
])
|
|
7007
7001
|
])
|
|
@@ -7016,7 +7010,7 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
|
|
|
7016
7010
|
};
|
|
7017
7011
|
}
|
|
7018
7012
|
});
|
|
7019
|
-
const DatePicker = /* @__PURE__ */ _export_sfc(_sfc_main$j, [["__scopeId", "data-v-
|
|
7013
|
+
const DatePicker = /* @__PURE__ */ _export_sfc(_sfc_main$j, [["__scopeId", "data-v-d43f3297"]]);
|
|
7020
7014
|
const _hoisted_1$f = ["disabled"];
|
|
7021
7015
|
const _hoisted_2$f = {
|
|
7022
7016
|
key: 0,
|
|
@@ -7613,10 +7607,10 @@ const _sfc_main$h = /* @__PURE__ */ defineComponent({
|
|
|
7613
7607
|
return openBlock(), createBlock(Teleport, { to: "body" }, [
|
|
7614
7608
|
createVNode(Transition, { name: "drawer" }, {
|
|
7615
7609
|
default: withCtx(() => [
|
|
7616
|
-
isOpen.value ? (openBlock(), createElementBlock("div", {
|
|
7610
|
+
isOpen.value ? (openBlock(), createElementBlock("div", mergeProps({
|
|
7617
7611
|
key: 0,
|
|
7618
|
-
class:
|
|
7619
|
-
}, [
|
|
7612
|
+
class: ["ina-drawer", drawerClasses.value]
|
|
7613
|
+
}, _ctx.$attrs), [
|
|
7620
7614
|
createElementVNode("div", {
|
|
7621
7615
|
class: "ina-drawer__backdrop",
|
|
7622
7616
|
onClick: handleBackdropClick
|
|
@@ -7677,7 +7671,7 @@ const _sfc_main$h = /* @__PURE__ */ defineComponent({
|
|
|
7677
7671
|
renderSlot(_ctx.$slots, "footer", {}, void 0, true)
|
|
7678
7672
|
])) : createCommentVNode("", true)
|
|
7679
7673
|
], 10, _hoisted_1$e)
|
|
7680
|
-
],
|
|
7674
|
+
], 16)) : createCommentVNode("", true)
|
|
7681
7675
|
]),
|
|
7682
7676
|
_: 3
|
|
7683
7677
|
})
|
|
@@ -7685,7 +7679,7 @@ const _sfc_main$h = /* @__PURE__ */ defineComponent({
|
|
|
7685
7679
|
};
|
|
7686
7680
|
}
|
|
7687
7681
|
});
|
|
7688
|
-
const Drawer = /* @__PURE__ */ _export_sfc(_sfc_main$h, [["__scopeId", "data-v-
|
|
7682
|
+
const Drawer = /* @__PURE__ */ _export_sfc(_sfc_main$h, [["__scopeId", "data-v-a924d690"]]);
|
|
7689
7683
|
const _sfc_main$g = /* @__PURE__ */ defineComponent({
|
|
7690
7684
|
__name: "Skeleton",
|
|
7691
7685
|
props: {
|
|
@@ -8716,7 +8710,7 @@ const _hoisted_2$8 = {
|
|
|
8716
8710
|
key: 0,
|
|
8717
8711
|
class: "ina-text-area__required"
|
|
8718
8712
|
};
|
|
8719
|
-
const _hoisted_3$6 = ["id", "placeholder", "disabled", "readonly", "maxlength", "rows", "autocomplete", "spellcheck", "autocapitalize", "autocorrect", "dir"];
|
|
8713
|
+
const _hoisted_3$6 = ["id", "name", "placeholder", "disabled", "readonly", "maxlength", "rows", "autocomplete", "spellcheck", "autocapitalize", "autocorrect", "dir"];
|
|
8720
8714
|
const _sfc_main$9 = /* @__PURE__ */ defineComponent({
|
|
8721
8715
|
__name: "TextArea",
|
|
8722
8716
|
props: {
|
|
@@ -8747,6 +8741,7 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
|
|
|
8747
8741
|
setup(__props, { emit: __emit }) {
|
|
8748
8742
|
const props = __props;
|
|
8749
8743
|
const emit = __emit;
|
|
8744
|
+
const attrs = useAttrs();
|
|
8750
8745
|
const textareaRef = ref();
|
|
8751
8746
|
const inputValue = ref(getInitialValue());
|
|
8752
8747
|
const validationError = ref(null);
|
|
@@ -8759,9 +8754,20 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
|
|
|
8759
8754
|
}
|
|
8760
8755
|
return value;
|
|
8761
8756
|
}
|
|
8762
|
-
const textareaId = computed(
|
|
8763
|
-
|
|
8764
|
-
|
|
8757
|
+
const textareaId = computed(() => {
|
|
8758
|
+
const providedId = attrs.id || attrs.name;
|
|
8759
|
+
if (providedId) {
|
|
8760
|
+
return String(providedId);
|
|
8761
|
+
}
|
|
8762
|
+
if (props.label) {
|
|
8763
|
+
return String(props.label).toLowerCase();
|
|
8764
|
+
}
|
|
8765
|
+
return `text-area-${Math.random().toString(36).substr(2, 9)}`;
|
|
8766
|
+
});
|
|
8767
|
+
const filteredAttrs = computed(() => {
|
|
8768
|
+
const { id, name, ...rest } = attrs;
|
|
8769
|
+
return rest;
|
|
8770
|
+
});
|
|
8765
8771
|
const containerClasses = computed(() => {
|
|
8766
8772
|
const classes = ["ina-text-area"];
|
|
8767
8773
|
if (props.disabled) {
|
|
@@ -8919,11 +8925,12 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
|
|
|
8919
8925
|
createElementVNode("div", {
|
|
8920
8926
|
class: normalizeClass(["ina-text-area__wrapper", wrapperClasses.value])
|
|
8921
8927
|
}, [
|
|
8922
|
-
withDirectives(createElementVNode("textarea", mergeProps({
|
|
8928
|
+
withDirectives(createElementVNode("textarea", mergeProps(filteredAttrs.value, {
|
|
8923
8929
|
id: textareaId.value,
|
|
8924
8930
|
ref_key: "textareaRef",
|
|
8925
8931
|
ref: textareaRef,
|
|
8926
8932
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => inputValue.value = $event),
|
|
8933
|
+
name: unref(attrs).name || void 0,
|
|
8927
8934
|
placeholder: __props.placeholder,
|
|
8928
8935
|
disabled: __props.disabled,
|
|
8929
8936
|
readonly: __props.readonly,
|
|
@@ -8934,8 +8941,7 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
|
|
|
8934
8941
|
autocapitalize: __props.autoCapitalize,
|
|
8935
8942
|
autocorrect: __props.autoCorrect,
|
|
8936
8943
|
dir: __props.dir,
|
|
8937
|
-
class: textareaClasses.value
|
|
8938
|
-
}, _ctx.$attrs, {
|
|
8944
|
+
class: textareaClasses.value,
|
|
8939
8945
|
onInput: handleInput,
|
|
8940
8946
|
onBlur: handleBlur,
|
|
8941
8947
|
onFocus: handleFocus
|