forked from unovue/radix-vue
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(NavigationMenu): disable hover or click props for triggers (unov…
…ue#778) * feat(menu-trigger): add props and basic logic * feat(menu-trigger): add props open on click and open on hover * feat(menu-trigger): add logic to disable triggers * test(menu-trigger): add tests on new props * docs(navigation_menu): add docs * chore: remove unused code * feat(menu-trigger): change props names * docs(navigation_menu): update docs after changing prop names * chore: make disable click trigger only response to mouse event * chore: add stories, update test --------- Co-authored-by: zernonia <[email protected]>
- Loading branch information
Showing
6 changed files
with
159 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
packages/radix-vue/src/NavigationMenu/story/NavigationMenuChromatic.story.vue
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<script setup lang="ts"> | ||
import NavigationMenu from './_NavigationMenu.vue' | ||
</script> | ||
|
||
<template> | ||
<Story title="Navigation Menu/Chromatic" :layout="{ type: 'grid', width: '50%', iframe: false }"> | ||
<Variant title="Default"> | ||
<NavigationMenu /> | ||
</Variant> | ||
|
||
<Variant title="Disabled click trigger"> | ||
<NavigationMenu disable-click-trigger /> | ||
</Variant> | ||
|
||
<Variant title="Disabled hover trigger"> | ||
<NavigationMenu disable-hover-trigger /> | ||
</Variant> | ||
</Story> | ||
</template> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters