@pibit.ai/cure-design-system 0.3.8 → 0.3.11
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.
- package/dist/applications/loading-indicator/loading-indicator.d.ts +19 -0
- package/dist/applications/loading-indicator/loading-indicator.d.ts.map +1 -0
- package/dist/applications/loading-indicator/loading-indicator.js +172 -0
- package/dist/hooks/use-resize-observer.d.ts +25 -0
- package/dist/hooks/use-resize-observer.d.ts.map +1 -0
- package/dist/hooks/use-resize-observer.js +25 -0
- package/dist/index.d.ts +7 -4
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +61 -42
- package/dist/node_modules/@react-aria/focus/dist/FocusScope.js +442 -0
- package/dist/node_modules/@react-aria/i18n/dist/context.js +10 -0
- package/dist/node_modules/@react-aria/i18n/dist/useCollator.js +11 -0
- package/dist/node_modules/@react-aria/i18n/dist/useDefaultLocale.js +36 -0
- package/dist/node_modules/@react-aria/i18n/dist/useFilter.js +35 -0
- package/dist/node_modules/@react-aria/i18n/dist/utils.js +44 -0
- package/dist/node_modules/@react-aria/interactions/dist/focusSafely.js +18 -0
- package/dist/node_modules/@react-aria/interactions/dist/useFocusVisible.js +62 -0
- package/dist/node_modules/@react-aria/interactions/dist/utils.js +5 -0
- package/dist/node_modules/@react-aria/ssr/dist/SSRProvider.js +49 -0
- package/dist/node_modules/@react-aria/utils/dist/DOMFunctions.js +27 -0
- package/dist/node_modules/@react-aria/utils/dist/ShadowTreeWalker.js +130 -0
- package/dist/node_modules/@react-aria/utils/dist/domHelpers.js +15 -0
- package/dist/node_modules/@react-aria/utils/dist/focusWithoutScrolling.js +45 -0
- package/dist/node_modules/@react-aria/utils/dist/isElementVisible.js +25 -0
- package/dist/node_modules/@react-aria/utils/dist/isFocusable.js +37 -0
- package/dist/node_modules/@react-aria/utils/dist/isVirtualEvent.js +7 -0
- package/dist/node_modules/@react-aria/utils/dist/openLink.js +28 -0
- package/dist/node_modules/@react-aria/utils/dist/platform.js +47 -0
- package/dist/node_modules/@react-aria/utils/dist/runAfterTransition.js +35 -0
- package/dist/node_modules/@react-aria/utils/dist/useLayoutEffect.js +6 -0
- package/dist/node_modules/@react-stately/data/dist/useListData.js +212 -0
- package/dist/node_modules/@react-stately/flags/dist/import.js +7 -0
- package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/PopChild.js +59 -0
- package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/PresenceChild.js +34 -0
- package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/index.js +47 -0
- package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/use-presence.js +17 -0
- package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/utils.js +12 -0
- package/dist/node_modules/framer-motion/dist/es/context/LayoutGroupContext.js +5 -0
- package/dist/node_modules/framer-motion/dist/es/context/LazyContext.js +5 -0
- package/dist/node_modules/framer-motion/dist/es/context/MotionConfigContext.js +9 -0
- package/dist/node_modules/framer-motion/dist/es/context/MotionContext/create.js +13 -0
- package/dist/node_modules/framer-motion/dist/es/context/MotionContext/index.js +5 -0
- package/dist/node_modules/framer-motion/dist/es/context/MotionContext/utils.js +15 -0
- package/dist/node_modules/framer-motion/dist/es/context/PresenceContext.js +5 -0
- package/dist/node_modules/framer-motion/dist/es/context/SwitchLayoutGroupContext.js +5 -0
- package/dist/node_modules/framer-motion/dist/es/events/add-pointer-event.js +8 -0
- package/dist/node_modules/framer-motion/dist/es/events/event-info.js +14 -0
- package/dist/node_modules/framer-motion/dist/es/gestures/drag/VisualElementDragControls.js +277 -0
- package/dist/node_modules/framer-motion/dist/es/gestures/drag/index.js +22 -0
- package/dist/node_modules/framer-motion/dist/es/gestures/drag/utils/constraints.js +67 -0
- package/dist/node_modules/framer-motion/dist/es/gestures/focus.js +28 -0
- package/dist/node_modules/framer-motion/dist/es/gestures/hover.js +21 -0
- package/dist/node_modules/framer-motion/dist/es/gestures/pan/PanSession.js +131 -0
- package/dist/node_modules/framer-motion/dist/es/gestures/pan/index.js +43 -0
- package/dist/node_modules/framer-motion/dist/es/gestures/press.js +23 -0
- package/dist/node_modules/framer-motion/dist/es/motion/features/animation/exit.js +27 -0
- package/dist/node_modules/framer-motion/dist/es/motion/features/animation/index.js +34 -0
- package/dist/node_modules/framer-motion/dist/es/motion/features/animations.js +13 -0
- package/dist/node_modules/framer-motion/dist/es/motion/features/definitions.js +39 -0
- package/dist/node_modules/framer-motion/dist/es/motion/features/drag.js +17 -0
- package/dist/node_modules/framer-motion/dist/es/motion/features/gestures.js +21 -0
- package/dist/node_modules/framer-motion/dist/es/motion/features/layout/MeasureLayout.js +60 -0
- package/dist/node_modules/framer-motion/dist/es/motion/features/layout.js +11 -0
- package/dist/node_modules/framer-motion/dist/es/motion/features/load-features.js +14 -0
- package/dist/node_modules/framer-motion/dist/es/motion/features/viewport/index.js +44 -0
- package/dist/node_modules/framer-motion/dist/es/motion/features/viewport/observers.js +21 -0
- package/dist/node_modules/framer-motion/dist/es/motion/index.js +63 -0
- package/dist/node_modules/framer-motion/dist/es/motion/utils/symbol.js +4 -0
- package/dist/node_modules/framer-motion/dist/es/motion/utils/use-motion-ref.js +22 -0
- package/dist/node_modules/framer-motion/dist/es/motion/utils/use-visual-element.js +66 -0
- package/dist/node_modules/framer-motion/dist/es/motion/utils/use-visual-state.js +52 -0
- package/dist/node_modules/framer-motion/dist/es/motion/utils/valid-prop.js +38 -0
- package/dist/node_modules/framer-motion/dist/es/render/components/create-proxy.js +18 -0
- package/dist/node_modules/framer-motion/dist/es/render/components/motion/feature-bundle.js +13 -0
- package/dist/node_modules/framer-motion/dist/es/render/components/motion/proxy.js +7 -0
- package/dist/node_modules/framer-motion/dist/es/render/dom/create-visual-element.js +10 -0
- package/dist/node_modules/framer-motion/dist/es/render/dom/use-render.js +16 -0
- package/dist/node_modules/framer-motion/dist/es/render/dom/utils/filter-props.js +20 -0
- package/dist/node_modules/framer-motion/dist/es/render/dom/utils/is-svg-component.js +24 -0
- package/dist/node_modules/framer-motion/dist/es/render/html/use-html-visual-state.js +10 -0
- package/dist/node_modules/framer-motion/dist/es/render/html/use-props.js +27 -0
- package/dist/node_modules/framer-motion/dist/es/render/html/utils/create-render-state.js +9 -0
- package/dist/node_modules/framer-motion/dist/es/render/svg/lowercase-elements.js +30 -0
- package/dist/node_modules/framer-motion/dist/es/render/svg/use-props.js +22 -0
- package/dist/node_modules/framer-motion/dist/es/render/svg/use-svg-visual-state.js +10 -0
- package/dist/node_modules/framer-motion/dist/es/render/svg/utils/create-render-state.js +8 -0
- package/dist/node_modules/framer-motion/dist/es/utils/distance.js +9 -0
- package/dist/node_modules/framer-motion/dist/es/utils/get-context-window.js +4 -0
- package/dist/node_modules/framer-motion/dist/es/utils/is-browser.js +4 -0
- package/dist/node_modules/framer-motion/dist/es/utils/is-ref-object.js +6 -0
- package/dist/node_modules/framer-motion/dist/es/utils/use-composed-ref.js +28 -0
- package/dist/node_modules/framer-motion/dist/es/utils/use-constant.js +8 -0
- package/dist/node_modules/framer-motion/dist/es/utils/use-isomorphic-effect.js +6 -0
- package/dist/node_modules/motion-dom/dist/es/animation/AsyncMotionValueAnimation.js +106 -0
- package/dist/node_modules/motion-dom/dist/es/animation/JSAnimation.js +133 -0
- package/dist/node_modules/motion-dom/dist/es/animation/NativeAnimation.js +109 -0
- package/dist/node_modules/motion-dom/dist/es/animation/NativeAnimationExtended.js +37 -0
- package/dist/node_modules/motion-dom/dist/es/animation/animate/single-value.js +10 -0
- package/dist/node_modules/motion-dom/dist/es/animation/drivers/frame.js +17 -0
- package/dist/node_modules/motion-dom/dist/es/animation/generators/inertia.js +37 -0
- package/dist/node_modules/motion-dom/dist/es/animation/generators/keyframes.js +30 -0
- package/dist/node_modules/motion-dom/dist/es/animation/generators/spring/defaults.js +32 -0
- package/dist/node_modules/motion-dom/dist/es/animation/generators/spring/find.js +52 -0
- package/dist/node_modules/motion-dom/dist/es/animation/generators/spring/index.js +98 -0
- package/dist/node_modules/motion-dom/dist/es/animation/generators/utils/calc-duration.js +13 -0
- package/dist/node_modules/motion-dom/dist/es/animation/generators/utils/create-generator-easing.js +13 -0
- package/dist/node_modules/motion-dom/dist/es/animation/generators/utils/is-generator.js +6 -0
- package/dist/node_modules/motion-dom/dist/es/animation/generators/utils/velocity.js +9 -0
- package/dist/node_modules/motion-dom/dist/es/animation/interfaces/motion-value.js +46 -0
- package/dist/node_modules/motion-dom/dist/es/animation/interfaces/visual-element-target.js +49 -0
- package/dist/node_modules/motion-dom/dist/es/animation/interfaces/visual-element-variant.js +30 -0
- package/dist/node_modules/motion-dom/dist/es/animation/interfaces/visual-element.js +22 -0
- package/dist/node_modules/motion-dom/dist/es/animation/keyframes/DOMKeyframesResolver.js +69 -0
- package/dist/node_modules/motion-dom/dist/es/animation/keyframes/KeyframesResolver.js +75 -0
- package/dist/node_modules/motion-dom/dist/es/animation/keyframes/get-final.js +8 -0
- package/dist/node_modules/motion-dom/dist/es/animation/keyframes/offsets/default.js +8 -0
- package/dist/node_modules/motion-dom/dist/es/animation/keyframes/offsets/fill.js +12 -0
- package/dist/node_modules/motion-dom/dist/es/animation/keyframes/offsets/time.js +6 -0
- package/dist/node_modules/motion-dom/dist/es/animation/keyframes/utils/fill-wildcards.js +7 -0
- package/dist/node_modules/motion-dom/dist/es/animation/keyframes/utils/is-none.js +7 -0
- package/dist/node_modules/motion-dom/dist/es/animation/keyframes/utils/make-none-animatable.js +16 -0
- package/dist/node_modules/motion-dom/dist/es/animation/keyframes/utils/unit-conversion.js +31 -0
- package/dist/node_modules/motion-dom/dist/es/animation/optimized-appear/data-id.js +6 -0
- package/dist/node_modules/motion-dom/dist/es/animation/optimized-appear/get-appear-id.js +7 -0
- package/dist/node_modules/motion-dom/dist/es/animation/utils/WithPromise.js +27 -0
- package/dist/node_modules/motion-dom/dist/es/animation/utils/calc-child-stagger.js +7 -0
- package/dist/node_modules/motion-dom/dist/es/animation/utils/can-animate.js +23 -0
- package/dist/node_modules/motion-dom/dist/es/animation/utils/css-variables-conversion.js +31 -0
- package/dist/node_modules/motion-dom/dist/es/animation/utils/default-transitions.js +22 -0
- package/dist/node_modules/motion-dom/dist/es/animation/utils/get-final-keyframe.js +8 -0
- package/dist/node_modules/motion-dom/dist/es/animation/utils/get-value-transition.js +6 -0
- package/dist/node_modules/motion-dom/dist/es/animation/utils/is-animatable.js +7 -0
- package/dist/node_modules/motion-dom/dist/es/animation/utils/is-css-variable.js +9 -0
- package/dist/node_modules/motion-dom/dist/es/animation/utils/is-transition-defined.js +6 -0
- package/dist/node_modules/motion-dom/dist/es/animation/utils/make-animation-instant.js +6 -0
- package/dist/node_modules/motion-dom/dist/es/animation/utils/replace-transition-type.js +16 -0
- package/dist/node_modules/motion-dom/dist/es/animation/waapi/easing/cubic-bezier.js +4 -0
- package/dist/node_modules/motion-dom/dist/es/animation/waapi/easing/map-easing.js +12 -0
- package/dist/node_modules/motion-dom/dist/es/animation/waapi/easing/supported.js +15 -0
- package/dist/node_modules/motion-dom/dist/es/animation/waapi/start-waapi-animation.js +21 -0
- package/dist/node_modules/motion-dom/dist/es/animation/waapi/supports/waapi.js +24 -0
- package/dist/node_modules/motion-dom/dist/es/animation/waapi/utils/apply-generator.js +8 -0
- package/dist/node_modules/motion-dom/dist/es/animation/waapi/utils/linear.js +10 -0
- package/dist/node_modules/motion-dom/dist/es/animation/waapi/utils/unsupported-easing.js +17 -0
- package/dist/node_modules/motion-dom/dist/es/events/add-dom-event.js +6 -0
- package/dist/node_modules/motion-dom/dist/es/frameloop/batcher.js +27 -0
- package/dist/node_modules/motion-dom/dist/es/frameloop/frame.js +9 -0
- package/dist/node_modules/motion-dom/dist/es/frameloop/microtask.js +5 -0
- package/dist/node_modules/motion-dom/dist/es/frameloop/order.js +21 -0
- package/dist/node_modules/motion-dom/dist/es/frameloop/render-step.js +41 -0
- package/dist/node_modules/motion-dom/dist/es/frameloop/sync-time.js +15 -0
- package/dist/node_modules/motion-dom/dist/es/gestures/drag/state/is-active.js +11 -0
- package/dist/node_modules/motion-dom/dist/es/gestures/drag/state/set-active.js +11 -0
- package/dist/node_modules/motion-dom/dist/es/gestures/hover.js +24 -0
- package/dist/node_modules/motion-dom/dist/es/gestures/press/index.js +33 -0
- package/dist/node_modules/motion-dom/dist/es/gestures/press/utils/is-keyboard-accessible.js +13 -0
- package/dist/node_modules/motion-dom/dist/es/gestures/press/utils/keyboard.js +27 -0
- package/dist/node_modules/motion-dom/dist/es/gestures/press/utils/state.js +4 -0
- package/dist/node_modules/motion-dom/dist/es/gestures/utils/is-node-or-child.js +4 -0
- package/dist/node_modules/motion-dom/dist/es/gestures/utils/is-primary-pointer.js +4 -0
- package/dist/node_modules/motion-dom/dist/es/gestures/utils/setup.js +12 -0
- package/dist/node_modules/motion-dom/dist/es/projection/animation/mix-values.js +27 -0
- package/dist/node_modules/motion-dom/dist/es/projection/geometry/conversion.js +25 -0
- package/dist/node_modules/motion-dom/dist/es/projection/geometry/copy.js +14 -0
- package/dist/node_modules/motion-dom/dist/es/projection/geometry/delta-apply.js +52 -0
- package/dist/node_modules/motion-dom/dist/es/projection/geometry/delta-calc.js +36 -0
- package/dist/node_modules/motion-dom/dist/es/projection/geometry/delta-remove.js +25 -0
- package/dist/node_modules/motion-dom/dist/es/projection/geometry/models.js +18 -0
- package/dist/node_modules/motion-dom/dist/es/projection/geometry/utils.js +34 -0
- package/dist/node_modules/motion-dom/dist/es/projection/node/DocumentProjectionNode.js +16 -0
- package/dist/node_modules/motion-dom/dist/es/projection/node/HTMLProjectionNode.js +25 -0
- package/dist/node_modules/motion-dom/dist/es/projection/node/create-projection-node.js +623 -0
- package/dist/node_modules/motion-dom/dist/es/projection/node/state.js +15 -0
- package/dist/node_modules/motion-dom/dist/es/projection/shared/stack.js +60 -0
- package/dist/node_modules/motion-dom/dist/es/projection/styles/scale-border-radius.js +21 -0
- package/dist/node_modules/motion-dom/dist/es/projection/styles/scale-box-shadow.js +16 -0
- package/dist/node_modules/motion-dom/dist/es/projection/styles/scale-correction.js +21 -0
- package/dist/node_modules/motion-dom/dist/es/projection/styles/transform.js +13 -0
- package/dist/node_modules/motion-dom/dist/es/projection/utils/compare-by-depth.js +4 -0
- package/dist/node_modules/motion-dom/dist/es/projection/utils/each-axis.js +6 -0
- package/dist/node_modules/motion-dom/dist/es/projection/utils/flat-tree.js +19 -0
- package/dist/node_modules/motion-dom/dist/es/projection/utils/has-transform.js +20 -0
- package/dist/node_modules/motion-dom/dist/es/projection/utils/measure.js +13 -0
- package/dist/node_modules/motion-dom/dist/es/render/Feature.js +10 -0
- package/dist/node_modules/motion-dom/dist/es/render/VisualElement.js +247 -0
- package/dist/node_modules/motion-dom/dist/es/render/dom/DOMVisualElement.js +28 -0
- package/dist/node_modules/motion-dom/dist/es/render/dom/is-css-var.js +4 -0
- package/dist/node_modules/motion-dom/dist/es/render/dom/parse-transform.js +65 -0
- package/dist/node_modules/motion-dom/dist/es/render/dom/style-set.js +7 -0
- package/dist/node_modules/motion-dom/dist/es/render/dom/utils/camel-to-dash.js +6 -0
- package/dist/node_modules/motion-dom/dist/es/render/html/HTMLVisualElement.js +38 -0
- package/dist/node_modules/motion-dom/dist/es/render/html/utils/build-styles.js +29 -0
- package/dist/node_modules/motion-dom/dist/es/render/html/utils/build-transform.js +37 -0
- package/dist/node_modules/motion-dom/dist/es/render/html/utils/render.js +12 -0
- package/dist/node_modules/motion-dom/dist/es/render/html/utils/scrape-motion-values.js +14 -0
- package/dist/node_modules/motion-dom/dist/es/render/store.js +4 -0
- package/dist/node_modules/motion-dom/dist/es/render/svg/SVGVisualElement.js +40 -0
- package/dist/node_modules/motion-dom/dist/es/render/svg/utils/build-attrs.js +32 -0
- package/dist/node_modules/motion-dom/dist/es/render/svg/utils/camel-case-attrs.js +28 -0
- package/dist/node_modules/motion-dom/dist/es/render/svg/utils/is-svg-tag.js +4 -0
- package/dist/node_modules/motion-dom/dist/es/render/svg/utils/path.js +15 -0
- package/dist/node_modules/motion-dom/dist/es/render/svg/utils/render.js +11 -0
- package/dist/node_modules/motion-dom/dist/es/render/svg/utils/scrape-motion-values.js +15 -0
- package/dist/node_modules/motion-dom/dist/es/render/utils/animation-state.js +141 -0
- package/dist/node_modules/motion-dom/dist/es/render/utils/get-variant-context.js +20 -0
- package/dist/node_modules/motion-dom/dist/es/render/utils/is-animation-controls.js +6 -0
- package/dist/node_modules/motion-dom/dist/es/render/utils/is-controlling-variants.js +13 -0
- package/dist/node_modules/motion-dom/dist/es/render/utils/is-forced-motion-value.js +9 -0
- package/dist/node_modules/motion-dom/dist/es/render/utils/is-keyframes-target.js +4 -0
- package/dist/node_modules/motion-dom/dist/es/render/utils/is-variant-label.js +6 -0
- package/dist/node_modules/motion-dom/dist/es/render/utils/keys-position.js +13 -0
- package/dist/node_modules/motion-dom/dist/es/render/utils/keys-transform.js +23 -0
- package/dist/node_modules/motion-dom/dist/es/render/utils/motion-values.js +25 -0
- package/dist/node_modules/motion-dom/dist/es/render/utils/reduced-motion/index.js +15 -0
- package/dist/node_modules/motion-dom/dist/es/render/utils/reduced-motion/state.js +5 -0
- package/dist/node_modules/motion-dom/dist/es/render/utils/resolve-dynamic-variants.js +8 -0
- package/dist/node_modules/motion-dom/dist/es/render/utils/resolve-variants.js +20 -0
- package/dist/node_modules/motion-dom/dist/es/render/utils/setters.js +21 -0
- package/dist/node_modules/motion-dom/dist/es/render/utils/shallow-compare.js +14 -0
- package/dist/node_modules/motion-dom/dist/es/render/utils/variant-props.js +13 -0
- package/dist/node_modules/motion-dom/dist/es/utils/delay.js +12 -0
- package/dist/node_modules/motion-dom/dist/es/utils/interpolate.js +42 -0
- package/dist/node_modules/motion-dom/dist/es/utils/is-html-element.js +7 -0
- package/dist/node_modules/motion-dom/dist/es/utils/is-svg-element.js +7 -0
- package/dist/node_modules/motion-dom/dist/es/utils/is-svg-svg-element.js +7 -0
- package/dist/node_modules/motion-dom/dist/es/utils/mix/color.js +29 -0
- package/dist/node_modules/motion-dom/dist/es/utils/mix/complex.js +51 -0
- package/dist/node_modules/motion-dom/dist/es/utils/mix/immediate.js +6 -0
- package/dist/node_modules/motion-dom/dist/es/utils/mix/index.js +8 -0
- package/dist/node_modules/motion-dom/dist/es/utils/mix/number.js +4 -0
- package/dist/node_modules/motion-dom/dist/es/utils/mix/visibility.js +8 -0
- package/dist/node_modules/motion-dom/dist/es/utils/resolve-elements.js +15 -0
- package/dist/node_modules/motion-dom/dist/es/utils/supports/flags.js +4 -0
- package/dist/node_modules/motion-dom/dist/es/utils/supports/linear-easing.js +12 -0
- package/dist/node_modules/motion-dom/dist/es/utils/supports/memo.js +9 -0
- package/dist/node_modules/motion-dom/dist/es/utils/supports/scroll-timeline.js +5 -0
- package/dist/node_modules/motion-dom/dist/es/value/index.js +215 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/auto.js +7 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/color/hex.js +19 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/color/hsla-to-rgba.js +22 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/color/hsla.js +12 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/color/index.js +15 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/color/rgba.js +16 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/color/utils.js +18 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/complex/filter.js +24 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/complex/index.js +49 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/dimensions.js +9 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/int.js +8 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/maps/defaults.js +24 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/maps/number.js +70 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/maps/transform.js +31 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/numbers/index.js +17 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/numbers/units.js +17 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/test.js +4 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/utils/animatable-none.js +10 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/utils/color-regex.js +4 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/utils/find.js +8 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/utils/float-regex.js +4 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/utils/get-as-type.js +4 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/utils/is-nullish.js +6 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/utils/sanitize.js +4 -0
- package/dist/node_modules/motion-dom/dist/es/value/types/utils/single-color-regex.js +4 -0
- package/dist/node_modules/motion-dom/dist/es/value/utils/is-motion-value.js +4 -0
- package/dist/node_modules/motion-dom/dist/es/value/utils/resolve-motion-value.js +7 -0
- package/dist/node_modules/motion-dom/dist/es/value/will-change/add-will-change.js +14 -0
- package/dist/node_modules/motion-dom/dist/es/value/will-change/is.js +7 -0
- package/dist/node_modules/motion-utils/dist/es/array.js +11 -0
- package/dist/node_modules/motion-utils/dist/es/clamp.js +4 -0
- package/dist/node_modules/motion-utils/dist/es/easing/anticipate.js +5 -0
- package/dist/node_modules/motion-utils/dist/es/easing/back.js +9 -0
- package/dist/node_modules/motion-utils/dist/es/easing/circ.js +8 -0
- package/dist/node_modules/motion-utils/dist/es/easing/cubic-bezier.js +18 -0
- package/dist/node_modules/motion-utils/dist/es/easing/ease.js +7 -0
- package/dist/node_modules/motion-utils/dist/es/easing/modifiers/mirror.js +4 -0
- package/dist/node_modules/motion-utils/dist/es/easing/modifiers/reverse.js +4 -0
- package/dist/node_modules/motion-utils/dist/es/easing/utils/is-bezier-definition.js +4 -0
- package/dist/node_modules/motion-utils/dist/es/easing/utils/is-easing-array.js +4 -0
- package/dist/node_modules/motion-utils/dist/es/easing/utils/map.js +32 -0
- package/dist/node_modules/motion-utils/dist/es/errors.js +15 -0
- package/dist/node_modules/motion-utils/dist/es/format-error-message.js +6 -0
- package/dist/node_modules/motion-utils/dist/es/global-config.js +4 -0
- package/dist/node_modules/motion-utils/dist/es/is-numerical-string.js +4 -0
- package/dist/node_modules/motion-utils/dist/es/is-object.js +6 -0
- package/dist/node_modules/motion-utils/dist/es/is-zero-value-string.js +4 -0
- package/dist/node_modules/motion-utils/dist/es/memo.js +8 -0
- package/dist/node_modules/motion-utils/dist/es/noop.js +4 -0
- package/dist/node_modules/motion-utils/dist/es/pipe.js +4 -0
- package/dist/node_modules/motion-utils/dist/es/progress.js +7 -0
- package/dist/node_modules/motion-utils/dist/es/subscription-manager.js +29 -0
- package/dist/node_modules/motion-utils/dist/es/time-conversion.js +5 -0
- package/dist/node_modules/motion-utils/dist/es/velocity-per-second.js +6 -0
- package/dist/node_modules/motion-utils/dist/es/warn-once.js +8 -0
- package/dist/patterns/table/TableWrapper.d.ts.map +1 -1
- package/dist/patterns/table/TableWrapper.js +77 -67
- package/dist/patterns/table/table.d.ts +9 -9
- package/dist/patterns/table/table.d.ts.map +1 -1
- package/dist/patterns/table/table.js +146 -73
- package/dist/patterns/tree-view/tree-view.d.ts.map +1 -1
- package/dist/patterns/tree-view/tree-view.js +32 -38
- package/dist/primitives/button/button-utility.d.ts +43 -0
- package/dist/primitives/button/button-utility.d.ts.map +1 -0
- package/dist/primitives/button/button-utility.js +79 -0
- package/dist/primitives/button/index.d.ts +2 -1
- package/dist/primitives/button/index.d.ts.map +1 -1
- package/dist/primitives/custom-icon/custom-icon.d.ts +14 -0
- package/dist/primitives/custom-icon/custom-icon.d.ts.map +1 -0
- package/dist/primitives/custom-icon/custom-icon.js +29 -0
- package/dist/primitives/custom-icon/icons/Placeholder.d.ts +10 -0
- package/dist/primitives/custom-icon/icons/Placeholder.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/Placeholder.js +39 -0
- package/dist/primitives/custom-icon/icons/activity-outline.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/activity-outline.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/activity-outline.js +34 -0
- package/dist/primitives/custom-icon/icons/activity-solid.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/activity-solid.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/activity-solid.js +43 -0
- package/dist/primitives/custom-icon/icons/ai-extraction.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/ai-extraction.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/ai-extraction.js +42 -0
- package/dist/primitives/custom-icon/icons/apps.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/apps.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/apps.js +54 -0
- package/dist/primitives/custom-icon/icons/arrows-rl.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/arrows-rl.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/arrows-rl.js +34 -0
- package/dist/primitives/custom-icon/icons/auto-number.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/auto-number.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/auto-number.js +34 -0
- package/dist/primitives/custom-icon/icons/branch-01.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/branch-01.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/branch-01.js +34 -0
- package/dist/primitives/custom-icon/icons/branch-02.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/branch-02.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/branch-02.js +34 -0
- package/dist/primitives/custom-icon/icons/branch.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/branch.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/branch.js +31 -0
- package/dist/primitives/custom-icon/icons/calendar.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/calendar.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/calendar.js +42 -0
- package/dist/primitives/custom-icon/icons/callable.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/callable.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/callable.js +31 -0
- package/dist/primitives/custom-icon/icons/check-circle-broken-outline.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/check-circle-broken-outline.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/check-circle-broken-outline.js +46 -0
- package/dist/primitives/custom-icon/icons/check-circle-broken-solid.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/check-circle-broken-solid.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/check-circle-broken-solid.js +31 -0
- package/dist/primitives/custom-icon/icons/check-circle-broken-solid1.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/check-circle-broken-solid1.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/check-circle-broken-solid1.js +43 -0
- package/dist/primitives/custom-icon/icons/clear-cure.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/clear-cure.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/clear-cure.js +44 -0
- package/dist/primitives/custom-icon/icons/code-node.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/code-node.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/code-node.js +33 -0
- package/dist/primitives/custom-icon/icons/collapse-left.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/collapse-left.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/collapse-left.js +34 -0
- package/dist/primitives/custom-icon/icons/collapse-right.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/collapse-right.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/collapse-right.js +34 -0
- package/dist/primitives/custom-icon/icons/file-04-outline.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/file-04-outline.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/file-04-outline.js +34 -0
- package/dist/primitives/custom-icon/icons/file-04-solid.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/file-04-solid.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/file-04-solid.js +33 -0
- package/dist/primitives/custom-icon/icons/file-edit.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/file-edit.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/file-edit.js +34 -0
- package/dist/primitives/custom-icon/icons/file-manager.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/file-manager.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/file-manager.js +31 -0
- package/dist/primitives/custom-icon/icons/formula.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/formula.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/formula.js +34 -0
- package/dist/primitives/custom-icon/icons/grid-plus.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/grid-plus.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/grid-plus.js +34 -0
- package/dist/primitives/custom-icon/icons/high.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/high.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/high.js +34 -0
- package/dist/primitives/custom-icon/icons/http-endpoint.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/http-endpoint.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/http-endpoint.js +31 -0
- package/dist/primitives/custom-icon/icons/if-else.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/if-else.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/if-else.js +31 -0
- package/dist/primitives/custom-icon/icons/integer.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/integer.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/integer.js +34 -0
- package/dist/primitives/custom-icon/icons/loop.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/loop.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/loop.js +56 -0
- package/dist/primitives/custom-icon/icons/low.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/low.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/low.js +34 -0
- package/dist/primitives/custom-icon/icons/mail-01-outline.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/mail-01-outline.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/mail-01-outline.js +34 -0
- package/dist/primitives/custom-icon/icons/mail-01-solid.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/mail-01-solid.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/mail-01-solid.js +40 -0
- package/dist/primitives/custom-icon/icons/medium.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/medium.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/medium.js +34 -0
- package/dist/primitives/custom-icon/icons/message-dots-square-outline.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/message-dots-square-outline.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/message-dots-square-outline.js +34 -0
- package/dist/primitives/custom-icon/icons/message-dots-square-solid.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/message-dots-square-solid.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/message-dots-square-solid.js +36 -0
- package/dist/primitives/custom-icon/icons/navigate.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/navigate.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/navigate.js +34 -0
- package/dist/primitives/custom-icon/icons/nesting-arrow-closed.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/nesting-arrow-closed.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/nesting-arrow-closed.js +31 -0
- package/dist/primitives/custom-icon/icons/nesting-arrow-open.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/nesting-arrow-open.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/nesting-arrow-open.js +31 -0
- package/dist/primitives/custom-icon/icons/object-manager.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/object-manager.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/object-manager.js +56 -0
- package/dist/primitives/custom-icon/icons/pibit-ai-solid.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/pibit-ai-solid.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/pibit-ai-solid.js +36 -0
- package/dist/primitives/custom-icon/icons/plus-circle-solid.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/plus-circle-solid.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/plus-circle-solid.js +36 -0
- package/dist/primitives/custom-icon/icons/radio.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/radio.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/radio.js +47 -0
- package/dist/primitives/custom-icon/icons/resize.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/resize.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/resize.js +34 -0
- package/dist/primitives/custom-icon/icons/stop-circle.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/stop-circle.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/stop-circle.js +42 -0
- package/dist/primitives/custom-icon/icons/submission.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/submission.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/submission.js +31 -0
- package/dist/primitives/custom-icon/icons/swap.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/swap.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/swap.js +34 -0
- package/dist/primitives/custom-icon/icons/thumbs-down-solid.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/thumbs-down-solid.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/thumbs-down-solid.js +40 -0
- package/dist/primitives/custom-icon/icons/thumbs-down.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/thumbs-down.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/thumbs-down.js +34 -0
- package/dist/primitives/custom-icon/icons/thumbs-up-solid.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/thumbs-up-solid.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/thumbs-up-solid.js +40 -0
- package/dist/primitives/custom-icon/icons/thumbs-up.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/thumbs-up.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/thumbs-up.js +34 -0
- package/dist/primitives/custom-icon/icons/variable-node.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/variable-node.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/variable-node.js +42 -0
- package/dist/primitives/custom-icon/icons/webhook.d.ts +6 -0
- package/dist/primitives/custom-icon/icons/webhook.d.ts.map +1 -0
- package/dist/primitives/custom-icon/icons/webhook.js +47 -0
- package/dist/primitives/custom-icon/index.d.ts +3 -0
- package/dist/primitives/custom-icon/index.d.ts.map +1 -0
- package/dist/primitives/custom-icon/registry.d.ts +110 -0
- package/dist/primitives/custom-icon/registry.d.ts.map +1 -0
- package/dist/primitives/custom-icon/registry.js +111 -0
- package/dist/primitives/heading/heading.d.ts +1 -1
- package/dist/primitives/input/hint-text.d.ts +15 -0
- package/dist/primitives/input/hint-text.d.ts.map +1 -0
- package/dist/primitives/input/hint-text.js +31 -0
- package/dist/primitives/input/input.d.ts +72 -27
- package/dist/primitives/input/input.d.ts.map +1 -1
- package/dist/primitives/input/input.js +385 -74
- package/dist/primitives/input/label.d.ts +15 -0
- package/dist/primitives/input/label.d.ts.map +1 -0
- package/dist/primitives/input/label.js +56 -0
- package/dist/primitives/select/ExpandableSearchInput.d.ts +15 -0
- package/dist/primitives/select/ExpandableSearchInput.d.ts.map +1 -0
- package/dist/primitives/select/ExpandableSearchInput.js +115 -0
- package/dist/primitives/select/SearchInput.d.ts +26 -0
- package/dist/primitives/select/SearchInput.d.ts.map +1 -0
- package/dist/primitives/select/SearchInput.js +136 -0
- package/dist/primitives/select/combobox.d.ts +14 -0
- package/dist/primitives/select/combobox.d.ts.map +1 -0
- package/dist/primitives/select/combobox.js +231 -0
- package/dist/primitives/select/index.d.ts +6 -0
- package/dist/primitives/select/index.d.ts.map +1 -0
- package/dist/primitives/select/multi-select.d.ts +46 -0
- package/dist/primitives/select/multi-select.d.ts.map +1 -0
- package/dist/primitives/select/multi-select.js +306 -0
- package/dist/primitives/select/popover.d.ts +7 -0
- package/dist/primitives/select/popover.d.ts.map +1 -0
- package/dist/primitives/select/popover.js +23 -0
- package/dist/primitives/select/searchable-select.d.ts +35 -0
- package/dist/primitives/select/searchable-select.d.ts.map +1 -0
- package/dist/primitives/select/searchable-select.js +239 -0
- package/dist/primitives/select/select-item.d.ts +8 -0
- package/dist/primitives/select/select-item.d.ts.map +1 -0
- package/dist/primitives/select/select-item.js +108 -0
- package/dist/primitives/select/select-native.d.ts +14 -0
- package/dist/primitives/select/select-native.d.ts.map +1 -0
- package/dist/primitives/select/select.d.ts +61 -0
- package/dist/primitives/select/select.d.ts.map +1 -0
- package/dist/primitives/select/select.js +208 -0
- package/dist/primitives/tags/base-components/tag-close-x.d.ts +9 -0
- package/dist/primitives/tags/base-components/tag-close-x.d.ts.map +1 -0
- package/dist/primitives/tags/base-components/tag-close-x.js +35 -0
- package/dist/primitives/text/text.d.ts +1 -1
- package/dist/primitives/tooltip/index.d.ts +2 -0
- package/dist/primitives/tooltip/index.d.ts.map +1 -0
- package/dist/primitives/tooltip/tooltip.d.ts +35 -0
- package/dist/primitives/tooltip/tooltip.d.ts.map +1 -0
- package/dist/primitives/tooltip/tooltip.js +104 -0
- package/dist/styles/components.css +1 -1
- package/package.json +1 -2
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { hex as p } from "../../value/types/color/hex.js";
|
|
2
|
+
import { hsla as l } from "../../value/types/color/hsla.js";
|
|
3
|
+
import { hslaToRgba as c } from "../../value/types/color/hsla-to-rgba.js";
|
|
4
|
+
import { rgba as s } from "../../value/types/color/rgba.js";
|
|
5
|
+
import { mixImmediate as f } from "./immediate.js";
|
|
6
|
+
import { mixNumber as u } from "./number.js";
|
|
7
|
+
import { warning as d } from "../../../../../motion-utils/dist/es/errors.js";
|
|
8
|
+
const m = (r, o, e) => {
|
|
9
|
+
const t = r * r, n = e * (o * o - t) + t;
|
|
10
|
+
return n < 0 ? 0 : Math.sqrt(n);
|
|
11
|
+
}, b = [p, s, l], h = (r) => b.find((o) => o.test(r));
|
|
12
|
+
function i(r) {
|
|
13
|
+
const o = h(r);
|
|
14
|
+
if (d(!!o, `'${r}' is not an animatable color. Use the equivalent color code instead.`, "color-not-animatable"), !o)
|
|
15
|
+
return !1;
|
|
16
|
+
let e = o.parse(r);
|
|
17
|
+
return o === l && (e = c(e)), e;
|
|
18
|
+
}
|
|
19
|
+
const G = (r, o) => {
|
|
20
|
+
const e = i(r), t = i(o);
|
|
21
|
+
if (!e || !t)
|
|
22
|
+
return f(r, o);
|
|
23
|
+
const n = { ...e };
|
|
24
|
+
return (a) => (n.red = m(e.red, t.red, a), n.green = m(e.green, t.green, a), n.blue = m(e.blue, t.blue, a), n.alpha = u(e.alpha, t.alpha, a), s.transform(n));
|
|
25
|
+
};
|
|
26
|
+
export {
|
|
27
|
+
G as mixColor,
|
|
28
|
+
m as mixLinearColor
|
|
29
|
+
};
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { isCSSVariableToken as d } from "../../animation/utils/is-css-variable.js";
|
|
2
|
+
import { color as u } from "../../value/types/color/index.js";
|
|
3
|
+
import { complex as h, analyseComplexValue as m } from "../../value/types/complex/index.js";
|
|
4
|
+
import { mixColor as a } from "./color.js";
|
|
5
|
+
import { mixImmediate as l } from "./immediate.js";
|
|
6
|
+
import { mixNumber as b } from "./number.js";
|
|
7
|
+
import { invisibleValues as c, mixVisibility as y } from "./visibility.js";
|
|
8
|
+
import { pipe as v } from "../../../../../motion-utils/dist/es/pipe.js";
|
|
9
|
+
import { warning as g } from "../../../../../motion-utils/dist/es/errors.js";
|
|
10
|
+
function V(e, t) {
|
|
11
|
+
return (r) => b(e, t, r);
|
|
12
|
+
}
|
|
13
|
+
function f(e) {
|
|
14
|
+
return typeof e == "number" ? V : typeof e == "string" ? d(e) ? l : u.test(e) ? a : I : Array.isArray(e) ? p : typeof e == "object" ? u.test(e) ? a : C : l;
|
|
15
|
+
}
|
|
16
|
+
function p(e, t) {
|
|
17
|
+
const r = [...e], o = r.length, n = e.map((i, s) => f(i)(i, t[s]));
|
|
18
|
+
return (i) => {
|
|
19
|
+
for (let s = 0; s < o; s++)
|
|
20
|
+
r[s] = n[s](i);
|
|
21
|
+
return r;
|
|
22
|
+
};
|
|
23
|
+
}
|
|
24
|
+
function C(e, t) {
|
|
25
|
+
const r = { ...e, ...t }, o = {};
|
|
26
|
+
for (const n in r)
|
|
27
|
+
e[n] !== void 0 && t[n] !== void 0 && (o[n] = f(e[n])(e[n], t[n]));
|
|
28
|
+
return (n) => {
|
|
29
|
+
for (const i in o)
|
|
30
|
+
r[i] = o[i](n);
|
|
31
|
+
return r;
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
function k(e, t) {
|
|
35
|
+
const r = [], o = { color: 0, var: 0, number: 0 };
|
|
36
|
+
for (let n = 0; n < t.values.length; n++) {
|
|
37
|
+
const i = t.types[n], s = e.indexes[i][o[i]], x = e.values[s] ?? 0;
|
|
38
|
+
r[n] = x, o[i]++;
|
|
39
|
+
}
|
|
40
|
+
return r;
|
|
41
|
+
}
|
|
42
|
+
const I = (e, t) => {
|
|
43
|
+
const r = h.createTransformer(t), o = m(e), n = m(t);
|
|
44
|
+
return o.indexes.var.length === n.indexes.var.length && o.indexes.color.length === n.indexes.color.length && o.indexes.number.length >= n.indexes.number.length ? c.has(e) && !n.values.length || c.has(t) && !o.values.length ? y(e, t) : v(p(k(o, n), n.values), r) : (g(!0, `Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`, "complex-values-different"), l(e, t));
|
|
45
|
+
};
|
|
46
|
+
export {
|
|
47
|
+
f as getMixer,
|
|
48
|
+
p as mixArray,
|
|
49
|
+
I as mixComplex,
|
|
50
|
+
C as mixObject
|
|
51
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
function s(n, r, f) {
|
|
2
|
+
if (n == null)
|
|
3
|
+
return [];
|
|
4
|
+
if (n instanceof EventTarget)
|
|
5
|
+
return [n];
|
|
6
|
+
if (typeof n == "string") {
|
|
7
|
+
let u = document;
|
|
8
|
+
const i = (f == null ? void 0 : f[n]) ?? u.querySelectorAll(n);
|
|
9
|
+
return i ? Array.from(i) : [];
|
|
10
|
+
}
|
|
11
|
+
return Array.from(n).filter((u) => u != null);
|
|
12
|
+
}
|
|
13
|
+
export {
|
|
14
|
+
s as resolveElements
|
|
15
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { memoSupports as e } from "./memo.js";
|
|
2
|
+
const a = /* @__PURE__ */ e(() => {
|
|
3
|
+
try {
|
|
4
|
+
document.createElement("div").animate({ opacity: 0 }, { easing: "linear(0, 1)" });
|
|
5
|
+
} catch {
|
|
6
|
+
return !1;
|
|
7
|
+
}
|
|
8
|
+
return !0;
|
|
9
|
+
}, "linearEasing");
|
|
10
|
+
export {
|
|
11
|
+
a as supportsLinearEasing
|
|
12
|
+
};
|
|
@@ -0,0 +1,215 @@
|
|
|
1
|
+
import { time as n } from "../frameloop/sync-time.js";
|
|
2
|
+
import { frame as d } from "../frameloop/frame.js";
|
|
3
|
+
import { warnOnce as c } from "../../../../motion-utils/dist/es/warn-once.js";
|
|
4
|
+
import { SubscriptionManager as p } from "../../../../motion-utils/dist/es/subscription-manager.js";
|
|
5
|
+
import { velocityPerSecond as u } from "../../../../motion-utils/dist/es/velocity-per-second.js";
|
|
6
|
+
const a = 30, f = (s) => !isNaN(parseFloat(s));
|
|
7
|
+
class l {
|
|
8
|
+
/**
|
|
9
|
+
* @param init - The initiating value
|
|
10
|
+
* @param config - Optional configuration options
|
|
11
|
+
*
|
|
12
|
+
* - `transformer`: A function to transform incoming values with.
|
|
13
|
+
*/
|
|
14
|
+
constructor(t, e = {}) {
|
|
15
|
+
this.canTrackVelocity = null, this.events = {}, this.updateAndNotify = (i) => {
|
|
16
|
+
var r;
|
|
17
|
+
const h = n.now();
|
|
18
|
+
if (this.updatedAt !== h && this.setPrevFrameValue(), this.prev = this.current, this.setCurrent(i), this.current !== this.prev && ((r = this.events.change) == null || r.notify(this.current), this.dependents))
|
|
19
|
+
for (const o of this.dependents)
|
|
20
|
+
o.dirty();
|
|
21
|
+
}, this.hasAnimated = !1, this.setCurrent(t), this.owner = e.owner;
|
|
22
|
+
}
|
|
23
|
+
setCurrent(t) {
|
|
24
|
+
this.current = t, this.updatedAt = n.now(), this.canTrackVelocity === null && t !== void 0 && (this.canTrackVelocity = f(this.current));
|
|
25
|
+
}
|
|
26
|
+
setPrevFrameValue(t = this.current) {
|
|
27
|
+
this.prevFrameValue = t, this.prevUpdatedAt = this.updatedAt;
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Adds a function that will be notified when the `MotionValue` is updated.
|
|
31
|
+
*
|
|
32
|
+
* It returns a function that, when called, will cancel the subscription.
|
|
33
|
+
*
|
|
34
|
+
* When calling `onChange` inside a React component, it should be wrapped with the
|
|
35
|
+
* `useEffect` hook. As it returns an unsubscribe function, this should be returned
|
|
36
|
+
* from the `useEffect` function to ensure you don't add duplicate subscribers..
|
|
37
|
+
*
|
|
38
|
+
* ```jsx
|
|
39
|
+
* export const MyComponent = () => {
|
|
40
|
+
* const x = useMotionValue(0)
|
|
41
|
+
* const y = useMotionValue(0)
|
|
42
|
+
* const opacity = useMotionValue(1)
|
|
43
|
+
*
|
|
44
|
+
* useEffect(() => {
|
|
45
|
+
* function updateOpacity() {
|
|
46
|
+
* const maxXY = Math.max(x.get(), y.get())
|
|
47
|
+
* const newOpacity = transform(maxXY, [0, 100], [1, 0])
|
|
48
|
+
* opacity.set(newOpacity)
|
|
49
|
+
* }
|
|
50
|
+
*
|
|
51
|
+
* const unsubscribeX = x.on("change", updateOpacity)
|
|
52
|
+
* const unsubscribeY = y.on("change", updateOpacity)
|
|
53
|
+
*
|
|
54
|
+
* return () => {
|
|
55
|
+
* unsubscribeX()
|
|
56
|
+
* unsubscribeY()
|
|
57
|
+
* }
|
|
58
|
+
* }, [])
|
|
59
|
+
*
|
|
60
|
+
* return <motion.div style={{ x }} />
|
|
61
|
+
* }
|
|
62
|
+
* ```
|
|
63
|
+
*
|
|
64
|
+
* @param subscriber - A function that receives the latest value.
|
|
65
|
+
* @returns A function that, when called, will cancel this subscription.
|
|
66
|
+
*
|
|
67
|
+
* @deprecated
|
|
68
|
+
*/
|
|
69
|
+
onChange(t) {
|
|
70
|
+
return process.env.NODE_ENV !== "production" && c(!1, 'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'), this.on("change", t);
|
|
71
|
+
}
|
|
72
|
+
on(t, e) {
|
|
73
|
+
this.events[t] || (this.events[t] = new p());
|
|
74
|
+
const i = this.events[t].add(e);
|
|
75
|
+
return t === "change" ? () => {
|
|
76
|
+
i(), d.read(() => {
|
|
77
|
+
this.events.change.getSize() || this.stop();
|
|
78
|
+
});
|
|
79
|
+
} : i;
|
|
80
|
+
}
|
|
81
|
+
clearListeners() {
|
|
82
|
+
for (const t in this.events)
|
|
83
|
+
this.events[t].clear();
|
|
84
|
+
}
|
|
85
|
+
/**
|
|
86
|
+
* Attaches a passive effect to the `MotionValue`.
|
|
87
|
+
*/
|
|
88
|
+
attach(t, e) {
|
|
89
|
+
this.passiveEffect = t, this.stopPassiveEffect = e;
|
|
90
|
+
}
|
|
91
|
+
/**
|
|
92
|
+
* Sets the state of the `MotionValue`.
|
|
93
|
+
*
|
|
94
|
+
* @remarks
|
|
95
|
+
*
|
|
96
|
+
* ```jsx
|
|
97
|
+
* const x = useMotionValue(0)
|
|
98
|
+
* x.set(10)
|
|
99
|
+
* ```
|
|
100
|
+
*
|
|
101
|
+
* @param latest - Latest value to set.
|
|
102
|
+
* @param render - Whether to notify render subscribers. Defaults to `true`
|
|
103
|
+
*
|
|
104
|
+
* @public
|
|
105
|
+
*/
|
|
106
|
+
set(t) {
|
|
107
|
+
this.passiveEffect ? this.passiveEffect(t, this.updateAndNotify) : this.updateAndNotify(t);
|
|
108
|
+
}
|
|
109
|
+
setWithVelocity(t, e, i) {
|
|
110
|
+
this.set(e), this.prev = void 0, this.prevFrameValue = t, this.prevUpdatedAt = this.updatedAt - i;
|
|
111
|
+
}
|
|
112
|
+
/**
|
|
113
|
+
* Set the state of the `MotionValue`, stopping any active animations,
|
|
114
|
+
* effects, and resets velocity to `0`.
|
|
115
|
+
*/
|
|
116
|
+
jump(t, e = !0) {
|
|
117
|
+
this.updateAndNotify(t), this.prev = t, this.prevUpdatedAt = this.prevFrameValue = void 0, e && this.stop(), this.stopPassiveEffect && this.stopPassiveEffect();
|
|
118
|
+
}
|
|
119
|
+
dirty() {
|
|
120
|
+
var t;
|
|
121
|
+
(t = this.events.change) == null || t.notify(this.current);
|
|
122
|
+
}
|
|
123
|
+
addDependent(t) {
|
|
124
|
+
this.dependents || (this.dependents = /* @__PURE__ */ new Set()), this.dependents.add(t);
|
|
125
|
+
}
|
|
126
|
+
removeDependent(t) {
|
|
127
|
+
this.dependents && this.dependents.delete(t);
|
|
128
|
+
}
|
|
129
|
+
/**
|
|
130
|
+
* Returns the latest state of `MotionValue`
|
|
131
|
+
*
|
|
132
|
+
* @returns - The latest state of `MotionValue`
|
|
133
|
+
*
|
|
134
|
+
* @public
|
|
135
|
+
*/
|
|
136
|
+
get() {
|
|
137
|
+
return this.current;
|
|
138
|
+
}
|
|
139
|
+
/**
|
|
140
|
+
* @public
|
|
141
|
+
*/
|
|
142
|
+
getPrevious() {
|
|
143
|
+
return this.prev;
|
|
144
|
+
}
|
|
145
|
+
/**
|
|
146
|
+
* Returns the latest velocity of `MotionValue`
|
|
147
|
+
*
|
|
148
|
+
* @returns - The latest velocity of `MotionValue`. Returns `0` if the state is non-numerical.
|
|
149
|
+
*
|
|
150
|
+
* @public
|
|
151
|
+
*/
|
|
152
|
+
getVelocity() {
|
|
153
|
+
const t = n.now();
|
|
154
|
+
if (!this.canTrackVelocity || this.prevFrameValue === void 0 || t - this.updatedAt > a)
|
|
155
|
+
return 0;
|
|
156
|
+
const e = Math.min(this.updatedAt - this.prevUpdatedAt, a);
|
|
157
|
+
return u(parseFloat(this.current) - parseFloat(this.prevFrameValue), e);
|
|
158
|
+
}
|
|
159
|
+
/**
|
|
160
|
+
* Registers a new animation to control this `MotionValue`. Only one
|
|
161
|
+
* animation can drive a `MotionValue` at one time.
|
|
162
|
+
*
|
|
163
|
+
* ```jsx
|
|
164
|
+
* value.start()
|
|
165
|
+
* ```
|
|
166
|
+
*
|
|
167
|
+
* @param animation - A function that starts the provided animation
|
|
168
|
+
*/
|
|
169
|
+
start(t) {
|
|
170
|
+
return this.stop(), new Promise((e) => {
|
|
171
|
+
this.hasAnimated = !0, this.animation = t(e), this.events.animationStart && this.events.animationStart.notify();
|
|
172
|
+
}).then(() => {
|
|
173
|
+
this.events.animationComplete && this.events.animationComplete.notify(), this.clearAnimation();
|
|
174
|
+
});
|
|
175
|
+
}
|
|
176
|
+
/**
|
|
177
|
+
* Stop the currently active animation.
|
|
178
|
+
*
|
|
179
|
+
* @public
|
|
180
|
+
*/
|
|
181
|
+
stop() {
|
|
182
|
+
this.animation && (this.animation.stop(), this.events.animationCancel && this.events.animationCancel.notify()), this.clearAnimation();
|
|
183
|
+
}
|
|
184
|
+
/**
|
|
185
|
+
* Returns `true` if this value is currently animating.
|
|
186
|
+
*
|
|
187
|
+
* @public
|
|
188
|
+
*/
|
|
189
|
+
isAnimating() {
|
|
190
|
+
return !!this.animation;
|
|
191
|
+
}
|
|
192
|
+
clearAnimation() {
|
|
193
|
+
delete this.animation;
|
|
194
|
+
}
|
|
195
|
+
/**
|
|
196
|
+
* Destroy and clean up subscribers to this `MotionValue`.
|
|
197
|
+
*
|
|
198
|
+
* The `MotionValue` hooks like `useMotionValue` and `useTransform` automatically
|
|
199
|
+
* handle the lifecycle of the returned `MotionValue`, so this method is only necessary if you've manually
|
|
200
|
+
* created a `MotionValue` via the `motionValue` function.
|
|
201
|
+
*
|
|
202
|
+
* @public
|
|
203
|
+
*/
|
|
204
|
+
destroy() {
|
|
205
|
+
var t, e;
|
|
206
|
+
(t = this.dependents) == null || t.clear(), (e = this.events.destroy) == null || e.notify(), this.clearListeners(), this.stop(), this.stopPassiveEffect && this.stopPassiveEffect();
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
function g(s, t) {
|
|
210
|
+
return new l(s, t);
|
|
211
|
+
}
|
|
212
|
+
export {
|
|
213
|
+
l as MotionValue,
|
|
214
|
+
g as motionValue
|
|
215
|
+
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { rgba as i } from "./rgba.js";
|
|
2
|
+
import { isColorString as g } from "./utils.js";
|
|
3
|
+
function a(r) {
|
|
4
|
+
let t = "", e = "", n = "", s = "";
|
|
5
|
+
return r.length > 5 ? (t = r.substring(1, 3), e = r.substring(3, 5), n = r.substring(5, 7), s = r.substring(7, 9)) : (t = r.substring(1, 2), e = r.substring(2, 3), n = r.substring(3, 4), s = r.substring(4, 5), t += t, e += e, n += n, s += s), {
|
|
6
|
+
red: parseInt(t, 16),
|
|
7
|
+
green: parseInt(e, 16),
|
|
8
|
+
blue: parseInt(n, 16),
|
|
9
|
+
alpha: s ? parseInt(s, 16) / 255 : 1
|
|
10
|
+
};
|
|
11
|
+
}
|
|
12
|
+
const u = {
|
|
13
|
+
test: /* @__PURE__ */ g("#"),
|
|
14
|
+
parse: a,
|
|
15
|
+
transform: i.transform
|
|
16
|
+
};
|
|
17
|
+
export {
|
|
18
|
+
u as hex
|
|
19
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
function c(e, f, r) {
|
|
2
|
+
return r < 0 && (r += 1), r > 1 && (r -= 1), r < 1 / 6 ? e + (f - e) * 6 * r : r < 1 / 2 ? f : r < 2 / 3 ? e + (f - e) * (2 / 3 - r) * 6 : e;
|
|
3
|
+
}
|
|
4
|
+
function R({ hue: e, saturation: f, lightness: r, alpha: M }) {
|
|
5
|
+
e /= 360, f /= 100, r /= 100;
|
|
6
|
+
let o = 0, u = 0, d = 0;
|
|
7
|
+
if (!f)
|
|
8
|
+
o = u = d = r;
|
|
9
|
+
else {
|
|
10
|
+
const n = r < 0.5 ? r * (1 + f) : r + f - r * f, b = 2 * r - n;
|
|
11
|
+
o = c(b, n, e + 1 / 3), u = c(b, n, e), d = c(b, n, e - 1 / 3);
|
|
12
|
+
}
|
|
13
|
+
return {
|
|
14
|
+
red: Math.round(o * 255),
|
|
15
|
+
green: Math.round(u * 255),
|
|
16
|
+
blue: Math.round(d * 255),
|
|
17
|
+
alpha: M
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
export {
|
|
21
|
+
R as hslaToRgba
|
|
22
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { alpha as n } from "../numbers/index.js";
|
|
2
|
+
import { percent as t } from "../numbers/units.js";
|
|
3
|
+
import { sanitize as r } from "../utils/sanitize.js";
|
|
4
|
+
import { isColorString as i, splitColor as e } from "./utils.js";
|
|
5
|
+
const u = {
|
|
6
|
+
test: /* @__PURE__ */ i("hsl", "hue"),
|
|
7
|
+
parse: /* @__PURE__ */ e("hue", "saturation", "lightness"),
|
|
8
|
+
transform: ({ hue: o, saturation: s, lightness: a, alpha: m = 1 }) => "hsla(" + Math.round(o) + ", " + t.transform(r(s)) + ", " + t.transform(r(a)) + ", " + r(n.transform(m)) + ")"
|
|
9
|
+
};
|
|
10
|
+
export {
|
|
11
|
+
u as hsla
|
|
12
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { hex as o } from "./hex.js";
|
|
2
|
+
import { hsla as t } from "./hsla.js";
|
|
3
|
+
import { rgba as e } from "./rgba.js";
|
|
4
|
+
const a = {
|
|
5
|
+
test: (r) => e.test(r) || o.test(r) || t.test(r),
|
|
6
|
+
parse: (r) => e.test(r) ? e.parse(r) : t.test(r) ? t.parse(r) : o.parse(r),
|
|
7
|
+
transform: (r) => typeof r == "string" ? r : r.hasOwnProperty("red") ? e.transform(r) : t.transform(r),
|
|
8
|
+
getAnimatableNone: (r) => {
|
|
9
|
+
const s = a.parse(r);
|
|
10
|
+
return s.alpha = 0, a.transform(s);
|
|
11
|
+
}
|
|
12
|
+
};
|
|
13
|
+
export {
|
|
14
|
+
a as color
|
|
15
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { number as n, alpha as s } from "../numbers/index.js";
|
|
2
|
+
import { sanitize as i } from "../utils/sanitize.js";
|
|
3
|
+
import { isColorString as p, splitColor as e } from "./utils.js";
|
|
4
|
+
import { clamp as f } from "../../../../../../motion-utils/dist/es/clamp.js";
|
|
5
|
+
const l = (r) => f(0, 255, r), o = {
|
|
6
|
+
...n,
|
|
7
|
+
transform: (r) => Math.round(l(r))
|
|
8
|
+
}, h = {
|
|
9
|
+
test: /* @__PURE__ */ p("rgb", "red"),
|
|
10
|
+
parse: /* @__PURE__ */ e("red", "green", "blue"),
|
|
11
|
+
transform: ({ red: r, green: t, blue: a, alpha: m = 1 }) => "rgba(" + o.transform(r) + ", " + o.transform(t) + ", " + o.transform(a) + ", " + i(s.transform(m)) + ")"
|
|
12
|
+
};
|
|
13
|
+
export {
|
|
14
|
+
o as rgbUnit,
|
|
15
|
+
h as rgba
|
|
16
|
+
};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { floatRegex as i } from "../utils/float-regex.js";
|
|
2
|
+
import { isNullish as n } from "../utils/is-nullish.js";
|
|
3
|
+
import { singleColorRegex as f } from "../utils/single-color-regex.js";
|
|
4
|
+
const h = (r, o) => (t) => !!(typeof t == "string" && f.test(t) && t.startsWith(r) || o && !n(t) && Object.prototype.hasOwnProperty.call(t, o)), u = (r, o, t) => (e) => {
|
|
5
|
+
if (typeof e != "string")
|
|
6
|
+
return e;
|
|
7
|
+
const [l, s, p, a] = e.match(i);
|
|
8
|
+
return {
|
|
9
|
+
[r]: parseFloat(l),
|
|
10
|
+
[o]: parseFloat(s),
|
|
11
|
+
[t]: parseFloat(p),
|
|
12
|
+
alpha: a !== void 0 ? parseFloat(a) : 1
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
export {
|
|
16
|
+
h as isColorString,
|
|
17
|
+
u as splitColor
|
|
18
|
+
};
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { complex as c } from "./index.js";
|
|
2
|
+
import { floatRegex as i } from "../utils/float-regex.js";
|
|
3
|
+
const s = /* @__PURE__ */ new Set(["brightness", "contrast", "saturate", "opacity"]);
|
|
4
|
+
function u(t) {
|
|
5
|
+
const [e, n] = t.slice(0, -1).split("(");
|
|
6
|
+
if (e === "drop-shadow")
|
|
7
|
+
return t;
|
|
8
|
+
const [o] = n.match(i) || [];
|
|
9
|
+
if (!o)
|
|
10
|
+
return t;
|
|
11
|
+
const r = n.replace(o, "");
|
|
12
|
+
let a = s.has(e) ? 1 : 0;
|
|
13
|
+
return o !== n && (a *= 100), e + "(" + a + r + ")";
|
|
14
|
+
}
|
|
15
|
+
const l = /\b([a-z-]*)\(.*?\)/gu, p = {
|
|
16
|
+
...c,
|
|
17
|
+
getAnimatableNone: (t) => {
|
|
18
|
+
const e = t.match(l);
|
|
19
|
+
return e ? e.map(u).join(" ") : t;
|
|
20
|
+
}
|
|
21
|
+
};
|
|
22
|
+
export {
|
|
23
|
+
p as filter
|
|
24
|
+
};
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { color as u } from "../color/index.js";
|
|
2
|
+
import { colorRegex as N } from "../utils/color-regex.js";
|
|
3
|
+
import { floatRegex as d } from "../utils/float-regex.js";
|
|
4
|
+
import { sanitize as b } from "../utils/sanitize.js";
|
|
5
|
+
function x(t) {
|
|
6
|
+
var o, e;
|
|
7
|
+
return isNaN(t) && typeof t == "string" && (((o = t.match(d)) == null ? void 0 : o.length) || 0) + (((e = t.match(N)) == null ? void 0 : e.length) || 0) > 0;
|
|
8
|
+
}
|
|
9
|
+
const p = "number", m = "color", T = "var", O = "var(", a = "${}", R = /var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;
|
|
10
|
+
function f(t) {
|
|
11
|
+
const o = t.toString(), e = [], c = {
|
|
12
|
+
color: [],
|
|
13
|
+
number: [],
|
|
14
|
+
var: []
|
|
15
|
+
}, n = [];
|
|
16
|
+
let s = 0;
|
|
17
|
+
const l = o.replace(R, (i) => (u.test(i) ? (c.color.push(s), n.push(m), e.push(u.parse(i))) : i.startsWith(O) ? (c.var.push(s), n.push(T), e.push(i)) : (c.number.push(s), n.push(p), e.push(parseFloat(i))), ++s, a)).split(a);
|
|
18
|
+
return { values: e, split: l, indexes: c, types: n };
|
|
19
|
+
}
|
|
20
|
+
function h(t) {
|
|
21
|
+
return f(t).values;
|
|
22
|
+
}
|
|
23
|
+
function g(t) {
|
|
24
|
+
const { split: o, types: e } = f(t), c = o.length;
|
|
25
|
+
return (n) => {
|
|
26
|
+
let s = "";
|
|
27
|
+
for (let r = 0; r < c; r++)
|
|
28
|
+
if (s += o[r], n[r] !== void 0) {
|
|
29
|
+
const l = e[r];
|
|
30
|
+
l === p ? s += b(n[r]) : l === m ? s += u.transform(n[r]) : s += n[r];
|
|
31
|
+
}
|
|
32
|
+
return s;
|
|
33
|
+
};
|
|
34
|
+
}
|
|
35
|
+
const y = (t) => typeof t == "number" ? 0 : u.test(t) ? u.getAnimatableNone(t) : t;
|
|
36
|
+
function E(t) {
|
|
37
|
+
const o = h(t);
|
|
38
|
+
return g(t)(o.map(y));
|
|
39
|
+
}
|
|
40
|
+
const S = {
|
|
41
|
+
test: x,
|
|
42
|
+
parse: h,
|
|
43
|
+
createTransformer: g,
|
|
44
|
+
getAnimatableNone: E
|
|
45
|
+
};
|
|
46
|
+
export {
|
|
47
|
+
f as analyseComplexValue,
|
|
48
|
+
S as complex
|
|
49
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { auto as o } from "./auto.js";
|
|
2
|
+
import { number as r } from "./numbers/index.js";
|
|
3
|
+
import { px as m, percent as t, degrees as i, vw as n, vh as p } from "./numbers/units.js";
|
|
4
|
+
import { testValueType as s } from "./test.js";
|
|
5
|
+
const f = [r, m, t, i, n, p, o], l = (e) => f.find(s(e));
|
|
6
|
+
export {
|
|
7
|
+
f as dimensionValueTypes,
|
|
8
|
+
l as findDimensionValueType
|
|
9
|
+
};
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { color as o } from "../color/index.js";
|
|
2
|
+
import { filter as r } from "../complex/filter.js";
|
|
3
|
+
import { numberValueTypes as l } from "./number.js";
|
|
4
|
+
const t = {
|
|
5
|
+
...l,
|
|
6
|
+
// Color props
|
|
7
|
+
color: o,
|
|
8
|
+
backgroundColor: o,
|
|
9
|
+
outlineColor: o,
|
|
10
|
+
fill: o,
|
|
11
|
+
stroke: o,
|
|
12
|
+
// Border props
|
|
13
|
+
borderColor: o,
|
|
14
|
+
borderTopColor: o,
|
|
15
|
+
borderRightColor: o,
|
|
16
|
+
borderBottomColor: o,
|
|
17
|
+
borderLeftColor: o,
|
|
18
|
+
filter: r,
|
|
19
|
+
WebkitFilter: r
|
|
20
|
+
}, m = (e) => t[e];
|
|
21
|
+
export {
|
|
22
|
+
t as defaultValueTypes,
|
|
23
|
+
m as getDefaultValueType
|
|
24
|
+
};
|