naive-ui/packages/mixins/themeable.js
2019-10-12 16:09:30 +08:00

18 lines
291 B
JavaScript

export default {
props: {
theme: {
type: String,
default: null
}
},
computed: {
synthesizedTheme () {
if (this.theme !== null) {
return this.theme
} else {
return (this.NApp && this.NApp.synthesizedTheme) || null
}
}
}
}