@trackunit/react-date-and-time-components 2.4.15 → 2.4.16-alpha-037fb409571.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/index.cjs.js CHANGED
@@ -702,7 +702,9 @@ const DayRangeSelect = ({ className, "data-testid": dataTestId, disabled = false
702
702
  return filterTemporalPeriodsInRange({ temporalPeriods: defaultCombinations, maxDaysInRange });
703
703
  }, [initialDateRangeOptions, filterTemporalPeriodsInRange, allowedDirection, maxDaysInRange]);
704
704
  const [temporalPeriods, setTemporalPeriods] = react.useState(defaultTemporalPeriods);
705
- const [dateRangeSearchValue, setDateRangeSearchValue] = react.useState();
705
+ // Starts as an empty string rather than undefined: clearing the search would otherwise switch the
706
+ // input from uncontrolled to controlled, which React warns about.
707
+ const [dateRangeSearchValue, setDateRangeSearchValue] = react.useState("");
706
708
  const [selectedRange, setSelectedRange] = react.useState();
707
709
  const currentSelectedRange = react.useMemo(() => {
708
710
  // Internal selected range takes precedence
package/index.esm.js CHANGED
@@ -700,7 +700,9 @@ const DayRangeSelect = ({ className, "data-testid": dataTestId, disabled = false
700
700
  return filterTemporalPeriodsInRange({ temporalPeriods: defaultCombinations, maxDaysInRange });
701
701
  }, [initialDateRangeOptions, filterTemporalPeriodsInRange, allowedDirection, maxDaysInRange]);
702
702
  const [temporalPeriods, setTemporalPeriods] = useState(defaultTemporalPeriods);
703
- const [dateRangeSearchValue, setDateRangeSearchValue] = useState();
703
+ // Starts as an empty string rather than undefined: clearing the search would otherwise switch the
704
+ // input from uncontrolled to controlled, which React warns about.
705
+ const [dateRangeSearchValue, setDateRangeSearchValue] = useState("");
704
706
  const [selectedRange, setSelectedRange] = useState();
705
707
  const currentSelectedRange = useMemo(() => {
706
708
  // Internal selected range takes precedence
package/package.json CHANGED
@@ -1,20 +1,20 @@
1
1
  {
2
2
  "name": "@trackunit/react-date-and-time-components",
3
- "version": "2.4.15",
3
+ "version": "2.4.16-alpha-037fb409571.0",
4
4
  "repository": "https://github.com/Trackunit/manager",
5
5
  "license": "SEE LICENSE IN LICENSE.txt",
6
6
  "engines": {
7
7
  "node": ">=24.x"
8
8
  },
9
9
  "dependencies": {
10
- "@trackunit/react-components": "2.7.3",
11
- "@trackunit/date-and-time-utils": "1.14.9",
12
- "@trackunit/react-date-and-time-hooks": "2.4.14",
13
- "@trackunit/css-class-variance-utilities": "1.14.8",
14
- "@trackunit/ui-icons": "1.14.8",
15
- "@trackunit/shared-utils": "1.16.8",
16
- "@trackunit/i18n-library-translation": "2.3.10",
17
- "@trackunit/react-form-components": "2.4.14",
10
+ "@trackunit/react-components": "2.7.4-alpha-037fb409571.0",
11
+ "@trackunit/date-and-time-utils": "1.14.10-alpha-037fb409571.0",
12
+ "@trackunit/react-date-and-time-hooks": "2.4.15-alpha-037fb409571.0",
13
+ "@trackunit/css-class-variance-utilities": "1.14.9-alpha-037fb409571.0",
14
+ "@trackunit/ui-icons": "1.14.9-alpha-037fb409571.0",
15
+ "@trackunit/shared-utils": "1.16.9-alpha-037fb409571.0",
16
+ "@trackunit/i18n-library-translation": "2.3.11-alpha-037fb409571.0",
17
+ "@trackunit/react-form-components": "2.4.15-alpha-037fb409571.0",
18
18
  "string-ts": "^2.0.0",
19
19
  "tailwind-merge": "^2.0.0",
20
20
  "react-calendar": "^6.0.0"