首页样式的修改
This commit is contained in:
@@ -5,21 +5,28 @@
|
|||||||
<div class="mobile-home__banner-bg">
|
<div class="mobile-home__banner-bg">
|
||||||
<div class="mobile-home__banner-content">
|
<div class="mobile-home__banner-content">
|
||||||
<div class="mobile-home__brand">
|
<div class="mobile-home__brand">
|
||||||
<div class="mobile-home__brand-logo">亚为MOM</div>
|
<div class="mobile-home__brand-logo">
|
||||||
<div class="mobile-home__brand-text">
|
<img src="@/assets/imgs/logo.png" alt="Logo" class="mobile-home__logo-icon" />
|
||||||
<div class="mobile-home__brand-title">智能一体化管理系统</div>
|
<div class="mobile-home__logo-text">
|
||||||
<div class="mobile-home__brand-sub">私有化部署,可定制</div>
|
<div class="mobile-home__logo-title">亚为MOM</div>
|
||||||
|
<div class="mobile-home__logo-subtitle">Manufacturing Operations Management</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="mobile-home__brand-desc">
|
||||||
|
<div class="mobile-home__brand-title">智能制造一体化管理平台</div>
|
||||||
|
<div class="mobile-home__brand-tags">
|
||||||
|
<span class="tag">私有化部署</span>
|
||||||
|
<span class="tag">可定制</span>
|
||||||
|
<span class="tag">安全可靠</span>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="mobile-home__banner-deco">
|
</div>
|
||||||
<svg width="80" height="80" viewBox="0 0 80 80" fill="none">
|
<!-- 装饰元素 -->
|
||||||
<rect x="10" y="20" width="25" height="35" rx="3" fill="rgba(255,255,255,0.3)"/>
|
<div class="mobile-home__banner-circles">
|
||||||
<rect x="40" y="10" width="30" height="45" rx="3" fill="rgba(255,255,255,0.2)"/>
|
<div class="circle circle-1"></div>
|
||||||
<circle cx="55" cy="60" r="15" fill="rgba(255,255,255,0.15)"/>
|
<div class="circle circle-2"></div>
|
||||||
<rect x="15" y="58" width="20" height="3" rx="1" fill="rgba(255,255,255,0.4)"/>
|
<div class="circle circle-3"></div>
|
||||||
<rect x="15" y="64" width="14" height="3" rx="1" fill="rgba(255,255,255,0.3)"/>
|
|
||||||
</svg>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -27,12 +34,8 @@
|
|||||||
<!-- 常用功能区 -->
|
<!-- 常用功能区 -->
|
||||||
<div class="mobile-home__section">
|
<div class="mobile-home__section">
|
||||||
<div class="mobile-home__section-header">
|
<div class="mobile-home__section-header">
|
||||||
<div class="mobile-home__section-icon">
|
|
||||||
<svg viewBox="0 0 24 24" width="18" height="18" fill="#409eff">
|
|
||||||
<path d="M3.5 18.49l6-6.01 4 4L22 6.92l-1.41-1.41-7.09 7.97-4-4L2 16.99z"/>
|
|
||||||
</svg>
|
|
||||||
</div>
|
|
||||||
<span class="mobile-home__section-title">常用功能</span>
|
<span class="mobile-home__section-title">常用功能</span>
|
||||||
|
<span class="mobile-home__section-more">全部 ></span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mobile-home__grid" v-loading="loading">
|
<div class="mobile-home__grid" v-loading="loading">
|
||||||
@@ -42,7 +45,7 @@
|
|||||||
class="mobile-home__grid-item"
|
class="mobile-home__grid-item"
|
||||||
@click="handleShortcutClick(item.url)"
|
@click="handleShortcutClick(item.url)"
|
||||||
>
|
>
|
||||||
<div class="mobile-home__grid-icon" :style="{ color: item.color, background: item.color + '18' }">
|
<div class="mobile-home__grid-icon" :style="{ background: item.color }">
|
||||||
<Icon :icon="item.icon" />
|
<Icon :icon="item.icon" />
|
||||||
</div>
|
</div>
|
||||||
<span class="mobile-home__grid-label">{{ item.name }}</span>
|
<span class="mobile-home__grid-label">{{ item.name }}</span>
|
||||||
@@ -131,177 +134,251 @@ getAllApi()
|
|||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.mobile-home {
|
.mobile-home {
|
||||||
background: #f5f5f5;
|
background: linear-gradient(180deg, #f0f4f8 0%, #f5f7fa 100%);
|
||||||
min-height: 100%;
|
min-height: 100vh;
|
||||||
padding-bottom: 16px;
|
padding-bottom: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Banner */
|
/* Banner 区域 */
|
||||||
.mobile-home__banner {
|
.mobile-home__banner {
|
||||||
padding: 0 12px;
|
margin-bottom: 16px;
|
||||||
margin-bottom: 12px;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.mobile-home__banner-bg {
|
.mobile-home__banner-bg {
|
||||||
background: linear-gradient(135deg, #43cea2 0%, #2a9d8f 50%, #264653 100%);
|
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
|
||||||
border-radius: 0 0 16px 16px;
|
border-radius: 0 0 24px 24px;
|
||||||
padding: 20px 16px 24px;
|
padding: 24px 16px 32px;
|
||||||
position: relative;
|
position: relative;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
box-shadow: 0 4px 20px rgba(102, 126, 234, 0.3);
|
||||||
}
|
}
|
||||||
|
|
||||||
.mobile-home__banner-content {
|
.mobile-home__banner-content {
|
||||||
display: flex;
|
position: relative;
|
||||||
justify-content: space-between;
|
z-index: 2;
|
||||||
align-items: center;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.mobile-home__brand {
|
.mobile-home__brand {
|
||||||
display: flex;
|
color: #fff;
|
||||||
flex-direction: column;
|
|
||||||
gap: 8px;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.mobile-home__brand-logo {
|
.mobile-home__brand-logo {
|
||||||
font-size: 28px;
|
display: flex;
|
||||||
font-weight: 800;
|
align-items: center;
|
||||||
color: #fff;
|
gap: 12px;
|
||||||
letter-spacing: 2px;
|
margin-bottom: 16px;
|
||||||
text-shadow: 0 2px 8px rgba(0,0,0,0.2);
|
|
||||||
}
|
}
|
||||||
.mobile-home__brand-text {
|
|
||||||
|
.mobile-home__logo-icon {
|
||||||
|
width: 48px;
|
||||||
|
height: 48px;
|
||||||
|
background: rgba(255, 255, 255, 0.2);
|
||||||
|
backdrop-filter: blur(10px);
|
||||||
|
border-radius: 12px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
font-size: 24px;
|
||||||
|
font-weight: 700;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
|
border: 2px solid rgba(255, 255, 255, 0.3);
|
||||||
|
object-fit: contain;
|
||||||
|
padding: 6px;
|
||||||
}
|
}
|
||||||
.mobile-home__brand-title {
|
|
||||||
font-size: 16px;
|
.mobile-home__logo-text {
|
||||||
font-weight: 600;
|
flex: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-home__logo-title {
|
||||||
|
font-size: 22px;
|
||||||
|
font-weight: 700;
|
||||||
margin-bottom: 2px;
|
margin-bottom: 2px;
|
||||||
|
letter-spacing: 0.5px;
|
||||||
}
|
}
|
||||||
.mobile-home__brand-sub {
|
|
||||||
font-size: 12px;
|
.mobile-home__logo-subtitle {
|
||||||
opacity: 0.8;
|
font-size: 10px;
|
||||||
|
opacity: 0.85;
|
||||||
|
letter-spacing: 0.3px;
|
||||||
|
text-transform: uppercase;
|
||||||
}
|
}
|
||||||
.mobile-home__banner-deco {
|
|
||||||
opacity: 0.7;
|
.mobile-home__brand-desc {
|
||||||
flex-shrink: 0;
|
margin-top: 4px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-home__brand-title {
|
||||||
|
font-size: 15px;
|
||||||
|
font-weight: 500;
|
||||||
|
margin-bottom: 10px;
|
||||||
|
opacity: 0.95;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-home__brand-tags {
|
||||||
|
display: flex;
|
||||||
|
gap: 8px;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
|
||||||
|
.tag {
|
||||||
|
padding: 4px 12px;
|
||||||
|
background: rgba(255, 255, 255, 0.2);
|
||||||
|
backdrop-filter: blur(10px);
|
||||||
|
border-radius: 12px;
|
||||||
|
font-size: 11px;
|
||||||
|
font-weight: 500;
|
||||||
|
border: 1px solid rgba(255, 255, 255, 0.3);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Banner 装饰圆圈 */
|
||||||
|
.mobile-home__banner-circles {
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
right: 0;
|
||||||
|
bottom: 0;
|
||||||
|
overflow: hidden;
|
||||||
|
z-index: 1;
|
||||||
|
|
||||||
|
.circle {
|
||||||
|
position: absolute;
|
||||||
|
border-radius: 50%;
|
||||||
|
background: rgba(255, 255, 255, 0.1);
|
||||||
|
|
||||||
|
&.circle-1 {
|
||||||
|
width: 120px;
|
||||||
|
height: 120px;
|
||||||
|
top: -40px;
|
||||||
|
right: -20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.circle-2 {
|
||||||
|
width: 80px;
|
||||||
|
height: 80px;
|
||||||
|
bottom: -20px;
|
||||||
|
right: 60px;
|
||||||
|
background: rgba(255, 255, 255, 0.08);
|
||||||
|
}
|
||||||
|
|
||||||
|
&.circle-3 {
|
||||||
|
width: 60px;
|
||||||
|
height: 60px;
|
||||||
|
top: 50%;
|
||||||
|
right: -10px;
|
||||||
|
background: rgba(255, 255, 255, 0.06);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* 功能区 */
|
/* 功能区 */
|
||||||
.mobile-home__section {
|
.mobile-home__section {
|
||||||
margin: 0 12px;
|
margin: 0 12px;
|
||||||
background: #fff;
|
background: #fff;
|
||||||
border-radius: 12px;
|
border-radius: 16px;
|
||||||
padding: 14px;
|
padding: 16px;
|
||||||
box-shadow: 0 1px 4px rgba(0,0,0,0.06);
|
box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
|
||||||
}
|
}
|
||||||
|
|
||||||
.mobile-home__section-header {
|
.mobile-home__section-header {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 8px;
|
justify-content: space-between;
|
||||||
margin-bottom: 16px;
|
margin-bottom: 16px;
|
||||||
padding-bottom: 10px;
|
padding-bottom: 12px;
|
||||||
border-bottom: 2px solid #409eff;
|
border-bottom: 1px solid #f0f0f0;
|
||||||
}
|
|
||||||
.mobile-home__section-icon {
|
|
||||||
width: 28px;
|
|
||||||
height: 28px;
|
|
||||||
background: rgba(64,158,255,0.1);
|
|
||||||
border-radius: 50%;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
justify-content: center;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.mobile-home__section-title {
|
.mobile-home__section-title {
|
||||||
font-size: 16px;
|
font-size: 17px;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
color: #303133;
|
color: #1a1a1a;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-home__section-more {
|
||||||
|
font-size: 13px;
|
||||||
|
color: #909399;
|
||||||
|
cursor: pointer;
|
||||||
|
|
||||||
|
&:active {
|
||||||
|
opacity: 0.7;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* 功能网格 */
|
/* 功能网格 */
|
||||||
.mobile-home__grid {
|
.mobile-home__grid {
|
||||||
display: grid;
|
display: grid;
|
||||||
grid-template-columns: repeat(4, 1fr);
|
grid-template-columns: repeat(4, 1fr);
|
||||||
gap: 16px 8px;
|
gap: 16px 12px;
|
||||||
min-height: 100px;
|
min-height: 100px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.mobile-home__grid-item {
|
.mobile-home__grid-item {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 6px;
|
gap: 8px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
-webkit-tap-highlight-color: transparent;
|
-webkit-tap-highlight-color: transparent;
|
||||||
|
|
||||||
&:active {
|
&:active .mobile-home__grid-icon {
|
||||||
opacity: 0.7;
|
transform: scale(0.9);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.mobile-home__grid-icon {
|
.mobile-home__grid-icon {
|
||||||
width: 44px;
|
width: 56px;
|
||||||
height: 44px;
|
height: 56px;
|
||||||
border-radius: 12px;
|
border-radius: 16px;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
font-size: 22px;
|
font-size: 28px;
|
||||||
transition: transform 0.2s;
|
color: #fff;
|
||||||
|
transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
|
||||||
|
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
|
||||||
|
position: relative;
|
||||||
|
|
||||||
&:active {
|
&::before {
|
||||||
transform: scale(0.92);
|
content: '';
|
||||||
|
position: absolute;
|
||||||
|
inset: 0;
|
||||||
|
border-radius: 16px;
|
||||||
|
background: linear-gradient(135deg, rgba(255,255,255,0.3) 0%, rgba(255,255,255,0) 100%);
|
||||||
|
pointer-events: none;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.mobile-home__grid-label {
|
.mobile-home__grid-label {
|
||||||
font-size: 11px;
|
font-size: 12px;
|
||||||
color: #303133;
|
color: #303133;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
line-height: 1.3;
|
line-height: 1.3;
|
||||||
max-width: 64px;
|
max-width: 70px;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
text-overflow: ellipsis;
|
text-overflow: ellipsis;
|
||||||
white-space: nowrap;
|
display: -webkit-box;
|
||||||
|
-webkit-line-clamp: 2;
|
||||||
|
-webkit-box-orient: vertical;
|
||||||
|
white-space: normal;
|
||||||
|
word-break: break-all;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* 响应式调整 */
|
||||||
/* 功能网格 */
|
@media (max-width: 375px) {
|
||||||
.mobile-home__grid {
|
.mobile-home__grid {
|
||||||
display: grid;
|
grid-template-columns: repeat(4, 1fr);
|
||||||
grid-template-columns: repeat(4, 1fr);
|
gap: 12px 8px;
|
||||||
gap: 12px 6px; // 网格间距变小
|
|
||||||
min-height: 100px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.mobile-home__grid-item {
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
align-items: center;
|
|
||||||
gap: 4px; // 图标和文字间距变小
|
|
||||||
cursor: pointer;
|
|
||||||
-webkit-tap-highlight-color: transparent;
|
|
||||||
|
|
||||||
&:active {
|
|
||||||
opacity: 0.7;
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
.mobile-home__grid-icon {
|
.mobile-home__grid-icon {
|
||||||
width: 65px; // 图标变大
|
width: 52px;
|
||||||
height: 65px;
|
height: 52px;
|
||||||
border-radius: 14px;
|
font-size: 26px;
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
justify-content: center;
|
|
||||||
font-size: 26px; // 图标字体大小变大
|
|
||||||
transition: transform 0.2s;
|
|
||||||
|
|
||||||
&:active {
|
|
||||||
transform: scale(0.92);
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
.mobile-home__grid-label {
|
.mobile-home__grid-label {
|
||||||
font-size: 12px; // 文字略大,可根据需求微调
|
font-size: 11px;
|
||||||
color: #303133;
|
}
|
||||||
text-align: center;
|
|
||||||
line-height: 1.2;
|
|
||||||
max-width: 64px;
|
|
||||||
overflow: hidden;
|
|
||||||
text-overflow: ellipsis;
|
|
||||||
white-space: nowrap;
|
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
Reference in New Issue
Block a user