ublo-lib 1.25.0 → 1.25.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -15,7 +15,6 @@ import * as Plausible from "./services/plausible";
15
15
  import styles from "./gesco-contact-form.module.css";
16
16
  import { jsx as _jsx } from "react/jsx-runtime";
17
17
  import { jsxs as _jsxs } from "react/jsx-runtime";
18
- import { Fragment as _Fragment } from "react/jsx-runtime";
19
18
  export default function GescoContactForm({
20
19
  lang = "fr",
21
20
  channel = "ESF",
@@ -190,39 +189,37 @@ export default function GescoContactForm({
190
189
  options: categoryOptions,
191
190
  disabled: Boolean(error) || loading,
192
191
  required: true
193
- }), stayNeeded && _jsxs(_Fragment, {
194
- children: [_jsx(Input, {
195
- name: "stayFrom",
196
- className: styles.stayField,
197
- type: "date",
198
- label: messages.stayFromDate,
199
- placeholder: messages.dateFormat,
200
- onValueChange: updateStayToMin,
201
- hint: stayFromMax,
202
- min: stayMin,
203
- max: stayFromMax,
204
- disabled: Boolean(error) || loading,
205
- patternError: Messages.format(messages.mandatoryError, {
206
- label: messages.stayFrom
207
- }),
208
- extended: true,
209
- required: true
210
- }), _jsx(Input, {
211
- name: "stayTo",
212
- className: styles.stayField,
213
- type: "date",
214
- label: messages.stayToDate,
215
- placeholder: messages.dateFormat,
216
- onValueChange: updateStayFromMax,
217
- hint: stayToMin,
218
- min: stayToMin || stayMin,
219
- disabled: Boolean(error) || loading,
220
- patternError: Messages.format(messages.mandatoryError, {
221
- label: messages.stayTo
222
- }),
223
- extended: true,
224
- required: true
225
- })]
192
+ }), _jsx(Input, {
193
+ name: "stayFrom",
194
+ className: styles.stayField,
195
+ type: "date",
196
+ label: messages.stayFromDate,
197
+ placeholder: messages.dateFormat,
198
+ onValueChange: updateStayToMin,
199
+ hint: stayFromMax,
200
+ min: stayMin,
201
+ max: stayFromMax,
202
+ disabled: Boolean(error) || loading,
203
+ patternError: Messages.format(messages.mandatoryError, {
204
+ label: messages.stayFrom
205
+ }),
206
+ required: true,
207
+ extended: true
208
+ }), _jsx(Input, {
209
+ name: "stayTo",
210
+ className: styles.stayField,
211
+ type: "date",
212
+ label: messages.stayToDate,
213
+ placeholder: messages.dateFormat,
214
+ onValueChange: updateStayFromMax,
215
+ hint: stayToMin,
216
+ min: stayToMin || stayMin,
217
+ disabled: Boolean(error) || loading,
218
+ patternError: Messages.format(messages.mandatoryError, {
219
+ label: messages.stayTo
220
+ }),
221
+ required: true,
222
+ extended: true
226
223
  }), _jsx(Textarea, {
227
224
  name: "message",
228
225
  className: styles.fullWidthField,
@@ -50,10 +50,10 @@ export default function ScrollingCarousel({
50
50
  if (zone && inner) {
51
51
  const zoneContainer = zone;
52
52
  const innerContainer = inner;
53
- setOverflow(innerContainer.clientWidth < zoneContainer.clientWidth);
53
+ setOverflow(Math.round(innerContainer.clientWidth) < Math.round(zoneContainer.clientWidth));
54
54
  setControls({
55
- prevDisabled: innerContainer.scrollLeft === 0,
56
- nextDisabled: innerContainer.scrollLeft === Math.round(innerContainer.scrollWidth) - Math.round(innerContainer.clientWidth)
55
+ prevDisabled: Math.floor(innerContainer.scrollLeft) === 0,
56
+ nextDisabled: Math.round(innerContainer.scrollLeft) === Math.round(innerContainer.scrollWidth) - Math.round(innerContainer.clientWidth)
57
57
  });
58
58
  }
59
59
  }, []);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ublo-lib",
3
- "version": "1.25.0",
3
+ "version": "1.25.2",
4
4
  "peerDependencies": {
5
5
  "dt-design-system": "^3.1.5",
6
6
  "leaflet": "^1.9.1",