@digigov/ui 0.8.3 → 0.9.2
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/CHANGELOG.md +34 -1
- package/app/App.js +6 -8
- package/app/Header/HeaderLogo.js +19 -39
- package/app/Header/HeaderSection.js +6 -43
- package/app/Header/HeaderTitle.js +14 -91
- package/app/Header/index.js +20 -67
- package/app/Header/index.spec.js +0 -1
- package/app/PageTitle.js +45 -81
- package/core/Accordion/index.js +103 -57
- package/core/Blockquote/index.js +17 -47
- package/core/Button/BackButton.js +20 -42
- package/core/Button/ButtonLink.js +28 -0
- package/core/Button/CallToAction.js +21 -12
- package/core/Button/Icon.js +5 -47
- package/core/Button/index.js +49 -99
- package/core/Details/index.js +22 -70
- package/core/Divider/index.js +9 -9
- package/core/ErrorSummary/index.js +8 -28
- package/core/List/List.js +8 -34
- package/core/List/ListItem.js +8 -38
- package/core/List/ListItemTitle.js +1 -3
- package/core/NavList/NavListItem.js +2 -2
- package/core/NotificationBanner/index.js +49 -48
- package/core/NotificationBanner/index.spec.js +3 -1
- package/core/ServiceBadge/index.js +17 -28
- package/core/SummaryList/index.js +57 -124
- package/core/Tabs/index.js +65 -98
- package/core/WarningText/index.js +8 -41
- package/es/app/App.js +6 -8
- package/es/app/Header/HeaderLogo.js +15 -30
- package/es/app/Header/HeaderSection.js +5 -36
- package/es/app/Header/HeaderTitle.js +13 -78
- package/es/app/Header/index.js +6 -56
- package/es/app/Header/index.spec.js +0 -1
- package/es/app/PageTitle.js +46 -74
- package/es/core/Accordion/index.js +64 -52
- package/es/core/Blockquote/index.js +13 -39
- package/es/core/Button/BackButton.js +18 -36
- package/es/core/Button/ButtonLink.js +16 -0
- package/es/core/Button/CallToAction.js +19 -9
- package/es/core/Button/Icon.js +5 -35
- package/es/core/Button/index.js +26 -87
- package/es/core/Details/index.js +5 -62
- package/es/core/Divider/index.js +7 -6
- package/es/core/ErrorSummary/index.js +2 -21
- package/es/core/List/List.js +2 -26
- package/es/core/List/ListItem.js +2 -30
- package/es/core/List/ListItemTitle.js +1 -3
- package/es/core/NavList/NavListItem.js +1 -1
- package/es/core/NotificationBanner/index.js +27 -45
- package/es/core/NotificationBanner/index.spec.js +3 -1
- package/es/core/ServiceBadge/index.js +15 -25
- package/es/core/SummaryList/index.js +7 -119
- package/es/core/Tabs/index.js +33 -93
- package/es/core/WarningText/index.js +2 -33
- package/es/govgr/Footer/Copyright.js +14 -36
- package/es/govgr/Footer/HellenicRepublicLogo.js +2 -30
- package/es/govgr/Footer/LicenseCCSA.js +2 -17
- package/es/govgr/Footer/index.js +23 -69
- package/es/govgr/Logo/index.js +2 -14
- package/es/hooks/useTogglableSections.js +96 -0
- package/es/layouts/Basic/Bottom/index.js +3 -13
- package/es/layouts/Basic/Content/index.js +14 -51
- package/es/layouts/Basic/Content/index.mdx +1 -1
- package/es/layouts/Basic/Main/index.js +3 -21
- package/es/layouts/Basic/Masthead/index.js +4 -47
- package/es/layouts/Basic/Masthead/index.mdx +1 -1
- package/es/layouts/Basic/Side/index.js +6 -28
- package/es/layouts/Basic/Top/index.js +7 -36
- package/es/layouts/Basic/index.js +3 -49
- package/es/themes/grnet.js +1 -1
- package/es/typography/Caption.js +5 -21
- package/es/typography/NormalText.js +2 -10
- package/es/typography/Paragraph.js +1 -29
- package/es/typography/Title.js +40 -87
- package/es/utils/withDeprecation.js +102 -0
- package/esm/app/App.js +6 -8
- package/esm/app/Header/HeaderLogo.js +15 -30
- package/esm/app/Header/HeaderSection.js +5 -36
- package/esm/app/Header/HeaderTitle.js +13 -78
- package/esm/app/Header/index.js +6 -56
- package/esm/app/Header/index.spec.js +0 -1
- package/esm/app/PageTitle.js +46 -74
- package/esm/core/Accordion/index.js +64 -52
- package/esm/core/Blockquote/index.js +13 -39
- package/esm/core/Button/BackButton.js +18 -36
- package/esm/core/Button/ButtonLink.js +16 -0
- package/esm/core/Button/CallToAction.js +19 -9
- package/esm/core/Button/Icon.js +5 -35
- package/esm/core/Button/index.js +26 -87
- package/esm/core/Details/index.js +5 -62
- package/esm/core/Divider/index.js +7 -6
- package/esm/core/ErrorSummary/index.js +2 -21
- package/esm/core/List/List.js +2 -26
- package/esm/core/List/ListItem.js +2 -30
- package/esm/core/List/ListItemTitle.js +1 -3
- package/esm/core/NavList/NavListItem.js +1 -1
- package/esm/core/NotificationBanner/index.js +27 -45
- package/esm/core/NotificationBanner/index.spec.js +3 -1
- package/esm/core/ServiceBadge/index.js +15 -25
- package/esm/core/SummaryList/index.js +7 -119
- package/esm/core/Tabs/index.js +33 -93
- package/esm/core/WarningText/index.js +2 -33
- package/esm/govgr/Footer/Copyright.js +14 -36
- package/esm/govgr/Footer/HellenicRepublicLogo.js +2 -30
- package/esm/govgr/Footer/LicenseCCSA.js +2 -17
- package/esm/govgr/Footer/index.js +23 -69
- package/esm/govgr/Logo/index.js +2 -14
- package/esm/hooks/useTogglableSections.js +96 -0
- package/esm/index.js +1 -1
- package/esm/layouts/Basic/Bottom/index.js +3 -13
- package/esm/layouts/Basic/Content/index.js +14 -51
- package/esm/layouts/Basic/Content/index.mdx +1 -1
- package/esm/layouts/Basic/Main/index.js +3 -21
- package/esm/layouts/Basic/Masthead/index.js +4 -47
- package/esm/layouts/Basic/Masthead/index.mdx +1 -1
- package/esm/layouts/Basic/Side/index.js +6 -28
- package/esm/layouts/Basic/Top/index.js +7 -36
- package/esm/layouts/Basic/index.js +3 -49
- package/esm/themes/grnet.js +1 -1
- package/esm/typography/Caption.js +5 -21
- package/esm/typography/NormalText.js +2 -10
- package/esm/typography/Paragraph.js +1 -29
- package/esm/typography/Title.js +40 -87
- package/esm/utils/withDeprecation.js +102 -0
- package/govgr/Footer/Copyright.js +15 -42
- package/govgr/Footer/HellenicRepublicLogo.js +8 -39
- package/govgr/Footer/LicenseCCSA.js +2 -19
- package/govgr/Footer/index.js +23 -72
- package/govgr/Logo/index.js +9 -28
- package/hooks/useTogglableSections.js +108 -0
- package/layouts/Basic/Bottom/index.js +10 -19
- package/layouts/Basic/Content/index.js +17 -68
- package/layouts/Basic/Content/index.mdx +1 -1
- package/layouts/Basic/Main/index.js +10 -23
- package/layouts/Basic/Masthead/index.js +17 -54
- package/layouts/Basic/Masthead/index.mdx +1 -1
- package/layouts/Basic/Side/index.js +9 -35
- package/layouts/Basic/Top/index.js +7 -40
- package/layouts/Basic/index.js +4 -57
- package/{api → libs/ui/src/api}/APIErrors.d.ts +0 -0
- package/{api → libs/ui/src/api}/APIProvider.d.ts +0 -0
- package/{api → libs/ui/src/api}/fetchAPI.d.ts +0 -0
- package/{api → libs/ui/src/api}/index.d.ts +0 -0
- package/{api → libs/ui/src/api}/index.spec.d.ts +0 -0
- package/{api → libs/ui/src/api}/useResource.d.ts +0 -0
- package/{api → libs/ui/src/api}/useResourceAction.d.ts +0 -0
- package/{api → libs/ui/src/api}/useResourceQuery.d.ts +0 -0
- package/{api → libs/ui/src/api}/utils.d.ts +0 -0
- package/{app → libs/ui/src/app}/App.d.ts +0 -0
- package/libs/ui/src/app/Header/HeaderLogo.d.ts +3 -0
- package/libs/ui/src/app/Header/HeaderSection.d.ts +5 -0
- package/libs/ui/src/app/Header/HeaderTitle.d.ts +5 -0
- package/libs/ui/src/app/Header/index.d.ts +9 -0
- package/{app → libs/ui/src/app}/Header/index.spec.d.ts +0 -0
- package/{app → libs/ui/src/app}/NotFound/index.d.ts +0 -0
- package/{app → libs/ui/src/app}/OutdatedBrowserBanner.d.ts +0 -0
- package/libs/ui/src/app/PageTitle.d.ts +10 -0
- package/{app → libs/ui/src/app}/QrCodeScanner/index.d.ts +0 -0
- package/{app → libs/ui/src/app}/QrCodeScanner/index.spec.d.ts +0 -0
- package/{app → libs/ui/src/app}/i18n.d.ts +0 -0
- package/{app → libs/ui/src/app}/index.d.ts +0 -0
- package/libs/ui/src/core/Accordion/index.d.ts +21 -0
- package/{core → libs/ui/src/core}/Accordion/index.spec.d.ts +0 -0
- package/libs/ui/src/core/Blockquote/index.d.ts +3 -0
- package/{core → libs/ui/src/core}/Blockquote/index.spec.d.ts +0 -0
- package/libs/ui/src/core/Button/BackButton.d.ts +3 -0
- package/libs/ui/src/core/Button/ButtonLink.d.ts +4 -0
- package/libs/ui/src/core/Button/CallToAction.d.ts +7 -0
- package/libs/ui/src/core/Button/Icon.d.ts +2 -0
- package/libs/ui/src/core/Button/index.d.ts +14 -0
- package/{core → libs/ui/src/core}/Button/index.spec.d.ts +0 -0
- package/libs/ui/src/core/Details/index.d.ts +5 -0
- package/{core → libs/ui/src/core}/Details/index.spec.d.ts +0 -0
- package/libs/ui/src/core/Divider/index.d.ts +5 -0
- package/libs/ui/src/core/ErrorSummary/index.d.ts +3 -0
- package/{core → libs/ui/src/core}/ErrorSummary/index.spec.d.ts +0 -0
- package/{core → libs/ui/src/core}/Link/index.d.ts +0 -0
- package/{core → libs/ui/src/core}/Link/index.spec.d.ts +0 -0
- package/libs/ui/src/core/List/List.d.ts +3 -0
- package/libs/ui/src/core/List/ListItem.d.ts +3 -0
- package/{core → libs/ui/src/core}/List/ListItemContent.d.ts +0 -0
- package/{core → libs/ui/src/core}/List/ListItemIcon.d.ts +0 -0
- package/{core → libs/ui/src/core}/List/ListItemText.d.ts +1 -0
- package/{core → libs/ui/src/core}/List/ListItemTitle.d.ts +0 -0
- package/{core → libs/ui/src/core}/List/index.d.ts +0 -0
- package/{core → libs/ui/src/core}/List/index.spec.d.ts +0 -0
- package/{core → libs/ui/src/core}/NavList/NavList.d.ts +1 -1
- package/{core → libs/ui/src/core}/NavList/NavListContext.d.ts +0 -0
- package/{core → libs/ui/src/core}/NavList/NavListItem.d.ts +0 -0
- package/{core → libs/ui/src/core}/NavList/NavListItemBase.d.ts +1 -1
- package/{core → libs/ui/src/core}/NavList/NavListSubMenu.d.ts +0 -0
- package/{core → libs/ui/src/core}/NavList/index.d.ts +0 -0
- package/{core → libs/ui/src/core}/NavList/index.spec.d.ts +0 -0
- package/libs/ui/src/core/NotificationBanner/index.d.ts +17 -0
- package/{core → libs/ui/src/core}/NotificationBanner/index.spec.d.ts +0 -0
- package/libs/ui/src/core/ServiceBadge/index.d.ts +8 -0
- package/libs/ui/src/core/SummaryList/index.d.ts +7 -0
- package/{core → libs/ui/src/core}/SummaryList/index.spec.d.ts +0 -0
- package/libs/ui/src/core/Tabs/index.d.ts +16 -0
- package/libs/ui/src/core/WarningText/index.d.ts +3 -0
- package/{core → libs/ui/src/core}/WarningText/index.spec.d.ts +0 -0
- package/{core → libs/ui/src/core}/index.d.ts +0 -0
- package/{govgr → libs/ui/src/govgr}/Footer/Copyright.d.ts +1 -1
- package/libs/ui/src/govgr/Footer/HellenicRepublicLogo.d.ts +3 -0
- package/{govgr → libs/ui/src/govgr}/Footer/LicenseCCSA.d.ts +0 -0
- package/{govgr → libs/ui/src/govgr}/Footer/index.d.ts +3 -3
- package/{govgr → libs/ui/src/govgr}/Footer/logo.d.ts +0 -0
- package/libs/ui/src/govgr/Footer/logos/logo-el.d.ts +2 -0
- package/libs/ui/src/govgr/Footer/logos/logo-en.d.ts +2 -0
- package/libs/ui/src/govgr/Logo/index.d.ts +3 -0
- package/{govgr → libs/ui/src/govgr}/Logo/logo.d.ts +0 -0
- package/{govgr → libs/ui/src/govgr}/index.d.ts +0 -0
- package/{hooks → libs/ui/src/hooks}/useDebounce.d.ts +0 -0
- package/{hooks → libs/ui/src/hooks}/useLatest.d.ts +0 -0
- package/{hooks → libs/ui/src/hooks}/useOutdatedBrowserCheck.d.ts +0 -0
- package/{hooks → libs/ui/src/hooks}/useSearch.d.ts +0 -0
- package/libs/ui/src/hooks/useTogglableSections.d.ts +18 -0
- package/{index.d.ts → libs/ui/src/index.d.ts} +0 -0
- package/libs/ui/src/layouts/Basic/Bottom/index.d.ts +3 -0
- package/libs/ui/src/layouts/Basic/Content/index.d.ts +5 -0
- package/libs/ui/src/layouts/Basic/Main/index.d.ts +3 -0
- package/libs/ui/src/layouts/Basic/Masthead/index.d.ts +4 -0
- package/libs/ui/src/layouts/Basic/Side/index.d.ts +3 -0
- package/libs/ui/src/layouts/Basic/Top/index.d.ts +3 -0
- package/libs/ui/src/layouts/Basic/index.d.ts +8 -0
- package/{layouts → libs/ui/src/layouts}/Basic/index.spec.d.ts +0 -0
- package/{layouts → libs/ui/src/layouts}/index.d.ts +0 -0
- package/{locales → libs/ui/src/locales}/el.d.ts +0 -0
- package/{locales → libs/ui/src/locales}/en.d.ts +0 -0
- package/{router → libs/ui/src/router}/index.d.ts +0 -0
- package/{test-utils → libs/ui/src/test-utils}/delay.d.ts +0 -0
- package/{test-utils → libs/ui/src/test-utils}/mountWithTheme.d.ts +0 -0
- package/{themes → libs/ui/src/themes}/govgr.d.ts +0 -0
- package/{themes → libs/ui/src/themes}/grnet.d.ts +0 -0
- package/{themes → libs/ui/src/themes}/index.d.ts +0 -0
- package/libs/ui/src/typography/Caption.d.ts +7 -0
- package/libs/ui/src/typography/NormalText.d.ts +5 -0
- package/libs/ui/src/typography/Paragraph.d.ts +6 -0
- package/libs/ui/src/typography/Title.d.ts +9 -0
- package/{typography → libs/ui/src/typography}/index.d.ts +0 -0
- package/{utils → libs/ui/src/utils}/evaluateBrowserVersion.d.ts +0 -0
- package/libs/ui/src/utils/withDeprecation.d.ts +16 -0
- package/libs-ui/react-core/src/Accordion/index.d.ts +10 -0
- package/libs-ui/react-core/src/AccordionControls/index.d.ts +9 -0
- package/libs-ui/react-core/src/AccordionSection/index.d.ts +15 -0
- package/libs-ui/react-core/src/AccordionSectionContent/index.d.ts +10 -0
- package/libs-ui/react-core/src/AccordionSectionHeader/index.d.ts +9 -0
- package/libs-ui/react-core/src/Aside/index.d.ts +10 -0
- package/libs-ui/react-core/src/BackLink/index.d.ts +13 -0
- package/libs-ui/react-core/src/Blockquote/index.d.ts +9 -0
- package/libs-ui/react-core/src/Bottom/index.d.ts +9 -0
- package/libs-ui/react-core/src/Button/index.d.ts +21 -0
- package/libs-ui/react-core/src/ButtonLink/index.d.ts +17 -0
- package/libs-ui/react-core/src/CallToAction/index.d.ts +10 -0
- package/libs-ui/react-core/src/Container/index.d.ts +9 -0
- package/libs-ui/react-core/src/Copyright/index.d.ts +10 -0
- package/libs-ui/react-core/src/Details/index.d.ts +10 -0
- package/libs-ui/react-core/src/DetailsContent/index.d.ts +10 -0
- package/libs-ui/react-core/src/DetailsSummary/index.d.ts +9 -0
- package/libs-ui/react-core/src/ErrorSummary/index.d.ts +9 -0
- package/libs-ui/react-core/src/Footer/index.d.ts +9 -0
- package/libs-ui/react-core/src/FooterContainer/index.d.ts +9 -0
- package/libs-ui/react-core/src/FooterMeta/index.d.ts +11 -0
- package/libs-ui/react-core/src/FooterMetaItem/index.d.ts +14 -0
- package/libs-ui/react-core/src/GovGRLogo/index.d.ts +9 -0
- package/libs-ui/react-core/src/Grid/index.d.ts +20 -0
- package/libs-ui/react-core/src/Header/index.d.ts +10 -0
- package/libs-ui/react-core/src/HeaderLogo/index.d.ts +17 -0
- package/libs-ui/react-core/src/HeaderSection/index.d.ts +9 -0
- package/libs-ui/react-core/src/HeaderSubtitle/index.d.ts +9 -0
- package/libs-ui/react-core/src/HeaderTitle/index.d.ts +13 -0
- package/libs-ui/react-core/src/Heading/index.d.ts +21 -0
- package/libs-ui/react-core/src/HeadingCaption/index.d.ts +15 -0
- package/libs-ui/react-core/src/HellenicRepublicLogo/index.d.ts +20 -0
- package/{govgr/Footer/logos → libs-ui/react-core/src/HellenicRepublicLogo}/logo-el.d.ts +0 -0
- package/{govgr/Footer/logos → libs-ui/react-core/src/HellenicRepublicLogo}/logo-en.d.ts +0 -0
- package/libs-ui/react-core/src/Layout/index.d.ts +10 -0
- package/libs-ui/react-core/src/List/index.d.ts +18 -0
- package/libs-ui/react-core/src/ListItem/index.d.ts +9 -0
- package/libs-ui/react-core/src/Main/index.d.ts +9 -0
- package/libs-ui/react-core/src/Masthead/index.d.ts +9 -0
- package/libs-ui/react-core/src/MastheadBody/index.d.ts +9 -0
- package/libs-ui/react-core/src/NormalText/index.d.ts +28 -0
- package/libs-ui/react-core/src/NotificationBanner/index.d.ts +17 -0
- package/libs-ui/react-core/src/NotificationBannerContent/index.d.ts +12 -0
- package/libs-ui/react-core/src/NotificationBannerHeader/index.d.ts +11 -0
- package/libs-ui/react-core/src/NotificationBannerHeading/index.d.ts +11 -0
- package/libs-ui/react-core/src/Paragraph/index.d.ts +26 -0
- package/libs-ui/react-core/src/PhaseBanner/index.d.ts +15 -0
- package/libs-ui/react-core/src/PhaseBannerTag/index.d.ts +9 -0
- package/libs-ui/react-core/src/SectionBreak/index.d.ts +18 -0
- package/libs-ui/react-core/src/SummaryList/index.d.ts +10 -0
- package/libs-ui/react-core/src/SummaryListItem/index.d.ts +10 -0
- package/libs-ui/react-core/src/SummaryListItemAction/index.d.ts +10 -0
- package/libs-ui/react-core/src/SummaryListItemKey/index.d.ts +10 -0
- package/libs-ui/react-core/src/SummaryListItemValue/index.d.ts +9 -0
- package/libs-ui/react-core/src/Tabs/index.d.ts +10 -0
- package/libs-ui/react-core/src/TabsHeading/index.d.ts +15 -0
- package/libs-ui/react-core/src/TabsList/index.d.ts +10 -0
- package/libs-ui/react-core/src/TabsListItem/index.d.ts +20 -0
- package/libs-ui/react-core/src/TabsPanel/index.d.ts +16 -0
- package/libs-ui/react-core/src/Top/index.d.ts +9 -0
- package/libs-ui/react-core/src/WarningText/index.d.ts +11 -0
- package/package.json +3 -2
- package/themes/grnet.js +1 -1
- package/typography/Caption.js +5 -25
- package/typography/NormalText.js +9 -16
- package/typography/Paragraph.js +3 -39
- package/typography/Title.js +42 -88
- package/utils/withDeprecation.js +114 -0
- package/app/Header/HeaderLogo.d.ts +0 -12
- package/app/Header/HeaderSection.d.ts +0 -6
- package/app/Header/HeaderTitle.d.ts +0 -26
- package/app/Header/index.d.ts +0 -20
- package/app/PageTitle.d.ts +0 -21
- package/core/Accordion/index.d.ts +0 -23
- package/core/Blockquote/index.d.ts +0 -9
- package/core/Button/BackButton.d.ts +0 -4
- package/core/Button/CallToAction.d.ts +0 -8
- package/core/Button/Icon.d.ts +0 -9
- package/core/Button/__snapshots__/index.spec.tsx.snap +0 -145
- package/core/Button/index.d.js +0 -1
- package/core/Button/index.d.ts +0 -26
- package/core/Details/index.d.ts +0 -17
- package/core/Divider/index.d.ts +0 -6
- package/core/ErrorSummary/index.d.ts +0 -8
- package/core/List/List.d.ts +0 -10
- package/core/List/ListItem.d.ts +0 -10
- package/core/NotificationBanner/index.d.ts +0 -7
- package/core/ServiceBadge/index.d.ts +0 -7
- package/core/SummaryList/index.d.ts +0 -29
- package/core/Tabs/index.d.ts +0 -21
- package/core/WarningText/index.d.ts +0 -8
- package/es/core/Button/__snapshots__/index.spec.tsx.snap +0 -145
- package/es/core/Button/index.d.js +0 -0
- package/esm/core/Button/__snapshots__/index.spec.tsx.snap +0 -145
- package/esm/core/Button/index.d.js +0 -0
- package/govgr/Footer/HellenicRepublicLogo.d.ts +0 -6
- package/govgr/Logo/index.d.ts +0 -3
- package/layouts/Basic/Bottom/index.d.ts +0 -5
- package/layouts/Basic/Content/index.d.ts +0 -9
- package/layouts/Basic/Main/index.d.ts +0 -8
- package/layouts/Basic/Masthead/index.d.ts +0 -7
- package/layouts/Basic/Side/index.d.ts +0 -14
- package/layouts/Basic/Top/index.d.ts +0 -13
- package/layouts/Basic/index.d.ts +0 -31
- package/typography/Caption.d.ts +0 -10
- package/typography/NormalText.d.ts +0 -6
- package/typography/Paragraph.d.ts +0 -7
- package/typography/Title.d.ts +0 -16
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
declare type DivElementAttributes = JSX.IntrinsicElements['div'];
|
|
3
|
+
export interface TopProps extends DivElementAttributes {
|
|
4
|
+
}
|
|
5
|
+
/**
|
|
6
|
+
* Top is used inside the Layout component and it must be the first component in order.
|
|
7
|
+
*/
|
|
8
|
+
export declare const Top: React.ForwardRefExoticComponent<Pick<TopProps, "color" | "className" | "children" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture"> & React.RefAttributes<HTMLDivElement>>;
|
|
9
|
+
export default Top;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
declare type DivElementAttributes = JSX.IntrinsicElements['div'];
|
|
3
|
+
export interface WarningTextProps extends DivElementAttributes {
|
|
4
|
+
}
|
|
5
|
+
/**
|
|
6
|
+
* WarningText.
|
|
7
|
+
* Use the WarningText component when you need to warn users about something important.
|
|
8
|
+
* The component is used with a text inside it.
|
|
9
|
+
*/
|
|
10
|
+
export declare const WarningText: React.ForwardRefExoticComponent<Pick<WarningTextProps, "color" | "className" | "children" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture"> & React.RefAttributes<HTMLDivElement>>;
|
|
11
|
+
export default WarningText;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@digigov/ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.9.2",
|
|
4
4
|
"description": "@digigov reusable components toolkit",
|
|
5
5
|
"module": "./esm/index.js",
|
|
6
6
|
"publishConfig": {
|
|
@@ -17,7 +17,8 @@
|
|
|
17
17
|
"@material-ui/icons": "4.11.2",
|
|
18
18
|
"clsx": "1.1.1",
|
|
19
19
|
"react": "16.14.0",
|
|
20
|
-
"react-dom": "16.14.0"
|
|
20
|
+
"react-dom": "16.14.0",
|
|
21
|
+
"@digigov/react-core": "0.3.1"
|
|
21
22
|
},
|
|
22
23
|
"gitHead": "c903a46306f77f55ad7fc4d2e274006f39a6c871",
|
|
23
24
|
"private": false,
|
package/themes/grnet.js
CHANGED
|
@@ -21,7 +21,7 @@ var _Toolbar = _interopRequireDefault(require("@material-ui/core/Toolbar"));
|
|
|
21
21
|
|
|
22
22
|
var _Typography = _interopRequireDefault(require("@material-ui/core/Typography"));
|
|
23
23
|
|
|
24
|
-
var _Grid = _interopRequireDefault(require("@
|
|
24
|
+
var _Grid = _interopRequireDefault(require("@digigov/react-core/Grid"));
|
|
25
25
|
|
|
26
26
|
var _AppBar = _interopRequireDefault(require("@material-ui/core/AppBar"));
|
|
27
27
|
|
package/typography/Caption.js
CHANGED
|
@@ -7,34 +7,14 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
});
|
|
8
8
|
exports["default"] = exports.Caption = void 0;
|
|
9
9
|
|
|
10
|
-
var
|
|
10
|
+
var _HeadingCaption = _interopRequireDefault(require("@digigov/react-core/HeadingCaption"));
|
|
11
11
|
|
|
12
|
-
var
|
|
12
|
+
var _withDeprecation = _interopRequireDefault(require("@digigov/ui/utils/withDeprecation"));
|
|
13
13
|
|
|
14
|
-
var
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
var _clsx = _interopRequireDefault(require("clsx"));
|
|
19
|
-
|
|
20
|
-
var useStyles = (0, _styles.makeStyles)(function () {
|
|
21
|
-
return {
|
|
22
|
-
caption: {
|
|
23
|
-
color: '#4d4d4d',
|
|
24
|
-
fontWeight: 'normal'
|
|
25
|
-
}
|
|
26
|
-
};
|
|
14
|
+
var Caption = (0, _withDeprecation["default"])(_HeadingCaption["default"], {
|
|
15
|
+
name: 'Caption',
|
|
16
|
+
rename: 'HeadingCaption'
|
|
27
17
|
});
|
|
28
|
-
|
|
29
|
-
var Caption = function Caption(_ref) {
|
|
30
|
-
var props = (0, _extends2["default"])({}, _ref);
|
|
31
|
-
var classes = useStyles(props);
|
|
32
|
-
return /*#__PURE__*/_react["default"].createElement(_Typography["default"], {
|
|
33
|
-
className: (0, _clsx["default"])(props.className, classes.caption),
|
|
34
|
-
variant: "h6"
|
|
35
|
-
}, props.children);
|
|
36
|
-
};
|
|
37
|
-
|
|
38
18
|
exports.Caption = Caption;
|
|
39
19
|
var _default = Caption;
|
|
40
20
|
exports["default"] = _default;
|
package/typography/NormalText.js
CHANGED
|
@@ -5,22 +5,15 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", {
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
|
-
exports
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
8
|
+
Object.defineProperty(exports, "NormalText", {
|
|
9
|
+
enumerable: true,
|
|
10
|
+
get: function get() {
|
|
11
|
+
return _NormalText["default"];
|
|
12
|
+
}
|
|
13
|
+
});
|
|
14
|
+
exports["default"] = void 0;
|
|
15
15
|
|
|
16
|
-
|
|
17
|
-
var NormalText = function NormalText(props) {
|
|
18
|
-
return /*#__PURE__*/_react["default"].createElement(_Typography["default"], (0, _extends2["default"])({
|
|
19
|
-
component: "span",
|
|
20
|
-
variant: "body1"
|
|
21
|
-
}, props), props.children);
|
|
22
|
-
};
|
|
16
|
+
var _NormalText = _interopRequireDefault(require("@digigov/react-core/NormalText"));
|
|
23
17
|
|
|
24
|
-
|
|
25
|
-
var _default = NormalText;
|
|
18
|
+
var _default = _NormalText["default"];
|
|
26
19
|
exports["default"] = _default;
|
package/typography/Paragraph.js
CHANGED
|
@@ -5,45 +5,9 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", {
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
|
-
exports
|
|
8
|
+
exports["default"] = void 0;
|
|
9
9
|
|
|
10
|
-
var
|
|
10
|
+
var _Paragraph = _interopRequireDefault(require("@digigov/react-core/Paragraph"));
|
|
11
11
|
|
|
12
|
-
var
|
|
13
|
-
|
|
14
|
-
var _react = _interopRequireDefault(require("react"));
|
|
15
|
-
|
|
16
|
-
var _styles = require("@material-ui/core/styles");
|
|
17
|
-
|
|
18
|
-
var _Typography = _interopRequireDefault(require("@material-ui/core/Typography"));
|
|
19
|
-
|
|
20
|
-
var _excluded = ["paragraph"];
|
|
21
|
-
var useParagraphStyles = (0, _styles.makeStyles)(function (theme) {
|
|
22
|
-
return {
|
|
23
|
-
paragraph: {
|
|
24
|
-
// here be thy styles
|
|
25
|
-
margin: theme.spacing(0, 0, 2),
|
|
26
|
-
marginBottom: theme.spacing(4)
|
|
27
|
-
}
|
|
28
|
-
};
|
|
29
|
-
}, {
|
|
30
|
-
name: 'MuiParagraph'
|
|
31
|
-
});
|
|
32
|
-
exports.useParagraphStyles = useParagraphStyles;
|
|
33
|
-
;
|
|
34
|
-
|
|
35
|
-
var Paragraph = function Paragraph(props) {
|
|
36
|
-
var _useParagraphStyles = useParagraphStyles(),
|
|
37
|
-
paragraph = _useParagraphStyles.paragraph,
|
|
38
|
-
classes = (0, _objectWithoutProperties2["default"])(_useParagraphStyles, _excluded);
|
|
39
|
-
|
|
40
|
-
return /*#__PURE__*/_react["default"].createElement(_Typography["default"], (0, _extends2["default"])({
|
|
41
|
-
className: paragraph,
|
|
42
|
-
variant: "body1",
|
|
43
|
-
classes: classes
|
|
44
|
-
}, props), props.children);
|
|
45
|
-
};
|
|
46
|
-
|
|
47
|
-
exports.Paragraph = Paragraph;
|
|
48
|
-
var _default = Paragraph;
|
|
12
|
+
var _default = _Paragraph["default"];
|
|
49
13
|
exports["default"] = _default;
|
package/typography/Title.js
CHANGED
|
@@ -5,105 +5,59 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", {
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
|
-
exports["default"] = void 0;
|
|
8
|
+
exports["default"] = exports.Title = void 0;
|
|
9
9
|
|
|
10
10
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
11
11
|
|
|
12
12
|
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
|
13
13
|
|
|
14
|
-
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
15
|
-
|
|
16
14
|
var _react = _interopRequireDefault(require("react"));
|
|
17
15
|
|
|
18
|
-
var
|
|
19
|
-
|
|
20
|
-
var _styles = require("@material-ui/core/styles");
|
|
16
|
+
var _Heading = _interopRequireDefault(require("@digigov/react-core/Heading"));
|
|
21
17
|
|
|
22
|
-
var
|
|
23
|
-
_excluded2 = ["className"];
|
|
24
|
-
var useStyles = (0, _styles.makeStyles)(function (theme) {
|
|
25
|
-
var _xl;
|
|
18
|
+
var _withDeprecation = _interopRequireDefault(require("@digigov/ui/utils/withDeprecation"));
|
|
26
19
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
20
|
+
var _excluded = ["size", "component", "children"];
|
|
21
|
+
var sizeMappings = {
|
|
22
|
+
xl: 'xl',
|
|
23
|
+
lg: 'l',
|
|
24
|
+
md: 'm',
|
|
25
|
+
sm: 's'
|
|
26
|
+
};
|
|
27
|
+
var Title = (0, _withDeprecation["default"])(function (_ref) {
|
|
28
|
+
var _ref$size = _ref.size,
|
|
29
|
+
size = _ref$size === void 0 ? 'xl' : _ref$size,
|
|
30
|
+
component = _ref.component,
|
|
31
|
+
children = _ref.children,
|
|
32
|
+
props = (0, _objectWithoutProperties2["default"])(_ref, _excluded);
|
|
33
|
+
var newSize = sizeMappings[size];
|
|
34
|
+
return /*#__PURE__*/_react["default"].createElement(_Heading["default"], (0, _extends2["default"])({
|
|
35
|
+
size: newSize,
|
|
36
|
+
element: component
|
|
37
|
+
}, props), children);
|
|
38
|
+
}, {
|
|
39
|
+
name: 'Title',
|
|
40
|
+
rename: 'Heading',
|
|
41
|
+
props: {
|
|
42
|
+
dense: {
|
|
43
|
+
error: true
|
|
47
44
|
},
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
45
|
+
size: {
|
|
46
|
+
values: {
|
|
47
|
+
xs: {
|
|
48
|
+
error: true
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
51
|
},
|
|
52
|
-
|
|
53
|
-
|
|
52
|
+
component: {
|
|
53
|
+
values: {
|
|
54
|
+
h5: {
|
|
55
|
+
error: true
|
|
56
|
+
}
|
|
57
|
+
}
|
|
54
58
|
}
|
|
55
|
-
};
|
|
56
|
-
}, {
|
|
57
|
-
name: 'MuiDigigovTitle'
|
|
58
|
-
});
|
|
59
|
-
|
|
60
|
-
var getComponentBySize = function getComponentBySize(size) {
|
|
61
|
-
switch (size) {
|
|
62
|
-
case 'xl':
|
|
63
|
-
return 'h1';
|
|
64
|
-
|
|
65
|
-
case 'lg':
|
|
66
|
-
return 'h2';
|
|
67
|
-
|
|
68
|
-
case 'md':
|
|
69
|
-
return 'h3';
|
|
70
|
-
|
|
71
|
-
case 'sm':
|
|
72
|
-
return 'h4';
|
|
73
|
-
|
|
74
|
-
case 'xs':
|
|
75
|
-
return 'h5';
|
|
76
|
-
|
|
77
|
-
default:
|
|
78
|
-
return 'h4';
|
|
79
59
|
}
|
|
80
|
-
};
|
|
81
|
-
|
|
82
|
-
var
|
|
83
|
-
var size = _ref.size,
|
|
84
|
-
children = _ref.children,
|
|
85
|
-
dense = _ref.dense,
|
|
86
|
-
classesObj = _ref.classes,
|
|
87
|
-
component = _ref.component,
|
|
88
|
-
props = (0, _objectWithoutProperties2["default"])(_ref, _excluded);
|
|
89
|
-
var classes = useStyles({
|
|
90
|
-
classes: classesObj
|
|
91
|
-
});
|
|
92
|
-
var cls = classes[size || 'sm'];
|
|
93
|
-
var Tag = component || getComponentBySize(size);
|
|
94
|
-
var className = props.className,
|
|
95
|
-
otherProps = (0, _objectWithoutProperties2["default"])(props, _excluded2);
|
|
96
|
-
return /*#__PURE__*/_react["default"].createElement(Tag, (0, _extends2["default"])({
|
|
97
|
-
ref: ref,
|
|
98
|
-
className: (0, _clsx["default"])(className, classes.root, cls, dense && classes.dense)
|
|
99
|
-
}, otherProps), children);
|
|
100
|
-
};
|
|
101
|
-
|
|
102
|
-
var RefTitle = /*#__PURE__*/_react["default"].forwardRef(Title);
|
|
103
|
-
|
|
104
|
-
RefTitle.defaultProps = {
|
|
105
|
-
size: 'sm',
|
|
106
|
-
dense: false
|
|
107
|
-
};
|
|
108
|
-
var _default = RefTitle;
|
|
60
|
+
});
|
|
61
|
+
exports.Title = Title;
|
|
62
|
+
var _default = Title;
|
|
109
63
|
exports["default"] = _default;
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports["default"] = withDeprecation;
|
|
9
|
+
|
|
10
|
+
var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
|
|
11
|
+
|
|
12
|
+
var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits"));
|
|
13
|
+
|
|
14
|
+
var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));
|
|
15
|
+
|
|
16
|
+
var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));
|
|
17
|
+
|
|
18
|
+
var _wrapNativeSuper2 = _interopRequireDefault(require("@babel/runtime/helpers/wrapNativeSuper"));
|
|
19
|
+
|
|
20
|
+
var _react = _interopRequireDefault(require("react"));
|
|
21
|
+
|
|
22
|
+
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2["default"])(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2["default"])(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2["default"])(this, result); }; }
|
|
23
|
+
|
|
24
|
+
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
25
|
+
|
|
26
|
+
var DigigovError = /*#__PURE__*/function (_Error) {
|
|
27
|
+
(0, _inherits2["default"])(DigigovError, _Error);
|
|
28
|
+
|
|
29
|
+
var _super = _createSuper(DigigovError);
|
|
30
|
+
|
|
31
|
+
function DigigovError(message) {
|
|
32
|
+
var _this;
|
|
33
|
+
|
|
34
|
+
(0, _classCallCheck2["default"])(this, DigigovError);
|
|
35
|
+
_this = _super.call(this, message); // (1)
|
|
36
|
+
|
|
37
|
+
_this.name = 'DigigovError'; // (2)
|
|
38
|
+
|
|
39
|
+
return _this;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
return DigigovError;
|
|
43
|
+
}( /*#__PURE__*/(0, _wrapNativeSuper2["default"])(Error));
|
|
44
|
+
|
|
45
|
+
var loggedDeprecations = new Set();
|
|
46
|
+
|
|
47
|
+
var handleErrorWarning = function handleErrorWarning(componentName, name, _ref, type) {
|
|
48
|
+
var error = _ref.error,
|
|
49
|
+
warning = _ref.warning;
|
|
50
|
+
|
|
51
|
+
if (warning === true) {
|
|
52
|
+
console.warn("\u26A0\uFE0F ".concat(componentName, ": ").concat(name, " ").concat(type, " will be deprecated."));
|
|
53
|
+
} else if (typeof warning === 'string') {
|
|
54
|
+
console.warn(warning);
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
if (error === true) {
|
|
58
|
+
throw new DigigovError("".concat(componentName, ": !! ").concat(name, " ").concat(type, " is deprecated."));
|
|
59
|
+
} else if (typeof error === 'string') {
|
|
60
|
+
throw new DigigovError("Component `".concat(componentName, "` with `").concat(name, "` prop: ").concat(error));
|
|
61
|
+
}
|
|
62
|
+
};
|
|
63
|
+
|
|
64
|
+
function withDeprecation(Component, deprecations) {
|
|
65
|
+
var _Component$render;
|
|
66
|
+
|
|
67
|
+
var componentName = // eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
68
|
+
// @ts-ignore
|
|
69
|
+
deprecations.name || Component.name || (Component === null || Component === void 0 ? void 0 : (_Component$render = Component.render) === null || _Component$render === void 0 ? void 0 : _Component$render.name);
|
|
70
|
+
|
|
71
|
+
if (loggedDeprecations.has(componentName)) {
|
|
72
|
+
return Component;
|
|
73
|
+
} else {
|
|
74
|
+
loggedDeprecations.add(componentName);
|
|
75
|
+
} // eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
76
|
+
// @ts-ignore
|
|
77
|
+
|
|
78
|
+
|
|
79
|
+
return function withDeprecationComponent(props) {
|
|
80
|
+
if (deprecations.rename) {
|
|
81
|
+
console.warn("\u267B\uFE0F ".concat(componentName, " is renamed to ").concat(deprecations.rename, "\n"));
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
handleErrorWarning(componentName, componentName, deprecations, 'component');
|
|
85
|
+
|
|
86
|
+
if (deprecations.props) {
|
|
87
|
+
Object.keys(deprecations.props).forEach(function (propName) {
|
|
88
|
+
var _deprecations$props, _propDeprecation$valu;
|
|
89
|
+
|
|
90
|
+
var value = props[propName];
|
|
91
|
+
|
|
92
|
+
if (!value) {
|
|
93
|
+
return;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
var propDeprecation = deprecations === null || deprecations === void 0 ? void 0 : (_deprecations$props = deprecations.props) === null || _deprecations$props === void 0 ? void 0 : _deprecations$props[propName];
|
|
97
|
+
|
|
98
|
+
if (propDeprecation !== null && propDeprecation !== void 0 && (_propDeprecation$valu = propDeprecation.values) !== null && _propDeprecation$valu !== void 0 && _propDeprecation$valu[value]) {
|
|
99
|
+
var _propDeprecation$valu2;
|
|
100
|
+
|
|
101
|
+
return handleErrorWarning(componentName, "".concat(propName, " ").concat(value), propDeprecation === null || propDeprecation === void 0 ? void 0 : (_propDeprecation$valu2 = propDeprecation.values) === null || _propDeprecation$valu2 === void 0 ? void 0 : _propDeprecation$valu2[value], 'property value');
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
if (propDeprecation !== null && propDeprecation !== void 0 && propDeprecation.error || propDeprecation !== null && propDeprecation !== void 0 && propDeprecation.warning) {
|
|
105
|
+
return handleErrorWarning(componentName, propName, propDeprecation, 'property');
|
|
106
|
+
}
|
|
107
|
+
});
|
|
108
|
+
} // eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
109
|
+
// @ts-ignore
|
|
110
|
+
|
|
111
|
+
|
|
112
|
+
return /*#__PURE__*/_react["default"].createElement(Component, props);
|
|
113
|
+
};
|
|
114
|
+
}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
interface HeaderLogoProps {
|
|
3
|
-
href?: string;
|
|
4
|
-
src?: string;
|
|
5
|
-
label?: string;
|
|
6
|
-
className?: string;
|
|
7
|
-
height?: number | string;
|
|
8
|
-
linkProps?: Record<'target', '_blank' | '_self' | '_parent' | '_top'>;
|
|
9
|
-
}
|
|
10
|
-
export declare const useHeaderLogoStyles: (props?: any) => import("@material-ui/core/styles/withStyles").ClassNameMap<"root">;
|
|
11
|
-
export declare const HeaderLogo: React.FC<HeaderLogoProps>;
|
|
12
|
-
export default HeaderLogo;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { GridProps } from '@material-ui/core/Grid';
|
|
3
|
-
declare type HeaderSectionProps = GridProps;
|
|
4
|
-
export declare const useHeaderSectionStyles: (props?: any) => import("@material-ui/core/styles/withStyles").ClassNameMap<"root" | "container">;
|
|
5
|
-
export declare const HeaderSection: React.FC<HeaderSectionProps>;
|
|
6
|
-
export default HeaderSection;
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { GridProps } from '@material-ui/core/Grid';
|
|
3
|
-
import { BaseCSSProperties } from '@material-ui/core/styles/withStyles';
|
|
4
|
-
export declare type HeaderTitleStyles = {
|
|
5
|
-
root?: BaseCSSProperties;
|
|
6
|
-
grid?: BaseCSSProperties;
|
|
7
|
-
link?: BaseCSSProperties;
|
|
8
|
-
};
|
|
9
|
-
export declare const useHeaderTitleStyles: (props?: any) => import("@material-ui/core/styles/withStyles").ClassNameMap<"link" | "root" | "grid">;
|
|
10
|
-
export interface HeaderTitleProps {
|
|
11
|
-
xs?: GridProps['xs'];
|
|
12
|
-
classes?: HeaderTitleStyles;
|
|
13
|
-
className?: string;
|
|
14
|
-
href?: string;
|
|
15
|
-
linkProps?: Record<'target', '_blank' | '_self' | '_parent' | '_top'>;
|
|
16
|
-
linkComponent?: React.ElementType;
|
|
17
|
-
}
|
|
18
|
-
export declare const HeaderTitle: React.FC<HeaderTitleProps>;
|
|
19
|
-
export interface HeaderSubtitleProps {
|
|
20
|
-
classes?: {
|
|
21
|
-
root: BaseCSSProperties;
|
|
22
|
-
};
|
|
23
|
-
}
|
|
24
|
-
export declare const useHeaderSubtitleStyles: (props?: any) => import("@material-ui/core/styles/withStyles").ClassNameMap<"root">;
|
|
25
|
-
export declare const HeaderSubtitle: React.FC<HeaderTitleProps>;
|
|
26
|
-
export default HeaderTitle;
|
package/app/Header/index.d.ts
DELETED
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { AppBarProps } from '@material-ui/core/AppBar';
|
|
3
|
-
import { ContainerProps as MuiContainerProps } from '@material-ui/core/Container';
|
|
4
|
-
import { BaseCSSProperties } from '@material-ui/core/styles/withStyles';
|
|
5
|
-
export declare type HeaderStyles = {
|
|
6
|
-
root?: BaseCSSProperties;
|
|
7
|
-
appbar?: BaseCSSProperties;
|
|
8
|
-
toolbar?: BaseCSSProperties;
|
|
9
|
-
coloredBar?: BaseCSSProperties;
|
|
10
|
-
};
|
|
11
|
-
interface HeaderProps extends Omit<AppBarProps, 'classes'> {
|
|
12
|
-
maxWidth?: MuiContainerProps['maxWidth'];
|
|
13
|
-
classes?: HeaderStyles;
|
|
14
|
-
}
|
|
15
|
-
export declare const useHeaderStyles: (props?: any) => import("@material-ui/core/styles/withStyles").ClassNameMap<"root" | "toolbar" | "coloredBar">;
|
|
16
|
-
export declare const Header: React.FC<HeaderProps>;
|
|
17
|
-
export * from '@digigov/ui/app/Header/HeaderTitle';
|
|
18
|
-
export * from '@digigov/ui/app/Header/HeaderLogo';
|
|
19
|
-
export * from '@digigov/ui/app/Header/HeaderSection';
|
|
20
|
-
export default Header;
|
package/app/PageTitle.d.ts
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { CaptionProps } from '@digigov/ui/typography/Caption';
|
|
3
|
-
import { TitleProps, TitleStyles } from '@digigov/ui/typography/Title';
|
|
4
|
-
import { BaseCSSProperties } from '@material-ui/core/styles/withStyles';
|
|
5
|
-
import { GridProps } from '@material-ui/core/Grid';
|
|
6
|
-
interface PageTitleProps extends GridProps {
|
|
7
|
-
preserveHeight?: boolean;
|
|
8
|
-
}
|
|
9
|
-
export declare const PageTitle: React.FC<PageTitleProps>;
|
|
10
|
-
export default PageTitle;
|
|
11
|
-
export declare const PageTitleSection: React.FC<GridProps>;
|
|
12
|
-
export declare const PageTitleCaption: React.FC<CaptionProps>;
|
|
13
|
-
export interface PageTitleHeadingStyles extends TitleStyles {
|
|
14
|
-
dense?: BaseCSSProperties;
|
|
15
|
-
}
|
|
16
|
-
export interface PageTitleHeadingProps extends Omit<TitleProps, 'classes'> {
|
|
17
|
-
classes?: PageTitleHeadingStyles;
|
|
18
|
-
dense?: boolean;
|
|
19
|
-
className?: string;
|
|
20
|
-
}
|
|
21
|
-
export declare const PageTitleHeading: React.FC<PageTitleHeadingProps>;
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
interface AccordionItemDetailsProps {
|
|
3
|
-
children: React.ReactNode;
|
|
4
|
-
className?: string;
|
|
5
|
-
}
|
|
6
|
-
export declare const AccordionItemDetails: React.FC<AccordionItemDetailsProps>;
|
|
7
|
-
interface AccordionItemSummaryProps {
|
|
8
|
-
children: React.ReactNode;
|
|
9
|
-
className?: string;
|
|
10
|
-
icon?: React.ReactNode;
|
|
11
|
-
}
|
|
12
|
-
export declare const AccordionItemSummary: React.FC<AccordionItemSummaryProps>;
|
|
13
|
-
interface AccordionItemProps {
|
|
14
|
-
children: React.FunctionComponentElement<typeof AccordionItemSummary | typeof AccordionItemDetails>[];
|
|
15
|
-
className?: string;
|
|
16
|
-
}
|
|
17
|
-
export declare const AccordionItem: React.FC<AccordionItemProps>;
|
|
18
|
-
interface AccordionProps {
|
|
19
|
-
children: React.ReactNode;
|
|
20
|
-
className?: string;
|
|
21
|
-
}
|
|
22
|
-
export declare const Accordion: React.FC<AccordionProps>;
|
|
23
|
-
export {};
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
export declare const useBlockquoteStyles: (props?: any) => import("@material-ui/core/styles/withStyles").ClassNameMap<"root" | "info" | "warning" | "error" | "success">;
|
|
3
|
-
export interface BlockquoteProps {
|
|
4
|
-
children: React.ReactNode;
|
|
5
|
-
variant?: 'info' | 'warning' | 'error' | 'success';
|
|
6
|
-
className?: string;
|
|
7
|
-
}
|
|
8
|
-
export declare const Blockquote: React.FC<BlockquoteProps>;
|
|
9
|
-
export default Blockquote;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { ButtonProps } from '@digigov/ui/core/Button';
|
|
3
|
-
export interface CallToActionProps extends ButtonProps {
|
|
4
|
-
label?: string;
|
|
5
|
-
children?: React.ReactNode;
|
|
6
|
-
}
|
|
7
|
-
export declare const ButtonIcon: React.FC<CallToActionProps>;
|
|
8
|
-
export default ButtonIcon;
|
package/core/Button/Icon.d.ts
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { ButtonProps } from '@digigov/ui/core/Button';
|
|
3
|
-
export interface ButtonIconProps extends ButtonProps {
|
|
4
|
-
Icon: React.ElementType;
|
|
5
|
-
icon: string;
|
|
6
|
-
label: string;
|
|
7
|
-
}
|
|
8
|
-
export declare const ButtonIcon: React.FC<ButtonIconProps>;
|
|
9
|
-
export default ButtonIcon;
|