@c15t/react 2.0.4 → 2.2.0-canary-20260727202135

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 (332) hide show
  1. package/AGENTS.md +155 -0
  2. package/README.md +29 -14
  3. package/client/components/integrations.js +3 -0
  4. package/dist/components/consent-banner/atoms/overlay.cjs +1 -1
  5. package/dist/components/consent-banner/atoms/root.cjs +1 -1
  6. package/dist/components/consent-banner/components.cjs +1 -1
  7. package/dist/components/consent-banner/consent-banner.cjs +1 -1
  8. package/dist/components/consent-banner/error-boundary.cjs +1 -1
  9. package/dist/components/consent-banner/index.cjs +1 -1
  10. package/dist/components/consent-banner/policy-actions.cjs +1 -1
  11. package/dist/components/consent-dialog/atoms/card.cjs +1 -1
  12. package/dist/components/consent-dialog/atoms/overlay.cjs +1 -1
  13. package/dist/components/consent-dialog/atoms/root.cjs +1 -1
  14. package/dist/components/consent-dialog/consent-dialog.cjs +1 -1
  15. package/dist/components/consent-dialog/index.cjs +1 -1
  16. package/dist/components/consent-dialog-link/index.cjs +1 -1
  17. package/dist/components/consent-dialog-trigger/atoms/button.cjs +1 -1
  18. package/dist/components/consent-dialog-trigger/atoms/button.js +1 -1
  19. package/dist/components/consent-dialog-trigger/atoms/icon.cjs +1 -1
  20. package/dist/components/consent-dialog-trigger/atoms/root.cjs +1 -1
  21. package/dist/components/consent-dialog-trigger/atoms/text.cjs +1 -1
  22. package/dist/components/consent-dialog-trigger/atoms/toolbar.cjs +1 -0
  23. package/dist/components/consent-dialog-trigger/atoms/toolbar.js +1 -0
  24. package/dist/components/consent-dialog-trigger/consent-dialog-trigger-toolbar.cjs +1 -0
  25. package/dist/components/consent-dialog-trigger/consent-dialog-trigger-toolbar.js +1 -0
  26. package/dist/components/consent-dialog-trigger/consent-dialog-trigger.cjs +1 -1
  27. package/dist/components/consent-dialog-trigger/index.cjs +1 -1
  28. package/dist/components/consent-dialog-trigger/index.js +1 -1
  29. package/dist/components/consent-dialog-trigger/use-draggable.cjs +1 -1
  30. package/dist/components/consent-preferences-link/consent-preferences-link.cjs +1 -1
  31. package/dist/components/consent-preferences-link/index.cjs +1 -1
  32. package/dist/components/consent-widget/atoms/accordion.cjs +1 -1
  33. package/dist/components/consent-widget/atoms/button.cjs +1 -1
  34. package/dist/components/consent-widget/atoms/footer.cjs +1 -1
  35. package/dist/components/consent-widget/atoms/root.cjs +1 -1
  36. package/dist/components/consent-widget/consent-widget.cjs +1 -1
  37. package/dist/components/consent-widget/index.cjs +1 -1
  38. package/dist/components/consent-widget/policy-actions.cjs +1 -1
  39. package/dist/components/frame/atoms.cjs +1 -1
  40. package/dist/components/frame/atoms.js +1 -1
  41. package/dist/components/frame/frame.cjs +1 -1
  42. package/dist/components/frame/index.cjs +1 -1
  43. package/dist/components/iab-consent-banner/atoms/button-group.cjs +1 -1
  44. package/dist/components/iab-consent-banner/atoms/card.cjs +1 -1
  45. package/dist/components/iab-consent-banner/atoms/description.cjs +1 -1
  46. package/dist/components/iab-consent-banner/atoms/footer.cjs +1 -1
  47. package/dist/components/iab-consent-banner/atoms/header.cjs +1 -1
  48. package/dist/components/iab-consent-banner/atoms/overlay.cjs +1 -1
  49. package/dist/components/iab-consent-banner/atoms/root.cjs +1 -1
  50. package/dist/components/iab-consent-banner/atoms/title.cjs +1 -1
  51. package/dist/components/iab-consent-banner/iab-consent-banner.cjs +1 -1
  52. package/dist/components/iab-consent-banner/iab-consent-banner.js +1 -1
  53. package/dist/components/iab-consent-banner/index.cjs +1 -1
  54. package/dist/components/iab-consent-dialog/atoms/card.cjs +1 -1
  55. package/dist/components/iab-consent-dialog/atoms/content.cjs +1 -1
  56. package/dist/components/iab-consent-dialog/atoms/footer.cjs +1 -1
  57. package/dist/components/iab-consent-dialog/atoms/header.cjs +1 -1
  58. package/dist/components/iab-consent-dialog/atoms/overlay.cjs +1 -1
  59. package/dist/components/iab-consent-dialog/atoms/purpose-item.cjs +1 -1
  60. package/dist/components/iab-consent-dialog/atoms/root.cjs +1 -1
  61. package/dist/components/iab-consent-dialog/atoms/stack-item.cjs +1 -1
  62. package/dist/components/iab-consent-dialog/atoms/tabs.cjs +1 -1
  63. package/dist/components/iab-consent-dialog/atoms/vendor-list.cjs +1 -1
  64. package/dist/components/iab-consent-dialog/hooks/use-gvl-data.cjs +1 -1
  65. package/dist/components/iab-consent-dialog/iab-consent-dialog.cjs +1 -1
  66. package/dist/components/iab-consent-dialog/index.cjs +1 -1
  67. package/dist/components/iab-consent-dialog/use-iab-translations.cjs +1 -1
  68. package/dist/components/integrations/google-map.cjs +1 -0
  69. package/dist/components/integrations/google-map.js +1 -0
  70. package/dist/components/integrations/index.cjs +1 -0
  71. package/dist/components/integrations/index.js +1 -0
  72. package/dist/components/integrations/shared.cjs +1 -0
  73. package/dist/components/integrations/shared.js +1 -0
  74. package/dist/components/integrations/youtube-embed.cjs +1 -0
  75. package/dist/components/integrations/youtube-embed.js +1 -0
  76. package/dist/components/shared/libs/recursive-clone-children.cjs +1 -1
  77. package/dist/components/shared/libs/slot.cjs +1 -1
  78. package/dist/components/shared/libs/use-controllable-state.cjs +1 -1
  79. package/dist/components/shared/policy-actions.cjs +1 -1
  80. package/dist/components/shared/primitives/box.cjs +1 -1
  81. package/dist/components/shared/primitives/button.cjs +1 -1
  82. package/dist/components/shared/primitives/button.js +1 -1
  83. package/dist/components/shared/primitives/legal-links/index.cjs +1 -1
  84. package/dist/components/shared/primitives/legal-links/index.js +1 -1
  85. package/dist/components/shared/ui/accordion/accordion.cjs +1 -1
  86. package/dist/components/shared/ui/accordion/index.cjs +1 -1
  87. package/dist/components/shared/ui/animated-collapse/animated-collapse.cjs +1 -1
  88. package/dist/components/shared/ui/animated-collapse/index.cjs +1 -1
  89. package/dist/components/shared/ui/branding.cjs +1 -1
  90. package/dist/components/shared/ui/button/button.cjs +1 -1
  91. package/dist/components/shared/ui/button/index.cjs +1 -1
  92. package/dist/components/shared/ui/collapsible/collapsible.cjs +1 -1
  93. package/dist/components/shared/ui/collapsible/index.cjs +1 -1
  94. package/dist/components/shared/ui/dialog/dialog.cjs +1 -1
  95. package/dist/components/shared/ui/dialog/index.cjs +1 -1
  96. package/dist/components/shared/ui/icon.cjs +1 -1
  97. package/dist/components/shared/ui/logo.cjs +1 -1
  98. package/dist/components/shared/ui/preference-item/index.cjs +1 -1
  99. package/dist/components/shared/ui/preference-item/preference-item.cjs +1 -1
  100. package/dist/components/shared/ui/switch/index.cjs +1 -1
  101. package/dist/components/shared/ui/switch/switch.cjs +1 -1
  102. package/dist/components/shared/ui/tabs/index.cjs +1 -1
  103. package/dist/components/shared/ui/tabs/tabs.cjs +1 -1
  104. package/dist/context/consent-manager-context.cjs +1 -1
  105. package/dist/context/consent-tracking-context.cjs +1 -1
  106. package/dist/context/theme-context.cjs +1 -1
  107. package/dist/headless.cjs +1 -1
  108. package/dist/headless.js +1 -1
  109. package/dist/hooks/index.cjs +1 -1
  110. package/dist/hooks/index.js +1 -1
  111. package/dist/hooks/use-color-scheme.cjs +1 -1
  112. package/dist/hooks/use-component-config.cjs +1 -1
  113. package/dist/hooks/use-consent-dialog-trigger.cjs +1 -1
  114. package/dist/hooks/use-consent-manager.cjs +1 -1
  115. package/dist/hooks/use-consent-script.cjs +1 -0
  116. package/dist/hooks/use-consent-script.js +1 -0
  117. package/dist/hooks/use-focus-trap.cjs +1 -1
  118. package/dist/hooks/use-headless-consent-ui.cjs +1 -1
  119. package/dist/hooks/use-headless-iab-consent-ui.cjs +1 -1
  120. package/dist/hooks/use-reduced-motion.cjs +1 -1
  121. package/dist/hooks/use-scroll-lock.cjs +1 -1
  122. package/dist/hooks/use-ssr-status.cjs +1 -1
  123. package/dist/hooks/use-styles.cjs +1 -1
  124. package/dist/hooks/use-text-direction.cjs +1 -1
  125. package/dist/hooks/use-theme.cjs +1 -1
  126. package/dist/hooks/use-translations.cjs +1 -1
  127. package/dist/iab.cjs +1 -1
  128. package/dist/index.cjs +1 -1
  129. package/dist/index.js +1 -1
  130. package/dist/primitives/accordion.cjs +1 -1
  131. package/dist/primitives/button.cjs +1 -1
  132. package/dist/primitives/collapsible.cjs +1 -1
  133. package/dist/primitives/dialog.cjs +1 -1
  134. package/dist/primitives/preference-item.cjs +1 -1
  135. package/dist/primitives/switch.cjs +1 -1
  136. package/dist/primitives/tabs.cjs +1 -1
  137. package/dist/primitives.cjs +1 -1
  138. package/dist/providers/consent-manager-provider.cjs +1 -1
  139. package/dist/server/fetch-ssr-data.cjs +1 -1
  140. package/dist/server/fetch-ssr-data.js +1 -1
  141. package/dist/server/headers.cjs +1 -1
  142. package/dist/server/headers.js +1 -1
  143. package/dist/server/index.cjs +1 -1
  144. package/dist/server/init-cache-key.cjs +1 -1
  145. package/dist/server/normalize-url.cjs +1 -1
  146. package/dist/styles.tw3.css +1 -1
  147. package/dist/types/theme/index.cjs +1 -1
  148. package/dist/types/theme/style-types.cjs +1 -1
  149. package/dist/utils/cn.cjs +1 -1
  150. package/dist/utils/merge-styles.cjs +1 -1
  151. package/dist/utils/test-helpers.cjs +1 -1
  152. package/dist/utils/theme-utils.cjs +1 -1
  153. package/dist/version.cjs +1 -1
  154. package/dist/version.js +1 -1
  155. package/dist-types/components/consent-banner/components.d.ts +2 -2
  156. package/dist-types/components/consent-banner/policy-actions.d.ts +1 -1
  157. package/dist-types/components/consent-dialog/atoms/card.d.ts +5 -5
  158. package/dist-types/components/consent-dialog-trigger/atoms/toolbar.d.ts +22 -0
  159. package/dist-types/components/consent-dialog-trigger/consent-dialog-trigger-toolbar.d.ts +35 -0
  160. package/dist-types/components/consent-dialog-trigger/index.d.ts +2 -1
  161. package/dist-types/components/consent-dialog-trigger/types.d.ts +111 -6
  162. package/dist-types/components/consent-widget/atoms/accordion.d.ts +4 -4
  163. package/dist-types/components/consent-widget/consent-widget.d.ts +1 -1
  164. package/dist-types/components/consent-widget/policy-actions.d.ts +1 -1
  165. package/dist-types/components/integrations/google-map.d.ts +82 -0
  166. package/dist-types/components/integrations/index.d.ts +2 -0
  167. package/dist-types/components/integrations/shared.d.ts +12 -0
  168. package/dist-types/components/integrations/youtube-embed.d.ts +95 -0
  169. package/dist-types/components/shared/policy-actions.d.ts +1 -1
  170. package/dist-types/components/shared/primitives/button.d.ts +36 -2
  171. package/dist-types/components/shared/primitives/legal-links/index.d.ts +1 -1
  172. package/dist-types/components/shared/ui/accordion/accordion.d.ts +2 -2
  173. package/dist-types/components/shared/ui/branding.d.ts +3 -3
  174. package/dist-types/components/shared/ui/button/button.d.ts +1 -1
  175. package/dist-types/components/shared/ui/dialog/dialog.d.ts +1 -1
  176. package/dist-types/components/shared/ui/logo.d.ts +8 -8
  177. package/dist-types/headless.d.ts +1 -0
  178. package/dist-types/hooks/index.d.ts +1 -0
  179. package/dist-types/hooks/use-consent-script.d.ts +80 -0
  180. package/dist-types/index.d.ts +3 -1
  181. package/dist-types/providers/consent-manager-provider.d.ts +1 -1
  182. package/dist-types/server/headers.d.ts +1 -1
  183. package/dist-types/utils/theme-utils.d.ts +1 -1
  184. package/dist-types/version.d.ts +1 -1
  185. package/docs/README.md +155 -76
  186. package/docs/{building-headless-components.md → frameworks/react/building-headless-components.md} +3 -1
  187. package/docs/{callbacks.md → frameworks/react/callbacks.md} +3 -1
  188. package/docs/{components → frameworks/react/components}/consent-banner.md +10 -21
  189. package/docs/{components → frameworks/react/components}/consent-dialog-link.md +8 -5
  190. package/docs/frameworks/react/components/consent-dialog-trigger.md +202 -0
  191. package/docs/{components → frameworks/react/components}/consent-dialog.md +7 -15
  192. package/docs/frameworks/react/components/consent-manager-provider.md +228 -0
  193. package/docs/{components → frameworks/react/components}/consent-widget.md +8 -6
  194. package/docs/{components → frameworks/react/components}/dev-tools.md +9 -6
  195. package/docs/{components → frameworks/react/components}/frame.md +8 -9
  196. package/docs/{concepts → frameworks/react/concepts}/client-modes.md +4 -2
  197. package/docs/{concepts → frameworks/react/concepts}/consent-categories.md +1 -0
  198. package/docs/{concepts → frameworks/react/concepts}/consent-models.md +1 -0
  199. package/docs/{concepts → frameworks/react/concepts}/cookie-management.md +3 -3
  200. package/docs/{concepts → frameworks/react/concepts}/glossary.md +1 -0
  201. package/docs/{concepts → frameworks/react/concepts}/initialization-flow.md +1 -0
  202. package/docs/{concepts → frameworks/react/concepts}/policy-packs.md +1 -0
  203. package/docs/{headless.md → frameworks/react/headless.md} +3 -1
  204. package/docs/{hooks → frameworks/react/hooks}/use-color-scheme.md +1 -0
  205. package/docs/{hooks → frameworks/react/hooks}/use-consent-manager/checking-consent.md +3 -1
  206. package/docs/{hooks → frameworks/react/hooks}/use-consent-manager/location-info.md +3 -1
  207. package/docs/frameworks/react/hooks/use-consent-manager/overview.md +172 -0
  208. package/docs/{hooks → frameworks/react/hooks}/use-consent-manager/setting-consent.md +3 -1
  209. package/docs/{hooks → frameworks/react/hooks}/use-draggable.md +3 -1
  210. package/docs/{hooks → frameworks/react/hooks}/use-focus-trap.md +1 -0
  211. package/docs/{hooks → frameworks/react/hooks}/use-reduced-motion.md +3 -1
  212. package/docs/{hooks → frameworks/react/hooks}/use-ssr-status.md +6 -5
  213. package/docs/{hooks → frameworks/react/hooks}/use-text-direction.md +1 -0
  214. package/docs/frameworks/react/hooks/use-translations.md +55 -0
  215. package/docs/{iab → frameworks/react/iab}/consent-banner.md +9 -12
  216. package/docs/{iab → frameworks/react/iab}/consent-dialog.md +9 -14
  217. package/docs/{iab → frameworks/react/iab}/overview.md +4 -2
  218. package/docs/{iab → frameworks/react/iab}/use-gvl-data.md +3 -2
  219. package/docs/{iframe-blocking.md → frameworks/react/iframe-blocking.md} +8 -9
  220. package/docs/{internationalization.md → frameworks/react/internationalization.md} +13 -3
  221. package/docs/{network-blocker.md → frameworks/react/network-blocker.md} +13 -51
  222. package/docs/{optimization.md → frameworks/react/optimization.md} +3 -2
  223. package/docs/{policy-packs.md → frameworks/react/policy-packs.md} +3 -1
  224. package/docs/{quickstart.md → frameworks/react/quickstart.md} +26 -42
  225. package/docs/frameworks/react/script-loader.md +553 -0
  226. package/docs/{server-side.md → frameworks/react/server-side.md} +9 -4
  227. package/docs/{styling → frameworks/react/styling}/classnames.md +3 -1
  228. package/docs/{styling → frameworks/react/styling}/color-scheme.md +3 -1
  229. package/docs/frameworks/react/styling/css-variables.md +53 -0
  230. package/docs/frameworks/react/styling/overview.md +302 -0
  231. package/docs/frameworks/react/styling/slots.md +94 -0
  232. package/docs/{styling → frameworks/react/styling}/tailwind.md +3 -1
  233. package/docs/frameworks/react/styling/tokens.md +156 -0
  234. package/docs/{troubleshooting.md → frameworks/react/troubleshooting.md} +3 -1
  235. package/docs/integrations/adobe-analytics.md +160 -0
  236. package/docs/integrations/ahrefs-analytics.md +157 -0
  237. package/docs/integrations/amplitude.md +230 -0
  238. package/docs/integrations/building-integrations.md +15 -181
  239. package/docs/integrations/clearbit.md +130 -0
  240. package/docs/integrations/cloudflare-web-analytics.md +126 -0
  241. package/docs/integrations/crisp.md +140 -0
  242. package/docs/integrations/databuddy.md +152 -150
  243. package/docs/integrations/fathom-analytics.md +150 -0
  244. package/docs/integrations/google-maps.md +263 -0
  245. package/docs/integrations/google-tag-manager.md +102 -101
  246. package/docs/integrations/google-tag.md +104 -92
  247. package/docs/integrations/heap.md +219 -0
  248. package/docs/integrations/hightouch.md +199 -0
  249. package/docs/integrations/hotjar.md +143 -0
  250. package/docs/integrations/intercom.md +144 -0
  251. package/docs/integrations/linkedin-insights.md +142 -90
  252. package/docs/integrations/logrocket.md +175 -0
  253. package/docs/integrations/matomo-analytics.md +171 -0
  254. package/docs/integrations/meta-pixel.md +379 -309
  255. package/docs/integrations/microsoft-clarity.md +173 -0
  256. package/docs/integrations/microsoft-uet.md +135 -91
  257. package/docs/integrations/mixpanel-analytics.md +130 -0
  258. package/docs/integrations/overview.md +119 -75
  259. package/docs/integrations/pirsch.md +142 -0
  260. package/docs/integrations/plausible-analytics.md +154 -0
  261. package/docs/integrations/posthog.md +186 -127
  262. package/docs/integrations/promptwatch.md +121 -0
  263. package/docs/integrations/reddit-pixel.md +241 -0
  264. package/docs/integrations/rudderstack.md +271 -0
  265. package/docs/integrations/rybbit-analytics.md +143 -0
  266. package/docs/integrations/segment.md +146 -0
  267. package/docs/integrations/snapchat-pixel.md +163 -0
  268. package/docs/integrations/tiktok-pixel.md +101 -91
  269. package/docs/integrations/umami-analytics.md +148 -0
  270. package/docs/integrations/vercel-analytics.md +141 -0
  271. package/docs/integrations/x-pixel.md +123 -109
  272. package/docs/integrations/youtube.md +193 -0
  273. package/docs/shared/concepts/client-modes.md +103 -0
  274. package/docs/shared/concepts/consent-categories.md +41 -0
  275. package/docs/shared/concepts/consent-models.md +72 -0
  276. package/docs/shared/concepts/cookie-management.md +88 -0
  277. package/docs/shared/concepts/glossary.md +24 -0
  278. package/docs/shared/concepts/initialization-flow.md +105 -0
  279. package/docs/shared/concepts/policy-packs.md +225 -0
  280. package/docs/shared/react/components/consent-banner.md +242 -0
  281. package/docs/shared/react/components/consent-dialog-link.md +45 -0
  282. package/docs/shared/react/components/consent-dialog-trigger.md +185 -0
  283. package/docs/shared/react/components/consent-dialog.md +119 -0
  284. package/docs/shared/react/components/consent-manager-provider.md +183 -0
  285. package/docs/shared/react/components/consent-widget.md +121 -0
  286. package/docs/shared/react/components/dev-tools.md +81 -0
  287. package/docs/shared/react/components/frame.md +52 -0
  288. package/docs/shared/react/guides/building-headless-components.md +110 -0
  289. package/docs/shared/react/guides/callbacks.md +89 -0
  290. package/docs/shared/react/guides/headless.md +31 -0
  291. package/docs/shared/react/guides/iframe-blocking.md +65 -0
  292. package/docs/shared/react/guides/internationalization.md +123 -0
  293. package/docs/shared/react/guides/network-blocker.md +72 -0
  294. package/docs/shared/react/guides/optimization.md +44 -0
  295. package/docs/shared/react/guides/policy-packs.md +173 -0
  296. package/docs/shared/react/guides/script-loader.md +309 -0
  297. package/docs/shared/react/hooks/use-color-scheme.md +31 -0
  298. package/docs/shared/react/hooks/use-consent-manager/checking-consent.md +95 -0
  299. package/docs/shared/react/hooks/use-consent-manager/location-info.md +96 -0
  300. package/docs/shared/react/hooks/use-consent-manager/overview.md +74 -0
  301. package/docs/shared/react/hooks/use-consent-manager/setting-consent.md +93 -0
  302. package/docs/shared/react/hooks/use-draggable.md +30 -0
  303. package/docs/shared/react/hooks/use-focus-trap.md +20 -0
  304. package/docs/shared/react/hooks/use-reduced-motion.md +33 -0
  305. package/docs/shared/react/hooks/use-ssr-status.md +16 -0
  306. package/docs/shared/react/hooks/use-text-direction.md +38 -0
  307. package/docs/shared/react/hooks/use-translations.md +15 -0
  308. package/docs/shared/react/iab/consent-banner.md +60 -0
  309. package/docs/shared/react/iab/consent-dialog.md +76 -0
  310. package/docs/shared/react/iab/overview.md +80 -0
  311. package/docs/shared/react/iab/use-gvl-data.md +21 -0
  312. package/docs/shared/react/styling/classnames.md +93 -0
  313. package/docs/shared/react/styling/color-scheme.md +35 -0
  314. package/docs/shared/react/styling/css-variables.md +53 -0
  315. package/docs/shared/react/styling/overview.md +261 -0
  316. package/docs/shared/react/styling/slots.md +93 -0
  317. package/docs/shared/react/styling/stylesheet-entrypoint.md +8 -0
  318. package/docs/shared/react/styling/tailwind.md +88 -0
  319. package/docs/shared/react/styling/tokens.md +155 -0
  320. package/docs/shared/troubleshooting.md +82 -0
  321. package/package.json +23 -12
  322. package/readme.json +12 -7
  323. package/docs/ai-agents.md +0 -111
  324. package/docs/components/consent-dialog-trigger.md +0 -103
  325. package/docs/components/consent-manager-provider.md +0 -425
  326. package/docs/hooks/use-consent-manager/overview.md +0 -420
  327. package/docs/hooks/use-translations.md +0 -118
  328. package/docs/script-loader.md +0 -321
  329. package/docs/styling/css-variables.md +0 -92
  330. package/docs/styling/overview.md +0 -460
  331. package/docs/styling/slots.md +0 -128
  332. package/docs/styling/tokens.md +0 -216
@@ -5,7 +5,7 @@ export interface DialogRootProps {
5
5
  onOpenChange?: (open: boolean) => void;
6
6
  open?: boolean;
7
7
  }
8
- declare function DialogRoot({ children, defaultOpen, onOpenChange, open, }: DialogRootProps): import("react/jsx-runtime").JSX.Element;
8
+ declare function DialogRoot({ children, defaultOpen, onOpenChange, open, }: DialogRootProps): import("react").JSX.Element;
9
9
  export interface DialogTriggerProps extends Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'type'> {
10
10
  asChild?: boolean;
11
11
  }
@@ -7,20 +7,20 @@ interface IconProps {
7
7
  * c15t icon only (without text).
8
8
  * Use this for compact displays like the floating trigger.
9
9
  */
10
- export declare const C15TIconOnly: ({ title, titleId, ...props }: SVGProps<SVGSVGElement> & IconProps) => import("react/jsx-runtime").JSX.Element;
10
+ export declare const C15TIconOnly: ({ title, titleId, ...props }: SVGProps<SVGSVGElement> & IconProps) => import("react").JSX.Element;
11
11
  /**
12
12
  * c15t full logo with text.
13
13
  * Use this for branding displays.
14
14
  */
15
- export declare const C15TIcon: ({ title, titleId, ...props }: SVGProps<SVGSVGElement> & IconProps) => import("react/jsx-runtime").JSX.Element;
15
+ export declare const C15TIcon: ({ title, titleId, ...props }: SVGProps<SVGSVGElement> & IconProps) => import("react").JSX.Element;
16
16
  /**
17
17
  * INTH logo for partner branding displays.
18
18
  */
19
- export declare const InthLogo: (props: SVGProps<SVGSVGElement> & IconProps) => import("react/jsx-runtime").JSX.Element;
19
+ export declare const InthLogo: (props: SVGProps<SVGSVGElement> & IconProps) => import("react").JSX.Element;
20
20
  /**
21
21
  * INTH icon-only mark for compact placements like floating triggers.
22
22
  */
23
- export declare const InthIconOnly: (props: SVGProps<SVGSVGElement> & IconProps) => import("react/jsx-runtime").JSX.Element;
23
+ export declare const InthIconOnly: (props: SVGProps<SVGSVGElement> & IconProps) => import("react").JSX.Element;
24
24
  /**
25
25
  * Wordmark logo for the hosted consent product (inth.com).
26
26
  *
@@ -31,20 +31,20 @@ export declare const InthIconOnly: (props: SVGProps<SVGSVGElement> & IconProps)
31
31
  * @param title - Accessible title announced to screen readers. Defaults to "Consent".
32
32
  * @param titleId - DOM id for the SVG `<title>` element. Must be unique on the page when rendered more than once.
33
33
  */
34
- export declare const ConsentLogo: ({ title, titleId, ...props }: SVGProps<SVGSVGElement> & IconProps) => import("react/jsx-runtime").JSX.Element;
34
+ export declare const ConsentLogo: ({ title, titleId, ...props }: SVGProps<SVGSVGElement> & IconProps) => import("react").JSX.Element;
35
35
  /**
36
36
  * Consent icon only (without text).
37
37
  * Use this for compact displays like the preference center footer.
38
38
  */
39
- export declare const ConsentIconOnly: ({ title, titleId, ...props }: SVGProps<SVGSVGElement> & IconProps) => import("react/jsx-runtime").JSX.Element;
39
+ export declare const ConsentIconOnly: ({ title, titleId, ...props }: SVGProps<SVGSVGElement> & IconProps) => import("react").JSX.Element;
40
40
  /**
41
41
  * Fingerprint icon for privacy/consent contexts.
42
42
  * A generic icon representing user identity and privacy.
43
43
  */
44
- export declare const FingerprintIcon: ({ title, titleId, ...props }: SVGProps<SVGSVGElement> & IconProps) => import("react/jsx-runtime").JSX.Element;
44
+ export declare const FingerprintIcon: ({ title, titleId, ...props }: SVGProps<SVGSVGElement> & IconProps) => import("react").JSX.Element;
45
45
  /**
46
46
  * Settings/gear icon for preference contexts.
47
47
  * A generic icon representing configuration and settings.
48
48
  */
49
- export declare const SettingsIcon: ({ title, titleId, ...props }: SVGProps<SVGSVGElement> & IconProps) => import("react/jsx-runtime").JSX.Element;
49
+ export declare const SettingsIcon: ({ title, titleId, ...props }: SVGProps<SVGSVGElement> & IconProps) => import("react").JSX.Element;
50
50
  export {};
@@ -2,6 +2,7 @@ export { type ConsentManagerInterface, configureConsentManager, defaultTranslati
2
2
  export { useColorScheme } from './hooks/use-color-scheme';
3
3
  export { type ConsentDialogTriggerVisibility, type UseConsentDialogTriggerOptions, type UseConsentDialogTriggerResult, useConsentDialogTrigger, } from './hooks/use-consent-dialog-trigger';
4
4
  export { useConsentManager } from './hooks/use-consent-manager';
5
+ export { ConsentScriptConflictError, type ConsentScriptReadyControls, type ConsentScriptStatus, type ConsentScriptUnmountBehavior, type UseConsentScriptOptions, type UseConsentScriptResult, useConsentScript, } from './hooks/use-consent-script';
5
6
  export { useFocusTrap } from './hooks/use-focus-trap';
6
7
  export { type HeadlessConsentBannerAction, type HeadlessConsentBannerState, type HeadlessConsentDialogAction, type HeadlessConsentDialogState, type HeadlessConsentSurface, type HeadlessConsentSurfaceAction, type HeadlessConsentSurfaceState, type HeadlessConsentWriteAction, type UseHeadlessConsentUIResult, useHeadlessConsentUI, } from './hooks/use-headless-consent-ui';
7
8
  export { useTranslations } from './hooks/use-translations';
@@ -1,6 +1,7 @@
1
1
  export * from './use-component-config';
2
2
  export * from './use-consent-dialog-trigger';
3
3
  export * from './use-consent-manager';
4
+ export * from './use-consent-script';
4
5
  export * from './use-focus-trap';
5
6
  export * from './use-headless-consent-ui';
6
7
  export * from './use-headless-iab-consent-ui';
@@ -0,0 +1,80 @@
1
+ import type { Script } from 'c15t';
2
+ export type ConsentScriptStatus = 'idle' | 'blocked' | 'loading' | 'ready' | 'error';
3
+ export type ConsentScriptUnmountBehavior = 'keep' | 'remove';
4
+ export declare class ConsentScriptConflictError extends Error {
5
+ readonly scriptId: string;
6
+ constructor(scriptId: string);
7
+ }
8
+ export interface ConsentScriptReadyControls<TReady> {
9
+ resolve: (value: TReady) => void;
10
+ reject: (error: Error) => void;
11
+ }
12
+ export interface UseConsentScriptOptions<TReady = unknown> {
13
+ /**
14
+ * Script configuration registered with c15t's script manager.
15
+ */
16
+ script: Script;
17
+ /**
18
+ * Whether this hook should register the script.
19
+ *
20
+ * @default true
21
+ */
22
+ enabled?: boolean;
23
+ /**
24
+ * Returns the SDK object when it is already available.
25
+ */
26
+ resolveReady?: () => TReady | false | null | undefined;
27
+ /**
28
+ * Registers callback-based SDK readiness, such as `callback=` query params.
29
+ * The returned cleanup function runs after readiness settles or the registry
30
+ * entry is released.
31
+ */
32
+ registerReadyCallback?: (controls: ConsentScriptReadyControls<TReady>) => undefined | (() => void);
33
+ /**
34
+ * Semantic key for the SDK readiness contract shared by this script id.
35
+ *
36
+ * Consumers of the same script id must use the same key. Set this when the
37
+ * readiness callbacks are configured differently from the script itself.
38
+ *
39
+ * @default script.id
40
+ */
41
+ readinessKey?: string;
42
+ /**
43
+ * Optional timeout for SDK readiness after the script is registered.
44
+ */
45
+ timeoutMs?: number;
46
+ /**
47
+ * Changing this value retries a failed registration with the same script id.
48
+ * Successful singleton registrations remain shared.
49
+ *
50
+ * @default 0
51
+ */
52
+ retryKey?: string | number;
53
+ /**
54
+ * Whether c15t should retain an owned script registration after the final
55
+ * hook consumer unmounts. Use `keep` for page-level singleton SDKs that
56
+ * cannot safely be loaded more than once.
57
+ *
58
+ * @default 'remove'
59
+ */
60
+ unmountBehavior?: ConsentScriptUnmountBehavior;
61
+ }
62
+ export interface UseConsentScriptResult<TReady = unknown> {
63
+ status: ConsentScriptStatus;
64
+ scriptId: string;
65
+ hasConsent: boolean;
66
+ scriptAppended: boolean;
67
+ readyValue: TReady | null;
68
+ error: Error | null;
69
+ ready: Promise<TReady> | null;
70
+ }
71
+ /**
72
+ * Registers a consent-gated script through c15t and exposes SDK readiness as a promise.
73
+ *
74
+ * @remarks
75
+ * Registrations are shared within one ConsentManagerProvider. The hook adopts
76
+ * compatible scripts already registered with that manager and never removes
77
+ * registrations it does not own. Inline script objects and callbacks are safe:
78
+ * lifecycle callbacks are read from the latest render without re-registering.
79
+ */
80
+ export declare function useConsentScript<TReady = unknown>(options: UseConsentScriptOptions<TReady>): UseConsentScriptResult<TReady>;
@@ -4,13 +4,15 @@ export { ConsentBanner, type ConsentBannerProps, } from './components/consent-ba
4
4
  export * from './components/consent-banner/components';
5
5
  export { ConsentDialog, type ConsentDialogProps, } from './components/consent-dialog';
6
6
  export { ConsentDialogLink, type ConsentDialogLinkProps, } from './components/consent-dialog-link';
7
- export { ConsentDialogTrigger, type ConsentDialogTriggerCompound, type ConsentDialogTriggerProps, TriggerButton, type TriggerButtonProps, TriggerIcon, type TriggerIconProps, type TriggerIconType, TriggerRoot, type TriggerRootProps, type TriggerSize, TriggerText, type TriggerTextProps, type TriggerVisibility, type UseDraggableOptions, type UseDraggableReturn, useDraggable, useTriggerContext, } from './components/consent-dialog-trigger';
7
+ export { ConsentDialogTrigger, type ConsentDialogTriggerCompound, type ConsentDialogTriggerProps, ConsentDialogTriggerToolbar, type ConsentDialogTriggerToolbarAction, type ConsentDialogTriggerToolbarPreferences, type ConsentDialogTriggerToolbarProps, TriggerButton, type TriggerButtonProps, TriggerIcon, type TriggerIconProps, type TriggerIconType, type TriggerOrientation, TriggerRoot, type TriggerRootProps, type TriggerSize, TriggerText, type TriggerTextProps, type TriggerVisibility, type UseDraggableOptions, type UseDraggableReturn, useDraggable, useTriggerContext, } from './components/consent-dialog-trigger';
8
8
  export { ConsentWidget, type ConsentWidgetProps, } from './components/consent-widget';
9
9
  export { Frame, type FrameProps } from './components/frame';
10
+ export { GoogleMap, type GoogleMapCoordinates, type GoogleMapInstance, type GoogleMapOptions, type GoogleMapProps, type GoogleMapsApi, type GoogleMapsLibrary, YouTubeEmbed, type YouTubeEmbedParams, type YouTubeEmbedProps, type YouTubeSrcSource, type YouTubeVideoIdSource, } from './components/integrations';
10
11
  export { ConsentButton } from './components/shared/primitives/button';
11
12
  export { useColorScheme } from './hooks/use-color-scheme';
12
13
  export { type ConsentDialogTriggerVisibility, type UseConsentDialogTriggerOptions, type UseConsentDialogTriggerResult, useConsentDialogTrigger, } from './hooks/use-consent-dialog-trigger';
13
14
  export { useConsentManager } from './hooks/use-consent-manager';
15
+ export { ConsentScriptConflictError, type ConsentScriptReadyControls, type ConsentScriptStatus, type ConsentScriptUnmountBehavior, type UseConsentScriptOptions, type UseConsentScriptResult, useConsentScript, } from './hooks/use-consent-script';
14
16
  export { useFocusTrap } from './hooks/use-focus-trap';
15
17
  export { type HeadlessConsentBannerAction, type HeadlessConsentBannerState, type HeadlessConsentDialogAction, type HeadlessConsentDialogState, type HeadlessConsentSurface, type HeadlessConsentSurfaceAction, type HeadlessConsentSurfaceState, type HeadlessConsentWriteAction, type UseHeadlessConsentUIResult, useHeadlessConsentUI, } from './hooks/use-headless-consent-ui';
16
18
  export { useSSRStatus } from './hooks/use-ssr-status';
@@ -37,4 +37,4 @@ export declare function clearConsentRuntimeCache(): void;
37
37
  *
38
38
  * @public
39
39
  */
40
- export declare function ConsentManagerProvider({ children, options, }: ConsentManagerProviderProps): import("react/jsx-runtime").JSX.Element;
40
+ export declare function ConsentManagerProvider({ children, options, }: ConsentManagerProviderProps): import("react").JSX.Element;
@@ -1,4 +1,4 @@
1
- declare const FORWARDED_HEADERS: readonly ["cf-ipcountry", "x-vercel-ip-country", "x-amz-cf-ipcountry", "x-country-code", "x-vercel-ip-country-region", "x-region-code", "accept-language", "user-agent", "x-forwarded-host", "x-forwarded-for", "sec-gpc", "purpose", "sec-purpose", "next-router-prefetch", "x-middleware-prefetch"];
1
+ declare const FORWARDED_HEADERS: readonly ["cf-ipcountry", "x-vercel-ip-country", "x-amz-cf-ipcountry", "x-country-code", "x-vercel-ip-country-region", "x-region-code", "x-c15t-version", "accept-language", "user-agent", "x-forwarded-host", "x-forwarded-for", "sec-gpc", "purpose", "sec-purpose", "next-router-prefetch", "x-middleware-prefetch"];
2
2
  type ForwardedHeader = (typeof FORWARDED_HEADERS)[number] | 'x-c15t-country' | 'x-c15t-region';
3
3
  type RelevantHeaders = Partial<Record<ForwardedHeader, string>>;
4
4
  /**
@@ -7,7 +7,7 @@ import type { Theme } from '../types/theme/style-types';
7
7
  /**
8
8
  * Default design tokens for the v2 theme system.
9
9
  */
10
- export declare const defaultTheme: Required<Omit<Theme, "slots">>;
10
+ export declare const defaultTheme: Required<Omit<Theme, 'slots'>>;
11
11
  /**
12
12
  * Maps theme tokens to CSS variables.
13
13
  */
@@ -1 +1 @@
1
- export declare const version = "2.0.4";
1
+ export declare const version = "2.2.0-canary-20260727202135";
package/docs/README.md CHANGED
@@ -1,76 +1,155 @@
1
- # c15t React Docs
2
-
3
- React-focused c15t docs for consent UI, hooks, headless flows, and script integrations.
4
-
5
- If you are changing consent flows, consent UI, script loading, server-side setup, or backend configuration in an app that uses this package, start here before editing code.
6
-
7
- ## Start Here
8
-
9
- - [Quickstart](./quickstart.md)
10
- - [Headless](./headless.md)
11
- - [Building Headless Components](./building-headless-components.md)
12
- - [Callbacks](./callbacks.md)
13
- - [Google Tag Manager](./integrations/google-tag-manager.md)
14
-
15
- ## Workflow Rules
16
-
17
- ### Styling
18
-
19
- Use this when:
20
- - customizing component appearance
21
- - adapting c15t components to a design system
22
- - deciding how far to override the default UI
23
-
24
- Prefer:
25
- - Prefer design tokens first.
26
- - If tokens are not enough, use component slots.
27
- - Then use CSS variables or `className` for targeted overrides.
28
-
29
- If that is not enough:
30
- - Use `noStyle` or a full headless rebuild only when the design system cannot be expressed through the supported styling layers.
31
-
32
- Avoid:
33
- - Do not rebuild the consent UI from scratch if tokens, slots, or scoped overrides are sufficient.
34
-
35
- Read next:
36
- - [Overview](./styling/overview.md)
37
- - [Tokens](./styling/tokens.md)
38
- - [Slots](./styling/slots.md)
39
- - [Css Variables](./styling/css-variables.md)
40
-
41
- ### Consent UI Customization
42
-
43
- Use this when:
44
- - changing banners, dialogs, or preference centers
45
- - deciding between built-in components and headless APIs
46
-
47
- Prefer:
48
- - Prefer the built-in components and their documented customization surfaces first.
49
- - If the UI requirements diverge significantly, use the headless APIs.
50
-
51
- Avoid:
52
- - Do not rebuild the full consent flow if a token, slot, or component override is enough.
53
-
54
- Read next:
55
- - [Quickstart](./quickstart.md)
56
- - [Consent Banner](./components/consent-banner.md)
57
- - [Headless](./headless.md)
58
- - [Building Headless Components](./building-headless-components.md)
59
-
60
- ### Scripts & Integrations
61
-
62
- Use this when:
63
- - adding third-party scripts in React components or providers
64
- - wiring analytics or advertising behind consent
65
-
66
- Prefer:
67
- - Prefer premade scripts from `@c15t/scripts/*`.
68
- - Start from the integration docs before implementing custom script wiring in React components.
69
-
70
- Avoid:
71
- - Do not duplicate consent-sync logic in React effects when the integration already handles it.
72
-
73
- Read next:
74
- - [Script Loader](./script-loader.md)
75
- - [Google Tag Manager](./integrations/google-tag-manager.md)
76
- - [Meta Pixel](./integrations/meta-pixel.md)
1
+ # @c15t/react
2
+
3
+ > React consent management docs for c15t, including consent UI, hooks, styling, script loading, and integrations.
4
+
5
+ These docs ship inside the package so coding agents can read them offline. Open the topic file you need from the list below paths are relative to this file.
6
+
7
+ ## Frameworks
8
+
9
+ Install and configure c15t in JavaScript, React, and Next.js applications.
10
+
11
+ - [Building Headless Components](./frameworks/react/building-headless-components.md): Build policy-aware custom consent components in React using the headless hooks and policy-pack tooling.
12
+ - [Callbacks](./frameworks/react/callbacks.md): React to consent lifecycle events - initialization, consent changes, errors, and revocation reloads.
13
+ - [ConsentBanner](./frameworks/react/components/consent-banner.md): A pre-built consent banner that appears when user consent is needed. Supports policy-aware layout, theming, and advanced composition when markup must change.
14
+ - [ConsentDialog](./frameworks/react/components/consent-dialog.md): A modal dialog where users can toggle individual consent categories.
15
+ - [ConsentDialogLink](./frameworks/react/components/consent-dialog-link.md): An inline trigger for opening the consent dialog from footers, legal pages, and account settings.
16
+ - [ConsentDialogTrigger](./frameworks/react/components/consent-dialog-trigger.md): A floating, draggable button that lets users re-open the consent dialog at any time.
17
+ - [ConsentManagerProvider](./frameworks/react/components/consent-manager-provider.md): The root provider component that initializes the consent system and makes consent state available to all child components.
18
+ - [ConsentWidget](./frameworks/react/components/consent-widget.md): An inline consent management widget for embedding in settings or privacy pages. Shows category toggles with accordion layout.
19
+ - [DevTools](./frameworks/react/components/dev-tools.md): A development tool for inspecting consent state, geolocation, loaded scripts, and consent events in real time.
20
+ - [Frame](./frameworks/react/components/frame.md): A consent-gated content wrapper - children only mount when the required consent category is granted.
21
+ - [Client Modes](./frameworks/react/concepts/client-modes.md): Choose how c15t connects to its backend - full hosted integration, offline-only, or bring your own backend.
22
+ - [Consent Categories](./frameworks/react/concepts/consent-categories.md): How c15t organizes tracking technologies into five consent categories.
23
+ - [Consent Models](./frameworks/react/concepts/consent-models.md): How c15t determines consent behavior based on legal jurisdiction.
24
+ - [Cookie Management](./frameworks/react/concepts/cookie-management.md): How c15t manages cookies through script, iframe, and network gating
25
+ - [Glossary](./frameworks/react/concepts/glossary.md): Key terms used throughout the c15t documentation.
26
+ - [Initialization Flow](./frameworks/react/concepts/initialization-flow.md): What happens from provider mount to first render — the full consent lifecycle.
27
+ - [Policy Packs](./frameworks/react/concepts/policy-packs.md): How c15t resolves regional consent policies and what a policy pack controls.
28
+ - [Headless Mode](./frameworks/react/headless.md): Build fully custom consent UI using only hooks - no pre-built components required.
29
+ - [useColorScheme](./frameworks/react/hooks/use-color-scheme.md): Manage light/dark mode preferences for consent components.
30
+ - [Checking Consent](./frameworks/react/hooks/use-consent-manager/checking-consent.md): Use has() for flexible consent checks with AND, OR, and NOT logic. Check if any consent exists with hasConsented().
31
+ - [Location Info](./frameworks/react/hooks/use-consent-manager/location-info.md): Access detected jurisdiction, country, and region. Override geolocation for testing.
32
+ - [useConsentManager](./frameworks/react/hooks/use-consent-manager/overview.md): The primary hook for accessing consent state and actions. Returns the full consent store including all state properties and action methods.
33
+ - [Setting Consent](./frameworks/react/hooks/use-consent-manager/setting-consent.md): Save, update, and reset consent preferences with setConsent(), setSelectedConsent(), and saveConsents().
34
+ - [useDraggable](./frameworks/react/hooks/use-draggable.md): Make an element draggable between viewport corners with snapping, persistence, and animation support.
35
+ - [useFocusTrap](./frameworks/react/hooks/use-focus-trap.md): Trap keyboard focus within a container for accessible modal dialogs.
36
+ - [useReducedMotion](./frameworks/react/hooks/use-reduced-motion.md): Detect the user's prefers-reduced-motion OS setting and reactively disable animations.
37
+ - [useSSRStatus](./frameworks/react/hooks/use-ssr-status.md): Check whether server-side rendered consent data was used during initialization.
38
+ - [useTextDirection](./frameworks/react/hooks/use-text-direction.md): Manage RTL/LTR text direction based on the active language for consent UI.
39
+ - [useTranslations](./frameworks/react/hooks/use-translations.md): Access the current language's translations for building custom consent UI.
40
+ - [IABConsentBanner](./frameworks/react/iab/consent-banner.md): An IAB TCF 2.3 compliant consent banner that displays partner count, purpose summaries, and legitimate interest notices.
41
+ - [IABConsentDialog](./frameworks/react/iab/consent-dialog.md): An IAB TCF 2.3 compliant preference center with tabbed purpose and vendor management.
42
+ - [IAB TCF 2.3](./frameworks/react/iab/overview.md): Implement IAB Transparency & Consent Framework 2.3 compliance for programmatic advertising in EU/EEA jurisdictions.
43
+ - [useGVLData (Internal)](./frameworks/react/iab/use-gvl-data.md): Status note for the internal GVL hook used by the built-in IAB dialog.
44
+ - [Iframe Blocking](./frameworks/react/iframe-blocking.md): Block embedded content (YouTube, social widgets, maps) until users grant consent for the appropriate category.
45
+ - [Internationalization](./frameworks/react/internationalization.md): Translate consent UI into 30+ languages with built-in translations, custom overrides, and automatic browser language detection.
46
+ - [Network Blocker](./frameworks/react/network-blocker.md): Block outgoing network requests to third-party domains until the user grants consent for the appropriate category.
47
+ - [Optimization](./frameworks/react/optimization.md): Improve c15t startup performance in React with prefetching, proxy rewrites, and rendering tradeoffs.
48
+ - [Policy Packs](./frameworks/react/policy-packs.md): Configure regional consent policies in React hosted mode, presets, and offline fallback.
49
+ - [Quickstart](./frameworks/react/quickstart.md): Add consent management to your React app in under 5 minutes.
50
+ - [Script Loader](./frameworks/react/script-loader.md): Gate third-party scripts behind consent in React — load Google Analytics, Meta Pixel, and other tracking scripts only when users grant permission.
51
+ - [Server-Side Utilities](./frameworks/react/server-side.md): Fetch consent data on the server for SSR hydration — eliminate the loading flash and improve performance.
52
+ - [Class Names](./frameworks/react/styling/classnames.md): Style consent components using className props and per-slot className targeting via the theme.
53
+ - [Color Scheme](./frameworks/react/styling/color-scheme.md): Support light mode, dark mode, and system preference detection in consent components.
54
+ - [CSS Variables](./frameworks/react/styling/css-variables.md): Reference for all --c15t-* CSS custom properties generated by the theme system.
55
+ - [Styling Overview](./frameworks/react/styling/overview.md): Customize every aspect of c15t's consent components using design tokens, component slots, and CSS variables.
56
+ - [Component Slots](./frameworks/react/styling/slots.md): Target individual component parts with styles using the slot system - className strings or inline style objects.
57
+ - [Tailwind CSS](./frameworks/react/styling/tailwind.md): Use Tailwind CSS utility classes to style consent components via the slot system.
58
+ - [Design Tokens](./frameworks/react/styling/tokens.md): The six base token categories that control colors, typography, spacing, radius, shadows, and motion, plus optional dark-mode overrides.
59
+ - [Troubleshooting](./frameworks/react/troubleshooting.md): Solutions for common issues with @c15t/react — provider errors, missing banners, consent persistence, and more.
60
+
61
+ ## Integrations
62
+
63
+ Connect analytics, advertising, maps, media, and other third-party tools behind consent.
64
+
65
+ - [Adobe Analytics](./integrations/adobe-analytics.md): Adobe Analytics loaded through an Adobe Experience Platform Data Collection Tags embed URL.
66
+ - [Ahrefs Analytics](./integrations/ahrefs-analytics.md): Cookieless web analytics from Ahrefs with a prebuilt helper that wires the project key into a c15t-managed script.
67
+ - [Amplitude](./integrations/amplitude.md): Load Amplitude Browser SDK 2 with c15t and gate product analytics behind measurement consent.
68
+ - [Build a Custom Script Integration](./integrations/building-integrations.md): Learn when to use a raw Script, when to build a reusable manifest-backed integration, and how to debug and test custom consent-aware scripts in c15t.
69
+ - [Clearbit](./integrations/clearbit.md): Visitor and company enrichment loaded with Clearbit's account-keyed tags.js snippet.
70
+ - [Cloudflare Web Analytics](./integrations/cloudflare-web-analytics.md): Cookieless analytics from Cloudflare with a prebuilt helper that serializes the beacon config into the `data-cf-beacon` attribute.
71
+ - [Crisp](./integrations/crisp.md): Load Crisp live chat with website ID, runtime, cookie, and session options.
72
+ - [Databuddy](./integrations/databuddy.md): Databuddy is a privacy-focused analytics platform that helps you understand user behavior and track events. It supports cookieless tracking and manages consent automatically through c15t's consent state synchronization.
73
+ - [Fathom Analytics](./integrations/fathom-analytics.md): Privacy-friendly cookieless analytics with a prebuilt helper that maps Fathom's data attributes into a c15t-managed script.
74
+ - [Google Maps](./integrations/google-maps.md): Render Google Maps only after consent with one shared Maps JavaScript API loader and independently managed map instances.
75
+ - [GA4 + Google Ads (gtag.js)](./integrations/google-tag.md): Send data to Google Analytics 4 and Google Ads with automatic Consent Mode v2 support.
76
+ - [Google Tag Manager](./integrations/google-tag-manager.md): Deploy and manage marketing tags centrally with automatic consent state synchronization.
77
+ - [Heap](./integrations/heap.md): Load Heap with c15t and gate autocapture product analytics behind measurement consent.
78
+ - [Hightouch](./integrations/hightouch.md): Load Hightouch Events with c15t and gate the browser SDK behind measurement consent.
79
+ - [Hotjar](./integrations/hotjar.md): Product analytics and behavior insights with a prebuilt helper that seeds Hotjar globals before loading the vendor bundle.
80
+ - [Intercom](./integrations/intercom.md): Bootstrap Intercom settings and load the messenger widget bundle.
81
+ - [LinkedIn Insights](./integrations/linkedin-insights.md): Track conversions and build matched audiences for LinkedIn advertising campaigns.
82
+ - [LogRocket](./integrations/logrocket.md): Session replay and monitoring loaded after measurement consent with LogRocket's browser SDK.
83
+ - [Matomo Analytics](./integrations/matomo-analytics.md): Load Matomo with c15t and keep Matomo's queue aligned with measurement consent.
84
+ - [Meta Pixel](./integrations/meta-pixel.md): Track conversions and build audiences for Facebook and Instagram advertising campaigns.
85
+ - [Microsoft Clarity](./integrations/microsoft-clarity.md): Session replay and behavior analytics with a prebuilt helper that keeps Clarity consent synchronized with c15t measurement state.
86
+ - [Microsoft UET](./integrations/microsoft-uet.md): Track conversions and measure performance for Microsoft Advertising and Bing Ads.
87
+ - [Mixpanel Analytics](./integrations/mixpanel-analytics.md): Load Mixpanel with c15t and let Mixpanel's own opt-in and opt-out APIs follow measurement consent.
88
+ - [Integrations](./integrations/overview.md): Load analytics, pixels, tag managers, and widgets through c15t so consent state controls when they run, update, and appear in your consent UI.
89
+ - [Pirsch](./integrations/pirsch.md): Privacy-friendly, cookieless analytics loaded with Pirsch's fixed script id and identification-code attributes.
90
+ - [Plausible Analytics](./integrations/plausible-analytics.md): Privacy-friendly cookieless analytics with a prebuilt helper that preserves Plausible's queue bootstrap and loader attributes.
91
+ - [PostHog](./integrations/posthog.md): PostHog is an open-source product analytics platform for tracking user behavior, session replays, feature flags, and A/B testing. It supports cookieless tracking, allowing analytics to continue even without cookie consent.
92
+ - [Promptwatch](./integrations/promptwatch.md): Promptwatch analyzes traffic on your site for Artificial Intelligence (AI) traffic and usage insights. Data is stored in the EU without user-identifiable information.
93
+ - [Reddit Pixel](./integrations/reddit-pixel.md): Track conversions and build retargeting audiences for Reddit advertising campaigns.
94
+ - [RudderStack](./integrations/rudderstack.md): Load RudderStack's JavaScript SDK with c15t and gate the browser SDK behind measurement consent.
95
+ - [Rybbit Analytics](./integrations/rybbit-analytics.md): Privacy-friendly analytics with script-tag configuration via Rybbit's data attributes.
96
+ - [Segment](./integrations/segment.md): Load Segment Analytics.js with c15t and gate it behind measurement consent.
97
+ - [Snapchat Pixel](./integrations/snapchat-pixel.md): Measure Snapchat ad performance and build remarketing audiences with a prebuilt pixel helper.
98
+ - [TikTok Pixel](./integrations/tiktok-pixel.md): Measure ad performance and build audiences for TikTok advertising campaigns.
99
+ - [Umami Analytics](./integrations/umami-analytics.md): Open-source, cookieless analytics with a prebuilt helper that maps Umami's data attributes into a c15t-managed script.
100
+ - [Vercel Analytics](./integrations/vercel-analytics.md): Bootstrap Vercel Analytics with a declarative queue and script attributes.
101
+ - [X Pixel (Twitter Pixel)](./integrations/x-pixel.md): Track conversions and build audiences for advertising campaigns on X (formerly Twitter).
102
+ - [YouTube](./integrations/youtube.md): Keep YouTube iframes unmounted until consent with a privacy-enhanced, lazy-loaded React or Next.js embed.
103
+
104
+ ## Reference
105
+
106
+ Concepts, legal templates, open-source policies, and contributor documentation.
107
+
108
+ - [Client Modes](./shared/concepts/client-modes.md): Reference page for client modes.
109
+ - [Consent Categories](./shared/concepts/consent-categories.md): Reference page for consent categories.
110
+ - [Consent Models](./shared/concepts/consent-models.md): Reference page for consent models.
111
+ - [Cookie Management](./shared/concepts/cookie-management.md): Reference page for cookie management.
112
+ - [Glossary](./shared/concepts/glossary.md): Reference page for glossary.
113
+ - [Initialization Flow](./shared/concepts/initialization-flow.md): Reference page for initialization flow.
114
+ - [Policy Packs](./shared/concepts/policy-packs.md): Reference page for policy packs.
115
+ - [Consent Banner](./shared/react/components/consent-banner.md): Reference page for consent banner.
116
+ - [Consent Dialog](./shared/react/components/consent-dialog.md): Reference page for consent dialog.
117
+ - [Consent Dialog Link](./shared/react/components/consent-dialog-link.md): Reference page for consent dialog link.
118
+ - [Consent Dialog Trigger](./shared/react/components/consent-dialog-trigger.md): Reference page for consent dialog trigger.
119
+ - [Consent Manager Provider](./shared/react/components/consent-manager-provider.md): Reference page for consent manager provider.
120
+ - [Consent Widget](./shared/react/components/consent-widget.md): Reference page for consent widget.
121
+ - [Dev Tools](./shared/react/components/dev-tools.md): Reference page for dev tools.
122
+ - [Frame](./shared/react/components/frame.md): Reference page for frame.
123
+ - [Building Headless Components](./shared/react/guides/building-headless-components.md): Reference page for building headless components.
124
+ - [Callbacks](./shared/react/guides/callbacks.md): Reference page for callbacks.
125
+ - [Headless](./shared/react/guides/headless.md): Reference page for headless.
126
+ - [Iframe Blocking](./shared/react/guides/iframe-blocking.md): Reference page for iframe blocking.
127
+ - [Internationalization](./shared/react/guides/internationalization.md): Reference page for internationalization.
128
+ - [Network Blocker](./shared/react/guides/network-blocker.md): Reference page for network blocker.
129
+ - [Optimization](./shared/react/guides/optimization.md): Reference page for optimization.
130
+ - [Policy Packs](./shared/react/guides/policy-packs.md): Reference page for policy packs.
131
+ - [Script Loader](./shared/react/guides/script-loader.md): Reference page for script loader.
132
+ - [Use Color Scheme](./shared/react/hooks/use-color-scheme.md): Reference page for use color scheme.
133
+ - [Checking Consent](./shared/react/hooks/use-consent-manager/checking-consent.md): Reference page for checking consent.
134
+ - [Location Info](./shared/react/hooks/use-consent-manager/location-info.md): Reference page for location info.
135
+ - [Overview](./shared/react/hooks/use-consent-manager/overview.md): Reference page for overview.
136
+ - [Setting Consent](./shared/react/hooks/use-consent-manager/setting-consent.md): Reference page for setting consent.
137
+ - [Use Draggable](./shared/react/hooks/use-draggable.md): Reference page for use draggable.
138
+ - [Use Focus Trap](./shared/react/hooks/use-focus-trap.md): Reference page for use focus trap.
139
+ - [Use Reduced Motion](./shared/react/hooks/use-reduced-motion.md): Reference page for use reduced motion.
140
+ - [Use SSR Status](./shared/react/hooks/use-ssr-status.md): Reference page for use ssr status.
141
+ - [Use Text Direction](./shared/react/hooks/use-text-direction.md): Reference page for use text direction.
142
+ - [Use Translations](./shared/react/hooks/use-translations.md): Reference page for use translations.
143
+ - [Consent Banner](./shared/react/iab/consent-banner.md): Reference page for consent banner.
144
+ - [Consent Dialog](./shared/react/iab/consent-dialog.md): Reference page for consent dialog.
145
+ - [Overview](./shared/react/iab/overview.md): Reference page for overview.
146
+ - [Use GVL Data](./shared/react/iab/use-gvl-data.md): Reference page for use gvl data.
147
+ - [Classnames](./shared/react/styling/classnames.md): Reference page for classnames.
148
+ - [Color Scheme](./shared/react/styling/color-scheme.md): Reference page for color scheme.
149
+ - [CSS Variables](./shared/react/styling/css-variables.md): Reference page for css variables.
150
+ - [Overview](./shared/react/styling/overview.md): Reference page for overview.
151
+ - [Slots](./shared/react/styling/slots.md): Reference page for slots.
152
+ - [Stylesheet Entrypoint](./shared/react/styling/stylesheet-entrypoint.md): Reference page for stylesheet entrypoint.
153
+ - [Tailwind](./shared/react/styling/tailwind.md): Reference page for tailwind.
154
+ - [Tokens](./shared/react/styling/tokens.md): Reference page for tokens.
155
+ - [Troubleshooting](./shared/troubleshooting.md): Reference page for troubleshooting.
@@ -1,6 +1,8 @@
1
1
  ---
2
2
  title: Building Headless Components
3
- description: Build policy-aware custom consent components in React using the headless hooks and policy-pack tooling.
3
+ description: Build policy-aware custom consent components in React using the
4
+ headless hooks and policy-pack tooling.
5
+ group: frameworks
4
6
  ---
5
7
  Building custom consent UI is easier now because c15t exposes multiple layers of policy-aware primitives instead of forcing you to reconstruct banner rules by hand.
6
8
 
@@ -1,6 +1,8 @@
1
1
  ---
2
2
  title: Callbacks
3
- description: React to consent lifecycle events - initialization, consent changes, errors, and revocation reloads.
3
+ description: React to consent lifecycle events - initialization, consent
4
+ changes, errors, and revocation reloads.
5
+ group: frameworks
4
6
  ---
5
7
  Callbacks let you run custom code at key points in the consent lifecycle. Define them in the provider or runtime `callbacks` option, or register them dynamically after initialization.
6
8
 
@@ -1,6 +1,9 @@
1
1
  ---
2
2
  title: ConsentBanner
3
- description: A pre-built consent banner that appears when user consent is needed. Supports policy-aware layout, theming, and advanced composition when markup must change.
3
+ description: A pre-built consent banner that appears when user consent is
4
+ needed. Supports policy-aware layout, theming, and advanced composition when
5
+ markup must change.
6
+ group: frameworks
4
7
  ---
5
8
  `ConsentBanner` is a ready-to-use consent banner that appears automatically in **opt-in jurisdictions** (like GDPR) where explicit consent is required before tracking. In opt-out jurisdictions (like CCPA), the banner won't appear — users get an opt-out mechanism instead. It includes reject, accept, and customize buttons with configurable layout.
6
9
 
@@ -247,23 +250,9 @@ If you only need styling changes, stay with tokens and slots instead of rebuildi
247
250
 
248
251
  ## Props
249
252
 
250
- ### ConsentBannerProps
251
-
252
- |Property|Type|Description|Default|Required|
253
- |:--|:--|:--|:--|:--:|
254
- |noStyle|boolean \|undefined|When true, removes all default styling from the component|false|Optional|
255
- |title|ReactNode|Content to display as the banner's title|undefined|Optional|
256
- |description|ReactNode|Content to display as the banner's description|undefined|Optional|
257
- |rejectButtonText|ReactNode|Content to display on the reject button|undefined|Optional|
258
- |customizeButtonText|ReactNode|Content to display on the customize button|undefined|Optional|
259
- |acceptButtonText|ReactNode|Content to display on the accept button|undefined|Optional|
260
- |scrollLock|boolean \|undefined|When true, the consent banner will lock the scroll of the page|false|Optional|
261
- |trapFocus|boolean \|undefined|When true, the consent banner will trap focus|true|Optional|
262
- |disableAnimation|boolean \|undefined|When true, disables the entrance/exit animations|false|Optional|
263
- |legalLinks|(keyof LegalLinksTranslations)\[] \|null \|undefined|Controls which legal links to display. Options: \`undefined\` (default): Shows all available legal links; \`null\`: Explicitly hides all legal links; Array of keys: Shows only the specified legal links|-|Optional|
264
- |hideBranding|boolean \|undefined|When true, hides the branding tag on the banner.|false|Optional|
265
- |layout|ConsentBannerLayout \|undefined|Defines the layout of buttons in the footer. Allows reordering and grouping of buttons.|-|Optional|
266
- |direction|PolicyUiActionDirection \|undefined|Defines how footer button groups flow.|-|Optional|
267
- |primaryButton|ConsentBannerButton \|undefined|Specifies which button(s) should be highlighted as the primary action.|-|Optional|
268
- |models|Model \|undefined|Which consent models this banner responds to.|\['opt-in']|Optional|
269
- |uiSource|string \|undefined|Override the UI source identifier sent with consent API calls.|'banner'|Optional|
253
+ |Property|Value|
254
+ |:--|:--|
255
+ |Type Name|\`ConsentBannerProps\`|
256
+ |Source Path|\`./packages/react/src/components/consent-banner/consent-banner.tsx\`|
257
+
258
+ \*ExtractedTypeTable: Could not extract "ConsentBannerProps" from "./packages/react/src/components/consent-banner/consent-banner.tsx" using base path "/home/runner/work/c15t/c15t". Verify the path/name and that the file is included by your tsconfig.\*
@@ -1,6 +1,8 @@
1
1
  ---
2
2
  title: ConsentDialogLink
3
- description: An inline trigger for opening the consent dialog from footers, legal pages, and account settings.
3
+ description: An inline trigger for opening the consent dialog from footers,
4
+ legal pages, and account settings.
5
+ group: frameworks
4
6
  ---
5
7
  `ConsentDialogLink` is an inline trigger for opening the consent dialog from places like site footers, legal pages, or account settings. It is unstyled by default, so it inherits your app's typography and link/button styles.
6
8
 
@@ -52,8 +54,9 @@ The component defaults to `noStyle={true}`. Set it to `false` if you want c15t b
52
54
 
53
55
  ## Props
54
56
 
55
- ### ConsentDialogLinkProps
57
+ |Property|Value|
58
+ |:--|:--|
59
+ |Type Name|\`ConsentDialogLinkProps\`|
60
+ |Source Path|\`./packages/react/src/components/consent-preferences-link/consent-preferences-link.tsx\`|
56
61
 
57
- |Property|Type|Description|Default|Required|
58
- |:--|:--|:--|:--|:--:|
59
- |children|ReactNode|Custom trigger content, for example "Your privacy settings" or "Manage preferences".|-|✅ Required|
62
+ \*ExtractedTypeTable: Could not extract "ConsentDialogLinkProps" from "./packages/react/src/components/consent-preferences-link/consent-preferences-link.tsx" using base path "/home/runner/work/c15t/c15t". Verify the path/name and that the file is included by your tsconfig.\*