|
|
@ -4,7 +4,7 @@ |
|
|
|
</ul> |
|
|
|
</ul> |
|
|
|
</template> |
|
|
|
</template> |
|
|
|
|
|
|
|
|
|
|
|
<script lang="ts" setup name="Menu"> |
|
|
|
<script lang="ts" setup> |
|
|
|
import type { SubMenuProvider } from './types' |
|
|
|
import type { SubMenuProvider } from './types' |
|
|
|
import { ref, computed, onMounted, watchEffect, watch, nextTick, getCurrentInstance, provide } from 'vue' |
|
|
|
import { ref, computed, onMounted, watchEffect, watch, nextTick, getCurrentInstance, provide } from 'vue' |
|
|
|
import { useDesign } from '@/hooks/web/useDesign' |
|
|
|
import { useDesign } from '@/hooks/web/useDesign' |
|
|
@ -12,6 +12,8 @@ import { propTypes } from '@/utils/propTypes' |
|
|
|
import { createSimpleRootMenuContext } from './useSimpleMenuContext' |
|
|
|
import { createSimpleRootMenuContext } from './useSimpleMenuContext' |
|
|
|
import mitt from '@/utils/mitt' |
|
|
|
import mitt from '@/utils/mitt' |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
defineOptions({ name: 'Menu' }) |
|
|
|
|
|
|
|
|
|
|
|
const props = defineProps({ |
|
|
|
const props = defineProps({ |
|
|
|
theme: propTypes.oneOf(['light', 'dark']).def('light'), |
|
|
|
theme: propTypes.oneOf(['light', 'dark']).def('light'), |
|
|
|
activeName: propTypes.oneOfType([propTypes.string, propTypes.number]), |
|
|
|
activeName: propTypes.oneOfType([propTypes.string, propTypes.number]), |
|
|
|