Browse Source

removed overpaint and repr helpers

David Sehnal 5 years ago
parent
commit
aee7f4988a

+ 0 - 183
src/mol-plugin-ui/structure/representation.tsx

@@ -1,183 +0,0 @@
-/**
- * Copyright (c) 2019-2020 mol* contributors, licensed under MIT, See LICENSE file for more info.
- *
- * @author Alexander Rose <alexander.rose@weirdbyte.de>
- */
-
-import * as React from 'react';
-import { PluginUIComponent, CollapsableState, CollapsableProps } from '../base';
-import { Structure, StructureElement } from '../../mol-model/structure';
-import { isEmptyLoci } from '../../mol-model/loci';
-import { ParameterControls } from '../controls/parameters';
-import { Color } from '../../mol-util/color';
-import { ButtonSelect, Options } from '../controls/common'
-import { ParamDefinition as PD } from '../../mol-util/param-definition';
-import { VisualQuality, VisualQualityOptions } from '../../mol-geo/geometry/base';
-import { CollapsableControls } from '../base';
-import { StateSelection, StateObject } from '../../mol-state';
-import { PluginStateObject } from '../../mol-plugin-state/objects';
-import { ColorOptions } from '../controls/color';
-import { InteractionsProvider } from '../../mol-model-props/computed/interactions';
-
-interface BaseStructureRepresentationControlsState {
-    isDisabled: boolean
-}
-
-abstract class BaseStructureRepresentationControls extends PluginUIComponent<{}, BaseStructureRepresentationControlsState> {
-    abstract label: string
-    abstract lociGetter(structure: Structure): StructureElement.Loci
-
-    state = {
-        isDisabled: false
-    }
-
-    /** root structures */
-    protected get structures() {
-        return this.plugin.state.dataState.select(StateSelection.Generators.rootsOfType(PluginStateObject.Molecule.Structure)).map(s => s.obj!.data)
-    }
-
-    /** applicable types */
-    private get types() {
-        const types: [string, string][] = []
-        const structures = this.structures
-        for (const e of this.plugin.structureRepresentation.registry.list) {
-            if (structures.some(s => e.provider.isApplicable(s))) {
-                types.push([e.name, e.provider.label])
-            }
-        }
-        return types
-    }
-
-    private forceUpdateIfStructure = (obj?: StateObject) => {
-        if (obj && obj.type === PluginStateObject.Molecule.Structure.type) {
-            this.forceUpdate()
-        }
-    }
-
-    componentDidMount() {
-        this.subscribe(this.plugin.events.state.object.created, ({ obj }) => this.forceUpdateIfStructure(obj))
-
-        this.subscribe(this.plugin.events.state.object.removed, ({ obj }) => this.forceUpdateIfStructure(obj))
-
-        this.subscribe(this.plugin.state.dataState.events.isUpdating, v => this.setState({ isDisabled: v }))
-    }
-
-    show = (value: string) => {
-        this.plugin.helpers.structureRepresentation.set('add', value, this.lociGetter)
-    }
-
-    hide = (value: string) => {
-        if (value === '__all__') {
-            const { types } = this.plugin.structureRepresentation.registry
-            for (let i = 0, il = types.length; i < il; ++i) {
-                this.plugin.helpers.structureRepresentation.set('remove', types[i][0], this.lociGetter)
-            }
-        } else {
-            this.plugin.helpers.structureRepresentation.set('remove', value, this.lociGetter)
-        }
-    }
-
-    color = (value: string) => {
-        const color = Color(parseInt(value))
-        this.plugin.helpers.structureOverpaint.set(color, this.lociGetter)
-    }
-
-    render() {
-        const TypeOptions = Options(this.types)
-
-        return <div className='msp-control-row'>
-            <span title={this.label}>{this.label}</span>
-            <div className='msp-select-row'>
-                <ButtonSelect label='Show' onChange={this.show} disabled={this.state.isDisabled}>
-                    <optgroup label='Show'>{TypeOptions}</optgroup>
-                </ButtonSelect>
-                <ButtonSelect label='Hide' onChange={this.hide} disabled={this.state.isDisabled}>
-                    <optgroup label='Clear'>
-                        <option key={'__all__'} value={'__all__'}>All</option>
-                    </optgroup>
-                    <optgroup label='Hide'>{TypeOptions}</optgroup>
-                </ButtonSelect>
-                <ButtonSelect label='Color' onChange={this.color} disabled={this.state.isDisabled}>
-                    <optgroup label='Clear'>
-                        <option key={-1} value={-1}>Theme</option>
-                    </optgroup>
-                    <optgroup label='Color'>{ColorOptions()}</optgroup>
-                </ButtonSelect>
-            </div>
-        </div>
-    }
-}
-
-class EverythingStructureRepresentationControls extends BaseStructureRepresentationControls {
-    label = 'Everything'
-    lociGetter = (structure: Structure) => {
-        return StructureElement.Loci.all(structure)
-    }
-}
-
-class SelectionStructureRepresentationControls extends BaseStructureRepresentationControls {
-    label = 'Selection'
-    lociGetter = (structure: Structure) => {
-        const loci = this.plugin.managers.structure.selection.getLoci(structure)
-        return isEmptyLoci(loci) ? StructureElement.Loci.none(structure) : loci
-    }
-}
-
-interface StructureRepresentationControlsState extends CollapsableState {
-    isDisabled: boolean
-}
-
-export class StructureRepresentationControls extends CollapsableControls<CollapsableProps, StructureRepresentationControlsState> {
-    componentDidMount() {
-        this.subscribe(this.plugin.state.dataState.events.isUpdating, v => this.setState({ isDisabled: v }))
-    }
-
-    onChange = async (p: { param: PD.Base<any>, name: string, value: any }) => {
-        if (p.name === 'options') {
-            await this.plugin.helpers.structureRepresentation.setIgnoreHydrogens(!p.value.showHydrogens)
-            await this.plugin.helpers.structureRepresentation.setQuality(p.value.visualQuality)
-            await this.plugin.helpers.structureRepresentation.setInteractionsProps(p.value.interactions)
-            this.forceUpdate()
-        }
-    }
-
-    get params () {
-        const { options } = this.values
-        return {
-            options: PD.Group({
-                showHydrogens: PD.Boolean(options.showHydrogens, { description: 'Toggle display of hydrogen atoms in representations' }),
-                visualQuality: PD.Select<VisualQuality>(options.visualQuality, VisualQualityOptions, { description: 'Control the visual/rendering quality of representations' }),
-                interactions: PD.Group(InteractionsProvider.defaultParams, { label: 'Non-covalent Interactions' }),
-            }, { isExpanded: true })
-        }
-    }
-
-    get values () {
-        const { structureRepresentation: rep } = this.plugin.helpers
-        return {
-            options: {
-                showHydrogens: !rep.ignoreHydrogens,
-                visualQuality: rep.quality,
-                interactions: rep.interactionProps,
-            }
-        }
-    }
-
-    defaultState() {
-        return {
-            isCollapsed: false,
-            header: 'Representation',
-
-            isDisabled: false
-        }
-    }
-
-    renderControls() {
-        return <div>
-            <EverythingStructureRepresentationControls />
-            <SelectionStructureRepresentationControls />
-
-            <ParameterControls params={this.params} values={this.values} onChange={this.onChange} isDisabled={this.state.isDisabled} />
-        </div>
-    }
-}

+ 0 - 4
src/mol-plugin/context.ts

@@ -36,8 +36,6 @@ import { ModifiersKeys } from '../mol-util/input/input-observer';
 import { isProductionMode, isDebugMode } from '../mol-util/debug';
 import { Model, Structure } from '../mol-model/structure';
 import { InteractivityManager } from '../mol-plugin-state/manager/interactivity';
-import { StructureRepresentationHelper } from './util/structure-representation-helper';
-import { StructureOverpaintHelper } from './util/structure-overpaint-helper';
 import { PluginToastManager } from './util/toast';
 import { StructureMeasurementManager } from '../mol-plugin-state/manager/structure/measurement';
 import { ViewportScreenshotHelper } from './util/viewport-screenshot';
@@ -144,8 +142,6 @@ export class PluginContext {
     readonly customParamEditors = new Map<string, StateTransformParameters.Class>();
 
     readonly helpers = {
-        structureRepresentation: new StructureRepresentationHelper(this),
-        structureOverpaint: new StructureOverpaintHelper(this),
         substructureParent: new SubstructureParentHelper(this),
         viewportScreenshot: void 0 as ViewportScreenshotHelper | undefined
     } as const;

+ 0 - 80
src/mol-plugin/util/structure-overpaint-helper.ts

@@ -1,80 +0,0 @@
-/**
- * Copyright (c) 2019-2020 mol* contributors, licensed under MIT, See LICENSE file for more info.
- *
- * @author Alexander Rose <alexander.rose@weirdbyte.de>
- */
-
-import { PluginStateObject } from '../../mol-plugin-state/objects';
-import { StateTransforms } from '../../mol-plugin-state/transforms';
-import { StateSelection, StateObjectCell, StateTransform, StateBuilder } from '../../mol-state';
-import { Structure, StructureElement, StructureSelection, QueryContext } from '../../mol-model/structure';
-import { PluginContext } from '../context';
-import { Color } from '../../mol-util/color';
-import { Overpaint } from '../../mol-theme/overpaint';
-import Expression from '../../mol-script/language/expression';
-import { compile } from '../../mol-script/runtime/query/compiler';
-
-type OverpaintEachReprCallback = (update: StateBuilder.Root, repr: StateObjectCell<PluginStateObject.Molecule.Structure.Representation3D, StateTransform<typeof StateTransforms.Representation.StructureRepresentation3D>>, overpaint?: StateObjectCell<any, StateTransform<typeof StateTransforms.Representation.OverpaintStructureRepresentation3DFromBundle>>) => void
-const OverpaintManagerTag = 'overpaint-controls'
-
-export class StructureOverpaintHelper {
-    private async eachRepr(callback: OverpaintEachReprCallback) {
-        const state = this.plugin.state.dataState;
-        const reprs = state.select(StateSelection.Generators.ofType(PluginStateObject.Molecule.Structure.Representation3D));
-
-        const update = state.build();
-        for (const r of reprs) {
-            const overpaint = state.select(StateSelection.Generators.ofTransformer(StateTransforms.Representation.OverpaintStructureRepresentation3DFromBundle, r.transform.ref).withTag(OverpaintManagerTag))
-            callback(update, r, overpaint[0])
-        }
-
-        await this.plugin.runTask(state.updateTree(update, { doNotUpdateCurrent: true }));
-    }
-
-    async set(color: Color | -1, lociGetter: (structure: Structure) => StructureElement.Loci, types?: string[], alpha = 1) {
-        await this.eachRepr((update, repr, overpaintCell) => {
-            if (types && !types.includes(repr.params!.values.type.name)) return
-
-            const structure = repr.obj!.data.source.data
-            // always use the root structure to get the loci so the overpaint
-            // stays applicable as long as the root structure does not change
-            const loci = lociGetter(structure.root)
-            if (StructureElement.Loci.isEmpty(loci)) return
-
-            const layer = {
-                bundle: StructureElement.Bundle.fromLoci(loci),
-                color: color === -1 ? Color(0) : color,
-                clear: color === -1
-            }
-
-            if (overpaintCell) {
-                const bundleLayers = [ ...overpaintCell.params!.values.layers, layer ]
-                const filtered = getFilteredBundle(bundleLayers, structure)
-                update.to(overpaintCell).update(Overpaint.toBundle(filtered, alpha))
-            } else {
-                const filtered = getFilteredBundle([ layer ], structure)
-                update.to(repr.transform.ref)
-                    .apply(StateTransforms.Representation.OverpaintStructureRepresentation3DFromBundle, Overpaint.toBundle(filtered, alpha), { tags: OverpaintManagerTag });
-            }
-        })
-    }
-
-    async setFromExpression(color: Color | -1, expression: Expression, types?: string[], alpha = 1) {
-        return this.set(color, (structure) => {
-            const compiled = compile<StructureSelection>(expression)
-            const result = compiled(new QueryContext(structure))
-            return StructureSelection.toLociWithSourceUnits(result)
-        }, types, alpha)
-    }
-
-    constructor(private plugin: PluginContext) {
-
-    }
-}
-
-/** filter overpaint layers for given structure */
-function getFilteredBundle(layers: Overpaint.BundleLayer[], structure: Structure) {
-    const overpaint = Overpaint.ofBundle(layers, 1, structure.root)
-    const merged = Overpaint.merge(overpaint)
-    return Overpaint.filter(merged, structure)
-}

+ 0 - 277
src/mol-plugin/util/structure-representation-helper.ts

@@ -1,277 +0,0 @@
-/**
- * Copyright (c) 2019-2020 mol* contributors, licensed under MIT, See LICENSE file for more info.
- *
- * @author Alexander Rose <alexander.rose@weirdbyte.de>
- */
-
-import { PluginStateObject as PSO } from '../../mol-plugin-state/objects';
-import { StateTransforms } from '../../mol-plugin-state/transforms';
-import { StateTransformer, StateSelection, StateObjectCell, StateTransform, StateBuilder } from '../../mol-state';
-import { StructureElement, Structure, StructureSelection, QueryContext } from '../../mol-model/structure';
-import { PluginContext } from '../context';
-import { ParamDefinition as PD } from '../../mol-util/param-definition';
-import { StructureRepresentation3DHelpers } from '../../mol-plugin-state/transforms/representation';
-import Expression from '../../mol-script/language/expression';
-import { compile } from '../../mol-script/runtime/query/compiler';
-import { VisualQuality } from '../../mol-geo/geometry/base';
-import { InteractionsProps } from '../../mol-model-props/computed/interactions/interactions';
-import { InteractionsProvider } from '../../mol-model-props/computed/interactions';
-
-type StructureTransform = StateObjectCell<PSO.Molecule.Structure, StateTransform<StateTransformer<any, PSO.Molecule.Structure, any>>>
-type RepresentationTransform = StateObjectCell<PSO.Molecule.Structure.Representation3D, StateTransform<StateTransformer<any, PSO.Molecule.Structure.Representation3D, any>>>
-const RepresentationManagerTag = 'representation-controls'
-
-export function getRepresentationManagerTag(type: string) {
-    return `${RepresentationManagerTag}-${type}`
-}
-
-function getCombinedLoci(mode: SelectionModifier, loci: StructureElement.Loci, currentLoci: StructureElement.Loci): StructureElement.Loci {
-    switch (mode) {
-        case 'add': return StructureElement.Loci.union(loci, currentLoci)
-        case 'remove': return StructureElement.Loci.subtract(currentLoci, loci)
-        case 'only': return loci
-    }
-}
-
-type SelectionModifier = 'add' | 'remove' | 'only'
-
-type ReprProps = {
-    repr?: {},
-    color?: string | [string, {}],
-    size?: string | [string, {}],
-}
-
-export class StructureRepresentationHelper {
-    getRepresentationStructure(rootRef: string, type: string) {
-        const state = this.plugin.state.dataState
-        const selections = state.select(StateSelection.Generators.ofType(PSO.Molecule.Structure, rootRef).withTag(getRepresentationManagerTag(type)));
-        return selections.length > 0 ? selections[0] : undefined
-    }
-
-    getRepresentation(rootRef: string, type: string) {
-        const reprStructure = this.getRepresentationStructure(rootRef, type)
-        if (!reprStructure) return
-        const state = this.plugin.state.dataState
-        const selections = state.select(StateSelection.Generators.ofType(PSO.Molecule.Structure.Representation3D, reprStructure.transform.ref))
-        return selections.length > 0 ? selections[0] : undefined
-    }
-
-    private getRepresentationParams(structure: Structure, type: string, repr: RepresentationTransform | undefined, props: ReprProps = {}) {
-        const reprProps = {
-            ...(repr?.params && repr.params.values.type.params),
-            ignoreHydrogens: this._ignoreHydrogens,
-            quality: this._quality,
-            ...props.repr
-        }
-        const { themeCtx } =  this.plugin.structureRepresentation
-
-        const p: StructureRepresentation3DHelpers.Props = {
-            repr: [
-                this.plugin.structureRepresentation.registry.get(type),
-                () => reprProps
-            ]
-        }
-        if (props.color) {
-            const colorType = props.color instanceof Array ? props.color[0] : props.color
-            const colorTheme = themeCtx.colorThemeRegistry.get(colorType)
-            const colorProps = {
-                ...(repr?.params && repr.params.values.colorTheme.name === colorType && repr.params.values.colorTheme.params),
-                ...(props.color instanceof Array ? props.color[1] : {})
-            }
-            p.color = [colorTheme, () => colorProps]
-        }
-        if (props.size) {
-            const sizeType = props.size instanceof Array ? props.size[0] : props.size
-            const sizeTheme = themeCtx.sizeThemeRegistry.get(sizeType)
-            const sizeProps = {
-                ...(repr?.params && repr.params.values.sizeTheme.name === sizeType && repr.params.values.sizeTheme.params),
-                ...(props.size instanceof Array ? props.size[1] : {})
-            }
-            p.size = [sizeTheme, () => sizeProps]
-        }
-        if (props.size) p.size = props.size
-
-        return StructureRepresentation3DHelpers.createParams(this.plugin, structure, p)
-    }
-
-    private async _set(modifier: SelectionModifier, type: string, loci: StructureElement.Loci, structure: StructureTransform, props: ReprProps = {}) {
-        const state = this.plugin.state.dataState
-        const update = state.build()
-        const s = structure.obj!.data
-
-        const repr = this.getRepresentation(structure.transform.ref, type)
-        const reprStructure = this.getRepresentationStructure(structure.transform.ref, type)
-        const reprParams = this.getRepresentationParams(s.root, type, repr, props)
-
-        if (reprStructure) {
-            const currentLoci = StructureElement.Bundle.toLoci(reprStructure.params!.values.bundle, s)
-            const combinedLoci = getCombinedLoci(modifier, loci, currentLoci)
-
-            update.to(reprStructure).update({
-                ...reprStructure.params!.values,
-                bundle: StructureElement.Bundle.fromLoci(combinedLoci)
-            })
-            if (repr) update.to(repr).update(reprParams)
-        } else {
-            const combinedLoci = getCombinedLoci(modifier, loci, StructureElement.Loci.none(s))
-
-            update.to(structure.transform.ref)
-                .apply(
-                    StateTransforms.Model.StructureSelectionFromBundle,
-                    { bundle: StructureElement.Bundle.fromLoci(combinedLoci), label: type },
-                    { tags: [ RepresentationManagerTag, getRepresentationManagerTag(type) ] }
-                )
-                .apply(StateTransforms.Representation.StructureRepresentation3D, reprParams)
-        }
-
-        await this.plugin.runTask(state.updateTree(update, { doNotUpdateCurrent: true }))
-    }
-
-    async set(modifier: SelectionModifier, type: string, lociGetter: (structure: Structure) => StructureElement.Loci, props: ReprProps = {}) {
-        const state = this.plugin.state.dataState;
-        const structures = state.select(StateSelection.Generators.rootsOfType(PSO.Molecule.Structure))
-
-        for (const structure of structures) {
-            const s = structure.obj!.data
-            const loci = lociGetter(s)
-            await this._set(modifier, type, loci, structure, props)
-        }
-    }
-
-    async setFromExpression(modifier: SelectionModifier, type: string, expression: Expression, props: ReprProps = {}) {
-        return this.set(modifier, type, (structure) => {
-            const compiled = compile<StructureSelection>(expression)
-            const result = compiled(new QueryContext(structure))
-            return StructureSelection.toLociWithSourceUnits(result)
-        }, props)
-    }
-
-    async eachStructure(callback: (structure: StructureTransform, type: string, update: StateBuilder.Root) => void) {
-        const { registry } = this.plugin.structureRepresentation
-        const state = this.plugin.state.dataState;
-        const update = state.build()
-        const structures = state.select(StateSelection.Generators.rootsOfType(PSO.Molecule.Structure))
-
-        for (const structure of structures) {
-            for (let i = 0, il = registry.types.length; i < il; ++i) {
-                const type = registry.types[i][0]
-                const reprStructure = this.getRepresentationStructure(structure.transform.ref, type)
-                if (reprStructure) callback(reprStructure, type, update)
-            }
-        }
-        await this.plugin.runTask(state.updateTree(update, { doNotUpdateCurrent: true }))
-    }
-
-    async clear() {
-        const bundle = StructureElement.Bundle.Empty
-        await this.eachStructure((structure, type, update) => {
-            update.to(structure).update({ ...structure.params!.values, bundle })
-        })
-    }
-
-    async clearExcept(exceptTypes: string[]) {
-        const bundle = StructureElement.Bundle.Empty
-        await this.eachStructure((structure, type, update) => {
-            if (!exceptTypes.includes(type)) {
-                update.to(structure).update({ ...structure.params!.values, bundle })
-            }
-        })
-    }
-
-    async eachRepresentation(callback: (repr: RepresentationTransform, type: string, update: StateBuilder.Root) => void) {
-        const { registry } = this.plugin.structureRepresentation
-        const state = this.plugin.state.dataState;
-        const update = state.build()
-        const structures = state.select(StateSelection.Generators.rootsOfType(PSO.Molecule.Structure))
-        for (const structure of structures) {
-            for (let i = 0, il = registry.types.length; i < il; ++i) {
-                const type = registry.types[i][0]
-                const repr = this.getRepresentation(structure.transform.ref, type)
-                if (repr) callback(repr, type, update)
-            }
-        }
-        await this.plugin.runTask(state.updateTree(update, { doNotUpdateCurrent: true }))
-    }
-
-    setRepresentationParams(repr: RepresentationTransform, type: string, update: StateBuilder.Root, props: ReprProps) {
-        const state = this.plugin.state.dataState;
-        const structures = state.select(StateSelection.Generators.rootsOfType(PSO.Molecule.Structure))
-
-        for (const structure of structures) {
-            const s = structure.obj!.data
-            const reprParams = this.getRepresentationParams(s.root, type, repr, props)
-            update.to(repr).update(reprParams)
-        }
-    }
-
-    async updateRepresentation(repr: RepresentationTransform, type: string, props: ReprProps) {
-        const state = this.plugin.state.dataState;
-        const update = state.build()
-        this.setRepresentationParams(repr, type, update, props)
-        await this.plugin.runTask(state.updateTree(update, { doNotUpdateCurrent: true }))
-    }
-
-    private _ignoreHydrogens = false
-    get ignoreHydrogens () { return this._ignoreHydrogens }
-    async setIgnoreHydrogens(ignoreHydrogens: boolean) {
-        if (ignoreHydrogens === this._ignoreHydrogens) return
-        await this.eachRepresentation((repr, type, update) => {
-            if (repr.params && repr.params.values.type.params.ignoreHydrogens !== undefined) {
-                const { name, params } = repr.params.values.type
-                update.to(repr.transform.ref).update(
-                    StateTransforms.Representation.StructureRepresentation3D,
-                    props => ({ ...props, type: { name, params: { ...params, ignoreHydrogens }}})
-                )
-            }
-        })
-        this._ignoreHydrogens = ignoreHydrogens
-    }
-
-    private _quality = 'auto' as VisualQuality
-    get quality () { return this._quality }
-    async setQuality(quality: VisualQuality) {
-        if (quality === this._quality) return
-        await this.eachRepresentation((repr, type, update) => {
-            if (repr.params && repr.params.values.type.params.quality !== undefined) {
-                const { name, params } = repr.params.values.type
-                update.to(repr.transform.ref).update(
-                    StateTransforms.Representation.StructureRepresentation3D,
-                    props => ({ ...props, type: { name, params: { ...params, quality }}})
-                )
-            }
-        })
-        this._quality = quality
-    }
-
-    private _interactionProps = PD.getDefaultValues(InteractionsProvider.defaultParams)
-    get interactionProps () { return this._interactionProps }
-    async setInteractionsProps(interactionProps: InteractionsProps) {
-        const state = this.plugin.state.dataState;
-        const update = state.build()
-        const structures = state.select(StateSelection.Generators.rootsOfType(PSO.Molecule.Structure))
-        for (const structure of structures) {
-            const reprStructure = this.getRepresentationStructure(structure.transform.ref, 'interactions') // TODO use enum for type name
-            if (reprStructure) {
-                const customStructureProps = state.select(StateSelection.Generators.ofTransformer(StateTransforms.Model.CustomStructureProperties, reprStructure.transform.ref))[0]
-
-                const params = PD.getDefaultValues(this.plugin.customStructureProperties.getParams(structure.obj?.data))
-                params.autoAttach.push(InteractionsProvider.descriptor.name)
-                params.properties[InteractionsProvider.descriptor.name] = interactionProps
-
-                if (customStructureProps) {
-                    update.to(customStructureProps).update(params)
-                } else {
-                    update.to(reprStructure)
-                        .insert(StateTransforms.Model.CustomStructureProperties, params)
-                }
-            }
-        }
-        await this.plugin.runTask(state.updateTree(update, { doNotUpdateCurrent: true }))
-
-        this._interactionProps = interactionProps
-    }
-
-    constructor(private plugin: PluginContext) {
-
-    }
-}