From 9fd50e02a737bc1ea715605f89a2958a7e7d9cad Mon Sep 17 00:00:00 2001 From: Abhishek Deshpande Date: Thu, 14 Mar 2019 16:59:07 +0530 Subject: [PATCH] adding instagram in Social Links --- includes/functions/theme-functions.php | 2 +- template/css/social-list.css | 6 ++++++ template/css/social-list.min.css | 2 +- template/customizer/customizer.php | 9 +++++++++ template/views/misc/social-links.php | 2 +- 5 files changed, 18 insertions(+), 3 deletions(-) diff --git a/includes/functions/theme-functions.php b/includes/functions/theme-functions.php index f4a88ff..e96248c 100644 --- a/includes/functions/theme-functions.php +++ b/includes/functions/theme-functions.php @@ -2733,7 +2733,7 @@ function better_amp_social_share_get_li( $id = '', $show_title = true, $count_la $title = __( 'VK', 'better-amp' ); $icon = ''; break; - + default: return ''; } diff --git a/template/css/social-list.css b/template/css/social-list.css index 3839e58..c50dda4 100644 --- a/template/css/social-list.css +++ b/template/css/social-list.css @@ -165,3 +165,9 @@ ul.social-list{ .social-list .social-item.whatsapp a:hover { background-color: #00c462; } +.social-list .social-item.instagram a { + background-color: #e1306c; +} +.social-list .social-item.instagram a:hover { + background-color: #c13584; +} diff --git a/template/css/social-list.min.css b/template/css/social-list.min.css index e47a44e..93d9aa0 100644 --- a/template/css/social-list.min.css +++ b/template/css/social-list.min.css @@ -1 +1 @@ -.social-list-wrapper{margin:15px 0}.social-list-wrapper.share-list{border:1px solid #e2e2e2;padding:10px 10px 6px}.social-list-wrapper .number{font-size:12px;font-weight:700;margin:0 0 0 4px;font-family:Arial,"Helvetica Neue",Helvetica,sans-serif;display:inline-block}.social-list-wrapper .post-share-btn{background:#fff;border:1px solid #e2e2e2;line-height:30px;height:30px;display:inline-block;padding:0 10px;border-radius:30px;font-size:12px;color:#4d4d4d;margin-right:8px;margin-bottom:4px;vertical-align:top}.social-list-wrapper .post-share-btn .fa{font-size:14px}.social-list-wrapper .post-share-btn .fa,.social-list-wrapper .post-share-btn .number,.social-list-wrapper .post-share-btn .text{line-height:28px;vertical-align:top}.social-list-wrapper .post-share-btn .text{font-size:12px;margin-left:3px}ul.social-list{list-style:none;margin:0;padding:0;display:inline-block;font-size:0;vertical-align:top}.social-list li{display:inline-block;margin-right:6px;vertical-align:top}.social-list li:last-child{margin-right:0}.social-list .social-item a{color:#fff;min-width:30px;height:30px;overflow:hidden;border-radius:15px;background:#bbb;display:inline-block;text-align:center;vertical-align:middle;font-size:14px;line-height:28px;margin-bottom:5px}.social-list .social-item.has-count a{padding:0 10px}.social-list .social-item.has-count .fa{margin-right:1px}.social-list .fa{vertical-align:middle}.social-list .item-title,.social-list .number:empty{display:none}.social-list .social-item.facebook a{background-color:#2d5f9a}.social-list .social-item.facebook a:hover{background-color:#1b4a82}.social-list .social-item.twitter a{background-color:#53c7ff}.social-list .social-item.twitter a:hover{background-color:#369ed0}.social-list .social-item.google_plus a{background-color:#d93b2b}.social-list .social-item.google_plus a:hover{background-color:#b7291a}.social-list .social-item.pinterest a{background-color:#a41719}.social-list .social-item.pinterest a:hover{background-color:#8c0a0c}.social-list .social-item.linkedin a{background-color:#005182}.social-list .social-item.linkedin a:hover{background-color:#003b5f}.social-list .social-item.email a{background-color:#444}.social-list .social-item.email a:hover{background-color:#2f2f2f}.social-list .social-item.tumblr a{background-color:#3e5a70}.social-list .social-item.tumblr a:hover{background-color:#426283}.social-list .social-item.telegram a{background-color:#179cde}.social-list .social-item.telegram a:hover{background-color:#0f8dde}.social-list .social-item.reddit a{background-color:#ff4500}.social-list .social-item.reddit a:hover{background-color:#dc3c01}.social-list .social-item.stumbleupon a{background-color:#ee4813}.social-list .social-item.stumbleupon a:hover{background-color:#ce3d0f}.social-list .social-item.vk a{background-color:#4c75a3}.social-list .social-item.vk a:hover{background-color:#3e5f84}.social-list .social-item.digg a{background-color:#000}.social-list .social-item.digg a:hover{background-color:#2f2f2f}.social-list .social-item.whatsapp a{background-color:#00e676}.social-list .social-item.whatsapp a:hover{background-color:#00c462} \ No newline at end of file +.social-list-wrapper{margin:15px 0}.social-list-wrapper.share-list{border:1px solid #e2e2e2;padding:10px 10px 6px}.social-list-wrapper .number{font-size:12px;font-weight:700;margin:0 0 0 4px;font-family:Arial,"Helvetica Neue",Helvetica,sans-serif;display:inline-block}.social-list-wrapper .post-share-btn{background:#fff;border:1px solid #e2e2e2;line-height:30px;height:30px;display:inline-block;padding:0 10px;border-radius:30px;font-size:12px;color:#4d4d4d;margin-right:8px;margin-bottom:4px;vertical-align:top}.social-list-wrapper .post-share-btn .fa{font-size:14px}.social-list-wrapper .post-share-btn .fa,.social-list-wrapper .post-share-btn .number,.social-list-wrapper .post-share-btn .text{line-height:28px;vertical-align:top}.social-list-wrapper .post-share-btn .text{font-size:12px;margin-left:3px}ul.social-list{list-style:none;margin:0;padding:0;display:inline-block;font-size:0;vertical-align:top}.social-list li{display:inline-block;margin-right:6px;vertical-align:top}.social-list li:last-child{margin-right:0}.social-list .social-item a{color:#fff;min-width:30px;height:30px;overflow:hidden;border-radius:15px;background:#bbb;display:inline-block;text-align:center;vertical-align:middle;font-size:14px;line-height:28px;margin-bottom:5px}.social-list .social-item.has-count a{padding:0 10px}.social-list .social-item.has-count .fa{margin-right:1px}.social-list .fa{vertical-align:middle}.social-list .item-title,.social-list .number:empty{display:none}.social-list .social-item.facebook a{background-color:#2d5f9a}.social-list .social-item.facebook a:hover{background-color:#1b4a82}.social-list .social-item.twitter a{background-color:#53c7ff}.social-list .social-item.twitter a:hover{background-color:#369ed0}.social-list .social-item.google_plus a{background-color:#d93b2b}.social-list .social-item.google_plus a:hover{background-color:#b7291a}.social-list .social-item.pinterest a{background-color:#a41719}.social-list .social-item.pinterest a:hover{background-color:#8c0a0c}.social-list .social-item.linkedin a{background-color:#005182}.social-list .social-item.linkedin a:hover{background-color:#003b5f}.social-list .social-item.email a{background-color:#444}.social-list .social-item.email a:hover{background-color:#2f2f2f}.social-list .social-item.tumblr a{background-color:#3e5a70}.social-list .social-item.tumblr a:hover{background-color:#426283}.social-list .social-item.telegram a{background-color:#179cde}.social-list .social-item.telegram a:hover{background-color:#0f8dde}.social-list .social-item.reddit a{background-color:#ff4500}.social-list .social-item.reddit a:hover{background-color:#dc3c01}.social-list .social-item.stumbleupon a{background-color:#ee4813}.social-list .social-item.stumbleupon a:hover{background-color:#ce3d0f}.social-list .social-item.vk a{background-color:#4c75a3}.social-list .social-item.vk a:hover{background-color:#3e5f84}.social-list .social-item.digg a{background-color:#000}.social-list .social-item.digg a:hover{background-color:#2f2f2f}.social-list .social-item.whatsapp a{background-color:#00e676}.social-list .social-item.whatsapp a:hover{background-color:#00c462} .social-list .social-item.instagram a {background-color: #e1306c;}.social-list .social-item.instagram a:hover {background-color: #c13584;} \ No newline at end of file diff --git a/template/customizer/customizer.php b/template/customizer/customizer.php index d92bbb8..b75821b 100644 --- a/template/customizer/customizer.php +++ b/template/customizer/customizer.php @@ -339,6 +339,15 @@ function better_amp_customize_register( $wp_customizer ) { 'priority' => 24, ) ); + $wp_customizer->add_setting( 'better-amp-instagram', array( + 'default' => '#', + 'transport' => 'postMessage', + ) ); + $wp_customizer->add_control( 'better-amp-instagram', array( + 'label' => __( 'Instagram', 'better-amp' ), + 'section' => 'better-amp-sidebar-section', + 'priority' => 24, + ) ); /** * 2.5 Copyright text diff --git a/template/views/misc/social-links.php b/template/views/misc/social-links.php index c71aa5b..04d1c49 100644 --- a/template/views/misc/social-links.php +++ b/template/views/misc/social-links.php @@ -7,7 +7,7 @@