@kaufmann-lab/ui 0.1.28 → 0.1.29
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.
|
@@ -1237,34 +1237,54 @@ const TONE_ICON = {
|
|
|
1237
1237
|
* vencimiento, confirmaciones. Persiste hasta que se descarta o hasta que la
|
|
1238
1238
|
* condición que lo causó desaparece — para feedback efímero está el toast.
|
|
1239
1239
|
*
|
|
1240
|
-
*
|
|
1241
|
-
*
|
|
1242
|
-
*
|
|
1243
|
-
*
|
|
1244
|
-
* un input. Ninguna apariencia lleva borde ni acento lateral de color.
|
|
1240
|
+
* El color sale siempre de los tokens (`*-soft`, `*-strong`), nunca de un input.
|
|
1241
|
+
* Ninguna apariencia lleva borde ni acento lateral de color. El ícono va
|
|
1242
|
+
* alineado con la primera línea del texto (la del título si lo hay), no
|
|
1243
|
+
* centrado en el bloque: en un aviso de una sola línea ambas cosas coinciden.
|
|
1245
1244
|
*
|
|
1246
1245
|
* `appearance` elige cómo se muestra el tono (solo aplica a `variant="card"`):
|
|
1247
1246
|
*
|
|
1248
|
-
* - `
|
|
1249
|
-
*
|
|
1250
|
-
*
|
|
1247
|
+
* - `surface` (default): aviso estándar dentro de pantallas y cards. Fondo suave
|
|
1248
|
+
* del tono con un borde fino de una mezcla más fuerte del mismo tono, ícono de
|
|
1249
|
+
* estado relleno y texto neutro. Sin `title` es compacto (relleno 8/12, ícono
|
|
1250
|
+
* de 16px, texto de 14px); con `title` pasa al layout amplio (relleno 20/24,
|
|
1251
|
+
* ícono de 24px, título de 16px y mensaje de 14px, con las acciones bajo el
|
|
1252
|
+
* mensaje). Acciones sugeridas: `kf-button size="sm"` primario y `variant="outline"`.
|
|
1251
1253
|
*
|
|
1252
1254
|
* <kf-alert tone="warn" title="SOAT por vencer">Vence el 15/08.</kf-alert>
|
|
1253
1255
|
*
|
|
1254
|
-
* - `
|
|
1255
|
-
*
|
|
1256
|
-
*
|
|
1257
|
-
*
|
|
1258
|
-
*
|
|
1256
|
+
* - `elevated`: aviso que flota sobre el contenido, como una notificación.
|
|
1257
|
+
* Tarjeta blanca con sombra y un borde fino neutro, ícono de estado relleno de
|
|
1258
|
+
* 24px y título de 14px con la descripción atenuada. Las acciones van como
|
|
1259
|
+
* enlaces separados por un punto medio: proyecta `kf-button size="sm"
|
|
1260
|
+
* variant="ghost"` (el aviso alinea el primero con el texto).
|
|
1261
|
+
*
|
|
1262
|
+
* <kf-alert appearance="elevated" tone="ok" title="Pago registrado">
|
|
1263
|
+
* El comprobante fue enviado a tu correo.
|
|
1264
|
+
* <div kfAlertActions>
|
|
1265
|
+
* <kf-button size="sm" variant="ghost">Descargar</kf-button>
|
|
1266
|
+
* <kf-button size="sm" variant="ghost">Ver pagos</kf-button>
|
|
1267
|
+
* </div>
|
|
1268
|
+
* </kf-alert>
|
|
1259
1269
|
*
|
|
1260
|
-
* - `
|
|
1261
|
-
*
|
|
1262
|
-
*
|
|
1270
|
+
* - `solid`: máxima visibilidad, para avisos que no pueden pasar inadvertidos.
|
|
1271
|
+
* Fondo en el `*-strong` del tono con texto e ícono (de trazo) blancos; en
|
|
1272
|
+
* `warn` el fondo es `--kf-color-warning` con texto `--kf-color-ink`. Se agota
|
|
1273
|
+
* si hay más de uno a la vez. Las acciones deben ser `kf-button size="sm"`:
|
|
1274
|
+
* `variant="primary"` se pinta como botón blanco (de `ink` en `warn`) y
|
|
1275
|
+
* `variant="outline"` como botón de contorno blanco; `ghost` también funciona.
|
|
1263
1276
|
*
|
|
1264
|
-
* <kf-alert appearance="
|
|
1277
|
+
* <kf-alert appearance="solid" tone="error" title="Pago rechazado">
|
|
1265
1278
|
* Tu banco no autorizó el cargo.
|
|
1279
|
+
* <div kfAlertActions>
|
|
1280
|
+
* <kf-button size="sm">Reintentar</kf-button>
|
|
1281
|
+
* <kf-button size="sm" variant="outline">Ver detalle</kf-button>
|
|
1282
|
+
* </div>
|
|
1266
1283
|
* </kf-alert>
|
|
1267
1284
|
*
|
|
1285
|
+
* Las acciones de `variant="card"` van siempre bajo el mensaje. Los botones de
|
|
1286
|
+
* un `<div kfAlertActions>` quedan separados 12px (8px en `solid`).
|
|
1287
|
+
*
|
|
1268
1288
|
* `open` es two-way: el botón de cerrar lo pone en `false` y el componente
|
|
1269
1289
|
* deja de renderizar. El consumidor puede volver a abrirlo poniéndolo en
|
|
1270
1290
|
* `true` (ej. cuando la validación falla otra vez).
|
|
@@ -1283,11 +1303,10 @@ const TONE_ICON = {
|
|
|
1283
1303
|
*
|
|
1284
1304
|
* <kf-alert variant="bar" tone="warn" title="Modo suplantación">Viendo como Ana Pérez.</kf-alert>
|
|
1285
1305
|
*
|
|
1286
|
-
* Los elementos con el atributo `kfAlertActions` se proyectan
|
|
1287
|
-
*
|
|
1288
|
-
*
|
|
1289
|
-
*
|
|
1290
|
-
* Sin ellos la zona no existe y el aviso queda igual.
|
|
1306
|
+
* Los elementos con el atributo `kfAlertActions` se proyectan bajo el mensaje, en
|
|
1307
|
+
* una fila propia apilados y alineados al inicio. Si los envuelves en un solo
|
|
1308
|
+
* `<div kfAlertActions>`, el aviso separa a sus hijos. Sin ellos la zona no
|
|
1309
|
+
* existe y el aviso queda igual.
|
|
1291
1310
|
*
|
|
1292
1311
|
* <kf-alert tone="warn" title="SOAT por vencer">
|
|
1293
1312
|
* Vence el 15/08.
|
|
@@ -1301,12 +1320,15 @@ class Alert {
|
|
|
1301
1320
|
variant = input('card', /* @ts-ignore */
|
|
1302
1321
|
...(ngDevMode ? [{ debugName: "variant" }] : /* istanbul ignore next */ []));
|
|
1303
1322
|
/**
|
|
1304
|
-
* `
|
|
1305
|
-
* ignora. Se expone en el host como `data-appearance`.
|
|
1323
|
+
* `surface` (default), `elevated` o `solid`. Solo aplica a `variant="card"`; `bar`
|
|
1324
|
+
* la ignora. Se expone en el host como `data-appearance`.
|
|
1306
1325
|
*/
|
|
1307
|
-
appearance = input('
|
|
1326
|
+
appearance = input('surface', /* @ts-ignore */
|
|
1308
1327
|
...(ngDevMode ? [{ debugName: "appearance" }] : /* istanbul ignore next */ []));
|
|
1309
|
-
/**
|
|
1328
|
+
/**
|
|
1329
|
+
* Título arriba del mensaje. Vacío deja solo el contenido proyectado y, en
|
|
1330
|
+
* `surface`, el layout compacto.
|
|
1331
|
+
*/
|
|
1310
1332
|
title = input('', /* @ts-ignore */
|
|
1311
1333
|
...(ngDevMode ? [{ debugName: "title" }] : /* istanbul ignore next */ []));
|
|
1312
1334
|
dismissible = input(false, { ...(ngDevMode ? { debugName: "dismissible" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
@@ -1319,21 +1341,30 @@ class Alert {
|
|
|
1319
1341
|
*/
|
|
1320
1342
|
ariaRole = computed(() => this.tone() === 'error' || this.tone() === 'warn' ? 'alert' : 'status', /* @ts-ignore */
|
|
1321
1343
|
...(ngDevMode ? [{ debugName: "ariaRole" }] : /* istanbul ignore next */ []));
|
|
1344
|
+
/** Glifo de trazo de `kf-icon`: lo usan `bar` y `solid`. `surface`/`elevated` dibujan el suyo relleno. */
|
|
1322
1345
|
toneIcon = computed(() => TONE_ICON[this.tone()], /* @ts-ignore */
|
|
1323
1346
|
...(ngDevMode ? [{ debugName: "toneIcon" }] : /* istanbul ignore next */ []));
|
|
1324
|
-
/**
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
|
|
1347
|
+
/** Clases del contenedor: tono, forma (`bar` o `card` + apariencia) y si lleva título. */
|
|
1348
|
+
rootClass = computed(() => {
|
|
1349
|
+
const classes = [`kf-alert--${this.tone()}`];
|
|
1350
|
+
if (this.variant() === 'bar') {
|
|
1351
|
+
classes.push('kf-alert--bar');
|
|
1352
|
+
}
|
|
1353
|
+
else {
|
|
1354
|
+
classes.push('kf-alert--card', `kf-alert--${this.appearance()}`);
|
|
1355
|
+
}
|
|
1356
|
+
if (this.title()) {
|
|
1357
|
+
classes.push('kf-alert--titled');
|
|
1358
|
+
}
|
|
1359
|
+
return classes.join(' ');
|
|
1329
1360
|
}, /* @ts-ignore */
|
|
1330
|
-
...(ngDevMode ? [{ debugName: "
|
|
1361
|
+
...(ngDevMode ? [{ debugName: "rootClass" }] : /* istanbul ignore next */ []));
|
|
1331
1362
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: Alert, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1332
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: Alert, isStandalone: true, selector: "kf-alert", inputs: { tone: { classPropertyName: "tone", publicName: "tone", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, appearance: { classPropertyName: "appearance", publicName: "appearance", isSignal: true, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, dismissible: { classPropertyName: "dismissible", publicName: "dismissible", isSignal: true, isRequired: false, transformFunction: null }, open: { classPropertyName: "open", publicName: "open", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { open: "openChange" }, host: { properties: { "attr.data-appearance": "appearance()" } }, ngImport: i0, template: "@if (open()) {\n <div\n class=\"kf-alert\"\n [class]=\"'kf-alert--' + tone()\"\n [class.kf-alert--bar]=\"variant() === 'bar'\"\n [attr.role]=\"ariaRole()\"\n >\n <kf-icon class=\"kf-alert__icon\" [name]=\"toneIcon()\" [size]=\"iconSize()\" />\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{display:flex;align-items:center;gap:var(--kf-space-md);padding:calc(var(--kf-space-sm) + var(--kf-space-xs)) var(--kf-space-md);border:1px solid var(--kf-color-border);border-radius:var(--kf-radius-md);background:var(--kf-color-white);box-shadow:var(--kf-shadow-xs);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)}.kf-alert--ok{--_tone: var(--kf-color-success);--_soft: var(--kf-color-success-soft);--_strong: 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)}.kf-alert--error{--_tone: var(--kf-color-error);--_soft: var(--kf-color-error-soft);--_strong: var(--kf-color-error-strong)}.kf-alert__icon{align-items:center;justify-content:center;inline-size:40px;block-size:40px;border-radius:var(--kf-radius-sm);background:var(--_strong);color:var(--kf-color-white)}.kf-alert__body{display:flex;flex:1 1 0;flex-wrap:wrap;align-items:center;gap:var(--kf-space-md) var(--kf-space-lg);min-width:0}.kf-alert__content{display:flex;flex:1 1 20rem;flex-direction:column;gap:2px;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:calc(var(--kf-space-sm) + var(--kf-space-xs));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:calc(var(--kf-space-sm) + var(--kf-space-xs));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 .14s ease,color .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{gap:var(--kf-space-sm);padding:var(--kf-space-sm) var(--kf-space-md);border-color:color-mix(in srgb,var(--_tone) 40%,var(--_soft));border-width:1px 0;border-radius:0;background:var(--_soft);box-shadow:none}.kf-alert--bar .kf-alert__icon{inline-size:auto;block-size:auto;border-radius:0;background:none;color:var(--_strong)}.kf-alert--bar .kf-alert__body{row-gap:var(--kf-space-sm)}.kf-alert--bar .kf-alert__content{flex-flow:row wrap;align-items:baseline;column-gap: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__close:hover{background:color-mix(in srgb,var(--_strong) 12%,transparent)}:host([data-appearance=\"tint\"]) .kf-alert:not(.kf-alert--bar){padding-block:var(--kf-space-md);border-color:transparent;background:var(--_soft);box-shadow:none}:host([data-appearance=\"tint\"]) .kf-alert:not(.kf-alert--bar) .kf-alert__icon{inline-size:24px;block-size:24px;border-radius:0;background:none;color:var(--_strong)}:host([data-appearance=\"tint\"]) .kf-alert:not(.kf-alert--bar) .kf-alert__close:hover{background:color-mix(in srgb,var(--_strong) 12%,transparent)}:host([data-appearance=\"rail\"]) .kf-alert:not(.kf-alert--bar){gap:0;padding:0}:host([data-appearance=\"rail\"]) .kf-alert:not(.kf-alert--bar) .kf-alert__icon{align-self:stretch;box-sizing:border-box;inline-size:56px;block-size:auto;min-block-size:56px;border-inline-end:1px solid var(--kf-color-border);border-radius:calc(var(--kf-radius-md) - 1px) 0 0 calc(var(--kf-radius-md) - 1px);background:color-mix(in srgb,var(--_tone) 22%,var(--_soft));color:color-mix(in srgb,var(--_strong) 75%,var(--kf-color-ink))}:host([data-appearance=\"rail\"]) .kf-alert:not(.kf-alert--bar) .kf-alert__body{padding:var(--kf-space-md)}:host([data-appearance=\"rail\"]) .kf-alert:not(.kf-alert--bar) .kf-alert__close{margin-inline-end:var(--kf-space-md)}\n"], dependencies: [{ kind: "component", type: Icon, selector: "kf-icon", inputs: ["name", "size", "rotate", "filled"] }] });
|
|
1363
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.0", type: Alert, isStandalone: true, selector: "kf-alert", inputs: { tone: { classPropertyName: "tone", publicName: "tone", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, appearance: { classPropertyName: "appearance", publicName: "appearance", isSignal: true, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, dismissible: { classPropertyName: "dismissible", publicName: "dismissible", isSignal: true, isRequired: false, transformFunction: null }, open: { classPropertyName: "open", publicName: "open", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { open: "openChange" }, host: { properties: { "attr.data-appearance": "appearance()" } }, ngImport: i0, 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 .14s ease,color .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__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)}\n"], dependencies: [{ kind: "component", type: Icon, selector: "kf-icon", inputs: ["name", "size", "rotate", "filled"] }] });
|
|
1333
1364
|
}
|
|
1334
1365
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.0", ngImport: i0, type: Alert, decorators: [{
|
|
1335
1366
|
type: Component,
|
|
1336
|
-
args: [{ selector: 'kf-alert', imports: [Icon], host: { '[attr.data-appearance]': 'appearance()' }, template: "@if (open()) {\n <div\n class=\"kf-alert\"\n [class]=\"'kf-alert--' + tone()\"\n [class.kf-alert--bar]=\"variant() === 'bar'\"\n [attr.role]=\"ariaRole()\"\n >\n <kf-icon class=\"kf-alert__icon\" [name]=\"toneIcon()\" [size]=\"iconSize()\" />\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{display:flex;align-items:center;gap:var(--kf-space-md);padding:calc(var(--kf-space-sm) + var(--kf-space-xs)) var(--kf-space-md);border:1px solid var(--kf-color-border);border-radius:var(--kf-radius-md);background:var(--kf-color-white);box-shadow:var(--kf-shadow-xs);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)}.kf-alert--ok{--_tone: var(--kf-color-success);--_soft: var(--kf-color-success-soft);--_strong: 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)}.kf-alert--error{--_tone: var(--kf-color-error);--_soft: var(--kf-color-error-soft);--_strong: var(--kf-color-error-strong)}.kf-alert__icon{align-items:center;justify-content:center;inline-size:40px;block-size:40px;border-radius:var(--kf-radius-sm);background:var(--_strong);color:var(--kf-color-white)}.kf-alert__body{display:flex;flex:1 1 0;flex-wrap:wrap;align-items:center;gap:var(--kf-space-md) var(--kf-space-lg);min-width:0}.kf-alert__content{display:flex;flex:1 1 20rem;flex-direction:column;gap:2px;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:calc(var(--kf-space-sm) + var(--kf-space-xs));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:calc(var(--kf-space-sm) + var(--kf-space-xs));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 .14s ease,color .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{gap:var(--kf-space-sm);padding:var(--kf-space-sm) var(--kf-space-md);border-color:color-mix(in srgb,var(--_tone) 40%,var(--_soft));border-width:1px 0;border-radius:0;background:var(--_soft);box-shadow:none}.kf-alert--bar .kf-alert__icon{inline-size:auto;block-size:auto;border-radius:0;background:none;color:var(--_strong)}.kf-alert--bar .kf-alert__body{row-gap:var(--kf-space-sm)}.kf-alert--bar .kf-alert__content{flex-flow:row wrap;align-items:baseline;column-gap: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__close:hover{background:color-mix(in srgb,var(--_strong) 12%,transparent)}:host([data-appearance=\"tint\"]) .kf-alert:not(.kf-alert--bar){padding-block:var(--kf-space-md);border-color:transparent;background:var(--_soft);box-shadow:none}:host([data-appearance=\"tint\"]) .kf-alert:not(.kf-alert--bar) .kf-alert__icon{inline-size:24px;block-size:24px;border-radius:0;background:none;color:var(--_strong)}:host([data-appearance=\"tint\"]) .kf-alert:not(.kf-alert--bar) .kf-alert__close:hover{background:color-mix(in srgb,var(--_strong) 12%,transparent)}:host([data-appearance=\"rail\"]) .kf-alert:not(.kf-alert--bar){gap:0;padding:0}:host([data-appearance=\"rail\"]) .kf-alert:not(.kf-alert--bar) .kf-alert__icon{align-self:stretch;box-sizing:border-box;inline-size:56px;block-size:auto;min-block-size:56px;border-inline-end:1px solid var(--kf-color-border);border-radius:calc(var(--kf-radius-md) - 1px) 0 0 calc(var(--kf-radius-md) - 1px);background:color-mix(in srgb,var(--_tone) 22%,var(--_soft));color:color-mix(in srgb,var(--_strong) 75%,var(--kf-color-ink))}:host([data-appearance=\"rail\"]) .kf-alert:not(.kf-alert--bar) .kf-alert__body{padding:var(--kf-space-md)}:host([data-appearance=\"rail\"]) .kf-alert:not(.kf-alert--bar) .kf-alert__close{margin-inline-end:var(--kf-space-md)}\n"] }]
|
|
1367
|
+
args: [{ selector: 'kf-alert', imports: [Icon], host: { '[attr.data-appearance]': 'appearance()' }, 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 .14s ease,color .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__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)}\n"] }]
|
|
1337
1368
|
}], 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 }] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], dismissible: [{ type: i0.Input, args: [{ isSignal: true, alias: "dismissible", required: false }] }], open: [{ type: i0.Input, args: [{ isSignal: true, alias: "open", required: false }] }, { type: i0.Output, args: ["openChange"] }] } });
|
|
1338
1369
|
|
|
1339
1370
|
/**
|