import { Prop, toNative } from 'vue-facing-decorator'; import PowerduckState from '../../app/powerduck-state'; import TsxComponent, { Component } from '../../app/vuetsx'; import { ModalSectionMode } from '../../common/enums/modal'; import { SlotNameIdentifier } from '../../common/slot-name-identifier'; import Fieldset from '../form/fieldset'; interface TabPageArgs { navCaption: string; navCaptionShort?: string; tabCaption?: string; escapeCaption?: boolean; collapsedByDefault?: boolean; icon: string; uuid?: string; } @Component class ModalSectionComponent extends TsxComponent implements TabPageArgs { @Prop() navCaption!: string; @Prop() navCaptionShort!: string; @Prop() tabCaption!: string; @Prop() escapeCaption?: boolean; @Prop() icon!: string; @Prop() uuid!: string; @Prop() collapsedByDefault: boolean; active: boolean = false; render(h) { if (PowerduckState.getModalSectionMode() == ModalSectionMode.fieldSet) { return (
{this.$slots.default?.()}
); } return
{this.$slots.default?.()}
; } } SlotNameIdentifier(ModalSectionComponent, 'TabPage'); const ModalSection = toNative(ModalSectionComponent); export default ModalSection;