@m3e/web 2.2.1 → 2.3.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/README.md +2 -0
- package/dist/all.js +782 -5
- package/dist/all.js.map +1 -1
- package/dist/all.min.js +45 -45
- package/dist/all.min.js.map +1 -1
- package/dist/calendar.js +4 -2
- package/dist/calendar.js.map +1 -1
- package/dist/calendar.min.js +3 -3
- package/dist/calendar.min.js.map +1 -1
- package/dist/core.js +22 -1
- package/dist/core.js.map +1 -1
- package/dist/core.min.js +1 -1
- package/dist/core.min.js.map +1 -1
- package/dist/css-custom-data.json +733 -603
- package/dist/custom-elements.json +8398 -7000
- package/dist/datepicker.js +3 -1
- package/dist/datepicker.js.map +1 -1
- package/dist/datepicker.min.js +1 -1
- package/dist/datepicker.min.js.map +1 -1
- package/dist/html-custom-data.json +293 -205
- package/dist/skeleton.js +153 -0
- package/dist/skeleton.js.map +1 -0
- package/dist/skeleton.min.js +7 -0
- package/dist/skeleton.min.js.map +1 -0
- package/dist/split-pane.js +627 -0
- package/dist/split-pane.js.map +1 -0
- package/dist/split-pane.min.js +7 -0
- package/dist/split-pane.min.js.map +1 -0
- package/dist/src/all.d.ts +2 -0
- package/dist/src/all.d.ts.map +1 -1
- package/dist/src/calendar/CalendarElement.d.ts +2 -0
- package/dist/src/calendar/CalendarElement.d.ts.map +1 -1
- package/dist/src/calendar/CalendarViewElementBase.d.ts.map +1 -1
- package/dist/src/calendar/MonthViewElement.d.ts.map +1 -1
- package/dist/src/core/shared/utils/index.d.ts +1 -0
- package/dist/src/core/shared/utils/index.d.ts.map +1 -1
- package/dist/src/core/shared/utils/waitForUpgrade.d.ts +6 -0
- package/dist/src/core/shared/utils/waitForUpgrade.d.ts.map +1 -0
- package/dist/src/datepicker/DatepickerElement.d.ts +2 -0
- package/dist/src/datepicker/DatepickerElement.d.ts.map +1 -1
- package/dist/src/skeleton/SkeletonAnimation.d.ts +3 -0
- package/dist/src/skeleton/SkeletonAnimation.d.ts.map +1 -0
- package/dist/src/skeleton/SkeletonElement.d.ts +73 -0
- package/dist/src/skeleton/SkeletonElement.d.ts.map +1 -0
- package/dist/src/skeleton/SkeletonShape.d.ts +3 -0
- package/dist/src/skeleton/SkeletonShape.d.ts.map +1 -0
- package/dist/src/skeleton/index.d.ts +4 -0
- package/dist/src/skeleton/index.d.ts.map +1 -0
- package/dist/src/split-pane/SplitPaneElement.d.ts +163 -0
- package/dist/src/split-pane/SplitPaneElement.d.ts.map +1 -0
- package/dist/src/split-pane/SplitPaneOrientation.d.ts +3 -0
- package/dist/src/split-pane/SplitPaneOrientation.d.ts.map +1 -0
- package/dist/src/split-pane/index.d.ts +3 -0
- package/dist/src/split-pane/index.d.ts.map +1 -0
- package/package.json +11 -1
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
import { CSSResultGroup, LitElement, PropertyValues } from "lit";
|
|
2
|
+
import { formValue } from "@m3e/web/core";
|
|
3
|
+
import { Direction } from "@m3e/web/core/bidi";
|
|
4
|
+
import { SplitPaneOrientation } from "./SplitPaneOrientation";
|
|
5
|
+
declare const M3eSplitPaneElement_base: import("../core/shared/mixins/Constructor").Constructor<import("@m3e/web/core").FormAssociatedMixin> & import("../core/shared/mixins/Constructor").Constructor<import("@m3e/web/core").DisabledMixin> & import("../core/shared/mixins/Constructor").Constructor<import("@m3e/web/core").ReconnectedCallbackMixin> & import("../core/shared/mixins/Constructor").Constructor<import("@m3e/web/core").AttachInternalsMixin> & typeof LitElement;
|
|
6
|
+
/**
|
|
7
|
+
* A dual-view layout that separates content with a movable drag handle.
|
|
8
|
+
* @description
|
|
9
|
+
* The `m3e-split-pane` component delivers a Material 3-inspired split view with a
|
|
10
|
+
* movable drag handle, enabling responsive layout composition and pane resizing.
|
|
11
|
+
* It supports keyboard interaction, adaptive orientation, and optional detent snapping
|
|
12
|
+
* for consistent, accessible content distribution.
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* The following example illustrates the basic use of the `m3e-split-pane` with start and end content.
|
|
16
|
+
* In this example, the start pane occupies 25% of the available width.
|
|
17
|
+
* ```html
|
|
18
|
+
* <m3e-split-pane value="25">
|
|
19
|
+
* <m3e-card slot="start"></m3e-card>
|
|
20
|
+
* <m3e-card slot="end"></m3e-card>
|
|
21
|
+
* </m3e-split-pane>
|
|
22
|
+
* ```
|
|
23
|
+
*
|
|
24
|
+
* @example
|
|
25
|
+
* The next example demonstrates minimum and maximum constraints, where the start pane
|
|
26
|
+
* may shrink to 25% but cannot grow beyond 50% of the available space.
|
|
27
|
+
* ```html
|
|
28
|
+
* <m3e-split-pane value="25" min="25" max="50">
|
|
29
|
+
* <m3e-card slot="start"></m3e-card>
|
|
30
|
+
* <m3e-card slot="end"></m3e-card>
|
|
31
|
+
* </m3e-split-pane>
|
|
32
|
+
* ```
|
|
33
|
+
*
|
|
34
|
+
* @example
|
|
35
|
+
* The next example demonstrates percentage‑based detents, allowing the drag handle to snap at
|
|
36
|
+
* 0%, 25%, 50%, 75%, and 100% of the available space.
|
|
37
|
+
* ```html
|
|
38
|
+
* <m3e-split-pane value="50" detents="0 25 50 75 100">
|
|
39
|
+
* <m3e-card slot="start"></m3e-card>
|
|
40
|
+
* <m3e-card slot="end"></m3e-card>
|
|
41
|
+
* </m3e-split-pane>
|
|
42
|
+
* ```
|
|
43
|
+
*
|
|
44
|
+
* @tag m3e-split-pane
|
|
45
|
+
*
|
|
46
|
+
* @slot start - Renders content at the logical start side of the pane.
|
|
47
|
+
* @slot end - Renders content at the logical end side of the pane.
|
|
48
|
+
*
|
|
49
|
+
* @attr detents - Detents (discrete sizes) the start pane can snap to.
|
|
50
|
+
* @attr label - The accessible label given to the moveable drag handle.
|
|
51
|
+
* @attr max - A fractional value, between 0 and 100, indicating the maximum size of the start pane.
|
|
52
|
+
* @attr min - A fractional value, between 0 and 100, indicating the minimum size of the start pane.
|
|
53
|
+
* @attr orientation - The orientation of the split.
|
|
54
|
+
* @attr step - A fractional value, between 0 and 100, indicating the increment by which to adjust the value when resized via keyboard.
|
|
55
|
+
* @attr value - A fractional value, between 0 and 100, indicating the size of the start pane.
|
|
56
|
+
* @attr wrap-detents - Whether cycling through detents will wrap.
|
|
57
|
+
*
|
|
58
|
+
* @fires input - Fired continuously while the user adjusts the drag handle.
|
|
59
|
+
* @fires change - Fired when the user finishes adjusting the drag handle.
|
|
60
|
+
*
|
|
61
|
+
* @cssprop --m3e-split-pane-drag-handle-hover-color - Color used for the drag handle hover state.
|
|
62
|
+
* @cssprop --m3e-split-pane-drag-handle-hover-opacity - Opacity used for the drag handle hover state.
|
|
63
|
+
* @cssprop --m3e-split-pane-drag-handle-focus-color - Color used for the drag handle focus state.
|
|
64
|
+
* @cssprop --m3e-split-pane-drag-handle-focus-opacity - Opacity used for the drag handle focus state.
|
|
65
|
+
* @cssprop --m3e-split-pane-drag-handle-color - Background color of the drag handle when not pressed.
|
|
66
|
+
* @cssprop --m3e-split-pane-drag-handle-shape - Corner shape of the drag handle when not pressed.
|
|
67
|
+
* @cssprop --m3e-split-pane-drag-handle-pressed-color - Background color of the drag handle when pressed.
|
|
68
|
+
* @cssprop --m3e-split-pane-drag-handle-pressed-shape - Corner shape of the drag handle when pressed.
|
|
69
|
+
* @cssprop --m3e-split-pane-drag-handle-container-width - Width of the drag handle container.
|
|
70
|
+
* @cssprop --m3e-split-pane-drag-handle-width - Thickness of the drag handle when not pressed.
|
|
71
|
+
* @cssprop --m3e-split-pane-drag-handle-height - Length of the drag handle when not pressed.
|
|
72
|
+
* @cssprop --m3e-split-pane-drag-handle-pressed-width - Thickness of the drag handle when pressed.
|
|
73
|
+
* @cssprop --m3e-split-pane-drag-handle-pressed-height - Length of the drag handle when pressed.
|
|
74
|
+
*/
|
|
75
|
+
export declare class M3eSplitPaneElement extends M3eSplitPaneElement_base {
|
|
76
|
+
#private;
|
|
77
|
+
/** The styles of the element. */
|
|
78
|
+
static styles: CSSResultGroup;
|
|
79
|
+
/** @private */ _orientation?: Exclude<SplitPaneOrientation, "auto">;
|
|
80
|
+
/** @private */ private _base;
|
|
81
|
+
/** @private */ private _dragHandle;
|
|
82
|
+
/**
|
|
83
|
+
* A fractional value, between 0 and 100, indicating the size of the start pane.
|
|
84
|
+
* @default 50
|
|
85
|
+
*/
|
|
86
|
+
value: number;
|
|
87
|
+
/**
|
|
88
|
+
* A fractional value, between 0 and 100, indicating the minimum size of the start pane.
|
|
89
|
+
* @default 0
|
|
90
|
+
*/
|
|
91
|
+
min: number;
|
|
92
|
+
/**
|
|
93
|
+
* A fractional value, between 0 and 100, indicating the maximum size of the start pane.
|
|
94
|
+
* @default 100
|
|
95
|
+
*/
|
|
96
|
+
max: number;
|
|
97
|
+
/**
|
|
98
|
+
* A fractional value, between 0 and 100, indicating the increment by which to adjust the value when resized via keyboard.
|
|
99
|
+
* @default 1
|
|
100
|
+
*/
|
|
101
|
+
step: number;
|
|
102
|
+
/**
|
|
103
|
+
* Detents (discrete sizes) the start pane can snap to.
|
|
104
|
+
* @default []
|
|
105
|
+
*/
|
|
106
|
+
detents: string[];
|
|
107
|
+
/**
|
|
108
|
+
* Whether cycling through detents will wrap.
|
|
109
|
+
* @default false
|
|
110
|
+
*/
|
|
111
|
+
wrapDetents: boolean;
|
|
112
|
+
/**
|
|
113
|
+
* The orientation of the split.
|
|
114
|
+
* @default "horizontal"
|
|
115
|
+
*/
|
|
116
|
+
orientation: SplitPaneOrientation;
|
|
117
|
+
/**
|
|
118
|
+
* The accessible label given to the movable drag handle.
|
|
119
|
+
* @default "Resize panes"
|
|
120
|
+
*/
|
|
121
|
+
label: string;
|
|
122
|
+
/** A function used to generates human readable text for the accessible value (`aria-valuetext`) of the drag handle. */
|
|
123
|
+
valueFormatter?: (value: number, orientation: Omit<SplitPaneOrientation, "auto">, dir: Direction) => string | undefined;
|
|
124
|
+
/** The current orientation of the split. */
|
|
125
|
+
get currentOrientation(): Exclude<SplitPaneOrientation, "auto">;
|
|
126
|
+
/** @inheritdoc */
|
|
127
|
+
get [formValue](): string | File | FormData | null;
|
|
128
|
+
/**
|
|
129
|
+
* Moves the drag handle to the collapsed position. If detents exist, snaps to the collapsed detent.
|
|
130
|
+
* If no detents exist, moves to the minimum allowed value.
|
|
131
|
+
*/
|
|
132
|
+
collapse(): void;
|
|
133
|
+
/**
|
|
134
|
+
* Moves the drag handle to the expanded position. If detents exist, snaps to the expanded detent.
|
|
135
|
+
* If no detents exist, moves to the maximum allowed value.
|
|
136
|
+
*/
|
|
137
|
+
expand(): void;
|
|
138
|
+
/**
|
|
139
|
+
* Moves the drag handle to the specified position. If detents exist, snaps to the closest detent.
|
|
140
|
+
* If no detents exist, moves to the specified value.
|
|
141
|
+
* @param {number} value A fractional value, between 0 and 100, indicating the size of the start pane.
|
|
142
|
+
*/
|
|
143
|
+
snapToValue(value: number): void;
|
|
144
|
+
/** @inheritdoc */
|
|
145
|
+
disconnectedCallback(): void;
|
|
146
|
+
/** @inheritdoc */
|
|
147
|
+
reconnectedCallback(): void;
|
|
148
|
+
/** @inheritdoc */
|
|
149
|
+
protected willUpdate(changedProperties: PropertyValues<this>): void;
|
|
150
|
+
/** @inheritdoc */
|
|
151
|
+
protected updated(_changedProperties: PropertyValues): void;
|
|
152
|
+
/** @inheritdoc */
|
|
153
|
+
protected firstUpdated(_changedProperties: PropertyValues): void;
|
|
154
|
+
/** @inheritdoc */
|
|
155
|
+
protected render(): unknown;
|
|
156
|
+
}
|
|
157
|
+
declare global {
|
|
158
|
+
interface HTMLElementTagNameMap {
|
|
159
|
+
"m3e-split-pane": M3eSplitPaneElement;
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
export {};
|
|
163
|
+
//# sourceMappingURL=SplitPaneElement.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SplitPaneElement.d.ts","sourceRoot":"","sources":["../../../src/split-pane/SplitPaneElement.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,cAAc,EAAQ,UAAU,EAAE,cAAc,EAAa,MAAM,KAAK,CAAC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AIhB;;;OAGG;IACH,MAAM,IAAI,IAAI;IAId;;;;OAIG;IACH,WAAW,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI;IAUhC,kBAAkB;IACT,oBAAoB,IAAI,IAAI;IAOrC,kBAAkB;IACT,mBAAmB,IAAI,IAAI;IAUpC,kBAAkB;cACC,UAAU,CAAC,iBAAiB,EAAE,cAAc,CAAC,IAAI,CAAC,GAAG,IAAI;IAe5E,kBAAkB;cACC,OAAO,CAAC,kBAAkB,EAAE,cAAc,GAAG,IAAI;IAOpE,kBAAkB;cACC,YAAY,CAAC,kBAAkB,EAAE,cAAc,GAAG,IAAI;IAKzE,kBAAkB;cACC,MAAM,IAAI,OAAO;CAgbrC;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,gBAAgB,EAAE,mBAAmB,CAAC;KACvC;CACF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SplitPaneOrientation.d.ts","sourceRoot":"","sources":["../../../src/split-pane/SplitPaneOrientation.ts"],"names":[],"mappings":"AAAA,kEAAkE;AAClE,MAAM,MAAM,oBAAoB,GAAG,YAAY,GAAG,UAAU,GAAG,MAAM,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/split-pane/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC;AACnC,cAAc,wBAAwB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@m3e/web",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.3.0",
|
|
4
4
|
"description": "Platform-native Web Components for M3E",
|
|
5
5
|
"author": "matraic <matraic@yahoo.com>",
|
|
6
6
|
"license": "MIT",
|
|
@@ -48,10 +48,12 @@
|
|
|
48
48
|
"segmented-button",
|
|
49
49
|
"select",
|
|
50
50
|
"shape",
|
|
51
|
+
"skeleton",
|
|
51
52
|
"slide-group",
|
|
52
53
|
"slider",
|
|
53
54
|
"snackbar",
|
|
54
55
|
"split-button",
|
|
56
|
+
"split-pane",
|
|
55
57
|
"stepper",
|
|
56
58
|
"switch",
|
|
57
59
|
"tabs",
|
|
@@ -231,6 +233,10 @@
|
|
|
231
233
|
"types": "./dist/src/shape/index.d.ts",
|
|
232
234
|
"default": "./dist/shape.js"
|
|
233
235
|
},
|
|
236
|
+
"./skeleton": {
|
|
237
|
+
"types": "./dist/src/skeleton/index.d.ts",
|
|
238
|
+
"default": "./dist/skeleton.js"
|
|
239
|
+
},
|
|
234
240
|
"./slide-group": {
|
|
235
241
|
"types": "./dist/src/slide-group/index.d.ts",
|
|
236
242
|
"default": "./dist/slide-group.js"
|
|
@@ -247,6 +253,10 @@
|
|
|
247
253
|
"types": "./dist/src/split-button/index.d.ts",
|
|
248
254
|
"default": "./dist/split-button.js"
|
|
249
255
|
},
|
|
256
|
+
"./split-pane": {
|
|
257
|
+
"types": "./dist/src/split-pane/index.d.ts",
|
|
258
|
+
"default": "./dist/split-pane.js"
|
|
259
|
+
},
|
|
250
260
|
"./stepper": {
|
|
251
261
|
"types": "./dist/src/stepper/index.d.ts",
|
|
252
262
|
"default": "./dist/stepper.js"
|