@frigade/react 2.7.1 → 2.7.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/index.cjs +43 -43
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +32 -16
- package/dist/index.js +18 -18
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1344,6 +1344,26 @@ declare function useStepHandlers(step: FlowStep, { onPrimary, onSecondary }?: St
|
|
|
1344
1344
|
interface BoxPropsWithoutChildren extends Omit<BoxProps, 'children'> {
|
|
1345
1345
|
}
|
|
1346
1346
|
interface FlowPropsWithoutChildren extends BoxPropsWithoutChildren {
|
|
1347
|
+
/**
|
|
1348
|
+
* Whether to automatically mark the Flow started (i.e. in progress) when the Flow is eligible to be shown.
|
|
1349
|
+
* You will need to call `flow.start()` or `step.start()` from the parent component if you set this to `false`. Most components should not need to override this behavior.
|
|
1350
|
+
*
|
|
1351
|
+
* Defaults to `true`.
|
|
1352
|
+
*/
|
|
1353
|
+
autoStart?: boolean;
|
|
1354
|
+
/**
|
|
1355
|
+
* Optional component to wrap the child components in, e.g. `as={Dialog}` will render the Flow in a modal Dialog. Defaults to `Box`.
|
|
1356
|
+
*/
|
|
1357
|
+
as?: React$1.ElementType;
|
|
1358
|
+
/**
|
|
1359
|
+
* Emotion CSS prop to apply to the component. See [Theming documentation](https://docs.frigade.com/v2/sdk/styling/css-overrides) for more information.
|
|
1360
|
+
*
|
|
1361
|
+
* Example usage:
|
|
1362
|
+
* ```
|
|
1363
|
+
* <Frigade.Checklist css={{ backgroundColor: "pink", ".fr-button-primary": { backgroundColor: "fuchsia" } }} />
|
|
1364
|
+
* ```
|
|
1365
|
+
*/
|
|
1366
|
+
css?: React$1.Attributes['css'];
|
|
1347
1367
|
/**
|
|
1348
1368
|
* Whether the Flow is dismissible or not
|
|
1349
1369
|
*
|
|
@@ -1385,19 +1405,6 @@ interface FlowPropsWithoutChildren extends BoxPropsWithoutChildren {
|
|
|
1385
1405
|
* For instance, you can use `title: Hello, ${name}!` in the Flow configuration and pass `variables={{name: 'John'}}` to customize the copy.
|
|
1386
1406
|
*/
|
|
1387
1407
|
variables?: Record<string, unknown>;
|
|
1388
|
-
/**
|
|
1389
|
-
* Optional component to wrap the child components in, e.g. `as={Dialog}` will render the Flow in a modal Dialog. Defaults to `Box`.
|
|
1390
|
-
*/
|
|
1391
|
-
as?: React$1.ElementType;
|
|
1392
|
-
/**
|
|
1393
|
-
* Emotion CSS prop to apply to the component. See [Theming documentation](https://docs.frigade.com/v2/sdk/styling/css-overrides) for more information.
|
|
1394
|
-
*
|
|
1395
|
-
* Example usage:
|
|
1396
|
-
* ```
|
|
1397
|
-
* <Frigade.Checklist css={{ backgroundColor: "pink", ".fr-button-primary": { backgroundColor: "fuchsia" } }} />
|
|
1398
|
-
* ```
|
|
1399
|
-
*/
|
|
1400
|
-
css?: React$1.Attributes['css'];
|
|
1401
1408
|
}
|
|
1402
1409
|
interface FlowProps extends FlowPropsWithoutChildren {
|
|
1403
1410
|
/**
|
|
@@ -1445,7 +1452,7 @@ declare namespace Dialog {
|
|
|
1445
1452
|
var displayName: string;
|
|
1446
1453
|
}
|
|
1447
1454
|
|
|
1448
|
-
declare function Flow({ as, children, flowId, onComplete, onDismiss, onPrimary, onSecondary, variables, ...props }: FlowProps): _emotion_react_jsx_runtime.JSX.Element;
|
|
1455
|
+
declare function Flow({ as, autoStart, children, flowId, onComplete, onDismiss, onPrimary, onSecondary, variables, ...props }: FlowProps): _emotion_react_jsx_runtime.JSX.Element;
|
|
1449
1456
|
|
|
1450
1457
|
interface AnnouncementProps extends FlowPropsWithoutChildren, DialogProps {
|
|
1451
1458
|
/**
|
|
@@ -1679,14 +1686,16 @@ interface HintProps extends BoxProps {
|
|
|
1679
1686
|
autoScroll?: ScrollIntoViewOptions | boolean;
|
|
1680
1687
|
children?: React.ReactNode;
|
|
1681
1688
|
defaultOpen?: boolean;
|
|
1689
|
+
lockScroll?: boolean;
|
|
1682
1690
|
modal?: boolean;
|
|
1691
|
+
onMount?: () => void;
|
|
1683
1692
|
onOpenChange?: (open: boolean) => void;
|
|
1684
1693
|
open?: boolean;
|
|
1685
1694
|
side?: SideValue;
|
|
1686
1695
|
sideOffset?: number;
|
|
1687
1696
|
spotlight?: boolean;
|
|
1688
1697
|
}
|
|
1689
|
-
declare function Hint({ align, alignOffset, anchor, autoScroll, children, css, defaultOpen, modal, onOpenChange, open, part, side, sideOffset, spotlight, style, ...props }: HintProps): _emotion_react_jsx_runtime.JSX.Element;
|
|
1698
|
+
declare function Hint({ align, alignOffset, anchor, autoScroll, children, css, defaultOpen, lockScroll, modal, onMount, onOpenChange, open, part, side, sideOffset, spotlight, style, ...props }: HintProps): _emotion_react_jsx_runtime.JSX.Element;
|
|
1690
1699
|
|
|
1691
1700
|
declare function SelectField(props: FormFieldProps): _emotion_react_jsx_runtime.JSX.Element;
|
|
1692
1701
|
|
|
@@ -1857,12 +1866,14 @@ interface ProviderProps {
|
|
|
1857
1866
|
declare function Provider({ children, css, defaultCollection, navigate, theme, ...props }: ProviderProps): _emotion_react_jsx_runtime.JSX.Element;
|
|
1858
1867
|
|
|
1859
1868
|
interface OverlayProps extends BoxProps {
|
|
1869
|
+
lockScroll?: boolean;
|
|
1860
1870
|
}
|
|
1861
1871
|
|
|
1862
1872
|
interface SpotlightProps extends OverlayProps {
|
|
1863
1873
|
anchor: string;
|
|
1874
|
+
lockScroll?: boolean;
|
|
1864
1875
|
}
|
|
1865
|
-
declare function Spotlight({ anchor, part, style, ...props }: SpotlightProps): _emotion_react_jsx_runtime.JSX.Element;
|
|
1876
|
+
declare function Spotlight({ anchor, lockScroll, part, style, ...props }: SpotlightProps): _emotion_react_jsx_runtime.JSX.Element;
|
|
1866
1877
|
|
|
1867
1878
|
declare const index_NPS: typeof NPS;
|
|
1868
1879
|
type index_NPSProps = NPSProps;
|
|
@@ -1936,6 +1947,11 @@ interface TourProps extends FlowPropsWithoutChildren, Omit<HintProps, 'anchor'>
|
|
|
1936
1947
|
* Whether the tooltip should be open by default.
|
|
1937
1948
|
*/
|
|
1938
1949
|
defaultOpen?: boolean;
|
|
1950
|
+
/**
|
|
1951
|
+
* Whether to lock the scroll of the container when the Spotlight is enabled.
|
|
1952
|
+
* Defaults to `true`.
|
|
1953
|
+
*/
|
|
1954
|
+
lockScroll?: boolean;
|
|
1939
1955
|
/**
|
|
1940
1956
|
* Whether to render a modal overlay behind the tooltip.
|
|
1941
1957
|
*/
|