提交 d292a5f1 authored 作者: lidongxu's avatar lidongxu

style(levitatedsphere): 样式修改

多个工具按钮时布局不太对,调整完毕
上级 5b3ca7bb
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
<!-- 工具抽屉 --> <!-- 工具抽屉 -->
<el-drawer title="工具箱" <el-drawer title="工具箱"
v-model="drawer" v-model="drawer"
size="20%" size="300px"
@click.native="drawer = false"> @click.native="drawer = false">
<slot></slot> <slot></slot>
</el-drawer> </el-drawer>
...@@ -133,18 +133,15 @@ export default { ...@@ -133,18 +133,15 @@ export default {
align-items: center; align-items: center;
transition: all 0.5s; transition: all 0.5s;
font-size: 20px; font-size: 20px;
} }
::v-deep(.el-drawer__body) { ::v-deep(.el-drawer__body) {
padding: 10px; padding: 10px;
display: grid; display: grid;
grid-template-columns: repeat(3, 1fr); grid-template-columns: repeat(3, 1fr);
/* 让元素两端对齐 */ grid-template-rows: repeat(auto-fill, 30px); /* 明确指定行高为100px */
justify-content: space-between; grid-auto-rows: 30px; /* 自动生成的行高也为100px */
align-items: start; grid-gap: 20px 5px; /* 上下间距20px,左右间距5px */
grid-gap: 5px;
/* 可以根据实际情况设置容器宽度等其他样式 */
width: 100%; width: 100%;
.el-button { .el-button {
...@@ -152,4 +149,11 @@ export default { ...@@ -152,4 +149,11 @@ export default {
margin: 0; margin: 0;
} }
} }
@media (max-width: 768px) {
.wrap {
width: 30px;
height: 30px;
font-size: 12px;
}
}
</style> </style>
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论