@4sh/ui-kit 0.15.0 → 0.17.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.fr.md +18 -10
- package/README.md +18 -10
- package/fesm2022/4sh-ui-kit-actions-ui-button-split.mjs +542 -150
- package/fesm2022/4sh-ui-kit-actions-ui-button-split.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-actions-ui-button.mjs +622 -248
- package/fesm2022/4sh-ui-kit-actions-ui-button.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-actions-ui-link.mjs +385 -152
- package/fesm2022/4sh-ui-kit-actions-ui-link.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-actions-ui-speed-dial.mjs +748 -433
- package/fesm2022/4sh-ui-kit-actions-ui-speed-dial.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-base-ui-icon.mjs +227 -135
- package/fesm2022/4sh-ui-kit-base-ui-icon.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-base-ui-image.mjs +1200 -633
- package/fesm2022/4sh-ui-kit-base-ui-image.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-autocomplete.mjs +1675 -953
- package/fesm2022/4sh-ui-kit-forms-ui-autocomplete.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-checkbox.mjs +243 -117
- package/fesm2022/4sh-ui-kit-forms-ui-checkbox.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-datepicker.mjs +2294 -2039
- package/fesm2022/4sh-ui-kit-forms-ui-datepicker.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-editor.mjs +1058 -1113
- package/fesm2022/4sh-ui-kit-forms-ui-editor.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-field-sign.mjs +1108 -0
- package/fesm2022/4sh-ui-kit-forms-ui-field-sign.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-forms-ui-field.mjs +397 -141
- package/fesm2022/4sh-ui-kit-forms-ui-field.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-file-upload.mjs +1529 -583
- package/fesm2022/4sh-ui-kit-forms-ui-file-upload.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-input-date.mjs +383 -224
- package/fesm2022/4sh-ui-kit-forms-ui-input-date.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-input-group.mjs +345 -177
- package/fesm2022/4sh-ui-kit-forms-ui-input-group.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-input-mask.mjs +280 -130
- package/fesm2022/4sh-ui-kit-forms-ui-input-mask.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-input-number.mjs +507 -246
- package/fesm2022/4sh-ui-kit-forms-ui-input-number.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-input-otp.mjs +401 -291
- package/fesm2022/4sh-ui-kit-forms-ui-input-otp.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-input-tags.mjs +1277 -697
- package/fesm2022/4sh-ui-kit-forms-ui-input-tags.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-input.mjs +467 -194
- package/fesm2022/4sh-ui-kit-forms-ui-input.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-knob.mjs +394 -270
- package/fesm2022/4sh-ui-kit-forms-ui-knob.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-label.mjs +140 -60
- package/fesm2022/4sh-ui-kit-forms-ui-label.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-nudger.mjs +386 -167
- package/fesm2022/4sh-ui-kit-forms-ui-nudger.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-radio.mjs +150 -87
- package/fesm2022/4sh-ui-kit-forms-ui-radio.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-rating.mjs +345 -180
- package/fesm2022/4sh-ui-kit-forms-ui-rating.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-segment-control.mjs +582 -392
- package/fesm2022/4sh-ui-kit-forms-ui-segment-control.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-select.mjs +1552 -888
- package/fesm2022/4sh-ui-kit-forms-ui-select.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-slider.mjs +485 -338
- package/fesm2022/4sh-ui-kit-forms-ui-slider.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-swatch-picker.mjs +503 -311
- package/fesm2022/4sh-ui-kit-forms-ui-swatch-picker.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-textarea.mjs +271 -131
- package/fesm2022/4sh-ui-kit-forms-ui-textarea.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-toggle-block.mjs +457 -214
- package/fesm2022/4sh-ui-kit-forms-ui-toggle-block.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-toggle-button.mjs +711 -371
- package/fesm2022/4sh-ui-kit-forms-ui-toggle-button.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms-ui-toggle.mjs +235 -121
- package/fesm2022/4sh-ui-kit-forms-ui-toggle.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-forms.mjs +723 -596
- package/fesm2022/4sh-ui-kit-forms.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-informative-ui-accordion.mjs +546 -242
- package/fesm2022/4sh-ui-kit-informative-ui-accordion.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-informative-ui-alert.mjs +335 -157
- package/fesm2022/4sh-ui-kit-informative-ui-alert.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-informative-ui-avatar-group.mjs +53 -33
- package/fesm2022/4sh-ui-kit-informative-ui-avatar-group.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-informative-ui-avatar.mjs +218 -121
- package/fesm2022/4sh-ui-kit-informative-ui-avatar.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-informative-ui-badge.mjs +192 -100
- package/fesm2022/4sh-ui-kit-informative-ui-badge.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-informative-ui-chip.mjs +456 -204
- package/fesm2022/4sh-ui-kit-informative-ui-chip.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-informative-ui-empty-state.mjs +314 -147
- package/fesm2022/4sh-ui-kit-informative-ui-empty-state.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-informative-ui-helper.mjs +179 -82
- package/fesm2022/4sh-ui-kit-informative-ui-helper.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-informative-ui-progress-bar.mjs +268 -123
- package/fesm2022/4sh-ui-kit-informative-ui-progress-bar.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-informative-ui-read-only.mjs +391 -146
- package/fesm2022/4sh-ui-kit-informative-ui-read-only.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-informative-ui-separator.mjs +158 -76
- package/fesm2022/4sh-ui-kit-informative-ui-separator.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-informative-ui-skeleton.mjs +159 -80
- package/fesm2022/4sh-ui-kit-informative-ui-skeleton.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-informative-ui-spinner.mjs +295 -131
- package/fesm2022/4sh-ui-kit-informative-ui-spinner.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-informative-ui-tag.mjs +211 -83
- package/fesm2022/4sh-ui-kit-informative-ui-tag.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-informative-ui-toast.mjs +784 -414
- package/fesm2022/4sh-ui-kit-informative-ui-toast.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-informative-ui-tooltip.mjs +822 -476
- package/fesm2022/4sh-ui-kit-informative-ui-tooltip.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-layout-ui-bottom-sheet.mjs +1014 -599
- package/fesm2022/4sh-ui-kit-layout-ui-bottom-sheet.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-layout-ui-card.mjs +403 -189
- package/fesm2022/4sh-ui-kit-layout-ui-card.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-layout-ui-drawer.mjs +707 -272
- package/fesm2022/4sh-ui-kit-layout-ui-drawer.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-layout-ui-modal.mjs +1146 -568
- package/fesm2022/4sh-ui-kit-layout-ui-modal.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-layout-ui-popover.mjs +519 -308
- package/fesm2022/4sh-ui-kit-layout-ui-popover.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-motion.mjs +252 -150
- package/fesm2022/4sh-ui-kit-motion.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-navigation-ui-bottom-tab-bar.mjs +793 -341
- package/fesm2022/4sh-ui-kit-navigation-ui-bottom-tab-bar.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-navigation-ui-breadcrumb.mjs +351 -194
- package/fesm2022/4sh-ui-kit-navigation-ui-breadcrumb.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-navigation-ui-context-menu.mjs +511 -220
- package/fesm2022/4sh-ui-kit-navigation-ui-context-menu.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-navigation-ui-menu.mjs +910 -548
- package/fesm2022/4sh-ui-kit-navigation-ui-menu.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-navigation-ui-sidebar.mjs +1128 -555
- package/fesm2022/4sh-ui-kit-navigation-ui-sidebar.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-navigation-ui-stepper.mjs +915 -470
- package/fesm2022/4sh-ui-kit-navigation-ui-stepper.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-navigation-ui-tabs.mjs +931 -474
- package/fesm2022/4sh-ui-kit-navigation-ui-tabs.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-overlay.mjs +26 -109
- package/fesm2022/4sh-ui-kit-overlay.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-ripple.mjs +329 -290
- package/fesm2022/4sh-ui-kit-ripple.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-table-ui-paginator.mjs +709 -248
- package/fesm2022/4sh-ui-kit-table-ui-paginator.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-table-ui-table.mjs +2633 -1370
- package/fesm2022/4sh-ui-kit-table-ui-table.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-theming.mjs +112 -113
- package/fesm2022/4sh-ui-kit-theming.mjs.map +1 -1
- package/fesm2022/4sh-ui-kit-types.mjs +0 -12
- package/fesm2022/4sh-ui-kit.mjs +3 -15
- package/fesm2022/4sh-ui-kit.mjs.map +1 -1
- package/mcp/data/component-api.json +313 -2
- package/mcp/data/text-search-docs.json +177 -17
- package/mcp/data/ui-config.json +378 -1
- package/mcp/index.js +8190 -2876
- package/mcp/package.json +1 -1
- package/package.json +5 -1
- package/styles/component-vars.scss +22 -1
- package/styles/utils/_mixins.scss +11 -0
- package/types/4sh-ui-kit-actions-ui-button-split.d.ts +198 -87
- package/types/4sh-ui-kit-actions-ui-button.d.ts +240 -116
- package/types/4sh-ui-kit-actions-ui-link.d.ts +136 -67
- package/types/4sh-ui-kit-actions-ui-speed-dial.d.ts +287 -180
- package/types/4sh-ui-kit-base-ui-icon.d.ts +92 -58
- package/types/4sh-ui-kit-base-ui-image.d.ts +406 -205
- package/types/4sh-ui-kit-forms-ui-autocomplete.d.ts +577 -367
- package/types/4sh-ui-kit-forms-ui-checkbox.d.ts +77 -42
- package/types/4sh-ui-kit-forms-ui-datepicker.d.ts +953 -700
- package/types/4sh-ui-kit-forms-ui-editor.d.ts +374 -340
- package/types/4sh-ui-kit-forms-ui-field-sign.d.ts +325 -0
- package/types/4sh-ui-kit-forms-ui-field.d.ts +150 -64
- package/types/4sh-ui-kit-forms-ui-file-upload.d.ts +583 -241
- package/types/4sh-ui-kit-forms-ui-input-date.d.ts +152 -103
- package/types/4sh-ui-kit-forms-ui-input-group.d.ts +109 -63
- package/types/4sh-ui-kit-forms-ui-input-mask.d.ts +93 -57
- package/types/4sh-ui-kit-forms-ui-input-number.d.ts +171 -93
- package/types/4sh-ui-kit-forms-ui-input-otp.d.ts +137 -100
- package/types/4sh-ui-kit-forms-ui-input-tags.d.ts +469 -309
- package/types/4sh-ui-kit-forms-ui-input.d.ts +198 -116
- package/types/4sh-ui-kit-forms-ui-knob.d.ts +132 -80
- package/types/4sh-ui-kit-forms-ui-label.d.ts +47 -22
- package/types/4sh-ui-kit-forms-ui-nudger.d.ts +134 -67
- package/types/4sh-ui-kit-forms-ui-radio.d.ts +48 -33
- package/types/4sh-ui-kit-forms-ui-rating.d.ts +120 -86
- package/types/4sh-ui-kit-forms-ui-segment-control.d.ts +221 -147
- package/types/4sh-ui-kit-forms-ui-select.d.ts +561 -357
- package/types/4sh-ui-kit-forms-ui-slider.d.ts +156 -105
- package/types/4sh-ui-kit-forms-ui-swatch-picker.d.ts +133 -97
- package/types/4sh-ui-kit-forms-ui-textarea.d.ts +90 -54
- package/types/4sh-ui-kit-forms-ui-toggle-block.d.ts +158 -94
- package/types/4sh-ui-kit-forms-ui-toggle-button.d.ts +314 -178
- package/types/4sh-ui-kit-forms-ui-toggle.d.ts +88 -54
- package/types/4sh-ui-kit-forms.d.ts +291 -186
- package/types/4sh-ui-kit-informative-ui-accordion.d.ts +162 -92
- package/types/4sh-ui-kit-informative-ui-alert.d.ts +128 -62
- package/types/4sh-ui-kit-informative-ui-avatar-group.d.ts +8 -8
- package/types/4sh-ui-kit-informative-ui-avatar.d.ts +81 -44
- package/types/4sh-ui-kit-informative-ui-badge.d.ts +71 -41
- package/types/4sh-ui-kit-informative-ui-chip.d.ts +194 -99
- package/types/4sh-ui-kit-informative-ui-empty-state.d.ts +105 -65
- package/types/4sh-ui-kit-informative-ui-helper.d.ts +64 -34
- package/types/4sh-ui-kit-informative-ui-progress-bar.d.ts +120 -65
- package/types/4sh-ui-kit-informative-ui-read-only.d.ts +147 -67
- package/types/4sh-ui-kit-informative-ui-separator.d.ts +65 -35
- package/types/4sh-ui-kit-informative-ui-skeleton.d.ts +62 -32
- package/types/4sh-ui-kit-informative-ui-spinner.d.ts +111 -50
- package/types/4sh-ui-kit-informative-ui-tag.d.ts +77 -37
- package/types/4sh-ui-kit-informative-ui-toast.d.ts +300 -180
- package/types/4sh-ui-kit-informative-ui-tooltip.d.ts +269 -141
- package/types/4sh-ui-kit-layout-ui-bottom-sheet.d.ts +360 -221
- package/types/4sh-ui-kit-layout-ui-card.d.ts +119 -79
- package/types/4sh-ui-kit-layout-ui-drawer.d.ts +244 -120
- package/types/4sh-ui-kit-layout-ui-modal.d.ts +409 -222
- package/types/4sh-ui-kit-layout-ui-popover.d.ts +149 -91
- package/types/4sh-ui-kit-motion.d.ts +117 -67
- package/types/4sh-ui-kit-navigation-ui-bottom-tab-bar.d.ts +279 -145
- package/types/4sh-ui-kit-navigation-ui-breadcrumb.d.ts +134 -96
- package/types/4sh-ui-kit-navigation-ui-context-menu.d.ts +148 -89
- package/types/4sh-ui-kit-navigation-ui-menu.d.ts +282 -201
- package/types/4sh-ui-kit-navigation-ui-sidebar.d.ts +425 -261
- package/types/4sh-ui-kit-navigation-ui-stepper.d.ts +279 -183
- package/types/4sh-ui-kit-navigation-ui-tabs.d.ts +275 -173
- package/types/4sh-ui-kit-overlay.d.ts +6 -6
- package/types/4sh-ui-kit-ripple.d.ts +99 -74
- package/types/4sh-ui-kit-table-ui-paginator.d.ts +237 -133
- package/types/4sh-ui-kit-table-ui-table.d.ts +769 -470
- package/types/4sh-ui-kit-theming.d.ts +27 -29
- package/types/4sh-ui-kit-types.d.ts +6 -5
- package/types/4sh-ui-kit.d.ts +4 -3
- package/fesm2022/4sh-ui-kit-types.mjs.map +0 -1
|
@@ -1,439 +1,754 @@
|
|
|
1
|
-
import * as i0 from
|
|
2
|
-
import {
|
|
3
|
-
import { DOCUMENT, NgTemplateOutlet } from
|
|
4
|
-
import { RouterLink } from
|
|
5
|
-
import { UiButton } from
|
|
6
|
-
import { UiTooltip } from
|
|
7
|
-
import { closeOnNavigation } from
|
|
8
|
-
import { UiMotion } from
|
|
9
|
-
|
|
10
|
-
/** Process-wide unique id source (aria wiring). */
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
import { Component, ElementRef, afterNextRender, booleanAttribute, computed, effect, inject, input, model, numberAttribute, output, signal, viewChild, viewChildren } from "@angular/core";
|
|
3
|
+
import { DOCUMENT, NgTemplateOutlet } from "@angular/common";
|
|
4
|
+
import { RouterLink } from "@angular/router";
|
|
5
|
+
import { UiButton } from "@4sh/ui-kit/actions/ui-button";
|
|
6
|
+
import { UiTooltip } from "@4sh/ui-kit/informative/ui-tooltip";
|
|
7
|
+
import { closeOnNavigation } from "@4sh/ui-kit/overlay";
|
|
8
|
+
import { UiMotion } from "@4sh/ui-kit/motion";
|
|
11
9
|
let nextUid = 0;
|
|
12
|
-
/** @ignore Rounds away floating point noise CSS `calc()` cannot parse (see `arcTransform`). */
|
|
13
10
|
function round(value) {
|
|
14
|
-
|
|
11
|
+
return Math.round(value * 1e6) / 1e6;
|
|
15
12
|
}
|
|
16
|
-
/**
|
|
17
|
-
* @ignore Angular span an arc-type dial occupies, in degrees clockwise from
|
|
18
|
-
* top (0° = up, 90° = right, 180° = down, 270° = left — the same convention
|
|
19
|
-
* `arcTransform` reads it back with).
|
|
20
|
-
*
|
|
21
|
-
* `circle` ignores `direction`: a full ring has no "side". `semi-circle`
|
|
22
|
-
* centres its 180° half on `direction`. `quarter-circle` fills the 90°
|
|
23
|
-
* quadrant named by `direction`'s corner, defaulting to `up-right` for a
|
|
24
|
-
* cardinal value (`quarter-circle` has no "up" of its own — only corners).
|
|
25
|
-
*/
|
|
26
13
|
function arcSpan(type, direction) {
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
* while open (`@if`) — closed actions are neither rendered nor reachable by
|
|
50
|
-
* keyboard, so no `aria-hidden`/`inert` bookkeeping is needed. Escape closes
|
|
51
|
-
* and returns focus to the trigger; `hideOnClickOutside` dismisses on an
|
|
52
|
-
* outside click. The actions form **one tab stop** (roving tabindex, same
|
|
53
|
-
* pattern as `ui-menu` / `ui-editor`'s toolbar): arrow keys move between
|
|
54
|
-
* them, `Home`/`End` jump to the ends, disabled entries are skipped.
|
|
55
|
-
*
|
|
56
|
-
* The trigger and every action are `ui-button` instances (`rounded
|
|
57
|
-
* iconOnly`) — colors come from the `actions.*` tokens, nothing is drawn by
|
|
58
|
-
* hand. `mask` dims the page behind the open dial (`--primitives-black-50`,
|
|
59
|
-
* the same token as `ui-modal`'s scrim).
|
|
60
|
-
*
|
|
61
|
-
* Positioning is left to the caller: the component does not assume a fixed
|
|
62
|
-
* corner. Wrap it in a `position: fixed` host (see the MDX "Bouton flottant"
|
|
63
|
-
* recipe) to reproduce the classic floating-action-button placement.
|
|
64
|
-
*/
|
|
65
|
-
class UiSpeedDial {
|
|
66
|
-
constructor() {
|
|
67
|
-
/** Actions revealed by the dial (see {@link UiSpeedDialItem}). */
|
|
68
|
-
this.items = input.required(/* @ts-ignore */
|
|
69
|
-
...(ngDevMode ? [{ debugName: "items" }] : /* istanbul ignore next */ []));
|
|
70
|
-
/** Open state (two-way). */
|
|
71
|
-
this.visible = model(false, /* @ts-ignore */
|
|
72
|
-
...(ngDevMode ? [{ debugName: "visible" }] : /* istanbul ignore next */ []));
|
|
73
|
-
/** Layout: `linear` (stacked), `circle` (ring), `semi-circle` or `quarter-circle` (arc). */
|
|
74
|
-
this.type = input('linear', /* @ts-ignore */
|
|
75
|
-
...(ngDevMode ? [{ debugName: "type" }] : /* istanbul ignore next */ []));
|
|
76
|
-
/**
|
|
77
|
-
* Axis the actions fan along. `linear`/`semi-circle` read the four
|
|
78
|
-
* cardinal values; `quarter-circle` reads the four corners. Unused by
|
|
79
|
-
* `circle`, which always goes full ring.
|
|
80
|
-
*/
|
|
81
|
-
this.direction = input('up', /* @ts-ignore */
|
|
82
|
-
...(ngDevMode ? [{ debugName: "direction" }] : /* istanbul ignore next */ []));
|
|
83
|
-
/** Ring/arc radius in px — every type but `linear`. Falls back to a size-derived default. */
|
|
84
|
-
this.radius = input(/* @ts-ignore */
|
|
85
|
-
...(ngDevMode ? [undefined, { debugName: "radius" }] : /* istanbul ignore next */ []));
|
|
86
|
-
/** Semantic level of the trigger. */
|
|
87
|
-
this.level = input('high', /* @ts-ignore */
|
|
88
|
-
...(ngDevMode ? [{ debugName: "level" }] : /* istanbul ignore next */ []));
|
|
89
|
-
/**
|
|
90
|
-
* Semantic level of the actions. Defaults to `low`, deliberately different
|
|
91
|
-
* from the trigger's own `level`: a `high`-styled action would read as a
|
|
92
|
-
* second primary button rather than a revealed option.
|
|
93
|
-
*/
|
|
94
|
-
this.itemLevel = input('low', /* @ts-ignore */
|
|
95
|
-
...(ngDevMode ? [{ debugName: "itemLevel" }] : /* istanbul ignore next */ []));
|
|
96
|
-
/** Apparence of the trigger and the actions. */
|
|
97
|
-
this.variant = input('filled', /* @ts-ignore */
|
|
98
|
-
...(ngDevMode ? [{ debugName: "variant" }] : /* istanbul ignore next */ []));
|
|
99
|
-
/** Size of the trigger and the actions. */
|
|
100
|
-
this.size = input('default', /* @ts-ignore */
|
|
101
|
-
...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
102
|
-
/** Icon of the trigger while closed. */
|
|
103
|
-
this.showIcon = input('plus', /* @ts-ignore */
|
|
104
|
-
...(ngDevMode ? [{ debugName: "showIcon" }] : /* istanbul ignore next */ []));
|
|
105
|
-
/**
|
|
106
|
-
* Icon of the trigger while open. Left unset, `showIcon` rotates 45° in
|
|
107
|
-
* place instead of being swapped for a second icon.
|
|
108
|
-
*/
|
|
109
|
-
this.hideIcon = input(/* @ts-ignore */
|
|
110
|
-
...(ngDevMode ? [undefined, { debugName: "hideIcon" }] : /* istanbul ignore next */ []));
|
|
111
|
-
/** Animates the trigger icon's rotation (`hideIcon` unset only). */
|
|
112
|
-
this.rotateAnimation = input(true, { ...(ngDevMode ? { debugName: "rotateAnimation" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
113
|
-
/** Dims the page behind the dial while open. */
|
|
114
|
-
this.mask = input(false, { ...(ngDevMode ? { debugName: "mask" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
115
|
-
/** Closes the dial on an outside click. */
|
|
116
|
-
this.hideOnClickOutside = input(true, { ...(ngDevMode ? { debugName: "hideOnClickOutside" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
117
|
-
/** Disables the trigger and every action. */
|
|
118
|
-
this.disabled = input(false, { ...(ngDevMode ? { debugName: "disabled" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
119
|
-
/** Shows each action's label as a tooltip (icon-only actions). */
|
|
120
|
-
this.showTooltips = input(false, { ...(ngDevMode ? { debugName: "showTooltips" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
121
|
-
/** Animates the trigger and the actions (reduced-motion always wins). */
|
|
122
|
-
this.motion = input(true, { ...(ngDevMode ? { debugName: "motion" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
123
|
-
/** Accessible name of the trigger. */
|
|
124
|
-
this.ariaLabel = input(/* @ts-ignore */
|
|
125
|
-
...(ngDevMode ? [undefined, { debugName: "ariaLabel" }] : /* istanbul ignore next */ []));
|
|
126
|
-
/** id of an external element naming the trigger. */
|
|
127
|
-
this.ariaLabelledBy = input(/* @ts-ignore */
|
|
128
|
-
...(ngDevMode ? [undefined, { debugName: "ariaLabelledBy" }] : /* istanbul ignore next */ []));
|
|
129
|
-
/** Native tabindex of the trigger. */
|
|
130
|
-
this.tabindex = input(0, { ...(ngDevMode ? { debugName: "tabindex" } : /* istanbul ignore next */ {}), transform: numberAttribute });
|
|
131
|
-
/** Fired when the trigger is clicked (never when disabled). */
|
|
132
|
-
this.triggerClick = output();
|
|
133
|
-
/** Fired when the dial opens. */
|
|
134
|
-
this.opened = output();
|
|
135
|
-
/** Fired when the dial closes. */
|
|
136
|
-
this.closed = output();
|
|
137
|
-
/** Fired when an action is activated (click / keyboard), never when disabled. */
|
|
138
|
-
this.itemClick = output();
|
|
139
|
-
/** @ignore */
|
|
140
|
-
this.document = inject(DOCUMENT);
|
|
141
|
-
/** @ignore Host element — outside-click detection. */
|
|
142
|
-
this.hostEl = inject((ElementRef));
|
|
143
|
-
/** @ignore Trigger button (programmatic focus). */
|
|
144
|
-
this.triggerEl = viewChild('trigger', /* @ts-ignore */
|
|
145
|
-
...(ngDevMode ? [{ debugName: "triggerEl" }] : /* istanbul ignore next */ []));
|
|
146
|
-
/** @ignore Rendered action buttons, in DOM order — the roving tabindex ring.
|
|
147
|
-
* Matched by their own `#actionBtn` ref so the trigger (`#trigger`) is excluded. */
|
|
148
|
-
this.actionEls = viewChildren('actionBtn', /* @ts-ignore */
|
|
149
|
-
...(ngDevMode ? [{ debugName: "actionEls" }] : /* istanbul ignore next */ []));
|
|
150
|
-
/** Unique id of the actions list (wired to the trigger's `aria-controls`). */
|
|
151
|
-
this.uid = `ui-speed-dial-${nextUid++}`;
|
|
152
|
-
/** @ignore Key of the action currently holding the roving tab stop. */
|
|
153
|
-
this.focusedKey = signal(null, /* @ts-ignore */
|
|
154
|
-
...(ngDevMode ? [{ debugName: "focusedKey" }] : /* istanbul ignore next */ []));
|
|
155
|
-
/** @ignore Enabled actions, keyed for the roving tabindex + trigonometry. */
|
|
156
|
-
this.nodes = computed(() => this.items().map((item, index) => ({ item, key: item.id ?? `${this.uid}_${index}`, index })), /* @ts-ignore */
|
|
157
|
-
...(ngDevMode ? [{ debugName: "nodes" }] : /* istanbul ignore next */ []));
|
|
158
|
-
/** @ignore Keys of the enabled entries, in order (roving focus path). */
|
|
159
|
-
this.focusableKeys = computed(() => this.nodes()
|
|
160
|
-
.filter((n) => !n.item.disabled)
|
|
161
|
-
.map((n) => n.key), /* @ts-ignore */
|
|
162
|
-
...(ngDevMode ? [{ debugName: "focusableKeys" }] : /* istanbul ignore next */ []));
|
|
163
|
-
/** @ignore Node owning the tab stop: last focused, else the first enabled one. */
|
|
164
|
-
this.tabStopKey = computed(() => {
|
|
165
|
-
const keys = this.focusableKeys();
|
|
166
|
-
const focused = this.focusedKey();
|
|
167
|
-
return focused && keys.includes(focused) ? focused : (keys[0] ?? null);
|
|
168
|
-
}, /* @ts-ignore */
|
|
169
|
-
...(ngDevMode ? [{ debugName: "tabStopKey" }] : /* istanbul ignore next */ []));
|
|
170
|
-
/**
|
|
171
|
-
* @ignore Explicit ring radius, in px — set as the `--_radius` override.
|
|
172
|
-
* Left unset (`null`, no inline style), the SCSS default takes over.
|
|
173
|
-
*/
|
|
174
|
-
this.radiusOverride = computed(() => {
|
|
175
|
-
const r = this.radius();
|
|
176
|
-
return r != null ? `${r}px` : null;
|
|
177
|
-
}, /* @ts-ignore */
|
|
178
|
-
...(ngDevMode ? [{ debugName: "radiusOverride" }] : /* istanbul ignore next */ []));
|
|
179
|
-
/**
|
|
180
|
-
* @ignore Per-item position on an arc (`circle`/`semi-circle`/
|
|
181
|
-
* `quarter-circle`): self-centred on the trigger, `--_radius` out at its
|
|
182
|
-
* angular slot (see `radiusOverride` for the explicit/default split).
|
|
183
|
-
*
|
|
184
|
-
* `circle` steps evenly around the FULL span (`span / total`, wrapping);
|
|
185
|
-
* the other two divide by `total - 1` so the first and last actions land
|
|
186
|
-
* exactly on the arc's own ends, not short of them.
|
|
187
|
-
*/
|
|
188
|
-
this.arcTransform = computed(() => {
|
|
189
|
-
const type = this.type();
|
|
190
|
-
const total = this.nodes().length;
|
|
191
|
-
if (type === 'linear' || !total)
|
|
192
|
-
return () => null;
|
|
193
|
-
const { start, span } = arcSpan(type, this.direction());
|
|
194
|
-
const step = type === 'circle' ? span / total : span / Math.max(total - 1, 1);
|
|
195
|
-
return (index) => {
|
|
196
|
-
const angle = ((start + step * index) * Math.PI) / 180;
|
|
197
|
-
// Floating point noise (e.g. sin(π) ≈ 1.2e-16) prints as exponential
|
|
198
|
-
// notation, which CSS `calc()` cannot parse — round it away.
|
|
199
|
-
const x = round(Math.sin(angle));
|
|
200
|
-
const y = round(-Math.cos(angle));
|
|
201
|
-
return `translate(-50%, -50%) translate(calc(${x} * var(--_radius)), calc(${y} * var(--_radius)))`;
|
|
202
|
-
};
|
|
203
|
-
}, /* @ts-ignore */
|
|
204
|
-
...(ngDevMode ? [{ debugName: "arcTransform" }] : /* istanbul ignore next */ []));
|
|
205
|
-
/**
|
|
206
|
-
* @ignore Enter/leave preset.
|
|
207
|
-
*
|
|
208
|
-
* Arc items (`circle`/`semi-circle`/`quarter-circle`) already carry their
|
|
209
|
-
* own `[style.transform]` (angular position, `arcTransform`) —
|
|
210
|
-
* `zoom`/`slide-*` animate `transform` too, and a CSS animation on a
|
|
211
|
-
* property wins over an inline style for it, wiping the position out for
|
|
212
|
-
* the animation's duration. `fade` (opacity only) is the one preset that
|
|
213
|
-
* cannot collide with it.
|
|
214
|
-
*
|
|
215
|
-
* `linear` items carry no such transform, so they get the more expressive
|
|
216
|
-
* `slide-${direction}` — "enter moving toward `direction`".
|
|
217
|
-
*/
|
|
218
|
-
this.itemMotionPreset = computed(() => {
|
|
219
|
-
if (this.type() !== 'linear')
|
|
220
|
-
return 'fade';
|
|
221
|
-
// `linear` only means a cardinal direction; a corner value (meant for
|
|
222
|
-
// `quarter-circle`) has no matching slide preset — fall back to 'up'.
|
|
223
|
-
const d = this.direction();
|
|
224
|
-
return (d === 'up' || d === 'down' || d === 'left' || d === 'right' ? `slide-${d}` : 'slide-up');
|
|
225
|
-
}, /* @ts-ignore */
|
|
226
|
-
...(ngDevMode ? [{ debugName: "itemMotionPreset" }] : /* istanbul ignore next */ []));
|
|
227
|
-
/** @ignore Trigger icon while open: `hideIcon`, or `showIcon` rotated in place. */
|
|
228
|
-
this.triggerIcon = computed(() => this.hideIcon() ?? this.showIcon(), /* @ts-ignore */
|
|
229
|
-
...(ngDevMode ? [{ debugName: "triggerIcon" }] : /* istanbul ignore next */ []));
|
|
230
|
-
/** @ignore The trigger icon rotates only when there is no dedicated `hideIcon`. */
|
|
231
|
-
this.triggerIconRotates = computed(() => this.visible() && !this.hideIcon() && this.rotateAnimation(), /* @ts-ignore */
|
|
232
|
-
...(ngDevMode ? [{ debugName: "triggerIconRotates" }] : /* istanbul ignore next */ []));
|
|
233
|
-
/** @ignore Tooltip side: opposite the fan-out direction, so it never overlaps an action. */
|
|
234
|
-
this.tooltipPosition = computed(() => {
|
|
235
|
-
if (this.type() !== 'linear')
|
|
236
|
-
return 'top';
|
|
237
|
-
const d = this.direction();
|
|
238
|
-
if (d === 'up')
|
|
239
|
-
return 'right';
|
|
240
|
-
if (d === 'down')
|
|
241
|
-
return 'right';
|
|
242
|
-
if (d === 'left')
|
|
243
|
-
return 'top';
|
|
244
|
-
return 'top';
|
|
245
|
-
}, /* @ts-ignore */
|
|
246
|
-
...(ngDevMode ? [{ debugName: "tooltipPosition" }] : /* istanbul ignore next */ []));
|
|
247
|
-
/**
|
|
248
|
-
* @ignore Attributes forwarded onto the trigger's real `<button>`/`<a>`
|
|
249
|
-
* (`ui-button`'s `#host`, not the `<ui-speed-dial>` wrapper): `role`,
|
|
250
|
-
* `ariaLabel` and `tabindex` already have dedicated `ui-button` inputs, the
|
|
251
|
-
* rest goes through `buttonProps` (see `ui-button`'s own forwarding).
|
|
252
|
-
*/
|
|
253
|
-
this.triggerProps = computed(() => ({
|
|
254
|
-
'aria-haspopup': 'true',
|
|
255
|
-
'aria-expanded': this.visible() ? 'true' : 'false',
|
|
256
|
-
'aria-controls': this.uid,
|
|
257
|
-
'aria-labelledby': this.ariaLabelledBy() ?? null,
|
|
258
|
-
}), /* @ts-ignore */
|
|
259
|
-
...(ngDevMode ? [{ debugName: "triggerProps" }] : /* istanbul ignore next */ []));
|
|
260
|
-
/** @ignore Static: every action is a `menuitem`, whatever it renders as (button/link). */
|
|
261
|
-
this.itemProps = { role: 'menuitem' };
|
|
262
|
-
/** @ignore */
|
|
263
|
-
this.hostClasses = computed(() => {
|
|
264
|
-
const c = ['ui-speed-dial', `_${this.type()}`];
|
|
265
|
-
if (this.type() === 'linear')
|
|
266
|
-
c.push(`_${this.direction()}`);
|
|
267
|
-
if (this.size() !== 'default')
|
|
268
|
-
c.push(`_${this.size()}`);
|
|
269
|
-
if (this.visible())
|
|
270
|
-
c.push('_open');
|
|
271
|
-
return c.join(' ');
|
|
272
|
-
}, /* @ts-ignore */
|
|
273
|
-
...(ngDevMode ? [{ debugName: "hostClasses" }] : /* istanbul ignore next */ []));
|
|
274
|
-
// A dial declared in an app shell (header, sidebar) outlives the routed
|
|
275
|
-
// view: close it rather than leaving it open over the next page.
|
|
276
|
-
//
|
|
277
|
-
// Deferred one frame (`afterNextRender`, not the constructor directly): a
|
|
278
|
-
// dial that starts open (`[visible]="true"`, e.g. this very Storybook
|
|
279
|
-
// canvas) races the router's OWN initial navigation — that first
|
|
280
|
-
// `NavigationStart` can still fire after this component exists but
|
|
281
|
-
// before `router.url` has settled, which `closeOnNavigation` would then
|
|
282
|
-
// read as "the page changed" and close a dial that never got a chance to
|
|
283
|
-
// be seen open. One frame is enough for that bootstrap navigation to
|
|
284
|
-
// resolve, and `closeOnNavigation`'s own job (dismiss on a LATER, real
|
|
285
|
-
// navigation) is not time-critical to wire up before then.
|
|
286
|
-
afterNextRender(() => closeOnNavigation(() => this.hide()));
|
|
287
|
-
// Outside-click dismissal: attached only while open, torn down on close —
|
|
288
|
-
// a document-wide listener has no reason to exist while nothing is open.
|
|
289
|
-
effect((onCleanup) => {
|
|
290
|
-
if (!this.visible())
|
|
291
|
-
return;
|
|
292
|
-
const handler = (event) => this.onDocumentPointerdown(event);
|
|
293
|
-
this.document.addEventListener('pointerdown', handler, true);
|
|
294
|
-
onCleanup(() => this.document.removeEventListener('pointerdown', handler, true));
|
|
295
|
-
});
|
|
296
|
-
}
|
|
297
|
-
/** Opens the dial. */
|
|
298
|
-
show() {
|
|
299
|
-
if (this.disabled() || this.visible())
|
|
300
|
-
return;
|
|
301
|
-
this.visible.set(true);
|
|
302
|
-
this.opened.emit();
|
|
303
|
-
}
|
|
304
|
-
/** Closes the dial. */
|
|
305
|
-
hide(focusTrigger = false) {
|
|
306
|
-
if (!this.visible())
|
|
307
|
-
return;
|
|
308
|
-
this.visible.set(false);
|
|
309
|
-
this.focusedKey.set(null);
|
|
310
|
-
this.closed.emit();
|
|
311
|
-
if (focusTrigger)
|
|
312
|
-
this.triggerEl()?.focus();
|
|
313
|
-
}
|
|
314
|
-
/** Toggles the dial open/closed. */
|
|
315
|
-
toggle() {
|
|
316
|
-
this.visible() ? this.hide() : this.show();
|
|
317
|
-
}
|
|
318
|
-
/** Moves focus onto the trigger. */
|
|
319
|
-
focus(options) {
|
|
320
|
-
this.triggerEl()?.focus(options);
|
|
321
|
-
}
|
|
322
|
-
/** @ignore */
|
|
323
|
-
onTriggerClick(event) {
|
|
324
|
-
if (this.disabled())
|
|
325
|
-
return;
|
|
326
|
-
this.triggerClick.emit(event);
|
|
327
|
-
this.toggle();
|
|
328
|
-
}
|
|
329
|
-
/** @ignore Arrow key on the (closed) trigger opens the dial onto its first action. */
|
|
330
|
-
onTriggerKeydown(event) {
|
|
331
|
-
if (this.disabled() || this.visible())
|
|
332
|
-
return;
|
|
333
|
-
if (!['ArrowUp', 'ArrowDown', 'ArrowLeft', 'ArrowRight'].includes(event.key))
|
|
334
|
-
return;
|
|
335
|
-
event.preventDefault();
|
|
336
|
-
this.show();
|
|
337
|
-
this.queueFocusTabStop();
|
|
338
|
-
}
|
|
339
|
-
/** @ignore Activation: command + itemClick, then close (never on a disabled entry). */
|
|
340
|
-
onItemClick(event, node) {
|
|
341
|
-
const item = node.item;
|
|
342
|
-
if (item.disabled) {
|
|
343
|
-
event.preventDefault();
|
|
344
|
-
return;
|
|
345
|
-
}
|
|
346
|
-
if (!item.url && !item.routerLink)
|
|
347
|
-
event.preventDefault();
|
|
348
|
-
this.focusedKey.set(node.key);
|
|
349
|
-
item.command?.({ originalEvent: event, item });
|
|
350
|
-
this.itemClick.emit({ originalEvent: event, item });
|
|
351
|
-
this.hide(true);
|
|
352
|
-
}
|
|
353
|
-
/**
|
|
354
|
-
* @ignore Roving keyboard navigation among the open actions.
|
|
355
|
-
*
|
|
356
|
-
* Both arrow pairs move the same way regardless of `direction`/`type`: it
|
|
357
|
-
* keeps the mapping simple and predictable rather than re-deriving which
|
|
358
|
-
* pair means "forward" for eight possible linear/circular layouts.
|
|
359
|
-
*/
|
|
360
|
-
onListKeydown(event) {
|
|
361
|
-
const keys = this.focusableKeys();
|
|
362
|
-
if (!keys.length)
|
|
363
|
-
return;
|
|
364
|
-
const current = this.focusedKey();
|
|
365
|
-
const index = current ? keys.indexOf(current) : -1;
|
|
366
|
-
switch (event.key) {
|
|
367
|
-
case 'ArrowUp':
|
|
368
|
-
case 'ArrowRight':
|
|
369
|
-
event.preventDefault();
|
|
370
|
-
this.focusByKey(keys[(index + 1) % keys.length]);
|
|
371
|
-
break;
|
|
372
|
-
case 'ArrowDown':
|
|
373
|
-
case 'ArrowLeft':
|
|
374
|
-
event.preventDefault();
|
|
375
|
-
this.focusByKey(keys[(index - 1 + keys.length) % keys.length]);
|
|
376
|
-
break;
|
|
377
|
-
case 'Home':
|
|
378
|
-
event.preventDefault();
|
|
379
|
-
this.focusByKey(keys[0]);
|
|
380
|
-
break;
|
|
381
|
-
case 'End':
|
|
382
|
-
event.preventDefault();
|
|
383
|
-
this.focusByKey(keys[keys.length - 1]);
|
|
384
|
-
break;
|
|
385
|
-
case 'Escape':
|
|
386
|
-
event.preventDefault();
|
|
387
|
-
this.hide(true);
|
|
388
|
-
break;
|
|
389
|
-
}
|
|
390
|
-
}
|
|
391
|
-
/** @ignore */
|
|
392
|
-
onEntryFocus(key) {
|
|
393
|
-
this.focusedKey.set(key);
|
|
394
|
-
}
|
|
395
|
-
/** @ignore Outside pointerdown closes the dial (mousedown mirrors ui-menu's own outside-click). */
|
|
396
|
-
onDocumentPointerdown(event) {
|
|
397
|
-
if (!this.visible() || !this.hideOnClickOutside())
|
|
398
|
-
return;
|
|
399
|
-
if (event.target instanceof Node && this.hostEl.nativeElement.contains(event.target))
|
|
400
|
-
return;
|
|
401
|
-
this.hide();
|
|
402
|
-
}
|
|
403
|
-
/** @ignore Clicking the mask itself closes the dial. */
|
|
404
|
-
onMaskClick() {
|
|
405
|
-
this.hide();
|
|
406
|
-
}
|
|
407
|
-
/** @ignore */
|
|
408
|
-
focusByKey(key) {
|
|
409
|
-
if (!key)
|
|
410
|
-
return;
|
|
411
|
-
this.focusedKey.set(key);
|
|
412
|
-
const target = this.nodes().find((n) => n.key === key);
|
|
413
|
-
if (!target)
|
|
414
|
-
return;
|
|
415
|
-
this.actionEls()[target.index]?.focus();
|
|
416
|
-
}
|
|
417
|
-
/** @ignore Focus the roving tab stop once the actions are rendered (macrotask: rAF
|
|
418
|
-
* never fires in throttled/background tabs). */
|
|
419
|
-
queueFocusTabStop() {
|
|
420
|
-
setTimeout(() => this.focusByKey(this.tabStopKey() ?? undefined));
|
|
421
|
-
}
|
|
422
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: UiSpeedDial, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
423
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.7", type: UiSpeedDial, isStandalone: true, selector: "ui-speed-dial", inputs: { items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: true, transformFunction: null }, visible: { classPropertyName: "visible", publicName: "visible", isSignal: true, isRequired: false, transformFunction: null }, type: { classPropertyName: "type", publicName: "type", isSignal: true, isRequired: false, transformFunction: null }, direction: { classPropertyName: "direction", publicName: "direction", isSignal: true, isRequired: false, transformFunction: null }, radius: { classPropertyName: "radius", publicName: "radius", isSignal: true, isRequired: false, transformFunction: null }, level: { classPropertyName: "level", publicName: "level", isSignal: true, isRequired: false, transformFunction: null }, itemLevel: { classPropertyName: "itemLevel", publicName: "itemLevel", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, showIcon: { classPropertyName: "showIcon", publicName: "showIcon", isSignal: true, isRequired: false, transformFunction: null }, hideIcon: { classPropertyName: "hideIcon", publicName: "hideIcon", isSignal: true, isRequired: false, transformFunction: null }, rotateAnimation: { classPropertyName: "rotateAnimation", publicName: "rotateAnimation", isSignal: true, isRequired: false, transformFunction: null }, mask: { classPropertyName: "mask", publicName: "mask", isSignal: true, isRequired: false, transformFunction: null }, hideOnClickOutside: { classPropertyName: "hideOnClickOutside", publicName: "hideOnClickOutside", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, showTooltips: { classPropertyName: "showTooltips", publicName: "showTooltips", isSignal: true, isRequired: false, transformFunction: null }, motion: { classPropertyName: "motion", publicName: "motion", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, ariaLabelledBy: { classPropertyName: "ariaLabelledBy", publicName: "ariaLabelledBy", isSignal: true, isRequired: false, transformFunction: null }, tabindex: { classPropertyName: "tabindex", publicName: "tabindex", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { visible: "visibleChange", triggerClick: "triggerClick", opened: "opened", closed: "closed", itemClick: "itemClick" }, viewQueries: [{ propertyName: "triggerEl", first: true, predicate: ["trigger"], descendants: true, isSignal: true }, { propertyName: "actionEls", predicate: ["actionBtn"], descendants: true, isSignal: true }], ngImport: i0, template: "<div [class]=\"hostClasses()\" [style.--_radius]=\"radiusOverride()\">\n @if (mask() && visible()) {\n <div\n class=\"ui-speed-dial-mask\"\n [uiMotion]=\"'fade'\"\n [motionDisabled]=\"!motion()\"\n #maskMotion=\"uiMotion\"\n [animate.enter]=\"maskMotion.enter()\"\n [animate.leave]=\"maskMotion.leave()\"\n (click)=\"onMaskClick()\"\n aria-hidden=\"true\"\n ></div>\n }\n\n <ui-button\n #trigger\n class=\"ui-speed-dial-trigger\"\n [class._rotate]=\"triggerIconRotates()\"\n rounded\n iconOnly\n [level]=\"level()\"\n [variant]=\"variant()\"\n [size]=\"size()\"\n [icon]=\"triggerIcon()\"\n [ariaLabel]=\"ariaLabel()\"\n [disabled]=\"disabled()\"\n [tabindex]=\"tabindex()\"\n [buttonProps]=\"triggerProps()\"\n (buttonClick)=\"onTriggerClick($event)\"\n (keydown)=\"onTriggerKeydown($event)\"\n />\n\n @if (visible()) {\n <!-- ARIA menu pattern: keyboard delegated to the role=\"menu\" container,\n focus lives on the items (roving tabindex), same as ui-menu. -->\n <!-- eslint-disable-next-line @angular-eslint/template/interactive-supports-focus -->\n <div\n class=\"ui-speed-dial-list\"\n [id]=\"uid\"\n role=\"menu\"\n [attr.aria-label]=\"ariaLabel() || null\"\n (keydown)=\"onListKeydown($event)\"\n >\n @for (node of nodes(); track node.key) {\n <ui-button\n #actionBtn\n class=\"ui-speed-dial-item\"\n [style.--_stagger-index]=\"node.index\"\n [style.transform]=\"type() !== 'linear' ? arcTransform()(node.index) : null\"\n [uiMotion]=\"itemMotionPreset()\"\n [motionDisabled]=\"!motion()\"\n #itemMotion=\"uiMotion\"\n [animate.enter]=\"itemMotion.enter()\"\n [animate.leave]=\"itemMotion.leave()\"\n rounded\n iconOnly\n [level]=\"itemLevel()\"\n [variant]=\"variant()\"\n size=\"small\"\n [icon]=\"node.item.icon\"\n [ariaLabel]=\"node.item.ariaLabel || node.item.label\"\n [disabled]=\"node.item.disabled\"\n [href]=\"node.item.url\"\n [routerLink]=\"node.item.routerLink\"\n [target]=\"node.item.target\"\n [tabindex]=\"node.key === tabStopKey() ? 0 : -1\"\n [buttonProps]=\"itemProps\"\n [uiTooltip]=\"showTooltips() ? node.item.ariaLabel || node.item.label : undefined\"\n [tooltipPosition]=\"tooltipPosition()\"\n (buttonClick)=\"onItemClick($event, node)\"\n (focus)=\"onEntryFocus(node.key)\"\n />\n }\n </div>\n }\n</div>\n", styles: [".ui-speed-dial{position:relative;display:inline-flex;z-index:var(--ui-speed-dial-z-index, 10);--_radius: var(--ui-speed-dial-radius, calc(2 * var(--size-components-default)))}.ui-speed-dial-mask{position:fixed;inset:0;background-color:var(--ui-speed-dial-mask-background, var(--primitives-black-50))}.ui-speed-dial-trigger{position:relative}.ui-speed-dial-trigger ::ng-deep .ui-button-icon{transition:rotate var(--ui-control-transition-duration, var(--motion-toggle-duration, var(--transition-default))) var(--ui-control-transition-easing, var(--motion-toggle-easing, var(--transition-easeinout)))}.ui-speed-dial-trigger._rotate ::ng-deep .ui-button-icon{rotate:45deg}.ui-speed-dial-list{position:absolute;display:flex;gap:var(--ui-speed-dial-item-gap, var(--units-sm));margin:0;padding:0;list-style:none;pointer-events:none}.ui-speed-dial._up .ui-speed-dial-list{bottom:calc(100% + var(--ui-speed-dial-item-gap, var(--units-sm)));left:50%;flex-direction:column-reverse;translate:-50% 0}.ui-speed-dial._down .ui-speed-dial-list{top:calc(100% + var(--ui-speed-dial-item-gap, var(--units-sm)));left:50%;flex-direction:column;translate:-50% 0}.ui-speed-dial._left .ui-speed-dial-list{right:calc(100% + var(--ui-speed-dial-item-gap, var(--units-sm)));top:50%;flex-direction:row-reverse;translate:0 -50%}.ui-speed-dial._right .ui-speed-dial-list{left:calc(100% + var(--ui-speed-dial-item-gap, var(--units-sm)));top:50%;flex-direction:row;translate:0 -50%}.ui-speed-dial._circle .ui-speed-dial-list,.ui-speed-dial._semi-circle .ui-speed-dial-list,.ui-speed-dial._quarter-circle .ui-speed-dial-list{inset:0}.ui-speed-dial._circle .ui-speed-dial-item,.ui-speed-dial._semi-circle .ui-speed-dial-item,.ui-speed-dial._quarter-circle .ui-speed-dial-item{position:absolute;top:50%;left:50%}.ui-speed-dial-item{pointer-events:auto;--ui-motion-delay: calc(var(--_stagger-index, 0) * var(--ui-speed-dial-item-delay, var(--motion-stagger-delay, var(--transition-fast))))}.ui-speed-dial-item[class*=-leave]{--ui-motion-delay: 0ms}\n"], dependencies: [{ kind: "component", type: UiButton, selector: "ui-button", inputs: ["label", "ariaLabel", "type", "level", "variant", "onColor", "size", "icon", "iconPos", "iconOnly", "loading", "loadingIcon", "expanded", "rounded", "disabled", "ripple", "tabindex", "buttonProps", "iconTemplate", "loadingIconTemplate", "href", "routerLink", "target", "rel"], outputs: ["buttonClick", "buttonFocus", "buttonBlur"] }, { kind: "directive", type: RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "browserUrl", "routerLink"] }, { kind: "directive", type: UiTooltip, selector: "[uiTooltip]", inputs: ["uiTooltip", "tooltipPosition", "fitContent", "tooltipEvent", "tooltipDisabled", "showDelay", "hideDelay", "escape", "tooltipStyleClass", "autoHide", "hideOnEscape", "life", "showOnEllipsis", "positionTop", "positionLeft", "tooltipContext"], outputs: ["tooltipShow", "tooltipHide"], exportAs: ["uiTooltip"] }, { kind: "directive", type: UiMotion, selector: "[uiMotion]", inputs: ["uiMotion", "motionDuration", "motionDelay", "motionEasing", "motionEnterEasing", "motionLeaveEasing", "motionDistance", "motionScale", "motionDisabled", "motionOnInsert"], exportAs: ["uiMotion"] }] }); }
|
|
14
|
+
if (type === "circle") return {
|
|
15
|
+
start: 0,
|
|
16
|
+
span: 360
|
|
17
|
+
};
|
|
18
|
+
if (type === "semi-circle") return {
|
|
19
|
+
start: ({
|
|
20
|
+
up: 0,
|
|
21
|
+
right: 90,
|
|
22
|
+
down: 180,
|
|
23
|
+
left: 270
|
|
24
|
+
}[direction] ?? 0) - 90,
|
|
25
|
+
span: 180
|
|
26
|
+
};
|
|
27
|
+
return {
|
|
28
|
+
start: {
|
|
29
|
+
"up-right": 0,
|
|
30
|
+
"down-right": 90,
|
|
31
|
+
"down-left": 180,
|
|
32
|
+
"up-left": 270
|
|
33
|
+
}[direction] ?? 0,
|
|
34
|
+
span: 90
|
|
35
|
+
};
|
|
424
36
|
}
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
/*
|
|
431
|
-
|
|
432
|
-
*/
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
*/
|
|
437
|
-
|
|
37
|
+
var UiSpeedDial = class UiSpeedDial {
|
|
38
|
+
constructor() {
|
|
39
|
+
this.items = input.required(...ngDevMode ? [{ debugName: "items" }] : /* istanbul ignore next */ []);
|
|
40
|
+
this.visible = model(false, ...ngDevMode ? [{ debugName: "visible" }] : /* istanbul ignore next */ []);
|
|
41
|
+
this.type = input("linear", ...ngDevMode ? [{ debugName: "type" }] : /* istanbul ignore next */ []);
|
|
42
|
+
this.direction = input("up", ...ngDevMode ? [{ debugName: "direction" }] : /* istanbul ignore next */ []);
|
|
43
|
+
this.radius = input(...ngDevMode ? [void 0, { debugName: "radius" }] : /* istanbul ignore next */ []);
|
|
44
|
+
this.level = input("high", ...ngDevMode ? [{ debugName: "level" }] : /* istanbul ignore next */ []);
|
|
45
|
+
this.itemLevel = input("low", ...ngDevMode ? [{ debugName: "itemLevel" }] : /* istanbul ignore next */ []);
|
|
46
|
+
this.variant = input("filled", ...ngDevMode ? [{ debugName: "variant" }] : /* istanbul ignore next */ []);
|
|
47
|
+
this.size = input("default", ...ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []);
|
|
48
|
+
this.showIcon = input("plus", ...ngDevMode ? [{ debugName: "showIcon" }] : /* istanbul ignore next */ []);
|
|
49
|
+
this.hideIcon = input(...ngDevMode ? [void 0, { debugName: "hideIcon" }] : /* istanbul ignore next */ []);
|
|
50
|
+
this.rotateAnimation = input(true, {
|
|
51
|
+
...ngDevMode ? { debugName: "rotateAnimation" } : /* istanbul ignore next */ {},
|
|
52
|
+
transform: booleanAttribute
|
|
53
|
+
});
|
|
54
|
+
this.mask = input(false, {
|
|
55
|
+
...ngDevMode ? { debugName: "mask" } : /* istanbul ignore next */ {},
|
|
56
|
+
transform: booleanAttribute
|
|
57
|
+
});
|
|
58
|
+
this.hideOnClickOutside = input(true, {
|
|
59
|
+
...ngDevMode ? { debugName: "hideOnClickOutside" } : /* istanbul ignore next */ {},
|
|
60
|
+
transform: booleanAttribute
|
|
61
|
+
});
|
|
62
|
+
this.disabled = input(false, {
|
|
63
|
+
...ngDevMode ? { debugName: "disabled" } : /* istanbul ignore next */ {},
|
|
64
|
+
transform: booleanAttribute
|
|
65
|
+
});
|
|
66
|
+
this.showTooltips = input(false, {
|
|
67
|
+
...ngDevMode ? { debugName: "showTooltips" } : /* istanbul ignore next */ {},
|
|
68
|
+
transform: booleanAttribute
|
|
69
|
+
});
|
|
70
|
+
this.motion = input(true, {
|
|
71
|
+
...ngDevMode ? { debugName: "motion" } : /* istanbul ignore next */ {},
|
|
72
|
+
transform: booleanAttribute
|
|
73
|
+
});
|
|
74
|
+
this.ariaLabel = input(...ngDevMode ? [void 0, { debugName: "ariaLabel" }] : /* istanbul ignore next */ []);
|
|
75
|
+
this.ariaLabelledBy = input(...ngDevMode ? [void 0, { debugName: "ariaLabelledBy" }] : /* istanbul ignore next */ []);
|
|
76
|
+
this.tabindex = input(0, {
|
|
77
|
+
...ngDevMode ? { debugName: "tabindex" } : /* istanbul ignore next */ {},
|
|
78
|
+
transform: numberAttribute
|
|
79
|
+
});
|
|
80
|
+
this.triggerClick = output();
|
|
81
|
+
this.opened = output();
|
|
82
|
+
this.closed = output();
|
|
83
|
+
this.itemClick = output();
|
|
84
|
+
this.document = inject(DOCUMENT);
|
|
85
|
+
this.hostEl = inject(ElementRef);
|
|
86
|
+
this.triggerEl = viewChild("trigger", ...ngDevMode ? [{ debugName: "triggerEl" }] : /* istanbul ignore next */ []);
|
|
87
|
+
this.actionEls = viewChildren("actionBtn", ...ngDevMode ? [{ debugName: "actionEls" }] : /* istanbul ignore next */ []);
|
|
88
|
+
this.uid = `ui-speed-dial-${nextUid++}`;
|
|
89
|
+
this.focusedKey = signal(null, ...ngDevMode ? [{ debugName: "focusedKey" }] : /* istanbul ignore next */ []);
|
|
90
|
+
this.nodes = computed(() => this.items().map((item, index) => ({
|
|
91
|
+
item,
|
|
92
|
+
key: item.id ?? `${this.uid}_${index}`,
|
|
93
|
+
index
|
|
94
|
+
})), ...ngDevMode ? [{ debugName: "nodes" }] : /* istanbul ignore next */ []);
|
|
95
|
+
this.focusableKeys = computed(() => this.nodes().filter((n) => !n.item.disabled).map((n) => n.key), ...ngDevMode ? [{ debugName: "focusableKeys" }] : /* istanbul ignore next */ []);
|
|
96
|
+
this.tabStopKey = computed(() => {
|
|
97
|
+
const keys = this.focusableKeys();
|
|
98
|
+
const focused = this.focusedKey();
|
|
99
|
+
return focused && keys.includes(focused) ? focused : keys[0] ?? null;
|
|
100
|
+
}, ...ngDevMode ? [{ debugName: "tabStopKey" }] : /* istanbul ignore next */ []);
|
|
101
|
+
this.radiusOverride = computed(() => {
|
|
102
|
+
const r = this.radius();
|
|
103
|
+
return r != null ? `${r}px` : null;
|
|
104
|
+
}, ...ngDevMode ? [{ debugName: "radiusOverride" }] : /* istanbul ignore next */ []);
|
|
105
|
+
this.arcTransform = computed(() => {
|
|
106
|
+
const type = this.type();
|
|
107
|
+
const total = this.nodes().length;
|
|
108
|
+
if (type === "linear" || !total) return () => null;
|
|
109
|
+
const { start, span } = arcSpan(type, this.direction());
|
|
110
|
+
const step = type === "circle" ? span / total : span / Math.max(total - 1, 1);
|
|
111
|
+
return (index) => {
|
|
112
|
+
const angle = (start + step * index) * Math.PI / 180;
|
|
113
|
+
return `translate(-50%, -50%) translate(calc(${round(Math.sin(angle))} * var(--_radius)), calc(${round(-Math.cos(angle))} * var(--_radius)))`;
|
|
114
|
+
};
|
|
115
|
+
}, ...ngDevMode ? [{ debugName: "arcTransform" }] : /* istanbul ignore next */ []);
|
|
116
|
+
this.itemMotionPreset = computed(() => {
|
|
117
|
+
if (this.type() !== "linear") return "fade";
|
|
118
|
+
const d = this.direction();
|
|
119
|
+
return d === "up" || d === "down" || d === "left" || d === "right" ? `slide-${d}` : "slide-up";
|
|
120
|
+
}, ...ngDevMode ? [{ debugName: "itemMotionPreset" }] : /* istanbul ignore next */ []);
|
|
121
|
+
this.triggerIcon = computed(() => this.hideIcon() ?? this.showIcon(), ...ngDevMode ? [{ debugName: "triggerIcon" }] : /* istanbul ignore next */ []);
|
|
122
|
+
this.triggerIconRotates = computed(() => this.visible() && !this.hideIcon() && this.rotateAnimation(), ...ngDevMode ? [{ debugName: "triggerIconRotates" }] : /* istanbul ignore next */ []);
|
|
123
|
+
this.tooltipPosition = computed(() => {
|
|
124
|
+
if (this.type() !== "linear") return "top";
|
|
125
|
+
const d = this.direction();
|
|
126
|
+
if (d === "up") return "right";
|
|
127
|
+
if (d === "down") return "right";
|
|
128
|
+
if (d === "left") return "top";
|
|
129
|
+
return "top";
|
|
130
|
+
}, ...ngDevMode ? [{ debugName: "tooltipPosition" }] : /* istanbul ignore next */ []);
|
|
131
|
+
this.triggerProps = computed(() => ({
|
|
132
|
+
"aria-haspopup": "true",
|
|
133
|
+
"aria-expanded": this.visible() ? "true" : "false",
|
|
134
|
+
"aria-controls": this.uid,
|
|
135
|
+
"aria-labelledby": this.ariaLabelledBy() ?? null
|
|
136
|
+
}), ...ngDevMode ? [{ debugName: "triggerProps" }] : /* istanbul ignore next */ []);
|
|
137
|
+
this.itemProps = { role: "menuitem" };
|
|
138
|
+
this.hostClasses = computed(() => {
|
|
139
|
+
const c = ["ui-speed-dial", `_${this.type()}`];
|
|
140
|
+
if (this.type() === "linear") c.push(`_${this.direction()}`);
|
|
141
|
+
if (this.size() !== "default") c.push(`_${this.size()}`);
|
|
142
|
+
if (this.visible()) c.push("_open");
|
|
143
|
+
return c.join(" ");
|
|
144
|
+
}, ...ngDevMode ? [{ debugName: "hostClasses" }] : /* istanbul ignore next */ []);
|
|
145
|
+
afterNextRender(() => closeOnNavigation(() => this.hide()));
|
|
146
|
+
effect((onCleanup) => {
|
|
147
|
+
if (!this.visible()) return;
|
|
148
|
+
const handler = (event) => this.onDocumentPointerdown(event);
|
|
149
|
+
this.document.addEventListener("pointerdown", handler, true);
|
|
150
|
+
onCleanup(() => this.document.removeEventListener("pointerdown", handler, true));
|
|
151
|
+
});
|
|
152
|
+
}
|
|
153
|
+
show() {
|
|
154
|
+
if (this.disabled() || this.visible()) return;
|
|
155
|
+
this.visible.set(true);
|
|
156
|
+
this.opened.emit();
|
|
157
|
+
}
|
|
158
|
+
hide(focusTrigger = false) {
|
|
159
|
+
if (!this.visible()) return;
|
|
160
|
+
this.visible.set(false);
|
|
161
|
+
this.focusedKey.set(null);
|
|
162
|
+
this.closed.emit();
|
|
163
|
+
if (focusTrigger) this.triggerEl()?.focus();
|
|
164
|
+
}
|
|
165
|
+
toggle() {
|
|
166
|
+
this.visible() ? this.hide() : this.show();
|
|
167
|
+
}
|
|
168
|
+
focus(options) {
|
|
169
|
+
this.triggerEl()?.focus(options);
|
|
170
|
+
}
|
|
171
|
+
onTriggerClick(event) {
|
|
172
|
+
if (this.disabled()) return;
|
|
173
|
+
this.triggerClick.emit(event);
|
|
174
|
+
this.toggle();
|
|
175
|
+
}
|
|
176
|
+
onTriggerKeydown(event) {
|
|
177
|
+
if (this.disabled() || this.visible()) return;
|
|
178
|
+
if (![
|
|
179
|
+
"ArrowUp",
|
|
180
|
+
"ArrowDown",
|
|
181
|
+
"ArrowLeft",
|
|
182
|
+
"ArrowRight"
|
|
183
|
+
].includes(event.key)) return;
|
|
184
|
+
event.preventDefault();
|
|
185
|
+
this.show();
|
|
186
|
+
this.queueFocusTabStop();
|
|
187
|
+
}
|
|
188
|
+
onItemClick(event, node) {
|
|
189
|
+
const item = node.item;
|
|
190
|
+
if (item.disabled) {
|
|
191
|
+
event.preventDefault();
|
|
192
|
+
return;
|
|
193
|
+
}
|
|
194
|
+
if (!item.url && !item.routerLink) event.preventDefault();
|
|
195
|
+
this.focusedKey.set(node.key);
|
|
196
|
+
item.command?.({
|
|
197
|
+
originalEvent: event,
|
|
198
|
+
item
|
|
199
|
+
});
|
|
200
|
+
this.itemClick.emit({
|
|
201
|
+
originalEvent: event,
|
|
202
|
+
item
|
|
203
|
+
});
|
|
204
|
+
this.hide(true);
|
|
205
|
+
}
|
|
206
|
+
onListKeydown(event) {
|
|
207
|
+
const keys = this.focusableKeys();
|
|
208
|
+
if (!keys.length) return;
|
|
209
|
+
const current = this.focusedKey();
|
|
210
|
+
const index = current ? keys.indexOf(current) : -1;
|
|
211
|
+
switch (event.key) {
|
|
212
|
+
case "ArrowUp":
|
|
213
|
+
case "ArrowRight":
|
|
214
|
+
event.preventDefault();
|
|
215
|
+
this.focusByKey(keys[(index + 1) % keys.length]);
|
|
216
|
+
break;
|
|
217
|
+
case "ArrowDown":
|
|
218
|
+
case "ArrowLeft":
|
|
219
|
+
event.preventDefault();
|
|
220
|
+
this.focusByKey(keys[(index - 1 + keys.length) % keys.length]);
|
|
221
|
+
break;
|
|
222
|
+
case "Home":
|
|
223
|
+
event.preventDefault();
|
|
224
|
+
this.focusByKey(keys[0]);
|
|
225
|
+
break;
|
|
226
|
+
case "End":
|
|
227
|
+
event.preventDefault();
|
|
228
|
+
this.focusByKey(keys[keys.length - 1]);
|
|
229
|
+
break;
|
|
230
|
+
case "Escape":
|
|
231
|
+
event.preventDefault();
|
|
232
|
+
this.hide(true);
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
onEntryFocus(key) {
|
|
236
|
+
this.focusedKey.set(key);
|
|
237
|
+
}
|
|
238
|
+
onDocumentPointerdown(event) {
|
|
239
|
+
if (!this.visible() || !this.hideOnClickOutside()) return;
|
|
240
|
+
if (event.target instanceof Node && this.hostEl.nativeElement.contains(event.target)) return;
|
|
241
|
+
this.hide();
|
|
242
|
+
}
|
|
243
|
+
onMaskClick() {
|
|
244
|
+
this.hide();
|
|
245
|
+
}
|
|
246
|
+
focusByKey(key) {
|
|
247
|
+
if (!key) return;
|
|
248
|
+
this.focusedKey.set(key);
|
|
249
|
+
const target = this.nodes().find((n) => n.key === key);
|
|
250
|
+
if (!target) return;
|
|
251
|
+
this.actionEls()[target.index]?.focus();
|
|
252
|
+
}
|
|
253
|
+
queueFocusTabStop() {
|
|
254
|
+
setTimeout(() => this.focusByKey(this.tabStopKey() ?? void 0));
|
|
255
|
+
}
|
|
256
|
+
static {
|
|
257
|
+
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
258
|
+
minVersion: "12.0.0",
|
|
259
|
+
version: "22.3.0",
|
|
260
|
+
ngImport: i0,
|
|
261
|
+
type: UiSpeedDial,
|
|
262
|
+
deps: [],
|
|
263
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
264
|
+
});
|
|
265
|
+
}
|
|
266
|
+
static {
|
|
267
|
+
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
268
|
+
minVersion: "17.0.0",
|
|
269
|
+
version: "22.3.0",
|
|
270
|
+
type: UiSpeedDial,
|
|
271
|
+
isStandalone: true,
|
|
272
|
+
selector: "ui-speed-dial",
|
|
273
|
+
inputs: {
|
|
274
|
+
items: {
|
|
275
|
+
classPropertyName: "items",
|
|
276
|
+
publicName: "items",
|
|
277
|
+
isSignal: true,
|
|
278
|
+
isRequired: true,
|
|
279
|
+
transformFunction: null
|
|
280
|
+
},
|
|
281
|
+
visible: {
|
|
282
|
+
classPropertyName: "visible",
|
|
283
|
+
publicName: "visible",
|
|
284
|
+
isSignal: true,
|
|
285
|
+
isRequired: false,
|
|
286
|
+
transformFunction: null
|
|
287
|
+
},
|
|
288
|
+
type: {
|
|
289
|
+
classPropertyName: "type",
|
|
290
|
+
publicName: "type",
|
|
291
|
+
isSignal: true,
|
|
292
|
+
isRequired: false,
|
|
293
|
+
transformFunction: null
|
|
294
|
+
},
|
|
295
|
+
direction: {
|
|
296
|
+
classPropertyName: "direction",
|
|
297
|
+
publicName: "direction",
|
|
298
|
+
isSignal: true,
|
|
299
|
+
isRequired: false,
|
|
300
|
+
transformFunction: null
|
|
301
|
+
},
|
|
302
|
+
radius: {
|
|
303
|
+
classPropertyName: "radius",
|
|
304
|
+
publicName: "radius",
|
|
305
|
+
isSignal: true,
|
|
306
|
+
isRequired: false,
|
|
307
|
+
transformFunction: null
|
|
308
|
+
},
|
|
309
|
+
level: {
|
|
310
|
+
classPropertyName: "level",
|
|
311
|
+
publicName: "level",
|
|
312
|
+
isSignal: true,
|
|
313
|
+
isRequired: false,
|
|
314
|
+
transformFunction: null
|
|
315
|
+
},
|
|
316
|
+
itemLevel: {
|
|
317
|
+
classPropertyName: "itemLevel",
|
|
318
|
+
publicName: "itemLevel",
|
|
319
|
+
isSignal: true,
|
|
320
|
+
isRequired: false,
|
|
321
|
+
transformFunction: null
|
|
322
|
+
},
|
|
323
|
+
variant: {
|
|
324
|
+
classPropertyName: "variant",
|
|
325
|
+
publicName: "variant",
|
|
326
|
+
isSignal: true,
|
|
327
|
+
isRequired: false,
|
|
328
|
+
transformFunction: null
|
|
329
|
+
},
|
|
330
|
+
size: {
|
|
331
|
+
classPropertyName: "size",
|
|
332
|
+
publicName: "size",
|
|
333
|
+
isSignal: true,
|
|
334
|
+
isRequired: false,
|
|
335
|
+
transformFunction: null
|
|
336
|
+
},
|
|
337
|
+
showIcon: {
|
|
338
|
+
classPropertyName: "showIcon",
|
|
339
|
+
publicName: "showIcon",
|
|
340
|
+
isSignal: true,
|
|
341
|
+
isRequired: false,
|
|
342
|
+
transformFunction: null
|
|
343
|
+
},
|
|
344
|
+
hideIcon: {
|
|
345
|
+
classPropertyName: "hideIcon",
|
|
346
|
+
publicName: "hideIcon",
|
|
347
|
+
isSignal: true,
|
|
348
|
+
isRequired: false,
|
|
349
|
+
transformFunction: null
|
|
350
|
+
},
|
|
351
|
+
rotateAnimation: {
|
|
352
|
+
classPropertyName: "rotateAnimation",
|
|
353
|
+
publicName: "rotateAnimation",
|
|
354
|
+
isSignal: true,
|
|
355
|
+
isRequired: false,
|
|
356
|
+
transformFunction: null
|
|
357
|
+
},
|
|
358
|
+
mask: {
|
|
359
|
+
classPropertyName: "mask",
|
|
360
|
+
publicName: "mask",
|
|
361
|
+
isSignal: true,
|
|
362
|
+
isRequired: false,
|
|
363
|
+
transformFunction: null
|
|
364
|
+
},
|
|
365
|
+
hideOnClickOutside: {
|
|
366
|
+
classPropertyName: "hideOnClickOutside",
|
|
367
|
+
publicName: "hideOnClickOutside",
|
|
368
|
+
isSignal: true,
|
|
369
|
+
isRequired: false,
|
|
370
|
+
transformFunction: null
|
|
371
|
+
},
|
|
372
|
+
disabled: {
|
|
373
|
+
classPropertyName: "disabled",
|
|
374
|
+
publicName: "disabled",
|
|
375
|
+
isSignal: true,
|
|
376
|
+
isRequired: false,
|
|
377
|
+
transformFunction: null
|
|
378
|
+
},
|
|
379
|
+
showTooltips: {
|
|
380
|
+
classPropertyName: "showTooltips",
|
|
381
|
+
publicName: "showTooltips",
|
|
382
|
+
isSignal: true,
|
|
383
|
+
isRequired: false,
|
|
384
|
+
transformFunction: null
|
|
385
|
+
},
|
|
386
|
+
motion: {
|
|
387
|
+
classPropertyName: "motion",
|
|
388
|
+
publicName: "motion",
|
|
389
|
+
isSignal: true,
|
|
390
|
+
isRequired: false,
|
|
391
|
+
transformFunction: null
|
|
392
|
+
},
|
|
393
|
+
ariaLabel: {
|
|
394
|
+
classPropertyName: "ariaLabel",
|
|
395
|
+
publicName: "ariaLabel",
|
|
396
|
+
isSignal: true,
|
|
397
|
+
isRequired: false,
|
|
398
|
+
transformFunction: null
|
|
399
|
+
},
|
|
400
|
+
ariaLabelledBy: {
|
|
401
|
+
classPropertyName: "ariaLabelledBy",
|
|
402
|
+
publicName: "ariaLabelledBy",
|
|
403
|
+
isSignal: true,
|
|
404
|
+
isRequired: false,
|
|
405
|
+
transformFunction: null
|
|
406
|
+
},
|
|
407
|
+
tabindex: {
|
|
408
|
+
classPropertyName: "tabindex",
|
|
409
|
+
publicName: "tabindex",
|
|
410
|
+
isSignal: true,
|
|
411
|
+
isRequired: false,
|
|
412
|
+
transformFunction: null
|
|
413
|
+
}
|
|
414
|
+
},
|
|
415
|
+
outputs: {
|
|
416
|
+
visible: "visibleChange",
|
|
417
|
+
triggerClick: "triggerClick",
|
|
418
|
+
opened: "opened",
|
|
419
|
+
closed: "closed",
|
|
420
|
+
itemClick: "itemClick"
|
|
421
|
+
},
|
|
422
|
+
viewQueries: [{
|
|
423
|
+
propertyName: "triggerEl",
|
|
424
|
+
first: true,
|
|
425
|
+
predicate: ["trigger"],
|
|
426
|
+
descendants: true,
|
|
427
|
+
isSignal: true
|
|
428
|
+
}, {
|
|
429
|
+
propertyName: "actionEls",
|
|
430
|
+
predicate: ["actionBtn"],
|
|
431
|
+
descendants: true,
|
|
432
|
+
isSignal: true
|
|
433
|
+
}],
|
|
434
|
+
ngImport: i0,
|
|
435
|
+
template: "<div [class]=\"hostClasses()\" [style.--_radius]=\"radiusOverride()\">\n @if (mask() && visible()) {\n <div\n class=\"ui-speed-dial-mask\"\n [uiMotion]=\"'fade'\"\n [motionDisabled]=\"!motion()\"\n #maskMotion=\"uiMotion\"\n [animate.enter]=\"maskMotion.enter()\"\n [animate.leave]=\"maskMotion.leave()\"\n (click)=\"onMaskClick()\"\n aria-hidden=\"true\"\n ></div>\n }\n\n <ui-button\n #trigger\n class=\"ui-speed-dial-trigger\"\n [class._rotate]=\"triggerIconRotates()\"\n rounded\n iconOnly\n [level]=\"level()\"\n [variant]=\"variant()\"\n [size]=\"size()\"\n [icon]=\"triggerIcon()\"\n [ariaLabel]=\"ariaLabel()\"\n [disabled]=\"disabled()\"\n [tabindex]=\"tabindex()\"\n [buttonProps]=\"triggerProps()\"\n (buttonClick)=\"onTriggerClick($event)\"\n (keydown)=\"onTriggerKeydown($event)\"\n />\n\n @if (visible()) {\n <!-- ARIA menu pattern: keyboard delegated to the role=\"menu\" container,\n focus lives on the items (roving tabindex), same as ui-menu. -->\n <!-- eslint-disable-next-line @angular-eslint/template/interactive-supports-focus -->\n <div\n class=\"ui-speed-dial-list\"\n [id]=\"uid\"\n role=\"menu\"\n [attr.aria-label]=\"ariaLabel() || null\"\n (keydown)=\"onListKeydown($event)\"\n >\n @for (node of nodes(); track node.key) {\n <ui-button\n #actionBtn\n class=\"ui-speed-dial-item\"\n [style.--_stagger-index]=\"node.index\"\n [style.transform]=\"type() !== 'linear' ? arcTransform()(node.index) : null\"\n [uiMotion]=\"itemMotionPreset()\"\n [motionDisabled]=\"!motion()\"\n #itemMotion=\"uiMotion\"\n [animate.enter]=\"itemMotion.enter()\"\n [animate.leave]=\"itemMotion.leave()\"\n rounded\n iconOnly\n [level]=\"itemLevel()\"\n [variant]=\"variant()\"\n size=\"small\"\n [icon]=\"node.item.icon\"\n [ariaLabel]=\"node.item.ariaLabel || node.item.label\"\n [disabled]=\"node.item.disabled\"\n [href]=\"node.item.url\"\n [routerLink]=\"node.item.routerLink\"\n [target]=\"node.item.target\"\n [tabindex]=\"node.key === tabStopKey() ? 0 : -1\"\n [buttonProps]=\"itemProps\"\n [uiTooltip]=\"showTooltips() ? node.item.ariaLabel || node.item.label : undefined\"\n [tooltipPosition]=\"tooltipPosition()\"\n (buttonClick)=\"onItemClick($event, node)\"\n (focus)=\"onEntryFocus(node.key)\"\n />\n }\n </div>\n }\n</div>\n",
|
|
436
|
+
styles: [".ui-speed-dial{position:relative;display:inline-flex;z-index:var(--ui-speed-dial-z-index, 10);--_radius: var(--ui-speed-dial-radius, calc(2 * var(--size-components-default)))}.ui-speed-dial-mask{position:fixed;inset:0;background-color:var(--ui-speed-dial-mask-background, var(--primitives-black-50))}.ui-speed-dial-trigger{position:relative}.ui-speed-dial-trigger ::ng-deep .ui-button-icon{transition:rotate var(--ui-control-transition-duration, var(--motion-toggle-duration, var(--transition-default))) var(--ui-control-transition-easing, var(--motion-toggle-easing, var(--transition-easeinout)))}.ui-speed-dial-trigger._rotate ::ng-deep .ui-button-icon{rotate:45deg}.ui-speed-dial-list{position:absolute;display:flex;gap:var(--ui-speed-dial-item-gap, var(--units-sm));margin:0;padding:0;list-style:none;pointer-events:none}.ui-speed-dial._up .ui-speed-dial-list{bottom:calc(100% + var(--ui-speed-dial-item-gap, var(--units-sm)));left:50%;flex-direction:column-reverse;translate:-50% 0}.ui-speed-dial._down .ui-speed-dial-list{top:calc(100% + var(--ui-speed-dial-item-gap, var(--units-sm)));left:50%;flex-direction:column;translate:-50% 0}.ui-speed-dial._left .ui-speed-dial-list{right:calc(100% + var(--ui-speed-dial-item-gap, var(--units-sm)));top:50%;flex-direction:row-reverse;translate:0 -50%}.ui-speed-dial._right .ui-speed-dial-list{left:calc(100% + var(--ui-speed-dial-item-gap, var(--units-sm)));top:50%;flex-direction:row;translate:0 -50%}.ui-speed-dial._circle .ui-speed-dial-list,.ui-speed-dial._semi-circle .ui-speed-dial-list,.ui-speed-dial._quarter-circle .ui-speed-dial-list{inset:0}.ui-speed-dial._circle .ui-speed-dial-item,.ui-speed-dial._semi-circle .ui-speed-dial-item,.ui-speed-dial._quarter-circle .ui-speed-dial-item{position:absolute;top:50%;left:50%}.ui-speed-dial-item{pointer-events:auto;--ui-motion-delay: calc(var(--_stagger-index, 0) * var(--ui-speed-dial-item-delay, var(--motion-stagger-delay, var(--transition-fast))))}.ui-speed-dial-item[class*=-leave]{--ui-motion-delay: 0ms}\n"],
|
|
437
|
+
dependencies: [
|
|
438
|
+
{
|
|
439
|
+
kind: "component",
|
|
440
|
+
type: UiButton,
|
|
441
|
+
selector: "ui-button",
|
|
442
|
+
inputs: [
|
|
443
|
+
"label",
|
|
444
|
+
"ariaLabel",
|
|
445
|
+
"type",
|
|
446
|
+
"level",
|
|
447
|
+
"variant",
|
|
448
|
+
"onColor",
|
|
449
|
+
"size",
|
|
450
|
+
"icon",
|
|
451
|
+
"iconPos",
|
|
452
|
+
"iconOnly",
|
|
453
|
+
"loading",
|
|
454
|
+
"loadingIcon",
|
|
455
|
+
"expanded",
|
|
456
|
+
"rounded",
|
|
457
|
+
"disabled",
|
|
458
|
+
"ripple",
|
|
459
|
+
"tabindex",
|
|
460
|
+
"buttonProps",
|
|
461
|
+
"iconTemplate",
|
|
462
|
+
"loadingIconTemplate",
|
|
463
|
+
"href",
|
|
464
|
+
"routerLink",
|
|
465
|
+
"target",
|
|
466
|
+
"rel"
|
|
467
|
+
],
|
|
468
|
+
outputs: [
|
|
469
|
+
"buttonClick",
|
|
470
|
+
"buttonFocus",
|
|
471
|
+
"buttonBlur"
|
|
472
|
+
]
|
|
473
|
+
},
|
|
474
|
+
{
|
|
475
|
+
kind: "directive",
|
|
476
|
+
type: RouterLink,
|
|
477
|
+
selector: "[routerLink]",
|
|
478
|
+
inputs: [
|
|
479
|
+
"target",
|
|
480
|
+
"queryParams",
|
|
481
|
+
"fragment",
|
|
482
|
+
"queryParamsHandling",
|
|
483
|
+
"state",
|
|
484
|
+
"info",
|
|
485
|
+
"relativeTo",
|
|
486
|
+
"preserveFragment",
|
|
487
|
+
"skipLocationChange",
|
|
488
|
+
"replaceUrl",
|
|
489
|
+
"browserUrl",
|
|
490
|
+
"scroll",
|
|
491
|
+
"routerLink"
|
|
492
|
+
]
|
|
493
|
+
},
|
|
494
|
+
{
|
|
495
|
+
kind: "directive",
|
|
496
|
+
type: UiTooltip,
|
|
497
|
+
selector: "[uiTooltip]",
|
|
498
|
+
inputs: [
|
|
499
|
+
"uiTooltip",
|
|
500
|
+
"tooltipPosition",
|
|
501
|
+
"fitContent",
|
|
502
|
+
"tooltipEvent",
|
|
503
|
+
"tooltipDisabled",
|
|
504
|
+
"showDelay",
|
|
505
|
+
"hideDelay",
|
|
506
|
+
"escape",
|
|
507
|
+
"tooltipStyleClass",
|
|
508
|
+
"autoHide",
|
|
509
|
+
"hideOnEscape",
|
|
510
|
+
"life",
|
|
511
|
+
"showOnEllipsis",
|
|
512
|
+
"positionTop",
|
|
513
|
+
"positionLeft",
|
|
514
|
+
"tooltipContext"
|
|
515
|
+
],
|
|
516
|
+
outputs: ["tooltipShow", "tooltipHide"],
|
|
517
|
+
exportAs: ["uiTooltip"]
|
|
518
|
+
},
|
|
519
|
+
{
|
|
520
|
+
kind: "directive",
|
|
521
|
+
type: UiMotion,
|
|
522
|
+
selector: "[uiMotion]",
|
|
523
|
+
inputs: [
|
|
524
|
+
"uiMotion",
|
|
525
|
+
"motionDuration",
|
|
526
|
+
"motionDelay",
|
|
527
|
+
"motionEasing",
|
|
528
|
+
"motionEnterEasing",
|
|
529
|
+
"motionLeaveEasing",
|
|
530
|
+
"motionDistance",
|
|
531
|
+
"motionScale",
|
|
532
|
+
"motionDisabled",
|
|
533
|
+
"motionOnInsert"
|
|
534
|
+
],
|
|
535
|
+
exportAs: ["uiMotion"]
|
|
536
|
+
}
|
|
537
|
+
]
|
|
538
|
+
});
|
|
539
|
+
}
|
|
540
|
+
};
|
|
541
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
542
|
+
minVersion: "12.0.0",
|
|
543
|
+
version: "22.3.0",
|
|
544
|
+
ngImport: i0,
|
|
545
|
+
type: UiSpeedDial,
|
|
546
|
+
decorators: [{
|
|
547
|
+
type: Component,
|
|
548
|
+
args: [{
|
|
549
|
+
selector: "ui-speed-dial",
|
|
550
|
+
imports: [
|
|
551
|
+
UiButton,
|
|
552
|
+
NgTemplateOutlet,
|
|
553
|
+
RouterLink,
|
|
554
|
+
UiTooltip,
|
|
555
|
+
UiMotion
|
|
556
|
+
],
|
|
557
|
+
template: "<div [class]=\"hostClasses()\" [style.--_radius]=\"radiusOverride()\">\n @if (mask() && visible()) {\n <div\n class=\"ui-speed-dial-mask\"\n [uiMotion]=\"'fade'\"\n [motionDisabled]=\"!motion()\"\n #maskMotion=\"uiMotion\"\n [animate.enter]=\"maskMotion.enter()\"\n [animate.leave]=\"maskMotion.leave()\"\n (click)=\"onMaskClick()\"\n aria-hidden=\"true\"\n ></div>\n }\n\n <ui-button\n #trigger\n class=\"ui-speed-dial-trigger\"\n [class._rotate]=\"triggerIconRotates()\"\n rounded\n iconOnly\n [level]=\"level()\"\n [variant]=\"variant()\"\n [size]=\"size()\"\n [icon]=\"triggerIcon()\"\n [ariaLabel]=\"ariaLabel()\"\n [disabled]=\"disabled()\"\n [tabindex]=\"tabindex()\"\n [buttonProps]=\"triggerProps()\"\n (buttonClick)=\"onTriggerClick($event)\"\n (keydown)=\"onTriggerKeydown($event)\"\n />\n\n @if (visible()) {\n <!-- ARIA menu pattern: keyboard delegated to the role=\"menu\" container,\n focus lives on the items (roving tabindex), same as ui-menu. -->\n <!-- eslint-disable-next-line @angular-eslint/template/interactive-supports-focus -->\n <div\n class=\"ui-speed-dial-list\"\n [id]=\"uid\"\n role=\"menu\"\n [attr.aria-label]=\"ariaLabel() || null\"\n (keydown)=\"onListKeydown($event)\"\n >\n @for (node of nodes(); track node.key) {\n <ui-button\n #actionBtn\n class=\"ui-speed-dial-item\"\n [style.--_stagger-index]=\"node.index\"\n [style.transform]=\"type() !== 'linear' ? arcTransform()(node.index) : null\"\n [uiMotion]=\"itemMotionPreset()\"\n [motionDisabled]=\"!motion()\"\n #itemMotion=\"uiMotion\"\n [animate.enter]=\"itemMotion.enter()\"\n [animate.leave]=\"itemMotion.leave()\"\n rounded\n iconOnly\n [level]=\"itemLevel()\"\n [variant]=\"variant()\"\n size=\"small\"\n [icon]=\"node.item.icon\"\n [ariaLabel]=\"node.item.ariaLabel || node.item.label\"\n [disabled]=\"node.item.disabled\"\n [href]=\"node.item.url\"\n [routerLink]=\"node.item.routerLink\"\n [target]=\"node.item.target\"\n [tabindex]=\"node.key === tabStopKey() ? 0 : -1\"\n [buttonProps]=\"itemProps\"\n [uiTooltip]=\"showTooltips() ? node.item.ariaLabel || node.item.label : undefined\"\n [tooltipPosition]=\"tooltipPosition()\"\n (buttonClick)=\"onItemClick($event, node)\"\n (focus)=\"onEntryFocus(node.key)\"\n />\n }\n </div>\n }\n</div>\n",
|
|
558
|
+
styles: [".ui-speed-dial{position:relative;display:inline-flex;z-index:var(--ui-speed-dial-z-index, 10);--_radius: var(--ui-speed-dial-radius, calc(2 * var(--size-components-default)))}.ui-speed-dial-mask{position:fixed;inset:0;background-color:var(--ui-speed-dial-mask-background, var(--primitives-black-50))}.ui-speed-dial-trigger{position:relative}.ui-speed-dial-trigger ::ng-deep .ui-button-icon{transition:rotate var(--ui-control-transition-duration, var(--motion-toggle-duration, var(--transition-default))) var(--ui-control-transition-easing, var(--motion-toggle-easing, var(--transition-easeinout)))}.ui-speed-dial-trigger._rotate ::ng-deep .ui-button-icon{rotate:45deg}.ui-speed-dial-list{position:absolute;display:flex;gap:var(--ui-speed-dial-item-gap, var(--units-sm));margin:0;padding:0;list-style:none;pointer-events:none}.ui-speed-dial._up .ui-speed-dial-list{bottom:calc(100% + var(--ui-speed-dial-item-gap, var(--units-sm)));left:50%;flex-direction:column-reverse;translate:-50% 0}.ui-speed-dial._down .ui-speed-dial-list{top:calc(100% + var(--ui-speed-dial-item-gap, var(--units-sm)));left:50%;flex-direction:column;translate:-50% 0}.ui-speed-dial._left .ui-speed-dial-list{right:calc(100% + var(--ui-speed-dial-item-gap, var(--units-sm)));top:50%;flex-direction:row-reverse;translate:0 -50%}.ui-speed-dial._right .ui-speed-dial-list{left:calc(100% + var(--ui-speed-dial-item-gap, var(--units-sm)));top:50%;flex-direction:row;translate:0 -50%}.ui-speed-dial._circle .ui-speed-dial-list,.ui-speed-dial._semi-circle .ui-speed-dial-list,.ui-speed-dial._quarter-circle .ui-speed-dial-list{inset:0}.ui-speed-dial._circle .ui-speed-dial-item,.ui-speed-dial._semi-circle .ui-speed-dial-item,.ui-speed-dial._quarter-circle .ui-speed-dial-item{position:absolute;top:50%;left:50%}.ui-speed-dial-item{pointer-events:auto;--ui-motion-delay: calc(var(--_stagger-index, 0) * var(--ui-speed-dial-item-delay, var(--motion-stagger-delay, var(--transition-fast))))}.ui-speed-dial-item[class*=-leave]{--ui-motion-delay: 0ms}\n"]
|
|
559
|
+
}]
|
|
560
|
+
}],
|
|
561
|
+
ctorParameters: () => [],
|
|
562
|
+
propDecorators: {
|
|
563
|
+
items: [{
|
|
564
|
+
type: i0.Input,
|
|
565
|
+
args: [{
|
|
566
|
+
isSignal: true,
|
|
567
|
+
alias: "items",
|
|
568
|
+
required: true
|
|
569
|
+
}]
|
|
570
|
+
}],
|
|
571
|
+
visible: [{
|
|
572
|
+
type: i0.Input,
|
|
573
|
+
args: [{
|
|
574
|
+
isSignal: true,
|
|
575
|
+
alias: "visible",
|
|
576
|
+
required: false
|
|
577
|
+
}]
|
|
578
|
+
}, {
|
|
579
|
+
type: i0.Output,
|
|
580
|
+
args: ["visibleChange"]
|
|
581
|
+
}],
|
|
582
|
+
type: [{
|
|
583
|
+
type: i0.Input,
|
|
584
|
+
args: [{
|
|
585
|
+
isSignal: true,
|
|
586
|
+
alias: "type",
|
|
587
|
+
required: false
|
|
588
|
+
}]
|
|
589
|
+
}],
|
|
590
|
+
direction: [{
|
|
591
|
+
type: i0.Input,
|
|
592
|
+
args: [{
|
|
593
|
+
isSignal: true,
|
|
594
|
+
alias: "direction",
|
|
595
|
+
required: false
|
|
596
|
+
}]
|
|
597
|
+
}],
|
|
598
|
+
radius: [{
|
|
599
|
+
type: i0.Input,
|
|
600
|
+
args: [{
|
|
601
|
+
isSignal: true,
|
|
602
|
+
alias: "radius",
|
|
603
|
+
required: false
|
|
604
|
+
}]
|
|
605
|
+
}],
|
|
606
|
+
level: [{
|
|
607
|
+
type: i0.Input,
|
|
608
|
+
args: [{
|
|
609
|
+
isSignal: true,
|
|
610
|
+
alias: "level",
|
|
611
|
+
required: false
|
|
612
|
+
}]
|
|
613
|
+
}],
|
|
614
|
+
itemLevel: [{
|
|
615
|
+
type: i0.Input,
|
|
616
|
+
args: [{
|
|
617
|
+
isSignal: true,
|
|
618
|
+
alias: "itemLevel",
|
|
619
|
+
required: false
|
|
620
|
+
}]
|
|
621
|
+
}],
|
|
622
|
+
variant: [{
|
|
623
|
+
type: i0.Input,
|
|
624
|
+
args: [{
|
|
625
|
+
isSignal: true,
|
|
626
|
+
alias: "variant",
|
|
627
|
+
required: false
|
|
628
|
+
}]
|
|
629
|
+
}],
|
|
630
|
+
size: [{
|
|
631
|
+
type: i0.Input,
|
|
632
|
+
args: [{
|
|
633
|
+
isSignal: true,
|
|
634
|
+
alias: "size",
|
|
635
|
+
required: false
|
|
636
|
+
}]
|
|
637
|
+
}],
|
|
638
|
+
showIcon: [{
|
|
639
|
+
type: i0.Input,
|
|
640
|
+
args: [{
|
|
641
|
+
isSignal: true,
|
|
642
|
+
alias: "showIcon",
|
|
643
|
+
required: false
|
|
644
|
+
}]
|
|
645
|
+
}],
|
|
646
|
+
hideIcon: [{
|
|
647
|
+
type: i0.Input,
|
|
648
|
+
args: [{
|
|
649
|
+
isSignal: true,
|
|
650
|
+
alias: "hideIcon",
|
|
651
|
+
required: false
|
|
652
|
+
}]
|
|
653
|
+
}],
|
|
654
|
+
rotateAnimation: [{
|
|
655
|
+
type: i0.Input,
|
|
656
|
+
args: [{
|
|
657
|
+
isSignal: true,
|
|
658
|
+
alias: "rotateAnimation",
|
|
659
|
+
required: false
|
|
660
|
+
}]
|
|
661
|
+
}],
|
|
662
|
+
mask: [{
|
|
663
|
+
type: i0.Input,
|
|
664
|
+
args: [{
|
|
665
|
+
isSignal: true,
|
|
666
|
+
alias: "mask",
|
|
667
|
+
required: false
|
|
668
|
+
}]
|
|
669
|
+
}],
|
|
670
|
+
hideOnClickOutside: [{
|
|
671
|
+
type: i0.Input,
|
|
672
|
+
args: [{
|
|
673
|
+
isSignal: true,
|
|
674
|
+
alias: "hideOnClickOutside",
|
|
675
|
+
required: false
|
|
676
|
+
}]
|
|
677
|
+
}],
|
|
678
|
+
disabled: [{
|
|
679
|
+
type: i0.Input,
|
|
680
|
+
args: [{
|
|
681
|
+
isSignal: true,
|
|
682
|
+
alias: "disabled",
|
|
683
|
+
required: false
|
|
684
|
+
}]
|
|
685
|
+
}],
|
|
686
|
+
showTooltips: [{
|
|
687
|
+
type: i0.Input,
|
|
688
|
+
args: [{
|
|
689
|
+
isSignal: true,
|
|
690
|
+
alias: "showTooltips",
|
|
691
|
+
required: false
|
|
692
|
+
}]
|
|
693
|
+
}],
|
|
694
|
+
motion: [{
|
|
695
|
+
type: i0.Input,
|
|
696
|
+
args: [{
|
|
697
|
+
isSignal: true,
|
|
698
|
+
alias: "motion",
|
|
699
|
+
required: false
|
|
700
|
+
}]
|
|
701
|
+
}],
|
|
702
|
+
ariaLabel: [{
|
|
703
|
+
type: i0.Input,
|
|
704
|
+
args: [{
|
|
705
|
+
isSignal: true,
|
|
706
|
+
alias: "ariaLabel",
|
|
707
|
+
required: false
|
|
708
|
+
}]
|
|
709
|
+
}],
|
|
710
|
+
ariaLabelledBy: [{
|
|
711
|
+
type: i0.Input,
|
|
712
|
+
args: [{
|
|
713
|
+
isSignal: true,
|
|
714
|
+
alias: "ariaLabelledBy",
|
|
715
|
+
required: false
|
|
716
|
+
}]
|
|
717
|
+
}],
|
|
718
|
+
tabindex: [{
|
|
719
|
+
type: i0.Input,
|
|
720
|
+
args: [{
|
|
721
|
+
isSignal: true,
|
|
722
|
+
alias: "tabindex",
|
|
723
|
+
required: false
|
|
724
|
+
}]
|
|
725
|
+
}],
|
|
726
|
+
triggerClick: [{
|
|
727
|
+
type: i0.Output,
|
|
728
|
+
args: ["triggerClick"]
|
|
729
|
+
}],
|
|
730
|
+
opened: [{
|
|
731
|
+
type: i0.Output,
|
|
732
|
+
args: ["opened"]
|
|
733
|
+
}],
|
|
734
|
+
closed: [{
|
|
735
|
+
type: i0.Output,
|
|
736
|
+
args: ["closed"]
|
|
737
|
+
}],
|
|
738
|
+
itemClick: [{
|
|
739
|
+
type: i0.Output,
|
|
740
|
+
args: ["itemClick"]
|
|
741
|
+
}],
|
|
742
|
+
triggerEl: [{
|
|
743
|
+
type: i0.ViewChild,
|
|
744
|
+
args: ["trigger", { isSignal: true }]
|
|
745
|
+
}],
|
|
746
|
+
actionEls: [{
|
|
747
|
+
type: i0.ViewChildren,
|
|
748
|
+
args: ["actionBtn", { isSignal: true }]
|
|
749
|
+
}]
|
|
750
|
+
}
|
|
751
|
+
});
|
|
438
752
|
export { UiSpeedDial };
|
|
439
|
-
|
|
753
|
+
|
|
754
|
+
//# sourceMappingURL=4sh-ui-kit-actions-ui-speed-dial.mjs.map
|