@owocow/saber-ui 0.0.7 → 0.0.8

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.
@@ -0,0 +1,108 @@
1
+ import z from "@nuxt/ui/components/DashboardSearch.vue";
2
+ import L from "@nuxt/ui/components/Button.vue";
3
+ import P from "@nuxt/ui/components/Kbd.vue";
4
+ import { defineComponent as V, useModel as y, computed as w, openBlock as s, createElementBlock as S, normalizeClass as u, createVNode as T, withCtx as B, createElementVNode as A, Fragment as D, renderList as F, createBlock as G, renderSlot as O, normalizeProps as R, guardReactiveProps as W, mergeModels as U } from "vue";
5
+ const Q = /* @__PURE__ */ V({
6
+ name: "SaberNavigationSearch",
7
+ __name: "SaberNavigationSearch",
8
+ props: /* @__PURE__ */ U({
9
+ groups: {},
10
+ label: { default: "搜索菜单" },
11
+ placeholder: { default: "搜索菜单" },
12
+ shortcut: { default: "meta_k" },
13
+ kbds: { default: () => ["meta", "k"] },
14
+ ui: {}
15
+ }, {
16
+ open: { type: Boolean, default: !1 },
17
+ openModifiers: {},
18
+ searchTerm: { default: "" },
19
+ searchTermModifiers: {}
20
+ }),
21
+ emits: /* @__PURE__ */ U(["select"], ["update:open", "update:searchTerm"]),
22
+ setup(l, { emit: C }) {
23
+ const e = l, K = C, n = y(l, "open"), r = y(l, "searchTerm");
24
+ function M(a, t) {
25
+ K("select", {
26
+ source: "search",
27
+ item: a,
28
+ sectionKey: t.sectionKey,
29
+ groupKey: t.key
30
+ }), n.value = !1, r.value = "";
31
+ }
32
+ const N = w(
33
+ () => e.groups.map((a) => ({
34
+ id: a.key,
35
+ label: a.label,
36
+ items: a.items.map((t) => ({
37
+ ...t,
38
+ onSelect: () => M(t, a)
39
+ }))
40
+ }))
41
+ ), E = {
42
+ fuseOptions: {
43
+ keys: ["label", "description"],
44
+ useTokenSearch: !0,
45
+ threshold: 0.2
46
+ },
47
+ resultLimit: 12,
48
+ matchAllWhenSearchEmpty: !0
49
+ };
50
+ return (a, t) => {
51
+ var c, i, m, p, d, h, b, f, v, _;
52
+ const I = P, $ = L, x = z;
53
+ return s(), S("div", {
54
+ class: u((c = e.ui) == null ? void 0 : c.root)
55
+ }, [
56
+ T($, {
57
+ "data-testid": "search-button",
58
+ color: "neutral",
59
+ variant: "outline",
60
+ icon: "i-lucide-search",
61
+ label: e.label,
62
+ class: u([(m = (i = e.ui) == null ? void 0 : i.button) == null ? void 0 : m.base, (d = (p = e.ui) == null ? void 0 : p.button) == null ? void 0 : d.hover]),
63
+ ui: {
64
+ leadingIcon: (b = (h = e.ui) == null ? void 0 : h.button) == null ? void 0 : b.leadingIcon,
65
+ label: (v = (f = e.ui) == null ? void 0 : f.button) == null ? void 0 : v.label
66
+ },
67
+ onClick: t[0] || (t[0] = (o) => n.value = !0)
68
+ }, {
69
+ trailing: B(() => {
70
+ var o, g;
71
+ return [
72
+ A("span", {
73
+ class: u((g = (o = e.ui) == null ? void 0 : o.button) == null ? void 0 : g.trailing)
74
+ }, [
75
+ (s(!0), S(D, null, F(e.kbds, (k) => (s(), G(I, {
76
+ key: k,
77
+ value: k,
78
+ variant: "subtle"
79
+ }, null, 8, ["value"]))), 128))
80
+ ], 2)
81
+ ];
82
+ }),
83
+ _: 1
84
+ }, 8, ["label", "class", "ui"]),
85
+ T(x, {
86
+ open: n.value,
87
+ "onUpdate:open": t[1] || (t[1] = (o) => n.value = o),
88
+ "search-term": r.value,
89
+ "onUpdate:searchTerm": t[2] || (t[2] = (o) => r.value = o),
90
+ groups: N.value,
91
+ shortcut: e.shortcut,
92
+ placeholder: e.placeholder,
93
+ fuse: E,
94
+ "color-mode": !1,
95
+ ui: (_ = e.ui) == null ? void 0 : _.panel
96
+ }, {
97
+ empty: B((o) => [
98
+ O(a.$slots, "empty", R(W(o)))
99
+ ]),
100
+ _: 3
101
+ }, 8, ["open", "search-term", "groups", "shortcut", "placeholder", "ui"])
102
+ ], 2);
103
+ };
104
+ }
105
+ });
106
+ export {
107
+ Q as _
108
+ };
@@ -0,0 +1,4 @@
1
+ import { _ as f } from "../SaberAppSidebar.vue_vue_type_script_setup_true_lang-DsdFlpyM.js";
2
+ export {
3
+ f as default
4
+ };
@@ -0,0 +1,4 @@
1
+ import { _ as f } from "../SaberNavigationSearch.vue_vue_type_script_setup_true_lang-BdCVvmQo.js";
2
+ export {
3
+ f as default
4
+ };
@@ -0,0 +1,89 @@
1
+ import { DashboardSearchProps } from '@nuxt/ui/components/DashboardSearch.vue';
2
+ export interface SaberNavigationItem {
3
+ key: string;
4
+ label: string;
5
+ value: string;
6
+ icon?: string;
7
+ description?: string;
8
+ }
9
+ export interface SaberNavigationGroup {
10
+ key: string;
11
+ label?: string;
12
+ items: SaberNavigationItem[];
13
+ }
14
+ export interface SaberNavigationSection {
15
+ key: string;
16
+ label: string;
17
+ icon?: string;
18
+ entryValue?: string;
19
+ groups: SaberNavigationGroup[];
20
+ }
21
+ export interface SaberNavigationSearchGroup {
22
+ key: string;
23
+ label?: string;
24
+ sectionKey?: string;
25
+ items: SaberNavigationItem[];
26
+ }
27
+ export type SaberNavigationSelectSource = 'direct' | 'item' | 'search';
28
+ export interface SaberNavigationSelectPayload {
29
+ source: SaberNavigationSelectSource;
30
+ item: SaberNavigationItem;
31
+ sectionKey?: string;
32
+ groupKey?: string;
33
+ }
34
+ export interface SaberNavigationSearchUI {
35
+ root?: string;
36
+ button?: {
37
+ base?: string;
38
+ hover?: string;
39
+ leadingIcon?: string;
40
+ label?: string;
41
+ trailing?: string;
42
+ };
43
+ panel?: DashboardSearchProps['ui'];
44
+ }
45
+ export interface SaberAppSidebarUI {
46
+ root?: string;
47
+ header?: string;
48
+ logo?: string;
49
+ viewport?: string;
50
+ panel?: string;
51
+ sectionList?: string;
52
+ group?: string;
53
+ groupLabel?: string;
54
+ childList?: string;
55
+ nestedHeader?: string;
56
+ footer?: string;
57
+ transition?: {
58
+ enterActive?: string;
59
+ leaveActive?: string;
60
+ forwardEnterFrom?: string;
61
+ forwardLeaveTo?: string;
62
+ backwardEnterFrom?: string;
63
+ backwardLeaveTo?: string;
64
+ };
65
+ backButton?: {
66
+ base?: string;
67
+ hover?: string;
68
+ icon?: string;
69
+ label?: string;
70
+ };
71
+ sectionItem?: {
72
+ base?: string;
73
+ active?: string;
74
+ inactive?: string;
75
+ hover?: string;
76
+ leadingIcon?: string;
77
+ label?: string;
78
+ trailingIcon?: string;
79
+ };
80
+ childItem?: {
81
+ base?: string;
82
+ active?: string;
83
+ inactive?: string;
84
+ hover?: string;
85
+ leadingIcon?: string;
86
+ label?: string;
87
+ };
88
+ search?: SaberNavigationSearchUI;
89
+ }
@@ -0,0 +1,43 @@
1
+ import { SaberAppSidebarUI, SaberNavigationSearchGroup, SaberNavigationSection, SaberNavigationSelectPayload } from './SaberAppSidebar.types';
2
+ type __VLS_Props = {
3
+ sections: SaberNavigationSection[];
4
+ searchGroups?: SaberNavigationSearchGroup[];
5
+ activeKey?: string;
6
+ shortcut?: string;
7
+ ui?: SaberAppSidebarUI;
8
+ };
9
+ type __VLS_PublicProps = {
10
+ 'activeSection'?: string | undefined;
11
+ } & __VLS_Props;
12
+ declare function __VLS_template(): {
13
+ attrs: Partial<{}>;
14
+ slots: {
15
+ logo?(_: {}): any;
16
+ 'search-empty'?(_: {
17
+ searchTerm: string;
18
+ }): any;
19
+ footer?(_: {}): any;
20
+ };
21
+ refs: {};
22
+ rootEl: HTMLElement;
23
+ };
24
+ type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
25
+ declare const __VLS_component: import('vue').DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
26
+ select: (payload: SaberNavigationSelectPayload) => any;
27
+ "section-select": (section: SaberNavigationSection) => any;
28
+ "update:activeSection": (value: string | undefined) => any;
29
+ }, string, import('vue').PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
30
+ onSelect?: ((payload: SaberNavigationSelectPayload) => any) | undefined;
31
+ "onSection-select"?: ((section: SaberNavigationSection) => any) | undefined;
32
+ "onUpdate:activeSection"?: ((value: string | undefined) => any) | undefined;
33
+ }>, {
34
+ shortcut: string;
35
+ searchGroups: SaberNavigationSearchGroup[];
36
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLElement>;
37
+ declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
38
+ export default _default;
39
+ type __VLS_WithTemplateSlots<T, S> = T & {
40
+ new (): {
41
+ $slots: S;
42
+ };
43
+ };
@@ -0,0 +1,49 @@
1
+ import { SaberNavigationSearchGroup, SaberNavigationSearchUI, SaberNavigationSelectPayload } from './SaberAppSidebar.types';
2
+ type __VLS_Props = {
3
+ groups: SaberNavigationSearchGroup[];
4
+ label?: string;
5
+ placeholder?: string;
6
+ shortcut?: string;
7
+ kbds?: string[];
8
+ ui?: SaberNavigationSearchUI;
9
+ };
10
+ type __VLS_PublicProps = {
11
+ 'open'?: boolean;
12
+ 'searchTerm'?: string;
13
+ } & __VLS_Props;
14
+ declare function __VLS_template(): {
15
+ attrs: Partial<{}>;
16
+ slots: Readonly<{
17
+ empty?: (props: {
18
+ searchTerm: string;
19
+ }) => unknown;
20
+ }> & {
21
+ empty?: (props: {
22
+ searchTerm: string;
23
+ }) => unknown;
24
+ };
25
+ refs: {};
26
+ rootEl: HTMLDivElement;
27
+ };
28
+ type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
29
+ declare const __VLS_component: import('vue').DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
30
+ select: (payload: SaberNavigationSelectPayload) => any;
31
+ "update:open": (value: boolean) => any;
32
+ "update:searchTerm": (value: string) => any;
33
+ }, string, import('vue').PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
34
+ onSelect?: ((payload: SaberNavigationSelectPayload) => any) | undefined;
35
+ "onUpdate:open"?: ((value: boolean) => any) | undefined;
36
+ "onUpdate:searchTerm"?: ((value: string) => any) | undefined;
37
+ }>, {
38
+ label: string;
39
+ placeholder: string;
40
+ shortcut: string;
41
+ kbds: string[];
42
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
43
+ declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
44
+ export default _default;
45
+ type __VLS_WithTemplateSlots<T, S> = T & {
46
+ new (): {
47
+ $slots: S;
48
+ };
49
+ };
@@ -17,9 +17,9 @@ declare const _default: import('vue').DefineComponent<__VLS_PublicProps, {}, {},
17
17
  "onUpdate:modelValue"?: ((value: any) => any) | undefined;
18
18
  }>, {
19
19
  placeholder: string;
20
+ multiple: boolean;
20
21
  disabled: boolean;
21
22
  clearable: boolean;
22
23
  items: PopSelectOption[];
23
- multiple: boolean;
24
24
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
25
25
  export default _default;
@@ -102,10 +102,10 @@ declare const _default: import('vue').DefineComponent<__VLS_PublicProps, {
102
102
  "onUpdate:modelValue"?: ((value: any) => any) | undefined;
103
103
  onRemoveError?: ((error: Error, value: any) => any) | undefined;
104
104
  }>, {
105
+ multiple: boolean;
105
106
  disabled: boolean;
106
107
  size: string;
107
108
  dataSource: UploadImageDataSource<any>;
108
- multiple: boolean;
109
109
  max: number;
110
110
  maxSize: number;
111
111
  accept: string;
package/dist/index.d.ts CHANGED
@@ -8,6 +8,8 @@ import { default as SaberInfoProvider } from './components/SaberInfoProvider.vue
8
8
  import { default as SaberModalWithMobile } from './components/SaberModalWithMobile.vue';
9
9
  import { default as SaberStatus } from './components/SaberStatus.vue';
10
10
  import { default as SaberSwitchBar } from './components/SaberSwitchBar.vue';
11
+ import { default as SaberAppSidebar } from './components/navigation/SaberAppSidebar.vue';
12
+ import { default as SaberNavigationSearch } from './components/navigation/SaberNavigationSearch.vue';
11
13
  import { default as SaberFilterBar } from './forms/components/SaberFilterBar.vue';
12
14
  import { default as SaberFormModal } from './forms/components/SaberFormModal.vue';
13
15
  import { default as SaberModal } from './forms/components/SaberModal.vue';
@@ -31,10 +33,11 @@ export { BadgeStatus as SaberBadgeStatus };
31
33
  export type { BadgeStatusProps } from './BadgeStatus.types';
32
34
  export { SaberNoData };
33
35
  export type { SaberNoDataProps } from './SaberNoData.types';
34
- export { SaberConfirmModal, SaberConfirmProvider, SaberInfo, SaberInfoProvider, SaberModalWithMobile, SaberStatus, SaberSwitchBar, };
36
+ export { SaberConfirmModal, SaberConfirmProvider, SaberInfo, SaberInfoProvider, SaberModalWithMobile, SaberAppSidebar, SaberNavigationSearch, SaberStatus, SaberSwitchBar, };
35
37
  export type { SaberInfoContext, SaberInfoMode, SaberInfoProps, SaberInfoVariant } from './components/SaberInfo.types';
36
38
  export type { SaberStatusType } from './components/SaberStatus.types';
37
39
  export type { SaberSwitchBarItem, SaberSwitchBarUI, SaberSwitchBarValue } from './components/SaberSwitchBar.types';
40
+ export type { SaberAppSidebarUI, SaberNavigationGroup, SaberNavigationItem, SaberNavigationSearchGroup, SaberNavigationSearchUI, SaberNavigationSection, SaberNavigationSelectPayload, SaberNavigationSelectSource, } from './components/navigation/SaberAppSidebar.types';
38
41
  export { SaberFilterBar, SaberFormModal, SaberDictCheckbox, SaberDictRadio, SaberDictSelect, SaberDistrictSelect, SaberInput, SaberInputNumber, SaberModal, SaberPopSelect, SaberRadioGroup, SaberSelect, SaberTextarea, };
39
42
  export { installSaberForms, type SaberFormsOptions } from './forms/plugin';
40
43
  export type { DictDataSource, DictOption, FilterField, FormField, FormSubmitHandler, FormValidator } from './forms/types';
@@ -50,6 +53,8 @@ declare module 'vue' {
50
53
  SaberModalWithMobile: typeof SaberModalWithMobile;
51
54
  SaberStatus: typeof SaberStatus;
52
55
  SaberSwitchBar: typeof SaberSwitchBar;
56
+ SaberAppSidebar: typeof SaberAppSidebar;
57
+ SaberNavigationSearch: typeof SaberNavigationSearch;
53
58
  SaberFilterBar: typeof SaberFilterBar;
54
59
  SaberFormModal: typeof SaberFormModal;
55
60
  SaberModal: typeof SaberModal;
package/dist/index.mjs CHANGED
@@ -1,22 +1,24 @@
1
1
  import h from "@nuxt/ui/vue-plugin";
2
2
  import y from "@nuxt/ui/components/Badge.vue";
3
- import { defineComponent as S, computed as f, openBlock as s, createBlock as $, normalizeStyle as v, withCtx as C, createTextVNode as k, toDisplayString as d, createElementBlock as i, normalizeClass as B, createElementVNode as l, createVNode as I, createCommentVNode as m, renderSlot as u } from "vue";
4
- import D from "@nuxt/ui/runtime/vue/components/Icon.vue";
5
- import { _ as N } from "./SaberConfirmModal.vue_vue_type_script_setup_true_lang-Cqp9krYl.js";
3
+ import { defineComponent as _, computed as f, openBlock as s, createBlock as $, normalizeStyle as v, withCtx as C, createTextVNode as k, toDisplayString as d, createElementBlock as i, normalizeClass as B, createElementVNode as l, createVNode as I, createCommentVNode as m, renderSlot as u } from "vue";
4
+ import N from "@nuxt/ui/runtime/vue/components/Icon.vue";
5
+ import { _ as D } from "./SaberConfirmModal.vue_vue_type_script_setup_true_lang-Cqp9krYl.js";
6
6
  import { _ as M } from "./SaberConfirmProvider.vue_vue_type_script_setup_true_lang-DUJ6ftNJ.js";
7
7
  import { _ as w } from "./SaberInfo.vue_vue_type_script_setup_true_lang-B3W5VsGR.js";
8
8
  import { _ as P } from "./SaberInfoProvider.vue_vue_type_script_setup_true_lang-3rF6bSCn.js";
9
9
  import { _ as z } from "./SaberModalWithMobile.vue_vue_type_script_setup_true_lang-aQlToncY.js";
10
- import { _ as F } from "./SaberStatus.vue_vue_type_script_setup_true_lang-D9aRVCow.js";
11
- import { _ as U } from "./SaberSwitchBar.vue_vue_type_script_setup_true_lang-CDx3Dcas.js";
12
- import { k as V } from "./plugin-Dr3z0YFg.js";
13
- import { _ as ie, a as le, b as me, c as de, d as be, e as fe } from "./plugin-Dr3z0YFg.js";
14
- import { _ as _e } from "./SaberModal.vue_vue_type_script_setup_true_lang-DJno3jA3.js";
15
- import { _ as pe } from "./SaberDictCheckbox.vue_vue_type_script_setup_true_lang-DUbzy_C6.js";
16
- import { _ as xe, a as he } from "./SaberDictRadio.vue_vue_type_script_setup_true_lang-DR6-jSID.js";
17
- import { _ as $e } from "./SaberDictSelect.vue_vue_type_script_setup_true_lang-B8PTKNKX.js";
18
- import { _ as Ce } from "./SaberDistrictSelect.vue_vue_type_script_setup_true_lang-BX8nLC35.js";
19
- import { _ as Be } from "./SaberPopSelect.vue_vue_type_script_setup_true_lang-BcS27NXI.js";
10
+ import { _ as A } from "./SaberStatus.vue_vue_type_script_setup_true_lang-D9aRVCow.js";
11
+ import { _ as F } from "./SaberSwitchBar.vue_vue_type_script_setup_true_lang-CDx3Dcas.js";
12
+ import { _ as U } from "./SaberAppSidebar.vue_vue_type_script_setup_true_lang-DsdFlpyM.js";
13
+ import { _ as V } from "./SaberNavigationSearch.vue_vue_type_script_setup_true_lang-BdCVvmQo.js";
14
+ import { k as W } from "./plugin-Dr3z0YFg.js";
15
+ import { _ as be, a as fe, b as ue, c as Se, d as _e, e as pe } from "./plugin-Dr3z0YFg.js";
16
+ import { _ as xe } from "./SaberModal.vue_vue_type_script_setup_true_lang-DJno3jA3.js";
17
+ import { _ as ye } from "./SaberDictCheckbox.vue_vue_type_script_setup_true_lang-DUbzy_C6.js";
18
+ import { _ as ve, a as Ce } from "./SaberDictRadio.vue_vue_type_script_setup_true_lang-DR6-jSID.js";
19
+ import { _ as Be } from "./SaberDictSelect.vue_vue_type_script_setup_true_lang-B8PTKNKX.js";
20
+ import { _ as Ne } from "./SaberDistrictSelect.vue_vue_type_script_setup_true_lang-BX8nLC35.js";
21
+ import { _ as Me } from "./SaberPopSelect.vue_vue_type_script_setup_true_lang-BcS27NXI.js";
20
22
  const b = {
21
23
  red: { 500: "#ef4444", 600: "#dc2626" },
22
24
  orange: { 500: "#f97316", 600: "#ea580c" },
@@ -40,16 +42,16 @@ const b = {
40
42
  zinc: { 500: "#71717a", 600: "#52525b" },
41
43
  neutral: { 500: "#737373", 600: "#525252" },
42
44
  stone: { 500: "#78716c", 600: "#57534e" }
43
- }, W = b.gray;
44
- function _(e, t) {
45
+ }, H = b.gray;
46
+ function S(e, t) {
45
47
  var o, a;
46
- return ((o = b[e]) == null ? void 0 : o[t]) ?? ((a = b[e]) == null ? void 0 : a[500]) ?? W[500];
48
+ return ((o = b[e]) == null ? void 0 : o[t]) ?? ((a = b[e]) == null ? void 0 : a[500]) ?? H[500];
47
49
  }
48
- function H(e, t) {
50
+ function R(e, t) {
49
51
  const o = parseInt(e.slice(1, 3), 16), a = parseInt(e.slice(3, 5), 16), r = parseInt(e.slice(5, 7), 16);
50
52
  return `rgba(${o}, ${a}, ${r}, ${t / 100})`;
51
53
  }
52
- const R = /* @__PURE__ */ S({
54
+ const T = /* @__PURE__ */ _({
53
55
  __name: "BadgeStatus",
54
56
  props: {
55
57
  value: {},
@@ -69,9 +71,9 @@ const R = /* @__PURE__ */ S({
69
71
  }
70
72
  return { label: r, color: "gray" };
71
73
  }), a = f(() => {
72
- const { color: r } = o.value, c = _(r, 500), n = _(r, t.textColorWeight);
74
+ const { color: r } = o.value, c = S(r, 500), n = S(r, t.textColorWeight);
73
75
  return {
74
- backgroundColor: H(c, t.bgOpacity),
76
+ backgroundColor: R(c, t.bgOpacity),
75
77
  color: n
76
78
  };
77
79
  });
@@ -88,10 +90,10 @@ const R = /* @__PURE__ */ S({
88
90
  }, 8, ["style"]);
89
91
  };
90
92
  }
91
- }), T = { class: "rounded-md border border-accented p-3" }, A = { class: "flex flex-col gap-1" }, E = { class: "text-base font-semibold mb-2 text-highlighted w-60" }, L = {
93
+ }), E = { class: "rounded-md border border-accented p-3" }, L = { class: "flex flex-col gap-1" }, O = { class: "text-base font-semibold mb-2 text-highlighted w-60" }, j = {
92
94
  key: 0,
93
95
  class: "text-sm text-muted w-60"
94
- }, O = { key: 0 }, j = { key: 1 }, G = /* @__PURE__ */ S({
96
+ }, G = { key: 0 }, K = { key: 1 }, q = /* @__PURE__ */ _({
95
97
  name: "SaberNoData",
96
98
  __name: "SaberNoData",
97
99
  props: {
@@ -103,7 +105,7 @@ const R = /* @__PURE__ */ S({
103
105
  },
104
106
  setup(e) {
105
107
  return (t, o) => {
106
- const a = D;
108
+ const a = N;
107
109
  return s(), i("div", {
108
110
  class: B([
109
111
  "flex flex-col items-center justify-center gap-6 rounded-md p-10 text-center bg-default",
@@ -111,53 +113,55 @@ const R = /* @__PURE__ */ S({
111
113
  t.$props.class
112
114
  ])
113
115
  }, [
114
- l("div", T, [
116
+ l("div", E, [
115
117
  I(a, {
116
118
  name: e.icon,
117
119
  class: "size-5"
118
120
  }, null, 8, ["name"])
119
121
  ]),
120
- l("div", A, [
121
- l("h4", E, d(e.title), 1),
122
- e.description ? (s(), i("p", L, d(e.description), 1)) : m("", !0)
122
+ l("div", L, [
123
+ l("h4", O, d(e.title), 1),
124
+ e.description ? (s(), i("p", j, d(e.description), 1)) : m("", !0)
123
125
  ]),
124
- t.$slots.default ? (s(), i("div", O, [
126
+ t.$slots.default ? (s(), i("div", G, [
125
127
  u(t.$slots, "default")
126
128
  ])) : m("", !0),
127
- t.$slots.extra ? (s(), i("p", j, [
129
+ t.$slots.extra ? (s(), i("p", K, [
128
130
  u(t.$slots, "extra")
129
131
  ])) : m("", !0)
130
132
  ], 2);
131
133
  };
132
134
  }
133
- }), ne = {
135
+ }), le = {
134
136
  install(e, t = {}) {
135
- e.use(h), e.component("SaberBadgeStatus", R), e.component("SaberNoData", G), e.component("SaberConfirmModal", N), e.component("SaberConfirmProvider", M), e.component("SaberInfo", w), e.component("SaberInfoProvider", P), e.component("SaberModalWithMobile", z), e.component("SaberStatus", F), e.component("SaberSwitchBar", U), V(e, t.forms);
137
+ e.use(h), e.component("SaberBadgeStatus", T), e.component("SaberNoData", q), e.component("SaberConfirmModal", D), e.component("SaberConfirmProvider", M), e.component("SaberInfo", w), e.component("SaberInfoProvider", P), e.component("SaberModalWithMobile", z), e.component("SaberStatus", A), e.component("SaberSwitchBar", F), e.component("SaberAppSidebar", U), e.component("SaberNavigationSearch", V), W(e, t.forms);
136
138
  }
137
139
  };
138
140
  export {
139
- R as SaberBadgeStatus,
140
- N as SaberConfirmModal,
141
+ U as SaberAppSidebar,
142
+ T as SaberBadgeStatus,
143
+ D as SaberConfirmModal,
141
144
  M as SaberConfirmProvider,
142
- pe as SaberDictCheckbox,
143
- xe as SaberDictRadio,
144
- $e as SaberDictSelect,
145
- Ce as SaberDistrictSelect,
146
- ie as SaberFilterBar,
147
- le as SaberFormModal,
145
+ ye as SaberDictCheckbox,
146
+ ve as SaberDictRadio,
147
+ Be as SaberDictSelect,
148
+ Ne as SaberDistrictSelect,
149
+ be as SaberFilterBar,
150
+ fe as SaberFormModal,
148
151
  w as SaberInfo,
149
152
  P as SaberInfoProvider,
150
- me as SaberInput,
151
- de as SaberInputNumber,
152
- _e as SaberModal,
153
+ ue as SaberInput,
154
+ Se as SaberInputNumber,
155
+ xe as SaberModal,
153
156
  z as SaberModalWithMobile,
154
- G as SaberNoData,
155
- Be as SaberPopSelect,
156
- he as SaberRadioGroup,
157
- be as SaberSelect,
158
- F as SaberStatus,
159
- U as SaberSwitchBar,
160
- fe as SaberTextarea,
161
- ne as default,
162
- V as installSaberForms
157
+ V as SaberNavigationSearch,
158
+ q as SaberNoData,
159
+ Me as SaberPopSelect,
160
+ Ce as SaberRadioGroup,
161
+ _e as SaberSelect,
162
+ A as SaberStatus,
163
+ F as SaberSwitchBar,
164
+ pe as SaberTextarea,
165
+ le as default,
166
+ W as installSaberForms
163
167
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@owocow/saber-ui",
3
- "version": "0.0.7",
3
+ "version": "0.0.8",
4
4
  "description": "Saber application foundation for Vue 3 projects built on Nuxt UI",
5
5
  "type": "module",
6
6
  "sideEffects": false,
@@ -100,6 +100,14 @@
100
100
  "types": "./dist/components/SaberSwitchBar.vue.d.ts",
101
101
  "import": "./dist/components/SaberSwitchBar.mjs"
102
102
  },
103
+ "./components/SaberAppSidebar": {
104
+ "types": "./dist/components/navigation/SaberAppSidebar.vue.d.ts",
105
+ "import": "./dist/components/SaberAppSidebar.mjs"
106
+ },
107
+ "./components/SaberNavigationSearch": {
108
+ "types": "./dist/components/navigation/SaberNavigationSearch.vue.d.ts",
109
+ "import": "./dist/components/SaberNavigationSearch.mjs"
110
+ },
103
111
  "./components/SaberStatus": {
104
112
  "types": "./dist/components/SaberStatus.vue.d.ts",
105
113
  "import": "./dist/components/SaberStatus.mjs"
@@ -177,7 +185,7 @@
177
185
  "dist"
178
186
  ],
179
187
  "scripts": {
180
- "test": "node --test",
188
+ "test": "node --test && vitest run",
181
189
  "build": "vite build",
182
190
  "docs:dev": "vitepress dev docs",
183
191
  "docs:typecheck": "tsc -p docs/tsconfig.json --noEmit",
@@ -191,7 +199,8 @@
191
199
  "jsencrypt": "^3.5.4",
192
200
  "klona": "^2.0.6",
193
201
  "nanoid": "^5.1.9",
194
- "ofetch": "^1.5.1"
202
+ "ofetch": "^1.5.1",
203
+ "tailwind-variants": "^3.3.0"
195
204
  },
196
205
  "peerDependencies": {
197
206
  "@nuxt/ui": "^4",
@@ -203,12 +212,15 @@
203
212
  "@types/crypto-js": "^4.2.2",
204
213
  "@types/node": "^26.1.2",
205
214
  "@vitejs/plugin-vue": "^5",
215
+ "@vue/test-utils": "^2.5.0",
216
+ "jsdom": "27.4.0",
206
217
  "tailwindcss": "^4.3.3",
207
218
  "typescript": "^5",
208
219
  "unplugin-vue-components": "^32",
209
220
  "vite": "^6",
210
221
  "vite-plugin-dts": "^4",
211
222
  "vitepress": "2.0.0-alpha.19",
223
+ "vitest": "^4.1.11",
212
224
  "vue": "^3.5.31",
213
225
  "vue-router": "^4.6.4"
214
226
  },