mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-15 18:31:06 +00:00
parent
d55aacaf27
commit
76d7dc5319
9 changed files with 190 additions and 0 deletions
14
src/components/ListBox/ListBoxMenu.svelte
Normal file
14
src/components/ListBox/ListBoxMenu.svelte
Normal file
|
@ -0,0 +1,14 @@
|
|||
<script>
|
||||
let className = undefined;
|
||||
export { className as class };
|
||||
export let id = Math.random(); // TODO: Use context to re-use same id per ListBox
|
||||
export let style = undefined;
|
||||
|
||||
import { cx } from '../../lib';
|
||||
|
||||
$: menuId = `menu-${id}`;
|
||||
</script>
|
||||
|
||||
<div role="listbox" id={menuId} class={cx('--list-box__menu', className)} {style}>
|
||||
<slot />
|
||||
</div>
|
Loading…
Add table
Add a link
Reference in a new issue