@donotdev/components 0.0.33 → 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (286) hide show
  1. package/LICENSE.md +21 -48
  2. package/README.md +12 -0
  3. package/dist/CodeContent-4RJHYJO7.js +2 -0
  4. package/dist/{CrawlContent-5CUKBDIN.js → CrawlContent-6LR66N57.js} +1 -1
  5. package/dist/advanced/Bento/Bento.js +1 -1
  6. package/dist/advanced/Carousel/Carousel.js +1 -1
  7. package/dist/advanced/Carousel/CarouselContent.d.ts +1 -1
  8. package/dist/advanced/Carousel/CarouselContent.js +1 -1
  9. package/dist/advanced/Carousel/CarouselSkeleton.js +1 -1
  10. package/dist/advanced/Code/Code.js +1 -1
  11. package/dist/advanced/Code/CodeContent.d.ts.map +1 -1
  12. package/dist/advanced/Code/CodeContent.js +9 -7
  13. package/dist/advanced/Code/CodeSkeleton.js +1 -1
  14. package/dist/advanced/Crawl/Crawl.d.ts +2 -2
  15. package/dist/advanced/Crawl/Crawl.js +2 -2
  16. package/dist/advanced/Crawl/CrawlContent.d.ts +1 -1
  17. package/dist/advanced/Crawl/CrawlContent.js +1 -1
  18. package/dist/advanced/Crawl/utils/parseHtml.d.ts +5 -5
  19. package/dist/advanced/Crawl/utils/parseHtml.d.ts.map +1 -1
  20. package/dist/advanced/Crawl/utils/parseHtml.js +15 -9
  21. package/dist/advanced/ImageGallery/ImageGallery.js +1 -1
  22. package/dist/advanced/JsonViewer/JsonViewer.js +1 -1
  23. package/dist/advanced/Marquee/Marquee.js +1 -1
  24. package/dist/advanced/Marquee/MarqueeContent.js +1 -1
  25. package/dist/advanced/Marquee/MarqueeSkeleton.js +1 -1
  26. package/dist/advanced/Reveal/Reveal.d.ts +1 -1
  27. package/dist/advanced/Reveal/Reveal.js +1 -1
  28. package/dist/advanced/Roadmap/Roadmap.d.ts +1 -1
  29. package/dist/advanced/Roadmap/Roadmap.js +1 -1
  30. package/dist/advanced/Roadmap/RoadmapContent.js +1 -1
  31. package/dist/advanced/SplitReveal/SplitReveal.d.ts +3 -3
  32. package/dist/advanced/SplitReveal/SplitReveal.js +2 -2
  33. package/dist/advanced/StackedCards/StackedCards.d.ts +1 -1
  34. package/dist/advanced/StackedCards/StackedCards.js +1 -1
  35. package/dist/advanced/StackedCards/StackedCardsContent.js +1 -1
  36. package/dist/advanced/index.d.ts +1 -1
  37. package/dist/advanced/index.js +1 -1
  38. package/dist/atomic/Accordion/AccordionPrimitive.d.ts +1 -1
  39. package/dist/atomic/Accordion/AccordionPrimitive.js +1 -1
  40. package/dist/atomic/Accordion/index.js +1 -1
  41. package/dist/atomic/ActionButton/index.js +1 -1
  42. package/dist/atomic/ActionButton/useAction.js +1 -1
  43. package/dist/atomic/Alert/index.d.ts +1 -1
  44. package/dist/atomic/Alert/index.js +1 -1
  45. package/dist/atomic/AlertDialog/AlertDialogPrimitive.d.ts +1 -1
  46. package/dist/atomic/AlertDialog/AlertDialogPrimitive.js +1 -1
  47. package/dist/atomic/AlertDialog/index.js +1 -1
  48. package/dist/atomic/Avatar/AvatarPrimitive.d.ts +1 -1
  49. package/dist/atomic/Avatar/AvatarPrimitive.js +1 -1
  50. package/dist/atomic/Avatar/index.d.ts +1 -1
  51. package/dist/atomic/Avatar/index.js +1 -1
  52. package/dist/atomic/Badge/index.d.ts +1 -1
  53. package/dist/atomic/Badge/index.js +1 -1
  54. package/dist/atomic/Blockquote/index.d.ts +1 -1
  55. package/dist/atomic/Blockquote/index.js +2 -2
  56. package/dist/atomic/Button/index.d.ts +2 -2
  57. package/dist/atomic/Button/index.js +1 -1
  58. package/dist/atomic/ButtonGroup/index.js +1 -1
  59. package/dist/atomic/Calendar/CalendarPrimitive.d.ts +1 -1
  60. package/dist/atomic/Calendar/CalendarPrimitive.js +1 -1
  61. package/dist/atomic/CallToAction/index.d.ts +1 -1
  62. package/dist/atomic/CallToAction/index.js +1 -1
  63. package/dist/atomic/Card/index.d.ts +1 -1
  64. package/dist/atomic/Card/index.js +1 -1
  65. package/dist/atomic/Checkbox/CheckboxPrimitive.d.ts +1 -1
  66. package/dist/atomic/Checkbox/CheckboxPrimitive.js +1 -1
  67. package/dist/atomic/Checkbox/index.js +1 -1
  68. package/dist/atomic/Collapsible/CollapsiblePrimitive.d.ts +1 -1
  69. package/dist/atomic/Collapsible/CollapsiblePrimitive.js +1 -1
  70. package/dist/atomic/Collapsible/index.js +1 -1
  71. package/dist/atomic/ColorPicker/index.js +1 -1
  72. package/dist/atomic/Command/index.js +1 -1
  73. package/dist/atomic/CommandDialog/index.js +1 -1
  74. package/dist/atomic/ContextMenu/ContextMenuPrimitive.d.ts +1 -1
  75. package/dist/atomic/ContextMenu/ContextMenuPrimitive.js +1 -1
  76. package/dist/atomic/ContextMenu/index.js +1 -1
  77. package/dist/atomic/CopyToClipboard/index.d.ts +1 -1
  78. package/dist/atomic/CopyToClipboard/index.js +3 -3
  79. package/dist/atomic/DescriptionList/index.js +1 -1
  80. package/dist/atomic/Dialog/index.js +1 -1
  81. package/dist/atomic/DropdownMenu/DropdownMenuPrimitive.d.ts +1 -1
  82. package/dist/atomic/DropdownMenu/DropdownMenuPrimitive.js +1 -1
  83. package/dist/atomic/DropdownMenu/index.js +1 -1
  84. package/dist/atomic/DualCard/index.d.ts +1 -1
  85. package/dist/atomic/DualCard/index.js +1 -1
  86. package/dist/atomic/FeatureFallback/index.js +1 -1
  87. package/dist/atomic/FileButton/index.d.ts +3 -3
  88. package/dist/atomic/FileButton/index.js +3 -3
  89. package/dist/atomic/Grid/GridArea.d.ts +1 -1
  90. package/dist/atomic/Grid/GridArea.js +1 -1
  91. package/dist/atomic/Grid/index.d.ts +1 -1
  92. package/dist/atomic/Grid/index.js +1 -1
  93. package/dist/atomic/HeroSection/index.d.ts +1 -1
  94. package/dist/atomic/HeroSection/index.js +1 -1
  95. package/dist/atomic/HoverCard/HoverCardPrimitive.d.ts +1 -1
  96. package/dist/atomic/HoverCard/HoverCardPrimitive.js +1 -1
  97. package/dist/atomic/HoverCard/index.js +1 -1
  98. package/dist/atomic/Icons/Icon.js +1 -1
  99. package/dist/atomic/Icons/IconBox.d.ts +3 -3
  100. package/dist/atomic/Icons/IconBox.js +3 -3
  101. package/dist/atomic/Icons/Partner/AppleIcon.d.ts +3 -3
  102. package/dist/atomic/Icons/Partner/AppleIcon.js +3 -3
  103. package/dist/atomic/Icons/Partner/DiscordIcon.d.ts +1 -1
  104. package/dist/atomic/Icons/Partner/DiscordIcon.js +1 -1
  105. package/dist/atomic/Icons/Partner/FacebookIcon.d.ts +1 -1
  106. package/dist/atomic/Icons/Partner/FacebookIcon.js +1 -1
  107. package/dist/atomic/Icons/Partner/GitHubIcon.d.ts +1 -1
  108. package/dist/atomic/Icons/Partner/GitHubIcon.js +1 -1
  109. package/dist/atomic/Icons/Partner/GoogleIcon.d.ts +1 -1
  110. package/dist/atomic/Icons/Partner/GoogleIcon.js +1 -1
  111. package/dist/atomic/Icons/Partner/LinkedinIcon.d.ts +1 -1
  112. package/dist/atomic/Icons/Partner/LinkedinIcon.js +1 -1
  113. package/dist/atomic/Icons/Partner/MastodonIcon.d.ts +1 -1
  114. package/dist/atomic/Icons/Partner/MastodonIcon.js +1 -1
  115. package/dist/atomic/Icons/Partner/MediumIcon.d.ts +1 -1
  116. package/dist/atomic/Icons/Partner/MediumIcon.js +1 -1
  117. package/dist/atomic/Icons/Partner/MicrosoftIcon.d.ts +1 -1
  118. package/dist/atomic/Icons/Partner/MicrosoftIcon.js +1 -1
  119. package/dist/atomic/Icons/Partner/NotionIcon.d.ts +1 -1
  120. package/dist/atomic/Icons/Partner/NotionIcon.js +1 -1
  121. package/dist/atomic/Icons/Partner/RedditIcon.d.ts +1 -1
  122. package/dist/atomic/Icons/Partner/RedditIcon.js +1 -1
  123. package/dist/atomic/Icons/Partner/SlackIcon.d.ts +1 -1
  124. package/dist/atomic/Icons/Partner/SlackIcon.js +1 -1
  125. package/dist/atomic/Icons/Partner/SpotifyIcon.d.ts +1 -1
  126. package/dist/atomic/Icons/Partner/SpotifyIcon.js +1 -1
  127. package/dist/atomic/Icons/Partner/TwitchIcon.d.ts +1 -1
  128. package/dist/atomic/Icons/Partner/TwitchIcon.js +1 -1
  129. package/dist/atomic/Icons/Partner/XIcon.d.ts +1 -1
  130. package/dist/atomic/Icons/Partner/XIcon.js +1 -1
  131. package/dist/atomic/Icons/Partner/YahooIcon.d.ts +1 -1
  132. package/dist/atomic/Icons/Partner/YahooIcon.js +1 -1
  133. package/dist/atomic/Icons/Partner/YouTubeIcon.d.ts +1 -1
  134. package/dist/atomic/Icons/Partner/YouTubeIcon.js +1 -1
  135. package/dist/atomic/Icons/Partner/providerIcons.d.ts +3 -3
  136. package/dist/atomic/Icons/Partner/providerIcons.js +4 -4
  137. package/dist/atomic/InfiniteScroll/index.d.ts +1 -1
  138. package/dist/atomic/InfiniteScroll/index.js +1 -1
  139. package/dist/atomic/Input/index.js +1 -1
  140. package/dist/atomic/Label/FloatingLabel.d.ts +1 -1
  141. package/dist/atomic/Label/FloatingLabel.js +1 -1
  142. package/dist/atomic/Label/LabelPrimitive.d.ts +2 -2
  143. package/dist/atomic/Label/LabelPrimitive.js +1 -1
  144. package/dist/atomic/Label/index.d.ts +1 -1
  145. package/dist/atomic/Label/index.js +1 -1
  146. package/dist/atomic/List/index.d.ts +1 -1
  147. package/dist/atomic/List/index.js +1 -1
  148. package/dist/atomic/NavigationMenu/NavigationMenuPrimitive.d.ts +1 -1
  149. package/dist/atomic/NavigationMenu/NavigationMenuPrimitive.js +1 -1
  150. package/dist/atomic/NavigationMenu/index.d.ts +1 -1
  151. package/dist/atomic/NavigationMenu/index.js +1 -1
  152. package/dist/atomic/PasswordInput/index.d.ts +1 -1
  153. package/dist/atomic/PasswordInput/index.js +2 -2
  154. package/dist/atomic/Popover/PopoverPrimitive.d.ts +1 -1
  155. package/dist/atomic/Popover/PopoverPrimitive.js +1 -1
  156. package/dist/atomic/Popover/index.js +1 -1
  157. package/dist/atomic/Portal/PortalPrimitive.d.ts +1 -1
  158. package/dist/atomic/Portal/PortalPrimitive.js +1 -1
  159. package/dist/atomic/Portal/index.d.ts +1 -1
  160. package/dist/atomic/Portal/index.js +1 -1
  161. package/dist/atomic/PortalButton/index.d.ts +1 -1
  162. package/dist/atomic/PortalButton/index.js +1 -1
  163. package/dist/atomic/Progress/ProgressPrimitive.d.ts +1 -1
  164. package/dist/atomic/Progress/ProgressPrimitive.js +1 -1
  165. package/dist/atomic/Progress/index.d.ts +1 -1
  166. package/dist/atomic/Progress/index.js +1 -1
  167. package/dist/atomic/RadioGroup/RadioGroupPrimitive.d.ts +2 -2
  168. package/dist/atomic/RadioGroup/RadioGroupPrimitive.js +1 -1
  169. package/dist/atomic/RadioGroup/index.js +1 -1
  170. package/dist/atomic/RangeInput/index.js +1 -1
  171. package/dist/atomic/Rating/index.d.ts +1 -1
  172. package/dist/atomic/Rating/index.js +1 -1
  173. package/dist/atomic/ScrollArea/ScrollAreaPrimitive.d.ts +1 -1
  174. package/dist/atomic/ScrollArea/ScrollAreaPrimitive.js +1 -1
  175. package/dist/atomic/ScrollArea/index.d.ts +1 -1
  176. package/dist/atomic/ScrollArea/index.js +1 -1
  177. package/dist/atomic/Section/index.d.ts +15 -0
  178. package/dist/atomic/Section/index.d.ts.map +1 -1
  179. package/dist/atomic/Section/index.js +12 -3
  180. package/dist/atomic/Select/SelectPrimitive.d.ts +1 -1
  181. package/dist/atomic/Select/SelectPrimitive.js +1 -1
  182. package/dist/atomic/Select/index.js +1 -1
  183. package/dist/atomic/Separator/SeparatorPrimitive.d.ts +1 -1
  184. package/dist/atomic/Separator/SeparatorPrimitive.js +1 -1
  185. package/dist/atomic/Separator/index.d.ts +2 -2
  186. package/dist/atomic/Separator/index.js +2 -2
  187. package/dist/atomic/Sheet/SheetPrimitive.d.ts +1 -1
  188. package/dist/atomic/Sheet/SheetPrimitive.js +1 -1
  189. package/dist/atomic/Sheet/index.d.ts +1 -1
  190. package/dist/atomic/Sheet/index.js +1 -1
  191. package/dist/atomic/Skeleton/index.d.ts +1 -1
  192. package/dist/atomic/Skeleton/index.js +2 -2
  193. package/dist/atomic/SkipLink/index.js +1 -1
  194. package/dist/atomic/Slider/SliderPrimitive.d.ts +1 -1
  195. package/dist/atomic/Slider/SliderPrimitive.js +1 -1
  196. package/dist/atomic/Slider/index.d.ts +1 -1
  197. package/dist/atomic/Slider/index.js +1 -1
  198. package/dist/atomic/Slot/SlotPrimitive.d.ts +1 -1
  199. package/dist/atomic/Slot/SlotPrimitive.js +1 -1
  200. package/dist/atomic/Slot/index.d.ts +1 -1
  201. package/dist/atomic/Slot/index.js +1 -1
  202. package/dist/atomic/Spinner/index.d.ts +2 -2
  203. package/dist/atomic/Spinner/index.js +2 -2
  204. package/dist/atomic/Stack/index.d.ts +1 -1
  205. package/dist/atomic/Stack/index.js +1 -1
  206. package/dist/atomic/Stepper/index.d.ts +1 -1
  207. package/dist/atomic/Stepper/index.js +1 -1
  208. package/dist/atomic/Switch/SwitchPrimitive.d.ts +1 -1
  209. package/dist/atomic/Switch/SwitchPrimitive.js +1 -1
  210. package/dist/atomic/Switch/index.d.ts +1 -1
  211. package/dist/atomic/Switch/index.js +1 -1
  212. package/dist/atomic/Table/index.d.ts +2 -2
  213. package/dist/atomic/Table/index.js +1 -1
  214. package/dist/atomic/Tabs/TabsPrimitive.d.ts +1 -1
  215. package/dist/atomic/Tabs/TabsPrimitive.js +1 -1
  216. package/dist/atomic/Tabs/index.d.ts +1 -1
  217. package/dist/atomic/Tabs/index.js +1 -1
  218. package/dist/atomic/Tag/index.d.ts +1 -1
  219. package/dist/atomic/Tag/index.js +1 -1
  220. package/dist/atomic/Text/index.d.ts +1 -1
  221. package/dist/atomic/Text/index.js +1 -1
  222. package/dist/atomic/Textarea/index.js +1 -1
  223. package/dist/atomic/Toaster/Toast.types.d.ts +2 -2
  224. package/dist/atomic/Toaster/ToastPrimitive.d.ts +1 -1
  225. package/dist/atomic/Toaster/ToastPrimitive.js +1 -1
  226. package/dist/atomic/Toaster/index.d.ts +1 -1
  227. package/dist/atomic/Toaster/index.js +1 -1
  228. package/dist/atomic/Toggle/TogglePrimitive.d.ts +1 -1
  229. package/dist/atomic/Toggle/TogglePrimitive.js +1 -1
  230. package/dist/atomic/Toggle/index.d.ts +1 -1
  231. package/dist/atomic/Toggle/index.js +1 -1
  232. package/dist/atomic/ToggleGroup/ToggleGroupPrimitive.d.ts +1 -1
  233. package/dist/atomic/ToggleGroup/ToggleGroupPrimitive.js +1 -1
  234. package/dist/atomic/ToggleGroup/index.d.ts +1 -1
  235. package/dist/atomic/ToggleGroup/index.js +1 -1
  236. package/dist/atomic/Tooltip/TooltipPrimitive.d.ts +1 -1
  237. package/dist/atomic/Tooltip/TooltipPrimitive.js +1 -1
  238. package/dist/atomic/Tooltip/index.js +1 -1
  239. package/dist/atomic/TreeView/index.js +1 -1
  240. package/dist/atomic/VideoPlayer/index.d.ts +2 -2
  241. package/dist/atomic/VideoPlayer/index.js +4 -4
  242. package/dist/atomic/VisuallyHidden/index.d.ts +1 -1
  243. package/dist/atomic/VisuallyHidden/index.js +1 -1
  244. package/dist/atomic/index.d.ts +1 -1
  245. package/dist/atomic/index.js +1 -1
  246. package/dist/chunk-2CNNVCFI.js +1 -0
  247. package/dist/{chunk-APZZAGK2.js → chunk-FM52VMY6.js} +2 -2
  248. package/dist/hooks/index.d.ts +1 -1
  249. package/dist/hooks/index.js +1 -1
  250. package/dist/hooks/useClickOutside.js +1 -1
  251. package/dist/hooks/useIntersectionObserver.d.ts +3 -3
  252. package/dist/hooks/useIntersectionObserver.js +2 -2
  253. package/dist/hooks/useSwipeToClose.js +1 -1
  254. package/dist/hooks/useToast.d.ts +8 -8
  255. package/dist/hooks/useToast.js +6 -6
  256. package/dist/hooks/useViewportVisibility.d.ts +3 -3
  257. package/dist/hooks/useViewportVisibility.js +2 -2
  258. package/dist/index.d.ts +1 -1
  259. package/dist/index.js +3 -3
  260. package/dist/styles/componentConstants.d.ts +8 -8
  261. package/dist/styles/componentConstants.js +8 -8
  262. package/dist/styles/index.css +224 -0
  263. package/dist/styles/index.d.ts +1 -1
  264. package/dist/styles/index.js +1 -1
  265. package/dist/types.d.ts +3 -3
  266. package/dist/utils/eventListener.d.ts +3 -3
  267. package/dist/utils/eventListener.js +3 -3
  268. package/dist/utils/helpers.d.ts +2 -2
  269. package/dist/utils/helpers.js +3 -3
  270. package/dist/utils/index.d.ts +1 -1
  271. package/dist/utils/index.js +1 -1
  272. package/dist/utils/intersectionObserver.d.ts +7 -7
  273. package/dist/utils/intersectionObserver.js +6 -6
  274. package/dist/utils/isDark.d.ts +2 -2
  275. package/dist/utils/isDark.js +3 -3
  276. package/dist/utils/measurement.d.ts +8 -8
  277. package/dist/utils/measurement.js +6 -6
  278. package/dist/utils/rtl.d.ts +1 -1
  279. package/dist/utils/rtl.js +2 -2
  280. package/dist/utils/viewportDetection.d.ts +6 -6
  281. package/dist/utils/viewportDetection.js +3 -3
  282. package/package.json +2 -2
  283. package/dist/CodeContent-CAM2LFZ7.js +0 -2
  284. package/dist/CodeContent-OPBVWY43.js +0 -2
  285. package/dist/chunk-E54ZWOWD.js +0 -1
  286. package/dist/chunk-NCBN5O34.js +0 -3
package/LICENSE.md CHANGED
@@ -1,48 +1,21 @@
1
- # DoNotDev Free License
2
-
3
- Copyright (c) 2025 Ambroise Park Consulting. All rights reserved.
4
-
5
- **Permissive Use License - No Commercial Restrictions**
6
-
7
- ---
8
-
9
- ## LICENSE GRANT
10
-
11
- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), specifically the @donotdev/components package, to download, install, and use the Software in your applications for any purpose, including commercial use, subject to the following restrictions:
12
-
13
- ## WHAT YOU CAN DO
14
-
15
- ✅ Download and install @donotdev/components
16
- ✅ Use @donotdev/components in your applications (commercial or non-commercial)
17
- ✅ Integrate @donotdev/components into your projects
18
-
19
- ## WHAT YOU CANNOT DO
20
-
21
- ❌ Fork, copy, or redistribute @donotdev/components as a standalone package
22
- ❌ Resell or sublicense @donotdev/components
23
- ❌ Remove or alter copyright notices
24
- ❌ Claim ownership of @donotdev/components
25
- ❌ Create derivative works that compete with or replace @donotdev/components
26
-
27
- ## WARRANTY DISCLAIMER
28
-
29
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
30
-
31
- ## LIMITATION OF LIABILITY
32
-
33
- IN NO EVENT SHALL AMBROISE PARK CONSULTING BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
34
-
35
- ## NO SUPPORT OBLIGATION
36
-
37
- The licensor has no obligation to provide support, updates, or maintenance for @donotdev/components. Any support provided is at the sole discretion of the licensor and may be discontinued at any time without notice.
38
-
39
- ## CONTACT
40
-
41
- For questions about this license:
42
- **mooti.web.app@gmail.com**
43
-
44
- ---
45
-
46
- **DoNotDev Free License v1.0**
47
- Ambroise Park Consulting - 2025
48
-
1
+ MIT License
2
+
3
+ Copyright (c) 2025 Ambroise Park Consulting
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -76,6 +76,18 @@ import { Dialog } from '@donotdev/components';
76
76
  </Dialog>;
77
77
  ```
78
78
 
79
+ ## Compatibility Notice
80
+
81
+ `@donotdev/components` is the foundational UI layer of the DoNotDev Framework. The following commercial packages depend on the component prop contracts defined here:
82
+
83
+ - `@donotdev/ui` - Layout and navigation components
84
+ - `@donotdev/features/*` - Auth, billing, CRUD, OAuth features
85
+ - `@donotdev/expo` - React Native bridge
86
+
87
+ **If you fork this package**, you are free to customize styling, add variants, and extend components. However, **do not remove or rename existing props, change type signatures, or alter component export names** - doing so will break the commercial packages that depend on them.
88
+
89
+ Modifications that break component contracts are not covered by DoNotDev support. When in doubt, extend rather than modify.
90
+
79
91
  ## Key Features
80
92
 
81
93
  - **Radix UI Primitives**: Accessible, headless components in `./src/base/`
@@ -0,0 +1,2 @@
1
+ import{r as l,w as S,x as w,z as T}from"./chunk-FM52VMY6.js";import{k as d}from"./chunk-EOCKFSHC.js";import"./chunk-O2XFH626.js";import{useEffect as H,useState as m,useMemo as x}from"react";import{jsx as e,jsxs as i}from"react/jsx-runtime";function O({children:a,language:p="tsx",className:P,showLineNumbers:E=!0,wrapLines:f=!1,showCopyButton:L=!0,onCopy:_,compact:h=!1}){let[r,D]=m(!1),[c,A]=m(null),[v,N]=m(!0),[k,F]=m(!1),y=T(),s=x(()=>a.trim().split(`
2
+ `),[a]);H(()=>{if(!r)return;let t=!0;return(async()=>{try{let[{createHighlighterCore:n},{createJavaScriptRegexEngine:b},...C]=await Promise.all([import("shiki/core"),import("shiki/engine/javascript"),import("shiki/themes/github-dark.mjs"),import("shiki/themes/github-light.mjs"),import("shiki/langs/typescript.mjs"),import("shiki/langs/tsx.mjs"),import("shiki/langs/javascript.mjs"),import("shiki/langs/jsx.mjs"),import("shiki/langs/json.mjs"),import("shiki/langs/css.mjs"),import("shiki/langs/html.mjs"),import("shiki/langs/bash.mjs"),import("shiki/langs/sql.mjs"),import("shiki/langs/yaml.mjs"),import("shiki/langs/markdown.mjs")]),I=C.slice(0,2).map(u=>u.default),M=C.slice(2).map(u=>u.default),V=await n({themes:I,langs:M,engine:b()});t&&(A(V),N(!1))}catch(n){n instanceof Error&&(n.message.includes("Cannot find module 'shiki'")||n.message.includes("Failed to fetch dynamically imported module")),t&&(F(!0),N(!1))}})(),()=>{t=!1}},[r]);let g=x(()=>{if(!r||!a||k||!c||v)return null;try{let t=y?"github-dark":"github-light",o=p||"text";return c.getLoadedLanguages().includes(o)?c.codeToHtml(a,{lang:o,theme:t}).replace(/^<pre[^>]*><code[^>]*>/,"").replace(/<\/code><\/pre>$/,"").replace(/\n/g,""):null}catch{return null}},[a,p,r,c,v,y,k]);return H(()=>{D(!0)},[]),i(d,{gap:"none",className:"dndev-code dndev-surface","data-glow":"blank","data-compact":h,children:[!h&&e("div",{className:"dndev-code-header",children:i(d,{direction:"row",align:"center",justify:"between",children:[i(d,{direction:"row",align:"center",gap:"tight",children:[i("div",{className:"dndev-code-traffic-lights",children:[e("div",{className:"dndev-code-traffic-light","data-color":"red"}),e("div",{className:"dndev-code-traffic-light","data-color":"yellow"}),e("div",{className:"dndev-code-traffic-light","data-color":"green"})]}),e(l,{as:"span",className:"dndev-code-language",children:p}),i(l,{as:"span",className:"dndev-code-line-count",children:[s.length," line",s.length!==1?"s":""]})]}),L&&r&&e(w,{text:a,onCopy:_})]})}),e(S,{className:"dndev-code-content",showHorizontal:!f,showVertical:!0,children:e("pre",{className:"dndev-code-pre","data-wrap":f,"data-compact":h,children:E?i(d,{direction:"row",gap:"none",children:[e("div",{className:"dndev-code-line-numbers",children:s.map((t,o)=>e("div",{className:"dndev-code-line-number",children:String(o+1).padStart(2," ")},o))}),g?e("code",{className:"dndev-code-code",dangerouslySetInnerHTML:{__html:g}}):e("code",{className:"dndev-code-code",children:s.map((t,o)=>e(l,{as:"code",variant:"code",style:{display:"block",background:"transparent",padding:0,lineHeight:1.5},children:t||"\xA0"},o))})]}):g?e("code",{className:"dndev-code-code",dangerouslySetInnerHTML:{__html:g}}):e("code",{className:"dndev-code-code",children:s.map((t,o)=>e(l,{as:"code",variant:"code",style:{display:"block",background:"transparent",padding:0},children:t||"\xA0"},o))})})})]})}var j=O;export{j as default};
@@ -1 +1 @@
1
- import{a as o}from"./chunk-E54ZWOWD.js";import"./chunk-O2XFH626.js";import{useEffect as k,useRef as x,useState as P,useMemo as c,isValidElement as R}from"react";import{Fragment as E,jsx as n,jsxs as u}from"react/jsx-runtime";var S=()=>typeof window<"u"&&typeof document<"u",T=({content:t,title:i,duration:m=26,contentHeight:v="150vh",tiltAngle:l,onPause:g,onResume:w})=>{let d=x(null),[s,f]=P(!1),h=r=>!r||typeof r!="string"?null:r.split(/\n\s*\n/).map(a=>a.trim()).filter(a=>a.length>0).map((a,N)=>n("p",{children:o(a,{allowedTags:["u","br","i","em","strong","b"]})},`p-${N}`)),y=c(()=>i?typeof i=="string"?n("h2",{className:"dndev-crawl-title",children:o(i,{allowedTags:["u","br","i","em","strong","b"]})}):i:null,[i]),b=c(()=>R(t)?t:Array.isArray(t)?t.map(e=>typeof e=="string"?e.trim():"").filter(e=>e&&e.length>0).map((e,a)=>n("p",{children:o(e,{allowedTags:["u","br","i","em","strong","b"]})},`c-${a}`)):typeof t=="string"?h(t):t,[t]),C=c(()=>{let r={"--crawl-content-height":v,animationName:"dndev-crawl-animation",animationDuration:`${m}s`,animationTimingFunction:"linear",animationIterationCount:"infinite",animationFillMode:"forwards",animationPlayState:s?"paused":"running"};return l!==void 0&&(r["--crawl-tilt"]=`${l}deg`),r},[s,m,v,l]);k(()=>{if(!S()||!d.current)return;let r=window.matchMedia("(prefers-reduced-motion: reduce)"),e=()=>{r.matches&&d.current&&d.current.classList.add("dndev-crawl-reduced-motion")};return e(),r.addEventListener("change",e),()=>r.removeEventListener("change",e)},[]);let p=()=>{s?(f(!1),w?.()):(f(!0),g?.())};return u(E,{children:[n("div",{className:"dndev-crawl-3d-container",onClick:p,children:n("div",{ref:d,className:"dndev-crawl-text",style:{...C,willChange:s?"auto":"transform"},children:u("div",{className:"dndev-crawl-content",children:[y,b]})})}),s&&n("div",{className:"dndev-absolute dndev-inset-0 dndev-flex dndev-items-center dndev-justify-center",style:{zIndex:30,backgroundColor:"rgba(0, 0, 0, 0.3)",backdropFilter:"blur(2px)"},onClick:p,children:n("button",{style:{width:"96px",height:"96px",borderRadius:"50%",display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:"rgba(255, 255, 255, 0.2)",border:"4px solid rgba(255, 255, 255, 0.4)",backdropFilter:"blur(4px)",cursor:"pointer",transition:"all var(--dur-normal) var(--ease-in-out)"},"aria-label":"Resume animation",children:n("svg",{width:"48",height:"48",viewBox:"0 0 24 24",fill:"white",children:n("path",{d:"M6 4h4v16H6V4zm8 0h4v16h-4V4z"})})})}),u("div",{className:"dndev-crawl-stars",children:[n("div",{className:"dndev-crawl-stars-layer-1"}),n("div",{className:"dndev-crawl-stars-layer-2"}),n("div",{className:"dndev-crawl-stars-layer-3"})]})]})},I=T;export{I as default};
1
+ import{a as o}from"./chunk-2CNNVCFI.js";import"./chunk-O2XFH626.js";import{useEffect as k,useRef as x,useState as P,useMemo as c,isValidElement as R}from"react";import{Fragment as E,jsx as n,jsxs as u}from"react/jsx-runtime";var S=()=>typeof window<"u"&&typeof document<"u",T=({content:t,title:i,duration:m=26,contentHeight:v="150vh",tiltAngle:l,onPause:g,onResume:w})=>{let d=x(null),[s,f]=P(!1),h=r=>!r||typeof r!="string"?null:r.split(/\n\s*\n/).map(a=>a.trim()).filter(a=>a.length>0).map((a,N)=>n("p",{children:o(a,{allowedTags:["u","br","i","em","strong","b"]})},`p-${N}`)),y=c(()=>i?typeof i=="string"?n("h2",{className:"dndev-crawl-title",children:o(i,{allowedTags:["u","br","i","em","strong","b"]})}):i:null,[i]),b=c(()=>R(t)?t:Array.isArray(t)?t.map(e=>typeof e=="string"?e.trim():"").filter(e=>e&&e.length>0).map((e,a)=>n("p",{children:o(e,{allowedTags:["u","br","i","em","strong","b"]})},`c-${a}`)):typeof t=="string"?h(t):t,[t]),C=c(()=>{let r={"--crawl-content-height":v,animationName:"dndev-crawl-animation",animationDuration:`${m}s`,animationTimingFunction:"linear",animationIterationCount:"infinite",animationFillMode:"forwards",animationPlayState:s?"paused":"running"};return l!==void 0&&(r["--crawl-tilt"]=`${l}deg`),r},[s,m,v,l]);k(()=>{if(!S()||!d.current)return;let r=window.matchMedia("(prefers-reduced-motion: reduce)"),e=()=>{r.matches&&d.current&&d.current.classList.add("dndev-crawl-reduced-motion")};return e(),r.addEventListener("change",e),()=>r.removeEventListener("change",e)},[]);let p=()=>{s?(f(!1),w?.()):(f(!0),g?.())};return u(E,{children:[n("div",{className:"dndev-crawl-3d-container",onClick:p,children:n("div",{ref:d,className:"dndev-crawl-text",style:{...C,willChange:s?"auto":"transform"},children:u("div",{className:"dndev-crawl-content",children:[y,b]})})}),s&&n("div",{className:"dndev-absolute dndev-inset-0 dndev-flex dndev-items-center dndev-justify-center",style:{zIndex:30,backgroundColor:"rgba(0, 0, 0, 0.3)",backdropFilter:"blur(2px)"},onClick:p,children:n("button",{style:{width:"96px",height:"96px",borderRadius:"50%",display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:"rgba(255, 255, 255, 0.2)",border:"4px solid rgba(255, 255, 255, 0.4)",backdropFilter:"blur(4px)",cursor:"pointer",transition:"all var(--dur-normal) var(--ease-in-out)"},"aria-label":"Resume animation",children:n("svg",{width:"48",height:"48",viewBox:"0 0 24 24",fill:"white",children:n("path",{d:"M6 4h4v16H6V4zm8 0h4v16h-4V4z"})})})}),u("div",{className:"dndev-crawl-stars",children:[n("div",{className:"dndev-crawl-stars-layer-1"}),n("div",{className:"dndev-crawl-stars-layer-2"}),n("div",{className:"dndev-crawl-stars-layer-3"})]})]})},I=T;export{I as default};
@@ -5,7 +5,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
5
5
  * @description Asymmetric grid layout for modern "bento box" style displays.
6
6
  * Supports variable cell spanning for visual hierarchy.
7
7
  *
8
- * @version 0.0.1
8
+ * @version 0.1.0
9
9
  * @since 0.0.1
10
10
  * @author AMBROISE PARK Consulting
11
11
  */
@@ -4,7 +4,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
4
4
  * @fileoverview Carousel Component
5
5
  * @description Premium carousel component with lazy loading built-in. Features true infinite circular loop, hardware-accelerated animations, swipe/touch gestures, autoplay with pause-on-hover, and lazy loading by default.
6
6
  *
7
- * @version 0.0.1
7
+ * @version 0.1.0
8
8
  * @since 0.0.1
9
9
  * @author AMBROISE PARK Consulting
10
10
  */
@@ -3,7 +3,7 @@ import './Carousel.css';
3
3
  /**
4
4
  * Carousel props interface
5
5
  *
6
- * @version 0.0.1
6
+ * @version 0.1.0
7
7
  * @since 0.0.1
8
8
  * @author AMBROISE PARK Consulting
9
9
  */
@@ -4,7 +4,7 @@ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-run
4
4
  * @fileoverview Carousel Component
5
5
  * @description Premium carousel component with advanced features including autoplay, transitions, and accessibility
6
6
  *
7
- * @version 0.0.1
7
+ * @version 0.1.0
8
8
  * @since 0.0.1
9
9
  * @author AMBROISE PARK Consulting
10
10
  */
@@ -4,7 +4,7 @@ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-run
4
4
  * @fileoverview Carousel Skeleton Component
5
5
  * @description Loading skeleton for Carousel component
6
6
  *
7
- * @version 0.0.1
7
+ * @version 0.1.0
8
8
  * @since 0.0.1
9
9
  * @author AMBROISE PARK Consulting
10
10
  */
@@ -4,7 +4,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
4
4
  * @fileoverview Code Component
5
5
  * @description Code component with lazy loading built-in. Features Shiki syntax highlighting, lazy-loaded language support, line numbers, copy to clipboard, theme-aware styling, and SSR/CSR compatibility.
6
6
  *
7
- * @version 0.0.1
7
+ * @version 0.1.0
8
8
  * @since 0.0.1
9
9
  * @author AMBROISE PARK Consulting
10
10
  */
@@ -1 +1 @@
1
- {"version":3,"file":"CodeContent.d.ts","sourceRoot":"","sources":["../../../src/advanced/Code/CodeContent.tsx"],"names":[],"mappings":"AA6BA,MAAM,WAAW,SAAS;IACxB;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;OAGG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B;;;OAGG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB;;;OAGG;IACH,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB;;OAEG;IACH,MAAM,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IAChC;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB;AAED;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,iBAAS,IAAI,CAAC,EACZ,QAAQ,EACR,QAAgB,EAChB,SAAS,EACT,eAAsB,EACtB,SAAiB,EACjB,cAAqB,EACrB,MAAM,EACN,OAAe,GAChB,EAAE,SAAS,2CAsQX;AAED,eAAe,IAAI,CAAC"}
1
+ {"version":3,"file":"CodeContent.d.ts","sourceRoot":"","sources":["../../../src/advanced/Code/CodeContent.tsx"],"names":[],"mappings":"AA6BA,MAAM,WAAW,SAAS;IACxB;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;OAGG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B;;;OAGG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB;;;OAGG;IACH,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB;;OAEG;IACH,MAAM,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IAChC;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB;AAED;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,iBAAS,IAAI,CAAC,EACZ,QAAQ,EACR,QAAgB,EAChB,SAAS,EACT,eAAsB,EACtB,SAAiB,EACjB,cAAqB,EACrB,MAAM,EACN,OAAe,GAChB,EAAE,SAAS,2CAuQX;AAED,eAAe,IAAI,CAAC"}
@@ -7,7 +7,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
7
7
  * Gracefully degrades to basic <pre><code> if shiki is not installed.
8
8
  * To enable syntax highlighting: npm install shiki
9
9
  *
10
- * @version 0.0.2
10
+ * @version 0.1.0
11
11
  * @since 0.0.1
12
12
  * @author AMBROISE PARK Consulting
13
13
  */
@@ -79,7 +79,9 @@ function Code({ children, language = 'tsx', className, showLineNumbers = true, w
79
79
  import('shiki/langs/yaml.mjs'),
80
80
  import('shiki/langs/markdown.mjs'),
81
81
  ]);
82
- const themes = langAndThemeModules.slice(0, 2).map((m) => m.default);
82
+ const themes = langAndThemeModules
83
+ .slice(0, 2)
84
+ .map((m) => m.default);
83
85
  const langs = langAndThemeModules.slice(2).map((m) => m.default);
84
86
  const shiki = await createHighlighterCore({
85
87
  themes,
@@ -141,15 +143,15 @@ function Code({ children, language = 'tsx', className, showLineNumbers = true, w
141
143
  // Also strip \n between </span> and <span — the .line spans
142
144
  // are display:block, so newlines would create double line breaks
143
145
  // under white-space:pre.
146
+ //
147
+ // Safety: This HTML is trusted — produced by Shiki's codeToHtml()
148
+ // from the `children` string prop. Shiki only emits <span> tags
149
+ // with class/style attributes. No user-provided HTML reaches here.
144
150
  const inner = html
145
151
  .replace(/^<pre[^>]*><code[^>]*>/, '')
146
152
  .replace(/<\/code><\/pre>$/, '')
147
153
  .replace(/\n/g, '');
148
- // Sanitize Shiki output: strip <script> tags and on* event handler attributes
149
- const sanitized = inner
150
- .replace(/<script\b[^>]*>[\s\S]*?<\/script>/gi, '')
151
- .replace(/\s+on\w+\s*=\s*(?:"[^"]*"|'[^']*'|[^\s>]+)/gi, '');
152
- return sanitized;
154
+ return inner;
153
155
  }
154
156
  catch (error) {
155
157
  if (process.env.NODE_ENV === 'development') {
@@ -4,7 +4,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
4
4
  * @fileoverview Code Skeleton Component
5
5
  * @description Loading skeleton for Code component
6
6
  *
7
- * @version 0.0.1
7
+ * @version 0.1.0
8
8
  * @since 0.0.1
9
9
  * @author AMBROISE PARK Consulting
10
10
  */
@@ -3,7 +3,7 @@
3
3
  * @description Cinematic 3D text crawl. Intro renders immediately (eager),
4
4
  * heavy 3D animation loads lazily after user clicks play.
5
5
  *
6
- * @version 0.0.2
6
+ * @version 0.1.0
7
7
  * @since 0.0.1
8
8
  * @author AMBROISE PARK Consulting
9
9
  */
@@ -36,7 +36,7 @@ export interface CrawlProps {
36
36
  * - Heavy 3D animation lazy loads after user clicks play
37
37
  * - Zero initial bundle impact for animation code
38
38
  *
39
- * @version 0.0.3
39
+ * @version 0.1.0
40
40
  * @since 0.0.1
41
41
  */
42
42
  declare const Crawl: ({ content, intro, title, duration, contentHeight, tiltAngle, className, style, "aria-label": ariaLabel, }: CrawlProps) => import("react/jsx-runtime").JSX.Element;
@@ -5,7 +5,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
5
5
  * @description Cinematic 3D text crawl. Intro renders immediately (eager),
6
6
  * heavy 3D animation loads lazily after user clicks play.
7
7
  *
8
- * @version 0.0.2
8
+ * @version 0.1.0
9
9
  * @since 0.0.1
10
10
  * @author AMBROISE PARK Consulting
11
11
  */
@@ -22,7 +22,7 @@ const CrawlContent = lazy(() => import('./CrawlContent'));
22
22
  * - Heavy 3D animation lazy loads after user clicks play
23
23
  * - Zero initial bundle impact for animation code
24
24
  *
25
- * @version 0.0.3
25
+ * @version 0.1.0
26
26
  * @since 0.0.1
27
27
  */
28
28
  const Crawl = ({ content, intro, title, duration = 36, contentHeight = '150vh', tiltAngle, className, style, 'aria-label': ariaLabel, }) => {
@@ -3,7 +3,7 @@
3
3
  * @description Contains the 3D perspective animation, starfield, and text crawl.
4
4
  * Lazy loaded after user clicks play to keep initial bundle small.
5
5
  *
6
- * @version 0.0.1
6
+ * @version 0.1.0
7
7
  * @since 0.0.1
8
8
  * @author AMBROISE PARK Consulting
9
9
  */
@@ -5,7 +5,7 @@ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-run
5
5
  * @description Contains the 3D perspective animation, starfield, and text crawl.
6
6
  * Lazy loaded after user clicks play to keep initial bundle small.
7
7
  *
8
- * @version 0.0.1
8
+ * @version 0.1.0
9
9
  * @since 0.0.1
10
10
  * @author AMBROISE PARK Consulting
11
11
  */
@@ -2,7 +2,7 @@
2
2
  * @fileoverview HTML Parser Utility
3
3
  * @description Parse simple HTML tags into React components. Provides safe HTML parsing with configurable allowed tags and line break preservation.
4
4
  *
5
- * @version 0.0.1
5
+ * @version 0.1.0
6
6
  * @since 0.0.1
7
7
  * @author AMBROISE PARK Consulting
8
8
  */
@@ -10,7 +10,7 @@ import { type JSX, type ReactNode, type ReactElement } from 'react';
10
10
  /**
11
11
  * Supported HTML tags for parsing
12
12
  *
13
- * @version 0.0.1
13
+ * @version 0.1.0
14
14
  * @since 0.0.1
15
15
  * @author AMBROISE PARK Consulting
16
16
  */
@@ -18,7 +18,7 @@ export type SupportedHtmlTag = 'p' | 'br' | 'u' | 'i' | 'em' | 'strong' | 'b';
18
18
  /**
19
19
  * Options for HTML parsing
20
20
  *
21
- * @version 0.0.1
21
+ * @version 0.1.0
22
22
  * @since 0.0.1
23
23
  * @author AMBROISE PARK Consulting
24
24
  */
@@ -44,7 +44,7 @@ export interface ParseHtmlOptions {
44
44
  * // Returns: [React.Fragment with "Hello ", <u>world</u>, " and ", <i>italic</i>, " text"]
45
45
  * ```
46
46
  *
47
- * @version 0.0.1
47
+ * @version 0.1.0
48
48
  * @since 0.0.1
49
49
  * @author AMBROISE PARK Consulting
50
50
  */
@@ -64,7 +64,7 @@ export declare function parseHtml(html: string, options?: ParseHtmlOptions): Rea
64
64
  * // Returns: <p>Hello <u>world</u></p>
65
65
  * ```
66
66
  *
67
- * @version 0.0.1
67
+ * @version 0.1.0
68
68
  * @since 0.0.1
69
69
  * @author AMBROISE PARK Consulting
70
70
  */
@@ -1 +1 @@
1
- {"version":3,"file":"parseHtml.d.ts","sourceRoot":"","sources":["../../../../src/advanced/Crawl/utils/parseHtml.tsx"],"names":[],"mappings":"AAEA;;;;;;;GAOG;AAEH,OAAO,EAEL,KAAK,GAAG,EACR,KAAK,SAAS,EACd,KAAK,YAAY,EAClB,MAAM,OAAO,CAAC;AAEf;;;;;;GAMG;AACH,MAAM,MAAM,gBAAgB,GAAG,GAAG,GAAG,IAAI,GAAG,GAAG,GAAG,GAAG,GAAG,IAAI,GAAG,QAAQ,GAAG,GAAG,CAAC;AAE9E;;;;;;GAMG;AACH,MAAM,WAAW,gBAAgB;IAC/B,iCAAiC;IACjC,WAAW,CAAC,EAAE,gBAAgB,EAAE,CAAC;IACjC,oDAAoD;IACpD,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,6CAA6C;IAC7C,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAgB,SAAS,CACvB,IAAI,EAAE,MAAM,EACZ,OAAO,GAAE,gBAAqB,GAC7B,SAAS,EAAE,CAsFb;AAkCD;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,gBAAgB,CAC9B,IAAI,EAAE,MAAM,EACZ,OAAO,GAAE,MAAM,GAAG,CAAC,iBAAyB,EAC5C,OAAO,GAAE,gBAAqB,GAC7B,YAAY,CASd"}
1
+ {"version":3,"file":"parseHtml.d.ts","sourceRoot":"","sources":["../../../../src/advanced/Crawl/utils/parseHtml.tsx"],"names":[],"mappings":"AAEA;;;;;;;GAOG;AAEH,OAAO,EAEL,KAAK,GAAG,EACR,KAAK,SAAS,EACd,KAAK,YAAY,EAClB,MAAM,OAAO,CAAC;AAEf;;;;;;GAMG;AACH,MAAM,MAAM,gBAAgB,GAAG,GAAG,GAAG,IAAI,GAAG,GAAG,GAAG,GAAG,GAAG,IAAI,GAAG,QAAQ,GAAG,GAAG,CAAC;AAE9E;;;;;;GAMG;AACH,MAAM,WAAW,gBAAgB;IAC/B,iCAAiC;IACjC,WAAW,CAAC,EAAE,gBAAgB,EAAE,CAAC;IACjC,oDAAoD;IACpD,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,6CAA6C;IAC7C,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAgB,SAAS,CACvB,IAAI,EAAE,MAAM,EACZ,OAAO,GAAE,gBAAqB,GAC7B,SAAS,EAAE,CA2Fb;AAkCD;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,gBAAgB,CAC9B,IAAI,EAAE,MAAM,EACZ,OAAO,GAAE,MAAM,GAAG,CAAC,iBAAyB,EAC5C,OAAO,GAAE,gBAAqB,GAC7B,YAAY,CASd"}
@@ -3,7 +3,7 @@
3
3
  * @fileoverview HTML Parser Utility
4
4
  * @description Parse simple HTML tags into React components. Provides safe HTML parsing with configurable allowed tags and line break preservation.
5
5
  *
6
- * @version 0.0.1
6
+ * @version 0.1.0
7
7
  * @since 0.0.1
8
8
  * @author AMBROISE PARK Consulting
9
9
  */
@@ -22,7 +22,7 @@ import { createElement, } from 'react';
22
22
  * // Returns: [React.Fragment with "Hello ", <u>world</u>, " and ", <i>italic</i>, " text"]
23
23
  * ```
24
24
  *
25
- * @version 0.0.1
25
+ * @version 0.1.0
26
26
  * @since 0.0.1
27
27
  * @author AMBROISE PARK Consulting
28
28
  */
@@ -62,16 +62,22 @@ export function parseHtml(html, options = {}) {
62
62
  if (openingTagMatch && openingTagMatch[1]) {
63
63
  const tagName = openingTagMatch[1].toLowerCase();
64
64
  if (allowedTags.includes(tagName)) {
65
- // Find the corresponding closing tag — use exact match, not includes,
66
- // to handle nested cases (e.g., <b> inside <b> won't match prematurely)
65
+ // Find the corresponding closing tag using depth tracking
66
+ // to handle nested identical tags (e.g., <b>outer <b>inner</b> outer</b>)
67
+ const openingTag = `<${tagName}>`;
67
68
  const closingTag = `</${tagName}>`;
68
69
  let content = '';
69
70
  let j = i + 1;
70
- // Collect content until an exact closing tag part is found
71
+ let depth = 1;
71
72
  while (j < parts.length && parts[j]) {
72
- // parts are split by tags, so a closing tag part should match exactly
73
- if (parts[j] === closingTag) {
74
- break;
73
+ if (parts[j] === openingTag) {
74
+ depth++;
75
+ }
76
+ else if (parts[j] === closingTag) {
77
+ depth--;
78
+ if (depth === 0) {
79
+ break;
80
+ }
75
81
  }
76
82
  content += parts[j];
77
83
  j++;
@@ -135,7 +141,7 @@ function createHtmlElement(tagName, content, className, key) {
135
141
  * // Returns: <p>Hello <u>world</u></p>
136
142
  * ```
137
143
  *
138
- * @version 0.0.1
144
+ * @version 0.1.0
139
145
  * @since 0.0.1
140
146
  * @author AMBROISE PARK Consulting
141
147
  */
@@ -5,7 +5,7 @@ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-run
5
5
  * @fileoverview ImageGallery component
6
6
  * @description Full-featured image gallery with keyboard navigation, arrows, and wrapping thumbnails
7
7
  *
8
- * @version 0.0.1
8
+ * @version 0.1.0
9
9
  * @since 0.0.1
10
10
  * @author AMBROISE PARK Consulting
11
11
  */
@@ -5,7 +5,7 @@ import { jsxs as _jsxs, jsx as _jsx } from "react/jsx-runtime";
5
5
  * @fileoverview JSON Viewer Component
6
6
  * @description Interactive JSON viewer with collapsible nodes, syntax highlighting, and copy functionality
7
7
  *
8
- * @version 0.0.1
8
+ * @version 0.1.0
9
9
  * @since 0.0.1
10
10
  * @author AMBROISE PARK Consulting
11
11
  */
@@ -4,7 +4,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
4
4
  * @fileoverview Marquee Component
5
5
  * @description Marquee component with lazy loading built-in. Features smooth CSS animations with hardware acceleration, pause on hover, RTL language support, configurable speed and direction, and responsive gap spacing.
6
6
  *
7
- * @version 0.0.1
7
+ * @version 0.1.0
8
8
  * @since 0.0.1
9
9
  * @author AMBROISE PARK Consulting
10
10
  */
@@ -4,7 +4,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
4
4
  * @fileoverview Marquee Content Component
5
5
  * @description Production-grade marquee with accessibility, reduced motion support, and smart behavior detection
6
6
  *
7
- * @version 0.0.1
7
+ * @version 0.1.0
8
8
  * @since 0.0.1
9
9
  * @author AMBROISE PARK Consulting
10
10
  */
@@ -4,7 +4,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
4
4
  * @fileoverview Marquee Skeleton Component
5
5
  * @description Loading skeleton for Marquee component
6
6
  *
7
- * @version 0.0.1
7
+ * @version 0.1.0
8
8
  * @since 0.0.1
9
9
  * @author AMBROISE PARK Consulting
10
10
  */
@@ -2,7 +2,7 @@
2
2
  * @fileoverview Reveal Component
3
3
  * @description Reveal component for staggered animations. Features viewport-based visibility detection, directional animations, customizable stagger delays, and support for string arrays or ReactNode arrays.
4
4
  *
5
- * @version 0.0.2
5
+ * @version 0.1.0
6
6
  * @since 0.0.1
7
7
  * @author AMBROISE PARK Consulting
8
8
  */
@@ -4,7 +4,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
4
4
  * @fileoverview Reveal Component
5
5
  * @description Reveal component for staggered animations. Features viewport-based visibility detection, directional animations, customizable stagger delays, and support for string arrays or ReactNode arrays.
6
6
  *
7
- * @version 0.0.2
7
+ * @version 0.1.0
8
8
  * @since 0.0.1
9
9
  * @author AMBROISE PARK Consulting
10
10
  */
@@ -3,7 +3,7 @@
3
3
  * @description Timeline component with horizontal (desktop) / vertical (mobile) layout.
4
4
  * Features animated progress line, glowing nodes, and lift-on-hover cards.
5
5
  *
6
- * @version 0.0.2
6
+ * @version 0.1.0
7
7
  * @since 0.0.1
8
8
  * @author AMBROISE PARK Consulting
9
9
  */
@@ -5,7 +5,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
5
5
  * @description Timeline component with horizontal (desktop) / vertical (mobile) layout.
6
6
  * Features animated progress line, glowing nodes, and lift-on-hover cards.
7
7
  *
8
- * @version 0.0.2
8
+ * @version 0.1.0
9
9
  * @since 0.0.1
10
10
  * @author AMBROISE PARK Consulting
11
11
  */
@@ -5,7 +5,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
5
5
  * @description Timeline component with horizontal (desktop) / vertical (mobile) layout.
6
6
  * Features animated progress line, glowing nodes, and cards with content at bottom.
7
7
  *
8
- * @version 0.0.4
8
+ * @version 0.1.0
9
9
  * @since 0.0.1
10
10
  * @author AMBROISE PARK Consulting
11
11
  */
@@ -2,7 +2,7 @@ import type { ReactNode, ComponentType } from 'react';
2
2
  /**
3
3
  * Stat card data structure
4
4
  *
5
- * @version 0.0.1
5
+ * @version 0.1.0
6
6
  * @since 0.0.1
7
7
  * @author AMBROISE PARK Consulting
8
8
  */
@@ -13,7 +13,7 @@ export interface StatCardData {
13
13
  /**
14
14
  * Props for SplitReveal component
15
15
  *
16
- * @version 0.0.1
16
+ * @version 0.1.0
17
17
  * @since 0.0.1
18
18
  * @author AMBROISE PARK Consulting
19
19
  */
@@ -89,7 +89,7 @@ declare const SplitReveal: ComponentType<SplitRevealProps>;
89
89
  /**
90
90
  * Split reveal component
91
91
  *
92
- * @version 0.0.1
92
+ * @version 0.1.0
93
93
  * @since 0.0.1
94
94
  * @author AMBROISE PARK Consulting
95
95
  */
@@ -4,7 +4,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
4
4
  * @fileoverview Split Reveal Component
5
5
  * @description Split reveal component for displaying content in two columns. Features left column content and right column stat cards or custom content with reveal animations.
6
6
  *
7
- * @version 0.0.1
7
+ * @version 0.1.0
8
8
  * @since 0.0.1
9
9
  * @author AMBROISE PARK Consulting
10
10
  */
@@ -36,7 +36,7 @@ const SplitReveal = ({ left, right, leftDirection = 'left', rightDirection = 'ri
36
36
  /**
37
37
  * Split reveal component
38
38
  *
39
- * @version 0.0.1
39
+ * @version 0.1.0
40
40
  * @since 0.0.1
41
41
  * @author AMBROISE PARK Consulting
42
42
  */
@@ -3,7 +3,7 @@
3
3
  * @description Simple scroll-reveal stacked cards. Active card shows full content,
4
4
  * stacked cards show only bottom edge with number. No height calculations.
5
5
  *
6
- * @version 0.0.2
6
+ * @version 0.1.0
7
7
  * @since 0.0.1
8
8
  * @author AMBROISE PARK Consulting
9
9
  */
@@ -5,7 +5,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
5
5
  * @description Simple scroll-reveal stacked cards. Active card shows full content,
6
6
  * stacked cards show only bottom edge with number. No height calculations.
7
7
  *
8
- * @version 0.0.2
8
+ * @version 0.1.0
9
9
  * @since 0.0.1
10
10
  * @author AMBROISE PARK Consulting
11
11
  */
@@ -5,7 +5,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
5
5
  * @description Simple stacked cards with scroll-reveal. Active card shows full content,
6
6
  * stacked cards show only bottom edge with number.
7
7
  *
8
- * @version 0.0.2
8
+ * @version 0.1.0
9
9
  * @since 0.0.1
10
10
  * @author AMBROISE PARK Consulting
11
11
  */
@@ -2,7 +2,7 @@
2
2
  * @fileoverview Advanced Components
3
3
  * @description Complex, composite UI components for DoNotDev framework
4
4
  *
5
- * @version 0.0.1
5
+ * @version 0.1.0
6
6
  * @since 0.0.1
7
7
  * @author AMBROISE PARK Consulting
8
8
  */
@@ -3,7 +3,7 @@
3
3
  * @fileoverview Advanced Components
4
4
  * @description Complex, composite UI components for DoNotDev framework
5
5
  *
6
- * @version 0.0.1
6
+ * @version 0.1.0
7
7
  * @since 0.0.1
8
8
  * @author AMBROISE PARK Consulting
9
9
  */
@@ -2,7 +2,7 @@
2
2
  * @fileoverview Accordion component
3
3
  * @description Accessible accordion component built on Radix UI primitives
4
4
  *
5
- * @version 0.0.1
5
+ * @version 0.1.0
6
6
  * @since 0.0.1
7
7
  * @author AMBROISE PARK Consulting
8
8
  */
@@ -4,7 +4,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
4
4
  * @fileoverview Accordion component
5
5
  * @description Accessible accordion component built on Radix UI primitives
6
6
  *
7
- * @version 0.0.1
7
+ * @version 0.1.0
8
8
  * @since 0.0.1
9
9
  * @author AMBROISE PARK Consulting
10
10
  */
@@ -4,7 +4,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
4
4
  * @fileoverview Accordion component
5
5
  * @description Accessible accordion component built on Radix UI primitives provides a prop based implementation to get rid of Radix internal nesting.
6
6
  *
7
- * @version 0.0.1
7
+ * @version 0.1.0
8
8
  * @since 0.0.1
9
9
  * @author AMBROISE PARK Consulting
10
10
  */