docs: fix color box spacing (#7458)

This commit is contained in:
云游君 2022-05-01 18:38:08 +08:00 committed by GitHub
parent 0b92157b43
commit 4ea1d85184
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 7 additions and 5 deletions

View File

@ -14,12 +14,12 @@ const { copyColor } = useCopyColor()
<el-col :span="10" :xs="{ span: 12 }">
<div class="demo-color-box" :style="{ background: primary }">
Brand Color
<div class="value">{{ primary.toUpperCase() }}</div>
<div class="value" text="xs">{{ primary.toUpperCase() }}</div>
<div class="bg-color-sub" :style="{ background: primary }">
<div
v-for="level in colorLevel"
:key="level"
class="bg-blue-sub-item hover:(cursor-pointer shadow)"
class="bg-blue-sub-item cursor-pointer hover:shadow"
:style="{
width: `${100 / 6}%`,
background: 'var(--el-color-primary-' + level + ')',

View File

@ -19,12 +19,14 @@ const { copyColor } = useCopyColor()
>
<div class="demo-color-box" :style="{ background: getColorValue(type) }">
{{ type.charAt(0).toUpperCase() + type.slice(1) }}
<div class="value">{{ getColorValue(type).toUpperCase() }}</div>
<div class="value" text="xs">
{{ getColorValue(type).toUpperCase() }}
</div>
<div class="bg-color-sub">
<div
v-for="(level, key) in colorLevel"
:key="key"
class="bg-secondary-sub-item transition hover:(cursor-pointer shadow)"
class="bg-secondary-sub-item transition cursor-pointer hover:shadow"
:style="{
width: `${100 / 6}%`,
background: `var(--el-color-${type}-` + level + ')',

View File

@ -13,7 +13,7 @@ Element Plus uses a specific set of palettes to specify colors to provide a cons
border-radius: 4px;
padding: 20px;
margin: 8px 0;
height: 100px;
height: 112px;
box-sizing: border-box;
color: var(--el-color-white);
font-size: 14px;