All files / src/lib/modules fragments.ts

100% Statements 8/8
100% Branches 0/0
100% Functions 4/4
100% Lines 8/8
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 232x 2x   2x               2x   1x 1x 1x 1x            
import {Module} from "../module";
import {Util} from "../util";
import {PuzzleJs} from "../puzzle";
import {LOG_COLORS} from "../enums";
 
export interface IFragmentInfo {
    [fragmentName: string]: {
        [name: string]: any
    }
}
 
export class Fragments extends Module {
    set(fragmentInfo: IFragmentInfo) {
        Util.wrapGroup('PuzzleJs', 'Debug Mode - Fragments', () => {
            Object.keys(fragmentInfo).forEach(fragmentName => {
                Util.wrapGroup('PuzzleJs', fragmentName, () => {
                    Util.log(fragmentInfo[fragmentName]);
                }, LOG_COLORS.BLUE);
            });
        });
    }
}