@fkui/vue-labs 6.36.1 → 6.38.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/cjs/index.cjs.js +40 -42
- package/dist/cjs/index.cjs.js.map +1 -1
- package/dist/esm/index.esm.js +40 -42
- package/dist/esm/index.esm.js.map +1 -1
- package/dist/types/index.d.ts +15 -1
- package/dist/types/tsdoc-metadata.json +1 -1
- package/htmlvalidate/configs/index.js +5 -0
- package/htmlvalidate/configs/recommended.js +4 -0
- package/htmlvalidate/elements/elements.js +116 -0
- package/htmlvalidate/index.cjs +8 -0
- package/htmlvalidate/index.d.ts +4 -0
- package/package.json +8 -7
package/dist/esm/index.esm.js
CHANGED
|
@@ -2616,7 +2616,7 @@ const _hoisted_1$e = {
|
|
|
2616
2616
|
class: "table-ng__cell table-ng__cell--expand"
|
|
2617
2617
|
};
|
|
2618
2618
|
const _hoisted_2$a = ["aria-label", "aria-expanded"];
|
|
2619
|
-
const _hoisted_3$
|
|
2619
|
+
const _hoisted_3$7 = {
|
|
2620
2620
|
key: 1,
|
|
2621
2621
|
ref: "expandable",
|
|
2622
2622
|
tabindex: "-1",
|
|
@@ -2662,7 +2662,7 @@ const _sfc_main$g = /* @__PURE__ */ defineComponent({
|
|
|
2662
2662
|
}, [createVNode(unref(FIcon), {
|
|
2663
2663
|
class: "button__icon",
|
|
2664
2664
|
name: toggleIcon.value
|
|
2665
|
-
}, null, 8, ["name"])], 8, _hoisted_2$a)])) : (openBlock(), createElementBlock("td", _hoisted_3$
|
|
2665
|
+
}, null, 8, ["name"])], 8, _hoisted_2$a)])) : (openBlock(), createElementBlock("td", _hoisted_3$7, null, 512));
|
|
2666
2666
|
};
|
|
2667
2667
|
}
|
|
2668
2668
|
});
|
|
@@ -3080,7 +3080,7 @@ const _hoisted_1$b = {
|
|
|
3080
3080
|
scope: "col",
|
|
3081
3081
|
class: "table-ng__column table-ng__column--selectable"
|
|
3082
3082
|
};
|
|
3083
|
-
const _hoisted_2$9 = ["checked", "indeterminate"];
|
|
3083
|
+
const _hoisted_2$9 = ["checked", "indeterminate", "aria-label"];
|
|
3084
3084
|
const _sfc_main$d = /* @__PURE__ */ defineComponent({
|
|
3085
3085
|
__name: "ITableHeaderSelectable",
|
|
3086
3086
|
props: {
|
|
@@ -3095,9 +3095,13 @@ const _sfc_main$d = /* @__PURE__ */ defineComponent({
|
|
|
3095
3095
|
emit: __emit
|
|
3096
3096
|
}) {
|
|
3097
3097
|
const emit = __emit;
|
|
3098
|
+
const $t = useTranslate();
|
|
3098
3099
|
const indeterminate = computed(() => __props.state === "indeterminate");
|
|
3099
3100
|
const checked = computed(() => __props.state === "indeterminate" ? false : __props.state);
|
|
3100
3101
|
const expose = {};
|
|
3102
|
+
const ariaLabel = computed(() => {
|
|
3103
|
+
return !checked.value || indeterminate.value ? $t("fkui.ftable.select-all.aria-label", "Välj alla rader") : $t("fkui.ftable.unselect-all.aria-label", "Avmarkera alla rader");
|
|
3104
|
+
});
|
|
3101
3105
|
if (__props.selectable === "multi") {
|
|
3102
3106
|
const inputRef = useTemplateRef("input");
|
|
3103
3107
|
expose.tabstopEl = inputRef;
|
|
@@ -3110,7 +3114,7 @@ const _sfc_main$d = /* @__PURE__ */ defineComponent({
|
|
|
3110
3114
|
checked: checked.value,
|
|
3111
3115
|
indeterminate: indeterminate.value,
|
|
3112
3116
|
type: "checkbox",
|
|
3113
|
-
"aria-label":
|
|
3117
|
+
"aria-label": ariaLabel.value,
|
|
3114
3118
|
tabindex: "-1",
|
|
3115
3119
|
onChange: _cache[0] || (_cache[0] = ($event) => emit("toggle"))
|
|
3116
3120
|
}, null, 40, _hoisted_2$9)) : createCommentVNode("", true)]);
|
|
@@ -3122,7 +3126,7 @@ const _hoisted_1$a = {
|
|
|
3122
3126
|
class: "table-ng__cell table-ng__cell--checkbox"
|
|
3123
3127
|
};
|
|
3124
3128
|
const _hoisted_2$8 = ["checked", "aria-label"];
|
|
3125
|
-
const _hoisted_3$
|
|
3129
|
+
const _hoisted_3$6 = {
|
|
3126
3130
|
key: 1,
|
|
3127
3131
|
ref: "target",
|
|
3128
3132
|
tabindex: "-1",
|
|
@@ -3159,7 +3163,7 @@ const _sfc_main$c = /* @__PURE__ */ defineComponent({
|
|
|
3159
3163
|
"aria-label": ariaLabel.value,
|
|
3160
3164
|
tabindex: "-1",
|
|
3161
3165
|
onChange
|
|
3162
|
-
}, null, 40, _hoisted_2$8)])) : (openBlock(), createElementBlock("td", _hoisted_3$
|
|
3166
|
+
}, null, 40, _hoisted_2$8)])) : (openBlock(), createElementBlock("td", _hoisted_3$6, [createElementVNode("input", {
|
|
3163
3167
|
checked: Boolean(__props.column.checked(__props.row)),
|
|
3164
3168
|
type: "checkbox",
|
|
3165
3169
|
"aria-label": ariaLabel.value
|
|
@@ -3660,7 +3664,7 @@ const _hoisted_1$7 = {
|
|
|
3660
3664
|
class: "table-ng__cell table-ng__cell--anchor"
|
|
3661
3665
|
};
|
|
3662
3666
|
const _hoisted_2$6 = ["href"];
|
|
3663
|
-
const _hoisted_3$
|
|
3667
|
+
const _hoisted_3$5 = {
|
|
3664
3668
|
key: 1,
|
|
3665
3669
|
ref: "target",
|
|
3666
3670
|
tabindex: "-1",
|
|
@@ -3690,7 +3694,7 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
|
|
|
3690
3694
|
target: "_blank",
|
|
3691
3695
|
href: __props.column.href,
|
|
3692
3696
|
tabindex: "-1"
|
|
3693
|
-
}, toDisplayString(__props.column.text(__props.row)), 9, _hoisted_2$6)])) : (openBlock(), createElementBlock("td", _hoisted_3$
|
|
3697
|
+
}, toDisplayString(__props.column.text(__props.row)), 9, _hoisted_2$6)])) : (openBlock(), createElementBlock("td", _hoisted_3$5, null, 512));
|
|
3694
3698
|
};
|
|
3695
3699
|
}
|
|
3696
3700
|
});
|
|
@@ -3701,7 +3705,7 @@ const _hoisted_1$6 = {
|
|
|
3701
3705
|
const _hoisted_2$5 = {
|
|
3702
3706
|
class: "sr-only"
|
|
3703
3707
|
};
|
|
3704
|
-
const _hoisted_3$
|
|
3708
|
+
const _hoisted_3$4 = {
|
|
3705
3709
|
key: 1,
|
|
3706
3710
|
ref: "td",
|
|
3707
3711
|
tabindex: "-1",
|
|
@@ -3743,7 +3747,7 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
|
|
|
3743
3747
|
key: 0,
|
|
3744
3748
|
library: __props.column.iconLibrary,
|
|
3745
3749
|
name: __props.column.icon
|
|
3746
|
-
}, null, 8, ["library", "name"])) : createCommentVNode("", true), _cache[0] || (_cache[0] = createTextVNode()), createElementVNode("span", _hoisted_2$5, toDisplayString(__props.column.text(__props.row)), 1)], 512)])) : (openBlock(), createElementBlock("td", _hoisted_3$
|
|
3750
|
+
}, null, 8, ["library", "name"])) : createCommentVNode("", true), _cache[0] || (_cache[0] = createTextVNode()), createElementVNode("span", _hoisted_2$5, toDisplayString(__props.column.text(__props.row)), 1)], 512)])) : (openBlock(), createElementBlock("td", _hoisted_3$4, null, 512));
|
|
3747
3751
|
};
|
|
3748
3752
|
}
|
|
3749
3753
|
});
|
|
@@ -3789,13 +3793,9 @@ function requireEs_iterator_find() {
|
|
|
3789
3793
|
}
|
|
3790
3794
|
requireEs_iterator_find();
|
|
3791
3795
|
const _hoisted_1$5 = {
|
|
3792
|
-
key: 0,
|
|
3793
|
-
class: "table-ng__cell table-ng__cell--button"
|
|
3794
|
-
};
|
|
3795
|
-
const _hoisted_2$4 = {
|
|
3796
3796
|
class: "sr-only"
|
|
3797
3797
|
};
|
|
3798
|
-
const
|
|
3798
|
+
const _hoisted_2$4 = {
|
|
3799
3799
|
key: 1,
|
|
3800
3800
|
tabindex: "-1",
|
|
3801
3801
|
class: "table-ng__cell"
|
|
@@ -3857,7 +3857,12 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
|
3857
3857
|
__expose(expose);
|
|
3858
3858
|
return (_ctx, _cache) => {
|
|
3859
3859
|
var _buttonRef$value;
|
|
3860
|
-
return renderButton.value ? (openBlock(), createElementBlock("td",
|
|
3860
|
+
return renderButton.value ? (openBlock(), createElementBlock("td", {
|
|
3861
|
+
key: 0,
|
|
3862
|
+
class: normalizeClass(["table-ng__cell table-ng__cell--button", {
|
|
3863
|
+
"table-ng__cell--menu-open": isOpen.value
|
|
3864
|
+
}])
|
|
3865
|
+
}, [createElementVNode("button", {
|
|
3861
3866
|
ref: "button",
|
|
3862
3867
|
class: "icon-button",
|
|
3863
3868
|
type: "button",
|
|
@@ -3866,14 +3871,14 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
|
3866
3871
|
onClick: onOpen
|
|
3867
3872
|
}, [createVNode(unref(FIcon), {
|
|
3868
3873
|
name: "bars"
|
|
3869
|
-
}), _cache[0] || (_cache[0] = createTextVNode()), createElementVNode("span",
|
|
3874
|
+
}), _cache[0] || (_cache[0] = createTextVNode()), createElementVNode("span", _hoisted_1$5, toDisplayString(__props.column.text(__props.row)), 1)], 512), _cache[1] || (_cache[1] = createTextVNode()), createVNode(unref(FContextMenu), {
|
|
3870
3875
|
"is-open": isOpen.value,
|
|
3871
3876
|
items: menuitems.value,
|
|
3872
3877
|
anchor: (_buttonRef$value = buttonRef.value) !== null && _buttonRef$value !== void 0 ? _buttonRef$value : void 0,
|
|
3873
3878
|
onClose,
|
|
3874
3879
|
onSelect,
|
|
3875
3880
|
onFocusout
|
|
3876
|
-
}, null, 8, ["is-open", "items", "anchor"])])) : (openBlock(), createElementBlock("td",
|
|
3881
|
+
}, null, 8, ["is-open", "items", "anchor"])], 2)) : (openBlock(), createElementBlock("td", _hoisted_2$4));
|
|
3877
3882
|
};
|
|
3878
3883
|
}
|
|
3879
3884
|
});
|
|
@@ -3903,7 +3908,7 @@ const _hoisted_3$3 = ["aria-expanded", "aria-controls", "aria-activedescendant",
|
|
|
3903
3908
|
const _hoisted_4$3 = {
|
|
3904
3909
|
class: "table-ng__editable__text"
|
|
3905
3910
|
};
|
|
3906
|
-
const _hoisted_5$
|
|
3911
|
+
const _hoisted_5$2 = {
|
|
3907
3912
|
key: 1,
|
|
3908
3913
|
tabindex: "-1",
|
|
3909
3914
|
class: "table-ng__cell table-ng__cell--static"
|
|
@@ -4056,10 +4061,7 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
|
|
|
4056
4061
|
tabindex: "-1",
|
|
4057
4062
|
onKeydown: onCellKeyDown,
|
|
4058
4063
|
onClick: withModifiers(onCellClick, ["stop"])
|
|
4059
|
-
}, [withDirectives(createElementVNode("div", _hoisted_1$4, [createElementVNode("span", _hoisted_2$3, toDisplayString(viewValue.value), 1), _cache[3] || (_cache[3] = createTextVNode()),
|
|
4060
|
-
name: "arrow-down",
|
|
4061
|
-
class: "table-ng__editable__icon"
|
|
4062
|
-
})], 512), [[vShow, !editing.value]]), _cache[5] || (_cache[5] = createTextVNode()), withDirectives(createElementVNode("div", {
|
|
4064
|
+
}, [withDirectives(createElementVNode("div", _hoisted_1$4, [createElementVNode("span", _hoisted_2$3, toDisplayString(viewValue.value), 1)], 512), [[vShow, !editing.value]]), _cache[3] || (_cache[3] = createTextVNode()), withDirectives(createElementVNode("div", {
|
|
4063
4065
|
ref: "edit",
|
|
4064
4066
|
role: "combobox",
|
|
4065
4067
|
tabindex: "-1",
|
|
@@ -4075,10 +4077,7 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
|
|
|
4075
4077
|
}, ["prevent"])),
|
|
4076
4078
|
onKeydown: withModifiers(onEditKeyDown, ["stop"]),
|
|
4077
4079
|
onFocusout: _cache[2] || (_cache[2] = (e) => onEditBlur(e))
|
|
4078
|
-
}, [createElementVNode("span", _hoisted_4$3, toDisplayString(viewValue.value), 1), _cache[4] || (_cache[4] = createTextVNode()), createVNode(unref(
|
|
4079
|
-
name: "arrow-down",
|
|
4080
|
-
class: "table-ng__editable__icon--active"
|
|
4081
|
-
})], 40, _hoisted_3$3), [[vShow, editing.value]]), _cache[6] || (_cache[6] = createTextVNode()), withDirectives(createVNode(unref(IComboboxDropdown), {
|
|
4080
|
+
}, [createElementVNode("span", _hoisted_4$3, toDisplayString(viewValue.value), 1)], 40, _hoisted_3$3), [[vShow, editing.value]]), _cache[4] || (_cache[4] = createTextVNode()), withDirectives(createVNode(unref(IComboboxDropdown), {
|
|
4082
4081
|
id: unref(dropdownId),
|
|
4083
4082
|
"is-open": dropdownIsOpen.value,
|
|
4084
4083
|
options: __props.column.options,
|
|
@@ -4087,7 +4086,7 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
|
|
|
4087
4086
|
"input-node": editRef.value,
|
|
4088
4087
|
onSelect: selectDropdownOption,
|
|
4089
4088
|
onClose: onDropdownClose
|
|
4090
|
-
}, null, 8, ["id", "is-open", "options", "active-option", "active-option-id", "input-node"]), [[vShow, editing.value]])], 32)) : (openBlock(), createElementBlock("td", _hoisted_5$
|
|
4089
|
+
}, null, 8, ["id", "is-open", "options", "active-option", "active-option-id", "input-node"]), [[vShow, editing.value]])], 32)) : (openBlock(), createElementBlock("td", _hoisted_5$2, toDisplayString(__props.column.selected(__props.row)), 1));
|
|
4091
4090
|
};
|
|
4092
4091
|
}
|
|
4093
4092
|
});
|
|
@@ -4143,9 +4142,6 @@ const _hoisted_3$2 = {
|
|
|
4143
4142
|
class: "sr-only"
|
|
4144
4143
|
};
|
|
4145
4144
|
const _hoisted_4$2 = ["id", "aria-label"];
|
|
4146
|
-
const _hoisted_5$2 = {
|
|
4147
|
-
ref: "pen"
|
|
4148
|
-
};
|
|
4149
4145
|
const _sfc_main$4 = /* @__PURE__ */ defineComponent({
|
|
4150
4146
|
__name: "ITableText",
|
|
4151
4147
|
props: {
|
|
@@ -4235,7 +4231,6 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
|
|
|
4235
4231
|
});
|
|
4236
4232
|
const tdElement = useTemplateRef("td");
|
|
4237
4233
|
const inputElement = useTemplateRef("input");
|
|
4238
|
-
const penElement = useTemplateRef("pen");
|
|
4239
4234
|
const {
|
|
4240
4235
|
stopEdit: stopEdit2
|
|
4241
4236
|
} = useStartStopEdit();
|
|
@@ -4297,20 +4292,20 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
|
|
|
4297
4292
|
});
|
|
4298
4293
|
watchEffect(() => {
|
|
4299
4294
|
if (hasError.value) {
|
|
4300
|
-
var _tdElement$value,
|
|
4295
|
+
var _tdElement$value, _inputElement$value;
|
|
4301
4296
|
emit("onError", {
|
|
4302
4297
|
anchor: (_tdElement$value = tdElement.value) !== null && _tdElement$value !== void 0 ? _tdElement$value : void 0,
|
|
4303
|
-
arrowAnchor: (
|
|
4298
|
+
arrowAnchor: (_inputElement$value = inputElement.value) !== null && _inputElement$value !== void 0 ? _inputElement$value : void 0,
|
|
4304
4299
|
message: validity.value.validationMessage,
|
|
4305
4300
|
hasFocus: focused.value,
|
|
4306
4301
|
hasHover: isHovered.value,
|
|
4307
4302
|
inEdit: inEdit.value
|
|
4308
4303
|
});
|
|
4309
4304
|
} else {
|
|
4310
|
-
var _tdElement$value2,
|
|
4305
|
+
var _tdElement$value2, _inputElement$value2;
|
|
4311
4306
|
emit("closeError", {
|
|
4312
4307
|
anchor: (_tdElement$value2 = tdElement.value) !== null && _tdElement$value2 !== void 0 ? _tdElement$value2 : void 0,
|
|
4313
|
-
arrowAnchor: (
|
|
4308
|
+
arrowAnchor: (_inputElement$value2 = inputElement.value) !== null && _inputElement$value2 !== void 0 ? _inputElement$value2 : void 0,
|
|
4314
4309
|
message: validity.value.validationMessage,
|
|
4315
4310
|
hasFocus: focused.value,
|
|
4316
4311
|
hasHover: isHovered.value,
|
|
@@ -4485,14 +4480,11 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
|
|
|
4485
4480
|
}, {
|
|
4486
4481
|
onValidity,
|
|
4487
4482
|
onPendingValidity
|
|
4488
|
-
}), null, 16, _hoisted_4$2), [[vModelText, viewValue.value]]), _cache[3] || (_cache[3] = createTextVNode()),
|
|
4489
|
-
name: "pen",
|
|
4490
|
-
class: "table-ng__editable__icon"
|
|
4491
|
-
})], 512)], 2), _cache[4] || (_cache[4] = createTextVNode()), createVNode(unref(IPopupError), {
|
|
4483
|
+
}), null, 16, _hoisted_4$2), [[vModelText, viewValue.value]])], 2), _cache[3] || (_cache[3] = createTextVNode()), createVNode(unref(IPopupError), {
|
|
4492
4484
|
anchor: tdElement.value,
|
|
4493
4485
|
"is-open": openPopupError.value,
|
|
4494
4486
|
"error-message": validity.value.validationMessage,
|
|
4495
|
-
"arrow-anchor":
|
|
4487
|
+
"arrow-anchor": inputElement.value,
|
|
4496
4488
|
layout: "f-table"
|
|
4497
4489
|
}, null, 8, ["anchor", "is-open", "error-message", "arrow-anchor"])], 42, _hoisted_1$3)) : (openBlock(), createElementBlock("td", {
|
|
4498
4490
|
key: 1,
|
|
@@ -5129,6 +5121,9 @@ const _sfc_main$3 = /* @__PURE__ */ defineComponent({
|
|
|
5129
5121
|
striped: {
|
|
5130
5122
|
type: Boolean
|
|
5131
5123
|
},
|
|
5124
|
+
disableDividers: {
|
|
5125
|
+
type: Boolean
|
|
5126
|
+
},
|
|
5132
5127
|
selectable: {
|
|
5133
5128
|
default: () => void 0
|
|
5134
5129
|
}
|
|
@@ -5176,7 +5171,10 @@ const _sfc_main$3 = /* @__PURE__ */ defineComponent({
|
|
|
5176
5171
|
});
|
|
5177
5172
|
const columns = computed(() => normalizeTableColumns(__props.columns));
|
|
5178
5173
|
const tableClasses = computed(() => {
|
|
5179
|
-
return
|
|
5174
|
+
return ["table-ng", {
|
|
5175
|
+
"table-ng--striped": __props.striped,
|
|
5176
|
+
"table-ng--divided": !__props.disableDividers
|
|
5177
|
+
}];
|
|
5180
5178
|
});
|
|
5181
5179
|
const slots = useSlots();
|
|
5182
5180
|
const hasExpandableSlot = computed(() => {
|