@plasmicapp/host 1.0.203 → 1.0.204
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/host.esm.js +1 -1
- package/dist/host.esm.js.map +1 -1
- package/dist/index.cjs.js +1 -1
- package/dist/index.cjs.js.map +1 -1
- package/dist/prop-types.d.ts +15 -0
- package/dist/registerComponent.d.ts +6 -12
- package/dist/version.d.ts +1 -1
- package/package.json +2 -2
- package/registerComponent/dist/index.cjs.js.map +1 -1
- package/registerComponent/dist/index.esm.js.map +1 -1
- package/registerComponent/dist/prop-types.d.ts +15 -0
- package/registerComponent/dist/registerComponent.d.ts +6 -12
- package/registerComponent/dist/version.d.ts +1 -1
- package/registerFunction/dist/prop-types.d.ts +15 -0
- package/registerFunction/dist/registerComponent.d.ts +6 -12
- package/registerFunction/dist/version.d.ts +1 -1
- package/registerGlobalContext/dist/prop-types.d.ts +15 -0
- package/registerGlobalContext/dist/registerComponent.d.ts +6 -12
- package/registerGlobalContext/dist/version.d.ts +1 -1
- package/registerToken/dist/prop-types.d.ts +15 -0
- package/registerToken/dist/registerComponent.d.ts +6 -12
- package/registerToken/dist/version.d.ts +1 -1
- package/registerTrait/dist/prop-types.d.ts +15 -0
- package/registerTrait/dist/registerComponent.d.ts +6 -12
- package/registerTrait/dist/version.d.ts +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const hostVersion = "1.0.
|
|
1
|
+
export declare const hostVersion = "1.0.204";
|
|
@@ -402,6 +402,16 @@ export interface ModalProps {
|
|
|
402
402
|
onClose: () => void;
|
|
403
403
|
style?: CSSProperties;
|
|
404
404
|
}
|
|
405
|
+
export interface StudioOps {
|
|
406
|
+
showModal: (modalProps: Omit<ModalProps, "onClose"> & {
|
|
407
|
+
onClose?: () => void;
|
|
408
|
+
}) => void;
|
|
409
|
+
refreshQueryData: () => void;
|
|
410
|
+
appendToSlot: (element: PlasmicElement, slotName: string) => void;
|
|
411
|
+
removeFromSlotAt: (pos: number, slotName: string) => void;
|
|
412
|
+
updateProps: (newValues: any) => void;
|
|
413
|
+
updateStates: (newValues: any) => void;
|
|
414
|
+
}
|
|
405
415
|
export interface CustomControlProps<P> {
|
|
406
416
|
componentProps: P;
|
|
407
417
|
/**
|
|
@@ -410,6 +420,11 @@ export interface CustomControlProps<P> {
|
|
|
410
420
|
* calls `setControlContextData`)
|
|
411
421
|
*/
|
|
412
422
|
contextData: InferDataType<P> | null;
|
|
423
|
+
/**
|
|
424
|
+
* Operations available to the editor that allow modifying the entire component.
|
|
425
|
+
* Can be null if the custom prop is used in a global context.
|
|
426
|
+
*/
|
|
427
|
+
studioOps: StudioOps | null;
|
|
413
428
|
value: any;
|
|
414
429
|
/**
|
|
415
430
|
* Sets the value to be passed to the prop. Expects a JSON-compatible value.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { CodeComponentElement, CSSProperties
|
|
3
|
-
import { ContextDependentConfig, InferDataType,
|
|
2
|
+
import { CodeComponentElement, CSSProperties } from "./element-types";
|
|
3
|
+
import { ContextDependentConfig, InferDataType, PropType, RestrictPropType, StudioOps } from "./prop-types";
|
|
4
4
|
import { TupleUnion } from "./type-utils";
|
|
5
5
|
export type * from "./prop-types";
|
|
6
6
|
export interface ActionProps<P> {
|
|
@@ -11,16 +11,10 @@ export interface ActionProps<P> {
|
|
|
11
11
|
* calls `setControlContextData`)
|
|
12
12
|
*/
|
|
13
13
|
contextData: InferDataType<P> | null;
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
refreshQueryData: () => void;
|
|
19
|
-
appendToSlot: (element: PlasmicElement, slotName: string) => void;
|
|
20
|
-
removeFromSlotAt: (pos: number, slotName: string) => void;
|
|
21
|
-
updateProps: (newValues: any) => void;
|
|
22
|
-
updateStates: (newValues: any) => void;
|
|
23
|
-
};
|
|
14
|
+
/**
|
|
15
|
+
* Operations available to the editor that allow modifying the entire component.
|
|
16
|
+
*/
|
|
17
|
+
studioOps: StudioOps;
|
|
24
18
|
/**
|
|
25
19
|
* The document that the component will be rendered into; instead of using
|
|
26
20
|
* `document` directly (for, say, `document.querySelector()` etc.), you
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const hostVersion = "1.0.
|
|
1
|
+
export declare const hostVersion = "1.0.204";
|
|
@@ -402,6 +402,16 @@ export interface ModalProps {
|
|
|
402
402
|
onClose: () => void;
|
|
403
403
|
style?: CSSProperties;
|
|
404
404
|
}
|
|
405
|
+
export interface StudioOps {
|
|
406
|
+
showModal: (modalProps: Omit<ModalProps, "onClose"> & {
|
|
407
|
+
onClose?: () => void;
|
|
408
|
+
}) => void;
|
|
409
|
+
refreshQueryData: () => void;
|
|
410
|
+
appendToSlot: (element: PlasmicElement, slotName: string) => void;
|
|
411
|
+
removeFromSlotAt: (pos: number, slotName: string) => void;
|
|
412
|
+
updateProps: (newValues: any) => void;
|
|
413
|
+
updateStates: (newValues: any) => void;
|
|
414
|
+
}
|
|
405
415
|
export interface CustomControlProps<P> {
|
|
406
416
|
componentProps: P;
|
|
407
417
|
/**
|
|
@@ -410,6 +420,11 @@ export interface CustomControlProps<P> {
|
|
|
410
420
|
* calls `setControlContextData`)
|
|
411
421
|
*/
|
|
412
422
|
contextData: InferDataType<P> | null;
|
|
423
|
+
/**
|
|
424
|
+
* Operations available to the editor that allow modifying the entire component.
|
|
425
|
+
* Can be null if the custom prop is used in a global context.
|
|
426
|
+
*/
|
|
427
|
+
studioOps: StudioOps | null;
|
|
413
428
|
value: any;
|
|
414
429
|
/**
|
|
415
430
|
* Sets the value to be passed to the prop. Expects a JSON-compatible value.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { CodeComponentElement, CSSProperties
|
|
3
|
-
import { ContextDependentConfig, InferDataType,
|
|
2
|
+
import { CodeComponentElement, CSSProperties } from "./element-types";
|
|
3
|
+
import { ContextDependentConfig, InferDataType, PropType, RestrictPropType, StudioOps } from "./prop-types";
|
|
4
4
|
import { TupleUnion } from "./type-utils";
|
|
5
5
|
export type * from "./prop-types";
|
|
6
6
|
export interface ActionProps<P> {
|
|
@@ -11,16 +11,10 @@ export interface ActionProps<P> {
|
|
|
11
11
|
* calls `setControlContextData`)
|
|
12
12
|
*/
|
|
13
13
|
contextData: InferDataType<P> | null;
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
refreshQueryData: () => void;
|
|
19
|
-
appendToSlot: (element: PlasmicElement, slotName: string) => void;
|
|
20
|
-
removeFromSlotAt: (pos: number, slotName: string) => void;
|
|
21
|
-
updateProps: (newValues: any) => void;
|
|
22
|
-
updateStates: (newValues: any) => void;
|
|
23
|
-
};
|
|
14
|
+
/**
|
|
15
|
+
* Operations available to the editor that allow modifying the entire component.
|
|
16
|
+
*/
|
|
17
|
+
studioOps: StudioOps;
|
|
24
18
|
/**
|
|
25
19
|
* The document that the component will be rendered into; instead of using
|
|
26
20
|
* `document` directly (for, say, `document.querySelector()` etc.), you
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const hostVersion = "1.0.
|
|
1
|
+
export declare const hostVersion = "1.0.204";
|
|
@@ -402,6 +402,16 @@ export interface ModalProps {
|
|
|
402
402
|
onClose: () => void;
|
|
403
403
|
style?: CSSProperties;
|
|
404
404
|
}
|
|
405
|
+
export interface StudioOps {
|
|
406
|
+
showModal: (modalProps: Omit<ModalProps, "onClose"> & {
|
|
407
|
+
onClose?: () => void;
|
|
408
|
+
}) => void;
|
|
409
|
+
refreshQueryData: () => void;
|
|
410
|
+
appendToSlot: (element: PlasmicElement, slotName: string) => void;
|
|
411
|
+
removeFromSlotAt: (pos: number, slotName: string) => void;
|
|
412
|
+
updateProps: (newValues: any) => void;
|
|
413
|
+
updateStates: (newValues: any) => void;
|
|
414
|
+
}
|
|
405
415
|
export interface CustomControlProps<P> {
|
|
406
416
|
componentProps: P;
|
|
407
417
|
/**
|
|
@@ -410,6 +420,11 @@ export interface CustomControlProps<P> {
|
|
|
410
420
|
* calls `setControlContextData`)
|
|
411
421
|
*/
|
|
412
422
|
contextData: InferDataType<P> | null;
|
|
423
|
+
/**
|
|
424
|
+
* Operations available to the editor that allow modifying the entire component.
|
|
425
|
+
* Can be null if the custom prop is used in a global context.
|
|
426
|
+
*/
|
|
427
|
+
studioOps: StudioOps | null;
|
|
413
428
|
value: any;
|
|
414
429
|
/**
|
|
415
430
|
* Sets the value to be passed to the prop. Expects a JSON-compatible value.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { CodeComponentElement, CSSProperties
|
|
3
|
-
import { ContextDependentConfig, InferDataType,
|
|
2
|
+
import { CodeComponentElement, CSSProperties } from "./element-types";
|
|
3
|
+
import { ContextDependentConfig, InferDataType, PropType, RestrictPropType, StudioOps } from "./prop-types";
|
|
4
4
|
import { TupleUnion } from "./type-utils";
|
|
5
5
|
export type * from "./prop-types";
|
|
6
6
|
export interface ActionProps<P> {
|
|
@@ -11,16 +11,10 @@ export interface ActionProps<P> {
|
|
|
11
11
|
* calls `setControlContextData`)
|
|
12
12
|
*/
|
|
13
13
|
contextData: InferDataType<P> | null;
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
refreshQueryData: () => void;
|
|
19
|
-
appendToSlot: (element: PlasmicElement, slotName: string) => void;
|
|
20
|
-
removeFromSlotAt: (pos: number, slotName: string) => void;
|
|
21
|
-
updateProps: (newValues: any) => void;
|
|
22
|
-
updateStates: (newValues: any) => void;
|
|
23
|
-
};
|
|
14
|
+
/**
|
|
15
|
+
* Operations available to the editor that allow modifying the entire component.
|
|
16
|
+
*/
|
|
17
|
+
studioOps: StudioOps;
|
|
24
18
|
/**
|
|
25
19
|
* The document that the component will be rendered into; instead of using
|
|
26
20
|
* `document` directly (for, say, `document.querySelector()` etc.), you
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const hostVersion = "1.0.
|
|
1
|
+
export declare const hostVersion = "1.0.204";
|
|
@@ -402,6 +402,16 @@ export interface ModalProps {
|
|
|
402
402
|
onClose: () => void;
|
|
403
403
|
style?: CSSProperties;
|
|
404
404
|
}
|
|
405
|
+
export interface StudioOps {
|
|
406
|
+
showModal: (modalProps: Omit<ModalProps, "onClose"> & {
|
|
407
|
+
onClose?: () => void;
|
|
408
|
+
}) => void;
|
|
409
|
+
refreshQueryData: () => void;
|
|
410
|
+
appendToSlot: (element: PlasmicElement, slotName: string) => void;
|
|
411
|
+
removeFromSlotAt: (pos: number, slotName: string) => void;
|
|
412
|
+
updateProps: (newValues: any) => void;
|
|
413
|
+
updateStates: (newValues: any) => void;
|
|
414
|
+
}
|
|
405
415
|
export interface CustomControlProps<P> {
|
|
406
416
|
componentProps: P;
|
|
407
417
|
/**
|
|
@@ -410,6 +420,11 @@ export interface CustomControlProps<P> {
|
|
|
410
420
|
* calls `setControlContextData`)
|
|
411
421
|
*/
|
|
412
422
|
contextData: InferDataType<P> | null;
|
|
423
|
+
/**
|
|
424
|
+
* Operations available to the editor that allow modifying the entire component.
|
|
425
|
+
* Can be null if the custom prop is used in a global context.
|
|
426
|
+
*/
|
|
427
|
+
studioOps: StudioOps | null;
|
|
413
428
|
value: any;
|
|
414
429
|
/**
|
|
415
430
|
* Sets the value to be passed to the prop. Expects a JSON-compatible value.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { CodeComponentElement, CSSProperties
|
|
3
|
-
import { ContextDependentConfig, InferDataType,
|
|
2
|
+
import { CodeComponentElement, CSSProperties } from "./element-types";
|
|
3
|
+
import { ContextDependentConfig, InferDataType, PropType, RestrictPropType, StudioOps } from "./prop-types";
|
|
4
4
|
import { TupleUnion } from "./type-utils";
|
|
5
5
|
export type * from "./prop-types";
|
|
6
6
|
export interface ActionProps<P> {
|
|
@@ -11,16 +11,10 @@ export interface ActionProps<P> {
|
|
|
11
11
|
* calls `setControlContextData`)
|
|
12
12
|
*/
|
|
13
13
|
contextData: InferDataType<P> | null;
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
refreshQueryData: () => void;
|
|
19
|
-
appendToSlot: (element: PlasmicElement, slotName: string) => void;
|
|
20
|
-
removeFromSlotAt: (pos: number, slotName: string) => void;
|
|
21
|
-
updateProps: (newValues: any) => void;
|
|
22
|
-
updateStates: (newValues: any) => void;
|
|
23
|
-
};
|
|
14
|
+
/**
|
|
15
|
+
* Operations available to the editor that allow modifying the entire component.
|
|
16
|
+
*/
|
|
17
|
+
studioOps: StudioOps;
|
|
24
18
|
/**
|
|
25
19
|
* The document that the component will be rendered into; instead of using
|
|
26
20
|
* `document` directly (for, say, `document.querySelector()` etc.), you
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const hostVersion = "1.0.
|
|
1
|
+
export declare const hostVersion = "1.0.204";
|