@ajuarezso/sui-design-system 0.24.1 → 0.25.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/docs/sui-accordion/README.md +85 -11
- package/docs/sui-activity-feed/README.md +65 -11
- package/docs/sui-activity-filter/README.md +54 -5
- package/docs/sui-alert/README.md +54 -0
- package/docs/sui-app-store-badge/README.md +64 -10
- package/docs/sui-avatar/README.md +92 -29
- package/docs/sui-avatar-group/README.md +75 -9
- package/docs/sui-badge/README.md +85 -17
- package/docs/sui-banner/README.md +85 -20
- package/docs/sui-brand-logo/README.md +95 -31
- package/docs/sui-breadcrumb-item/README.md +54 -3
- package/docs/sui-breadcrumbs/README.md +54 -6
- package/docs/sui-button/README.md +76 -12
- package/docs/sui-button-group/README.md +91 -23
- package/docs/sui-button-group-item/README.md +81 -14
- package/docs/sui-card/README.md +105 -18
- package/docs/sui-chart-legend/README.md +63 -10
- package/docs/sui-chart-legend-dot/README.md +59 -10
- package/docs/sui-checkbox/README.md +109 -29
- package/docs/sui-checkbox-card/README.md +70 -14
- package/docs/sui-checkbox-label/README.md +92 -26
- package/docs/sui-circular-progress-bar/README.md +80 -19
- package/docs/sui-color-dot/README.md +72 -12
- package/docs/sui-color-picker/README.md +71 -13
- package/docs/sui-command-menu-footer/README.md +50 -1
- package/docs/sui-command-menu-item/README.md +74 -14
- package/docs/sui-command-menu-search/README.md +58 -3
- package/docs/sui-compact-avatar-group/README.md +73 -13
- package/docs/sui-compact-button/README.md +123 -34
- package/docs/sui-compact-select/README.md +61 -7
- package/docs/sui-compact-select-for-input/README.md +70 -6
- package/docs/sui-content-card/README.md +75 -14
- package/docs/sui-content-divider/README.md +67 -16
- package/docs/sui-content-label/README.md +99 -20
- package/docs/sui-counter-input/README.md +102 -18
- package/docs/sui-date-selector/README.md +69 -11
- package/docs/sui-datepicker/README.md +85 -18
- package/docs/sui-day-cell/README.md +75 -17
- package/docs/sui-day-label/README.md +56 -7
- package/docs/sui-divider/README.md +64 -9
- package/docs/sui-drawer-footer/README.md +63 -2
- package/docs/sui-drawer-header/README.md +69 -12
- package/docs/sui-dropdown-caption/README.md +58 -6
- package/docs/sui-dropdown-item/README.md +75 -9
- package/docs/sui-dropdown-menu/README.md +83 -14
- package/docs/sui-dropdown-search/README.md +60 -4
- package/docs/sui-emoji/README.md +94 -30
- package/docs/sui-empty-state/README.md +71 -7
- package/docs/sui-fancy-button/README.md +74 -14
- package/docs/sui-file-icon/README.md +70 -12
- package/docs/sui-file-upload/README.md +77 -17
- package/docs/sui-file-upload-card/README.md +64 -12
- package/docs/sui-filter/README.md +83 -14
- package/docs/sui-flag/README.md +73 -8
- package/docs/sui-form-hint/README.md +56 -7
- package/docs/sui-form-label/README.md +57 -5
- package/docs/sui-href/README.md +47 -0
- package/docs/sui-icon/README.md +86 -18
- package/docs/sui-image-upload/README.md +90 -22
- package/docs/sui-image-upload-profile/README.md +70 -11
- package/docs/sui-img-retry/README.md +50 -1
- package/docs/sui-inline-input/README.md +67 -9
- package/docs/sui-inline-select/README.md +62 -2
- package/docs/sui-input/README.md +90 -27
- package/docs/sui-integration-switch/README.md +84 -17
- package/docs/sui-kbd/README.md +73 -9
- package/docs/sui-key-icon/README.md +85 -23
- package/docs/sui-link-button/README.md +96 -27
- package/docs/sui-logo/README.md +93 -22
- package/docs/sui-modal/README.md +72 -13
- package/docs/sui-modal-footer/README.md +86 -12
- package/docs/sui-modal-header/README.md +57 -1
- package/docs/sui-modal-sheet/README.md +74 -12
- package/docs/sui-notification/README.md +81 -11
- package/docs/sui-notification-footer/README.md +55 -5
- package/docs/sui-notification-tab-menu/README.md +61 -5
- package/docs/sui-otp-input/README.md +70 -9
- package/docs/sui-page-header/README.md +89 -19
- package/docs/sui-pagination/README.md +73 -13
- package/docs/sui-password-strength/README.md +50 -1
- package/docs/sui-payment-icon/README.md +80 -18
- package/docs/sui-period-range/README.md +70 -11
- package/docs/sui-popover/README.md +81 -15
- package/docs/sui-product-card/README.md +89 -21
- package/docs/sui-progress-bar/README.md +82 -15
- package/docs/sui-progress-bar-label/README.md +79 -18
- package/docs/sui-radio/README.md +84 -7
- package/docs/sui-radio-card/README.md +70 -16
- package/docs/sui-radio-label/README.md +89 -22
- package/docs/sui-rating/README.md +101 -31
- package/docs/sui-rich-editor/README.md +47 -2
- package/docs/sui-segmented-control/README.md +90 -21
- package/docs/sui-select/README.md +80 -11
- package/docs/sui-sidebar/README.md +71 -16
- package/docs/sui-slider/README.md +75 -8
- package/docs/sui-social-button/README.md +71 -11
- package/docs/sui-status-badge/README.md +75 -14
- package/docs/sui-stepper/README.md +75 -18
- package/docs/sui-store-card/README.md +85 -22
- package/docs/sui-switch/README.md +82 -11
- package/docs/sui-switch-card/README.md +80 -16
- package/docs/sui-switch-label/README.md +91 -14
- package/docs/sui-tab-chips/README.md +93 -21
- package/docs/sui-tab-menu-horizontal/README.md +68 -7
- package/docs/sui-tab-menu-vertical/README.md +64 -11
- package/docs/sui-table/README.md +77 -16
- package/docs/sui-tag/README.md +86 -12
- package/docs/sui-tag-input/README.md +77 -13
- package/docs/sui-textarea/README.md +84 -17
- package/docs/sui-time-picker/README.md +96 -33
- package/docs/sui-toast/README.md +81 -20
- package/docs/sui-tooltip/README.md +80 -22
- package/docs/sui-topbar/README.md +64 -10
- package/docs/sui-topbar-button/README.md +61 -7
- package/docs/sui-topbar-item/README.md +68 -7
- package/docs/sui-topbar-user/README.md +61 -5
- package/fesm2022/ajuarezso-sui-design-system.mjs +15 -10
- package/fesm2022/ajuarezso-sui-design-system.mjs.map +1 -1
- package/package.json +1 -1
- package/types/ajuarezso-sui-design-system.d.ts +7 -3
|
@@ -24,15 +24,15 @@ nombre y un menú (perfil, cambiar de rol, salir). Dentro de `sui-topbar` sale d
|
|
|
24
24
|
## Qué variante usar
|
|
25
25
|
|
|
26
26
|
> **La guía del DS no tiene página de este chip.** Sale del Figma de SUI (User Profile [Topbar],
|
|
27
|
-
> set 3814:24667: Default, Hover, Active). Uso medido el 03-10-2026: **0 usos** en la app.
|
|
28
|
-
>
|
|
27
|
+
> set 3814:24667: Default, Hover, Active). Uso medido el 03-10-2026: **0 usos** en la app. Las reglas
|
|
28
|
+
> marcadas canon están aprobadas (05-10-2026) y no queda ninguna en propuesta.
|
|
29
29
|
|
|
30
30
|
| prop | cuándo | fuente |
|
|
31
31
|
|---|---|---|
|
|
32
32
|
| `avatar` (string) | La URL de la foto. Siempre de `avatarUrl`, nunca de `photoURL`. | canon (CLAUDE.md, «Fotos de otra persona») |
|
|
33
|
-
| `avatar` (objeto) | Sin foto: `{ initials, color }`
|
|
33
|
+
| `avatar` (objeto) | Sin foto: `{ initials, color }` con el color del rol: `orange` local, `green` repartidor, `blue` cliente. | canon (decisión del dueño, color de avatar sin foto por rol; README de `sui-avatar`, 03-10-2026) |
|
|
34
34
|
| `name` | El nombre corto («Sophia», no el correo). Vacío = chip solo con la foto, para barras angostas. | Figma (name=false) |
|
|
35
|
-
| `verified` | No usar hoy: la app no verifica cuentas de personas. |
|
|
35
|
+
| `verified` | No usar hoy: la app no verifica cuentas de personas. | canon (aprobado por el dueño, 05-10-2026, bloque B6) |
|
|
36
36
|
| `open` | Mientras el menú de la cuenta está abierto (flecha hacia arriba, `aria-expanded`). | Figma (State=Active) |
|
|
37
37
|
|
|
38
38
|
## Tamaño en mobile y en web
|
|
@@ -42,7 +42,20 @@ topbar, que hoy es solo de escritorio.
|
|
|
42
42
|
|
|
43
43
|
| uso | mobile | web | fuente |
|
|
44
44
|
|---|---|---|---|
|
|
45
|
-
| cuenta en la barra superior | no usar (en mobile la cuenta va en el cajón del sidebar) | con nombre |
|
|
45
|
+
| cuenta en la barra superior | no usar (en mobile la cuenta va en el cajón del sidebar) | con nombre | canon (aprobado por el dueño, 05-10-2026, bloque B7) |
|
|
46
|
+
|
|
47
|
+
### Por dispositivo (D16)
|
|
48
|
+
|
|
49
|
+
No aplica una tabla: no tiene input `size`; mide 40 de alto con el avatar en `md` (32) fijo, en
|
|
50
|
+
todos los dispositivos. Como se toca y no tiene un size que llegue a 44, B7 lo saca de todo lo
|
|
51
|
+
táctil: en el celular chico, el celular y la tablet táctil **no se usa** (la cuenta va en el cajón
|
|
52
|
+
del sidebar); solo en la computadora (`pointer: fine`) y en el ultrawide, igual que en la
|
|
53
|
+
computadora. La columna «mobile» de D16 incluye la tablet en lo que se toca, así que el «no usar en
|
|
54
|
+
mobile» de B7 la cubre. El avatar no se pasa por `bp.sizeAvatar()`.
|
|
55
|
+
|
|
56
|
+
En master-pedidos: sin `[size]` ni helper; si algún día se monta, va detrás de `@if (!bp.tactil())`
|
|
57
|
+
(`isMobile() || toque()`: todo celular por ancho y toda pantalla táctil). No `!bp.isMobile()`: ese
|
|
58
|
+
es solo por ancho (≤ 768) y deja pasar un iPad de 769 a 1024 con `pointer: coarse`.
|
|
46
59
|
|
|
47
60
|
## API
|
|
48
61
|
|
|
@@ -72,6 +85,49 @@ topbar, que hoy es solo de escritorio.
|
|
|
72
85
|
barra de quien mira funciona, pero sigue siendo regla usar `avatarUrl`.
|
|
73
86
|
- Ya trae el arreglo de iOS para el `:active` pegado.
|
|
74
87
|
|
|
88
|
+
## Bien y mal
|
|
89
|
+
|
|
90
|
+
La foto y el nombre de la cuenta
|
|
91
|
+
|
|
92
|
+
```html
|
|
93
|
+
<!-- ❌ mal: el correo empuja la barra y photoURL puede ser la foto de Google -->
|
|
94
|
+
<sui-topbar-user [name]="usuario().email" [avatar]="usuario().photoURL"
|
|
95
|
+
(clicked)="menuCuenta.set(!menuCuenta())" />
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
```html
|
|
99
|
+
<!-- ✅ bien -->
|
|
100
|
+
<sui-topbar-user [name]="usuario().nombre"
|
|
101
|
+
[avatar]="usuario().avatarUrl || { initials: usuario().iniciales, color: 'orange' }"
|
|
102
|
+
[open]="menuCuenta()" (clicked)="menuCuenta.set(!menuCuenta())" />
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
Sin foto
|
|
106
|
+
|
|
107
|
+
```html
|
|
108
|
+
<!-- ❌ mal: sin avatar sale la silueta gris, y verified no se usa en esta app -->
|
|
109
|
+
<sui-topbar-user name="Sophia" [verified]="true" />
|
|
110
|
+
```
|
|
111
|
+
|
|
112
|
+
```html
|
|
113
|
+
<!-- ✅ bien -->
|
|
114
|
+
<sui-topbar-user name="Sophia" [avatar]="{ initials: 'S', color: 'orange' }" />
|
|
115
|
+
```
|
|
116
|
+
|
|
117
|
+
El repartidor de un pedido
|
|
118
|
+
|
|
119
|
+
```html
|
|
120
|
+
<!-- ❌ mal: es otra persona; la flecha promete un menú que no existe -->
|
|
121
|
+
<sui-topbar-user [name]="pedido().repartidorNombre" [avatar]="pedido().repartidorFoto" />
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
```html
|
|
125
|
+
<!-- ✅ bien -->
|
|
126
|
+
<sui-avatar [size]="bp.sizeAvatar('md')" [src]="pedido().repartidorFoto"
|
|
127
|
+
[alt]="pedido().repartidorNombre" />
|
|
128
|
+
<span>{{ pedido().repartidorNombre }}</span>
|
|
129
|
+
```
|
|
130
|
+
|
|
75
131
|
## Ejemplo
|
|
76
132
|
|
|
77
133
|
```html
|
|
@@ -4105,8 +4105,8 @@ class SuiColorPicker {
|
|
|
4105
4105
|
* Default `null` = sin valor seleccionado.
|
|
4106
4106
|
*/
|
|
4107
4107
|
value = model(null, ...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
|
|
4108
|
-
/** Label visible cuando no hay color seleccionado. */
|
|
4109
|
-
placeholder = input('
|
|
4108
|
+
/** Label visible cuando no hay color seleccionado. Imperativo con tuteo (dueño, 05-10-2026, P4 a). */
|
|
4109
|
+
placeholder = input('Elige un color', ...(ngDevMode ? [{ debugName: "placeholder" }] : /* istanbul ignore next */ []));
|
|
4110
4110
|
/** Etiqueta de la sección Recommended Colors dentro del panel. */
|
|
4111
4111
|
recommendedLabel = input('Colores recomendados', ...(ngDevMode ? [{ debugName: "recommendedLabel" }] : /* istanbul ignore next */ []));
|
|
4112
4112
|
/** Si true, oculta el HSV spectrum + sliders + hex input — solo grid de presets. */
|
|
@@ -7296,8 +7296,9 @@ class SuiDatepicker {
|
|
|
7296
7296
|
inline = input(false, ...(ngDevMode ? [{ debugName: "inline" }] : /* istanbul ignore next */ []));
|
|
7297
7297
|
/** Alto del campo: small 36 · medium 40 (default) · large 48 · xlarge 52 con días de 44 (ver SuiDatepickerSize). */
|
|
7298
7298
|
size = input('medium', ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
7299
|
-
/** Placeholder del
|
|
7300
|
-
|
|
7299
|
+
/** Placeholder del campo cuando no hay valor. Sin pasarlo: «Elige una fecha» (`date`) o
|
|
7300
|
+
* «Elige el período» (`range`), en imperativo con tuteo (dueño, 05-10-2026, P4 a). */
|
|
7301
|
+
placeholder = input(null, ...(ngDevMode ? [{ debugName: "placeholder" }] : /* istanbul ignore next */ []));
|
|
7301
7302
|
/** Si true, muestra Cancel/Apply en el footer. Range siempre lo muestra. */
|
|
7302
7303
|
showFooter = input(true, ...(ngDevMode ? [{ debugName: "showFooter" }] : /* istanbul ignore next */ []));
|
|
7303
7304
|
disabled = input(false, ...(ngDevMode ? [{ debugName: "disabled" }] : /* istanbul ignore next */ []));
|
|
@@ -7463,11 +7464,13 @@ class SuiDatepicker {
|
|
|
7463
7464
|
/** Preset «Todo el tiempo» aplicado: su valor es `{ start: null, end: null }`,
|
|
7464
7465
|
* igual que «nada elegido», así que se recuerda aparte para el trigger. */
|
|
7465
7466
|
_todoElTiempoAplicado = signal(false, ...(ngDevMode ? [{ debugName: "_todoElTiempoAplicado" }] : /* istanbul ignore next */ []));
|
|
7467
|
+
/** El placeholder que se ve: el que se pasó o, si no, el de fábrica según `mode`. */
|
|
7468
|
+
resolvedPlaceholder = computed(() => this.placeholder() ?? (this.mode() === 'range' ? 'Elige el período' : 'Elige una fecha'), ...(ngDevMode ? [{ debugName: "resolvedPlaceholder" }] : /* istanbul ignore next */ []));
|
|
7466
7469
|
/** Texto del trigger input. */
|
|
7467
7470
|
triggerText = computed(() => {
|
|
7468
7471
|
const v = this.value();
|
|
7469
7472
|
if (!v)
|
|
7470
|
-
return this.
|
|
7473
|
+
return this.resolvedPlaceholder();
|
|
7471
7474
|
if (v instanceof Date)
|
|
7472
7475
|
return formatDateInput(v);
|
|
7473
7476
|
if (v.start && v.end)
|
|
@@ -7477,12 +7480,12 @@ class SuiDatepicker {
|
|
|
7477
7480
|
// Fix 04-10-2026: con «Todo el tiempo» el campo mostraba el placeholder,
|
|
7478
7481
|
// como si estuviera vacío.
|
|
7479
7482
|
if (this._todoElTiempoAplicado()) {
|
|
7480
|
-
return this.presets().find(p => p.id === 'all-time')?.label ?? this.
|
|
7483
|
+
return this.presets().find(p => p.id === 'all-time')?.label ?? this.resolvedPlaceholder();
|
|
7481
7484
|
}
|
|
7482
|
-
return this.
|
|
7485
|
+
return this.resolvedPlaceholder();
|
|
7483
7486
|
}, ...(ngDevMode ? [{ debugName: "triggerText" }] : /* istanbul ignore next */ []));
|
|
7484
7487
|
/** ¿El trigger muestra un valor (no el placeholder)? Pinta el texto oscuro. */
|
|
7485
|
-
hasDisplayValue = computed(() => this.triggerText() !== this.
|
|
7488
|
+
hasDisplayValue = computed(() => this.triggerText() !== this.resolvedPlaceholder(), ...(ngDevMode ? [{ debugName: "hasDisplayValue" }] : /* istanbul ignore next */ []));
|
|
7486
7489
|
/** Nombre del panel para el lector de pantalla (role dialog / group). */
|
|
7487
7490
|
panelAriaLabel = computed(() => this.mode() === 'range' ? 'Elegir período' : 'Elegir fecha', ...(ngDevMode ? [{ debugName: "panelAriaLabel" }] : /* istanbul ignore next */ []));
|
|
7488
7491
|
/** «martes 7 de octubre de 2026» para cada celda (antes «Día 7»). */
|
|
@@ -9630,7 +9633,8 @@ class SuiImageUpload {
|
|
|
9630
9633
|
resolvedTitle = computed(() => {
|
|
9631
9634
|
if (this.title())
|
|
9632
9635
|
return this.title();
|
|
9633
|
-
|
|
9636
|
+
// Imperativo con tuteo (dueño, 05-10-2026, P4 a).
|
|
9637
|
+
return this.shape() === 'circle' ? 'Sube tu foto' : 'Sube tu logo';
|
|
9634
9638
|
}, ...(ngDevMode ? [{ debugName: "resolvedTitle" }] : /* istanbul ignore next */ []));
|
|
9635
9639
|
resolvedSubtitle = computed(() => {
|
|
9636
9640
|
if (this.subtitle())
|
|
@@ -19826,7 +19830,8 @@ class SuiTimePicker {
|
|
|
19826
19830
|
hint = input(null, ...(ngDevMode ? [{ debugName: "hint" }] : /* istanbul ignore next */ []));
|
|
19827
19831
|
errorMessage = input(null, ...(ngDevMode ? [{ debugName: "errorMessage" }] : /* istanbul ignore next */ []));
|
|
19828
19832
|
error = input(false, ...(ngDevMode ? [{ debugName: "error" }] : /* istanbul ignore next */ []));
|
|
19829
|
-
|
|
19833
|
+
/** Texto del campo sin hora. Imperativo con tuteo (dueño, 05-10-2026, P4 a). */
|
|
19834
|
+
placeholder = input('Elige una hora', ...(ngDevMode ? [{ debugName: "placeholder" }] : /* istanbul ignore next */ []));
|
|
19830
19835
|
disabled = input(false, ...(ngDevMode ? [{ debugName: "disabled" }] : /* istanbul ignore next */ []));
|
|
19831
19836
|
/**
|
|
19832
19837
|
* Alto del campo: small 36 · medium 40 (default) · large 48 (extensión SUI,
|