Skip to content

Commit

Permalink
feat(ui/space): add new component name is space
Browse files Browse the repository at this point in the history
affects: @varlet/ui
  • Loading branch information
haoziqaq committed Nov 17, 2021
1 parent 146a958 commit 6f6e5e5
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 47 deletions.
38 changes: 0 additions & 38 deletions packages/varlet-ui/darkMode.md

This file was deleted.

17 changes: 16 additions & 1 deletion packages/varlet-ui/src/space/example/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -48,13 +48,28 @@
import AppType from '@varlet/cli/site/mobile/components/AppType'
import VarSpace from '..'
import VarButton from '../../button'
import context from '../../context'
import { pack, use } from './locale'
import { watchLang } from '@varlet/cli/site/utils'
import { watchLang, watchPlatform } from '@varlet/cli/site/utils'
import { watchDarkMode } from '../../utils/components'
import { onUnmounted } from 'vue'
export default {
components: { VarSpace, VarButton, AppType },
setup() {
watchLang(use)
watchDarkMode()
const prevTouchmoveForbid = context.touchmoveForbid
watchPlatform((platform) => {
if (platform === 'pc') {
context.touchmoveForbid = false
}
})
onUnmounted(() => {
context.touchmoveForbid = prevTouchmoveForbid
})
return {
pack,
}
Expand Down
16 changes: 8 additions & 8 deletions packages/varlet-ui/varlet.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,14 @@ module.exports = {
doc: 'collapse',
type: 2,
},
{
text: {
'zh-CN': 'Space 间隔',
'en-US': 'Space',
},
doc: 'space',
type: 2,
},
{
text: {
'zh-CN': 'Layout 布局',
Expand Down Expand Up @@ -242,14 +250,6 @@ module.exports = {
doc: 'card',
type: 2,
},
{
text: {
'zh-CN': 'Space 间隔',
'en-US': 'Space',
},
doc: 'space',
type: 2,
},
{
text: {
'zh-CN': 'Divider 分割线',
Expand Down

0 comments on commit 6f6e5e5

Please sign in to comment.