constructor(
        x,
        y,
        scope = globalScope,
        dir = "RIGHT",
        bitWidth = 2,
        selectorBitWidth = 1
    ) {
        super(x, y, scope, dir, bitWidth);
        /* this is done in this.baseSetup() now
        this.scope['BitSelector'].push(this);
        */
        this.setDimensions(20, 20);
        this.selectorBitWidth =
            selectorBitWidth || parseInt(prompt("Enter Selector bitWidth"), 10);
        this.rectangleObject = false;
        this.inp1 = new Node(-20, 0, 0, this, this.bitWidth, "Input");
        this.output1 = new Node(20, 0, 1, this, 1, "Output");
        this.bitSelectorInp = new Node(
            0,
            20,
            0,
            this,
            this.selectorBitWidth,
            "Bit Selector"
        );
    }
@class
BitSelector
@extends CircuitElement
@param {number} x - x coordinate of element.
@param {number} y - y coordinate of element.
@param {Scope=} scope - Cirucit on which element is drawn
@param {string=} dir - direction of element
@param {number=} bitWidth - bit width per node.
@param {number=} selectorBitWidth - 1 by default
@category modules