mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-15 02:11:05 +00:00
test(overflow-menu): add more unit tests
This commit is contained in:
parent
14edf41e57
commit
cdd3a38448
2 changed files with 177 additions and 0 deletions
|
@ -1,8 +1,25 @@
|
|||
<script lang="ts">
|
||||
import { OverflowMenu, OverflowMenuItem } from "carbon-components-svelte";
|
||||
|
||||
export let size: "sm" | "xl" | undefined = undefined;
|
||||
export let light: boolean = false;
|
||||
export let flipped: boolean = false;
|
||||
export let direction: "top" | "bottom" = "bottom";
|
||||
export let menuOptionsClass: string | undefined = undefined;
|
||||
export let iconClass: string | undefined = undefined;
|
||||
export let iconDescription: string = "Open and close list of options";
|
||||
export let id: string = "ccs-" + Math.random().toString(36);
|
||||
</script>
|
||||
|
||||
<OverflowMenu
|
||||
{size}
|
||||
{light}
|
||||
{flipped}
|
||||
{direction}
|
||||
{menuOptionsClass}
|
||||
{iconClass}
|
||||
{iconDescription}
|
||||
{id}
|
||||
on:close={(e) => {
|
||||
console.log("close", e.detail); // { index: number; text: string; }
|
||||
}}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue