@kaufmann-lab/ui 0.1.43 → 0.1.45
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, model, linkedSignal, afterRenderEffect, HostListener, TemplateRef,
|
|
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, Injectable } 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';
|
|
@@ -1754,6 +1754,28 @@ function retreatHistory(history, win) {
|
|
|
1754
1754
|
const LARGE_SHEET_GAP_PX = 24;
|
|
1755
1755
|
/** Controles que, al recibir el `pointerdown`, no deben iniciar el arrastre de la hoja. */
|
|
1756
1756
|
const DRAG_IGNORED_TARGETS = 'button, a[href], input, select, textarea, [role="button"], [contenteditable="true"]';
|
|
1757
|
+
/**
|
|
1758
|
+
* Marca el contenido del slot `[kfDrawerTitle]` de `kf-drawer`: un título con contenido propio
|
|
1759
|
+
* (una placa, una insignia de estado, texto) en vez del texto plano de `title`. `kf-drawer` la
|
|
1760
|
+
* detecta vía `contentChild` para dibujar la barra de título aunque no haya `title`; hay que
|
|
1761
|
+
* importarla junto a `Drawer`. Con `title` también presente, gana el slot (ver `Drawer`). El atributo
|
|
1762
|
+
* va en camelCase porque la regla de lint de selectores de directiva lo exige (como `kfAuthLayoutSso`);
|
|
1763
|
+
* `[kf-drawer-actions]` y los otros slots son kebab-case porque no necesitan directiva.
|
|
1764
|
+
*
|
|
1765
|
+
* <kf-drawer [(open)]="open" role="dialog" side="right" closeLabel="Cerrar ticket">
|
|
1766
|
+
* <kf-plate kfDrawerTitle value="D4K-902" country="PE" />
|
|
1767
|
+
* <kf-badge kfDrawerTitle tone="info">En ruta</kf-badge>
|
|
1768
|
+
* …
|
|
1769
|
+
* </kf-drawer>
|
|
1770
|
+
*/
|
|
1771
|
+
class DrawerTitle {
|
|
1772
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: DrawerTitle, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
1773
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.1.0", type: DrawerTitle, isStandalone: true, selector: "[kfDrawerTitle]", ngImport: i0 });
|
|
1774
|
+
}
|
|
1775
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: DrawerTitle, decorators: [{
|
|
1776
|
+
type: Directive,
|
|
1777
|
+
args: [{ selector: '[kfDrawerTitle]' }]
|
|
1778
|
+
}] });
|
|
1757
1779
|
/**
|
|
1758
1780
|
* Panel lateral genérico, agnóstico de contenido — no sabe qué es navegación
|
|
1759
1781
|
* ni qué es sesión, solo da tres lugares para proyectar contenido
|
|
@@ -1814,6 +1836,22 @@ const DRAG_IGNORED_TARGETS = 'button, a[href], input, select, textarea, [role="b
|
|
|
1814
1836
|
* …
|
|
1815
1837
|
* </kf-drawer>
|
|
1816
1838
|
*
|
|
1839
|
+
* `[kfDrawerTitle]` (con la directiva `DrawerTitle` importada) reemplaza el texto de `title` por
|
|
1840
|
+
* contenido propio —una placa y una insignia de estado, por ejemplo—, y crea la barra de título por
|
|
1841
|
+
* sí solo: no necesita `title`. Cada elemento marcado queda en la misma fila, centrado con los demás,
|
|
1842
|
+
* y la fila baja de línea sin cortarse; un texto va en un `<span kfDrawerTitle>`. El título vive
|
|
1843
|
+
* en el mismo `<h2>` que el de texto, así que `aria-labelledby` del panel apunta a él y el nombre
|
|
1844
|
+
* accesible es el texto de todo lo proyectado (la placa y la insignia incluidas). Con `title` también
|
|
1845
|
+
* presente gana el slot y el texto de `title` no se dibuja. El botón de cerrar y `[kf-drawer-actions]`
|
|
1846
|
+
* quedan igual a su derecha. Con `@if`, un solo elemento raíz por bloque: Angular decide el slot por
|
|
1847
|
+
* ese elemento.
|
|
1848
|
+
*
|
|
1849
|
+
* <kf-drawer [(open)]="open" role="dialog" side="right" closeLabel="Cerrar ticket">
|
|
1850
|
+
* <kf-plate kfDrawerTitle value="D4K-902" country="PE" />
|
|
1851
|
+
* <kf-badge kfDrawerTitle tone="info">En ruta</kf-badge>
|
|
1852
|
+
* …
|
|
1853
|
+
* </kf-drawer>
|
|
1854
|
+
*
|
|
1817
1855
|
* `side="bottom"` lo convierte en hoja inferior (grip, esquinas superiores
|
|
1818
1856
|
* redondeadas, alto máximo 80vh) — pensado para un resumen en mobile.
|
|
1819
1857
|
*
|
|
@@ -1931,7 +1969,11 @@ class Drawer {
|
|
|
1931
1969
|
* "Diálogo" (`dialog`). */
|
|
1932
1970
|
ariaLabel = input(/* @ts-ignore */
|
|
1933
1971
|
...(ngDevMode ? [undefined, { debugName: "ariaLabel" }] : /* istanbul ignore next */ []));
|
|
1934
|
-
/**
|
|
1972
|
+
/**
|
|
1973
|
+
* Título visible en una barra clara arriba del panel, con botón de cierre. Sin él (ni
|
|
1974
|
+
* `[kfDrawerTitle]`) no hay barra (comportamiento histórico). Con `[kfDrawerTitle]`
|
|
1975
|
+
* proyectado, ese contenido lo reemplaza.
|
|
1976
|
+
*/
|
|
1935
1977
|
title = input(/* @ts-ignore */
|
|
1936
1978
|
...(ngDevMode ? [undefined, { debugName: "title" }] : /* istanbul ignore next */ []));
|
|
1937
1979
|
/** Nombre accesible del botón de cierre de la barra de título y del
|
|
@@ -2001,6 +2043,14 @@ class Drawer {
|
|
|
2001
2043
|
resolvedCloseLabel = computed(() => this.closeLabel() ?? (this.role() === 'dialog' ? 'Cerrar' : 'Cerrar menú'), /* @ts-ignore */
|
|
2002
2044
|
...(ngDevMode ? [{ debugName: "resolvedCloseLabel" }] : /* istanbul ignore next */ []));
|
|
2003
2045
|
titleId = `kf-drawer-title-${nextId$9++}`;
|
|
2046
|
+
/**
|
|
2047
|
+
* Presencia de `[kfDrawerTitle]`. Sin `descendants`: como la proyección, solo cuenta lo que se
|
|
2048
|
+
* declara directo en este `<kf-drawer>`, no el título de un drawer anidado en su cuerpo.
|
|
2049
|
+
*/
|
|
2050
|
+
titleSlot = contentChild(DrawerTitle, { ...(ngDevMode ? { debugName: "titleSlot" } : /* istanbul ignore next */ {}), descendants: false });
|
|
2051
|
+
/** La barra de título existe con `title` o con el slot proyectado. */
|
|
2052
|
+
hasTitleBar = computed(() => !!this.title() || !!this.titleSlot(), /* @ts-ignore */
|
|
2053
|
+
...(ngDevMode ? [{ debugName: "hasTitleBar" }] : /* istanbul ignore next */ []));
|
|
2004
2054
|
/** Ausente solo un instante: con `mountInOverlay` la plantilla se monta tras el primer render. */
|
|
2005
2055
|
panelRef = viewChild('panel', /* @ts-ignore */
|
|
2006
2056
|
...(ngDevMode ? [{ debugName: "panelRef" }] : /* istanbul ignore next */ []));
|
|
@@ -2095,8 +2145,8 @@ class Drawer {
|
|
|
2095
2145
|
});
|
|
2096
2146
|
if (isDevMode()) {
|
|
2097
2147
|
effect(() => {
|
|
2098
|
-
if (this.role() === 'dialog' && !this.
|
|
2099
|
-
console.warn('[kf-drawer] role="dialog" sin `title` ni `ariaLabel`: el diálogo se anuncia con el nombre genérico "Diálogo".');
|
|
2148
|
+
if (this.role() === 'dialog' && !this.hasTitleBar() && !this.ariaLabel()) {
|
|
2149
|
+
console.warn('[kf-drawer] role="dialog" sin `title`, `[kfDrawerTitle]` ni `ariaLabel`: el diálogo se anuncia con el nombre genérico "Diálogo".');
|
|
2100
2150
|
}
|
|
2101
2151
|
});
|
|
2102
2152
|
}
|
|
@@ -2289,7 +2339,7 @@ class Drawer {
|
|
|
2289
2339
|
return this.focusTrap;
|
|
2290
2340
|
}
|
|
2291
2341
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: Drawer, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2292
|
-
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" } }, 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]=\"title() ? null : resolvedAriaLabel()\"\n [attr.aria-labelledby]=\"title() ? 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 (title(); as titleText) {\n <div\n class=\"kf-drawer__titlebar\"\n (pointerdown)=\"onDragStart($event)\"\n (pointermove)=\"onDragMove($event)\"\n (pointerup)=\"onDragEnd($event)\"\n (pointercancel)=\"onDragCancel()\"\n >\n <h2 class=\"kf-drawer__title\" [id]=\"titleId\">{{ titleText }}</h2>\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__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"] }] });
|
|
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"] }] });
|
|
2293
2343
|
}
|
|
2294
2344
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: Drawer, decorators: [{
|
|
2295
2345
|
type: Component,
|
|
@@ -2301,8 +2351,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
2301
2351
|
'[attr.role]': 'null',
|
|
2302
2352
|
'[attr.title]': 'null',
|
|
2303
2353
|
'(window:popstate)': 'onPopState()',
|
|
2304
|
-
}, 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]=\"
|
|
2305
|
-
}], 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"] }], panelRef: [{ type: i0.ViewChild, args: ['panel', { isSignal: true }] }], contentTemplate: [{ type: i0.ViewChild, args: ['content', { isSignal: true }] }], onEscape: [{
|
|
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)=\"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"] }]
|
|
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: [{
|
|
2306
2356
|
type: HostListener,
|
|
2307
2357
|
args: ['document:keydown.escape', ['$event']]
|
|
2308
2358
|
}] } });
|
|
@@ -16022,10 +16072,15 @@ const MOBILE_STEP_DOWN = {
|
|
|
16022
16072
|
* `title-sm`, el subtítulo y la línea desaparecen.
|
|
16023
16073
|
*
|
|
16024
16074
|
* Con `sticky`, pasado el alto del encabezado queda fijo arriba (`--kf-page-header-top`, default
|
|
16025
|
-
* `0px`) en una versión compacta de
|
|
16026
|
-
* misma fila, las acciones y la frescura compacta; solo se
|
|
16027
|
-
* elevación mientras flota (`data-stuck`). Necesita que el
|
|
16028
|
-
* el contenido que se desplaza.
|
|
16075
|
+
* `0px`) en una versión compacta de 56px (`--kf-page-header-stuck-height`): el título en una
|
|
16076
|
+
* línea, las pestañas (de 32px) en la misma fila, las acciones y la frescura compacta; solo se
|
|
16077
|
+
* oculta el subtítulo. Tiene línea fina y elevación mientras flota (`data-stuck`). Necesita que el
|
|
16078
|
+
* contenedor del encabezado abarque todo el contenido que se desplaza.
|
|
16079
|
+
*
|
|
16080
|
+
* La barra compacta deja en el flujo el alto que el encabezado completo ocupaba: al fijarse o
|
|
16081
|
+
* soltarse, el contenido de abajo no se mueve ni cambia el alto del documento. Sin esa reserva, el
|
|
16082
|
+
* cambio de alto lo corrige el ancla de desplazamiento del navegador y la página salta o vuelve al
|
|
16083
|
+
* tope cerca del umbral.
|
|
16029
16084
|
*
|
|
16030
16085
|
* <kf-page-header layout="v4" sticky title="Divisiones" subtitle="Configuración de las 4 divisiones">
|
|
16031
16086
|
* <kf-button actions size="sm">Nueva división</kf-button>
|
|
@@ -16053,6 +16108,13 @@ class PageHeader {
|
|
|
16053
16108
|
isMobile = matchMediaSignal('(max-width: 900px)');
|
|
16054
16109
|
stuck = signal$1(false, /* @ts-ignore */
|
|
16055
16110
|
...(ngDevMode ? [{ debugName: "stuck" }] : /* istanbul ignore next */ []));
|
|
16111
|
+
/**
|
|
16112
|
+
* Alto del encabezado completo (sin fijar). Lo lee el CSS de la barra compacta para dejar en el flujo la
|
|
16113
|
+
* diferencia (`margin-block-end`). Mientras está fija solo se conoce el alto compacto, así que se conserva
|
|
16114
|
+
* el último medido.
|
|
16115
|
+
*/
|
|
16116
|
+
naturalHeight = signal$1(null, /* @ts-ignore */
|
|
16117
|
+
...(ngDevMode ? [{ debugName: "naturalHeight" }] : /* istanbul ignore next */ []));
|
|
16056
16118
|
host = inject(ElementRef);
|
|
16057
16119
|
resolvedTitleVariant = computed(() => {
|
|
16058
16120
|
if (this.density() === 'compact') {
|
|
@@ -16087,9 +16149,23 @@ class PageHeader {
|
|
|
16087
16149
|
});
|
|
16088
16150
|
});
|
|
16089
16151
|
destroyRef.onDestroy(() => this.stuck.set(false));
|
|
16152
|
+
afterNextRender(() => {
|
|
16153
|
+
if (typeof ResizeObserver === 'undefined') {
|
|
16154
|
+
return;
|
|
16155
|
+
}
|
|
16156
|
+
const el = this.host.nativeElement;
|
|
16157
|
+
const observer = new ResizeObserver(([entry]) => {
|
|
16158
|
+
// Con la barra fija el alto observado es el compacto: no es el que hay que reservar.
|
|
16159
|
+
if (!this.stuck() && entry) {
|
|
16160
|
+
this.naturalHeight.set(entry.borderBoxSize?.[0]?.blockSize ?? el.offsetHeight);
|
|
16161
|
+
}
|
|
16162
|
+
});
|
|
16163
|
+
observer.observe(el);
|
|
16164
|
+
destroyRef.onDestroy(() => observer.disconnect());
|
|
16165
|
+
});
|
|
16090
16166
|
}
|
|
16091
16167
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: PageHeader, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
16092
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: PageHeader, isStandalone: true, selector: "kf-page-header", inputs: { icon: { classPropertyName: "icon", publicName: "icon", 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 }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, layout: { classPropertyName: "layout", publicName: "layout", isSignal: true, isRequired: false, transformFunction: null }, density: { classPropertyName: "density", publicName: "density", isSignal: true, isRequired: false, transformFunction: null }, sticky: { classPropertyName: "sticky", publicName: "sticky", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "attr.data-layout": "layout()", "attr.data-density": "density()", "attr.data-sticky": "layout() === 'v4' && sticky() ? '' : null", "attr.data-stuck": "stuck() ? '' : null" } }, ngImport: i0, template: "<div class=\"kf-page-header__row\">\n @if (icon(); as iconName) {\n @if (!compact()) {\n <span class=\"kf-page-header__icon\">\n <kf-icon [name]=\"iconName\" size=\"lg\" />\n </span>\n }\n }\n\n <div class=\"kf-page-header__heading\">\n <kf-text\n as=\"h1\"\n class=\"kf-page-header__title\"\n [variant]=\"resolvedTitleVariant()\"\n [attr.title]=\"layout() === 'v4' ? title() : null\"\n >\n {{ title() }}\n </kf-text>\n @if (subtitle() && !compact()) {\n <p class=\"kf-page-header__subtitle\" [attr.title]=\"layout() === 'v4' ? subtitle() : null\">\n {{ subtitle() }}\n </p>\n }\n </div>\n\n <div class=\"kf-page-header__actions\">\n <ng-content select=\"[actions]\" />\n </div>\n <span class=\"kf-page-header__divider\" aria-hidden=\"true\"></span>\n <div class=\"kf-page-header__freshness\">\n <ng-content select=\"[freshness]\" />\n </div>\n</div>\n<div class=\"kf-page-header__tabs\">\n <ng-content select=\"[tabs]\" />\n</div>\n", styles: [":host{display:block;font-family:var(--kf-font-body);padding-bottom:var(--kf-space-lg);border-bottom:1px solid var(--kf-color-border)}.kf-page-header__row{display:flex;align-items:center;gap:var(--kf-space-md)}.kf-page-header__icon{display:inline-flex;align-items:center;justify-content:center;flex:none;width:52px;height:52px;border-radius:var(--kf-radius-md);background:var(--kf-color-primary-soft);color:var(--kf-color-primary);border:1px solid var(--kf-color-border)}.kf-page-header__heading{display:flex;flex-direction:column;gap:2px;flex:1 1 auto;min-width:0}.kf-page-header__title{line-height:1.2}.kf-page-header__subtitle{margin:0;font-size:.9375rem;color:var(--kf-color-text-muted)}.kf-page-header__actions{flex:none;display:flex;align-items:center;gap:var(--kf-space-sm)}@media(max-width:900px){.kf-page-header__icon{width:40px;height:40px}.kf-page-header__subtitle{font-size:var(--kf-font-size-label)}}.kf-page-header__actions:empty,.kf-page-header__freshness:empty,.kf-page-header__tabs:empty,.kf-page-header__divider{display:none}:host([data-density=compact]) .kf-page-header__heading{gap:0}:host([data-layout=v4]){container:kf-page-header/inline-size;display:flex;flex-direction:column;gap:var(--kf-space-md);padding-bottom:0;border-bottom:none}:host([data-layout=v4]) .kf-page-header__row{gap:var(--kf-page-header-gap, 12px);min-height:40px;min-width:0}:host([data-layout=v4]) .kf-page-header__heading{gap:4px}:host([data-layout=v4]) .kf-page-header__title{display:block;min-width:0;line-height:1.2}:host([data-layout=v4]) .kf-page-header__title ::ng-deep>h1{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}:host([data-layout=v4]) .kf-page-header__subtitle{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;font-size:var(--kf-font-size-body-sm);line-height:20px}:host([data-layout=v4]) .kf-page-header__actions{justify-content:flex-end}:host([data-layout=v4]) .kf-page-header__freshness{flex:none;display:inline-flex;justify-content:flex-end;--kf-data-freshness-prefix: inline}:host([data-layout=v4]) .kf-page-header__actions:not(:empty)+.kf-page-header__divider:has(+.kf-page-header__freshness:not(:empty)){display:block;flex:none;align-self:center;width:1px;height:24px;background:var(--kf-color-border)}:host([data-layout=v4]) .kf-page-header__tabs{min-width:0}@container kf-page-header (max-width: 799.98px){:host([data-layout=v4]) .kf-page-header__freshness{--kf-data-freshness-prefix: none}}@container kf-page-header (max-width: 599.98px){:host([data-layout=v4]){gap:var(--kf-space-sm)}:host([data-layout=v4]) .kf-page-header__row{--kf-page-header-gap: 8px;flex-wrap:wrap;row-gap:var(--kf-space-sm)}:host([data-layout=v4]) .kf-page-header__heading{flex:1 1 7.5rem;min-width:7.5rem}:host([data-layout=v4]) .kf-page-header__actions,:host([data-layout=v4]) .kf-page-header__freshness{margin-inline-start:auto}:host([data-layout=v4]) .kf-page-header__subtitle,:host([data-layout=v4]) .kf-page-header__divider{display:none!important}:host([data-layout=v4]) .kf-page-header__title ::ng-deep>h1{font-size:var(--kf-font-size-title-sm)}}:host([data-layout=v4][data-sticky]){position:sticky;top:calc(var(--kf-page-header-top, 0px) - 1px);z-index:var(--kf-page-header-z, 30)}:host([data-layout=v4][data-stuck]){flex-direction:row;align-items:center;gap:var(--kf-page-header-gap, 12px);margin-inline:calc(-1 * var(--kf-page-header-bleed, 0px));padding:8px var(--kf-page-header-bleed, 0px);background:var(--kf-color-white);border-bottom:1px solid var(--kf-color-border);box-shadow:var(--kf-elevation-raised);--kf-tabs-tab-height: 32px;--kf-tabs-line-width: 0px;--kf-data-freshness-prefix: none}:host([data-layout=v4][data-stuck]) .kf-page-header__row{display:contents}:host([data-layout=v4][data-stuck]) .kf-page-header__icon{order:0}:host([data-layout=v4][data-stuck]) .kf-page-header__heading{order:1;flex:0 1 auto;max-width:32%}:host([data-layout=v4][data-stuck]) .kf-page-header__subtitle{display:none}:host([data-layout=v4][data-stuck]) .kf-page-header__tabs{order:2;flex:1 1 0;align-self:center}:host([data-layout=v4][data-stuck]) .kf-page-header__actions{order:3}:host([data-layout=v4][data-stuck]) .kf-page-header__divider{order:4}:host([data-layout=v4][data-stuck]) .kf-page-header__freshness{order:5;--kf-data-freshness-prefix: none}:host([data-layout=v4][data-stuck]) .kf-page-header__title ::ng-deep>h1{font-size:var(--kf-font-size-body)}@container kf-page-header (max-width: 599.98px){:host([data-layout=v4][data-stuck]) .kf-page-header__heading{display:none}:host([data-layout=v4][data-stuck]) .kf-page-header__freshness{--kf-data-freshness-text: none}}:host([data-layout=v4][data-stuck]) .kf-page-header__tabs{min-width:0}@media(prefers-reduced-motion:no-preference){:host([data-layout=v4][data-sticky]){transition:box-shadow var(--kf-motion-base, .22s) var(--kf-ease-standard, ease)}}\n"], dependencies: [{ kind: "component", type: Icon, selector: "kf-icon", inputs: ["name", "size", "rotate", "filled"] }, { kind: "component", type: Text, selector: "kf-text", inputs: ["as", "variant", "tone"] }] });
|
|
16168
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: PageHeader, isStandalone: true, selector: "kf-page-header", inputs: { icon: { classPropertyName: "icon", publicName: "icon", 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 }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, layout: { classPropertyName: "layout", publicName: "layout", isSignal: true, isRequired: false, transformFunction: null }, density: { classPropertyName: "density", publicName: "density", isSignal: true, isRequired: false, transformFunction: null }, sticky: { classPropertyName: "sticky", publicName: "sticky", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "attr.data-layout": "layout()", "attr.data-density": "density()", "attr.data-sticky": "layout() === 'v4' && sticky() ? '' : null", "attr.data-stuck": "stuck() ? '' : null", "style.--kf-page-header-natural.px": "naturalHeight()" } }, ngImport: i0, template: "<div class=\"kf-page-header__row\">\n @if (icon(); as iconName) {\n @if (!compact()) {\n <span class=\"kf-page-header__icon\">\n <kf-icon [name]=\"iconName\" size=\"lg\" />\n </span>\n }\n }\n\n <div class=\"kf-page-header__heading\">\n <kf-text\n as=\"h1\"\n class=\"kf-page-header__title\"\n [variant]=\"resolvedTitleVariant()\"\n [attr.title]=\"layout() === 'v4' ? title() : null\"\n >\n {{ title() }}\n </kf-text>\n @if (subtitle() && !compact()) {\n <p class=\"kf-page-header__subtitle\" [attr.title]=\"layout() === 'v4' ? subtitle() : null\">\n {{ subtitle() }}\n </p>\n }\n </div>\n\n <div class=\"kf-page-header__actions\">\n <ng-content select=\"[actions]\" />\n </div>\n <span class=\"kf-page-header__divider\" aria-hidden=\"true\"></span>\n <div class=\"kf-page-header__freshness\">\n <ng-content select=\"[freshness]\" />\n </div>\n</div>\n<div class=\"kf-page-header__tabs\">\n <ng-content select=\"[tabs]\" />\n</div>\n", styles: [":host{display:block;font-family:var(--kf-font-body);padding-bottom:var(--kf-space-lg);border-bottom:1px solid var(--kf-color-border)}.kf-page-header__row{display:flex;align-items:center;gap:var(--kf-space-md)}.kf-page-header__icon{display:inline-flex;align-items:center;justify-content:center;flex:none;width:52px;height:52px;border-radius:var(--kf-radius-md);background:var(--kf-color-primary-soft);color:var(--kf-color-primary);border:1px solid var(--kf-color-border)}.kf-page-header__heading{display:flex;flex-direction:column;gap:2px;flex:1 1 auto;min-width:0}.kf-page-header__title{line-height:1.2}.kf-page-header__subtitle{margin:0;font-size:.9375rem;color:var(--kf-color-text-muted)}.kf-page-header__actions{flex:none;display:flex;align-items:center;gap:var(--kf-space-sm)}@media(max-width:900px){.kf-page-header__icon{width:40px;height:40px}.kf-page-header__subtitle{font-size:var(--kf-font-size-label)}}.kf-page-header__actions:empty,.kf-page-header__freshness:empty,.kf-page-header__tabs:empty,.kf-page-header__divider{display:none}:host([data-density=compact]) .kf-page-header__heading{gap:0}:host([data-layout=v4]){container:kf-page-header/inline-size;display:flex;flex-direction:column;gap:var(--kf-space-md);padding-bottom:0;border-bottom:none}:host([data-layout=v4]) .kf-page-header__row{gap:var(--kf-page-header-gap, 12px);min-height:40px;min-width:0}:host([data-layout=v4]) .kf-page-header__heading{gap:4px}:host([data-layout=v4]) .kf-page-header__title{display:block;min-width:0;line-height:1.2}:host([data-layout=v4]) .kf-page-header__title ::ng-deep>h1{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}:host([data-layout=v4]) .kf-page-header__subtitle{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;font-size:var(--kf-font-size-body-sm);line-height:20px}:host([data-layout=v4]) .kf-page-header__actions{justify-content:flex-end}:host([data-layout=v4]) .kf-page-header__freshness{flex:none;display:inline-flex;justify-content:flex-end;--kf-data-freshness-prefix: inline}:host([data-layout=v4]) .kf-page-header__actions:not(:empty)+.kf-page-header__divider:has(+.kf-page-header__freshness:not(:empty)){display:block;flex:none;align-self:center;width:1px;height:24px;background:var(--kf-color-border)}:host([data-layout=v4]) .kf-page-header__tabs{min-width:0}@container kf-page-header (max-width: 799.98px){:host([data-layout=v4]) .kf-page-header__freshness{--kf-data-freshness-prefix: none}}@container kf-page-header (max-width: 599.98px){:host([data-layout=v4]){gap:var(--kf-space-sm)}:host([data-layout=v4]) .kf-page-header__row{--kf-page-header-gap: 8px;flex-wrap:wrap;row-gap:var(--kf-space-sm)}:host([data-layout=v4]) .kf-page-header__heading{flex:1 1 7.5rem;min-width:7.5rem}:host([data-layout=v4]) .kf-page-header__actions,:host([data-layout=v4]) .kf-page-header__freshness{margin-inline-start:auto}:host([data-layout=v4]) .kf-page-header__subtitle,:host([data-layout=v4]) .kf-page-header__divider{display:none!important}:host([data-layout=v4]) .kf-page-header__title ::ng-deep>h1{font-size:var(--kf-font-size-title-sm)}}:host([data-layout=v4][data-sticky]){position:sticky;top:calc(var(--kf-page-header-top, 0px) - 1px);z-index:var(--kf-page-header-z, 30);overflow-anchor:none}:host([data-layout=v4][data-stuck]){--_stuck-height: var(--kf-page-header-stuck-height, 56px);box-sizing:border-box;block-size:var(--_stuck-height);margin-block-end:calc(var(--kf-page-header-natural, var(--_stuck-height)) - var(--_stuck-height));flex-direction:row;align-items:center;gap:var(--kf-page-header-gap, 12px);margin-inline:calc(-1 * var(--kf-page-header-bleed, 0px));padding:8px var(--kf-page-header-bleed, 0px);background:var(--kf-color-white);border-bottom:1px solid var(--kf-color-border);box-shadow:var(--kf-elevation-raised);--kf-tabs-tab-height: 32px;--kf-tabs-line-width: 0px;--kf-data-freshness-prefix: none}:host([data-layout=v4][data-stuck]) .kf-page-header__row{display:contents}:host([data-layout=v4][data-stuck]) .kf-page-header__icon{order:0}:host([data-layout=v4][data-stuck]) .kf-page-header__heading{order:1;flex:0 1 auto;max-width:32%}:host([data-layout=v4][data-stuck]) .kf-page-header__subtitle{display:none}:host([data-layout=v4][data-stuck]) .kf-page-header__tabs{order:2;flex:1 1 0;align-self:center}:host([data-layout=v4][data-stuck]) .kf-page-header__actions{order:3}:host([data-layout=v4][data-stuck]) .kf-page-header__divider{order:4}:host([data-layout=v4][data-stuck]) .kf-page-header__freshness{order:5;--kf-data-freshness-prefix: none}:host([data-layout=v4][data-stuck]) .kf-page-header__title ::ng-deep>h1{font-size:var(--kf-font-size-body)}@container kf-page-header (max-width: 599.98px){:host([data-layout=v4][data-stuck]) .kf-page-header__heading{display:none}:host([data-layout=v4][data-stuck]) .kf-page-header__freshness{--kf-data-freshness-text: none}}:host([data-layout=v4][data-stuck]) .kf-page-header__tabs{min-width:0}@media(prefers-reduced-motion:no-preference){:host([data-layout=v4][data-sticky]){transition:box-shadow var(--kf-motion-base, .22s) var(--kf-ease-standard, ease)}:host([data-layout=v4][data-stuck]){animation:kf-page-header-stuck-in var(--kf-motion-fast, .14s) var(--kf-ease-enter, ease-out)}}@keyframes kf-page-header-stuck-in{0%{opacity:.55}}\n"], dependencies: [{ kind: "component", type: Icon, selector: "kf-icon", inputs: ["name", "size", "rotate", "filled"] }, { kind: "component", type: Text, selector: "kf-text", inputs: ["as", "variant", "tone"] }] });
|
|
16093
16169
|
}
|
|
16094
16170
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: PageHeader, decorators: [{
|
|
16095
16171
|
type: Component,
|
|
@@ -16098,7 +16174,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
16098
16174
|
'[attr.data-density]': 'density()',
|
|
16099
16175
|
'[attr.data-sticky]': "layout() === 'v4' && sticky() ? '' : null",
|
|
16100
16176
|
'[attr.data-stuck]': "stuck() ? '' : null",
|
|
16101
|
-
|
|
16177
|
+
'[style.--kf-page-header-natural.px]': 'naturalHeight()',
|
|
16178
|
+
}, template: "<div class=\"kf-page-header__row\">\n @if (icon(); as iconName) {\n @if (!compact()) {\n <span class=\"kf-page-header__icon\">\n <kf-icon [name]=\"iconName\" size=\"lg\" />\n </span>\n }\n }\n\n <div class=\"kf-page-header__heading\">\n <kf-text\n as=\"h1\"\n class=\"kf-page-header__title\"\n [variant]=\"resolvedTitleVariant()\"\n [attr.title]=\"layout() === 'v4' ? title() : null\"\n >\n {{ title() }}\n </kf-text>\n @if (subtitle() && !compact()) {\n <p class=\"kf-page-header__subtitle\" [attr.title]=\"layout() === 'v4' ? subtitle() : null\">\n {{ subtitle() }}\n </p>\n }\n </div>\n\n <div class=\"kf-page-header__actions\">\n <ng-content select=\"[actions]\" />\n </div>\n <span class=\"kf-page-header__divider\" aria-hidden=\"true\"></span>\n <div class=\"kf-page-header__freshness\">\n <ng-content select=\"[freshness]\" />\n </div>\n</div>\n<div class=\"kf-page-header__tabs\">\n <ng-content select=\"[tabs]\" />\n</div>\n", styles: [":host{display:block;font-family:var(--kf-font-body);padding-bottom:var(--kf-space-lg);border-bottom:1px solid var(--kf-color-border)}.kf-page-header__row{display:flex;align-items:center;gap:var(--kf-space-md)}.kf-page-header__icon{display:inline-flex;align-items:center;justify-content:center;flex:none;width:52px;height:52px;border-radius:var(--kf-radius-md);background:var(--kf-color-primary-soft);color:var(--kf-color-primary);border:1px solid var(--kf-color-border)}.kf-page-header__heading{display:flex;flex-direction:column;gap:2px;flex:1 1 auto;min-width:0}.kf-page-header__title{line-height:1.2}.kf-page-header__subtitle{margin:0;font-size:.9375rem;color:var(--kf-color-text-muted)}.kf-page-header__actions{flex:none;display:flex;align-items:center;gap:var(--kf-space-sm)}@media(max-width:900px){.kf-page-header__icon{width:40px;height:40px}.kf-page-header__subtitle{font-size:var(--kf-font-size-label)}}.kf-page-header__actions:empty,.kf-page-header__freshness:empty,.kf-page-header__tabs:empty,.kf-page-header__divider{display:none}:host([data-density=compact]) .kf-page-header__heading{gap:0}:host([data-layout=v4]){container:kf-page-header/inline-size;display:flex;flex-direction:column;gap:var(--kf-space-md);padding-bottom:0;border-bottom:none}:host([data-layout=v4]) .kf-page-header__row{gap:var(--kf-page-header-gap, 12px);min-height:40px;min-width:0}:host([data-layout=v4]) .kf-page-header__heading{gap:4px}:host([data-layout=v4]) .kf-page-header__title{display:block;min-width:0;line-height:1.2}:host([data-layout=v4]) .kf-page-header__title ::ng-deep>h1{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}:host([data-layout=v4]) .kf-page-header__subtitle{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;font-size:var(--kf-font-size-body-sm);line-height:20px}:host([data-layout=v4]) .kf-page-header__actions{justify-content:flex-end}:host([data-layout=v4]) .kf-page-header__freshness{flex:none;display:inline-flex;justify-content:flex-end;--kf-data-freshness-prefix: inline}:host([data-layout=v4]) .kf-page-header__actions:not(:empty)+.kf-page-header__divider:has(+.kf-page-header__freshness:not(:empty)){display:block;flex:none;align-self:center;width:1px;height:24px;background:var(--kf-color-border)}:host([data-layout=v4]) .kf-page-header__tabs{min-width:0}@container kf-page-header (max-width: 799.98px){:host([data-layout=v4]) .kf-page-header__freshness{--kf-data-freshness-prefix: none}}@container kf-page-header (max-width: 599.98px){:host([data-layout=v4]){gap:var(--kf-space-sm)}:host([data-layout=v4]) .kf-page-header__row{--kf-page-header-gap: 8px;flex-wrap:wrap;row-gap:var(--kf-space-sm)}:host([data-layout=v4]) .kf-page-header__heading{flex:1 1 7.5rem;min-width:7.5rem}:host([data-layout=v4]) .kf-page-header__actions,:host([data-layout=v4]) .kf-page-header__freshness{margin-inline-start:auto}:host([data-layout=v4]) .kf-page-header__subtitle,:host([data-layout=v4]) .kf-page-header__divider{display:none!important}:host([data-layout=v4]) .kf-page-header__title ::ng-deep>h1{font-size:var(--kf-font-size-title-sm)}}:host([data-layout=v4][data-sticky]){position:sticky;top:calc(var(--kf-page-header-top, 0px) - 1px);z-index:var(--kf-page-header-z, 30);overflow-anchor:none}:host([data-layout=v4][data-stuck]){--_stuck-height: var(--kf-page-header-stuck-height, 56px);box-sizing:border-box;block-size:var(--_stuck-height);margin-block-end:calc(var(--kf-page-header-natural, var(--_stuck-height)) - var(--_stuck-height));flex-direction:row;align-items:center;gap:var(--kf-page-header-gap, 12px);margin-inline:calc(-1 * var(--kf-page-header-bleed, 0px));padding:8px var(--kf-page-header-bleed, 0px);background:var(--kf-color-white);border-bottom:1px solid var(--kf-color-border);box-shadow:var(--kf-elevation-raised);--kf-tabs-tab-height: 32px;--kf-tabs-line-width: 0px;--kf-data-freshness-prefix: none}:host([data-layout=v4][data-stuck]) .kf-page-header__row{display:contents}:host([data-layout=v4][data-stuck]) .kf-page-header__icon{order:0}:host([data-layout=v4][data-stuck]) .kf-page-header__heading{order:1;flex:0 1 auto;max-width:32%}:host([data-layout=v4][data-stuck]) .kf-page-header__subtitle{display:none}:host([data-layout=v4][data-stuck]) .kf-page-header__tabs{order:2;flex:1 1 0;align-self:center}:host([data-layout=v4][data-stuck]) .kf-page-header__actions{order:3}:host([data-layout=v4][data-stuck]) .kf-page-header__divider{order:4}:host([data-layout=v4][data-stuck]) .kf-page-header__freshness{order:5;--kf-data-freshness-prefix: none}:host([data-layout=v4][data-stuck]) .kf-page-header__title ::ng-deep>h1{font-size:var(--kf-font-size-body)}@container kf-page-header (max-width: 599.98px){:host([data-layout=v4][data-stuck]) .kf-page-header__heading{display:none}:host([data-layout=v4][data-stuck]) .kf-page-header__freshness{--kf-data-freshness-text: none}}:host([data-layout=v4][data-stuck]) .kf-page-header__tabs{min-width:0}@media(prefers-reduced-motion:no-preference){:host([data-layout=v4][data-sticky]){transition:box-shadow var(--kf-motion-base, .22s) var(--kf-ease-standard, ease)}:host([data-layout=v4][data-stuck]){animation:kf-page-header-stuck-in var(--kf-motion-fast, .14s) var(--kf-ease-enter, ease-out)}}@keyframes kf-page-header-stuck-in{0%{opacity:.55}}\n"] }]
|
|
16102
16179
|
}], ctorParameters: () => [], propDecorators: { icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: true }] }], subtitle: [{ type: i0.Input, args: [{ isSignal: true, alias: "subtitle", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], layout: [{ type: i0.Input, args: [{ isSignal: true, alias: "layout", required: false }] }], density: [{ type: i0.Input, args: [{ isSignal: true, alias: "density", required: false }] }], sticky: [{ type: i0.Input, args: [{ isSignal: true, alias: "sticky", required: false }] }] } });
|
|
16103
16180
|
|
|
16104
16181
|
/**
|
|
@@ -19212,5 +19289,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImpor
|
|
|
19212
19289
|
* Generated bundle index. Do not edit.
|
|
19213
19290
|
*/
|
|
19214
19291
|
|
|
19215
|
-
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, 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 };
|
|
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 };
|
|
19216
19293
|
//# sourceMappingURL=kaufmann-lab-ui-core.mjs.map
|