aboutsummaryrefslogtreecommitdiff
path: root/public
diff options
context:
space:
mode:
Diffstat (limited to 'public')
-rw-r--r--public/css/head.css5
-rw-r--r--public/js/Input.js12
2 files changed, 10 insertions, 7 deletions
diff --git a/public/css/head.css b/public/css/head.css
index 3d9d6ca..b5f1bd1 100644
--- a/public/css/head.css
+++ b/public/css/head.css
@@ -90,11 +90,6 @@ header a
90#header_social_content img 90#header_social_content img
91{ 91{
92 width: 28px; 92 width: 28px;
93
94}
95#header_social_content a img
96{
97 width: 28px;
98 background-color: #ffffffb3; 93 background-color: #ffffffb3;
99 border-radius: 50%; 94 border-radius: 50%;
100} 95}
diff --git a/public/js/Input.js b/public/js/Input.js
index 6c5af10..54872d1 100644
--- a/public/js/Input.js
+++ b/public/js/Input.js
@@ -76,11 +76,19 @@ class InputText extends InputToggler{
76 76
77class InputTextSocialNetwork extends InputText{ 77class InputTextSocialNetwork extends InputText{
78 open(){ 78 open(){
79 this.input_elem.value = this.content_elem.parentNode.href; 79 const elem_parent = this.content_elem.parentNode;
80 if(elem_parent.tagName.toLowerCase() === 'a'){
81 this.input_elem.value = elem_parent.href;
82 }
80 super.open(); 83 super.open();
81 } 84 }
82 onSuccess(data){ 85 onSuccess(data){
83 this.content_elem.parentNode.href = this.input_elem.value; 86 if(this.input_elem.value){
87 this.content_elem.parentNode.href = this.input_elem.value;
88 }
89 else{
90 this.content_elem.parentNode.removeAttribute('href');
91 }
84 } 92 }
85} 93}
86 94