All files / roosterjs-content-model-plugins/lib/tableEdit/editors/features TableEditFeature.ts

100% Statements 6/6
71.43% Branches 10/14
100% Functions 1/1
100% Lines 6/6

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23                            1x 18x 18x 18x 18x 18x      
import type { Disposable } from '../../../pluginUtils/Disposable';
 
/**
 * @internal
 */
export interface TableEditFeature {
    node: Node;
    div: HTMLDivElement | null;
    featureHandler: Disposable | null;
}
 
/**
 * @internal
 */
export function disposeTableEditFeature(feature: TableEditFeature | null) {
    Eif (feature) {
        feature.featureHandler?.dispose();
        feature.featureHandler = null;
        feature.div?.parentNode?.removeChild(feature.div);
        feature.div = null;
    }
}