grommet 2.21.0 → 2.22.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/components/Anchor/index.d.ts +2 -0
- package/components/Anchor/stories/Default.js +17 -8
- package/components/Box/StyledBox.js +1 -3
- package/components/Box/stories/Animation.js +23 -21
- package/components/Box/stories/Background.js +94 -92
- package/components/Box/stories/Border.js +88 -86
- package/components/Box/stories/Custom.js +15 -13
- package/components/Box/stories/Elevation.js +27 -25
- package/components/Box/stories/Fixed.js +43 -41
- package/components/Box/stories/MinMax.js +206 -204
- package/components/Box/stories/OnClick.js +27 -25
- package/components/Box/stories/RTL.js +35 -31
- package/components/Box/stories/Round.js +55 -53
- package/components/Box/stories/Simple.js +46 -44
- package/components/Button/stories/CustomThemed/Active.js +1 -0
- package/components/Button/stories/CustomThemed/Typescript.tsx +1 -1
- package/components/Button/stories/Multiple.js +1 -1
- package/components/Button/stories/typescript/Badge.tsx +58 -0
- package/components/Calendar/Calendar.js +83 -115
- package/components/Calendar/stories/Multiple.js +2 -1
- package/components/Calendar/stories/Simple.js +0 -8
- package/components/Calendar/utils.js +78 -18
- package/components/Carousel/stories/Autoplay.js +6 -3
- package/components/Carousel/stories/ControlVariations.js +9 -9
- package/components/Carousel/stories/Controlled.js +3 -3
- package/components/Carousel/stories/Simple.js +3 -3
- package/components/Chart/stories/Labelled.js +2 -2
- package/components/Chart/utils.js +4 -4
- package/components/CheckBox/stories/Simple.js +9 -3
- package/components/CheckBox/stories/WithStickyDiv.js +1 -1
- package/components/CheckBoxGroup/stories/Disabled.js +7 -1
- package/components/DataChart/DataChart.js +27 -5
- package/components/DataChart/XAxis.js +4 -7
- package/components/DataChart/YAxis.js +4 -7
- package/components/DataChart/YGuide.js +12 -1
- package/components/DataChart/index.d.ts +6 -1
- package/components/DataChart/propTypes.js +4 -1
- package/components/DataChart/stories/Placeholder.js +48 -0
- package/components/DataTable/DataTable.js +57 -45
- package/components/{TextArea/stories/Fill.js → DataTable/PlaceholderBody.js} +14 -42
- package/components/DataTable/stories/MultiplePin.js +1 -1
- package/components/DateInput/DateInput.js +60 -22
- package/components/DateInput/stories/Form.js +2 -1
- package/components/DateInput/stories/Format.js +2 -1
- package/components/DateInput/stories/FormatInline.js +16 -8
- package/components/DateInput/stories/Inline.js +2 -1
- package/components/DateInput/stories/Range.js +2 -1
- package/components/DateInput/stories/RangeFormat.js +2 -1
- package/components/DateInput/stories/Simple.js +2 -1
- package/components/DateInput/stories/typescript/European.tsx +2 -1
- package/components/DateInput/utils.js +2 -2
- package/components/Diagram/stories/Animated.js +43 -41
- package/components/Diagram/stories/Progressing.js +31 -29
- package/components/Diagram/stories/typescript/Connections.tsx +14 -13
- package/components/Distribution/stories/typescript/Simple.tsx +24 -20
- package/components/Drop/Drop.js +12 -6
- package/components/Drop/index.d.ts +1 -0
- package/components/Drop/propTypes.js +1 -0
- package/components/Drop/stories/CustomThemed/Lazy.js +20 -16
- package/components/Drop/stories/CustomThemed/Themed.js +5 -4
- package/components/Drop/stories/Inline.js +69 -0
- package/components/Drop/stories/Meter.js +7 -5
- package/components/Drop/stories/Multiple.js +20 -6
- package/components/Drop/stories/Overflow.js +7 -4
- package/components/Drop/stories/Plain.js +7 -5
- package/components/Drop/stories/Progressive.js +6 -4
- package/components/Drop/stories/Simple.js +6 -4
- package/components/Drop/stories/Styled.js +11 -8
- package/components/Drop/stories/TrapFocus.js +5 -3
- package/components/DropButton/stories/Menu.js +8 -4
- package/components/DropButton/stories/Simple.js +4 -3
- package/components/Footer/stories/DoubleFooter.js +36 -32
- package/components/Footer/stories/Simple.js +24 -20
- package/components/Footer/stories/Sitemap.js +34 -30
- package/components/Footer/stories/Social.js +34 -30
- package/components/Form/stories/AggregateValidation.js +64 -54
- package/components/Form/stories/ArrayOfFormFields.js +58 -54
- package/components/Form/stories/Controlled.js +99 -95
- package/components/Form/stories/ControlledInput.js +129 -125
- package/components/Form/stories/ControlledInputLazy.js +129 -125
- package/components/Form/stories/ControlledLazy.js +97 -93
- package/components/Form/stories/{Custom.js → CustomThemed/Custom.js} +1 -1
- package/components/Form/stories/{FieldBorderPosition.js → CustomThemed/FieldBorderPosition.js} +23 -19
- package/components/Form/stories/{FieldCustomStates.js → CustomThemed/FieldCustomStates.js} +1 -1
- package/components/Form/stories/{FieldSpacingOptions.js → CustomThemed/FieldSpacingOptions.js} +5 -5
- package/components/Form/stories/{RequiredLabel.js → CustomThemed/RequiredLabel.js} +1 -1
- package/components/Form/stories/{Themed.js → CustomThemed/Themed.js} +2 -2
- package/components/Form/stories/DynamicFields.js +62 -58
- package/components/Form/stories/FieldStates.js +62 -60
- package/components/Form/stories/FieldWithChildren.js +109 -105
- package/components/Form/stories/FieldWithComponentProp.js +109 -105
- package/components/Form/stories/HelpAndError.js +39 -18
- package/components/Form/stories/Uncontrolled.js +99 -95
- package/components/Form/stories/ValidateOnBlur.js +65 -61
- package/components/Form/stories/ValidateOnChange.js +82 -78
- package/components/Form/stories/ValidateOnMount.js +67 -63
- package/components/Form/stories/typescript/TypedForm.tsx +69 -66
- package/components/FormField/FormField.js +1 -1
- package/components/FormField/stories/{typescript → CustomThemed}/Custom.tsx +1 -1
- package/components/FormField/stories/Simple.js +22 -20
- package/components/Grid/StyledGrid.js +1 -3
- package/components/Grid/stories/AreasPropAlternative.js +27 -23
- package/components/Grid/stories/Border.js +75 -73
- package/components/Grid/stories/{Responsive.js → CustomThemed/Responsive.js} +1 -1
- package/components/Grid/stories/NColumn.js +28 -24
- package/components/Grid/stories/Percentages.js +30 -26
- package/components/Grid/stories/ResponsiveCards.js +21 -17
- package/components/Grid/stories/typescript/App.tsx +10 -4
- package/components/Image/stories/Fallback.js +10 -8
- package/components/Image/stories/Fill.js +20 -18
- package/components/Image/stories/Fit.js +24 -22
- package/components/Image/stories/Opacity.js +39 -37
- package/components/Image/stories/Simple.js +9 -7
- package/components/InfiniteScroll/stories/Basics.js +18 -16
- package/components/InfiniteScroll/stories/ClassChildren.js +14 -12
- package/components/InfiniteScroll/stories/Grid.js +21 -19
- package/components/InfiniteScroll/stories/GridWithShow.js +22 -20
- package/components/InfiniteScroll/stories/HeightReplace.js +20 -18
- package/components/InfiniteScroll/stories/Marker.js +18 -16
- package/components/InfiniteScroll/stories/Replace.js +19 -17
- package/components/InfiniteScroll/stories/Show.js +18 -16
- package/components/InfiniteScroll/stories/ShowAfter.js +18 -16
- package/components/InfiniteScroll/stories/ShowBefore.js +18 -16
- package/components/InfiniteScroll/stories/Variable.js +19 -17
- package/components/InfiniteScroll/stories/typescript/OnMore.tsx +18 -24
- package/components/InfiniteScroll/stories/typescript/OnMoreStep.tsx +18 -24
- package/components/Keyboard/stories/OnDocument.js +1 -5
- package/components/Layer/stories/Center.js +83 -79
- package/components/Layer/stories/Corner.js +29 -25
- package/components/Layer/stories/{Round.js → CustomThemed/Round.js} +1 -1
- package/components/Layer/stories/Form.js +72 -68
- package/components/Layer/stories/Full.js +37 -33
- package/components/Layer/stories/Notification.js +51 -47
- package/components/Layer/stories/Plain.js +24 -20
- package/components/Layer/stories/RTL.js +32 -28
- package/components/Layer/stories/ScrollBody.js +43 -41
- package/components/Layer/stories/Target.js +74 -70
- package/components/Main/stories/typescript/Simple.tsx +6 -4
- package/components/Markdown/stories/Override.js +14 -12
- package/components/Markdown/stories/Simple.js +12 -10
- package/components/MaskedInput/MaskedInput.js +1 -1
- package/components/MaskedInput/index.d.ts +1 -0
- package/components/MaskedInput/propTypes.js +1 -0
- package/components/MaskedInput/stories/CustomBox.js +48 -44
- package/components/MaskedInput/stories/Date.js +54 -50
- package/components/MaskedInput/stories/DateRange.js +87 -83
- package/components/MaskedInput/stories/DateTimeDrop.js +30 -28
- package/components/MaskedInput/stories/Filtered.js +32 -28
- package/components/MaskedInput/stories/Form.js +34 -32
- package/components/MaskedInput/stories/IPV4Range.js +69 -65
- package/components/MaskedInput/stories/IPv4Address.js +45 -41
- package/components/MaskedInput/stories/Phone.js +43 -39
- package/components/MaskedInput/stories/SizeUnits.js +35 -31
- package/components/MaskedInput/stories/Time.js +46 -42
- package/components/MaskedInput/stories/URL.js +28 -24
- package/components/MaskedInput/stories/typescript/Email.tsx +24 -20
- package/components/Menu/Menu.js +8 -2
- package/components/Menu/stories/Justify.js +4 -4
- package/components/Menu/stories/typescript/Children.tsx +4 -3
- package/components/NameValueList/stories/Align.js +37 -35
- package/components/NameValueList/stories/CustomName.js +23 -21
- package/components/NameValueList/stories/CustomValue.js +64 -62
- package/components/NameValueList/stories/Layout.js +43 -41
- package/components/NameValueList/stories/PairProps.js +24 -22
- package/components/NameValueList/stories/Simple.js +16 -14
- package/components/NameValueList/stories/Width.js +38 -36
- package/components/Nav/stories/Sidebar.js +5 -3
- package/components/Notification/Notification.js +119 -15
- package/components/Notification/index.d.ts +3 -2
- package/components/Notification/propTypes.js +4 -1
- package/components/Notification/stories/Global.js +87 -0
- package/components/{CheckBox/stories/Disabled.js → Page/Page.js} +34 -33
- package/components/Page/PageContext.js +9 -0
- package/components/Page/README.md +2 -0
- package/components/Page/index.d.ts +12 -0
- package/components/Page/index.js +12 -0
- package/components/Page/propTypes.js +19 -0
- package/components/Page/stories/Background.js +42 -0
- package/components/Page/stories/ContentBackground.js +44 -0
- package/components/Page/stories/CustomThemed/LeftColumn.js +78 -0
- package/components/Page/stories/GlobalHeader.js +47 -0
- package/components/Page/stories/MultipleBackgrounds.js +75 -0
- package/components/Page/stories/MultipleContent.js +49 -0
- package/components/Page/stories/PageNotificaton.js +91 -0
- package/components/Page/stories/Simple.js +39 -0
- package/components/{CheckBox/stories/Toggle.js → PageContent/PageContent.js} +28 -32
- package/components/PageContent/README.md +2 -0
- package/components/PageContent/index.d.ts +19 -0
- package/components/PageContent/index.js +8 -0
- package/components/PageContent/propTypes.js +31 -0
- package/components/Pagination/stories/Grid.js +34 -30
- package/components/Pagination/stories/NumberEdgePages.js +18 -16
- package/components/Pagination/stories/NumberMiddlePages.js +18 -16
- package/components/Pagination/stories/Simple.js +19 -17
- package/components/Pagination/stories/Size.js +20 -18
- package/components/RadioButton/stories/CustomThemed/Theme.js +5 -5
- package/components/RadioButtonGroup/stories/CustomThemed/CustomTheme.js +7 -10
- package/components/RadioButtonGroup/stories/typescript/Simple.tsx +11 -11
- package/components/RangeInput/RangeInput.js +9 -5
- package/components/RangeInput/StyledRangeInput.js +11 -5
- package/components/RangeInput/stories/{Bounds.js → CustomThemed/Bounds.js} +1 -1
- package/{es6/components/RangeInput/stories/typescript → components/RangeInput/stories/CustomThemed}/CustomRange.tsx +2 -2
- package/components/RangeInput/stories/{Disabled.js → CustomThemed/Disabled.js} +1 -1
- package/components/RangeInput/stories/{TrackColor.js → CustomThemed/TrackColor.js} +1 -1
- package/components/RangeSelector/stories/Basics.js +32 -30
- package/components/RangeSelector/stories/{Custom.js → CustomThemed/Custom.js} +1 -1
- package/components/RangeSelector/stories/{CustomEdgeControl.js → CustomThemed/CustomEdgeControl.js} +1 -1
- package/components/RangeSelector/stories/Step.js +32 -30
- package/components/RangeSelector/stories/Thin.js +11 -9
- package/components/RangeSelector/stories/Vertical.js +32 -30
- package/components/Select/Select.js +15 -4
- package/components/Select/SelectContainer.js +39 -33
- package/components/Select/index.d.ts +3 -3
- package/components/Select/propTypes.js +1 -1
- package/components/Sidebar/stories/Labels.js +3 -5
- package/components/SkipLinks/SkipLinks.js +1 -0
- package/components/Stack/stories/Simple.js +17 -8
- package/components/TableCell/TableCell.js +1 -1
- package/components/TableCell/propTypes.js +11 -0
- package/components/Tabs/stories/Responsive.js +17 -102
- package/components/Tabs/stories/Rich.js +29 -51
- package/components/Tabs/stories/Scrollable.js +5 -3
- package/components/Tabs/stories/typescript/Controlled.tsx +18 -17
- package/components/Text/stories/All.js +5 -1
- package/components/Tip/Tip.js +6 -14
- package/components/Tip/stories/Caret.js +1 -3
- package/components/Tip/stories/CustomThemed/Themed.tsx +3 -6
- package/components/Tip/stories/typescript/Animated.tsx +2 -2
- package/components/Tip/stories/typescript/Children.tsx +67 -49
- package/components/index.js +16 -0
- package/es6/components/Anchor/index.d.ts +2 -0
- package/es6/components/Anchor/stories/Default.js +16 -7
- package/es6/components/Box/StyledBox.js +1 -3
- package/es6/components/Box/stories/Animation.js +24 -21
- package/es6/components/Box/stories/Background.js +95 -92
- package/es6/components/Box/stories/Border.js +89 -86
- package/es6/components/Box/stories/Custom.js +16 -13
- package/es6/components/Box/stories/Elevation.js +28 -25
- package/es6/components/Box/stories/Fixed.js +44 -41
- package/es6/components/Box/stories/MinMax.js +207 -204
- package/es6/components/Box/stories/OnClick.js +28 -25
- package/es6/components/Box/stories/RTL.js +36 -31
- package/es6/components/Box/stories/Round.js +56 -53
- package/es6/components/Box/stories/Simple.js +47 -44
- package/es6/components/Button/stories/CustomThemed/Active.js +1 -0
- package/es6/components/Button/stories/CustomThemed/Typescript.tsx +1 -1
- package/es6/components/Button/stories/Multiple.js +1 -1
- package/es6/components/Button/stories/typescript/Badge.tsx +58 -0
- package/es6/components/Calendar/Calendar.js +84 -116
- package/es6/components/Calendar/stories/Multiple.js +2 -1
- package/es6/components/Calendar/stories/Simple.js +0 -8
- package/es6/components/Calendar/utils.js +72 -15
- package/es6/components/Carousel/stories/Autoplay.js +6 -3
- package/es6/components/Carousel/stories/ControlVariations.js +9 -9
- package/es6/components/Carousel/stories/Controlled.js +3 -3
- package/es6/components/Carousel/stories/Simple.js +3 -3
- package/es6/components/Chart/stories/Labelled.js +2 -2
- package/es6/components/Chart/utils.js +4 -4
- package/es6/components/CheckBox/stories/Simple.js +9 -3
- package/es6/components/CheckBox/stories/WithStickyDiv.js +1 -1
- package/es6/components/CheckBoxGroup/stories/Disabled.js +7 -1
- package/es6/components/DataChart/DataChart.js +26 -5
- package/es6/components/DataChart/XAxis.js +4 -7
- package/es6/components/DataChart/YAxis.js +4 -7
- package/es6/components/DataChart/YGuide.js +12 -1
- package/es6/components/DataChart/index.d.ts +6 -1
- package/es6/components/DataChart/propTypes.js +4 -1
- package/es6/components/DataChart/stories/Placeholder.js +36 -0
- package/es6/components/DataTable/DataTable.js +56 -45
- package/es6/components/DataTable/PlaceholderBody.js +13 -0
- package/es6/components/DataTable/stories/MultiplePin.js +1 -1
- package/es6/components/DateInput/DateInput.js +60 -22
- package/es6/components/DateInput/stories/Form.js +2 -1
- package/es6/components/DateInput/stories/Format.js +2 -1
- package/es6/components/DateInput/stories/FormatInline.js +16 -8
- package/es6/components/DateInput/stories/Inline.js +2 -1
- package/es6/components/DateInput/stories/Range.js +2 -1
- package/es6/components/DateInput/stories/RangeFormat.js +2 -1
- package/es6/components/DateInput/stories/Simple.js +2 -1
- package/es6/components/DateInput/stories/typescript/European.tsx +2 -1
- package/es6/components/DateInput/utils.js +2 -2
- package/es6/components/Diagram/stories/Animated.js +44 -41
- package/es6/components/Diagram/stories/Progressing.js +32 -29
- package/es6/components/Diagram/stories/typescript/Connections.tsx +14 -13
- package/es6/components/Distribution/stories/typescript/Simple.tsx +24 -20
- package/es6/components/Drop/Drop.js +10 -6
- package/es6/components/Drop/index.d.ts +1 -0
- package/es6/components/Drop/propTypes.js +1 -0
- package/es6/components/Drop/stories/CustomThemed/Lazy.js +20 -16
- package/es6/components/Drop/stories/CustomThemed/Themed.js +5 -4
- package/es6/components/Drop/stories/Inline.js +55 -0
- package/es6/components/Drop/stories/Meter.js +6 -5
- package/es6/components/Drop/stories/Multiple.js +19 -6
- package/es6/components/Drop/stories/Overflow.js +6 -4
- package/es6/components/Drop/stories/Plain.js +6 -5
- package/es6/components/Drop/stories/Progressive.js +5 -4
- package/es6/components/Drop/stories/Simple.js +5 -4
- package/es6/components/Drop/stories/Styled.js +10 -8
- package/es6/components/Drop/stories/TrapFocus.js +4 -3
- package/es6/components/DropButton/stories/Menu.js +8 -4
- package/es6/components/DropButton/stories/Simple.js +4 -3
- package/es6/components/Footer/stories/DoubleFooter.js +37 -33
- package/es6/components/Footer/stories/Simple.js +25 -21
- package/es6/components/Footer/stories/Sitemap.js +35 -31
- package/es6/components/Footer/stories/Social.js +35 -31
- package/es6/components/Form/stories/AggregateValidation.js +65 -54
- package/es6/components/Form/stories/ArrayOfFormFields.js +59 -55
- package/es6/components/Form/stories/Controlled.js +100 -95
- package/es6/components/Form/stories/ControlledInput.js +130 -125
- package/es6/components/Form/stories/ControlledInputLazy.js +130 -125
- package/es6/components/Form/stories/ControlledLazy.js +98 -93
- package/es6/components/Form/stories/{Custom.js → CustomThemed/Custom.js} +1 -1
- package/es6/components/Form/stories/{FieldBorderPosition.js → CustomThemed/FieldBorderPosition.js} +24 -20
- package/es6/components/Form/stories/{FieldCustomStates.js → CustomThemed/FieldCustomStates.js} +1 -1
- package/es6/components/Form/stories/{FieldSpacingOptions.js → CustomThemed/FieldSpacingOptions.js} +5 -5
- package/es6/components/Form/stories/{RequiredLabel.js → CustomThemed/RequiredLabel.js} +1 -1
- package/es6/components/Form/stories/{Themed.js → CustomThemed/Themed.js} +2 -2
- package/es6/components/Form/stories/DynamicFields.js +63 -58
- package/es6/components/Form/stories/FieldStates.js +63 -60
- package/es6/components/Form/stories/FieldWithChildren.js +110 -105
- package/es6/components/Form/stories/FieldWithComponentProp.js +110 -105
- package/es6/components/Form/stories/HelpAndError.js +40 -18
- package/es6/components/Form/stories/Uncontrolled.js +100 -95
- package/es6/components/Form/stories/ValidateOnBlur.js +66 -61
- package/es6/components/Form/stories/ValidateOnChange.js +83 -78
- package/es6/components/Form/stories/ValidateOnMount.js +68 -63
- package/es6/components/Form/stories/typescript/TypedForm.tsx +69 -66
- package/es6/components/FormField/FormField.js +1 -1
- package/es6/components/FormField/stories/{typescript → CustomThemed}/Custom.tsx +1 -1
- package/es6/components/FormField/stories/Simple.js +23 -20
- package/es6/components/Grid/StyledGrid.js +1 -3
- package/es6/components/Grid/stories/AreasPropAlternative.js +28 -23
- package/es6/components/Grid/stories/Border.js +76 -73
- package/es6/components/Grid/stories/{Responsive.js → CustomThemed/Responsive.js} +1 -1
- package/es6/components/Grid/stories/NColumn.js +29 -24
- package/es6/components/Grid/stories/Percentages.js +31 -26
- package/es6/components/Grid/stories/ResponsiveCards.js +22 -18
- package/es6/components/Grid/stories/typescript/App.tsx +10 -4
- package/es6/components/Image/stories/Fallback.js +11 -8
- package/es6/components/Image/stories/Fill.js +21 -18
- package/es6/components/Image/stories/Fit.js +25 -22
- package/es6/components/Image/stories/Opacity.js +40 -37
- package/es6/components/Image/stories/Simple.js +10 -7
- package/es6/components/InfiniteScroll/stories/Basics.js +19 -16
- package/es6/components/InfiniteScroll/stories/ClassChildren.js +15 -12
- package/es6/components/InfiniteScroll/stories/Grid.js +22 -19
- package/es6/components/InfiniteScroll/stories/GridWithShow.js +23 -20
- package/es6/components/InfiniteScroll/stories/HeightReplace.js +21 -18
- package/es6/components/InfiniteScroll/stories/Marker.js +19 -16
- package/es6/components/InfiniteScroll/stories/Replace.js +20 -17
- package/es6/components/InfiniteScroll/stories/Show.js +19 -16
- package/es6/components/InfiniteScroll/stories/ShowAfter.js +19 -16
- package/es6/components/InfiniteScroll/stories/ShowBefore.js +19 -16
- package/es6/components/InfiniteScroll/stories/Variable.js +20 -17
- package/es6/components/InfiniteScroll/stories/typescript/OnMore.tsx +18 -24
- package/es6/components/InfiniteScroll/stories/typescript/OnMoreStep.tsx +18 -24
- package/es6/components/Keyboard/stories/OnDocument.js +2 -5
- package/es6/components/Layer/stories/Center.js +84 -79
- package/es6/components/Layer/stories/Corner.js +30 -25
- package/es6/components/Layer/stories/{Round.js → CustomThemed/Round.js} +1 -1
- package/es6/components/Layer/stories/Form.js +73 -68
- package/es6/components/Layer/stories/Full.js +38 -33
- package/es6/components/Layer/stories/Notification.js +52 -47
- package/es6/components/Layer/stories/Plain.js +25 -20
- package/es6/components/Layer/stories/RTL.js +33 -28
- package/es6/components/Layer/stories/ScrollBody.js +44 -41
- package/es6/components/Layer/stories/Target.js +75 -70
- package/es6/components/Main/stories/typescript/Simple.tsx +6 -4
- package/es6/components/Markdown/stories/Override.js +15 -12
- package/es6/components/Markdown/stories/Simple.js +13 -10
- package/es6/components/MaskedInput/MaskedInput.js +1 -1
- package/es6/components/MaskedInput/index.d.ts +1 -0
- package/es6/components/MaskedInput/propTypes.js +1 -0
- package/es6/components/MaskedInput/stories/CustomBox.js +49 -44
- package/es6/components/MaskedInput/stories/Date.js +55 -50
- package/es6/components/MaskedInput/stories/DateRange.js +88 -83
- package/es6/components/MaskedInput/stories/DateTimeDrop.js +31 -28
- package/es6/components/MaskedInput/stories/Filtered.js +33 -28
- package/es6/components/MaskedInput/stories/Form.js +35 -32
- package/es6/components/MaskedInput/stories/IPV4Range.js +70 -65
- package/es6/components/MaskedInput/stories/IPv4Address.js +46 -41
- package/es6/components/MaskedInput/stories/Phone.js +44 -39
- package/es6/components/MaskedInput/stories/SizeUnits.js +36 -31
- package/es6/components/MaskedInput/stories/Time.js +47 -42
- package/es6/components/MaskedInput/stories/URL.js +29 -24
- package/es6/components/MaskedInput/stories/typescript/Email.tsx +24 -20
- package/es6/components/Menu/Menu.js +8 -2
- package/es6/components/Menu/stories/Justify.js +5 -4
- package/es6/components/Menu/stories/typescript/Children.tsx +4 -3
- package/es6/components/NameValueList/stories/Align.js +38 -35
- package/es6/components/NameValueList/stories/CustomName.js +24 -21
- package/es6/components/NameValueList/stories/CustomValue.js +65 -62
- package/es6/components/NameValueList/stories/Layout.js +44 -41
- package/es6/components/NameValueList/stories/PairProps.js +25 -22
- package/es6/components/NameValueList/stories/Simple.js +17 -14
- package/es6/components/NameValueList/stories/Width.js +39 -36
- package/es6/components/Nav/stories/Sidebar.js +5 -3
- package/es6/components/Notification/Notification.js +119 -16
- package/es6/components/Notification/index.d.ts +3 -2
- package/es6/components/Notification/propTypes.js +3 -1
- package/es6/components/Notification/stories/Global.js +70 -0
- package/es6/components/Page/Page.js +40 -0
- package/es6/components/Page/PageContext.js +2 -0
- package/es6/components/Page/README.md +2 -0
- package/es6/components/Page/index.d.ts +12 -0
- package/es6/components/Page/index.js +2 -0
- package/es6/components/Page/propTypes.js +10 -0
- package/es6/components/Page/stories/Background.js +30 -0
- package/es6/components/Page/stories/ContentBackground.js +32 -0
- package/es6/components/Page/stories/CustomThemed/LeftColumn.js +65 -0
- package/es6/components/Page/stories/GlobalHeader.js +35 -0
- package/es6/components/Page/stories/MultipleBackgrounds.js +63 -0
- package/es6/components/Page/stories/MultipleContent.js +37 -0
- package/es6/components/Page/stories/PageNotificaton.js +77 -0
- package/es6/components/Page/stories/Simple.js +27 -0
- package/es6/components/PageContent/PageContent.js +36 -0
- package/es6/components/PageContent/README.md +2 -0
- package/es6/components/PageContent/index.d.ts +19 -0
- package/es6/components/PageContent/index.js +1 -0
- package/es6/components/PageContent/propTypes.js +21 -0
- package/es6/components/Pagination/stories/Grid.js +35 -30
- package/es6/components/Pagination/stories/NumberEdgePages.js +19 -16
- package/es6/components/Pagination/stories/NumberMiddlePages.js +19 -16
- package/es6/components/Pagination/stories/Simple.js +20 -17
- package/es6/components/Pagination/stories/Size.js +21 -18
- package/es6/components/RadioButton/stories/CustomThemed/Theme.js +5 -5
- package/es6/components/RadioButtonGroup/stories/CustomThemed/CustomTheme.js +7 -10
- package/es6/components/RadioButtonGroup/stories/typescript/Simple.tsx +11 -11
- package/es6/components/RangeInput/RangeInput.js +9 -5
- package/es6/components/RangeInput/StyledRangeInput.js +11 -5
- package/es6/components/RangeInput/stories/{Bounds.js → CustomThemed/Bounds.js} +1 -1
- package/{components/RangeInput/stories/typescript → es6/components/RangeInput/stories/CustomThemed}/CustomRange.tsx +2 -2
- package/es6/components/RangeInput/stories/{Disabled.js → CustomThemed/Disabled.js} +1 -1
- package/es6/components/RangeInput/stories/{TrackColor.js → CustomThemed/TrackColor.js} +1 -1
- package/es6/components/RangeSelector/stories/Basics.js +33 -30
- package/es6/components/RangeSelector/stories/{Custom.js → CustomThemed/Custom.js} +1 -1
- package/es6/components/RangeSelector/stories/{CustomEdgeControl.js → CustomThemed/CustomEdgeControl.js} +1 -1
- package/es6/components/RangeSelector/stories/Step.js +33 -30
- package/es6/components/RangeSelector/stories/Thin.js +12 -9
- package/es6/components/RangeSelector/stories/Vertical.js +33 -30
- package/es6/components/Select/Select.js +15 -4
- package/es6/components/Select/SelectContainer.js +39 -33
- package/es6/components/Select/index.d.ts +3 -3
- package/es6/components/Select/propTypes.js +1 -1
- package/es6/components/Sidebar/stories/Labels.js +3 -5
- package/es6/components/SkipLinks/SkipLinks.js +1 -0
- package/es6/components/Stack/stories/Simple.js +17 -9
- package/es6/components/TableCell/TableCell.js +1 -1
- package/es6/components/TableCell/propTypes.js +10 -0
- package/es6/components/Tabs/stories/Responsive.js +17 -102
- package/es6/components/Tabs/stories/Rich.js +31 -50
- package/es6/components/Tabs/stories/Scrollable.js +6 -4
- package/es6/components/Tabs/stories/typescript/Controlled.tsx +18 -17
- package/es6/components/Text/stories/All.js +5 -1
- package/es6/components/Tip/Tip.js +6 -15
- package/es6/components/Tip/stories/Caret.js +1 -3
- package/es6/components/Tip/stories/CustomThemed/Themed.tsx +3 -6
- package/es6/components/Tip/stories/typescript/Animated.tsx +2 -2
- package/es6/components/Tip/stories/typescript/Children.tsx +67 -49
- package/es6/components/index.js +2 -0
- package/es6/index.d.ts +2 -0
- package/es6/themes/base.d.ts +69 -0
- package/es6/themes/base.js +134 -6
- package/es6/utils/border.js +40 -36
- package/es6/utils/index.d.ts +11 -12
- package/es6/utils/styles.js +3 -1
- package/grommet.min.js +1 -1
- package/grommet.min.js.map +1 -1
- package/index.d.ts +2 -0
- package/package.json +23 -23
- package/themes/base.d.ts +69 -0
- package/themes/base.js +135 -6
- package/utils/border.js +46 -42
- package/utils/index.d.ts +11 -12
- package/utils/styles.js +3 -1
- package/components/Accordion/stories/DarkNoAnimation.js +0 -59
- package/components/Anchor/stories/Disabled.js +0 -32
- package/components/Anchor/stories/Inline.js +0 -30
- package/components/Button/stories/CustomThemed/Badge.tsx +0 -129
- package/components/Chart/stories/Types.js +0 -49
- package/components/CheckBox/stories/InsideFormField.js +0 -93
- package/components/CheckBox/stories/Reverse.js +0 -52
- package/components/CheckBoxGroup/stories/FormControlled.js +0 -55
- package/components/CheckBoxGroup/stories/FormUncontrolled.js +0 -69
- package/components/CheckBoxGroup/stories/ObjectOptions.js +0 -71
- package/components/Heading/stories/Color.js +0 -28
- package/components/Layer/stories/Margin.js +0 -61
- package/components/Layer/stories/MarginCenter.js +0 -62
- package/components/Layer/stories/MarginTop.js +0 -71
- package/components/RadioButtonGroup/stories/Simple.js +0 -54
- package/components/Sidebar/stories/typescript/Simple.tsx +0 -68
- package/components/Tabs/stories/CustomThemed/AlignControls.js +0 -83
- package/components/Tabs/stories/CustomThemed/Icon.js +0 -99
- package/components/Tabs/stories/Plain.js +0 -80
- package/components/Tabs/stories/Uncontrolled.js +0 -78
- package/components/Text/stories/Color.js +0 -22
- package/es6/components/Accordion/stories/DarkNoAnimation.js +0 -47
- package/es6/components/Anchor/stories/Disabled.js +0 -21
- package/es6/components/Anchor/stories/Inline.js +0 -19
- package/es6/components/Button/stories/CustomThemed/Badge.tsx +0 -129
- package/es6/components/Chart/stories/Types.js +0 -36
- package/es6/components/CheckBox/stories/Disabled.js +0 -40
- package/es6/components/CheckBox/stories/InsideFormField.js +0 -81
- package/es6/components/CheckBox/stories/Reverse.js +0 -39
- package/es6/components/CheckBox/stories/Toggle.js +0 -39
- package/es6/components/CheckBoxGroup/stories/FormControlled.js +0 -41
- package/es6/components/CheckBoxGroup/stories/FormUncontrolled.js +0 -57
- package/es6/components/CheckBoxGroup/stories/ObjectOptions.js +0 -57
- package/es6/components/Heading/stories/Color.js +0 -16
- package/es6/components/Layer/stories/Margin.js +0 -49
- package/es6/components/Layer/stories/MarginCenter.js +0 -50
- package/es6/components/Layer/stories/MarginTop.js +0 -59
- package/es6/components/RadioButtonGroup/stories/Simple.js +0 -40
- package/es6/components/Sidebar/stories/typescript/Simple.tsx +0 -68
- package/es6/components/Tabs/stories/CustomThemed/AlignControls.js +0 -71
- package/es6/components/Tabs/stories/CustomThemed/Icon.js +0 -85
- package/es6/components/Tabs/stories/Plain.js +0 -68
- package/es6/components/Tabs/stories/Uncontrolled.js +0 -66
- package/es6/components/Text/stories/Color.js +0 -10
- package/es6/components/TextArea/stories/Fill.js +0 -38
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
2
2
|
|
|
3
|
-
import React, { useCallback, useContext, useEffect, useState, useMemo } from 'react';
|
|
4
|
-
import { ThemeContext } from 'styled-components';
|
|
3
|
+
import React, { useCallback, useContext, useEffect, useState, useMemo, Fragment } from 'react';
|
|
4
|
+
import styled, { ThemeContext } from 'styled-components';
|
|
5
5
|
import { defaultProps } from '../../default-props';
|
|
6
|
+
import { Anchor } from '../Anchor';
|
|
6
7
|
import { Box } from '../Box';
|
|
7
8
|
import { Button } from '../Button';
|
|
8
9
|
import { Layer } from '../Layer';
|
|
@@ -10,14 +11,60 @@ import { Paragraph } from '../Paragraph';
|
|
|
10
11
|
import { Text } from '../Text';
|
|
11
12
|
import { NotificationType } from './propTypes';
|
|
12
13
|
|
|
14
|
+
var adaptThemeStyle = function adaptThemeStyle(value, theme) {
|
|
15
|
+
var textStyle = value;
|
|
16
|
+
var closeButtonStyle = value;
|
|
17
|
+
|
|
18
|
+
if (typeof value === 'string' && theme.global.edgeSize[value]) {
|
|
19
|
+
textStyle = {
|
|
20
|
+
vertical: value,
|
|
21
|
+
left: value,
|
|
22
|
+
right: undefined
|
|
23
|
+
};
|
|
24
|
+
closeButtonStyle = {
|
|
25
|
+
vertical: value,
|
|
26
|
+
right: value
|
|
27
|
+
};
|
|
28
|
+
} else if (typeof value === 'object') {
|
|
29
|
+
var left = value.left,
|
|
30
|
+
right = value.right,
|
|
31
|
+
top = value.top,
|
|
32
|
+
bottom = value.bottom,
|
|
33
|
+
horizontal = value.horizontal,
|
|
34
|
+
vertical = value.vertical;
|
|
35
|
+
textStyle = {
|
|
36
|
+
top: top || vertical,
|
|
37
|
+
bottom: bottom || vertical,
|
|
38
|
+
left: left || horizontal,
|
|
39
|
+
right: undefined
|
|
40
|
+
};
|
|
41
|
+
closeButtonStyle = {
|
|
42
|
+
top: top || vertical,
|
|
43
|
+
bottom: bottom || vertical,
|
|
44
|
+
right: right || horizontal
|
|
45
|
+
};
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
return [textStyle, closeButtonStyle];
|
|
49
|
+
};
|
|
50
|
+
|
|
51
|
+
var NotificationAnchor = styled(Anchor).withConfig({
|
|
52
|
+
displayName: "Notification__NotificationAnchor",
|
|
53
|
+
componentId: "sc-1yq09yz-0"
|
|
54
|
+
})(["white-space:nowrap;"]);
|
|
55
|
+
|
|
13
56
|
var Notification = function Notification(_ref) {
|
|
14
|
-
var
|
|
57
|
+
var _theme$notification, _theme$notification$s2, _theme$notification$s3, _theme$notification2, _theme$notification2$, _theme$notification3, _theme$notification3$, _theme$notification3$2;
|
|
58
|
+
|
|
59
|
+
var actionsProp = _ref.actions,
|
|
60
|
+
messageProp = _ref.message,
|
|
15
61
|
onClose = _ref.onClose,
|
|
16
62
|
id = _ref.id,
|
|
63
|
+
global = _ref.global,
|
|
17
64
|
status = _ref.status,
|
|
18
65
|
title = _ref.title,
|
|
19
66
|
toast = _ref.toast;
|
|
20
|
-
var autoClose = (toast == null ? void 0 : toast.autoClose) === undefined ? true : toast.autoClose;
|
|
67
|
+
var autoClose = toast && (toast == null ? void 0 : toast.autoClose) === undefined ? true : toast.autoClose;
|
|
21
68
|
var theme = useContext(ThemeContext) || defaultProps.theme;
|
|
22
69
|
|
|
23
70
|
var _useState = useState(true),
|
|
@@ -27,9 +74,9 @@ var Notification = function Notification(_ref) {
|
|
|
27
74
|
var position = useMemo(function () {
|
|
28
75
|
return toast && (toast == null ? void 0 : toast.position) || 'top';
|
|
29
76
|
}, [toast]);
|
|
30
|
-
var close = useCallback(function () {
|
|
77
|
+
var close = useCallback(function (event) {
|
|
31
78
|
setVisible(false);
|
|
32
|
-
if (onClose) onClose();
|
|
79
|
+
if (onClose) onClose(event);
|
|
33
80
|
}, [onClose]);
|
|
34
81
|
useEffect(function () {
|
|
35
82
|
if (autoClose) {
|
|
@@ -46,22 +93,78 @@ var Notification = function Notification(_ref) {
|
|
|
46
93
|
StatusIcon = _theme$notification$s.icon,
|
|
47
94
|
color = _theme$notification$s.color;
|
|
48
95
|
var closeIconColor = theme.notification.close.color;
|
|
49
|
-
var
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
}
|
|
54
|
-
|
|
96
|
+
var kind = useMemo(function () {
|
|
97
|
+
if (toast) return 'toast';
|
|
98
|
+
if (global) return 'global';
|
|
99
|
+
return undefined;
|
|
100
|
+
}, [global, toast]);
|
|
101
|
+
var direction;
|
|
102
|
+
if (kind && theme.notification[kind].direction) direction = theme.notification[kind].direction;else direction = theme.notification.direction;
|
|
103
|
+
var background;
|
|
104
|
+
if (kind && (_theme$notification = theme.notification) != null && (_theme$notification$s2 = _theme$notification[status]) != null && (_theme$notification$s3 = _theme$notification$s2[kind]) != null && _theme$notification$s3.background) background = theme.notification[status][kind].background;else if ((_theme$notification2 = theme.notification) != null && (_theme$notification2$ = _theme$notification2[status]) != null && _theme$notification2$.background) background = theme.notification[status].background;else background = ((_theme$notification3 = theme.notification) == null ? void 0 : (_theme$notification3$ = _theme$notification3[kind]) == null ? void 0 : (_theme$notification3$2 = _theme$notification3$.container) == null ? void 0 : _theme$notification3$2.background) || theme.notification.container.background;
|
|
105
|
+
var TextWrapper = direction === 'row' ? Text : Fragment; // notification is built with two child boxes that contain:
|
|
106
|
+
// 1. icon + text (wrapped in button when clickable)
|
|
107
|
+
// 2. close button
|
|
108
|
+
// pad needs to be applied to the child boxes, but we don't want to apply
|
|
109
|
+
// extra padding between the icon + text and the button.
|
|
110
|
+
|
|
111
|
+
var pad;
|
|
112
|
+
if (kind && theme.notification[kind].container.pad) pad = theme.notification[kind].container.pad;else pad = theme.notification.container.pad;
|
|
113
|
+
var textPad;
|
|
114
|
+
var closeButtonPad;
|
|
115
|
+
|
|
116
|
+
if (onClose) {
|
|
117
|
+
var _adaptThemeStyle = adaptThemeStyle(pad, theme);
|
|
118
|
+
|
|
119
|
+
textPad = _adaptThemeStyle[0];
|
|
120
|
+
closeButtonPad = _adaptThemeStyle[1];
|
|
121
|
+
} else textPad = pad;
|
|
122
|
+
|
|
123
|
+
var actions;
|
|
124
|
+
var message = messageProp;
|
|
125
|
+
if (actionsProp) actions = actionsProp.map(function (action) {
|
|
126
|
+
return /*#__PURE__*/React.createElement(Fragment, {
|
|
127
|
+
key: action.label
|
|
128
|
+
}, /*#__PURE__*/React.createElement(NotificationAnchor // create space between first anchor and
|
|
129
|
+
// text content and next anchor
|
|
130
|
+
, _extends({
|
|
131
|
+
margin: {
|
|
132
|
+
right: 'xsmall'
|
|
133
|
+
}
|
|
134
|
+
}, action, theme.notification.actions)), ' ');
|
|
135
|
+
});
|
|
136
|
+
var Message = direction !== 'row' ? Paragraph : Text;
|
|
137
|
+
if (message || actions) message = /*#__PURE__*/React.createElement(Message, theme.notification.message, /*#__PURE__*/React.createElement(Text, {
|
|
138
|
+
margin: {
|
|
139
|
+
right: 'xsmall'
|
|
140
|
+
}
|
|
141
|
+
}, message), actions);
|
|
142
|
+
var content = /*#__PURE__*/React.createElement(Box, _extends({}, theme.notification.container, global ? _extends({}, theme.notification.global.container) : {}, toast ? _extends({}, theme.notification.toast.container) : {}, {
|
|
143
|
+
background: background // let internal box control pad
|
|
144
|
+
,
|
|
145
|
+
pad: undefined,
|
|
55
146
|
direction: "row",
|
|
56
|
-
|
|
147
|
+
gap: "small"
|
|
148
|
+
}), /*#__PURE__*/React.createElement(Box, {
|
|
149
|
+
direction: "row",
|
|
150
|
+
pad: textPad,
|
|
57
151
|
flex: true
|
|
58
|
-
}
|
|
152
|
+
}, /*#__PURE__*/React.createElement(Box, theme.notification.iconContainer, /*#__PURE__*/React.createElement(StatusIcon, {
|
|
153
|
+
color: color
|
|
154
|
+
})), /*#__PURE__*/React.createElement(Box, theme.notification.textContainer, /*#__PURE__*/React.createElement(TextWrapper, null, title && /*#__PURE__*/React.createElement(Text, theme.notification.title, title), message && title && direction === 'row' && /*#__PURE__*/React.createElement(React.Fragment, null, "\xA0"), message))), onClose &&
|
|
155
|
+
/*#__PURE__*/
|
|
156
|
+
// theme.notification.container and textContainer may both have pad,
|
|
157
|
+
// account for both
|
|
158
|
+
React.createElement(Box, {
|
|
159
|
+
pad: closeButtonPad
|
|
160
|
+
}, /*#__PURE__*/React.createElement(Box, theme.notification.textContainer, /*#__PURE__*/React.createElement(Button, {
|
|
59
161
|
icon: /*#__PURE__*/React.createElement(CloseIcon, {
|
|
60
162
|
color: closeIconColor
|
|
61
163
|
}),
|
|
62
164
|
onClick: close,
|
|
165
|
+
hoverIndicator: true,
|
|
63
166
|
plain: true
|
|
64
|
-
})));
|
|
167
|
+
}))));
|
|
65
168
|
|
|
66
169
|
if (toast) {
|
|
67
170
|
content = visible && /*#__PURE__*/React.createElement(Layer, _extends({}, theme.notification.toast.layer, {
|
|
@@ -69,7 +172,7 @@ var Notification = function Notification(_ref) {
|
|
|
69
172
|
modal: false,
|
|
70
173
|
onEsc: onClose,
|
|
71
174
|
id: id,
|
|
72
|
-
responsive:
|
|
175
|
+
responsive: false,
|
|
73
176
|
plain: true,
|
|
74
177
|
position: position
|
|
75
178
|
}), content);
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { LayerPositionType } from '../Layer';
|
|
3
|
-
|
|
3
|
+
import { AnchorType } from '..';
|
|
4
4
|
export type StatusType = 'critical' | 'warning' | 'normal' | 'unknown';
|
|
5
5
|
|
|
6
6
|
export interface NotificationProps {
|
|
7
|
-
|
|
7
|
+
actions?: AnchorType[];
|
|
8
|
+
title?: string;
|
|
8
9
|
message?: string;
|
|
9
10
|
status?: StatusType;
|
|
10
11
|
toast?:
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import PropTypes from 'prop-types';
|
|
2
|
+
import { AnchorPropTypes } from '../Anchor/propTypes';
|
|
2
3
|
var PropType = {};
|
|
3
4
|
|
|
4
5
|
if (process.env.NODE_ENV !== 'production') {
|
|
5
6
|
PropType = {
|
|
6
|
-
|
|
7
|
+
actions: PropTypes.arrayOf(PropTypes.shape(AnchorPropTypes)),
|
|
8
|
+
title: PropTypes.string,
|
|
7
9
|
message: PropTypes.string,
|
|
8
10
|
status: PropTypes.oneOf(['critical', 'warning', 'normal', 'unknown']),
|
|
9
11
|
toast: PropTypes.oneOfType([PropTypes.bool, PropTypes.shape({
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import React, { useState } from 'react';
|
|
2
|
+
import { Button, NameValueList, NameValuePair, Notification, Header, Heading, Paragraph } from 'grommet';
|
|
3
|
+
import { Grommet as GrommetIcon } from "grommet-icons/es6/icons/Grommet";
|
|
4
|
+
import { AppsRounded } from "grommet-icons/es6/icons/AppsRounded";
|
|
5
|
+
import { Box } from '../../Box';
|
|
6
|
+
import { Text } from '../../Text';
|
|
7
|
+
import { data } from '../../NameValueList/stories/data';
|
|
8
|
+
export var Global = function Global() {
|
|
9
|
+
var _useState = useState(true),
|
|
10
|
+
showGlobalNotification = _useState[0],
|
|
11
|
+
setShowGlobalNotification = _useState[1];
|
|
12
|
+
|
|
13
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Header, {
|
|
14
|
+
border: "bottom",
|
|
15
|
+
pad: {
|
|
16
|
+
horizontal: 'large',
|
|
17
|
+
vertical: 'small'
|
|
18
|
+
}
|
|
19
|
+
}, /*#__PURE__*/React.createElement(Box, {
|
|
20
|
+
direction: "row",
|
|
21
|
+
align: "center",
|
|
22
|
+
gap: "small"
|
|
23
|
+
}, /*#__PURE__*/React.createElement(GrommetIcon, {
|
|
24
|
+
size: "large",
|
|
25
|
+
color: "plain"
|
|
26
|
+
}), /*#__PURE__*/React.createElement(Text, {
|
|
27
|
+
weight: "bold"
|
|
28
|
+
}, "Company Name")), /*#__PURE__*/React.createElement(Button, {
|
|
29
|
+
icon: /*#__PURE__*/React.createElement(AppsRounded, null)
|
|
30
|
+
})), /*#__PURE__*/React.createElement(Box, {
|
|
31
|
+
gap: "medium"
|
|
32
|
+
}, showGlobalNotification && /*#__PURE__*/React.createElement(Notification, {
|
|
33
|
+
status: "warning",
|
|
34
|
+
message: "Your supscription will expire in 7 days. Renew your \n subscription to ensure you don't lose access.",
|
|
35
|
+
onClose: function onClose() {
|
|
36
|
+
return setShowGlobalNotification(false);
|
|
37
|
+
},
|
|
38
|
+
actions: [{
|
|
39
|
+
href: '#',
|
|
40
|
+
label: 'Renew Subscription'
|
|
41
|
+
}],
|
|
42
|
+
global: true
|
|
43
|
+
}), /*#__PURE__*/React.createElement(Box, {
|
|
44
|
+
width: "large",
|
|
45
|
+
margin: "auto",
|
|
46
|
+
pad: "medium",
|
|
47
|
+
gap: "medium"
|
|
48
|
+
}, /*#__PURE__*/React.createElement(Header, null, /*#__PURE__*/React.createElement(Heading, {
|
|
49
|
+
margin: "none"
|
|
50
|
+
}, "Page Heading"), /*#__PURE__*/React.createElement(Button, {
|
|
51
|
+
alignSelf: "start",
|
|
52
|
+
label: "Page-level Action",
|
|
53
|
+
primary: true
|
|
54
|
+
})), /*#__PURE__*/React.createElement(Paragraph, {
|
|
55
|
+
margin: "none"
|
|
56
|
+
}, "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam aliquet vitae velit non cursus. Aliquam fringilla dapibus elit, non fermentum neque tempor non."), /*#__PURE__*/React.createElement(Heading, {
|
|
57
|
+
margin: "none",
|
|
58
|
+
level: 2
|
|
59
|
+
}, "Details"), /*#__PURE__*/React.createElement(NameValueList, null, Object.entries(data).map(function (_ref) {
|
|
60
|
+
var name = _ref[0],
|
|
61
|
+
value = _ref[1];
|
|
62
|
+
return /*#__PURE__*/React.createElement(NameValuePair, {
|
|
63
|
+
key: name,
|
|
64
|
+
name: name
|
|
65
|
+
}, value);
|
|
66
|
+
})))));
|
|
67
|
+
};
|
|
68
|
+
export default {
|
|
69
|
+
title: 'Visualizations/Notification/Global'
|
|
70
|
+
};
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
var _excluded = ["kind"];
|
|
2
|
+
|
|
3
|
+
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
4
|
+
|
|
5
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
6
|
+
|
|
7
|
+
import React, { useContext, useMemo } from 'react';
|
|
8
|
+
import { ThemeContext } from 'styled-components';
|
|
9
|
+
import { Box } from '../Box';
|
|
10
|
+
import { PageContext } from './PageContext';
|
|
11
|
+
import { ResponsiveContext } from '../../contexts/ResponsiveContext';
|
|
12
|
+
import { PagePropTypes } from './propTypes';
|
|
13
|
+
|
|
14
|
+
var Page = function Page(_ref) {
|
|
15
|
+
var kind = _ref.kind,
|
|
16
|
+
rest = _objectWithoutPropertiesLoose(_ref, _excluded);
|
|
17
|
+
|
|
18
|
+
var size = useContext(ResponsiveContext);
|
|
19
|
+
var theme = useContext(ThemeContext);
|
|
20
|
+
var contentValue = useMemo(function () {
|
|
21
|
+
var _theme$page$kind, _theme$page$kind2;
|
|
22
|
+
|
|
23
|
+
return _extends({
|
|
24
|
+
alignSelf: (_theme$page$kind = theme.page[kind]) == null ? void 0 : _theme$page$kind.alignSelf,
|
|
25
|
+
width: (_theme$page$kind2 = theme.page[kind]) == null ? void 0 : _theme$page$kind2.width
|
|
26
|
+
}, theme.page[kind][size]);
|
|
27
|
+
}, [theme, size, kind]);
|
|
28
|
+
return /*#__PURE__*/React.createElement(PageContext.Provider, {
|
|
29
|
+
value: contentValue
|
|
30
|
+
}, /*#__PURE__*/React.createElement(Box, _extends({
|
|
31
|
+
fill: "horizontal"
|
|
32
|
+
}, rest)));
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
Page.displayName = 'Page';
|
|
36
|
+
Page.propTypes = PagePropTypes;
|
|
37
|
+
Page.defaultProps = {
|
|
38
|
+
kind: 'wide'
|
|
39
|
+
};
|
|
40
|
+
export { Page };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { BoxProps } from '../Box/index';
|
|
3
|
+
|
|
4
|
+
export interface PageProps {
|
|
5
|
+
kind?: 'wide' | 'narrow' | 'full' | string;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
export interface PageExtendedProps extends PageProps, BoxProps {}
|
|
9
|
+
|
|
10
|
+
declare const Page: React.FC<PageExtendedProps>;
|
|
11
|
+
|
|
12
|
+
export { Page };
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Page, PageContent, Heading, Paragraph, Grid, Card } from 'grommet';
|
|
3
|
+
export var Background = function Background() {
|
|
4
|
+
return (
|
|
5
|
+
/*#__PURE__*/
|
|
6
|
+
// Uncomment <Grommet> lines when using outside of storybook
|
|
7
|
+
// <Grommet theme={...}>
|
|
8
|
+
React.createElement(Page, {
|
|
9
|
+
background: "light-3",
|
|
10
|
+
kind: "narrow"
|
|
11
|
+
}, /*#__PURE__*/React.createElement(PageContent, null, /*#__PURE__*/React.createElement(Heading, null, "Narrow Page"), /*#__PURE__*/React.createElement(Paragraph, null, "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer commodo gravida tincidunt. Nunc fringilla blandit tortor, id accumsan nisi dictum quis. Aenean porttitor at mi id semper. Donec mattis bibendum leo, interdum ullamcorper lectus ultrices vel. Fusce nec enim faucibus nunc porta egestas. Fusce dapibus lobortis tincidunt."), /*#__PURE__*/React.createElement(Grid, {
|
|
12
|
+
rows: "small",
|
|
13
|
+
columns: {
|
|
14
|
+
count: 'fit',
|
|
15
|
+
size: 'small'
|
|
16
|
+
},
|
|
17
|
+
gap: "small"
|
|
18
|
+
}, /*#__PURE__*/React.createElement(Card, {
|
|
19
|
+
background: "white",
|
|
20
|
+
pad: "large"
|
|
21
|
+
}, "Card"), /*#__PURE__*/React.createElement(Card, {
|
|
22
|
+
background: "white",
|
|
23
|
+
pad: "large"
|
|
24
|
+
}, "Card")), /*#__PURE__*/React.createElement(Paragraph, null, "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer commodo gravida tincidunt. Nunc fringilla blandit tortor, id accumsan nisi dictum quis. Aenean porttitor at mi id semper. Donec mattis bibendum leo, interdum ullamcorper lectus ultrices vel. Fusce nec enim faucibus nunc porta egestas. Fusce dapibus lobortis tincidunt."))) // </Grommet>
|
|
25
|
+
|
|
26
|
+
);
|
|
27
|
+
};
|
|
28
|
+
export default {
|
|
29
|
+
title: 'Layout/Page/Background'
|
|
30
|
+
};
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Page, PageContent, Heading, Paragraph, Grid, Card } from 'grommet';
|
|
3
|
+
export var ContentBackground = function ContentBackground() {
|
|
4
|
+
return (
|
|
5
|
+
/*#__PURE__*/
|
|
6
|
+
// Uncomment <Grommet> lines when using outside of storybook
|
|
7
|
+
// <Grommet theme={...}>
|
|
8
|
+
React.createElement(Page, {
|
|
9
|
+
kind: "narrow"
|
|
10
|
+
}, /*#__PURE__*/React.createElement(PageContent, {
|
|
11
|
+
background: "light-3"
|
|
12
|
+
}, /*#__PURE__*/React.createElement(Heading, null, "Narrow Page"), /*#__PURE__*/React.createElement(Paragraph, null, "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer commodo gravida tincidunt. Nunc fringilla blandit tortor, id accumsan nisi dictum quis. Aenean porttitor at mi id semper. Donec mattis bibendum leo, interdum ullamcorper lectus ultrices vel. Fusce nec enim faucibus nunc porta egestas. Fusce dapibus lobortis tincidunt."), /*#__PURE__*/React.createElement(Grid, {
|
|
13
|
+
rows: "small",
|
|
14
|
+
columns: {
|
|
15
|
+
count: 'fit',
|
|
16
|
+
size: 'small'
|
|
17
|
+
},
|
|
18
|
+
gap: "small"
|
|
19
|
+
}, /*#__PURE__*/React.createElement(Card, {
|
|
20
|
+
background: "white",
|
|
21
|
+
pad: "large"
|
|
22
|
+
}, "Card"), /*#__PURE__*/React.createElement(Card, {
|
|
23
|
+
background: "white",
|
|
24
|
+
pad: "large"
|
|
25
|
+
}, "Card")), /*#__PURE__*/React.createElement(Paragraph, null, "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer commodo gravida tincidunt. Nunc fringilla blandit tortor, id accumsan nisi dictum quis. Aenean porttitor at mi id semper. Donec mattis bibendum leo, interdum ullamcorper lectus ultrices vel. Fusce nec enim faucibus nunc porta egestas. Fusce dapibus lobortis tincidunt."))) // </Grommet>
|
|
26
|
+
|
|
27
|
+
);
|
|
28
|
+
};
|
|
29
|
+
ContentBackground.storyName = 'Content background';
|
|
30
|
+
export default {
|
|
31
|
+
title: 'Layout/Page/Content background'
|
|
32
|
+
};
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Page, Header, Heading, Paragraph, Grid, Card, PageContent, Grommet } from 'grommet';
|
|
3
|
+
var customTheme = {
|
|
4
|
+
page: {
|
|
5
|
+
customKind: {
|
|
6
|
+
alignSelf: 'start',
|
|
7
|
+
width: {
|
|
8
|
+
min: '200px',
|
|
9
|
+
max: '500px'
|
|
10
|
+
},
|
|
11
|
+
small: {
|
|
12
|
+
pad: 'medium',
|
|
13
|
+
margin: {
|
|
14
|
+
vertical: 'small',
|
|
15
|
+
horizontal: 'small'
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
medium: {
|
|
19
|
+
pad: 'medium',
|
|
20
|
+
margin: {
|
|
21
|
+
vertical: 'small',
|
|
22
|
+
horizontal: 'small'
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
large: {
|
|
26
|
+
pad: 'medium',
|
|
27
|
+
margin: {
|
|
28
|
+
vertical: 'small',
|
|
29
|
+
horizontal: 'small'
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
};
|
|
35
|
+
export var LeftColumn = function LeftColumn() {
|
|
36
|
+
return /*#__PURE__*/React.createElement(Grommet, {
|
|
37
|
+
theme: customTheme
|
|
38
|
+
}, /*#__PURE__*/React.createElement(Page, {
|
|
39
|
+
kind: "customKind"
|
|
40
|
+
}, /*#__PURE__*/React.createElement(PageContent, null, /*#__PURE__*/React.createElement(Header, null, /*#__PURE__*/React.createElement(Heading, null, "Custom Kind"))), /*#__PURE__*/React.createElement(PageContent, {
|
|
41
|
+
background: {
|
|
42
|
+
fill: 'horizontal',
|
|
43
|
+
color: 'pink'
|
|
44
|
+
}
|
|
45
|
+
}, "Background goes all the way across Page width regardless of Page kind (wide, narrow, full, or custom)."), /*#__PURE__*/React.createElement(PageContent, null, /*#__PURE__*/React.createElement(Paragraph, null, "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer commodo gravida tincidunt. Nunc fringilla blandit tortor, id accumsan nisi dictum quis. Aenean porttitor at mi id semper. Donec mattis bibendum leo, interdum ullamcorper lectus ultrices vel. Fusce nec enim faucibus nunc porta egestas. Fusce dapibus lobortis tincidunt.")), /*#__PURE__*/React.createElement(PageContent, {
|
|
46
|
+
background: "orange"
|
|
47
|
+
}, /*#__PURE__*/React.createElement(Paragraph, null, "Background width is restricted by Page kind (wide, narrow, or full)."), /*#__PURE__*/React.createElement(Grid, {
|
|
48
|
+
rows: "small",
|
|
49
|
+
columns: {
|
|
50
|
+
count: 'fit',
|
|
51
|
+
size: 'small'
|
|
52
|
+
},
|
|
53
|
+
gap: "small"
|
|
54
|
+
}, /*#__PURE__*/React.createElement(Card, {
|
|
55
|
+
background: "white",
|
|
56
|
+
pad: "large"
|
|
57
|
+
}, "Card"), /*#__PURE__*/React.createElement(Card, {
|
|
58
|
+
background: "white",
|
|
59
|
+
pad: "large"
|
|
60
|
+
}, "Card"))), /*#__PURE__*/React.createElement(PageContent, null, /*#__PURE__*/React.createElement(Paragraph, null, "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer commodo gravida tincidunt. Nunc fringilla blandit tortor, id accumsan nisi dictum quis. Aenean porttitor at mi id semper. Donec mattis bibendum leo, interdum ullamcorper lectus ultrices vel. Fusce nec enim faucibus nunc porta egestas. Fusce dapibus lobortis tincidunt."))));
|
|
61
|
+
};
|
|
62
|
+
LeftColumn.storyName = 'Left column';
|
|
63
|
+
export default {
|
|
64
|
+
title: 'Layout/Page/Custom Themed/Left column'
|
|
65
|
+
};
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Header, Page, PageContent, Heading, Paragraph, Grid, Card, Footer } from 'grommet';
|
|
3
|
+
export var GlobalHeaderFooter = function GlobalHeaderFooter() {
|
|
4
|
+
return (
|
|
5
|
+
/*#__PURE__*/
|
|
6
|
+
// Uncomment <Grommet> lines when using outside of storybook
|
|
7
|
+
// <Grommet theme={...}>
|
|
8
|
+
React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Header, {
|
|
9
|
+
pad: "small"
|
|
10
|
+
}, "Global Header"), /*#__PURE__*/React.createElement(Page, {
|
|
11
|
+
background: "background-front",
|
|
12
|
+
kind: "narrow"
|
|
13
|
+
}, /*#__PURE__*/React.createElement(PageContent, null, /*#__PURE__*/React.createElement(Heading, null, "Narrow Page"), /*#__PURE__*/React.createElement(Paragraph, null, "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer commodo gravida tincidunt. Nunc fringilla blandit tortor, id accumsan nisi dictum quis. Aenean porttitor at mi id semper. Donec mattis bibendum leo, interdum ullamcorper lectus ultrices vel. Fusce nec enim faucibus nunc porta egestas. Fusce dapibus lobortis tincidunt."), /*#__PURE__*/React.createElement(Grid, {
|
|
14
|
+
rows: "small",
|
|
15
|
+
columns: {
|
|
16
|
+
count: 'fit',
|
|
17
|
+
size: 'small'
|
|
18
|
+
},
|
|
19
|
+
gap: "small"
|
|
20
|
+
}, /*#__PURE__*/React.createElement(Card, {
|
|
21
|
+
background: "white",
|
|
22
|
+
pad: "large"
|
|
23
|
+
}, "Card"), /*#__PURE__*/React.createElement(Card, {
|
|
24
|
+
background: "white",
|
|
25
|
+
pad: "large"
|
|
26
|
+
}, "Card")), /*#__PURE__*/React.createElement(Paragraph, null, "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer commodo gravida tincidunt. Nunc fringilla blandit tortor, id accumsan nisi dictum quis. Aenean porttitor at mi id semper. Donec mattis bibendum leo, interdum ullamcorper lectus ultrices vel. Fusce nec enim faucibus nunc porta egestas. Fusce dapibus lobortis tincidunt."))), /*#__PURE__*/React.createElement(Footer, {
|
|
27
|
+
pad: "small"
|
|
28
|
+
}, "Global Footer")) // </Grommet>
|
|
29
|
+
|
|
30
|
+
);
|
|
31
|
+
};
|
|
32
|
+
GlobalHeaderFooter.storyName = 'Global Header and Footer';
|
|
33
|
+
export default {
|
|
34
|
+
title: 'Layout/Page/Global Header and Footer'
|
|
35
|
+
};
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Page, Header, Heading, Paragraph, Grid, Card, PageContent, Footer, Box } from 'grommet';
|
|
3
|
+
export var MultipleBackgrounds = function MultipleBackgrounds() {
|
|
4
|
+
return (
|
|
5
|
+
/*#__PURE__*/
|
|
6
|
+
// Uncomment <Grommet> lines when using outside of storybook
|
|
7
|
+
// <Grommet theme={...}>
|
|
8
|
+
React.createElement(Page, {
|
|
9
|
+
kind: "narrow"
|
|
10
|
+
}, /*#__PURE__*/React.createElement(PageContent, {
|
|
11
|
+
background: {
|
|
12
|
+
fill: 'horizontal',
|
|
13
|
+
color: 'white'
|
|
14
|
+
}
|
|
15
|
+
}, /*#__PURE__*/React.createElement(Header, null, /*#__PURE__*/React.createElement(Heading, null, "Narrow Page"))), /*#__PURE__*/React.createElement(PageContent, {
|
|
16
|
+
background: {
|
|
17
|
+
fill: 'horizontal',
|
|
18
|
+
color: 'light-2'
|
|
19
|
+
}
|
|
20
|
+
}, /*#__PURE__*/React.createElement(Paragraph, null, "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer commodo gravida tincidunt. Nunc fringilla blandit tortor, id accumsan nisi dictum quis. Aenean porttitor at mi id semper. Donec mattis bibendum leo, interdum ullamcorper lectus ultrices vel. Fusce nec enim faucibus nunc porta egestas. Fusce dapibus lobortis tincidunt.")), /*#__PURE__*/React.createElement(PageContent, {
|
|
21
|
+
background: {
|
|
22
|
+
fill: 'horizontal',
|
|
23
|
+
color: 'dark-4'
|
|
24
|
+
}
|
|
25
|
+
}, /*#__PURE__*/React.createElement(Box, {
|
|
26
|
+
pad: {
|
|
27
|
+
vertical: 'medium'
|
|
28
|
+
}
|
|
29
|
+
}, /*#__PURE__*/React.createElement(Grid, {
|
|
30
|
+
rows: "small",
|
|
31
|
+
columns: {
|
|
32
|
+
count: 'fit',
|
|
33
|
+
size: 'small'
|
|
34
|
+
},
|
|
35
|
+
gap: "small"
|
|
36
|
+
}, /*#__PURE__*/React.createElement(Card, {
|
|
37
|
+
background: "white",
|
|
38
|
+
pad: "large"
|
|
39
|
+
}, "Card"), /*#__PURE__*/React.createElement(Card, {
|
|
40
|
+
background: "white",
|
|
41
|
+
pad: "large"
|
|
42
|
+
}, "Card")))), /*#__PURE__*/React.createElement(PageContent, {
|
|
43
|
+
background: {
|
|
44
|
+
fill: 'horizontal',
|
|
45
|
+
color: 'light-2'
|
|
46
|
+
}
|
|
47
|
+
}, /*#__PURE__*/React.createElement(Paragraph, null, "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer commodo gravida tincidunt. Nunc fringilla blandit tortor, id accumsan nisi dictum quis. Aenean porttitor at mi id semper. Donec mattis bibendum leo, interdum ullamcorper lectus ultrices vel. Fusce nec enim faucibus nunc porta egestas. Fusce dapibus lobortis tincidunt.")), /*#__PURE__*/React.createElement(PageContent, {
|
|
48
|
+
background: {
|
|
49
|
+
fill: 'horizontal',
|
|
50
|
+
color: 'white'
|
|
51
|
+
}
|
|
52
|
+
}, /*#__PURE__*/React.createElement(Footer, {
|
|
53
|
+
pad: {
|
|
54
|
+
vertical: 'small'
|
|
55
|
+
}
|
|
56
|
+
}, "Footer"))) // </Grommet>
|
|
57
|
+
|
|
58
|
+
);
|
|
59
|
+
};
|
|
60
|
+
MultipleBackgrounds.storyName = 'Multiple backgrounds';
|
|
61
|
+
export default {
|
|
62
|
+
title: 'Layout/Page/Multiple backgrounds'
|
|
63
|
+
};
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Page, PageContent, Header, Heading, Paragraph, Grid, Card } from 'grommet';
|
|
3
|
+
export var MultipleContent = function MultipleContent() {
|
|
4
|
+
return (
|
|
5
|
+
/*#__PURE__*/
|
|
6
|
+
// Uncomment <Grommet> lines when using outside of storybook
|
|
7
|
+
// <Grommet theme={...}>
|
|
8
|
+
React.createElement(Page, {
|
|
9
|
+
kind: "narrow"
|
|
10
|
+
}, /*#__PURE__*/React.createElement(PageContent, {
|
|
11
|
+
background: {
|
|
12
|
+
fill: 'horizontal',
|
|
13
|
+
color: 'white'
|
|
14
|
+
}
|
|
15
|
+
}, /*#__PURE__*/React.createElement(Header, null, /*#__PURE__*/React.createElement(Heading, null, "Page Header"))), /*#__PURE__*/React.createElement(PageContent, null, /*#__PURE__*/React.createElement(Heading, {
|
|
16
|
+
level: 2
|
|
17
|
+
}, "Narrow Page"), /*#__PURE__*/React.createElement(Paragraph, null, "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer commodo gravida tincidunt. Nunc fringilla blandit tortor, id accumsan nisi dictum quis. Aenean porttitor at mi id semper. Donec mattis bibendum leo, interdum ullamcorper lectus ultrices vel. Fusce nec enim faucibus nunc porta egestas. Fusce dapibus lobortis tincidunt."), /*#__PURE__*/React.createElement(Grid, {
|
|
18
|
+
rows: "small",
|
|
19
|
+
columns: {
|
|
20
|
+
count: 'fit',
|
|
21
|
+
size: 'small'
|
|
22
|
+
},
|
|
23
|
+
gap: "small"
|
|
24
|
+
}, /*#__PURE__*/React.createElement(Card, {
|
|
25
|
+
background: "white",
|
|
26
|
+
pad: "large"
|
|
27
|
+
}, "Card"), /*#__PURE__*/React.createElement(Card, {
|
|
28
|
+
background: "white",
|
|
29
|
+
pad: "large"
|
|
30
|
+
}, "Card")), /*#__PURE__*/React.createElement(Paragraph, null, "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer commodo gravida tincidunt. Nunc fringilla blandit tortor, id accumsan nisi dictum quis. Aenean porttitor at mi id semper. Donec mattis bibendum leo, interdum ullamcorper lectus ultrices vel. Fusce nec enim faucibus nunc porta egestas. Fusce dapibus lobortis tincidunt."))) // </Grommet>
|
|
31
|
+
|
|
32
|
+
);
|
|
33
|
+
};
|
|
34
|
+
MultipleContent.storyName = 'Multiple content';
|
|
35
|
+
export default {
|
|
36
|
+
title: 'Layout/Page/Multiple content'
|
|
37
|
+
};
|