@react-stately/tabs
Advanced tools
Comparing version
@@ -34,3 +34,3 @@ var $3yB4p$reactstatelylist = require("@react-stately/list"); | ||
let selectedKey = currentSelectedKey; | ||
if (selectionManager.isEmpty || selectedKey == null || !collection.getItem(selectedKey)) { | ||
if (props.selectedKey == null && (selectionManager.isEmpty || selectedKey == null || !collection.getItem(selectedKey))) { | ||
selectedKey = $817f925d289daf81$var$findDefaultSelectedKey(collection, state.disabledKeys); | ||
@@ -37,0 +37,0 @@ if (selectedKey != null) // directly set selection because replace/toggle selection won't consider disabled keys |
@@ -28,3 +28,3 @@ import {useSingleSelectListState as $fgY1A$useSingleSelectListState} from "@react-stately/list"; | ||
let selectedKey = currentSelectedKey; | ||
if (selectionManager.isEmpty || selectedKey == null || !collection.getItem(selectedKey)) { | ||
if (props.selectedKey == null && (selectionManager.isEmpty || selectedKey == null || !collection.getItem(selectedKey))) { | ||
selectedKey = $76f919a04c5a7d14$var$findDefaultSelectedKey(collection, state.disabledKeys); | ||
@@ -31,0 +31,0 @@ if (selectedKey != null) // directly set selection because replace/toggle selection won't consider disabled keys |
{ | ||
"name": "@react-stately/tabs", | ||
"version": "3.7.1", | ||
"version": "3.8.0", | ||
"description": "Spectrum UI components in React", | ||
@@ -25,5 +25,5 @@ "license": "Apache-2.0", | ||
"dependencies": { | ||
"@react-stately/list": "^3.11.2", | ||
"@react-types/shared": "^3.27.0", | ||
"@react-types/tabs": "^3.3.12", | ||
"@react-stately/list": "^3.12.0", | ||
"@react-types/shared": "^3.28.0", | ||
"@react-types/tabs": "^3.3.13", | ||
"@swc/helpers": "^0.5.0" | ||
@@ -37,3 +37,3 @@ }, | ||
}, | ||
"gitHead": "09e7f44bebdc9d89122926b2b439a0a38a2814ea" | ||
"gitHead": "4d3c72c94eea2d72eb3a0e7d56000c6ef7e39726" | ||
} |
@@ -46,3 +46,3 @@ /* | ||
let selectedKey = currentSelectedKey; | ||
if (selectionManager.isEmpty || selectedKey == null || !collection.getItem(selectedKey)) { | ||
if (props.selectedKey == null && (selectionManager.isEmpty || selectedKey == null || !collection.getItem(selectedKey))) { | ||
selectedKey = findDefaultSelectedKey(collection, state.disabledKeys); | ||
@@ -49,0 +49,0 @@ if (selectedKey != null) { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
47330
0.52%Updated
Updated
Updated