@citruslime/ui 2.0.0-beta.19 → 2.0.0-beta.22
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 +1 -1
- package/dist/citrus-lime-ui.es.js +48 -43
- package/dist/citrus-lime-ui.umd.js +2 -2
- package/dist/components/accordion/cl-ui-accordion.vue.d.ts +7 -5
- package/dist/components/accordion/item/cl-ui-accordion-item.vue.d.ts +11 -7
- package/dist/components/app/cl-ui-app.vue.d.ts +19 -12
- package/dist/components/button/cl-ui-button.vue.d.ts +22 -11
- package/dist/components/card/cl-ui-card.vue.d.ts +12 -7
- package/dist/components/combo-box/cl-ui-combo-box.vue.d.ts +193 -92
- package/dist/components/combo-box/search-container/cl-ui-combo-box-search.vue.d.ts +89 -43
- package/dist/components/combo-box/search-container/header/cl-ui-combo-box-header.vue.d.ts +17 -9
- package/dist/components/combo-box/search-container/selectable/cl-ui-combo-box-selectable.vue.d.ts +26 -13
- package/dist/components/grid/cell/cl-ui-grid-cell.vue.d.ts +15 -9
- package/dist/components/grid/cl-ui-grid.vue.d.ts +151 -85
- package/dist/components/grid/filter/cl-ui-grid-filter.vue.d.ts +15 -9
- package/dist/components/grid/footer/cl-ui-grid-footer.vue.d.ts +11 -7
- package/dist/components/grid/header/cl-ui-grid-header.vue.d.ts +69 -38
- package/dist/components/grid/view-manager/cl-ui-grid-view-manager.vue.d.ts +28 -16
- package/dist/components/header/menu/cl-ui-header-menu.vue.d.ts +17 -9
- package/dist/components/language-switcher/cl-ui-language-switcher.vue.d.ts +11 -7
- package/dist/components/login/cl-ui-login.vue.d.ts +34 -18
- package/dist/components/modal/cl-ui-modal.vue.d.ts +17 -9
- package/dist/components/navigation/cl-ui-navigation.vue.d.ts +1 -1
- package/dist/components/navigation/group/cl-ui-navigation-group.vue.d.ts +6 -5
- package/dist/components/navigation/icon/cl-ui-navigation-icon.vue.d.ts +10 -7
- package/dist/components/notification/cl-ui-notification.vue.d.ts +12 -7
- package/dist/components/slider/cl-ui-slider.vue.d.ts +34 -17
- package/dist/style.css +1 -1
- package/package.json +4 -4
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Citrus-Lime UI
|
|
2
2
|
|
|
3
|
-
A Vue 3 UI library
|
|
3
|
+
A Vue 3 UI library, which is used across Citrus-Lime web apps.
|
|
4
4
|
|
|
5
5
|

|
|
6
6
|

|
|
@@ -1154,6 +1154,7 @@ function getFormattedTimeForMinMax(date) {
|
|
|
1154
1154
|
return formatted;
|
|
1155
1155
|
}
|
|
1156
1156
|
var clUiCalendar_vue_vue_type_style_index_0_lang = "";
|
|
1157
|
+
var clUiCalendar_vue_vue_type_style_index_1_scoped_true_lang = "";
|
|
1157
1158
|
const _hoisted_1$m = ["placeholder", "disabled"];
|
|
1158
1159
|
const _hoisted_2$l = { class: "cl-absolute cl-bg-white cl-flex cl-right-2 cl-text-grey-4 cl-top-3.5" };
|
|
1159
1160
|
const _sfc_main$n = /* @__PURE__ */ defineComponent({
|
|
@@ -1383,6 +1384,7 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
|
|
|
1383
1384
|
};
|
|
1384
1385
|
}
|
|
1385
1386
|
});
|
|
1387
|
+
var clUiCalendar = /* @__PURE__ */ _export_sfc(_sfc_main$n, [["__scopeId", "data-v-533d446d"]]);
|
|
1386
1388
|
const calendarTypes = [
|
|
1387
1389
|
"date",
|
|
1388
1390
|
"datetime",
|
|
@@ -1553,7 +1555,7 @@ function getInputTypeAsCalendarType(type) {
|
|
|
1553
1555
|
return calendarType;
|
|
1554
1556
|
}
|
|
1555
1557
|
var clUiInput_vue_vue_type_style_index_0_scoped_true_lang = "";
|
|
1556
|
-
const _hoisted_1$k = { class: "cl-align-top cl-border-none cl-inline-block cl-
|
|
1558
|
+
const _hoisted_1$k = { class: "cl-align-top cl-border-none cl-inline-block cl-text-left" };
|
|
1557
1559
|
const _hoisted_2$j = { class: "cl-flex cl-justify-between" };
|
|
1558
1560
|
const _hoisted_3$f = { class: "cl-w-full" };
|
|
1559
1561
|
const _hoisted_4$b = {
|
|
@@ -1564,12 +1566,12 @@ const _hoisted_5$8 = {
|
|
|
1564
1566
|
key: 1,
|
|
1565
1567
|
class: "cl-bg-danger-light cl-block cl-max-h-6 cl-mb-1 cl-ml-2 cl-px-2 cl-rounded-md cl-text-center cl-text-danger-default cl-text-xs cl-uppercase"
|
|
1566
1568
|
};
|
|
1567
|
-
const _hoisted_6$6 = ["type", "disabled", "min", "max", "minlength", "maxlength", "step", "placeholder", "accept", "name", "autocomplete", "onBlur"
|
|
1568
|
-
const _hoisted_7$6 = {
|
|
1569
|
-
const _hoisted_8$5 = {
|
|
1569
|
+
const _hoisted_6$6 = ["type", "disabled", "min", "max", "minlength", "maxlength", "step", "placeholder", "accept", "name", "autocomplete", "onBlur"];
|
|
1570
|
+
const _hoisted_7$6 = {
|
|
1570
1571
|
key: 2,
|
|
1571
1572
|
class: "cl-h-[5.78rem] cl-pb-2 md:cl-h-20"
|
|
1572
1573
|
};
|
|
1574
|
+
const _hoisted_8$5 = { class: "cl-relative" };
|
|
1573
1575
|
const _hoisted_9$5 = {
|
|
1574
1576
|
key: 0,
|
|
1575
1577
|
class: "cl-bg-primary-lighter cl-px-2 cl-rounded-md cl-text-center cl-text-secondary-light cl-text-xs cl-w-auto cl-whitespace-pre-line"
|
|
@@ -1586,7 +1588,7 @@ const _sfc_main$l = /* @__PURE__ */ defineComponent({
|
|
|
1586
1588
|
isRequired: { type: Boolean, default: false },
|
|
1587
1589
|
customValidationFunction: { type: Function, default: void 0 },
|
|
1588
1590
|
onInputFunction: { type: Function, default: void 0 },
|
|
1589
|
-
min: { default:
|
|
1591
|
+
min: { default: 0 },
|
|
1590
1592
|
max: { default: 1e11 },
|
|
1591
1593
|
step: { default: 1 },
|
|
1592
1594
|
validateImmediately: { type: Boolean, default: false },
|
|
@@ -1679,7 +1681,7 @@ const _sfc_main$l = /* @__PURE__ */ defineComponent({
|
|
|
1679
1681
|
}
|
|
1680
1682
|
Promise.all(validationPromises).then((internalValidationResults) => {
|
|
1681
1683
|
const messages2 = [...internalValidationResults.map((e) => e.message)];
|
|
1682
|
-
let invalid = internalValidationResults.some((e) => e.valid === false) || props.externalErrors.length > 0;
|
|
1684
|
+
let invalid = internalValidationResults.some((e) => e.message.length > 0 && e.valid === false) || props.externalErrors.length > 0;
|
|
1683
1685
|
if (dateFlaggedAsOutOfRange.value) {
|
|
1684
1686
|
messages2.push(t2("input.dateOutOfRange"));
|
|
1685
1687
|
invalid = true;
|
|
@@ -1814,12 +1816,14 @@ const _sfc_main$l = /* @__PURE__ */ defineComponent({
|
|
|
1814
1816
|
onClick: _cache[1] || (_cache[1] = ($event) => emitClickIfButton($event)),
|
|
1815
1817
|
onFocus: _cache[2] || (_cache[2] = ($event) => emit("focus")),
|
|
1816
1818
|
onBlur: withModifiers(onLostFocus, ["self"]),
|
|
1817
|
-
|
|
1818
|
-
onInput: _cache[3] || (_cache[3] = ($event) =>
|
|
1819
|
+
onMousewheelPassive: onMouseWheel,
|
|
1820
|
+
onInput: _cache[3] || (_cache[3] = ($event) => {
|
|
1821
|
+
emit("input", $event);
|
|
1822
|
+
_ctx.$forceUpdate();
|
|
1823
|
+
})
|
|
1819
1824
|
}), null, 16, _hoisted_6$6)), [
|
|
1820
1825
|
[vModelDynamic, unref(currentValue)]
|
|
1821
|
-
]) :
|
|
1822
|
-
unref(isInputCalendarSupportedDate)(__props.inputType) ? (openBlock(), createBlock(unref(_sfc_main$n), mergeProps({ key: 1 }, _ctx.$attrs, {
|
|
1826
|
+
]) : unref(isInputCalendarSupportedDate)(__props.inputType) ? (openBlock(), createBlock(unref(clUiCalendar), mergeProps({ key: 1 }, _ctx.$attrs, {
|
|
1823
1827
|
ref_key: "inputElement",
|
|
1824
1828
|
ref: inputElement,
|
|
1825
1829
|
date: unref(currentDateValue),
|
|
@@ -1836,8 +1840,22 @@ const _sfc_main$l = /* @__PURE__ */ defineComponent({
|
|
|
1836
1840
|
onBlur: withModifiers(onLostFocus, ["self"]),
|
|
1837
1841
|
onValueOutOfRange: onDateOutOfRange,
|
|
1838
1842
|
onFocus: _cache[5] || (_cache[5] = ($event) => emit("focus"))
|
|
1839
|
-
}), null, 16, ["date", "class", "disabled", "type", "min", "max", "onBlur"])) :
|
|
1840
|
-
|
|
1843
|
+
}), null, 16, ["date", "class", "disabled", "type", "min", "max", "onBlur"])) : __props.inputType === "range" && typeof unref(currentValue) === "number" ? (openBlock(), createElementBlock("div", _hoisted_7$6, [
|
|
1844
|
+
createVNode(unref(clUiSlider), {
|
|
1845
|
+
ref_key: "inputElement",
|
|
1846
|
+
ref: inputElement,
|
|
1847
|
+
value: unref(currentValue),
|
|
1848
|
+
"onUpdate:value": _cache[6] || (_cache[6] = ($event) => isRef(currentValue) ? currentValue.value = $event : null),
|
|
1849
|
+
min: unref(minAsNumber),
|
|
1850
|
+
max: unref(maxAsNumber),
|
|
1851
|
+
step: __props.step,
|
|
1852
|
+
disabled: __props.disabled,
|
|
1853
|
+
"show-numeric-input": false,
|
|
1854
|
+
onBlur: withModifiers(onLostFocus, ["self"]),
|
|
1855
|
+
onFocus: _cache[7] || (_cache[7] = ($event) => emit("focus"))
|
|
1856
|
+
}, null, 8, ["value", "min", "max", "step", "disabled", "onBlur"])
|
|
1857
|
+
])) : createCommentVNode("", true),
|
|
1858
|
+
createElementVNode("div", _hoisted_8$5, [
|
|
1841
1859
|
__props.inputType === "number" && !__props.disabled && __props.showArrows ? (openBlock(), createElementBlock("div", {
|
|
1842
1860
|
key: 0,
|
|
1843
1861
|
class: normalizeClass(["cl-absolute cl-duration-300 cl-right-1 cl-transition", {
|
|
@@ -1849,7 +1867,7 @@ const _sfc_main$l = /* @__PURE__ */ defineComponent({
|
|
|
1849
1867
|
icon: "ph:caret-up-bold",
|
|
1850
1868
|
class: "cl-bg-link-default cl-rounded-md cl-text-sm cl-text-white hover:cl-bg-link-light hover:cl-cursor-pointer",
|
|
1851
1869
|
onClick: incrementNumericValue,
|
|
1852
|
-
onMousedown: _cache[
|
|
1870
|
+
onMousedown: _cache[8] || (_cache[8] = withModifiers(() => {
|
|
1853
1871
|
}, ["prevent"]))
|
|
1854
1872
|
})
|
|
1855
1873
|
], 2)) : createCommentVNode("", true),
|
|
@@ -1863,26 +1881,11 @@ const _sfc_main$l = /* @__PURE__ */ defineComponent({
|
|
|
1863
1881
|
icon: "ph:caret-down-bold",
|
|
1864
1882
|
class: "cl-bg-link-default cl-rounded-md cl-text-sm cl-text-white hover:cl-bg-link-light hover:cl-cursor-pointer",
|
|
1865
1883
|
onClick: decrementNumericValue,
|
|
1866
|
-
onMousedown: _cache[
|
|
1884
|
+
onMousedown: _cache[9] || (_cache[9] = withModifiers(() => {
|
|
1867
1885
|
}, ["prevent"]))
|
|
1868
1886
|
})
|
|
1869
1887
|
], 2)) : createCommentVNode("", true)
|
|
1870
|
-
])
|
|
1871
|
-
__props.inputType === "range" && typeof unref(currentValue) === "number" ? (openBlock(), createElementBlock("div", _hoisted_8$5, [
|
|
1872
|
-
createVNode(unref(clUiSlider), {
|
|
1873
|
-
ref_key: "inputElement",
|
|
1874
|
-
ref: inputElement,
|
|
1875
|
-
value: unref(currentValue),
|
|
1876
|
-
"onUpdate:value": _cache[8] || (_cache[8] = ($event) => isRef(currentValue) ? currentValue.value = $event : null),
|
|
1877
|
-
min: unref(minAsNumber),
|
|
1878
|
-
max: unref(maxAsNumber),
|
|
1879
|
-
step: __props.step,
|
|
1880
|
-
disabled: __props.disabled,
|
|
1881
|
-
"show-numeric-input": false,
|
|
1882
|
-
onBlur: withModifiers(onLostFocus, ["self"]),
|
|
1883
|
-
onFocus: _cache[9] || (_cache[9] = ($event) => emit("focus"))
|
|
1884
|
-
}, null, 8, ["value", "min", "max", "step", "disabled", "onBlur"])
|
|
1885
|
-
])) : createCommentVNode("", true)
|
|
1888
|
+
])
|
|
1886
1889
|
], 32),
|
|
1887
1890
|
isValid.value && unref(validMessage) ? (openBlock(), createElementBlock("div", _hoisted_9$5, toDisplayString(unref(validMessage)), 1)) : createCommentVNode("", true),
|
|
1888
1891
|
!isValid.value && unref(errors).length > 0 ? (openBlock(), createElementBlock("div", _hoisted_10$5, toDisplayString(unref(errors)), 1)) : createCommentVNode("", true)
|
|
@@ -1890,7 +1893,7 @@ const _sfc_main$l = /* @__PURE__ */ defineComponent({
|
|
|
1890
1893
|
};
|
|
1891
1894
|
}
|
|
1892
1895
|
});
|
|
1893
|
-
var ClUiInput = /* @__PURE__ */ _export_sfc(_sfc_main$l, [["__scopeId", "data-v-
|
|
1896
|
+
var ClUiInput = /* @__PURE__ */ _export_sfc(_sfc_main$l, [["__scopeId", "data-v-007f3e50"]]);
|
|
1894
1897
|
const _hoisted_1$j = { class: "cl-align-items-center cl-bg-black cl-bg-opacity-40 cl-bottom-0 cl-fixed cl-flex cl-h-screen cl-justify-center cl-left-0 cl-right-0 cl-top-0 cl-w-full cl-z-40" };
|
|
1895
1898
|
const _hoisted_2$i = ["onKeypress"];
|
|
1896
1899
|
const _hoisted_3$e = { class: "cl-overflow-y-auto cl-p-2 cl-w-full" };
|
|
@@ -1957,10 +1960,10 @@ const _sfc_main$k = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues
|
|
|
1957
1960
|
"cl-bg-primary-default cl-text-white": __props.headerColour === "primary"
|
|
1958
1961
|
}])
|
|
1959
1962
|
}, [
|
|
1960
|
-
renderSlot(_ctx.$slots, "title"
|
|
1963
|
+
renderSlot(_ctx.$slots, "title")
|
|
1961
1964
|
], 2),
|
|
1962
1965
|
createElementVNode("div", _hoisted_3$e, [
|
|
1963
|
-
renderSlot(_ctx.$slots, "default")
|
|
1966
|
+
renderSlot(_ctx.$slots, "default", normalizeProps(guardReactiveProps({ close })))
|
|
1964
1967
|
]),
|
|
1965
1968
|
renderSlot(_ctx.$slots, "footer", normalizeProps(guardReactiveProps({ close })))
|
|
1966
1969
|
], 16)
|
|
@@ -3030,7 +3033,7 @@ const _sfc_main$d = /* @__PURE__ */ defineComponent({
|
|
|
3030
3033
|
const _component_icon = resolveComponent("icon");
|
|
3031
3034
|
return __props.column.filterable === void 0 || __props.column.filterable === true ? (openBlock(), createElementBlock("div", {
|
|
3032
3035
|
key: 0,
|
|
3033
|
-
class: normalizeClass(["cl-border-grey-2 cl-flex cl-rounded cl-w-full", {
|
|
3036
|
+
class: normalizeClass(["cl-border-grey-2 cl-flex cl-h-[2.6rem] cl-rounded cl-w-full", {
|
|
3034
3037
|
"cl-border-b cl-p-5": __props.column.type === "slot" && (__props.column.slotType === void 0 || __props.column.field === void 0),
|
|
3035
3038
|
"cl-border": __props.column.type !== "slot" || __props.column.slotType !== void 0 && __props.column.field !== void 0
|
|
3036
3039
|
}])
|
|
@@ -3157,7 +3160,7 @@ const _sfc_main$c = /* @__PURE__ */ defineComponent({
|
|
|
3157
3160
|
const currentPage = ref(props.request.pageNumber);
|
|
3158
3161
|
const totalPages = computed(() => {
|
|
3159
3162
|
var _a, _b;
|
|
3160
|
-
return props.data !== null ? Math.ceil((_b = (_a = props.data) == null ? void 0 : _a.totalRecords) != null ? _b : 0 / props.request.pageSize) : 1;
|
|
3163
|
+
return props.data !== null ? Math.ceil(((_b = (_a = props.data) == null ? void 0 : _a.totalRecords) != null ? _b : 0) / props.request.pageSize) : 1;
|
|
3161
3164
|
});
|
|
3162
3165
|
const pageNumbers = computed(() => {
|
|
3163
3166
|
const calculatedPageNumbers = Array.from(Array(totalPages.value + 1).keys());
|
|
@@ -3197,7 +3200,7 @@ const _sfc_main$c = /* @__PURE__ */ defineComponent({
|
|
|
3197
3200
|
createVNode(ClUiInput, {
|
|
3198
3201
|
modelValue: currentPage.value,
|
|
3199
3202
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => currentPage.value = $event),
|
|
3200
|
-
class: "
|
|
3203
|
+
class: "cl-ml-1 cl-mt-0.5 cl-text-sm",
|
|
3201
3204
|
"input-type": "number",
|
|
3202
3205
|
label: "Page",
|
|
3203
3206
|
"show-label": false,
|
|
@@ -3291,7 +3294,7 @@ const _sfc_main$c = /* @__PURE__ */ defineComponent({
|
|
|
3291
3294
|
};
|
|
3292
3295
|
}
|
|
3293
3296
|
});
|
|
3294
|
-
const _hoisted_1$a = { class: "cl-fixed cl-flex cl-h-full cl-justify-end cl-right-0 cl-shadow-lg cl-top-0 cl-z-
|
|
3297
|
+
const _hoisted_1$a = { class: "cl-fixed cl-flex cl-h-full cl-justify-end cl-right-0 cl-shadow-lg cl-top-0 cl-z-50" };
|
|
3295
3298
|
const _hoisted_2$9 = { class: "cl-bg-secondary-default cl-h-full cl-overflow-y-auto cl-px-10 cl-py-20 cl-relative cl-text-grey-2 cl-w-80" };
|
|
3296
3299
|
const _hoisted_3$7 = { class: "cl-mb-4 cl-text-2xl cl-text-off-white" };
|
|
3297
3300
|
const _hoisted_4$5 = { class: "cl-border-grey-3 cl-border-t cl-flex cl-flex-wrap cl-text-sm cl-w-full" };
|
|
@@ -4135,18 +4138,18 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
|
|
|
4135
4138
|
modelModifiers: { trim: true },
|
|
4136
4139
|
class: "!cl-border-2 !cl-mb-1 cl-w-full",
|
|
4137
4140
|
"input-type": "email",
|
|
4138
|
-
"highlight-when-valid":
|
|
4139
|
-
label: "
|
|
4141
|
+
"highlight-when-valid": username.value !== void 0 && username.value !== "",
|
|
4142
|
+
label: unref(t2)("login.username"),
|
|
4140
4143
|
"show-label": false,
|
|
4141
4144
|
"placeholder-text": unref(t2)("login.email"),
|
|
4142
4145
|
autocomplete: "username",
|
|
4143
4146
|
"validate-immediately": true,
|
|
4144
4147
|
"custom-validation-function": emptyIsInvalidValidation,
|
|
4145
4148
|
"input-specific-classes": "!cl-pl-9",
|
|
4146
|
-
"message-when-valid": unref(t2)("login.validEmail"),
|
|
4149
|
+
"message-when-valid": username.value ? unref(t2)("login.validEmail") : "",
|
|
4147
4150
|
onInput: clearErrors,
|
|
4148
4151
|
onValidated: onUsernameValidated
|
|
4149
|
-
}, null, 8, ["modelValue", "placeholder-text", "message-when-valid"])
|
|
4152
|
+
}, null, 8, ["modelValue", "highlight-when-valid", "label", "placeholder-text", "message-when-valid"])
|
|
4150
4153
|
])
|
|
4151
4154
|
]),
|
|
4152
4155
|
createElementVNode("div", _hoisted_8, [
|
|
@@ -4177,14 +4180,16 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
|
|
|
4177
4180
|
"onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => password.value = $event),
|
|
4178
4181
|
class: "!cl-border-2 cl-w-full",
|
|
4179
4182
|
"input-type": passwordFieldType.value,
|
|
4180
|
-
"highlight-when-valid":
|
|
4183
|
+
"highlight-when-valid": password.value !== void 0 && password.value !== "",
|
|
4184
|
+
label: unref(t2)("login.password"),
|
|
4185
|
+
"show-label": false,
|
|
4181
4186
|
"placeholder-text": unref(t2)("login.password"),
|
|
4182
4187
|
autocomplete: "current-password",
|
|
4183
4188
|
"validate-immediately": true,
|
|
4184
4189
|
"input-specific-classes": "!cl-pl-9 !cl-pr-9",
|
|
4185
4190
|
"custom-validation-function": emptyIsInvalidValidation,
|
|
4186
4191
|
onInput: clearErrors
|
|
4187
|
-
}, null, 8, ["modelValue", "input-type", "placeholder-text"])
|
|
4192
|
+
}, null, 8, ["modelValue", "input-type", "highlight-when-valid", "label", "placeholder-text"])
|
|
4188
4193
|
])
|
|
4189
4194
|
]),
|
|
4190
4195
|
createElementVNode("div", {
|