origam 2.2.1 → 2.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (345) hide show
  1. package/CHANGELOG.md +224 -0
  2. package/README.md +22 -0
  3. package/dist/src/assets/css/tokens/dark.css +318 -0
  4. package/dist/src/assets/css/tokens/light.css +159 -0
  5. package/dist/src/assets/locales/index.js +2 -2
  6. package/dist/src/assets/scss/tokens/_dark.scss +159 -0
  7. package/dist/src/assets/scss/tokens/_light.scss +159 -0
  8. package/dist/src/components/Bracket/OrigamBracket.vue +530 -0
  9. package/dist/src/components/Bracket/OrigamBracketCompetitor.vue +210 -0
  10. package/dist/src/components/Bracket/OrigamBracketMatch.vue +288 -0
  11. package/dist/src/components/Bracket/OrigamBracketRound.vue +150 -0
  12. package/dist/src/components/Bracket/index.cjs +34 -0
  13. package/dist/src/components/Bracket/index.d.ts +4 -0
  14. package/dist/src/components/Bracket/index.js +4 -0
  15. package/dist/src/components/ClientOnly/OrigamClientOnly.vue +28 -0
  16. package/dist/src/components/ClientOnly/index.cjs +13 -0
  17. package/dist/src/components/ClientOnly/index.d.ts +1 -0
  18. package/dist/src/components/ClientOnly/index.js +1 -0
  19. package/dist/src/components/Code/OrigamCode.vue +449 -0
  20. package/dist/src/components/Code/index.cjs +13 -0
  21. package/dist/src/components/Code/index.d.ts +1 -0
  22. package/dist/src/components/Code/index.js +1 -0
  23. package/dist/src/components/ColorPickerField/OrigamColorPickerField.vue +1 -0
  24. package/dist/src/components/CommandPalette/OrigamCommandPalette.vue +614 -0
  25. package/dist/src/components/CommandPalette/index.cjs +13 -0
  26. package/dist/src/components/CommandPalette/index.d.ts +1 -0
  27. package/dist/src/components/CommandPalette/index.js +1 -0
  28. package/dist/src/components/DatePickerField/OrigamDatePickerField.vue +1 -0
  29. package/dist/src/components/Parallax/OrigamParallax.vue +65 -34
  30. package/dist/src/components/Parallax/OrigamParallaxLayer.vue +119 -0
  31. package/dist/src/components/Parallax/index.cjs +7 -0
  32. package/dist/src/components/Parallax/index.d.ts +1 -0
  33. package/dist/src/components/Parallax/index.js +1 -0
  34. package/dist/src/components/PasswordField/OrigamPasswordField.vue +1 -0
  35. package/dist/src/components/Select/OrigamSelect.vue +1 -0
  36. package/dist/src/components/SnackbarStack/OrigamSnackbarStack.vue +457 -0
  37. package/dist/src/components/SnackbarStack/index.cjs +13 -0
  38. package/dist/src/components/SnackbarStack/index.d.ts +1 -0
  39. package/dist/src/components/SnackbarStack/index.js +1 -0
  40. package/dist/src/components/Tabs/OrigamTab.vue +263 -0
  41. package/dist/src/components/Tabs/OrigamTabPanel.vue +112 -0
  42. package/dist/src/components/Tabs/OrigamTabPanels.vue +139 -0
  43. package/dist/src/components/Tabs/OrigamTabs.vue +242 -0
  44. package/dist/src/components/Tabs/index.cjs +34 -0
  45. package/dist/src/components/Tabs/index.d.ts +4 -0
  46. package/dist/src/components/Tabs/index.js +4 -0
  47. package/dist/src/components/TextField/OrigamTextField.vue +75 -5
  48. package/dist/src/components/TextareaField/OrigamRichToolbar.vue +284 -0
  49. package/dist/src/components/TextareaField/OrigamTextareaField.vue +192 -5
  50. package/dist/src/components/TextareaField/index.cjs +7 -0
  51. package/dist/src/components/TextareaField/index.d.ts +1 -0
  52. package/dist/src/components/TextareaField/index.js +1 -0
  53. package/dist/src/components/index.cjs +66 -0
  54. package/dist/src/components/index.d.ts +6 -0
  55. package/dist/src/components/index.js +6 -0
  56. package/dist/src/composables/Code/code.composable.cjs +98 -0
  57. package/dist/src/composables/Code/code.composable.d.ts +10 -0
  58. package/dist/src/composables/Code/code.composable.js +82 -0
  59. package/dist/src/composables/CommandPalette/command.composable.cjs +53 -0
  60. package/dist/src/composables/CommandPalette/command.composable.d.ts +37 -0
  61. package/dist/src/composables/CommandPalette/command.composable.js +46 -0
  62. package/dist/src/composables/Commons/virtual.composable.cjs +1 -0
  63. package/dist/src/composables/Commons/virtual.composable.js +1 -0
  64. package/dist/src/composables/CssSupport/cssSupport.composable.cjs +12 -0
  65. package/dist/src/composables/CssSupport/cssSupport.composable.d.ts +25 -0
  66. package/dist/src/composables/CssSupport/cssSupport.composable.js +10 -1
  67. package/dist/src/composables/DataTable/headers.composable.d.ts +36 -36
  68. package/dist/src/composables/Mask/index.cjs +16 -0
  69. package/dist/src/composables/Mask/index.d.ts +1 -0
  70. package/dist/src/composables/Mask/index.js +1 -0
  71. package/dist/src/composables/Mask/mask.composable.cjs +57 -0
  72. package/dist/src/composables/Mask/mask.composable.d.ts +39 -0
  73. package/dist/src/composables/Mask/mask.composable.js +51 -0
  74. package/dist/src/composables/Parallax/parallax.composable.cjs +232 -0
  75. package/dist/src/composables/Parallax/parallax.composable.d.ts +60 -0
  76. package/dist/src/composables/Parallax/parallax.composable.js +219 -0
  77. package/dist/src/composables/Responsive/aspect.composable.cjs +6 -1
  78. package/dist/src/composables/Responsive/aspect.composable.d.ts +10 -0
  79. package/dist/src/composables/Responsive/aspect.composable.js +6 -1
  80. package/dist/src/composables/SnackbarStack/snackbar-stack.composable.cjs +102 -0
  81. package/dist/src/composables/SnackbarStack/snackbar-stack.composable.d.ts +58 -0
  82. package/dist/src/composables/SnackbarStack/snackbar-stack.composable.js +92 -0
  83. package/dist/src/composables/Textarea/textarea-rich.composable.cjs +263 -0
  84. package/dist/src/composables/Textarea/textarea-rich.composable.d.ts +41 -0
  85. package/dist/src/composables/Textarea/textarea-rich.composable.js +257 -0
  86. package/dist/src/composables/index.cjs +66 -0
  87. package/dist/src/composables/index.d.ts +6 -0
  88. package/dist/src/composables/index.js +6 -0
  89. package/dist/src/consts/Bracket/bracket.const.cjs +12 -0
  90. package/dist/src/consts/Bracket/bracket.const.d.ts +34 -0
  91. package/dist/src/consts/Bracket/bracket.const.js +15 -0
  92. package/dist/src/consts/Code/code.const.cjs +26 -0
  93. package/dist/src/consts/Code/code.const.d.ts +40 -0
  94. package/dist/src/consts/Code/code.const.js +35 -0
  95. package/dist/src/consts/CommandPalette/command-palette.const.cjs +10 -0
  96. package/dist/src/consts/CommandPalette/command-palette.const.d.ts +16 -0
  97. package/dist/src/consts/CommandPalette/command-palette.const.js +7 -0
  98. package/dist/src/consts/Mask/built-in-patterns.const.cjs +66 -0
  99. package/dist/src/consts/Mask/built-in-patterns.const.d.ts +20 -0
  100. package/dist/src/consts/Mask/built-in-patterns.const.js +60 -0
  101. package/dist/src/consts/Parallax/parallax-layer.const.cjs +7 -0
  102. package/dist/src/consts/Parallax/parallax-layer.const.d.ts +3 -0
  103. package/dist/src/consts/Parallax/parallax-layer.const.js +1 -0
  104. package/dist/src/consts/SnackbarStack/snackbar-stack.const.cjs +12 -0
  105. package/dist/src/consts/SnackbarStack/snackbar-stack.const.d.ts +33 -0
  106. package/dist/src/consts/SnackbarStack/snackbar-stack.const.js +18 -0
  107. package/dist/src/consts/Tabs/tabs.const.cjs +9 -0
  108. package/dist/src/consts/Tabs/tabs.const.d.ts +23 -0
  109. package/dist/src/consts/Tabs/tabs.const.js +3 -0
  110. package/dist/src/consts/Textarea/textarea.const.cjs +28 -0
  111. package/dist/src/consts/Textarea/textarea.const.d.ts +38 -0
  112. package/dist/src/consts/Textarea/textarea.const.js +65 -0
  113. package/dist/src/consts/Theme/theme.const.cjs +15 -0
  114. package/dist/src/consts/Theme/theme.const.d.ts +9 -0
  115. package/dist/src/consts/Theme/theme.const.js +9 -0
  116. package/dist/src/consts/index.cjs +99 -0
  117. package/dist/src/consts/index.d.ts +9 -0
  118. package/dist/src/consts/index.js +9 -0
  119. package/dist/src/enums/Bracket/bracket-match-status.enum.cjs +13 -0
  120. package/dist/src/enums/Bracket/bracket-match-status.enum.d.ts +6 -0
  121. package/dist/src/enums/Bracket/bracket-match-status.enum.js +7 -0
  122. package/dist/src/enums/Bracket/bracket-variant.enum.cjs +12 -0
  123. package/dist/src/enums/Bracket/bracket-variant.enum.d.ts +5 -0
  124. package/dist/src/enums/Bracket/bracket-variant.enum.js +6 -0
  125. package/dist/src/enums/Code/code-lang.enum.cjs +23 -0
  126. package/dist/src/enums/Code/code-lang.enum.d.ts +25 -0
  127. package/dist/src/enums/Code/code-lang.enum.js +17 -0
  128. package/dist/src/enums/Code/code-theme.enum.cjs +12 -0
  129. package/dist/src/enums/Code/code-theme.enum.d.ts +12 -0
  130. package/dist/src/enums/Code/code-theme.enum.js +6 -0
  131. package/dist/src/enums/Mask/mask.enum.cjs +28 -0
  132. package/dist/src/enums/Mask/mask.enum.d.ts +36 -0
  133. package/dist/src/enums/Mask/mask.enum.js +22 -0
  134. package/dist/src/enums/Parallax/parallax-direction.enum.cjs +12 -0
  135. package/dist/src/enums/Parallax/parallax-direction.enum.d.ts +5 -0
  136. package/dist/src/enums/Parallax/parallax-direction.enum.js +6 -0
  137. package/dist/src/enums/Parallax/parallax-easing.enum.cjs +12 -0
  138. package/dist/src/enums/Parallax/parallax-easing.enum.d.ts +5 -0
  139. package/dist/src/enums/Parallax/parallax-easing.enum.js +6 -0
  140. package/dist/src/enums/Tabs/tab-variant.enum.cjs +12 -0
  141. package/dist/src/enums/Tabs/tab-variant.enum.d.ts +5 -0
  142. package/dist/src/enums/Tabs/tab-variant.enum.js +6 -0
  143. package/dist/src/enums/Textarea/textarea-mode.enum.cjs +11 -0
  144. package/dist/src/enums/Textarea/textarea-mode.enum.d.ts +13 -0
  145. package/dist/src/enums/Textarea/textarea-mode.enum.js +5 -0
  146. package/dist/src/enums/Textarea/textarea-output.enum.cjs +11 -0
  147. package/dist/src/enums/Textarea/textarea-output.enum.d.ts +14 -0
  148. package/dist/src/enums/Textarea/textarea-output.enum.js +5 -0
  149. package/dist/src/enums/Textarea/textarea-toolbar-command.enum.cjs +21 -0
  150. package/dist/src/enums/Textarea/textarea-toolbar-command.enum.d.ts +20 -0
  151. package/dist/src/enums/Textarea/textarea-toolbar-command.enum.js +15 -0
  152. package/dist/src/enums/Textarea/textarea-toolbar-position.enum.cjs +12 -0
  153. package/dist/src/enums/Textarea/textarea-toolbar-position.enum.d.ts +10 -0
  154. package/dist/src/enums/Textarea/textarea-toolbar-position.enum.js +6 -0
  155. package/dist/src/enums/index.cjs +132 -0
  156. package/dist/src/enums/index.d.ts +12 -0
  157. package/dist/src/enums/index.js +12 -0
  158. package/dist/src/interfaces/Bracket/bracket-competitor-component.interface.cjs +1 -0
  159. package/dist/src/interfaces/Bracket/bracket-competitor-component.interface.d.ts +53 -0
  160. package/dist/src/interfaces/Bracket/bracket-competitor-component.interface.js +0 -0
  161. package/dist/src/interfaces/Bracket/bracket-competitor.interface.cjs +1 -0
  162. package/dist/src/interfaces/Bracket/bracket-competitor.interface.d.ts +25 -0
  163. package/dist/src/interfaces/Bracket/bracket-competitor.interface.js +0 -0
  164. package/dist/src/interfaces/Bracket/bracket-match-component.interface.cjs +1 -0
  165. package/dist/src/interfaces/Bracket/bracket-match-component.interface.d.ts +45 -0
  166. package/dist/src/interfaces/Bracket/bracket-match-component.interface.js +0 -0
  167. package/dist/src/interfaces/Bracket/bracket-match.interface.cjs +1 -0
  168. package/dist/src/interfaces/Bracket/bracket-match.interface.d.ts +51 -0
  169. package/dist/src/interfaces/Bracket/bracket-match.interface.js +0 -0
  170. package/dist/src/interfaces/Bracket/bracket-round-component.interface.cjs +1 -0
  171. package/dist/src/interfaces/Bracket/bracket-round-component.interface.d.ts +26 -0
  172. package/dist/src/interfaces/Bracket/bracket-round-component.interface.js +0 -0
  173. package/dist/src/interfaces/Bracket/bracket-round.interface.cjs +1 -0
  174. package/dist/src/interfaces/Bracket/bracket-round.interface.d.ts +27 -0
  175. package/dist/src/interfaces/Bracket/bracket-round.interface.js +0 -0
  176. package/dist/src/interfaces/Bracket/bracket.interface.cjs +1 -0
  177. package/dist/src/interfaces/Bracket/bracket.interface.d.ts +71 -0
  178. package/dist/src/interfaces/Bracket/bracket.interface.js +0 -0
  179. package/dist/src/interfaces/Code/code.interface.cjs +1 -0
  180. package/dist/src/interfaces/Code/code.interface.d.ts +99 -0
  181. package/dist/src/interfaces/Code/code.interface.js +0 -0
  182. package/dist/src/interfaces/CommandPalette/command-palette.interface.cjs +1 -0
  183. package/dist/src/interfaces/CommandPalette/command-palette.interface.d.ts +57 -0
  184. package/dist/src/interfaces/CommandPalette/command-palette.interface.js +0 -0
  185. package/dist/src/interfaces/CommandPalette/command.interface.cjs +1 -0
  186. package/dist/src/interfaces/CommandPalette/command.interface.d.ts +51 -0
  187. package/dist/src/interfaces/CommandPalette/command.interface.js +0 -0
  188. package/dist/src/interfaces/Mask/mask-options.interface.cjs +1 -0
  189. package/dist/src/interfaces/Mask/mask-options.interface.d.ts +48 -0
  190. package/dist/src/interfaces/Mask/mask-options.interface.js +0 -0
  191. package/dist/src/interfaces/Nuxt/nuxt-module.interface.cjs +1 -0
  192. package/dist/src/interfaces/Nuxt/nuxt-module.interface.d.ts +73 -0
  193. package/dist/src/interfaces/Nuxt/nuxt-module.interface.js +0 -0
  194. package/dist/src/interfaces/Parallax/parallax-layer.interface.cjs +1 -0
  195. package/dist/src/interfaces/Parallax/parallax-layer.interface.d.ts +39 -0
  196. package/dist/src/interfaces/Parallax/parallax-layer.interface.js +0 -0
  197. package/dist/src/interfaces/Parallax/parallax.interface.d.ts +83 -3
  198. package/dist/src/interfaces/SnackbarStack/snackbar-stack-item.interface.cjs +1 -0
  199. package/dist/src/interfaces/SnackbarStack/snackbar-stack-item.interface.d.ts +60 -0
  200. package/dist/src/interfaces/SnackbarStack/snackbar-stack-item.interface.js +0 -0
  201. package/dist/src/interfaces/SnackbarStack/snackbar-stack.interface.cjs +1 -0
  202. package/dist/src/interfaces/SnackbarStack/snackbar-stack.interface.d.ts +60 -0
  203. package/dist/src/interfaces/SnackbarStack/snackbar-stack.interface.js +0 -0
  204. package/dist/src/interfaces/Tabs/tab-panel.interface.cjs +1 -0
  205. package/dist/src/interfaces/Tabs/tab-panel.interface.d.ts +12 -0
  206. package/dist/src/interfaces/Tabs/tab-panel.interface.js +0 -0
  207. package/dist/src/interfaces/Tabs/tab-panels.interface.cjs +1 -0
  208. package/dist/src/interfaces/Tabs/tab-panels.interface.d.ts +28 -0
  209. package/dist/src/interfaces/Tabs/tab-panels.interface.js +0 -0
  210. package/dist/src/interfaces/Tabs/tab.interface.cjs +1 -0
  211. package/dist/src/interfaces/Tabs/tab.interface.d.ts +18 -0
  212. package/dist/src/interfaces/Tabs/tab.interface.js +0 -0
  213. package/dist/src/interfaces/Tabs/tabs.interface.cjs +1 -0
  214. package/dist/src/interfaces/Tabs/tabs.interface.d.ts +26 -0
  215. package/dist/src/interfaces/Tabs/tabs.interface.js +0 -0
  216. package/dist/src/interfaces/TextField/text-field.interface.d.ts +21 -1
  217. package/dist/src/interfaces/Textarea/textarea-rich.interface.cjs +1 -0
  218. package/dist/src/interfaces/Textarea/textarea-rich.interface.d.ts +41 -0
  219. package/dist/src/interfaces/Textarea/textarea-rich.interface.js +0 -0
  220. package/dist/src/interfaces/Textarea/textarea-toolbar.interface.cjs +1 -0
  221. package/dist/src/interfaces/Textarea/textarea-toolbar.interface.d.ts +31 -0
  222. package/dist/src/interfaces/Textarea/textarea-toolbar.interface.js +0 -0
  223. package/dist/src/interfaces/TextareaField/textarea-field.interface.d.ts +38 -1
  224. package/dist/src/interfaces/index.cjs +231 -0
  225. package/dist/src/interfaces/index.d.ts +21 -0
  226. package/dist/src/interfaces/index.js +21 -0
  227. package/dist/src/nuxt/index.cjs +13 -0
  228. package/dist/src/nuxt/index.d.ts +2 -0
  229. package/dist/src/nuxt/index.js +1 -0
  230. package/dist/src/nuxt/module.cjs +74 -0
  231. package/dist/src/nuxt/module.d.ts +31 -0
  232. package/dist/src/nuxt/module.js +68 -0
  233. package/dist/src/nuxt/plugin.client.cjs +44 -0
  234. package/dist/src/nuxt/plugin.client.d.ts +2 -0
  235. package/dist/src/nuxt/plugin.client.js +36 -0
  236. package/dist/src/nuxt/plugin.server.cjs +51 -0
  237. package/dist/src/nuxt/plugin.server.d.ts +2 -0
  238. package/dist/src/nuxt/plugin.server.js +45 -0
  239. package/dist/src/types/Bracket/bracket-direction.type.cjs +1 -0
  240. package/dist/src/types/Bracket/bracket-direction.type.d.ts +13 -0
  241. package/dist/src/types/Bracket/bracket-direction.type.js +0 -0
  242. package/dist/src/types/Bracket/bracket-match-status.type.cjs +1 -0
  243. package/dist/src/types/Bracket/bracket-match-status.type.d.ts +2 -0
  244. package/dist/src/types/Bracket/bracket-match-status.type.js +0 -0
  245. package/dist/src/types/Bracket/bracket-round-side.type.cjs +1 -0
  246. package/dist/src/types/Bracket/bracket-round-side.type.d.ts +12 -0
  247. package/dist/src/types/Bracket/bracket-round-side.type.js +0 -0
  248. package/dist/src/types/Bracket/bracket-variant.type.cjs +1 -0
  249. package/dist/src/types/Bracket/bracket-variant.type.d.ts +2 -0
  250. package/dist/src/types/Bracket/bracket-variant.type.js +0 -0
  251. package/dist/src/types/Code/code-lang.type.cjs +1 -0
  252. package/dist/src/types/Code/code-lang.type.d.ts +2 -0
  253. package/dist/src/types/Code/code-lang.type.js +0 -0
  254. package/dist/src/types/Code/code-theme.type.cjs +1 -0
  255. package/dist/src/types/Code/code-theme.type.d.ts +2 -0
  256. package/dist/src/types/Code/code-theme.type.js +0 -0
  257. package/dist/src/types/CommandPalette/command-palette-hotkey.type.cjs +1 -0
  258. package/dist/src/types/CommandPalette/command-palette-hotkey.type.d.ts +5 -0
  259. package/dist/src/types/CommandPalette/command-palette-hotkey.type.js +0 -0
  260. package/dist/src/types/Mask/built-in-pattern.type.cjs +1 -0
  261. package/dist/src/types/Mask/built-in-pattern.type.d.ts +7 -0
  262. package/dist/src/types/Mask/built-in-pattern.type.js +0 -0
  263. package/dist/src/types/Mask/mask.type.cjs +1 -0
  264. package/dist/src/types/Mask/mask.type.d.ts +19 -0
  265. package/dist/src/types/Mask/mask.type.js +0 -0
  266. package/dist/src/types/Mask/pattern-validator.type.cjs +1 -0
  267. package/dist/src/types/Mask/pattern-validator.type.d.ts +16 -0
  268. package/dist/src/types/Mask/pattern-validator.type.js +0 -0
  269. package/dist/src/types/Parallax/parallax-direction.type.cjs +1 -0
  270. package/dist/src/types/Parallax/parallax-direction.type.d.ts +2 -0
  271. package/dist/src/types/Parallax/parallax-direction.type.js +0 -0
  272. package/dist/src/types/Parallax/parallax-easing.type.cjs +1 -0
  273. package/dist/src/types/Parallax/parallax-easing.type.d.ts +2 -0
  274. package/dist/src/types/Parallax/parallax-easing.type.js +0 -0
  275. package/dist/src/types/SnackbarStack/snackbar-stack-direction.type.cjs +1 -0
  276. package/dist/src/types/SnackbarStack/snackbar-stack-direction.type.d.ts +11 -0
  277. package/dist/src/types/SnackbarStack/snackbar-stack-direction.type.js +0 -0
  278. package/dist/src/types/SnackbarStack/snackbar-stack-location.type.cjs +1 -0
  279. package/dist/src/types/SnackbarStack/snackbar-stack-location.type.d.ts +9 -0
  280. package/dist/src/types/SnackbarStack/snackbar-stack-location.type.js +0 -0
  281. package/dist/src/types/SnackbarStack/snackbar-stack.type.cjs +1 -0
  282. package/dist/src/types/SnackbarStack/snackbar-stack.type.d.ts +2 -0
  283. package/dist/src/types/SnackbarStack/snackbar-stack.type.js +0 -0
  284. package/dist/src/types/Tabs/tab-panel.type.cjs +1 -0
  285. package/dist/src/types/Tabs/tab-panel.type.d.ts +2 -0
  286. package/dist/src/types/Tabs/tab-panel.type.js +0 -0
  287. package/dist/src/types/Tabs/tab-panels.type.cjs +1 -0
  288. package/dist/src/types/Tabs/tab-panels.type.d.ts +2 -0
  289. package/dist/src/types/Tabs/tab-panels.type.js +0 -0
  290. package/dist/src/types/Tabs/tab-variant.type.cjs +1 -0
  291. package/dist/src/types/Tabs/tab-variant.type.d.ts +2 -0
  292. package/dist/src/types/Tabs/tab-variant.type.js +0 -0
  293. package/dist/src/types/Tabs/tab.type.cjs +1 -0
  294. package/dist/src/types/Tabs/tab.type.d.ts +2 -0
  295. package/dist/src/types/Tabs/tab.type.js +0 -0
  296. package/dist/src/types/Tabs/tabs.type.cjs +1 -0
  297. package/dist/src/types/Tabs/tabs.type.d.ts +2 -0
  298. package/dist/src/types/Tabs/tabs.type.js +0 -0
  299. package/dist/src/types/Textarea/textarea-mode.type.cjs +1 -0
  300. package/dist/src/types/Textarea/textarea-mode.type.d.ts +2 -0
  301. package/dist/src/types/Textarea/textarea-mode.type.js +0 -0
  302. package/dist/src/types/Textarea/textarea-output.type.cjs +1 -0
  303. package/dist/src/types/Textarea/textarea-output.type.d.ts +2 -0
  304. package/dist/src/types/Textarea/textarea-output.type.js +0 -0
  305. package/dist/src/types/Textarea/textarea-toolbar-command.type.cjs +1 -0
  306. package/dist/src/types/Textarea/textarea-toolbar-command.type.d.ts +2 -0
  307. package/dist/src/types/Textarea/textarea-toolbar-command.type.js +0 -0
  308. package/dist/src/types/Textarea/textarea-toolbar-position.type.cjs +1 -0
  309. package/dist/src/types/Textarea/textarea-toolbar-position.type.d.ts +2 -0
  310. package/dist/src/types/Textarea/textarea-toolbar-position.type.js +0 -0
  311. package/dist/src/types/index.cjs +264 -0
  312. package/dist/src/types/index.d.ts +24 -0
  313. package/dist/src/types/index.js +24 -0
  314. package/dist/src/types/tokens.type.d.ts +1 -1
  315. package/dist/src/utils/Code/parse-highlight-lines.util.cjs +34 -0
  316. package/dist/src/utils/Code/parse-highlight-lines.util.d.ts +24 -0
  317. package/dist/src/utils/Code/parse-highlight-lines.util.js +28 -0
  318. package/dist/src/utils/CommandPalette/fuzzy-match.util.cjs +84 -0
  319. package/dist/src/utils/CommandPalette/fuzzy-match.util.d.ts +51 -0
  320. package/dist/src/utils/CommandPalette/fuzzy-match.util.js +62 -0
  321. package/dist/src/utils/Mask/apply-mask.util.cjs +120 -0
  322. package/dist/src/utils/Mask/apply-mask.util.d.ts +13 -0
  323. package/dist/src/utils/Mask/apply-mask.util.js +91 -0
  324. package/dist/src/utils/Mask/index.cjs +38 -0
  325. package/dist/src/utils/Mask/index.d.ts +3 -0
  326. package/dist/src/utils/Mask/index.js +3 -0
  327. package/dist/src/utils/Mask/resolve-mask-config.util.cjs +31 -0
  328. package/dist/src/utils/Mask/resolve-mask-config.util.d.ts +15 -0
  329. package/dist/src/utils/Mask/resolve-mask-config.util.js +21 -0
  330. package/dist/src/utils/Mask/validate-pattern.util.cjs +92 -0
  331. package/dist/src/utils/Mask/validate-pattern.util.d.ts +41 -0
  332. package/dist/src/utils/Mask/validate-pattern.util.js +81 -0
  333. package/dist/src/utils/Textarea/html-to-markdown.util.cjs +85 -0
  334. package/dist/src/utils/Textarea/html-to-markdown.util.d.ts +21 -0
  335. package/dist/src/utils/Textarea/html-to-markdown.util.js +78 -0
  336. package/dist/src/utils/Textarea/sanitize-html.util.cjs +82 -0
  337. package/dist/src/utils/Textarea/sanitize-html.util.d.ts +17 -0
  338. package/dist/src/utils/Textarea/sanitize-html.util.js +83 -0
  339. package/dist/src/utils/index.cjs +77 -0
  340. package/dist/src/utils/index.d.ts +7 -0
  341. package/dist/src/utils/index.js +7 -0
  342. package/package.json +13 -3
  343. package/dist/src/globals.d.ts +0 -172
  344. package/dist/src/shims.d.ts +0 -36
  345. package/dist/src/vite-env.d.ts +0 -1
@@ -0,0 +1,242 @@
1
+ <template>
2
+ <component
3
+ :is="tag"
4
+ :id="id"
5
+ ref="rootRef"
6
+ role="tablist"
7
+ :aria-orientation="ariaOrientation"
8
+ :class="tabsClasses"
9
+ :style="tabsStyles"
10
+ @keydown="handleKeydown"
11
+ >
12
+ <origam-defaults-provider :defaults="slotDefaults">
13
+ <slot
14
+ name="default"
15
+ v-bind="slotProps"
16
+ />
17
+ </origam-defaults-provider>
18
+ </component>
19
+ </template>
20
+
21
+ <script setup>
22
+ import { computed, ref, StyleValue } from "vue";
23
+ import { OrigamDefaultsProvider } from "../../components";
24
+ import {
25
+ useDensity,
26
+ useGroup,
27
+ useProps,
28
+ useRounded,
29
+ useStyle
30
+ } from "../../composables";
31
+ import { ORIGAM_TABS_KEY } from "../../consts";
32
+ import { DENSITY, DIRECTION, TAB_VARIANT } from "../../enums";
33
+ const props = defineProps({
34
+ tag: { type: String, required: false, default: "div" },
35
+ variant: { type: null, required: false, default: TAB_VARIANT.DEFAULT },
36
+ fixed: { type: Boolean, required: false, default: false },
37
+ centered: { type: Boolean, required: false, default: false },
38
+ id: { type: String, required: false },
39
+ class: { type: [String, Array, Object], required: false },
40
+ style: { type: [String, Array, Object, Boolean, null], required: false, skipCheck: true },
41
+ direction: { type: null, required: false, default: DIRECTION.HORIZONTAL },
42
+ density: { type: null, required: false, default: DENSITY.DEFAULT },
43
+ rounded: { type: [Boolean, Number, String, null], required: false, skipCheck: true },
44
+ roundedTopRight: { type: [Boolean, Number, String], required: false },
45
+ roundedTopLeft: { type: [Boolean, Number, String], required: false },
46
+ roundedBottomLeft: { type: [Boolean, Number, String], required: false },
47
+ roundedBottomRight: { type: [Boolean, Number, String], required: false },
48
+ color: { type: [String, Boolean, null], required: false, skipCheck: true },
49
+ bgColor: { type: [String, Boolean, null], required: false, skipCheck: true },
50
+ disabled: { type: Boolean, required: false },
51
+ modelValue: { type: null, required: false },
52
+ multiple: { type: Boolean, required: false },
53
+ mandatory: { type: Boolean, required: false, default: true },
54
+ max: { type: Number, required: false },
55
+ selectedClass: { type: String, required: false, default: "origam-tab--active" }
56
+ });
57
+ defineEmits(["update:modelValue"]);
58
+ const { filterProps } = useProps(props);
59
+ const { isSelected, select, next, prev, selected, items } = useGroup(props, ORIGAM_TABS_KEY);
60
+ const rootRef = ref();
61
+ const slotProps = computed(() => ({
62
+ isSelected,
63
+ select,
64
+ next,
65
+ prev,
66
+ selected,
67
+ items: items.value
68
+ }));
69
+ const slotDefaults = computed(() => ({
70
+ "origam-tab": {
71
+ density: props.density,
72
+ color: props.color,
73
+ variant: props.variant,
74
+ fixed: props.fixed
75
+ }
76
+ }));
77
+ const ariaOrientation = computed(() => props.direction === DIRECTION.VERTICAL ? "vertical" : "horizontal");
78
+ const focusTab = (id2) => {
79
+ if (!rootRef.value) return;
80
+ const target = rootRef.value.querySelector(`[data-origam-tab-id="${id2}"]`);
81
+ target?.focus();
82
+ };
83
+ const focusFirstNonDisabled = (offset) => {
84
+ const list = items.value;
85
+ if (!list.length) return;
86
+ const start = offset > 0 ? 0 : list.length - 1;
87
+ const end = offset > 0 ? list.length : -1;
88
+ for (let i = start; i !== end; i += offset) {
89
+ const item = list[i];
90
+ if (!item.disabled) {
91
+ select(item.id, true);
92
+ focusTab(item.id);
93
+ return;
94
+ }
95
+ }
96
+ };
97
+ const handleKeydown = (event) => {
98
+ const isHorizontal = props.direction !== DIRECTION.VERTICAL;
99
+ const prevKey = isHorizontal ? "ArrowLeft" : "ArrowUp";
100
+ const nextKey = isHorizontal ? "ArrowRight" : "ArrowDown";
101
+ const currentId = selected.value[0];
102
+ if (event.key === prevKey) {
103
+ event.preventDefault();
104
+ prev();
105
+ if (selected.value[0] != null) focusTab(selected.value[0]);
106
+ } else if (event.key === nextKey) {
107
+ event.preventDefault();
108
+ next();
109
+ if (selected.value[0] != null) focusTab(selected.value[0]);
110
+ } else if (event.key === "Home") {
111
+ event.preventDefault();
112
+ focusFirstNonDisabled(1);
113
+ } else if (event.key === "End") {
114
+ event.preventDefault();
115
+ focusFirstNonDisabled(-1);
116
+ } else if (event.key === "Enter" || event.key === " ") {
117
+ if (currentId != null) {
118
+ event.preventDefault();
119
+ select(currentId, true);
120
+ }
121
+ }
122
+ };
123
+ const { densityClasses } = useDensity(props);
124
+ const { roundedClasses, roundedStyles } = useRounded(props);
125
+ const tabsStyles = computed(() => {
126
+ return [
127
+ roundedStyles.value,
128
+ props.style
129
+ ];
130
+ });
131
+ const tabsClasses = computed(() => {
132
+ return [
133
+ "origam-tabs",
134
+ `origam-tabs--${props.variant}`,
135
+ `origam-tabs--direction-${props.direction}`,
136
+ {
137
+ "origam-tabs--fixed": props.fixed,
138
+ "origam-tabs--centered": props.centered
139
+ },
140
+ densityClasses.value,
141
+ roundedClasses.value,
142
+ props.class
143
+ ];
144
+ });
145
+ const { id, css, load, isLoaded, unload } = useStyle(tabsStyles);
146
+ defineExpose({
147
+ filterProps,
148
+ next,
149
+ prev,
150
+ select,
151
+ css,
152
+ id,
153
+ load,
154
+ unload,
155
+ isLoaded
156
+ });
157
+ </script>
158
+
159
+ <style lang="scss" scoped>
160
+ .origam-tabs {
161
+ display: flex;
162
+ flex-wrap: nowrap;
163
+ position: relative;
164
+ min-height: var(--origam-tabs---height, 48px);
165
+
166
+ gap: var(--origam-tabs---gap, 0);
167
+ padding-block: var(--origam-tabs---padding-block, 0);
168
+ padding-inline: var(--origam-tabs---padding-inline, 0);
169
+
170
+ background-color: var(--origam-tabs---background-color, transparent);
171
+ border-radius: var(--origam-tabs---border-radius, 0);
172
+ border-width: var(--origam-tabs---border-width, 0);
173
+ border-style: var(--origam-tabs---border-style, solid);
174
+ border-color: var(--origam-tabs---border-color, currentColor);
175
+ color: var(--origam-tabs---color, inherit);
176
+
177
+ &--direction-horizontal {
178
+ flex-direction: row;
179
+ align-items: stretch;
180
+ }
181
+
182
+ &--direction-vertical {
183
+ flex-direction: column;
184
+ align-items: stretch;
185
+ min-height: 0;
186
+ }
187
+
188
+ &--fixed {
189
+ :deep(.origam-tab) {
190
+ flex: 1 1 0;
191
+ min-width: 0;
192
+ }
193
+ }
194
+
195
+ &--centered {
196
+ justify-content: center;
197
+ }
198
+
199
+ &--default {
200
+ border-block-end-width: var(--origam-tabs--default---border-block-end-width, 1px);
201
+ border-block-end-color: var(--origam-tabs--default---border-block-end-color, var(--origam-color__border---subtle, rgba(0, 0, 0, 0.12)));
202
+ }
203
+
204
+ &--pills {
205
+ background-color: var(--origam-tabs--pills---background-color, transparent);
206
+ gap: var(--origam-tabs--pills---gap, 8px);
207
+ padding: var(--origam-tabs--pills---padding, 4px);
208
+ }
209
+
210
+ &--underline {
211
+ border-block-end-width: var(--origam-tabs--underline---border-block-end-width, 1px);
212
+ border-block-end-color: var(--origam-tabs--underline---border-block-end-color, var(--origam-color__border---subtle, rgba(0, 0, 0, 0.12)));
213
+ }
214
+
215
+ &--density-comfortable {
216
+ --origam-tabs---height: 56px;
217
+ }
218
+
219
+ &--density-default {
220
+ --origam-tabs---height: 48px;
221
+ }
222
+
223
+ &--density-compact {
224
+ --origam-tabs---height: 36px;
225
+ }
226
+ }
227
+ </style>
228
+
229
+ <style>
230
+ :root {
231
+ --origam-tabs---height: 48px;
232
+ --origam-tabs---gap: 0;
233
+ --origam-tabs---padding-block: 0;
234
+ --origam-tabs---padding-inline: 0;
235
+ --origam-tabs---background-color: transparent;
236
+ --origam-tabs---border-radius: 0;
237
+ --origam-tabs---border-width: 0;
238
+ --origam-tabs---border-style: solid;
239
+ --origam-tabs---border-color: currentColor;
240
+ --origam-tabs---color: inherit;
241
+ }
242
+ </style>
@@ -0,0 +1,34 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ Object.defineProperty(exports, "OrigamTab", {
7
+ enumerable: true,
8
+ get: function () {
9
+ return _OrigamTab.default;
10
+ }
11
+ });
12
+ Object.defineProperty(exports, "OrigamTabPanel", {
13
+ enumerable: true,
14
+ get: function () {
15
+ return _OrigamTabPanel.default;
16
+ }
17
+ });
18
+ Object.defineProperty(exports, "OrigamTabPanels", {
19
+ enumerable: true,
20
+ get: function () {
21
+ return _OrigamTabPanels.default;
22
+ }
23
+ });
24
+ Object.defineProperty(exports, "OrigamTabs", {
25
+ enumerable: true,
26
+ get: function () {
27
+ return _OrigamTabs.default;
28
+ }
29
+ });
30
+ var _OrigamTabs = _interopRequireDefault(require("./OrigamTabs.vue"));
31
+ var _OrigamTab = _interopRequireDefault(require("./OrigamTab.vue"));
32
+ var _OrigamTabPanels = _interopRequireDefault(require("./OrigamTabPanels.vue"));
33
+ var _OrigamTabPanel = _interopRequireDefault(require("./OrigamTabPanel.vue"));
34
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
@@ -0,0 +1,4 @@
1
+ export { default as OrigamTabs } from './OrigamTabs.vue';
2
+ export { default as OrigamTab } from './OrigamTab.vue';
3
+ export { default as OrigamTabPanels } from './OrigamTabPanels.vue';
4
+ export { default as OrigamTabPanel } from './OrigamTabPanel.vue';
@@ -0,0 +1,4 @@
1
+ export { default as OrigamTabs } from "./OrigamTabs.vue";
2
+ export { default as OrigamTab } from "./OrigamTab.vue";
3
+ export { default as OrigamTabPanels } from "./OrigamTabPanels.vue";
4
+ export { default as OrigamTabPanel } from "./OrigamTabPanel.vue";
@@ -90,12 +90,14 @@
90
90
  :placeholder="placeholder"
91
91
  :readonly="isReadonly"
92
92
  :size="1"
93
- :type="type"
94
- :value="model"
93
+ :type="resolvedInputType"
94
+ :value="displayValue"
95
+ :aria-invalid="ariaInvalid"
95
96
  v-bind="{ ...fieldSlotProps, ...inputAttrs }"
96
97
  @blur="handleBlur"
97
98
  @focus="handleFocus"
98
99
  @input="handleInput"
100
+ @paste="handlePaste"
99
101
  >
100
102
  </div>
101
103
  </template>
@@ -181,7 +183,7 @@
181
183
  </template>
182
184
 
183
185
  <script setup>
184
- import { computed, nextTick, ref, toRef, StyleValue, useAttrs, useSlots } from "vue";
186
+ import { computed, nextTick, ref, toRef, StyleValue, useAttrs, useSlots, watch } from "vue";
185
187
  import { OrigamCounter, OrigamField, OrigamInput } from "../../components";
186
188
  import {
187
189
  useAdjacent,
@@ -189,6 +191,7 @@ import {
189
191
  useDefaults,
190
192
  useFocus,
191
193
  useLocale,
194
+ useMask,
192
195
  useProps,
193
196
  useStyle,
194
197
  useVModel
@@ -196,7 +199,7 @@ import {
196
199
  import { ACTIVE_TEXT_FIELD_TYPE, INPUT_TEXT_FIELD_TYPE } from "../../consts";
197
200
  import { vIntersect } from "../../directives";
198
201
  import { DENSITY, DIRECTION, MDI_ICONS, TEXT_FIELD_TYPE } from "../../enums";
199
- import { filterInputAttrs, forwardRefs } from "../../utils";
202
+ import { applyMask, filterInputAttrs, forwardRefs, resolveMaskConfig } from "../../utils";
200
203
  const _props = defineProps({
201
204
  autofocus: { type: Boolean, required: false },
202
205
  counter: { type: [Boolean, Number, String], required: false },
@@ -207,6 +210,7 @@ const _props = defineProps({
207
210
  role: { type: String, required: false },
208
211
  type: { type: null, required: false, default: TEXT_FIELD_TYPE.TEXT },
209
212
  modelModifiers: { type: [String, Boolean], required: false },
213
+ mask: { type: null, required: false },
210
214
  id: { type: String, required: false },
211
215
  class: { type: [String, Array, Object], required: false },
212
216
  style: { type: [String, Array, Object, Boolean, null], required: false, skipCheck: true },
@@ -297,7 +301,7 @@ const _props = defineProps({
297
301
  prependIcon: { type: null, required: false }
298
302
  });
299
303
  const props = useDefaults(_props);
300
- const emits = defineEmits(["click:control", "mousedown:control", "update:focused", "update:modelValue", "click:appendInner", "click:prependInner", "click:clear", "update:active", "click:append", "click:prepend"]);
304
+ const emits = defineEmits(["click:control", "mousedown:control", "valid", "complete", "update:focused", "update:modelValue", "click:appendInner", "click:prependInner", "click:clear", "update:active", "click:append", "click:prepend"]);
301
305
  defineSlots();
302
306
  const slots = useSlots();
303
307
  const attrs = useAttrs();
@@ -370,8 +374,57 @@ const handleClear = (e) => {
370
374
  emits("click:clear", e);
371
375
  });
372
376
  };
377
+ const maskConfig = computed(() => resolveMaskConfig(props.mask ?? null));
378
+ const hasMask = computed(() => maskConfig.value !== null);
379
+ const {
380
+ masked: maskedValue,
381
+ unmasked: unmaskedValue,
382
+ isValid: maskIsValid,
383
+ complete: maskComplete
384
+ } = useMask(model, toRef(props, "mask"));
385
+ const displayValue = computed(() => {
386
+ return hasMask.value ? maskedValue.value : model.value ?? "";
387
+ });
388
+ const ariaInvalid = computed(() => {
389
+ if (!hasMask.value) return void 0;
390
+ if (!isFocused.value && !model.value) return void 0;
391
+ return !maskIsValid.value;
392
+ });
393
+ const resolvedInputType = computed(() => {
394
+ if (!hasMask.value) return props.type;
395
+ const pattern = maskConfig.value?.pattern ?? "";
396
+ if (typeof props.mask === "string" && props.mask.startsWith("phone")) {
397
+ return "tel";
398
+ }
399
+ if (pattern && /^[#\s+()\-./]+$/.test(pattern)) {
400
+ return "tel";
401
+ }
402
+ return props.type;
403
+ });
404
+ watch(maskIsValid, (v) => {
405
+ if (hasMask.value) emits("valid", v);
406
+ }, { immediate: false });
407
+ watch(maskComplete, (c) => {
408
+ if (hasMask.value) emits("complete", { complete: c, unmasked: unmaskedValue.value });
409
+ }, { immediate: false });
373
410
  const handleInput = (e) => {
374
411
  const el = e.target;
412
+ if (hasMask.value) {
413
+ const cfg = maskConfig.value;
414
+ const tokens = cfg?.pattern ?? "";
415
+ const r = applyMask(el.value, tokens);
416
+ model.value = r.unmasked;
417
+ nextTick(() => {
418
+ if (el.value !== r.masked) el.value = r.masked;
419
+ const pos = r.masked.length;
420
+ try {
421
+ el.setSelectionRange(pos, pos);
422
+ } catch (err) {
423
+ void err;
424
+ }
425
+ });
426
+ return;
427
+ }
375
428
  model.value = el.value;
376
429
  if (typeof props.modelModifiers === "string" && INPUT_TEXT_FIELD_TYPE.includes(props.type)) {
377
430
  const caretPosition = [el.selectionStart, el.selectionEnd];
@@ -381,6 +434,17 @@ const handleInput = (e) => {
381
434
  });
382
435
  }
383
436
  };
437
+ const handlePaste = (e) => {
438
+ if (!hasMask.value) return;
439
+ const text = e.clipboardData?.getData("text") ?? "";
440
+ if (!text) return;
441
+ e.preventDefault();
442
+ const cfg = maskConfig.value;
443
+ if (!cfg) return;
444
+ const merged = (unmaskedValue.value ?? "") + text;
445
+ const r = applyMask(merged, cfg.pattern);
446
+ model.value = r.unmasked;
447
+ };
384
448
  const hasCounter = computed(() => {
385
449
  return slots.counter || props.counter !== false && props.counter != null;
386
450
  });
@@ -393,6 +457,12 @@ const enrichedRules = computed(() => {
393
457
  const limit = props.counter;
394
458
  base.push((v) => !v || v.length <= limit || t("origam.validation.max_length", [limit]));
395
459
  }
460
+ if (hasMask.value) {
461
+ base.push(() => {
462
+ if (!model.value) return true;
463
+ return maskIsValid.value || t("origam.validation.invalid_format", "Invalid format");
464
+ });
465
+ }
396
466
  return base;
397
467
  });
398
468
  const [rootAttrs, inputAttrs] = filterInputAttrs(attrs);