Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Hooke
/
data-table
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Graphs
Network
Create a new issue
Commits
Issue Boards
Authored by
hookehuyr
2023-06-01 14:25:16 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
3e3b8525e2a2738274ae9ad514881f230c1cc205
3e3b8525
1 parent
43b9fabd
性别组件细节调整
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
3 deletions
src/components/GenderField/index.vue
src/components/GenderField/index.vue
View file @
3e3b852
...
...
@@ -19,9 +19,11 @@
:disabled="item.component_props.disabled"
>
<template #input>
<van-radio-group v-model="item.value" direction="horizontal">
<van-radio name="男" :checked-color="themeVars.radioColor">男</van-radio>
<van-radio name="女" :checked-color="themeVars.radioColor">女</van-radio>
<van-radio-group v-model="item.value" :direction="item.component_props.direction" style="width: 100%">
<div v-for="x in item.component_props.options" :key="x.value" class="radio-wrapper">
<van-radio :name="x.value" icon-size="1rem" :checked-color="themeVars.radioColor"
style="margin-bottom: 0.25rem">{{ x.title }}</van-radio>
</div>
</van-radio-group>
</template>
</van-field>
...
...
@@ -66,5 +68,11 @@ onMounted(() => {
padding-bottom: 0.5rem;
white-space: pre-wrap;
}
.radio-wrapper {
border: 1px solid #eaeaea;
border-radius: 0.25rem;
padding: 0.25rem 0.5rem;
margin-bottom: 0.25rem;
}
}
</style>
...
...
Please
register
or
login
to post a comment