@reykjavik/hanna-react 0.10.56 → 0.10.59
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/{AccordionList.jsx → AccordionList.js} +5 -14
- package/ActionCards.d.ts +1 -1
- package/{ActionCards.jsx → ActionCards.js} +3 -4
- package/{Alert.jsx → Alert.js} +7 -9
- package/ArticleCards.d.ts +6 -0
- package/ArticleCards.js +9 -0
- package/ArticleCarousel/_ArticleCarouselCard.d.ts +1 -1
- package/ArticleCarousel/_ArticleCarouselCard.js +31 -0
- package/{ArticleCarousel.jsx → ArticleCarousel.js} +1 -1
- package/ArticleMeta.d.ts +1 -0
- package/{ArticleMeta.jsx → ArticleMeta.js} +15 -10
- package/{Attention.jsx → Attention.js} +1 -1
- package/{BasicTable.jsx → BasicTable.js} +11 -12
- package/BgBox.d.ts +8 -0
- package/BgBox.js +14 -0
- package/{Bling.jsx → Bling.js} +2 -2
- package/{BlockBreak.jsx → BlockBreak.js} +1 -1
- package/{BlockQuote.jsx → BlockQuote.js} +1 -1
- package/BreadCrumbs.js +33 -0
- package/ButtonBack.d.ts +1 -1
- package/{ButtonBack.jsx → ButtonBack.js} +2 -2
- package/{ButtonBar.jsx → ButtonBar.js} +2 -4
- package/ButtonPrimary.d.ts +1 -1
- package/{ButtonPrimary.jsx → ButtonPrimary.js} +2 -2
- package/ButtonSecondary.d.ts +1 -1
- package/{ButtonSecondary.jsx → ButtonSecondary.js} +2 -2
- package/ButtonTertiary.d.ts +1 -1
- package/{ButtonTertiary.jsx → ButtonTertiary.js} +2 -2
- package/CHANGELOG.md +12 -1
- package/{Carousel.jsx → Carousel.js} +1 -1
- package/{CarouselStepper.jsx → CarouselStepper.js} +1 -1
- package/{CenterColumn.jsx → CenterColumn.js} +1 -3
- package/Checkbox.d.ts +1 -1
- package/{Checkbox.jsx → Checkbox.js} +2 -2
- package/CheckboxButtonsGroup.d.ts +1 -1
- package/{CheckboxButtonsGroup.jsx → CheckboxButtonsGroup.js} +4 -4
- package/CheckboxGroup.d.ts +1 -1
- package/{CheckboxGroup.jsx → CheckboxGroup.js} +2 -2
- package/CityBlock.d.ts +1 -1
- package/{CityBlock.jsx → CityBlock.js} +1 -1
- package/{ContactBubble.jsx → ContactBubble.js} +13 -27
- package/{ContentArticle.jsx → ContentArticle.js} +9 -12
- package/ContentImage.d.ts +1 -1
- package/ContentImage.js +23 -0
- package/{Datepicker.jsx → Datepicker.js} +17 -18
- package/ExtraLinks.d.ts +1 -1
- package/{ExtraLinks.jsx → ExtraLinks.js} +11 -19
- package/FeatureList.js +21 -0
- package/{FieldGroup.jsx → FieldGroup.js} +3 -4
- package/{FileInput.jsx → FileInput.js} +22 -25
- package/{Foonote.jsx → Foonote.js} +0 -0
- package/FooterBadges.js +17 -0
- package/FooterInfo.js +14 -0
- package/{Footnote.jsx → Footnote.js} +1 -1
- package/{Form.jsx → Form.js} +2 -4
- package/{FormField.jsx → FormField.js} +20 -22
- package/Gallery/_GalleryItem.d.ts +1 -1
- package/Gallery/{_GalleryItem.jsx → _GalleryItem.js} +10 -11
- package/Gallery/{_GalleryModal.jsx → _GalleryModal.js} +11 -15
- package/Gallery/{_GalleryModalItem.jsx → _GalleryModalItem.js} +6 -8
- package/{Gallery.jsx → Gallery.js} +3 -4
- package/GridBlocks.d.ts +2 -2
- package/GridBlocks.js +29 -0
- package/Heading.d.ts +1 -1
- package/{Heading.jsx → Heading.js} +3 -5
- package/HeroBlock.d.ts +2 -2
- package/{HeroBlock.jsx → HeroBlock.js} +9 -10
- package/{IframeBlock.jsx → IframeBlock.js} +6 -6
- package/Illustration.d.ts +1 -1
- package/{Illustration.jsx → Illustration.js} +2 -2
- package/ImageCards.d.ts +1 -1
- package/{ImageCards.jsx → ImageCards.js} +3 -4
- package/InfoBlock.js +18 -0
- package/InfoHero.d.ts +2 -2
- package/{InfoHero.jsx → InfoHero.js} +10 -16
- package/IslandBlock.d.ts +1 -1
- package/{IslandBlock.jsx → IslandBlock.js} +1 -1
- package/IslandPageBlock.d.ts +1 -1
- package/{IslandPageBlock.jsx → IslandPageBlock.js} +1 -1
- package/LabeledTextBlock.d.ts +1 -1
- package/{LabeledTextBlock.jsx → LabeledTextBlock.js} +5 -7
- package/Layout.js +58 -0
- package/MainMenu/_Auxiliary.js +20 -0
- package/MainMenu/_PrimaryPanel.js +29 -0
- package/{MainMenu.jsx → MainMenu.js} +28 -41
- package/MiniMetrics.d.ts +1 -1
- package/{MiniMetrics.jsx → MiniMetrics.js} +6 -5
- package/Modal.js +19 -0
- package/{NameCard.jsx → NameCard.js} +19 -24
- package/{NameCards.jsx → NameCards.js} +1 -3
- package/NewsHero.d.ts +1 -1
- package/{NewsHero.jsx → NewsHero.js} +8 -10
- package/{PageFilter.jsx → PageFilter.js} +6 -7
- package/{PageHeading.jsx → PageHeading.js} +2 -4
- package/Picture.d.ts +7 -0
- package/Picture.js +13 -0
- package/ProcessOverview.js +22 -0
- package/{PullQuote.jsx → PullQuote.js} +1 -1
- package/RadioButtonsGroup.d.ts +1 -1
- package/{RadioButtonsGroup.jsx → RadioButtonsGroup.js} +4 -4
- package/RadioGroup.d.ts +2 -2
- package/RadioGroup.js +12 -0
- package/RelatedLinks.js +31 -0
- package/{RowBlock.jsx → RowBlock.js} +1 -3
- package/{RowBlockColumn.jsx → RowBlockColumn.js} +2 -4
- package/{SearchInput.jsx → SearchInput.js} +4 -6
- package/SearchResults/_SearchResultsItem.js +20 -0
- package/{SearchResults.jsx → SearchResults.js} +27 -36
- package/{SeenEffect.jsx → SeenEffect.js} +1 -1
- package/{Selectbox.jsx → Selectbox.js} +1 -1
- package/{ShareButtons.jsx → ShareButtons.js} +7 -13
- package/{Sharpie.jsx → Sharpie.js} +1 -1
- package/{SiteSearchAutocomplete.jsx → SiteSearchAutocomplete.js} +5 -7
- package/{SiteSearchCurtain.jsx → SiteSearchCurtain.js} +1 -5
- package/SiteSearchInput.d.ts +1 -1
- package/{SiteSearchInput.jsx → SiteSearchInput.js} +10 -12
- package/{Skeleton.jsx → Skeleton.js} +5 -5
- package/{SubHeading.jsx → SubHeading.js} +2 -4
- package/{Tabs.jsx → Tabs.js} +12 -12
- package/TagPill.d.ts +1 -1
- package/{TagPill.jsx → TagPill.js} +12 -17
- package/{TextBlock.jsx → TextBlock.js} +2 -4
- package/TextButton.d.ts +1 -1
- package/{TextButton.jsx → TextButton.js} +2 -2
- package/{TextInput.jsx → TextInput.js} +1 -1
- package/{VSpacer.jsx → VSpacer.js} +1 -1
- package/{VerticalTabsTOC.jsx → VerticalTabsTOC.js} +2 -2
- package/WizardLayout.js +35 -0
- package/WizardLayoutClose.d.ts +1 -1
- package/{WizardLayoutClose.jsx → WizardLayoutClose.js} +2 -2
- package/WizardStepper.js +30 -0
- package/_abstract/{_AbstractCarousel.jsx → _AbstractCarousel.js} +7 -10
- package/_abstract/{_Blings.jsx → _Blings.js} +1 -3
- package/_abstract/_Block.d.ts +2 -2
- package/_abstract/_Block.js +29 -0
- package/_abstract/{Button.d.ts → _Button.d.ts} +0 -0
- package/_abstract/{Button.jsx → _Button.js} +3 -7
- package/_abstract/{CardList.d.ts → _CardList.d.ts} +2 -1
- package/_abstract/_CardList.js +45 -0
- package/{esm/_abstract/Image.d.ts → _abstract/_Image.d.ts} +9 -5
- package/_abstract/{Image.jsx → _Image.js} +11 -13
- package/_abstract/{Link.d.ts → _Link.d.ts} +0 -0
- package/_abstract/{Link.jsx → _Link.js} +0 -0
- package/_abstract/_Quote.js +15 -0
- package/{esm/_abstract/TogglerGroup.d.ts → _abstract/_TogglerGroup.d.ts} +1 -1
- package/_abstract/_TogglerGroup.js +34 -0
- package/_abstract/{TogglerGroupField.d.ts → _TogglerGroupField.d.ts} +2 -2
- package/_abstract/{TogglerGroupField.jsx → _TogglerGroupField.js} +4 -4
- package/_abstract/{TogglerInput.d.ts → _TogglerInput.d.ts} +0 -0
- package/_abstract/{TogglerInput.jsx → _TogglerInput.js} +13 -15
- package/_abstract/{breakOnNL.jsx → breakOnNL.js} +1 -1
- package/esm/AccordionList.js +24 -0
- package/esm/ActionCards.d.ts +1 -1
- package/esm/ActionCards.js +9 -0
- package/esm/{Alert.jsx → Alert.js} +7 -9
- package/esm/ArticleCards.d.ts +6 -0
- package/esm/ArticleCards.js +4 -0
- package/esm/ArticleCarousel/_ArticleCarouselCard.d.ts +1 -1
- package/esm/ArticleCarousel/_ArticleCarouselCard.js +24 -0
- package/esm/{ArticleCarousel.jsx → ArticleCarousel.js} +1 -1
- package/esm/ArticleMeta.d.ts +1 -0
- package/esm/ArticleMeta.js +19 -0
- package/esm/Attention.js +4 -0
- package/esm/{BasicTable.jsx → BasicTable.js} +11 -12
- package/esm/BgBox.d.ts +8 -0
- package/esm/BgBox.js +9 -0
- package/esm/{Bling.jsx → Bling.js} +2 -2
- package/esm/BlockBreak.js +6 -0
- package/esm/BlockQuote.js +4 -0
- package/esm/BreadCrumbs.js +28 -0
- package/esm/ButtonBack.d.ts +1 -1
- package/esm/ButtonBack.js +4 -0
- package/esm/{ButtonBar.jsx → ButtonBar.js} +2 -4
- package/esm/ButtonPrimary.d.ts +1 -1
- package/esm/ButtonPrimary.js +4 -0
- package/esm/ButtonSecondary.d.ts +1 -1
- package/esm/ButtonSecondary.js +4 -0
- package/esm/ButtonTertiary.d.ts +1 -1
- package/esm/{ButtonTertiary.jsx → ButtonTertiary.js} +2 -2
- package/esm/Carousel.js +4 -0
- package/esm/CarouselStepper.js +4 -0
- package/esm/CenterColumn.js +7 -0
- package/esm/Checkbox.d.ts +1 -1
- package/esm/Checkbox.js +4 -0
- package/esm/CheckboxButtonsGroup.d.ts +1 -1
- package/esm/CheckboxButtonsGroup.js +14 -0
- package/esm/CheckboxGroup.d.ts +1 -1
- package/esm/CheckboxGroup.js +7 -0
- package/esm/CityBlock.d.ts +1 -1
- package/esm/{CityBlock.jsx → CityBlock.js} +1 -1
- package/esm/{ContactBubble.jsx → ContactBubble.js} +13 -27
- package/esm/ContentArticle.js +21 -0
- package/esm/ContentImage.d.ts +1 -1
- package/esm/ContentImage.js +18 -0
- package/esm/{Datepicker.jsx → Datepicker.js} +17 -18
- package/esm/ExtraLinks.d.ts +1 -1
- package/esm/{ExtraLinks.jsx → ExtraLinks.js} +11 -19
- package/esm/FeatureList.js +16 -0
- package/esm/FieldGroup.js +9 -0
- package/esm/{FileInput.jsx → FileInput.js} +22 -25
- package/esm/{Foonote.jsx → Foonote.js} +0 -0
- package/esm/FooterBadges.js +12 -0
- package/esm/FooterInfo.js +9 -0
- package/esm/Footnote.js +3 -0
- package/esm/{Form.jsx → Form.js} +2 -4
- package/esm/{FormField.jsx → FormField.js} +20 -22
- package/esm/Gallery/_GalleryItem.d.ts +1 -1
- package/esm/Gallery/{_GalleryItem.jsx → _GalleryItem.js} +10 -11
- package/esm/Gallery/{_GalleryModal.jsx → _GalleryModal.js} +11 -15
- package/esm/Gallery/{_GalleryModalItem.jsx → _GalleryModalItem.js} +6 -8
- package/esm/{Gallery.jsx → Gallery.js} +3 -4
- package/esm/GridBlocks.d.ts +2 -2
- package/esm/GridBlocks.js +24 -0
- package/esm/Heading.d.ts +1 -1
- package/esm/{Heading.jsx → Heading.js} +3 -5
- package/esm/HeroBlock.d.ts +2 -2
- package/esm/HeroBlock.js +21 -0
- package/esm/{IframeBlock.jsx → IframeBlock.js} +6 -6
- package/esm/Illustration.d.ts +1 -1
- package/esm/{Illustration.jsx → Illustration.js} +2 -2
- package/esm/ImageCards.d.ts +1 -1
- package/esm/{ImageCards.jsx → ImageCards.js} +3 -4
- package/esm/InfoBlock.js +13 -0
- package/esm/InfoHero.d.ts +2 -2
- package/esm/{InfoHero.jsx → InfoHero.js} +10 -16
- package/esm/IslandBlock.d.ts +1 -1
- package/esm/{IslandBlock.jsx → IslandBlock.js} +1 -1
- package/esm/IslandPageBlock.d.ts +1 -1
- package/esm/{IslandPageBlock.jsx → IslandPageBlock.js} +1 -1
- package/esm/LabeledTextBlock.d.ts +1 -1
- package/esm/LabeledTextBlock.js +14 -0
- package/esm/Layout.js +52 -0
- package/esm/MainMenu/_Auxiliary.js +13 -0
- package/esm/MainMenu/_PrimaryPanel.js +22 -0
- package/esm/{MainMenu.jsx → MainMenu.js} +28 -41
- package/esm/MiniMetrics.d.ts +1 -1
- package/esm/MiniMetrics.js +12 -0
- package/esm/Modal.js +14 -0
- package/esm/{NameCard.jsx → NameCard.js} +19 -24
- package/esm/NameCards.js +7 -0
- package/esm/NewsHero.d.ts +1 -1
- package/esm/{NewsHero.jsx → NewsHero.js} +8 -10
- package/esm/PageFilter.js +15 -0
- package/esm/{PageHeading.jsx → PageHeading.js} +2 -4
- package/esm/Picture.d.ts +7 -0
- package/esm/Picture.js +8 -0
- package/esm/ProcessOverview.js +17 -0
- package/esm/PullQuote.js +4 -0
- package/esm/RadioButtonsGroup.d.ts +1 -1
- package/esm/RadioButtonsGroup.js +14 -0
- package/esm/RadioGroup.d.ts +2 -2
- package/esm/RadioGroup.js +7 -0
- package/esm/RelatedLinks.js +26 -0
- package/esm/{RowBlock.jsx → RowBlock.js} +1 -3
- package/esm/{RowBlockColumn.jsx → RowBlockColumn.js} +2 -4
- package/esm/{SearchInput.jsx → SearchInput.js} +4 -6
- package/esm/SearchResults/_SearchResultsItem.js +15 -0
- package/esm/{SearchResults.jsx → SearchResults.js} +27 -36
- package/esm/{SeenEffect.jsx → SeenEffect.js} +1 -1
- package/esm/{Selectbox.jsx → Selectbox.js} +1 -1
- package/esm/{ShareButtons.jsx → ShareButtons.js} +7 -13
- package/esm/{Sharpie.jsx → Sharpie.js} +1 -1
- package/esm/{SiteSearchAutocomplete.jsx → SiteSearchAutocomplete.js} +5 -7
- package/esm/{SiteSearchCurtain.jsx → SiteSearchCurtain.js} +1 -5
- package/esm/SiteSearchInput.d.ts +1 -1
- package/esm/{SiteSearchInput.jsx → SiteSearchInput.js} +10 -12
- package/esm/{Skeleton.jsx → Skeleton.js} +5 -5
- package/esm/{SubHeading.jsx → SubHeading.js} +2 -4
- package/esm/{Tabs.jsx → Tabs.js} +12 -12
- package/esm/TagPill.d.ts +1 -1
- package/esm/{TagPill.jsx → TagPill.js} +12 -17
- package/esm/{TextBlock.jsx → TextBlock.js} +2 -4
- package/esm/TextButton.d.ts +1 -1
- package/esm/{TextButton.jsx → TextButton.js} +2 -2
- package/esm/{TextInput.jsx → TextInput.js} +1 -1
- package/esm/{VSpacer.jsx → VSpacer.js} +1 -1
- package/esm/{VerticalTabsTOC.jsx → VerticalTabsTOC.js} +2 -2
- package/esm/WizardLayout.js +30 -0
- package/esm/WizardLayoutClose.d.ts +1 -1
- package/esm/WizardLayoutClose.js +4 -0
- package/esm/WizardStepper.js +25 -0
- package/esm/_abstract/{_AbstractCarousel.jsx → _AbstractCarousel.js} +7 -10
- package/esm/_abstract/_Blings.js +12 -0
- package/esm/_abstract/_Block.d.ts +2 -2
- package/esm/_abstract/_Block.js +24 -0
- package/esm/_abstract/{Button.d.ts → _Button.d.ts} +0 -0
- package/esm/_abstract/{Button.jsx → _Button.js} +3 -7
- package/esm/_abstract/{CardList.d.ts → _CardList.d.ts} +2 -1
- package/esm/_abstract/_CardList.js +38 -0
- package/{_abstract/Image.d.ts → esm/_abstract/_Image.d.ts} +9 -5
- package/esm/_abstract/_Image.js +27 -0
- package/esm/_abstract/{Link.d.ts → _Link.d.ts} +0 -0
- package/esm/_abstract/{Link.jsx → _Link.js} +0 -0
- package/esm/_abstract/_Quote.js +8 -0
- package/{_abstract/TogglerGroup.d.ts → esm/_abstract/_TogglerGroup.d.ts} +1 -1
- package/esm/_abstract/_TogglerGroup.js +29 -0
- package/esm/_abstract/{TogglerGroupField.d.ts → _TogglerGroupField.d.ts} +2 -2
- package/esm/_abstract/{TogglerGroupField.jsx → _TogglerGroupField.js} +4 -4
- package/esm/_abstract/{TogglerInput.d.ts → _TogglerInput.d.ts} +0 -0
- package/esm/_abstract/{TogglerInput.jsx → _TogglerInput.js} +13 -15
- package/esm/_abstract/{breakOnNL.jsx → breakOnNL.js} +1 -1
- package/esm/utils/seenEffect.d.ts +2 -2
- package/esm/utils/seenEffect.js +1 -1
- package/package.json +106 -91
- package/utils/seenEffect.d.ts +2 -2
- package/utils/seenEffect.js +1 -1
- package/ArticleCarousel/_ArticleCarouselCard.jsx +0 -32
- package/BreadCrumbs.jsx +0 -36
- package/ContentImage.jsx +0 -18
- package/FeatureList.jsx +0 -28
- package/FooterBadges.jsx +0 -21
- package/FooterInfo.jsx +0 -19
- package/GridBlocks.jsx +0 -40
- package/InfoBlock.jsx +0 -23
- package/Layout.jsx +0 -69
- package/MainMenu/_Auxiliary.jsx +0 -26
- package/MainMenu/_PrimaryPanel.jsx +0 -37
- package/Modal.jsx +0 -21
- package/ProcessOverview.jsx +0 -25
- package/RadioGroup.jsx +0 -12
- package/RelatedLinks.jsx +0 -35
- package/SearchResults/_SearchResultsItem.jsx +0 -24
- package/WizardLayout.jsx +0 -44
- package/WizardStepper.jsx +0 -34
- package/_abstract/CardList.jsx +0 -46
- package/_abstract/TogglerGroup.jsx +0 -36
- package/_abstract/_Block.jsx +0 -32
- package/_abstract/_Quote.jsx +0 -18
- package/esm/AccordionList.jsx +0 -33
- package/esm/ActionCards.jsx +0 -10
- package/esm/ArticleCarousel/_ArticleCarouselCard.jsx +0 -25
- package/esm/ArticleMeta.jsx +0 -17
- package/esm/Attention.jsx +0 -4
- package/esm/BlockBreak.jsx +0 -6
- package/esm/BlockQuote.jsx +0 -4
- package/esm/BreadCrumbs.jsx +0 -31
- package/esm/ButtonBack.jsx +0 -4
- package/esm/ButtonPrimary.jsx +0 -4
- package/esm/ButtonSecondary.jsx +0 -4
- package/esm/Carousel.jsx +0 -4
- package/esm/CarouselStepper.jsx +0 -4
- package/esm/CenterColumn.jsx +0 -9
- package/esm/Checkbox.jsx +0 -4
- package/esm/CheckboxButtonsGroup.jsx +0 -14
- package/esm/CheckboxGroup.jsx +0 -7
- package/esm/ContentArticle.jsx +0 -24
- package/esm/ContentImage.jsx +0 -13
- package/esm/FeatureList.jsx +0 -23
- package/esm/FieldGroup.jsx +0 -10
- package/esm/FooterBadges.jsx +0 -16
- package/esm/FooterInfo.jsx +0 -14
- package/esm/Footnote.jsx +0 -3
- package/esm/GridBlocks.jsx +0 -35
- package/esm/HeroBlock.jsx +0 -22
- package/esm/InfoBlock.jsx +0 -18
- package/esm/LabeledTextBlock.jsx +0 -16
- package/esm/Layout.jsx +0 -63
- package/esm/MainMenu/_Auxiliary.jsx +0 -19
- package/esm/MainMenu/_PrimaryPanel.jsx +0 -30
- package/esm/MiniMetrics.jsx +0 -11
- package/esm/Modal.jsx +0 -16
- package/esm/NameCards.jsx +0 -9
- package/esm/PageFilter.jsx +0 -16
- package/esm/ProcessOverview.jsx +0 -20
- package/esm/PullQuote.jsx +0 -4
- package/esm/RadioButtonsGroup.jsx +0 -14
- package/esm/RadioGroup.jsx +0 -7
- package/esm/RelatedLinks.jsx +0 -30
- package/esm/SearchResults/_SearchResultsItem.jsx +0 -19
- package/esm/WizardLayout.jsx +0 -39
- package/esm/WizardLayoutClose.jsx +0 -4
- package/esm/WizardStepper.jsx +0 -29
- package/esm/_abstract/CardList.jsx +0 -39
- package/esm/_abstract/Image.jsx +0 -29
- package/esm/_abstract/TogglerGroup.jsx +0 -31
- package/esm/_abstract/_Blings.jsx +0 -14
- package/esm/_abstract/_Block.jsx +0 -27
- package/esm/_abstract/_Quote.jsx +0 -11
package/esm/WizardLayout.jsx
DELETED
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { useIsBrowserSide } from '@hugsmidjan/react/hooks';
|
|
3
|
-
import { getAssetUrl } from '@reykjavik/hanna-utils/assets';
|
|
4
|
-
import Image from './_abstract/Image';
|
|
5
|
-
import { Link } from './_abstract/Link';
|
|
6
|
-
import { useScrollbarWidthCSSVar } from './utils/useScrollbarWidthCSSVar';
|
|
7
|
-
const WizardLayout = (props) => {
|
|
8
|
-
useScrollbarWidthCSSVar();
|
|
9
|
-
const {
|
|
10
|
-
// ssr,
|
|
11
|
-
wizardStepper, wizardFooter, children, colorTheme, logoLink = '/', siteName = 'Reykjavík', globalAlerts, } = props;
|
|
12
|
-
const isBrowser = useIsBrowserSide( /* ssr */);
|
|
13
|
-
return (<div className="WizardLayout" data-sprinkled={isBrowser} data-color-theme={colorTheme}>
|
|
14
|
-
{globalAlerts && (<div className="WizardLayout__alerts" role="alert">
|
|
15
|
-
{globalAlerts}
|
|
16
|
-
</div>)}
|
|
17
|
-
<div className="WizardLayout__content">
|
|
18
|
-
<div className="WizardLayout__header" role="banner">
|
|
19
|
-
<Link className="WizardLayout__header__logo" href={logoLink}>
|
|
20
|
-
{' '}
|
|
21
|
-
<Image inline={true} src={getAssetUrl('reykjavik-logo.svg')}/> {siteName}{' '}
|
|
22
|
-
</Link>{' '}
|
|
23
|
-
</div>
|
|
24
|
-
<div className="WizardLayout__wrap">
|
|
25
|
-
{wizardStepper && (<div className="WizardLayout__stepper" role="navigation">
|
|
26
|
-
{wizardStepper}
|
|
27
|
-
</div>)}
|
|
28
|
-
<div className="WizardLayout__main" role="main">
|
|
29
|
-
{children}
|
|
30
|
-
</div>
|
|
31
|
-
<div className="WizardLayout__deco WizardLayout__deco--geometry"/>
|
|
32
|
-
</div>
|
|
33
|
-
<div className="WizardLayout__footer" role="complementary">
|
|
34
|
-
{wizardFooter}
|
|
35
|
-
</div>
|
|
36
|
-
</div>
|
|
37
|
-
</div>);
|
|
38
|
-
};
|
|
39
|
-
export default WizardLayout;
|
package/esm/WizardStepper.jsx
DELETED
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import getBemClass from '@hugsmidjan/react/utils/getBemClass';
|
|
3
|
-
const WizardStepper = (props) => {
|
|
4
|
-
const { steps, activeStep = -1, allowForwardSkip, disableBacktrack, onClick } = props;
|
|
5
|
-
return (<div className={getBemClass('WizardStepper', activeStep === -1 && 'preview')}>
|
|
6
|
-
{steps.map((step, i) => {
|
|
7
|
-
const { label, clickable, done, neutral } = step;
|
|
8
|
-
const stepClass = getBemClass('WizardStepper__step', [
|
|
9
|
-
(done || (done == null && i < activeStep)) && 'done',
|
|
10
|
-
neutral && 'neutral',
|
|
11
|
-
]);
|
|
12
|
-
const isClickable = clickable === 'always' ||
|
|
13
|
-
(clickable &&
|
|
14
|
-
(activeStep === i ||
|
|
15
|
-
(i > activeStep && allowForwardSkip) ||
|
|
16
|
-
(i < activeStep && !disableBacktrack)));
|
|
17
|
-
const ariaCurrent = activeStep === i ? 'step' : undefined;
|
|
18
|
-
return (<React.Fragment key={i}>
|
|
19
|
-
{isClickable ? (<button type="button" className={stepClass} onClick={() => onClick(i)} aria-current={ariaCurrent}>
|
|
20
|
-
{label}
|
|
21
|
-
</button>) : (<span className={stepClass} aria-current={ariaCurrent}>
|
|
22
|
-
{' '}
|
|
23
|
-
{label}{' '}
|
|
24
|
-
</span>)}{' '}
|
|
25
|
-
</React.Fragment>);
|
|
26
|
-
})}
|
|
27
|
-
</div>);
|
|
28
|
-
};
|
|
29
|
-
export default WizardStepper;
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import Button from './Button';
|
|
3
|
-
import Image from './Image';
|
|
4
|
-
const Card = (props) => {
|
|
5
|
-
const { bem, href, title, imgPlaceholder } = props;
|
|
6
|
-
const cardClass = `${bem}__card`;
|
|
7
|
-
const image = 'image' in props && props.image;
|
|
8
|
-
const meta = 'meta' in props && props.meta;
|
|
9
|
-
const summary = 'summary' in props && props.summary;
|
|
10
|
-
return (<>
|
|
11
|
-
<Button bem={cardClass} href={href}>
|
|
12
|
-
{' '}
|
|
13
|
-
<Image className={`${bem}__image`} {...image} placeholder={imgPlaceholder}/>
|
|
14
|
-
<span className={`${cardClass}__title`}>{title}</span>{' '}
|
|
15
|
-
{meta && <span className={`${cardClass}__meta`}>{meta}</span>}{' '}
|
|
16
|
-
{summary && <span className={`${cardClass}__summary`}>{summary}</span>}{' '}
|
|
17
|
-
</Button>{' '}
|
|
18
|
-
</>);
|
|
19
|
-
};
|
|
20
|
-
export const CardList = (props) => {
|
|
21
|
-
const { bemPrefix, title, summaryElement, cards, titleTag = 'h2', children, imgPlaceholder, } = props;
|
|
22
|
-
const TitleTag = titleTag;
|
|
23
|
-
const fallbackImage = (imgPlaceholder !== true && imgPlaceholder) || undefined;
|
|
24
|
-
const fallbackImageStyle = fallbackImage
|
|
25
|
-
? { '--ImageCards--fallback': `url("${fallbackImage}")` }
|
|
26
|
-
: undefined;
|
|
27
|
-
return (<>
|
|
28
|
-
{summaryElement ? (<div className={bemPrefix + '__summary'}>
|
|
29
|
-
{title && <TitleTag className={bemPrefix + '__title'}>{title}</TitleTag>}
|
|
30
|
-
{summaryElement}
|
|
31
|
-
</div>) : (title && <TitleTag className={bemPrefix + '__title'}>{title}</TitleTag>)}
|
|
32
|
-
<ul className={bemPrefix + '__list'} style={fallbackImageStyle}>
|
|
33
|
-
{cards.map((card, i) => (<li key={i} className={bemPrefix + '__item'}>
|
|
34
|
-
<Card {...card} bem={bemPrefix} imgPlaceholder={!!imgPlaceholder}/>
|
|
35
|
-
</li>))}
|
|
36
|
-
</ul>
|
|
37
|
-
{children}
|
|
38
|
-
</>);
|
|
39
|
-
};
|
package/esm/_abstract/Image.jsx
DELETED
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import getBemClass from '@hugsmidjan/react/utils/getBemClass';
|
|
3
|
-
import { useGetSVGtext } from '../utils/useGetSVGtext';
|
|
4
|
-
// eslint-disable-next-line complexity
|
|
5
|
-
const Image = (props) => {
|
|
6
|
-
const { src, altText = '', sources = [], preloadSrc, className, inline, placeholder, } = props;
|
|
7
|
-
const _src = (sources.length && preloadSrc) || src;
|
|
8
|
-
const imageSrc = _src || (sources[0] != null ? sources[0].srcset.split(' ')[0] : undefined);
|
|
9
|
-
const imgLoading = preloadSrc ? 'eager' : 'lazy';
|
|
10
|
-
const inlineSvg = useGetSVGtext(inline ? imageSrc : undefined);
|
|
11
|
-
if (!imageSrc) {
|
|
12
|
-
return placeholder ? (<span className={className && getBemClass(className, 'missing')}>
|
|
13
|
-
{placeholder !== true && placeholder()}
|
|
14
|
-
</span>) : null;
|
|
15
|
-
}
|
|
16
|
-
if (inline && inlineSvg) {
|
|
17
|
-
const __html = inlineSvg.imageSrc === imageSrc ? inlineSvg.code : '';
|
|
18
|
-
return <span className={className} dangerouslySetInnerHTML={{ __html }}/>;
|
|
19
|
-
}
|
|
20
|
-
return (<picture className={className}>
|
|
21
|
-
{' '}
|
|
22
|
-
{sources.map((source, i) => (<>
|
|
23
|
-
<source key={i} srcSet={source.srcset} media={source.media}/>{' '}
|
|
24
|
-
</>))}{' '}
|
|
25
|
-
<img src={imageSrc} alt={altText} loading={imgLoading}/>
|
|
26
|
-
{' '}
|
|
27
|
-
</picture>);
|
|
28
|
-
};
|
|
29
|
-
export default Image;
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import getBemClass from '@hugsmidjan/react/utils/getBemClass';
|
|
3
|
-
const TogglerGroup = (props) => {
|
|
4
|
-
const {
|
|
5
|
-
// id,
|
|
6
|
-
className, bem, name, disabled, Toggler, onSelected, options, inputProps = {}, } = props;
|
|
7
|
-
const values = props.value || [];
|
|
8
|
-
return (<ul className={getBemClass(bem, null, className)} role="group" aria-labelledby={props['aria-labelledby']} aria-describedby={props['aria-describedby']} aria-required={props.required}>
|
|
9
|
-
{options.map((option, i) => {
|
|
10
|
-
const isDisabled = option.disabled != null
|
|
11
|
-
? option.disabled
|
|
12
|
-
: disabled && typeof disabled !== 'boolean'
|
|
13
|
-
? disabled.includes(i)
|
|
14
|
-
: disabled;
|
|
15
|
-
const isChecked = values.includes(option.value);
|
|
16
|
-
return (<Toggler key={i} {...inputProps} className={bem + '__item'} name={name} Wrapper="li" {...option} label={option.label || option.value} onChange={onSelected
|
|
17
|
-
? (e) => {
|
|
18
|
-
const { value } = option;
|
|
19
|
-
const checked = e.currentTarget.checked;
|
|
20
|
-
inputProps.onChange && inputProps.onChange(e);
|
|
21
|
-
const selectedValues = values.filter((val) => val !== value);
|
|
22
|
-
if (checked) {
|
|
23
|
-
selectedValues.push(value);
|
|
24
|
-
}
|
|
25
|
-
onSelected({ value, checked, option, selectedValues });
|
|
26
|
-
}
|
|
27
|
-
: inputProps.onChange} disabled={isDisabled} aria-invalid={props['aria-invalid']} checked={isChecked}/>);
|
|
28
|
-
})}
|
|
29
|
-
</ul>);
|
|
30
|
-
};
|
|
31
|
-
export default TogglerGroup;
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import Bling from '../Bling';
|
|
3
|
-
const inverseAlignments = {
|
|
4
|
-
left: 'right',
|
|
5
|
-
'left-ish': 'right-ish',
|
|
6
|
-
'left-center': 'right-center',
|
|
7
|
-
'right-center': 'left-center',
|
|
8
|
-
'right-ish': 'left-ish',
|
|
9
|
-
right: 'left',
|
|
10
|
-
};
|
|
11
|
-
const Blings = (props) => (<>
|
|
12
|
-
{props.blings.map(({ type, align, vertical, color, overlay, parent }, i) => (<Bling key={type + '-' + i} type={type} align={props.mirror ? inverseAlignments[align || 'left'] : align} vertical={vertical} color={color} overlay={overlay} parent={parent}/>))}
|
|
13
|
-
</>);
|
|
14
|
-
export default Blings;
|
package/esm/_abstract/_Block.jsx
DELETED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import getBemClass from '@hugsmidjan/react/utils/getBemClass';
|
|
3
|
-
import { useSeenEffect } from '../utils/seenEffect';
|
|
4
|
-
import Button from './Button';
|
|
5
|
-
import Image from './Image';
|
|
6
|
-
const Block = (props) => {
|
|
7
|
-
const { image, modifier, bem, content, startSeen } = props;
|
|
8
|
-
const [ref] = useSeenEffect(startSeen);
|
|
9
|
-
const contentItems = Array.isArray(content) ? content : [content];
|
|
10
|
-
return (<div className={getBemClass(bem, modifier)} ref={ref}>
|
|
11
|
-
{contentItems.map(({ title, summary, buttons = [] }, i) => {
|
|
12
|
-
const hasSummary = summary && (typeof summary !== 'string' || !!summary.trim());
|
|
13
|
-
return (<div key={i} className={`${bem}__content`}>
|
|
14
|
-
<h2 className={`${bem}__title`}>{title}</h2>
|
|
15
|
-
{hasSummary && <div className={`${bem}__summary`}>{summary}</div>}
|
|
16
|
-
{buttons.length > 0 && (<div className={`${bem}__buttons`}>
|
|
17
|
-
{' '}
|
|
18
|
-
{buttons.map((buttonProps, i) => (<>
|
|
19
|
-
<Button bem={`${bem}__button`} key={i} {...buttonProps}/>{' '}
|
|
20
|
-
</>))}
|
|
21
|
-
</div>)}
|
|
22
|
-
</div>);
|
|
23
|
-
})}
|
|
24
|
-
{image && <Image className={`${bem}__image`} {...image}/>}
|
|
25
|
-
</div>);
|
|
26
|
-
};
|
|
27
|
-
export default Block;
|
package/esm/_abstract/_Quote.jsx
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { Link } from './Link';
|
|
3
|
-
export const _Quote = (props) => {
|
|
4
|
-
const { bem, children, by, byHref } = props;
|
|
5
|
-
return (<figure className={bem}>
|
|
6
|
-
<blockquote className={bem + '__quote'}>{children}</blockquote>
|
|
7
|
-
{by && (<figcaption className={bem + '__by'}>
|
|
8
|
-
{byHref ? (<Link href={byHref}>{by}</Link>) : typeof by === 'string' ? (<span>{by}</span>) : (by)}
|
|
9
|
-
</figcaption>)}
|
|
10
|
-
</figure>);
|
|
11
|
-
};
|