@onepercentio/one-ui 0.6.2 → 0.6.5
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/cypress/support/e2e.js +20 -18
- package/dist/__test__/analytics.d.ts +3 -3
- package/dist/__test__/analytics.js +18 -18
- package/dist/__test__/firestore.d.ts +2 -2
- package/dist/__test__/firestore.js +25 -25
- package/dist/__test__/utils.d.ts +16 -16
- package/dist/__test__/utils.js +155 -155
- package/dist/components/AdaptiveButton/AdaptiveButton.d.ts +8 -8
- package/dist/components/AdaptiveButton/AdaptiveButton.js +92 -92
- package/dist/components/AdaptiveButton/AdaptiveButton.stories.d.ts +18 -18
- package/dist/components/AdaptiveButton/AdaptiveButton.stories.js +81 -81
- package/dist/components/AdaptiveButton/index.d.ts +1 -1
- package/dist/components/AdaptiveButton/index.js +8 -8
- package/dist/components/AdaptiveDialog/AdaptiveDialog.d.ts +9 -9
- package/dist/components/AdaptiveDialog/AdaptiveDialog.js +59 -59
- package/dist/components/AdaptiveDialog/AdaptiveDialog.stories.d.ts +19 -19
- package/dist/components/AdaptiveDialog/AdaptiveDialog.stories.js +93 -93
- package/dist/components/AdaptiveDialog/AdaptiveDialog.test.d.ts +1 -1
- package/dist/components/AdaptiveDialog/AdaptiveDialog.test.js +14 -14
- package/dist/components/AdaptiveDialog/index.d.ts +1 -1
- package/dist/components/AdaptiveDialog/index.js +8 -8
- package/dist/components/AdaptiveSidebar/AdaptiveSidebar.d.ts +14 -14
- package/dist/components/AdaptiveSidebar/AdaptiveSidebar.js +72 -72
- package/dist/components/AdaptiveSidebar/AdaptiveSidebar.module.scss +1 -0
- package/dist/components/AdaptiveSidebar/AdaptiveSidebar.stories.d.ts +19 -19
- package/dist/components/AdaptiveSidebar/AdaptiveSidebar.stories.js +20 -20
- package/dist/components/AdaptiveSidebar/index.d.ts +1 -1
- package/dist/components/AdaptiveSidebar/index.js +8 -8
- package/dist/components/AnchoredTooltip/AnchoredTooltip.d.ts +13 -13
- package/dist/components/AnchoredTooltip/AnchoredTooltip.js +173 -173
- package/dist/components/AnchoredTooltip/AnchoredTooltip.stories.d.ts +16 -16
- package/dist/components/AnchoredTooltip/AnchoredTooltip.stories.js +85 -85
- package/dist/components/AnchoredTooltip/AnchoredTooltip.test.d.ts +1 -1
- package/dist/components/AnchoredTooltip/AnchoredTooltip.test.js +19 -19
- package/dist/components/AnchoredTooltip/index.d.ts +1 -1
- package/dist/components/AnchoredTooltip/index.js +8 -8
- package/dist/components/AnimatedEntrance/AnimatedEntrance.d.ts +18 -18
- package/dist/components/AnimatedEntrance/AnimatedEntrance.js +125 -125
- package/dist/components/AnimatedEntrance/AnimatedEntrance.js.map +1 -1
- package/dist/components/AnimatedEntrance/AnimatedEntrance.stories.d.ts +14 -14
- package/dist/components/AnimatedEntrance/AnimatedEntrance.stories.js +66 -66
- package/dist/components/AnimatedEntrance/index.d.ts +1 -1
- package/dist/components/AnimatedEntrance/index.js +8 -8
- package/dist/components/AsyncWrapper/AsyncWrapper.d.ts +10 -10
- package/dist/components/AsyncWrapper/AsyncWrapper.js +24 -24
- package/dist/components/AsyncWrapper/AsyncWrapper.stories.d.ts +18 -18
- package/dist/components/AsyncWrapper/AsyncWrapper.stories.js +33 -33
- package/dist/components/AsyncWrapper/AsyncWrapper.test.d.ts +1 -1
- package/dist/components/AsyncWrapper/AsyncWrapper.test.js +18 -18
- package/dist/components/AsyncWrapper/index.d.ts +1 -1
- package/dist/components/AsyncWrapper/index.js +8 -8
- package/dist/components/Avatar/Avatar.d.ts +8 -8
- package/dist/components/Avatar/Avatar.js +44 -44
- package/dist/components/Avatar/Avatar.js.map +1 -1
- package/dist/components/Avatar/Avatar.module.scss +17 -14
- package/dist/components/Avatar/Avatar.stories.d.ts +14 -14
- package/dist/components/Avatar/Avatar.stories.js +18 -18
- package/dist/components/Avatar/Avatar.test.d.ts +1 -1
- package/dist/components/Avatar/Avatar.test.js +35 -35
- package/dist/components/Avatar/index.d.ts +1 -1
- package/dist/components/Avatar/index.js +8 -8
- package/dist/components/BucketFill/BucketFill.d.ts +12 -12
- package/dist/components/BucketFill/BucketFill.js +65 -65
- package/dist/components/BucketFill/BucketFill.stories.d.ts +17 -17
- package/dist/components/BucketFill/BucketFill.stories.js +140 -140
- package/dist/components/BucketFill/index.d.ts +1 -1
- package/dist/components/BucketFill/index.js +8 -8
- package/dist/components/Button/Button.d.ts +14 -14
- package/dist/components/Button/Button.js +51 -51
- package/dist/components/Button/Button.stories.d.ts +9 -9
- package/dist/components/Button/Button.stories.js +57 -57
- package/dist/components/Button/Button.test.d.ts +1 -1
- package/dist/components/Button/Button.test.js +14 -14
- package/dist/components/Button/index.d.ts +1 -1
- package/dist/components/Button/index.js +8 -8
- package/dist/components/Card/Card.d.ts +7 -7
- package/dist/components/Card/Card.js +14 -14
- package/dist/components/Card/Card.stories.d.ts +15 -15
- package/dist/components/Card/Card.stories.js +15 -15
- package/dist/components/Card/index.d.ts +1 -1
- package/dist/components/Card/index.js +8 -8
- package/dist/components/CheckBox/CheckBox.d.ts +11 -11
- package/dist/components/CheckBox/CheckBox.js +31 -31
- package/dist/components/CheckBox/CheckBox.stories.d.ts +20 -20
- package/dist/components/CheckBox/CheckBox.stories.js +52 -52
- package/dist/components/CheckBox/index.d.ts +1 -1
- package/dist/components/CheckBox/index.js +8 -8
- package/dist/components/Collapsable/Collapsable.d.ts +31 -31
- package/dist/components/Collapsable/Collapsable.js +126 -126
- package/dist/components/Collapsable/Collapsable.stories.d.ts +39 -39
- package/dist/components/Collapsable/Collapsable.stories.js +27 -27
- package/dist/components/Collapsable/index.d.ts +1 -1
- package/dist/components/Collapsable/index.js +8 -8
- package/dist/components/Countdown/Countdown.d.ts +13 -13
- package/dist/components/Countdown/Countdown.js +79 -79
- package/dist/components/Countdown/Countdown.stories.d.ts +14 -14
- package/dist/components/Countdown/Countdown.stories.js +54 -54
- package/dist/components/Countdown/index.d.ts +1 -1
- package/dist/components/Countdown/index.js +8 -8
- package/dist/components/Divider/Divider.d.ts +6 -6
- package/dist/components/Divider/Divider.js +15 -15
- package/dist/components/Divider/Divider.stories.d.ts +7 -7
- package/dist/components/Divider/Divider.stories.js +14 -14
- package/dist/components/Divider/index.d.ts +1 -1
- package/dist/components/Divider/index.js +8 -8
- package/dist/components/EmailInput/EmailInput.d.ts +25 -25
- package/dist/components/EmailInput/EmailInput.js +51 -51
- package/dist/components/EmailInput/EmailInput.stories.d.ts +28 -28
- package/dist/components/EmailInput/EmailInput.stories.js +14 -14
- package/dist/components/EmailInput/EmailInput.test.d.ts +1 -1
- package/dist/components/EmailInput/EmailInput.test.js +76 -76
- package/dist/components/EmailInput/index.d.ts +1 -1
- package/dist/components/EmailInput/index.js +9 -9
- package/dist/components/FadeIn/FadeIn.d.ts +10 -10
- package/dist/components/FadeIn/FadeIn.js +63 -63
- package/dist/components/FadeIn/FadeIn.stories.d.ts +24 -24
- package/dist/components/FadeIn/FadeIn.stories.js +15 -15
- package/dist/components/FadeIn/FadeIn.test.d.ts +1 -1
- package/dist/components/FadeIn/FadeIn.test.js +21 -21
- package/dist/components/FadeIn/index.d.ts +1 -1
- package/dist/components/FadeIn/index.js +8 -8
- package/dist/components/FileInput/FileInput.d.ts +13 -13
- package/dist/components/FileInput/FileInput.js +74 -74
- package/dist/components/FileInput/FileInput.stories.d.ts +19 -19
- package/dist/components/FileInput/FileInput.stories.js +58 -58
- package/dist/components/FileInput/index.d.ts +1 -1
- package/dist/components/FileInput/index.js +8 -8
- package/dist/components/FlowController/FlowController.d.ts +23 -23
- package/dist/components/FlowController/FlowController.js +33 -33
- package/dist/components/FlowController/FlowController.stories.d.ts +43 -43
- package/dist/components/FlowController/FlowController.stories.js +100 -100
- package/dist/components/FlowController/FlowController.test.d.ts +1 -1
- package/dist/components/FlowController/FlowController.test.js +165 -165
- package/dist/components/FlowController/index.d.ts +1 -1
- package/dist/components/FlowController/index.js +8 -8
- package/dist/components/Form/Form.d.ts +48 -48
- package/dist/components/Form/Form.js +101 -101
- package/dist/components/Form/Form.stories.d.ts +13 -13
- package/dist/components/Form/Form.stories.js +35 -35
- package/dist/components/Form/index.d.ts +1 -1
- package/dist/components/Form/index.js +8 -8
- package/dist/components/Freeze/Freeze.d.ts +5 -5
- package/dist/components/Freeze/Freeze.js +12 -12
- package/dist/components/Freeze/Freeze.stories.d.ts +7 -7
- package/dist/components/Freeze/Freeze.stories.js +55 -55
- package/dist/components/Freeze/Freeze.test.d.ts +1 -1
- package/dist/components/Freeze/Freeze.test.js +14 -14
- package/dist/components/Freeze/index.d.ts +1 -1
- package/dist/components/Freeze/index.js +8 -8
- package/dist/components/HSForms/HSForms.d.ts +5 -5
- package/dist/components/HSForms/HSForms.js +46 -46
- package/dist/components/HSForms/index.d.ts +1 -1
- package/dist/components/HSForms/index.js +8 -8
- package/dist/components/Header/Header.d.ts +25 -25
- package/dist/components/Header/Header.js +74 -74
- package/dist/components/Header/Header.stories.d.ts +28 -28
- package/dist/components/Header/Header.stories.js +40 -40
- package/dist/components/Header/Header.test.d.ts +1 -1
- package/dist/components/Header/Header.test.js +99 -99
- package/dist/components/Header/index.d.ts +1 -1
- package/dist/components/Header/index.js +8 -8
- package/dist/components/HeaderCloseBtn/HeaderCloseBtn.d.ts +8 -8
- package/dist/components/HeaderCloseBtn/HeaderCloseBtn.js +16 -16
- package/dist/components/HeaderCloseBtn/HeaderCloseBtn.stories.d.ts +14 -14
- package/dist/components/HeaderCloseBtn/HeaderCloseBtn.stories.js +15 -15
- package/dist/components/HeaderCloseBtn/index.d.ts +1 -1
- package/dist/components/HeaderCloseBtn/index.js +8 -8
- package/dist/components/InfinityScroll/InfinityScroll.d.ts +11 -11
- package/dist/components/InfinityScroll/InfinityScroll.js +111 -111
- package/dist/components/InfinityScroll/InfinityScroll.stories.d.ts +23 -23
- package/dist/components/InfinityScroll/InfinityScroll.stories.js +53 -53
- package/dist/components/InfinityScroll/InfinityScroll.test.d.ts +1 -1
- package/dist/components/InfinityScroll/InfinityScroll.test.js +188 -188
- package/dist/components/InfinityScroll/index.d.ts +1 -1
- package/dist/components/InfinityScroll/index.js +8 -8
- package/dist/components/Input/Input.d.ts +34 -34
- package/dist/components/Input/Input.js +95 -95
- package/dist/components/Input/Input.stories.d.ts +24 -24
- package/dist/components/Input/Input.stories.js +20 -20
- package/dist/components/Input/Input.test.d.ts +1 -1
- package/dist/components/Input/Input.test.js +57 -57
- package/dist/components/Input/index.d.ts +1 -1
- package/dist/components/Input/index.js +8 -8
- package/dist/components/InstantCounter/InstantCounter.d.ts +13 -13
- package/dist/components/InstantCounter/InstantCounter.js +58 -58
- package/dist/components/InstantCounter/InstantCounter.stories.d.ts +41 -41
- package/dist/components/InstantCounter/InstantCounter.stories.js +60 -60
- package/dist/components/InstantCounter/InstantCounter.test.d.ts +1 -1
- package/dist/components/InstantCounter/InstantCounter.test.js +49 -49
- package/dist/components/InstantCounter/index.d.ts +1 -1
- package/dist/components/InstantCounter/index.js +8 -8
- package/dist/components/LinkToId/LinkToId.d.ts +10 -10
- package/dist/components/LinkToId/LinkToId.js +32 -32
- package/dist/components/LinkToId/LinkToId.stories.d.ts +7 -7
- package/dist/components/LinkToId/LinkToId.stories.js +14 -14
- package/dist/components/LinkToId/LinkToId.test.d.ts +1 -1
- package/dist/components/LinkToId/LinkToId.test.js +11 -11
- package/dist/components/LinkToId/index.d.ts +1 -1
- package/dist/components/LinkToId/index.js +9 -9
- package/dist/components/Loader/Loader.d.ts +6 -6
- package/dist/components/Loader/Loader.js +17 -17
- package/dist/components/Loader/Loader.stories.d.ts +12 -12
- package/dist/components/Loader/Loader.stories.js +15 -15
- package/dist/components/Loader/index.d.ts +1 -1
- package/dist/components/Loader/index.js +8 -8
- package/dist/components/LoaderDotsIndicator/LoaderDotsIndicator.d.ts +6 -6
- package/dist/components/LoaderDotsIndicator/LoaderDotsIndicator.js +41 -41
- package/dist/components/LoaderDotsIndicator/LoaderDotsIndicator.stories.d.ts +7 -7
- package/dist/components/LoaderDotsIndicator/LoaderDotsIndicator.stories.js +14 -14
- package/dist/components/LoaderDotsIndicator/index.d.ts +1 -1
- package/dist/components/LoaderDotsIndicator/index.js +8 -8
- package/dist/components/MainGrid/MainGrid.d.ts +10 -10
- package/dist/components/MainGrid/MainGrid.js +55 -55
- package/dist/components/MainGrid/MainGrid.stories.d.ts +14 -14
- package/dist/components/MainGrid/MainGrid.stories.js +69 -69
- package/dist/components/MainGrid/MainGrid.test.d.ts +1 -1
- package/dist/components/MainGrid/MainGrid.test.js +17 -17
- package/dist/components/MainGrid/index.d.ts +1 -1
- package/dist/components/MainGrid/index.js +8 -8
- package/dist/components/MutableHamburgerButton/MutableHamburgerButton.d.ts +8 -8
- package/dist/components/MutableHamburgerButton/MutableHamburgerButton.js +29 -29
- package/dist/components/MutableHamburgerButton/MutableHamburgerButton.stories.d.ts +21 -21
- package/dist/components/MutableHamburgerButton/MutableHamburgerButton.stories.js +73 -73
- package/dist/components/MutableHamburgerButton/index.d.ts +1 -1
- package/dist/components/MutableHamburgerButton/index.js +8 -8
- package/dist/components/Notification/Notification.d.ts +7 -7
- package/dist/components/Notification/Notification.js +15 -15
- package/dist/components/Notification/Notification.stories.d.ts +15 -15
- package/dist/components/Notification/Notification.stories.js +18 -18
- package/dist/components/Notification/index.d.ts +1 -1
- package/dist/components/Notification/index.js +8 -8
- package/dist/components/Parallax/Parallax.d.ts +15 -15
- package/dist/components/Parallax/Parallax.js +174 -174
- package/dist/components/Parallax/Parallax.stories.d.ts +32 -32
- package/dist/components/Parallax/Parallax.stories.js +22 -22
- package/dist/components/Parallax/Parallax.test.d.ts +1 -1
- package/dist/components/Parallax/Parallax.test.js +21 -21
- package/dist/components/Parallax/index.d.ts +1 -1
- package/dist/components/Parallax/index.js +8 -8
- package/dist/components/Parallax/math/helpers.d.ts +58 -58
- package/dist/components/Parallax/math/helpers.js +228 -228
- package/dist/components/PasswordInput/PasswordInput.d.ts +42 -42
- package/dist/components/PasswordInput/PasswordInput.js +105 -105
- package/dist/components/PasswordInput/PasswordInput.stories.d.ts +45 -45
- package/dist/components/PasswordInput/PasswordInput.stories.js +21 -21
- package/dist/components/PasswordInput/PasswordInput.test.d.ts +1 -1
- package/dist/components/PasswordInput/PasswordInput.test.js +156 -156
- package/dist/components/PasswordInput/index.d.ts +1 -1
- package/dist/components/PasswordInput/index.js +8 -8
- package/dist/components/PixelatedScan/PixelatedScan.d.ts +8 -8
- package/dist/components/PixelatedScan/PixelatedScan.js +104 -104
- package/dist/components/PixelatedScan/PixelatedScan.stories.d.ts +15 -15
- package/dist/components/PixelatedScan/PixelatedScan.stories.js +39 -39
- package/dist/components/PixelatedScan/index.d.ts +1 -1
- package/dist/components/PixelatedScan/index.js +8 -8
- package/dist/components/Portal/Portal.d.ts +11 -11
- package/dist/components/Portal/Portal.js +61 -61
- package/dist/components/Portal/Portal.stories.d.ts +7 -7
- package/dist/components/Portal/Portal.stories.js +14 -14
- package/dist/components/Portal/index.d.ts +1 -1
- package/dist/components/Portal/index.js +9 -9
- package/dist/components/ProgressTexts/ProgressTexts.d.ts +22 -22
- package/dist/components/ProgressTexts/ProgressTexts.js +37 -37
- package/dist/components/ProgressTexts/ProgressTexts.stories.d.ts +24 -24
- package/dist/components/ProgressTexts/ProgressTexts.stories.js +89 -89
- package/dist/components/ProgressTexts/ProgressTexts.test.d.ts +1 -1
- package/dist/components/ProgressTexts/ProgressTexts.test.js +51 -51
- package/dist/components/ProgressTexts/index.d.ts +1 -1
- package/dist/components/ProgressTexts/index.js +8 -8
- package/dist/components/SectionContainer/SectionContainer.d.ts +11 -11
- package/dist/components/SectionContainer/SectionContainer.js +45 -45
- package/dist/components/SectionContainer/SectionContainer.stories.d.ts +14 -14
- package/dist/components/SectionContainer/SectionContainer.stories.js +14 -14
- package/dist/components/SectionContainer/index.d.ts +1 -1
- package/dist/components/SectionContainer/index.js +8 -8
- package/dist/components/Select/Select.d.ts +22 -22
- package/dist/components/Select/Select.js +75 -75
- package/dist/components/Select/Select.stories.d.ts +56 -56
- package/dist/components/Select/Select.stories.js +33 -33
- package/dist/components/Select/Select.test.d.ts +1 -1
- package/dist/components/Select/Select.test.js +11 -11
- package/dist/components/Select/index.d.ts +1 -1
- package/dist/components/Select/index.js +8 -8
- package/dist/components/Spacing/Spacing.d.ts +6 -6
- package/dist/components/Spacing/Spacing.js +14 -14
- package/dist/components/Spacing/Spacing.stories.d.ts +7 -7
- package/dist/components/Spacing/Spacing.stories.js +34 -34
- package/dist/components/Spacing/index.d.ts +1 -1
- package/dist/components/Spacing/index.js +8 -8
- package/dist/components/Table/Table.d.ts +19 -19
- package/dist/components/Table/Table.js +87 -87
- package/dist/components/Table/Table.stories.d.ts +15 -15
- package/dist/components/Table/Table.stories.js +87 -87
- package/dist/components/Table/Table.test.d.ts +1 -1
- package/dist/components/Table/Table.test.js +34 -34
- package/dist/components/Table/index.d.ts +1 -1
- package/dist/components/Table/index.js +8 -8
- package/dist/components/Tabs/Tabs.d.ts +11 -11
- package/dist/components/Tabs/Tabs.js +48 -48
- package/dist/components/Tabs/Tabs.stories.d.ts +17 -17
- package/dist/components/Tabs/Tabs.stories.js +56 -56
- package/dist/components/Tabs/Tabs.test.d.ts +1 -1
- package/dist/components/Tabs/Tabs.test.js +38 -38
- package/dist/components/Tabs/index.d.ts +1 -1
- package/dist/components/Tabs/index.js +8 -8
- package/dist/components/Text/Text.d.ts +15 -15
- package/dist/components/Text/Text.js +53 -53
- package/dist/components/Text/Text.stories.d.ts +7 -7
- package/dist/components/Text/Text.stories.js +42 -42
- package/dist/components/Text/Text.test.d.ts +1 -1
- package/dist/components/Text/Text.test.js +11 -11
- package/dist/components/Text/index.d.ts +1 -1
- package/dist/components/Text/index.js +8 -8
- package/dist/components/Transition/Transition.d.ts +45 -45
- package/dist/components/Transition/Transition.js +267 -242
- package/dist/components/Transition/Transition.js.map +1 -1
- package/dist/components/Transition/Transition.stories.d.ts +10 -10
- package/dist/components/Transition/Transition.stories.js +28 -28
- package/dist/components/Transition/Transition.test.d.ts +1 -1
- package/dist/components/Transition/Transition.test.js +54 -54
- package/dist/components/Transition/index.d.ts +1 -1
- package/dist/components/Transition/index.js +9 -9
- package/dist/components/UncontrolledTransition/UncontrolledTransition.d.ts +13 -13
- package/dist/components/UncontrolledTransition/UncontrolledTransition.js +93 -88
- package/dist/components/UncontrolledTransition/UncontrolledTransition.js.map +1 -1
- package/dist/components/UncontrolledTransition/UncontrolledTransition.stories.d.ts +33 -33
- package/dist/components/UncontrolledTransition/UncontrolledTransition.stories.js +224 -224
- package/dist/components/UncontrolledTransition/UncontrolledTransition.test.d.ts +1 -1
- package/dist/components/UncontrolledTransition/UncontrolledTransition.test.js +134 -134
- package/dist/components/UncontrolledTransition/index.d.ts +1 -1
- package/dist/components/UncontrolledTransition/index.js +8 -8
- package/dist/components/WalletConnectionWrapper/WalletConnectionWrapper.d.ts +52 -52
- package/dist/components/WalletConnectionWrapper/WalletConnectionWrapper.js +120 -120
- package/dist/components/WalletConnectionWrapper/WalletConnectionWrapper.stories.d.ts +70 -70
- package/dist/components/WalletConnectionWrapper/WalletConnectionWrapper.stories.js +64 -64
- package/dist/components/WalletConnectionWrapper/WalletConnectionWrapper.test.d.ts +1 -1
- package/dist/components/WalletConnectionWrapper/WalletConnectionWrapper.test.js +136 -136
- package/dist/components/WalletConnectionWrapper/index.d.ts +1 -1
- package/dist/components/WalletConnectionWrapper/index.js +9 -9
- package/dist/components/utilitary/ScrollAndFocusLock/ScrollAndFocusLock.d.ts +7 -7
- package/dist/components/utilitary/ScrollAndFocusLock/ScrollAndFocusLock.js +74 -74
- package/dist/components/utilitary/ScrollAndFocusLock/index.d.ts +1 -1
- package/dist/components/utilitary/ScrollAndFocusLock/index.js +8 -8
- package/dist/context/CustomBrowserRouter.d.ts +5 -5
- package/dist/context/CustomBrowserRouter.js +53 -53
- package/dist/context/OneUIProvider.d.ts +69 -69
- package/dist/context/OneUIProvider.js +62 -62
- package/dist/context/OneUIProvider.test.d.ts +1 -1
- package/dist/context/OneUIProvider.test.js +44 -44
- package/dist/context/__mocks__/OneUIProvider.d.ts +67 -67
- package/dist/context/__mocks__/OneUIProvider.js +12 -12
- package/dist/hooks/shims/ObjectWatchShim.js +51 -51
- package/dist/hooks/useAsyncControl.d.ts +9 -9
- package/dist/hooks/useAsyncControl.js +39 -39
- package/dist/hooks/useCustomHistory.d.ts +14 -14
- package/dist/hooks/useCustomHistory.js +14 -14
- package/dist/hooks/useCustomHistory.js.map +1 -1
- package/dist/hooks/useFirestoreWatch.d.ts +12 -12
- package/dist/hooks/useFirestoreWatch.js +37 -37
- package/dist/hooks/useForm.d.ts +16 -16
- package/dist/hooks/useForm.js +23 -23
- package/dist/hooks/useIntersection.d.ts +4 -4
- package/dist/hooks/useIntersection.js +29 -29
- package/dist/hooks/useObserve.d.ts +2 -2
- package/dist/hooks/useObserve.js +17 -17
- package/dist/hooks/usePagination.d.ts +19 -19
- package/dist/hooks/usePagination.js +64 -64
- package/dist/hooks/usePooledOperation.d.ts +15 -15
- package/dist/hooks/usePooledOperation.js +63 -63
- package/dist/hooks/usePooling.d.ts +17 -16
- package/dist/hooks/usePooling.js +49 -46
- package/dist/hooks/usePooling.js.map +1 -1
- package/dist/hooks/usePooling.test.d.ts +1 -1
- package/dist/hooks/usePooling.test.js +103 -103
- package/dist/hooks/useRebound.d.ts +9 -9
- package/dist/hooks/useRebound.js +23 -23
- package/dist/hooks/useShortIntl.d.ts +15 -15
- package/dist/hooks/useShortIntl.js +37 -37
- package/dist/models/GenericContract.d.ts +74 -66
- package/dist/models/GenericContract.js +13 -13
- package/dist/models/GenericContract.js.map +1 -1
- package/dist/storybookUtils/index.d.ts +5 -5
- package/dist/storybookUtils/index.js +26 -26
- package/package.json +3 -4
- package/scripts/start-emulator.js +0 -0
- package/dist/components/AsyncProcessQueue/AsyncProcessQueue.d.ts +0 -4
- package/dist/components/AsyncProcessQueue/AsyncProcessQueue.js +0 -14
- package/dist/components/AsyncProcessQueue/AsyncProcessQueue.js.map +0 -1
- package/dist/components/AsyncProcessQueue/AsyncProcessQueue.module.scss +0 -0
- package/dist/components/AsyncProcessQueue/AsyncProcessQueue.stories.d.ts +0 -10
- package/dist/components/AsyncProcessQueue/AsyncProcessQueue.stories.js +0 -16
- package/dist/components/AsyncProcessQueue/AsyncProcessQueue.stories.js.map +0 -1
- package/dist/components/AsyncProcessQueue/index.d.ts +0 -1
- package/dist/components/AsyncProcessQueue/index.js +0 -9
- package/dist/components/AsyncProcessQueue/index.js.map +0 -1
- package/dist/components/WalletConnectionWrapper/v2/WalletConnectionWrapper.d.ts +0 -40
- package/dist/components/WalletConnectionWrapper/v2/WalletConnectionWrapper.js +0 -130
- package/dist/components/WalletConnectionWrapper/v2/WalletConnectionWrapper.js.map +0 -1
- package/dist/components/WalletConnectionWrapper/v2/WalletConnectionWrapper.stories.d.ts +0 -59
- package/dist/components/WalletConnectionWrapper/v2/WalletConnectionWrapper.stories.js +0 -62
- package/dist/components/WalletConnectionWrapper/v2/WalletConnectionWrapper.stories.js.map +0 -1
- package/dist/components/WalletConnectionWrapper/v2/index.d.ts +0 -1
- package/dist/components/WalletConnectionWrapper/v2/index.js +0 -9
- package/dist/components/WalletConnectionWrapper/v2/index.js.map +0 -1
- package/dist/components/WalletConnectionWrapper/v2/rLoginConfig.d.ts +0 -6
- package/dist/components/WalletConnectionWrapper/v2/rLoginConfig.js +0 -52
- package/dist/components/WalletConnectionWrapper/v2/rLoginConfig.js.map +0 -1
- package/dist/context/AsyncProcessQueue.d.ts +0 -10
- package/dist/context/AsyncProcessQueue.js +0 -16
- package/dist/context/AsyncProcessQueue.js.map +0 -1
- package/dist/hooks/useImprovedHistory.d.ts +0 -0
- package/dist/hooks/useImprovedHistory.js +0 -2
- package/dist/hooks/useImprovedHistory.js.map +0 -1
- package/dist/hooks/useScrollLock.d.ts +0 -0
- package/dist/hooks/useScrollLock.js +0 -2
- package/dist/hooks/useScrollLock.js.map +0 -1
|
@@ -1,34 +1,34 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.InitialImplementation = void 0;
|
|
7
|
-
const react_1 = __importDefault(require("react"));
|
|
8
|
-
const OneUIProvider_1 = __importDefault(require("../../context/OneUIProvider"));
|
|
9
|
-
const Loader_1 = __importDefault(require("../Loader"));
|
|
10
|
-
const AsyncWrapper_1 = __importDefault(require("./AsyncWrapper"));
|
|
11
|
-
exports.default = {
|
|
12
|
-
component: AsyncWrapper_1.default,
|
|
13
|
-
title: "Async Wrapper",
|
|
14
|
-
};
|
|
15
|
-
const InitialImplementation = (args) => (react_1.default.createElement(OneUIProvider_1.default, { config: {
|
|
16
|
-
component: {
|
|
17
|
-
asyncWrapper: {
|
|
18
|
-
LoadingComponent: () => react_1.default.createElement(Loader_1.default, null),
|
|
19
|
-
messages: {
|
|
20
|
-
error: {
|
|
21
|
-
title: "Exemplo de error",
|
|
22
|
-
retryBtn: "Tentar novamente",
|
|
23
|
-
},
|
|
24
|
-
},
|
|
25
|
-
},
|
|
26
|
-
},
|
|
27
|
-
} },
|
|
28
|
-
react_1.default.createElement(AsyncWrapper_1.default, Object.assign({}, args))));
|
|
29
|
-
exports.InitialImplementation = InitialImplementation;
|
|
30
|
-
exports.InitialImplementation.args = {
|
|
31
|
-
loading: true,
|
|
32
|
-
error: false
|
|
33
|
-
};
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.InitialImplementation = void 0;
|
|
7
|
+
const react_1 = __importDefault(require("react"));
|
|
8
|
+
const OneUIProvider_1 = __importDefault(require("../../context/OneUIProvider"));
|
|
9
|
+
const Loader_1 = __importDefault(require("../Loader"));
|
|
10
|
+
const AsyncWrapper_1 = __importDefault(require("./AsyncWrapper"));
|
|
11
|
+
exports.default = {
|
|
12
|
+
component: AsyncWrapper_1.default,
|
|
13
|
+
title: "Async Wrapper",
|
|
14
|
+
};
|
|
15
|
+
const InitialImplementation = (args) => (react_1.default.createElement(OneUIProvider_1.default, { config: {
|
|
16
|
+
component: {
|
|
17
|
+
asyncWrapper: {
|
|
18
|
+
LoadingComponent: () => react_1.default.createElement(Loader_1.default, null),
|
|
19
|
+
messages: {
|
|
20
|
+
error: {
|
|
21
|
+
title: "Exemplo de error",
|
|
22
|
+
retryBtn: "Tentar novamente",
|
|
23
|
+
},
|
|
24
|
+
},
|
|
25
|
+
},
|
|
26
|
+
},
|
|
27
|
+
} },
|
|
28
|
+
react_1.default.createElement(AsyncWrapper_1.default, Object.assign({}, args))));
|
|
29
|
+
exports.InitialImplementation = InitialImplementation;
|
|
30
|
+
exports.InitialImplementation.args = {
|
|
31
|
+
loading: true,
|
|
32
|
+
error: false
|
|
33
|
+
};
|
|
34
34
|
//# sourceMappingURL=AsyncWrapper.stories.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export {};
|
|
1
|
+
export {};
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const react_1 = __importDefault(require("react"));
|
|
7
|
-
const react_2 = require("@testing-library/react");
|
|
8
|
-
const AsyncWrapper_stories_1 = require("./AsyncWrapper.stories");
|
|
9
|
-
function renderScreen(props) {
|
|
10
|
-
return (0, react_2.render)(react_1.default.createElement(AsyncWrapper_stories_1.InitialImplementation, Object.assign({}, props)));
|
|
11
|
-
}
|
|
12
|
-
it('Should at least render :)', () => {
|
|
13
|
-
renderScreen({});
|
|
14
|
-
});
|
|
15
|
-
it.todo("Should show the modal when ther is error");
|
|
16
|
-
it.todo("Should show the loading screen when it's loading");
|
|
17
|
-
it.todo("Should be able to retry");
|
|
18
|
-
it.todo("Should be able to exit without retrying");
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const react_1 = __importDefault(require("react"));
|
|
7
|
+
const react_2 = require("@testing-library/react");
|
|
8
|
+
const AsyncWrapper_stories_1 = require("./AsyncWrapper.stories");
|
|
9
|
+
function renderScreen(props) {
|
|
10
|
+
return (0, react_2.render)(react_1.default.createElement(AsyncWrapper_stories_1.InitialImplementation, Object.assign({}, props)));
|
|
11
|
+
}
|
|
12
|
+
it('Should at least render :)', () => {
|
|
13
|
+
renderScreen({});
|
|
14
|
+
});
|
|
15
|
+
it.todo("Should show the modal when ther is error");
|
|
16
|
+
it.todo("Should show the loading screen when it's loading");
|
|
17
|
+
it.todo("Should be able to retry");
|
|
18
|
+
it.todo("Should be able to exit without retrying");
|
|
19
19
|
//# sourceMappingURL=AsyncWrapper.test.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { default } from './AsyncWrapper';
|
|
1
|
+
export { default } from './AsyncWrapper';
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.default = void 0;
|
|
7
|
-
var AsyncWrapper_1 = require("./AsyncWrapper");
|
|
8
|
-
Object.defineProperty(exports, "default", { enumerable: true, get: function () { return __importDefault(AsyncWrapper_1).default; } });
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
var AsyncWrapper_1 = require("./AsyncWrapper");
|
|
8
|
+
Object.defineProperty(exports, "default", { enumerable: true, get: function () { return __importDefault(AsyncWrapper_1).default; } });
|
|
9
9
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* A simple avatar that shows the image of the user or it's initials as fallback
|
|
3
|
-
**/
|
|
4
|
-
export default function Avatar({ name, imgSrc, size, }: {
|
|
5
|
-
imgSrc?: string;
|
|
6
|
-
name: string;
|
|
7
|
-
size?: number;
|
|
8
|
-
}): JSX.Element;
|
|
1
|
+
/**
|
|
2
|
+
* A simple avatar that shows the image of the user or it's initials as fallback
|
|
3
|
+
**/
|
|
4
|
+
export default function Avatar({ name, imgSrc, size, }: {
|
|
5
|
+
imgSrc?: string;
|
|
6
|
+
name: string;
|
|
7
|
+
size?: number;
|
|
8
|
+
}): JSX.Element;
|
|
@@ -1,45 +1,45 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
-
if (mod && mod.__esModule) return mod;
|
|
20
|
-
var result = {};
|
|
21
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
-
__setModuleDefault(result, mod);
|
|
23
|
-
return result;
|
|
24
|
-
};
|
|
25
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
26
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
27
|
-
};
|
|
28
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
-
const react_1 = __importStar(require("react"));
|
|
30
|
-
const Avatar_module_scss_1 = __importDefault(require("./Avatar.module.scss"));
|
|
31
|
-
/**
|
|
32
|
-
* A simple avatar that shows the image of the user or it's initials as fallback
|
|
33
|
-
**/
|
|
34
|
-
function Avatar({ name, imgSrc, size = 48, }) {
|
|
35
|
-
const initials = (0, react_1.useMemo)(() => {
|
|
36
|
-
const nameParts = name.trim().split(" ");
|
|
37
|
-
if (nameParts.length === 1)
|
|
38
|
-
return nameParts[0].charAt(0).toUpperCase();
|
|
39
|
-
const [firstName, lastName] = [nameParts[0], nameParts.slice(-1)[0]];
|
|
40
|
-
return `${firstName.charAt(0)}${lastName.charAt(0)}`.toUpperCase();
|
|
41
|
-
}, [name]);
|
|
42
|
-
return (react_1.default.createElement("div", { className: Avatar_module_scss_1.default.container
|
|
43
|
-
}
|
|
44
|
-
exports.default = Avatar;
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
25
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
26
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
27
|
+
};
|
|
28
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
+
const react_1 = __importStar(require("react"));
|
|
30
|
+
const Avatar_module_scss_1 = __importDefault(require("./Avatar.module.scss"));
|
|
31
|
+
/**
|
|
32
|
+
* A simple avatar that shows the image of the user or it's initials as fallback
|
|
33
|
+
**/
|
|
34
|
+
function Avatar({ name, imgSrc, size = 48, }) {
|
|
35
|
+
const initials = (0, react_1.useMemo)(() => {
|
|
36
|
+
const nameParts = name.trim().split(" ");
|
|
37
|
+
if (nameParts.length === 1)
|
|
38
|
+
return nameParts[0].charAt(0).toUpperCase();
|
|
39
|
+
const [firstName, lastName] = [nameParts[0], nameParts.slice(-1)[0]];
|
|
40
|
+
return `${firstName.charAt(0)}${lastName.charAt(0)}`.toUpperCase();
|
|
41
|
+
}, [name]);
|
|
42
|
+
return (react_1.default.createElement("div", { className: `${Avatar_module_scss_1.default.container} ${imgSrc ? "" : Avatar_module_scss_1.default.noImg}`, style: { fontSize: size }, title: name }, imgSrc ? react_1.default.createElement("img", { src: imgSrc, alt: name }) : react_1.default.createElement("span", null, initials)));
|
|
43
|
+
}
|
|
44
|
+
exports.default = Avatar;
|
|
45
45
|
//# sourceMappingURL=Avatar.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Avatar.js","sourceRoot":"","sources":["../../../src/components/Avatar/Avatar.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,+CAAuC;AACvC,8EAA0C;AAE1C;;IAEI;AACJ,SAAwB,MAAM,CAAC,EAC7B,IAAI,EACJ,MAAM,EACN,IAAI,GAAG,EAAE,GAKV;IACC,MAAM,QAAQ,GAAG,IAAA,eAAO,EAAC,GAAG,EAAE;QAC5B,MAAM,SAAS,GAAG,IAAI,CAAC,IAAI,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;QACzC,IAAI,SAAS,CAAC,MAAM,KAAK,CAAC;YAAE,OAAO,SAAS,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,WAAW,EAAE,CAAC;QACxE,MAAM,CAAC,SAAS,EAAE,QAAQ,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,SAAS,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QACrE,OAAO,GAAG,SAAS,CAAC,MAAM,CAAC,CAAC,CAAC,GAAG,QAAQ,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,WAAW,EAAE,CAAC;IACrE,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,CAAC;IACX,OAAO,CACL,
|
|
1
|
+
{"version":3,"file":"Avatar.js","sourceRoot":"","sources":["../../../src/components/Avatar/Avatar.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,+CAAuC;AACvC,8EAA0C;AAE1C;;IAEI;AACJ,SAAwB,MAAM,CAAC,EAC7B,IAAI,EACJ,MAAM,EACN,IAAI,GAAG,EAAE,GAKV;IACC,MAAM,QAAQ,GAAG,IAAA,eAAO,EAAC,GAAG,EAAE;QAC5B,MAAM,SAAS,GAAG,IAAI,CAAC,IAAI,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;QACzC,IAAI,SAAS,CAAC,MAAM,KAAK,CAAC;YAAE,OAAO,SAAS,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,WAAW,EAAE,CAAC;QACxE,MAAM,CAAC,SAAS,EAAE,QAAQ,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,SAAS,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QACrE,OAAO,GAAG,SAAS,CAAC,MAAM,CAAC,CAAC,CAAC,GAAG,QAAQ,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,WAAW,EAAE,CAAC;IACrE,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,CAAC;IACX,OAAO,CACL,uCACE,SAAS,EAAE,GAAG,4BAAM,CAAC,SAAS,IAAI,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,4BAAM,CAAC,KAAK,EAAE,EAC9D,KAAK,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,EACzB,KAAK,EAAE,IAAI,IAEV,MAAM,CAAC,CAAC,CAAC,uCAAK,GAAG,EAAE,MAAM,EAAE,GAAG,EAAE,IAAI,GAAI,CAAC,CAAC,CAAC,4CAAO,QAAQ,CAAQ,CAC/D,CACP,CAAC;AACJ,CAAC;AAxBD,yBAwBC"}
|
|
@@ -1,19 +1,22 @@
|
|
|
1
1
|
@import "../../assets/styles/index.scss";
|
|
2
2
|
|
|
3
3
|
.container {
|
|
4
|
+
&.noImg {
|
|
4
5
|
background-color: $avatarBackgroundColor;
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
6
|
+
}
|
|
7
|
+
display: inline-block;
|
|
8
|
+
width: 1em;
|
|
9
|
+
height: 1em;
|
|
10
|
+
border-radius: 0.5em;
|
|
9
11
|
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
}
|
|
12
|
+
> span,
|
|
13
|
+
> img {
|
|
14
|
+
font-size: 0.4em;
|
|
15
|
+
width: inherit;
|
|
16
|
+
height: inherit;
|
|
17
|
+
text-align: center;
|
|
18
|
+
line-height: 2.5em;
|
|
19
|
+
display: block;
|
|
20
|
+
color: $digitalBlue;
|
|
21
|
+
}
|
|
22
|
+
}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import Avatar from "./Avatar";
|
|
2
|
-
declare const _default: {
|
|
3
|
-
component: typeof Avatar;
|
|
4
|
-
title: string;
|
|
5
|
-
};
|
|
6
|
-
export default _default;
|
|
7
|
-
export declare const InitialImplementation: {
|
|
8
|
-
(args: any): JSX.Element;
|
|
9
|
-
args: Partial<{
|
|
10
|
-
imgSrc?: string | undefined;
|
|
11
|
-
name: string;
|
|
12
|
-
size?: number | undefined;
|
|
13
|
-
}>;
|
|
14
|
-
};
|
|
1
|
+
import Avatar from "./Avatar";
|
|
2
|
+
declare const _default: {
|
|
3
|
+
component: typeof Avatar;
|
|
4
|
+
title: string;
|
|
5
|
+
};
|
|
6
|
+
export default _default;
|
|
7
|
+
export declare const InitialImplementation: {
|
|
8
|
+
(args: any): JSX.Element;
|
|
9
|
+
args: Partial<{
|
|
10
|
+
imgSrc?: string | undefined;
|
|
11
|
+
name: string;
|
|
12
|
+
size?: number | undefined;
|
|
13
|
+
}>;
|
|
14
|
+
};
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.InitialImplementation = void 0;
|
|
7
|
-
const react_1 = __importDefault(require("react"));
|
|
8
|
-
const Avatar_1 = __importDefault(require("./Avatar"));
|
|
9
|
-
exports.default = {
|
|
10
|
-
component: Avatar_1.default,
|
|
11
|
-
title: "Avatar"
|
|
12
|
-
};
|
|
13
|
-
const InitialImplementation = (args) => react_1.default.createElement(Avatar_1.default, Object.assign({}, args));
|
|
14
|
-
exports.InitialImplementation = InitialImplementation;
|
|
15
|
-
exports.InitialImplementation.args = {
|
|
16
|
-
name: "Put your name here",
|
|
17
|
-
size: 48
|
|
18
|
-
};
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.InitialImplementation = void 0;
|
|
7
|
+
const react_1 = __importDefault(require("react"));
|
|
8
|
+
const Avatar_1 = __importDefault(require("./Avatar"));
|
|
9
|
+
exports.default = {
|
|
10
|
+
component: Avatar_1.default,
|
|
11
|
+
title: "Avatar"
|
|
12
|
+
};
|
|
13
|
+
const InitialImplementation = (args) => react_1.default.createElement(Avatar_1.default, Object.assign({}, args));
|
|
14
|
+
exports.InitialImplementation = InitialImplementation;
|
|
15
|
+
exports.InitialImplementation.args = {
|
|
16
|
+
name: "Put your name here",
|
|
17
|
+
size: 48
|
|
18
|
+
};
|
|
19
19
|
//# sourceMappingURL=Avatar.stories.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export {};
|
|
1
|
+
export {};
|
|
@@ -1,36 +1,36 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const react_1 = __importDefault(require("react"));
|
|
7
|
-
const react_2 = require("@testing-library/react");
|
|
8
|
-
const Avatar_stories_1 = require("./Avatar.stories");
|
|
9
|
-
function renderScreen(props) {
|
|
10
|
-
return (0, react_2.render)(react_1.default.createElement(Avatar_stories_1.InitialImplementation, Object.assign({}, props)));
|
|
11
|
-
}
|
|
12
|
-
it("Should show the image if provided", () => {
|
|
13
|
-
const MOCK_IMG = `data:base64//somebase64`;
|
|
14
|
-
const MOCK_NAME = "Francesco Silva";
|
|
15
|
-
const { container } = renderScreen({
|
|
16
|
-
name: MOCK_NAME,
|
|
17
|
-
imgSrc: MOCK_IMG,
|
|
18
|
-
});
|
|
19
|
-
expect(container.textContent).toBe("");
|
|
20
|
-
expect(container.querySelector("img").getAttribute("alt")).toEqual(MOCK_NAME);
|
|
21
|
-
});
|
|
22
|
-
it.each([
|
|
23
|
-
["Murilo", "M"],
|
|
24
|
-
["Murilo Oliveira de Araujo", "MA"],
|
|
25
|
-
["Murilo Araujo", "MA"],
|
|
26
|
-
["Francesco Espacio ", "FE"],
|
|
27
|
-
[" This Is the Way ", "TW"],
|
|
28
|
-
["Mano Mano", "MM"],
|
|
29
|
-
["Single", "S"],
|
|
30
|
-
])("Should show the initials for the name %s as %s", (name, expectation) => {
|
|
31
|
-
const { container } = renderScreen({
|
|
32
|
-
name: name,
|
|
33
|
-
});
|
|
34
|
-
expect(container.textContent).toEqual(expectation);
|
|
35
|
-
});
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const react_1 = __importDefault(require("react"));
|
|
7
|
+
const react_2 = require("@testing-library/react");
|
|
8
|
+
const Avatar_stories_1 = require("./Avatar.stories");
|
|
9
|
+
function renderScreen(props) {
|
|
10
|
+
return (0, react_2.render)(react_1.default.createElement(Avatar_stories_1.InitialImplementation, Object.assign({}, props)));
|
|
11
|
+
}
|
|
12
|
+
it("Should show the image if provided", () => {
|
|
13
|
+
const MOCK_IMG = `data:base64//somebase64`;
|
|
14
|
+
const MOCK_NAME = "Francesco Silva";
|
|
15
|
+
const { container } = renderScreen({
|
|
16
|
+
name: MOCK_NAME,
|
|
17
|
+
imgSrc: MOCK_IMG,
|
|
18
|
+
});
|
|
19
|
+
expect(container.textContent).toBe("");
|
|
20
|
+
expect(container.querySelector("img").getAttribute("alt")).toEqual(MOCK_NAME);
|
|
21
|
+
});
|
|
22
|
+
it.each([
|
|
23
|
+
["Murilo", "M"],
|
|
24
|
+
["Murilo Oliveira de Araujo", "MA"],
|
|
25
|
+
["Murilo Araujo", "MA"],
|
|
26
|
+
["Francesco Espacio ", "FE"],
|
|
27
|
+
[" This Is the Way ", "TW"],
|
|
28
|
+
["Mano Mano", "MM"],
|
|
29
|
+
["Single", "S"],
|
|
30
|
+
])("Should show the initials for the name %s as %s", (name, expectation) => {
|
|
31
|
+
const { container } = renderScreen({
|
|
32
|
+
name: name,
|
|
33
|
+
});
|
|
34
|
+
expect(container.textContent).toEqual(expectation);
|
|
35
|
+
});
|
|
36
36
|
//# sourceMappingURL=Avatar.test.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { default } from './Avatar';
|
|
1
|
+
export { default } from './Avatar';
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.default = void 0;
|
|
7
|
-
var Avatar_1 = require("./Avatar");
|
|
8
|
-
Object.defineProperty(exports, "default", { enumerable: true, get: function () { return __importDefault(Avatar_1).default; } });
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
var Avatar_1 = require("./Avatar");
|
|
8
|
+
Object.defineProperty(exports, "default", { enumerable: true, get: function () { return __importDefault(Avatar_1).default; } });
|
|
9
9
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { PropsWithChildren, ReactNode } from "react";
|
|
2
|
-
/**
|
|
3
|
-
* A weird name for a component, but it's objective is to change element colors as the user progresses through a series of steps
|
|
4
|
-
*
|
|
5
|
-
* IT IS NOT READY (AND PROBABLY NEVER WILL) FOR FRAGMENT NODES
|
|
6
|
-
**/
|
|
7
|
-
export default function BucketFill({ children, background, fillTo, }: {
|
|
8
|
-
children: ReactNode[];
|
|
9
|
-
fillTo: number;
|
|
10
|
-
background: string;
|
|
11
|
-
}): JSX.Element;
|
|
12
|
-
export declare function IgnoreFill({ children }: PropsWithChildren<{}>): JSX.Element;
|
|
1
|
+
import { PropsWithChildren, ReactNode } from "react";
|
|
2
|
+
/**
|
|
3
|
+
* A weird name for a component, but it's objective is to change element colors as the user progresses through a series of steps
|
|
4
|
+
*
|
|
5
|
+
* IT IS NOT READY (AND PROBABLY NEVER WILL) FOR FRAGMENT NODES
|
|
6
|
+
**/
|
|
7
|
+
export default function BucketFill({ children, background, fillTo, }: {
|
|
8
|
+
children: ReactNode[];
|
|
9
|
+
fillTo: number;
|
|
10
|
+
background: string;
|
|
11
|
+
}): JSX.Element;
|
|
12
|
+
export declare function IgnoreFill({ children }: PropsWithChildren<{}>): JSX.Element;
|
|
@@ -1,66 +1,66 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
-
if (mod && mod.__esModule) return mod;
|
|
20
|
-
var result = {};
|
|
21
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
-
__setModuleDefault(result, mod);
|
|
23
|
-
return result;
|
|
24
|
-
};
|
|
25
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
26
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
27
|
-
};
|
|
28
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
-
exports.IgnoreFill = void 0;
|
|
30
|
-
const react_1 = __importStar(require("react"));
|
|
31
|
-
const BucketFill_module_scss_1 = __importDefault(require("./BucketFill.module.scss"));
|
|
32
|
-
/**
|
|
33
|
-
* A weird name for a component, but it's objective is to change element colors as the user progresses through a series of steps
|
|
34
|
-
*
|
|
35
|
-
* IT IS NOT READY (AND PROBABLY NEVER WILL) FOR FRAGMENT NODES
|
|
36
|
-
**/
|
|
37
|
-
function BucketFill({ children, background, fillTo, }) {
|
|
38
|
-
const rootRef = (0, react_1.useRef)(null);
|
|
39
|
-
function resize() {
|
|
40
|
-
const childs = rootRef.current.children;
|
|
41
|
-
const s = rootRef.current.style;
|
|
42
|
-
const elementAtPosition = fillTo === 0 ? null : childs.item(fillTo - 1);
|
|
43
|
-
const elementOffsetAndHeight = elementAtPosition === null
|
|
44
|
-
? 0
|
|
45
|
-
: elementAtPosition.offsetTop + elementAtPosition.clientHeight;
|
|
46
|
-
const elementRootHeight = rootRef.current.clientHeight;
|
|
47
|
-
const percentToFill = Math.min((elementOffsetAndHeight * 100) / elementRootHeight, 100);
|
|
48
|
-
s.setProperty("--fill-height", `${percentToFill}%`);
|
|
49
|
-
s.setProperty("--empty-height", `${100 - percentToFill}%`);
|
|
50
|
-
s.setProperty("--bg-offset", `${percentToFill === 100 ? -1000 : 100 / ((100 - percentToFill) / 100)}%`);
|
|
51
|
-
}
|
|
52
|
-
(0, react_1.useEffect)(() => {
|
|
53
|
-
resize();
|
|
54
|
-
window.addEventListener("resize", resize);
|
|
55
|
-
return () => window.removeEventListener("resize", resize);
|
|
56
|
-
}, [fillTo]);
|
|
57
|
-
return (react_1.default.createElement("div", { ref: rootRef, style: {
|
|
58
|
-
"--bg": background,
|
|
59
|
-
}, className: BucketFill_module_scss_1.default.root }, children));
|
|
60
|
-
}
|
|
61
|
-
exports.default = BucketFill;
|
|
62
|
-
function IgnoreFill({ children }) {
|
|
63
|
-
return react_1.default.createElement("div", { className: BucketFill_module_scss_1.default.ignoreFill }, children);
|
|
64
|
-
}
|
|
65
|
-
exports.IgnoreFill = IgnoreFill;
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
25
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
26
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
27
|
+
};
|
|
28
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
+
exports.IgnoreFill = void 0;
|
|
30
|
+
const react_1 = __importStar(require("react"));
|
|
31
|
+
const BucketFill_module_scss_1 = __importDefault(require("./BucketFill.module.scss"));
|
|
32
|
+
/**
|
|
33
|
+
* A weird name for a component, but it's objective is to change element colors as the user progresses through a series of steps
|
|
34
|
+
*
|
|
35
|
+
* IT IS NOT READY (AND PROBABLY NEVER WILL) FOR FRAGMENT NODES
|
|
36
|
+
**/
|
|
37
|
+
function BucketFill({ children, background, fillTo, }) {
|
|
38
|
+
const rootRef = (0, react_1.useRef)(null);
|
|
39
|
+
function resize() {
|
|
40
|
+
const childs = rootRef.current.children;
|
|
41
|
+
const s = rootRef.current.style;
|
|
42
|
+
const elementAtPosition = fillTo === 0 ? null : childs.item(fillTo - 1);
|
|
43
|
+
const elementOffsetAndHeight = elementAtPosition === null
|
|
44
|
+
? 0
|
|
45
|
+
: elementAtPosition.offsetTop + elementAtPosition.clientHeight;
|
|
46
|
+
const elementRootHeight = rootRef.current.clientHeight;
|
|
47
|
+
const percentToFill = Math.min((elementOffsetAndHeight * 100) / elementRootHeight, 100);
|
|
48
|
+
s.setProperty("--fill-height", `${percentToFill}%`);
|
|
49
|
+
s.setProperty("--empty-height", `${100 - percentToFill}%`);
|
|
50
|
+
s.setProperty("--bg-offset", `${percentToFill === 100 ? -1000 : 100 / ((100 - percentToFill) / 100)}%`);
|
|
51
|
+
}
|
|
52
|
+
(0, react_1.useEffect)(() => {
|
|
53
|
+
resize();
|
|
54
|
+
window.addEventListener("resize", resize);
|
|
55
|
+
return () => window.removeEventListener("resize", resize);
|
|
56
|
+
}, [fillTo]);
|
|
57
|
+
return (react_1.default.createElement("div", { ref: rootRef, style: {
|
|
58
|
+
"--bg": background,
|
|
59
|
+
}, className: BucketFill_module_scss_1.default.root }, children));
|
|
60
|
+
}
|
|
61
|
+
exports.default = BucketFill;
|
|
62
|
+
function IgnoreFill({ children }) {
|
|
63
|
+
return react_1.default.createElement("div", { className: BucketFill_module_scss_1.default.ignoreFill }, children);
|
|
64
|
+
}
|
|
65
|
+
exports.IgnoreFill = IgnoreFill;
|
|
66
66
|
//# sourceMappingURL=BucketFill.js.map
|