@dododog/ui 0.1.1 → 0.2.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.
@@ -0,0 +1,220 @@
1
+ import { cn } from './chunk-IMKLN273.mjs';
2
+ import React, { useState, useEffect, useCallback } from 'react';
3
+ import { cva } from 'class-variance-authority';
4
+ import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
5
+
6
+ var promoBannerVariants = cva(
7
+ "w-full px-4 py-2.5 text-sm",
8
+ {
9
+ variants: {
10
+ variant: {
11
+ promo: "bg-secondary text-white",
12
+ alert: "bg-amber-400 text-amber-950",
13
+ maintenance: "bg-red-600 text-white",
14
+ info: "bg-blue-600 text-white"
15
+ }
16
+ },
17
+ defaultVariants: {
18
+ variant: "info"
19
+ }
20
+ }
21
+ );
22
+ function useCountdown(targetDate) {
23
+ const computeTimeLeft = useCallback(() => {
24
+ const diff = new Date(targetDate).getTime() - Date.now();
25
+ if (diff <= 0) return { days: 0, hours: 0, minutes: 0, seconds: 0, isExpired: true };
26
+ return {
27
+ days: Math.floor(diff / 864e5),
28
+ hours: Math.floor(diff % 864e5 / 36e5),
29
+ minutes: Math.floor(diff % 36e5 / 6e4),
30
+ seconds: Math.floor(diff % 6e4 / 1e3),
31
+ isExpired: false
32
+ };
33
+ }, [targetDate]);
34
+ const [timeLeft, setTimeLeft] = useState(computeTimeLeft);
35
+ useEffect(() => {
36
+ const id = setInterval(() => setTimeLeft(computeTimeLeft()), 1e3);
37
+ return () => clearInterval(id);
38
+ }, [computeTimeLeft]);
39
+ return timeLeft;
40
+ }
41
+ function useEmailForm(onSubmit) {
42
+ const [value, setValue] = useState("");
43
+ const [isLoading, setIsLoading] = useState(false);
44
+ const [isSuccess, setIsSuccess] = useState(false);
45
+ const [error, setError] = useState(null);
46
+ const EMAIL_RE = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;
47
+ const handleSubmit = async (e) => {
48
+ e.preventDefault();
49
+ setError(null);
50
+ if (!EMAIL_RE.test(value)) {
51
+ setError("Email invalide");
52
+ return;
53
+ }
54
+ setIsLoading(true);
55
+ try {
56
+ await onSubmit(value);
57
+ setIsSuccess(true);
58
+ } catch (err) {
59
+ setError(err instanceof Error ? err.message : "Erreur");
60
+ } finally {
61
+ setIsLoading(false);
62
+ }
63
+ };
64
+ return { value, setValue, isLoading, isSuccess, error, handleSubmit };
65
+ }
66
+ function useDismiss(storageKey) {
67
+ const [isDismissed, setIsDismissed] = useState(false);
68
+ useEffect(() => {
69
+ if (!storageKey) return;
70
+ try {
71
+ if (localStorage.getItem(storageKey) === "1") setIsDismissed(true);
72
+ } catch {
73
+ }
74
+ }, [storageKey]);
75
+ const dismiss = useCallback(() => {
76
+ setIsDismissed(true);
77
+ if (!storageKey) return;
78
+ try {
79
+ localStorage.setItem(storageKey, "1");
80
+ } catch {
81
+ }
82
+ }, [storageKey]);
83
+ return { isDismissed, dismiss };
84
+ }
85
+ var variantIcons = {
86
+ promo: /* @__PURE__ */ jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 20 20", fill: "currentColor", className: "size-5 shrink-0", children: /* @__PURE__ */ jsx("path", { fillRule: "evenodd", d: "M5 2a2 2 0 0 0-2 2v1a1 1 0 0 0 0 2v1a1 1 0 0 0 0 2v1a1 1 0 0 0 0 2v1a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2v-1a1 1 0 0 0 0-2v-1a1 1 0 0 0 0-2V7a1 1 0 0 0 0-2V4a2 2 0 0 0-2-2H5Z", clipRule: "evenodd" }) }),
87
+ alert: /* @__PURE__ */ jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 20 20", fill: "currentColor", className: "size-5 shrink-0", children: /* @__PURE__ */ jsx("path", { fillRule: "evenodd", d: "M8.485 2.495c.673-1.167 2.357-1.167 3.03 0l6.28 10.875c.673 1.167-.17 2.625-1.516 2.625H3.72c-1.347 0-2.189-1.458-1.515-2.625L8.485 2.495ZM10 6a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 10 6Zm0 9a1 1 0 1 0 0-2 1 1 0 0 0 0 2Z", clipRule: "evenodd" }) }),
88
+ maintenance: /* @__PURE__ */ jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 20 20", fill: "currentColor", className: "size-5 shrink-0", children: /* @__PURE__ */ jsx("path", { fillRule: "evenodd", d: "M8.157 2.176a1.5 1.5 0 0 1 1.858-.062l.106.09 1.769 1.768a15.07 15.07 0 0 1 4.138 4.138l1.768 1.769a1.5 1.5 0 0 1 .028 1.964l-.09.106-1.768 1.769a15.07 15.07 0 0 1-4.138 4.138l-1.769 1.768a1.5 1.5 0 0 1-1.964.028l-.106-.09-1.769-1.768a15.07 15.07 0 0 1-4.138-4.138l-1.768-1.769a1.5 1.5 0 0 1-.028-1.964l.09-.106 1.768-1.769a15.07 15.07 0 0 1 4.138-4.138l1.769-1.768ZM10 9a1 1 0 1 0 0 2 1 1 0 0 0 0-2Z", clipRule: "evenodd" }) }),
89
+ info: /* @__PURE__ */ jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 20 20", fill: "currentColor", className: "size-5 shrink-0", children: /* @__PURE__ */ jsx("path", { fillRule: "evenodd", d: "M18 10a8 8 0 1 1-16 0 8 8 0 0 1 16 0Zm-7-4a1 1 0 1 1-2 0 1 1 0 0 1 2 0ZM9 9a.75.75 0 0 0 0 1.5h.253a.25.25 0 0 1 .244.304l-.459 2.066A1.75 1.75 0 0 0 10.747 15H11a.75.75 0 0 0 0-1.5h-.253a.25.25 0 0 1-.244-.304l.459-2.066A1.75 1.75 0 0 0 9.253 9H9Z", clipRule: "evenodd" }) })
90
+ };
91
+ function CountdownBlock({
92
+ targetDate,
93
+ label,
94
+ expiredLabel
95
+ }) {
96
+ const { days, hours, minutes, seconds, isExpired } = useCountdown(targetDate);
97
+ if (isExpired) {
98
+ return /* @__PURE__ */ jsx("span", { className: "font-medium", children: expiredLabel ?? "Expir\xE9" });
99
+ }
100
+ const pad = (n) => String(n).padStart(2, "0");
101
+ return /* @__PURE__ */ jsxs("span", { className: "inline-flex items-center gap-1.5", children: [
102
+ label && /* @__PURE__ */ jsx("span", { children: label }),
103
+ /* @__PURE__ */ jsxs("span", { className: "font-mono tabular-nums font-semibold", children: [
104
+ days > 0 && /* @__PURE__ */ jsxs(Fragment, { children: [
105
+ days,
106
+ "j\xA0"
107
+ ] }),
108
+ pad(hours),
109
+ ":",
110
+ pad(minutes),
111
+ ":",
112
+ pad(seconds)
113
+ ] })
114
+ ] });
115
+ }
116
+ function EmailFormBlock({
117
+ onSubmit,
118
+ placeholder,
119
+ submitLabel,
120
+ successMessage
121
+ }) {
122
+ const { value, setValue, isLoading, isSuccess, error, handleSubmit } = useEmailForm(onSubmit);
123
+ if (isSuccess) {
124
+ return /* @__PURE__ */ jsxs("span", { className: "flex items-center gap-1.5 font-medium", children: [
125
+ /* @__PURE__ */ jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 20 20", fill: "currentColor", className: "size-4", children: /* @__PURE__ */ jsx("path", { fillRule: "evenodd", d: "M16.704 4.153a.75.75 0 0 1 .143 1.052l-8 10.5a.75.75 0 0 1-1.127.075l-4.5-4.5a.75.75 0 0 1 1.06-1.06l3.894 3.893 7.48-9.817a.75.75 0 0 1 1.05-.143Z", clipRule: "evenodd" }) }),
126
+ successMessage ?? "Inscrit !"
127
+ ] });
128
+ }
129
+ return /* @__PURE__ */ jsxs("form", { onSubmit: handleSubmit, className: "flex items-center gap-2", children: [
130
+ /* @__PURE__ */ jsx(
131
+ "input",
132
+ {
133
+ type: "email",
134
+ value,
135
+ onChange: (e) => setValue(e.target.value),
136
+ placeholder: placeholder ?? "votre@email.com",
137
+ "aria-label": "Email",
138
+ className: cn(
139
+ "rounded px-2.5 py-1 text-sm text-gray-900 placeholder:text-gray-400 outline-none",
140
+ error && "ring-2 ring-red-300"
141
+ )
142
+ }
143
+ ),
144
+ /* @__PURE__ */ jsx(
145
+ "button",
146
+ {
147
+ type: "submit",
148
+ disabled: isLoading,
149
+ className: "rounded bg-white/20 px-3 py-1 text-sm font-medium hover:bg-white/30 transition-colors disabled:opacity-50",
150
+ children: isLoading ? "\u2026" : submitLabel ?? "OK"
151
+ }
152
+ ),
153
+ error && /* @__PURE__ */ jsx("span", { className: "text-xs opacity-80", children: error })
154
+ ] });
155
+ }
156
+ var PromoBanner = React.forwardRef(
157
+ ({
158
+ variant = "info",
159
+ promo,
160
+ alert,
161
+ countdown,
162
+ email,
163
+ storageKey,
164
+ className,
165
+ renderLink,
166
+ ...props
167
+ }, ref) => {
168
+ const { isDismissed, dismiss } = useDismiss(storageKey);
169
+ if (isDismissed) return null;
170
+ const LinkComponent = renderLink ?? DefaultLink;
171
+ return /* @__PURE__ */ jsx(
172
+ "div",
173
+ {
174
+ ref,
175
+ role: "banner",
176
+ className: cn(promoBannerVariants({ variant }), className),
177
+ ...props,
178
+ children: /* @__PURE__ */ jsxs("div", { className: "mx-auto max-w-7xl flex items-center justify-between gap-3 flex-wrap md:flex-nowrap", children: [
179
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3 flex-wrap md:flex-nowrap flex-1", children: [
180
+ variantIcons[variant ?? "info"],
181
+ alert && /* @__PURE__ */ jsx("span", { className: "font-medium", children: alert.message }),
182
+ promo && /* @__PURE__ */ jsxs("span", { className: "inline-flex items-center gap-2", children: [
183
+ /* @__PURE__ */ jsx("span", { children: promo.message }),
184
+ promo.cta && /* @__PURE__ */ jsx(
185
+ LinkComponent,
186
+ {
187
+ href: promo.cta.href,
188
+ className: "underline underline-offset-2 font-semibold hover:opacity-80 transition-opacity",
189
+ children: promo.cta.label
190
+ }
191
+ )
192
+ ] }),
193
+ countdown && /* @__PURE__ */ jsx(CountdownBlock, { ...countdown }),
194
+ email && /* @__PURE__ */ jsx(EmailFormBlock, { ...email })
195
+ ] }),
196
+ storageKey && /* @__PURE__ */ jsx(
197
+ "button",
198
+ {
199
+ type: "button",
200
+ onClick: dismiss,
201
+ "aria-label": "Fermer",
202
+ className: "shrink-0 rounded p-0.5 hover:bg-white/20 transition-colors",
203
+ children: /* @__PURE__ */ jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 20 20", fill: "currentColor", className: "size-4", children: /* @__PURE__ */ jsx("path", { d: "M6.28 5.22a.75.75 0 0 0-1.06 1.06L8.94 10l-3.72 3.72a.75.75 0 1 0 1.06 1.06L10 11.06l3.72 3.72a.75.75 0 1 0 1.06-1.06L11.06 10l3.72-3.72a.75.75 0 0 0-1.06-1.06L10 8.94 6.28 5.22Z" }) })
204
+ }
205
+ )
206
+ ] })
207
+ }
208
+ );
209
+ }
210
+ );
211
+ PromoBanner.displayName = "PromoBanner";
212
+ function DefaultLink({
213
+ href,
214
+ className,
215
+ children
216
+ }) {
217
+ return /* @__PURE__ */ jsx("a", { href, className, children });
218
+ }
219
+
220
+ export { PromoBanner, promoBannerVariants };
@@ -0,0 +1,227 @@
1
+ 'use strict';
2
+
3
+ var chunkADIDI7AJ_js = require('./chunk-ADIDI7AJ.js');
4
+ var React = require('react');
5
+ var classVarianceAuthority = require('class-variance-authority');
6
+ var jsxRuntime = require('react/jsx-runtime');
7
+
8
+ function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
9
+
10
+ var React__default = /*#__PURE__*/_interopDefault(React);
11
+
12
+ var promoBannerVariants = classVarianceAuthority.cva(
13
+ "w-full px-4 py-2.5 text-sm",
14
+ {
15
+ variants: {
16
+ variant: {
17
+ promo: "bg-secondary text-white",
18
+ alert: "bg-amber-400 text-amber-950",
19
+ maintenance: "bg-red-600 text-white",
20
+ info: "bg-blue-600 text-white"
21
+ }
22
+ },
23
+ defaultVariants: {
24
+ variant: "info"
25
+ }
26
+ }
27
+ );
28
+ function useCountdown(targetDate) {
29
+ const computeTimeLeft = React.useCallback(() => {
30
+ const diff = new Date(targetDate).getTime() - Date.now();
31
+ if (diff <= 0) return { days: 0, hours: 0, minutes: 0, seconds: 0, isExpired: true };
32
+ return {
33
+ days: Math.floor(diff / 864e5),
34
+ hours: Math.floor(diff % 864e5 / 36e5),
35
+ minutes: Math.floor(diff % 36e5 / 6e4),
36
+ seconds: Math.floor(diff % 6e4 / 1e3),
37
+ isExpired: false
38
+ };
39
+ }, [targetDate]);
40
+ const [timeLeft, setTimeLeft] = React.useState(computeTimeLeft);
41
+ React.useEffect(() => {
42
+ const id = setInterval(() => setTimeLeft(computeTimeLeft()), 1e3);
43
+ return () => clearInterval(id);
44
+ }, [computeTimeLeft]);
45
+ return timeLeft;
46
+ }
47
+ function useEmailForm(onSubmit) {
48
+ const [value, setValue] = React.useState("");
49
+ const [isLoading, setIsLoading] = React.useState(false);
50
+ const [isSuccess, setIsSuccess] = React.useState(false);
51
+ const [error, setError] = React.useState(null);
52
+ const EMAIL_RE = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;
53
+ const handleSubmit = async (e) => {
54
+ e.preventDefault();
55
+ setError(null);
56
+ if (!EMAIL_RE.test(value)) {
57
+ setError("Email invalide");
58
+ return;
59
+ }
60
+ setIsLoading(true);
61
+ try {
62
+ await onSubmit(value);
63
+ setIsSuccess(true);
64
+ } catch (err) {
65
+ setError(err instanceof Error ? err.message : "Erreur");
66
+ } finally {
67
+ setIsLoading(false);
68
+ }
69
+ };
70
+ return { value, setValue, isLoading, isSuccess, error, handleSubmit };
71
+ }
72
+ function useDismiss(storageKey) {
73
+ const [isDismissed, setIsDismissed] = React.useState(false);
74
+ React.useEffect(() => {
75
+ if (!storageKey) return;
76
+ try {
77
+ if (localStorage.getItem(storageKey) === "1") setIsDismissed(true);
78
+ } catch {
79
+ }
80
+ }, [storageKey]);
81
+ const dismiss = React.useCallback(() => {
82
+ setIsDismissed(true);
83
+ if (!storageKey) return;
84
+ try {
85
+ localStorage.setItem(storageKey, "1");
86
+ } catch {
87
+ }
88
+ }, [storageKey]);
89
+ return { isDismissed, dismiss };
90
+ }
91
+ var variantIcons = {
92
+ promo: /* @__PURE__ */ jsxRuntime.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 20 20", fill: "currentColor", className: "size-5 shrink-0", children: /* @__PURE__ */ jsxRuntime.jsx("path", { fillRule: "evenodd", d: "M5 2a2 2 0 0 0-2 2v1a1 1 0 0 0 0 2v1a1 1 0 0 0 0 2v1a1 1 0 0 0 0 2v1a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2v-1a1 1 0 0 0 0-2v-1a1 1 0 0 0 0-2V7a1 1 0 0 0 0-2V4a2 2 0 0 0-2-2H5Z", clipRule: "evenodd" }) }),
93
+ alert: /* @__PURE__ */ jsxRuntime.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 20 20", fill: "currentColor", className: "size-5 shrink-0", children: /* @__PURE__ */ jsxRuntime.jsx("path", { fillRule: "evenodd", d: "M8.485 2.495c.673-1.167 2.357-1.167 3.03 0l6.28 10.875c.673 1.167-.17 2.625-1.516 2.625H3.72c-1.347 0-2.189-1.458-1.515-2.625L8.485 2.495ZM10 6a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 10 6Zm0 9a1 1 0 1 0 0-2 1 1 0 0 0 0 2Z", clipRule: "evenodd" }) }),
94
+ maintenance: /* @__PURE__ */ jsxRuntime.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 20 20", fill: "currentColor", className: "size-5 shrink-0", children: /* @__PURE__ */ jsxRuntime.jsx("path", { fillRule: "evenodd", d: "M8.157 2.176a1.5 1.5 0 0 1 1.858-.062l.106.09 1.769 1.768a15.07 15.07 0 0 1 4.138 4.138l1.768 1.769a1.5 1.5 0 0 1 .028 1.964l-.09.106-1.768 1.769a15.07 15.07 0 0 1-4.138 4.138l-1.769 1.768a1.5 1.5 0 0 1-1.964.028l-.106-.09-1.769-1.768a15.07 15.07 0 0 1-4.138-4.138l-1.768-1.769a1.5 1.5 0 0 1-.028-1.964l.09-.106 1.768-1.769a15.07 15.07 0 0 1 4.138-4.138l1.769-1.768ZM10 9a1 1 0 1 0 0 2 1 1 0 0 0 0-2Z", clipRule: "evenodd" }) }),
95
+ info: /* @__PURE__ */ jsxRuntime.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 20 20", fill: "currentColor", className: "size-5 shrink-0", children: /* @__PURE__ */ jsxRuntime.jsx("path", { fillRule: "evenodd", d: "M18 10a8 8 0 1 1-16 0 8 8 0 0 1 16 0Zm-7-4a1 1 0 1 1-2 0 1 1 0 0 1 2 0ZM9 9a.75.75 0 0 0 0 1.5h.253a.25.25 0 0 1 .244.304l-.459 2.066A1.75 1.75 0 0 0 10.747 15H11a.75.75 0 0 0 0-1.5h-.253a.25.25 0 0 1-.244-.304l.459-2.066A1.75 1.75 0 0 0 9.253 9H9Z", clipRule: "evenodd" }) })
96
+ };
97
+ function CountdownBlock({
98
+ targetDate,
99
+ label,
100
+ expiredLabel
101
+ }) {
102
+ const { days, hours, minutes, seconds, isExpired } = useCountdown(targetDate);
103
+ if (isExpired) {
104
+ return /* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-medium", children: expiredLabel ?? "Expir\xE9" });
105
+ }
106
+ const pad = (n) => String(n).padStart(2, "0");
107
+ return /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "inline-flex items-center gap-1.5", children: [
108
+ label && /* @__PURE__ */ jsxRuntime.jsx("span", { children: label }),
109
+ /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "font-mono tabular-nums font-semibold", children: [
110
+ days > 0 && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
111
+ days,
112
+ "j\xA0"
113
+ ] }),
114
+ pad(hours),
115
+ ":",
116
+ pad(minutes),
117
+ ":",
118
+ pad(seconds)
119
+ ] })
120
+ ] });
121
+ }
122
+ function EmailFormBlock({
123
+ onSubmit,
124
+ placeholder,
125
+ submitLabel,
126
+ successMessage
127
+ }) {
128
+ const { value, setValue, isLoading, isSuccess, error, handleSubmit } = useEmailForm(onSubmit);
129
+ if (isSuccess) {
130
+ return /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "flex items-center gap-1.5 font-medium", children: [
131
+ /* @__PURE__ */ jsxRuntime.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 20 20", fill: "currentColor", className: "size-4", children: /* @__PURE__ */ jsxRuntime.jsx("path", { fillRule: "evenodd", d: "M16.704 4.153a.75.75 0 0 1 .143 1.052l-8 10.5a.75.75 0 0 1-1.127.075l-4.5-4.5a.75.75 0 0 1 1.06-1.06l3.894 3.893 7.48-9.817a.75.75 0 0 1 1.05-.143Z", clipRule: "evenodd" }) }),
132
+ successMessage ?? "Inscrit !"
133
+ ] });
134
+ }
135
+ return /* @__PURE__ */ jsxRuntime.jsxs("form", { onSubmit: handleSubmit, className: "flex items-center gap-2", children: [
136
+ /* @__PURE__ */ jsxRuntime.jsx(
137
+ "input",
138
+ {
139
+ type: "email",
140
+ value,
141
+ onChange: (e) => setValue(e.target.value),
142
+ placeholder: placeholder ?? "votre@email.com",
143
+ "aria-label": "Email",
144
+ className: chunkADIDI7AJ_js.cn(
145
+ "rounded px-2.5 py-1 text-sm text-gray-900 placeholder:text-gray-400 outline-none",
146
+ error && "ring-2 ring-red-300"
147
+ )
148
+ }
149
+ ),
150
+ /* @__PURE__ */ jsxRuntime.jsx(
151
+ "button",
152
+ {
153
+ type: "submit",
154
+ disabled: isLoading,
155
+ className: "rounded bg-white/20 px-3 py-1 text-sm font-medium hover:bg-white/30 transition-colors disabled:opacity-50",
156
+ children: isLoading ? "\u2026" : submitLabel ?? "OK"
157
+ }
158
+ ),
159
+ error && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-xs opacity-80", children: error })
160
+ ] });
161
+ }
162
+ var PromoBanner = React__default.default.forwardRef(
163
+ ({
164
+ variant = "info",
165
+ promo,
166
+ alert,
167
+ countdown,
168
+ email,
169
+ storageKey,
170
+ className,
171
+ renderLink,
172
+ ...props
173
+ }, ref) => {
174
+ const { isDismissed, dismiss } = useDismiss(storageKey);
175
+ if (isDismissed) return null;
176
+ const LinkComponent = renderLink ?? DefaultLink;
177
+ return /* @__PURE__ */ jsxRuntime.jsx(
178
+ "div",
179
+ {
180
+ ref,
181
+ role: "banner",
182
+ className: chunkADIDI7AJ_js.cn(promoBannerVariants({ variant }), className),
183
+ ...props,
184
+ children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mx-auto max-w-7xl flex items-center justify-between gap-3 flex-wrap md:flex-nowrap", children: [
185
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-3 flex-wrap md:flex-nowrap flex-1", children: [
186
+ variantIcons[variant ?? "info"],
187
+ alert && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-medium", children: alert.message }),
188
+ promo && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "inline-flex items-center gap-2", children: [
189
+ /* @__PURE__ */ jsxRuntime.jsx("span", { children: promo.message }),
190
+ promo.cta && /* @__PURE__ */ jsxRuntime.jsx(
191
+ LinkComponent,
192
+ {
193
+ href: promo.cta.href,
194
+ className: "underline underline-offset-2 font-semibold hover:opacity-80 transition-opacity",
195
+ children: promo.cta.label
196
+ }
197
+ )
198
+ ] }),
199
+ countdown && /* @__PURE__ */ jsxRuntime.jsx(CountdownBlock, { ...countdown }),
200
+ email && /* @__PURE__ */ jsxRuntime.jsx(EmailFormBlock, { ...email })
201
+ ] }),
202
+ storageKey && /* @__PURE__ */ jsxRuntime.jsx(
203
+ "button",
204
+ {
205
+ type: "button",
206
+ onClick: dismiss,
207
+ "aria-label": "Fermer",
208
+ className: "shrink-0 rounded p-0.5 hover:bg-white/20 transition-colors",
209
+ children: /* @__PURE__ */ jsxRuntime.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 20 20", fill: "currentColor", className: "size-4", children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M6.28 5.22a.75.75 0 0 0-1.06 1.06L8.94 10l-3.72 3.72a.75.75 0 1 0 1.06 1.06L10 11.06l3.72 3.72a.75.75 0 1 0 1.06-1.06L11.06 10l3.72-3.72a.75.75 0 0 0-1.06-1.06L10 8.94 6.28 5.22Z" }) })
210
+ }
211
+ )
212
+ ] })
213
+ }
214
+ );
215
+ }
216
+ );
217
+ PromoBanner.displayName = "PromoBanner";
218
+ function DefaultLink({
219
+ href,
220
+ className,
221
+ children
222
+ }) {
223
+ return /* @__PURE__ */ jsxRuntime.jsx("a", { href, className, children });
224
+ }
225
+
226
+ exports.PromoBanner = PromoBanner;
227
+ exports.promoBannerVariants = promoBannerVariants;
@@ -0,0 +1,39 @@
1
+ import * as class_variance_authority_types from 'class-variance-authority/types';
2
+ import React__default from 'react';
3
+ import { VariantProps } from 'class-variance-authority';
4
+
5
+ declare const promoBannerVariants: (props?: ({
6
+ variant?: "alert" | "info" | "promo" | "maintenance" | null | undefined;
7
+ } & class_variance_authority_types.ClassProp) | undefined) => string;
8
+ interface PromoBannerProps extends Omit<React__default.HTMLAttributes<HTMLDivElement>, "children">, VariantProps<typeof promoBannerVariants> {
9
+ promo?: {
10
+ message: string;
11
+ cta?: {
12
+ label: string;
13
+ href: string;
14
+ };
15
+ };
16
+ alert?: {
17
+ message: string;
18
+ };
19
+ countdown?: {
20
+ targetDate: string;
21
+ label?: string;
22
+ expiredLabel?: string;
23
+ };
24
+ email?: {
25
+ placeholder?: string;
26
+ submitLabel?: string;
27
+ onSubmit: (email: string) => Promise<void>;
28
+ successMessage?: string;
29
+ };
30
+ storageKey?: string;
31
+ renderLink?: (props: {
32
+ href: string;
33
+ className?: string;
34
+ children: React__default.ReactNode;
35
+ }) => React__default.ReactNode;
36
+ }
37
+ declare const PromoBanner: React__default.ForwardRefExoticComponent<PromoBannerProps & React__default.RefAttributes<HTMLDivElement>>;
38
+
39
+ export { PromoBanner, type PromoBannerProps, promoBannerVariants };
@@ -0,0 +1,39 @@
1
+ import * as class_variance_authority_types from 'class-variance-authority/types';
2
+ import React__default from 'react';
3
+ import { VariantProps } from 'class-variance-authority';
4
+
5
+ declare const promoBannerVariants: (props?: ({
6
+ variant?: "alert" | "info" | "promo" | "maintenance" | null | undefined;
7
+ } & class_variance_authority_types.ClassProp) | undefined) => string;
8
+ interface PromoBannerProps extends Omit<React__default.HTMLAttributes<HTMLDivElement>, "children">, VariantProps<typeof promoBannerVariants> {
9
+ promo?: {
10
+ message: string;
11
+ cta?: {
12
+ label: string;
13
+ href: string;
14
+ };
15
+ };
16
+ alert?: {
17
+ message: string;
18
+ };
19
+ countdown?: {
20
+ targetDate: string;
21
+ label?: string;
22
+ expiredLabel?: string;
23
+ };
24
+ email?: {
25
+ placeholder?: string;
26
+ submitLabel?: string;
27
+ onSubmit: (email: string) => Promise<void>;
28
+ successMessage?: string;
29
+ };
30
+ storageKey?: string;
31
+ renderLink?: (props: {
32
+ href: string;
33
+ className?: string;
34
+ children: React__default.ReactNode;
35
+ }) => React__default.ReactNode;
36
+ }
37
+ declare const PromoBanner: React__default.ForwardRefExoticComponent<PromoBannerProps & React__default.RefAttributes<HTMLDivElement>>;
38
+
39
+ export { PromoBanner, type PromoBannerProps, promoBannerVariants };
@@ -0,0 +1,15 @@
1
+ 'use strict';
2
+
3
+ var chunkPRDIS2VR_js = require('../../chunk-PRDIS2VR.js');
4
+ require('../../chunk-ADIDI7AJ.js');
5
+
6
+
7
+
8
+ Object.defineProperty(exports, "PromoBanner", {
9
+ enumerable: true,
10
+ get: function () { return chunkPRDIS2VR_js.PromoBanner; }
11
+ });
12
+ Object.defineProperty(exports, "promoBannerVariants", {
13
+ enumerable: true,
14
+ get: function () { return chunkPRDIS2VR_js.promoBannerVariants; }
15
+ });
@@ -0,0 +1,2 @@
1
+ export { PromoBanner, promoBannerVariants } from '../../chunk-FNDR3WOZ.mjs';
2
+ import '../../chunk-IMKLN273.mjs';
package/dist/index.d.mts CHANGED
@@ -42,6 +42,7 @@ export { Toast, ToastProps, toastVariants } from './components/Toast/index.mjs';
42
42
  export { Pagination, PaginationProps } from './components/Pagination/index.mjs';
43
43
  export { Tag, TagProps, tagVariants } from './components/Tag/index.mjs';
44
44
  export { DropdownMenu, DropdownMenuItem, DropdownMenuProps } from './components/DropdownMenu/index.mjs';
45
+ export { PromoBanner, PromoBannerProps, promoBannerVariants } from './components/PromoBanner/index.mjs';
45
46
  export { ProgressBar, ProgressBarProps, progressBarVariants, progressFillVariants } from './components/ProgressBar/index.mjs';
46
47
  export { Carousel, CarouselProps } from './components/Carousel/index.mjs';
47
48
  export { StatusBadge, StatusBadgeProps, statusBadgeVariants } from './components/StatusBadge/index.mjs';
package/dist/index.d.ts CHANGED
@@ -42,6 +42,7 @@ export { Toast, ToastProps, toastVariants } from './components/Toast/index.js';
42
42
  export { Pagination, PaginationProps } from './components/Pagination/index.js';
43
43
  export { Tag, TagProps, tagVariants } from './components/Tag/index.js';
44
44
  export { DropdownMenu, DropdownMenuItem, DropdownMenuProps } from './components/DropdownMenu/index.js';
45
+ export { PromoBanner, PromoBannerProps, promoBannerVariants } from './components/PromoBanner/index.js';
45
46
  export { ProgressBar, ProgressBarProps, progressBarVariants, progressFillVariants } from './components/ProgressBar/index.js';
46
47
  export { Carousel, CarouselProps } from './components/Carousel/index.js';
47
48
  export { StatusBadge, StatusBadgeProps, statusBadgeVariants } from './components/StatusBadge/index.js';
package/dist/index.js CHANGED
@@ -1,5 +1,7 @@
1
1
  'use strict';
2
2
 
3
+ var chunkN3JU7JS7_js = require('./chunk-N3JU7JS7.js');
4
+ var chunk3VU6TPAT_js = require('./chunk-3VU6TPAT.js');
3
5
  var chunkI4S3R6C6_js = require('./chunk-I4S3R6C6.js');
4
6
  var chunk762LQMWP_js = require('./chunk-762LQMWP.js');
5
7
  var chunk7IJOHVNJ_js = require('./chunk-7IJOHVNJ.js');
@@ -7,22 +9,21 @@ var chunkL7OYR6U3_js = require('./chunk-L7OYR6U3.js');
7
9
  var chunkVTELEOT7_js = require('./chunk-VTELEOT7.js');
8
10
  var chunkDTIYZ3TQ_js = require('./chunk-DTIYZ3TQ.js');
9
11
  var chunkE6ZNND75_js = require('./chunk-E6ZNND75.js');
10
- var chunkN3JU7JS7_js = require('./chunk-N3JU7JS7.js');
11
12
  var chunkQWDKSY6Y_js = require('./chunk-QWDKSY6Y.js');
12
13
  var chunk3R7PT3JG_js = require('./chunk-3R7PT3JG.js');
14
+ var chunkTZHT7NZU_js = require('./chunk-TZHT7NZU.js');
13
15
  var chunkDS4LM7OS_js = require('./chunk-DS4LM7OS.js');
14
16
  var chunkNCU5PY34_js = require('./chunk-NCU5PY34.js');
15
17
  var chunkXHRDPJTF_js = require('./chunk-XHRDPJTF.js');
16
18
  var chunkTT7L3ZU7_js = require('./chunk-TT7L3ZU7.js');
17
19
  var chunkDFXXGKMI_js = require('./chunk-DFXXGKMI.js');
18
- var chunk3VU6TPAT_js = require('./chunk-3VU6TPAT.js');
19
20
  var chunkKZSGVMUG_js = require('./chunk-KZSGVMUG.js');
20
21
  var chunkNBDPT3XQ_js = require('./chunk-NBDPT3XQ.js');
21
22
  var chunkSCGN5H6D_js = require('./chunk-SCGN5H6D.js');
22
23
  var chunk6ASRTUXO_js = require('./chunk-6ASRTUXO.js');
23
24
  var chunkPG4I4NWO_js = require('./chunk-PG4I4NWO.js');
25
+ var chunkPRDIS2VR_js = require('./chunk-PRDIS2VR.js');
24
26
  var chunkGXKON34B_js = require('./chunk-GXKON34B.js');
25
- var chunkTZHT7NZU_js = require('./chunk-TZHT7NZU.js');
26
27
  var chunkHS3MAW3G_js = require('./chunk-HS3MAW3G.js');
27
28
  var chunkYN4HPIRC_js = require('./chunk-YN4HPIRC.js');
28
29
  var chunkMKOKWME3_js = require('./chunk-MKOKWME3.js');
@@ -32,7 +33,7 @@ var chunkU3XWNFHH_js = require('./chunk-U3XWNFHH.js');
32
33
  var chunkW7DZZS6L_js = require('./chunk-W7DZZS6L.js');
33
34
  var chunkTE4WHZ4Q_js = require('./chunk-TE4WHZ4Q.js');
34
35
  var chunkHN6B4TAW_js = require('./chunk-HN6B4TAW.js');
35
- var chunkIEHX4DU6_js = require('./chunk-IEHX4DU6.js');
36
+ var chunkTDGU5Y2P_js = require('./chunk-TDGU5Y2P.js');
36
37
  var chunkS5TLUDNM_js = require('./chunk-S5TLUDNM.js');
37
38
  var chunk7W3TFPIF_js = require('./chunk-7W3TFPIF.js');
38
39
  var chunkN2Q4Z2FU_js = require('./chunk-N2Q4Z2FU.js');
@@ -40,22 +41,22 @@ var chunkC4RZBOKH_js = require('./chunk-C4RZBOKH.js');
40
41
  var chunkKOO5ZXLD_js = require('./chunk-KOO5ZXLD.js');
41
42
  var chunkIRKM5UF4_js = require('./chunk-IRKM5UF4.js');
42
43
  var chunkODUY7NXD_js = require('./chunk-ODUY7NXD.js');
43
- var chunkIJIUUBFT_js = require('./chunk-IJIUUBFT.js');
44
44
  var chunk3BPC4LNH_js = require('./chunk-3BPC4LNH.js');
45
45
  var chunkNWLJ7VQF_js = require('./chunk-NWLJ7VQF.js');
46
+ var chunkIJIUUBFT_js = require('./chunk-IJIUUBFT.js');
46
47
  var chunkYSJAEDMG_js = require('./chunk-YSJAEDMG.js');
47
48
  var chunkXXC2YD3D_js = require('./chunk-XXC2YD3D.js');
48
- var chunkVWFY24XF_js = require('./chunk-VWFY24XF.js');
49
49
  var chunkT5FLQQP6_js = require('./chunk-T5FLQQP6.js');
50
- var chunkTDGU5Y2P_js = require('./chunk-TDGU5Y2P.js');
50
+ var chunkVWFY24XF_js = require('./chunk-VWFY24XF.js');
51
+ var chunkIEHX4DU6_js = require('./chunk-IEHX4DU6.js');
51
52
  var chunkZ5S7LHMY_js = require('./chunk-Z5S7LHMY.js');
52
53
  var chunk6EG6EAHW_js = require('./chunk-6EG6EAHW.js');
53
54
  var chunkPND5YKFN_js = require('./chunk-PND5YKFN.js');
54
55
  var chunkH3JNRTAI_js = require('./chunk-H3JNRTAI.js');
55
56
  var chunkYZTVHCLK_js = require('./chunk-YZTVHCLK.js');
56
- var chunkZAUYE2EI_js = require('./chunk-ZAUYE2EI.js');
57
- var chunkMY6BYO5F_js = require('./chunk-MY6BYO5F.js');
58
57
  var chunkP7GAKOCX_js = require('./chunk-P7GAKOCX.js');
58
+ var chunkMY6BYO5F_js = require('./chunk-MY6BYO5F.js');
59
+ var chunkZAUYE2EI_js = require('./chunk-ZAUYE2EI.js');
59
60
  var chunkMCF3EQTV_js = require('./chunk-MCF3EQTV.js');
60
61
  var chunkWBRVUWGC_js = require('./chunk-WBRVUWGC.js');
61
62
  var chunkNHB2TI2B_js = require('./chunk-NHB2TI2B.js');
@@ -64,6 +65,14 @@ var chunkADIDI7AJ_js = require('./chunk-ADIDI7AJ.js');
64
65
 
65
66
 
66
67
 
68
+ Object.defineProperty(exports, "VerticalMarquee", {
69
+ enumerable: true,
70
+ get: function () { return chunkN3JU7JS7_js.VerticalMarquee; }
71
+ });
72
+ Object.defineProperty(exports, "Stepper", {
73
+ enumerable: true,
74
+ get: function () { return chunk3VU6TPAT_js.Stepper; }
75
+ });
67
76
  Object.defineProperty(exports, "Switch", {
68
77
  enumerable: true,
69
78
  get: function () { return chunkI4S3R6C6_js.Switch; }
@@ -112,10 +121,6 @@ Object.defineProperty(exports, "Tooltip", {
112
121
  enumerable: true,
113
122
  get: function () { return chunkE6ZNND75_js.Tooltip; }
114
123
  });
115
- Object.defineProperty(exports, "VerticalMarquee", {
116
- enumerable: true,
117
- get: function () { return chunkN3JU7JS7_js.VerticalMarquee; }
118
- });
119
124
  Object.defineProperty(exports, "SegmentedControl", {
120
125
  enumerable: true,
121
126
  get: function () { return chunkQWDKSY6Y_js.SegmentedControl; }
@@ -128,6 +133,10 @@ Object.defineProperty(exports, "selectVariants", {
128
133
  enumerable: true,
129
134
  get: function () { return chunk3R7PT3JG_js.selectVariants; }
130
135
  });
136
+ Object.defineProperty(exports, "Rating", {
137
+ enumerable: true,
138
+ get: function () { return chunkTZHT7NZU_js.Rating; }
139
+ });
131
140
  Object.defineProperty(exports, "Sidebar", {
132
141
  enumerable: true,
133
142
  get: function () { return chunkDS4LM7OS_js.Sidebar; }
@@ -168,10 +177,6 @@ Object.defineProperty(exports, "statusBadgeVariants", {
168
177
  enumerable: true,
169
178
  get: function () { return chunkDFXXGKMI_js.statusBadgeVariants; }
170
179
  });
171
- Object.defineProperty(exports, "Stepper", {
172
- enumerable: true,
173
- get: function () { return chunk3VU6TPAT_js.Stepper; }
174
- });
175
180
  Object.defineProperty(exports, "MobileMenu", {
176
181
  enumerable: true,
177
182
  get: function () { return chunkKZSGVMUG_js.MobileMenu; }
@@ -200,13 +205,17 @@ Object.defineProperty(exports, "progressFillVariants", {
200
205
  enumerable: true,
201
206
  get: function () { return chunkPG4I4NWO_js.progressFillVariants; }
202
207
  });
203
- Object.defineProperty(exports, "RadioGroup", {
208
+ Object.defineProperty(exports, "PromoBanner", {
204
209
  enumerable: true,
205
- get: function () { return chunkGXKON34B_js.RadioGroup; }
210
+ get: function () { return chunkPRDIS2VR_js.PromoBanner; }
206
211
  });
207
- Object.defineProperty(exports, "Rating", {
212
+ Object.defineProperty(exports, "promoBannerVariants", {
208
213
  enumerable: true,
209
- get: function () { return chunkTZHT7NZU_js.Rating; }
214
+ get: function () { return chunkPRDIS2VR_js.promoBannerVariants; }
215
+ });
216
+ Object.defineProperty(exports, "RadioGroup", {
217
+ enumerable: true,
218
+ get: function () { return chunkGXKON34B_js.RadioGroup; }
210
219
  });
211
220
  Object.defineProperty(exports, "SearchBar", {
212
221
  enumerable: true,
@@ -252,9 +261,9 @@ Object.defineProperty(exports, "MegaMenu", {
252
261
  enumerable: true,
253
262
  get: function () { return chunkHN6B4TAW_js.MegaMenu; }
254
263
  });
255
- Object.defineProperty(exports, "EmptyState", {
264
+ Object.defineProperty(exports, "DualRangeSlider", {
256
265
  enumerable: true,
257
- get: function () { return chunkIEHX4DU6_js.EmptyState; }
266
+ get: function () { return chunkTDGU5Y2P_js.DualRangeSlider; }
258
267
  });
259
268
  Object.defineProperty(exports, "ErrorBoundary", {
260
269
  enumerable: true,
@@ -284,10 +293,6 @@ Object.defineProperty(exports, "HotelCard", {
284
293
  enumerable: true,
285
294
  get: function () { return chunkODUY7NXD_js.HotelCard; }
286
295
  });
287
- Object.defineProperty(exports, "Checkbox", {
288
- enumerable: true,
289
- get: function () { return chunkIJIUUBFT_js.Checkbox; }
290
- });
291
296
  Object.defineProperty(exports, "Counter", {
292
297
  enumerable: true,
293
298
  get: function () { return chunk3BPC4LNH_js.Counter; }
@@ -300,6 +305,10 @@ Object.defineProperty(exports, "DateRangePicker", {
300
305
  enumerable: true,
301
306
  get: function () { return chunkNWLJ7VQF_js.DateRangePicker; }
302
307
  });
308
+ Object.defineProperty(exports, "Checkbox", {
309
+ enumerable: true,
310
+ get: function () { return chunkIJIUUBFT_js.Checkbox; }
311
+ });
303
312
  Object.defineProperty(exports, "DetailList", {
304
313
  enumerable: true,
305
314
  get: function () { return chunkYSJAEDMG_js.DetailList; }
@@ -308,17 +317,17 @@ Object.defineProperty(exports, "Divider", {
308
317
  enumerable: true,
309
318
  get: function () { return chunkXXC2YD3D_js.Divider; }
310
319
  });
311
- Object.defineProperty(exports, "Drawer", {
312
- enumerable: true,
313
- get: function () { return chunkVWFY24XF_js.Drawer; }
314
- });
315
320
  Object.defineProperty(exports, "DropdownMenu", {
316
321
  enumerable: true,
317
322
  get: function () { return chunkT5FLQQP6_js.DropdownMenu; }
318
323
  });
319
- Object.defineProperty(exports, "DualRangeSlider", {
324
+ Object.defineProperty(exports, "Drawer", {
320
325
  enumerable: true,
321
- get: function () { return chunkTDGU5Y2P_js.DualRangeSlider; }
326
+ get: function () { return chunkVWFY24XF_js.Drawer; }
327
+ });
328
+ Object.defineProperty(exports, "EmptyState", {
329
+ enumerable: true,
330
+ get: function () { return chunkIEHX4DU6_js.EmptyState; }
322
331
  });
323
332
  Object.defineProperty(exports, "Badge", {
324
333
  enumerable: true,
@@ -356,6 +365,14 @@ Object.defineProperty(exports, "buttonVariants", {
356
365
  enumerable: true,
357
366
  get: function () { return chunkYZTVHCLK_js.buttonVariants; }
358
367
  });
368
+ Object.defineProperty(exports, "Carousel", {
369
+ enumerable: true,
370
+ get: function () { return chunkP7GAKOCX_js.Carousel; }
371
+ });
372
+ Object.defineProperty(exports, "CardList", {
373
+ enumerable: true,
374
+ get: function () { return chunkMY6BYO5F_js.CardList; }
375
+ });
359
376
  Object.defineProperty(exports, "Card", {
360
377
  enumerable: true,
361
378
  get: function () { return chunkZAUYE2EI_js.Card; }
@@ -384,14 +401,6 @@ Object.defineProperty(exports, "cardVariants", {
384
401
  enumerable: true,
385
402
  get: function () { return chunkZAUYE2EI_js.cardVariants; }
386
403
  });
387
- Object.defineProperty(exports, "CardList", {
388
- enumerable: true,
389
- get: function () { return chunkMY6BYO5F_js.CardList; }
390
- });
391
- Object.defineProperty(exports, "Carousel", {
392
- enumerable: true,
393
- get: function () { return chunkP7GAKOCX_js.Carousel; }
394
- });
395
404
  Object.defineProperty(exports, "Accordion", {
396
405
  enumerable: true,
397
406
  get: function () { return chunkMCF3EQTV_js.Accordion; }
package/dist/index.mjs CHANGED
@@ -1,3 +1,5 @@
1
+ export { VerticalMarquee } from './chunk-JP5ZR2HI.mjs';
2
+ export { Stepper } from './chunk-2ASKBL63.mjs';
1
3
  export { Switch, switchThumbVariants, switchTrackVariants } from './chunk-DMCMWOBJ.mjs';
2
4
  export { Tabs } from './chunk-VOZPGXQD.mjs';
3
5
  export { Tag, tagVariants } from './chunk-WOG6V7OW.mjs';
@@ -5,22 +7,21 @@ export { Textarea, textareaVariants } from './chunk-ZZ4EWC53.mjs';
5
7
  export { Toast, toastVariants } from './chunk-YVTUUNAX.mjs';
6
8
  export { Toggle } from './chunk-2AB5ZHY5.mjs';
7
9
  export { Tooltip } from './chunk-2MJTZ6RR.mjs';
8
- export { VerticalMarquee } from './chunk-JP5ZR2HI.mjs';
9
10
  export { SegmentedControl } from './chunk-36Y7UU32.mjs';
10
11
  export { Select, selectVariants } from './chunk-333YD5QI.mjs';
12
+ export { Rating } from './chunk-SGDC4IVX.mjs';
11
13
  export { Sidebar } from './chunk-MPL35D5G.mjs';
12
14
  export { Skeleton, SkeletonCircle, SkeletonImage, SkeletonText } from './chunk-PAHSQMXV.mjs';
13
15
  export { Spinner, spinnerVariants } from './chunk-NCSFXSOZ.mjs';
14
16
  export { StatCard } from './chunk-O2W7NR33.mjs';
15
17
  export { StatusBadge, statusBadgeVariants } from './chunk-FZ7UNXSC.mjs';
16
- export { Stepper } from './chunk-2ASKBL63.mjs';
17
18
  export { MobileMenu } from './chunk-R4DC7XPP.mjs';
18
19
  export { Modal } from './chunk-74B2EGKT.mjs';
19
20
  export { Pagination } from './chunk-XQVODPHL.mjs';
20
21
  export { PriceDisplay } from './chunk-DGEXT7PN.mjs';
21
22
  export { ProgressBar, progressBarVariants, progressFillVariants } from './chunk-UGYMWWKT.mjs';
23
+ export { PromoBanner, promoBannerVariants } from './chunk-FNDR3WOZ.mjs';
22
24
  export { RadioGroup } from './chunk-F2BUMJYW.mjs';
23
- export { Rating } from './chunk-SGDC4IVX.mjs';
24
25
  export { SearchBar } from './chunk-KQK7LFWM.mjs';
25
26
  export { IconBadge, iconBadgeVariants } from './chunk-I4WCNTNP.mjs';
26
27
  export { ImageGallery } from './chunk-QU6ZRLKO.mjs';
@@ -30,7 +31,7 @@ export { Lightbox } from './chunk-GBWVIY3C.mjs';
30
31
  export { LinkCard } from './chunk-UYDZKAGZ.mjs';
31
32
  export { LoadingOverlay } from './chunk-WVEJS2J2.mjs';
32
33
  export { MegaMenu } from './chunk-EUEM2D5M.mjs';
33
- export { EmptyState } from './chunk-OCUHCDAQ.mjs';
34
+ export { DualRangeSlider } from './chunk-ERL3WXNY.mjs';
34
35
  export { ErrorBoundary } from './chunk-5257MWFI.mjs';
35
36
  export { FilterAccordion } from './chunk-VQVRKRSM.mjs';
36
37
  export { FilterPill } from './chunk-TNWMTKNR.mjs';
@@ -38,22 +39,22 @@ export { Footer } from './chunk-SZ3SV4SJ.mjs';
38
39
  export { GuestPicker } from './chunk-EJ7LDW7E.mjs';
39
40
  export { Header } from './chunk-PPDKQ3FF.mjs';
40
41
  export { HotelCard } from './chunk-PXHZ4CXG.mjs';
41
- export { Checkbox } from './chunk-EEIPCJQ2.mjs';
42
42
  export { Counter } from './chunk-TNGW36OC.mjs';
43
43
  export { DatePickerInput, DateRangePicker } from './chunk-RQGC6RPI.mjs';
44
+ export { Checkbox } from './chunk-EEIPCJQ2.mjs';
44
45
  export { DetailList } from './chunk-76DZXGKJ.mjs';
45
46
  export { Divider } from './chunk-E4B6LXK7.mjs';
46
- export { Drawer } from './chunk-ZLF7IL3Y.mjs';
47
47
  export { DropdownMenu } from './chunk-Q7BKR6O7.mjs';
48
- export { DualRangeSlider } from './chunk-ERL3WXNY.mjs';
48
+ export { Drawer } from './chunk-ZLF7IL3Y.mjs';
49
+ export { EmptyState } from './chunk-OCUHCDAQ.mjs';
49
50
  export { Badge, badgeVariants } from './chunk-XZU2SISM.mjs';
50
51
  export { Banner, bannerVariants } from './chunk-LFIZX2S6.mjs';
51
52
  export { BottomNavBar } from './chunk-UQRQZLMQ.mjs';
52
53
  export { Breadcrumb, breadcrumbVariants } from './chunk-UKCH6RYL.mjs';
53
54
  export { Button, buttonVariants } from './chunk-4U5MNA3B.mjs';
54
- export { Card, CardContent, CardDescription, CardImage, CardTitle, cardImageVariants, cardVariants } from './chunk-V5J2XLPD.mjs';
55
- export { CardList } from './chunk-RJWHPHHX.mjs';
56
55
  export { Carousel } from './chunk-OOPP4ES2.mjs';
56
+ export { CardList } from './chunk-RJWHPHHX.mjs';
57
+ export { Card, CardContent, CardDescription, CardImage, CardTitle, cardImageVariants, cardVariants } from './chunk-V5J2XLPD.mjs';
57
58
  export { Accordion } from './chunk-NZ7GF6RF.mjs';
58
59
  export { Alert } from './chunk-BQWVWK74.mjs';
59
60
  export { Autocomplete, autocompleteInputVariants } from './chunk-B47HQHX3.mjs';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dododog/ui",
3
- "version": "0.1.1",
3
+ "version": "0.2.0",
4
4
  "description": "React UI component library for DodoDog — pet-friendly travel platform",
5
5
  "sideEffects": false,
6
6
  "license": "MIT",
@@ -223,6 +223,11 @@
223
223
  "import": "./dist/components/PriceDisplay/index.mjs",
224
224
  "require": "./dist/components/PriceDisplay/index.js"
225
225
  },
226
+ "./promo-banner": {
227
+ "types": "./dist/components/PromoBanner/index.d.ts",
228
+ "import": "./dist/components/PromoBanner/index.mjs",
229
+ "require": "./dist/components/PromoBanner/index.js"
230
+ },
226
231
  "./progress-bar": {
227
232
  "types": "./dist/components/ProgressBar/index.d.ts",
228
233
  "import": "./dist/components/ProgressBar/index.mjs",