@inkeep/cxkit-primitives 0.0.0-dev-20250221234142

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 (477) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +1 -0
  3. package/dist/atoms/api/analytics/conversation.cjs +1 -0
  4. package/dist/atoms/api/analytics/conversation.d.cts +3 -0
  5. package/dist/atoms/api/analytics/conversation.d.ts +3 -0
  6. package/dist/atoms/api/analytics/conversation.js +37 -0
  7. package/dist/atoms/api/analytics/events.cjs +1 -0
  8. package/dist/atoms/api/analytics/events.d.cts +2 -0
  9. package/dist/atoms/api/analytics/events.d.ts +2 -0
  10. package/dist/atoms/api/analytics/events.js +30 -0
  11. package/dist/atoms/api/analytics/feedback.cjs +1 -0
  12. package/dist/atoms/api/analytics/feedback.d.cts +11 -0
  13. package/dist/atoms/api/analytics/feedback.d.ts +11 -0
  14. package/dist/atoms/api/analytics/feedback.js +26 -0
  15. package/dist/atoms/avatars/ai.cjs +1 -0
  16. package/dist/atoms/avatars/ai.d.cts +3 -0
  17. package/dist/atoms/avatars/ai.d.ts +3 -0
  18. package/dist/atoms/avatars/ai.js +88 -0
  19. package/dist/atoms/avatars/user.cjs +1 -0
  20. package/dist/atoms/avatars/user.d.cts +3 -0
  21. package/dist/atoms/avatars/user.d.ts +3 -0
  22. package/dist/atoms/avatars/user.js +27 -0
  23. package/dist/atoms/codeblock/index.cjs +1 -0
  24. package/dist/atoms/codeblock/index.d.cts +10 -0
  25. package/dist/atoms/codeblock/index.d.ts +10 -0
  26. package/dist/atoms/codeblock/index.js +40 -0
  27. package/dist/atoms/custom-styles.cjs +1 -0
  28. package/dist/atoms/custom-styles.d.cts +5 -0
  29. package/dist/atoms/custom-styles.d.ts +5 -0
  30. package/dist/atoms/custom-styles.js +57 -0
  31. package/dist/atoms/dialog.cjs +1 -0
  32. package/dist/atoms/dialog.d.cts +68 -0
  33. package/dist/atoms/dialog.d.ts +68 -0
  34. package/dist/atoms/dialog.js +185 -0
  35. package/dist/atoms/icons/built-in-icon-renderer.cjs +1 -0
  36. package/dist/atoms/icons/built-in-icon-renderer.d.cts +6 -0
  37. package/dist/atoms/icons/built-in-icon-renderer.d.ts +6 -0
  38. package/dist/atoms/icons/built-in-icon-renderer.js +49 -0
  39. package/dist/atoms/icons/built-in-icons.cjs +1 -0
  40. package/dist/atoms/icons/built-in-icons.d.cts +72 -0
  41. package/dist/atoms/icons/built-in-icons.d.ts +72 -0
  42. package/dist/atoms/icons/built-in-icons.js +79 -0
  43. package/dist/atoms/icons/checkbox-icon.cjs +1 -0
  44. package/dist/atoms/icons/checkbox-icon.d.cts +1 -0
  45. package/dist/atoms/icons/checkbox-icon.d.ts +1 -0
  46. package/dist/atoms/icons/checkbox-icon.js +24 -0
  47. package/dist/atoms/icons/custom-icon.cjs +1 -0
  48. package/dist/atoms/icons/custom-icon.d.cts +6 -0
  49. package/dist/atoms/icons/custom-icon.d.ts +6 -0
  50. package/dist/atoms/icons/custom-icon.js +19 -0
  51. package/dist/atoms/icons/index.cjs +1 -0
  52. package/dist/atoms/icons/index.d.cts +2 -0
  53. package/dist/atoms/icons/index.d.ts +2 -0
  54. package/dist/atoms/icons/index.js +6 -0
  55. package/dist/atoms/icons/inkeep-default-icons.cjs +1 -0
  56. package/dist/atoms/icons/inkeep-default-icons.d.cts +2 -0
  57. package/dist/atoms/icons/inkeep-default-icons.d.ts +2 -0
  58. package/dist/atoms/icons/inkeep-default-icons.js +23 -0
  59. package/dist/atoms/link.cjs +1 -0
  60. package/dist/atoms/link.d.cts +14 -0
  61. package/dist/atoms/link.d.ts +14 -0
  62. package/dist/atoms/link.js +35 -0
  63. package/dist/atoms/markdown/components.cjs +1 -0
  64. package/dist/atoms/markdown/components.d.cts +27 -0
  65. package/dist/atoms/markdown/components.d.ts +27 -0
  66. package/dist/atoms/markdown/components.js +64 -0
  67. package/dist/atoms/markdown/index.cjs +1 -0
  68. package/dist/atoms/markdown/index.d.cts +15 -0
  69. package/dist/atoms/markdown/index.d.ts +15 -0
  70. package/dist/atoms/markdown/index.js +79 -0
  71. package/dist/atoms/markdown/rehype-inline-code-property.cjs +1 -0
  72. package/dist/atoms/markdown/rehype-inline-code-property.d.cts +1 -0
  73. package/dist/atoms/markdown/rehype-inline-code-property.d.ts +1 -0
  74. package/dist/atoms/markdown/rehype-inline-code-property.js +12 -0
  75. package/dist/atoms/portal-with-theme.cjs +1 -0
  76. package/dist/atoms/portal-with-theme.d.cts +2 -0
  77. package/dist/atoms/portal-with-theme.d.ts +2 -0
  78. package/dist/atoms/portal-with-theme.js +12 -0
  79. package/dist/atoms/portal.cjs +1 -0
  80. package/dist/atoms/portal.d.cts +8 -0
  81. package/dist/atoms/portal.d.ts +8 -0
  82. package/dist/atoms/portal.js +19 -0
  83. package/dist/atoms/shadow/context.cjs +2 -0
  84. package/dist/atoms/shadow/context.d.cts +14 -0
  85. package/dist/atoms/shadow/context.d.ts +14 -0
  86. package/dist/atoms/shadow/context.js +55 -0
  87. package/dist/atoms/shadow/create.cjs +1 -0
  88. package/dist/atoms/shadow/create.d.cts +8 -0
  89. package/dist/atoms/shadow/create.d.ts +8 -0
  90. package/dist/atoms/shadow/create.js +56 -0
  91. package/dist/atoms/shadow/index.d.cts +1 -0
  92. package/dist/atoms/shadow/index.d.ts +1 -0
  93. package/dist/atoms/shadow/root.cjs +1 -0
  94. package/dist/atoms/shadow/root.d.cts +5 -0
  95. package/dist/atoms/shadow/root.d.ts +5 -0
  96. package/dist/atoms/shadow/root.js +22 -0
  97. package/dist/atoms/shadow/use-ensured-forwarded-ref.cjs +1 -0
  98. package/dist/atoms/shadow/use-ensured-forwarded-ref.d.cts +2 -0
  99. package/dist/atoms/shadow/use-ensured-forwarded-ref.d.ts +2 -0
  100. package/dist/atoms/shadow/use-ensured-forwarded-ref.js +11 -0
  101. package/dist/atoms/shadow/utils.cjs +1 -0
  102. package/dist/atoms/shadow/utils.d.cts +9 -0
  103. package/dist/atoms/shadow/utils.d.ts +9 -0
  104. package/dist/atoms/shadow/utils.js +16 -0
  105. package/dist/components/chat-button.cjs +1 -0
  106. package/dist/components/chat-button.d.cts +11 -0
  107. package/dist/components/chat-button.d.ts +11 -0
  108. package/dist/components/chat-button.js +42 -0
  109. package/dist/components/embedded-chat/chat-provider.cjs +1 -0
  110. package/dist/components/embedded-chat/chat-provider.d.cts +19 -0
  111. package/dist/components/embedded-chat/chat-provider.d.ts +19 -0
  112. package/dist/components/embedded-chat/chat-provider.js +22 -0
  113. package/dist/components/embedded-chat/use-captcha.cjs +1 -0
  114. package/dist/components/embedded-chat/use-captcha.d.cts +13 -0
  115. package/dist/components/embedded-chat/use-captcha.d.ts +13 -0
  116. package/dist/components/embedded-chat/use-captcha.js +56 -0
  117. package/dist/components/embedded-chat/use-chat-action.cjs +1 -0
  118. package/dist/components/embedded-chat/use-chat-action.d.cts +9 -0
  119. package/dist/components/embedded-chat/use-chat-action.d.ts +9 -0
  120. package/dist/components/embedded-chat/use-chat-action.js +26 -0
  121. package/dist/components/embedded-chat/use-inkeep-chat.cjs +4 -0
  122. package/dist/components/embedded-chat/use-inkeep-chat.d.cts +25 -0
  123. package/dist/components/embedded-chat/use-inkeep-chat.d.ts +25 -0
  124. package/dist/components/embedded-chat/use-inkeep-chat.js +227 -0
  125. package/dist/components/embedded-chat.cjs +17 -0
  126. package/dist/components/embedded-chat.d.cts +415 -0
  127. package/dist/components/embedded-chat.d.ts +415 -0
  128. package/dist/components/embedded-chat.js +1840 -0
  129. package/dist/components/embedded-search/search-provider.cjs +1 -0
  130. package/dist/components/embedded-search/search-provider.d.cts +21 -0
  131. package/dist/components/embedded-search/search-provider.d.ts +21 -0
  132. package/dist/components/embedded-search/search-provider.js +19 -0
  133. package/dist/components/embedded-search/search-query.graphql.cjs +82 -0
  134. package/dist/components/embedded-search/search-query.graphql.js +86 -0
  135. package/dist/components/embedded-search/transform-results.cjs +1 -0
  136. package/dist/components/embedded-search/transform-results.d.cts +3 -0
  137. package/dist/components/embedded-search/transform-results.d.ts +3 -0
  138. package/dist/components/embedded-search/transform-results.js +113 -0
  139. package/dist/components/embedded-search/use-inkeep-search.cjs +1 -0
  140. package/dist/components/embedded-search/use-inkeep-search.d.cts +21 -0
  141. package/dist/components/embedded-search/use-inkeep-search.d.ts +21 -0
  142. package/dist/components/embedded-search/use-inkeep-search.js +137 -0
  143. package/dist/components/embedded-search.cjs +1 -0
  144. package/dist/components/embedded-search.d.cts +229 -0
  145. package/dist/components/embedded-search.d.ts +229 -0
  146. package/dist/components/embedded-search.js +390 -0
  147. package/dist/components/factory.cjs +1 -0
  148. package/dist/components/factory.d.cts +19 -0
  149. package/dist/components/factory.d.ts +19 -0
  150. package/dist/components/factory.js +39 -0
  151. package/dist/components/index.cjs +1 -0
  152. package/dist/components/index.d.cts +11 -0
  153. package/dist/components/index.d.ts +11 -0
  154. package/dist/components/index.js +31 -0
  155. package/dist/components/intelligent-form/actions/context-model-response.cjs +9 -0
  156. package/dist/components/intelligent-form/actions/context-model-response.d.cts +10 -0
  157. package/dist/components/intelligent-form/actions/context-model-response.d.ts +10 -0
  158. package/dist/components/intelligent-form/actions/context-model-response.js +36 -0
  159. package/dist/components/intelligent-form/actions/escalation-schema.cjs +1 -0
  160. package/dist/components/intelligent-form/actions/escalation-schema.d.cts +2 -0
  161. package/dist/components/intelligent-form/actions/escalation-schema.d.ts +2 -0
  162. package/dist/components/intelligent-form/actions/escalation-schema.js +48 -0
  163. package/dist/components/intelligent-form/actions/qa-model-messages.cjs +27 -0
  164. package/dist/components/intelligent-form/actions/qa-model-messages.d.cts +2 -0
  165. package/dist/components/intelligent-form/actions/qa-model-messages.d.ts +2 -0
  166. package/dist/components/intelligent-form/actions/qa-model-messages.js +45 -0
  167. package/dist/components/intelligent-form/actions/qa-model-response.cjs +1 -0
  168. package/dist/components/intelligent-form/actions/qa-model-response.d.cts +14 -0
  169. package/dist/components/intelligent-form/actions/qa-model-response.d.ts +14 -0
  170. package/dist/components/intelligent-form/actions/qa-model-response.js +46 -0
  171. package/dist/components/intelligent-form/intelligent-form-provider.cjs +1 -0
  172. package/dist/components/intelligent-form/intelligent-form-provider.d.cts +29 -0
  173. package/dist/components/intelligent-form/intelligent-form-provider.d.ts +29 -0
  174. package/dist/components/intelligent-form/intelligent-form-provider.js +23 -0
  175. package/dist/components/intelligent-form/use-inkeep-intelligent-form.cjs +1 -0
  176. package/dist/components/intelligent-form/use-inkeep-intelligent-form.d.cts +30 -0
  177. package/dist/components/intelligent-form/use-inkeep-intelligent-form.d.ts +30 -0
  178. package/dist/components/intelligent-form/use-inkeep-intelligent-form.js +157 -0
  179. package/dist/components/intelligent-form.cjs +1 -0
  180. package/dist/components/intelligent-form.d.cts +135 -0
  181. package/dist/components/intelligent-form.d.ts +135 -0
  182. package/dist/components/intelligent-form.js +568 -0
  183. package/dist/components/modal/modal-provider.cjs +1 -0
  184. package/dist/components/modal/modal-provider.d.cts +13 -0
  185. package/dist/components/modal/modal-provider.d.ts +13 -0
  186. package/dist/components/modal/modal-provider.js +8 -0
  187. package/dist/components/modal/use-inkeep-modal.cjs +1 -0
  188. package/dist/components/modal/use-inkeep-modal.d.cts +8 -0
  189. package/dist/components/modal/use-inkeep-modal.d.ts +8 -0
  190. package/dist/components/modal/use-inkeep-modal.js +30 -0
  191. package/dist/components/modal.cjs +1 -0
  192. package/dist/components/modal.d.cts +18 -0
  193. package/dist/components/modal.d.ts +18 -0
  194. package/dist/components/modal.js +40 -0
  195. package/dist/components/searchbar.cjs +1 -0
  196. package/dist/components/searchbar.d.cts +23 -0
  197. package/dist/components/searchbar.d.ts +23 -0
  198. package/dist/components/searchbar.js +54 -0
  199. package/dist/components/tagline-logo-icon.cjs +1 -0
  200. package/dist/components/tagline-logo-icon.d.cts +1 -0
  201. package/dist/components/tagline-logo-icon.d.ts +1 -0
  202. package/dist/components/tagline-logo-icon.js +34 -0
  203. package/dist/hooks/index.cjs +1 -0
  204. package/dist/hooks/index.d.cts +12 -0
  205. package/dist/hooks/index.d.ts +12 -0
  206. package/dist/hooks/index.js +27 -0
  207. package/dist/hooks/use-boolean.cjs +1 -0
  208. package/dist/hooks/use-boolean.d.cts +10 -0
  209. package/dist/hooks/use-boolean.d.ts +10 -0
  210. package/dist/hooks/use-boolean.js +17 -0
  211. package/dist/hooks/use-browser-storage.cjs +1 -0
  212. package/dist/hooks/use-browser-storage.d.cts +17 -0
  213. package/dist/hooks/use-browser-storage.d.ts +17 -0
  214. package/dist/hooks/use-browser-storage.js +88 -0
  215. package/dist/hooks/use-component-classnames.cjs +1 -0
  216. package/dist/hooks/use-component-classnames.d.cts +6 -0
  217. package/dist/hooks/use-component-classnames.d.ts +6 -0
  218. package/dist/hooks/use-component-classnames.js +14 -0
  219. package/dist/hooks/use-container-size.cjs +1 -0
  220. package/dist/hooks/use-container-size.d.cts +5 -0
  221. package/dist/hooks/use-container-size.d.ts +5 -0
  222. package/dist/hooks/use-container-size.js +18 -0
  223. package/dist/hooks/use-copy-to-clipboard.cjs +1 -0
  224. package/dist/hooks/use-copy-to-clipboard.d.cts +3 -0
  225. package/dist/hooks/use-copy-to-clipboard.d.ts +3 -0
  226. package/dist/hooks/use-copy-to-clipboard.js +19 -0
  227. package/dist/hooks/use-instant-update.cjs +1 -0
  228. package/dist/hooks/use-instant-update.d.cts +17 -0
  229. package/dist/hooks/use-instant-update.d.ts +17 -0
  230. package/dist/hooks/use-instant-update.js +16 -0
  231. package/dist/hooks/use-is-mounted.cjs +1 -0
  232. package/dist/hooks/use-is-mounted.d.cts +1 -0
  233. package/dist/hooks/use-is-mounted.d.ts +1 -0
  234. package/dist/hooks/use-is-mounted.js +11 -0
  235. package/dist/hooks/use-media-query.cjs +1 -0
  236. package/dist/hooks/use-media-query.d.cts +1 -0
  237. package/dist/hooks/use-media-query.d.ts +1 -0
  238. package/dist/hooks/use-media-query.js +14 -0
  239. package/dist/hooks/use-resize-observer.cjs +1 -0
  240. package/dist/hooks/use-resize-observer.d.cts +12 -0
  241. package/dist/hooks/use-resize-observer.d.ts +12 -0
  242. package/dist/hooks/use-resize-observer.js +32 -0
  243. package/dist/hooks/use-scroll-to-bottom.cjs +1 -0
  244. package/dist/hooks/use-scroll-to-bottom.d.cts +13 -0
  245. package/dist/hooks/use-scroll-to-bottom.d.ts +13 -0
  246. package/dist/hooks/use-scroll-to-bottom.js +52 -0
  247. package/dist/hooks/use-scrolling-fades.cjs +1 -0
  248. package/dist/hooks/use-scrolling-fades.d.cts +2 -0
  249. package/dist/hooks/use-scrolling-fades.d.ts +2 -0
  250. package/dist/hooks/use-scrolling-fades.js +18 -0
  251. package/dist/hooks/use-settle-action.cjs +1 -0
  252. package/dist/hooks/use-settle-action.d.cts +3 -0
  253. package/dist/hooks/use-settle-action.d.ts +3 -0
  254. package/dist/hooks/use-settle-action.js +11 -0
  255. package/dist/index.cjs +1 -0
  256. package/dist/index.d.cts +11 -0
  257. package/dist/index.d.ts +11 -0
  258. package/dist/index.js +152 -0
  259. package/dist/node_modules/.pnpm/react-icons@5.4.0_react@19.0.0/node_modules/react-icons/fa6/index.cjs +1 -0
  260. package/dist/node_modules/.pnpm/react-icons@5.4.0_react@19.0.0/node_modules/react-icons/fa6/index.js +92 -0
  261. package/dist/node_modules/.pnpm/react-icons@5.4.0_react@19.0.0/node_modules/react-icons/fi/index.cjs +1 -0
  262. package/dist/node_modules/.pnpm/react-icons@5.4.0_react@19.0.0/node_modules/react-icons/fi/index.js +8 -0
  263. package/dist/node_modules/.pnpm/react-icons@5.4.0_react@19.0.0/node_modules/react-icons/hi2/index.cjs +1 -0
  264. package/dist/node_modules/.pnpm/react-icons@5.4.0_react@19.0.0/node_modules/react-icons/hi2/index.js +8 -0
  265. package/dist/node_modules/.pnpm/react-icons@5.4.0_react@19.0.0/node_modules/react-icons/io5/index.cjs +1 -0
  266. package/dist/node_modules/.pnpm/react-icons@5.4.0_react@19.0.0/node_modules/react-icons/io5/index.js +128 -0
  267. package/dist/node_modules/.pnpm/react-icons@5.4.0_react@19.0.0/node_modules/react-icons/lib/iconBase.cjs +1 -0
  268. package/dist/node_modules/.pnpm/react-icons@5.4.0_react@19.0.0/node_modules/react-icons/lib/iconBase.js +109 -0
  269. package/dist/node_modules/.pnpm/react-icons@5.4.0_react@19.0.0/node_modules/react-icons/lib/iconContext.cjs +1 -0
  270. package/dist/node_modules/.pnpm/react-icons@5.4.0_react@19.0.0/node_modules/react-icons/lib/iconContext.js +13 -0
  271. package/dist/node_modules/.pnpm/react-icons@5.4.0_react@19.0.0/node_modules/react-icons/lu/index.cjs +1 -0
  272. package/dist/node_modules/.pnpm/react-icons@5.4.0_react@19.0.0/node_modules/react-icons/lu/index.js +68 -0
  273. package/dist/providers/attachment-item-provider.cjs +1 -0
  274. package/dist/providers/attachment-item-provider.d.cts +9 -0
  275. package/dist/providers/attachment-item-provider.d.ts +9 -0
  276. package/dist/providers/attachment-item-provider.js +13 -0
  277. package/dist/providers/attachments-bar-provider.cjs +1 -0
  278. package/dist/providers/attachments-bar-provider.d.cts +30 -0
  279. package/dist/providers/attachments-bar-provider.d.ts +30 -0
  280. package/dist/providers/attachments-bar-provider.js +64 -0
  281. package/dist/providers/base-events-provider.cjs +1 -0
  282. package/dist/providers/base-events-provider.d.cts +8 -0
  283. package/dist/providers/base-events-provider.d.ts +8 -0
  284. package/dist/providers/base-events-provider.js +39 -0
  285. package/dist/providers/chat-events-provider.cjs +1 -0
  286. package/dist/providers/chat-events-provider.d.cts +12 -0
  287. package/dist/providers/chat-events-provider.d.ts +12 -0
  288. package/dist/providers/chat-events-provider.js +66 -0
  289. package/dist/providers/chat-form-provider.cjs +1 -0
  290. package/dist/providers/chat-form-provider.d.cts +23 -0
  291. package/dist/providers/chat-form-provider.d.ts +23 -0
  292. package/dist/providers/chat-form-provider.js +66 -0
  293. package/dist/providers/config-provider.cjs +1 -0
  294. package/dist/providers/config-provider.d.cts +24 -0
  295. package/dist/providers/config-provider.d.ts +24 -0
  296. package/dist/providers/config-provider.js +37 -0
  297. package/dist/providers/conversation-provider.cjs +1 -0
  298. package/dist/providers/conversation-provider.d.cts +12 -0
  299. package/dist/providers/conversation-provider.d.ts +12 -0
  300. package/dist/providers/conversation-provider.js +49 -0
  301. package/dist/providers/feedback-item-provider.cjs +1 -0
  302. package/dist/providers/feedback-item-provider.d.cts +10 -0
  303. package/dist/providers/feedback-item-provider.d.ts +10 -0
  304. package/dist/providers/feedback-item-provider.js +16 -0
  305. package/dist/providers/feedback-provider.cjs +1 -0
  306. package/dist/providers/feedback-provider.d.cts +19 -0
  307. package/dist/providers/feedback-provider.d.ts +19 -0
  308. package/dist/providers/feedback-provider.js +82 -0
  309. package/dist/providers/form-field-provider.cjs +1 -0
  310. package/dist/providers/form-field-provider.d.cts +15 -0
  311. package/dist/providers/form-field-provider.d.ts +15 -0
  312. package/dist/providers/form-field-provider.js +17 -0
  313. package/dist/providers/help-menu-provider.cjs +1 -0
  314. package/dist/providers/help-menu-provider.d.cts +11 -0
  315. package/dist/providers/help-menu-provider.d.ts +11 -0
  316. package/dist/providers/help-menu-provider.js +19 -0
  317. package/dist/providers/index.cjs +1 -0
  318. package/dist/providers/index.d.cts +19 -0
  319. package/dist/providers/index.d.ts +19 -0
  320. package/dist/providers/index.js +63 -0
  321. package/dist/providers/intelligent-form-field-provider.cjs +1 -0
  322. package/dist/providers/intelligent-form-field-provider.d.cts +15 -0
  323. package/dist/providers/intelligent-form-field-provider.d.ts +15 -0
  324. package/dist/providers/intelligent-form-field-provider.js +19 -0
  325. package/dist/providers/markdown-provider.cjs +1 -0
  326. package/dist/providers/markdown-provider.d.cts +9 -0
  327. package/dist/providers/markdown-provider.d.ts +9 -0
  328. package/dist/providers/markdown-provider.js +8 -0
  329. package/dist/providers/message-attachments-provider.cjs +1 -0
  330. package/dist/providers/message-attachments-provider.d.cts +13 -0
  331. package/dist/providers/message-attachments-provider.d.ts +13 -0
  332. package/dist/providers/message-attachments-provider.js +27 -0
  333. package/dist/providers/message-provider.cjs +1 -0
  334. package/dist/providers/message-provider.d.cts +10 -0
  335. package/dist/providers/message-provider.d.ts +10 -0
  336. package/dist/providers/message-provider.js +14 -0
  337. package/dist/providers/root-provider.cjs +1 -0
  338. package/dist/providers/root-provider.d.cts +8 -0
  339. package/dist/providers/root-provider.d.ts +8 -0
  340. package/dist/providers/root-provider.js +21 -0
  341. package/dist/providers/search-events-provider.cjs +1 -0
  342. package/dist/providers/search-events-provider.d.cts +11 -0
  343. package/dist/providers/search-events-provider.d.ts +11 -0
  344. package/dist/providers/search-events-provider.js +18 -0
  345. package/dist/providers/source-item-provider.cjs +1 -0
  346. package/dist/providers/source-item-provider.d.cts +12 -0
  347. package/dist/providers/source-item-provider.d.ts +12 -0
  348. package/dist/providers/source-item-provider.js +13 -0
  349. package/dist/providers/theme-provider.cjs +1 -0
  350. package/dist/providers/theme-provider.d.cts +3 -0
  351. package/dist/providers/theme-provider.d.ts +3 -0
  352. package/dist/providers/theme-provider.js +65 -0
  353. package/dist/providers/user-provider.cjs +1 -0
  354. package/dist/providers/user-provider.d.cts +13 -0
  355. package/dist/providers/user-provider.d.ts +13 -0
  356. package/dist/providers/user-provider.js +34 -0
  357. package/dist/providers/widget-provider.cjs +1 -0
  358. package/dist/providers/widget-provider.d.cts +9 -0
  359. package/dist/providers/widget-provider.d.ts +9 -0
  360. package/dist/providers/widget-provider.js +8 -0
  361. package/dist/utils/component-ids.cjs +1 -0
  362. package/dist/utils/component-ids.d.cts +632 -0
  363. package/dist/utils/component-ids.d.ts +632 -0
  364. package/dist/utils/component-ids.js +340 -0
  365. package/dist/utils/compose-event-handlers.cjs +1 -0
  366. package/dist/utils/compose-event-handlers.d.cts +3 -0
  367. package/dist/utils/compose-event-handlers.d.ts +3 -0
  368. package/dist/utils/compose-event-handlers.js +10 -0
  369. package/dist/utils/compose-refs.cjs +1 -0
  370. package/dist/utils/compose-refs.d.cts +5 -0
  371. package/dist/utils/compose-refs.d.ts +5 -0
  372. package/dist/utils/compose-refs.js +30 -0
  373. package/dist/utils/default-settings.cjs +1 -0
  374. package/dist/utils/default-settings.d.cts +244 -0
  375. package/dist/utils/default-settings.d.ts +244 -0
  376. package/dist/utils/default-settings.js +75 -0
  377. package/dist/utils/form.cjs +1 -0
  378. package/dist/utils/form.d.cts +3 -0
  379. package/dist/utils/form.d.ts +3 -0
  380. package/dist/utils/form.js +17 -0
  381. package/dist/utils/generate-uid.cjs +1 -0
  382. package/dist/utils/generate-uid.d.cts +2 -0
  383. package/dist/utils/generate-uid.d.ts +2 -0
  384. package/dist/utils/generate-uid.js +14 -0
  385. package/dist/utils/get-message-metadata.cjs +10 -0
  386. package/dist/utils/get-message-metadata.d.cts +8 -0
  387. package/dist/utils/get-message-metadata.d.ts +8 -0
  388. package/dist/utils/get-message-metadata.js +142 -0
  389. package/dist/utils/graphql-client.cjs +1 -0
  390. package/dist/utils/graphql-client.d.cts +8 -0
  391. package/dist/utils/graphql-client.d.ts +8 -0
  392. package/dist/utils/graphql-client.js +23 -0
  393. package/dist/utils/highlight-emphasis.cjs +1 -0
  394. package/dist/utils/highlight-emphasis.d.cts +4 -0
  395. package/dist/utils/highlight-emphasis.d.ts +4 -0
  396. package/dist/utils/highlight-emphasis.js +15 -0
  397. package/dist/utils/merge-props.cjs +1 -0
  398. package/dist/utils/merge-props.d.cts +7 -0
  399. package/dist/utils/merge-props.d.ts +7 -0
  400. package/dist/utils/merge-props.js +41 -0
  401. package/dist/utils/misc.cjs +1 -0
  402. package/dist/utils/misc.d.cts +13 -0
  403. package/dist/utils/misc.d.ts +13 -0
  404. package/dist/utils/misc.js +36 -0
  405. package/dist/utils/reset-query-params.cjs +1 -0
  406. package/dist/utils/reset-query-params.d.cts +1 -0
  407. package/dist/utils/reset-query-params.d.ts +1 -0
  408. package/dist/utils/reset-query-params.js +13 -0
  409. package/dist/utils/tools/links-schema.cjs +1 -0
  410. package/dist/utils/tools/links-schema.d.cts +64 -0
  411. package/dist/utils/tools/links-schema.d.ts +64 -0
  412. package/dist/utils/tools/links-schema.js +85 -0
  413. package/dist/utils/transform-source/breadcrumbs.cjs +1 -0
  414. package/dist/utils/transform-source/breadcrumbs.d.cts +2 -0
  415. package/dist/utils/transform-source/breadcrumbs.d.ts +2 -0
  416. package/dist/utils/transform-source/breadcrumbs.js +16 -0
  417. package/dist/utils/transform-source/common-words/long.cjs +1 -0
  418. package/dist/utils/transform-source/common-words/long.d.cts +1 -0
  419. package/dist/utils/transform-source/common-words/long.d.ts +1 -0
  420. package/dist/utils/transform-source/common-words/long.js +69 -0
  421. package/dist/utils/transform-source/common-words/lowercase.cjs +1 -0
  422. package/dist/utils/transform-source/common-words/lowercase.d.cts +1 -0
  423. package/dist/utils/transform-source/common-words/lowercase.d.ts +1 -0
  424. package/dist/utils/transform-source/common-words/lowercase.js +48 -0
  425. package/dist/utils/transform-source/common-words/short.cjs +1 -0
  426. package/dist/utils/transform-source/common-words/short.d.cts +1 -0
  427. package/dist/utils/transform-source/common-words/short.d.ts +1 -0
  428. package/dist/utils/transform-source/common-words/short.js +141 -0
  429. package/dist/utils/transform-source/description.cjs +1 -0
  430. package/dist/utils/transform-source/description.d.cts +2 -0
  431. package/dist/utils/transform-source/description.d.ts +2 -0
  432. package/dist/utils/transform-source/description.js +10 -0
  433. package/dist/utils/transform-source/icon.cjs +1 -0
  434. package/dist/utils/transform-source/icon.d.cts +2 -0
  435. package/dist/utils/transform-source/icon.d.ts +2 -0
  436. package/dist/utils/transform-source/icon.js +9 -0
  437. package/dist/utils/transform-source/index.cjs +1 -0
  438. package/dist/utils/transform-source/index.d.cts +2 -0
  439. package/dist/utils/transform-source/index.d.ts +2 -0
  440. package/dist/utils/transform-source/index.js +21 -0
  441. package/dist/utils/transform-source/tabs.cjs +1 -0
  442. package/dist/utils/transform-source/tabs.d.cts +2 -0
  443. package/dist/utils/transform-source/tabs.d.ts +2 -0
  444. package/dist/utils/transform-source/tabs.js +13 -0
  445. package/dist/utils/transform-source/title.cjs +1 -0
  446. package/dist/utils/transform-source/title.d.cts +2 -0
  447. package/dist/utils/transform-source/title.d.ts +2 -0
  448. package/dist/utils/transform-source/title.js +12 -0
  449. package/dist/utils/transform-source/utils/description-without-title.cjs +1 -0
  450. package/dist/utils/transform-source/utils/description-without-title.d.cts +11 -0
  451. package/dist/utils/transform-source/utils/description-without-title.d.ts +11 -0
  452. package/dist/utils/transform-source/utils/description-without-title.js +12 -0
  453. package/dist/utils/transform-source/utils/index.cjs +1 -0
  454. package/dist/utils/transform-source/utils/index.d.cts +6 -0
  455. package/dist/utils/transform-source/utils/index.d.ts +6 -0
  456. package/dist/utils/transform-source/utils/index.js +16 -0
  457. package/dist/utils/transform-source/utils/misc.cjs +1 -0
  458. package/dist/utils/transform-source/utils/misc.d.cts +2 -0
  459. package/dist/utils/transform-source/utils/misc.d.ts +2 -0
  460. package/dist/utils/transform-source/utils/misc.js +15 -0
  461. package/dist/utils/transform-source/utils/standardize-common-words.cjs +1 -0
  462. package/dist/utils/transform-source/utils/standardize-common-words.d.cts +1 -0
  463. package/dist/utils/transform-source/utils/standardize-common-words.d.ts +1 -0
  464. package/dist/utils/transform-source/utils/standardize-common-words.js +26 -0
  465. package/dist/utils/transform-source/utils/standardize-organization-display-name.cjs +1 -0
  466. package/dist/utils/transform-source/utils/standardize-organization-display-name.d.cts +8 -0
  467. package/dist/utils/transform-source/utils/standardize-organization-display-name.d.ts +8 -0
  468. package/dist/utils/transform-source/utils/standardize-organization-display-name.js +10 -0
  469. package/dist/utils/transform-source/utils/standardize-suffixes.cjs +1 -0
  470. package/dist/utils/transform-source/utils/standardize-suffixes.d.cts +5 -0
  471. package/dist/utils/transform-source/utils/standardize-suffixes.d.ts +5 -0
  472. package/dist/utils/transform-source/utils/standardize-suffixes.js +16 -0
  473. package/dist/utils/transform-source/utils/strip-branding-keywords.cjs +1 -0
  474. package/dist/utils/transform-source/utils/strip-branding-keywords.d.cts +17 -0
  475. package/dist/utils/transform-source/utils/strip-branding-keywords.d.ts +17 -0
  476. package/dist/utils/transform-source/utils/strip-branding-keywords.js +14 -0
  477. package/package.json +111 -0
@@ -0,0 +1,18 @@
1
+ import { ComponentPropsWithRef, ForwardRefExoticComponent, RefAttributes } from 'react';
2
+ import { InkeepModalSettings } from '@inkeep/cxkit-types';
3
+ import { PolymorphicProps } from './factory';
4
+ import * as DialogPrimitive from '../atoms/dialog';
5
+ declare const Modal: ForwardRefExoticComponent< PolymorphicProps & Omit<DialogPrimitive.DialogProps, "_id"> & Partial<Pick<DialogPrimitive.DialogProps, "_id">>>;
6
+ export interface PrimitiveModalProps extends ComponentPropsWithRef<typeof Modal> {
7
+ /**
8
+ * Configuration for the modal.
9
+ */
10
+ config?: InkeepModalSettings;
11
+ }
12
+ declare const PrimitiveModal: (props: PrimitiveModalProps) => import("react/jsx-runtime").JSX.Element;
13
+ declare const PrimitiveModalOverlay: ForwardRefExoticComponent< PolymorphicProps & Omit<DialogPrimitive.DialogOverlayProps & RefAttributes<HTMLDivElement>, "_id"> & Partial<Pick<DialogPrimitive.DialogOverlayProps & RefAttributes<HTMLDivElement>, "_id">>>;
14
+ declare const ModalContent: ForwardRefExoticComponent< PolymorphicProps & Omit<DialogPrimitive.DialogContentProps & RefAttributes<HTMLDivElement>, "aria-describedby" | "_id"> & Partial<Pick<DialogPrimitive.DialogContentProps & RefAttributes<HTMLDivElement>, "aria-describedby" | "_id">>>;
15
+ declare const PrimitiveModalContent: (props: ComponentPropsWithRef<typeof ModalContent>) => import("react/jsx-runtime").JSX.Element;
16
+ declare const ModalClose: ForwardRefExoticComponent< PolymorphicProps & Omit<DialogPrimitive.DialogCloseProps & RefAttributes<HTMLButtonElement>, "children" | "_id"> & Partial<Pick<DialogPrimitive.DialogCloseProps & RefAttributes<HTMLButtonElement>, "children" | "_id">>>;
17
+ declare const PrimitiveModalClose: (props: ComponentPropsWithRef<typeof ModalClose>) => import("react/jsx-runtime").JSX.Element | null;
18
+ export { PrimitiveModal as Modal, PrimitiveModalOverlay as Overlay, PrimitiveModalContent as Content, PrimitiveModalClose as Close, };
@@ -0,0 +1,40 @@
1
+ "use client";
2
+ import { jsx as e } from "react/jsx-runtime";
3
+ import { Overlay as l, Root as d, Content as m, Close as s } from "../atoms/dialog.js";
4
+ import { ikp as n } from "./factory.js";
5
+ import { CustomIcon as c } from "../atoms/icons/custom-icon.js";
6
+ import { useInkeepModal as p } from "./modal/use-inkeep-modal.js";
7
+ import { ModalProvider as C, useModal as M } from "./modal/modal-provider.js";
8
+ import { composeEventHandlers as f } from "../utils/compose-event-handlers.js";
9
+ import { useMediaQuery as u } from "../hooks/use-media-query.js";
10
+ import { dataAttr as v } from "../utils/misc.js";
11
+ const _ = n(d, {
12
+ _id: "modal"
13
+ }), A = (o) => {
14
+ const { onOpenChange: t, config: i, ...a } = o, r = p(i);
15
+ return /* @__PURE__ */ e(C, { modal: r, children: /* @__PURE__ */ e(
16
+ _,
17
+ {
18
+ open: r.open,
19
+ onOpenChange: f(t, r.handleOpenChange),
20
+ ...a
21
+ }
22
+ ) });
23
+ }, E = n(l, {
24
+ _id: "modal__Overlay"
25
+ }), h = n(m, {
26
+ _id: "modal__Content",
27
+ "aria-describedby": void 0
28
+ }), H = (o) => {
29
+ const t = u("(max-width: 768px)");
30
+ return /* @__PURE__ */ e(h, { "data-mobile": v(t), ...o });
31
+ }, y = n(s, {
32
+ _id: "modal__Close",
33
+ children: /* @__PURE__ */ e(c, { iconKey: "close" })
34
+ }), K = (o) => M() ? /* @__PURE__ */ e(y, { ...o }) : null;
35
+ export {
36
+ K as Close,
37
+ H as Content,
38
+ A as Modal,
39
+ E as Overlay
40
+ };
@@ -0,0 +1 @@
1
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react/jsx-runtime"),r=require("./factory.cjs"),a=require("../atoms/icons/custom-icon.cjs"),n=require("../providers/config-provider.cjs"),o=r.ikp("div",{_id:"searchBar__Container"}),s=r.ikp("button",{_id:"searchBar__Button",type:"button"}),d=r.ikp("div",{_id:"searchBar__ContentWrapper"}),h=r.ikp("div",{_id:"searchBar__Text"}),u=e=>{const{searchSettings:{placeholder:i}}=n.useInkeepConfig();return t.jsx(h,{...e,children:i})},B=r.ikp(a.CustomIcon,{_id:"searchBar__Icon",iconKey:"search"}),p=r.ikp("kbd",{_id:"searchBar__KbdWrapper"}),_=r.ikp("kbd",{_id:"searchBar__KbdShortcutKey"}),S=e=>{const{shortcutKey:i,...c}=e;return t.jsx(_,{...c,children:i?.toUpperCase()})},m=()=>{if(typeof window>"u")return!1;const e=window.navigator?.userAgent?.toLowerCase();return e.includes("macintosh")||e.includes("mac os x")},l=r.ikp("kbd",{_id:"searchBar__Ctrl",children:"Ctrl"}),v=r.ikp(a.CustomIcon,{_id:"searchBar__CmdIcon",iconKey:"command"}),K=e=>{const{shortcutKey:i,...c}=e;return t.jsx(t.Fragment,{children:i?m()?t.jsx(v,{...c}):t.jsx(l,{...c}):null})};exports.SearchBarButton=s;exports.SearchBarContainer=o;exports.SearchBarContentWrapper=d;exports.SearchBarIcon=B;exports.SearchBarKbdModifier=K;exports.SearchBarKbdShortcutKey=S;exports.SearchBarKbdWrapper=p;exports.SearchBarText=u;
@@ -0,0 +1,23 @@
1
+ import { ComponentPropsWithRef, ForwardRefExoticComponent, DetailedHTMLProps, HTMLAttributes, ButtonHTMLAttributes } from 'react';
2
+ import { InkeepModalSettings } from '@inkeep/cxkit-types';
3
+ import { PolymorphicProps } from './factory';
4
+ import { CustomIconProps } from '..';
5
+ declare const SearchBarContainer: ForwardRefExoticComponent< PolymorphicProps & Omit< DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "_id"> & Partial<Pick< DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "_id">>>;
6
+ declare const SearchBarPrimitiveButton: ForwardRefExoticComponent< PolymorphicProps & Omit< DetailedHTMLProps<ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "type" | "_id"> & Partial<Pick< DetailedHTMLProps<ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "type" | "_id">>>;
7
+ declare const SearchBarPrimitiveContentWrapper: ForwardRefExoticComponent< PolymorphicProps & Omit< DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "_id"> & Partial<Pick< DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "_id">>>;
8
+ declare const PrimitiveSearchBarText: ForwardRefExoticComponent< PolymorphicProps & Omit< DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "_id"> & Partial<Pick< DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "_id">>>;
9
+ declare const SearchBarPrimitiveText: (props: ComponentPropsWithRef<typeof PrimitiveSearchBarText>) => import("react/jsx-runtime").JSX.Element;
10
+ declare const SearchBarPrimitiveIcon: ForwardRefExoticComponent< PolymorphicProps & Omit< CustomIconProps, "_id" | "iconKey"> & Partial<Pick< CustomIconProps, "_id" | "iconKey">>>;
11
+ declare const SearchBarPrimitiveKbdWrapper: ForwardRefExoticComponent< PolymorphicProps & Omit< DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement>, "_id"> & Partial<Pick< DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement>, "_id">>>;
12
+ declare const PrimitiveKbdShortcutKey: ForwardRefExoticComponent< PolymorphicProps & Omit< DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement>, "_id"> & Partial<Pick< DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement>, "_id">>>;
13
+ type SearchBarPrimitiveKbdShortcutKeyProps = ComponentPropsWithRef<typeof PrimitiveKbdShortcutKey> & {
14
+ shortcutKey?: InkeepModalSettings['shortcutKey'];
15
+ };
16
+ declare const SearchBarPrimitiveKbdShortcutKey: (props: SearchBarPrimitiveKbdShortcutKeyProps) => import("react/jsx-runtime").JSX.Element;
17
+ declare const SearchBarPrimitiveCtrl: ForwardRefExoticComponent< PolymorphicProps & Omit< DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement>, "children" | "_id"> & Partial<Pick< DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement>, "children" | "_id">>>;
18
+ declare const SearchBarPrimitiveCmdIcon: ForwardRefExoticComponent< PolymorphicProps & Omit< CustomIconProps, "_id" | "iconKey"> & Partial<Pick< CustomIconProps, "_id" | "iconKey">>>;
19
+ type SearchBarPrimitiveKbdModifierProps = ComponentPropsWithRef<typeof SearchBarPrimitiveCtrl | typeof SearchBarPrimitiveCmdIcon> & {
20
+ shortcutKey?: InkeepModalSettings['shortcutKey'];
21
+ };
22
+ declare const SearchBarPrimitiveKbdModifier: (props: SearchBarPrimitiveKbdModifierProps) => import("react/jsx-runtime").JSX.Element;
23
+ export { SearchBarContainer, SearchBarPrimitiveButton as SearchBarButton, SearchBarPrimitiveText as SearchBarText, SearchBarPrimitiveContentWrapper as SearchBarContentWrapper, SearchBarPrimitiveIcon as SearchBarIcon, SearchBarPrimitiveKbdWrapper as SearchBarKbdWrapper, SearchBarPrimitiveKbdModifier as SearchBarKbdModifier, SearchBarPrimitiveKbdShortcutKey as SearchBarKbdShortcutKey, };
@@ -0,0 +1,23 @@
1
+ import { ComponentPropsWithRef, ForwardRefExoticComponent, DetailedHTMLProps, HTMLAttributes, ButtonHTMLAttributes } from 'react';
2
+ import { InkeepModalSettings } from '@inkeep/cxkit-types';
3
+ import { PolymorphicProps } from './factory';
4
+ import { CustomIconProps } from '..';
5
+ declare const SearchBarContainer: ForwardRefExoticComponent< PolymorphicProps & Omit< DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "_id"> & Partial<Pick< DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "_id">>>;
6
+ declare const SearchBarPrimitiveButton: ForwardRefExoticComponent< PolymorphicProps & Omit< DetailedHTMLProps<ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "type" | "_id"> & Partial<Pick< DetailedHTMLProps<ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "type" | "_id">>>;
7
+ declare const SearchBarPrimitiveContentWrapper: ForwardRefExoticComponent< PolymorphicProps & Omit< DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "_id"> & Partial<Pick< DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "_id">>>;
8
+ declare const PrimitiveSearchBarText: ForwardRefExoticComponent< PolymorphicProps & Omit< DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "_id"> & Partial<Pick< DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "_id">>>;
9
+ declare const SearchBarPrimitiveText: (props: ComponentPropsWithRef<typeof PrimitiveSearchBarText>) => import("react/jsx-runtime").JSX.Element;
10
+ declare const SearchBarPrimitiveIcon: ForwardRefExoticComponent< PolymorphicProps & Omit< CustomIconProps, "_id" | "iconKey"> & Partial<Pick< CustomIconProps, "_id" | "iconKey">>>;
11
+ declare const SearchBarPrimitiveKbdWrapper: ForwardRefExoticComponent< PolymorphicProps & Omit< DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement>, "_id"> & Partial<Pick< DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement>, "_id">>>;
12
+ declare const PrimitiveKbdShortcutKey: ForwardRefExoticComponent< PolymorphicProps & Omit< DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement>, "_id"> & Partial<Pick< DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement>, "_id">>>;
13
+ type SearchBarPrimitiveKbdShortcutKeyProps = ComponentPropsWithRef<typeof PrimitiveKbdShortcutKey> & {
14
+ shortcutKey?: InkeepModalSettings['shortcutKey'];
15
+ };
16
+ declare const SearchBarPrimitiveKbdShortcutKey: (props: SearchBarPrimitiveKbdShortcutKeyProps) => import("react/jsx-runtime").JSX.Element;
17
+ declare const SearchBarPrimitiveCtrl: ForwardRefExoticComponent< PolymorphicProps & Omit< DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement>, "children" | "_id"> & Partial<Pick< DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement>, "children" | "_id">>>;
18
+ declare const SearchBarPrimitiveCmdIcon: ForwardRefExoticComponent< PolymorphicProps & Omit< CustomIconProps, "_id" | "iconKey"> & Partial<Pick< CustomIconProps, "_id" | "iconKey">>>;
19
+ type SearchBarPrimitiveKbdModifierProps = ComponentPropsWithRef<typeof SearchBarPrimitiveCtrl | typeof SearchBarPrimitiveCmdIcon> & {
20
+ shortcutKey?: InkeepModalSettings['shortcutKey'];
21
+ };
22
+ declare const SearchBarPrimitiveKbdModifier: (props: SearchBarPrimitiveKbdModifierProps) => import("react/jsx-runtime").JSX.Element;
23
+ export { SearchBarContainer, SearchBarPrimitiveButton as SearchBarButton, SearchBarPrimitiveText as SearchBarText, SearchBarPrimitiveContentWrapper as SearchBarContentWrapper, SearchBarPrimitiveIcon as SearchBarIcon, SearchBarPrimitiveKbdWrapper as SearchBarKbdWrapper, SearchBarPrimitiveKbdModifier as SearchBarKbdModifier, SearchBarPrimitiveKbdShortcutKey as SearchBarKbdShortcutKey, };
@@ -0,0 +1,54 @@
1
+ "use client";
2
+ import { jsx as a, Fragment as n } from "react/jsx-runtime";
3
+ import { ikp as r } from "./factory.js";
4
+ import { CustomIcon as c } from "../atoms/icons/custom-icon.js";
5
+ import { useInkeepConfig as o } from "../providers/config-provider.js";
6
+ const K = r("div", {
7
+ _id: "searchBar__Container"
8
+ }), l = r("button", {
9
+ _id: "searchBar__Button",
10
+ type: "button"
11
+ }), v = r("div", {
12
+ _id: "searchBar__ContentWrapper"
13
+ }), s = r("div", {
14
+ _id: "searchBar__Text"
15
+ }), b = (e) => {
16
+ const {
17
+ searchSettings: { placeholder: t }
18
+ } = o();
19
+ return /* @__PURE__ */ a(s, { ...e, children: t });
20
+ }, C = r(c, {
21
+ _id: "searchBar__Icon",
22
+ iconKey: "search"
23
+ }), f = r("kbd", {
24
+ _id: "searchBar__KbdWrapper"
25
+ }), h = r("kbd", {
26
+ _id: "searchBar__KbdShortcutKey"
27
+ }), P = (e) => {
28
+ const { shortcutKey: t, ...i } = e;
29
+ return /* @__PURE__ */ a(h, { ...i, children: t?.toUpperCase() });
30
+ }, d = () => {
31
+ if (typeof window > "u")
32
+ return !1;
33
+ const e = window.navigator?.userAgent?.toLowerCase();
34
+ return e.includes("macintosh") || e.includes("mac os x");
35
+ }, B = r("kbd", {
36
+ _id: "searchBar__Ctrl",
37
+ children: "Ctrl"
38
+ }), m = r(c, {
39
+ _id: "searchBar__CmdIcon",
40
+ iconKey: "command"
41
+ }), y = (e) => {
42
+ const { shortcutKey: t, ...i } = e;
43
+ return /* @__PURE__ */ a(n, { children: t ? d() ? /* @__PURE__ */ a(m, { ...i }) : /* @__PURE__ */ a(B, { ...i }) : null });
44
+ };
45
+ export {
46
+ l as SearchBarButton,
47
+ K as SearchBarContainer,
48
+ v as SearchBarContentWrapper,
49
+ C as SearchBarIcon,
50
+ y as SearchBarKbdModifier,
51
+ P as SearchBarKbdShortcutKey,
52
+ f as SearchBarKbdWrapper,
53
+ b as SearchBarText
54
+ };
@@ -0,0 +1 @@
1
+ "use client";"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("react/jsx-runtime"),r=require("@radix-ui/react-id");function s(o){const t=r.useId();return e.jsxs("svg",{viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg",...o,children:[e.jsx("title",{children:"Tag Line Logo Icon"}),e.jsx("path",{d:"M32 4.01845V25.1411C32 26.3154 30.9971 27.2462 29.8223 27.1531L16.9277 26.1507C15.409 26.0361 13.8903 26.3727 12.565 27.1173L8.11641 29.6234C7.72241 29.8454 7.29259 29.3943 7.54332 29.0148L9.77121 25.5922L11.8415 22.4131C12.0636 22.0694 12.4934 21.9119 12.8874 22.0336C16.1397 23.079 19.8075 21.8761 21.7631 18.8831C24.0913 15.2886 23.0741 10.4913 19.4851 8.15706C15.8961 5.82282 11.0965 6.83958 8.76114 10.4269C6.81263 13.427 7.19946 17.272 9.4775 19.8139C9.74972 20.1218 9.77837 20.5729 9.5563 20.9237L6.92724 24.9621C6.76964 25.1984 6.49743 25.3344 6.21804 25.313L1.4184 24.9406C0.616073 24.8834 0 24.2175 0 23.4155V5.7369C0 4.93496 0.616073 4.26905 1.4184 4.21177L29.8294 2.00642C31.0043 1.91334 32 2.84417 32 4.01845ZM15.2586 9.35282C12.3286 9.35282 9.95747 11.7229 9.95747 14.6514C9.95747 16.0763 10.5234 17.3723 11.4403 18.3246C11.9991 18.9046 12.6868 19.3557 13.4605 19.6349C14.0264 19.8354 14.6282 19.95 15.2657 19.95C18.1957 19.95 20.5668 17.5799 20.5668 14.6514C20.5597 11.73 18.1885 9.35282 15.2586 9.35282Z",fill:`url(#${t})`}),e.jsx("defs",{children:e.jsxs("linearGradient",{id:t,x1:"1.5893",y1:"25.285",x2:"24.0784",y2:"10.1057",gradientUnits:"userSpaceOnUse",children:[e.jsx("stop",{stopColor:"currentColor"}),e.jsx("stop",{offset:"1",stopColor:"currentColor"})]})})]})}exports.default=s;
@@ -0,0 +1 @@
1
+ export default function TagLineLogoIcon(props: React.SVGProps<SVGSVGElement>): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1 @@
1
+ export default function TagLineLogoIcon(props: React.SVGProps<SVGSVGElement>): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,34 @@
1
+ "use client";
2
+ import { jsxs as r, jsx as o } from "react/jsx-runtime";
3
+ import { useId as t } from "@radix-ui/react-id";
4
+ function s(n) {
5
+ const e = t();
6
+ return /* @__PURE__ */ r("svg", { viewBox: "0 0 32 32", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...n, children: [
7
+ /* @__PURE__ */ o("title", { children: "Tag Line Logo Icon" }),
8
+ /* @__PURE__ */ o(
9
+ "path",
10
+ {
11
+ d: "M32 4.01845V25.1411C32 26.3154 30.9971 27.2462 29.8223 27.1531L16.9277 26.1507C15.409 26.0361 13.8903 26.3727 12.565 27.1173L8.11641 29.6234C7.72241 29.8454 7.29259 29.3943 7.54332 29.0148L9.77121 25.5922L11.8415 22.4131C12.0636 22.0694 12.4934 21.9119 12.8874 22.0336C16.1397 23.079 19.8075 21.8761 21.7631 18.8831C24.0913 15.2886 23.0741 10.4913 19.4851 8.15706C15.8961 5.82282 11.0965 6.83958 8.76114 10.4269C6.81263 13.427 7.19946 17.272 9.4775 19.8139C9.74972 20.1218 9.77837 20.5729 9.5563 20.9237L6.92724 24.9621C6.76964 25.1984 6.49743 25.3344 6.21804 25.313L1.4184 24.9406C0.616073 24.8834 0 24.2175 0 23.4155V5.7369C0 4.93496 0.616073 4.26905 1.4184 4.21177L29.8294 2.00642C31.0043 1.91334 32 2.84417 32 4.01845ZM15.2586 9.35282C12.3286 9.35282 9.95747 11.7229 9.95747 14.6514C9.95747 16.0763 10.5234 17.3723 11.4403 18.3246C11.9991 18.9046 12.6868 19.3557 13.4605 19.6349C14.0264 19.8354 14.6282 19.95 15.2657 19.95C18.1957 19.95 20.5668 17.5799 20.5668 14.6514C20.5597 11.73 18.1885 9.35282 15.2586 9.35282Z",
12
+ fill: `url(#${e})`
13
+ }
14
+ ),
15
+ /* @__PURE__ */ o("defs", { children: /* @__PURE__ */ r(
16
+ "linearGradient",
17
+ {
18
+ id: e,
19
+ x1: "1.5893",
20
+ y1: "25.285",
21
+ x2: "24.0784",
22
+ y2: "10.1057",
23
+ gradientUnits: "userSpaceOnUse",
24
+ children: [
25
+ /* @__PURE__ */ o("stop", { stopColor: "currentColor" }),
26
+ /* @__PURE__ */ o("stop", { offset: "1", stopColor: "currentColor" })
27
+ ]
28
+ }
29
+ ) })
30
+ ] });
31
+ }
32
+ export {
33
+ s as default
34
+ };
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("./use-boolean.cjs"),e=require("./use-browser-storage.cjs"),o=require("./use-component-classnames.cjs"),r=require("./use-container-size.cjs"),u=require("./use-copy-to-clipboard.cjs"),t=require("./use-instant-update.cjs"),n=require("./use-is-mounted.cjs"),a=require("./use-media-query.cjs"),i=require("./use-resize-observer.cjs"),l=require("./use-scrolling-fades.cjs"),c=require("./use-settle-action.cjs"),S=require("./use-scroll-to-bottom.cjs");exports.useBoolean=s.useBoolean;exports.passesBrowserStorageChecks=e.passesBrowserStorageChecks;exports.useBrowserStorage=e.useBrowserStorage;exports.useComponentClassNames=o.useComponentClassNames;exports.useContainerSize=r.useContainerSize;exports.useCopyToClipboard=u.useCopyToClipboard;exports.useInstantUpdate=t.useInstantUpdate;exports.useIsMounted=n.useIsMounted;exports.useMediaQuery=a.useMediaQuery;exports.useResizeObserver=i.useResizeObserver;exports.useScrollingFades=l.useScrollingFades;exports.useSettleAction=c.useSettleAction;exports.useScrollToBottom=S.useScrollToBottom;
@@ -0,0 +1,12 @@
1
+ export * from './use-boolean';
2
+ export * from './use-browser-storage';
3
+ export * from './use-component-classnames';
4
+ export * from './use-container-size';
5
+ export * from './use-copy-to-clipboard';
6
+ export * from './use-instant-update';
7
+ export * from './use-is-mounted';
8
+ export * from './use-media-query';
9
+ export * from './use-resize-observer';
10
+ export * from './use-scrolling-fades';
11
+ export * from './use-settle-action';
12
+ export * from './use-scroll-to-bottom';
@@ -0,0 +1,12 @@
1
+ export * from './use-boolean';
2
+ export * from './use-browser-storage';
3
+ export * from './use-component-classnames';
4
+ export * from './use-container-size';
5
+ export * from './use-copy-to-clipboard';
6
+ export * from './use-instant-update';
7
+ export * from './use-is-mounted';
8
+ export * from './use-media-query';
9
+ export * from './use-resize-observer';
10
+ export * from './use-scrolling-fades';
11
+ export * from './use-settle-action';
12
+ export * from './use-scroll-to-bottom';
@@ -0,0 +1,27 @@
1
+ import { useBoolean as r } from "./use-boolean.js";
2
+ import { passesBrowserStorageChecks as t, useBrowserStorage as p } from "./use-browser-storage.js";
3
+ import { useComponentClassNames as u } from "./use-component-classnames.js";
4
+ import { useContainerSize as f } from "./use-container-size.js";
5
+ import { useCopyToClipboard as n } from "./use-copy-to-clipboard.js";
6
+ import { useInstantUpdate as i } from "./use-instant-update.js";
7
+ import { useIsMounted as S } from "./use-is-mounted.js";
8
+ import { useMediaQuery as c } from "./use-media-query.js";
9
+ import { useResizeObserver as g } from "./use-resize-observer.js";
10
+ import { useScrollingFades as w } from "./use-scrolling-fades.js";
11
+ import { useSettleAction as z } from "./use-settle-action.js";
12
+ import { useScrollToBottom as M } from "./use-scroll-to-bottom.js";
13
+ export {
14
+ t as passesBrowserStorageChecks,
15
+ r as useBoolean,
16
+ p as useBrowserStorage,
17
+ u as useComponentClassNames,
18
+ f as useContainerSize,
19
+ n as useCopyToClipboard,
20
+ i as useInstantUpdate,
21
+ S as useIsMounted,
22
+ c as useMediaQuery,
23
+ g as useResizeObserver,
24
+ M as useScrollToBottom,
25
+ w as useScrollingFades,
26
+ z as useSettleAction
27
+ };
@@ -0,0 +1 @@
1
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react");function n(s=!1){if(typeof s!="boolean")throw new Error("defaultValue must be `true` or `false`");const[o,e]=t.useState(s),l=t.useCallback(()=>{e(!0)},[]),a=t.useCallback(()=>{e(!1)},[]),u=t.useCallback(()=>{e(r=>!r)},[]);return{value:o,setValue:e,setTrue:l,setFalse:a,toggle:u}}exports.useBoolean=n;
@@ -0,0 +1,10 @@
1
+ import { Dispatch, SetStateAction } from 'react';
2
+ type UseBooleanReturn = {
3
+ value: boolean;
4
+ setValue: Dispatch<SetStateAction<boolean>>;
5
+ setTrue: () => void;
6
+ setFalse: () => void;
7
+ toggle: () => void;
8
+ };
9
+ export declare function useBoolean(defaultValue?: boolean): UseBooleanReturn;
10
+ export {};
@@ -0,0 +1,10 @@
1
+ import { Dispatch, SetStateAction } from 'react';
2
+ type UseBooleanReturn = {
3
+ value: boolean;
4
+ setValue: Dispatch<SetStateAction<boolean>>;
5
+ setTrue: () => void;
6
+ setFalse: () => void;
7
+ toggle: () => void;
8
+ };
9
+ export declare function useBoolean(defaultValue?: boolean): UseBooleanReturn;
10
+ export {};
@@ -0,0 +1,17 @@
1
+ "use client";
2
+ import { useState as n, useCallback as t } from "react";
3
+ function f(o = !1) {
4
+ if (typeof o != "boolean")
5
+ throw new Error("defaultValue must be `true` or `false`");
6
+ const [s, e] = n(o), r = t(() => {
7
+ e(!0);
8
+ }, []), l = t(() => {
9
+ e(!1);
10
+ }, []), u = t(() => {
11
+ e((a) => !a);
12
+ }, []);
13
+ return { value: s, setValue: e, setTrue: r, setFalse: l, toggle: u };
14
+ }
15
+ export {
16
+ f as useBoolean
17
+ };
@@ -0,0 +1 @@
1
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const S=require("react"),w=require("../providers/config-provider.cjs"),a="inkeepUsagePreferences",_={hasSwitchModeButtonJiggled:!1,userId:null},k={defaultView:null,inkeepChatSessionId:null},d={..._,...k},f={set(e,o,t,n=365){try{if(e==="cookie"){const s=new Date;t===void 0?(s.setTime(s.getTime()-1),document.cookie=`${a}_${o}=; expires=${s.toUTCString()}; path=/`):(s.setTime(s.getTime()+n*24*60*60*1e3),document.cookie=`${a}_${o}=${t}; expires=${s.toUTCString()}; path=/`)}else typeof sessionStorage<"u"&&sessionStorage.setItem(`${a}_${o}`,t?JSON.stringify(t):"")}catch{return null}},get(e,o){if(e==="cookie"){const t=`${a}_${o}=`,n=document.cookie.split(";");for(const s of n){const i=s.trim();if(i.startsWith(t))return i.substring(t.length)}return null}try{if(typeof sessionStorage<"u"){const t=sessionStorage.getItem(`${a}_${o}`);return t?JSON.parse(t):null}}catch{return null}return null}},I=()=>{const{baseSettings:e,interactionType:o}=w.useInkeepConfig(),{optOutAllAnalytics:t,optOutFunctionalCookies:n}=e.analytics,i=!t&&!n&&p()?"cookie":"sessionStorage",m=`${e.apiKey}-${o}`,u=r=>r in k?`${r}-${m}`:r,y=Object.keys(d).reduce((r,c)=>{const l=u(c),g=f.get(i,l);return{...r,[c]:g}},{...d}),[$,h]=S.useState(y),C=(r,c,l=365)=>{const g=u(r);f.set(i,g,c,l),h(b=>({...b,[r]:c}))};return S.useEffect(()=>{if(n)for(const r of Object.keys(d)){const c=u(r);f.set("cookie",c,null,-1)}},[n]),{browserStorage:$,setBrowserStorage:C}},T=()=>{try{if(typeof localStorage>"u")return!1;const e="__df709c5b-6651-43dc-94e7-d8dc899bf4e8__";return localStorage.setItem(e,"test_value"),localStorage.removeItem(e),!0}catch{return!1}},B=()=>{if(typeof document>"u")return!1;document.cookie="testcookie=true; Path=/; Max-Age=1000";const e=document.cookie.includes("testcookie=true");return document.cookie="testcookie=; Path=/; Max-Age=-1000",e},p=()=>{const e=T(),o=B();return e&&o};exports.passesBrowserStorageChecks=p;exports.useBrowserStorage=I;
@@ -0,0 +1,17 @@
1
+ import { ModalViewTypes } from '@inkeep/cxkit-types';
2
+ interface GlobalCookieData {
3
+ hasSwitchModeButtonJiggled?: boolean | null;
4
+ userId?: string | null;
5
+ }
6
+ interface PerInstanceCookieData {
7
+ defaultView?: ModalViewTypes | null;
8
+ inkeepChatSessionId?: string | null;
9
+ }
10
+ type CookieData = GlobalCookieData & PerInstanceCookieData;
11
+ type CookieKey = keyof CookieData;
12
+ export declare const useBrowserStorage: () => {
13
+ browserStorage: CookieData;
14
+ setBrowserStorage: <K extends CookieKey>(name: K, value: CookieData[K] | undefined, days?: number) => void;
15
+ };
16
+ export declare const passesBrowserStorageChecks: () => boolean;
17
+ export {};
@@ -0,0 +1,17 @@
1
+ import { ModalViewTypes } from '@inkeep/cxkit-types';
2
+ interface GlobalCookieData {
3
+ hasSwitchModeButtonJiggled?: boolean | null;
4
+ userId?: string | null;
5
+ }
6
+ interface PerInstanceCookieData {
7
+ defaultView?: ModalViewTypes | null;
8
+ inkeepChatSessionId?: string | null;
9
+ }
10
+ type CookieData = GlobalCookieData & PerInstanceCookieData;
11
+ type CookieKey = keyof CookieData;
12
+ export declare const useBrowserStorage: () => {
13
+ browserStorage: CookieData;
14
+ setBrowserStorage: <K extends CookieKey>(name: K, value: CookieData[K] | undefined, days?: number) => void;
15
+ };
16
+ export declare const passesBrowserStorageChecks: () => boolean;
17
+ export {};
@@ -0,0 +1,88 @@
1
+ "use client";
2
+ import { useState as C, useEffect as b } from "react";
3
+ import { useInkeepConfig as _ } from "../providers/config-provider.js";
4
+ const a = "inkeepUsagePreferences", w = {
5
+ hasSwitchModeButtonJiggled: !1,
6
+ userId: null
7
+ }, k = {
8
+ defaultView: null,
9
+ inkeepChatSessionId: null
10
+ }, f = {
11
+ ...w,
12
+ ...k
13
+ }, d = {
14
+ set(e, o, t, r = 365) {
15
+ try {
16
+ if (e === "cookie") {
17
+ const s = /* @__PURE__ */ new Date();
18
+ t === void 0 ? (s.setTime(s.getTime() - 1), document.cookie = `${a}_${o}=; expires=${s.toUTCString()}; path=/`) : (s.setTime(s.getTime() + r * 24 * 60 * 60 * 1e3), document.cookie = `${a}_${o}=${t}; expires=${s.toUTCString()}; path=/`);
19
+ } else typeof sessionStorage < "u" && sessionStorage.setItem(`${a}_${o}`, t ? JSON.stringify(t) : "");
20
+ } catch {
21
+ return null;
22
+ }
23
+ },
24
+ get(e, o) {
25
+ if (e === "cookie") {
26
+ const t = `${a}_${o}=`, r = document.cookie.split(";");
27
+ for (const s of r) {
28
+ const i = s.trim();
29
+ if (i.startsWith(t))
30
+ return i.substring(t.length);
31
+ }
32
+ return null;
33
+ }
34
+ try {
35
+ if (typeof sessionStorage < "u") {
36
+ const t = sessionStorage.getItem(`${a}_${o}`);
37
+ return t ? JSON.parse(t) : null;
38
+ }
39
+ } catch {
40
+ return null;
41
+ }
42
+ return null;
43
+ }
44
+ }, U = () => {
45
+ const { baseSettings: e, interactionType: o } = _(), { optOutAllAnalytics: t, optOutFunctionalCookies: r } = e.analytics, i = !t && !r && B() ? "cookie" : "sessionStorage", S = `${e.apiKey}-${o}`, l = (n) => n in k ? `${n}-${S}` : n, p = Object.keys(f).reduce(
46
+ (n, c) => {
47
+ const u = l(c), g = d.get(i, u);
48
+ return { ...n, [c]: g };
49
+ },
50
+ { ...f }
51
+ ), [m, y] = C(p), $ = (n, c, u = 365) => {
52
+ const g = l(n);
53
+ d.set(i, g, c, u), y((h) => ({
54
+ ...h,
55
+ [n]: c
56
+ }));
57
+ };
58
+ return b(() => {
59
+ if (r)
60
+ for (const n of Object.keys(f)) {
61
+ const c = l(n);
62
+ d.set("cookie", c, null, -1);
63
+ }
64
+ }, [r]), {
65
+ browserStorage: m,
66
+ setBrowserStorage: $
67
+ };
68
+ }, I = () => {
69
+ try {
70
+ if (typeof localStorage > "u") return !1;
71
+ const e = "__df709c5b-6651-43dc-94e7-d8dc899bf4e8__";
72
+ return localStorage.setItem(e, "test_value"), localStorage.removeItem(e), !0;
73
+ } catch {
74
+ return !1;
75
+ }
76
+ }, T = () => {
77
+ if (typeof document > "u") return !1;
78
+ document.cookie = "testcookie=true; Path=/; Max-Age=1000";
79
+ const e = document.cookie.includes("testcookie=true");
80
+ return document.cookie = "testcookie=; Path=/; Max-Age=-1000", e;
81
+ }, B = () => {
82
+ const e = I(), o = T();
83
+ return e && o;
84
+ };
85
+ export {
86
+ B as passesBrowserStorageChecks,
87
+ U as useBrowserStorage
88
+ };
@@ -0,0 +1 @@
1
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("../providers/config-provider.cjs"),a=require("../providers/markdown-provider.cjs"),c=require("../utils/misc.cjs");function m(e,n){const{prefix:s}=i.useInkeepConfig(),o=a.useChatMarkdown(),t=u(e,o)?o?.componentStyles?.[e]:void 0,r=`${s}-${c.toKebabCase(e)}`;return[n,t,r].filter(Boolean).join(" ")}function u(e,n){return!!n?.componentStyles&&e in n.componentStyles}exports.useComponentClassNames=m;
@@ -0,0 +1,6 @@
1
+ import { ComponentID } from '../utils/component-ids';
2
+ /**
3
+ * Hook to compute class names for a component based on its ID, user-provided classes,
4
+ * global configuration, and prefixing rules.
5
+ */
6
+ export declare function useComponentClassNames(id: ComponentID, userClassName?: string): string;
@@ -0,0 +1,6 @@
1
+ import { ComponentID } from '../utils/component-ids';
2
+ /**
3
+ * Hook to compute class names for a component based on its ID, user-provided classes,
4
+ * global configuration, and prefixing rules.
5
+ */
6
+ export declare function useComponentClassNames(id: ComponentID, userClassName?: string): string;
@@ -0,0 +1,14 @@
1
+ "use client";
2
+ import { useInkeepConfig as m } from "../providers/config-provider.js";
3
+ import { useChatMarkdown as a } from "../providers/markdown-provider.js";
4
+ import { toKebabCase as i } from "../utils/misc.js";
5
+ function u(o, n) {
6
+ const { prefix: t } = m(), e = a(), s = p(o, e) ? e?.componentStyles?.[o] : void 0, r = `${t}-${i(o)}`;
7
+ return [n, s, r].filter(Boolean).join(" ");
8
+ }
9
+ function p(o, n) {
10
+ return !!n?.componentStyles && o in n.componentStyles;
11
+ }
12
+ export {
13
+ u as useComponentClassNames
14
+ };
@@ -0,0 +1 @@
1
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react");function o(){const e=t.useRef(null),[r,s]=t.useState({width:0,height:0});return t.useEffect(()=>{if(!e.current)return;const n=new ResizeObserver(([i])=>{const{width:c,height:u}=i.contentRect;s({width:c,height:u})});return n.observe(e.current),()=>{n.disconnect()}},[e]),[e,r]}exports.useContainerSize=o;
@@ -0,0 +1,5 @@
1
+ export interface ContainerSize {
2
+ width: number;
3
+ height: number;
4
+ }
5
+ export declare function useContainerSize(): [React.RefObject<HTMLDivElement | null>, ContainerSize];
@@ -0,0 +1,5 @@
1
+ export interface ContainerSize {
2
+ width: number;
3
+ height: number;
4
+ }
5
+ export declare function useContainerSize(): [React.RefObject<HTMLDivElement | null>, ContainerSize];
@@ -0,0 +1,18 @@
1
+ "use client";
2
+ import { useRef as o, useState as u, useEffect as f } from "react";
3
+ function z() {
4
+ const e = o(null), [n, r] = u({ width: 0, height: 0 });
5
+ return f(() => {
6
+ if (!e.current) return;
7
+ const t = new ResizeObserver(([s]) => {
8
+ const { width: i, height: c } = s.contentRect;
9
+ r({ width: i, height: c });
10
+ });
11
+ return t.observe(e.current), () => {
12
+ t.disconnect();
13
+ };
14
+ }, [e]), [e, n];
15
+ }
16
+ export {
17
+ z as useContainerSize
18
+ };
@@ -0,0 +1 @@
1
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react");function i(){const[o,e]=t.useState(!1),r=t.useCallback(async a=>{if(!navigator?.clipboard)return console.warn("Clipboard not supported"),!1;try{return await navigator.clipboard.writeText(a),e(!0),setTimeout(()=>{e(!1)},1e3),!0}catch(s){return console.warn("Copy failed",s),e(!1),!1}},[]);return[o,r]}exports.useCopyToClipboard=i;
@@ -0,0 +1,3 @@
1
+ type CopyFn = (text: string) => void;
2
+ export declare function useCopyToClipboard(): [boolean, CopyFn];
3
+ export {};
@@ -0,0 +1,3 @@
1
+ type CopyFn = (text: string) => void;
2
+ export declare function useCopyToClipboard(): [boolean, CopyFn];
3
+ export {};
@@ -0,0 +1,19 @@
1
+ "use client";
2
+ import { useState as n, useCallback as s } from "react";
3
+ function l() {
4
+ const [r, e] = n(!1), o = s(async (t) => {
5
+ if (!navigator?.clipboard)
6
+ return console.warn("Clipboard not supported"), !1;
7
+ try {
8
+ return await navigator.clipboard.writeText(t), e(!0), setTimeout(() => {
9
+ e(!1);
10
+ }, 1e3), !0;
11
+ } catch (a) {
12
+ return console.warn("Copy failed", a), e(!1), !1;
13
+ }
14
+ }, []);
15
+ return [r, o];
16
+ }
17
+ export {
18
+ l as useCopyToClipboard
19
+ };
@@ -0,0 +1 @@
1
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react");function u(){const[e,s]=t.useState(!1);t.useEffect(()=>{if(e){const n=setTimeout(()=>s(!1),0);return()=>clearTimeout(n)}},[e]);const a=t.useCallback(()=>s(!0),[]);return{disabled:e,disableTransition:a}}exports.useInstantUpdate=u;
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Hook for temporarily disabling transitions/animations.
3
+ * Useful when you need to prevent unwanted transition effects during state changes.
4
+ *
5
+ * @example
6
+ * const { disabled, disableTransition } = useInstantUpdate();
7
+ *
8
+ * // Disable transitions before a state change
9
+ * const handleClick = () => {
10
+ * disableTransition();
11
+ * // State change here...
12
+ * };
13
+ */
14
+ export declare function useInstantUpdate(): {
15
+ disabled: boolean;
16
+ disableTransition: () => void;
17
+ };
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Hook for temporarily disabling transitions/animations.
3
+ * Useful when you need to prevent unwanted transition effects during state changes.
4
+ *
5
+ * @example
6
+ * const { disabled, disableTransition } = useInstantUpdate();
7
+ *
8
+ * // Disable transitions before a state change
9
+ * const handleClick = () => {
10
+ * disableTransition();
11
+ * // State change here...
12
+ * };
13
+ */
14
+ export declare function useInstantUpdate(): {
15
+ disabled: boolean;
16
+ disableTransition: () => void;
17
+ };
@@ -0,0 +1,16 @@
1
+ "use client";
2
+ import { useState as i, useEffect as n, useCallback as r } from "react";
3
+ function o() {
4
+ const [e, t] = i(!1);
5
+ n(() => {
6
+ if (e) {
7
+ const a = setTimeout(() => t(!1), 0);
8
+ return () => clearTimeout(a);
9
+ }
10
+ }, [e]);
11
+ const s = r(() => t(!0), []);
12
+ return { disabled: e, disableTransition: s };
13
+ }
14
+ export {
15
+ o as useInstantUpdate
16
+ };
@@ -0,0 +1 @@
1
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react");function u(){const e=t.useRef(!1);return t.useEffect(()=>(e.current=!0,()=>{e.current=!1}),[]),t.useCallback(()=>e.current,[])}exports.useIsMounted=u;