ag-element-ui/packages/agCol/src/index.vue

33 lines
577 B
Vue
Raw Normal View History

2024-08-23 17:06:01 +08:00
<template>
<div class="agColbox" :style="{flex:`0 0 ${Number(span)/24*100}%`,marginLeft:`${Number(offset)/24*100}%`}">
<slot></slot>
</div>
</template>
<script>
export default {
name: 'AgCol',
props: {
span:{
type:Number|String,
default:24
},
offset:{
type:Number|String,
default:0
}
},
data() {
return {};
},
}
</script>
<style lang="scss" scoped>
.agColbox{
flex:0 0 100%;
padding-left: 10px;
padding-right: 10px;
box-sizing: border-box;
}
</style>