ublo-lib 1.47.1 → 1.47.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -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,QA6HP"}
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;AAYF,wBAAgB,IAAI,CAAC,EACnB,KAAK,EACL,YAAY,EAAE,WAAW,EACzB,QAAQ,EACR,KAAU,EACV,OAAO,EACP,MAAM,EACN,QAAgB,GACjB,EAAE,KAAK,QAgIP"}
@@ -96,6 +96,9 @@ export function MseM({ event, payment_type: paymentType, execcode, items = [], o
96
96
  }
97
97
  }
98
98
  else {
99
+ const isQuotation = checkQuotation(amount);
100
+ if (isQuotation)
101
+ return;
99
102
  sendGoal(name, { cartId, orderId, Code: execcode, stayFrom: stay?.from, rawData }, revenue);
100
103
  }
101
104
  break;
@@ -128,6 +131,11 @@ function formatPeekPerformancesItem(items) {
128
131
  };
129
132
  });
130
133
  }
134
+ function checkQuotation(amount) {
135
+ const search = window.location.search;
136
+ const hasQuotation = new URLSearchParams(search).has("hasQuotation");
137
+ return hasQuotation && amount === 0;
138
+ }
131
139
  function getStay() {
132
140
  const stay = window.sessionStorage.getItem("stay");
133
141
  if (stay) {
@@ -1 +1 @@
1
- {"version":3,"file":"scrollbar-size.d.ts","sourceRoot":"","sources":["../../../src/common/components/scrollbar-size.js"],"names":[],"mappings":"AAEA,iFA8BC"}
1
+ {"version":3,"file":"scrollbar-size.d.ts","sourceRoot":"","sources":["../../../src/common/components/scrollbar-size.js"],"names":[],"mappings":"AAEA,iFAwCC"}
@@ -1,4 +1,4 @@
1
- import { jsx as _jsx } from "react/jsx-runtime";
1
+ import { jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
2
2
  import * as React from "react";
3
3
  export default function ScrollbarSize() {
4
4
  const ref = React.useRef();
@@ -8,15 +8,21 @@ export default function ScrollbarSize() {
8
8
  setScrollbarSize(ref.current ? ref.current.offsetWidth - ref.current.clientWidth : 0);
9
9
  }
10
10
  }, [scrollbarSize]);
11
- return scrollbarSize !== undefined ? (_jsx("style", { jsx: true, global: true, children: `
12
- :root {
13
- --scrollbar-size: ${scrollbarSize}px;
14
- }
15
- ` })) : (_jsx("div", { ref: ref, style: {
16
- position: "absolute",
17
- top: "-9999px",
18
- width: "50px",
19
- height: "50px",
20
- overflow: "scroll",
21
- } }));
11
+ React.useEffect(() => {
12
+ if (scrollbarSize !== undefined) {
13
+ const styleTag = document.createElement("style");
14
+ styleTag.innerHTML = `:root { --scrollbar-size: ${scrollbarSize}px; }`;
15
+ document.head.appendChild(styleTag);
16
+ return () => {
17
+ document.head.removeChild(styleTag);
18
+ };
19
+ }
20
+ }, [scrollbarSize]);
21
+ return (_jsx(_Fragment, { children: scrollbarSize === undefined && (_jsx("div", { ref: ref, style: {
22
+ position: "absolute",
23
+ top: "-9999px",
24
+ width: "50px",
25
+ height: "50px",
26
+ overflow: "scroll",
27
+ } })) }));
22
28
  }
@@ -1 +1 @@
1
- {"version":3,"file":"filter.d.ts","sourceRoot":"","sources":["../../../../src/esf/components/magic-box/filter.js"],"names":[],"mappings":";AAOA;;;;;4CA2BC"}
1
+ {"version":3,"file":"filter.d.ts","sourceRoot":"","sources":["../../../../src/esf/components/magic-box/filter.js"],"names":[],"mappings":";AAOA;;;;;4CAkCC"}
@@ -11,10 +11,17 @@ const Filter = ({ code, filter, values, setValues }) => {
11
11
  const newValues = { ...values, [code]: value };
12
12
  setValues(newValues);
13
13
  };
14
- const formattedValues = filter.map(({ libelle, value }) => ({
15
- label: libelle,
16
- value,
17
- }));
14
+ const formattedValues = filter.map(({ libelle, value, restricted }) => {
15
+ let label = libelle;
16
+ if (restricted) {
17
+ label = `${libelle} (${message(lang, "unavailable")})`;
18
+ }
19
+ return {
20
+ label: libelle,
21
+ value,
22
+ disabled: restricted,
23
+ };
24
+ });
18
25
  const options = values.length === 1 ? formattedValues : [""].concat(formattedValues);
19
26
  const classes = classNames(css.filter, css[code]);
20
27
  return (_jsxs("div", { className: classes, children: [_jsx("div", { className: css.filterLabel, children: message(lang, code) }), _jsx(Select, { options: options, value: values[code], onValueChange: updateFilter })] }));
@@ -1 +1 @@
1
- {"version":3,"file":"magic-box.d.ts","sourceRoot":"","sources":["../../../../src/esf/components/magic-box/magic-box.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAiB/B,KAAK,IAAI,GAAG;IACV,IAAI,EAAE,MAAM,CAAC;IACb,EAAE,EAAE,MAAM,CAAC;CACZ,CAAC;AAEF,KAAK,cAAc,GACf,0BAA0B,GAC1B,sCAAsC,GACtC,8BAA8B,CAAC;AACnC,KAAK,WAAW,GACZ,oCAAoC,GACpC,gDAAgD,GAChD,wCAAwC,CAAC;AAC7C,KAAK,aAAa,GACd,oDAAoD,GACpD,gEAAgE,GAChE,wDAAwD,CAAC;AAE7D,KAAK,KAAK,GAAG;IACX,IAAI,CAAC,EAAE,IAAI,CAAC;IACZ,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,KAAK,GAAG,MAAM,CAAC;IACxB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,YAAY,CAAC,EAAE,MAAM,GAAG,QAAQ,GAAG,OAAO,CAAC;IAC3C,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,iBAAiB,CAAC,EAAE,MAAM,EAAE,CAAC;IAC7B,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;IACtB,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,cAAc,CAAC,EAAE,cAAc,CAAC;IAChC,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,aAAa,CAAC,EAAE,aAAa,CAAC;IAC9B,YAAY,CAAC,EAAE;QACb,KAAK,EAAE,MAAM,CAAC;QACd,WAAW,EAAE,MAAM,CAAC;QACpB,kBAAkB,EAAE,OAAO,CAAC;KAC7B,CAAC;CACH,CAAC;;AAIF,wBAAoC;AAEpC,iBAAS,QAAQ,CAAC,EAChB,IAAI,EACJ,OAAO,EACP,OAAe,EACf,SAAS,EACT,YAAY,EACZ,aAAa,EACb,OAAW,EACX,OAAkB,EAClB,iBAAiB,EACjB,UAAU,EACV,cAA2C,EAC3C,WAAkD,EAClD,aAAoE,EACpE,YAAY,EACZ,QAAQ,GACT,EAAE,KAAK,2CAoPP"}
1
+ {"version":3,"file":"magic-box.d.ts","sourceRoot":"","sources":["../../../../src/esf/components/magic-box/magic-box.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAiB/B,KAAK,IAAI,GAAG;IACV,IAAI,EAAE,MAAM,CAAC;IACb,EAAE,EAAE,MAAM,CAAC;CACZ,CAAC;AAEF,KAAK,cAAc,GACf,0BAA0B,GAC1B,sCAAsC,GACtC,8BAA8B,CAAC;AACnC,KAAK,WAAW,GACZ,oCAAoC,GACpC,gDAAgD,GAChD,wCAAwC,CAAC;AAC7C,KAAK,aAAa,GACd,oDAAoD,GACpD,gEAAgE,GAChE,wDAAwD,CAAC;AAE7D,KAAK,KAAK,GAAG;IACX,IAAI,CAAC,EAAE,IAAI,CAAC;IACZ,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,KAAK,GAAG,MAAM,CAAC;IACxB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,YAAY,CAAC,EAAE,MAAM,GAAG,QAAQ,GAAG,OAAO,CAAC;IAC3C,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,iBAAiB,CAAC,EAAE,MAAM,EAAE,CAAC;IAC7B,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;IACtB,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,cAAc,CAAC,EAAE,cAAc,CAAC;IAChC,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,aAAa,CAAC,EAAE,aAAa,CAAC;IAC9B,YAAY,CAAC,EAAE;QACb,KAAK,EAAE,MAAM,CAAC;QACd,WAAW,EAAE,MAAM,CAAC;QACpB,kBAAkB,EAAE,OAAO,CAAC;KAC7B,CAAC;CACH,CAAC;;AAIF,wBAAoC;AAEpC,iBAAS,QAAQ,CAAC,EAChB,IAAI,EACJ,OAAO,EACP,OAAe,EACf,SAAS,EACT,YAAY,EACZ,aAAa,EACb,OAAW,EACX,OAAkB,EAClB,iBAAiB,EACjB,UAAU,EACV,cAA2C,EAC3C,WAAkD,EAClD,aAAoE,EACpE,YAAY,EACZ,QAAQ,GACT,EAAE,KAAK,2CAkPP"}
@@ -93,7 +93,7 @@ function MagicBox({ stay, cartUrl, channel = "ESF", className, alignContent, max
93
93
  const mustFilterActivities = allowedActivities && allowedActivities.length > 0;
94
94
  const activities = filter.filter((item) => {
95
95
  if (mustFilterActivities) {
96
- return (!item.restricted && allowedActivities.includes(item.value));
96
+ return allowedActivities.includes(item.value);
97
97
  }
98
98
  return !item.restricted;
99
99
  });
@@ -1 +1 @@
1
- {"version":3,"file":"messages.d.ts","sourceRoot":"","sources":["../../../../src/esf/components/magic-box/messages.js"],"names":[],"mappings":"AAuCO,iDAIN"}
1
+ {"version":3,"file":"messages.d.ts","sourceRoot":"","sources":["../../../../src/esf/components/magic-box/messages.js"],"names":[],"mappings":"AAyCO,iDAIN"}
@@ -14,6 +14,7 @@ const locales = {
14
14
  "booking-block-day-minus-start": "Nous sommes à moins de ",
15
15
  "booking-block-day-minus-end": " jours de la date de début de votre séjour. La demande de réservation d'un moniteur n'est plus disponible. Vous pouvez venir au bureau esf à votre arrivée pour voir nos disponibilités de dernière minute.",
16
16
  "contact-us": "Nous contacter",
17
+ unavailable: "Indisponible",
17
18
  },
18
19
  en: {
19
20
  confirm: "Find an instructor",
@@ -30,6 +31,7 @@ const locales = {
30
31
  "booking-block-day-minus-start": "We are less than ",
31
32
  "booking-block-day-minus-end": " days from the start date of your stay. The request for booking an instructor is no longer available. You can come to the esf office upon arrival to see our last minute availability.",
32
33
  "contact-us": "Contact us",
34
+ unavailable: "Unavailable",
33
35
  },
34
36
  };
35
37
  export const message = (lang, id) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ublo-lib",
3
- "version": "1.47.1",
3
+ "version": "1.47.3",
4
4
  "peerDependencies": {
5
5
  "classnames": "^2.5.1",
6
6
  "dt-design-system": "^3.12.0",