@supernova-studio/client 0.52.14 → 0.52.16
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 +420 -1
- package/dist/index.d.ts +420 -1
- package/dist/index.js +8 -11
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +7 -10
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/api/dto/elements/components/figma-component.ts +29 -2
package/package.json
CHANGED
|
@@ -1,6 +1,21 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import {
|
|
2
|
+
FigmaComponentBooleanProperty,
|
|
3
|
+
FigmaComponentInstanceSwapProperty,
|
|
4
|
+
FigmaComponentOrigin,
|
|
5
|
+
FigmaComponentProperty,
|
|
6
|
+
FigmaComponentTextProperty,
|
|
7
|
+
FigmaComponentVariantProperty,
|
|
8
|
+
ObjectMeta,
|
|
9
|
+
} from "@supernova-studio/model";
|
|
2
10
|
import { z } from "zod";
|
|
3
11
|
|
|
12
|
+
const DTOFigmaComponentBooleanProperty = FigmaComponentBooleanProperty;
|
|
13
|
+
const DTOFigmaComponentInstanceSwapProperty = FigmaComponentInstanceSwapProperty;
|
|
14
|
+
const DTOFigmaComponentTextProperty = FigmaComponentTextProperty;
|
|
15
|
+
const DTOFigmaComponentVariantProperty = FigmaComponentVariantProperty;
|
|
16
|
+
const DTOFigmaComponentProperty = FigmaComponentProperty;
|
|
17
|
+
const DTOFigmaComponentPropertyMap = z.record(DTOFigmaComponentProperty);
|
|
18
|
+
|
|
4
19
|
export const DTOFigmaComponent = z.object({
|
|
5
20
|
id: z.string(),
|
|
6
21
|
persistentId: z.string(),
|
|
@@ -20,7 +35,19 @@ export const DTOFigmaComponent = z.object({
|
|
|
20
35
|
originComponent: FigmaComponentOrigin.optional(),
|
|
21
36
|
|
|
22
37
|
parentComponentPersistentId: z.string().optional(),
|
|
23
|
-
componentPropertyDefinitions:
|
|
38
|
+
componentPropertyDefinitions: DTOFigmaComponentPropertyMap.optional(),
|
|
39
|
+
});
|
|
40
|
+
|
|
41
|
+
export const DTOFigmaComponentListResponse = z.object({
|
|
42
|
+
components: DTOFigmaComponent.array(),
|
|
24
43
|
});
|
|
25
44
|
|
|
45
|
+
export type DTOFigmaComponentBooleanProperty = z.infer<typeof DTOFigmaComponentBooleanProperty>;
|
|
46
|
+
export type DTOFigmaComponentInstanceSwapProperty = z.infer<typeof DTOFigmaComponentInstanceSwapProperty>;
|
|
47
|
+
export type DTOFigmaComponentTextProperty = z.infer<typeof DTOFigmaComponentTextProperty>;
|
|
48
|
+
export type DTOFigmaComponentVariantProperty = z.infer<typeof DTOFigmaComponentVariantProperty>;
|
|
49
|
+
export type DTOFigmaComponentProperty = z.infer<typeof DTOFigmaComponentProperty>;
|
|
50
|
+
export type DTOFigmaComponentPropertyMap = z.infer<typeof DTOFigmaComponentPropertyMap>;
|
|
51
|
+
|
|
26
52
|
export type DTOFigmaComponent = z.infer<typeof DTOFigmaComponent>;
|
|
53
|
+
export type DTOFigmaComponentListResponse = z.infer<typeof DTOFigmaComponentListResponse>;
|