question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

cc-input-text: multi + secret

See original GitHub issue

Context

We didn’t implement secret in multiline mode because it’s not simple to create the equivalent of <input type=password> with a textarea.

What we tried

We naively tried this when multi + secret:

  • if secret is hidden => display a <input type=password>
  • if secret is revealed => display a <textarea> with the multiline value

Problems

This behaviour is almost what we want, the weird case comes from the fact that you can still edit the <input type=password> and once you edit the value while hidden you lost line breaks when you reveal the secret.

If we decide to do multi + secret while hidden with <input type=password readonly> the result will work with the copy to clipboard button but not with a text selection and a regular copy paste. We would lose line breaks.

Maybe an idea

If we use a filter:blur we could achieve something but I’m not convinced yet and I want feedbacks.

Capture d’écran_2020-01-07_15-17-04

Issue Analytics

  • State:open
  • Created 4 years ago
  • Comments:11 (9 by maintainers)

github_iconTop GitHub Comments

2reactions
hsablonnierecommented, Dec 22, 2020

The custom font seems like a good idea, here’s a proof of concept:

https://user-images.githubusercontent.com/236342/102905923-286c1880-4474-11eb-9840-8c471dd397c7.mp4

TODO:

  • Generate (look for) a font that has only the .notdef character
  • Ask around if it’s a good idea
  • Use a dot instead of the crossed square
Read more comments on GitHub >

github_iconTop Results From Across the Web

collect multi inputs in one hidden text input - Stack Overflow
This should work fine: $(function() { var macSelector = "input[name^='MacAddressPart']"; $(macSelector).bind('keyup', function() { var macs ...
Read more >
<input type="hidden"> - HTML: HyperText Markup Language
<input> elements of type hidden let web developers include data that cannot be seen or modified by users when a form is submitted....
Read more >
Change secret text field to textarea to support multiline text
Currently the interface for StringBinding/Secret Text is an HTML input field, so when a multiple line secret is pasted in, the newlines ...
Read more >
Text field - Shopify Polaris
A text field is an input field that merchants can type into. It has a range of options and supports several text formats...
Read more >
Labeling Controls | Web Accessibility Initiative (WAI) - W3C
The label can be hidden visually, though it still needs to be provided within ... The purpose of the text input field is...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found