@instructure/ui-calendar 11.7.5 → 11.7.6-snapshot-11

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/CHANGELOG.md CHANGED
@@ -3,6 +3,17 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [11.7.6-snapshot-11](https://github.com/instructure/instructure-ui/compare/v11.7.5...v11.7.6-snapshot-11) (2026-08-31)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * **many:** generate deterministic ids with React useId ([83aa25a](https://github.com/instructure/instructure-ui/commit/83aa25aebd41720fd09beac025dbf961e1f413c2))
12
+
13
+
14
+
15
+
16
+
6
17
  ## [11.7.5](https://github.com/instructure/instructure-ui/compare/v11.7.4...v11.7.5) (2026-08-25)
7
18
 
8
19
  **Note:** Version bump only for package @instructure/ui-calendar
@@ -62,9 +62,12 @@ let Calendar = (_dec = withDeterministicId(), _dec2 = withStyle(generateStyle, g
62
62
  constructor(props) {
63
63
  super(props);
64
64
  this._weekdayHeaderIds = (this.props.renderWeekdayLabels || this.defaultWeekdays).reduce((ids, _label, i) => {
65
+ // The instance name must vary per weekday: `deterministicId` derives the
66
+ // id from the name, so calling it repeatedly with the same name returns
67
+ // the same id (it is no longer a counter) and every header would collide.
65
68
  return {
66
69
  ...ids,
67
- [i]: this.props.deterministicId('weekday-header')
70
+ [i]: this.props.deterministicId(`weekday-header-${i}`)
68
71
  };
69
72
  }, {});
70
73
  this.state = this.calculateState(this.locale(), this.timezone(), props.currentDate);
@@ -61,9 +61,12 @@ let Calendar = (_dec = withDeterministicId(), _dec2 = withStyleNew(generateStyle
61
61
  constructor(props) {
62
62
  super(props);
63
63
  this._weekdayHeaderIds = (this.props.renderWeekdayLabels || this.defaultWeekdays).reduce((ids, _label, i) => {
64
+ // The instance name must vary per weekday: `deterministicId` derives the
65
+ // id from the name, so calling it repeatedly with the same name returns
66
+ // the same id (it is no longer a counter) and every header would collide.
64
67
  return {
65
68
  ...ids,
66
- [i]: this.props.deterministicId('weekday-header')
69
+ [i]: this.props.deterministicId(`weekday-header-${i}`)
67
70
  };
68
71
  }, {});
69
72
  this.state = this.calculateState(this.locale(), this.timezone(), props.currentDate);
@@ -73,9 +73,12 @@ let Calendar = exports.Calendar = (_dec = (0, _withDeterministicId.withDetermini
73
73
  constructor(props) {
74
74
  super(props);
75
75
  this._weekdayHeaderIds = (this.props.renderWeekdayLabels || this.defaultWeekdays).reduce((ids, _label, i) => {
76
+ // The instance name must vary per weekday: `deterministicId` derives the
77
+ // id from the name, so calling it repeatedly with the same name returns
78
+ // the same id (it is no longer a counter) and every header would collide.
76
79
  return {
77
80
  ...ids,
78
- [i]: this.props.deterministicId('weekday-header')
81
+ [i]: this.props.deterministicId(`weekday-header-${i}`)
79
82
  };
80
83
  }, {});
81
84
  this.state = this.calculateState(this.locale(), this.timezone(), props.currentDate);
@@ -71,9 +71,12 @@ let Calendar = exports.Calendar = (_dec = (0, _withDeterministicId.withDetermini
71
71
  constructor(props) {
72
72
  super(props);
73
73
  this._weekdayHeaderIds = (this.props.renderWeekdayLabels || this.defaultWeekdays).reduce((ids, _label, i) => {
74
+ // The instance name must vary per weekday: `deterministicId` derives the
75
+ // id from the name, so calling it repeatedly with the same name returns
76
+ // the same id (it is no longer a counter) and every header would collide.
74
77
  return {
75
78
  ...ids,
76
- [i]: this.props.deterministicId('weekday-header')
79
+ [i]: this.props.deterministicId(`weekday-header-${i}`)
77
80
  };
78
81
  }, {});
79
82
  this.state = this.calculateState(this.locale(), this.timezone(), props.currentDate);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@instructure/ui-calendar",
3
- "version": "11.7.5",
3
+ "version": "11.7.6-snapshot-11",
4
4
  "description": "A calendar component.",
5
5
  "author": "Instructure, Inc. Engineering and Product Design",
6
6
  "module": "./es/index.js",
@@ -15,27 +15,27 @@
15
15
  "license": "MIT",
16
16
  "dependencies": {
17
17
  "@babel/runtime": "^7.29.7",
18
- "@instructure/console": "11.7.5",
19
- "@instructure/emotion": "11.7.5",
20
- "@instructure/shared-types": "11.7.5",
21
- "@instructure/ui-a11y-content": "11.7.5",
22
- "@instructure/ui-buttons": "11.7.5",
23
- "@instructure/ui-i18n": "11.7.5",
24
- "@instructure/ui-icons": "11.7.5",
25
- "@instructure/ui-simple-select": "11.7.5",
26
- "@instructure/ui-themes": "11.7.5",
27
- "@instructure/ui-utils": "11.7.5",
28
- "@instructure/uid": "11.7.5",
29
- "@instructure/ui-react-utils": "11.7.5",
30
- "@instructure/ui-view": "11.7.5"
18
+ "@instructure/console": "11.7.6-snapshot-11",
19
+ "@instructure/emotion": "11.7.6-snapshot-11",
20
+ "@instructure/ui-a11y-content": "11.7.6-snapshot-11",
21
+ "@instructure/shared-types": "11.7.6-snapshot-11",
22
+ "@instructure/ui-buttons": "11.7.6-snapshot-11",
23
+ "@instructure/ui-react-utils": "11.7.6-snapshot-11",
24
+ "@instructure/ui-i18n": "11.7.6-snapshot-11",
25
+ "@instructure/ui-icons": "11.7.6-snapshot-11",
26
+ "@instructure/ui-simple-select": "11.7.6-snapshot-11",
27
+ "@instructure/ui-themes": "11.7.6-snapshot-11",
28
+ "@instructure/ui-utils": "11.7.6-snapshot-11",
29
+ "@instructure/ui-view": "11.7.6-snapshot-11",
30
+ "@instructure/uid": "11.7.6-snapshot-11"
31
31
  },
32
32
  "devDependencies": {
33
33
  "@testing-library/jest-dom": "^6.9.1",
34
34
  "@testing-library/react": "16.3.2",
35
35
  "@testing-library/user-event": "^14.6.1",
36
36
  "vitest": "^4.1.9",
37
- "@instructure/ui-babel-preset": "11.7.5",
38
- "@instructure/ui-color-utils": "11.7.5"
37
+ "@instructure/ui-babel-preset": "11.7.6-snapshot-11",
38
+ "@instructure/ui-color-utils": "11.7.6-snapshot-11"
39
39
  },
40
40
  "peerDependencies": {
41
41
  "react": ">=18 <=19"
@@ -87,7 +87,10 @@ class Calendar extends Component<CalendarProps, CalendarState> {
87
87
  this._weekdayHeaderIds = (
88
88
  this.props.renderWeekdayLabels || this.defaultWeekdays
89
89
  ).reduce((ids: Record<number, string>, _label, i) => {
90
- return { ...ids, [i]: this.props.deterministicId!('weekday-header') }
90
+ // The instance name must vary per weekday: `deterministicId` derives the
91
+ // id from the name, so calling it repeatedly with the same name returns
92
+ // the same id (it is no longer a counter) and every header would collide.
93
+ return { ...ids, [i]: this.props.deterministicId!(`weekday-header-${i}`) }
91
94
  }, {})
92
95
  this.state = this.calculateState(
93
96
  this.locale(),
@@ -86,7 +86,10 @@ class Calendar extends Component<CalendarProps, CalendarState> {
86
86
  this._weekdayHeaderIds = (
87
87
  this.props.renderWeekdayLabels || this.defaultWeekdays
88
88
  ).reduce((ids: Record<number, string>, _label, i) => {
89
- return { ...ids, [i]: this.props.deterministicId!('weekday-header') }
89
+ // The instance name must vary per weekday: `deterministicId` derives the
90
+ // id from the name, so calling it repeatedly with the same name returns
91
+ // the same id (it is no longer a counter) and every header would collide.
92
+ return { ...ids, [i]: this.props.deterministicId!(`weekday-header-${i}`) }
90
93
  }, {})
91
94
  this.state = this.calculateState(
92
95
  this.locale(),