mirror of https://github.com/halo-dev/halo
![]() #### What type of PR is this? /area console /kind improvement /milestone 2.12.x #### What this PR does / why we need it: 重构 UI 的 Modal 组件,支持通过 v-if 控制是否显示(渲染)。 example: ```vue <script lang="ts" setup> import { ref } from "vue" const visible = ref(false) const modal = ref() function open() { visible.value = true } function close() { modal.value.close() } </script> <template> <button @click="open">Open</button> <VModal v-if="visible" ref="modal" title="test"> <button @click="close">Close</button> </VModal> </template> ``` #### Which issue(s) this PR fixes: Fixes #5077 #### Special notes for your reviewer: 测试方式: 1. cd console && pnpm --filter "./packages/components" storybook 2. 测试 Modal 组件在文档中是否工作正常。 3. 启动 Console 或者 UC。 4. 观察以前页面上的弹框是否工作正常。 #### Does this PR introduce a user-facing change? ```release-note 重构 UI 的 Modal 组件,支持通过 v-if 控制是否显示(渲染)。 ``` |
||
---|---|---|
.. | ||
.storybook | ||
src | ||
.eslintignore | ||
.eslintrc.cjs | ||
env.d.ts | ||
package.json | ||
postcss.config.js | ||
prettier.config.js | ||
tailwind.config.js | ||
tsconfig.app.json | ||
tsconfig.json | ||
tsconfig.node.json | ||
tsconfig.vitest.json | ||
vite.config.ts |