motion-v 1.0.0-beta.0 → 1.0.0-beta.2
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/cjs/index.js +5 -1
- package/dist/es/components/reorder/Group.vue.mjs +5 -2
- package/dist/es/state/create-visual-element.d.ts +2 -1
- package/dist/es/state/style.mjs +1 -0
- package/dist/es/state/utils.d.ts +2 -4
- package/dist/es/types/common.d.ts +1 -1
- package/dist/nuxt/index.cjs +0 -1
- package/dist/nuxt/index.mjs +0 -1
- package/dist/resolver/index.cjs +0 -1
- package/dist/resolver/index.mjs +0 -1
- package/package.json +1 -1
package/dist/cjs/index.js
CHANGED
|
@@ -6643,6 +6643,7 @@ const SVG_STYLE_TO_ATTRIBUTES = {
|
|
|
6643
6643
|
"fill": true,
|
|
6644
6644
|
"stroke": true,
|
|
6645
6645
|
"opacity": true,
|
|
6646
|
+
"stroke-width": true,
|
|
6646
6647
|
"fill-opacity": true,
|
|
6647
6648
|
"stroke-opacity": true,
|
|
6648
6649
|
"stroke-linecap": true,
|
|
@@ -9201,7 +9202,7 @@ const _sfc_main$3 = /* @__PURE__ */ vue.defineComponent({
|
|
|
9201
9202
|
setup(__props) {
|
|
9202
9203
|
const props = __props;
|
|
9203
9204
|
const { axis } = vue.toRefs(props);
|
|
9204
|
-
|
|
9205
|
+
let order2 = [];
|
|
9205
9206
|
let isReordering = false;
|
|
9206
9207
|
function warning2() {
|
|
9207
9208
|
heyListen.invariant(Boolean(props.values), "Reorder.Group must be provided a values prop");
|
|
@@ -9209,6 +9210,9 @@ const _sfc_main$3 = /* @__PURE__ */ vue.defineComponent({
|
|
|
9209
9210
|
vue.onUpdated(() => {
|
|
9210
9211
|
isReordering = false;
|
|
9211
9212
|
});
|
|
9213
|
+
vue.onBeforeUpdate(() => {
|
|
9214
|
+
order2 = [];
|
|
9215
|
+
});
|
|
9212
9216
|
reorderContextProvider({
|
|
9213
9217
|
axis,
|
|
9214
9218
|
registerItem: (value, layout) => {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent, toRefs, onUpdated, useAttrs, openBlock, createBlock, unref, normalizeProps, guardReactiveProps, withCtx, renderSlot, createTextVNode, toDisplayString } from "vue";
|
|
1
|
+
import { defineComponent, toRefs, onUpdated, onBeforeUpdate, useAttrs, openBlock, createBlock, unref, normalizeProps, guardReactiveProps, withCtx, renderSlot, createTextVNode, toDisplayString } from "vue";
|
|
2
2
|
import { Motion } from "../motion/index.mjs";
|
|
3
3
|
import { invariant } from "hey-listen";
|
|
4
4
|
import { reorderContextProvider } from "./context.mjs";
|
|
@@ -87,7 +87,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
87
87
|
setup(__props) {
|
|
88
88
|
const props = __props;
|
|
89
89
|
const { axis } = toRefs(props);
|
|
90
|
-
|
|
90
|
+
let order = [];
|
|
91
91
|
let isReordering = false;
|
|
92
92
|
function warning() {
|
|
93
93
|
invariant(Boolean(props.values), "Reorder.Group must be provided a values prop");
|
|
@@ -95,6 +95,9 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
95
95
|
onUpdated(() => {
|
|
96
96
|
isReordering = false;
|
|
97
97
|
});
|
|
98
|
+
onBeforeUpdate(() => {
|
|
99
|
+
order = [];
|
|
100
|
+
});
|
|
98
101
|
reorderContextProvider({
|
|
99
102
|
axis,
|
|
100
103
|
registerItem: (value, layout) => {
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
import { AsTag } from '../types';
|
|
2
|
+
export declare function createVisualElement(Component: AsTag, options: any): any;
|
package/dist/es/state/style.mjs
CHANGED
package/dist/es/state/utils.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import { $Transition, Options } from '../types';
|
|
1
|
+
import { $Transition, AsTag, Options } from '../types';
|
|
2
2
|
import { Variant } from 'framer-motion';
|
|
3
|
-
import { IntrinsicElementAttributes } from 'vue';
|
|
4
3
|
export declare function resolveVariant(definition?: Options['animate'], variants?: Options['variants'], custom?: Options['custom']): Variant | undefined;
|
|
5
4
|
export declare function hasChanged(a: any, b: any): boolean;
|
|
6
5
|
export declare function shallowCompare(next: any[], prev: any[]): boolean;
|
|
@@ -10,10 +9,9 @@ export declare function getOptions(options: $Transition, key: string): $Transiti
|
|
|
10
9
|
export declare function isCssVar(name: string): boolean;
|
|
11
10
|
export declare const noopReturn: <V>(v: V) => V;
|
|
12
11
|
export declare function isNumber(value: any): boolean;
|
|
13
|
-
type ElementType = keyof IntrinsicElementAttributes;
|
|
14
12
|
export declare const svgElements: readonly ["animate", "circle", "defs", "desc", "ellipse", "g", "image", "line", "filter", "marker", "mask", "metadata", "path", "pattern", "polygon", "polyline", "rect", "stop", "svg", "switch", "symbol", "text", "tspan", "use", "view", "clipPath", "feBlend", "feColorMatrix", "feComponentTransfer", "feComposite", "feConvolveMatrix", "feDiffuseLighting", "feDisplacementMap", "feDistantLight", "feDropShadow", "feFlood", "feFuncA", "feFuncB", "feFuncG", "feFuncR", "feGaussianBlur", "feImage", "feMerge", "feMergeNode", "feMorphology", "feOffset", "fePointLight", "feSpecularLighting", "feSpotLight", "feTile", "feTurbulence", "foreignObject", "linearGradient", "radialGradient", "textPath"];
|
|
15
13
|
type UnionStringArray<T extends Readonly<string[]>> = T[number];
|
|
16
14
|
export type SVGElements = UnionStringArray<typeof svgElements>;
|
|
17
|
-
export declare function isSVGElement(as:
|
|
15
|
+
export declare function isSVGElement(as: AsTag): as is SVGElements;
|
|
18
16
|
export declare function isAnimateChanged(oldOptions: Options, newOptions: Options): boolean;
|
|
19
17
|
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { Component, DefineComponent, ExtractPropTypes, ExtractPublicPropTypes, IntrinsicElementAttributes } from 'vue';
|
|
2
2
|
export type ComponentProps<T> = T extends DefineComponent<ExtractPropTypes<infer Props>, any, any> ? ExtractPublicPropTypes<Props> : never;
|
|
3
3
|
export type ElementType = keyof IntrinsicElementAttributes;
|
|
4
|
-
export type AsTag = keyof IntrinsicElementAttributes | (
|
|
4
|
+
export type AsTag = keyof IntrinsicElementAttributes | ({} & string) | Component;
|
package/dist/nuxt/index.cjs
CHANGED
package/dist/nuxt/index.mjs
CHANGED
package/dist/resolver/index.cjs
CHANGED
package/dist/resolver/index.mjs
CHANGED