-
Notifications
You must be signed in to change notification settings - Fork 2.9k
Login: Adds show/hide password toggle #20611
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
Merged
Merged
Changes from 12 commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
2eb1994
Implimented an inline toggle button to show/hide your password, also …
MrHutmat 1c6d603
Cleaned the css
MrHutmat e294b05
Removed old logic that added a 100ms timeout that would sometimes be …
MrHutmat 9b1e765
Re adding the hide for -ms-reveal to support Microsoft Edge browsers
MrHutmat a31f36e
Removed a console.log
MrHutmat 187dbde
Alligned the button behavior so it fits better with what we have in t…
MrHutmat 0d718a1
Update src/Umbraco.Web.UI.Login/src/auth.element.ts
iOvergaard f7b4f86
Update src/Umbraco.Web.UI.Login/src/auth.element.ts
iOvergaard c7d9362
Apply suggestion from @Copilot
iOvergaard c3697bc
Apply suggestion from @Copilot
iOvergaard 8605fa2
Apply suggestion from @iOvergaard
iOvergaard f6a9e54
Apply suggestion from @iOvergaard
iOvergaard 8b544f8
Adding the requested changes via my own fork (#20664)
MrHutmat File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,44 +1,84 @@ | ||
| #umb-login-form input { | ||
| width: 100%; | ||
| height: var(--input-height); | ||
| box-sizing: border-box; | ||
| display: block; | ||
| border: 1px solid var(--uui-color-border); | ||
| border-radius: var(--uui-border-radius); | ||
| background-color: var(--uui-color-surface); | ||
| padding: var(--uui-size-1, 3px) var(--uui-size-space-4, 9px); | ||
| #umb-login-form #username-input { | ||
| width: 100%; | ||
| height: var(--input-height); | ||
| box-sizing: border-box; | ||
| display: block; | ||
| border: 1px solid var(--uui-color-border); | ||
| border-radius: var(--uui-border-radius); | ||
| background-color: var(--uui-color-surface); | ||
| padding: var(--uui-size-1, 3px) var(--uui-size-space-4, 9px); | ||
| } | ||
|
|
||
| #umb-login-form uui-form-layout-item { | ||
| margin-top: var(--uui-size-space-4); | ||
| margin-bottom: var(--uui-size-space-4); | ||
| margin-top: var(--uui-size-space-4); | ||
| margin-bottom: var(--uui-size-space-4); | ||
| } | ||
|
|
||
| #umb-login-form input:focus-within { | ||
| border-color: var(--uui-input-border-color-focus, var(--uui-color-border-emphasis, #a1a1a1)); | ||
| outline: calc(2px * var(--uui-show-focus-outline, 1)) solid var(--uui-color-focus); | ||
| #umb-login-form #username-input:focus-within { | ||
| border-color: var(--uui-input-border-color-focus, var(--uui-color-border-emphasis, #a1a1a1)); | ||
| outline: calc(2px * var(--uui-show-focus-outline, 1)) solid var(--uui-color-focus); | ||
| } | ||
|
|
||
| #umb-login-form input:hover:not(:focus-within) { | ||
| border-color: var(--uui-input-border-color-hover, var(--uui-color-border-standalone, #c2c2c2)); | ||
| #umb-login-form #username-input:hover:not(:focus-within) { | ||
| border-color: var(--uui-input-border-color-hover, var(--uui-color-border-standalone, #c2c2c2)); | ||
| } | ||
|
|
||
| #umb-login-form input::-ms-reveal { | ||
| display: none; | ||
| #umb-login-form #password-input-span button { | ||
| color: var(--uui-color-default-standalone); | ||
| display: inline-flex; | ||
| justify-content: center; | ||
| align-items: center; | ||
| vertical-align: middle; | ||
| min-width: 24px; | ||
| min-height: 24px; | ||
| border-color: transparent; | ||
| background-color: transparent; | ||
| padding: 0; | ||
| transition-property: color; | ||
| transition-duration: 0.1s; | ||
| transition-timing-function: linear; | ||
| } | ||
|
|
||
| #umb-login-form #password-input-span button:hover { | ||
| color: var(--uui-color-default-emphasis); | ||
| cursor: pointer; | ||
| } | ||
|
|
||
| #umb-login-form #password-input-span { | ||
| display: inline-flex; | ||
| width: 100%; | ||
| align-items: center; | ||
| flex-wrap: nowrap; | ||
| position: relative; | ||
| vertical-align: middle; | ||
| column-gap: 0; | ||
| height: var(--input-height); | ||
| box-sizing: border-box; | ||
| border: 1px solid var(--uui-color-border); | ||
| border-radius: var(--uui-border-radius); | ||
| background-color: var(--uui-color-surface); | ||
| padding: var(--uui-size-1, 3px) var(--uui-size-space-4, 9px); | ||
| } | ||
|
|
||
| #umb-login-form input span { | ||
| position: absolute; | ||
| right: 1px; | ||
| top: 50%; | ||
| transform: translateY(-50%); | ||
| z-index: 100; | ||
| #umb-login-form #password-input-span input { | ||
| flex-grow: 1; | ||
| align-self: stretch; | ||
| min-width: 0; | ||
| display: block; | ||
| border-style: none; | ||
| padding: 0; | ||
| outline-style: none; | ||
| } | ||
|
|
||
| #umb-login-form input span svg { | ||
| background-color: white; | ||
| display: block; | ||
| padding: .2em; | ||
| width: 1.3em; | ||
| height: 1.3em; | ||
| #umb-login-form #password-input-span:focus-within { | ||
| border-color: var(--uui-input-border-color-focus, var(--uui-color-border-emphasis, #a1a1a1)); | ||
| outline: calc(2px * var(--uui-show-focus-outline, 1)) solid var(--uui-color-focus); | ||
| } | ||
|
|
||
| #umb-login-form #password-input-span:hover:not(:focus-within) { | ||
| border-color: var(--uui-input-border-color-hover, var(--uui-color-border-standalone, #c2c2c2)); | ||
| } | ||
|
|
||
| #umb-login-form input::-ms-reveal { | ||
| display: none; | ||
| } | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.