Permalink
Browse files

feat(breadcrumb-link): support children elements (#1832) (#1833)

  • Loading branch information...
jackmu95 authored and pi0 committed May 17, 2018
1 parent e3e5439 commit 42175f80047ad7b2ad20ec5de13402d9e01c0dfe
Showing with 2 additions and 6 deletions.
  1. +2 −6 src/components/breadcrumb/breadcrumb-link.js
@@ -28,17 +28,13 @@ export default {
render (h, { props: suppliedProps, data, children }) {
const tag = suppliedProps.active ? 'span' : Link
let componentData = {
props: pluckProps(props, suppliedProps),
domProps: { innerHTML: suppliedProps.text }
}
let componentData = { props: pluckProps(props, suppliedProps) }
if (suppliedProps.active) {
componentData.attrs = { 'aria-current': suppliedProps.ariaCurrent }
} else {
componentData.attrs = { href: suppliedProps.href }
}
return h(tag, mergeData(data, componentData), children)
return h(tag, mergeData(data, componentData), children || suppliedProps.text)
}
}

0 comments on commit 42175f8

Please sign in to comment.