@brightlocal/ui-components 2.27.0 → 3.1.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.
Files changed (289) hide show
  1. package/README.md +7 -1
  2. package/component-meta.json +568 -143
  3. package/deprecations.json +298 -1
  4. package/dist/accordion.cjs +1 -1
  5. package/dist/accordion.d.ts +36 -0
  6. package/dist/accordion.d.ts.map +1 -1
  7. package/dist/accordion.js +74 -61
  8. package/dist/alert-dialog.cjs +1 -1
  9. package/dist/alert-dialog.js +18 -18
  10. package/dist/alert.cjs +1 -1
  11. package/dist/alert.d.ts +11 -1
  12. package/dist/alert.d.ts.map +1 -1
  13. package/dist/alert.js +31 -28
  14. package/dist/avatar.cjs +1 -1
  15. package/dist/avatar.js +4 -4
  16. package/dist/badge.cjs +1 -1
  17. package/dist/badge.d.ts.map +1 -1
  18. package/dist/badge.js +15 -11
  19. package/dist/blocks/empty-state.cjs +1 -0
  20. package/dist/blocks/empty-state.d.ts +172 -0
  21. package/dist/blocks/empty-state.d.ts.map +1 -0
  22. package/dist/blocks/empty-state.js +147 -0
  23. package/dist/blocks/input-list.cjs +2 -2
  24. package/dist/blocks/input-list.d.ts.map +1 -1
  25. package/dist/blocks/input-list.js +124 -108
  26. package/dist/blocks/progress-state.cjs +1 -0
  27. package/dist/blocks/{progress-screen.d.ts → progress-state.d.ts} +30 -18
  28. package/dist/blocks/progress-state.d.ts.map +1 -0
  29. package/dist/blocks/{progress-screen.js → progress-state.js} +100 -71
  30. package/dist/blocks/sidebar.cjs +1 -1
  31. package/dist/blocks/sidebar.d.ts.map +1 -1
  32. package/dist/blocks/sidebar.js +160 -161
  33. package/dist/breadcrumb.cjs +1 -1
  34. package/dist/breadcrumb.js +1 -1
  35. package/dist/button-group.cjs +1 -0
  36. package/dist/button-group.d.ts +36 -0
  37. package/dist/button-group.d.ts.map +1 -0
  38. package/dist/button-group.js +47 -0
  39. package/dist/button.cjs +1 -1
  40. package/dist/button.js +12 -12
  41. package/dist/calendar.cjs +1 -1
  42. package/dist/calendar.d.ts.map +1 -1
  43. package/dist/calendar.js +37 -38
  44. package/dist/callout.cjs +1 -1
  45. package/dist/callout.d.ts +24 -2
  46. package/dist/callout.d.ts.map +1 -1
  47. package/dist/callout.js +57 -55
  48. package/dist/card.cjs +1 -1
  49. package/dist/card.d.ts +42 -3
  50. package/dist/card.d.ts.map +1 -1
  51. package/dist/card.js +102 -91
  52. package/dist/chart-empty.cjs +1 -0
  53. package/dist/chart-empty.d.ts +59 -0
  54. package/dist/chart-empty.d.ts.map +1 -0
  55. package/dist/chart-empty.js +29 -0
  56. package/dist/chart.cjs +6 -6
  57. package/dist/chart.d.ts +46 -13
  58. package/dist/chart.d.ts.map +1 -1
  59. package/dist/chart.js +172 -157
  60. package/dist/chip.cjs +1 -1
  61. package/dist/chip.d.ts +38 -4
  62. package/dist/chip.d.ts.map +1 -1
  63. package/dist/chip.js +100 -84
  64. package/dist/combobox.cjs +2 -2
  65. package/dist/combobox.d.ts.map +1 -1
  66. package/dist/combobox.js +81 -79
  67. package/dist/command.cjs +1 -1
  68. package/dist/command.d.ts +23 -1
  69. package/dist/command.d.ts.map +1 -1
  70. package/dist/command.js +248 -225
  71. package/dist/context-menu.cjs +1 -1
  72. package/dist/context-menu.d.ts.map +1 -1
  73. package/dist/context-menu.js +26 -29
  74. package/dist/data-table.cjs +1 -1
  75. package/dist/data-table.d.ts +75 -10
  76. package/dist/data-table.d.ts.map +1 -1
  77. package/dist/data-table.js +346 -334
  78. package/dist/date-picker.cjs +1 -1
  79. package/dist/date-picker.d.ts +13 -5
  80. package/dist/date-picker.d.ts.map +1 -1
  81. package/dist/date-picker.js +54 -53
  82. package/dist/description.cjs +1 -1
  83. package/dist/description.js +5 -5
  84. package/dist/dialog.cjs +1 -1
  85. package/dist/dialog.js +20 -20
  86. package/dist/drawer.cjs +1 -1
  87. package/dist/drawer.d.ts.map +1 -1
  88. package/dist/drawer.js +8 -11
  89. package/dist/dropdown-menu.cjs +1 -1
  90. package/dist/dropdown-menu.d.ts.map +1 -1
  91. package/dist/dropdown-menu.js +17 -20
  92. package/dist/field.cjs +1 -1
  93. package/dist/field.d.ts +8 -1
  94. package/dist/field.d.ts.map +1 -1
  95. package/dist/field.js +96 -65
  96. package/dist/global-layout.cjs +1 -1
  97. package/dist/global-layout.d.ts +130 -12
  98. package/dist/global-layout.d.ts.map +1 -1
  99. package/dist/global-layout.js +146 -127
  100. package/dist/grid.cjs +1 -0
  101. package/dist/grid.d.ts +56 -0
  102. package/dist/grid.d.ts.map +1 -0
  103. package/dist/grid.js +32 -0
  104. package/dist/header.d.ts +13 -0
  105. package/dist/header.d.ts.map +1 -1
  106. package/dist/hooks/use-delayed-pending.cjs +1 -0
  107. package/dist/hooks/use-delayed-pending.d.ts +34 -0
  108. package/dist/hooks/use-delayed-pending.d.ts.map +1 -0
  109. package/dist/hooks/use-delayed-pending.js +17 -0
  110. package/dist/hooks/use-mobile.cjs +1 -0
  111. package/dist/hooks/use-mobile.js +8 -0
  112. package/dist/hover-card.cjs +1 -1
  113. package/dist/hover-card.js +13 -13
  114. package/dist/index.cjs +1 -1
  115. package/dist/index.d.ts +9 -1
  116. package/dist/index.d.ts.map +1 -1
  117. package/dist/index.js +554 -527
  118. package/dist/input-chip.cjs +1 -1
  119. package/dist/input-chip.js +25 -25
  120. package/dist/input-group.cjs +1 -1
  121. package/dist/input-group.js +9 -9
  122. package/dist/input-otp.cjs +1 -1
  123. package/dist/input-otp.js +9 -9
  124. package/dist/input-password.cjs +1 -1
  125. package/dist/input-password.d.ts +17 -9
  126. package/dist/input-password.d.ts.map +1 -1
  127. package/dist/input-password.js +73 -72
  128. package/dist/input.cjs +1 -1
  129. package/dist/input.js +9 -9
  130. package/dist/label.cjs +1 -1
  131. package/dist/label.d.ts.map +1 -1
  132. package/dist/label.js +25 -28
  133. package/dist/lib/block-illustration.cjs +1 -0
  134. package/dist/lib/block-illustration.d.ts +28 -0
  135. package/dist/lib/block-illustration.d.ts.map +1 -0
  136. package/dist/lib/block-illustration.js +21 -0
  137. package/dist/lib/empty-canvas.cjs +1 -0
  138. package/dist/lib/empty-canvas.d.ts +27 -0
  139. package/dist/lib/empty-canvas.d.ts.map +1 -0
  140. package/dist/lib/empty-canvas.js +62 -0
  141. package/dist/lib/empty-chip.cjs +1 -0
  142. package/dist/lib/empty-chip.d.ts +4 -0
  143. package/dist/lib/empty-chip.d.ts.map +1 -0
  144. package/dist/lib/empty-chip.js +13 -0
  145. package/dist/lib/optical-center.cjs +1 -0
  146. package/dist/lib/optical-center.d.ts +12 -0
  147. package/dist/lib/optical-center.d.ts.map +1 -0
  148. package/dist/lib/optical-center.js +11 -0
  149. package/dist/lib/utils.cjs +1 -1
  150. package/dist/lib/utils.d.ts.map +1 -1
  151. package/dist/lib/utils.js +28 -5
  152. package/dist/list.cjs +1 -1
  153. package/dist/list.d.ts.map +1 -1
  154. package/dist/list.js +62 -58
  155. package/dist/map.cjs +1 -1
  156. package/dist/map.d.ts +60 -2
  157. package/dist/map.d.ts.map +1 -1
  158. package/dist/map.js +187 -164
  159. package/dist/media-empty.cjs +1 -0
  160. package/dist/media-empty.d.ts +72 -0
  161. package/dist/media-empty.d.ts.map +1 -0
  162. package/dist/media-empty.js +45 -0
  163. package/dist/menubar.cjs +1 -1
  164. package/dist/menubar.d.ts.map +1 -1
  165. package/dist/menubar.js +17 -20
  166. package/dist/navigation-menu.cjs +1 -1
  167. package/dist/navigation-menu.js +7 -7
  168. package/dist/pagination.cjs +1 -1
  169. package/dist/pagination.d.ts +130 -1
  170. package/dist/pagination.d.ts.map +1 -1
  171. package/dist/pagination.js +193 -102
  172. package/dist/progress.cjs +1 -1
  173. package/dist/progress.d.ts +2 -26
  174. package/dist/progress.d.ts.map +1 -1
  175. package/dist/progress.js +79 -118
  176. package/dist/scroll-area.cjs +1 -1
  177. package/dist/scroll-area.d.ts +15 -6
  178. package/dist/scroll-area.d.ts.map +1 -1
  179. package/dist/scroll-area.js +38 -36
  180. package/dist/select.cjs +2 -2
  181. package/dist/select.d.ts +13 -2
  182. package/dist/select.d.ts.map +1 -1
  183. package/dist/select.js +92 -87
  184. package/dist/separator.cjs +1 -1
  185. package/dist/separator.js +8 -8
  186. package/dist/sheet.cjs +1 -1
  187. package/dist/sheet.js +2 -2
  188. package/dist/skeleton.cjs +1 -1
  189. package/dist/skeleton.d.ts +38 -3
  190. package/dist/skeleton.d.ts.map +1 -1
  191. package/dist/skeleton.js +43 -20
  192. package/dist/sonner.cjs +1 -1
  193. package/dist/sonner.js +26 -26
  194. package/dist/stepper.cjs +1 -1
  195. package/dist/stepper.js +40 -40
  196. package/dist/table.cjs +1 -1
  197. package/dist/table.d.ts.map +1 -1
  198. package/dist/table.js +31 -28
  199. package/dist/tabs.cjs +1 -1
  200. package/dist/tabs.js +1 -1
  201. package/dist/text-reveal-motion.d.ts +10 -0
  202. package/dist/text-reveal-motion.d.ts.map +1 -1
  203. package/dist/textarea.cjs +1 -1
  204. package/dist/textarea.js +11 -11
  205. package/dist/toggle.cjs +1 -1
  206. package/dist/toggle.js +8 -8
  207. package/dist/tooltip.cjs +1 -1
  208. package/dist/tooltip.js +8 -8
  209. package/dist/typography-heading.cjs +1 -0
  210. package/dist/typography-heading.d.ts +129 -0
  211. package/dist/typography-heading.d.ts.map +1 -0
  212. package/dist/typography-heading.js +95 -0
  213. package/dist/typography-text.cjs +1 -0
  214. package/dist/typography-text.d.ts +127 -0
  215. package/dist/typography-text.d.ts.map +1 -0
  216. package/dist/typography-text.js +92 -0
  217. package/dist/typography.d.ts +13 -0
  218. package/dist/typography.d.ts.map +1 -1
  219. package/package.json +35 -7
  220. package/src/blocks/empty-state.tsx +412 -0
  221. package/src/blocks/input-list.tsx +66 -36
  222. package/src/blocks/{progress-screen.tsx → progress-state.tsx} +154 -93
  223. package/src/blocks/sidebar.tsx +25 -26
  224. package/src/components/accordion.tsx +82 -27
  225. package/src/components/alert-dialog.tsx +2 -2
  226. package/src/components/alert.tsx +27 -13
  227. package/src/components/avatar.tsx +1 -1
  228. package/src/components/badge.tsx +8 -4
  229. package/src/components/breadcrumb.tsx +1 -1
  230. package/src/components/button-group.tsx +112 -0
  231. package/src/components/button.tsx +4 -4
  232. package/src/components/calendar.tsx +5 -6
  233. package/src/components/callout.tsx +48 -15
  234. package/src/components/card.tsx +89 -19
  235. package/src/components/chart-empty.tsx +116 -0
  236. package/src/components/chart.tsx +103 -32
  237. package/src/components/chip.tsx +88 -13
  238. package/src/components/combobox.tsx +12 -10
  239. package/src/components/command.tsx +64 -13
  240. package/src/components/context-menu.tsx +6 -9
  241. package/src/components/data-table.tsx +135 -20
  242. package/src/components/date-picker.tsx +18 -7
  243. package/src/components/description.tsx +1 -1
  244. package/src/components/dialog.tsx +2 -2
  245. package/src/components/drawer.tsx +2 -5
  246. package/src/components/dropdown-menu.tsx +8 -11
  247. package/src/components/field.tsx +89 -16
  248. package/src/components/global-layout.tsx +210 -39
  249. package/src/components/grid.tsx +130 -0
  250. package/src/components/header.tsx +13 -0
  251. package/src/components/hover-card.tsx +1 -1
  252. package/src/components/input-chip.tsx +1 -1
  253. package/src/components/input-group.tsx +1 -1
  254. package/src/components/input-otp.tsx +1 -1
  255. package/src/components/input-password.tsx +24 -12
  256. package/src/components/input.tsx +1 -1
  257. package/src/components/label.tsx +10 -13
  258. package/src/components/list.tsx +13 -9
  259. package/src/components/map.tsx +101 -5
  260. package/src/components/media-empty.tsx +156 -0
  261. package/src/components/menubar.tsx +7 -10
  262. package/src/components/navigation-menu.tsx +1 -1
  263. package/src/components/pagination.tsx +286 -1
  264. package/src/components/progress.tsx +35 -113
  265. package/src/components/scroll-area.tsx +23 -10
  266. package/src/components/select.tsx +35 -10
  267. package/src/components/separator.tsx +1 -1
  268. package/src/components/sheet.tsx +2 -2
  269. package/src/components/skeleton.tsx +78 -7
  270. package/src/components/sonner.tsx +2 -2
  271. package/src/components/stepper.tsx +3 -3
  272. package/src/components/table.tsx +6 -3
  273. package/src/components/tabs.tsx +1 -1
  274. package/src/components/text-reveal-motion.tsx +10 -0
  275. package/src/components/textarea.tsx +1 -1
  276. package/src/components/toggle.tsx +1 -1
  277. package/src/components/tooltip.tsx +1 -1
  278. package/src/components/typography-heading.tsx +253 -0
  279. package/src/components/typography-text.tsx +250 -0
  280. package/src/components/typography.tsx +13 -0
  281. package/src/hooks/use-delayed-pending.ts +60 -0
  282. package/src/index.ts +11 -1
  283. package/src/lib/block-illustration.tsx +88 -0
  284. package/src/lib/empty-canvas.tsx +128 -0
  285. package/src/lib/empty-chip.ts +24 -0
  286. package/src/lib/optical-center.tsx +45 -0
  287. package/src/lib/utils.ts +26 -0
  288. package/dist/blocks/progress-screen.cjs +0 -1
  289. package/dist/blocks/progress-screen.d.ts.map +0 -1
@@ -0,0 +1,11 @@
1
+ import { jsxs as a, Fragment as i, jsx as e } from "react/jsx-runtime";
2
+ function n({ children: r }) {
3
+ return /* @__PURE__ */ a(i, { children: [
4
+ /* @__PURE__ */ e("div", { "aria-hidden": "true", className: "flex-1" }),
5
+ r,
6
+ /* @__PURE__ */ e("div", { "aria-hidden": "true", className: "flex-[1.6]" })
7
+ ] });
8
+ }
9
+ export {
10
+ n as OpticalCenter
11
+ };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("clsx"),a=require("tailwind-merge"),o=a.extendTailwindMerge({extend:{classGroups:{duration:[{duration:["fast","base","slow"]}],ease:[{ease:["emphasized","overshoot"]}]}}});function s(...t){return o(e.clsx(t))}const d="data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 duration-base ease-out data-[state=closed]:duration-fast data-[state=closed]:ease-in";exports.FLOATING_CONTENT_ANIMATION=d;exports.cn=s;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("clsx"),a=require("tailwind-merge"),o=a.extendTailwindMerge({extend:{classGroups:{duration:[{duration:["fast","base","slow"]}],ease:[{ease:["emphasized","overshoot"]}],"font-weight":[{text:["emphasis"]}],"font-size":[{text:["display","heading-page","heading-section","heading-subsection","heading-compact","body","body-sm","body-xs","label","label-sm","metric","code","code-inline"]}]}}});function s(...e){return o(t.clsx(e))}const d="data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 duration-base ease-out data-[state=closed]:duration-fast data-[state=closed]:ease-in";exports.FLOATING_CONTENT_ANIMATION=d;exports.cn=s;
@@ -1 +1 @@
1
- {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/lib/utils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,KAAK,UAAU,EAAE,MAAM,MAAM,CAAC;AAe7C,wBAAgB,EAAE,CAAC,GAAG,MAAM,EAAE,UAAU,EAAE,UAEzC;AAED,eAAO,MAAM,0BAA0B,0aACkY,CAAC"}
1
+ {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/lib/utils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,KAAK,UAAU,EAAE,MAAM,MAAM,CAAC;AAyC7C,wBAAgB,EAAE,CAAC,GAAG,MAAM,EAAE,UAAU,EAAE,UAEzC;AAED,eAAO,MAAM,0BAA0B,0aACkY,CAAC"}
package/dist/lib/utils.js CHANGED
@@ -1,15 +1,38 @@
1
- import { clsx as a } from "clsx";
2
- import { extendTailwindMerge as e } from "tailwind-merge";
3
- const o = e({
1
+ import { clsx as e } from "clsx";
2
+ import { extendTailwindMerge as a } from "tailwind-merge";
3
+ const o = a({
4
4
  extend: {
5
5
  classGroups: {
6
6
  duration: [{ duration: ["fast", "base", "slow"] }],
7
- ease: [{ ease: ["emphasized", "overshoot"] }]
7
+ ease: [{ ease: ["emphasized", "overshoot"] }],
8
+ // text-emphasis sets font-weight only, so it belongs to the font-weight
9
+ // group (conflicts with font-bold etc.), NOT font-size — and unregistered
10
+ // it would be treated as a text colour and clobber color utilities.
11
+ "font-weight": [{ text: ["emphasis"] }],
12
+ "font-size": [
13
+ {
14
+ text: [
15
+ "display",
16
+ "heading-page",
17
+ "heading-section",
18
+ "heading-subsection",
19
+ "heading-compact",
20
+ "body",
21
+ "body-sm",
22
+ "body-xs",
23
+ "label",
24
+ "label-sm",
25
+ "metric",
26
+ "code",
27
+ "code-inline"
28
+ ]
29
+ }
30
+ ]
8
31
  }
9
32
  }
10
33
  });
11
34
  function i(...t) {
12
- return o(a(t));
35
+ return o(e(t));
13
36
  }
14
37
  const n = "data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 duration-base ease-out data-[state=closed]:duration-fast data-[state=closed]:ease-in";
15
38
  export {
package/dist/list.cjs CHANGED
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("react/jsx-runtime"),k=require("react"),h=require("@radix-ui/react-slot"),R=require("class-variance-authority"),n=require("@brightlocal/ui-components/lib/utils"),v=require("@brightlocal/ui-components/skeleton");function w(e){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const s=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(a,t,s.get?s:{enumerable:!0,get:()=>e[t]})}}return a.default=e,Object.freeze(a)}const r=w(k),d=R.cva(["flex","items-center","gap-4","rounded-lg","py-2","pr-2","pl-4","transition-colors","duration-fast","ease-out"],{variants:{variant:{default:[],filled:["bg-card"],outline:["bg-background","border","border-border"],loading:["p-0"]}},defaultVariants:{variant:"filled"}}),c=r.forwardRef(({className:e,dataHook:a,trackingEl:t,trackingLabel:s,...i},l)=>o.jsx("ul",{ref:l,className:n.cn("flex flex-col gap-2",e),"data-hook":a,"data-slot":"list","data-tracking-el":t,"data-tracking-label":s,...i}));c.displayName="List";const m=r.forwardRef(({asChild:e=!1,className:a,variant:t,dataHook:s,trackingEl:i,trackingLabel:l,children:I,...N},y)=>{const j=e?h.Slot:"li";return o.jsx(j,{ref:y,className:n.cn(d({variant:t}),a),"data-hook":s,"data-slot":"item","data-tracking-el":i,"data-tracking-label":l,...N,children:t==="loading"?o.jsx(v.Skeleton,{className:"h-13 w-full rounded-lg"}):I})});m.displayName="Item";const f=r.forwardRef(({className:e,...a},t)=>o.jsx("div",{ref:t,className:n.cn("shrink-0",e),"data-slot":"item-media",...a}));f.displayName="ItemMedia";const u=r.forwardRef(({className:e,...a},t)=>o.jsx("div",{ref:t,className:n.cn("flex flex-1 flex-col gap-1",e),"data-slot":"item-content",...a}));u.displayName="ItemContent";const p=r.forwardRef(({className:e,...a},t)=>o.jsx("div",{ref:t,className:n.cn("text-foreground text-base leading-normal font-medium",e),"data-slot":"item-title",...a}));p.displayName="ItemTitle";const g=r.forwardRef(({className:e,...a},t)=>o.jsx("div",{ref:t,className:n.cn("text-muted-foreground text-sm leading-normal font-normal",e),"data-slot":"item-description",...a}));g.displayName="ItemDescription";const x=r.forwardRef(({className:e,...a},t)=>o.jsx("div",{ref:t,className:n.cn("text-muted-foreground flex size-9 shrink-0 items-center justify-center rounded-full",e),"data-slot":"item-actions",...a}));x.displayName="ItemActions";const b=r.forwardRef(({className:e,dataHook:a,...t},s)=>o.jsx("li",{ref:s,className:n.cn("text-muted-foreground flex items-center py-2 pr-2 pl-4 text-base leading-none font-medium",e),"data-hook":a,"data-slot":"item-subheader",...t}));b.displayName="ItemSubheader";exports.Item=m;exports.ItemActions=x;exports.ItemContent=u;exports.ItemDescription=g;exports.ItemMedia=f;exports.ItemSubheader=b;exports.ItemTitle=p;exports.List=c;exports.itemVariants=d;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),k=require("react"),h=require("@radix-ui/react-slot"),R=require("class-variance-authority"),o=require("@brightlocal/ui-components/lib/utils"),v=require("@brightlocal/ui-components/skeleton");function w(e){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(a,t,r.get?r:{enumerable:!0,get:()=>e[t]})}}return a.default=e,Object.freeze(a)}const i=w(k),d=R.cva(["flex","items-center","gap-4","rounded-lg","py-2","pr-2","pl-4","transition-colors","duration-fast","ease-out"],{variants:{variant:{default:[],filled:["bg-card"],outline:["bg-background","border","border-border"],loading:["p-0"]}},defaultVariants:{variant:"filled"}}),c=i.forwardRef(({className:e,dataHook:a,trackingEl:t,trackingLabel:r,...n},l)=>s.jsx("ul",{ref:l,className:o.cn("flex flex-col gap-2",e),"data-hook":a,"data-slot":"list","data-tracking-el":t,"data-tracking-label":r,...n}));c.displayName="List";const m=i.forwardRef(({asChild:e=!1,className:a,variant:t,dataHook:r,trackingEl:n,trackingLabel:l,children:I,...y},N)=>{const j=e?h.Slot:"li";return s.jsx(j,{ref:N,className:o.cn(d({variant:t}),a),"data-hook":r,"data-slot":"item","data-tracking-el":n,"data-tracking-label":l,...y,children:t==="loading"?s.jsx(v.Skeleton,{className:"h-13 w-full rounded-lg"}):I})});m.displayName="Item";const f=i.forwardRef(({className:e,...a},t)=>s.jsx("div",{ref:t,className:o.cn("shrink-0",e),"data-slot":"item-media",...a}));f.displayName="ItemMedia";const u=i.forwardRef(({className:e,...a},t)=>s.jsx("div",{ref:t,className:o.cn("flex flex-1 flex-col gap-1",e),"data-slot":"item-content",...a}));u.displayName="ItemContent";const p=i.forwardRef(({className:e,...a},t)=>s.jsx("div",{ref:t,className:o.cn("text-foreground text-body",e),"data-slot":"item-title",...a}));p.displayName="ItemTitle";const g=i.forwardRef(({className:e,...a},t)=>s.jsx("div",{ref:t,className:o.cn("text-body-sm text-muted-foreground",e),"data-slot":"item-description",...a}));g.displayName="ItemDescription";const x=i.forwardRef(({className:e,...a},t)=>s.jsx("div",{ref:t,className:o.cn("text-muted-foreground flex size-9 shrink-0 items-center justify-center rounded-full",e),"data-slot":"item-actions",...a}));x.displayName="ItemActions";const b=i.forwardRef(({className:e,dataHook:a,...t},r)=>s.jsx("li",{ref:r,className:o.cn("text-muted-foreground text-label-sm flex items-center pt-4 pr-2 pb-1 pl-4 first:pt-2",e),"data-hook":a,"data-slot":"item-subheader",...t}));b.displayName="ItemSubheader";exports.Item=m;exports.ItemActions=x;exports.ItemContent=u;exports.ItemDescription=g;exports.ItemMedia=f;exports.ItemSubheader=b;exports.ItemTitle=p;exports.List=c;exports.itemVariants=d;
@@ -1 +1 @@
1
- {"version":3,"file":"list.d.ts","sourceRoot":"","sources":["../../src/components/list.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAW/B,QAAA,MAAM,YAAY;;8EA0BjB,CAAC;AAMF;;;GAGG;AACH,MAAM,MAAM,SAAS,GAAG,KAAK,CAAC,cAAc,CAAC,IAAI,CAAC,GAAG;IACnD;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB,CAAC;AAEF;;;;;;;;;;;;;;;;GAgBG;AACH,QAAA,MAAM,IAAI,iGAYT,CAAC;AAOF;;;GAGG;AACH,MAAM,MAAM,SAAS,GAAG,KAAK,CAAC,cAAc,CAAC,IAAI,CAAC,GAAG;IACnD;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;;;;;;;O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A,MAAM,WAAW,mKAShB,CAAC;AAOF,iFAAiF;AACjF,MAAM,MAAM,cAAc,GAAG,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC;AAEzD;;GAEG;AACH,QAAA,MAAM,SAAS,mKASd,CAAC;AAOF,uFAAuF;AACvF,MAAM,MAAM,oBAAoB,GAAG,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC;AAE/D;;GAEG;AACH,QAAA,MAAM,eAAe,mKASpB,CAAC;AAOF,qFAAqF;AACrF,MAAM,MAAM,gBAAgB,GAAG,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC;AAE3D;;GAEG;AACH,QAAA,MAAM,WAAW,mKAYhB,CAAC;AAOF,iFAAiF;AACjF,MAAM,MAAM,kBAAkB,GAAG,KAAK,CAAC,cAAc,CAAC,IAAI,CAAC,GAAG;IAC5D;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF;;;;;;;;;;;GAWG;AACH,QAAA,MAAM,aAAa,uGAuBlB,CAAC;AAOF,OAAO,EACL,IAAI,EACJ,IAAI,EACJ,SAAS,EACT,WAAW,EACX,SAAS,EACT,eAAe,EACf,WAAW,EACX,aAAa,EACb,YAAY,GACb,CAAC"}
package/dist/list.js CHANGED
@@ -2,7 +2,7 @@ import { jsx as o } from "react/jsx-runtime";
2
2
  import * as r from "react";
3
3
  import { Slot as c } from "@radix-ui/react-slot";
4
4
  import { cva as p } from "class-variance-authority";
5
- import { cn as i } from "@brightlocal/ui-components/lib/utils";
5
+ import { cn as s } from "@brightlocal/ui-components/lib/utils";
6
6
  import { Skeleton as u } from "@brightlocal/ui-components/skeleton";
7
7
  const g = p(
8
8
  [
@@ -31,41 +31,41 @@ const g = p(
31
31
  }
32
32
  }
33
33
  ), x = r.forwardRef(
34
- ({ className: t, dataHook: a, trackingEl: e, trackingLabel: l, ...d }, s) => /* @__PURE__ */ o(
34
+ ({ className: e, dataHook: a, trackingEl: t, trackingLabel: i, ...l }, d) => /* @__PURE__ */ o(
35
35
  "ul",
36
36
  {
37
- ref: s,
38
- className: i("flex flex-col gap-2", t),
37
+ ref: d,
38
+ className: s("flex flex-col gap-2", e),
39
39
  "data-hook": a,
40
40
  "data-slot": "list",
41
- "data-tracking-el": e,
42
- "data-tracking-label": l,
43
- ...d
41
+ "data-tracking-el": t,
42
+ "data-tracking-label": i,
43
+ ...l
44
44
  }
45
45
  )
46
46
  );
47
47
  x.displayName = "List";
48
48
  const N = r.forwardRef(
49
49
  ({
50
- asChild: t = !1,
50
+ asChild: e = !1,
51
51
  className: a,
52
- variant: e,
53
- dataHook: l,
54
- trackingEl: d,
55
- trackingLabel: s,
52
+ variant: t,
53
+ dataHook: i,
54
+ trackingEl: l,
55
+ trackingLabel: d,
56
56
  children: m,
57
57
  ...n
58
58
  }, f) => /* @__PURE__ */ o(
59
- t ? c : "li",
59
+ e ? c : "li",
60
60
  {
61
61
  ref: f,
62
- className: i(g({ variant: e }), a),
63
- "data-hook": l,
62
+ className: s(g({ variant: t }), a),
63
+ "data-hook": i,
64
64
  "data-slot": "item",
65
- "data-tracking-el": d,
66
- "data-tracking-label": s,
65
+ "data-tracking-el": l,
66
+ "data-tracking-label": d,
67
67
  ...n,
68
- children: e === "loading" ? (
68
+ children: t === "loading" ? (
69
69
  /* One skeleton per data row, mirroring the filled row's footprint:
70
70
  h-13 = py-2 × 2 + the size-9 actions slot that drives the row's
71
71
  height, so nothing shifts when the content arrives. */
@@ -75,68 +75,62 @@ const N = r.forwardRef(
75
75
  )
76
76
  );
77
77
  N.displayName = "Item";
78
- const I = r.forwardRef(
79
- ({ className: t, ...a }, e) => /* @__PURE__ */ o(
78
+ const b = r.forwardRef(
79
+ ({ className: e, ...a }, t) => /* @__PURE__ */ o(
80
80
  "div",
81
81
  {
82
- ref: e,
83
- className: i("shrink-0", t),
82
+ ref: t,
83
+ className: s("shrink-0", e),
84
84
  "data-slot": "item-media",
85
85
  ...a
86
86
  }
87
87
  )
88
88
  );
89
- I.displayName = "ItemMedia";
90
- const b = r.forwardRef(
91
- ({ className: t, ...a }, e) => /* @__PURE__ */ o(
89
+ b.displayName = "ItemMedia";
90
+ const I = r.forwardRef(
91
+ ({ className: e, ...a }, t) => /* @__PURE__ */ o(
92
92
  "div",
93
93
  {
94
- ref: e,
95
- className: i("flex flex-1 flex-col gap-1", t),
94
+ ref: t,
95
+ className: s("flex flex-1 flex-col gap-1", e),
96
96
  "data-slot": "item-content",
97
97
  ...a
98
98
  }
99
99
  )
100
100
  );
101
- b.displayName = "ItemContent";
102
- const k = r.forwardRef(
103
- ({ className: t, ...a }, e) => /* @__PURE__ */ o(
101
+ I.displayName = "ItemContent";
102
+ const y = r.forwardRef(
103
+ ({ className: e, ...a }, t) => /* @__PURE__ */ o(
104
104
  "div",
105
105
  {
106
- ref: e,
107
- className: i(
108
- "text-foreground text-base leading-normal font-medium",
109
- t
110
- ),
106
+ ref: t,
107
+ className: s("text-foreground text-body", e),
111
108
  "data-slot": "item-title",
112
109
  ...a
113
110
  }
114
111
  )
115
112
  );
116
- k.displayName = "ItemTitle";
117
- const y = r.forwardRef(
118
- ({ className: t, ...a }, e) => /* @__PURE__ */ o(
113
+ y.displayName = "ItemTitle";
114
+ const k = r.forwardRef(
115
+ ({ className: e, ...a }, t) => /* @__PURE__ */ o(
119
116
  "div",
120
117
  {
121
- ref: e,
122
- className: i(
123
- "text-muted-foreground text-sm leading-normal font-normal",
124
- t
125
- ),
118
+ ref: t,
119
+ className: s("text-body-sm text-muted-foreground", e),
126
120
  "data-slot": "item-description",
127
121
  ...a
128
122
  }
129
123
  )
130
124
  );
131
- y.displayName = "ItemDescription";
125
+ k.displayName = "ItemDescription";
132
126
  const h = r.forwardRef(
133
- ({ className: t, ...a }, e) => /* @__PURE__ */ o(
127
+ ({ className: e, ...a }, t) => /* @__PURE__ */ o(
134
128
  "div",
135
129
  {
136
- ref: e,
137
- className: i(
130
+ ref: t,
131
+ className: s(
138
132
  "text-muted-foreground flex size-9 shrink-0 items-center justify-center rounded-full",
139
- t
133
+ e
140
134
  ),
141
135
  "data-slot": "item-actions",
142
136
  ...a
@@ -145,17 +139,27 @@ const h = r.forwardRef(
145
139
  );
146
140
  h.displayName = "ItemActions";
147
141
  const w = r.forwardRef(
148
- ({ className: t, dataHook: a, ...e }, l) => /* @__PURE__ */ o(
142
+ ({ className: e, dataHook: a, ...t }, i) => /* @__PURE__ */ o(
149
143
  "li",
150
144
  {
151
- ref: l,
152
- className: i(
153
- "text-muted-foreground flex items-center py-2 pr-2 pl-4 text-base leading-none font-medium",
154
- t
145
+ ref: i,
146
+ className: s(
147
+ // A subheader is a caption over its group of items — the same role as a
148
+ // menu or sidebar group label, so text-label-sm (DS-925).
149
+ // Padding is deliberately asymmetric: with the old symmetric py-2 the
150
+ // caption sat equidistant between the previous group and its own
151
+ // (17px each side over the list's 8px gap), so it read as a second
152
+ // title rather than a label for the group below. 16px above / 4px
153
+ // below binds it downwards. The space above only has a job when a
154
+ // group precedes it, so a subheader that opens the list stays tight —
155
+ // that keeps compact surfaces (the Map popover, which sets gap-0
156
+ // inside p-3) from opening up.
157
+ "text-muted-foreground text-label-sm flex items-center pt-4 pr-2 pb-1 pl-4 first:pt-2",
158
+ e
155
159
  ),
156
160
  "data-hook": a,
157
161
  "data-slot": "item-subheader",
158
- ...e
162
+ ...t
159
163
  }
160
164
  )
161
165
  );
@@ -163,11 +167,11 @@ w.displayName = "ItemSubheader";
163
167
  export {
164
168
  N as Item,
165
169
  h as ItemActions,
166
- b as ItemContent,
167
- y as ItemDescription,
168
- I as ItemMedia,
170
+ I as ItemContent,
171
+ k as ItemDescription,
172
+ b as ItemMedia,
169
173
  w as ItemSubheader,
170
- k as ItemTitle,
174
+ y as ItemTitle,
171
175
  x as List,
172
176
  g as itemVariants
173
177
  };
package/dist/map.cjs CHANGED
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react/jsx-runtime"),ae=require("react"),ne=require("class-variance-authority"),P=require("@brightlocal/icons"),R=require("@brightlocal/illustrations"),L=require("@brightlocal/ui-components/button"),T=require("@brightlocal/ui-components/card"),g=require("@brightlocal/ui-components/lib/utils"),j=require("@brightlocal/ui-components/popover");function oe(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const a in e)if(a!=="default"){const n=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(t,a,n.get?n:{enumerable:!0,get:()=>e[a]})}}return t.default=e,Object.freeze(t)}const p=oe(ae),se={ROADMAP:"roadmap",SATELLITE:"satellite"},le=["water","landscape","road","poi","transit"];function ie(e,t){return[...le.map(a=>({featureType:a,elementType:"geometry",stylers:[{saturation:e,lightness:t}]})),{elementType:"labels.text.fill",stylers:[{saturation:e,lightness:t-10}]},{elementType:"labels.icon",stylers:[{saturation:e,lightness:t}]}]}const E=[{elementType:"geometry",stylers:[{color:"#444444"}]},{elementType:"labels.text.fill",stylers:[{color:"#aaaaaa"}]},{elementType:"labels.text.stroke",stylers:[{color:"#323232"}]},{featureType:"water",elementType:"geometry",stylers:[{color:"#30405a"}]},{featureType:"landscape",elementType:"geometry",stylers:[{color:"#4b4b4b"}]},{featureType:"road",elementType:"geometry",stylers:[{color:"#5c5c5c"}]},{featureType:"road",elementType:"geometry.stroke",stylers:[{color:"#3e3e3e"}]},{featureType:"poi",elementType:"geometry",stylers:[{color:"#525252"}]},{featureType:"transit",elementType:"geometry",stylers:[{color:"#505050"}]},{elementType:"labels.icon",stylers:[{visibility:"off"}]}],A={default:{light:[],dark:E},muted:{light:ie(-40,20),dark:E}},k=new Set;let w=typeof document<"u"&&!!document.body&&document.body.classList.contains("dark"),O=!1;function ce(){if(O||typeof document>"u")return;O=!0,new MutationObserver(()=>{const t=document.body.classList.contains("dark");if(t!==w){w=t;for(const a of k)a()}}).observe(document.body,{attributes:!0,attributeFilter:["class"]})}function de(e){return k.add(e),ce(),()=>{k.delete(e)}}function ue(){return w}function pe(){return!1}function I(){return p.useSyncExternalStore(de,ue,pe)}function me(e="default"){const t=I();return A[e][t?"dark":"light"]}const _={primary:"strong",secondary:"moderate",warning:"moderate",destructive:"unranked",outline:"unranked"};function fe(e){return e in _}function ge(e){return fe(e)?_[e]:e}const h={strong:{className:"bg-primary dark:bg-green-400",cssVar:"--ds-tailwind-colors-green-400",fallback:"#2ae855"},moderate:{className:"bg-chart-4",cssVar:"--ds-tailwind-colors-yellow-400",fallback:"#facc15"},weak:{className:"bg-orange-400",cssVar:"--ds-tailwind-colors-orange-400",fallback:"#fb923c"},unranked:{className:"bg-red-600",cssVar:"--ds-tailwind-colors-red-600",fallback:"#dc2626"},error:{className:"bg-warning-background dark:bg-orange-200",cssVar:"--ds-tailwind-colors-orange-200",fallback:"#fed7aa"}},y=Object.fromEntries(Object.entries(h).map(([e,t])=>[e,t.className])),ye=ne.cva("inline-flex items-center justify-center rounded-full font-sans text-sm font-semibold text-foreground dark:text-neutral-900 border-2 border-white shadow-sm transition-shadow duration-fast ease-out hover:shadow-md",{variants:{variant:{strong:`${y.strong}`,moderate:`${y.moderate}`,weak:`${y.weak}`,unranked:`${y.unranked} text-white dark:text-white`,error:`${y.error}`}},defaultVariants:{variant:"strong"}}),C=p.forwardRef(({value:e,variant:t="strong",loading:a=!1,pulse:n,dataHook:s,className:o,trackingEl:r,trackingLabel:c,style:i,...d},m)=>{const u=ge(t);return l.jsx("div",{ref:m,className:g.cn(a?"border-border bg-accent rounded-full border":ye({variant:u}),"size-8 p-0",o),"data-hook":s,"data-slot":"map-grid-pin","data-state":a?"loading":void 0,"data-tracking-el":r||"map-grid-pin","data-tracking-label":c,style:i,...d,children:u==="error"&&!a?l.jsx(P.TriangleAlert,{"aria-hidden":"true",className:"text-warning-foreground",size:14}):String(e)})});C.displayName="MapGridPin";function D(){const t={colors:Object.fromEntries(Object.entries(h).map(([n,s])=>[n,s.fallback])),fontFamily:"Inter, system-ui, sans-serif",textColor:"#111412"};if(typeof document>"u")return t;const a=getComputedStyle(document.documentElement);return{colors:Object.fromEntries(Object.entries(h).map(([n,{cssVar:s,fallback:o}])=>[n,a.getPropertyValue(s).trim()||o])),fontFamily:a.getPropertyValue("--ds-font-font-sans").trim()||t.fontFamily,textColor:a.getPropertyValue("--ds-tailwind-colors-neutral-950").trim()||t.textColor}}function xe(){return D().colors}const be=Object.fromEntries(Object.entries(h).map(([e,t])=>[e,t.fallback])),M=["strong","moderate","weak","unranked","error"];function N(e,t){const{colors:a,fontFamily:n,textColor:s}=D(),o=40,r=o/2,c=2,i=r-c,d=i*.55,u=[...e].sort((f,x)=>M.indexOf(f.variant)-M.indexOf(x.variant)).filter(f=>f.count>0),W=u.reduce((f,x)=>f+x.count,0)||1,Z=Math.max(Number(t)||0,1);let b;const S=u[0];if(u.length<=1){const f=S?a[S.variant]:"#e5e7eb";b=`<circle cx="${r}" cy="${r}" r="${i}" fill="${f}"/>`}else{b="";let f=-Math.PI/2;for(const x of u){const $=x.count/W*Math.PI*2,v=f+$,Q=r+i*Math.cos(f),X=r+i*Math.sin(f),ee=r+i*Math.cos(v),te=r+i*Math.sin(v),re=$>Math.PI?1:0;b+=`<path d="M${r},${r}L${Q.toFixed(2)},${X.toFixed(2)}A${i},${i} 0 ${re} 1 ${ee.toFixed(2)},${te.toFixed(2)}Z" fill="${a[x.variant]}"/>`,f=v}}const J=Math.round(o*.3);return[`<svg xmlns="http://www.w3.org/2000/svg" width="${o}" height="${o}" viewBox="0 0 ${o} ${o}" style="filter:drop-shadow(0 1px 2px rgba(0,0,0,.15))">`,`<circle cx="${r}" cy="${r}" r="${r}" fill="white"/>`,b,`<circle cx="${r}" cy="${r}" r="${i}" fill="none" stroke="white" stroke-width="${c}"/>`,`<circle cx="${r}" cy="${r}" r="${d}" fill="white"/>`,`<text x="${r}" y="${r}" text-anchor="middle" dominant-baseline="central" font-family="${n}" font-size="${J}" font-weight="600" fill="${s}">${Z}</text>`,"</svg>"].join("")}function he(e){if(typeof DOMParser>"u")throw new Error("createClusterPinElement requires a browser environment (DOMParser). Use createClusterPinSvg for SSR.");const{markers:t,count:a,getVariant:n}=e,s=new Map;for(const m of t){const u=n(m);s.set(u,(s.get(u)??0)+1)}const o=[];for(const m of M){const u=s.get(m);u&&o.push({variant:m,count:u})}const r=N(o,a),d=new DOMParser().parseFromString(r,"image/svg+xml").documentElement;if(!(d instanceof SVGElement))throw new Error("createClusterPinElement: failed to parse SVG");return d}const V=p.forwardRef(({segments:e,count:t,dataHook:a,className:n,trackingEl:s,trackingLabel:o,...r},c)=>{const i=JSON.stringify(e),d=p.useMemo(()=>N(e,t),[i,t]);return l.jsx("div",{dangerouslySetInnerHTML:{__html:d},ref:c,className:g.cn("inline-flex items-center justify-center",n),"data-hook":a,"data-slot":"map-cluster-pin","data-tracking-el":s||"map-cluster-pin","data-tracking-label":o,...r})});V.displayName="MapClusterPin";const F=p.forwardRef(({icon:e,animateIn:t=!1,value:a,variant:n,pulse:s,dataHook:o,className:r,trackingEl:c,trackingLabel:i,ariaLabel:d,...m},u)=>a!==void 0||n!==void 0||s!==void 0?l.jsx(C,{ref:u,className:r,dataHook:o,pulse:s,trackingEl:c,trackingLabel:i,value:a??1,variant:n,...m}):l.jsx("div",{ref:u,"aria-label":d??"Location",className:g.cn("relative inline-flex h-[46px] w-[38px] items-start justify-center",r),"data-hook":o,"data-slot":"map-location-pin","data-tracking-el":c||"map-location-pin","data-tracking-label":i,role:"img",...m,children:l.jsxs("span",{"aria-hidden":"true",className:g.cn("relative flex size-full",t&&"animate-emphasis-pop origin-bottom will-change-transform"),children:[l.jsxs("svg",{"aria-hidden":"true",className:"size-full overflow-visible drop-shadow-sm",fill:"none",viewBox:"0 0 38 46",children:[l.jsx("path",{className:"fill-white",d:"M38 19.15C38 29.21 29.4 35.77 20.38 44.63C19.61 45.39 18.37 45.41 17.58 44.67C8.01 35.79 0 29.23 0 19.15C0 8.57 8.51 0 19 0C29.49 0 38 8.57 38 19.15Z"}),l.jsx("circle",{className:"fill-sky-500",cx:"19",cy:"19",r:"16"})]}),l.jsx("span",{className:"absolute top-[19px] left-1/2 flex -translate-x-1/2 -translate-y-1/2 items-center justify-center text-white",children:e??l.jsx(P.Store,{size:16})})]})}));F.displayName="MapLocationPin";const z=p.forwardRef(({className:e,dataHook:t,trackingEl:a,trackingLabel:n,children:s,iconOnly:o=!0,...r},c)=>{const i=I();return l.jsx(L.Button,{ref:c,className:e,"data-slot":"map-control-button",dataHook:t,iconOnly:o,trackingEl:a||"map-control-button",trackingLabel:n,variant:i?"secondary":"outline",...r,children:s})});z.displayName="MapControlButton";const q=p.forwardRef(({className:e,children:t,dataHook:a,trackingEl:n,trackingLabel:s,ariaLabel:o,...r},c)=>l.jsxs("div",{ref:c,"aria-label":o??"Loading map",className:g.cn("border-border relative flex h-full w-full items-center justify-center overflow-hidden rounded-lg border",e),"data-hook":a,"data-slot":"map-loading-state","data-tracking-el":n||"map-loading-state","data-tracking-label":s,role:"status",...r,children:[l.jsx(B,{}),t&&l.jsx("div",{className:"relative",children:t})]}));q.displayName="MapLoadingState";const B=p.memo(function({rounded:t}){return l.jsx(R.MapBackground,{"aria-hidden":"true",className:g.cn("absolute inset-0 h-full w-full object-cover",t&&"rounded-[inherit]"),mode:"auto"})}),G=p.forwardRef(({className:e,title:t="We couldn't load your map rankings.",message:a="Reloading usually fixes it, and it won't use any credits",onRetry:n,retryLoading:s=!1,retryLabel:o="Reload",dataHook:r,trackingEl:c,trackingLabel:i,...d},m)=>l.jsxs("div",{ref:m,className:g.cn("border-border relative flex h-full w-full flex-col items-center justify-center gap-4 rounded-lg border p-4 text-center sm:gap-6 sm:p-8",e),"data-hook":r,"data-slot":"map-error-state","data-tracking-el":c||"map-error-state","data-tracking-label":i,role:"alert",...d,children:[l.jsx(B,{rounded:!0}),l.jsxs("div",{className:"relative flex flex-col items-center gap-4 sm:gap-6",children:[l.jsx("div",{"aria-hidden":"true",className:"flex items-center justify-center","data-slot":"map-error-illustration",children:l.jsx(R.GlobeyFixingFault,{className:"h-auto w-full max-w-41"})}),l.jsxs("div",{className:"flex flex-col gap-2",children:[l.jsx("h3",{className:"text-foreground text-lg font-medium","data-slot":"map-error-title",children:t}),a&&l.jsx("p",{className:"text-muted-foreground text-sm","data-slot":"map-error-message",children:a})]}),n&&l.jsxs(L.Button,{className:"mt-1",dataHook:`${r}-retry`,loading:s,size:"sm",variant:"primary",onClick:n,children:[!s&&l.jsx(P.RefreshCw,{"aria-hidden":"true"}),o]})]})]}));G.displayName="MapErrorState";const K=p.forwardRef(({variant:e,color:t,dataHook:a,className:n,children:s,...o},r)=>{const c=e?y[e]:t;return l.jsxs("span",{ref:r,className:g.cn("text-foreground flex items-center gap-1 font-sans text-xs",n),"data-hook":a,"data-slot":"map-legend-item",...o,children:[l.jsx("span",{"aria-hidden":"true",className:g.cn("inline-block size-2 shrink-0 rounded-full",c)}),s]})});K.displayName="MapLegendItem";const Y=p.forwardRef(({className:e,dataHook:t,trackingEl:a,trackingLabel:n,ariaLabel:s,children:o,...r},c)=>l.jsx(T.Card,{ref:c,"aria-label":s??"Map legend",className:g.cn("inline-flex w-auto max-w-none flex-row items-center bg-white font-sans dark:bg-neutral-800",e),"data-slot":"map-legend",dataHook:t,density:"condensed",role:"group",trackingEl:a||"map-legend",trackingLabel:n,variant:"border",...r,children:l.jsx(T.CardContent,{className:"flex items-center gap-3",children:o})}));Y.displayName="MapLegend";function ve(e){const{hoverWhenOpen:t=!1}=e??{},[a,n]=p.useState(null),[s,o]=p.useState(null),r=p.useCallback(d=>{o(d),n(d)},[]),c=p.useCallback(()=>{n(null)},[]),i=p.useCallback(d=>{const m={onClick:()=>r(d)};return t&&(m.onPointerEnter=u=>{u.pointerType==="mouse"&&a!=null&&r(d)}),m},[t,r,a]);return{activeItem:a,anchorItem:s,showItem:r,close:c,getInteractionProps:i}}const ke=j.Popover,H=j.PopoverAnchor;H.displayName="MapPopoverAnchor";const U=p.forwardRef(({className:e,side:t="top",sideOffset:a=4,dataHook:n,trackingEl:s,trackingLabel:o,...r},c)=>l.jsx(j.PopoverContent,{ref:c,className:g.cn("w-auto max-w-68.25 p-3 data-[state=closed]:animate-none data-[state=closed]:opacity-0",e),"data-slot":"map-popover-content","data-tracking-el":s||"map-popover","data-tracking-label":o,dataHook:n,side:t,sideOffset:a,onCloseAutoFocus:i=>i.preventDefault(),onOpenAutoFocus:i=>i.preventDefault(),...r}));U.displayName="MapPopoverContent";exports.MAP_STYLES=A;exports.MapClusterPin=V;exports.MapControlButton=z;exports.MapErrorState=G;exports.MapGridPin=C;exports.MapLegend=Y;exports.MapLegendItem=K;exports.MapLoadingState=q;exports.MapLocationPin=F;exports.MapPopover=ke;exports.MapPopoverAnchor=H;exports.MapPopoverContent=U;exports.MapTypeId=se;exports.clusterPinHexColors=be;exports.createClusterPinElement=he;exports.createClusterPinSvg=N;exports.mapGridPinColorMap=y;exports.resolveClusterPinColors=xe;exports.useMapPopoverClick=ve;exports.useMapStyles=me;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react/jsx-runtime"),ne=require("react"),oe=require("class-variance-authority"),v=require("@brightlocal/icons"),R=require("@brightlocal/illustrations"),L=require("@brightlocal/ui-components/button"),T=require("@brightlocal/ui-components/card"),g=require("@brightlocal/ui-components/lib/utils"),j=require("@brightlocal/ui-components/popover"),se=require("./lib/empty-canvas.cjs");function le(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const p=le(ne),ie={ROADMAP:"roadmap",SATELLITE:"satellite"},ce=["water","landscape","road","poi","transit"];function de(e,t){return[...ce.map(r=>({featureType:r,elementType:"geometry",stylers:[{saturation:e,lightness:t}]})),{elementType:"labels.text.fill",stylers:[{saturation:e,lightness:t-10}]},{elementType:"labels.icon",stylers:[{saturation:e,lightness:t}]}]}const E=[{elementType:"geometry",stylers:[{color:"#444444"}]},{elementType:"labels.text.fill",stylers:[{color:"#aaaaaa"}]},{elementType:"labels.text.stroke",stylers:[{color:"#323232"}]},{featureType:"water",elementType:"geometry",stylers:[{color:"#30405a"}]},{featureType:"landscape",elementType:"geometry",stylers:[{color:"#4b4b4b"}]},{featureType:"road",elementType:"geometry",stylers:[{color:"#5c5c5c"}]},{featureType:"road",elementType:"geometry.stroke",stylers:[{color:"#3e3e3e"}]},{featureType:"poi",elementType:"geometry",stylers:[{color:"#525252"}]},{featureType:"transit",elementType:"geometry",stylers:[{color:"#505050"}]},{elementType:"labels.icon",stylers:[{visibility:"off"}]}],A={default:{light:[],dark:E},muted:{light:de(-40,20),dark:E}},M=new Set;let w=typeof document<"u"&&!!document.body&&document.body.classList.contains("dark"),O=!1;function ue(){if(O||typeof document>"u")return;O=!0,new MutationObserver(()=>{const t=document.body.classList.contains("dark");if(t!==w){w=t;for(const r of M)r()}}).observe(document.body,{attributes:!0,attributeFilter:["class"]})}function pe(e){return M.add(e),ue(),()=>{M.delete(e)}}function me(){return w}function fe(){return!1}function I(){return p.useSyncExternalStore(pe,me,fe)}function ge(e="default"){const t=I();return A[e][t?"dark":"light"]}const _={primary:"strong",secondary:"moderate",warning:"moderate",destructive:"unranked",outline:"unranked"};function ye(e){return e in _}function xe(e){return ye(e)?_[e]:e}const h={strong:{className:"bg-primary dark:bg-green-400",cssVar:"--ds-tailwind-colors-green-400",fallback:"#2ae855"},moderate:{className:"bg-chart-4",cssVar:"--ds-tailwind-colors-yellow-400",fallback:"#facc15"},weak:{className:"bg-orange-400",cssVar:"--ds-tailwind-colors-orange-400",fallback:"#fb923c"},unranked:{className:"bg-red-600",cssVar:"--ds-tailwind-colors-red-600",fallback:"#dc2626"},error:{className:"bg-warning-background dark:bg-orange-200",cssVar:"--ds-tailwind-colors-orange-200",fallback:"#fed7aa"}},y=Object.fromEntries(Object.entries(h).map(([e,t])=>[e,t.className])),be=oe.cva("inline-flex items-center justify-center rounded-full text-label font-semibold text-foreground dark:text-neutral-900 border-2 border-white shadow-sm transition-shadow duration-fast ease-out hover:shadow-md",{variants:{variant:{strong:`${y.strong}`,moderate:`${y.moderate}`,weak:`${y.weak}`,unranked:`${y.unranked} text-white dark:text-white`,error:`${y.error}`}},defaultVariants:{variant:"strong"}}),C=p.forwardRef(({value:e,variant:t="strong",loading:r=!1,pulse:n,dataHook:s,className:o,trackingEl:a,trackingLabel:c,style:i,...d},m)=>{const u=xe(t);return l.jsx("div",{ref:m,className:g.cn(r?"border-border bg-accent rounded-full border":be({variant:u}),"size-8 p-0",o),"data-hook":s,"data-slot":"map-grid-pin","data-state":r?"loading":void 0,"data-tracking-el":a||"map-grid-pin","data-tracking-label":c,style:i,...d,children:u==="error"&&!r?l.jsx(v.TriangleAlert,{"aria-hidden":"true",className:"text-warning-foreground",size:14}):String(e)})});C.displayName="MapGridPin";function D(){const t={colors:Object.fromEntries(Object.entries(h).map(([n,s])=>[n,s.fallback])),fontFamily:"Inter, system-ui, sans-serif",textColor:"#111412"};if(typeof document>"u")return t;const r=getComputedStyle(document.documentElement);return{colors:Object.fromEntries(Object.entries(h).map(([n,{cssVar:s,fallback:o}])=>[n,r.getPropertyValue(s).trim()||o])),fontFamily:r.getPropertyValue("--ds-font-font-sans").trim()||t.fontFamily,textColor:r.getPropertyValue("--ds-tailwind-colors-neutral-950").trim()||t.textColor}}function he(){return D().colors}const ve=Object.fromEntries(Object.entries(h).map(([e,t])=>[e,t.fallback])),P=["strong","moderate","weak","unranked","error"];function N(e,t){const{colors:r,fontFamily:n,textColor:s}=D(),o=40,a=o/2,c=2,i=a-c,d=i*.55,u=[...e].sort((f,x)=>P.indexOf(f.variant)-P.indexOf(x.variant)).filter(f=>f.count>0),Z=u.reduce((f,x)=>f+x.count,0)||1,J=Math.max(Number(t)||0,1);let b;const S=u[0];if(u.length<=1){const f=S?r[S.variant]:"#e5e7eb";b=`<circle cx="${a}" cy="${a}" r="${i}" fill="${f}"/>`}else{b="";let f=-Math.PI/2;for(const x of u){const $=x.count/Z*Math.PI*2,k=f+$,X=a+i*Math.cos(f),ee=a+i*Math.sin(f),te=a+i*Math.cos(k),ae=a+i*Math.sin(k),re=$>Math.PI?1:0;b+=`<path d="M${a},${a}L${X.toFixed(2)},${ee.toFixed(2)}A${i},${i} 0 ${re} 1 ${te.toFixed(2)},${ae.toFixed(2)}Z" fill="${r[x.variant]}"/>`,f=k}}const Q=Math.round(o*.3);return[`<svg xmlns="http://www.w3.org/2000/svg" width="${o}" height="${o}" viewBox="0 0 ${o} ${o}" style="filter:drop-shadow(0 1px 2px rgba(0,0,0,.15))">`,`<circle cx="${a}" cy="${a}" r="${a}" fill="white"/>`,b,`<circle cx="${a}" cy="${a}" r="${i}" fill="none" stroke="white" stroke-width="${c}"/>`,`<circle cx="${a}" cy="${a}" r="${d}" fill="white"/>`,`<text x="${a}" y="${a}" text-anchor="middle" dominant-baseline="central" font-family="${n}" font-size="${Q}" font-weight="600" fill="${s}">${J}</text>`,"</svg>"].join("")}function ke(e){if(typeof DOMParser>"u")throw new Error("createClusterPinElement requires a browser environment (DOMParser). Use createClusterPinSvg for SSR.");const{markers:t,count:r,getVariant:n}=e,s=new Map;for(const m of t){const u=n(m);s.set(u,(s.get(u)??0)+1)}const o=[];for(const m of P){const u=s.get(m);u&&o.push({variant:m,count:u})}const a=N(o,r),d=new DOMParser().parseFromString(a,"image/svg+xml").documentElement;if(!(d instanceof SVGElement))throw new Error("createClusterPinElement: failed to parse SVG");return d}const V=p.forwardRef(({segments:e,count:t,dataHook:r,className:n,trackingEl:s,trackingLabel:o,...a},c)=>{const i=JSON.stringify(e),d=p.useMemo(()=>N(e,t),[i,t]);return l.jsx("div",{dangerouslySetInnerHTML:{__html:d},ref:c,className:g.cn("inline-flex items-center justify-center",n),"data-hook":r,"data-slot":"map-cluster-pin","data-tracking-el":s||"map-cluster-pin","data-tracking-label":o,...a})});V.displayName="MapClusterPin";const F=p.forwardRef(({icon:e,animateIn:t=!1,value:r,variant:n,pulse:s,dataHook:o,className:a,trackingEl:c,trackingLabel:i,ariaLabel:d,...m},u)=>r!==void 0||n!==void 0||s!==void 0?l.jsx(C,{ref:u,className:a,dataHook:o,pulse:s,trackingEl:c,trackingLabel:i,value:r??1,variant:n,...m}):l.jsx("div",{ref:u,"aria-label":d??"Location",className:g.cn("relative inline-flex h-[46px] w-[38px] items-start justify-center",a),"data-hook":o,"data-slot":"map-location-pin","data-tracking-el":c||"map-location-pin","data-tracking-label":i,role:"img",...m,children:l.jsxs("span",{"aria-hidden":"true",className:g.cn("relative flex size-full",t&&"animate-emphasis-pop origin-bottom will-change-transform"),children:[l.jsxs("svg",{"aria-hidden":"true",className:"size-full overflow-visible drop-shadow-sm",fill:"none",viewBox:"0 0 38 46",children:[l.jsx("path",{className:"fill-white",d:"M38 19.15C38 29.21 29.4 35.77 20.38 44.63C19.61 45.39 18.37 45.41 17.58 44.67C8.01 35.79 0 29.23 0 19.15C0 8.57 8.51 0 19 0C29.49 0 38 8.57 38 19.15Z"}),l.jsx("circle",{className:"fill-sky-500",cx:"19",cy:"19",r:"16"})]}),l.jsx("span",{className:"absolute top-[19px] left-1/2 flex -translate-x-1/2 -translate-y-1/2 items-center justify-center text-white",children:e??l.jsx(v.Store,{size:16})})]})}));F.displayName="MapLocationPin";const q=p.forwardRef(({className:e,dataHook:t,trackingEl:r,trackingLabel:n,children:s,iconOnly:o=!0,...a},c)=>{const i=I();return l.jsx(L.Button,{ref:c,className:e,"data-slot":"map-control-button",dataHook:t,iconOnly:o,trackingEl:r||"map-control-button",trackingLabel:n,variant:i?"secondary":"outline",...a,children:s})});q.displayName="MapControlButton";const z=p.forwardRef(({className:e,children:t,dataHook:r,trackingEl:n,trackingLabel:s,ariaLabel:o,...a},c)=>l.jsxs("div",{ref:c,"aria-label":o??"Loading map",className:g.cn("border-border relative flex h-full w-full items-center justify-center overflow-hidden rounded-lg border",e),"data-hook":r,"data-slot":"map-loading-state","data-tracking-el":n||"map-loading-state","data-tracking-label":s,role:"status",...a,children:[l.jsx(B,{}),t&&l.jsx("div",{className:"relative",children:t})]}));z.displayName="MapLoadingState";const B=p.memo(function({rounded:t}){return l.jsx(R.MapBackground,{"aria-hidden":"true",className:g.cn("absolute inset-0 h-full w-full object-cover",t&&"rounded-[inherit]"),mode:"auto"})}),G=p.forwardRef(({className:e,title:t="We couldn't load your map rankings.",message:r="Reloading usually fixes it, and it won't use any credits",onRetry:n,retryLoading:s=!1,retryLabel:o="Reload",dataHook:a,trackingEl:c,trackingLabel:i,...d},m)=>l.jsxs("div",{ref:m,className:g.cn("border-border relative flex h-full w-full flex-col items-center justify-center gap-4 rounded-lg border p-4 text-center sm:gap-6 sm:p-8",e),"data-hook":a,"data-slot":"map-error-state","data-tracking-el":c||"map-error-state","data-tracking-label":i,role:"alert",...d,children:[l.jsx(B,{rounded:!0}),l.jsxs("div",{className:"relative flex flex-col items-center gap-4 sm:gap-6",children:[l.jsx("div",{"aria-hidden":"true",className:"flex items-center justify-center","data-slot":"map-error-illustration",children:l.jsx(R.GlobeyFixingFault,{className:"h-auto w-full max-w-41"})}),l.jsxs("div",{className:"flex flex-col gap-2",children:[l.jsx("h3",{className:"text-foreground text-heading-subsection","data-slot":"map-error-title",children:t}),r&&l.jsx("p",{className:"text-muted-foreground text-body-sm","data-slot":"map-error-message",children:r})]}),n&&l.jsxs(L.Button,{className:"mt-1",dataHook:`${a}-retry`,loading:s,size:"sm",variant:"primary",onClick:n,children:[!s&&l.jsx(v.RefreshCw,{"aria-hidden":"true"}),o]})]})]}));G.displayName="MapErrorState";const K=p.forwardRef(({className:e,dataHook:t,icon:r,message:n,trackingEl:s,trackingLabel:o,...a},c)=>l.jsx(se.EmptyCanvas,{ref:c,className:g.cn("h-full w-full rounded-lg",e),dataHook:t,icon:r??l.jsx(v.Map,{strokeWidth:2}),message:n??"No data yet",slot:"map-empty",trackingEl:s,trackingLabel:o,...a}));K.displayName="MapEmpty";const W=p.forwardRef(({variant:e,color:t,dataHook:r,className:n,children:s,...o},a)=>{const c=e?y[e]:t;return l.jsxs("span",{ref:a,className:g.cn("text-foreground text-body-xs flex items-center gap-1",n),"data-hook":r,"data-slot":"map-legend-item",...o,children:[l.jsx("span",{"aria-hidden":"true",className:g.cn("inline-block size-2 shrink-0 rounded-full",c)}),s]})});W.displayName="MapLegendItem";const Y=p.forwardRef(({className:e,dataHook:t,trackingEl:r,trackingLabel:n,ariaLabel:s,children:o,...a},c)=>l.jsx(T.Card,{ref:c,"aria-label":s??"Map legend",className:g.cn("inline-flex w-auto max-w-none flex-row items-center bg-white font-sans dark:bg-neutral-800",e),"data-slot":"map-legend",dataHook:t,density:"condensed",role:"group",trackingEl:r||"map-legend",trackingLabel:n,variant:"border",...a,children:l.jsx(T.CardContent,{className:"flex items-center gap-3",children:o})}));Y.displayName="MapLegend";function Me(e){const{hoverWhenOpen:t=!1}=e??{},[r,n]=p.useState(null),[s,o]=p.useState(null),a=p.useCallback(d=>{o(d),n(d)},[]),c=p.useCallback(()=>{n(null)},[]),i=p.useCallback(d=>{const m={onClick:()=>a(d)};return t&&(m.onPointerEnter=u=>{u.pointerType==="mouse"&&r!=null&&a(d)}),m},[t,a,r]);return{activeItem:r,anchorItem:s,showItem:a,close:c,getInteractionProps:i}}const we=j.Popover,H=j.PopoverAnchor;H.displayName="MapPopoverAnchor";const U=p.forwardRef(({className:e,side:t="top",sideOffset:r=4,dataHook:n,trackingEl:s,trackingLabel:o,...a},c)=>l.jsx(j.PopoverContent,{ref:c,className:g.cn("w-auto max-w-68.25 p-3 data-[state=closed]:animate-none data-[state=closed]:opacity-0",e),"data-slot":"map-popover-content","data-tracking-el":s||"map-popover","data-tracking-label":o,dataHook:n,side:t,sideOffset:r,onCloseAutoFocus:i=>i.preventDefault(),onOpenAutoFocus:i=>i.preventDefault(),...a}));U.displayName="MapPopoverContent";exports.MAP_STYLES=A;exports.MapClusterPin=V;exports.MapControlButton=q;exports.MapEmpty=K;exports.MapErrorState=G;exports.MapGridPin=C;exports.MapLegend=Y;exports.MapLegendItem=W;exports.MapLoadingState=z;exports.MapLocationPin=F;exports.MapPopover=we;exports.MapPopoverAnchor=H;exports.MapPopoverContent=U;exports.MapTypeId=ie;exports.clusterPinHexColors=ve;exports.createClusterPinElement=ke;exports.createClusterPinSvg=N;exports.mapGridPinColorMap=y;exports.resolveClusterPinColors=he;exports.useMapPopoverClick=Me;exports.useMapStyles=ge;
package/dist/map.d.ts CHANGED
@@ -385,6 +385,64 @@ interface MapErrorStateProps extends React.ComponentProps<"div"> {
385
385
  * Pass `onRetry` to render a retry button; omit it to hide the button entirely.
386
386
  */
387
387
  declare const MapErrorState: React.ForwardRefExoticComponent<Omit<MapErrorStateProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
388
+ /**
389
+ * Props for the MapEmpty component.
390
+ */
391
+ interface MapEmptyProps extends Omit<React.ComponentProps<"div">, "children" | "title"> {
392
+ /**
393
+ * Required data-hook attribute for automated testing. The parts derive
394
+ * theirs from it: `-icon`, `-message`.
395
+ * @example "rankings-grid-map-empty"
396
+ */
397
+ dataHook: string;
398
+ /**
399
+ * The glyph on the surface. The component sizes it.
400
+ * @default <Map strokeWidth={2} />
401
+ */
402
+ icon?: React.ReactNode;
403
+ /**
404
+ * The one line on the surface. Domain copy — "No ranking data yet" rather
405
+ * than a bare "No data" — with no trailing period.
406
+ * @default "No data yet"
407
+ */
408
+ message?: string;
409
+ /** Analytics element identifier */
410
+ trackingEl?: string;
411
+ /** Analytics label */
412
+ trackingLabel?: string;
413
+ }
414
+ /**
415
+ * A map surface with nothing to plot — the map's reserved box filled with a
416
+ * muted surface, a bare icon, and one quiet line.
417
+ *
418
+ * The rule this exists to enforce: **a map never renders pinless with no
419
+ * message.** An empty map and a broken map look identical, so silence here
420
+ * reads as a fault every time.
421
+ *
422
+ * Unlike its `MapLoadingState` and `MapErrorState` siblings it does not draw
423
+ * the decorative map background. Those two are telling the reader that a real
424
+ * map is coming or has failed, so a map-shaped backdrop is honest; here there
425
+ * is nothing to show, and a pinless map behind the message would recreate the
426
+ * exact confusion the message is there to clear up.
427
+ *
428
+ * The surroundings must agree: KPI tiles beside an empty map show em-dashes and
429
+ * drop their trend badges.
430
+ *
431
+ * @example
432
+ * ```tsx
433
+ * <div className="h-[500px]">
434
+ * {hasRuns ? (
435
+ * <GridMap dataHook="rankings-grid-map" {...gridMap} />
436
+ * ) : (
437
+ * <MapEmpty
438
+ * dataHook="rankings-grid-map-empty"
439
+ * message={t("rankings.map.empty")}
440
+ * />
441
+ * )}
442
+ * </div>
443
+ * ```
444
+ */
445
+ declare const MapEmpty: React.ForwardRefExoticComponent<Omit<MapEmptyProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
388
446
  /**
389
447
  * Props for the MapLegendItem component.
390
448
  */
@@ -558,6 +616,6 @@ interface MapPopoverContentProps extends PopoverContentProps {
558
616
  * with `MapPopoverAnchor` and {@link useMapPopoverClick}.
559
617
  */
560
618
  declare const MapPopoverContent: React.ForwardRefExoticComponent<Omit<MapPopoverContentProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
561
- export { MAP_STYLES, MapTypeId, MapLocationPin, MapGridPin, MapClusterPin, mapGridPinColorMap, clusterPinHexColors, resolveClusterPinColors, createClusterPinSvg, createClusterPinElement, MapControlButton, MapLoadingState, MapErrorState, MapLegend, MapLegendItem, MapPopover, MapPopoverAnchor, MapPopoverContent, useMapStyles, useMapPopoverClick, };
562
- export type { MapStyleVariant, MapStyleRule, MapTypeIdValue, ResolvedVariant as MapPinVariant, MapLocationPinProps, MapGridPinProps, MapGridPinVariant, MapClusterPinProps, ClusterPinSegment, CreateClusterPinElementOptions, MapControlButtonProps, MapLoadingStateProps, MapErrorStateProps, MapLegendProps, MapLegendItemProps, MapPopoverProps, MapPopoverAnchorProps, MapPopoverContentProps, UseMapPopoverClickOptions, UseMapPopoverClickReturn, MapPinInteractionProps, };
619
+ export { MAP_STYLES, MapTypeId, MapLocationPin, MapGridPin, MapClusterPin, mapGridPinColorMap, clusterPinHexColors, resolveClusterPinColors, createClusterPinSvg, createClusterPinElement, MapControlButton, MapLoadingState, MapErrorState, MapEmpty, MapLegend, MapLegendItem, MapPopover, MapPopoverAnchor, MapPopoverContent, useMapStyles, useMapPopoverClick, };
620
+ export type { MapStyleVariant, MapStyleRule, MapTypeIdValue, ResolvedVariant as MapPinVariant, MapLocationPinProps, MapGridPinProps, MapGridPinVariant, MapClusterPinProps, ClusterPinSegment, CreateClusterPinElementOptions, MapControlButtonProps, MapLoadingStateProps, MapErrorStateProps, MapEmptyProps, MapLegendProps, MapLegendItemProps, MapPopoverProps, MapPopoverAnchorProps, MapPopoverContentProps, UseMapPopoverClickOptions, UseMapPopoverClickReturn, MapPinInteractionProps, };
563
621
  //# sourceMappingURL=map.d.ts.map
package/dist/map.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"map.d.ts","sourceRoot":"","sources":["../../src/components/map.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAU/B,OAAO,EACL,OAAO,EAGP,KAAK,YAAY,EACjB,KAAK,kBAAkB,EACvB,KAAK,mBAAmB,EACzB,MAAM,oCAAoC,CAAC;AAM5C;;;;GAIG;AACH,QAAA,MAAM,SAAS;IACb,4BAA4B;;IAE5B,gFAAgF;;CAExE,CAAC;AAEX;;GAEG;AACH,KAAK,cAAc,GAAG,CAAC,OAAO,SAAS,CAAC,CAAC,MAAM,OAAO,SAAS,CAAC,CAAC;AAMjE;;;;GAIG;AACH,KAAK,eAAe,GAAG,SAAS,GAAG,OAAO,CAAC;AAE3C;;;;GAIG;AACH,KAAK,YAAY,GAAG;IAClB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC,EAAE,CAAC;CAC5C,CAAC;AA8DF;;;;;;;GAOG;AACH,QAAA,MAAM,UAAU,EAAE,MAAM,CACtB,eAAe,EACf;IAAE,KAAK,EAAE,YAAY,EAAE,CAAC;I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kB,EAClB,mBAAmB,EACnB,uBAAuB,EACvB,mBAAmB,EACnB,uBAAuB,EACvB,gBAAgB,EAChB,eAAe,EACf,aAAa,EACb,SAAS,EACT,aAAa,EACb,UAAU,EACV,gBAAgB,EAChB,iBAAiB,EACjB,YAAY,EACZ,kBAAkB,GACnB,CAAC;AAEF,YAAY,EACV,eAAe,EACf,YAAY,EACZ,cAAc,EACd,eAAe,IAAI,aAAa,EAChC,mBAAmB,EACnB,eAAe,EACf,iBAAiB,EACjB,kBAAkB,EAClB,iBAAiB,EACjB,8BAA8B,EAC9B,qBAAqB,EACrB,oBAAoB,EACpB,kBAAkB,EAClB,cAAc,EACd,kBAAkB,EAClB,eAAe,EACf,qBAAqB,EACrB,sBAAsB,EACtB,yBAAyB,EACzB,wBAAwB,EACxB,sBAAsB,GACvB,CAAC"}
1
+ {"version":3,"file":"map.d.ts","sourceRoot":"","sources":["../../src/components/map.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAe/B,OAAO,EACL,OAAO,EAGP,KAAK,YAAY,EACjB,KAAK,kBAAkB,EACvB,KAAK,mBAAmB,EACzB,MAAM,oCAAoC,CAAC;AAO5C;;;;GAIG;AACH,QAAA,MAAM,SAAS;IACb,4BAA4B;;IAE5B,gFAAgF;;CAExE,CAAC;AAEX;;GAEG;AACH,KAAK,cAAc,GAAG,CAAC,OAAO,SAAS,CAAC,CAAC,MAAM,OAAO,SAAS,CAAC,CAAC;AAMjE;;;;GAIG;AACH,KAAK,eAAe,GAAG,SAAS,GAAG,OAAO,CAAC;AAE3C;;;;GAIG;AACH,KAAK,YAAY,GAAG;IAClB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC,EAAE,CAAC;CAC5C,CAAC;AA8DF;;;;;;;GAOG;AACH,QAAA,MAAM,UAAU,EAAE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