mirror of
https://github.com/9001/copyparty.git
synced 2026-06-21 21:52:25 -06:00
toast X in top right
This commit is contained in:
parent
bfd572829b
commit
53674248d1
|
|
@ -54,8 +54,7 @@ html {
|
||||||
bottom: 5em;
|
bottom: 5em;
|
||||||
right: -1em;
|
right: -1em;
|
||||||
line-height: 1.5em;
|
line-height: 1.5em;
|
||||||
padding: 1em 1.3em;
|
padding: 1em 2em 1em 1em;
|
||||||
margin-left: 3em;
|
|
||||||
border-width: .4em 0;
|
border-width: .4em 0;
|
||||||
overflow-wrap: break-word;
|
overflow-wrap: break-word;
|
||||||
transform: translateX(100%);
|
transform: translateX(100%);
|
||||||
|
|
@ -92,8 +91,8 @@ html {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
left: 0;
|
right: 0;
|
||||||
width: 0;
|
top: -.1em;
|
||||||
opacity: 0;
|
opacity: 0;
|
||||||
padding: .3em 0;
|
padding: .3em 0;
|
||||||
margin: -.3em 0 0 0;
|
margin: -.3em 0 0 0;
|
||||||
|
|
@ -102,7 +101,7 @@ html {
|
||||||
border: none;
|
border: none;
|
||||||
outline: none;
|
outline: none;
|
||||||
text-shadow: none;
|
text-shadow: none;
|
||||||
border-radius: .5em 0 0 .5em;
|
border-radius: .5em;
|
||||||
transition: left .3s, width .3s, padding .3s, opacity .3s;
|
transition: left .3s, width .3s, padding .3s, opacity .3s;
|
||||||
}
|
}
|
||||||
#toastb {
|
#toastb {
|
||||||
|
|
@ -130,9 +129,7 @@ html {
|
||||||
transform: initial;
|
transform: initial;
|
||||||
}
|
}
|
||||||
#toast.vis #toastc {
|
#toast.vis #toastc {
|
||||||
left: -2em;
|
padding: .3em .5em;
|
||||||
width: .4em;
|
|
||||||
padding: .3em .8em;
|
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
}
|
}
|
||||||
#toast.inf {
|
#toast.inf {
|
||||||
|
|
|
||||||
|
|
@ -1784,7 +1784,7 @@ var toast = (function () {
|
||||||
setcvar('--tmstep', Math.floor(sec * 20));
|
setcvar('--tmstep', Math.floor(sec * 20));
|
||||||
html += '<div id="toastt"></div>';
|
html += '<div id="toastt"></div>';
|
||||||
}
|
}
|
||||||
obj.innerHTML = html + '<a href="#" id="toastc">x</a><div id="toastb">' + lf2br(txt) + '</div>';
|
obj.innerHTML = html + '<a href="#" id="toastc">✕</a><div id="toastb">' + lf2br(txt) + '</div>';
|
||||||
obj.className = cl;
|
obj.className = cl;
|
||||||
sec += obj.offsetWidth;
|
sec += obj.offsetWidth;
|
||||||
obj.className += ' vis';
|
obj.className += ' vis';
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue