Password peek 🫣

This commit is contained in:
Karthik Kasturi 2025-09-11 21:34:12 +00:00
parent 2b8b5d71d2
commit f9c958da90
42 changed files with 203 additions and 9 deletions

View file

@ -105,3 +105,55 @@
background-color: #fd8;
transition: background-color 0.2s ease-in;
}
::-ms-reveal {
display: none;
}
.password-peek-container {
position: relative;
}
button.toggle-password {
position: absolute;
top: 3px;
right: 4px;
z-index: 9;
width: 2rem;
height: 2rem;
background: 0;
border: 0;
}
button.toggle-password:active,
button.toggle-password:focus,
button.toggle-password:hover {
cursor: pointer;
}
button.toggle-password:focus {
outline: none !important;
}
.input-password {
padding-right: calc(1.5em + 0.75rem);
background-repeat: no-repeat;
background-position: right calc(0.375em + 0.1875rem) center;
background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}
.input-password[type=text] {
background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 16 16' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M13.359 11.238C15.06 9.72 16 8 16 8s-3-5.5-8-5.5a7.028 7.028 0 0 0-2.79.588l.77.771A5.944 5.944 0 0 1 8 3.5c2.12 0 3.879 1.168 5.168 2.457A13.134 13.134 0 0 1 14.828 8c-.058.087-.122.183-.195.288-.335.48-.83 1.12-1.465 1.755-.165.165-.337.328-.517.486l.708.709z'/%3E%3Cpath d='M11.297 9.176a3.5 3.5 0 0 0-4.474-4.474l.823.823a2.5 2.5 0 0 1 2.829 2.829l.822.822zm-2.943 1.299l.822.822a3.5 3.5 0 0 1-4.474-4.474l.823.823a2.5 2.5 0 0 0 2.829 2.829z'/%3E%3Cpath d='M3.35 5.47c-.18.16-.353.322-.518.487A13.134 13.134 0 0 0 1.172 8l.195.288c.335.48.83 1.12 1.465 1.755C4.121 11.332 5.881 12.5 8 12.5c.716 0 1.39-.133 2.02-.36l.77.772A7.029 7.029 0 0 1 8 13.5C3 13.5 0 8 0 8s.939-1.721 2.641-3.238l.708.709z'/%3E%3Cpath fill-rule='evenodd' d='M13.646 14.354l-12-12 .708-.708 12 12-.708.708z'/%3E%3C/svg%3E") !important;
}
.input-password[type=password] {
background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 16 16' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill-rule='evenodd' d='M16 8s-3-5.5-8-5.5S0 8 0 8s3 5.5 8 5.5S16 8 16 8zM1.173 8a13.134 13.134 0 0 0 1.66 2.043C4.12 11.332 5.88 12.5 8 12.5c2.12 0 3.879-1.168 5.168-2.457A13.134 13.134 0 0 0 14.828 8a13.133 13.133 0 0 0-1.66-2.043C11.879 4.668 10.119 3.5 8 3.5c-2.12 0-3.879 1.168-5.168 2.457A13.133 13.133 0 0 0 1.172 8z'/%3E%3Cpath fill-rule='evenodd' d='M8 5.5a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5zM4.5 8a3.5 3.5 0 1 1 7 0 3.5 3.5 0 0 1-7 0z'/%3E%3C/svg%3E") !important;
}
[data-bs-theme=dark] .input-password[type=text] {
background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 16 16' fill='%23adb5bd' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M13.359 11.238C15.06 9.72 16 8 16 8s-3-5.5-8-5.5a7.028 7.028 0 0 0-2.79.588l.77.771A5.944 5.944 0 0 1 8 3.5c2.12 0 3.879 1.168 5.168 2.457A13.134 13.134 0 0 1 14.828 8c-.058.087-.122.183-.195.288-.335.48-.83 1.12-1.465 1.755-.165.165-.337.328-.517.486l.708.709z'/%3E%3Cpath d='M11.297 9.176a3.5 3.5 0 0 0-4.474-4.474l.823.823a2.5 2.5 0 0 1 2.829 2.829l.822.822zm-2.943 1.299l.822.822a3.5 3.5 0 0 1-4.474-4.474l.823.823a2.5 2.5 0 0 0 2.829 2.829z'/%3E%3Cpath d='M3.35 5.47c-.18.16-.353.322-.518.487A13.134 13.134 0 0 0 1.172 8l.195.288c.335.48.83 1.12 1.465 1.755C4.121 11.332 5.881 12.5 8 12.5c.716 0 1.39-.133 2.02-.36l.77.772A7.029 7.029 0 0 1 8 13.5C3 13.5 0 8 0 8s.939-1.721 2.641-3.238l.708.709z'/%3E%3Cpath fill-rule='evenodd' d='M13.646 14.354l-12-12 .708-.708 12 12-.708.708z'/%3E%3C/svg%3E") !important;
}
[data-bs-theme=dark] .input-password[type=password] {
background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 16 16' fill='%23adb5bd' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill-rule='evenodd' d='M16 8s-3-5.5-8-5.5S0 8 0 8s3 5.5 8 5.5S16 8 16 8zM1.173 8a13.134 13.134 0 0 0 1.66 2.043C4.12 11.332 5.88 12.5 8 12.5c2.12 0 3.879-1.168 5.168-2.457A13.134 13.134 0 0 0 14.828 8a13.133 13.133 0 0 0-1.66-2.043C11.879 4.668 10.119 3.5 8 3.5c-2.12 0-3.879 1.168-5.168 2.457A13.133 13.133 0 0 0 1.172 8z'/%3E%3Cpath fill-rule='evenodd' d='M8 5.5a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5zM4.5 8a3.5 3.5 0 1 1 7 0 3.5 3.5 0 0 1-7 0z'/%3E%3C/svg%3E") !important;
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "نُسخ الرابط إلى الحافظة",
"Document text": "لصق النص",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "مفتاح التبويب يعمل كشخصية (انقر <kbd>Ctrl</kbd>+<kbd>m</kbd> أو <kbd>Esc</kbd> للتبديل)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "السمة"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "U liame hè statu cupiatu in u premepapei",
"Document text": "Testu di u ducumentu",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "U tastu di tabulazione ghjova cumè un caratteru (Appughjate nantà <kbd>Ctrl</kbd>+<kbd>m</kbd> o <kbd>Scapp</kbd> per scambià)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Tema"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Odkaz zkopírován do schránky",
"Document text": "Text dokumentu",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulátor funguje jako znak (pro přepnutí stiskněte <kbd>Ctrl</kbd>+<kbd>m</kbd> nebo <kbd>Esc</kbd>)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Vzhled"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Verknüpfung wurde in die Zwischenablage kopiert.",
"Document text": "Text des Dokuments",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulatortaste als Zeichen interpretieren (Umschalten durch <kbd>Strg</kbd>+<kbd>m</kbd> oder <kbd>Esc</kbd>)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Design"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link kopeeriti lõikelauale",
"Document text": "Kleebi tekst",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Teema"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Linkki kopioitu leikepöydälle",
"Document text": "Liitä teksti",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulaattori toimii merkkinä (Paina <kbd>Ctrl</kbd>+<kbd>m</kbd> tai <kbd>Esc</kbd> vaihtaaksesi)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Teema"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Lien copié dans le presse-papier",
"Document text": "Texte du document",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "La touche de tabulation sert de caractère (Presser <kbd>Ctrl</kbd>+<kbd>m</kbd> ou <kbd>Esc</kbd> pour basculer)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Thème"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "הקישור הועתק ללוח",
"Document text": "הדבק טקסט",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "משטח ה-tab פועל כמקש תו (לחץ על <kbd>Ctrl</kbd>+<kbd>m</kbd> או <kbd>Esc</kbd> להחלפה)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "נושא"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Testo del messaggio",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link gekopieerd naar klembord",
"Document text": "Tekst plakken",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulatortoets dient als teken (gebruik <kbd>Ctrl</kbd>+<kbd>m</kbd> of <kbd>Esc</kbd> om te schakelen)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Thema"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link został skopiowany do schowka",
"Document text": "Tekst dokumentu",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Klawisz Tabulatora służy jako znak (przytrzymaj <kbd>Ctrl</kbd>+<kbd>m</kbd> lub <kbd>Esc</kbd> aby przełączać)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Motyw"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Ссылка скопирована в буфер обмена",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Тема"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Odkaz vložený do schránky",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "คัดลอกลิงก์ไปที่คลิปบอร์ดแล้ว",
"Document text": "ฝากข้อความ",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "ปุ่ม Tabulator ใช้เป็นอักขระ (กด <kbd>Ctrl</kbd>+<kbd>m</kbd> หรือ <kbd>Esc</kbd> เพื่อสลับ)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "ธีม"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "Link copied to clipboard",
"Document text": "Document text",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "Theme"
}

View file

@ -229,5 +229,7 @@
"Link copied to clipboard": "链接已复制到剪贴板",
"Document text": "粘贴文本",
"Tabulator key serves as character (Hit <kbd>Ctrl</kbd>+<kbd>m</kbd> or <kbd>Esc</kbd> to toggle)": "Tab 键可作为字符(按 <kbd>Ctrl</kbd>+<kbd>m</kbd> 或 <kbd>Esc</kbd> 切换开关)",
"Show password as plain text. Warning: this will display your password on the screen.": "Show password as plain text. Warning: this will display your password on the screen.",
"Hide password": "Hide password",
"Theme": "主题"
}

View file

@ -2132,7 +2132,7 @@ jQuery.PrivateBin = (function($) {
// if so, we send the link to the shortener
// we do not remove the button, in case shortener fails
sendToShortener();
}
}
}
/**
@ -5674,6 +5674,48 @@ jQuery.PrivateBin = (function($) {
return me;
})();
/**
*
* @name PasswordPeek
* @class
*/
const PasswordPeek = (function () {
const me = {};
/**
* Switch between visible and hidden password
*
* @name PasswordPeek.handleRevealButtonClick
* @private
* @function
*/
function handleRevealButtonClick() {
const passwordInput = $(this).siblings('.input-password');
const isHidden = passwordInput.attr('type') === 'password';
passwordInput.attr('type', isHidden ? 'text' : 'password');
const tooltip = I18n._(isHidden ? 'Hide password' : 'Show password as plain text. Warning: this will display your password on the screen.');
$(this).attr('title', tooltip);
$(this).attr('aria-label', tooltip);
}
/**
* Initialize
*
* @name PasswordPeek.init
* @function
*/
me.init = function() {
const revealButton = $('.toggle-password');
revealButton.click(handleRevealButtonClick);
};
return me;
})();
/**
* (controller) main PrivateBin logic
*
@ -5922,6 +5964,7 @@ jQuery.PrivateBin = (function($) {
TopNav.init();
UiHelper.init();
CopyToClipboard.init();
PasswordPeek.init();
// check for legacy browsers before going any further
if (!Legacy.Check.getInit()) {
@ -5981,6 +6024,7 @@ jQuery.PrivateBin = (function($) {
ServerInteraction: ServerInteraction,
PasteEncrypter: PasteEncrypter,
PasteDecrypter: PasteDecrypter,
PasswordPeek: PasswordPeek,
CopyToClipboard: CopyToClipboard,
Controller: Controller
};

View file

@ -121,7 +121,7 @@ class Configuration
'js/kjua-0.10.0.js' => 'sha512-BYj4xggowR7QD150VLSTRlzH62YPfhpIM+b/1EUEr7RQpdWAGKulxWnOvjFx1FUlba4m6ihpNYuQab51H6XlYg==',
'js/legacy.js' => 'sha512-08+subq1Lo+r+la5ENqeXiMgNJcVaaTtBIFGkrjziSpvtgCId3Jtin4/OkSdHYSoeztwwIab8uvCzPKHta6puQ==',
'js/prettify.js' => 'sha512-puO0Ogy++IoA2Pb9IjSxV1n4+kQkKXYAEUtVzfZpQepyDPyXk8hokiYDS7ybMogYlyyEIwMLpZqVhCkARQWLMg==',
'js/privatebin.js' => 'sha512-Cor4acli/veLhX81YVTGQNkQ+poXsz0gRQUmLeJ6WebIXUlUi7ZQZ6lk1oIYesnBG3cV/stVT07cdVsByXoaJA==',
'js/privatebin.js' => 'sha512-WUwQX00pq9GWmMcB+umoiizpmlfGz9LjxAlUXzsNxjPh8vEcuy0gQ0lolidPmBPeNVBDzeh0DOmZ+h4gSH6ekw==',
'js/purify-3.2.6.js' => 'sha512-zqwL4OoBLFx89QPewkz4Lz5CSA2ktU+f31fuECkF0iK3Id5qd3Zpq5dMby8KwHjIEpsUgOqwF58cnmcaNem0EA==',
'js/showdown-2.1.0.js' => 'sha512-WYXZgkTR0u/Y9SVIA4nTTOih0kXMEd8RRV6MLFdL6YU8ymhR528NLlYQt1nlJQbYz4EW+ZsS0fx1awhiQJme1Q==',
'js/zlib-1.3.1-1.js' => 'sha512-5bU9IIP4PgBrOKLZvGWJD4kgfQrkTz8Z3Iqeu058mbQzW3mCumOU6M3UVbVZU9rrVoVwaW4cZK8U8h5xjF88eQ==',

View file

@ -109,7 +109,13 @@ if (count($class)) {
<form id="passwordform" role="form">
<div class="form-group">
<label for="passworddecrypt"><span class="glyphicon glyphicon-eye-open"></span> <?php echo I18n::_('Please enter the password for this document:') ?></label>
<input id="passworddecrypt" type="password" class="form-control" placeholder="<?php echo I18n::_('Enter password') ?>" required="required">
<div class="password-peek-container">
<input id="passworddecrypt" type="password" class="form-control input-password" placeholder="<?php echo I18n::_('Enter password') ?>" required="required">
<button class="toggle-password" type="button"
title="<?php echo I18n::_('Show password as plain text. Warning: this will display your password on the screen.'); ?>"
aria-label="<?php echo I18n::_('Show password as plain text. Warning: this will display your password on the screen.'); ?>">
</button>
</div>
</div>
<button type="submit" class="btn btn-success btn-block"><span class="glyphicon glyphicon-off"></span> <?php echo I18n::_('Decrypt') ?></button>
</form>
@ -368,7 +374,13 @@ if ($PASSWORD) :
?>
<li>
<div id="password" class="navbar-form hidden">
<input type="password" id="passwordinput" placeholder="<?php echo I18n::_('Password (recommended)'); ?>" class="form-control" size="23" />
<div class="password-peek-container">
<input type="password" id="passwordinput" placeholder="<?php echo I18n::_('Password (recommended)'); ?>" class="form-control input-password" size="23" />
<button class="toggle-password" type="button"
title="<?php echo I18n::_('Show password as plain text. Warning: this will display your password on the screen.'); ?>"
aria-label="<?php echo I18n::_('Show password as plain text. Warning: this will display your password on the screen.'); ?>">
</button>
</div>
</div>
</li>
<?php
@ -565,9 +577,9 @@ endif;
if (!empty($URLSHORTENER)) :
?>
<p>
<button id="shortenbutton" data-shortener="<?php echo I18n::encode($URLSHORTENER); ?>"
<button id="shortenbutton" data-shortener="<?php echo I18n::encode($URLSHORTENER); ?>"
<?php if ($SHORTENBYDEFAULT) : ?>
data-autoshorten="true"
data-autoshorten="true"
<?php endif; ?>
type="button" class="btn btn-<?php echo $isDark ? 'warning' : 'primary'; ?> btn-block"
>

View file

@ -82,7 +82,13 @@ endif;
<form id="passwordform" role="form">
<div class="mb-3">
<label for="passworddecrypt"><svg width="16" height="16" fill="currentColor" aria-hidden="true"><use href="img/bootstrap-icons.svg#eye" /></svg> <?php echo I18n::_('Please enter the password for this document:') ?></label>
<input id="passworddecrypt" type="password" class="form-control" placeholder="<?php echo I18n::_('Enter password') ?>" required="required" />
<div class="password-peek-container">
<input id="passworddecrypt" type="password" class="form-control input-password" placeholder="<?php echo I18n::_('Enter password') ?>" required="required" />
<button class="toggle-password" type="button"
title="<?php echo I18n::_('Show password as plain text. Warning: this will display your password on the screen.'); ?>"
aria-label="<?php echo I18n::_('Show password as plain text. Warning: this will display your password on the screen.'); ?>">
</button>
</div>
</div>
<button type="submit" class="btn btn-success btn-block"><svg width="16" height="16" fill="currentColor" aria-hidden="true"><use href="img/bootstrap-icons.svg#power" /></svg> <?php echo I18n::_('Decrypt') ?></button>
</form>
@ -243,7 +249,13 @@ if ($PASSWORD) :
?>
<li class="nav-item">
<div id="password" class="navbar-form hidden">
<input type="password" id="passwordinput" placeholder="<?php echo I18n::_('Password (recommended)'); ?>" aria-label="<?php echo I18n::_('Password (recommended)'); ?>" class="form-control" size="23" />
<div class="password-peek-container">
<input type="password" id="passwordinput" placeholder="<?php echo I18n::_('Password (recommended)'); ?>" aria-label="<?php echo I18n::_('Password (recommended)'); ?>" class="form-control input-password" size="23" />
<button class="toggle-password" type="button"
title="<?php echo I18n::_('Show password as plain text. Warning: this will display your password on the screen.'); ?>"
aria-label="<?php echo I18n::_('Show password as plain text. Warning: this will display your password on the screen.'); ?>">
</button>
</div>
</div>
</li>
<?php
@ -434,7 +446,7 @@ if (!empty($URLSHORTENER)) :
<p>
<button id="shortenbutton" data-shortener="<?php echo I18n::encode($URLSHORTENER); ?>"
<?php if ($SHORTENBYDEFAULT) : ?>
data-autoshorten="true"
data-autoshorten="true"
<?php endif; ?>
type="button" class="btn btn-primary btn-block d-flex justify-content-center align-items-center gap-1"
>