Browse Source

fix:修复svg自适应问题

dev-xjf
肖晋飞 2 weeks ago
parent
commit
0fffeb2bb6
  1. 2
      public/测试.svg
  2. 8
      src/views/dashboard/demo/components/ParameterInfo.vue
  3. 3
      src/views/dashboard/demo/components/staticSvg.vue
  4. 1
      src/views/dashboard/demo/components/svg.vue

2
public/测试.svg

File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 325 KiB

After

Width:  |  Height:  |  Size: 325 KiB

8
src/views/dashboard/demo/components/ParameterInfo.vue

@ -38,6 +38,7 @@ const [registerTable, { setTableData }] = useTable({
useSearchForm: false, useSearchForm: false,
showTableSetting: false, showTableSetting: false,
showIndexColumn: false, showIndexColumn: false,
}) })
// //
onBeforeUpdate(async () => { onBeforeUpdate(async () => {
@ -86,7 +87,10 @@ onBeforeUpdate(async () => {
更多 更多
</a-button> </a-button>
</template> --> </template> -->
<BasicTable style="min-height:30vh" :loading="loading" @register="registerTable"> <BasicTable
:pagination="{ pageSize: 6 }"
:loading="loading" @register="registerTable"
>
<template #threshold="{ record }"> <template #threshold="{ record }">
<span>{{ getInterval(record) }}</span> <span>{{ getInterval(record) }}</span>
</template> </template>
@ -97,5 +101,7 @@ onBeforeUpdate(async () => {
<style scoped> <style scoped>
::v-deep(.ant-card-body) { ::v-deep(.ant-card-body) {
padding:10px; padding:10px;
height:calc(46vh - 56px)
} }
</style> </style>

3
src/views/dashboard/demo/components/staticSvg.vue

@ -43,6 +43,7 @@ function fullScreen() {
<style scoped> <style scoped>
::v-deep .ant-card-body { ::v-deep .ant-card-body {
padding: 10px; padding: 5px;
height:calc(46vh - 56px)
} }
</style> </style>

1
src/views/dashboard/demo/components/svg.vue

@ -240,7 +240,6 @@ defineExpose({
width: 100%; width: 100%;
height:100%; height:100%;
min-height: 300px; min-height: 300px;
padding: 10px;
overflow: auto; overflow: auto;
} }

Loading…
Cancel
Save