Code Duplication    Length = 8-8 lines in 3 locations

src/CliMenu.php 3 locations

@@ 438-445 (lines=8) @@
435
        return new Confirm($this, $style, $this->terminal, $text);
436
    }
437
438
    public function askNumber() : Number
439
    {
440
        $style = (new MenuStyle($this->terminal))
441
            ->setBg('yellow')
442
            ->setFg('red');
443
444
        return new Number(new InputIO($this, $style, $this->terminal));
445
    }
446
447
    public function askText() : Text
448
    {
@@ 447-454 (lines=8) @@
444
        return new Number(new InputIO($this, $style, $this->terminal));
445
    }
446
447
    public function askText() : Text
448
    {
449
        $style = (new MenuStyle($this->terminal))
450
            ->setBg('yellow')
451
            ->setFg('red');
452
453
        return new Text(new InputIO($this, $style, $this->terminal));
454
    }
455
456
    public function askPassword() : Password
457
    {
@@ 456-463 (lines=8) @@
453
        return new Text(new InputIO($this, $style, $this->terminal));
454
    }
455
456
    public function askPassword() : Password
457
    {
458
        $style = (new MenuStyle($this->terminal))
459
            ->setBg('yellow')
460
            ->setFg('red');
461
462
        return new Password(new InputIO($this, $style, $this->terminal));
463
    }
464
465
    private function guardSingleLine($text)
466
    {