@threadlabs/looma 0.47.2 → 0.47.4
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/components/ui-card/ui-card.html +39 -5
- package/components/ui-card-group/ui-card-group.html +29 -0
- package/components/ui-combobox/ui-combobox.html +2 -1
- package/components/ui-site-header/ui-site-header.html +7 -5
- package/components/ui-toast-region/ui-toast-region.html +2 -0
- package/dist/index.js +1 -1
- package/docs/catalog.json +131 -8
- package/package.json +1 -1
- package/styles/ui-card-group.css +41 -0
- package/styles/ui-card.css +19 -1
- package/styles/ui-combobox.css +4 -2
- package/styles/ui-site-header.css +14 -10
- package/styles/ui-toast-region.css +4 -0
- package/vanilla/UiCard.js +148 -36
- package/vanilla/UiCardGroup.d.ts +25 -0
- package/vanilla/UiCardGroup.js +59 -0
- package/vanilla/index.js +1 -0
- package/vue/UiCard.d.ts +20 -4
- package/vue/UiCard.vue +31 -5
- package/vue/UiCardGroup.d.ts +41 -0
- package/vue/UiCardGroup.js +2 -0
- package/vue/UiCardGroup.vue +168 -0
- package/vue/UiCombobox.vue +4 -2
- package/vue/UiSiteHeader.vue +12 -8
- package/vue/UiToastRegion.vue +4 -0
- package/vue/chunks/UiCard.js +73 -9
- package/vue/chunks/UiCardGroup.js +153 -0
- package/vue/chunks/UiCombobox.js +1 -1
- package/vue/chunks/UiSiteHeader.js +1 -1
- package/vue/chunks/UiToastRegion.js +1 -1
- package/vue/components.css +138 -83
- package/vue/index.d.ts +1 -0
- package/vue/index.js +3 -2
package/vue/chunks/UiCard.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { C as useReflectedProp, _ as nativeAttrs, a as checkHydratedRoot, t as _plugin_vue_export_helper_default, y as preserveRootFocus } from "./_plugin-vue_export-helper.js";
|
|
2
2
|
import { a as checkPropInput, g as vuePropInputs, h as vPropValidity, t as BINDING_INPUTS_PROP } from "./props.js";
|
|
3
|
-
import { computed, createElementBlock, defineComponent, mergeProps, openBlock, renderSlot, unref, useTemplateRef, watchSyncEffect, withDirectives } from "vue";
|
|
3
|
+
import { computed, createElementBlock, createElementVNode, defineComponent, mergeProps, openBlock, renderSlot, unref, useTemplateRef, watchSyncEffect, withDirectives } from "vue";
|
|
4
4
|
//#region .build/vue/UiCard.vue?vue&type=script&setup=true&lang.ts
|
|
5
5
|
var _hoisted_1 = [
|
|
6
6
|
"data-ui-card-prop-as",
|
|
@@ -11,7 +11,19 @@ var _hoisted_1 = [
|
|
|
11
11
|
"data-ui-card-prop-variant",
|
|
12
12
|
"data-ui-card-state"
|
|
13
13
|
];
|
|
14
|
-
var _hoisted_2 =
|
|
14
|
+
var _hoisted_2 = {
|
|
15
|
+
class: "header",
|
|
16
|
+
"data-hn-ui-card": ""
|
|
17
|
+
};
|
|
18
|
+
var _hoisted_3 = {
|
|
19
|
+
class: "content",
|
|
20
|
+
"data-hn-ui-card": ""
|
|
21
|
+
};
|
|
22
|
+
var _hoisted_4 = {
|
|
23
|
+
class: "actions",
|
|
24
|
+
"data-hn-ui-card": ""
|
|
25
|
+
};
|
|
26
|
+
var _hoisted_5 = [
|
|
15
27
|
"data-ui-card-prop-as",
|
|
16
28
|
"data-ui-card-prop-padding",
|
|
17
29
|
"data-ui-card-prop-size",
|
|
@@ -20,7 +32,19 @@ var _hoisted_2 = [
|
|
|
20
32
|
"data-ui-card-prop-variant",
|
|
21
33
|
"data-ui-card-state"
|
|
22
34
|
];
|
|
23
|
-
var
|
|
35
|
+
var _hoisted_6 = {
|
|
36
|
+
class: "header",
|
|
37
|
+
"data-hn-ui-card": ""
|
|
38
|
+
};
|
|
39
|
+
var _hoisted_7 = {
|
|
40
|
+
class: "content",
|
|
41
|
+
"data-hn-ui-card": ""
|
|
42
|
+
};
|
|
43
|
+
var _hoisted_8 = {
|
|
44
|
+
class: "actions",
|
|
45
|
+
"data-hn-ui-card": ""
|
|
46
|
+
};
|
|
47
|
+
var _hoisted_9 = [
|
|
24
48
|
"data-ui-card-prop-as",
|
|
25
49
|
"data-ui-card-prop-padding",
|
|
26
50
|
"data-ui-card-prop-size",
|
|
@@ -29,7 +53,19 @@ var _hoisted_3 = [
|
|
|
29
53
|
"data-ui-card-prop-variant",
|
|
30
54
|
"data-ui-card-state"
|
|
31
55
|
];
|
|
32
|
-
var
|
|
56
|
+
var _hoisted_10 = {
|
|
57
|
+
class: "header",
|
|
58
|
+
"data-hn-ui-card": ""
|
|
59
|
+
};
|
|
60
|
+
var _hoisted_11 = {
|
|
61
|
+
class: "content",
|
|
62
|
+
"data-hn-ui-card": ""
|
|
63
|
+
};
|
|
64
|
+
var _hoisted_12 = {
|
|
65
|
+
class: "actions",
|
|
66
|
+
"data-hn-ui-card": ""
|
|
67
|
+
};
|
|
68
|
+
var _hoisted_13 = [
|
|
33
69
|
"data-ui-card-prop-as",
|
|
34
70
|
"data-ui-card-prop-padding",
|
|
35
71
|
"data-ui-card-prop-size",
|
|
@@ -38,6 +74,18 @@ var _hoisted_4 = [
|
|
|
38
74
|
"data-ui-card-prop-variant",
|
|
39
75
|
"data-ui-card-state"
|
|
40
76
|
];
|
|
77
|
+
var _hoisted_14 = {
|
|
78
|
+
class: "header",
|
|
79
|
+
"data-hn-ui-card": ""
|
|
80
|
+
};
|
|
81
|
+
var _hoisted_15 = {
|
|
82
|
+
class: "content",
|
|
83
|
+
"data-hn-ui-card": ""
|
|
84
|
+
};
|
|
85
|
+
var _hoisted_16 = {
|
|
86
|
+
class: "actions",
|
|
87
|
+
"data-hn-ui-card": ""
|
|
88
|
+
};
|
|
41
89
|
//#endregion
|
|
42
90
|
//#region .build/vue/UiCard.vue
|
|
43
91
|
var UiCard_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
@@ -243,7 +291,11 @@ var UiCard_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE_
|
|
|
243
291
|
"data-ui-card-prop-variant": unref(reflectedProp)("variant", "variant", checkedProps.value.variant, void 0, false),
|
|
244
292
|
"data-ui-card-state": hostState.value || void 0,
|
|
245
293
|
ref: "@html-next/root"
|
|
246
|
-
}), [
|
|
294
|
+
}), [
|
|
295
|
+
createElementVNode("div", _hoisted_2, [renderSlot(_ctx.$slots, "header", {}, void 0, true)]),
|
|
296
|
+
createElementVNode("div", _hoisted_3, [renderSlot(_ctx.$slots, "default", {}, void 0, true)]),
|
|
297
|
+
createElementVNode("div", _hoisted_4, [renderSlot(_ctx.$slots, "actions", {}, void 0, true)])
|
|
298
|
+
], 16, _hoisted_1)), [[unref(vPropValidity), {
|
|
247
299
|
contract: propValidityContract,
|
|
248
300
|
values: { ...props }
|
|
249
301
|
}]]) : checkedProps.value.as === "article" ? withDirectives((openBlock(), createElementBlock("article", mergeProps({
|
|
@@ -260,7 +312,11 @@ var UiCard_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE_
|
|
|
260
312
|
"data-ui-card-prop-variant": unref(reflectedProp)("variant", "variant", checkedProps.value.variant, void 0, false),
|
|
261
313
|
"data-ui-card-state": hostState.value || void 0,
|
|
262
314
|
ref: "@html-next/root"
|
|
263
|
-
}), [
|
|
315
|
+
}), [
|
|
316
|
+
createElementVNode("div", _hoisted_6, [renderSlot(_ctx.$slots, "header", {}, void 0, true)]),
|
|
317
|
+
createElementVNode("div", _hoisted_7, [renderSlot(_ctx.$slots, "default", {}, void 0, true)]),
|
|
318
|
+
createElementVNode("div", _hoisted_8, [renderSlot(_ctx.$slots, "actions", {}, void 0, true)])
|
|
319
|
+
], 16, _hoisted_5)), [[unref(vPropValidity), {
|
|
264
320
|
contract: propValidityContract,
|
|
265
321
|
values: { ...props }
|
|
266
322
|
}]]) : checkedProps.value.as === "aside" ? withDirectives((openBlock(), createElementBlock("aside", mergeProps({
|
|
@@ -277,7 +333,11 @@ var UiCard_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE_
|
|
|
277
333
|
"data-ui-card-prop-variant": unref(reflectedProp)("variant", "variant", checkedProps.value.variant, void 0, false),
|
|
278
334
|
"data-ui-card-state": hostState.value || void 0,
|
|
279
335
|
ref: "@html-next/root"
|
|
280
|
-
}), [
|
|
336
|
+
}), [
|
|
337
|
+
createElementVNode("div", _hoisted_10, [renderSlot(_ctx.$slots, "header", {}, void 0, true)]),
|
|
338
|
+
createElementVNode("div", _hoisted_11, [renderSlot(_ctx.$slots, "default", {}, void 0, true)]),
|
|
339
|
+
createElementVNode("div", _hoisted_12, [renderSlot(_ctx.$slots, "actions", {}, void 0, true)])
|
|
340
|
+
], 16, _hoisted_9)), [[unref(vPropValidity), {
|
|
281
341
|
contract: propValidityContract,
|
|
282
342
|
values: { ...props }
|
|
283
343
|
}]]) : withDirectives((openBlock(), createElementBlock("div", mergeProps({
|
|
@@ -294,12 +354,16 @@ var UiCard_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE_
|
|
|
294
354
|
"data-ui-card-prop-variant": unref(reflectedProp)("variant", "variant", checkedProps.value.variant, void 0, false),
|
|
295
355
|
"data-ui-card-state": hostState.value || void 0,
|
|
296
356
|
ref: "@html-next/root"
|
|
297
|
-
}), [
|
|
357
|
+
}), [
|
|
358
|
+
createElementVNode("div", _hoisted_14, [renderSlot(_ctx.$slots, "header", {}, void 0, true)]),
|
|
359
|
+
createElementVNode("div", _hoisted_15, [renderSlot(_ctx.$slots, "default", {}, void 0, true)]),
|
|
360
|
+
createElementVNode("div", _hoisted_16, [renderSlot(_ctx.$slots, "actions", {}, void 0, true)])
|
|
361
|
+
], 16, _hoisted_13)), [[unref(vPropValidity), {
|
|
298
362
|
contract: propValidityContract,
|
|
299
363
|
values: { ...props }
|
|
300
364
|
}]]);
|
|
301
365
|
};
|
|
302
366
|
}
|
|
303
|
-
}), [["__scopeId", "data-v-
|
|
367
|
+
}), [["__scopeId", "data-v-54ed7533"]]);
|
|
304
368
|
//#endregion
|
|
305
369
|
export { UiCard_default as t };
|
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
import { C as useReflectedProp, _ as nativeAttrs, a as checkHydratedRoot, t as _plugin_vue_export_helper_default } from "./_plugin-vue_export-helper.js";
|
|
2
|
+
import { a as checkPropInput, g as vuePropInputs, h as vPropValidity, p as requireInputStatus, t as BINDING_INPUTS_PROP } from "./props.js";
|
|
3
|
+
import { t as UiGrid_default } from "./UiGrid.js";
|
|
4
|
+
import { computed, createElementBlock, createVNode, defineComponent, mergeProps, openBlock, renderSlot, unref, watchSyncEffect, withCtx, withDirectives } from "vue";
|
|
5
|
+
//#region .build/vue/UiCardGroup.vue?vue&type=script&setup=true&lang.ts
|
|
6
|
+
var _hoisted_1 = [
|
|
7
|
+
"data-ui-card-group-prop-columns",
|
|
8
|
+
"data-ui-card-group-prop-gap",
|
|
9
|
+
"data-ui-card-group-prop-min"
|
|
10
|
+
];
|
|
11
|
+
//#endregion
|
|
12
|
+
//#region .build/vue/UiCardGroup.vue
|
|
13
|
+
var UiCardGroup_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
14
|
+
inheritAttrs: false,
|
|
15
|
+
__name: "UiCardGroup",
|
|
16
|
+
props: {
|
|
17
|
+
columns: { type: null },
|
|
18
|
+
gap: { type: null },
|
|
19
|
+
min: { type: null },
|
|
20
|
+
[BINDING_INPUTS_PROP]: { type: null }
|
|
21
|
+
},
|
|
22
|
+
setup(__props) {
|
|
23
|
+
const propValidityContract = { props: {
|
|
24
|
+
columns: {
|
|
25
|
+
type: {
|
|
26
|
+
kind: "terminal",
|
|
27
|
+
name: "integer"
|
|
28
|
+
},
|
|
29
|
+
required: false,
|
|
30
|
+
target: { attribute: "columns" },
|
|
31
|
+
description: "Maximum columns when there is room. Omit for no cap; cards wrap as the container narrows."
|
|
32
|
+
},
|
|
33
|
+
gap: {
|
|
34
|
+
type: {
|
|
35
|
+
kind: "terminal",
|
|
36
|
+
name: "keyword"
|
|
37
|
+
},
|
|
38
|
+
required: false,
|
|
39
|
+
target: { attribute: "gap" },
|
|
40
|
+
description: "Space between cards, using Grid’s spacing scale. Grid’s public --ui-grid-gap custom property also applies.",
|
|
41
|
+
values: [
|
|
42
|
+
"xs",
|
|
43
|
+
"s",
|
|
44
|
+
"m",
|
|
45
|
+
"l",
|
|
46
|
+
"xl"
|
|
47
|
+
],
|
|
48
|
+
default: "l"
|
|
49
|
+
},
|
|
50
|
+
min: {
|
|
51
|
+
type: {
|
|
52
|
+
kind: "terminal",
|
|
53
|
+
name: "keyword"
|
|
54
|
+
},
|
|
55
|
+
required: false,
|
|
56
|
+
target: { attribute: "min" },
|
|
57
|
+
description: "Minimum card column width: sm is 12rem, md 16rem and lg 20rem. A narrower container still fits one column.",
|
|
58
|
+
values: [
|
|
59
|
+
"sm",
|
|
60
|
+
"md",
|
|
61
|
+
"lg"
|
|
62
|
+
],
|
|
63
|
+
default: "lg"
|
|
64
|
+
}
|
|
65
|
+
} };
|
|
66
|
+
const props = __props;
|
|
67
|
+
const inputTracking = vuePropInputs({
|
|
68
|
+
columns: null,
|
|
69
|
+
gap: "l",
|
|
70
|
+
min: "lg"
|
|
71
|
+
}, {
|
|
72
|
+
gap: "l",
|
|
73
|
+
min: "lg"
|
|
74
|
+
}, (name, value, source, values) => {
|
|
75
|
+
switch (name) {
|
|
76
|
+
case "columns": return checkPropInput(value, {
|
|
77
|
+
kind: "terminal",
|
|
78
|
+
name: "integer"
|
|
79
|
+
}, true, true);
|
|
80
|
+
case "gap": return checkPropInput(value, {
|
|
81
|
+
kind: "terminal",
|
|
82
|
+
name: "keyword"
|
|
83
|
+
}, true, true);
|
|
84
|
+
case "min": return checkPropInput(value, {
|
|
85
|
+
kind: "terminal",
|
|
86
|
+
name: "keyword"
|
|
87
|
+
}, true, true);
|
|
88
|
+
default: return { ok: false };
|
|
89
|
+
}
|
|
90
|
+
}, () => {
|
|
91
|
+
checkedProps.value;
|
|
92
|
+
});
|
|
93
|
+
const propInputs = inputTracking.inputs;
|
|
94
|
+
const checkedProps = computed(() => {
|
|
95
|
+
inputTracking.version.value;
|
|
96
|
+
return {
|
|
97
|
+
columns: propInputs.value("columns", props["columns"], props[BINDING_INPUTS_PROP]),
|
|
98
|
+
gap: propInputs.value("gap", props["gap"], props[BINDING_INPUTS_PROP]),
|
|
99
|
+
min: propInputs.value("min", props["min"], props[BINDING_INPUTS_PROP])
|
|
100
|
+
};
|
|
101
|
+
});
|
|
102
|
+
const inputStatus = (name, handlesError) => {
|
|
103
|
+
checkedProps.value;
|
|
104
|
+
inputTracking.version.value;
|
|
105
|
+
return requireInputStatus(propInputs.status(name), handlesError);
|
|
106
|
+
};
|
|
107
|
+
checkedProps.value;
|
|
108
|
+
watchSyncEffect(() => {
|
|
109
|
+
checkedProps.value;
|
|
110
|
+
});
|
|
111
|
+
const reflectedProp = useReflectedProp();
|
|
112
|
+
checkHydratedRoot("div", "ui-card-group");
|
|
113
|
+
return (_ctx, _cache) => {
|
|
114
|
+
return withDirectives((openBlock(), createElementBlock("div", mergeProps({ class: "ui-card-group" }, unref(nativeAttrs)(_ctx.$attrs), {
|
|
115
|
+
"data-hn": "",
|
|
116
|
+
"data-hn-ui-card-group": "",
|
|
117
|
+
"data-ui-card-group-prop-columns": unref(reflectedProp)("columns", "columns", checkedProps.value.columns, void 0, false),
|
|
118
|
+
"data-ui-card-group-prop-gap": unref(reflectedProp)("gap", "gap", checkedProps.value.gap, void 0, false),
|
|
119
|
+
"data-ui-card-group-prop-min": unref(reflectedProp)("min", "min", checkedProps.value.min, void 0, false)
|
|
120
|
+
}), [createVNode(UiGrid_default, mergeProps({
|
|
121
|
+
class: "ui-grid",
|
|
122
|
+
gap: checkedProps.value.gap,
|
|
123
|
+
min: checkedProps.value.min,
|
|
124
|
+
columns: checkedProps.value.columns
|
|
125
|
+
}, { [unref(BINDING_INPUTS_PROP)]: {
|
|
126
|
+
gap: () => ({
|
|
127
|
+
value: checkedProps.value.gap,
|
|
128
|
+
status: inputStatus("gap", true)
|
|
129
|
+
}),
|
|
130
|
+
min: () => ({
|
|
131
|
+
value: checkedProps.value.min,
|
|
132
|
+
status: inputStatus("min", true)
|
|
133
|
+
}),
|
|
134
|
+
columns: () => ({
|
|
135
|
+
value: checkedProps.value.columns,
|
|
136
|
+
status: inputStatus("columns", true)
|
|
137
|
+
})
|
|
138
|
+
} }), {
|
|
139
|
+
default: withCtx(() => [renderSlot(_ctx.$slots, "default", {}, void 0, true)]),
|
|
140
|
+
_: 3
|
|
141
|
+
}, 16, [
|
|
142
|
+
"gap",
|
|
143
|
+
"min",
|
|
144
|
+
"columns"
|
|
145
|
+
])], 16, _hoisted_1)), [[unref(vPropValidity), {
|
|
146
|
+
contract: propValidityContract,
|
|
147
|
+
values: { ...props }
|
|
148
|
+
}]]);
|
|
149
|
+
};
|
|
150
|
+
}
|
|
151
|
+
}), [["__scopeId", "data-v-f5544ff3"]]);
|
|
152
|
+
//#endregion
|
|
153
|
+
export { UiCardGroup_default as t };
|
package/vue/chunks/UiCombobox.js
CHANGED
|
@@ -2181,6 +2181,6 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
2181
2181
|
}]]);
|
|
2182
2182
|
};
|
|
2183
2183
|
}
|
|
2184
|
-
}), [["__scopeId", "data-v-
|
|
2184
|
+
}), [["__scopeId", "data-v-ddbc2c44"]]);
|
|
2185
2185
|
//#endregion
|
|
2186
2186
|
export { UiCombobox_default as t };
|