Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Michael Schreiber
passwordgrey
Commits
877e1f29
Commit
877e1f29
authored
Feb 16, 2021
by
Michael Schreiber
Browse files
better styling with animation
parent
b9bc5c09
Changes
3
Hide whitespace changes
Inline
Side-by-side
plugin.info.txt
View file @
877e1f29
base passwordgrey
author Michael Schreiber
email m.schreiber@creatronics.de
date 202
0-01-09
date 202
1-02-16
name passwordgrey plugin
desc display passwords in grey
url https://www.dokuwiki.org/plugin:passwordgrey
script.js
View file @
877e1f29
...
...
@@ -3,7 +3,7 @@
color_icobase
=
"
../../plugins/passwordgrey/images/
"
;
if
(
window
.
toolbar
!=
undefined
)
{
if
(
window
.
toolbar
!=
=
undefined
)
{
toolbar
[
toolbar
.
length
]
=
{
"
type
"
:
"
format
"
,
"
title
"
:
"
Password
"
,
...
...
@@ -12,7 +12,6 @@ if(window.toolbar != undefined) {
"
close
"
:
"
</pwd>
"
};
}
function
copyClip
(
id
){
var
copyText
=
document
.
getElementById
(
id
);
text
=
copyText
.
textContent
;
...
...
@@ -25,11 +24,11 @@ function copyClip(id){
document
.
body
.
removeChild
(
el
);
el
=
document
.
createElement
(
"
div
"
);
el
.
setAttribute
(
"
style
"
,
"
font-size: 2em;text-align:center;vertical-alignment:middle;position:absolute;top:40px;left: 50%;transform: translate(-50%, 0);background-color:light
grey
;
"
);
el
.
setAttribute
(
"
class
"
,
"
password
grey
CTC
"
);
el
.
innerHTML
=
"
Copied to clipboard!
"
;
setTimeout
(
function
(){
el
.
parentNode
.
removeChild
(
el
);
},
1
0
00
);
},
1
5
00
);
document
.
body
.
appendChild
(
el
);
}
style.css
View file @
877e1f29
.passwordgrey
{
color
:
lightgray
;
}
.passwordgreyCTC
{
font-size
:
2em
;
text-align
:
center
;
vertical-align
:
middle
;
position
:
fixed
;
top
:
40px
;
left
:
50%
;
transform
:
translate
(
-50%
,
0
);
background-color
:
lightgrey
;
border-radius
:
100000px
;
padding
:
10px
;
animation
:
showCTC
1.5s
linear
forwards
;
opacity
:
1
;
}
@keyframes
showCTC
{
0
%
{
opacity
:
0
;
}
50
%
{
opacity
:
1
;
}
100
%
{
opacity
:
0
;
}
}
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment