-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
9 changed files
with
72 additions
and
120 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,22 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
|
||
<head> | ||
<meta charset="UTF-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
<meta http-equiv="X-UA-Compatible" content="ie=edge"> | ||
<title>skin-switch</title> | ||
<!-- inject:css --> | ||
<!-- endinject --> | ||
</head> | ||
|
||
<body> | ||
<div class="app"> | ||
<div class="view1"></div> | ||
<div class="view2"></div> | ||
</div> | ||
<!-- inject:js --> | ||
<!-- endinject --> | ||
</body> | ||
|
||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,12 @@ | ||
let isDefault = true; | ||
|
||
function changeSkin(){ | ||
console.log('changing '); | ||
} | ||
isDefault = !isDefault; | ||
const linkTag = document.getElementById('theme'); | ||
linkTag.href=`/dist/style/${isDefault?'default':'light'}.css` | ||
} | ||
|
||
const btn = document.createElement('button'); | ||
btn.innerText="toggle skin"; | ||
btn.onclick = changeSkin; | ||
document.body.append(btn) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,35 +1 @@ | ||
//字体 | ||
$font-family-base:Microsoft YaHei; //基础字体 | ||
$font-size-large:24px; | ||
$font-size-base:14px; //基础字号 | ||
$font-size-mini:12px; | ||
|
||
//主盒 | ||
$z-index:999; //默认 | ||
|
||
//提示状态颜色 | ||
$success: #00cc00; | ||
$error: red; | ||
$info: #409eff; | ||
$before: #409eff; | ||
|
||
//bug | ||
$bug-type-1:red; | ||
$bug-type-2:orange; | ||
$bug-type-3:#3399ff; | ||
$bug-type-4:#00cc00; | ||
|
||
//文本溢出 | ||
@mixin overflow-text($line) { | ||
overflow: hidden; | ||
text-overflow: ellipsis; | ||
display: -webkit-box; | ||
-webkit-line-clamp: $line; | ||
-webkit-box-orient: vertical; | ||
} | ||
|
||
@mixin light-font { | ||
font-size: $font-size-mini; | ||
color: $font-color-light; | ||
} | ||
|
||
$size:100px; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,51 +1 @@ | ||
$base-green:#a6d669; | ||
$base-blue:#58c8f2; | ||
$base-yellow:#f8d348; | ||
$base-red:#ff6d61; | ||
|
||
|
||
//背景 | ||
$bg-gray:#F2F2F3; //灰色背景 | ||
$bg-base:white; //白色背景 | ||
$bg-btn:#1ED2E3; //按钮背景 | ||
$bg-msg:#FC2D2D; //消息背景 | ||
$pop-bg:rgba(0, 0, 0, .6); //弹窗背景 | ||
$bg-nav-light-blue:#EEF2F8; //左侧菜单背景色 | ||
|
||
$bg-base-light:#f1f2f7; | ||
$bg-base-alpha:rgba(102,102,102,.1); | ||
|
||
$bg-menu-dark:#2a3542; | ||
$bg-menu-light:#35404d; | ||
|
||
$color-act:#347BFC; //行为颜色 | ||
//边框 | ||
$border-color-light:#f5f5f5; | ||
|
||
$btn-color-primary:#326CFC; | ||
$btn-color-primary-hover:#4278FF; | ||
|
||
$btn-color-cancel:#FFFFFF; | ||
$btn-color-cancel-hover:#E5E8EF; | ||
|
||
$button-plain-color: #409eff; | ||
$button-plain-background: #ecf5ff; | ||
$button-plain-border-color: #b3d8ff; | ||
|
||
|
||
$table-bg-odd:#EEF2F8; | ||
$table-bg-even:white; | ||
$table-bg-stripe:#FAFAFA; | ||
|
||
|
||
$box-shadow-light:rgba(167,188,209,0.22); | ||
$box-shadow-dark:rgba(0,0,0,0.4); | ||
|
||
$rancher-green: #87e3ae; | ||
$rancher-green-bg: #daf6e6; | ||
|
||
$font-color-base:black; | ||
$font-color-normal:#5d5c5a; | ||
$font-color-light:#c6cad6; | ||
$font-color-blue:#46aadc; | ||
$font-color-msg:red; | ||
$bg-color:red; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
$bg-color:green; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
.view1{ | ||
height: 100px; | ||
background:green; | ||
height: $size; | ||
width:$size; | ||
background:$bg-color; | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
["default","light"] |