@visitscotland/component-library 1.2.1 → 1.2.2
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 +15 -8
- package/dist/client/manifest.json +2 -2
- package/dist/client/styles/9e00186f935145b10cee.css +6 -0
- package/dist/components/brandscotland-logo-CFk2vaAQ.mjs +4 -0
- package/dist/components/close-circle-filled-BBjsY4Zb.mjs +21 -0
- package/dist/components/component-entry.d.ts +3 -0
- package/dist/components/components/accordion/Accordion.vue.d.ts +24 -0
- package/dist/components/components/accordion/components/AccordionItem.vue.d.ts +94 -0
- package/dist/components/components/accordion/components/AccordionToggle.vue.d.ts +39 -0
- package/dist/components/components/accordion/index.d.ts +103 -0
- package/dist/components/components/address/Address.vue.d.ts +2 -0
- package/dist/components/components/address/index.d.ts +5 -0
- package/dist/components/components/alert/Alert.vue.d.ts +2 -0
- package/dist/components/components/alert/index.d.ts +5 -0
- package/dist/components/components/article/Article.vue.d.ts +34 -0
- package/dist/components/components/article/components/ArticleSection.vue.d.ts +24 -0
- package/dist/components/components/article/components/ArticleSidebar.vue.d.ts +24 -0
- package/dist/components/components/article/index.d.ts +9 -0
- package/dist/components/components/banner/Banner.vue.d.ts +55 -0
- package/dist/components/components/banner/index.d.ts +2 -0
- package/dist/components/components/blog-details/BlogDetails.vue.d.ts +46 -0
- package/dist/components/components/blog-details/index.d.ts +2 -0
- package/dist/components/components/breadcrumb/Breadcrumb.vue.d.ts +2 -0
- package/dist/components/components/breadcrumb/components/BreadcrumbItem.vue.d.ts +67 -0
- package/dist/components/components/breadcrumb/index.d.ts +3 -0
- package/dist/components/components/button/Button.vue.d.ts +244 -0
- package/dist/components/components/button/index.d.ts +2 -0
- package/dist/components/components/button-toggle-group/ButtonToggleGroup.vue.d.ts +68 -0
- package/dist/components/components/button-toggle-group/index.d.ts +2 -0
- package/dist/components/components/canned-search/CannedSearch.vue.d.ts +135 -0
- package/dist/components/components/canned-search/components/CannedSearchBadges.vue.d.ts +76 -0
- package/dist/components/components/canned-search/components/CannedSearchCategories.vue.d.ts +28 -0
- package/dist/components/components/canned-search/components/CannedSearchCuisines.vue.d.ts +22 -0
- package/dist/components/components/canned-search/components/CannedSearchDates.vue.d.ts +41 -0
- package/dist/components/components/canned-search/components/CannedSearchDuration.vue.d.ts +35 -0
- package/dist/components/components/canned-search/components/CannedSearchLogos.vue.d.ts +73 -0
- package/dist/components/components/canned-search/components/CannedSearchPrice.vue.d.ts +50 -0
- package/dist/components/components/canned-search/components/CannedSearchProductCard.vue.d.ts +141 -0
- package/dist/components/components/canned-search/components/CannedSearchStars.vue.d.ts +56 -0
- package/dist/components/components/canned-search/components/CannedSearchSubHeading.vue.d.ts +43 -0
- package/dist/components/components/canned-search/components/CannedSearchSummaryBox.vue.d.ts +67 -0
- package/dist/components/components/canned-search/components/CannedSearchTourDeparts.vue.d.ts +43 -0
- package/dist/components/components/canned-search/components/CannedSearchTourRuns.vue.d.ts +59 -0
- package/dist/components/components/canned-search/index.d.ts +27 -0
- package/dist/components/components/caption/Caption.vue.d.ts +82 -0
- package/dist/components/components/caption/components/CaptionImageMap.vue.d.ts +67 -0
- package/dist/components/components/caption/index.d.ts +7 -0
- package/dist/components/components/carbon-calculator/CarbonCalculator.vue.d.ts +242 -0
- package/dist/components/components/carbon-calculator/components/CarbonCalculatorIntro.vue.d.ts +2 -0
- package/dist/components/components/carbon-calculator/components/CarbonCalculatorQuestion.vue.d.ts +151 -0
- package/dist/components/components/carbon-calculator/components/CarbonCalculatorResults.vue.d.ts +183 -0
- package/dist/components/components/carbon-calculator/components/CarbonCalculatorRunningTotal.vue.d.ts +45 -0
- package/dist/components/components/carbon-calculator/components/CarbonCalculatorTip.vue.d.ts +23 -0
- package/dist/components/components/carbon-calculator/index.d.ts +5 -0
- package/dist/components/components/carousel/Carousel.vue.d.ts +134 -0
- package/dist/components/components/carousel/components/CarouselSlide.vue.d.ts +176 -0
- package/dist/components/components/carousel/index.d.ts +7 -0
- package/dist/components/components/checkbox/Checkbox.vue.d.ts +218 -0
- package/dist/components/components/checkbox/index.d.ts +2 -0
- package/dist/components/components/cookie-checker/index.d.ts +2 -0
- package/dist/components/components/cookie-fallback/CookiesFallback.vue.d.ts +14 -0
- package/dist/components/components/cookie-fallback/index.d.ts +5 -0
- package/dist/components/components/description-list/DescriptionList.vue.d.ts +20 -0
- package/dist/components/components/description-list/components/DescriptionListItem.vue.d.ts +20 -0
- package/dist/components/components/description-list/index.d.ts +3 -0
- package/dist/components/components/dropdown/Dropdown.vue.d.ts +16 -0
- package/dist/components/components/dropdown/components/DropdownItem.vue.d.ts +2 -0
- package/dist/components/components/dropdown/index.d.ts +3 -0
- package/dist/components/components/embed-wrapper/EmbedWrapper.vue.d.ts +78 -0
- package/dist/components/components/embed-wrapper/index.d.ts +5 -0
- package/dist/components/components/footer/Footer.vue.d.ts +2 -0
- package/dist/components/components/footer/components/FooterAccordionItem.vue.d.ts +84 -0
- package/dist/components/components/footer/components/FooterCopyright.vue.d.ts +36 -0
- package/dist/components/components/footer/components/FooterNavList.vue.d.ts +24 -0
- package/dist/components/components/footer/components/FooterNavListItem.vue.d.ts +54 -0
- package/dist/components/components/footer/components/FooterSocialItem.vue.d.ts +53 -0
- package/dist/components/components/footer/components/FooterSocialMenu.vue.d.ts +2 -0
- package/dist/components/components/footer/components/FooterUtilityList.vue.d.ts +2 -0
- package/dist/components/components/footer/index.d.ts +19 -0
- package/dist/components/components/global-menu/GlobalMenu.vue.d.ts +39 -0
- package/dist/components/components/global-menu/components/GlobalMenuDropdown.vue.d.ts +48 -0
- package/dist/components/components/global-menu/components/GlobalMenuLanguage.vue.d.ts +49 -0
- package/dist/components/components/global-menu/components/GlobalMenuLanguageItem.vue.d.ts +66 -0
- package/dist/components/components/global-menu/components/GlobalMenuList.vue.d.ts +32 -0
- package/dist/components/components/global-menu/index.d.ts +13 -0
- package/dist/components/components/grid/Col.vue.d.ts +2 -0
- package/dist/components/components/grid/Container.vue.d.ts +2 -0
- package/dist/components/components/grid/Row.vue.d.ts +2 -0
- package/dist/components/components/grid/index.d.ts +4 -0
- package/dist/components/components/heading/Heading.vue.d.ts +78 -0
- package/dist/components/components/heading/index.d.ts +2 -0
- package/dist/components/components/html-error/HtmlError.vue.d.ts +35 -0
- package/dist/components/components/html-error/index.d.ts +5 -0
- package/dist/components/components/icentre/Icentre.vue.d.ts +2 -0
- package/dist/components/components/icentre/index.d.ts +5 -0
- package/dist/components/components/icon/Icon.vue.d.ts +128 -0
- package/dist/components/components/icon/index.d.ts +80 -0
- package/dist/components/components/icon-list/IconList.vue.d.ts +20 -0
- package/dist/components/components/icon-list/components/IconListItem.vue.d.ts +32 -0
- package/dist/components/components/icon-list/index.d.ts +7 -0
- package/dist/components/components/image-with-caption/ImageWithCaption.vue.d.ts +276 -0
- package/dist/components/components/image-with-caption/index.d.ts +5 -0
- package/dist/components/components/img/Img.vue.d.ts +121 -0
- package/dist/components/components/img/index.d.ts +2 -0
- package/dist/components/components/index.d.ts +118 -0
- package/dist/components/components/input/Input.vue.d.ts +297 -0
- package/dist/components/components/input/index.d.ts +2 -0
- package/dist/components/components/itineraries/Itinerary.vue.d.ts +43 -0
- package/dist/components/components/itineraries/components/ItineraryDay.vue.d.ts +66 -0
- package/dist/components/components/itineraries/components/ItineraryStop.vue.d.ts +46 -0
- package/dist/components/components/itineraries/components/ItineraryStopInfo.vue.d.ts +175 -0
- package/dist/components/components/itineraries/components/ItineraryTips.vue.d.ts +8 -0
- package/dist/components/components/itineraries/index.d.ts +7 -0
- package/dist/components/components/itineraries/itineraries.store.d.ts +30 -0
- package/dist/components/components/link/Link.vue.d.ts +133 -0
- package/dist/components/components/link/index.d.ts +5 -0
- package/dist/components/components/link-list/LinkList.vue.d.ts +2 -0
- package/dist/components/components/link-list/components/LinkListItem.vue.d.ts +96 -0
- package/dist/components/components/link-list/index.d.ts +7 -0
- package/dist/components/components/list/List.vue.d.ts +50 -0
- package/dist/components/components/list/index.d.ts +2 -0
- package/dist/components/components/listicle/ListicleItem.vue.d.ts +52 -0
- package/dist/components/components/listicle/index.d.ts +5 -0
- package/dist/components/components/loading-spinner/LoadingSpinner.vue.d.ts +18 -0
- package/dist/components/components/loading-spinner/index.d.ts +5 -0
- package/dist/components/components/map/Map.vue.d.ts +370 -0
- package/dist/components/components/map/components/MapMarker.vue.d.ts +87 -0
- package/dist/components/components/map/index.d.ts +7 -0
- package/dist/components/components/map-marker-icon/MapMarkerIcon.vue.d.ts +50 -0
- package/dist/components/components/map-marker-icon/index.d.ts +5 -0
- package/dist/components/components/map-with-sidebar/MapWithSidebar.vue.d.ts +365 -0
- package/dist/components/components/map-with-sidebar/components/MapWithSidebarButtons.vue.d.ts +39 -0
- package/dist/components/components/map-with-sidebar/components/MapWithSidebarCategory.vue.d.ts +57 -0
- package/dist/components/components/map-with-sidebar/components/MapWithSidebarControls.vue.d.ts +16 -0
- package/dist/components/components/map-with-sidebar/components/MapWithSidebarDetail.vue.d.ts +36 -0
- package/dist/components/components/map-with-sidebar/components/MapWithSidebarListItem.vue.d.ts +65 -0
- package/dist/components/components/map-with-sidebar/components/MapWithSidebarPanel.vue.d.ts +274 -0
- package/dist/components/components/map-with-sidebar/components/MapWithSidebarSubcategory.vue.d.ts +35 -0
- package/dist/components/components/map-with-sidebar/index.d.ts +19 -0
- package/dist/components/components/marketo-form/MarketoForm.vue.d.ts +284 -0
- package/dist/components/components/marketo-form/index.d.ts +5 -0
- package/dist/components/components/mega-nav/MegaNav.vue.d.ts +151 -0
- package/dist/components/components/mega-nav/components/MegaNavAccordionItem.vue.d.ts +84 -0
- package/dist/components/components/mega-nav/components/MegaNavDropdown.vue.d.ts +44 -0
- package/dist/components/components/mega-nav/components/MegaNavFeaturedEvent.vue.d.ts +29 -0
- package/dist/components/components/mega-nav/components/MegaNavFeaturedItem.vue.d.ts +48 -0
- package/dist/components/components/mega-nav/components/MegaNavList.vue.d.ts +22 -0
- package/dist/components/components/mega-nav/components/MegaNavListItem.vue.d.ts +74 -0
- package/dist/components/components/mega-nav/components/MegaNavMobileMenu.vue.d.ts +24 -0
- package/dist/components/components/mega-nav/components/MegaNavTopMenu.vue.d.ts +2 -0
- package/dist/components/components/mega-nav/components/MegaNavTopMenuItem.vue.d.ts +57 -0
- package/dist/components/components/megalinks/Megalinks.vue.d.ts +126 -0
- package/dist/components/components/megalinks/components/megalink-link-list/MegalinkLinkList.vue.d.ts +194 -0
- package/dist/components/components/megalinks/components/megalink-link-list/index.d.ts +5 -0
- package/dist/components/components/megalinks/components/megalink-multi-image/MegalinkMultiImage.vue.d.ts +233 -0
- package/dist/components/components/megalinks/components/megalink-multi-image/index.d.ts +5 -0
- package/dist/components/components/megalinks/components/megalink-single-image/MegalinkSingleImage.vue.d.ts +76 -0
- package/dist/components/components/megalinks/components/megalink-single-image/index.d.ts +5 -0
- package/dist/components/components/megalinks/index.d.ts +5 -0
- package/dist/components/components/modal/Modal.vue.d.ts +82 -0
- package/dist/components/components/modal/index.d.ts +2 -0
- package/dist/components/components/module-wrapper/ModuleWrapper.vue.d.ts +22 -0
- package/dist/components/components/module-wrapper/index.d.ts +5 -0
- package/dist/components/components/number-input/NumberInput.vue.d.ts +294 -0
- package/dist/components/components/number-input/index.d.ts +2 -0
- package/dist/components/components/page-intro/PageIntro.vue.d.ts +60 -0
- package/dist/components/components/page-intro/index.d.ts +2 -0
- package/dist/components/components/panel/Panel.vue.d.ts +2 -0
- package/dist/components/components/panel/index.d.ts +2 -0
- package/dist/components/components/product-search/ProductSearch.vue.d.ts +64 -0
- package/dist/components/components/product-search/components/Autocomplete.vue.d.ts +37 -0
- package/dist/components/components/product-search/components/DateInput.vue.d.ts +27 -0
- package/dist/components/components/product-search/components/DateRange.vue.d.ts +48 -0
- package/dist/components/components/product-search/components/GuestSelector.vue.d.ts +15 -0
- package/dist/components/components/product-search/components/GuestSelectorNumberGroup.vue.d.ts +44 -0
- package/dist/components/components/product-search/components/GuestSelectorRow.vue.d.ts +30 -0
- package/dist/components/components/product-search/components/ProductSearchEmbed.vue.d.ts +55 -0
- package/dist/components/components/product-search/index.d.ts +2 -0
- package/dist/components/components/progress-bar/ProgressBar.vue.d.ts +96 -0
- package/dist/components/components/progress-bar/index.d.ts +5 -0
- package/dist/components/components/quote/Quote.vue.d.ts +21 -0
- package/dist/components/components/quote/index.d.ts +23 -0
- package/dist/components/components/radio-button/RadioButton.vue.d.ts +233 -0
- package/dist/components/components/recaptcha/Recaptcha.vue.d.ts +111 -0
- package/dist/components/components/recaptcha/index.d.ts +5 -0
- package/dist/components/components/rich-text-wrapper/RichTextWrapper.vue.d.ts +24 -0
- package/dist/components/components/rich-text-wrapper/index.d.ts +5 -0
- package/dist/components/components/select/Select.vue.d.ts +213 -0
- package/dist/components/components/select/index.d.ts +2 -0
- package/dist/components/components/site-search/SiteSearch.vue.d.ts +27 -0
- package/dist/components/components/site-search/components/SiteSearchForm.vue.d.ts +100 -0
- package/dist/components/components/site-search/index.d.ts +7 -0
- package/dist/components/components/ski-scotland/ski-scotland-card/SkiScotlandCard.vue.d.ts +336 -0
- package/dist/components/components/ski-scotland/ski-scotland-card/index.d.ts +5 -0
- package/dist/components/components/ski-scotland/ski-scotland-status/SkiScotlandStatus.vue.d.ts +677 -0
- package/dist/components/components/ski-scotland/ski-scotland-status/index.d.ts +5 -0
- package/dist/components/components/skip-to/SkipTo.vue.d.ts +28 -0
- package/dist/components/components/skip-to/index.d.ts +5 -0
- package/dist/components/components/social-credit-link/SocialCreditLink.vue.d.ts +50 -0
- package/dist/components/components/social-credit-link/index.d.ts +5 -0
- package/dist/components/components/social-share/SocialShare.vue.d.ts +141 -0
- package/dist/components/components/social-share/components/SocialShareItem.vue.d.ts +76 -0
- package/dist/components/components/social-share/index.d.ts +7 -0
- package/dist/components/components/stretched-link-card/StretchedLinkCard.vue.d.ts +220 -0
- package/dist/components/components/stretched-link-card/components/StretchedLinkPanels.vue.d.ts +67 -0
- package/dist/components/components/stretched-link-card/index.d.ts +6 -0
- package/dist/components/components/summary-box/SummaryBoxList.vue.d.ts +2 -0
- package/dist/components/components/summary-box/components/SummaryBoxDistanceListItem.vue.d.ts +99 -0
- package/dist/components/components/summary-box/components/SummaryBoxListItem.vue.d.ts +67 -0
- package/dist/components/components/summary-box/index.d.ts +4 -0
- package/dist/components/components/svg/Svg.vue.d.ts +75 -0
- package/dist/components/components/svg/index.d.ts +5 -0
- package/dist/components/components/svg-link/SvgLink.vue.d.ts +126 -0
- package/dist/components/components/svg-link/index.d.ts +5 -0
- package/dist/components/components/table/Table.vue.d.ts +41 -0
- package/dist/components/components/table/components/TableBody.vue.d.ts +2 -0
- package/dist/components/components/table/components/TableDataCell.vue.d.ts +20 -0
- package/dist/components/components/table/components/TableFooter.vue.d.ts +2 -0
- package/dist/components/components/table/components/TableHead.vue.d.ts +2 -0
- package/dist/components/components/table/components/TableHeaderCell.vue.d.ts +20 -0
- package/dist/components/components/table/components/TableRow.vue.d.ts +2 -0
- package/dist/components/components/table/index.d.ts +8 -0
- package/dist/components/components/tabs/Tabs.vue.d.ts +2 -0
- package/dist/components/components/tabs/components/TabItem.vue.d.ts +18 -0
- package/dist/components/components/tabs/index.d.ts +9 -0
- package/dist/components/components/tag/Tag.vue.d.ts +18 -0
- package/dist/components/components/tag/index.d.ts +5 -0
- package/dist/components/components/tag-manager-wrapper/TagManagerWrapper.vue.d.ts +48 -0
- package/dist/components/components/tag-manager-wrapper/index.d.ts +2 -0
- package/dist/components/components/toggle-button/ToggleButton.vue.d.ts +24 -0
- package/dist/components/components/toggle-button/index.d.ts +5 -0
- package/dist/components/components/tooltip/Tooltip.vue.d.ts +39 -0
- package/dist/components/components/tooltip/index.d.ts +2 -0
- package/dist/components/components/video/Video.vue.d.ts +264 -0
- package/dist/components/components/video-caption/VideoCaption.vue.d.ts +95 -0
- package/dist/components/components/video-caption/index.d.ts +5 -0
- package/dist/components/components/warning/Warning.vue.d.ts +115 -0
- package/dist/components/components/warning/index.d.ts +5 -0
- package/dist/components/constants.d.ts +13 -0
- package/dist/components/cookie-coo-BpVlZYES.mjs +4 -0
- package/dist/components/deprecated-SV4OJNeR.mjs +16 -0
- package/dist/components/directives/click-outside.d.ts +5 -0
- package/dist/components/directives/hand-down-focus.d.ts +7 -0
- package/dist/components/highland-cow-6AoCzBpF.mjs +18 -0
- package/dist/components/iCentre-BLimkPxI.mjs +46 -0
- package/dist/components/information-filled-CZjvtLmT.mjs +4 -0
- package/dist/components/instagram-filled-CGGEG-Rb.mjs +4 -0
- package/dist/components/mixins/__mocks__/verifyCookiesMixin.d.ts +13 -0
- package/dist/components/mixins/ariaDescriptionMixin.d.ts +6 -0
- package/dist/components/mixins/cookieMixin.d.ts +12 -0
- package/dist/components/mixins/dataLayerMixin.d.ts +19 -0
- package/dist/components/mixins/mapIconMapping.d.ts +8 -0
- package/dist/components/mixins/srcSetMixin.d.ts +9 -0
- package/dist/components/mixins/validateFormElementMixin.d.ts +37 -0
- package/dist/components/mixins/verifyCookiesMixin.d.ts +13 -0
- package/dist/components/no-js-coo-BgxQI1Or.mjs +4 -0
- package/dist/components/os-logo-maps-DUN8X-lQ.mjs +13 -0
- package/dist/components/os-logo-maps-white-SKYtuD6d.mjs +10 -0
- package/dist/components/prototype-lvwJzV8T.mjs +16 -0
- package/dist/components/ready-CWPx4e9A.mjs +15 -0
- package/dist/components/review-CknihZl_.mjs +15 -0
- package/dist/components/stores/cookies.store.d.ts +18 -0
- package/dist/components/stores/dataLayer.store.d.ts +31 -0
- package/dist/components/stores/index.d.ts +3 -0
- package/dist/components/stores/map.store.d.ts +48 -0
- package/dist/components/stores/video.store.d.ts +21 -0
- package/dist/components/style.css +5 -0
- package/dist/components/types/types.d.ts +33 -0
- package/dist/components/utils/axios.d.ts +1 -0
- package/dist/components/utils/breakpoints.d.ts +2 -0
- package/dist/components/utils/check-vendor-library.d.ts +2 -0
- package/dist/components/utils/data-layer-templates.d.ts +17 -0
- package/dist/components/utils/event-bus.d.ts +15 -0
- package/dist/components/utils/get-env-value.d.ts +2 -0
- package/dist/components/utils/get-token.d.ts +2 -0
- package/dist/components/utils/hash-code.d.ts +2 -0
- package/dist/components/utils/js-is-disabled.d.ts +2 -0
- package/dist/components/utils/lang.d.ts +8 -0
- package/dist/components/utils/one-trust.d.ts +11 -0
- package/dist/components/utils/os-branding.d.ts +14 -0
- package/dist/components/utils/required-cookies-data.d.ts +8 -0
- package/dist/components/utils/svg-context.d.ts +2 -0
- package/dist/components/utils/utils.d.ts +10 -0
- package/dist/components/visitscotland-logo-B2aRxuQk.mjs +7 -0
- package/dist/components/vs-component-library.mjs +61269 -0
- package/dist/components/vs-component-library.umd.js +1010 -0
- package/dist/ssr/manifest.json +1 -1
- package/dist/ssr/styles/{072fe569c704008153e5.css → 6d8721bee71bcca76bf1.css} +1 -1
- package/package.json +1 -1
- package/dist/client/styles/daf570a405772cd396ad.css +0 -6
- /package/dist/client/scripts/{daf570a405772cd396ad.js → 9e00186f935145b10cee.js} +0 -0
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{
|
|
2
|
+
/**
|
|
3
|
+
* The image latitude
|
|
4
|
+
*/
|
|
5
|
+
latitude: {
|
|
6
|
+
type: StringConstructor;
|
|
7
|
+
default: string;
|
|
8
|
+
};
|
|
9
|
+
/**
|
|
10
|
+
* The image longitude
|
|
11
|
+
*/
|
|
12
|
+
longitude: {
|
|
13
|
+
type: StringConstructor;
|
|
14
|
+
default: string;
|
|
15
|
+
};
|
|
16
|
+
mapOutlineColor: {
|
|
17
|
+
type: StringConstructor;
|
|
18
|
+
default: string;
|
|
19
|
+
};
|
|
20
|
+
mapMarkerColor: {
|
|
21
|
+
type: StringConstructor;
|
|
22
|
+
default: string;
|
|
23
|
+
};
|
|
24
|
+
}, any, {
|
|
25
|
+
cornerCoordinates: {
|
|
26
|
+
NE: number;
|
|
27
|
+
NW: number;
|
|
28
|
+
SE: number;
|
|
29
|
+
SW: number;
|
|
30
|
+
};
|
|
31
|
+
mapWidth: number;
|
|
32
|
+
mapHeight: number;
|
|
33
|
+
}, {
|
|
34
|
+
positionY(): number;
|
|
35
|
+
positionX(): number;
|
|
36
|
+
}, {
|
|
37
|
+
calculateAxisPosition(scaleStart: any, scaleEnd: any, coord: any, axisLength: any): number;
|
|
38
|
+
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
39
|
+
/**
|
|
40
|
+
* The image latitude
|
|
41
|
+
*/
|
|
42
|
+
latitude: {
|
|
43
|
+
type: StringConstructor;
|
|
44
|
+
default: string;
|
|
45
|
+
};
|
|
46
|
+
/**
|
|
47
|
+
* The image longitude
|
|
48
|
+
*/
|
|
49
|
+
longitude: {
|
|
50
|
+
type: StringConstructor;
|
|
51
|
+
default: string;
|
|
52
|
+
};
|
|
53
|
+
mapOutlineColor: {
|
|
54
|
+
type: StringConstructor;
|
|
55
|
+
default: string;
|
|
56
|
+
};
|
|
57
|
+
mapMarkerColor: {
|
|
58
|
+
type: StringConstructor;
|
|
59
|
+
default: string;
|
|
60
|
+
};
|
|
61
|
+
}>>, {
|
|
62
|
+
latitude: string;
|
|
63
|
+
longitude: string;
|
|
64
|
+
mapOutlineColor: string;
|
|
65
|
+
mapMarkerColor: string;
|
|
66
|
+
}, {}>;
|
|
67
|
+
export default _default;
|
|
@@ -0,0 +1,242 @@
|
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{
|
|
2
|
+
/**
|
|
3
|
+
* An object providing all required localisation content from the CMS. This
|
|
4
|
+
* should contain global props like a translation for `next`, `previous`,
|
|
5
|
+
* `results` and so on, as well as question by question labels. Those should
|
|
6
|
+
* take the form
|
|
7
|
+
* `question-1.title` <- the category for the first question
|
|
8
|
+
* `question-1.question` <- the content of the first question
|
|
9
|
+
* `question-1.option-1` <- the first option for the first question
|
|
10
|
+
* `question-1.tip` <- the content of the tip for the above option
|
|
11
|
+
* and then repeat for each question-x beyond that.
|
|
12
|
+
*/
|
|
13
|
+
labelsMap: {
|
|
14
|
+
type: ObjectConstructor;
|
|
15
|
+
required: true;
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* Language locale string. Used to determine correct formatting for numbers (decimal
|
|
19
|
+
* delimeter)
|
|
20
|
+
*
|
|
21
|
+
* Example: "en-gb"
|
|
22
|
+
*/
|
|
23
|
+
language: {
|
|
24
|
+
type: StringConstructor;
|
|
25
|
+
default: string;
|
|
26
|
+
};
|
|
27
|
+
}, any, any, {
|
|
28
|
+
/**
|
|
29
|
+
* The question which is currently being displayed to the user, null if
|
|
30
|
+
* the user is on the intro or results page.
|
|
31
|
+
*/
|
|
32
|
+
currentQuestion(): any;
|
|
33
|
+
/**
|
|
34
|
+
* The tip which is currently being displayed to the user, based on their
|
|
35
|
+
* answer to the current question and what tips are available in their language
|
|
36
|
+
*/
|
|
37
|
+
currentTip(): any;
|
|
38
|
+
/**
|
|
39
|
+
* The length of the user's stay, parsed to an int from an answer
|
|
40
|
+
* provided to the user. Necessary to calculate the emissions per
|
|
41
|
+
* day in the results page.
|
|
42
|
+
*/
|
|
43
|
+
stayDuration(): number;
|
|
44
|
+
/**
|
|
45
|
+
* Retrieves the category for a given stage from the localised labelsMap provided
|
|
46
|
+
* by the CMS
|
|
47
|
+
*/
|
|
48
|
+
currentCategory(): any;
|
|
49
|
+
/**
|
|
50
|
+
* Retrieves the CTA to add an extra answer for a given stage, if that stage is repeatable
|
|
51
|
+
*/
|
|
52
|
+
activeStageRepeatable(): any;
|
|
53
|
+
}, {
|
|
54
|
+
/**
|
|
55
|
+
* Defines the initial state of the component, when the component is
|
|
56
|
+
* initialised and when the user resets the form to get another calculation.
|
|
57
|
+
*/
|
|
58
|
+
initialState(): {
|
|
59
|
+
formData: {};
|
|
60
|
+
messagingData: {};
|
|
61
|
+
form: {};
|
|
62
|
+
formIsInvalid: boolean;
|
|
63
|
+
showErrorMessage: boolean;
|
|
64
|
+
errorFields: any[];
|
|
65
|
+
triggerValidate: boolean;
|
|
66
|
+
conditionalFields: {};
|
|
67
|
+
reAlertErrors: boolean;
|
|
68
|
+
totalKilos: number;
|
|
69
|
+
transportKilos: number;
|
|
70
|
+
accommodationKilos: number;
|
|
71
|
+
foodKilos: number;
|
|
72
|
+
transportTip: any;
|
|
73
|
+
foodTip: any;
|
|
74
|
+
accommodationTip: any;
|
|
75
|
+
transportInternalTip: any;
|
|
76
|
+
activeStage: number;
|
|
77
|
+
answerSet: boolean;
|
|
78
|
+
repeatableStages: {};
|
|
79
|
+
};
|
|
80
|
+
/**
|
|
81
|
+
* Resets the form to its initial data configuration to restart the user's calculation.
|
|
82
|
+
* The formData is loaded on page creation by axios and won't change between calculations
|
|
83
|
+
* so can be held and set in the component to avoid doubling the load.
|
|
84
|
+
*/
|
|
85
|
+
restart(): void;
|
|
86
|
+
/**
|
|
87
|
+
* Remove leftover duplicated fields from form field data on reset, and reset count for
|
|
88
|
+
* each field that has been duplicated.
|
|
89
|
+
*/
|
|
90
|
+
cleanFields(): void;
|
|
91
|
+
/**
|
|
92
|
+
* Called on component created. Loads the json file located at this.dataUrl which
|
|
93
|
+
* contains all of the question data validation. This does not contain localisations, which
|
|
94
|
+
* are loaded from the CMS as labels and then mapped to the questions from the form.
|
|
95
|
+
*/
|
|
96
|
+
getFormData(): void;
|
|
97
|
+
/**
|
|
98
|
+
* Retrieves the default value for a message from the global messages json file in the
|
|
99
|
+
* current language.
|
|
100
|
+
*/
|
|
101
|
+
getMessagingData(type: any, lang: any): any;
|
|
102
|
+
/**
|
|
103
|
+
* Retrieves the label for a given question from the localised labelsMap provided
|
|
104
|
+
* by the CMS
|
|
105
|
+
*/
|
|
106
|
+
getQuestionLabel(field: any, index: any): any;
|
|
107
|
+
/**
|
|
108
|
+
* Retrieves the hint for a given question from the localised labelsMap provided
|
|
109
|
+
* by the CMS
|
|
110
|
+
*/
|
|
111
|
+
getQuestionHint(field: any, index: any): any;
|
|
112
|
+
/**
|
|
113
|
+
* Retrieves the options for a given question from the localised labelsMap provided
|
|
114
|
+
* by the CMS
|
|
115
|
+
*/
|
|
116
|
+
getQuestionOptions(field: any, index: any): any;
|
|
117
|
+
/**
|
|
118
|
+
* Called when the value of any input changes, updating values in the main this.form source
|
|
119
|
+
* of truth. The new value is stored, validated, error statuses and conditional field
|
|
120
|
+
* appearance is updated
|
|
121
|
+
*
|
|
122
|
+
* The inputs can't directly v-model variables from the this.form object because reactivity
|
|
123
|
+
* on sub-variables on arrays passed through multiple components is inconsistent and
|
|
124
|
+
* unreliable. Instead each component tracks its own value on an internal variable called
|
|
125
|
+
* inputVal then reports any changes to that value back up to the form.
|
|
126
|
+
*/
|
|
127
|
+
updateFieldData(data: any): void;
|
|
128
|
+
/**
|
|
129
|
+
* Updates the errorFields list with the current validated state of each field.
|
|
130
|
+
*/
|
|
131
|
+
manageErrorStatus(field: any, errors: any): void;
|
|
132
|
+
/**
|
|
133
|
+
* Calculates the current value of a radio button based question in the carbon calculator
|
|
134
|
+
* form. Each field has an actual raw value which is retruned by the radio button
|
|
135
|
+
* component, but also has a potential multiplication factor which could be based on
|
|
136
|
+
* another field or on a static value.
|
|
137
|
+
*/
|
|
138
|
+
getRadioValue(fieldName: any, key: any): any;
|
|
139
|
+
/**
|
|
140
|
+
* Calculates the current value of a number input based question in the carbon calculator
|
|
141
|
+
* form. Each field has an actual raw value which is retruned by the radio button
|
|
142
|
+
* component, but also has a potential multiplication factor which could be based on
|
|
143
|
+
* another field or on a static value.
|
|
144
|
+
*/
|
|
145
|
+
getNumberValue(fieldName: any, key: any): number;
|
|
146
|
+
/**
|
|
147
|
+
* Retrieves the current value for a given field, based on its type
|
|
148
|
+
*/
|
|
149
|
+
getFieldValue(checkField: any): any;
|
|
150
|
+
/**
|
|
151
|
+
* Calculates the current total emissions value, and category specific emission values
|
|
152
|
+
* for the user based on their submitted answers.
|
|
153
|
+
*/
|
|
154
|
+
calculateEmissions(): void;
|
|
155
|
+
/**
|
|
156
|
+
* Checks whether conditional fields meet the rules to show them
|
|
157
|
+
*/
|
|
158
|
+
checkConditionalFields(): void;
|
|
159
|
+
/**
|
|
160
|
+
* Moves the form forward one stage
|
|
161
|
+
*/
|
|
162
|
+
forwardPage(event: any): void;
|
|
163
|
+
/**
|
|
164
|
+
* Moves the form back one stage
|
|
165
|
+
*/
|
|
166
|
+
backwardPage(event: any): void;
|
|
167
|
+
/**
|
|
168
|
+
* Checks if an answer has been provided for the current question, if one
|
|
169
|
+
* is necessary to proceed
|
|
170
|
+
*/
|
|
171
|
+
checkNewAnswerSet(): void;
|
|
172
|
+
/**
|
|
173
|
+
* Check if the current stage appears in the list of repeatableStages defined in the form
|
|
174
|
+
* data. If so it should be possible to enter multiple values for it.
|
|
175
|
+
*/
|
|
176
|
+
isRepeatable(stage: any): boolean;
|
|
177
|
+
/**
|
|
178
|
+
* Sets the 'd-none' class on conditional fields which are currently not displaying.
|
|
179
|
+
*/
|
|
180
|
+
conditionalElementClass(fieldName: any): "" | "d-none";
|
|
181
|
+
/**
|
|
182
|
+
* Set the user focus to just before the current question. Called whenever they navigate
|
|
183
|
+
* to a new page to ensure a keyboard navigating user has clarity on what is happening
|
|
184
|
+
* after nav.
|
|
185
|
+
*/
|
|
186
|
+
resetFocus(): void;
|
|
187
|
+
/**
|
|
188
|
+
* Adds a duplicate for each question in the current stage to the form data. Duplicates
|
|
189
|
+
* are marked as clones to ensure subsequent duplicates are only added one set at a time
|
|
190
|
+
* rather than doubled.
|
|
191
|
+
*/
|
|
192
|
+
duplicateCurrentStage(event: any): void;
|
|
193
|
+
}, {
|
|
194
|
+
computed: {
|
|
195
|
+
pageUrl: () => string;
|
|
196
|
+
};
|
|
197
|
+
data(): {
|
|
198
|
+
dataLayerLoadConfirmed: boolean;
|
|
199
|
+
dataLayerStore: any;
|
|
200
|
+
};
|
|
201
|
+
mounted(): void;
|
|
202
|
+
methods: {
|
|
203
|
+
templateFiller(template: any, values: any): {};
|
|
204
|
+
createDataLayerObject(type: any, event: any, href: any): void; /**
|
|
205
|
+
* Retrieves the options for a given question from the localised labelsMap provided
|
|
206
|
+
* by the CMS
|
|
207
|
+
*/
|
|
208
|
+
returnIsoDate(): string;
|
|
209
|
+
pushToDataLayer(object: any): void;
|
|
210
|
+
compileFullTemplate(templateValues: any): any;
|
|
211
|
+
targetText(event: any): any;
|
|
212
|
+
};
|
|
213
|
+
}, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
214
|
+
/**
|
|
215
|
+
* An object providing all required localisation content from the CMS. This
|
|
216
|
+
* should contain global props like a translation for `next`, `previous`,
|
|
217
|
+
* `results` and so on, as well as question by question labels. Those should
|
|
218
|
+
* take the form
|
|
219
|
+
* `question-1.title` <- the category for the first question
|
|
220
|
+
* `question-1.question` <- the content of the first question
|
|
221
|
+
* `question-1.option-1` <- the first option for the first question
|
|
222
|
+
* `question-1.tip` <- the content of the tip for the above option
|
|
223
|
+
* and then repeat for each question-x beyond that.
|
|
224
|
+
*/
|
|
225
|
+
labelsMap: {
|
|
226
|
+
type: ObjectConstructor;
|
|
227
|
+
required: true;
|
|
228
|
+
};
|
|
229
|
+
/**
|
|
230
|
+
* Language locale string. Used to determine correct formatting for numbers (decimal
|
|
231
|
+
* delimeter)
|
|
232
|
+
*
|
|
233
|
+
* Example: "en-gb"
|
|
234
|
+
*/
|
|
235
|
+
language: {
|
|
236
|
+
type: StringConstructor;
|
|
237
|
+
default: string;
|
|
238
|
+
};
|
|
239
|
+
}>>, {
|
|
240
|
+
language: string;
|
|
241
|
+
}, {}>;
|
|
242
|
+
export default _default;
|
package/dist/components/components/carbon-calculator/components/CarbonCalculatorQuestion.vue.d.ts
ADDED
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{
|
|
2
|
+
/**
|
|
3
|
+
* The localised main text of the question that prompts the user to answer
|
|
4
|
+
*/
|
|
5
|
+
label: {
|
|
6
|
+
type: StringConstructor;
|
|
7
|
+
required: true;
|
|
8
|
+
};
|
|
9
|
+
labelFor: {
|
|
10
|
+
type: StringConstructor;
|
|
11
|
+
required: true;
|
|
12
|
+
};
|
|
13
|
+
/**
|
|
14
|
+
* The localised hint text of the question that clarifies the answer expected
|
|
15
|
+
* from the user
|
|
16
|
+
*/
|
|
17
|
+
hint: {
|
|
18
|
+
type: StringConstructor;
|
|
19
|
+
default: string;
|
|
20
|
+
};
|
|
21
|
+
/**
|
|
22
|
+
* Any additional styling classes that should be applied to the question
|
|
23
|
+
* as a whole
|
|
24
|
+
*/
|
|
25
|
+
fieldClass: {
|
|
26
|
+
type: StringConstructor;
|
|
27
|
+
required: true;
|
|
28
|
+
};
|
|
29
|
+
/**
|
|
30
|
+
* Which selector type should be used for the question.
|
|
31
|
+
* `radio|number`.
|
|
32
|
+
*/
|
|
33
|
+
fieldType: {
|
|
34
|
+
type: StringConstructor;
|
|
35
|
+
default: string;
|
|
36
|
+
validator: (value: unknown) => any;
|
|
37
|
+
};
|
|
38
|
+
/**
|
|
39
|
+
* The identifier for the field which should be provided when updating the
|
|
40
|
+
* value of the field to the calculator as a whole
|
|
41
|
+
*/
|
|
42
|
+
fieldName: {
|
|
43
|
+
type: StringConstructor;
|
|
44
|
+
required: true;
|
|
45
|
+
};
|
|
46
|
+
/**
|
|
47
|
+
* An array of options that the user can select. Each should be an object with a `value`
|
|
48
|
+
* string (that is submitted as part of the answer to the carbon calculation), a `text`
|
|
49
|
+
* string which denotes what the answer represents, and an `icon` string which dictates
|
|
50
|
+
* which icon is rendered on the radio button.
|
|
51
|
+
*/
|
|
52
|
+
options: {
|
|
53
|
+
type: ArrayConstructor;
|
|
54
|
+
required: true;
|
|
55
|
+
};
|
|
56
|
+
/**
|
|
57
|
+
* Minimum number value, only needed for number inputs
|
|
58
|
+
*/
|
|
59
|
+
minimum: {
|
|
60
|
+
type: NumberConstructor;
|
|
61
|
+
default: number;
|
|
62
|
+
};
|
|
63
|
+
/**
|
|
64
|
+
* Maximum number value, only needed for number inputs
|
|
65
|
+
*/
|
|
66
|
+
maximum: {
|
|
67
|
+
type: NumberConstructor;
|
|
68
|
+
default: number;
|
|
69
|
+
};
|
|
70
|
+
}, any, any, {}, {
|
|
71
|
+
/**
|
|
72
|
+
* Fired when the value of the nested input changes, emits the new value up to the
|
|
73
|
+
* questionnaire to be tracked in the running total.
|
|
74
|
+
*/
|
|
75
|
+
valueChanged(newData: any): void;
|
|
76
|
+
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
77
|
+
/**
|
|
78
|
+
* The localised main text of the question that prompts the user to answer
|
|
79
|
+
*/
|
|
80
|
+
label: {
|
|
81
|
+
type: StringConstructor;
|
|
82
|
+
required: true;
|
|
83
|
+
};
|
|
84
|
+
labelFor: {
|
|
85
|
+
type: StringConstructor;
|
|
86
|
+
required: true;
|
|
87
|
+
};
|
|
88
|
+
/**
|
|
89
|
+
* The localised hint text of the question that clarifies the answer expected
|
|
90
|
+
* from the user
|
|
91
|
+
*/
|
|
92
|
+
hint: {
|
|
93
|
+
type: StringConstructor;
|
|
94
|
+
default: string;
|
|
95
|
+
};
|
|
96
|
+
/**
|
|
97
|
+
* Any additional styling classes that should be applied to the question
|
|
98
|
+
* as a whole
|
|
99
|
+
*/
|
|
100
|
+
fieldClass: {
|
|
101
|
+
type: StringConstructor;
|
|
102
|
+
required: true;
|
|
103
|
+
};
|
|
104
|
+
/**
|
|
105
|
+
* Which selector type should be used for the question.
|
|
106
|
+
* `radio|number`.
|
|
107
|
+
*/
|
|
108
|
+
fieldType: {
|
|
109
|
+
type: StringConstructor;
|
|
110
|
+
default: string;
|
|
111
|
+
validator: (value: unknown) => any;
|
|
112
|
+
};
|
|
113
|
+
/**
|
|
114
|
+
* The identifier for the field which should be provided when updating the
|
|
115
|
+
* value of the field to the calculator as a whole
|
|
116
|
+
*/
|
|
117
|
+
fieldName: {
|
|
118
|
+
type: StringConstructor;
|
|
119
|
+
required: true;
|
|
120
|
+
};
|
|
121
|
+
/**
|
|
122
|
+
* An array of options that the user can select. Each should be an object with a `value`
|
|
123
|
+
* string (that is submitted as part of the answer to the carbon calculation), a `text`
|
|
124
|
+
* string which denotes what the answer represents, and an `icon` string which dictates
|
|
125
|
+
* which icon is rendered on the radio button.
|
|
126
|
+
*/
|
|
127
|
+
options: {
|
|
128
|
+
type: ArrayConstructor;
|
|
129
|
+
required: true;
|
|
130
|
+
};
|
|
131
|
+
/**
|
|
132
|
+
* Minimum number value, only needed for number inputs
|
|
133
|
+
*/
|
|
134
|
+
minimum: {
|
|
135
|
+
type: NumberConstructor;
|
|
136
|
+
default: number;
|
|
137
|
+
};
|
|
138
|
+
/**
|
|
139
|
+
* Maximum number value, only needed for number inputs
|
|
140
|
+
*/
|
|
141
|
+
maximum: {
|
|
142
|
+
type: NumberConstructor;
|
|
143
|
+
default: number;
|
|
144
|
+
};
|
|
145
|
+
}>>, {
|
|
146
|
+
hint: string;
|
|
147
|
+
fieldType: string;
|
|
148
|
+
minimum: number;
|
|
149
|
+
maximum: number;
|
|
150
|
+
}, {}>;
|
|
151
|
+
export default _default;
|
package/dist/components/components/carbon-calculator/components/CarbonCalculatorResults.vue.d.ts
ADDED
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{
|
|
2
|
+
/**
|
|
3
|
+
* The total equivalent weight of emissions for the survey, used as the headline figure
|
|
4
|
+
* as well as for working out daily emissions and in the comparison.
|
|
5
|
+
*/
|
|
6
|
+
totalKilos: {
|
|
7
|
+
type: NumberConstructor;
|
|
8
|
+
default: number;
|
|
9
|
+
};
|
|
10
|
+
/**
|
|
11
|
+
* The weight of emissions specifically related to food
|
|
12
|
+
*/
|
|
13
|
+
foodKilos: {
|
|
14
|
+
type: NumberConstructor;
|
|
15
|
+
default: number;
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* The weight of emissions specifically related to transport
|
|
19
|
+
*/
|
|
20
|
+
transportKilos: {
|
|
21
|
+
type: NumberConstructor;
|
|
22
|
+
default: number;
|
|
23
|
+
};
|
|
24
|
+
/**
|
|
25
|
+
* The weight of emissions specifically related to accommodation
|
|
26
|
+
*/
|
|
27
|
+
accommodationKilos: {
|
|
28
|
+
type: NumberConstructor;
|
|
29
|
+
default: number;
|
|
30
|
+
};
|
|
31
|
+
/**
|
|
32
|
+
* The number of nights the user is staying, used to calculate per day emissions
|
|
33
|
+
*/
|
|
34
|
+
stayDuration: {
|
|
35
|
+
type: NumberConstructor;
|
|
36
|
+
default: number;
|
|
37
|
+
};
|
|
38
|
+
/**
|
|
39
|
+
* An array that defines which placeholders in the comparison need to be replaced and what
|
|
40
|
+
* they should be replaced with. Each entry should be an object with a "repl" key and a
|
|
41
|
+
* "divisor" key
|
|
42
|
+
*
|
|
43
|
+
* {
|
|
44
|
+
* "repl": "xxx",
|
|
45
|
+
* "divisor": 0.2
|
|
46
|
+
* }
|
|
47
|
+
*
|
|
48
|
+
* In the above case, the substring "xxx" in the comparison will be replaced with the total
|
|
49
|
+
* emissions number / 0.2
|
|
50
|
+
*/
|
|
51
|
+
comparisonReplacements: {
|
|
52
|
+
type: ArrayConstructor;
|
|
53
|
+
default: () => any[];
|
|
54
|
+
};
|
|
55
|
+
/**
|
|
56
|
+
* Language locale string. Used to determine correct formatting for numbers (decimal
|
|
57
|
+
* delimeter)
|
|
58
|
+
*
|
|
59
|
+
* Example: "en-gb"
|
|
60
|
+
*/
|
|
61
|
+
language: {
|
|
62
|
+
type: StringConstructor;
|
|
63
|
+
default: string;
|
|
64
|
+
};
|
|
65
|
+
}, any, {
|
|
66
|
+
chartDirection: import("vue").Ref<string>;
|
|
67
|
+
chartAxis: import("vue").Ref<{
|
|
68
|
+
primary: {
|
|
69
|
+
type: string;
|
|
70
|
+
};
|
|
71
|
+
}>;
|
|
72
|
+
cssProps: string;
|
|
73
|
+
}, {
|
|
74
|
+
/**
|
|
75
|
+
* Data object for the vue3-chart
|
|
76
|
+
*/
|
|
77
|
+
chartData(): {
|
|
78
|
+
name: any;
|
|
79
|
+
emissions: any;
|
|
80
|
+
}[];
|
|
81
|
+
/**
|
|
82
|
+
* Returns the localised comparison from the labelsmap with actual data interpolated into
|
|
83
|
+
* it. The comparison is a string with one or more placeholders in it which need to be
|
|
84
|
+
* replaced with a number specific to the user's actual data (in the general form of
|
|
85
|
+
* "that's equivalent to 15 full washloads").
|
|
86
|
+
*
|
|
87
|
+
* The exact string that needs to be replaced and the number that should be entered is
|
|
88
|
+
* derived from the comparison replacements object described in props.
|
|
89
|
+
*/
|
|
90
|
+
interpolComparison(): any;
|
|
91
|
+
/**
|
|
92
|
+
* Interpolates the per day emissions into a localised string.
|
|
93
|
+
*/
|
|
94
|
+
interpolKGsPerDay(): any;
|
|
95
|
+
/**
|
|
96
|
+
* Interpolates the per day success into a localised string.
|
|
97
|
+
*/
|
|
98
|
+
interpolPerDaySuccess(): any;
|
|
99
|
+
transportPercent(): number;
|
|
100
|
+
accommodationPercent(): number;
|
|
101
|
+
foodPercent(): number;
|
|
102
|
+
totalPerDay(): number;
|
|
103
|
+
}, {
|
|
104
|
+
responsiveMargin(width: any): {
|
|
105
|
+
left: number;
|
|
106
|
+
top: number;
|
|
107
|
+
right: number;
|
|
108
|
+
bottom: number;
|
|
109
|
+
};
|
|
110
|
+
}, any, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
111
|
+
/**
|
|
112
|
+
* The total equivalent weight of emissions for the survey, used as the headline figure
|
|
113
|
+
* as well as for working out daily emissions and in the comparison.
|
|
114
|
+
*/
|
|
115
|
+
totalKilos: {
|
|
116
|
+
type: NumberConstructor;
|
|
117
|
+
default: number;
|
|
118
|
+
};
|
|
119
|
+
/**
|
|
120
|
+
* The weight of emissions specifically related to food
|
|
121
|
+
*/
|
|
122
|
+
foodKilos: {
|
|
123
|
+
type: NumberConstructor;
|
|
124
|
+
default: number;
|
|
125
|
+
};
|
|
126
|
+
/**
|
|
127
|
+
* The weight of emissions specifically related to transport
|
|
128
|
+
*/
|
|
129
|
+
transportKilos: {
|
|
130
|
+
type: NumberConstructor;
|
|
131
|
+
default: number;
|
|
132
|
+
};
|
|
133
|
+
/**
|
|
134
|
+
* The weight of emissions specifically related to accommodation
|
|
135
|
+
*/
|
|
136
|
+
accommodationKilos: {
|
|
137
|
+
type: NumberConstructor;
|
|
138
|
+
default: number;
|
|
139
|
+
};
|
|
140
|
+
/**
|
|
141
|
+
* The number of nights the user is staying, used to calculate per day emissions
|
|
142
|
+
*/
|
|
143
|
+
stayDuration: {
|
|
144
|
+
type: NumberConstructor;
|
|
145
|
+
default: number;
|
|
146
|
+
};
|
|
147
|
+
/**
|
|
148
|
+
* An array that defines which placeholders in the comparison need to be replaced and what
|
|
149
|
+
* they should be replaced with. Each entry should be an object with a "repl" key and a
|
|
150
|
+
* "divisor" key
|
|
151
|
+
*
|
|
152
|
+
* {
|
|
153
|
+
* "repl": "xxx",
|
|
154
|
+
* "divisor": 0.2
|
|
155
|
+
* }
|
|
156
|
+
*
|
|
157
|
+
* In the above case, the substring "xxx" in the comparison will be replaced with the total
|
|
158
|
+
* emissions number / 0.2
|
|
159
|
+
*/
|
|
160
|
+
comparisonReplacements: {
|
|
161
|
+
type: ArrayConstructor;
|
|
162
|
+
default: () => any[];
|
|
163
|
+
};
|
|
164
|
+
/**
|
|
165
|
+
* Language locale string. Used to determine correct formatting for numbers (decimal
|
|
166
|
+
* delimeter)
|
|
167
|
+
*
|
|
168
|
+
* Example: "en-gb"
|
|
169
|
+
*/
|
|
170
|
+
language: {
|
|
171
|
+
type: StringConstructor;
|
|
172
|
+
default: string;
|
|
173
|
+
};
|
|
174
|
+
}>>, {
|
|
175
|
+
language: string;
|
|
176
|
+
totalKilos: number;
|
|
177
|
+
foodKilos: number;
|
|
178
|
+
transportKilos: number;
|
|
179
|
+
accommodationKilos: number;
|
|
180
|
+
stayDuration: number;
|
|
181
|
+
comparisonReplacements: unknown[];
|
|
182
|
+
}, {}>;
|
|
183
|
+
export default _default;
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{
|
|
2
|
+
/**
|
|
3
|
+
* The current total number of kilos of carbon captured in the
|
|
4
|
+
* user's calculation. Will be rounded to 3 significant figures
|
|
5
|
+
* when rendered.
|
|
6
|
+
*/
|
|
7
|
+
totalKilos: {
|
|
8
|
+
type: NumberConstructor;
|
|
9
|
+
default: number;
|
|
10
|
+
};
|
|
11
|
+
/**
|
|
12
|
+
* Language locale string. Used to determine correct formatting for numbers (decimal
|
|
13
|
+
* delimeter)
|
|
14
|
+
*
|
|
15
|
+
* Example: "en-gb"
|
|
16
|
+
*/
|
|
17
|
+
language: {
|
|
18
|
+
type: StringConstructor;
|
|
19
|
+
default: string;
|
|
20
|
+
};
|
|
21
|
+
}, any, any, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
22
|
+
/**
|
|
23
|
+
* The current total number of kilos of carbon captured in the
|
|
24
|
+
* user's calculation. Will be rounded to 3 significant figures
|
|
25
|
+
* when rendered.
|
|
26
|
+
*/
|
|
27
|
+
totalKilos: {
|
|
28
|
+
type: NumberConstructor;
|
|
29
|
+
default: number;
|
|
30
|
+
};
|
|
31
|
+
/**
|
|
32
|
+
* Language locale string. Used to determine correct formatting for numbers (decimal
|
|
33
|
+
* delimeter)
|
|
34
|
+
*
|
|
35
|
+
* Example: "en-gb"
|
|
36
|
+
*/
|
|
37
|
+
language: {
|
|
38
|
+
type: StringConstructor;
|
|
39
|
+
default: string;
|
|
40
|
+
};
|
|
41
|
+
}>>, {
|
|
42
|
+
language: string;
|
|
43
|
+
totalKilos: number;
|
|
44
|
+
}, {}>;
|
|
45
|
+
export default _default;
|