Skip to content

Commit

Permalink
feat: improve secrets management styling.
Browse files Browse the repository at this point in the history
  • Loading branch information
benoitdevos committed May 16, 2024
1 parent d4ce955 commit adcf04c
Show file tree
Hide file tree
Showing 9 changed files with 24 additions and 10 deletions.
4 changes: 4 additions & 0 deletions public/assets/key.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/components/toggle/Eye.css
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
background-image: url("../../img/eye.svg");
}
.Eye:not(.checked):after {
background-image: url("../../img/eye-closed.svg");
background-image: url("../../img/eye-slash.svg");
}

.Eye:after {
Expand Down
3 changes: 0 additions & 3 deletions src/img/eye-closed.svg

This file was deleted.

5 changes: 5 additions & 0 deletions src/img/eye-slash.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 3 additions & 3 deletions src/img/eye.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions src/loc/secrets/SecretsButton.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.SecretsButton img {
margin-right: 10px;
}
6 changes: 5 additions & 1 deletion src/loc/secrets/SecretsButton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ import Button from "../../common/Button";
import { useNavigate } from "react-router-dom";
import { secretsPath } from "../../wallet-user/UserPaths";
import { useLocContext } from "../LocContext";
import Icon from "../../common/Icon";
import "./SecretsButton.css";

export default function SecretsButton() {
const { loc } = useLocContext();
Expand All @@ -11,7 +13,9 @@ export default function SecretsButton() {
}

return (
<Button onClick={ () => { navigate(secretsPath(loc.id))} }>
<Button className="SecretsButton"
onClick={ () => navigate(secretsPath(loc.id)) }>
<Icon icon={ { id: "key" } } />
Recoverable secrets
</Button>
)
Expand Down
3 changes: 2 additions & 1 deletion src/loc/secrets/SecretsPane.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,8 @@ function UserSecretsPane() {
contributionMode="Requester"
>
<Frame
title="Secrets"
title="Recoverable secrets"
titleIcon={ { icon: { id: "key" } } }
>
<SecretsTable
secrets={ locState?.data().secrets || [] }
Expand Down
2 changes: 1 addition & 1 deletion src/loc/secrets/ViewableSecret.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export default function ViewableSecret(props: Props) {
return (
<div className="ViewableSecret">
{ !hidden && <span>{ props.value }</span> }
{ hidden && <span>******</span> }
{ hidden && <span>••••••</span> }
<Checkbox checked={ hidden } setChecked={ setHidden } skin="Eye" />
</div>
)
Expand Down

0 comments on commit adcf04c

Please sign in to comment.