|
|
@ -17,23 +17,8 @@ export default { |
|
|
|
const { icon, title } = context.props; |
|
|
|
const vnodes = []; |
|
|
|
|
|
|
|
// if (icon) { |
|
|
|
// // vnodes.push(<svg-icon icon-class={icon} />); |
|
|
|
// vnodes.push(<img src={itmeIcon[title]} />); |
|
|
|
// } |
|
|
|
|
|
|
|
if (title) { |
|
|
|
console.log("title", title); |
|
|
|
|
|
|
|
if (title.length > 5) { |
|
|
|
vnodes.push( |
|
|
|
<span slot="title" title={title}> |
|
|
|
{title} |
|
|
|
</span> |
|
|
|
); |
|
|
|
} else { |
|
|
|
vnodes.push(<span slot="title">{title}</span>); |
|
|
|
} |
|
|
|
vnodes.push(<span slot="title">{title}</span>); |
|
|
|
} |
|
|
|
|
|
|
|
return vnodes; |
|
|
|