@koine/react 2.0.0-beta.16 → 2.0.0-beta.18
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/Alert/Alert.d.ts +0 -0
- package/Alert/Alert.js +0 -0
- package/Alert/index.d.ts +0 -0
- package/Alert/index.js +0 -0
- package/Animations/Reveal.d.ts +0 -0
- package/Animations/Reveal.js +0 -0
- package/Animations/Underline.d.ts +0 -0
- package/Animations/Underline.js +0 -0
- package/Animations/index.d.ts +0 -0
- package/Animations/index.js +0 -0
- package/Animations/useReveal.d.ts +0 -0
- package/Animations/useReveal.js +4 -3
- package/Autocomplete/AutocompleteDownshift.d.ts +0 -0
- package/Autocomplete/AutocompleteDownshift.js +0 -0
- package/Autocomplete/AutocompleteDownshiftMultiselect.d.ts +0 -0
- package/Autocomplete/AutocompleteDownshiftMultiselect.js +0 -0
- package/Autocomplete/AutocompleteMui.d.ts +0 -0
- package/Autocomplete/AutocompleteMui.js +3 -3
- package/Autocomplete/AutocompleteReach.d.ts +0 -0
- package/Autocomplete/AutocompleteReach.js +0 -0
- package/Autocomplete/components.d.ts +0 -0
- package/Autocomplete/components.js +0 -0
- package/Autocomplete/helpers.d.ts +0 -0
- package/Autocomplete/helpers.js +0 -0
- package/Autocomplete/index.d.ts +0 -0
- package/Autocomplete/index.js +0 -0
- package/Bg/BgColor.d.ts +0 -0
- package/Bg/BgColor.js +0 -0
- package/Bg/BgPhoto.d.ts +0 -0
- package/Bg/BgPhoto.js +0 -0
- package/Bg/BgSvg.d.ts +0 -0
- package/Bg/BgSvg.js +0 -0
- package/Bg/index.d.ts +0 -0
- package/Bg/index.js +0 -0
- package/Breadcrumbs/Breadcrumbs.d.ts +0 -0
- package/Breadcrumbs/Breadcrumbs.js +0 -0
- package/Breadcrumbs/index.d.ts +0 -0
- package/Breadcrumbs/index.js +0 -0
- package/Buttons/Button.d.ts +0 -0
- package/Buttons/Button.js +0 -0
- package/Buttons/ButtonComposite.d.ts +0 -0
- package/Buttons/ButtonComposite.js +0 -0
- package/Buttons/ButtonFab.d.ts +0 -0
- package/Buttons/ButtonFab.js +0 -0
- package/Buttons/ButtonLink.d.ts +0 -0
- package/Buttons/ButtonLink.js +0 -0
- package/Buttons/IconButton.d.ts +0 -0
- package/Buttons/IconButton.js +0 -0
- package/Buttons/index.d.ts +0 -0
- package/Buttons/index.js +0 -0
- package/Calendar/CalendarDaygridCell.d.ts +0 -0
- package/Calendar/CalendarDaygridCell.js +2 -2
- package/Calendar/CalendarDaygridNav.d.ts +0 -0
- package/Calendar/CalendarDaygridNav.js +2 -1
- package/Calendar/CalendarDaygridTable.d.ts +0 -0
- package/Calendar/CalendarDaygridTable.js +4 -4
- package/Calendar/CalendarLegend.d.ts +0 -0
- package/Calendar/CalendarLegend.js +2 -1
- package/Calendar/calendar-api-google.d.ts +0 -0
- package/Calendar/calendar-api-google.js +0 -0
- package/Calendar/index.d.ts +0 -0
- package/Calendar/index.js +0 -0
- package/Calendar/types.d.ts +0 -0
- package/Calendar/types.js +0 -0
- package/Calendar/useCalendar.d.ts +0 -0
- package/Calendar/useCalendar.js +15 -15
- package/Calendar/utils.d.ts +0 -0
- package/Calendar/utils.js +0 -0
- package/Carousel/Carousel.d.ts +0 -0
- package/Carousel/Carousel.js +0 -0
- package/Carousel/CarouselCss.d.ts +0 -0
- package/Carousel/CarouselCss.js +0 -0
- package/Carousel/index.d.ts +0 -0
- package/Carousel/index.js +0 -0
- package/Collapsable/Collapsable.d.ts +0 -0
- package/Collapsable/Collapsable.js +0 -0
- package/Collapsable/CollapsableReach.d.ts +0 -0
- package/Collapsable/CollapsableReach.js +0 -0
- package/Collapsable/index.d.ts +0 -0
- package/Collapsable/index.js +0 -0
- package/Debug/Debug.d.ts +0 -0
- package/Debug/Debug.js +0 -0
- package/Debug/index.d.ts +0 -0
- package/Debug/index.js +0 -0
- package/Details/Details.d.ts +0 -0
- package/Details/Details.js +4 -4
- package/Details/index.d.ts +0 -0
- package/Details/index.js +0 -0
- package/Dialog/DialogMui.d.ts +0 -0
- package/Dialog/DialogMui.js +0 -0
- package/Dialog/css/bare.d.ts +0 -0
- package/Dialog/css/bare.js +0 -0
- package/Dialog/index.d.ts +0 -0
- package/Dialog/index.js +0 -0
- package/Dialog/m/bare.d.ts +0 -0
- package/Dialog/m/bare.js +0 -0
- package/Dialog/m/basic.d.ts +0 -0
- package/Dialog/m/basic.js +0 -0
- package/Dialog/m/index.d.ts +0 -0
- package/Dialog/m/index.js +0 -0
- package/Dialog/sc/bare.d.ts +0 -0
- package/Dialog/sc/bare.js +0 -0
- package/Dialog/sc/framer.d.ts +0 -0
- package/Dialog/sc/framer.js +0 -0
- package/Dialog/sc/framerMaterial.d.ts +0 -0
- package/Dialog/sc/framerMaterial.js +0 -0
- package/Dialog/sc/material.d.ts +0 -0
- package/Dialog/sc/material.js +0 -0
- package/Dialog/tw/bare.d.ts +0 -0
- package/Dialog/tw/bare.js +0 -0
- package/Dialog/tw/elegant.d.ts +0 -0
- package/Dialog/tw/elegant.js +0 -0
- package/Dialog/tw/framer.d.ts +0 -0
- package/Dialog/tw/framer.js +0 -0
- package/Dialog/tw/framerMaterial.d.ts +0 -0
- package/Dialog/tw/framerMaterial.js +0 -0
- package/Dialog/tw/material.d.ts +0 -0
- package/Dialog/tw/material.js +0 -0
- package/Editor/Editor--tiptap.d.ts +0 -0
- package/Editor/Editor--tiptap.js +0 -0
- package/Editor/components.d.ts +0 -0
- package/Editor/components.js +0 -0
- package/Editor/index.d.ts +0 -0
- package/Editor/index.js +0 -0
- package/FaviconTags.d.ts +0 -0
- package/FaviconTags.js +0 -0
- package/Form/Form.d.ts +0 -0
- package/Form/Form.js +2 -2
- package/Form/index.d.ts +0 -0
- package/Form/index.js +0 -0
- package/Form/sc/bare.d.ts +0 -0
- package/Form/sc/bare.js +0 -0
- package/Forms/Checkbox/Checkbox.d.ts +0 -0
- package/Forms/Checkbox/Checkbox.js +0 -0
- package/Forms/Checkbox/index.d.ts +0 -0
- package/Forms/Checkbox/index.js +0 -0
- package/Forms/Feedback/Feedback.d.ts +0 -0
- package/Forms/Feedback/Feedback.js +0 -0
- package/Forms/Feedback/index.d.ts +0 -0
- package/Forms/Feedback/index.js +0 -0
- package/Forms/Field/Field.d.ts +0 -0
- package/Forms/Field/Field.js +0 -0
- package/Forms/Field/FieldControl.d.ts +0 -0
- package/Forms/Field/FieldControl.js +0 -0
- package/Forms/Field/FieldHint.d.ts +0 -0
- package/Forms/Field/FieldHint.js +0 -0
- package/Forms/Field/index.d.ts +0 -0
- package/Forms/Field/index.js +0 -0
- package/Forms/Input/Input.d.ts +0 -0
- package/Forms/Input/Input.js +0 -0
- package/Forms/Input/index.d.ts +0 -0
- package/Forms/Input/index.js +0 -0
- package/Forms/InputGroup/InputGroup.d.ts +0 -0
- package/Forms/InputGroup/InputGroup.js +0 -0
- package/Forms/InputGroup/index.d.ts +0 -0
- package/Forms/InputGroup/index.js +0 -0
- package/Forms/Label/Label.d.ts +0 -0
- package/Forms/Label/Label.js +0 -0
- package/Forms/Label/index.d.ts +0 -0
- package/Forms/Label/index.js +0 -0
- package/Forms/Password/Password.d.ts +0 -0
- package/Forms/Password/Password.js +2 -2
- package/Forms/Password/index.d.ts +0 -0
- package/Forms/Password/index.js +0 -0
- package/Forms/Radio/Radio.d.ts +0 -0
- package/Forms/Radio/Radio.js +0 -0
- package/Forms/Radio/index.d.ts +0 -0
- package/Forms/Radio/index.js +0 -0
- package/Forms/Switch/Switch.d.ts +0 -0
- package/Forms/Switch/Switch.js +0 -0
- package/Forms/Switch/index.d.ts +0 -0
- package/Forms/Switch/index.js +0 -0
- package/Forms/Textarea/Textarea.d.ts +0 -0
- package/Forms/Textarea/Textarea.js +0 -0
- package/Forms/Textarea/TextareaRich.d.ts +0 -0
- package/Forms/Textarea/TextareaRich.js +0 -0
- package/Forms/Textarea/index.d.ts +0 -0
- package/Forms/Textarea/index.js +0 -0
- package/Forms/Toggle/Toggle-tailwind.d.ts +0 -0
- package/Forms/Toggle/Toggle-tailwind.js +0 -0
- package/Forms/Toggle/Toggle.d.ts +0 -0
- package/Forms/Toggle/Toggle.js +0 -0
- package/Forms/Toggle/index.d.ts +0 -0
- package/Forms/Toggle/index.js +0 -0
- package/Forms/Toggle/useToggle-tailwind.d.ts +0 -0
- package/Forms/Toggle/useToggle-tailwind.js +0 -0
- package/Forms/Toggle/useToggle.d.ts +0 -0
- package/Forms/Toggle/useToggle.js +0 -0
- package/Forms/antispam.d.ts +0 -0
- package/Forms/antispam.js +0 -0
- package/Forms/helpers.d.ts +0 -0
- package/Forms/helpers.js +0 -0
- package/Forms/index.d.ts +0 -0
- package/Forms/index.js +0 -0
- package/Forms/styles.d.ts +0 -0
- package/Forms/styles.js +0 -0
- package/Gauge/Gauge.d.ts +0 -0
- package/Gauge/Gauge.js +0 -0
- package/Grid/Grid.d.ts +0 -0
- package/Grid/Grid.js +2 -2
- package/Grid/index.d.ts +0 -0
- package/Grid/index.js +0 -0
- package/Hamburger/Hamburger.d.ts +0 -0
- package/Hamburger/Hamburger.js +0 -0
- package/Hamburger/index.d.ts +0 -0
- package/Hamburger/index.js +0 -0
- package/Header/index.d.ts +0 -0
- package/Header/index.js +0 -0
- package/Header/useHeader.d.ts +0 -0
- package/Header/useHeader.js +5 -4
- package/Hidden/Hidden.d.ts +0 -0
- package/Hidden/Hidden.js +0 -0
- package/Hidden/index.d.ts +0 -0
- package/Hidden/index.js +0 -0
- package/Img/index.d.ts +0 -0
- package/Img/index.js +0 -0
- package/Img/sc/bare.d.ts +0 -0
- package/Img/sc/bare.js +0 -0
- package/Img/types.d.ts +0 -0
- package/Img/types.js +0 -0
- package/Link/Link.d.ts +0 -0
- package/Link/Link.js +0 -0
- package/Link/LinkBlank.d.ts +0 -0
- package/Link/LinkBlank.js +0 -0
- package/Link/index.d.ts +0 -0
- package/Link/index.js +0 -0
- package/Menu/Menu.d.ts +0 -0
- package/Menu/Menu.js +0 -0
- package/Menu/MenuMui.d.ts +0 -0
- package/Menu/MenuMui.js +0 -0
- package/Menu/index.d.ts +0 -0
- package/Menu/index.js +0 -0
- package/MenuItem/MenuItem.d.ts +0 -0
- package/MenuItem/MenuItem.js +0 -0
- package/MenuItem/MenuItemMui.d.ts +0 -0
- package/MenuItem/MenuItemMui.js +0 -0
- package/MenuItem/index.d.ts +0 -0
- package/MenuItem/index.js +0 -0
- package/MenuItem/useMenuItem.d.ts +0 -0
- package/MenuItem/useMenuItem.js +2 -2
- package/Meta.d.ts +0 -0
- package/Meta.js +0 -0
- package/NoJs.d.ts +0 -0
- package/NoJs.js +0 -0
- package/Pagination/PaginationNav.d.ts +0 -0
- package/Pagination/PaginationNav.js +0 -0
- package/Pagination/PaginationResults.d.ts +0 -0
- package/Pagination/PaginationResults.js +0 -0
- package/Pagination/index.d.ts +0 -0
- package/Pagination/index.js +0 -0
- package/Pill/Pill.d.ts +0 -0
- package/Pill/Pill.js +0 -0
- package/Pill/index.d.ts +0 -0
- package/Pill/index.js +0 -0
- package/Progress/ProgressCircular.d.ts +0 -0
- package/Progress/ProgressCircular.js +0 -0
- package/Progress/ProgressLinear.d.ts +0 -0
- package/Progress/ProgressLinear.js +0 -0
- package/Progress/ProgressOverlay.d.ts +0 -0
- package/Progress/ProgressOverlay.js +2 -2
- package/Progress/index.d.ts +0 -0
- package/Progress/index.js +0 -0
- package/Rating/Rating.d.ts +0 -0
- package/Rating/Rating.js +3 -3
- package/Rating/index.d.ts +0 -0
- package/Rating/index.js +0 -0
- package/Select/SelectDownshift.d.ts +0 -0
- package/Select/SelectDownshift.js +0 -0
- package/Select/components.d.ts +0 -0
- package/Select/components.js +0 -0
- package/Select/index.d.ts +0 -0
- package/Select/index.js +0 -0
- package/Sidebar/Sidebar.d.ts +0 -0
- package/Sidebar/Sidebar.js +3 -3
- package/Sidebar/index.d.ts +0 -0
- package/Sidebar/index.js +0 -0
- package/Spacing/Spacing.d.ts +0 -0
- package/Spacing/Spacing.js +3 -3
- package/Spacing/index.d.ts +0 -0
- package/Spacing/index.js +0 -0
- package/Sticky/Sticky.d.ts +0 -0
- package/Sticky/Sticky.js +0 -0
- package/Sticky/StickyCss.d.ts +0 -0
- package/Sticky/StickyCss.js +0 -0
- package/Sticky/index.d.ts +0 -0
- package/Sticky/index.js +0 -0
- package/Tabs/TabsMui.d.ts +0 -0
- package/Tabs/TabsMui.js +0 -0
- package/Tabs/index.d.ts +0 -0
- package/Tabs/index.js +0 -0
- package/Tabs/sc/bare.d.ts +0 -0
- package/Tabs/sc/bare.js +0 -0
- package/Tabs/tw/bare.d.ts +0 -0
- package/Tabs/tw/bare.js +0 -0
- package/Tabs/tw/material.d.ts +0 -0
- package/Tabs/tw/material.js +0 -0
- package/Tabs/useTabs.d.ts +0 -0
- package/Tabs/useTabs.js +3 -2
- package/Typography/CopyPasteVisible.d.ts +0 -0
- package/Typography/CopyPasteVisible.js +0 -0
- package/Typography/Native.d.ts +0 -0
- package/Typography/Native.js +0 -0
- package/Typography/ReadMore.d.ts +0 -0
- package/Typography/ReadMore.js +5 -5
- package/Typography/TextLoop.d.ts +0 -0
- package/Typography/TextLoop.js +4 -4
- package/Typography/TypeStairs.d.ts +0 -0
- package/Typography/TypeStairs.js +0 -0
- package/Typography/index.d.ts +0 -0
- package/Typography/index.js +0 -0
- package/classed.d.ts +0 -0
- package/classed.js +0 -0
- package/createUseMediaQueryWidth.d.ts +0 -0
- package/createUseMediaQueryWidth.js +4 -3
- package/css/index.d.ts +0 -0
- package/css/index.js +0 -0
- package/extendComponent.d.ts +0 -0
- package/extendComponent.js +0 -0
- package/index.d.ts +0 -0
- package/index.js +0 -0
- package/m/MotionProvider.d.ts +0 -0
- package/m/MotionProvider.js +0 -0
- package/m/index.d.ts +0 -0
- package/m/index.js +0 -0
- package/m/lite.d.ts +0 -0
- package/m/lite.js +0 -0
- package/m/max.d.ts +0 -0
- package/m/max.js +0 -0
- package/mergeRefs.d.ts +0 -0
- package/mergeRefs.js +0 -0
- package/package.json +3 -3
- package/sc/index.d.ts +0 -0
- package/sc/index.js +0 -0
- package/scm/index.d.ts +0 -0
- package/scm/index.js +0 -0
- package/shared/index.d.ts +0 -0
- package/shared/index.js +0 -0
- package/styles/Body.d.ts +0 -0
- package/styles/Body.js +0 -0
- package/styles/Global.d.ts +0 -0
- package/styles/Global.js +0 -0
- package/styles/index.d.ts +0 -0
- package/styles/index.js +0 -0
- package/styles/media.d.ts +0 -0
- package/styles/media.js +3 -2
- package/styles/spacing.d.ts +0 -0
- package/styles/spacing.js +0 -0
- package/styles/styled.d.ts +0 -0
- package/styles/styled.js +0 -0
- package/styles/theme--vanilla.d.ts +0 -0
- package/styles/theme--vanilla.js +2 -1
- package/styles/theme.d.ts +0 -0
- package/styles/theme.js +2 -2
- package/tw/index.d.ts +0 -0
- package/tw/index.js +0 -0
- package/twm/index.d.ts +0 -0
- package/twm/index.js +0 -0
- package/types.d.ts +0 -0
- package/types.js +0 -0
- package/useAsyncFn.d.ts +0 -0
- package/useAsyncFn.js +3 -3
- package/useDateLocale.d.ts +0 -0
- package/useDateLocale.js +3 -3
- package/useFirstMountState.d.ts +0 -0
- package/useFirstMountState.js +0 -0
- package/useFixedOffset.d.ts +0 -0
- package/useFixedOffset.js +0 -0
- package/useFocus.d.ts +0 -0
- package/useFocus.js +0 -0
- package/useInterval.d.ts +0 -0
- package/useInterval.js +2 -2
- package/useIsomorphicLayoutEffect.d.ts +0 -0
- package/useIsomorphicLayoutEffect.js +0 -0
- package/useKeyUp.d.ts +0 -0
- package/useKeyUp.js +2 -2
- package/useMeasure.d.ts +0 -0
- package/useMeasure.js +9 -9
- package/useMountedState.d.ts +0 -0
- package/useMountedState.js +0 -0
- package/useNavigateAway.d.ts +0 -0
- package/useNavigateAway.js +0 -0
- package/usePrevious.d.ts +0 -0
- package/usePrevious.js +2 -1
- package/usePreviousRef.d.ts +0 -0
- package/usePreviousRef.js +0 -0
- package/useScrollPosition.d.ts +0 -0
- package/useScrollPosition.js +0 -0
- package/useScrollThreshold.d.ts +0 -0
- package/useScrollThreshold.js +2 -1
- package/useScrollTo.d.ts +0 -0
- package/useScrollTo.js +2 -1
- package/useSmoothScroll.d.ts +0 -0
- package/useSmoothScroll.js +0 -0
- package/useSpinDelay.d.ts +0 -0
- package/useSpinDelay.js +2 -1
- package/useTraceUpdate.d.ts +0 -0
- package/useTraceUpdate.js +2 -1
- package/useUpdateEffect.d.ts +0 -0
- package/useUpdateEffect.js +0 -0
- package/useWindowSize.d.ts +0 -0
- package/useWindowSize.js +3 -2
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { __read } from "tslib";
|
|
1
2
|
import { useState } from "react";
|
|
2
3
|
import { getMediaQueryWidthResolvers, isUndefined, } from "@koine/utils";
|
|
3
4
|
import useIsomorphicLayoutEffect from "./useIsomorphicLayoutEffect.js";
|
|
@@ -5,16 +6,16 @@ export function createUseMediaQueryWidth(customBreakpoints) {
|
|
|
5
6
|
var queryResolvers = getMediaQueryWidthResolvers(customBreakpoints);
|
|
6
7
|
return function useMediaQueryWidth(media, serverValue) {
|
|
7
8
|
var definition = media.substring(1);
|
|
8
|
-
var _a = definition.split("-"), rule = _a[0], ruleBreakpoint = _a[1];
|
|
9
|
+
var _a = __read(definition.split("-"), 2), rule = _a[0], ruleBreakpoint = _a[1];
|
|
9
10
|
if (isUndefined(ruleBreakpoint)) {
|
|
10
11
|
ruleBreakpoint = rule;
|
|
11
12
|
}
|
|
12
13
|
if (isUndefined(rule)) {
|
|
13
14
|
rule = "min";
|
|
14
15
|
}
|
|
15
|
-
var _b = ruleBreakpoint.split("_"), br1 = _b[0], br2 = _b[1];
|
|
16
|
+
var _b = __read(ruleBreakpoint.split("_"), 2), br1 = _b[0], br2 = _b[1];
|
|
16
17
|
var query = queryResolvers[rule](br1, br2);
|
|
17
|
-
var _c = useState(isUndefined(serverValue) ? null : serverValue), matches = _c[0], setMatches = _c[1];
|
|
18
|
+
var _c = __read(useState(isUndefined(serverValue) ? null : serverValue), 2), matches = _c[0], setMatches = _c[1];
|
|
18
19
|
useIsomorphicLayoutEffect(function () {
|
|
19
20
|
var mq = window.matchMedia(query);
|
|
20
21
|
var handleChange = function (event) {
|
package/css/index.d.ts
CHANGED
|
File without changes
|
package/css/index.js
CHANGED
|
File without changes
|
package/extendComponent.d.ts
CHANGED
|
File without changes
|
package/extendComponent.js
CHANGED
|
File without changes
|
package/index.d.ts
CHANGED
|
File without changes
|
package/index.js
CHANGED
|
File without changes
|
package/m/MotionProvider.d.ts
CHANGED
|
File without changes
|
package/m/MotionProvider.js
CHANGED
|
File without changes
|
package/m/index.d.ts
CHANGED
|
File without changes
|
package/m/index.js
CHANGED
|
File without changes
|
package/m/lite.d.ts
CHANGED
|
File without changes
|
package/m/lite.js
CHANGED
|
File without changes
|
package/m/max.d.ts
CHANGED
|
File without changes
|
package/m/max.js
CHANGED
|
File without changes
|
package/mergeRefs.d.ts
CHANGED
|
File without changes
|
package/mergeRefs.js
CHANGED
|
File without changes
|
package/package.json
CHANGED
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
"name": "@koine/react",
|
|
3
3
|
"sideEffects": false,
|
|
4
4
|
"dependencies": {
|
|
5
|
-
"@koine/dom": "2.0.0-beta.
|
|
6
|
-
"@koine/utils": "2.0.0-beta.
|
|
5
|
+
"@koine/dom": "2.0.0-beta.18",
|
|
6
|
+
"@koine/utils": "2.0.0-beta.18"
|
|
7
7
|
},
|
|
8
8
|
"peerDependenciesMeta": {
|
|
9
9
|
"@hookform/resolvers": {
|
|
@@ -655,5 +655,5 @@
|
|
|
655
655
|
}
|
|
656
656
|
},
|
|
657
657
|
"peerDependencies": {},
|
|
658
|
-
"version": "2.0.0-beta.
|
|
658
|
+
"version": "2.0.0-beta.18"
|
|
659
659
|
}
|
package/sc/index.d.ts
CHANGED
|
File without changes
|
package/sc/index.js
CHANGED
|
File without changes
|
package/scm/index.d.ts
CHANGED
|
File without changes
|
package/scm/index.js
CHANGED
|
File without changes
|
package/shared/index.d.ts
CHANGED
|
File without changes
|
package/shared/index.js
CHANGED
|
File without changes
|
package/styles/Body.d.ts
CHANGED
|
File without changes
|
package/styles/Body.js
CHANGED
|
File without changes
|
package/styles/Global.d.ts
CHANGED
|
File without changes
|
package/styles/Global.js
CHANGED
|
File without changes
|
package/styles/index.d.ts
CHANGED
|
File without changes
|
package/styles/index.js
CHANGED
|
File without changes
|
package/styles/media.d.ts
CHANGED
|
File without changes
|
package/styles/media.js
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
var _a;
|
|
2
|
+
import { __read } from "tslib";
|
|
2
3
|
import { useEffect, useState } from "react";
|
|
3
4
|
import { breakpoints, useTheme } from "./theme.js";
|
|
4
5
|
export var min = (_a = generateMediaQueries(breakpoints), _a.min), max = _a.max, up = _a.up, down = _a.down, between = _a.between, only = _a.only;
|
|
5
6
|
export function useMedia(media) {
|
|
6
7
|
var breakpoints = useTheme().breakpoints;
|
|
7
|
-
var _a = useState(false), matches = _a[0], setMatches = _a[1];
|
|
8
|
-
var _b = media.split(":"), _c = _b[0], direction = _c === void 0 ? "min" : _c, breakpoint = _b[1];
|
|
8
|
+
var _a = __read(useState(false), 2), matches = _a[0], setMatches = _a[1];
|
|
9
|
+
var _b = __read(media.split(":"), 2), _c = _b[0], direction = _c === void 0 ? "min" : _c, breakpoint = _b[1];
|
|
9
10
|
var px = breakpoints[breakpoint];
|
|
10
11
|
if (direction === "max") {
|
|
11
12
|
px = px - 0.02;
|
package/styles/spacing.d.ts
CHANGED
|
File without changes
|
package/styles/spacing.js
CHANGED
|
File without changes
|
package/styles/styled.d.ts
CHANGED
|
File without changes
|
package/styles/styled.js
CHANGED
|
File without changes
|
|
File without changes
|
package/styles/theme--vanilla.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { __read } from "tslib";
|
|
1
2
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
3
|
import { createContext, useEffect, useState } from "react";
|
|
3
4
|
import { isBrowser } from "@koine/utils";
|
|
@@ -23,7 +24,7 @@ export var ThemeVanillaContext = createContext({
|
|
|
23
24
|
});
|
|
24
25
|
export var ThemeVanillaProvider = function (_a) {
|
|
25
26
|
var initialTheme = _a.initialTheme, children = _a.children;
|
|
26
|
-
var _b = useState(initialTheme), theme = _b[0], setTheme = _b[1];
|
|
27
|
+
var _b = __read(useState(initialTheme), 2), theme = _b[0], setTheme = _b[1];
|
|
27
28
|
var rawSetTheme = function (rawTheme) {
|
|
28
29
|
if (!rawTheme || !isBrowser) {
|
|
29
30
|
return;
|
package/styles/theme.d.ts
CHANGED
|
File without changes
|
package/styles/theme.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { __assign } from "tslib";
|
|
1
|
+
import { __assign, __read } from "tslib";
|
|
2
2
|
import { useTheme as _useTheme } from "styled-components";
|
|
3
3
|
var DEFAULT_BREAKPOINTS = {
|
|
4
4
|
xs: 0,
|
|
@@ -10,7 +10,7 @@ var DEFAULT_BREAKPOINTS = {
|
|
|
10
10
|
};
|
|
11
11
|
export var breakpoints = process.env["BREAKPOINTS"]
|
|
12
12
|
? process.env["BREAKPOINTS"].split(",").reduce(function (map, pair) {
|
|
13
|
-
var _a = pair.split(":"), key = _a[0], value = _a[1];
|
|
13
|
+
var _a = __read(pair.split(":"), 2), key = _a[0], value = _a[1];
|
|
14
14
|
map[key] = parseFloat(value);
|
|
15
15
|
return map;
|
|
16
16
|
}, {})
|
package/tw/index.d.ts
CHANGED
|
File without changes
|
package/tw/index.js
CHANGED
|
File without changes
|
package/twm/index.d.ts
CHANGED
|
File without changes
|
package/twm/index.js
CHANGED
|
File without changes
|
package/types.d.ts
CHANGED
|
File without changes
|
package/types.js
CHANGED
|
File without changes
|
package/useAsyncFn.d.ts
CHANGED
|
File without changes
|
package/useAsyncFn.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { __assign } from "tslib";
|
|
1
|
+
import { __assign, __read, __spreadArray } from "tslib";
|
|
2
2
|
import { useCallback, useRef, useState } from "react";
|
|
3
3
|
import { useMountedState } from "./useMountedState.js";
|
|
4
4
|
export function useAsyncFn(fn, deps, initialState) {
|
|
@@ -6,7 +6,7 @@ export function useAsyncFn(fn, deps, initialState) {
|
|
|
6
6
|
if (initialState === void 0) { initialState = { loading: false }; }
|
|
7
7
|
var lastCallId = useRef(0);
|
|
8
8
|
var isMounted = useMountedState();
|
|
9
|
-
var _a = useState(initialState), state = _a[0], set = _a[1];
|
|
9
|
+
var _a = __read(useState(initialState), 2), state = _a[0], set = _a[1];
|
|
10
10
|
var callback = useCallback(function () {
|
|
11
11
|
var args = [];
|
|
12
12
|
for (var _i = 0; _i < arguments.length; _i++) {
|
|
@@ -16,7 +16,7 @@ export function useAsyncFn(fn, deps, initialState) {
|
|
|
16
16
|
if (!state.loading) {
|
|
17
17
|
set(function (prevState) { return (__assign(__assign({}, prevState), { loading: true })); });
|
|
18
18
|
}
|
|
19
|
-
return fn.apply(void 0, args).then(function (value) {
|
|
19
|
+
return fn.apply(void 0, __spreadArray([], __read(args), false)).then(function (value) {
|
|
20
20
|
isMounted() &&
|
|
21
21
|
callId === lastCallId.current &&
|
|
22
22
|
set({ value: value, loading: false });
|
package/useDateLocale.d.ts
CHANGED
|
File without changes
|
package/useDateLocale.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { __awaiter, __generator } from "tslib";
|
|
1
|
+
import { __awaiter, __generator, __read } from "tslib";
|
|
2
2
|
import { useEffect, useState } from "react";
|
|
3
3
|
export function useDateLocale(locale, defaultLocale) {
|
|
4
4
|
var _this = this;
|
|
5
5
|
if (defaultLocale === void 0) { defaultLocale = "en"; }
|
|
6
|
-
var _a = useState(), data = _a[0], setData = _a[1];
|
|
7
|
-
var _b = useState(defaultLocale), current = _b[0], setCurrent = _b[1];
|
|
6
|
+
var _a = __read(useState(), 2), data = _a[0], setData = _a[1];
|
|
7
|
+
var _b = __read(useState(defaultLocale), 2), current = _b[0], setCurrent = _b[1];
|
|
8
8
|
useEffect(function () {
|
|
9
9
|
var importLocaleFile = function () { return __awaiter(_this, void 0, void 0, function () {
|
|
10
10
|
var localeToSet;
|
package/useFirstMountState.d.ts
CHANGED
|
File without changes
|
package/useFirstMountState.js
CHANGED
|
File without changes
|
package/useFixedOffset.d.ts
CHANGED
|
File without changes
|
package/useFixedOffset.js
CHANGED
|
File without changes
|
package/useFocus.d.ts
CHANGED
|
File without changes
|
package/useFocus.js
CHANGED
|
File without changes
|
package/useInterval.d.ts
CHANGED
|
File without changes
|
package/useInterval.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { __spreadArray } from "tslib";
|
|
1
|
+
import { __read, __spreadArray } from "tslib";
|
|
2
2
|
import { useEffect, useRef } from "react";
|
|
3
3
|
import { noop } from "@koine/utils";
|
|
4
4
|
export function useInterval(callback, delay, deps) {
|
|
@@ -6,7 +6,7 @@ export function useInterval(callback, delay, deps) {
|
|
|
6
6
|
var savedCallback = useRef();
|
|
7
7
|
useEffect(function () {
|
|
8
8
|
savedCallback.current = callback;
|
|
9
|
-
}, __spreadArray([callback], deps,
|
|
9
|
+
}, __spreadArray([callback], __read(deps), false));
|
|
10
10
|
useEffect(function () {
|
|
11
11
|
function tick() {
|
|
12
12
|
if (savedCallback.current)
|
|
File without changes
|
|
File without changes
|
package/useKeyUp.d.ts
CHANGED
|
File without changes
|
package/useKeyUp.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { __spreadArray } from "tslib";
|
|
1
|
+
import { __read, __spreadArray } from "tslib";
|
|
2
2
|
import { useEffect } from "react";
|
|
3
3
|
import { on } from "@koine/dom";
|
|
4
4
|
export function useKeyUp(callback, deps) {
|
|
@@ -13,6 +13,6 @@ export function useKeyUp(callback, deps) {
|
|
|
13
13
|
}
|
|
14
14
|
});
|
|
15
15
|
return listener;
|
|
16
|
-
}, __spreadArray([callback], deps,
|
|
16
|
+
}, __spreadArray([callback], __read(deps), false));
|
|
17
17
|
}
|
|
18
18
|
export default useKeyUp;
|
package/useMeasure.d.ts
CHANGED
|
File without changes
|
package/useMeasure.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { __spreadArray } from "tslib";
|
|
1
|
+
import { __read, __spreadArray } from "tslib";
|
|
2
2
|
import { useEffect, useMemo, useRef, useState } from "react";
|
|
3
3
|
import { debounce, noop } from "@koine/utils";
|
|
4
4
|
import { listenResizeDebounced, listenScrollDebounced, off, on, } from "@koine/dom";
|
|
@@ -10,7 +10,7 @@ function findScrollContainers(element) {
|
|
|
10
10
|
var _a = window.getComputedStyle(element), overflow = _a.overflow, overflowX = _a.overflowX, overflowY = _a.overflowY;
|
|
11
11
|
if ([overflow, overflowX, overflowY].some(function (prop) { return prop === "auto" || prop === "scroll"; }))
|
|
12
12
|
result.push(element);
|
|
13
|
-
return __spreadArray(__spreadArray([], result,
|
|
13
|
+
return __spreadArray(__spreadArray([], __read(result), false), __read(findScrollContainers(element.parentElement)), false);
|
|
14
14
|
}
|
|
15
15
|
var keys = [
|
|
16
16
|
"x",
|
|
@@ -27,7 +27,7 @@ var areBoundsEqual = function (a, b) {
|
|
|
27
27
|
};
|
|
28
28
|
export function useMeasure(options) {
|
|
29
29
|
var _a = (options || {}).scroll, scroll = _a === void 0 ? false : _a;
|
|
30
|
-
var _b = useState({
|
|
30
|
+
var _b = __read(useState({
|
|
31
31
|
left: 0,
|
|
32
32
|
top: 0,
|
|
33
33
|
width: 0,
|
|
@@ -36,7 +36,7 @@ export function useMeasure(options) {
|
|
|
36
36
|
right: 0,
|
|
37
37
|
x: 0,
|
|
38
38
|
y: 0,
|
|
39
|
-
}), bounds = _b[0], setBounds = _b[1];
|
|
39
|
+
}), 2), bounds = _b[0], setBounds = _b[1];
|
|
40
40
|
var state = useRef([
|
|
41
41
|
null,
|
|
42
42
|
null,
|
|
@@ -48,13 +48,13 @@ export function useMeasure(options) {
|
|
|
48
48
|
mounted.current = true;
|
|
49
49
|
return function () { return void (mounted.current = false); };
|
|
50
50
|
}, []);
|
|
51
|
-
var _c = useMemo(function () {
|
|
51
|
+
var _c = __read(useMemo(function () {
|
|
52
52
|
var callback = function () {
|
|
53
53
|
var _args = [];
|
|
54
54
|
for (var _i = 0; _i < arguments.length; _i++) {
|
|
55
55
|
_args[_i] = arguments[_i];
|
|
56
56
|
}
|
|
57
|
-
var _a = state.current, element = _a[0], lastBounds = _a[3];
|
|
57
|
+
var _a = __read(state.current, 4), element = _a[0], lastBounds = _a[3];
|
|
58
58
|
if (!element)
|
|
59
59
|
return;
|
|
60
60
|
var size = element.getBoundingClientRect();
|
|
@@ -66,9 +66,9 @@ export function useMeasure(options) {
|
|
|
66
66
|
};
|
|
67
67
|
var debouncedCallback = debounce(callback);
|
|
68
68
|
return [callback, debouncedCallback, debouncedCallback];
|
|
69
|
-
}, [setBounds]), forceRefresh = _c[0], scrollChange = _c[2];
|
|
69
|
+
}, [setBounds]), 3), forceRefresh = _c[0], scrollChange = _c[2];
|
|
70
70
|
function removeListeners() {
|
|
71
|
-
var _a = state.current, scrollContainers = _a[1], resizeObserver = _a[2];
|
|
71
|
+
var _a = __read(state.current, 3), scrollContainers = _a[1], resizeObserver = _a[2];
|
|
72
72
|
if (scrollContainers) {
|
|
73
73
|
scrollContainers.forEach(function (element) {
|
|
74
74
|
return off(element, "scroll", scrollChange);
|
|
@@ -81,7 +81,7 @@ export function useMeasure(options) {
|
|
|
81
81
|
}
|
|
82
82
|
}
|
|
83
83
|
function addListeners() {
|
|
84
|
-
var _a = state.current, element = _a[0], scrollContainers = _a[1];
|
|
84
|
+
var _a = __read(state.current, 2), element = _a[0], scrollContainers = _a[1];
|
|
85
85
|
if (!element)
|
|
86
86
|
return;
|
|
87
87
|
if (!observer && ResizeObserver) {
|
package/useMountedState.d.ts
CHANGED
|
File without changes
|
package/useMountedState.js
CHANGED
|
File without changes
|
package/useNavigateAway.d.ts
CHANGED
|
File without changes
|
package/useNavigateAway.js
CHANGED
|
File without changes
|
package/usePrevious.d.ts
CHANGED
|
File without changes
|
package/usePrevious.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
+
import { __read } from "tslib";
|
|
1
2
|
import { useState } from "react";
|
|
2
3
|
export function usePrevious(state, defaulValue) {
|
|
3
|
-
var _a = useState([state, defaulValue]), tuple = _a[0], setTuple = _a[1];
|
|
4
|
+
var _a = __read(useState([state, defaulValue]), 2), tuple = _a[0], setTuple = _a[1];
|
|
4
5
|
if (tuple[1] !== state) {
|
|
5
6
|
setTuple([tuple[1], state]);
|
|
6
7
|
}
|
package/usePreviousRef.d.ts
CHANGED
|
File without changes
|
package/usePreviousRef.js
CHANGED
|
File without changes
|
package/useScrollPosition.d.ts
CHANGED
|
File without changes
|
package/useScrollPosition.js
CHANGED
|
File without changes
|
package/useScrollThreshold.d.ts
CHANGED
|
File without changes
|
package/useScrollThreshold.js
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
|
+
import { __read } from "tslib";
|
|
1
2
|
import { useCallback, useEffect, useState } from "react";
|
|
2
3
|
import { noop } from "@koine/utils";
|
|
3
4
|
import { listenScroll } from "@koine/dom";
|
|
4
5
|
export var useScrollThreshold = function (threshold, callback) {
|
|
5
|
-
var _a = useState(false), isBelow = _a[0], setIsBelow = _a[1];
|
|
6
|
+
var _a = __read(useState(false), 2), isBelow = _a[0], setIsBelow = _a[1];
|
|
6
7
|
var handler = useCallback(function () {
|
|
7
8
|
if (threshold) {
|
|
8
9
|
var posY = window.scrollY;
|
package/useScrollTo.d.ts
CHANGED
|
File without changes
|
package/useScrollTo.js
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
|
+
import { __read } from "tslib";
|
|
1
2
|
import { isBrowser } from "@koine/utils";
|
|
2
3
|
import useHeader from "./Header/useHeader.js";
|
|
3
4
|
export function useScrollTo(id, offset) {
|
|
4
5
|
if (id === void 0) { id = ""; }
|
|
5
6
|
if (offset === void 0) { offset = 0; }
|
|
6
|
-
var _a = useHeader(), headerHeight = _a[2];
|
|
7
|
+
var _a = __read(useHeader(), 3), headerHeight = _a[2];
|
|
7
8
|
if (!isBrowser) {
|
|
8
9
|
return;
|
|
9
10
|
}
|
package/useSmoothScroll.d.ts
CHANGED
|
File without changes
|
package/useSmoothScroll.js
CHANGED
|
File without changes
|
package/useSpinDelay.d.ts
CHANGED
|
File without changes
|
package/useSpinDelay.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { __read } from "tslib";
|
|
1
2
|
import { useEffect, useRef, useState } from "react";
|
|
2
3
|
var State;
|
|
3
4
|
(function (State) {
|
|
@@ -9,7 +10,7 @@ var State;
|
|
|
9
10
|
export function useSpinDelay(loading, delay, minDuration) {
|
|
10
11
|
if (delay === void 0) { delay = 500; }
|
|
11
12
|
if (minDuration === void 0) { minDuration = 200; }
|
|
12
|
-
var _a = useState(State.IDLE), state = _a[0], setState = _a[1];
|
|
13
|
+
var _a = __read(useState(State.IDLE), 2), state = _a[0], setState = _a[1];
|
|
13
14
|
var timeout = useRef();
|
|
14
15
|
useEffect(function () {
|
|
15
16
|
if (loading && state === State.IDLE) {
|
package/useTraceUpdate.d.ts
CHANGED
|
File without changes
|
package/useTraceUpdate.js
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
|
+
import { __read } from "tslib";
|
|
1
2
|
import { useEffect, useRef } from "react";
|
|
2
3
|
export function useTraceUpdate(props) {
|
|
3
4
|
var prev = useRef(props);
|
|
4
5
|
useEffect(function () {
|
|
5
6
|
var changedProps = Object.entries(props).reduce(function (ps, _a) {
|
|
6
|
-
var k =
|
|
7
|
+
var _b = __read(_a, 2), k = _b[0], v = _b[1];
|
|
7
8
|
if (prev.current[k] !== v) {
|
|
8
9
|
ps[k] = [prev.current[k], v];
|
|
9
10
|
}
|
package/useUpdateEffect.d.ts
CHANGED
|
File without changes
|
package/useUpdateEffect.js
CHANGED
|
File without changes
|
package/useWindowSize.d.ts
CHANGED
|
File without changes
|
package/useWindowSize.js
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
|
+
import { __read } from "tslib";
|
|
1
2
|
import { useEffect, useState } from "react";
|
|
2
3
|
import { listenResize, listenResizeDebounced } from "@koine/dom";
|
|
3
4
|
export function useWindowSize(wait, immediate) {
|
|
4
|
-
var _a = useState(0), width = _a[0], widthSet = _a[1];
|
|
5
|
-
var _b = useState(0), height = _b[0], heightSet = _b[1];
|
|
5
|
+
var _a = __read(useState(0), 2), width = _a[0], widthSet = _a[1];
|
|
6
|
+
var _b = __read(useState(0), 2), height = _b[0], heightSet = _b[1];
|
|
6
7
|
useEffect(function () {
|
|
7
8
|
function updateSize() {
|
|
8
9
|
widthSet(window.innerWidth);
|