@webx-ui/core 0.3.0 → 0.4.0

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.
Files changed (52) hide show
  1. package/dist/components/Accordion/Accordion.d.ts +40 -0
  2. package/dist/components/Accordion/index.d.ts +2 -0
  3. package/dist/components/Accordion/types.d.ts +25 -0
  4. package/dist/components/AccordionItem/AccordionItem.d.ts +41 -0
  5. package/dist/components/AccordionItem/index.d.ts +2 -0
  6. package/dist/components/AccordionItem/types.d.ts +12 -0
  7. package/dist/components/Action/Action.d.ts +4 -4
  8. package/dist/components/Autocomplete/Autocomplete.d.ts +9 -9
  9. package/dist/components/Badge/Badge.d.ts +1 -1
  10. package/dist/components/Button/Button.d.ts +3 -3
  11. package/dist/components/ButtonGroup/ButtonGroup.d.ts +3 -3
  12. package/dist/components/Card/Card.d.ts +1 -1
  13. package/dist/components/Cascader/Cascader.d.ts +7 -7
  14. package/dist/components/Checkbox/Checkbox.d.ts +2 -2
  15. package/dist/components/ColorPicker/ColorPicker.d.ts +1 -1
  16. package/dist/components/DatePicker/DatePicker.d.ts +9 -9
  17. package/dist/components/DateRangePicker/DateRangePicker.d.ts +8 -8
  18. package/dist/components/DateTimePicker/DateTimePicker.d.ts +2 -2
  19. package/dist/components/DropdownItem/DropdownItem.d.ts +3 -3
  20. package/dist/components/EntityCard/EntityCard.d.ts +4 -4
  21. package/dist/components/FormItem/FormItem.d.ts +2 -2
  22. package/dist/components/Icon/Icon.d.ts +1 -1
  23. package/dist/components/Indicator/Indicator.d.ts +2 -2
  24. package/dist/components/Input/Input.d.ts +5 -5
  25. package/dist/components/Link/Link.d.ts +3 -3
  26. package/dist/components/Popover/Popover.d.ts +75 -0
  27. package/dist/components/Popover/index.d.ts +2 -0
  28. package/dist/components/Popover/types.d.ts +34 -0
  29. package/dist/components/Prose/Prose.d.ts +1 -1
  30. package/dist/components/Radio/Radio.d.ts +1 -1
  31. package/dist/components/RichText/RichText.d.ts +1 -1
  32. package/dist/components/RichText/ToolbarButton.d.ts +1 -1
  33. package/dist/components/Select/Select.d.ts +10 -10
  34. package/dist/components/Statistic/Statistic.d.ts +1 -1
  35. package/dist/components/Switch/Switch.d.ts +1 -1
  36. package/dist/components/Tab/Tab.d.ts +32 -0
  37. package/dist/components/Tab/index.d.ts +2 -0
  38. package/dist/components/Tab/types.d.ts +15 -0
  39. package/dist/components/Table/Table.d.ts +49 -3
  40. package/dist/components/Tabs/Tabs.d.ts +58 -0
  41. package/dist/components/Tabs/index.d.ts +2 -0
  42. package/dist/components/Tabs/types.d.ts +37 -0
  43. package/dist/components/TagsInput/TagsInput.d.ts +2 -2
  44. package/dist/components/Text/Text.d.ts +1 -1
  45. package/dist/components/Textarea/Textarea.d.ts +2 -2
  46. package/dist/components/TimePicker/TimePicker.d.ts +2 -2
  47. package/dist/components/index.d.ts +5 -0
  48. package/dist/composables/useAccordion.d.ts +16 -0
  49. package/dist/index.js +2327 -1874
  50. package/dist/index.js.map +1 -1
  51. package/dist/style.css +1 -1
  52. package/package.json +1 -1
@@ -10,8 +10,8 @@ declare function __VLS_template(): {
10
10
  type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
11
11
  declare const __VLS_component: import('vue').DefineComponent<ProseProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<ProseProps> & Readonly<{}>, {
12
12
  size: import('./types').ProseSize;
13
- html: string;
14
13
  as: string;
14
+ html: string;
15
15
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
16
16
  declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
17
17
  export default _default;
@@ -22,8 +22,8 @@ declare const __VLS_component: import('vue').DefineComponent<__VLS_PublicProps,
22
22
  }>, {
23
23
  name: string;
24
24
  size: import('../..').ControlSize;
25
- label: string;
26
25
  disabled: boolean;
26
+ label: string;
27
27
  ariaLabel: string;
28
28
  id: string;
29
29
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
@@ -20,10 +20,10 @@ declare const _default: import('vue').DefineComponent<__VLS_PublicProps, {
20
20
  onFocus?: (() => any) | undefined;
21
21
  onUploadError?: ((error: unknown, file: File) => any) | undefined;
22
22
  }>, {
23
- upload: import('./types').RichTextUpload;
24
23
  size: import('../..').ControlSize;
25
24
  disabled: boolean;
26
25
  placeholder: string;
26
+ upload: import('./types').RichTextUpload;
27
27
  ariaLabel: string;
28
28
  status: import('../..').ControlStatus;
29
29
  id: string;
@@ -12,9 +12,9 @@ declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {
12
12
  }, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
13
13
  onClick?: (() => any) | undefined;
14
14
  }>, {
15
+ disabled: boolean;
15
16
  text: string;
16
17
  icon: string;
17
- disabled: boolean;
18
18
  active: boolean;
19
19
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLButtonElement>;
20
20
  export default _default;
@@ -13,32 +13,32 @@ declare function __VLS_template(): {
13
13
  };
14
14
  type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
15
15
  declare const __VLS_component: import('vue').DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
16
- close: () => any;
17
- search: (term: string) => any;
18
- clear: () => any;
19
- open: () => any;
20
16
  change: (value: SelectModelValue) => any;
17
+ search: (term: string) => any;
21
18
  "update:modelValue": (value: SelectModelValue) => any;
19
+ close: () => any;
20
+ open: () => any;
21
+ clear: () => any;
22
22
  }, string, import('vue').PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
23
- onClose?: (() => any) | undefined;
24
- onSearch?: ((term: string) => any) | undefined;
25
- onClear?: (() => any) | undefined;
26
- onOpen?: (() => any) | undefined;
27
23
  onChange?: ((value: SelectModelValue) => any) | undefined;
24
+ onSearch?: ((term: string) => any) | undefined;
28
25
  "onUpdate:modelValue"?: ((value: SelectModelValue) => any) | undefined;
26
+ onClose?: (() => any) | undefined;
27
+ onOpen?: (() => any) | undefined;
28
+ onClear?: (() => any) | undefined;
29
29
  }>, {
30
30
  name: string;
31
+ multiple: boolean;
31
32
  size: import('../..').ControlSize;
32
33
  disabled: boolean;
33
- teleport: boolean;
34
34
  placeholder: string;
35
+ teleport: boolean;
35
36
  ariaLabel: string;
36
37
  options: import('./types').SelectOption[];
37
38
  emptyText: string;
38
39
  clearable: boolean;
39
40
  status: import('../..').ControlStatus;
40
41
  id: string;
41
- multiple: boolean;
42
42
  filterable: boolean;
43
43
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
44
44
  declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
@@ -15,9 +15,9 @@ type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
15
15
  declare const __VLS_component: import('vue').DefineComponent<StatisticProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<StatisticProps> & Readonly<{}>, {
16
16
  size: import('./types').StatisticSize;
17
17
  title: string;
18
+ value: number | string;
18
19
  tone: import('..').TextTone;
19
20
  align: import('..').TextAlign;
20
- value: number | string;
21
21
  precision: number;
22
22
  locale: string;
23
23
  grouping: boolean;
@@ -22,8 +22,8 @@ declare const __VLS_component: import('vue').DefineComponent<__VLS_PublicProps,
22
22
  }>, {
23
23
  name: string;
24
24
  size: import('../..').ControlSize;
25
- label: string;
26
25
  disabled: boolean;
26
+ label: string;
27
27
  ariaLabel: string;
28
28
  id: string;
29
29
  activeValue: ChoiceValue;
@@ -0,0 +1,32 @@
1
+ import { TabProps } from './types';
2
+ declare function __VLS_template(): {
3
+ attrs: Partial<{}>;
4
+ slots: Readonly<{
5
+ /** The panel. */
6
+ default?: () => unknown;
7
+ /** Replaces `label` in the strip — an avatar, a coloured dot, anything. */
8
+ label?: () => unknown;
9
+ }> & {
10
+ /** The panel. */
11
+ default?: () => unknown;
12
+ /** Replaces `label` in the strip — an avatar, a coloured dot, anything. */
13
+ label?: () => unknown;
14
+ };
15
+ refs: {};
16
+ rootEl: any;
17
+ };
18
+ type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
19
+ declare const __VLS_component: import('vue').DefineComponent<TabProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<TabProps> & Readonly<{}>, {
20
+ disabled: boolean;
21
+ label: string;
22
+ icon: import('..').IconName;
23
+ badge: string | number;
24
+ keepAlive: boolean;
25
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
26
+ declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
27
+ export default _default;
28
+ type __VLS_WithTemplateSlots<T, S> = T & {
29
+ new (): {
30
+ $slots: S;
31
+ };
32
+ };
@@ -0,0 +1,2 @@
1
+ export { default as WxTab } from './Tab';
2
+ export type * from './types';
@@ -0,0 +1,15 @@
1
+ import { IconName } from '../Icon/types';
2
+ import { TabValue } from '../Tabs/types';
3
+ export interface TabProps {
4
+ /** Unique within the tabs; this is what `v-model` holds. */
5
+ value: TabValue;
6
+ /** Text of the tab itself. The `label` slot replaces it. */
7
+ label?: string;
8
+ /** Icon before the label. */
9
+ icon?: IconName;
10
+ /** A count or a short marker after the label. */
11
+ badge?: string | number;
12
+ disabled?: boolean;
13
+ /** Keep this one panel mounted while it is hidden, whatever the tabs say. */
14
+ keepAlive?: boolean;
15
+ }
@@ -1,4 +1,4 @@
1
- import { RowKey, TableProps, TableRow, TableSort, TableState } from './types';
1
+ import { RowKey, TableColumn, TableProps, TableRow, TableSort, TableState, TableSummaryRow } from './types';
2
2
  declare const _default: <T extends TableRow = TableRow>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
3
3
  props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
4
4
  readonly onSearch?: ((term: string) => any) | undefined;
@@ -20,10 +20,56 @@ declare const _default: <T extends TableRow = TableRow>(__VLS_props: NonNullable
20
20
  search?: string;
21
21
  page?: number;
22
22
  perPage?: number;
23
- } & TableProps<T>) & any> & import('vue').PublicProps;
23
+ } & TableProps<T>) & Partial<{}>> & import('vue').PublicProps;
24
24
  expose(exposed: import('vue').ShallowUnwrapRef<{}>): void;
25
25
  attrs: any;
26
- slots: any;
26
+ slots: Readonly<{
27
+ [key: `header-${string}`]: ((props: {
28
+ column: TableColumn<T>;
29
+ }) => unknown) | undefined;
30
+ [key: `cell-${string}`]: ((props: {
31
+ row: T;
32
+ value: unknown;
33
+ index: number;
34
+ column: TableColumn<T>;
35
+ }) => unknown) | undefined;
36
+ [key: `summary-${string}`]: ((props: {
37
+ row: TableSummaryRow;
38
+ value: unknown;
39
+ }) => unknown) | undefined;
40
+ title?: () => unknown;
41
+ actions?: () => unknown;
42
+ empty?: () => unknown;
43
+ footer?: () => unknown;
44
+ loading?: () => unknown;
45
+ expanded?: (props: {
46
+ row: T;
47
+ index: number;
48
+ }) => unknown;
49
+ }> & {
50
+ [key: `header-${string}`]: ((props: {
51
+ column: TableColumn<T>;
52
+ }) => unknown) | undefined;
53
+ [key: `cell-${string}`]: ((props: {
54
+ row: T;
55
+ value: unknown;
56
+ index: number;
57
+ column: TableColumn<T>;
58
+ }) => unknown) | undefined;
59
+ [key: `summary-${string}`]: ((props: {
60
+ row: TableSummaryRow;
61
+ value: unknown;
62
+ }) => unknown) | undefined;
63
+ title?: () => unknown;
64
+ actions?: () => unknown;
65
+ empty?: () => unknown;
66
+ footer?: () => unknown;
67
+ loading?: () => unknown;
68
+ expanded?: (props: {
69
+ row: T;
70
+ index: number;
71
+ }) => unknown;
72
+ };
27
73
  emit: (((evt: "search", term: string) => void) & ((evt: "row-click", row: T, index: number, event: MouseEvent) => void) & ((evt: "sort-change", sort: TableSort | null) => void) & ((evt: "selection-change", keys: RowKey[], rows: T[]) => void) & ((evt: "expand-change", keys: RowKey[], rows: T[]) => void) & ((evt: "state-change", state: TableState) => void)) & (((evt: "update:page", value: number) => void) & ((evt: "update:perPage", value: number) => void) & ((evt: "update:selected", value: RowKey[]) => void) & ((evt: "update:expanded", value: RowKey[]) => void) & ((evt: "update:sort", value: TableSort | null) => void) & ((evt: "update:search", value: string) => void));
28
74
  }>) => import('vue').VNode & {
29
75
  __ctx?: Awaited<typeof __VLS_setup>;
@@ -0,0 +1,58 @@
1
+ import { TabsProps, TabValue } from './types';
2
+ type __VLS_Props = TabsProps;
3
+ declare function measure(): void;
4
+ /**
5
+ * `instant` is for the first placement: a strip that opens on its eighth tab should
6
+ * already be there, not slide there while the page is still settling.
7
+ */
8
+ declare function revealActive(instant?: boolean): void;
9
+ type __VLS_PublicProps = {
10
+ modelValue?: TabValue | undefined;
11
+ } & __VLS_Props;
12
+ declare function __VLS_template(): {
13
+ attrs: Partial<{}>;
14
+ slots: Readonly<{
15
+ /** The `WxTab`s. */
16
+ default?: () => unknown;
17
+ /** Sits at the end of the strip — a button, a filter, a count. */
18
+ extra?: () => unknown;
19
+ }> & {
20
+ /** The `WxTab`s. */
21
+ default?: () => unknown;
22
+ /** Sits at the end of the strip — a button, a filter, a count. */
23
+ extra?: () => unknown;
24
+ };
25
+ refs: {
26
+ scroller: HTMLDivElement;
27
+ };
28
+ rootEl: any;
29
+ };
30
+ type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
31
+ declare const __VLS_component: import('vue').DefineComponent<__VLS_PublicProps, {
32
+ measure: typeof measure;
33
+ revealActive: typeof revealActive;
34
+ }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
35
+ change: (value: TabValue) => any;
36
+ "update:modelValue": (value: TabValue | undefined) => any;
37
+ }, string, import('vue').PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
38
+ onChange?: ((value: TabValue) => any) | undefined;
39
+ "onUpdate:modelValue"?: ((value: TabValue | undefined) => any) | undefined;
40
+ }>, {
41
+ variant: import('./types').TabsVariant;
42
+ size: import('./types').TabsSize;
43
+ orientation: import('./types').TabsOrientation;
44
+ align: import('./types').TabsAlign;
45
+ ariaLabel: string;
46
+ loop: boolean;
47
+ keepAlive: boolean;
48
+ activationMode: import('./types').TabsActivationMode;
49
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
50
+ scroller: HTMLDivElement;
51
+ }, any>;
52
+ declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
53
+ export default _default;
54
+ type __VLS_WithTemplateSlots<T, S> = T & {
55
+ new (): {
56
+ $slots: S;
57
+ };
58
+ };
@@ -0,0 +1,2 @@
1
+ export { default as WxTabs } from './Tabs';
2
+ export type * from './types';
@@ -0,0 +1,37 @@
1
+ import { IconName } from '../Icon/types';
2
+ /** Reka's tabs key their panels by string or number; ours do the same. */
3
+ export type TabValue = string | number;
4
+ export type TabsVariant = 'line' | 'pill' | 'card';
5
+ export type TabsSize = 'sm' | 'md';
6
+ export type TabsOrientation = 'horizontal' | 'vertical';
7
+ export type TabsAlign = 'start' | 'center' | 'end' | 'stretch';
8
+ export type TabsActivationMode = 'automatic' | 'manual';
9
+ export interface TabsProps {
10
+ /** Underlined strip, a segmented control, or folder tabs. */
11
+ variant?: TabsVariant;
12
+ size?: TabsSize;
13
+ /** A column of tabs beside the panel. It falls back to a strip in a narrow container. */
14
+ orientation?: TabsOrientation;
15
+ /** Where the tabs sit in the strip; `stretch` splits the width between them. */
16
+ align?: TabsAlign;
17
+ /** Whether arrow keys switch the panel as they move, or only move focus. */
18
+ activationMode?: TabsActivationMode;
19
+ /** Keep hidden panels in the DOM, so form state and scroll position survive a switch. */
20
+ keepAlive?: boolean;
21
+ /** Arrow keys wrap around from the last tab to the first. */
22
+ loop?: boolean;
23
+ /** Accessible name for the tab strip. */
24
+ ariaLabel?: string;
25
+ }
26
+ export interface TabsEmits {
27
+ change: [value: TabValue];
28
+ }
29
+ /** What `WxTabs` reads off each `WxTab` in its slot to build the strip. */
30
+ export interface TabDescriptor {
31
+ value: TabValue;
32
+ label?: string;
33
+ icon?: IconName;
34
+ badge?: string | number;
35
+ disabled: boolean;
36
+ labelSlot?: () => unknown;
37
+ }
@@ -6,12 +6,12 @@ type __VLS_PublicProps = {
6
6
  declare const _default: import('vue').DefineComponent<__VLS_PublicProps, {
7
7
  focus: () => void | undefined;
8
8
  }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
9
- search: (term: string) => any;
10
9
  change: (value: string[]) => any;
10
+ search: (term: string) => any;
11
11
  "update:modelValue": (value: string[]) => any;
12
12
  }, string, import('vue').PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
13
- onSearch?: ((term: string) => any) | undefined;
14
13
  onChange?: ((value: string[]) => any) | undefined;
14
+ onSearch?: ((term: string) => any) | undefined;
15
15
  "onUpdate:modelValue"?: ((value: string[]) => any) | undefined;
16
16
  }>, {
17
17
  name: string;
@@ -10,8 +10,8 @@ declare function __VLS_template(): {
10
10
  type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
11
11
  declare const __VLS_component: import('vue').DefineComponent<TextProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<TextProps> & Readonly<{}>, {
12
12
  size: import('./types').TextSize;
13
- tone: import('./types').TextTone;
14
13
  as: string;
14
+ tone: import('./types').TextTone;
15
15
  align: import('./types').TextAlign;
16
16
  truncate: boolean | number;
17
17
  weight: import('./types').TextWeight;
@@ -9,15 +9,15 @@ declare const _default: import('vue').DefineComponent<__VLS_PublicProps, {
9
9
  select: () => void | undefined;
10
10
  textarea: import('vue').Ref<HTMLTextAreaElement | null, HTMLTextAreaElement | null>;
11
11
  }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
12
- input: (value: string) => any;
13
12
  change: (value: string) => any;
14
13
  "update:modelValue": (value: TextareaModelValue) => any;
14
+ input: (value: string) => any;
15
15
  blur: (event: FocusEvent) => any;
16
16
  focus: (event: FocusEvent) => any;
17
17
  }, string, import('vue').PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
18
- onInput?: ((value: string) => any) | undefined;
19
18
  onChange?: ((value: string) => any) | undefined;
20
19
  "onUpdate:modelValue"?: ((value: TextareaModelValue) => any) | undefined;
20
+ onInput?: ((value: string) => any) | undefined;
21
21
  onBlur?: ((event: FocusEvent) => any) | undefined;
22
22
  onFocus?: ((event: FocusEvent) => any) | undefined;
23
23
  }>, {
@@ -12,7 +12,7 @@ type __VLS_PublicProps = {
12
12
  } & __VLS_Props;
13
13
  declare function __VLS_template(): {
14
14
  attrs: Partial<{}>;
15
- slots: any;
15
+ slots: Readonly<Record<string, (props: Record<string, unknown>) => unknown>> & Record<string, (props: Record<string, unknown>) => unknown>;
16
16
  refs: {};
17
17
  rootEl: any;
18
18
  };
@@ -25,8 +25,8 @@ declare const __VLS_component: import('vue').DefineComponent<__VLS_PublicProps,
25
25
  name: string;
26
26
  size: import('../..').ControlSize;
27
27
  disabled: boolean;
28
- teleport: boolean | string;
29
28
  placeholder: string;
29
+ teleport: boolean | string;
30
30
  ariaLabel: string;
31
31
  clearable: boolean;
32
32
  status: import('../..').ControlStatus;
@@ -1,3 +1,5 @@
1
+ export * from './Accordion';
2
+ export * from './AccordionItem';
1
3
  export * from './Action';
2
4
  export * from './Actions';
3
5
  export * from './Autocomplete';
@@ -25,6 +27,7 @@ export * from './Input';
25
27
  export * from './InputNumber';
26
28
  export * from './Link';
27
29
  export * from './Pagination';
30
+ export * from './Popover';
28
31
  export * from './Prose';
29
32
  export * from './Radio';
30
33
  export * from './RadioGroup';
@@ -34,7 +37,9 @@ export * from './Select';
34
37
  export * from './Slider';
35
38
  export * from './Statistic';
36
39
  export * from './Switch';
40
+ export * from './Tab';
37
41
  export * from './Table';
42
+ export * from './Tabs';
38
43
  export * from './TagsInput';
39
44
  export * from './Text';
40
45
  export * from './Textarea';
@@ -0,0 +1,16 @@
1
+ import { ComputedRef, InjectionKey } from 'vue';
2
+ export type AccordionSize = 'sm' | 'md';
3
+ /** Boxed as one list, each panel its own card, or nothing but rules between them. */
4
+ export type AccordionVariant = 'bordered' | 'separated' | 'plain';
5
+ /** Which side of the header the chevron sits on. */
6
+ export type AccordionIconPosition = 'start' | 'end';
7
+ /** What `WxAccordion` hands down to the items inside it. */
8
+ export interface AccordionContext {
9
+ size: ComputedRef<AccordionSize>;
10
+ variant: ComputedRef<AccordionVariant>;
11
+ iconPosition: ComputedRef<AccordionIconPosition>;
12
+ /** The element each header is written as, so a page keeps one heading outline. */
13
+ headingTag: ComputedRef<string>;
14
+ }
15
+ export declare const accordionKey: InjectionKey<AccordionContext>;
16
+ export declare function useAccordion(): AccordionContext | null;