@code0-tech/pictor 0.18.3 → 1.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 (464) hide show
  1. package/dist/_virtual/__vite-optional-peer-dep_@emotion/is-prop-valid_framer-motion.js +6 -0
  2. package/dist/_virtual/rolldown_runtime.js +18 -0
  3. package/dist/assets/Alert.style.css +1 -0
  4. package/dist/assets/Aurora.style.css +1 -0
  5. package/dist/assets/Avatar.style.css +1 -0
  6. package/dist/assets/Badge.style.css +1 -0
  7. package/dist/assets/Breadcrumb.style.css +1 -0
  8. package/dist/assets/Button.style.css +1 -0
  9. package/dist/assets/ButtonGroup.style.css +1 -0
  10. package/dist/assets/Card.style.css +1 -0
  11. package/dist/assets/Chart.style.css +1 -0
  12. package/dist/assets/Col.style.css +1 -0
  13. package/dist/assets/ColorInput.style.css +1 -0
  14. package/dist/assets/Command.style.css +1 -0
  15. package/dist/assets/Container.style.css +1 -0
  16. package/dist/assets/ContextMenu.style.css +1 -0
  17. package/dist/assets/DataTable.style.css +1 -0
  18. package/dist/assets/DateInput.style.css +1 -0
  19. package/dist/assets/Dialog.style.css +1 -0
  20. package/dist/assets/Editor.styles.css +1 -0
  21. package/dist/assets/EditorInput.style.css +1 -0
  22. package/dist/assets/FileInput.style.css +1 -0
  23. package/dist/assets/FileTabs.style.css +1 -0
  24. package/dist/assets/FullScreen.style.css +1 -0
  25. package/dist/assets/Gantt.style.css +1 -0
  26. package/dist/assets/Icon.style.css +1 -0
  27. package/dist/assets/Input.style.css +1 -0
  28. package/dist/assets/InputWrapper.style.css +1 -0
  29. package/dist/assets/JsonView.style.css +1 -0
  30. package/dist/assets/Layout.style.css +1 -0
  31. package/dist/assets/Menu.style.css +1 -0
  32. package/dist/assets/Progress.style.css +1 -0
  33. package/dist/assets/Quote.style.css +1 -0
  34. package/dist/assets/Resizable.style.css +1 -0
  35. package/dist/assets/Row.style.css +1 -0
  36. package/dist/assets/ScrollArea.style.css +1 -0
  37. package/dist/assets/SegmentedControl.style.css +1 -0
  38. package/dist/assets/SelectInput.style.css +1 -0
  39. package/dist/assets/Tab.style.css +1 -0
  40. package/dist/assets/Text.style.css +1 -0
  41. package/dist/assets/Toast.style.css +1 -0
  42. package/dist/assets/Tooltip.style.css +1 -0
  43. package/dist/components/alert/Alert.js +34 -41
  44. package/dist/components/aurora/Aurora.js +27 -22
  45. package/dist/components/avatar/Avatar.js +57 -55
  46. package/dist/components/badge/Badge.js +58 -64
  47. package/dist/components/breadcrumb/Breadcrumb.js +16 -20
  48. package/dist/components/button/Button.js +24 -31
  49. package/dist/components/button-group/ButtonGroup.js +29 -31
  50. package/dist/components/card/Card.js +30 -44
  51. package/dist/components/card/CardSection.js +21 -29
  52. package/dist/components/chart/Chart.js +138 -153
  53. package/dist/components/chart/LineChart.js +75 -74
  54. package/dist/components/chart/index.js +3 -8
  55. package/dist/components/col/Col.js +19 -29
  56. package/dist/components/command/Command.js +101 -134
  57. package/dist/components/container/Container.js +19 -23
  58. package/dist/components/context-menu/ContextMenu.d.ts +1 -1
  59. package/dist/components/context-menu/ContextMenu.js +119 -125
  60. package/dist/components/data-table/DataTable.js +53 -63
  61. package/dist/components/data-table/DataTableColumn.js +18 -22
  62. package/dist/components/data-table/DataTableFilterInput.js +208 -205
  63. package/dist/components/data-table/DataTableFilterSuggestionMenu.js +59 -48
  64. package/dist/components/data-table/DataTableHeader.js +34 -38
  65. package/dist/components/data-table/DataTablePagination.js +62 -74
  66. package/dist/components/data-table/index.js +7 -22
  67. package/dist/components/dialog/Dialog.js +107 -102
  68. package/dist/components/editor/Editor.js +352 -322
  69. package/dist/components/file-tabs/FileTabs.js +78 -73
  70. package/dist/components/file-tabs/FileTabs.service.js +85 -87
  71. package/dist/components/file-tabs/FileTabs.view.js +0 -1
  72. package/dist/components/file-tabs/index.js +3 -9
  73. package/dist/components/flex/Flex.js +19 -23
  74. package/dist/components/form/CheckboxInput.js +73 -76
  75. package/dist/components/form/ColorInput.js +378 -353
  76. package/dist/components/form/DateInput.js +315 -265
  77. package/dist/components/form/EditorInput.js +597 -579
  78. package/dist/components/form/EmailInput.js +30 -23
  79. package/dist/components/form/FileInput.js +93 -123
  80. package/dist/components/form/Input.js +64 -57
  81. package/dist/components/form/Input.utils.js +25 -37
  82. package/dist/components/form/InputDescription.js +11 -11
  83. package/dist/components/form/InputLabel.js +18 -22
  84. package/dist/components/form/InputMessage.js +17 -17
  85. package/dist/components/form/InputWrapper.js +56 -65
  86. package/dist/components/form/NumberInput.js +41 -20
  87. package/dist/components/form/PasswordInput.js +71 -54
  88. package/dist/components/form/PinInput.js +50 -65
  89. package/dist/components/form/RadioGroup.js +42 -50
  90. package/dist/components/form/RadioInput.js +31 -29
  91. package/dist/components/form/SelectInput.js +69 -92
  92. package/dist/components/form/SwitchInput.js +17 -18
  93. package/dist/components/form/TagInput.js +108 -122
  94. package/dist/components/form/TextAreaInput.js +24 -21
  95. package/dist/components/form/TextInput.js +30 -22
  96. package/dist/components/form/index.js +22 -87
  97. package/dist/components/form/useForm.js +87 -88
  98. package/dist/components/fullscreen/FullScreen.js +28 -27
  99. package/dist/components/gantt/Gantt.js +100 -98
  100. package/dist/components/gantt/GanttGroup.js +210 -194
  101. package/dist/components/gantt/GanttHeader.js +79 -81
  102. package/dist/components/gantt/GanttItem.js +19 -22
  103. package/dist/components/icon/Icon.d.ts +6 -4
  104. package/dist/components/icon/Icon.js +53 -42
  105. package/dist/components/icon/codezero/codezero.js +10 -0
  106. package/dist/components/icon/codezero/gls.js +9 -0
  107. package/dist/components/icon/codezero/index.js +17 -13
  108. package/dist/components/json-view/JsonView.js +120 -109
  109. package/dist/components/layout/Layout.js +101 -78
  110. package/dist/components/menu/Menu.js +135 -141
  111. package/dist/components/progress/ProgressCircle.js +60 -48
  112. package/dist/components/progress/ProgressLinear.js +39 -42
  113. package/dist/components/quote/Quote.js +52 -43
  114. package/dist/components/resizable/Resizable.js +36 -33
  115. package/dist/components/row/Row.js +19 -23
  116. package/dist/components/scroll-area/ScrollArea.js +66 -76
  117. package/dist/components/segmented-control/SegmentedControl.d.ts +2 -2
  118. package/dist/components/segmented-control/SegmentedControl.js +46 -26
  119. package/dist/components/spacing/Spacing.js +16 -23
  120. package/dist/components/tab/Tab.js +73 -40
  121. package/dist/components/text/Text.js +19 -25
  122. package/dist/components/toast/Toast.d.ts +1 -1
  123. package/dist/components/toast/Toast.js +104 -83
  124. package/dist/components/tooltip/Tooltip.js +66 -60
  125. package/dist/index.js +76 -261
  126. package/dist/node_modules/@lezer/common/dist/index.js +778 -143
  127. package/dist/node_modules/@lezer/highlight/dist/index.js +305 -536
  128. package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/PopChild.js +55 -55
  129. package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/PresenceChild.js +49 -32
  130. package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/index.js +57 -46
  131. package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/use-presence.js +17 -16
  132. package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/utils.js +8 -11
  133. package/dist/node_modules/framer-motion/dist/es/context/LayoutGroupContext.js +4 -5
  134. package/dist/node_modules/framer-motion/dist/es/context/LazyContext.js +4 -5
  135. package/dist/node_modules/framer-motion/dist/es/context/MotionConfigContext.js +7 -8
  136. package/dist/node_modules/framer-motion/dist/es/context/MotionContext/create.js +13 -11
  137. package/dist/node_modules/framer-motion/dist/es/context/MotionContext/index.js +4 -5
  138. package/dist/node_modules/framer-motion/dist/es/context/MotionContext/utils.js +12 -14
  139. package/dist/node_modules/framer-motion/dist/es/context/PresenceContext.js +4 -5
  140. package/dist/node_modules/framer-motion/dist/es/context/SwitchLayoutGroupContext.js +4 -5
  141. package/dist/node_modules/framer-motion/dist/es/events/add-pointer-event.js +5 -7
  142. package/dist/node_modules/framer-motion/dist/es/events/event-info.js +8 -13
  143. package/dist/node_modules/framer-motion/dist/es/gestures/drag/VisualElementDragControls.js +252 -281
  144. package/dist/node_modules/framer-motion/dist/es/gestures/drag/index.js +19 -21
  145. package/dist/node_modules/framer-motion/dist/es/gestures/drag/utils/constraints.js +57 -67
  146. package/dist/node_modules/framer-motion/dist/es/gestures/focus.js +24 -27
  147. package/dist/node_modules/framer-motion/dist/es/gestures/hover.js +16 -19
  148. package/dist/node_modules/framer-motion/dist/es/gestures/pan/PanSession.js +130 -124
  149. package/dist/node_modules/framer-motion/dist/es/gestures/pan/index.js +39 -42
  150. package/dist/node_modules/framer-motion/dist/es/gestures/press.js +22 -27
  151. package/dist/node_modules/framer-motion/dist/es/motion/features/animation/exit.js +36 -44
  152. package/dist/node_modules/framer-motion/dist/es/motion/features/animation/index.js +22 -32
  153. package/dist/node_modules/framer-motion/dist/es/motion/features/animations.js +6 -12
  154. package/dist/node_modules/framer-motion/dist/es/motion/features/definitions.js +47 -37
  155. package/dist/node_modules/framer-motion/dist/es/motion/features/drag.js +12 -16
  156. package/dist/node_modules/framer-motion/dist/es/motion/features/gestures.js +10 -20
  157. package/dist/node_modules/framer-motion/dist/es/motion/features/layout/MeasureLayout.js +58 -59
  158. package/dist/node_modules/framer-motion/dist/es/motion/features/layout.js +7 -11
  159. package/dist/node_modules/framer-motion/dist/es/motion/features/load-features.js +10 -13
  160. package/dist/node_modules/framer-motion/dist/es/motion/features/viewport/index.js +42 -43
  161. package/dist/node_modules/framer-motion/dist/es/motion/features/viewport/observers.js +19 -18
  162. package/dist/node_modules/framer-motion/dist/es/motion/index.js +64 -58
  163. package/dist/node_modules/framer-motion/dist/es/motion/utils/symbol.js +2 -4
  164. package/dist/node_modules/framer-motion/dist/es/motion/utils/use-motion-ref.js +18 -20
  165. package/dist/node_modules/framer-motion/dist/es/motion/utils/use-visual-element.js +53 -62
  166. package/dist/node_modules/framer-motion/dist/es/motion/utils/use-visual-state.js +45 -49
  167. package/dist/node_modules/framer-motion/dist/es/motion/utils/valid-prop.js +4 -38
  168. package/dist/node_modules/framer-motion/dist/es/render/components/create-proxy.js +7 -17
  169. package/dist/node_modules/framer-motion/dist/es/render/components/m/proxy.js +3 -0
  170. package/dist/node_modules/framer-motion/dist/es/render/components/motion/feature-bundle.js +10 -12
  171. package/dist/node_modules/framer-motion/dist/es/render/components/motion/proxy.js +5 -7
  172. package/dist/node_modules/framer-motion/dist/es/render/dom/create-visual-element.js +6 -10
  173. package/dist/node_modules/framer-motion/dist/es/render/dom/use-render.js +18 -15
  174. package/dist/node_modules/framer-motion/dist/es/render/dom/utils/filter-props.js +14 -18
  175. package/dist/node_modules/framer-motion/dist/es/render/dom/utils/is-svg-component.js +4 -23
  176. package/dist/node_modules/framer-motion/dist/es/render/html/use-html-visual-state.js +8 -9
  177. package/dist/node_modules/framer-motion/dist/es/render/html/use-props.js +20 -23
  178. package/dist/node_modules/framer-motion/dist/es/render/html/utils/create-render-state.js +6 -8
  179. package/dist/node_modules/framer-motion/dist/es/render/svg/lowercase-elements.js +27 -29
  180. package/dist/node_modules/framer-motion/dist/es/render/svg/use-props.js +23 -21
  181. package/dist/node_modules/framer-motion/dist/es/render/svg/use-svg-visual-state.js +8 -9
  182. package/dist/node_modules/framer-motion/dist/es/render/svg/utils/create-render-state.js +5 -7
  183. package/dist/node_modules/framer-motion/dist/es/utils/distance.js +5 -8
  184. package/dist/node_modules/framer-motion/dist/es/utils/get-context-window.js +2 -4
  185. package/dist/node_modules/framer-motion/dist/es/utils/is-browser.js +2 -4
  186. package/dist/node_modules/framer-motion/dist/es/utils/is-ref-object.js +3 -5
  187. package/dist/node_modules/framer-motion/dist/es/utils/reduced-motion/use-reduced-motion.js +11 -0
  188. package/dist/node_modules/framer-motion/dist/es/utils/use-composed-ref.js +20 -25
  189. package/dist/node_modules/framer-motion/dist/es/utils/use-constant.js +6 -7
  190. package/dist/node_modules/framer-motion/dist/es/utils/use-isomorphic-effect.js +5 -6
  191. package/dist/node_modules/motion/dist/es/react.js +196 -0
  192. package/dist/node_modules/motion-dom/dist/es/animation/AsyncMotionValueAnimation.js +104 -111
  193. package/dist/node_modules/motion-dom/dist/es/animation/JSAnimation.js +126 -143
  194. package/dist/node_modules/motion-dom/dist/es/animation/NativeAnimation.js +81 -105
  195. package/dist/node_modules/motion-dom/dist/es/animation/NativeAnimationExtended.js +25 -37
  196. package/dist/node_modules/motion-dom/dist/es/animation/animate/single-value.js +7 -9
  197. package/dist/node_modules/motion-dom/dist/es/animation/drivers/frame.js +10 -16
  198. package/dist/node_modules/motion-dom/dist/es/animation/generators/inertia.js +29 -36
  199. package/dist/node_modules/motion-dom/dist/es/animation/generators/keyframes.js +18 -28
  200. package/dist/node_modules/motion-dom/dist/es/animation/generators/spring.js +156 -170
  201. package/dist/node_modules/motion-dom/dist/es/animation/generators/utils/calc-duration.js +6 -12
  202. package/dist/node_modules/motion-dom/dist/es/animation/generators/utils/create-generator-easing.js +13 -12
  203. package/dist/node_modules/motion-dom/dist/es/animation/generators/utils/is-generator.js +3 -5
  204. package/dist/node_modules/motion-dom/dist/es/animation/generators/utils/velocity.js +6 -8
  205. package/dist/node_modules/motion-dom/dist/es/animation/interfaces/motion-value.js +42 -45
  206. package/dist/node_modules/motion-dom/dist/es/animation/interfaces/visual-element-target.js +52 -57
  207. package/dist/node_modules/motion-dom/dist/es/animation/interfaces/visual-element-variant.js +22 -27
  208. package/dist/node_modules/motion-dom/dist/es/animation/interfaces/visual-element.js +18 -21
  209. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/DOMKeyframesResolver.js +58 -67
  210. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/KeyframesResolver.js +61 -70
  211. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/get-final.js +5 -7
  212. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/offsets/default.js +5 -7
  213. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/offsets/fill.js +9 -11
  214. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/offsets/time.js +3 -5
  215. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/utils/fill-wildcards.js +3 -6
  216. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/utils/is-none.js +4 -6
  217. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/utils/make-none-animatable.js +15 -15
  218. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/utils/unit-conversion.js +32 -35
  219. package/dist/node_modules/motion-dom/dist/es/animation/optimized-appear/data-id.js +3 -6
  220. package/dist/node_modules/motion-dom/dist/es/animation/optimized-appear/get-appear-id.js +4 -6
  221. package/dist/node_modules/motion-dom/dist/es/animation/utils/WithPromise.js +19 -26
  222. package/dist/node_modules/motion-dom/dist/es/animation/utils/calc-child-stagger.js +4 -6
  223. package/dist/node_modules/motion-dom/dist/es/animation/utils/can-animate.js +14 -21
  224. package/dist/node_modules/motion-dom/dist/es/animation/utils/css-variables-conversion.js +21 -29
  225. package/dist/node_modules/motion-dom/dist/es/animation/utils/default-transitions.js +25 -22
  226. package/dist/node_modules/motion-dom/dist/es/animation/utils/get-value-transition.js +5 -7
  227. package/dist/node_modules/motion-dom/dist/es/animation/utils/is-animatable.js +3 -7
  228. package/dist/node_modules/motion-dom/dist/es/animation/utils/is-css-variable.js +4 -8
  229. package/dist/node_modules/motion-dom/dist/es/animation/utils/is-transition-defined.js +15 -19
  230. package/dist/node_modules/motion-dom/dist/es/animation/utils/make-animation-instant.js +3 -5
  231. package/dist/node_modules/motion-dom/dist/es/animation/utils/replace-transition-type.js +12 -14
  232. package/dist/node_modules/motion-dom/dist/es/animation/utils/resolve-transition.js +10 -9
  233. package/dist/node_modules/motion-dom/dist/es/animation/waapi/easing/cubic-bezier.js +2 -4
  234. package/dist/node_modules/motion-dom/dist/es/animation/waapi/easing/map-easing.js +8 -11
  235. package/dist/node_modules/motion-dom/dist/es/animation/waapi/easing/supported.js +32 -14
  236. package/dist/node_modules/motion-dom/dist/es/animation/waapi/start-waapi-animation.js +16 -20
  237. package/dist/node_modules/motion-dom/dist/es/animation/waapi/supports/waapi.js +21 -32
  238. package/dist/node_modules/motion-dom/dist/es/animation/waapi/utils/accelerated-values.js +7 -11
  239. package/dist/node_modules/motion-dom/dist/es/animation/waapi/utils/apply-generator.js +5 -7
  240. package/dist/node_modules/motion-dom/dist/es/animation/waapi/utils/is-browser-color.js +5 -9
  241. package/dist/node_modules/motion-dom/dist/es/animation/waapi/utils/linear.js +5 -9
  242. package/dist/node_modules/motion-dom/dist/es/animation/waapi/utils/unsupported-easing.js +12 -14
  243. package/dist/node_modules/motion-dom/dist/es/events/add-dom-event.js +3 -5
  244. package/dist/node_modules/motion-dom/dist/es/frameloop/batcher.js +27 -26
  245. package/dist/node_modules/motion-dom/dist/es/frameloop/frame.js +4 -9
  246. package/dist/node_modules/motion-dom/dist/es/frameloop/microtask.js +3 -5
  247. package/dist/node_modules/motion-dom/dist/es/frameloop/order.js +10 -20
  248. package/dist/node_modules/motion-dom/dist/es/frameloop/render-step.js +29 -42
  249. package/dist/node_modules/motion-dom/dist/es/frameloop/sync-time.js +11 -13
  250. package/dist/node_modules/motion-dom/dist/es/gestures/drag/state/is-active.js +6 -9
  251. package/dist/node_modules/motion-dom/dist/es/gestures/drag/state/set-active.js +8 -10
  252. package/dist/node_modules/motion-dom/dist/es/gestures/hover.js +32 -36
  253. package/dist/node_modules/motion-dom/dist/es/gestures/press/index.js +32 -32
  254. package/dist/node_modules/motion-dom/dist/es/gestures/press/utils/is-keyboard-accessible.js +16 -15
  255. package/dist/node_modules/motion-dom/dist/es/gestures/press/utils/keyboard.js +23 -24
  256. package/dist/node_modules/motion-dom/dist/es/gestures/press/utils/state.js +2 -4
  257. package/dist/node_modules/motion-dom/dist/es/gestures/utils/is-node-or-child.js +2 -4
  258. package/dist/node_modules/motion-dom/dist/es/gestures/utils/is-primary-pointer.js +2 -4
  259. package/dist/node_modules/motion-dom/dist/es/gestures/utils/setup.js +13 -11
  260. package/dist/node_modules/motion-dom/dist/es/projection/animation/mix-values.js +20 -29
  261. package/dist/node_modules/motion-dom/dist/es/projection/geometry/conversion.js +34 -22
  262. package/dist/node_modules/motion-dom/dist/es/projection/geometry/copy.js +7 -11
  263. package/dist/node_modules/motion-dom/dist/es/projection/geometry/delta-apply.js +41 -53
  264. package/dist/node_modules/motion-dom/dist/es/projection/geometry/delta-calc.js +28 -38
  265. package/dist/node_modules/motion-dom/dist/es/projection/geometry/delta-remove.js +23 -21
  266. package/dist/node_modules/motion-dom/dist/es/projection/geometry/models.js +15 -17
  267. package/dist/node_modules/motion-dom/dist/es/projection/geometry/utils.js +18 -26
  268. package/dist/node_modules/motion-dom/dist/es/projection/node/DocumentProjectionNode.js +10 -12
  269. package/dist/node_modules/motion-dom/dist/es/projection/node/HTMLProjectionNode.js +19 -24
  270. package/dist/node_modules/motion-dom/dist/es/projection/node/create-projection-node.js +554 -592
  271. package/dist/node_modules/motion-dom/dist/es/projection/node/state.js +4 -14
  272. package/dist/node_modules/motion-dom/dist/es/projection/shared/stack.js +48 -52
  273. package/dist/node_modules/motion-dom/dist/es/projection/styles/scale-border-radius.js +10 -20
  274. package/dist/node_modules/motion-dom/dist/es/projection/styles/scale-box-shadow.js +11 -16
  275. package/dist/node_modules/motion-dom/dist/es/projection/styles/scale-correction.js +14 -20
  276. package/dist/node_modules/motion-dom/dist/es/projection/styles/transform.js +9 -12
  277. package/dist/node_modules/motion-dom/dist/es/projection/utils/compare-by-depth.js +2 -4
  278. package/dist/node_modules/motion-dom/dist/es/projection/utils/each-axis.js +3 -5
  279. package/dist/node_modules/motion-dom/dist/es/projection/utils/flat-tree.js +16 -18
  280. package/dist/node_modules/motion-dom/dist/es/projection/utils/has-transform.js +11 -15
  281. package/dist/node_modules/motion-dom/dist/es/projection/utils/measure.js +8 -11
  282. package/dist/node_modules/motion-dom/dist/es/render/Feature.js +6 -9
  283. package/dist/node_modules/motion-dom/dist/es/render/VisualElement.js +198 -260
  284. package/dist/node_modules/motion-dom/dist/es/render/dom/DOMVisualElement.js +25 -27
  285. package/dist/node_modules/motion-dom/dist/es/render/dom/is-css-var.js +2 -4
  286. package/dist/node_modules/motion-dom/dist/es/render/dom/parse-transform.js +49 -60
  287. package/dist/node_modules/motion-dom/dist/es/render/dom/style-set.js +4 -6
  288. package/dist/node_modules/motion-dom/dist/es/render/dom/utils/camel-to-dash.js +3 -5
  289. package/dist/node_modules/motion-dom/dist/es/render/html/HTMLVisualElement.js +35 -35
  290. package/dist/node_modules/motion-dom/dist/es/render/html/utils/build-styles.js +25 -28
  291. package/dist/node_modules/motion-dom/dist/es/render/html/utils/build-transform.js +33 -37
  292. package/dist/node_modules/motion-dom/dist/es/render/html/utils/render.js +5 -11
  293. package/dist/node_modules/motion-dom/dist/es/render/html/utils/scrape-motion-values.js +8 -12
  294. package/dist/node_modules/motion-dom/dist/es/render/store.js +2 -4
  295. package/dist/node_modules/motion-dom/dist/es/render/svg/SVGVisualElement.js +37 -39
  296. package/dist/node_modules/motion-dom/dist/es/render/svg/utils/build-attrs.js +18 -30
  297. package/dist/node_modules/motion-dom/dist/es/render/svg/utils/camel-case-attrs.js +25 -27
  298. package/dist/node_modules/motion-dom/dist/es/render/svg/utils/is-svg-tag.js +2 -4
  299. package/dist/node_modules/motion-dom/dist/es/render/svg/utils/path.js +11 -13
  300. package/dist/node_modules/motion-dom/dist/es/render/svg/utils/render.js +6 -10
  301. package/dist/node_modules/motion-dom/dist/es/render/svg/utils/scrape-motion-values.js +11 -14
  302. package/dist/node_modules/motion-dom/dist/es/render/utils/animation-state.js +128 -138
  303. package/dist/node_modules/motion-dom/dist/es/render/utils/get-variant-context.js +16 -19
  304. package/dist/node_modules/motion-dom/dist/es/render/utils/is-animation-controls.js +3 -5
  305. package/dist/node_modules/motion-dom/dist/es/render/utils/is-controlling-variants.js +8 -11
  306. package/dist/node_modules/motion-dom/dist/es/render/utils/is-forced-motion-value.js +5 -8
  307. package/dist/node_modules/motion-dom/dist/es/render/utils/is-keyframes-target.js +2 -4
  308. package/dist/node_modules/motion-dom/dist/es/render/utils/is-variant-label.js +3 -5
  309. package/dist/node_modules/motion-dom/dist/es/render/utils/keys-position.js +10 -12
  310. package/dist/node_modules/motion-dom/dist/es/render/utils/keys-transform.js +20 -23
  311. package/dist/node_modules/motion-dom/dist/es/render/utils/motion-values.js +18 -24
  312. package/dist/node_modules/motion-dom/dist/es/render/utils/reduced-motion/index.js +8 -14
  313. package/dist/node_modules/motion-dom/dist/es/render/utils/reduced-motion/state.js +2 -5
  314. package/dist/node_modules/motion-dom/dist/es/render/utils/resolve-dynamic-variants.js +5 -7
  315. package/dist/node_modules/motion-dom/dist/es/render/utils/resolve-variants.js +16 -18
  316. package/dist/node_modules/motion-dom/dist/es/render/utils/setters.js +14 -18
  317. package/dist/node_modules/motion-dom/dist/es/render/utils/shallow-compare.js +7 -13
  318. package/dist/node_modules/motion-dom/dist/es/render/utils/variant-props.js +10 -13
  319. package/dist/node_modules/motion-dom/dist/es/resize/handle-element.js +31 -35
  320. package/dist/node_modules/motion-dom/dist/es/resize/handle-window.js +18 -21
  321. package/dist/node_modules/motion-dom/dist/es/resize/index.js +5 -7
  322. package/dist/node_modules/motion-dom/dist/es/stats/buffer.js +5 -0
  323. package/dist/node_modules/motion-dom/dist/es/utils/border-radius.js +7 -0
  324. package/dist/node_modules/motion-dom/dist/es/utils/delay.js +9 -11
  325. package/dist/node_modules/motion-dom/dist/es/utils/interpolate.js +29 -40
  326. package/dist/node_modules/motion-dom/dist/es/utils/is-html-element.js +4 -6
  327. package/dist/node_modules/motion-dom/dist/es/utils/is-svg-element.js +4 -6
  328. package/dist/node_modules/motion-dom/dist/es/utils/is-svg-svg-element.js +4 -6
  329. package/dist/node_modules/motion-dom/dist/es/utils/mix/color.js +26 -27
  330. package/dist/node_modules/motion-dom/dist/es/utils/mix/complex.js +44 -45
  331. package/dist/node_modules/motion-dom/dist/es/utils/mix/immediate.js +3 -5
  332. package/dist/node_modules/motion-dom/dist/es/utils/mix/index.js +5 -7
  333. package/dist/node_modules/motion-dom/dist/es/utils/mix/number.js +2 -4
  334. package/dist/node_modules/motion-dom/dist/es/utils/mix/visibility.js +4 -7
  335. package/dist/node_modules/motion-dom/dist/es/utils/resolve-elements.js +11 -14
  336. package/dist/node_modules/motion-dom/dist/es/utils/supports/flags.js +2 -4
  337. package/dist/node_modules/motion-dom/dist/es/utils/supports/linear-easing.js +9 -11
  338. package/dist/node_modules/motion-dom/dist/es/utils/supports/memo.js +6 -8
  339. package/dist/node_modules/motion-dom/dist/es/utils/supports/scroll-timeline.js +3 -5
  340. package/dist/node_modules/motion-dom/dist/es/value/index.js +89 -211
  341. package/dist/node_modules/motion-dom/dist/es/value/types/auto.js +4 -6
  342. package/dist/node_modules/motion-dom/dist/es/value/types/color/hex.js +15 -17
  343. package/dist/node_modules/motion-dom/dist/es/value/types/color/hsla-to-rgba.js +17 -20
  344. package/dist/node_modules/motion-dom/dist/es/value/types/color/hsla.js +9 -11
  345. package/dist/node_modules/motion-dom/dist/es/value/types/color/index.js +12 -14
  346. package/dist/node_modules/motion-dom/dist/es/value/types/color/rgba.js +12 -15
  347. package/dist/node_modules/motion-dom/dist/es/value/types/color/utils.js +13 -17
  348. package/dist/node_modules/motion-dom/dist/es/value/types/complex/filter.js +22 -22
  349. package/dist/node_modules/motion-dom/dist/es/value/types/complex/index.js +43 -44
  350. package/dist/node_modules/motion-dom/dist/es/value/types/complex/mask.js +11 -10
  351. package/dist/node_modules/motion-dom/dist/es/value/types/dimensions.js +14 -9
  352. package/dist/node_modules/motion-dom/dist/es/value/types/int.js +5 -7
  353. package/dist/node_modules/motion-dom/dist/es/value/types/maps/defaults.js +22 -27
  354. package/dist/node_modules/motion-dom/dist/es/value/types/maps/number.js +61 -69
  355. package/dist/node_modules/motion-dom/dist/es/value/types/maps/transform.js +29 -36
  356. package/dist/node_modules/motion-dom/dist/es/value/types/numbers/index.js +12 -16
  357. package/dist/node_modules/motion-dom/dist/es/value/types/numbers/units.js +10 -17
  358. package/dist/node_modules/motion-dom/dist/es/value/types/test.js +2 -4
  359. package/dist/node_modules/motion-dom/dist/es/value/types/utils/animatable-none.js +9 -11
  360. package/dist/node_modules/motion-dom/dist/es/value/types/utils/color-regex.js +2 -4
  361. package/dist/node_modules/motion-dom/dist/es/value/types/utils/find.js +10 -8
  362. package/dist/node_modules/motion-dom/dist/es/value/types/utils/float-regex.js +2 -4
  363. package/dist/node_modules/motion-dom/dist/es/value/types/utils/get-as-type.js +2 -4
  364. package/dist/node_modules/motion-dom/dist/es/value/types/utils/is-nullish.js +3 -5
  365. package/dist/node_modules/motion-dom/dist/es/value/types/utils/sanitize.js +2 -4
  366. package/dist/node_modules/motion-dom/dist/es/value/types/utils/single-color-regex.js +2 -4
  367. package/dist/node_modules/motion-dom/dist/es/value/utils/is-motion-value.js +2 -4
  368. package/dist/node_modules/motion-dom/dist/es/value/utils/resolve-motion-value.js +4 -6
  369. package/dist/node_modules/motion-dom/dist/es/value/will-change/add-will-change.js +10 -13
  370. package/dist/node_modules/motion-dom/dist/es/value/will-change/is.js +4 -6
  371. package/dist/node_modules/motion-utils/dist/es/array.js +6 -9
  372. package/dist/node_modules/motion-utils/dist/es/clamp.js +2 -4
  373. package/dist/node_modules/motion-utils/dist/es/easing/anticipate.js +3 -5
  374. package/dist/node_modules/motion-utils/dist/es/easing/back.js +5 -9
  375. package/dist/node_modules/motion-utils/dist/es/easing/circ.js +4 -8
  376. package/dist/node_modules/motion-utils/dist/es/easing/cubic-bezier.js +14 -17
  377. package/dist/node_modules/motion-utils/dist/es/easing/ease.js +3 -7
  378. package/dist/node_modules/motion-utils/dist/es/easing/modifiers/mirror.js +2 -4
  379. package/dist/node_modules/motion-utils/dist/es/easing/modifiers/reverse.js +2 -4
  380. package/dist/node_modules/motion-utils/dist/es/easing/utils/is-bezier-definition.js +2 -4
  381. package/dist/node_modules/motion-utils/dist/es/easing/utils/is-easing-array.js +2 -4
  382. package/dist/node_modules/motion-utils/dist/es/easing/utils/map.js +28 -31
  383. package/dist/node_modules/motion-utils/dist/es/errors.js +7 -13
  384. package/dist/node_modules/motion-utils/dist/es/format-error-message.js +3 -5
  385. package/dist/node_modules/motion-utils/dist/es/global-config.js +2 -4
  386. package/dist/node_modules/motion-utils/dist/es/is-numerical-string.js +2 -4
  387. package/dist/node_modules/motion-utils/dist/es/is-object.js +2 -4
  388. package/dist/node_modules/motion-utils/dist/es/is-zero-value-string.js +2 -4
  389. package/dist/node_modules/motion-utils/dist/es/memo.js +5 -7
  390. package/dist/node_modules/motion-utils/dist/es/noop.js +2 -4
  391. package/dist/node_modules/motion-utils/dist/es/pipe.js +2 -4
  392. package/dist/node_modules/motion-utils/dist/es/progress.js +4 -6
  393. package/dist/node_modules/motion-utils/dist/es/subscription-manager.js +23 -28
  394. package/dist/node_modules/motion-utils/dist/es/time-conversion.js +2 -5
  395. package/dist/node_modules/motion-utils/dist/es/velocity-per-second.js +2 -4
  396. package/dist/node_modules/motion-utils/dist/es/warn-once.js +5 -7
  397. package/dist/node_modules/prettier/plugins/babel.js +9582 -7023
  398. package/dist/node_modules/prettier/plugins/estree.js +6997 -4377
  399. package/dist/node_modules/prettier/standalone.js +3444 -2415
  400. package/dist/node_modules/react/cjs/react-compiler-runtime.development.js +21 -21
  401. package/dist/node_modules/react/cjs/react-compiler-runtime.production.js +18 -14
  402. package/dist/node_modules/react/compiler-runtime.js +8 -10
  403. package/dist/utils/arrayService.js +0 -1
  404. package/dist/utils/color.js +46 -41
  405. package/dist/utils/component.js +60 -129
  406. package/dist/utils/contextStore.js +48 -58
  407. package/dist/utils/index.d.ts +1 -0
  408. package/dist/utils/index.js +7 -18
  409. package/dist/utils/motion.d.ts +55 -0
  410. package/dist/utils/motion.js +87 -0
  411. package/dist/utils/reactiveArrayService.js +80 -76
  412. package/dist/utils/size.js +14 -26
  413. package/dist/utils/utils.js +0 -1
  414. package/dist/utils/view.js +27 -24
  415. package/dist/vite-env.d.js +0 -1
  416. package/package.json +30 -25
  417. package/dist/_virtual/compiler-runtime.js +0 -5
  418. package/dist/_virtual/compiler-runtime2.js +0 -4
  419. package/dist/_virtual/react-compiler-runtime.development.js +0 -4
  420. package/dist/_virtual/react-compiler-runtime.production.js +0 -4
  421. package/dist/assets/components/alert/Alert.style.css +0 -1
  422. package/dist/assets/components/aurora/Aurora.style.css +0 -1
  423. package/dist/assets/components/avatar/Avatar.style.css +0 -1
  424. package/dist/assets/components/badge/Badge.style.css +0 -1
  425. package/dist/assets/components/breadcrumb/Breadcrumb.style.css +0 -1
  426. package/dist/assets/components/button/Button.style.css +0 -1
  427. package/dist/assets/components/button-group/ButtonGroup.style.css +0 -1
  428. package/dist/assets/components/card/Card.style.css +0 -1
  429. package/dist/assets/components/chart/Chart.style.css +0 -1
  430. package/dist/assets/components/col/Col.style.css +0 -1
  431. package/dist/assets/components/command/Command.style.css +0 -1
  432. package/dist/assets/components/container/Container.style.css +0 -1
  433. package/dist/assets/components/context-menu/ContextMenu.style.css +0 -1
  434. package/dist/assets/components/data-table/DataTable.style.css +0 -1
  435. package/dist/assets/components/dialog/Dialog.style.css +0 -1
  436. package/dist/assets/components/editor/Editor.styles.css +0 -1
  437. package/dist/assets/components/file-tabs/FileTabs.style.css +0 -1
  438. package/dist/assets/components/form/ColorInput.style.css +0 -1
  439. package/dist/assets/components/form/DateInput.style.css +0 -1
  440. package/dist/assets/components/form/EditorInput.style.css +0 -1
  441. package/dist/assets/components/form/FileInput.style.css +0 -1
  442. package/dist/assets/components/form/Input.style.css +0 -1
  443. package/dist/assets/components/form/InputWrapper.style.css +0 -1
  444. package/dist/assets/components/form/SelectInput.style.css +0 -1
  445. package/dist/assets/components/fullscreen/FullScreen.style.css +0 -1
  446. package/dist/assets/components/gantt/Gantt.style.css +0 -1
  447. package/dist/assets/components/icon/Icon.style.css +0 -1
  448. package/dist/assets/components/json-view/JsonView.style.css +0 -1
  449. package/dist/assets/components/layout/Layout.style.css +0 -1
  450. package/dist/assets/components/menu/Menu.style.css +0 -1
  451. package/dist/assets/components/progress/Progress.style.css +0 -1
  452. package/dist/assets/components/quote/Quote.style.css +0 -1
  453. package/dist/assets/components/resizable/Resizable.style.css +0 -1
  454. package/dist/assets/components/row/Row.style.css +0 -1
  455. package/dist/assets/components/scroll-area/ScrollArea.style.css +0 -1
  456. package/dist/assets/components/segmented-control/SegmentedControl.style.css +0 -1
  457. package/dist/assets/components/tab/Tab.style.css +0 -1
  458. package/dist/assets/components/text/Text.style.css +0 -1
  459. package/dist/assets/components/toast/Toast.style.css +0 -1
  460. package/dist/assets/components/tooltip/Tooltip.style.css +0 -1
  461. package/dist/components/icon/codezero/codezero.svg.js +0 -5
  462. package/dist/components/icon/codezero/gls.svg.js +0 -5
  463. /package/dist/assets/{components/flex/Flex.style.css → Flex.style.css} +0 -0
  464. /package/dist/assets/{components/spacing/Spacing.style.css → Spacing.style.css} +0 -0
@@ -1,543 +1,312 @@
1
- import { NodeProp as q } from "../../common/dist/index.js";
2
- let A = 0;
3
- class l {
4
- /**
5
- @internal
6
- */
7
- constructor(t, a, i, n) {
8
- this.name = t, this.set = a, this.base = i, this.modified = n, this.id = A++;
9
- }
10
- toString() {
11
- let { name: t } = this;
12
- for (let a of this.modified)
13
- a.name && (t = `${a.name}(${t})`);
14
- return t;
15
- }
16
- static define(t, a) {
17
- let i = typeof t == "string" ? t : "?";
18
- if (t instanceof l && (a = t), a?.base)
19
- throw new Error("Can not derive from a modified tag");
20
- let n = new l(i, [], null, []);
21
- if (n.set.push(n), a)
22
- for (let r of a.set)
23
- n.set.push(r);
24
- return n;
25
- }
26
- /**
27
- Define a tag _modifier_, which is a function that, given a tag,
28
- will return a tag that is a subtag of the original. Applying the
29
- same modifier to a twice tag will return the same value (`m1(t1)
30
- == m1(t1)`) and applying multiple modifiers will, regardless or
31
- order, produce the same tag (`m1(m2(t1)) == m2(m1(t1))`).
32
-
33
- When multiple modifiers are applied to a given base tag, each
34
- smaller set of modifiers is registered as a parent, so that for
35
- example `m1(m2(m3(t1)))` is a subtype of `m1(m2(t1))`,
36
- `m1(m3(t1)`, and so on.
37
- */
38
- static defineModifier(t) {
39
- let a = new b(t);
40
- return (i) => i.modified.indexOf(a) > -1 ? i : b.get(i.base || i, i.modified.concat(a).sort((n, r) => n.id - r.id));
41
- }
42
- }
43
- let I = 0;
44
- class b {
45
- constructor(t) {
46
- this.name = t, this.instances = [], this.id = I++;
47
- }
48
- static get(t, a) {
49
- if (!a.length)
50
- return t;
51
- let i = a[0].instances.find((g) => g.base == t && j(a, g.modified));
52
- if (i)
53
- return i;
54
- let n = [], r = new l(t.name, n, t, a);
55
- for (let g of a)
56
- g.instances.push(r);
57
- let f = B(a);
58
- for (let g of t.set)
59
- if (!g.modified.length)
60
- for (let w of f)
61
- n.push(b.get(g, w));
62
- return r;
63
- }
64
- }
65
- function j(s, t) {
66
- return s.length == t.length && s.every((a, i) => a == t[i]);
67
- }
68
- function B(s) {
69
- let t = [[]];
70
- for (let a = 0; a < s.length; a++)
71
- for (let i = 0, n = t.length; i < n; i++)
72
- t.push(t[i].concat(s[a]));
73
- return t.sort((a, i) => i.length - a.length);
1
+ import { NodeProp } from "../../common/dist/index.js";
2
+ var nextTagID = 0, Tag = class n {
3
+ constructor(n, x, S, C) {
4
+ this.name = n, this.set = x, this.base = S, this.modified = C, this.id = nextTagID++;
5
+ }
6
+ toString() {
7
+ let { name: n } = this;
8
+ for (let b of this.modified) b.name && (n = `${b.name}(${n})`);
9
+ return n;
10
+ }
11
+ static define(b, x) {
12
+ let S = typeof b == "string" ? b : "?";
13
+ if (b instanceof n && (x = b), x?.base) throw Error("Can not derive from a modified tag");
14
+ let C = new n(S, [], null, []);
15
+ if (C.set.push(C), x) for (let n of x.set) C.set.push(n);
16
+ return C;
17
+ }
18
+ static defineModifier(n) {
19
+ let b = new Modifier(n);
20
+ return (n) => n.modified.indexOf(b) > -1 ? n : Modifier.get(n.base || n, n.modified.concat(b).sort((n, b) => n.id - b.id));
21
+ }
22
+ }, nextModifierID = 0, Modifier = class n {
23
+ constructor(n) {
24
+ this.name = n, this.instances = [], this.id = nextModifierID++;
25
+ }
26
+ static get(b, S) {
27
+ if (!S.length) return b;
28
+ let C = S[0].instances.find((n) => n.base == b && sameArray(S, n.modified));
29
+ if (C) return C;
30
+ let T = [], E = new Tag(b.name, T, b, S);
31
+ for (let n of S) n.instances.push(E);
32
+ let D = powerSet(S);
33
+ for (let x of b.set) if (!x.modified.length) for (let b of D) T.push(n.get(x, b));
34
+ return E;
35
+ }
36
+ };
37
+ function sameArray(n, b) {
38
+ return n.length == b.length && n.every((n, x) => n == b[x]);
74
39
  }
75
- const D = new q({
76
- combine(s, t) {
77
- let a, i, n;
78
- for (; s || t; ) {
79
- if (!s || t && s.depth >= t.depth ? (n = t, t = t.next) : (n = s, s = s.next), a && a.mode == n.mode && !n.context && !a.context)
80
- continue;
81
- let r = new O(n.tags, n.mode, n.context);
82
- a ? a.next = r : i = r, a = r;
83
- }
84
- return i;
85
- }
86
- });
87
- class O {
88
- constructor(t, a, i, n) {
89
- this.tags = t, this.mode = a, this.context = i, this.next = n;
90
- }
91
- get opaque() {
92
- return this.mode == 0;
93
- }
94
- get inherit() {
95
- return this.mode == 1;
96
- }
97
- sort(t) {
98
- return !t || t.depth < this.depth ? (this.next = t, this) : (t.next = this.sort(t.next), t);
99
- }
100
- get depth() {
101
- return this.context ? this.context.length : 0;
102
- }
40
+ function powerSet(n) {
41
+ let b = [[]];
42
+ for (let x = 0; x < n.length; x++) for (let S = 0, C = b.length; S < C; S++) b.push(b[S].concat(n[x]));
43
+ return b.sort((n, b) => b.length - n.length);
103
44
  }
104
- O.empty = new O([], 2, null);
105
- function $(s, t) {
106
- let a = /* @__PURE__ */ Object.create(null);
107
- for (let r of s)
108
- if (!Array.isArray(r.tag))
109
- a[r.tag.id] = r.class;
110
- else
111
- for (let f of r.tag)
112
- a[f.id] = r.class;
113
- let { scope: i, all: n = null } = {};
114
- return {
115
- style: (r) => {
116
- let f = n;
117
- for (let g of r)
118
- for (let w of g.set) {
119
- let v = a[w.id];
120
- if (v) {
121
- f = f ? f + " " + v : v;
122
- break;
123
- }
124
- }
125
- return f;
126
- },
127
- scope: i
128
- };
45
+ var ruleNodeProp = new NodeProp({ combine(n, b) {
46
+ let x, S, C;
47
+ for (; n || b;) {
48
+ if (!n || b && n.depth >= b.depth ? (C = b, b = b.next) : (C = n, n = n.next), x && x.mode == C.mode && !C.context && !x.context) continue;
49
+ let w = new Rule(C.tags, C.mode, C.context);
50
+ x ? x.next = w : S = w, x = w;
51
+ }
52
+ return S;
53
+ } }), Rule = class {
54
+ constructor(n, b, x, S) {
55
+ this.tags = n, this.mode = b, this.context = x, this.next = S;
56
+ }
57
+ get opaque() {
58
+ return this.mode == 0;
59
+ }
60
+ get inherit() {
61
+ return this.mode == 1;
62
+ }
63
+ sort(n) {
64
+ return !n || n.depth < this.depth ? (this.next = n, this) : (n.next = this.sort(n.next), n);
65
+ }
66
+ get depth() {
67
+ return this.context ? this.context.length : 0;
68
+ }
69
+ };
70
+ Rule.empty = new Rule([], 2, null);
71
+ function tagHighlighter(n, b) {
72
+ let x = Object.create(null);
73
+ for (let b of n) if (!Array.isArray(b.tag)) x[b.tag.id] = b.class;
74
+ else for (let n of b.tag) x[n.id] = b.class;
75
+ let { scope: S, all: C = null } = b || {};
76
+ return {
77
+ style: (n) => {
78
+ let b = C;
79
+ for (let S of n) for (let n of S.set) {
80
+ let S = x[n.id];
81
+ if (S) {
82
+ b = b ? b + " " + S : S;
83
+ break;
84
+ }
85
+ }
86
+ return b;
87
+ },
88
+ scope: S
89
+ };
129
90
  }
130
- function H(s) {
131
- let t = s.type.prop(D);
132
- for (; t && t.context && !s.matchContext(t.context); )
133
- t = t.next;
134
- return t || null;
91
+ function getStyleTags(n) {
92
+ let b = n.type.prop(ruleNodeProp);
93
+ for (; b && b.context && !n.matchContext(b.context);) b = b.next;
94
+ return b || null;
135
95
  }
136
- const e = l.define, N = e(), p = e(), S = e(p), K = e(p), u = e(), y = e(u), M = e(u), m = e(), h = e(m), c = e(), d = e(), C = e(), k = e(C), x = e(), o = {
137
- /**
138
- A comment.
139
- */
140
- comment: N,
141
- /**
142
- A line [comment](#highlight.tags.comment).
143
- */
144
- lineComment: e(N),
145
- /**
146
- A block [comment](#highlight.tags.comment).
147
- */
148
- blockComment: e(N),
149
- /**
150
- A documentation [comment](#highlight.tags.comment).
151
- */
152
- docComment: e(N),
153
- /**
154
- Any kind of identifier.
155
- */
156
- name: p,
157
- /**
158
- The [name](#highlight.tags.name) of a variable.
159
- */
160
- variableName: e(p),
161
- /**
162
- A type [name](#highlight.tags.name).
163
- */
164
- typeName: S,
165
- /**
166
- A tag name (subtag of [`typeName`](#highlight.tags.typeName)).
167
- */
168
- tagName: e(S),
169
- /**
170
- A property or field [name](#highlight.tags.name).
171
- */
172
- propertyName: K,
173
- /**
174
- An attribute name (subtag of [`propertyName`](#highlight.tags.propertyName)).
175
- */
176
- attributeName: e(K),
177
- /**
178
- The [name](#highlight.tags.name) of a class.
179
- */
180
- className: e(p),
181
- /**
182
- A label [name](#highlight.tags.name).
183
- */
184
- labelName: e(p),
185
- /**
186
- A namespace [name](#highlight.tags.name).
187
- */
188
- namespace: e(p),
189
- /**
190
- The [name](#highlight.tags.name) of a macro.
191
- */
192
- macroName: e(p),
193
- /**
194
- A literal value.
195
- */
196
- literal: u,
197
- /**
198
- A string [literal](#highlight.tags.literal).
199
- */
200
- string: y,
201
- /**
202
- A documentation [string](#highlight.tags.string).
203
- */
204
- docString: e(y),
205
- /**
206
- A character literal (subtag of [string](#highlight.tags.string)).
207
- */
208
- character: e(y),
209
- /**
210
- An attribute value (subtag of [string](#highlight.tags.string)).
211
- */
212
- attributeValue: e(y),
213
- /**
214
- A number [literal](#highlight.tags.literal).
215
- */
216
- number: M,
217
- /**
218
- An integer [number](#highlight.tags.number) literal.
219
- */
220
- integer: e(M),
221
- /**
222
- A floating-point [number](#highlight.tags.number) literal.
223
- */
224
- float: e(M),
225
- /**
226
- A boolean [literal](#highlight.tags.literal).
227
- */
228
- bool: e(u),
229
- /**
230
- Regular expression [literal](#highlight.tags.literal).
231
- */
232
- regexp: e(u),
233
- /**
234
- An escape [literal](#highlight.tags.literal), for example a
235
- backslash escape in a string.
236
- */
237
- escape: e(u),
238
- /**
239
- A color [literal](#highlight.tags.literal).
240
- */
241
- color: e(u),
242
- /**
243
- A URL [literal](#highlight.tags.literal).
244
- */
245
- url: e(u),
246
- /**
247
- A language keyword.
248
- */
249
- keyword: c,
250
- /**
251
- The [keyword](#highlight.tags.keyword) for the self or this
252
- object.
253
- */
254
- self: e(c),
255
- /**
256
- The [keyword](#highlight.tags.keyword) for null.
257
- */
258
- null: e(c),
259
- /**
260
- A [keyword](#highlight.tags.keyword) denoting some atomic value.
261
- */
262
- atom: e(c),
263
- /**
264
- A [keyword](#highlight.tags.keyword) that represents a unit.
265
- */
266
- unit: e(c),
267
- /**
268
- A modifier [keyword](#highlight.tags.keyword).
269
- */
270
- modifier: e(c),
271
- /**
272
- A [keyword](#highlight.tags.keyword) that acts as an operator.
273
- */
274
- operatorKeyword: e(c),
275
- /**
276
- A control-flow related [keyword](#highlight.tags.keyword).
277
- */
278
- controlKeyword: e(c),
279
- /**
280
- A [keyword](#highlight.tags.keyword) that defines something.
281
- */
282
- definitionKeyword: e(c),
283
- /**
284
- A [keyword](#highlight.tags.keyword) related to defining or
285
- interfacing with modules.
286
- */
287
- moduleKeyword: e(c),
288
- /**
289
- An operator.
290
- */
291
- operator: d,
292
- /**
293
- An [operator](#highlight.tags.operator) that dereferences something.
294
- */
295
- derefOperator: e(d),
296
- /**
297
- Arithmetic-related [operator](#highlight.tags.operator).
298
- */
299
- arithmeticOperator: e(d),
300
- /**
301
- Logical [operator](#highlight.tags.operator).
302
- */
303
- logicOperator: e(d),
304
- /**
305
- Bit [operator](#highlight.tags.operator).
306
- */
307
- bitwiseOperator: e(d),
308
- /**
309
- Comparison [operator](#highlight.tags.operator).
310
- */
311
- compareOperator: e(d),
312
- /**
313
- [Operator](#highlight.tags.operator) that updates its operand.
314
- */
315
- updateOperator: e(d),
316
- /**
317
- [Operator](#highlight.tags.operator) that defines something.
318
- */
319
- definitionOperator: e(d),
320
- /**
321
- Type-related [operator](#highlight.tags.operator).
322
- */
323
- typeOperator: e(d),
324
- /**
325
- Control-flow [operator](#highlight.tags.operator).
326
- */
327
- controlOperator: e(d),
328
- /**
329
- Program or markup punctuation.
330
- */
331
- punctuation: C,
332
- /**
333
- [Punctuation](#highlight.tags.punctuation) that separates
334
- things.
335
- */
336
- separator: e(C),
337
- /**
338
- Bracket-style [punctuation](#highlight.tags.punctuation).
339
- */
340
- bracket: k,
341
- /**
342
- Angle [brackets](#highlight.tags.bracket) (usually `<` and `>`
343
- tokens).
344
- */
345
- angleBracket: e(k),
346
- /**
347
- Square [brackets](#highlight.tags.bracket) (usually `[` and `]`
348
- tokens).
349
- */
350
- squareBracket: e(k),
351
- /**
352
- Parentheses (usually `(` and `)` tokens). Subtag of
353
- [bracket](#highlight.tags.bracket).
354
- */
355
- paren: e(k),
356
- /**
357
- Braces (usually `{` and `}` tokens). Subtag of
358
- [bracket](#highlight.tags.bracket).
359
- */
360
- brace: e(k),
361
- /**
362
- Content, for example plain text in XML or markup documents.
363
- */
364
- content: m,
365
- /**
366
- [Content](#highlight.tags.content) that represents a heading.
367
- */
368
- heading: h,
369
- /**
370
- A level 1 [heading](#highlight.tags.heading).
371
- */
372
- heading1: e(h),
373
- /**
374
- A level 2 [heading](#highlight.tags.heading).
375
- */
376
- heading2: e(h),
377
- /**
378
- A level 3 [heading](#highlight.tags.heading).
379
- */
380
- heading3: e(h),
381
- /**
382
- A level 4 [heading](#highlight.tags.heading).
383
- */
384
- heading4: e(h),
385
- /**
386
- A level 5 [heading](#highlight.tags.heading).
387
- */
388
- heading5: e(h),
389
- /**
390
- A level 6 [heading](#highlight.tags.heading).
391
- */
392
- heading6: e(h),
393
- /**
394
- A prose [content](#highlight.tags.content) separator (such as a horizontal rule).
395
- */
396
- contentSeparator: e(m),
397
- /**
398
- [Content](#highlight.tags.content) that represents a list.
399
- */
400
- list: e(m),
401
- /**
402
- [Content](#highlight.tags.content) that represents a quote.
403
- */
404
- quote: e(m),
405
- /**
406
- [Content](#highlight.tags.content) that is emphasized.
407
- */
408
- emphasis: e(m),
409
- /**
410
- [Content](#highlight.tags.content) that is styled strong.
411
- */
412
- strong: e(m),
413
- /**
414
- [Content](#highlight.tags.content) that is part of a link.
415
- */
416
- link: e(m),
417
- /**
418
- [Content](#highlight.tags.content) that is styled as code or
419
- monospace.
420
- */
421
- monospace: e(m),
422
- /**
423
- [Content](#highlight.tags.content) that has a strike-through
424
- style.
425
- */
426
- strikethrough: e(m),
427
- /**
428
- Inserted text in a change-tracking format.
429
- */
430
- inserted: e(),
431
- /**
432
- Deleted text.
433
- */
434
- deleted: e(),
435
- /**
436
- Changed text.
437
- */
438
- changed: e(),
439
- /**
440
- An invalid or unsyntactic element.
441
- */
442
- invalid: e(),
443
- /**
444
- Metadata or meta-instruction.
445
- */
446
- meta: x,
447
- /**
448
- [Metadata](#highlight.tags.meta) that applies to the entire
449
- document.
450
- */
451
- documentMeta: e(x),
452
- /**
453
- [Metadata](#highlight.tags.meta) that annotates or adds
454
- attributes to a given syntactic element.
455
- */
456
- annotation: e(x),
457
- /**
458
- Processing instruction or preprocessor directive. Subtag of
459
- [meta](#highlight.tags.meta).
460
- */
461
- processingInstruction: e(x),
462
- /**
463
- [Modifier](#highlight.Tag^defineModifier) that indicates that a
464
- given element is being defined. Expected to be used with the
465
- various [name](#highlight.tags.name) tags.
466
- */
467
- definition: l.defineModifier("definition"),
468
- /**
469
- [Modifier](#highlight.Tag^defineModifier) that indicates that
470
- something is constant. Mostly expected to be used with
471
- [variable names](#highlight.tags.variableName).
472
- */
473
- constant: l.defineModifier("constant"),
474
- /**
475
- [Modifier](#highlight.Tag^defineModifier) used to indicate that
476
- a [variable](#highlight.tags.variableName) or [property
477
- name](#highlight.tags.propertyName) is being called or defined
478
- as a function.
479
- */
480
- function: l.defineModifier("function"),
481
- /**
482
- [Modifier](#highlight.Tag^defineModifier) that can be applied to
483
- [names](#highlight.tags.name) to indicate that they belong to
484
- the language's standard environment.
485
- */
486
- standard: l.defineModifier("standard"),
487
- /**
488
- [Modifier](#highlight.Tag^defineModifier) that indicates a given
489
- [names](#highlight.tags.name) is local to some scope.
490
- */
491
- local: l.defineModifier("local"),
492
- /**
493
- A generic variant [modifier](#highlight.Tag^defineModifier) that
494
- can be used to tag language-specific alternative variants of
495
- some common tag. It is recommended for themes to define special
496
- forms of at least the [string](#highlight.tags.string) and
497
- [variable name](#highlight.tags.variableName) tags, since those
498
- come up a lot.
499
- */
500
- special: l.defineModifier("special")
96
+ var t = Tag.define, comment = t(), name = t(), typeName = t(name), propertyName = t(name), literal = t(), string = t(literal), number = t(literal), content = t(), heading = t(content), keyword = t(), operator = t(), punctuation = t(), bracket = t(punctuation), meta = t(), tags = {
97
+ comment,
98
+ lineComment: t(comment),
99
+ blockComment: t(comment),
100
+ docComment: t(comment),
101
+ name,
102
+ variableName: t(name),
103
+ typeName,
104
+ tagName: t(typeName),
105
+ propertyName,
106
+ attributeName: t(propertyName),
107
+ className: t(name),
108
+ labelName: t(name),
109
+ namespace: t(name),
110
+ macroName: t(name),
111
+ literal,
112
+ string,
113
+ docString: t(string),
114
+ character: t(string),
115
+ attributeValue: t(string),
116
+ number,
117
+ integer: t(number),
118
+ float: t(number),
119
+ bool: t(literal),
120
+ regexp: t(literal),
121
+ escape: t(literal),
122
+ color: t(literal),
123
+ url: t(literal),
124
+ keyword,
125
+ self: t(keyword),
126
+ null: t(keyword),
127
+ atom: t(keyword),
128
+ unit: t(keyword),
129
+ modifier: t(keyword),
130
+ operatorKeyword: t(keyword),
131
+ controlKeyword: t(keyword),
132
+ definitionKeyword: t(keyword),
133
+ moduleKeyword: t(keyword),
134
+ operator,
135
+ derefOperator: t(operator),
136
+ arithmeticOperator: t(operator),
137
+ logicOperator: t(operator),
138
+ bitwiseOperator: t(operator),
139
+ compareOperator: t(operator),
140
+ updateOperator: t(operator),
141
+ definitionOperator: t(operator),
142
+ typeOperator: t(operator),
143
+ controlOperator: t(operator),
144
+ punctuation,
145
+ separator: t(punctuation),
146
+ bracket,
147
+ angleBracket: t(bracket),
148
+ squareBracket: t(bracket),
149
+ paren: t(bracket),
150
+ brace: t(bracket),
151
+ content,
152
+ heading,
153
+ heading1: t(heading),
154
+ heading2: t(heading),
155
+ heading3: t(heading),
156
+ heading4: t(heading),
157
+ heading5: t(heading),
158
+ heading6: t(heading),
159
+ contentSeparator: t(content),
160
+ list: t(content),
161
+ quote: t(content),
162
+ emphasis: t(content),
163
+ strong: t(content),
164
+ link: t(content),
165
+ monospace: t(content),
166
+ strikethrough: t(content),
167
+ inserted: t(),
168
+ deleted: t(),
169
+ changed: t(),
170
+ invalid: t(),
171
+ meta,
172
+ documentMeta: t(meta),
173
+ annotation: t(meta),
174
+ processingInstruction: t(meta),
175
+ definition: Tag.defineModifier("definition"),
176
+ constant: Tag.defineModifier("constant"),
177
+ function: Tag.defineModifier("function"),
178
+ standard: Tag.defineModifier("standard"),
179
+ local: Tag.defineModifier("local"),
180
+ special: Tag.defineModifier("special")
501
181
  };
502
- for (let s in o) {
503
- let t = o[s];
504
- t instanceof l && (t.name = s);
182
+ for (let n in tags) {
183
+ let b = tags[n];
184
+ b instanceof Tag && (b.name = n);
505
185
  }
506
- $([
507
- { tag: o.link, class: "tok-link" },
508
- { tag: o.heading, class: "tok-heading" },
509
- { tag: o.emphasis, class: "tok-emphasis" },
510
- { tag: o.strong, class: "tok-strong" },
511
- { tag: o.keyword, class: "tok-keyword" },
512
- { tag: o.atom, class: "tok-atom" },
513
- { tag: o.bool, class: "tok-bool" },
514
- { tag: o.url, class: "tok-url" },
515
- { tag: o.labelName, class: "tok-labelName" },
516
- { tag: o.inserted, class: "tok-inserted" },
517
- { tag: o.deleted, class: "tok-deleted" },
518
- { tag: o.literal, class: "tok-literal" },
519
- { tag: o.string, class: "tok-string" },
520
- { tag: o.number, class: "tok-number" },
521
- { tag: [o.regexp, o.escape, o.special(o.string)], class: "tok-string2" },
522
- { tag: o.variableName, class: "tok-variableName" },
523
- { tag: o.local(o.variableName), class: "tok-variableName tok-local" },
524
- { tag: o.definition(o.variableName), class: "tok-variableName tok-definition" },
525
- { tag: o.special(o.variableName), class: "tok-variableName2" },
526
- { tag: o.definition(o.propertyName), class: "tok-propertyName tok-definition" },
527
- { tag: o.typeName, class: "tok-typeName" },
528
- { tag: o.namespace, class: "tok-namespace" },
529
- { tag: o.className, class: "tok-className" },
530
- { tag: o.macroName, class: "tok-macroName" },
531
- { tag: o.propertyName, class: "tok-propertyName" },
532
- { tag: o.operator, class: "tok-operator" },
533
- { tag: o.comment, class: "tok-comment" },
534
- { tag: o.meta, class: "tok-meta" },
535
- { tag: o.invalid, class: "tok-invalid" },
536
- { tag: o.punctuation, class: "tok-punctuation" }
186
+ tagHighlighter([
187
+ {
188
+ tag: tags.link,
189
+ class: "tok-link"
190
+ },
191
+ {
192
+ tag: tags.heading,
193
+ class: "tok-heading"
194
+ },
195
+ {
196
+ tag: tags.emphasis,
197
+ class: "tok-emphasis"
198
+ },
199
+ {
200
+ tag: tags.strong,
201
+ class: "tok-strong"
202
+ },
203
+ {
204
+ tag: tags.keyword,
205
+ class: "tok-keyword"
206
+ },
207
+ {
208
+ tag: tags.atom,
209
+ class: "tok-atom"
210
+ },
211
+ {
212
+ tag: tags.bool,
213
+ class: "tok-bool"
214
+ },
215
+ {
216
+ tag: tags.url,
217
+ class: "tok-url"
218
+ },
219
+ {
220
+ tag: tags.labelName,
221
+ class: "tok-labelName"
222
+ },
223
+ {
224
+ tag: tags.inserted,
225
+ class: "tok-inserted"
226
+ },
227
+ {
228
+ tag: tags.deleted,
229
+ class: "tok-deleted"
230
+ },
231
+ {
232
+ tag: tags.literal,
233
+ class: "tok-literal"
234
+ },
235
+ {
236
+ tag: tags.string,
237
+ class: "tok-string"
238
+ },
239
+ {
240
+ tag: tags.number,
241
+ class: "tok-number"
242
+ },
243
+ {
244
+ tag: [
245
+ tags.regexp,
246
+ tags.escape,
247
+ tags.special(tags.string)
248
+ ],
249
+ class: "tok-string2"
250
+ },
251
+ {
252
+ tag: tags.variableName,
253
+ class: "tok-variableName"
254
+ },
255
+ {
256
+ tag: tags.local(tags.variableName),
257
+ class: "tok-variableName tok-local"
258
+ },
259
+ {
260
+ tag: tags.definition(tags.variableName),
261
+ class: "tok-variableName tok-definition"
262
+ },
263
+ {
264
+ tag: tags.special(tags.variableName),
265
+ class: "tok-variableName2"
266
+ },
267
+ {
268
+ tag: tags.definition(tags.propertyName),
269
+ class: "tok-propertyName tok-definition"
270
+ },
271
+ {
272
+ tag: tags.typeName,
273
+ class: "tok-typeName"
274
+ },
275
+ {
276
+ tag: tags.namespace,
277
+ class: "tok-namespace"
278
+ },
279
+ {
280
+ tag: tags.className,
281
+ class: "tok-className"
282
+ },
283
+ {
284
+ tag: tags.macroName,
285
+ class: "tok-macroName"
286
+ },
287
+ {
288
+ tag: tags.propertyName,
289
+ class: "tok-propertyName"
290
+ },
291
+ {
292
+ tag: tags.operator,
293
+ class: "tok-operator"
294
+ },
295
+ {
296
+ tag: tags.comment,
297
+ class: "tok-comment"
298
+ },
299
+ {
300
+ tag: tags.meta,
301
+ class: "tok-meta"
302
+ },
303
+ {
304
+ tag: tags.invalid,
305
+ class: "tok-invalid"
306
+ },
307
+ {
308
+ tag: tags.punctuation,
309
+ class: "tok-punctuation"
310
+ }
537
311
  ]);
538
- export {
539
- l as Tag,
540
- H as getStyleTags,
541
- $ as tagHighlighter,
542
- o as tags
543
- };
312
+ export { getStyleTags, tags };