@coras-io/embed 0.2.0 → 0.3.0
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 +127 -0
- package/README.md +8 -7
- package/dist/components/accordion/accordion-item/accordion-item.styles.js +1 -1
- package/dist/components/alert/alert.styles.js +14 -14
- package/dist/components/attraction-card/base/attraction-card.styles.js +7 -3
- package/dist/components/attraction-discovery/attraction-discovery.styles.js +1 -1
- package/dist/components/attraction-header/attraction-header.styles.js +1 -1
- package/dist/components/attraction-option/attraction-option.styles.js +4 -4
- package/dist/components/basket/basket.styles.js +27 -26
- package/dist/components/basket-empty/basket-empty.styles.js +1 -0
- package/dist/components/basket-item/basket-item.component.js +10 -4
- package/dist/components/basket-item/basket-item.styles.js +9 -3
- package/dist/components/basket-item-ticket/basket-item-ticket.styles.js +1 -3
- package/dist/components/basket-mobile/basket-mobile.styles.js +5 -5
- package/dist/components/better-carousel/better-carousel.styles.js +2 -0
- package/dist/components/bottom-drawer/bottom-drawer.styles.js +6 -4
- package/dist/components/button/button.component.d.ts +0 -1
- package/dist/components/button/button.component.js +1 -8
- package/dist/components/button/button.constants.d.ts +1 -1
- package/dist/components/button/button.constants.js +1 -1
- package/dist/components/button/button.styles.js +66 -39
- package/dist/components/calendar/base/calendar.styles.js +3 -5
- package/dist/components/calendar/multi/multi.styles.js +7 -0
- package/dist/components/category-tag/category-tag.styles.js +10 -7
- package/dist/components/checkbox/checkbox.styles.js +2 -2
- package/dist/components/chip/chip.styles.js +2 -2
- package/dist/components/collect-fida/collect-fida.component.js +5 -3
- package/dist/components/collect-fida/collect-fida.styles.js +9 -16
- package/dist/components/crypto-auth-modal/crypto-auth-modal.component.js +6 -4
- package/dist/components/crypto-auth-modal/crypto-auth-modal.styles.js +2 -2
- package/dist/components/dialog/dialog.styles.js +10 -17
- package/dist/components/drawer/drawer.component.js +6 -0
- package/dist/components/drawer/drawer.styles.js +17 -3
- package/dist/components/dropdown/dropdown.component.js +7 -0
- package/dist/components/dropdown/dropdown.styles.js +3 -6
- package/dist/components/expiration-timer/expiration-timer.styles.js +3 -3
- package/dist/components/explore-card/explore-card.styles.js +1 -1
- package/dist/components/filter-chip/filter-chip.styles.js +11 -9
- package/dist/components/filters-drawer/filters-drawer.component.js +1 -1
- package/dist/components/filters-drawer/filters-drawer.styles.js +6 -5
- package/dist/components/image/image.styles.js +3 -3
- package/dist/components/image-chip/image-chip.styles.js +1 -1
- package/dist/components/input-field/input-field.styles.js +22 -17
- package/dist/components/itinerary/itinerary-item/itinerary-item.styles.js +1 -1
- package/dist/components/joined-fields/joined-fields.styles.js +10 -6
- package/dist/components/loading-spinner/loading-spinner.styles.js +1 -1
- package/dist/components/location-image/location-image.component.d.ts +6 -0
- package/dist/components/location-image/location-image.component.js +15 -2
- package/dist/components/location-image/location-image.styles.js +1 -1
- package/dist/components/locations-results/locations-results.styles.js +4 -6
- package/dist/components/marketing-tag/marketing-tag.styles.js +1 -1
- package/dist/components/message-card/message-card.styles.js +6 -6
- package/dist/components/option-group/option-chip/option-chip.styles.js +4 -3
- package/dist/components/order-confirmation/order-confirmation-item/order-confirmation-item.styles.js +9 -0
- package/dist/components/order-confirmation/order-confirmation.component.js +4 -3
- package/dist/components/order-confirmation/order-confirmation.styles.js +1 -1
- package/dist/components/otp/otp.styles.js +6 -6
- package/dist/components/overlay/overlay.styles.js +5 -1
- package/dist/components/pay-in/pay-in.styles.js +2 -2
- package/dist/components/payment-fiat-method/payment-fiat-method.styles.js +20 -4
- package/dist/components/payment-option/payment-option.styles.js +10 -12
- package/dist/components/performance-time/performance-time.styles.js +2 -2
- package/dist/components/phone-country-code/phone-country-code.styles.js +1 -1
- package/dist/components/points/points.styles.js +1 -1
- package/dist/components/search-button/search-button.styles.js +15 -7
- package/dist/components/seated-selector/seated-selector.component.d.ts +2 -0
- package/dist/components/seated-selector/seated-selector.component.js +53 -10
- package/dist/components/seated-selector/seated-selector.styles.js +77 -14
- package/dist/components/seats-io/seats-io.component.d.ts +2 -0
- package/dist/components/seats-io/seats-io.component.js +25 -2
- package/dist/components/seats-io/seats-io.constants.d.ts +2 -1
- package/dist/components/seats-io/seats-io.constants.js +6 -1
- package/dist/components/seats-io/seats-io.transform.d.ts +8 -2
- package/dist/components/seats-io/seats-io.transform.js +12 -4
- package/dist/components/select-list/select-list.styles.js +1 -0
- package/dist/components/select-list/select-option/select-option.styles.js +3 -3
- package/dist/components/sort-dropdown/sort-dropdown.styles.js +1 -1
- package/dist/components/sort-list/sort-list.styles.js +1 -1
- package/dist/components/sport-options/sport-option/sport-option.styles.js +2 -2
- package/dist/components/star-rating/star-rating.component.d.ts +1 -0
- package/dist/components/star-rating/star-rating.component.js +19 -23
- package/dist/components/star-rating/star-rating.styles.js +32 -6
- package/dist/components/tab/tab.styles.js +1 -1
- package/dist/components/tabs/tabs.styles.js +1 -1
- package/dist/components/tag/tag.styles.js +7 -7
- package/dist/components/text-section/text-section.styles.js +2 -1
- package/dist/components/time-tag/time-tag.styles.js +1 -2
- package/dist/components/tooltip/tooltip.styles.js +3 -3
- package/dist/components/tour-ticket-type-selector/tour-ticket-type/tour-ticket-type.styles.js +2 -2
- package/dist/components/tour-ticket-type-selector/tour-ticket-type-selector.component.js +1 -1
- package/dist/components/tour-ticket-type-selector/tour-ticket-type-selector.styles.js +1 -10
- package/dist/components/transfer-modal/transfer-modal.component.js +3 -3
- package/dist/components/transfer-modal/transfer-modal.styles.js +6 -8
- package/dist/containers/basket/basket.component.d.ts +1 -1
- package/dist/containers/basket/basket.component.js +56 -25
- package/dist/containers/footer/footer.styles.js +4 -0
- package/dist/containers/navbar/navbar.component.d.ts +5 -1
- package/dist/containers/navbar/navbar.component.js +38 -9
- package/dist/containers/navbar/navbar.styles.js +38 -12
- package/dist/contexts/basket/basket.provider.d.ts +1 -0
- package/dist/contexts/basket/basket.provider.js +31 -4
- package/dist/contexts/properties.context.d.ts +4 -4
- package/dist/core/api/middlewares/booking-session/booking-session.constants.d.ts +1 -0
- package/dist/core/api/middlewares/booking-session/booking-session.constants.js +1 -0
- package/dist/core/api/middlewares/booking-session/booking-session.js +18 -27
- package/dist/core/api/middlewares/booking-session/booking-session.utils.d.ts +4 -4
- package/dist/core/api/middlewares/booking-session/booking-session.utils.js +13 -10
- package/dist/core/api/queries.js +3 -2
- package/dist/core/color-scheme.d.ts +14 -0
- package/dist/core/color-scheme.js +48 -0
- package/dist/core/currency/constants.d.ts +1 -1
- package/dist/core/currency/constants.js +4 -3
- package/dist/core/i18n/date.js +20 -9
- package/dist/core/i18n/locale-codes.d.ts +2 -2
- package/dist/core/i18n/locale-codes.js +4 -0
- package/dist/core/images/constants.d.ts +0 -5
- package/dist/core/images/constants.js +0 -5
- package/dist/core/images/helpers.d.ts +8 -0
- package/dist/core/images/helpers.js +14 -6
- package/dist/core/images/srcset.js +2 -2
- package/dist/core/storybook/demo.d.ts +4 -0
- package/dist/core/storybook/demo.js +17 -0
- package/dist/core/types/locales.d.ts +7 -0
- package/dist/core/utils/datetime.js +10 -4
- package/dist/core/utils/locale.d.ts +8 -1
- package/dist/core/utils/locale.js +10 -0
- package/dist/helpers/helpers.d.ts +1 -1
- package/dist/index.d.ts +2 -3
- package/dist/index.js +1 -2
- package/dist/locales/ar-SA.d.ts +279 -0
- package/dist/locales/ar-SA.js +288 -0
- package/dist/locales/da-DK.d.ts +100 -82
- package/dist/locales/da-DK.js +104 -89
- package/dist/locales/de-DE.d.ts +100 -82
- package/dist/locales/de-DE.js +104 -89
- package/dist/locales/en-IE.d.ts +250 -232
- package/dist/locales/en-IE.js +253 -238
- package/dist/locales/en-US.d.ts +100 -82
- package/dist/locales/en-US.js +105 -90
- package/dist/locales/es-ES.d.ts +100 -82
- package/dist/locales/es-ES.js +104 -89
- package/dist/locales/fr-FR.d.ts +100 -82
- package/dist/locales/fr-FR.js +104 -89
- package/dist/locales/fr-MA.d.ts +100 -82
- package/dist/locales/fr-MA.js +104 -89
- package/dist/locales/is-IS.d.ts +100 -82
- package/dist/locales/is-IS.js +104 -89
- package/dist/locales/it-IT.d.ts +100 -82
- package/dist/locales/it-IT.js +104 -89
- package/dist/locales/ms-MY.d.ts +100 -82
- package/dist/locales/ms-MY.js +104 -89
- package/dist/locales/nb-NO.d.ts +100 -82
- package/dist/locales/nb-NO.js +104 -89
- package/dist/locales/pl-PL.d.ts +100 -82
- package/dist/locales/pl-PL.js +104 -89
- package/dist/locales/pt-PT.d.ts +100 -82
- package/dist/locales/pt-PT.js +104 -89
- package/dist/locales/sv-SE.d.ts +100 -82
- package/dist/locales/sv-SE.js +104 -89
- package/dist/locales/th-TH.d.ts +100 -82
- package/dist/locales/th-TH.js +104 -89
- package/dist/locales/tr-TR.d.ts +100 -82
- package/dist/locales/tr-TR.js +104 -89
- package/dist/locales/zh-CN.d.ts +100 -82
- package/dist/locales/zh-CN.js +105 -90
- package/dist/locales/zh-HK.d.ts +279 -0
- package/dist/locales/zh-HK.js +288 -0
- package/dist/mixins/coinbase.mixin.js +1 -1
- package/dist/mixins/error-modal.styles.js +2 -2
- package/dist/mixins/location-search/location-search.js +3 -3
- package/dist/mixins/location-search/location-search.styles.js +6 -5
- package/dist/sdk/chrome.d.ts +9 -3
- package/dist/sdk/chrome.js +21 -9
- package/dist/sdk/element-adapter.js +11 -8
- package/dist/sdk/mount.d.ts +3 -3
- package/dist/sdk/mount.js +150 -42
- package/dist/sdk/navigation-intent.js +3 -0
- package/dist/sdk/page-registry.d.ts +14 -2
- package/dist/sdk/page-registry.js +33 -13
- package/dist/sdk/theme.d.ts +1 -15
- package/dist/sdk/theme.js +4 -39
- package/dist/sdk/types.d.ts +55 -24
- package/dist/sdk/url.d.ts +24 -3
- package/dist/sdk/url.js +66 -27
- package/dist/sdk/validation.d.ts +0 -7
- package/dist/sdk/validation.js +105 -47
- package/dist/styles/contrast-fixtures.d.ts +0 -5
- package/dist/styles/contrast-fixtures.js +79 -9
- package/dist/styles/contrast.js +4 -3
- package/dist/styles/defaults/component.js +17 -1
- package/dist/styles/primitives.d.ts +0 -10
- package/dist/styles/primitives.js +2 -12
- package/dist/styles/tokens.d.ts +1 -1
- package/dist/styles/tokens.generated.d.ts +1 -1
- package/dist/styles/tokens.generated.js +1 -1
- package/dist/styles/tokens.metadata.d.ts +1 -1
- package/dist/styles/tokens.metadata.js +360 -90
- package/dist/views/details-page/details-page.component.d.ts +5 -5
- package/dist/views/details-page/details-page.component.js +72 -79
- package/dist/views/details-page/details-page.styles.js +64 -9
- package/dist/views/help-page/help-page.component.d.ts +1 -0
- package/dist/views/help-page/help-page.component.js +11 -4
- package/dist/views/help-page/help-page.styles.js +21 -8
- package/dist/views/landing-page/landing-page.component.d.ts +4 -4
- package/dist/views/landing-page/landing-page.component.js +65 -65
- package/dist/views/landing-page/landing-page.styles.js +70 -3
- package/dist/views/payment-page/partials/activity-details/activity-details.styles.js +10 -33
- package/dist/views/payment-page/partials/billing-address/billing-address.styles.js +4 -9
- package/dist/views/payment-page/partials/confirmation/confirmation.styles.js +6 -6
- package/dist/views/payment-page/partials/hotel-pickup-list/hotel-pickup-list.styles.js +4 -4
- package/dist/views/payment-page/partials/payment-type-selector/payment-type-selector.styles.js +1 -0
- package/dist/views/payment-page/partials/stripe/stripe.component.d.ts +1 -1
- package/dist/views/payment-page/partials/stripe/stripe.component.js +11 -12
- package/dist/views/payment-page/partials/stripe/stripe.constants.d.ts +2 -15
- package/dist/views/payment-page/partials/stripe/stripe.constants.js +4 -17
- package/dist/views/payment-page/partials/stripe/stripe.styles.js +16 -23
- package/dist/views/payment-page/partials/stripe/stripe.utils.d.ts +25 -14
- package/dist/views/payment-page/partials/stripe/stripe.utils.js +111 -62
- package/dist/views/payment-page/partials/terms-checkbox/terms-checkbox.styles.js +1 -1
- package/dist/views/payment-page/payment-page.component.d.ts +1 -0
- package/dist/views/payment-page/payment-page.component.js +19 -9
- package/dist/views/payment-page/payment-page.styles.js +37 -32
- package/dist/views/payment-page/payment-page.utils.d.ts +7 -0
- package/dist/views/payment-page/payment-page.utils.js +29 -14
- package/dist/views/payment-page/payment-page.validators.js +9 -3
- package/dist/views/payment-page/services/payment-api.service.d.ts +1 -1
- package/dist/views/search-page/search-page.component.d.ts +1 -0
- package/dist/views/search-page/search-page.component.js +12 -6
- package/dist/views/search-page/search-page.styles.js +24 -2
- package/dist/views/suggestion-widget/suggestion-widget.styles.js +1 -1
- package/package.json +62 -75
- package/dist/custom-elements.json +0 -37397
- package/dist/sdk/meta.d.ts +0 -7
- package/dist/sdk/meta.js +0 -9
- package/dist/styles/tokens.css +0 -359
|
@@ -52,10 +52,8 @@ import "../../components/layout/layout.js";
|
|
|
52
52
|
import { apiGet, withErrorHandling } from "../../core/api/queries.js";
|
|
53
53
|
import { addRecentlySelectedSearches } from "../../containers/navbar/navbar.utils.js";
|
|
54
54
|
/**
|
|
55
|
-
*
|
|
56
|
-
*
|
|
57
|
-
* @fires coras:navigate - Dispatched when navigating to another page (search result, page navigation)
|
|
58
|
-
* @fires coras:state-change - Dispatched when in-page params change (filters, sorting, dates)
|
|
55
|
+
* @fires coras:navigate
|
|
56
|
+
* @fires coras:state-change
|
|
59
57
|
*/
|
|
60
58
|
let CorasLandingPage = class CorasLandingPage extends ErrorModalMixin(PointsMixin(LocationSearchMixin(BaseMixin(LitElement)))) {
|
|
61
59
|
constructor() {
|
|
@@ -76,13 +74,14 @@ let CorasLandingPage = class CorasLandingPage extends ErrorModalMixin(PointsMixi
|
|
|
76
74
|
this.startDate,
|
|
77
75
|
this.endDate,
|
|
78
76
|
];
|
|
77
|
+
// The filters drawer's working selection, reactive so clearing or re-syncing
|
|
78
|
+
// it from the applied params repaints the checkboxes.
|
|
79
79
|
this.selectedPriceOptions = [];
|
|
80
80
|
this.selectedDurationOptions = [];
|
|
81
81
|
this._selectedCategories = "";
|
|
82
82
|
this.activePriceOptions = null;
|
|
83
83
|
this.activeDurationOptions = null;
|
|
84
84
|
this.activeCategorySlugs = null;
|
|
85
|
-
// prevent duplicate writes within a single component lifecycle
|
|
86
85
|
this.lastSavedRecentValue = null;
|
|
87
86
|
this.geolocationTask = new Task(this, {
|
|
88
87
|
autoRun: false,
|
|
@@ -201,14 +200,11 @@ let CorasLandingPage = class CorasLandingPage extends ErrorModalMixin(PointsMixi
|
|
|
201
200
|
if (getLocale() !== this.locale) {
|
|
202
201
|
setLocale(this.locale);
|
|
203
202
|
}
|
|
204
|
-
// Record recently viewed location (country or city)
|
|
205
203
|
if (this.locationsData && (this.country || this.city)) {
|
|
206
|
-
// Try to find the readable names
|
|
207
204
|
const matchingCountry = this.locationsData
|
|
208
205
|
.flatMap((continent) => continent.countries ?? [])
|
|
209
206
|
.find((country) => country?.slug === this.country);
|
|
210
207
|
const matchingCity = matchingCountry?.cities?.find((city) => city?.slug === this.city);
|
|
211
|
-
// Prefer city if present, otherwise country
|
|
212
208
|
const item = this.city && matchingCity
|
|
213
209
|
? { type: "city", value: this.city, name: matchingCity.name }
|
|
214
210
|
: this.country && matchingCountry
|
|
@@ -223,26 +219,16 @@ let CorasLandingPage = class CorasLandingPage extends ErrorModalMixin(PointsMixi
|
|
|
223
219
|
addRecentlySelectedSearches(item);
|
|
224
220
|
this.lastSavedRecentValue = item.value;
|
|
225
221
|
}
|
|
226
|
-
catch {
|
|
227
|
-
// noop
|
|
228
|
-
}
|
|
222
|
+
catch { }
|
|
229
223
|
}
|
|
230
224
|
}
|
|
231
225
|
if (changedProperties.has("startDate") ||
|
|
232
226
|
changedProperties.has("endDate")) {
|
|
233
227
|
this.selectedDates = [this.startDate, this.endDate];
|
|
234
|
-
if (
|
|
235
|
-
|
|
236
|
-
const startDateISO = new Date(changedProperties.get("startDate")).toISOString();
|
|
237
|
-
this.selectedMonth = format(parseISO(startDateISO), "yyyy-MM");
|
|
228
|
+
if (this.startDate !== "") {
|
|
229
|
+
this.selectedMonth = format(parseISO(this.startDate), "yyyy-MM");
|
|
238
230
|
}
|
|
239
231
|
}
|
|
240
|
-
if (changedProperties.has("startDate") &&
|
|
241
|
-
changedProperties.get("startDate") &&
|
|
242
|
-
changedProperties.get("startDate") !== "") {
|
|
243
|
-
const startDateISO = new Date(changedProperties.get("startDate")).toISOString();
|
|
244
|
-
this.selectedMonth = format(parseISO(startDateISO), "yyyy-MM");
|
|
245
|
-
}
|
|
246
232
|
if (changedProperties.has("duration")) {
|
|
247
233
|
this.selectedDurationOptions = this.duration
|
|
248
234
|
? this.duration.split(",").filter(Boolean)
|
|
@@ -258,6 +244,7 @@ let CorasLandingPage = class CorasLandingPage extends ErrorModalMixin(PointsMixi
|
|
|
258
244
|
}
|
|
259
245
|
}
|
|
260
246
|
if (changedProperties.has("categories")) {
|
|
247
|
+
this._selectedCategories = this.categories;
|
|
261
248
|
this.updateActiveFilters();
|
|
262
249
|
}
|
|
263
250
|
}
|
|
@@ -303,7 +290,7 @@ let CorasLandingPage = class CorasLandingPage extends ErrorModalMixin(PointsMixi
|
|
|
303
290
|
<div slot="trigger" @click=${this.toggleDateFilter}>
|
|
304
291
|
<coras-button
|
|
305
292
|
variant=${variant}
|
|
306
|
-
radius="
|
|
293
|
+
radius="field"
|
|
307
294
|
border-color="light"
|
|
308
295
|
?rotate-suffix=${this.isDateFilterOpen && !hasSelectedDates}
|
|
309
296
|
>
|
|
@@ -381,7 +368,7 @@ let CorasLandingPage = class CorasLandingPage extends ErrorModalMixin(PointsMixi
|
|
|
381
368
|
return html `
|
|
382
369
|
<coras-button
|
|
383
370
|
variant=${variant}
|
|
384
|
-
radius="
|
|
371
|
+
radius="field"
|
|
385
372
|
border-color="light"
|
|
386
373
|
@click=${this.toggleDateFilter}
|
|
387
374
|
>
|
|
@@ -405,21 +392,21 @@ let CorasLandingPage = class CorasLandingPage extends ErrorModalMixin(PointsMixi
|
|
|
405
392
|
@calendar-month-changed=${this.handleCalendarMonthChange}
|
|
406
393
|
@date-selected=${this.setSelectedDates}
|
|
407
394
|
></coras-multi-month-calendar>
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
</
|
|
395
|
+
</div>
|
|
396
|
+
<div slot="footer" class="select-dates-actions">
|
|
397
|
+
<coras-button
|
|
398
|
+
variant="outlined"
|
|
399
|
+
border-color="medium"
|
|
400
|
+
@click=${this.handleDatesResetBtnClicked}
|
|
401
|
+
>
|
|
402
|
+
${msg("Reset")}
|
|
403
|
+
</coras-button>
|
|
404
|
+
<coras-button
|
|
405
|
+
variant="primary"
|
|
406
|
+
@click=${this.handleDatesApplyBtnClicked}
|
|
407
|
+
>
|
|
408
|
+
${msg("Done")}
|
|
409
|
+
</coras-button>
|
|
423
410
|
</div>
|
|
424
411
|
</coras-drawer>
|
|
425
412
|
`;
|
|
@@ -456,7 +443,7 @@ let CorasLandingPage = class CorasLandingPage extends ErrorModalMixin(PointsMixi
|
|
|
456
443
|
<coras-button
|
|
457
444
|
slot="trigger"
|
|
458
445
|
variant="outlined"
|
|
459
|
-
radius="
|
|
446
|
+
radius="field"
|
|
460
447
|
border-color="light"
|
|
461
448
|
?rotate-suffix=${this.isSortingSelectorOpen}
|
|
462
449
|
@click=${this.toggleSortingSelector}
|
|
@@ -514,7 +501,7 @@ let CorasLandingPage = class CorasLandingPage extends ErrorModalMixin(PointsMixi
|
|
|
514
501
|
return html `
|
|
515
502
|
<coras-button
|
|
516
503
|
variant=${variant}
|
|
517
|
-
radius="
|
|
504
|
+
radius="field"
|
|
518
505
|
border-color="light"
|
|
519
506
|
@click=${this.toggleFiltersDrawer}
|
|
520
507
|
>
|
|
@@ -599,12 +586,10 @@ let CorasLandingPage = class CorasLandingPage extends ErrorModalMixin(PointsMixi
|
|
|
599
586
|
if (!filters)
|
|
600
587
|
return slug;
|
|
601
588
|
const categoryFilters = filters.filter((filter) => filter.type === "category");
|
|
602
|
-
// Search in main categories first
|
|
603
589
|
for (const categoryFilter of categoryFilters) {
|
|
604
590
|
if (categoryFilter.value === slug) {
|
|
605
591
|
return categoryFilter.label;
|
|
606
592
|
}
|
|
607
|
-
// Search in subcategories (options)
|
|
608
593
|
const subcategory = categoryFilter.options.find((option) => option.value === slug);
|
|
609
594
|
if (subcategory) {
|
|
610
595
|
return subcategory.label;
|
|
@@ -677,11 +662,9 @@ let CorasLandingPage = class CorasLandingPage extends ErrorModalMixin(PointsMixi
|
|
|
677
662
|
}
|
|
678
663
|
updateSelectedPriceOptions(key) {
|
|
679
664
|
if (this.selectedPriceOptions.includes(key)) {
|
|
680
|
-
// If clicking the same option, deselect it (clear all)
|
|
681
665
|
this.selectedPriceOptions = [];
|
|
682
666
|
}
|
|
683
667
|
else {
|
|
684
|
-
// If clicking a different option, select only that one (single selection)
|
|
685
668
|
this.selectedPriceOptions = [key];
|
|
686
669
|
}
|
|
687
670
|
this.requestUpdate();
|
|
@@ -708,7 +691,7 @@ let CorasLandingPage = class CorasLandingPage extends ErrorModalMixin(PointsMixi
|
|
|
708
691
|
`category-${index}`,
|
|
709
692
|
media: [],
|
|
710
693
|
subcategories: categoryFilter.options.map((option, subIndex) => ({
|
|
711
|
-
id: subIndex + 1000,
|
|
694
|
+
id: subIndex + 1000,
|
|
712
695
|
name: option.label,
|
|
713
696
|
slug: option.value,
|
|
714
697
|
media: [],
|
|
@@ -719,7 +702,7 @@ let CorasLandingPage = class CorasLandingPage extends ErrorModalMixin(PointsMixi
|
|
|
719
702
|
renderCategoriesTree() {
|
|
720
703
|
return this.filtersTask.render({
|
|
721
704
|
error: () => html `error`,
|
|
722
|
-
|
|
705
|
+
pending: () => this.renderFiltersSkeleton(),
|
|
723
706
|
complete: (filters) => {
|
|
724
707
|
if (!filters.data)
|
|
725
708
|
return nothing;
|
|
@@ -727,7 +710,7 @@ let CorasLandingPage = class CorasLandingPage extends ErrorModalMixin(PointsMixi
|
|
|
727
710
|
return html `
|
|
728
711
|
<coras-categories-tree
|
|
729
712
|
.categories=${transformedCategories}
|
|
730
|
-
selectedCategories=${this.
|
|
713
|
+
.selectedCategories=${this._selectedCategories}
|
|
731
714
|
@selection-changed=${(event) => {
|
|
732
715
|
this._selectedCategories = event.detail;
|
|
733
716
|
event.stopPropagation();
|
|
@@ -754,7 +737,7 @@ let CorasLandingPage = class CorasLandingPage extends ErrorModalMixin(PointsMixi
|
|
|
754
737
|
renderFiltersContent() {
|
|
755
738
|
return this.filtersTask.render({
|
|
756
739
|
error: () => html `error`,
|
|
757
|
-
|
|
740
|
+
pending: () => this.renderFiltersSkeleton(),
|
|
758
741
|
complete: (filters) => {
|
|
759
742
|
if (!filters.data)
|
|
760
743
|
return nothing;
|
|
@@ -789,22 +772,6 @@ let CorasLandingPage = class CorasLandingPage extends ErrorModalMixin(PointsMixi
|
|
|
789
772
|
}
|
|
790
773
|
renderShowMoreButton(_) {
|
|
791
774
|
return html `<span class="show-more-button" aria-hidden="true"></span>`;
|
|
792
|
-
// return html`
|
|
793
|
-
// <coras-button
|
|
794
|
-
// class="show-more-button"
|
|
795
|
-
// variant="text"
|
|
796
|
-
// @click=${() =>
|
|
797
|
-
// this.dispatchPageUpdate({
|
|
798
|
-
// city: params.city || this.city || undefined,
|
|
799
|
-
// country: params.country || this.country || undefined,
|
|
800
|
-
// categories: params.category?.join(",") || undefined,
|
|
801
|
-
// sorting: params.sorting || undefined,
|
|
802
|
-
// startDate: params.date_start || undefined,
|
|
803
|
-
// })}
|
|
804
|
-
// >
|
|
805
|
-
// ${msg("Show more")}
|
|
806
|
-
// </coras-button>
|
|
807
|
-
// `;
|
|
808
775
|
}
|
|
809
776
|
renderPoints(price) {
|
|
810
777
|
if (this.calculateRewardPoints) {
|
|
@@ -899,13 +866,37 @@ let CorasLandingPage = class CorasLandingPage extends ErrorModalMixin(PointsMixi
|
|
|
899
866
|
</div>
|
|
900
867
|
`;
|
|
901
868
|
}
|
|
869
|
+
renderAttractionsSkeleton() {
|
|
870
|
+
return html `
|
|
871
|
+
<section class="landing-skeleton" aria-hidden="true">
|
|
872
|
+
${Array.from({ length: 2 }, () => html `
|
|
873
|
+
<div class="sk-section">
|
|
874
|
+
<div class="coras-skeleton sk-title"></div>
|
|
875
|
+
<div class="sk-cards">
|
|
876
|
+
${Array.from({ length: 4 }, () => html `<div class="coras-skeleton sk-card"></div>`)}
|
|
877
|
+
</div>
|
|
878
|
+
</div>
|
|
879
|
+
`)}
|
|
880
|
+
</section>
|
|
881
|
+
<span class="coras-sr-only" role="status">${msg("Loading")}</span>
|
|
882
|
+
`;
|
|
883
|
+
}
|
|
884
|
+
renderFiltersSkeleton() {
|
|
885
|
+
return html `
|
|
886
|
+
<div class="filters-skeleton" aria-hidden="true">
|
|
887
|
+
${Array.from({ length: 5 }, (_, index) => html `<div
|
|
888
|
+
class="coras-skeleton sk-line ${index % 2 ? "sk-short" : ""}"
|
|
889
|
+
></div>`)}
|
|
890
|
+
</div>
|
|
891
|
+
`;
|
|
892
|
+
}
|
|
902
893
|
renderAttractions() {
|
|
903
894
|
return this.attractionsSearchTask.render({
|
|
904
895
|
error: () => {
|
|
905
896
|
this.showErrorModalOnce();
|
|
906
897
|
return html ``;
|
|
907
898
|
},
|
|
908
|
-
|
|
899
|
+
pending: () => this.renderAttractionsSkeleton(),
|
|
909
900
|
complete: (result) => {
|
|
910
901
|
if (!result.data)
|
|
911
902
|
return nothing;
|
|
@@ -994,6 +985,15 @@ __decorate([
|
|
|
994
985
|
__decorate([
|
|
995
986
|
state()
|
|
996
987
|
], CorasLandingPage.prototype, "isFiltersDrawerOpened", void 0);
|
|
988
|
+
__decorate([
|
|
989
|
+
state()
|
|
990
|
+
], CorasLandingPage.prototype, "selectedPriceOptions", void 0);
|
|
991
|
+
__decorate([
|
|
992
|
+
state()
|
|
993
|
+
], CorasLandingPage.prototype, "selectedDurationOptions", void 0);
|
|
994
|
+
__decorate([
|
|
995
|
+
state()
|
|
996
|
+
], CorasLandingPage.prototype, "_selectedCategories", void 0);
|
|
997
997
|
__decorate([
|
|
998
998
|
state()
|
|
999
999
|
], CorasLandingPage.prototype, "activeCategorySlugs", void 0);
|
|
@@ -1,12 +1,78 @@
|
|
|
1
1
|
import { css } from "lit";
|
|
2
2
|
import component from "../../styles/defaults/component.js";
|
|
3
|
+
import { skeleton, visuallyHidden } from "../../styles/primitives.js";
|
|
3
4
|
export default css `
|
|
4
5
|
${component}
|
|
6
|
+
${skeleton}
|
|
7
|
+
${visuallyHidden}
|
|
8
|
+
|
|
9
|
+
.landing-skeleton {
|
|
10
|
+
display: flex;
|
|
11
|
+
flex-direction: column;
|
|
12
|
+
gap: 2.5rem;
|
|
13
|
+
|
|
14
|
+
.sk-section {
|
|
15
|
+
display: flex;
|
|
16
|
+
flex-direction: column;
|
|
17
|
+
gap: 1.25rem;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.sk-title {
|
|
21
|
+
margin-inline: 1rem;
|
|
22
|
+
width: 18rem;
|
|
23
|
+
max-width: 60%;
|
|
24
|
+
height: 1.75rem;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.sk-cards {
|
|
28
|
+
display: flex;
|
|
29
|
+
gap: 1.25rem;
|
|
30
|
+
padding-inline: 1rem;
|
|
31
|
+
overflow: hidden;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.sk-card {
|
|
35
|
+
flex-shrink: 0;
|
|
36
|
+
width: 250px;
|
|
37
|
+
height: 380px;
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.filters-skeleton {
|
|
42
|
+
display: flex;
|
|
43
|
+
flex-direction: column;
|
|
44
|
+
gap: 1rem;
|
|
45
|
+
padding: 1rem;
|
|
46
|
+
|
|
47
|
+
.sk-line {
|
|
48
|
+
width: 100%;
|
|
49
|
+
height: 1.25rem;
|
|
50
|
+
|
|
51
|
+
&.sk-short {
|
|
52
|
+
width: 50%;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|
|
5
56
|
|
|
6
57
|
.calendar {
|
|
7
58
|
padding: 1rem;
|
|
8
59
|
}
|
|
9
60
|
|
|
61
|
+
.select-dates-container {
|
|
62
|
+
padding: 1rem;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
.select-dates-actions {
|
|
66
|
+
display: flex;
|
|
67
|
+
justify-content: space-between;
|
|
68
|
+
align-items: center;
|
|
69
|
+
gap: 1rem;
|
|
70
|
+
|
|
71
|
+
padding: 1rem 1.5rem;
|
|
72
|
+
border-top: 1px solid var(--coras-color-divider);
|
|
73
|
+
background-color: var(--coras-color-menu);
|
|
74
|
+
}
|
|
75
|
+
|
|
10
76
|
coras-layout {
|
|
11
77
|
container-type: inline-size;
|
|
12
78
|
container-name: coras-layout;
|
|
@@ -23,13 +89,14 @@ export default css `
|
|
|
23
89
|
column-gap: 0.5rem;
|
|
24
90
|
row-gap: 0.75rem;
|
|
25
91
|
padding-block: 1rem;
|
|
26
|
-
border-top: 1px solid var(--coras-color-
|
|
27
|
-
border-bottom: 1px solid var(--coras-color-
|
|
92
|
+
border-top: 1px solid var(--coras-color-divider);
|
|
93
|
+
border-bottom: 1px solid var(--coras-color-divider);
|
|
28
94
|
}
|
|
29
95
|
}
|
|
30
96
|
|
|
31
97
|
.attractions-sections {
|
|
32
98
|
.popular-title {
|
|
99
|
+
font-family: var(--coras-font-family-sans);
|
|
33
100
|
font-weight: var(--coras-font-weight-normal);
|
|
34
101
|
font-size: var(--coras-font-size-sm);
|
|
35
102
|
line-height: 16px;
|
|
@@ -43,7 +110,7 @@ export default css `
|
|
|
43
110
|
align-items: center;
|
|
44
111
|
gap: 1rem;
|
|
45
112
|
font-weight: 600;
|
|
46
|
-
font-size: 22px;
|
|
113
|
+
font-size: calc(22px * var(--coras-brand-heading-scale));
|
|
47
114
|
line-height: 30px;
|
|
48
115
|
letter-spacing: 0.2px;
|
|
49
116
|
}
|
|
@@ -5,50 +5,27 @@ export default css `
|
|
|
5
5
|
}
|
|
6
6
|
|
|
7
7
|
h2 {
|
|
8
|
-
font-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
);
|
|
12
|
-
line-height: var(
|
|
13
|
-
--payment-page-header-line-height,
|
|
14
|
-
var(--font-line-height-lg, 1.75rem)
|
|
15
|
-
);
|
|
8
|
+
font-family: var(--coras-font-family-heading);
|
|
9
|
+
font-size: var(--payment-page-header-font-size);
|
|
10
|
+
line-height: var(--payment-page-header-line-height);
|
|
16
11
|
font-weight: 600;
|
|
17
12
|
letter-spacing: 0.2px;
|
|
18
13
|
margin: 0 0 1rem 0;
|
|
19
|
-
color: var(--payment-page-header-color
|
|
14
|
+
color: var(--payment-page-header-color);
|
|
20
15
|
}
|
|
21
16
|
|
|
22
17
|
h3 {
|
|
23
|
-
font-size: var(
|
|
24
|
-
|
|
25
|
-
var(--font-size-2xl, 1.5rem)
|
|
26
|
-
);
|
|
27
|
-
font-weight: var(
|
|
28
|
-
--activities-details-label-font-weight,
|
|
29
|
-
var(--font-weight-semibold, 600)
|
|
30
|
-
);
|
|
18
|
+
font-size: var(--activities-details-label-font-size);
|
|
19
|
+
font-weight: var(--activities-details-label-font-weight);
|
|
31
20
|
margin: 0 0 0.75rem 0;
|
|
32
|
-
color: var(
|
|
33
|
-
--activities-details-label-color,
|
|
34
|
-
var(--color-text-primary, #161c44)
|
|
35
|
-
);
|
|
21
|
+
color: var(--activities-details-label-color);
|
|
36
22
|
}
|
|
37
23
|
|
|
38
24
|
h4 {
|
|
39
|
-
font-size: var(
|
|
40
|
-
|
|
41
|
-
var(--font-size-base, 1rem)
|
|
42
|
-
);
|
|
43
|
-
font-weight: var(
|
|
44
|
-
--activities-details-label-span-font-weight,
|
|
45
|
-
var(--font-weight-medium, 500)
|
|
46
|
-
);
|
|
25
|
+
font-size: var(--activities-details-label-span-font-size);
|
|
26
|
+
font-weight: var(--activities-details-label-span-font-weight);
|
|
47
27
|
margin: 0 0 0.25rem 0;
|
|
48
|
-
color: var(
|
|
49
|
-
--activities-details-label-color,
|
|
50
|
-
var(--color-text-primary, #161c44)
|
|
51
|
-
);
|
|
28
|
+
color: var(--activities-details-label-color);
|
|
52
29
|
}
|
|
53
30
|
|
|
54
31
|
.fields-container {
|
|
@@ -5,18 +5,13 @@ export default css `
|
|
|
5
5
|
}
|
|
6
6
|
|
|
7
7
|
h2 {
|
|
8
|
-
font-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
);
|
|
12
|
-
line-height: var(
|
|
13
|
-
--payment-page-header-line-height,
|
|
14
|
-
var(--font-line-height-lg, 1.75rem)
|
|
15
|
-
);
|
|
8
|
+
font-family: var(--coras-font-family-heading);
|
|
9
|
+
font-size: var(--payment-page-header-font-size);
|
|
10
|
+
line-height: var(--payment-page-header-line-height);
|
|
16
11
|
font-weight: 600;
|
|
17
12
|
letter-spacing: 0.2px;
|
|
18
13
|
margin: 0 0 1rem 0;
|
|
19
|
-
color: var(--payment-page-header-color
|
|
14
|
+
color: var(--payment-page-header-color);
|
|
20
15
|
}
|
|
21
16
|
|
|
22
17
|
.fields-container {
|
|
@@ -2,28 +2,28 @@ import { css } from "lit";
|
|
|
2
2
|
export default css `
|
|
3
3
|
:host {
|
|
4
4
|
--confirmation-text-color: var(--coras-color-text);
|
|
5
|
-
--confirmation-container-border-color: var(--coras-color-
|
|
5
|
+
--confirmation-container-border-color: var(--coras-color-card-border);
|
|
6
6
|
--confirmation-container-border-radius: var(--coras-radius-md);
|
|
7
|
-
--confirmation-divider-color: var(--coras-color-
|
|
7
|
+
--confirmation-divider-color: var(--coras-color-divider);
|
|
8
8
|
--confirmation-success-icon-color: var(--coras-color-text);
|
|
9
9
|
--confirmation-title-color: var(--coras-color-text);
|
|
10
10
|
--confirmation-title-font-size: var(--coras-font-size-2xl);
|
|
11
11
|
--confirmation-title-font-weight: var(--coras-font-weight-bold);
|
|
12
12
|
--confirmation-order-reference-font-size: var(--coras-font-size-lg);
|
|
13
13
|
--confirmation-email-font-size: var(--coras-font-size-base);
|
|
14
|
-
--confirmation-email-color: var(--coras-color-text-
|
|
14
|
+
--confirmation-email-color: var(--coras-color-text-muted);
|
|
15
15
|
--confirmation-ticket-title-font-size: var(--coras-font-size-xl);
|
|
16
16
|
--confirmation-ticket-title-font-weight: var(--coras-font-weight-bold);
|
|
17
17
|
--confirmation-ticket-title-color: var(--coras-color-text);
|
|
18
18
|
--confirmation-ticket-image-border-radius: var(--coras-radius-sm);
|
|
19
19
|
--confirmation-info-label-font-size: var(--coras-font-size-base);
|
|
20
|
-
--confirmation-info-label-color: var(--coras-color-text-
|
|
20
|
+
--confirmation-info-label-color: var(--coras-color-text-muted);
|
|
21
21
|
--confirmation-info-value-font-size: var(--coras-font-size-base);
|
|
22
22
|
--confirmation-info-value-font-weight: var(--coras-font-weight-medium);
|
|
23
23
|
--confirmation-info-value-color: var(--coras-color-text);
|
|
24
24
|
--confirmation-help-text-font-size: var(--coras-font-size-base);
|
|
25
|
-
--confirmation-help-text-color: var(--coras-color-text-
|
|
26
|
-
--confirmation-help-link-color: var(--coras-color-
|
|
25
|
+
--confirmation-help-text-color: var(--coras-color-text-muted);
|
|
26
|
+
--confirmation-help-link-color: var(--coras-color-link);
|
|
27
27
|
--confirmation-help-link-font-weight: var(--coras-font-weight-medium);
|
|
28
28
|
|
|
29
29
|
display: block;
|
|
@@ -15,8 +15,8 @@ export default css `
|
|
|
15
15
|
display: none;
|
|
16
16
|
}
|
|
17
17
|
|
|
18
|
-
-ms-overflow-style: none;
|
|
19
|
-
scrollbar-width: none;
|
|
18
|
+
-ms-overflow-style: none;
|
|
19
|
+
scrollbar-width: none;
|
|
20
20
|
|
|
21
21
|
.pickup-item {
|
|
22
22
|
cursor: pointer;
|
|
@@ -30,7 +30,7 @@ export default css `
|
|
|
30
30
|
&:hover {
|
|
31
31
|
background-color: color-mix(
|
|
32
32
|
in srgb,
|
|
33
|
-
var(--coras-color-error
|
|
33
|
+
var(--coras-color-error),
|
|
34
34
|
white 60%
|
|
35
35
|
);
|
|
36
36
|
}
|
|
@@ -38,7 +38,7 @@ export default css `
|
|
|
38
38
|
&.selected {
|
|
39
39
|
background-color: color-mix(
|
|
40
40
|
in srgb,
|
|
41
|
-
var(--coras-color-error
|
|
41
|
+
var(--coras-color-error),
|
|
42
42
|
white 60%
|
|
43
43
|
);
|
|
44
44
|
}
|
|
@@ -36,7 +36,7 @@ export declare class CorasStripe extends LitElement {
|
|
|
36
36
|
private isCardNumberValid;
|
|
37
37
|
private isCardExpiryValid;
|
|
38
38
|
private isCardCvcValid;
|
|
39
|
-
private
|
|
39
|
+
private portalUpdate;
|
|
40
40
|
connectedCallback(): void;
|
|
41
41
|
disconnectedCallback(): void;
|
|
42
42
|
protected firstUpdated(): void;
|
|
@@ -15,9 +15,9 @@ import "../../../../components/joined-fields/joined-fields.js";
|
|
|
15
15
|
import "../../../../components/input-field/input-field.js";
|
|
16
16
|
import styles from "./stripe.styles.js";
|
|
17
17
|
import { localized, msg } from "@lit/localize";
|
|
18
|
-
import { CSS_CLASSES, PLACEHOLDERS,
|
|
18
|
+
import { CSS_CLASSES, PLACEHOLDERS, INITIAL_PORTAL_UPDATE_DELAY_MS, } from "./stripe.constants.js";
|
|
19
19
|
import { fireInternalEvent, } from "../../../../core/events.js";
|
|
20
|
-
import { validateStripeKey, extractThemeColors, createStripeElementStyle, buildStripeAppearance, createPortalElement, positionPortalElement,
|
|
20
|
+
import { validateStripeKey, extractThemeColors, createStripeElementStyle, buildStripeAppearance, createPortalElement, positionPortalElement, createFrameThrottle, normalizeLocale, normalizeCountry, normalizeCurrency, } from "./stripe.utils.js";
|
|
21
21
|
let CorasStripe = class CorasStripe extends LitElement {
|
|
22
22
|
constructor() {
|
|
23
23
|
super(...arguments);
|
|
@@ -52,9 +52,9 @@ let CorasStripe = class CorasStripe extends LitElement {
|
|
|
52
52
|
this.isCardNumberValid = false;
|
|
53
53
|
this.isCardExpiryValid = false;
|
|
54
54
|
this.isCardCvcValid = false;
|
|
55
|
-
this.
|
|
55
|
+
this.portalUpdate = null;
|
|
56
56
|
this.handleWindowEvent = () => {
|
|
57
|
-
this.
|
|
57
|
+
this.portalUpdate?.execute();
|
|
58
58
|
};
|
|
59
59
|
this.handleCardChange = (event) => {
|
|
60
60
|
const errorMessage = event.error?.message ?? "";
|
|
@@ -113,11 +113,11 @@ let CorasStripe = class CorasStripe extends LitElement {
|
|
|
113
113
|
document.body.appendChild(this.cardNumberPortal);
|
|
114
114
|
document.body.appendChild(this.cardExpiryPortal);
|
|
115
115
|
document.body.appendChild(this.cardCvcPortal);
|
|
116
|
-
this.
|
|
116
|
+
this.portalUpdate = createFrameThrottle(() => this.positionAllPortals());
|
|
117
117
|
}
|
|
118
118
|
cleanupPortals() {
|
|
119
|
-
this.
|
|
120
|
-
this.
|
|
119
|
+
this.portalUpdate?.cancel();
|
|
120
|
+
this.portalUpdate = null;
|
|
121
121
|
this.cardNumberPortal?.remove();
|
|
122
122
|
this.cardExpiryPortal?.remove();
|
|
123
123
|
this.cardCvcPortal?.remove();
|
|
@@ -143,7 +143,7 @@ let CorasStripe = class CorasStripe extends LitElement {
|
|
|
143
143
|
this.intersectionObserver = null;
|
|
144
144
|
}
|
|
145
145
|
updatePortals() {
|
|
146
|
-
this.
|
|
146
|
+
this.portalUpdate?.execute();
|
|
147
147
|
}
|
|
148
148
|
positionAllPortals() {
|
|
149
149
|
const portals = [
|
|
@@ -190,7 +190,7 @@ let CorasStripe = class CorasStripe extends LitElement {
|
|
|
190
190
|
// Theme the hosted card iframe to match the embed's surface, brand, and
|
|
191
191
|
// colour scheme (light/dark) - the per-element style only sets text.
|
|
192
192
|
this.elements = this.stripe.elements({
|
|
193
|
-
appearance: buildStripeAppearance(
|
|
193
|
+
appearance: buildStripeAppearance(this),
|
|
194
194
|
});
|
|
195
195
|
this.initializeCardElement();
|
|
196
196
|
this.initializePaymentRequest();
|
|
@@ -256,11 +256,10 @@ let CorasStripe = class CorasStripe extends LitElement {
|
|
|
256
256
|
return;
|
|
257
257
|
}
|
|
258
258
|
this.destroyStripeElements();
|
|
259
|
-
const
|
|
260
|
-
const colors = extractThemeColors(computed);
|
|
259
|
+
const colors = extractThemeColors(this);
|
|
261
260
|
const baseStyle = createStripeElementStyle(colors);
|
|
262
261
|
// Re-theme on re-init so a colour-scheme change is reflected in the iframe.
|
|
263
|
-
this.elements.update({ appearance: buildStripeAppearance(
|
|
262
|
+
this.elements.update({ appearance: buildStripeAppearance(this) });
|
|
264
263
|
this.cardNumberElement = this.elements.create("cardNumber", {
|
|
265
264
|
style: baseStyle,
|
|
266
265
|
placeholder: PLACEHOLDERS.CARD_NUMBER,
|