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
ba983ffb
Commit
ba983ffb
authored
Nov 26, 2016
by
baiyaaaaa
Committed by
cinwell.li
Nov 26, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
normalize the componentName writing
parent
66b055f9
Changes
10
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
31 additions
and
29 deletions
+31
-29
packages/checkbox/src/checkbox-group.vue
packages/checkbox/src/checkbox-group.vue
+1
-1
packages/date-picker/src/picker.vue
packages/date-picker/src/picker.vue
+2
-2
packages/form/src/form-item.vue
packages/form/src/form-item.vue
+4
-4
packages/form/src/form.vue
packages/form/src/form.vue
+1
-1
packages/input/src/input.vue
packages/input/src/input.vue
+4
-2
packages/radio/src/radio-group.vue
packages/radio/src/radio-group.vue
+1
-1
packages/select/src/option-group.vue
packages/select/src/option-group.vue
+2
-2
packages/select/src/option.vue
packages/select/src/option.vue
+5
-5
packages/select/src/select-dropdown.vue
packages/select/src/select-dropdown.vue
+1
-1
packages/select/src/select.vue
packages/select/src/select.vue
+10
-10
No files found.
packages/checkbox/src/checkbox-group.vue
View file @
ba983ffb
...
...
@@ -15,7 +15,7 @@
watch
:
{
value
(
value
)
{
this
.
$emit
(
'
change
'
,
value
);
this
.
dispatch
(
'
form-i
tem
'
,
'
el.form.change
'
,
[
value
]);
this
.
dispatch
(
'
ElFormI
tem
'
,
'
el.form.change
'
,
[
value
]);
this
.
broadcast
(
'
ElCheckbox
'
,
'
initData
'
,
[
value
]);
}
},
...
...
packages/date-picker/src/picker.vue
View file @
ba983ffb
...
...
@@ -236,7 +236,7 @@ export default {
if
(
!
val
&&
this
.
picker
&&
typeof
this
.
picker
.
handleClear
===
'
function
'
)
{
this
.
picker
.
handleClear
();
}
this
.
dispatch
(
'
form-i
tem
'
,
'
el.form.change
'
);
this
.
dispatch
(
'
ElFormI
tem
'
,
'
el.form.change
'
);
},
value
:
{
immediate
:
true
,
...
...
@@ -358,7 +358,7 @@ export default {
handleBlur
()
{
this
.
$emit
(
'
blur
'
,
this
);
this
.
dispatch
(
'
form-i
tem
'
,
'
el.form.blur
'
);
this
.
dispatch
(
'
ElFormI
tem
'
,
'
el.form.blur
'
);
},
handleKeydown
(
event
)
{
...
...
packages/form/src/form-item.vue
View file @
ba983ffb
...
...
@@ -47,7 +47,7 @@
export
default
{
name
:
'
ElFormItem
'
,
componentName
:
'
form-i
tem
'
,
componentName
:
'
ElFormI
tem
'
,
mixins
:
[
emitter
],
...
...
@@ -88,7 +88,7 @@
},
form
()
{
var
parent
=
this
.
$parent
;
while
(
parent
.
$options
.
componentName
!==
'
f
orm
'
)
{
while
(
parent
.
$options
.
componentName
!==
'
ElF
orm
'
)
{
parent
=
parent
.
$parent
;
}
return
parent
;
...
...
@@ -192,7 +192,7 @@
},
mounted
()
{
if
(
this
.
prop
)
{
this
.
dispatch
(
'
f
orm
'
,
'
el.form.addField
'
,
[
this
]);
this
.
dispatch
(
'
ElF
orm
'
,
'
el.form.addField
'
,
[
this
]);
Object
.
defineProperty
(
this
,
'
initialValue
'
,
{
value
:
this
.
fieldValue
...
...
@@ -213,7 +213,7 @@
}
},
beforeDestroy
()
{
this
.
dispatch
(
'
f
orm
'
,
'
el.form.removeField
'
,
[
this
]);
this
.
dispatch
(
'
ElF
orm
'
,
'
el.form.removeField
'
,
[
this
]);
}
};
</
script
>
packages/form/src/form.vue
View file @
ba983ffb
...
...
@@ -10,7 +10,7 @@
export
default
{
name
:
'
ElForm
'
,
componentName
:
'
f
orm
'
,
componentName
:
'
ElF
orm
'
,
props
:
{
model
:
Object
,
...
...
packages/input/src/input.vue
View file @
ba983ffb
...
...
@@ -68,6 +68,8 @@
export
default
{
name
:
'
ElInput
'
,
componentName
:
'
ElInput
'
,
mixins
:
[
emitter
],
props
:
{
...
...
@@ -105,7 +107,7 @@
methods
:
{
handleBlur
(
event
)
{
this
.
$emit
(
'
blur
'
,
event
);
this
.
dispatch
(
'
form-i
tem
'
,
'
el.form.blur
'
,
[
this
.
currentValue
]);
this
.
dispatch
(
'
ElFormI
tem
'
,
'
el.form.blur
'
,
[
this
.
currentValue
]);
},
inputSelect
()
{
this
.
$refs
.
input
.
select
();
...
...
@@ -162,7 +164,7 @@
});
this
.
$emit
(
'
input
'
,
val
);
this
.
$emit
(
'
change
'
,
val
);
this
.
dispatch
(
'
form-i
tem
'
,
'
el.form.change
'
,
[
val
]);
this
.
dispatch
(
'
ElFormI
tem
'
,
'
el.form.change
'
,
[
val
]);
}
}
};
...
...
packages/radio/src/radio-group.vue
View file @
ba983ffb
...
...
@@ -16,7 +16,7 @@
value
(
value
)
{
this
.
$emit
(
'
change
'
,
value
);
this
.
broadcast
(
'
ElRadio
'
,
'
initData
'
,
value
);
this
.
dispatch
(
'
form-i
tem
'
,
'
el.form.change
'
,
[
this
.
value
]);
this
.
dispatch
(
'
ElFormI
tem
'
,
'
el.form.change
'
,
[
this
.
value
]);
}
},
mounted
()
{
...
...
packages/select/src/option-group.vue
View file @
ba983ffb
...
...
@@ -27,13 +27,13 @@
watch
:
{
disabled
(
val
)
{
this
.
broadcast
(
'
o
ption
'
,
'
handleGroupDisabled
'
,
val
);
this
.
broadcast
(
'
ElO
ption
'
,
'
handleGroupDisabled
'
,
val
);
}
},
mounted
()
{
if
(
this
.
disabled
)
{
this
.
broadcast
(
'
o
ption
'
,
'
handleGroupDisabled
'
,
this
.
disabled
);
this
.
broadcast
(
'
ElO
ption
'
,
'
handleGroupDisabled
'
,
this
.
disabled
);
}
}
};
...
...
packages/select/src/option.vue
View file @
ba983ffb
...
...
@@ -19,7 +19,7 @@
name
:
'
el-option
'
,
componentName
:
'
o
ption
'
,
componentName
:
'
ElO
ption
'
,
props
:
{
value
:
{
...
...
@@ -78,7 +78,7 @@
watch
:
{
currentSelected
(
val
)
{
if
(
val
===
true
)
{
this
.
dispatch
(
'
s
elect
'
,
'
addOptionToValue
'
,
this
);
this
.
dispatch
(
'
ElS
elect
'
,
'
addOptionToValue
'
,
this
);
}
}
},
...
...
@@ -96,7 +96,7 @@
selectOptionClick
()
{
if
(
this
.
disabled
!==
true
&&
this
.
groupDisabled
!==
true
)
{
this
.
dispatch
(
'
s
elect
'
,
'
handleOptionClick
'
,
this
);
this
.
dispatch
(
'
ElS
elect
'
,
'
handleOptionClick
'
,
this
);
}
},
...
...
@@ -123,7 +123,7 @@
this
.
index
=
this
.
parent
.
options
.
indexOf
(
this
);
if
(
this
.
currentSelected
===
true
)
{
this
.
dispatch
(
'
s
elect
'
,
'
addOptionToValue
'
,
[
this
,
true
]);
this
.
dispatch
(
'
ElS
elect
'
,
'
addOptionToValue
'
,
[
this
,
true
]);
}
this
.
$on
(
'
queryChange
'
,
this
.
queryChange
);
...
...
@@ -132,7 +132,7 @@
},
beforeDestroy
()
{
this
.
dispatch
(
'
s
elect
'
,
'
onOptionDestroy
'
,
this
);
this
.
dispatch
(
'
ElS
elect
'
,
'
onOptionDestroy
'
,
this
);
}
};
</
script
>
packages/select/src/select-dropdown.vue
View file @
ba983ffb
...
...
@@ -13,7 +13,7 @@
export
default
{
name
:
'
el-select-dropdown
'
,
componentName
:
'
select-d
ropdown
'
,
componentName
:
'
ElSelectD
ropdown
'
,
mixins
:
[
Popper
],
...
...
packages/select/src/select.vue
View file @
ba983ffb
...
...
@@ -82,7 +82,7 @@
name
:
'
ElSelect
'
,
componentName
:
'
s
elect
'
,
componentName
:
'
ElS
elect
'
,
computed
:
{
iconClass
()
{
...
...
@@ -242,7 +242,7 @@
this
.
$emit
(
'
input
'
,
result
);
this
.
$emit
(
'
change
'
,
result
);
this
.
dispatch
(
'
form-i
tem
'
,
'
el.form.change
'
,
val
);
this
.
dispatch
(
'
ElFormI
tem
'
,
'
el.form.change
'
,
val
);
if
(
this
.
filterable
)
{
this
.
query
=
''
;
this
.
hoverIndex
=
-
1
;
...
...
@@ -262,7 +262,7 @@
query
(
val
)
{
this
.
$nextTick
(()
=>
{
this
.
broadcast
(
'
select-d
ropdown
'
,
'
updatePopper
'
);
this
.
broadcast
(
'
ElSelectD
ropdown
'
,
'
updatePopper
'
);
});
if
(
this
.
multiple
&&
this
.
filterable
)
{
this
.
resetInputHeight
();
...
...
@@ -271,12 +271,12 @@
this
.
hoverIndex
=
-
1
;
this
.
remoteMethod
(
val
);
this
.
voidRemoteQuery
=
val
===
''
;
this
.
broadcast
(
'
o
ption
'
,
'
resetIndex
'
);
this
.
broadcast
(
'
ElO
ption
'
,
'
resetIndex
'
);
}
else
if
(
typeof
this
.
filterMethod
===
'
function
'
)
{
this
.
filterMethod
(
val
);
}
else
{
this
.
filteredOptionsCount
=
this
.
optionsCount
;
this
.
broadcast
(
'
o
ption
'
,
'
queryChange
'
,
val
);
this
.
broadcast
(
'
ElO
ption
'
,
'
queryChange
'
,
val
);
}
},
...
...
@@ -286,7 +286,7 @@
if
(
this
.
$el
.
querySelector
(
'
.el-input__icon
'
))
{
removeClass
(
this
.
$el
.
querySelector
(
'
.el-input__icon
'
),
'
is-reverse
'
);
}
this
.
broadcast
(
'
select-d
ropdown
'
,
'
destroyPopper
'
);
this
.
broadcast
(
'
ElSelectD
ropdown
'
,
'
destroyPopper
'
);
if
(
this
.
$refs
.
input
)
{
this
.
$refs
.
input
.
blur
();
}
...
...
@@ -304,13 +304,13 @@
if
(
icon
&&
!
hasClass
(
icon
,
'
el-icon-circle-close
'
))
{
addClass
(
this
.
$el
.
querySelector
(
'
.el-input__icon
'
),
'
is-reverse
'
);
}
this
.
broadcast
(
'
select-d
ropdown
'
,
'
updatePopper
'
);
this
.
broadcast
(
'
ElSelectD
ropdown
'
,
'
updatePopper
'
);
if
(
this
.
filterable
)
{
this
.
query
=
this
.
selectedLabel
;
if
(
this
.
multiple
)
{
this
.
$refs
.
input
.
focus
();
}
else
{
this
.
broadcast
(
'
i
nput
'
,
'
inputSelect
'
);
this
.
broadcast
(
'
ElI
nput
'
,
'
inputSelect
'
);
}
}
if
(
!
this
.
dropdownUl
)
{
...
...
@@ -398,7 +398,7 @@
let
inputChildNodes
=
this
.
$refs
.
reference
.
$el
.
childNodes
;
let
input
=
[].
filter
.
call
(
inputChildNodes
,
item
=>
item
.
tagName
===
'
INPUT
'
)[
0
];
input
.
style
.
height
=
Math
.
max
(
this
.
$refs
.
tags
.
clientHeight
+
6
,
this
.
size
===
'
small
'
?
28
:
36
)
+
'
px
'
;
this
.
broadcast
(
'
select-d
ropdown
'
,
'
updatePopper
'
);
this
.
broadcast
(
'
ElSelectD
ropdown
'
,
'
updatePopper
'
);
});
},
...
...
@@ -525,7 +525,7 @@
if
(
index
>
-
1
)
{
this
.
options
.
splice
(
index
,
1
);
}
this
.
broadcast
(
'
o
ption
'
,
'
resetIndex
'
);
this
.
broadcast
(
'
ElO
ption
'
,
'
resetIndex
'
);
},
resetInputWidth
()
{
...
...
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