feat: implement custom mini-program tab bar
This commit is contained in:
42
mini/custom-tab-bar/index.wxss
Normal file
42
mini/custom-tab-bar/index.wxss
Normal file
@@ -0,0 +1,42 @@
|
||||
.custom-tab-bar {
|
||||
display: flex;
|
||||
align-items: flex-start;
|
||||
padding-top: 14px;
|
||||
padding-bottom: calc(6px + constant(safe-area-inset-bottom));
|
||||
padding-bottom: calc(6px + env(safe-area-inset-bottom));
|
||||
min-height: 72px;
|
||||
background: #ffffff;
|
||||
border-top: 1rpx solid #e5e7eb;
|
||||
box-shadow: 0 -4px 18px rgba(15, 23, 42, 0.05);
|
||||
}
|
||||
|
||||
.custom-tab-bar__item {
|
||||
flex: 1;
|
||||
min-height: 44px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: flex-start;
|
||||
}
|
||||
|
||||
.custom-tab-bar__icon {
|
||||
width: 26px;
|
||||
height: 26px;
|
||||
display: block;
|
||||
flex-shrink: 0;
|
||||
margin-bottom: -3px;
|
||||
}
|
||||
|
||||
.custom-tab-bar__label {
|
||||
display: block;
|
||||
margin-top: 0;
|
||||
font-size: 12px;
|
||||
line-height: 1;
|
||||
color: #64748b;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.custom-tab-bar__label--active {
|
||||
color: #16a34a;
|
||||
font-weight: 600;
|
||||
}
|
||||
Reference in New Issue
Block a user