This repository has been archived on 2024-07-27. You can view files and clone it, but cannot push or open issues or pull requests.
keksAccountGUI/node_modulesOLD/vuetify/lib/components/VOverlay/VOverlay.js

85 lines
1.7 KiB
JavaScript
Raw Permalink Normal View History

2019-08-11 18:48:02 +00:00
// Styles
import "../../../src/components/VOverlay/VOverlay.sass"; // Mixins
import Colorable from './../../mixins/colorable';
import Themeable from '../../mixins/themeable';
import Toggleable from './../../mixins/toggleable'; // Utilities
import mixins from '../../util/mixins';
/* @vue/component */
export default mixins(Colorable, Themeable, Toggleable).extend({
name: 'v-overlay',
props: {
absolute: Boolean,
color: {
type: String,
default: '#212121'
},
dark: {
type: Boolean,
default: true
},
opacity: {
type: [Number, String],
default: 0.46
},
value: {
default: true
},
zIndex: {
type: [Number, String],
default: 5
}
},
computed: {
__scrim() {
const data = this.setBackgroundColor(this.color, {
staticClass: 'v-overlay__scrim',
style: {
opacity: this.computedOpacity
}
});
return this.$createElement('div', data);
},
classes() {
return {
'v-overlay--absolute': this.absolute,
'v-overlay--active': this.isActive,
...this.themeClasses
};
},
computedOpacity() {
return Number(this.isActive ? this.opacity : 0);
},
styles() {
return {
zIndex: this.zIndex
};
}
},
methods: {
genContent() {
return this.$createElement('div', {
staticClass: 'v-overlay__content'
}, this.$slots.default);
}
},
render(h) {
const children = [this.__scrim];
if (this.isActive) children.push(this.genContent());
return h('div', {
staticClass: 'v-overlay',
class: this.classes,
style: this.styles
}, children);
}
});
//# sourceMappingURL=VOverlay.js.map