nuance-ui 0.2.19 → 0.2.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/dist/module.json +1 -1
- package/dist/runtime/components/action-icon/action-icon.d.vue.ts +1 -1
- package/dist/runtime/components/action-icon/action-icon.module.css +1 -1
- package/dist/runtime/components/action-icon/action-icon.vue.d.ts +1 -1
- package/dist/runtime/components/alert.vue +1 -1
- package/dist/runtime/components/badge.vue +1 -1
- package/dist/runtime/components/button/button.d.vue.ts +1 -1
- package/dist/runtime/components/button/button.module.css +1 -1
- package/dist/runtime/components/button/button.vue.d.ts +1 -1
- package/dist/runtime/components/calendar/ui/core/calendar-cell.d.vue.ts +1 -1
- package/dist/runtime/components/calendar/ui/core/calendar-cell.vue.d.ts +1 -1
- package/dist/runtime/components/calendar/ui/core/calendar-header.vue +1 -1
- package/dist/runtime/components/calendar/ui/levels/calendar-month.vue +1 -1
- package/dist/runtime/components/checkbox/checkbox.vue +1 -1
- package/dist/runtime/components/chip/chip.vue +1 -1
- package/dist/runtime/components/combobox/combobox.module.css +1 -1
- package/dist/runtime/components/dialog/index.d.ts +2 -0
- package/dist/runtime/components/dialog/ui/dialog-footer.d.vue.ts +16 -0
- package/dist/runtime/components/dialog/ui/dialog-footer.vue +16 -0
- package/dist/runtime/components/dialog/ui/dialog-footer.vue.d.ts +16 -0
- package/dist/runtime/components/dialog/ui/dialog-root.d.vue.ts +2 -2
- package/dist/runtime/components/dialog/ui/dialog-root.vue +9 -4
- package/dist/runtime/components/dialog/ui/dialog-root.vue.d.ts +2 -2
- package/dist/runtime/components/dialog/ui/dialog-section.d.vue.ts +17 -0
- package/dist/runtime/components/dialog/ui/dialog-section.vue +17 -0
- package/dist/runtime/components/dialog/ui/dialog-section.vue.d.ts +17 -0
- package/dist/runtime/components/dialog/ui/dialog.module.css +1 -1
- package/dist/runtime/components/drawer/drawer-footer.d.vue.ts +16 -0
- package/dist/runtime/components/drawer/drawer-footer.vue +13 -0
- package/dist/runtime/components/drawer/drawer-footer.vue.d.ts +16 -0
- package/dist/runtime/components/drawer/drawer-root.vue +1 -0
- package/dist/runtime/components/drawer/drawer-section.d.vue.ts +16 -0
- package/dist/runtime/components/drawer/drawer-section.vue +14 -0
- package/dist/runtime/components/drawer/drawer-section.vue.d.ts +16 -0
- package/dist/runtime/components/drawer/index.d.ts +2 -0
- package/dist/runtime/components/input/password-input.d.vue.ts +5 -5
- package/dist/runtime/components/input/password-input.vue +1 -2
- package/dist/runtime/components/input/password-input.vue.d.ts +5 -5
- package/dist/runtime/components/input/ui/button-input.d.vue.ts +1 -1
- package/dist/runtime/components/input/ui/button-input.vue.d.ts +1 -1
- package/dist/runtime/components/input/ui/input-base.vue +3 -3
- package/dist/runtime/components/input/ui/input-inline.vue +1 -1
- package/dist/runtime/components/input/ui/input-label.vue +1 -1
- package/dist/runtime/components/input/ui/input-wrapper.vue +1 -1
- package/dist/runtime/components/modal/index.d.ts +0 -2
- package/dist/runtime/components/modal/modal-footer.d.vue.ts +14 -0
- package/dist/runtime/components/modal/modal-footer.vue +13 -0
- package/dist/runtime/components/modal/modal-footer.vue.d.ts +14 -0
- package/dist/runtime/components/modal/modal-header.d.vue.ts +1 -3
- package/dist/runtime/components/modal/modal-header.vue.d.ts +1 -3
- package/dist/runtime/components/modal/modal-root.d.vue.ts +1 -2
- package/dist/runtime/components/modal/modal-root.vue +3 -1
- package/dist/runtime/components/modal/modal-root.vue.d.ts +1 -2
- package/dist/runtime/components/modal/modal-section.d.vue.ts +14 -0
- package/dist/runtime/components/modal/modal-section.vue +14 -0
- package/dist/runtime/components/modal/modal-section.vue.d.ts +14 -0
- package/dist/runtime/components/modal/modal-title.d.vue.ts +1 -3
- package/dist/runtime/components/modal/modal-title.vue.d.ts +1 -3
- package/dist/runtime/components/nav-link/nav-link.vue +1 -1
- package/dist/runtime/components/pin-input/pin-input.vue +2 -2
- package/dist/runtime/components/segmented-control.d.vue.ts +2 -1
- package/dist/runtime/components/segmented-control.vue +5 -2
- package/dist/runtime/components/segmented-control.vue.d.ts +2 -1
- package/dist/runtime/components/table/ui/table.vue +1 -1
- package/dist/runtime/components/tabs/lib.d.ts +26 -26
- package/dist/runtime/components/tabs/lib.js +1 -1
- package/dist/runtime/components/tabs/tabs-list.vue +5 -5
- package/dist/runtime/components/tabs/tabs-panel.vue +1 -1
- package/dist/runtime/components/tabs/tabs-root.d.vue.ts +5 -1
- package/dist/runtime/components/tabs/tabs-root.vue +16 -30
- package/dist/runtime/components/tabs/tabs-root.vue.d.ts +5 -1
- package/dist/runtime/components/tabs/tabs-tab.vue +4 -4
- package/dist/runtime/components/tabs/tabs.module.css +1 -1
- package/dist/runtime/components/text.vue +1 -1
- package/dist/runtime/components/time-picker/time-picker.vue +1 -1
- package/dist/runtime/components/tree/_ui/tree-item.vue +1 -0
- package/dist/runtime/components/tree/_ui/tree-root.vue +1 -1
- package/dist/runtime/components/tree/tree.vue +1 -1
- package/dist/runtime/modals/_confirm-modal/confirm-modal.vue +16 -6
- package/dist/runtime/styles/const.css +1 -1
- package/dist/runtime/types/styling.d.ts +2 -1
- package/package.json +2 -1
|
@@ -1,26 +1,14 @@
|
|
|
1
1
|
<script setup>
|
|
2
2
|
import { useVarsResolver } from "@nui/composables";
|
|
3
3
|
import { getRadius, getThemeColor } from "@nui/utils";
|
|
4
|
-
import { onMounted, useId } from "vue";
|
|
4
|
+
import { computed, onMounted, toRefs, useId } from "vue";
|
|
5
5
|
import Box from "../box.vue";
|
|
6
6
|
import { getSafeId, useProvideTabsContext } from "./lib";
|
|
7
7
|
import css from "./tabs.module.css";
|
|
8
|
-
const {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
radius,
|
|
13
|
-
color,
|
|
14
|
-
placement = "left",
|
|
15
|
-
inverted,
|
|
16
|
-
orientation = "horizontal",
|
|
17
|
-
variant = "default",
|
|
18
|
-
defaultTab,
|
|
19
|
-
...rest
|
|
20
|
-
} = defineProps({
|
|
21
|
-
orientation: { type: String, required: false },
|
|
22
|
-
placement: { type: String, required: false },
|
|
23
|
-
variant: { type: String, required: false },
|
|
8
|
+
const props = defineProps({
|
|
9
|
+
orientation: { type: String, required: false, default: "horizontal" },
|
|
10
|
+
placement: { type: String, required: false, default: "left" },
|
|
11
|
+
variant: { type: String, required: false, default: "default" },
|
|
24
12
|
color: { type: null, required: false },
|
|
25
13
|
radius: { type: [String, Number], required: false },
|
|
26
14
|
inverted: { type: Boolean, required: false },
|
|
@@ -33,36 +21,34 @@ const {
|
|
|
33
21
|
is: { type: null, required: false },
|
|
34
22
|
mod: { type: [Object, Array, null], required: false }
|
|
35
23
|
});
|
|
36
|
-
const uid = id ?? useId();
|
|
24
|
+
const uid = computed(() => props.id ?? useId());
|
|
37
25
|
const active = defineModel({ type: [String, null], ...{ default: null } });
|
|
38
26
|
onMounted(() => {
|
|
39
|
-
if (active.value === null && defaultTab) {
|
|
40
|
-
active.value = defaultTab;
|
|
27
|
+
if (active.value === null && props.defaultTab) {
|
|
28
|
+
active.value = props.defaultTab;
|
|
41
29
|
}
|
|
42
30
|
});
|
|
43
31
|
const style = useVarsResolver((theme) => ({
|
|
44
32
|
root: {
|
|
45
|
-
"--tabs-radius": getRadius(radius),
|
|
46
|
-
"--tabs-color": getThemeColor(color, theme)
|
|
33
|
+
"--tabs-radius": getRadius(props.radius),
|
|
34
|
+
"--tabs-color": getThemeColor(props.color, theme)
|
|
47
35
|
}
|
|
48
36
|
}));
|
|
49
37
|
const VALUE_ERROR = "component was rendered with invalid value or without value";
|
|
38
|
+
const refs = toRefs(props);
|
|
50
39
|
useProvideTabsContext({
|
|
51
|
-
...
|
|
52
|
-
id: uid,
|
|
53
|
-
getTabId: getSafeId(`${uid}-tab`, `TabsTab ${VALUE_ERROR}`),
|
|
54
|
-
getPanelId: getSafeId(`${uid}-panel`, `TabsPanel ${VALUE_ERROR}`),
|
|
55
|
-
variant,
|
|
40
|
+
...refs,
|
|
56
41
|
active,
|
|
57
|
-
|
|
58
|
-
|
|
42
|
+
id: uid,
|
|
43
|
+
getTabId: getSafeId(`${uid.value}-tab`, `TabsTab ${VALUE_ERROR}`),
|
|
44
|
+
getPanelId: getSafeId(`${uid.value}-panel`, `TabsPanel ${VALUE_ERROR}`)
|
|
59
45
|
});
|
|
60
46
|
</script>
|
|
61
47
|
|
|
62
48
|
<template>
|
|
63
49
|
<Box
|
|
64
50
|
:is
|
|
65
|
-
:style
|
|
51
|
+
:style='style.root'
|
|
66
52
|
:mod='[mod, {
|
|
67
53
|
orientation,
|
|
68
54
|
inverted: orientation === "horizontal" && inverted,
|
|
@@ -61,7 +61,11 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {}, {
|
|
|
61
61
|
"update:modelValue": (value: string | null) => any;
|
|
62
62
|
}, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
63
63
|
"onUpdate:modelValue"?: ((value: string | null) => any) | undefined;
|
|
64
|
-
}>, {
|
|
64
|
+
}>, {
|
|
65
|
+
orientation: "vertical" | "horizontal";
|
|
66
|
+
variant: TabsVariant;
|
|
67
|
+
placement: "left" | "right";
|
|
68
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
65
69
|
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
66
70
|
declare const _default: typeof __VLS_export;
|
|
67
71
|
export default _default;
|
|
@@ -16,11 +16,11 @@ const active = computed(() => value === ctx?.active.value);
|
|
|
16
16
|
<UnstyledButton
|
|
17
17
|
:id='ctx?.getTabId(value)'
|
|
18
18
|
:mod='[mod, {
|
|
19
|
-
variant: ctx?.variant,
|
|
19
|
+
variant: ctx?.variant.value,
|
|
20
20
|
active,
|
|
21
|
-
orientation: ctx?.orientation,
|
|
22
|
-
inverted: ctx?.inverted,
|
|
23
|
-
placement: ctx?.orientation === "vertical" && ctx.placement
|
|
21
|
+
orientation: ctx?.orientation.value,
|
|
22
|
+
inverted: ctx?.inverted.value,
|
|
23
|
+
placement: ctx?.orientation.value === "vertical" && ctx.placement.value
|
|
24
24
|
}]'
|
|
25
25
|
:class='css.tab'
|
|
26
26
|
role='tab'
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.root{--tabs-radius:var(--radius-default);--tabs-color:var(--radius-default);@mixin light{--tab-border-color:var(--color-gray-3)}@mixin dark{--tab-border-color:var(--color-dark-4)}display:var(--tabs-display);flex-direction:var(--tabs-flex-direction);--tabs-list-direction:row;--tabs-panel-grow:unset;--tabs-display:grid;--tabs-flex-direction:row;--tabs-list-border-width:0;--tabs-list-border-size:0 0 var(--tabs-list-border-width) 0;--tabs-list-gap:unset;--tabs-list-line-bottom:0;--tabs-list-line-top:unset;--tabs-list-line-start:0;--tabs-list-line-end:0;--tab-radius:var(--tabs-radius) var(--tabs-radius) 0 0;--tab-border-width:0 0 var(--tabs-list-border-width) 0}.root[data-inverted]{--tabs-list-line-bottom:unset;--tabs-list-line-top:0;--tab-radius:0 0 var(--tabs-radius) var(--tabs-radius);--tab-border-width:var(--tabs-list-border-width) 0 0 0}.root[data-inverted] .list--default:before{bottom:unset;top:0}.root[data-orientation=vertical]{--tabs-list-line-start:unset;--tabs-list-line-end:0;--tabs-list-line-top:0;--tabs-list-line-bottom:0;--tabs-list-border-size:0 var(--tabs-list-border-width) 0 0;--tab-border-width:0 var(--tabs-list-border-width) 0 0;--tab-radius:var(--tabs-radius) 0 0 var(--tabs-radius);--tabs-list-direction:column;--tabs-panel-grow:1;--tabs-display:flex;@mixin rtl{--tabs-list-border-size:0 0 0 var(--tabs-list-border-width);--tab-border-width:0 0 0 var(--tabs-list-border-width);--tab-radius:0 var(--tabs-radius) var(--tabs-radius) 0}}.root[data-orientation=vertical][data-placement=right]{--tabs-flex-direction:row-reverse;--tabs-list-line-start:0;--tabs-list-line-end:unset;--tabs-list-border-size:0 0 0 var(--tabs-list-border-width);--tab-border-width:0 0 0 var(--tabs-list-border-width);--tab-radius:0 var(--tabs-radius) var(--tabs-radius) 0;@mixin rtl{--tabs-list-border-size:0 var(--tabs-list-border-width) 0 0;--tab-border-width:0 var(--tabs-list-border-width) 0 0;--tab-radius:var(--tabs-radius) 0 0 var(--tabs-radius)}}.root[data-variant=default]{--tabs-list-border-width:2px;@mixin light{--tab-hover-color:var(--color-gray-0)}@mixin dark{--tab-hover-color:var(--color-dark-6)}}.root[data-variant=outline]{--tabs-list-border-width:1px}.root[data-variant=pills]{--tabs-list-gap:calc(var(--spacing-sm)/2);@mixin light{--tab-hover-color:var(--color-gray-0)}@mixin dark{--tab-hover-color:var(--color-dark-6)}}.list{--tabs-justify:flex-start;display:flex;flex-direction:var(--tabs-list-direction);flex-wrap:wrap;gap:var(--tabs-list-gap);justify-content:var(--tabs-justify)}.list:where([data-grow]) .tab{flex:1}.panel{flex-grow:var(--tabs-panel-grow)}.panel[data-active=false]{display:none}.tab{align-items:center;display:flex;font-size:var(--font-size-
|
|
1
|
+
.root{--tabs-radius:var(--radius-default);--tabs-color:var(--radius-default);@mixin light{--tab-border-color:var(--color-gray-3)}@mixin dark{--tab-border-color:var(--color-dark-4)}display:var(--tabs-display);flex-direction:var(--tabs-flex-direction);--tabs-list-direction:row;--tabs-panel-grow:unset;--tabs-display:grid;--tabs-flex-direction:row;--tabs-list-border-width:0;--tabs-list-border-size:0 0 var(--tabs-list-border-width) 0;--tabs-list-gap:unset;--tabs-list-line-bottom:0;--tabs-list-line-top:unset;--tabs-list-line-start:0;--tabs-list-line-end:0;--tab-radius:var(--tabs-radius) var(--tabs-radius) 0 0;--tab-border-width:0 0 var(--tabs-list-border-width) 0}.root[data-inverted]{--tabs-list-line-bottom:unset;--tabs-list-line-top:0;--tab-radius:0 0 var(--tabs-radius) var(--tabs-radius);--tab-border-width:var(--tabs-list-border-width) 0 0 0}.root[data-inverted] .list--default:before{bottom:unset;top:0}.root[data-orientation=vertical]{--tabs-list-line-start:unset;--tabs-list-line-end:0;--tabs-list-line-top:0;--tabs-list-line-bottom:0;--tabs-list-border-size:0 var(--tabs-list-border-width) 0 0;--tab-border-width:0 var(--tabs-list-border-width) 0 0;--tab-radius:var(--tabs-radius) 0 0 var(--tabs-radius);--tabs-list-direction:column;--tabs-panel-grow:1;--tabs-display:flex;@mixin rtl{--tabs-list-border-size:0 0 0 var(--tabs-list-border-width);--tab-border-width:0 0 0 var(--tabs-list-border-width);--tab-radius:0 var(--tabs-radius) var(--tabs-radius) 0}}.root[data-orientation=vertical][data-placement=right]{--tabs-flex-direction:row-reverse;--tabs-list-line-start:0;--tabs-list-line-end:unset;--tabs-list-border-size:0 0 0 var(--tabs-list-border-width);--tab-border-width:0 0 0 var(--tabs-list-border-width);--tab-radius:0 var(--tabs-radius) var(--tabs-radius) 0;@mixin rtl{--tabs-list-border-size:0 var(--tabs-list-border-width) 0 0;--tab-border-width:0 var(--tabs-list-border-width) 0 0;--tab-radius:var(--tabs-radius) 0 0 var(--tabs-radius)}}.root[data-variant=default]{--tabs-list-border-width:2px;@mixin light{--tab-hover-color:var(--color-gray-0)}@mixin dark{--tab-hover-color:var(--color-dark-6)}}.root[data-variant=outline]{--tabs-list-border-width:1px}.root[data-variant=pills]{--tabs-list-gap:calc(var(--spacing-sm)/2);@mixin light{--tab-hover-color:var(--color-gray-0)}@mixin dark{--tab-hover-color:var(--color-dark-6)}}.list{--tabs-justify:flex-start;display:flex;flex-direction:var(--tabs-list-direction);flex-wrap:wrap;gap:var(--tabs-list-gap);justify-content:var(--tabs-justify)}.list:where([data-grow]) .tab{flex:1}.panel{flex-grow:var(--tabs-panel-grow)}.panel[data-active=false]{display:none}.tab{align-items:center;display:flex;font-size:var(--font-size-md);line-height:1;padding:var(--spacing-xs) var(--spacing-md);position:relative;-webkit-user-select:none;-moz-user-select:none;user-select:none;white-space:nowrap;z-index:0}.tab:where(:disabled,[data-disabled]){cursor:not-allowed;opacity:.5}.tab:focus{z-index:1}.tabSection{align-items:center;display:flex;justify-content:center}.tabSection:where([data-position=left]:not(:only-child)){margin-inline-end:var(--spacing-xs)}.tabSection:where([data-position=right]:not(:only-child)){margin-inline-start:var(--spacing-xs)}.tabLabel{flex:1;text-align:center}.list[data-variant=default]{position:relative}.list[data-variant=default]:before{border:1px solid var(--tab-border-color);bottom:var(--tabs-list-line-bottom);content:"";inset-inline-end:var(--tabs-list-line-end);inset-inline-start:var(--tabs-list-line-start);position:absolute;top:var(--tabs-list-line-top)}.tab[data-variant=default]{background-color:transparent;border-color:transparent;border-radius:var(--tab-radius);border-style:solid;border-width:var(--tab-border-width)}.tab[data-variant=default]:where([data-active]){border-color:var(--tabs-color)}.tab[data-variant=default]{@mixin hover{background-color:var(--tab-hover-color);&:where(:not([data-active])){border-color:var(--tab-border-color)}}}.tab[data-variant=default]:disabled,.tab[data-variant=default][data-disabled]{@mixin hover{background-color:transparent}}.list[data-variant=outline]{position:relative}.list[data-variant=outline]:before{border-color:var(--tab-border-color);border-style:solid;border-width:var(--tabs-list-border-size);bottom:var(--tabs-list-line-bottom);content:"";inset-inline-end:var(--tabs-list-line-end);inset-inline-start:var(--tabs-list-line-start);position:absolute;top:var(--tabs-list-line-top)}.tab[data-variant=outline]{border-bottom:1px solid transparent;border-bottom-color:var(--tab-border-bottom-color);border-left:1px solid transparent;border-radius:var(--tab-radius);border-right:1px solid transparent;border-top:1px solid transparent;border-top-color:var(--tab-border-top-color);position:relative;--tab-border-bottom-color:transparent;--tab-border-top-color:transparent;--tab-border-inline-end-color:transparent;--tab-border-inline-start-color:transparent}.tab[data-variant=outline]:where([data-active]):before{background-color:var(--tab-border-color);bottom:var(--tab-before-bottom,rem(-1px));content:"";height:1px;left:var(--tab-before-left,rem(-1px));position:absolute;right:var(--tab-before-right,auto);top:var(--tab-before-top,auto);width:1px}.tab[data-variant=outline]:where([data-active]):after{background-color:var(--tab-border-color);bottom:var(--tab-after-bottom,rem(-1px));content:"";height:1px;left:var(--tab-after-left,auto);position:absolute;right:var(--tab-after-right,rem(-1px));top:var(--tab-after-top,auto);width:1px}.tab[data-variant=outline]:where([data-active]){border-bottom-color:var(--tab-border-bottom-color);border-inline-end-color:var(--tab-border-inline-end-color);border-inline-start-color:var(--tab-border-inline-start-color);border-top-color:var(--tab-border-top-color);--tab-border-top-color:var(--tab-border-color);--tab-border-inline-start-color:var(--tab-border-color);--tab-border-inline-end-color:var(--tab-border-color);--tab-border-bottom-color:var(--color-body)}.tab[data-variant=outline]:where([data-active])[data-inverted]{--tab-border-bottom-color:var(--tab-border-color);--tab-border-top-color:var(--color-body);--tab-before-bottom:auto;--tab-before-top:-1px;--tab-after-bottom:auto;--tab-after-top:-1px}.tab[data-variant=outline]:where([data-active])[data-orientation=vertical][data-placement=left]{--tab-border-inline-end-color:var(--color-body);--tab-border-inline-start-color:var(--tab-border-color);--tab-border-bottom-color:var(--tab-border-color);--tab-before-right:-1px;--tab-before-left:auto;--tab-before-bottom:auto;--tab-before-top:-1px;--tab-after-left:auto;--tab-after-right:-1px;@mixin rtl{--tab-before-right:auto;--tab-before-left:-1px;--tab-after-left:-1px;--tab-after-right:auto}}.tab[data-variant=outline]:where([data-active])[data-orientation=vertical][data-placement=right]{--tab-border-inline-start-color:var(--color-body);--tab-border-inline-end-color:var(--tab-border-color);--tab-border-bottom-color:var(--tab-border-color);--tab-before-left:-1px;--tab-before-right:auto;--tab-before-bottom:auto;--tab-before-top:-1px;--tab-after-right:auto;--tab-after-left:-1px;@mixin rtl{--tab-before-left:auto;--tab-before-right:-1px;--tab-after-right:-1px;--tab-after-left:auto}}.tab[data-variant=pills]{background-color:var(--tab-bg);border-radius:var(--tabs-radius);color:var(--tab-color);--tab-bg:transparent;--tab-color:inherit}.tab[data-variant=pills]:not([data-disabled]){@mixin hover{--tab-bg:var(--tab-hover-color)}}.tab[data-variant=pills][data-active][data-active]{--tab-bg:var(--tabs-color);--tab-color:var(--tabs-text-color,var(--color-white));@mixin hover{--tab-bg:var(--tabs-color)}}
|
|
@@ -59,5 +59,5 @@ const style = useVarsResolver((theme) => ({
|
|
|
59
59
|
</template>
|
|
60
60
|
|
|
61
61
|
<style module>
|
|
62
|
-
.root{--text-fz:var(--font-size-
|
|
62
|
+
.root{--text-fz:var(--font-size-md);--text-lh:var(--line-height-md);--text-color:inherit;--text-fw:normal;--text-gradient:none;--text-line-clamp:none;color:var(--text-color);font-size:var(--text-fz);font-weight:var(--text-fw);line-height:var(--text-lh);margin:0;padding:0;text-decoration:none;-webkit-tap-highlight-color:transparent}.root:where([data-truncate]){overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.root:where([data-truncate=start]){direction:rtl;text-align:right;@mixin where-rtl{direction:ltr;text-align:left}}.root:where([data-variant=gradient]){-webkit-background-clip:text;background-clip:text;background-image:var(--text-gradient);-webkit-text-fill-color:transparent}.root:where([data-line-clamp]){display:-webkit-box;overflow:hidden;-webkit-box-orient:vertical;-webkit-line-clamp:var(--text-line-clamp);text-overflow:ellipsis}.root:where([data-inherit]){color:inherit;font-size:inherit;font-weight:inherit;line-height:inherit}.root:where([data-inline]){line-height:1}
|
|
63
63
|
</style>
|
|
@@ -189,5 +189,5 @@ const isClearable = computed(() => clearable && !readonly && !disabled && (hours
|
|
|
189
189
|
</template>
|
|
190
190
|
|
|
191
191
|
<style module>
|
|
192
|
-
.root{align-items:center;display:flex;height:100%;overflow:hidden;@mixin where-rtl{flex-direction:row-reverse}}.group{align-items:center;display:flex;height:calc(var(--input-height) - rem(15px))}.controls{display:flex;flex-direction:column}.controlsGroup{display:flex;gap:.25rem}.dropdown{padding:.25rem}.control{border-radius:var(--radius-default);font-size:var(--control-font-size,var(--font-size-
|
|
192
|
+
.root{align-items:center;display:flex;height:100%;overflow:hidden;@mixin where-rtl{flex-direction:row-reverse}}.group{align-items:center;display:flex;height:calc(var(--input-height) - rem(15px))}.controls{display:flex;flex-direction:column}.controlsGroup{display:flex;gap:.25rem}.dropdown{padding:.25rem}.control{border-radius:var(--radius-default);font-size:var(--control-font-size,var(--font-size-md));height:2em;min-width:2.5em;text-align:center;width:-moz-max-content;width:max-content}.control:where([data-active]){background-color:var(--color-primary-filled);color:var(--color-white)}.control{@mixin hover{&:where(:not([data-active])){color:var(--color-bright);@mixin where-dark{background-color:var(--color-dark-5)}@mixin where-light{background-color:var(--color-gray-1)}}}}.presetControl{border-radius:var(--radius-default);font-size:var(--control-font-size,var(--font-size-md));height:2em;padding-inline:.5em;text-align:center}.presetControl:where([data-active]){background-color:var(--color-primary-filled);color:var(--color-white)}.presetControl{@mixin hover{&:where(:not([data-active])){color:var(--color-bright);@mixin where-dark{background-color:var(--color-dark-5)}@mixin where-light{background-color:var(--color-gray-1)}}}}.presetsGroup+.presetsGroup{margin-top:var(--spacing-sm)}.presetsGroupLabel{align-items:center;color:var(--color-dimmed);display:flex;font-size:calc(var(--control-font-size, var(--font-size-md)) - 2px);font-weight:500;margin-bottom:.25rem;padding-inline-start:7px}.presetsGroupLabel:after{content:"";flex:1;height:1px;margin-inline-start:var(--spacing-xs);width:100%;@mixin where-light{background-color:var(--color-gray-2)}@mixin where-dark{background-color:var(--color-dark-4)}}
|
|
193
193
|
</style>
|
|
@@ -64,6 +64,7 @@ const { handleClick, handleKeyDown } = useTreeItemHandlers(path, isFolder, expan
|
|
|
64
64
|
:aria-selected='selected'
|
|
65
65
|
:mod='{ active, selected, "tree-item": path }'
|
|
66
66
|
right-section-p-e='all'
|
|
67
|
+
justify='flex-start'
|
|
67
68
|
@click.prevent='handleClick'
|
|
68
69
|
@keydown.prevent='handleKeyDown'
|
|
69
70
|
>
|
|
@@ -2,8 +2,10 @@
|
|
|
2
2
|
import { ref } from "vue";
|
|
3
3
|
import Button from "../../components/button/button.vue";
|
|
4
4
|
import ModalCloseButton from "../../components/modal/modal-close-button.vue";
|
|
5
|
+
import ModalFooter from "../../components/modal/modal-footer.vue";
|
|
5
6
|
import ModalHeader from "../../components/modal/modal-header.vue";
|
|
6
7
|
import ModalRoot from "../../components/modal/modal-root.vue";
|
|
8
|
+
import ModalSection from "../../components/modal/modal-section.vue";
|
|
7
9
|
import Title from "../../components/title.vue";
|
|
8
10
|
import { useModal } from "../use-modal";
|
|
9
11
|
const {
|
|
@@ -53,11 +55,19 @@ async function hanleConfirm() {
|
|
|
53
55
|
<ModalCloseButton />
|
|
54
56
|
</ModalHeader>
|
|
55
57
|
|
|
56
|
-
<
|
|
57
|
-
|
|
58
|
-
|
|
58
|
+
<ModalSection bordered>
|
|
59
|
+
<p v-if='body' :class='$style.body'>
|
|
60
|
+
{{ body }}
|
|
61
|
+
</p>
|
|
62
|
+
</ModalSection>
|
|
59
63
|
|
|
60
|
-
<
|
|
64
|
+
<ModalSection bordered>
|
|
65
|
+
<p v-if='body' :class='$style.body'>
|
|
66
|
+
{{ body }}
|
|
67
|
+
</p>
|
|
68
|
+
</ModalSection>
|
|
69
|
+
|
|
70
|
+
<ModalFooter :class='$style.footer'>
|
|
61
71
|
<Button
|
|
62
72
|
variant='default'
|
|
63
73
|
v-bind='cancelProps'
|
|
@@ -74,10 +84,10 @@ async function hanleConfirm() {
|
|
|
74
84
|
>
|
|
75
85
|
{{ labels?.confirm ?? "Confirm" }}
|
|
76
86
|
</Button>
|
|
77
|
-
</
|
|
87
|
+
</ModalFooter>
|
|
78
88
|
</ModalRoot>
|
|
79
89
|
</template>
|
|
80
90
|
|
|
81
91
|
<style module>
|
|
82
|
-
.body{color:var(--color-dimmed);margin:0}.footer{display:flex;gap:var(--spacing-sm);justify-content:flex-end
|
|
92
|
+
.body{color:var(--color-dimmed);margin:0}.footer{display:flex;gap:var(--spacing-sm);justify-content:flex-end}
|
|
83
93
|
</style>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
:root{--mantine-scale:1;--font-family:Inter
|
|
1
|
+
:root{--mantine-scale:1;--font-family:Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji";--font-family-headings:Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif;--font-family-mono:"JetBrains Mono","JetBrainsMono Nerd Font","SF Mono",Menlo,Consolas,monospace;--heading-text-wrap:wrap;--font-size-xs:.5rem;--font-size-sm:.75rem;--font-size-md:.875rem;--font-size-lg:1rem;--font-size-xl:1.125rem;--font-size-h1:2.125rem;--line-height-h1:1.3;--font-weight-h1:700;--font-size-h2:1.625rem;--line-height-h2:1.35;--font-weight-h2:700;--font-size-h3:1.375rem;--line-height-h3:1.4;--font-weight-h3:700;--font-size-h4:1.125rem;--line-height-h4:1.45;--font-weight-h4:700;--font-size-h5:1rem;--line-height-h5:1.5;--font-weight-h5:600;--font-size-h6:0.875rem;--line-height-h6:1.5;--font-weight-h6:600;--spacing-2xs:0.25rem;--spacing-xs:0.5rem;--spacing-sm:0.75rem;--spacing-md:1rem;--spacing-lg:1.25rem;--spacing-xl:2rem;--spacing-2xl:3rem;--radius-xs:0.125rem;--radius-sm:0.25rem;--radius-md:0.5rem;--radius-lg:1rem;--radius-xl:2rem;--radius-default:var(--radius-md);--line-height:1.55;--line-height-xs:1.4;--line-height-sm:1.45;--line-height-md:1.55;--line-height-lg:1.6;--line-height-xl:1.65;--shadow-xs:0 0.0625rem 0.1875rem rgba(0,0,0,.05),0 0.0625rem 0.125rem rgba(0,0,0,.1);--shadow-sm:0 0.0625rem 0.1875rem rgba(0,0,0,.05),rgba(0,0,0,.05) 0 0.625rem 0.9375rem -0.3125rem,rgba(0,0,0,.04) 0 0.4375rem 0.4375rem -0.3125rem;--shadow-md:0 0.0625rem 0.1875rem rgba(0,0,0,.05),rgba(0,0,0,.05) 0 1.25rem 1.5625rem -0.3125rem,rgba(0,0,0,.04) 0 0.625rem 0.625rem -0.3125rem;--shadow-lg:0 0.0625rem 0.1875rem rgba(0,0,0,.05),rgba(0,0,0,.05) 0 1.75rem 1.4375rem -0.4375rem,rgba(0,0,0,.04) 0 0.75rem 0.75rem -0.4375rem;--shadow-xl:0 0.0625rem 0.1875rem rgba(0,0,0,.05),rgba(0,0,0,.05) 0 2.25rem 1.75rem -0.4375rem,rgba(0,0,0,.04) 0 1.0625rem 1.0625rem -0.4375rem;--breakpoint-xs:36em;--breakpoint-sm:48em;--breakpoint-md:62em;--breakpoint-lg:75em;--breakpoint-xl:88em}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
+
import type { HTMLAttributes } from 'vue';
|
|
1
2
|
export type CssVariable = `--${string}`;
|
|
2
3
|
export type TransformVars<V> = {
|
|
3
4
|
[Key in keyof V]: V[Key] extends CssVariable ? Record<V[Key], string | number | undefined> : never;
|
|
4
5
|
};
|
|
5
6
|
/** Map of component part names to user-provided class names. */
|
|
6
|
-
export type Classes<Key extends string
|
|
7
|
+
export type Classes<Key extends string> = Partial<Record<Key, HTMLAttributes['class']>>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "nuance-ui",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.22",
|
|
4
4
|
"description": "A modern Vue UI library inspired by the best of the React ecosystem.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -81,6 +81,7 @@
|
|
|
81
81
|
"@nuxt/devtools": "^3.1.1",
|
|
82
82
|
"@nuxt/eslint": "1.10.0",
|
|
83
83
|
"@nuxt/eslint-config": "^1.13.0",
|
|
84
|
+
"@nuxt/image": "^2.0.0",
|
|
84
85
|
"@nuxt/module-builder": "^1.0.2",
|
|
85
86
|
"@nuxt/schema": "^4.4.2",
|
|
86
87
|
"@nuxt/test-utils": "^4.0.0",
|