@krizaka/ui 3.76.0 → 3.76.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.
@@ -83,11 +83,11 @@ declare const filterBar: tailwind_variants.TVReturnType<{
83
83
  [key: string]: {
84
84
  [key: string]: tailwind_variants.ClassValue | {
85
85
  root?: tailwind_variants.ClassValue;
86
+ count?: tailwind_variants.ClassValue;
86
87
  controls?: tailwind_variants.ClassValue;
87
88
  active?: tailwind_variants.ClassValue;
88
89
  clear?: tailwind_variants.ClassValue;
89
90
  results?: tailwind_variants.ClassValue;
90
- count?: tailwind_variants.ClassValue;
91
91
  optionCount?: tailwind_variants.ClassValue;
92
92
  trigger?: tailwind_variants.ClassValue;
93
93
  };
@@ -96,11 +96,11 @@ declare const filterBar: tailwind_variants.TVReturnType<{
96
96
  [x: string]: {
97
97
  [x: string]: tailwind_variants.ClassValue | {
98
98
  root?: tailwind_variants.ClassValue;
99
+ count?: tailwind_variants.ClassValue;
99
100
  controls?: tailwind_variants.ClassValue;
100
101
  active?: tailwind_variants.ClassValue;
101
102
  clear?: tailwind_variants.ClassValue;
102
103
  results?: tailwind_variants.ClassValue;
103
- count?: tailwind_variants.ClassValue;
104
104
  optionCount?: tailwind_variants.ClassValue;
105
105
  trigger?: tailwind_variants.ClassValue;
106
106
  };
@@ -118,11 +118,11 @@ declare const filterBar: tailwind_variants.TVReturnType<{
118
118
  [key: string]: {
119
119
  [key: string]: tailwind_variants.ClassValue | {
120
120
  root?: tailwind_variants.ClassValue;
121
+ count?: tailwind_variants.ClassValue;
121
122
  controls?: tailwind_variants.ClassValue;
122
123
  active?: tailwind_variants.ClassValue;
123
124
  clear?: tailwind_variants.ClassValue;
124
125
  results?: tailwind_variants.ClassValue;
125
- count?: tailwind_variants.ClassValue;
126
126
  optionCount?: tailwind_variants.ClassValue;
127
127
  trigger?: tailwind_variants.ClassValue;
128
128
  };
@@ -75,7 +75,7 @@ function Menu({ services, groupBy, columns, aside, chooseLabel, popularLabel, li
75
75
  if (!aside) return list;
76
76
  return /* @__PURE__ */ jsxs("div", { className: "grid items-start gap-6 lg:grid-cols-[minmax(0,1fr)_20rem] lg:gap-12", children: [
77
77
  list,
78
- /* @__PURE__ */ jsx("aside", { className: "kz-shop-aside flex flex-col gap-4", children: aside })
78
+ /* @__PURE__ */ jsx("div", { className: "kz-shop-aside flex flex-col gap-4", children: aside })
79
79
  ] });
80
80
  }
81
81
  function ServicesSection({ variant = "menu", services, title, lead, groupBy = "category", columns = 1, aside, chooseLabel, popularLabel, listLabel, linkAs, className, ...props }) {
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/shop/services/services.tsx"],"sourcesContent":["// Server-safe: no hook. The services of a shop (ADR-007 §3). `menu` — the compact price board, the default of every preset:\n// one row per service (an optional 56 px square thumbnail of the service's own photo, the name, « Popular », a dotted leader,\n// the price in tabular figures, the duration and one line, a « Choose » button that names the service), grouped by category\n// under a lower-case typewriter note, in one column beside an `aside` or in two. `cards` (4:3, six at most), `index` (the\n// Cahier's stamped cards), `carousel` (a snap strip, phone first). The section receives resolved services; it never fetches.\nimport { Badge } from \"@krizaka/ui/badge\";\nimport { buttonVariants } from \"@krizaka/ui/button\";\nimport { ServiceCard } from \"@krizaka/ui/service-card\";\nimport * as React from \"react\";\n\nimport { BlockLink, type LinkComponent } from \"../../block-link\";\nimport { cn } from \"../../cn\";\nimport type { ShopPhoto } from \"../frame\";\nimport { ShopSection } from \"../frame\";\nimport { SHOP_LIMITS } from \"../limits\";\nimport { Photo } from \"../photo\";\n\nexport type ServicesVariant = \"menu\" | \"cards\" | \"index\" | \"carousel\";\n\n/** A service as the product resolved it: its own photo (or none), its price already formatted. */\nexport type ShopService = {\n id: string;\n name: string;\n /** Formatted by the app (`$45`): the section never formats money. */\n price: string;\n /** The word before a varying price (`from`). */\n priceFrom?: string;\n /** `30 min`. */\n duration?: string;\n /** `Up to 5 dogs`. */\n capacity?: string;\n /** One line: what it is (truncated in the menu). */\n description?: string;\n /** What is included, one short line each (cards and index). */\n included?: readonly string[];\n /** The shop's category (`cuts`): the menu's group. */\n category?: string;\n /** The service's OWN photo. Never a default: without one the menu draws no thumbnail. */\n photo?: ShopPhoto;\n /** Booked most often (a real count): wears « Popular ». */\n popular?: boolean;\n /** The booking page with this service chosen. */\n href?: string;\n};\n\nexport type ServicesSectionProps = Omit<React.ComponentProps<\"section\">, \"title\"> & {\n /** @default \"menu\" */\n variant?: ServicesVariant;\n services: readonly ShopService[];\n /** The section's `h2` (`Services`). */\n title: React.ReactNode;\n lead?: React.ReactNode;\n /** `menu`: group by the services' `category`. @default \"category\" */\n groupBy?: \"category\" | \"none\";\n /** `menu` with no `aside`: one or two columns. @default 1 */\n columns?: 1 | 2;\n /** `menu`: the hours, the team and the address, beside the list from `lg` (sticky), below it on a phone. */\n aside?: React.ReactNode;\n /** The button's words (`Choose`); its accessible name is « Choose Short cut ». */\n chooseLabel: string;\n /** « Popular ». */\n popularLabel: string;\n /** The list's accessible name when there is no group (`Services`). */\n listLabel?: string;\n /** The app's link component for the booking addresses. */\n linkAs?: LinkComponent;\n};\n\nconst GROUP_NOTE = \"m-0 font-mono text-[13px] lowercase text-fg-secondary\";\n\nfunction groupsOf(services: readonly ShopService[], by: \"category\" | \"none\") {\n if (by === \"none\") return [{ name: undefined as string | undefined, items: services }];\n const groups: { name: string | undefined; items: ShopService[] }[] = [];\n for (const s of services) {\n const name = s.category;\n const group = groups.find((g) => g.name === name);\n if (group) group.items.push(s);\n else groups.push({ name, items: [s] });\n }\n return groups;\n}\n\nfunction MenuRow({ service, chooseLabel, popularLabel, linkAs }: { service: ShopService; chooseLabel: string; popularLabel: string; linkAs?: LinkComponent }) {\n const facts = [service.duration, service.capacity].filter(Boolean).join(\" · \");\n return (\n <li className=\"flex items-center gap-3 border-b border-border-subtle py-2.5 last:border-b-0\" data-service={service.id}>\n {service.photo && (\n <Photo photo={service.photo} ratio=\"1/1\" sizes=\"56px\" className=\"h-12 w-12 shrink-0 rounded-md sm:h-14 sm:w-14\" />\n )}\n <div className=\"min-w-0 flex-1\">\n <div className=\"flex items-baseline gap-2\">\n <h3 className=\"m-0 shrink truncate text-[15px] font-semibold leading-tight text-fg\">{service.name}</h3>\n {service.popular && <Badge tone=\"accent\" size=\"sm\" className=\"hidden shrink-0 self-center sm:inline-flex\">{popularLabel}</Badge>}\n <span aria-hidden className=\"min-w-4 flex-1 -translate-y-0.5 border-b border-dotted border-border-control\" />\n <span className=\"shrink-0 whitespace-nowrap text-[15px] font-bold tabular-nums text-fg\">\n {service.priceFrom && <span className=\"mr-1 text-xs font-medium text-fg-secondary\">{service.priceFrom}</span>}\n {service.price}\n </span>\n </div>\n <p className=\"m-0 mt-0.5 truncate text-[13px] leading-snug text-fg-secondary\">\n {service.popular && <Badge tone=\"accent\" size=\"sm\" className=\"mr-1.5 sm:hidden\">{popularLabel}</Badge>}\n <span className=\"font-mono tabular-nums\">{facts}</span>\n {facts && service.description && <span aria-hidden> · </span>}\n {service.description}\n </p>\n </div>\n {service.href && (\n <BlockLink\n href={service.href}\n linkAs={linkAs}\n aria-label={`${chooseLabel} ${service.name}`}\n className={cn(buttonVariants({ variant: \"secondary\", size: \"md\" }), \"min-h-11 shrink-0 no-underline\")}\n >\n {chooseLabel}\n </BlockLink>\n )}\n </li>\n );\n}\n\nfunction Menu({ services, groupBy, columns, aside, chooseLabel, popularLabel, listLabel, linkAs }: Required<Pick<ServicesSectionProps, \"services\" | \"groupBy\" | \"columns\" | \"chooseLabel\" | \"popularLabel\">> & Pick<ServicesSectionProps, \"aside\" | \"listLabel\" | \"linkAs\">) {\n const groups = groupsOf(services, groupBy);\n const uid = React.useId();\n const list = (\n <div className={cn(\"grid gap-x-12\", !aside && columns === 2 && \"lg:grid-cols-2\")}>\n {groups.map((g, i) => (\n <div key={g.name ?? i} className=\"mb-3 min-w-0 last:mb-0\">\n {g.name && <p className={GROUP_NOTE} id={`${uid}-grp-${i}`}>{g.name}</p>}\n <ul aria-label={g.name ? undefined : listLabel} aria-labelledby={g.name ? `${uid}-grp-${i}` : undefined} className=\"m-0 list-none p-0\">\n {g.items.map((s) => (\n <MenuRow key={s.id} service={s} chooseLabel={chooseLabel} popularLabel={popularLabel} linkAs={linkAs} />\n ))}\n </ul>\n </div>\n ))}\n </div>\n );\n if (!aside) return list;\n return (\n <div className=\"grid items-start gap-6 lg:grid-cols-[minmax(0,1fr)_20rem] lg:gap-12\">\n {list}\n <aside className=\"kz-shop-aside flex flex-col gap-4\">{aside}</aside>\n </div>\n );\n}\n\n/** The services of a shop: the price board by default, or cards, index cards, a carousel. */\nexport function ServicesSection({ variant = \"menu\", services, title, lead, groupBy = \"category\", columns = 1, aside, chooseLabel, popularLabel, listLabel, linkAs, className, ...props }: ServicesSectionProps) {\n const card = (s: ShopService, i: number, extra?: string) => (\n <ServiceCard\n key={s.id}\n name={s.name}\n price={s.price}\n priceFrom={s.priceFrom}\n duration={s.duration}\n capacity={s.capacity}\n description={s.description}\n included={s.included}\n tag={s.popular ? popularLabel : undefined}\n media={s.photo ? <img src={s.photo.src} srcSet={s.photo.srcSet} sizes=\"(min-width: 64rem) 18rem, 90vw\" alt={s.photo.alt} loading=\"lazy\" decoding=\"async\" /> : undefined}\n mediaRatio=\"photo\"\n variant={variant === \"index\" ? \"index\" : \"default\"}\n actionLabel={chooseLabel}\n href={s.href}\n linkAs={linkAs}\n className={extra}\n data-index={i}\n />\n );\n let body: React.ReactNode;\n if (variant === \"menu\") {\n body = <Menu services={services} groupBy={groupBy} columns={columns} aside={aside} chooseLabel={chooseLabel} popularLabel={popularLabel} listLabel={listLabel} linkAs={linkAs} />;\n } else if (variant === \"carousel\") {\n body = (\n <div role=\"group\" aria-label={listLabel ?? (typeof title === \"string\" ? title : undefined)} tabIndex={0} className=\"-mx-4 flex snap-x snap-mandatory gap-3 overflow-x-auto px-4 pb-2 focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-ring sm:mx-0 sm:px-0\">\n {services.map((s, i) => card(s, i, \"w-[78vw] max-w-72 shrink-0 snap-start sm:w-72\"))}\n </div>\n );\n } else {\n const shown = variant === \"cards\" ? services.slice(0, SHOP_LIMITS.cards) : services;\n body = <div className=\"grid items-start gap-4 sm:grid-cols-2 lg:grid-cols-3\">{shown.map((s, i) => card(s, i, \"h-auto\"))}</div>;\n }\n return (\n <ShopSection title={title} lead={lead} className={className} data-variant={variant} {...props}>\n {body}\n </ShopSection>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;AAKA,SAAS,aAAa;AACtB,SAAS,sBAAsB;AAC/B,SAAS,mBAAmB;AAC5B,YAAY,WAAW;AA+Ef,cAOE,YAPF;AAnBR,IAAM,aAAa;AAEnB,SAAS,SAAS,UAAkC,IAAyB;AAC3E,MAAI,OAAO,OAAQ,QAAO,CAAC,EAAE,MAAM,QAAiC,OAAO,SAAS,CAAC;AACrF,QAAM,SAA+D,CAAC;AACtE,aAAW,KAAK,UAAU;AACxB,UAAM,OAAO,EAAE;AACf,UAAM,QAAQ,OAAO,KAAK,CAAC,MAAM,EAAE,SAAS,IAAI;AAChD,QAAI,MAAO,OAAM,MAAM,KAAK,CAAC;AAAA,QACxB,QAAO,KAAK,EAAE,MAAM,OAAO,CAAC,CAAC,EAAE,CAAC;AAAA,EACvC;AACA,SAAO;AACT;AAEA,SAAS,QAAQ,EAAE,SAAS,aAAa,cAAc,OAAO,GAAgG;AAC5J,QAAM,QAAQ,CAAC,QAAQ,UAAU,QAAQ,QAAQ,EAAE,OAAO,OAAO,EAAE,KAAK,QAAK;AAC7E,SACE,qBAAC,QAAG,WAAU,gFAA+E,gBAAc,QAAQ,IAChH;AAAA,YAAQ,SACP,oBAAC,SAAM,OAAO,QAAQ,OAAO,OAAM,OAAM,OAAM,QAAO,WAAU,iDAAgD;AAAA,IAElH,qBAAC,SAAI,WAAU,kBACb;AAAA,2BAAC,SAAI,WAAU,6BACb;AAAA,4BAAC,QAAG,WAAU,uEAAuE,kBAAQ,MAAK;AAAA,QACjG,QAAQ,WAAW,o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AY;AACjC,WACE,oBAAC,SAAI,MAAK,SAAQ,cAAY,cAAc,OAAO,UAAU,WAAW,QAAQ,SAAY,UAAU,GAAG,WAAU,sKAChH,mBAAS,IAAI,CAAC,GAAG,MAAM,KAAK,GAAG,GAAG,+CAA+C,CAAC,GACrF;AAAA,EAEJ,OAAO;AACL,UAAM,QAAQ,YAAY,UAAU,SAAS,MAAM,GAAG,YAAY,KAAK,IAAI;AAC3E,WAAO,oBAAC,SAAI,WAAU,wDAAwD,gBAAM,IAAI,CAAC,GAAG,MAAM,KAAK,GAAG,GAAG,QAAQ,CAAC,GAAE;AAAA,EAC1H;AACA,SACE,oBAAC,eAAY,OAAc,MAAY,WAAsB,gBAAc,SAAU,GAAG,OACrF,gBACH;AAEJ;","names":[]}
1
+ {"version":3,"sources":["../../src/shop/services/services.tsx"],"sourcesContent":["// Server-safe: no hook. The services of a shop (ADR-007 §3). `menu` — the compact price board, the default of every preset:\n// one row per service (an optional 56 px square thumbnail of the service's own photo, the name, « Popular », a dotted leader,\n// the price in tabular figures, the duration and one line, a « Choose » button that names the service), grouped by category\n// under a lower-case typewriter note, in one column beside an `aside` (a plain block, never a landmark) or in two. `cards` (4:3, six at most), `index` (the\n// Cahier's stamped cards), `carousel` (a snap strip, phone first). The section receives resolved services; it never fetches.\nimport { Badge } from \"@krizaka/ui/badge\";\nimport { buttonVariants } from \"@krizaka/ui/button\";\nimport { ServiceCard } from \"@krizaka/ui/service-card\";\nimport * as React from \"react\";\n\nimport { BlockLink, type LinkComponent } from \"../../block-link\";\nimport { cn } from \"../../cn\";\nimport type { ShopPhoto } from \"../frame\";\nimport { ShopSection } from \"../frame\";\nimport { SHOP_LIMITS } from \"../limits\";\nimport { Photo } from \"../photo\";\n\nexport type ServicesVariant = \"menu\" | \"cards\" | \"index\" | \"carousel\";\n\n/** A service as the product resolved it: its own photo (or none), its price already formatted. */\nexport type ShopService = {\n id: string;\n name: string;\n /** Formatted by the app (`$45`): the section never formats money. */\n price: string;\n /** The word before a varying price (`from`). */\n priceFrom?: string;\n /** `30 min`. */\n duration?: string;\n /** `Up to 5 dogs`. */\n capacity?: string;\n /** One line: what it is (truncated in the menu). */\n description?: string;\n /** What is included, one short line each (cards and index). */\n included?: readonly string[];\n /** The shop's category (`cuts`): the menu's group. */\n category?: string;\n /** The service's OWN photo. Never a default: without one the menu draws no thumbnail. */\n photo?: ShopPhoto;\n /** Booked most often (a real count): wears « Popular ». */\n popular?: boolean;\n /** The booking page with this service chosen. */\n href?: string;\n};\n\nexport type ServicesSectionProps = Omit<React.ComponentProps<\"section\">, \"title\"> & {\n /** @default \"menu\" */\n variant?: ServicesVariant;\n services: readonly ShopService[];\n /** The section's `h2` (`Services`). */\n title: React.ReactNode;\n lead?: React.ReactNode;\n /** `menu`: group by the services' `category`. @default \"category\" */\n groupBy?: \"category\" | \"none\";\n /** `menu` with no `aside`: one or two columns. @default 1 */\n columns?: 1 | 2;\n /** `menu`: the hours, the team and the address, beside the list from `lg` (sticky), below it on a phone. */\n aside?: React.ReactNode;\n /** The button's words (`Choose`); its accessible name is « Choose Short cut ». */\n chooseLabel: string;\n /** « Popular ». */\n popularLabel: string;\n /** The list's accessible name when there is no group (`Services`). */\n listLabel?: string;\n /** The app's link component for the booking addresses. */\n linkAs?: LinkComponent;\n};\n\nconst GROUP_NOTE = \"m-0 font-mono text-[13px] lowercase text-fg-secondary\";\n\nfunction groupsOf(services: readonly ShopService[], by: \"category\" | \"none\") {\n if (by === \"none\") return [{ name: undefined as string | undefined, items: services }];\n const groups: { name: string | undefined; items: ShopService[] }[] = [];\n for (const s of services) {\n const name = s.category;\n const group = groups.find((g) => g.name === name);\n if (group) group.items.push(s);\n else groups.push({ name, items: [s] });\n }\n return groups;\n}\n\nfunction MenuRow({ service, chooseLabel, popularLabel, linkAs }: { service: ShopService; chooseLabel: string; popularLabel: string; linkAs?: LinkComponent }) {\n const facts = [service.duration, service.capacity].filter(Boolean).join(\" · \");\n return (\n <li className=\"flex items-center gap-3 border-b border-border-subtle py-2.5 last:border-b-0\" data-service={service.id}>\n {service.photo && (\n <Photo photo={service.photo} ratio=\"1/1\" sizes=\"56px\" className=\"h-12 w-12 shrink-0 rounded-md sm:h-14 sm:w-14\" />\n )}\n <div className=\"min-w-0 flex-1\">\n <div className=\"flex items-baseline gap-2\">\n <h3 className=\"m-0 shrink truncate text-[15px] font-semibold leading-tight text-fg\">{service.name}</h3>\n {service.popular && <Badge tone=\"accent\" size=\"sm\" className=\"hidden shrink-0 self-center sm:inline-flex\">{popularLabel}</Badge>}\n <span aria-hidden className=\"min-w-4 flex-1 -translate-y-0.5 border-b border-dotted border-border-control\" />\n <span className=\"shrink-0 whitespace-nowrap text-[15px] font-bold tabular-nums text-fg\">\n {service.priceFrom && <span className=\"mr-1 text-xs font-medium text-fg-secondary\">{service.priceFrom}</span>}\n {service.price}\n </span>\n </div>\n <p className=\"m-0 mt-0.5 truncate text-[13px] leading-snug text-fg-secondary\">\n {service.popular && <Badge tone=\"accent\" size=\"sm\" className=\"mr-1.5 sm:hidden\">{popularLabel}</Badge>}\n <span className=\"font-mono tabular-nums\">{facts}</span>\n {facts && service.description && <span aria-hidden> · </span>}\n {service.description}\n </p>\n </div>\n {service.href && (\n <BlockLink\n href={service.href}\n linkAs={linkAs}\n aria-label={`${chooseLabel} ${service.name}`}\n className={cn(buttonVariants({ variant: \"secondary\", size: \"md\" }), \"min-h-11 shrink-0 no-underline\")}\n >\n {chooseLabel}\n </BlockLink>\n )}\n </li>\n );\n}\n\nfunction Menu({ services, groupBy, columns, aside, chooseLabel, popularLabel, listLabel, linkAs }: Required<Pick<ServicesSectionProps, \"services\" | \"groupBy\" | \"columns\" | \"chooseLabel\" | \"popularLabel\">> & Pick<ServicesSectionProps, \"aside\" | \"listLabel\" | \"linkAs\">) {\n const groups = groupsOf(services, groupBy);\n const uid = React.useId();\n const list = (\n <div className={cn(\"grid gap-x-12\", !aside && columns === 2 && \"lg:grid-cols-2\")}>\n {groups.map((g, i) => (\n <div key={g.name ?? i} className=\"mb-3 min-w-0 last:mb-0\">\n {g.name && <p className={GROUP_NOTE} id={`${uid}-grp-${i}`}>{g.name}</p>}\n <ul aria-label={g.name ? undefined : listLabel} aria-labelledby={g.name ? `${uid}-grp-${i}` : undefined} className=\"m-0 list-none p-0\">\n {g.items.map((s) => (\n <MenuRow key={s.id} service={s} chooseLabel={chooseLabel} popularLabel={popularLabel} linkAs={linkAs} />\n ))}\n </ul>\n </div>\n ))}\n </div>\n );\n if (!aside) return list;\n return (\n <div className=\"grid items-start gap-6 lg:grid-cols-[minmax(0,1fr)_20rem] lg:gap-12\">\n {list}\n <div className=\"kz-shop-aside flex flex-col gap-4\">{aside}</div>\n </div>\n );\n}\n\n/** The services of a shop: the price board by default, or cards, index cards, a carousel. */\nexport function ServicesSection({ variant = \"menu\", services, title, lead, groupBy = \"category\", columns = 1, aside, chooseLabel, popularLabel, listLabel, linkAs, className, ...props }: ServicesSectionProps) {\n const card = (s: ShopService, i: number, extra?: string) => (\n <ServiceCard\n key={s.id}\n name={s.name}\n price={s.price}\n priceFrom={s.priceFrom}\n duration={s.duration}\n capacity={s.capacity}\n description={s.description}\n included={s.included}\n tag={s.popular ? popularLabel : undefined}\n media={s.photo ? <img src={s.photo.src} srcSet={s.photo.srcSet} sizes=\"(min-width: 64rem) 18rem, 90vw\" alt={s.photo.alt} loading=\"lazy\" decoding=\"async\" /> : undefined}\n mediaRatio=\"photo\"\n variant={variant === \"index\" ? \"index\" : \"default\"}\n actionLabel={chooseLabel}\n href={s.href}\n linkAs={linkAs}\n className={extra}\n data-index={i}\n />\n );\n let body: React.ReactNode;\n if (variant === \"menu\") {\n body = <Menu services={services} groupBy={groupBy} columns={columns} aside={aside} chooseLabel={chooseLabel} popularLabel={popularLabel} listLabel={listLabel} linkAs={linkAs} />;\n } else if (variant === \"carousel\") {\n body = (\n <div role=\"group\" aria-label={listLabel ?? (typeof title === \"string\" ? title : undefined)} tabIndex={0} className=\"-mx-4 flex snap-x snap-mandatory gap-3 overflow-x-auto px-4 pb-2 focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-ring sm:mx-0 sm:px-0\">\n {services.map((s, i) => card(s, i, \"w-[78vw] max-w-72 shrink-0 snap-start sm:w-72\"))}\n </div>\n );\n } else {\n const shown = variant === \"cards\" ? services.slice(0, SHOP_LIMITS.cards) : services;\n body = <div className=\"grid items-start gap-4 sm:grid-cols-2 lg:grid-cols-3\">{shown.map((s, i) => card(s, i, \"h-auto\"))}</div>;\n }\n return (\n <ShopSection title={title} lead={lead} className={className} data-variant={variant} {...props}>\n {body}\n </ShopSection>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;AAKA,SAAS,aAAa;AACtB,SAAS,sBAAsB;AAC/B,SAAS,mBAAmB;AAC5B,YAAY,WAAW;AA+Ef,cAOE,YAPF;AAnBR,IAAM,aAAa;AAEnB,SAAS,SAAS,UAAkC,IAAyB;AAC3E,MAAI,OAAO,OAAQ,QAAO,CAAC,EAAE,MAAM,QAAiC,OAAO,SAAS,CAAC;AACrF,QAAM,SAA+D,CAAC;AACtE,aAAW,KAAK,UAAU;AACxB,UAAM,OAAO,EAAE;AACf,UAAM,QAAQ,OAAO,KAAK,CAAC,MAAM,EAAE,SAAS,IAAI;AAChD,QAAI,MAAO,OAAM,MAAM,KAAK,CAAC;AAAA,QACxB,QAAO,KAAK,EAAE,MAAM,OAAO,CAAC,CAAC,EAAE,CAAC;AAAA,EACvC;AACA,SAAO;AACT;AAEA,SAAS,QAAQ,EAAE,SAAS,aAAa,cAAc,OAAO,GAAgG;AAC5J,QAAM,QAAQ,CAAC,QAAQ,UAAU,QAAQ,QAAQ,EAAE,OAAO,OAAO,EAAE,KAAK,QAAK;AAC7E,SACE,qBAAC,QAAG,WAAU,gFAA+E,gBAAc,QAAQ,IAChH;AAAA,YAAQ,SACP,oBAAC,SAAM,OAAO,QAAQ,OAAO,OAAM,OAAM,OAAM,QAAO,WAAU,iDAAgD;AAAA,IAElH,qBAAC,SAAI,WAAU,kBACb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ACtB,WAAO,oBAAC,QAAK,UAAoB,SAAkB,SAAkB,OAAc,aAA0B,cAA4B,WAAsB,QAAgB;AAAA,EACjL,WAAW,YAAY,YAAY;AACjC,WACE,oBAAC,SAAI,MAAK,SAAQ,cAAY,cAAc,OAAO,UAAU,WAAW,QAAQ,SAAY,UAAU,GAAG,WAAU,sKAChH,mBAAS,IAAI,CAAC,GAAG,MAAM,KAAK,GAAG,GAAG,+CAA+C,CAAC,GACrF;AAAA,EAEJ,OAAO;AACL,UAAM,QAAQ,YAAY,UAAU,SAAS,MAAM,GAAG,YAAY,KAAK,IAAI;AAC3E,WAAO,oBAAC,SAAI,WAAU,wDAAwD,gBAAM,IAAI,CAAC,GAAG,MAAM,KAAK,GAAG,GAAG,QAAQ,CAAC,GAAE;AAAA,EAC1H;AACA,SACE,oBAAC,eAAY,OAAc,MAAY,WAAsB,gBAAc,SAAU,GAAG,OACrF,gBACH;AAEJ;","names":[]}
@@ -1394,7 +1394,7 @@ function Menu({ services, groupBy, columns, aside, chooseLabel, popularLabel, li
1394
1394
  if (!aside) return list;
1395
1395
  return /* @__PURE__ */ jsxs11("div", { className: "grid items-start gap-6 lg:grid-cols-[minmax(0,1fr)_20rem] lg:gap-12", children: [
1396
1396
  list,
1397
- /* @__PURE__ */ jsx15("aside", { className: "kz-shop-aside flex flex-col gap-4", children: aside })
1397
+ /* @__PURE__ */ jsx15("div", { className: "kz-shop-aside flex flex-col gap-4", children: aside })
1398
1398
  ] });
1399
1399
  }
1400
1400
  function ServicesSection({ variant = "menu", services, title, lead: lead2, groupBy = "category", columns = 1, aside, chooseLabel, popularLabel, listLabel, linkAs, className, ...props }) {