@reykjavik/hanna-react 0.10.53
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 +795 -0
- package/README.md +69 -0
- package/lib/AccordionList.cjs +91 -0
- package/lib/AccordionList.mjs +69 -0
- package/lib/ActionCards.cjs +57 -0
- package/lib/ActionCards.mjs +35 -0
- package/lib/Alert.cjs +159 -0
- package/lib/Alert.mjs +139 -0
- package/lib/ArticleCarousel/_ArticleCarouselCard.cjs +75 -0
- package/lib/ArticleCarousel/_ArticleCarouselCard.mjs +51 -0
- package/lib/ArticleCarousel.cjs +43 -0
- package/lib/ArticleCarousel.mjs +21 -0
- package/lib/ArticleMeta.cjs +46 -0
- package/lib/ArticleMeta.mjs +22 -0
- package/lib/Attention.cjs +33 -0
- package/lib/Attention.mjs +9 -0
- package/lib/BasicTable.cjs +72 -0
- package/lib/BasicTable.mjs +50 -0
- package/lib/Bling.cjs +76 -0
- package/lib/Bling.mjs +52 -0
- package/lib/BlockBreak.cjs +32 -0
- package/lib/BlockBreak.mjs +8 -0
- package/lib/BlockQuote.cjs +47 -0
- package/lib/BlockQuote.mjs +25 -0
- package/lib/BreadCrumbs.cjs +67 -0
- package/lib/BreadCrumbs.mjs +43 -0
- package/lib/ButtonBack.cjs +47 -0
- package/lib/ButtonBack.mjs +25 -0
- package/lib/ButtonBar.cjs +45 -0
- package/lib/ButtonBar.mjs +18 -0
- package/lib/ButtonPrimary.cjs +47 -0
- package/lib/ButtonPrimary.mjs +25 -0
- package/lib/ButtonSecondary.cjs +47 -0
- package/lib/ButtonSecondary.mjs +25 -0
- package/lib/ButtonTertiary.cjs +64 -0
- package/lib/ButtonTertiary.mjs +42 -0
- package/lib/Carousel.cjs +52 -0
- package/lib/Carousel.mjs +30 -0
- package/lib/CarouselStepper.cjs +51 -0
- package/lib/CarouselStepper.mjs +29 -0
- package/lib/CenterColumn.cjs +40 -0
- package/lib/CenterColumn.mjs +16 -0
- package/lib/Checkbox.cjs +52 -0
- package/lib/Checkbox.mjs +30 -0
- package/lib/CheckboxButtonsGroup.cjs +65 -0
- package/lib/CheckboxButtonsGroup.mjs +43 -0
- package/lib/CheckboxGroup.cjs +55 -0
- package/lib/CheckboxGroup.mjs +33 -0
- package/lib/CityBlock.cjs +49 -0
- package/lib/CityBlock.mjs +25 -0
- package/lib/ContactBubble.cjs +200 -0
- package/lib/ContactBubble.mjs +173 -0
- package/lib/ContentArticle.cjs +63 -0
- package/lib/ContentArticle.mjs +41 -0
- package/lib/ContentImage.cjs +58 -0
- package/lib/ContentImage.mjs +36 -0
- package/lib/Datepicker.cjs +164 -0
- package/lib/Datepicker.mjs +142 -0
- package/lib/ExtraLinks.cjs +96 -0
- package/lib/ExtraLinks.mjs +74 -0
- package/lib/FeatureList.cjs +53 -0
- package/lib/FeatureList.mjs +29 -0
- package/lib/FieldGroup.cjs +40 -0
- package/lib/FieldGroup.mjs +16 -0
- package/lib/FileInput.cjs +256 -0
- package/lib/FileInput.mjs +234 -0
- package/lib/Foonote.cjs +30 -0
- package/lib/Foonote.mjs +6 -0
- package/lib/FooterBadges.cjs +49 -0
- package/lib/FooterBadges.mjs +25 -0
- package/lib/FooterInfo.cjs +47 -0
- package/lib/FooterInfo.mjs +23 -0
- package/lib/Footnote.cjs +32 -0
- package/lib/Footnote.mjs +8 -0
- package/lib/Form.cjs +56 -0
- package/lib/Form.mjs +34 -0
- package/lib/FormField.cjs +153 -0
- package/lib/FormField.mjs +131 -0
- package/lib/Gallery/_GalleryItem.cjs +83 -0
- package/lib/Gallery/_GalleryItem.mjs +61 -0
- package/lib/Gallery/_GalleryModal.cjs +104 -0
- package/lib/Gallery/_GalleryModal.mjs +82 -0
- package/lib/Gallery/_GalleryModalContext.cjs +30 -0
- package/lib/Gallery/_GalleryModalContext.mjs +6 -0
- package/lib/Gallery/_GalleryModalItem.cjs +59 -0
- package/lib/Gallery/_GalleryModalItem.mjs +36 -0
- package/lib/Gallery.cjs +79 -0
- package/lib/Gallery.mjs +57 -0
- package/lib/GridBlocks.cjs +81 -0
- package/lib/GridBlocks.mjs +59 -0
- package/lib/Heading.cjs +45 -0
- package/lib/Heading.mjs +21 -0
- package/lib/HeroBlock.cjs +74 -0
- package/lib/HeroBlock.mjs +52 -0
- package/lib/IframeBlock.cjs +48 -0
- package/lib/IframeBlock.mjs +24 -0
- package/lib/Illustration.cjs +51 -0
- package/lib/Illustration.mjs +31 -0
- package/lib/ImageCards.cjs +72 -0
- package/lib/ImageCards.mjs +52 -0
- package/lib/InfoBlock.cjs +51 -0
- package/lib/InfoBlock.mjs +27 -0
- package/lib/InfoHero.cjs +150 -0
- package/lib/InfoHero.mjs +128 -0
- package/lib/IslandBlock.cjs +63 -0
- package/lib/IslandBlock.mjs +41 -0
- package/lib/IslandPageBlock.cjs +49 -0
- package/lib/IslandPageBlock.mjs +25 -0
- package/lib/LabeledTextBlock.cjs +60 -0
- package/lib/LabeledTextBlock.mjs +38 -0
- package/lib/Layout.cjs +113 -0
- package/lib/Layout.mjs +87 -0
- package/lib/MainMenu/_Auxiliary.cjs +54 -0
- package/lib/MainMenu/_Auxiliary.mjs +28 -0
- package/lib/MainMenu/_PrimaryPanel.cjs +74 -0
- package/lib/MainMenu/_PrimaryPanel.mjs +48 -0
- package/lib/MainMenu.cjs +209 -0
- package/lib/MainMenu.mjs +187 -0
- package/lib/MiniMetrics.cjs +56 -0
- package/lib/MiniMetrics.mjs +34 -0
- package/lib/Modal.cjs +70 -0
- package/lib/Modal.mjs +48 -0
- package/lib/NameCard.cjs +115 -0
- package/lib/NameCard.mjs +91 -0
- package/lib/NameCards.cjs +52 -0
- package/lib/NameCards.mjs +30 -0
- package/lib/NewsHero.cjs +136 -0
- package/lib/NewsHero.mjs +114 -0
- package/lib/PageFilter.cjs +48 -0
- package/lib/PageFilter.mjs +24 -0
- package/lib/PageHeading.cjs +42 -0
- package/lib/PageHeading.mjs +18 -0
- package/lib/ProcessOverview.cjs +52 -0
- package/lib/ProcessOverview.mjs +28 -0
- package/lib/PullQuote.cjs +47 -0
- package/lib/PullQuote.mjs +25 -0
- package/lib/RadioButtonsGroup.cjs +64 -0
- package/lib/RadioButtonsGroup.mjs +42 -0
- package/lib/RadioGroup.cjs +58 -0
- package/lib/RadioGroup.mjs +36 -0
- package/lib/RelatedLinks.cjs +61 -0
- package/lib/RelatedLinks.mjs +37 -0
- package/lib/RowBlock.cjs +39 -0
- package/lib/RowBlock.mjs +15 -0
- package/lib/RowBlockColumn.cjs +40 -0
- package/lib/RowBlockColumn.mjs +16 -0
- package/lib/SearchInput.cjs +136 -0
- package/lib/SearchInput.mjs +114 -0
- package/lib/SearchResults/_SearchResultsItem.cjs +54 -0
- package/lib/SearchResults/_SearchResultsItem.mjs +30 -0
- package/lib/SearchResults.cjs +172 -0
- package/lib/SearchResults.mjs +150 -0
- package/lib/SeenEffect.cjs +66 -0
- package/lib/SeenEffect.mjs +44 -0
- package/lib/Selectbox.cjs +144 -0
- package/lib/Selectbox.mjs +122 -0
- package/lib/ShareButtons.cjs +101 -0
- package/lib/ShareButtons.mjs +83 -0
- package/lib/Sharpie.cjs +51 -0
- package/lib/Sharpie.mjs +27 -0
- package/lib/SiteSearchAutocomplete.cjs +150 -0
- package/lib/SiteSearchAutocomplete.mjs +126 -0
- package/lib/SiteSearchCurtain.cjs +78 -0
- package/lib/SiteSearchCurtain.mjs +56 -0
- package/lib/SiteSearchInput.cjs +119 -0
- package/lib/SiteSearchInput.mjs +97 -0
- package/lib/Skeleton.cjs +63 -0
- package/lib/Skeleton.mjs +39 -0
- package/lib/SubHeading.cjs +43 -0
- package/lib/SubHeading.mjs +19 -0
- package/lib/Tabs.cjs +166 -0
- package/lib/Tabs.mjs +144 -0
- package/lib/TagPill.cjs +113 -0
- package/lib/TagPill.mjs +91 -0
- package/lib/TextBlock.cjs +45 -0
- package/lib/TextBlock.mjs +21 -0
- package/lib/TextButton.cjs +55 -0
- package/lib/TextButton.mjs +33 -0
- package/lib/TextInput.cjs +136 -0
- package/lib/TextInput.mjs +114 -0
- package/lib/VSpacer.cjs +70 -0
- package/lib/VSpacer.mjs +46 -0
- package/lib/VerticalTabsTOC.cjs +123 -0
- package/lib/VerticalTabsTOC.mjs +101 -0
- package/lib/WizardLayout.cjs +79 -0
- package/lib/WizardLayout.mjs +55 -0
- package/lib/WizardLayoutClose.cjs +47 -0
- package/lib/WizardLayoutClose.mjs +25 -0
- package/lib/WizardStepper.cjs +55 -0
- package/lib/WizardStepper.mjs +31 -0
- package/lib/_abstract/Button.cjs +114 -0
- package/lib/_abstract/Button.mjs +92 -0
- package/lib/_abstract/CardList.cjs +100 -0
- package/lib/_abstract/CardList.mjs +76 -0
- package/lib/_abstract/Image.cjs +75 -0
- package/lib/_abstract/Image.mjs +51 -0
- package/lib/_abstract/Link.cjs +37 -0
- package/lib/_abstract/Link.mjs +10 -0
- package/lib/_abstract/TogglerGroup.cjs +92 -0
- package/lib/_abstract/TogglerGroup.mjs +70 -0
- package/lib/_abstract/TogglerGroupField.cjs +121 -0
- package/lib/_abstract/TogglerGroupField.mjs +99 -0
- package/lib/_abstract/TogglerInput.cjs +105 -0
- package/lib/_abstract/TogglerInput.mjs +83 -0
- package/lib/_abstract/_AbstractCarousel.cjs +170 -0
- package/lib/_abstract/_AbstractCarousel.mjs +152 -0
- package/lib/_abstract/_Blings.cjs +47 -0
- package/lib/_abstract/_Blings.mjs +23 -0
- package/lib/_abstract/_Block.cjs +73 -0
- package/lib/_abstract/_Block.mjs +51 -0
- package/lib/_abstract/_Quote.cjs +43 -0
- package/lib/_abstract/_Quote.mjs +17 -0
- package/lib/_abstract/breakOnNL.cjs +30 -0
- package/lib/_abstract/breakOnNL.mjs +6 -0
- package/lib/assets.cjs +77 -0
- package/lib/assets.mjs +53 -0
- package/lib/constants.cjs +49 -0
- package/lib/constants.mjs +24 -0
- package/lib/focus-visible.cjs +1 -0
- package/lib/focus-visible.mjs +1 -0
- package/lib/utils/config.cjs +27 -0
- package/lib/utils/config.mjs +4 -0
- package/lib/utils/detectEdgeScroll.cjs +95 -0
- package/lib/utils/detectEdgeScroll.mjs +71 -0
- package/lib/utils/env.cjs +31 -0
- package/lib/utils/env.mjs +5 -0
- package/lib/utils/seenEffect.cjs +93 -0
- package/lib/utils/seenEffect.mjs +65 -0
- package/lib/utils/useFormatMonitor.cjs +29 -0
- package/lib/utils/useFormatMonitor.mjs +6 -0
- package/lib/utils/useGetSVGtext.cjs +44 -0
- package/lib/utils/useGetSVGtext.mjs +21 -0
- package/lib/utils/useMenuToggling.cjs +83 -0
- package/lib/utils/useMenuToggling.mjs +60 -0
- package/lib/utils/useScrollbarWidthCSSVar.cjs +32 -0
- package/lib/utils/useScrollbarWidthCSSVar.mjs +6 -0
- package/lib/utils.cjs +18 -0
- package/lib/utils.mjs +2 -0
- package/package.json +491 -0
- package/types/AccordionList.d.ts +17 -0
- package/types/ActionCards.d.ts +5 -0
- package/types/Alert.d.ts +49 -0
- package/types/ArticleCarousel/_ArticleCarouselCard.d.ts +27 -0
- package/types/ArticleCarousel.d.ts +12 -0
- package/types/ArticleMeta.d.ts +9 -0
- package/types/Attention.d.ts +7 -0
- package/types/BasicTable.d.ts +12 -0
- package/types/Bling.d.ts +81 -0
- package/types/BlockBreak.d.ts +2 -0
- package/types/BlockQuote.d.ts +4 -0
- package/types/BreadCrumbs.d.ts +11 -0
- package/types/ButtonBack.d.ts +7 -0
- package/types/ButtonBar.d.ts +16 -0
- package/types/ButtonPrimary.d.ts +7 -0
- package/types/ButtonSecondary.d.ts +7 -0
- package/types/ButtonTertiary.d.ts +12 -0
- package/types/Carousel.d.ts +4 -0
- package/types/CarouselStepper.d.ts +4 -0
- package/types/CenterColumn.d.ts +7 -0
- package/types/Checkbox.d.ts +4 -0
- package/types/CheckboxButtonsGroup.d.ts +11 -0
- package/types/CheckboxGroup.d.ts +9 -0
- package/types/CityBlock.d.ts +23 -0
- package/types/ContactBubble.d.ts +58 -0
- package/types/ContentArticle.d.ts +15 -0
- package/types/ContentImage.d.ts +8 -0
- package/types/Datepicker.d.ts +39 -0
- package/types/ExtraLinks.d.ts +18 -0
- package/types/FeatureList.d.ts +12 -0
- package/types/FieldGroup.d.ts +9 -0
- package/types/FileInput.d.ts +17 -0
- package/types/Foonote.d.ts +12 -0
- package/types/FooterBadges.d.ts +9 -0
- package/types/FooterInfo.d.ts +18 -0
- package/types/Footnote.d.ts +6 -0
- package/types/Form.d.ts +7 -0
- package/types/FormField.d.ts +65 -0
- package/types/Gallery/_GalleryItem.d.ts +8 -0
- package/types/Gallery/_GalleryModal.d.ts +6 -0
- package/types/Gallery/_GalleryModalContext.d.ts +9 -0
- package/types/Gallery/_GalleryModalItem.d.ts +3 -0
- package/types/Gallery.d.ts +17 -0
- package/types/GridBlocks.d.ts +26 -0
- package/types/Heading.d.ts +16 -0
- package/types/HeroBlock.d.ts +19 -0
- package/types/IframeBlock.d.ts +23 -0
- package/types/Illustration.d.ts +13 -0
- package/types/ImageCards.d.ts +8 -0
- package/types/InfoBlock.d.ts +17 -0
- package/types/InfoHero.d.ts +17 -0
- package/types/IslandBlock.d.ts +25 -0
- package/types/IslandPageBlock.d.ts +24 -0
- package/types/LabeledTextBlock.d.ts +11 -0
- package/types/Layout.d.ts +33 -0
- package/types/MainMenu/_Auxiliary.d.ts +6 -0
- package/types/MainMenu/_PrimaryPanel.d.ts +13 -0
- package/types/MainMenu.d.ts +48 -0
- package/types/MiniMetrics.d.ts +8 -0
- package/types/Modal.d.ts +10 -0
- package/types/NameCard.d.ts +64 -0
- package/types/NameCards.d.ts +6 -0
- package/types/NewsHero.d.ts +14 -0
- package/types/PageFilter.d.ts +17 -0
- package/types/PageHeading.d.ts +10 -0
- package/types/ProcessOverview.d.ts +13 -0
- package/types/PullQuote.d.ts +4 -0
- package/types/RadioButtonsGroup.d.ts +11 -0
- package/types/RadioGroup.d.ts +13 -0
- package/types/RelatedLinks.d.ts +20 -0
- package/types/RowBlock.d.ts +12 -0
- package/types/RowBlockColumn.d.ts +8 -0
- package/types/SearchInput.d.ts +18 -0
- package/types/SearchResults/_SearchResultsItem.d.ts +18 -0
- package/types/SearchResults.d.ts +33 -0
- package/types/SeenEffect.d.ts +4 -0
- package/types/Selectbox.d.ts +8 -0
- package/types/ShareButtons.d.ts +9 -0
- package/types/Sharpie.d.ts +23 -0
- package/types/SiteSearchAutocomplete.d.ts +40 -0
- package/types/SiteSearchCurtain.d.ts +6 -0
- package/types/SiteSearchInput.d.ts +24 -0
- package/types/Skeleton.d.ts +25 -0
- package/types/SubHeading.d.ts +10 -0
- package/types/Tabs.d.ts +35 -0
- package/types/TagPill.d.ts +27 -0
- package/types/TextBlock.d.ts +15 -0
- package/types/TextButton.d.ts +9 -0
- package/types/TextInput.d.ts +16 -0
- package/types/VSpacer.d.ts +24 -0
- package/types/VerticalTabsTOC.d.ts +14 -0
- package/types/WizardLayout.d.ts +15 -0
- package/types/WizardLayoutClose.d.ts +3 -0
- package/types/WizardStepper.d.ts +36 -0
- package/types/_abstract/Button.d.ts +40 -0
- package/types/_abstract/CardList.d.ts +29 -0
- package/types/_abstract/Image.d.ts +32 -0
- package/types/_abstract/Link.d.ts +27 -0
- package/types/_abstract/TogglerGroup.d.ts +31 -0
- package/types/_abstract/TogglerGroupField.d.ts +17 -0
- package/types/_abstract/TogglerInput.d.ts +22 -0
- package/types/_abstract/_AbstractCarousel.d.ts +25 -0
- package/types/_abstract/_Blings.d.ts +11 -0
- package/types/_abstract/_Block.d.ts +22 -0
- package/types/_abstract/_Quote.d.ts +9 -0
- package/types/_abstract/breakOnNL.d.ts +2 -0
- package/types/assets.d.ts +42 -0
- package/types/constants.d.ts +39 -0
- package/types/focus-visible.d.ts +1 -0
- package/types/utils/config.d.ts +2 -0
- package/types/utils/detectEdgeScroll.d.ts +52 -0
- package/types/utils/env.d.ts +1 -0
- package/types/utils/seenEffect.d.ts +28 -0
- package/types/utils/useFormatMonitor.d.ts +38 -0
- package/types/utils/useGetSVGtext.d.ts +6 -0
- package/types/utils/useMenuToggling.d.ts +8 -0
- package/types/utils/useScrollbarWidthCSSVar.d.ts +1 -0
- package/types/utils.d.ts +2 -0
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Illustration } from '@reykjavik/hanna-utils/assets';
|
|
2
|
+
import { ButtonProps } from './_abstract/Button';
|
|
3
|
+
import { ImageProps } from './_abstract/Image';
|
|
4
|
+
import { SeenProp } from './utils/seenEffect';
|
|
5
|
+
declare type HeroBlockImageProps = {
|
|
6
|
+
illustration: Illustration;
|
|
7
|
+
image?: undefined;
|
|
8
|
+
} | {
|
|
9
|
+
image: ImageProps;
|
|
10
|
+
illustration?: undefined;
|
|
11
|
+
};
|
|
12
|
+
export declare type HeroBlockProps = {
|
|
13
|
+
title: string;
|
|
14
|
+
summary: string | JSX.Element;
|
|
15
|
+
primaryButton?: ButtonProps;
|
|
16
|
+
secondaryButton?: ButtonProps;
|
|
17
|
+
} & HeroBlockImageProps & SeenProp;
|
|
18
|
+
declare const HeroBlock: (props: HeroBlockProps) => JSX.Element;
|
|
19
|
+
export default HeroBlock;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export declare type IframeBlockProps = {
|
|
2
|
+
src: string;
|
|
3
|
+
framed?: boolean;
|
|
4
|
+
compact?: boolean;
|
|
5
|
+
align?: 'right';
|
|
6
|
+
} & ({
|
|
7
|
+
/** Default: 'auto' ... which initializes "iframe-resizer" script */
|
|
8
|
+
height?: 'auto';
|
|
9
|
+
scrolling?: never;
|
|
10
|
+
} | {
|
|
11
|
+
height: number;
|
|
12
|
+
scrolling?: boolean | 'no' | 'yes';
|
|
13
|
+
});
|
|
14
|
+
/**
|
|
15
|
+
* When `height` is undefined or "auto", then Add the following code-snipped to the iframed page:
|
|
16
|
+
*
|
|
17
|
+
* ```js
|
|
18
|
+
* <script> window.iFrameResizer = { targetOrigin: '*' }; </script>
|
|
19
|
+
* <script src="https://styles.reykjavik.is/assets/scripts/iframeResizer.contentWindow@4.js"></script>
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
22
|
+
declare const IframeBlock: (props: IframeBlockProps) => JSX.Element;
|
|
23
|
+
export default IframeBlock;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Illustration as IllustrationName } from '@reykjavik/hanna-utils/assets';
|
|
2
|
+
import { ImageProps } from './_abstract/Image';
|
|
3
|
+
declare type IllustrationProps = {
|
|
4
|
+
children?: undefined;
|
|
5
|
+
} & ({
|
|
6
|
+
type: IllustrationName;
|
|
7
|
+
image?: undefined;
|
|
8
|
+
} | {
|
|
9
|
+
image: ImageProps;
|
|
10
|
+
type?: undefined;
|
|
11
|
+
});
|
|
12
|
+
declare const Illustration: (props: IllustrationProps) => JSX.Element;
|
|
13
|
+
export default Illustration;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ImageCardListProps, ImageCardProps as ICP } from './_abstract/CardList';
|
|
2
|
+
import { SeenProp } from './utils/seenEffect';
|
|
3
|
+
export declare type ImageCardProps = ICP;
|
|
4
|
+
declare type _ImageCardProps = ImageCardListProps & {
|
|
5
|
+
background?: boolean;
|
|
6
|
+
} & SeenProp;
|
|
7
|
+
declare const ImageCards: (props: _ImageCardProps) => JSX.Element;
|
|
8
|
+
export default ImageCards;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { SeenProp } from './utils/seenEffect';
|
|
2
|
+
export declare type InfoBlockProps = {
|
|
3
|
+
title: string;
|
|
4
|
+
subtitle: string | JSX.Element;
|
|
5
|
+
items: Array<string | JSX.Element>;
|
|
6
|
+
} & ({
|
|
7
|
+
attention?: undefined;
|
|
8
|
+
extraInfo?: undefined;
|
|
9
|
+
} | {
|
|
10
|
+
attention: string | JSX.Element;
|
|
11
|
+
extraInfo?: undefined;
|
|
12
|
+
} | {
|
|
13
|
+
extraInfo: string | JSX.Element;
|
|
14
|
+
attention?: undefined;
|
|
15
|
+
}) & SeenProp;
|
|
16
|
+
declare const InfoBlock: (props: InfoBlockProps) => JSX.Element;
|
|
17
|
+
export default InfoBlock;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { ButtonProps } from './_abstract/Button';
|
|
2
|
+
import { ImageProps } from './_abstract/Image';
|
|
3
|
+
import { Alignment } from './constants';
|
|
4
|
+
declare type BlingOptions = 'waves' | 'sunny-waves' | 'triangles' | 'circles';
|
|
5
|
+
export declare type InfoHeroProps = {
|
|
6
|
+
title: string;
|
|
7
|
+
titleBlurb?: string | JSX.Element;
|
|
8
|
+
/** Inserts `<br/>`s on `\n`. Collapses multiple `\n`s. */
|
|
9
|
+
subTitle?: string;
|
|
10
|
+
blurb?: string | JSX.Element;
|
|
11
|
+
buttons?: Array<ButtonProps>;
|
|
12
|
+
align?: Alignment;
|
|
13
|
+
image?: ImageProps;
|
|
14
|
+
blingType?: BlingOptions;
|
|
15
|
+
};
|
|
16
|
+
declare const InfoHero: (props: InfoHeroProps) => JSX.Element;
|
|
17
|
+
export default InfoHero;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { Formheimur } from '@reykjavik/hanna-utils/assets';
|
|
2
|
+
import { BlockItem } from './_abstract/_Block';
|
|
3
|
+
import { ImageProps } from './_abstract/Image';
|
|
4
|
+
import { SeenProp } from './utils/seenEffect';
|
|
5
|
+
import { Alignment } from './constants';
|
|
6
|
+
declare type IslandBaseBlockProps = {
|
|
7
|
+
align?: Alignment;
|
|
8
|
+
};
|
|
9
|
+
declare type IslandImageBlock = {
|
|
10
|
+
content: BlockItem;
|
|
11
|
+
} & ({
|
|
12
|
+
shapes: Formheimur;
|
|
13
|
+
image?: undefined;
|
|
14
|
+
} | {
|
|
15
|
+
image: ImageProps;
|
|
16
|
+
shapes?: undefined;
|
|
17
|
+
});
|
|
18
|
+
declare type IslandContentBlocks = {
|
|
19
|
+
content: Array<BlockItem>;
|
|
20
|
+
shapes?: undefined;
|
|
21
|
+
image?: undefined;
|
|
22
|
+
};
|
|
23
|
+
export declare type IslandBlockProps = IslandBaseBlockProps & (IslandContentBlocks | IslandImageBlock) & SeenProp;
|
|
24
|
+
declare const IslandBlock: (props: IslandBlockProps) => JSX.Element;
|
|
25
|
+
export default IslandBlock;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { Illustration } from '@reykjavik/hanna-utils/assets';
|
|
2
|
+
import { BlockItem } from './_abstract/_Block';
|
|
3
|
+
import { ImageProps } from './_abstract/Image';
|
|
4
|
+
import { SeenProp } from './utils/seenEffect';
|
|
5
|
+
import { Alignment } from './constants';
|
|
6
|
+
declare const backgrounds: {
|
|
7
|
+
none: undefined;
|
|
8
|
+
gray: string;
|
|
9
|
+
secondary: string;
|
|
10
|
+
};
|
|
11
|
+
declare type Background = keyof typeof backgrounds;
|
|
12
|
+
declare type IslandPageImageProps = {
|
|
13
|
+
illustration: Illustration;
|
|
14
|
+
image?: undefined;
|
|
15
|
+
} | {
|
|
16
|
+
illustration?: undefined;
|
|
17
|
+
image: ImageProps;
|
|
18
|
+
};
|
|
19
|
+
export declare type IslandPageBlockProps = BlockItem & IslandPageImageProps & {
|
|
20
|
+
align?: Alignment;
|
|
21
|
+
background?: Background;
|
|
22
|
+
} & SeenProp;
|
|
23
|
+
declare const IslandPageBlock: (props: IslandPageBlockProps) => JSX.Element;
|
|
24
|
+
export default IslandPageBlock;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { ButtonProps } from './_abstract/Button';
|
|
3
|
+
import { SeenProp } from './utils/seenEffect';
|
|
4
|
+
export declare type LabeledTextBlockProps = {
|
|
5
|
+
label: string;
|
|
6
|
+
summary: string | ReactElement;
|
|
7
|
+
wide?: boolean;
|
|
8
|
+
buttons?: Array<ButtonProps>;
|
|
9
|
+
} & SeenProp;
|
|
10
|
+
declare const LabeledTextBlock: (props: LabeledTextBlockProps) => JSX.Element;
|
|
11
|
+
export default LabeledTextBlock;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { SSRSupport } from '@hugsmidjan/react/hooks';
|
|
3
|
+
import { BemPropsModifier } from '@hugsmidjan/react/types';
|
|
4
|
+
import { HannaColorTheme } from '@reykjavik/hanna-css';
|
|
5
|
+
import { DefaultTexts } from '@reykjavik/hanna-utils/i18n';
|
|
6
|
+
export declare type LayoutI18n = {
|
|
7
|
+
lang?: string;
|
|
8
|
+
skipLinkLabel: string;
|
|
9
|
+
closeMenuLabel: string;
|
|
10
|
+
closeMenuLabelLong?: string;
|
|
11
|
+
};
|
|
12
|
+
export declare const defaultLayoutTexts: DefaultTexts<LayoutI18n>;
|
|
13
|
+
declare type LayoutProps = {
|
|
14
|
+
globalAlerts?: ReactNode;
|
|
15
|
+
mainChildren?: ReactNode;
|
|
16
|
+
navChildren?: ReactNode;
|
|
17
|
+
footerChildren?: ReactNode;
|
|
18
|
+
colorTheme?: HannaColorTheme;
|
|
19
|
+
logoLink?: string;
|
|
20
|
+
siteName?: string;
|
|
21
|
+
modifier?: BemPropsModifier['modifier'];
|
|
22
|
+
ssr?: SSRSupport;
|
|
23
|
+
texts?: LayoutI18n;
|
|
24
|
+
lang?: string;
|
|
25
|
+
} & ({
|
|
26
|
+
mainChildren: ReactNode;
|
|
27
|
+
children?: never;
|
|
28
|
+
} | {
|
|
29
|
+
mainChildren?: never;
|
|
30
|
+
children: ReactNode;
|
|
31
|
+
});
|
|
32
|
+
declare const Layout: (props: LayoutProps) => JSX.Element;
|
|
33
|
+
export default Layout;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { MegaMenuPanel } from '../MainMenu';
|
|
2
|
+
export declare type AuxilaryPanelIllustration = 'hanna-veitiggi' | 'hanna-vandro' | 'hanna-hugsi' | 'hanna-hissa' | 'hanna-hahaha' | 'hanna-hae' | 'hanna-god_spurning' | 'hanna-gjuggiborg' | 'hanna-benda';
|
|
3
|
+
export declare type AuxiliaryPanelProps = MegaMenuPanel & {
|
|
4
|
+
image?: AuxilaryPanelIllustration;
|
|
5
|
+
};
|
|
6
|
+
export declare const AuxiliaryPanel: (props: AuxiliaryPanelProps) => JSX.Element;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { RefObject } from 'react';
|
|
2
|
+
import { MainMenuI18n, MegaMenuPanel } from '../MainMenu';
|
|
3
|
+
declare type PrimaryPanelProps = {
|
|
4
|
+
setActivePanel: (panel: MegaMenuPanel | undefined, setFocus?: boolean) => void;
|
|
5
|
+
isParent?: boolean;
|
|
6
|
+
isActive?: boolean;
|
|
7
|
+
panel: MegaMenuPanel;
|
|
8
|
+
texts: MainMenuI18n;
|
|
9
|
+
activeRef: RefObject<HTMLLIElement>;
|
|
10
|
+
isBrowser: true | undefined;
|
|
11
|
+
};
|
|
12
|
+
export declare const PrimaryPanel: (props: PrimaryPanelProps) => JSX.Element;
|
|
13
|
+
export {};
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { SSRSupport } from '@hugsmidjan/react/hooks';
|
|
2
|
+
import { DefaultTexts } from '@reykjavik/hanna-utils/i18n';
|
|
3
|
+
import { AuxilaryPanelIllustration, AuxiliaryPanelProps } from './MainMenu/_Auxiliary';
|
|
4
|
+
export declare type MainMenuI18n = {
|
|
5
|
+
lang?: string;
|
|
6
|
+
backToMenu: string;
|
|
7
|
+
backToMenuLong?: string;
|
|
8
|
+
};
|
|
9
|
+
export declare const defaultMainMenuTexts: DefaultTexts<MainMenuI18n>;
|
|
10
|
+
export type { AuxilaryPanelIllustration, AuxiliaryPanelProps };
|
|
11
|
+
export declare type MainMenuItem = {
|
|
12
|
+
label: string;
|
|
13
|
+
labelLong?: string;
|
|
14
|
+
lang?: string;
|
|
15
|
+
modifier?: string;
|
|
16
|
+
current?: boolean;
|
|
17
|
+
href?: string;
|
|
18
|
+
onClick?: (index: number, item: MainMenuItem) => void;
|
|
19
|
+
controlsId?: string;
|
|
20
|
+
};
|
|
21
|
+
export declare type MainMenuSeparator = '---';
|
|
22
|
+
export declare type MainMenuItemList = Array<MainMenuItem | MainMenuSeparator>;
|
|
23
|
+
export declare type MegaMenuItem = {
|
|
24
|
+
label: string;
|
|
25
|
+
summary?: string;
|
|
26
|
+
href: string;
|
|
27
|
+
lang?: string;
|
|
28
|
+
current?: boolean;
|
|
29
|
+
target?: string;
|
|
30
|
+
};
|
|
31
|
+
export declare type MegaMenuPanel = {
|
|
32
|
+
title: string;
|
|
33
|
+
items: Array<MegaMenuItem>;
|
|
34
|
+
id: string;
|
|
35
|
+
};
|
|
36
|
+
export declare type MainMenuProps = {
|
|
37
|
+
title: string;
|
|
38
|
+
items: MainMenuItemList;
|
|
39
|
+
megaPanels?: Array<MegaMenuPanel>;
|
|
40
|
+
auxiliaryPanel?: AuxiliaryPanelProps;
|
|
41
|
+
onItemClick?: (index: number, item: MainMenuItem) => void;
|
|
42
|
+
activePanelId?: string;
|
|
43
|
+
texts?: MainMenuI18n;
|
|
44
|
+
lang?: string;
|
|
45
|
+
ssr?: SSRSupport;
|
|
46
|
+
};
|
|
47
|
+
declare const MainMenu: (props: MainMenuProps) => JSX.Element;
|
|
48
|
+
export default MainMenu;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ButtonProps } from './_abstract/Button';
|
|
2
|
+
import { SeenProp } from './utils/seenEffect';
|
|
3
|
+
export declare type MiniMetricsProps = {
|
|
4
|
+
text: string;
|
|
5
|
+
moreButton: ButtonProps;
|
|
6
|
+
} & SeenProp;
|
|
7
|
+
declare const MiniMetrics: (props: MiniMetricsProps) => JSX.Element;
|
|
8
|
+
export default MiniMetrics;
|
package/types/Modal.d.ts
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { ModalProps as _ModalProps } from '@hugsmidjan/react/Modal';
|
|
3
|
+
export declare type ModalProps = _ModalProps & {
|
|
4
|
+
bem?: never;
|
|
5
|
+
bodyWrap?: never;
|
|
6
|
+
modifier?: 'w6' | 'w8' | 'w10';
|
|
7
|
+
bling?: ReactElement;
|
|
8
|
+
};
|
|
9
|
+
declare const Modal: (props: ModalProps) => JSX.Element;
|
|
10
|
+
export default Modal;
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
export declare type NameCardI18n = {
|
|
2
|
+
updatedLabel: string;
|
|
3
|
+
availableLabel: string;
|
|
4
|
+
unavailableLabel: string;
|
|
5
|
+
/** @deprecated Use availableLabel instead (will be removed in v0.11) */
|
|
6
|
+
vacancyLabel?: string;
|
|
7
|
+
/** @deprecated Use unavailableLabel instead (will be removed in v0.11) */
|
|
8
|
+
noVacancyLabel?: string;
|
|
9
|
+
/** @deprecated Not used anymore (will be rmoved in v0.11) */
|
|
10
|
+
telLabel?: string;
|
|
11
|
+
};
|
|
12
|
+
declare type ContactInfo = {
|
|
13
|
+
href: string;
|
|
14
|
+
label: string;
|
|
15
|
+
longLabel?: string;
|
|
16
|
+
};
|
|
17
|
+
/** @deprecated use label and longLabel props instead (Will be removed in v0.11) */
|
|
18
|
+
declare type DeprecatedContactInfo = {
|
|
19
|
+
href: string;
|
|
20
|
+
value: string;
|
|
21
|
+
label?: string;
|
|
22
|
+
};
|
|
23
|
+
export declare type NameCardProps = {
|
|
24
|
+
name: string;
|
|
25
|
+
/** Phone numbers, e-mail addresses, etc. */
|
|
26
|
+
contactInfo?: Array<string | ContactInfo | DeprecatedContactInfo>;
|
|
27
|
+
/** Address/location info
|
|
28
|
+
*
|
|
29
|
+
* Special handling of string:
|
|
30
|
+
* Inserts `<br/>`s on `\n`. Collapses multiple `\n`s.
|
|
31
|
+
*
|
|
32
|
+
* Only simple, inline element HTML allowed
|
|
33
|
+
*/
|
|
34
|
+
location?: string | JSX.Element;
|
|
35
|
+
/** Misc info such as opening-hours, etc.
|
|
36
|
+
*
|
|
37
|
+
* Special handling of string:
|
|
38
|
+
* Inserts `<br/>`s on `\n`. Collapses multiple `\n`s.
|
|
39
|
+
*
|
|
40
|
+
* Only simple, inline element HTML allowed
|
|
41
|
+
*/
|
|
42
|
+
aboutText?: string | JSX.Element;
|
|
43
|
+
/**
|
|
44
|
+
* Designated for info about working/opening hours
|
|
45
|
+
*
|
|
46
|
+
* Special handling of string:
|
|
47
|
+
* Inserts `<br/>`s on `\n`. Collapses multiple `\n`s.
|
|
48
|
+
*
|
|
49
|
+
* Only simple, inline element HTML allowed
|
|
50
|
+
*/
|
|
51
|
+
hours?: string | JSX.Element;
|
|
52
|
+
/** Displays "active" indicator. Use for vacancies, inline-status, etc. */
|
|
53
|
+
available?: boolean;
|
|
54
|
+
/** Meta data about freshness status, etc. */
|
|
55
|
+
updated?: string | Date;
|
|
56
|
+
lang?: string;
|
|
57
|
+
texts?: NameCardI18n;
|
|
58
|
+
/** @deprecated Use `available` instead (will be removed in v0.11) */
|
|
59
|
+
vacancy?: boolean;
|
|
60
|
+
/** @deprecated Use `contactInfo` instead (will be removed in v0.11) */
|
|
61
|
+
tel?: string | Array<string>;
|
|
62
|
+
};
|
|
63
|
+
declare const NameCard: (props: NameCardProps) => JSX.Element;
|
|
64
|
+
export default NameCard;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { ImageProps } from './_abstract/Image';
|
|
2
|
+
import { SeenProp } from './utils/seenEffect';
|
|
3
|
+
declare type BlingOptions = 'interesting' | 'snake' | 'pentagon' | 'dome' | 'balls-small' | 'balls-large';
|
|
4
|
+
export declare type NewsHeroProps = {
|
|
5
|
+
title: string;
|
|
6
|
+
meta?: string;
|
|
7
|
+
summary?: string | JSX.Element;
|
|
8
|
+
/** For custom sharing component */
|
|
9
|
+
sharing?: boolean | (() => JSX.Element);
|
|
10
|
+
image?: ImageProps;
|
|
11
|
+
blingType?: BlingOptions;
|
|
12
|
+
} & SeenProp;
|
|
13
|
+
declare const NewsHero: (props: NewsHeroProps) => JSX.Element;
|
|
14
|
+
export default NewsHero;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { SeenProp } from './utils/seenEffect';
|
|
3
|
+
export declare type PageFilterProps = {
|
|
4
|
+
title: string;
|
|
5
|
+
summary?: React.ReactNode;
|
|
6
|
+
footnote?: React.ReactNode;
|
|
7
|
+
buttonRow?: React.ReactNode;
|
|
8
|
+
underlap?: boolean;
|
|
9
|
+
} & ({
|
|
10
|
+
filters: React.ReactNode;
|
|
11
|
+
children?: never;
|
|
12
|
+
} | {
|
|
13
|
+
filters?: never;
|
|
14
|
+
children: React.ReactNode;
|
|
15
|
+
}) & SeenProp;
|
|
16
|
+
declare const PageFilter: (props: PageFilterProps) => JSX.Element;
|
|
17
|
+
export default PageFilter;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { SeenProp } from './utils/seenEffect';
|
|
3
|
+
export declare type PageHeadingProps = {
|
|
4
|
+
Tag?: 'h1' | 'h2';
|
|
5
|
+
align?: 'right';
|
|
6
|
+
small?: boolean;
|
|
7
|
+
children: ReactNode;
|
|
8
|
+
} & SeenProp;
|
|
9
|
+
declare const PageHeading: (props: PageHeadingProps) => JSX.Element;
|
|
10
|
+
export default PageHeading;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export declare type ProcessOverviewItemProps = {
|
|
2
|
+
title: string;
|
|
3
|
+
content: string | JSX.Element;
|
|
4
|
+
};
|
|
5
|
+
export declare type ProcessOverviewProps = {
|
|
6
|
+
title: string;
|
|
7
|
+
items: Array<ProcessOverviewItemProps>;
|
|
8
|
+
attention?: string | JSX.Element;
|
|
9
|
+
transparent?: boolean;
|
|
10
|
+
narrow?: boolean;
|
|
11
|
+
};
|
|
12
|
+
declare const ProcessOverview: (props: ProcessOverviewProps) => JSX.Element;
|
|
13
|
+
export default ProcessOverview;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { TogglerGroupFieldOptions, TogglerGroupFieldProps } from './_abstract/TogglerGroupField';
|
|
2
|
+
export declare type RadioButtonsGroupProps = TogglerGroupFieldProps & {
|
|
3
|
+
value?: string;
|
|
4
|
+
/** @deprecated (Will be removed in v0.9) */
|
|
5
|
+
columns?: '2col' | '3col';
|
|
6
|
+
/** @deprecated (Will be removed in v0.9) */
|
|
7
|
+
layout?: 'slim';
|
|
8
|
+
};
|
|
9
|
+
export declare type RadioButtonsGroupOptions = TogglerGroupFieldOptions;
|
|
10
|
+
declare const RadioButtonsGroup: (props: RadioButtonsGroupProps) => JSX.Element;
|
|
11
|
+
export default RadioButtonsGroup;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { TogglerGroupFieldOption, TogglerGroupFieldOptions, TogglerGroupFieldProps } from './_abstract/TogglerGroupField';
|
|
2
|
+
import { TogglerInputProps } from './_abstract/TogglerInput';
|
|
3
|
+
export declare type RadioGroupProps = TogglerGroupFieldProps & {
|
|
4
|
+
layout?: 'inline';
|
|
5
|
+
value?: string;
|
|
6
|
+
};
|
|
7
|
+
export declare type RadioGroupOption = TogglerGroupFieldOption;
|
|
8
|
+
export declare type RadioGroupOptions = TogglerGroupFieldOptions;
|
|
9
|
+
declare const RadioGroup: {
|
|
10
|
+
(props: RadioGroupProps): JSX.Element;
|
|
11
|
+
__Radio: (props: TogglerInputProps) => JSX.Element;
|
|
12
|
+
};
|
|
13
|
+
export default RadioGroup;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
declare const types: {
|
|
2
|
+
readonly external: 1;
|
|
3
|
+
readonly document: 1;
|
|
4
|
+
readonly pdf: 1;
|
|
5
|
+
readonly link: 0;
|
|
6
|
+
};
|
|
7
|
+
export declare type RelatedLinkType = keyof typeof types;
|
|
8
|
+
export declare type RelatedLinkItem = {
|
|
9
|
+
href: string;
|
|
10
|
+
label: string;
|
|
11
|
+
target?: string;
|
|
12
|
+
type?: RelatedLinkType;
|
|
13
|
+
};
|
|
14
|
+
export declare type RelatedLinksProps = {
|
|
15
|
+
title?: string;
|
|
16
|
+
titleTag?: 'h2' | 'h3' | 'h4' | 'h5';
|
|
17
|
+
links: Array<RelatedLinkItem>;
|
|
18
|
+
};
|
|
19
|
+
declare const RelatedLinks: (props: RelatedLinksProps) => JSX.Element | null;
|
|
20
|
+
export default RelatedLinks;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { BemPropsModifier } from '@hugsmidjan/react/types';
|
|
3
|
+
import { SeenProp } from './utils/seenEffect';
|
|
4
|
+
export declare type RowBlockProps = {
|
|
5
|
+
/** Float the first RowBlockColumn to the right on larger screens. */
|
|
6
|
+
right?: boolean;
|
|
7
|
+
/** Custom **additional** class-name */
|
|
8
|
+
className?: string;
|
|
9
|
+
children: ReactNode;
|
|
10
|
+
} & BemPropsModifier & SeenProp;
|
|
11
|
+
declare const RowBlock: (props: RowBlockProps) => JSX.Element;
|
|
12
|
+
export default RowBlock;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
export declare type RowBlockColumnProps = {
|
|
3
|
+
background?: boolean | 'primary';
|
|
4
|
+
narrow?: boolean;
|
|
5
|
+
children: ReactNode;
|
|
6
|
+
};
|
|
7
|
+
declare const RowBlockColumn: (props: RowBlockColumnProps) => JSX.Element;
|
|
8
|
+
export default RowBlockColumn;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { RefObject } from 'react';
|
|
2
|
+
import { FormFieldWrappingProps } from './FormField';
|
|
3
|
+
declare type InputElmProps = JSX.IntrinsicElements['input'];
|
|
4
|
+
declare type BaseProps<Type extends {
|
|
5
|
+
type?: string;
|
|
6
|
+
}, InputProps extends object> = {
|
|
7
|
+
small?: boolean;
|
|
8
|
+
children?: undefined;
|
|
9
|
+
onButtonClick?: () => void;
|
|
10
|
+
buttonText?: string;
|
|
11
|
+
inputRef?: RefObject<HTMLInputElement>;
|
|
12
|
+
buttonRef?: RefObject<HTMLButtonElement>;
|
|
13
|
+
} & Type & FormFieldWrappingProps & InputProps;
|
|
14
|
+
export declare type SearchInputProps = BaseProps<{
|
|
15
|
+
type?: 'text';
|
|
16
|
+
}, InputElmProps>;
|
|
17
|
+
declare const SearchInput: (props: SearchInputProps) => JSX.Element;
|
|
18
|
+
export default SearchInput;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
declare type MetaValue = string | (() => JSX.Element | string | number);
|
|
2
|
+
export declare type SearchResultsItemProps = {
|
|
3
|
+
/** Plain text title */
|
|
4
|
+
title: string;
|
|
5
|
+
/** Simple HTML-encoded summary (excluding any layout) */
|
|
6
|
+
summary: string;
|
|
7
|
+
href: string;
|
|
8
|
+
meta?: MetaValue | ReadonlyArray<MetaValue>;
|
|
9
|
+
/**
|
|
10
|
+
* URL to the image to display with the result item.
|
|
11
|
+
* Should ideally be approximately 600-700px wide
|
|
12
|
+
*/
|
|
13
|
+
image?: string;
|
|
14
|
+
/** Should this search-result item be displayed as a "major"/"main" result at the top */
|
|
15
|
+
highlight?: boolean;
|
|
16
|
+
};
|
|
17
|
+
declare const SearchResultsItem: (props: SearchResultsItemProps) => JSX.Element;
|
|
18
|
+
export default SearchResultsItem;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { SearchResultsItemProps } from './SearchResults/_SearchResultsItem';
|
|
3
|
+
export declare type SearchReesultI18n = {
|
|
4
|
+
lang: string;
|
|
5
|
+
loadQueryTitle: string;
|
|
6
|
+
resultsTitle: string;
|
|
7
|
+
noResultsTitle: string;
|
|
8
|
+
loadMore: string;
|
|
9
|
+
};
|
|
10
|
+
export declare type SearchStatus = 'loadingquery' | 'loadingfilter' | 'error' | 'results' | 'loadingmore';
|
|
11
|
+
export declare type SearchResultsFilter = {
|
|
12
|
+
label: string;
|
|
13
|
+
count?: number;
|
|
14
|
+
};
|
|
15
|
+
export type { SearchResultsItemProps } from './SearchResults/_SearchResultsItem';
|
|
16
|
+
export declare type SearchResultsProps = {
|
|
17
|
+
totalHits?: number;
|
|
18
|
+
hits?: number;
|
|
19
|
+
query?: string;
|
|
20
|
+
items?: Array<SearchResultsItemProps>;
|
|
21
|
+
filters?: Array<SearchResultsFilter>;
|
|
22
|
+
activeFilterIdx?: number;
|
|
23
|
+
setFilter?: (activeTab: number) => void;
|
|
24
|
+
status: SearchStatus;
|
|
25
|
+
errorText?: string | ReactNode;
|
|
26
|
+
pageSize: number;
|
|
27
|
+
pages?: number;
|
|
28
|
+
loadMore?: () => void;
|
|
29
|
+
texts?: SearchReesultI18n;
|
|
30
|
+
lang?: string;
|
|
31
|
+
};
|
|
32
|
+
declare const SearchResults: (props: SearchResultsProps) => JSX.Element;
|
|
33
|
+
export default SearchResults;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { SelectboxProps as _SelectboxProps } from '@hugsmidjan/react/Selectbox';
|
|
2
|
+
import { FormFieldWrappingProps } from './FormField';
|
|
3
|
+
export declare type SelectboxProps = FormFieldWrappingProps & Omit<_SelectboxProps, 'bem'> & {
|
|
4
|
+
small?: boolean;
|
|
5
|
+
};
|
|
6
|
+
export type { SelectboxOptions } from '@hugsmidjan/react/Selectbox';
|
|
7
|
+
declare const Selectbox: (props: SelectboxProps) => JSX.Element;
|
|
8
|
+
export default Selectbox;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { SSRSupport } from '@hugsmidjan/react/hooks';
|
|
2
|
+
import { ShareButtonI18n, ShareButtonPlatforms } from '@reykjavik/hanna-utils/shareButtonsUtils';
|
|
3
|
+
export declare type ShareButtonsProps = {
|
|
4
|
+
ssr?: SSRSupport;
|
|
5
|
+
children?: undefined;
|
|
6
|
+
texts?: Readonly<ShareButtonI18n>;
|
|
7
|
+
} & Partial<Record<ShareButtonPlatforms, boolean>>;
|
|
8
|
+
declare const ShareButtons: (props: ShareButtonsProps) => JSX.Element | null;
|
|
9
|
+
export default ShareButtons;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
declare const colors: {
|
|
3
|
+
green: number;
|
|
4
|
+
red: number;
|
|
5
|
+
};
|
|
6
|
+
declare type SharpieColor = keyof typeof colors;
|
|
7
|
+
declare const tags: {
|
|
8
|
+
span: number;
|
|
9
|
+
strong: number;
|
|
10
|
+
em: number;
|
|
11
|
+
b: number;
|
|
12
|
+
i: number;
|
|
13
|
+
u: number;
|
|
14
|
+
s: number;
|
|
15
|
+
};
|
|
16
|
+
declare type SharpieTag = keyof typeof tags;
|
|
17
|
+
export declare type SharpieProps = {
|
|
18
|
+
color: SharpieColor;
|
|
19
|
+
tag?: SharpieTag;
|
|
20
|
+
children: ReactNode;
|
|
21
|
+
};
|
|
22
|
+
declare const Sharpie: (props: SharpieProps) => JSX.Element;
|
|
23
|
+
export default Sharpie;
|