@leaflink/stash 44.0.0-beta.1 → 44.0.0-beta.10
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 +107 -39
- package/dist/ActionsDropdown.js +25 -25
- package/dist/ActionsDropdown.js.map +1 -1
- package/dist/AddressSelect.js +12 -11
- package/dist/AddressSelect.js.map +1 -1
- package/dist/Alert.js +9 -9
- package/dist/Alert.js.map +1 -1
- package/dist/AppNavigationItem.js +22 -22
- package/dist/AppNavigationItem.js.map +1 -1
- package/dist/AppSidebar.js +11 -11
- package/dist/AppSidebar.js.map +1 -1
- package/dist/AppTopbar.js +12 -12
- package/dist/Avatar.js +12 -12
- package/dist/Avatar.js.map +1 -1
- package/dist/Backdrop.js +1 -1
- package/dist/Backdrop.js.map +1 -1
- package/dist/Badge.js +12 -12
- package/dist/Badge.js.map +1 -1
- package/dist/Badge.vue.d.ts +1 -1
- package/dist/Button.js +1 -1
- package/dist/Button.js.map +1 -1
- package/dist/Button.vue_used_vue_type_style_index_0_lang.module-63d31dc0.js +17 -0
- package/dist/Button.vue_used_vue_type_style_index_0_lang.module-63d31dc0.js.map +1 -0
- package/dist/ButtonGroup.js +28 -28
- package/dist/ButtonGroup.js.map +1 -1
- package/dist/Card.js +3 -3
- package/dist/Card.js.map +1 -1
- package/dist/CardHeader.js +3 -3
- package/dist/CardMedia.js +1 -1
- package/dist/CardMedia.js.map +1 -1
- package/dist/Carousel.js +260 -248
- package/dist/Carousel.js.map +1 -1
- package/dist/Checkbox.js +58 -46
- package/dist/Checkbox.js.map +1 -1
- package/dist/Checkbox.vue.d.ts +2 -0
- package/dist/Checkbox.vue_used_vue_type_style_index_0_lang.module-fa8d9c06.js +9 -0
- package/dist/Checkbox.vue_used_vue_type_style_index_0_lang.module-fa8d9c06.js.map +1 -0
- package/dist/ChevronToggle.js +1 -1
- package/dist/Chip.js +1 -1
- package/dist/Chip.js.map +1 -1
- package/dist/ConfirmationCodeInput.js +21 -21
- package/dist/ConfirmationCodeInput.js.map +1 -1
- package/dist/ContextSwitcher.js +6 -5
- package/dist/ContextSwitcher.js.map +1 -1
- package/dist/Copy.js +1 -1
- package/dist/CurrencyInput.js +2 -2
- package/dist/DataView.js +1 -1
- package/dist/DataViewFilters.js +7 -7
- package/dist/DataViewFilters.js.map +1 -1
- package/dist/DataViewSortButton.js +47 -38
- package/dist/DataViewSortButton.js.map +1 -1
- package/dist/DataViewToolbar.js +4 -4
- package/dist/DataViewToolbar.js.map +1 -1
- package/dist/DatePicker.js +12 -15
- package/dist/DatePicker.js.map +1 -1
- package/dist/DescriptionListTerm.js +8 -8
- package/dist/DescriptionListTerm.js.map +1 -1
- package/dist/Dialog.js +46 -46
- package/dist/Dialog.js.map +1 -1
- package/dist/Divider.js +9 -9
- package/dist/Divider.js.map +1 -1
- package/dist/Dropdown.js +17 -17
- package/dist/Dropdown.js.map +1 -1
- package/dist/EmptyState.js +1 -1
- package/dist/EmptyState.js.map +1 -1
- package/dist/Expand.js +1 -1
- package/dist/{Expand.vue_vue_type_script_setup_true_lang-5fe03d51.js → Expand.vue_vue_type_script_setup_true_lang-1751f4a6.js} +14 -15
- package/dist/Expand.vue_vue_type_script_setup_true_lang-1751f4a6.js.map +1 -0
- package/dist/Field.js +2 -2
- package/dist/Field.vue.d.ts +1 -1
- package/dist/{Field.vue_vue_type_script_setup_true_lang-475832fe.js → Field.vue_vue_type_script_setup_true_lang-42ba3c5a.js} +5 -5
- package/dist/Field.vue_vue_type_script_setup_true_lang-42ba3c5a.js.map +1 -0
- package/dist/FileUpload.js +49 -47
- package/dist/FileUpload.js.map +1 -1
- package/dist/FilterChip.js +20 -20
- package/dist/FilterChip.js.map +1 -1
- package/dist/FilterDrawerItem.js +4 -4
- package/dist/FilterDrawerItem.js.map +1 -1
- package/dist/FilterDropdown.js +19 -19
- package/dist/FilterDropdown.js.map +1 -1
- package/dist/FilterSelect.js +27 -27
- package/dist/FilterSelect.js.map +1 -1
- package/dist/Filters.js +51 -50
- package/dist/Filters.js.map +1 -1
- package/dist/HttpError.js +28 -28
- package/dist/HttpError.js.map +1 -1
- package/dist/IconLabel.js +17 -17
- package/dist/IconLabel.js.map +1 -1
- package/dist/IconLabel.vue.d.ts +1 -1
- package/dist/Illustration.js +10 -60
- package/dist/Illustration.js.map +1 -1
- package/dist/Illustration.vue_vue_type_script_setup_true_lang-d6a94e17.js +56 -0
- package/dist/Illustration.vue_vue_type_script_setup_true_lang-d6a94e17.js.map +1 -0
- package/dist/Image.js +67 -72
- package/dist/Image.js.map +1 -1
- package/dist/InlineEdit.js +3 -3
- package/dist/InlineEdit.js.map +1 -1
- package/dist/Input.js +43 -43
- package/dist/Input.js.map +1 -1
- package/dist/InputOptions.js +34 -33
- package/dist/InputOptions.js.map +1 -1
- package/dist/Label.js +1 -1
- package/dist/Label.vue.d.ts +13 -2
- package/dist/Label.vue_vue_type_script_setup_true_lang-4b02087f.js +38 -0
- package/dist/Label.vue_vue_type_script_setup_true_lang-4b02087f.js.map +1 -0
- package/dist/ListItem.js +16 -15
- package/dist/ListItem.js.map +1 -1
- package/dist/ListItemCell.js +9 -9
- package/dist/ListItemCell.js.map +1 -1
- package/dist/ListView.js +143 -139
- package/dist/ListView.js.map +1 -1
- package/dist/Loading.js +17 -10
- package/dist/Loading.js.map +1 -1
- package/dist/Loading.vue_used_vue_type_style_index_0_lang.module-ef5a3bc6.js +8 -0
- package/dist/Loading.vue_used_vue_type_style_index_0_lang.module-ef5a3bc6.js.map +1 -0
- package/dist/Menu.js +1 -1
- package/dist/Menu.js.map +1 -1
- package/dist/MenuItem.js +20 -14
- package/dist/MenuItem.js.map +1 -1
- package/dist/Metric.js +4 -4
- package/dist/Metric.js.map +1 -1
- package/dist/Modal.js +21 -21
- package/dist/Modal.js.map +1 -1
- package/dist/Modals.js +13 -13
- package/dist/Modals.js.map +1 -1
- package/dist/Module.js +2 -2
- package/dist/Module.js.map +1 -1
- package/dist/ModuleContent.js +2 -2
- package/dist/ModuleContent.js.map +1 -1
- package/dist/ModuleFooter.js +11 -11
- package/dist/ModuleFooter.js.map +1 -1
- package/dist/ModuleHeader.js +6 -6
- package/dist/ModuleHeader.js.map +1 -1
- package/dist/ObfuscateText.js +30 -32
- package/dist/ObfuscateText.js.map +1 -1
- package/dist/ObfuscateText.vue.d.ts +1 -1
- package/dist/PageContent.js +9 -9
- package/dist/PageContent.js.map +1 -1
- package/dist/PageHeader.js +24 -24
- package/dist/PageHeader.js.map +1 -1
- package/dist/PageNavigation.js +3 -3
- package/dist/PageNavigation.js.map +1 -1
- package/dist/Paginate.js +1 -1
- package/dist/Paginate.js.map +1 -1
- package/dist/Paginate.vue_used_vue_type_style_index_0_lang.module-18343da7.js +11 -0
- package/dist/Paginate.vue_used_vue_type_style_index_0_lang.module-18343da7.js.map +1 -0
- package/dist/QuickAction.js +20 -17
- package/dist/QuickAction.js.map +1 -1
- package/dist/Radio.js +30 -15
- package/dist/Radio.js.map +1 -1
- package/dist/RadioGroup.js +177 -148
- package/dist/RadioGroup.js.map +1 -1
- package/dist/RadioNew.js +118 -91
- package/dist/RadioNew.js.map +1 -1
- package/dist/SearchBar.js +27 -27
- package/dist/SearchBar.js.map +1 -1
- package/dist/Select.js +189 -188
- package/dist/Select.js.map +1 -1
- package/dist/SelectStatus.js +22 -21
- package/dist/SelectStatus.js.map +1 -1
- package/dist/Step.js +37 -37
- package/dist/Step.js.map +1 -1
- package/dist/Switch.js +44 -36
- package/dist/Switch.js.map +1 -1
- package/dist/Tab.js +3 -2
- package/dist/Tab.js.map +1 -1
- package/dist/{Tab.vue_vue_type_script_setup_true_lang-b810bee8.js → Tab.vue_vue_type_script_setup_true_lang-69d1b046.js} +23 -22
- package/dist/Tab.vue_vue_type_script_setup_true_lang-69d1b046.js.map +1 -0
- package/dist/Table.js +23 -22
- package/dist/Table.js.map +1 -1
- package/dist/Table.keys-cf93df19.js +27 -0
- package/dist/{Table.keys-1ebe4ecb.js.map → Table.keys-cf93df19.js.map} +1 -1
- package/dist/TableCell.js +24 -23
- package/dist/TableCell.js.map +1 -1
- package/dist/TableHeaderCell.js +37 -36
- package/dist/TableHeaderCell.js.map +1 -1
- package/dist/TableHeaderRow.js +13 -12
- package/dist/TableHeaderRow.js.map +1 -1
- package/dist/TableRow.js +36 -34
- package/dist/TableRow.js.map +1 -1
- package/dist/Tabs.js +2 -2
- package/dist/{Tabs.vue_used_vue_type_style_index_0_lang.module-4f247ed7.js → Tabs.vue_used_vue_type_style_index_0_lang.module-2a131332.js} +26 -26
- package/dist/Tabs.vue_used_vue_type_style_index_0_lang.module-2a131332.js.map +1 -0
- package/dist/Textarea.js +61 -53
- package/dist/Textarea.js.map +1 -1
- package/dist/Toast.js +23 -23
- package/dist/Toast.js.map +1 -1
- package/dist/components.css +1 -1
- package/dist/constants.d.ts +33 -26
- package/dist/constants.js +56 -41
- package/dist/constants.js.map +1 -1
- package/dist/index.js +21 -20
- package/dist/index.js.map +1 -1
- package/dist/storage.js +3 -2
- package/dist/storage.js.map +1 -1
- package/dist/tailwind-base.d.ts +16 -16
- package/dist/tailwind-base.js +16 -6
- package/dist/tailwind-base.js.map +1 -1
- package/dist/useGoogleMaps.js.map +1 -1
- package/dist/utils/helpers.js +37 -37
- package/dist/utils/helpers.js.map +1 -1
- package/dist/utils/storage.js +30 -29
- package/dist/utils/storage.js.map +1 -1
- package/package.json +2 -2
- package/styles/_core.scss +1 -1
- package/styles/backwards-compat.css +61 -105
- package/styles/base.css +259 -113
- package/tailwind-base.ts +6 -1
- package/dist/Button.vue_used_vue_type_style_index_0_lang.module-b77978d6.js +0 -17
- package/dist/Button.vue_used_vue_type_style_index_0_lang.module-b77978d6.js.map +0 -1
- package/dist/Checkbox.vue_vue_type_style_index_0_scoped_0d7e7fd0_lang-4ed993c7.js +0 -2
- package/dist/Checkbox.vue_vue_type_style_index_0_scoped_0d7e7fd0_lang-4ed993c7.js.map +0 -1
- package/dist/Expand.vue_vue_type_script_setup_true_lang-5fe03d51.js.map +0 -1
- package/dist/Field.vue_vue_type_script_setup_true_lang-475832fe.js.map +0 -1
- package/dist/Label.vue_vue_type_script_setup_true_lang-1d29d98a.js +0 -37
- package/dist/Label.vue_vue_type_script_setup_true_lang-1d29d98a.js.map +0 -1
- package/dist/Loading.vue_vue_type_style_index_0_scoped_bb8d5f15_lang-4ed993c7.js +0 -2
- package/dist/Loading.vue_vue_type_style_index_0_scoped_bb8d5f15_lang-4ed993c7.js.map +0 -1
- package/dist/Paginate.vue_used_vue_type_style_index_0_lang.module-bfccf992.js +0 -11
- package/dist/Paginate.vue_used_vue_type_style_index_0_lang.module-bfccf992.js.map +0 -1
- package/dist/Tab.vue_vue_type_script_setup_true_lang-b810bee8.js.map +0 -1
- package/dist/Table.keys-1ebe4ecb.js +0 -27
- package/dist/Tabs.vue_used_vue_type_style_index_0_lang.module-4f247ed7.js.map +0 -1
- package/styles/_base.scss +0 -493
- package/styles/elements/_links.scss +0 -32
- package/styles/elements/_lists.scss +0 -31
- package/styles/elements/_misc.scss +0 -16
- package/styles/main.scss +0 -38
package/dist/PageContent.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as l, useSlots as d, useCssModule as c, openBlock as n, createElementBlock as r, normalizeClass as _, unref as e, createElementVNode as i, renderSlot as a, createCommentVNode as m } from "vue";
|
|
2
2
|
import { _ as u } from "./_plugin-vue_export-helper-dad06003.js";
|
|
3
|
-
const p = { key: 0 }, g = /* @__PURE__ */
|
|
3
|
+
const p = { key: 0 }, g = /* @__PURE__ */ l({
|
|
4
4
|
name: "ll-page-content",
|
|
5
5
|
__name: "PageContent",
|
|
6
|
-
setup(
|
|
7
|
-
const s = d(), t =
|
|
8
|
-
return (o,
|
|
6
|
+
setup(y) {
|
|
7
|
+
const s = d(), t = c();
|
|
8
|
+
return (o, M) => (n(), r("div", {
|
|
9
9
|
class: _(["stash-page-content", [
|
|
10
10
|
e(t).root,
|
|
11
11
|
{
|
|
@@ -23,14 +23,14 @@ const p = { key: 0 }, g = /* @__PURE__ */ c({
|
|
|
23
23
|
])) : m("", !0)
|
|
24
24
|
], 2));
|
|
25
25
|
}
|
|
26
|
-
}), b = "
|
|
26
|
+
}), b = "_root_r9enl_2", f = "_grid_r9enl_10", C = "_sidebar_r9enl_17", h = {
|
|
27
27
|
root: b,
|
|
28
28
|
grid: f,
|
|
29
29
|
sidebar: C
|
|
30
|
-
},
|
|
30
|
+
}, k = {
|
|
31
31
|
$style: h
|
|
32
|
-
},
|
|
32
|
+
}, B = /* @__PURE__ */ u(g, [["__cssModules", k]]);
|
|
33
33
|
export {
|
|
34
|
-
|
|
34
|
+
B as default
|
|
35
35
|
};
|
|
36
36
|
//# sourceMappingURL=PageContent.js.map
|
package/dist/PageContent.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PageContent.js","sources":["../src/components/PageContent/PageContent.vue"],"sourcesContent":["<script setup lang=\"ts\">\n import { useCssModule, useSlots } from 'vue';\n\n defineOptions({\n name: 'll-page-content',\n });\n\n const slots = useSlots();\n const classes = useCssModule();\n</script>\n\n<template>\n <div\n class=\"stash-page-content\"\n :class=\"[\n classes.root,\n {\n [classes.grid]: !!slots.sidebar,\n [classes.sidebar]: !!slots.sidebar,\n },\n ]\"\n date-test=\"stash-page-content\"\n >\n <div>\n <!-- @slot Default content -->\n <slot name=\"default\"></slot>\n </div>\n\n <aside v-if=\"!!slots.sidebar\">\n <!-- @slot Sidebar content -->\n <slot name=\"sidebar\"></slot>\n </aside>\n </div>\n</template>\n\n<style module>\n .root {\n max-width: theme(width.container); /* 1400px */\n padding-inline:
|
|
1
|
+
{"version":3,"file":"PageContent.js","sources":["../src/components/PageContent/PageContent.vue"],"sourcesContent":["<script setup lang=\"ts\">\n import { useCssModule, useSlots } from 'vue';\n\n defineOptions({\n name: 'll-page-content',\n });\n\n const slots = useSlots();\n const classes = useCssModule();\n</script>\n\n<template>\n <div\n class=\"stash-page-content\"\n :class=\"[\n classes.root,\n {\n [classes.grid]: !!slots.sidebar,\n [classes.sidebar]: !!slots.sidebar,\n },\n ]\"\n date-test=\"stash-page-content\"\n >\n <div>\n <!-- @slot Default content -->\n <slot name=\"default\"></slot>\n </div>\n\n <aside v-if=\"!!slots.sidebar\">\n <!-- @slot Sidebar content -->\n <slot name=\"sidebar\"></slot>\n </aside>\n </div>\n</template>\n\n<style module>\n .root {\n max-width: theme('width.container'); /* 1400px */\n padding-inline: var(--grid-gutter);\n position: relative;\n margin-inline: auto;\n width: 100%;\n }\n\n .grid {\n display: grid;\n grid-gap: var(--grid-gutter);\n grid-template-columns: [start] 1fr [end];\n }\n\n @media screen('lg') {\n .sidebar {\n grid-template-columns: [start] 3fr 1fr [end]; /* 9 cols / 3 cols */\n }\n }\n</style>\n"],"names":["slots","useSlots","classes","useCssModule"],"mappings":";;;;;;AAOE,UAAMA,IAAQC,KACRC,IAAUC;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/dist/PageHeader.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as g, useCssModule as h, useSlots as u, computed as f, openBlock as a, createElementBlock as c, normalizeClass as n, unref as s, createElementVNode as l, renderSlot as t, createCommentVNode as i, toDisplayString as _ } from "vue";
|
|
2
2
|
import { _ as w } from "./_plugin-vue_export-helper-dad06003.js";
|
|
3
|
-
const y = { class: "tw-flex tw-items-center
|
|
3
|
+
const y = { class: "tw-col-span-full tw-flex tw-items-center lg:tw-col-span-1" }, v = { class: "stash-page-header__title tw-my-0" }, $ = {
|
|
4
4
|
key: 0,
|
|
5
|
-
class: "stash-page-header__description tw-mt-1.5
|
|
6
|
-
},
|
|
5
|
+
class: "stash-page-header__description tw-mb-0 tw-mt-1.5"
|
|
6
|
+
}, k = /* @__PURE__ */ g({
|
|
7
7
|
name: "ll-page-header",
|
|
8
8
|
__name: "PageHeader",
|
|
9
9
|
props: {
|
|
@@ -11,45 +11,45 @@ const y = { class: "tw-flex tw-items-center tw-col-span-full lg:tw-col-span-1" }
|
|
|
11
11
|
description: { default: "" }
|
|
12
12
|
},
|
|
13
13
|
setup(m) {
|
|
14
|
-
const d = m, o =
|
|
15
|
-
return (e,
|
|
16
|
-
class:
|
|
14
|
+
const d = m, o = h(), r = u(), p = f(() => !!(r["primary-action"] || r["secondary-action"]));
|
|
15
|
+
return (e, H) => (a(), c("header", {
|
|
16
|
+
class: n(["stash-page-header", [s(o).root, { [s(o).grid]: p.value }]]),
|
|
17
17
|
"date-test": "stash-page-header"
|
|
18
18
|
}, [
|
|
19
|
-
|
|
20
|
-
s(
|
|
19
|
+
l("div", y, [
|
|
20
|
+
s(r).media ? (a(), c("div", {
|
|
21
21
|
key: 0,
|
|
22
|
-
class:
|
|
22
|
+
class: n(["stash-page-header__media tw-mr-3 tw-self-center", s(o).mediaTest])
|
|
23
23
|
}, [
|
|
24
24
|
t(e.$slots, "media")
|
|
25
25
|
], 2)) : i("", !0),
|
|
26
|
-
|
|
26
|
+
l("div", null, [
|
|
27
27
|
t(e.$slots, "title", {}, () => [
|
|
28
|
-
|
|
28
|
+
l("h1", v, _(d.title), 1)
|
|
29
29
|
]),
|
|
30
30
|
t(e.$slots, "description", {}, () => [
|
|
31
|
-
e.description ? (a(),
|
|
31
|
+
e.description ? (a(), c("p", $, _(d.description), 1)) : i("", !0)
|
|
32
32
|
])
|
|
33
33
|
])
|
|
34
34
|
]),
|
|
35
|
-
p.value ? (a(),
|
|
35
|
+
p.value ? (a(), c("div", {
|
|
36
36
|
key: 0,
|
|
37
|
-
class:
|
|
37
|
+
class: n(["stash-page-header__actions tw-col-span-full tw-flex lg:tw-col-span-1", s(o).actions])
|
|
38
38
|
}, [
|
|
39
39
|
t(e.$slots, "secondary-action"),
|
|
40
40
|
t(e.$slots, "primary-action")
|
|
41
41
|
], 2)) : i("", !0)
|
|
42
42
|
], 2));
|
|
43
43
|
}
|
|
44
|
-
}),
|
|
45
|
-
root:
|
|
46
|
-
grid:
|
|
47
|
-
actions:
|
|
48
|
-
"media-test": "_media-
|
|
49
|
-
},
|
|
50
|
-
$style:
|
|
51
|
-
},
|
|
44
|
+
}), C = "_root_1gg6c_2", M = "_grid_1gg6c_13", S = "_actions_1gg6c_18", B = {
|
|
45
|
+
root: C,
|
|
46
|
+
grid: M,
|
|
47
|
+
actions: S,
|
|
48
|
+
"media-test": "_media-test_1gg6c_41"
|
|
49
|
+
}, E = {
|
|
50
|
+
$style: B
|
|
51
|
+
}, V = /* @__PURE__ */ w(k, [["__cssModules", E]]);
|
|
52
52
|
export {
|
|
53
|
-
|
|
53
|
+
V as default
|
|
54
54
|
};
|
|
55
55
|
//# sourceMappingURL=PageHeader.js.map
|
package/dist/PageHeader.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PageHeader.js","sources":["../src/components/PageHeader/PageHeader.vue"],"sourcesContent":["<script setup lang=\"ts\">\n import { computed, useCssModule, useSlots } from 'vue';\n\n export interface PageHeaderProps {\n /**\n * The title of the page.\n */\n title: string;\n /**\n * The description of the page.\n */\n description?: string;\n }\n\n defineOptions({\n name: 'll-page-header',\n });\n\n const props = withDefaults(defineProps<PageHeaderProps>(), {\n description: '',\n });\n\n const classes = useCssModule();\n const slots = useSlots();\n\n const hasActions = computed<boolean>(() => !!(slots['primary-action'] || slots['secondary-action']));\n</script>\n\n<template>\n <header\n class=\"stash-page-header\"\n :class=\"[classes.root, { [classes.grid]: hasActions }]\"\n date-test=\"stash-page-header\"\n >\n <div class=\"tw-flex tw-items-center
|
|
1
|
+
{"version":3,"file":"PageHeader.js","sources":["../src/components/PageHeader/PageHeader.vue"],"sourcesContent":["<script setup lang=\"ts\">\n import { computed, useCssModule, useSlots } from 'vue';\n\n export interface PageHeaderProps {\n /**\n * The title of the page.\n */\n title: string;\n /**\n * The description of the page.\n */\n description?: string;\n }\n\n defineOptions({\n name: 'll-page-header',\n });\n\n const props = withDefaults(defineProps<PageHeaderProps>(), {\n description: '',\n });\n\n const classes = useCssModule();\n const slots = useSlots();\n\n const hasActions = computed<boolean>(() => !!(slots['primary-action'] || slots['secondary-action']));\n</script>\n\n<template>\n <header\n class=\"stash-page-header\"\n :class=\"[classes.root, { [classes.grid]: hasActions }]\"\n date-test=\"stash-page-header\"\n >\n <div class=\"tw-col-span-full tw-flex tw-items-center lg:tw-col-span-1\">\n <div v-if=\"slots.media\" class=\"stash-page-header__media tw-mr-3 tw-self-center\" :class=\"classes.mediaTest\">\n <!-- @slot Receives a custom media -->\n <slot name=\"media\"></slot>\n </div>\n\n <div>\n <!-- @slot Receives a custom title -->\n <slot name=\"title\">\n <h1 class=\"stash-page-header__title tw-my-0\">{{ props.title }}</h1>\n </slot>\n\n <!-- @slot Receives a custom description -->\n <slot name=\"description\">\n <p v-if=\"description\" class=\"stash-page-header__description tw-mb-0 tw-mt-1.5\">{{ props.description }}</p>\n </slot>\n </div>\n </div>\n\n <div\n v-if=\"hasActions\"\n class=\"stash-page-header__actions tw-col-span-full tw-flex lg:tw-col-span-1\"\n :class=\"classes.actions\"\n >\n <!-- @slot Receives a custom secondary action -->\n <slot name=\"secondary-action\"> </slot>\n <!-- @slot Receives a custom primary action -->\n <slot name=\"primary-action\"> </slot>\n </div>\n </header>\n</template>\n\n<style module>\n .root {\n border-bottom: 0;\n display: grid;\n gap: var(--grid-gutter);\n margin: 0 auto;\n max-width: theme('width.container');\n padding: theme('spacing.6') var(--grid-gutter) theme('spacing.12');\n width: 100%;\n }\n\n @media screen('lg') {\n .root.grid {\n grid-template-columns: repeat(2, 1fr);\n }\n }\n\n .actions {\n align-self: flex-end;\n flex-direction: column-reverse;\n row-gap: var(--grid-gutter);\n }\n\n @media screen('md') {\n .actions {\n column-gap: var(--grid-gutter);\n flex-direction: row;\n row-gap: 0;\n }\n }\n\n @media screen('lg') {\n .actions {\n align-items: flex-end;\n flex-direction: row;\n justify-content: flex-end;\n }\n }\n\n /* max size for media/marketing illustration icons we would be passing to the slot */\n .media-test {\n max-width: 58px;\n max-height: 58px;\n }\n</style>\n"],"names":["classes","useCssModule","slots","useSlots","hasActions","computed"],"mappings":";;;;;;;;;;;;;iBAsBQA,IAAUC,KACVC,IAAQC,KAERC,IAAaC,EAAkB,MAAM,CAAC,EAAEH,EAAM,gBAAgB,KAAKA,EAAM,kBAAkB,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/dist/PageNavigation.js
CHANGED
|
@@ -2,11 +2,11 @@ import { defineComponent as b, ref as g, watch as m, onMounted as x, openBlock a
|
|
|
2
2
|
import C from "@leaflink/snitch";
|
|
3
3
|
import d from "lodash-es/kebabCase";
|
|
4
4
|
import { useRoute as U, useRouter as y } from "vue-router";
|
|
5
|
-
import { _ as P } from "./Tab.vue_vue_type_script_setup_true_lang-
|
|
5
|
+
import { _ as P } from "./Tab.vue_vue_type_script_setup_true_lang-69d1b046.js";
|
|
6
6
|
import D from "./Tabs.js";
|
|
7
7
|
import "./Badge.js";
|
|
8
8
|
import "./_plugin-vue_export-helper-dad06003.js";
|
|
9
|
-
import "./Tabs.vue_used_vue_type_style_index_0_lang.module-
|
|
9
|
+
import "./Tabs.vue_used_vue_type_style_index_0_lang.module-2a131332.js";
|
|
10
10
|
import "lodash-es/debounce";
|
|
11
11
|
import "lodash-es/uniqueId";
|
|
12
12
|
import "./constants.js";
|
|
@@ -23,7 +23,7 @@ import "./Icon.js";
|
|
|
23
23
|
import "./index-79ce320f.js";
|
|
24
24
|
import "./Icon.vue_used_vue_type_style_index_0_lang.module-eb359559.js";
|
|
25
25
|
const E = {
|
|
26
|
-
class: "
|
|
26
|
+
class: "stash-page-navigation container",
|
|
27
27
|
"data-test": "stash-page-navigation"
|
|
28
28
|
}, re = /* @__PURE__ */ b({
|
|
29
29
|
name: "ll-page-navigation",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PageNavigation.js","sources":["../src/components/PageNavigation/PageNavigation.vue"],"sourcesContent":["<script setup lang=\"ts\">\n import logger from '@leaflink/snitch';\n import kebabCase from 'lodash-es/kebabCase';\n import { onMounted, ref, watch } from 'vue';\n import { RouteLocationRaw, useRoute, useRouter } from 'vue-router';\n\n import Tab, { type TabProps } from '../Tab/Tab.vue';\n import Tabs from '../Tabs/Tabs.vue';\n\n defineOptions({\n name: 'll-page-navigation',\n });\n\n export interface NavItem extends Omit<TabProps, 'value'> {\n /**\n * The tab's label\n */\n label: string;\n\n /**\n * The tab's label\n */\n value?: string;\n }\n\n export interface PageNavigationProps {\n /**\n * Index of active tab (zero-based)\n * @deprecated Use v-model instead.\n */\n activeIndex?: number | string;\n\n /**\n * The currently active tab value\n */\n modelValue?: string;\n\n /**\n * Array of tabs. A `tab` is an object containing a `label` and either an `href` | `to`\n */\n items: NavItem[];\n }\n\n const props = withDefaults(defineProps<PageNavigationProps>(), {\n activeIndex: undefined,\n modelValue: '',\n });\n\n const emit =\n defineEmits<{\n /**\n * Emits the current active nav value\n */\n (e: 'update:modelValue', activeTab: string): void;\n\n /**\n * Emits the current active nav index\n * @deprecated - Use v-model instead.\n */\n (e: 'change', activeNavIndex: number): void;\n }>();\n\n if (props.activeIndex) {\n logger.info('The `activeIndex` prop is deprecated. Use `v-model` instead.');\n }\n\n const route = useRoute();\n const router = useRouter();\n\n // this ref is needed to keep track of the active tab even if v-model is not passed\n const activeTab = ref('');\n\n function onUpdateActiveTab(newActiveTab: string) {\n if (newActiveTab === activeTab.value) return;\n\n activeTab.value = newActiveTab;\n emit('update:modelValue', newActiveTab);\n }\n\n // TODO: Remove this once activeIndex is removed\n watch(() => props.modelValue, (newValue, oldValue) => {\n if (oldValue === newValue) return;\n\n const activeNavItemIndex = props.items.findIndex((item) => kebabCase(item.label) === newValue);\n\n emit('change', activeNavItemIndex);\n });\n\n onMounted(() => {\n if (!props.items.length) return;\n\n // TODO: Remove this once activeIndex is removed\n if (props.activeIndex !== undefined) {\n const activeTabItem = props.items[props.activeIndex];\n\n onUpdateActiveTab(kebabCase(activeTabItem.label));\n\n return;\n }\n\n if (props.modelValue) {\n onUpdateActiveTab(props.modelValue);\n return;\n }\n\n if (!router) return;\n\n const itemMatchingRoute = props.items.find(item => {\n if (item?.disabled || (!item?.to && !item?.href)) return;\n\n const { path } = router.resolve(item?.to as RouteLocationRaw || item?.href as string);\n\n if (path === route.path) {\n return true;\n }\n\n if (!route.path.includes(path)) return;\n\n const sliceIndex = (route.path.length - route.path.lastIndexOf('/')) * -1;\n const parentPath = route.path.slice(0, sliceIndex);\n\n return path === parentPath;\n });\n\n if (!itemMatchingRoute) return;\n\n onUpdateActiveTab(itemMatchingRoute?.value || kebabCase(itemMatchingRoute.label));\n });\n</script>\n\n<template>\n <nav class=\"
|
|
1
|
+
{"version":3,"file":"PageNavigation.js","sources":["../src/components/PageNavigation/PageNavigation.vue"],"sourcesContent":["<script setup lang=\"ts\">\n import logger from '@leaflink/snitch';\n import kebabCase from 'lodash-es/kebabCase';\n import { onMounted, ref, watch } from 'vue';\n import { RouteLocationRaw, useRoute, useRouter } from 'vue-router';\n\n import Tab, { type TabProps } from '../Tab/Tab.vue';\n import Tabs from '../Tabs/Tabs.vue';\n\n defineOptions({\n name: 'll-page-navigation',\n });\n\n export interface NavItem extends Omit<TabProps, 'value'> {\n /**\n * The tab's label\n */\n label: string;\n\n /**\n * The tab's label\n */\n value?: string;\n }\n\n export interface PageNavigationProps {\n /**\n * Index of active tab (zero-based)\n * @deprecated Use v-model instead.\n */\n activeIndex?: number | string;\n\n /**\n * The currently active tab value\n */\n modelValue?: string;\n\n /**\n * Array of tabs. A `tab` is an object containing a `label` and either an `href` | `to`\n */\n items: NavItem[];\n }\n\n const props = withDefaults(defineProps<PageNavigationProps>(), {\n activeIndex: undefined,\n modelValue: '',\n });\n\n const emit =\n defineEmits<{\n /**\n * Emits the current active nav value\n */\n (e: 'update:modelValue', activeTab: string): void;\n\n /**\n * Emits the current active nav index\n * @deprecated - Use v-model instead.\n */\n (e: 'change', activeNavIndex: number): void;\n }>();\n\n if (props.activeIndex) {\n logger.info('The `activeIndex` prop is deprecated. Use `v-model` instead.');\n }\n\n const route = useRoute();\n const router = useRouter();\n\n // this ref is needed to keep track of the active tab even if v-model is not passed\n const activeTab = ref('');\n\n function onUpdateActiveTab(newActiveTab: string) {\n if (newActiveTab === activeTab.value) return;\n\n activeTab.value = newActiveTab;\n emit('update:modelValue', newActiveTab);\n }\n\n // TODO: Remove this once activeIndex is removed\n watch(() => props.modelValue, (newValue, oldValue) => {\n if (oldValue === newValue) return;\n\n const activeNavItemIndex = props.items.findIndex((item) => kebabCase(item.label) === newValue);\n\n emit('change', activeNavItemIndex);\n });\n\n onMounted(() => {\n if (!props.items.length) return;\n\n // TODO: Remove this once activeIndex is removed\n if (props.activeIndex !== undefined) {\n const activeTabItem = props.items[props.activeIndex];\n\n onUpdateActiveTab(kebabCase(activeTabItem.label));\n\n return;\n }\n\n if (props.modelValue) {\n onUpdateActiveTab(props.modelValue);\n return;\n }\n\n if (!router) return;\n\n const itemMatchingRoute = props.items.find(item => {\n if (item?.disabled || (!item?.to && !item?.href)) return;\n\n const { path } = router.resolve(item?.to as RouteLocationRaw || item?.href as string);\n\n if (path === route.path) {\n return true;\n }\n\n if (!route.path.includes(path)) return;\n\n const sliceIndex = (route.path.length - route.path.lastIndexOf('/')) * -1;\n const parentPath = route.path.slice(0, sliceIndex);\n\n return path === parentPath;\n });\n\n if (!itemMatchingRoute) return;\n\n onUpdateActiveTab(itemMatchingRoute?.value || kebabCase(itemMatchingRoute.label));\n });\n</script>\n\n<template>\n <nav class=\"stash-page-navigation container\" data-test=\"stash-page-navigation\">\n <Tabs :active-tab=\"activeTab\" @update:active-tab=\"onUpdateActiveTab\">\n <Tab\n v-for=\"(item, index) in props.items\"\n :key=\"item.label\"\n :value=\"item?.value || kebabCase(item.label)\"\n :to=\"item.to\"\n :href=\"item.href\"\n :badge=\"item.badge\"\n :disabled=\"item.disabled\"\n :data-id=\"index\"\n >\n {{ item.label }}\n </Tab>\n </Tabs>\n </nav>\n</template>\n"],"names":["props","logger","route","useRoute","router","useRouter","activeTab","ref","onUpdateActiveTab","newActiveTab","emit","watch","newValue","oldValue","activeNavItemIndex","item","kebabCase","onMounted","activeTabItem","itemMatchingRoute","path","sliceIndex","parentPath"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA8DE,IAAIA,EAAM,eACRC,EAAO,KAAK,8DAA8D;AAG5E,UAAMC,IAAQC,KACRC,IAASC,KAGTC,IAAYC,EAAI,EAAE;AAExB,aAASC,EAAkBC,GAAsB;AAC/C,MAAIA,MAAiBH,EAAU,UAE/BA,EAAU,QAAQG,GAClBC,EAAK,qBAAqBD,CAAY;AAAA,IACxC;AAGA,WAAAE,EAAM,MAAMX,EAAM,YAAY,CAACY,GAAUC,MAAa;AACpD,UAAIA,MAAaD;AAAU;AAErB,YAAAE,IAAqBd,EAAM,MAAM,UAAU,CAACe,MAASC,EAAUD,EAAK,KAAK,MAAMH,CAAQ;AAE7F,MAAAF,EAAK,UAAUI,CAAkB;AAAA,IAAA,CAClC,GAEDG,EAAU,MAAM;AACV,UAAA,CAACjB,EAAM,MAAM;AAAQ;AAGrB,UAAAA,EAAM,gBAAgB,QAAW;AACnC,cAAMkB,IAAgBlB,EAAM,MAAMA,EAAM,WAAW;AAEjC,QAAAQ,EAAAQ,EAAUE,EAAc,KAAK,CAAC;AAEhD;AAAA,MACF;AAEA,UAAIlB,EAAM,YAAY;AACpB,QAAAQ,EAAkBR,EAAM,UAAU;AAClC;AAAA,MACF;AAEA,UAAI,CAACI;AAAQ;AAEb,YAAMe,IAAoBnB,EAAM,MAAM,KAAK,CAAQe,MAAA;AACjD,YAAIA,KAAA,QAAAA,EAAM,YAAa,EAACA,KAAA,QAAAA,EAAM,OAAM,EAACA,KAAA,QAAAA,EAAM;AAAO;AAE5C,cAAA,EAAE,MAAAK,EAAS,IAAAhB,EAAO,SAAQW,KAAA,gBAAAA,EAAM,QAA0BA,KAAA,gBAAAA,EAAM,KAAc;AAEhF,YAAAK,MAASlB,EAAM;AACV,iBAAA;AAGT,YAAI,CAACA,EAAM,KAAK,SAASkB,CAAI;AAAG;AAE1B,cAAAC,KAAcnB,EAAM,KAAK,SAASA,EAAM,KAAK,YAAY,GAAG,KAAK,IACjEoB,IAAapB,EAAM,KAAK,MAAM,GAAGmB,CAAU;AAEjD,eAAOD,MAASE;AAAA,MAAA,CACjB;AAED,MAAKH,KAELX,GAAkBW,KAAA,gBAAAA,EAAmB,UAASH,EAAUG,EAAkB,KAAK,CAAC;AAAA,IAAA,CACjF;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/dist/Paginate.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineComponent as w, useCssModule as y, computed as S, openBlock as r, createElementBlock as l, createElementVNode as c, normalizeClass as o, unref as i, createVNode as f, Fragment as g, renderList as x, createCommentVNode as p, toDisplayString as z } from "vue";
|
|
2
2
|
import m from "./Icon.js";
|
|
3
|
-
import { s as M } from "./Paginate.vue_used_vue_type_style_index_0_lang.module-
|
|
3
|
+
import { s as M } from "./Paginate.vue_used_vue_type_style_index_0_lang.module-18343da7.js";
|
|
4
4
|
import { _ as E } from "./_plugin-vue_export-helper-dad06003.js";
|
|
5
5
|
import "lodash-es/uniqueId";
|
|
6
6
|
import "./index-79ce320f.js";
|
package/dist/Paginate.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Paginate.js","sources":["../src/components/Paginate/Paginate.vue"],"sourcesContent":["<script lang=\"ts\" setup>\n import { computed, useCssModule } from 'vue';\n\n import Icon from '../Icon/Icon.vue';\n\n defineOptions({\n name: 'll-paginate',\n });\n\n export interface PaginateProps {\n /**\n * Current page number\n */\n currentPage?: number;\n /**\n * Total number of items in list\n */\n listLength?: number;\n /**\n * Number of items per page\n */\n pageSize?: number;\n }\n\n const props = withDefaults(defineProps<PaginateProps>(), {\n currentPage: 1,\n listLength: 1,\n pageSize: 50,\n });\n\n const emit =\n defineEmits<{\n /**\n * Emitted when the page number changes.\n */\n (e: 'set-page', pageNumber: number): void;\n }>();\n\n const classes = useCssModule();\n\n const pages = computed(() => Math.ceil(props.listLength / props.pageSize));\n\n /**\n * Emits current page to list view.\n */\n function updatePage(currentPage: number) {\n emit('set-page', currentPage);\n }\n\n /**\n * Sets current page to next page\n */\n function next() {\n if (props.currentPage < pages.value) {\n updatePage(props.currentPage + 1);\n }\n }\n\n /**\n * Sets current page to previous page\n */\n function prev() {\n if (props.currentPage > 1) {\n updatePage(props.currentPage - 1);\n }\n }\n\n /**\n * Determines whether to show page\n * @returns {boolean} - should show page in pagination component\n */\n function shouldShowPage(page: number): boolean {\n const pageDiff = Math.abs(props.currentPage - page);\n\n if (\n pages.value < 10 ||\n page === 1 ||\n page === pages.value ||\n (props.currentPage < 6 && page < 8) ||\n (pages.value - props.currentPage < 5 && pages.value - page < 7) ||\n pageDiff < 3\n ) {\n return true;\n }\n\n return false;\n }\n\n /**\n * Determines whether to show the leading ellipsis\n * @returns {boolean} should show or not\n */\n function shouldShowFirstEllipsis(page: number): boolean {\n return pages.value > 9 && props.currentPage > 5 && page === 2;\n }\n\n /**\n * Determines whether to show the trailing ellipsis\n * @returns {boolean} should show or not\n */\n function shouldShowLastEllipsis(page: number): boolean {\n return pages.value > 9 && pages.value - props.currentPage > 4 && page === pages.value - 1;\n }\n</script>\n\n<template>\n <div class=\"stash-paginate tw-flex tw-justify-center\" data-test=\"stash-paginate\">\n <ul class=\"stash-paginate__list tw-flex\" :class=\"classes.pagination\" data-test=\"stash-paginate|list\">\n <button\n data-test=\"stash-paginate|prev-page\"\n :class=\"[classes.prev, { [classes['is-disabled']]: currentPage === 1 }]\"\n @click=\"prev\"\n >\n <Icon size=\"small\" name=\"chevron-left\" />\n </button>\n <template v-for=\"page in pages\">\n <button\n v-if=\"shouldShowFirstEllipsis(page)\"\n :key=\"`${page}-ellipsis`\"\n data-test=\"stash-paginate|first-ellipsis\"\n >\n …\n </button>\n <button\n v-if=\"shouldShowPage(page)\"\n :key=\"page\"\n data-test=\"stash-paginate|page-number\"\n :class=\"{ [classes['is-active']]: currentPage === page }\"\n @click=\"updatePage(page)\"\n >\n {{ page }}\n </button>\n <button v-if=\"shouldShowLastEllipsis(page)\" :key=\"`${page}-ellipsis`\" data-test=\"stash-paginate|last-ellipsis\">\n …\n </button>\n </template>\n <button\n data-test=\"stash-paginate|next-page\"\n :class=\"[classes.next, { [classes['is-disabled']]: currentPage === pages }]\"\n @click=\"next\"\n >\n <Icon size=\"small\" class=\"tw-rotate-180\" name=\"chevron-left\" />\n </button>\n </ul>\n </div>\n</template>\n\n<style module>\n .pagination {\n /* Todo: We shouldn't really be making assumptions about the outer spacing of the pagination component */\n margin-top: theme(spacing.12);\n z-index: 0;\n\n a,\n button {\n @apply tw-border tw-border-solid tw-border-ice-200;\n align-items: center;\n background-color: theme(colors.white);\n color:
|
|
1
|
+
{"version":3,"file":"Paginate.js","sources":["../src/components/Paginate/Paginate.vue"],"sourcesContent":["<script lang=\"ts\" setup>\n import { computed, useCssModule } from 'vue';\n\n import Icon from '../Icon/Icon.vue';\n\n defineOptions({\n name: 'll-paginate',\n });\n\n export interface PaginateProps {\n /**\n * Current page number\n */\n currentPage?: number;\n /**\n * Total number of items in list\n */\n listLength?: number;\n /**\n * Number of items per page\n */\n pageSize?: number;\n }\n\n const props = withDefaults(defineProps<PaginateProps>(), {\n currentPage: 1,\n listLength: 1,\n pageSize: 50,\n });\n\n const emit =\n defineEmits<{\n /**\n * Emitted when the page number changes.\n */\n (e: 'set-page', pageNumber: number): void;\n }>();\n\n const classes = useCssModule();\n\n const pages = computed(() => Math.ceil(props.listLength / props.pageSize));\n\n /**\n * Emits current page to list view.\n */\n function updatePage(currentPage: number) {\n emit('set-page', currentPage);\n }\n\n /**\n * Sets current page to next page\n */\n function next() {\n if (props.currentPage < pages.value) {\n updatePage(props.currentPage + 1);\n }\n }\n\n /**\n * Sets current page to previous page\n */\n function prev() {\n if (props.currentPage > 1) {\n updatePage(props.currentPage - 1);\n }\n }\n\n /**\n * Determines whether to show page\n * @returns {boolean} - should show page in pagination component\n */\n function shouldShowPage(page: number): boolean {\n const pageDiff = Math.abs(props.currentPage - page);\n\n if (\n pages.value < 10 ||\n page === 1 ||\n page === pages.value ||\n (props.currentPage < 6 && page < 8) ||\n (pages.value - props.currentPage < 5 && pages.value - page < 7) ||\n pageDiff < 3\n ) {\n return true;\n }\n\n return false;\n }\n\n /**\n * Determines whether to show the leading ellipsis\n * @returns {boolean} should show or not\n */\n function shouldShowFirstEllipsis(page: number): boolean {\n return pages.value > 9 && props.currentPage > 5 && page === 2;\n }\n\n /**\n * Determines whether to show the trailing ellipsis\n * @returns {boolean} should show or not\n */\n function shouldShowLastEllipsis(page: number): boolean {\n return pages.value > 9 && pages.value - props.currentPage > 4 && page === pages.value - 1;\n }\n</script>\n\n<template>\n <div class=\"stash-paginate tw-flex tw-justify-center\" data-test=\"stash-paginate\">\n <ul class=\"stash-paginate__list tw-flex\" :class=\"classes.pagination\" data-test=\"stash-paginate|list\">\n <button\n data-test=\"stash-paginate|prev-page\"\n :class=\"[classes.prev, { [classes['is-disabled']]: currentPage === 1 }]\"\n @click=\"prev\"\n >\n <Icon size=\"small\" name=\"chevron-left\" />\n </button>\n <template v-for=\"page in pages\">\n <button\n v-if=\"shouldShowFirstEllipsis(page)\"\n :key=\"`${page}-ellipsis`\"\n data-test=\"stash-paginate|first-ellipsis\"\n >\n …\n </button>\n <button\n v-if=\"shouldShowPage(page)\"\n :key=\"page\"\n data-test=\"stash-paginate|page-number\"\n :class=\"{ [classes['is-active']]: currentPage === page }\"\n @click=\"updatePage(page)\"\n >\n {{ page }}\n </button>\n <button v-if=\"shouldShowLastEllipsis(page)\" :key=\"`${page}-ellipsis`\" data-test=\"stash-paginate|last-ellipsis\">\n …\n </button>\n </template>\n <button\n data-test=\"stash-paginate|next-page\"\n :class=\"[classes.next, { [classes['is-disabled']]: currentPage === pages }]\"\n @click=\"next\"\n >\n <Icon size=\"small\" class=\"tw-rotate-180\" name=\"chevron-left\" />\n </button>\n </ul>\n </div>\n</template>\n\n<style module>\n .pagination {\n /* Todo: We shouldn't really be making assumptions about the outer spacing of the pagination component */\n margin-top: theme('spacing.12');\n z-index: 0;\n\n a,\n button {\n @apply tw-border tw-border-solid tw-border-ice-200;\n align-items: center;\n background-color: theme('colors.white');\n color: var(--color-blue-500);\n cursor: pointer;\n display: flex;\n height: theme('height.input');\n justify-content: center;\n margin: 0 0 0 -1px;\n width: theme('height.input');\n\n &.prev {\n border-bottom-left-radius: theme('borderRadius.DEFAULT');\n border-top-left-radius: theme('borderRadius.DEFAULT');\n }\n\n &.next {\n border-bottom-right-radius: theme('borderRadius.DEFAULT');\n border-top-right-radius: theme('borderRadius.DEFAULT');\n }\n\n &:focus {\n outline: none;\n }\n\n &:hover {\n text-decoration: none;\n }\n\n &.is-active {\n background-color: var(--color-blue-500);\n color: theme('colors.white');\n pointer-events: none;\n z-index: theme('zIndex.control');\n }\n\n &:hover,\n &.is-active {\n @apply tw-border tw-border-solid tw-border-blue-500;\n position: relative;\n }\n\n &.is-disabled {\n cursor: not-allowed;\n opacity: 0.5;\n }\n }\n }\n</style>\n"],"names":["classes","useCssModule","pages","computed","props","updatePage","currentPage","emit","next","prev","shouldShowPage","page","pageDiff","shouldShowFirstEllipsis","shouldShowLastEllipsis"],"mappings":";;;;;;;;;;;;;;;;;;;;iBAsCQA,IAAUC,KAEVC,IAAQC,EAAS,MAAM,KAAK,KAAKC,EAAM,aAAaA,EAAM,QAAQ,CAAC;AAKzE,aAASC,EAAWC,GAAqB;AACvC,MAAAC,EAAK,YAAYD,CAAW;AAAA,IAC9B;AAKA,aAASE,IAAO;AACV,MAAAJ,EAAM,cAAcF,EAAM,SACjBG,EAAAD,EAAM,cAAc,CAAC;AAAA,IAEpC;AAKA,aAASK,IAAO;AACV,MAAAL,EAAM,cAAc,KACXC,EAAAD,EAAM,cAAc,CAAC;AAAA,IAEpC;AAMA,aAASM,EAAeC,GAAuB;AAC7C,YAAMC,IAAW,KAAK,IAAIR,EAAM,cAAcO,CAAI;AAGhD,aAAAT,EAAM,QAAQ,MACdS,MAAS,KACTA,MAAST,EAAM,SACdE,EAAM,cAAc,KAAKO,IAAO,KAChCT,EAAM,QAAQE,EAAM,cAAc,KAAKF,EAAM,QAAQS,IAAO,KAC7DC,IAAW;AAAA,IAMf;AAMA,aAASC,EAAwBF,GAAuB;AACtD,aAAOT,EAAM,QAAQ,KAAKE,EAAM,cAAc,KAAKO,MAAS;AAAA,IAC9D;AAMA,aAASG,EAAuBH,GAAuB;AAC9C,aAAAT,EAAM,QAAQ,KAAKA,EAAM,QAAQE,EAAM,cAAc,KAAKO,MAAST,EAAM,QAAQ;AAAA,IAC1F;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
const _ = "_pagination_14zhb_2", i = "_prev_14zhb_20", t = "_next_14zhb_25", n = {
|
|
2
|
+
pagination: _,
|
|
3
|
+
prev: i,
|
|
4
|
+
next: t,
|
|
5
|
+
"is-active": "_is-active_14zhb_38",
|
|
6
|
+
"is-disabled": "_is-disabled_14zhb_51"
|
|
7
|
+
};
|
|
8
|
+
export {
|
|
9
|
+
n as s
|
|
10
|
+
};
|
|
11
|
+
//# sourceMappingURL=Paginate.vue_used_vue_type_style_index_0_lang.module-18343da7.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Paginate.vue_used_vue_type_style_index_0_lang.module-18343da7.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;"}
|
package/dist/QuickAction.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as u, useCssModule as _, computed as o, openBlock as d, createBlock as m, resolveDynamicComponent as f, mergeProps as p, unref as w, withCtx as h, createElementVNode as e, createVNode as s, toDisplayString as r } from "vue";
|
|
2
2
|
import n from "./Icon.js";
|
|
3
|
-
import { _ as
|
|
3
|
+
import { _ as x } from "./_plugin-vue_export-helper-dad06003.js";
|
|
4
4
|
import "lodash-es/uniqueId";
|
|
5
5
|
import "./index-79ce320f.js";
|
|
6
6
|
import "./Icon.vue_used_vue_type_style_index_0_lang.module-eb359559.js";
|
|
7
|
-
const
|
|
7
|
+
const b = { class: "tw-flex tw-items-center tw-gap-3" }, k = { class: "tw-flex tw-items-center tw-justify-center tw-rounded tw-bg-blue-100 tw-p-3" }, v = { class: "tw-flex-1" }, g = { class: "tw-text-blue-500" }, y = { class: "tw-text-xs tw-font-normal tw-text-ice-700 lg:tw-mb-0" }, C = /* @__PURE__ */ u({
|
|
8
8
|
__name: "QuickAction",
|
|
9
9
|
props: {
|
|
10
10
|
title: {},
|
|
@@ -13,27 +13,27 @@ const w = { class: "content tw-flex tw-items-center" }, h = { class: "tw-flex tw
|
|
|
13
13
|
href: {},
|
|
14
14
|
icon: {}
|
|
15
15
|
},
|
|
16
|
-
setup(
|
|
17
|
-
const t =
|
|
16
|
+
setup(c) {
|
|
17
|
+
const t = c, i = _(), l = o(() => t.to ? "router-link" : t.href ? "a" : "div"), a = o(() => t.to ? {
|
|
18
18
|
to: t.to
|
|
19
19
|
} : t.href ? {
|
|
20
20
|
href: t.href
|
|
21
21
|
} : {});
|
|
22
|
-
return (
|
|
23
|
-
class: "stash-quick-action
|
|
22
|
+
return (B, D) => (d(), m(f(l.value), p(a.value, {
|
|
23
|
+
class: ["stash-quick-action tw-rounded tw-p-3 tw-shadow", w(i).root],
|
|
24
24
|
"data-test": "stash-quick-action"
|
|
25
25
|
}), {
|
|
26
|
-
default:
|
|
27
|
-
e("div",
|
|
28
|
-
e("div",
|
|
26
|
+
default: h(() => [
|
|
27
|
+
e("div", b, [
|
|
28
|
+
e("div", k, [
|
|
29
29
|
s(n, {
|
|
30
30
|
name: t.icon,
|
|
31
31
|
class: "tw-text-blue-500"
|
|
32
32
|
}, null, 8, ["name"])
|
|
33
33
|
]),
|
|
34
|
-
e("div",
|
|
35
|
-
e("h4",
|
|
36
|
-
e("p",
|
|
34
|
+
e("div", v, [
|
|
35
|
+
e("h4", g, r(t.title), 1),
|
|
36
|
+
e("p", y, r(t.subtitle), 1)
|
|
37
37
|
]),
|
|
38
38
|
s(n, {
|
|
39
39
|
name: "arrow-right",
|
|
@@ -42,11 +42,14 @@ const w = { class: "content tw-flex tw-items-center" }, h = { class: "tw-flex tw
|
|
|
42
42
|
])
|
|
43
43
|
]),
|
|
44
44
|
_: 1
|
|
45
|
-
}, 16));
|
|
45
|
+
}, 16, ["class"]));
|
|
46
46
|
}
|
|
47
|
-
})
|
|
48
|
-
|
|
47
|
+
}), A = "_root_nu1bt_2", M = {
|
|
48
|
+
root: A
|
|
49
|
+
}, q = {
|
|
50
|
+
$style: M
|
|
51
|
+
}, P = /* @__PURE__ */ x(C, [["__cssModules", q]]);
|
|
49
52
|
export {
|
|
50
|
-
|
|
53
|
+
P as default
|
|
51
54
|
};
|
|
52
55
|
//# sourceMappingURL=QuickAction.js.map
|
package/dist/QuickAction.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"QuickAction.js","sources":["../src/components/QuickAction/QuickAction.vue"],"sourcesContent":["<script setup lang=\"ts\">\n import {
|
|
1
|
+
{"version":3,"file":"QuickAction.js","sources":["../src/components/QuickAction/QuickAction.vue"],"sourcesContent":["<script setup lang=\"ts\">\n import {computed, useCssModule} from 'vue';\n import { type RouteLocationRaw } from 'vue-router';\n\n import { IconName } from '../Icon/Icon.types';\n import Icon from '../Icon/Icon.vue';\n\n export interface QuickActionProps {\n /**\n * The title prop will show the first line of text\n */\n title: string;\n\n /**\n * The subtitle prop will show the second line of text\n */\n subtitle: string;\n\n /**\n * The `to` prop for vue-router's `RouterLink` component\n */\n to?: RouteLocationRaw;\n /**\n * If defined, the quick action will render as an `<a />` tag.\n */\n href?: string;\n /**\n * Icon to render on the left side\n */\n icon: IconName;\n }\n\n const props = defineProps<QuickActionProps>();\n const classes = useCssModule();\n\n const is = computed(() => {\n if (props.to) {\n return 'router-link';\n }\n\n if (props.href) {\n return 'a';\n }\n\n return 'div';\n });\n\n const linkAttrs = computed(() => {\n if (props.to) {\n return {\n to: props.to,\n };\n }\n\n if (props.href) {\n return {\n href: props.href\n };\n }\n\n return {};\n });\n</script>\n\n<template>\n <component\n :is=\"is\"\n v-bind=\"linkAttrs\"\n class=\"stash-quick-action tw-rounded tw-p-3 tw-shadow\"\n :class=\"classes.root\"\n data-test=\"stash-quick-action\"\n >\n <div class=\"tw-flex tw-items-center tw-gap-3\">\n <div class=\"tw-flex tw-items-center tw-justify-center tw-rounded tw-bg-blue-100 tw-p-3\">\n <Icon :name=\"props.icon\" class=\"tw-text-blue-500\" />\n </div>\n <div class=\"tw-flex-1\">\n <h4 class=\"tw-text-blue-500\">{{ props.title }}</h4>\n <p class=\"tw-text-xs tw-font-normal tw-text-ice-700 lg:tw-mb-0\">\n {{ props.subtitle }}\n </p>\n </div>\n <Icon name=\"arrow-right\" class=\"tw-text-blue-500\" />\n </div>\n </component>\n</template>\n\n<style module>\n .root {\n background-color: #fff;\n border: 1px solid transparent; /* it prevents layout size shifting of extra height/width when hover */\n cursor: pointer;\n display: inline-block;\n }\n\n .root:hover,\n .root:active,\n .root:focus {\n border: 1px solid var(--color-blue-500);\n text-decoration: none;\n }\n</style>\n"],"names":["classes","useCssModule","is","computed","props","linkAttrs"],"mappings":";;;;;;;;;;;;;;;;iBAiCQA,IAAUC,KAEVC,IAAKC,EAAS,MACdC,EAAM,KACD,gBAGLA,EAAM,OACD,MAGF,KACR,GAEKC,IAAYF,EAAS,MACrBC,EAAM,KACD;AAAA,MACL,IAAIA,EAAM;AAAA,IAAA,IAIVA,EAAM,OACD;AAAA,MACL,MAAMA,EAAM;AAAA,IAAA,IAIT,EACR;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/dist/Radio.js
CHANGED
|
@@ -1,6 +1,11 @@
|
|
|
1
|
-
import { openBlock as
|
|
2
|
-
import { _ as
|
|
3
|
-
const
|
|
1
|
+
import { useCssModule as d, openBlock as i, createElementBlock as u, normalizeClass as a, withDirectives as c, createElementVNode as s, mergeProps as _, vModelRadio as m, toDisplayString as h } from "vue";
|
|
2
|
+
import { _ as f } from "./_plugin-vue_export-helper-dad06003.js";
|
|
3
|
+
const p = "_root_ul6uq_2", b = "_label_ul6uq_7", k = "_error_ul6uq_40", y = "_input_ul6uq_45", g = {
|
|
4
|
+
root: p,
|
|
5
|
+
label: b,
|
|
6
|
+
error: k,
|
|
7
|
+
input: y
|
|
8
|
+
}, v = {
|
|
4
9
|
name: "ll-radio",
|
|
5
10
|
props: {
|
|
6
11
|
/**
|
|
@@ -43,6 +48,11 @@ const f = {
|
|
|
43
48
|
}
|
|
44
49
|
},
|
|
45
50
|
emits: ["update:checked"],
|
|
51
|
+
setup() {
|
|
52
|
+
return {
|
|
53
|
+
classes: d()
|
|
54
|
+
};
|
|
55
|
+
},
|
|
46
56
|
computed: {
|
|
47
57
|
internalValue: {
|
|
48
58
|
get() {
|
|
@@ -57,25 +67,30 @@ const f = {
|
|
|
57
67
|
if (this.$attrs.onChange)
|
|
58
68
|
throw new Error("ll-radio: use the @update:checked event instead of @input");
|
|
59
69
|
}
|
|
60
|
-
},
|
|
61
|
-
function
|
|
62
|
-
return
|
|
63
|
-
class:
|
|
70
|
+
}, w = ["id"], E = ["for"];
|
|
71
|
+
function V(e, l, t, r, S, o) {
|
|
72
|
+
return i(), u("div", {
|
|
73
|
+
class: a(["stash-radio", [r.classes.root, { error: t.hasError }]]),
|
|
64
74
|
"data-test": "ll-radio"
|
|
65
75
|
}, [
|
|
66
|
-
s(
|
|
76
|
+
c(s("input", _({
|
|
67
77
|
id: t.id,
|
|
68
|
-
"onUpdate:modelValue":
|
|
69
|
-
class: "sr-only",
|
|
78
|
+
"onUpdate:modelValue": l[0] || (l[0] = (n) => o.internalValue = n),
|
|
79
|
+
class: ["tw-sr-only", r.classes.input],
|
|
70
80
|
type: "radio"
|
|
71
|
-
}, e.$attrs), null, 16,
|
|
72
|
-
[
|
|
81
|
+
}, e.$attrs), null, 16, w), [
|
|
82
|
+
[m, o.internalValue]
|
|
73
83
|
]),
|
|
74
|
-
|
|
84
|
+
s("label", {
|
|
85
|
+
for: t.id,
|
|
86
|
+
class: a(r.classes.label)
|
|
87
|
+
}, h(t.label), 11, E)
|
|
75
88
|
], 2);
|
|
76
89
|
}
|
|
77
|
-
const
|
|
90
|
+
const q = {
|
|
91
|
+
$style: g
|
|
92
|
+
}, C = /* @__PURE__ */ f(v, [["render", V], ["__cssModules", q]]);
|
|
78
93
|
export {
|
|
79
|
-
|
|
94
|
+
C as default
|
|
80
95
|
};
|
|
81
96
|
//# sourceMappingURL=Radio.js.map
|
package/dist/Radio.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Radio.js","sources":["../src/components/Radio/Radio.vue"],"sourcesContent":["<script>\n /**\n * @deprecated use components/RadioNew/Radio instead.\n * if you need multiple Radio components considering using RadioGroup instead.\n */\n export default {\n name: 'll-radio',\n\n props: {\n /**\n * The checked/selected state of the radio button\n */\n checked: {\n type: [String, Number],\n default: undefined,\n },\n\n /**\n * Use :checked or v-model:checked instead of :model-value and v-model.\n */\n modelValue: {\n type: [String, Number, null],\n default: null,\n validator(value) {\n if (value !== null) {\n throw new Error('ll-radio: use :checked or v-model:checked instead of :model-value and v-model.');\n }\n\n return true;\n },\n },\n\n /**\n * Adds error styling\n */\n hasError: Boolean,\n\n /**\n * A unique string to distinguish one Radio instance from another\n * and to link the label to the input; required for accessibility\n */\n id: {\n type: String,\n required: true,\n },\n\n /**\n * The description which appears to the right of the radio button\n */\n label: {\n type: String,\n default: '',\n },\n },\n\n emits: ['update:checked'],\n\n computed: {\n internalValue: {\n get() {\n return this.checked;\n },\n set(value) {\n this.$emit('update:checked', value);\n },\n },\n },\n\n created() {\n if (this.$attrs.onChange) {\n throw new Error('ll-radio: use the @update:checked event instead of @input');\n }\n },\n };\n</script>\n\n<template>\n <div class=\"
|
|
1
|
+
{"version":3,"file":"Radio.js","sources":["../src/components/Radio/Radio.vue"],"sourcesContent":["<script>\n import { useCssModule } from 'vue';\n\n /**\n * @deprecated use components/RadioNew/Radio instead.\n * if you need multiple Radio components considering using RadioGroup instead.\n */\n export default {\n name: 'll-radio',\n\n props: {\n /**\n * The checked/selected state of the radio button\n */\n checked: {\n type: [String, Number],\n default: undefined,\n },\n\n /**\n * Use :checked or v-model:checked instead of :model-value and v-model.\n */\n modelValue: {\n type: [String, Number, null],\n default: null,\n validator(value) {\n if (value !== null) {\n throw new Error('ll-radio: use :checked or v-model:checked instead of :model-value and v-model.');\n }\n\n return true;\n },\n },\n\n /**\n * Adds error styling\n */\n hasError: Boolean,\n\n /**\n * A unique string to distinguish one Radio instance from another\n * and to link the label to the input; required for accessibility\n */\n id: {\n type: String,\n required: true,\n },\n\n /**\n * The description which appears to the right of the radio button\n */\n label: {\n type: String,\n default: '',\n },\n },\n\n emits: ['update:checked'],\n\n setup() {\n return {\n classes: useCssModule(),\n };\n },\n\n computed: {\n internalValue: {\n get() {\n return this.checked;\n },\n set(value) {\n this.$emit('update:checked', value);\n },\n },\n },\n\n created() {\n if (this.$attrs.onChange) {\n throw new Error('ll-radio: use the @update:checked event instead of @input');\n }\n },\n };\n</script>\n\n<template>\n <div class=\"stash-radio\" data-test=\"ll-radio\" :class=\"[classes.root, { error: hasError }]\">\n <input :id=\"id\" v-model=\"internalValue\" class=\"tw-sr-only\" :class=\"classes.input\" type=\"radio\" v-bind=\"$attrs\" />\n\n <label :for=\"id\" :class=\"classes.label\">\n {{ label }}\n </label>\n </div>\n</template>\n\n<style module>\n .root {\n position: relative;\n margin: theme('spacing[1.5]') 0;\n }\n\n .label {\n color: var(--color-ice-700);\n cursor: pointer;\n display: inline-block;\n font-size: theme('fontSize.sm');\n font-weight: theme('fontWeight.normal');\n line-height: theme('spacing.6');\n min-height: theme('spacing.9');\n overflow: visible;\n padding: theme('spacing[1.5]') 0 theme('spacing[1.5]') calc(20px + theme('spacing.3'));\n position: relative;\n vertical-align: top;\n }\n\n .label::before {\n background: var(--color-white);\n border: 1px solid var(--color-ice-500);\n content: '';\n display: inline-block;\n vertical-align: top;\n }\n\n .label::before,\n .label::after {\n height: 20px;\n left: 0;\n position: absolute;\n top: 50%;\n transform: translateY(-50%);\n width: 20px;\n border-radius: 50%;\n }\n\n .error .label {\n color: var(--color-red-500);\n }\n\n .error .label::before,\n .error .input {\n border-color: var(--color-red-500);\n }\n\n .input:checked + .label::after {\n background: var(--color-blue-500);\n content: '';\n height: 14px;\n left: 3px;\n width: 14px;\n }\n\n .input:checked:disabled + .label::after {\n background: var(--color-ice-500);\n }\n\n .input:not(:disabled, :checked) + .label:hover::before {\n border-color: var(--color-blue-500);\n }\n\n @media screen('lg') {\n .root input {\n margin: 0;\n }\n }\n</style>\n"],"names":["_sfc_main","value","useCssModule","_createElementBlock","$setup","$props","_withDirectives","_createElementVNode","_mergeProps","$options","$event","_ctx","_hoisted_1","_normalizeClass","_hoisted_2"],"mappings":";;;;;;;GAOOA,IAAU;AAAA,EACb,MAAM;AAAA,EAEN,OAAO;AAAA;AAAA;AAAA;AAAA,IAIL,SAAS;AAAA,MACP,MAAM,CAAC,QAAQ,MAAM;AAAA,MACrB,SAAS;AAAA,IACV;AAAA;AAAA;AAAA;AAAA,IAKD,YAAY;AAAA,MACV,MAAM,CAAC,QAAQ,QAAQ,IAAI;AAAA,MAC3B,SAAS;AAAA,MACT,UAAUC,GAAO;AACf,YAAIA,MAAU;AACZ,gBAAM,IAAI,MAAM,gFAAgF;AAGlG,eAAO;AAAA,MACR;AAAA,IACF;AAAA;AAAA;AAAA;AAAA,IAKD,UAAU;AAAA;AAAA;AAAA;AAAA;AAAA,IAMV,IAAI;AAAA,MACF,MAAM;AAAA,MACN,UAAU;AAAA,IACX;AAAA;AAAA;AAAA;AAAA,IAKD,OAAO;AAAA,MACL,MAAM;AAAA,MACN,SAAS;AAAA,IACV;AAAA,EACF;AAAA,EAED,OAAO,CAAC,gBAAgB;AAAA,EAExB,QAAQ;AACN,WAAO;AAAA,MACL,SAASC,EAAc;AAAA;EAE1B;AAAA,EAED,UAAU;AAAA,IACR,eAAe;AAAA,MACb,MAAM;AACJ,eAAO,KAAK;AAAA,MACb;AAAA,MACD,IAAID,GAAO;AACT,aAAK,MAAM,kBAAkBA,CAAK;AAAA,MACnC;AAAA,IACF;AAAA,EACF;AAAA,EAED,UAAU;AACR,QAAI,KAAK,OAAO;AACd,YAAM,IAAI,MAAM,2DAA2D;AAAA,EAE9E;;;cAKHE,EAMM,OAAA;AAAA,IAND,UAAM,eAAa,CAA+BC,UAAQ,eAAeC,EAAQ,SAAA,CAAA,CAAA,CAAA;AAAA,IAA7D,aAAU;AAAA;IACjCC,EAAAC,EAAiH,SAAjHC,EAAiH;AAAA,MAAzG,IAAIH,EAAE;AAAA,oDAAWI,EAAa,gBAAAC;AAAA,MAAE,OAAM,CAAA,cAAqBN,EAAA,QAAQ,KAAK;AAAA,MAAE,MAAK;AAAA,OAAgBO,EAAM,MAAA,GAAA,MAAA,IAAAC,CAAA,GAAA;AAAA,UAApFH,EAAa,aAAA;AAAA;IAEtCF,EAEQ,SAAA;AAAA,MAFA,KAAKF,EAAE;AAAA,MAAG,OAAKQ,EAAET,EAAO,QAAC,KAAK;AAAA,SACjCC,EAAK,KAAA,GAAA,IAAAS,CAAA;AAAA;;;;;"}
|