mirror of
https://github.com/openvk/openvk
synced 2024-11-11 01:19:53 +03:00
Add smooth spoiler animations
Co-authored-by: Kos Furler <35310076+kosfurler@users.noreply.github.com>
This commit is contained in:
parent
b2f7d3b662
commit
e3fdf75b26
1 changed files with 13 additions and 12 deletions
|
@ -1,15 +1,4 @@
|
||||||
function hidePanel(el,count=null) {
|
|
||||||
var info = el.parentNode.children[1];
|
|
||||||
if (info.style.display=="none") {
|
|
||||||
info.style.display="block";
|
|
||||||
el.className = "content_title_expanded";
|
|
||||||
if (count) el.innerHTML=el.innerHTML.replace(" ("+count+")","");
|
|
||||||
} else {
|
|
||||||
info.style.display="none";
|
|
||||||
el.className = "content_title_unexpanded";
|
|
||||||
if (count) el.innerHTML+=" ("+count+")";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function show_write_textarea() {
|
function show_write_textarea() {
|
||||||
var el = document.getElementById('write');
|
var el = document.getElementById('write');
|
||||||
|
@ -32,6 +21,18 @@ function edit_post(id, wid) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
$(function () {
|
||||||
|
$('.content_title_expanded').click(function(){
|
||||||
|
$(this).toggleClass("content_title_expanded content_title_unexpanded");
|
||||||
|
$(this).next('div').slideToggle(300);
|
||||||
|
});});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
document.addEventListener("DOMContentLoaded", function() { //BEGIN
|
document.addEventListener("DOMContentLoaded", function() { //BEGIN
|
||||||
|
|
||||||
u("#_photoDelete").on("click", function(e) {
|
u("#_photoDelete").on("click", function(e) {
|
||||||
|
|
Loading…
Reference in a new issue