Skip to content

Commit

Permalink
Merge pull request #53 from huntabyte/revert
Browse files Browse the repository at this point in the history
  • Loading branch information
huntabyte authored Aug 18, 2023
2 parents d1b249f + 4fe9ccc commit c984dd5
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 9 deletions.
5 changes: 5 additions & 0 deletions .changeset/kind-shoes-ring.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"bits-ui": patch
---

Revert menubar changes
15 changes: 6 additions & 9 deletions src/lib/bits/menubar/components/MenubarContent.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,15 @@
export let sideOffset: $$Props["sideOffset"] = 4;
export let asChild = false;
const {
elements: { menu },
states: { open }
elements: { menu }
} = ctx.getContent(sideOffset);
</script>

<!-- svelte-ignore a11y-no-static-element-interactions / applied by melt's builder-->
{#if $open}
{#if asChild}
{#if asChild}
<slot builder={$menu} />
{:else}
<div use:melt={$menu} {...$$restProps} on:m-keydown>
<slot builder={$menu} />
{:else}
<div use:melt={$menu} {...$$restProps} on:m-keydown>
<slot builder={$menu} />
</div>
{/if}
</div>
{/if}

0 comments on commit c984dd5

Please sign in to comment.