optimized-react-component-library-xyz123 2.2.1 → 2.2.3

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/dist/index.d.mts CHANGED
@@ -1,4 +1,4 @@
1
- import React$1, { FC } from 'react';
1
+ import React$1, { ComponentType, SVGProps, FC, ElementType, RefObject, ReactNode } from 'react';
2
2
  import * as reselect from 'reselect';
3
3
  import * as _reduxjs_toolkit from '@reduxjs/toolkit';
4
4
  import { PayloadAction, ActionReducerMapBuilder } from '@reduxjs/toolkit';
@@ -46,7 +46,11 @@ interface IOption {
46
46
  interface IPTSLink {
47
47
  title: string;
48
48
  url: string;
49
- ariaLabel: string;
49
+ ariaLabel?: string;
50
+ activatedLanguage?: string;
51
+ openTarget?: string;
52
+ icon?: ComponentType<SVGProps<SVGSVGElement>>;
53
+ iconType?: string;
50
54
  }
51
55
  interface IStepObject {
52
56
  step: number;
@@ -136,8 +140,15 @@ interface IAppSettings {
136
140
  appUsesLanguage: boolean;
137
141
  appUsesNavigation: boolean;
138
142
  appCookies?: IAppSettingsCookies;
139
- appUsesPreview?: boolean;
140
143
  }
144
+ type INavigationItem = {
145
+ label: {
146
+ sv: string;
147
+ en: string;
148
+ };
149
+ href: string;
150
+ children?: INavigationItem[];
151
+ };
141
152
 
142
153
  interface RadioProps {
143
154
  question: IQuestion;
@@ -780,6 +791,54 @@ interface HeaderProps {
780
791
 
781
792
  declare const Header: FC<HeaderProps>;
782
793
 
794
+ interface NavigationHeaderProps {
795
+ SetActivatedLanguage?: (language: string) => void;
796
+ headline?: string;
797
+ homelink?: string;
798
+ activatedLanguage?: string;
799
+ useLanguage?: boolean;
800
+ useNavigationMenu: boolean;
801
+ useSearch?: boolean;
802
+ useBreadCrumbs?: boolean;
803
+ menuLinks: INavigationItem[];
804
+ linkComponent?: ElementType;
805
+ noLogoLink?: boolean;
806
+ }
807
+
808
+ declare const NavigationHeader: FC<NavigationHeaderProps>;
809
+
810
+ interface NavigationProps {
811
+ setIsMenyOpen?: (open: boolean) => void;
812
+ activatedLanguage?: string;
813
+ menuLinks?: INavigationLink[];
814
+ isOpen: boolean;
815
+ openButtonRef: RefObject<HTMLButtonElement | null>;
816
+ linkComponent?: ElementType;
817
+ }
818
+ type Locale = 'sv' | 'en';
819
+ type Label = Record<Locale, string>;
820
+ interface INavigationLink {
821
+ label: Label;
822
+ href: string;
823
+ children?: INavigationLink[];
824
+ openInNewWindow?: boolean;
825
+ }
826
+
827
+ declare const Navigation: FC<NavigationProps>;
828
+
829
+ interface BreadCrumbsProps {
830
+ activatedLanguage: string;
831
+ onLinkClick?: (e: React.MouseEvent) => void;
832
+ }
833
+
834
+ declare const BreadCrumbs: FC<BreadCrumbsProps>;
835
+
836
+ interface SearchBarProps {
837
+ activatedLanguage: string;
838
+ }
839
+
840
+ declare const SearchBar: FC<SearchBarProps>;
841
+
783
842
  interface ModalProps {
784
843
  showModal: boolean;
785
844
  activatedLanguage?: string;
@@ -792,6 +851,37 @@ type SkipLinkProps = {
792
851
  };
793
852
  declare const SkipLink: FC<SkipLinkProps>;
794
853
 
854
+ interface LinkProps extends IPTSLink {
855
+ customClass?: string;
856
+ openTarget?: string;
857
+ useDownLoad?: boolean;
858
+ linkComponent?: ElementType;
859
+ }
860
+
861
+ declare const LinkStandard: FC<LinkProps>;
862
+
863
+ interface LinkListProps {
864
+ linkArray: IPTSLink[];
865
+ activatedLanguage?: string;
866
+ customCss?: string;
867
+ linkComponent?: ElementType;
868
+ }
869
+
870
+ declare const LinkList: FC<LinkListProps>;
871
+
872
+ interface CollapseProps {
873
+ title: ReactNode;
874
+ children: ReactNode;
875
+ isOpen?: boolean;
876
+ defaultOpen?: boolean;
877
+ onToggle?: (open: boolean) => void;
878
+ id?: string;
879
+ activatedLanguage?: string;
880
+ customClass?: string;
881
+ }
882
+
883
+ declare const Collapse: FC<CollapseProps>;
884
+
795
885
  interface PrincipleOfPublicityProps {
796
886
  activatedLanguage?: string;
797
887
  }
@@ -898,4 +988,4 @@ interface FormStatusMessagesProps {
898
988
  */
899
989
  declare const FormStatusMessagesScreenReader: React$1.FC<FormStatusMessagesProps>;
900
990
 
901
- export { AddFiles as AddFilesStandard, CheckboxGroup as CheckboxGroupStandard, CookieBanner, type CookieConsentConfig, EditPreviewLink as EditPreviewLinkStandard, Footer as FooterStandard, FormStatusMessagesScreenReader, Header as HeaderStandard, type IAppSettings, type IAppSettingsCookies, type IApplicationContent, type IFormState, type IOption, type IPTSLink, type IQuestion, type IQuestionExtraAttribute, type IStepObject, type IStepQuestionData, type ITextBlock, type LanguageSupportConfig, Modal as ModalStandard, MultipleCheckboxes as MultipleCheckboxesStandard, PrincipleOfPublicity as PrincipleOfPublicityStandard, QuestionGroup, QuestionRenderer, InputRadio as RadioMultipleStandard, SingleCheckbox as SingleCheckboxStandard, SkipLink as SkipLinkStandard, StartApplicationButton, StepperButtons as StepperButtonsStandard, Stepper as StepperStandard, InputTextarea as TextAreaStandard, TextBody, TextFieldStandard, ValidationErrorSummaryList, buildStepCategoryGroupQuestionStructure, createApiDataObject, createCookieConsent, createFormSlice, createGlobalLanguageSlice, createGlobalLanguageSlice as createLanguageSlice, createFormSlice as createQuestionsSlice, findVisibleQuestionsWithValidationErrors, focusElement, getGroupCheckIds, hasQuestionValidationError, isQuestionDependencySatisfied, isScriptLoaded, makeFormSelectors, makeglobalLanguageSelectors as makeLanguageSelectors, makeFormSelectors as makeQuestionsSelectors, makeglobalLanguageSelectors, preparePreviewData, removeScriptById, toggleScriptByConsent, updateQuestionsAndCategoriesVisibilityAndErrors, useCookieConsent, useFormStatusModal, useInputMethodDetection, usePTSPageTitle };
991
+ export { AddFiles as AddFilesStandard, BreadCrumbs, BreadCrumbs as BreadcrumbsAdaptive, CheckboxGroup as CheckboxGroupStandard, Collapse, CookieBanner, type CookieConsentConfig, EditPreviewLink as EditPreviewLinkStandard, Footer as FooterStandard, FormStatusMessagesScreenReader, Header as HeaderStandard, type IAppSettings, type IAppSettingsCookies, type IApplicationContent, type IFormState, type IOption, type IPTSLink, type IQuestion, type IQuestionExtraAttribute, type IStepObject, type IStepQuestionData, type ITextBlock, type LanguageSupportConfig, LinkList as LinkListStandard, LinkStandard, Modal as ModalStandard, MultipleCheckboxes as MultipleCheckboxesStandard, Navigation, NavigationHeader, PrincipleOfPublicity as PrincipleOfPublicityStandard, QuestionGroup, QuestionRenderer, InputRadio as RadioMultipleStandard, SearchBar, SingleCheckbox as SingleCheckboxStandard, SkipLink as SkipLinkStandard, StartApplicationButton, StepperButtons as StepperButtonsStandard, Stepper as StepperStandard, InputTextarea as TextAreaStandard, TextBody, TextFieldStandard, ValidationErrorSummaryList, buildStepCategoryGroupQuestionStructure, createApiDataObject, createCookieConsent, createFormSlice, createGlobalLanguageSlice, createGlobalLanguageSlice as createLanguageSlice, createFormSlice as createQuestionsSlice, findVisibleQuestionsWithValidationErrors, focusElement, getGroupCheckIds, hasQuestionValidationError, isQuestionDependencySatisfied, isScriptLoaded, makeFormSelectors, makeglobalLanguageSelectors as makeLanguageSelectors, makeFormSelectors as makeQuestionsSelectors, makeglobalLanguageSelectors, preparePreviewData, removeScriptById, toggleScriptByConsent, updateQuestionsAndCategoriesVisibilityAndErrors, useCookieConsent, useFormStatusModal, useInputMethodDetection, usePTSPageTitle };
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import React$1, { FC } from 'react';
1
+ import React$1, { ComponentType, SVGProps, FC, ElementType, RefObject, ReactNode } from 'react';
2
2
  import * as reselect from 'reselect';
3
3
  import * as _reduxjs_toolkit from '@reduxjs/toolkit';
4
4
  import { PayloadAction, ActionReducerMapBuilder } from '@reduxjs/toolkit';
@@ -46,7 +46,11 @@ interface IOption {
46
46
  interface IPTSLink {
47
47
  title: string;
48
48
  url: string;
49
- ariaLabel: string;
49
+ ariaLabel?: string;
50
+ activatedLanguage?: string;
51
+ openTarget?: string;
52
+ icon?: ComponentType<SVGProps<SVGSVGElement>>;
53
+ iconType?: string;
50
54
  }
51
55
  interface IStepObject {
52
56
  step: number;
@@ -136,8 +140,15 @@ interface IAppSettings {
136
140
  appUsesLanguage: boolean;
137
141
  appUsesNavigation: boolean;
138
142
  appCookies?: IAppSettingsCookies;
139
- appUsesPreview?: boolean;
140
143
  }
144
+ type INavigationItem = {
145
+ label: {
146
+ sv: string;
147
+ en: string;
148
+ };
149
+ href: string;
150
+ children?: INavigationItem[];
151
+ };
141
152
 
142
153
  interface RadioProps {
143
154
  question: IQuestion;
@@ -780,6 +791,54 @@ interface HeaderProps {
780
791
 
781
792
  declare const Header: FC<HeaderProps>;
782
793
 
794
+ interface NavigationHeaderProps {
795
+ SetActivatedLanguage?: (language: string) => void;
796
+ headline?: string;
797
+ homelink?: string;
798
+ activatedLanguage?: string;
799
+ useLanguage?: boolean;
800
+ useNavigationMenu: boolean;
801
+ useSearch?: boolean;
802
+ useBreadCrumbs?: boolean;
803
+ menuLinks: INavigationItem[];
804
+ linkComponent?: ElementType;
805
+ noLogoLink?: boolean;
806
+ }
807
+
808
+ declare const NavigationHeader: FC<NavigationHeaderProps>;
809
+
810
+ interface NavigationProps {
811
+ setIsMenyOpen?: (open: boolean) => void;
812
+ activatedLanguage?: string;
813
+ menuLinks?: INavigationLink[];
814
+ isOpen: boolean;
815
+ openButtonRef: RefObject<HTMLButtonElement | null>;
816
+ linkComponent?: ElementType;
817
+ }
818
+ type Locale = 'sv' | 'en';
819
+ type Label = Record<Locale, string>;
820
+ interface INavigationLink {
821
+ label: Label;
822
+ href: string;
823
+ children?: INavigationLink[];
824
+ openInNewWindow?: boolean;
825
+ }
826
+
827
+ declare const Navigation: FC<NavigationProps>;
828
+
829
+ interface BreadCrumbsProps {
830
+ activatedLanguage: string;
831
+ onLinkClick?: (e: React.MouseEvent) => void;
832
+ }
833
+
834
+ declare const BreadCrumbs: FC<BreadCrumbsProps>;
835
+
836
+ interface SearchBarProps {
837
+ activatedLanguage: string;
838
+ }
839
+
840
+ declare const SearchBar: FC<SearchBarProps>;
841
+
783
842
  interface ModalProps {
784
843
  showModal: boolean;
785
844
  activatedLanguage?: string;
@@ -792,6 +851,37 @@ type SkipLinkProps = {
792
851
  };
793
852
  declare const SkipLink: FC<SkipLinkProps>;
794
853
 
854
+ interface LinkProps extends IPTSLink {
855
+ customClass?: string;
856
+ openTarget?: string;
857
+ useDownLoad?: boolean;
858
+ linkComponent?: ElementType;
859
+ }
860
+
861
+ declare const LinkStandard: FC<LinkProps>;
862
+
863
+ interface LinkListProps {
864
+ linkArray: IPTSLink[];
865
+ activatedLanguage?: string;
866
+ customCss?: string;
867
+ linkComponent?: ElementType;
868
+ }
869
+
870
+ declare const LinkList: FC<LinkListProps>;
871
+
872
+ interface CollapseProps {
873
+ title: ReactNode;
874
+ children: ReactNode;
875
+ isOpen?: boolean;
876
+ defaultOpen?: boolean;
877
+ onToggle?: (open: boolean) => void;
878
+ id?: string;
879
+ activatedLanguage?: string;
880
+ customClass?: string;
881
+ }
882
+
883
+ declare const Collapse: FC<CollapseProps>;
884
+
795
885
  interface PrincipleOfPublicityProps {
796
886
  activatedLanguage?: string;
797
887
  }
@@ -898,4 +988,4 @@ interface FormStatusMessagesProps {
898
988
  */
899
989
  declare const FormStatusMessagesScreenReader: React$1.FC<FormStatusMessagesProps>;
900
990
 
901
- export { AddFiles as AddFilesStandard, CheckboxGroup as CheckboxGroupStandard, CookieBanner, type CookieConsentConfig, EditPreviewLink as EditPreviewLinkStandard, Footer as FooterStandard, FormStatusMessagesScreenReader, Header as HeaderStandard, type IAppSettings, type IAppSettingsCookies, type IApplicationContent, type IFormState, type IOption, type IPTSLink, type IQuestion, type IQuestionExtraAttribute, type IStepObject, type IStepQuestionData, type ITextBlock, type LanguageSupportConfig, Modal as ModalStandard, MultipleCheckboxes as MultipleCheckboxesStandard, PrincipleOfPublicity as PrincipleOfPublicityStandard, QuestionGroup, QuestionRenderer, InputRadio as RadioMultipleStandard, SingleCheckbox as SingleCheckboxStandard, SkipLink as SkipLinkStandard, StartApplicationButton, StepperButtons as StepperButtonsStandard, Stepper as StepperStandard, InputTextarea as TextAreaStandard, TextBody, TextFieldStandard, ValidationErrorSummaryList, buildStepCategoryGroupQuestionStructure, createApiDataObject, createCookieConsent, createFormSlice, createGlobalLanguageSlice, createGlobalLanguageSlice as createLanguageSlice, createFormSlice as createQuestionsSlice, findVisibleQuestionsWithValidationErrors, focusElement, getGroupCheckIds, hasQuestionValidationError, isQuestionDependencySatisfied, isScriptLoaded, makeFormSelectors, makeglobalLanguageSelectors as makeLanguageSelectors, makeFormSelectors as makeQuestionsSelectors, makeglobalLanguageSelectors, preparePreviewData, removeScriptById, toggleScriptByConsent, updateQuestionsAndCategoriesVisibilityAndErrors, useCookieConsent, useFormStatusModal, useInputMethodDetection, usePTSPageTitle };
991
+ export { AddFiles as AddFilesStandard, BreadCrumbs, BreadCrumbs as BreadcrumbsAdaptive, CheckboxGroup as CheckboxGroupStandard, Collapse, CookieBanner, type CookieConsentConfig, EditPreviewLink as EditPreviewLinkStandard, Footer as FooterStandard, FormStatusMessagesScreenReader, Header as HeaderStandard, type IAppSettings, type IAppSettingsCookies, type IApplicationContent, type IFormState, type IOption, type IPTSLink, type IQuestion, type IQuestionExtraAttribute, type IStepObject, type IStepQuestionData, type ITextBlock, type LanguageSupportConfig, LinkList as LinkListStandard, LinkStandard, Modal as ModalStandard, MultipleCheckboxes as MultipleCheckboxesStandard, Navigation, NavigationHeader, PrincipleOfPublicity as PrincipleOfPublicityStandard, QuestionGroup, QuestionRenderer, InputRadio as RadioMultipleStandard, SearchBar, SingleCheckbox as SingleCheckboxStandard, SkipLink as SkipLinkStandard, StartApplicationButton, StepperButtons as StepperButtonsStandard, Stepper as StepperStandard, InputTextarea as TextAreaStandard, TextBody, TextFieldStandard, ValidationErrorSummaryList, buildStepCategoryGroupQuestionStructure, createApiDataObject, createCookieConsent, createFormSlice, createGlobalLanguageSlice, createGlobalLanguageSlice as createLanguageSlice, createFormSlice as createQuestionsSlice, findVisibleQuestionsWithValidationErrors, focusElement, getGroupCheckIds, hasQuestionValidationError, isQuestionDependencySatisfied, isScriptLoaded, makeFormSelectors, makeglobalLanguageSelectors as makeLanguageSelectors, makeFormSelectors as makeQuestionsSelectors, makeglobalLanguageSelectors, preparePreviewData, removeScriptById, toggleScriptByConsent, updateQuestionsAndCategoriesVisibilityAndErrors, useCookieConsent, useFormStatusModal, useInputMethodDetection, usePTSPageTitle };