@elementor/editor-props 3.32.0-63 → 3.32.0-65
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/index.d.mts +92 -15
- package/dist/index.d.ts +92 -15
- package/dist/index.js +39 -31
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +38 -31
- package/dist/index.mjs.map +1 -1
- package/package.json +2 -2
- package/src/prop-types/index.ts +5 -4
- package/src/prop-types/transform-prop-types/{move-transform.ts → transform-functions/move-transform.ts} +3 -3
- package/src/prop-types/transform-prop-types/{rotate-transform.ts → transform-functions/rotate-transform.ts} +3 -3
- package/src/prop-types/transform-prop-types/{scale-transform.ts → transform-functions/scale-transform.ts} +3 -3
- package/src/prop-types/transform-prop-types/{skew-transform.ts → transform-functions/skew-transform.ts} +3 -3
- package/src/prop-types/transform-prop-types/transform-functions.ts +18 -0
- package/src/prop-types/transform-prop-types/transform.ts +9 -13
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { z } from '@elementor/schema';
|
|
2
2
|
|
|
3
|
-
import { createPropUtils } from '
|
|
4
|
-
import { unknownChildrenSchema } from '
|
|
5
|
-
import { TransformFunctionKeys } from '
|
|
3
|
+
import { createPropUtils } from '../../../utils/create-prop-utils';
|
|
4
|
+
import { unknownChildrenSchema } from '../../utils';
|
|
5
|
+
import { TransformFunctionKeys } from '../types';
|
|
6
6
|
|
|
7
7
|
export const moveTransformPropTypeUtil = createPropUtils(
|
|
8
8
|
TransformFunctionKeys.move,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { z } from '@elementor/schema';
|
|
2
2
|
|
|
3
|
-
import { createPropUtils } from '
|
|
4
|
-
import { unknownChildrenSchema } from '
|
|
5
|
-
import { TransformFunctionKeys } from '
|
|
3
|
+
import { createPropUtils } from '../../../utils/create-prop-utils';
|
|
4
|
+
import { unknownChildrenSchema } from '../../utils';
|
|
5
|
+
import { TransformFunctionKeys } from '../types';
|
|
6
6
|
|
|
7
7
|
export const rotateTransformPropTypeUtil = createPropUtils(
|
|
8
8
|
TransformFunctionKeys.rotate,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { z } from '@elementor/schema';
|
|
2
2
|
|
|
3
|
-
import { createPropUtils } from '
|
|
4
|
-
import { numberPropTypeUtil } from '
|
|
5
|
-
import { TransformFunctionKeys } from '
|
|
3
|
+
import { createPropUtils } from '../../../utils/create-prop-utils';
|
|
4
|
+
import { numberPropTypeUtil } from '../../number';
|
|
5
|
+
import { TransformFunctionKeys } from '../types';
|
|
6
6
|
|
|
7
7
|
export const scaleTransformPropTypeUtil = createPropUtils(
|
|
8
8
|
TransformFunctionKeys.scale,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { z } from '@elementor/schema';
|
|
2
2
|
|
|
3
|
-
import { createPropUtils } from '
|
|
4
|
-
import { unknownChildrenSchema } from '
|
|
5
|
-
import { TransformFunctionKeys } from '
|
|
3
|
+
import { createPropUtils } from '../../../utils/create-prop-utils';
|
|
4
|
+
import { unknownChildrenSchema } from '../../utils';
|
|
5
|
+
import { TransformFunctionKeys } from '../types';
|
|
6
6
|
|
|
7
7
|
export const skewTransformPropTypeUtil = createPropUtils(
|
|
8
8
|
TransformFunctionKeys.skew,
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { z } from '@elementor/schema';
|
|
2
|
+
|
|
3
|
+
import { createPropUtils } from '../../utils/create-prop-utils';
|
|
4
|
+
import { moveTransformPropTypeUtil } from './transform-functions/move-transform';
|
|
5
|
+
import { rotateTransformPropTypeUtil } from './transform-functions/rotate-transform';
|
|
6
|
+
import { scaleTransformPropTypeUtil } from './transform-functions/scale-transform';
|
|
7
|
+
import { skewTransformPropTypeUtil } from './transform-functions/skew-transform';
|
|
8
|
+
|
|
9
|
+
const filterTypes = moveTransformPropTypeUtil.schema
|
|
10
|
+
.or( scaleTransformPropTypeUtil.schema )
|
|
11
|
+
.or( rotateTransformPropTypeUtil.schema )
|
|
12
|
+
.or( skewTransformPropTypeUtil.schema );
|
|
13
|
+
|
|
14
|
+
export const transformFunctionsPropTypeUtil = createPropUtils( 'transform-functions', z.array( filterTypes ) );
|
|
15
|
+
|
|
16
|
+
export type TransformFunctionsPropValue = z.infer< typeof transformFunctionsPropTypeUtil.schema >;
|
|
17
|
+
|
|
18
|
+
export type TransformFunctionsItemPropValue = z.infer< typeof filterTypes >;
|
|
@@ -1,19 +1,15 @@
|
|
|
1
1
|
import { z } from '@elementor/schema';
|
|
2
2
|
|
|
3
3
|
import { createPropUtils } from '../../utils/create-prop-utils';
|
|
4
|
-
import {
|
|
5
|
-
import { rotateTransformPropTypeUtil } from './rotate-transform';
|
|
6
|
-
import { scaleTransformPropTypeUtil } from './scale-transform';
|
|
7
|
-
import { skewTransformPropTypeUtil } from './skew-transform';
|
|
4
|
+
import { unknownChildrenSchema } from '../utils';
|
|
8
5
|
|
|
9
|
-
const
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
6
|
+
export const transformPropTypeUtil = createPropUtils(
|
|
7
|
+
'transform',
|
|
8
|
+
z.strictObject( {
|
|
9
|
+
'transform-functions': unknownChildrenSchema,
|
|
10
|
+
'transform-origin': unknownChildrenSchema,
|
|
11
|
+
perspective: unknownChildrenSchema,
|
|
12
|
+
} )
|
|
13
|
+
);
|
|
16
14
|
|
|
17
15
|
export type TransformPropValue = z.infer< typeof transformPropTypeUtil.schema >;
|
|
18
|
-
|
|
19
|
-
export type TransformItemPropValue = z.infer< typeof filterTypes >;
|