mirror of
https://github.com/S2-/pwgen.git
synced 2025-08-04 01:30:04 +02:00
Compare commits
7 Commits
Author | SHA1 | Date | |
---|---|---|---|
0d6278cd82 | |||
fee9b6b20a | |||
5959bc4cbe | |||
93c4955d1d | |||
3a64948533 | |||
a0d5b54b5d | |||
396236254a |
12
README.md
Normal file
12
README.md
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
# pwgen reloaded
|
||||||
|
|
||||||
|
## What it does
|
||||||
|
|
||||||
|
A firefox addon that generates a password and copies it to the clipboard
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
## install
|
||||||
|
|
||||||
|
On amo!
|
||||||
|
[https://addons.mozilla.org/firefox/addon/pwgen-reloaded/](https://addons.mozilla.org/firefox/addon/pwgen-reloaded/)
|
Binary file not shown.
Before Width: | Height: | Size: 68 KiB After Width: | Height: | Size: 29 KiB |
@@ -1,5 +0,0 @@
|
|||||||
# pwgen
|
|
||||||
|
|
||||||
## What it does ##
|
|
||||||
|
|
||||||
Simply generate a password and copy it to the clipboard
|
|
@@ -2,7 +2,7 @@
|
|||||||
"description": "Just a toolbar button that generates a password and copies it to your clipboard.",
|
"description": "Just a toolbar button that generates a password and copies it to your clipboard.",
|
||||||
"manifest_version": 2,
|
"manifest_version": 2,
|
||||||
"name": "pwgen reloaded",
|
"name": "pwgen reloaded",
|
||||||
"version": "1.1.8",
|
"version": "1.1.10",
|
||||||
"homepage_url": "https://github.com/S2-/pwgen",
|
"homepage_url": "https://github.com/S2-/pwgen",
|
||||||
"icons": {
|
"icons": {
|
||||||
"48": "icons/lock-48.png"
|
"48": "icons/lock-48.png"
|
||||||
|
@@ -21,6 +21,18 @@ input[type="number"] {
|
|||||||
font-size: inherit;
|
font-size: inherit;
|
||||||
padding: 5px 10px;
|
padding: 5px 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
input[type="checkbox"] {
|
input[type="checkbox"] {
|
||||||
margin-bottom: -7px;
|
margin-bottom: -7px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#copied {
|
||||||
|
/*height: 100%;*/
|
||||||
|
width: 100%;
|
||||||
|
background-color: #FFF8DC;
|
||||||
|
position: absolute;
|
||||||
|
margin: -25px;
|
||||||
|
margin-top: -5px;
|
||||||
|
padding: 5px;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
@@ -10,6 +10,8 @@
|
|||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
|
<div id="copied" style="display: none;">password copied to clipboard</div>
|
||||||
|
|
||||||
<form>
|
<form>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
|
@@ -34,14 +34,31 @@ function saveOptions(options) {
|
|||||||
return browser.storage.local.set(options);
|
return browser.storage.local.set(options);
|
||||||
}
|
}
|
||||||
|
|
||||||
function copypasstoclippboard() {
|
function copypasstoclippboard(cb) {
|
||||||
setTimeout(function() {
|
setTimeout(function() {
|
||||||
var copyText = document.getElementById('pw');
|
var copyText = document.getElementById('pw');
|
||||||
copyText.select();
|
copyText.select();
|
||||||
document.execCommand('copy');
|
document.execCommand('copy');
|
||||||
|
if (typeof(cb) === 'function') {
|
||||||
|
cb();
|
||||||
|
}
|
||||||
|
fade(document.getElementById('copied'));
|
||||||
}, 200);
|
}, 200);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function fade(element) {
|
||||||
|
element.style.display = 'block';
|
||||||
|
var op = 1; // initial opacity
|
||||||
|
var timer = setInterval(function () {
|
||||||
|
if (op <= 0.1) {
|
||||||
|
clearInterval(timer);
|
||||||
|
element.style.display = 'none';
|
||||||
|
}
|
||||||
|
element.style.opacity = op;
|
||||||
|
op -= op * 0.1;
|
||||||
|
}, 50);
|
||||||
|
}
|
||||||
|
|
||||||
document.addEventListener('DOMContentLoaded', function() {
|
document.addEventListener('DOMContentLoaded', function() {
|
||||||
|
|
||||||
document.getElementById('new').addEventListener('click', (ev) => {
|
document.getElementById('new').addEventListener('click', (ev) => {
|
||||||
@@ -74,4 +91,3 @@ document.addEventListener('DOMContentLoaded', function() {
|
|||||||
});
|
});
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user