Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hide input component #1417

Merged
merged 4 commits into from
Aug 20, 2021
Merged

Hide input component #1417

merged 4 commits into from
Aug 20, 2021

Conversation

ilija-lazoroski
Copy link
Contributor

@ilija-lazoroski ilija-lazoroski commented Aug 18, 2021

What does this PR do?

Fixes #1183

Add any further explanations here.

PR Checklist

  • Have you added an explanation of what your changes do and why you'd like to include them?
  • Is the TravisCI build passing?
  • Was the CHANGELOG.md updated to reflect the changes?
  • Was the documentation framework updated to reflect the changes?

Testing Checklist

  • Added relevant unit tests?
  • Have you successfully tested your changes locally? Elaborate:

    Tested by {Running the Monkey locally with relevant config/running Island/...}

  • If applicable, add screenshots or log transcripts of the feature working

Explain Changes

image
image
image

@codecov
Copy link

codecov bot commented Aug 18, 2021

Codecov Report

Merging #1417 (0fc9631) into develop (dd390ff) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff            @@
##           develop    #1417   +/-   ##
========================================
  Coverage    40.07%   40.07%           
========================================
  Files          465      465           
  Lines        13845    13845           
========================================
  Hits          5548     5548           
  Misses        8297     8297           
Impacted Files Coverage Δ
...y/monkey_island/cc/services/config_schema/basic.py 100.00% <ø> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update dd390ff...0fc9631. Read the comment docs.

Copy link
Contributor

@shreyamalviya shreyamalviya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is the spacing before the "should be string" more in configuration options with the hidden eye component? Let's make it uniform.

image

this.setState({hidden: ! this.state.hidden});
}

onChange(e) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Again, my javascript is rusty. Does this also need a call to bind() or equivalent?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

https://newbedev.com/why-and-when-do-we-need-to-bind-functions-and-eventhandlers-in-react
Apparently there is couple ways of binding, in which I have use the third one.

onChange={(event) => this.onChange(event)}

import {InputGroup, FormControl} from 'react-bootstrap';
import '../../styles/components/HideInput.scss'

class HideInput extends React.PureComponent {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe a name like SensitiveTextInput would be better? The input isn't always hidden.

Copy link
Collaborator

@mssalvatore mssalvatore left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The develop branch has been backmerged into this branch. We need to undo/fix that before we merge this branch back into develop.

@ilija-lazoroski ilija-lazoroski force-pushed the 1183/hide-input-component branch from 38d3296 to 2400979 Compare August 20, 2021 11:43
@ilija-lazoroski ilija-lazoroski merged commit 9f194f3 into develop Aug 20, 2021
@mssalvatore mssalvatore deleted the 1183/hide-input-component branch August 20, 2021 13:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Hide passwords and other credentials in UI
3 participants