@superdispatch/ui 0.18.0 → 0.18.3
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-src/index.js
CHANGED
|
@@ -35,6 +35,7 @@ export * from "./theme/Color.js";
|
|
|
35
35
|
export * from "./theme/SuperDispatchTheme.js";
|
|
36
36
|
export * from "./theme/ThemeProvider.js";
|
|
37
37
|
export * from "./tiles/Tiles.js";
|
|
38
|
+
export * from "./utils/ExitTransitionPlaceholder.js";
|
|
38
39
|
export * from "./utils/isEmptyReactNode.js";
|
|
39
40
|
export * from "./utils/mergeRefs.js";
|
|
40
41
|
export * from "./utils/renderChildren.js";
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { useEffect, useState } from 'react';
|
|
2
|
+
import { renderChildren } from "./renderChildren.js";
|
|
3
|
+
export function ExitTransitionPlaceholder(_ref) {
|
|
4
|
+
var {
|
|
5
|
+
in: inProp,
|
|
6
|
+
children: childrenProp
|
|
7
|
+
} = _ref;
|
|
8
|
+
var [children, setChildren] = useState(childrenProp);
|
|
9
|
+
useEffect(() => {
|
|
10
|
+
if (inProp) {
|
|
11
|
+
setChildren(childrenProp);
|
|
12
|
+
}
|
|
13
|
+
}, [inProp, childrenProp]);
|
|
14
|
+
return renderChildren(children);
|
|
15
|
+
}
|
package/dist-types/index.d.ts
CHANGED
|
@@ -412,6 +412,12 @@ interface TilesProps {
|
|
|
412
412
|
}
|
|
413
413
|
declare const Tiles: ForwardRefExoticComponent<TilesProps & RefAttributes<HTMLDivElement>>;
|
|
414
414
|
|
|
415
|
+
interface ExitTransitionPlaceholderProps {
|
|
416
|
+
in: boolean;
|
|
417
|
+
children: ReactNode;
|
|
418
|
+
}
|
|
419
|
+
declare function ExitTransitionPlaceholder({ in: inProp, children: childrenProp, }: ExitTransitionPlaceholderProps): null | ReactElement;
|
|
420
|
+
|
|
415
421
|
declare function isEmptyReactNode(node: ReactNode): node is null | undefined | boolean | string;
|
|
416
422
|
|
|
417
423
|
declare function mergeRefs<T>(...refs: Array<null | undefined | Ref<T>>): (node: T) => void;
|
|
@@ -442,4 +448,4 @@ interface VisibilityObserverProps extends VisibilityObserverOptions {
|
|
|
442
448
|
}
|
|
443
449
|
declare function VisibilityObserver({ render, onChange, ...options }: VisibilityObserverProps): null | ReactElement;
|
|
444
450
|
|
|
445
|
-
export { AdaptiveToolbar, AdaptiveToolbarDropdownItem, AdaptiveToolbarItem, AdaptiveToolbarProps, AdaptiveVerticalToolbar, AdaptiveVerticalToolbarItem, AdaptiveVerticalToolbarProps, AvatarButton, AvatarButtonClassKey, AvatarButtonProps, Button, ButtonProps, CardButton, CardButtonClassKey, CardButtonProps, CheckboxField, CheckboxFieldProps, CheckboxGroupField, CheckboxGroupFieldProps, CollapseBreakpoint, CollapseProp, Color, ColorProp, ColorVariant, Column, ColumnProps, ColumnWidth, Columns, ColumnsProps, DescriptionList, DescriptionListItem, DescriptionListItemProps, DescriptionListProps, DrawerActions, DrawerActionsProps, DrawerContent, DrawerContentProps, DrawerList, DrawerListProps, DrawerTitle, DrawerTitleProps, DropdownButton, ElementVisibility, GridStack, GridStackProps, HorizontalAlign, InfoCard, InfoCardClassKey, InfoCardProps, Inline, InlineGrid, InlineGridProps, InlineProps, NegativeSpaceProp, OverflowText, OverflowTextProps, PartialResponsivePropRecord, RadioField, RadioFieldProps, RadioGroupField, RadioGroupFieldProps, ResponsiveContext, ResponsiveContextProvider, ResponsiveContextProviderProps, ResponsiveProp, ResponsivePropPrimitive, ResponsivePropRecord, ResponsivePropTuple, ResponsivePropTupleInit, Snackbar, SnackbarCloseReason, SnackbarContent, SnackbarContentProps, SnackbarProps, SnackbarStack, SnackbarStackConsumer, SnackbarStackOptions, SnackbarStackProvider, SnackbarStackProviderProps, SnackbarVariant, SpaceProp, Stack, StackProps, SuperDispatchTheme, Tag, TagClassKey, TagProps, ThemeProvider, ThemeProviderProps, Tiles, TilesColumns, TilesProps, TilesSpace, VerticalAlign, VisibilityObserver, VisibilityObserverOptions, VisibilityObserverProps, VisibilityObserverRenderProps, assignRef, isColorProp, isEmptyReactNode, mergeRefs, parseAlignProp, parseCollapsedBelow, parseResponsiveProp, parseSpaceProp, renderChildren, useCollapseBreakpoint, useResizeObserver, useResponsiveContext, useResponsiveProp, useResponsivePropRecord, useResponsiveValue, useSnackbarStack, useUID, useVisibilityObserver };
|
|
451
|
+
export { AdaptiveToolbar, AdaptiveToolbarDropdownItem, AdaptiveToolbarItem, AdaptiveToolbarProps, AdaptiveVerticalToolbar, AdaptiveVerticalToolbarItem, AdaptiveVerticalToolbarProps, AvatarButton, AvatarButtonClassKey, AvatarButtonProps, Button, ButtonProps, CardButton, CardButtonClassKey, CardButtonProps, CheckboxField, CheckboxFieldProps, CheckboxGroupField, CheckboxGroupFieldProps, CollapseBreakpoint, CollapseProp, Color, ColorProp, ColorVariant, Column, ColumnProps, ColumnWidth, Columns, ColumnsProps, DescriptionList, DescriptionListItem, DescriptionListItemProps, DescriptionListProps, DrawerActions, DrawerActionsProps, DrawerContent, DrawerContentProps, DrawerList, DrawerListProps, DrawerTitle, DrawerTitleProps, DropdownButton, ElementVisibility, ExitTransitionPlaceholder, GridStack, GridStackProps, HorizontalAlign, InfoCard, InfoCardClassKey, InfoCardProps, Inline, InlineGrid, InlineGridProps, InlineProps, NegativeSpaceProp, OverflowText, OverflowTextProps, PartialResponsivePropRecord, RadioField, RadioFieldProps, RadioGroupField, RadioGroupFieldProps, ResponsiveContext, ResponsiveContextProvider, ResponsiveContextProviderProps, ResponsiveProp, ResponsivePropPrimitive, ResponsivePropRecord, ResponsivePropTuple, ResponsivePropTupleInit, Snackbar, SnackbarCloseReason, SnackbarContent, SnackbarContentProps, SnackbarProps, SnackbarStack, SnackbarStackConsumer, SnackbarStackOptions, SnackbarStackProvider, SnackbarStackProviderProps, SnackbarVariant, SpaceProp, Stack, StackProps, SuperDispatchTheme, Tag, TagClassKey, TagProps, ThemeProvider, ThemeProviderProps, Tiles, TilesColumns, TilesProps, TilesSpace, VerticalAlign, VisibilityObserver, VisibilityObserverOptions, VisibilityObserverProps, VisibilityObserverRenderProps, assignRef, isColorProp, isEmptyReactNode, mergeRefs, parseAlignProp, parseCollapsedBelow, parseResponsiveProp, parseSpaceProp, renderChildren, useCollapseBreakpoint, useResizeObserver, useResponsiveContext, useResponsiveProp, useResponsivePropRecord, useResponsiveValue, useSnackbarStack, useUID, useVisibilityObserver };
|
package/dist-web/index.js
CHANGED
|
@@ -3,7 +3,7 @@ import _objectWithoutProperties from '@babel/runtime/helpers/objectWithoutProper
|
|
|
3
3
|
import { Button as Button$1, CircularProgress, ButtonGroup, Popover, MenuList, Toolbar, Grid, MenuItem, Typography, Menu, Divider, ButtonBase, Avatar, FormControl, FormControlLabel, Checkbox, FormHelperText, FormLabel, FormGroup, useMediaQuery, Tooltip, SvgIcon, AppBar, List, Card, CardContent, Radio, RadioGroup, SnackbarContent as SnackbarContent$1, IconButton, Portal, Snackbar as Snackbar$1, Slide, CssBaseline, createTheme, createGenerateClassName } from '@material-ui/core';
|
|
4
4
|
import { MoreHoriz, Close, Warning, CheckCircle } from '@material-ui/icons';
|
|
5
5
|
import { makeStyles, StylesProvider, ThemeProvider as ThemeProvider$1 } from '@material-ui/styles';
|
|
6
|
-
import { forwardRef, useState, useRef, useLayoutEffect, cloneElement, useMemo, useContext, createContext, Children, useCallback } from 'react';
|
|
6
|
+
import { forwardRef, useState, useRef, useLayoutEffect, cloneElement, useMemo, useContext, createContext, Children, useCallback, useEffect } from 'react';
|
|
7
7
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
8
8
|
import styled, { css, ThemeProvider as ThemeProvider$2 } from 'styled-components';
|
|
9
9
|
import { ResizeObserver } from '@juggle/resize-observer';
|
|
@@ -3665,5 +3665,19 @@ var Tiles = /*#__PURE__*/forwardRef((_ref, ref) => {
|
|
|
3665
3665
|
});
|
|
3666
3666
|
if (process.env.NODE_ENV !== "production") Tiles.displayName = "Tiles";
|
|
3667
3667
|
|
|
3668
|
-
|
|
3668
|
+
function ExitTransitionPlaceholder(_ref) {
|
|
3669
|
+
var {
|
|
3670
|
+
in: inProp,
|
|
3671
|
+
children: childrenProp
|
|
3672
|
+
} = _ref;
|
|
3673
|
+
var [children, setChildren] = useState(childrenProp);
|
|
3674
|
+
useEffect(() => {
|
|
3675
|
+
if (inProp) {
|
|
3676
|
+
setChildren(childrenProp);
|
|
3677
|
+
}
|
|
3678
|
+
}, [inProp, childrenProp]);
|
|
3679
|
+
return renderChildren(children);
|
|
3680
|
+
}
|
|
3681
|
+
|
|
3682
|
+
export { AdaptiveToolbar, AdaptiveVerticalToolbar, AvatarButton, Button, CardButton, CheckboxField, CheckboxGroupField, Color, Column, Columns, DescriptionList, DescriptionListItem, DrawerActions, DrawerContent, DrawerList, DrawerTitle, DropdownButton, ExitTransitionPlaceholder, GridStack, InfoCard, Inline, InlineGrid, OverflowText, RadioField, RadioGroupField, ResponsiveContextProvider, Snackbar, SnackbarContent, SnackbarStackConsumer, SnackbarStackProvider, Stack, Tag, ThemeProvider, Tiles, VisibilityObserver, assignRef, isColorProp, isEmptyReactNode, mergeRefs, parseAlignProp, parseCollapsedBelow, parseResponsiveProp, parseSpaceProp, renderChildren, useCollapseBreakpoint, useResizeObserver, useResponsiveContext, useResponsiveProp, useResponsivePropRecord, useResponsiveValue, useSnackbarStack, useUID, useVisibilityObserver };
|
|
3669
3683
|
//# sourceMappingURL=index.js.map
|