-
Notifications
You must be signed in to change notification settings - Fork 116
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(select): enable defaultValue to work correctly by removing rehydr…
…ation hack (#3545) * fix(select): enable defaultValue to work correctly by removing rehydration hack * chore: changeset * fix: change the fix to render the entire select on mount * fix: small adjustment * chore: undo format * chore: adjust changelog note * fix: logspam and local test running * chore: different approach for tests * fix(data-grid): tab management issue on re-renders --------- Co-authored-by: TheSisb <[email protected]>
- Loading branch information
Showing
9 changed files
with
84 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
"@twilio-paste/meter": patch | ||
"@twilio-paste/core": patch | ||
--- | ||
|
||
[Meter] Remove console.warn log spam regarding aria-label |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
"@twilio-paste/data-grid": patch | ||
"@twilio-paste/core": patch | ||
--- | ||
|
||
[Data Grid] Fix issue where form elements in the data-grid that immediately re-render on mount cause the tabIndex management system to faulter. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
--- | ||
"@twilio-paste/select": patch | ||
"@twilio-paste/core": patch | ||
--- | ||
|
||
[Select] fix the hydration issue which caused the `defaultValue` prop to not be respected. | ||
|
||
Since the React v18 upgrade, we were only rendering the children options after the component and html select | ||
wrapper had mounted. The select would mount with a `defaultValue` of a child that didn't exist, then the | ||
children would be added, so it wouldn't know what value to select. By adding a `key` prop to the select, | ||
it now knows to re-render on mount with the children, and can properly lookup the correct value now. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters