@appolabs/ui 0.1.29 → 0.1.31

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.
@@ -3,18 +3,27 @@
3
3
  var chunkK3WGYDSA_cjs = require('./chunk-K3WGYDSA.cjs');
4
4
  var jsxRuntime = require('react/jsx-runtime');
5
5
 
6
+ var defaultLabels = {
7
+ message: "Utilizziamo i cookie per migliorare la tua esperienza.",
8
+ policyLink: "Cookie policy",
9
+ manage: "Gestisci",
10
+ reject: "Rifiuta",
11
+ accept: "Accetta tutto"
12
+ };
6
13
  function CookieBanner({
7
14
  visible,
8
15
  cookiePolicyUrl,
9
16
  onAccept,
10
17
  onReject,
11
18
  onManage,
19
+ labels,
12
20
  className
13
21
  }) {
14
22
  if (!visible) return null;
23
+ const copy = { ...defaultLabels, ...labels };
15
24
  return /* @__PURE__ */ jsxRuntime.jsx("div", { className: chunkK3WGYDSA_cjs.cn("fixed bottom-0 left-0 right-0 z-50 sm:py-4 sm:px-4 md:px-6 lg:px-8", className), children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "sm:max-w-7xl sm:mx-auto", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "border border-white/10 bg-white/5 backdrop-blur-md flex flex-col gap-4 px-4 py-3 sm:rounded-xl sm:flex-row sm:items-center sm:justify-between", children: [
16
25
  /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "text-sm text-white/60", children: [
17
- "Utilizziamo i cookie per migliorare la tua esperienza.",
26
+ copy.message,
18
27
  " ",
19
28
  /* @__PURE__ */ jsxRuntime.jsx(
20
29
  "a",
@@ -23,7 +32,7 @@ function CookieBanner({
23
32
  className: "text-white underline underline-offset-2 hover:no-underline",
24
33
  target: "_blank",
25
34
  rel: "noreferrer",
26
- children: "Cookie policy"
35
+ children: copy.policyLink
27
36
  }
28
37
  )
29
38
  ] }),
@@ -34,7 +43,7 @@ function CookieBanner({
34
43
  type: "button",
35
44
  onClick: onManage,
36
45
  className: "h-9 cursor-pointer rounded-md px-3 text-sm text-white/60 transition-colors hover:underline",
37
- children: "Gestisci"
46
+ children: copy.manage
38
47
  }
39
48
  ),
40
49
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -43,7 +52,7 @@ function CookieBanner({
43
52
  type: "button",
44
53
  onClick: onReject,
45
54
  className: "h-9 cursor-pointer rounded-xl border border-white/20 px-3 text-sm text-white/70 transition-colors hover:bg-white/10",
46
- children: "Rifiuta"
55
+ children: copy.reject
47
56
  }
48
57
  ),
49
58
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -52,7 +61,7 @@ function CookieBanner({
52
61
  type: "button",
53
62
  onClick: onAccept,
54
63
  className: "h-9 cursor-pointer rounded-xl bg-gradient-to-r from-[#8a9eff] to-[#5e77cc] px-3 text-sm font-medium text-white transition-all hover:from-[#7a8eef] hover:to-[#4e67bc]",
55
- children: "Accetta tutto"
64
+ children: copy.accept
56
65
  }
57
66
  )
58
67
  ] })
@@ -60,5 +69,5 @@ function CookieBanner({
60
69
  }
61
70
 
62
71
  exports.CookieBanner = CookieBanner;
63
- //# sourceMappingURL=chunk-LLT7263D.cjs.map
64
- //# sourceMappingURL=chunk-LLT7263D.cjs.map
72
+ //# sourceMappingURL=chunk-5AE4EJNL.cjs.map
73
+ //# sourceMappingURL=chunk-5AE4EJNL.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/components/cookie-banner.tsx"],"names":["jsx","cn","jsxs"],"mappings":";;;;;AAoBA,IAAM,aAAA,GAAoC;AAAA,EACtC,OAAA,EAAS,wDAAA;AAAA,EACT,UAAA,EAAY,eAAA;AAAA,EACZ,MAAA,EAAQ,UAAA;AAAA,EACR,MAAA,EAAQ,SAAA;AAAA,EACR,MAAA,EAAQ;AACZ,CAAA;AAcO,SAAS,YAAA,CAAa;AAAA,EACzB,OAAA;AAAA,EACA,eAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,MAAA;AA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,cAAA;AAAA,QAAC,QAAA;AAAA,QAAA;AAAA,UACG,IAAA,EAAK,QAAA;AAAA,UACL,OAAA,EAAS,QAAA;AAAA,UACT,SAAA,EAAU,uKAAA;AAAA,UAET,QAAA,EAAA,IAAA,CAAK;AAAA;AAAA;AACV,KAAA,EACJ;AAAA,GAAA,EACJ,GACJ,CAAA,EACJ,CAAA;AAER","file":"chunk-5AE4EJNL.cjs","sourcesContent":["import { cn } from '../lib/utils';\n\nexport interface CookieBannerLabels {\n message: string;\n policyLink: string;\n manage: string;\n reject: string;\n accept: string;\n}\n\nexport interface CookieBannerProps {\n visible: boolean;\n cookiePolicyUrl: string;\n onAccept: () => void;\n onReject: () => void;\n onManage?: () => void;\n labels?: Partial<CookieBannerLabels>;\n className?: string;\n}\n\nconst defaultLabels: CookieBannerLabels = {\n message: 'Utilizziamo i cookie per migliorare la tua esperienza.',\n policyLink: 'Cookie policy',\n manage: 'Gestisci',\n reject: 'Rifiuta',\n accept: 'Accetta tutto',\n};\n\n/**\n * Brand-fixed cookie consent banner. Reads as a sibling system bar to the\n * site/app topbar: translucent `bg-white/5` + `backdrop-blur-md` over the\n * page's own background. Card design is the canonical Appo design-system\n * \"glass card\" — match this treatment in any new card-like surfaces.\n *\n * Copy is overridable through `labels` so a localized host can pass its own\n * translations; the defaults are Italian.\n *\n * If you need a different visual for a future product, do not add a variant\n * prop to this component — duplicate it under a different name.\n */\nexport function CookieBanner({\n visible,\n cookiePolicyUrl,\n onAccept,\n onReject,\n onManage,\n labels,\n className,\n}: CookieBannerProps) {\n if (!visible) return null;\n\n const copy = { ...defaultLabels, ...labels };\n\n return (\n <div className={cn('fixed bottom-0 left-0 right-0 z-50 sm:py-4 sm:px-4 md:px-6 lg:px-8', className)}>\n <div className=\"sm:max-w-7xl sm:mx-auto\">\n <div className=\"border border-white/10 bg-white/5 backdrop-blur-md flex flex-col gap-4 px-4 py-3 sm:rounded-xl sm:flex-row sm:items-center sm:justify-between\">\n <p className=\"text-sm text-white/60\">\n {copy.message}{' '}\n <a\n href={cookiePolicyUrl}\n className=\"text-white underline underline-offset-2 hover:no-underline\"\n target=\"_blank\"\n rel=\"noreferrer\"\n >\n {copy.policyLink}\n </a>\n </p>\n <div className=\"flex shrink-0 items-center gap-2 self-end sm:self-auto\">\n {onManage && (\n <button\n type=\"button\"\n onClick={onManage}\n className=\"h-9 cursor-pointer rounded-md px-3 text-sm text-white/60 transition-colors hover:underline\"\n >\n {copy.manage}\n </button>\n )}\n <button\n type=\"button\"\n onClick={onReject}\n className=\"h-9 cursor-pointer rounded-xl border border-white/20 px-3 text-sm text-white/70 transition-colors hover:bg-white/10\"\n >\n {copy.reject}\n </button>\n <button\n type=\"button\"\n onClick={onAccept}\n className=\"h-9 cursor-pointer rounded-xl bg-gradient-to-r from-[#8a9eff] to-[#5e77cc] px-3 text-sm font-medium text-white transition-all hover:from-[#7a8eef] hover:to-[#4e67bc]\"\n >\n {copy.accept}\n </button>\n </div>\n </div>\n </div>\n </div>\n );\n}\n"]}
@@ -1,18 +1,27 @@
1
1
  import { cn } from './chunk-C6QNNG2X.js';
2
2
  import { jsx, jsxs } from 'react/jsx-runtime';
3
3
 
4
+ var defaultLabels = {
5
+ message: "Utilizziamo i cookie per migliorare la tua esperienza.",
6
+ policyLink: "Cookie policy",
7
+ manage: "Gestisci",
8
+ reject: "Rifiuta",
9
+ accept: "Accetta tutto"
10
+ };
4
11
  function CookieBanner({
5
12
  visible,
6
13
  cookiePolicyUrl,
7
14
  onAccept,
8
15
  onReject,
9
16
  onManage,
17
+ labels,
10
18
  className
11
19
  }) {
12
20
  if (!visible) return null;
21
+ const copy = { ...defaultLabels, ...labels };
13
22
  return /* @__PURE__ */ jsx("div", { className: cn("fixed bottom-0 left-0 right-0 z-50 sm:py-4 sm:px-4 md:px-6 lg:px-8", className), children: /* @__PURE__ */ jsx("div", { className: "sm:max-w-7xl sm:mx-auto", children: /* @__PURE__ */ jsxs("div", { className: "border border-white/10 bg-white/5 backdrop-blur-md flex flex-col gap-4 px-4 py-3 sm:rounded-xl sm:flex-row sm:items-center sm:justify-between", children: [
14
23
  /* @__PURE__ */ jsxs("p", { className: "text-sm text-white/60", children: [
15
- "Utilizziamo i cookie per migliorare la tua esperienza.",
24
+ copy.message,
16
25
  " ",
17
26
  /* @__PURE__ */ jsx(
18
27
  "a",
@@ -21,7 +30,7 @@ function CookieBanner({
21
30
  className: "text-white underline underline-offset-2 hover:no-underline",
22
31
  target: "_blank",
23
32
  rel: "noreferrer",
24
- children: "Cookie policy"
33
+ children: copy.policyLink
25
34
  }
26
35
  )
27
36
  ] }),
@@ -32,7 +41,7 @@ function CookieBanner({
32
41
  type: "button",
33
42
  onClick: onManage,
34
43
  className: "h-9 cursor-pointer rounded-md px-3 text-sm text-white/60 transition-colors hover:underline",
35
- children: "Gestisci"
44
+ children: copy.manage
36
45
  }
37
46
  ),
38
47
  /* @__PURE__ */ jsx(
@@ -41,7 +50,7 @@ function CookieBanner({
41
50
  type: "button",
42
51
  onClick: onReject,
43
52
  className: "h-9 cursor-pointer rounded-xl border border-white/20 px-3 text-sm text-white/70 transition-colors hover:bg-white/10",
44
- children: "Rifiuta"
53
+ children: copy.reject
45
54
  }
46
55
  ),
47
56
  /* @__PURE__ */ jsx(
@@ -50,7 +59,7 @@ function CookieBanner({
50
59
  type: "button",
51
60
  onClick: onAccept,
52
61
  className: "h-9 cursor-pointer rounded-xl bg-gradient-to-r from-[#8a9eff] to-[#5e77cc] px-3 text-sm font-medium text-white transition-all hover:from-[#7a8eef] hover:to-[#4e67bc]",
53
- children: "Accetta tutto"
62
+ children: copy.accept
54
63
  }
55
64
  )
56
65
  ] })
@@ -58,5 +67,5 @@ function CookieBanner({
58
67
  }
59
68
 
60
69
  export { CookieBanner };
61
- //# sourceMappingURL=chunk-JIIMGSA2.js.map
62
- //# sourceMappingURL=chunk-JIIMGSA2.js.map
70
+ //# sourceMappingURL=chunk-SWGYVBN7.js.map
71
+ //# sourceMappingURL=chunk-SWGYVBN7.js.map
@@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AAA,QAAC,QAAA;AAAA,QAAA;AAAA,UACG,IAAA,EAAK,QAAA;AAAA,UACL,OAAA,EAAS,QAAA;AAAA,UACT,SAAA,EAAU,4FAAA;AAAA,UAET,QAAA,EAAA,IAAA,CAAK;AAAA;AAAA,OACV;AAAA,sBAEJ,GAAA;AAAA,QAAC,QAAA;AAAA,QAAA;AAAA,UACG,IAAA,EAAK,QAAA;AAAA,UACL,OAAA,EAAS,QAAA;AAAA,UACT,SAAA,EAAU,qHAAA;AAAA,UAET,QAAA,EAAA,IAAA,CAAK;AAAA;AAAA,OACV;AAAA,sBACA,GAAA;AAAA,QAAC,QAAA;AAAA,QAAA;AAAA,UACG,IAAA,EAAK,QAAA;AAAA,UACL,OAAA,EAAS,QAAA;AAAA,UACT,SAAA,EAAU,uKAAA;AAAA,UAET,QAAA,EAAA,IAAA,CAAK;AAAA;AAAA;AACV,KAAA,EACJ;AAAA,GAAA,EACJ,GACJ,CAAA,EACJ,CAAA;AAER","file":"chunk-SWGYVBN7.js","sourcesContent":["import { cn } from '../lib/utils';\n\nexport interface CookieBannerLabels {\n message: string;\n policyLink: string;\n manage: string;\n reject: string;\n accept: string;\n}\n\nexport interface CookieBannerProps {\n visible: boolean;\n cookiePolicyUrl: string;\n onAccept: () => void;\n onReject: () => void;\n onManage?: () => void;\n labels?: Partial<CookieBannerLabels>;\n className?: string;\n}\n\nconst defaultLabels: CookieBannerLabels = {\n message: 'Utilizziamo i cookie per migliorare la tua esperienza.',\n policyLink: 'Cookie policy',\n manage: 'Gestisci',\n reject: 'Rifiuta',\n accept: 'Accetta tutto',\n};\n\n/**\n * Brand-fixed cookie consent banner. Reads as a sibling system bar to the\n * site/app topbar: translucent `bg-white/5` + `backdrop-blur-md` over the\n * page's own background. Card design is the canonical Appo design-system\n * \"glass card\" — match this treatment in any new card-like surfaces.\n *\n * Copy is overridable through `labels` so a localized host can pass its own\n * translations; the defaults are Italian.\n *\n * If you need a different visual for a future product, do not add a variant\n * prop to this component — duplicate it under a different name.\n */\nexport function CookieBanner({\n visible,\n cookiePolicyUrl,\n onAccept,\n onReject,\n onManage,\n labels,\n className,\n}: CookieBannerProps) {\n if (!visible) return null;\n\n const copy = { ...defaultLabels, ...labels };\n\n return (\n <div className={cn('fixed bottom-0 left-0 right-0 z-50 sm:py-4 sm:px-4 md:px-6 lg:px-8', className)}>\n <div className=\"sm:max-w-7xl sm:mx-auto\">\n <div className=\"border border-white/10 bg-white/5 backdrop-blur-md flex flex-col gap-4 px-4 py-3 sm:rounded-xl sm:flex-row sm:items-center sm:justify-between\">\n <p className=\"text-sm text-white/60\">\n {copy.message}{' '}\n <a\n href={cookiePolicyUrl}\n className=\"text-white underline underline-offset-2 hover:no-underline\"\n target=\"_blank\"\n rel=\"noreferrer\"\n >\n {copy.policyLink}\n </a>\n </p>\n <div className=\"flex shrink-0 items-center gap-2 self-end sm:self-auto\">\n {onManage && (\n <button\n type=\"button\"\n onClick={onManage}\n className=\"h-9 cursor-pointer rounded-md px-3 text-sm text-white/60 transition-colors hover:underline\"\n >\n {copy.manage}\n </button>\n )}\n <button\n type=\"button\"\n onClick={onReject}\n className=\"h-9 cursor-pointer rounded-xl border border-white/20 px-3 text-sm text-white/70 transition-colors hover:bg-white/10\"\n >\n {copy.reject}\n </button>\n <button\n type=\"button\"\n onClick={onAccept}\n className=\"h-9 cursor-pointer rounded-xl bg-gradient-to-r from-[#8a9eff] to-[#5e77cc] px-3 text-sm font-medium text-white transition-all hover:from-[#7a8eef] hover:to-[#4e67bc]\"\n >\n {copy.accept}\n </button>\n </div>\n </div>\n </div>\n </div>\n );\n}\n"]}
@@ -8,7 +8,7 @@ declare const Command: React.ForwardRefExoticComponent<Omit<{
8
8
  ref?: React.Ref<HTMLDivElement>;
9
9
  } & {
10
10
  asChild?: boolean;
11
- }, "key" | keyof React.HTMLAttributes<HTMLDivElement> | "asChild"> & {
11
+ }, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & {
12
12
  label?: string;
13
13
  shouldFilter?: boolean;
14
14
  filter?: (value: string, search: string, keywords?: string[]) => number;
@@ -26,7 +26,7 @@ declare const CommandInput: React.ForwardRefExoticComponent<Omit<Omit<Pick<Pick<
26
26
  ref?: React.Ref<HTMLInputElement>;
27
27
  } & {
28
28
  asChild?: boolean;
29
- }, "key" | "asChild" | keyof React.InputHTMLAttributes<HTMLInputElement>>, "onChange" | "value" | "type"> & {
29
+ }, "key" | "asChild" | keyof React.InputHTMLAttributes<HTMLInputElement>>, "type" | "onChange" | "value"> & {
30
30
  value?: string;
31
31
  onValueChange?: (search: string) => void;
32
32
  } & React.RefAttributes<HTMLInputElement>, "ref"> & React.RefAttributes<HTMLInputElement>>;
@@ -36,7 +36,7 @@ declare const CommandList: React.ForwardRefExoticComponent<Omit<{
36
36
  ref?: React.Ref<HTMLDivElement>;
37
37
  } & {
38
38
  asChild?: boolean;
39
- }, "key" | keyof React.HTMLAttributes<HTMLDivElement> | "asChild"> & {
39
+ }, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & {
40
40
  label?: string;
41
41
  } & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
42
42
  declare const CommandEmpty: React.ForwardRefExoticComponent<Omit<{
@@ -45,14 +45,14 @@ declare const CommandEmpty: React.ForwardRefExoticComponent<Omit<{
45
45
  ref?: React.Ref<HTMLDivElement>;
46
46
  } & {
47
47
  asChild?: boolean;
48
- }, "key" | keyof React.HTMLAttributes<HTMLDivElement> | "asChild"> & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
48
+ }, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
49
49
  declare const CommandGroup: React.ForwardRefExoticComponent<Omit<{
50
50
  children?: React.ReactNode;
51
51
  } & Omit<Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
52
52
  ref?: React.Ref<HTMLDivElement>;
53
53
  } & {
54
54
  asChild?: boolean;
55
- }, "key" | keyof React.HTMLAttributes<HTMLDivElement> | "asChild">, "value" | "heading"> & {
55
+ }, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>>, "value" | "heading"> & {
56
56
  heading?: React.ReactNode;
57
57
  value?: string;
58
58
  forceMount?: boolean;
@@ -61,7 +61,7 @@ declare const CommandSeparator: React.ForwardRefExoticComponent<Omit<Pick<Pick<R
61
61
  ref?: React.Ref<HTMLDivElement>;
62
62
  } & {
63
63
  asChild?: boolean;
64
- }, "key" | keyof React.HTMLAttributes<HTMLDivElement> | "asChild"> & {
64
+ }, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & {
65
65
  alwaysRender?: boolean;
66
66
  } & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
67
67
  declare const CommandItem: React.ForwardRefExoticComponent<Omit<{
@@ -70,7 +70,7 @@ declare const CommandItem: React.ForwardRefExoticComponent<Omit<{
70
70
  ref?: React.Ref<HTMLDivElement>;
71
71
  } & {
72
72
  asChild?: boolean;
73
- }, "key" | keyof React.HTMLAttributes<HTMLDivElement> | "asChild">, "onSelect" | "disabled" | "value"> & {
73
+ }, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>>, "onSelect" | "disabled" | "value"> & {
74
74
  disabled?: boolean;
75
75
  onSelect?: (value: string) => void;
76
76
  value?: string;
package/dist/command.d.ts CHANGED
@@ -8,7 +8,7 @@ declare const Command: React.ForwardRefExoticComponent<Omit<{
8
8
  ref?: React.Ref<HTMLDivElement>;
9
9
  } & {
10
10
  asChild?: boolean;
11
- }, "key" | keyof React.HTMLAttributes<HTMLDivElement> | "asChild"> & {
11
+ }, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & {
12
12
  label?: string;
13
13
  shouldFilter?: boolean;
14
14
  filter?: (value: string, search: string, keywords?: string[]) => number;
@@ -26,7 +26,7 @@ declare const CommandInput: React.ForwardRefExoticComponent<Omit<Omit<Pick<Pick<
26
26
  ref?: React.Ref<HTMLInputElement>;
27
27
  } & {
28
28
  asChild?: boolean;
29
- }, "key" | "asChild" | keyof React.InputHTMLAttributes<HTMLInputElement>>, "onChange" | "value" | "type"> & {
29
+ }, "key" | "asChild" | keyof React.InputHTMLAttributes<HTMLInputElement>>, "type" | "onChange" | "value"> & {
30
30
  value?: string;
31
31
  onValueChange?: (search: string) => void;
32
32
  } & React.RefAttributes<HTMLInputElement>, "ref"> & React.RefAttributes<HTMLInputElement>>;
@@ -36,7 +36,7 @@ declare const CommandList: React.ForwardRefExoticComponent<Omit<{
36
36
  ref?: React.Ref<HTMLDivElement>;
37
37
  } & {
38
38
  asChild?: boolean;
39
- }, "key" | keyof React.HTMLAttributes<HTMLDivElement> | "asChild"> & {
39
+ }, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & {
40
40
  label?: string;
41
41
  } & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
42
42
  declare const CommandEmpty: React.ForwardRefExoticComponent<Omit<{
@@ -45,14 +45,14 @@ declare const CommandEmpty: React.ForwardRefExoticComponent<Omit<{
45
45
  ref?: React.Ref<HTMLDivElement>;
46
46
  } & {
47
47
  asChild?: boolean;
48
- }, "key" | keyof React.HTMLAttributes<HTMLDivElement> | "asChild"> & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
48
+ }, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
49
49
  declare const CommandGroup: React.ForwardRefExoticComponent<Omit<{
50
50
  children?: React.ReactNode;
51
51
  } & Omit<Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
52
52
  ref?: React.Ref<HTMLDivElement>;
53
53
  } & {
54
54
  asChild?: boolean;
55
- }, "key" | keyof React.HTMLAttributes<HTMLDivElement> | "asChild">, "value" | "heading"> & {
55
+ }, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>>, "value" | "heading"> & {
56
56
  heading?: React.ReactNode;
57
57
  value?: string;
58
58
  forceMount?: boolean;
@@ -61,7 +61,7 @@ declare const CommandSeparator: React.ForwardRefExoticComponent<Omit<Pick<Pick<R
61
61
  ref?: React.Ref<HTMLDivElement>;
62
62
  } & {
63
63
  asChild?: boolean;
64
- }, "key" | keyof React.HTMLAttributes<HTMLDivElement> | "asChild"> & {
64
+ }, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & {
65
65
  alwaysRender?: boolean;
66
66
  } & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
67
67
  declare const CommandItem: React.ForwardRefExoticComponent<Omit<{
@@ -70,7 +70,7 @@ declare const CommandItem: React.ForwardRefExoticComponent<Omit<{
70
70
  ref?: React.Ref<HTMLDivElement>;
71
71
  } & {
72
72
  asChild?: boolean;
73
- }, "key" | keyof React.HTMLAttributes<HTMLDivElement> | "asChild">, "onSelect" | "disabled" | "value"> & {
73
+ }, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>>, "onSelect" | "disabled" | "value"> & {
74
74
  disabled?: boolean;
75
75
  onSelect?: (value: string) => void;
76
76
  value?: string;
@@ -1,13 +1,13 @@
1
1
  'use strict';
2
2
 
3
- var chunkLLT7263D_cjs = require('./chunk-LLT7263D.cjs');
3
+ var chunk5AE4EJNL_cjs = require('./chunk-5AE4EJNL.cjs');
4
4
  require('./chunk-K3WGYDSA.cjs');
5
5
 
6
6
 
7
7
 
8
8
  Object.defineProperty(exports, "CookieBanner", {
9
9
  enumerable: true,
10
- get: function () { return chunkLLT7263D_cjs.CookieBanner; }
10
+ get: function () { return chunk5AE4EJNL_cjs.CookieBanner; }
11
11
  });
12
12
  //# sourceMappingURL=cookie-banner.cjs.map
13
13
  //# sourceMappingURL=cookie-banner.cjs.map
@@ -1,11 +1,19 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
 
3
+ interface CookieBannerLabels {
4
+ message: string;
5
+ policyLink: string;
6
+ manage: string;
7
+ reject: string;
8
+ accept: string;
9
+ }
3
10
  interface CookieBannerProps {
4
11
  visible: boolean;
5
12
  cookiePolicyUrl: string;
6
13
  onAccept: () => void;
7
14
  onReject: () => void;
8
15
  onManage?: () => void;
16
+ labels?: Partial<CookieBannerLabels>;
9
17
  className?: string;
10
18
  }
11
19
  /**
@@ -14,9 +22,12 @@ interface CookieBannerProps {
14
22
  * page's own background. Card design is the canonical Appo design-system
15
23
  * "glass card" — match this treatment in any new card-like surfaces.
16
24
  *
25
+ * Copy is overridable through `labels` so a localized host can pass its own
26
+ * translations; the defaults are Italian.
27
+ *
17
28
  * If you need a different visual for a future product, do not add a variant
18
29
  * prop to this component — duplicate it under a different name.
19
30
  */
20
- declare function CookieBanner({ visible, cookiePolicyUrl, onAccept, onReject, onManage, className, }: CookieBannerProps): react_jsx_runtime.JSX.Element | null;
31
+ declare function CookieBanner({ visible, cookiePolicyUrl, onAccept, onReject, onManage, labels, className, }: CookieBannerProps): react_jsx_runtime.JSX.Element | null;
21
32
 
22
- export { CookieBanner, type CookieBannerProps };
33
+ export { CookieBanner, type CookieBannerLabels, type CookieBannerProps };
@@ -1,11 +1,19 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
 
3
+ interface CookieBannerLabels {
4
+ message: string;
5
+ policyLink: string;
6
+ manage: string;
7
+ reject: string;
8
+ accept: string;
9
+ }
3
10
  interface CookieBannerProps {
4
11
  visible: boolean;
5
12
  cookiePolicyUrl: string;
6
13
  onAccept: () => void;
7
14
  onReject: () => void;
8
15
  onManage?: () => void;
16
+ labels?: Partial<CookieBannerLabels>;
9
17
  className?: string;
10
18
  }
11
19
  /**
@@ -14,9 +22,12 @@ interface CookieBannerProps {
14
22
  * page's own background. Card design is the canonical Appo design-system
15
23
  * "glass card" — match this treatment in any new card-like surfaces.
16
24
  *
25
+ * Copy is overridable through `labels` so a localized host can pass its own
26
+ * translations; the defaults are Italian.
27
+ *
17
28
  * If you need a different visual for a future product, do not add a variant
18
29
  * prop to this component — duplicate it under a different name.
19
30
  */
20
- declare function CookieBanner({ visible, cookiePolicyUrl, onAccept, onReject, onManage, className, }: CookieBannerProps): react_jsx_runtime.JSX.Element | null;
31
+ declare function CookieBanner({ visible, cookiePolicyUrl, onAccept, onReject, onManage, labels, className, }: CookieBannerProps): react_jsx_runtime.JSX.Element | null;
21
32
 
22
- export { CookieBanner, type CookieBannerProps };
33
+ export { CookieBanner, type CookieBannerLabels, type CookieBannerProps };
@@ -1,4 +1,4 @@
1
- export { CookieBanner } from './chunk-JIIMGSA2.js';
1
+ export { CookieBanner } from './chunk-SWGYVBN7.js';
2
2
  import './chunk-C6QNNG2X.js';
3
3
  //# sourceMappingURL=cookie-banner.js.map
4
4
  //# sourceMappingURL=cookie-banner.js.map
package/dist/index.cjs CHANGED
@@ -36,7 +36,7 @@ var chunk3WUKE7HN_cjs = require('./chunk-3WUKE7HN.cjs');
36
36
  var chunkCAHV7CMU_cjs = require('./chunk-CAHV7CMU.cjs');
37
37
  var chunkJQM7U4HY_cjs = require('./chunk-JQM7U4HY.cjs');
38
38
  var chunkP5VBESJ3_cjs = require('./chunk-P5VBESJ3.cjs');
39
- var chunkLLT7263D_cjs = require('./chunk-LLT7263D.cjs');
39
+ var chunk5AE4EJNL_cjs = require('./chunk-5AE4EJNL.cjs');
40
40
  var chunk3CWEXWUR_cjs = require('./chunk-3CWEXWUR.cjs');
41
41
  var chunk3SQHEJFP_cjs = require('./chunk-3SQHEJFP.cjs');
42
42
  var chunkAPCEE7AC_cjs = require('./chunk-APCEE7AC.cjs');
@@ -755,7 +755,7 @@ Object.defineProperty(exports, "ContextMenuTrigger", {
755
755
  });
756
756
  Object.defineProperty(exports, "CookieBanner", {
757
757
  enumerable: true,
758
- get: function () { return chunkLLT7263D_cjs.CookieBanner; }
758
+ get: function () { return chunk5AE4EJNL_cjs.CookieBanner; }
759
759
  });
760
760
  Object.defineProperty(exports, "Dialog", {
761
761
  enumerable: true,
package/dist/index.d.cts CHANGED
@@ -4,7 +4,7 @@ import { ToastProps, ToastActionElement } from './toast.cjs';
4
4
  export { Toast, ToastAction, ToastClose, ToastDescription, ToastProvider, ToastTitle, ToastViewport } from './toast.cjs';
5
5
  export { Accordion, AccordionContent, AccordionItem, AccordionTrigger } from './accordion.cjs';
6
6
  export { Alert, AlertDescription, AlertTitle } from './alert.cjs';
7
- export { CookieBanner, CookieBannerProps } from './cookie-banner.cjs';
7
+ export { CookieBanner, CookieBannerLabels, CookieBannerProps } from './cookie-banner.cjs';
8
8
  export { AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger } from './alert-dialog.cjs';
9
9
  export { AnimatedBackground, GradientOrb } from './animated-background.cjs';
10
10
  export { AspectRatio } from './aspect-ratio.cjs';
package/dist/index.d.ts CHANGED
@@ -4,7 +4,7 @@ import { ToastProps, ToastActionElement } from './toast.js';
4
4
  export { Toast, ToastAction, ToastClose, ToastDescription, ToastProvider, ToastTitle, ToastViewport } from './toast.js';
5
5
  export { Accordion, AccordionContent, AccordionItem, AccordionTrigger } from './accordion.js';
6
6
  export { Alert, AlertDescription, AlertTitle } from './alert.js';
7
- export { CookieBanner, CookieBannerProps } from './cookie-banner.js';
7
+ export { CookieBanner, CookieBannerLabels, CookieBannerProps } from './cookie-banner.js';
8
8
  export { AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger } from './alert-dialog.js';
9
9
  export { AnimatedBackground, GradientOrb } from './animated-background.js';
10
10
  export { AspectRatio } from './aspect-ratio.js';
package/dist/index.js CHANGED
@@ -34,7 +34,7 @@ export { Input, inputVariants } from './chunk-53CK5CTK.js';
34
34
  export { Collapsible, CollapsibleContent, CollapsibleTrigger } from './chunk-ONTWZWVJ.js';
35
35
  export { Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut } from './chunk-ZVMXDLJ3.js';
36
36
  export { ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger } from './chunk-XUSP522X.js';
37
- export { CookieBanner } from './chunk-JIIMGSA2.js';
37
+ export { CookieBanner } from './chunk-SWGYVBN7.js';
38
38
  export { Dialog, DialogBody, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogSteps, DialogTitle, DialogTrigger } from './chunk-652R2JBT.js';
39
39
  export { Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger } from './chunk-VHVVKUFM.js';
40
40
  export { DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger } from './chunk-FOTJ6OCK.js';
@@ -3,7 +3,7 @@ import * as react_jsx_runtime from 'react/jsx-runtime';
3
3
  import * as ResizablePrimitive from 'react-resizable-panels';
4
4
 
5
5
  declare const ResizablePanelGroup: ({ className, ...props }: React.ComponentProps<typeof ResizablePrimitive.PanelGroup>) => react_jsx_runtime.JSX.Element;
6
- declare const ResizablePanel: React$1.ForwardRefExoticComponent<Omit<React$1.HTMLAttributes<HTMLDivElement | HTMLElement | HTMLObjectElement | HTMLAnchorElement | HTMLButtonElement | HTMLFormElement | HTMLHeadingElement | HTMLImageElement | HTMLInputElement | HTMLLabelElement | HTMLLIElement | HTMLOListElement | HTMLParagraphElement | HTMLSelectElement | HTMLSpanElement | HTMLUListElement | HTMLAreaElement | HTMLAudioElement | HTMLBaseElement | HTMLQuoteElement | HTMLBodyElement | HTMLBRElement | HTMLCanvasElement | HTMLTableColElement | HTMLDataElement | HTMLDataListElement | HTMLModElement | HTMLDetailsElement | HTMLDialogElement | HTMLDListElement | HTMLEmbedElement | HTMLFieldSetElement | HTMLHeadElement | HTMLHRElement | HTMLHtmlElement | HTMLIFrameElement | HTMLLegendElement | HTMLLinkElement | HTMLMapElement | HTMLMetaElement | HTMLMeterElement | HTMLOptGroupElement | HTMLOptionElement | HTMLOutputElement | HTMLPreElement | HTMLProgressElement | HTMLSlotElement | HTMLScriptElement | HTMLSourceElement | HTMLStyleElement | HTMLTableElement | HTMLTemplateElement | HTMLTableSectionElement | HTMLTableCellElement | HTMLTextAreaElement | HTMLTimeElement | HTMLTitleElement | HTMLTableRowElement | HTMLTrackElement | HTMLVideoElement | HTMLTableCaptionElement | HTMLMenuElement | HTMLPictureElement>, "id" | "onResize"> & {
6
+ declare const ResizablePanel: React$1.ForwardRefExoticComponent<Omit<React$1.HTMLAttributes<HTMLOListElement | HTMLElement | HTMLObjectElement | HTMLAnchorElement | HTMLButtonElement | HTMLDivElement | HTMLFormElement | HTMLHeadingElement | HTMLImageElement | HTMLInputElement | HTMLLabelElement | HTMLLIElement | HTMLParagraphElement | HTMLSelectElement | HTMLSpanElement | HTMLUListElement | HTMLAreaElement | HTMLAudioElement | HTMLBaseElement | HTMLQuoteElement | HTMLBodyElement | HTMLBRElement | HTMLCanvasElement | HTMLTableColElement | HTMLDataElement | HTMLDataListElement | HTMLModElement | HTMLDetailsElement | HTMLDialogElement | HTMLDListElement | HTMLEmbedElement | HTMLFieldSetElement | HTMLHeadElement | HTMLHRElement | HTMLHtmlElement | HTMLIFrameElement | HTMLLegendElement | HTMLLinkElement | HTMLMapElement | HTMLMetaElement | HTMLMeterElement | HTMLOptGroupElement | HTMLOptionElement | HTMLOutputElement | HTMLPreElement | HTMLProgressElement | HTMLSlotElement | HTMLScriptElement | HTMLSourceElement | HTMLStyleElement | HTMLTableElement | HTMLTemplateElement | HTMLTableSectionElement | HTMLTableCellElement | HTMLTextAreaElement | HTMLTimeElement | HTMLTitleElement | HTMLTableRowElement | HTMLTrackElement | HTMLVideoElement | HTMLTableCaptionElement | HTMLMenuElement | HTMLPictureElement>, "id" | "onResize"> & {
7
7
  className?: string | undefined;
8
8
  collapsedSize?: number | undefined;
9
9
  collapsible?: boolean | undefined;
@@ -3,7 +3,7 @@ import * as react_jsx_runtime from 'react/jsx-runtime';
3
3
  import * as ResizablePrimitive from 'react-resizable-panels';
4
4
 
5
5
  declare const ResizablePanelGroup: ({ className, ...props }: React.ComponentProps<typeof ResizablePrimitive.PanelGroup>) => react_jsx_runtime.JSX.Element;
6
- declare const ResizablePanel: React$1.ForwardRefExoticComponent<Omit<React$1.HTMLAttributes<HTMLDivElement | HTMLElement | HTMLObjectElement | HTMLAnchorElement | HTMLButtonElement | HTMLFormElement | HTMLHeadingElement | HTMLImageElement | HTMLInputElement | HTMLLabelElement | HTMLLIElement | HTMLOListElement | HTMLParagraphElement | HTMLSelectElement | HTMLSpanElement | HTMLUListElement | HTMLAreaElement | HTMLAudioElement | HTMLBaseElement | HTMLQuoteElement | HTMLBodyElement | HTMLBRElement | HTMLCanvasElement | HTMLTableColElement | HTMLDataElement | HTMLDataListElement | HTMLModElement | HTMLDetailsElement | HTMLDialogElement | HTMLDListElement | HTMLEmbedElement | HTMLFieldSetElement | HTMLHeadElement | HTMLHRElement | HTMLHtmlElement | HTMLIFrameElement | HTMLLegendElement | HTMLLinkElement | HTMLMapElement | HTMLMetaElement | HTMLMeterElement | HTMLOptGroupElement | HTMLOptionElement | HTMLOutputElement | HTMLPreElement | HTMLProgressElement | HTMLSlotElement | HTMLScriptElement | HTMLSourceElement | HTMLStyleElement | HTMLTableElement | HTMLTemplateElement | HTMLTableSectionElement | HTMLTableCellElement | HTMLTextAreaElement | HTMLTimeElement | HTMLTitleElement | HTMLTableRowElement | HTMLTrackElement | HTMLVideoElement | HTMLTableCaptionElement | HTMLMenuElement | HTMLPictureElement>, "id" | "onResize"> & {
6
+ declare const ResizablePanel: React$1.ForwardRefExoticComponent<Omit<React$1.HTMLAttributes<HTMLOListElement | HTMLElement | HTMLObjectElement | HTMLAnchorElement | HTMLButtonElement | HTMLDivElement | HTMLFormElement | HTMLHeadingElement | HTMLImageElement | HTMLInputElement | HTMLLabelElement | HTMLLIElement | HTMLParagraphElement | HTMLSelectElement | HTMLSpanElement | HTMLUListElement | HTMLAreaElement | HTMLAudioElement | HTMLBaseElement | HTMLQuoteElement | HTMLBodyElement | HTMLBRElement | HTMLCanvasElement | HTMLTableColElement | HTMLDataElement | HTMLDataListElement | HTMLModElement | HTMLDetailsElement | HTMLDialogElement | HTMLDListElement | HTMLEmbedElement | HTMLFieldSetElement | HTMLHeadElement | HTMLHRElement | HTMLHtmlElement | HTMLIFrameElement | HTMLLegendElement | HTMLLinkElement | HTMLMapElement | HTMLMetaElement | HTMLMeterElement | HTMLOptGroupElement | HTMLOptionElement | HTMLOutputElement | HTMLPreElement | HTMLProgressElement | HTMLSlotElement | HTMLScriptElement | HTMLSourceElement | HTMLStyleElement | HTMLTableElement | HTMLTemplateElement | HTMLTableSectionElement | HTMLTableCellElement | HTMLTextAreaElement | HTMLTimeElement | HTMLTitleElement | HTMLTableRowElement | HTMLTrackElement | HTMLVideoElement | HTMLTableCaptionElement | HTMLMenuElement | HTMLPictureElement>, "id" | "onResize"> & {
7
7
  className?: string | undefined;
8
8
  collapsedSize?: number | undefined;
9
9
  collapsible?: boolean | undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@appolabs/ui",
3
- "version": "0.1.29",
3
+ "version": "0.1.31",
4
4
  "description": "React UI component library for Appo Labs",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -64,6 +64,17 @@
64
64
  "sideEffects": [
65
65
  "**/*.css"
66
66
  ],
67
+ "scripts": {
68
+ "dev": "tsup --watch",
69
+ "build": "tsup",
70
+ "lint": "eslint 'src/**/*.{ts,tsx}'",
71
+ "lint:fix": "eslint 'src/**/*.{ts,tsx}' --fix",
72
+ "format": "prettier --write 'src/**/*.{ts,tsx}'",
73
+ "typecheck": "tsc --noEmit",
74
+ "test": "vitest run",
75
+ "test:watch": "vitest",
76
+ "prepublishOnly": "pnpm build"
77
+ },
67
78
  "peerDependencies": {
68
79
  "react": "^18.0.0 || ^19.0.0",
69
80
  "react-dom": "^18.0.0 || ^19.0.0",
@@ -147,15 +158,5 @@
147
158
  },
148
159
  "publishConfig": {
149
160
  "access": "public"
150
- },
151
- "scripts": {
152
- "dev": "tsup --watch",
153
- "build": "tsup",
154
- "lint": "eslint 'src/**/*.{ts,tsx}'",
155
- "lint:fix": "eslint 'src/**/*.{ts,tsx}' --fix",
156
- "format": "prettier --write 'src/**/*.{ts,tsx}'",
157
- "typecheck": "tsc --noEmit",
158
- "test": "vitest run",
159
- "test:watch": "vitest"
160
161
  }
161
- }
162
+ }
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/components/cookie-banner.tsx"],"names":[],"mappings":";;;AAoBO,SAAS,YAAA,CAAa;AAAA,EACzB,OAAA;AAAA,EACA,eAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA;AACJ,CAAA,EAAsB;AAClB,EAAA,IAAI,CAAC,SAAS,OAAO,IAAA;AAErB,EAAA,uBACI,GAAA,CAAC,KAAA,EAAA,EAAI,SAAA,EAAW,EAAA,CAAG,sEAAsE,SAAS,CAAA,EAC9F,QAAA,kBAAA,GAAA,CAAC,KAAA,EAAA,EAAI,SAAA,EAAU,yBAAA,EACX,QAAA,kBAAA,IAAA,CAAC,KAAA,EAAA,EAAI,WAAU,+IAAA,EACX,QAAA,EAAA;AAAA,oBAAA,IAAA,CAAC,GAAA,EAAA,EAAE,WAAU,uBAAA,EAAwB,QAAA,EAAA;AAAA,MAAA,wDAAA;AAAA,MACsB,GAAA;AAAA,sBACvD,GAAA;AAAA,QAAC,GAAA;AAAA,QAAA;AAAA,UACG,IAAA,EAAM,eAAA;AAAA,UACN,SAAA,EAAU,4DAAA;AAAA,UACV,MAAA,EAAO,QAAA;AAAA,UACP,GAAA,EAAI,YAAA;AAAA,UACP,QAAA,EAAA;AAAA;AAAA;AAED,KAAA,EACJ,CAAA;AAAA,oBACA,IAAA,CAAC,KAAA,EAAA,EAAI,SAAA,EAAU,wDAAA,EACV,QAAA,EAAA;AAAA,MAAA,QAAA,oBACG,GAAA;AAAA,QAAC,QAAA;AAAA,QAAA;AAAA,UACG,IAAA,EAAK,QAAA;AAAA,UACL,OAAA,EAAS,QAAA;AAAA,UACT,SAAA,EAAU,4FAAA;AAAA,UACb,QAAA,EAAA;AAAA;AAAA,OAED;AAAA,sBAEJ,GAAA;AAAA,QAAC,QAAA;AAAA,QAAA;AAAA,UACG,IAAA,EAAK,QAAA;AAAA,UACL,OAAA,EAAS,QAAA;AAAA,UACT,SAAA,EAAU,qHAAA;AAAA,UACb,QAAA,EAAA;AAAA;AAAA,OAED;AAAA,sBACA,GAAA;AAAA,QAAC,QAAA;AAAA,QAAA;AAAA,UACG,IAAA,EAAK,QAAA;AAAA,UACL,OAAA,EAAS,QAAA;AAAA,UACT,SAAA,EAAU,uKAAA;AAAA,UACb,QAAA,EAAA;AAAA;AAAA;AAED,KAAA,EACJ;AAAA,GAAA,EACJ,GACJ,CAAA,EACJ,CAAA;AAER","file":"chunk-JIIMGSA2.js","sourcesContent":["import { cn } from '../lib/utils';\n\nexport interface CookieBannerProps {\n visible: boolean;\n cookiePolicyUrl: string;\n onAccept: () => void;\n onReject: () => void;\n onManage?: () => void;\n className?: string;\n}\n\n/**\n * Brand-fixed cookie consent banner. Reads as a sibling system bar to the\n * site/app topbar: translucent `bg-white/5` + `backdrop-blur-md` over the\n * page's own background. Card design is the canonical Appo design-system\n * \"glass card\" — match this treatment in any new card-like surfaces.\n *\n * If you need a different visual for a future product, do not add a variant\n * prop to this component — duplicate it under a different name.\n */\nexport function CookieBanner({\n visible,\n cookiePolicyUrl,\n onAccept,\n onReject,\n onManage,\n className,\n}: CookieBannerProps) {\n if (!visible) return null;\n\n return (\n <div className={cn('fixed bottom-0 left-0 right-0 z-50 sm:py-4 sm:px-4 md:px-6 lg:px-8', className)}>\n <div className=\"sm:max-w-7xl sm:mx-auto\">\n <div className=\"border border-white/10 bg-white/5 backdrop-blur-md flex flex-col gap-4 px-4 py-3 sm:rounded-xl sm:flex-row sm:items-center sm:justify-between\">\n <p className=\"text-sm text-white/60\">\n Utilizziamo i cookie per migliorare la tua esperienza.{' '}\n <a\n href={cookiePolicyUrl}\n className=\"text-white underline underline-offset-2 hover:no-underline\"\n target=\"_blank\"\n rel=\"noreferrer\"\n >\n Cookie policy\n </a>\n </p>\n <div className=\"flex shrink-0 items-center gap-2 self-end sm:self-auto\">\n {onManage && (\n <button\n type=\"button\"\n onClick={onManage}\n className=\"h-9 cursor-pointer rounded-md px-3 text-sm text-white/60 transition-colors hover:underline\"\n >\n Gestisci\n </button>\n )}\n <button\n type=\"button\"\n onClick={onReject}\n className=\"h-9 cursor-pointer rounded-xl border border-white/20 px-3 text-sm text-white/70 transition-colors hover:bg-white/10\"\n >\n Rifiuta\n </button>\n <button\n type=\"button\"\n onClick={onAccept}\n className=\"h-9 cursor-pointer rounded-xl bg-gradient-to-r from-[#8a9eff] to-[#5e77cc] px-3 text-sm font-medium text-white transition-all hover:from-[#7a8eef] hover:to-[#4e67bc]\"\n >\n Accetta tutto\n </button>\n </div>\n </div>\n </div>\n </div>\n );\n}\n"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AA;AAAA,UACT,SAAA,EAAU,qHAAA;AAAA,UACb,QAAA,EAAA;AAAA;AAAA,OAED;AAAA,sBACAA,cAAA;AAAA,QAAC,QAAA;AAAA,QAAA;AAAA,UACG,IAAA,EAAK,QAAA;AAAA,UACL,OAAA,EAAS,QAAA;AAAA,UACT,SAAA,EAAU,uKAAA;AAAA,UACb,QAAA,EAAA;AAAA;AAAA;AAED,KAAA,EACJ;AAAA,GAAA,EACJ,GACJ,CAAA,EACJ,CAAA;AAER","file":"chunk-LLT7263D.cjs","sourcesContent":["import { cn } from '../lib/utils';\n\nexport interface CookieBannerProps {\n visible: boolean;\n cookiePolicyUrl: string;\n onAccept: () => void;\n onReject: () => void;\n onManage?: () => void;\n className?: string;\n}\n\n/**\n * Brand-fixed cookie consent banner. Reads as a sibling system bar to the\n * site/app topbar: translucent `bg-white/5` + `backdrop-blur-md` over the\n * page's own background. Card design is the canonical Appo design-system\n * \"glass card\" — match this treatment in any new card-like surfaces.\n *\n * If you need a different visual for a future product, do not add a variant\n * prop to this component — duplicate it under a different name.\n */\nexport function CookieBanner({\n visible,\n cookiePolicyUrl,\n onAccept,\n onReject,\n onManage,\n className,\n}: CookieBannerProps) {\n if (!visible) return null;\n\n return (\n <div className={cn('fixed bottom-0 left-0 right-0 z-50 sm:py-4 sm:px-4 md:px-6 lg:px-8', className)}>\n <div className=\"sm:max-w-7xl sm:mx-auto\">\n <div className=\"border border-white/10 bg-white/5 backdrop-blur-md flex flex-col gap-4 px-4 py-3 sm:rounded-xl sm:flex-row sm:items-center sm:justify-between\">\n <p className=\"text-sm text-white/60\">\n Utilizziamo i cookie per migliorare la tua esperienza.{' '}\n <a\n href={cookiePolicyUrl}\n className=\"text-white underline underline-offset-2 hover:no-underline\"\n target=\"_blank\"\n rel=\"noreferrer\"\n >\n Cookie policy\n </a>\n </p>\n <div className=\"flex shrink-0 items-center gap-2 self-end sm:self-auto\">\n {onManage && (\n <button\n type=\"button\"\n onClick={onManage}\n className=\"h-9 cursor-pointer rounded-md px-3 text-sm text-white/60 transition-colors hover:underline\"\n >\n Gestisci\n </button>\n )}\n <button\n type=\"button\"\n onClick={onReject}\n className=\"h-9 cursor-pointer rounded-xl border border-white/20 px-3 text-sm text-white/70 transition-colors hover:bg-white/10\"\n >\n Rifiuta\n </button>\n <button\n type=\"button\"\n onClick={onAccept}\n className=\"h-9 cursor-pointer rounded-xl bg-gradient-to-r from-[#8a9eff] to-[#5e77cc] px-3 text-sm font-medium text-white transition-all hover:from-[#7a8eef] hover:to-[#4e67bc]\"\n >\n Accetta tutto\n </button>\n </div>\n </div>\n </div>\n </div>\n );\n}\n"]}