This commit is contained in:
2026-01-05 12:47:14 +08:00
commit 1fc846fae3
1614 changed files with 162035 additions and 0 deletions

View File

@@ -0,0 +1,44 @@
<script setup lang="ts">
import { computed, defineComponent, provide } from 'vue'
import { PREFIX } from '../_constants'
import { getMainClass } from '../_utils'
import { rowProps } from './row'
const props = defineProps(rowProps)
provide('gutter', props.gutter)
function getClass(prefix: string, type: string) {
return prefix ? (type ? `nut-row-${prefix}-${type}` : '') : `nut-row-${type}`
}
const classes = computed(() => {
return getMainClass(props, componentName, [
getClass('', props.type),
getClass('justify', props.justify),
getClass('align', props.align),
getClass('flex', props.flexWrap),
])
})
</script>
<script lang="ts">
const componentName = `${PREFIX}-row`
export default defineComponent({
name: componentName,
options: {
virtualHost: true,
addGlobalClass: true,
styleIsolation: 'shared',
},
})
</script>
<template>
<view :class="classes" :style="customStyle">
<slot />
</view>
</template>
<style lang="scss">
@import './index';
</style>