ublo-lib 1.12.4 → 1.12.5

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.
@@ -189,7 +189,8 @@ const Calendar = ({
189
189
  setLastSelectedDate: setLastSelectedDate,
190
190
  singleDate: singleDate,
191
191
  submitOnSelectionEnd: submitOnSelectionEnd,
192
- onSubmit: submit
192
+ onSubmit: submit,
193
+ setShowPopup: setShowPopup
193
194
  }), !hide2ndMonth && _jsx(Month, {
194
195
  mode: mode,
195
196
  setMode: setMode,
@@ -79,6 +79,7 @@
79
79
  display: flex;
80
80
  flex-direction: column;
81
81
  text-align: center;
82
+ color: var(--ds-grey-600, #323338);
82
83
  }
83
84
 
84
85
  .lastName {
@@ -25,9 +25,11 @@ const PeriodPicker = ({
25
25
  }) => {
26
26
  const ref = React.useRef();
27
27
  const {
28
+ lang,
28
29
  config,
29
30
  cmsMode,
30
- metadata
31
+ metadata,
32
+ path
31
33
  } = useUbloContext();
32
34
  const {
33
35
  start,
@@ -103,7 +105,7 @@ const PeriodPicker = ({
103
105
  React.useEffect(() => {
104
106
  const stored = window.sessionStorage.getItem(WEEK_STORAGE);
105
107
  selectWeek(stored !== null ? Number(stored) : null, true);
106
- }, [selectWeek]);
108
+ }, [selectWeek, path, lang]);
107
109
  React.useEffect(() => {
108
110
  if (selected !== null && selected !== undefined) {
109
111
  const stored = window.sessionStorage.getItem(WEEK_STORAGE);
@@ -4,6 +4,7 @@ import classNames from "classnames";
4
4
  import Week from "./week";
5
5
  import { weekToLongDate, weekToDate, formatDate } from "./utils";
6
6
  import messages from "./messages";
7
+ import { useUbloContext } from "ublo/with-ublo";
7
8
  import { jsx as _jsx } from "react/jsx-runtime";
8
9
  import { Fragment as _Fragment } from "react/jsx-runtime";
9
10
  import { jsxs as _jsxs } from "react/jsx-runtime";
@@ -62,6 +63,9 @@ const WeekPicker = ({
62
63
  forceSeasonSwitch = false,
63
64
  onChange
64
65
  }) => {
66
+ const {
67
+ path
68
+ } = useUbloContext();
65
69
  const [isBrowser, setBrowser] = useState(false);
66
70
  const [warn, setWarn] = useState(-1);
67
71
  const [opened, setOpened] = useState(true);
@@ -112,7 +116,7 @@ const WeekPicker = ({
112
116
  const stored = window.sessionStorage.getItem(WEEK_STORAGE);
113
117
  selectWeek(stored !== null ? Number(stored) : null, true);
114
118
  setBrowser(true);
115
- }, [selectWeek]);
119
+ }, [selectWeek, lang, path]);
116
120
  useEffect(() => {
117
121
  if (selected !== null && selected !== undefined) {
118
122
  const stored = window.sessionStorage.getItem(WEEK_STORAGE);
@@ -4,6 +4,7 @@ import classNames from "classnames";
4
4
  import Week from "./week";
5
5
  import { weekToLongDate, weekToDate, formatDate } from "./utils";
6
6
  import messages from "./messages";
7
+ import { useUbloContext } from "ublo/with-ublo";
7
8
  import { jsx as _jsx } from "react/jsx-runtime";
8
9
  import { jsxs as _jsxs } from "react/jsx-runtime";
9
10
  import { Fragment as _Fragment } from "react/jsx-runtime";
@@ -62,6 +63,9 @@ const WeekPicker = ({
62
63
  forceSeasonSwitch = false,
63
64
  onChange
64
65
  }) => {
66
+ const {
67
+ path
68
+ } = useUbloContext();
65
69
  const [isBrowser, setBrowser] = useState(false);
66
70
  const [warn, setWarn] = useState(-1);
67
71
  const [opened, setOpened] = useState(true);
@@ -112,7 +116,7 @@ const WeekPicker = ({
112
116
  const stored = window.sessionStorage.getItem(WEEK_STORAGE);
113
117
  selectWeek(stored !== null ? Number(stored) : null, true);
114
118
  setBrowser(true);
115
- }, [selectWeek]);
119
+ }, [selectWeek, lang, path]);
116
120
  useEffect(() => {
117
121
  if (selected !== null && selected !== undefined) {
118
122
  const stored = window.sessionStorage.getItem(WEEK_STORAGE);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ublo-lib",
3
- "version": "1.12.4",
3
+ "version": "1.12.5",
4
4
  "peerDependencies": {
5
5
  "dt-design-system": "^2.1.0",
6
6
  "leaflet": "^1.9.1",