@simplybusiness/services 2.4.5 → 2.4.7
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 +14 -0
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +3 -3
- package/dist/types/address-lookup/index.test.d.ts +0 -1
- package/dist/types/components/Actions/Actions.d.ts +0 -15
- package/dist/types/components/Actions/Actions.hidden-stories.d.ts +0 -10
- package/dist/types/components/Actions/Actions.stories.d.ts +0 -10
- package/dist/types/components/Actions/Actions.test.d.ts +0 -1
- package/dist/types/components/Actions/LinkOrButton.d.ts +0 -2
- package/dist/types/components/Actions/LinkOrButton.test.d.ts +0 -1
- package/dist/types/components/Actions/index.d.ts +0 -1
- package/dist/types/components/Footer/Address.d.ts +0 -6
- package/dist/types/components/Footer/Addresses.d.ts +0 -5
- package/dist/types/components/Footer/Copyright.d.ts +0 -7
- package/dist/types/components/Footer/Footer.d.ts +0 -2
- package/dist/types/components/Footer/Footer.stories.d.ts +0 -7
- package/dist/types/components/Footer/Footer.test.d.ts +0 -1
- package/dist/types/components/Footer/Legal.d.ts +0 -7
- package/dist/types/components/Footer/LegalLinks.d.ts +0 -5
- package/dist/types/components/Footer/OpeningHours.d.ts +0 -2
- package/dist/types/components/Footer/OpeningHoursEntry.d.ts +0 -2
- package/dist/types/components/Footer/SmallPrint.d.ts +0 -5
- package/dist/types/components/Footer/Support.d.ts +0 -3
- package/dist/types/components/Footer/Title.d.ts +0 -5
- package/dist/types/components/Footer/Underline.d.ts +0 -1
- package/dist/types/components/Footer/constants.d.ts +0 -25
- package/dist/types/components/Footer/index.d.ts +0 -2
- package/dist/types/components/Footer/types.d.ts +0 -18
- package/dist/types/components/Header/ContactDetails.d.ts +0 -2
- package/dist/types/components/Header/Header.d.ts +0 -2
- package/dist/types/components/Header/Header.stories.d.ts +0 -8
- package/dist/types/components/Header/Header.test.d.ts +0 -1
- package/dist/types/components/Header/Logo.d.ts +0 -2
- package/dist/types/components/Header/constants.d.ts +0 -4
- package/dist/types/components/Header/index.d.ts +0 -3
- package/dist/types/components/Header/mockOpeningHoursData.d.ts +0 -4
- package/dist/types/components/Header/types.d.ts +0 -25
- package/dist/types/components/HelpWidget/HelpWidget.d.ts +0 -10
- package/dist/types/components/HelpWidget/HelpWidget.stories.d.ts +0 -6
- package/dist/types/components/HelpWidget/HelpWidget.test.d.ts +0 -1
- package/dist/types/components/HelpWidget/index.d.ts +0 -1
- package/dist/types/components/MaskedField/MaskedField.d.ts +0 -11
- package/dist/types/components/MaskedField/MaskedField.hidden-stories.d.ts +0 -6
- package/dist/types/components/MaskedField/MaskedField.stories.d.ts +0 -6
- package/dist/types/components/MaskedField/MaskedField.test.d.ts +0 -1
- package/dist/types/components/MaskedField/index.d.ts +0 -1
- package/dist/types/components/MaskedField/inputFormatters.d.ts +0 -10
- package/dist/types/components/PageFlat/PageFlat.d.ts +0 -2
- package/dist/types/components/PageFlat/PageFlat.stories.d.ts +0 -6
- package/dist/types/components/PageFlat/index.d.ts +0 -1
- package/dist/types/components/PageNested/PageNested.d.ts +0 -2
- package/dist/types/components/PageNested/PageNested.stories.d.ts +0 -6
- package/dist/types/components/PageNested/index.d.ts +0 -1
- package/dist/types/components/PaymentConfirmation/PaymentConfirmation.d.ts +0 -6
- package/dist/types/components/PaymentConfirmation/PaymentConfirmation.hidden-stories.d.ts +0 -6
- package/dist/types/components/PaymentConfirmation/PaymentConfirmation.stories.d.ts +0 -6
- package/dist/types/components/PaymentConfirmation/PaymentConfirmation.test.d.ts +0 -1
- package/dist/types/components/PaymentConfirmation/index.d.ts +0 -1
- package/dist/types/components/PercentageTotalsQuestion/PercentageItem.d.ts +0 -6
- package/dist/types/components/PercentageTotalsQuestion/PercentageTotalsQuestion.d.ts +0 -10
- package/dist/types/components/PercentageTotalsQuestion/PercentageTotalsQuestion.hidden-stories.d.ts +0 -6
- package/dist/types/components/PercentageTotalsQuestion/PercentageTotalsQuestion.hiddenstories.d.ts +0 -6
- package/dist/types/components/PercentageTotalsQuestion/PercentageTotalsQuestion.stories.d.ts +0 -6
- package/dist/types/components/PercentageTotalsQuestion/PercentageTotalsQuestion.test.d.ts +0 -1
- package/dist/types/components/PercentageTotalsQuestion/index.d.ts +0 -1
- package/dist/types/components/PreFooter/LogoBbbAccreditedBusiness.d.ts +0 -5
- package/dist/types/components/PreFooter/LogoForbesAdvisor.d.ts +0 -5
- package/dist/types/components/PreFooter/PreFooter.d.ts +0 -10
- package/dist/types/components/PreFooter/PreFooter.stories.d.ts +0 -6
- package/dist/types/components/PreFooter/PreFooter.test.d.ts +0 -1
- package/dist/types/components/PreFooter/index.d.ts +0 -1
- package/dist/types/components/Question/Question.d.ts +0 -13
- package/dist/types/components/Question/Question.hidden-stories.d.ts +0 -14
- package/dist/types/components/Question/Question.stories.d.ts +0 -14
- package/dist/types/components/Question/Question.test.d.ts +0 -1
- package/dist/types/components/Question/index.d.ts +0 -1
- package/dist/types/components/QuestionGroup/QuestionGroup.d.ts +0 -16
- package/dist/types/components/QuestionGroup/QuestionGroup.hidden-stories.d.ts +0 -6
- package/dist/types/components/QuestionGroup/QuestionGroup.stories.d.ts +0 -6
- package/dist/types/components/QuestionGroup/QuestionGroup.test.d.ts +0 -1
- package/dist/types/components/QuestionGroup/index.d.ts +0 -1
- package/dist/types/components/QuestionHelp/QuestionHelp.d.ts +0 -11
- package/dist/types/components/QuestionHelp/QuestionHelp.test.d.ts +0 -1
- package/dist/types/components/QuestionHelp/index.d.ts +0 -1
- package/dist/types/components/QuestionHelp/question.d.ts +0 -3
- package/dist/types/components/Section/Section.d.ts +0 -14
- package/dist/types/components/Section/Section.hidden-stories.d.ts +0 -6
- package/dist/types/components/Section/Section.stories.d.ts +0 -6
- package/dist/types/components/Section/Section.test.d.ts +0 -1
- package/dist/types/components/Section/index.d.ts +0 -1
- package/dist/types/components/Steps/StepItem.d.ts +0 -20
- package/dist/types/components/Steps/Steps.d.ts +0 -13
- package/dist/types/components/Steps/Steps.hidden-stories.d.ts +0 -6
- package/dist/types/components/Steps/Steps.stories.d.ts +0 -6
- package/dist/types/components/Steps/Steps.test.d.ts +0 -1
- package/dist/types/components/Steps/index.d.ts +0 -2
- package/dist/types/components/Testimonial/Testimonial.d.ts +0 -13
- package/dist/types/components/Testimonial/Testimonial.hidden-stories.d.ts +0 -6
- package/dist/types/components/Testimonial/Testimonial.stories.d.ts +0 -6
- package/dist/types/components/Testimonial/Testimonial.test.d.ts +0 -1
- package/dist/types/components/Testimonial/index.d.ts +0 -1
- package/dist/types/components/ThankYou/ThankYou.d.ts +0 -3
- package/dist/types/components/ThankYou/ThankYou.stories.d.ts +0 -7
- package/dist/types/components/ThankYou/ThankYou.test.d.ts +0 -1
- package/dist/types/components/ThankYou/ThankYouSidebar.d.ts +0 -1
- package/dist/types/components/ThankYou/ThankYouText.d.ts +0 -2
- package/dist/types/components/ThankYou/ThankYouText.test.d.ts +0 -1
- package/dist/types/components/ThankYou/index.d.ts +0 -2
- package/dist/types/components/ThankYou/types.d.ts +0 -17
- package/dist/types/components/TradeSearch/SearchResults/SearchResults.d.ts +0 -15
- package/dist/types/components/TradeSearch/TradeSearch.d.ts +0 -2
- package/dist/types/components/TradeSearch/TradeSearch.stories.d.ts +0 -6
- package/dist/types/components/TradeSearch/components/Listing/Listing.d.ts +0 -12
- package/dist/types/components/TradeSearch/components/Listing/Listing.test.d.ts +0 -1
- package/dist/types/components/TradeSearch/components/Listing/ListingItem.d.ts +0 -8
- package/dist/types/components/TradeSearch/components/Listing/ListingItem.test.d.ts +0 -1
- package/dist/types/components/TradeSearch/components/Listing/index.d.ts +0 -1
- package/dist/types/components/TradeSearch/components/SearchResults/SearchResults.d.ts +0 -2
- package/dist/types/components/TradeSearch/components/SearchResults/SearchResults.test.d.ts +0 -1
- package/dist/types/components/TradeSearch/components/SearchResults/index.d.ts +0 -1
- package/dist/types/components/TradeSearch/components/TradeContext/TradeContext.d.ts +0 -1
- package/dist/types/components/TradeSearch/components/TradeContext/index.d.ts +0 -1
- package/dist/types/components/TradeSearch/components/index.d.ts +0 -1
- package/dist/types/components/TradeSearch/constants.d.ts +0 -1
- package/dist/types/components/TradeSearch/hooks/index.d.ts +0 -4
- package/dist/types/components/TradeSearch/hooks/useApiEndpoint.d.ts +0 -1
- package/dist/types/components/TradeSearch/hooks/useFetchTrades.d.ts +0 -6
- package/dist/types/components/TradeSearch/hooks/useTradeContext.d.ts +0 -1
- package/dist/types/components/TradeSearch/hooks/useTradeState.d.ts +0 -6
- package/dist/types/components/TradeSearch/index.d.ts +0 -2
- package/dist/types/components/TradeSearch/types.d.ts +0 -65
- package/dist/types/components/TradeSearch/utils/addQueryParam.d.ts +0 -1
- package/dist/types/components/TradeSearch/utils/index.d.ts +0 -1
- package/dist/types/components/TradeSelector/Header/Header.d.ts +0 -9
- package/dist/types/components/TradeSelector/Header/index.d.ts +0 -1
- package/dist/types/components/TradeSelector/Listing/Listing.d.ts +0 -12
- package/dist/types/components/TradeSelector/Listing/Listing.test.d.ts +0 -1
- package/dist/types/components/TradeSelector/Listing/ListingItem.d.ts +0 -8
- package/dist/types/components/TradeSelector/Listing/ListingItem.test.d.ts +0 -1
- package/dist/types/components/TradeSelector/Listing/index.d.ts +0 -1
- package/dist/types/components/TradeSelector/SearchResults/SearchResults.d.ts +0 -15
- package/dist/types/components/TradeSelector/SearchResults/SearchResults.test.d.ts +0 -1
- package/dist/types/components/TradeSelector/SearchResults/index.d.ts +0 -1
- package/dist/types/components/TradeSelector/TradeInput/TradeInput.d.ts +0 -15
- package/dist/types/components/TradeSelector/TradeInput/TradeInput.test.d.ts +0 -1
- package/dist/types/components/TradeSelector/TradeInput/index.d.ts +0 -1
- package/dist/types/components/TradeSelector/TradeSelector.d.ts +0 -5
- package/dist/types/components/TradeSelector/TradeSelector.stories.d.ts +0 -10
- package/dist/types/components/TradeSelector/TradeSelector.test.d.ts +0 -1
- package/dist/types/components/TradeSelector/config/development.d.ts +0 -7
- package/dist/types/components/TradeSelector/config/index.d.ts +0 -18
- package/dist/types/components/TradeSelector/config/production.d.ts +0 -7
- package/dist/types/components/TradeSelector/config/shared.d.ts +0 -17
- package/dist/types/components/TradeSelector/config/testing.d.ts +0 -7
- package/dist/types/components/TradeSelector/index.d.ts +0 -2
- package/dist/types/components/TradeSelector/jestHTMLDialogPolyfill.d.ts +0 -1
- package/dist/types/components/TradeSelector/mockApiResults.d.ts +0 -13
- package/dist/types/components/TradeSelector/types.d.ts +0 -51
- package/dist/types/components/TradeSelector/useFetchTrades/index.d.ts +0 -1
- package/dist/types/components/TradeSelector/useFetchTrades/useFetchTrades.d.ts +0 -7
- package/dist/types/components/TradeSelector/useTradeSelectorUrl/index.d.ts +0 -1
- package/dist/types/components/TradeSelector/useTradeSelectorUrl/useTradeSelectorUrl.d.ts +0 -6
- package/dist/types/components/TradeSelector/useTradeSelectorUrl/useTradeSelectorUrl.test.d.ts +0 -1
- package/dist/types/components/TrustSection/TrustSection.d.ts +0 -10
- package/dist/types/components/TrustSection/TrustSection.stories.d.ts +0 -6
- package/dist/types/components/TrustSection/TrustSection.test.d.ts +0 -1
- package/dist/types/components/TrustSection/index.d.ts +0 -1
- package/dist/types/data/page-contract-flat.d.ts +0 -17
- package/dist/types/data/page-contract-nested.d.ts +0 -17
- package/dist/types/data/page-contract-v1.d.ts +0 -2
- package/dist/types/data/page-contract-v2.d.ts +0 -2
- package/dist/types/data/scripts-mock.d.ts +0 -44
- package/dist/types/data/thank-you-page-mock.d.ts +0 -44
- package/dist/types/hooks/useOnClickOutside/index.d.ts +0 -1
- package/dist/types/hooks/useOnClickOutside/useOnClickOutside.d.ts +0 -2
- package/dist/types/hooks/useWindowEvent/index.d.ts +0 -1
- package/dist/types/hooks/useWindowEvent/useWindowEvent.d.ts +0 -1
- package/dist/types/pages/GeneralPage/GeneralPage.d.ts +0 -2
- package/dist/types/pages/GeneralPage/GeneralPage.stories.d.ts +0 -6
- package/dist/types/pages/GeneralPage/GeneralPage.test.d.ts +0 -1
- package/dist/types/pages/GeneralPage/Main.d.ts +0 -5
- package/dist/types/pages/GeneralPage/getMainComponents.d.ts +0 -6
- package/dist/types/pages/GeneralPage/index.d.ts +0 -1
- package/dist/types/pages/GeneralPage/mainComponents.d.ts +0 -2
- package/dist/types/pages/GeneralPage/types.d.ts +0 -23
- package/dist/types/pages/Page/Page.d.ts +0 -2
- package/dist/types/pages/Page/index.d.ts +0 -1
- package/dist/types/pages/Page/types.d.ts +0 -29
- package/dist/types/pages/Simple/Main.d.ts +0 -5
- package/dist/types/pages/Simple/Simple.d.ts +0 -2
- package/dist/types/pages/Simple/Simple.stories.d.ts +0 -6
- package/dist/types/pages/Simple/index.d.ts +0 -1
- package/dist/types/pages/Simple/useMainComponents.d.ts +0 -3
- package/dist/types/pages/ThankYouPage/ThankYouPage.d.ts +0 -2
- package/dist/types/pages/ThankYouPage/ThankYouPage.stories.d.ts +0 -6
- package/dist/types/pages/ThankYouPage/ThankYouPage.test.d.ts +0 -1
- package/dist/types/pages/ThankYouPage/index.d.ts +0 -1
- package/dist/types/pages/ThankYouPage/types.d.ts +0 -10
- package/dist/types/services/airbrake/index.d.ts +0 -2
- package/dist/types/services/index.d.ts +0 -2
- package/dist/types/services/snowplow/Snowplow.d.ts +0 -29
- package/dist/types/services/snowplow/SnowplowContext.d.ts +0 -14
- package/dist/types/services/snowplow/SnowplowContext.test.d.ts +0 -1
- package/dist/types/services/snowplow/contexts.d.ts +0 -3
- package/dist/types/services/snowplow/contexts.test.d.ts +0 -1
- package/dist/types/services/snowplow/event-definitions/base.d.ts +0 -18
- package/dist/types/services/snowplow/event-definitions/index.d.ts +0 -2
- package/dist/types/services/snowplow/event-definitions/qcp.d.ts +0 -18
- package/dist/types/services/snowplow/event-definitions.d.ts +0 -18
- package/dist/types/services/snowplow/getSnowplowConfig.d.ts +0 -2
- package/dist/types/services/snowplow/index.d.ts +0 -6
- package/dist/types/services/snowplow/index.test.d.ts +0 -1
- package/dist/types/services/snowplow/types.d.ts +0 -37
- package/dist/types/snowplow/SnowplowContext.test.d.ts +0 -1
- package/dist/types/snowplow/contexts.test.d.ts +0 -1
- package/dist/types/snowplow/event-definitions/events.d.ts +0 -20
- package/dist/types/snowplow/event-definitions/pcp.d.ts +0 -20
- package/dist/types/snowplow/event-definitions/progressbar.d.ts +0 -2
- package/dist/types/snowplow/event-definitions/questionnaire/questionnaire.test.d.ts +0 -1
- package/dist/types/snowplow/event-definitions/questionnaire.d.ts +0 -2
- package/dist/types/snowplow/event-definitions/questionnaire.test.d.ts +0 -1
- package/dist/types/snowplow/event-definitions/redaction.d.ts +0 -5
- package/dist/types/snowplow/event-definitions/shared.d.ts +0 -2
- package/dist/types/snowplow/event-definitions/shoppingCart.d.ts +0 -2
- package/dist/types/snowplow/event-definitions/thankYou.d.ts +0 -2
- package/dist/types/snowplow/events.d.ts +0 -20
- package/dist/types/snowplow/index.test.d.ts +0 -1
- package/dist/types/src/address-lookup/index.d.ts +0 -15
- package/dist/types/src/address-lookup/types.d.ts +0 -44
- package/dist/types/src/airbrake/index.d.ts +0 -9
- package/dist/types/src/index.d.ts +0 -3
- package/dist/types/src/mocks/eventDefinitions.d.ts +0 -61
- package/dist/types/src/mocks/scripts-mock.d.ts +0 -44
- package/dist/types/src/snowplow/Snowplow.d.ts +0 -34
- package/dist/types/src/snowplow/SnowplowContext.d.ts +0 -14
- package/dist/types/src/snowplow/constants.d.ts +0 -1
- package/dist/types/src/snowplow/contexts.d.ts +0 -4
- package/dist/types/src/snowplow/event-definitions/base.d.ts +0 -22
- package/dist/types/src/snowplow/event-definitions/coverage-selection.d.ts +0 -2
- package/dist/types/src/snowplow/event-definitions/index.d.ts +0 -8
- package/dist/types/src/snowplow/event-definitions/intervention.d.ts +0 -12
- package/dist/types/src/snowplow/event-definitions/personalised_cover.d.ts +0 -22
- package/dist/types/src/snowplow/event-definitions/qcp.d.ts +0 -2
- package/dist/types/src/snowplow/event-definitions/questionnaire/questionnaire.d.ts +0 -2
- package/dist/types/src/snowplow/event-definitions/questionnaire/redaction.d.ts +0 -5
- package/dist/types/src/snowplow/event-definitions/referral.d.ts +0 -2
- package/dist/types/src/snowplow/event-definitions/test-utils.d.ts +0 -2
- package/dist/types/src/snowplow/getSnowplowConfig.d.ts +0 -2
- package/dist/types/src/snowplow/index.d.ts +0 -6
- package/dist/types/src/snowplow/types.d.ts +0 -54
- package/dist/types/src/utils/index.d.ts +0 -2
- package/dist/types/src/utils/isObject.d.ts +0 -1
- package/dist/types/src/utils/testUtils.d.ts +0 -7
- package/dist/types/src/utils/text.d.ts +0 -3
- package/dist/types/tracking-helper/TrackingHelper.d.ts +0 -15
- package/dist/types/tracking-helper/index.d.ts +0 -15
- package/dist/types/types.d.ts +0 -5
- package/dist/types/utils/StoryContainer.d.ts +0 -1
- package/dist/types/utils/TrackingHelper.d.ts +0 -15
- package/dist/types/utils/TrustpilotProvider.d.ts +0 -4
- package/dist/types/utils/env.d.ts +0 -5
- package/dist/types/utils/env.test.d.ts +0 -1
- package/dist/types/utils/excludeControls.d.ts +0 -1
- package/dist/types/utils/excludeControls.test.d.ts +0 -1
- package/dist/types/utils/isObject.test.d.ts +0 -1
- package/dist/types/utils/spaceDelimitedList.d.ts +0 -1
- package/dist/types/utils/spaceDelimitedList.test.d.ts +0 -1
- package/dist/types/utils/text.test.d.ts +0 -1
- package/dist/types/vitest.config.d.ts +0 -2
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
export declare const snowplowEvents: {
|
|
2
|
-
limitChanged: (primaryText: string, newLimit: string) => {
|
|
3
|
-
label: string;
|
|
4
|
-
limit: string;
|
|
5
|
-
};
|
|
6
|
-
validationShown: (coverName: string, fieldName: string) => {
|
|
7
|
-
cover: string;
|
|
8
|
-
question: string;
|
|
9
|
-
};
|
|
10
|
-
coverQuestionAnswered: (questionText: string, answerValue: string) => {
|
|
11
|
-
question: string;
|
|
12
|
-
answer: string;
|
|
13
|
-
};
|
|
14
|
-
coverPresented: (primaryText: string) => {
|
|
15
|
-
property: string;
|
|
16
|
-
};
|
|
17
|
-
moreInfoClicked: (primaryText: string) => {
|
|
18
|
-
property: string;
|
|
19
|
-
};
|
|
20
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
export declare const snowplowEvents: {
|
|
2
|
-
limitChanged: (primaryText: string, newLimit: string) => {
|
|
3
|
-
label: string;
|
|
4
|
-
limit: string;
|
|
5
|
-
};
|
|
6
|
-
validationShown: (coverName: string, fieldName: string) => {
|
|
7
|
-
cover: string;
|
|
8
|
-
question: string;
|
|
9
|
-
};
|
|
10
|
-
coverQuestionAnswered: (questionText: string, answerValue: string) => {
|
|
11
|
-
question: string;
|
|
12
|
-
answer: string;
|
|
13
|
-
};
|
|
14
|
-
coverPresented: (primaryText: string) => {
|
|
15
|
-
property: string;
|
|
16
|
-
};
|
|
17
|
-
moreInfoClicked: (primaryText: string) => {
|
|
18
|
-
property: string;
|
|
19
|
-
};
|
|
20
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import type { AddressLookupConfig, Options } from "./types";
|
|
2
|
-
export declare class AddressLookup {
|
|
3
|
-
private apiKey;
|
|
4
|
-
private limit;
|
|
5
|
-
private findUrl;
|
|
6
|
-
private retrieveUrl;
|
|
7
|
-
private countries;
|
|
8
|
-
constructor({ apiKey, limit, countries }: AddressLookupConfig);
|
|
9
|
-
private static fetchFromApi;
|
|
10
|
-
find(partialAddress: string): Promise<Options>;
|
|
11
|
-
findById(id: string): Promise<Options>;
|
|
12
|
-
get(id: string): Promise<Record<string, string>>;
|
|
13
|
-
private formatItems;
|
|
14
|
-
private static formatUkAddress;
|
|
15
|
-
}
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
export type Option = {
|
|
2
|
-
id: string;
|
|
3
|
-
label: string;
|
|
4
|
-
value: string | number | boolean;
|
|
5
|
-
callback?: () => Promise<Options>;
|
|
6
|
-
};
|
|
7
|
-
export type OptionGroup = {
|
|
8
|
-
heading: string;
|
|
9
|
-
options: Option[];
|
|
10
|
-
};
|
|
11
|
-
export type Options = Option[] | OptionGroup[];
|
|
12
|
-
export type FindAddressResult = {
|
|
13
|
-
Id: string;
|
|
14
|
-
Type: string;
|
|
15
|
-
Text: string;
|
|
16
|
-
Highlight: string;
|
|
17
|
-
Description: string;
|
|
18
|
-
};
|
|
19
|
-
export type AddressError = {
|
|
20
|
-
Cause: string;
|
|
21
|
-
Error: string;
|
|
22
|
-
Description: string;
|
|
23
|
-
Resolution: string;
|
|
24
|
-
};
|
|
25
|
-
export type FindAddressResponse = {
|
|
26
|
-
Items: FindAddressResult[] | AddressError[];
|
|
27
|
-
};
|
|
28
|
-
export type RetrieveAddressResult = {
|
|
29
|
-
Id: string;
|
|
30
|
-
Type: string;
|
|
31
|
-
City: string;
|
|
32
|
-
Line1: string;
|
|
33
|
-
Line2: string;
|
|
34
|
-
PostalCode: string;
|
|
35
|
-
Label: string;
|
|
36
|
-
};
|
|
37
|
-
export type RetrieveAddressResponse = {
|
|
38
|
-
Items: RetrieveAddressResult[] | AddressError[];
|
|
39
|
-
};
|
|
40
|
-
export type AddressLookupConfig = {
|
|
41
|
-
apiKey: string;
|
|
42
|
-
limit?: number;
|
|
43
|
-
countries?: string[];
|
|
44
|
-
};
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
export declare const getAirbrakeEnvironment: () => string;
|
|
2
|
-
export type GetAirbrakeOptions = {
|
|
3
|
-
projectId?: number;
|
|
4
|
-
projectKey?: string;
|
|
5
|
-
forceSend?: boolean;
|
|
6
|
-
};
|
|
7
|
-
export declare function getAirbrake(options?: GetAirbrakeOptions): {
|
|
8
|
-
notify: (...data: any[]) => void;
|
|
9
|
-
};
|
|
@@ -1,61 +0,0 @@
|
|
|
1
|
-
import type { ParamsType } from "../snowplow";
|
|
2
|
-
declare const _default: ({
|
|
3
|
-
name: string;
|
|
4
|
-
type: string;
|
|
5
|
-
makePayload: (params: {
|
|
6
|
-
label: "next" | "back" | "redirect";
|
|
7
|
-
}) => {
|
|
8
|
-
category: string;
|
|
9
|
-
action: string;
|
|
10
|
-
label: "next" | "back" | "redirect";
|
|
11
|
-
property: string;
|
|
12
|
-
};
|
|
13
|
-
contexts?: undefined;
|
|
14
|
-
} | {
|
|
15
|
-
name: string;
|
|
16
|
-
type: string;
|
|
17
|
-
makePayload: (params: ParamsType) => {
|
|
18
|
-
schema: string;
|
|
19
|
-
data: {
|
|
20
|
-
site: string;
|
|
21
|
-
page_index: number;
|
|
22
|
-
page_name: string;
|
|
23
|
-
submitted_from: string;
|
|
24
|
-
section_name: string;
|
|
25
|
-
question: string;
|
|
26
|
-
answer: string;
|
|
27
|
-
vertical: string;
|
|
28
|
-
journey_id: string;
|
|
29
|
-
};
|
|
30
|
-
};
|
|
31
|
-
contexts: string[];
|
|
32
|
-
} | {
|
|
33
|
-
name: string;
|
|
34
|
-
type: string;
|
|
35
|
-
makePayload: (params: ParamsType) => {
|
|
36
|
-
schema: string;
|
|
37
|
-
data: {
|
|
38
|
-
site: string;
|
|
39
|
-
vertical: string;
|
|
40
|
-
primary_detail: string;
|
|
41
|
-
selected_type: string;
|
|
42
|
-
};
|
|
43
|
-
};
|
|
44
|
-
contexts?: undefined;
|
|
45
|
-
} | {
|
|
46
|
-
name: string;
|
|
47
|
-
type: string;
|
|
48
|
-
makePayload: (params: ParamsType) => {
|
|
49
|
-
schema: string;
|
|
50
|
-
data: {
|
|
51
|
-
vertical: string;
|
|
52
|
-
site: string;
|
|
53
|
-
help_text: string;
|
|
54
|
-
primary_text: string;
|
|
55
|
-
label: string;
|
|
56
|
-
page_name: string;
|
|
57
|
-
};
|
|
58
|
-
};
|
|
59
|
-
contexts?: undefined;
|
|
60
|
-
})[];
|
|
61
|
-
export default _default;
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
export declare const pageData: {
|
|
2
|
-
scripts: {
|
|
3
|
-
metadata: {
|
|
4
|
-
name: string;
|
|
5
|
-
};
|
|
6
|
-
props: {
|
|
7
|
-
uid: string;
|
|
8
|
-
cookieDomain: string;
|
|
9
|
-
avalancheCollector: string;
|
|
10
|
-
appId: string;
|
|
11
|
-
includeGAContext: boolean;
|
|
12
|
-
eventMethod: string;
|
|
13
|
-
postPath: string;
|
|
14
|
-
trackActivity: boolean;
|
|
15
|
-
trackPageView: boolean;
|
|
16
|
-
pageViewContext: {
|
|
17
|
-
schema: string;
|
|
18
|
-
data: {
|
|
19
|
-
site: string;
|
|
20
|
-
vertical: string;
|
|
21
|
-
superSegment: string;
|
|
22
|
-
primaryDetail: string;
|
|
23
|
-
journeyName: string;
|
|
24
|
-
journeyId: string;
|
|
25
|
-
pageStepName: string;
|
|
26
|
-
pageStepDepth: number;
|
|
27
|
-
};
|
|
28
|
-
};
|
|
29
|
-
distributionChannelContext: {
|
|
30
|
-
schema: string;
|
|
31
|
-
data: {
|
|
32
|
-
service_channel_identifier: string;
|
|
33
|
-
};
|
|
34
|
-
};
|
|
35
|
-
serviceChannelContext: {
|
|
36
|
-
schema: string;
|
|
37
|
-
data: {
|
|
38
|
-
service_channel_identifier: string;
|
|
39
|
-
};
|
|
40
|
-
};
|
|
41
|
-
forceSecureTracker: boolean;
|
|
42
|
-
};
|
|
43
|
-
}[];
|
|
44
|
-
};
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
import type { PageViewEvent, StructuredEvent } from "@snowplow/browser-tracker";
|
|
2
|
-
import type { EventDefinition, SerialisedEvent, TrackingProps } from "./types";
|
|
3
|
-
export type FrontOfficeStructuredEvent = StructuredEvent & {
|
|
4
|
-
serviceChannelIdentifier: string;
|
|
5
|
-
};
|
|
6
|
-
/**
|
|
7
|
-
* This class is an abstraction which wraps Snowplow
|
|
8
|
-
* and exposes common methods with other services:
|
|
9
|
-
* - trackEvent : sends a standard payload
|
|
10
|
-
* - trackUnstructEvent : sends a payload for custom schema
|
|
11
|
-
*/
|
|
12
|
-
export declare class Snowplow {
|
|
13
|
-
avalancheTrackerName: string;
|
|
14
|
-
bronzeAvalancheTrackerName: string;
|
|
15
|
-
pvAvalancheTrackerName: string;
|
|
16
|
-
uid: unknown;
|
|
17
|
-
trackPageView: boolean;
|
|
18
|
-
contexts: Record<string, SerialisedEvent>;
|
|
19
|
-
pvContext: SerialisedEvent[];
|
|
20
|
-
structContext: SerialisedEvent[];
|
|
21
|
-
serverData: Record<string, unknown>;
|
|
22
|
-
eventHandlers: Record<string, (params?: Record<string, unknown>) => void>;
|
|
23
|
-
static instance: Snowplow | undefined;
|
|
24
|
-
constructor(props?: TrackingProps);
|
|
25
|
-
setContexts(contexts: Record<string, SerialisedEvent>): this;
|
|
26
|
-
trackView(event?: PageViewEvent): this;
|
|
27
|
-
trackEvent(event: StructuredEvent): this;
|
|
28
|
-
trackUnstructEvent(event: SerialisedEvent, contexts?: string[]): this;
|
|
29
|
-
addEventHandlers(eventDefinitions: EventDefinition[]): this;
|
|
30
|
-
private addEventHandler;
|
|
31
|
-
private removeEventHandler;
|
|
32
|
-
trigger(name: string, params?: Record<string, unknown>): this;
|
|
33
|
-
static getInstance(props?: TrackingProps): Snowplow;
|
|
34
|
-
}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { type ReactNode } from "react";
|
|
2
|
-
import { Snowplow } from "./Snowplow";
|
|
3
|
-
import type { TrackingProps } from "./types";
|
|
4
|
-
export interface SnowplowContextInterface {
|
|
5
|
-
config: TrackingProps;
|
|
6
|
-
snowplow?: Snowplow;
|
|
7
|
-
}
|
|
8
|
-
type ProviderProps = {
|
|
9
|
-
scripts: TrackingProps;
|
|
10
|
-
children: ReactNode;
|
|
11
|
-
};
|
|
12
|
-
export declare const SnowplowProvider: ({ scripts, children }: ProviderProps) => import("react/jsx-runtime").JSX.Element;
|
|
13
|
-
export declare function useSnowplowContext(): SnowplowContextInterface;
|
|
14
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const DELIMITER = "|";
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import type { SerialisedEvent, TrackingProps } from "./types";
|
|
2
|
-
export declare const getContexts: (config: TrackingProps) => Record<string, SerialisedEvent>;
|
|
3
|
-
export declare const updateIdentityContext: (contexts: Record<string, SerialisedEvent>, uid: unknown) => Record<string, SerialisedEvent>;
|
|
4
|
-
export declare const makeContexts: (keys: string[], config: Record<string, SerialisedEvent>) => SerialisedEvent[];
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import type { EventDefinition } from "../types";
|
|
2
|
-
/**
|
|
3
|
-
* Event definitions for Snowplow
|
|
4
|
-
* @type {EventDefinition[]}
|
|
5
|
-
* @property {string} name - The name of the event, to use when triggering
|
|
6
|
-
* @property {string} type - The type of the event (structured | unstructured)
|
|
7
|
-
* @property {makePayload} makePayload
|
|
8
|
-
* - Function that creates the payload for the event;
|
|
9
|
-
* - Allows optional params object to be passed in
|
|
10
|
-
*
|
|
11
|
-
* @example
|
|
12
|
-
* Parent
|
|
13
|
-
* import { getSnowplowConfig, SnowplowProvider } from "@simplybusiness/services";
|
|
14
|
-
* const snowplowProps = getSnowplowConfig(pageData);
|
|
15
|
-
* <SnowplowProvider scripts={snowplowProps!}>{children}</SnowplowProvider>
|
|
16
|
-
*
|
|
17
|
-
* Child
|
|
18
|
-
* import { useSnowplowContext } from "@simplybusiness/services";
|
|
19
|
-
* const { snowplow } = useSnowplowContext();
|
|
20
|
-
* const handlerFunction = () => snowplow?.trigger("eventNameHere");
|
|
21
|
-
*/
|
|
22
|
-
export declare const baseEventDefinitions: EventDefinition[];
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
export declare const eventDefinitions: import("..").EventDefinition[];
|
|
2
|
-
export declare const qcpPageEvents: import("..").EventDefinition[];
|
|
3
|
-
export declare const referralPageEvents: import("..").EventDefinition[];
|
|
4
|
-
export declare const personalisedCoverPageEvents: import("..").EventDefinition[];
|
|
5
|
-
export declare const interventionPageEvents: import("..").EventDefinition[];
|
|
6
|
-
export type { InterventionPayload } from "./intervention";
|
|
7
|
-
export declare const questionnairePageEvents: import("..").EventDefinition[];
|
|
8
|
-
export declare const coverageSelectionPageEvents: import("..").EventDefinition[];
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import type { EventDefinition } from "../types";
|
|
2
|
-
type InterventionIdTypes = "duid";
|
|
3
|
-
export type InterventionPayload = {
|
|
4
|
-
interventionId: string;
|
|
5
|
-
interventionName: string;
|
|
6
|
-
userUniqueIdentifier: string;
|
|
7
|
-
userUniqueIdentifierType: InterventionIdTypes;
|
|
8
|
-
action: string;
|
|
9
|
-
site?: string;
|
|
10
|
-
};
|
|
11
|
-
export declare const interventionEventDefinitions: EventDefinition[];
|
|
12
|
-
export {};
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import type { EventDefinition } from "../types";
|
|
2
|
-
/**
|
|
3
|
-
* Event definitions for Snowplow
|
|
4
|
-
* @type {EventDefinition[]}
|
|
5
|
-
* @property {string} name - The name of the event, to use when triggering
|
|
6
|
-
* @property {string} type - The type of the event (structured | unstructured)
|
|
7
|
-
* @property {makePayload} makePayload
|
|
8
|
-
* - Function that creates the payload for the event;
|
|
9
|
-
* - Allows optional params object to be passed in
|
|
10
|
-
*
|
|
11
|
-
* @example
|
|
12
|
-
* Parent
|
|
13
|
-
* import { getSnowplowConfig, SnowplowProvider } from "@simplybusiness/services";
|
|
14
|
-
* const snowplowProps = getSnowplowConfig(pageData);
|
|
15
|
-
* <SnowplowProvider scripts={snowplowProps!}>{children}</SnowplowProvider>
|
|
16
|
-
*
|
|
17
|
-
* Child
|
|
18
|
-
* import { useSnowplowContext } from "@simplybusiness/services";
|
|
19
|
-
* const { snowplow } = useSnowplowContext();
|
|
20
|
-
* const handlerFunction = () => snowplow?.trigger("eventNameHere");
|
|
21
|
-
*/
|
|
22
|
-
export declare const personalisedCoverEventDefinitions: EventDefinition[];
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
import type { EventMethod, SelfDescribingJson, StructuredEvent } from "@snowplow/browser-tracker";
|
|
2
|
-
type BaseConfig = {
|
|
3
|
-
appId: string;
|
|
4
|
-
avalancheCollector: string;
|
|
5
|
-
eventMethod: EventMethod;
|
|
6
|
-
trackPageView: boolean;
|
|
7
|
-
includeGAContext: boolean;
|
|
8
|
-
duid?: string;
|
|
9
|
-
uid?: string;
|
|
10
|
-
postPath?: string;
|
|
11
|
-
};
|
|
12
|
-
export type EnvConfig = BaseConfig & {
|
|
13
|
-
cookieDomain: Record<string, string>;
|
|
14
|
-
};
|
|
15
|
-
export type TrackingProps = BaseConfig & {
|
|
16
|
-
eventMethod: EventMethod;
|
|
17
|
-
cookieDomain?: string;
|
|
18
|
-
pageViewContext?: ChannelContext;
|
|
19
|
-
};
|
|
20
|
-
export type ChannelContext = {
|
|
21
|
-
schema: string;
|
|
22
|
-
data: Record<string, string | number>;
|
|
23
|
-
};
|
|
24
|
-
export type ChannelContexts = Record<string, ChannelContext>;
|
|
25
|
-
export type ArrayOneOrMore<T> = [T, ...T[]];
|
|
26
|
-
export type ParamsType = Record<string, string> & {
|
|
27
|
-
context: ServerContext;
|
|
28
|
-
};
|
|
29
|
-
type ServerContext = {
|
|
30
|
-
site: string;
|
|
31
|
-
vertical: string;
|
|
32
|
-
primaryDetail: string;
|
|
33
|
-
journeyName: string;
|
|
34
|
-
journeyId: string;
|
|
35
|
-
};
|
|
36
|
-
export type LinkType = Record<string, string> & {
|
|
37
|
-
targetUrl: string;
|
|
38
|
-
elementContent: string;
|
|
39
|
-
};
|
|
40
|
-
export type SerialisedEvent = SelfDescribingJson<Record<string, unknown>>;
|
|
41
|
-
export type EventDefinition = {
|
|
42
|
-
name: string;
|
|
43
|
-
type: "structured" | "unstructured";
|
|
44
|
-
makePayload: (params?: Record<string, unknown>) => StructuredEvent | SerialisedEvent;
|
|
45
|
-
contexts?: string[];
|
|
46
|
-
};
|
|
47
|
-
export interface PageDataProps extends Partial<Record<"scripts", Array<{
|
|
48
|
-
metadata: {
|
|
49
|
-
name: string;
|
|
50
|
-
};
|
|
51
|
-
props?: Record<string, unknown>;
|
|
52
|
-
}>>> {
|
|
53
|
-
}
|
|
54
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function isObject(value: unknown): value is Record<string, unknown>;
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import type { RenderOptions } from "@testing-library/react";
|
|
2
|
-
import type { ReactElement } from "react";
|
|
3
|
-
export declare const renderWithProviders: (ui: ReactElement, options?: RenderOptions) => import("@testing-library/react").RenderResult<typeof import("@testing-library/dom/types/queries"), HTMLElement, HTMLElement>;
|
|
4
|
-
export declare const mockLocation: ({ origin, pathname, }: {
|
|
5
|
-
origin?: string;
|
|
6
|
-
pathname?: string;
|
|
7
|
-
}) => Window & typeof globalThis;
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
export interface TrackingHandler {
|
|
2
|
-
event: string;
|
|
3
|
-
action: () => void;
|
|
4
|
-
onInit?: () => boolean;
|
|
5
|
-
trigger?: Element | Window;
|
|
6
|
-
}
|
|
7
|
-
export interface TrackingHelperOptions {
|
|
8
|
-
onInit?: () => boolean;
|
|
9
|
-
trigger?: Element | Window;
|
|
10
|
-
}
|
|
11
|
-
export declare class TrackingHelper {
|
|
12
|
-
private handlers;
|
|
13
|
-
register(event: string, action: () => void, opts?: TrackingHelperOptions): void;
|
|
14
|
-
attach(): void;
|
|
15
|
-
}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
export interface TrackingHandler {
|
|
2
|
-
event: string;
|
|
3
|
-
action: () => void;
|
|
4
|
-
onInit?: () => boolean;
|
|
5
|
-
trigger?: Element | Window;
|
|
6
|
-
}
|
|
7
|
-
export interface TrackingHelperOptions {
|
|
8
|
-
onInit?: () => boolean;
|
|
9
|
-
trigger?: Element | Window;
|
|
10
|
-
}
|
|
11
|
-
export declare class TrackingHelper {
|
|
12
|
-
private handlers;
|
|
13
|
-
register(event: string, action: () => void, opts?: TrackingHelperOptions): void;
|
|
14
|
-
attach(): void;
|
|
15
|
-
}
|
package/dist/types/types.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const StoryContainer: (props: Record<string, unknown>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
export interface TrackingHandler {
|
|
2
|
-
event: string;
|
|
3
|
-
action: () => void;
|
|
4
|
-
onInit?: () => boolean;
|
|
5
|
-
trigger?: Element | Window;
|
|
6
|
-
}
|
|
7
|
-
export interface TrackingHelperOptions {
|
|
8
|
-
onInit?: () => boolean;
|
|
9
|
-
trigger?: Element | Window;
|
|
10
|
-
}
|
|
11
|
-
export declare class TrackingHelper {
|
|
12
|
-
private handlers;
|
|
13
|
-
register(event: string, action: () => void, opts?: TrackingHelperOptions): void;
|
|
14
|
-
attach(): void;
|
|
15
|
-
}
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
export declare const getEnvironment: () => string;
|
|
2
|
-
export declare const isTestEnv: () => boolean;
|
|
3
|
-
export declare const hasRailsEnv: () => boolean;
|
|
4
|
-
export declare const isHosted: (host?: string) => boolean;
|
|
5
|
-
export declare const urlIncludes: (text: string, mockOrigin?: string) => boolean;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const excludeControls: (...args: string[]) => {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function spaceDelimitedList(list: (string | null | undefined)[]): string | undefined;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|