@dododog/ui 0.10.0 → 0.11.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,134 @@
1
+ import { cn } from './chunk-IMKLN273.mjs';
2
+ import * as React from 'react';
3
+ import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
4
+
5
+ function CrownIcon({ className }) {
6
+ return /* @__PURE__ */ jsx(
7
+ "svg",
8
+ {
9
+ xmlns: "http://www.w3.org/2000/svg",
10
+ width: "14",
11
+ height: "14",
12
+ viewBox: "0 0 24 24",
13
+ fill: "currentColor",
14
+ className,
15
+ "aria-hidden": "true",
16
+ children: /* @__PURE__ */ jsx("path", { d: "M5 16 3 6l5.5 4L12 5l3.5 5L21 6l-2 10H5Zm0 2h14v2H5v-2Z" })
17
+ }
18
+ );
19
+ }
20
+ function PawIcon({ className }) {
21
+ return /* @__PURE__ */ jsxs(
22
+ "svg",
23
+ {
24
+ xmlns: "http://www.w3.org/2000/svg",
25
+ width: "24",
26
+ height: "24",
27
+ viewBox: "0 0 24 24",
28
+ fill: "currentColor",
29
+ className,
30
+ "aria-hidden": "true",
31
+ children: [
32
+ /* @__PURE__ */ jsx("circle", { cx: "5.5", cy: "12.5", r: "2" }),
33
+ /* @__PURE__ */ jsx("circle", { cx: "9.5", cy: "7.5", r: "2" }),
34
+ /* @__PURE__ */ jsx("circle", { cx: "14.5", cy: "7.5", r: "2" }),
35
+ /* @__PURE__ */ jsx("circle", { cx: "18.5", cy: "12.5", r: "2" }),
36
+ /* @__PURE__ */ jsx("path", { d: "M12 11c-2.2 0-4 1.9-4 4.2 0 1.6 1.2 2.8 2.8 2.8.6 0 .9-.2 1.2-.2s.6.2 1.2.2c1.6 0 2.8-1.2 2.8-2.8C16 12.9 14.2 11 12 11Z" })
37
+ ]
38
+ }
39
+ );
40
+ }
41
+ var INITIAL_COLORS = [
42
+ "bg-emerald-100 text-emerald-700",
43
+ "bg-amber-100 text-amber-700",
44
+ "bg-sky-100 text-sky-700",
45
+ "bg-violet-100 text-violet-700",
46
+ "bg-rose-100 text-rose-700"
47
+ ];
48
+ function initialColor(name) {
49
+ let hash = 0;
50
+ for (let i = 0; i < name.length; i++) {
51
+ hash = name.charCodeAt(i) + ((hash << 5) - hash);
52
+ }
53
+ return INITIAL_COLORS[Math.abs(hash) % INITIAL_COLORS.length];
54
+ }
55
+ function InfoChip({ children }) {
56
+ return /* @__PURE__ */ jsx("span", { className: "inline-flex items-center rounded-full bg-sand px-2.5 py-0.5 text-xs font-medium text-text-secondary", children });
57
+ }
58
+ var DogCard = React.forwardRef(
59
+ ({ dog, actions, renderImage, renderLink, className, ...props }, ref) => {
60
+ const imageSrc = dog.photoUrl || dog.breedImageUrl || null;
61
+ const initial = dog.name.charAt(0).toUpperCase() || "?";
62
+ const chips = [
63
+ dog.sizeLabel,
64
+ dog.sexLabel,
65
+ dog.ageLabel,
66
+ dog.weightLabel,
67
+ dog.breed
68
+ ].filter((v) => Boolean(v));
69
+ const media = /* @__PURE__ */ jsxs("div", { className: "relative aspect-[4/3] w-full overflow-hidden bg-sand", children: [
70
+ imageSrc ? renderImage ? renderImage({
71
+ src: imageSrc,
72
+ alt: dog.name,
73
+ className: "h-full w-full object-cover"
74
+ }) : /* @__PURE__ */ jsx(
75
+ "img",
76
+ {
77
+ src: imageSrc,
78
+ alt: dog.name,
79
+ className: "h-full w-full object-cover"
80
+ }
81
+ ) : /* @__PURE__ */ jsxs(
82
+ "div",
83
+ {
84
+ className: cn(
85
+ "flex h-full w-full flex-col items-center justify-center gap-1",
86
+ initialColor(dog.name)
87
+ ),
88
+ "aria-label": dog.name,
89
+ children: [
90
+ /* @__PURE__ */ jsx(PawIcon, { className: "h-7 w-7 opacity-50" }),
91
+ /* @__PURE__ */ jsx("span", { className: "text-2xl font-bold", children: initial })
92
+ ]
93
+ }
94
+ ),
95
+ dog.isPrimary && /* @__PURE__ */ jsxs("span", { className: "absolute left-2 top-2 inline-flex items-center gap-1 rounded-full bg-secondary/95 px-2 py-1 text-[11px] font-semibold text-white shadow-sm", children: [
96
+ /* @__PURE__ */ jsx(CrownIcon, { className: "h-3 w-3" }),
97
+ "Principal"
98
+ ] })
99
+ ] });
100
+ const info = /* @__PURE__ */ jsxs("div", { className: "flex flex-1 flex-col p-4", children: [
101
+ /* @__PURE__ */ jsx("h3", { className: "truncate font-heading text-base font-semibold text-primary", children: dog.name }),
102
+ chips.length > 0 && /* @__PURE__ */ jsx("div", { className: "mt-2 flex flex-wrap gap-1.5", children: chips.map((chip, i) => /* @__PURE__ */ jsx(InfoChip, { children: chip }, `${chip}-${i}`)) })
103
+ ] });
104
+ const linkClassName = "group flex flex-1 flex-col rounded-t-xl transition-opacity hover:opacity-95 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-primary focus-visible:ring-offset-2";
105
+ const linkLabel = `Voir le passeport de ${dog.name}`;
106
+ const body = /* @__PURE__ */ jsxs(Fragment, { children: [
107
+ media,
108
+ info
109
+ ] });
110
+ return /* @__PURE__ */ jsxs(
111
+ "div",
112
+ {
113
+ ref,
114
+ className: cn(
115
+ "flex flex-col overflow-hidden rounded-xl border border-sand-dark bg-white transition-shadow hover:shadow-lg",
116
+ className
117
+ ),
118
+ ...props,
119
+ children: [
120
+ dog.href ? renderLink ? renderLink({
121
+ href: dog.href,
122
+ className: linkClassName,
123
+ children: body,
124
+ "aria-label": linkLabel
125
+ }) : /* @__PURE__ */ jsx("a", { href: dog.href, className: linkClassName, "aria-label": linkLabel, children: body }) : /* @__PURE__ */ jsx("div", { className: "flex flex-1 flex-col", children: body }),
126
+ actions && /* @__PURE__ */ jsx("div", { className: "flex items-center justify-end gap-1 border-t border-sand-dark px-3 py-2", children: actions })
127
+ ]
128
+ }
129
+ );
130
+ }
131
+ );
132
+ DogCard.displayName = "DogCard";
133
+
134
+ export { DogCard };
@@ -0,0 +1,156 @@
1
+ 'use strict';
2
+
3
+ var chunkADIDI7AJ_js = require('./chunk-ADIDI7AJ.js');
4
+ var React = require('react');
5
+ var jsxRuntime = require('react/jsx-runtime');
6
+
7
+ function _interopNamespace(e) {
8
+ if (e && e.__esModule) return e;
9
+ var n = Object.create(null);
10
+ if (e) {
11
+ Object.keys(e).forEach(function (k) {
12
+ if (k !== 'default') {
13
+ var d = Object.getOwnPropertyDescriptor(e, k);
14
+ Object.defineProperty(n, k, d.get ? d : {
15
+ enumerable: true,
16
+ get: function () { return e[k]; }
17
+ });
18
+ }
19
+ });
20
+ }
21
+ n.default = e;
22
+ return Object.freeze(n);
23
+ }
24
+
25
+ var React__namespace = /*#__PURE__*/_interopNamespace(React);
26
+
27
+ function CrownIcon({ className }) {
28
+ return /* @__PURE__ */ jsxRuntime.jsx(
29
+ "svg",
30
+ {
31
+ xmlns: "http://www.w3.org/2000/svg",
32
+ width: "14",
33
+ height: "14",
34
+ viewBox: "0 0 24 24",
35
+ fill: "currentColor",
36
+ className,
37
+ "aria-hidden": "true",
38
+ children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M5 16 3 6l5.5 4L12 5l3.5 5L21 6l-2 10H5Zm0 2h14v2H5v-2Z" })
39
+ }
40
+ );
41
+ }
42
+ function PawIcon({ className }) {
43
+ return /* @__PURE__ */ jsxRuntime.jsxs(
44
+ "svg",
45
+ {
46
+ xmlns: "http://www.w3.org/2000/svg",
47
+ width: "24",
48
+ height: "24",
49
+ viewBox: "0 0 24 24",
50
+ fill: "currentColor",
51
+ className,
52
+ "aria-hidden": "true",
53
+ children: [
54
+ /* @__PURE__ */ jsxRuntime.jsx("circle", { cx: "5.5", cy: "12.5", r: "2" }),
55
+ /* @__PURE__ */ jsxRuntime.jsx("circle", { cx: "9.5", cy: "7.5", r: "2" }),
56
+ /* @__PURE__ */ jsxRuntime.jsx("circle", { cx: "14.5", cy: "7.5", r: "2" }),
57
+ /* @__PURE__ */ jsxRuntime.jsx("circle", { cx: "18.5", cy: "12.5", r: "2" }),
58
+ /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M12 11c-2.2 0-4 1.9-4 4.2 0 1.6 1.2 2.8 2.8 2.8.6 0 .9-.2 1.2-.2s.6.2 1.2.2c1.6 0 2.8-1.2 2.8-2.8C16 12.9 14.2 11 12 11Z" })
59
+ ]
60
+ }
61
+ );
62
+ }
63
+ var INITIAL_COLORS = [
64
+ "bg-emerald-100 text-emerald-700",
65
+ "bg-amber-100 text-amber-700",
66
+ "bg-sky-100 text-sky-700",
67
+ "bg-violet-100 text-violet-700",
68
+ "bg-rose-100 text-rose-700"
69
+ ];
70
+ function initialColor(name) {
71
+ let hash = 0;
72
+ for (let i = 0; i < name.length; i++) {
73
+ hash = name.charCodeAt(i) + ((hash << 5) - hash);
74
+ }
75
+ return INITIAL_COLORS[Math.abs(hash) % INITIAL_COLORS.length];
76
+ }
77
+ function InfoChip({ children }) {
78
+ return /* @__PURE__ */ jsxRuntime.jsx("span", { className: "inline-flex items-center rounded-full bg-sand px-2.5 py-0.5 text-xs font-medium text-text-secondary", children });
79
+ }
80
+ var DogCard = React__namespace.forwardRef(
81
+ ({ dog, actions, renderImage, renderLink, className, ...props }, ref) => {
82
+ const imageSrc = dog.photoUrl || dog.breedImageUrl || null;
83
+ const initial = dog.name.charAt(0).toUpperCase() || "?";
84
+ const chips = [
85
+ dog.sizeLabel,
86
+ dog.sexLabel,
87
+ dog.ageLabel,
88
+ dog.weightLabel,
89
+ dog.breed
90
+ ].filter((v) => Boolean(v));
91
+ const media = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative aspect-[4/3] w-full overflow-hidden bg-sand", children: [
92
+ imageSrc ? renderImage ? renderImage({
93
+ src: imageSrc,
94
+ alt: dog.name,
95
+ className: "h-full w-full object-cover"
96
+ }) : /* @__PURE__ */ jsxRuntime.jsx(
97
+ "img",
98
+ {
99
+ src: imageSrc,
100
+ alt: dog.name,
101
+ className: "h-full w-full object-cover"
102
+ }
103
+ ) : /* @__PURE__ */ jsxRuntime.jsxs(
104
+ "div",
105
+ {
106
+ className: chunkADIDI7AJ_js.cn(
107
+ "flex h-full w-full flex-col items-center justify-center gap-1",
108
+ initialColor(dog.name)
109
+ ),
110
+ "aria-label": dog.name,
111
+ children: [
112
+ /* @__PURE__ */ jsxRuntime.jsx(PawIcon, { className: "h-7 w-7 opacity-50" }),
113
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-2xl font-bold", children: initial })
114
+ ]
115
+ }
116
+ ),
117
+ dog.isPrimary && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "absolute left-2 top-2 inline-flex items-center gap-1 rounded-full bg-secondary/95 px-2 py-1 text-[11px] font-semibold text-white shadow-sm", children: [
118
+ /* @__PURE__ */ jsxRuntime.jsx(CrownIcon, { className: "h-3 w-3" }),
119
+ "Principal"
120
+ ] })
121
+ ] });
122
+ const info = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-1 flex-col p-4", children: [
123
+ /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "truncate font-heading text-base font-semibold text-primary", children: dog.name }),
124
+ chips.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mt-2 flex flex-wrap gap-1.5", children: chips.map((chip, i) => /* @__PURE__ */ jsxRuntime.jsx(InfoChip, { children: chip }, `${chip}-${i}`)) })
125
+ ] });
126
+ const linkClassName = "group flex flex-1 flex-col rounded-t-xl transition-opacity hover:opacity-95 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-primary focus-visible:ring-offset-2";
127
+ const linkLabel = `Voir le passeport de ${dog.name}`;
128
+ const body = /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
129
+ media,
130
+ info
131
+ ] });
132
+ return /* @__PURE__ */ jsxRuntime.jsxs(
133
+ "div",
134
+ {
135
+ ref,
136
+ className: chunkADIDI7AJ_js.cn(
137
+ "flex flex-col overflow-hidden rounded-xl border border-sand-dark bg-white transition-shadow hover:shadow-lg",
138
+ className
139
+ ),
140
+ ...props,
141
+ children: [
142
+ dog.href ? renderLink ? renderLink({
143
+ href: dog.href,
144
+ className: linkClassName,
145
+ children: body,
146
+ "aria-label": linkLabel
147
+ }) : /* @__PURE__ */ jsxRuntime.jsx("a", { href: dog.href, className: linkClassName, "aria-label": linkLabel, children: body }) : /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-1 flex-col", children: body }),
148
+ actions && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center justify-end gap-1 border-t border-sand-dark px-3 py-2", children: actions })
149
+ ]
150
+ }
151
+ );
152
+ }
153
+ );
154
+ DogCard.displayName = "DogCard";
155
+
156
+ exports.DogCard = DogCard;
@@ -0,0 +1,156 @@
1
+ 'use strict';
2
+
3
+ var chunkADIDI7AJ_js = require('./chunk-ADIDI7AJ.js');
4
+ var React = require('react');
5
+ var jsxRuntime = require('react/jsx-runtime');
6
+
7
+ function _interopNamespace(e) {
8
+ if (e && e.__esModule) return e;
9
+ var n = Object.create(null);
10
+ if (e) {
11
+ Object.keys(e).forEach(function (k) {
12
+ if (k !== 'default') {
13
+ var d = Object.getOwnPropertyDescriptor(e, k);
14
+ Object.defineProperty(n, k, d.get ? d : {
15
+ enumerable: true,
16
+ get: function () { return e[k]; }
17
+ });
18
+ }
19
+ });
20
+ }
21
+ n.default = e;
22
+ return Object.freeze(n);
23
+ }
24
+
25
+ var React__namespace = /*#__PURE__*/_interopNamespace(React);
26
+
27
+ function MapPinIcon({ className }) {
28
+ return /* @__PURE__ */ jsxRuntime.jsxs("svg", { xmlns: "http://www.w3.org/2000/svg", width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", className, "aria-hidden": "true", children: [
29
+ /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M20 10c0 6-8 12-8 12s-8-6-8-12a8 8 0 0 1 16 0Z" }),
30
+ /* @__PURE__ */ jsxRuntime.jsx("circle", { cx: "12", cy: "10", r: "3" })
31
+ ] });
32
+ }
33
+ function CalendarIcon({ className }) {
34
+ return /* @__PURE__ */ jsxRuntime.jsxs("svg", { xmlns: "http://www.w3.org/2000/svg", width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", className, "aria-hidden": "true", children: [
35
+ /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M8 2v4M16 2v4M3 10h18" }),
36
+ /* @__PURE__ */ jsxRuntime.jsx("rect", { x: "3", y: "4", width: "18", height: "18", rx: "2" })
37
+ ] });
38
+ }
39
+ function DogIcon({ className }) {
40
+ return /* @__PURE__ */ jsxRuntime.jsxs("svg", { xmlns: "http://www.w3.org/2000/svg", width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", className, "aria-hidden": "true", children: [
41
+ /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M10 5.172C10 3.782 8.423 2.679 6.5 3c-2.823.47-4.113 6.006-4 7 .08.703 1.725 1.722 3.656 1 1.261-.472 1.96-1.45 2.344-2.5" }),
42
+ /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M14.267 5.172c0-1.39 1.577-2.493 3.5-2.172 2.823.47 4.113 6.006 4 7-.08.703-1.725 1.722-3.656 1-1.261-.472-1.855-1.45-2.239-2.5" }),
43
+ /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M8 14v.5M16 14v.5M11.25 16.25h1.5L12 17l-.75-.75Z" }),
44
+ /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M4.42 11.247A13.152 13.152 0 0 0 4 14.556C4 18.728 7.582 21 12 21s8-2.272 8-6.444c0-1.061-.162-2.2-.493-3.309m-9.243-6.082A8.801 8.801 0 0 1 12 5c.78 0 1.5.108 2.161.306" })
45
+ ] });
46
+ }
47
+ var STATUS_STYLES = {
48
+ confirmed: "bg-accent/15 text-accent",
49
+ pending: "bg-amber-100 text-amber-700",
50
+ processing: "bg-sky-100 text-sky-700"
51
+ };
52
+ var TripHeroCard = React__namespace.forwardRef(
53
+ ({ trip, actions, renderImage, className, ...props }, ref) => {
54
+ const {
55
+ hotelName,
56
+ hotelImage,
57
+ city,
58
+ address,
59
+ checkinLabel,
60
+ checkoutLabel,
61
+ nights,
62
+ countdownLabel,
63
+ isSoon,
64
+ statusLabel,
65
+ statusTone = "confirmed",
66
+ priceLabel,
67
+ dogName
68
+ } = trip;
69
+ const media = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative aspect-[16/10] w-full overflow-hidden bg-gradient-to-br from-sand-dark to-sand md:aspect-auto md:h-full md:min-h-[15rem]", children: [
70
+ hotelImage ? renderImage ? renderImage({
71
+ src: hotelImage,
72
+ alt: hotelName,
73
+ className: "h-full w-full object-cover"
74
+ }) : /* @__PURE__ */ jsxRuntime.jsx("img", { src: hotelImage, alt: hotelName, className: "h-full w-full object-cover" }) : /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex h-full w-full items-center justify-center text-text-muted", children: /* @__PURE__ */ jsxRuntime.jsx(CalendarIcon, { className: "h-10 w-10" }) }),
75
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "pointer-events-none absolute inset-x-0 bottom-0 h-24 bg-gradient-to-t from-black/55 to-transparent" }),
76
+ /* @__PURE__ */ jsxRuntime.jsxs(
77
+ "span",
78
+ {
79
+ className: chunkADIDI7AJ_js.cn(
80
+ "absolute bottom-3 left-3 inline-flex items-center gap-1.5 rounded-full px-3 py-1.5 text-sm font-semibold shadow-sm backdrop-blur-sm",
81
+ isSoon ? "bg-secondary text-white" : "bg-white/90 text-primary"
82
+ ),
83
+ children: [
84
+ /* @__PURE__ */ jsxRuntime.jsx(CalendarIcon, { className: "h-3.5 w-3.5" }),
85
+ countdownLabel
86
+ ]
87
+ }
88
+ )
89
+ ] });
90
+ return /* @__PURE__ */ jsxRuntime.jsx(
91
+ "section",
92
+ {
93
+ ref,
94
+ "aria-label": "Prochain s\xE9jour",
95
+ className: chunkADIDI7AJ_js.cn(
96
+ "overflow-hidden rounded-2xl border border-sand-dark bg-white shadow-card",
97
+ className
98
+ ),
99
+ ...props,
100
+ children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col md:flex-row", children: [
101
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "md:w-2/5 md:shrink-0", children: media }),
102
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-1 flex-col gap-4 p-5", children: [
103
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
104
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-wrap items-center gap-2", children: [
105
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs font-semibold uppercase tracking-wide text-secondary", children: "Prochain s\xE9jour" }),
106
+ statusLabel && /* @__PURE__ */ jsxRuntime.jsx(
107
+ "span",
108
+ {
109
+ className: chunkADIDI7AJ_js.cn(
110
+ "inline-flex items-center rounded-full px-2 py-0.5 text-xs font-semibold",
111
+ STATUS_STYLES[statusTone]
112
+ ),
113
+ children: statusLabel
114
+ }
115
+ )
116
+ ] }),
117
+ /* @__PURE__ */ jsxRuntime.jsx("h2", { className: "mt-1 font-heading text-2xl font-bold text-primary", children: hotelName }),
118
+ (city || address) && /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "mt-1 inline-flex items-center gap-1.5 text-sm text-text-secondary", children: [
119
+ /* @__PURE__ */ jsxRuntime.jsx(MapPinIcon, { className: "h-4 w-4 shrink-0 text-text-muted" }),
120
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "truncate", children: [city, address].filter(Boolean).join(" \xB7 ") })
121
+ ] })
122
+ ] }),
123
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-wrap items-center gap-x-4 gap-y-2 text-sm", children: [
124
+ /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "inline-flex items-center gap-1.5 text-primary", children: [
125
+ /* @__PURE__ */ jsxRuntime.jsx(CalendarIcon, { className: "h-4 w-4 text-text-muted" }),
126
+ /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "font-medium", children: [
127
+ checkinLabel,
128
+ " \u2192 ",
129
+ checkoutLabel
130
+ ] }),
131
+ /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-text-muted", children: [
132
+ "\xB7 ",
133
+ nights,
134
+ " nuit",
135
+ nights > 1 ? "s" : ""
136
+ ] })
137
+ ] }),
138
+ dogName && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "inline-flex items-center gap-1.5 text-text-secondary", children: [
139
+ /* @__PURE__ */ jsxRuntime.jsx(DogIcon, { className: "h-4 w-4 text-secondary" }),
140
+ dogName
141
+ ] })
142
+ ] }),
143
+ priceLabel && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-baseline gap-1.5", children: [
144
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm text-text-muted", children: "Total" }),
145
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-heading text-xl font-bold text-primary tabular-nums", children: priceLabel })
146
+ ] }),
147
+ actions && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mt-auto flex flex-wrap gap-2 pt-1", children: actions })
148
+ ] })
149
+ ] })
150
+ }
151
+ );
152
+ }
153
+ );
154
+ TripHeroCard.displayName = "TripHeroCard";
155
+
156
+ exports.TripHeroCard = TripHeroCard;
@@ -0,0 +1,79 @@
1
+ 'use strict';
2
+
3
+ var chunkADIDI7AJ_js = require('./chunk-ADIDI7AJ.js');
4
+ var React = require('react');
5
+ var jsxRuntime = require('react/jsx-runtime');
6
+
7
+ function _interopNamespace(e) {
8
+ if (e && e.__esModule) return e;
9
+ var n = Object.create(null);
10
+ if (e) {
11
+ Object.keys(e).forEach(function (k) {
12
+ if (k !== 'default') {
13
+ var d = Object.getOwnPropertyDescriptor(e, k);
14
+ Object.defineProperty(n, k, d.get ? d : {
15
+ enumerable: true,
16
+ get: function () { return e[k]; }
17
+ });
18
+ }
19
+ });
20
+ }
21
+ n.default = e;
22
+ return Object.freeze(n);
23
+ }
24
+
25
+ var React__namespace = /*#__PURE__*/_interopNamespace(React);
26
+
27
+ function ChevronRightIcon({ className }) {
28
+ return /* @__PURE__ */ jsxRuntime.jsx(
29
+ "svg",
30
+ {
31
+ xmlns: "http://www.w3.org/2000/svg",
32
+ width: "16",
33
+ height: "16",
34
+ viewBox: "0 0 24 24",
35
+ fill: "none",
36
+ stroke: "currentColor",
37
+ strokeWidth: "2",
38
+ strokeLinecap: "round",
39
+ strokeLinejoin: "round",
40
+ className,
41
+ "aria-hidden": "true",
42
+ children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "m9 18 6-6-6-6" })
43
+ }
44
+ );
45
+ }
46
+ var StatTile = React__namespace.forwardRef(
47
+ ({ label, value, icon, href, hint, renderLink, className, ...props }, ref) => {
48
+ const body = /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
49
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "flex h-10 w-10 shrink-0 items-center justify-center rounded-xl bg-sand text-secondary", children: icon }),
50
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "min-w-0 flex-1", children: [
51
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-baseline gap-1.5", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-heading text-2xl font-bold leading-none text-primary tabular-nums", children: value }) }),
52
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "mt-1 truncate text-sm font-medium text-text-secondary", children: label }),
53
+ hint && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "truncate text-xs text-text-muted", children: hint })
54
+ ] }),
55
+ href && /* @__PURE__ */ jsxRuntime.jsx(ChevronRightIcon, { className: "h-4 w-4 shrink-0 self-center text-text-muted" })
56
+ ] });
57
+ const baseClassName = chunkADIDI7AJ_js.cn(
58
+ "flex items-center gap-3 rounded-2xl border border-sand-dark bg-white p-4",
59
+ className
60
+ );
61
+ if (href) {
62
+ const linkClassName = chunkADIDI7AJ_js.cn(
63
+ baseClassName,
64
+ "min-h-[44px] transition-shadow hover:shadow-md focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-primary focus-visible:ring-offset-2"
65
+ );
66
+ const ariaLabel = `${label} : ${typeof value === "string" || typeof value === "number" ? value : ""}`.trim();
67
+ return /* @__PURE__ */ jsxRuntime.jsx("div", { ref, ...props, children: renderLink ? renderLink({
68
+ href,
69
+ className: linkClassName,
70
+ "aria-label": ariaLabel,
71
+ children: body
72
+ }) : /* @__PURE__ */ jsxRuntime.jsx("a", { href, className: linkClassName, "aria-label": ariaLabel, children: body }) });
73
+ }
74
+ return /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: baseClassName, ...props, children: body });
75
+ }
76
+ );
77
+ StatTile.displayName = "StatTile";
78
+
79
+ exports.StatTile = StatTile;
@@ -0,0 +1,67 @@
1
+ import { cn } from './chunk-IMKLN273.mjs';
2
+ import * as React from 'react';
3
+ import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
4
+
5
+ function ChevronRightIcon({ className }) {
6
+ return /* @__PURE__ */ jsx(
7
+ "svg",
8
+ {
9
+ xmlns: "http://www.w3.org/2000/svg",
10
+ width: "16",
11
+ height: "16",
12
+ viewBox: "0 0 24 24",
13
+ fill: "none",
14
+ stroke: "currentColor",
15
+ strokeWidth: "2",
16
+ strokeLinecap: "round",
17
+ strokeLinejoin: "round",
18
+ className,
19
+ "aria-hidden": "true",
20
+ children: /* @__PURE__ */ jsx("path", { d: "m9 18 6-6-6-6" })
21
+ }
22
+ );
23
+ }
24
+ var SectionHeader = React.forwardRef(
25
+ ({
26
+ title,
27
+ subtitle,
28
+ icon,
29
+ actionLabel,
30
+ actionHref,
31
+ renderLink,
32
+ as: Heading = "h2",
33
+ className,
34
+ ...props
35
+ }, ref) => {
36
+ const linkClassName = "inline-flex items-center gap-1 rounded text-sm font-medium text-secondary transition-colors hover:text-secondary/80 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-primary focus-visible:ring-offset-2";
37
+ const linkChildren = /* @__PURE__ */ jsxs(Fragment, { children: [
38
+ actionLabel,
39
+ /* @__PURE__ */ jsx(ChevronRightIcon, { className: "h-4 w-4" })
40
+ ] });
41
+ return /* @__PURE__ */ jsxs(
42
+ "div",
43
+ {
44
+ ref,
45
+ className: cn("flex items-end justify-between gap-3", className),
46
+ ...props,
47
+ children: [
48
+ /* @__PURE__ */ jsxs("div", { className: "flex min-w-0 items-start gap-2", children: [
49
+ icon && /* @__PURE__ */ jsx("span", { className: "mt-0.5 shrink-0 text-secondary", children: icon }),
50
+ /* @__PURE__ */ jsxs("div", { className: "min-w-0", children: [
51
+ /* @__PURE__ */ jsx(Heading, { className: "font-heading text-xl font-semibold text-primary", children: title }),
52
+ subtitle && /* @__PURE__ */ jsx("p", { className: "mt-0.5 text-sm text-text-secondary", children: subtitle })
53
+ ] })
54
+ ] }),
55
+ actionLabel && actionHref && (renderLink ? renderLink({
56
+ href: actionHref,
57
+ className: linkClassName,
58
+ children: linkChildren
59
+ }) : /* @__PURE__ */ jsx("a", { href: actionHref, className: linkClassName, children: linkChildren }))
60
+ ]
61
+ }
62
+ );
63
+ }
64
+ );
65
+ SectionHeader.displayName = "SectionHeader";
66
+
67
+ export { SectionHeader };