grommet 2.36.1 → 2.38.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/all/stories/AllComponents.js +2 -2
- package/components/Accordion/Accordion.js +2 -2
- package/components/Accordion/stories/CustomHeader.js +1 -1
- package/components/Accordion/stories/CustomThemed/Custom.js +1 -1
- package/components/Accordion/stories/Simple.js +1 -1
- package/components/AccordionPanel/AccordionPanel.js +2 -2
- package/components/Anchor/Anchor.js +2 -2
- package/components/Anchor/StyledAnchor.js +2 -8
- package/components/Avatar/Avatar.js +2 -2
- package/components/Box/Box.js +2 -2
- package/components/Box/StyledBox.js +3 -3
- package/components/Box/stories/BackgroundThemed.js +1 -1
- package/components/Button/Badge.js +1 -1
- package/components/Button/BusyAnimation.js +3 -2
- package/components/Button/Button.js +3 -2
- package/components/Button/StyledButton.js +3 -2
- package/components/Button/StyledButtonKind.js +5 -5
- package/components/Button/stories/Busy.js +1 -1
- package/components/Calendar/Calendar.js +2 -2
- package/components/Calendar/StyledCalendar.js +7 -7
- package/components/Calendar/stories/ActiveDate.js +1 -1
- package/components/Calendar/stories/CustomDay.js +1 -1
- package/components/Calendar/stories/CustomHeader.js +1 -1
- package/components/Calendar/stories/CustomThemed/CustomSizeHeading.js +1 -1
- package/components/Calendar/stories/Dual.js +1 -1
- package/components/Calendar/stories/Multiple.js +1 -1
- package/components/Calendar/stories/ShowAdjacentDays.js +1 -1
- package/components/Calendar/stories/Simple.js +1 -1
- package/components/Card/Card.js +1 -1
- package/components/Card/stories/CustomThemed/Clickable.js +1 -1
- package/components/Card/stories/CustomThemed/Themed.js +1 -1
- package/components/CardBody/CardBody.js +1 -1
- package/components/CardFooter/CardFooter.js +1 -1
- package/components/CardHeader/CardHeader.js +1 -1
- package/components/Cards/Cards.js +2 -2
- package/components/Carousel/Carousel.js +2 -2
- package/components/Carousel/CarouselChild.js +1 -1
- package/components/Carousel/StyledCarousel.js +1 -1
- package/components/Carousel/stories/CustomThemed/Custom.js +1 -1
- package/components/Chart/Chart.js +2 -2
- package/components/Chart/StyledChart.js +2 -2
- package/components/Chart/stories/Rich.js +1 -1
- package/components/Chart/stories/Scan.js +1 -1
- package/components/Chart/stories/Window.js +1 -1
- package/components/Chart/stories/Zoom.js +1 -1
- package/components/CheckBox/CheckBox.js +2 -5
- package/components/CheckBox/StyledCheckBox.js +12 -11
- package/components/CheckBox/stories/CustomThemed/Custom.js +1 -1
- package/components/CheckBox/stories/CustomThemed/CustomToggle.js +1 -1
- package/components/CheckBox/stories/Indeterminate.js +1 -1
- package/components/CheckBox/stories/InsideButton.js +1 -1
- package/components/CheckBox/stories/NoLabel.js +2 -2
- package/components/CheckBox/stories/Simple.js +2 -2
- package/components/CheckBox/stories/WithStickyDiv.js +1 -1
- package/components/CheckBoxGroup/CheckBoxGroup.js +2 -2
- package/components/CheckBoxGroup/stories/Children.js +1 -1
- package/components/CheckBoxGroup/stories/InitialValues.js +1 -1
- package/components/Clock/Analog.js +2 -2
- package/components/Clock/Clock.js +2 -2
- package/components/Clock/Digital.js +2 -2
- package/components/Clock/StyledClock.js +8 -8
- package/components/Collapsible/Collapsible.js +1 -1
- package/components/Collapsible/stories/Nested.js +1 -1
- package/components/Data/Data.js +2 -2
- package/components/Data/DataForm.js +2 -2
- package/components/Data/stories/Infinite.js +2 -2
- package/components/Data/stories/Inline.js +2 -2
- package/components/Data/stories/OnSelect.js +264 -0
- package/components/Data/stories/SpaceX.js +2 -2
- package/components/Data/stories/StarWars.js +2 -2
- package/components/DataChart/DataChart.js +2 -2
- package/components/DataChart/Detail.js +1 -1
- package/components/DataChart/Legend.js +1 -1
- package/components/DataChart/Swatch.js +1 -1
- package/components/DataChart/XAxis.js +2 -2
- package/components/DataChart/XGuide.js +1 -1
- package/components/DataChart/YAxis.js +1 -1
- package/components/DataChart/YGuide.js +1 -1
- package/components/DataChart/stories/Prediction.js +1 -1
- package/components/DataClearFilters/DataClearFilters.js +2 -2
- package/components/DataClearFilters/stories/Simple.js +1 -1
- package/components/DataFilter/DataFilter.js +2 -2
- package/components/DataFilters/DataFilters.js +2 -2
- package/components/DataSearch/DataSearch.js +7 -2
- package/components/DataSort/DataSort.js +2 -2
- package/components/DataSummary/DataSummary.js +2 -2
- package/components/DataTable/Body.js +2 -2
- package/components/DataTable/Cell.js +2 -2
- package/components/DataTable/DataTable.js +11 -18
- package/components/DataTable/ExpanderCell.js +2 -2
- package/components/DataTable/Footer.js +2 -2
- package/components/DataTable/GroupedBody.js +2 -2
- package/components/DataTable/Header.js +24 -17
- package/components/DataTable/PlaceholderBody.js +1 -1
- package/components/DataTable/Resizer.js +1 -1
- package/components/DataTable/Searcher.js +1 -1
- package/components/DataTable/Sorter.js +1 -1
- package/components/DataTable/StyledDataTable.js +2 -2
- package/components/DataTable/index.d.ts +5 -1
- package/components/DataTable/stories/ControlledGrouped.js +1 -1
- package/components/DataTable/stories/CustomThemed/Custom.js +1 -1
- package/components/DataTable/stories/OnUpdate.js +1 -1
- package/components/DataTable/stories/SpaceX.js +2 -2
- package/components/DataTable/stories/SpaceXUngrouped.js +2 -2
- package/components/DataTableColumns/DataTableColumns.js +18 -4
- package/components/DataTableColumns/index.d.ts +9 -1
- package/components/DataTableColumns/propTypes.js +1 -0
- package/components/DataTableColumns/stories/Pinned.js +46 -0
- package/components/DataTableGroupBy/DataTableGroupBy.js +2 -2
- package/components/DataView/DataView.js +2 -2
- package/components/DateInput/DateInput.js +2 -2
- package/components/DateInput/stories/FormatInline.js +1 -1
- package/components/Diagram/Diagram.js +2 -2
- package/components/Diagram/StyledDiagram.js +3 -2
- package/components/Diagram/stories/Animated.js +1 -1
- package/components/Diagram/stories/Progressing.js +2 -2
- package/components/Distribution/Distribution.js +1 -1
- package/components/Drop/Drop.js +2 -2
- package/components/Drop/DropContainer.js +2 -4
- package/components/Drop/StyledDrop.js +3 -2
- package/components/Drop/stories/CustomThemed/Lazy.js +1 -1
- package/components/Drop/stories/CustomThemed/Themed.js +1 -1
- package/components/Drop/stories/Inline.js +1 -1
- package/components/Drop/stories/Meter.js +1 -1
- package/components/Drop/stories/Multiple.js +1 -1
- package/components/Drop/stories/Overflow.js +1 -1
- package/components/Drop/stories/Plain.js +1 -1
- package/components/Drop/stories/Progressive.js +1 -1
- package/components/Drop/stories/Simple.js +1 -1
- package/components/Drop/stories/Styled.js +1 -1
- package/components/Drop/stories/TrapFocus.js +1 -1
- package/components/DropButton/DropButton.js +2 -2
- package/components/FileInput/FileInput.js +2 -2
- package/components/FileInput/StyledFileInput.js +1 -1
- package/components/FocusedContainer.js +2 -2
- package/components/Form/Form.js +2 -2
- package/components/Form/FormContext.js +1 -1
- package/components/Form/stories/ArrayOfFormFields.js +1 -1
- package/components/Form/stories/Controlled.js +1 -1
- package/components/Form/stories/ControlledInput.js +1 -1
- package/components/Form/stories/ControlledInputLazy.js +1 -1
- package/components/Form/stories/ControlledLazy.js +1 -1
- package/components/Form/stories/CustomThemed/FieldBorderPosition.js +1 -1
- package/components/Form/stories/CustomThemed/FieldCustomStates.js +1 -1
- package/components/Form/stories/DynamicFields.js +1 -1
- package/components/Form/stories/FieldStates.js +1 -1
- package/components/Form/stories/SolicitedFeedback.js +1 -1
- package/components/Form/stories/UnsolicitedFeedback.js +1 -1
- package/components/Form/stories/ValidateOnChange.js +1 -1
- package/components/Form/stories/ValidateOnMount.js +1 -1
- package/components/FormField/FormField.js +3 -3
- package/components/FormField/stories/Simple.js +1 -1
- package/components/Grid/Grid.js +2 -2
- package/components/Grid/StyledGrid.js +2 -2
- package/components/Grid/stories/CustomThemed/Responsive.js +1 -1
- package/components/Grid/stories/ResponsiveCards.js +1 -1
- package/components/Grommet/Grommet.js +2 -2
- package/components/Grommet/StyledGrommet.js +2 -2
- package/components/Header/Header.js +2 -2
- package/components/Header/stories/Sticky.js +1 -1
- package/components/Heading/Heading.js +2 -2
- package/components/Heading/HeadingSkeleton.js +1 -1
- package/components/Heading/StyledHeading.js +2 -2
- package/components/Image/Image.js +2 -2
- package/components/Image/StyledImage.js +2 -2
- package/components/InfiniteScroll/InfiniteScroll.js +1 -1
- package/components/Keyboard/Keyboard.js +1 -1
- package/components/Layer/Layer.js +1 -1
- package/components/Layer/LayerContainer.js +3 -3
- package/components/Layer/StyledLayer.js +7 -7
- package/components/List/List.js +46 -22
- package/components/List/index.d.ts +20 -6
- package/components/List/propTypes.js +6 -1
- package/components/List/stories/Order.js +1 -1
- package/components/List/stories/Pinned.js +1 -1
- package/components/Markdown/Markdown.js +2 -2
- package/components/Markdown/stories/Override.js +2 -1
- package/components/MaskedInput/MaskedInput.js +2 -2
- package/components/MaskedInput/StyledMaskedInput.js +3 -3
- package/components/Menu/Menu.js +3 -3
- package/components/Meter/Bar.js +2 -2
- package/components/Meter/Circle.js +2 -2
- package/components/Meter/Meter.js +2 -2
- package/components/Meter/StyledMeter.js +2 -2
- package/components/Meter/stories/Circle.js +1 -1
- package/components/Meter/stories/VerticalBarMultiple.js +1 -1
- package/components/NameValueList/NameValueList.js +2 -2
- package/components/NameValuePair/NameValuePair.js +1 -1
- package/components/Nav/stories/CustomThemed/JustifySidebar.js +2 -2
- package/components/Nav/stories/Sidebar.js +2 -2
- package/components/Notification/Notification.js +2 -2
- package/components/Notification/stories/Global.js +1 -1
- package/components/Notification/stories/Title.js +1 -1
- package/components/Notification/stories/TitleAndMessage.js +1 -1
- package/components/Page/Page.js +2 -2
- package/components/Page/stories/PageNotificaton.js +1 -1
- package/components/PageContent/PageContent.js +2 -2
- package/components/PageHeader/PageHeader.js +2 -2
- package/components/PageHeader/stories/MultipleActions.js +1 -1
- package/components/Pagination/PageControl.js +2 -2
- package/components/Pagination/Pagination.js +5 -2
- package/components/Pagination/PaginationStep.js +2 -2
- package/components/Pagination/PaginationSummary.js +2 -2
- package/components/Pagination/StyledPageControl.js +2 -1
- package/components/Pagination/stories/Grid.js +1 -1
- package/components/Paragraph/Paragraph.js +2 -2
- package/components/Paragraph/ParagraphSkeleton.js +1 -1
- package/components/Paragraph/StyledParagraph.js +2 -2
- package/components/RadioButton/RadioButton.js +2 -5
- package/components/RadioButton/StyledRadioButton.js +9 -8
- package/components/RadioButtonGroup/RadioButtonGroup.js +2 -2
- package/components/RadioButtonGroup/stories/Children.js +1 -1
- package/components/RadioButtonGroup/stories/CustomThemed/CustomTheme.js +2 -2
- package/components/RadioButtonGroup/stories/Disabled.js +2 -2
- package/components/RangeInput/RangeInput.js +3 -3
- package/components/RangeInput/StyledRangeInput.js +2 -2
- package/components/RangeSelector/EdgeControl.js +2 -2
- package/components/RangeSelector/RangeSelector.js +2 -2
- package/components/RangeSelector/stories/Basics.js +1 -1
- package/components/RangeSelector/stories/CustomThemed/Custom.js +2 -2
- package/components/RangeSelector/stories/CustomThemed/CustomEdgeControl.js +2 -2
- package/components/RangeSelector/stories/Label.js +1 -1
- package/components/RangeSelector/stories/Simple.js +1 -1
- package/components/RangeSelector/stories/Step.js +2 -2
- package/components/RangeSelector/stories/Thin.js +1 -1
- package/components/RangeSelector/stories/Vertical.js +2 -2
- package/components/RoutedAnchor/RoutedAnchor.js +3 -3
- package/components/RoutedButton/RoutedButton.js +3 -3
- package/components/Select/DefaultSelectTextInput.js +2 -2
- package/components/Select/Select.js +2 -2
- package/components/Select/SelectContainer.js +2 -3
- package/components/Select/StyledSelect.js +4 -3
- package/components/Select/stories/ChildrenRender.js +1 -1
- package/components/Select/stories/Clear.js +1 -1
- package/components/Select/stories/Controlled.js +1 -1
- package/components/Select/stories/CustomThemed/CustomSearch.js +1 -1
- package/components/Select/stories/Disabled.js +1 -1
- package/components/Select/stories/InsideFormField.js +1 -1
- package/components/Select/stories/Multiple.js +1 -1
- package/components/Select/stories/ObjectOptions.js +1 -1
- package/components/Select/stories/Search.js +1 -1
- package/components/Select/stories/Simple.js +1 -1
- package/components/Select/stories/ValueLabel.js +1 -1
- package/components/Select/stories/components/SearchBorderBox.js +2 -2
- package/components/Select/stories/components/SearchInput.js +2 -2
- package/components/SelectMultiple/SelectMultiple.js +2 -2
- package/components/SelectMultiple/SelectMultipleContainer.js +1 -2
- package/components/SelectMultiple/SelectMultipleValue.js +1 -1
- package/components/SelectMultiple/SelectionSummary.js +1 -1
- package/components/SelectMultiple/stories/CustomMessages.js +1 -1
- package/components/SelectMultiple/stories/Default.js +1 -1
- package/components/SelectMultiple/stories/Disabled.js +1 -1
- package/components/SelectMultiple/stories/FormField.js +1 -1
- package/components/SelectMultiple/stories/Help.js +1 -1
- package/components/SelectMultiple/stories/Limited.js +1 -1
- package/components/SelectMultiple/stories/ObjectOptions.js +1 -1
- package/components/SelectMultiple/stories/ShowSelectedInline.js +1 -1
- package/components/Sidebar/Sidebar.js +1 -1
- package/components/Sidebar/stories/Labels.js +1 -1
- package/components/Skeleton/Skeleton.js +2 -2
- package/components/Skeleton/SkeletonContext.js +1 -1
- package/components/Skeleton/StyledSkeleton.js +6 -3
- package/components/Skeleton/stories/CustomThemed/Custom.js +1 -1
- package/components/Skeleton/stories/GridContainer.js +2 -2
- package/components/Skeleton/stories/Group.js +1 -1
- package/components/Skeleton/stories/Individual.js +2 -2
- package/components/SkipLink/SkipLink.js +2 -2
- package/components/SkipLinkTarget/SkipLinkTarget.js +1 -1
- package/components/SkipLinks/SkipLinks.js +1 -1
- package/components/Spinner/Spinner.js +2 -2
- package/components/Spinner/stories/Animation.js +1 -1
- package/components/Spinner/stories/Announced.js +1 -1
- package/components/Stack/Stack.js +2 -2
- package/components/Stack/StyledStack.js +3 -3
- package/components/StarRating/StarRating.js +2 -2
- package/components/Tab/StyledTab.js +3 -2
- package/components/Tab/Tab.js +2 -4
- package/components/Table/StyledTable.js +8 -8
- package/components/Table/Table.js +2 -2
- package/components/Table/stories/InfiniteScrollInTable.js +1 -1
- package/components/TableBody/TableBody.js +1 -1
- package/components/TableCell/TableCell.js +2 -2
- package/components/TableFooter/TableFooter.js +1 -1
- package/components/TableHeader/TableHeader.js +1 -1
- package/components/TableRow/TableRow.js +1 -1
- package/components/Tabs/StyledTabs.js +5 -4
- package/components/Tabs/Tabs.js +2 -4
- package/components/Tabs/stories/CustomThemed/States.js +1 -1
- package/components/Tabs/stories/Responsive.js +1 -1
- package/components/Tag/Tag.js +2 -2
- package/components/Text/StyledText.js +2 -6
- package/components/Text/Text.js +2 -2
- package/components/Text/TextSkeleton.js +2 -2
- package/components/TextArea/StyledTextArea.js +2 -2
- package/components/TextArea/TextArea.js +2 -2
- package/components/TextArea/stories/CustomThemed/Themed.js +1 -1
- package/components/TextArea/stories/InsideFormField.js +1 -1
- package/components/TextArea/stories/NonResizable.js +1 -1
- package/components/TextArea/stories/Simple.js +1 -1
- package/components/TextInput/CopyButton.js +1 -1
- package/components/TextInput/StyledTextInput.js +6 -6
- package/components/TextInput/TextInput.js +2 -2
- package/components/TextInput/stories/InsideFormField.js +1 -1
- package/components/TextInput/stories/Simple.js +6 -1
- package/components/TextInput/stories/WithTags.js +1 -1
- package/components/ThumbsRating/ThumbsRating.js +1 -1
- package/components/Tip/Tip.js +1 -1
- package/components/Tip/stories/HeaderActions.js +1 -1
- package/components/ToggleGroup/README.md +2 -0
- package/components/ToggleGroup/StyledToggleGroup.js +36 -0
- package/components/ToggleGroup/ToggleGroup.js +165 -0
- package/components/ToggleGroup/index.d.ts +26 -0
- package/components/ToggleGroup/index.js +6 -0
- package/components/ToggleGroup/propTypes.js +21 -0
- package/components/ToggleGroup/stories/Controlled.js +31 -0
- package/components/ToggleGroup/stories/multiple.tsx +28 -0
- package/components/ToggleGroup/stories/simple.js +37 -0
- package/components/Toolbar/Toolbar.js +2 -2
- package/components/Video/StyledVideo.js +5 -5
- package/components/Video/Video.js +2 -2
- package/components/WorldMap/StyledWorldMap.js +1 -1
- package/components/WorldMap/WorldMap.js +2 -2
- package/components/index.d.ts +2 -0
- package/components/index.js +6 -0
- package/contexts/AnalyticsContext/AnalyticsContext.js +1 -1
- package/contexts/AnnounceContext/stories/Polite.js +1 -1
- package/contexts/ResponsiveContext/stories/ResponsiveGrid.js +1 -1
- package/contexts/ThemeContext/stories/ThemeContextExtend.js +1 -1
- package/es6/all/stories/AllComponents.js +1 -1
- package/es6/components/Accordion/Accordion.js +1 -1
- package/es6/components/Accordion/stories/CustomThemed/Custom.js +1 -1
- package/es6/components/Accordion/stories/Simple.js +1 -1
- package/es6/components/AccordionPanel/AccordionPanel.js +1 -1
- package/es6/components/Anchor/Anchor.js +1 -1
- package/es6/components/Anchor/StyledAnchor.js +2 -8
- package/es6/components/Avatar/Avatar.js +1 -1
- package/es6/components/Box/Box.js +1 -1
- package/es6/components/Box/StyledBox.js +3 -3
- package/es6/components/Button/BusyAnimation.js +2 -1
- package/es6/components/Button/Button.js +2 -1
- package/es6/components/Button/StyledButton.js +2 -1
- package/es6/components/Button/StyledButtonKind.js +3 -4
- package/es6/components/Calendar/Calendar.js +1 -1
- package/es6/components/Calendar/StyledCalendar.js +7 -7
- package/es6/components/Card/stories/CustomThemed/Clickable.js +1 -1
- package/es6/components/Card/stories/CustomThemed/Themed.js +1 -1
- package/es6/components/Cards/Cards.js +1 -1
- package/es6/components/Carousel/Carousel.js +1 -1
- package/es6/components/Carousel/stories/CustomThemed/Custom.js +1 -1
- package/es6/components/Chart/Chart.js +1 -1
- package/es6/components/Chart/StyledChart.js +2 -2
- package/es6/components/CheckBox/CheckBox.js +1 -4
- package/es6/components/CheckBox/StyledCheckBox.js +12 -11
- package/es6/components/CheckBox/stories/NoLabel.js +1 -1
- package/es6/components/CheckBox/stories/Simple.js +1 -1
- package/es6/components/CheckBoxGroup/CheckBoxGroup.js +1 -1
- package/es6/components/Clock/Analog.js +1 -1
- package/es6/components/Clock/Clock.js +1 -1
- package/es6/components/Clock/Digital.js +1 -1
- package/es6/components/Clock/StyledClock.js +8 -8
- package/es6/components/Collapsible/stories/Nested.js +1 -1
- package/es6/components/Data/Data.js +1 -1
- package/es6/components/Data/DataForm.js +1 -1
- package/es6/components/Data/stories/Infinite.js +1 -1
- package/es6/components/Data/stories/Inline.js +1 -1
- package/es6/components/Data/stories/OnSelect.js +258 -0
- package/es6/components/Data/stories/SpaceX.js +1 -1
- package/es6/components/Data/stories/StarWars.js +1 -1
- package/es6/components/DataChart/DataChart.js +1 -1
- package/es6/components/DataChart/XAxis.js +1 -1
- package/es6/components/DataClearFilters/DataClearFilters.js +1 -1
- package/es6/components/DataFilter/DataFilter.js +1 -1
- package/es6/components/DataFilters/DataFilters.js +1 -1
- package/es6/components/DataSearch/DataSearch.js +6 -1
- package/es6/components/DataSort/DataSort.js +1 -1
- package/es6/components/DataSummary/DataSummary.js +1 -1
- package/es6/components/DataTable/Body.js +1 -1
- package/es6/components/DataTable/Cell.js +1 -1
- package/es6/components/DataTable/DataTable.js +10 -17
- package/es6/components/DataTable/ExpanderCell.js +1 -1
- package/es6/components/DataTable/Footer.js +1 -1
- package/es6/components/DataTable/GroupedBody.js +1 -1
- package/es6/components/DataTable/Header.js +23 -16
- package/es6/components/DataTable/StyledDataTable.js +2 -2
- package/es6/components/DataTable/index.d.ts +5 -1
- package/es6/components/DataTable/stories/CustomThemed/Custom.js +1 -1
- package/es6/components/DataTable/stories/SpaceX.js +1 -1
- package/es6/components/DataTable/stories/SpaceXUngrouped.js +1 -1
- package/es6/components/DataTableColumns/DataTableColumns.js +17 -3
- package/es6/components/DataTableColumns/index.d.ts +9 -1
- package/es6/components/DataTableColumns/propTypes.js +1 -0
- package/es6/components/DataTableColumns/stories/Pinned.js +42 -0
- package/es6/components/DataTableGroupBy/DataTableGroupBy.js +1 -1
- package/es6/components/DataView/DataView.js +1 -1
- package/es6/components/DateInput/DateInput.js +1 -1
- package/es6/components/Diagram/Diagram.js +1 -1
- package/es6/components/Diagram/StyledDiagram.js +2 -1
- package/es6/components/Diagram/stories/Progressing.js +1 -1
- package/es6/components/Distribution/Distribution.js +1 -1
- package/es6/components/Drop/Drop.js +1 -1
- package/es6/components/Drop/DropContainer.js +1 -3
- package/es6/components/Drop/StyledDrop.js +2 -1
- package/es6/components/DropButton/DropButton.js +1 -1
- package/es6/components/FileInput/FileInput.js +1 -1
- package/es6/components/FileInput/StyledFileInput.js +2 -2
- package/es6/components/FocusedContainer.js +1 -1
- package/es6/components/Form/Form.js +1 -1
- package/es6/components/FormField/FormField.js +2 -2
- package/es6/components/Grid/Grid.js +1 -1
- package/es6/components/Grid/StyledGrid.js +2 -2
- package/es6/components/Grid/stories/CustomThemed/Responsive.js +1 -1
- package/es6/components/Grommet/Grommet.js +1 -1
- package/es6/components/Grommet/StyledGrommet.js +2 -2
- package/es6/components/Header/Header.js +1 -1
- package/es6/components/Heading/Heading.js +1 -1
- package/es6/components/Heading/StyledHeading.js +2 -2
- package/es6/components/Image/Image.js +1 -1
- package/es6/components/Image/StyledImage.js +2 -2
- package/es6/components/Keyboard/Keyboard.js +1 -1
- package/es6/components/Layer/LayerContainer.js +3 -3
- package/es6/components/Layer/StyledLayer.js +6 -7
- package/es6/components/List/List.js +47 -23
- package/es6/components/List/index.d.ts +20 -6
- package/es6/components/List/propTypes.js +7 -2
- package/es6/components/Markdown/Markdown.js +1 -1
- package/es6/components/Markdown/stories/Override.js +2 -1
- package/es6/components/MaskedInput/MaskedInput.js +1 -1
- package/es6/components/MaskedInput/StyledMaskedInput.js +4 -4
- package/es6/components/Menu/Menu.js +2 -2
- package/es6/components/Meter/Bar.js +1 -1
- package/es6/components/Meter/Circle.js +1 -1
- package/es6/components/Meter/Meter.js +1 -1
- package/es6/components/Meter/StyledMeter.js +2 -2
- package/es6/components/NameValueList/NameValueList.js +1 -1
- package/es6/components/Nav/stories/CustomThemed/JustifySidebar.js +1 -1
- package/es6/components/Nav/stories/Sidebar.js +1 -1
- package/es6/components/Notification/Notification.js +1 -1
- package/es6/components/Page/Page.js +1 -1
- package/es6/components/PageContent/PageContent.js +1 -1
- package/es6/components/PageHeader/PageHeader.js +1 -1
- package/es6/components/Pagination/PageControl.js +1 -1
- package/es6/components/Pagination/Pagination.js +4 -1
- package/es6/components/Pagination/PaginationStep.js +1 -1
- package/es6/components/Pagination/PaginationSummary.js +1 -1
- package/es6/components/Pagination/StyledPageControl.js +2 -1
- package/es6/components/Paragraph/Paragraph.js +1 -1
- package/es6/components/Paragraph/StyledParagraph.js +2 -2
- package/es6/components/RadioButton/RadioButton.js +1 -4
- package/es6/components/RadioButton/StyledRadioButton.js +9 -8
- package/es6/components/RadioButtonGroup/RadioButtonGroup.js +1 -1
- package/es6/components/RadioButtonGroup/stories/CustomThemed/CustomTheme.js +1 -1
- package/es6/components/RadioButtonGroup/stories/Disabled.js +1 -1
- package/es6/components/RangeInput/RangeInput.js +2 -2
- package/es6/components/RangeInput/StyledRangeInput.js +2 -2
- package/es6/components/RangeSelector/EdgeControl.js +1 -1
- package/es6/components/RangeSelector/RangeSelector.js +1 -1
- package/es6/components/RangeSelector/stories/CustomThemed/Custom.js +1 -1
- package/es6/components/RangeSelector/stories/CustomThemed/CustomEdgeControl.js +1 -1
- package/es6/components/RangeSelector/stories/Step.js +1 -1
- package/es6/components/RangeSelector/stories/Vertical.js +1 -1
- package/es6/components/RoutedAnchor/RoutedAnchor.js +2 -2
- package/es6/components/RoutedButton/RoutedButton.js +2 -2
- package/es6/components/Select/DefaultSelectTextInput.js +1 -1
- package/es6/components/Select/Select.js +1 -1
- package/es6/components/Select/SelectContainer.js +1 -2
- package/es6/components/Select/StyledSelect.js +5 -4
- package/es6/components/Select/stories/components/SearchBorderBox.js +1 -1
- package/es6/components/Select/stories/components/SearchInput.js +1 -1
- package/es6/components/SelectMultiple/SelectMultiple.js +1 -1
- package/es6/components/SelectMultiple/SelectMultipleContainer.js +0 -1
- package/es6/components/Sidebar/Sidebar.js +1 -1
- package/es6/components/Sidebar/stories/Labels.js +1 -1
- package/es6/components/Skeleton/Skeleton.js +1 -1
- package/es6/components/Skeleton/StyledSkeleton.js +7 -4
- package/es6/components/Skeleton/stories/GridContainer.js +1 -1
- package/es6/components/Skeleton/stories/Individual.js +1 -1
- package/es6/components/SkipLink/SkipLink.js +1 -1
- package/es6/components/SkipLinkTarget/SkipLinkTarget.js +1 -1
- package/es6/components/Spinner/Spinner.js +1 -1
- package/es6/components/Stack/Stack.js +1 -1
- package/es6/components/Stack/StyledStack.js +3 -3
- package/es6/components/StarRating/StarRating.js +1 -1
- package/es6/components/Tab/StyledTab.js +2 -1
- package/es6/components/Tab/Tab.js +1 -3
- package/es6/components/Table/StyledTable.js +8 -8
- package/es6/components/Table/Table.js +1 -1
- package/es6/components/TableCell/TableCell.js +1 -1
- package/es6/components/Tabs/StyledTabs.js +5 -4
- package/es6/components/Tabs/Tabs.js +1 -3
- package/es6/components/Tag/Tag.js +1 -1
- package/es6/components/Text/StyledText.js +2 -6
- package/es6/components/Text/Text.js +1 -1
- package/es6/components/Text/TextSkeleton.js +1 -1
- package/es6/components/TextArea/StyledTextArea.js +2 -2
- package/es6/components/TextArea/TextArea.js +1 -1
- package/es6/components/TextInput/StyledTextInput.js +6 -6
- package/es6/components/TextInput/TextInput.js +1 -1
- package/es6/components/TextInput/stories/Simple.js +7 -2
- package/es6/components/TextInput/stories/WithTags.js +1 -1
- package/es6/components/ToggleGroup/README.md +2 -0
- package/es6/components/ToggleGroup/StyledToggleGroup.js +31 -0
- package/es6/components/ToggleGroup/ToggleGroup.js +160 -0
- package/es6/components/ToggleGroup/index.d.ts +26 -0
- package/es6/components/ToggleGroup/index.js +1 -0
- package/es6/components/ToggleGroup/propTypes.js +16 -0
- package/es6/components/ToggleGroup/stories/Controlled.js +25 -0
- package/es6/components/ToggleGroup/stories/multiple.tsx +28 -0
- package/es6/components/ToggleGroup/stories/simple.js +34 -0
- package/es6/components/Toolbar/Toolbar.js +1 -1
- package/es6/components/Video/StyledVideo.js +5 -5
- package/es6/components/Video/Video.js +1 -1
- package/es6/components/WorldMap/StyledWorldMap.js +2 -2
- package/es6/components/WorldMap/WorldMap.js +1 -1
- package/es6/components/index.d.ts +2 -0
- package/es6/components/index.js +1 -0
- package/es6/contexts/ResponsiveContext/stories/ResponsiveGrid.js +1 -1
- package/es6/index.d.ts +1 -0
- package/es6/themes/base.d.ts +20 -1
- package/es6/themes/base.js +19 -0
- package/es6/utils/DOM.js +3 -1
- package/es6/utils/pagination.js +1 -1
- package/es6/utils/styles.js +7 -1
- package/es6/utils/useControlled.js +25 -0
- package/grommet.min.js +1 -1
- package/grommet.min.js.map +1 -1
- package/index.d.ts +1 -0
- package/package.json +39 -35
- package/themes/base.d.ts +20 -1
- package/themes/base.js +19 -0
- package/tools/release-stable.js +1 -1
- package/tools/release-styled-components-beta-stable.js +1 -1
- package/utils/DOM.js +3 -1
- package/utils/pagination.js +1 -1
- package/utils/styles.js +8 -2
- package/utils/useControlled.js +28 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var _excluded = ["children", "overrideColumns", "overrideRows", "areas"];
|
|
2
2
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
|
|
3
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
3
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
4
4
|
import React from 'react';
|
|
5
5
|
import { Grommet, Box, Grid, Heading, ResponsiveContext } from 'grommet';
|
|
6
6
|
import { grommet } from 'grommet/themes';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var _excluded = ["children", "full", "containerTarget", "theme", "options", "messages", "onAnalytics"];
|
|
2
2
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
|
|
3
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
3
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
4
4
|
import React, { forwardRef, useEffect, useMemo, useState } from 'react';
|
|
5
5
|
import { createGlobalStyle } from 'styled-components';
|
|
6
6
|
import { ContainerTargetContext, ResponsiveContext, ThemeContext } from '../../contexts';
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import styled, { css } from 'styled-components';
|
|
2
|
-
import { baseStyle } from '../../utils';
|
|
2
|
+
import { baseStyle, styledComponentsConfig } from '../../utils';
|
|
3
3
|
import { defaultProps } from '../../default-props';
|
|
4
4
|
var fullStyle = function fullStyle(full) {
|
|
5
5
|
if (full === 'min') return css(["min-height:100vh;"]);
|
|
6
6
|
return css(["width:100vw;height:100vh;overflow:auto;"]);
|
|
7
7
|
};
|
|
8
|
-
var StyledGrommet = styled.div.withConfig({
|
|
8
|
+
var StyledGrommet = styled.div.withConfig(styledComponentsConfig).withConfig({
|
|
9
9
|
displayName: "StyledGrommet",
|
|
10
10
|
componentId: "sc-19lkkz7-0"
|
|
11
11
|
})(["", " ", " ", " ", " ", ""], function (props) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var _excluded = ["sticky"];
|
|
2
2
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
|
|
3
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
3
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
4
4
|
import React, { useContext, useEffect } from 'react';
|
|
5
5
|
import { ThemeContext } from 'styled-components';
|
|
6
6
|
import { findScrollParent, useForwardedRef } from '../../utils';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var _excluded = ["children", "color", "fill", "level", "overflowWrap", "weight"];
|
|
2
2
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
|
|
3
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
3
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
4
4
|
import React, { forwardRef, useState } from 'react';
|
|
5
5
|
import { useLayoutEffect } from '../../utils/use-isomorphic-layout-effect';
|
|
6
6
|
import { StyledHeading } from './StyledHeading';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import styled, { css } from 'styled-components';
|
|
2
|
-
import { breakpointStyle, genericStyles, normalizeColor, textAlignStyle } from '../../utils';
|
|
2
|
+
import { breakpointStyle, genericStyles, normalizeColor, textAlignStyle, styledComponentsConfig } from '../../utils';
|
|
3
3
|
import { defaultProps } from '../../default-props';
|
|
4
4
|
var sizeStyle = function sizeStyle(props) {
|
|
5
5
|
// size is a combination of the level and size properties
|
|
@@ -35,7 +35,7 @@ var truncateStyle = "\n white-space: nowrap;\n overflow: hidden;\n text-overf
|
|
|
35
35
|
var colorStyle = css(["color:", ";"], function (props) {
|
|
36
36
|
return normalizeColor(props.colorProp || props.theme.heading.color, props.theme);
|
|
37
37
|
});
|
|
38
|
-
var StyledHeading = styled.h1.withConfig({
|
|
38
|
+
var StyledHeading = styled.h1.withConfig(styledComponentsConfig).withConfig({
|
|
39
39
|
displayName: "StyledHeading",
|
|
40
40
|
componentId: "sc-1rdh4aw-0"
|
|
41
41
|
})(["", " ", " ", " ", " ", " ", " ", ""], genericStyles, function (props) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var _excluded = ["a11yTitle", "fallback", "onError", "onLoad", "opacity", "fill", "src"];
|
|
2
2
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
|
|
3
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
3
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
4
4
|
import React, { forwardRef, useState } from 'react';
|
|
5
5
|
import { StyledImage } from './StyledImage';
|
|
6
6
|
import { ImagePropTypes } from './propTypes';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import styled, { css } from 'styled-components';
|
|
2
|
-
import { fillStyle, genericStyles } from '../../utils';
|
|
2
|
+
import { fillStyle, genericStyles, styledComponentsConfig } from '../../utils';
|
|
3
3
|
import { defaultProps } from '../../default-props';
|
|
4
4
|
var FIT_MAP = {
|
|
5
5
|
cover: 'cover',
|
|
@@ -8,7 +8,7 @@ var FIT_MAP = {
|
|
|
8
8
|
var fitStyle = css(["flex:1 1;overflow:hidden;object-fit:", ";"], function (props) {
|
|
9
9
|
return FIT_MAP[props.fit];
|
|
10
10
|
});
|
|
11
|
-
var StyledImage = styled.img.withConfig({
|
|
11
|
+
var StyledImage = styled.img.withConfig(styledComponentsConfig).withConfig({
|
|
12
12
|
displayName: "StyledImage",
|
|
13
13
|
componentId: "sc-ey4zx9-0"
|
|
14
14
|
})(["", " ", " ", " ", " ", ""], genericStyles, function (props) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
var _excluded = ["capture", "target", "children", "onKeyDown"];
|
|
2
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
2
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
3
3
|
import { Children, cloneElement, useCallback, useEffect } from 'react';
|
|
4
4
|
import { KeyboardPropTypes } from './propTypes';
|
|
5
5
|
var KEYS = {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var _excluded = ["background", "children", "full", "id", "margin", "modal", "onClickOutside", "onEsc", "plain", "position", "responsive", "target"];
|
|
2
2
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
|
|
3
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
3
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
4
4
|
import React, { forwardRef, useContext, useEffect, useMemo, useRef } from 'react';
|
|
5
5
|
import styled, { ThemeContext } from 'styled-components';
|
|
6
6
|
import { defaultProps } from '../../default-props';
|
|
@@ -10,9 +10,9 @@ import { ResponsiveContext } from '../../contexts/ResponsiveContext';
|
|
|
10
10
|
import { OptionsContext } from '../../contexts/OptionsContext';
|
|
11
11
|
import { ContainerTargetContext } from '../../contexts/ContainerTargetContext';
|
|
12
12
|
import { useAnalytics } from '../../contexts/AnalyticsContext';
|
|
13
|
-
import { backgroundIsDark, findVisibleParent, PortalContext } from '../../utils';
|
|
13
|
+
import { backgroundIsDark, findVisibleParent, PortalContext, styledComponentsConfig } from '../../utils';
|
|
14
14
|
import { StyledLayer, StyledContainer, StyledOverlay } from './StyledLayer';
|
|
15
|
-
var HiddenAnchor = styled.a.withConfig({
|
|
15
|
+
var HiddenAnchor = styled.a.withConfig(styledComponentsConfig).withConfig({
|
|
16
16
|
displayName: "LayerContainer__HiddenAnchor",
|
|
17
17
|
componentId: "sc-1srj14c-0"
|
|
18
18
|
})(["width:0;height:0;overflow:hidden;position:absolute;&:focus{outline:none;}"]);
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import styled, { css, keyframes } from 'styled-components';
|
|
2
|
-
import
|
|
2
|
+
import isPropValid from '@emotion/is-prop-valid';
|
|
3
|
+
import { baseStyle, backgroundStyle, breakpointStyle, parseMetricToNum, styledComponentsConfig } from '../../utils';
|
|
3
4
|
import { defaultProps } from '../../default-props';
|
|
4
5
|
var hiddenPositionStyle = css(["left:-100%;right:100%;z-index:-1;position:fixed;"]);
|
|
5
6
|
var desktopLayerStyle = "\n position: fixed;\n top: 0px;\n left: 0px;\n right: 0px;\n bottom: 0px;\n";
|
|
6
7
|
var responsiveLayerStyle = "\n position: fixed;\n width: 100%;\n height: 100%;\n min-height: 100vh;\n";
|
|
7
|
-
var StyledLayer = styled.div.withConfig({
|
|
8
|
+
var StyledLayer = styled.div.withConfig(styledComponentsConfig).withConfig({
|
|
8
9
|
displayName: "StyledLayer",
|
|
9
10
|
componentId: "sc-rmtehz-0"
|
|
10
11
|
})(["", " background:transparent;position:relative;z-index:", ";pointer-events:none;outline:none;", " ", ";"], baseStyle, function (props) {
|
|
@@ -25,7 +26,7 @@ var StyledLayer = styled.div.withConfig({
|
|
|
25
26
|
});
|
|
26
27
|
StyledLayer.defaultProps = {};
|
|
27
28
|
Object.setPrototypeOf(StyledLayer.defaultProps, defaultProps);
|
|
28
|
-
var StyledOverlay = styled.div.withConfig({
|
|
29
|
+
var StyledOverlay = styled.div.withConfig(styledComponentsConfig).withConfig({
|
|
29
30
|
displayName: "StyledLayer__StyledOverlay",
|
|
30
31
|
componentId: "sc-rmtehz-1"
|
|
31
32
|
})(["position:absolute;", " top:0px;left:0px;right:0px;bottom:0px;", " ", " pointer-events:all;will-change:transform;"], function (props) {
|
|
@@ -440,10 +441,8 @@ var elevationStyle = css(["box-shadow:", ";"], function (props) {
|
|
|
440
441
|
return props.theme.global.elevation[props.theme.dark ? 'dark' : 'light'][props.theme.layer.container.elevation];
|
|
441
442
|
});
|
|
442
443
|
var StyledContainer = styled.div.withConfig({
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
shouldForwardProp: function shouldForwardProp(prop, defaultValidatorFn) {
|
|
446
|
-
return !['elevation'].includes(prop) && defaultValidatorFn(prop);
|
|
444
|
+
shouldForwardProp: function shouldForwardProp(prop) {
|
|
445
|
+
return isPropValid(prop) && !['elevation'].includes(prop);
|
|
447
446
|
}
|
|
448
447
|
}).withConfig({
|
|
449
448
|
displayName: "StyledLayer__StyledContainer",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
var _excluded = ["a11yTitle", "aria-label", "action", "as", "background", "border", "children", "data", "defaultItemProps", "disabled", "focus", "itemKey", "itemProps", "onActive", "onClickItem", "onKeyDown", "onMore", "onOrder", "pad", "paginate", "pinned", "primaryKey", "secondaryKey", "show", "step"];
|
|
2
2
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
|
|
3
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
4
|
-
import React, { Fragment, useContext, useMemo, useRef, useState } from 'react';
|
|
3
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
4
|
+
import React, { Fragment, cloneElement, useContext, useMemo, useRef, useState } from 'react';
|
|
5
5
|
import styled, { ThemeContext } from 'styled-components';
|
|
6
6
|
import { DataContext } from '../../contexts/DataContext';
|
|
7
7
|
import { Box } from '../Box';
|
|
@@ -10,11 +10,11 @@ import { InfiniteScroll } from '../InfiniteScroll';
|
|
|
10
10
|
import { Keyboard } from '../Keyboard';
|
|
11
11
|
import { Pagination } from '../Pagination';
|
|
12
12
|
import { Text } from '../Text';
|
|
13
|
-
import { focusStyle, genericStyles, normalizeColor, normalizeShow, unfocusStyle, useForwardedRef, usePagination } from '../../utils';
|
|
13
|
+
import { focusStyle, genericStyles, normalizeColor, normalizeShow, unfocusStyle, useForwardedRef, usePagination, styledComponentsConfig } from '../../utils';
|
|
14
14
|
import { useAnalytics } from '../../contexts/AnalyticsContext';
|
|
15
15
|
import { ListPropTypes } from './propTypes';
|
|
16
16
|
var emptyData = [];
|
|
17
|
-
var StyledList = styled.ul.withConfig({
|
|
17
|
+
var StyledList = styled.ul.withConfig(styledComponentsConfig).withConfig({
|
|
18
18
|
displayName: "List__StyledList",
|
|
19
19
|
componentId: "sc-130gdqg-0"
|
|
20
20
|
})(["list-style:none;", " padding:0;", " &:focus{", "}", "}&:focus:not(:focus-visible){", "}"], function (props) {
|
|
@@ -174,8 +174,10 @@ var List = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
174
174
|
indexes: pinnedIndexes
|
|
175
175
|
}];
|
|
176
176
|
currentData.forEach(function (item, index) {
|
|
177
|
+
var _pinned$items;
|
|
177
178
|
var key = getValue(item, index, itemKey);
|
|
178
|
-
|
|
179
|
+
var isPinned = Array.isArray(pinned) ? pinned.includes(key) : typeof pinned === 'object' && (pinned == null || (_pinned$items = pinned.items) == null ? void 0 : _pinned$items.includes(key));
|
|
180
|
+
if (isPinned) {
|
|
179
181
|
pinnedData.push(item);
|
|
180
182
|
pinnedIndexes.push(index);
|
|
181
183
|
} else {
|
|
@@ -301,8 +303,21 @@ var List = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
301
303
|
}, marker);
|
|
302
304
|
}
|
|
303
305
|
}, function (item, index) {
|
|
306
|
+
var _pinned$items2;
|
|
304
307
|
var content;
|
|
305
308
|
var boxProps = {};
|
|
309
|
+
var key = getValue(item, index, itemKey) || index;
|
|
310
|
+
var isPinned;
|
|
311
|
+
if (Array.isArray(pinned) && pinned.length > 0 || Array.isArray(pinned == null ? void 0 : pinned.items) && (pinned == null || (_pinned$items2 = pinned.items) == null ? void 0 : _pinned$items2.length) > 0) {
|
|
312
|
+
if (typeof item === 'object' && !itemKey) {
|
|
313
|
+
console.error( // eslint-disable-next-line max-len
|
|
314
|
+
"Warning: Missing prop itemKey. Prop pin requires itemKey to be specified when data is of type 'object'.");
|
|
315
|
+
}
|
|
316
|
+
isPinned = Array.isArray(pinned) ? pinned == null ? void 0 : pinned.includes(key) : pinned.items.some(function (pinnedItem) {
|
|
317
|
+
return pinnedItem === key;
|
|
318
|
+
});
|
|
319
|
+
}
|
|
320
|
+
var pinnedColor = isPinned ? pinned.color : undefined;
|
|
306
321
|
if (children) {
|
|
307
322
|
content = children(item, index, onClickItem ? {
|
|
308
323
|
active: active === index
|
|
@@ -310,11 +325,13 @@ var List = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
310
325
|
} else if (primaryKey) {
|
|
311
326
|
var primary = getValue(item, index, primaryKey);
|
|
312
327
|
content = typeof primary === 'string' || typeof primary === 'number' ? /*#__PURE__*/React.createElement(Text, _extends({
|
|
328
|
+
color: pinnedColor,
|
|
313
329
|
key: "p"
|
|
314
330
|
}, theme.list.primaryKey), primary) : primary;
|
|
315
331
|
if (secondaryKey) {
|
|
316
332
|
var secondary = getValue(item, index, secondaryKey);
|
|
317
333
|
content = [content, typeof secondary === 'string' || typeof secondary === 'number' ? /*#__PURE__*/React.createElement(Text, {
|
|
334
|
+
color: pinnedColor,
|
|
318
335
|
key: "s"
|
|
319
336
|
}, getValue(item, index, secondaryKey)) : secondary];
|
|
320
337
|
boxProps = {
|
|
@@ -325,11 +342,20 @@ var List = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
325
342
|
};
|
|
326
343
|
}
|
|
327
344
|
} else if (typeof item === 'object') {
|
|
328
|
-
|
|
345
|
+
var value = item[Object.keys(item)[0]];
|
|
346
|
+
content =
|
|
347
|
+
// for backwards compatibility, only wrap in Text if
|
|
348
|
+
// pinned.color is defined
|
|
349
|
+
pinnedColor && typeof value === 'string' ? /*#__PURE__*/React.createElement(Text, {
|
|
350
|
+
color: pinnedColor
|
|
351
|
+
}, value) : value;
|
|
329
352
|
} else {
|
|
330
|
-
|
|
353
|
+
// for backwards compatibility, only wrap in Text if
|
|
354
|
+
// pinned.color is defined
|
|
355
|
+
content = pinnedColor ? /*#__PURE__*/React.createElement(Text, {
|
|
356
|
+
color: pinnedColor
|
|
357
|
+
}, item) : item;
|
|
331
358
|
}
|
|
332
|
-
var key = getValue(item, index, itemKey) || index;
|
|
333
359
|
var orderableIndex = orderableData.findIndex(function (ordItem, ordIndex) {
|
|
334
360
|
return getValue(ordItem, ordIndex, itemKey) === key;
|
|
335
361
|
});
|
|
@@ -341,14 +367,6 @@ var List = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
341
367
|
}
|
|
342
368
|
isDisabled = disabledItems == null ? void 0 : disabledItems.includes(key);
|
|
343
369
|
}
|
|
344
|
-
var isPinned;
|
|
345
|
-
if (pinned.length > 0) {
|
|
346
|
-
if (typeof item === 'object' && !itemKey) {
|
|
347
|
-
console.error( // eslint-disable-next-line max-len
|
|
348
|
-
"Warning: Missing prop itemKey. Prop pin requires itemKey to be specified when data is of type 'object'.");
|
|
349
|
-
}
|
|
350
|
-
isPinned = pinned == null ? void 0 : pinned.includes(key);
|
|
351
|
-
}
|
|
352
370
|
if (action) {
|
|
353
371
|
content = [/*#__PURE__*/React.createElement(Box, {
|
|
354
372
|
align: "start",
|
|
@@ -367,7 +385,7 @@ var List = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
367
385
|
} else if (Array.isArray(adjustedBackground)) {
|
|
368
386
|
adjustedBackground = adjustedBackground[index % adjustedBackground.length];
|
|
369
387
|
} else if (isPinned) {
|
|
370
|
-
adjustedBackground = theme.list.item.pinned.background;
|
|
388
|
+
adjustedBackground = (pinned == null ? void 0 : pinned.background) || theme.list.item.pinned.background;
|
|
371
389
|
}
|
|
372
390
|
var adjustedBorder = border !== undefined ? border : theme.list.item.border;
|
|
373
391
|
if (adjustedBorder === 'horizontal' && index) {
|
|
@@ -541,10 +559,16 @@ var List = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
541
559
|
}
|
|
542
560
|
var displayPinned;
|
|
543
561
|
if (isPinned) {
|
|
544
|
-
|
|
545
|
-
var Pin = theme.list.icons.pin;
|
|
562
|
+
var _pinIcon$props;
|
|
546
563
|
var pinSize = theme.list.item.pinned.icon.size;
|
|
547
564
|
var pinPad = theme.list.item.pinned.icon.pad;
|
|
565
|
+
var Icon = (pinned == null ? void 0 : pinned.icon) || theme.list.icons.pin;
|
|
566
|
+
var pinIcon = /*#__PURE__*/React.isValidElement(Icon) ? Icon : /*#__PURE__*/React.createElement(Icon, null);
|
|
567
|
+
pinIcon = /*#__PURE__*/cloneElement(pinIcon, _extends({}, !((_pinIcon$props = pinIcon.props) != null && _pinIcon$props.color) && pinnedColor ? {
|
|
568
|
+
color: pinnedColor
|
|
569
|
+
} : {}, {
|
|
570
|
+
size: pinSize
|
|
571
|
+
}));
|
|
548
572
|
boxProps = {
|
|
549
573
|
direction: 'row',
|
|
550
574
|
align: defaultItemProps && defaultItemProps.align || 'center',
|
|
@@ -555,9 +579,7 @@ var List = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
555
579
|
align: "center",
|
|
556
580
|
justify: "end",
|
|
557
581
|
pad: pinPad
|
|
558
|
-
},
|
|
559
|
-
size: pinSize
|
|
560
|
-
}));
|
|
582
|
+
}, pinIcon);
|
|
561
583
|
content = /*#__PURE__*/React.createElement(Box, {
|
|
562
584
|
flex: true
|
|
563
585
|
}, content);
|
|
@@ -573,7 +595,9 @@ var List = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
573
595
|
isDisabled: isDisabled,
|
|
574
596
|
flex: false,
|
|
575
597
|
pad: pad || theme.list.item.pad
|
|
576
|
-
}, defaultItemProps, boxProps, clickProps, orderProps, itemAriaProps), onOrder && /*#__PURE__*/React.createElement(Text,
|
|
598
|
+
}, defaultItemProps, boxProps, clickProps, orderProps, itemAriaProps), onOrder && /*#__PURE__*/React.createElement(Text, {
|
|
599
|
+
color: pinnedColor
|
|
600
|
+
}, index + 1), content, displayPinned, orderControls);
|
|
577
601
|
}))), paginate && data.length > step && items && items.length ? /*#__PURE__*/React.createElement(Pagination, _extends({
|
|
578
602
|
alignSelf: "end"
|
|
579
603
|
}, paginationProps)) : null);
|
|
@@ -2,6 +2,8 @@ import * as React from 'react';
|
|
|
2
2
|
import {
|
|
3
3
|
A11yTitleType,
|
|
4
4
|
AlignSelfType,
|
|
5
|
+
BackgroundType,
|
|
6
|
+
ColorType,
|
|
5
7
|
GridAreaType,
|
|
6
8
|
MarginType,
|
|
7
9
|
PadType,
|
|
@@ -43,7 +45,11 @@ export interface ListProps<ListItemType> {
|
|
|
43
45
|
| string[]
|
|
44
46
|
| { light: string | string[]; dark: string | string[] };
|
|
45
47
|
border?: BorderType;
|
|
46
|
-
children?: (
|
|
48
|
+
children?: (
|
|
49
|
+
item: ListItemType,
|
|
50
|
+
index: number,
|
|
51
|
+
state?: { active: boolean },
|
|
52
|
+
) => any;
|
|
47
53
|
data?: ListItemType[];
|
|
48
54
|
disabled?: string[];
|
|
49
55
|
gridArea?: GridAreaType;
|
|
@@ -54,14 +60,22 @@ export interface ListProps<ListItemType> {
|
|
|
54
60
|
};
|
|
55
61
|
margin?: MarginType;
|
|
56
62
|
onActive?: (index: number) => void;
|
|
57
|
-
onClickItem?:
|
|
58
|
-
|
|
59
|
-
|
|
63
|
+
onClickItem?: (
|
|
64
|
+
event: React.MouseEvent & { item: ListItemType; index: number },
|
|
65
|
+
) => void;
|
|
60
66
|
onMore?: () => void;
|
|
61
67
|
onOrder?: (orderedData: ListItemType[]) => void;
|
|
62
68
|
pad?: PadType;
|
|
63
69
|
paginate?: boolean | PaginationType;
|
|
64
|
-
pinned?:
|
|
70
|
+
pinned?:
|
|
71
|
+
| boolean
|
|
72
|
+
| (string | number)[]
|
|
73
|
+
| {
|
|
74
|
+
items?: (string | number)[];
|
|
75
|
+
background?: BackgroundType;
|
|
76
|
+
color?: ColorType;
|
|
77
|
+
icon?: JSX.Element;
|
|
78
|
+
};
|
|
65
79
|
primaryKey?: string | ((item: ListItemType) => React.ReactElement);
|
|
66
80
|
secondaryKey?: string | ((item: ListItemType) => React.ReactElement);
|
|
67
81
|
show?: number | { page?: number };
|
|
@@ -76,7 +90,7 @@ export interface ListExtendedProps<ListItemType>
|
|
|
76
90
|
ulProps {}
|
|
77
91
|
|
|
78
92
|
declare const List: <ListItemType = string | {}>(
|
|
79
|
-
p:
|
|
93
|
+
p: ListExtendedProps<ListItemType>,
|
|
80
94
|
) => React.ReactElement<ListExtendedProps<ListItemType>>;
|
|
81
95
|
|
|
82
96
|
export { List };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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
|
import PropTypes from 'prop-types';
|
|
3
|
-
import { genericProps, padPropType } from '../../utils/general-prop-types';
|
|
3
|
+
import { backgroundDoc, genericProps, padPropType } from '../../utils/general-prop-types';
|
|
4
4
|
import { BoxPropTypes } from '../Box/propTypes';
|
|
5
5
|
var sizes = ['none', 'xxsmall', 'xsmall', 'small', 'medium', 'large', 'xlarge'];
|
|
6
6
|
var sides = ['horizontal', 'vertical', 'top', 'bottom', 'left', 'right', 'start', 'end'];
|
|
@@ -35,7 +35,12 @@ if (process.env.NODE_ENV !== 'production') {
|
|
|
35
35
|
onOrder: PropTypes.func,
|
|
36
36
|
pad: PropTypes.oneOfType([padPropType]),
|
|
37
37
|
paginate: PropTypes.oneOfType([PropTypes.bool, PropTypes.object]),
|
|
38
|
-
pinned: PropTypes.arrayOf(PropTypes.string),
|
|
38
|
+
pinned: PropTypes.oneOfType([PropTypes.bool, PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.string, PropTypes.number])), PropTypes.shape({
|
|
39
|
+
items: PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.string, PropTypes.number])),
|
|
40
|
+
background: backgroundDoc,
|
|
41
|
+
color: PropTypes.string,
|
|
42
|
+
icon: PropTypes.element
|
|
43
|
+
})]),
|
|
39
44
|
primaryKey: PropTypes.oneOfType([PropTypes.string, PropTypes.func]),
|
|
40
45
|
secondaryKey: PropTypes.oneOfType([PropTypes.string, PropTypes.func]),
|
|
41
46
|
show: PropTypes.oneOfType([PropTypes.number, PropTypes.shape({
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var _excluded = ["children", "components", "options", "theme"];
|
|
2
2
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
|
|
3
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
3
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
4
4
|
import React, { forwardRef, Fragment } from 'react';
|
|
5
5
|
import Markdown from 'markdown-to-jsx';
|
|
6
6
|
import { deepMerge } from '../../utils';
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import styled from 'styled-components';
|
|
3
3
|
import { Box, Markdown } from 'grommet';
|
|
4
|
+
import { styledComponentsConfig } from '../../../utils/styles';
|
|
4
5
|
var CONTENT = "\n # Out of Breath\n\n You know, sometimes in life it seems like there's no way out. Like\n a sheep trapped in a maze designed by wolves. See all the\n options [here](https://github.com/probablyup/markdown-to-jsx/)\n\n [reference](#)\n\n```\nimport { Grommet } from 'grommet';\n```\n\n > i carry your heart with me\n\n \n\n Markdown | Less | Pretty\n --- | --- | ---\n *Still* | `renders` | **nicely**\n 1 | 2 | 3\n";
|
|
5
|
-
var StyledPre = styled.pre.withConfig({
|
|
6
|
+
var StyledPre = styled.pre.withConfig(styledComponentsConfig).withConfig({
|
|
6
7
|
displayName: "Override__StyledPre",
|
|
7
8
|
componentId: "sc-13lo9xg-0"
|
|
8
9
|
})(["background-color:#ffca58;"]);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var _excluded = ["a11yTitle", "dropHeight", "dropProps", "focus", "focusIndicator", "icon", "id", "mask", "name", "onBlur", "onChange", "onFocus", "onKeyDown", "placeholder", "plain", "reverse", "textAlign", "value"];
|
|
2
2
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
|
|
3
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
3
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
4
4
|
import React, { forwardRef, useCallback, useContext, useEffect, useMemo, useRef, useState } from 'react';
|
|
5
5
|
import styled, { ThemeContext } from 'styled-components';
|
|
6
6
|
import { defaultProps } from '../../default-props';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import styled from 'styled-components';
|
|
2
|
-
import { disabledStyle, getInputPadBySide, inputStyle, plainInputStyle, textAlignStyle } from '../../utils';
|
|
2
|
+
import { disabledStyle, getInputPadBySide, inputStyle, plainInputStyle, textAlignStyle, styledComponentsConfig } from '../../utils';
|
|
3
3
|
import { inputPadForIcon } from '../../utils/styles';
|
|
4
|
-
export var StyledMaskedInput = styled.input.withConfig({
|
|
4
|
+
export var StyledMaskedInput = styled.input.withConfig(styledComponentsConfig).withConfig({
|
|
5
5
|
displayName: "StyledMaskedInput",
|
|
6
6
|
componentId: "sc-99vkfa-0"
|
|
7
7
|
})(["", " ", " ", " ", " ", " ", ";"], inputStyle, function (props) {
|
|
@@ -15,13 +15,13 @@ export var StyledMaskedInput = styled.input.withConfig({
|
|
|
15
15
|
}, function (props) {
|
|
16
16
|
return props.theme.maskedInput && props.theme.maskedInput.extend;
|
|
17
17
|
});
|
|
18
|
-
export var StyledMaskedInputContainer = styled.div.withConfig({
|
|
18
|
+
export var StyledMaskedInputContainer = styled.div.withConfig(styledComponentsConfig).withConfig({
|
|
19
19
|
displayName: "StyledMaskedInput__StyledMaskedInputContainer",
|
|
20
20
|
componentId: "sc-99vkfa-1"
|
|
21
21
|
})(["position:relative;width:100%;", ";"], function (props) {
|
|
22
22
|
return props.theme.maskedInput && props.theme.maskedInput.container && props.theme.maskedInput.container.extend;
|
|
23
23
|
});
|
|
24
|
-
export var StyledIcon = styled.div.withConfig({
|
|
24
|
+
export var StyledIcon = styled.div.withConfig(styledComponentsConfig).withConfig({
|
|
25
25
|
displayName: "StyledMaskedInput__StyledIcon",
|
|
26
26
|
componentId: "sc-99vkfa-2"
|
|
27
27
|
})(["position:absolute;display:flex;justify:center;top:50%;transform:translateY(-50%);pointer-events:none;", ""], function (props) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
var _excluded = ["a11yTitle", "aria-label", "children", "disabled", "dropAlign", "dropBackground", "dropProps", "dropTarget", "justifyContent", "icon", "items", "label", "messages", "onKeyDown", "open", "plain", "size"],
|
|
2
2
|
_excluded2 = ["align"];
|
|
3
3
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
4
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
5
5
|
import React, { useRef, forwardRef, useCallback, useContext, useMemo, useState, useEffect } from 'react';
|
|
6
6
|
import styled, { ThemeContext } from 'styled-components';
|
|
7
7
|
import { defaultProps } from '../../default-props';
|
|
@@ -16,7 +16,7 @@ import { MenuPropTypes } from './propTypes';
|
|
|
16
16
|
var ContainerBox = styled(Box).withConfig({
|
|
17
17
|
displayName: "Menu__ContainerBox",
|
|
18
18
|
componentId: "sc-17fcys9-0"
|
|
19
|
-
})(["max-height:inherit;@media screen and (-ms-high-contrast:active),(-ms-high-contrast:none){width:100%;}
|
|
19
|
+
})(["max-height:inherit;@media screen and (-ms-high-contrast:active),(-ms-high-contrast:none){width:100%;}&:focus{outline:none;}", ";"], function (props) {
|
|
20
20
|
return props.theme.menu.extend;
|
|
21
21
|
});
|
|
22
22
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
var _excluded = ["background", "max", "round", "size", "thickness", "direction", "values", "reverse"],
|
|
2
2
|
_excluded2 = ["color", "highlight", "label", "onHover", "value"];
|
|
3
3
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
4
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
5
5
|
import React, { forwardRef, useContext } from 'react';
|
|
6
6
|
import { ThemeContext } from 'styled-components';
|
|
7
7
|
import { defaultProps } from '../../default-props';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
var _excluded = ["background", "max", "round", "size", "thickness", "type", "values"],
|
|
2
2
|
_excluded2 = ["color", "highlight", "label", "onHover", "value"];
|
|
3
3
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
4
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
5
5
|
import React, { forwardRef, useContext } from 'react';
|
|
6
6
|
import { ThemeContext } from 'styled-components';
|
|
7
7
|
import { defaultProps } from '../../default-props';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var _excluded = ["background", "color", "direction", "size", "thickness", "type", "reverse", "value", "values"];
|
|
2
2
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
|
|
3
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
3
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
4
4
|
import React, { forwardRef, useMemo, useContext } from 'react';
|
|
5
5
|
import { ThemeContext } from 'styled-components';
|
|
6
6
|
import { defaultProps } from '../../default-props';
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import styled, { css } from 'styled-components';
|
|
2
|
-
import { genericStyles } from '../../utils';
|
|
2
|
+
import { genericStyles, styledComponentsConfig } from '../../utils';
|
|
3
3
|
import { defaultProps } from '../../default-props';
|
|
4
4
|
var roundStyle = css(["border-radius:", ";"], function (props) {
|
|
5
5
|
return props.theme.global.edgeSize[props.round.size];
|
|
6
6
|
});
|
|
7
7
|
|
|
8
8
|
// overflow: hidden is needed for ie11
|
|
9
|
-
var StyledMeter = styled.svg.withConfig({
|
|
9
|
+
var StyledMeter = styled.svg.withConfig(styledComponentsConfig).withConfig({
|
|
10
10
|
displayName: "StyledMeter",
|
|
11
11
|
componentId: "sc-nsxarx-0"
|
|
12
12
|
})(["max-width:100%;overflow:hidden;", " ", " ", " path{transition:stroke 0.3s,stroke-width 0.3s;}", ";"], function (props) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var _excluded = ["align", "layout", "nameProps", "pairProps", "valueProps"];
|
|
2
2
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
|
|
3
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
3
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
4
4
|
import React, { forwardRef, useContext, useMemo } from 'react';
|
|
5
5
|
import { ThemeContext } from 'styled-components';
|
|
6
6
|
import { Grid } from '../Grid';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var _excluded = ["label"];
|
|
2
2
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
|
|
3
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
3
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
4
4
|
import React, { useState } from 'react';
|
|
5
5
|
import { Box, Button, Grommet, Nav } from 'grommet';
|
|
6
6
|
import { Dashboard } from "grommet-icons/es6/icons/Dashboard";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var _excluded = ["label"];
|
|
2
2
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
|
|
3
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
3
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
4
4
|
import React, { useState } from 'react';
|
|
5
5
|
import { Box, Button, Nav, Text } from 'grommet';
|
|
6
6
|
var SidebarButton = function SidebarButton(_ref) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var _excluded = ["actions", "message", "onClose", "id", "global", "status", "title", "toast", "icon", "time"];
|
|
2
2
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
|
|
3
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
3
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
4
4
|
import React, { useCallback, useContext, useEffect, useState, useMemo, Fragment } from 'react';
|
|
5
5
|
import styled, { ThemeContext } from 'styled-components';
|
|
6
6
|
import { defaultProps } from '../../default-props';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var _excluded = ["kind"];
|
|
2
2
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
|
|
3
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
3
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
4
4
|
import React, { useContext, useMemo } from 'react';
|
|
5
5
|
import { ThemeContext } from 'styled-components';
|
|
6
6
|
import { Box } from '../Box';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
var _excluded = ["children", "background"];
|
|
2
2
|
function _objectDestructuringEmpty(obj) { if (obj == null) throw new TypeError("Cannot destructure " + obj); }
|
|
3
3
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var
|
|
4
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } } return target; }
|
|
5
5
|
import React, { useContext } from 'react';
|
|
6
6
|
import { Box } from '../Box';
|
|
7
7
|
import { PageContext } from '../Page';
|