@cellarnode/ui 0.2.0 → 0.3.0
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/README.md +238 -0
- package/dist/globe/country-coords.d.ts +29 -0
- package/dist/globe/country-coords.d.ts.map +1 -0
- package/dist/globe/country-coords.js +117 -0
- package/dist/globe/country-coords.js.map +1 -0
- package/dist/globe/globe-loading-skeleton.d.ts +10 -0
- package/dist/globe/globe-loading-skeleton.d.ts.map +1 -0
- package/dist/globe/globe-loading-skeleton.js +23 -0
- package/dist/globe/globe-loading-skeleton.js.map +1 -0
- package/dist/globe/index.d.ts +2 -0
- package/dist/globe/index.d.ts.map +1 -1
- package/dist/globe/index.js +2 -0
- package/dist/globe/index.js.map +1 -1
- package/dist/hooks/use-deferred-mount.d.ts +16 -0
- package/dist/hooks/use-deferred-mount.d.ts.map +1 -0
- package/dist/hooks/use-deferred-mount.js +32 -0
- package/dist/hooks/use-deferred-mount.js.map +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/nav/app-shell.d.ts +18 -0
- package/dist/nav/app-shell.d.ts.map +1 -0
- package/dist/nav/app-shell.js +9 -0
- package/dist/nav/app-shell.js.map +1 -0
- package/dist/nav/app-sidebar.d.ts +33 -0
- package/dist/nav/app-sidebar.d.ts.map +1 -0
- package/dist/nav/app-sidebar.js +46 -0
- package/dist/nav/app-sidebar.js.map +1 -0
- package/dist/nav/expandable-nav-item.d.ts +11 -0
- package/dist/nav/expandable-nav-item.d.ts.map +1 -0
- package/dist/nav/expandable-nav-item.js +27 -0
- package/dist/nav/expandable-nav-item.js.map +1 -0
- package/dist/nav/index.d.ts +6 -0
- package/dist/nav/index.d.ts.map +1 -0
- package/dist/nav/index.js +5 -0
- package/dist/nav/index.js.map +1 -0
- package/dist/nav/types.d.ts +40 -0
- package/dist/nav/types.d.ts.map +1 -0
- package/dist/nav/types.js +4 -0
- package/dist/nav/types.js.map +1 -0
- package/dist/offer/beverage-details.d.ts +23 -0
- package/dist/offer/beverage-details.d.ts.map +1 -0
- package/dist/offer/beverage-details.js +41 -0
- package/dist/offer/beverage-details.js.map +1 -0
- package/dist/offer/composition-list.d.ts +9 -0
- package/dist/offer/composition-list.d.ts.map +1 -0
- package/dist/offer/composition-list.js +9 -0
- package/dist/offer/composition-list.js.map +1 -0
- package/dist/offer/index.d.ts +12 -0
- package/dist/offer/index.d.ts.map +1 -1
- package/dist/offer/index.js +6 -0
- package/dist/offer/index.js.map +1 -1
- package/dist/offer/opportunity-requirements.d.ts +31 -0
- package/dist/offer/opportunity-requirements.d.ts.map +1 -0
- package/dist/offer/opportunity-requirements.js +54 -0
- package/dist/offer/opportunity-requirements.js.map +1 -0
- package/dist/offer/org-banner.d.ts +11 -0
- package/dist/offer/org-banner.d.ts.map +1 -0
- package/dist/offer/org-banner.js +19 -0
- package/dist/offer/org-banner.js.map +1 -0
- package/dist/offer/reviews-summary.d.ts +19 -0
- package/dist/offer/reviews-summary.d.ts.map +1 -0
- package/dist/offer/reviews-summary.js +17 -0
- package/dist/offer/reviews-summary.js.map +1 -0
- package/dist/offer/sensory-profile.d.ts +11 -0
- package/dist/offer/sensory-profile.d.ts.map +1 -0
- package/dist/offer/sensory-profile.js +28 -0
- package/dist/offer/sensory-profile.js.map +1 -0
- package/package.json +11 -2
- package/src/theme/tokens.css +6 -0
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { type SidebarNavLeafItem, type SidebarNavSection, type SidebarUser, type RenderLinkFn } from "./types";
|
|
3
|
+
interface AppSidebarProps {
|
|
4
|
+
/** "Producer Portal" | "Importer Portal" | any custom label */
|
|
5
|
+
portalLabel: string;
|
|
6
|
+
/** Optional pinned dashboard item shown above nav sections */
|
|
7
|
+
dashboardItem?: SidebarNavLeafItem;
|
|
8
|
+
navSections: SidebarNavSection[];
|
|
9
|
+
/** Current route pathname for active-state determination */
|
|
10
|
+
currentPath: string;
|
|
11
|
+
/** Provide the router-aware Link component */
|
|
12
|
+
renderLink: RenderLinkFn;
|
|
13
|
+
user: SidebarUser | null;
|
|
14
|
+
isDark: boolean;
|
|
15
|
+
onToggleTheme: () => void;
|
|
16
|
+
onSignOut: () => void;
|
|
17
|
+
/** Notification button (e.g. <NotificationPanel />) rendered in footer */
|
|
18
|
+
notificationSlot?: React.ReactNode;
|
|
19
|
+
/** Language switcher rendered in footer */
|
|
20
|
+
languageSwitcherSlot?: React.ReactNode;
|
|
21
|
+
/** Any dashboard-specific controls in the footer (e.g. data-source toggle) */
|
|
22
|
+
extraFooterContent?: React.ReactNode;
|
|
23
|
+
/** i18n overrides */
|
|
24
|
+
labels?: {
|
|
25
|
+
signOut?: string;
|
|
26
|
+
user?: string;
|
|
27
|
+
switchToLight?: string;
|
|
28
|
+
switchToDark?: string;
|
|
29
|
+
};
|
|
30
|
+
}
|
|
31
|
+
export declare function AppSidebar({ portalLabel, dashboardItem, navSections, currentPath, renderLink, user, isDark, onToggleTheme, onSignOut, notificationSlot, languageSwitcherSlot, extraFooterContent, labels, }: AppSidebarProps): import("react/jsx-runtime").JSX.Element;
|
|
32
|
+
export {};
|
|
33
|
+
//# sourceMappingURL=app-sidebar.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"app-sidebar.d.ts","sourceRoot":"","sources":["../../src/nav/app-sidebar.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,OAAO,EAEL,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACtB,KAAK,WAAW,EAChB,KAAK,YAAY,EAClB,MAAM,SAAS,CAAC;AAIjB,UAAU,eAAe;IACvB,+DAA+D;IAC/D,WAAW,EAAE,MAAM,CAAC;IACpB,8DAA8D;IAC9D,aAAa,CAAC,EAAE,kBAAkB,CAAC;IACnC,WAAW,EAAE,iBAAiB,EAAE,CAAC;IACjC,4DAA4D;IAC5D,WAAW,EAAE,MAAM,CAAC;IACpB,8CAA8C;IAC9C,UAAU,EAAE,YAAY,CAAC;IACzB,IAAI,EAAE,WAAW,GAAG,IAAI,CAAC;IACzB,MAAM,EAAE,OAAO,CAAC;IAChB,aAAa,EAAE,MAAM,IAAI,CAAC;IAC1B,SAAS,EAAE,MAAM,IAAI,CAAC;IACtB,0EAA0E;IAC1E,gBAAgB,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACnC,2CAA2C;IAC3C,oBAAoB,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACvC,8EAA8E;IAC9E,kBAAkB,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACrC,qBAAqB;IACrB,MAAM,CAAC,EAAE;QACP,OAAO,CAAC,EAAE,MAAM,CAAC;QACjB,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,aAAa,CAAC,EAAE,MAAM,CAAC;QACvB,YAAY,CAAC,EAAE,MAAM,CAAC;KACvB,CAAC;CACH;AAOD,wBAAgB,UAAU,CAAC,EACzB,WAAW,EACX,aAAa,EACb,WAAW,EACX,WAAW,EACX,UAAU,EACV,IAAI,EACJ,MAAM,EACN,aAAa,EACb,SAAS,EACT,gBAAgB,EAChB,oBAAoB,EACpB,kBAAkB,EAClB,MAAW,GACZ,EAAE,eAAe,2CAkKjB"}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
+
import { Sun, Moon } from "lucide-react";
|
|
3
|
+
import { cn } from "../lib/utils";
|
|
4
|
+
import { ExpandableNavItem } from "./expandable-nav-item";
|
|
5
|
+
import { isSidebarNavExpandable, } from "./types";
|
|
6
|
+
const BRAND_NAME = "CellarNode";
|
|
7
|
+
function isActive(currentPath, href) {
|
|
8
|
+
if (href === "/" || href === "/dashboard")
|
|
9
|
+
return currentPath === href;
|
|
10
|
+
return currentPath.startsWith(href);
|
|
11
|
+
}
|
|
12
|
+
export function AppSidebar({ portalLabel, dashboardItem, navSections, currentPath, renderLink, user, isDark, onToggleTheme, onSignOut, notificationSlot, languageSwitcherSlot, extraFooterContent, labels = {}, }) {
|
|
13
|
+
const ThemeIcon = isDark ? Sun : Moon;
|
|
14
|
+
const initials = user?.initials
|
|
15
|
+
?? (user?.name
|
|
16
|
+
? user.name
|
|
17
|
+
.split(" ")
|
|
18
|
+
.map((n) => n[0])
|
|
19
|
+
.join("")
|
|
20
|
+
.toUpperCase()
|
|
21
|
+
.slice(0, 2)
|
|
22
|
+
: "?");
|
|
23
|
+
return (_jsxs("div", { className: "relative flex grow flex-col gap-y-5 overflow-y-auto bg-primary px-6 dark:bg-sidebar dark:before:pointer-events-none dark:before:absolute dark:before:inset-0 dark:before:border-r dark:before:border-white/5 dark:before:bg-white/[0.015]", children: [_jsx("div", { className: "relative flex h-16 shrink-0 items-center gap-3", children: renderLink({
|
|
24
|
+
href: dashboardItem?.href ?? "/",
|
|
25
|
+
className: "flex items-center gap-3",
|
|
26
|
+
children: (_jsxs(_Fragment, { children: [_jsx("img", { src: "/android-chrome-192x192.png", alt: BRAND_NAME, className: "size-10 shrink-0 rounded-[1.15rem]" }), _jsxs("div", { className: "flex flex-col leading-none", children: [_jsx("span", { className: "text-sm font-semibold font-display tracking-tight text-white dark:text-sidebar-foreground", children: BRAND_NAME }), _jsx("span", { className: "text-[11px] uppercase tracking-[0.16em] text-white/65 dark:text-sidebar-foreground/65", children: portalLabel })] })] })),
|
|
27
|
+
}) }), _jsx("nav", { className: "relative flex flex-1 flex-col", children: _jsxs("ul", { role: "list", className: "flex flex-1 flex-col gap-y-7", children: [dashboardItem && (_jsx("li", { children: _jsx("ul", { role: "list", className: "-mx-2 mt-2 space-y-1.5", children: _jsx(NavLeafItem, { item: dashboardItem, current: isActive(currentPath, dashboardItem.href), renderLink: renderLink }) }) })), navSections.map((section) => (_jsxs("li", { children: [_jsx("div", { className: "text-[11px] font-semibold uppercase tracking-[0.16em] text-white/50 dark:text-sidebar-foreground/50 mb-2", children: section.label }), _jsx("ul", { role: "list", className: "-mx-2 space-y-1.5", children: section.items.map((item) => isSidebarNavExpandable(item) ? (_jsx(ExpandableNavItem, { name: item.title, icon: item.icon, children: item.children, currentPath: currentPath, renderLink: renderLink }, item.title)) : (_jsx(NavLeafItem, { item: item, current: isActive(currentPath, item.href), renderLink: renderLink }, item.href))) })] }, section.label))), _jsxs("li", { className: "-mx-6 mt-auto", children: [extraFooterContent && (_jsx("div", { className: "px-6 pb-3", children: extraFooterContent })), _jsxs("div", { className: "flex items-center gap-x-4 px-6 py-3", children: [renderLink({
|
|
28
|
+
href: user?.profileHref ?? "/profile",
|
|
29
|
+
className: "flex flex-1 items-center gap-x-4 text-sm/6 font-semibold text-primary-foreground hover:opacity-80 truncate min-w-0",
|
|
30
|
+
children: (_jsxs(_Fragment, { children: [_jsx("span", { className: "inline-grid size-8 shrink-0 select-none place-items-center rounded-full bg-primary/80 text-xs font-semibold text-white outline -outline-offset-1 outline-white/10 dark:bg-white/5", "aria-hidden": "true", children: user?.avatarUrl ? (_jsx("img", { src: user.avatarUrl, alt: user.name, className: "size-full rounded-full object-cover" })) : (initials) }), _jsx("span", { className: "font-display truncate", children: user?.name ?? labels.user ?? "User" })] })),
|
|
31
|
+
}), _jsxs("div", { className: "flex items-center gap-x-2", children: [_jsx("button", { type: "button", onClick: onToggleTheme, "aria-label": isDark
|
|
32
|
+
? (labels.switchToLight ?? "Switch to light theme")
|
|
33
|
+
: (labels.switchToDark ?? "Switch to dark theme"), className: "inline-flex size-9 items-center justify-center rounded-full border border-white/15 bg-white/5 text-white/80 transition-colors hover:bg-white/10 hover:text-white focus:outline-none focus-visible:ring-2 focus-visible:ring-white/20 dark:border-white/10 dark:bg-white/5 dark:text-zinc-200 dark:hover:bg-white/10 dark:hover:text-zinc-50", children: _jsx(ThemeIcon, { className: "size-4.5", "aria-hidden": "true" }) }), notificationSlot] })] }), languageSwitcherSlot && (_jsx("div", { className: "flex items-center justify-between px-6 pb-3", children: languageSwitcherSlot })), _jsx("div", { className: "px-6 pb-4", children: _jsx("button", { type: "button", onClick: onSignOut, className: "w-full rounded-md border border-white/20 px-3 py-2 text-sm font-semibold text-white/80 hover:bg-white/5 hover:text-white dark:border-white/10 dark:text-zinc-200 dark:hover:bg-white/5 dark:hover:text-zinc-50", children: labels.signOut ?? "Sign out" }) })] })] }) })] }));
|
|
34
|
+
}
|
|
35
|
+
function NavLeafItem({ item, current, renderLink, }) {
|
|
36
|
+
return (_jsx("li", { children: renderLink({
|
|
37
|
+
href: item.href,
|
|
38
|
+
className: cn("group relative flex min-h-11 items-center gap-x-3 rounded-md px-3 py-2 text-sm/6 transition-colors ring-1 ring-transparent", current
|
|
39
|
+
? "bg-white/10 text-white font-semibold before:absolute before:left-1.5 before:top-1/2 before:h-5 before:w-0.5 before:-translate-y-1/2 before:rounded-full before:bg-white/85 dark:bg-white/6 dark:text-zinc-50 dark:ring-1 dark:ring-white/10 dark:before:bg-primary/80"
|
|
40
|
+
: "text-white/80 font-medium hover:bg-white/6 hover:text-white dark:text-zinc-300 dark:hover:bg-white/5 dark:hover:text-zinc-100"),
|
|
41
|
+
children: (_jsxs(_Fragment, { children: [_jsx(item.icon, { "aria-hidden": "true", className: cn("size-6 shrink-0 transition-opacity", current ? "opacity-100" : "opacity-80 group-hover:opacity-100") }), _jsx("span", { className: cn("font-display truncate", current ? "tracking-[0.01em]" : ""), children: item.title }), item.badgeCount != null && item.badgeCount > 0 ? (_jsx("span", { "aria-hidden": "true", className: cn("ml-auto w-9 min-w-max rounded-full px-2.5 py-0.5 text-center text-xs/5 font-medium whitespace-nowrap outline-1 -outline-offset-1", current
|
|
42
|
+
? "bg-white/12 text-white outline-white/15 dark:bg-white/8 dark:text-zinc-100 dark:outline-white/10"
|
|
43
|
+
: "bg-white/8 text-white/80 outline-white/10 dark:bg-white/5 dark:text-zinc-300 dark:outline-white/5"), children: item.badgeCount > 99 ? "99+" : item.badgeCount })) : null] })),
|
|
44
|
+
}) }));
|
|
45
|
+
}
|
|
46
|
+
//# sourceMappingURL=app-sidebar.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"app-sidebar.js","sourceRoot":"","sources":["../../src/nav/app-sidebar.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,EAAE,EAAE,EAAE,MAAM,cAAc,CAAC;AAClC,OAAO,EAAE,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAC1D,OAAO,EACL,sBAAsB,GAKvB,MAAM,SAAS,CAAC;AAEjB,MAAM,UAAU,GAAG,YAAY,CAAC;AA+BhC,SAAS,QAAQ,CAAC,WAAmB,EAAE,IAAY;IACjD,IAAI,IAAI,KAAK,GAAG,IAAI,IAAI,KAAK,YAAY;QAAE,OAAO,WAAW,KAAK,IAAI,CAAC;IACvE,OAAO,WAAW,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;AACtC,CAAC;AAED,MAAM,UAAU,UAAU,CAAC,EACzB,WAAW,EACX,aAAa,EACb,WAAW,EACX,WAAW,EACX,UAAU,EACV,IAAI,EACJ,MAAM,EACN,aAAa,EACb,SAAS,EACT,gBAAgB,EAChB,oBAAoB,EACpB,kBAAkB,EAClB,MAAM,GAAG,EAAE,GACK;IAChB,MAAM,SAAS,GAAG,MAAM,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC;IAEtC,MAAM,QAAQ,GAAG,IAAI,EAAE,QAAQ;WAC1B,CAAC,IAAI,EAAE,IAAI;YACZ,CAAC,CAAC,IAAI,CAAC,IAAI;iBACN,KAAK,CAAC,GAAG,CAAC;iBACV,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;iBAChB,IAAI,CAAC,EAAE,CAAC;iBACR,WAAW,EAAE;iBACb,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC;YAChB,CA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,CAAC,CAAC,IAAI,IACP,CACJ;SACF,CAAC,GACC,CACN,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { SidebarNavSubItem, IconType, RenderLinkFn } from "./types";
|
|
2
|
+
interface ExpandableNavItemProps {
|
|
3
|
+
name: string;
|
|
4
|
+
icon: IconType;
|
|
5
|
+
children: SidebarNavSubItem[];
|
|
6
|
+
currentPath: string;
|
|
7
|
+
renderLink: RenderLinkFn;
|
|
8
|
+
}
|
|
9
|
+
export declare function ExpandableNavItem({ name, icon: Icon, children, currentPath, renderLink, }: ExpandableNavItemProps): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
export {};
|
|
11
|
+
//# sourceMappingURL=expandable-nav-item.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"expandable-nav-item.d.ts","sourceRoot":"","sources":["../../src/nav/expandable-nav-item.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,iBAAiB,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAEzE,UAAU,sBAAsB;IAC9B,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,QAAQ,CAAC;IACf,QAAQ,EAAE,iBAAiB,EAAE,CAAC;IAC9B,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,YAAY,CAAC;CAC1B;AAED,wBAAgB,iBAAiB,CAAC,EAChC,IAAI,EACJ,IAAI,EAAE,IAAI,EACV,QAAQ,EACR,WAAW,EACX,UAAU,GACX,EAAE,sBAAsB,2CAuExB"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { useState, useEffect } from "react";
|
|
3
|
+
import { ChevronDown, ChevronUp } from "lucide-react";
|
|
4
|
+
import { cn } from "../lib/utils";
|
|
5
|
+
export function ExpandableNavItem({ name, icon: Icon, children, currentPath, renderLink, }) {
|
|
6
|
+
const isChildActive = children.some((child) => child.href === "/" ? currentPath === "/" : currentPath.startsWith(child.href));
|
|
7
|
+
const [open, setOpen] = useState(isChildActive);
|
|
8
|
+
useEffect(() => {
|
|
9
|
+
if (isChildActive)
|
|
10
|
+
setOpen(true);
|
|
11
|
+
}, [isChildActive]);
|
|
12
|
+
return (_jsxs("li", { children: [_jsxs("button", { type: "button", onClick: () => setOpen((prev) => !prev), className: cn("group relative flex w-full min-h-11 items-center gap-x-3 rounded-md px-3 py-2 text-sm/6 transition-colors ring-1 ring-transparent", isChildActive
|
|
13
|
+
? "text-white font-semibold"
|
|
14
|
+
: "text-white/80 font-medium hover:bg-white/6 hover:text-white dark:text-zinc-300 dark:hover:bg-white/5 dark:hover:text-zinc-100"), children: [_jsx(Icon, { "aria-hidden": "true", className: cn("size-6 shrink-0 transition-opacity", isChildActive ? "opacity-100" : "opacity-80 group-hover:opacity-100") }), _jsx("span", { className: cn("font-display truncate", isChildActive ? "tracking-[0.01em]" : ""), children: name }), open ? (_jsx(ChevronUp, { "aria-hidden": "true", className: "ml-auto size-4 shrink-0 opacity-60 group-hover:opacity-80" })) : (_jsx(ChevronDown, { "aria-hidden": "true", className: "ml-auto size-4 shrink-0 opacity-60 group-hover:opacity-80" }))] }), open && (_jsx("ul", { role: "list", className: "mt-1 space-y-1", children: children.map((child, index) => {
|
|
15
|
+
const current = index === 0
|
|
16
|
+
? currentPath === child.href
|
|
17
|
+
: currentPath === child.href || currentPath.startsWith(child.href + "/");
|
|
18
|
+
return (_jsx("li", { children: renderLink({
|
|
19
|
+
href: child.href,
|
|
20
|
+
className: cn("group relative flex min-h-9 items-center gap-x-3 rounded-md pl-12 pr-3 py-1.5 text-sm/6 transition-colors ring-1 ring-transparent", current
|
|
21
|
+
? "bg-white/10 text-white font-semibold before:absolute before:left-1.5 before:top-1/2 before:h-5 before:w-0.5 before:-translate-y-1/2 before:rounded-full before:bg-white/85 dark:bg-white/6 dark:text-zinc-50 dark:ring-1 dark:ring-white/10 dark:before:bg-primary/80"
|
|
22
|
+
: "text-white/80 font-medium hover:bg-white/6 hover:text-white dark:text-zinc-300 dark:hover:bg-white/5 dark:hover:text-zinc-100"),
|
|
23
|
+
children: (_jsx("span", { className: cn("font-display truncate", current ? "tracking-[0.01em]" : ""), children: child.title })),
|
|
24
|
+
}) }, child.href));
|
|
25
|
+
}) }))] }));
|
|
26
|
+
}
|
|
27
|
+
//# sourceMappingURL=expandable-nav-item.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"expandable-nav-item.js","sourceRoot":"","sources":["../../src/nav/expandable-nav-item.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACtD,OAAO,EAAE,EAAE,EAAE,MAAM,cAAc,CAAC;AAWlC,MAAM,UAAU,iBAAiB,CAAC,EAChC,IAAI,EACJ,IAAI,EAAE,IAAI,EACV,QAAQ,EACR,WAAW,EACX,UAAU,GACa;IACvB,MAAM,aAAa,GAAG,QAAQ,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,EAAE,CAC5C,KAAK,CAAC,IAAI,KAAK,GAAG,CAAC,CAAC,CAAC,WAAW,KAAK,GAAG,CAAC,CAAC,CAAC,WAAW,CAAC,UAAU,CAAC,KAAK,CAAC,IAAI,CAAC,CAC9E,CAAC;IAEF,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,GAAG,QAAQ,CAAC,aAAa,CAAC,CAAC;IAEhD,SAAS,CAAC,GAAG,EAAE;QACb,IAAI,aAAa;YAAE,OAAO,CAAC,IAAI,CAAC,CAAC;IACnC,CAAC,EAAE,CAAC,aAAa,CAAC,CAAC,CAAC;IAEpB,OAAO,CACL,yBACE,kBACE,IAAI,EAAC,QAAQ,EACb,OAAO,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,CAAC,IAAI,EA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C,mBAAmB,CAAC,CAAC,CAAC,EAAE,CAAC,YAC7E,KAAK,CAAC,KAAK,GACP,CACR;yBACF,CAAC,IAdK,KAAK,CAAC,IAAI,CAed,CACN,CAAC;gBACJ,CAAC,CAAC,GACC,CACN,IACE,CACN,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export { AppSidebar } from "./app-sidebar";
|
|
2
|
+
export { AppShell } from "./app-shell";
|
|
3
|
+
export { ExpandableNavItem } from "./expandable-nav-item";
|
|
4
|
+
export type { IconType, RenderLinkFn, SidebarNavLeafItem, SidebarNavExpandableItem, SidebarNavSectionItem, SidebarNavSection, SidebarNavSubItem, SidebarUser, } from "./types";
|
|
5
|
+
export { isSidebarNavExpandable } from "./types";
|
|
6
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/nav/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAC1D,YAAY,EACV,QAAQ,EACR,YAAY,EACZ,kBAAkB,EAClB,wBAAwB,EACxB,qBAAqB,EACrB,iBAAiB,EACjB,iBAAiB,EACjB,WAAW,GACZ,MAAM,SAAS,CAAC;AACjB,OAAO,EAAE,sBAAsB,EAAE,MAAM,SAAS,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/nav/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAW1D,OAAO,EAAE,sBAAsB,EAAE,MAAM,SAAS,CAAC"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import type React from "react";
|
|
2
|
+
export type IconType = React.ComponentType<{
|
|
3
|
+
className?: string;
|
|
4
|
+
"aria-hidden"?: boolean | "true" | "false";
|
|
5
|
+
}>;
|
|
6
|
+
export type RenderLinkFn = (props: {
|
|
7
|
+
href: string;
|
|
8
|
+
className?: string;
|
|
9
|
+
children: React.ReactNode;
|
|
10
|
+
}) => React.ReactElement;
|
|
11
|
+
export interface SidebarNavSubItem {
|
|
12
|
+
title: string;
|
|
13
|
+
href: string;
|
|
14
|
+
}
|
|
15
|
+
export interface SidebarNavLeafItem {
|
|
16
|
+
title: string;
|
|
17
|
+
href: string;
|
|
18
|
+
icon: IconType;
|
|
19
|
+
badgeCount?: number;
|
|
20
|
+
}
|
|
21
|
+
export interface SidebarNavExpandableItem {
|
|
22
|
+
title: string;
|
|
23
|
+
icon: IconType;
|
|
24
|
+
expandable: true;
|
|
25
|
+
children: SidebarNavSubItem[];
|
|
26
|
+
}
|
|
27
|
+
export type SidebarNavSectionItem = SidebarNavLeafItem | SidebarNavExpandableItem;
|
|
28
|
+
export interface SidebarNavSection {
|
|
29
|
+
label: string;
|
|
30
|
+
items: SidebarNavSectionItem[];
|
|
31
|
+
}
|
|
32
|
+
export interface SidebarUser {
|
|
33
|
+
name: string;
|
|
34
|
+
email?: string;
|
|
35
|
+
initials?: string;
|
|
36
|
+
avatarUrl?: string;
|
|
37
|
+
profileHref: string;
|
|
38
|
+
}
|
|
39
|
+
export declare function isSidebarNavExpandable(item: SidebarNavSectionItem): item is SidebarNavExpandableItem;
|
|
40
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/nav/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,MAAM,MAAM,QAAQ,GAAG,KAAK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ourceRoot":"","sources":["../../src/nav/types.ts"],"names":[],"mappings":"AA+CA,MAAM,UAAU,sBAAsB,CACpC,IAA2B;IAE3B,OAAO,YAAY,IAAI,IAAI,IAAI,IAAI,CAAC,UAAU,KAAK,IAAI,CAAC;AAC1D,CAAC"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export interface BeverageDetailsProps {
|
|
2
|
+
beverageType?: string | null;
|
|
3
|
+
producerName?: string | null;
|
|
4
|
+
countryOfOrigin?: string | null;
|
|
5
|
+
region?: string | null;
|
|
6
|
+
vintage?: string | number | null;
|
|
7
|
+
abv?: string | number | null;
|
|
8
|
+
containerVolume?: string | number | null;
|
|
9
|
+
productionVolume?: string | number | null;
|
|
10
|
+
residualSugar?: string | number | null;
|
|
11
|
+
totalAcidity?: string | number | null;
|
|
12
|
+
pH?: string | number | null;
|
|
13
|
+
packaging?: string | null;
|
|
14
|
+
closure?: string | null;
|
|
15
|
+
priceRange?: {
|
|
16
|
+
min?: number;
|
|
17
|
+
max?: number;
|
|
18
|
+
} | null;
|
|
19
|
+
currency?: string | null;
|
|
20
|
+
className?: string;
|
|
21
|
+
}
|
|
22
|
+
export declare function BeverageDetails(props: BeverageDetailsProps): import("react/jsx-runtime").JSX.Element | null;
|
|
23
|
+
//# sourceMappingURL=beverage-details.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"beverage-details.d.ts","sourceRoot":"","sources":["../../src/offer/beverage-details.tsx"],"names":[],"mappings":"AAEA,MAAM,WAAW,oBAAoB;IACnC,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B,eAAe,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAChC,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,OAAO,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;IACjC,GAAG,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;IAC7B,eAAe,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;IACzC,gBAAgB,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;IAC1C,aAAa,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;IACvC,YAAY,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;IACtC,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;IAC5B,SAAS,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,UAAU,CAAC,EAAE;QAAE,GAAG,CAAC,EAAE,MAAM,CAAC;QAAC,GAAG,CAAC,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAC;IACnD,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAoBD,wBAAgB,eAAe,CAAC,KAAK,EAAE,oBAAoB,kDAoC1D"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { cn } from "../lib/utils";
|
|
3
|
+
function formatPriceRange(range, currency) {
|
|
4
|
+
if (!range)
|
|
5
|
+
return null;
|
|
6
|
+
const { min, max } = range;
|
|
7
|
+
if (min == null && max == null)
|
|
8
|
+
return null;
|
|
9
|
+
const cur = currency ?? "";
|
|
10
|
+
if (min != null && max != null)
|
|
11
|
+
return `${cur} ${min} – ${max}`.trim();
|
|
12
|
+
if (min != null)
|
|
13
|
+
return `${cur} ${min}+`.trim();
|
|
14
|
+
return `up to ${cur} ${max}`.trim();
|
|
15
|
+
}
|
|
16
|
+
export function BeverageDetails(props) {
|
|
17
|
+
const fields = [];
|
|
18
|
+
const push = (label, value) => {
|
|
19
|
+
if (value != null && String(value).trim() !== "") {
|
|
20
|
+
fields.push({ label, value: String(value) });
|
|
21
|
+
}
|
|
22
|
+
};
|
|
23
|
+
push("Beverage Type", props.beverageType);
|
|
24
|
+
push("Producer", props.producerName);
|
|
25
|
+
push("Country of Origin", props.countryOfOrigin);
|
|
26
|
+
push("Region", props.region);
|
|
27
|
+
push("Vintage", props.vintage);
|
|
28
|
+
push("ABV", props.abv != null ? `${props.abv}%` : null);
|
|
29
|
+
push("Container Volume", props.containerVolume);
|
|
30
|
+
push("Production Volume", props.productionVolume);
|
|
31
|
+
push("Residual Sugar", props.residualSugar);
|
|
32
|
+
push("Total Acidity", props.totalAcidity);
|
|
33
|
+
push("pH", props.pH);
|
|
34
|
+
push("Packaging", props.packaging);
|
|
35
|
+
push("Closure", props.closure);
|
|
36
|
+
push("Price Range", formatPriceRange(props.priceRange, props.currency));
|
|
37
|
+
if (fields.length === 0)
|
|
38
|
+
return null;
|
|
39
|
+
return (_jsx("div", { className: cn("grid grid-cols-2 gap-x-4 gap-y-3 sm:grid-cols-3", props.className), children: fields.map((field) => (_jsxs("div", { className: "grid gap-0.5", children: [_jsx("span", { className: "text-xs text-muted-foreground", children: field.label }), _jsx("span", { className: "text-sm font-medium text-foreground", children: field.value })] }, field.label))) }));
|
|
40
|
+
}
|
|
41
|
+
//# sourceMappingURL=beverage-details.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"beverage-details.js","sourceRoot":"","sources":["../../src/offer/beverage-details.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,EAAE,EAAE,MAAM,cAAc,CAAC;AA0BlC,SAAS,gBAAgB,CACvB,KAAwD,EACxD,QAAwB;IAExB,IAAI,CAAC,KAAK;QAAE,OAAO,IAAI,CAAC;IACxB,MAAM,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,KAAK,CAAC;IAC3B,IAAI,GAAG,IAAI,IAAI,IAAI,GAAG,IAAI,IAAI;QAAE,OAAO,IAAI,C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AAe,CAAC,CAAC;IAChD,IAAI,CAAC,mBAAmB,EAAE,KAAK,CAAC,gBAAgB,CAAC,CAAC;IAClD,IAAI,CAAC,gBAAgB,EAAE,KAAK,CAAC,aAAa,CAAC,CAAC;IAC5C,IAAI,CAAC,eAAe,EAAE,KAAK,CAAC,YAAY,CAAC,CAAC;IAC1C,IAAI,CAAC,IAAI,EAAE,KAAK,CAAC,EAAE,CAAC,CAAC;IACrB,IAAI,CAAC,WAAW,EAAE,KAAK,CAAC,SAAS,CAAC,CAAC;IACnC,IAAI,CAAC,SAAS,EAAE,KAAK,CAAC,OAAO,CAAC,CAAC;IAC/B,IAAI,CAAC,aAAa,EAAE,gBAAgB,CAAC,KAAK,CAAC,UAAU,EAAE,KAAK,CAAC,QAAQ,CAAC,CAAC,CAAC;IAExE,IAAI,MAAM,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,IAAI,CAAC;IAErC,OAAO,CACL,cAAK,SAAS,EAAE,EAAE,CAAC,iDAAiD,EAAE,KAAK,CAAC,SAAS,CAAC,YACnF,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,CACrB,eAAuB,SAAS,EAAC,cAAc,aAC7C,eAAM,SAAS,EAAC,+BAA+B,YAAE,KAAK,CAAC,KAAK,GAAQ,EACpE,eAAM,SAAS,EAAC,qCAAqC,YAAE,KAAK,CAAC,KAAK,GAAQ,KAFlE,KAAK,CAAC,KAAK,CAGf,CACP,CAAC,GACE,CACP,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export interface CompositionListProps {
|
|
2
|
+
composition?: {
|
|
3
|
+
name: string;
|
|
4
|
+
percentage?: number | null;
|
|
5
|
+
}[] | null;
|
|
6
|
+
className?: string;
|
|
7
|
+
}
|
|
8
|
+
export declare function CompositionList({ composition, className }: CompositionListProps): import("react/jsx-runtime").JSX.Element | null;
|
|
9
|
+
//# sourceMappingURL=composition-list.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"composition-list.d.ts","sourceRoot":"","sources":["../../src/offer/composition-list.tsx"],"names":[],"mappings":"AAGA,MAAM,WAAW,oBAAoB;IACnC,WAAW,CAAC,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;KAAE,EAAE,GAAG,IAAI,CAAC;IACpE,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,wBAAgB,eAAe,CAAC,EAAE,WAAW,EAAE,SAAS,EAAE,EAAE,oBAAoB,kDAe/E"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { jsxs as _jsxs, jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { Badge } from "../components/badge";
|
|
3
|
+
import { cn } from "../lib/utils";
|
|
4
|
+
export function CompositionList({ composition, className }) {
|
|
5
|
+
if (!composition || composition.length === 0)
|
|
6
|
+
return null;
|
|
7
|
+
return (_jsx("div", { className: cn("flex flex-wrap gap-2", className), children: composition.map((entry) => (_jsxs(Badge, { color: "zinc", children: [entry.name, entry.percentage != null && (_jsxs("span", { className: "ml-0.5 opacity-70", children: [entry.percentage, "%"] }))] }, entry.name))) }));
|
|
8
|
+
}
|
|
9
|
+
//# sourceMappingURL=composition-list.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"composition-list.js","sourceRoot":"","sources":["../../src/offer/composition-list.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,qBAAqB,CAAC;AAC5C,OAAO,EAAE,EAAE,EAAE,MAAM,cAAc,CAAC;AAOlC,MAAM,UAAU,eAAe,CAAC,EAAE,WAAW,EAAE,SAAS,EAAwB;IAC9E,IAAI,CAAC,WAAW,IAAI,WAAW,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,IAAI,CAAC;IAE1D,OAAO,CACL,cAAK,SAAS,EAAE,EAAE,CAAC,sBAAsB,EAAE,SAAS,CAAC,YAClD,WAAW,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,CAC1B,MAAC,KAAK,IAAkB,KAAK,EAAC,MAAM,aACjC,KAAK,CAAC,IAAI,EACV,KAAK,CAAC,UAAU,IAAI,IAAI,IAAI,CAC3B,gBAAM,SAAS,EAAC,mBAAmB,aAAE,KAAK,CAAC,UAAU,SAAS,CAC/D,KAJS,KAAK,CAAC,IAAI,CAKd,CACT,CAAC,GACE,CACP,CAAC;AACJ,CAAC"}
|
package/dist/offer/index.d.ts
CHANGED
|
@@ -8,4 +8,16 @@ export type { ConfirmActionDialogProps } from "./confirm-action-dialog";
|
|
|
8
8
|
export { AttachmentsFolder } from "./attachments-folder";
|
|
9
9
|
export type { AttachmentsFolderProps } from "./attachments-folder";
|
|
10
10
|
export type { OfferResponseThread, OfferResponseInput, TranslationFn, AttachmentMetadata, OfferActionType, } from "./types";
|
|
11
|
+
export { BeverageDetails } from "./beverage-details";
|
|
12
|
+
export type { BeverageDetailsProps } from "./beverage-details";
|
|
13
|
+
export { SensoryProfile } from "./sensory-profile";
|
|
14
|
+
export type { SensoryProfileProps } from "./sensory-profile";
|
|
15
|
+
export { CompositionList } from "./composition-list";
|
|
16
|
+
export type { CompositionListProps } from "./composition-list";
|
|
17
|
+
export { ReviewsSummary } from "./reviews-summary";
|
|
18
|
+
export type { ReviewsSummaryProps } from "./reviews-summary";
|
|
19
|
+
export { OpportunityRequirements } from "./opportunity-requirements";
|
|
20
|
+
export type { OpportunityRequirementsProps } from "./opportunity-requirements";
|
|
21
|
+
export { OrgBanner } from "./org-banner";
|
|
22
|
+
export type { OrgBannerProps } from "./org-banner";
|
|
11
23
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/offer/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AACxD,YAA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,YAAY,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAC;AAC/D,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AACnD,YAAY,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAC7D,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AACrD,YAAY,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAC;AAC/D,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AACnD,YAAY,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAC7D,OAAO,EAAE,uBAAuB,EAAE,MAAM,4BAA4B,CAAC;AACrE,YAAY,EAAE,4BAA4B,EAAE,MAAM,4BAA4B,CAAC;AAC/E,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,YAAY,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC"}
|
package/dist/offer/index.js
CHANGED
|
@@ -3,4 +3,10 @@ export { NegotiationEventCard } from "./negotiation-event-card";
|
|
|
3
3
|
export { InlineCounterForm } from "./inline-counter-form";
|
|
4
4
|
export { ConfirmActionDialog } from "./confirm-action-dialog";
|
|
5
5
|
export { AttachmentsFolder } from "./attachments-folder";
|
|
6
|
+
export { BeverageDetails } from "./beverage-details";
|
|
7
|
+
export { SensoryProfile } from "./sensory-profile";
|
|
8
|
+
export { CompositionList } from "./composition-list";
|
|
9
|
+
export { ReviewsSummary } from "./reviews-summary";
|
|
10
|
+
export { OpportunityRequirements } from "./opportunity-requirements";
|
|
11
|
+
export { OrgBanner } from "./org-banner";
|
|
6
12
|
//# sourceMappingURL=index.js.map
|
package/dist/offer/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/offer/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAExD,OAAO,EAAE,oBAAoB,EAAE,MAAM,0BAA0B,CAAC;AAChE,OAAO,EAAE,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAE1D,OAAO,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AAE9D,OAAO,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/offer/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAExD,OAAO,EAAE,oBAAoB,EAAE,MAAM,0BAA0B,CAAC;AAChE,OAAO,EAAE,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAE1D,OAAO,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AAE9D,OAAO,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AASzD,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAErD,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAEnD,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAErD,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAEnD,OAAO,EAAE,uBAAuB,EAAE,MAAM,4BAA4B,CAAC;AAErE,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
export interface OpportunityRequirementsProps {
|
|
2
|
+
marketIdentifier?: string | null;
|
|
3
|
+
beverageType?: string | null;
|
|
4
|
+
countryOfOrigin?: string | null;
|
|
5
|
+
packagingType?: string | null;
|
|
6
|
+
closure?: string | null;
|
|
7
|
+
currency?: string | null;
|
|
8
|
+
submissionDeadline?: string | null;
|
|
9
|
+
sampleDeadline?: string | null;
|
|
10
|
+
alcoholContent?: {
|
|
11
|
+
min?: number;
|
|
12
|
+
max?: number;
|
|
13
|
+
} | null;
|
|
14
|
+
residualSugarMin?: number | null;
|
|
15
|
+
residualSugarMax?: number | null;
|
|
16
|
+
volumeOptions?: number[] | null;
|
|
17
|
+
grapeBlend?: {
|
|
18
|
+
grape: string;
|
|
19
|
+
amount?: string;
|
|
20
|
+
}[] | null;
|
|
21
|
+
vintages?: number[] | null;
|
|
22
|
+
certifications?: {
|
|
23
|
+
organic?: boolean;
|
|
24
|
+
fairtrade?: boolean;
|
|
25
|
+
sustainable?: boolean;
|
|
26
|
+
} | null;
|
|
27
|
+
styleTasteProfile?: string | null;
|
|
28
|
+
className?: string;
|
|
29
|
+
}
|
|
30
|
+
export declare function OpportunityRequirements(props: OpportunityRequirementsProps): import("react/jsx-runtime").JSX.Element | null;
|
|
31
|
+
//# sourceMappingURL=opportunity-requirements.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"opportunity-requirements.d.ts","sourceRoot":"","sources":["../../src/offer/opportunity-requirements.tsx"],"names":[],"mappings":"AAGA,MAAM,WAAW,4BAA4B;IAC3C,gBAAgB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACjC,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B,eAAe,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAChC,aAAa,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC9B,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,kBAAkB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACnC,cAAc,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC/B,cAAc,CAAC,EAAE;QAAE,GAAG,CAAC,EAAE,MAAM,CAAC;QAAC,GAAG,CAAC,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAC;IACvD,gBAAgB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACjC,gBAAgB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACjC,aAAa,CAAC,EAAE,MAAM,EAAE,GAAG,IAAI,CAAC;IAChC,UAAU,CAAC,EAAE;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,MAAM,CAAC,EAAE,MAAM,CAAA;KAAE,EAAE,GAAG,IAAI,CAAC;IACzD,QAAQ,CAAC,EAAE,MAAM,EAAE,GAAG,IAAI,CAAC;IAC3B,cAAc,CAAC,EAAE;QACf,OAAO,CAAC,EAAE,OAAO,CAAC;QAClB,SAAS,CAAC,EAAE,OAAO,CAAC;QACpB,WAAW,CAAC,EAAE,OAAO,CAAC;KACvB,GAAG,IAAI,CAAC;IACT,iBAAiB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAClC,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AA+BD,wBAAgB,uBAAuB,CAAC,KAAK,EAAE,4BAA4B,kDAwE1E"}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { Badge } from "../components/badge";
|
|
3
|
+
import { cn } from "../lib/utils";
|
|
4
|
+
function formatRange(label, min, max, suffix) {
|
|
5
|
+
if (min == null && max == null)
|
|
6
|
+
return null;
|
|
7
|
+
const s = suffix ? ` ${suffix}` : "";
|
|
8
|
+
if (min != null && max != null)
|
|
9
|
+
return `${min}${s} – ${max}${s}`;
|
|
10
|
+
if (min != null)
|
|
11
|
+
return `${min}${s}+`;
|
|
12
|
+
return `up to ${max}${s}`;
|
|
13
|
+
}
|
|
14
|
+
function buildCertsList(certs) {
|
|
15
|
+
if (!certs)
|
|
16
|
+
return null;
|
|
17
|
+
const active = [];
|
|
18
|
+
if (certs.organic)
|
|
19
|
+
active.push("Organic");
|
|
20
|
+
if (certs.fairtrade)
|
|
21
|
+
active.push("Fairtrade");
|
|
22
|
+
if (certs.sustainable)
|
|
23
|
+
active.push("Sustainable");
|
|
24
|
+
return active.length > 0 ? active.join(", ") : null;
|
|
25
|
+
}
|
|
26
|
+
export function OpportunityRequirements(props) {
|
|
27
|
+
const fields = [];
|
|
28
|
+
const push = (label, value) => {
|
|
29
|
+
if (value != null && String(value).trim() !== "") {
|
|
30
|
+
fields.push({ label, value: String(value) });
|
|
31
|
+
}
|
|
32
|
+
};
|
|
33
|
+
push("Market", props.marketIdentifier);
|
|
34
|
+
push("Beverage Type", props.beverageType);
|
|
35
|
+
push("Country of Origin", props.countryOfOrigin);
|
|
36
|
+
push("Packaging", props.packagingType);
|
|
37
|
+
push("Closure", props.closure);
|
|
38
|
+
push("Currency", props.currency);
|
|
39
|
+
push("Submission Deadline", props.submissionDeadline);
|
|
40
|
+
push("Sample Deadline", props.sampleDeadline);
|
|
41
|
+
push("Alcohol Content", formatRange("ABV", props.alcoholContent?.min, props.alcoholContent?.max, "%"));
|
|
42
|
+
push("Residual Sugar", formatRange("RS", props.residualSugarMin, props.residualSugarMax, "g/L"));
|
|
43
|
+
push("Volume Options", props.volumeOptions && props.volumeOptions.length > 0
|
|
44
|
+
? props.volumeOptions.join(", ")
|
|
45
|
+
: null);
|
|
46
|
+
push("Vintages", props.vintages && props.vintages.length > 0 ? props.vintages.join(", ") : null);
|
|
47
|
+
push("Certifications", buildCertsList(props.certifications));
|
|
48
|
+
push("Style / Taste Profile", props.styleTasteProfile);
|
|
49
|
+
const hasGrapeBlend = props.grapeBlend && props.grapeBlend.length > 0;
|
|
50
|
+
if (fields.length === 0 && !hasGrapeBlend)
|
|
51
|
+
return null;
|
|
52
|
+
return (_jsxs("div", { className: cn("grid gap-4", props.className), children: [fields.length > 0 && (_jsx("div", { className: "grid grid-cols-2 gap-x-4 gap-y-3 sm:grid-cols-3", children: fields.map((field) => (_jsxs("div", { className: "grid gap-0.5", children: [_jsx("span", { className: "text-xs text-muted-foreground", children: field.label }), _jsx("span", { className: "text-sm font-medium text-foreground", children: field.value })] }, field.label))) })), hasGrapeBlend && (_jsxs("div", { className: "grid gap-1.5", children: [_jsx("span", { className: "text-xs text-muted-foreground", children: "Grape Blend" }), _jsx("div", { className: "flex flex-wrap gap-2", children: props.grapeBlend.map((entry) => (_jsxs(Badge, { color: "zinc", children: [entry.grape, entry.amount && (_jsx("span", { className: "ml-0.5 opacity-70", children: entry.amount }))] }, entry.grape))) })] }))] }));
|
|
53
|
+
}
|
|
54
|
+
//# sourceMappingURL=opportunity-requirements.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"opportunity-requirements.js","sourceRoot":"","sources":["../../src/offer/opportunity-requirements.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,qBAAqB,CAAC;AAC5C,OAAO,EAAE,EAAE,EAAE,MAAM,cAAc,CAAC;AA+BlC,SAAS,WAAW,CAClB,KAAa,EACb,GAAmB,EACnB,GAAmB,EACnB,MAAe;IAEf,IAAI,GAAG,IAAI,IAAI,IAAI,GAAG,IAAI,IAAI;QAAE,OAAO,IAAI,CAAC;IAC5C,MAAM,CAAC,GAAG,MAAM,CAAC,CAAC,CAAC,IAAI,MAAM,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;IACrC,IAAI,GAAG,IAAI,IAAI,IAAI,GAAG,IAAI,IAAI;QAAE,OAAO,GAAG,GAAG,GAAG,CAAC,MAAM,GAAG,GAAG,CAAC,EAAE,CAAC;IACjE,IAAI,GAAG,IAAI,IAAI;QAAE,OAAO,GAAG,GAAG,GAAG,CAAC,GAAG,CAAC;IACtC,OAAO,SAAS,GAAG,GAAG,CAAC,EAAE,CAAC;AAC5B,CAAC;AAED,SAAS,cAAc,CACrB,KAA2F;IAE3F,IAAI,CAAC,KAAK;QAAE,OAAO,IAAI,CAAC;IACxB,MAAM,MAAM,GAAa,EAAE,CAAC;IAC5B,IAAI,KAAK,CAAC,OAAO;QAAE,MAAM,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;IAC1C,IAAI,KAAK,CAAC,SAAS;QAAE,MAAM,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;IAC9C,IAAI,KAAK,CAAC,WAAW;QAAE,MA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K,CAGf,CACP,CAAC,GACE,CACP,EAEA,aAAa,IAAI,CAChB,eAAK,SAAS,EAAC,cAAc,aAC3B,eAAM,SAAS,EAAC,+BAA+B,4BAAmB,EAClE,cAAK,SAAS,EAAC,sBAAsB,YAClC,KAAK,CAAC,UAAW,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,CAChC,MAAC,KAAK,IAAmB,KAAK,EAAC,MAAM,aAClC,KAAK,CAAC,KAAK,EACX,KAAK,CAAC,MAAM,IAAI,CACf,eAAM,SAAS,EAAC,mBAAmB,YAAE,KAAK,CAAC,MAAM,GAAQ,CAC1D,KAJS,KAAK,CAAC,KAAK,CAKf,CACT,CAAC,GACE,IACF,CACP,IACG,CACP,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export interface OrgBannerProps {
|
|
2
|
+
name: string;
|
|
3
|
+
country?: string | null;
|
|
4
|
+
region?: string | null;
|
|
5
|
+
verified?: boolean;
|
|
6
|
+
profilePictureUrl?: string | null;
|
|
7
|
+
description?: string | null;
|
|
8
|
+
className?: string;
|
|
9
|
+
}
|
|
10
|
+
export declare function OrgBanner({ name, country, region, verified, profilePictureUrl, description, className, }: OrgBannerProps): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
//# sourceMappingURL=org-banner.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"org-banner.d.ts","sourceRoot":"","sources":["../../src/offer/org-banner.tsx"],"names":[],"mappings":"AAGA,MAAM,WAAW,cAAc;IAC7B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,iBAAiB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAClC,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAkBD,wBAAgB,SAAS,CAAC,EACxB,IAAI,EACJ,OAAO,EACP,MAAM,EACN,QAAQ,EACR,iBAAiB,EACjB,WAAW,EACX,SAAS,GACV,EAAE,cAAc,2CAqChB"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { Badge } from "../components/badge";
|
|
3
|
+
import { cn } from "../lib/utils";
|
|
4
|
+
function getInitials(name) {
|
|
5
|
+
return name
|
|
6
|
+
.split(/\s+/)
|
|
7
|
+
.slice(0, 2)
|
|
8
|
+
.map((w) => w.charAt(0).toUpperCase())
|
|
9
|
+
.join("");
|
|
10
|
+
}
|
|
11
|
+
function buildLocation(country, region) {
|
|
12
|
+
const parts = [region, country].filter(Boolean);
|
|
13
|
+
return parts.length > 0 ? parts.join(", ") : null;
|
|
14
|
+
}
|
|
15
|
+
export function OrgBanner({ name, country, region, verified, profilePictureUrl, description, className, }) {
|
|
16
|
+
const location = buildLocation(country, region);
|
|
17
|
+
return (_jsxs("div", { className: cn("flex items-start gap-4", className), children: [profilePictureUrl ? (_jsx("img", { src: profilePictureUrl, alt: name, className: "size-12 shrink-0 rounded-full object-cover" })) : (_jsx("div", { className: "flex size-12 shrink-0 items-center justify-center rounded-full bg-muted text-sm font-semibold text-muted-foreground", children: getInitials(name) })), _jsxs("div", { className: "grid min-w-0 gap-0.5", children: [_jsxs("div", { className: "flex items-center gap-2", children: [_jsx("span", { className: "truncate text-sm font-semibold text-foreground", children: name }), verified && (_jsx(Badge, { color: "emerald", children: "Verified" }))] }), location && (_jsx("span", { className: "text-xs text-muted-foreground", children: location })), description && (_jsx("p", { className: "mt-1 text-sm/6 text-muted-foreground", children: description }))] })] }));
|
|
18
|
+
}
|
|
19
|
+
//# sourceMappingURL=org-banner.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"org-banner.js","source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ACtC,eAAM,SAAS,EAAC,gDAAgD,YAAE,IAAI,GAAQ,EAC7E,QAAQ,IAAI,CACX,KAAC,KAAK,IAAC,KAAK,EAAC,SAAS,yBAAiB,CACxC,IACG,EAEL,QAAQ,IAAI,CACX,eAAM,SAAS,EAAC,+BAA+B,YAAE,QAAQ,GAAQ,CAClE,EAEA,WAAW,IAAI,CACd,YAAG,SAAS,EAAC,sCAAsC,YAAE,WAAW,GAAK,CACtE,IACG,IACF,CACP,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export interface ReviewsSummaryProps {
|
|
2
|
+
averageScore?: number | null;
|
|
3
|
+
individualScores?: {
|
|
4
|
+
source: string;
|
|
5
|
+
score: number;
|
|
6
|
+
}[] | null;
|
|
7
|
+
professionalSummary?: string | null;
|
|
8
|
+
awards?: {
|
|
9
|
+
id: string;
|
|
10
|
+
name: string;
|
|
11
|
+
}[] | null;
|
|
12
|
+
citations?: {
|
|
13
|
+
url: string;
|
|
14
|
+
title?: string;
|
|
15
|
+
}[] | null;
|
|
16
|
+
className?: string;
|
|
17
|
+
}
|
|
18
|
+
export declare function ReviewsSummary(props: ReviewsSummaryProps): import("react/jsx-runtime").JSX.Element | null;
|
|
19
|
+
//# sourceMappingURL=reviews-summary.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"reviews-summary.d.ts","sourceRoot":"","sources":["../../src/offer/reviews-summary.tsx"],"names":[],"mappings":"AAGA,MAAM,WAAW,mBAAmB;IAClC,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B,gBAAgB,CAAC,EAAE;QAAE,MAAM,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,EAAE,GAAG,IAAI,CAAC;IAC9D,mBAAmB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACpC,MAAM,CAAC,EAAE;QAAE,EAAE,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,EAAE,GAAG,IAAI,CAAC;IAC/C,SAAS,CAAC,EAAE;QAAE,GAAG,EAAE,MAAM,CAAC;QAAC,KAAK,CAAC,EAAE,MAAM,CAAA;KAAE,EAAE,GAAG,IAAI,CAAC;IACrD,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAYD,wBAAgB,cAAc,CAAC,KAAK,EAAE,mBAAmB,kDAwExD"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { Badge } from "../components/badge";
|
|
3
|
+
import { cn } from "../lib/utils";
|
|
4
|
+
function isEmpty(props) {
|
|
5
|
+
return (props.averageScore == null &&
|
|
6
|
+
(!props.individualScores || props.individualScores.length === 0) &&
|
|
7
|
+
!props.professionalSummary &&
|
|
8
|
+
(!props.awards || props.awards.length === 0) &&
|
|
9
|
+
(!props.citations || props.citations.length === 0));
|
|
10
|
+
}
|
|
11
|
+
export function ReviewsSummary(props) {
|
|
12
|
+
if (isEmpty(props))
|
|
13
|
+
return null;
|
|
14
|
+
const { averageScore, individualScores, professionalSummary, awards, citations, className, } = props;
|
|
15
|
+
return (_jsxs("div", { className: cn("grid gap-4", className), children: [averageScore != null && (_jsxs("div", { className: "flex items-baseline gap-2", children: [_jsx("span", { className: "text-2xl font-bold text-foreground", children: averageScore }), _jsx("span", { className: "text-sm text-muted-foreground", children: "/ 100" })] })), individualScores && individualScores.length > 0 && (_jsx("div", { className: "grid gap-1.5", children: individualScores.map((entry) => (_jsxs("div", { className: "flex items-center justify-between gap-4 text-sm", children: [_jsx("span", { className: "text-muted-foreground", children: entry.source }), _jsx("span", { className: "font-medium text-foreground", children: entry.score })] }, entry.source))) })), professionalSummary && (_jsx("p", { className: "text-sm/6 text-foreground", children: professionalSummary })), awards && awards.length > 0 && (_jsx("div", { className: "flex flex-wrap gap-2", children: awards.map((award) => (_jsx(Badge, { color: "amber", children: award.name }, award.id))) })), citations && citations.length > 0 && (_jsx("ul", { className: "grid gap-1", children: citations.map((citation) => (_jsx("li", { children: _jsx("a", { href: citation.url, target: "_blank", rel: "noopener noreferrer", className: "text-sm text-primary underline-offset-2 hover:underline", children: citation.title || citation.url }) }, citation.url))) }))] }));
|
|
16
|
+
}
|
|
17
|
+
//# sourceMappingURL=reviews-summary.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"reviews-summary.js","sourceRoot":"","sources":["../../src/offer/reviews-summary.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,qBAAqB,CAAC;AAC5C,OAAO,EAAE,EAAE,EAAE,MAAM,cAAc,CAAC;AAWlC,SAAS,OAAO,CAAC,KAA0B;IACzC,OAAO,CACL,KAAK,CAAC,YAAY,IAAI,IAAI;QAC1B,CAAC,CAAC,KAAK,CAAC,gBAAgB,IAAI,KAAK,CAAC,gBAAgB,CAAC,MAAM,KAAK,CAAC,CAAC;QAChE,CAAC,KAAK,CAAC,mBAAmB;QAC1B,CAAC,CAAC,KAAK,CAAC,MAAM,IAAI,KAAK,CAAC,MAAM,CAAC,MAAM,KAAK,CAAC,CAAC;QAC5C,CAAC,CAAC,KAAK,CAAC,SAAS,IAAI,KAAK,CAAC,SAAS,CAAC,MAAM,KAAK,CAAC,CAAC,CACnD,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,cAAc,CAAC,KAA0B;IACvD,IAAI,OAAO,CAAC,KAAK,CAAC;QAAE,OAAO,IAAI,CAAC;IAEhC,MAAM,EACJ,YAAY,EACZ,gBAAgB,EAChB,mBAAmB,EACnB,MAAM,EACN,SAAS,EACT,SAAS,GACV,GAAG,KAAK,CAAC;IAEV,OAAO,CACL,eAAK,SAAS,EAAE,EAAE,CAAC,YAAY,EAAE,SAAS,CAAC,aAExC,YAAY,IAAI,IAAI,IAAI,CACvB,eAAK,SAAS,EAAC,2BAA2B,aACxC,eAAM,SAAS,EAAC,oCAAoC,YAAE,YA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oryProfileProps {
|
|
2
|
+
/** Stages keyed by stage name, each containing field key/value pairs. */
|
|
3
|
+
sensoryDetails?: Record<string, Record<string, string | null> | null> | null;
|
|
4
|
+
/** Optional label overrides per stage key. */
|
|
5
|
+
stageLabels?: Record<string, string>;
|
|
6
|
+
/** Optional label overrides per field, keyed by stage then field. */
|
|
7
|
+
fieldLabels?: Record<string, Record<string, string>>;
|
|
8
|
+
className?: string;
|
|
9
|
+
}
|
|
10
|
+
export declare function SensoryProfile({ sensoryDetails, stageLabels, fieldLabels, className, }: SensoryProfileProps): import("react/jsx-runtime").JSX.Element | null;
|
|
11
|
+
//# sourceMappingURL=sensory-profile.d.ts.map
|