@reykjavik/hanna-react 0.10.57 → 0.10.60
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.js +3 -28
- package/ActionCards.d.ts +1 -1
- package/ActionCards.js +4 -6
- package/Alert.js +5 -30
- package/ArticleCards.d.ts +6 -0
- package/ArticleCards.js +7 -0
- package/ArticleCarousel/_ArticleCarouselCard.d.ts +1 -1
- package/ArticleCarousel/_ArticleCarouselCard.js +8 -10
- package/ArticleCarousel.js +3 -5
- package/ArticleMeta.d.ts +1 -0
- package/ArticleMeta.js +7 -28
- package/Attention.js +3 -5
- package/BasicTable.js +5 -7
- package/{esm/CenterColumn.d.ts → BgBox.d.ts} +4 -3
- package/BgBox.js +12 -0
- package/Bling.js +3 -5
- package/BlockBreak.js +2 -4
- package/BlockQuote.js +2 -4
- package/BreadCrumbs.js +4 -6
- package/ButtonBack.d.ts +1 -1
- package/ButtonBack.js +4 -6
- package/ButtonBar.js +3 -5
- package/ButtonPrimary.d.ts +1 -1
- package/ButtonPrimary.js +4 -6
- package/ButtonSecondary.d.ts +1 -1
- package/ButtonSecondary.js +4 -6
- package/ButtonTertiary.d.ts +1 -1
- package/ButtonTertiary.js +4 -6
- package/CHANGELOG.md +20 -1
- package/Carousel.js +3 -5
- package/CarouselStepper.js +3 -5
- package/CenterColumn.js +3 -5
- package/Checkbox.d.ts +1 -1
- package/Checkbox.js +4 -6
- package/CheckboxButtonsGroup.d.ts +1 -1
- package/CheckboxButtonsGroup.js +6 -8
- package/CheckboxGroup.d.ts +1 -1
- package/CheckboxGroup.js +5 -7
- package/CityBlock.d.ts +1 -1
- package/CityBlock.js +3 -5
- package/ContactBubble.js +6 -31
- package/ContentArticle.js +8 -10
- package/ContentImage.d.ts +1 -1
- package/ContentImage.js +4 -6
- package/Datepicker.js +6 -31
- package/ExtraLinks.d.ts +1 -1
- package/ExtraLinks.js +8 -21
- package/FeatureList.js +3 -5
- package/FieldGroup.js +3 -5
- package/FileInput.js +5 -41
- package/Foonote.js +2 -4
- package/FooterBadges.js +4 -6
- package/FooterInfo.js +3 -5
- package/Footnote.js +2 -4
- package/Form.js +3 -5
- package/FormField.js +3 -28
- package/Gallery/_GalleryItem.d.ts +1 -1
- package/Gallery/_GalleryItem.js +9 -45
- package/Gallery/_GalleryModal.js +6 -31
- package/Gallery/_GalleryModalContext.js +2 -4
- package/Gallery/_GalleryModalItem.js +5 -18
- package/Gallery.js +6 -31
- package/GridBlocks.d.ts +2 -2
- package/GridBlocks.js +8 -10
- package/Heading.d.ts +1 -1
- package/Heading.js +4 -6
- package/HeroBlock.d.ts +2 -2
- package/HeroBlock.js +6 -8
- package/IframeBlock.d.ts +5 -1
- package/IframeBlock.js +6 -8
- package/Illustration.d.ts +1 -1
- package/Illustration.js +4 -6
- package/ImageCards.d.ts +1 -1
- package/ImageCards.js +6 -19
- package/InfoBlock.js +2 -4
- package/InfoHero.d.ts +2 -2
- package/InfoHero.js +8 -10
- package/IslandBlock.d.ts +1 -1
- package/IslandBlock.js +3 -5
- package/IslandPageBlock.d.ts +1 -1
- package/IslandPageBlock.js +3 -5
- package/LabeledTextBlock.d.ts +1 -1
- package/LabeledTextBlock.js +4 -6
- package/Layout.js +9 -11
- package/MainMenu/_Auxiliary.js +4 -6
- package/MainMenu/_PrimaryPanel.js +5 -7
- package/MainMenu.js +7 -32
- package/MiniMetrics.d.ts +1 -1
- package/MiniMetrics.js +5 -7
- package/Modal.js +3 -5
- package/NameCard.js +6 -8
- package/NameCards.js +3 -5
- package/NewsHero.d.ts +1 -1
- package/NewsHero.js +7 -9
- package/PageFilter.js +4 -6
- package/PageHeading.js +3 -5
- package/Picture.d.ts +7 -0
- package/Picture.js +11 -0
- package/ProcessOverview.js +3 -5
- package/PullQuote.js +2 -4
- package/RadioButtonsGroup.d.ts +1 -1
- package/RadioButtonsGroup.js +6 -8
- package/RadioGroup.d.ts +2 -2
- package/RadioGroup.js +6 -8
- package/RelatedLinks.js +4 -6
- package/RowBlock.js +3 -5
- package/RowBlockColumn.js +3 -5
- package/SearchInput.js +5 -41
- package/SearchResults/_SearchResultsItem.js +6 -8
- package/SearchResults.js +7 -32
- package/SeenEffect.js +3 -16
- package/Selectbox.js +6 -42
- package/ShareButtons.js +4 -26
- package/Sharpie.js +3 -5
- package/SiteSearchAutocomplete.js +5 -41
- package/SiteSearchCurtain.js +3 -28
- package/SiteSearchInput.d.ts +1 -1
- package/SiteSearchInput.js +4 -40
- package/Skeleton.js +4 -6
- package/SubHeading.js +3 -5
- package/Tabs.js +3 -28
- package/TagPill.d.ts +1 -1
- package/TagPill.js +7 -20
- package/TextBlock.js +3 -5
- package/TextButton.d.ts +1 -1
- package/TextButton.js +4 -6
- package/TextInput.js +5 -41
- package/VSpacer.js +3 -5
- package/VerticalTabsTOC.js +3 -28
- package/WizardLayout.js +7 -9
- package/WizardLayoutClose.d.ts +1 -1
- package/WizardLayoutClose.js +4 -6
- package/WizardStepper.js +3 -5
- package/_abstract/_AbstractCarousel.js +7 -32
- package/_abstract/_Blings.js +3 -5
- package/_abstract/_Block.d.ts +2 -2
- package/_abstract/_Block.js +7 -9
- package/_abstract/{Button.d.ts → _Button.d.ts} +0 -0
- package/_abstract/{Button.js → _Button.js} +6 -19
- package/{esm/_abstract/CardList.d.ts → _abstract/_CardList.d.ts} +2 -1
- package/_abstract/{CardList.js → _CardList.js} +12 -12
- package/{esm/_abstract/Image.d.ts → _abstract/_Image.d.ts} +9 -5
- package/_abstract/{Image.js → _Image.js} +5 -7
- package/_abstract/{Link.d.ts → _Link.d.ts} +0 -0
- package/_abstract/{Link.js → _Link.js} +2 -4
- package/_abstract/_Quote.js +4 -6
- package/{esm/_abstract/TogglerGroup.d.ts → _abstract/_TogglerGroup.d.ts} +1 -1
- package/_abstract/{TogglerGroup.js → _TogglerGroup.js} +8 -8
- package/{esm/_abstract/TogglerGroupField.d.ts → _abstract/_TogglerGroupField.d.ts} +2 -2
- package/_abstract/_TogglerGroupField.js +14 -0
- package/_abstract/{TogglerInput.d.ts → _TogglerInput.d.ts} +0 -0
- package/_abstract/{TogglerInput.js → _TogglerInput.js} +4 -17
- package/_abstract/breakOnNL.js +2 -4
- package/package.json +6 -365
- package/utils/env.js +2 -4
- package/utils/seenEffect.d.ts +2 -2
- package/utils/seenEffect.js +1 -1
- package/utils/useScrollbarWidthCSSVar.js +2 -4
- package/utils.js +3 -16
- package/_abstract/CardList.d.ts +0 -29
- package/_abstract/Image.d.ts +0 -32
- package/_abstract/TogglerGroup.d.ts +0 -31
- package/_abstract/TogglerGroupField.d.ts +0 -17
- package/_abstract/TogglerGroupField.js +0 -27
- package/esm/AccordionList.d.ts +0 -17
- package/esm/AccordionList.js +0 -24
- package/esm/ActionCards.d.ts +0 -5
- package/esm/ActionCards.js +0 -9
- package/esm/Alert.d.ts +0 -49
- package/esm/Alert.js +0 -92
- package/esm/ArticleCarousel/_ArticleCarouselCard.d.ts +0 -27
- package/esm/ArticleCarousel/_ArticleCarouselCard.js +0 -24
- package/esm/ArticleCarousel.d.ts +0 -12
- package/esm/ArticleCarousel.js +0 -8
- package/esm/ArticleMeta.d.ts +0 -9
- package/esm/ArticleMeta.js +0 -18
- package/esm/Attention.d.ts +0 -7
- package/esm/Attention.js +0 -4
- package/esm/BasicTable.d.ts +0 -12
- package/esm/BasicTable.js +0 -29
- package/esm/Bling.d.ts +0 -81
- package/esm/Bling.js +0 -44
- package/esm/BlockBreak.d.ts +0 -2
- package/esm/BlockBreak.js +0 -6
- package/esm/BlockQuote.d.ts +0 -4
- package/esm/BlockQuote.js +0 -4
- package/esm/BreadCrumbs.d.ts +0 -11
- package/esm/BreadCrumbs.js +0 -28
- package/esm/ButtonBack.d.ts +0 -7
- package/esm/ButtonBack.js +0 -4
- package/esm/ButtonBar.d.ts +0 -16
- package/esm/ButtonBar.js +0 -14
- package/esm/ButtonPrimary.d.ts +0 -7
- package/esm/ButtonPrimary.js +0 -4
- package/esm/ButtonSecondary.d.ts +0 -7
- package/esm/ButtonSecondary.js +0 -4
- package/esm/ButtonTertiary.d.ts +0 -12
- package/esm/ButtonTertiary.js +0 -15
- package/esm/Carousel.d.ts +0 -4
- package/esm/Carousel.js +0 -4
- package/esm/CarouselStepper.d.ts +0 -4
- package/esm/CarouselStepper.js +0 -4
- package/esm/CenterColumn.js +0 -7
- package/esm/Checkbox.d.ts +0 -4
- package/esm/Checkbox.js +0 -4
- package/esm/CheckboxButtonsGroup.d.ts +0 -11
- package/esm/CheckboxButtonsGroup.js +0 -14
- package/esm/CheckboxGroup.d.ts +0 -9
- package/esm/CheckboxGroup.js +0 -7
- package/esm/CityBlock.d.ts +0 -23
- package/esm/CityBlock.js +0 -18
- package/esm/ContactBubble.d.ts +0 -58
- package/esm/ContactBubble.js +0 -148
- package/esm/ContentArticle.d.ts +0 -15
- package/esm/ContentArticle.js +0 -21
- package/esm/ContentImage.d.ts +0 -8
- package/esm/ContentImage.js +0 -18
- package/esm/Datepicker.d.ts +0 -39
- package/esm/Datepicker.js +0 -63
- package/esm/ExtraLinks.d.ts +0 -18
- package/esm/ExtraLinks.js +0 -34
- package/esm/FeatureList.d.ts +0 -12
- package/esm/FeatureList.js +0 -16
- package/esm/FieldGroup.d.ts +0 -9
- package/esm/FieldGroup.js +0 -9
- package/esm/FileInput.d.ts +0 -17
- package/esm/FileInput.js +0 -154
- package/esm/Foonote.d.ts +0 -12
- package/esm/Foonote.js +0 -7
- package/esm/FooterBadges.d.ts +0 -9
- package/esm/FooterBadges.js +0 -12
- package/esm/FooterInfo.d.ts +0 -18
- package/esm/FooterInfo.js +0 -9
- package/esm/Footnote.d.ts +0 -6
- package/esm/Footnote.js +0 -3
- package/esm/Form.d.ts +0 -7
- package/esm/Form.js +0 -10
- package/esm/FormField.d.ts +0 -65
- package/esm/FormField.js +0 -91
- package/esm/Gallery/_GalleryItem.d.ts +0 -8
- package/esm/Gallery/_GalleryItem.js +0 -30
- package/esm/Gallery/_GalleryModal.d.ts +0 -6
- package/esm/Gallery/_GalleryModal.js +0 -54
- package/esm/Gallery/_GalleryModalContext.d.ts +0 -9
- package/esm/Gallery/_GalleryModalContext.js +0 -3
- package/esm/Gallery/_GalleryModalItem.d.ts +0 -3
- package/esm/Gallery/_GalleryModalItem.js +0 -22
- package/esm/Gallery.d.ts +0 -17
- package/esm/Gallery.js +0 -27
- package/esm/GridBlocks.d.ts +0 -26
- package/esm/GridBlocks.js +0 -24
- package/esm/Heading.d.ts +0 -16
- package/esm/Heading.js +0 -17
- package/esm/HeroBlock.d.ts +0 -19
- package/esm/HeroBlock.js +0 -21
- package/esm/IframeBlock.d.ts +0 -23
- package/esm/IframeBlock.js +0 -26
- package/esm/Illustration.d.ts +0 -13
- package/esm/Illustration.js +0 -8
- package/esm/ImageCards.d.ts +0 -8
- package/esm/ImageCards.js +0 -22
- package/esm/InfoBlock.d.ts +0 -17
- package/esm/InfoBlock.js +0 -13
- package/esm/InfoHero.d.ts +0 -17
- package/esm/InfoHero.js +0 -82
- package/esm/IslandBlock.d.ts +0 -25
- package/esm/IslandBlock.js +0 -16
- package/esm/IslandPageBlock.d.ts +0 -24
- package/esm/IslandPageBlock.js +0 -16
- package/esm/LabeledTextBlock.d.ts +0 -11
- package/esm/LabeledTextBlock.js +0 -14
- package/esm/Layout.d.ts +0 -33
- package/esm/Layout.js +0 -52
- package/esm/MainMenu/_Auxiliary.d.ts +0 -6
- package/esm/MainMenu/_Auxiliary.js +0 -13
- package/esm/MainMenu/_PrimaryPanel.d.ts +0 -13
- package/esm/MainMenu/_PrimaryPanel.js +0 -22
- package/esm/MainMenu.d.ts +0 -48
- package/esm/MainMenu.js +0 -136
- package/esm/MiniMetrics.d.ts +0 -8
- package/esm/MiniMetrics.js +0 -12
- package/esm/Modal.d.ts +0 -10
- package/esm/Modal.js +0 -14
- package/esm/NameCard.d.ts +0 -64
- package/esm/NameCard.js +0 -82
- package/esm/NameCards.d.ts +0 -6
- package/esm/NameCards.js +0 -7
- package/esm/NewsHero.d.ts +0 -14
- package/esm/NewsHero.js +0 -86
- package/esm/PageFilter.d.ts +0 -17
- package/esm/PageFilter.js +0 -15
- package/esm/PageHeading.d.ts +0 -10
- package/esm/PageHeading.js +0 -12
- package/esm/ProcessOverview.d.ts +0 -13
- package/esm/ProcessOverview.js +0 -17
- package/esm/PullQuote.d.ts +0 -4
- package/esm/PullQuote.js +0 -4
- package/esm/RadioButtonsGroup.d.ts +0 -11
- package/esm/RadioButtonsGroup.js +0 -14
- package/esm/RadioGroup.d.ts +0 -13
- package/esm/RadioGroup.js +0 -7
- package/esm/RelatedLinks.d.ts +0 -20
- package/esm/RelatedLinks.js +0 -26
- package/esm/RowBlock.d.ts +0 -12
- package/esm/RowBlock.js +0 -9
- package/esm/RowBlockColumn.d.ts +0 -8
- package/esm/RowBlockColumn.js +0 -11
- package/esm/SearchInput.d.ts +0 -18
- package/esm/SearchInput.js +0 -33
- package/esm/SearchResults/_SearchResultsItem.d.ts +0 -18
- package/esm/SearchResults/_SearchResultsItem.js +0 -15
- package/esm/SearchResults.d.ts +0 -33
- package/esm/SearchResults.js +0 -109
- package/esm/SeenEffect.d.ts +0 -4
- package/esm/SeenEffect.js +0 -19
- package/esm/Selectbox.d.ts +0 -8
- package/esm/Selectbox.js +0 -46
- package/esm/ShareButtons.d.ts +0 -9
- package/esm/ShareButtons.js +0 -51
- package/esm/Sharpie.d.ts +0 -23
- package/esm/Sharpie.js +0 -22
- package/esm/SiteSearchAutocomplete.d.ts +0 -40
- package/esm/SiteSearchAutocomplete.js +0 -58
- package/esm/SiteSearchCurtain.d.ts +0 -6
- package/esm/SiteSearchCurtain.js +0 -33
- package/esm/SiteSearchInput.d.ts +0 -24
- package/esm/SiteSearchInput.js +0 -40
- package/esm/Skeleton.d.ts +0 -25
- package/esm/Skeleton.js +0 -30
- package/esm/SubHeading.d.ts +0 -10
- package/esm/SubHeading.js +0 -13
- package/esm/Tabs.d.ts +0 -35
- package/esm/Tabs.js +0 -94
- package/esm/TagPill.d.ts +0 -27
- package/esm/TagPill.js +0 -43
- package/esm/TextBlock.d.ts +0 -15
- package/esm/TextBlock.js +0 -15
- package/esm/TextButton.d.ts +0 -9
- package/esm/TextButton.js +0 -9
- package/esm/TextInput.d.ts +0 -16
- package/esm/TextInput.js +0 -35
- package/esm/VSpacer.d.ts +0 -24
- package/esm/VSpacer.js +0 -41
- package/esm/VerticalTabsTOC.d.ts +0 -14
- package/esm/VerticalTabsTOC.js +0 -68
- package/esm/WizardLayout.d.ts +0 -15
- package/esm/WizardLayout.js +0 -30
- package/esm/WizardLayoutClose.d.ts +0 -3
- package/esm/WizardLayoutClose.js +0 -4
- package/esm/WizardStepper.d.ts +0 -36
- package/esm/WizardStepper.js +0 -25
- package/esm/_abstract/Button.d.ts +0 -40
- package/esm/_abstract/Button.js +0 -47
- package/esm/_abstract/CardList.js +0 -36
- package/esm/_abstract/Image.js +0 -27
- package/esm/_abstract/Link.d.ts +0 -27
- package/esm/_abstract/Link.js +0 -24
- package/esm/_abstract/TogglerGroup.js +0 -29
- package/esm/_abstract/TogglerGroupField.js +0 -22
- package/esm/_abstract/TogglerInput.d.ts +0 -22
- package/esm/_abstract/TogglerInput.js +0 -33
- package/esm/_abstract/_AbstractCarousel.d.ts +0 -25
- package/esm/_abstract/_AbstractCarousel.js +0 -130
- package/esm/_abstract/_Blings.d.ts +0 -11
- package/esm/_abstract/_Blings.js +0 -12
- package/esm/_abstract/_Block.d.ts +0 -22
- package/esm/_abstract/_Block.js +0 -24
- package/esm/_abstract/_Quote.d.ts +0 -9
- package/esm/_abstract/_Quote.js +0 -8
- package/esm/_abstract/breakOnNL.d.ts +0 -2
- package/esm/_abstract/breakOnNL.js +0 -8
- package/esm/assets.d.ts +0 -42
- package/esm/assets.js +0 -56
- package/esm/constants.d.ts +0 -39
- package/esm/constants.js +0 -22
- package/esm/focus-visible.d.ts +0 -1
- package/esm/focus-visible.js +0 -1
- package/esm/package.json +0 -1
- package/esm/utils/env.d.ts +0 -1
- package/esm/utils/env.js +0 -8
- package/esm/utils/seenEffect.d.ts +0 -28
- package/esm/utils/seenEffect.js +0 -73
- package/esm/utils/useFormatMonitor.d.ts +0 -38
- package/esm/utils/useFormatMonitor.js +0 -41
- package/esm/utils/useGetSVGtext.d.ts +0 -6
- package/esm/utils/useGetSVGtext.js +0 -19
- package/esm/utils/useMenuToggling.d.ts +0 -8
- package/esm/utils/useMenuToggling.js +0 -62
- package/esm/utils/useScrollbarWidthCSSVar.d.ts +0 -1
- package/esm/utils/useScrollbarWidthCSSVar.js +0 -3
- package/esm/utils.d.ts +0 -2
- package/esm/utils.js +0 -2
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
7
5
|
const GalleryModalContext = react_1.default.createContext({});
|
|
8
6
|
exports.default = GalleryModalContext;
|
|
@@ -1,27 +1,14 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
3
|
-
var t = {};
|
|
4
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
5
|
-
t[p] = s[p];
|
|
6
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
7
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
8
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
9
|
-
t[p[i]] = s[p[i]];
|
|
10
|
-
}
|
|
11
|
-
return t;
|
|
12
|
-
};
|
|
13
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
14
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
15
|
-
};
|
|
16
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
const
|
|
18
|
-
const
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
5
|
+
const _Image_1 = tslib_1.__importDefault(require("../_abstract/_Image"));
|
|
19
6
|
const GalleryModalItem = (props) => {
|
|
20
|
-
const { caption, description } = props, image = __rest(props, ["caption", "description"]);
|
|
7
|
+
const { caption, description } = props, image = tslib_1.__rest(props, ["caption", "description"]);
|
|
21
8
|
return (react_1.default.createElement("div", { className: "GalleryModalItem" },
|
|
22
9
|
(caption || description) && (react_1.default.createElement("div", { className: "GalleryModalItem__text" },
|
|
23
10
|
react_1.default.createElement("div", { className: "GalleryModalItem__caption" }, caption),
|
|
24
11
|
react_1.default.createElement("div", { className: "GalleryModalItem__description" }, description))),
|
|
25
|
-
react_1.default.createElement(
|
|
12
|
+
react_1.default.createElement(_Image_1.default, { className: "GalleryModalItem__image", src: image.largeImageSrc || image.src })));
|
|
26
13
|
};
|
|
27
14
|
exports.default = GalleryModalItem;
|
package/Gallery.js
CHANGED
|
@@ -1,37 +1,12 @@
|
|
|
1
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
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
-
const
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const react_1 = tslib_1.__importStar(require("react"));
|
|
30
5
|
const i18n_1 = require("@reykjavik/hanna-utils/i18n");
|
|
31
|
-
const _AbstractCarousel_1 = __importDefault(require("./_abstract/_AbstractCarousel"));
|
|
32
|
-
const _GalleryItem_1 = __importDefault(require("./Gallery/_GalleryItem"));
|
|
33
|
-
const _GalleryModal_1 = __importDefault(require("./Gallery/_GalleryModal"));
|
|
34
|
-
const _GalleryModalContext_1 = __importDefault(require("./Gallery/_GalleryModalContext"));
|
|
6
|
+
const _AbstractCarousel_1 = tslib_1.__importDefault(require("./_abstract/_AbstractCarousel"));
|
|
7
|
+
const _GalleryItem_1 = tslib_1.__importDefault(require("./Gallery/_GalleryItem"));
|
|
8
|
+
const _GalleryModal_1 = tslib_1.__importDefault(require("./Gallery/_GalleryModal"));
|
|
9
|
+
const _GalleryModalContext_1 = tslib_1.__importDefault(require("./Gallery/_GalleryModalContext"));
|
|
35
10
|
const defaultTexts = {
|
|
36
11
|
en: {
|
|
37
12
|
modalNextLabel: 'Next image',
|
package/GridBlocks.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Efnistakn } from '@reykjavik/hanna-utils/assets';
|
|
2
|
-
import { ButtonProps } from './_abstract/
|
|
3
|
-
import { ImageProps } from './_abstract/
|
|
2
|
+
import { ButtonProps } from './_abstract/_Button';
|
|
3
|
+
import { ImageProps } from './_abstract/_Image';
|
|
4
4
|
import { SeenProp } from './utils/seenEffect';
|
|
5
5
|
export declare type GridBlockItem = {
|
|
6
6
|
title: string;
|
package/GridBlocks.js
CHANGED
|
@@ -1,24 +1,22 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const
|
|
7
|
-
const
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
5
|
+
const getBemClass_1 = tslib_1.__importDefault(require("@hugsmidjan/react/utils/getBemClass"));
|
|
8
6
|
const assets_1 = require("@reykjavik/hanna-utils/assets");
|
|
9
|
-
const
|
|
10
|
-
const
|
|
7
|
+
const _Image_1 = tslib_1.__importDefault(require("./_abstract/_Image"));
|
|
8
|
+
const _Link_1 = require("./_abstract/_Link");
|
|
11
9
|
const seenEffect_1 = require("./utils/seenEffect");
|
|
12
|
-
const ButtonTertiary_1 = __importDefault(require("./ButtonTertiary"));
|
|
10
|
+
const ButtonTertiary_1 = tslib_1.__importDefault(require("./ButtonTertiary"));
|
|
13
11
|
const GridBlocks = (props) => {
|
|
14
12
|
const { blocks, twocol, startSeen } = props;
|
|
15
13
|
const [ref] = (0, seenEffect_1.useSeenEffect)(startSeen);
|
|
16
14
|
return (react_1.default.createElement("div", { className: (0, getBemClass_1.default)('GridBlocks', [twocol && 'twocol']), ref: ref }, blocks.map(({ title, summary, href, links = [], icon, image }, i) => {
|
|
17
15
|
const imageProps = icon ? { src: (0, assets_1.getEfnistaknUrl)(icon) } : image;
|
|
18
16
|
return (react_1.default.createElement("div", { key: i, className: "GridBlocks__item" },
|
|
19
|
-
imageProps && react_1.default.createElement(
|
|
17
|
+
imageProps && react_1.default.createElement(_Image_1.default, Object.assign({ className: "GridBlocks__illustration" }, imageProps)),
|
|
20
18
|
react_1.default.createElement("div", { className: "GridBlocks__textwrap" },
|
|
21
|
-
react_1.default.createElement("h3", { className: "GridBlocks__item__title" }, href != null ? (react_1.default.createElement(
|
|
19
|
+
react_1.default.createElement("h3", { className: "GridBlocks__item__title" }, href != null ? (react_1.default.createElement(_Link_1.Link, { className: "GridBlocks__item__titlelink", href: href }, title)) : (title)),
|
|
22
20
|
react_1.default.createElement("div", { className: "GridBlocks__item__summary" }, summary),
|
|
23
21
|
react_1.default.createElement("ul", { className: "GridBlocks__links" }, links.map((link, i) => {
|
|
24
22
|
return (react_1.default.createElement("li", { key: i, className: "GridBlocks__link" },
|
package/Heading.d.ts
CHANGED
package/Heading.js
CHANGED
|
@@ -1,14 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const
|
|
7
|
-
const
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
5
|
+
const getBemClass_1 = tslib_1.__importDefault(require("@hugsmidjan/react/utils/getBemClass"));
|
|
8
6
|
const sizes = {
|
|
9
7
|
small: 'small',
|
|
10
8
|
/** Default value */
|
|
11
|
-
normal: '
|
|
9
|
+
normal: '',
|
|
12
10
|
large: 'large',
|
|
13
11
|
};
|
|
14
12
|
const Heading = (props) => {
|
package/HeroBlock.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Illustration } from '@reykjavik/hanna-utils/assets';
|
|
2
|
-
import { ButtonProps } from './_abstract/
|
|
3
|
-
import { ImageProps } from './_abstract/
|
|
2
|
+
import { ButtonProps } from './_abstract/_Button';
|
|
3
|
+
import { ImageProps } from './_abstract/_Image';
|
|
4
4
|
import { SeenProp } from './utils/seenEffect';
|
|
5
5
|
declare type HeroBlockImageProps = {
|
|
6
6
|
illustration: Illustration;
|
package/HeroBlock.js
CHANGED
|
@@ -1,14 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
7
5
|
const assets_1 = require("@reykjavik/hanna-utils/assets");
|
|
8
|
-
const
|
|
6
|
+
const _Image_1 = tslib_1.__importDefault(require("./_abstract/_Image"));
|
|
9
7
|
const seenEffect_1 = require("./utils/seenEffect");
|
|
10
|
-
const ButtonPrimary_1 = __importDefault(require("./ButtonPrimary"));
|
|
11
|
-
const ButtonTertiary_1 = __importDefault(require("./ButtonTertiary"));
|
|
8
|
+
const ButtonPrimary_1 = tslib_1.__importDefault(require("./ButtonPrimary"));
|
|
9
|
+
const ButtonTertiary_1 = tslib_1.__importDefault(require("./ButtonTertiary"));
|
|
12
10
|
const HeroBlock = (props) => {
|
|
13
11
|
const { title, summary, illustration, image, primaryButton, secondaryButton, startSeen, } = props;
|
|
14
12
|
const hasButtons = Boolean(primaryButton || secondaryButton);
|
|
@@ -16,7 +14,7 @@ const HeroBlock = (props) => {
|
|
|
16
14
|
const [ref] = (0, seenEffect_1.useSeenEffect)(startSeen);
|
|
17
15
|
return (react_1.default.createElement("div", { className: "HeroBlock", ref: ref },
|
|
18
16
|
react_1.default.createElement("h1", { className: "HeroBlock__title" }, title),
|
|
19
|
-
react_1.default.createElement(
|
|
17
|
+
react_1.default.createElement(_Image_1.default, Object.assign({ className: "HeroBlock__image" }, imgProps)),
|
|
20
18
|
react_1.default.createElement("div", { className: "HeroBlock__summary" }, summary),
|
|
21
19
|
hasButtons && (react_1.default.createElement("div", { className: "HeroBlock__buttons" },
|
|
22
20
|
primaryButton && react_1.default.createElement(ButtonPrimary_1.default, Object.assign({}, primaryButton)),
|
package/IframeBlock.d.ts
CHANGED
|
@@ -1,15 +1,19 @@
|
|
|
1
|
+
import { ResizerOptions } from 'iframe-resizer-react';
|
|
1
2
|
export declare type IframeBlockProps = {
|
|
2
3
|
src: string;
|
|
3
4
|
framed?: boolean;
|
|
4
5
|
compact?: boolean;
|
|
5
6
|
align?: 'right';
|
|
6
7
|
} & ({
|
|
7
|
-
/** Default: 'auto' ... which initializes "iframe-resizer" script */
|
|
8
|
+
/** Default: `'auto'` ... which initializes "iframe-resizer" script */
|
|
8
9
|
height?: 'auto';
|
|
9
10
|
scrolling?: never;
|
|
11
|
+
/** Default: `false` ... Set to `true` for same-site only, or provide array of allowed domain-names */
|
|
12
|
+
checkOrigin?: ResizerOptions['checkOrigin'];
|
|
10
13
|
} | {
|
|
11
14
|
height: number;
|
|
12
15
|
scrolling?: boolean | 'no' | 'yes';
|
|
16
|
+
checkOrigin?: never;
|
|
13
17
|
});
|
|
14
18
|
/**
|
|
15
19
|
* When `height` is undefined or "auto", then Add the following code-snipped to the iframed page:
|
package/IframeBlock.js
CHANGED
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const
|
|
7
|
-
const
|
|
8
|
-
const
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
5
|
+
const getBemClass_1 = tslib_1.__importDefault(require("@hugsmidjan/react/utils/getBemClass"));
|
|
6
|
+
const iframe_resizer_react_1 = tslib_1.__importDefault(require("iframe-resizer-react"));
|
|
9
7
|
/**
|
|
10
8
|
* When `height` is undefined or "auto", then Add the following code-snipped to the iframed page:
|
|
11
9
|
*
|
|
@@ -15,13 +13,13 @@ const iframe_resizer_react_1 = __importDefault(require("iframe-resizer-react"));
|
|
|
15
13
|
* ```
|
|
16
14
|
*/
|
|
17
15
|
const IframeBlock = (props) => {
|
|
18
|
-
const { src, framed, compact, scrolling, height = 'auto', align } = props;
|
|
16
|
+
const { src, framed, compact, scrolling, height = 'auto', align, checkOrigin = false, } = props;
|
|
19
17
|
const className = (0, getBemClass_1.default)('IframeBlock', [
|
|
20
18
|
framed && 'framed',
|
|
21
19
|
compact && 'compact',
|
|
22
20
|
align === 'right' && 'align--' + align,
|
|
23
21
|
]);
|
|
24
|
-
return height === 'auto' ? (react_1.default.createElement(iframe_resizer_react_1.default, { className: className, src: src })) : (react_1.default.createElement("iframe", { className: className, src: src,
|
|
22
|
+
return height === 'auto' ? (react_1.default.createElement(iframe_resizer_react_1.default, { className: className, src: src, checkOrigin: checkOrigin })) : (react_1.default.createElement("iframe", { className: className, src: src,
|
|
25
23
|
// hidden tiger: pass negative height to disable iframe-resizer but not set height explicitly
|
|
26
24
|
// (Silly hack, don't rely on this)
|
|
27
25
|
height: height < 0 ? undefined : height,
|
package/Illustration.d.ts
CHANGED
package/Illustration.js
CHANGED
|
@@ -1,13 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
7
5
|
const assets_1 = require("@reykjavik/hanna-utils/assets");
|
|
8
|
-
const
|
|
6
|
+
const _Image_1 = tslib_1.__importDefault(require("./_abstract/_Image"));
|
|
9
7
|
const Illustration = (props) => {
|
|
10
8
|
const imgProps = props.type ? { src: (0, assets_1.getIllustrationUrl)(props.type) } : props.image;
|
|
11
|
-
return react_1.default.createElement(
|
|
9
|
+
return react_1.default.createElement(_Image_1.default, Object.assign({ className: "Illustration" }, imgProps));
|
|
12
10
|
};
|
|
13
11
|
exports.default = Illustration;
|
package/ImageCards.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ImageCardListProps, ImageCardProps as ICP } from './_abstract/
|
|
1
|
+
import { ImageCardListProps, ImageCardProps as ICP } from './_abstract/_CardList';
|
|
2
2
|
import { SeenProp } from './utils/seenEffect';
|
|
3
3
|
export declare type ImageCardProps = ICP;
|
|
4
4
|
declare type _ImageCardProps = ImageCardListProps & {
|
package/ImageCards.js
CHANGED
|
@@ -1,27 +1,14 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
3
|
-
var t = {};
|
|
4
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
5
|
-
t[p] = s[p];
|
|
6
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
7
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
8
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
9
|
-
t[p[i]] = s[p[i]];
|
|
10
|
-
}
|
|
11
|
-
return t;
|
|
12
|
-
};
|
|
13
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
14
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
15
|
-
};
|
|
16
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
const
|
|
18
|
-
const
|
|
19
|
-
const
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
5
|
+
const getBemClass_1 = tslib_1.__importDefault(require("@hugsmidjan/react/utils/getBemClass"));
|
|
6
|
+
const _CardList_1 = require("./_abstract/_CardList");
|
|
20
7
|
const seenEffect_1 = require("./utils/seenEffect");
|
|
21
8
|
const ImageCards = (props) => {
|
|
22
|
-
const { background, startSeen } = props, cardListProps = __rest(props, ["background", "startSeen"]);
|
|
9
|
+
const { background, startSeen } = props, cardListProps = tslib_1.__rest(props, ["background", "startSeen"]);
|
|
23
10
|
const [ref] = (0, seenEffect_1.useSeenEffect)(startSeen);
|
|
24
11
|
return (react_1.default.createElement("div", { className: (0, getBemClass_1.default)('ImageCards', background && 'background'), ref: ref },
|
|
25
|
-
react_1.default.createElement(
|
|
12
|
+
react_1.default.createElement(_CardList_1.CardList, Object.assign({}, cardListProps, { bemPrefix: "ImageCards", imgPlaceholder: props.imgPlaceholder || true }))));
|
|
26
13
|
};
|
|
27
14
|
exports.default = ImageCards;
|
package/InfoBlock.js
CHANGED
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
7
5
|
const seenEffect_1 = require("./utils/seenEffect");
|
|
8
6
|
const InfoBlock = (props) => {
|
|
9
7
|
const { title, subtitle, items, startSeen } = props;
|
package/InfoHero.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ButtonProps } from './_abstract/
|
|
2
|
-
import { ImageProps } from './_abstract/
|
|
1
|
+
import { ButtonProps } from './_abstract/_Button';
|
|
2
|
+
import { ImageProps } from './_abstract/_Image';
|
|
3
3
|
import { Alignment } from './constants';
|
|
4
4
|
declare type BlingOptions = 'waves' | 'sunny-waves' | 'triangles' | 'circles';
|
|
5
5
|
export declare type InfoHeroProps = {
|
package/InfoHero.js
CHANGED
|
@@ -1,14 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const
|
|
7
|
-
const
|
|
8
|
-
const
|
|
9
|
-
const
|
|
10
|
-
const
|
|
11
|
-
const
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
5
|
+
const getBemClass_1 = tslib_1.__importDefault(require("@hugsmidjan/react/utils/getBemClass"));
|
|
6
|
+
const _Blings_1 = tslib_1.__importDefault(require("./_abstract/_Blings"));
|
|
7
|
+
const _Image_1 = tslib_1.__importDefault(require("./_abstract/_Image"));
|
|
8
|
+
const breakOnNL_1 = tslib_1.__importDefault(require("./_abstract/breakOnNL"));
|
|
9
|
+
const ButtonTertiary_1 = tslib_1.__importDefault(require("./ButtonTertiary"));
|
|
12
10
|
const constants_1 = require("./constants");
|
|
13
11
|
const blingOptions = {
|
|
14
12
|
waves: [
|
|
@@ -81,7 +79,7 @@ const InfoHero = (props) => {
|
|
|
81
79
|
subTitle && react_1.default.createElement("div", { className: "InfoHero__subtitle" }, (0, breakOnNL_1.default)(subTitle)),
|
|
82
80
|
blurb && react_1.default.createElement("div", { className: "InfoHero__blurb" }, blurb),
|
|
83
81
|
showButtons && (react_1.default.createElement("div", { className: "InfoHero__buttons" }, buttons.map((buttonProps, i) => (react_1.default.createElement(ButtonTertiary_1.default, Object.assign({ key: i }, buttonProps))))))),
|
|
84
|
-
react_1.default.createElement(
|
|
82
|
+
react_1.default.createElement(_Image_1.default, Object.assign({ className: "InfoHero__image", altText: title }, image, { placeholder: true })),
|
|
85
83
|
react_1.default.createElement(_Blings_1.default, { blings: blings, mirror: alignment === 'right' })));
|
|
86
84
|
};
|
|
87
85
|
exports.default = InfoHero;
|
package/IslandBlock.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Formheimur } from '@reykjavik/hanna-utils/assets';
|
|
2
2
|
import { BlockItem } from './_abstract/_Block';
|
|
3
|
-
import { ImageProps } from './_abstract/
|
|
3
|
+
import { ImageProps } from './_abstract/_Image';
|
|
4
4
|
import { SeenProp } from './utils/seenEffect';
|
|
5
5
|
import { Alignment } from './constants';
|
|
6
6
|
declare type IslandBaseBlockProps = {
|
package/IslandBlock.js
CHANGED
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
7
5
|
const assets_1 = require("@reykjavik/hanna-utils/assets");
|
|
8
|
-
const _Block_1 = __importDefault(require("./_abstract/_Block"));
|
|
6
|
+
const _Block_1 = tslib_1.__importDefault(require("./_abstract/_Block"));
|
|
9
7
|
const constants_1 = require("./constants");
|
|
10
8
|
const IslandBlock = (props) => {
|
|
11
9
|
const { align, content, shapes, image, startSeen } = props;
|
package/IslandPageBlock.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Illustration } from '@reykjavik/hanna-utils/assets';
|
|
2
2
|
import { BlockItem } from './_abstract/_Block';
|
|
3
|
-
import { ImageProps } from './_abstract/
|
|
3
|
+
import { ImageProps } from './_abstract/_Image';
|
|
4
4
|
import { SeenProp } from './utils/seenEffect';
|
|
5
5
|
import { Alignment } from './constants';
|
|
6
6
|
declare const backgrounds: {
|
package/IslandPageBlock.js
CHANGED
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
7
5
|
const assets_1 = require("@reykjavik/hanna-utils/assets");
|
|
8
|
-
const _Block_1 = __importDefault(require("./_abstract/_Block"));
|
|
6
|
+
const _Block_1 = tslib_1.__importDefault(require("./_abstract/_Block"));
|
|
9
7
|
const constants_1 = require("./constants");
|
|
10
8
|
const backgrounds = {
|
|
11
9
|
none: undefined,
|
package/LabeledTextBlock.d.ts
CHANGED
package/LabeledTextBlock.js
CHANGED
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const
|
|
7
|
-
const
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
5
|
+
const getBemClass_1 = tslib_1.__importDefault(require("@hugsmidjan/react/utils/getBemClass"));
|
|
8
6
|
const seenEffect_1 = require("./utils/seenEffect");
|
|
9
|
-
const ButtonTertiary_1 = __importDefault(require("./ButtonTertiary"));
|
|
7
|
+
const ButtonTertiary_1 = tslib_1.__importDefault(require("./ButtonTertiary"));
|
|
10
8
|
const LabeledTextBlock = (props) => {
|
|
11
9
|
const { label, summary, wide, buttons = [], startSeen } = props;
|
|
12
10
|
const [ref] = (0, seenEffect_1.useSeenEffect)(startSeen);
|
package/Layout.js
CHANGED
|
@@ -1,16 +1,14 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
3
|
exports.defaultLayoutTexts = void 0;
|
|
7
|
-
const
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
8
6
|
const hooks_1 = require("@hugsmidjan/react/hooks");
|
|
9
|
-
const getBemClass_1 = __importDefault(require("@hugsmidjan/react/utils/getBemClass"));
|
|
7
|
+
const getBemClass_1 = tslib_1.__importDefault(require("@hugsmidjan/react/utils/getBemClass"));
|
|
10
8
|
const assets_1 = require("@reykjavik/hanna-utils/assets");
|
|
11
9
|
const i18n_1 = require("@reykjavik/hanna-utils/i18n");
|
|
12
|
-
const
|
|
13
|
-
const
|
|
10
|
+
const _Image_1 = tslib_1.__importDefault(require("./_abstract/_Image"));
|
|
11
|
+
const _Link_1 = require("./_abstract/_Link");
|
|
14
12
|
const useMenuToggling_1 = require("./utils/useMenuToggling");
|
|
15
13
|
const useScrollbarWidthCSSVar_1 = require("./utils/useScrollbarWidthCSSVar");
|
|
16
14
|
exports.defaultLayoutTexts = {
|
|
@@ -37,14 +35,14 @@ const Layout = (props) => {
|
|
|
37
35
|
globalAlerts && (react_1.default.createElement("div", { className: "Layout__alerts", role: "alert" }, globalAlerts)),
|
|
38
36
|
react_1.default.createElement("div", { className: "Layout__content" },
|
|
39
37
|
react_1.default.createElement("div", { className: "Layout__header", role: "banner" },
|
|
40
|
-
react_1.default.createElement(
|
|
38
|
+
react_1.default.createElement(_Link_1.Link, { className: "Layout__header__logo", href: logoLink },
|
|
39
|
+
' ',
|
|
40
|
+
react_1.default.createElement(_Image_1.default, { className: undefined, inline: true, src: (0, assets_1.getAssetUrl)('reykjavik-logo.svg') }),
|
|
41
41
|
' ',
|
|
42
|
-
react_1.default.createElement(Image_1.default, { inline: true, src: (0, assets_1.getAssetUrl)('reykjavik-logo.svg') }),
|
|
43
|
-
" ",
|
|
44
42
|
siteName,
|
|
45
43
|
' '),
|
|
46
44
|
' ',
|
|
47
|
-
navChildren && (react_1.default.createElement(
|
|
45
|
+
navChildren && (react_1.default.createElement(_Link_1.Link, { className: "Layout__header__skiplink", href: "#pagenav", onClick: isMenuActive &&
|
|
48
46
|
((e) => {
|
|
49
47
|
e.preventDefault();
|
|
50
48
|
toggleMenu();
|
package/MainMenu/_Auxiliary.js
CHANGED
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
3
|
exports.AuxiliaryPanel = void 0;
|
|
7
|
-
const
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
8
6
|
const assets_1 = require("@reykjavik/hanna-utils/assets");
|
|
9
|
-
const
|
|
7
|
+
const _Link_1 = require("../_abstract/_Link");
|
|
10
8
|
const AuxiliaryPanel = (props) => {
|
|
11
9
|
const { title, id, items, image } = props;
|
|
12
10
|
const imageUrl = image ? (0, assets_1.getIllustrationUrl)(image) : image;
|
|
@@ -15,6 +13,6 @@ const AuxiliaryPanel = (props) => {
|
|
|
15
13
|
: undefined },
|
|
16
14
|
react_1.default.createElement("h3", { className: "AuxiliaryPanel__title" }, title),
|
|
17
15
|
react_1.default.createElement("ul", { className: "AuxiliaryPanel__items" }, items.map((item, i) => (react_1.default.createElement("li", { key: i, className: "AuxiliaryPanel__item", "aria-current": item.current || undefined },
|
|
18
|
-
react_1.default.createElement(
|
|
16
|
+
react_1.default.createElement(_Link_1.Link, { className: "AuxiliaryPanel__link", href: item.href, target: item.target, lang: item.lang }, item.label)))))));
|
|
19
17
|
};
|
|
20
18
|
exports.AuxiliaryPanel = AuxiliaryPanel;
|
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
3
|
exports.PrimaryPanel = void 0;
|
|
7
|
-
const
|
|
8
|
-
const
|
|
9
|
-
const
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
6
|
+
const getBemClass_1 = tslib_1.__importDefault(require("@hugsmidjan/react/utils/getBemClass"));
|
|
7
|
+
const _Link_1 = require("../_abstract/_Link");
|
|
10
8
|
const PrimaryPanel = (props) => {
|
|
11
9
|
const { setActivePanel, panel, isParent, isActive, isBrowser, texts } = props;
|
|
12
10
|
const { items } = panel;
|
|
@@ -19,7 +17,7 @@ const PrimaryPanel = (props) => {
|
|
|
19
17
|
' ',
|
|
20
18
|
isBrowser && !isActive ? (react_1.default.createElement("button", { className: "MainMenu__mega__title-toggler", "aria-controls": panel.id, onClick: () => setActivePanel(panel, false), "aria-pressed": isActive, type: "button" }, panel.title)) : (panel.title)),
|
|
21
19
|
react_1.default.createElement("ul", { className: "PrimaryPanel__items" }, items.map((item, i) => (react_1.default.createElement("li", { key: i, className: "PrimaryPanel__item", "aria-current": item.current || undefined },
|
|
22
|
-
react_1.default.createElement(
|
|
20
|
+
react_1.default.createElement(_Link_1.Link, { className: "PrimaryPanel__link", href: item.href, target: item.target, lang: item.lang },
|
|
23
21
|
react_1.default.createElement("span", { className: "PrimaryPanel__linkTitle" }, item.label),
|
|
24
22
|
' ',
|
|
25
23
|
react_1.default.createElement("small", { className: "PrimaryPanel__summary" }, item.summary),
|
package/MainMenu.js
CHANGED
|
@@ -1,40 +1,15 @@
|
|
|
1
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
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
3
|
exports.defaultMainMenuTexts = void 0;
|
|
30
|
-
const
|
|
31
|
-
const
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const react_1 = tslib_1.__importStar(require("react"));
|
|
6
|
+
const focusElm_1 = tslib_1.__importDefault(require("@hugsmidjan/qj/focusElm"));
|
|
32
7
|
const hooks_1 = require("@hugsmidjan/react/hooks");
|
|
33
|
-
const useShortState_1 = __importDefault(require("@hugsmidjan/react/hooks/useShortState"));
|
|
34
|
-
const getBemClass_1 = __importDefault(require("@hugsmidjan/react/utils/getBemClass"));
|
|
8
|
+
const useShortState_1 = tslib_1.__importDefault(require("@hugsmidjan/react/hooks/useShortState"));
|
|
9
|
+
const getBemClass_1 = tslib_1.__importDefault(require("@hugsmidjan/react/utils/getBemClass"));
|
|
35
10
|
const hanna_utils_1 = require("@reykjavik/hanna-utils");
|
|
36
11
|
const i18n_1 = require("@reykjavik/hanna-utils/i18n");
|
|
37
|
-
const
|
|
12
|
+
const _Link_1 = require("./_abstract/_Link");
|
|
38
13
|
const _Auxiliary_1 = require("./MainMenu/_Auxiliary");
|
|
39
14
|
const _PrimaryPanel_1 = require("./MainMenu/_PrimaryPanel");
|
|
40
15
|
const useFormatMonitor_1 = require("./utils/useFormatMonitor");
|
|
@@ -146,7 +121,7 @@ const MainMenu = (props) => {
|
|
|
146
121
|
onItemClick && onItemClick(i, item);
|
|
147
122
|
}, ref: pressed && pressedLinkRef, "aria-pressed": pressed, "aria-controls": controlsId, "aria-label": labelLong, title: labelLong, lang: lang, type: "button" }, label)) : item.href != null ? (
|
|
148
123
|
// always render links server-side
|
|
149
|
-
react_1.default.createElement(
|
|
124
|
+
react_1.default.createElement(_Link_1.Link, { className: "MainMenu__link", href: item.href, "aria-label": labelLong, title: labelLong, onClick: onItemClick && (() => onItemClick(i, item)), lang: lang }, label)) : undefined // skip rendering non-link menu items server side
|
|
150
125
|
));
|
|
151
126
|
})),
|
|
152
127
|
'\n\n',
|