@frigade/react 2.5.17 → 2.5.19

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.ts CHANGED
@@ -1388,6 +1388,15 @@ interface FlowPropsWithoutChildren extends BoxPropsWithoutChildren {
1388
1388
  * Optional component to wrap the child components in, e.g. `as={Dialog}` will render the Flow in a modal Dialog. Defaults to `Box`.
1389
1389
  */
1390
1390
  as?: React$1.ElementType;
1391
+ /**
1392
+ * Emotion CSS prop to apply to the component. See [Theming documentation](https://docs.frigade.com/v2/sdk/styling/css-overrides) for more information.
1393
+ *
1394
+ * Example usage:
1395
+ * ```
1396
+ * <Frigade.Checklist css={{ backgroundColor: "pink", ".fr-button-primary": { backgroundColor: "fuchsia" } }} />
1397
+ * ```
1398
+ */
1399
+ css?: React$1.Attributes['css'];
1391
1400
  }
1392
1401
  interface FlowProps extends FlowPropsWithoutChildren {
1393
1402
  /**
@@ -1666,6 +1675,7 @@ interface HintProps extends BoxProps {
1666
1675
  align?: AlignValue;
1667
1676
  alignOffset?: number;
1668
1677
  anchor: string;
1678
+ autoScroll?: ScrollIntoViewOptions | boolean;
1669
1679
  children?: React.ReactNode;
1670
1680
  defaultOpen?: boolean;
1671
1681
  modal?: boolean;
@@ -1675,7 +1685,7 @@ interface HintProps extends BoxProps {
1675
1685
  sideOffset?: number;
1676
1686
  spotlight?: boolean;
1677
1687
  }
1678
- declare function Hint({ align, alignOffset, anchor, children, defaultOpen, modal, onOpenChange, open, part, side, sideOffset, spotlight, style, ...props }: HintProps): _emotion_react_jsx_runtime.JSX.Element;
1688
+ 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;
1679
1689
 
1680
1690
  declare function SelectField(props: FormFieldProps): _emotion_react_jsx_runtime.JSX.Element;
1681
1691
 
@@ -1872,13 +1882,14 @@ declare namespace Tooltip {
1872
1882
  var Title: ({ children, ...props }: TextProps) => _emotion_react_jsx_runtime.JSX.Element;
1873
1883
  }
1874
1884
 
1885
+ declare function useClientPortal(children: React.ReactNode, container: Element | DocumentFragment | string, key?: null | string): React$1.ReactPortal;
1886
+
1887
+ interface ClientPortalProps {
1888
+ children?: React.ReactNode;
1889
+ container?: Parameters<typeof useClientPortal>[1];
1890
+ }
1891
+
1875
1892
  interface TourProps extends FlowPropsWithoutChildren, Omit<HintProps, 'anchor'> {
1876
- /**
1877
- * Whether the tour should be completed by the end-user in sequential order.
1878
- * If `false`, all steps will be rendered at once.
1879
- * Defaults to `true`, which means only one step will be rendered at a time in sequential order.
1880
- */
1881
- sequential?: boolean;
1882
1893
  /**
1883
1894
  * The alignment of the tooltip relative to the anchor.
1884
1895
  * Possible values: `after`, `before`, `center`, `end`, `start`.
@@ -1888,6 +1899,14 @@ interface TourProps extends FlowPropsWithoutChildren, Omit<HintProps, 'anchor'>
1888
1899
  * The offset of the tooltip relative to the anchor along the alignment axis.
1889
1900
  */
1890
1901
  alignOffset?: number;
1902
+ /**
1903
+ * Automatically scroll to the anchor element of the current Step
1904
+ */
1905
+ autoScroll?: boolean;
1906
+ /**
1907
+ * Specify a container in the DOM render the Tour into
1908
+ */
1909
+ container?: ClientPortalProps['container'];
1891
1910
  /**
1892
1911
  * Whether the tooltip should be open by default.
1893
1912
  */
@@ -1904,6 +1923,12 @@ interface TourProps extends FlowPropsWithoutChildren, Omit<HintProps, 'anchor'>
1904
1923
  * Controls the open state of the tooltip. Use this for controlled components.
1905
1924
  */
1906
1925
  open?: boolean;
1926
+ /**
1927
+ * Whether the Tour should be completed by the end-user in sequential order.
1928
+ * If `false`, all steps will be rendered at once.
1929
+ * Defaults to `true`, which means only one step will be rendered at a time in sequential order.
1930
+ */
1931
+ sequential?: boolean;
1907
1932
  /**
1908
1933
  * The preferred side of the anchor to render the tooltip.
1909
1934
  * Possible values: `top`, `right`, `bottom`, `left`.
@@ -1918,7 +1943,7 @@ interface TourProps extends FlowPropsWithoutChildren, Omit<HintProps, 'anchor'>
1918
1943
  */
1919
1944
  spotlight?: boolean;
1920
1945
  }
1921
- declare function Tour({ align, alignOffset, as, defaultOpen, dismissible, flowId, modal, part, sequential, side, sideOffset, spotlight, zIndex, ...props }: TourProps): React$1.ReactPortal;
1946
+ declare function Tour({ as, flowId, ...props }: TourProps): _emotion_react_jsx_runtime.JSX.Element;
1922
1947
 
1923
1948
  declare function useBoundingClientRect(): {
1924
1949
  node: any;