* Creates a new Panel consisting of a sign and an exit tab. * @param {string} color - Background color of the sign and exit tab. * @param {Sign} sign - Sign to make up the panel. * @param {String} corner - Choice of Sharp or Rounded Corners on the Panel * @param {ExitTab} [exitTab=null] - Op
(sign, color, exitTabs = [], corner)
| 7 | * @param {ExitTab} [exitTab=null] - Optional exit tab to include in the panel. |
| 8 | */ |
| 9 | constructor(sign, color, exitTabs = [], corner) { |
| 10 | if (Object.keys(lib.colors).includes(color)) { |
| 11 | this.color = color; |
| 12 | } else { |
| 13 | this.color = "Green"; |
| 14 | } |
| 15 | if (Object.keys(this.cornerType).includes(corner)) { |
| 16 | this.corner = corner; |
| 17 | } else { |
| 18 | this.corner = this.cornerType[0]; |
| 19 | } |
| 20 | |
| 21 | this.sign = sign; |
| 22 | this.exitTabs = exitTabs; |
| 23 | |
| 24 | } |
| 25 | |
| 26 | newExitTab() { |
| 27 | const exitTab = new ExitTab(); |
nothing calls this directly
no outgoing calls
no test coverage detected