ublo-lib 1.32.4 → 1.32.6

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.
Files changed (32) hide show
  1. package/es/common/components/custom-contact-form/attachment.js +2 -2
  2. package/es/common/components/custom-contact-form/utils.js +2 -2
  3. package/es/common/components/date-picker/calendar.js +2 -2
  4. package/es/common/components/date-picker/date-item.js +5 -5
  5. package/es/common/components/editable-calendar/calendar-editor.js +3 -3
  6. package/es/common/components/editable-map/popup-data.js +2 -2
  7. package/es/common/components/msem-preset-editor/editors/lodgings.js +5 -5
  8. package/es/common/components/msem-preset-editor/editors/ski-passes.js +2 -2
  9. package/es/common/components/msem-preset-editor/editors/standard-products.js +2 -2
  10. package/es/common/components/msem-preset-editor/editors/vakario.js +8 -8
  11. package/es/common/components/msem-preset-editor/msem-preset-editor.js +3 -3
  12. package/es/common/components/msem-preset-editor/services/offers.js +2 -2
  13. package/es/common/components/msem-preset-linker/components/resort-selector.js +2 -2
  14. package/es/common/components/plausible/services/callback.d.ts.map +1 -1
  15. package/es/common/components/plausible/services/callback.js +28 -12
  16. package/es/common/hooks/use-injected-cms-markup.js +2 -2
  17. package/es/esf/components/booking-form/field.js +2 -2
  18. package/es/esf/components/instructors-book/filters.js +3 -3
  19. package/es/esf/components/loyal-customers/components/field.js +2 -2
  20. package/es/esf/components/loyal-customers/content.js +4 -4
  21. package/es/esf/components/magic-box/filter.js +2 -2
  22. package/es/esf/components/magic-box/magic-box.js +2 -2
  23. package/es/esf/components/period-picker/date-display.js +2 -2
  24. package/es/esf/components/period-picker/days.js +2 -2
  25. package/es/esf/components/period-picker/title.js +2 -2
  26. package/es/esf/components/period-picker/weeks.d.ts.map +1 -1
  27. package/es/esf/components/period-picker/weeks.js +8 -5
  28. package/es/esf/components/period-picker/weeks.module.css +6 -0
  29. package/es/future/components/plausible/services/callback.d.ts.map +1 -1
  30. package/es/future/components/plausible/services/callback.js +28 -12
  31. package/es/lbm/components/lumiplan/weather/weather-days.js +2 -2
  32. package/package.json +1 -1
@@ -12,7 +12,7 @@ export default function Attachment({ lang, name, label, settings, data, setData,
12
12
  const items = data?.attachment?.value || [];
13
13
  const { attachmentAllowed, attachmentMaxSize, attachmentAuthorizedFormats, attachmentMaxFiles, } = settings;
14
14
  const splittedFormats = attachmentAuthorizedFormats?.split(",");
15
- const formatedAuthorizedFormats = splittedFormats?.map((format, i) => `${i > 0 ? "," : ""} ${getFormatName(format)}`);
15
+ const formattedAuthorizedFormats = splittedFormats?.map((format, i) => `${i > 0 ? "," : ""} ${getFormatName(format)}`);
16
16
  const handleDrop = React.useCallback((files) => {
17
17
  const authorizedSelectionFormats = files.every((file) => splittedFormats.includes(file.type));
18
18
  if (!authorizedSelectionFormats) {
@@ -102,7 +102,7 @@ export default function Attachment({ lang, name, label, settings, data, setData,
102
102
  });
103
103
  if (!attachmentAllowed)
104
104
  return null;
105
- return (_jsxs("div", { className: attachmentcss, children: [_jsxs("label", { className: css.label, htmlFor: name, children: [label && _jsx("span", { children: label }), _jsxs("div", { ref: ref, className: css.input, children: [items.length ? (_jsx("div", { className: css.items, children: Array.from(items).map((item, i) => (_jsx(Item, { item: item, removeItem: removeItem }, i))) })) : (_jsxs("div", { className: css.placeholder, children: [_jsx(Icons.Upload, { className: css.placeholderIcon }), Messages.get(lang, "attachmentPlaceholder")] })), (error || dragging) && (_jsx("div", { className: overlaycss, children: overlayMessage }))] }), _jsx("input", { id: name, className: css.uploadInput, type: "file", accept: attachmentAuthorizedFormats, disabled: !attachmentAllowed, onChange: onChange, multiple: attachmentMaxFiles > 1 })] }), _jsxs("div", { className: css.helper, children: [_jsx("b", { children: attachmentMaxFiles }), " ", Messages.get(lang, "attachmentHelper1"), ".", " ", _jsx("b", { children: attachmentMaxSize }), Messages.get(lang, "attachmentHelper2"), ".", " ", Messages.get(lang, "attachmentHelper3"), " ", _jsx("b", { children: formatedAuthorizedFormats }), "."] })] }));
105
+ return (_jsxs("div", { className: attachmentcss, children: [_jsxs("label", { className: css.label, htmlFor: name, children: [label && _jsx("span", { children: label }), _jsxs("div", { ref: ref, className: css.input, children: [items.length ? (_jsx("div", { className: css.items, children: Array.from(items).map((item, i) => (_jsx(Item, { item: item, removeItem: removeItem }, i))) })) : (_jsxs("div", { className: css.placeholder, children: [_jsx(Icons.Upload, { className: css.placeholderIcon }), Messages.get(lang, "attachmentPlaceholder")] })), (error || dragging) && (_jsx("div", { className: overlaycss, children: overlayMessage }))] }), _jsx("input", { id: name, className: css.uploadInput, type: "file", accept: attachmentAuthorizedFormats, disabled: !attachmentAllowed, onChange: onChange, multiple: attachmentMaxFiles > 1 })] }), _jsxs("div", { className: css.helper, children: [_jsx("b", { children: attachmentMaxFiles }), " ", Messages.get(lang, "attachmentHelper1"), ".", " ", _jsx("b", { children: attachmentMaxSize }), Messages.get(lang, "attachmentHelper2"), ".", " ", Messages.get(lang, "attachmentHelper3"), " ", _jsx("b", { children: formattedAuthorizedFormats }), "."] })] }));
106
106
  }
107
107
  function Item({ item, removeItem }) {
108
108
  const { name } = item;
@@ -83,10 +83,10 @@ export const send = async ({ site, data, fields, subjectPrefix, subjectSuffix, k
83
83
  }
84
84
  else {
85
85
  const { formatter } = fields[key];
86
- const formatedValue = typeof formatter === "function"
86
+ const formattedValue = typeof formatter === "function"
87
87
  ? formatter(data[key].value)
88
88
  : data[key].value;
89
- formData.append(key, formatedValue);
89
+ formData.append(key, formattedValue);
90
90
  }
91
91
  });
92
92
  if (subjectPrefix) {
@@ -98,10 +98,10 @@ export default function Calendar({ date, display, stayDates = [], min, max, onSu
98
98
  try {
99
99
  const { stays } = await fetcher({ ...rest, start, numberDays });
100
100
  if (stays?.length) {
101
- const formatedStays = stays.map((stay) => {
101
+ const formattedStays = stays.map((stay) => {
102
102
  return { start: new Date(stay.start), end: new Date(stay.end) };
103
103
  });
104
- setStays(formatedStays);
104
+ setStays(formattedStays);
105
105
  }
106
106
  }
107
107
  catch (e) {
@@ -26,11 +26,11 @@ export default function DateItem({ date, index, month, year, min, max, selectedD
26
26
  const enableAvailability = Boolean(stays);
27
27
  const isAvailable = stays?.some((stay) => {
28
28
  const { start, end } = stay;
29
- const formatedStart = Utils.formatDate(start);
30
- const formatedEnd = Utils.formatDate(end);
31
- const formatedDate = Utils.formatDate(_date);
32
- return (formatedStart === formatedDate ||
33
- (selecting && formatedEnd === formatedDate));
29
+ const formattedStart = Utils.formatDate(start);
30
+ const formattedEnd = Utils.formatDate(end);
31
+ const formattedDate = Utils.formatDate(_date);
32
+ return (formattedStart === formattedDate ||
33
+ (selecting && formattedEnd === formattedDate));
34
34
  }) || false;
35
35
  const shortestMatchingStaysLength = enableAvailability &&
36
36
  matchingStays?.reduce((acc, stay) => {
@@ -6,11 +6,11 @@ import css from "./calendar-editor.module.css";
6
6
  import * as Utils from "./utils";
7
7
  export default function CalendarEditor({ presets, setPresets, hoveredDates, closeEditor, }) {
8
8
  const { colors, dates = {} } = presets;
9
- const formatedHoveredDates = hoveredDates.map((date) => {
9
+ const formattedHoveredDates = hoveredDates.map((date) => {
10
10
  return Utils.formatDate(date);
11
11
  });
12
12
  const updateDates = (colorIndex) => () => {
13
- const newDates = formatedHoveredDates.reduce((acc, date) => {
13
+ const newDates = formattedHoveredDates.reduce((acc, date) => {
14
14
  if (!colorIndex)
15
15
  return acc;
16
16
  return { ...acc, [date]: colorIndex };
@@ -19,7 +19,7 @@ export default function CalendarEditor({ presets, setPresets, hoveredDates, clos
19
19
  dates: { ...dates, ...newDates },
20
20
  };
21
21
  if (!colorIndex) {
22
- for (const date of formatedHoveredDates) {
22
+ for (const date of formattedHoveredDates) {
23
23
  delete newPresets.dates[date];
24
24
  }
25
25
  }
@@ -7,6 +7,6 @@ export default function PopupData({ marker }) {
7
7
  const isExternalUrl = /^((http|https):\/\/)/.test(url);
8
8
  const target = isExternalUrl ? "_blank" : undefined;
9
9
  const rel = isExternalUrl ? "noopener" : undefined;
10
- const formatedDescription = description.replace(/\n/g, "<br />");
11
- return (_jsxs("div", { className: css.data, children: [_jsx("div", { className: css.title, children: title }), formatedDescription && (_jsx("div", { className: css.description, dangerouslySetInnerHTML: { __html: formatedDescription } })), url?.trim() && (_jsx(Button, { tag: "a", href: url.trim(), className: css.link, target: target, rel: rel, children: label || "En savoir plus" }))] }));
10
+ const formattedDescription = description.replace(/\n/g, "<br />");
11
+ return (_jsxs("div", { className: css.data, children: [_jsx("div", { className: css.title, children: title }), formattedDescription && (_jsx("div", { className: css.description, dangerouslySetInnerHTML: { __html: formattedDescription } })), url?.trim() && (_jsx(Button, { tag: "a", href: url.trim(), className: css.link, target: target, rel: rel, children: label || "En savoir plus" }))] }));
12
12
  }
@@ -44,11 +44,11 @@ export default function Lodgings({ preset, setPreset, setShowPresetDialog, testP
44
44
  const updateFilter = (kind) => (newValue) => {
45
45
  setData((data) => ({ ...data, [kind]: newValue.map((v) => v.value) }));
46
46
  };
47
- const formatedLodgings = lodgings.map((lodging) => ({
47
+ const formattedLodgings = lodgings.map((lodging) => ({
48
48
  value: lodging.slug,
49
49
  label: lodging.name,
50
50
  }));
51
- const formatedRooms = rooms.map((room) => ({
51
+ const formattedRooms = rooms.map((room) => ({
52
52
  label: room.title,
53
53
  value: room.type,
54
54
  }));
@@ -67,7 +67,7 @@ export default function Lodgings({ preset, setPreset, setShowPresetDialog, testP
67
67
  try {
68
68
  setLoading(true);
69
69
  const filters = await API.getLodgingFilters(channel, resort, facet);
70
- const formatedFilters = Object.keys(filters).reduce((acc, key) => {
70
+ const formattedFilters = Object.keys(filters).reduce((acc, key) => {
71
71
  if (key === "accomodations")
72
72
  return acc;
73
73
  const filter = filters[key];
@@ -87,7 +87,7 @@ export default function Lodgings({ preset, setPreset, setShowPresetDialog, testP
87
87
  }
88
88
  }, {});
89
89
  setLogings(filters.accomodations);
90
- setFilters(formatedFilters);
90
+ setFilters(formattedFilters);
91
91
  setReady(true);
92
92
  }
93
93
  catch (e) {
@@ -170,7 +170,7 @@ export default function Lodgings({ preset, setPreset, setShowPresetDialog, testP
170
170
  testPreset,
171
171
  cancelPreset,
172
172
  confirmPreset,
173
- }, children: [_jsx("div", { className: css.label, children: "Nombre de personnes" }), _jsxs("div", { className: css.row, children: [_jsx(NumberPicker, { className: css.peopleInput, label: "Adultes", min: 0, max: 20, value: data.adults, onChange: updateField("adults"), withInput: true }), _jsx(NumberPicker, { className: css.peopleInput, label: "Enfants", min: 0, max: 9, value: data.children, onChange: updateField("children"), withInput: true })] }), _jsx("div", { className: css.label, children: "H\u00E9bergement" }), _jsx(Select, { placeholder: "S\u00E9lectionnez un h\u00E9bergement", options: formatedLodgings, value: data.lodging, onValueChange: updateField("lodging"), loading: loading }), showLodgingPageCheckbox && (_jsx(Checkbox, { label: "Ouvrir la page du site", checked: data.openPage, disabled: !showLodgingPageCheckbox, onCheckedChange: updateField("openPage") })), !showFilters && (_jsxs(_Fragment, { children: [_jsx("div", { className: css.label, children: "Chambres" }), (formatedRooms?.length > 0 || loading) && (_jsx(Select, { label: "Type de bien", placeholder: "S\u00E9lectionnez un type de bien", value: data.roomType, options: formatedRooms, loading: loading, onValueChange: updateField("roomType") })), _jsx(NumberPicker, { label: "Nombre de chambres", min: 0, max: 20, value: data.nbRooms?.[0] || 0, onChange: updateRoomNb, withInput: true })] })), showFilters && (_jsxs(_Fragment, { children: [_jsx("div", { className: css.label, children: "Filtres" }), kinds.length > 1 && (_jsx(Select, { label: "Type", placeholder: "S\u00E9lectionnez un type", options: kinds, value: data.type, onValueChange: updateField("type"), loading: loading })), filters?.options && filters?.options?.length > 1 && (_jsx(MultipleSelect, { placeholder: "Selectionnez une ou plusieurs options", label: "Options", options: filters.options, values: selectedOptions, onChange: updateFilter("options"), loading: loading })), filters?.districts && filters?.districts?.length > 1 && (_jsx(MultipleSelect, { placeholder: "Selectionnez une ou plusieurs options", label: "Quartiers", options: filters.districts, values: selectedDistricts, onChange: updateFilter("districts"), loading: loading }))] }))] }));
173
+ }, children: [_jsx("div", { className: css.label, children: "Nombre de personnes" }), _jsxs("div", { className: css.row, children: [_jsx(NumberPicker, { className: css.peopleInput, label: "Adultes", min: 0, max: 20, value: data.adults, onChange: updateField("adults"), withInput: true }), _jsx(NumberPicker, { className: css.peopleInput, label: "Enfants", min: 0, max: 9, value: data.children, onChange: updateField("children"), withInput: true })] }), _jsx("div", { className: css.label, children: "H\u00E9bergement" }), _jsx(Select, { placeholder: "S\u00E9lectionnez un h\u00E9bergement", options: formattedLodgings, value: data.lodging, onValueChange: updateField("lodging"), loading: loading }), showLodgingPageCheckbox && (_jsx(Checkbox, { label: "Ouvrir la page du site", checked: data.openPage, disabled: !showLodgingPageCheckbox, onCheckedChange: updateField("openPage") })), !showFilters && (_jsxs(_Fragment, { children: [_jsx("div", { className: css.label, children: "Chambres" }), (formattedRooms?.length > 0 || loading) && (_jsx(Select, { label: "Type de bien", placeholder: "S\u00E9lectionnez un type de bien", value: data.roomType, options: formattedRooms, loading: loading, onValueChange: updateField("roomType") })), _jsx(NumberPicker, { label: "Nombre de chambres", min: 0, max: 20, value: data.nbRooms?.[0] || 0, onChange: updateRoomNb, withInput: true })] })), showFilters && (_jsxs(_Fragment, { children: [_jsx("div", { className: css.label, children: "Filtres" }), kinds.length > 1 && (_jsx(Select, { label: "Type", placeholder: "S\u00E9lectionnez un type", options: kinds, value: data.type, onValueChange: updateField("type"), loading: loading })), filters?.options && filters?.options?.length > 1 && (_jsx(MultipleSelect, { placeholder: "Selectionnez une ou plusieurs options", label: "Options", options: filters.options, values: selectedOptions, onChange: updateFilter("options"), loading: loading })), filters?.districts && filters?.districts?.length > 1 && (_jsx(MultipleSelect, { placeholder: "Selectionnez une ou plusieurs options", label: "Quartiers", options: filters.districts, values: selectedDistricts, onChange: updateFilter("districts"), loading: loading }))] }))] }));
174
174
  }
175
175
  function getDefaultData(preset) {
176
176
  if (!preset?.presets && !preset?.options)
@@ -45,7 +45,7 @@ export default function SkiPasses({ preset, setPreset, stay, setShowPresetDialog
45
45
  const { tags } = domain;
46
46
  if (!tags?.length)
47
47
  return acc;
48
- const formatedTags = tags
48
+ const formattedTags = tags
49
49
  .filter((tag) => {
50
50
  return (Object.keys(ACTIVITIES_LABELS).includes(tag) &&
51
51
  !acc.some((item) => item.value === tag));
@@ -53,7 +53,7 @@ export default function SkiPasses({ preset, setPreset, stay, setShowPresetDialog
53
53
  .map((tag) => {
54
54
  return { value: tag, label: ACTIVITIES_LABELS[tag] || tag };
55
55
  });
56
- return [...acc, ...formatedTags];
56
+ return [...acc, ...formattedTags];
57
57
  }, [])),
58
58
  ]
59
59
  : []);
@@ -11,7 +11,7 @@ export default function StandardProducts({ preset, setPreset, facet, setShowPres
11
11
  const [loading, setLoading] = React.useState(false);
12
12
  const [productCategories, setProductCategories] = React.useState([]);
13
13
  const [selectedProductCategory, setSelectedProductCategory] = React.useState(getDefaultData(preset));
14
- const formatedCategories = productCategories.map(({ name, slug }) => {
14
+ const formattedCategories = productCategories.map(({ name, slug }) => {
15
15
  return { label: name, value: slug };
16
16
  });
17
17
  const { merchant } = preset?.options || {};
@@ -55,7 +55,7 @@ export default function StandardProducts({ preset, setPreset, facet, setShowPres
55
55
  testPreset,
56
56
  cancelPreset,
57
57
  confirmPreset: selectedProductCategory ? confirmPreset : undefined,
58
- }, children: _jsx(Select, { label: "Cat\u00E9gorie de produit", placeholder: "S\u00E9lectionnez une cat\u00E9gorie", options: formatedCategories, value: selectedProductCategory, onValueChange: setSelectedProductCategory, disabled: loading }) }));
58
+ }, children: _jsx(Select, { label: "Cat\u00E9gorie de produit", placeholder: "S\u00E9lectionnez une cat\u00E9gorie", options: formattedCategories, value: selectedProductCategory, onValueChange: setSelectedProductCategory, disabled: loading }) }));
59
59
  }
60
60
  function getDefaultData(preset) {
61
61
  if (!preset?.presets)
@@ -50,11 +50,11 @@ export default function Vakario({ preset, setPreset, setShowPresetDialog, onChan
50
50
  try {
51
51
  setLoading(true);
52
52
  const kinds = await API.getVakarioKinds(channel, merchant);
53
- const formatedKinds = kinds.map(({ code, name }) => ({
53
+ const formattedKinds = kinds.map(({ code, name }) => ({
54
54
  label: name,
55
55
  value: code,
56
56
  }));
57
- setKindCodes(formatedKinds);
57
+ setKindCodes(formattedKinds);
58
58
  setData((data) => ({
59
59
  ...data,
60
60
  ageCodes: "",
@@ -77,11 +77,11 @@ export default function Vakario({ preset, setPreset, setShowPresetDialog, onChan
77
77
  try {
78
78
  setLoading(true);
79
79
  const ages = await API.getVakarioAges(channel, merchant, data.kindCodes);
80
- const formatedAges = ages.map(({ code, name }) => ({
80
+ const formattedAges = ages.map(({ code, name }) => ({
81
81
  label: name,
82
82
  value: code,
83
83
  }));
84
- setAgeCodes(formatedAges);
84
+ setAgeCodes(formattedAges);
85
85
  setData((data) => ({ ...data, categoryCodes: "", levelCodes: "" }));
86
86
  }
87
87
  catch (e) {
@@ -100,11 +100,11 @@ export default function Vakario({ preset, setPreset, setShowPresetDialog, onChan
100
100
  try {
101
101
  setLoading(true);
102
102
  const categories = await API.getVakarioCategories(channel, merchant, data.kindCodes, data.ageCodes);
103
- const formatedCategories = categories.map(({ code, name }) => ({
103
+ const formattedCategories = categories.map(({ code, name }) => ({
104
104
  label: name,
105
105
  value: code,
106
106
  }));
107
- setCategoryCodes(formatedCategories);
107
+ setCategoryCodes(formattedCategories);
108
108
  setData((data) => ({ ...data, levelCodes: "" }));
109
109
  }
110
110
  catch (e) {
@@ -123,11 +123,11 @@ export default function Vakario({ preset, setPreset, setShowPresetDialog, onChan
123
123
  try {
124
124
  setLoading(true);
125
125
  const levels = await API.getVakarioLevels(channel, merchant, data.kindCodes, data.ageCodes, data.categoryCodes);
126
- const formatedLevels = levels.map(({ code, name }) => ({
126
+ const formattedLevels = levels.map(({ code, name }) => ({
127
127
  label: name,
128
128
  value: code,
129
129
  }));
130
- setLevelCodes(formatedLevels);
130
+ setLevelCodes(formattedLevels);
131
131
  }
132
132
  catch (e) {
133
133
  console.error(e);
@@ -44,10 +44,10 @@ export default function MseMPresetEditor({ lang, options, urls, selectedPreset,
44
44
  return;
45
45
  }
46
46
  if (subPreset) {
47
- const formatedSubPreset = Preset.format(subPreset);
47
+ const formattedSubPreset = Preset.format(subPreset);
48
48
  name = subPreset.name;
49
- itemOptions = formatedSubPreset.options;
50
- itemPresets = formatedSubPreset.presets;
49
+ itemOptions = formattedSubPreset.options;
50
+ itemPresets = formattedSubPreset.presets;
51
51
  }
52
52
  if (stay?.from && stay?.to) {
53
53
  itemPresets = { ...itemPresets, stay };
@@ -1,7 +1,7 @@
1
1
  import * as API from "./api";
2
2
  export async function get(lang, channel, resort, facet) {
3
3
  const offers = (await API.getOffers(lang, channel, resort, facet));
4
- const formatedOffers = await Promise.all(offers.map(async (offer) => {
4
+ const formattedOffers = await Promise.all(offers.map(async (offer) => {
5
5
  const { widget, category, kind, options, preset } = offer;
6
6
  const isSkiSchool = kind === "SKISCHOOL";
7
7
  const hasCategoryGroup = !!options?.categoryGroup || isSkiSchool;
@@ -31,7 +31,7 @@ export async function get(lang, channel, resort, facet) {
31
31
  }
32
32
  return offer;
33
33
  }));
34
- return formatedOffers;
34
+ return formattedOffers;
35
35
  }
36
36
  function mergeSkiPasses(offer) {
37
37
  const { items = [], ...rest } = offer;
@@ -1,12 +1,12 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import Select from "dt-design-system/es/select";
3
3
  export default function ResortSelector({ resorts, resort, setResort }) {
4
- const formatedResorts = resorts.map((resort) => ({
4
+ const formattedResorts = resorts.map((resort) => ({
5
5
  label: resort.label,
6
6
  value: String(resort.resort),
7
7
  }));
8
8
  return (_jsx(Select, { value: resort, onValueChange: setResort, label: "Destination", options: [
9
9
  { label: "Sélectionnez une destination pour continuer", value: "" },
10
- ...formatedResorts,
10
+ ...formattedResorts,
11
11
  ] }));
12
12
  }
@@ -1 +1 @@
1
- {"version":3,"file":"callback.d.ts","sourceRoot":"","sources":["../../../../../src/common/components/plausible/services/callback.ts"],"names":[],"mappings":"AAEA,KAAK,IAAI,GAAG;IACV,OAAO,EAAE;QACP,SAAS,EAAE,MAAM,CAAC;QAClB,UAAU,EAAE,MAAM,CAAC;QACnB,aAAa,EAAE,MAAM,CAAC;QACtB,cAAc,EAAE,MAAM,CAAC;QACvB,cAAc,EAAE,MAAM,CAAC;QACvB,YAAY,EAAE,MAAM,CAAC;QACrB,KAAK,EAAE,MAAM,CAAC;QACd,QAAQ,EAAE,MAAM,CAAC;KAClB,CAAC;CACH,CAAC;AAEF,KAAK,KAAK,GAAG;IACX,KAAK,EAAE,MAAM,CAAC;IACd,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,IAAI,EAAE,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAkBF,wBAAgB,IAAI,CAAC,EACnB,KAAK,EACL,YAAY,EAAE,WAAW,EACzB,QAAQ,EACR,KAAU,EACV,OAAO,EACP,MAAM,EACN,QAAgB,GACjB,EAAE,KAAK,QA6GP"}
1
+ {"version":3,"file":"callback.d.ts","sourceRoot":"","sources":["../../../../../src/common/components/plausible/services/callback.ts"],"names":[],"mappings":"AAEA,KAAK,IAAI,GAAG;IACV,OAAO,EAAE;QACP,SAAS,EAAE,MAAM,CAAC;QAClB,UAAU,EAAE,MAAM,CAAC;QACnB,aAAa,EAAE,MAAM,CAAC;QACtB,cAAc,EAAE,MAAM,CAAC;QACvB,cAAc,EAAE,MAAM,CAAC;QACvB,YAAY,EAAE,MAAM,CAAC;QACrB,KAAK,EAAE,MAAM,CAAC;QACd,QAAQ,EAAE,MAAM,CAAC;KAClB,CAAC;CACH,CAAC;AAEF,KAAK,KAAK,GAAG;IACX,KAAK,EAAE,MAAM,CAAC;IACd,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,IAAI,EAAE,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAkBF,wBAAgB,IAAI,CAAC,EACnB,KAAK,EACL,YAAY,EAAE,WAAW,EACzB,QAAQ,EACR,KAAU,EACV,OAAO,EACP,MAAM,EACN,QAAgB,GACjB,EAAE,KAAK,QA6HP"}
@@ -26,33 +26,49 @@ export function MseM({ event, payment_type: paymentType, execcode, items = [], o
26
26
  };
27
27
  switch (event) {
28
28
  case "view_item": {
29
- const formatedItems = formatPeekPerformancesItem(items);
30
- const rawData = JSON.stringify({ products: formatedItems, hoteId, stay });
29
+ const formattedItems = formatPeekPerformancesItem(items);
30
+ const rawData = JSON.stringify({
31
+ products: formattedItems,
32
+ hoteId,
33
+ stay,
34
+ });
31
35
  sendGoal(name, { ...firstProductProps, stayFrom: stay?.from, rawData });
32
36
  break;
33
37
  }
34
38
  case "add_to_cart": {
35
- const formatedItems = formatPeekPerformancesItem(items);
36
- const rawData = JSON.stringify({ products: formatedItems, hoteId, stay });
39
+ const formattedItems = formatPeekPerformancesItem(items);
40
+ const rawData = JSON.stringify({
41
+ products: formattedItems,
42
+ hoteId,
43
+ stay,
44
+ });
37
45
  sendGoal(name, { ...firstProductProps, stayFrom: stay?.from, rawData }, revenue);
38
46
  break;
39
47
  }
40
48
  case "remove_from_cart": {
41
- const formatedItems = formatPeekPerformancesItem(items);
42
- const rawData = JSON.stringify({ products: formatedItems, hoteId, stay });
49
+ const formattedItems = formatPeekPerformancesItem(items);
50
+ const rawData = JSON.stringify({
51
+ products: formattedItems,
52
+ hoteId,
53
+ stay,
54
+ });
43
55
  sendGoal(name, { ...firstProductProps, stayFrom: stay?.from, rawData }, revenue);
44
56
  break;
45
57
  }
46
58
  case "checkout": {
47
- const formatedItems = formatPeekPerformancesItem(items);
48
- const rawData = JSON.stringify({ products: formatedItems, hoteId, stay });
59
+ const formattedItems = formatPeekPerformancesItem(items);
60
+ const rawData = JSON.stringify({
61
+ products: formattedItems,
62
+ hoteId,
63
+ stay,
64
+ });
49
65
  sendGoal(name, { cartId, stayFrom: stay?.from, rawData }, revenue);
50
66
  break;
51
67
  }
52
68
  case "add_payment_info": {
53
- const formatedItems = formatPeekPerformancesItem(items);
69
+ const formattedItems = formatPeekPerformancesItem(items);
54
70
  const rawData = JSON.stringify({
55
- products: formatedItems,
71
+ products: formattedItems,
56
72
  hoteId,
57
73
  stay,
58
74
  paymentMethod: paymentType,
@@ -62,10 +78,10 @@ export function MseM({ event, payment_type: paymentType, execcode, items = [], o
62
78
  }
63
79
  case "purchase": {
64
80
  const isFailure = execcode !== "0000";
65
- const formatedItems = formatPeekPerformancesItem(items);
81
+ const formattedItems = formatPeekPerformancesItem(items);
66
82
  const attempts = (cartId && getPurchaseAttempts()[cartId]) || 0;
67
83
  const rawData = JSON.stringify({
68
- products: formatedItems,
84
+ products: formattedItems,
69
85
  hoteId,
70
86
  stay,
71
87
  attempts,
@@ -22,11 +22,11 @@ const useInjectedCmsMarkup = (entries, isReady) => {
22
22
  if (!target?.markup)
23
23
  return;
24
24
  if (isArray) {
25
- const formatedRows = value.map((v) => {
25
+ const formattedRows = value.map((v) => {
26
26
  return { name: v, markup: `<tr><td>${v}</td></tr>` };
27
27
  });
28
28
  const [anchor] = target.markup;
29
- target.markup = anchor ? [anchor, ...formatedRows] : formatedRows;
29
+ target.markup = anchor ? [anchor, ...formattedRows] : formattedRows;
30
30
  }
31
31
  else {
32
32
  target.markup = value;
@@ -24,12 +24,12 @@ const getOptions = (lang, options) => {
24
24
  value: "",
25
25
  disabled: true,
26
26
  };
27
- const formatedOptions = options[lang].map((option) => {
27
+ const formattedOptions = options[lang].map((option) => {
28
28
  const isTitle = option.startsWith("--");
29
29
  const label = isTitle ? option.replace("--", "") : option;
30
30
  return { label, value: option, disabled: isTitle };
31
31
  });
32
- return [emptyOption, ...formatedOptions];
32
+ return [emptyOption, ...formattedOptions];
33
33
  };
34
34
  const Field = ({ lang, index, name, field, data, setData }) => {
35
35
  const { type, icon, label, options, required, placeholder, fullWidth, hidden, } = field;
@@ -8,19 +8,19 @@ import { message } from "./messages";
8
8
  export default function Filters({ context, search, activity, language, updateFilter, loading, }) {
9
9
  const { lang } = useUbloContext();
10
10
  const { disciplines: activities, langues: languages } = context;
11
- const formatedActivities = [
11
+ const formattedActivities = [
12
12
  "",
13
13
  ...activities.map(({ code, label }) => ({
14
14
  label,
15
15
  value: code,
16
16
  })),
17
17
  ];
18
- const formatedLanguages = [
18
+ const formattedLanguages = [
19
19
  "",
20
20
  ...languages.map(({ code, label }) => ({
21
21
  label,
22
22
  value: code,
23
23
  })),
24
24
  ];
25
- return (_jsxs("div", { className: css.container, children: [_jsx(Input, { icon: "Search", label: message(lang, "search-label"), placeholder: message(lang, "search-placeholder"), value: search, onValueChange: updateFilter("search") }), _jsx(Select, { icon: "Filter", label: message(lang, "activity-label"), value: activity, options: formatedActivities, onValueChange: updateFilter("activity"), loading: loading }), _jsx(Select, { icon: "Globe", label: message(lang, "language-label"), value: language, options: formatedLanguages, onValueChange: updateFilter("language"), loading: loading })] }));
25
+ return (_jsxs("div", { className: css.container, children: [_jsx(Input, { icon: "Search", label: message(lang, "search-label"), placeholder: message(lang, "search-placeholder"), value: search, onValueChange: updateFilter("search") }), _jsx(Select, { icon: "Filter", label: message(lang, "activity-label"), value: activity, options: formattedActivities, onValueChange: updateFilter("activity"), loading: loading }), _jsx(Select, { icon: "Globe", label: message(lang, "language-label"), value: language, options: formattedLanguages, onValueChange: updateFilter("language"), loading: loading })] }));
26
26
  }
@@ -63,7 +63,7 @@ const renderField = (lang, label, classes, name, field, data, setData) => {
63
63
  newData[name].validator = isValid;
64
64
  }
65
65
  };
66
- const formatedOptions = type === "select"
66
+ const formattedOptions = type === "select"
67
67
  ? [{ label: Messages.get(lang, "select"), value: "" }].concat(optionsToDisplay.map((option) => {
68
68
  return {
69
69
  label: option.label?.[lang],
@@ -71,7 +71,7 @@ const renderField = (lang, label, classes, name, field, data, setData) => {
71
71
  };
72
72
  }))
73
73
  : undefined;
74
- return _jsx(Tag, { onValueChange: onChange, options: formatedOptions, ...props });
74
+ return _jsx(Tag, { onValueChange: onChange, options: formattedOptions, ...props });
75
75
  };
76
76
  const Field = ({ lang, name, field, data, setData }) => {
77
77
  const { label, required, hidden } = field;
@@ -15,15 +15,15 @@ export const getData = (product, selectors, levels, handleVariants, convertTable
15
15
  ? classList.reduce((acc, className) => Object.keys(levels).includes(className) ? className : acc, null)
16
16
  : undefined;
17
17
  const selectedOption = getSelectedOption(product, options, convertTableToSelect);
18
- const formatedTitle = title
18
+ const formattedTitle = title
19
19
  ?.map((element) => element.textContent)
20
20
  .join(" - ");
21
- const formatedPrice = price
21
+ const formattedPrice = price
22
22
  ? parseInt(price.textContent.replace(/€/g, "").trim())
23
23
  : 0;
24
24
  return {
25
- title: formatedTitle || "",
26
- price: formatedPrice,
25
+ title: formattedTitle || "",
26
+ price: formattedPrice,
27
27
  details: details?.innerText || "",
28
28
  selectedOption,
29
29
  productCategory,
@@ -11,11 +11,11 @@ const Filter = ({ code, filter, values, setValues }) => {
11
11
  const newValues = { ...values, [code]: value };
12
12
  setValues(newValues);
13
13
  };
14
- const formatedValues = filter.map(({ libelle, value }) => ({
14
+ const formattedValues = filter.map(({ libelle, value }) => ({
15
15
  label: libelle,
16
16
  value,
17
17
  }));
18
- const options = values.length === 1 ? formatedValues : [""].concat(formatedValues);
18
+ const options = values.length === 1 ? formattedValues : [""].concat(formattedValues);
19
19
  const classes = classNames(css.filter, css[code]);
20
20
  return (_jsxs("div", { className: classes, children: [_jsx("div", { className: css.filterLabel, children: message(lang, code) }), _jsx(Select, { options: options, value: values[code], onValueChange: updateFilter })] }));
21
21
  };
@@ -75,11 +75,11 @@ function MagicBox({ stay, cartUrl, channel = "ESF", className, alignContent, max
75
75
  const filterWithoutRestricted = filter.filter((item) => !item.restricted);
76
76
  return { ...acc, [key]: filterWithoutRestricted };
77
77
  }, {});
78
- const formatedCategories = categoryList?.map(({ code, label }) => {
78
+ const formattedCategories = categoryList?.map(({ code, label }) => {
79
79
  return { value: code, libelle: label };
80
80
  });
81
81
  const allFilters = categories
82
- ? { ...newFilters, categories: formatedCategories }
82
+ ? { ...newFilters, categories: formattedCategories }
83
83
  : newFilters;
84
84
  setFilters(allFilters);
85
85
  }
@@ -35,6 +35,6 @@ export default function DateDisplay({ className }) {
35
35
  }, [getStoredStay, metadata?.disableWeekpicker, updateStay]);
36
36
  if (!extend || !stay || metadata?.disableWeekpicker)
37
37
  return null;
38
- const formatedStay = Stay.formatStay(lang, stay);
39
- return (_jsxs("div", { className: classes, children: [Messages.get(lang, "offers"), " ", _jsx("span", { className: css.dates, children: formatedStay.split(" ").map((word, index) => (_jsx(motion.span, { className: css.word, transition: { delayChildren: index * 0.05, staggerChildren: 0.05 }, initial: "hidden", animate: "visible", children: word.split("").map((letter, index) => (_jsx(motion.span, { className: css.letter, variants: Motions.character, children: letter }, `${letter}-${index}`))) }, `${word}-${index}`))) })] }));
38
+ const formattedStay = Stay.formatStay(lang, stay);
39
+ return (_jsxs("div", { className: classes, children: [Messages.get(lang, "offers"), " ", _jsx("span", { className: css.dates, children: formattedStay.split(" ").map((word, index) => (_jsx(motion.span, { className: css.word, transition: { delayChildren: index * 0.05, staggerChildren: 0.05 }, initial: "hidden", animate: "visible", children: word.split("").map((letter, index) => (_jsx(motion.span, { className: css.letter, variants: Motions.character, children: letter }, `${letter}-${index}`))) }, `${word}-${index}`))) })] }));
40
40
  }
@@ -55,7 +55,7 @@ function Day({ lang, index, day, fullStay, firstSelected, updateSelection }) {
55
55
  const currMonth = day.getMonth();
56
56
  const hasMonthChanged = prevMonth !== currMonth;
57
57
  const showMonth = index === 0 || hasMonthChanged;
58
- const formatedMonth = day.toLocaleString(locale, { month: "short" });
58
+ const formattedMonth = day.toLocaleString(locale, { month: "short" });
59
59
  const classes = classNames(css.day, {
60
60
  [css.firstSelected]: isFirstSelected,
61
61
  [css.dayFirstInStay]: !firstSelected && isFirstDayOfStay,
@@ -63,5 +63,5 @@ function Day({ lang, index, day, fullStay, firstSelected, updateSelection }) {
63
63
  [css.dayBoundary]: !firstSelected && (isFirstDayOfStay || isLastDayOfStay),
64
64
  [css.dayInStay]: !firstSelected && isInStay,
65
65
  });
66
- return (_jsxs("div", { className: classes, children: [_jsx("div", { className: css.weekday, children: dayLabel }), _jsx("div", { className: css.dayBottom, children: _jsx("button", { className: css.dayNumber, onClick: updateSelection(day), children: _jsx("span", { className: css.dayNumberText, children: dayNumber }) }) }), showMonth && _jsx("span", { className: css.month, children: formatedMonth })] }));
66
+ return (_jsxs("div", { className: classes, children: [_jsx("div", { className: css.weekday, children: dayLabel }), _jsx("div", { className: css.dayBottom, children: _jsx("button", { className: css.dayNumber, onClick: updateSelection(day), children: _jsx("span", { className: css.dayNumberText, children: dayNumber }) }) }), showMonth && _jsx("span", { className: css.month, children: formattedMonth })] }));
67
67
  }
@@ -7,6 +7,6 @@ export default function Title({ lang, stay }) {
7
7
  if (!stay) {
8
8
  return (_jsx("div", { className: css.title, dangerouslySetInnerHTML: { __html: Messages.get(lang, "title") } }));
9
9
  }
10
- const formatedStay = Stay.formatStay(lang, stay);
11
- return (_jsxs("div", { className: css.title, children: [Messages.get(lang, "selected-title"), " ", _jsx("b", { children: formatedStay })] }));
10
+ const formattedStay = Stay.formatStay(lang, stay);
11
+ return (_jsxs("div", { className: css.title, children: [Messages.get(lang, "selected-title"), " ", _jsx("b", { children: formattedStay })] }));
12
12
  }
@@ -1 +1 @@
1
- {"version":3,"file":"weeks.d.ts","sourceRoot":"","sources":["../../../../src/esf/components/period-picker/weeks.js"],"names":[],"mappings":";AAaA,+EAyCG;uBAtDoB,OAAO"}
1
+ {"version":3,"file":"weeks.d.ts","sourceRoot":"","sources":["../../../../src/esf/components/period-picker/weeks.js"],"names":[],"mappings":";AAaA,+EA6CG;uBA1DoB,OAAO"}
@@ -1,4 +1,4 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
1
+ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
2
  import * as React from "react";
3
3
  import classNames from "classnames";
4
4
  import getConfig from "next/config";
@@ -9,7 +9,7 @@ import * as Dates from "./services/dates";
9
9
  import * as Messages from "./messages";
10
10
  import css from "./weeks.module.css";
11
11
  const { publicRuntimeConfig } = getConfig();
12
- const { periods } = publicRuntimeConfig.season;
12
+ const { periods } = publicRuntimeConfig.season || {};
13
13
  const Weeks = React.forwardRef(({ weeks, lang, ...props }, ref) => {
14
14
  React.useEffect(() => {
15
15
  const bar = ref.current;
@@ -21,7 +21,10 @@ const Weeks = React.forwardRef(({ weeks, lang, ...props }, ref) => {
21
21
  const { clientWidth, offsetLeft } = selectedItem;
22
22
  bar.scrollLeft = offsetLeft - clientWidth * 1.5;
23
23
  }, [props.selected, ref]);
24
- return (_jsxs(LayoutGroup, { children: [_jsx("div", { ref: ref, className: css.weeks, children: weeks.map((week) => (_jsx(Week, { lang: lang, week: week, ...props }, week))) }), periods && (_jsxs("div", { className: css.nomenclature, children: [periods.high?.length > 0 && (_jsxs("div", { className: css.period, "data-period": "high", children: [_jsx("div", { className: css.pill }), Messages.get(lang, "high-period")] })), periods.medium?.length > 0 && (_jsxs("div", { className: css.period, "data-period": "medium", children: [_jsx("div", { className: css.pill }), Messages.get(lang, "medium-period")] })), periods.low?.length > 0 && (_jsxs("div", { className: css.period, "data-period": "low", children: [_jsx("div", { className: css.pill }), Messages.get(lang, "low-period")] }))] }))] }));
24
+ const classes = classNames(css.weeks, {
25
+ [css.withPeriods]: periods,
26
+ });
27
+ return (_jsxs(LayoutGroup, { children: [_jsx("div", { ref: ref, className: classes, children: weeks.map((week) => (_jsx(Week, { lang: lang, week: week, ...props }, week))) }), periods && (_jsxs("div", { className: css.nomenclature, children: [periods.high?.length > 0 && (_jsxs("div", { className: css.period, "data-period": "high", children: [_jsx("div", { className: css.pill }), Messages.get(lang, "high-period")] })), periods.medium?.length > 0 && (_jsxs("div", { className: css.period, "data-period": "medium", children: [_jsx("div", { className: css.pill }), Messages.get(lang, "medium-period")] })), periods.low?.length > 0 && (_jsxs("div", { className: css.period, "data-period": "low", children: [_jsx("div", { className: css.pill }), Messages.get(lang, "low-period")] }))] }))] }));
25
28
  });
26
29
  Weeks.displayName = "Weeks";
27
30
  export default Weeks;
@@ -45,7 +48,7 @@ function Week({ lang, week, beginWeek, endWeek, selected, select, forceSeasonSwi
45
48
  const hasMonthChanged = prevMonth !== currMonth;
46
49
  const showMonth = isFirst || hasMonthChanged;
47
50
  const locale = Dates.locales[lang] || Dates.locales.en;
48
- const formatedMonth = currDate.toLocaleString(locale, { month: "short" });
51
+ const formattedMonth = currDate.toLocaleString(locale, { month: "short" });
49
52
  const weekClasses = classNames(css.item, {
50
53
  [css.selected]: isSelected,
51
54
  [css.past]: isPast,
@@ -63,5 +66,5 @@ function Week({ lang, week, beginWeek, endWeek, selected, select, forceSeasonSwi
63
66
  }, 1200));
64
67
  };
65
68
  const layoutId = isPopup ? "current-popup" : "current";
66
- return (_jsxs("div", { className: weekClasses, children: [_jsxs(Button, { className: css.button, onClick: selectWeek, "aria-label": `${Dates.weekToLongDate(week)} - ${Dates.weekToLongDate(week + 1)}`, disabled: isPast, children: [isSelected && (_jsx(motion.div, { layoutId: layoutId, className: css.buttonFiller })), checkVisible && _jsx(Icons.CheckCircle, { className: css.check })] }), _jsxs("div", { className: css.date, children: [_jsx("div", { className: css.dateFrom, children: Dates.formatShort(currDate) }), isLast && (_jsx("div", { className: css.dateTo, children: Dates.formatShort(nextDate) }))] }), showMonth && (_jsxs("span", { className: css.month, children: [formatedMonth, " ", showYear && _jsx("b", { className: css.year, children: currYear })] }))] }));
69
+ return (_jsxs("div", { className: weekClasses, children: [_jsx(Button, { className: css.button, onClick: selectWeek, "aria-label": `${Dates.weekToLongDate(week)} - ${Dates.weekToLongDate(week + 1)}`, disabled: isPast, children: !periods && (_jsxs(_Fragment, { children: [isSelected && (_jsx(motion.div, { layoutId: layoutId, className: css.buttonFiller })), checkVisible && _jsx(Icons.CheckCircle, { className: css.check })] })) }), _jsxs("div", { className: css.date, children: [_jsx("div", { className: css.dateFrom, children: Dates.formatShort(currDate) }), isLast && (_jsx("div", { className: css.dateTo, children: Dates.formatShort(nextDate) }))] }), showMonth && (_jsxs("span", { className: css.month, children: [formattedMonth, " ", showYear && _jsx("b", { className: css.year, children: currYear })] }))] }));
67
70
  }
@@ -128,6 +128,12 @@ button.button {
128
128
  background-color: var(--ds-grey-500, #484848);
129
129
  }
130
130
 
131
+ .weeks.withPeriods .selected button.button {
132
+ outline: 2px solid var(--ds-primary, var(--ds-blue-500, #002dcc));
133
+ outline-offset: -1px;
134
+ border-radius: var(--ds-radius-100, 4px);
135
+ }
136
+
131
137
  .buttonFiller {
132
138
  position: relative;
133
139
  width: calc(100% + var(--gap) * 2);
@@ -1 +1 @@
1
- {"version":3,"file":"callback.d.ts","sourceRoot":"","sources":["../../../../../src/future/components/plausible/services/callback.ts"],"names":[],"mappings":"AAEA,KAAK,IAAI,GAAG;IACV,OAAO,EAAE;QACP,SAAS,EAAE,MAAM,CAAC;QAClB,UAAU,EAAE,MAAM,CAAC;QACnB,aAAa,EAAE,MAAM,CAAC;QACtB,cAAc,EAAE,MAAM,CAAC;QACvB,cAAc,EAAE,MAAM,CAAC;QACvB,YAAY,EAAE,MAAM,CAAC;QACrB,KAAK,EAAE,MAAM,CAAC;QACd,QAAQ,EAAE,MAAM,CAAC;KAClB,CAAC;CACH,CAAC;AAEF,KAAK,KAAK,GAAG;IACX,KAAK,EAAE,MAAM,CAAC;IACd,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,IAAI,EAAE,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAkBF,wBAAgB,IAAI,CAAC,EACnB,KAAK,EACL,YAAY,EAAE,WAAW,EACzB,QAAQ,EACR,KAAU,EACV,OAAO,EACP,MAAM,EACN,QAAgB,GACjB,EAAE,KAAK,QA6GP"}
1
+ {"version":3,"file":"callback.d.ts","sourceRoot":"","sources":["../../../../../src/future/components/plausible/services/callback.ts"],"names":[],"mappings":"AAEA,KAAK,IAAI,GAAG;IACV,OAAO,EAAE;QACP,SAAS,EAAE,MAAM,CAAC;QAClB,UAAU,EAAE,MAAM,CAAC;QACnB,aAAa,EAAE,MAAM,CAAC;QACtB,cAAc,EAAE,MAAM,CAAC;QACvB,cAAc,EAAE,MAAM,CAAC;QACvB,YAAY,EAAE,MAAM,CAAC;QACrB,KAAK,EAAE,MAAM,CAAC;QACd,QAAQ,EAAE,MAAM,CAAC;KAClB,CAAC;CACH,CAAC;AAEF,KAAK,KAAK,GAAG;IACX,KAAK,EAAE,MAAM,CAAC;IACd,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,IAAI,EAAE,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAkBF,wBAAgB,IAAI,CAAC,EACnB,KAAK,EACL,YAAY,EAAE,WAAW,EACzB,QAAQ,EACR,KAAU,EACV,OAAO,EACP,MAAM,EACN,QAAgB,GACjB,EAAE,KAAK,QA6HP"}
@@ -26,33 +26,49 @@ export function MseM({ event, payment_type: paymentType, execcode, items = [], o
26
26
  };
27
27
  switch (event) {
28
28
  case "view_item": {
29
- const formatedItems = formatPeekPerformancesItem(items);
30
- const rawData = JSON.stringify({ products: formatedItems, hoteId, stay });
29
+ const formattedItems = formatPeekPerformancesItem(items);
30
+ const rawData = JSON.stringify({
31
+ products: formattedItems,
32
+ hoteId,
33
+ stay,
34
+ });
31
35
  sendGoal(name, { ...firstProductProps, stayFrom: stay?.from, rawData });
32
36
  break;
33
37
  }
34
38
  case "add_to_cart": {
35
- const formatedItems = formatPeekPerformancesItem(items);
36
- const rawData = JSON.stringify({ products: formatedItems, hoteId, stay });
39
+ const formattedItems = formatPeekPerformancesItem(items);
40
+ const rawData = JSON.stringify({
41
+ products: formattedItems,
42
+ hoteId,
43
+ stay,
44
+ });
37
45
  sendGoal(name, { ...firstProductProps, stayFrom: stay?.from, rawData }, revenue);
38
46
  break;
39
47
  }
40
48
  case "remove_from_cart": {
41
- const formatedItems = formatPeekPerformancesItem(items);
42
- const rawData = JSON.stringify({ products: formatedItems, hoteId, stay });
49
+ const formattedItems = formatPeekPerformancesItem(items);
50
+ const rawData = JSON.stringify({
51
+ products: formattedItems,
52
+ hoteId,
53
+ stay,
54
+ });
43
55
  sendGoal(name, { ...firstProductProps, stayFrom: stay?.from, rawData }, revenue);
44
56
  break;
45
57
  }
46
58
  case "checkout": {
47
- const formatedItems = formatPeekPerformancesItem(items);
48
- const rawData = JSON.stringify({ products: formatedItems, hoteId, stay });
59
+ const formattedItems = formatPeekPerformancesItem(items);
60
+ const rawData = JSON.stringify({
61
+ products: formattedItems,
62
+ hoteId,
63
+ stay,
64
+ });
49
65
  sendGoal(name, { cartId, stayFrom: stay?.from, rawData }, revenue);
50
66
  break;
51
67
  }
52
68
  case "add_payment_info": {
53
- const formatedItems = formatPeekPerformancesItem(items);
69
+ const formattedItems = formatPeekPerformancesItem(items);
54
70
  const rawData = JSON.stringify({
55
- products: formatedItems,
71
+ products: formattedItems,
56
72
  hoteId,
57
73
  stay,
58
74
  paymentMethod: paymentType,
@@ -62,10 +78,10 @@ export function MseM({ event, payment_type: paymentType, execcode, items = [], o
62
78
  }
63
79
  case "purchase": {
64
80
  const isFailure = execcode !== "0000";
65
- const formatedItems = formatPeekPerformancesItem(items);
81
+ const formattedItems = formatPeekPerformancesItem(items);
66
82
  const attempts = (cartId && getPurchaseAttempts()[cartId]) || 0;
67
83
  const rawData = JSON.stringify({
68
- products: formatedItems,
84
+ products: formattedItems,
69
85
  hoteId,
70
86
  stay,
71
87
  attempts,
@@ -40,7 +40,7 @@ export default function Days({ days, currentDayIndex, setCurrentDayIndex, lang,
40
40
  const today = new Date(date).toLocaleDateString(locale, {
41
41
  weekday: "long",
42
42
  });
43
- const formatedDate = new Date(date).toLocaleDateString(locale, {
43
+ const formattedDate = new Date(date).toLocaleDateString(locale, {
44
44
  day: "2-digit",
45
45
  month: "2-digit",
46
46
  year: "numeric",
@@ -48,6 +48,6 @@ export default function Days({ days, currentDayIndex, setCurrentDayIndex, lang,
48
48
  const classes = classNames(css.day, {
49
49
  [css.daySelected]: isSelected,
50
50
  });
51
- return (_jsxs(Button, { className: classes, onClick: updateCurrentDay, children: [_jsx("b", { children: isToday ? _jsx(T, { id: "weather.today" }) : today }), formatedDate] }, date));
51
+ return (_jsxs(Button, { className: classes, onClick: updateCurrentDay, children: [_jsx("b", { children: isToday ? _jsx(T, { id: "weather.today" }) : today }), formattedDate] }, date));
52
52
  }) }) }));
53
53
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ublo-lib",
3
- "version": "1.32.4",
3
+ "version": "1.32.6",
4
4
  "peerDependencies": {
5
5
  "dt-design-system": "^3.8.5",
6
6
  "leaflet": "^1.9.1",