@brandlab-digital/site-next 3.20.0 → 4.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 (345) hide show
  1. package/README.md +24 -0
  2. package/dist/contact/client.d.ts +2 -0
  3. package/dist/contact/client.d.ts.map +1 -1
  4. package/dist/contact/client.js +6 -0
  5. package/dist/contact/client.js.map +1 -1
  6. package/dist/contact/form-client.d.ts.map +1 -1
  7. package/dist/contact/form-client.js +5 -1
  8. package/dist/contact/form-client.js.map +1 -1
  9. package/dist/contact/route-handler.d.ts +5 -0
  10. package/dist/contact/route-handler.d.ts.map +1 -1
  11. package/dist/contact/route-handler.js +1 -0
  12. package/dist/contact/route-handler.js.map +1 -1
  13. package/dist/contact/server-entry.d.ts +1 -0
  14. package/dist/contact/server-entry.d.ts.map +1 -1
  15. package/dist/contact/server-entry.js +1 -0
  16. package/dist/contact/server-entry.js.map +1 -1
  17. package/dist/contact/server.d.ts +8 -0
  18. package/dist/contact/server.d.ts.map +1 -1
  19. package/dist/contact/server.js +24 -0
  20. package/dist/contact/server.js.map +1 -1
  21. package/dist/contact/shared.d.ts +2 -0
  22. package/dist/contact/shared.d.ts.map +1 -1
  23. package/dist/contact/shared.js +2 -0
  24. package/dist/contact/shared.js.map +1 -1
  25. package/dist/contact/spam-filter.d.ts +65 -0
  26. package/dist/contact/spam-filter.d.ts.map +1 -0
  27. package/dist/contact/spam-filter.js +347 -0
  28. package/dist/contact/spam-filter.js.map +1 -0
  29. package/dist/contact/spam-places.d.ts +8 -0
  30. package/dist/contact/spam-places.d.ts.map +1 -0
  31. package/dist/contact/spam-places.js +8 -0
  32. package/dist/contact/spam-places.js.map +1 -0
  33. package/dist/instrumentation-client.d.ts +1 -1
  34. package/dist/instrumentation-client.js +1 -1
  35. package/dist/instrumentation-client.js.map +1 -1
  36. package/dist/navigation/index.d.ts +2 -3
  37. package/dist/navigation/index.d.ts.map +1 -1
  38. package/dist/navigation/index.js +2 -3
  39. package/dist/navigation/index.js.map +1 -1
  40. package/dist/next-config.d.ts +1 -17
  41. package/dist/next-config.d.ts.map +1 -1
  42. package/dist/next-config.js +2 -33
  43. package/dist/next-config.js.map +1 -1
  44. package/package.json +4 -33
  45. package/dist/ui-kit/brandlab-skin.d.ts +0 -112
  46. package/dist/ui-kit/brandlab-skin.d.ts.map +0 -1
  47. package/dist/ui-kit/brandlab-skin.js +0 -2
  48. package/dist/ui-kit/brandlab-skin.js.map +0 -1
  49. package/dist/ui-kit/form/copy.d.ts +0 -3
  50. package/dist/ui-kit/form/copy.d.ts.map +0 -1
  51. package/dist/ui-kit/form/copy.js +0 -5
  52. package/dist/ui-kit/form/copy.js.map +0 -1
  53. package/dist/ui-kit/form/dialog.d.ts +0 -24
  54. package/dist/ui-kit/form/dialog.d.ts.map +0 -1
  55. package/dist/ui-kit/form/dialog.js +0 -17
  56. package/dist/ui-kit/form/dialog.js.map +0 -1
  57. package/dist/ui-kit/form/field.d.ts +0 -30
  58. package/dist/ui-kit/form/field.d.ts.map +0 -1
  59. package/dist/ui-kit/form/field.js +0 -11
  60. package/dist/ui-kit/form/field.js.map +0 -1
  61. package/dist/ui-kit/form/index.d.ts +0 -7
  62. package/dist/ui-kit/form/index.d.ts.map +0 -1
  63. package/dist/ui-kit/form/index.js +0 -7
  64. package/dist/ui-kit/form/index.js.map +0 -1
  65. package/dist/ui-kit/form/photo-upload.d.ts +0 -40
  66. package/dist/ui-kit/form/photo-upload.d.ts.map +0 -1
  67. package/dist/ui-kit/form/photo-upload.js +0 -19
  68. package/dist/ui-kit/form/photo-upload.js.map +0 -1
  69. package/dist/ui-kit/form/quote-dialog.d.ts +0 -15
  70. package/dist/ui-kit/form/quote-dialog.d.ts.map +0 -1
  71. package/dist/ui-kit/form/quote-dialog.js +0 -68
  72. package/dist/ui-kit/form/quote-dialog.js.map +0 -1
  73. package/dist/ui-kit/form/quote-form.d.ts +0 -172
  74. package/dist/ui-kit/form/quote-form.d.ts.map +0 -1
  75. package/dist/ui-kit/form/quote-form.js +0 -238
  76. package/dist/ui-kit/form/quote-form.js.map +0 -1
  77. package/dist/ui-kit/form/thank-you.d.ts +0 -40
  78. package/dist/ui-kit/form/thank-you.d.ts.map +0 -1
  79. package/dist/ui-kit/form/thank-you.js +0 -36
  80. package/dist/ui-kit/form/thank-you.js.map +0 -1
  81. package/dist/ui-kit/icon-glyphs.d.ts +0 -41
  82. package/dist/ui-kit/icon-glyphs.d.ts.map +0 -1
  83. package/dist/ui-kit/icon-glyphs.js +0 -138
  84. package/dist/ui-kit/icon-glyphs.js.map +0 -1
  85. package/dist/ui-kit/icon-sprite.d.ts +0 -19
  86. package/dist/ui-kit/icon-sprite.d.ts.map +0 -1
  87. package/dist/ui-kit/icon-sprite.js +0 -44
  88. package/dist/ui-kit/icon-sprite.js.map +0 -1
  89. package/dist/ui-kit/icons.d.ts +0 -50
  90. package/dist/ui-kit/icons.d.ts.map +0 -1
  91. package/dist/ui-kit/icons.js +0 -55
  92. package/dist/ui-kit/icons.js.map +0 -1
  93. package/dist/ui-kit/prefetch.d.ts +0 -59
  94. package/dist/ui-kit/prefetch.d.ts.map +0 -1
  95. package/dist/ui-kit/prefetch.js +0 -63
  96. package/dist/ui-kit/prefetch.js.map +0 -1
  97. package/dist/ui-kit/primitives/badge.d.ts +0 -25
  98. package/dist/ui-kit/primitives/badge.d.ts.map +0 -1
  99. package/dist/ui-kit/primitives/badge.js +0 -21
  100. package/dist/ui-kit/primitives/badge.js.map +0 -1
  101. package/dist/ui-kit/primitives/breadcrumbs.d.ts +0 -27
  102. package/dist/ui-kit/primitives/breadcrumbs.d.ts.map +0 -1
  103. package/dist/ui-kit/primitives/breadcrumbs.js +0 -40
  104. package/dist/ui-kit/primitives/breadcrumbs.js.map +0 -1
  105. package/dist/ui-kit/primitives/button.d.ts +0 -32
  106. package/dist/ui-kit/primitives/button.d.ts.map +0 -1
  107. package/dist/ui-kit/primitives/button.js +0 -8
  108. package/dist/ui-kit/primitives/button.js.map +0 -1
  109. package/dist/ui-kit/primitives/card.d.ts +0 -40
  110. package/dist/ui-kit/primitives/card.d.ts.map +0 -1
  111. package/dist/ui-kit/primitives/card.js +0 -8
  112. package/dist/ui-kit/primitives/card.js.map +0 -1
  113. package/dist/ui-kit/primitives/index.d.ts +0 -16
  114. package/dist/ui-kit/primitives/index.d.ts.map +0 -1
  115. package/dist/ui-kit/primitives/index.js +0 -16
  116. package/dist/ui-kit/primitives/index.js.map +0 -1
  117. package/dist/ui-kit/primitives/layout.d.ts +0 -85
  118. package/dist/ui-kit/primitives/layout.d.ts.map +0 -1
  119. package/dist/ui-kit/primitives/layout.js +0 -52
  120. package/dist/ui-kit/primitives/layout.js.map +0 -1
  121. package/dist/ui-kit/primitives/links.d.ts +0 -74
  122. package/dist/ui-kit/primitives/links.d.ts.map +0 -1
  123. package/dist/ui-kit/primitives/links.js +0 -41
  124. package/dist/ui-kit/primitives/links.js.map +0 -1
  125. package/dist/ui-kit/primitives/lists.d.ts +0 -51
  126. package/dist/ui-kit/primitives/lists.d.ts.map +0 -1
  127. package/dist/ui-kit/primitives/lists.js +0 -34
  128. package/dist/ui-kit/primitives/lists.js.map +0 -1
  129. package/dist/ui-kit/primitives/media-frame.d.ts +0 -33
  130. package/dist/ui-kit/primitives/media-frame.d.ts.map +0 -1
  131. package/dist/ui-kit/primitives/media-frame.js +0 -61
  132. package/dist/ui-kit/primitives/media-frame.js.map +0 -1
  133. package/dist/ui-kit/primitives/media.d.ts +0 -40
  134. package/dist/ui-kit/primitives/media.d.ts.map +0 -1
  135. package/dist/ui-kit/primitives/media.js +0 -9
  136. package/dist/ui-kit/primitives/media.js.map +0 -1
  137. package/dist/ui-kit/primitives/quote-button.d.ts +0 -46
  138. package/dist/ui-kit/primitives/quote-button.d.ts.map +0 -1
  139. package/dist/ui-kit/primitives/quote-button.js +0 -38
  140. package/dist/ui-kit/primitives/quote-button.js.map +0 -1
  141. package/dist/ui-kit/primitives/stat.d.ts +0 -25
  142. package/dist/ui-kit/primitives/stat.d.ts.map +0 -1
  143. package/dist/ui-kit/primitives/stat.js +0 -7
  144. package/dist/ui-kit/primitives/stat.js.map +0 -1
  145. package/dist/ui-kit/repeated-slots.d.ts +0 -153
  146. package/dist/ui-kit/repeated-slots.d.ts.map +0 -1
  147. package/dist/ui-kit/repeated-slots.js +0 -100
  148. package/dist/ui-kit/repeated-slots.js.map +0 -1
  149. package/dist/ui-kit/sections/accordion.d.ts +0 -28
  150. package/dist/ui-kit/sections/accordion.d.ts.map +0 -1
  151. package/dist/ui-kit/sections/accordion.js +0 -14
  152. package/dist/ui-kit/sections/accordion.js.map +0 -1
  153. package/dist/ui-kit/sections/area-map.d.ts +0 -64
  154. package/dist/ui-kit/sections/area-map.d.ts.map +0 -1
  155. package/dist/ui-kit/sections/area-map.js +0 -146
  156. package/dist/ui-kit/sections/area-map.js.map +0 -1
  157. package/dist/ui-kit/sections/before-after.d.ts +0 -59
  158. package/dist/ui-kit/sections/before-after.d.ts.map +0 -1
  159. package/dist/ui-kit/sections/before-after.js +0 -42
  160. package/dist/ui-kit/sections/before-after.js.map +0 -1
  161. package/dist/ui-kit/sections/contact-block.d.ts +0 -77
  162. package/dist/ui-kit/sections/contact-block.d.ts.map +0 -1
  163. package/dist/ui-kit/sections/contact-block.js +0 -23
  164. package/dist/ui-kit/sections/contact-block.js.map +0 -1
  165. package/dist/ui-kit/sections/council-rules.d.ts +0 -64
  166. package/dist/ui-kit/sections/council-rules.d.ts.map +0 -1
  167. package/dist/ui-kit/sections/council-rules.js +0 -46
  168. package/dist/ui-kit/sections/council-rules.js.map +0 -1
  169. package/dist/ui-kit/sections/coverage.d.ts +0 -53
  170. package/dist/ui-kit/sections/coverage.d.ts.map +0 -1
  171. package/dist/ui-kit/sections/coverage.js +0 -57
  172. package/dist/ui-kit/sections/coverage.js.map +0 -1
  173. package/dist/ui-kit/sections/cta-band.d.ts +0 -67
  174. package/dist/ui-kit/sections/cta-band.d.ts.map +0 -1
  175. package/dist/ui-kit/sections/cta-band.js +0 -11
  176. package/dist/ui-kit/sections/cta-band.js.map +0 -1
  177. package/dist/ui-kit/sections/emergency-band.d.ts +0 -60
  178. package/dist/ui-kit/sections/emergency-band.d.ts.map +0 -1
  179. package/dist/ui-kit/sections/emergency-band.js +0 -43
  180. package/dist/ui-kit/sections/emergency-band.js.map +0 -1
  181. package/dist/ui-kit/sections/faqs.d.ts +0 -46
  182. package/dist/ui-kit/sections/faqs.d.ts.map +0 -1
  183. package/dist/ui-kit/sections/faqs.js +0 -39
  184. package/dist/ui-kit/sections/faqs.js.map +0 -1
  185. package/dist/ui-kit/sections/gallery.d.ts +0 -60
  186. package/dist/ui-kit/sections/gallery.d.ts.map +0 -1
  187. package/dist/ui-kit/sections/gallery.js +0 -39
  188. package/dist/ui-kit/sections/gallery.js.map +0 -1
  189. package/dist/ui-kit/sections/hero.d.ts +0 -168
  190. package/dist/ui-kit/sections/hero.d.ts.map +0 -1
  191. package/dist/ui-kit/sections/hero.js +0 -147
  192. package/dist/ui-kit/sections/hero.js.map +0 -1
  193. package/dist/ui-kit/sections/index.d.ts +0 -29
  194. package/dist/ui-kit/sections/index.d.ts.map +0 -1
  195. package/dist/ui-kit/sections/index.js +0 -29
  196. package/dist/ui-kit/sections/index.js.map +0 -1
  197. package/dist/ui-kit/sections/licences.d.ts +0 -95
  198. package/dist/ui-kit/sections/licences.d.ts.map +0 -1
  199. package/dist/ui-kit/sections/licences.js +0 -72
  200. package/dist/ui-kit/sections/licences.js.map +0 -1
  201. package/dist/ui-kit/sections/local-facts.d.ts +0 -107
  202. package/dist/ui-kit/sections/local-facts.d.ts.map +0 -1
  203. package/dist/ui-kit/sections/local-facts.js +0 -44
  204. package/dist/ui-kit/sections/local-facts.js.map +0 -1
  205. package/dist/ui-kit/sections/nearby-areas.d.ts +0 -50
  206. package/dist/ui-kit/sections/nearby-areas.d.ts.map +0 -1
  207. package/dist/ui-kit/sections/nearby-areas.js +0 -49
  208. package/dist/ui-kit/sections/nearby-areas.js.map +0 -1
  209. package/dist/ui-kit/sections/nearby-jobs.d.ts +0 -84
  210. package/dist/ui-kit/sections/nearby-jobs.d.ts.map +0 -1
  211. package/dist/ui-kit/sections/nearby-jobs.js +0 -72
  212. package/dist/ui-kit/sections/nearby-jobs.js.map +0 -1
  213. package/dist/ui-kit/sections/page-header.d.ts +0 -29
  214. package/dist/ui-kit/sections/page-header.d.ts.map +0 -1
  215. package/dist/ui-kit/sections/page-header.js +0 -9
  216. package/dist/ui-kit/sections/page-header.js.map +0 -1
  217. package/dist/ui-kit/sections/price-guide.d.ts +0 -59
  218. package/dist/ui-kit/sections/price-guide.d.ts.map +0 -1
  219. package/dist/ui-kit/sections/price-guide.js +0 -28
  220. package/dist/ui-kit/sections/price-guide.js.map +0 -1
  221. package/dist/ui-kit/sections/price-table.d.ts +0 -42
  222. package/dist/ui-kit/sections/price-table.d.ts.map +0 -1
  223. package/dist/ui-kit/sections/price-table.js +0 -29
  224. package/dist/ui-kit/sections/price-table.js.map +0 -1
  225. package/dist/ui-kit/sections/projects.d.ts +0 -79
  226. package/dist/ui-kit/sections/projects.d.ts.map +0 -1
  227. package/dist/ui-kit/sections/projects.js +0 -69
  228. package/dist/ui-kit/sections/projects.js.map +0 -1
  229. package/dist/ui-kit/sections/proof-strip.d.ts +0 -68
  230. package/dist/ui-kit/sections/proof-strip.d.ts.map +0 -1
  231. package/dist/ui-kit/sections/proof-strip.js +0 -27
  232. package/dist/ui-kit/sections/proof-strip.js.map +0 -1
  233. package/dist/ui-kit/sections/quote-checklist.d.ts +0 -43
  234. package/dist/ui-kit/sections/quote-checklist.d.ts.map +0 -1
  235. package/dist/ui-kit/sections/quote-checklist.js +0 -19
  236. package/dist/ui-kit/sections/quote-checklist.js.map +0 -1
  237. package/dist/ui-kit/sections/rating-chip.d.ts +0 -35
  238. package/dist/ui-kit/sections/rating-chip.d.ts.map +0 -1
  239. package/dist/ui-kit/sections/rating-chip.js +0 -21
  240. package/dist/ui-kit/sections/rating-chip.js.map +0 -1
  241. package/dist/ui-kit/sections/related-services.d.ts +0 -41
  242. package/dist/ui-kit/sections/related-services.d.ts.map +0 -1
  243. package/dist/ui-kit/sections/related-services.js +0 -52
  244. package/dist/ui-kit/sections/related-services.js.map +0 -1
  245. package/dist/ui-kit/sections/reviews-band.d.ts +0 -124
  246. package/dist/ui-kit/sections/reviews-band.d.ts.map +0 -1
  247. package/dist/ui-kit/sections/reviews-band.js +0 -115
  248. package/dist/ui-kit/sections/reviews-band.js.map +0 -1
  249. package/dist/ui-kit/sections/section-sequence.d.ts +0 -41
  250. package/dist/ui-kit/sections/section-sequence.d.ts.map +0 -1
  251. package/dist/ui-kit/sections/section-sequence.js +0 -36
  252. package/dist/ui-kit/sections/section-sequence.js.map +0 -1
  253. package/dist/ui-kit/sections/services-grid.d.ts +0 -82
  254. package/dist/ui-kit/sections/services-grid.d.ts.map +0 -1
  255. package/dist/ui-kit/sections/services-grid.js +0 -90
  256. package/dist/ui-kit/sections/services-grid.js.map +0 -1
  257. package/dist/ui-kit/sections/signature-section.d.ts +0 -42
  258. package/dist/ui-kit/sections/signature-section.d.ts.map +0 -1
  259. package/dist/ui-kit/sections/signature-section.js +0 -14
  260. package/dist/ui-kit/sections/signature-section.js.map +0 -1
  261. package/dist/ui-kit/sections/site-footer-columns.d.ts +0 -12
  262. package/dist/ui-kit/sections/site-footer-columns.d.ts.map +0 -1
  263. package/dist/ui-kit/sections/site-footer-columns.js +0 -63
  264. package/dist/ui-kit/sections/site-footer-columns.js.map +0 -1
  265. package/dist/ui-kit/sections/site-footer.d.ts +0 -66
  266. package/dist/ui-kit/sections/site-footer.d.ts.map +0 -1
  267. package/dist/ui-kit/sections/site-footer.js +0 -49
  268. package/dist/ui-kit/sections/site-footer.js.map +0 -1
  269. package/dist/ui-kit/sections/work-photos.d.ts +0 -15
  270. package/dist/ui-kit/sections/work-photos.d.ts.map +0 -1
  271. package/dist/ui-kit/sections/work-photos.js +0 -24
  272. package/dist/ui-kit/sections/work-photos.js.map +0 -1
  273. package/dist/ui-kit/shell/back-to-top-client.d.ts +0 -9
  274. package/dist/ui-kit/shell/back-to-top-client.d.ts.map +0 -1
  275. package/dist/ui-kit/shell/back-to-top-client.js +0 -8
  276. package/dist/ui-kit/shell/back-to-top-client.js.map +0 -1
  277. package/dist/ui-kit/shell/back-to-top.d.ts +0 -13
  278. package/dist/ui-kit/shell/back-to-top.d.ts.map +0 -1
  279. package/dist/ui-kit/shell/back-to-top.js +0 -14
  280. package/dist/ui-kit/shell/back-to-top.js.map +0 -1
  281. package/dist/ui-kit/shell/call-bar-client.d.ts +0 -8
  282. package/dist/ui-kit/shell/call-bar-client.d.ts.map +0 -1
  283. package/dist/ui-kit/shell/call-bar-client.js +0 -13
  284. package/dist/ui-kit/shell/call-bar-client.js.map +0 -1
  285. package/dist/ui-kit/shell/current-link.d.ts +0 -45
  286. package/dist/ui-kit/shell/current-link.d.ts.map +0 -1
  287. package/dist/ui-kit/shell/current-link.js +0 -54
  288. package/dist/ui-kit/shell/current-link.js.map +0 -1
  289. package/dist/ui-kit/shell/drawer-client.d.ts +0 -22
  290. package/dist/ui-kit/shell/drawer-client.d.ts.map +0 -1
  291. package/dist/ui-kit/shell/drawer-client.js +0 -70
  292. package/dist/ui-kit/shell/drawer-client.js.map +0 -1
  293. package/dist/ui-kit/shell/header-client.d.ts +0 -44
  294. package/dist/ui-kit/shell/header-client.d.ts.map +0 -1
  295. package/dist/ui-kit/shell/header-client.js +0 -59
  296. package/dist/ui-kit/shell/header-client.js.map +0 -1
  297. package/dist/ui-kit/shell/index.d.ts +0 -7
  298. package/dist/ui-kit/shell/index.d.ts.map +0 -1
  299. package/dist/ui-kit/shell/index.js +0 -7
  300. package/dist/ui-kit/shell/index.js.map +0 -1
  301. package/dist/ui-kit/shell/intent-prefetch.d.ts +0 -4
  302. package/dist/ui-kit/shell/intent-prefetch.d.ts.map +0 -1
  303. package/dist/ui-kit/shell/intent-prefetch.js +0 -62
  304. package/dist/ui-kit/shell/intent-prefetch.js.map +0 -1
  305. package/dist/ui-kit/shell/mobile-call-bar.d.ts +0 -25
  306. package/dist/ui-kit/shell/mobile-call-bar.d.ts.map +0 -1
  307. package/dist/ui-kit/shell/mobile-call-bar.js +0 -21
  308. package/dist/ui-kit/shell/mobile-call-bar.js.map +0 -1
  309. package/dist/ui-kit/shell/mobile-drawer.d.ts +0 -41
  310. package/dist/ui-kit/shell/mobile-drawer.d.ts.map +0 -1
  311. package/dist/ui-kit/shell/mobile-drawer.js +0 -41
  312. package/dist/ui-kit/shell/mobile-drawer.js.map +0 -1
  313. package/dist/ui-kit/shell/shell-context.d.ts +0 -3
  314. package/dist/ui-kit/shell/shell-context.d.ts.map +0 -1
  315. package/dist/ui-kit/shell/shell-context.js +0 -5
  316. package/dist/ui-kit/shell/shell-context.js.map +0 -1
  317. package/dist/ui-kit/shell/shell-quote.d.ts +0 -10
  318. package/dist/ui-kit/shell/shell-quote.d.ts.map +0 -1
  319. package/dist/ui-kit/shell/shell-quote.js +0 -13
  320. package/dist/ui-kit/shell/shell-quote.js.map +0 -1
  321. package/dist/ui-kit/shell/site-header.d.ts +0 -55
  322. package/dist/ui-kit/shell/site-header.d.ts.map +0 -1
  323. package/dist/ui-kit/shell/site-header.js +0 -35
  324. package/dist/ui-kit/shell/site-header.js.map +0 -1
  325. package/dist/ui-kit/shell/social-links.d.ts +0 -7
  326. package/dist/ui-kit/shell/social-links.d.ts.map +0 -1
  327. package/dist/ui-kit/shell/social-links.js +0 -12
  328. package/dist/ui-kit/shell/social-links.js.map +0 -1
  329. package/dist/ui-kit/shell/utility-bar.d.ts +0 -33
  330. package/dist/ui-kit/shell/utility-bar.d.ts.map +0 -1
  331. package/dist/ui-kit/shell/utility-bar.js +0 -15
  332. package/dist/ui-kit/shell/utility-bar.js.map +0 -1
  333. package/dist/ui-kit/skin-index.d.ts +0 -4
  334. package/dist/ui-kit/skin-index.d.ts.map +0 -1
  335. package/dist/ui-kit/skin-index.js +0 -3
  336. package/dist/ui-kit/skin-index.js.map +0 -1
  337. package/dist/ui-kit/skin.d.ts +0 -65
  338. package/dist/ui-kit/skin.d.ts.map +0 -1
  339. package/dist/ui-kit/skin.js +0 -60
  340. package/dist/ui-kit/skin.js.map +0 -1
  341. package/dist/ui-kit/structure.css +0 -2546
  342. package/dist/ui-kit/types.d.ts +0 -27
  343. package/dist/ui-kit/types.d.ts.map +0 -1
  344. package/dist/ui-kit/types.js +0 -6
  345. package/dist/ui-kit/types.js.map +0 -1
@@ -1,153 +0,0 @@
1
- /**
2
- * The repeated slots of every shared component (3.14.0): the parts a component renders once per entry of a list in
3
- * its data. They carry their `data-slot` hook and never a class, so a long class string is not repeated in the HTML and
4
- * the RSC payload for every link, review, star, card or chip. A site styles them once in `src/site/skin.css`:
5
- *
6
- * ```css
7
- * @layer components {
8
- * [data-bl="footer"] [data-slot="link"] { @apply text-sm text-white/80 hover:text-white; }
9
- * [data-bl="header"] [data-slot="list"] [data-slot="panelLink"] { padding: 0.5rem 0.75rem; }
10
- * }
11
- * ```
12
- *
13
- * `scope` is the selector that holds the repeated slots without reaching a nested component that reuses a slot name
14
- * (the drawer sits inside the header; the rating chip inside the reviews band uses `stars` too).
15
- * `repeatedSlotSelector()` joins the two. Pure data: safe to import anywhere.
16
- */
17
- export declare const REPEATED_SLOTS: {
18
- readonly siteHeader: {
19
- readonly scope: "[data-bl=\"header\"] [data-slot=\"list\"]";
20
- readonly slots: readonly ["item", "itemRow", "link", "trigger", "panel", "panelBody", "panelList", "panelGroup", "panelHeading", "panelLink", "panelLabel", "panelText", "featured", "featuredMedia", "featuredLabel", "featuredText"];
21
- };
22
- readonly mobileDrawer: {
23
- readonly scope: "[data-bl=\"drawer\"]";
24
- readonly slots: readonly ["group", "groupTrigger", "groupLinks", "groupLink", "link", "socialLink"];
25
- };
26
- readonly utilityBar: {
27
- readonly scope: "[data-bl=\"utility\"]";
28
- readonly slots: readonly ["item", "licence", "socialLink"];
29
- };
30
- readonly siteFooter: {
31
- readonly scope: "[data-bl=\"footer\"]";
32
- readonly slots: readonly ["licenceLink", "socialLink", "column", "heading", "toggle", "list", "link", "policyLink"];
33
- };
34
- readonly accordion: {
35
- readonly scope: "[data-bl=\"accordion\"]";
36
- readonly slots: readonly ["item", "summary", "label", "marker", "content"];
37
- };
38
- readonly faqs: {
39
- readonly scope: "[data-bl-section=\"faqs\"] [data-slot=\"columns\"]";
40
- readonly slots: readonly ["column", "group", "subheading", "accordion", "item", "summary", "label", "marker", "content"];
41
- /** The nested accordion's root is its own component: `data-bl="accordion"`, not a `data-slot`. */
42
- readonly hooks: {
43
- readonly accordion: "[data-bl=\"accordion\"]";
44
- };
45
- };
46
- readonly priceTable: {
47
- readonly scope: "[data-bl=\"price-table\"]";
48
- readonly slots: readonly ["row", "job", "cell", "label", "range", "unit", "gst", "parts", "part", "includes", "excludes"];
49
- };
50
- readonly priceGuide: {
51
- readonly scope: "[data-bl-section=\"price-guide\"]";
52
- readonly slots: readonly ["row", "job", "cell", "label", "range", "unit", "gst", "parts", "part", "includes", "excludes", "card", "title", "figures", "band", "factor", "name", "effect", "detail"];
53
- };
54
- readonly proofStrip: {
55
- readonly scope: "[data-bl-section=\"proof-strip\"] [data-slot=\"list\"]";
56
- readonly slots: readonly ["item", "link", "icon", "stars", "value", "label", "linkLabel"];
57
- };
58
- readonly reviewsBand: {
59
- readonly scope: "[data-bl-section=\"reviews\"] [data-slot=\"list\"]";
60
- readonly slots: readonly ["item", "stars", "quote", "more", "author", "avatar", "name", "date"];
61
- };
62
- readonly contactBlock: {
63
- readonly scope: "[data-bl-section=\"contact\"] [data-slot=\"details\"]";
64
- readonly slots: readonly ["line", "note"];
65
- };
66
- readonly servicesGrid: {
67
- readonly scope: "[data-bl-section=\"services\"] [data-slot=\"list\"]";
68
- readonly slots: readonly ["item", "body", "media", "title", "summary", "points", "point", "action", "link"];
69
- };
70
- readonly breadcrumbs: {
71
- readonly scope: "[data-bl=\"breadcrumbs\"]";
72
- readonly slots: readonly ["item", "link", "current"];
73
- };
74
- readonly localFacts: {
75
- readonly scope: "[data-bl-section=\"local-facts\"]";
76
- readonly slots: readonly ["fact", "factSource", "fee"];
77
- };
78
- readonly councilRules: {
79
- readonly scope: "[data-bl-section=\"council-rules\"]";
80
- readonly slots: readonly ["fee"];
81
- };
82
- readonly nearbyJobs: {
83
- readonly scope: "[data-bl-section=\"nearby-jobs\"] [data-slot=\"list\"]";
84
- readonly slots: readonly ["item", "body", "media", "title", "link", "outcome", "cue"];
85
- };
86
- readonly coverage: {
87
- readonly scope: "[data-bl-section=\"coverage\"] [data-slot=\"groups\"]";
88
- readonly slots: readonly ["group", "groupHeading"];
89
- };
90
- readonly relatedServices: {
91
- readonly scope: "[data-bl-section=\"related-services\"] [data-slot=\"list\"]";
92
- readonly slots: readonly ["item", "body", "media", "title", "summary", "link"];
93
- };
94
- readonly gallery: {
95
- readonly scope: "[data-bl-section=\"gallery\"] [data-slot=\"list\"]";
96
- readonly slots: readonly ["item", "link"];
97
- };
98
- readonly beforeAfter: {
99
- readonly scope: "[data-bl-section=\"before-after\"] [data-slot=\"list\"]";
100
- readonly slots: readonly ["pair", "frames", "frame", "note"];
101
- };
102
- readonly licences: {
103
- readonly scope: "[data-bl-section=\"licences\"] [data-slot=\"list\"]";
104
- readonly slots: readonly ["row", "label", "value", "number", "holder", "classes", "class", "register", "cover", "amount", "date", "abn", "lookup"];
105
- };
106
- readonly thankYou: {
107
- readonly scope: "[data-bl=\"thank-you\"]";
108
- readonly slots: readonly ["step"];
109
- };
110
- readonly photoUpload: {
111
- readonly scope: "[data-bl=\"photo-upload\"]";
112
- readonly slots: readonly ["photo", "thumb", "remove"];
113
- };
114
- readonly quoteForm: {
115
- readonly scope: "[data-bl=\"quote-form\"] [data-bl=\"photo-upload\"]";
116
- readonly slots: readonly ["photo", "thumb", "remove"];
117
- };
118
- readonly card: {
119
- readonly scope: "[data-bl=\"card\"]";
120
- readonly slots: readonly ["media", "body", "title", "link", "text", "meta"];
121
- };
122
- readonly badge: {
123
- readonly scope: "[data-bl=\"badge\"]";
124
- readonly slots: readonly ["icon", "label"];
125
- };
126
- readonly chip: {
127
- readonly scope: "[data-bl=\"chip\"]";
128
- readonly slots: readonly ["icon", "label"];
129
- };
130
- readonly stat: {
131
- readonly scope: "[data-bl=\"stat\"]";
132
- readonly slots: readonly ["value", "label", "link"];
133
- };
134
- readonly tickList: {
135
- readonly scope: "[data-bl=\"tick-list\"]";
136
- readonly slots: readonly ["item", "tick", "text", "link"];
137
- };
138
- /** A lean list (cost item 1f): plain `<li><a>` entries with no `data-slot`, reached by element. */
139
- readonly linkList: {
140
- readonly scope: "[data-bl=\"link-list\"]";
141
- readonly slots: readonly ["item", "link"];
142
- readonly hooks: {
143
- readonly item: "> li";
144
- readonly link: "> li > a";
145
- };
146
- };
147
- };
148
- export type RepeatedSlotComponent = keyof typeof REPEATED_SLOTS;
149
- /** The repeated slots of one component, for example `RepeatedSlotOf<'siteFooter'>` is `'licenceLink' | … | 'policyLink'`. */
150
- export type RepeatedSlotOf<Component extends RepeatedSlotComponent> = (typeof REPEATED_SLOTS)[Component]['slots'][number];
151
- /** The selector a skin stylesheet uses for one repeated slot, for example `[data-bl="footer"] [data-slot="link"]`. */
152
- export declare function repeatedSlotSelector<Component extends RepeatedSlotComponent>(component: Component, slot: RepeatedSlotOf<Component>): string;
153
- //# sourceMappingURL=repeated-slots.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"repeated-slots.d.ts","sourceRoot":"","sources":["../../src/ui-kit/repeated-slots.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;QAqBvB,kGAAkG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAsDpG,mGAAmG;;;;;;;;;CAE3F,CAAA;AAEV,MAAM,MAAM,qBAAqB,GAAG,MAAM,OAAO,cAAc,CAAA;AAC/D,6HAA6H;AAC7H,MAAM,MAAM,cAAc,CAAC,SAAS,SAAS,qBAAqB,IAAI,CAAC,OAAO,cAAc,CAAC,CAAC,SAAS,CAAC,CAAC,OAAO,CAAC,CAAC,MAAM,CAAC,CAAA;AAEzH,sHAAsH;AACtH,wBAAgB,oBAAoB,CAAC,SAAS,SAAS,qBAAqB,EAAE,SAAS,EAAE,SAAS,EAAE,IAAI,EAAE,cAAc,CAAC,SAAS,CAAC,GAAG,MAAM,CAG3I"}
@@ -1,100 +0,0 @@
1
- /**
2
- * The repeated slots of every shared component (3.14.0): the parts a component renders once per entry of a list in
3
- * its data. They carry their `data-slot` hook and never a class, so a long class string is not repeated in the HTML and
4
- * the RSC payload for every link, review, star, card or chip. A site styles them once in `src/site/skin.css`:
5
- *
6
- * ```css
7
- * @layer components {
8
- * [data-bl="footer"] [data-slot="link"] { @apply text-sm text-white/80 hover:text-white; }
9
- * [data-bl="header"] [data-slot="list"] [data-slot="panelLink"] { padding: 0.5rem 0.75rem; }
10
- * }
11
- * ```
12
- *
13
- * `scope` is the selector that holds the repeated slots without reaching a nested component that reuses a slot name
14
- * (the drawer sits inside the header; the rating chip inside the reviews band uses `stars` too).
15
- * `repeatedSlotSelector()` joins the two. Pure data: safe to import anywhere.
16
- */
17
- export const REPEATED_SLOTS = {
18
- siteHeader: {
19
- scope: '[data-bl="header"] [data-slot="list"]',
20
- slots: [
21
- 'item', 'itemRow', 'link', 'trigger', 'panel', 'panelBody', 'panelList', 'panelGroup', 'panelHeading', 'panelLink',
22
- 'panelLabel', 'panelText', 'featured', 'featuredMedia', 'featuredLabel', 'featuredText',
23
- ],
24
- },
25
- mobileDrawer: {
26
- scope: '[data-bl="drawer"]',
27
- slots: ['group', 'groupTrigger', 'groupLinks', 'groupLink', 'link', 'socialLink'],
28
- },
29
- utilityBar: { scope: '[data-bl="utility"]', slots: ['item', 'licence', 'socialLink'] },
30
- siteFooter: {
31
- scope: '[data-bl="footer"]',
32
- slots: ['licenceLink', 'socialLink', 'column', 'heading', 'toggle', 'list', 'link', 'policyLink'],
33
- },
34
- accordion: { scope: '[data-bl="accordion"]', slots: ['item', 'summary', 'label', 'marker', 'content'] },
35
- faqs: {
36
- scope: '[data-bl-section="faqs"] [data-slot="columns"]',
37
- slots: ['column', 'group', 'subheading', 'accordion', 'item', 'summary', 'label', 'marker', 'content'],
38
- /** The nested accordion's root is its own component: `data-bl="accordion"`, not a `data-slot`. */
39
- hooks: { accordion: '[data-bl="accordion"]' },
40
- },
41
- priceTable: {
42
- scope: '[data-bl="price-table"]',
43
- slots: ['row', 'job', 'cell', 'label', 'range', 'unit', 'gst', 'parts', 'part', 'includes', 'excludes'],
44
- },
45
- priceGuide: {
46
- scope: '[data-bl-section="price-guide"]',
47
- slots: [
48
- 'row', 'job', 'cell', 'label', 'range', 'unit', 'gst', 'parts', 'part', 'includes', 'excludes', 'card', 'title',
49
- 'figures', 'band', 'factor', 'name', 'effect', 'detail',
50
- ],
51
- },
52
- proofStrip: {
53
- scope: '[data-bl-section="proof-strip"] [data-slot="list"]',
54
- slots: ['item', 'link', 'icon', 'stars', 'value', 'label', 'linkLabel'],
55
- },
56
- reviewsBand: {
57
- scope: '[data-bl-section="reviews"] [data-slot="list"]',
58
- slots: ['item', 'stars', 'quote', 'more', 'author', 'avatar', 'name', 'date'],
59
- },
60
- contactBlock: { scope: '[data-bl-section="contact"] [data-slot="details"]', slots: ['line', 'note'] },
61
- servicesGrid: {
62
- scope: '[data-bl-section="services"] [data-slot="list"]',
63
- slots: ['item', 'body', 'media', 'title', 'summary', 'points', 'point', 'action', 'link'],
64
- },
65
- breadcrumbs: { scope: '[data-bl="breadcrumbs"]', slots: ['item', 'link', 'current'] },
66
- // Location sections (3.15.0). Their link lists are `LinkList`s, reached through `linkList` (`[data-bl="link-list"]`).
67
- localFacts: { scope: '[data-bl-section="local-facts"]', slots: ['fact', 'factSource', 'fee'] },
68
- councilRules: { scope: '[data-bl-section="council-rules"]', slots: ['fee'] },
69
- nearbyJobs: { scope: '[data-bl-section="nearby-jobs"] [data-slot="list"]', slots: ['item', 'body', 'media', 'title', 'link', 'outcome', 'cue'] },
70
- coverage: { scope: '[data-bl-section="coverage"] [data-slot="groups"]', slots: ['group', 'groupHeading'] },
71
- relatedServices: {
72
- scope: '[data-bl-section="related-services"] [data-slot="list"]',
73
- slots: ['item', 'body', 'media', 'title', 'summary', 'link'],
74
- },
75
- // Proof sections (3.15.0). Their photos are nested `[data-bl="media"]` frames; project cards are `[data-bl="card"]`.
76
- gallery: { scope: '[data-bl-section="gallery"] [data-slot="list"]', slots: ['item', 'link'] },
77
- beforeAfter: { scope: '[data-bl-section="before-after"] [data-slot="list"]', slots: ['pair', 'frames', 'frame', 'note'] },
78
- licences: {
79
- scope: '[data-bl-section="licences"] [data-slot="list"]',
80
- slots: ['row', 'label', 'value', 'number', 'holder', 'classes', 'class', 'register', 'cover', 'amount', 'date', 'abn', 'lookup'],
81
- },
82
- thankYou: { scope: '[data-bl="thank-you"]', slots: ['step'] },
83
- photoUpload: { scope: '[data-bl="photo-upload"]', slots: ['photo', 'thumb', 'remove'] },
84
- quoteForm: { scope: '[data-bl="quote-form"] [data-bl="photo-upload"]', slots: ['photo', 'thumb', 'remove'] },
85
- // Primitives rendered once per list entry (3.14.0): every part is repeated, the root included (style the root
86
- // through its own hook, `[data-bl="card"]`).
87
- card: { scope: '[data-bl="card"]', slots: ['media', 'body', 'title', 'link', 'text', 'meta'] },
88
- badge: { scope: '[data-bl="badge"]', slots: ['icon', 'label'] },
89
- chip: { scope: '[data-bl="chip"]', slots: ['icon', 'label'] },
90
- stat: { scope: '[data-bl="stat"]', slots: ['value', 'label', 'link'] },
91
- tickList: { scope: '[data-bl="tick-list"]', slots: ['item', 'tick', 'text', 'link'] },
92
- /** A lean list (cost item 1f): plain `<li><a>` entries with no `data-slot`, reached by element. */
93
- linkList: { scope: '[data-bl="link-list"]', slots: ['item', 'link'], hooks: { item: '> li', link: '> li > a' } },
94
- };
95
- /** The selector a skin stylesheet uses for one repeated slot, for example `[data-bl="footer"] [data-slot="link"]`. */
96
- export function repeatedSlotSelector(component, slot) {
97
- const entry = REPEATED_SLOTS[component];
98
- return `${entry.scope} ${entry.hooks?.[slot] ?? `[data-slot="${slot}"]`}`;
99
- }
100
- //# sourceMappingURL=repeated-slots.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"repeated-slots.js","sourceRoot":"","sources":["../../src/ui-kit/repeated-slots.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AACH,MAAM,CAAC,MAAM,cAAc,GAAG;IAC5B,UAAU,EAAE;QACV,KAAK,EAAE,uCAAuC;QAC9C,KAAK,EAAE;YACL,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,SAAS,EAAE,OAAO,EAAE,WAAW,EAAE,WAAW,EAAE,YAAY,EAAE,cAAc,EAAE,WAAW;YAClH,YAAY,EAAE,WAAW,EAAE,UAAU,EAAE,eAAe,EAAE,eAAe,EAAE,cAAc;SACxF;KACF;IACD,YAAY,EAAE;QACZ,KAAK,EAAE,oBAAoB;QAC3B,KAAK,EAAE,CAAC,OAAO,EAAE,cAAc,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,EAAE,YAAY,CAAC;KAClF;IACD,UAAU,EAAE,EAAE,KAAK,EAAE,qBAAqB,EAAE,KAAK,EAAE,CAAC,MAAM,EAAE,SAAS,EAAE,YAAY,CAAC,EAAE;IACtF,UAAU,EAAE;QACV,KAAK,EAAE,oBAAoB;QAC3B,KAAK,EAAE,CAAC,aAAa,EAAE,YAAY,EAAE,QAAQ,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,YAAY,CAAC;KAClG;IACD,SAAS,EAAE,EAAE,KAAK,EAAE,uBAAuB,EAAE,KAAK,EAAE,CAAC,MAAM,EAAE,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAE,SAAS,CAAC,EAAE;IACvG,IAAI,EAAE;QACJ,KAAK,EAAE,g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,oBAAoB,CAA0C,SAAoB,EAAE,IAA+B;IACjI,MAAM,KAAK,GAAkF,cAAc,CAAC,SAAS,CAAC,CAAA;IACtH,OAAO,GAAG,KAAK,CAAC,KAAK,IAAI,KAAK,CAAC,KAAK,EAAE,CAAC,IAAI,CAAC,IAAI,eAAe,IAAI,IAAI,EAAE,CAAA;AAC3E,CAAC","sourcesContent":["/**\n * The repeated slots of every shared component (3.14.0): the parts a component renders once per entry of a list in\n * its data. They carry their `data-slot` hook and never a class, so a long class string is not repeated in the HTML and\n * the RSC payload for every link, review, star, card or chip. A site styles them once in `src/site/skin.css`:\n *\n * ```css\n * @layer components {\n * [data-bl=\"footer\"] [data-slot=\"link\"] { @apply text-sm text-white/80 hover:text-white; }\n * [data-bl=\"header\"] [data-slot=\"list\"] [data-slot=\"panelLink\"] { padding: 0.5rem 0.75rem; }\n * }\n * ```\n *\n * `scope` is the selector that holds the repeated slots without reaching a nested component that reuses a slot name\n * (the drawer sits inside the header; the rating chip inside the reviews band uses `stars` too).\n * `repeatedSlotSelector()` joins the two. Pure data: safe to import anywhere.\n */\nexport const REPEATED_SLOTS = {\n siteHeader: {\n scope: '[data-bl=\"header\"] [data-slot=\"list\"]',\n slots: [\n 'item', 'itemRow', 'link', 'trigger', 'panel', 'panelBody', 'panelList', 'panelGroup', 'panelHeading', 'panelLink',\n 'panelLabel', 'panelText', 'featured', 'featuredMedia', 'featuredLabel', 'featuredText',\n ],\n },\n mobileDrawer: {\n scope: '[data-bl=\"drawer\"]',\n slots: ['group', 'groupTrigger', 'groupLinks', 'groupLink', 'link', 'socialLink'],\n },\n utilityBar: { scope: '[data-bl=\"utility\"]', slots: ['item', 'licence', 'socialLink'] },\n siteFooter: {\n scope: '[data-bl=\"footer\"]',\n slots: ['licenceLink', 'socialLink', 'column', 'heading', 'toggle', 'list', 'link', 'policyLink'],\n },\n accordion: { scope: '[data-bl=\"accordion\"]', slots: ['item', 'summary', 'label', 'marker', 'content'] },\n faqs: {\n scope: '[data-bl-section=\"faqs\"] [data-slot=\"columns\"]',\n slots: ['column', 'group', 'subheading', 'accordion', 'item', 'summary', 'label', 'marker', 'content'],\n /** The nested accordion's root is its own component: `data-bl=\"accordion\"`, not a `data-slot`. */\n hooks: { accordion: '[data-bl=\"accordion\"]' },\n },\n priceTable: {\n scope: '[data-bl=\"price-table\"]',\n slots: ['row', 'job', 'cell', 'label', 'range', 'unit', 'gst', 'parts', 'part', 'includes', 'excludes'],\n },\n priceGuide: {\n scope: '[data-bl-section=\"price-guide\"]',\n slots: [\n 'row', 'job', 'cell', 'label', 'range', 'unit', 'gst', 'parts', 'part', 'includes', 'excludes', 'card', 'title',\n 'figures', 'band', 'factor', 'name', 'effect', 'detail',\n ],\n },\n proofStrip: {\n scope: '[data-bl-section=\"proof-strip\"] [data-slot=\"list\"]',\n slots: ['item', 'link', 'icon', 'stars', 'value', 'label', 'linkLabel'],\n },\n reviewsBand: {\n scope: '[data-bl-section=\"reviews\"] [data-slot=\"list\"]',\n slots: ['item', 'stars', 'quote', 'more', 'author', 'avatar', 'name', 'date'],\n },\n contactBlock: { scope: '[data-bl-section=\"contact\"] [data-slot=\"details\"]', slots: ['line', 'note'] },\n servicesGrid: {\n scope: '[data-bl-section=\"services\"] [data-slot=\"list\"]',\n slots: ['item', 'body', 'media', 'title', 'summary', 'points', 'point', 'action', 'link'],\n },\n breadcrumbs: { scope: '[data-bl=\"breadcrumbs\"]', slots: ['item', 'link', 'current'] },\n // Location sections (3.15.0). Their link lists are `LinkList`s, reached through `linkList` (`[data-bl=\"link-list\"]`).\n localFacts: { scope: '[data-bl-section=\"local-facts\"]', slots: ['fact', 'factSource', 'fee'] },\n councilRules: { scope: '[data-bl-section=\"council-rules\"]', slots: ['fee'] },\n nearbyJobs: { scope: '[data-bl-section=\"nearby-jobs\"] [data-slot=\"list\"]', slots: ['item', 'body', 'media', 'title', 'link', 'outcome', 'cue'] },\n coverage: { scope: '[data-bl-section=\"coverage\"] [data-slot=\"groups\"]', slots: ['group', 'groupHeading'] },\n relatedServices: {\n scope: '[data-bl-section=\"related-services\"] [data-slot=\"list\"]',\n slots: ['item', 'body', 'media', 'title', 'summary', 'link'],\n },\n // Proof sections (3.15.0). Their photos are nested `[data-bl=\"media\"]` frames; project cards are `[data-bl=\"card\"]`.\n gallery: { scope: '[data-bl-section=\"gallery\"] [data-slot=\"list\"]', slots: ['item', 'link'] },\n beforeAfter: { scope: '[data-bl-section=\"before-after\"] [data-slot=\"list\"]', slots: ['pair', 'frames', 'frame', 'note'] },\n licences: {\n scope: '[data-bl-section=\"licences\"] [data-slot=\"list\"]',\n slots: ['row', 'label', 'value', 'number', 'holder', 'classes', 'class', 'register', 'cover', 'amount', 'date', 'abn', 'lookup'],\n },\n thankYou: { scope: '[data-bl=\"thank-you\"]', slots: ['step'] },\n photoUpload: { scope: '[data-bl=\"photo-upload\"]', slots: ['photo', 'thumb', 'remove'] },\n quoteForm: { scope: '[data-bl=\"quote-form\"] [data-bl=\"photo-upload\"]', slots: ['photo', 'thumb', 'remove'] },\n // Primitives rendered once per list entry (3.14.0): every part is repeated, the root included (style the root\n // through its own hook, `[data-bl=\"card\"]`).\n card: { scope: '[data-bl=\"card\"]', slots: ['media', 'body', 'title', 'link', 'text', 'meta'] },\n badge: { scope: '[data-bl=\"badge\"]', slots: ['icon', 'label'] },\n chip: { scope: '[data-bl=\"chip\"]', slots: ['icon', 'label'] },\n stat: { scope: '[data-bl=\"stat\"]', slots: ['value', 'label', 'link'] },\n tickList: { scope: '[data-bl=\"tick-list\"]', slots: ['item', 'tick', 'text', 'link'] },\n /** A lean list (cost item 1f): plain `<li><a>` entries with no `data-slot`, reached by element. */\n linkList: { scope: '[data-bl=\"link-list\"]', slots: ['item', 'link'], hooks: { item: '> li', link: '> li > a' } },\n} as const\n\nexport type RepeatedSlotComponent = keyof typeof REPEATED_SLOTS\n/** The repeated slots of one component, for example `RepeatedSlotOf<'siteFooter'>` is `'licenceLink' | … | 'policyLink'`. */\nexport type RepeatedSlotOf<Component extends RepeatedSlotComponent> = (typeof REPEATED_SLOTS)[Component]['slots'][number]\n\n/** The selector a skin stylesheet uses for one repeated slot, for example `[data-bl=\"footer\"] [data-slot=\"link\"]`. */\nexport function repeatedSlotSelector<Component extends RepeatedSlotComponent>(component: Component, slot: RepeatedSlotOf<Component>): string {\n const entry: { readonly scope: string; readonly hooks?: Readonly<Record<string, string>> } = REPEATED_SLOTS[component]\n return `${entry.scope} ${entry.hooks?.[slot] ?? `[data-slot=\"${slot}\"]`}`\n}\n"]}
@@ -1,28 +0,0 @@
1
- /**
2
- * `Accordion`: a list of disclosures on `<details name>`. Server component: items sharing a `name` open one at a time
3
- * natively (no script), and every item's content is in the server HTML whether open or closed (K7). Items are closed
4
- * by default; `defaultOpen` opens one only where a site recorded it (Gabrael: Eastern Suburbs open). The open state is
5
- * the native `open` attribute, so skins style `[open]`.
6
- */
7
- import type { ReactNode } from 'react';
8
- import type { RepeatedSlotOf } from '../repeated-slots.js';
9
- import { type SkinEntry } from '../skin.js';
10
- export type AccordionSlot = 'root' | 'item' | 'summary' | 'label' | 'marker' | 'content';
11
- /** Rendered once per item: styled from the skin stylesheet, never by class (3.14.0). */
12
- export type AccordionRepeatedSlot = RepeatedSlotOf<'accordion'>;
13
- export type AccordionSkin = SkinEntry<AccordionSlot, never, Record<never, never>, AccordionRepeatedSlot>;
14
- export interface AccordionItem {
15
- /** A stable slug, unique in the group. The item's element id is `{name}-{id}`, so it can be linked to. */
16
- readonly id: string;
17
- readonly summary: ReactNode;
18
- readonly content: ReactNode;
19
- }
20
- export interface AccordionProps extends AccordionSkin {
21
- readonly items: readonly AccordionItem[];
22
- /** The group: items sharing a name open one at a time. Unique on the page. */
23
- readonly name: string;
24
- /** The id of the item open on load, only when the site recorded one. */
25
- readonly defaultOpen?: string | undefined;
26
- }
27
- export declare function Accordion({ items, name, defaultOpen, classes }: AccordionProps): import("react/jsx-runtime").JSX.Element | null;
28
- //# sourceMappingURL=accordion.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"accordion.d.ts","sourceRoot":"","sources":["../../../src/ui-kit/sections/accordion.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAEtC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAA;AAC1D,OAAO,EAAsB,KAAK,SAAS,EAAE,MAAM,YAAY,CAAA;AAE/D,MAAM,MAAM,aAAa,GAAG,MAAM,GAAG,MAAM,GAAG,SAAS,GAAG,OAAO,GAAG,QAAQ,GAAG,SAAS,CAAA;AACxF,wFAAwF;AACxF,MAAM,MAAM,qBAAqB,GAAG,cAAc,CAAC,WAAW,CAAC,CAAA;AAC/D,MAAM,MAAM,aAAa,GAAG,SAAS,CAAC,aAAa,EAAE,KAAK,EAAE,MAAM,CAAC,KAAK,EAAE,KAAK,CAAC,EAAE,qBAAqB,CAAC,CAAA;AAExG,MAAM,WAAW,aAAa;IAC5B,0GAA0G;IAC1G,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAA;IACnB,QAAQ,CAAC,OAAO,EAAE,SAAS,CAAA;IAC3B,QAAQ,CAAC,OAAO,EAAE,SAAS,CAAA;CAC5B;AAED,MAAM,WAAW,cAAe,SAAQ,aAAa;IACnD,QAAQ,CAAC,KAAK,EAAE,SAAS,aAAa,EAAE,CAAA;IACxC,8EAA8E;IAC9E,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;IACrB,wEAAwE;IACxE,QAAQ,CAAC,WAAW,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;CAC1C;AAED,wBAAgB,SAAS,CAAC,EAAE,KAAK,EAAE,IAAI,EAAE,WAAW,EAAE,OAAO,EAAE,EAAE,cAAc,kDAoB9E"}
@@ -1,14 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { Icon } from '../icons.js';
3
- import { repeatedSlot, slot } from '../skin.js';
4
- export function Accordion({ items, name, defaultOpen, classes }) {
5
- if (items.length === 0)
6
- return null;
7
- const ids = new Set(items.map((item) => item.id));
8
- if (ids.size !== items.length)
9
- throw new Error(`Accordion "${name}": item ids must be unique.`);
10
- if (defaultOpen !== undefined && !ids.has(defaultOpen))
11
- throw new Error(`Accordion "${name}": defaultOpen "${defaultOpen}" is not an item.`);
12
- return (_jsx("div", { "data-bl": "accordion", className: classes?.root, children: items.map((item) => (_jsxs("details", { id: `${name}-${item.id}`, name: name, open: item.id === defaultOpen, ...repeatedSlot('item'), children: [_jsxs("summary", { ...repeatedSlot('summary'), children: [_jsx("span", { ...repeatedSlot('label'), children: item.summary }), _jsx("span", { ...repeatedSlot('marker'), "aria-hidden": "true", children: _jsx(Icon, { name: "chevron" }) })] }), _jsx("div", { ...repeatedSlot('content'), children: item.content })] }, item.id))) }));
13
- }
14
- //# sourceMappingURL=accordion.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"accordion.js","sourceRoot":"","sources":["../../../src/ui-kit/sections/accordion.tsx"],"names":[],"mappings":";AAOA,OAAO,EAAE,IAAI,EAAE,MAAM,aAAa,CAAA;AAElC,OAAO,EAAE,YAAY,EAAE,IAAI,EAAkB,MAAM,YAAY,CAAA;AAsB/D,MAAM,UAAU,SAAS,CAAC,EAAE,KAAK,EAAE,IAAI,EAAE,WAAW,EAAE,OAAO,EAAkB;IAC7E,IAAI,KAAK,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,IAAI,CAAA;IACnC,MAAM,GAAG,GAAG,IAAI,GAAG,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,CAAA;IACjD,IAAI,GAAG,CAAC,IAAI,KAAK,KAAK,CAAC,MAAM;QAAE,MAAM,IAAI,KAAK,CAAC,cAAc,IAAI,6BAA6B,CAAC,CAAA;IAC/F,IAAI,WAAW,KAAK,SAAS,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC,WAAW,CAAC;QAAE,MAAM,IAAI,KAAK,CAAC,cAAc,IAAI,mBAAmB,WAAW,mBAAmB,CAAC,CAAA;IAC5I,OAAO,CACL,yBAAa,WAAW,EAAC,SAAS,EAAE,OAAO,EAAE,IAAI,YAC9C,KAAK,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,CACnB,mBAAuB,EAAE,EAAE,GAAG,IAAI,IAAI,IAAI,CAAC,EAAE,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,EAAE,KAAK,WAAW,KAAM,YAAY,CAAC,MAAM,CAAC,aAClH,sBAAa,YAAY,CAAC,SAAS,CAAC,aAClC,kBAAU,YAAY,CAAC,OAAO,CAAC,YAAG,IAAI,CAAC,OAAO,GAAQ,EACtD,kBAAU,YAAY,CAAC,QAAQ,CAAC,iBAAc,MAAM,YAClD,KAAC,IAAI,IAAC,IAAI,EAAC,SAAS,GAAG,GAClB,IACC,EACV,iBAAS,YAAY,CAAC,SAAS,CAAC,YAAG,IAAI,CAAC,OAAO,GAAO,KAP1C,IAAI,CAAC,EAAE,CAQX,CACX,CAAC,GACE,CACP,CAAA;AACH,CAAC","sourcesContent":["/**\n * `Accordion`: a list of disclosures on `<details name>`. Server component: items sharing a `name` open one at a time\n * natively (no script), and every item's content is in the server HTML whether open or closed (K7). Items are closed\n * by default; `defaultOpen` opens one only where a site recorded it (Gabrael: Eastern Suburbs open). The open state is\n * the native `open` attribute, so skins style `[open]`.\n */\nimport type { ReactNode } from 'react'\nimport { Icon } from '../icons.js'\nimport type { RepeatedSlotOf } from '../repeated-slots.js'\nimport { repeatedSlot, slot, type SkinEntry } from '../skin.js'\n\nexport type AccordionSlot = 'root' | 'item' | 'summary' | 'label' | 'marker' | 'content'\n/** Rendered once per item: styled from the skin stylesheet, never by class (3.14.0). */\nexport type AccordionRepeatedSlot = RepeatedSlotOf<'accordion'>\nexport type AccordionSkin = SkinEntry<AccordionSlot, never, Record<never, never>, AccordionRepeatedSlot>\n\nexport interface AccordionItem {\n /** A stable slug, unique in the group. The item's element id is `{name}-{id}`, so it can be linked to. */\n readonly id: string\n readonly summary: ReactNode\n readonly content: ReactNode\n}\n\nexport interface AccordionProps extends AccordionSkin {\n readonly items: readonly AccordionItem[]\n /** The group: items sharing a name open one at a time. Unique on the page. */\n readonly name: string\n /** The id of the item open on load, only when the site recorded one. */\n readonly defaultOpen?: string | undefined\n}\n\nexport function Accordion({ items, name, defaultOpen, classes }: AccordionProps) {\n if (items.length === 0) return null\n const ids = new Set(items.map((item) => item.id))\n if (ids.size !== items.length) throw new Error(`Accordion \"${name}\": item ids must be unique.`)\n if (defaultOpen !== undefined && !ids.has(defaultOpen)) throw new Error(`Accordion \"${name}\": defaultOpen \"${defaultOpen}\" is not an item.`)\n return (\n <div data-bl=\"accordion\" className={classes?.root}>\n {items.map((item) => (\n <details key={item.id} id={`${name}-${item.id}`} name={name} open={item.id === defaultOpen} {...repeatedSlot('item')}>\n <summary {...repeatedSlot('summary')}>\n <span {...repeatedSlot('label')}>{item.summary}</span>\n <span {...repeatedSlot('marker')} aria-hidden=\"true\">\n <Icon name=\"chevron\" />\n </span>\n </summary>\n <div {...repeatedSlot('content')}>{item.content}</div>\n </details>\n ))}\n </div>\n )\n}\n"]}
@@ -1,64 +0,0 @@
1
- import type { ReactNode } from 'react';
2
- import type { AreaMapModel } from '@brandlab-digital/site-core/area-map';
3
- import { type BrandlabSectionReadiness } from '@brandlab-digital/site-core/section-order';
4
- import { type LinkListEntry, type LinkListLayout } from '../primitives/lists.js';
5
- import { type SectionHeadingSlot, type SectionSlot, type SectionTone } from '../primitives/layout.js';
6
- import { type SkinEntry } from '../skin.js';
7
- import type { UiLink } from '../types.js';
8
- /** The map a page shows, from its model's kind: `locator` (suburb or town), `region` or `overview`. */
9
- export declare const AREA_MAP_VARIANTS: readonly ["locator", "region", "overview"];
10
- export type AreaMapVariant = (typeof AREA_MAP_VARIANTS)[number];
11
- export type AreaMapSlot = SectionSlot | SectionHeadingSlot | 'body' | 'figure' | 'frame' | 'map' | 'caption' | 'legend' | 'legendBase' | 'legendJobs' | 'credit' | 'places' | 'placesTitle' | 'list' | 'region' | 'more';
12
- export interface AreaMapLayout extends LinkListLayout {
13
- /** The place list beside the map on wide screens (default) or below it. */
14
- readonly list?: 'beside' | 'below';
15
- /** Draw place names inside their shapes where they fit (default true). */
16
- readonly names?: boolean;
17
- }
18
- /** The variant follows the model, so a skin sets the look (layout and classes) only. */
19
- export type AreaMapSkin = SkinEntry<AreaMapSlot, never, AreaMapLayout>;
20
- /** A model from site-core's map engine and the URL of its base layer file (written with `linked: true`). */
21
- export interface AreaMapData {
22
- readonly model: AreaMapModel;
23
- /** For example `/area-maps/suburb-castle-hill.svg`. */
24
- readonly baseHref: string;
25
- }
26
- export interface AreaMapProps extends AreaMapSkin {
27
- /** The H2, for example "Where we work around Castle Hill". */
28
- readonly title: ReactNode;
29
- readonly eyebrow?: ReactNode;
30
- readonly lead?: ReactNode;
31
- /** The model and its base file; `undefined` (a locator with no neighbours or jobs) renders nothing. */
32
- readonly map: AreaMapData | undefined;
33
- /** What the map shows, in the site's words (the figure's caption, before the boundary credit). */
34
- readonly caption: ReactNode;
35
- /** A heading over the place list (an H3), for example "Suburbs we serve near Castle Hill". */
36
- readonly placesTitle?: ReactNode;
37
- /** The text alternative. Defaults to `areaMapPlaces(map.model)`. */
38
- readonly places?: readonly LinkListEntry[];
39
- /** Legend lines in the site's words, shown only when the map has that marker. */
40
- readonly legend?: {
41
- readonly base?: ReactNode;
42
- readonly jobs?: ReactNode;
43
- };
44
- /** The region's page on a locator, for example `{ label: 'All of the Hills District', href }`. Never prefetched. */
45
- readonly regionLink?: UiLink;
46
- /** A link after the list, for example the areas hub. Never prefetched. */
47
- readonly more?: UiLink;
48
- /** Defaults to `area-map-heading`. */
49
- readonly headingId?: string;
50
- /** Set by `SectionSequence`. */
51
- readonly tone?: SectionTone;
52
- }
53
- /**
54
- * The map's text alternative: its linked places as links and its served places without an indexable page as plain
55
- * names, in the model's order (a locator's nearest first, a region's by name). The page's own place is left out.
56
- * `links: false` lists every name as plain text, for a page whose `NearbyAreas` or `Coverage` links them already.
57
- */
58
- export declare function areaMapPlaces(model: AreaMapModel, { links }?: {
59
- readonly links?: boolean;
60
- }): LinkListEntry[];
61
- /** The guard for `SectionSequence`: a locator with no neighbours and no jobs has no map. */
62
- export declare function areaMapReady({ map }: Pick<AreaMapProps, 'map'>): BrandlabSectionReadiness;
63
- export declare function AreaMap({ title, eyebrow, lead, map, caption, placesTitle, places, legend, regionLink, more, headingId, tone, layout, classes, }: AreaMapProps): import("react/jsx-runtime").JSX.Element | null;
64
- //# sourceMappingURL=area-map.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"area-map.d.ts","sourceRoot":"","sources":["../../../src/ui-kit/sections/area-map.tsx"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAiB,SAAS,EAAE,MAAM,OAAO,CAAA;AACrD,OAAO,KAAK,EAAgB,YAAY,EAAE,MAAM,sCAAsC,CAAA;AACtF,OAAO,EAAiB,KAAK,wBAAwB,EAAE,MAAM,2CAA2C,CAAA;AACxG,OAAO,EAAY,KAAK,aAAa,EAAE,KAAK,cAAc,EAAE,MAAM,wBAAwB,CAAA;AAC1F,OAAO,EAA2B,KAAK,kBAAkB,EAAE,KAAK,WAAW,EAAE,KAAK,WAAW,EAAE,MAAM,yBAAyB,CAAA;AAC9H,OAAO,EAAQ,KAAK,SAAS,EAAE,MAAM,YAAY,CAAA;AACjD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,aAAa,CAAA;AAEzC,uGAAuG;AACvG,eAAO,MAAM,iBAAiB,4CAA6C,CAAA;AAC3E,MAAM,MAAM,cAAc,GAAG,CAAC,OAAO,iBAAiB,CAAC,CAAC,MAAM,CAAC,CAAA;AAE/D,MAAM,MAAM,WAAW,GACnB,WAAW,GACX,kBAAkB,GAClB,MAAM,GACN,QAAQ,GACR,OAAO,GACP,KAAK,GACL,SAAS,G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M,CAAA;IAC5B,0EAA0E;IAC1E,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAA;IACtB,sCAAsC;IACtC,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAA;IAC3B,gCAAgC;IAChC,QAAQ,CAAC,IAAI,CAAC,EAAE,WAAW,CAAA;CAC5B;AAcD;;;;GAIG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,YAAY,EAAE,EAAE,KAAY,EAAE,GAAE;IAAE,QAAQ,CAAC,KAAK,CAAC,EAAE,OAAO,CAAA;CAAO,GAAG,aAAa,EAAE,CAoBvH;AAED,4FAA4F;AAC5F,wBAAgB,YAAY,CAAC,EAAE,GAAG,EAAE,EAAE,IAAI,CAAC,YAAY,EAAE,KAAK,CAAC,GAAG,wBAAwB,CAEzF;AA0DD,wBAAgB,OAAO,CAAC,EACtB,KAAK,EACL,OAAO,EACP,IAAI,EACJ,GAAG,EACH,OAAO,EACP,WAAW,EACX,MAAM,EACN,MAAM,EACN,UAAU,EACV,IAAI,EACJ,SAA8B,EAC9B,IAAI,EACJ,MAAM,EACN,OAAO,GACR,EAAE,YAAY,kDAoId"}
@@ -1,146 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- /**
3
- * `AreaMap` (`area-map`, 3.15.0): the service-area map of a suburb page (`locator`: the suburb, its nearest served
4
- * neighbours and nearby jobs) or a region page (`region`: the region's suburbs), and the overview of the home page or
5
- * locations hub (`overview`). Server component, no client JS.
6
- *
7
- * Data comes from site-core's map engine (`./area-map`, since 3.6.0): `suburbLocator`, `regionMap` or `overviewMap`
8
- * build a plain model on the server, and the site serves the model's static base layer once as a cached SVG file
9
- * (`renderAreaMapBaseSvg(site, model, { linked: true })`, for example at `/area-maps/<model.id>.svg`). The page's SVG
10
- * is lean: land, the focus area, served areas and outlines are `<use>` references into that file, and each linked
11
- * place is an `<a>` around a `<use>` of its shape (`areaMapShapeId`), so no boundary path sits in the page's HTML.
12
- *
13
- * The drawing is `aria-hidden` and its links are out of the tab order; the text alternative is the place list beside
14
- * it (`areaMapPlaces(model)`: the linked places as links, served places without an indexable page as plain names), a
15
- * lean `LinkList` marked `data-bl-links="map"` that never prefetches (W2). Where the page's `NearbyAreas` or `Coverage`
16
- * already links the same places, pass `areaMapPlaces(model, { links: false })` so the map lists their names only. The
17
- * figure's caption is site copy; the boundary credit (CC BY 4.0) always follows it.
18
- */
19
- import Link from 'next/link';
20
- import { SECTION_READY } from '@brandlab-digital/site-core/section-order';
21
- import { LinkList } from '../primitives/lists.js';
22
- import { Section, SectionHeading } from '../primitives/layout.js';
23
- import { slot } from '../skin.js';
24
- /** The map a page shows, from its model's kind: `locator` (suburb or town), `region` or `overview`. */
25
- export const AREA_MAP_VARIANTS = ['locator', 'region', 'overview'];
26
- const VARIANT_OF = { overview: 'overview', region: 'region', suburb: 'locator' };
27
- /** Which shapes carry their name: the overview names every region with room; close-ups name the served places. */
28
- const NAMED = {
29
- overview: ['linked', 'served', 'muted'],
30
- region: ['linked', 'served'],
31
- suburb: ['focus', 'linked', 'served'],
32
- };
33
- /** A link's element id in the base file, as site-core's `areaMapShapeId` (kept here so the page never loads the boundary data). */
34
- const shapeId = (key) => key.replace(':', '-');
35
- /**
36
- * The map's text alternative: its linked places as links and its served places without an indexable page as plain
37
- * names, in the model's order (a locator's nearest first, a region's by name). The page's own place is left out.
38
- * `links: false` lists every name as plain text, for a page whose `NearbyAreas` or `Coverage` links them already.
39
- */
40
- export function areaMapPlaces(model, { links = true } = {}) {
41
- const hrefOf = new Map(model.shapes.map((shape) => [shape.key, shape.href]));
42
- const seen = new Set();
43
- const entries = [];
44
- const add = (key, label) => {
45
- if (seen.has(key))
46
- return;
47
- seen.add(key);
48
- const href = hrefOf.get(key);
49
- entries.push(links && href !== undefined ? { label, href } : { label });
50
- };
51
- for (const label of model.labels)
52
- if (label.state === 'linked' || label.state === 'served')
53
- add(label.key, label.name);
54
- for (const shape of model.shapes)
55
- add(shape.key, shape.name);
56
- // A region's outlying served places are left out of its frame (3.15.0), so only the list names them.
57
- for (const place of model.outside ?? []) {
58
- if (seen.has(place.key))
59
- continue;
60
- seen.add(place.key);
61
- entries.push(links && place.href !== undefined ? { label: place.name, href: place.href } : { label: place.name });
62
- }
63
- if (model.kind === 'region')
64
- entries.sort((a, b) => a.label.localeCompare(b.label));
65
- return entries;
66
- }
67
- /** The guard for `SectionSequence`: a locator with no neighbours and no jobs has no map. */
68
- export function areaMapReady({ map }) {
69
- return map ? SECTION_READY : { render: false, reason: 'no-area-map' };
70
- }
71
- /** Whether a name fits inside its shape around the label point (`room` is the distance to the nearest edge). */
72
- function fits(label, size) {
73
- const halfWidth = (label.name.length * size * 0.56) / 2;
74
- return halfWidth <= label.room * 1.4 && size * 0.6 <= label.room;
75
- }
76
- const percent = (value) => `${Math.round(value * 100) / 100}%`;
77
- /** A marker's centre moved inside the frame by its radius and stroke. */
78
- function keepInside(point, r, model) {
79
- const pad = r * 1.2;
80
- return { x: Math.round(Math.min(Math.max(point.x, pad), model.width - pad)), y: Math.round(Math.min(Math.max(point.y, pad), model.height - pad)), r };
81
- }
82
- /**
83
- * Where a name sits (3.15.0): centred on its label point and inside the frame (and the phone crop, 3.17.0), or, when that would cover a job pin or
84
- * the base, just below or above the marker if that stays near its shape. A name with no clear place is not drawn (the
85
- * place list still names it). Returns the text's x and baseline, or undefined.
86
- */
87
- function placeName(label, size, marks, model) {
88
- const half = (label.name.length * size * 0.56) / 2;
89
- const pad = size * 0.3;
90
- // 3.17.0: a name whose point is inside the phone crop stays inside the crop too, so phones never cut it off.
91
- const { crop } = model;
92
- const inCrop = label.x >= crop.x && label.x <= crop.x + crop.width && label.y >= crop.y && label.y <= crop.y + crop.height;
93
- const box = inCrop && crop.width >= 2 * (half + pad) ? crop : { x: 0, y: 0, width: model.width, height: model.height };
94
- const x = Math.min(Math.max(label.x, box.x + half + pad), box.x + box.width - half - pad);
95
- const top = box.y + size * 0.8 + pad;
96
- const bottom = box.y + box.height - size * 0.25 - pad;
97
- const clear = (baseline) => marks.every((mark) => mark.x + mark.r + pad < x - half ||
98
- mark.x - mark.r - pad > x + half ||
99
- mark.y + mark.r + pad < baseline - size * 0.8 ||
100
- mark.y - mark.r - pad > baseline + size * 0.25);
101
- const natural = label.y + size * 0.35;
102
- // The nearest clear place first: just below or above whichever marker it would cover.
103
- const candidates = [natural, ...marks.flatMap((mark) => [mark.y + mark.r + pad + size * 0.85, mark.y - mark.r - pad - size * 0.3])].sort((one, other) => Math.abs(one - natural) - Math.abs(other - natural));
104
- for (const candidate of candidates) {
105
- const y = Math.min(Math.max(candidate, top), bottom);
106
- if (Math.abs(y - natural) > Math.max(label.room * 1.5, size))
107
- continue;
108
- if (clear(y))
109
- return { x: Math.round(x), y: Math.round(y) };
110
- }
111
- return undefined;
112
- }
113
- export function AreaMap({ title, eyebrow, lead, map, caption, placesTitle, places, legend, regionLink, more, headingId = 'area-map-heading', tone, layout, classes, }) {
114
- if (!map)
115
- return null;
116
- const { model, baseHref } = map;
117
- if (!/\.svg(?:$|[?#])/.test(baseHref))
118
- throw new Error(`AreaMap: baseHref must be the model's base SVG file, not "${baseHref}".`);
119
- const list = places ?? areaMapPlaces(model);
120
- if (regionLink && list.some((entry) => entry.href === regionLink.href))
121
- throw new Error('AreaMap: the region link repeats a listed place.');
122
- const size = Math.round(model.width * 0.022);
123
- const marker = Math.round(model.width * 0.009);
124
- const names = layout?.names === false ? [] : model.labels.filter((label) => NAMED[model.kind].includes(label.state) && fits(label, size));
125
- const baseMarker = model.markers.find((point) => point.kind === 'base');
126
- const base = baseMarker ? keepInside(baseMarker, marker, model) : undefined;
127
- const jobs = model.markers.filter((point) => point.kind === 'job').map((point) => ({ slug: point.slug, ...keepInside(point, marker, model) }));
128
- const marks = base ? [...jobs, base] : jobs;
129
- const placed = names.flatMap((label) => {
130
- const at = placeName(label, size, marks, model);
131
- return at ? [{ label, ...at }] : [];
132
- });
133
- const { crop } = model;
134
- const frame = {
135
- '--bl-map-ratio': `${model.width} / ${model.height}`,
136
- '--bl-map-crop-ratio': `${crop.width} / ${crop.height}`,
137
- '--bl-map-crop-size': percent((model.width / crop.width) * 100),
138
- '--bl-map-crop-x': percent((-crop.x / crop.width) * 100),
139
- '--bl-map-crop-y': percent((-crop.y / crop.height) * 100),
140
- };
141
- const use = (id) => `${baseHref}#${id}`;
142
- const legendBase = base && legend?.base ? legend.base : null;
143
- const legendJobs = jobs.length > 0 && legend?.jobs ? legend.jobs : null;
144
- return (_jsxs(Section, { id: "area-map", labelledBy: headingId, tone: tone, variant: VARIANT_OF[model.kind], classes: classes, hooks: { 'data-list': layout?.list ?? 'beside' }, children: [_jsx(SectionHeading, { id: headingId, title: title, eyebrow: eyebrow, lead: lead, classes: classes }), _jsxs("div", { ...slot(classes, 'body'), children: [_jsxs("figure", { ...slot(classes, 'figure'), children: [_jsx("div", { ...slot(classes, 'frame'), style: frame, children: _jsxs("svg", { ...slot(classes, 'map'), viewBox: model.viewBox, "aria-hidden": "true", focusable: "false", children: [_jsx("rect", { "data-layer": "water", width: model.width, height: model.height }), _jsx("use", { "data-layer": "land", href: use('land') }), model.layers.focus.length > 0 ? _jsx("use", { "data-layer": "focus", href: use('focus') }) : null, model.layers.served.length > 0 ? _jsx("use", { "data-layer": "served", href: use('served') }) : null, model.shapes.length > 0 ? (_jsx("g", { "data-layer": "linked", children: model.shapes.map((shape) => (_jsx("a", { href: shape.href, tabIndex: -1, children: _jsx("use", { href: use(shapeId(shape.key)) }) }, shape.key))) })) : null, _jsx("use", { "data-layer": "outline", href: use('outline') }), placed.length > 0 ? (_jsx("g", { "data-layer": "names", fontSize: size, strokeWidth: Math.round(size * 0.2), children: placed.map(({ label, x, y }) => (_jsx("text", { x: x, y: y, "data-state": label.state, children: label.name }, label.key))) })) : null, jobs.length > 0 ? (_jsx("g", { "data-layer": "jobs", strokeWidth: Math.round(marker * 0.35), children: jobs.map((point) => (_jsx("circle", { cx: point.x, cy: point.y, r: marker }, point.slug))) })) : null, base ? (_jsx("rect", { "data-layer": "base", x: base.x - marker, y: base.y - marker, width: marker * 2, height: marker * 2, strokeWidth: Math.round(marker * 0.35) })) : null] }) }), _jsxs("figcaption", { ...slot(classes, 'caption'), children: [caption, legendBase || legendJobs ? (_jsxs("span", { ...slot(classes, 'legend'), children: [legendBase ? (_jsxs("span", { ...slot(classes, 'legendBase'), children: [_jsx("svg", { viewBox: "0 0 12 12", "aria-hidden": "true", focusable: "false", "data-layer": "base", children: _jsx("rect", { x: "2", y: "2", width: "8", height: "8", strokeWidth: "1.5" }) }), legendBase] })) : null, legendJobs ? (_jsxs("span", { ...slot(classes, 'legendJobs'), children: [_jsx("svg", { viewBox: "0 0 12 12", "aria-hidden": "true", focusable: "false", "data-layer": "jobs", children: _jsx("circle", { cx: "6", cy: "6", r: "4.5", strokeWidth: "1.5" }) }), legendJobs] })) : null] })) : null, _jsx("small", { ...slot(classes, 'credit'), children: model.attribution })] })] }), list.length > 0 || regionLink || more ? (_jsxs("div", { ...slot(classes, 'places'), children: [placesTitle && list.length > 0 ? _jsx("h3", { ...slot(classes, 'placesTitle'), children: placesTitle }) : null, _jsx(LinkList, { links: list, kind: "map", layout: layout?.columns !== undefined ? { columns: layout.columns } : undefined, classes: { root: classes?.list } }), regionLink ? (_jsx("p", { ...slot(classes, 'region'), children: _jsx(Link, { href: regionLink.href, prefetch: false, children: regionLink.label }) })) : null, more ? (_jsx("p", { ...slot(classes, 'more'), children: _jsx(Link, { href: more.href, prefetch: false, children: more.label }) })) : null] })) : null] })] }));
145
- }
146
- //# sourceMappingURL=area-map.js.map