Skip to content

Commit 8aaa70a

Browse files
authored
docs: Random bug fixes and improvements (#9235)
* Add TabLinks to generated example code * Open search menu to components from home page * Scroll current page into view * Click logo on mobile to go to homepage * Add links to examples to homepage * Fix code font size on mobile * Fix example app code rendering * Update Autocomplete description * Make Menu starter API mirror RAC API * Make grid sizing properties use touch scaling * Correct copy on getting started page * Fix toc shifting when scrolling to the bottom * Align markdown menu to the end * Fix article resizing
1 parent eac07db commit 8aaa70a

24 files changed

+363
-355
lines changed

packages/@react-spectrum/s2/style/spectrum-theme.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -395,7 +395,7 @@ const radius = {
395395
};
396396

397397
type GridTrack = 'none' | 'subgrid' | (string & {}) | readonly GridTrackSize[];
398-
type GridTrackSize = 'auto' | 'min-content' | 'max-content' | `${number}fr` | `minmax(${string}, ${string})` | keyof typeof baseSpacing | (string & {});
398+
type GridTrackSize = 'auto' | 'min-content' | 'max-content' | `${number}fr` | `minmax(${string}, ${string})` | number | (string & {});
399399

400400
let gridTrack = (value: GridTrack) => {
401401
if (typeof value === 'string') {
@@ -405,7 +405,7 @@ let gridTrack = (value: GridTrack) => {
405405
};
406406

407407
let gridTrackSize = (value: GridTrackSize) => {
408-
return value in baseSpacing ? baseSpacing[value] : value;
408+
return typeof value === 'number' ? size(value) : value;
409409
};
410410

411411
const transitionProperty = {

0 commit comments

Comments
 (0)