@alfadocs/ui-kit 0.33.5 → 0.33.6
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.
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsxs as u, jsx as e, Fragment as R } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef as
|
|
3
|
-
import { c as
|
|
4
|
-
import { useTranslation as
|
|
2
|
+
import { forwardRef as ce, useId as se, useMemo as de } from "react";
|
|
3
|
+
import { c as pe } from "./index-D2ZczOXr.js";
|
|
4
|
+
import { useTranslation as ue } from "react-i18next";
|
|
5
5
|
import { B as S } from "./badge-zsf5i5bH.js";
|
|
6
6
|
import { C as F } from "./card-DPmk26CL.js";
|
|
7
|
-
import { K as
|
|
7
|
+
import { K as fe, a as me } from "./key-value-pair-CkQIb9EG.js";
|
|
8
8
|
import { L as d } from "./link-DrD_cRUg.js";
|
|
9
|
-
import { u as
|
|
9
|
+
import { u as he } from "./registry-nPAVE19X.js";
|
|
10
10
|
import { S as T } from "./stethoscope-DT5qCW8Y.js";
|
|
11
11
|
import { H, S as V, L as z } from "./shield-check-BhHyReu8.js";
|
|
12
12
|
import { c as O } from "./createLucideIcon-CrFbzy84.js";
|
|
@@ -20,18 +20,18 @@ import { M as U } from "./map-pin-B8STOPMJ.js";
|
|
|
20
20
|
* This source code is licensed under the ISC license.
|
|
21
21
|
* See the LICENSE file in the root directory of this source tree.
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const ge = [
|
|
24
24
|
["rect", { width: "20", height: "12", x: "2", y: "6", rx: "2", key: "9lu3g6" }],
|
|
25
25
|
["circle", { cx: "12", cy: "12", r: "2", key: "1c9p78" }],
|
|
26
26
|
["path", { d: "M6 12h.01M18 12h.01", key: "113zkx" }]
|
|
27
|
-
], j = O("banknote",
|
|
27
|
+
], j = O("banknote", ge);
|
|
28
28
|
/**
|
|
29
29
|
* @license lucide-react v1.8.0 - ISC
|
|
30
30
|
*
|
|
31
31
|
* This source code is licensed under the ISC license.
|
|
32
32
|
* See the LICENSE file in the root directory of this source tree.
|
|
33
33
|
*/
|
|
34
|
-
const
|
|
34
|
+
const ve = [
|
|
35
35
|
[
|
|
36
36
|
"path",
|
|
37
37
|
{
|
|
@@ -39,7 +39,7 @@ const ge = [
|
|
|
39
39
|
key: "9njp5v"
|
|
40
40
|
}
|
|
41
41
|
]
|
|
42
|
-
], B = O("phone",
|
|
42
|
+
], B = O("phone", ve), xe = {
|
|
43
43
|
id: "contact-profile-card",
|
|
44
44
|
capabilities: ["view_change"],
|
|
45
45
|
state: {
|
|
@@ -63,7 +63,7 @@ const ge = [
|
|
|
63
63
|
description: "Sourced from the id prop."
|
|
64
64
|
}
|
|
65
65
|
}
|
|
66
|
-
},
|
|
66
|
+
}, ye = pe(
|
|
67
67
|
"ds:w-full ds:text-[color:var(--foreground)] ds:[--key-value-pair-icon-color:var(--accent)]",
|
|
68
68
|
{
|
|
69
69
|
variants: {
|
|
@@ -79,17 +79,17 @@ const ge = [
|
|
|
79
79
|
defaultVariants: { surface: "elevated" }
|
|
80
80
|
}
|
|
81
81
|
);
|
|
82
|
-
function
|
|
82
|
+
function Ce(t) {
|
|
83
83
|
return t.replace(/[^\d+]/g, "");
|
|
84
84
|
}
|
|
85
|
-
function
|
|
85
|
+
function be(t, r) {
|
|
86
86
|
const a = `https://wa.me/${t}`;
|
|
87
87
|
return r ? `${a}?text=${encodeURIComponent(r)}` : a;
|
|
88
88
|
}
|
|
89
|
-
function
|
|
89
|
+
function Pe(t) {
|
|
90
90
|
return `https://www.google.com/maps/search/?api=1&query=${encodeURIComponent(t.line)}`;
|
|
91
91
|
}
|
|
92
|
-
function
|
|
92
|
+
function ke(t, r, a) {
|
|
93
93
|
try {
|
|
94
94
|
return new Intl.NumberFormat(a, {
|
|
95
95
|
style: "currency",
|
|
@@ -99,13 +99,13 @@ function Pe(t, r, a) {
|
|
|
99
99
|
return (t / 100).toFixed(2);
|
|
100
100
|
}
|
|
101
101
|
}
|
|
102
|
-
function
|
|
102
|
+
function we() {
|
|
103
103
|
if (typeof document > "u") return "4945a3";
|
|
104
104
|
const t = getComputedStyle(document.documentElement).getPropertyValue("--map-marker-color").trim(), r = /^#?([0-9a-fA-F]{6})$/.exec(t);
|
|
105
105
|
return r ? r[1] : "4945a3";
|
|
106
106
|
}
|
|
107
|
-
function
|
|
108
|
-
const s =
|
|
107
|
+
function Me({ apiKey: t, center: r, zoom: a, altText: c }) {
|
|
108
|
+
const s = we(), f = `https://maps.googleapis.com/maps/api/staticmap?center=${r.lat},${r.lng}&zoom=${a}&size=640x192&scale=2&markers=color:0x${s}%7C${r.lat},${r.lng}&key=${encodeURIComponent(t)}`;
|
|
109
109
|
return /* @__PURE__ */ e(
|
|
110
110
|
"img",
|
|
111
111
|
{
|
|
@@ -119,7 +119,7 @@ function we({ apiKey: t, center: r, zoom: a, altText: c }) {
|
|
|
119
119
|
}
|
|
120
120
|
);
|
|
121
121
|
}
|
|
122
|
-
const
|
|
122
|
+
const $e = ce(
|
|
123
123
|
({
|
|
124
124
|
heading: t,
|
|
125
125
|
description: r,
|
|
@@ -151,10 +151,10 @@ const Me = le(
|
|
|
151
151
|
className: ae,
|
|
152
152
|
...te
|
|
153
153
|
}, re) => {
|
|
154
|
-
const { t: n, i18n: w } =
|
|
154
|
+
const { t: n, i18n: w } = ue(), M = se(), $ = w.language ?? "en", A = t ?? n("contactProfileCard.heading"), ne = ee ?? A, N = de(() => {
|
|
155
155
|
if (x != null)
|
|
156
|
-
return
|
|
157
|
-
}, [x, b,
|
|
156
|
+
return ke(x, b, $);
|
|
157
|
+
}, [x, b, $]), o = [];
|
|
158
158
|
if (a && o.push({
|
|
159
159
|
key: "address",
|
|
160
160
|
icon: /* @__PURE__ */ e(U, { "aria-hidden": "true" }),
|
|
@@ -164,7 +164,7 @@ const Me = le(
|
|
|
164
164
|
a.lat != null && a.lng != null ? /* @__PURE__ */ e(
|
|
165
165
|
d,
|
|
166
166
|
{
|
|
167
|
-
href:
|
|
167
|
+
href: Pe(a),
|
|
168
168
|
external: !0,
|
|
169
169
|
intent: "default",
|
|
170
170
|
onClick: Y,
|
|
@@ -179,7 +179,7 @@ const Me = le(
|
|
|
179
179
|
value: /* @__PURE__ */ e(
|
|
180
180
|
d,
|
|
181
181
|
{
|
|
182
|
-
href: `tel:${
|
|
182
|
+
href: `tel:${Ce(c)}`,
|
|
183
183
|
intent: "default",
|
|
184
184
|
onClick: W,
|
|
185
185
|
children: c
|
|
@@ -192,7 +192,7 @@ const Me = le(
|
|
|
192
192
|
value: /* @__PURE__ */ e(
|
|
193
193
|
d,
|
|
194
194
|
{
|
|
195
|
-
href:
|
|
195
|
+
href: be(s, f),
|
|
196
196
|
external: !0,
|
|
197
197
|
intent: "default",
|
|
198
198
|
onClick: D,
|
|
@@ -250,25 +250,13 @@ const Me = le(
|
|
|
250
250
|
icon: /* @__PURE__ */ e(T, { "aria-hidden": "true" }),
|
|
251
251
|
label: n("contactProfileCard.label.profession"),
|
|
252
252
|
value: y
|
|
253
|
-
}),
|
|
254
|
-
|
|
253
|
+
}), he(
|
|
254
|
+
xe,
|
|
255
255
|
{ getProfession: () => y },
|
|
256
256
|
C
|
|
257
257
|
);
|
|
258
|
-
const oe = /* @__PURE__ */
|
|
259
|
-
|
|
260
|
-
o.length > 0 ? /* @__PURE__ */ e(ue, { rowGap: "md", children: o.map((i) => /* @__PURE__ */ e(
|
|
261
|
-
fe,
|
|
262
|
-
{
|
|
263
|
-
icon: i.icon,
|
|
264
|
-
label: i.label,
|
|
265
|
-
value: i.value
|
|
266
|
-
},
|
|
267
|
-
i.key
|
|
268
|
-
)) }) : null,
|
|
269
|
-
X
|
|
270
|
-
] }), ie = !!P && (a == null ? void 0 : a.lat) !== void 0 && (a == null ? void 0 : a.lng) !== void 0 ? /* @__PURE__ */ e(
|
|
271
|
-
we,
|
|
258
|
+
const oe = !!P && (a == null ? void 0 : a.lat) !== void 0 && (a == null ? void 0 : a.lng) !== void 0 ? /* @__PURE__ */ e(
|
|
259
|
+
Me,
|
|
272
260
|
{
|
|
273
261
|
apiKey: P,
|
|
274
262
|
center: { lat: a.lat, lng: a.lng },
|
|
@@ -278,8 +266,20 @@ const Me = le(
|
|
|
278
266
|
defaultValue: "Map showing {{address}}"
|
|
279
267
|
})
|
|
280
268
|
}
|
|
281
|
-
) : null,
|
|
282
|
-
|
|
269
|
+
) : null, ie = Z ?? oe, le = /* @__PURE__ */ u(R, { children: [
|
|
270
|
+
r ? /* @__PURE__ */ e("p", { className: "type-body-sm ds:m-0 ds:whitespace-pre-line", children: r }) : null,
|
|
271
|
+
o.length > 0 ? /* @__PURE__ */ e(fe, { rowGap: "md", children: o.map((i) => /* @__PURE__ */ e(
|
|
272
|
+
me,
|
|
273
|
+
{
|
|
274
|
+
icon: i.icon,
|
|
275
|
+
label: i.label,
|
|
276
|
+
value: i.value
|
|
277
|
+
},
|
|
278
|
+
i.key
|
|
279
|
+
)) }) : null,
|
|
280
|
+
ie,
|
|
281
|
+
X
|
|
282
|
+
] }), _ = /* @__PURE__ */ u(R, { children: [
|
|
283
283
|
/* @__PURE__ */ u("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]", children: [
|
|
284
284
|
Q,
|
|
285
285
|
/* @__PURE__ */ e(
|
|
@@ -287,11 +287,11 @@ const Me = le(
|
|
|
287
287
|
{
|
|
288
288
|
id: M,
|
|
289
289
|
className: "type-title-card ds:m-0 ds:text-[color:var(--foreground)]",
|
|
290
|
-
children:
|
|
290
|
+
children: A
|
|
291
291
|
}
|
|
292
292
|
)
|
|
293
293
|
] }),
|
|
294
|
-
|
|
294
|
+
le
|
|
295
295
|
] });
|
|
296
296
|
return /* @__PURE__ */ e(
|
|
297
297
|
"div",
|
|
@@ -303,14 +303,14 @@ const Me = le(
|
|
|
303
303
|
"data-component": "contact-profile-card",
|
|
304
304
|
"data-component-id": C,
|
|
305
305
|
id: C,
|
|
306
|
-
className:
|
|
306
|
+
className: ye({ surface: k, className: ae }),
|
|
307
307
|
...te,
|
|
308
308
|
children: k === "elevated" ? /* @__PURE__ */ e(F, { variant: "elevated", children: /* @__PURE__ */ e(F.Body, { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: _ }) }) : /* @__PURE__ */ e("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", children: _ })
|
|
309
309
|
}
|
|
310
310
|
);
|
|
311
311
|
}
|
|
312
312
|
);
|
|
313
|
-
|
|
313
|
+
$e.displayName = "ContactProfileCard";
|
|
314
314
|
const Be = [
|
|
315
315
|
"address",
|
|
316
316
|
"phone",
|
|
@@ -337,7 +337,7 @@ const Be = [
|
|
|
337
337
|
export {
|
|
338
338
|
Ge as C,
|
|
339
339
|
Be as a,
|
|
340
|
-
|
|
341
|
-
|
|
340
|
+
$e as b,
|
|
341
|
+
xe as c
|
|
342
342
|
};
|
|
343
|
-
//# sourceMappingURL=contact-profile-card-
|
|
343
|
+
//# sourceMappingURL=contact-profile-card-BA6fgS45.js.map
|
package/dist/agent-catalog.json
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { C as _, a as O, b as o, c as r } from "../../_chunks/contact-profile-card-
|
|
1
|
+
import { C as _, a as O, b as o, c as r } from "../../_chunks/contact-profile-card-BA6fgS45.js";
|
|
2
2
|
export {
|
|
3
3
|
_ as CONTACT_PROFILE_CARD_ROW_ICONS,
|
|
4
4
|
O as CONTACT_PROFILE_CARD_ROW_KEYS,
|
package/dist/index.js
CHANGED
|
@@ -130,7 +130,7 @@ import { B as kn, C as On, O as _n, b as yn } from "./_chunks/booking-h_kBZM6M.j
|
|
|
130
130
|
import { C as Mn, c as Dn, r as wn } from "./_chunks/calendar-YHFknAGv.js";
|
|
131
131
|
import { O as vn, o as Hn } from "./_chunks/operator-hero-7LiiP7zi.js";
|
|
132
132
|
import { P as Gn, p as Un } from "./_chunks/patient-search-CBq62kmL.js";
|
|
133
|
-
import { C as Yn, a as jn, b as zn, c as qn } from "./_chunks/contact-profile-card-
|
|
133
|
+
import { C as Yn, a as jn, b as zn, c as qn } from "./_chunks/contact-profile-card-BA6fgS45.js";
|
|
134
134
|
import { P as Jn, p as Xn } from "./_chunks/practice-results-Bv2RhAmD.js";
|
|
135
135
|
import { P as $n, f as ap, p as ep, a as rp, s as op, b as tp, c as sp } from "./_chunks/payment-form-D5rgnZu7.js";
|
|
136
136
|
import { P as np, p as pp } from "./_chunks/pdf-viewer-DvtEHcEP.js";
|
package/package.json
CHANGED