-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbutton分析.html
executable file
·172 lines (143 loc) · 4.53 KB
/
button分析.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" href="css/normalize.css">
<link rel="stylesheet" href="grid/css/grid.css">
<link rel="stylesheet" href="button/css/button.css">
<title>Document</title>
<!--css样式演示-->
<style>
.btn {
display: inline-block;
font-weight: normal;
text-align: center;
vertical-align: middle;
border-radius: 4px;
cursor: pointer;
border: 1px solid transparent;
padding: 6px 12px;
/*考虑兼容性*/
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
/*touch-action: manipulation;*/
/*margin-bottom: 0;*/
/*white-space: nowrap;*/
/*padding: 6px 12px;*/
/*font-size: 14px;*/
/*line-height: 1.42857;*/
}
.btn-primary {
color: #fff;
background-color: #337ab7;
border-color: #2e6da4;
}
.btn-primary:hover {
color: #fff;
background-color: #286090;
border-color: #204d74;
}
.btn-primary:active {
color: #fff;
background-color: #286090;
border-color: #204d74;
outline: 0;
box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
}
.btn-primary:active:hover {
color: #fff;
background-color: #204d74;
border-color: #122b40;
}
<!--</style>
-->
</head>
<body>
<br>
<div class="container">
<!--按钮组-->
<div><h2>由button.scss生成的button样式</h2></div>
<div class="row">
<div class="col-md-2">
<div class="btn btn-default">button default</div>
</div>
<div class="col-md-2">
<div class="btn btn-primary">button primary</div>
</div>
<div class="col-md-2">
<div class="btn btn-success">button success</div>
</div>
<div class="col-md-2">
<div class="btn btn-info">button info</div>
</div>
<div class="col-md-2">
<div class="btn btn-warning">button warning</div>
</div>
<div class="col-md-2">
<div class="btn btn-danger">button danger</div>
</div>
</div>
<br>
<div class="row">
<div class="col-md-2">
<div class="btn btn-default disabled">button disabled</div>
</div>
<div class="col-md-2">
<div class="btn btn-primary" disabled="">disabled=""</div>
</div>
<div class="col-md-2">
<div class="btn btn-success" disabled>disabled</div>
</div>
<div class="col-md-2">
<div class="btn btn-info" disabled>disabled</div>
</div>
<div class="col-md-2">
<div class="btn btn-warning" disabled>disabled</div>
</div>
<div class="col-md-2">
<div class="btn btn-danger" disabled="">disabled</div>
</div>
</div>
<br>
<div class="row">
<div class="col-md-2">
<div class="btn btn-default btn-lg ">button lg</div>
</div>
<div class="col-md-2">
<div class="btn btn-primary btn-lg">button lg</div>
</div>
<div class="col-md-2">
<div class="btn btn-success btn-lg">button lg</div>
</div>
<div class="col-md-2">
<div class="btn btn-info btn-lg">button lg</div>
</div>
<div class="col-md-2">
<div class="btn btn-warning btn-lg">button lg</div>
</div>
<div class="col-md-2">
<div class="btn btn-danger btn-lg">button lg</div>
</div>
</div>
<br>
<div><h2>由button.scss生成的,新的色调的button,依此你便可以批量生成:</h2></div>
<pre>$btn-mine-color:#ffffff; //字体颜色
$btn-mine-bg:#1ABC9C; //背景色
$btn-mine-border: darken($btn-mine-bg, 5%) !default; //边框色
.btn-mine {
@include button-variant($btn-mine-color, $btn-mine-bg, $btn-mine-border);
}
</pre>
<div class="row">
<div class="col-md-2">
<div class="btn btn-mine btn-lg ">button mine lg</div>
</div>
</div>
</div>
</body>
</html>