@axzydev/axzy_ui_system 1.8.6 → 1.8.8

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/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "packageManager": "pnpm@10.34.0",
5
5
  "private": false,
6
6
  "license": "MIT",
7
- "version": "1.8.6",
7
+ "version": "1.8.8",
8
8
  "type": "module",
9
9
  "sideEffects": [
10
10
  "*.css"
@@ -422,6 +422,11 @@ export interface ITBentoStatStripProps {
422
422
  onSelect?: (id: string) => void;
423
423
  /** Dibuja la barra apilada con la proporción de cada cifra. */
424
424
  stack?: boolean;
425
+ /**
426
+ * Cifras que forman la barra, cuando no todas las de la tira se suman
427
+ * (p. ej. «sin asignar» es un subconjunto de «abiertos»). Por defecto usa `items`.
428
+ */
429
+ stackItems?: ITBentoStatItem[];
425
430
  className?: string;
426
431
  }
427
432
 
@@ -430,10 +435,11 @@ export interface ITBentoStatStripProps {
430
435
  * por línea fina y, si se pide, la barra apilada con la proporción de cada uno.
431
436
  * Al pasar el cursor por un bloque se resalta su segmento de la barra.
432
437
  */
433
- export function ITBentoStatStrip({ items, activeId, onSelect, stack = false, className }: ITBentoStatStripProps) {
438
+ export function ITBentoStatStrip({ items, activeId, onSelect, stack = false, stackItems, className }: ITBentoStatStripProps) {
434
439
  const [hovered, setHovered] = useState<string | null>(null);
435
440
  const focus = hovered ?? activeId ?? null;
436
- const total = items.reduce((acc, item) => acc + (typeof item.value === "number" ? item.value : 0), 0);
441
+ const parts = stackItems ?? items;
442
+ const total = parts.reduce((acc, item) => acc + (typeof item.value === "number" ? item.value : 0), 0);
437
443
  const clickable = typeof onSelect === "function";
438
444
 
439
445
  return (
@@ -467,7 +473,7 @@ export function ITBentoStatStrip({ items, activeId, onSelect, stack = false, cla
467
473
 
468
474
  {stack && total > 0 && (
469
475
  <div className={clsx("it-bento-statstrip__stack", focus && "is-dim")} aria-hidden>
470
- {items
476
+ {parts
471
477
  .filter((item) => typeof item.value === "number" && item.value > 0)
472
478
  .map((item) => (
473
479
  <i
package/src/index.css CHANGED
@@ -912,8 +912,8 @@
912
912
  }
913
913
 
914
914
  .it-bento-statstrip__item.is-on {
915
- background: color-mix(in srgb, currentColor 4%, transparent);
916
- box-shadow: inset 0 -3px 0 var(--it-bento-c, currentColor);
915
+ background: color-mix(in srgb, currentColor 2.5%, transparent);
916
+ box-shadow: inset 0 -2px 0 color-mix(in srgb, var(--it-bento-c, currentColor) 70%, transparent);
917
917
  }
918
918
 
919
919
  .it-bento-statstrip__item:focus-visible {
@@ -978,9 +978,9 @@
978
978
  .it-bento-statstrip__stack {
979
979
  display: flex;
980
980
  gap: 2px;
981
- height: 14px;
982
- margin: 6px 20px 14px;
983
- border-radius: 9px;
981
+ height: 9px;
982
+ margin: 4px 20px 12px;
983
+ border-radius: 6px;
984
984
  overflow: hidden;
985
985
  }
986
986