code review

This commit is contained in:
cookfront
2017-03-30 21:22:14 +08:00
parent e241d92cd9
commit e20022b868
20 changed files with 522 additions and 186 deletions
+69 -63
View File
@@ -2,70 +2,76 @@
@import './mixins/border_retina.css';
@component-namespace zan {
@b badge-group {
position: relative;
width: 85px;
&::after {
@mixin border-retina (top);
}
@b badge-group {
position: relative;
width: 85px;
&::after {
@mixin border-retina (top);
}
@b badge {
}
@b badge {
display: block;
overflow: hidden;
position: relative;
padding: 20px 12px;
box-sizing: border-box;
line-height: 1.4;
background-color: $c-background;
color: $c-gray-darker;
font-size: 14px;
text-decoration: none;
word-break: break-all;
@m select {
font-weight: bold;
color: $c-black;
background-color: $c-white;
.zan-badge__active {
display: block;
overflow: hidden;
position: relative;
padding: 20px 12px;
box-sizing: border-box;
line-height: 1.4;
background-color: $c-background;
color: $c-gray-darker;
font-size: 14px;
text-decoration: none;
word-break: break-all;
@e active {
display: none;
position: absolute;
left: 0;
top: 0;
width: 3px;
height: 100%;
background-color: #FF4444;
}
@e info {
position: absolute;
top: 2px;
right: 2px;
font-size: 10px;
transform:scale(0.8);
text-align: center;
box-sizing: border-box;
padding: 0 6px;
min-width: 18px;
height: 18px;
line-height: 18px;
border-radius: 9px;
background-color: #FF4444;
color: $c-white;
}
@when select {
font-weight: bold;
color: $c-black;
background-color: $c-white;
.zan-badge__active {
display: block;
}
&::after {
@mixin border-retina (top);
@mixin border-retina (right);
@mixin border-retina (left);
}
}
&::after {
@mixin border-retina (bottom);
}
&:last-child {
&::after {
border-bottom: 0;
}
}
}
&::after {
@mixin border-retina (top);
@mixin border-retina (right);
@mixin border-retina (left);
}
}
@e active {
display: none;
position: absolute;
left: 0;
top: 0;
width: 3px;
height: 100%;
background-color: #FF4444;
}
@e info {
position: absolute;
top: 2px;
right: 2px;
font-size: 10px;
transform:scale(0.8);
text-align: center;
box-sizing: border-box;
padding: 0 6px;
min-width: 18px;
height: 18px;
line-height: 18px;
border-radius: 9px;
background-color: #FF4444;
color: $c-white;
}
&::after {
@mixin border-retina (bottom);
}
&:last-child {
&::after {
border-bottom: 0;
}
}
}
}
+2 -2
View File
@@ -15,7 +15,7 @@
@e img {
width: 90px;
height: 90px;
height: auto;
border: 0;
position: absolute;
top: 5px;
@@ -26,7 +26,7 @@
display: table;
width: 100%;
@when center {
@m center {
display: table;
height: 90px;
+10 -3
View File
@@ -20,12 +20,15 @@
}
@e icon {
font-size: 40px;
line-height: 1;
float: left;
margin-right: 10px;
}
.zan-icon {
font-size: 40px;
line-height: 1;
}
@e message {
display: table;
height: 40px;
@@ -53,8 +56,12 @@
@e items {
margin: 0 0 10px;
overflow: hidden;
padding-bottom: 20px;
position: relative;
padding-bottom: 20px;
@m alone {
padding-top: 10px;
}
}
}
+3
View File
@@ -23,6 +23,7 @@
&::after {
border-color: $c-green;
}
@when plain {
color: $c-green;
}
@@ -34,6 +35,7 @@
&::after {
border-color: $button-danger-background-color;
}
@when plain {
color: $button-danger-background-color;
}
@@ -45,6 +47,7 @@
&::after {
border-color: $c-blue;
}
@when plain {
color: $c-blue;
}