@kaufmann-lab/ui 0.1.45 → 0.1.47
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.
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { DOCUMENT, NgTemplateOutlet } from '@angular/common';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
|
-
import { input, booleanAttribute, inject, computed, effect, Component, output, signal as signal$1, viewChild, untracked, DestroyRef, afterNextRender, isDevMode, ViewContainerRef, Injector, Directive, model, linkedSignal, contentChild, afterRenderEffect, HostListener, TemplateRef, ElementRef, ChangeDetectionStrategy, numberAttribute, contentChildren, forwardRef, viewChildren, Input as Input$1
|
|
3
|
+
import { input, booleanAttribute, inject, computed, effect, Component, output, signal as signal$1, viewChild, untracked, DestroyRef, afterNextRender, isDevMode, ViewContainerRef, Injector, Directive, model, linkedSignal, contentChild, ErrorHandler, afterRenderEffect, HostListener, TemplateRef, ElementRef, ChangeDetectionStrategy, numberAttribute, contentChildren, forwardRef, Injectable, viewChildren, Input as Input$1 } from '@angular/core';
|
|
4
4
|
import { FocusTrapFactory } from '@angular/cdk/a11y';
|
|
5
5
|
import { Overlay, OverlayContainer } from '@angular/cdk/overlay';
|
|
6
6
|
import { TemplatePortal, ComponentPortal } from '@angular/cdk/portal';
|
|
@@ -1580,6 +1580,24 @@ function unregisterOpenModalDialog(dialog) {
|
|
|
1580
1580
|
relocateContainers();
|
|
1581
1581
|
}
|
|
1582
1582
|
}
|
|
1583
|
+
/**
|
|
1584
|
+
* `true` si hay una capa modal abierta por encima de `panel`: un `kf-modal`, un `kf-media-viewer` u otro
|
|
1585
|
+
* `kf-drawer` con `role="dialog"` registrado después, o un `<dialog>` abierto que no pertenece a la
|
|
1586
|
+
* librería. Una capa que contiene a `panel` (el `<dialog>` donde vive el drawer) no está por encima.
|
|
1587
|
+
*
|
|
1588
|
+
* `Escape` le llega a cada capa con un oyente propio en `document`, y el cierre nativo de un `<dialog>` es la
|
|
1589
|
+
* acción por defecto de la tecla, que corre después de despachada: un panel que solo mira
|
|
1590
|
+
* `defaultPrevented` ve la tecla sin consumir y se cierra junto con el diálogo. Un panel sin registro
|
|
1591
|
+
* (`role="navigation"`) cuenta cualquier capa registrada que no lo contenga como superior.
|
|
1592
|
+
*/
|
|
1593
|
+
function hasModalLayerAbove(panel) {
|
|
1594
|
+
const index = openModalDialogs.indexOf(panel);
|
|
1595
|
+
const registeredAbove = index === -1 ? openModalDialogs : openModalDialogs.slice(index + 1);
|
|
1596
|
+
if (registeredAbove.some((layer) => !layer.contains(panel))) {
|
|
1597
|
+
return true;
|
|
1598
|
+
}
|
|
1599
|
+
return Array.from(panel.ownerDocument.querySelectorAll('dialog[open]')).some((dialog) => !dialog.contains(panel) && !openModalDialogs.includes(dialog));
|
|
1600
|
+
}
|
|
1583
1601
|
/**
|
|
1584
1602
|
* El diálogo abierto más reciente que pueda alojar al contenedor. Se descarta
|
|
1585
1603
|
* el que vive DENTRO del propio contenedor (la hoja de `kf-action-menu`, un
|
|
@@ -1712,7 +1730,7 @@ class SheetPortal {
|
|
|
1712
1730
|
}
|
|
1713
1731
|
}
|
|
1714
1732
|
|
|
1715
|
-
let nextId$
|
|
1733
|
+
let nextId$a = 0;
|
|
1716
1734
|
/**
|
|
1717
1735
|
* Retrocesos de historial pedidos por un drawer cuyo `popstate` todavía no se
|
|
1718
1736
|
* procesó. Mientras hay alguno, ningún drawer toma ese `popstate` como el botón
|
|
@@ -1885,7 +1903,24 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
1885
1903
|
* Escape cierra el panel salvo que un control interno ya haya consumido la
|
|
1886
1904
|
* tecla (`event.defaultPrevented`): un `kf-select`, `kf-multi-select` o
|
|
1887
1905
|
* `kf-dropdown` abierto dentro del drawer cierra primero su propio panel y
|
|
1888
|
-
* un segundo Escape cierra el drawer.
|
|
1906
|
+
* un segundo Escape cierra el drawer. Lo mismo vale para una capa modal por
|
|
1907
|
+
* encima: con un `kf-modal`, un `kf-confirm-dialog`, un `kf-media-viewer` o
|
|
1908
|
+
* otro `kf-drawer` con `role="dialog"` abierto después, `Escape` cierra solo esa
|
|
1909
|
+
* capa (la más reciente) y el drawer sigue abierto hasta el siguiente.
|
|
1910
|
+
*
|
|
1911
|
+
* ## `closeGuard`: preguntar antes de cerrar
|
|
1912
|
+
*
|
|
1913
|
+
* `closeGuard` es una función que se consulta antes de cada cierre pedido por la persona
|
|
1914
|
+
* (la X, el telón, `Escape`, el arrastre de la hoja y el botón atrás de `closeOnBack`):
|
|
1915
|
+
* devuelve `true` para cerrar o `false` para dejar el panel abierto, y puede ser asíncrona
|
|
1916
|
+
* (por ejemplo, esperar la respuesta de un `kf-confirm-dialog`). Como se pregunta antes de que
|
|
1917
|
+
* `open` cambie, `open` nunca pasa por `false` mientras la respuesta es «no»: lo escrito en el
|
|
1918
|
+
* panel no se pierde ni los efectos que miran `open` se disparan. Mientras hay una pregunta
|
|
1919
|
+
* pendiente, otro intento de cierre recibe la misma respuesta. `requestClose()` pasa por la
|
|
1920
|
+
* guarda, para los botones propios («Cancelar») de quien aloja el panel; `close()` y
|
|
1921
|
+
* `open.set(false)` no la consultan.
|
|
1922
|
+
*
|
|
1923
|
+
* <kf-drawer [(open)]="open" role="dialog" side="right" title="Editar" [closeGuard]="confirmDiscard" />
|
|
1889
1924
|
*
|
|
1890
1925
|
* Nombres por defecto: con `role="navigation"` el panel se llama "Menú" y
|
|
1891
1926
|
* el cierre "Cerrar menú" (comportamiento histórico). Con `role="dialog"`
|
|
@@ -1981,9 +2016,9 @@ class Drawer {
|
|
|
1981
2016
|
closeLabel = input(/* @ts-ignore */
|
|
1982
2017
|
...(ngDevMode ? [undefined, { debugName: "closeLabel" }] : /* istanbul ignore next */ []));
|
|
1983
2018
|
/**
|
|
1984
|
-
* Ancho con nombre de un panel lateral (`left` o `right`): `
|
|
1985
|
-
* 94vw)` y `lg` = `min(880px, 70vw)`,
|
|
1986
|
-
* ajustan con `--kf-drawer-width-md` y
|
|
2019
|
+
* Ancho con nombre de un panel lateral (`left` o `right`): `sm` = `min(400px,
|
|
2020
|
+
* 94vw)`, `md` = `min(640px, 94vw)` y `lg` = `min(880px, 70vw)`, los tres a ancho
|
|
2021
|
+
* completo bajo 600px; se ajustan con `--kf-drawer-width-sm`, `-md` y `-lg`. `null` (default)
|
|
1987
2022
|
* conserva el ancho de siempre (`--kf-drawer-width`, 480px en `dialog`). Sin
|
|
1988
2023
|
* efecto en la hoja inferior.
|
|
1989
2024
|
*/
|
|
@@ -2025,6 +2060,13 @@ class Drawer {
|
|
|
2025
2060
|
* JSDoc de la clase.
|
|
2026
2061
|
*/
|
|
2027
2062
|
mountInOverlay = input(false, { ...(ngDevMode ? { debugName: "mountInOverlay" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
2063
|
+
/**
|
|
2064
|
+
* Se consulta antes de cerrar por la X, el telón, `Escape`, el arrastre de la hoja o el botón atrás
|
|
2065
|
+
* (`closeOnBack`); si devuelve `false` el panel queda abierto. `null` (default) cierra sin preguntar. No
|
|
2066
|
+
* afecta a `close()` ni a `open.set(false)`. Ver el JSDoc de la clase.
|
|
2067
|
+
*/
|
|
2068
|
+
closeGuard = input(null, /* @ts-ignore */
|
|
2069
|
+
...(ngDevMode ? [{ debugName: "closeGuard" }] : /* istanbul ignore next */ []));
|
|
2028
2070
|
/**
|
|
2029
2071
|
* Se emite cada vez que el drawer termina de cerrarse: con `closeOnBack`,
|
|
2030
2072
|
* después de que el historial retrocedió su entrada. Abrir otra hoja o
|
|
@@ -2042,7 +2084,7 @@ class Drawer {
|
|
|
2042
2084
|
/** `closeLabel` o, sin él, el default según el rol. */
|
|
2043
2085
|
resolvedCloseLabel = computed(() => this.closeLabel() ?? (this.role() === 'dialog' ? 'Cerrar' : 'Cerrar menú'), /* @ts-ignore */
|
|
2044
2086
|
...(ngDevMode ? [{ debugName: "resolvedCloseLabel" }] : /* istanbul ignore next */ []));
|
|
2045
|
-
titleId = `kf-drawer-title-${nextId$
|
|
2087
|
+
titleId = `kf-drawer-title-${nextId$a++}`;
|
|
2046
2088
|
/**
|
|
2047
2089
|
* Presencia de `[kfDrawerTitle]`. Sin `descendants`: como la proyección, solo cuenta lo que se
|
|
2048
2090
|
* declara directo en este `<kf-drawer>`, no el título de un drawer anidado en su cuerpo.
|
|
@@ -2060,6 +2102,8 @@ class Drawer {
|
|
|
2060
2102
|
focusTrapFactory = inject(FocusTrapFactory);
|
|
2061
2103
|
document = inject(DOCUMENT);
|
|
2062
2104
|
overlayContainer = inject(OverlayContainer);
|
|
2105
|
+
errorHandler = inject(ErrorHandler);
|
|
2106
|
+
pendingClose = null;
|
|
2063
2107
|
history = inject(DOCUMENT).defaultView?.history ?? null;
|
|
2064
2108
|
window = inject(DOCUMENT).defaultView;
|
|
2065
2109
|
historyPushed = false;
|
|
@@ -2157,12 +2201,55 @@ class Drawer {
|
|
|
2157
2201
|
this.focusTrap?.destroy();
|
|
2158
2202
|
});
|
|
2159
2203
|
}
|
|
2160
|
-
/**
|
|
2204
|
+
/**
|
|
2205
|
+
* Cierra el drawer con Escape — mismo patrón que `Dropdown`/`Modal`. Con una capa modal por encima
|
|
2206
|
+
* (un diálogo o un drawer abierto después) la tecla es de esa capa y este panel sigue abierto; al
|
|
2207
|
+
* consumirla se cancela su acción por defecto, que es lo que cerraría un `<dialog>` que lo contenga.
|
|
2208
|
+
*/
|
|
2161
2209
|
onEscape(event) {
|
|
2162
2210
|
if (!this.open() || event.defaultPrevented) {
|
|
2163
2211
|
return;
|
|
2164
2212
|
}
|
|
2213
|
+
const panel = this.panelRef()?.nativeElement;
|
|
2214
|
+
if (panel && hasModalLayerAbove(panel)) {
|
|
2215
|
+
return;
|
|
2216
|
+
}
|
|
2217
|
+
event.preventDefault();
|
|
2218
|
+
this.onDismiss();
|
|
2219
|
+
}
|
|
2220
|
+
/**
|
|
2221
|
+
* Cierra el drawer como lo pediría la persona: si hay `closeGuard`, primero lo consulta y solo cierra
|
|
2222
|
+
* si responde `true`. Resuelve `true` si el panel quedó cerrado y `false` si la guarda lo mantuvo abierto
|
|
2223
|
+
* (o falló). Dos pedidos mientras la guarda responde reciben la misma respuesta.
|
|
2224
|
+
*/
|
|
2225
|
+
requestClose() {
|
|
2226
|
+
if (!this.open()) {
|
|
2227
|
+
return Promise.resolve(true);
|
|
2228
|
+
}
|
|
2229
|
+
this.pendingClose ??= this.askGuardThenClose().finally(() => (this.pendingClose = null));
|
|
2230
|
+
return this.pendingClose;
|
|
2231
|
+
}
|
|
2232
|
+
/** Cierre pedido desde un control del propio panel: la X, el telón, `Escape` o el arrastre. */
|
|
2233
|
+
onDismiss() {
|
|
2234
|
+
void this.requestClose();
|
|
2235
|
+
}
|
|
2236
|
+
async askGuardThenClose() {
|
|
2237
|
+
const guard = this.closeGuard();
|
|
2238
|
+
if (guard) {
|
|
2239
|
+
let allowed = false;
|
|
2240
|
+
try {
|
|
2241
|
+
allowed = await guard();
|
|
2242
|
+
}
|
|
2243
|
+
catch (error) {
|
|
2244
|
+
// Una guarda que falla no puede decidir por la persona: el panel sigue abierto.
|
|
2245
|
+
this.errorHandler.handleError(error);
|
|
2246
|
+
}
|
|
2247
|
+
if (!allowed) {
|
|
2248
|
+
return false;
|
|
2249
|
+
}
|
|
2250
|
+
}
|
|
2165
2251
|
this.open.set(false);
|
|
2252
|
+
return true;
|
|
2166
2253
|
}
|
|
2167
2254
|
/**
|
|
2168
2255
|
* Cierra el drawer y resuelve cuando el cierre terminó (el mismo momento que
|
|
@@ -2183,7 +2270,12 @@ class Drawer {
|
|
|
2183
2270
|
return;
|
|
2184
2271
|
}
|
|
2185
2272
|
this.historyPushed = false;
|
|
2186
|
-
this.
|
|
2273
|
+
void this.requestClose().then((closed) => {
|
|
2274
|
+
// La guarda mantuvo la hoja abierta: se repone la entrada de historial que el botón atrás acaba de retirar.
|
|
2275
|
+
if (!closed && this.open()) {
|
|
2276
|
+
this.pushEntry();
|
|
2277
|
+
}
|
|
2278
|
+
});
|
|
2187
2279
|
}
|
|
2188
2280
|
notifyClosed() {
|
|
2189
2281
|
if (this.open()) {
|
|
@@ -2307,7 +2399,7 @@ class Drawer {
|
|
|
2307
2399
|
this.setDetent('medium');
|
|
2308
2400
|
}
|
|
2309
2401
|
else {
|
|
2310
|
-
this.
|
|
2402
|
+
this.onDismiss();
|
|
2311
2403
|
}
|
|
2312
2404
|
}
|
|
2313
2405
|
/** Quita los estilos del arrastre: la transición del CSS lleva la hoja a su posición de reposo. */
|
|
@@ -2339,7 +2431,7 @@ class Drawer {
|
|
|
2339
2431
|
return this.focusTrap;
|
|
2340
2432
|
}
|
|
2341
2433
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: Drawer, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2342
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: Drawer, isStandalone: true, selector: "kf-drawer", inputs: { open: { classPropertyName: "open", publicName: "open", isSignal: true, isRequired: false, transformFunction: null }, side: { classPropertyName: "side", publicName: "side", isSignal: true, isRequired: false, transformFunction: null }, role: { classPropertyName: "role", publicName: "role", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, closeLabel: { classPropertyName: "closeLabel", publicName: "closeLabel", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, sheetSize: { classPropertyName: "sheetSize", publicName: "sheetSize", isSignal: true, isRequired: false, transformFunction: null }, expandable: { classPropertyName: "expandable", publicName: "expandable", isSignal: true, isRequired: false, transformFunction: null }, sheetWidth: { classPropertyName: "sheetWidth", publicName: "sheetWidth", isSignal: true, isRequired: false, transformFunction: null }, flush: { classPropertyName: "flush", publicName: "flush", isSignal: true, isRequired: false, transformFunction: null }, swipeToClose: { classPropertyName: "swipeToClose", publicName: "swipeToClose", isSignal: true, isRequired: false, transformFunction: null }, closeOnBack: { classPropertyName: "closeOnBack", publicName: "closeOnBack", isSignal: true, isRequired: false, transformFunction: null }, mountInOverlay: { classPropertyName: "mountInOverlay", publicName: "mountInOverlay", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { open: "openChange", closedAfterBack: "closedAfterBack", detentChange: "detentChange" }, host: { listeners: { "window:popstate": "onPopState()", "document:keydown.escape": "onEscape($event)" }, properties: { "attr.role": "null", "attr.title": "null" } }, queries: [{ propertyName: "titleSlot", first: true, predicate: DrawerTitle, isSignal: true }], viewQueries: [{ propertyName: "panelRef", first: true, predicate: ["panel"], descendants: true, isSignal: true }, { propertyName: "contentTemplate", first: true, predicate: ["content"], descendants: true, isSignal: true }], ngImport: i0, template: "<!-- Backdrop y panel van en una plantilla: inline dentro del propio componente\n (default) o, con `mountInOverlay`, montados en el contenedor de overlays de\n CDK para escapar de un ancestro con `container-type`, `transform` o `contain`. -->\n<ng-template #content>\n @if (open()) {\n <button\n type=\"button\"\n class=\"kf-drawer__overlay\"\n [class.kf-drawer__overlay--sheet]=\"side() === 'bottom'\"\n animate.leave=\"kf-drawer__overlay--leave\"\n [attr.aria-label]=\"resolvedCloseLabel()\"\n [attr.tabindex]=\"role() === 'dialog' ? -1 : null\"\n (click)=\"open.set(false)\"\n ></button>\n }\n\n <!-- Un <div> con rol expl\u00EDcito (no <nav>): un mismo panel puede ser\n navegaci\u00F3n o di\u00E1logo, y <nav> no admite role=\"dialog\". -->\n <div\n #panel\n class=\"kf-drawer__panel\"\n [class.kf-drawer__panel--open]=\"open()\"\n [class.kf-drawer__panel--right]=\"side() === 'right'\"\n [class.kf-drawer__panel--bottom]=\"side() === 'bottom'\"\n [class.kf-drawer__panel--size-md]=\"side() !== 'bottom' && size() === 'md'\"\n [class.kf-drawer__panel--size-lg]=\"side() !== 'bottom' && size() === 'lg'\"\n [class.kf-drawer__panel--sheet-full]=\"side() === 'bottom' && sheetSize() === 'full'\"\n [class.kf-drawer__panel--sheet-medium]=\"side() === 'bottom' && detent() === 'medium'\"\n [class.kf-drawer__panel--sheet-large]=\"side() === 'bottom' && detent() === 'large'\"\n [class.kf-drawer__panel--sheet-readable]=\"side() === 'bottom' && sheetWidth() === 'readable'\"\n [class.kf-drawer__panel--flush]=\"flush()\"\n [class.kf-drawer__panel--dialog]=\"role() === 'dialog'\"\n [class.kf-drawer__panel--overlay]=\"mountInOverlay()\"\n [attr.role]=\"role()\"\n [attr.aria-modal]=\"role() === 'dialog' ? 'true' : null\"\n [attr.aria-label]=\"hasTitleBar() ? null : resolvedAriaLabel()\"\n [attr.aria-labelledby]=\"hasTitleBar() ? titleId : null\"\n [attr.aria-hidden]=\"!open()\"\n >\n @if (side() === 'bottom') {\n <div\n class=\"kf-drawer__grip\"\n aria-hidden=\"true\"\n (pointerdown)=\"onDragStart($event)\"\n (pointermove)=\"onDragMove($event)\"\n (pointerup)=\"onDragEnd($event)\"\n (pointercancel)=\"onDragCancel()\"\n ></div>\n }\n @if (hasTitleBar()) {\n <div\n class=\"kf-drawer__titlebar\"\n (pointerdown)=\"onDragStart($event)\"\n (pointermove)=\"onDragMove($event)\"\n (pointerup)=\"onDragEnd($event)\"\n (pointercancel)=\"onDragCancel()\"\n >\n @if (titleSlot()) {\n <h2 class=\"kf-drawer__title kf-drawer__title--slot\" [id]=\"titleId\">\n <ng-content select=\"[kfDrawerTitle]\" />\n </h2>\n } @else {\n <h2 class=\"kf-drawer__title\" [id]=\"titleId\">{{ title() }}</h2>\n }\n <div class=\"kf-drawer__controls\">\n <ng-content select=\"[kf-drawer-actions]\" />\n <kf-button\n class=\"kf-drawer__close\"\n type=\"button\"\n variant=\"ghost\"\n size=\"sm\"\n icon=\"x\"\n [ariaLabel]=\"resolvedCloseLabel()\"\n (click)=\"open.set(false)\"\n />\n </div>\n </div>\n }\n <div class=\"kf-drawer__header\"><ng-content select=\"[kf-drawer-header]\" /></div>\n <div class=\"kf-drawer__body\"><ng-content /></div>\n <div class=\"kf-drawer__footer\"><ng-content select=\"[kf-drawer-footer]\" /></div>\n </div>\n</ng-template>\n\n@if (!mountInOverlay()) {\n <ng-container [ngTemplateOutlet]=\"content\" />\n}\n", styles: [".kf-drawer__overlay{position:fixed;inset:0;border:none;padding:0;cursor:pointer;background:var(--kf-drawer-scrim, var(--kf-scrim, rgba(23, 29, 37, .4)));backdrop-filter:var(--kf-drawer-backdrop-filter, blur(4px));-webkit-backdrop-filter:var(--kf-drawer-backdrop-filter, blur(4px));z-index:39;animation:kf-drawer-fade-in var(--kf-motion-base, .22s) var(--kf-ease-standard, ease) both}.kf-drawer__overlay--sheet{backdrop-filter:var(--kf-drawer-backdrop-filter, none);-webkit-backdrop-filter:var(--kf-drawer-backdrop-filter, none)}.kf-drawer__overlay--leave{pointer-events:none;animation:kf-drawer-fade-out var(--kf-motion-base, .22s) var(--kf-ease-exit, ease-in) both}@keyframes kf-drawer-fade-in{0%{opacity:0}}@keyframes kf-drawer-fade-out{to{opacity:0}}.kf-drawer__panel{position:fixed;top:0;left:0;bottom:0;z-index:40;display:flex;flex-direction:column;width:82%;max-width:320px;background:var(--kf-color-white);box-shadow:8px 0 24px -8px #1018284d;transform:translate(-100%);visibility:hidden;transition:transform var(--kf-drawer-duration, .24s) var(--kf-ease-spring-ish, cubic-bezier(.32, .72, 0, 1)),visibility 0s linear var(--kf-drawer-duration, .24s)}.kf-drawer__panel--overlay{font-family:var(--kf-font-body)}.kf-drawer__panel--right{left:auto;right:0;box-shadow:-8px 0 24px -8px #1018284d;transform:translate(100%)}.kf-drawer__panel--dialog{width:min(var(--kf-drawer-width, 480px),100vw);max-width:none}@media(max-width:640px){.kf-drawer__panel--dialog{width:100vw}}.kf-drawer__panel--size-md{width:min(var(--kf-drawer-width-md, 640px),94vw);max-width:none}.kf-drawer__panel--size-lg{width:min(var(--kf-drawer-width-lg, 880px),70vw);max-width:none}@media(max-width:600px){.kf-drawer__panel--size-md,.kf-drawer__panel--size-lg{width:100vw}}.kf-drawer__panel--bottom{--kf-drawer-duration: var(--kf-motion-slow, .32s);top:auto;right:0;bottom:var(--kf-keyboard-inset, 0px);width:100%;max-width:none;max-height:min(var(--kf-drawer-sheet-max-height, 80vh),calc(100dvh - var(--kf-keyboard-inset, 0px) - env(safe-area-inset-top,0px)));border-radius:var(--kf-drawer-sheet-radius, var(--kf-radius-lg)) var(--kf-drawer-sheet-radius, var(--kf-radius-lg)) 0 0;box-shadow:var(--kf-elevation-sheet, var(--kf-shadow-lg));padding-bottom:max(0px,calc(env(safe-area-inset-bottom,0px) - var(--kf-keyboard-inset, 0px)));padding-left:env(safe-area-inset-left,0px);padding-right:env(safe-area-inset-right,0px);transform:translateY(100%)}.kf-drawer__panel--sheet-medium,.kf-drawer__panel--sheet-large{max-height:none}.kf-drawer__panel--sheet-medium{height:min(var(--kf-drawer-sheet-medium-height, 50dvh),calc(100dvh - var(--kf-keyboard-inset, 0px) - env(safe-area-inset-top,0px)))}.kf-drawer__panel--sheet-large{height:calc(100dvh - var(--kf-drawer-sheet-large-gap, 24px) - env(safe-area-inset-top,0px) - var(--kf-keyboard-inset, 0px))}.kf-drawer__panel--sheet-medium.kf-drawer__panel--open,.kf-drawer__panel--sheet-large.kf-drawer__panel--open{transition:transform var(--kf-drawer-duration) var(--kf-ease-spring-ish, cubic-bezier(.32, .72, 0, 1)),height var(--kf-drawer-duration) var(--kf-ease-spring-ish, cubic-bezier(.32, .72, 0, 1)),visibility 0s linear 0s}@media(min-width:640px){.kf-drawer__panel--sheet-readable:not(.kf-drawer__panel--sheet-full){left:max(0px,calc((100% - var(--kf-drawer-sheet-readable-width, 600px)) / 2));right:max(0px,calc((100% - var(--kf-drawer-sheet-readable-width, 600px)) / 2));width:auto}}.kf-drawer__panel--sheet-full{height:100vh;height:calc(100dvh - var(--kf-keyboard-inset, 0px));max-height:none;border-radius:0}@media(orientation:landscape)and (max-height:500px){.kf-drawer__panel--bottom:not(.kf-drawer__panel--sheet-full){max-height:94vh}}.kf-drawer__panel--bottom .kf-drawer__grip,.kf-drawer__panel--bottom .kf-drawer__titlebar{touch-action:none}.kf-drawer__panel--open{transform:none;visibility:visible;transition:transform var(--kf-drawer-duration, .24s) var(--kf-ease-spring-ish, cubic-bezier(.32, .72, 0, 1)),visibility 0s linear 0s}.kf-drawer__panel--bottom.kf-drawer__panel--open{transform:none}@media(prefers-reduced-motion:reduce){.kf-drawer__panel,.kf-drawer__panel--open{transition:none}.kf-drawer__overlay,.kf-drawer__overlay--leave{animation:none}}.kf-drawer__grip{position:relative;flex:none;align-self:center;width:36px;height:4px;margin-top:var(--kf-space-sm);border-radius:var(--kf-radius-pill);background:var(--kf-color-border-strong)}.kf-drawer__grip:before{content:\"\";position:absolute;inset:-12px -32px}.kf-drawer__titlebar{flex:none;display:flex;align-items:center;justify-content:space-between;gap:var(--kf-space-sm);padding:var(--kf-space-sm) var(--kf-space-sm) var(--kf-space-sm) var(--kf-space-lg);border-bottom:1px solid var(--kf-color-border)}.kf-drawer__title{margin:0;min-width:0;font-family:var(--kf-font-title);font-size:var(--kf-font-size-title-sm);font-weight:700;line-height:1.25;color:var(--kf-color-ink)}.kf-drawer__title--slot{display:flex;flex-wrap:wrap;align-items:center;gap:var(--kf-space-xs) var(--kf-space-sm)}.kf-drawer__controls{flex:none;display:flex;align-items:center;gap:var(--kf-space-xs)}.kf-drawer__close{flex:none}@media(pointer:coarse),(max-width:760px){.kf-drawer__close{--kf-button-min-height: 44px;min-width:44px}}.kf-drawer__header:empty,.kf-drawer__footer:empty{display:none}.kf-drawer__header{padding:var(--kf-space-lg);background:var(--kf-color-tertiary-deep)}.kf-drawer__body{flex:1 1 auto;min-height:0;overscroll-behavior:contain;display:flex;flex-direction:column;gap:var(--kf-drawer-body-gap, var(--kf-space-xs));padding:var(--kf-drawer-body-padding, var(--kf-space-lg));overflow-y:auto}.kf-drawer__panel--dialog .kf-drawer__body{gap:var(--kf-drawer-body-gap, var(--kf-space-lg))}.kf-drawer__panel--flush .kf-drawer__body{gap:0;padding:0 0 var(--kf-space-md)}.kf-drawer__footer{flex:none;padding:var(--kf-space-lg);border-top:1px solid var(--kf-color-border)}.kf-drawer__panel--dialog .kf-drawer__footer{padding:var(--kf-space-md) var(--kf-space-lg)}\n"], dependencies: [{ kind: "component", type: Button, selector: "kf-button", inputs: ["variant", "size", "shape", "disabled", "type", "icon", "block", "loading", "ariaLabel", "ariaExpanded", "ariaPressed", "ariaDisabled", "ariaDescribedby", "attention", "ariaControls", "ariaHaspopup"], outputs: ["disabledClick"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }] });
|
|
2434
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: Drawer, isStandalone: true, selector: "kf-drawer", inputs: { open: { classPropertyName: "open", publicName: "open", isSignal: true, isRequired: false, transformFunction: null }, side: { classPropertyName: "side", publicName: "side", isSignal: true, isRequired: false, transformFunction: null }, role: { classPropertyName: "role", publicName: "role", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, closeLabel: { classPropertyName: "closeLabel", publicName: "closeLabel", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, sheetSize: { classPropertyName: "sheetSize", publicName: "sheetSize", isSignal: true, isRequired: false, transformFunction: null }, expandable: { classPropertyName: "expandable", publicName: "expandable", isSignal: true, isRequired: false, transformFunction: null }, sheetWidth: { classPropertyName: "sheetWidth", publicName: "sheetWidth", isSignal: true, isRequired: false, transformFunction: null }, flush: { classPropertyName: "flush", publicName: "flush", isSignal: true, isRequired: false, transformFunction: null }, swipeToClose: { classPropertyName: "swipeToClose", publicName: "swipeToClose", isSignal: true, isRequired: false, transformFunction: null }, closeOnBack: { classPropertyName: "closeOnBack", publicName: "closeOnBack", isSignal: true, isRequired: false, transformFunction: null }, mountInOverlay: { classPropertyName: "mountInOverlay", publicName: "mountInOverlay", isSignal: true, isRequired: false, transformFunction: null }, closeGuard: { classPropertyName: "closeGuard", publicName: "closeGuard", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { open: "openChange", closedAfterBack: "closedAfterBack", detentChange: "detentChange" }, host: { listeners: { "window:popstate": "onPopState()", "document:keydown.escape": "onEscape($event)" }, properties: { "attr.role": "null", "attr.title": "null" } }, queries: [{ propertyName: "titleSlot", first: true, predicate: DrawerTitle, isSignal: true }], viewQueries: [{ propertyName: "panelRef", first: true, predicate: ["panel"], descendants: true, isSignal: true }, { propertyName: "contentTemplate", first: true, predicate: ["content"], descendants: true, isSignal: true }], ngImport: i0, template: "<!-- Backdrop y panel van en una plantilla: inline dentro del propio componente\n (default) o, con `mountInOverlay`, montados en el contenedor de overlays de\n CDK para escapar de un ancestro con `container-type`, `transform` o `contain`. -->\n<ng-template #content>\n @if (open()) {\n <button\n type=\"button\"\n class=\"kf-drawer__overlay\"\n [class.kf-drawer__overlay--sheet]=\"side() === 'bottom'\"\n animate.leave=\"kf-drawer__overlay--leave\"\n [attr.aria-label]=\"resolvedCloseLabel()\"\n [attr.tabindex]=\"role() === 'dialog' ? -1 : null\"\n (click)=\"onDismiss()\"\n ></button>\n }\n\n <!-- Un <div> con rol expl\u00EDcito (no <nav>): un mismo panel puede ser\n navegaci\u00F3n o di\u00E1logo, y <nav> no admite role=\"dialog\". -->\n <div\n #panel\n class=\"kf-drawer__panel\"\n [class.kf-drawer__panel--open]=\"open()\"\n [class.kf-drawer__panel--right]=\"side() === 'right'\"\n [class.kf-drawer__panel--bottom]=\"side() === 'bottom'\"\n [class.kf-drawer__panel--size-sm]=\"side() !== 'bottom' && size() === 'sm'\"\n [class.kf-drawer__panel--size-md]=\"side() !== 'bottom' && size() === 'md'\"\n [class.kf-drawer__panel--size-lg]=\"side() !== 'bottom' && size() === 'lg'\"\n [class.kf-drawer__panel--sheet-full]=\"side() === 'bottom' && sheetSize() === 'full'\"\n [class.kf-drawer__panel--sheet-medium]=\"side() === 'bottom' && detent() === 'medium'\"\n [class.kf-drawer__panel--sheet-large]=\"side() === 'bottom' && detent() === 'large'\"\n [class.kf-drawer__panel--sheet-readable]=\"side() === 'bottom' && sheetWidth() === 'readable'\"\n [class.kf-drawer__panel--flush]=\"flush()\"\n [class.kf-drawer__panel--dialog]=\"role() === 'dialog'\"\n [class.kf-drawer__panel--overlay]=\"mountInOverlay()\"\n [attr.role]=\"role()\"\n [attr.aria-modal]=\"role() === 'dialog' ? 'true' : null\"\n [attr.aria-label]=\"hasTitleBar() ? null : resolvedAriaLabel()\"\n [attr.aria-labelledby]=\"hasTitleBar() ? titleId : null\"\n [attr.aria-hidden]=\"!open()\"\n >\n @if (side() === 'bottom') {\n <div\n class=\"kf-drawer__grip\"\n aria-hidden=\"true\"\n (pointerdown)=\"onDragStart($event)\"\n (pointermove)=\"onDragMove($event)\"\n (pointerup)=\"onDragEnd($event)\"\n (pointercancel)=\"onDragCancel()\"\n ></div>\n }\n @if (hasTitleBar()) {\n <div\n class=\"kf-drawer__titlebar\"\n (pointerdown)=\"onDragStart($event)\"\n (pointermove)=\"onDragMove($event)\"\n (pointerup)=\"onDragEnd($event)\"\n (pointercancel)=\"onDragCancel()\"\n >\n @if (titleSlot()) {\n <h2 class=\"kf-drawer__title kf-drawer__title--slot\" [id]=\"titleId\">\n <ng-content select=\"[kfDrawerTitle]\" />\n </h2>\n } @else {\n <h2 class=\"kf-drawer__title\" [id]=\"titleId\">{{ title() }}</h2>\n }\n <div class=\"kf-drawer__controls\">\n <ng-content select=\"[kf-drawer-actions]\" />\n <kf-button\n class=\"kf-drawer__close\"\n type=\"button\"\n variant=\"ghost\"\n size=\"sm\"\n icon=\"x\"\n [ariaLabel]=\"resolvedCloseLabel()\"\n (click)=\"onDismiss()\"\n />\n </div>\n </div>\n }\n <div class=\"kf-drawer__header\"><ng-content select=\"[kf-drawer-header]\" /></div>\n <div class=\"kf-drawer__body\"><ng-content /></div>\n <div class=\"kf-drawer__footer\"><ng-content select=\"[kf-drawer-footer]\" /></div>\n </div>\n</ng-template>\n\n@if (!mountInOverlay()) {\n <ng-container [ngTemplateOutlet]=\"content\" />\n}\n", styles: [".kf-drawer__overlay{position:fixed;inset:0;border:none;padding:0;cursor:pointer;background:var(--kf-drawer-scrim, var(--kf-scrim, rgba(23, 29, 37, .4)));backdrop-filter:var(--kf-drawer-backdrop-filter, blur(4px));-webkit-backdrop-filter:var(--kf-drawer-backdrop-filter, blur(4px));z-index:39;animation:kf-drawer-fade-in var(--kf-motion-base, .22s) var(--kf-ease-standard, ease) both}.kf-drawer__overlay--sheet{backdrop-filter:var(--kf-drawer-backdrop-filter, none);-webkit-backdrop-filter:var(--kf-drawer-backdrop-filter, none)}.kf-drawer__overlay--leave{pointer-events:none;animation:kf-drawer-fade-out var(--kf-motion-base, .22s) var(--kf-ease-exit, ease-in) both}@keyframes kf-drawer-fade-in{0%{opacity:0}}@keyframes kf-drawer-fade-out{to{opacity:0}}.kf-drawer__panel{position:fixed;top:0;left:0;bottom:0;z-index:40;display:flex;flex-direction:column;width:82%;max-width:320px;background:var(--kf-color-white);box-shadow:8px 0 24px -8px #1018284d;transform:translate(-100%);visibility:hidden;transition:transform var(--kf-drawer-duration, .24s) var(--kf-ease-spring-ish, cubic-bezier(.32, .72, 0, 1)),visibility 0s linear var(--kf-drawer-duration, .24s)}.kf-drawer__panel--overlay{font-family:var(--kf-font-body)}.kf-drawer__panel--right{left:auto;right:0;box-shadow:-8px 0 24px -8px #1018284d;transform:translate(100%)}.kf-drawer__panel--dialog{width:min(var(--kf-drawer-width, 480px),100vw);max-width:none}@media(max-width:640px){.kf-drawer__panel--dialog{width:100vw}}.kf-drawer__panel--size-sm{width:min(var(--kf-drawer-width-sm, 400px),94vw);max-width:none}.kf-drawer__panel--size-md{width:min(var(--kf-drawer-width-md, 640px),94vw);max-width:none}.kf-drawer__panel--size-lg{width:min(var(--kf-drawer-width-lg, 880px),70vw);max-width:none}@media(max-width:600px){.kf-drawer__panel--size-sm,.kf-drawer__panel--size-md,.kf-drawer__panel--size-lg{width:100vw}}.kf-drawer__panel--bottom{--kf-drawer-duration: var(--kf-motion-slow, .32s);top:auto;right:0;bottom:var(--kf-keyboard-inset, 0px);width:100%;max-width:none;max-height:min(var(--kf-drawer-sheet-max-height, 80vh),calc(100dvh - var(--kf-keyboard-inset, 0px) - env(safe-area-inset-top,0px)));border-radius:var(--kf-drawer-sheet-radius, var(--kf-radius-lg)) var(--kf-drawer-sheet-radius, var(--kf-radius-lg)) 0 0;box-shadow:var(--kf-elevation-sheet, var(--kf-shadow-lg));padding-bottom:max(0px,calc(env(safe-area-inset-bottom,0px) - var(--kf-keyboard-inset, 0px)));padding-left:env(safe-area-inset-left,0px);padding-right:env(safe-area-inset-right,0px);transform:translateY(100%)}.kf-drawer__panel--sheet-medium,.kf-drawer__panel--sheet-large{max-height:none}.kf-drawer__panel--sheet-medium{height:min(var(--kf-drawer-sheet-medium-height, 50dvh),calc(100dvh - var(--kf-keyboard-inset, 0px) - env(safe-area-inset-top,0px)))}.kf-drawer__panel--sheet-large{height:calc(100dvh - var(--kf-drawer-sheet-large-gap, 24px) - env(safe-area-inset-top,0px) - var(--kf-keyboard-inset, 0px))}.kf-drawer__panel--sheet-medium.kf-drawer__panel--open,.kf-drawer__panel--sheet-large.kf-drawer__panel--open{transition:transform var(--kf-drawer-duration) var(--kf-ease-spring-ish, cubic-bezier(.32, .72, 0, 1)),height var(--kf-drawer-duration) var(--kf-ease-spring-ish, cubic-bezier(.32, .72, 0, 1)),visibility 0s linear 0s}@media(min-width:640px){.kf-drawer__panel--sheet-readable:not(.kf-drawer__panel--sheet-full){left:max(0px,calc((100% - var(--kf-drawer-sheet-readable-width, 600px)) / 2));right:max(0px,calc((100% - var(--kf-drawer-sheet-readable-width, 600px)) / 2));width:auto}}.kf-drawer__panel--sheet-full{height:100vh;height:calc(100dvh - var(--kf-keyboard-inset, 0px));max-height:none;border-radius:0}@media(orientation:landscape)and (max-height:500px){.kf-drawer__panel--bottom:not(.kf-drawer__panel--sheet-full){max-height:94vh}}.kf-drawer__panel--bottom .kf-drawer__grip,.kf-drawer__panel--bottom .kf-drawer__titlebar{touch-action:none}.kf-drawer__panel--open{transform:none;visibility:visible;transition:transform var(--kf-drawer-duration, .24s) var(--kf-ease-spring-ish, cubic-bezier(.32, .72, 0, 1)),visibility 0s linear 0s}.kf-drawer__panel--bottom.kf-drawer__panel--open{transform:none}@media(prefers-reduced-motion:reduce){.kf-drawer__panel,.kf-drawer__panel--open{transition:none}.kf-drawer__overlay,.kf-drawer__overlay--leave{animation:none}}.kf-drawer__grip{position:relative;flex:none;align-self:center;width:36px;height:4px;margin-top:var(--kf-space-sm);border-radius:var(--kf-radius-pill);background:var(--kf-color-border-strong)}.kf-drawer__grip:before{content:\"\";position:absolute;inset:-12px -32px}.kf-drawer__titlebar{flex:none;display:flex;align-items:center;justify-content:space-between;gap:var(--kf-space-sm);padding:var(--kf-space-sm) var(--kf-space-sm) var(--kf-space-sm) var(--kf-space-lg);border-bottom:1px solid var(--kf-color-border)}.kf-drawer__title{margin:0;min-width:0;font-family:var(--kf-font-title);font-size:var(--kf-font-size-title-sm);font-weight:700;line-height:1.25;color:var(--kf-color-ink);overflow-wrap:anywhere}.kf-drawer__title--slot{display:flex;flex-wrap:wrap;align-items:center;gap:var(--kf-space-xs) var(--kf-space-sm)}.kf-drawer__controls{flex:none;display:flex;align-items:center;gap:var(--kf-space-xs)}.kf-drawer__close{flex:none}@media(pointer:coarse),(max-width:760px){.kf-drawer__close{--kf-button-min-height: 44px;min-width:44px}}.kf-drawer__header:empty,.kf-drawer__footer:empty{display:none}.kf-drawer__header{padding:var(--kf-space-lg);background:var(--kf-color-tertiary-deep)}.kf-drawer__body{flex:1 1 auto;min-height:0;overscroll-behavior:contain;display:flex;flex-direction:column;gap:var(--kf-drawer-body-gap, var(--kf-space-xs));padding:var(--kf-drawer-body-padding, var(--kf-space-lg));overflow-y:auto;scroll-padding-block:var(--kf-space-sm)}.kf-drawer__panel--dialog .kf-drawer__body{gap:var(--kf-drawer-body-gap, var(--kf-space-lg))}.kf-drawer__panel--flush .kf-drawer__body{gap:0;padding:0 0 var(--kf-space-md)}.kf-drawer__footer{flex:none;padding:var(--kf-space-lg);border-top:1px solid var(--kf-color-border)}.kf-drawer__panel--dialog .kf-drawer__footer{padding:var(--kf-space-md) var(--kf-space-lg)}\n"], dependencies: [{ kind: "component", type: Button, selector: "kf-button", inputs: ["variant", "size", "shape", "disabled", "type", "icon", "block", "loading", "ariaLabel", "ariaExpanded", "ariaPressed", "ariaDisabled", "ariaDescribedby", "attention", "ariaControls", "ariaHaspopup"], outputs: ["disabledClick"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }] });
|
|
2343
2435
|
}
|
|
2344
2436
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: Drawer, decorators: [{
|
|
2345
2437
|
type: Component,
|
|
@@ -2351,8 +2443,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
2351
2443
|
'[attr.role]': 'null',
|
|
2352
2444
|
'[attr.title]': 'null',
|
|
2353
2445
|
'(window:popstate)': 'onPopState()',
|
|
2354
|
-
}, template: "<!-- Backdrop y panel van en una plantilla: inline dentro del propio componente\n (default) o, con `mountInOverlay`, montados en el contenedor de overlays de\n CDK para escapar de un ancestro con `container-type`, `transform` o `contain`. -->\n<ng-template #content>\n @if (open()) {\n <button\n type=\"button\"\n class=\"kf-drawer__overlay\"\n [class.kf-drawer__overlay--sheet]=\"side() === 'bottom'\"\n animate.leave=\"kf-drawer__overlay--leave\"\n [attr.aria-label]=\"resolvedCloseLabel()\"\n [attr.tabindex]=\"role() === 'dialog' ? -1 : null\"\n (click)=\"
|
|
2355
|
-
}], ctorParameters: () => [], propDecorators: { open: [{ type: i0.Input, args: [{ isSignal: true, alias: "open", required: false }] }, { type: i0.Output, args: ["openChange"] }], side: [{ type: i0.Input, args: [{ isSignal: true, alias: "side", required: false }] }], role: [{ type: i0.Input, args: [{ isSignal: true, alias: "role", required: false }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], closeLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "closeLabel", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], sheetSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "sheetSize", required: false }] }], expandable: [{ type: i0.Input, args: [{ isSignal: true, alias: "expandable", required: false }] }], sheetWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "sheetWidth", required: false }] }], flush: [{ type: i0.Input, args: [{ isSignal: true, alias: "flush", required: false }] }], swipeToClose: [{ type: i0.Input, args: [{ isSignal: true, alias: "swipeToClose", required: false }] }], closeOnBack: [{ type: i0.Input, args: [{ isSignal: true, alias: "closeOnBack", required: false }] }], mountInOverlay: [{ type: i0.Input, args: [{ isSignal: true, alias: "mountInOverlay", required: false }] }], closedAfterBack: [{ type: i0.Output, args: ["closedAfterBack"] }], detentChange: [{ type: i0.Output, args: ["detentChange"] }], titleSlot: [{ type: i0.ContentChild, args: [i0.forwardRef(() => DrawerTitle), { ...{ descendants: false }, isSignal: true }] }], panelRef: [{ type: i0.ViewChild, args: ['panel', { isSignal: true }] }], contentTemplate: [{ type: i0.ViewChild, args: ['content', { isSignal: true }] }], onEscape: [{
|
|
2446
|
+
}, template: "<!-- Backdrop y panel van en una plantilla: inline dentro del propio componente\n (default) o, con `mountInOverlay`, montados en el contenedor de overlays de\n CDK para escapar de un ancestro con `container-type`, `transform` o `contain`. -->\n<ng-template #content>\n @if (open()) {\n <button\n type=\"button\"\n class=\"kf-drawer__overlay\"\n [class.kf-drawer__overlay--sheet]=\"side() === 'bottom'\"\n animate.leave=\"kf-drawer__overlay--leave\"\n [attr.aria-label]=\"resolvedCloseLabel()\"\n [attr.tabindex]=\"role() === 'dialog' ? -1 : null\"\n (click)=\"onDismiss()\"\n ></button>\n }\n\n <!-- Un <div> con rol expl\u00EDcito (no <nav>): un mismo panel puede ser\n navegaci\u00F3n o di\u00E1logo, y <nav> no admite role=\"dialog\". -->\n <div\n #panel\n class=\"kf-drawer__panel\"\n [class.kf-drawer__panel--open]=\"open()\"\n [class.kf-drawer__panel--right]=\"side() === 'right'\"\n [class.kf-drawer__panel--bottom]=\"side() === 'bottom'\"\n [class.kf-drawer__panel--size-sm]=\"side() !== 'bottom' && size() === 'sm'\"\n [class.kf-drawer__panel--size-md]=\"side() !== 'bottom' && size() === 'md'\"\n [class.kf-drawer__panel--size-lg]=\"side() !== 'bottom' && size() === 'lg'\"\n [class.kf-drawer__panel--sheet-full]=\"side() === 'bottom' && sheetSize() === 'full'\"\n [class.kf-drawer__panel--sheet-medium]=\"side() === 'bottom' && detent() === 'medium'\"\n [class.kf-drawer__panel--sheet-large]=\"side() === 'bottom' && detent() === 'large'\"\n [class.kf-drawer__panel--sheet-readable]=\"side() === 'bottom' && sheetWidth() === 'readable'\"\n [class.kf-drawer__panel--flush]=\"flush()\"\n [class.kf-drawer__panel--dialog]=\"role() === 'dialog'\"\n [class.kf-drawer__panel--overlay]=\"mountInOverlay()\"\n [attr.role]=\"role()\"\n [attr.aria-modal]=\"role() === 'dialog' ? 'true' : null\"\n [attr.aria-label]=\"hasTitleBar() ? null : resolvedAriaLabel()\"\n [attr.aria-labelledby]=\"hasTitleBar() ? titleId : null\"\n [attr.aria-hidden]=\"!open()\"\n >\n @if (side() === 'bottom') {\n <div\n class=\"kf-drawer__grip\"\n aria-hidden=\"true\"\n (pointerdown)=\"onDragStart($event)\"\n (pointermove)=\"onDragMove($event)\"\n (pointerup)=\"onDragEnd($event)\"\n (pointercancel)=\"onDragCancel()\"\n ></div>\n }\n @if (hasTitleBar()) {\n <div\n class=\"kf-drawer__titlebar\"\n (pointerdown)=\"onDragStart($event)\"\n (pointermove)=\"onDragMove($event)\"\n (pointerup)=\"onDragEnd($event)\"\n (pointercancel)=\"onDragCancel()\"\n >\n @if (titleSlot()) {\n <h2 class=\"kf-drawer__title kf-drawer__title--slot\" [id]=\"titleId\">\n <ng-content select=\"[kfDrawerTitle]\" />\n </h2>\n } @else {\n <h2 class=\"kf-drawer__title\" [id]=\"titleId\">{{ title() }}</h2>\n }\n <div class=\"kf-drawer__controls\">\n <ng-content select=\"[kf-drawer-actions]\" />\n <kf-button\n class=\"kf-drawer__close\"\n type=\"button\"\n variant=\"ghost\"\n size=\"sm\"\n icon=\"x\"\n [ariaLabel]=\"resolvedCloseLabel()\"\n (click)=\"onDismiss()\"\n />\n </div>\n </div>\n }\n <div class=\"kf-drawer__header\"><ng-content select=\"[kf-drawer-header]\" /></div>\n <div class=\"kf-drawer__body\"><ng-content /></div>\n <div class=\"kf-drawer__footer\"><ng-content select=\"[kf-drawer-footer]\" /></div>\n </div>\n</ng-template>\n\n@if (!mountInOverlay()) {\n <ng-container [ngTemplateOutlet]=\"content\" />\n}\n", styles: [".kf-drawer__overlay{position:fixed;inset:0;border:none;padding:0;cursor:pointer;background:var(--kf-drawer-scrim, var(--kf-scrim, rgba(23, 29, 37, .4)));backdrop-filter:var(--kf-drawer-backdrop-filter, blur(4px));-webkit-backdrop-filter:var(--kf-drawer-backdrop-filter, blur(4px));z-index:39;animation:kf-drawer-fade-in var(--kf-motion-base, .22s) var(--kf-ease-standard, ease) both}.kf-drawer__overlay--sheet{backdrop-filter:var(--kf-drawer-backdrop-filter, none);-webkit-backdrop-filter:var(--kf-drawer-backdrop-filter, none)}.kf-drawer__overlay--leave{pointer-events:none;animation:kf-drawer-fade-out var(--kf-motion-base, .22s) var(--kf-ease-exit, ease-in) both}@keyframes kf-drawer-fade-in{0%{opacity:0}}@keyframes kf-drawer-fade-out{to{opacity:0}}.kf-drawer__panel{position:fixed;top:0;left:0;bottom:0;z-index:40;display:flex;flex-direction:column;width:82%;max-width:320px;background:var(--kf-color-white);box-shadow:8px 0 24px -8px #1018284d;transform:translate(-100%);visibility:hidden;transition:transform var(--kf-drawer-duration, .24s) var(--kf-ease-spring-ish, cubic-bezier(.32, .72, 0, 1)),visibility 0s linear var(--kf-drawer-duration, .24s)}.kf-drawer__panel--overlay{font-family:var(--kf-font-body)}.kf-drawer__panel--right{left:auto;right:0;box-shadow:-8px 0 24px -8px #1018284d;transform:translate(100%)}.kf-drawer__panel--dialog{width:min(var(--kf-drawer-width, 480px),100vw);max-width:none}@media(max-width:640px){.kf-drawer__panel--dialog{width:100vw}}.kf-drawer__panel--size-sm{width:min(var(--kf-drawer-width-sm, 400px),94vw);max-width:none}.kf-drawer__panel--size-md{width:min(var(--kf-drawer-width-md, 640px),94vw);max-width:none}.kf-drawer__panel--size-lg{width:min(var(--kf-drawer-width-lg, 880px),70vw);max-width:none}@media(max-width:600px){.kf-drawer__panel--size-sm,.kf-drawer__panel--size-md,.kf-drawer__panel--size-lg{width:100vw}}.kf-drawer__panel--bottom{--kf-drawer-duration: var(--kf-motion-slow, .32s);top:auto;right:0;bottom:var(--kf-keyboard-inset, 0px);width:100%;max-width:none;max-height:min(var(--kf-drawer-sheet-max-height, 80vh),calc(100dvh - var(--kf-keyboard-inset, 0px) - env(safe-area-inset-top,0px)));border-radius:var(--kf-drawer-sheet-radius, var(--kf-radius-lg)) var(--kf-drawer-sheet-radius, var(--kf-radius-lg)) 0 0;box-shadow:var(--kf-elevation-sheet, var(--kf-shadow-lg));padding-bottom:max(0px,calc(env(safe-area-inset-bottom,0px) - var(--kf-keyboard-inset, 0px)));padding-left:env(safe-area-inset-left,0px);padding-right:env(safe-area-inset-right,0px);transform:translateY(100%)}.kf-drawer__panel--sheet-medium,.kf-drawer__panel--sheet-large{max-height:none}.kf-drawer__panel--sheet-medium{height:min(var(--kf-drawer-sheet-medium-height, 50dvh),calc(100dvh - var(--kf-keyboard-inset, 0px) - env(safe-area-inset-top,0px)))}.kf-drawer__panel--sheet-large{height:calc(100dvh - var(--kf-drawer-sheet-large-gap, 24px) - env(safe-area-inset-top,0px) - var(--kf-keyboard-inset, 0px))}.kf-drawer__panel--sheet-medium.kf-drawer__panel--open,.kf-drawer__panel--sheet-large.kf-drawer__panel--open{transition:transform var(--kf-drawer-duration) var(--kf-ease-spring-ish, cubic-bezier(.32, .72, 0, 1)),height var(--kf-drawer-duration) var(--kf-ease-spring-ish, cubic-bezier(.32, .72, 0, 1)),visibility 0s linear 0s}@media(min-width:640px){.kf-drawer__panel--sheet-readable:not(.kf-drawer__panel--sheet-full){left:max(0px,calc((100% - var(--kf-drawer-sheet-readable-width, 600px)) / 2));right:max(0px,calc((100% - var(--kf-drawer-sheet-readable-width, 600px)) / 2));width:auto}}.kf-drawer__panel--sheet-full{height:100vh;height:calc(100dvh - var(--kf-keyboard-inset, 0px));max-height:none;border-radius:0}@media(orientation:landscape)and (max-height:500px){.kf-drawer__panel--bottom:not(.kf-drawer__panel--sheet-full){max-height:94vh}}.kf-drawer__panel--bottom .kf-drawer__grip,.kf-drawer__panel--bottom .kf-drawer__titlebar{touch-action:none}.kf-drawer__panel--open{transform:none;visibility:visible;transition:transform var(--kf-drawer-duration, .24s) var(--kf-ease-spring-ish, cubic-bezier(.32, .72, 0, 1)),visibility 0s linear 0s}.kf-drawer__panel--bottom.kf-drawer__panel--open{transform:none}@media(prefers-reduced-motion:reduce){.kf-drawer__panel,.kf-drawer__panel--open{transition:none}.kf-drawer__overlay,.kf-drawer__overlay--leave{animation:none}}.kf-drawer__grip{position:relative;flex:none;align-self:center;width:36px;height:4px;margin-top:var(--kf-space-sm);border-radius:var(--kf-radius-pill);background:var(--kf-color-border-strong)}.kf-drawer__grip:before{content:\"\";position:absolute;inset:-12px -32px}.kf-drawer__titlebar{flex:none;display:flex;align-items:center;justify-content:space-between;gap:var(--kf-space-sm);padding:var(--kf-space-sm) var(--kf-space-sm) var(--kf-space-sm) var(--kf-space-lg);border-bottom:1px solid var(--kf-color-border)}.kf-drawer__title{margin:0;min-width:0;font-family:var(--kf-font-title);font-size:var(--kf-font-size-title-sm);font-weight:700;line-height:1.25;color:var(--kf-color-ink);overflow-wrap:anywhere}.kf-drawer__title--slot{display:flex;flex-wrap:wrap;align-items:center;gap:var(--kf-space-xs) var(--kf-space-sm)}.kf-drawer__controls{flex:none;display:flex;align-items:center;gap:var(--kf-space-xs)}.kf-drawer__close{flex:none}@media(pointer:coarse),(max-width:760px){.kf-drawer__close{--kf-button-min-height: 44px;min-width:44px}}.kf-drawer__header:empty,.kf-drawer__footer:empty{display:none}.kf-drawer__header{padding:var(--kf-space-lg);background:var(--kf-color-tertiary-deep)}.kf-drawer__body{flex:1 1 auto;min-height:0;overscroll-behavior:contain;display:flex;flex-direction:column;gap:var(--kf-drawer-body-gap, var(--kf-space-xs));padding:var(--kf-drawer-body-padding, var(--kf-space-lg));overflow-y:auto;scroll-padding-block:var(--kf-space-sm)}.kf-drawer__panel--dialog .kf-drawer__body{gap:var(--kf-drawer-body-gap, var(--kf-space-lg))}.kf-drawer__panel--flush .kf-drawer__body{gap:0;padding:0 0 var(--kf-space-md)}.kf-drawer__footer{flex:none;padding:var(--kf-space-lg);border-top:1px solid var(--kf-color-border)}.kf-drawer__panel--dialog .kf-drawer__footer{padding:var(--kf-space-md) var(--kf-space-lg)}\n"] }]
|
|
2447
|
+
}], ctorParameters: () => [], propDecorators: { open: [{ type: i0.Input, args: [{ isSignal: true, alias: "open", required: false }] }, { type: i0.Output, args: ["openChange"] }], side: [{ type: i0.Input, args: [{ isSignal: true, alias: "side", required: false }] }], role: [{ type: i0.Input, args: [{ isSignal: true, alias: "role", required: false }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], closeLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "closeLabel", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], sheetSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "sheetSize", required: false }] }], expandable: [{ type: i0.Input, args: [{ isSignal: true, alias: "expandable", required: false }] }], sheetWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "sheetWidth", required: false }] }], flush: [{ type: i0.Input, args: [{ isSignal: true, alias: "flush", required: false }] }], swipeToClose: [{ type: i0.Input, args: [{ isSignal: true, alias: "swipeToClose", required: false }] }], closeOnBack: [{ type: i0.Input, args: [{ isSignal: true, alias: "closeOnBack", required: false }] }], mountInOverlay: [{ type: i0.Input, args: [{ isSignal: true, alias: "mountInOverlay", required: false }] }], closeGuard: [{ type: i0.Input, args: [{ isSignal: true, alias: "closeGuard", required: false }] }], closedAfterBack: [{ type: i0.Output, args: ["closedAfterBack"] }], detentChange: [{ type: i0.Output, args: ["detentChange"] }], titleSlot: [{ type: i0.ContentChild, args: [i0.forwardRef(() => DrawerTitle), { ...{ descendants: false }, isSignal: true }] }], panelRef: [{ type: i0.ViewChild, args: ['panel', { isSignal: true }] }], contentTemplate: [{ type: i0.ViewChild, args: ['content', { isSignal: true }] }], onEscape: [{
|
|
2356
2448
|
type: HostListener,
|
|
2357
2449
|
args: ['document:keydown.escape', ['$event']]
|
|
2358
2450
|
}] } });
|
|
@@ -3011,7 +3103,7 @@ class ActionMenu {
|
|
|
3011
3103
|
}
|
|
3012
3104
|
}
|
|
3013
3105
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: ActionMenu, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
3014
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: ActionMenu, isStandalone: true, selector: "kf-action-menu", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", 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 }, iconOnly: { classPropertyName: "iconOnly", publicName: "iconOnly", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: true, transformFunction: null }, presentation: { classPropertyName: "presentation", publicName: "presentation", isSignal: true, isRequired: false, transformFunction: null }, sheetTitle: { classPropertyName: "sheetTitle", publicName: "sheetTitle", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { itemSelect: "itemSelect" }, viewQueries: [{ propertyName: "sheetTemplate", first: true, predicate: ["sheetTemplate"], descendants: true, isSignal: true }, { propertyName: "sheetBody", first: true, predicate: ["sheetBody"], descendants: true, isSignal: true }], ngImport: i0, template: "<ng-template #itemTemplate let-item>\n <kf-dropdown-item\n [icon]=\"item.icon\"\n [tone]=\"item.tone ?? 'neutral'\"\n [disabled]=\"item.disabled ?? false\"\n [description]=\"item.description\"\n [disabledReason]=\"item.disabledReason\"\n [badge]=\"item.badge\"\n [badgeTone]=\"item.badgeTone ?? 'neutral'\"\n [current]=\"item.current ?? false\"\n (click)=\"select(item)\"\n >\n {{ item.label }}\n </kf-dropdown-item>\n</ng-template>\n\n<ng-template #entriesTemplate>\n @for (entry of items(); track $index) {\n @if (asGroup(entry); as group) {\n <kf-dropdown-group [label]=\"group.group\">\n @for (item of group.items; track item.id) {\n <ng-container\n [ngTemplateOutlet]=\"itemTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: item }\"\n />\n }\n </kf-dropdown-group>\n } @else {\n <ng-container\n [ngTemplateOutlet]=\"itemTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: asItem(entry) }\"\n />\n }\n }\n</ng-template>\n\n<kf-dropdown [(open)]=\"menuOpen\">\n <kf-button\n class=\"kf-action-menu__trigger\"\n [variant]=\"variant()\"\n [size]=\"size()\"\n [shape]=\"iconOnly() ? 'circle' : 'rect'\"\n [icon]=\"iconOnly() ? (icon() ?? 'more-vertical') : icon()\"\n [disabled]=\"disabled()\"\n [ariaLabel]=\"iconOnly() ? label() : undefined\"\n [ariaHaspopup]=\"asSheet() ? 'dialog' : 'menu'\"\n [ariaExpanded]=\"expanded()\"\n (click)=\"toggle()\"\n >\n @if (!iconOnly()) {\n {{ label() }}\n <kf-icon name=\"chevron-down\" size=\"sm\" [rotate]=\"expanded() ? 180 : 0\" />\n }\n </kf-button>\n <kf-dropdown-panel width=\"19rem\" [ariaLabel]=\"label()\">\n <ng-container [ngTemplateOutlet]=\"entriesTemplate\" />\n </kf-dropdown-panel>\n</kf-dropdown>\n\n<ng-template #sheetTemplate>\n <kf-drawer side=\"bottom\" role=\"dialog\" [title]=\"sheetTitle() || label()\" [(open)]=\"sheetOpen\">\n <div\n #sheetBody\n class=\"kf-action-menu__sheet\"\n role=\"menu\"\n tabindex=\"-1\"\n [attr.aria-label]=\"label()\"\n (keydown)=\"onSheetKeydown($event)\"\n >\n <ng-container [ngTemplateOutlet]=\"entriesTemplate\" />\n </div>\n </kf-drawer>\n</ng-template>\n", styles: [":host{display:inline-flex}.kf-action-menu__sheet{--kf-control-min-height: 3rem;display:flex;flex-direction:column;outline:none}\n"], dependencies: [{ kind: "component", type: Button, selector: "kf-button", inputs: ["variant", "size", "shape", "disabled", "type", "icon", "block", "loading", "ariaLabel", "ariaExpanded", "ariaPressed", "ariaDisabled", "ariaDescribedby", "attention", "ariaControls", "ariaHaspopup"], outputs: ["disabledClick"] }, { kind: "component", type: Drawer, selector: "kf-drawer", inputs: ["open", "side", "role", "ariaLabel", "title", "closeLabel", "size", "sheetSize", "expandable", "sheetWidth", "flush", "swipeToClose", "closeOnBack", "mountInOverlay"], outputs: ["openChange", "closedAfterBack", "detentChange"] }, { kind: "component", type: Dropdown, selector: "kf-dropdown", inputs: ["open", "anchor", "autoFocus"], outputs: ["openChange"] }, { kind: "component", type: DropdownGroup, selector: "kf-dropdown-group", inputs: ["label"] }, { kind: "component", type: DropdownItem, selector: "kf-dropdown-item", inputs: ["tone", "icon", "disabled", "description", "disabledReason", "badge", "badgeTone", "current", "checked"] }, { kind: "component", type: DropdownPanel, selector: "kf-dropdown-panel", inputs: ["variant", "role", "maxHeight", "width", "ariaLabel"] }, { kind: "component", type: Icon, selector: "kf-icon", inputs: ["name", "size", "rotate", "filled"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
3106
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: ActionMenu, isStandalone: true, selector: "kf-action-menu", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", 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 }, iconOnly: { classPropertyName: "iconOnly", publicName: "iconOnly", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: true, transformFunction: null }, presentation: { classPropertyName: "presentation", publicName: "presentation", isSignal: true, isRequired: false, transformFunction: null }, sheetTitle: { classPropertyName: "sheetTitle", publicName: "sheetTitle", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { itemSelect: "itemSelect" }, viewQueries: [{ propertyName: "sheetTemplate", first: true, predicate: ["sheetTemplate"], descendants: true, isSignal: true }, { propertyName: "sheetBody", first: true, predicate: ["sheetBody"], descendants: true, isSignal: true }], ngImport: i0, template: "<ng-template #itemTemplate let-item>\n <kf-dropdown-item\n [icon]=\"item.icon\"\n [tone]=\"item.tone ?? 'neutral'\"\n [disabled]=\"item.disabled ?? false\"\n [description]=\"item.description\"\n [disabledReason]=\"item.disabledReason\"\n [badge]=\"item.badge\"\n [badgeTone]=\"item.badgeTone ?? 'neutral'\"\n [current]=\"item.current ?? false\"\n (click)=\"select(item)\"\n >\n {{ item.label }}\n </kf-dropdown-item>\n</ng-template>\n\n<ng-template #entriesTemplate>\n @for (entry of items(); track $index) {\n @if (asGroup(entry); as group) {\n <kf-dropdown-group [label]=\"group.group\">\n @for (item of group.items; track item.id) {\n <ng-container\n [ngTemplateOutlet]=\"itemTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: item }\"\n />\n }\n </kf-dropdown-group>\n } @else {\n <ng-container\n [ngTemplateOutlet]=\"itemTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: asItem(entry) }\"\n />\n }\n }\n</ng-template>\n\n<kf-dropdown [(open)]=\"menuOpen\">\n <kf-button\n class=\"kf-action-menu__trigger\"\n [variant]=\"variant()\"\n [size]=\"size()\"\n [shape]=\"iconOnly() ? 'circle' : 'rect'\"\n [icon]=\"iconOnly() ? (icon() ?? 'more-vertical') : icon()\"\n [disabled]=\"disabled()\"\n [ariaLabel]=\"iconOnly() ? label() : undefined\"\n [ariaHaspopup]=\"asSheet() ? 'dialog' : 'menu'\"\n [ariaExpanded]=\"expanded()\"\n (click)=\"toggle()\"\n >\n @if (!iconOnly()) {\n {{ label() }}\n <kf-icon name=\"chevron-down\" size=\"sm\" [rotate]=\"expanded() ? 180 : 0\" />\n }\n </kf-button>\n <kf-dropdown-panel width=\"19rem\" [ariaLabel]=\"label()\">\n <ng-container [ngTemplateOutlet]=\"entriesTemplate\" />\n </kf-dropdown-panel>\n</kf-dropdown>\n\n<ng-template #sheetTemplate>\n <kf-drawer side=\"bottom\" role=\"dialog\" [title]=\"sheetTitle() || label()\" [(open)]=\"sheetOpen\">\n <div\n #sheetBody\n class=\"kf-action-menu__sheet\"\n role=\"menu\"\n tabindex=\"-1\"\n [attr.aria-label]=\"label()\"\n (keydown)=\"onSheetKeydown($event)\"\n >\n <ng-container [ngTemplateOutlet]=\"entriesTemplate\" />\n </div>\n </kf-drawer>\n</ng-template>\n", styles: [":host{display:inline-flex}.kf-action-menu__sheet{--kf-control-min-height: 3rem;display:flex;flex-direction:column;outline:none}\n"], dependencies: [{ kind: "component", type: Button, selector: "kf-button", inputs: ["variant", "size", "shape", "disabled", "type", "icon", "block", "loading", "ariaLabel", "ariaExpanded", "ariaPressed", "ariaDisabled", "ariaDescribedby", "attention", "ariaControls", "ariaHaspopup"], outputs: ["disabledClick"] }, { kind: "component", type: Drawer, selector: "kf-drawer", inputs: ["open", "side", "role", "ariaLabel", "title", "closeLabel", "size", "sheetSize", "expandable", "sheetWidth", "flush", "swipeToClose", "closeOnBack", "mountInOverlay", "closeGuard"], outputs: ["openChange", "closedAfterBack", "detentChange"] }, { kind: "component", type: Dropdown, selector: "kf-dropdown", inputs: ["open", "anchor", "autoFocus"], outputs: ["openChange"] }, { kind: "component", type: DropdownGroup, selector: "kf-dropdown-group", inputs: ["label"] }, { kind: "component", type: DropdownItem, selector: "kf-dropdown-item", inputs: ["tone", "icon", "disabled", "description", "disabledReason", "badge", "badgeTone", "current", "checked"] }, { kind: "component", type: DropdownPanel, selector: "kf-dropdown-panel", inputs: ["variant", "role", "maxHeight", "width", "ariaLabel"] }, { kind: "component", type: Icon, selector: "kf-icon", inputs: ["name", "size", "rotate", "filled"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
3015
3107
|
}
|
|
3016
3108
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: ActionMenu, decorators: [{
|
|
3017
3109
|
type: Component,
|
|
@@ -3896,7 +3988,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
3896
3988
|
}]
|
|
3897
3989
|
}], ctorParameters: () => [], propDecorators: { kfPopover: [{ type: i0.Input, args: [{ isSignal: true, alias: "kfPopover", required: true }] }], kfPopoverPlacement: [{ type: i0.Input, args: [{ isSignal: true, alias: "kfPopoverPlacement", required: false }] }], kfPopoverShowDelay: [{ type: i0.Input, args: [{ isSignal: true, alias: "kfPopoverShowDelay", required: false }] }], kfPopoverHideDelay: [{ type: i0.Input, args: [{ isSignal: true, alias: "kfPopoverHideDelay", required: false }] }], kfPopoverDisabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "kfPopoverDisabled", required: false }] }], kfPopoverInteractive: [{ type: i0.Input, args: [{ isSignal: true, alias: "kfPopoverInteractive", required: false }] }], kfPopoverLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "kfPopoverLabel", required: false }] }], kfPopoverDescribe: [{ type: i0.Input, args: [{ isSignal: true, alias: "kfPopoverDescribe", required: false }] }], kfPopoverTrigger: [{ type: i0.Input, args: [{ isSignal: true, alias: "kfPopoverTrigger", required: false }] }], kfPopoverOpen: [{ type: i0.Input, args: [{ isSignal: true, alias: "kfPopoverOpen", required: false }] }, { type: i0.Output, args: ["kfPopoverOpenChange"] }] } });
|
|
3898
3990
|
|
|
3899
|
-
let nextId$
|
|
3991
|
+
let nextId$9 = 0;
|
|
3900
3992
|
/**
|
|
3901
3993
|
* Marca de un valor inferido por IA: ícono de 16 px junto al dato, con un
|
|
3902
3994
|
* popover que explica el origen al pasar el cursor o al enfocar. Es un
|
|
@@ -3920,7 +4012,7 @@ class AiMark {
|
|
|
3920
4012
|
label = input('Inferido por IA', /* @ts-ignore */
|
|
3921
4013
|
...(ngDevMode ? [{ debugName: "label" }] : /* istanbul ignore next */ []));
|
|
3922
4014
|
still = input(false, { ...(ngDevMode ? { debugName: "still" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
3923
|
-
tipId = `kf-ai-mark-tip-${nextId$
|
|
4015
|
+
tipId = `kf-ai-mark-tip-${nextId$9++}`;
|
|
3924
4016
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: AiMark, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
3925
4017
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.0", type: AiMark, isStandalone: true, selector: "kf-ai-mark", inputs: { tip: { classPropertyName: "tip", publicName: "tip", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, still: { classPropertyName: "still", publicName: "still", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<button\n type=\"button\"\n class=\"kf-ai-mark\"\n kfPopoverPlacement=\"top\"\n [kfPopover]=\"tipTemplate\"\n [kfPopoverDescribe]=\"false\"\n [attr.aria-label]=\"label()\"\n [attr.aria-describedby]=\"tipId\"\n [attr.tabindex]=\"still() ? -1 : null\"\n>\n <kf-icon class=\"kf-ai-mark__icon\" name=\"sparkle\" size=\"sm\" />\n</button>\n<span class=\"kf-sr-only\" [id]=\"tipId\">{{ tip() }}</span>\n<ng-template #tipTemplate>{{ tip() }}</ng-template>\n", styles: [".kf-sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}:host{position:relative;display:inline-flex;flex:none;vertical-align:-3px}.kf-ai-mark{display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;width:24px;height:24px;margin:-4px;padding:0;border:0;background:transparent;border-radius:var(--kf-radius-pill);color:var(--kf-color-ai);font:inherit;cursor:help}.kf-ai-mark:focus-visible{outline:none;box-shadow:var(--kf-shadow-focus)}.kf-ai-mark__icon{--kf-icon-size: 14px !important}\n"], dependencies: [{ kind: "component", type: Icon, selector: "kf-icon", inputs: ["name", "size", "rotate", "filled"] }, { kind: "directive", type: PopoverDirective, selector: "[kfPopover]", inputs: ["kfPopover", "kfPopoverPlacement", "kfPopoverShowDelay", "kfPopoverHideDelay", "kfPopoverDisabled", "kfPopoverInteractive", "kfPopoverLabel", "kfPopoverDescribe", "kfPopoverTrigger", "kfPopoverOpen"], outputs: ["kfPopoverOpenChange"], exportAs: ["kfPopover"] }] });
|
|
3926
4018
|
}
|
|
@@ -4270,7 +4362,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
4270
4362
|
}, template: "@if (open()) {\n <div class=\"kf-alert\" [class]=\"rootClass()\" [attr.role]=\"ariaRole()\">\n <!--\n `bar` y `solid` usan el glifo de trazo de `kf-icon`. `surface` y `elevated`\n dibujan un glifo relleno propio: `kf-icon` solo tiene trazo y una marca\n blanca sobre un relleno exige dos colores en el mismo glifo.\n -->\n @if (variant() === 'bar') {\n <kf-icon class=\"kf-alert__icon\" [name]=\"toneIcon()\" size=\"sm\" />\n } @else if (appearance() === 'solid') {\n <kf-icon class=\"kf-alert__icon\" [name]=\"toneIcon()\" size=\"md\" />\n } @else {\n <span class=\"kf-alert__icon\">\n <svg class=\"kf-alert__glyph\" viewBox=\"0 0 24 24\" aria-hidden=\"true\" focusable=\"false\">\n @switch (tone()) {\n @case ('ok') {\n <circle class=\"kf-alert__shape\" cx=\"12\" cy=\"12\" r=\"9.5\" />\n <path class=\"kf-alert__mark\" d=\"m7.8 12.4 2.8 2.8 5.6-5.8\" />\n }\n @case ('warn') {\n <path\n class=\"kf-alert__shape\"\n d=\"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3Z\"\n />\n <path class=\"kf-alert__mark\" d=\"M12 9.2v4.2\" />\n <path class=\"kf-alert__mark kf-alert__mark--dot\" d=\"M12 17h.01\" />\n }\n @case ('error') {\n <polygon\n class=\"kf-alert__shape\"\n points=\"7.86 2 16.14 2 22 7.86 22 16.14 16.14 22 7.86 22 2 16.14 2 7.86 7.86 2\"\n />\n <path class=\"kf-alert__mark\" d=\"M12 7.8v4.6\" />\n <path class=\"kf-alert__mark kf-alert__mark--dot\" d=\"M12 16h.01\" />\n }\n @default {\n <circle class=\"kf-alert__shape\" cx=\"12\" cy=\"12\" r=\"9.5\" />\n <path class=\"kf-alert__mark\" d=\"M12 11v5\" />\n <path class=\"kf-alert__mark kf-alert__mark--dot\" d=\"M12 7.6h.01\" />\n }\n }\n </svg>\n </span>\n }\n <div class=\"kf-alert__body\">\n <div class=\"kf-alert__content\">\n @if (title()) {\n <p class=\"kf-alert__title\">{{ title() }}</p>\n }\n <div class=\"kf-alert__message\"><ng-content /></div>\n </div>\n <div class=\"kf-alert__actions\"><ng-content select=\"[kfAlertActions]\" /></div>\n </div>\n @if (dismissible()) {\n <button\n type=\"button\"\n class=\"kf-alert__close\"\n aria-label=\"Cerrar aviso\"\n (click)=\"open.set(false)\"\n >\n <kf-icon name=\"x\" size=\"sm\" />\n </button>\n }\n </div>\n}\n", styles: [":host{display:block;font-family:var(--kf-font-body)}.kf-alert{--_mark: var(--kf-color-white);--_actions-gap: calc(var(--kf-space-sm) + var(--kf-space-xs));display:flex;color:var(--kf-color-text);font-size:var(--kf-font-size-body-sm);line-height:1.5}.kf-alert--info{--_tone: var(--kf-color-info);--_soft: var(--kf-color-info-soft);--_strong: var(--kf-color-info-strong);--_icon: var(--kf-color-info)}.kf-alert--ok{--_tone: var(--kf-color-success);--_soft: var(--kf-color-success-soft);--_strong: var(--kf-color-success-strong);--_icon: color-mix(in srgb, var(--kf-color-success) 60%, var(--kf-color-success-strong))}.kf-alert--warn{--_tone: var(--kf-color-warning);--_soft: var(--kf-color-warning-soft);--_strong: var(--kf-color-warning-strong);--_icon: color-mix(in srgb, var(--kf-color-warning) 35%, var(--kf-color-warning-strong));--_mark: var(--kf-color-ink)}.kf-alert--error{--_tone: var(--kf-color-error);--_soft: var(--kf-color-error-soft);--_strong: var(--kf-color-error-strong);--_icon: var(--kf-color-error)}.kf-alert__body{display:flex;min-width:0}.kf-alert__content{display:flex;flex-direction:column;min-width:0}.kf-alert__title{margin:0;color:var(--kf-color-ink);font-family:var(--kf-font-body);font-size:var(--kf-font-size-body);font-weight:var(--kf-font-weight-medium);line-height:1.5}.kf-alert__message{max-inline-size:72ch;color:var(--kf-color-text);overflow-wrap:anywhere}.kf-alert__message:has(>div,>section,>form,>table){max-inline-size:none}.kf-alert__message:empty{display:none}.kf-alert__actions{display:flex;flex:0 1 auto;flex-wrap:wrap;align-items:center;gap:var(--_actions-gap);min-width:0;max-width:100%}.kf-alert__actions:empty{display:none}.kf-alert__actions>*{max-width:100%;min-width:0}.kf-alert__actions ::ng-deep>:is(div,span,ul)[kfAlertActions]{display:flex;flex-wrap:wrap;align-items:center;gap:var(--_actions-gap);margin:0;padding:0;list-style:none}.kf-alert__close{position:relative;flex:none;display:inline-flex;align-self:center;margin-inline-start:var(--kf-space-sm);padding:2px;border:none;background:transparent;color:var(--kf-color-text-muted);border-radius:var(--kf-radius-xs);cursor:pointer;transition:background-color var(--kf-motion-fast, .14s) ease,color var(--kf-motion-fast, .14s) ease}.kf-alert__close:after{content:\"\";position:absolute;top:50%;left:calc(-1 * var(--kf-space-sm));width:44px;height:44px;transform:translateY(-50%)}.kf-alert__close:hover{background:var(--kf-color-gray-100);color:var(--kf-color-ink)}.kf-alert__close:focus-visible{outline:none;box-shadow:var(--kf-shadow-focus)}@media(prefers-reduced-motion:reduce){.kf-alert__close{transition:none}}.kf-alert--bar{align-items:center;gap:var(--kf-space-sm);padding:var(--kf-space-sm) var(--kf-space-md);border:1px solid color-mix(in srgb,var(--_tone) 40%,var(--_soft));border-width:1px 0;border-radius:0;background:var(--_soft)}.kf-alert--bar .kf-alert__icon{align-items:center;justify-content:center;color:var(--_strong)}.kf-alert--bar .kf-alert__body{flex:1 1 0;flex-wrap:wrap;align-items:center;gap:var(--kf-space-sm) var(--kf-space-lg)}.kf-alert--bar .kf-alert__content{flex:1 1 20rem;flex-flow:row wrap;align-items:baseline;gap:2px var(--kf-space-xs)}.kf-alert--bar .kf-alert__title{font-size:inherit}.kf-alert--bar .kf-alert__message{max-inline-size:none}.kf-alert--bar .kf-alert__actions{flex-basis:100%}.kf-alert--bar.kf-alert--actions-inline .kf-alert__actions{flex-basis:auto}.kf-alert--bar .kf-alert__close:hover{background:color-mix(in srgb,var(--_strong) 12%,transparent)}.kf-alert--card{--_line: calc(var(--kf-font-size-body-sm) * 1.5);--_content-gap: 0px;align-items:flex-start}.kf-alert--card.kf-alert--titled{--_line: var(--_title-line)}.kf-alert--card .kf-alert__icon{display:flex;flex:none;align-items:center;justify-content:center;inline-size:var(--_glyph);block-size:var(--_line);color:var(--_icon)}.kf-alert--card .kf-alert__body{flex:1 1 0;flex-direction:column;gap:var(--_body-gap)}.kf-alert--card .kf-alert__content{gap:var(--_content-gap)}.kf-alert--card .kf-alert__title{color:inherit;font-size:var(--_title-size);font-weight:var(--_title-weight);line-height:var(--_title-line)}.kf-alert--card .kf-alert__message{color:inherit}.kf-alert--card.kf-alert--titled .kf-alert__message{color:var(--_desc)}.kf-alert--card .kf-alert__close{align-self:flex-start;margin-inline-start:0;margin-inline-end:calc(var(--kf-space-md) - var(--_pad-end));margin-block-start:calc((var(--_line) - 20px) / 2)}.kf-alert__glyph{display:block;flex:none;inline-size:var(--_glyph);block-size:var(--_glyph);fill:none;stroke:none}.kf-alert__shape{fill:currentColor;stroke:currentColor;stroke-width:1;stroke-linejoin:round}.kf-alert__mark{fill:none;stroke:var(--_mark);stroke-width:2.2;stroke-linecap:round;stroke-linejoin:round}.kf-alert__mark--dot{stroke-width:2.6}.kf-alert--surface{--_glyph: 16px;--_title-line: calc(var(--kf-font-size-body) * 1.5);--_title-size: var(--kf-font-size-body);--_title-weight: 500;--_body-gap: calc(var(--kf-space-sm) + var(--kf-space-xs));--_desc: var(--kf-color-text);--_pad-end: calc(var(--kf-space-sm) + var(--kf-space-xs));gap:var(--kf-space-sm);padding:var(--kf-space-sm) var(--_pad-end);border:1px solid color-mix(in srgb,var(--_tone) 40%,var(--_soft));border-radius:var(--kf-radius-sm);background:var(--_soft);color:var(--kf-color-ink)}.kf-alert--surface.kf-alert--titled{--_glyph: 24px;--_content-gap: var(--kf-space-sm);--_pad-end: var(--kf-space-lg);gap:calc(var(--kf-space-sm) + var(--kf-space-xs));padding:calc(var(--kf-space-md) + var(--kf-space-xs)) var(--_pad-end)}.kf-alert--surface .kf-alert__close:hover{background:color-mix(in srgb,var(--_strong) 12%,transparent)}.kf-alert--elevated{--_glyph: 24px;--_title-line: var(--kf-space-lg);--_title-size: var(--kf-font-size-body-sm);--_title-weight: var(--kf-font-weight-medium);--_body-gap: var(--kf-space-sm);--_actions-gap: 0px;--_desc: var(--kf-color-text-muted);--_pad-end: var(--kf-space-md);gap:var(--kf-space-md);padding:var(--kf-space-md) var(--_pad-end);border:1px solid var(--kf-color-border);border-radius:var(--kf-radius-sm);background:var(--kf-color-white);box-shadow:var(--kf-shadow-md);color:var(--kf-color-ink)}.kf-alert--elevated .kf-alert__actions{margin-inline-start:calc(-1 * var(--kf-space-sm))}.kf-alert--elevated .kf-alert__actions ::ng-deep>:is(div,span,ul)[kfAlertActions]>*{position:relative}.kf-alert--elevated .kf-alert__actions ::ng-deep>:is(div,span,ul)[kfAlertActions]>:not(:last-child):after{content:\"\\b7\";content:\"\\b7\" / \"\";position:absolute;inset-block:0;inset-inline-start:100%;display:grid;place-items:center;inline-size:0;color:var(--kf-color-text-muted);pointer-events:none}.kf-alert--solid{--_glyph: 20px;--_title-line: calc(var(--kf-space-md) + var(--kf-space-xs));--_title-size: .9375rem;--_title-weight: var(--kf-font-weight-medium);--_body-gap: var(--kf-space-sm);--_actions-gap: var(--kf-space-sm);--_solid: var(--_strong);--_on: var(--kf-color-white);--_btn-fg: var(--_solid);--_desc: var(--_on);--_pad-end: var(--kf-space-sm);gap:calc(var(--kf-space-sm) + var(--kf-space-xs));padding:calc(var(--kf-space-sm) + var(--kf-space-xs)) var(--_pad-end) calc(var(--kf-space-sm) + var(--kf-space-xs)) var(--kf-space-md);border-radius:var(--kf-radius-sm);background:var(--_solid);color:var(--_on)}.kf-alert--solid.kf-alert--warn{--_solid: var(--kf-color-warning);--_on: var(--kf-color-ink);--_btn-fg: var(--kf-color-white)}.kf-alert--solid .kf-alert__icon{color:var(--_on)}.kf-alert--solid:not(.kf-alert--titled) .kf-alert__message{font-weight:500}.kf-alert--solid .kf-alert__close{color:var(--_on)}.kf-alert--solid .kf-alert__close:hover{background:color-mix(in srgb,var(--_on) 16%,transparent);color:var(--_on)}.kf-alert--solid .kf-alert__close:focus-visible{box-shadow:0 0 0 2px var(--_solid),0 0 0 4px var(--_on)}.kf-alert--solid .kf-alert__actions{--kf-color-primary: var(--_on);--kf-color-primary-hover: color-mix(in srgb, var(--_on) 88%, var(--_solid));--kf-color-primary-soft: color-mix(in srgb, var(--_on) 16%, transparent);--kf-color-white: var(--_btn-fg);--kf-color-text: var(--_on);--kf-color-text-muted: var(--_on);--kf-color-border-strong: color-mix(in srgb, var(--_on) 55%, transparent);--kf-color-surface: color-mix(in srgb, var(--_on) 16%, transparent);--kf-shadow-focus: 0 0 0 2px var(--_solid), 0 0 0 4px var(--_on)}:host([data-actions-inline]){container:kf-alert / inline-size}.kf-alert--card.kf-alert--actions-inline .kf-alert__body{flex-direction:row;align-items:center;gap:var(--kf-space-sm) var(--kf-space-md)}.kf-alert--card.kf-alert--actions-inline .kf-alert__content{flex:1 1 0}.kf-alert--card.kf-alert--actions-inline .kf-alert__actions{flex:none}@container kf-alert (max-width: 479.98px){.kf-alert--card.kf-alert--actions-inline .kf-alert__body{flex-wrap:wrap}.kf-alert--card.kf-alert--actions-inline .kf-alert__actions{flex:1 1 100%}}.kf-alert--card.kf-alert--icon-center{display:grid;grid-template-columns:auto minmax(0,1fr);row-gap:var(--_body-gap)}.kf-alert--icon-center .kf-alert__body{display:contents}.kf-alert--icon-center .kf-alert__icon{grid-area:1 / 1;align-self:center}.kf-alert--icon-center .kf-alert__content{grid-area:1 / 2}.kf-alert--icon-center .kf-alert__actions{grid-area:2 / 2}.kf-alert--icon-center .kf-alert__close{grid-area:1 / 3;align-self:center;margin-block-start:0}\n"] }]
|
|
4271
4363
|
}], propDecorators: { tone: [{ type: i0.Input, args: [{ isSignal: true, alias: "tone", required: false }] }], variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], appearance: [{ type: i0.Input, args: [{ isSignal: true, alias: "appearance", required: false }] }], iconAlign: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconAlign", required: false }] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], dismissible: [{ type: i0.Input, args: [{ isSignal: true, alias: "dismissible", required: false }] }], actionsInline: [{ type: i0.Input, args: [{ isSignal: true, alias: "actionsInline", required: false }] }], open: [{ type: i0.Input, args: [{ isSignal: true, alias: "open", required: false }] }, { type: i0.Output, args: ["openChange"] }] } });
|
|
4272
4364
|
|
|
4273
|
-
let nextId$
|
|
4365
|
+
let nextId$8 = 0;
|
|
4274
4366
|
/**
|
|
4275
4367
|
* Avisos contextuales agrupados dentro de un contenedor (una sección, una hoja):
|
|
4276
4368
|
* en vez de un `kf-alert` por cada ítem rechazado, un solo aviso con una fila por
|
|
@@ -4314,7 +4406,7 @@ class AlertGroup {
|
|
|
4314
4406
|
...(ngDevMode ? [{ debugName: "dismissItemLabel" }] : /* istanbul ignore next */ []));
|
|
4315
4407
|
dismissAll = output();
|
|
4316
4408
|
dismissItem = output();
|
|
4317
|
-
listId = `kf-alert-group-list-${nextId$
|
|
4409
|
+
listId = `kf-alert-group-list-${nextId$8++}`;
|
|
4318
4410
|
/** Agrupa por clave conservando el orden de la primera aparición y el último texto recibido. */
|
|
4319
4411
|
entries = computed(() => {
|
|
4320
4412
|
const groups = new Map();
|
|
@@ -5961,7 +6053,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
5961
6053
|
}, template: "@if (dot()) {\n <span\n class=\"kf-chip__dot\"\n [class.kf-chip__dot--ok]=\"tone() === 'ok'\"\n [class.kf-chip__dot--warn]=\"tone() === 'warn'\"\n [class.kf-chip__dot--error]=\"tone() === 'error'\"\n [class.kf-chip__dot--neutral]=\"tone() === 'neutral'\"\n ></span>\n}\n<span class=\"kf-chip__label\"><ng-content /></span>\n", styles: [":host{display:inline-flex;align-items:center;gap:var(--kf-space-xs);padding:var(--kf-space-xs) var(--kf-space-sm);border-radius:var(--kf-radius-pill);border:1px solid transparent;font:inherit;font-size:.875em;line-height:1;color:var(--kf-color-text);background:var(--kf-color-surface);border-color:var(--kf-color-border);white-space:nowrap}:host(.kf-chip--ok){background:var(--kf-color-success-soft);border-color:var(--kf-color-success-soft);color:var(--kf-color-text)}:host(.kf-chip--warn){background:var(--kf-color-warning-soft);border-color:var(--kf-color-warning-soft);color:var(--kf-color-text)}:host(.kf-chip--error){background:var(--kf-color-error-soft);border-color:var(--kf-color-error-soft);color:var(--kf-color-text)}:host(.kf-chip--neutral){background:var(--kf-color-surface);border-color:var(--kf-color-border);color:var(--kf-color-text)}.kf-chip__dot{inline-size:.5em;block-size:.5em;border-radius:var(--kf-radius-pill);flex:none;background:var(--kf-color-text-muted)}.kf-chip__label{display:inline-block}.kf-chip__dot--ok{background:var(--kf-color-success)}.kf-chip__dot--warn{background:var(--kf-color-warning)}.kf-chip__dot--error{background:var(--kf-color-error)}.kf-chip__dot--neutral{background:var(--kf-color-text-muted)}\n"] }]
|
|
5962
6054
|
}], propDecorators: { tone: [{ type: i0.Input, args: [{ isSignal: true, alias: "tone", required: false }] }], dot: [{ type: i0.Input, args: [{ isSignal: true, alias: "dot", required: false }] }] } });
|
|
5963
6055
|
|
|
5964
|
-
let nextId$
|
|
6056
|
+
let nextId$7 = 0;
|
|
5965
6057
|
/**
|
|
5966
6058
|
* Bloque colapsable genérico: un header clickeable (título + chevron) que
|
|
5967
6059
|
* expande/colapsa contenido proyectado libre, sin saber nada de lo que hay
|
|
@@ -5996,7 +6088,7 @@ class Collapsible {
|
|
|
5996
6088
|
...(ngDevMode ? [{ debugName: "title" }] : /* istanbul ignore next */ []));
|
|
5997
6089
|
expanded = model(false, /* @ts-ignore */
|
|
5998
6090
|
...(ngDevMode ? [{ debugName: "expanded" }] : /* istanbul ignore next */ []));
|
|
5999
|
-
instanceId = `kf-collapsible-${nextId$
|
|
6091
|
+
instanceId = `kf-collapsible-${nextId$7++}`;
|
|
6000
6092
|
triggerId = `${this.instanceId}-trigger`;
|
|
6001
6093
|
panelId = `${this.instanceId}-panel`;
|
|
6002
6094
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: Collapsible, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
@@ -6100,6 +6192,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
6100
6192
|
}, template: "<div class=\"kf-content-slot__media\">\n <kf-icon [name]=\"icon()\" [size]=\"compact() ? 'md' : 'lg'\" />\n</div>\n<span class=\"kf-content-slot__title\">{{ title() }}</span>\n@if (description()) {\n <p class=\"kf-content-slot__description\">{{ description() }}</p>\n}\n@if (!compact()) {\n <span class=\"kf-content-slot__footer\">\n <kf-text as=\"span\" variant=\"overline\">Contenido disponible para uso</kf-text>\n </span>\n}\n", styles: [":host{display:flex;flex-direction:column;gap:var(--kf-space-xs);padding:var(--kf-space-md);border:1px solid var(--kf-color-border);border-radius:var(--kf-radius-sm);background:var(--kf-color-white);font-family:var(--kf-font-body)}.kf-content-slot__media{display:flex;align-items:center;justify-content:center;height:96px;margin-bottom:var(--kf-space-xs);border-radius:var(--kf-radius-sm);background:var(--kf-color-surface);color:var(--kf-color-border-strong)}:host(.kf-content-slot--compact) .kf-content-slot__media{height:56px}.kf-content-slot__title{font-family:var(--kf-font-title);font-weight:700;color:var(--kf-color-ink)}.kf-content-slot__description{margin:0;font-size:var(--kf-font-size-label);color:var(--kf-color-text-muted)}.kf-content-slot__footer{align-self:flex-start;margin-top:var(--kf-space-xs);padding:2px var(--kf-space-sm);border-radius:var(--kf-radius-pill);background:var(--kf-color-surface)}\n"] }]
|
|
6101
6193
|
}], propDecorators: { title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], description: [{ type: i0.Input, args: [{ isSignal: true, alias: "description", required: false }] }], icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], compact: [{ type: i0.Input, args: [{ isSignal: true, alias: "compact", required: false }] }] } });
|
|
6102
6194
|
|
|
6195
|
+
/** Acepta el nivel como número (`[headingLevel]="2"`) o como atributo estático (`headingLevel="2"`). */
|
|
6196
|
+
function toHeadingLevel(value) {
|
|
6197
|
+
const level = Number(value);
|
|
6198
|
+
return level === 2 || level === 3 || level === 4 ? level : null;
|
|
6199
|
+
}
|
|
6103
6200
|
/**
|
|
6104
6201
|
* Placeholder para una sección sin contenido. Dos tonos, con anatomía
|
|
6105
6202
|
* distinta (páginas 27-28 del design system, que los trata como piezas
|
|
@@ -6159,9 +6256,38 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
6159
6256
|
* metadatos debajo de los botones ("¿Ya estás conectado? …", "Intento 2 ·
|
|
6160
6257
|
* 10:42"). Vacío, no ocupa lugar.
|
|
6161
6258
|
*
|
|
6162
|
-
*
|
|
6163
|
-
*
|
|
6164
|
-
* vacío no debe alterar su
|
|
6259
|
+
* ## Título y encabezado
|
|
6260
|
+
* `title` se dibuja como texto destacado (`<p>`), no como encabezado: el nivel
|
|
6261
|
+
* depende de la página que lo contiene, y un estado vacío no debe alterar su
|
|
6262
|
+
* estructura. Cuando el estado ocupa la pantalla entera y el título sí es el
|
|
6263
|
+
* encabezado de su región, `headingLevel` (2, 3 o 4) lo dibuja como `<h2>`,
|
|
6264
|
+
* `<h3>` o `<h4>`. Solo cambia el elemento: el aspecto es el mismo.
|
|
6265
|
+
*
|
|
6266
|
+
* ## Composición compacta con chip (pantallas completas, mobile)
|
|
6267
|
+
* Cuatro opciones, independientes entre sí y apagadas por defecto, que juntas dan el
|
|
6268
|
+
* estado de una pantalla completa sin sobrescribir el CSS de la librería:
|
|
6269
|
+
*
|
|
6270
|
+
* - `iconChip`: el ícono (24px) va en un círculo tonal de 56px que toma el tono del estado
|
|
6271
|
+
* (`neutral` usa los roles de marca `primary-soft` / `primary-active`; el resto, el par
|
|
6272
|
+
* `*-soft` / `*-strong` de su rol). El ritmo vertical es el de `card` (`--kf-space-md`
|
|
6273
|
+
* entre bloques, título pegado a su texto) y, en `flat`, el relleno vertical sube a
|
|
6274
|
+
* `--kf-space-xl`. En `card` el chip ya existe y `iconChip` no cambia nada.
|
|
6275
|
+
* - `size="sm"`: el contenido pasa a `body-sm` con interlineado 1.5 y el título a negrita.
|
|
6276
|
+
* - `textTone="neutral"`: el texto del contenido queda atenuado también en `error`; el color
|
|
6277
|
+
* del tono lo lleva solo el ícono.
|
|
6278
|
+
* - `headingLevel`: ver arriba.
|
|
6279
|
+
*
|
|
6280
|
+
* <kf-empty-state variant="flat" iconChip size="sm" textTone="neutral" headingLevel="2"
|
|
6281
|
+
* tone="error" icon="alert-circle" title="No se pudo cargar la lista"
|
|
6282
|
+
* role="alert">
|
|
6283
|
+
* Revisar la conexión e intentar de nuevo.
|
|
6284
|
+
* <kf-button kf-empty-state-actions variant="outline" (click)="retry()">Reintentar</kf-button>
|
|
6285
|
+
* </kf-empty-state>
|
|
6286
|
+
*
|
|
6287
|
+
* ## Regiones vivas
|
|
6288
|
+
* El rol (`role="status"` para un vacío, `role="alert"` para una falla) lo pone el consumidor
|
|
6289
|
+
* en el host, como en `kf-content-state`: no todo estado debe interrumpir al lector de pantalla,
|
|
6290
|
+
* y quien conoce el contexto es quien decide.
|
|
6165
6291
|
*/
|
|
6166
6292
|
class EmptyState {
|
|
6167
6293
|
icon = input(undefined, /* @ts-ignore */
|
|
@@ -6175,10 +6301,20 @@ class EmptyState {
|
|
|
6175
6301
|
/** Título destacado sobre el contenido. Opcional en ambas variantes. */
|
|
6176
6302
|
title = input(/* @ts-ignore */
|
|
6177
6303
|
...(ngDevMode ? [undefined, { debugName: "title" }] : /* istanbul ignore next */ []));
|
|
6178
|
-
|
|
6304
|
+
/** Dibuja el título como `<h2>`, `<h3>` o `<h4>`. Sin valor (default) es un `<p>`. El aspecto no cambia. */
|
|
6305
|
+
headingLevel = input(null, { ...(ngDevMode ? { debugName: "headingLevel" } : /* istanbul ignore next */ {}), transform: toHeadingLevel });
|
|
6306
|
+
/** Pone el ícono (24px) en un círculo tonal de 56px en `inline` y `flat`. En `card` el chip ya es el de siempre. */
|
|
6307
|
+
iconChip = input(false, { ...(ngDevMode ? { debugName: "iconChip" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
6308
|
+
/** `md` (default) o `sm`: contenido en `body-sm` y título en negrita. */
|
|
6309
|
+
size = input('md', /* @ts-ignore */
|
|
6310
|
+
...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
6311
|
+
/** `auto` (default) sigue al tono; `neutral` deja el texto atenuado y el color del tono solo en el ícono. */
|
|
6312
|
+
textTone = input('auto', /* @ts-ignore */
|
|
6313
|
+
...(ngDevMode ? [{ debugName: "textTone" }] : /* istanbul ignore next */ []));
|
|
6314
|
+
iconSize = computed(() => this.variant() === 'card' || this.tone() === 'error' || this.iconChip() ? 'lg' : 'md', /* @ts-ignore */
|
|
6179
6315
|
...(ngDevMode ? [{ debugName: "iconSize" }] : /* istanbul ignore next */ []));
|
|
6180
6316
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: EmptyState, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
6181
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: EmptyState, isStandalone: true, selector: "kf-empty-state", inputs: { icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, tone: { classPropertyName: "tone", publicName: "tone", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class.kf-empty-state--error": "tone() === 'error'", "class.kf-empty-state--warn": "tone() === 'warn'", "class.kf-empty-state--info": "tone() === 'info'", "class.kf-empty-state--ok": "tone() === 'ok'", "class.kf-empty-state--card": "variant() === 'card'", "class.kf-empty-state--flat": "variant() === 'flat'", "attr.title": "null" } }, ngImport: i0, template: "@if (icon(); as iconName) {\n <span class=\"kf-empty-state__icon\">\n <kf-icon [name]=\"iconName\" [size]=\"iconSize()\" />\n </span>\n}\n@if (title(); as titleText) {\n <p class=\"kf-empty-state__title\">{{ titleText }}</p>\n}\n<div class=\"kf-empty-state__content\">\n <ng-content />\n</div>\n<div class=\"kf-empty-state__actions\"><ng-content select=\"[kf-empty-state-actions]\" /></div>\n<div class=\"kf-empty-state__footer\"><ng-content select=\"[kf-empty-state-footer]\" /></div>\n", styles: [":host{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:var(--kf-space-sm);padding:var(--kf-space-xl);border:1px dashed var(--kf-color-border-strong);border-radius:var(--kf-radius-md);background:var(--kf-color-surface);color:var(--kf-color-text-muted);font:inherit;text-align:center}:host(.kf-empty-state--error){border:none;background:var(--kf-color-error-soft)}.kf-empty-state__content{color:var(--kf-color-text-muted);font-family:var(--kf-font-body)}:host(.kf-empty-state--error) .kf-empty-state__content{color:var(--kf-color-error-strong)}.kf-empty-state__title{margin:0;font-family:var(--kf-font-title);font-size:var(--kf-font-size-title-sm);line-height:1.25;color:var(--kf-color-ink)}.kf-empty-state__actions{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:var(--kf-space-sm)}.kf-empty-state__actions>::ng-deep [kf-empty-state-actions]{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:var(--kf-space-sm)}.kf-empty-state__actions:empty,.kf-empty-state__footer:empty{display:none}.kf-empty-state__footer{display:flex;flex-direction:column;align-items:center;gap:var(--kf-space-xs);font-size:var(--kf-font-size-caption);color:var(--kf-color-text)}:host(.kf-empty-state--ok) .kf-empty-state__icon{color:var(--kf-color-success-strong)}:host(.kf-empty-state--warn) .kf-empty-state__icon{color:var(--kf-color-warning-strong)}:host(.kf-empty-state--info) .kf-empty-state__icon{color:var(--kf-color-info-strong)}:host(.kf-empty-state--flat){padding:var(--kf-space-lg) var(--kf-space-md);border:0;background:transparent}:host(.kf-empty-state--card){box-sizing:border-box;width:min(480px,100%);gap:var(--kf-space-md);padding:var(--kf-space-xl) var(--kf-space-lg);border:1px solid var(--kf-color-border);border-radius:var(--kf-radius-lg);background:var(--kf-color-white);box-shadow:var(--kf-elevation-raised);color:var(--kf-color-text)}:host(.kf-empty-state--card) .kf-empty-state__title+.kf-empty-state__content{margin-top:calc(var(--kf-space-sm) - var(--kf-space-md))}:host(.kf-empty-state--card) .kf-empty-state__content>::ng-deep :is(p,ol,ul),:host(.kf-empty-state--card) .kf-empty-state__footer>::ng-deep [kf-empty-state-footer] :is(p),:host(.kf-empty-state--card) .kf-empty-state__footer>::ng-deep p[kf-empty-state-footer]{margin:0}:host(.kf-empty-state--card) .kf-empty-state__content:empty{display:none}:host(.kf-empty-state--card) .kf-empty-state__content{display:flex;flex-direction:column;align-items:stretch;gap:var(--kf-space-md);align-self:stretch;color:var(--kf-color-text);font-size:var(--kf-font-size-body-sm);line-height:1.5}:host(.kf-empty-state--card.kf-empty-state--error) .kf-empty-state__content{color:var(--kf-color-text)}:host(.kf-empty-state--card) .kf-empty-state__icon{display:flex;align-items:center;justify-content:center;width:56px;height:56px;border-radius:50%;background:var(--kf-color-surface);color:var(--kf-color-text-muted)}:host(.kf-empty-state--card.kf-empty-state--ok) .kf-empty-state__icon{background:var(--kf-color-success-soft);color:var(--kf-color-success-strong)}:host(.kf-empty-state--card.kf-empty-state--warn) .kf-empty-state__icon{background:var(--kf-color-warning-soft);color:var(--kf-color-warning-strong)}:host(.kf-empty-state--card.kf-empty-state--info) .kf-empty-state__icon{background:var(--kf-color-info-soft);color:var(--kf-color-info-strong)}:host(.kf-empty-state--card.kf-empty-state--error) .kf-empty-state__icon{background:var(--kf-color-error-soft);color:var(--kf-color-error-strong)}\n"], dependencies: [{ kind: "component", type: Icon, selector: "kf-icon", inputs: ["name", "size", "rotate", "filled"] }] });
|
|
6317
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: EmptyState, isStandalone: true, selector: "kf-empty-state", inputs: { icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, tone: { classPropertyName: "tone", publicName: "tone", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, headingLevel: { classPropertyName: "headingLevel", publicName: "headingLevel", isSignal: true, isRequired: false, transformFunction: null }, iconChip: { classPropertyName: "iconChip", publicName: "iconChip", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, textTone: { classPropertyName: "textTone", publicName: "textTone", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class.kf-empty-state--error": "tone() === 'error'", "class.kf-empty-state--warn": "tone() === 'warn'", "class.kf-empty-state--info": "tone() === 'info'", "class.kf-empty-state--ok": "tone() === 'ok'", "class.kf-empty-state--card": "variant() === 'card'", "class.kf-empty-state--flat": "variant() === 'flat'", "class.kf-empty-state--chip": "iconChip() && variant() !== 'card'", "class.kf-empty-state--sm": "size() === 'sm'", "class.kf-empty-state--text-neutral": "textTone() === 'neutral'", "attr.title": "null" } }, ngImport: i0, template: "@if (icon(); as iconName) {\n <span class=\"kf-empty-state__icon\">\n <kf-icon [name]=\"iconName\" [size]=\"iconSize()\" />\n </span>\n}\n@if (title(); as titleText) {\n @switch (headingLevel()) {\n @case (2) {\n <h2 class=\"kf-empty-state__title\">{{ titleText }}</h2>\n }\n @case (3) {\n <h3 class=\"kf-empty-state__title\">{{ titleText }}</h3>\n }\n @case (4) {\n <h4 class=\"kf-empty-state__title\">{{ titleText }}</h4>\n }\n @default {\n <p class=\"kf-empty-state__title\">{{ titleText }}</p>\n }\n }\n}\n<div class=\"kf-empty-state__content\">\n <ng-content />\n</div>\n<div class=\"kf-empty-state__actions\"><ng-content select=\"[kf-empty-state-actions]\" /></div>\n<div class=\"kf-empty-state__footer\"><ng-content select=\"[kf-empty-state-footer]\" /></div>\n", styles: [":host{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:var(--kf-space-sm);padding:var(--kf-space-xl);border:1px dashed var(--kf-color-border-strong);border-radius:var(--kf-radius-md);background:var(--kf-color-surface);color:var(--kf-color-text-muted);font:inherit;text-align:center}:host(.kf-empty-state--error){border:none;background:var(--kf-color-error-soft)}.kf-empty-state__content{color:var(--kf-color-text-muted);font-family:var(--kf-font-body)}:host(.kf-empty-state--error) .kf-empty-state__content{color:var(--kf-color-error-strong)}.kf-empty-state__title{margin:0;font-family:var(--kf-font-title);font-size:var(--kf-font-size-title-sm);font-weight:inherit;line-height:1.25;color:var(--kf-color-ink)}.kf-empty-state__actions{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:var(--kf-space-sm)}.kf-empty-state__actions>::ng-deep [kf-empty-state-actions]{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:var(--kf-space-sm)}.kf-empty-state__actions:empty,.kf-empty-state__footer:empty{display:none}.kf-empty-state__footer{display:flex;flex-direction:column;align-items:center;gap:var(--kf-space-xs);font-size:var(--kf-font-size-caption);color:var(--kf-color-text)}:host(.kf-empty-state--ok) .kf-empty-state__icon{color:var(--kf-color-success-strong)}:host(.kf-empty-state--warn) .kf-empty-state__icon{color:var(--kf-color-warning-strong)}:host(.kf-empty-state--info) .kf-empty-state__icon{color:var(--kf-color-info-strong)}:host(.kf-empty-state--flat){padding:var(--kf-space-lg) var(--kf-space-md);border:0;background:transparent}:host(.kf-empty-state--sm) .kf-empty-state__title{font-weight:var(--kf-font-weight-title)}:host(.kf-empty-state--sm) .kf-empty-state__content{font-size:var(--kf-font-size-body-sm);line-height:1.5}:host(.kf-empty-state--text-neutral.kf-empty-state--error) .kf-empty-state__content{color:var(--kf-color-text-muted)}:host(.kf-empty-state--chip){gap:var(--kf-space-md)}:host(.kf-empty-state--chip.kf-empty-state--flat){padding-block:var(--kf-space-xl)}:host(.kf-empty-state--chip) .kf-empty-state__title+.kf-empty-state__content{margin-top:calc(var(--kf-space-sm) - var(--kf-space-md))}:host(.kf-empty-state--chip) .kf-empty-state__content:empty{display:none}:host(.kf-empty-state--chip) .kf-empty-state__icon{display:flex;align-items:center;justify-content:center;width:56px;height:56px;border-radius:50%;background:var(--kf-color-primary-soft);color:var(--kf-color-primary-active)}:host(.kf-empty-state--chip.kf-empty-state--ok) .kf-empty-state__icon{background:var(--kf-color-success-soft);color:var(--kf-color-success-strong)}:host(.kf-empty-state--chip.kf-empty-state--warn) .kf-empty-state__icon{background:var(--kf-color-warning-soft);color:var(--kf-color-warning-strong)}:host(.kf-empty-state--chip.kf-empty-state--info) .kf-empty-state__icon{background:var(--kf-color-info-soft);color:var(--kf-color-info-strong)}:host(.kf-empty-state--chip.kf-empty-state--error) .kf-empty-state__icon{background:var(--kf-color-error-soft);color:var(--kf-color-error-strong)}:host(.kf-empty-state--chip.kf-empty-state--error:not(.kf-empty-state--flat)) .kf-empty-state__icon{background:var(--kf-color-white)}:host(.kf-empty-state--card){box-sizing:border-box;width:min(480px,100%);gap:var(--kf-space-md);padding:var(--kf-space-xl) var(--kf-space-lg);border:1px solid var(--kf-color-border);border-radius:var(--kf-radius-lg);background:var(--kf-color-white);box-shadow:var(--kf-elevation-raised);color:var(--kf-color-text)}:host(.kf-empty-state--card) .kf-empty-state__title+.kf-empty-state__content{margin-top:calc(var(--kf-space-sm) - var(--kf-space-md))}:host(.kf-empty-state--card) .kf-empty-state__content>::ng-deep :is(p,ol,ul),:host(.kf-empty-state--card) .kf-empty-state__footer>::ng-deep [kf-empty-state-footer] :is(p),:host(.kf-empty-state--card) .kf-empty-state__footer>::ng-deep p[kf-empty-state-footer]{margin:0}:host(.kf-empty-state--card) .kf-empty-state__content:empty{display:none}:host(.kf-empty-state--card) .kf-empty-state__content{display:flex;flex-direction:column;align-items:stretch;gap:var(--kf-space-md);align-self:stretch;color:var(--kf-color-text);font-size:var(--kf-font-size-body-sm);line-height:1.5}:host(.kf-empty-state--card.kf-empty-state--error) .kf-empty-state__content{color:var(--kf-color-text)}:host(.kf-empty-state--card) .kf-empty-state__icon{display:flex;align-items:center;justify-content:center;width:56px;height:56px;border-radius:50%;background:var(--kf-color-surface);color:var(--kf-color-text-muted)}:host(.kf-empty-state--card.kf-empty-state--ok) .kf-empty-state__icon{background:var(--kf-color-success-soft);color:var(--kf-color-success-strong)}:host(.kf-empty-state--card.kf-empty-state--warn) .kf-empty-state__icon{background:var(--kf-color-warning-soft);color:var(--kf-color-warning-strong)}:host(.kf-empty-state--card.kf-empty-state--info) .kf-empty-state__icon{background:var(--kf-color-info-soft);color:var(--kf-color-info-strong)}:host(.kf-empty-state--card.kf-empty-state--error) .kf-empty-state__icon{background:var(--kf-color-error-soft);color:var(--kf-color-error-strong)}\n"], dependencies: [{ kind: "component", type: Icon, selector: "kf-icon", inputs: ["name", "size", "rotate", "filled"] }] });
|
|
6182
6318
|
}
|
|
6183
6319
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: EmptyState, decorators: [{
|
|
6184
6320
|
type: Component,
|
|
@@ -6189,11 +6325,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
6189
6325
|
'[class.kf-empty-state--ok]': "tone() === 'ok'",
|
|
6190
6326
|
'[class.kf-empty-state--card]': "variant() === 'card'",
|
|
6191
6327
|
'[class.kf-empty-state--flat]': "variant() === 'flat'",
|
|
6328
|
+
// En `card` el chip ya existe con sus propios colores: la clase solo marca el chip de `inline` y `flat`.
|
|
6329
|
+
'[class.kf-empty-state--chip]': "iconChip() && variant() !== 'card'",
|
|
6330
|
+
'[class.kf-empty-state--sm]': "size() === 'sm'",
|
|
6331
|
+
'[class.kf-empty-state--text-neutral]': "textTone() === 'neutral'",
|
|
6192
6332
|
// `title` es un input con nombre de atributo nativo: escrito estático,
|
|
6193
6333
|
// Angular también lo dejaría en el host como tooltip sobre todo el bloque.
|
|
6194
6334
|
'[attr.title]': 'null',
|
|
6195
|
-
}, template: "@if (icon(); as iconName) {\n <span class=\"kf-empty-state__icon\">\n <kf-icon [name]=\"iconName\" [size]=\"iconSize()\" />\n </span>\n}\n@if (title(); as titleText) {\n <p class=\"kf-empty-state__title\">{{ titleText }}</p>\n}\n<div class=\"kf-empty-state__content\">\n <ng-content />\n</div>\n<div class=\"kf-empty-state__actions\"><ng-content select=\"[kf-empty-state-actions]\" /></div>\n<div class=\"kf-empty-state__footer\"><ng-content select=\"[kf-empty-state-footer]\" /></div>\n", styles: [":host{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:var(--kf-space-sm);padding:var(--kf-space-xl);border:1px dashed var(--kf-color-border-strong);border-radius:var(--kf-radius-md);background:var(--kf-color-surface);color:var(--kf-color-text-muted);font:inherit;text-align:center}:host(.kf-empty-state--error){border:none;background:var(--kf-color-error-soft)}.kf-empty-state__content{color:var(--kf-color-text-muted);font-family:var(--kf-font-body)}:host(.kf-empty-state--error) .kf-empty-state__content{color:var(--kf-color-error-strong)}.kf-empty-state__title{margin:0;font-family:var(--kf-font-title);font-size:var(--kf-font-size-title-sm);line-height:1.25;color:var(--kf-color-ink)}.kf-empty-state__actions{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:var(--kf-space-sm)}.kf-empty-state__actions>::ng-deep [kf-empty-state-actions]{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:var(--kf-space-sm)}.kf-empty-state__actions:empty,.kf-empty-state__footer:empty{display:none}.kf-empty-state__footer{display:flex;flex-direction:column;align-items:center;gap:var(--kf-space-xs);font-size:var(--kf-font-size-caption);color:var(--kf-color-text)}:host(.kf-empty-state--ok) .kf-empty-state__icon{color:var(--kf-color-success-strong)}:host(.kf-empty-state--warn) .kf-empty-state__icon{color:var(--kf-color-warning-strong)}:host(.kf-empty-state--info) .kf-empty-state__icon{color:var(--kf-color-info-strong)}:host(.kf-empty-state--flat){padding:var(--kf-space-lg) var(--kf-space-md);border:0;background:transparent}:host(.kf-empty-state--card){box-sizing:border-box;width:min(480px,100%);gap:var(--kf-space-md);padding:var(--kf-space-xl) var(--kf-space-lg);border:1px solid var(--kf-color-border);border-radius:var(--kf-radius-lg);background:var(--kf-color-white);box-shadow:var(--kf-elevation-raised);color:var(--kf-color-text)}:host(.kf-empty-state--card) .kf-empty-state__title+.kf-empty-state__content{margin-top:calc(var(--kf-space-sm) - var(--kf-space-md))}:host(.kf-empty-state--card) .kf-empty-state__content>::ng-deep :is(p,ol,ul),:host(.kf-empty-state--card) .kf-empty-state__footer>::ng-deep [kf-empty-state-footer] :is(p),:host(.kf-empty-state--card) .kf-empty-state__footer>::ng-deep p[kf-empty-state-footer]{margin:0}:host(.kf-empty-state--card) .kf-empty-state__content:empty{display:none}:host(.kf-empty-state--card) .kf-empty-state__content{display:flex;flex-direction:column;align-items:stretch;gap:var(--kf-space-md);align-self:stretch;color:var(--kf-color-text);font-size:var(--kf-font-size-body-sm);line-height:1.5}:host(.kf-empty-state--card.kf-empty-state--error) .kf-empty-state__content{color:var(--kf-color-text)}:host(.kf-empty-state--card) .kf-empty-state__icon{display:flex;align-items:center;justify-content:center;width:56px;height:56px;border-radius:50%;background:var(--kf-color-surface);color:var(--kf-color-text-muted)}:host(.kf-empty-state--card.kf-empty-state--ok) .kf-empty-state__icon{background:var(--kf-color-success-soft);color:var(--kf-color-success-strong)}:host(.kf-empty-state--card.kf-empty-state--warn) .kf-empty-state__icon{background:var(--kf-color-warning-soft);color:var(--kf-color-warning-strong)}:host(.kf-empty-state--card.kf-empty-state--info) .kf-empty-state__icon{background:var(--kf-color-info-soft);color:var(--kf-color-info-strong)}:host(.kf-empty-state--card.kf-empty-state--error) .kf-empty-state__icon{background:var(--kf-color-error-soft);color:var(--kf-color-error-strong)}\n"] }]
|
|
6196
|
-
}], propDecorators: { icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], tone: [{ type: i0.Input, args: [{ isSignal: true, alias: "tone", required: false }] }], variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }] } });
|
|
6335
|
+
}, template: "@if (icon(); as iconName) {\n <span class=\"kf-empty-state__icon\">\n <kf-icon [name]=\"iconName\" [size]=\"iconSize()\" />\n </span>\n}\n@if (title(); as titleText) {\n @switch (headingLevel()) {\n @case (2) {\n <h2 class=\"kf-empty-state__title\">{{ titleText }}</h2>\n }\n @case (3) {\n <h3 class=\"kf-empty-state__title\">{{ titleText }}</h3>\n }\n @case (4) {\n <h4 class=\"kf-empty-state__title\">{{ titleText }}</h4>\n }\n @default {\n <p class=\"kf-empty-state__title\">{{ titleText }}</p>\n }\n }\n}\n<div class=\"kf-empty-state__content\">\n <ng-content />\n</div>\n<div class=\"kf-empty-state__actions\"><ng-content select=\"[kf-empty-state-actions]\" /></div>\n<div class=\"kf-empty-state__footer\"><ng-content select=\"[kf-empty-state-footer]\" /></div>\n", styles: [":host{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:var(--kf-space-sm);padding:var(--kf-space-xl);border:1px dashed var(--kf-color-border-strong);border-radius:var(--kf-radius-md);background:var(--kf-color-surface);color:var(--kf-color-text-muted);font:inherit;text-align:center}:host(.kf-empty-state--error){border:none;background:var(--kf-color-error-soft)}.kf-empty-state__content{color:var(--kf-color-text-muted);font-family:var(--kf-font-body)}:host(.kf-empty-state--error) .kf-empty-state__content{color:var(--kf-color-error-strong)}.kf-empty-state__title{margin:0;font-family:var(--kf-font-title);font-size:var(--kf-font-size-title-sm);font-weight:inherit;line-height:1.25;color:var(--kf-color-ink)}.kf-empty-state__actions{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:var(--kf-space-sm)}.kf-empty-state__actions>::ng-deep [kf-empty-state-actions]{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:var(--kf-space-sm)}.kf-empty-state__actions:empty,.kf-empty-state__footer:empty{display:none}.kf-empty-state__footer{display:flex;flex-direction:column;align-items:center;gap:var(--kf-space-xs);font-size:var(--kf-font-size-caption);color:var(--kf-color-text)}:host(.kf-empty-state--ok) .kf-empty-state__icon{color:var(--kf-color-success-strong)}:host(.kf-empty-state--warn) .kf-empty-state__icon{color:var(--kf-color-warning-strong)}:host(.kf-empty-state--info) .kf-empty-state__icon{color:var(--kf-color-info-strong)}:host(.kf-empty-state--flat){padding:var(--kf-space-lg) var(--kf-space-md);border:0;background:transparent}:host(.kf-empty-state--sm) .kf-empty-state__title{font-weight:var(--kf-font-weight-title)}:host(.kf-empty-state--sm) .kf-empty-state__content{font-size:var(--kf-font-size-body-sm);line-height:1.5}:host(.kf-empty-state--text-neutral.kf-empty-state--error) .kf-empty-state__content{color:var(--kf-color-text-muted)}:host(.kf-empty-state--chip){gap:var(--kf-space-md)}:host(.kf-empty-state--chip.kf-empty-state--flat){padding-block:var(--kf-space-xl)}:host(.kf-empty-state--chip) .kf-empty-state__title+.kf-empty-state__content{margin-top:calc(var(--kf-space-sm) - var(--kf-space-md))}:host(.kf-empty-state--chip) .kf-empty-state__content:empty{display:none}:host(.kf-empty-state--chip) .kf-empty-state__icon{display:flex;align-items:center;justify-content:center;width:56px;height:56px;border-radius:50%;background:var(--kf-color-primary-soft);color:var(--kf-color-primary-active)}:host(.kf-empty-state--chip.kf-empty-state--ok) .kf-empty-state__icon{background:var(--kf-color-success-soft);color:var(--kf-color-success-strong)}:host(.kf-empty-state--chip.kf-empty-state--warn) .kf-empty-state__icon{background:var(--kf-color-warning-soft);color:var(--kf-color-warning-strong)}:host(.kf-empty-state--chip.kf-empty-state--info) .kf-empty-state__icon{background:var(--kf-color-info-soft);color:var(--kf-color-info-strong)}:host(.kf-empty-state--chip.kf-empty-state--error) .kf-empty-state__icon{background:var(--kf-color-error-soft);color:var(--kf-color-error-strong)}:host(.kf-empty-state--chip.kf-empty-state--error:not(.kf-empty-state--flat)) .kf-empty-state__icon{background:var(--kf-color-white)}:host(.kf-empty-state--card){box-sizing:border-box;width:min(480px,100%);gap:var(--kf-space-md);padding:var(--kf-space-xl) var(--kf-space-lg);border:1px solid var(--kf-color-border);border-radius:var(--kf-radius-lg);background:var(--kf-color-white);box-shadow:var(--kf-elevation-raised);color:var(--kf-color-text)}:host(.kf-empty-state--card) .kf-empty-state__title+.kf-empty-state__content{margin-top:calc(var(--kf-space-sm) - var(--kf-space-md))}:host(.kf-empty-state--card) .kf-empty-state__content>::ng-deep :is(p,ol,ul),:host(.kf-empty-state--card) .kf-empty-state__footer>::ng-deep [kf-empty-state-footer] :is(p),:host(.kf-empty-state--card) .kf-empty-state__footer>::ng-deep p[kf-empty-state-footer]{margin:0}:host(.kf-empty-state--card) .kf-empty-state__content:empty{display:none}:host(.kf-empty-state--card) .kf-empty-state__content{display:flex;flex-direction:column;align-items:stretch;gap:var(--kf-space-md);align-self:stretch;color:var(--kf-color-text);font-size:var(--kf-font-size-body-sm);line-height:1.5}:host(.kf-empty-state--card.kf-empty-state--error) .kf-empty-state__content{color:var(--kf-color-text)}:host(.kf-empty-state--card) .kf-empty-state__icon{display:flex;align-items:center;justify-content:center;width:56px;height:56px;border-radius:50%;background:var(--kf-color-surface);color:var(--kf-color-text-muted)}:host(.kf-empty-state--card.kf-empty-state--ok) .kf-empty-state__icon{background:var(--kf-color-success-soft);color:var(--kf-color-success-strong)}:host(.kf-empty-state--card.kf-empty-state--warn) .kf-empty-state__icon{background:var(--kf-color-warning-soft);color:var(--kf-color-warning-strong)}:host(.kf-empty-state--card.kf-empty-state--info) .kf-empty-state__icon{background:var(--kf-color-info-soft);color:var(--kf-color-info-strong)}:host(.kf-empty-state--card.kf-empty-state--error) .kf-empty-state__icon{background:var(--kf-color-error-soft);color:var(--kf-color-error-strong)}\n"] }]
|
|
6336
|
+
}], propDecorators: { icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], tone: [{ type: i0.Input, args: [{ isSignal: true, alias: "tone", required: false }] }], variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], headingLevel: [{ type: i0.Input, args: [{ isSignal: true, alias: "headingLevel", required: false }] }], iconChip: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconChip", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], textTone: [{ type: i0.Input, args: [{ isSignal: true, alias: "textTone", required: false }] }] } });
|
|
6197
6337
|
|
|
6198
6338
|
/**
|
|
6199
6339
|
* Bloque placeholder con shimmer para contenido que todavía carga: una línea
|
|
@@ -6373,7 +6513,7 @@ class SelectOverlay {
|
|
|
6373
6513
|
}
|
|
6374
6514
|
}
|
|
6375
6515
|
|
|
6376
|
-
let nextId$
|
|
6516
|
+
let nextId$6 = 0;
|
|
6377
6517
|
/** Ancho mínimo del panel flotante en `variant="compact"` — el trigger de
|
|
6378
6518
|
* ese modo puede medir menos de 45px (ej. "10" + caret), y sin este piso
|
|
6379
6519
|
* la opción quedaría apretada contra ese mismo ancho angosto. 72px es lo
|
|
@@ -6549,7 +6689,7 @@ class Select {
|
|
|
6549
6689
|
panelWidth = input('trigger', /* @ts-ignore */
|
|
6550
6690
|
...(ngDevMode ? [{ debugName: "panelWidth" }] : /* istanbul ignore next */ []));
|
|
6551
6691
|
valueChange = output();
|
|
6552
|
-
instanceId = `kf-select-${nextId$
|
|
6692
|
+
instanceId = `kf-select-${nextId$6++}`;
|
|
6553
6693
|
triggerId = `${this.instanceId}-trigger`;
|
|
6554
6694
|
listboxId = `${this.instanceId}-listbox`;
|
|
6555
6695
|
errorId = `${this.instanceId}-error`;
|
|
@@ -7121,6 +7261,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
7121
7261
|
args: [{ selector: 'kf-view-toggle', imports: [Icon], template: "<div\n class=\"kf-view-toggle\"\n role=\"radiogroup\"\n [attr.aria-label]=\"ariaLabel()\"\n [attr.aria-disabled]=\"disabled() ? 'true' : null\"\n>\n <button\n type=\"button\"\n role=\"radio\"\n class=\"kf-view-toggle__option\"\n [class.kf-view-toggle__option--icon]=\"iconOnly()\"\n [class.kf-view-toggle__option--active]=\"view() === 'table'\"\n [attr.aria-checked]=\"view() === 'table'\"\n [attr.aria-label]=\"iconOnly() ? tableLabel() : null\"\n [attr.title]=\"iconOnly() ? tableLabel() : null\"\n [attr.tabindex]=\"view() === 'table' ? 0 : -1\"\n [disabled]=\"disabled()\"\n (click)=\"select('table')\"\n (keydown)=\"onKeydown($event)\"\n >\n @if (iconOnly()) {\n <kf-icon name=\"list\" size=\"md\" />\n } @else {\n {{ tableLabel() }}\n }\n </button>\n <button\n type=\"button\"\n role=\"radio\"\n class=\"kf-view-toggle__option\"\n [class.kf-view-toggle__option--icon]=\"iconOnly()\"\n [class.kf-view-toggle__option--active]=\"view() === 'cards'\"\n [attr.aria-checked]=\"view() === 'cards'\"\n [attr.aria-label]=\"iconOnly() ? cardsLabel() : null\"\n [attr.title]=\"iconOnly() ? cardsLabel() : null\"\n [attr.tabindex]=\"view() === 'cards' ? 0 : -1\"\n [disabled]=\"disabled()\"\n (click)=\"select('cards')\"\n (keydown)=\"onKeydown($event)\"\n >\n @if (iconOnly()) {\n <kf-icon name=\"layout-grid\" size=\"md\" />\n } @else {\n {{ cardsLabel() }}\n }\n </button>\n</div>\n", styles: [":host{display:inline-block;font-family:var(--kf-font-body)}.kf-view-toggle{display:inline-flex;align-items:stretch;gap:2px;padding:2px;background:var(--kf-color-surface);border:1px solid var(--kf-color-border);border-radius:var(--kf-radius-sm)}.kf-view-toggle__option{font:inherit;font-size:.85rem;line-height:1;color:var(--kf-color-text-muted);background:transparent;border:none;border-radius:var(--kf-radius-xs);padding:var(--kf-space-xs) var(--kf-space-sm);cursor:pointer;transition:background var(--kf-motion-fast, .14s),color var(--kf-motion-fast, .14s),box-shadow var(--kf-motion-fast, .14s)}.kf-view-toggle__option:hover:not(.kf-view-toggle__option--active,:disabled){color:var(--kf-color-text)}.kf-view-toggle__option:focus-visible{outline:none;box-shadow:var(--kf-shadow-focus)}.kf-view-toggle__option--active{color:var(--kf-color-ink);background:var(--kf-color-white);box-shadow:var(--kf-shadow-xs)}.kf-view-toggle__option:disabled{opacity:.5;cursor:not-allowed}.kf-view-toggle__option--icon{display:inline-flex;align-items:center;justify-content:center;min-width:32px;min-height:32px;padding:var(--kf-space-xs)}@media(max-width:640px),(pointer:coarse){.kf-view-toggle__option--icon{min-width:44px;min-height:44px}}@media(prefers-reduced-motion:reduce){.kf-view-toggle__option{transition:none}}\n"] }]
|
|
7122
7262
|
}], propDecorators: { view: [{ type: i0.Input, args: [{ isSignal: true, alias: "view", required: true }] }], iconOnly: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconOnly", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], tableLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "tableLabel", required: false }] }], cardsLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "cardsLabel", required: false }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }], viewChange: [{ type: i0.Output, args: ["viewChange"] }] } });
|
|
7123
7263
|
|
|
7264
|
+
/** Controles que no pueden vivir dentro de una tarjeta `role="button"` (controles anidados). */
|
|
7265
|
+
const NESTED_CONTROL_SELECTOR = 'a[href], button, input, select, textarea, [role="button"], [role="link"], [role="menuitem"], [role="checkbox"], [role="switch"], [role="tab"], [contenteditable="true"]';
|
|
7124
7266
|
/** Controles cuyo clic/Enter NO debe activar además la fila o tarjeta que los contiene. */
|
|
7125
7267
|
const INTERACTIVE_CONTROL_SELECTOR = 'a[href], button, input, select, textarea, summary, label, [role="button"], [role="link"], [role="menuitem"], [role="checkbox"], [role="switch"], [role="tab"], [contenteditable="true"]';
|
|
7126
7268
|
/** Piso de ancho de una columna `grow` que no declara `minWidth` ni `width`. */
|
|
@@ -7297,10 +7439,29 @@ const DEFAULT_PAGE_SIZE_OPTIONS = [10, 25, 50];
|
|
|
7297
7439
|
* [cellAriaLabel]="stageLabel" (cellClick)="openStage($event.row, $event.column)" />
|
|
7298
7440
|
*
|
|
7299
7441
|
* Convive con `rowClick`: la fila sigue emitiéndolo desde cualquier punto que
|
|
7300
|
-
* no sea una celda interactiva. En tarjetas, la tarjeta deja
|
|
7301
|
-
*
|
|
7302
|
-
* `
|
|
7303
|
-
*
|
|
7442
|
+
* no sea una celda interactiva. En tarjetas, sin `[rowClickable]` la tarjeta deja
|
|
7443
|
+
* de ser clicable cuando hay una columna `interactive` o `cardRole: 'action'`.
|
|
7444
|
+
* `sticky`, `cellTemplates`, `currentRowKey`, la ordenación y la paginación no cambian.
|
|
7445
|
+
*
|
|
7446
|
+
* Tarjeta clicable con controles adentro: una tarjeta nunca es un `role="button"` si
|
|
7447
|
+
* contiene un control (WCAG 4.1.2, controles anidados). Con `selectable`, `cardMenu`, una
|
|
7448
|
+
* columna `interactive`, una `cardRole: 'action'` o una columna con `hasControls: true`
|
|
7449
|
+
* (el `cellTemplates` trae un enlace, un botón, un interruptor, una casilla o un campo), la
|
|
7450
|
+
* tarjeta clicable (`rowClickable` o el cálculo automático) queda sin rol ni `tabindex` y la
|
|
7451
|
+
* abre un `<button>` propio, visible con el foco como anillo de la tarjeta (nombre con
|
|
7452
|
+
* `cardOpenLabel`, por defecto «Abrir {título}»), que va primero en el orden de Tab. Un clic
|
|
7453
|
+
* o Enter dentro de un control interno no abre la fila; el clic en el resto de la tarjeta
|
|
7454
|
+
* sigue abriéndola con el mouse. Una tarjeta sin controles conserva el `role="button"`:
|
|
7455
|
+
*
|
|
7456
|
+
* columns = [
|
|
7457
|
+
* { key: 'plate', label: 'Placa', cardRole: 'title' },
|
|
7458
|
+
* { key: 'owner', label: 'Responsable', hasControls: true },
|
|
7459
|
+
* ];
|
|
7460
|
+
* <kf-data-table [columns]="columns" [rows]="units" cardable (rowClick)="open($event.row)"
|
|
7461
|
+
* [cellTemplates]="{ owner: ownerLink }" [cardOpenLabel]="openLabel" />
|
|
7462
|
+
*
|
|
7463
|
+
* En desarrollo, una tarjeta con `role="button"` que contiene un control sin declarar avisa
|
|
7464
|
+
* con `console.warn` una sola vez.
|
|
7304
7465
|
*/
|
|
7305
7466
|
class DataTable {
|
|
7306
7467
|
columns = input.required(/* @ts-ignore */
|
|
@@ -7428,6 +7589,13 @@ class DataTable {
|
|
|
7428
7589
|
this.activeView();
|
|
7429
7590
|
this.evaluateAutoCards();
|
|
7430
7591
|
});
|
|
7592
|
+
afterRenderEffect(() => {
|
|
7593
|
+
this.activeView();
|
|
7594
|
+
this.displayedRows();
|
|
7595
|
+
this.shownColumns();
|
|
7596
|
+
this.cardInteractive();
|
|
7597
|
+
this.warnIfNestedControls();
|
|
7598
|
+
});
|
|
7431
7599
|
afterNextRender(() => {
|
|
7432
7600
|
const observer = new ResizeObserver(() => this.evaluateAutoCards());
|
|
7433
7601
|
observer.observe(this.hostEl.nativeElement);
|
|
@@ -7739,9 +7907,12 @@ class DataTable {
|
|
|
7739
7907
|
cardMenuAriaLabel(row) {
|
|
7740
7908
|
return this.cardMenuLabel()?.(row) ?? 'Acciones de la fila';
|
|
7741
7909
|
}
|
|
7742
|
-
/**
|
|
7910
|
+
/**
|
|
7911
|
+
* La tarjeta lleva casilla, menú o celdas con controles propios: no puede ser un `role="button"`
|
|
7912
|
+
* con controles adentro, la abre su botón `card-open`.
|
|
7913
|
+
*/
|
|
7743
7914
|
cardHasNestedControls(row) {
|
|
7744
|
-
return this.selectable() || this.cardMenuEntries(row) !== null;
|
|
7915
|
+
return (this.selectable() || this.cardMenuEntries(row) !== null || this.cardColumnsHaveControls());
|
|
7745
7916
|
}
|
|
7746
7917
|
cardOpenAriaLabel(row) {
|
|
7747
7918
|
const custom = this.cardOpenLabel()?.(row);
|
|
@@ -7793,7 +7964,10 @@ class DataTable {
|
|
|
7793
7964
|
density = input('comfortable', /* @ts-ignore */
|
|
7794
7965
|
...(ngDevMode ? [{ debugName: "density" }] : /* istanbul ignore next */ []));
|
|
7795
7966
|
/** Fuerza si la fila entera dispara `rowClick` en la vista de tabla —
|
|
7796
|
-
* ver `rowInteractive` para el cálculo automático cuando no se define.
|
|
7967
|
+
* ver `rowInteractive` para el cálculo automático cuando no se define. En tarjetas fuerza
|
|
7968
|
+
* `cardInteractive`; una tarjeta con controles propios (columnas `interactive`, `action` o
|
|
7969
|
+
* `hasControls`, `selectable`, `cardMenu`) se abre con su botón `card-open`, nunca como
|
|
7970
|
+
* `role="button"`. */
|
|
7797
7971
|
rowClickable = input(null, /* @ts-ignore */
|
|
7798
7972
|
...(ngDevMode ? [{ debugName: "rowClickable" }] : /* istanbul ignore next */ []));
|
|
7799
7973
|
/**
|
|
@@ -7803,7 +7977,7 @@ class DataTable {
|
|
|
7803
7977
|
* dentro de una celda — así una página de N filas no suma N paradas de Tab
|
|
7804
7978
|
* sin rol. El clic con mouse sigue emitiendo `rowClick`. Default `true`
|
|
7805
7979
|
* (comportamiento histórico). No afecta a las tarjetas, que son
|
|
7806
|
-
* `role="button"
|
|
7980
|
+
* `role="button"` salvo que lleven controles propios (ver `hasControls`).
|
|
7807
7981
|
*/
|
|
7808
7982
|
rowFocusable = input(true, /* @ts-ignore */
|
|
7809
7983
|
...(ngDevMode ? [{ debugName: "rowFocusable" }] : /* istanbul ignore next */ []));
|
|
@@ -8180,7 +8354,9 @@ class DataTable {
|
|
|
8180
8354
|
/**
|
|
8181
8355
|
* La card entera es clickeable solo si no tiene acciones propias: un
|
|
8182
8356
|
* `role="button"` con botones adentro es inválido y deja el foco ambiguo.
|
|
8183
|
-
* Con columnas `action`, la interacción la manejan esos botones.
|
|
8357
|
+
* Con columnas `action`, la interacción la manejan esos botones. Una columna con
|
|
8358
|
+
* `hasControls` no la desactiva: la tarjeta sigue siendo clicable, pero se abre con
|
|
8359
|
+
* su botón `card-open` en vez de ser un `role="button"`.
|
|
8184
8360
|
*/
|
|
8185
8361
|
cardInteractive = computed(() => this.rowClickable() ??
|
|
8186
8362
|
(this.cardActionColumns().length === 0 && !this.hasInteractiveColumns()), /* @ts-ignore */
|
|
@@ -8188,6 +8364,12 @@ class DataTable {
|
|
|
8188
8364
|
/** Hay al menos una columna `interactive` (celdas con botón propio). */
|
|
8189
8365
|
hasInteractiveColumns = computed(() => this.shownColumns().some((column) => column.interactive), /* @ts-ignore */
|
|
8190
8366
|
...(ngDevMode ? [{ debugName: "hasInteractiveColumns" }] : /* istanbul ignore next */ []));
|
|
8367
|
+
/**
|
|
8368
|
+
* Alguna columna mostrada trae controles propios: es `interactive`, va en la zona de acciones
|
|
8369
|
+
* (`cardRole: 'action'`) o declara `hasControls`.
|
|
8370
|
+
*/
|
|
8371
|
+
cardColumnsHaveControls = computed(() => this.shownColumns().some((column) => column.interactive || column.hasControls || column.cardRole === 'action'), /* @ts-ignore */
|
|
8372
|
+
...(ngDevMode ? [{ debugName: "cardColumnsHaveControls" }] : /* istanbul ignore next */ []));
|
|
8191
8373
|
/**
|
|
8192
8374
|
* Mismo criterio que `cardInteractive`, para la vista de tabla: la fila
|
|
8193
8375
|
* entera dispara `rowClick` solo si no hay una columna `action` que ya
|
|
@@ -8274,6 +8456,26 @@ class DataTable {
|
|
|
8274
8456
|
}
|
|
8275
8457
|
this.rowClick.emit({ row, index });
|
|
8276
8458
|
}
|
|
8459
|
+
warnedNestedControls = false;
|
|
8460
|
+
/**
|
|
8461
|
+
* Solo desarrollo: una tarjeta `role="button"` con un control adentro es HTML inválido. La tabla no
|
|
8462
|
+
* ve dentro de los templates, así que avisa una vez y pide declarar `hasControls` en la columna.
|
|
8463
|
+
*/
|
|
8464
|
+
warnIfNestedControls() {
|
|
8465
|
+
if (!isDevMode() || this.warnedNestedControls) {
|
|
8466
|
+
return;
|
|
8467
|
+
}
|
|
8468
|
+
for (const card of this.hostEl.nativeElement.querySelectorAll('.kf-data-table__card[role="button"]')) {
|
|
8469
|
+
const control = card.querySelector(NESTED_CONTROL_SELECTOR);
|
|
8470
|
+
if (control) {
|
|
8471
|
+
this.warnedNestedControls = true;
|
|
8472
|
+
console.warn(`[kf-data-table] una tarjeta clicable es un role="button" y contiene un control (<${control.localName}>): ` +
|
|
8473
|
+
'un control dentro de un botón es inválido. Declarar `hasControls: true` en la columna cuyo ' +
|
|
8474
|
+
'template lo trae para que la fila se abra con un botón propio.');
|
|
8475
|
+
return;
|
|
8476
|
+
}
|
|
8477
|
+
}
|
|
8478
|
+
}
|
|
8277
8479
|
/** Activación de una celda interactiva (clic, o Enter/Espacio sobre su botón). */
|
|
8278
8480
|
onCellClick(row, column, index) {
|
|
8279
8481
|
this.cellClick.emit({ row, column, index });
|
|
@@ -8743,7 +8945,7 @@ class ContentState {
|
|
|
8743
8945
|
customLoading = computed(() => this.projectedLoading() ?? this.loadingTemplate(), /* @ts-ignore */
|
|
8744
8946
|
...(ngDevMode ? [{ debugName: "customLoading" }] : /* istanbul ignore next */ []));
|
|
8745
8947
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: ContentState, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
8746
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: ContentState, isStandalone: true, selector: "kf-content-state", inputs: { state: { classPropertyName: "state", publicName: "state", isSignal: true, isRequired: true, transformFunction: null }, load: { classPropertyName: "load", publicName: "load", isSignal: true, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, subtitle: { classPropertyName: "subtitle", publicName: "subtitle", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, loadingLabel: { classPropertyName: "loadingLabel", publicName: "loadingLabel", isSignal: true, isRequired: false, transformFunction: null }, loadingTemplate: { classPropertyName: "loadingTemplate", publicName: "loadingTemplate", isSignal: true, isRequired: false, transformFunction: null }, loadingPreset: { classPropertyName: "loadingPreset", publicName: "loadingPreset", isSignal: true, isRequired: false, transformFunction: null } }, queries: [{ propertyName: "projectedLoading", first: true, predicate: ContentStateLoading, descendants: true, read: TemplateRef, isSignal: true }], ngImport: i0, template: "@switch (state()) {\n @case ('ready') {\n <ng-content />\n }\n @case ('loading') {\n @if (load() === 'skeleton') {\n <!-- Fuera del contenedor `aria-busy`: una regi\u00F3n viva ocupada no anuncia nada. -->\n <span class=\"kf-sr-only\" role=\"status\">{{ loadingLabel() }}</span>\n }\n <div class=\"kf-content-state__loading\" aria-busy=\"true\">\n @if (load() === 'spinner') {\n <kf-spinner [label]=\"loadingLabel()\" />\n } @else {\n @if (customLoading(); as template) {\n <ng-container [ngTemplateOutlet]=\"template\" />\n } @else if (loadingPreset(); as preset) {\n <kf-skeleton-preset [variant]=\"preset\" />\n } @else {\n <kf-skeleton />\n <kf-skeleton width=\"80%\" />\n <kf-skeleton width=\"60%\" />\n }\n }\n </div>\n }\n @default {\n <kf-empty-state\n [tone]=\"state() === 'error' ? 'error' : 'neutral'\"\n [variant]=\"variant()\"\n [icon]=\"icon()\"\n [attr.role]=\"state() === 'error' ? 'alert' : 'status'\"\n >\n @if (title()) {\n <p class=\"kf-content-state__title\">{{ title() }}</p>\n }\n @if (subtitle()) {\n <p class=\"kf-content-state__subtitle\">{{ subtitle() }}</p>\n }\n <div class=\"kf-content-state__actions\"><ng-content select=\"[actions]\" /></div>\n </kf-empty-state>\n }\n}\n", styles: [".kf-sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}:host{position:relative;display:block;font-family:var(--kf-font-body)}.kf-content-state__loading{display:flex;flex-direction:column;gap:var(--kf-space-sm);min-width:min(12rem,100vw);box-sizing:border-box}.kf-content-state__title{margin:0;font-family:var(--kf-font-title);font-weight:700;color:var(--kf-color-ink)}.kf-content-state__subtitle{margin:0;color:var(--kf-color-text-muted)}.kf-content-state__actions:empty{display:none}.kf-content-state__actions{display:flex;flex-wrap:wrap;justify-content:center;gap:var(--kf-space-sm);margin-top:var(--kf-space-sm)}\n"], dependencies: [{ kind: "component", type: EmptyState, selector: "kf-empty-state", inputs: ["icon", "tone", "variant", "title"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: Skeleton, selector: "kf-skeleton", inputs: ["variant", "width", "height"] }, { kind: "component", type: SkeletonPreset, selector: "kf-skeleton-preset", inputs: ["variant", "count", "columns", "label"] }, { kind: "component", type: Spinner, selector: "kf-spinner", inputs: ["size", "label", "onDark"] }] });
|
|
8948
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: ContentState, isStandalone: true, selector: "kf-content-state", inputs: { state: { classPropertyName: "state", publicName: "state", isSignal: true, isRequired: true, transformFunction: null }, load: { classPropertyName: "load", publicName: "load", isSignal: true, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, subtitle: { classPropertyName: "subtitle", publicName: "subtitle", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, loadingLabel: { classPropertyName: "loadingLabel", publicName: "loadingLabel", isSignal: true, isRequired: false, transformFunction: null }, loadingTemplate: { classPropertyName: "loadingTemplate", publicName: "loadingTemplate", isSignal: true, isRequired: false, transformFunction: null }, loadingPreset: { classPropertyName: "loadingPreset", publicName: "loadingPreset", isSignal: true, isRequired: false, transformFunction: null } }, queries: [{ propertyName: "projectedLoading", first: true, predicate: ContentStateLoading, descendants: true, read: TemplateRef, isSignal: true }], ngImport: i0, template: "@switch (state()) {\n @case ('ready') {\n <ng-content />\n }\n @case ('loading') {\n @if (load() === 'skeleton') {\n <!-- Fuera del contenedor `aria-busy`: una regi\u00F3n viva ocupada no anuncia nada. -->\n <span class=\"kf-sr-only\" role=\"status\">{{ loadingLabel() }}</span>\n }\n <div class=\"kf-content-state__loading\" aria-busy=\"true\">\n @if (load() === 'spinner') {\n <kf-spinner [label]=\"loadingLabel()\" />\n } @else {\n @if (customLoading(); as template) {\n <ng-container [ngTemplateOutlet]=\"template\" />\n } @else if (loadingPreset(); as preset) {\n <kf-skeleton-preset [variant]=\"preset\" />\n } @else {\n <kf-skeleton />\n <kf-skeleton width=\"80%\" />\n <kf-skeleton width=\"60%\" />\n }\n }\n </div>\n }\n @default {\n <kf-empty-state\n [tone]=\"state() === 'error' ? 'error' : 'neutral'\"\n [variant]=\"variant()\"\n [icon]=\"icon()\"\n [attr.role]=\"state() === 'error' ? 'alert' : 'status'\"\n >\n @if (title()) {\n <p class=\"kf-content-state__title\">{{ title() }}</p>\n }\n @if (subtitle()) {\n <p class=\"kf-content-state__subtitle\">{{ subtitle() }}</p>\n }\n <div class=\"kf-content-state__actions\"><ng-content select=\"[actions]\" /></div>\n </kf-empty-state>\n }\n}\n", styles: [".kf-sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}:host{position:relative;display:block;font-family:var(--kf-font-body)}.kf-content-state__loading{display:flex;flex-direction:column;gap:var(--kf-space-sm);min-width:min(12rem,100vw);box-sizing:border-box}.kf-content-state__title{margin:0;font-family:var(--kf-font-title);font-weight:700;color:var(--kf-color-ink)}.kf-content-state__subtitle{margin:0;color:var(--kf-color-text-muted)}.kf-content-state__actions:empty{display:none}.kf-content-state__actions{display:flex;flex-wrap:wrap;justify-content:center;gap:var(--kf-space-sm);margin-top:var(--kf-space-sm)}\n"], dependencies: [{ kind: "component", type: EmptyState, selector: "kf-empty-state", inputs: ["icon", "tone", "variant", "title", "headingLevel", "iconChip", "size", "textTone"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: Skeleton, selector: "kf-skeleton", inputs: ["variant", "width", "height"] }, { kind: "component", type: SkeletonPreset, selector: "kf-skeleton-preset", inputs: ["variant", "count", "columns", "label"] }, { kind: "component", type: Spinner, selector: "kf-spinner", inputs: ["size", "label", "onDark"] }] });
|
|
8747
8949
|
}
|
|
8748
8950
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: ContentState, decorators: [{
|
|
8749
8951
|
type: Component,
|
|
@@ -9251,6 +9453,19 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
9251
9453
|
* `[autoClose]="false"` lo cierra quien consume al terminar la operación.
|
|
9252
9454
|
* `cancelled` se emite al cerrar por cualquier vía distinta de confirmar.
|
|
9253
9455
|
*
|
|
9456
|
+
* ## Motivo antes de una acción sensible
|
|
9457
|
+
* Con `reasonLabel` el diálogo pide un motivo (suspender, rechazar, revocar): `reasonMinLength` y
|
|
9458
|
+
* `reasonMaxLength` lo acotan (con máximo se muestra el contador y el campo no admite más) y `confirmed`
|
|
9459
|
+
* entrega `{ reason }` ya recortado. `reasonOptional` deja el motivo en blanco: solo se valida si se escribió
|
|
9460
|
+
* algo y, en blanco, `reason` llega vacío. Si la operación falla, el consumidor deja el diálogo abierto
|
|
9461
|
+
* (`[autoClose]="false"`) y pasa el texto en `error` (con `errorTitle` opcional): se ve en una alerta al final
|
|
9462
|
+
* del cuerpo. Las consecuencias en lista van como contenido proyectado.
|
|
9463
|
+
*
|
|
9464
|
+
* <kf-confirm-dialog [(open)]="open" tone="danger" title="Suspender la cuenta" message="No podrá ingresar."
|
|
9465
|
+
* reasonLabel="Motivo" [reasonMinLength]="3" [reasonMaxLength]="500" reasonHint="Queda en la auditoría."
|
|
9466
|
+
* confirmLabel="Suspender" [autoClose]="false" [busy]="saving()" [error]="failure()"
|
|
9467
|
+
* (confirmed)="suspend($event.reason)" />
|
|
9468
|
+
*
|
|
9254
9469
|
* <kf-confirm-dialog [(open)]="open" tone="danger" title="Desactivar división"
|
|
9255
9470
|
* message="Las órdenes abiertas se conservan." consequence="Dejará de recibir tickets."
|
|
9256
9471
|
* reasonLabel="Motivo" [reasonMinLength]="8" confirmLabel="Desactivar"
|
|
@@ -9283,6 +9498,11 @@ class ConfirmDialog {
|
|
|
9283
9498
|
reasonLabel = input(/* @ts-ignore */
|
|
9284
9499
|
...(ngDevMode ? [undefined, { debugName: "reasonLabel" }] : /* istanbul ignore next */ []));
|
|
9285
9500
|
reasonMinLength = input(0, { ...(ngDevMode ? { debugName: "reasonMinLength" } : /* istanbul ignore next */ {}), transform: numberAttribute });
|
|
9501
|
+
/** Largo máximo del motivo: acota el campo y muestra el contador. Sin valor no hay tope. */
|
|
9502
|
+
reasonMaxLength = input(null, /* @ts-ignore */
|
|
9503
|
+
...(ngDevMode ? [{ debugName: "reasonMaxLength" }] : /* istanbul ignore next */ []));
|
|
9504
|
+
/** El motivo se puede dejar en blanco; si se escribe, vale `reasonMinLength`. Sin efecto sin `reasonLabel`. */
|
|
9505
|
+
reasonOptional = input(false, { ...(ngDevMode ? { debugName: "reasonOptional" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
9286
9506
|
reasonPlaceholder = input('', /* @ts-ignore */
|
|
9287
9507
|
...(ngDevMode ? [{ debugName: "reasonPlaceholder" }] : /* istanbul ignore next */ []));
|
|
9288
9508
|
reasonHint = input(/* @ts-ignore */
|
|
@@ -9290,6 +9510,12 @@ class ConfirmDialog {
|
|
|
9290
9510
|
/** Mensaje de error del motivo; por defecto se arma con `reasonMinLength`. */
|
|
9291
9511
|
reasonError = input(/* @ts-ignore */
|
|
9292
9512
|
...(ngDevMode ? [undefined, { debugName: "reasonError" }] : /* istanbul ignore next */ []));
|
|
9513
|
+
/** Texto de una operación que falló, en una alerta al final del cuerpo; sin valor no se dibuja. */
|
|
9514
|
+
error = input(/* @ts-ignore */
|
|
9515
|
+
...(ngDevMode ? [undefined, { debugName: "error" }] : /* istanbul ignore next */ []));
|
|
9516
|
+
/** Título de la alerta de `error`. */
|
|
9517
|
+
errorTitle = input('No se pudo completar la acción', /* @ts-ignore */
|
|
9518
|
+
...(ngDevMode ? [{ debugName: "errorTitle" }] : /* istanbul ignore next */ []));
|
|
9293
9519
|
acknowledgeLabel = input(/* @ts-ignore */
|
|
9294
9520
|
...(ngDevMode ? [undefined, { debugName: "acknowledgeLabel" }] : /* istanbul ignore next */ []));
|
|
9295
9521
|
acknowledgeError = input('Marcar la casilla para confirmar.', /* @ts-ignore */
|
|
@@ -9351,8 +9577,8 @@ class ConfirmDialog {
|
|
|
9351
9577
|
if (this.busy()) {
|
|
9352
9578
|
return;
|
|
9353
9579
|
}
|
|
9354
|
-
const
|
|
9355
|
-
const reasonInvalid =
|
|
9580
|
+
const reasonAsked = !!this.reasonLabel();
|
|
9581
|
+
const reasonInvalid = this.isReasonInvalid(this.reason());
|
|
9356
9582
|
const acknowledgeInvalid = !!this.acknowledgeLabel() && !this.acknowledged();
|
|
9357
9583
|
this.showReasonError.set(reasonInvalid);
|
|
9358
9584
|
this.showAcknowledgeError.set(acknowledgeInvalid);
|
|
@@ -9360,17 +9586,25 @@ class ConfirmDialog {
|
|
|
9360
9586
|
afterNextRender(() => this.focusFirstError(), { injector: this.injector });
|
|
9361
9587
|
return;
|
|
9362
9588
|
}
|
|
9363
|
-
this.confirmed.emit(
|
|
9589
|
+
this.confirmed.emit(reasonAsked ? { reason: this.reason().trim() } : {});
|
|
9364
9590
|
if (this.autoClose()) {
|
|
9365
9591
|
this.open.set(false);
|
|
9366
9592
|
}
|
|
9367
9593
|
}
|
|
9368
9594
|
onReason(value) {
|
|
9369
9595
|
this.reason.set(value);
|
|
9370
|
-
if (this.showReasonError() &&
|
|
9596
|
+
if (this.showReasonError() && !this.isReasonInvalid(value)) {
|
|
9371
9597
|
this.showReasonError.set(false);
|
|
9372
9598
|
}
|
|
9373
9599
|
}
|
|
9600
|
+
/** Un motivo pedido es obligatorio; uno opcional solo se valida cuando se escribió algo. */
|
|
9601
|
+
isReasonInvalid(value) {
|
|
9602
|
+
if (!this.reasonLabel()) {
|
|
9603
|
+
return false;
|
|
9604
|
+
}
|
|
9605
|
+
const length = value.trim().length;
|
|
9606
|
+
return length < this.minReasonLength() && !(this.reasonOptional() && length === 0);
|
|
9607
|
+
}
|
|
9374
9608
|
onAcknowledge(checked) {
|
|
9375
9609
|
this.acknowledged.set(checked);
|
|
9376
9610
|
if (checked) {
|
|
@@ -9387,12 +9621,12 @@ class ConfirmDialog {
|
|
|
9387
9621
|
this.host.nativeElement.querySelector('[aria-invalid="true"]')?.focus();
|
|
9388
9622
|
}
|
|
9389
9623
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: ConfirmDialog, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
9390
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: ConfirmDialog, isStandalone: true, selector: "kf-confirm-dialog", inputs: { open: { classPropertyName: "open", publicName: "open", isSignal: true, isRequired: false, transformFunction: null }, tone: { classPropertyName: "tone", publicName: "tone", isSignal: true, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: true, transformFunction: null }, message: { classPropertyName: "message", publicName: "message", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, iconPlacement: { classPropertyName: "iconPlacement", publicName: "iconPlacement", isSignal: true, isRequired: false, transformFunction: null }, iconTone: { classPropertyName: "iconTone", publicName: "iconTone", isSignal: true, isRequired: false, transformFunction: null }, confirmLabel: { classPropertyName: "confirmLabel", publicName: "confirmLabel", isSignal: true, isRequired: false, transformFunction: null }, cancelLabel: { classPropertyName: "cancelLabel", publicName: "cancelLabel", isSignal: true, isRequired: false, transformFunction: null }, busy: { classPropertyName: "busy", publicName: "busy", isSignal: true, isRequired: false, transformFunction: null }, consequence: { classPropertyName: "consequence", publicName: "consequence", isSignal: true, isRequired: false, transformFunction: null }, reasonLabel: { classPropertyName: "reasonLabel", publicName: "reasonLabel", isSignal: true, isRequired: false, transformFunction: null }, reasonMinLength: { classPropertyName: "reasonMinLength", publicName: "reasonMinLength", isSignal: true, isRequired: false, transformFunction: null }, reasonPlaceholder: { classPropertyName: "reasonPlaceholder", publicName: "reasonPlaceholder", isSignal: true, isRequired: false, transformFunction: null }, reasonHint: { classPropertyName: "reasonHint", publicName: "reasonHint", isSignal: true, isRequired: false, transformFunction: null }, reasonError: { classPropertyName: "reasonError", publicName: "reasonError", isSignal: true, isRequired: false, transformFunction: null }, acknowledgeLabel: { classPropertyName: "acknowledgeLabel", publicName: "acknowledgeLabel", isSignal: true, isRequired: false, transformFunction: null }, acknowledgeError: { classPropertyName: "acknowledgeError", publicName: "acknowledgeError", isSignal: true, isRequired: false, transformFunction: null }, autoClose: { classPropertyName: "autoClose", publicName: "autoClose", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { open: "openChange", confirmed: "confirmed", cancelled: "cancelled" }, ngImport: i0, template: "<kf-modal\n size=\"sm\"\n [open]=\"open()\"\n [title]=\"title()\"\n [dismissible]=\"!busy()\"\n [icon]=\"titleIcon()\"\n [iconTone]=\"titleIconTone()\"\n [initialFocus]=\"initialFocus()\"\n (openChange)=\"onOpenChange($event)\"\n>\n <div class=\"kf-confirm-dialog__body\" [class.kf-confirm-dialog__body--title-icon]=\"!!titleIcon()\">\n @if (iconPlacement() === 'body' && icon(); as iconName) {\n <span\n class=\"kf-confirm-dialog__icon\"\n [class.kf-confirm-dialog__icon--danger]=\"tone() === 'danger'\"\n >\n <kf-icon [name]=\"iconName\" size=\"lg\" />\n </span>\n }\n @if (message(); as text) {\n <p class=\"kf-confirm-dialog__message\">{{ text }}</p>\n }\n <ng-content />\n @if (consequence(); as text) {\n @if (iconPlacement() === 'title') {\n <p class=\"kf-confirm-dialog__consequence\">{{ text }}</p>\n } @else {\n <kf-alert [tone]=\"tone() === 'danger' ? 'warn' : 'info'\">{{ text }}</kf-alert>\n }\n }\n @if (reasonLabel(); as label) {\n <kf-textarea\n class=\"kf-confirm-dialog__reason\"\n required\n [label]=\"label\"\n [placeholder]=\"reasonPlaceholder()\"\n [hint]=\"reasonHint()\"\n [invalid]=\"showReasonError()\"\n [errorMessage]=\"showReasonError() ? reasonErrorText() : undefined\"\n [ngModelOptions]=\"{ standalone: true }\"\n [ngModel]=\"reason()\"\n (ngModelChange)=\"onReason($event)\"\n />\n }\n @if (acknowledgeLabel(); as label) {\n <div class=\"kf-confirm-dialog__acknowledge\">\n <kf-checkbox\n [label]=\"label\"\n [checked]=\"acknowledged()\"\n [invalid]=\"showAcknowledgeError()\"\n (checkedChange)=\"onAcknowledge($event)\"\n />\n @if (showAcknowledgeError()) {\n <span class=\"kf-confirm-dialog__error kf-field-error\" role=\"alert\">{{\n acknowledgeError()\n }}</span>\n }\n </div>\n }\n </div>\n <div footer class=\"kf-confirm-dialog__actions\">\n <kf-button\n class=\"kf-confirm-dialog__cancel\"\n variant=\"outline\"\n type=\"button\"\n [disabled]=\"busy()\"\n (click)=\"cancel()\"\n >\n {{ cancelLabel() }}\n </kf-button>\n <kf-button\n class=\"kf-confirm-dialog__confirm\"\n type=\"button\"\n [variant]=\"tone() === 'danger' ? 'danger' : 'primary'\"\n [loading]=\"busy()\"\n (click)=\"confirm()\"\n >\n {{ confirmLabel() }}\n </kf-button>\n </div>\n</kf-modal>\n", styles: [".kf-field-hint{font-size:.75rem;color:var(--kf-color-text-muted)}.kf-field-error{display:flex;align-items:center;gap:var(--kf-space-xs);font-size:.75rem;font-weight:600;color:var(--kf-color-error-strong)}:host{display:contents}.kf-confirm-dialog__body{display:flex;flex-direction:column;gap:var(--kf-space-md)}.kf-confirm-dialog__message{margin:0;font-size:var(--kf-font-size-body-sm);color:var(--kf-color-text-muted)}.kf-confirm-dialog__body--title-icon{gap:var(--kf-space-sm)}.kf-confirm-dialog__consequence{margin:0;font-size:var(--kf-font-size-body-sm);color:var(--kf-color-text)}.kf-confirm-dialog__icon{display:flex;align-items:center;justify-content:center;align-self:center;width:48px;height:48px;border-radius:var(--kf-radius-pill);background:var(--kf-color-primary-soft);color:var(--kf-color-primary)}.kf-confirm-dialog__icon--danger{background:var(--kf-color-error-soft);color:var(--kf-color-error-strong)}.kf-confirm-dialog__acknowledge{display:flex;flex-direction:column;gap:var(--kf-space-xs)}.kf-confirm-dialog__actions{display:flex;justify-content:flex-end;gap:var(--kf-space-sm)}@media(max-width:480px){.kf-confirm-dialog__body:not(.kf-confirm-dialog__body--title-icon){text-align:center}.kf-confirm-dialog__actions{flex-direction:column-reverse;align-items:stretch}}\n"], dependencies: [{ kind: "component", type: Alert, selector: "kf-alert", inputs: ["tone", "variant", "appearance", "iconAlign", "title", "dismissible", "actionsInline", "open"], outputs: ["openChange"] }, { kind: "component", type: Button, selector: "kf-button", inputs: ["variant", "size", "shape", "disabled", "type", "icon", "block", "loading", "ariaLabel", "ariaExpanded", "ariaPressed", "ariaDisabled", "ariaDescribedby", "attention", "ariaControls", "ariaHaspopup"], outputs: ["disabledClick"] }, { kind: "component", type: Checkbox, selector: "kf-checkbox", inputs: ["label", "ariaLabel", "checked", "disabled", "indeterminate", "invalid", "row"], outputs: ["checkedChange"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: Icon, selector: "kf-icon", inputs: ["name", "size", "rotate", "filled"] }, { kind: "component", type: Modal, selector: "kf-modal", inputs: ["title", "open", "dismissible", "width", "size", "dividers", "maxHeight", "fullscreenOnMobile", "panel", "initialFocus", "icon", "iconTone", "closeLabel"], outputs: ["openChange"] }, { kind: "component", type: Textarea, selector: "kf-textarea", inputs: ["label", "required", "hint", "invalid", "errorMessage", "disabled", "readonly", "placeholder", "autocapitalize", "autocorrect", "spellcheck", "enterkeyhint", "minRows", "maxRows", "maxlength", "showCounter"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
9624
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: ConfirmDialog, isStandalone: true, selector: "kf-confirm-dialog", inputs: { open: { classPropertyName: "open", publicName: "open", isSignal: true, isRequired: false, transformFunction: null }, tone: { classPropertyName: "tone", publicName: "tone", isSignal: true, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: true, transformFunction: null }, message: { classPropertyName: "message", publicName: "message", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, iconPlacement: { classPropertyName: "iconPlacement", publicName: "iconPlacement", isSignal: true, isRequired: false, transformFunction: null }, iconTone: { classPropertyName: "iconTone", publicName: "iconTone", isSignal: true, isRequired: false, transformFunction: null }, confirmLabel: { classPropertyName: "confirmLabel", publicName: "confirmLabel", isSignal: true, isRequired: false, transformFunction: null }, cancelLabel: { classPropertyName: "cancelLabel", publicName: "cancelLabel", isSignal: true, isRequired: false, transformFunction: null }, busy: { classPropertyName: "busy", publicName: "busy", isSignal: true, isRequired: false, transformFunction: null }, consequence: { classPropertyName: "consequence", publicName: "consequence", isSignal: true, isRequired: false, transformFunction: null }, reasonLabel: { classPropertyName: "reasonLabel", publicName: "reasonLabel", isSignal: true, isRequired: false, transformFunction: null }, reasonMinLength: { classPropertyName: "reasonMinLength", publicName: "reasonMinLength", isSignal: true, isRequired: false, transformFunction: null }, reasonMaxLength: { classPropertyName: "reasonMaxLength", publicName: "reasonMaxLength", isSignal: true, isRequired: false, transformFunction: null }, reasonOptional: { classPropertyName: "reasonOptional", publicName: "reasonOptional", isSignal: true, isRequired: false, transformFunction: null }, reasonPlaceholder: { classPropertyName: "reasonPlaceholder", publicName: "reasonPlaceholder", isSignal: true, isRequired: false, transformFunction: null }, reasonHint: { classPropertyName: "reasonHint", publicName: "reasonHint", isSignal: true, isRequired: false, transformFunction: null }, reasonError: { classPropertyName: "reasonError", publicName: "reasonError", isSignal: true, isRequired: false, transformFunction: null }, error: { classPropertyName: "error", publicName: "error", isSignal: true, isRequired: false, transformFunction: null }, errorTitle: { classPropertyName: "errorTitle", publicName: "errorTitle", isSignal: true, isRequired: false, transformFunction: null }, acknowledgeLabel: { classPropertyName: "acknowledgeLabel", publicName: "acknowledgeLabel", isSignal: true, isRequired: false, transformFunction: null }, acknowledgeError: { classPropertyName: "acknowledgeError", publicName: "acknowledgeError", isSignal: true, isRequired: false, transformFunction: null }, autoClose: { classPropertyName: "autoClose", publicName: "autoClose", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { open: "openChange", confirmed: "confirmed", cancelled: "cancelled" }, ngImport: i0, template: "<kf-modal\n size=\"sm\"\n [open]=\"open()\"\n [title]=\"title()\"\n [dismissible]=\"!busy()\"\n [icon]=\"titleIcon()\"\n [iconTone]=\"titleIconTone()\"\n [initialFocus]=\"initialFocus()\"\n (openChange)=\"onOpenChange($event)\"\n>\n <div class=\"kf-confirm-dialog__body\" [class.kf-confirm-dialog__body--title-icon]=\"!!titleIcon()\">\n @if (iconPlacement() === 'body' && icon(); as iconName) {\n <span\n class=\"kf-confirm-dialog__icon\"\n [class.kf-confirm-dialog__icon--danger]=\"tone() === 'danger'\"\n >\n <kf-icon [name]=\"iconName\" size=\"lg\" />\n </span>\n }\n @if (message(); as text) {\n <p class=\"kf-confirm-dialog__message\">{{ text }}</p>\n }\n <ng-content />\n @if (consequence(); as text) {\n @if (iconPlacement() === 'title') {\n <p class=\"kf-confirm-dialog__consequence\">{{ text }}</p>\n } @else {\n <kf-alert [tone]=\"tone() === 'danger' ? 'warn' : 'info'\">{{ text }}</kf-alert>\n }\n }\n @if (reasonLabel(); as label) {\n <kf-textarea\n class=\"kf-confirm-dialog__reason\"\n [required]=\"!reasonOptional()\"\n [label]=\"label\"\n [placeholder]=\"reasonPlaceholder()\"\n [hint]=\"reasonHint()\"\n [maxlength]=\"reasonMaxLength()\"\n [showCounter]=\"reasonMaxLength() !== null\"\n [invalid]=\"showReasonError()\"\n [errorMessage]=\"showReasonError() ? reasonErrorText() : undefined\"\n [ngModelOptions]=\"{ standalone: true }\"\n [ngModel]=\"reason()\"\n (ngModelChange)=\"onReason($event)\"\n />\n }\n @if (acknowledgeLabel(); as label) {\n <div class=\"kf-confirm-dialog__acknowledge\">\n <kf-checkbox\n [label]=\"label\"\n [checked]=\"acknowledged()\"\n [invalid]=\"showAcknowledgeError()\"\n (checkedChange)=\"onAcknowledge($event)\"\n />\n @if (showAcknowledgeError()) {\n <span class=\"kf-confirm-dialog__error kf-field-error\" role=\"alert\">{{\n acknowledgeError()\n }}</span>\n }\n </div>\n }\n @if (error(); as text) {\n <kf-alert tone=\"error\" [title]=\"errorTitle()\">{{ text }}</kf-alert>\n }\n </div>\n <div footer class=\"kf-confirm-dialog__actions\">\n <kf-button\n class=\"kf-confirm-dialog__cancel\"\n variant=\"outline\"\n type=\"button\"\n [disabled]=\"busy()\"\n (click)=\"cancel()\"\n >\n {{ cancelLabel() }}\n </kf-button>\n <kf-button\n class=\"kf-confirm-dialog__confirm\"\n type=\"button\"\n [variant]=\"tone() === 'danger' ? 'danger' : 'primary'\"\n [loading]=\"busy()\"\n (click)=\"confirm()\"\n >\n {{ confirmLabel() }}\n </kf-button>\n </div>\n</kf-modal>\n", styles: [".kf-field-hint{font-size:.75rem;color:var(--kf-color-text-muted)}.kf-field-error{display:flex;align-items:center;gap:var(--kf-space-xs);font-size:.75rem;font-weight:600;color:var(--kf-color-error-strong)}:host{display:contents}.kf-confirm-dialog__body{display:flex;flex-direction:column;gap:var(--kf-space-md)}.kf-confirm-dialog__message{margin:0;font-size:var(--kf-font-size-body-sm);color:var(--kf-color-text-muted)}.kf-confirm-dialog__body--title-icon{gap:var(--kf-space-sm)}.kf-confirm-dialog__consequence{margin:0;font-size:var(--kf-font-size-body-sm);color:var(--kf-color-text)}.kf-confirm-dialog__icon{display:flex;align-items:center;justify-content:center;align-self:center;width:48px;height:48px;border-radius:var(--kf-radius-pill);background:var(--kf-color-primary-soft);color:var(--kf-color-primary)}.kf-confirm-dialog__icon--danger{background:var(--kf-color-error-soft);color:var(--kf-color-error-strong)}.kf-confirm-dialog__acknowledge{display:flex;flex-direction:column;gap:var(--kf-space-xs)}.kf-confirm-dialog__actions{display:flex;justify-content:flex-end;gap:var(--kf-space-sm)}@media(max-width:480px){.kf-confirm-dialog__body:not(.kf-confirm-dialog__body--title-icon){text-align:center}.kf-confirm-dialog__actions{flex-direction:column-reverse;align-items:stretch}}\n"], dependencies: [{ kind: "component", type: Alert, selector: "kf-alert", inputs: ["tone", "variant", "appearance", "iconAlign", "title", "dismissible", "actionsInline", "open"], outputs: ["openChange"] }, { kind: "component", type: Button, selector: "kf-button", inputs: ["variant", "size", "shape", "disabled", "type", "icon", "block", "loading", "ariaLabel", "ariaExpanded", "ariaPressed", "ariaDisabled", "ariaDescribedby", "attention", "ariaControls", "ariaHaspopup"], outputs: ["disabledClick"] }, { kind: "component", type: Checkbox, selector: "kf-checkbox", inputs: ["label", "ariaLabel", "checked", "disabled", "indeterminate", "invalid", "row"], outputs: ["checkedChange"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i1.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: Icon, selector: "kf-icon", inputs: ["name", "size", "rotate", "filled"] }, { kind: "component", type: Modal, selector: "kf-modal", inputs: ["title", "open", "dismissible", "width", "size", "dividers", "maxHeight", "fullscreenOnMobile", "panel", "initialFocus", "icon", "iconTone", "closeLabel"], outputs: ["openChange"] }, { kind: "component", type: Textarea, selector: "kf-textarea", inputs: ["label", "required", "hint", "invalid", "errorMessage", "disabled", "readonly", "placeholder", "autocapitalize", "autocorrect", "spellcheck", "enterkeyhint", "minRows", "maxRows", "maxlength", "showCounter"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
9391
9625
|
}
|
|
9392
9626
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: ConfirmDialog, decorators: [{
|
|
9393
9627
|
type: Component,
|
|
9394
|
-
args: [{ selector: 'kf-confirm-dialog', imports: [Alert, Button, Checkbox, FormsModule, Icon, Modal, Textarea], changeDetection: ChangeDetectionStrategy.OnPush, template: "<kf-modal\n size=\"sm\"\n [open]=\"open()\"\n [title]=\"title()\"\n [dismissible]=\"!busy()\"\n [icon]=\"titleIcon()\"\n [iconTone]=\"titleIconTone()\"\n [initialFocus]=\"initialFocus()\"\n (openChange)=\"onOpenChange($event)\"\n>\n <div class=\"kf-confirm-dialog__body\" [class.kf-confirm-dialog__body--title-icon]=\"!!titleIcon()\">\n @if (iconPlacement() === 'body' && icon(); as iconName) {\n <span\n class=\"kf-confirm-dialog__icon\"\n [class.kf-confirm-dialog__icon--danger]=\"tone() === 'danger'\"\n >\n <kf-icon [name]=\"iconName\" size=\"lg\" />\n </span>\n }\n @if (message(); as text) {\n <p class=\"kf-confirm-dialog__message\">{{ text }}</p>\n }\n <ng-content />\n @if (consequence(); as text) {\n @if (iconPlacement() === 'title') {\n <p class=\"kf-confirm-dialog__consequence\">{{ text }}</p>\n } @else {\n <kf-alert [tone]=\"tone() === 'danger' ? 'warn' : 'info'\">{{ text }}</kf-alert>\n }\n }\n @if (reasonLabel(); as label) {\n <kf-textarea\n class=\"kf-confirm-dialog__reason\"\n required\n [label]=\"label\"\n [placeholder]=\"reasonPlaceholder()\"\n [hint]=\"reasonHint()\"\n [invalid]=\"showReasonError()\"\n [errorMessage]=\"showReasonError() ? reasonErrorText() : undefined\"\n [ngModelOptions]=\"{ standalone: true }\"\n [ngModel]=\"reason()\"\n (ngModelChange)=\"onReason($event)\"\n />\n }\n @if (acknowledgeLabel(); as label) {\n <div class=\"kf-confirm-dialog__acknowledge\">\n <kf-checkbox\n [label]=\"label\"\n [checked]=\"acknowledged()\"\n [invalid]=\"showAcknowledgeError()\"\n (checkedChange)=\"onAcknowledge($event)\"\n />\n @if (showAcknowledgeError()) {\n <span class=\"kf-confirm-dialog__error kf-field-error\" role=\"alert\">{{\n acknowledgeError()\n }}</span>\n }\n </div>\n }\n </div>\n <div footer class=\"kf-confirm-dialog__actions\">\n <kf-button\n class=\"kf-confirm-dialog__cancel\"\n variant=\"outline\"\n type=\"button\"\n [disabled]=\"busy()\"\n (click)=\"cancel()\"\n >\n {{ cancelLabel() }}\n </kf-button>\n <kf-button\n class=\"kf-confirm-dialog__confirm\"\n type=\"button\"\n [variant]=\"tone() === 'danger' ? 'danger' : 'primary'\"\n [loading]=\"busy()\"\n (click)=\"confirm()\"\n >\n {{ confirmLabel() }}\n </kf-button>\n </div>\n</kf-modal>\n", styles: [".kf-field-hint{font-size:.75rem;color:var(--kf-color-text-muted)}.kf-field-error{display:flex;align-items:center;gap:var(--kf-space-xs);font-size:.75rem;font-weight:600;color:var(--kf-color-error-strong)}:host{display:contents}.kf-confirm-dialog__body{display:flex;flex-direction:column;gap:var(--kf-space-md)}.kf-confirm-dialog__message{margin:0;font-size:var(--kf-font-size-body-sm);color:var(--kf-color-text-muted)}.kf-confirm-dialog__body--title-icon{gap:var(--kf-space-sm)}.kf-confirm-dialog__consequence{margin:0;font-size:var(--kf-font-size-body-sm);color:var(--kf-color-text)}.kf-confirm-dialog__icon{display:flex;align-items:center;justify-content:center;align-self:center;width:48px;height:48px;border-radius:var(--kf-radius-pill);background:var(--kf-color-primary-soft);color:var(--kf-color-primary)}.kf-confirm-dialog__icon--danger{background:var(--kf-color-error-soft);color:var(--kf-color-error-strong)}.kf-confirm-dialog__acknowledge{display:flex;flex-direction:column;gap:var(--kf-space-xs)}.kf-confirm-dialog__actions{display:flex;justify-content:flex-end;gap:var(--kf-space-sm)}@media(max-width:480px){.kf-confirm-dialog__body:not(.kf-confirm-dialog__body--title-icon){text-align:center}.kf-confirm-dialog__actions{flex-direction:column-reverse;align-items:stretch}}\n"] }]
|
|
9395
|
-
}], ctorParameters: () => [], propDecorators: { open: [{ type: i0.Input, args: [{ isSignal: true, alias: "open", required: false }] }, { type: i0.Output, args: ["openChange"] }], tone: [{ type: i0.Input, args: [{ isSignal: true, alias: "tone", required: false }] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: true }] }], message: [{ type: i0.Input, args: [{ isSignal: true, alias: "message", required: false }] }], icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], iconPlacement: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconPlacement", required: false }] }], iconTone: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconTone", required: false }] }], confirmLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "confirmLabel", required: false }] }], cancelLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "cancelLabel", required: false }] }], busy: [{ type: i0.Input, args: [{ isSignal: true, alias: "busy", required: false }] }], consequence: [{ type: i0.Input, args: [{ isSignal: true, alias: "consequence", required: false }] }], reasonLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "reasonLabel", required: false }] }], reasonMinLength: [{ type: i0.Input, args: [{ isSignal: true, alias: "reasonMinLength", required: false }] }], reasonPlaceholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "reasonPlaceholder", required: false }] }], reasonHint: [{ type: i0.Input, args: [{ isSignal: true, alias: "reasonHint", required: false }] }], reasonError: [{ type: i0.Input, args: [{ isSignal: true, alias: "reasonError", required: false }] }], acknowledgeLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "acknowledgeLabel", required: false }] }], acknowledgeError: [{ type: i0.Input, args: [{ isSignal: true, alias: "acknowledgeError", required: false }] }], autoClose: [{ type: i0.Input, args: [{ isSignal: true, alias: "autoClose", required: false }] }], confirmed: [{ type: i0.Output, args: ["confirmed"] }], cancelled: [{ type: i0.Output, args: ["cancelled"] }] } });
|
|
9628
|
+
args: [{ selector: 'kf-confirm-dialog', imports: [Alert, Button, Checkbox, FormsModule, Icon, Modal, Textarea], changeDetection: ChangeDetectionStrategy.OnPush, template: "<kf-modal\n size=\"sm\"\n [open]=\"open()\"\n [title]=\"title()\"\n [dismissible]=\"!busy()\"\n [icon]=\"titleIcon()\"\n [iconTone]=\"titleIconTone()\"\n [initialFocus]=\"initialFocus()\"\n (openChange)=\"onOpenChange($event)\"\n>\n <div class=\"kf-confirm-dialog__body\" [class.kf-confirm-dialog__body--title-icon]=\"!!titleIcon()\">\n @if (iconPlacement() === 'body' && icon(); as iconName) {\n <span\n class=\"kf-confirm-dialog__icon\"\n [class.kf-confirm-dialog__icon--danger]=\"tone() === 'danger'\"\n >\n <kf-icon [name]=\"iconName\" size=\"lg\" />\n </span>\n }\n @if (message(); as text) {\n <p class=\"kf-confirm-dialog__message\">{{ text }}</p>\n }\n <ng-content />\n @if (consequence(); as text) {\n @if (iconPlacement() === 'title') {\n <p class=\"kf-confirm-dialog__consequence\">{{ text }}</p>\n } @else {\n <kf-alert [tone]=\"tone() === 'danger' ? 'warn' : 'info'\">{{ text }}</kf-alert>\n }\n }\n @if (reasonLabel(); as label) {\n <kf-textarea\n class=\"kf-confirm-dialog__reason\"\n [required]=\"!reasonOptional()\"\n [label]=\"label\"\n [placeholder]=\"reasonPlaceholder()\"\n [hint]=\"reasonHint()\"\n [maxlength]=\"reasonMaxLength()\"\n [showCounter]=\"reasonMaxLength() !== null\"\n [invalid]=\"showReasonError()\"\n [errorMessage]=\"showReasonError() ? reasonErrorText() : undefined\"\n [ngModelOptions]=\"{ standalone: true }\"\n [ngModel]=\"reason()\"\n (ngModelChange)=\"onReason($event)\"\n />\n }\n @if (acknowledgeLabel(); as label) {\n <div class=\"kf-confirm-dialog__acknowledge\">\n <kf-checkbox\n [label]=\"label\"\n [checked]=\"acknowledged()\"\n [invalid]=\"showAcknowledgeError()\"\n (checkedChange)=\"onAcknowledge($event)\"\n />\n @if (showAcknowledgeError()) {\n <span class=\"kf-confirm-dialog__error kf-field-error\" role=\"alert\">{{\n acknowledgeError()\n }}</span>\n }\n </div>\n }\n @if (error(); as text) {\n <kf-alert tone=\"error\" [title]=\"errorTitle()\">{{ text }}</kf-alert>\n }\n </div>\n <div footer class=\"kf-confirm-dialog__actions\">\n <kf-button\n class=\"kf-confirm-dialog__cancel\"\n variant=\"outline\"\n type=\"button\"\n [disabled]=\"busy()\"\n (click)=\"cancel()\"\n >\n {{ cancelLabel() }}\n </kf-button>\n <kf-button\n class=\"kf-confirm-dialog__confirm\"\n type=\"button\"\n [variant]=\"tone() === 'danger' ? 'danger' : 'primary'\"\n [loading]=\"busy()\"\n (click)=\"confirm()\"\n >\n {{ confirmLabel() }}\n </kf-button>\n </div>\n</kf-modal>\n", styles: [".kf-field-hint{font-size:.75rem;color:var(--kf-color-text-muted)}.kf-field-error{display:flex;align-items:center;gap:var(--kf-space-xs);font-size:.75rem;font-weight:600;color:var(--kf-color-error-strong)}:host{display:contents}.kf-confirm-dialog__body{display:flex;flex-direction:column;gap:var(--kf-space-md)}.kf-confirm-dialog__message{margin:0;font-size:var(--kf-font-size-body-sm);color:var(--kf-color-text-muted)}.kf-confirm-dialog__body--title-icon{gap:var(--kf-space-sm)}.kf-confirm-dialog__consequence{margin:0;font-size:var(--kf-font-size-body-sm);color:var(--kf-color-text)}.kf-confirm-dialog__icon{display:flex;align-items:center;justify-content:center;align-self:center;width:48px;height:48px;border-radius:var(--kf-radius-pill);background:var(--kf-color-primary-soft);color:var(--kf-color-primary)}.kf-confirm-dialog__icon--danger{background:var(--kf-color-error-soft);color:var(--kf-color-error-strong)}.kf-confirm-dialog__acknowledge{display:flex;flex-direction:column;gap:var(--kf-space-xs)}.kf-confirm-dialog__actions{display:flex;justify-content:flex-end;gap:var(--kf-space-sm)}@media(max-width:480px){.kf-confirm-dialog__body:not(.kf-confirm-dialog__body--title-icon){text-align:center}.kf-confirm-dialog__actions{flex-direction:column-reverse;align-items:stretch}}\n"] }]
|
|
9629
|
+
}], ctorParameters: () => [], propDecorators: { open: [{ type: i0.Input, args: [{ isSignal: true, alias: "open", required: false }] }, { type: i0.Output, args: ["openChange"] }], tone: [{ type: i0.Input, args: [{ isSignal: true, alias: "tone", required: false }] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: true }] }], message: [{ type: i0.Input, args: [{ isSignal: true, alias: "message", required: false }] }], icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], iconPlacement: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconPlacement", required: false }] }], iconTone: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconTone", required: false }] }], confirmLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "confirmLabel", required: false }] }], cancelLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "cancelLabel", required: false }] }], busy: [{ type: i0.Input, args: [{ isSignal: true, alias: "busy", required: false }] }], consequence: [{ type: i0.Input, args: [{ isSignal: true, alias: "consequence", required: false }] }], reasonLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "reasonLabel", required: false }] }], reasonMinLength: [{ type: i0.Input, args: [{ isSignal: true, alias: "reasonMinLength", required: false }] }], reasonMaxLength: [{ type: i0.Input, args: [{ isSignal: true, alias: "reasonMaxLength", required: false }] }], reasonOptional: [{ type: i0.Input, args: [{ isSignal: true, alias: "reasonOptional", required: false }] }], reasonPlaceholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "reasonPlaceholder", required: false }] }], reasonHint: [{ type: i0.Input, args: [{ isSignal: true, alias: "reasonHint", required: false }] }], reasonError: [{ type: i0.Input, args: [{ isSignal: true, alias: "reasonError", required: false }] }], error: [{ type: i0.Input, args: [{ isSignal: true, alias: "error", required: false }] }], errorTitle: [{ type: i0.Input, args: [{ isSignal: true, alias: "errorTitle", required: false }] }], acknowledgeLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "acknowledgeLabel", required: false }] }], acknowledgeError: [{ type: i0.Input, args: [{ isSignal: true, alias: "acknowledgeError", required: false }] }], autoClose: [{ type: i0.Input, args: [{ isSignal: true, alias: "autoClose", required: false }] }], confirmed: [{ type: i0.Output, args: ["confirmed"] }], cancelled: [{ type: i0.Output, args: ["cancelled"] }] } });
|
|
9396
9630
|
|
|
9397
9631
|
const RAW_BASE64_MIME = {
|
|
9398
9632
|
image: 'image/jpeg',
|
|
@@ -10377,7 +10611,7 @@ class DateField {
|
|
|
10377
10611
|
?.focus();
|
|
10378
10612
|
}
|
|
10379
10613
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: DateField, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
10380
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: DateField, isStandalone: true, selector: "kf-date-field", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: true, transformFunction: null }, hideLabel: { classPropertyName: "hideLabel", publicName: "hideLabel", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, min: { classPropertyName: "min", publicName: "min", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: "max", publicName: "max", isSignal: true, isRequired: false, transformFunction: null }, availableDates: { classPropertyName: "availableDates", publicName: "availableDates", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, invalid: { classPropertyName: "invalid", publicName: "invalid", isSignal: true, isRequired: false, transformFunction: null }, errorMessage: { classPropertyName: "errorMessage", publicName: "errorMessage", isSignal: true, isRequired: false, transformFunction: null }, hint: { classPropertyName: "hint", publicName: "hint", isSignal: true, isRequired: false, transformFunction: null }, locale: { classPropertyName: "locale", publicName: "locale", isSignal: true, isRequired: false, transformFunction: null }, presentation: { classPropertyName: "presentation", publicName: "presentation", isSignal: true, isRequired: false, transformFunction: null }, parseErrorMessage: { classPropertyName: "parseErrorMessage", publicName: "parseErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, rangeErrorMessage: { classPropertyName: "rangeErrorMessage", publicName: "rangeErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, openCalendarLabel: { classPropertyName: "openCalendarLabel", publicName: "openCalendarLabel", isSignal: true, isRequired: false, transformFunction: null }, describedBy: { classPropertyName: "describedBy", publicName: "describedBy", isSignal: true, isRequired: false, transformFunction: null }, hidePicker: { classPropertyName: "hidePicker", publicName: "hidePicker", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange" }, viewQueries: [{ propertyName: "field", first: true, predicate: Input, descendants: true, isSignal: true }, { propertyName: "fieldHost", first: true, predicate: Input, descendants: true, read: ElementRef, isSignal: true }, { propertyName: "panel", first: true, predicate: DropdownPanel, descendants: true, isSignal: true }, { propertyName: "sheetTemplate", first: true, predicate: ["sheetTemplate"], descendants: true, isSignal: true }], ngImport: i0, template: "<ng-template #calendarTemplate>\n <kf-calendar\n [value]=\"value()\"\n [min]=\"min()\"\n [max]=\"max()\"\n [availableDates]=\"availableDates()\"\n [monthNames]=\"monthNames()\"\n [weekdayLabels]=\"weekdayLabels()\"\n [weekdayNames]=\"weekdayNames()\"\n [ariaLabel]=\"label()\"\n (valueChange)=\"pick($event)\"\n />\n</ng-template>\n\n<kf-dropdown [(open)]=\"popoverOpen\" [anchor]=\"fieldHost()\" [autoFocus]=\"false\">\n <kf-input\n [label]=\"label()\"\n [hideLabel]=\"hideLabel()\"\n [required]=\"required()\"\n [disabled]=\"disabled()\"\n [invalid]=\"fieldInvalid()\"\n [errorMessage]=\"fieldError()\"\n [hint]=\"hint()\"\n [describedBy]=\"describedBy()\"\n [placeholder]=\"placeholder()\"\n [maxlength]=\"maxLength()\"\n inputmode=\"numeric\"\n autocomplete=\"off\"\n [ngModelOptions]=\"{ standalone: true }\"\n [ngModel]=\"text()\"\n (ngModelChange)=\"onText($event)\"\n (keydown)=\"onKeydown($event)\"\n >\n @if (!hidePicker()) {\n <kf-button\n kf-input-trailing\n class=\"kf-date-field__toggle\"\n variant=\"ghost\"\n shape=\"circle\"\n size=\"sm\"\n icon=\"calendar\"\n type=\"button\"\n [ariaLabel]=\"openCalendarLabel()\"\n [ariaHaspopup]=\"'dialog'\"\n [ariaExpanded]=\"expanded()\"\n [disabled]=\"disabled()\"\n (click)=\"toggle()\"\n />\n }\n </kf-input>\n <kf-dropdown-panel role=\"dialog\" [ariaLabel]=\"label()\">\n <ng-container [ngTemplateOutlet]=\"calendarTemplate\" />\n </kf-dropdown-panel>\n</kf-dropdown>\n\n<ng-template #sheetTemplate>\n <kf-drawer side=\"bottom\" role=\"dialog\" [title]=\"label()\" [(open)]=\"sheetOpen\">\n <div class=\"kf-date-field__sheet\">\n <ng-container [ngTemplateOutlet]=\"calendarTemplate\" />\n </div>\n </kf-drawer>\n</ng-template>\n", styles: [":host{display:block}kf-dropdown{display:block}.kf-date-field__sheet{display:flex;justify-content:center;padding:var(--kf-space-sm) 0 var(--kf-space-md)}\n"], dependencies: [{ kind: "component", type: Button, selector: "kf-button", inputs: ["variant", "size", "shape", "disabled", "type", "icon", "block", "loading", "ariaLabel", "ariaExpanded", "ariaPressed", "ariaDisabled", "ariaDescribedby", "attention", "ariaControls", "ariaHaspopup"], outputs: ["disabledClick"] }, { kind: "component", type: Calendar, selector: "kf-calendar", inputs: ["value", "month", "min", "max", "availableDates", "markedDates", "today", "loading", "ariaLabel", "monthNames", "weekdayLabels", "weekdayNames", "markedLabel", "previousMonthLabel", "nextMonthLabel"], outputs: ["valueChange", "monthChange"] }, { kind: "component", type: Drawer, selector: "kf-drawer", inputs: ["open", "side", "role", "ariaLabel", "title", "closeLabel", "size", "sheetSize", "expandable", "sheetWidth", "flush", "swipeToClose", "closeOnBack", "mountInOverlay"], outputs: ["openChange", "closedAfterBack", "detentChange"] }, { kind: "component", type: Dropdown, selector: "kf-dropdown", inputs: ["open", "anchor", "autoFocus"], outputs: ["openChange"] }, { kind: "component", type: DropdownPanel, selector: "kf-dropdown-panel", inputs: ["variant", "role", "maxHeight", "width", "ariaLabel"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i1.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: Input, selector: "kf-input", inputs: ["label", "size", "hideLabel", "required", "icon", "suffix", "hint", "invalid", "errorMessage", "disabled", "readonly", "type", "placeholder", "autocomplete", "name", "inputmode", "autocapitalize", "autocorrect", "spellcheck", "enterkeyhint", "min", "max", "step", "maxlength", "describedBy", "toggleable", "ariaLabel", "clearable", "clearLabel"], outputs: ["cleared"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
10614
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: DateField, isStandalone: true, selector: "kf-date-field", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: true, transformFunction: null }, hideLabel: { classPropertyName: "hideLabel", publicName: "hideLabel", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, min: { classPropertyName: "min", publicName: "min", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: "max", publicName: "max", isSignal: true, isRequired: false, transformFunction: null }, availableDates: { classPropertyName: "availableDates", publicName: "availableDates", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, invalid: { classPropertyName: "invalid", publicName: "invalid", isSignal: true, isRequired: false, transformFunction: null }, errorMessage: { classPropertyName: "errorMessage", publicName: "errorMessage", isSignal: true, isRequired: false, transformFunction: null }, hint: { classPropertyName: "hint", publicName: "hint", isSignal: true, isRequired: false, transformFunction: null }, locale: { classPropertyName: "locale", publicName: "locale", isSignal: true, isRequired: false, transformFunction: null }, presentation: { classPropertyName: "presentation", publicName: "presentation", isSignal: true, isRequired: false, transformFunction: null }, parseErrorMessage: { classPropertyName: "parseErrorMessage", publicName: "parseErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, rangeErrorMessage: { classPropertyName: "rangeErrorMessage", publicName: "rangeErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, openCalendarLabel: { classPropertyName: "openCalendarLabel", publicName: "openCalendarLabel", isSignal: true, isRequired: false, transformFunction: null }, describedBy: { classPropertyName: "describedBy", publicName: "describedBy", isSignal: true, isRequired: false, transformFunction: null }, hidePicker: { classPropertyName: "hidePicker", publicName: "hidePicker", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange" }, viewQueries: [{ propertyName: "field", first: true, predicate: Input, descendants: true, isSignal: true }, { propertyName: "fieldHost", first: true, predicate: Input, descendants: true, read: ElementRef, isSignal: true }, { propertyName: "panel", first: true, predicate: DropdownPanel, descendants: true, isSignal: true }, { propertyName: "sheetTemplate", first: true, predicate: ["sheetTemplate"], descendants: true, isSignal: true }], ngImport: i0, template: "<ng-template #calendarTemplate>\n <kf-calendar\n [value]=\"value()\"\n [min]=\"min()\"\n [max]=\"max()\"\n [availableDates]=\"availableDates()\"\n [monthNames]=\"monthNames()\"\n [weekdayLabels]=\"weekdayLabels()\"\n [weekdayNames]=\"weekdayNames()\"\n [ariaLabel]=\"label()\"\n (valueChange)=\"pick($event)\"\n />\n</ng-template>\n\n<kf-dropdown [(open)]=\"popoverOpen\" [anchor]=\"fieldHost()\" [autoFocus]=\"false\">\n <kf-input\n [label]=\"label()\"\n [hideLabel]=\"hideLabel()\"\n [required]=\"required()\"\n [disabled]=\"disabled()\"\n [invalid]=\"fieldInvalid()\"\n [errorMessage]=\"fieldError()\"\n [hint]=\"hint()\"\n [describedBy]=\"describedBy()\"\n [placeholder]=\"placeholder()\"\n [maxlength]=\"maxLength()\"\n inputmode=\"numeric\"\n autocomplete=\"off\"\n [ngModelOptions]=\"{ standalone: true }\"\n [ngModel]=\"text()\"\n (ngModelChange)=\"onText($event)\"\n (keydown)=\"onKeydown($event)\"\n >\n @if (!hidePicker()) {\n <kf-button\n kf-input-trailing\n class=\"kf-date-field__toggle\"\n variant=\"ghost\"\n shape=\"circle\"\n size=\"sm\"\n icon=\"calendar\"\n type=\"button\"\n [ariaLabel]=\"openCalendarLabel()\"\n [ariaHaspopup]=\"'dialog'\"\n [ariaExpanded]=\"expanded()\"\n [disabled]=\"disabled()\"\n (click)=\"toggle()\"\n />\n }\n </kf-input>\n <kf-dropdown-panel role=\"dialog\" [ariaLabel]=\"label()\">\n <ng-container [ngTemplateOutlet]=\"calendarTemplate\" />\n </kf-dropdown-panel>\n</kf-dropdown>\n\n<ng-template #sheetTemplate>\n <kf-drawer side=\"bottom\" role=\"dialog\" [title]=\"label()\" [(open)]=\"sheetOpen\">\n <div class=\"kf-date-field__sheet\">\n <ng-container [ngTemplateOutlet]=\"calendarTemplate\" />\n </div>\n </kf-drawer>\n</ng-template>\n", styles: [":host{display:block}kf-dropdown{display:block}.kf-date-field__sheet{display:flex;justify-content:center;padding:var(--kf-space-sm) 0 var(--kf-space-md)}\n"], dependencies: [{ kind: "component", type: Button, selector: "kf-button", inputs: ["variant", "size", "shape", "disabled", "type", "icon", "block", "loading", "ariaLabel", "ariaExpanded", "ariaPressed", "ariaDisabled", "ariaDescribedby", "attention", "ariaControls", "ariaHaspopup"], outputs: ["disabledClick"] }, { kind: "component", type: Calendar, selector: "kf-calendar", inputs: ["value", "month", "min", "max", "availableDates", "markedDates", "today", "loading", "ariaLabel", "monthNames", "weekdayLabels", "weekdayNames", "markedLabel", "previousMonthLabel", "nextMonthLabel"], outputs: ["valueChange", "monthChange"] }, { kind: "component", type: Drawer, selector: "kf-drawer", inputs: ["open", "side", "role", "ariaLabel", "title", "closeLabel", "size", "sheetSize", "expandable", "sheetWidth", "flush", "swipeToClose", "closeOnBack", "mountInOverlay", "closeGuard"], outputs: ["openChange", "closedAfterBack", "detentChange"] }, { kind: "component", type: Dropdown, selector: "kf-dropdown", inputs: ["open", "anchor", "autoFocus"], outputs: ["openChange"] }, { kind: "component", type: DropdownPanel, selector: "kf-dropdown-panel", inputs: ["variant", "role", "maxHeight", "width", "ariaLabel"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i1.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: Input, selector: "kf-input", inputs: ["label", "size", "hideLabel", "required", "icon", "suffix", "hint", "invalid", "errorMessage", "disabled", "readonly", "type", "placeholder", "autocomplete", "name", "inputmode", "autocapitalize", "autocorrect", "spellcheck", "enterkeyhint", "min", "max", "step", "maxlength", "describedBy", "toggleable", "ariaLabel", "clearable", "clearLabel"], outputs: ["cleared"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
10381
10615
|
}
|
|
10382
10616
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: DateField, decorators: [{
|
|
10383
10617
|
type: Component,
|
|
@@ -11269,7 +11503,7 @@ class DateRangeField {
|
|
|
11269
11503
|
?.focus();
|
|
11270
11504
|
}
|
|
11271
11505
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: DateRangeField, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
11272
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: DateRangeField, isStandalone: true, selector: "kf-date-range-field", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: true, transformFunction: null }, hideLabel: { classPropertyName: "hideLabel", publicName: "hideLabel", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, min: { classPropertyName: "min", publicName: "min", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: "max", publicName: "max", isSignal: true, isRequired: false, transformFunction: null }, maxDays: { classPropertyName: "maxDays", publicName: "maxDays", isSignal: true, isRequired: false, transformFunction: null }, presets: { classPropertyName: "presets", publicName: "presets", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, invalid: { classPropertyName: "invalid", publicName: "invalid", isSignal: true, isRequired: false, transformFunction: null }, errorMessage: { classPropertyName: "errorMessage", publicName: "errorMessage", isSignal: true, isRequired: false, transformFunction: null }, hint: { classPropertyName: "hint", publicName: "hint", isSignal: true, isRequired: false, transformFunction: null }, locale: { classPropertyName: "locale", publicName: "locale", isSignal: true, isRequired: false, transformFunction: null }, presentation: { classPropertyName: "presentation", publicName: "presentation", isSignal: true, isRequired: false, transformFunction: null }, today: { classPropertyName: "today", publicName: "today", isSignal: true, isRequired: false, transformFunction: null }, describedBy: { classPropertyName: "describedBy", publicName: "describedBy", isSignal: true, isRequired: false, transformFunction: null }, parseErrorMessage: { classPropertyName: "parseErrorMessage", publicName: "parseErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, rangeErrorMessage: { classPropertyName: "rangeErrorMessage", publicName: "rangeErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, orderErrorMessage: { classPropertyName: "orderErrorMessage", publicName: "orderErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, maxDaysErrorMessage: { classPropertyName: "maxDaysErrorMessage", publicName: "maxDaysErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, openCalendarLabel: { classPropertyName: "openCalendarLabel", publicName: "openCalendarLabel", isSignal: true, isRequired: false, transformFunction: null }, presetsLabel: { classPropertyName: "presetsLabel", publicName: "presetsLabel", isSignal: true, isRequired: false, transformFunction: null }, cancelLabel: { classPropertyName: "cancelLabel", publicName: "cancelLabel", isSignal: true, isRequired: false, transformFunction: null }, doneLabel: { classPropertyName: "doneLabel", publicName: "doneLabel", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange" }, viewQueries: [{ propertyName: "field", first: true, predicate: Input, descendants: true, isSignal: true }, { propertyName: "fieldHost", first: true, predicate: Input, descendants: true, read: ElementRef, isSignal: true }, { propertyName: "panel", first: true, predicate: DropdownPanel, descendants: true, isSignal: true }, { propertyName: "sheetTemplate", first: true, predicate: ["sheetTemplate"], descendants: true, isSignal: true }], ngImport: i0, template: "<ng-template #panelContent>\n <div class=\"kf-drf__panel\" [class.kf-drf__panel--stacked]=\"stacked()\">\n <div\n class=\"kf-drf__presets\"\n role=\"listbox\"\n [id]=\"presetsId\"\n [attr.aria-label]=\"presetsLabel()\"\n [attr.aria-orientation]=\"stacked() ? 'horizontal' : 'vertical'\"\n (keydown)=\"onPresetKeydown($event)\"\n >\n @for (preset of resolvedPresets(); track preset.id) {\n <button\n type=\"button\"\n role=\"option\"\n class=\"kf-drf__preset\"\n [class.kf-drf__preset--active]=\"preset.id === activePresetId()\"\n [attr.data-preset]=\"preset.id\"\n [attr.aria-selected]=\"preset.id === activePresetId()\"\n [attr.aria-disabled]=\"preset.disabled\"\n [attr.tabindex]=\"preset.id === presetTabStop() ? 0 : -1\"\n (click)=\"choosePreset(preset)\"\n >\n <kf-icon class=\"kf-drf__preset-check\" name=\"check\" size=\"sm\" aria-hidden=\"true\" />\n <span class=\"kf-drf__preset-label\">{{ preset.label }}</span>\n </button>\n }\n </div>\n\n <div class=\"kf-drf__calendar\">\n <kf-date-range-calendar\n [start]=\"draftStart()\"\n [end]=\"draftEnd()\"\n [(month)]=\"month\"\n [months]=\"months()\"\n [min]=\"min()\"\n [max]=\"max()\"\n [maxDays]=\"maxDays()\"\n [today]=\"todayIso()\"\n [monthNames]=\"monthNames()\"\n [weekdayLabels]=\"weekdayLabels()\"\n [weekdayNames]=\"weekdayNames()\"\n [ariaLabel]=\"label()\"\n (dayPick)=\"onDayPick($event)\"\n (blockedPick)=\"onBlockedPick()\"\n />\n @if (panelError(); as message) {\n <p class=\"kf-drf__summary kf-field-error\" role=\"alert\">{{ message }}</p>\n } @else {\n <p class=\"kf-drf__summary kf-field-hint\" [id]=\"summaryId\">{{ summary() }}</p>\n }\n </div>\n </div>\n</ng-template>\n\n<kf-dropdown [(open)]=\"popoverOpen\" [anchor]=\"fieldHost()\" [autoFocus]=\"false\">\n <kf-input\n [label]=\"label()\"\n [hideLabel]=\"hideLabel()\"\n [required]=\"required()\"\n [disabled]=\"disabled()\"\n [invalid]=\"fieldInvalid()\"\n [errorMessage]=\"fieldError()\"\n [hint]=\"hint()\"\n [describedBy]=\"describedBy()\"\n [placeholder]=\"placeholder()\"\n [maxlength]=\"maxLength()\"\n inputmode=\"numeric\"\n autocomplete=\"off\"\n [ngModelOptions]=\"{ standalone: true }\"\n [ngModel]=\"text()\"\n (ngModelChange)=\"onText($event)\"\n (keydown)=\"onKeydown($event)\"\n >\n <kf-button\n kf-input-trailing\n class=\"kf-date-range-field__toggle\"\n variant=\"ghost\"\n shape=\"circle\"\n size=\"sm\"\n icon=\"calendar\"\n type=\"button\"\n [ariaLabel]=\"openCalendarLabel()\"\n [ariaHaspopup]=\"'dialog'\"\n [ariaExpanded]=\"expanded()\"\n [disabled]=\"disabled()\"\n (click)=\"toggle()\"\n />\n </kf-input>\n <kf-dropdown-panel role=\"dialog\" [ariaLabel]=\"label()\" [width]=\"panelWidth()\" maxHeight=\"40rem\">\n <ng-container [ngTemplateOutlet]=\"panelContent\" />\n </kf-dropdown-panel>\n</kf-dropdown>\n\n<ng-template #sheetTemplate>\n <kf-drawer\n side=\"bottom\"\n role=\"dialog\"\n sheetWidth=\"readable\"\n sheetSize=\"large\"\n [title]=\"label()\"\n [closeLabel]=\"cancelLabel()\"\n [(open)]=\"sheetOpen\"\n >\n <div class=\"kf-drf__sheet\">\n <ng-container [ngTemplateOutlet]=\"panelContent\" />\n </div>\n <div kf-drawer-footer class=\"kf-drf__footer\">\n <kf-button class=\"kf-drf__cancel\" variant=\"outline\" (click)=\"cancelSheet()\">{{\n cancelLabel()\n }}</kf-button>\n <kf-button class=\"kf-drf__done\" [disabled]=\"!draftComplete()\" (click)=\"confirmSheet()\">{{\n doneLabel()\n }}</kf-button>\n </div>\n </kf-drawer>\n</ng-template>\n", styles: [".kf-field-hint{font-size:.75rem;color:var(--kf-color-text-muted)}.kf-field-error{display:flex;align-items:center;gap:var(--kf-space-xs);font-size:.75rem;font-weight:600;color:var(--kf-color-error-strong)}:host{display:block}kf-dropdown{display:block}.kf-drf__panel{display:grid;grid-template-columns:10rem minmax(0,1fr);gap:var(--kf-space-md);align-items:start;padding:var(--kf-space-md);min-width:0;font-family:var(--kf-font-body)}.kf-drf__panel--stacked{grid-template-columns:minmax(0,1fr)}.kf-drf__presets{display:flex;flex-direction:column;gap:2px;min-width:0}.kf-drf__panel--stacked .kf-drf__presets{flex-direction:row;gap:var(--kf-space-xs);overflow-x:auto;overscroll-behavior-x:contain;scrollbar-width:none;margin-inline:calc(-1 * var(--kf-drf-bleed, var(--kf-space-md)));padding:2px var(--kf-drf-bleed, var(--kf-space-md));scroll-padding-inline:var(--kf-drf-bleed, var(--kf-space-md))}.kf-drf__panel--stacked .kf-drf__presets::-webkit-scrollbar{display:none}.kf-drf__preset{display:flex;flex:none;align-items:center;gap:var(--kf-space-xs);min-height:var(--kf-hit-target-min);padding:0 var(--kf-space-sm);border:1px solid transparent;border-radius:var(--kf-radius-sm);background:transparent;font:inherit;font-size:var(--kf-font-size-body-sm);font-weight:var(--kf-font-weight-medium);color:var(--kf-color-ink);text-align:start;white-space:nowrap;cursor:pointer;-webkit-tap-highlight-color:transparent;transition:background-color var(--kf-motion-fast, .15s) var(--kf-ease-standard, ease),border-color var(--kf-motion-fast, .15s) var(--kf-ease-standard, ease)}.kf-drf__panel--stacked .kf-drf__preset{padding:0 var(--kf-space-md);border-color:var(--kf-color-border-control);border-radius:var(--kf-radius-pill)}@media(hover:hover){.kf-drf__preset:hover:not([aria-disabled=true]){background:var(--kf-color-primary-soft)}}.kf-drf__preset--active{background:var(--kf-color-primary-soft);border-color:var(--kf-color-primary)}.kf-drf__preset[aria-disabled=true]{color:var(--kf-color-text-muted);font-weight:var(--kf-font-weight-body);cursor:not-allowed}.kf-drf__preset:focus-visible{outline:2px solid var(--kf-color-primary);outline-offset:1px}.kf-drf__preset-check{flex:none;width:0;opacity:0;transition:width var(--kf-motion-fast, .15s) var(--kf-ease-standard, ease),opacity var(--kf-motion-fast, .15s) var(--kf-ease-standard, ease)}.kf-drf__preset--active .kf-drf__preset-check{width:1rem;opacity:1}.kf-drf__calendar{display:flex;flex-direction:column;gap:var(--kf-space-sm);min-width:0}.kf-drf__summary{margin:0;min-height:1.25rem;text-align:center}.kf-drf__summary.kf-field-error{justify-content:center}.kf-drf__sheet{--kf-drf-bleed: var(--kf-space-lg);font-family:var(--kf-font-body)}.kf-drf__sheet .kf-drf__panel{padding:0}.kf-drf__footer{display:flex;gap:var(--kf-space-sm);font-family:var(--kf-font-body)}.kf-drf__footer kf-button{flex:1 1 0;--kf-button-min-height: var(--kf-hit-target-min)}@media(prefers-reduced-motion:reduce){.kf-drf__preset,.kf-drf__preset-check{transition:none}}\n"], dependencies: [{ kind: "component", type: Button, selector: "kf-button", inputs: ["variant", "size", "shape", "disabled", "type", "icon", "block", "loading", "ariaLabel", "ariaExpanded", "ariaPressed", "ariaDisabled", "ariaDescribedby", "attention", "ariaControls", "ariaHaspopup"], outputs: ["disabledClick"] }, { kind: "component", type: DateRangeCalendar, selector: "kf-date-range-calendar", inputs: ["start", "end", "month", "months", "min", "max", "maxDays", "today", "ariaLabel", "monthNames", "weekdayLabels", "weekdayNames", "previousMonthLabel", "nextMonthLabel", "startDayLabel", "endDayLabel", "inRangeLabel", "startAnnouncement", "endAnnouncement", "pickEndHint"], outputs: ["monthChange", "dayPick", "blockedPick"] }, { kind: "component", type: Drawer, selector: "kf-drawer", inputs: ["open", "side", "role", "ariaLabel", "title", "closeLabel", "size", "sheetSize", "expandable", "sheetWidth", "flush", "swipeToClose", "closeOnBack", "mountInOverlay"], outputs: ["openChange", "closedAfterBack", "detentChange"] }, { kind: "component", type: Dropdown, selector: "kf-dropdown", inputs: ["open", "anchor", "autoFocus"], outputs: ["openChange"] }, { kind: "component", type: DropdownPanel, selector: "kf-dropdown-panel", inputs: ["variant", "role", "maxHeight", "width", "ariaLabel"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i1.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: Icon, selector: "kf-icon", inputs: ["name", "size", "rotate", "filled"] }, { kind: "component", type: Input, selector: "kf-input", inputs: ["label", "size", "hideLabel", "required", "icon", "suffix", "hint", "invalid", "errorMessage", "disabled", "readonly", "type", "placeholder", "autocomplete", "name", "inputmode", "autocapitalize", "autocorrect", "spellcheck", "enterkeyhint", "min", "max", "step", "maxlength", "describedBy", "toggleable", "ariaLabel", "clearable", "clearLabel"], outputs: ["cleared"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
11506
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: DateRangeField, isStandalone: true, selector: "kf-date-range-field", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: true, transformFunction: null }, hideLabel: { classPropertyName: "hideLabel", publicName: "hideLabel", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, min: { classPropertyName: "min", publicName: "min", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: "max", publicName: "max", isSignal: true, isRequired: false, transformFunction: null }, maxDays: { classPropertyName: "maxDays", publicName: "maxDays", isSignal: true, isRequired: false, transformFunction: null }, presets: { classPropertyName: "presets", publicName: "presets", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, invalid: { classPropertyName: "invalid", publicName: "invalid", isSignal: true, isRequired: false, transformFunction: null }, errorMessage: { classPropertyName: "errorMessage", publicName: "errorMessage", isSignal: true, isRequired: false, transformFunction: null }, hint: { classPropertyName: "hint", publicName: "hint", isSignal: true, isRequired: false, transformFunction: null }, locale: { classPropertyName: "locale", publicName: "locale", isSignal: true, isRequired: false, transformFunction: null }, presentation: { classPropertyName: "presentation", publicName: "presentation", isSignal: true, isRequired: false, transformFunction: null }, today: { classPropertyName: "today", publicName: "today", isSignal: true, isRequired: false, transformFunction: null }, describedBy: { classPropertyName: "describedBy", publicName: "describedBy", isSignal: true, isRequired: false, transformFunction: null }, parseErrorMessage: { classPropertyName: "parseErrorMessage", publicName: "parseErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, rangeErrorMessage: { classPropertyName: "rangeErrorMessage", publicName: "rangeErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, orderErrorMessage: { classPropertyName: "orderErrorMessage", publicName: "orderErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, maxDaysErrorMessage: { classPropertyName: "maxDaysErrorMessage", publicName: "maxDaysErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, openCalendarLabel: { classPropertyName: "openCalendarLabel", publicName: "openCalendarLabel", isSignal: true, isRequired: false, transformFunction: null }, presetsLabel: { classPropertyName: "presetsLabel", publicName: "presetsLabel", isSignal: true, isRequired: false, transformFunction: null }, cancelLabel: { classPropertyName: "cancelLabel", publicName: "cancelLabel", isSignal: true, isRequired: false, transformFunction: null }, doneLabel: { classPropertyName: "doneLabel", publicName: "doneLabel", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange" }, viewQueries: [{ propertyName: "field", first: true, predicate: Input, descendants: true, isSignal: true }, { propertyName: "fieldHost", first: true, predicate: Input, descendants: true, read: ElementRef, isSignal: true }, { propertyName: "panel", first: true, predicate: DropdownPanel, descendants: true, isSignal: true }, { propertyName: "sheetTemplate", first: true, predicate: ["sheetTemplate"], descendants: true, isSignal: true }], ngImport: i0, template: "<ng-template #panelContent>\n <div class=\"kf-drf__panel\" [class.kf-drf__panel--stacked]=\"stacked()\">\n <div\n class=\"kf-drf__presets\"\n role=\"listbox\"\n [id]=\"presetsId\"\n [attr.aria-label]=\"presetsLabel()\"\n [attr.aria-orientation]=\"stacked() ? 'horizontal' : 'vertical'\"\n (keydown)=\"onPresetKeydown($event)\"\n >\n @for (preset of resolvedPresets(); track preset.id) {\n <button\n type=\"button\"\n role=\"option\"\n class=\"kf-drf__preset\"\n [class.kf-drf__preset--active]=\"preset.id === activePresetId()\"\n [attr.data-preset]=\"preset.id\"\n [attr.aria-selected]=\"preset.id === activePresetId()\"\n [attr.aria-disabled]=\"preset.disabled\"\n [attr.tabindex]=\"preset.id === presetTabStop() ? 0 : -1\"\n (click)=\"choosePreset(preset)\"\n >\n <kf-icon class=\"kf-drf__preset-check\" name=\"check\" size=\"sm\" aria-hidden=\"true\" />\n <span class=\"kf-drf__preset-label\">{{ preset.label }}</span>\n </button>\n }\n </div>\n\n <div class=\"kf-drf__calendar\">\n <kf-date-range-calendar\n [start]=\"draftStart()\"\n [end]=\"draftEnd()\"\n [(month)]=\"month\"\n [months]=\"months()\"\n [min]=\"min()\"\n [max]=\"max()\"\n [maxDays]=\"maxDays()\"\n [today]=\"todayIso()\"\n [monthNames]=\"monthNames()\"\n [weekdayLabels]=\"weekdayLabels()\"\n [weekdayNames]=\"weekdayNames()\"\n [ariaLabel]=\"label()\"\n (dayPick)=\"onDayPick($event)\"\n (blockedPick)=\"onBlockedPick()\"\n />\n @if (panelError(); as message) {\n <p class=\"kf-drf__summary kf-field-error\" role=\"alert\">{{ message }}</p>\n } @else {\n <p class=\"kf-drf__summary kf-field-hint\" [id]=\"summaryId\">{{ summary() }}</p>\n }\n </div>\n </div>\n</ng-template>\n\n<kf-dropdown [(open)]=\"popoverOpen\" [anchor]=\"fieldHost()\" [autoFocus]=\"false\">\n <kf-input\n [label]=\"label()\"\n [hideLabel]=\"hideLabel()\"\n [required]=\"required()\"\n [disabled]=\"disabled()\"\n [invalid]=\"fieldInvalid()\"\n [errorMessage]=\"fieldError()\"\n [hint]=\"hint()\"\n [describedBy]=\"describedBy()\"\n [placeholder]=\"placeholder()\"\n [maxlength]=\"maxLength()\"\n inputmode=\"numeric\"\n autocomplete=\"off\"\n [ngModelOptions]=\"{ standalone: true }\"\n [ngModel]=\"text()\"\n (ngModelChange)=\"onText($event)\"\n (keydown)=\"onKeydown($event)\"\n >\n <kf-button\n kf-input-trailing\n class=\"kf-date-range-field__toggle\"\n variant=\"ghost\"\n shape=\"circle\"\n size=\"sm\"\n icon=\"calendar\"\n type=\"button\"\n [ariaLabel]=\"openCalendarLabel()\"\n [ariaHaspopup]=\"'dialog'\"\n [ariaExpanded]=\"expanded()\"\n [disabled]=\"disabled()\"\n (click)=\"toggle()\"\n />\n </kf-input>\n <kf-dropdown-panel role=\"dialog\" [ariaLabel]=\"label()\" [width]=\"panelWidth()\" maxHeight=\"40rem\">\n <ng-container [ngTemplateOutlet]=\"panelContent\" />\n </kf-dropdown-panel>\n</kf-dropdown>\n\n<ng-template #sheetTemplate>\n <kf-drawer\n side=\"bottom\"\n role=\"dialog\"\n sheetWidth=\"readable\"\n sheetSize=\"large\"\n [title]=\"label()\"\n [closeLabel]=\"cancelLabel()\"\n [(open)]=\"sheetOpen\"\n >\n <div class=\"kf-drf__sheet\">\n <ng-container [ngTemplateOutlet]=\"panelContent\" />\n </div>\n <div kf-drawer-footer class=\"kf-drf__footer\">\n <kf-button class=\"kf-drf__cancel\" variant=\"outline\" (click)=\"cancelSheet()\">{{\n cancelLabel()\n }}</kf-button>\n <kf-button class=\"kf-drf__done\" [disabled]=\"!draftComplete()\" (click)=\"confirmSheet()\">{{\n doneLabel()\n }}</kf-button>\n </div>\n </kf-drawer>\n</ng-template>\n", styles: [".kf-field-hint{font-size:.75rem;color:var(--kf-color-text-muted)}.kf-field-error{display:flex;align-items:center;gap:var(--kf-space-xs);font-size:.75rem;font-weight:600;color:var(--kf-color-error-strong)}:host{display:block}kf-dropdown{display:block}.kf-drf__panel{display:grid;grid-template-columns:10rem minmax(0,1fr);gap:var(--kf-space-md);align-items:start;padding:var(--kf-space-md);min-width:0;font-family:var(--kf-font-body)}.kf-drf__panel--stacked{grid-template-columns:minmax(0,1fr)}.kf-drf__presets{display:flex;flex-direction:column;gap:2px;min-width:0}.kf-drf__panel--stacked .kf-drf__presets{flex-direction:row;gap:var(--kf-space-xs);overflow-x:auto;overscroll-behavior-x:contain;scrollbar-width:none;margin-inline:calc(-1 * var(--kf-drf-bleed, var(--kf-space-md)));padding:2px var(--kf-drf-bleed, var(--kf-space-md));scroll-padding-inline:var(--kf-drf-bleed, var(--kf-space-md))}.kf-drf__panel--stacked .kf-drf__presets::-webkit-scrollbar{display:none}.kf-drf__preset{display:flex;flex:none;align-items:center;gap:var(--kf-space-xs);min-height:var(--kf-hit-target-min);padding:0 var(--kf-space-sm);border:1px solid transparent;border-radius:var(--kf-radius-sm);background:transparent;font:inherit;font-size:var(--kf-font-size-body-sm);font-weight:var(--kf-font-weight-medium);color:var(--kf-color-ink);text-align:start;white-space:nowrap;cursor:pointer;-webkit-tap-highlight-color:transparent;transition:background-color var(--kf-motion-fast, .15s) var(--kf-ease-standard, ease),border-color var(--kf-motion-fast, .15s) var(--kf-ease-standard, ease)}.kf-drf__panel--stacked .kf-drf__preset{padding:0 var(--kf-space-md);border-color:var(--kf-color-border-control);border-radius:var(--kf-radius-pill)}@media(hover:hover){.kf-drf__preset:hover:not([aria-disabled=true]){background:var(--kf-color-primary-soft)}}.kf-drf__preset--active{background:var(--kf-color-primary-soft);border-color:var(--kf-color-primary)}.kf-drf__preset[aria-disabled=true]{color:var(--kf-color-text-muted);font-weight:var(--kf-font-weight-body);cursor:not-allowed}.kf-drf__preset:focus-visible{outline:2px solid var(--kf-color-primary);outline-offset:1px}.kf-drf__preset-check{flex:none;width:0;opacity:0;transition:width var(--kf-motion-fast, .15s) var(--kf-ease-standard, ease),opacity var(--kf-motion-fast, .15s) var(--kf-ease-standard, ease)}.kf-drf__preset--active .kf-drf__preset-check{width:1rem;opacity:1}.kf-drf__calendar{display:flex;flex-direction:column;gap:var(--kf-space-sm);min-width:0}.kf-drf__summary{margin:0;min-height:1.25rem;text-align:center}.kf-drf__summary.kf-field-error{justify-content:center}.kf-drf__sheet{--kf-drf-bleed: var(--kf-space-lg);font-family:var(--kf-font-body)}.kf-drf__sheet .kf-drf__panel{padding:0}.kf-drf__footer{display:flex;gap:var(--kf-space-sm);font-family:var(--kf-font-body)}.kf-drf__footer kf-button{flex:1 1 0;--kf-button-min-height: var(--kf-hit-target-min)}@media(prefers-reduced-motion:reduce){.kf-drf__preset,.kf-drf__preset-check{transition:none}}\n"], dependencies: [{ kind: "component", type: Button, selector: "kf-button", inputs: ["variant", "size", "shape", "disabled", "type", "icon", "block", "loading", "ariaLabel", "ariaExpanded", "ariaPressed", "ariaDisabled", "ariaDescribedby", "attention", "ariaControls", "ariaHaspopup"], outputs: ["disabledClick"] }, { kind: "component", type: DateRangeCalendar, selector: "kf-date-range-calendar", inputs: ["start", "end", "month", "months", "min", "max", "maxDays", "today", "ariaLabel", "monthNames", "weekdayLabels", "weekdayNames", "previousMonthLabel", "nextMonthLabel", "startDayLabel", "endDayLabel", "inRangeLabel", "startAnnouncement", "endAnnouncement", "pickEndHint"], outputs: ["monthChange", "dayPick", "blockedPick"] }, { kind: "component", type: Drawer, selector: "kf-drawer", inputs: ["open", "side", "role", "ariaLabel", "title", "closeLabel", "size", "sheetSize", "expandable", "sheetWidth", "flush", "swipeToClose", "closeOnBack", "mountInOverlay", "closeGuard"], outputs: ["openChange", "closedAfterBack", "detentChange"] }, { kind: "component", type: Dropdown, selector: "kf-dropdown", inputs: ["open", "anchor", "autoFocus"], outputs: ["openChange"] }, { kind: "component", type: DropdownPanel, selector: "kf-dropdown-panel", inputs: ["variant", "role", "maxHeight", "width", "ariaLabel"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i1.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: Icon, selector: "kf-icon", inputs: ["name", "size", "rotate", "filled"] }, { kind: "component", type: Input, selector: "kf-input", inputs: ["label", "size", "hideLabel", "required", "icon", "suffix", "hint", "invalid", "errorMessage", "disabled", "readonly", "type", "placeholder", "autocomplete", "name", "inputmode", "autocapitalize", "autocorrect", "spellcheck", "enterkeyhint", "min", "max", "step", "maxlength", "describedBy", "toggleable", "ariaLabel", "clearable", "clearLabel"], outputs: ["cleared"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
11273
11507
|
}
|
|
11274
11508
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: DateRangeField, decorators: [{
|
|
11275
11509
|
type: Component,
|
|
@@ -12258,7 +12492,7 @@ class DateTimeField {
|
|
|
12258
12492
|
return parts && date === parts.date ? parts.time : null;
|
|
12259
12493
|
}
|
|
12260
12494
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: DateTimeField, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
12261
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: DateTimeField, isStandalone: true, selector: "kf-datetime-field", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: true, transformFunction: null }, hideLabel: { classPropertyName: "hideLabel", publicName: "hideLabel", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, timeZone: { classPropertyName: "timeZone", publicName: "timeZone", isSignal: true, isRequired: true, transformFunction: null }, zoneName: { classPropertyName: "zoneName", publicName: "zoneName", isSignal: true, isRequired: false, transformFunction: null }, min: { classPropertyName: "min", publicName: "min", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: "max", publicName: "max", isSignal: true, isRequired: false, transformFunction: null }, minuteStep: { classPropertyName: "minuteStep", publicName: "minuteStep", isSignal: true, isRequired: false, transformFunction: null }, nowLabel: { classPropertyName: "nowLabel", publicName: "nowLabel", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, invalid: { classPropertyName: "invalid", publicName: "invalid", isSignal: true, isRequired: false, transformFunction: null }, errorMessage: { classPropertyName: "errorMessage", publicName: "errorMessage", isSignal: true, isRequired: false, transformFunction: null }, locale: { classPropertyName: "locale", publicName: "locale", isSignal: true, isRequired: false, transformFunction: null }, hourCycle: { classPropertyName: "hourCycle", publicName: "hourCycle", isSignal: true, isRequired: false, transformFunction: null }, presentation: { classPropertyName: "presentation", publicName: "presentation", isSignal: true, isRequired: false, transformFunction: null }, dateLabel: { classPropertyName: "dateLabel", publicName: "dateLabel", isSignal: true, isRequired: false, transformFunction: null }, timeLabel: { classPropertyName: "timeLabel", publicName: "timeLabel", isSignal: true, isRequired: false, transformFunction: null }, parseErrorMessage: { classPropertyName: "parseErrorMessage", publicName: "parseErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, rangeErrorMessage: { classPropertyName: "rangeErrorMessage", publicName: "rangeErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, requiredErrorMessage: { classPropertyName: "requiredErrorMessage", publicName: "requiredErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, nonexistentErrorMessage: { classPropertyName: "nonexistentErrorMessage", publicName: "nonexistentErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, ambiguousNote: { classPropertyName: "ambiguousNote", publicName: "ambiguousNote", isSignal: true, isRequired: false, transformFunction: null }, ambiguousLaterNote: { classPropertyName: "ambiguousLaterNote", publicName: "ambiguousLaterNote", isSignal: true, isRequired: false, transformFunction: null }, invalidZoneMessage: { classPropertyName: "invalidZoneMessage", publicName: "invalidZoneMessage", isSignal: true, isRequired: false, transformFunction: null }, openPickerLabel: { classPropertyName: "openPickerLabel", publicName: "openPickerLabel", isSignal: true, isRequired: false, transformFunction: null }, cancelLabel: { classPropertyName: "cancelLabel", publicName: "cancelLabel", isSignal: true, isRequired: false, transformFunction: null }, doneLabel: { classPropertyName: "doneLabel", publicName: "doneLabel", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange" }, viewQueries: [{ propertyName: "sheetTemplate", first: true, predicate: ["sheetTemplate"], descendants: true, isSignal: true }], ngImport: i0, template: "<div\n class=\"kf-datetime-field\"\n role=\"group\"\n [attr.aria-labelledby]=\"labelId\"\n [attr.aria-describedby]=\"describedByIds()\"\n (focusout)=\"onFocusOut($event)\"\n (keydown)=\"onKeydown($event)\"\n>\n <span\n class=\"kf-datetime-field__label kf-field-label-text\"\n [class.kf-sr-only]=\"hideLabel()\"\n [id]=\"labelId\"\n >{{ label() }}\n @if (required()) {\n <span class=\"kf-datetime-field__required\" aria-hidden=\"true\">*</span>\n }\n </span>\n\n <div class=\"kf-datetime-field__row\" [class.kf-datetime-field__row--sheet]=\"asSheet()\">\n <kf-date-field\n class=\"kf-datetime-field__date\"\n presentation=\"popover\"\n [label]=\"dateAccessibleLabel()\"\n [hideLabel]=\"true\"\n [locale]=\"locale()\"\n [min]=\"dateMin()\"\n [max]=\"dateMax()\"\n [required]=\"required()\"\n [disabled]=\"fieldsDisabled()\"\n [invalid]=\"fieldInvalid()\"\n [parseErrorMessage]=\"parseErrorMessage()\"\n [rangeErrorMessage]=\"rangeErrorMessage()\"\n [describedBy]=\"describedByIds()\"\n [hidePicker]=\"asSheet()\"\n [value]=\"date()\"\n (valueChange)=\"onDate($event)\"\n />\n <kf-time-field\n class=\"kf-datetime-field__time\"\n [label]=\"timeAccessibleLabel()\"\n [hideLabel]=\"true\"\n [locale]=\"locale()\"\n [hourCycle]=\"hourCycle()\"\n [step]=\"minuteStep()\"\n [listStep]=\"listStep()\"\n [min]=\"timeMin()\"\n [max]=\"timeMax()\"\n [required]=\"required()\"\n [disabled]=\"fieldsDisabled()\"\n [invalid]=\"fieldInvalid()\"\n [parseErrorMessage]=\"parseErrorMessage()\"\n [rangeErrorMessage]=\"rangeErrorMessage()\"\n [describedBy]=\"describedByIds()\"\n [hidePicker]=\"asSheet()\"\n [value]=\"time()\"\n (valueChange)=\"onTime($event)\"\n />\n @if (asSheet()) {\n <kf-button\n class=\"kf-datetime-field__trigger\"\n variant=\"outline\"\n shape=\"circle\"\n icon=\"calendar\"\n type=\"button\"\n [ariaLabel]=\"openPickerLabel()\"\n [ariaHaspopup]=\"'dialog'\"\n [ariaExpanded]=\"sheetOpen()\"\n [disabled]=\"fieldsDisabled()\"\n (click)=\"openSheet()\"\n />\n }\n </div>\n\n <div class=\"kf-datetime-field__meta\">\n <span class=\"kf-datetime-field__zone kf-field-hint\" [id]=\"hintId\">\n <kf-icon class=\"kf-datetime-field__zone-icon\" name=\"globe\" size=\"sm\" />\n {{ zoneHint() }}\n </span>\n @if (nowLabel(); as nowText) {\n <kf-button\n class=\"kf-datetime-field__now\"\n variant=\"ghost\"\n size=\"sm\"\n icon=\"clock\"\n type=\"button\"\n [disabled]=\"fieldsDisabled()\"\n (click)=\"setNow()\"\n >\n {{ nowText }}\n </kf-button>\n }\n </div>\n @if (ambiguous()) {\n <span class=\"kf-datetime-field__note kf-field-hint\" [id]=\"noteId\">{{ ambiguousText() }}</span>\n }\n @if (groupError(); as message) {\n <span class=\"kf-datetime-field__error kf-field-error\" role=\"alert\" [id]=\"errorId\">{{\n message\n }}</span>\n }\n</div>\n\n<ng-template #sheetTemplate>\n <kf-drawer\n side=\"bottom\"\n role=\"dialog\"\n sheetWidth=\"readable\"\n sheetSize=\"large\"\n [title]=\"label()\"\n [closeLabel]=\"cancelLabel()\"\n [(open)]=\"sheetOpen\"\n >\n <div class=\"kf-datetime-field__sheet\">\n <kf-calendar\n [value]=\"draftDate()\"\n [min]=\"dateMin()\"\n [max]=\"dateMax()\"\n [monthNames]=\"monthNames()\"\n [weekdayLabels]=\"weekdayLabels()\"\n [weekdayNames]=\"weekdayNames()\"\n [ariaLabel]=\"dateAccessibleLabel()\"\n (valueChange)=\"draftDate.set($event)\"\n />\n <kf-time-field\n [label]=\"timeLabel()\"\n [locale]=\"locale()\"\n [hourCycle]=\"hourCycle()\"\n [step]=\"minuteStep()\"\n [listStep]=\"listStep()\"\n [min]=\"draftTimeMin()\"\n [max]=\"draftTimeMax()\"\n [parseErrorMessage]=\"parseErrorMessage()\"\n [rangeErrorMessage]=\"rangeErrorMessage()\"\n [value]=\"draftTime()\"\n (valueChange)=\"draftTime.set($event)\"\n />\n <div class=\"kf-datetime-field__meta\">\n <span class=\"kf-datetime-field__zone kf-field-hint\">\n <kf-icon class=\"kf-datetime-field__zone-icon\" name=\"globe\" size=\"sm\" />\n {{ draftZoneHint() }}\n </span>\n @if (nowLabel(); as nowText) {\n <kf-button\n class=\"kf-datetime-field__now\"\n variant=\"ghost\"\n size=\"sm\"\n icon=\"clock\"\n type=\"button\"\n (click)=\"setDraftNow()\"\n >\n {{ nowText }}\n </kf-button>\n }\n </div>\n @if (draftAmbiguous()) {\n <span class=\"kf-datetime-field__note kf-field-hint\">{{ ambiguousNote() }}</span>\n }\n @if (draftError(); as message) {\n <span class=\"kf-datetime-field__error kf-field-error\" role=\"alert\">{{ message }}</span>\n }\n </div>\n <div kf-drawer-footer class=\"kf-datetime-field__footer\">\n <kf-button class=\"kf-datetime-field__cancel\" variant=\"outline\" (click)=\"cancelSheet()\">{{\n cancelLabel()\n }}</kf-button>\n <kf-button\n class=\"kf-datetime-field__done\"\n [disabled]=\"!draftValid()\"\n (click)=\"confirmSheet()\"\n >{{ doneLabel() }}</kf-button\n >\n </div>\n </kf-drawer>\n</ng-template>\n", styles: [".kf-field-label-text{font-family:var(--kf-font-title);font-size:var(--kf-font-size-caption);font-weight:var(--kf-font-weight-medium);letter-spacing:.04em;text-transform:uppercase;color:var(--kf-color-text-muted)}.kf-field-hint{font-size:.75rem;color:var(--kf-color-text-muted)}.kf-field-error{display:flex;align-items:center;gap:var(--kf-space-xs);font-size:.75rem;font-weight:600;color:var(--kf-color-error-strong)}.kf-sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}:host{display:block;font-family:var(--kf-font-body)}.kf-datetime-field{display:flex;flex-direction:column;gap:var(--kf-space-xs);min-width:0}.kf-datetime-field__required{color:var(--kf-color-error);margin-inline-start:2px}.kf-datetime-field__row{display:grid;grid-template-columns:minmax(0,1.35fr) minmax(0,1fr);gap:var(--kf-space-sm);align-items:start}.kf-datetime-field__row--sheet{grid-template-columns:minmax(0,1.35fr) minmax(0,1fr) auto}.kf-datetime-field__trigger{--kf-button-min-height: var(--kf-hit-target-min);--kf-button-min-width: var(--kf-hit-target-min)}.kf-datetime-field__meta{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:var(--kf-space-xs) var(--kf-space-sm)}.kf-datetime-field__zone{display:inline-flex;align-items:center;gap:var(--kf-space-xs);font-size:var(--kf-font-size-label)}.kf-datetime-field__zone-icon{flex:none}.kf-datetime-field__now{margin-inline-start:auto}.kf-datetime-field__error{margin:0}.kf-datetime-field__sheet{display:flex;flex-direction:column;gap:var(--kf-space-sm);font-family:var(--kf-font-body);--kf-calendar-grid-min-height: 308px ;--kf-calendar-column-gap: 0px}.kf-datetime-field__sheet .kf-datetime-field__now{--kf-button-min-height: var(--kf-hit-target-min)}.kf-datetime-field__footer{display:flex;font-family:var(--kf-font-body);gap:var(--kf-space-sm)}.kf-datetime-field__footer kf-button{flex:1 1 0;--kf-button-min-height: var(--kf-hit-target-min)}\n"], dependencies: [{ kind: "component", type: Button, selector: "kf-button", inputs: ["variant", "size", "shape", "disabled", "type", "icon", "block", "loading", "ariaLabel", "ariaExpanded", "ariaPressed", "ariaDisabled", "ariaDescribedby", "attention", "ariaControls", "ariaHaspopup"], outputs: ["disabledClick"] }, { kind: "component", type: Calendar, selector: "kf-calendar", inputs: ["value", "month", "min", "max", "availableDates", "markedDates", "today", "loading", "ariaLabel", "monthNames", "weekdayLabels", "weekdayNames", "markedLabel", "previousMonthLabel", "nextMonthLabel"], outputs: ["valueChange", "monthChange"] }, { kind: "component", type: DateField, selector: "kf-date-field", inputs: ["label", "hideLabel", "value", "min", "max", "availableDates", "required", "disabled", "invalid", "errorMessage", "hint", "locale", "presentation", "parseErrorMessage", "rangeErrorMessage", "openCalendarLabel", "describedBy", "hidePicker"], outputs: ["valueChange"] }, { kind: "component", type: Drawer, selector: "kf-drawer", inputs: ["open", "side", "role", "ariaLabel", "title", "closeLabel", "size", "sheetSize", "expandable", "sheetWidth", "flush", "swipeToClose", "closeOnBack", "mountInOverlay"], outputs: ["openChange", "closedAfterBack", "detentChange"] }, { kind: "component", type: Icon, selector: "kf-icon", inputs: ["name", "size", "rotate", "filled"] }, { kind: "component", type: TimeField, selector: "kf-time-field", inputs: ["label", "hideLabel", "value", "hourCycle", "step", "listStep", "min", "max", "required", "disabled", "invalid", "errorMessage", "hint", "locale", "parseErrorMessage", "rangeErrorMessage", "openListLabel", "periodLabel", "describedBy", "hidePicker"], outputs: ["valueChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
12495
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: DateTimeField, isStandalone: true, selector: "kf-datetime-field", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: true, transformFunction: null }, hideLabel: { classPropertyName: "hideLabel", publicName: "hideLabel", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, timeZone: { classPropertyName: "timeZone", publicName: "timeZone", isSignal: true, isRequired: true, transformFunction: null }, zoneName: { classPropertyName: "zoneName", publicName: "zoneName", isSignal: true, isRequired: false, transformFunction: null }, min: { classPropertyName: "min", publicName: "min", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: "max", publicName: "max", isSignal: true, isRequired: false, transformFunction: null }, minuteStep: { classPropertyName: "minuteStep", publicName: "minuteStep", isSignal: true, isRequired: false, transformFunction: null }, nowLabel: { classPropertyName: "nowLabel", publicName: "nowLabel", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, invalid: { classPropertyName: "invalid", publicName: "invalid", isSignal: true, isRequired: false, transformFunction: null }, errorMessage: { classPropertyName: "errorMessage", publicName: "errorMessage", isSignal: true, isRequired: false, transformFunction: null }, locale: { classPropertyName: "locale", publicName: "locale", isSignal: true, isRequired: false, transformFunction: null }, hourCycle: { classPropertyName: "hourCycle", publicName: "hourCycle", isSignal: true, isRequired: false, transformFunction: null }, presentation: { classPropertyName: "presentation", publicName: "presentation", isSignal: true, isRequired: false, transformFunction: null }, dateLabel: { classPropertyName: "dateLabel", publicName: "dateLabel", isSignal: true, isRequired: false, transformFunction: null }, timeLabel: { classPropertyName: "timeLabel", publicName: "timeLabel", isSignal: true, isRequired: false, transformFunction: null }, parseErrorMessage: { classPropertyName: "parseErrorMessage", publicName: "parseErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, rangeErrorMessage: { classPropertyName: "rangeErrorMessage", publicName: "rangeErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, requiredErrorMessage: { classPropertyName: "requiredErrorMessage", publicName: "requiredErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, nonexistentErrorMessage: { classPropertyName: "nonexistentErrorMessage", publicName: "nonexistentErrorMessage", isSignal: true, isRequired: false, transformFunction: null }, ambiguousNote: { classPropertyName: "ambiguousNote", publicName: "ambiguousNote", isSignal: true, isRequired: false, transformFunction: null }, ambiguousLaterNote: { classPropertyName: "ambiguousLaterNote", publicName: "ambiguousLaterNote", isSignal: true, isRequired: false, transformFunction: null }, invalidZoneMessage: { classPropertyName: "invalidZoneMessage", publicName: "invalidZoneMessage", isSignal: true, isRequired: false, transformFunction: null }, openPickerLabel: { classPropertyName: "openPickerLabel", publicName: "openPickerLabel", isSignal: true, isRequired: false, transformFunction: null }, cancelLabel: { classPropertyName: "cancelLabel", publicName: "cancelLabel", isSignal: true, isRequired: false, transformFunction: null }, doneLabel: { classPropertyName: "doneLabel", publicName: "doneLabel", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange" }, viewQueries: [{ propertyName: "sheetTemplate", first: true, predicate: ["sheetTemplate"], descendants: true, isSignal: true }], ngImport: i0, template: "<div\n class=\"kf-datetime-field\"\n role=\"group\"\n [attr.aria-labelledby]=\"labelId\"\n [attr.aria-describedby]=\"describedByIds()\"\n (focusout)=\"onFocusOut($event)\"\n (keydown)=\"onKeydown($event)\"\n>\n <span\n class=\"kf-datetime-field__label kf-field-label-text\"\n [class.kf-sr-only]=\"hideLabel()\"\n [id]=\"labelId\"\n >{{ label() }}\n @if (required()) {\n <span class=\"kf-datetime-field__required\" aria-hidden=\"true\">*</span>\n }\n </span>\n\n <div class=\"kf-datetime-field__row\" [class.kf-datetime-field__row--sheet]=\"asSheet()\">\n <kf-date-field\n class=\"kf-datetime-field__date\"\n presentation=\"popover\"\n [label]=\"dateAccessibleLabel()\"\n [hideLabel]=\"true\"\n [locale]=\"locale()\"\n [min]=\"dateMin()\"\n [max]=\"dateMax()\"\n [required]=\"required()\"\n [disabled]=\"fieldsDisabled()\"\n [invalid]=\"fieldInvalid()\"\n [parseErrorMessage]=\"parseErrorMessage()\"\n [rangeErrorMessage]=\"rangeErrorMessage()\"\n [describedBy]=\"describedByIds()\"\n [hidePicker]=\"asSheet()\"\n [value]=\"date()\"\n (valueChange)=\"onDate($event)\"\n />\n <kf-time-field\n class=\"kf-datetime-field__time\"\n [label]=\"timeAccessibleLabel()\"\n [hideLabel]=\"true\"\n [locale]=\"locale()\"\n [hourCycle]=\"hourCycle()\"\n [step]=\"minuteStep()\"\n [listStep]=\"listStep()\"\n [min]=\"timeMin()\"\n [max]=\"timeMax()\"\n [required]=\"required()\"\n [disabled]=\"fieldsDisabled()\"\n [invalid]=\"fieldInvalid()\"\n [parseErrorMessage]=\"parseErrorMessage()\"\n [rangeErrorMessage]=\"rangeErrorMessage()\"\n [describedBy]=\"describedByIds()\"\n [hidePicker]=\"asSheet()\"\n [value]=\"time()\"\n (valueChange)=\"onTime($event)\"\n />\n @if (asSheet()) {\n <kf-button\n class=\"kf-datetime-field__trigger\"\n variant=\"outline\"\n shape=\"circle\"\n icon=\"calendar\"\n type=\"button\"\n [ariaLabel]=\"openPickerLabel()\"\n [ariaHaspopup]=\"'dialog'\"\n [ariaExpanded]=\"sheetOpen()\"\n [disabled]=\"fieldsDisabled()\"\n (click)=\"openSheet()\"\n />\n }\n </div>\n\n <div class=\"kf-datetime-field__meta\">\n <span class=\"kf-datetime-field__zone kf-field-hint\" [id]=\"hintId\">\n <kf-icon class=\"kf-datetime-field__zone-icon\" name=\"globe\" size=\"sm\" />\n {{ zoneHint() }}\n </span>\n @if (nowLabel(); as nowText) {\n <kf-button\n class=\"kf-datetime-field__now\"\n variant=\"ghost\"\n size=\"sm\"\n icon=\"clock\"\n type=\"button\"\n [disabled]=\"fieldsDisabled()\"\n (click)=\"setNow()\"\n >\n {{ nowText }}\n </kf-button>\n }\n </div>\n @if (ambiguous()) {\n <span class=\"kf-datetime-field__note kf-field-hint\" [id]=\"noteId\">{{ ambiguousText() }}</span>\n }\n @if (groupError(); as message) {\n <span class=\"kf-datetime-field__error kf-field-error\" role=\"alert\" [id]=\"errorId\">{{\n message\n }}</span>\n }\n</div>\n\n<ng-template #sheetTemplate>\n <kf-drawer\n side=\"bottom\"\n role=\"dialog\"\n sheetWidth=\"readable\"\n sheetSize=\"large\"\n [title]=\"label()\"\n [closeLabel]=\"cancelLabel()\"\n [(open)]=\"sheetOpen\"\n >\n <div class=\"kf-datetime-field__sheet\">\n <kf-calendar\n [value]=\"draftDate()\"\n [min]=\"dateMin()\"\n [max]=\"dateMax()\"\n [monthNames]=\"monthNames()\"\n [weekdayLabels]=\"weekdayLabels()\"\n [weekdayNames]=\"weekdayNames()\"\n [ariaLabel]=\"dateAccessibleLabel()\"\n (valueChange)=\"draftDate.set($event)\"\n />\n <kf-time-field\n [label]=\"timeLabel()\"\n [locale]=\"locale()\"\n [hourCycle]=\"hourCycle()\"\n [step]=\"minuteStep()\"\n [listStep]=\"listStep()\"\n [min]=\"draftTimeMin()\"\n [max]=\"draftTimeMax()\"\n [parseErrorMessage]=\"parseErrorMessage()\"\n [rangeErrorMessage]=\"rangeErrorMessage()\"\n [value]=\"draftTime()\"\n (valueChange)=\"draftTime.set($event)\"\n />\n <div class=\"kf-datetime-field__meta\">\n <span class=\"kf-datetime-field__zone kf-field-hint\">\n <kf-icon class=\"kf-datetime-field__zone-icon\" name=\"globe\" size=\"sm\" />\n {{ draftZoneHint() }}\n </span>\n @if (nowLabel(); as nowText) {\n <kf-button\n class=\"kf-datetime-field__now\"\n variant=\"ghost\"\n size=\"sm\"\n icon=\"clock\"\n type=\"button\"\n (click)=\"setDraftNow()\"\n >\n {{ nowText }}\n </kf-button>\n }\n </div>\n @if (draftAmbiguous()) {\n <span class=\"kf-datetime-field__note kf-field-hint\">{{ ambiguousNote() }}</span>\n }\n @if (draftError(); as message) {\n <span class=\"kf-datetime-field__error kf-field-error\" role=\"alert\">{{ message }}</span>\n }\n </div>\n <div kf-drawer-footer class=\"kf-datetime-field__footer\">\n <kf-button class=\"kf-datetime-field__cancel\" variant=\"outline\" (click)=\"cancelSheet()\">{{\n cancelLabel()\n }}</kf-button>\n <kf-button\n class=\"kf-datetime-field__done\"\n [disabled]=\"!draftValid()\"\n (click)=\"confirmSheet()\"\n >{{ doneLabel() }}</kf-button\n >\n </div>\n </kf-drawer>\n</ng-template>\n", styles: [".kf-field-label-text{font-family:var(--kf-font-title);font-size:var(--kf-font-size-caption);font-weight:var(--kf-font-weight-medium);letter-spacing:.04em;text-transform:uppercase;color:var(--kf-color-text-muted)}.kf-field-hint{font-size:.75rem;color:var(--kf-color-text-muted)}.kf-field-error{display:flex;align-items:center;gap:var(--kf-space-xs);font-size:.75rem;font-weight:600;color:var(--kf-color-error-strong)}.kf-sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}:host{display:block;font-family:var(--kf-font-body)}.kf-datetime-field{display:flex;flex-direction:column;gap:var(--kf-space-xs);min-width:0}.kf-datetime-field__required{color:var(--kf-color-error);margin-inline-start:2px}.kf-datetime-field__row{display:grid;grid-template-columns:minmax(0,1.35fr) minmax(0,1fr);gap:var(--kf-space-sm);align-items:start}.kf-datetime-field__row--sheet{grid-template-columns:minmax(0,1.35fr) minmax(0,1fr) auto}.kf-datetime-field__trigger{--kf-button-min-height: var(--kf-hit-target-min);--kf-button-min-width: var(--kf-hit-target-min)}.kf-datetime-field__meta{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:var(--kf-space-xs) var(--kf-space-sm)}.kf-datetime-field__zone{display:inline-flex;align-items:center;gap:var(--kf-space-xs);font-size:var(--kf-font-size-label)}.kf-datetime-field__zone-icon{flex:none}.kf-datetime-field__now{margin-inline-start:auto}.kf-datetime-field__error{margin:0}.kf-datetime-field__sheet{display:flex;flex-direction:column;gap:var(--kf-space-sm);font-family:var(--kf-font-body);--kf-calendar-grid-min-height: 308px ;--kf-calendar-column-gap: 0px}.kf-datetime-field__sheet .kf-datetime-field__now{--kf-button-min-height: var(--kf-hit-target-min)}.kf-datetime-field__footer{display:flex;font-family:var(--kf-font-body);gap:var(--kf-space-sm)}.kf-datetime-field__footer kf-button{flex:1 1 0;--kf-button-min-height: var(--kf-hit-target-min)}\n"], dependencies: [{ kind: "component", type: Button, selector: "kf-button", inputs: ["variant", "size", "shape", "disabled", "type", "icon", "block", "loading", "ariaLabel", "ariaExpanded", "ariaPressed", "ariaDisabled", "ariaDescribedby", "attention", "ariaControls", "ariaHaspopup"], outputs: ["disabledClick"] }, { kind: "component", type: Calendar, selector: "kf-calendar", inputs: ["value", "month", "min", "max", "availableDates", "markedDates", "today", "loading", "ariaLabel", "monthNames", "weekdayLabels", "weekdayNames", "markedLabel", "previousMonthLabel", "nextMonthLabel"], outputs: ["valueChange", "monthChange"] }, { kind: "component", type: DateField, selector: "kf-date-field", inputs: ["label", "hideLabel", "value", "min", "max", "availableDates", "required", "disabled", "invalid", "errorMessage", "hint", "locale", "presentation", "parseErrorMessage", "rangeErrorMessage", "openCalendarLabel", "describedBy", "hidePicker"], outputs: ["valueChange"] }, { kind: "component", type: Drawer, selector: "kf-drawer", inputs: ["open", "side", "role", "ariaLabel", "title", "closeLabel", "size", "sheetSize", "expandable", "sheetWidth", "flush", "swipeToClose", "closeOnBack", "mountInOverlay", "closeGuard"], outputs: ["openChange", "closedAfterBack", "detentChange"] }, { kind: "component", type: Icon, selector: "kf-icon", inputs: ["name", "size", "rotate", "filled"] }, { kind: "component", type: TimeField, selector: "kf-time-field", inputs: ["label", "hideLabel", "value", "hourCycle", "step", "listStep", "min", "max", "required", "disabled", "invalid", "errorMessage", "hint", "locale", "parseErrorMessage", "rangeErrorMessage", "openListLabel", "periodLabel", "describedBy", "hidePicker"], outputs: ["valueChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
12262
12496
|
}
|
|
12263
12497
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: DateTimeField, decorators: [{
|
|
12264
12498
|
type: Component,
|
|
@@ -12357,6 +12591,216 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
12357
12591
|
}, template: "<dl class=\"kf-description-list\">\n @for (item of items(); track item.id ?? item.label) {\n <div class=\"kf-description-list__row\">\n <dt class=\"kf-description-list__term\">{{ item.label }}</dt>\n <dd class=\"kf-description-list__value\" [class.kf-description-list__value--mono]=\"item.mono\">\n @if (valueTemplate(); as template) {\n <ng-container\n [ngTemplateOutlet]=\"template.template\"\n [ngTemplateOutletContext]=\"{ $implicit: item }\"\n />\n } @else if (item.value) {\n {{ item.value }}\n } @else {\n <span aria-hidden=\"true\">\u2014</span>\n <span class=\"kf-sr-only\">{{ emptyLabel() }}</span>\n }\n </dd>\n </div>\n }\n</dl>\n", styles: [".kf-sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}:host{display:block;width:100%;container-type:inline-size;font-family:var(--kf-font-body)}.kf-description-list{display:grid;gap:var(--kf-space-sm);margin:0}:host(.kf-description-list--compact) .kf-description-list{gap:var(--kf-space-xs)}.kf-description-list__row{display:flex;flex-direction:column;gap:2px;min-width:0}.kf-description-list__term{font-size:var(--kf-font-size-caption);font-weight:var(--kf-font-weight-medium);color:var(--kf-color-text-muted)}.kf-description-list__value{margin:0;font-size:var(--kf-font-size-body-sm);line-height:1.3;color:var(--kf-color-ink);overflow-wrap:anywhere}.kf-description-list__value--mono{font-family:var(--kf-font-mono)}:host(.kf-description-list--inline) .kf-description-list__row{display:grid;grid-template-columns:minmax(0,8.5rem) minmax(0,1fr);gap:var(--kf-space-xs) var(--kf-space-md)}:host(.kf-description-list--inline) .kf-description-list__term{font-size:var(--kf-font-size-body-sm);color:var(--kf-color-ink)}:host(.kf-description-list--grid) .kf-description-list{grid-template-columns:repeat(auto-fit,minmax(9rem,1fr));gap:var(--kf-space-xs) var(--kf-space-md)}:host(.kf-description-list--grid) .kf-description-list__term{font-family:var(--kf-font-title);letter-spacing:.04em;text-transform:uppercase}:host(.kf-description-list--grid.kf-description-list--compact) .kf-description-list{gap:2px var(--kf-space-sm)}@container (max-width: 29.99rem){:host(.kf-description-list--inline) .kf-description-list__row{grid-template-columns:minmax(0,1fr);gap:2px}}@container (max-width: 19.99rem){:host(.kf-description-list--grid) .kf-description-list{grid-template-columns:minmax(0,1fr)}}\n"] }]
|
|
12358
12592
|
}], propDecorators: { items: [{ type: i0.Input, args: [{ isSignal: true, alias: "items", required: true }] }], layout: [{ type: i0.Input, args: [{ isSignal: true, alias: "layout", required: false }] }], density: [{ type: i0.Input, args: [{ isSignal: true, alias: "density", required: false }] }], emptyLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "emptyLabel", required: false }] }], valueTemplate: [{ type: i0.ContentChild, args: [i0.forwardRef(() => DescriptionValue), { isSignal: true }] }] } });
|
|
12359
12593
|
|
|
12594
|
+
/** Lo que dura la salida del panel; el contenido sale del DOM pasado ese tiempo. */
|
|
12595
|
+
const LEAVE_MS = 400;
|
|
12596
|
+
/**
|
|
12597
|
+
* Panel lateral de detalle de un registro (una persona, una unidad, un ticket) sobre `kf-drawer`
|
|
12598
|
+
* `role="dialog"` anclado a la derecha: título que nombra el diálogo, subtítulo y descripción bajo él,
|
|
12599
|
+
* acciones junto a la X (por ejemplo un botón «Editar» y un menú «⋯» de `kf-action-menu`), cuerpo con
|
|
12600
|
+
* scroll y un pie fijo (por ejemplo `kf-edit-footer`). Foco atrapado, devolución del foco, `Escape` y
|
|
12601
|
+
* telón los resuelve `kf-drawer`; este componente solo compone la cabecera y el ciclo de vida del contenido.
|
|
12602
|
+
*
|
|
12603
|
+
* <kf-detail-drawer [(open)]="open" size="md" [title]="user().name" subtitle="Cuenta corporativa"
|
|
12604
|
+
* closeLabel="Cerrar el detalle de la persona" [closeGuard]="confirmDiscard">
|
|
12605
|
+
* <kf-badge kf-detail-drawer-subtitle tone="ok" dot>Activa</kf-badge>
|
|
12606
|
+
* @if (!editing()) {
|
|
12607
|
+
* <kf-button kf-detail-drawer-actions variant="outline" size="sm" icon="edit" (click)="edit()">Editar</kf-button>
|
|
12608
|
+
* }
|
|
12609
|
+
* <kf-section-card icon="user" title="Cuenta" level="h3">…</kf-section-card>
|
|
12610
|
+
* @if (editing()) {
|
|
12611
|
+
* <kf-edit-footer kf-detail-drawer-footer [changes]="changes()" (saved)="save()" (cancelled)="cancel()" />
|
|
12612
|
+
* }
|
|
12613
|
+
* </kf-detail-drawer>
|
|
12614
|
+
*
|
|
12615
|
+
* ## Contenido
|
|
12616
|
+
* - `title` es obligatorio: nombra el diálogo (`aria-labelledby`). Mientras el dato carga puede ir vacío: la
|
|
12617
|
+
* barra de título, y con ella la X, se conserva.
|
|
12618
|
+
* - `subtitle` es un texto; `[kf-detail-drawer-subtitle]` proyecta contenido propio (un correo y una
|
|
12619
|
+
* insignia de estado) en la misma zona, y `description` explica en una o dos frases qué es lo que se abre.
|
|
12620
|
+
* Sin ninguno de los tres no queda hueco.
|
|
12621
|
+
* - `[kf-detail-drawer-actions]` va a la izquierda de la X y antes de ella en el orden del teclado;
|
|
12622
|
+
* `[kf-detail-drawer-footer]` queda fijo bajo la zona con scroll y, sin contenido, no dibuja su franja.
|
|
12623
|
+
* Con `@if`, un solo elemento raíz por bloque: Angular decide el slot por ese elemento.
|
|
12624
|
+
* - El contenido proyectado solo está en el DOM con el panel abierto y mientras sale (400 ms). Lo
|
|
12625
|
+
* que se declara en la plantilla de quien lo usa se sigue creando: para que un componente hijo no
|
|
12626
|
+
* exista hasta abrir, declararlo dentro de `@if (open())`.
|
|
12627
|
+
*
|
|
12628
|
+
* ## `size`
|
|
12629
|
+
* `sm` (400px, filtros y formularios cortos), `md` (640px, default: detalle y alta) y `lg` (880px: comparar o
|
|
12630
|
+
* revisar). A ancho completo bajo 600px.
|
|
12631
|
+
*
|
|
12632
|
+
* ## Cerrar con una pregunta: `closeGuard` y `requestClose()`
|
|
12633
|
+
* `closeGuard` se consulta antes de cerrar por la X, el telón o `Escape` (ver `DrawerCloseGuard`); un
|
|
12634
|
+
* editor lo usa para preguntar si descartar lo escrito, y su propio «Cancelar» llama a `requestClose()`,
|
|
12635
|
+
* que pasa por la misma guarda. Un diálogo o un menú abierto encima (`kf-confirm-dialog`, `kf-action-menu`)
|
|
12636
|
+
* consume su `Escape`: el panel sigue abierto.
|
|
12637
|
+
*
|
|
12638
|
+
* No admite `mountInOverlay`: la cabecera se ajusta con estilos que alcanzan al panel mientras es descendiente
|
|
12639
|
+
* de este componente; un ancestro con `container-type`, `transform` o `contain` captura el `position: fixed`
|
|
12640
|
+
* del panel, así que va fuera de ese ancestro.
|
|
12641
|
+
*/
|
|
12642
|
+
class DetailDrawer {
|
|
12643
|
+
/** Visibilidad del panel, two-way: `[(open)]="open"`. */
|
|
12644
|
+
open = model(false, /* @ts-ignore */
|
|
12645
|
+
...(ngDevMode ? [{ debugName: "open" }] : /* istanbul ignore next */ []));
|
|
12646
|
+
/** Ancho del panel: `sm` 400px, `md` 640px (default) o `lg` 880px. */
|
|
12647
|
+
size = input('md', /* @ts-ignore */
|
|
12648
|
+
...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
12649
|
+
/** Nombre del panel; puede ir vacío mientras el dato carga. */
|
|
12650
|
+
title = input.required(/* @ts-ignore */
|
|
12651
|
+
...(ngDevMode ? [{ debugName: "title" }] : /* istanbul ignore next */ []));
|
|
12652
|
+
/** Línea de texto bajo el título; para contenido propio, `[kf-detail-drawer-subtitle]`. */
|
|
12653
|
+
subtitle = input(/* @ts-ignore */
|
|
12654
|
+
...(ngDevMode ? [undefined, { debugName: "subtitle" }] : /* istanbul ignore next */ []));
|
|
12655
|
+
/** Qué es lo que se abre, en una o dos frases; vacío no deja hueco. */
|
|
12656
|
+
description = input(/* @ts-ignore */
|
|
12657
|
+
...(ngDevMode ? [undefined, { debugName: "description" }] : /* istanbul ignore next */ []));
|
|
12658
|
+
/** Nombre accesible del botón de cerrar y del telón. */
|
|
12659
|
+
closeLabel = input('Cerrar detalle', /* @ts-ignore */
|
|
12660
|
+
...(ngDevMode ? [{ debugName: "closeLabel" }] : /* istanbul ignore next */ []));
|
|
12661
|
+
/** Se consulta antes de cerrar por la X, el telón o `Escape`; `false` deja el panel abierto. */
|
|
12662
|
+
closeGuard = input(null, /* @ts-ignore */
|
|
12663
|
+
...(ngDevMode ? [{ debugName: "closeGuard" }] : /* istanbul ignore next */ []));
|
|
12664
|
+
/** La barra de título (con la X) solo existe con un título: mientras el dato carga se deja un espacio, no se quita. */
|
|
12665
|
+
drawerTitle = computed(() => this.title() || '\u00A0', /* @ts-ignore */
|
|
12666
|
+
...(ngDevMode ? [{ debugName: "drawerTitle" }] : /* istanbul ignore next */ []));
|
|
12667
|
+
/** El contenido está en el DOM con el panel abierto y lo que dura su salida. */
|
|
12668
|
+
rendered = linkedSignal({ ...(ngDevMode ? { debugName: "rendered" } : /* istanbul ignore next */ {}), source: this.open,
|
|
12669
|
+
computation: (open, previous) => open || (previous?.value ?? false) });
|
|
12670
|
+
drawer = viewChild.required(Drawer, /* @ts-ignore */
|
|
12671
|
+
...(ngDevMode ? [{ debugName: "drawer" }] : /* istanbul ignore next */ []));
|
|
12672
|
+
leaveTimer;
|
|
12673
|
+
constructor() {
|
|
12674
|
+
effect(() => {
|
|
12675
|
+
const open = this.open();
|
|
12676
|
+
untracked(() => {
|
|
12677
|
+
clearTimeout(this.leaveTimer);
|
|
12678
|
+
if (!open) {
|
|
12679
|
+
this.leaveTimer = setTimeout(() => this.rendered.set(false), LEAVE_MS);
|
|
12680
|
+
}
|
|
12681
|
+
});
|
|
12682
|
+
});
|
|
12683
|
+
inject(DestroyRef).onDestroy(() => clearTimeout(this.leaveTimer));
|
|
12684
|
+
}
|
|
12685
|
+
/**
|
|
12686
|
+
* Cierra el panel como lo pediría la persona: con `closeGuard`, solo si la guarda lo permite. Es lo que
|
|
12687
|
+
* llama el «Cancelar» de un editor. Resuelve `true` si quedó cerrado.
|
|
12688
|
+
*/
|
|
12689
|
+
requestClose() {
|
|
12690
|
+
return this.drawer().requestClose();
|
|
12691
|
+
}
|
|
12692
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: DetailDrawer, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
12693
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: DetailDrawer, isStandalone: true, selector: "kf-detail-drawer", inputs: { open: { classPropertyName: "open", publicName: "open", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: true, transformFunction: null }, subtitle: { classPropertyName: "subtitle", publicName: "subtitle", isSignal: true, isRequired: false, transformFunction: null }, description: { classPropertyName: "description", publicName: "description", isSignal: true, isRequired: false, transformFunction: null }, closeLabel: { classPropertyName: "closeLabel", publicName: "closeLabel", isSignal: true, isRequired: false, transformFunction: null }, closeGuard: { classPropertyName: "closeGuard", publicName: "closeGuard", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { open: "openChange" }, viewQueries: [{ propertyName: "drawer", first: true, predicate: Drawer, descendants: true, isSignal: true }], ngImport: i0, template: "<kf-drawer\n role=\"dialog\"\n side=\"right\"\n [title]=\"drawerTitle()\"\n [closeLabel]=\"closeLabel()\"\n [size]=\"size()\"\n [closeGuard]=\"closeGuard()\"\n [open]=\"open()\"\n (openChange)=\"open.set($event)\"\n>\n <!-- Sin contenedor propio en los slots de acciones y de pie: vac\u00EDos, `kf-drawer` no les dibuja\n su espacio (`:empty` ignora los comentarios de las anclas). -->\n <ng-container ngProjectAs=\"[kf-drawer-actions]\">\n @if (rendered()) {\n <ng-content select=\"[kf-detail-drawer-actions]\" />\n }\n </ng-container>\n\n <div kf-drawer-header class=\"kf-detail-drawer__meta\">\n @if (subtitle(); as text) {\n <p class=\"kf-detail-drawer__subtitle\">{{ text }}</p>\n }\n <div class=\"kf-detail-drawer__sub-slot\">\n @if (rendered()) {\n <ng-content select=\"[kf-detail-drawer-subtitle]\" />\n }\n </div>\n @if (description(); as text) {\n <p class=\"kf-detail-drawer__description\">{{ text }}</p>\n }\n </div>\n\n <div class=\"kf-detail-drawer__content\">\n @if (rendered()) {\n <ng-content />\n }\n </div>\n\n <ng-container ngProjectAs=\"[kf-drawer-footer]\">\n @if (rendered()) {\n <ng-content select=\"[kf-detail-drawer-footer]\" />\n }\n </ng-container>\n</kf-drawer>\n", styles: [":host{display:contents}:host ::ng-deep .kf-drawer__titlebar.kf-drawer__titlebar{border-bottom:0}:host ::ng-deep .kf-drawer__header.kf-drawer__header{padding:0;background:transparent}:host ::ng-deep .kf-drawer__close.kf-drawer__close{--kf-button-ghost-fg: var(--kf-color-text-muted);--kf-button-ghost-hover-bg: var(--kf-color-surface)}.kf-detail-drawer__meta{display:flex;flex-direction:column;gap:2px;min-width:0;padding:0 var(--kf-space-lg) var(--kf-space-md);border-bottom:1px solid var(--kf-color-border)}.kf-detail-drawer__meta:not(:has(>:not(:empty))){padding-block-end:0}.kf-detail-drawer__subtitle{margin:0;font-size:var(--kf-font-size-body-sm);color:var(--kf-color-text-muted);overflow-wrap:anywhere}.kf-detail-drawer__description{margin:0;font-size:var(--kf-font-size-body-sm);color:var(--kf-color-text);overflow-wrap:anywhere}.kf-detail-drawer__sub-slot:empty{display:none}.kf-detail-drawer__content{flex:none;min-width:0}@media(pointer:coarse),(max-width:760px){:host ::ng-deep .kf-drawer__controls{--kf-button-min-height: 44px;--kf-button-min-width: 44px}}\n"], dependencies: [{ kind: "component", type: Drawer, selector: "kf-drawer", inputs: ["open", "side", "role", "ariaLabel", "title", "closeLabel", "size", "sheetSize", "expandable", "sheetWidth", "flush", "swipeToClose", "closeOnBack", "mountInOverlay", "closeGuard"], outputs: ["openChange", "closedAfterBack", "detentChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
12694
|
+
}
|
|
12695
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: DetailDrawer, decorators: [{
|
|
12696
|
+
type: Component,
|
|
12697
|
+
args: [{ selector: 'kf-detail-drawer', imports: [Drawer], changeDetection: ChangeDetectionStrategy.OnPush, template: "<kf-drawer\n role=\"dialog\"\n side=\"right\"\n [title]=\"drawerTitle()\"\n [closeLabel]=\"closeLabel()\"\n [size]=\"size()\"\n [closeGuard]=\"closeGuard()\"\n [open]=\"open()\"\n (openChange)=\"open.set($event)\"\n>\n <!-- Sin contenedor propio en los slots de acciones y de pie: vac\u00EDos, `kf-drawer` no les dibuja\n su espacio (`:empty` ignora los comentarios de las anclas). -->\n <ng-container ngProjectAs=\"[kf-drawer-actions]\">\n @if (rendered()) {\n <ng-content select=\"[kf-detail-drawer-actions]\" />\n }\n </ng-container>\n\n <div kf-drawer-header class=\"kf-detail-drawer__meta\">\n @if (subtitle(); as text) {\n <p class=\"kf-detail-drawer__subtitle\">{{ text }}</p>\n }\n <div class=\"kf-detail-drawer__sub-slot\">\n @if (rendered()) {\n <ng-content select=\"[kf-detail-drawer-subtitle]\" />\n }\n </div>\n @if (description(); as text) {\n <p class=\"kf-detail-drawer__description\">{{ text }}</p>\n }\n </div>\n\n <div class=\"kf-detail-drawer__content\">\n @if (rendered()) {\n <ng-content />\n }\n </div>\n\n <ng-container ngProjectAs=\"[kf-drawer-footer]\">\n @if (rendered()) {\n <ng-content select=\"[kf-detail-drawer-footer]\" />\n }\n </ng-container>\n</kf-drawer>\n", styles: [":host{display:contents}:host ::ng-deep .kf-drawer__titlebar.kf-drawer__titlebar{border-bottom:0}:host ::ng-deep .kf-drawer__header.kf-drawer__header{padding:0;background:transparent}:host ::ng-deep .kf-drawer__close.kf-drawer__close{--kf-button-ghost-fg: var(--kf-color-text-muted);--kf-button-ghost-hover-bg: var(--kf-color-surface)}.kf-detail-drawer__meta{display:flex;flex-direction:column;gap:2px;min-width:0;padding:0 var(--kf-space-lg) var(--kf-space-md);border-bottom:1px solid var(--kf-color-border)}.kf-detail-drawer__meta:not(:has(>:not(:empty))){padding-block-end:0}.kf-detail-drawer__subtitle{margin:0;font-size:var(--kf-font-size-body-sm);color:var(--kf-color-text-muted);overflow-wrap:anywhere}.kf-detail-drawer__description{margin:0;font-size:var(--kf-font-size-body-sm);color:var(--kf-color-text);overflow-wrap:anywhere}.kf-detail-drawer__sub-slot:empty{display:none}.kf-detail-drawer__content{flex:none;min-width:0}@media(pointer:coarse),(max-width:760px){:host ::ng-deep .kf-drawer__controls{--kf-button-min-height: 44px;--kf-button-min-width: 44px}}\n"] }]
|
|
12698
|
+
}], ctorParameters: () => [], propDecorators: { open: [{ type: i0.Input, args: [{ isSignal: true, alias: "open", required: false }] }, { type: i0.Output, args: ["openChange"] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: true }] }], subtitle: [{ type: i0.Input, args: [{ isSignal: true, alias: "subtitle", required: false }] }], description: [{ type: i0.Input, args: [{ isSignal: true, alias: "description", required: false }] }], closeLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "closeLabel", required: false }] }], closeGuard: [{ type: i0.Input, args: [{ isSignal: true, alias: "closeGuard", required: false }] }], drawer: [{ type: i0.ViewChild, args: [i0.forwardRef(() => Drawer), { isSignal: true }] }] } });
|
|
12699
|
+
|
|
12700
|
+
/**
|
|
12701
|
+
* Pregunta única «¿descartar lo escrito?» que comparten todos los cierres con cambios sin guardar. Un solo
|
|
12702
|
+
* anfitrión (`kf-discard-prompt-host`, montado una vez en el layout) la pinta; quien la necesita espera la
|
|
12703
|
+
* respuesta. Dos pedidos a la vez reciben la misma respuesta, así que la X y `Escape` pulsados seguidos no
|
|
12704
|
+
* apilan dos preguntas. Es la respuesta natural de un `closeGuard` (`kf-drawer`, `kf-detail-drawer`):
|
|
12705
|
+
*
|
|
12706
|
+
* readonly prompt = inject(DiscardPromptService);
|
|
12707
|
+
* readonly confirmDiscard = async () => !this.dirty() || this.prompt.request();
|
|
12708
|
+
*
|
|
12709
|
+
* <kf-detail-drawer [(open)]="open" title="Editar" [closeGuard]="confirmDiscard">…</kf-detail-drawer>
|
|
12710
|
+
*
|
|
12711
|
+
* Sin un `kf-discard-prompt-host` en el árbol, `request()` no se resuelve nunca.
|
|
12712
|
+
*/
|
|
12713
|
+
class DiscardPromptService {
|
|
12714
|
+
pendingSignal = signal$1(false, /* @ts-ignore */
|
|
12715
|
+
...(ngDevMode ? [{ debugName: "pendingSignal" }] : /* istanbul ignore next */ []));
|
|
12716
|
+
/** Verdadero mientras la pregunta está en pantalla. */
|
|
12717
|
+
pending = this.pendingSignal.asReadonly();
|
|
12718
|
+
waiting = null;
|
|
12719
|
+
resolve = null;
|
|
12720
|
+
/** Verdadero si la persona eligió descartar; falso si eligió seguir editando. */
|
|
12721
|
+
request() {
|
|
12722
|
+
this.waiting ??= new Promise((resolve) => {
|
|
12723
|
+
this.resolve = resolve;
|
|
12724
|
+
this.pendingSignal.set(true);
|
|
12725
|
+
});
|
|
12726
|
+
return this.waiting;
|
|
12727
|
+
}
|
|
12728
|
+
/** Respuesta de la persona; la emite el anfitrión. Sin pregunta pendiente no hace nada. */
|
|
12729
|
+
answer(discard) {
|
|
12730
|
+
const resolve = this.resolve;
|
|
12731
|
+
this.resolve = null;
|
|
12732
|
+
this.waiting = null;
|
|
12733
|
+
this.pendingSignal.set(false);
|
|
12734
|
+
resolve?.(discard);
|
|
12735
|
+
}
|
|
12736
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: DiscardPromptService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
12737
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: DiscardPromptService, providedIn: 'root' });
|
|
12738
|
+
}
|
|
12739
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: DiscardPromptService, decorators: [{
|
|
12740
|
+
type: Injectable,
|
|
12741
|
+
args: [{ providedIn: 'root' }]
|
|
12742
|
+
}] });
|
|
12743
|
+
/**
|
|
12744
|
+
* Diálogo de `DiscardPromptService`, montado una sola vez en el layout de la aplicación, junto a
|
|
12745
|
+
* `kf-toast-host`. Es un `kf-confirm-dialog` con `tone="danger"`: el foco inicial queda en «Seguir editando»
|
|
12746
|
+
* y `Escape`, la X y el fondo equivalen a esa misma salida, así que nada se descarta sin pedirlo. Los
|
|
12747
|
+
* textos se pueden cambiar con `title`, `message`, `keepLabel` y `discardLabel`.
|
|
12748
|
+
*
|
|
12749
|
+
* <kf-discard-prompt-host />
|
|
12750
|
+
*/
|
|
12751
|
+
class DiscardPromptHost {
|
|
12752
|
+
prompt = inject(DiscardPromptService);
|
|
12753
|
+
title = input('Hay cambios sin guardar', /* @ts-ignore */
|
|
12754
|
+
...(ngDevMode ? [{ debugName: "title" }] : /* istanbul ignore next */ []));
|
|
12755
|
+
message = input('¿Descartarlos?', /* @ts-ignore */
|
|
12756
|
+
...(ngDevMode ? [{ debugName: "message" }] : /* istanbul ignore next */ []));
|
|
12757
|
+
/** Salida segura: deja el diálogo o panel abierto con lo escrito. */
|
|
12758
|
+
keepLabel = input('Seguir editando', /* @ts-ignore */
|
|
12759
|
+
...(ngDevMode ? [{ debugName: "keepLabel" }] : /* istanbul ignore next */ []));
|
|
12760
|
+
/** Acción destructiva: descarta lo escrito y cierra. */
|
|
12761
|
+
discardLabel = input('Descartar cambios', /* @ts-ignore */
|
|
12762
|
+
...(ngDevMode ? [{ debugName: "discardLabel" }] : /* istanbul ignore next */ []));
|
|
12763
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: DiscardPromptHost, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
12764
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.0", type: DiscardPromptHost, isStandalone: true, selector: "kf-discard-prompt-host", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, message: { classPropertyName: "message", publicName: "message", isSignal: true, isRequired: false, transformFunction: null }, keepLabel: { classPropertyName: "keepLabel", publicName: "keepLabel", isSignal: true, isRequired: false, transformFunction: null }, discardLabel: { classPropertyName: "discardLabel", publicName: "discardLabel", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: `
|
|
12765
|
+
<kf-confirm-dialog
|
|
12766
|
+
tone="danger"
|
|
12767
|
+
icon="alert-triangle"
|
|
12768
|
+
iconPlacement="title"
|
|
12769
|
+
[open]="prompt.pending()"
|
|
12770
|
+
[title]="title()"
|
|
12771
|
+
[message]="message()"
|
|
12772
|
+
[confirmLabel]="discardLabel()"
|
|
12773
|
+
[cancelLabel]="keepLabel()"
|
|
12774
|
+
[autoClose]="false"
|
|
12775
|
+
(confirmed)="prompt.answer(true)"
|
|
12776
|
+
(cancelled)="prompt.answer(false)"
|
|
12777
|
+
/>
|
|
12778
|
+
`, isInline: true, dependencies: [{ kind: "component", type: ConfirmDialog, selector: "kf-confirm-dialog", inputs: ["open", "tone", "title", "message", "icon", "iconPlacement", "iconTone", "confirmLabel", "cancelLabel", "busy", "consequence", "reasonLabel", "reasonMinLength", "reasonMaxLength", "reasonOptional", "reasonPlaceholder", "reasonHint", "reasonError", "error", "errorTitle", "acknowledgeLabel", "acknowledgeError", "autoClose"], outputs: ["openChange", "confirmed", "cancelled"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
12779
|
+
}
|
|
12780
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: DiscardPromptHost, decorators: [{
|
|
12781
|
+
type: Component,
|
|
12782
|
+
args: [{
|
|
12783
|
+
selector: 'kf-discard-prompt-host',
|
|
12784
|
+
imports: [ConfirmDialog],
|
|
12785
|
+
template: `
|
|
12786
|
+
<kf-confirm-dialog
|
|
12787
|
+
tone="danger"
|
|
12788
|
+
icon="alert-triangle"
|
|
12789
|
+
iconPlacement="title"
|
|
12790
|
+
[open]="prompt.pending()"
|
|
12791
|
+
[title]="title()"
|
|
12792
|
+
[message]="message()"
|
|
12793
|
+
[confirmLabel]="discardLabel()"
|
|
12794
|
+
[cancelLabel]="keepLabel()"
|
|
12795
|
+
[autoClose]="false"
|
|
12796
|
+
(confirmed)="prompt.answer(true)"
|
|
12797
|
+
(cancelled)="prompt.answer(false)"
|
|
12798
|
+
/>
|
|
12799
|
+
`,
|
|
12800
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
12801
|
+
}]
|
|
12802
|
+
}], propDecorators: { title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], message: [{ type: i0.Input, args: [{ isSignal: true, alias: "message", required: false }] }], keepLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "keepLabel", required: false }] }], discardLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "discardLabel", required: false }] }] } });
|
|
12803
|
+
|
|
12360
12804
|
/**
|
|
12361
12805
|
* Separador visual simple entre bloques de contenido. `orientation`
|
|
12362
12806
|
* controla si es una línea horizontal (para separar secciones apiladas) o
|
|
@@ -12596,7 +13040,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
12596
13040
|
args: [{ selector: 'kf-fieldset', imports: [Icon], changeDetection: ChangeDetectionStrategy.OnPush, template: "<fieldset\n class=\"kf-fieldset\"\n [class.kf-fieldset--invalid]=\"invalid()\"\n [disabled]=\"disabled()\"\n [attr.aria-describedby]=\"describedBy()\"\n>\n <legend class=\"kf-fieldset__legend kf-field-label-text\">\n <span class=\"kf-fieldset__legend-row\">\n @if (invalid()) {\n <kf-icon class=\"kf-fieldset__invalid-icon\" name=\"alert-circle\" size=\"sm\" />\n }\n <span class=\"kf-fieldset__legend-text\">\n {{ legend() }}\n @if (required()) {\n <span class=\"kf-fieldset__required\" aria-hidden=\"true\">*</span>\n }\n </span>\n </span>\n </legend>\n <div class=\"kf-fieldset__content\"><ng-content /></div>\n @if (errorMessage(); as message) {\n <span class=\"kf-fieldset__error kf-field-error\" role=\"alert\" [id]=\"errorId\">{{ message }}</span>\n } @else if (hint(); as text) {\n <span class=\"kf-fieldset__hint kf-field-hint\" [id]=\"hintId\">{{ text }}</span>\n }\n</fieldset>\n", styles: [".kf-field-label-text{font-family:var(--kf-font-title);font-size:var(--kf-font-size-caption);font-weight:var(--kf-font-weight-medium);letter-spacing:.04em;text-transform:uppercase;color:var(--kf-color-text-muted)}.kf-field-hint{font-size:.75rem;color:var(--kf-color-text-muted)}.kf-field-error{display:flex;align-items:center;gap:var(--kf-space-xs);font-size:.75rem;font-weight:600;color:var(--kf-color-error-strong)}:host{display:block;font-family:var(--kf-font-body)}.kf-fieldset{display:flex;flex-direction:column;gap:var(--kf-space-xs);min-width:0;margin:0;padding:0;border:none}.kf-fieldset__legend{padding:0;margin-bottom:var(--kf-space-xs)}.kf-fieldset__required{color:var(--kf-color-error);margin-inline-start:2px}.kf-fieldset__content{display:flex;flex-direction:column;gap:var(--kf-space-sm);padding:var(--kf-space-xs) 0}.kf-fieldset__legend-row{display:inline-flex;align-items:center;gap:var(--kf-space-xs)}.kf-fieldset--invalid .kf-fieldset__legend,.kf-fieldset__invalid-icon{color:var(--kf-color-error-strong)}.kf-fieldset:disabled{opacity:.55}\n"] }]
|
|
12597
13041
|
}], propDecorators: { legend: [{ type: i0.Input, args: [{ isSignal: true, alias: "legend", required: true }] }], required: [{ type: i0.Input, args: [{ isSignal: true, alias: "required", required: false }] }], invalid: [{ type: i0.Input, args: [{ isSignal: true, alias: "invalid", required: false }] }], errorMessage: [{ type: i0.Input, args: [{ isSignal: true, alias: "errorMessage", required: false }] }], hint: [{ type: i0.Input, args: [{ isSignal: true, alias: "hint", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }] } });
|
|
12598
13042
|
|
|
12599
|
-
let nextId$
|
|
13043
|
+
let nextId$5 = 0;
|
|
12600
13044
|
/** Nombre legible de un token de `accept`: `.pdf` → `PDF`, `image/png` → `PNG`, `image/*` → `Imágenes`. */
|
|
12601
13045
|
function describeAcceptToken(token) {
|
|
12602
13046
|
const generic = {
|
|
@@ -12710,7 +13154,7 @@ class FileInput {
|
|
|
12710
13154
|
fileChange = output();
|
|
12711
13155
|
/** Un archivo descartado y su motivo. */
|
|
12712
13156
|
fileRejected = output();
|
|
12713
|
-
inputId = `kf-file-input-${nextId$
|
|
13157
|
+
inputId = `kf-file-input-${nextId$5++}`;
|
|
12714
13158
|
hintId = `${this.inputId}-hint`;
|
|
12715
13159
|
errorId = `${this.inputId}-error`;
|
|
12716
13160
|
filesId = `${this.inputId}-files`;
|
|
@@ -12907,7 +13351,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
12907
13351
|
], template: "@if (label()) {\n <kf-field-label [for]=\"inputId\" [required]=\"required()\">{{ label() }}</kf-field-label>\n}\n<div\n class=\"kf-file-input__area\"\n [class.kf-file-input__area--dropzone]=\"dropzone()\"\n [class.kf-file-input__area--dragging]=\"dragging()\"\n [class.kf-file-input__area--invalid]=\"isInvalid()\"\n [class.kf-file-input__area--disabled]=\"isDisabled()\"\n (dragover)=\"dropzone() ? onDragOver($event) : null\"\n (dragleave)=\"dropzone() ? onDragLeave() : null\"\n (drop)=\"dropzone() ? onDrop($event) : null\"\n>\n <input\n #nativeInput\n type=\"file\"\n class=\"kf-file-input__native\"\n [id]=\"inputId\"\n [attr.accept]=\"accept() || null\"\n [multiple]=\"multiple()\"\n [disabled]=\"isDisabled()\"\n [required]=\"required() && !files().length\"\n [attr.aria-describedby]=\"describedBy()\"\n [attr.aria-invalid]=\"isInvalid() ? true : null\"\n [attr.aria-label]=\"label() ? null : ariaLabel() || null\"\n (change)=\"onPick($event)\"\n />\n <label class=\"kf-file-input__button\" [for]=\"inputId\" aria-hidden=\"true\">\n <kf-icon name=\"upload-cloud\" size=\"sm\" />\n {{ triggerText() }}\n </label>\n @if (dropzone()) {\n <span class=\"kf-file-input__drop-text\" aria-hidden=\"true\">{{ dropzoneText() }}</span>\n }\n</div>\n@if (files().length) {\n <ul class=\"kf-file-input__files\" [id]=\"filesId\">\n @for (file of files(); track $index) {\n <li class=\"kf-file-input__file\">\n <kf-icon class=\"kf-file-input__file-icon\" name=\"file\" size=\"sm\" />\n <span class=\"kf-file-input__file-name\">{{ file.name }}</span>\n <span class=\"kf-file-input__file-size\">{{ formatSize(file) }}</span>\n <button\n type=\"button\"\n class=\"kf-file-input__remove\"\n [attr.aria-label]=\"removeLabel() + ' ' + file.name\"\n [disabled]=\"isDisabled()\"\n (click)=\"remove($index)\"\n >\n <kf-icon name=\"x\" size=\"sm\" />\n </button>\n </li>\n }\n </ul>\n}\n@if (message(); as text) {\n <span class=\"kf-file-input__error kf-field-error\" [id]=\"errorId\" role=\"alert\">{{ text }}</span>\n}\n@if (effectiveHint() && !error()) {\n <span class=\"kf-file-input__hint kf-field-hint\" [id]=\"hintId\">{{ effectiveHint() }}</span>\n}\n", styles: [".kf-field-hint{font-size:.75rem;color:var(--kf-color-text-muted)}.kf-field-error{display:flex;align-items:center;gap:var(--kf-space-xs);font-size:.75rem;font-weight:600;color:var(--kf-color-error-strong)}:host{display:flex;flex-direction:column;gap:var(--kf-space-xs);font-family:var(--kf-font-body)}.kf-file-input__area{position:relative;display:flex;align-items:center;gap:var(--kf-space-sm)}.kf-file-input__native{position:absolute;inset:0;width:100%;height:100%;margin:0;opacity:0;cursor:pointer}.kf-file-input__native:disabled{cursor:not-allowed}.kf-file-input__button{display:inline-flex;align-items:center;justify-content:center;gap:var(--kf-space-xs);min-height:2.25rem;padding:var(--kf-space-sm) var(--kf-space-md);box-sizing:border-box;border:1px solid var(--kf-color-primary);border-radius:var(--kf-radius-sm);background:var(--kf-color-white);color:var(--kf-color-primary-active);font:inherit;font-weight:600;pointer-events:none;transition:background var(--kf-motion-fast, .14s),box-shadow var(--kf-motion-fast, .14s)}.kf-file-input__area:hover .kf-file-input__native:not(:disabled)+.kf-file-input__button{background:var(--kf-color-primary-soft)}.kf-file-input__native:focus-visible+.kf-file-input__button{box-shadow:var(--kf-shadow-focus);outline:2px solid transparent}.kf-file-input__area--invalid .kf-file-input__button{border-color:var(--kf-color-error);color:var(--kf-color-error-strong)}.kf-file-input__area--invalid .kf-file-input__native:focus-visible+.kf-file-input__button{box-shadow:var(--kf-shadow-focus-error)}.kf-file-input__area--disabled{opacity:.5}.kf-file-input__area--dropzone{flex-direction:column;justify-content:center;gap:var(--kf-space-xs);padding:var(--kf-space-lg) var(--kf-space-md);border:1px dashed var(--kf-color-border-strong);border-radius:var(--kf-radius-sm);background:var(--kf-color-surface);transition:background var(--kf-motion-fast, .14s),border-color var(--kf-motion-fast, .14s)}.kf-file-input__area--dragging{border-color:var(--kf-color-primary);background:var(--kf-color-primary-soft)}.kf-file-input__area--dropzone.kf-file-input__area--invalid{border-color:var(--kf-color-error)}.kf-file-input__drop-text{font-size:.875rem;color:var(--kf-color-text);pointer-events:none}.kf-file-input__files{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:var(--kf-space-xs)}.kf-file-input__file{display:flex;align-items:center;gap:var(--kf-space-sm);padding:var(--kf-space-xs) var(--kf-space-sm);border:1px solid var(--kf-color-border);border-radius:var(--kf-radius-sm);background:var(--kf-color-white);min-width:0}.kf-file-input__file-icon{flex:none;color:var(--kf-color-text-muted)}.kf-file-input__file-name{flex:1 1 auto;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--kf-color-ink);font-weight:600}.kf-file-input__file-size{flex:none;font-size:.75rem;color:var(--kf-color-text)}.kf-file-input__remove{flex:none;display:inline-flex;align-items:center;justify-content:center;min-width:2rem;min-height:2rem;padding:0;border:none;border-radius:var(--kf-radius-xs);background:transparent;color:var(--kf-color-text);cursor:pointer}.kf-file-input__remove:hover:not(:disabled){background:var(--kf-color-surface);color:var(--kf-color-ink)}.kf-file-input__remove:focus-visible{outline:none;box-shadow:var(--kf-shadow-focus)}.kf-file-input__hint{color:var(--kf-color-text)}@media(pointer:coarse),(max-width:760px){.kf-file-input__button{min-height:44px}.kf-file-input__remove{min-width:44px;min-height:44px}}\n"] }]
|
|
12908
13352
|
}], propDecorators: { nativeInput: [{ type: i0.ViewChild, args: ['nativeInput', { isSignal: true }] }], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], required: [{ type: i0.Input, args: [{ isSignal: true, alias: "required", required: false }] }], hint: [{ type: i0.Input, args: [{ isSignal: true, alias: "hint", required: false }] }], accept: [{ type: i0.Input, args: [{ isSignal: true, alias: "accept", required: false }] }], maxSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxSize", required: false }] }], multiple: [{ type: i0.Input, args: [{ isSignal: true, alias: "multiple", required: false }] }], dropzone: [{ type: i0.Input, args: [{ isSignal: true, alias: "dropzone", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], invalid: [{ type: i0.Input, args: [{ isSignal: true, alias: "invalid", required: false }] }], error: [{ type: i0.Input, args: [{ isSignal: true, alias: "error", required: false }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }], buttonLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "buttonLabel", required: false }] }], changeLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "changeLabel", required: false }] }], removeLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "removeLabel", required: false }] }], dropzoneText: [{ type: i0.Input, args: [{ isSignal: true, alias: "dropzoneText", required: false }] }], rejectedTypeText: [{ type: i0.Input, args: [{ isSignal: true, alias: "rejectedTypeText", required: false }] }], rejectedSizeText: [{ type: i0.Input, args: [{ isSignal: true, alias: "rejectedSizeText", required: false }] }], fileChange: [{ type: i0.Output, args: ["fileChange"] }], fileRejected: [{ type: i0.Output, args: ["fileRejected"] }] } });
|
|
12909
13353
|
|
|
12910
|
-
let nextId$
|
|
13354
|
+
let nextId$4 = 0;
|
|
12911
13355
|
/**
|
|
12912
13356
|
* Dropdown de selección múltiple con checkboxes internos. El panel flotante
|
|
12913
13357
|
* se conecta al trigger vía `@angular/cdk/overlay` — el mismo mecanismo que
|
|
@@ -12964,7 +13408,7 @@ class MultiSelect {
|
|
|
12964
13408
|
searchThreshold = input(7, /* @ts-ignore */
|
|
12965
13409
|
...(ngDevMode ? [{ debugName: "searchThreshold" }] : /* istanbul ignore next */ []));
|
|
12966
13410
|
valuesChange = output();
|
|
12967
|
-
instanceId = `kf-multi-select-${nextId$
|
|
13411
|
+
instanceId = `kf-multi-select-${nextId$4++}`;
|
|
12968
13412
|
triggerId = `${this.instanceId}-trigger`;
|
|
12969
13413
|
listboxId = `${this.instanceId}-listbox`;
|
|
12970
13414
|
isOpen = signal$1(false, /* @ts-ignore */
|
|
@@ -15934,7 +16378,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
15934
16378
|
args: [{ selector: 'kf-number-stepper', imports: [Button], changeDetection: ChangeDetectionStrategy.OnPush, template: "<kf-button\n class=\"kf-number-stepper__button\"\n variant=\"outline\"\n shape=\"circle\"\n icon=\"minus\"\n type=\"button\"\n [ariaLabel]=\"decrementLabel()\"\n [disabled]=\"disabled()\"\n [ariaDisabled]=\"atMin() && !disabled()\"\n (click)=\"change(-1)\"\n/>\n<div\n class=\"kf-number-stepper__value\"\n role=\"spinbutton\"\n [attr.tabindex]=\"disabled() ? null : 0\"\n [attr.aria-label]=\"label()\"\n [attr.aria-valuenow]=\"current()\"\n [attr.aria-valuemin]=\"min()\"\n [attr.aria-valuemax]=\"max()\"\n [attr.aria-valuetext]=\"valueText() ? text() : null\"\n [attr.aria-disabled]=\"disabled() ? 'true' : null\"\n (keydown)=\"onKeydown($event)\"\n>\n {{ text() }}\n</div>\n<kf-button\n class=\"kf-number-stepper__button\"\n variant=\"outline\"\n shape=\"circle\"\n icon=\"plus\"\n type=\"button\"\n [ariaLabel]=\"incrementLabel()\"\n [disabled]=\"disabled()\"\n [ariaDisabled]=\"atMax() && !disabled()\"\n (click)=\"change(1)\"\n/>\n<span class=\"kf-sr-only\" role=\"status\" aria-live=\"polite\" aria-atomic=\"true\">{{\n announcement()\n}}</span>\n", styles: [".kf-sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}:host{position:relative;display:inline-flex;align-items:center;gap:var(--kf-space-sm)}.kf-number-stepper__button{--kf-button-min-height: 44px;--kf-button-min-width: 44px}.kf-number-stepper__value{min-width:96px;padding:var(--kf-space-xs) var(--kf-space-sm);border-radius:var(--kf-radius-sm);font-family:var(--kf-font-body);font-size:var(--kf-font-size-title-sm);font-weight:600;font-variant-numeric:tabular-nums;text-align:center;color:var(--kf-color-ink)}.kf-number-stepper__value:focus-visible{outline:none;box-shadow:var(--kf-shadow-focus)}.kf-number-stepper__value[aria-disabled=true]{opacity:.55}\n"] }]
|
|
15935
16379
|
}], propDecorators: { label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: true }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }], min: [{ type: i0.Input, args: [{ isSignal: true, alias: "min", required: false }] }], max: [{ type: i0.Input, args: [{ isSignal: true, alias: "max", required: false }] }], step: [{ type: i0.Input, args: [{ isSignal: true, alias: "step", required: false }] }], itemLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "itemLabel", required: false }] }], valueText: [{ type: i0.Input, args: [{ isSignal: true, alias: "valueText", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], changeText: [{ type: i0.Input, args: [{ isSignal: true, alias: "changeText", required: false }] }], minText: [{ type: i0.Input, args: [{ isSignal: true, alias: "minText", required: false }] }], maxText: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxText", required: false }] }] } });
|
|
15936
16380
|
|
|
15937
|
-
let nextId$
|
|
16381
|
+
let nextId$3 = 0;
|
|
15938
16382
|
/**
|
|
15939
16383
|
* Lista vertical de opciones de UNA sola selección para paneles (ej. las
|
|
15940
16384
|
* secciones "Estado", "Ordenar por" y "Vista" de un panel de filtros): una
|
|
@@ -15986,7 +16430,7 @@ class OptionList {
|
|
|
15986
16430
|
ariaLabel = input(/* @ts-ignore */
|
|
15987
16431
|
...(ngDevMode ? [undefined, { debugName: "ariaLabel" }] : /* istanbul ignore next */ []));
|
|
15988
16432
|
valueChange = output();
|
|
15989
|
-
instanceId = `kf-option-list-${nextId$
|
|
16433
|
+
instanceId = `kf-option-list-${nextId$3++}`;
|
|
15990
16434
|
labelId = `${this.instanceId}-label`;
|
|
15991
16435
|
/**
|
|
15992
16436
|
* Prefijo de id de cada opción — único por instancia (dos listas con los
|
|
@@ -16391,7 +16835,7 @@ class PortalHeader {
|
|
|
16391
16835
|
}, /* @ts-ignore */
|
|
16392
16836
|
...(ngDevMode ? [{ debugName: "thumbStyle" }] : /* istanbul ignore next */ []));
|
|
16393
16837
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: PortalHeader, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
16394
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: PortalHeader, isStandalone: true, selector: "kf-portal-header", inputs: { tone: { classPropertyName: "tone", publicName: "tone", isSignal: true, isRequired: false, transformFunction: null }, brand: { classPropertyName: "brand", publicName: "brand", isSignal: true, isRequired: false, transformFunction: null }, logoSrc: { classPropertyName: "logoSrc", publicName: "logoSrc", isSignal: true, isRequired: false, transformFunction: null }, logoAlt: { classPropertyName: "logoAlt", publicName: "logoAlt", isSignal: true, isRequired: false, transformFunction: null }, isAdmin: { classPropertyName: "isAdmin", publicName: "isAdmin", isSignal: true, isRequired: false, transformFunction: null }, adminActions: { classPropertyName: "adminActions", publicName: "adminActions", isSignal: true, isRequired: false, transformFunction: null }, navItems: { classPropertyName: "navItems", publicName: "navItems", isSignal: true, isRequired: false, transformFunction: null }, userInitials: { classPropertyName: "userInitials", publicName: "userInitials", isSignal: true, isRequired: true, transformFunction: null }, tagline: { classPropertyName: "tagline", publicName: "tagline", isSignal: true, isRequired: false, transformFunction: null }, userName: { classPropertyName: "userName", publicName: "userName", isSignal: true, isRequired: false, transformFunction: null }, showCart: { classPropertyName: "showCart", publicName: "showCart", isSignal: true, isRequired: false, transformFunction: null }, cartCount: { classPropertyName: "cartCount", publicName: "cartCount", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { sessionClick: "sessionClick", cartClick: "cartClick" }, host: { listeners: { "window:resize": "onWindowResize()" }, properties: { "attr.data-tone": "tone()" } }, viewQueries: [{ propertyName: "sessionButtonRef", first: true, predicate: ["sessionButton"], descendants: true, read: ElementRef, isSignal: true }, { propertyName: "navItemAnchors", predicate: ["navItemAnchor"], descendants: true, isSignal: true }], ngImport: i0, template: "@if (isAdmin()) {\n <div class=\"kf-portal-header__admin-bar\">\n <div class=\"kf-portal-header__admin-inner\">\n <kf-admin-badge inline />\n <div class=\"kf-portal-header__admin-actions\">\n @for (action of adminActions(); track action.label) {\n <a class=\"kf-portal-header__admin-action\" [href]=\"action.href\">{{ action.label }}</a>\n }\n </div>\n </div>\n </div>\n}\n<div class=\"kf-portal-header__brand-bar\">\n <div class=\"kf-portal-header__brand-inner\">\n <div class=\"kf-portal-header__top-row\">\n <div class=\"kf-portal-header__logo-group\">\n @if (logoSrc()) {\n <img class=\"kf-portal-header__logo-img\" [src]=\"logoSrc()\" [alt]=\"logoAlt() || brand()\" />\n } @else {\n <span class=\"kf-portal-header__logo\">{{ brand() }}</span>\n }\n @if (tagline()) {\n <span class=\"kf-portal-header__logo-sep\" aria-hidden=\"true\"></span>\n <span class=\"kf-portal-header__logo-tag\">{{ tagline() }}</span>\n }\n </div>\n\n <div class=\"kf-portal-header__actions\">\n @if (showCart()) {\n <button\n type=\"button\"\n class=\"kf-portal-header__cart\"\n [attr.aria-label]=\"cartAriaLabel()\"\n (click)=\"cartClick.emit()\"\n >\n <kf-icon name=\"cart\" size=\"md\" />\n @if (cartCount() > 0) {\n <span class=\"kf-portal-header__cart-count\" aria-hidden=\"true\">{{\n cartCountLabel()\n }}</span>\n }\n </button>\n }\n\n <button\n #sessionButton\n type=\"button\"\n class=\"kf-portal-header__session\"\n [class.kf-portal-header__session--expanded]=\"userName()\"\n (click)=\"sessionClick.emit()\"\n >\n @if (userName()) {\n <kf-avatar [initials]=\"userInitials()\" />\n <span class=\"kf-portal-header__session-who\">\n <span class=\"kf-portal-header__session-greeting\">Hola</span>\n <span class=\"kf-portal-header__session-name\">{{ userName() }}</span>\n </span>\n <kf-icon name=\"chevron-down\" size=\"sm\" class=\"kf-portal-header__session-chevron\" />\n } @else {\n <kf-avatar [initials]=\"userInitials()\" pill />\n }\n </button>\n\n <button\n type=\"button\"\n class=\"kf-portal-header__menu-toggle\"\n [attr.aria-expanded]=\"mobileMenuOpen()\"\n aria-label=\"Abrir men\u00FA de navegaci\u00F3n\"\n (click)=\"mobileMenuOpen.set(!mobileMenuOpen())\"\n >\n <kf-icon [name]=\"mobileMenuOpen() ? 'x' : 'menu'\" size=\"md\" />\n </button>\n </div>\n </div>\n\n <nav class=\"kf-portal-header__nav\">\n <span class=\"kf-portal-header__nav-thumb\" [style]=\"thumbStyle()\" aria-hidden=\"true\"></span>\n @for (item of navItems(); track item.label) {\n <a\n #navItemAnchor\n class=\"kf-portal-header__nav-item\"\n [class.kf-portal-header__nav-item--active]=\"item.active\"\n [href]=\"item.href\"\n >\n {{ item.label }}\n </a>\n }\n </nav>\n </div>\n</div>\n\n<kf-drawer [(open)]=\"mobileMenuOpen\" ariaLabel=\"Men\u00FA de navegaci\u00F3n\">\n <div kf-drawer-header>\n <ng-content select=\"[kf-portal-header-extra]\" />\n </div>\n @for (item of navItems(); track item.label) {\n <a\n class=\"kf-portal-header__mobile-nav-item\"\n [class.kf-portal-header__mobile-nav-item--active]=\"item.active\"\n [href]=\"item.href\"\n (click)=\"mobileMenuOpen.set(false)\"\n >\n @if (item.icon) {\n <kf-icon [name]=\"item.icon\" size=\"sm\" />\n }\n <span class=\"kf-portal-header__mobile-nav-item-label\">{{ item.label }}</span>\n <kf-icon name=\"chevron-right\" size=\"sm\" />\n </a>\n }\n <div kf-drawer-footer>\n <ng-content select=\"[kf-portal-header-footer]\" />\n </div>\n</kf-drawer>\n", styles: [":host{display:block;position:sticky;top:0;z-index:30;font-family:var(--kf-font-body)}.kf-portal-header__admin-bar{padding-block:var(--kf-space-xs);background:var(--kf-header-bg)}.kf-portal-header__admin-inner{display:flex;align-items:center;justify-content:space-between;gap:var(--kf-space-md);max-width:var(--kf-header-max-width, none);margin:0 auto;padding:0 var(--kf-space-lg)}.kf-portal-header__admin-actions{display:flex;gap:var(--kf-space-md)}.kf-portal-header__admin-action{font-size:var(--kf-font-size-label);font-weight:600;color:color-mix(in srgb,var(--kf-header-fg) 85%,transparent);text-decoration:none}.kf-portal-header__admin-action:hover{color:var(--kf-header-fg)}.kf-portal-header__brand-bar{background:var(--kf-header-bg);border-top:1px solid color-mix(in srgb,var(--kf-header-fg) 10%,transparent)}.kf-portal-header__brand-inner{display:flex;flex-direction:column;max-width:var(--kf-header-max-width, none);margin:0 auto;padding:0 var(--kf-space-lg)}.kf-portal-header__top-row{display:flex;align-items:center;gap:var(--kf-space-lg);min-height:60px;padding-block:var(--kf-space-sm) 4px}.kf-portal-header__logo-group{display:flex;align-items:center;gap:var(--kf-space-md);flex:1 1 auto;min-width:0}.kf-portal-header__logo{font-family:var(--kf-font-title);font-size:1.25rem;font-weight:700;letter-spacing:.02em;color:var(--kf-header-fg);text-transform:uppercase}.kf-portal-header__logo-img{height:28px;width:auto;display:block}.kf-portal-header__logo-sep{flex:none;width:1px;height:30px;background:color-mix(in srgb,var(--kf-header-fg) 20%,transparent)}.kf-portal-header__logo-tag{font-family:var(--kf-font-title);font-weight:400;font-size:1.1875rem;color:color-mix(in srgb,var(--kf-header-fg) 78%,transparent)}.kf-portal-header__actions{margin-left:auto;display:flex;align-items:center;gap:var(--kf-space-sm)}.kf-portal-header__cart{position:relative;flex:none;width:46px;height:46px;border-radius:var(--kf-radius-pill);border:1px solid color-mix(in srgb,var(--kf-header-fg) 18%,transparent);background:transparent;color:var(--kf-header-fg);display:grid;place-items:center;cursor:pointer}.kf-portal-header__cart-count{position:absolute;top:-4px;right:-4px;min-width:20px;height:20px;padding:0 5px;box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;border:2px solid var(--kf-header-bg);border-radius:var(--kf-radius-pill);background:var(--kf-color-primary);color:var(--kf-color-white);font-size:.6875rem;font-weight:700;line-height:1;pointer-events:none}.kf-portal-header__cart:hover{background:color-mix(in srgb,var(--kf-header-fg) 10%,transparent);border-color:color-mix(in srgb,var(--kf-header-fg) 30%,transparent)}.kf-portal-header__nav{display:flex;align-items:center;gap:2px;padding:4px;margin-bottom:var(--kf-space-sm);background:color-mix(in srgb,var(--kf-header-fg) 8%,transparent);border-radius:var(--kf-radius-pill);width:fit-content;max-width:100%;position:relative}.kf-portal-header__nav-thumb{position:absolute;top:4px;bottom:4px;left:0;background:var(--kf-header-fg);border-radius:var(--kf-radius-pill);transition:transform var(--kf-motion-base, .25s) var(--kf-ease-standard, ease),width var(--kf-motion-base, .25s) var(--kf-ease-standard, ease),opacity var(--kf-motion-fast, .15s) linear;pointer-events:none}@media(prefers-reduced-motion:reduce){.kf-portal-header__nav-thumb{transition:none}}.kf-portal-header__nav-item{position:relative;padding:var(--kf-space-sm) var(--kf-space-md);border-radius:var(--kf-radius-pill);color:color-mix(in srgb,var(--kf-header-fg) 75%,transparent);font-size:.875rem;font-weight:600;text-decoration:none;white-space:nowrap;transition:background var(--kf-motion-fast, .14s),color var(--kf-motion-fast, .14s)}.kf-portal-header__nav-item:hover:not(.kf-portal-header__nav-item--active){color:var(--kf-header-fg);background:color-mix(in srgb,var(--kf-header-fg) 8%,transparent)}.kf-portal-header__nav-item--active{color:var(--kf-color-ink)}:host([data-tone=\"light\"]) .kf-portal-header__nav-item--active{color:var(--kf-header-bg)}.kf-portal-header__session{flex:none;border:none;background:transparent;padding:0;cursor:pointer}.kf-portal-header__session--expanded{display:flex;align-items:center;gap:var(--kf-space-sm);padding:7px 12px 7px 8px;background:var(--kf-color-primary);border-radius:var(--kf-radius-pill)}.kf-portal-header__session--expanded:hover{background:var(--kf-color-primary-active)}.kf-portal-header__session-who{display:flex;flex-direction:column;line-height:1.2;color:var(--kf-color-white)}.kf-portal-header__session-greeting{font-size:.65625rem;font-weight:600;letter-spacing:.06em;text-transform:uppercase;color:color-mix(in srgb,var(--kf-color-white) 70%,transparent)}.kf-portal-header__session-name{font-size:.875rem;font-weight:700;max-width:150px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.kf-portal-header__session-chevron{color:color-mix(in srgb,var(--kf-color-white) 85%,transparent)}.kf-portal-header__menu-toggle{display:none;flex:none;align-items:center;justify-content:center;width:36px;height:36px;border:none;border-radius:var(--kf-radius-sm);background:transparent;color:var(--kf-header-fg);cursor:pointer}.kf-portal-header__menu-toggle:hover{background:color-mix(in srgb,var(--kf-header-fg) 10%,transparent)}.kf-portal-header__mobile-nav-item{display:flex;align-items:center;gap:var(--kf-space-sm);padding:var(--kf-space-sm) var(--kf-space-xs);color:var(--kf-color-text);font-size:.9375rem;font-weight:600;text-decoration:none;border-radius:var(--kf-radius-sm)}.kf-portal-header__mobile-nav-item:hover{background:var(--kf-color-surface)}.kf-portal-header__mobile-nav-item--active{color:var(--kf-color-primary-active);background:var(--kf-color-primary-soft)}.kf-portal-header__mobile-nav-item-label{flex:1 1 auto}.kf-portal-header__mobile-nav-item kf-icon:last-child{color:color-mix(in srgb,var(--kf-color-ink) 35%,transparent)}@media(max-width:768px){.kf-portal-header__nav,.kf-portal-header__session{display:none}.kf-portal-header__menu-toggle{display:inline-flex}}\n"], dependencies: [{ kind: "component", type: AdminBadge, selector: "kf-admin-badge", inputs: ["inline"] }, { kind: "component", type: Avatar, selector: "kf-avatar", inputs: ["initials", "src", "round", "size", "pill"] }, { kind: "component", type: Icon, selector: "kf-icon", inputs: ["name", "size", "rotate", "filled"] }, { kind: "component", type: Drawer, selector: "kf-drawer", inputs: ["open", "side", "role", "ariaLabel", "title", "closeLabel", "size", "sheetSize", "expandable", "sheetWidth", "flush", "swipeToClose", "closeOnBack", "mountInOverlay"], outputs: ["openChange", "closedAfterBack", "detentChange"] }] });
|
|
16838
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: PortalHeader, isStandalone: true, selector: "kf-portal-header", inputs: { tone: { classPropertyName: "tone", publicName: "tone", isSignal: true, isRequired: false, transformFunction: null }, brand: { classPropertyName: "brand", publicName: "brand", isSignal: true, isRequired: false, transformFunction: null }, logoSrc: { classPropertyName: "logoSrc", publicName: "logoSrc", isSignal: true, isRequired: false, transformFunction: null }, logoAlt: { classPropertyName: "logoAlt", publicName: "logoAlt", isSignal: true, isRequired: false, transformFunction: null }, isAdmin: { classPropertyName: "isAdmin", publicName: "isAdmin", isSignal: true, isRequired: false, transformFunction: null }, adminActions: { classPropertyName: "adminActions", publicName: "adminActions", isSignal: true, isRequired: false, transformFunction: null }, navItems: { classPropertyName: "navItems", publicName: "navItems", isSignal: true, isRequired: false, transformFunction: null }, userInitials: { classPropertyName: "userInitials", publicName: "userInitials", isSignal: true, isRequired: true, transformFunction: null }, tagline: { classPropertyName: "tagline", publicName: "tagline", isSignal: true, isRequired: false, transformFunction: null }, userName: { classPropertyName: "userName", publicName: "userName", isSignal: true, isRequired: false, transformFunction: null }, showCart: { classPropertyName: "showCart", publicName: "showCart", isSignal: true, isRequired: false, transformFunction: null }, cartCount: { classPropertyName: "cartCount", publicName: "cartCount", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { sessionClick: "sessionClick", cartClick: "cartClick" }, host: { listeners: { "window:resize": "onWindowResize()" }, properties: { "attr.data-tone": "tone()" } }, viewQueries: [{ propertyName: "sessionButtonRef", first: true, predicate: ["sessionButton"], descendants: true, read: ElementRef, isSignal: true }, { propertyName: "navItemAnchors", predicate: ["navItemAnchor"], descendants: true, isSignal: true }], ngImport: i0, template: "@if (isAdmin()) {\n <div class=\"kf-portal-header__admin-bar\">\n <div class=\"kf-portal-header__admin-inner\">\n <kf-admin-badge inline />\n <div class=\"kf-portal-header__admin-actions\">\n @for (action of adminActions(); track action.label) {\n <a class=\"kf-portal-header__admin-action\" [href]=\"action.href\">{{ action.label }}</a>\n }\n </div>\n </div>\n </div>\n}\n<div class=\"kf-portal-header__brand-bar\">\n <div class=\"kf-portal-header__brand-inner\">\n <div class=\"kf-portal-header__top-row\">\n <div class=\"kf-portal-header__logo-group\">\n @if (logoSrc()) {\n <img class=\"kf-portal-header__logo-img\" [src]=\"logoSrc()\" [alt]=\"logoAlt() || brand()\" />\n } @else {\n <span class=\"kf-portal-header__logo\">{{ brand() }}</span>\n }\n @if (tagline()) {\n <span class=\"kf-portal-header__logo-sep\" aria-hidden=\"true\"></span>\n <span class=\"kf-portal-header__logo-tag\">{{ tagline() }}</span>\n }\n </div>\n\n <div class=\"kf-portal-header__actions\">\n @if (showCart()) {\n <button\n type=\"button\"\n class=\"kf-portal-header__cart\"\n [attr.aria-label]=\"cartAriaLabel()\"\n (click)=\"cartClick.emit()\"\n >\n <kf-icon name=\"cart\" size=\"md\" />\n @if (cartCount() > 0) {\n <span class=\"kf-portal-header__cart-count\" aria-hidden=\"true\">{{\n cartCountLabel()\n }}</span>\n }\n </button>\n }\n\n <button\n #sessionButton\n type=\"button\"\n class=\"kf-portal-header__session\"\n [class.kf-portal-header__session--expanded]=\"userName()\"\n (click)=\"sessionClick.emit()\"\n >\n @if (userName()) {\n <kf-avatar [initials]=\"userInitials()\" />\n <span class=\"kf-portal-header__session-who\">\n <span class=\"kf-portal-header__session-greeting\">Hola</span>\n <span class=\"kf-portal-header__session-name\">{{ userName() }}</span>\n </span>\n <kf-icon name=\"chevron-down\" size=\"sm\" class=\"kf-portal-header__session-chevron\" />\n } @else {\n <kf-avatar [initials]=\"userInitials()\" pill />\n }\n </button>\n\n <button\n type=\"button\"\n class=\"kf-portal-header__menu-toggle\"\n [attr.aria-expanded]=\"mobileMenuOpen()\"\n aria-label=\"Abrir men\u00FA de navegaci\u00F3n\"\n (click)=\"mobileMenuOpen.set(!mobileMenuOpen())\"\n >\n <kf-icon [name]=\"mobileMenuOpen() ? 'x' : 'menu'\" size=\"md\" />\n </button>\n </div>\n </div>\n\n <nav class=\"kf-portal-header__nav\">\n <span class=\"kf-portal-header__nav-thumb\" [style]=\"thumbStyle()\" aria-hidden=\"true\"></span>\n @for (item of navItems(); track item.label) {\n <a\n #navItemAnchor\n class=\"kf-portal-header__nav-item\"\n [class.kf-portal-header__nav-item--active]=\"item.active\"\n [href]=\"item.href\"\n >\n {{ item.label }}\n </a>\n }\n </nav>\n </div>\n</div>\n\n<kf-drawer [(open)]=\"mobileMenuOpen\" ariaLabel=\"Men\u00FA de navegaci\u00F3n\">\n <div kf-drawer-header>\n <ng-content select=\"[kf-portal-header-extra]\" />\n </div>\n @for (item of navItems(); track item.label) {\n <a\n class=\"kf-portal-header__mobile-nav-item\"\n [class.kf-portal-header__mobile-nav-item--active]=\"item.active\"\n [href]=\"item.href\"\n (click)=\"mobileMenuOpen.set(false)\"\n >\n @if (item.icon) {\n <kf-icon [name]=\"item.icon\" size=\"sm\" />\n }\n <span class=\"kf-portal-header__mobile-nav-item-label\">{{ item.label }}</span>\n <kf-icon name=\"chevron-right\" size=\"sm\" />\n </a>\n }\n <div kf-drawer-footer>\n <ng-content select=\"[kf-portal-header-footer]\" />\n </div>\n</kf-drawer>\n", styles: [":host{display:block;position:sticky;top:0;z-index:30;font-family:var(--kf-font-body)}.kf-portal-header__admin-bar{padding-block:var(--kf-space-xs);background:var(--kf-header-bg)}.kf-portal-header__admin-inner{display:flex;align-items:center;justify-content:space-between;gap:var(--kf-space-md);max-width:var(--kf-header-max-width, none);margin:0 auto;padding:0 var(--kf-space-lg)}.kf-portal-header__admin-actions{display:flex;gap:var(--kf-space-md)}.kf-portal-header__admin-action{font-size:var(--kf-font-size-label);font-weight:600;color:color-mix(in srgb,var(--kf-header-fg) 85%,transparent);text-decoration:none}.kf-portal-header__admin-action:hover{color:var(--kf-header-fg)}.kf-portal-header__brand-bar{background:var(--kf-header-bg);border-top:1px solid color-mix(in srgb,var(--kf-header-fg) 10%,transparent)}.kf-portal-header__brand-inner{display:flex;flex-direction:column;max-width:var(--kf-header-max-width, none);margin:0 auto;padding:0 var(--kf-space-lg)}.kf-portal-header__top-row{display:flex;align-items:center;gap:var(--kf-space-lg);min-height:60px;padding-block:var(--kf-space-sm) 4px}.kf-portal-header__logo-group{display:flex;align-items:center;gap:var(--kf-space-md);flex:1 1 auto;min-width:0}.kf-portal-header__logo{font-family:var(--kf-font-title);font-size:1.25rem;font-weight:700;letter-spacing:.02em;color:var(--kf-header-fg);text-transform:uppercase}.kf-portal-header__logo-img{height:28px;width:auto;display:block}.kf-portal-header__logo-sep{flex:none;width:1px;height:30px;background:color-mix(in srgb,var(--kf-header-fg) 20%,transparent)}.kf-portal-header__logo-tag{font-family:var(--kf-font-title);font-weight:400;font-size:1.1875rem;color:color-mix(in srgb,var(--kf-header-fg) 78%,transparent)}.kf-portal-header__actions{margin-left:auto;display:flex;align-items:center;gap:var(--kf-space-sm)}.kf-portal-header__cart{position:relative;flex:none;width:46px;height:46px;border-radius:var(--kf-radius-pill);border:1px solid color-mix(in srgb,var(--kf-header-fg) 18%,transparent);background:transparent;color:var(--kf-header-fg);display:grid;place-items:center;cursor:pointer}.kf-portal-header__cart-count{position:absolute;top:-4px;right:-4px;min-width:20px;height:20px;padding:0 5px;box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;border:2px solid var(--kf-header-bg);border-radius:var(--kf-radius-pill);background:var(--kf-color-primary);color:var(--kf-color-white);font-size:.6875rem;font-weight:700;line-height:1;pointer-events:none}.kf-portal-header__cart:hover{background:color-mix(in srgb,var(--kf-header-fg) 10%,transparent);border-color:color-mix(in srgb,var(--kf-header-fg) 30%,transparent)}.kf-portal-header__nav{display:flex;align-items:center;gap:2px;padding:4px;margin-bottom:var(--kf-space-sm);background:color-mix(in srgb,var(--kf-header-fg) 8%,transparent);border-radius:var(--kf-radius-pill);width:fit-content;max-width:100%;position:relative}.kf-portal-header__nav-thumb{position:absolute;top:4px;bottom:4px;left:0;background:var(--kf-header-fg);border-radius:var(--kf-radius-pill);transition:transform var(--kf-motion-base, .25s) var(--kf-ease-standard, ease),width var(--kf-motion-base, .25s) var(--kf-ease-standard, ease),opacity var(--kf-motion-fast, .15s) linear;pointer-events:none}@media(prefers-reduced-motion:reduce){.kf-portal-header__nav-thumb{transition:none}}.kf-portal-header__nav-item{position:relative;padding:var(--kf-space-sm) var(--kf-space-md);border-radius:var(--kf-radius-pill);color:color-mix(in srgb,var(--kf-header-fg) 75%,transparent);font-size:.875rem;font-weight:600;text-decoration:none;white-space:nowrap;transition:background var(--kf-motion-fast, .14s),color var(--kf-motion-fast, .14s)}.kf-portal-header__nav-item:hover:not(.kf-portal-header__nav-item--active){color:var(--kf-header-fg);background:color-mix(in srgb,var(--kf-header-fg) 8%,transparent)}.kf-portal-header__nav-item--active{color:var(--kf-color-ink)}:host([data-tone=\"light\"]) .kf-portal-header__nav-item--active{color:var(--kf-header-bg)}.kf-portal-header__session{flex:none;border:none;background:transparent;padding:0;cursor:pointer}.kf-portal-header__session--expanded{display:flex;align-items:center;gap:var(--kf-space-sm);padding:7px 12px 7px 8px;background:var(--kf-color-primary);border-radius:var(--kf-radius-pill)}.kf-portal-header__session--expanded:hover{background:var(--kf-color-primary-active)}.kf-portal-header__session-who{display:flex;flex-direction:column;line-height:1.2;color:var(--kf-color-white)}.kf-portal-header__session-greeting{font-size:.65625rem;font-weight:600;letter-spacing:.06em;text-transform:uppercase;color:color-mix(in srgb,var(--kf-color-white) 70%,transparent)}.kf-portal-header__session-name{font-size:.875rem;font-weight:700;max-width:150px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.kf-portal-header__session-chevron{color:color-mix(in srgb,var(--kf-color-white) 85%,transparent)}.kf-portal-header__menu-toggle{display:none;flex:none;align-items:center;justify-content:center;width:36px;height:36px;border:none;border-radius:var(--kf-radius-sm);background:transparent;color:var(--kf-header-fg);cursor:pointer}.kf-portal-header__menu-toggle:hover{background:color-mix(in srgb,var(--kf-header-fg) 10%,transparent)}.kf-portal-header__mobile-nav-item{display:flex;align-items:center;gap:var(--kf-space-sm);padding:var(--kf-space-sm) var(--kf-space-xs);color:var(--kf-color-text);font-size:.9375rem;font-weight:600;text-decoration:none;border-radius:var(--kf-radius-sm)}.kf-portal-header__mobile-nav-item:hover{background:var(--kf-color-surface)}.kf-portal-header__mobile-nav-item--active{color:var(--kf-color-primary-active);background:var(--kf-color-primary-soft)}.kf-portal-header__mobile-nav-item-label{flex:1 1 auto}.kf-portal-header__mobile-nav-item kf-icon:last-child{color:color-mix(in srgb,var(--kf-color-ink) 35%,transparent)}@media(max-width:768px){.kf-portal-header__nav,.kf-portal-header__session{display:none}.kf-portal-header__menu-toggle{display:inline-flex}}\n"], dependencies: [{ kind: "component", type: AdminBadge, selector: "kf-admin-badge", inputs: ["inline"] }, { kind: "component", type: Avatar, selector: "kf-avatar", inputs: ["initials", "src", "round", "size", "pill"] }, { kind: "component", type: Icon, selector: "kf-icon", inputs: ["name", "size", "rotate", "filled"] }, { kind: "component", type: Drawer, selector: "kf-drawer", inputs: ["open", "side", "role", "ariaLabel", "title", "closeLabel", "size", "sheetSize", "expandable", "sheetWidth", "flush", "swipeToClose", "closeOnBack", "mountInOverlay", "closeGuard"], outputs: ["openChange", "closedAfterBack", "detentChange"] }] });
|
|
16395
16839
|
}
|
|
16396
16840
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: PortalHeader, decorators: [{
|
|
16397
16841
|
type: Component,
|
|
@@ -16401,7 +16845,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
16401
16845
|
args: ['window:resize']
|
|
16402
16846
|
}] } });
|
|
16403
16847
|
|
|
16404
|
-
let nextId$
|
|
16848
|
+
let nextId$2 = 0;
|
|
16405
16849
|
/**
|
|
16406
16850
|
* Avance compacto de un recorrido de pasos: «Paso N de M · etapa», una acción
|
|
16407
16851
|
* opcional («Ver recorrido») y una barra que se llena con transición también la
|
|
@@ -16459,7 +16903,7 @@ class ProgressStrip {
|
|
|
16459
16903
|
progressLabel = input('Avance del recorrido', /* @ts-ignore */
|
|
16460
16904
|
...(ngDevMode ? [{ debugName: "progressLabel" }] : /* istanbul ignore next */ []));
|
|
16461
16905
|
activate = output();
|
|
16462
|
-
descriptionId = `kf-progress-strip-desc-${nextId$
|
|
16906
|
+
descriptionId = `kf-progress-strip-desc-${nextId$2++}`;
|
|
16463
16907
|
known = computed(() => this.position() > 0 && this.total() > 0, /* @ts-ignore */
|
|
16464
16908
|
...(ngDevMode ? [{ debugName: "known" }] : /* istanbul ignore next */ []));
|
|
16465
16909
|
clampedPosition = computed(() => Math.min(this.position(), this.total()), /* @ts-ignore */
|
|
@@ -16489,7 +16933,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
16489
16933
|
args: [{ selector: 'kf-progress-strip', imports: [Icon], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div\n class=\"kf-progress-strip\"\n [class.kf-progress-strip--slim]=\"variant() === 'slim'\"\n [class.kf-progress-strip--interactive]=\"interactive()\"\n [style.--kf-progress-strip-fill]=\"color()\"\n>\n @if (interactive()) {\n <button\n type=\"button\"\n class=\"kf-progress-strip__head kf-progress-strip__hit\"\n [attr.aria-describedby]=\"descriptionId\"\n (click)=\"activate.emit()\"\n >\n <span class=\"kf-progress-strip__caption\">{{ caption() }}</span>\n <span class=\"kf-progress-strip__action\">\n {{ actionLabel() }}\n <kf-icon name=\"chevron-right\" size=\"sm\" />\n </span>\n </button>\n } @else {\n <div class=\"kf-progress-strip__head\">\n <span class=\"kf-progress-strip__caption\">{{ caption() }}</span>\n </div>\n }\n\n @if (known()) {\n <div\n class=\"kf-progress-strip__track\"\n role=\"progressbar\"\n aria-valuemin=\"0\"\n [attr.aria-valuemax]=\"total()\"\n [attr.aria-valuenow]=\"clampedPosition()\"\n [attr.aria-valuetext]=\"valueText()\"\n [attr.aria-label]=\"progressLabel()\"\n >\n <span class=\"kf-progress-strip__fill\" [style.transform]=\"'scaleX(' + ratio() + ')'\"></span>\n </div>\n }\n\n @if (variant() === 'full') {\n <div class=\"kf-progress-strip__steps\" [attr.aria-hidden]=\"interactive() ? 'true' : null\">\n <span class=\"kf-progress-strip__current\">\n <span class=\"kf-progress-strip__dot\"></span>\n <span class=\"kf-progress-strip__current-label\">{{ current() }}</span>\n </span>\n @if (previous() || next()) {\n <span class=\"kf-progress-strip__neighbors\">\n @if (previous(); as text) {\n <span class=\"kf-progress-strip__neighbor\">\n <span class=\"kf-progress-strip__neighbor-label\">{{ previousLabel() }}:</span>\n {{ text }}\n </span>\n }\n @if (next(); as text) {\n <span class=\"kf-progress-strip__neighbor\">\n <span class=\"kf-progress-strip__neighbor-label\">{{ nextLabel() }}:</span>\n {{ text }}\n </span>\n }\n </span>\n }\n </div>\n }\n @if (interactive()) {\n <span class=\"kf-progress-strip__sr\" [id]=\"descriptionId\">{{ description() }}</span>\n }\n</div>\n", styles: [":host{display:block}.kf-progress-strip{position:relative;display:flex;flex-direction:column;gap:var(--kf-space-sm);padding-block:var(--kf-space-sm);color:var(--kf-color-ink);font-family:var(--kf-font-body);transition:transform var(--kf-motion-fast) var(--kf-ease-standard),opacity var(--kf-motion-fast) var(--kf-ease-standard)}.kf-progress-strip--interactive:has(.kf-progress-strip__hit:active){transform:scale(var(--kf-press-scale));opacity:var(--kf-press-opacity)}.kf-progress-strip__head{display:flex;align-items:baseline;justify-content:space-between;gap:var(--kf-space-sm);min-width:0}.kf-progress-strip__hit{width:100%;min-height:var(--kf-control-min-height, auto);padding:0;border:none;background:transparent;color:inherit;font:inherit;text-align:start;cursor:pointer;-webkit-tap-highlight-color:transparent}.kf-progress-strip__hit:after{content:\"\";position:absolute;inset:0;border-radius:var(--kf-radius-sm)}.kf-progress-strip__hit:focus-visible{outline:none}.kf-progress-strip__hit:focus-visible:after{box-shadow:var(--kf-shadow-focus)}.kf-progress-strip__caption{min-width:0;font-size:var(--kf-font-size-caption);font-weight:var(--kf-font-weight-medium);line-height:1.3;letter-spacing:.04em;text-transform:uppercase;overflow-wrap:anywhere;color:var(--kf-color-text-muted);font-variant-numeric:tabular-nums}.kf-progress-strip__action{display:inline-flex;flex:none;align-items:center;gap:2px;font-size:var(--kf-font-size-body-sm);font-weight:var(--kf-font-weight-medium);color:var(--kf-color-primary)}.kf-progress-strip__track{height:4px;overflow:hidden;border-radius:var(--kf-radius-pill);background:var(--kf-color-gray-200)}.kf-progress-strip__fill{display:block;height:100%;background:var(--kf-progress-strip-fill, var(--kf-color-primary));transform-origin:left center;transition:transform var(--kf-motion-slow) var(--kf-ease-standard)}@starting-style{.kf-progress-strip__fill{transform:scaleX(0)!important}}.kf-progress-strip__steps{display:flex;flex-direction:column;gap:2px;min-width:0}.kf-progress-strip__current{display:flex;align-items:center;gap:var(--kf-space-sm);min-width:0;font-size:var(--kf-font-size-body);font-weight:var(--kf-font-weight-medium);line-height:1.35}.kf-progress-strip__dot{flex:none;width:10px;height:10px;border-radius:var(--kf-radius-pill);background:var(--kf-progress-strip-fill, var(--kf-color-primary))}.kf-progress-strip__current-label{min-width:0;overflow-wrap:anywhere}.kf-progress-strip__neighbors{display:flex;flex-wrap:wrap;column-gap:var(--kf-space-md);row-gap:2px;padding-inline-start:calc(10px + var(--kf-space-sm));font-size:var(--kf-font-size-body-sm);line-height:1.4;color:var(--kf-color-text)}.kf-progress-strip__neighbor{min-width:0;overflow-wrap:anywhere}.kf-progress-strip__neighbor-label{color:var(--kf-color-text-muted)}.kf-progress-strip__sr{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}\n"] }]
|
|
16490
16934
|
}], propDecorators: { current: [{ type: i0.Input, args: [{ isSignal: true, alias: "current", required: true }] }], previous: [{ type: i0.Input, args: [{ isSignal: true, alias: "previous", required: false }] }], next: [{ type: i0.Input, args: [{ isSignal: true, alias: "next", required: false }] }], position: [{ type: i0.Input, args: [{ isSignal: true, alias: "position", required: false }] }], total: [{ type: i0.Input, args: [{ isSignal: true, alias: "total", required: false }] }], phase: [{ type: i0.Input, args: [{ isSignal: true, alias: "phase", required: false }] }], color: [{ type: i0.Input, args: [{ isSignal: true, alias: "color", required: false }] }], variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], interactive: [{ type: i0.Input, args: [{ isSignal: true, alias: "interactive", required: false }] }], actionLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "actionLabel", required: false }] }], previousLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "previousLabel", required: false }] }], nextLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "nextLabel", required: false }] }], fallbackCaption: [{ type: i0.Input, args: [{ isSignal: true, alias: "fallbackCaption", required: false }] }], progressLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "progressLabel", required: false }] }], activate: [{ type: i0.Output, args: ["activate"] }] } });
|
|
16491
16935
|
|
|
16492
|
-
let nextId = 0;
|
|
16936
|
+
let nextId$1 = 0;
|
|
16493
16937
|
/**
|
|
16494
16938
|
* Grupo de filas (`kf-action-row` u otras) con un rótulo opcional en
|
|
16495
16939
|
* mayúsculas y bordes finos arriba y abajo. Reemplaza tarjetas dentro de
|
|
@@ -16511,7 +16955,7 @@ class ListGroup {
|
|
|
16511
16955
|
headingLevel = input(3, /* @ts-ignore */
|
|
16512
16956
|
...(ngDevMode ? [{ debugName: "headingLevel" }] : /* istanbul ignore next */ []));
|
|
16513
16957
|
bordered = input(true, { ...(ngDevMode ? { debugName: "bordered" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
16514
|
-
headingId = `kf-list-group-heading-${nextId++}`;
|
|
16958
|
+
headingId = `kf-list-group-heading-${nextId$1++}`;
|
|
16515
16959
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: ListGroup, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
16516
16960
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: ListGroup, isStandalone: true, selector: "kf-list-group", inputs: { heading: { classPropertyName: "heading", publicName: "heading", isSignal: true, isRequired: false, transformFunction: null }, headingLevel: { classPropertyName: "headingLevel", publicName: "headingLevel", isSignal: true, isRequired: false, transformFunction: null }, bordered: { classPropertyName: "bordered", publicName: "bordered", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "@if (heading(); as text) {\n <div\n class=\"kf-list-group__heading\"\n role=\"heading\"\n [attr.aria-level]=\"headingLevel()\"\n [id]=\"headingId\"\n >\n {{ text }}\n </div>\n}\n<div\n class=\"kf-list-group__body\"\n [class.kf-list-group__body--bordered]=\"bordered()\"\n [attr.role]=\"heading() ? 'group' : null\"\n [attr.aria-labelledby]=\"heading() ? headingId : null\"\n>\n <ng-content />\n</div>\n", styles: [":host{display:flex;flex-direction:column}.kf-list-group__heading{padding:var(--kf-space-md) var(--kf-space-md) var(--kf-space-xs);font-family:var(--kf-font-body);font-size:var(--kf-font-size-caption);font-weight:var(--kf-font-weight-medium);line-height:1.3;letter-spacing:.04em;text-transform:uppercase;color:var(--kf-color-text-muted)}.kf-list-group__body{display:flex;flex-direction:column;background:var(--kf-list-group-bg, var(--kf-color-white))}.kf-list-group__body--bordered{border-block:1px solid var(--kf-color-border)}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
16517
16961
|
}
|
|
@@ -17233,6 +17677,44 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
17233
17677
|
}, template: "<kf-button\n class=\"kf-scroll-top__button\"\n variant=\"surface\"\n shape=\"circle\"\n icon=\"arrow-up\"\n kfTooltipPosition=\"left\"\n [kfTooltip]=\"label()\"\n [ariaLabel]=\"label()\"\n (click)=\"goTop()\"\n/>\n", styles: [":host{position:sticky;bottom:0;z-index:2;display:block;height:0;pointer-events:none}.kf-scroll-top__button{--kf-button-min-height: 44px;--kf-button-min-width: 44px;position:absolute;inset-inline-end:var(--kf-space-md);bottom:calc(var(--kf-space-md) + env(safe-area-inset-bottom,0px));visibility:hidden;opacity:0;transition:opacity var(--kf-motion-fast, .16s) var(--kf-ease-standard, ease),visibility var(--kf-motion-fast, .16s)}:host(.kf-scroll-top--visible) .kf-scroll-top__button{visibility:visible;opacity:1;pointer-events:auto}@media(prefers-reduced-motion:reduce){.kf-scroll-top__button{transition:none}}\n"] }]
|
|
17234
17678
|
}], ctorParameters: () => [], propDecorators: { scroller: [{ type: i0.Input, args: [{ isSignal: true, alias: "scroller", required: false }] }], threshold: [{ type: i0.Input, args: [{ isSignal: true, alias: "threshold", required: false }] }], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], scrolled: [{ type: i0.Output, args: ["scrolled"] }] } });
|
|
17235
17679
|
|
|
17680
|
+
let nextId = 0;
|
|
17681
|
+
/**
|
|
17682
|
+
* Sección titulada de una ficha: ícono y título en una barra con línea fina y el contenido proyectado debajo, en
|
|
17683
|
+
* una tarjeta con la misma superficie que `kf-card`. Sirve para una sola vista con varias tarjetas en lugar de
|
|
17684
|
+
* pestañas cuando la información es acotada (la ficha de una persona o de una unidad dentro de un
|
|
17685
|
+
* `kf-detail-drawer`). La barra ocupa todo el ancho de la tarjeta; por eso no es un `kf-panel`, cuyo título es
|
|
17686
|
+
* un texto sin nivel de encabezado, sin ícono y con la línea dentro del relleno de la tarjeta.
|
|
17687
|
+
*
|
|
17688
|
+
* `level` es el nivel del encabezado: `h2` (default) en una página bajo su `h1`; `h3` dentro de un panel o de
|
|
17689
|
+
* un `kf-detail-drawer`, bajo su título. La sección es una región nombrada por ese encabezado.
|
|
17690
|
+
*
|
|
17691
|
+
* El cuerpo es un contenedor de consulta (`container-name: kf-section-card`, `inline-size`): lo que va dentro se
|
|
17692
|
+
* acomoda al ancho de la tarjeta con `@container kf-section-card (min-width: …)`, no al de la ventana. Un
|
|
17693
|
+
* contenedor de ese tipo no toma su ancho del contenido, así que la tarjeta se estira al de su padre.
|
|
17694
|
+
*
|
|
17695
|
+
* <kf-section-card icon="user" title="Cuenta" level="h3">
|
|
17696
|
+
* <kf-description-list [items]="account()" />
|
|
17697
|
+
* </kf-section-card>
|
|
17698
|
+
*/
|
|
17699
|
+
class SectionCard {
|
|
17700
|
+
/** Ícono decorativo a la izquierda del título; sin él no se dibuja. */
|
|
17701
|
+
icon = input(/* @ts-ignore */
|
|
17702
|
+
...(ngDevMode ? [undefined, { debugName: "icon" }] : /* istanbul ignore next */ []));
|
|
17703
|
+
/** Encabezado de la sección; también su nombre accesible. */
|
|
17704
|
+
title = input.required(/* @ts-ignore */
|
|
17705
|
+
...(ngDevMode ? [{ debugName: "title" }] : /* istanbul ignore next */ []));
|
|
17706
|
+
/** Nivel del encabezado: `h2` (default) o `h3`. */
|
|
17707
|
+
level = input('h2', /* @ts-ignore */
|
|
17708
|
+
...(ngDevMode ? [{ debugName: "level" }] : /* istanbul ignore next */ []));
|
|
17709
|
+
titleId = `kf-section-card-title-${nextId++}`;
|
|
17710
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: SectionCard, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
17711
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: SectionCard, isStandalone: true, selector: "kf-section-card", inputs: { icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: true, transformFunction: null }, level: { classPropertyName: "level", publicName: "level", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<section class=\"kf-section-card\" [attr.aria-labelledby]=\"titleId\">\n <header class=\"kf-section-card__head\">\n @if (icon(); as glyph) {\n <kf-icon class=\"kf-section-card__icon\" [name]=\"glyph\" size=\"sm\" aria-hidden=\"true\" />\n }\n @if (level() === 'h3') {\n <h3 class=\"kf-section-card__title\" [id]=\"titleId\">{{ title() }}</h3>\n } @else {\n <h2 class=\"kf-section-card__title\" [id]=\"titleId\">{{ title() }}</h2>\n }\n </header>\n <div class=\"kf-section-card__body\">\n <ng-content />\n </div>\n</section>\n", styles: [":host{display:block;min-width:0}.kf-section-card{display:flex;flex-direction:column;min-width:0;background:var(--kf-color-white);border:1px solid var(--kf-color-border);border-radius:var(--kf-radius-md);font-family:var(--kf-font-body)}.kf-section-card__head{display:flex;align-items:center;gap:var(--kf-space-sm);min-block-size:48px;padding:var(--kf-space-sm) var(--kf-space-md);border-block-end:1px solid var(--kf-color-border)}.kf-section-card__icon{flex:none;color:var(--kf-color-text-muted)}.kf-section-card__title{flex:1 1 auto;min-width:0;margin:0;font-family:var(--kf-font-title);font-size:var(--kf-font-size-body);font-weight:700;color:var(--kf-color-ink);text-wrap:balance;overflow-wrap:anywhere}.kf-section-card__body{display:flex;flex-direction:column;gap:var(--kf-space-md);padding:var(--kf-space-md);container:kf-section-card / inline-size}\n"], dependencies: [{ kind: "component", type: Icon, selector: "kf-icon", inputs: ["name", "size", "rotate", "filled"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
17712
|
+
}
|
|
17713
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: SectionCard, decorators: [{
|
|
17714
|
+
type: Component,
|
|
17715
|
+
args: [{ selector: 'kf-section-card', imports: [Icon], changeDetection: ChangeDetectionStrategy.OnPush, template: "<section class=\"kf-section-card\" [attr.aria-labelledby]=\"titleId\">\n <header class=\"kf-section-card__head\">\n @if (icon(); as glyph) {\n <kf-icon class=\"kf-section-card__icon\" [name]=\"glyph\" size=\"sm\" aria-hidden=\"true\" />\n }\n @if (level() === 'h3') {\n <h3 class=\"kf-section-card__title\" [id]=\"titleId\">{{ title() }}</h3>\n } @else {\n <h2 class=\"kf-section-card__title\" [id]=\"titleId\">{{ title() }}</h2>\n }\n </header>\n <div class=\"kf-section-card__body\">\n <ng-content />\n </div>\n</section>\n", styles: [":host{display:block;min-width:0}.kf-section-card{display:flex;flex-direction:column;min-width:0;background:var(--kf-color-white);border:1px solid var(--kf-color-border);border-radius:var(--kf-radius-md);font-family:var(--kf-font-body)}.kf-section-card__head{display:flex;align-items:center;gap:var(--kf-space-sm);min-block-size:48px;padding:var(--kf-space-sm) var(--kf-space-md);border-block-end:1px solid var(--kf-color-border)}.kf-section-card__icon{flex:none;color:var(--kf-color-text-muted)}.kf-section-card__title{flex:1 1 auto;min-width:0;margin:0;font-family:var(--kf-font-title);font-size:var(--kf-font-size-body);font-weight:700;color:var(--kf-color-ink);text-wrap:balance;overflow-wrap:anywhere}.kf-section-card__body{display:flex;flex-direction:column;gap:var(--kf-space-md);padding:var(--kf-space-md);container:kf-section-card / inline-size}\n"] }]
|
|
17716
|
+
}], propDecorators: { icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: true }] }], level: [{ type: i0.Input, args: [{ isSignal: true, alias: "level", required: false }] }] } });
|
|
17717
|
+
|
|
17236
17718
|
/**
|
|
17237
17719
|
* Título de sub-sección con chip de ícono, pensado para anidarse dentro de
|
|
17238
17720
|
* cards o paneles (a diferencia de `PageHeader`, que encabeza una página
|
|
@@ -19289,5 +19771,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
19289
19771
|
* Generated bundle index. Do not edit.
|
|
19290
19772
|
*/
|
|
19291
19773
|
|
|
19292
|
-
export { AUDIO_PLAYER_LABELS, ActionMenu, ActionRow, ActionTile, AdminBadge, AiMark, AiTag, Alert, AlertGroup, AlertRow, AudioPlayer, Avatar, Badge, BrandLogo, Breadcrumb, BucketProgress, Button, CUSTOM_PRESET_ID, Calendar, Card, Carousel, CarouselSlide, Checkbox, Chip, Collapsible, ConfirmDialog, ContactPopover, ContentSlot, ContentState, ContentStateLoading, ContentViewer, CursorPager, DATA_TABLE_MAX_SKELETON_ROWS, DEFAULT_MILESTONE_TIMELINE_LABELS, DEFAULT_PAGE_SIZE_OPTIONS, DataFreshness, DataTable, DateField, DateRangeField, DateTimeField, DeadlineStrip, DescriptionList, DescriptionValue, Divider, DocumentRow, Drawer, DrawerTitle, Dropdown, DropdownGroup, DropdownItem, DropdownPanel, EditFooter, EmptyState, EventTimeline, FeatureCard, Field, FieldLabel, Fieldset, FileInput, Filter, FilterChips, FloatingToolbar, FolderTabs, FolderTabsPanel, Footer, FormatInputDirective, Icon, Image, Input, JourneyStepper, LIST_TOOLBAR_HYSTERESIS, LayoutThumb, Link, ListGroup, ListMap, ListToolbar, MEDIA_VIEWER_LABELS, MediaViewer, MetricCard, MilestoneTimeline, Modal, MultiSelect, NoteBlock, NumberStepper, OptionList, PROGRESS_STATUS, PROGRESS_STATUS_LABEL, PageHeader, Pagination, Panel, PopoverDirective, PortalHeader, Progress, ProgressStrip, PulseDot, RowActions, SKELETON_PRESET_MAX_COUNT, ScrollSpyDirective, ScrollTop, SectionHeader, SectionNav, SectionNavItem, SectionNavSubsection, Segmented, Select, SelectableCardGroup, SelectableCardPreview, SidebarShell, SignaturePad, Skeleton, SkeletonPreset, Slider, SortableItem, SortableList, Spinner, StatCard, StatTile, StatusMark, StatusNode, StatusPill, Switch, TOAST_DEFAULT_DURATION_MS, TOAST_MAX_QUEUE, TOAST_MAX_VISIBLE, Tabs, Text, Textarea, TileGrid, TimeField, TimeSlotPicker, ToastHost, ToastService, TooltipDirective, ViewToggle, ZoomPanDirective, dataTableViewSignal, defaultDateRangePresets, formatDataAge, formatFileSize, resolveListToolbarMode };
|
|
19774
|
+
export { AUDIO_PLAYER_LABELS, ActionMenu, ActionRow, ActionTile, AdminBadge, AiMark, AiTag, Alert, AlertGroup, AlertRow, AudioPlayer, Avatar, Badge, BrandLogo, Breadcrumb, BucketProgress, Button, CUSTOM_PRESET_ID, Calendar, Card, Carousel, CarouselSlide, Checkbox, Chip, Collapsible, ConfirmDialog, ContactPopover, ContentSlot, ContentState, ContentStateLoading, ContentViewer, CursorPager, DATA_TABLE_MAX_SKELETON_ROWS, DEFAULT_MILESTONE_TIMELINE_LABELS, DEFAULT_PAGE_SIZE_OPTIONS, DataFreshness, DataTable, DateField, DateRangeField, DateTimeField, DeadlineStrip, DescriptionList, DescriptionValue, DetailDrawer, DiscardPromptHost, DiscardPromptService, Divider, DocumentRow, Drawer, DrawerTitle, Dropdown, DropdownGroup, DropdownItem, DropdownPanel, EditFooter, EmptyState, EventTimeline, FeatureCard, Field, FieldLabel, Fieldset, FileInput, Filter, FilterChips, FloatingToolbar, FolderTabs, FolderTabsPanel, Footer, FormatInputDirective, Icon, Image, Input, JourneyStepper, LIST_TOOLBAR_HYSTERESIS, LayoutThumb, Link, ListGroup, ListMap, ListToolbar, MEDIA_VIEWER_LABELS, MediaViewer, MetricCard, MilestoneTimeline, Modal, MultiSelect, NoteBlock, NumberStepper, OptionList, PROGRESS_STATUS, PROGRESS_STATUS_LABEL, PageHeader, Pagination, Panel, PopoverDirective, PortalHeader, Progress, ProgressStrip, PulseDot, RowActions, SKELETON_PRESET_MAX_COUNT, ScrollSpyDirective, ScrollTop, SectionCard, SectionHeader, SectionNav, SectionNavItem, SectionNavSubsection, Segmented, Select, SelectableCardGroup, SelectableCardPreview, SidebarShell, SignaturePad, Skeleton, SkeletonPreset, Slider, SortableItem, SortableList, Spinner, StatCard, StatTile, StatusMark, StatusNode, StatusPill, Switch, TOAST_DEFAULT_DURATION_MS, TOAST_MAX_QUEUE, TOAST_MAX_VISIBLE, Tabs, Text, Textarea, TileGrid, TimeField, TimeSlotPicker, ToastHost, ToastService, TooltipDirective, ViewToggle, ZoomPanDirective, dataTableViewSignal, defaultDateRangePresets, formatDataAge, formatFileSize, resolveListToolbarMode };
|
|
19293
19775
|
//# sourceMappingURL=kaufmann-lab-ui-core.mjs.map
|