修复timeline组件的slot读取
parent
9ee341d09c
commit
64b3d8b678
|
@ -151,7 +151,7 @@ class Sandbox extends Component {
|
|||
|
||||
created() {
|
||||
bind(this.root, 'slotchange', ev => {
|
||||
let slot = ev.target.assignedNodes().pop()
|
||||
let slot = ev.target.assignedElements().pop()
|
||||
|
||||
// 移除不合法的子组件
|
||||
|
||||
|
|
|
@ -477,7 +477,7 @@ class Tabs extends Component {
|
|||
|
||||
created() {
|
||||
bind(this.root, 'slotchange', ev => {
|
||||
let children = ev.target.assignedNodes()
|
||||
let children = ev.target.assignedElements()
|
||||
|
||||
// 移除不合法的子组件
|
||||
for (let it of children) {
|
||||
|
|
|
@ -34,7 +34,7 @@ class Timeline extends Component {
|
|||
]
|
||||
created() {
|
||||
bind(this.root, 'slotchange', ev => {
|
||||
let children = ev.target.assignedNodes()
|
||||
let children = ev.target.assignedElements()
|
||||
|
||||
children.forEach((it, i) => {
|
||||
it.removeAttribute('last')
|
||||
|
|
Loading…
Reference in New Issue