@equinor/eds-core-react 0.16.1-dev.12072021 → 0.18.0-dev.20220210
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/README.md +1 -1
- package/dist/{core-react.cjs.js → eds-core-react.cjs.js} +2731 -2290
- package/dist/esm/components/Accordion/Accordion.js +24 -11
- package/dist/esm/components/Accordion/Accordion.tokens.js +3 -0
- package/dist/esm/components/Accordion/AccordionHeader.js +65 -51
- package/dist/esm/components/Accordion/AccordionHeaderTitle.js +15 -13
- package/dist/esm/components/Accordion/AccordionItem.js +11 -10
- package/dist/esm/components/Accordion/AccordionPanel.js +32 -24
- package/dist/esm/components/Avatar/Avatar.js +21 -14
- package/dist/esm/components/Banner/Banner.js +36 -24
- package/dist/esm/components/Banner/Banner.tokens.js +9 -0
- package/dist/esm/components/Banner/BannerActions.js +16 -17
- package/dist/esm/components/Banner/BannerIcon.js +15 -11
- package/dist/esm/components/Banner/BannerMessage.js +5 -4
- package/dist/esm/components/Breadcrumbs/Breadcrumb.js +16 -12
- package/dist/esm/components/Breadcrumbs/Breadcrumbs.js +7 -6
- package/dist/esm/components/Button/Button.js +17 -18
- package/dist/esm/components/Button/InnerFullWidth.js +5 -4
- package/dist/esm/components/Button/tokens/button.js +17 -10
- package/dist/esm/components/Button/tokens/contained.js +5 -5
- package/dist/esm/components/Button/tokens/ghost.js +4 -4
- package/dist/esm/components/Button/tokens/icon.js +4 -4
- package/dist/esm/components/Button/tokens/outlined.js +5 -5
- package/dist/esm/components/Card/Card.js +19 -12
- package/dist/esm/components/Card/CardActions.js +13 -9
- package/dist/esm/components/Card/CardContent.js +5 -4
- package/dist/esm/components/Card/CardHeader.js +5 -4
- package/dist/esm/components/Card/CardHeaderTitle.js +5 -4
- package/dist/esm/components/Card/CardMedia.js +12 -8
- package/dist/esm/components/Checkbox/Checkbox.js +15 -11
- package/dist/esm/components/Checkbox/Input.js +72 -46
- package/dist/esm/components/Chip/Chip.js +46 -30
- package/dist/esm/components/Chip/Icon.js +12 -7
- package/dist/esm/components/Dialog/Dialog.js +55 -16
- package/dist/esm/components/Dialog/Dialog.tokens.js +7 -12
- package/dist/esm/components/Dialog/DialogActions.js +27 -0
- package/dist/esm/components/Dialog/DialogContent.js +44 -0
- package/dist/esm/components/Dialog/DialogHeader.js +37 -0
- package/dist/esm/components/Dialog/DialogTitle.js +31 -0
- package/dist/esm/components/Dialog/index.js +11 -7
- package/dist/esm/components/Divider/Divider.js +6 -5
- package/dist/esm/components/EdsProvider/eds.context.js +5 -4
- package/dist/esm/components/Icon/Icon.js +77 -46
- package/dist/esm/components/Input/Input.js +12 -12
- package/dist/esm/components/Input/Input.tokens.js +4 -4
- package/dist/esm/components/Label/Label.js +7 -4
- package/dist/esm/components/List/List.js +13 -9
- package/dist/esm/components/List/ListItem.js +5 -4
- package/dist/esm/components/Menu/Menu.context.js +5 -4
- package/dist/esm/components/Menu/Menu.js +39 -30
- package/dist/esm/components/Menu/MenuItem.js +38 -25
- package/dist/esm/components/Menu/MenuList.js +7 -6
- package/dist/esm/components/Menu/MenuSection.js +3 -3
- package/dist/esm/components/Pagination/Pagination.js +16 -12
- package/dist/esm/components/Pagination/PaginationItem.js +7 -6
- package/dist/esm/components/Paper/Paper.js +11 -7
- package/dist/esm/components/Popover/Popover.js +77 -58
- package/dist/esm/components/Popover/Popover.tokens.js +5 -12
- package/dist/esm/components/Popover/PopoverActions.js +28 -0
- package/dist/esm/components/Popover/PopoverContent.js +12 -6
- package/dist/esm/components/Popover/PopoverHeader.js +36 -0
- package/dist/esm/components/Popover/PopoverTitle.js +15 -19
- package/dist/esm/components/Popover/index.js +6 -0
- package/dist/esm/components/Progress/Circular/CircularProgress.js +14 -10
- package/dist/esm/components/Progress/Dots/DotProgress.js +12 -8
- package/dist/esm/components/Progress/Linear/LinearProgress.js +6 -5
- package/dist/esm/components/Progress/Star/StarProgress.js +14 -10
- package/dist/esm/components/Radio/Radio.js +84 -52
- package/dist/esm/components/Scrim/Scrim.js +20 -15
- package/dist/esm/components/Search/Search.js +81 -58
- package/dist/esm/components/Search/Search.tokens.js +8 -4
- package/dist/esm/components/Select/MultiSelect/MultiSelect.js +35 -24
- package/dist/esm/components/Select/NativeSelect/NativeSelect.js +19 -17
- package/dist/esm/components/Select/Select.tokens.js +5 -2
- package/dist/esm/components/Select/SingleSelect/SingleSelect.js +29 -23
- package/dist/esm/components/Select/commonStyles.js +15 -14
- package/dist/esm/components/SideSheet/SideSheet.js +16 -13
- package/dist/esm/components/Slider/MinMax.js +5 -4
- package/dist/esm/components/Slider/Output.js +13 -9
- package/dist/esm/components/Slider/Slider.js +63 -35
- package/dist/esm/components/Slider/SliderInput.js +14 -14
- package/dist/esm/components/Snackbar/Snackbar.js +36 -25
- package/dist/esm/components/Snackbar/Snackbar.tokens.js +3 -0
- package/dist/esm/components/Snackbar/SnackbarAction.js +12 -7
- package/dist/esm/components/Switch/Switch.js +21 -15
- package/dist/esm/components/Switch/Switch.styles.js +24 -17
- package/dist/esm/components/Switch/SwitchDefault.js +39 -29
- package/dist/esm/components/Switch/SwitchSmall.js +38 -28
- package/dist/esm/components/Table/Body.js +5 -4
- package/dist/esm/components/Table/Caption.js +8 -5
- package/dist/esm/components/Table/Cell.js +9 -6
- package/dist/esm/components/Table/DataCell/DataCell.js +15 -14
- package/dist/esm/components/Table/DataCell/DataCell.tokens.js +19 -9
- package/dist/esm/components/Table/Head/Head.js +7 -6
- package/dist/esm/components/Table/HeaderCell/HeaderCell.js +8 -9
- package/dist/esm/components/Table/HeaderCell/HeaderCell.tokens.js +18 -8
- package/dist/esm/components/Table/Row/Row.js +7 -5
- package/dist/esm/components/Table/Table.js +5 -4
- package/dist/esm/components/TableOfContents/LinkItem.js +13 -10
- package/dist/esm/components/TableOfContents/TableOfContents.js +44 -24
- package/dist/esm/components/TableOfContents/TableOfContents.tokens.js +3 -0
- package/dist/esm/components/Tabs/Tab.js +27 -30
- package/dist/esm/components/Tabs/TabList.js +12 -8
- package/dist/esm/components/Tabs/TabPanel.js +16 -12
- package/dist/esm/components/Tabs/TabPanels.js +5 -4
- package/dist/esm/components/Tabs/Tabs.js +37 -24
- package/dist/esm/components/Tabs/Tabs.tokens.js +3 -0
- package/dist/esm/components/TextField/Field.js +51 -38
- package/dist/esm/components/TextField/HelperText/HelperText.js +28 -19
- package/dist/esm/components/TextField/Icon/Icon.js +20 -18
- package/dist/esm/components/TextField/TextField.context.js +4 -3
- package/dist/esm/components/TextField/TextField.js +22 -18
- package/dist/esm/components/Textarea/Textarea.js +16 -16
- package/dist/esm/components/Tooltip/Tooltip.js +10 -16
- package/dist/esm/components/TopBar/Actions.js +5 -4
- package/dist/esm/components/TopBar/CustomContent.js +5 -4
- package/dist/esm/components/TopBar/Header.js +5 -4
- package/dist/esm/components/TopBar/TopBar.js +27 -19
- package/dist/esm/components/TopBar/TopBar.tokens.js +5 -2
- package/dist/esm/components/Typography/Typography.js +49 -28
- package/dist/esm/index.js +1 -0
- package/dist/esm/node_modules/.pnpm/{ramda@0.27.1 → ramda@0.27.2}/node_modules/ramda/src/internal/_curry1.js +1 -1
- package/dist/esm/node_modules/.pnpm/{ramda@0.27.1 → ramda@0.27.2}/node_modules/ramda/src/internal/_curry2.js +1 -1
- package/dist/esm/node_modules/.pnpm/{ramda@0.27.1 → ramda@0.27.2}/node_modules/ramda/src/internal/_curry3.js +1 -1
- package/dist/esm/node_modules/.pnpm/{ramda@0.27.1 → ramda@0.27.2}/node_modules/ramda/src/internal/_has.js +1 -1
- package/dist/esm/node_modules/.pnpm/{ramda@0.27.1 → ramda@0.27.2}/node_modules/ramda/src/internal/_isObject.js +1 -1
- package/dist/esm/node_modules/.pnpm/{ramda@0.27.1 → ramda@0.27.2}/node_modules/ramda/src/internal/_isPlaceholder.js +1 -1
- package/dist/esm/node_modules/.pnpm/{ramda@0.27.1 → ramda@0.27.2}/node_modules/ramda/src/mergeDeepRight.js +2 -1
- package/dist/esm/node_modules/.pnpm/{ramda@0.27.1 → ramda@0.27.2}/node_modules/ramda/src/mergeDeepWithKey.js +1 -1
- package/dist/esm/node_modules/.pnpm/{ramda@0.27.1 → ramda@0.27.2}/node_modules/ramda/src/mergeWithKey.js +1 -1
- package/dist/types/components/Checkbox/Checkbox.d.ts +1 -1
- package/dist/types/components/Checkbox/Input.d.ts +1 -1
- package/dist/types/components/Dialog/Dialog.d.ts +18 -2
- package/dist/types/components/Dialog/DialogActions.d.ts +3 -0
- package/dist/types/components/Dialog/{CustomContent.d.ts → DialogContent.d.ts} +2 -2
- package/dist/types/components/Dialog/DialogHeader.d.ts +3 -0
- package/dist/types/components/Dialog/DialogTitle.d.ts +3 -0
- package/dist/types/components/Dialog/index.d.ts +10 -7
- package/dist/types/components/Group/Group.d.ts +3 -0
- package/dist/types/components/Group/Group.tokens.d.ts +4 -0
- package/dist/types/components/Group/index.d.ts +1 -0
- package/dist/types/components/Icon/Icon.d.ts +2 -2
- package/dist/types/components/Menu/Menu.d.ts +1 -1
- package/dist/types/components/Menu/MenuSection.d.ts +1 -2
- package/dist/types/components/Popover/Popover.d.ts +1 -1
- package/dist/types/components/Popover/PopoverActions.d.ts +3 -0
- package/dist/types/components/Popover/PopoverHeader.d.ts +3 -0
- package/dist/types/components/Popover/index.d.ts +5 -1
- package/dist/types/components/Progress/Circular/CircularProgress.d.ts +1 -1
- package/dist/types/components/Progress/Dots/DotProgress.d.ts +1 -1
- package/dist/types/components/Progress/Star/StarProgress.d.ts +1 -1
- package/dist/types/components/Scrim/Scrim.d.ts +7 -3
- package/dist/types/components/Switch/Switch.d.ts +1 -1
- package/dist/types/components/Switch/Switch.styles.d.ts +2 -1
- package/dist/types/components/Tooltip/Tooltip.d.ts +1 -1
- package/dist/types/components/TopBar/TopBar.tokens.d.ts +1 -1
- package/dist/types/index.d.ts +1 -0
- package/package.json +47 -39
- package/dist/esm/components/Dialog/Actions.js +0 -24
- package/dist/esm/components/Dialog/CustomContent.js +0 -40
- package/dist/esm/components/Dialog/Title.js +0 -35
- package/dist/esm/hooks/useAutoResize.js +0 -39
- package/dist/esm/hooks/useCombinedRefs.js +0 -14
- package/dist/esm/hooks/useGlobalKeyPress.js +0 -34
- package/dist/esm/hooks/useHideBodyScroll.js +0 -12
- package/dist/esm/hooks/useId.js +0 -14
- package/dist/esm/hooks/useMountedRef.js +0 -12
- package/dist/esm/hooks/useOutsideClick.js +0 -18
- package/dist/esm/hooks/usePopper.js +0 -31
- package/dist/esm/hooks/useToken.js +0 -16
- package/dist/esm/utils/joinHandlers.js +0 -10
- package/dist/esm/utils/setReactInputValue.js +0 -18
- package/dist/esm/utils/templates/borders.js +0 -35
- package/dist/esm/utils/templates/common.js +0 -19
- package/dist/esm/utils/templates/focus.js +0 -35
- package/dist/esm/utils/templates/index.js +0 -52
- package/dist/types/components/Combobox/Combobox.d.ts +0 -55
- package/dist/types/components/Combobox/Combobox.tokens.d.ts +0 -3
- package/dist/types/components/Combobox/index.d.ts +0 -1
- package/dist/types/components/Dialog/Actions.d.ts +0 -3
- package/dist/types/components/Dialog/Title.d.ts +0 -3
- package/dist/types/hooks/index.d.ts +0 -9
- package/dist/types/hooks/useAutoResize.d.ts +0 -1
- package/dist/types/hooks/useCombinedRefs.d.ts +0 -3
- package/dist/types/hooks/useGlobalKeyPress.d.ts +0 -10
- package/dist/types/hooks/useHideBodyScroll.d.ts +0 -1
- package/dist/types/hooks/useId.d.ts +0 -1
- package/dist/types/hooks/useMountedRef.d.ts +0 -1
- package/dist/types/hooks/useOutsideClick.d.ts +0 -1
- package/dist/types/hooks/usePopper.d.ts +0 -12
- package/dist/types/hooks/useToken.d.ts +0 -7
- package/dist/types/utils/index.d.ts +0 -4
- package/dist/types/utils/joinHandlers.d.ts +0 -3
- package/dist/types/utils/setReactInputValue.d.ts +0 -7
- package/dist/types/utils/templates/borders.d.ts +0 -2
- package/dist/types/utils/templates/common.d.ts +0 -9
- package/dist/types/utils/templates/focus.d.ts +0 -2
- package/dist/types/utils/templates/index.d.ts +0 -7
|
@@ -1,10 +1,14 @@
|
|
|
1
1
|
import { Popover as BaseComponent, PopoverProps } from './Popover';
|
|
2
2
|
import { PopoverTitle, PopoverTitleProps } from './PopoverTitle';
|
|
3
3
|
import { PopoverContent, PopoverContentProps } from './PopoverContent';
|
|
4
|
+
import { PopoverHeader, PopoverHeaderProps } from './PopoverHeader';
|
|
5
|
+
import { PopoverActions, PopoverActionsProps } from './PopoverActions';
|
|
4
6
|
declare type PopoverConformProps = typeof BaseComponent & {
|
|
5
7
|
Title: typeof PopoverTitle;
|
|
6
8
|
Content: typeof PopoverContent;
|
|
9
|
+
Header: typeof PopoverHeader;
|
|
10
|
+
Actions: typeof PopoverActions;
|
|
7
11
|
};
|
|
8
12
|
declare const Popover: PopoverConformProps;
|
|
9
13
|
export { Popover };
|
|
10
|
-
export type { PopoverProps, PopoverContentProps, PopoverTitleProps };
|
|
14
|
+
export type { PopoverProps, PopoverContentProps, PopoverTitleProps, PopoverHeaderProps, PopoverActionsProps, };
|
|
@@ -12,5 +12,5 @@ export declare type CircularProgressProps = {
|
|
|
12
12
|
/** @ignore */
|
|
13
13
|
ref?: Ref<SVGSVGElement>;
|
|
14
14
|
} & SVGProps<SVGSVGElement>;
|
|
15
|
-
declare const CircularProgress: import("react").ForwardRefExoticComponent<Pick<CircularProgressProps, "string" | "color" | "fontFamily" | "fontSize" | "fontWeight" | "letterSpacing" | "fontStyle" | "textDecoration" | "
|
|
15
|
+
declare const CircularProgress: import("react").ForwardRefExoticComponent<Pick<CircularProgressProps, "string" | "color" | "fontFamily" | "fontSize" | "fontWeight" | "letterSpacing" | "fontStyle" | "textDecoration" | "width" | "style" | "radius" | "x" | "y" | "filter" | "fill" | "values" | "height" | "type" | "offset" | "clipPath" | "mask" | "path" | "children" | "className" | "id" | "lang" | "tabIndex" | "role" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "key" | "value" | "name" | "end" | "local" | "clip" | "size" | "stroke" | "alphabetic" | "hanging" | "ideographic" | "mathematical" | "variant" | "href" | "max" | "media" | "method" | "min" | "target" | "crossOrigin" | "accentHeight" | "accumulate" | "additive" | "alignmentBaseline" | "allowReorder" | "amplitude" | "arabicForm" | "ascent" | "attributeName" | "attributeType" | "autoReverse" | "azimuth" | "baseFrequency" | "baselineShift" | "baseProfile" | "bbox" | "begin" | "bias" | "by" | "calcMode" | "capHeight" | "clipPathUnits" | "clipRule" | "colorInterpolation" | "colorInterpolationFilters" | "colorProfile" | "colorRendering" | "contentScriptType" | "contentStyleType" | "cursor" | "cx" | "cy" | "d" | "decelerate" | "descent" | "diffuseConstant" | "direction" | "display" | "divisor" | "dominantBaseline" | "dur" | "dx" | "dy" | "edgeMode" | "elevation" | "enableBackground" | "exponent" | "externalResourcesRequired" | "fillOpacity" | "fillRule" | "filterRes" | "filterUnits" | "floodColor" | "floodOpacity" | "focusable" | "fontSizeAdjust" | "fontStretch" | "fontVariant" | "format" | "fr" | "from" | "fx" | "fy" | "g1" | "g2" | "glyphName" | "glyphOrientationHorizontal" | "glyphOrientationVertical" | "glyphRef" | "gradientTransform" | "gradientUnits" | "horizAdvX" | "horizOriginX" | "imageRendering" | "in2" | "in" | "intercept" | "k1" | "k2" | "k3" | "k4" | "k" | "kernelMatrix" | "kernelUnitLength" | "kerning" | "keyPoints" | "keySplines" | "keyTimes" | "lengthAdjust" | "lightingColor" | "limitingConeAngle" | "markerEnd" | "markerHeight" | "markerMid" | "markerStart" | "markerUnits" | "markerWidth" | "maskContentUnits" | "maskUnits" | "mode" | "numOctaves" | "opacity" | "operator" | "order" | "orient" | "orientation" | "origin" | "overflow" | "overlinePosition" | "overlineThickness" | "paintOrder" | "panose1" | "pathLength" | "patternContentUnits" | "patternTransform" | "patternUnits" | "pointerEvents" | "points" | "pointsAtX" | "pointsAtY" | "pointsAtZ" | "preserveAlpha" | "preserveAspectRatio" | "primitiveUnits" | "r" | "refX" | "refY" | "renderingIntent" | "repeatCount" | "repeatDur" | "requiredExtensions" | "requiredFeatures" | "restart" | "result" | "rotate" | "rx" | "ry" | "scale" | "seed" | "shapeRendering" | "slope" | "spacing" | "specularConstant" | "specularExponent" | "speed" | "spreadMethod" | "startOffset" | "stdDeviation" | "stemh" | "stemv" | "stitchTiles" | "stopColor" | "stopOpacity" | "strikethroughPosition" | "strikethroughThickness" | "strokeDasharray" | "strokeDashoffset" | "strokeLinecap" | "strokeLinejoin" | "strokeMiterlimit" | "strokeOpacity" | "strokeWidth" | "surfaceScale" | "systemLanguage" | "tableValues" | "targetX" | "targetY" | "textAnchor" | "textLength" | "textRendering" | "to" | "transform" | "u1" | "u2" | "underlinePosition" | "underlineThickness" | "unicode" | "unicodeBidi" | "unicodeRange" | "unitsPerEm" | "vAlphabetic" | "vectorEffect" | "version" | "vertAdvY" | "vertOriginX" | "vertOriginY" | "vHanging" | "vIdeographic" | "viewBox" | "viewTarget" | "visibility" | "vMathematical" | "widths" | "wordSpacing" | "writingMode" | "x1" | "x2" | "xChannelSelector" | "xHeight" | "xlinkActuate" | "xlinkArcrole" | "xlinkHref" | "xlinkRole" | "xlinkShow" | "xlinkTitle" | "xlinkType" | "xmlBase" | "xmlLang" | "xmlns" | "xmlnsXlink" | "xmlSpace" | "y1" | "y2" | "yChannelSelector" | "z" | "zoomAndPan"> & import("react").RefAttributes<SVGSVGElement>>;
|
|
16
16
|
export { CircularProgress };
|
|
@@ -7,5 +7,5 @@ export declare type DotProgressProps = {
|
|
|
7
7
|
/** @ignore */
|
|
8
8
|
ref?: Ref<SVGSVGElement>;
|
|
9
9
|
} & SVGProps<SVGSVGElement>;
|
|
10
|
-
declare const DotProgress: import("react").ForwardRefExoticComponent<Pick<DotProgressProps, "string" | "color" | "fontFamily" | "fontSize" | "fontWeight" | "letterSpacing" | "fontStyle" | "textDecoration" | "
|
|
10
|
+
declare const DotProgress: import("react").ForwardRefExoticComponent<Pick<DotProgressProps, "string" | "color" | "fontFamily" | "fontSize" | "fontWeight" | "letterSpacing" | "fontStyle" | "textDecoration" | "width" | "style" | "radius" | "x" | "y" | "filter" | "fill" | "values" | "height" | "type" | "offset" | "clipPath" | "mask" | "path" | "children" | "className" | "id" | "lang" | "tabIndex" | "role" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "key" | "name" | "end" | "local" | "clip" | "size" | "stroke" | "alphabetic" | "hanging" | "ideographic" | "mathematical" | "href" | "max" | "media" | "method" | "min" | "target" | "crossOrigin" | "accentHeight" | "accumulate" | "additive" | "alignmentBaseline" | "allowReorder" | "amplitude" | "arabicForm" | "ascent" | "attributeName" | "attributeType" | "autoReverse" | "azimuth" | "baseFrequency" | "baselineShift" | "baseProfile" | "bbox" | "begin" | "bias" | "by" | "calcMode" | "capHeight" | "clipPathUnits" | "clipRule" | "colorInterpolation" | "colorInterpolationFilters" | "colorProfile" | "colorRendering" | "contentScriptType" | "contentStyleType" | "cursor" | "cx" | "cy" | "d" | "decelerate" | "descent" | "diffuseConstant" | "direction" | "display" | "divisor" | "dominantBaseline" | "dur" | "dx" | "dy" | "edgeMode" | "elevation" | "enableBackground" | "exponent" | "externalResourcesRequired" | "fillOpacity" | "fillRule" | "filterRes" | "filterUnits" | "floodColor" | "floodOpacity" | "focusable" | "fontSizeAdjust" | "fontStretch" | "fontVariant" | "format" | "fr" | "from" | "fx" | "fy" | "g1" | "g2" | "glyphName" | "glyphOrientationHorizontal" | "glyphOrientationVertical" | "glyphRef" | "gradientTransform" | "gradientUnits" | "horizAdvX" | "horizOriginX" | "imageRendering" | "in2" | "in" | "intercept" | "k1" | "k2" | "k3" | "k4" | "k" | "kernelMatrix" | "kernelUnitLength" | "kerning" | "keyPoints" | "keySplines" | "keyTimes" | "lengthAdjust" | "lightingColor" | "limitingConeAngle" | "markerEnd" | "markerHeight" | "markerMid" | "markerStart" | "markerUnits" | "markerWidth" | "maskContentUnits" | "maskUnits" | "mode" | "numOctaves" | "opacity" | "operator" | "order" | "orient" | "orientation" | "origin" | "overflow" | "overlinePosition" | "overlineThickness" | "paintOrder" | "panose1" | "pathLength" | "patternContentUnits" | "patternTransform" | "patternUnits" | "pointerEvents" | "points" | "pointsAtX" | "pointsAtY" | "pointsAtZ" | "preserveAlpha" | "preserveAspectRatio" | "primitiveUnits" | "r" | "refX" | "refY" | "renderingIntent" | "repeatCount" | "repeatDur" | "requiredExtensions" | "requiredFeatures" | "restart" | "result" | "rotate" | "rx" | "ry" | "scale" | "seed" | "shapeRendering" | "slope" | "spacing" | "specularConstant" | "specularExponent" | "speed" | "spreadMethod" | "startOffset" | "stdDeviation" | "stemh" | "stemv" | "stitchTiles" | "stopColor" | "stopOpacity" | "strikethroughPosition" | "strikethroughThickness" | "strokeDasharray" | "strokeDashoffset" | "strokeLinecap" | "strokeLinejoin" | "strokeMiterlimit" | "strokeOpacity" | "strokeWidth" | "surfaceScale" | "systemLanguage" | "tableValues" | "targetX" | "targetY" | "textAnchor" | "textLength" | "textRendering" | "to" | "transform" | "u1" | "u2" | "underlinePosition" | "underlineThickness" | "unicode" | "unicodeBidi" | "unicodeRange" | "unitsPerEm" | "vAlphabetic" | "vectorEffect" | "version" | "vertAdvY" | "vertOriginX" | "vertOriginY" | "vHanging" | "vIdeographic" | "viewBox" | "viewTarget" | "visibility" | "vMathematical" | "widths" | "wordSpacing" | "writingMode" | "x1" | "x2" | "xChannelSelector" | "xHeight" | "xlinkActuate" | "xlinkArcrole" | "xlinkHref" | "xlinkRole" | "xlinkShow" | "xlinkTitle" | "xlinkType" | "xmlBase" | "xmlLang" | "xmlns" | "xmlnsXlink" | "xmlSpace" | "y1" | "y2" | "yChannelSelector" | "z" | "zoomAndPan"> & import("react").RefAttributes<SVGSVGElement>>;
|
|
11
11
|
export { DotProgress };
|
|
@@ -10,5 +10,5 @@ export declare type StarProgressProps = {
|
|
|
10
10
|
/** @ignore */
|
|
11
11
|
ref?: Ref<SVGSVGElement>;
|
|
12
12
|
} & SVGProps<SVGSVGElement>;
|
|
13
|
-
declare const StarProgress: import("react").ForwardRefExoticComponent<Pick<StarProgressProps, "string" | "color" | "fontFamily" | "fontSize" | "fontWeight" | "letterSpacing" | "fontStyle" | "textDecoration" | "
|
|
13
|
+
declare const StarProgress: import("react").ForwardRefExoticComponent<Pick<StarProgressProps, "string" | "color" | "fontFamily" | "fontSize" | "fontWeight" | "letterSpacing" | "fontStyle" | "textDecoration" | "width" | "style" | "radius" | "x" | "y" | "filter" | "fill" | "values" | "height" | "type" | "offset" | "clipPath" | "mask" | "path" | "children" | "className" | "id" | "lang" | "tabIndex" | "role" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "key" | "value" | "name" | "end" | "local" | "clip" | "size" | "stroke" | "alphabetic" | "hanging" | "ideographic" | "mathematical" | "variant" | "href" | "max" | "media" | "method" | "min" | "target" | "crossOrigin" | "accentHeight" | "accumulate" | "additive" | "alignmentBaseline" | "allowReorder" | "amplitude" | "arabicForm" | "ascent" | "attributeName" | "attributeType" | "autoReverse" | "azimuth" | "baseFrequency" | "baselineShift" | "baseProfile" | "bbox" | "begin" | "bias" | "by" | "calcMode" | "capHeight" | "clipPathUnits" | "clipRule" | "colorInterpolation" | "colorInterpolationFilters" | "colorProfile" | "colorRendering" | "contentScriptType" | "contentStyleType" | "cursor" | "cx" | "cy" | "d" | "decelerate" | "descent" | "diffuseConstant" | "direction" | "display" | "divisor" | "dominantBaseline" | "dur" | "dx" | "dy" | "edgeMode" | "elevation" | "enableBackground" | "exponent" | "externalResourcesRequired" | "fillOpacity" | "fillRule" | "filterRes" | "filterUnits" | "floodColor" | "floodOpacity" | "focusable" | "fontSizeAdjust" | "fontStretch" | "fontVariant" | "format" | "fr" | "from" | "fx" | "fy" | "g1" | "g2" | "glyphName" | "glyphOrientationHorizontal" | "glyphOrientationVertical" | "glyphRef" | "gradientTransform" | "gradientUnits" | "horizAdvX" | "horizOriginX" | "imageRendering" | "in2" | "in" | "intercept" | "k1" | "k2" | "k3" | "k4" | "k" | "kernelMatrix" | "kernelUnitLength" | "kerning" | "keyPoints" | "keySplines" | "keyTimes" | "lengthAdjust" | "lightingColor" | "limitingConeAngle" | "markerEnd" | "markerHeight" | "markerMid" | "markerStart" | "markerUnits" | "markerWidth" | "maskContentUnits" | "maskUnits" | "mode" | "numOctaves" | "opacity" | "operator" | "order" | "orient" | "orientation" | "origin" | "overflow" | "overlinePosition" | "overlineThickness" | "paintOrder" | "panose1" | "pathLength" | "patternContentUnits" | "patternTransform" | "patternUnits" | "pointerEvents" | "points" | "pointsAtX" | "pointsAtY" | "pointsAtZ" | "preserveAlpha" | "preserveAspectRatio" | "primitiveUnits" | "r" | "refX" | "refY" | "renderingIntent" | "repeatCount" | "repeatDur" | "requiredExtensions" | "requiredFeatures" | "restart" | "result" | "rotate" | "rx" | "ry" | "scale" | "seed" | "shapeRendering" | "slope" | "spacing" | "specularConstant" | "specularExponent" | "speed" | "spreadMethod" | "startOffset" | "stdDeviation" | "stemh" | "stemv" | "stitchTiles" | "stopColor" | "stopOpacity" | "strikethroughPosition" | "strikethroughThickness" | "strokeDasharray" | "strokeDashoffset" | "strokeLinecap" | "strokeLinejoin" | "strokeMiterlimit" | "strokeOpacity" | "strokeWidth" | "surfaceScale" | "systemLanguage" | "tableValues" | "targetX" | "targetY" | "textAnchor" | "textLength" | "textRendering" | "to" | "transform" | "u1" | "u2" | "underlinePosition" | "underlineThickness" | "unicode" | "unicodeBidi" | "unicodeRange" | "unitsPerEm" | "vAlphabetic" | "vectorEffect" | "version" | "vertAdvY" | "vertOriginX" | "vertOriginY" | "vHanging" | "vIdeographic" | "viewBox" | "viewTarget" | "visibility" | "vMathematical" | "widths" | "wordSpacing" | "writingMode" | "x1" | "x2" | "xChannelSelector" | "xHeight" | "xlinkActuate" | "xlinkArcrole" | "xlinkHref" | "xlinkRole" | "xlinkShow" | "xlinkTitle" | "xlinkType" | "xmlBase" | "xmlLang" | "xmlns" | "xmlnsXlink" | "xmlSpace" | "y1" | "y2" | "yChannelSelector" | "z" | "zoomAndPan"> & import("react").RefAttributes<SVGSVGElement>>;
|
|
14
14
|
export { StarProgress };
|
|
@@ -1,15 +1,19 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { HTMLAttributes } from 'react';
|
|
2
2
|
export declare type ScrimProps = {
|
|
3
3
|
/** Whether scrim can be dismissed with esc key and outside click
|
|
4
4
|
*/
|
|
5
5
|
isDismissable?: boolean;
|
|
6
|
+
/** programmatically toggle scrim */
|
|
7
|
+
open: boolean;
|
|
6
8
|
/** function to handle closing scrim */
|
|
7
|
-
onClose?: (
|
|
9
|
+
onClose?: () => void;
|
|
8
10
|
} & HTMLAttributes<HTMLDivElement>;
|
|
9
11
|
export declare const Scrim: import("react").ForwardRefExoticComponent<{
|
|
10
12
|
/** Whether scrim can be dismissed with esc key and outside click
|
|
11
13
|
*/
|
|
12
14
|
isDismissable?: boolean;
|
|
15
|
+
/** programmatically toggle scrim */
|
|
16
|
+
open: boolean;
|
|
13
17
|
/** function to handle closing scrim */
|
|
14
|
-
onClose?: (
|
|
18
|
+
onClose?: () => void;
|
|
15
19
|
} & HTMLAttributes<HTMLDivElement> & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -9,4 +9,4 @@ export declare type SwitchProps = {
|
|
|
9
9
|
} & Omit<InputHTMLAttributes<HTMLInputElement>, 'size'> & {
|
|
10
10
|
ref?: Ref<HTMLInputElement>;
|
|
11
11
|
};
|
|
12
|
-
export declare const Switch: import("react").ForwardRefExoticComponent<Pick<SwitchProps, "color" | "
|
|
12
|
+
export declare const Switch: import("react").ForwardRefExoticComponent<Pick<SwitchProps, "color" | "width" | "style" | "height" | "type" | "disabled" | "readOnly" | "form" | "label" | "slot" | "title" | "pattern" | "children" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "list" | "value" | "name" | "autoFocus" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "size" | "multiple" | "step" | "max" | "min" | "crossOrigin" | "alt" | "src" | "autoComplete" | "accept" | "capture" | "checked" | "enterKeyHint" | "maxLength" | "minLength" | "required"> & import("react").RefAttributes<HTMLInputElement>>;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
1
2
|
export declare const BaseInputWrapper: import("styled-components").StyledComponent<"span", import("styled-components").DefaultTheme, {}, never>;
|
|
2
3
|
export declare const BaseInput: import("styled-components").StyledComponent<"input", import("styled-components").DefaultTheme, {
|
|
3
|
-
type:
|
|
4
|
+
type: import("react").HTMLInputTypeAttribute;
|
|
4
5
|
}, "type">;
|
|
5
6
|
export declare const GridWrapper: import("styled-components").StyledComponent<"span", import("styled-components").DefaultTheme, {}, never>;
|
package/dist/types/index.d.ts
CHANGED
package/package.json
CHANGED
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@equinor/eds-core-react",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.18.0-dev.20220210",
|
|
4
4
|
"description": "The React implementation of the Equinor Design System",
|
|
5
|
-
"sideEffects":
|
|
6
|
-
|
|
5
|
+
"sideEffects": [
|
|
6
|
+
"**/*.css"
|
|
7
|
+
],
|
|
8
|
+
"main": "dist/eds-core-react.cjs.js",
|
|
7
9
|
"publishConfig": {
|
|
8
|
-
"main": "dist/core-react.cjs.js",
|
|
10
|
+
"main": "dist/eds-core-react.cjs.js",
|
|
9
11
|
"module": "dist/esm/index.js"
|
|
10
12
|
},
|
|
11
13
|
"types": "dist/types/index.d.ts",
|
|
@@ -18,7 +20,7 @@
|
|
|
18
20
|
"repository": {
|
|
19
21
|
"type": "git",
|
|
20
22
|
"url": "https://github.com/equinor/design-system",
|
|
21
|
-
"directory": "
|
|
23
|
+
"directory": "packages/eds-core-react"
|
|
22
24
|
},
|
|
23
25
|
"bugs": {
|
|
24
26
|
"url": "https://github.com/equinor/design-system/issues"
|
|
@@ -33,44 +35,48 @@
|
|
|
33
35
|
"react"
|
|
34
36
|
],
|
|
35
37
|
"devDependencies": {
|
|
36
|
-
"@babel/cli": "^7.
|
|
37
|
-
"@babel/core": "^7.
|
|
38
|
-
"@babel/plugin-transform-runtime": "^7.
|
|
39
|
-
"@babel/preset-env": "^7.
|
|
40
|
-
"@babel/preset-react": "^7.
|
|
41
|
-
"@babel/preset-typescript": "^7.
|
|
38
|
+
"@babel/cli": "^7.17.0",
|
|
39
|
+
"@babel/core": "^7.17.0",
|
|
40
|
+
"@babel/plugin-transform-runtime": "^7.17.0",
|
|
41
|
+
"@babel/preset-env": "^7.16.11",
|
|
42
|
+
"@babel/preset-react": "^7.16.7",
|
|
43
|
+
"@babel/preset-typescript": "^7.16.7",
|
|
42
44
|
"@rollup/plugin-babel": "^5.3.0",
|
|
43
|
-
"@rollup/plugin-commonjs": "^19.0.
|
|
44
|
-
"@rollup/plugin-node-resolve": "^13.
|
|
45
|
-
"@storybook/addon-a11y": "^6.
|
|
46
|
-
"@storybook/addon-actions": "^6.
|
|
47
|
-
"@storybook/addon-
|
|
48
|
-
"@storybook/addon-
|
|
49
|
-
"@storybook/
|
|
50
|
-
"@
|
|
51
|
-
"@
|
|
52
|
-
"@testing-library/
|
|
53
|
-
"@testing-library/
|
|
45
|
+
"@rollup/plugin-commonjs": "^19.0.2",
|
|
46
|
+
"@rollup/plugin-node-resolve": "^13.1.3",
|
|
47
|
+
"@storybook/addon-a11y": "^6.4.18",
|
|
48
|
+
"@storybook/addon-actions": "^6.4.18",
|
|
49
|
+
"@storybook/addon-docs": "^6.4.18",
|
|
50
|
+
"@storybook/addon-essentials": "^6.4.18",
|
|
51
|
+
"@storybook/addon-links": "^6.4.18",
|
|
52
|
+
"@storybook/client-api": "^6.4.18",
|
|
53
|
+
"@storybook/react": "^6.4.18",
|
|
54
|
+
"@testing-library/jest-dom": "^5.16.2",
|
|
55
|
+
"@testing-library/react": "^12.1.2",
|
|
56
|
+
"@testing-library/react-hooks": "^7.0.2",
|
|
57
|
+
"@testing-library/user-event": "^13.5.0",
|
|
54
58
|
"@types/jest": "^26.0.24",
|
|
55
|
-
"@types/ramda": "^0.27.
|
|
56
|
-
"@types/react": "^17.0.
|
|
57
|
-
"@types/react-dom": "^17.0.
|
|
58
|
-
"@types/styled-components": "^5.1.
|
|
59
|
-
"@types/testing-library__jest-dom": "^5.14.
|
|
60
|
-
"babel-loader": "^8.2.
|
|
61
|
-
"babel-plugin-styled-components": "^1.13.
|
|
62
|
-
"jest": "^27.
|
|
63
|
-
"jest-styled-components": "^7.0.
|
|
59
|
+
"@types/ramda": "^0.27.64",
|
|
60
|
+
"@types/react": "^17.0.39",
|
|
61
|
+
"@types/react-dom": "^17.0.11",
|
|
62
|
+
"@types/styled-components": "^5.1.21",
|
|
63
|
+
"@types/testing-library__jest-dom": "^5.14.2",
|
|
64
|
+
"babel-loader": "^8.2.3",
|
|
65
|
+
"babel-plugin-styled-components": "^1.13.3",
|
|
66
|
+
"jest": "^27.4.7",
|
|
67
|
+
"jest-styled-components": "^7.0.8",
|
|
64
68
|
"js-file-download": "^0.4.12",
|
|
65
|
-
"
|
|
69
|
+
"postcss": "^8.4.6",
|
|
70
|
+
"ramda": "^0.27.2",
|
|
66
71
|
"react": "^17.0.2",
|
|
67
72
|
"react-dom": "^17.0.2",
|
|
68
|
-
"react-hook-form": "^7.
|
|
69
|
-
"rollup": "^2.
|
|
73
|
+
"react-hook-form": "^7.26.0",
|
|
74
|
+
"rollup": "^2.67.0",
|
|
70
75
|
"rollup-plugin-delete": "^2.0.0",
|
|
76
|
+
"rollup-plugin-postcss": "^4.0.2",
|
|
71
77
|
"styled-components": "5.3.0",
|
|
72
|
-
"tsc-watch": "^4.
|
|
73
|
-
"typescript": "^4.
|
|
78
|
+
"tsc-watch": "^4.6.0",
|
|
79
|
+
"typescript": "^4.5.5"
|
|
74
80
|
},
|
|
75
81
|
"peerDependencies": {
|
|
76
82
|
"react": ">=16.8",
|
|
@@ -78,9 +84,10 @@
|
|
|
78
84
|
"styled-components": ">=4.2"
|
|
79
85
|
},
|
|
80
86
|
"dependencies": {
|
|
81
|
-
"@babel/runtime": "^7.
|
|
82
|
-
"@equinor/eds-icons": "0.
|
|
87
|
+
"@babel/runtime": "^7.17.0",
|
|
88
|
+
"@equinor/eds-icons": "0.10.0",
|
|
83
89
|
"@equinor/eds-tokens": "0.7.0",
|
|
90
|
+
"@equinor/eds-utils": "0.1.0-dev.20220210",
|
|
84
91
|
"@popperjs/core": "2.9.2",
|
|
85
92
|
"downshift": "^6.1.7",
|
|
86
93
|
"react-fast-compare": "3.2.0",
|
|
@@ -99,5 +106,6 @@
|
|
|
99
106
|
"storybook": "start-storybook -p 9000 --ci",
|
|
100
107
|
"build:storybook": "build-storybook -o storybook-build"
|
|
101
108
|
},
|
|
102
|
-
"module": "dist/esm/index.js"
|
|
109
|
+
"module": "dist/esm/index.js",
|
|
110
|
+
"readme": "# @equinor/eds-core-react\n\nAvailable components to help style your React application as an Equinor application. We publish new components regularly so make sure to check back often!\n\nMake sure to check out our [Storybook](https://eds-storybook-react.azurewebsites.net/) for more examples!\nRead the [changelog](https://github.com/equinor/design-system/blob/develop/packages/eds-core-react/CHANGELOG.md) for details on specific releases.\n\n## Installation\n\n```sh\nnpm install @equinor/eds-core-react styled-components\n```\nIf you use Typescript, make sure you have typescript >= 3.8 as a devDependency:\n```sh\nnpm install typescript --save-dev\n```\n\n## Usage\n\n```jsx\nimport * as React from 'react'\nimport { render } from 'react-dom'\nimport { Button, Typography } from '@equinor/eds-core-react'\n\nconst App = () => (\n <>\n <Typography variant=\"h1\" bold>Buttons</Typography>\n\n <Typography variant=\"h2\">Contained (default)</Typography>\n\n <Button>Primary</Button>\n <Button color=\"secondary\">Secondary</Button>\n <Button color=\"danger\">Danger</Button>\n <Button disabled>Disabled</Button>\n\n <Typography variant=\"h2\">Outlined</Typography>\n\n <Button variant=\"outlined\">Primary</Button>\n <Button variant=\"outlined\" color=\"secondary\">Secondary</Button>\n <Button variant=\"outlined\" color=\"danger\">Danger</Button>\n <Button variant=\"outlined\" disabled>Disabled</Button>\n\n <Typography variant=\"h2\">Ghost</Typography>\n\n <Button variant=\"ghost\">Primary</Button>\n <Button variant=\"ghost\" color=\"secondary\">Secondary</Button>\n <Button variant=\"ghost\" color=\"danger\">Danger</Button>\n <Button variant=\"ghost\" disabled>Disabled</Button>\n </>\n)\n\nrender(<App />, document.getElementById('root'))\n```\n\n\n## Components\n\n### Available ✅\n\n- Accordion\n- Banner\n- Breadcrumbs\n- Button\n- Cards\n- Chips\n- Dialog\n- Divider\n- Icon\n- List\n- Menu\n- Pagination\n- Popover\n- Progress indicators\n- Scrim\n- Search\n- Select (Native Select)\n- Single Select\n- Multi Select\n- Selection Controls\n- Side Sheet\n- Slider\n- Snackbar\n- Table\n- Table of contents\n- Tabs\n- TextField\n- Tooltip\n- TopBar\n- Typography\n\n### In progress 👷♀️\n\n- Navigation Drawer\n\n### TODO 🛠️\n\n- App launcher\n- Stepper\n\n"
|
|
103
111
|
}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { forwardRef } from 'react';
|
|
2
|
-
import styled, { css } from 'styled-components';
|
|
3
|
-
import { dialog } from './Dialog.tokens.js';
|
|
4
|
-
import { jsx } from 'react/jsx-runtime';
|
|
5
|
-
import { spacingsTemplate } from '../../utils/templates/index.js';
|
|
6
|
-
|
|
7
|
-
const StyledActions = styled.div.withConfig({
|
|
8
|
-
displayName: "Actions__StyledActions",
|
|
9
|
-
componentId: "sc-1qfwg1m-0"
|
|
10
|
-
})(["min-height:", ";", " align-self:end;justify-self:start;", ""], dialog.entities.actions.minHeight, spacingsTemplate(dialog.entities.children.spacings), ({
|
|
11
|
-
children
|
|
12
|
-
}) => !children && css(["min-height:initial;height:'8px';"]));
|
|
13
|
-
const Actions = /*#__PURE__*/forwardRef(function Actions({
|
|
14
|
-
children,
|
|
15
|
-
...props
|
|
16
|
-
}, ref) {
|
|
17
|
-
return /*#__PURE__*/jsx(StyledActions, {
|
|
18
|
-
ref: ref,
|
|
19
|
-
...props,
|
|
20
|
-
children: children
|
|
21
|
-
});
|
|
22
|
-
}); // Actions.displayName = 'EdsDialogActions'
|
|
23
|
-
|
|
24
|
-
export { Actions };
|
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
import { forwardRef } from 'react';
|
|
2
|
-
import styled, { css } from 'styled-components';
|
|
3
|
-
import { dialog } from './Dialog.tokens.js';
|
|
4
|
-
import { jsxs, Fragment, jsx } from 'react/jsx-runtime';
|
|
5
|
-
import { typographyTemplate, spacingsTemplate } from '../../utils/templates/index.js';
|
|
6
|
-
import { Divider } from '../Divider/Divider.js';
|
|
7
|
-
|
|
8
|
-
const StyledCustomContent = styled.div.withConfig({
|
|
9
|
-
displayName: "CustomContent__StyledCustomContent",
|
|
10
|
-
componentId: "sc-17fsw6x-0"
|
|
11
|
-
})(["", " min-height:", ";margin-bottom:", ";align-self:stretch;justify-self:stretch;", " ", ""], typographyTemplate(dialog.entities.content.typography), dialog.entities.content.minHeight, dialog.entities.content.spacings.bottom, spacingsTemplate(dialog.entities.children.spacings), ({
|
|
12
|
-
scrollable
|
|
13
|
-
}) => scrollable && css(["min-height:initial;height:", ";overflow-y:auto;"], dialog.entities.content.height));
|
|
14
|
-
const StyledDivider = styled(Divider).withConfig({
|
|
15
|
-
displayName: "CustomContent__StyledDivider",
|
|
16
|
-
componentId: "sc-17fsw6x-1"
|
|
17
|
-
})(["width:100%;margin-bottom:", ";"], dialog.entities.divider.spacings.bottom);
|
|
18
|
-
const CustomContent = /*#__PURE__*/forwardRef(function CustomContent({
|
|
19
|
-
children,
|
|
20
|
-
scrollable = false,
|
|
21
|
-
...rest
|
|
22
|
-
}, ref) {
|
|
23
|
-
const props = {
|
|
24
|
-
scrollable,
|
|
25
|
-
ref,
|
|
26
|
-
...rest
|
|
27
|
-
};
|
|
28
|
-
return /*#__PURE__*/jsxs(Fragment, {
|
|
29
|
-
children: [/*#__PURE__*/jsx(StyledCustomContent, {
|
|
30
|
-
id: "eds-dialog-customcontent",
|
|
31
|
-
...props,
|
|
32
|
-
children: children
|
|
33
|
-
}), children && scrollable && /*#__PURE__*/jsx(StyledDivider, {
|
|
34
|
-
color: "medium",
|
|
35
|
-
variant: "small"
|
|
36
|
-
})]
|
|
37
|
-
});
|
|
38
|
-
});
|
|
39
|
-
|
|
40
|
-
export { CustomContent };
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import { forwardRef } from 'react';
|
|
2
|
-
import styled, { css } from 'styled-components';
|
|
3
|
-
import { dialog } from './Dialog.tokens.js';
|
|
4
|
-
import { jsxs, Fragment, jsx } from 'react/jsx-runtime';
|
|
5
|
-
import { Divider } from '../Divider/Divider.js';
|
|
6
|
-
import { typographyTemplate, spacingsTemplate } from '../../utils/templates/index.js';
|
|
7
|
-
|
|
8
|
-
const StyledTitle = styled.div.withConfig({
|
|
9
|
-
displayName: "Title__StyledTitle",
|
|
10
|
-
componentId: "sc-i4qfl5-0"
|
|
11
|
-
})(["", " min-height:", ";align-self:end;justify-self:start;", ";", ""], typographyTemplate(dialog.entities.title.typography), dialog.entities.title.minHeight, spacingsTemplate(dialog.entities.children.spacings), ({
|
|
12
|
-
children
|
|
13
|
-
}) => !children && css(["min-height:initial;height:'8px';"]));
|
|
14
|
-
const StyledDivider = styled(Divider).withConfig({
|
|
15
|
-
displayName: "Title__StyledDivider",
|
|
16
|
-
componentId: "sc-i4qfl5-1"
|
|
17
|
-
})(["width:100%;margin-bottom:", ";"], dialog.entities.divider.spacings.bottom);
|
|
18
|
-
const Title = /*#__PURE__*/forwardRef(function Title({
|
|
19
|
-
children,
|
|
20
|
-
...rest
|
|
21
|
-
}, ref) {
|
|
22
|
-
return /*#__PURE__*/jsxs(Fragment, {
|
|
23
|
-
children: [/*#__PURE__*/jsx(StyledTitle, {
|
|
24
|
-
id: "eds-dialog-title",
|
|
25
|
-
ref: ref,
|
|
26
|
-
...rest,
|
|
27
|
-
children: children
|
|
28
|
-
}), children && /*#__PURE__*/jsx(StyledDivider, {
|
|
29
|
-
color: "medium",
|
|
30
|
-
variant: "small"
|
|
31
|
-
})]
|
|
32
|
-
});
|
|
33
|
-
});
|
|
34
|
-
|
|
35
|
-
export { Title };
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import { useEffect } from 'react';
|
|
2
|
-
|
|
3
|
-
const useAutoResize = (targetEl, maxHeight) => {
|
|
4
|
-
useEffect(() => {
|
|
5
|
-
const handleResize = () => {
|
|
6
|
-
targetEl.style.height = 'auto';
|
|
7
|
-
const {
|
|
8
|
-
scrollHeight,
|
|
9
|
-
clientHeight
|
|
10
|
-
} = targetEl;
|
|
11
|
-
let newHeight = clientHeight;
|
|
12
|
-
|
|
13
|
-
if (maxHeight > newHeight) {
|
|
14
|
-
newHeight = Math.min(maxHeight, Math.max(scrollHeight, newHeight));
|
|
15
|
-
|
|
16
|
-
if (scrollHeight > maxHeight) {
|
|
17
|
-
targetEl.style.overflow = 'auto';
|
|
18
|
-
} else {
|
|
19
|
-
targetEl.style.overflow = 'hidden';
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
if (newHeight > clientHeight) {
|
|
23
|
-
targetEl.style.height = "".concat(newHeight, "px");
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
};
|
|
27
|
-
|
|
28
|
-
if (targetEl && maxHeight) {
|
|
29
|
-
handleResize();
|
|
30
|
-
targetEl.addEventListener('keyup', handleResize, true);
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
return () => {
|
|
34
|
-
targetEl === null || targetEl === void 0 ? void 0 : targetEl.removeEventListener('keyup', handleResize, true);
|
|
35
|
-
};
|
|
36
|
-
}, [targetEl, maxHeight]);
|
|
37
|
-
};
|
|
38
|
-
|
|
39
|
-
export { useAutoResize };
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { useCallback } from 'react';
|
|
2
|
-
|
|
3
|
-
/** Returns a memoized function that calls passed refs sequentially with passed element */
|
|
4
|
-
const useCombinedRefs = (...refs) => {
|
|
5
|
-
return useCallback(element => refs.forEach(ref => {
|
|
6
|
-
if (typeof ref === 'function') {
|
|
7
|
-
ref(element);
|
|
8
|
-
} else if (ref && typeof ref === 'object') {
|
|
9
|
-
ref.current = element;
|
|
10
|
-
}
|
|
11
|
-
}), [refs]);
|
|
12
|
-
};
|
|
13
|
-
|
|
14
|
-
export { useCombinedRefs };
|