react-bricks 3.0.0-beta.2 → 3.1.0-alpha.0
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/react-bricks.d.ts
CHANGED
|
@@ -25,6 +25,7 @@ interface TextProps {
|
|
|
25
25
|
children: any;
|
|
26
26
|
}) => JSX.Element;
|
|
27
27
|
propName: string;
|
|
28
|
+
multiline: boolean;
|
|
28
29
|
}
|
|
29
30
|
declare const Text: React.FC<TextProps>;
|
|
30
31
|
|
|
@@ -153,6 +154,7 @@ declare namespace types {
|
|
|
153
154
|
slug: string;
|
|
154
155
|
meta: IMeta;
|
|
155
156
|
customValues?: Props;
|
|
157
|
+
externalData?: Props;
|
|
156
158
|
content: IContentBlock[];
|
|
157
159
|
authorId?: string;
|
|
158
160
|
author: Author;
|
|
@@ -252,6 +254,7 @@ declare namespace types {
|
|
|
252
254
|
hideFromAddMenu?: boolean;
|
|
253
255
|
sideEditProps?: Array<ISideEditProp | ISideGroup>;
|
|
254
256
|
repeaterItems?: IRepeaterItem[];
|
|
257
|
+
mapExternalDataToProps?: (externalData: Props, brickProps?: Props) => Props;
|
|
255
258
|
playgroundLinkUrl?: string;
|
|
256
259
|
playgroundLinkLabel?: string;
|
|
257
260
|
category?: string;
|
|
@@ -367,6 +370,7 @@ declare namespace types {
|
|
|
367
370
|
defaultFeaturedImage?: string;
|
|
368
371
|
getDefaultContent?: () => string[];
|
|
369
372
|
customFields?: Array<ISideEditPropPage | ISideGroup>;
|
|
373
|
+
getExternalData?: (page: Page) => Promise<Props>;
|
|
370
374
|
}
|
|
371
375
|
/**
|
|
372
376
|
* Structure returned by the cleanBlocks function
|
|
@@ -515,6 +519,7 @@ interface RichTextProps {
|
|
|
515
519
|
children: any;
|
|
516
520
|
}) => JSX.Element;
|
|
517
521
|
plugins?: types.RichTextPlugin[];
|
|
522
|
+
multiline?: boolean;
|
|
518
523
|
}
|
|
519
524
|
declare const RichText: React.FC<RichTextProps>;
|
|
520
525
|
|
|
@@ -609,7 +614,35 @@ declare const Playground: () => JSX.Element;
|
|
|
609
614
|
declare const AppSettings: React.FC;
|
|
610
615
|
|
|
611
616
|
declare const useAuth: () => {
|
|
612
|
-
loginUser: (email: string, password: string) => Promise<
|
|
617
|
+
loginUser: (email: string, password: string) => Promise<({
|
|
618
|
+
id: string;
|
|
619
|
+
email: string;
|
|
620
|
+
firstName: string;
|
|
621
|
+
lastName: string;
|
|
622
|
+
company: string;
|
|
623
|
+
avatarUrl?: string | undefined;
|
|
624
|
+
isAdmin: boolean;
|
|
625
|
+
token: string;
|
|
626
|
+
appName: string;
|
|
627
|
+
deployHookUrl?: string | undefined;
|
|
628
|
+
deployHookMethod?: string | undefined;
|
|
629
|
+
deployHookTriggerOnScheduledPublishing: boolean;
|
|
630
|
+
deployHookStagingUrl?: string | undefined;
|
|
631
|
+
deployHookStagingMethod?: string | undefined;
|
|
632
|
+
deployHookStagingTriggerOnScheduledPublishing: boolean;
|
|
633
|
+
eventsHookUrl?: string | undefined;
|
|
634
|
+
eventsHookAuthToken?: string | undefined;
|
|
635
|
+
canCreatePage: boolean;
|
|
636
|
+
canDeletePage: boolean;
|
|
637
|
+
canDeploy: boolean;
|
|
638
|
+
canDeployStaging: boolean;
|
|
639
|
+
role: string;
|
|
640
|
+
plan: string;
|
|
641
|
+
languages: types.Language[];
|
|
642
|
+
defaultLanguage: string;
|
|
643
|
+
} & {
|
|
644
|
+
authToken: string;
|
|
645
|
+
}) | null>;
|
|
613
646
|
logoutUser: () => void;
|
|
614
647
|
};
|
|
615
648
|
|
|
@@ -679,7 +712,7 @@ declare const useReactBricksContext: () => types.IReactBricksContext;
|
|
|
679
712
|
|
|
680
713
|
declare const useAdminContext: () => types.IReadAdminContext;
|
|
681
714
|
|
|
682
|
-
declare const fetchPage: (slug: string, apiKey: string, language?: string | undefined) => Promise<types.Page>;
|
|
715
|
+
declare const fetchPage: (slug: string, apiKey: string, language?: string | undefined, pageTypes?: types.IPageType[] | undefined) => Promise<types.Page>;
|
|
683
716
|
|
|
684
717
|
/**
|
|
685
718
|
* Values returned from fetchPages
|