grommet 2.33.2 → 2.34.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 +5 -7
- package/all/stories/Colors.js +3 -5
- package/all/stories/CustomThemed/DefaultTheme.js +3 -5
- package/all/stories/TypographyLarge.js +3 -5
- package/all/stories/TypographyMedium.js +3 -5
- package/all/stories/TypographySmall.js +3 -5
- package/components/Accordion/Accordion.js +3 -4
- package/components/Accordion/AccordionContext.js +1 -2
- package/components/Accordion/propTypes.js +1 -2
- package/components/Accordion/stories/CustomHeader.js +5 -7
- package/components/Accordion/stories/CustomThemed/Custom.js +3 -5
- package/components/Accordion/stories/Multiple.js +4 -5
- package/components/Accordion/stories/Simple.js +3 -5
- package/components/AccordionPanel/AccordionPanel.js +3 -4
- package/components/AccordionPanel/propTypes.js +1 -2
- package/components/Anchor/Anchor.js +3 -4
- package/components/Anchor/StyledAnchor.js +3 -4
- package/components/Anchor/propTypes.js +1 -2
- package/components/Anchor/stories/Color.js +3 -5
- package/components/Anchor/stories/Default.js +3 -5
- package/components/Anchor/stories/Gap.js +3 -5
- package/components/Anchor/stories/Size.js +3 -5
- package/components/Anchor/stories/Weight.js +3 -5
- package/components/Avatar/Avatar.js +3 -4
- package/components/Avatar/StyledAvatar.js +2 -4
- package/components/Avatar/propTypes.js +1 -2
- package/components/Avatar/stories/Basic.js +3 -5
- package/components/Avatar/stories/CustomThemed/Themed.js +3 -5
- package/components/Avatar/stories/Round.js +3 -5
- package/components/Avatar/stories/Sizes.js +3 -5
- package/components/Box/Box.js +3 -4
- package/components/Box/StyledBox.js +4 -6
- package/components/Box/index.d.ts +1 -1
- package/components/Box/propTypes.js +1 -2
- package/components/Box/stories/Animation.js +3 -5
- package/components/Box/stories/Background.js +4 -5
- package/components/Box/stories/BackgroundThemed.js +6 -7
- package/components/Box/stories/Border.js +4 -5
- package/components/Box/stories/Custom.js +4 -5
- package/components/Box/stories/Elevation.js +4 -5
- package/components/Box/stories/Fixed.js +4 -5
- package/components/Box/stories/MinMax.js +4 -5
- package/components/Box/stories/OnClick.js +4 -5
- package/components/Box/stories/RTL.js +4 -5
- package/components/Box/stories/Round.js +5 -6
- package/components/Box/stories/Simple.js +8 -8
- package/components/Button/Badge.js +4 -5
- package/components/Button/BusyAnimation.js +6 -9
- package/components/Button/Button.js +3 -4
- package/components/Button/StyledButton.js +3 -4
- package/components/Button/StyledButtonKind.js +3 -4
- package/components/Button/propTypes.js +1 -2
- package/components/Button/stories/Active.js +3 -5
- package/components/Button/stories/Basic.js +3 -5
- package/components/Button/stories/Busy.js +5 -7
- package/components/Button/stories/CustomThemed/Active.js +3 -5
- package/components/Button/stories/CustomThemed/Plain.js +3 -5
- package/components/Button/stories/CustomThemed/ThemedButtons.js +3 -5
- package/components/Button/stories/Fill.js +3 -5
- package/components/Button/stories/Icon.js +3 -5
- package/components/Button/stories/IconLabel.js +3 -5
- package/components/Button/stories/Kind.js +3 -5
- package/components/Button/stories/Multiple.js +3 -5
- package/components/Button/stories/RoutedButton.js +3 -5
- package/components/Button/stories/Sizes.js +3 -5
- package/components/Button/stories/TipOnButton.js +3 -5
- package/components/Calendar/Calendar.js +4 -6
- package/components/Calendar/StyledCalendar.js +8 -14
- package/components/Calendar/propTypes.js +1 -2
- package/components/Calendar/stories/ActiveDate.js +6 -7
- package/components/Calendar/stories/CustomDay.js +6 -7
- package/components/Calendar/stories/CustomHeader.js +6 -7
- package/components/Calendar/stories/CustomThemed/CustomSizeHeading.js +5 -7
- package/components/Calendar/stories/DaylightSavings.js +4 -5
- package/components/Calendar/stories/Dual.js +5 -7
- package/components/Calendar/stories/Fill.js +3 -5
- package/components/Calendar/stories/Multiple.js +5 -7
- package/components/Calendar/stories/Range.js +3 -5
- package/components/Calendar/stories/ShowAdjacentDays.js +6 -7
- package/components/Calendar/stories/Simple.js +5 -7
- package/components/Calendar/stories/SundayFirstDay.js +4 -5
- package/components/Calendar/utils.js +14 -27
- package/components/Card/Card.js +3 -4
- package/components/Card/stories/CustomThemed/Clickable.js +3 -5
- package/components/Card/stories/CustomThemed/RichFooter.js +3 -5
- package/components/Card/stories/CustomThemed/Stacked.js +3 -5
- package/components/Card/stories/CustomThemed/Themed.js +3 -5
- package/components/Card/stories/Simple.js +3 -5
- package/components/CardBody/CardBody.js +4 -5
- package/components/CardFooter/CardFooter.js +4 -5
- package/components/CardHeader/CardHeader.js +4 -5
- package/components/Cards/Cards.js +3 -4
- package/components/Cards/propTypes.js +1 -2
- package/components/Cards/stories/Children.js +3 -5
- package/components/Cards/stories/Paginated.js +3 -5
- package/components/Cards/stories/Simple.js +3 -5
- package/components/Carousel/Carousel.js +3 -4
- package/components/Carousel/CarouselChild.js +3 -4
- package/components/Carousel/StyledCarousel.js +6 -9
- package/components/Carousel/propTypes.js +2 -4
- package/components/Carousel/stories/Autoplay.js +3 -5
- package/components/Carousel/stories/ControlVariations.js +4 -5
- package/components/Carousel/stories/Controlled.js +4 -5
- package/components/Carousel/stories/CustomThemed/Custom.js +3 -5
- package/components/Carousel/stories/InteractiveChild.js +4 -5
- package/components/Carousel/stories/Multiple.js +3 -5
- package/components/Carousel/stories/Simple.js +4 -5
- package/components/Chart/Chart.js +3 -4
- package/components/Chart/StyledChart.js +3 -4
- package/components/Chart/calcs.js +4 -7
- package/components/Chart/index.d.ts +4 -4
- package/components/Chart/propTypes.js +1 -2
- package/components/Chart/stories/Animate.js +4 -5
- package/components/Chart/stories/Dash.js +3 -5
- package/components/Chart/stories/Gradient.js +4 -5
- package/components/Chart/stories/Horizontal.js +3 -5
- package/components/Chart/stories/Labelled.js +4 -5
- package/components/Chart/stories/Layout.js +3 -5
- package/components/Chart/stories/Pattern.js +3 -5
- package/components/Chart/stories/Point.js +3 -5
- package/components/Chart/stories/Range.js +3 -5
- package/components/Chart/stories/Rich.js +5 -7
- package/components/Chart/stories/Round.js +3 -5
- package/components/Chart/stories/Scan.js +5 -7
- package/components/Chart/stories/ValueStyle.js +4 -5
- package/components/Chart/stories/Window.js +5 -7
- package/components/Chart/stories/Zoom.js +5 -7
- package/components/Chart/stories/data.js +1 -2
- package/components/Chart/utils.js +6 -11
- package/components/CheckBox/CheckBox.js +3 -4
- package/components/CheckBox/StyledCheckBox.js +9 -16
- package/components/CheckBox/propTypes.js +1 -2
- package/components/CheckBox/stories/Children.js +3 -5
- package/components/CheckBox/stories/CustomThemed/Custom.js +5 -7
- package/components/CheckBox/stories/CustomThemed/CustomToggle.js +5 -7
- package/components/CheckBox/stories/Indeterminate.js +5 -7
- package/components/CheckBox/stories/InsideButton.js +5 -7
- package/components/CheckBox/stories/NoLabel.js +5 -7
- package/components/CheckBox/stories/Simple.js +5 -7
- package/components/CheckBox/stories/WithStickyDiv.js +5 -7
- package/components/CheckBoxGroup/CheckBoxGroup.js +3 -4
- package/components/CheckBoxGroup/StyledCheckBoxGroup.js +1 -2
- package/components/CheckBoxGroup/propTypes.js +1 -2
- package/components/CheckBoxGroup/stories/Children.js +5 -7
- package/components/CheckBoxGroup/stories/Disabled.js +3 -5
- package/components/CheckBoxGroup/stories/InitialValues.js +5 -7
- package/components/CheckBoxGroup/stories/Simple.js +3 -5
- package/components/Clock/Analog.js +3 -4
- package/components/Clock/Clock.js +3 -4
- package/components/Clock/Digital.js +4 -5
- package/components/Clock/StyledClock.js +9 -16
- package/components/Clock/propTypes.js +1 -2
- package/components/Clock/stories/Analog.js +4 -5
- package/components/Clock/stories/Countdown.js +4 -5
- package/components/Clock/stories/CustomThemed/Digital.js +3 -5
- package/components/Collapsible/Collapsible.js +3 -4
- package/components/Collapsible/propTypes.js +1 -2
- package/components/Collapsible/stories/Horizontal.js +4 -5
- package/components/Collapsible/stories/Nested.js +4 -5
- package/components/Collapsible/stories/Simple.js +4 -5
- package/components/Data/Data.js +3 -4
- package/components/Data/DataForm.js +12 -21
- package/components/Data/filter.js +2 -3
- package/components/Data/propTypes.js +1 -2
- package/components/Data/stories/Cards.js +4 -5
- package/components/Data/stories/Complex.js +4 -5
- package/components/Data/stories/Controlled.js +6 -7
- package/components/Data/stories/DataTable.js +4 -5
- package/components/Data/stories/Infinite.js +7 -8
- package/components/Data/stories/Inline.js +6 -7
- package/components/Data/stories/List.js +4 -5
- package/components/Data/stories/Simple.js +4 -5
- package/components/Data/stories/SpaceX.js +7 -8
- package/components/Data/stories/StarWars.js +8 -9
- package/components/Data/stories/Views.js +4 -5
- package/components/DataChart/DataChart.js +3 -4
- package/components/DataChart/Detail.js +4 -5
- package/components/DataChart/Legend.js +4 -5
- package/components/DataChart/Swatch.js +4 -5
- package/components/DataChart/XAxis.js +4 -5
- package/components/DataChart/XGuide.js +4 -5
- package/components/DataChart/YAxis.js +4 -5
- package/components/DataChart/YGuide.js +4 -5
- package/components/DataChart/propTypes.js +1 -2
- package/components/DataChart/stories/Axis.js +3 -5
- package/components/DataChart/stories/Detail.js +3 -5
- package/components/DataChart/stories/Everything.js +3 -5
- package/components/DataChart/stories/FourDimension.js +4 -5
- package/components/DataChart/stories/Guide.js +3 -5
- package/components/DataChart/stories/GuideDefault.js +4 -5
- package/components/DataChart/stories/Horizontal.js +3 -5
- package/components/DataChart/stories/Legend.js +3 -5
- package/components/DataChart/stories/MultipleTypes.js +4 -5
- package/components/DataChart/stories/Offset.js +4 -5
- package/components/DataChart/stories/Pad.js +3 -5
- package/components/DataChart/stories/Pattern.js +3 -5
- package/components/DataChart/stories/Placeholder.js +3 -5
- package/components/DataChart/stories/Prediction.js +5 -7
- package/components/DataChart/stories/Simple.js +3 -5
- package/components/DataChart/stories/StackedAreas.js +4 -5
- package/components/DataChart/stories/StackedBars.js +4 -5
- package/components/DataChart/stories/StackedLines.js +4 -5
- package/components/DataChart/utils.js +10 -19
- package/components/DataFilter/DataFilter.js +3 -4
- package/components/DataFilter/propTypes.js +1 -2
- package/components/DataFilter/stories/Simple.js +4 -5
- package/components/DataFilters/DataFilters.js +7 -8
- package/components/DataFilters/propTypes.js +1 -2
- package/components/DataFilters/stories/Drop.js +4 -5
- package/components/DataFilters/stories/Inline.js +4 -5
- package/components/DataFilters/stories/Layer.js +4 -5
- package/components/DataFilters/stories/Simple.js +4 -5
- package/components/DataSearch/DataSearch.js +3 -4
- package/components/DataSearch/propTypes.js +1 -2
- package/components/DataSearch/stories/Drop.js +4 -5
- package/components/DataSearch/stories/Responsive.js +4 -5
- package/components/DataSearch/stories/Simple.js +4 -5
- package/components/DataSort/DataSort.js +3 -4
- package/components/DataSort/propTypes.js +1 -2
- package/components/DataSort/stories/Drop.js +4 -5
- package/components/DataSort/stories/Simple.js +4 -5
- package/components/DataSummary/DataSummary.js +3 -4
- package/components/DataSummary/propTypes.js +1 -2
- package/components/DataSummary/stories/Simple.js +4 -5
- package/components/DataTable/Body.js +5 -6
- package/components/DataTable/Cell.js +3 -4
- package/components/DataTable/DataTable.js +8 -6
- package/components/DataTable/ExpanderCell.js +3 -4
- package/components/DataTable/Footer.js +3 -4
- package/components/DataTable/GroupedBody.js +4 -5
- package/components/DataTable/Header.js +8 -8
- package/components/DataTable/PlaceholderBody.js +4 -5
- package/components/DataTable/Resizer.js +3 -4
- package/components/DataTable/Searcher.js +3 -4
- package/components/DataTable/Sorter.js +3 -4
- package/components/DataTable/StyledDataTable.js +11 -19
- package/components/DataTable/buildState.js +13 -25
- package/components/DataTable/index.d.ts +1 -0
- package/components/DataTable/propTypes.js +2 -2
- package/components/DataTable/stories/AllowSelectAll.js +110 -0
- package/components/DataTable/stories/ColumnSize.js +4 -5
- package/components/DataTable/stories/Controlled.js +4 -5
- package/components/DataTable/stories/ControlledGrouped.js +6 -7
- package/components/DataTable/stories/CustomThemed/Custom.js +3 -5
- package/components/DataTable/stories/CustomThemed/Fill.js +3 -5
- package/components/DataTable/stories/Grouped.js +4 -5
- package/components/DataTable/stories/GroupedOnSelect.js +4 -5
- package/components/DataTable/stories/InfiniteScrollDataTable.js +4 -5
- package/components/DataTable/stories/MultiplePin.js +4 -5
- package/components/DataTable/stories/NoPrimary.js +4 -5
- package/components/DataTable/stories/OnUpdate.js +6 -7
- package/components/DataTable/stories/Placeholder.js +3 -5
- package/components/DataTable/stories/ResizableColumns.js +4 -5
- package/components/DataTable/stories/Served.js +4 -5
- package/components/DataTable/stories/Show.js +3 -5
- package/components/DataTable/stories/Simple.js +3 -5
- package/components/DataTable/stories/Sized.js +4 -5
- package/components/DataTable/stories/Sort.js +3 -5
- package/components/DataTable/stories/SpaceX.js +7 -8
- package/components/DataTable/stories/SpaceXUngrouped.js +7 -8
- package/components/DataTable/stories/Styled.js +4 -5
- package/components/DataTable/stories/Tunable.js +4 -5
- package/components/DataTable/stories/Units.js +4 -5
- package/components/DataTable/stories/VerticalAlign.js +4 -5
- package/components/DataTable/stories/data.js +8 -15
- package/components/DataTable/stories/rowDetails.js +4 -5
- package/components/DataTableColumns/DataTableColumns.js +3 -4
- package/components/DataTableColumns/propTypes.js +1 -2
- package/components/DataTableColumns/stories/Simple.js +4 -5
- package/components/DataTableGroupBy/DataTableGroupBy.js +3 -4
- package/components/DataTableGroupBy/propTypes.js +1 -2
- package/components/DataTableGroupBy/stories/Simple.js +4 -5
- package/components/DataView/DataView.js +3 -4
- package/components/DataView/propTypes.js +1 -2
- package/components/DataView/stories/Simple.js +4 -5
- package/components/DateInput/DateInput.js +4 -5
- package/components/DateInput/propTypes.js +1 -2
- package/components/DateInput/stories/Form.js +3 -5
- package/components/DateInput/stories/Format.js +3 -5
- package/components/DateInput/stories/FormatInline.js +5 -7
- package/components/DateInput/stories/Inline.js +3 -5
- package/components/DateInput/stories/Range.js +3 -5
- package/components/DateInput/stories/RangeFormat.js +3 -5
- package/components/DateInput/stories/ResetDate.js +4 -7
- package/components/DateInput/stories/Simple.js +3 -5
- package/components/DateInput/utils.js +7 -13
- package/components/Diagram/Diagram.js +3 -4
- package/components/Diagram/StyledDiagram.js +3 -4
- package/components/Diagram/propTypes.js +1 -2
- package/components/Diagram/stories/Animated.js +5 -7
- package/components/Diagram/stories/Progressing.js +6 -7
- package/components/Diagram/stories/data.js +2 -3
- package/components/Distribution/Distribution.js +1 -2
- package/components/Distribution/propTypes.js +1 -2
- package/components/Drop/Drop.js +3 -4
- package/components/Drop/DropContainer.js +59 -15
- package/components/Drop/StyledDrop.js +3 -4
- package/components/Drop/propTypes.js +1 -2
- package/components/Drop/stories/AllNotStretched.js +3 -5
- package/components/Drop/stories/CustomThemed/Lazy.js +5 -7
- package/components/Drop/stories/CustomThemed/Themed.js +5 -7
- package/components/Drop/stories/Inline.js +5 -7
- package/components/Drop/stories/Meter.js +5 -7
- package/components/Drop/stories/Multiple.js +5 -7
- package/components/Drop/stories/Overflow.js +5 -7
- package/components/Drop/stories/Plain.js +5 -7
- package/components/Drop/stories/Progressive.js +5 -7
- package/components/Drop/stories/Simple.js +5 -7
- package/components/Drop/stories/Styled.js +5 -7
- package/components/Drop/stories/TrapFocus.js +6 -7
- package/components/DropButton/DropButton.js +3 -4
- package/components/DropButton/propTypes.js +1 -2
- package/components/DropButton/stories/Menu.js +3 -5
- package/components/DropButton/stories/Simple.js +3 -5
- package/components/FileInput/FileInput.js +3 -4
- package/components/FileInput/StyledFileInput.js +1 -2
- package/components/FileInput/propTypes.js +1 -2
- package/components/FileInput/stories/ConfirmRemove.js +3 -5
- package/components/FileInput/stories/CustomThemed/Custom.js +3 -5
- package/components/FileInput/stories/MaxFileCount.js +3 -5
- package/components/FileInput/stories/MaxSize.js +3 -5
- package/components/FileInput/stories/Multiple.js +3 -5
- package/components/FileInput/stories/Simple.js +3 -5
- package/components/FileInput/utils/formatBytes.js +1 -2
- package/components/FocusedContainer.js +4 -5
- package/components/Footer/Footer.js +2 -3
- package/components/Footer/stories/DoubleFooter.js +4 -5
- package/components/Footer/stories/Simple.js +3 -5
- package/components/Footer/stories/Sitemap.js +3 -5
- package/components/Footer/stories/Social.js +3 -5
- package/components/Footer/stories/data.js +2 -4
- package/components/Form/Form.js +3 -4
- package/components/Form/FormContext.js +4 -5
- package/components/Form/propTypes.js +1 -2
- package/components/Form/stories/AggregateValidation.js +4 -5
- package/components/Form/stories/ArrayOfFormFields.js +5 -7
- package/components/Form/stories/Controlled.js +6 -7
- package/components/Form/stories/ControlledInput.js +6 -7
- package/components/Form/stories/ControlledInputLazy.js +6 -7
- package/components/Form/stories/ControlledLazy.js +6 -7
- package/components/Form/stories/CustomThemed/Custom.js +3 -5
- package/components/Form/stories/CustomThemed/FieldBorderPosition.js +6 -7
- package/components/Form/stories/CustomThemed/FieldCustomStates.js +5 -7
- package/components/Form/stories/CustomThemed/FieldSpacingOptions.js +3 -5
- package/components/Form/stories/CustomThemed/RequiredLabel.js +3 -5
- package/components/Form/stories/CustomThemed/Themed.js +3 -5
- package/components/Form/stories/DynamicFields.js +6 -7
- package/components/Form/stories/FieldStates.js +6 -7
- package/components/Form/stories/FieldWithChildren.js +4 -5
- package/components/Form/stories/FieldWithComponentProp.js +4 -5
- package/components/Form/stories/HelpAndError.js +4 -5
- package/components/Form/stories/SolicitedFeedback.js +6 -7
- package/components/Form/stories/TriggerValidationUsingFormField.js +3 -5
- package/components/Form/stories/Uncontrolled.js +4 -5
- package/components/Form/stories/UnsolicitedFeedback.js +6 -7
- package/components/Form/stories/ValidateOnBlur.js +4 -5
- package/components/Form/stories/ValidateOnChange.js +6 -7
- package/components/Form/stories/ValidateOnMount.js +6 -7
- package/components/FormField/FormField.js +3 -4
- package/components/FormField/propTypes.js +1 -2
- package/components/FormField/stories/Simple.js +5 -7
- package/components/Grid/Grid.js +3 -4
- package/components/Grid/StyledGrid.js +3 -4
- package/components/Grid/propTypes.js +1 -2
- package/components/Grid/stories/AreasPropAlternative.js +4 -5
- package/components/Grid/stories/Border.js +4 -5
- package/components/Grid/stories/CustomThemed/Responsive.js +3 -5
- package/components/Grid/stories/NColumn.js +4 -5
- package/components/Grid/stories/Percentages.js +4 -5
- package/components/Grid/stories/ResponsiveCards.js +6 -7
- package/components/Grommet/Grommet.js +3 -4
- package/components/Grommet/StyledGrommet.js +3 -4
- package/components/Grommet/index.d.ts +75 -0
- package/components/Grommet/propTypes.js +77 -3
- package/components/Grommet/stories/Background.js +3 -5
- package/components/Grommet/stories/Messages.js +3 -5
- package/components/Grommet/stories/Plain.js +3 -5
- package/components/Grommet/stories/Theme.js +3 -5
- package/components/Grommet/stories/ThemeMode.js +3 -5
- package/components/Grommet/stories/Vars.js +3 -5
- package/components/Header/Header.js +3 -4
- package/components/Header/propTypes.js +1 -2
- package/components/Header/stories/Responsive.js +3 -5
- package/components/Header/stories/Sticky.js +6 -7
- package/components/Heading/Heading.js +3 -4
- package/components/Heading/HeadingSkeleton.js +3 -4
- package/components/Heading/StyledHeading.js +3 -4
- package/components/Heading/propTypes.js +1 -2
- package/components/Heading/stories/All.js +3 -5
- package/components/Heading/stories/CustomThemed/CustomHeading.js +3 -5
- package/components/Heading/stories/CustomThemed/Extend.js +3 -5
- package/components/Image/Image.js +3 -4
- package/components/Image/StyledImage.js +3 -4
- package/components/Image/propTypes.js +1 -2
- package/components/Image/stories/Fallback.js +3 -5
- package/components/Image/stories/Fill.js +3 -5
- package/components/Image/stories/Fit.js +3 -5
- package/components/Image/stories/Opacity.js +3 -5
- package/components/Image/stories/Simple.js +3 -5
- package/components/InfiniteScroll/InfiniteScroll.js +3 -4
- package/components/InfiniteScroll/propTypes.js +1 -2
- package/components/InfiniteScroll/stories/Basics.js +3 -5
- package/components/InfiniteScroll/stories/ClassChildren.js +4 -5
- package/components/InfiniteScroll/stories/Grid.js +4 -5
- package/components/InfiniteScroll/stories/GridWithShow.js +4 -5
- package/components/InfiniteScroll/stories/HeightReplace.js +4 -5
- package/components/InfiniteScroll/stories/Marker.js +3 -5
- package/components/InfiniteScroll/stories/Replace.js +4 -5
- package/components/InfiniteScroll/stories/Show.js +3 -5
- package/components/InfiniteScroll/stories/ShowAfter.js +3 -5
- package/components/InfiniteScroll/stories/ShowBefore.js +3 -5
- package/components/InfiniteScroll/stories/Variable.js +4 -5
- package/components/Keyboard/Keyboard.js +1 -2
- package/components/Keyboard/propTypes.js +1 -2
- package/components/Keyboard/stories/OnDocument.js +3 -5
- package/components/Layer/Layer.js +3 -4
- package/components/Layer/LayerContainer.js +4 -5
- package/components/Layer/PortalContext.js +1 -2
- package/components/Layer/StyledLayer.js +6 -10
- package/components/Layer/propTypes.js +1 -2
- package/components/Layer/stories/Center.js +4 -5
- package/components/Layer/stories/Corner.js +4 -5
- package/components/Layer/stories/CustomThemed/Round.js +3 -5
- package/components/Layer/stories/Form.js +4 -5
- package/components/Layer/stories/Full.js +4 -5
- package/components/Layer/stories/Notification.js +4 -5
- package/components/Layer/stories/Plain.js +4 -5
- package/components/Layer/stories/RTL.js +4 -5
- package/components/Layer/stories/ScrollBody.js +4 -5
- package/components/Layer/stories/Target.js +4 -5
- package/components/List/List.js +3 -4
- package/components/List/propTypes.js +1 -2
- package/components/List/stories/Action.js +3 -5
- package/components/List/stories/Basic.js +3 -5
- package/components/List/stories/Children.js +3 -5
- package/components/List/stories/Disabled.js +3 -5
- package/components/List/stories/Order.js +5 -7
- package/components/List/stories/Paginated.js +3 -5
- package/components/List/stories/Pinned.js +5 -7
- package/components/List/stories/RenderedList.js +6 -5
- package/components/List/stories/Selection.js +3 -5
- package/components/List/stories/Show.js +3 -5
- package/components/List/stories/onClickItem.js +3 -5
- package/components/List/stories/secondaryKey.js +3 -5
- package/components/Main/Main.js +2 -3
- package/components/Markdown/Markdown.js +3 -4
- package/components/Markdown/propTypes.js +1 -2
- package/components/Markdown/stories/Override.js +4 -5
- package/components/Markdown/stories/Simple.js +3 -5
- package/components/MaskedInput/MaskedInput.js +3 -4
- package/components/MaskedInput/StyledMaskedInput.js +4 -7
- package/components/MaskedInput/propTypes.js +1 -2
- package/components/MaskedInput/stories/CustomBox.js +4 -5
- package/components/MaskedInput/stories/Date.js +4 -5
- package/components/MaskedInput/stories/DateRange.js +4 -5
- package/components/MaskedInput/stories/DateTimeDrop.js +4 -5
- package/components/MaskedInput/stories/Filtered.js +4 -5
- package/components/MaskedInput/stories/Form.js +4 -5
- package/components/MaskedInput/stories/IPV4Range.js +4 -5
- package/components/MaskedInput/stories/IPv4Address.js +4 -5
- package/components/MaskedInput/stories/Phone.js +4 -5
- package/components/MaskedInput/stories/SizeUnits.js +4 -5
- package/components/MaskedInput/stories/Time.js +4 -5
- package/components/MaskedInput/stories/URL.js +4 -5
- package/components/Menu/Menu.js +3 -4
- package/components/Menu/propTypes.js +1 -2
- package/components/Menu/stories/BottomControlButton.js +3 -5
- package/components/Menu/stories/Grouped.js +4 -5
- package/components/Menu/stories/ItemWithIcon.js +3 -5
- package/components/Menu/stories/Justify.js +3 -5
- package/components/Menu/stories/Reverse.js +3 -5
- package/components/Menu/stories/Simple.js +3 -5
- package/components/Meter/Bar.js +3 -4
- package/components/Meter/Circle.js +3 -4
- package/components/Meter/Meter.js +3 -4
- package/components/Meter/StyledMeter.js +3 -4
- package/components/Meter/propTypes.js +1 -2
- package/components/Meter/stories/Bar.js +3 -5
- package/components/Meter/stories/Circle.js +5 -7
- package/components/Meter/stories/Labelled.js +3 -5
- package/components/Meter/stories/Pie.js +3 -5
- package/components/Meter/stories/ReverseBar.js +3 -5
- package/components/Meter/stories/SemiCircle.js +3 -5
- package/components/Meter/stories/VerticalBar.js +3 -5
- package/components/Meter/stories/VerticalBarMultiple.js +6 -7
- package/components/Meter/utils.js +3 -5
- package/components/NameValueList/NameValueList.js +3 -4
- package/components/NameValueList/NameValueListContext.js +1 -2
- package/components/NameValueList/propTypes.js +1 -2
- package/components/NameValueList/stories/Align.js +3 -5
- package/components/NameValueList/stories/CustomName.js +3 -5
- package/components/NameValueList/stories/CustomValue.js +3 -5
- package/components/NameValueList/stories/Layout.js +3 -5
- package/components/NameValueList/stories/PairProps.js +3 -5
- package/components/NameValueList/stories/Simple.js +3 -5
- package/components/NameValueList/stories/Width.js +3 -5
- package/components/NameValueList/stories/data.js +5 -9
- package/components/NameValuePair/NameValuePair.js +4 -5
- package/components/NameValuePair/propTypes.js +1 -2
- package/components/Nav/Nav.js +2 -3
- package/components/Nav/stories/Collapsable.js +3 -5
- package/components/Nav/stories/CustomThemed/CustomAnchor.js +3 -5
- package/components/Nav/stories/CustomThemed/JustifySidebar.js +5 -7
- package/components/Nav/stories/OnHeader.js +3 -5
- package/components/Nav/stories/Sidebar.js +5 -7
- package/components/Nav/stories/Simple.js +3 -5
- package/components/Notification/Notification.js +3 -4
- package/components/Notification/propTypes.js +1 -2
- package/components/Notification/stories/Global.js +5 -7
- package/components/Notification/stories/Status.js +3 -5
- package/components/Notification/stories/Title.js +5 -7
- package/components/Notification/stories/TitleAndMessage.js +5 -7
- package/components/Page/Page.js +3 -4
- package/components/Page/PageContext.js +1 -2
- package/components/Page/propTypes.js +1 -2
- package/components/Page/stories/Background.js +3 -5
- package/components/Page/stories/ContentBackground.js +4 -5
- package/components/Page/stories/CustomThemed/LeftColumn.js +3 -5
- package/components/Page/stories/GlobalHeader.js +4 -5
- package/components/Page/stories/MultipleBackgrounds.js +4 -5
- package/components/Page/stories/MultipleContent.js +4 -5
- package/components/Page/stories/PageNotificaton.js +5 -7
- package/components/Page/stories/Simple.js +3 -5
- package/components/PageContent/PageContent.js +3 -4
- package/components/PageContent/propTypes.js +1 -2
- package/components/PageHeader/PageHeader.js +8 -6
- package/components/PageHeader/index.d.ts +1 -0
- package/components/PageHeader/propTypes.js +2 -2
- package/components/PageHeader/stories/Custom.js +3 -5
- package/components/PageHeader/stories/Level.js +34 -0
- package/components/PageHeader/stories/MultipleActions.js +6 -7
- package/components/PageHeader/stories/Responsive.js +3 -5
- package/components/PageHeader/stories/Simple.js +3 -5
- package/components/PageHeader/stories/Size.js +3 -5
- package/components/Pagination/PageControl.js +4 -5
- package/components/Pagination/Pagination.js +3 -4
- package/components/Pagination/StyledPageControl.js +4 -7
- package/components/Pagination/propTypes.js +1 -2
- package/components/Pagination/stories/Grid.js +6 -7
- package/components/Pagination/stories/NumberEdgePages.js +4 -5
- package/components/Pagination/stories/NumberMiddlePages.js +4 -5
- package/components/Pagination/stories/Simple.js +3 -5
- package/components/Pagination/stories/Size.js +3 -5
- package/components/Paragraph/Paragraph.js +3 -4
- package/components/Paragraph/ParagraphSkeleton.js +3 -4
- package/components/Paragraph/StyledParagraph.js +3 -4
- package/components/Paragraph/propTypes.js +1 -2
- package/components/Paragraph/stories/All.js +3 -5
- package/components/Paragraph/stories/CustomThemed/Themed.js +3 -5
- package/components/Paragraph/stories/MaxLines.js +3 -5
- package/components/RadioButton/RadioButton.js +10 -4
- package/components/RadioButton/StyledRadioButton.js +9 -16
- package/components/RadioButton/propTypes.js +1 -2
- package/components/RadioButton/stories/Children.js +3 -5
- package/components/RadioButton/stories/CustomThemed/Theme.js +3 -5
- package/components/RadioButton/stories/Disabled.js +3 -5
- package/components/RadioButton/stories/Simple.js +3 -5
- package/components/RadioButtonGroup/RadioButtonGroup.js +3 -4
- package/components/RadioButtonGroup/propTypes.js +1 -2
- package/components/RadioButtonGroup/stories/Children.js +5 -7
- package/components/RadioButtonGroup/stories/CustomThemed/CustomTheme.js +5 -7
- package/components/RadioButtonGroup/stories/Disabled.js +5 -7
- package/components/RangeInput/RangeInput.js +3 -4
- package/components/RangeInput/StyledRangeInput.js +4 -4
- package/components/RangeInput/propTypes.js +1 -2
- package/components/RangeInput/stories/CustomThemed/Bounds.js +3 -5
- package/components/RangeInput/stories/CustomThemed/Disabled.js +3 -5
- package/components/RangeInput/stories/CustomThemed/TrackColor.js +3 -5
- package/components/RangeInput/stories/SimpleRange.js +3 -5
- package/components/RangeSelector/EdgeControl.js +3 -4
- package/components/RangeSelector/RangeSelector.js +3 -4
- package/components/RangeSelector/index.d.ts +1 -1
- package/components/RangeSelector/propTypes.js +1 -2
- package/components/RangeSelector/stories/Basics.js +5 -7
- package/components/RangeSelector/stories/CustomThemed/Custom.js +5 -7
- package/components/RangeSelector/stories/CustomThemed/CustomEdgeControl.js +5 -7
- package/components/RangeSelector/stories/Label.js +5 -7
- package/components/RangeSelector/stories/Simple.js +5 -7
- package/components/RangeSelector/stories/Step.js +5 -7
- package/components/RangeSelector/stories/Thin.js +6 -7
- package/components/RangeSelector/stories/Vertical.js +5 -7
- package/components/RoutedAnchor/RoutedAnchor.js +3 -4
- package/components/RoutedButton/RoutedButton.js +3 -4
- package/components/Select/DefaultSelectTextInput.js +4 -5
- package/components/Select/EmptySearchOption.js +2 -3
- package/components/Select/Select.js +3 -4
- package/components/Select/SelectContainer.js +5 -6
- package/components/Select/StyledSelect.js +7 -13
- package/components/Select/propTypes.js +2 -4
- package/components/Select/stories/ChildrenRender.js +6 -7
- package/components/Select/stories/Clear.js +6 -7
- package/components/Select/stories/Controlled.js +6 -7
- package/components/Select/stories/CustomThemed/CustomSearch.js +5 -7
- package/components/Select/stories/Disabled.js +6 -7
- package/components/Select/stories/InsideFormField.js +6 -7
- package/components/Select/stories/LazyLoadingOptions.js +4 -5
- package/components/Select/stories/ManyOptions.js +4 -5
- package/components/Select/stories/Multiple.js +6 -7
- package/components/Select/stories/ObjectOptions.js +6 -7
- package/components/Select/stories/Search.js +6 -7
- package/components/Select/stories/Simple.js +6 -7
- package/components/Select/stories/Uncontrolled.js +4 -5
- package/components/Select/stories/ValueLabel.js +6 -7
- package/components/Select/stories/components/SearchBorderBox.js +4 -5
- package/components/Select/stories/components/SearchInput.js +4 -5
- package/components/Select/stories/theme.js +2 -3
- package/components/Select/utils.js +12 -23
- package/components/SelectMultiple/SelectMultiple.js +3 -4
- package/components/SelectMultiple/SelectMultipleContainer.js +5 -6
- package/components/SelectMultiple/SelectMultipleValue.js +4 -5
- package/components/SelectMultiple/SelectionSummary.js +4 -5
- package/components/SelectMultiple/propTypes.js +1 -2
- package/components/SelectMultiple/stories/Default.js +6 -7
- package/components/SelectMultiple/stories/Disabled.js +6 -7
- package/components/SelectMultiple/stories/FormField.js +6 -7
- package/components/SelectMultiple/stories/Help.js +6 -7
- package/components/SelectMultiple/stories/Limited.js +6 -7
- package/components/SelectMultiple/stories/LongList.js +4 -5
- package/components/SelectMultiple/stories/ObjectOptions.js +6 -7
- package/components/SelectMultiple/stories/ShowSelectedInline.js +6 -7
- package/components/Sidebar/Sidebar.js +1 -2
- package/components/Sidebar/propTypes.js +1 -2
- package/components/Sidebar/stories/Labels.js +4 -5
- package/components/Skeleton/Skeleton.js +3 -4
- package/components/Skeleton/SkeletonContext.js +5 -7
- package/components/Skeleton/StyledSkeleton.js +2 -3
- package/components/Skeleton/propTypes.js +1 -2
- package/components/Skeleton/stories/CustomThemed/Custom.js +5 -7
- package/components/Skeleton/stories/GridContainer.js +5 -7
- package/components/Skeleton/stories/Group.js +5 -7
- package/components/Skeleton/stories/Individual.js +5 -7
- package/components/Skeleton/stories/Simple.js +3 -5
- package/components/SkipLink/SkipLink.js +4 -5
- package/components/SkipLinkTarget/SkipLinkTarget.js +2 -3
- package/components/SkipLinks/SkipLinks.js +3 -4
- package/components/SkipLinks/propTypes.js +1 -2
- package/components/SkipLinks/stories/CustomThemed/Themed.js +3 -5
- package/components/SkipLinks/stories/Simple.js +4 -5
- package/components/Spinner/Spinner.js +3 -4
- package/components/Spinner/propTypes.js +1 -2
- package/components/Spinner/stories/Animation.js +5 -7
- package/components/Spinner/stories/Announced.js +5 -7
- package/components/Spinner/stories/Border.js +3 -5
- package/components/Spinner/stories/ChildrenSpinner.js +3 -5
- package/components/Spinner/stories/Color.js +3 -5
- package/components/Spinner/stories/Modal.js +3 -5
- package/components/Spinner/stories/Round.js +3 -5
- package/components/Spinner/stories/Simple.js +3 -5
- package/components/Spinner/stories/Size.js +3 -5
- package/components/Stack/Stack.js +3 -4
- package/components/Stack/StyledStack.js +4 -6
- package/components/Stack/propTypes.js +1 -2
- package/components/Stack/stories/Fill.js +4 -5
- package/components/Stack/stories/Simple.js +3 -5
- package/components/StarRating/StarRating.js +3 -4
- package/components/StarRating/stories/simple.js +3 -5
- package/components/Tab/StyledTab.js +3 -4
- package/components/Tab/Tab.js +3 -4
- package/components/Tab/propTypes.js +1 -2
- package/components/Table/StyledTable.js +9 -16
- package/components/Table/Table.js +3 -4
- package/components/Table/TableContext.js +1 -2
- package/components/Table/propTypes.js +1 -2
- package/components/Table/stories/CustomThemed/Custom.js +3 -5
- package/components/Table/stories/Default.js +3 -5
- package/components/Table/stories/InfiniteScrollInTable.js +6 -7
- package/components/Table/stories/MeterInTable.js +4 -5
- package/components/Table/stories/data.js +3 -5
- package/components/TableBody/TableBody.js +3 -4
- package/components/TableCell/TableCell.js +4 -6
- package/components/TableCell/propTypes.js +1 -2
- package/components/TableFooter/TableFooter.js +3 -4
- package/components/TableHeader/TableHeader.js +3 -4
- package/components/TableRow/TableRow.js +3 -4
- package/components/Tabs/StyledTabs.js +5 -8
- package/components/Tabs/Tabs.js +3 -4
- package/components/Tabs/TabsContext.js +1 -2
- package/components/Tabs/propTypes.js +1 -2
- package/components/Tabs/stories/CustomThemed/Custom.js +3 -5
- package/components/Tabs/stories/CustomThemed/States.js +5 -7
- package/components/Tabs/stories/Responsive.js +5 -7
- package/components/Tabs/stories/Rich.js +4 -5
- package/components/Tabs/stories/Scrollable.js +3 -5
- package/components/Tag/StyledTag.js +2 -4
- package/components/Tag/Tag.js +6 -6
- package/components/Tag/propTypes.js +1 -2
- package/components/Tag/stories/OnClick.js +3 -5
- package/components/Tag/stories/OnRemove.js +3 -5
- package/components/Tag/stories/Simple.js +3 -5
- package/components/Tag/stories/Size.js +3 -5
- package/components/Text/StyledText.js +3 -4
- package/components/Text/Text.js +3 -4
- package/components/Text/TextContext.js +1 -2
- package/components/Text/TextSkeleton.js +3 -4
- package/components/Text/propTypes.js +1 -2
- package/components/Text/stories/All.js +3 -5
- package/components/Text/stories/Tip.js +3 -5
- package/components/Text/stories/WordBreak.js +3 -5
- package/components/TextArea/StyledTextArea.js +3 -4
- package/components/TextArea/TextArea.js +3 -4
- package/components/TextArea/propTypes.js +1 -2
- package/components/TextArea/stories/CustomThemed/Themed.js +5 -7
- package/components/TextArea/stories/InsideFormField.js +6 -7
- package/components/TextArea/stories/NonResizable.js +5 -7
- package/components/TextArea/stories/Simple.js +5 -7
- package/components/TextInput/StyledTextInput.js +7 -12
- package/components/TextInput/TextInput.js +3 -4
- package/components/TextInput/propTypes.js +1 -2
- package/components/TextInput/stories/CustomThemed/Themed.js +3 -5
- package/components/TextInput/stories/DefaultSuggestion.js +4 -5
- package/components/TextInput/stories/Icon.js +3 -5
- package/components/TextInput/stories/InsideFormField.js +6 -7
- package/components/TextInput/stories/OnSelect.js +4 -5
- package/components/TextInput/stories/Password.js +3 -5
- package/components/TextInput/stories/Simple.js +4 -5
- package/components/TextInput/stories/StyledPlaceholder.js +4 -5
- package/components/TextInput/stories/Suggestions.js +4 -5
- package/components/TextInput/stories/Uncontrolled.js +4 -5
- package/components/TextInput/stories/WithTags.js +4 -5
- package/components/ThumbsRating/ThumbsRating.js +3 -4
- package/components/ThumbsRating/stories/simple.js +3 -5
- package/components/Tip/Tip.js +15 -6
- package/components/Tip/propTypes.js +1 -2
- package/components/Tip/stories/Caret.js +4 -5
- package/components/Tip/stories/CustomThemed/ResponsiveTip.js +3 -5
- package/components/Tip/stories/CustomThemed/SidebarTip.js +3 -5
- package/components/Tip/stories/HeaderActions.js +6 -7
- package/components/Tip/stories/InfoTip.js +4 -5
- package/components/Toolbar/Toolbar.js +3 -4
- package/components/Toolbar/propTypes.js +1 -2
- package/components/Toolbar/stories/Simple.js +4 -5
- package/components/Video/StyledVideo.js +6 -10
- package/components/Video/Video.js +4 -5
- package/components/Video/propTypes.js +1 -2
- package/components/WorldMap/StyledWorldMap.js +1 -2
- package/components/WorldMap/WorldMap.js +3 -4
- package/components/WorldMap/propTypes.js +1 -2
- package/components/WorldMap/stories/Color.js +3 -5
- package/components/WorldMap/stories/Continents.js +3 -5
- package/components/WorldMap/stories/Places.js +3 -5
- package/components/WorldMap/stories/SelectPlace.js +3 -5
- package/components/WorldMap/stories/Simple.js +3 -5
- package/contexts/AnalyticsContext/AnalyticsContext.js +6 -9
- package/contexts/AnnounceContext/AnnounceContext.js +1 -2
- package/contexts/AnnounceContext/propTypes.js +1 -2
- package/contexts/AnnounceContext/stories/Assertive.js +3 -5
- package/contexts/AnnounceContext/stories/Polite.js +5 -7
- package/contexts/ContainerTargetContext/ContainerTargetContext.js +1 -2
- package/contexts/DataContext.js +2 -3
- package/contexts/MessageContext/MessageContext.js +3 -5
- package/contexts/OptionsContext.js +1 -2
- package/contexts/ResponsiveContext/ResponsiveContext.js +1 -2
- package/contexts/ResponsiveContext/propTypes.js +1 -2
- package/contexts/ResponsiveContext/stories/CustomBreakpoints.js +3 -5
- package/contexts/ResponsiveContext/stories/ResponsiveGrid.js +3 -5
- package/contexts/RootsContext.js +1 -2
- package/contexts/ThemeContext/propTypes.js +1 -2
- package/contexts/ThemeContext/stories/ExternalComponent.js +3 -5
- package/contexts/ThemeContext/stories/ThemeContextExtend.js +5 -7
- package/default-props.js +3 -5
- package/es6/components/Box/index.d.ts +1 -1
- package/es6/components/Box/stories/Round.js +1 -1
- package/es6/components/Box/stories/Simple.js +4 -3
- package/es6/components/Chart/index.d.ts +4 -4
- package/es6/components/Data/stories/Infinite.js +1 -1
- package/es6/components/Data/stories/SpaceX.js +1 -1
- package/es6/components/Data/stories/StarWars.js +2 -2
- package/es6/components/DataFilters/DataFilters.js +4 -4
- package/es6/components/DataTable/Body.js +1 -1
- package/es6/components/DataTable/DataTable.js +5 -2
- package/es6/components/DataTable/Header.js +5 -4
- package/es6/components/DataTable/index.d.ts +1 -0
- package/es6/components/DataTable/propTypes.js +1 -0
- package/es6/components/DataTable/stories/AllowSelectAll.js +105 -0
- package/es6/components/DataTable/stories/SpaceX.js +1 -1
- package/es6/components/DataTable/stories/SpaceXUngrouped.js +1 -1
- package/es6/components/DateInput/DateInput.js +1 -1
- package/es6/components/Drop/DropContainer.js +55 -10
- package/es6/components/Grommet/index.d.ts +75 -0
- package/es6/components/Grommet/propTypes.js +76 -1
- package/es6/components/List/stories/RenderedList.js +3 -0
- package/es6/components/PageHeader/PageHeader.js +5 -2
- package/es6/components/PageHeader/index.d.ts +1 -0
- package/es6/components/PageHeader/propTypes.js +1 -0
- package/es6/components/PageHeader/stories/Level.js +29 -0
- package/es6/components/RadioButton/RadioButton.js +7 -0
- package/es6/components/RadioButton/StyledRadioButton.js +1 -2
- package/es6/components/RangeSelector/index.d.ts +1 -1
- package/es6/components/Select/SelectContainer.js +1 -1
- package/es6/components/SelectMultiple/SelectMultipleContainer.js +1 -1
- package/es6/components/Tag/Tag.js +3 -2
- package/es6/components/Tip/Tip.js +12 -2
- package/es6/components/Video/Video.js +1 -1
- package/es6/contexts/MessageContext/MessageContext.js +1 -1
- package/es6/languages/default.json +5 -5
- package/es6/themes/base.d.ts +6 -0
- package/es6/themes/base.js +6 -0
- package/es6/utils/index.d.ts +5 -5
- package/grommet.min.js +1 -1
- package/grommet.min.js.map +1 -1
- package/languages/default.json +5 -5
- package/package.json +40 -39
- package/themes/base.d.ts +6 -0
- package/themes/base.js +8 -4
- package/themes/dark.js +2 -3
- package/themes/grommet.js +2 -3
- package/themes/hacktoberfest2022.js +2 -3
- package/tools/release-styled-components-beta-stable.js +1 -0
- package/utils/DOM.js +16 -31
- package/utils/PortalContext.js +1 -2
- package/utils/animation.js +5 -9
- package/utils/background.js +8 -15
- package/utils/border.js +3 -5
- package/utils/colors.js +6 -11
- package/utils/dates.js +2 -3
- package/utils/general-prop-types.js +20 -40
- package/utils/graphics.js +5 -9
- package/utils/icon.js +2 -3
- package/utils/index.d.ts +5 -5
- package/utils/mixins.js +7 -13
- package/utils/object.js +5 -9
- package/utils/pagination.js +3 -5
- package/utils/refs.js +2 -3
- package/utils/responsive.js +4 -7
- package/utils/router.js +2 -3
- package/utils/styles.js +22 -43
- package/utils/use-isomorphic-layout-effect.js +2 -4
- package/utils/use-keyboard.js +2 -4
|
@@ -3,15 +3,13 @@
|
|
|
3
3
|
exports.__esModule = true;
|
|
4
4
|
exports.useAnalytics = exports.AnalyticsProvider = exports.AnalyticsContext = void 0;
|
|
5
5
|
var _react = _interopRequireWildcard(require("react"));
|
|
6
|
-
function _getRequireWildcardCache(
|
|
7
|
-
function _interopRequireWildcard(
|
|
8
|
-
var AnalyticsContext = /*#__PURE__*/_react["default"].createContext(function () {});
|
|
9
|
-
exports.
|
|
10
|
-
var useAnalytics = function useAnalytics() {
|
|
6
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
7
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { "default": e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n["default"] = e, t && t.set(e, n), n; }
|
|
8
|
+
var AnalyticsContext = exports.AnalyticsContext = /*#__PURE__*/_react["default"].createContext(function () {});
|
|
9
|
+
var useAnalytics = exports.useAnalytics = function useAnalytics() {
|
|
11
10
|
return (0, _react.useContext)(AnalyticsContext);
|
|
12
11
|
};
|
|
13
|
-
exports.
|
|
14
|
-
var AnalyticsProvider = function AnalyticsProvider(_ref) {
|
|
12
|
+
var AnalyticsProvider = exports.AnalyticsProvider = function AnalyticsProvider(_ref) {
|
|
15
13
|
var onAnalytics = _ref.onAnalytics,
|
|
16
14
|
children = _ref.children;
|
|
17
15
|
var lastUrlRef = (0, _react.useRef)();
|
|
@@ -47,5 +45,4 @@ var AnalyticsProvider = function AnalyticsProvider(_ref) {
|
|
|
47
45
|
return /*#__PURE__*/_react["default"].createElement(AnalyticsContext.Provider, {
|
|
48
46
|
value: sendAnalytics
|
|
49
47
|
}, children);
|
|
50
|
-
};
|
|
51
|
-
exports.AnalyticsProvider = AnalyticsProvider;
|
|
48
|
+
};
|
|
@@ -15,7 +15,7 @@ var createAnnouncer = function createAnnouncer() {
|
|
|
15
15
|
document.body.insertBefore(announcer, document.body.firstChild);
|
|
16
16
|
return announcer;
|
|
17
17
|
};
|
|
18
|
-
var AnnounceContext = /*#__PURE__*/_react["default"].createContext(function (message, mode, timeout) {
|
|
18
|
+
var AnnounceContext = exports.AnnounceContext = /*#__PURE__*/_react["default"].createContext(function (message, mode, timeout) {
|
|
19
19
|
if (mode === void 0) {
|
|
20
20
|
mode = 'polite';
|
|
21
21
|
}
|
|
@@ -32,5 +32,4 @@ var AnnounceContext = /*#__PURE__*/_react["default"].createContext(function (mes
|
|
|
32
32
|
announcer.innerHTML = '';
|
|
33
33
|
}, timeout);
|
|
34
34
|
});
|
|
35
|
-
exports.AnnounceContext = AnnounceContext;
|
|
36
35
|
AnnounceContext.propTypes = _propTypes.AnnounceContextPropTypes;
|
|
@@ -10,5 +10,4 @@ if (process.env.NODE_ENV !== 'production') {
|
|
|
10
10
|
children: _propTypes["default"].func
|
|
11
11
|
};
|
|
12
12
|
}
|
|
13
|
-
var AnnounceContextPropTypes = PropType;
|
|
14
|
-
exports.AnnounceContextPropTypes = AnnounceContextPropTypes;
|
|
13
|
+
var AnnounceContextPropTypes = exports.AnnounceContextPropTypes = PropType;
|
|
@@ -49,15 +49,13 @@ var AnnounceContextComponent = function AnnounceContextComponent(props) {
|
|
|
49
49
|
}, props));
|
|
50
50
|
})));
|
|
51
51
|
};
|
|
52
|
-
var Assertive = function Assertive() {
|
|
52
|
+
var Assertive = exports.Assertive = function Assertive() {
|
|
53
53
|
return /*#__PURE__*/_react["default"].createElement(AnnounceContextComponent, {
|
|
54
54
|
message: "Turn on Accessibility feature to listen to this announcement. This will soon disappear",
|
|
55
55
|
mode: "assertive",
|
|
56
56
|
role: "alert"
|
|
57
57
|
});
|
|
58
58
|
};
|
|
59
|
-
exports
|
|
60
|
-
var _default = {
|
|
59
|
+
var _default = exports["default"] = {
|
|
61
60
|
title: 'Utilities/AnnounceContext/Assertive'
|
|
62
|
-
};
|
|
63
|
-
exports["default"] = _default;
|
|
61
|
+
};
|
|
@@ -6,8 +6,8 @@ var _react = _interopRequireWildcard(require("react"));
|
|
|
6
6
|
var _grommetIcons = require("grommet-icons");
|
|
7
7
|
var _themes = require("grommet/themes");
|
|
8
8
|
var _grommet = require("grommet");
|
|
9
|
-
function _getRequireWildcardCache(
|
|
10
|
-
function _interopRequireWildcard(
|
|
9
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
10
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { "default": e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n["default"] = e, t && t.set(e, n), n; }
|
|
11
11
|
// used only for the grommet's font
|
|
12
12
|
|
|
13
13
|
var message = "Thank you for clicking the Announce Button,\nthis announcement is being broadcast on the Button's click.";
|
|
@@ -32,7 +32,7 @@ var PageContent = function PageContent(_ref) {
|
|
|
32
32
|
}
|
|
33
33
|
}));
|
|
34
34
|
};
|
|
35
|
-
var Polite = function Polite() {
|
|
35
|
+
var Polite = exports.Polite = function Polite() {
|
|
36
36
|
return /*#__PURE__*/_react["default"].createElement(_grommet.Grommet, {
|
|
37
37
|
theme: _themes.grommet,
|
|
38
38
|
full: true
|
|
@@ -45,8 +45,6 @@ var Polite = function Polite() {
|
|
|
45
45
|
role: "log"
|
|
46
46
|
})));
|
|
47
47
|
};
|
|
48
|
-
exports
|
|
49
|
-
var _default = {
|
|
48
|
+
var _default = exports["default"] = {
|
|
50
49
|
title: 'Utilities/AnnounceContext/Polite'
|
|
51
|
-
};
|
|
52
|
-
exports["default"] = _default;
|
|
50
|
+
};
|
|
@@ -4,5 +4,4 @@ exports.__esModule = true;
|
|
|
4
4
|
exports.ContainerTargetContext = void 0;
|
|
5
5
|
var _react = _interopRequireDefault(require("react"));
|
|
6
6
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
7
|
-
var ContainerTargetContext = /*#__PURE__*/_react["default"].createContext(typeof document === 'object' ? document.body : undefined);
|
|
8
|
-
exports.ContainerTargetContext = ContainerTargetContext;
|
|
7
|
+
var ContainerTargetContext = exports.ContainerTargetContext = /*#__PURE__*/_react["default"].createContext(typeof document === 'object' ? document.body : undefined);
|
package/contexts/DataContext.js
CHANGED
|
@@ -4,8 +4,7 @@ exports.__esModule = true;
|
|
|
4
4
|
exports.DataContext = void 0;
|
|
5
5
|
var _react = _interopRequireDefault(require("react"));
|
|
6
6
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
7
|
-
var DataContext = /*#__PURE__*/_react["default"].createContext({
|
|
7
|
+
var DataContext = exports.DataContext = /*#__PURE__*/_react["default"].createContext({
|
|
8
8
|
data: [],
|
|
9
9
|
addToolbarKey: function addToolbarKey() {}
|
|
10
|
-
});
|
|
11
|
-
exports.DataContext = DataContext;
|
|
10
|
+
});
|
|
@@ -13,7 +13,7 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "d
|
|
|
13
13
|
// positional variables in the message text.
|
|
14
14
|
// defaultMessage: (optional) default message to use if
|
|
15
15
|
// the message isn't found elsewhere.
|
|
16
|
-
var _format = function format(options, messages) {
|
|
16
|
+
var _format = exports.format = function format(options, messages) {
|
|
17
17
|
var _options$id;
|
|
18
18
|
// Message id's are hierarchical. For the component-specific
|
|
19
19
|
// message objects passed as options.messages, just use the last
|
|
@@ -41,19 +41,17 @@ var _format = function format(options, messages) {
|
|
|
41
41
|
var values = options.values;
|
|
42
42
|
var newMessage = message;
|
|
43
43
|
var tokens = message == null ? void 0 : message.match(/\{(.+?)\}/g);
|
|
44
|
-
tokens == null
|
|
44
|
+
tokens == null || tokens.forEach(function (token) {
|
|
45
45
|
var names = token.substr(1, token.length - 2);
|
|
46
46
|
var value = values[names];
|
|
47
47
|
newMessage = newMessage.replace(token, value);
|
|
48
48
|
});
|
|
49
49
|
return values ? newMessage : message;
|
|
50
50
|
};
|
|
51
|
-
exports.format = _format;
|
|
52
51
|
var defaultValue = {
|
|
53
52
|
messages: _default["default"],
|
|
54
53
|
format: function format(options) {
|
|
55
54
|
return _format(options, _default["default"]);
|
|
56
55
|
}
|
|
57
56
|
};
|
|
58
|
-
var MessageContext = /*#__PURE__*/_react["default"].createContext(defaultValue);
|
|
59
|
-
exports.MessageContext = MessageContext;
|
|
57
|
+
var MessageContext = exports.MessageContext = /*#__PURE__*/_react["default"].createContext(defaultValue);
|
|
@@ -4,5 +4,4 @@ exports.__esModule = true;
|
|
|
4
4
|
exports.OptionsContext = void 0;
|
|
5
5
|
var _react = _interopRequireDefault(require("react"));
|
|
6
6
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
7
|
-
var OptionsContext = /*#__PURE__*/_react["default"].createContext({});
|
|
8
|
-
exports.OptionsContext = OptionsContext;
|
|
7
|
+
var OptionsContext = exports.OptionsContext = /*#__PURE__*/_react["default"].createContext({});
|
|
@@ -5,6 +5,5 @@ exports.ResponsiveContext = void 0;
|
|
|
5
5
|
var _react = _interopRequireDefault(require("react"));
|
|
6
6
|
var _propTypes = require("./propTypes");
|
|
7
7
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
8
|
-
var ResponsiveContext = /*#__PURE__*/_react["default"].createContext(undefined);
|
|
9
|
-
exports.ResponsiveContext = ResponsiveContext;
|
|
8
|
+
var ResponsiveContext = exports.ResponsiveContext = /*#__PURE__*/_react["default"].createContext(undefined);
|
|
10
9
|
ResponsiveContext.propTypes = _propTypes.ResponsiveContextPropTypes;
|
|
@@ -10,5 +10,4 @@ if (process.env.NODE_ENV !== 'production') {
|
|
|
10
10
|
children: _propTypes["default"].func
|
|
11
11
|
};
|
|
12
12
|
}
|
|
13
|
-
var ResponsiveContextPropTypes = PropType;
|
|
14
|
-
exports.ResponsiveContextPropTypes = ResponsiveContextPropTypes;
|
|
13
|
+
var ResponsiveContextPropTypes = exports.ResponsiveContextPropTypes = PropType;
|
|
@@ -50,7 +50,7 @@ var customBreakpoints = {
|
|
|
50
50
|
}
|
|
51
51
|
}
|
|
52
52
|
};
|
|
53
|
-
var CustomBreakpoints = function CustomBreakpoints() {
|
|
53
|
+
var CustomBreakpoints = exports.CustomBreakpoints = function CustomBreakpoints() {
|
|
54
54
|
return /*#__PURE__*/_react["default"].createElement(_grommet.Grommet, {
|
|
55
55
|
theme: customBreakpoints,
|
|
56
56
|
full: true
|
|
@@ -61,9 +61,7 @@ var CustomBreakpoints = function CustomBreakpoints() {
|
|
|
61
61
|
}, /*#__PURE__*/_react["default"].createElement(_grommet.Heading, null, "Hi, I'm " + size + ", resize me!"));
|
|
62
62
|
}));
|
|
63
63
|
};
|
|
64
|
-
exports.CustomBreakpoints = CustomBreakpoints;
|
|
65
64
|
CustomBreakpoints.storyName = 'Custom breakpoints';
|
|
66
|
-
var _default = {
|
|
65
|
+
var _default = exports["default"] = {
|
|
67
66
|
title: 'Utilities/ResponsiveContext/Custom breakpoints'
|
|
68
|
-
};
|
|
69
|
-
exports["default"] = _default;
|
|
67
|
+
};
|
|
@@ -35,7 +35,7 @@ var ResponsiveGrid = function ResponsiveGrid(_ref) {
|
|
|
35
35
|
areas: areas[size]
|
|
36
36
|
}, props), children);
|
|
37
37
|
};
|
|
38
|
-
var ResponsiveGridExample = function ResponsiveGridExample() {
|
|
38
|
+
var ResponsiveGridExample = exports.ResponsiveGridExample = function ResponsiveGridExample() {
|
|
39
39
|
return /*#__PURE__*/_react["default"].createElement(_grommet.Grommet, {
|
|
40
40
|
theme: customBreakpoints,
|
|
41
41
|
full: true
|
|
@@ -126,9 +126,7 @@ var ResponsiveGridExample = function ResponsiveGridExample() {
|
|
|
126
126
|
background: "dark-3"
|
|
127
127
|
})), /*#__PURE__*/_react["default"].createElement(_grommet.Paragraph, null, "Below a certain threshold, Columns 1 & 2 switch to 50% and Column 3 moves down to a new spot in the grid."));
|
|
128
128
|
};
|
|
129
|
-
exports.ResponsiveGridExample = ResponsiveGridExample;
|
|
130
129
|
ResponsiveGridExample.storyName = 'Responsive grid';
|
|
131
|
-
var _default = {
|
|
130
|
+
var _default = exports["default"] = {
|
|
132
131
|
title: 'Utilities/ResponsiveContext/Responsive grid'
|
|
133
|
-
};
|
|
134
|
-
exports["default"] = _default;
|
|
132
|
+
};
|
package/contexts/RootsContext.js
CHANGED
|
@@ -7,5 +7,4 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "d
|
|
|
7
7
|
// When toggling aria-hidden values, we only want to affect elements
|
|
8
8
|
// in the DOM that come from Grommet, so we track those elements in this
|
|
9
9
|
// context value. See FocusedContainer.js
|
|
10
|
-
var RootsContext = /*#__PURE__*/_react["default"].createContext([]);
|
|
11
|
-
exports.RootsContext = RootsContext;
|
|
10
|
+
var RootsContext = exports.RootsContext = /*#__PURE__*/_react["default"].createContext([]);
|
|
@@ -10,5 +10,4 @@ if (process.env.NODE_ENV !== 'production') {
|
|
|
10
10
|
value: _propTypes["default"].shape({})
|
|
11
11
|
};
|
|
12
12
|
}
|
|
13
|
-
var ThemeContextPropTypes = PropType;
|
|
14
|
-
exports.ThemeContextPropTypes = ThemeContextPropTypes;
|
|
13
|
+
var ThemeContextPropTypes = exports.ThemeContextPropTypes = PropType;
|
|
@@ -6,7 +6,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
6
6
|
var _themes = require("grommet/themes");
|
|
7
7
|
var _grommet = require("grommet");
|
|
8
8
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
9
|
-
var ExternalComponentWithTheme = function ExternalComponentWithTheme() {
|
|
9
|
+
var ExternalComponentWithTheme = exports.ExternalComponentWithTheme = function ExternalComponentWithTheme() {
|
|
10
10
|
return /*#__PURE__*/_react["default"].createElement(_grommet.Grommet, {
|
|
11
11
|
theme: _themes.grommet
|
|
12
12
|
}, /*#__PURE__*/_react["default"].createElement(_grommet.Box, {
|
|
@@ -25,9 +25,7 @@ var ExternalComponentWithTheme = function ExternalComponentWithTheme() {
|
|
|
25
25
|
}, "This component is leveraging the grommet theme capabilities although it is not a grommet component"));
|
|
26
26
|
}));
|
|
27
27
|
};
|
|
28
|
-
exports.ExternalComponentWithTheme = ExternalComponentWithTheme;
|
|
29
28
|
ExternalComponentWithTheme.storyName = 'External components';
|
|
30
|
-
var _default = {
|
|
29
|
+
var _default = exports["default"] = {
|
|
31
30
|
title: 'Utilities/ThemeContext/External components'
|
|
32
|
-
};
|
|
33
|
-
exports["default"] = _default;
|
|
31
|
+
};
|
|
@@ -6,8 +6,8 @@ var _react = _interopRequireWildcard(require("react"));
|
|
|
6
6
|
var _themes = require("grommet/themes");
|
|
7
7
|
var _utils = require("grommet/utils");
|
|
8
8
|
var _grommet = require("grommet");
|
|
9
|
-
function _getRequireWildcardCache(
|
|
10
|
-
function _interopRequireWildcard(
|
|
9
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
10
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { "default": e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n["default"] = e, t && t.set(e, n), n; }
|
|
11
11
|
var customTheme = (0, _utils.deepMerge)(_themes.grommet, {
|
|
12
12
|
global: {
|
|
13
13
|
focus: {
|
|
@@ -20,7 +20,7 @@ var customTheme = (0, _utils.deepMerge)(_themes.grommet, {
|
|
|
20
20
|
}
|
|
21
21
|
}
|
|
22
22
|
});
|
|
23
|
-
var GlobalThemeWithThemeContext = function GlobalThemeWithThemeContext() {
|
|
23
|
+
var GlobalThemeWithThemeContext = exports.GlobalThemeWithThemeContext = function GlobalThemeWithThemeContext() {
|
|
24
24
|
var options = ['one', 'two', 'three'];
|
|
25
25
|
var _useState = (0, _react.useState)(''),
|
|
26
26
|
valueRed = _useState[0],
|
|
@@ -69,9 +69,7 @@ var GlobalThemeWithThemeContext = function GlobalThemeWithThemeContext() {
|
|
|
69
69
|
}
|
|
70
70
|
})))));
|
|
71
71
|
};
|
|
72
|
-
exports.GlobalThemeWithThemeContext = GlobalThemeWithThemeContext;
|
|
73
72
|
GlobalThemeWithThemeContext.storyName = 'Extend';
|
|
74
|
-
var _default = {
|
|
73
|
+
var _default = exports["default"] = {
|
|
75
74
|
title: 'Utilities/ThemeContext/Extend'
|
|
76
|
-
};
|
|
77
|
-
exports["default"] = _default;
|
|
75
|
+
};
|
package/default-props.js
CHANGED
|
@@ -4,11 +4,9 @@ exports.__esModule = true;
|
|
|
4
4
|
exports.extendDefaultTheme = exports.defaultProps = void 0;
|
|
5
5
|
var _utils = require("./utils");
|
|
6
6
|
var _base = require("./themes/base");
|
|
7
|
-
var defaultProps = {
|
|
7
|
+
var defaultProps = exports.defaultProps = {
|
|
8
8
|
theme: _base.base
|
|
9
9
|
};
|
|
10
|
-
exports.
|
|
11
|
-
var extendDefaultTheme = function extendDefaultTheme(theme) {
|
|
10
|
+
var extendDefaultTheme = exports.extendDefaultTheme = function extendDefaultTheme(theme) {
|
|
12
11
|
defaultProps.theme = (0, _utils.deepMerge)(_base.base, theme);
|
|
13
|
-
};
|
|
14
|
-
exports.extendDefaultTheme = extendDefaultTheme;
|
|
12
|
+
};
|
|
@@ -18,7 +18,7 @@ export var SimpleBox = function SimpleBox() {
|
|
|
18
18
|
pad: "large",
|
|
19
19
|
align: "center",
|
|
20
20
|
background: {
|
|
21
|
-
color: 'light-
|
|
21
|
+
color: 'light-4',
|
|
22
22
|
opacity: 'strong'
|
|
23
23
|
},
|
|
24
24
|
round: true,
|
|
@@ -27,14 +27,15 @@ export var SimpleBox = function SimpleBox() {
|
|
|
27
27
|
size: "large"
|
|
28
28
|
}), /*#__PURE__*/React.createElement(Text, null, "Party"), /*#__PURE__*/React.createElement(Anchor, {
|
|
29
29
|
href: "",
|
|
30
|
-
label: "Link"
|
|
30
|
+
label: "Link",
|
|
31
|
+
color: "dark-1"
|
|
31
32
|
}), /*#__PURE__*/React.createElement(Button, {
|
|
32
33
|
label: "Button",
|
|
33
34
|
onClick: function onClick() {}
|
|
34
35
|
})), /*#__PURE__*/React.createElement(Box, {
|
|
35
36
|
pad: "large",
|
|
36
37
|
align: "center",
|
|
37
|
-
background: "dark-
|
|
38
|
+
background: "dark-1",
|
|
38
39
|
round: true,
|
|
39
40
|
gap: "small"
|
|
40
41
|
}, /*#__PURE__*/React.createElement(Car, {
|
|
@@ -31,8 +31,8 @@ export interface ChartProps {
|
|
|
31
31
|
dash?: boolean;
|
|
32
32
|
direction?: 'horizontal' | 'vertical';
|
|
33
33
|
gap?: GapType;
|
|
34
|
-
onClick?: (
|
|
35
|
-
onHover?: (
|
|
34
|
+
onClick?: (event: React.MouseEvent) => void;
|
|
35
|
+
onHover?: (over: boolean) => void;
|
|
36
36
|
opacity?: 'weak' | 'medium' | 'strong' | boolean | number;
|
|
37
37
|
overflow?: boolean;
|
|
38
38
|
pad?: EdgeSizeType | { horizontal?: EdgeSizeType; vertical?: EdgeSizeType };
|
|
@@ -93,8 +93,8 @@ export interface ChartProps {
|
|
|
93
93
|
| {
|
|
94
94
|
color?: ColorType;
|
|
95
95
|
label?: string;
|
|
96
|
-
onClick?: (
|
|
97
|
-
onHover?: (
|
|
96
|
+
onClick?: (event: React.MouseEvent) => void;
|
|
97
|
+
onHover?: (over: boolean) => void;
|
|
98
98
|
opacity?: 'weak' | 'medium' | 'strong' | boolean | number;
|
|
99
99
|
thickness?: ThicknessType;
|
|
100
100
|
value: number | number[];
|
|
@@ -1,5 +1,5 @@
|
|
|
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
|
-
function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return exports; }; var exports = {}, Op = Object.prototype, hasOwn = Op.hasOwnProperty, defineProperty = Object.defineProperty || function (obj, key, desc) { obj[key] = desc.value; }, $Symbol = "function" == typeof Symbol ? Symbol : {}, iteratorSymbol = $Symbol.iterator || "@@iterator", asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator", toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag"; function define(obj, key, value) { return Object.defineProperty(obj, key, { value: value, enumerable: !0, configurable: !0, writable: !0 }), obj[key]; } try { define({}, ""); } catch (err) { define = function define(obj, key, value) { return obj[key] = value; }; } function wrap(innerFn, outerFn, self, tryLocsList) { var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator, generator = Object.create(protoGenerator.prototype), context = new Context(tryLocsList || []); return defineProperty(generator, "_invoke", { value: makeInvokeMethod(innerFn, self, context) }), generator; } function tryCatch(fn, obj, arg) { try { return { type: "normal", arg: fn.call(obj, arg) }; } catch (err) { return { type: "throw", arg: err }; } } exports.wrap = wrap; var ContinueSentinel = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var IteratorPrototype = {}; define(IteratorPrototype, iteratorSymbol, function () { return this; }); var getProto = Object.getPrototypeOf, NativeIteratorPrototype = getProto && getProto(getProto(values([]))); NativeIteratorPrototype && NativeIteratorPrototype !== Op && hasOwn.call(NativeIteratorPrototype, iteratorSymbol) && (IteratorPrototype = NativeIteratorPrototype); var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(IteratorPrototype); function defineIteratorMethods(prototype) { ["next", "throw", "return"].forEach(function (method) { define(prototype, method, function (arg) { return this._invoke(method, arg); }); }); } function AsyncIterator(generator, PromiseImpl) { function invoke(method, arg, resolve, reject) { var record = tryCatch(generator[method], generator, arg); if ("throw" !== record.type) { var result = record.arg, value = result.value; return value && "object" == typeof value && hasOwn.call(value, "__await") ? PromiseImpl.resolve(value.__await).then(function (value) { invoke("next", value, resolve, reject); }, function (err) { invoke("throw", err, resolve, reject); }) : PromiseImpl.resolve(value).then(function (unwrapped) { result.value = unwrapped, resolve(result); }, function (error) { return invoke("throw", error, resolve, reject); }); } reject(record.arg); } var previousPromise; defineProperty(this, "_invoke", { value: function value(method, arg) { function callInvokeWithMethodAndArg() { return new PromiseImpl(function (resolve, reject) { invoke(method, arg, resolve, reject); }); } return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(innerFn, self, context) { var state = "suspendedStart"; return function (method, arg) { if ("executing" === state) throw new Error("Generator is already running"); if ("completed" === state) { if ("throw" === method) throw arg; return doneResult(); } for (context.method = method, context.arg = arg;;) { var delegate = context.delegate; if (delegate) { var delegateResult = maybeInvokeDelegate(delegate, context); if (delegateResult) { if (delegateResult === ContinueSentinel) continue; return delegateResult; } } if ("next" === context.method) context.sent = context._sent = context.arg;else if ("throw" === context.method) { if ("suspendedStart" === state) throw state = "completed", context.arg; context.dispatchException(context.arg); } else "return" === context.method && context.abrupt("return", context.arg); state = "executing"; var record = tryCatch(innerFn, self, context); if ("normal" === record.type) { if (state = context.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel) continue; return { value: record.arg, done: context.done }; } "throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg); } }; } function maybeInvokeDelegate(delegate, context) { var methodName = context.method, method = delegate.iterator[methodName]; if (undefined === method) return context.delegate = null, "throw" === methodName && delegate.iterator["return"] && (context.method = "return", context.arg = undefined, maybeInvokeDelegate(delegate, context), "throw" === context.method) || "return" !== methodName && (context.method = "throw", context.arg = new TypeError("The iterator does not provide a '" + methodName + "' method")), ContinueSentinel; var record = tryCatch(method, delegate.iterator, context.arg); if ("throw" === record.type) return context.method = "throw", context.arg = record.arg, context.delegate = null, ContinueSentinel; var info = record.arg; return info ? info.done ? (context[delegate.resultName] = info.value, context.next = delegate.nextLoc, "return" !== context.method && (context.method = "next", context.arg = undefined), context.delegate = null, ContinueSentinel) : info : (context.method = "throw", context.arg = new TypeError("iterator result is not an object"), context.delegate = null, ContinueSentinel); } function pushTryEntry(locs) { var entry = { tryLoc: locs[0] }; 1 in locs && (entry.catchLoc = locs[1]), 2 in locs && (entry.finallyLoc = locs[2], entry.afterLoc = locs[3]), this.tryEntries.push(entry); } function resetTryEntry(entry) { var record = entry.completion || {}; record.type = "normal", delete record.arg, entry.completion = record; } function Context(tryLocsList) { this.tryEntries = [{ tryLoc: "root" }], tryLocsList.forEach(pushTryEntry, this), this.reset(!0); } function values(iterable) { if (iterable) { var iteratorMethod = iterable[iteratorSymbol]; if (iteratorMethod) return iteratorMethod.call(iterable); if ("function" == typeof iterable.next) return iterable; if (!isNaN(iterable.length)) { var i = -1, next = function next() { for (; ++i < iterable.length;) if (hasOwn.call(iterable, i)) return next.value = iterable[i], next.done = !1, next; return next.value = undefined, next.done = !0, next; }; return next.next = next; } } return { next: doneResult }; } function doneResult() { return { value: undefined, done: !0 }; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, defineProperty(Gp, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), defineProperty(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"), exports.isGeneratorFunction = function (genFun) { var ctor = "function" == typeof genFun && genFun.constructor; return !!ctor && (ctor === GeneratorFunction || "GeneratorFunction" === (ctor.displayName || ctor.name)); }, exports.mark = function (genFun) { return Object.setPrototypeOf ? Object.setPrototypeOf(genFun, GeneratorFunctionPrototype) : (genFun.__proto__ = GeneratorFunctionPrototype, define(genFun, toStringTagSymbol, "GeneratorFunction")), genFun.prototype = Object.create(Gp), genFun; }, exports.awrap = function (arg) { return { __await: arg }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () { return this; }), exports.AsyncIterator = AsyncIterator, exports.async = function (innerFn, outerFn, self, tryLocsList, PromiseImpl) { void 0 === PromiseImpl && (PromiseImpl = Promise); var iter = new AsyncIterator(wrap(innerFn, outerFn, self, tryLocsList), PromiseImpl); return exports.isGeneratorFunction(outerFn) ? iter : iter.next().then(function (result) { return result.done ? result.value : iter.next(); }); }, defineIteratorMethods(Gp), define(Gp, toStringTagSymbol, "Generator"), define(Gp, iteratorSymbol, function () { return this; }), define(Gp, "toString", function () { return "[object Generator]"; }), exports.keys = function (val) { var object = Object(val), keys = []; for (var key in object) keys.push(key); return keys.reverse(), function next() { for (; keys.length;) { var key = keys.pop(); if (key in object) return next.value = key, next.done = !1, next; } return next.done = !0, next; }; }, exports.values = values, Context.prototype = { constructor: Context, reset: function reset(skipTempReset) { if (this.prev = 0, this.next = 0, this.sent = this._sent = undefined, this.done = !1, this.delegate = null, this.method = "next", this.arg = undefined, this.tryEntries.forEach(resetTryEntry), !skipTempReset) for (var name in this) "t" === name.charAt(0) && hasOwn.call(this, name) && !isNaN(+name.slice(1)) && (this[name] = undefined); }, stop: function stop() { this.done = !0; var rootRecord = this.tryEntries[0].completion; if ("throw" === rootRecord.type) throw rootRecord.arg; return this.rval; }, dispatchException: function dispatchException(exception) { if (this.done) throw exception; var context = this; function handle(loc, caught) { return record.type = "throw", record.arg = exception, context.next = loc, caught && (context.method = "next", context.arg = undefined), !!caught; } for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i], record = entry.completion; if ("root" === entry.tryLoc) return handle("end"); if (entry.tryLoc <= this.prev) { var hasCatch = hasOwn.call(entry, "catchLoc"), hasFinally = hasOwn.call(entry, "finallyLoc"); if (hasCatch && hasFinally) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } else if (hasCatch) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); } else { if (!hasFinally) throw new Error("try statement without catch or finally"); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } } } }, abrupt: function abrupt(type, arg) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc <= this.prev && hasOwn.call(entry, "finallyLoc") && this.prev < entry.finallyLoc) { var finallyEntry = entry; break; } } finallyEntry && ("break" === type || "continue" === type) && finallyEntry.tryLoc <= arg && arg <= finallyEntry.finallyLoc && (finallyEntry = null); var record = finallyEntry ? finallyEntry.completion : {}; return record.type = type, record.arg = arg, finallyEntry ? (this.method = "next", this.next = finallyEntry.finallyLoc, ContinueSentinel) : this.complete(record); }, complete: function complete(record, afterLoc) { if ("throw" === record.type) throw record.arg; return "break" === record.type || "continue" === record.type ? this.next = record.arg : "return" === record.type ? (this.rval = this.arg = record.arg, this.method = "return", this.next = "end") : "normal" === record.type && afterLoc && (this.next = afterLoc), ContinueSentinel; }, finish: function finish(finallyLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.finallyLoc === finallyLoc) return this.complete(entry.completion, entry.afterLoc), resetTryEntry(entry), ContinueSentinel; } }, "catch": function _catch(tryLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc === tryLoc) { var record = entry.completion; if ("throw" === record.type) { var thrown = record.arg; resetTryEntry(entry); } return thrown; } } throw new Error("illegal catch attempt"); }, delegateYield: function delegateYield(iterable, resultName, nextLoc) { return this.delegate = { iterator: values(iterable), resultName: resultName, nextLoc: nextLoc }, "next" === this.method && (this.arg = undefined), ContinueSentinel; } }, exports; }
|
|
2
|
+
function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return e; }; var t, e = {}, r = Object.prototype, n = r.hasOwnProperty, o = Object.defineProperty || function (t, e, r) { t[e] = r.value; }, i = "function" == typeof Symbol ? Symbol : {}, a = i.iterator || "@@iterator", c = i.asyncIterator || "@@asyncIterator", u = i.toStringTag || "@@toStringTag"; function define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, ""); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, "_invoke", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: "normal", arg: t.call(e, r) }; } catch (t) { return { type: "throw", arg: t }; } } e.wrap = wrap; var h = "suspendedStart", l = "suspendedYield", f = "executing", s = "completed", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { ["next", "throw", "return"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if ("throw" !== c.type) { var u = c.arg, h = u.value; return h && "object" == typeof h && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) { invoke("next", t, i, a); }, function (t) { invoke("throw", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke("throw", t, i, a); }); } a(c.arg); } var r; o(this, "_invoke", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw new Error("Generator is already running"); if (o === s) { if ("throw" === i) throw a; return { value: t, done: !0 }; } for (n.method = i, n.arg = a;;) { var c = n.delegate; if (c) { var u = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else "return" === n.method && n.abrupt("return", n.arg); o = f; var p = tryCatch(e, r, n); if ("normal" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg); } }; } function maybeInvokeDelegate(e, r) { var n = r.method, o = e.iterator[n]; if (o === t) return r.delegate = null, "throw" === n && e.iterator["return"] && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y; var i = tryCatch(o, e.iterator, r.arg); if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y; var a = i.arg; return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y); } function pushTryEntry(t) { var e = { tryLoc: t[0] }; 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e); } function resetTryEntry(t) { var e = t.completion || {}; e.type = "normal", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: "root" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(e) { if (e || "" === e) { var r = e[a]; if (r) return r.call(e); if ("function" == typeof e.next) return e; if (!isNaN(e.length)) { var o = -1, i = function next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(typeof e + " is not iterable"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) { var e = "function" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () { return this; }), define(g, "toString", function () { return "[object Generator]"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if ("throw" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if ("root" === i.tryLoc) return handle("end"); if (i.tryLoc <= this.prev) { var c = n.call(i, "catchLoc"), u = n.call(i, "finallyLoc"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw new Error("try statement without catch or finally"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) { var i = o; break; } } i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if ("throw" === t.type) throw t.arg; return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, "catch": function _catch(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.tryLoc === t) { var n = r.completion; if ("throw" === n.type) { var o = n.arg; resetTryEntry(r); } return o; } } throw new Error("illegal catch attempt"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, "next" === this.method && (this.arg = t), y; } }, e; }
|
|
3
3
|
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
|
|
4
4
|
function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
|
|
5
5
|
import React, { useEffect, useState } from 'react';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return exports; }; var exports = {}, Op = Object.prototype, hasOwn = Op.hasOwnProperty, defineProperty = Object.defineProperty || function (obj, key, desc) { obj[key] = desc.value; }, $Symbol = "function" == typeof Symbol ? Symbol : {}, iteratorSymbol = $Symbol.iterator || "@@iterator", asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator", toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag"; function define(obj, key, value) { return Object.defineProperty(obj, key, { value: value, enumerable: !0, configurable: !0, writable: !0 }), obj[key]; } try { define({}, ""); } catch (err) { define = function define(obj, key, value) { return obj[key] = value; }; } function wrap(innerFn, outerFn, self, tryLocsList) { var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator, generator = Object.create(protoGenerator.prototype), context = new Context(tryLocsList || []); return defineProperty(generator, "_invoke", { value: makeInvokeMethod(innerFn, self, context) }), generator; } function tryCatch(fn, obj, arg) { try { return { type: "normal", arg: fn.call(obj, arg) }; } catch (err) { return { type: "throw", arg: err }; } } exports.wrap = wrap; var ContinueSentinel = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var IteratorPrototype = {}; define(IteratorPrototype, iteratorSymbol, function () { return this; }); var getProto = Object.getPrototypeOf, NativeIteratorPrototype = getProto && getProto(getProto(values([]))); NativeIteratorPrototype && NativeIteratorPrototype !== Op && hasOwn.call(NativeIteratorPrototype, iteratorSymbol) && (IteratorPrototype = NativeIteratorPrototype); var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(IteratorPrototype); function defineIteratorMethods(prototype) { ["next", "throw", "return"].forEach(function (method) { define(prototype, method, function (arg) { return this._invoke(method, arg); }); }); } function AsyncIterator(generator, PromiseImpl) { function invoke(method, arg, resolve, reject) { var record = tryCatch(generator[method], generator, arg); if ("throw" !== record.type) { var result = record.arg, value = result.value; return value && "object" == typeof value && hasOwn.call(value, "__await") ? PromiseImpl.resolve(value.__await).then(function (value) { invoke("next", value, resolve, reject); }, function (err) { invoke("throw", err, resolve, reject); }) : PromiseImpl.resolve(value).then(function (unwrapped) { result.value = unwrapped, resolve(result); }, function (error) { return invoke("throw", error, resolve, reject); }); } reject(record.arg); } var previousPromise; defineProperty(this, "_invoke", { value: function value(method, arg) { function callInvokeWithMethodAndArg() { return new PromiseImpl(function (resolve, reject) { invoke(method, arg, resolve, reject); }); } return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(innerFn, self, context) { var state = "suspendedStart"; return function (method, arg) { if ("executing" === state) throw new Error("Generator is already running"); if ("completed" === state) { if ("throw" === method) throw arg; return doneResult(); } for (context.method = method, context.arg = arg;;) { var delegate = context.delegate; if (delegate) { var delegateResult = maybeInvokeDelegate(delegate, context); if (delegateResult) { if (delegateResult === ContinueSentinel) continue; return delegateResult; } } if ("next" === context.method) context.sent = context._sent = context.arg;else if ("throw" === context.method) { if ("suspendedStart" === state) throw state = "completed", context.arg; context.dispatchException(context.arg); } else "return" === context.method && context.abrupt("return", context.arg); state = "executing"; var record = tryCatch(innerFn, self, context); if ("normal" === record.type) { if (state = context.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel) continue; return { value: record.arg, done: context.done }; } "throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg); } }; } function maybeInvokeDelegate(delegate, context) { var methodName = context.method, method = delegate.iterator[methodName]; if (undefined === method) return context.delegate = null, "throw" === methodName && delegate.iterator["return"] && (context.method = "return", context.arg = undefined, maybeInvokeDelegate(delegate, context), "throw" === context.method) || "return" !== methodName && (context.method = "throw", context.arg = new TypeError("The iterator does not provide a '" + methodName + "' method")), ContinueSentinel; var record = tryCatch(method, delegate.iterator, context.arg); if ("throw" === record.type) return context.method = "throw", context.arg = record.arg, context.delegate = null, ContinueSentinel; var info = record.arg; return info ? info.done ? (context[delegate.resultName] = info.value, context.next = delegate.nextLoc, "return" !== context.method && (context.method = "next", context.arg = undefined), context.delegate = null, ContinueSentinel) : info : (context.method = "throw", context.arg = new TypeError("iterator result is not an object"), context.delegate = null, ContinueSentinel); } function pushTryEntry(locs) { var entry = { tryLoc: locs[0] }; 1 in locs && (entry.catchLoc = locs[1]), 2 in locs && (entry.finallyLoc = locs[2], entry.afterLoc = locs[3]), this.tryEntries.push(entry); } function resetTryEntry(entry) { var record = entry.completion || {}; record.type = "normal", delete record.arg, entry.completion = record; } function Context(tryLocsList) { this.tryEntries = [{ tryLoc: "root" }], tryLocsList.forEach(pushTryEntry, this), this.reset(!0); } function values(iterable) { if (iterable) { var iteratorMethod = iterable[iteratorSymbol]; if (iteratorMethod) return iteratorMethod.call(iterable); if ("function" == typeof iterable.next) return iterable; if (!isNaN(iterable.length)) { var i = -1, next = function next() { for (; ++i < iterable.length;) if (hasOwn.call(iterable, i)) return next.value = iterable[i], next.done = !1, next; return next.value = undefined, next.done = !0, next; }; return next.next = next; } } return { next: doneResult }; } function doneResult() { return { value: undefined, done: !0 }; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, defineProperty(Gp, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), defineProperty(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"), exports.isGeneratorFunction = function (genFun) { var ctor = "function" == typeof genFun && genFun.constructor; return !!ctor && (ctor === GeneratorFunction || "GeneratorFunction" === (ctor.displayName || ctor.name)); }, exports.mark = function (genFun) { return Object.setPrototypeOf ? Object.setPrototypeOf(genFun, GeneratorFunctionPrototype) : (genFun.__proto__ = GeneratorFunctionPrototype, define(genFun, toStringTagSymbol, "GeneratorFunction")), genFun.prototype = Object.create(Gp), genFun; }, exports.awrap = function (arg) { return { __await: arg }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () { return this; }), exports.AsyncIterator = AsyncIterator, exports.async = function (innerFn, outerFn, self, tryLocsList, PromiseImpl) { void 0 === PromiseImpl && (PromiseImpl = Promise); var iter = new AsyncIterator(wrap(innerFn, outerFn, self, tryLocsList), PromiseImpl); return exports.isGeneratorFunction(outerFn) ? iter : iter.next().then(function (result) { return result.done ? result.value : iter.next(); }); }, defineIteratorMethods(Gp), define(Gp, toStringTagSymbol, "Generator"), define(Gp, iteratorSymbol, function () { return this; }), define(Gp, "toString", function () { return "[object Generator]"; }), exports.keys = function (val) { var object = Object(val), keys = []; for (var key in object) keys.push(key); return keys.reverse(), function next() { for (; keys.length;) { var key = keys.pop(); if (key in object) return next.value = key, next.done = !1, next; } return next.done = !0, next; }; }, exports.values = values, Context.prototype = { constructor: Context, reset: function reset(skipTempReset) { if (this.prev = 0, this.next = 0, this.sent = this._sent = undefined, this.done = !1, this.delegate = null, this.method = "next", this.arg = undefined, this.tryEntries.forEach(resetTryEntry), !skipTempReset) for (var name in this) "t" === name.charAt(0) && hasOwn.call(this, name) && !isNaN(+name.slice(1)) && (this[name] = undefined); }, stop: function stop() { this.done = !0; var rootRecord = this.tryEntries[0].completion; if ("throw" === rootRecord.type) throw rootRecord.arg; return this.rval; }, dispatchException: function dispatchException(exception) { if (this.done) throw exception; var context = this; function handle(loc, caught) { return record.type = "throw", record.arg = exception, context.next = loc, caught && (context.method = "next", context.arg = undefined), !!caught; } for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i], record = entry.completion; if ("root" === entry.tryLoc) return handle("end"); if (entry.tryLoc <= this.prev) { var hasCatch = hasOwn.call(entry, "catchLoc"), hasFinally = hasOwn.call(entry, "finallyLoc"); if (hasCatch && hasFinally) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } else if (hasCatch) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); } else { if (!hasFinally) throw new Error("try statement without catch or finally"); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } } } }, abrupt: function abrupt(type, arg) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc <= this.prev && hasOwn.call(entry, "finallyLoc") && this.prev < entry.finallyLoc) { var finallyEntry = entry; break; } } finallyEntry && ("break" === type || "continue" === type) && finallyEntry.tryLoc <= arg && arg <= finallyEntry.finallyLoc && (finallyEntry = null); var record = finallyEntry ? finallyEntry.completion : {}; return record.type = type, record.arg = arg, finallyEntry ? (this.method = "next", this.next = finallyEntry.finallyLoc, ContinueSentinel) : this.complete(record); }, complete: function complete(record, afterLoc) { if ("throw" === record.type) throw record.arg; return "break" === record.type || "continue" === record.type ? this.next = record.arg : "return" === record.type ? (this.rval = this.arg = record.arg, this.method = "return", this.next = "end") : "normal" === record.type && afterLoc && (this.next = afterLoc), ContinueSentinel; }, finish: function finish(finallyLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.finallyLoc === finallyLoc) return this.complete(entry.completion, entry.afterLoc), resetTryEntry(entry), ContinueSentinel; } }, "catch": function _catch(tryLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc === tryLoc) { var record = entry.completion; if ("throw" === record.type) { var thrown = record.arg; resetTryEntry(entry); } return thrown; } } throw new Error("illegal catch attempt"); }, delegateYield: function delegateYield(iterable, resultName, nextLoc) { return this.delegate = { iterator: values(iterable), resultName: resultName, nextLoc: nextLoc }, "next" === this.method && (this.arg = undefined), ContinueSentinel; } }, exports; }
|
|
1
|
+
function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return e; }; var t, e = {}, r = Object.prototype, n = r.hasOwnProperty, o = Object.defineProperty || function (t, e, r) { t[e] = r.value; }, i = "function" == typeof Symbol ? Symbol : {}, a = i.iterator || "@@iterator", c = i.asyncIterator || "@@asyncIterator", u = i.toStringTag || "@@toStringTag"; function define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, ""); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, "_invoke", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: "normal", arg: t.call(e, r) }; } catch (t) { return { type: "throw", arg: t }; } } e.wrap = wrap; var h = "suspendedStart", l = "suspendedYield", f = "executing", s = "completed", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { ["next", "throw", "return"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if ("throw" !== c.type) { var u = c.arg, h = u.value; return h && "object" == typeof h && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) { invoke("next", t, i, a); }, function (t) { invoke("throw", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke("throw", t, i, a); }); } a(c.arg); } var r; o(this, "_invoke", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw new Error("Generator is already running"); if (o === s) { if ("throw" === i) throw a; return { value: t, done: !0 }; } for (n.method = i, n.arg = a;;) { var c = n.delegate; if (c) { var u = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else "return" === n.method && n.abrupt("return", n.arg); o = f; var p = tryCatch(e, r, n); if ("normal" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg); } }; } function maybeInvokeDelegate(e, r) { var n = r.method, o = e.iterator[n]; if (o === t) return r.delegate = null, "throw" === n && e.iterator["return"] && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y; var i = tryCatch(o, e.iterator, r.arg); if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y; var a = i.arg; return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y); } function pushTryEntry(t) { var e = { tryLoc: t[0] }; 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e); } function resetTryEntry(t) { var e = t.completion || {}; e.type = "normal", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: "root" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(e) { if (e || "" === e) { var r = e[a]; if (r) return r.call(e); if ("function" == typeof e.next) return e; if (!isNaN(e.length)) { var o = -1, i = function next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(typeof e + " is not iterable"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) { var e = "function" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () { return this; }), define(g, "toString", function () { return "[object Generator]"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if ("throw" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if ("root" === i.tryLoc) return handle("end"); if (i.tryLoc <= this.prev) { var c = n.call(i, "catchLoc"), u = n.call(i, "finallyLoc"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw new Error("try statement without catch or finally"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) { var i = o; break; } } i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if ("throw" === t.type) throw t.arg; return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, "catch": function _catch(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.tryLoc === t) { var n = r.completion; if ("throw" === n.type) { var o = n.arg; resetTryEntry(r); } return o; } } throw new Error("illegal catch attempt"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, "next" === this.method && (this.arg = t), y; } }, e; }
|
|
2
2
|
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
|
|
3
3
|
function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
|
|
4
4
|
import React, { useEffect, useMemo, useState } from 'react';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return exports; }; var exports = {}, Op = Object.prototype, hasOwn = Op.hasOwnProperty, defineProperty = Object.defineProperty || function (obj, key, desc) { obj[key] = desc.value; }, $Symbol = "function" == typeof Symbol ? Symbol : {}, iteratorSymbol = $Symbol.iterator || "@@iterator", asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator", toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag"; function define(obj, key, value) { return Object.defineProperty(obj, key, { value: value, enumerable: !0, configurable: !0, writable: !0 }), obj[key]; } try { define({}, ""); } catch (err) { define = function define(obj, key, value) { return obj[key] = value; }; } function wrap(innerFn, outerFn, self, tryLocsList) { var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator, generator = Object.create(protoGenerator.prototype), context = new Context(tryLocsList || []); return defineProperty(generator, "_invoke", { value: makeInvokeMethod(innerFn, self, context) }), generator; } function tryCatch(fn, obj, arg) { try { return { type: "normal", arg: fn.call(obj, arg) }; } catch (err) { return { type: "throw", arg: err }; } } exports.wrap = wrap; var ContinueSentinel = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var IteratorPrototype = {}; define(IteratorPrototype, iteratorSymbol, function () { return this; }); var getProto = Object.getPrototypeOf, NativeIteratorPrototype = getProto && getProto(getProto(values([]))); NativeIteratorPrototype && NativeIteratorPrototype !== Op && hasOwn.call(NativeIteratorPrototype, iteratorSymbol) && (IteratorPrototype = NativeIteratorPrototype); var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(IteratorPrototype); function defineIteratorMethods(prototype) { ["next", "throw", "return"].forEach(function (method) { define(prototype, method, function (arg) { return this._invoke(method, arg); }); }); } function AsyncIterator(generator, PromiseImpl) { function invoke(method, arg, resolve, reject) { var record = tryCatch(generator[method], generator, arg); if ("throw" !== record.type) { var result = record.arg, value = result.value; return value && "object" == typeof value && hasOwn.call(value, "__await") ? PromiseImpl.resolve(value.__await).then(function (value) { invoke("next", value, resolve, reject); }, function (err) { invoke("throw", err, resolve, reject); }) : PromiseImpl.resolve(value).then(function (unwrapped) { result.value = unwrapped, resolve(result); }, function (error) { return invoke("throw", error, resolve, reject); }); } reject(record.arg); } var previousPromise; defineProperty(this, "_invoke", { value: function value(method, arg) { function callInvokeWithMethodAndArg() { return new PromiseImpl(function (resolve, reject) { invoke(method, arg, resolve, reject); }); } return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(innerFn, self, context) { var state = "suspendedStart"; return function (method, arg) { if ("executing" === state) throw new Error("Generator is already running"); if ("completed" === state) { if ("throw" === method) throw arg; return doneResult(); } for (context.method = method, context.arg = arg;;) { var delegate = context.delegate; if (delegate) { var delegateResult = maybeInvokeDelegate(delegate, context); if (delegateResult) { if (delegateResult === ContinueSentinel) continue; return delegateResult; } } if ("next" === context.method) context.sent = context._sent = context.arg;else if ("throw" === context.method) { if ("suspendedStart" === state) throw state = "completed", context.arg; context.dispatchException(context.arg); } else "return" === context.method && context.abrupt("return", context.arg); state = "executing"; var record = tryCatch(innerFn, self, context); if ("normal" === record.type) { if (state = context.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel) continue; return { value: record.arg, done: context.done }; } "throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg); } }; } function maybeInvokeDelegate(delegate, context) { var methodName = context.method, method = delegate.iterator[methodName]; if (undefined === method) return context.delegate = null, "throw" === methodName && delegate.iterator["return"] && (context.method = "return", context.arg = undefined, maybeInvokeDelegate(delegate, context), "throw" === context.method) || "return" !== methodName && (context.method = "throw", context.arg = new TypeError("The iterator does not provide a '" + methodName + "' method")), ContinueSentinel; var record = tryCatch(method, delegate.iterator, context.arg); if ("throw" === record.type) return context.method = "throw", context.arg = record.arg, context.delegate = null, ContinueSentinel; var info = record.arg; return info ? info.done ? (context[delegate.resultName] = info.value, context.next = delegate.nextLoc, "return" !== context.method && (context.method = "next", context.arg = undefined), context.delegate = null, ContinueSentinel) : info : (context.method = "throw", context.arg = new TypeError("iterator result is not an object"), context.delegate = null, ContinueSentinel); } function pushTryEntry(locs) { var entry = { tryLoc: locs[0] }; 1 in locs && (entry.catchLoc = locs[1]), 2 in locs && (entry.finallyLoc = locs[2], entry.afterLoc = locs[3]), this.tryEntries.push(entry); } function resetTryEntry(entry) { var record = entry.completion || {}; record.type = "normal", delete record.arg, entry.completion = record; } function Context(tryLocsList) { this.tryEntries = [{ tryLoc: "root" }], tryLocsList.forEach(pushTryEntry, this), this.reset(!0); } function values(iterable) { if (iterable) { var iteratorMethod = iterable[iteratorSymbol]; if (iteratorMethod) return iteratorMethod.call(iterable); if ("function" == typeof iterable.next) return iterable; if (!isNaN(iterable.length)) { var i = -1, next = function next() { for (; ++i < iterable.length;) if (hasOwn.call(iterable, i)) return next.value = iterable[i], next.done = !1, next; return next.value = undefined, next.done = !0, next; }; return next.next = next; } } return { next: doneResult }; } function doneResult() { return { value: undefined, done: !0 }; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, defineProperty(Gp, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), defineProperty(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"), exports.isGeneratorFunction = function (genFun) { var ctor = "function" == typeof genFun && genFun.constructor; return !!ctor && (ctor === GeneratorFunction || "GeneratorFunction" === (ctor.displayName || ctor.name)); }, exports.mark = function (genFun) { return Object.setPrototypeOf ? Object.setPrototypeOf(genFun, GeneratorFunctionPrototype) : (genFun.__proto__ = GeneratorFunctionPrototype, define(genFun, toStringTagSymbol, "GeneratorFunction")), genFun.prototype = Object.create(Gp), genFun; }, exports.awrap = function (arg) { return { __await: arg }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () { return this; }), exports.AsyncIterator = AsyncIterator, exports.async = function (innerFn, outerFn, self, tryLocsList, PromiseImpl) { void 0 === PromiseImpl && (PromiseImpl = Promise); var iter = new AsyncIterator(wrap(innerFn, outerFn, self, tryLocsList), PromiseImpl); return exports.isGeneratorFunction(outerFn) ? iter : iter.next().then(function (result) { return result.done ? result.value : iter.next(); }); }, defineIteratorMethods(Gp), define(Gp, toStringTagSymbol, "Generator"), define(Gp, iteratorSymbol, function () { return this; }), define(Gp, "toString", function () { return "[object Generator]"; }), exports.keys = function (val) { var object = Object(val), keys = []; for (var key in object) keys.push(key); return keys.reverse(), function next() { for (; keys.length;) { var key = keys.pop(); if (key in object) return next.value = key, next.done = !1, next; } return next.done = !0, next; }; }, exports.values = values, Context.prototype = { constructor: Context, reset: function reset(skipTempReset) { if (this.prev = 0, this.next = 0, this.sent = this._sent = undefined, this.done = !1, this.delegate = null, this.method = "next", this.arg = undefined, this.tryEntries.forEach(resetTryEntry), !skipTempReset) for (var name in this) "t" === name.charAt(0) && hasOwn.call(this, name) && !isNaN(+name.slice(1)) && (this[name] = undefined); }, stop: function stop() { this.done = !0; var rootRecord = this.tryEntries[0].completion; if ("throw" === rootRecord.type) throw rootRecord.arg; return this.rval; }, dispatchException: function dispatchException(exception) { if (this.done) throw exception; var context = this; function handle(loc, caught) { return record.type = "throw", record.arg = exception, context.next = loc, caught && (context.method = "next", context.arg = undefined), !!caught; } for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i], record = entry.completion; if ("root" === entry.tryLoc) return handle("end"); if (entry.tryLoc <= this.prev) { var hasCatch = hasOwn.call(entry, "catchLoc"), hasFinally = hasOwn.call(entry, "finallyLoc"); if (hasCatch && hasFinally) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } else if (hasCatch) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); } else { if (!hasFinally) throw new Error("try statement without catch or finally"); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } } } }, abrupt: function abrupt(type, arg) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc <= this.prev && hasOwn.call(entry, "finallyLoc") && this.prev < entry.finallyLoc) { var finallyEntry = entry; break; } } finallyEntry && ("break" === type || "continue" === type) && finallyEntry.tryLoc <= arg && arg <= finallyEntry.finallyLoc && (finallyEntry = null); var record = finallyEntry ? finallyEntry.completion : {}; return record.type = type, record.arg = arg, finallyEntry ? (this.method = "next", this.next = finallyEntry.finallyLoc, ContinueSentinel) : this.complete(record); }, complete: function complete(record, afterLoc) { if ("throw" === record.type) throw record.arg; return "break" === record.type || "continue" === record.type ? this.next = record.arg : "return" === record.type ? (this.rval = this.arg = record.arg, this.method = "return", this.next = "end") : "normal" === record.type && afterLoc && (this.next = afterLoc), ContinueSentinel; }, finish: function finish(finallyLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.finallyLoc === finallyLoc) return this.complete(entry.completion, entry.afterLoc), resetTryEntry(entry), ContinueSentinel; } }, "catch": function _catch(tryLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc === tryLoc) { var record = entry.completion; if ("throw" === record.type) { var thrown = record.arg; resetTryEntry(entry); } return thrown; } } throw new Error("illegal catch attempt"); }, delegateYield: function delegateYield(iterable, resultName, nextLoc) { return this.delegate = { iterator: values(iterable), resultName: resultName, nextLoc: nextLoc }, "next" === this.method && (this.arg = undefined), ContinueSentinel; } }, exports; }
|
|
1
|
+
function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return e; }; var t, e = {}, r = Object.prototype, n = r.hasOwnProperty, o = Object.defineProperty || function (t, e, r) { t[e] = r.value; }, i = "function" == typeof Symbol ? Symbol : {}, a = i.iterator || "@@iterator", c = i.asyncIterator || "@@asyncIterator", u = i.toStringTag || "@@toStringTag"; function define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, ""); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, "_invoke", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: "normal", arg: t.call(e, r) }; } catch (t) { return { type: "throw", arg: t }; } } e.wrap = wrap; var h = "suspendedStart", l = "suspendedYield", f = "executing", s = "completed", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { ["next", "throw", "return"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if ("throw" !== c.type) { var u = c.arg, h = u.value; return h && "object" == typeof h && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) { invoke("next", t, i, a); }, function (t) { invoke("throw", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke("throw", t, i, a); }); } a(c.arg); } var r; o(this, "_invoke", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw new Error("Generator is already running"); if (o === s) { if ("throw" === i) throw a; return { value: t, done: !0 }; } for (n.method = i, n.arg = a;;) { var c = n.delegate; if (c) { var u = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else "return" === n.method && n.abrupt("return", n.arg); o = f; var p = tryCatch(e, r, n); if ("normal" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg); } }; } function maybeInvokeDelegate(e, r) { var n = r.method, o = e.iterator[n]; if (o === t) return r.delegate = null, "throw" === n && e.iterator["return"] && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y; var i = tryCatch(o, e.iterator, r.arg); if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y; var a = i.arg; return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y); } function pushTryEntry(t) { var e = { tryLoc: t[0] }; 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e); } function resetTryEntry(t) { var e = t.completion || {}; e.type = "normal", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: "root" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(e) { if (e || "" === e) { var r = e[a]; if (r) return r.call(e); if ("function" == typeof e.next) return e; if (!isNaN(e.length)) { var o = -1, i = function next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(typeof e + " is not iterable"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) { var e = "function" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () { return this; }), define(g, "toString", function () { return "[object Generator]"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if ("throw" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if ("root" === i.tryLoc) return handle("end"); if (i.tryLoc <= this.prev) { var c = n.call(i, "catchLoc"), u = n.call(i, "finallyLoc"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw new Error("try statement without catch or finally"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) { var i = o; break; } } i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if ("throw" === t.type) throw t.arg; return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, "catch": function _catch(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.tryLoc === t) { var n = r.completion; if ("throw" === n.type) { var o = n.arg; resetTryEntry(r); } return o; } } throw new Error("illegal catch attempt"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, "next" === this.method && (this.arg = t), y; } }, e; }
|
|
2
2
|
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
|
|
3
3
|
function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
|
|
4
4
|
import React, { useEffect, useRef, useState } from 'react';
|
|
@@ -59,7 +59,7 @@ export var StarWars = function StarWars() {
|
|
|
59
59
|
useEffect(function () {
|
|
60
60
|
var _abortRef$current;
|
|
61
61
|
// This API is a bit slow, abort any uncompleted requests.
|
|
62
|
-
abortRef == null || (_abortRef$current = abortRef.current) == null
|
|
62
|
+
abortRef == null || (_abortRef$current = abortRef.current) == null || _abortRef$current.abort();
|
|
63
63
|
abortRef.current = new AbortController();
|
|
64
64
|
fetchData(view, abortRef.current.signal).then(function (_ref2) {
|
|
65
65
|
var count = _ref2.count,
|