Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
Element
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
CI / CD Analytics
Repository Analytics
Value Stream Analytics
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
林焕东
Element
Commits
62a1df61
Commit
62a1df61
authored
Aug 29, 2016
by
Leopoldthecoder
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
link to variables
parent
b527ca88
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
21 additions
and
14 deletions
+21
-14
examples/docs/rate.md
examples/docs/rate.md
+5
-5
packages/theme-default/src/common/var.css
packages/theme-default/src/common/var.css
+7
-0
packages/theme-default/src/message.css
packages/theme-default/src/message.css
+1
-1
packages/theme-default/src/notification.css
packages/theme-default/src/notification.css
+1
-1
packages/theme-default/src/slider.css
packages/theme-default/src/slider.css
+7
-7
No files found.
examples/docs/rate.md
View file @
62a1df61
...
@@ -44,7 +44,7 @@
...
@@ -44,7 +44,7 @@
```
```
:::
:::
## 辅助文字
##
#
辅助文字
用辅助文字直接地表达对应分数
用辅助文字直接地表达对应分数
...
@@ -57,7 +57,7 @@
...
@@ -57,7 +57,7 @@
```
```
:::
:::
## 其他 icon
##
#
其他 icon
:::demo 当有多层评价时,可以用不同类型的 icon 区分评分层级
:::demo 当有多层评价时,可以用不同类型的 icon 区分评分层级
```
html
```
html
...
@@ -70,7 +70,7 @@
...
@@ -70,7 +70,7 @@
```
```
:::
:::
## 只读
##
#
只读
只读的评分用来展示分数,允许出现半星
只读的评分用来展示分数,允许出现半星
...
@@ -86,7 +86,7 @@
...
@@ -86,7 +86,7 @@
```
```
:::
:::
## Attributes
##
#
Attributes
| 参数 | 说明 | 类型 | 可选值 | 默认值 |
| 参数 | 说明 | 类型 | 可选值 | 默认值 |
|---------- |-------- |---------- |------------- |-------- |
|---------- |-------- |---------- |------------- |-------- |
| max | 最大分值 | Number | - | 5 |
| max | 最大分值 | Number | - | 5 |
...
@@ -105,7 +105,7 @@
...
@@ -105,7 +105,7 @@
| texts | 辅助文字数组 | Array | - |
[
'极差', '失望', '一般', '满意', '惊喜'
]
|
| texts | 辅助文字数组 | Array | - |
[
'极差', '失望', '一般', '满意', '惊喜'
]
|
| text-template | 只读时的辅助文字模板 | String | - | {value} |
| text-template | 只读时的辅助文字模板 | String | - | {value} |
## Events
##
#
Events
| 事件名称 | 说明 | 回调参数 |
| 事件名称 | 说明 | 回调参数 |
|---------- |-------- |---------- |
|---------- |-------- |---------- |
| change | 分值改变时触发 | 改变后的分值 |
| change | 分值改变时触发 | 改变后的分值 |
...
...
packages/theme-default/src/common/var.css
View file @
62a1df61
...
@@ -373,6 +373,13 @@
...
@@ -373,6 +373,13 @@
--card-border-radius
:
4px
;
--card-border-radius
:
4px
;
--card-padding
:
20px
;
--card-padding
:
20px
;
/*Slider
--------------------------*/
--slider-main-background-color
:
var
(
--color-primary
);
--slider-runway-background-color
:
#e5e9f2
;
--slider-runway-hover-color
:
#1d8ce0
;
--slider-stop-background-color
:
#c0ccda
;
/*Steps
/*Steps
--------------------------*/
--------------------------*/
--steps-border-color
:
var
(
--disabled-border-base
);
--steps-border-color
:
var
(
--disabled-border-base
);
...
...
packages/theme-default/src/message.css
View file @
62a1df61
...
@@ -15,7 +15,7 @@
...
@@ -15,7 +15,7 @@
background-color
:
#fff
;
background-color
:
#fff
;
transition
:
opacity
0.3s
,
top
0.4s
;
transition
:
opacity
0.3s
,
top
0.4s
;
overflow
:
hidden
;
overflow
:
hidden
;
z-index
:
2000
;
z-index
:
var
(
--index-popper
)
;
@e
group
{
@e
group
{
margin-left
:
28px
;
margin-left
:
28px
;
...
...
packages/theme-default/src/notification.css
View file @
62a1df61
...
@@ -14,7 +14,7 @@
...
@@ -14,7 +14,7 @@
box-shadow
:
0
0
6px
rgba
(
0
,
0
,
0
,
.04
),
0
2px
4px
rgba
(
0
,
0
,
0
,
.12
);
box-shadow
:
0
0
6px
rgba
(
0
,
0
,
0
,
.04
),
0
2px
4px
rgba
(
0
,
0
,
0
,
.12
);
transition
:
opacity
0.3s
,
transform
.3s
,
right
.3s
,
top
0.4s
;
transition
:
opacity
0.3s
,
transform
.3s
,
right
.3s
,
top
0.4s
;
overflow
:
hidden
;
overflow
:
hidden
;
z-index
:
2000
;
z-index
:
var
(
--index-popper
)
;
@e
group
{
@e
group
{
&
span
{
&
span
{
...
...
packages/theme-default/src/slider.css
View file @
62a1df61
...
@@ -7,7 +7,7 @@
...
@@ -7,7 +7,7 @@
width
:
100%
;
width
:
100%
;
height
:
4px
;
height
:
4px
;
margin
:
20px
0
;
margin
:
20px
0
;
background-color
:
#E5E9F2
;
background-color
:
var
(
--slider-runway-background-color
)
;
border-radius
:
3px
;
border-radius
:
3px
;
position
:
relative
;
position
:
relative
;
cursor
:
pointer
;
cursor
:
pointer
;
...
@@ -30,7 +30,7 @@
...
@@ -30,7 +30,7 @@
@e
bar
{
@e
bar
{
height
:
4px
;
height
:
4px
;
background-color
:
#20A0FF
;
background-color
:
var
(
--slider-main-background-color
)
;
border-top-left-radius
:
3px
;
border-top-left-radius
:
3px
;
border-bottom-left-radius
:
3px
;
border-bottom-left-radius
:
3px
;
position
:
absolute
;
position
:
absolute
;
...
@@ -47,7 +47,7 @@
...
@@ -47,7 +47,7 @@
@e
button
{
@e
button
{
size
:
12px
;
size
:
12px
;
background-color
:
#20A0FF
;
background-color
:
var
(
--slider-main-background-color
)
;
border-radius
:
50%
;
border-radius
:
50%
;
position
:
absolute
;
position
:
absolute
;
top
:
12px
;
top
:
12px
;
...
@@ -70,7 +70,7 @@
...
@@ -70,7 +70,7 @@
text-align
:
center
;
text-align
:
center
;
size
:
26px
;
size
:
26px
;
border-radius
:
50
%;
border-radius
:
50
%;
background-color
:
#20A0FF
;
background-color
:
var
(
--slider-main-background-color
)
;
color
:
#fff
;
color
:
#fff
;
cursor
:
default
;
cursor
:
default
;
z-index
:
var
(
--index-top
);
z-index
:
var
(
--index-top
);
...
@@ -78,14 +78,14 @@
...
@@ -78,14 +78,14 @@
transform-origin
:
center
bottom
;
transform-origin
:
center
bottom
;
&
::before
{
&
::before
{
triangle
:
9px
top
#20A0FF
;
triangle
:
9px
top
var
(
--slider-main-background-color
)
;
position
:
absolute
;
position
:
absolute
;
top
:
-14px
;
top
:
-14px
;
left
:
4px
;
left
:
4px
;
}
}
&
::after
{
&
::after
{
triangle
:
9px
bottom
#20A0FF
;
triangle
:
9px
bottom
var
(
--slider-main-background-color
)
;
position
:
absolute
;
position
:
absolute
;
bottom
:
-14px
;
bottom
:
-14px
;
left
:
4px
;
left
:
4px
;
...
@@ -104,7 +104,7 @@
...
@@ -104,7 +104,7 @@
position
:
absolute
;
position
:
absolute
;
size
:
4px
;
size
:
4px
;
border-radius
:
50%
;
border-radius
:
50%
;
background-color
:
#c0ccda
;
background-color
:
var
(
--slider-stop-background-color
)
;
transform
:
translateX
(
-50%
);
transform
:
translateX
(
-50%
);
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment