style(BasicUpload): center upload icon and text in BasicForm

This commit is contained in:
“乃木流架”
2023-10-21 23:54:14 +09:00
parent 81e8222461
commit 0656035857

View File

@@ -31,6 +31,7 @@
v-if="imgList.length < maxNumber" v-if="imgList.length < maxNumber"
> >
<n-upload <n-upload
class="w-auto"
v-bind="$props" v-bind="$props"
:file-list-style="{ display: 'none' }" :file-list-style="{ display: 'none' }"
@before-upload="beforeUpload" @before-upload="beforeUpload"
@@ -68,18 +69,18 @@
</template> </template>
<script lang="ts"> <script lang="ts">
import { defineComponent, toRefs, reactive, computed, watch } from 'vue'; import { defineComponent, toRefs, reactive, computed, watch } from 'vue';
import { EyeOutlined, DeleteOutlined, PlusOutlined } from '@vicons/antd'; import { EyeOutlined, DeleteOutlined, PlusOutlined } from '@vicons/antd';
import { basicProps } from './props'; import { basicProps } from './props';
import { useMessage, useDialog } from 'naive-ui'; import { useMessage, useDialog } from 'naive-ui';
import { ResultEnum } from '@/enums/httpEnum'; import { ResultEnum } from '@/enums/httpEnum';
import componentSetting from '@/settings/componentSetting'; import componentSetting from '@/settings/componentSetting';
import { useGlobSetting } from '@/hooks/setting'; import { useGlobSetting } from '@/hooks/setting';
import { isString } from '@/utils/is'; import { isString } from '@/utils/is';
const globSetting = useGlobSetting(); const globSetting = useGlobSetting();
export default defineComponent({ export default defineComponent({
name: 'BasicUpload', name: 'BasicUpload',
components: { EyeOutlined, DeleteOutlined, PlusOutlined }, components: { EyeOutlined, DeleteOutlined, PlusOutlined },
@@ -196,11 +197,11 @@
getCSSProperties, getCSSProperties,
}; };
}, },
}); });
</script> </script>
<style lang="less"> <style lang="less">
.upload { .upload {
width: 100%; width: 100%;
overflow: hidden; overflow: hidden;
@@ -306,5 +307,5 @@
} }
} }
} }
} }
</style> </style>