@plexui/vue 0.9.0 → 0.11.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.
- package/dist/es/components/Alert/Alert.js +6 -2
- package/dist/es/components/Alert/Alert.js.map +1 -1
- package/dist/es/components/Avatar/Avatar.js +3 -1
- package/dist/es/components/Avatar/Avatar.js.map +1 -1
- package/dist/es/components/ButtonGroup/ButtonGroup.js +7 -0
- package/dist/es/components/ButtonGroup/ButtonGroup.js.map +1 -1
- package/dist/es/components/ButtonGroup/index.js.map +1 -1
- package/dist/es/components/Checkbox/Checkbox.js +5 -6
- package/dist/es/components/Checkbox/Checkbox.js.map +1 -1
- package/dist/es/components/ColorPicker/ColorPicker.js +476 -0
- package/dist/es/components/ColorPicker/ColorPicker.js.map +1 -0
- package/dist/es/components/ColorPicker/ColorWell.js +186 -0
- package/dist/es/components/ColorPicker/ColorWell.js.map +1 -0
- package/dist/es/components/ColorPicker/index.js +3 -0
- package/dist/es/components/ColorPicker/index.js.map +1 -0
- package/dist/es/components/ColorPicker/shared.js +132 -0
- package/dist/es/components/ColorPicker/shared.js.map +1 -0
- package/dist/es/components/ContextMenu/ContextMenu.js +223 -0
- package/dist/es/components/ContextMenu/ContextMenu.js.map +1 -0
- package/dist/es/components/ContextMenu/index.js +2 -0
- package/dist/es/components/ContextMenu/index.js.map +1 -0
- package/dist/es/components/ContextMenu/shared.js +58 -0
- package/dist/es/components/ContextMenu/shared.js.map +1 -0
- package/dist/es/components/DatePicker/DatePicker.js +19 -3
- package/dist/es/components/DatePicker/DatePicker.js.map +1 -1
- package/dist/es/components/DateRangePicker/DateRangePicker.js +1 -1
- package/dist/es/components/DateRangePicker/DateRangePicker.js.map +1 -1
- package/dist/es/components/Dialog/Dialog.js +245 -25
- package/dist/es/components/Dialog/Dialog.js.map +1 -1
- package/dist/es/components/Dialog/dialogSteps.js +85 -0
- package/dist/es/components/Dialog/dialogSteps.js.map +1 -0
- package/dist/es/components/Dialog/dialogViewport.js +74 -0
- package/dist/es/components/Dialog/dialogViewport.js.map +1 -0
- package/dist/es/components/Dialog/index.js +1 -1
- package/dist/es/components/Dialog/index.js.map +1 -1
- package/dist/es/components/Dialog/sheetDrag.js +2 -1
- package/dist/es/components/Dialog/sheetDrag.js.map +1 -1
- package/dist/es/components/Field/Field.js +11 -3
- package/dist/es/components/Field/Field.js.map +1 -1
- package/dist/es/components/FieldGroup/FieldGroup.js +12 -1
- package/dist/es/components/FieldGroup/FieldGroup.js.map +1 -1
- package/dist/es/components/FloatingLabelInput/FloatingLabelInput.js +2 -2
- package/dist/es/components/FloatingLabelInput/FloatingLabelInput.js.map +1 -1
- package/dist/es/components/Icon/index.js +1 -0
- package/dist/es/components/Icon/index.js.map +1 -1
- package/dist/es/components/Icon/svg/Eyedropper.js +10 -0
- package/dist/es/components/Icon/svg/Eyedropper.js.map +1 -0
- package/dist/es/components/IndexBar/IndexBar.js +215 -0
- package/dist/es/components/IndexBar/IndexBar.js.map +1 -0
- package/dist/es/components/IndexBar/index.js +2 -0
- package/dist/es/components/IndexBar/index.js.map +1 -0
- package/dist/es/components/Indicator/LoadingIndicator.js +1 -1
- package/dist/es/components/Indicator/LoadingIndicator.js.map +1 -1
- package/dist/es/components/Input/Input.js +3 -2
- package/dist/es/components/Input/Input.js.map +1 -1
- package/dist/es/components/MarkdownEditor/MarkdownEditor.js +149 -1
- package/dist/es/components/MarkdownEditor/MarkdownEditor.js.map +1 -1
- package/dist/es/components/Menu/Menu.js +206 -33
- package/dist/es/components/Menu/Menu.js.map +1 -1
- package/dist/es/components/Menu/index.js +1 -1
- package/dist/es/components/Menu/index.js.map +1 -1
- package/dist/es/components/Page/Page.js +43 -11
- package/dist/es/components/Page/Page.js.map +1 -1
- package/dist/es/components/PageControl/PageControl.js +210 -0
- package/dist/es/components/PageControl/PageControl.js.map +1 -0
- package/dist/es/components/PageControl/index.js +2 -0
- package/dist/es/components/PageControl/index.js.map +1 -0
- package/dist/es/components/PhoneLayout/PhoneLayout.js +50 -0
- package/dist/es/components/PhoneLayout/PhoneLayout.js.map +1 -0
- package/dist/es/components/PhoneLayout/index.js +2 -0
- package/dist/es/components/PhoneLayout/index.js.map +1 -0
- package/dist/es/components/Popover/Popover.js +5 -1
- package/dist/es/components/Popover/Popover.js.map +1 -1
- package/dist/es/components/Popover/deferredPointerDownOutside.js +59 -4
- package/dist/es/components/Popover/deferredPointerDownOutside.js.map +1 -1
- package/dist/es/components/Select/Select.js +18 -11
- package/dist/es/components/Select/Select.js.map +1 -1
- package/dist/es/components/SelectControl/SelectControl.js +1 -0
- package/dist/es/components/SelectControl/SelectControl.js.map +1 -1
- package/dist/es/components/Sidebar/Sidebar.js +21 -6
- package/dist/es/components/Sidebar/Sidebar.js.map +1 -1
- package/dist/es/components/Slider/Slider.js +44 -9
- package/dist/es/components/Slider/Slider.js.map +1 -1
- package/dist/es/components/Stepper/Stepper.js +195 -0
- package/dist/es/components/Stepper/Stepper.js.map +1 -0
- package/dist/es/components/Stepper/index.js +2 -0
- package/dist/es/components/Stepper/index.js.map +1 -0
- package/dist/es/components/SwipeActions/SwipeActions.js +374 -0
- package/dist/es/components/SwipeActions/SwipeActions.js.map +1 -0
- package/dist/es/components/SwipeActions/index.js +2 -0
- package/dist/es/components/SwipeActions/index.js.map +1 -0
- package/dist/es/components/Switch/Switch.js +3 -1
- package/dist/es/components/Switch/Switch.js.map +1 -1
- package/dist/es/components/TabBar/TabBar.js +205 -0
- package/dist/es/components/TabBar/TabBar.js.map +1 -0
- package/dist/es/components/TabBar/index.js +2 -0
- package/dist/es/components/TabBar/index.js.map +1 -0
- package/dist/es/components/Tabs/Tabs.js +10 -2
- package/dist/es/components/Tabs/Tabs.js.map +1 -1
- package/dist/es/components/TagInput/TagInput.js +3 -46
- package/dist/es/components/TagInput/TagInput.js.map +1 -1
- package/dist/es/components/Textarea/Textarea.js +2 -0
- package/dist/es/components/Textarea/Textarea.js.map +1 -1
- package/dist/es/components/Tip/Tip.js +276 -0
- package/dist/es/components/Tip/Tip.js.map +1 -0
- package/dist/es/components/Tip/index.js +2 -0
- package/dist/es/components/Tip/index.js.map +1 -0
- package/dist/es/components/Toast/ToastRenderer.js +30 -13
- package/dist/es/components/Toast/ToastRenderer.js.map +1 -1
- package/dist/es/components/Toast/Toaster.js +17 -6
- package/dist/es/components/Toast/Toaster.js.map +1 -1
- package/dist/es/components/Toast/toastLifecycle.js +113 -1
- package/dist/es/components/Toast/toastLifecycle.js.map +1 -1
- package/dist/es/components/Toolbar/Toolbar.js +37 -6
- package/dist/es/components/Toolbar/Toolbar.js.map +1 -1
- package/dist/es/components/Toolbar/index.js.map +1 -1
- package/dist/es/components/Tooltip/slot.js +3 -3
- package/dist/es/components/Tooltip/slot.js.map +1 -1
- package/dist/es/composables/useEscCloseStack.js +8 -4
- package/dist/es/composables/useEscCloseStack.js.map +1 -1
- package/dist/es/lib/fieldRow.js +15 -2
- package/dist/es/lib/fieldRow.js.map +1 -1
- package/dist/es/lib/floatingBoundary.js +3 -1
- package/dist/es/lib/floatingBoundary.js.map +1 -1
- package/dist/es/lib/helpers.js +21 -0
- package/dist/es/lib/helpers.js.map +1 -1
- package/dist/es/lib/menuSubmenuPlacement.js +51 -6
- package/dist/es/lib/menuSubmenuPlacement.js.map +1 -1
- package/dist/es/lib/menuTriggerCover.js +70 -0
- package/dist/es/lib/menuTriggerCover.js.map +1 -0
- package/dist/es/lib/phoneLayout.js +16 -0
- package/dist/es/lib/phoneLayout.js.map +1 -0
- package/dist/es/lib/scrollEdges.js +34 -0
- package/dist/es/lib/scrollEdges.js.map +1 -0
- package/dist/es/lib/toastRegion.js +6 -0
- package/dist/es/lib/toastRegion.js.map +1 -0
- package/dist/types/components/ButtonGroup/ButtonGroup.d.ts +13 -0
- package/dist/types/components/ButtonGroup/index.d.ts +1 -1
- package/dist/types/components/ColorPicker/ColorPicker.d.ts +244 -0
- package/dist/types/components/ColorPicker/ColorWell.d.ts +334 -0
- package/dist/types/components/ColorPicker/index.d.ts +3 -0
- package/dist/types/components/ColorPicker/shared.d.ts +69 -0
- package/dist/types/components/ContextMenu/ContextMenu.d.ts +128 -0
- package/dist/types/components/ContextMenu/index.d.ts +1 -0
- package/dist/types/components/ContextMenu/shared.d.ts +51 -0
- package/dist/types/components/DatePicker/DatePicker.d.ts +24 -4
- package/dist/types/components/DateRangePicker/DateRangePicker.d.ts +4 -4
- package/dist/types/components/Dialog/Dialog.d.ts +100 -4
- package/dist/types/components/Dialog/dialogSteps.d.ts +10 -0
- package/dist/types/components/Dialog/dialogViewport.d.ts +1 -0
- package/dist/types/components/Dialog/index.d.ts +1 -1
- package/dist/types/components/Field/Field.d.ts +21 -2
- package/dist/types/components/FieldGroup/FieldGroup.d.ts +18 -1
- package/dist/types/components/Icon/index.d.ts +1 -0
- package/dist/types/components/Icon/svg/Eyedropper.d.ts +3 -0
- package/dist/types/components/IndexBar/IndexBar.d.ts +112 -0
- package/dist/types/components/IndexBar/index.d.ts +1 -0
- package/dist/types/components/Indicator/LoadingIndicator.d.ts +2 -2
- package/dist/types/components/Menu/Menu.d.ts +153 -40
- package/dist/types/components/Menu/index.d.ts +1 -1
- package/dist/types/components/Page/Page.d.ts +13 -5
- package/dist/types/components/PageControl/PageControl.d.ts +216 -0
- package/dist/types/components/PageControl/index.d.ts +1 -0
- package/dist/types/components/PhoneLayout/PhoneLayout.d.ts +21 -0
- package/dist/types/components/PhoneLayout/index.d.ts +1 -0
- package/dist/types/components/Popover/deferredPointerDownOutside.d.ts +1 -1
- package/dist/types/components/Select/Select.d.ts +6 -6
- package/dist/types/components/Stepper/Stepper.d.ts +338 -0
- package/dist/types/components/Stepper/index.d.ts +1 -0
- package/dist/types/components/SwipeActions/SwipeActions.d.ts +135 -0
- package/dist/types/components/SwipeActions/index.d.ts +1 -0
- package/dist/types/components/TabBar/TabBar.d.ts +405 -0
- package/dist/types/components/TabBar/index.d.ts +1 -0
- package/dist/types/components/Tip/Tip.d.ts +146 -0
- package/dist/types/components/Tip/index.d.ts +1 -0
- package/dist/types/components/Toast/toastLifecycle.d.ts +34 -0
- package/dist/types/components/Toolbar/Toolbar.d.ts +26 -9
- package/dist/types/components/Toolbar/index.d.ts +1 -1
- package/dist/types/components/Tooltip/CopyTooltip.d.ts +1 -1
- package/dist/types/composables/useEscCloseStack.d.ts +2 -2
- package/dist/types/lib/fieldRow.d.ts +5 -0
- package/dist/types/lib/helpers.d.ts +6 -0
- package/dist/types/lib/menuSubmenuPlacement.d.ts +14 -1
- package/dist/types/lib/menuTriggerCover.d.ts +23 -0
- package/dist/types/lib/phoneLayout.d.ts +11 -0
- package/dist/types/lib/scrollEdges.d.ts +16 -0
- package/dist/types/lib/toastRegion.d.ts +5 -0
- package/package.json +2 -2
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
import { type PropType } from "vue";
|
|
2
|
+
/** The edge of an inline tip that points at what it explains. */
|
|
3
|
+
export type TipArrowEdge = "top" | "bottom" | "left" | "right";
|
|
4
|
+
/** How a tip's actions show on a phone. */
|
|
5
|
+
export type TipMobileActions = "rows" | "buttons";
|
|
6
|
+
declare const TipComponent: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
7
|
+
/** Shows the Close button; called when it is clicked. */
|
|
8
|
+
onClose: PropType<() => void>;
|
|
9
|
+
/** Draws an arrow at this edge, pointing at what the tip explains (TipKit's annotation). */
|
|
10
|
+
arrowEdge: PropType<TipArrowEdge>;
|
|
11
|
+
/** The tip's title: what the feature is (or the `title` slot). */
|
|
12
|
+
title: StringConstructor;
|
|
13
|
+
/** One or two sentences on how to use it (or the `description` slot). */
|
|
14
|
+
description: StringConstructor;
|
|
15
|
+
/**
|
|
16
|
+
* How the actions show at 767px and below: rows of text under a separator, as iOS tips show them, or the buttons
|
|
17
|
+
* as given, each a full-width capsule under the message, as an iOS card that asks for a permission.
|
|
18
|
+
* @default "rows"
|
|
19
|
+
*/
|
|
20
|
+
mobileActions: PropType<TipMobileActions>;
|
|
21
|
+
}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
22
|
+
[key: string]: any;
|
|
23
|
+
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
24
|
+
/** Shows the Close button; called when it is clicked. */
|
|
25
|
+
onClose: PropType<() => void>;
|
|
26
|
+
/** Draws an arrow at this edge, pointing at what the tip explains (TipKit's annotation). */
|
|
27
|
+
arrowEdge: PropType<TipArrowEdge>;
|
|
28
|
+
/** The tip's title: what the feature is (or the `title` slot). */
|
|
29
|
+
title: StringConstructor;
|
|
30
|
+
/** One or two sentences on how to use it (or the `description` slot). */
|
|
31
|
+
description: StringConstructor;
|
|
32
|
+
/**
|
|
33
|
+
* How the actions show at 767px and below: rows of text under a separator, as iOS tips show them, or the buttons
|
|
34
|
+
* as given, each a full-width capsule under the message, as an iOS card that asks for a permission.
|
|
35
|
+
* @default "rows"
|
|
36
|
+
*/
|
|
37
|
+
mobileActions: PropType<TipMobileActions>;
|
|
38
|
+
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
39
|
+
/**
|
|
40
|
+
* A tip anchored to a control, after TipKit's popover tip. The default slot is the control; `icon`,
|
|
41
|
+
* `title`, `description` and `actions` slots fill the tip. It does not take the focus. Bind `v-model:open`.
|
|
42
|
+
*/
|
|
43
|
+
export declare const TipPopover: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
44
|
+
/** Shows the tip (controlled, `v-model:open`). */
|
|
45
|
+
open: {
|
|
46
|
+
type: BooleanConstructor;
|
|
47
|
+
default: undefined;
|
|
48
|
+
};
|
|
49
|
+
/** Shows the tip at first (uncontrolled). @default false */
|
|
50
|
+
defaultOpen: {
|
|
51
|
+
type: BooleanConstructor;
|
|
52
|
+
default: boolean;
|
|
53
|
+
};
|
|
54
|
+
/** The side of the control the tip shows on. Turned when it does not fit. @default "bottom" */
|
|
55
|
+
side: {
|
|
56
|
+
type: PropType<"top" | "right" | "bottom" | "left">;
|
|
57
|
+
default: string;
|
|
58
|
+
};
|
|
59
|
+
/** The alignment against the control. @default "center" */
|
|
60
|
+
align: {
|
|
61
|
+
type: PropType<"start" | "center" | "end">;
|
|
62
|
+
default: string;
|
|
63
|
+
};
|
|
64
|
+
/** The distance from the control to the arrow's point, in pixels. @default 4 */
|
|
65
|
+
sideOffset: {
|
|
66
|
+
type: NumberConstructor;
|
|
67
|
+
default: number;
|
|
68
|
+
};
|
|
69
|
+
/** Shows the Close button. @default true */
|
|
70
|
+
closeButton: {
|
|
71
|
+
type: BooleanConstructor;
|
|
72
|
+
default: boolean;
|
|
73
|
+
};
|
|
74
|
+
/** The tip's title: what the feature is (or the `title` slot). */
|
|
75
|
+
title: StringConstructor;
|
|
76
|
+
/** One or two sentences on how to use it (or the `description` slot). */
|
|
77
|
+
description: StringConstructor;
|
|
78
|
+
/**
|
|
79
|
+
* How the actions show at 767px and below: rows of text under a separator, as iOS tips show them, or the buttons
|
|
80
|
+
* as given, each a full-width capsule under the message, as an iOS card that asks for a permission.
|
|
81
|
+
* @default "rows"
|
|
82
|
+
*/
|
|
83
|
+
mobileActions: PropType<TipMobileActions>;
|
|
84
|
+
}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
85
|
+
[key: string]: any;
|
|
86
|
+
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
87
|
+
/** Close, Escape or a press outside closes the tip. */
|
|
88
|
+
"update:open": (open: boolean) => boolean;
|
|
89
|
+
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
90
|
+
/** Shows the tip (controlled, `v-model:open`). */
|
|
91
|
+
open: {
|
|
92
|
+
type: BooleanConstructor;
|
|
93
|
+
default: undefined;
|
|
94
|
+
};
|
|
95
|
+
/** Shows the tip at first (uncontrolled). @default false */
|
|
96
|
+
defaultOpen: {
|
|
97
|
+
type: BooleanConstructor;
|
|
98
|
+
default: boolean;
|
|
99
|
+
};
|
|
100
|
+
/** The side of the control the tip shows on. Turned when it does not fit. @default "bottom" */
|
|
101
|
+
side: {
|
|
102
|
+
type: PropType<"top" | "right" | "bottom" | "left">;
|
|
103
|
+
default: string;
|
|
104
|
+
};
|
|
105
|
+
/** The alignment against the control. @default "center" */
|
|
106
|
+
align: {
|
|
107
|
+
type: PropType<"start" | "center" | "end">;
|
|
108
|
+
default: string;
|
|
109
|
+
};
|
|
110
|
+
/** The distance from the control to the arrow's point, in pixels. @default 4 */
|
|
111
|
+
sideOffset: {
|
|
112
|
+
type: NumberConstructor;
|
|
113
|
+
default: number;
|
|
114
|
+
};
|
|
115
|
+
/** Shows the Close button. @default true */
|
|
116
|
+
closeButton: {
|
|
117
|
+
type: BooleanConstructor;
|
|
118
|
+
default: boolean;
|
|
119
|
+
};
|
|
120
|
+
/** The tip's title: what the feature is (or the `title` slot). */
|
|
121
|
+
title: StringConstructor;
|
|
122
|
+
/** One or two sentences on how to use it (or the `description` slot). */
|
|
123
|
+
description: StringConstructor;
|
|
124
|
+
/**
|
|
125
|
+
* How the actions show at 767px and below: rows of text under a separator, as iOS tips show them, or the buttons
|
|
126
|
+
* as given, each a full-width capsule under the message, as an iOS card that asks for a permission.
|
|
127
|
+
* @default "rows"
|
|
128
|
+
*/
|
|
129
|
+
mobileActions: PropType<TipMobileActions>;
|
|
130
|
+
}>> & Readonly<{
|
|
131
|
+
"onUpdate:open"?: ((open: boolean) => any) | undefined;
|
|
132
|
+
}>, {
|
|
133
|
+
open: boolean;
|
|
134
|
+
defaultOpen: boolean;
|
|
135
|
+
side: "left" | "right" | "bottom" | "top";
|
|
136
|
+
sideOffset: number;
|
|
137
|
+
align: "center" | "end" | "start";
|
|
138
|
+
closeButton: boolean;
|
|
139
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
140
|
+
/** A tip inside the page, after TipKit: a title, a description, an optional symbol, actions and Close. */
|
|
141
|
+
export declare const Tip: typeof TipComponent & {
|
|
142
|
+
Popover: typeof TipPopover;
|
|
143
|
+
};
|
|
144
|
+
export type TipProps = InstanceType<typeof TipComponent>["$props"];
|
|
145
|
+
export type TipPopoverProps = InstanceType<typeof TipPopover>["$props"];
|
|
146
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Tip, TipPopover, type TipArrowEdge, type TipMobileActions, type TipPopoverProps, type TipProps } from "./Tip.js";
|
|
@@ -54,6 +54,14 @@ export declare class ToastLifecycle<T extends ToastData> {
|
|
|
54
54
|
private lists;
|
|
55
55
|
private suppressed;
|
|
56
56
|
private lastPointerType;
|
|
57
|
+
private region;
|
|
58
|
+
private announcers;
|
|
59
|
+
private announced;
|
|
60
|
+
/** Alerts read by the assertive announcer: shown behind the stack, their own role could not speak */
|
|
61
|
+
private assertive;
|
|
62
|
+
private announceTimers;
|
|
63
|
+
private pending;
|
|
64
|
+
private flushTimer?;
|
|
57
65
|
constructor(dismissStore: (id: ToastId) => unknown, notify: (reason: "dismiss" | "auto", toast: T) => void);
|
|
58
66
|
subscribe: (listener: () => void) => () => void;
|
|
59
67
|
snapshot: () => number;
|
|
@@ -62,6 +70,17 @@ export declare class ToastLifecycle<T extends ToastData> {
|
|
|
62
70
|
get paused(): boolean;
|
|
63
71
|
connect(doc: Document): void;
|
|
64
72
|
private visibility;
|
|
73
|
+
private isolate;
|
|
74
|
+
setRegion(node: HTMLElement | null): void;
|
|
75
|
+
setAnnouncer(kind: "polite" | "assertive", node: HTMLElement | null): void;
|
|
76
|
+
/** An error that waits to be closed interrupts as an alert; every other toast is read politely. */
|
|
77
|
+
alert(entry: ToastEntry<T>): boolean;
|
|
78
|
+
/** Whether a toast's content carries role="alert": an alert, unless it came in behind the stack and the assertive announcer read it. */
|
|
79
|
+
alertRole(entry: ToastEntry<T>, custom: boolean): boolean;
|
|
80
|
+
private visible;
|
|
81
|
+
/** Reads a toast's words once, and again only when they change (a promise that settles, a custom toast's own state). */
|
|
82
|
+
speak(id: ToastId, node: HTMLElement, custom: boolean): void;
|
|
83
|
+
private flush;
|
|
65
84
|
disconnect(): void;
|
|
66
85
|
sync(toasts: T[], config: ToastConfig): void;
|
|
67
86
|
private pause;
|
|
@@ -84,6 +103,21 @@ export declare class ToastLifecycle<T extends ToastData> {
|
|
|
84
103
|
pointerMove(id: ToastId, event: PointerEvent): void;
|
|
85
104
|
pointerEnd(id: ToastId, event: PointerEvent, cancelled?: boolean): void;
|
|
86
105
|
}
|
|
106
|
+
/** The words a toast says: its title and description, or a custom toast's text. */
|
|
107
|
+
export declare const toastText: (node: HTMLElement) => string;
|
|
108
|
+
/** Hides the polite announcer from sight, not from a screen reader. */
|
|
109
|
+
export declare const announcerStyle: {
|
|
110
|
+
readonly position: "absolute";
|
|
111
|
+
readonly width: "1px";
|
|
112
|
+
readonly height: "1px";
|
|
113
|
+
readonly margin: "-1px";
|
|
114
|
+
readonly padding: "0";
|
|
115
|
+
readonly overflow: "hidden";
|
|
116
|
+
readonly clip: "rect(0 0 0 0)";
|
|
117
|
+
readonly clipPath: "inset(50%)";
|
|
118
|
+
readonly whiteSpace: "nowrap";
|
|
119
|
+
readonly border: "0";
|
|
120
|
+
};
|
|
87
121
|
export type Offset = number | string | Partial<Record<"top" | "right" | "bottom" | "left", number | string>>;
|
|
88
122
|
export declare const offsetStyles: (offset: Offset | undefined, mobileOffset: Offset | undefined) => Record<string, string>;
|
|
89
123
|
export declare const documentDirection: (doc: Document | undefined) => "ltr" | "rtl";
|
|
@@ -3,8 +3,18 @@ export type ToolbarPlacement = "top" | "bottom";
|
|
|
3
3
|
/** Title layouts of the phone top bar. */
|
|
4
4
|
export type ToolbarTitleStyle = "inline" | "large" | "compact-large" | "compact-medium";
|
|
5
5
|
export type ToolbarTitleAlign = "center" | "start";
|
|
6
|
-
/**
|
|
7
|
-
|
|
6
|
+
/**
|
|
7
|
+
* How a bar meets the content scrolled under it, after the scroll edge effect of iOS 26:
|
|
8
|
+
* - `"soft"` (the default of a bottom bar): at the top, the canvas color covers the content under the bar's controls and fades out past them, over a
|
|
9
|
+
* light blur; at the bottom of a page the content stays clear under and around the controls, as on native iOS 26,
|
|
10
|
+
* and a Sheet's bottom bar fades its content into the panel
|
|
11
|
+
* - `"hard"`: an opaque bar of the canvas color with a line once content is under it
|
|
12
|
+
* - `"glass"` (the default of a top bar): a translucent, blurred bar with a hairline, shown once content is under it
|
|
13
|
+
* - `"solid"`: an opaque bar of the canvas color without a line
|
|
14
|
+
*/
|
|
15
|
+
export type BarBackground = "soft" | "hard" | "glass" | "solid";
|
|
16
|
+
/** `"edge"` is the earlier name of `"soft"`. */
|
|
17
|
+
export type ToolbarBackground = BarBackground | "edge";
|
|
8
18
|
/**
|
|
9
19
|
* A surface that places phone toolbars: `Page` puts the top bar over its content
|
|
10
20
|
* and reserves the space; `Dialog` puts it under the Sheet's grabber.
|
|
@@ -12,8 +22,12 @@ export type ToolbarBackground = "edge" | "solid";
|
|
|
12
22
|
export type ToolbarHost = {
|
|
13
23
|
kind: "page" | "dialog";
|
|
14
24
|
setHeight?: (placement: ToolbarPlacement, height: number | undefined) => void;
|
|
15
|
-
/** Content has scrolled under the top bar, so its glass casts a shadow. */
|
|
25
|
+
/** Content has scrolled under the top bar, so its glass casts a shadow and a hard or glass bar shows its line. */
|
|
16
26
|
scrolled?: Ref<boolean>;
|
|
27
|
+
/** Content continues under the bottom bar, so a hard or glass bar shows its line. */
|
|
28
|
+
contentBelow?: Ref<boolean>;
|
|
29
|
+
/** Calls the listener with the content's scroll offset on every scroll; returns the unsubscribe. A TabBar minimizes with it. */
|
|
30
|
+
subscribeScroll?: (listener: (scrollTop: number) => void) => () => void;
|
|
17
31
|
};
|
|
18
32
|
export declare const TOOLBAR_HOST: InjectionKey<ToolbarHost>;
|
|
19
33
|
declare const ToolbarComponent: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
@@ -32,10 +46,10 @@ declare const ToolbarComponent: import("vue").DefineComponent<import("vue").Extr
|
|
|
32
46
|
type: PropType<ToolbarTitleAlign>;
|
|
33
47
|
default: string;
|
|
34
48
|
};
|
|
35
|
-
/** @default "
|
|
49
|
+
/** How the bar meets the content scrolled under it on a phone. @default "glass" at the top, "soft" at the bottom */
|
|
36
50
|
background: {
|
|
37
51
|
type: PropType<ToolbarBackground>;
|
|
38
|
-
default:
|
|
52
|
+
default: undefined;
|
|
39
53
|
};
|
|
40
54
|
}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
41
55
|
[key: string]: any;
|
|
@@ -55,15 +69,15 @@ declare const ToolbarComponent: import("vue").DefineComponent<import("vue").Extr
|
|
|
55
69
|
type: PropType<ToolbarTitleAlign>;
|
|
56
70
|
default: string;
|
|
57
71
|
};
|
|
58
|
-
/** @default "
|
|
72
|
+
/** How the bar meets the content scrolled under it on a phone. @default "glass" at the top, "soft" at the bottom */
|
|
59
73
|
background: {
|
|
60
74
|
type: PropType<ToolbarBackground>;
|
|
61
|
-
default:
|
|
75
|
+
default: undefined;
|
|
62
76
|
};
|
|
63
77
|
}>> & Readonly<{}>, {
|
|
64
78
|
background: ToolbarBackground;
|
|
65
|
-
placement: ToolbarPlacement;
|
|
66
79
|
titleStyle: ToolbarTitleStyle;
|
|
80
|
+
placement: ToolbarPlacement;
|
|
67
81
|
titleAlign: ToolbarTitleAlign;
|
|
68
82
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
69
83
|
/** Props of `Toolbar`. */
|
|
@@ -71,6 +85,7 @@ export type ToolbarProps = {
|
|
|
71
85
|
placement?: ToolbarPlacement;
|
|
72
86
|
titleStyle?: ToolbarTitleStyle;
|
|
73
87
|
titleAlign?: ToolbarTitleAlign;
|
|
88
|
+
/** How the bar meets the content scrolled under it on a phone. @default "glass" at the top, "soft" at the bottom */
|
|
74
89
|
background?: ToolbarBackground;
|
|
75
90
|
} & HTMLAttributes;
|
|
76
91
|
/** A phone toolbar, top or bottom. It never renders at the desktop breakpoint. */
|
|
@@ -127,7 +142,9 @@ export declare const ToolbarTitle: import("vue").DefineComponent<import("vue").E
|
|
|
127
142
|
};
|
|
128
143
|
}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
129
144
|
[key: string]: any;
|
|
130
|
-
}
|
|
145
|
+
}> | import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
146
|
+
[key: string]: any;
|
|
147
|
+
}>[], {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
131
148
|
/** A second, smaller line below the title. The `subtitle` slot takes precedence. */
|
|
132
149
|
subtitle: {
|
|
133
150
|
type: StringConstructor;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { Toolbar, ToolbarContent, ToolbarGroup, ToolbarLeading, ToolbarTitle, ToolbarTrailing, TOOLBAR_HOST, type ToolbarBackground, type ToolbarHost, type ToolbarPlacement, type ToolbarProps, type ToolbarTitleAlign, type ToolbarTitleStyle, } from "./Toolbar.js";
|
|
1
|
+
export { Toolbar, ToolbarContent, ToolbarGroup, ToolbarLeading, ToolbarTitle, ToolbarTrailing, TOOLBAR_HOST, type BarBackground, type ToolbarBackground, type ToolbarHost, type ToolbarPlacement, type ToolbarProps, type ToolbarTitleAlign, type ToolbarTitleStyle, } from "./Toolbar.js";
|
|
@@ -73,8 +73,8 @@ export declare const CopyTooltip: import("vue").DefineComponent<import("vue").Ex
|
|
|
73
73
|
}>, {
|
|
74
74
|
side: TooltipSide;
|
|
75
75
|
sideOffset: number;
|
|
76
|
-
align: TooltipAlign;
|
|
77
76
|
alignOffset: number;
|
|
77
|
+
align: TooltipAlign;
|
|
78
78
|
openDelay: number;
|
|
79
79
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
80
80
|
export type CopyTooltipProps = InstanceType<typeof CopyTooltip>["$props"];
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type MaybeRefOrGetter } from "vue";
|
|
2
2
|
/**
|
|
3
3
|
* Escape closes the most recently registered listener first, so nested
|
|
4
|
-
* overlays close one at a time.
|
|
4
|
+
* overlays close one at a time. The callback gets the key event, already prevented.
|
|
5
5
|
*/
|
|
6
|
-
export declare const useEscCloseStack: (listening: MaybeRefOrGetter<boolean>, cb: () => void) => void;
|
|
6
|
+
export declare const useEscCloseStack: (listening: MaybeRefOrGetter<boolean>, cb: (event: KeyboardEvent) => void) => void;
|
|
@@ -1,4 +1,9 @@
|
|
|
1
1
|
import { type ComputedRef } from "vue";
|
|
2
2
|
export declare const provideFieldRow: (inRow: () => boolean) => void;
|
|
3
|
+
/** True when the control ends a `Field row`. */
|
|
4
|
+
export declare const useFieldRow: () => ComputedRef<boolean>;
|
|
5
|
+
export declare const provideFieldColumns: (columns: () => boolean) => void;
|
|
6
|
+
/** True when the control's value starts at the column of a `FieldGroup columns`. */
|
|
7
|
+
export declare const useFieldColumns: () => ComputedRef<boolean>;
|
|
3
8
|
/** The control's own `pill`, or else the shape of its row. */
|
|
4
9
|
export declare const useFieldRowPill: (pill: () => boolean | undefined) => ComputedRef<boolean>;
|
|
@@ -25,6 +25,12 @@ export declare const toFilterProperty: ({ blur }?: {
|
|
|
25
25
|
export declare const dataAttributes: (props: Record<string, unknown>) => {
|
|
26
26
|
[k: string]: unknown;
|
|
27
27
|
};
|
|
28
|
+
/**
|
|
29
|
+
* A copy of a key event that a handler can cancel. An event that reaches the Escape stack is already prevented, so
|
|
30
|
+
* its own `defaultPrevented` cannot tell whether an owner's handler asked to keep the overlay open. The copy keeps
|
|
31
|
+
* the key, the modifiers and the target.
|
|
32
|
+
*/
|
|
33
|
+
export declare const cancelableKeyCopy: (event: KeyboardEvent) => KeyboardEvent;
|
|
28
34
|
export declare const preventDefaultHandler: (evt: Event) => void;
|
|
29
35
|
/**
|
|
30
36
|
* For an overlay's close auto focus: focus that moved on to something else
|
|
@@ -22,15 +22,28 @@ export type PhoneSubmenuState = {
|
|
|
22
22
|
unavailable: boolean;
|
|
23
23
|
label: string;
|
|
24
24
|
} & PhoneSubmenuPlacement);
|
|
25
|
-
export declare function solvePhoneSubmenuPlacement({ boundary, trigger, parent, width, height, paddingTop, direction, }: {
|
|
25
|
+
export declare function solvePhoneSubmenuPlacement({ boundary, trigger, parent, reference, width, height, paddingTop, direction, }: {
|
|
26
26
|
boundary: MenuRect;
|
|
27
27
|
trigger: MenuRect;
|
|
28
28
|
parent: MenuRect;
|
|
29
|
+
/** The row's box as the primitive measures it, when the parent steps back (`readRestingMenuRects`) */
|
|
30
|
+
reference?: MenuRect;
|
|
29
31
|
width: number;
|
|
30
32
|
height: number;
|
|
31
33
|
paddingTop: number;
|
|
32
34
|
direction: "ltr" | "rtl";
|
|
33
35
|
}): PhoneSubmenuPlacement | null;
|
|
36
|
+
/**
|
|
37
|
+
* The boxes of a parent menu and of the row that opened a submenu at rest. While a phone submenu stands over it the
|
|
38
|
+
* parent steps back with the CSS `scale` property (Menu.module.css, iOS-menu IMG_5677), and the submenu keeps the
|
|
39
|
+
* parent's resting box, as the native one does: undo that scale around the parent's transform origin, at whatever
|
|
40
|
+
* value its transition has reached.
|
|
41
|
+
*/
|
|
42
|
+
export declare function readRestingMenuRects(parent: HTMLElement, trigger: HTMLElement): {
|
|
43
|
+
parent: MenuRect;
|
|
44
|
+
trigger: MenuRect;
|
|
45
|
+
reference: MenuRect;
|
|
46
|
+
};
|
|
34
47
|
/** Consume boundary91's resolved footer padding; never subtract the footer again. */
|
|
35
48
|
export declare function readMenuBoundaryRect(document: Document, boundary: MenuFloatingBoundary): MenuRect | null;
|
|
36
49
|
/** A text snapshot, never a clone of a consumer's rich children or their IDs. */
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/** Where a phone menu stands over its trigger: the side offset that covers it, and the side it opens to. */
|
|
2
|
+
export type MenuTriggerCover = {
|
|
3
|
+
sideOffset: number;
|
|
4
|
+
side: "top" | "bottom";
|
|
5
|
+
};
|
|
6
|
+
/**
|
|
7
|
+
* On a phone a menu grows out of the control that opens it and covers it, as iOS 26 menus do: the panel's top is the
|
|
8
|
+
* control's top, or its bottom when the menu opens upward, and its aligned edge is the control's edge (iOS-menu
|
|
9
|
+
* IMG_5657 and IMG_5654, the More button of a top bar; IMG_5658, a button of a group; IMG_5649, the value of a form
|
|
10
|
+
* row; IMG_5675 opens upward over its row). It opens toward the larger part of the screen: downward from a control in
|
|
11
|
+
* the upper half, upward from one in the lower half even when it would fit below (IMG_5688, the Icon and List Size
|
|
12
|
+
* row of Files' View Options; IMG_5687, IMG_5689, and IMG_5693 from a bottom bar). Reports the side offset that puts
|
|
13
|
+
* the panel there, minus the control's height, and that side, while the screen is a phone, and `null` on a larger one,
|
|
14
|
+
* where the menu keeps its gap below the control.
|
|
15
|
+
*/
|
|
16
|
+
export declare function observeMenuTriggerCover(trigger: HTMLElement, onChange: (cover: MenuTriggerCover | null) => void): () => void;
|
|
17
|
+
/**
|
|
18
|
+
* A mouse opens a menu when its button goes down, so on a phone-wide window the menu that covers the trigger is under
|
|
19
|
+
* the pointer when the button comes up, and that release would choose the item there. Cancels the release of the press
|
|
20
|
+
* that opened the menu while it is still over the trigger; a press dragged off the trigger onto an item still chooses
|
|
21
|
+
* it, as a touch dragged through an iOS menu does.
|
|
22
|
+
*/
|
|
23
|
+
export declare function ignoreReleaseOverTrigger(trigger: HTMLElement, pointerId: number): void;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The phone layout outside a narrow window (plan 176). The style sheets apply their phone rules (767px and below)
|
|
3
|
+
* inside an element marked `data-plex-layout="phone"` too, at any window width: PhoneLayout marks one, and so does a
|
|
4
|
+
* Dialog with `layout="phone"`. Scripts that change what they do on a phone ask the same question here.
|
|
5
|
+
*/
|
|
6
|
+
export declare const PHONE_LAYOUT_SCOPE = "[data-plex-layout=\"phone\"]";
|
|
7
|
+
export declare const PHONE_MEDIA = "(max-width: 767px)";
|
|
8
|
+
/** The window is 767px wide or narrower. */
|
|
9
|
+
export declare const isPhoneWindow: (view: Window | null | undefined) => boolean;
|
|
10
|
+
/** The element is laid out as on a phone: inside a phone layout, or in a window 767px wide or narrower. */
|
|
11
|
+
export declare const isPhoneLayout: (element: Element) => boolean;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/** Where content lies under the bars of a scroll area. */
|
|
2
|
+
export type ScrollEdges = {
|
|
3
|
+
/** Content has scrolled under the top bar. */
|
|
4
|
+
scrolled: boolean;
|
|
5
|
+
/** Content continues under the bottom bar. */
|
|
6
|
+
contentBelow: boolean;
|
|
7
|
+
};
|
|
8
|
+
export declare const NO_SCROLL_EDGES: ScrollEdges;
|
|
9
|
+
export declare const SCROLL_EDGE_SLOP = 4;
|
|
10
|
+
export declare const scrollEdges: (element: HTMLElement) => ScrollEdges;
|
|
11
|
+
export declare const sameScrollEdges: (a: ScrollEdges, b: ScrollEdges) => boolean;
|
|
12
|
+
/**
|
|
13
|
+
* Reports the scroll edges of `element` now and whenever its scroll offset, its size or the size of its
|
|
14
|
+
* content changes, so a bar can show its line only while content is under it. Returns the cleanup.
|
|
15
|
+
*/
|
|
16
|
+
export declare const observeScrollEdges: (element: HTMLElement, onChange: (edges: ScrollEdges) => void) => (() => void);
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The toast region is a layer of its own above any overlay: a press, focus or Escape inside a toast belongs to the
|
|
3
|
+
* toast, never to a Dialog, Popover or Menu under it. Every toast list carries `data-sonner-toaster`.
|
|
4
|
+
*/
|
|
5
|
+
export declare const inToastRegion: (target: EventTarget | null | undefined) => boolean;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@plexui/vue",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.11.0",
|
|
4
4
|
"description": "Plex UI components for Vue 3, built on Reka UI and the shared @plexui/styles CSS",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -77,7 +77,7 @@
|
|
|
77
77
|
"@maskito/core": "5.2.2",
|
|
78
78
|
"@maskito/kit": "5.2.2",
|
|
79
79
|
"@maskito/vue": "5.2.2",
|
|
80
|
-
"@plexui/styles": "^0.1.
|
|
80
|
+
"@plexui/styles": "^0.1.35",
|
|
81
81
|
"@tanstack/table-core": "8.21.3",
|
|
82
82
|
"@tanstack/vue-table": "8.21.3",
|
|
83
83
|
"@tiptap/core": "3.21.0",
|