blessed icon indicating copy to clipboard operation
blessed copied to clipboard

Password input

Open RossComputerGuy opened this issue 7 years ago • 3 comments

I'm trying to make a login screen and I'm wondering how I'd have the password characters show up as *.

RossComputerGuy avatar Nov 15 '18 19:11 RossComputerGuy

It sounds like you're asking for the censor property in the options for textbox, check out http://blessedjs.org/widgets/forms/textbox.html

fancyplants avatar Nov 27 '18 11:11 fancyplants

So I just need to set censor to true?

RossComputerGuy avatar Nov 27 '18 14:11 RossComputerGuy

I believe so, yes.

Here's an example from one of my input boxes:

const input = blessed.textbox({
    parent: form,
    top: 4,
    left: 5,
    height: 3,
    censor: true,
    mouse: true,
    inputOnFocus: true,
    border: {
      type: 'line',
    },
  })

fancyplants avatar Nov 27 '18 20:11 fancyplants