Files
trihuy-russian/web/html/component/aSettingListItem.html
T

50 lines
1.4 KiB
HTML
Raw Normal View History

2023-02-09 22:48:06 +03:30
{{define "component/settingListItem"}}
2025-03-06 17:17:25 +07:00
<a-list-item :style="{ padding: padding }">
2025-04-06 16:40:33 +07:00
<a-row :gutter="[8,16]">
2023-02-09 22:48:06 +03:30
<a-col :lg="24" :xl="12">
2025-03-06 17:17:25 +07:00
<a-list-item-meta>
<template #title>
<slot name="title"></slot>
</template>
<template #description>
<slot name="description"></slot>
</template>
</a-list-item-meta>
2023-02-09 22:48:06 +03:30
</a-col>
<a-col :lg="24" :xl="12">
2025-03-06 17:17:25 +07:00
<slot name="control"></slot>
2023-02-09 22:48:06 +03:30
</a-col>
</a-row>
</a-list-item>
{{end}}
2025-03-17 18:26:07 +07:00
{{define "component/aSettingListItem"}}
2023-02-09 22:48:06 +03:30
<script>
2025-03-06 17:17:25 +07:00
Vue.component('a-setting-list-item', {
2025-03-08 22:41:27 +07:00
props: {
'paddings': {
type: String,
required: false,
defaultValue: "default",
validator: function (value) {
return ['small', 'default'].includes(value)
}
}
},
2025-03-06 17:17:25 +07:00
template: `{{ template "component/settingListItem" }}`,
computed: {
padding() {
switch (this.paddings) {
case "small":
return "10px 20px !important"
break;
2025-03-08 22:41:27 +07:00
case "default":
2025-03-06 17:17:25 +07:00
return "20px !important"
break;
}
}
}
})
2023-02-09 22:48:06 +03:30
</script>
2023-05-11 14:04:35 +03:30
{{end}}