Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
H
hls-easy-ui
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
easyUI
hls-easy-ui
Commits
7f91df80
Commit
7f91df80
authored
Aug 26, 2020
by
JingChao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
field组件
parent
8cb8f354
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
36 deletions
+7
-36
Item.vue
packages/components/ListItem/Item.vue
+7
-36
No files found.
packages/components/ListItem/Item.vue
View file @
7f91df80
<
template
>
<div
:class=
"[showActivated,
focus,focusBorder
]"
:class=
"[showActivated,
cusClass
]"
:style=
"
{'min-height':minHeight}"
class="hls-item">
<div
...
...
@@ -11,22 +11,15 @@
@
touchcancel=
"end"
@
mousedown=
"start"
@
mouseup=
"end"
<<<<<<<
HEAD
@
mouseleave=
"end"
@
focusin=
"focusin"
@
focusout=
"focusout"
>
<div
v-if=
"showName"
:style=
"
{'min-height':minHeight,'flex':proportion[0] }" class="add-name">
=======
@
mouseleave=
"end"
>
<div
v-if=
"showName && hasName"
:style=
"
{'min-height':minHeight,'flex':proportion[0] }" class="add-name">
>>>>>>> develop
<slot
name=
"left-icon"
/>
<slot
name=
"name"
/>
</div>
<div
v-if=
"showContent && hasContent"
:style=
"
{'min-height':minHeight,'flex':proportion[1] }" class="add-content">
<slot
name=
"content"
/>
<slot
name=
"right-icon"
/>
<img
v-if=
"showArrow"
:src=
"rightIcon"
class=
"right-icon"
>
<img
v-if=
"showArrow"
:src=
"rightIcon"
class=
"right-icon"
style=
"height: 0.2rem"
>
</div>
<slot/>
</div>
...
...
@@ -60,6 +53,10 @@ export default {
type
:
String
,
default
:
''
,
},
cusClass
:
{
type
:
String
,
default
:
''
,
},
hasBorder
:
{
type
:
Boolean
,
default
:
true
,
...
...
@@ -68,16 +65,10 @@ export default {
type
:
Number
,
default
:
0
,
},
showFocusBorder
:
{
type
:
Boolean
,
default
:
false
,
},
},
data
()
{
return
{
showActivated
:
''
,
focus
:
''
,
focusBorder
:
''
,
hasTouchEvent
:
'ontouchstart'
in
document
,
Icon
:
require
(
'./right-gray@2x.png'
),
}
...
...
@@ -106,18 +97,6 @@ export default {
// 移动浏览器中长按元素会触发显示菜单,导致touchend事件不会触发,需要阻止该行为
e
.
preventDefault
()
},
focusin
()
{
let
vm
=
this
let
showFocus
=
vm
.
showFocusBorder
?
vm
.
showFocusBorder
:
vm
.
$parent
.
showFocusBorder
vm
.
focus
=
'focus'
if
(
showFocus
)
{
vm
.
focusBorder
=
'focus-border'
}
},
focusout
()
{
this
.
focus
=
''
this
.
focusBorder
=
''
},
start
(
e
)
{
if
(
e
.
target
.
readOnly
)
return
if
(
e
.
target
.
nodeName
===
'INPUT'
||
e
.
target
.
nodeName
===
'TEXTAREA'
||
e
.
target
.
nodeName
===
'BUTTON'
||
e
.
target
.
nodeName
===
'LABEL'
)
return
...
...
@@ -136,6 +115,7 @@ export default {
</
script
>
<
style
lang=
"less"
>
@import "../../common/styles/variables";
.hls-item {
//height: 100px;
width: 100%;
...
...
@@ -146,14 +126,6 @@ export default {
&.activated {
opacity: 0.8;
}
&.focus-border{
.contents {
&:after {
border-bottom: 2px solid rgba(0, 65, 196, 1); /*no*/
color: rgba(0, 65, 196, 1);
}
}
}
.contents {
height: 100%;
...
...
@@ -235,7 +207,6 @@ export default {
//右侧图标
.right-icon {
margin-left: 5px;
height: 0.2rem;
}
//toggle
...
...
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