chore(docs): add note itemHeight for virtualization (#4822)

* chore(docs): add note itemHeight for virtualization

* fix: format
This commit is contained in:
Ryo Matsukawa 2025-02-11 22:02:30 +09:00 committed by GitHub
parent 628bcdefeb
commit c659e2f215
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 5 additions and 2 deletions

View File

@ -337,6 +337,8 @@ The `maxListboxHeight` prop is used to set the maximum height of the listbox. Th
The `itemHeight` prop is used to set the height of each item in the listbox. This is required when using virtualization. By default, it's set to `32`.
> **Note**: If the height of the list items differs from the default due to `startContent` or other custom content, be sure to pass the correct value to `itemHeight` to prevent layout issues.
<CodeDemo title="Custom Item Height" files={autocompleteContent.virtualizationCustomItemHeight} />
### With Sections

View File

@ -153,7 +153,7 @@ function App() {
### Virtualization
Select supports virtualization, which allows efficient rendering of large lists by only rendering items that are visible in the viewport. You can enable virtualization by setting the `isVirtualized` prop to `true`.
Listbox supports virtualization, which allows efficient rendering of large lists by only rendering items that are visible in the viewport. You can enable virtualization by setting the `isVirtualized` prop to `true`.
<CodeDemo
title="Virtualization"

View File

@ -241,8 +241,9 @@ The `maxListboxHeight` prop is used to set the maximum height of the listbox. Th
The `itemHeight` prop is used to set the height of each item in the listbox. This is required when using virtualization. By default, it's set to `32`.
<CodeDemo title="Custom Item Height" files={selectContent.virtualizationCustomItemHeight} />
> **Note**: If the height of the list items differs from the default due to `startContent` or other custom content, be sure to pass the correct value to `itemHeight` to prevent layout issues.
<CodeDemo title="Custom Item Height" files={selectContent.virtualizationCustomItemHeight} />
### With Sections