@momentum-ui/web-components 2.22.17 → 2.23.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 (48) hide show
  1. package/dist/1439.js +1 -1
  2. package/dist/3135.js +1 -1
  3. package/dist/3820.js +1 -0
  4. package/dist/587.js +1 -1
  5. package/dist/6015.js +1 -1
  6. package/dist/6652.js +1 -1
  7. package/dist/6677.js +1 -1
  8. package/dist/754.js +1 -1
  9. package/dist/8004.js +1 -0
  10. package/dist/9058.js +1 -1
  11. package/dist/chunks/{md-7044.js → md-4663.js} +1 -1
  12. package/dist/comp/md-card-entry.js +1 -1
  13. package/dist/comp/md-card.js +1 -1
  14. package/dist/comp/md-coachmark-popover-entry.js +37 -41
  15. package/dist/comp/md-coachmark-popover.js +1 -1
  16. package/dist/comp/md-combobox-entry.js +1 -1
  17. package/dist/comp/md-combobox.js +1 -1
  18. package/dist/comp/md-date-range-picker-entry.js +1 -1
  19. package/dist/comp/md-date-range-picker.js +1 -1
  20. package/dist/comp/md-date-time-picker-entry.js +1 -1
  21. package/dist/comp/md-date-time-picker.js +1 -1
  22. package/dist/comp/md-datepicker-entry.js +1 -1
  23. package/dist/comp/md-datepicker.js +1 -1
  24. package/dist/comp/md-draggable-entry.js +1 -1
  25. package/dist/comp/md-draggable.js +1 -1
  26. package/dist/comp/md-floating-modal-entry.js +1 -1
  27. package/dist/comp/md-floating-modal.js +1 -1
  28. package/dist/comp/md-phone-input-entry.js +1 -1
  29. package/dist/comp/md-phone-input.js +1 -1
  30. package/dist/comp/md-popover-entry.js +17 -26
  31. package/dist/comp/md-popover.js +1 -1
  32. package/dist/comp/md-tabs-entry.js +1 -1
  33. package/dist/comp/md-timepicker-entry.js +1 -1
  34. package/dist/comp/md-timepicker.js +1 -1
  35. package/dist/index-entry.js +48 -52
  36. package/dist/index.js +1 -1
  37. package/dist/types/components/coachmark-popover/CoachmarkPopover.d.ts +1 -0
  38. package/dist/types/components/combobox/ComboBox.d.ts +1 -1
  39. package/dist/types/components/popover/Popover.constants.d.ts +53 -0
  40. package/dist/types/components/popover/Popover.d.ts +288 -191
  41. package/dist/types/components/popover/Popover.events.d.ts +34 -0
  42. package/dist/types/components/popover/Popover.stack.d.ts +45 -0
  43. package/dist/types/components/popover/Popover.types.d.ts +13 -1
  44. package/dist/types/components/popover/Popover.utils.d.ts +63 -0
  45. package/dist/types/index.d.ts +1 -0
  46. package/dist/types/utils/helpers.d.ts +2 -0
  47. package/package.json +2 -1
  48. package/dist/4663.js +0 -1
package/dist/index.js CHANGED
@@ -1 +1 @@
1
- require("./7678"),require("./7103"),require("./1890"),require("./6272"),require("./6325"),require("./6283"),require("./9217"),require("./5830"),require("./8889"),require("./8210"),require("./3135"),require("./1598"),require("./4977"),require("./1572"),require("./6366"),require("./7251"),require("./4974"),require("./2243"),require("./7919"),require("./3553"),require("./6700"),require("./528"),require("./4548"),require("./6795"),require("./76"),require("./1392"),require("./9164"),require("./1214"),require("./1625"),require("./3625"),require("./6067"),require("./8841"),require("./4663"),require("./3112"),require("./3866"),require("./1107"),require("./7330"),require("./7092"),require("./9719"),require("./6979"),require("./9130"),require("./6273"),require("./8612"),require("./9618"),require("./8521"),require("./2019"),require("./779"),require("./573"),require("./5801"),require("./2043"),require("./8171"),require("./2798"),require("./5467"),require("./2984"),require("./1869"),require("./2215"),require("./4392"),require("./630"),require("./3604"),require("./7833"),require("./8728"),require("./8227"),require("./1250"),require("./1705"),require("./7997"),require("./7875"),require("./6400"),require("./587"),require("./6441"),require("./6015"),require("./3663"),module.exports=require("./index-entry");
1
+ require("./7678"),require("./7103"),require("./1890"),require("./6272"),require("./6325"),require("./6283"),require("./9217"),require("./5830"),require("./8889"),require("./8210"),require("./3135"),require("./1598"),require("./4977"),require("./1572"),require("./6366"),require("./7251"),require("./4974"),require("./2243"),require("./7919"),require("./3553"),require("./6700"),require("./528"),require("./4548"),require("./6795"),require("./76"),require("./1392"),require("./9164"),require("./8004"),require("./1214"),require("./1625"),require("./3625"),require("./6067"),require("./8841"),require("./3112"),require("./3866"),require("./1107"),require("./7330"),require("./7092"),require("./9719"),require("./6979"),require("./9130"),require("./6273"),require("./8612"),require("./9618"),require("./8521"),require("./2019"),require("./779"),require("./573"),require("./5801"),require("./2043"),require("./8171"),require("./2798"),require("./5467"),require("./2984"),require("./1869"),require("./2215"),require("./4392"),require("./630"),require("./3604"),require("./7833"),require("./8728"),require("./8227"),require("./1250"),require("./1705"),require("./7997"),require("./7875"),require("./6400"),require("./587"),require("./6441"),require("./6015"),require("./3663"),module.exports=require("./index-entry");
@@ -27,6 +27,7 @@ export declare namespace CoachmarkPopover {
27
27
  * @type {PlacementType}
28
28
  */
29
29
  placement: PlacementType;
30
+ triggerID: string;
30
31
  /**
31
32
  * The name of the icon to be displayed before the title in the header.
32
33
  * If set, the specified icon will be rendered before the title.
@@ -204,7 +204,7 @@ export declare namespace ComboBox {
204
204
  checkForVirtualScroll(): boolean;
205
205
  rangeChanged(): void;
206
206
  getCustomErrorContent(): DocumentFragment;
207
- getCustomContent(option: string | OptionMember): DocumentFragment | TemplateResult;
207
+ getCustomContent(option: string | OptionMember): TemplateResult | DocumentFragment;
208
208
  renderGroupLabelHeader(option: OptionMember, optionIndex: number): TemplateResult;
209
209
  renderWithoutVirtualScroll(): import("lit-html").DirectiveFn;
210
210
  highlightingSearchedText(option: OptionMember | string): TemplateResult[];
@@ -0,0 +1,53 @@
1
+ declare const POPOVER_PLACEMENT: {
2
+ readonly LEFT_START: "left-start";
3
+ readonly LEFT: "left";
4
+ readonly LEFT_END: "left-end";
5
+ readonly RIGHT_START: "right-start";
6
+ readonly RIGHT: "right";
7
+ readonly RIGHT_END: "right-end";
8
+ readonly TOP_START: "top-start";
9
+ readonly TOP: "top";
10
+ readonly TOP_END: "top-end";
11
+ readonly BOTTOM_START: "bottom-start";
12
+ readonly BOTTOM: "bottom";
13
+ readonly BOTTOM_END: "bottom-end";
14
+ };
15
+ declare const POPOVER_STRATEGY: {
16
+ readonly FIXED: "fixed";
17
+ readonly ABSOLUTE: "absolute";
18
+ };
19
+ declare const TRIGGER: {
20
+ readonly CLICK: "click";
21
+ readonly MOUSEENTER: "mouseenter";
22
+ readonly FOCUSIN: "focusin";
23
+ readonly MANUAL: "manual";
24
+ };
25
+ declare const COLOR: {
26
+ readonly TONAL: "tonal";
27
+ readonly CONTRAST: "contrast";
28
+ };
29
+ declare const DEFAULTS: {
30
+ readonly PLACEMENT: "bottom";
31
+ readonly STRATEGY: "absolute";
32
+ readonly TRIGGER: "click";
33
+ readonly COLOR: "tonal";
34
+ readonly OFFSET: 4;
35
+ readonly VISIBLE: false;
36
+ readonly ARROW: false;
37
+ readonly CLOSE_BUTTON: false;
38
+ readonly FOCUS_TRAP: false;
39
+ readonly INTERACTIVE: false;
40
+ readonly PREVENT_SCROLL: false;
41
+ readonly HIDE_ON_ESCAPE: false;
42
+ readonly HIDE_ON_BLUR: false;
43
+ readonly HIDE_ON_CLICK_OUTSIDE: false;
44
+ readonly FOCUS_BACK: false;
45
+ readonly BACKDROP: false;
46
+ readonly FLIP: true;
47
+ readonly SIZE: false;
48
+ readonly DELAY: "0,0";
49
+ readonly ROLE: "dialog";
50
+ readonly Z_INDEX: 1000;
51
+ readonly DISABLE_ARIA_EXPANDED: false;
52
+ };
53
+ export { COLOR, DEFAULTS, POPOVER_PLACEMENT, POPOVER_STRATEGY, TRIGGER };
@@ -8,199 +8,296 @@
8
8
  import "@/components/button/Button";
9
9
  import "@/components/icon/Icon";
10
10
  import { LitElement, PropertyValues } from "lit-element";
11
- import { PlacementType, PopoverRoleType, StrategyType } from "./Popover.types";
12
- export declare namespace Popover {
13
- const ELEMENT_base: typeof LitElement & import("@/mixins/FocusTrapMixin").AnyConstructor<import("@/mixins/FocusTrapMixin").FocusTrapClass & import("@/mixins/FocusTrapMixin").FocusTrapInterface & import("../../mixins/FocusMixin").FocusClass>;
14
- /**
15
- * @fires popover-open-changed - Fired when the popover is opened or closed.
16
- */
17
- export class ELEMENT extends ELEMENT_base {
18
- /**
19
- * The placement of the popover relative to the trigger element.
20
- *
21
- * This property specifies where the popover should appear in relation to the trigger element.
22
- * The default placement is "bottom", but it can be customized to other positions such as "top", "left", or "right".
23
- *
24
- * @type {PlacementType}
25
- */
26
- placement: PlacementType;
27
- /**
28
- * The positioning strategy for the popover.
29
- *
30
- * This property specifies how the popover is positioned relative to the trigger element.
31
- * It accepts two values:
32
- * - `"absolute"`: The popover is positioned relative to the nearest positioned ancestor.
33
- * - `"fixed"`: The popover is positioned relative to the viewport, allowing it to escape parent containers with `overflow: hidden` or `overflow: auto`.
34
- *
35
- * By default, the positioning strategy is `"absolute"`. Use `"fixed"` if the popover needs to escape parent boundaries.
36
- *
37
- * @type {StrategyType}
38
- */
39
- positioningStrategy?: StrategyType;
40
- /**
41
- * Indicates whether the popover is open.
42
- *
43
- * This property controls the visibility of the popover. When set to true, the popover is displayed.
44
- * When set to false, the popover is hidden.
45
- *
46
- * @type {boolean}
47
- */
48
- isOpen: boolean;
49
- /**
50
- * Indicates whether the arrow should be shown on the popover.
51
- *
52
- * This property controls the visibility of the arrow on the popover. When set to true, the arrow is displayed.
53
- * When set to false, the arrow is hidden.
54
- *
55
- * @type {boolean}
56
- */
57
- showArrow: boolean;
58
- /**
59
- * Indicates whether the close button should be shown on the popover.
60
- *
61
- * This property controls the visibility of the close button on the popover. When set to true, the close button is displayed.
62
- * When set to false, the close button is hidden.
63
- *
64
- * @type {boolean}
65
- */
66
- showClose?: boolean | undefined;
67
- /**
68
- * Indicates whether the popover is interactive.
69
- *
70
- * When set to true, the popover will allow user interactions within it.
71
- * This property is used to determine if the popover should trap focus.
72
- *
73
- * @type {boolean}
74
- */
75
- interactive: boolean;
76
- /**
77
- * The role attribute for the popover.
78
- *
79
- * This property specifies the `role` attribute for the popover, which defines its role in the accessibility tree.
80
- * The default role is "dialog", but it can be customized to "dialog", "menu" or "tooltip.
81
- *
82
- * @type {PopoverRoleType}
83
- */
84
- role: PopoverRoleType;
85
- /**
86
- * The accessible label for the popover.
87
- *
88
- * This property specifies the `aria-label` attribute for the popover, which provides an accessible name for the popover element.
89
- * It is used by screen readers to announce the purpose of the popover to users with visual impairments.
90
- *
91
- * @type {string | null}
92
- */
93
- ariaLabel: string | null;
94
- /**
95
- * The offset distance (in pixels) from the trigger element.
96
- *
97
- * This property specifies the distance between the trigger element and the popover.
98
- * It is used to control the spacing between the trigger element and the popover when the popover is displayed.
99
- *
100
- * @type {number}
101
- */
102
- offsetDistance: number;
103
- /**
104
- * The slot element that contains the trigger element for the popover.
105
- *
106
- * This property is used to query the slot with the name "triggerElement" and store a reference to it.
107
- * The trigger element is the element that, when interacted with, will open or close the popover.
108
- *
109
- * @type {HTMLSlotElement}
110
- */
111
- triggerSlot: HTMLSlotElement;
112
- /**
113
- * The popover container element.
114
- *
115
- * This property is used to query the popover container element in the DOM.
116
- * The popover container is the main element that contains the popover content.
117
- *
118
- * @type {HTMLDivElement}
119
- */
120
- popoverContainer: HTMLDivElement;
121
- /**
122
- * The popover arrow element.
123
- *
124
- * This property is used to query the popover arrow element in the DOM.
125
- * The popover arrow is the element that visually connects the popover to the trigger element.
126
- *
127
- * @type {HTMLDivElement}
128
- */
129
- popoverArrow: HTMLDivElement;
130
- /**
131
- * The event that triggers the popover.
132
- *
133
- * This property specifies the event that will trigger the popover to open or close.
134
- * The default event is "click", but it can be customized to other events such as "mouseenter" or "focus".
135
- *
136
- * @type {string}
137
- */
138
- trigger?: string;
139
- /**
140
- * Indicates whether the popover should use an inverted color scheme.
141
- *
142
- * When set to `true`, the popover will invert its background color and text color.
143
- *
144
- * @type {boolean}
145
- */
146
- inverted: boolean;
147
- /**
148
- * The trigger element for the popover.
149
- *
150
- * This property holds a reference to the trigger element that, when interacted with, will open or close the popover.
151
- *
152
- * @type {HTMLElement | null}
153
- */
154
- private triggerElement;
155
- /**
156
- * The Popper.js instance used to manage the positioning of the popover.
157
- *
158
- * This instance is created when the popover is opened and destroyed when the popover is closed.
159
- * It is used to handle the positioning and alignment of the popover relative to the trigger element.
160
- */
161
- private popperInstance;
162
- /**
163
- * If mouse is over the trigger element or popover container.
164
- *
165
- * This property is used when both focus and mouse triggers are present
166
- * When focus leaves the trigger element if mouse is hovering we should not close the popover
167
- */
168
- private isMouseOver;
169
- static get styles(): import("lit-element").CSSResult[];
170
- connectedCallback(): void;
171
- disconnectedCallback(): void;
172
- private setupTriggerEvents;
173
- onOutsideOverlayClick: (event: MouseEvent) => void;
174
- onWindowBlurEvent: () => void;
175
- onOutsideOverlayKeydown: (event: KeyboardEvent) => Promise<void>;
176
- private handleTriggerElementSlotChange;
177
- private onContentSlotChanged;
178
- onTriggerElementClicked: () => void;
179
- onTriggerElementKeydown: (event: KeyboardEvent) => Promise<void>;
180
- onFocusInTrigger: () => void;
181
- onFocusOutTrigger: () => void;
182
- onMouseEnteredTriggerOrPopup: (_event: MouseEvent) => void;
183
- onMouseLeaveTriggerOrPopup: (_event: MouseEvent) => void;
184
- private shouldStayOpenOnTriggerFocus;
185
- private readonly setIsOpenDebounced;
186
- protected firstUpdated(changedProperties: PropertyValues): void;
187
- private focusInsideOverlay;
188
- private focusOnTrigger;
189
- private toggleOverlay;
190
- private handleCreatePopperFirstUpdate;
191
- private createInstance;
192
- private destroyInstance;
193
- protected updated(changedProperties: PropertyValues): void;
194
- private isOpenUpdated;
195
- private dispatchPopoverIsOpenChanged;
196
- private get popoverClassMap();
197
- private get renderPopoverTemplate();
198
- render(): import("lit-element").TemplateResult;
199
- }
200
- export {};
11
+ import { PopoverColor, PopoverPlacement, PopoverStrategy, PopoverTrigger } from "./Popover.types";
12
+ declare const Popover_base: typeof LitElement & import("@/mixins/FocusTrapMixin").AnyConstructor<import("@/mixins/FocusTrapMixin").FocusTrapClass & import("@/mixins/FocusTrapMixin").FocusTrapInterface & import("../../mixins/FocusMixin").FocusClass>;
13
+ /**
14
+ * Popover component is a lightweight floating UI element that displays additional content when triggered.
15
+ * It can be used for tooltips, dropdowns, or contextual menus.
16
+ * The popover automatically positions itself based on available space and
17
+ * supports dynamic height adjustments with scrollable content when needed。
18
+ *
19
+ * @dependency md-button
20
+ * @dependency md-icon
21
+ *
22
+ * @tagname md-popover
23
+ *
24
+ * @event shown - This event is dispatched when the popover is shown
25
+ * @event hidden - This event is dispatched when the popover is hidden
26
+ * @event created - This event is dispatched when the popover is created (added to the DOM)
27
+ * @event destroyed - This event is dispatched when the popover is destroyed (removed from the DOM)
28
+ *
29
+ * @cssproperty --md-popover-arrow-border-radius - radius of the arrow border
30
+ * @cssproperty --md-popover-arrow-border - border of the arrow
31
+ * @cssproperty --popover-bg-color - primary background color of the popover
32
+ * @cssproperty --popover-border-color - border color of the popover
33
+ * @cssproperty --popover-text-color - text color of the popover
34
+ * @cssproperty --popover-inverted-bg-color - inverted background color of the popover
35
+ * @cssproperty --popover-inverted-border-color - inverted border color of the popover
36
+ * @cssproperty --popover-inverted-text-color - inverted text color of the popover
37
+ * @cssproperty --md-popover-elevation-3 - elevation of the popover
38
+ * @cssproperty --md-popover-max-width - max width of the popover
39
+ * @cssproperty --md-popover-max-height - max height of the popover
40
+ *
41
+ * @slot - Default slot for the popover content
42
+ *
43
+ */
44
+ export declare class Popover extends Popover_base {
45
+ /**
46
+ * The unique ID of the popover.
47
+ */
48
+ id: string;
49
+ /**
50
+ * The ID of the element that triggers the popover.
51
+ * This attribute is required for the popover to work.
52
+ */
53
+ triggerID: string;
54
+ /**
55
+ * Determines the events that cause the Popover to show.
56
+ * Multiple event names should be separated by spaces.
57
+ * For example to allow both click and hover, use 'click mouseenter' as the trigger.
58
+ * - **click**
59
+ * - **mouseenter**
60
+ * - **focusin**
61
+ * - **manual**
62
+ * @default click
63
+ */
64
+ trigger: PopoverTrigger;
65
+ /**
66
+ * The placement of the popover.
67
+ * - **top**
68
+ * - **top-start**
69
+ * - **top-end**
70
+ * - **bottom**
71
+ * - **bottom-start**
72
+ * - **bottom-end**
73
+ * - **left**
74
+ * - **left-start**
75
+ * - **left-end**
76
+ * - **right**
77
+ * - **right-start**
78
+ * - **right-end**
79
+ * @default bottom
80
+ */
81
+ placement: PopoverPlacement;
82
+ /**
83
+ * The positioning strategy for the popover.
84
+ * - **absolute** - Position relative to closest positioned ancestor or the document body
85
+ * - **fixed** - Position relative to the viewport
86
+ * @default absolute
87
+ */
88
+ strategy: PopoverStrategy;
89
+ /**
90
+ * Color of the popover
91
+ * - **tonal**
92
+ * - **contrast**
93
+ * @default tonal
94
+ */
95
+ color: PopoverColor;
96
+ /**
97
+ * The visibility of the popover.
98
+ * @default false
99
+ */
100
+ visible: boolean;
101
+ /**
102
+ * The offset of the popover.
103
+ * @default 4
104
+ */
105
+ offset: number;
106
+ /**
107
+ * Determines whether the focus trap is enabled.
108
+ * If true, focus will be restricted to the content within this component.
109
+ * @default false
110
+ */
111
+ focusTrap: boolean;
112
+ /**
113
+ * Prevent outside scrolling when popover show.
114
+ * @default false
115
+ */
116
+ preventScroll: boolean;
117
+ /**
118
+ * The arrow visibility of the popover.
119
+ * @default false
120
+ */
121
+ showArrow: boolean;
122
+ /**
123
+ * The close button visibility of the popover.
124
+ * @default false
125
+ */
126
+ closeButton: boolean;
127
+ /**
128
+ * Determines whether the popover is interactive。
129
+ * @default false
130
+ */
131
+ interactive: boolean;
132
+ /**
133
+ * The delay of the show/hide popover.
134
+ * @default 0,0
135
+ */
136
+ delay: string;
137
+ /**
138
+ * Hide popover on escape key press.
139
+ * @default false
140
+ */
141
+ hideOnEscape: boolean;
142
+ /**
143
+ * Hide popover on blur.
144
+ * @default false
145
+ */
146
+ hideOnBlur: boolean;
147
+ /**
148
+ * Hide on outside click of the popover.
149
+ * @default false
150
+ */
151
+ hideOnOutsideClick: boolean;
152
+ /**
153
+ * The focus back to trigger after the popover hide.
154
+ * @default false
155
+ */
156
+ focusBackToTrigger: boolean;
157
+ /**
158
+ * Determines whether the popover with backdrop.
159
+ * Other than popover and trigger element, the rest of the screen will be covered with a backdrop.
160
+ * @default false
161
+ */
162
+ backdrop: boolean;
163
+ /**
164
+ * Changes the placement of popover to keep it in view when scrolling.
165
+ * @default true
166
+ */
167
+ flip: boolean;
168
+ /**
169
+ * Changes the size of popover to keep it in view when scrolling.
170
+ * @default false
171
+ */
172
+ size: boolean;
173
+ /**
174
+ * The z-index of the popover.
175
+ * @default 1000
176
+ */
177
+ zIndex: number;
178
+ /**
179
+ * Element ID that the popover append to.
180
+ * @default ''
181
+ */
182
+ appendTo: string;
183
+ /**
184
+ * aria-label attribute to be set for close button accessibility.
185
+ * @default null
186
+ */
187
+ closeButtonAriaLabel: string | null;
188
+ /**
189
+ * Role of the popover
190
+ * @default dialog
191
+ */
192
+ role: HTMLElement["role"];
193
+ /**
194
+ * aria-labelledby for an interactive popover only, defaults to the trigger component id.
195
+ * Used in nested cases where the triggerComponent isn't the actual button.
196
+ */
197
+ ariaLabelledby: string | null;
198
+ /**
199
+ * aria-describedby of the popover.
200
+ */
201
+ ariaDescribedby: string | null;
202
+ /**
203
+ * Disable aria-expanded attribute on trigger element.
204
+ * Make sure to set this to false when the popover is interactive.
205
+ * @default false
206
+ */
207
+ disableAriaExpanded: boolean;
208
+ arrowElement: HTMLElement | null;
209
+ triggerElement: HTMLElement | null;
210
+ /** @internal */
211
+ private hoverTimer;
212
+ /** @internal */
213
+ private isTriggerClicked;
214
+ /** @internal */
215
+ private openDelay;
216
+ /** @internal */
217
+ private closeDelay;
218
+ /** @internal */
219
+ private readonly utils;
220
+ /** @internal */
221
+ backdropElement: HTMLElement | null;
222
+ useLegacyFindFocusable: () => boolean;
223
+ constructor();
224
+ protected firstUpdated(changedProperties: PropertyValues): Promise<void>;
225
+ disconnectedCallback(): Promise<void>;
226
+ /**
227
+ * Sets up the trigger event listeners based on the trigger type.
228
+ */
229
+ setupTriggerListener(): void;
230
+ /**
231
+ * Removes the trigger event listeners.
232
+ */
233
+ removeEventListeners(): void;
234
+ protected updated(changedProperties: PropertyValues): Promise<void>;
235
+ /**
236
+ * Handles the outside click event to close the popover.
237
+ * Uses event.composedPath() to handle clicks across Shadow DOM boundaries.
238
+ *
239
+ * @param event - The mouse event.
240
+ */
241
+ private readonly onOutsidePopoverClick;
242
+ /**
243
+ * Handles the escape keydown event to close the popover.
244
+ *
245
+ * @param event - The keyboard event.
246
+ */
247
+ private readonly onEscapeKeydown;
248
+ /**
249
+ * Handles the popover focus out event.
250
+ *
251
+ * @param event - The focus event.
252
+ */
253
+ private readonly onPopoverFocusOut;
254
+ /**
255
+ * Handles the popover visibility change and position the popover.
256
+ * Handles the exit event to close the popover.
257
+ *
258
+ * @param oldValue - The old value of the visible property.
259
+ * @param newValue - The new value of the visible property.
260
+ */
261
+ private isOpenUpdated;
262
+ /**
263
+ * Starts the close delay timer.
264
+ * If the popover is not interactive, it will close the popover after the delay.
265
+ */
266
+ private readonly startCloseDelay;
267
+ /**
268
+ * Cancels the close delay timer.
269
+ */
270
+ readonly cancelCloseDelay: () => void;
271
+ /**
272
+ * Shows the popover.
273
+ */
274
+ showPopover: () => void;
275
+ /**
276
+ * Hides the popover.
277
+ */
278
+ hidePopover: () => void;
279
+ /**
280
+ * Toggles the popover visibility.
281
+ */
282
+ togglePopoverVisible: () => void;
283
+ private onTriggerClick;
284
+ private isMouseOverTrigger;
285
+ /**
286
+ * Sets the focusable elements inside the popover.
287
+ */
288
+ private handleCreatePopoverFirstUpdate;
289
+ /**
290
+ * Positions the popover based on the trigger element.
291
+ * It also handles the flip, size and arrow placement.
292
+ * It uses the floating-ui/dom library to calculate the position.
293
+ */
294
+ private positionPopover;
295
+ render(): import("lit-element").TemplateResult;
296
+ static get styles(): import("lit-element").CSSResult[];
201
297
  }
202
298
  declare global {
203
299
  interface HTMLElementTagNameMap {
204
- "md-popover": Popover.ELEMENT;
300
+ "md-popover": Popover;
205
301
  }
206
302
  }
303
+ export {};
@@ -0,0 +1,34 @@
1
+ import { type Popover } from "./Popover";
2
+ export declare class PopoverEventManager {
3
+ /**
4
+ * Dispatches a custom event for the popover.
5
+ *
6
+ * @param eventName - The name of the event.
7
+ * @param instance - The popover instance.
8
+ */
9
+ static dispatchPopoverEvent(eventName: string, instance: Popover): void;
10
+ /**
11
+ * Custom event that is fired when the popover is shown.
12
+ *
13
+ * @param instance - The popover instance.
14
+ */
15
+ static onShowPopover(instance: Popover): void;
16
+ /**
17
+ * Custom event that is fired when the popover is hidden.
18
+ *
19
+ * @param instance - The popover instance.
20
+ */
21
+ static onHidePopover(instance: Popover): void;
22
+ /**
23
+ * Custom event that is fired when the popover is created.
24
+ *
25
+ * @param instance - The popover instance.
26
+ */
27
+ static onCreatedPopover(instance: Popover): void;
28
+ /**
29
+ * Custom event that is fired when the popover is destroyed.
30
+ *
31
+ * @param instance - The popover instance.
32
+ */
33
+ static onDestroyedPopover(instance: Popover): void;
34
+ }