-
Notifications
You must be signed in to change notification settings - Fork 4
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
11 changed files
with
603 additions
and
66 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
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
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,100 @@ | ||
@import './variables.less'; | ||
|
||
.@{namespace}-color-picker { | ||
&__preview { | ||
width: 20px; | ||
height: 20px; | ||
cursor: pointer; | ||
border-radius: 6px; | ||
} | ||
|
||
&__content { | ||
.setCssVar(color-picker-bg-color, #ffffff); | ||
|
||
box-sizing: border-box; | ||
background: .getCssVar(color-picker-bg-color) []; | ||
border-radius: 6px; | ||
box-shadow: 0 0 6px #b2b5b8; | ||
width: 197px; | ||
height: 186px; | ||
padding: 8px; | ||
} | ||
|
||
&__selector { | ||
width: 150px; | ||
height: 150px; | ||
position: absolute; | ||
} | ||
|
||
&__background { | ||
width: 100%; | ||
height: 100%; | ||
background: linear-gradient(to top, #000 0%, rgba(0, 0, 0, 0) 100%), | ||
linear-gradient(to right, #fff 0%, rgba(255, 255, 255, 0) 100%); | ||
&-handle { | ||
box-sizing: border-box; | ||
position: absolute; | ||
top: 0px; | ||
left: 150px; | ||
border-radius: 100%; | ||
width: 10px; | ||
height: 10px; | ||
border: 1px solid #ffffff; | ||
cursor: pointer; | ||
transform: translate(-5px, -5px); | ||
opacity: 0.85; | ||
} | ||
} | ||
|
||
&__hue { | ||
width: 12px; | ||
height: 150px; | ||
margin-left: 164px; | ||
position: absolute; | ||
opacity: 0.85; | ||
background: linear-gradient(0deg, red 0, #ff0 17%, #0f0 33%, #0ff 50%, #00f 67%, #f0f 83%, red); | ||
&-handle { | ||
box-sizing: border-box; | ||
position: absolute; | ||
width: 16px; | ||
height: 10px; | ||
transform: translate(-2px, -5px); | ||
border: 2px solid #ffffff; | ||
opacity: 0.85; | ||
cursor: pointer; | ||
} | ||
} | ||
|
||
&__alpha { | ||
width: 150px; | ||
height: 12px; | ||
position: absolute; | ||
margin-top: 158px; | ||
background: linear-gradient(45deg, #ccc 25%, transparent 25%), linear-gradient(135deg, #ccc 25%, transparent 25%), | ||
linear-gradient(45deg, transparent 75%, #ccc 75%), linear-gradient(135deg, transparent 75%, #ccc 75%); | ||
background-size: 12px 12px; | ||
background-position: | ||
0 0, | ||
6px 0, | ||
6px -6px, | ||
0 6px; | ||
&-bg { | ||
position: relative; | ||
height: 100%; | ||
background: linear-gradient(to right, rgba(255, 255, 255, 0) 0%, #ffffff 100%); | ||
} | ||
&-handle { | ||
box-sizing: border-box; | ||
position: absolute; | ||
opacity: 0.85; | ||
cursor: pointer; | ||
top: 0; | ||
width: 10px; | ||
height: 16px; | ||
transform: translate(-5px, -2px); | ||
border: 1px solid #ebeef5; | ||
background-color: #ffffff; | ||
box-shadow: 0 0 2px #0009; | ||
} | ||
} | ||
} |
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
Oops, something went wrong.