Social Share Buttons – Social Pug - Version 1.7.0

Version Description

  • ENHANCEMENT: Change name and branding to Grow by Mediavine
  • ENHANCEMENT: Ensure text remains visible during icon webfont load
  • ENHANCEMENT: Optimize Javascript
  • ENHANCEMENT: Better accessibility for share buttons
  • FIX: Better spacing for the inline links
  • FIX: Total Shares won't wrap lines
Download this release

Release Info

Developer mediavine
Plugin Icon Social Share Buttons – Social Pug
Version 1.7.0
Comparing to
See all releases

Version 1.7.0

Files changed (91) hide show
  1. assets/dist/dashboard.1.0.0.js +1 -0
  2. assets/dist/dpsp-selectable-empty.1.0.0.png +0 -0
  3. assets/dist/front-end-jquery.1.0.0.js +1 -0
  4. assets/dist/front-end.1.0.0.js +1 -0
  5. assets/dist/jquery.ui.touch-punch.min.1.0.0.js +1 -0
  6. assets/dist/socialpug.1.0.0.eot +0 -0
  7. assets/dist/socialpug.1.0.0.svg +70 -0
  8. assets/dist/socialpug.1.0.0.ttf +0 -0
  9. assets/dist/socialpug.1.0.0.woff +0 -0
  10. assets/dist/style-dashboard.1.0.0.css +1 -0
  11. assets/dist/style-frontend-jquery.1.0.0.css +1 -0
  12. assets/dist/style-frontend.1.0.0.css +1 -0
  13. assets/src/css/style-dashboard.css +1282 -0
  14. assets/src/css/style-frontend-jquery.css +699 -0
  15. assets/src/css/style-frontend.css +685 -0
  16. assets/src/dev-entry-jquery.js +4 -0
  17. assets/src/dev-entry.js +4 -0
  18. assets/src/entry.html +14 -0
  19. assets/src/fonts/socialpug.eot +0 -0
  20. assets/src/fonts/socialpug.svg +70 -0
  21. assets/src/fonts/socialpug.ttf +0 -0
  22. assets/src/fonts/socialpug.woff +0 -0
  23. assets/src/img/dpsp-icon-sort-handle.png +0 -0
  24. assets/src/img/dpsp-icon-tooltip.png +0 -0
  25. assets/src/img/dpsp-selectable-empty.png +0 -0
  26. assets/src/img/extension-bitly.png +0 -0
  27. assets/src/img/extension-branch.png +0 -0
  28. assets/src/img/extension-ctt.png +0 -0
  29. assets/src/img/extension-ga-utm-tracking.png +0 -0
  30. assets/src/img/extension-networks.png +0 -0
  31. assets/src/img/feedback-thank-you.png +0 -0
  32. assets/src/img/grow-logo-sq-navy.png +0 -0
  33. assets/src/img/opt-in-hound-banner.png +0 -0
  34. assets/src/img/opt-in-hound-icon-256x256.png +0 -0
  35. assets/src/img/opt-in-hound-promo-pop-up.png +0 -0
  36. assets/src/img/opt-in-hound-promo-widget.png +0 -0
  37. assets/src/img/skyepress-banner-clouds.png +0 -0
  38. assets/src/img/skyepress-banner.png +0 -0
  39. assets/src/img/skyepress-promo-1.png +0 -0
  40. assets/src/img/skyepress-promo-2.png +0 -0
  41. assets/src/img/skyepress-promo-3.png +0 -0
  42. assets/src/img/skyepress-social-pug-promo.png +0 -0
  43. assets/src/img/social-pug-upgrade.png +0 -0
  44. assets/src/img/tool-content.png +0 -0
  45. assets/src/img/tool-follow-widget.png +0 -0
  46. assets/src/img/tool-image-hover-pinterest.png +0 -0
  47. assets/src/img/tool-integrations-logo-edd.png +0 -0
  48. assets/src/img/tool-integrations-logo-pb.png +0 -0
  49. assets/src/img/tool-integrations-logo-pms.png +0 -0
  50. assets/src/img/tool-integrations-logo-woocommerce.png +0 -0
  51. assets/src/img/tool-mobile.png +0 -0
  52. assets/src/img/tool-opt-in-icon-after-content.png +0 -0
  53. assets/src/img/tool-opt-in-icon-fly-in.png +0 -0
  54. assets/src/img/tool-opt-in-icon-pop-up.png +0 -0
  55. assets/src/img/tool-opt-in-icon-shortcode.png +0 -0
  56. assets/src/img/tool-opt-in-icon-widget.png +0 -0
  57. assets/src/img/tool-pop-up.png +0 -0
  58. assets/src/img/tool-sidebar.png +0 -0
  59. assets/src/js/dashboard.js +611 -0
  60. assets/src/js/front-end-jquery.js +105 -0
  61. assets/src/js/front-end.js +80 -0
  62. assets/src/js/jquery.ui.touch-punch.min.js +11 -0
  63. inc/admin/admin-metaboxes.php +136 -0
  64. inc/admin/feedback-form/assets/css/style-admin-feedback-form.css +77 -0
  65. inc/admin/feedback-form/assets/img/corgi-100x100.png +0 -0
  66. inc/admin/feedback-form/assets/js/script-admin-feedback-form.js +197 -0
  67. inc/admin/feedback-form/functions-ajax.php +62 -0
  68. inc/admin/feedback-form/functions.php +37 -0
  69. inc/admin/feedback-form/views/view-feedback-form.php +99 -0
  70. inc/admin/submenu-page-content.php +55 -0
  71. inc/admin/submenu-page-extensions.php +27 -0
  72. inc/admin/submenu-page-settings.php +79 -0
  73. inc/admin/submenu-page-sidebar.php +55 -0
  74. inc/admin/submenu-page-toolkit.php +25 -0
  75. inc/admin/views/view-submenu-page-content.php +118 -0
  76. inc/admin/views/view-submenu-page-extensions-sub-page-opt-in-hound.php +86 -0
  77. inc/admin/views/view-submenu-page-extensions.php +102 -0
  78. inc/admin/views/view-submenu-page-settings.php +92 -0
  79. inc/admin/views/view-submenu-page-sidebar.php +110 -0
  80. inc/admin/views/view-submenu-page-toolkit.php +19 -0
  81. inc/functions-admin.php +864 -0
  82. inc/functions-cron.php +134 -0
  83. inc/functions-frontend.php +468 -0
  84. inc/functions-share-counts.php +597 -0
  85. inc/functions-version-update.php +85 -0
  86. inc/functions.php +627 -0
  87. index.php +335 -0
  88. readme.txt +281 -0
  89. screenshot-1.png +0 -0
  90. screenshot-2.png +0 -0
  91. utils/after-build.js +53 -0
assets/dist/dashboard.1.0.0.js ADDED
@@ -0,0 +1 @@
 
1
+ jQuery(function(s){function t(t){s('.dpsp-social-platforms-sort-list li[data-network="'+t+'"]').remove(),s(".dpsp-social-platforms-sort-list li").removeClass("dpsp-last"),s(".dpsp-social-platforms-sort-list li").last().addClass("dpsp-last"),0==s(".dpsp-social-platforms-sort-list li").length&&(s(".dpsp-social-platforms-sort-list").fadeOut(1),s(".dpsp-social-platforms-sort-list").removeClass("dpsp-active"))}s(document).on("click",".dpsp-tool-wrapper .dpsp-switch label",function(t){var e=s(this).closest(".dpsp-tool-actions"),p=e.find(".dpsp-tool-settings");p.fadeOut(200),e.append('<div class="dpsp-tool-actions-overlay"><div class="spinner"></div></div>'),e.find(".dpsp-tool-actions-overlay").animate({opacity:1},200);var a,i,o=s(this).siblings("input").data("tool"),d=s(this).siblings("input").data("tool-activation");"undefined"!=o&&(e.hasClass("dpsp-inactive")?(a=d,i={action:"dpsp_activate_tool",dpsptkn:s("#dpsptkn").val(),setting:a},s.post(ajaxurl,i,function(){})).done(function(t){1==t&&(e.find(".dpsp-tool-actions-overlay").animate({opacity:0},200,function(){s(this).remove()}),e.removeClass("dpsp-inactive").addClass("dpsp-active"),e.find("span").text("Active"),p.fadeIn(200))}):function(t){var e={action:"dpsp_deactivate_tool",dpsptkn:s("#dpsptkn").val(),setting:t};return s.post(ajaxurl,e,function(){})}(d).done(function(t){var p;1==t&&(e.find(".dpsp-tool-actions-overlay").animate({opacity:0},200,function(){s(this).remove()}),e.removeClass("dpsp-active").addClass("dpsp-inactive"),e.find("span").text("Inactive"),p=(p=o).replace("share_","").replace("follow_","").replace("_","-"),s("#toplevel_page_dpsp-social-pug .wp-submenu li a").each(function(){-1!=s(this).attr("href").indexOf(p)&&s(this).parent().hide()}))}))}),s.fn.select2&&s(".dpsp-setting-field-select select").select2({minimumResultsForSearch:1/0}).on("select2:open",function(){s(".select2-container").last().addClass("dpsp-select2")}),s(function(){s(".dpsp-social-platforms-sort-list").sortable({handle:".dpsp-sort-handle",placeholder:"dpsp-sort-placeholder",containment:"#wpwrap"})}),s(document).on("click","#dpsp-networks-selector .dpsp-network-item",function(){$this=s(this),$checkbox=$this.children(".dpsp-network-item-checkbox"),$this.attr("data-checked")?$this.removeAttr("data-checked"):$this.attr("data-checked","true")}),s(document).on("click","#dpsp-select-networks",function(t){t.preventDefault(),s("#dpsp-networks-selector-wrapper").hasClass("dpsp-active")?(s("#dpsp-networks-selector-wrapper").removeClass("dpsp-active"),s("#dpsp-networks-selector-wrapper").stop().fadeOut(250,function(){0==s(".dpsp-social-platforms-sort-list").find("li").length?(s("#dpsp-sortable-networks-empty").stop().fadeIn(400),s("#dpsp-sortable-networks-empty").addClass("dpsp-active")):(s(".dpsp-social-platforms-sort-list").stop().fadeIn(400),s(".dpsp-social-platforms-sort-list").addClass("dpsp-active"))})):(s("#dpsp-select-networks").hide(),s("#dpsp-networks-selector-wrapper").addClass("dpsp-active"),0==s(".dpsp-social-platforms-sort-list").find("li").length?(s(".dpsp-social-platforms-sort-list").hide(),s("#dpsp-sortable-networks-empty").removeClass("dpsp-active"),s("#dpsp-sortable-networks-empty").stop().fadeOut(250,function(){s("#dpsp-networks-selector-wrapper").stop().fadeIn(250)})):(s(".dpsp-social-platforms-sort-list").removeClass("dpsp-active"),s(".dpsp-social-platforms-sort-list").stop().fadeOut(250,function(){s("#dpsp-networks-selector-wrapper").stop().fadeIn(250)})))}),s(document).on("click","#dpsp-networks-selector-footer a",function(e){e.preventDefault(),s("#dpsp-select-networks").show(),s("#dpsp-networks-selector .dpsp-network-item").each(function(){$this=s(this);var e=$this.attr("data-network"),p=$this.attr("data-network-name");if($this.attr("data-checked")){var a=!1;if(s(".dpsp-social-platforms-sort-list li").each(function(){s(this).attr("data-network")==e&&(a=!0)}),a)return a;!function(t,e){if("undefined"==t)return!1;if("undefined"==e)return!1;var p="",a=s('input[name="dpsp_buttons_location"]').val();p+='<li data-network="'+t+'">',p+='<div class="dpsp-sort-handle ui-sortable-handle">\x3c!-- --\x3e</div>',p+='<div class="dpsp-list-icon dpsp-list-icon-social dpsp-icon-'+t+" dpsp-background-color-network-"+t+'">\x3c!-- --\x3e</div>',p+='<div class="dpsp-list-input-wrapper"><input type="text" placeholder="This button has no label text." name="'+a+"[networks]["+t+'][label]" value="'+e+'"></div>',p+='<div class="dpsp-list-actions">',p+='<a class="dpsp-list-edit-label dpsp-transition" href="#"><span class="dashicons dashicons-edit"></span>Edit Label</a>',p+='<a class="dpsp-list-remove dpsp-transition" href="#"><span class="dashicons dashicons-no-alt"></span>Remove</a>',p+="</div>",p+="</li>",s(".dpsp-social-platforms-sort-list").append(p),s(".dpsp-social-platforms-sort-list li").removeClass("dpsp-last"),s(".dpsp-social-platforms-sort-list li").last().addClass("dpsp-last")}(e,p)}else t(e)}),s("#dpsp-networks-selector-wrapper").removeClass("dpsp-active").stop().fadeOut(250,function(){0==s(".dpsp-social-platforms-sort-list").find("li").length?(s("#dpsp-sortable-networks-empty").stop().fadeIn(250),s("#dpsp-sortable-networks-empty").addClass("dpsp-active")):(s(".dpsp-social-platforms-sort-list").stop().fadeIn(250),s(".dpsp-social-platforms-sort-list").addClass("dpsp-active"))})}),s(document).on("click",".dpsp-list-edit-label",function(t){t.preventDefault(),s(this).closest("li").find(".dpsp-list-input-wrapper input").focus().select()}),s(document).on("click",".dpsp-list-remove",function(e){e.preventDefault();var p=s(this).closest("li").attr("data-network");t(p),s('#dpsp-networks-selector .dpsp-network-item[data-network="'+p+'"]').removeAttr("data-checked"),0==s(".dpsp-social-platforms-sort-list").find("li").length&&(s("#dpsp-sortable-networks-empty").stop().fadeIn(250),s("#dpsp-sortable-networks-empty").addClass("dpsp-active"),s(".dpsp-social-platforms-sort-list").removeClass("dpsp-active"))}),s(document).ready(function(){s(".dpsp-network-btn").attr("href","#")}),s(document).on("click",".dpsp-network-btn",function(t){t.preventDefault(),s(this).closest("label").click()}),s(document).on("focus",".dpsp-page-mobile .dpsp-list-input-wrapper input",function(){s(this).blur()}),s(document).on("click",".dpsp-setting-field-button-shape input",function(){s(this).closest(".dpsp-page-wrapper").find(".dpsp-networks-btns-wrapper").parent().removeClass("dpsp-shape-circle dpsp-shape-rounded dpsp-shape-rectangular").addClass("dpsp-shape-"+s(this).val())}),s(document).on("mouseenter",".dpsp-setting-field-tooltip-icon",function(){s(this).siblings("div").css("opacity",1).css("visibility","visible")}),s(document).on("mouseleave",".dpsp-setting-field-tooltip-icon",function(){s(this).siblings("div").css("opacity",0).css("visibility","hidden")}),s(document).on("mouseenter",".dpsp-setting-field-tooltip-wrapper.dpsp-has-link",function(){s(this).find("div").css("opacity",1).css("visibility","visible")}),s(document).on("mouseleave",".dpsp-setting-field-tooltip-wrapper.dpsp-has-link",function(){s(this).find("div").css("opacity",0).css("visibility","hidden")}),s(document).on("change",".dpsp-setting-field-wrapper *",function(){s(".dpsp-card-inner").each(function(){s(this).find(".dpsp-setting-field-wrapper").removeClass("dpsp-last"),s(this).find(".dpsp-setting-field-wrapper:not(.disabled)").last().addClass("dpsp-last")})}),s(".dpsp-setting-field-wrapper *").first().trigger("change"),s(function(){function t(){$checkbox_total_shares.is(":checked")||$checkbox_shares.is(":checked")?($wrapper_checkbox_count_round.removeClass("disabled"),$checkbox_count_round.attr("disabled",!1)):($wrapper_checkbox_count_round.addClass("disabled"),$checkbox_count_round.attr("disabled",!0))}$checkbox_shares=s(".dpsp-setting-field-show-share-count input[type=checkbox]"),$checkbox_total_shares=s(".dpsp-setting-field-show-total-share-count input[type=checkbox]"),$checkbox_count_round=s(".dpsp-setting-field-share-count-round input[type=checkbox]"),$wrapper_checkbox_count_round=$checkbox_count_round.closest(".dpsp-setting-field-wrapper"),$checkbox_total_shares.is(":checked")||($checkbox_total_shares.closest(".dpsp-setting-field-wrapper").next().addClass("disabled"),$checkbox_total_shares.closest(".dpsp-setting-field-wrapper").next().find("select").attr("disabled",!0)),$checkbox_total_shares.change(function(){$checkbox_total_shares.is(":checked")?($checkbox_total_shares.closest(".dpsp-setting-field-wrapper").next().removeClass("disabled"),$checkbox_total_shares.closest(".dpsp-setting-field-wrapper").next().find("select").attr("disabled",!1)):($checkbox_total_shares.closest(".dpsp-setting-field-wrapper").next().addClass("disabled"),$checkbox_total_shares.closest(".dpsp-setting-field-wrapper").next().find("select").attr("disabled",!0))}),t(),$checkbox_shares.change(function(){t()}),$checkbox_total_shares.change(function(){t()})}),s(document).on("click","#dpsp-refresh-share-counts",function(t){if(t.preventDefault(),s(this).hasClass("disabled"))return!1;$refresh_button=s(this),$spinner=$refresh_button.siblings(".spinner"),$refresh_button.addClass("disabled"),$spinner.css("visibility","visible"),s(".dpsp-statistic-bar-wrapper-network").css("opacity",.6);var e={action:"dpsp_refresh_share_counts",nonce:$refresh_button.siblings('[name="dpsp_refresh_share_counts"]').val(),post_id:parseInt(s("#post_ID").val())};s.post(ajaxurl,e,function(t){t&&s(".dpsp-statistic-bars-wrapper").replaceWith(t)})}),s(document).on("change",'[name="dpsp_settings[facebook_share_counts_provider]"]',function(){s(".dpsp-setting-field-facebook-authorize-app").hide(),s(".dpsp-setting-field-facebook-app-id, .dpsp-setting-field-facebook-app-secret").hide(),"authorized_app"==s(this).val()&&s(".dpsp-setting-field-facebook-authorize-app").show(),"own_app"==s(this).val()&&s(".dpsp-setting-field-facebook-app-id, .dpsp-setting-field-facebook-app-secret").show()}),s('[name="dpsp_settings[facebook_share_counts_provider]"]').trigger("change"),s(document).on("keyup","#dpsp-deactivate-modal [name=dpsp_disable_text]",function(){""!=s(this).val()?s("#dpsp-feedback-submit").attr("disabled",!1):s("#dpsp-feedback-submit").attr("disabled",!0)}),s(document).on("keyup","#dpsp-deactivate-modal [name=dpsp_disable_from]",function(){var t;t=s(this).val(),/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(String(t).toLowerCase())?s("#dpsp-feedback-submit").attr("disabled",!1):s("#dpsp-feedback-submit").attr("disabled",!0)}),s("#dpsp-feedback-submit").click(function(t){t.preventDefault(),s("#dpsp-deactivate-modal").hide(),s.ajax({type:"POST",url:ajaxurl,dataType:"json",data:{action:"dpsp_send_deactivation_feedback",data:s("#dpsp-deactivate-modal form").serialize()},complete:function(t,e,p){s("#dpsp-deactivate-modal").remove(),window.location.href=s('.wp-admin.plugins-php tr[data-slug="social-pug"] .row-actions .deactivate a').attr("href")}})}),s("#dpsp-only-deactivate").click(function(t){t.preventDefault(),s("#dpsp-deactivate-modal").hide(),s("#dpsp-deactivate-modal").remove(),window.location.href=s('.wp-admin.plugins-php tr[data-slug="social-pug"] .row-actions .deactivate a').attr("href")}),s(".dpsp-deactivate-close").click(function(t){t.preventDefault(),s("#dpsp-deactivate-modal").hide()})});
assets/dist/dpsp-selectable-empty.1.0.0.png ADDED
Binary file
assets/dist/front-end-jquery.1.0.0.js ADDED
@@ -0,0 +1 @@
 
1
+ jQuery(function(t){t(document).ready(function(){"undefined"!=typeof dpsp_ajax_url&&"undefined"!=typeof dpsp_ajax_pull_post_share_counts_data&&t.post(dpsp_ajax_url,dpsp_ajax_pull_post_share_counts_data,function(t){})}),t(document).ready(function(){t("#dpsp-floating-sidebar").css("top",(window.innerHeight-t("#dpsp-floating-sidebar").height())/2)}),t(window).on("resize",function(){t("#dpsp-floating-sidebar").css("top",(window.innerHeight-t("#dpsp-floating-sidebar").height())/2)}),t(document).on("mouseenter",".dpsp-networks-btns-wrapper li a",function(e){t(this).closest("li").addClass("dpsp-hover")}),t(document).on("mouseleave",".dpsp-networks-btns-wrapper li a",function(){t(this).closest("li").removeClass("dpsp-hover")}),t(document).ready(function(){t(".dpsp-network-btn.dpsp-pinterest").click(function(e){if("#"!=t(this).attr("href"))return!1;e.preventDefault();var n=document.createElement("script");n.setAttribute("type","text/javascript"),n.setAttribute("charset","UTF-8"),n.setAttribute("src","https://assets.pinterest.com/js/pinmarklet.js"),document.body.appendChild(n)})}),t(document).ready(function(){t(".dpsp-network-btn.dpsp-print").click(function(t){window.print()})}),t(document).on("click",".dpsp-network-btn",function(e){if(!(t(this).hasClass("dpsp-twitter")&&void 0!==window.twttr||t(this).hasClass("dpsp-email"))){if(e.preventDefault(),"#"==t(this).attr("href"))return!1;t(this).blur(),window.open(t(this).attr("href"),"targetWindow","toolbar=no,location=no,status=no,menubar=no,scrollbars=no,resizable=yes,width=700,height=300,top=200,left="+(t(window).innerWidth()-700)/2)}})});
assets/dist/front-end.1.0.0.js ADDED
@@ -0,0 +1 @@
 
1
+ function t(){var t=document.querySelectorAll(".dpsp-networks-btns-wrapper li a"),e=!0,n=!1,r=void 0;try{for(var o,a=t[Symbol.iterator]();!(e=(o=a.next()).done);e=!0){var i=o.value;i.addEventListener("mouseenter",function(t){t.target.parentNode.classList.add("dpsp-hover")}),i.addEventListener("mouseleave",function(t){t.target.parentNode.classList.remove("dpsp-hover")})}}catch(s){n=!0,r=s}finally{try{e||null==a.return||a.return()}finally{if(n)throw r}}}function e(){var t=document.querySelectorAll(".dpsp-network-btn.dpsp-pinterest");Array.prototype.forEach.call(t,function(t){t.addEventListener("click",function(t){var e=t.target;if(!/#$/.test(e.href))return t.stopPropagation(),void t.preventDefault();t.preventDefault();var n=document.createElement("script");n.setAttribute("type","text/javascript"),n.setAttribute("charset","UTF-8"),n.setAttribute("src","https://assets.pinterest.com/js/pinmarklet.js"),document.body.appendChild(n)})})}function n(){var t=document.querySelectorAll(".dpsp-network-btn.dpsp-print");Array.prototype.forEach.call(t,function(t){t.addEventListener("click",function(){window.print()})})}function r(){var t=document.querySelectorAll(".dpsp-network-btn");Array.prototype.forEach.call(t,function(t){t.addEventListener("click",function(t){var e=t.target;e.classList.contains("dpsp-email")||(t.preventDefault(),/#$/.test(e.href)?t.stopPropagation():(e.blur(),window.open(e.href,"targetWindow","toolbar=no,location=no,status=no,menubar=no,scrollbars=no,resizable=yes,width=700,height=300,top=200,left=".concat((window.innerWidth-700)/2))))})})}var o=function o(){t(),e(),n(),r(),window.removeEventListener("mousemove",o)};window.addEventListener("mousemove",o);
assets/dist/jquery.ui.touch-punch.min.1.0.0.js ADDED
@@ -0,0 +1 @@
 
1
+ !function(o){function t(o,t){if(!(o.originalEvent.touches.length>1)){o.preventDefault();var e=o.originalEvent.changedTouches[0],u=document.createEvent("MouseEvents");u.initMouseEvent(t,!0,!0,window,1,e.screenX,e.screenY,e.clientX,e.clientY,!1,!1,!1,!1,0,null),o.target.dispatchEvent(u)}}if(o.support.touch="ontouchend"in document,o.support.touch){var e,u=o.ui.mouse.prototype,n=u._mouseInit,c=u._mouseDestroy;u._touchStart=function(o){!e&&this._mouseCapture(o.originalEvent.changedTouches[0])&&(e=!0,this._touchMoved=!1,t(o,"mouseover"),t(o,"mousemove"),t(o,"mousedown"))},u._touchMove=function(o){e&&(this._touchMoved=!0,t(o,"mousemove"))},u._touchEnd=function(o){e&&(t(o,"mouseup"),t(o,"mouseout"),this._touchMoved||t(o,"click"),e=!1)},u._mouseInit=function(){var t=this;t.element.bind({touchstart:o.proxy(t,"_touchStart"),touchmove:o.proxy(t,"_touchMove"),touchend:o.proxy(t,"_touchEnd")}),n.call(t)},u._mouseDestroy=function(){var t=this;t.element.unbind({touchstart:o.proxy(t,"_touchStart"),touchmove:o.proxy(t,"_touchMove"),touchend:o.proxy(t,"_touchEnd")}),c.call(t)}}}(jQuery);
assets/dist/socialpug.1.0.0.eot ADDED
Binary file
assets/dist/socialpug.1.0.0.svg ADDED
@@ -0,0 +1,70 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0" standalone="no"?>
2
+ <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
3
+ <svg xmlns="http://www.w3.org/2000/svg">
4
+ <metadata>Copyright (C) 2017 by original authors @ fontello.com</metadata>
5
+ <defs>
6
+ <font id="socialpug" horiz-adv-x="1000" >
7
+ <font-face font-family="socialpug" font-weight="400" font-stretch="normal" units-per-em="1000" ascent="850" descent="-150" />
8
+ <missing-glyph horiz-adv-x="1000" />
9
+ <glyph glyph-name="facebook" unicode="&#xe800;" d="M535 843v-147h-87q-48 0-65-20t-17-60v-106h164l-22-165h-142v-424h-171v424h-142v165h142v122q0 104 58 161t155 57q82 0 127-7z" horiz-adv-x="571.4" />
10
+
11
+ <glyph glyph-name="twitter" unicode="&#xe801;" d="M904 622q-37-54-90-93 0-8 0-23 0-73-21-145t-64-139-103-117-144-82-181-30q-151 0-276 81 19-2 43-2 126 0 224 77-59 1-105 36t-64 89q19-3 34-3 24 0 48 6-63 13-104 62t-41 115v2q38-21 82-23-37 25-59 64t-22 86q0 49 25 91 68-83 164-133t208-55q-5 21-5 41 0 75 53 127t127 53q79 0 132-57 61 12 115 44-21-64-80-100 52 6 104 28z" horiz-adv-x="928.6" />
12
+
13
+ <glyph glyph-name="gplus" unicode="&#xe802;" d="M318 403v-109h181c-8-47-55-137-181-137-108 0-197 90-197 201s89 201 197 201c62 0 103-27 127-49l86 83c-55 52-127 83-213 83-176 0-318-142-318-318s142-318 318-318c184 0 306 129 306 311 0 20-3 37-5 52h-301z m682 10h-94v93h-93v-93h-94v-94h94v-94h93v94h94z" horiz-adv-x="1000" />
14
+
15
+ <glyph glyph-name="pinterest" unicode="&#xe803;" d="M0 517q0 60 21 113t58 93 85 69 103 44 113 14q88 0 164-37t123-108 47-160q0-54-10-105t-34-99-56-83-80-58-106-21q-38 0-75 18t-54 49q-5-22-15-63t-14-53-11-40-15-39-17-35-26-44-35-48l-7-3-5 6q-9 88-9 105 0 51 12 115t37 161 29 113q-18 36-18 94 0 47 29 87t74 41q34 0 53-23t19-57q0-37-24-106t-25-105q0-35 25-58t61-23q31 0 57 14t44 38 31 53 21 61 11 62 4 56q0 96-61 150t-160 54q-111 0-186-72t-75-183q0-25 7-48t15-36 15-26 7-17q0-15-8-40t-21-25q-1 0-9 1-29 9-51 31t-34 53-18 60-6 60z" horiz-adv-x="714.3" />
16
+
17
+ <glyph glyph-name="linkedin" unicode="&#xe804;" d="M195 501v-553h-184v553h184z m12 171q0-41-29-68t-75-27h-1q-46 0-74 27t-28 68q0 41 29 68t75 27 74-27 29-68z m650-407v-317h-183v296q0 59-23 92t-71 33q-35 0-58-19t-36-48q-6-17-6-45v-309h-184q1 223 1 361t0 165l-1 27h184v-80h-1q11 18 23 31t31 29 49 24 64 9q95 0 153-63t58-186z" horiz-adv-x="857.1" />
18
+
19
+ <glyph glyph-name="stumbleupon" unicode="&#xe805;" d="M593 453v66q0 23-17 40t-40 16-40-16-17-40v-342q0-98-70-167t-170-69q-99 0-169 70t-70 169v149h183v-146q0-24 17-41t40-16 40 16 17 41v346q0 95 71 163t168 67q98 0 168-68t71-164v-76l-109-32z m295-124h183v-149q0-99-70-169t-169-70q-99 0-169 69t-70 168v150l73-34 109 32v-151q0-23 16-40t41-16 40 16 16 40v154z" horiz-adv-x="1071.4" />
20
+
21
+ <glyph glyph-name="reddit" unicode="&#xe806;" d="M0 362q0 23 9 44t24 37 36 25 46 9q43 0 74-29 59 37 135 59t162 25l80 228 196-47q9 26 33 42t53 17q39 0 67-27t28-67-28-66-66-27-67 27-28 66l-164 39-67-185q84-4 157-27t129-57q33 29 76 29 23 0 45-9t37-25 24-37 9-44q0-31-15-57t-40-41q4-17 4-35 0-60-35-116t-97-97-143-64-176-24q-92 0-174 24t-143 64-97 97-35 116q0 10 2 20 0 9 2 17-24 16-38 40t-15 56z m86-133q0-55 32-102t88-84 132-57 161-21 160 21 132 57 89 84 32 102-32 104-89 85-132 56-160 21-161-21-132-56-88-85-32-104z m199 54q0 28 22 50t50 21 50-21 21-50-21-49-50-21-50 21-22 49z m53-165q12 10 33-8 6-6 13-10t14-7 13-5 14-3 13-3 14-3 14-2 15-1 17-1q76 4 133 35 21 20 35 8 10-18-12-35-58-45-156-45-105 2-152 45-26 19-8 35z m242 166q0 29 21 50t50 20 51-20 21-50-21-50-51-21-50 21-21 50z" horiz-adv-x="1000" />
22
+
23
+ <glyph glyph-name="vkontakte" unicode="&#xe807;" d="M1070 560q13-36-84-164-13-18-36-48-22-28-31-40t-17-27-7-24 8-19 18-24 32-30q2-1 2-2 79-73 107-123 2-3 4-7t4-15-1-19-14-15-33-7l-142-3q-14-2-32 3t-29 13l-11 6q-17 12-39 36t-38 43-34 33-32 8q-1 0-4-2t-10-8-12-16-9-29-4-44q0-8-2-15t-4-10l-2-3q-10-11-30-12h-64q-40-3-81 9t-74 29-57 37-40 32l-14 14q-5 5-15 17t-40 50-59 85-68 117-73 152q-4 9-4 15t2 9l2 3q9 11 32 11l153 1q7-1 13-3t9-5l3-2q9-6 13-18 11-28 26-57t23-46l9-16q16-34 31-58t27-38 23-22 19-8 15 3q1 1 3 3t7 12 7 26 5 46 0 69q-1 23-5 41t-7 26l-4 6q-14 19-47 24-8 2 3 14 8 10 21 17 29 14 133 13 46-1 75-7 12-3 19-8t12-13 5-18 2-25 0-31-2-40 0-46q0-6-1-23t0-27 2-22 6-22 13-14q4-1 9-2t15 6 21 19 29 38 38 60q33 58 60 125 2 6 5 10t6 6l3 2 2 1t8 2 11 0l160 1q22 3 36-1t17-10z" horiz-adv-x="1071.4" />
24
+
25
+ <glyph glyph-name="whatsapp" unicode="&#xe808;" d="M550 307q7 0 54-25t50-30q1-2 1-8 0-18-9-42-9-22-40-37t-57-15q-32 0-106 35-55 25-95 66t-82 103q-41 60-40 108v5q2 50 41 88 14 12 29 12 4 0 10-1t11-1q11 0 15-3t8-16q5-11 19-49t14-41q0-12-19-33t-20-26q0-3 3-8 19-41 57-76 31-30 84-57 7-4 13-4 8 0 30 27t29 28z m-114-296q71 0 136 28t112 74 75 112 28 136-28 136-75 112-112 75-136 28-135-28-112-75-75-112-28-136q0-113 67-205l-44-130 135 43q88-58 192-58z m0 771q86 0 164-34t134-89 90-135 33-163-33-163-90-134-134-90-164-34q-108 0-203 53l-233-75 76 226q-60 99-60 217 0 86 33 163t90 135 134 89 163 34z" horiz-adv-x="857.1" />
26
+
27
+ <glyph glyph-name="instagram" unicode="&#xe809;" d="M571 350q0 59-41 101t-101 42-101-42-42-101 42-101 101-42 101 42 41 101z m77 0q0-91-64-156t-155-64-156 64-64 156 64 156 156 64 155-64 64-156z m61 229q0-21-15-36t-37-15-36 15-15 36 15 36 36 15 37-15 15-36z m-280 123q-4 0-43 0t-59 0-54-2-57-5-40-11q-28-11-49-32t-33-49q-6-16-10-40t-6-58-1-53 0-59 0-43 0-43 0-59 1-53 6-58 10-40q12-28 33-49t49-32q16-6 40-11t57-5 54-2 59 0 43 0 42 0 59 0 54 2 58 5 39 11q28 11 50 32t32 49q6 16 10 40t6 58 1 53 0 59 0 43 0 43 0 59-1 53-6 58-10 40q-11 28-32 49t-50 32q-16 6-39 11t-58 5-54 2-59 0-42 0z m428-352q0-128-3-177-5-116-69-180t-179-69q-50-3-177-3t-177 3q-116 6-180 69t-69 180q-3 49-3 177t3 177q5 116 69 180t180 69q49 3 177 3t177-3q116-6 179-69t69-180q3-49 3-177z" horiz-adv-x="857.1" />
28
+
29
+ <glyph glyph-name="youtube" unicode="&#xe810;" d="M397 221l270 139-270 141v-280z m103 481q94 0 181-3t128-5l41-2q0 0 9-1t13-2 13-2 16-5 16-7 17-11 16-15q4-3 9-10t16-33 15-56q4-36 7-76t3-64v-98q1-81-10-162-4-30-14-55t-18-35l-8-9q-7-8-16-15t-17-10-16-7-16-5-13-2-13-2-9-1q-140-11-350-11-115 2-201 4t-111 4l-28 3-20 2q-20 3-30 5t-29 12-31 23q-4 3-9 10t-16 33-15 56q-4 36-7 76t-3 64v98q-1 81 10 162 4 31 14 55t18 35l8 9q8 9 16 15t17 11 16 7 16 5 13 2 13 2 9 1q140 10 350 10z" horiz-adv-x="1000" />
30
+
31
+ <glyph glyph-name="vimeo" unicode="&#xe811;" d="M896 558q-32-186-171-351t-245-237q-42-28-81-17t-66 38-43 61q-16 32-78 239t-74 223q-16 12-38 5t-44-21l-20-14-36 50q18 20 46 52t100 89 124 67q30 6 53-7t36-35 23-60 15-70 12-75 13-67q14-54 21-80t17-54 18-39 18-11q40 0 126 166 42 76 6 124t-112 2q22 126 140 188 104 54 182 8 80-46 58-174z" horiz-adv-x="901" />
32
+
33
+ <glyph glyph-name="soundcloud" unicode="&#xe812;" d="M0 221q0 16 4 44t9 31q6-3 11-32t4-43q0-14-4-42t-11-32q-13 7-13 74z m64 0q0 25 5 74t6 61q0 6 6 6 4 0 6-6 12-129 12-135 0-24-5-71t-7-59q-2-7-6-7-6 0-6 7-1 11-6 59t-5 71z m81 0q0 24 5 74t5 54q0 9 7 9 8 0 8-9 11-113 11-128t-11-136q0-8-8-8-7 0-7 8 0 7-5 59t-5 77z m92 0q0 38 2 81t4 95 3 81q0 10 9 10 10 0 10-10 1-16 6-111t4-146q0-26-5-77t-5-58q0-10-10-10-9 0-9 10-9 132-9 135z m94 0q0 55 3 160t4 128q2 12 12 12t12-12q1-32 5-133t3-155q0-25-3-72t-5-61q-2-12-12-12t-12 12q0 11-3 59t-4 74z m95 0q0 40 1 85t3 100 2 85q2 15 14 15t14-15q1-30 3-85t2-100 1-85q0-2-6-131l0 1q-2-15-14-15t-14 14q-6 129-6 131z m95-1q0 3 6 351 2 18 16 18t16-18q6-348 6-351 0-1-6-127-2-17-16-17t-16 17q-6 126-6 127z m80 213q0 82 1 155-1 10 13 18t32 12 35 5 24 2q97 0 169-72t80-179q28 13 55 13 58 0 100-45t42-111-42-110-100-46l-393 0q-6 0-10 6t-5 13q0 55 0 156t-1 183z" horiz-adv-x="1152" />
34
+
35
+ <glyph glyph-name="twitch" unicode="&#xe813;" d="M500 608v-242h-81v242h81z m222 0v-242h-81v242h81z m0-424l141 141v444h-666v-585h182v-121l121 121h222z m222 666v-565l-242-242h-182l-121-122h-121v122h-222v646l61 161h827z" horiz-adv-x="1000" />
36
+
37
+ <glyph glyph-name="behance" unicode="&#xe814;" d="M1031 661h-285v-69h285v69z m-140-238q-51 0-82-29t-34-80h227q-10 109-111 109z m9-326q35 0 68 18t42 48h123q-55-171-238-171-119 0-190 73t-70 194q0 116 72 193t188 77q77 0 134-38t86-100 28-139q0-9-1-26h-367q0-62 32-96t93-33z m-745 28h165q114 0 114 93 0 100-111 100h-168v-193z m0 299h156q44 0 69 21t26 63q0 80-106 80h-145v-164z m-155 284h332q48 0 86-8t71-26 50-54 17-86q0-101-96-147 64-17 96-64t33-114q0-41-14-76t-37-58-55-39-67-24-75-7h-341v703z" horiz-adv-x="1142.9" />
38
+
39
+ <glyph glyph-name="yummly" unicode="&#xe815;" d="M143 846c-1-1-5-2-10-2-18-3-38-9-43-12-2-2-4-2-5-1-1 1-1 0-1-2 0-2-1-2-2-2-3 3-47-21-59-32-5-5-10-9-10-8 0 1-3-3-6-9-5-8-6-13-6-21 1-7 3-14 5-16 1-2 2-3 1-3-3 0 2-9 12-24 5-7 10-13 12-13 1 0 3-1 2-2-1-4 12-13 18-13 4 0 10 4 17 10 5 6 11 10 11 10 1 0 6 3 12 7 22 15 50 19 58 9 2-2 5-4 6-3 2 1 2 1 1-1-1-2-1-6 0-9 1-3 1-11 0-18-1-6-3-15-3-18-1-4-3-12-5-17-1-6-3-12-3-14-1-1-3-9-5-17-3-8-5-18-6-22-1-4-2-8-2-9-2-2-4-11-5-21-1-2-2-5-2-8-2-5-8-26-9-31 0-2-1-6-2-8-2-4-7-25-8-31-1-2-5-18-9-34-5-16-9-32-9-34-1-3-3-9-4-14-2-6-2-11-2-12 1-1 1-3-1-3-3-1-7-30-6-51 0-17 10-53 14-53 1 0 3-2 4-5 2-7 20-24 32-31 30-17 86-19 141-7 23 5 59 17 60 20 0 1 2 2 3 1 2-2 34 14 41 20 2 1 4 2 5 1 1 0-1-13-4-27-3-15-5-28-5-29 0-2-1-7-5-21 0-3-3-5-5-5-18 0-84-16-84-19 0-2-1-2-3-1-2 1-37-12-40-16-1-1-2-2-2 0 0 2-21-9-24-12 0-1-2-3-3-3-5 0-22-11-21-13 1-2 1-2-1-1-5 3-58-52-53-57 1-1 0-1-2-1-4 0-26-46-30-66-1-3-4-31-5-38-1-17 4-42 12-60 27-57 95-84 170-68 16 4 49 16 53 20 2 2 5 4 5 3 2-1 6 0 10 4 3 3 8 7 11 9 6 4 23 20 34 32 10 11 24 32 23 34-1 1-1 2 1 2 2 0 11 16 11 19 0 1 1 3 2 4 6 4 26 59 34 94 5 20 10 37 11 39 2 5 12 5 62-1 31-4 36-4 42-5 4-1 17-3 30-6 35-5 31-5 90-17 23-4 43-8 46-9 2 0 6-1 9-2 2-1 7-2 11-2 6-1 26-5 28-6 1 0 5-1 8-2 7-2 76-16 86-19 4 0 16-3 27-5 25-5 35-7 43-8 3 0 6-1 6-1 0-1 2-2 3-2 4 0 24-3 32-5 22-4 67-11 79-13 9-1 16-2 17-3 1 0 10-1 21-2 10-1 21-2 24-3 22-4 161-7 187-3 7 1 19 2 28 3 9 1 17 4 18 5 1 1 2 1 3 1 8-5 113 31 113 38 0 1 1 2 2 2 3-1 18 7 32 17 16 12 24 28 24 47 0 17-9 39-21 55-9 13-19 23-19 20 0-1-1 0-3 1-2 2-11-1-33-12-17-8-35-16-40-18-5-2-13-5-17-7-10-5-73-21-88-23-6-1-14-2-17-3-4 0-14-1-24-2-9-2-21-3-26-3-14-2-122-2-141 0-9 0-24 2-33 3-13 1-24 2-52 5-4 0-12 1-18 2-36 5-56 8-61 8-4 1-7 1-7 1 0 1-5 2-22 4-7 1-15 2-18 3-4 1-14 3-24 4-9 2-20 4-23 4-4 1-10 2-13 2-8 2-64 12-74 14-6 1-23 4-32 5-3 0-5 1-5 1 0 1-7 2-21 4-6 0-13 2-16 2-3 1-10 2-17 3-6 1-14 3-17 3-3 1-10 2-16 2-5 1-12 2-15 2-3 1-13 3-21 4-9 1-18 2-21 2-3 1-12 2-20 3-7 1-17 2-22 2-15 2-49 5-55 5-5-1-5 0-2 16 2 9 4 21 5 28 4 24 8 50 10 60 1 3 3 11 3 15 1 5 3 16 4 23 2 7 3 17 4 22 0 4 2 10 2 13 1 2 2 9 3 16 1 6 2 13 3 15 0 2 1 8 2 13 1 5 2 12 3 16 1 6 4 22 5 33 1 4 2 11 5 26 1 3 2 10 3 17 1 6 2 14 3 17 1 7 3 17 5 28 1 4 3 18 5 29 2 12 4 25 5 30 1 5 3 18 5 28 3 10 5 24 5 30 1 7 2 13 3 15 1 1 2 7 3 14 0 6 2 13 2 15 1 2 2 9 3 15 0 6 1 12 2 13 3 4 5 36 3 48-1 7-4 15-6 17-3 3-5 6-4 7 1 0-4 4-10 7-21 11-68 9-91-4-8-5-9-6-8-16 2-26 1-54-3-78-3-14-5-28-6-30 0-2-1-9-2-14-1-6-3-13-3-16-1-3-2-8-2-12-1-3-2-10-3-15-1-5-4-25-8-43-3-19-7-39-7-44-1-5-3-15-5-23-1-8-3-17-4-21 0-4-1-11-2-16-1-5-5-24-8-43-4-19-6-36-6-37 0-3-24-17-41-23-6-2-12-5-12-7 0-2 0-2-1-1-1 1-11-2-23-6-51-17-94-19-109-4-6 6-6 8-6 29 0 23 1 28 31 139 2 8 3 16 2 16 0 1 1 3 2 3 1 1 3 5 4 9 0 4 1 8 1 8 1 0 2 4 4 15 3 15 3 16 4 17 0 0 1 1 1 2 0 1 2 7 4 14 2 6 4 14 4 17 0 3 1 7 2 9 15 42 15 100 0 133-11 25-38 44-69 50-13 2-53 3-55 1z m199-745c-1-6-4-13-5-17-1-4-2-8-2-9 0-2 0-3-11-30-4-9-7-18-6-18 1-1 0-2-2-2-2 0-7-10-6-14 0-1 0-1-1-1-2 1-5-2-7-7-6-9-19-22-26-24-2-1-4-2-4-3 0-3-2-3-22-4-17-1-23 2-30 16-5 7-4 31 1 44 2 5 4 11 4 13 0 2 1 3 2 2 2-1 3 1 4 4 2 6 26 29 31 29 1 0 1 1 0 2-1 2 0 3 1 3 3-2 22 8 25 12 1 1 2 1 2 0 0-1 2 0 5 1 5 3 40 13 46 13 2 0 2-3 1-10z m872 563c-5-1-12-2-16-3-9-2-45-15-47-18-1-2-2-2-2-1 0 1-5-1-11-3-10-6-18-7-17-4 0 4-4 11-8 11-2 0-3 1-3 2 0 5-19 11-41 12-15 2-64-12-60-16 1 0 0-3-1-4-2-3-2-7 0-14 3-13 3-39 0-51-2-5-3-13-4-20-1-7-1-12-1-12-1 0-2-5-4-18-1-5-2-12-3-15-1-4-2-10-2-15-1-5-2-12-3-16-2-7-14-78-16-88-1-8-3-18-6-37-2-8-4-19-4-24-1-4-2-12-3-15-9-50 1-74 33-81 15-4 54-1 59 3 1 1 4 2 7 2 2 0 4 1 4 3 0 1 1 2 2 2 11-2 14 7 10 25-4 17-3 28 3 58 2 13 5 27 5 31 1 4 2 11 3 14 3 17 4 20 5 28 1 4 2 11 2 15 1 5 2 12 3 16 7 36 9 49 8 51-1 1-1 3 1 4 1 0 2 4 2 8 0 4 2 15 4 23l3 16 18 8c20 10 31 13 45 10 17-3 22-22 16-57-1-6-3-13-3-16-1-3-2-8-2-12-1-3-2-10-3-15-1-5-3-19-5-32-2-12-5-26-5-32-1-5-2-10-3-12-1-1-2-7-3-15 0-7-2-15-3-19-7-36-9-66-5-80 4-10 19-25 23-24 2 1 6 0 10-2 8-5 43-3 62 3 18 5 25 12 23 21-1 4-3 10-3 14-1 4-2 8-2 9-1 2 1 16 4 32 2 16 5 33 6 38 1 5 3 14 4 22 3 14 5 28 6 36 1 3 3 17 5 30 3 14 5 28 6 31 0 4 2 11 2 16 1 5 4 17 5 27l3 18 17 9c24 12 42 15 52 9 5-3 10-9 11-13 3-8 1-34-4-62-2-9-3-14-9-52-7-41-8-46-10-56 0-5-1-11-2-13 0-2-2-8-2-12-1-5-3-13-3-17-7-38-7-55 0-70 4-7 9-11 18-16 12-6 16-6 38-6 19 0 28 1 40 6 19 7 21 11 17 29-3 16-1 44 6 77 1 7 3 18 4 23 1 6 3 19 5 29 2 9 3 18 3 19 0 1 0 2 1 3 1 3 2 9 3 21 1 7 3 14 3 16 1 2 2 8 3 13 0 5 2 12 2 14 1 4 2 10 3 15 1 5 2 11 2 14 7 34 10 71 6 89-3 16-4 18-8 26-13 25-35 37-76 39-19 1-77-14-77-20 0-2 0-2-1-1-1 1-12-4-23-10l-22-11-5 7c-7 13-19 23-34 28-15 6-47 9-61 5z m-541-3c0-1-7-2-15-2-17-2-37-7-37-11 0-1-1-1-2-1-1 1-4 0-7-3-4-5-4-6 1-26 2-7 1-27-2-43-2-9-4-19-4-24 0-4-2-13-4-20-1-7-3-17-4-22-2-17-3-22-5-27 0-2-2-10-2-17-1-7-2-13-3-14 0-1-2-7-3-15-1-7-2-15-2-17-1-2-2-8-3-13-3-17-4-25-5-32-5-28-3-69 3-82 2-3 4-8 6-12 5-11 22-28 33-32 29-12 52-13 87-4 7 2 13 4 14 4 2 0 5 2 8 3 22 9 46 17 47 16 0 0 2-4 4-8 9-19 28-27 59-27 20 1 48 8 51 13 1 1 3 2 4 3 1 0 2 5 2 12-3 39-3 46-1 55 1 5 3 13 4 18 2 18 4 30 5 35 1 3 2 9 3 14 1 5 2 12 3 15 0 3 1 9 2 14 1 5 3 18 5 28 2 9 4 18 3 19-1 1 0 3 1 5 1 3 3 10 4 16 1 7 2 15 3 19 1 6 10 56 13 71 0 5 2 11 2 15 4 14 2 41-3 51-4 9-23 24-26 21-1-1-3 0-5 1-3 3-34 4-45 1-14-3-33-10-37-13-3-3-3-6-1-17 3-14 3-41 0-57-1-5-4-18-6-29-2-10-3-20-3-20 0-1 0-3 0-4-1-2-3-11-4-18-1-6-4-22-6-32-1-3-2-10-2-15-1-5-2-10-2-12-1-1-2-8-3-15-2-7-3-14-3-15 0 0-2-10-4-22-3-18-4-20-11-23-4-2-7-4-6-4 1-1-1-2-3-2-3 0-10-2-16-5-27-10-58-2-60 16 0 3-1 7-1 9 0 5 5 46 6 46 0 0 1 2 1 5 0 3 1 9 2 13 1 4 3 12 3 16 4 22 6 36 8 45 1 4 2 12 3 17 1 6 4 25 8 42 9 51 5 76-13 87-5 2-9 5-11 5-16 3-27 5-28 5z" horiz-adv-x="1538" />
40
+
41
+ <glyph glyph-name="mail" unicode="&#xe816;" d="M580 306l258-267-789 0 259 264 135-127z m-517 355l760 0-380-362z m566-309l257 242 0-508z m-629-266l0 508 259-243z" horiz-adv-x="886" />
42
+
43
+ <glyph glyph-name="print" unicode="&#xe817;" d="M866 564c40 0 75-35 75-78l0-366c0-42-35-77-75-77l-76 0 34-153-691 0 27 153-82 0c-45 0-78 35-78 77l0 366c0 43 33 78 78 78l96 0 0 117 34 0 0 129 527 0 0-129 34 0 0-117 97 0z m-623 199l0-292 457 0 0 292-457 0z m-113-389c30 0 55 24 55 54 0 28-25 53-55 53-29 0-54-25-54-53 0-30 25-54 54-54z m63-438l567 0-47 242-484 0z m252 113l-139 0 0 35 139 0 0-35z m198 0l-139 0 0 35 139 0 0-35z" horiz-adv-x="941" />
44
+
45
+ <glyph glyph-name="website" unicode="&#xe818;" d="M294 116q14 14 34 14t36-14q32-34 0-70l-42-40q-56-56-132-56-78 0-134 56t-56 132q0 78 56 134l148 148q70 68 144 77t128-43q16-16 16-36t-16-36q-36-32-70 0-50 48-132-34l-148-146q-26-26-26-64t26-62q26-26 63-26t63 26z m450 574q56-56 56-132 0-78-56-134l-158-158q-74-72-150-72-62 0-112 50-14 14-14 34t14 36q14 14 35 14t35-14q50-48 122 24l158 156q28 28 28 64 0 38-28 62-24 26-56 31t-60-21l-50-50q-16-14-36-14t-34 14q-34 34 0 70l50 50q54 54 127 51t129-61z" horiz-adv-x="800" />
46
+
47
+ <glyph glyph-name="pocket" unicode="&#xe819;" d="M2 520q-7 215 12 270 4 9 9 16t14 12 14 10 17 10 17 8q136 0 386 2t329 2l94 0t55 0 56-3 45-6 33-10q16-9 27-24t16-29 8-40 2-42-1-50 0-50q0-207-23-327t-96-213q-70-88-165-140t-193-62-200 11-186 73-151 134-96 181q-15 52-23 267z m232 2q-26-28 15-89t104-124q2-2 39-40t54-52 47-35 57-29q11-3 22-3t20 1 19 7 16 7 16 12 12 10 12 11l3 3q9 9 60 56t86 81 68 79 35 75q-15 40-38 56t-51 9-56-26-59-48-56-56-49-51-37-33q-27 16-73 60t-82 82-73 64-55 14q-25-15-56-41z" horiz-adv-x="1136" />
48
+
49
+ <glyph glyph-name="buffer" unicode="&#xe820;" d="M0 88q11 15 32 26t49 20 40 15q19 0 34-4t33-15 25-13q47-21 260-119 19-4 36 0t39 18 24 14q20 9 77 35t87 39q4 2 42 21t60 24q13 2 28-1t23-7 23-13 18-11 16-6 18-8 11-11q3-4 4-14-10-13-31-24t-51-22-40-16q-43-20-128-62t-129-61q-7-3-21-12t-23-13-26-11-27-7-30 2l-264 123q-6 3-32 14t-51 22-54 24-46 24-22 16q-4 4-4 13z m0 268q11 15 32 25t50 20 41 15q19 0 34-4t35-15 25-14q42-19 127-58t127-59q19-5 37 0t39 17 25 14q68 32 160 72 11 5 32 17t38 19 36 11q16 3 32-1t37-17 23-13q5-3 16-6t18-8 11-11q3-5 4-14-10-14-31-25t-53-23-41-16q-48-23-135-65t-123-59q-7-3-26-14t-29-15-32-10-36 0q-214 101-260 122-6 3-44 19t-69 30-62 30-34 22q-4 4-4 14z m0 267q10 15 32 27t52 22 41 16l348 162q30 0 54-7t56-26 40-22q39-18 117-54t117-55q4-2 37-15t54-24 27-20q3-4 4-13-9-13-26-22t-43-19-35-14q-47-22-140-66t-139-67q-6-3-20-11t-23-12-25-11-27-6-28 1q-245 114-256 119-4 2-63 28t-102 46-48 30q-4 4-4 13z" horiz-adv-x="979" />
50
+
51
+ <glyph glyph-name="tumblr" unicode="&#xe821;" d="M527 108l44-132q-12-19-61-37t-99-18q-58-1-107 15t-79 41-53 59-31 67-9 66v304h-94v120q40 14 72 39t51 50 32 57 19 55 8 49q1 3 3 5t4 2h136v-237h186v-140h-186v-289q0-17 3-31t13-30 28-23 45-8q44 1 75 16z" horiz-adv-x="571.4" />
52
+
53
+ <glyph glyph-name="github" unicode="&#xe822;" d="M0 351q0 102 40 194 79 186 265 265 92 40 194 40t194-40q184-78 265-265 40-95 40-194t-40-194q-81-188-265-267-92-40-194-40t-194 40q-186 80-265 267-40 92-40 194z m78 0q0-141 84-252 83-109 217-155l0 80q0 60 40 87-20 1-47 7-51 9-87 32-91 55-91 199 0 75 50 128-23 59 5 128l20 0q10 0 25-5 39-12 87-44 61 16 120 16t121-16q39 26 73 40 32 12 46 10l12-1q27-69 5-128 50-53 50-128 0-112-55-169-30-32-79-50-41-15-91-19 41-29 41-87l0-80q129 46 213 157 82 110 82 250 0 85-33 164-32 76-90 134-56 56-134 89-80 34-163 34-82 0-164-34-75-32-134-89-56-58-90-134-33-79-33-164z" horiz-adv-x="998" />
54
+
55
+ <glyph glyph-name="xing" unicode="&#xe823;" d="M0 152l219 0 173 286-130 229-219 0 130-229z m362 90l346 608 232 0-345-608 222-392-232 0z" horiz-adv-x="940" />
56
+
57
+ <glyph glyph-name="flipboard" unicode="&#xe824;" d="M0 850h321v-1000h-321v1000z m354-354h325v-325h-325v325z m0 354h646v-321h-646v321z" horiz-adv-x="1000" />
58
+
59
+ <glyph glyph-name="telegram" unicode="&#xe825;" d="M381-3c-28 0-23 11-33 38l-84 276 646 384m-529-698c22 0 32 10 44 22l118 114-147 89m0 0l355-263c41-22 70-11 80 38l145 681c15 59-23 86-61 69l-849-328c-58-23-58-55-11-70l218-68 504 318c24 15 46 7 28-9" horiz-adv-x="1000" />
60
+
61
+ <glyph glyph-name="ok" unicode="&#xe880;" d="M933 534q0-22-16-38l-404-404-76-76q-16-15-38-15t-38 15l-76 76-202 202q-15 16-15 38t15 38l76 76q16 16 38 16t38-16l164-165 366 367q16 16 38 16t38-16l76-76q16-15 16-38z" horiz-adv-x="1000" />
62
+
63
+ <glyph glyph-name="cancel" unicode="&#xe881;" d="M724 112q0-22-15-38l-76-76q-16-15-38-15t-38 15l-164 165-164-165q-16-15-38-15t-38 15l-76 76q-16 16-16 38t16 38l164 164-164 164q-16 16-16 38t16 38l76 76q16 16 38 16t38-16l164-164 164 164q16 16 38 16t38-16l76-76q15-15 15-38t-15-38l-164-164 164-164q15-15 15-38z" horiz-adv-x="785.7" />
64
+
65
+ <glyph glyph-name="pencil" unicode="&#xe882;" d="M938 605q22-22 22-55t-22-55l-570-570q-22-21-60-38t-73-17l-235 0 0 234q0 35 17 74t38 60l570 570q23 22 55 22t55-22z m-794-426l65-64 431 433-64 63z m91-205q14 0 33 8-10 10-27 26t-50 50-56 56l-22 22q-9-21-9-32l0-78 52-52 79 0z m74 40l432 432-63 64-433-431z m469 469l67 67-165 165-67-66z" horiz-adv-x="960" />
66
+
67
+ <glyph glyph-name="share" unicode="&#xe883;" d="M650 200q62 0 106-43t44-107q0-62-44-106t-106-44-106 44-44 106q0 6 1 14t1 12l-260 156q-42-32-92-32-62 0-106 44t-44 106 44 106 106 44q54 0 92-30l260 156q0 4-1 12t-1 12q0 62 44 106t106 44 106-43 44-107q0-62-44-106t-106-44q-52 0-90 32l-262-156q2-8 2-26 0-16-2-24l262-156q36 30 90 30z" horiz-adv-x="800" />
68
+ </font>
69
+ </defs>
70
+ </svg>
assets/dist/socialpug.1.0.0.ttf ADDED
Binary file
assets/dist/socialpug.1.0.0.woff ADDED
Binary file
assets/dist/style-dashboard.1.0.0.css ADDED
@@ -0,0 +1 @@
 
1
+ @import url(https://fonts.googleapis.com/css?family=Raleway:300,400,700,800);@font-face{font-family:Social Pug;src:url(./socialpug.1.0.0.eot?gd6mr8);src:url(./socialpug.1.0.0.eot?#iefix) format("embedded-opentype"),url(./socialpug.1.0.0.woff) format("woff"),url(./socialpug.1.0.0.ttf) format("truetype"),url(./socialpug.1.0.0.svg#socialpug) format("svg");font-weight:400;font-style:normal}[class*=" dpsp-icon-"]:before,[class^=dpsp-icon-]:before{font-family:Social Pug;font-style:normal;font-weight:400;display:inline-block;text-decoration:inherit;text-align:center;font-variant:normal;text-transform:none;line-height:1em}.dpsp-icon-ok:before{content:"\e880"}.dpsp-icon-remove:before{content:"\e881"}.dpsp-icon-edit:before{content:"\e882"}.dpsp-icon-facebook:before{content:"\e800"}.dpsp-icon-twitter:before{content:"\e801"}.dpsp-icon-google-plus:before{content:"\e802"}.dpsp-icon-pinterest:before{content:"\e803"}.dpsp-icon-linkedin:before{content:"\e804"}.dpsp-icon-email:before{content:"\e816"}.dpsp-icon-print:before{content:"\e817"}.dpsp-transition{-moz-transition:all .15s ease-in;-webkit-transition:all .15s ease-in;-o-transition:all .15s ease-in;transition:all .15s ease-in}[class*=dpsp-col-]{float:left;padding:5px;-moz-box-sizing:border-box;box-sizing:border-box}.dpsp-row{margin:0 -5px}.dpsp-row.dpsp-m-padding{margin:0 -8px}.dpsp-row.dpsp-m-padding [class*=dpsp-col-]{padding:8px}.dpsp-row.dpsp-big-padding{margin:0 -15px}.dpsp-row.dpsp-big-padding [class*=dpsp-col-]{padding:15px}.dpsp-col-1-1{width:100%}.dpsp-col-1-2{width:50%}.dpsp-col-1-3{width:33.3333%}.dpsp-col-2-3{width:66.6666%}.dpsp-col-1-4{width:25%}.dpsp-col-3-4{width:75%}.dpsp-col-1-5{width:20%}.dpsp-col-2-5{width:40%}.dpsp-col-3-5{width:60%}.dpsp-col-4-5{width:80%}.dpsp-col-3-8{width:37.5%}.dpsp-row:after{content:"";display:block;clear:both}.dpsp-page-wrapper{float:left;position:relative;width:100%;max-width:675px}.dpsp-page-wrapper hr{border:0;border-bottom:1px solid #e1e1e1}h1.dpsp-page-title{padding-right:0;padding-bottom:15px}.dpsp-section{margin-bottom:50px}.dpsp-section:after{content:"";display:block;clear:both}.dpsp-section-title{margin:2.75em 0 1.3em;padding-bottom:15px;border-bottom:1px solid #e5e5e5}.dpsp-section-title .add-new-h2,.dpsp-section-title .add-new-h2:focus{float:right;padding:3px 6px;top:-1px;margin-left:15px;box-shadow:none}.dpsp-social-platforms .add-new-h2{display:inline-block}.dpsp-social-platforms .add-new-h2,.dpsp-social-platforms .add-new-h2:active{padding:8px 16px;top:0;margin-left:0}.dpsp-background-color-network-facebook{background:#3a579a}.dpsp-background-color-network-twitter{background:#00abf0}.dpsp-background-color-network-google-plus{background:#df4a32}.dpsp-background-color-network-pinterest{background:#c92228}.dpsp-background-color-network-linkedin{background:#0077b5}.dpsp-background-color-network-email{background:#27ae60}.dpsp-background-color-network-print{background:#bdc3c7}.dpsp-page-header{background:#41a4a9;margin-left:-20px;line-height:60px;color:#fff}.dpsp-page-header .dpsp-logo{padding:0 10px 0 20px}.dpsp-page-header .dpsp-logo-inner{font-family:Raleway;font-weight:700;font-size:22px}.dpsp-page-header .dpsp-logo-inner span{font-weight:300}.mv-grow-logo{max-width:50px;display:inline-block;vertical-align:top;padding-right:.5rem;padding-top:.25rem}.dpsp-page-header:after{content:"";display:block;clear:both}.dpsp-page-header nav{display:inline-block;margin-left:25px;line-height:62px}.dpsp-page-header nav a{display:inline-block;color:#fff;background:hsla(0,0%,100%,.2);text-decoration:none;font-size:.9em;line-height:1;padding:8px 12px;border-radius:3px;font-weight:700;margin:0 5px;box-shadow:0 0 2px 2px rgba(52,152,219,.15)}.dpsp-page-header nav a .dashicons{font-size:14px;height:auto;width:auto;margin-right:5px;margin-top:-2px}.dpsp-page-header nav a:hover{background:hsla(0,0%,100%,.3)}#dpsp-to-premium{display:inline-block;line-height:18px;padding:14px 26px;color:#fff;background:#e74c3c;text-decoration:none;font-size:13px;border-radius:3px;font-weight:700}#dpsp-to-premium .dashicons{font-size:18px;height:auto;width:auto;margin-right:8px}#dpsp-to-premium:hover{background:#ea6153}.dpsp-card{margin-bottom:2em;margin-top:1.5em;background:#fff;box-shadow:0 3px 10px -2px rgba(94,135,161,.3);max-width:675px;border-radius:3px;box-sizing:border-box}.dpsp-card-header{position:relative;padding:20px;border-bottom:1px solid rgba(200,215,225,.5);font-size:14px;font-weight:700}.dpsp-card-inner{padding:20px}.dpsp-card-inner:after{content:"";display:block;clear:both}.dpsp-card-footer{position:relative;padding:20px;border-top:1px solid rgba(200,215,225,.5);background:rgba(200,215,225,.15)}.dpsp-card-footer-actions{text-align:right}.dpsp-card-footer-actions:after{content:"";display:block;clear:both}.dpsp-card-footer-actions a{float:left;color:#777;line-height:34px;outline:0;box-shadow:none}.dpsp-card-footer-actions a:hover{color:#444}.dpsp-button-primary{display:inline-block;border:none;background:#41a4a9;color:#fff!important;cursor:pointer;margin:0;outline:0;overflow:hidden;font-size:13px;font-weight:500;text-overflow:ellipsis;text-decoration:none;vertical-align:middle;box-sizing:border-box;line-height:21px;border-radius:3em;padding:.5em 2em;-webkit-appearance:none;-moz-appearance:none;appearance:none;box-shadow:none!important}.dpsp-button-primary:hover{color:#fff;background-color:#243c4a}.dpsp-button-primary:focus{color:#fff}.dpsp-button-primary.dpsp-active,.dpsp-button-primary:active{border-width:2px 1px 1px}.dpsp-button-primary.dpsp-hidden{display:none}.dpsp-button-secondary{display:inline-block;background:#fff;border:solid #c8d7e1;border-width:1px 1px 2px;color:#2e4453;cursor:pointer;margin:0;outline:0;overflow:hidden;font-size:13px;font-weight:500;text-overflow:ellipsis;text-decoration:none;vertical-align:middle;box-sizing:border-box;line-height:21px;border-radius:4px;padding:5px 11px;-webkit-appearance:none;-moz-appearance:none;appearance:none;box-shadow:none!important}.dpsp-button-secondary:hover{color:#2e4453;border-color:#a8bece}.dpsp-button-secondary:focus{color:#2e4453}.dpsp-button-secondary.dpsp-active,.dpsp-button-secondary:active{border-width:2px 1px 1px}.dpsp-button-secondary.dpsp-hidden{display:none}.dpsp-button-secondary.disabled,.dpsp-button-secondary[disabled]{color:#e9eff3;background:#fff;border-color:#e9eff3;cursor:default}#dpsp-select-networks{position:absolute;top:50%;margin-top:-17px;right:10px}#dpsp-sortable-networks-empty{display:none;position:relative;text-align:center;color:#848484}#dpsp-sortable-networks-empty:after{content:"";display:block;width:130px;height:70px;position:absolute;top:-17px;right:80px;background:url(./dpsp-selectable-empty.1.0.0.png) no-repeat 50%;background-size:100%;opacity:0;transition:all .15s ease-in}#dpsp-sortable-networks-empty.dpsp-active{display:block}#dpsp-sortable-networks-empty.dpsp-active:after{opacity:1}.dpsp-social-platforms-sort-list{margin-top:0;margin-bottom:0}.dpsp-social-platforms-sort-list li{position:relative;margin:0;overflow:hidden;background:#fff;border-bottom:1px solid #f1f1f1;padding-top:5px;padding-bottom:5px;box-sizing:border-box}.dpsp-social-platforms-sort-list li.dpsp-last{border-bottom:0;border-bottom-right-radius:3px;border-bottom-left-radius:3px}.dpsp-social-platforms-sort-list li.ui-sortable-helper{box-shadow:0 3px 12px 3px rgba(0,0,0,.1)}.dpsp-social-platforms-sort-list.empty li{background:none;border:2px dashed #c1c1c1;padding:20px}.dpsp-social-platforms-sort-list li:after{content:"";display:block;clear:both;height:0}.dpsp-social-platforms-sort-list li:last-of-type{margin-bottom:0}.dpsp-social-platforms-sort-list li.dpsp-sort-placeholder{background:#f9f9f9;height:55px;box-shadow:inset 0 3px 12px 3px rgba(0,0,0,.02);border-radius:0}.dpsp-social-platforms-sort-list li .dpsp-sort-handle{float:left;display:block;width:44px;height:44px;cursor:move}.dpsp-social-platforms-sort-list li .dpsp-sort-handle:before{content:"";position:absolute;left:12px;top:23px;width:20px;height:1px;background:#c1c1c1;box-shadow:0 .25em 0 0 #c1c1c1,0 .5em 0 0 #c1c1c1}.dpsp-social-platforms-sort-list li .dpsp-list-icon{float:left;display:block;width:44px;height:44px;line-height:44px;text-align:center;font-size:1.1em}.dpsp-social-platforms-sort-list li .dpsp-list-icon-social{color:#fff}.dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper{position:relative;float:left;padding:8px}.dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper input{border:0;line-height:28px;width:250px;border-radius:3px;margin:0;outline:0;padding:0 7px;font-weight:700;font-size:1em;color:#444;box-shadow:none;transition:background-color .1s ease-in-out}.dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper input:placeholder-shown{font-weight:400;font-style:italic}.dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper:hover input,.dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper input:focus{background:#f5f5f5}.dpsp-page-sticky-bar .dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper input{cursor:default;background-color:transparent!important}.dpsp-social-platforms-sort-list li .dpsp-list-actions{float:right;margin-right:6px}.dpsp-social-platforms-sort-list li .dpsp-list-actions a{position:relative;display:inline-block;color:#747474;text-decoration:none;line-height:28px;vertical-align:middle;margin:8px 2px 8px 0;padding:0 6px 0 3px;border-radius:3px;box-shadow:none;transition:background-color .1s ease-in-out,color .1s ease-in-out}.dpsp-social-platforms-sort-list li .dpsp-list-actions a .dashicons{position:relative;top:-1px;vertical-align:text-top;line-height:18px;height:18px;width:18px;font-size:18px;margin-right:2px}.dpsp-social-platforms-sort-list li .dpsp-list-actions a:hover{background:#f4f4f4;color:#353535}#dpsp-networks-selector-wrapper,.dpsp-page-sticky-bar .dpsp-social-platforms-sort-list li .dpsp-list-actions .dpsp-list-edit-label{display:none}#dpsp-networks-selector{padding:20px;margin:0}#dpsp-networks-selector li{position:relative;float:left;width:33.3333%;margin-bottom:1em;padding:0 10px;box-sizing:border-box}#dpsp-networks-selector:after{content:"";display:block;clear:both;height:0}#dpsp-networks-selector .dpsp-network-item{position:relative;overflow:hidden;padding-left:35px;box-sizing:border-box;cursor:pointer}#dpsp-networks-selector .dpsp-network-item-checkbox{position:absolute;top:0;left:0;width:26px;height:26px;line-height:26px;font-size:16px;vertical-align:middle;text-align:center;color:#555;background:#fff;border:2px solid #c8d7e1;border-radius:15px;-webkit-box-shadow:0 1px 1px -1px rgba(0,0,0,.1);box-shadow:0 1px 1px -1px rgba(0,0,0,.1)}#dpsp-networks-selector .dpsp-network-item-checkbox:before{position:relative;opacity:0;transition:all .15s ease-in}#dpsp-networks-selector .dpsp-network-item:hover .dpsp-network-item-checkbox:before{opacity:.15}#dpsp-networks-selector .dpsp-network-item[data-checked=true] .dpsp-network-item-checkbox:before,#dpsp-networks-selector .dpsp-network-item[data-checked=true]:hover .dpsp-network-item-checkbox:before{opacity:1}#dpsp-networks-selector .dpsp-network-item-name-wrapper{height:30px;line-height:30px;color:#fff;vertical-align:middle;padding-left:10px;border-radius:3px;-webkit-box-shadow:0 1px 1px -1px rgba(0,0,0,.1);box-shadow:0 1px 1px -1px rgba(0,0,0,.1)}#dpsp-networks-selector .dpsp-network-item-name-wrapper .dpsp-list-icon{display:inline-block;margin-right:12px;margin-left:5px}#dpsp-networks-selector .dpsp-network-item-name-wrapper h4{display:inline-block;margin:0}.dpsp-setting-field-wrapper{position:relative;left:auto;margin-bottom:12px;min-height:39px;transition:opacity .4s ease-in-out}.dpsp-setting-field-wrapper.disabled{position:absolute;left:-9999px;visibility:hidden;opacity:0}.dpsp-setting-field-wrapper.dpsp-last{margin-bottom:0}.dpsp-setting-field-label{position:absolute;top:2px;left:0;display:inline-block;width:235px;vertical-align:top;padding-right:15px;box-sizing:border-box}.dpsp-setting-field-wrapper.dpsp-has-field-label{padding-left:243px}.dpsp-setting-field-wrapper.dpsp-has-field-label .dpsp-setting-field-inner{position:relative;top:-18px;margin-left:243px}.dpsp-setting-field-wrapper input[type=text]{margin:0;box-shadow:none;padding:10px 12px;border-radius:2px;border:1px solid #c8d7e1;width:100%}.dpsp-setting-field-wrapper input[type=text]:focus{border-color:#0087be;box-shadow:0 0 1px 0 #78dcfa}.dpsp-setting-field-wrapper select{min-width:200px}.dpsp-setting-field-select :focus{outline:0!important}.dpsp-setting-field-select .select2-container{width:100%!important}.dpsp-setting-field-select .select2-selection{height:39px;border-radius:2px;border:1px solid #c8d7e1}.dpsp-setting-field-select .select2-selection .select2-selection__rendered{line-height:37px!important;padding-left:10px}.dpsp-setting-field-select .select2-selection .select2-selection__arrow{height:37px;padding-right:10px}.dpsp-select2 .select2-dropdown{border-color:#c8d7e1;border-radius:0}.dpsp-select2 .select2-dropdown li{margin:0;line-height:36px;padding:0 10px}.dpsp-select2 .select2-results__option[aria-selected=true]{background:#e8eaeb}.dpsp-select2 .select2-results__option--highlighted{background:#00aadc!important}.dpsp-select2 .select2-dropdown--below{top:32px;box-shadow:0 4px 3px 2px rgba(0,0,0,.08)}.dpsp-select2 .select2-dropdown--above{box-shadow:0 -4px 3px 2px rgba(0,0,0,.08)}.dpsp-setting-field-select .select2-container--open{box-shadow:0 0 3px 2px rgba(0,0,0,.08)}.dpsp-setting-field-wrapper textarea{min-height:100px;min-width:450px;border:0;box-shadow:none;padding:5px 8px;border-radius:3px}.dpsp-setting-field-wrapper input[type=checkbox],.dpsp-setting-field-wrapper input[type=radio]{display:none}.dpsp-setting-field-checkbox.dpsp-single .dpsp-setting-field-label{padding-right:18px}.dpsp-setting-field-checkbox.dpsp-multiple .dpsp-settings-field-checkbox,.dpsp-setting-field-radio.dpsp-multiple .dpsp-settings-field-radio{display:inline-block;margin-right:12px;position:relative;padding-left:23px}.dpsp-setting-field-checkbox input[type=checkbox]+label span,.dpsp-setting-field-radio input[type=radio]+label span{content:"";display:block;position:absolute;width:16px;height:16px;background:#fff;border:1px solid #e7e7e7;border-radius:3px;transition:background .1s ease-in-out,border-color .1s ease-in-out}.dpsp-setting-field-radio input[type=radio]+label span{border-radius:50%}.dpsp-setting-field-checkbox.dpsp-single input[type=checkbox]+label span{top:0;right:0}.dpsp-setting-field-checkbox.dpsp-multiple input[type=checkbox]+label span,.dpsp-setting-field-radio.dpsp-multiple input[type=radio]+label span{top:0;left:0}.dpsp-setting-field-checkbox input[type=checkbox]+label span:before{display:inline-block;content:"\f147";font:400 20px/1 dashicons;width:16px;height:16px;line-height:16px;vertical-align:middle;margin:-5px 0 0 -3px;color:transparent;transition:color .1s ease-in-out}.dpsp-setting-field-radio input[type=radio]+label span:before{content:"";position:relative;top:5px;left:5px;display:block;width:6px;height:6px;border-radius:50%}.dpsp-setting-field-checkbox input[type=checkbox]:checked+label span{background:#41a4a9;border-color:transparent}.dpsp-setting-field-checkbox input[type=checkbox]:checked+label span:before{color:#fff}.dpsp-setting-field-radio input[type=radio]:checked+label span{background:#41a4a9;border-color:transparent}.dpsp-setting-field-radio input[type=radio]:checked+label span:before{background:#fff}.dpsp-setting-field-tooltip-wrapper{position:absolute;top:2px;left:217px;display:inline-block;width:18px;height:18px;margin-left:5px}.dpsp-setting-field-tooltip-icon:before{content:"?";display:inline-block;width:14px;height:14px;line-height:14px;font-size:10px;font-weight:700;vertical-align:middle;text-align:center;color:#fff;background:#34495e;border-radius:9px;cursor:pointer;transition:all .15s ease-in}.dpsp-setting-field-tooltip-icon:hover:before{background:#34495e}.dpsp-setting-field-tooltip{z-index:10;opacity:0;visibility:hidden;position:absolute;top:28px;left:-25px;width:220px;background:rgba(52,73,94,.975);color:#fff;border-radius:4px;padding:8px 12px}.dpsp-setting-field-tooltip a{color:#3498db}.dpsp-setting-field-tooltip:before{content:"";display:block;position:absolute;top:-6px;left:27px;width:0;height:0;border-color:transparent transparent rgba(52,73,94,.975);border-style:solid;border-width:0 4.5px 6px}.dpsp-settings-button-style{cursor:pointer;width:10%;margin-right:1.5%;margin-bottom:10px;padding:12px;border-radius:5px;border:1px solid transparent;float:left;-moz-box-sizing:border-box;box-sizing:border-box}.dpsp-setting-field-share-text input{width:350px}.dpsp-setting-field-wrapper .dpsp-switch{float:none;margin-left:0}.dpsp-setting-field-facebook-app-authorized{background:rgba(0,184,148,.3);padding:9px;border-radius:3px;color:#27ae60}.dpsp-setting-field-facebook-app-authorized-expired{background:rgba(192,57,43,.3);padding:9px;border-radius:3px;color:#c0392b;margin-bottom:10px}.dpsp-setting-field-facebook-app-id,.dpsp-setting-field-facebook-app-secret,.dpsp-setting-field-facebook-authorize-app{display:none}.dpsp-page-wrapper .dpsp-settings-button-style .dpsp-networks-btns-wrapper li{margin-bottom:6px}.dpsp-page-wrapper .dpsp-settings-button-style .dpsp-networks-btns-wrapper li:last-of-type{margin-bottom:0}.dpsp-page-sidebar .dpsp-settings-button-style .dpsp-networks-btns-wrapper .dpsp-network-btn{margin:0 auto}.dpsp-page-sidebar .dpsp-settings-button-style .dpsp-shape-rounded .dpsp-networks-btns-wrapper .dpsp-network-btn,.dpsp-page-sidebar .dpsp-settings-button-style .dpsp-shape-rounded .dpsp-networks-btns-wrapper .dpsp-network-btn:before{border-radius:5px}.dpsp-page-content .dpsp-settings-button-style{width:24.25%;margin-right:1%}.dpsp-page-content .dpsp-section-button-style label:nth-of-type(4n){margin-right:0}.dpsp-settings-button-style:hover{border-color:#e1e1e1}.dpsp-settings-button-style-input{display:none!important}.dpsp-settings-button-style-input:checked+label{border-color:rgba(52,152,219,.3);background:rgba(52,152,219,.075)}#dpsp-toolkit-welcome{padding:35px 25px;background:#fff;margin-left:-20px;text-align:center;overflow:hidden}#dpsp-toolkit-welcome h2{font-size:1.8em;margin-top:0;margin-bottom:1.6em}#dpsp-toolkit-welcome p{font-size:14px}#dpsp-toolkit-welcome .button{margin-top:1.6em;box-shadow:none;outline:0}.dpsp-tool-wrapper{background:#fff;border-radius:3px;overflow:hidden}.dpsp-tool-wrapper img{max-width:100%;height:auto}.dpsp-tool-wrapper a{color:#777;text-decoration:none}.dpsp-tool-wrapper a:hover{color:rgba(52,152,219,.75)}.dpsp-tool-wrapper h4{font-size:15px;margin-bottom:0;margin-top:0;padding:10px;text-align:center}.dpsp-tool-wrapper .dpsp-tool-actions{position:relative;padding:15px}.dpsp-tool-wrapper .dpsp-tool-actions:after{content:"";display:block;clear:both}.dpsp-tool-wrapper .dpsp-tool-actions-overlay{z-index:1;position:absolute;top:0;left:0;height:100%;width:100%;background:hsla(0,0%,100%,.6);opacity:0}.dpsp-tool-wrapper .dpsp-tool-actions-overlay .spinner{float:none;visibility:visible;opacity:1;margin:15px 0 0 15px}.dpsp-tool-wrapper .dpsp-tool-actions.dpsp-active span{opacity:0}.dpsp-tool-wrapper .dpsp-tool-actions.dpsp-inactive span{opacity:.4}.dpsp-tool-wrapper .dpsp-tool-actions .dpsp-tool-settings{line-height:1;vertical-align:middle}.dpsp-tool-wrapper .dpsp-tool-actions .dpsp-tool-settings:focus{box-shadow:none}.dpsp-tool-wrapper .dpsp-tool-actions.dpsp-inactive .dpsp-tool-settings{display:none}.dpsp-tool-wrapper .dpsp-tool-actions .dpsp-tool-settings i{margin-right:3px}.dpsp-tool-wrapper .dpsp-switch span{text-transform:uppercase;font-size:.85em;margin-right:5px}.dpsp-tool-wrapper .dpsp-switch label{display:inline-block!important}.dpsp-page-toolkit .dpsp-col-3-8{padding-top:0!important}.dpsp-page-extensions{max-width:1000px}.dpsp-page-extensions .dpsp-card{margin-top:0;margin-bottom:0}.dpsp-unavailable>a{display:block;line-height:0}.dpsp-unavailable h4{padding-bottom:0;border-bottom:0;border-top:1px solid #f1f1f1;text-align:left}.dpsp-unavailable p.dpsp-description{margin:0;padding:10px}.dpsp-unavailable .dpsp-tool-actions{padding:15px 10px;overflow:hidden;text-align:center;background:#f9f9f9;border-top:1px solid #f1f1f1}.dpsp-unavailable .dpsp-tool-actions .button{padding-left:25px;padding-right:25px}.dpsp-unavailable .dpsp-description{height:57px}.dpsp-settings-sidebar{float:left;margin-top:63px;padding-left:20px;width:365px;-moz-box-sizing:border-box;box-sizing:border-box}.dpsp-settings-sidebar p{color:#767676}@media screen and (max-width:1225px){.dpsp-settings-sidebar{border-left:0;padding-left:0}}#dpsp-settings-sidebar-social-pug-pro img{max-width:100%;height:auto;padding:0 20px;box-sizing:border-box}#dpsp-settings-sidebar-social-pug-pro h3{text-align:center;line-height:1.7em;font-weight:700}#dpsp-settings-sidebar-social-pug-pro p{position:relative;padding-left:45px;color:#454545;margin-bottom:20px}#dpsp-settings-sidebar-social-pug-pro p .dpsp-dashicons{position:absolute;top:-5px;left:0;display:inline-block;width:30px;height:30px}#dpsp-settings-sidebar-social-pug-pro p .dpsp-dashicons:after{content:"";display:block;position:absolute;z-index:1;top:-1px;left:2px;width:30px;height:30px;border-radius:20px;background:#41a4a9}#dpsp-settings-sidebar-social-pug-pro p .dashicons{position:absolute;top:0;left:0;width:30px;height:30px;font-size:24px;line-height:30px;color:#fff;z-index:2}#dpsp-settings-sidebar-social-pug-pro .dpsp-button-primary{width:100%;text-align:center;padding:10px 0;box-sizing:border-box}#dpsp-settings-sidebar-opt-in-hound img{max-width:35px;height:auto;margin-right:10px;border-radius:50px;vertical-align:middle}#dpsp-mailchimp-subscribe-wrapper h3{margin-bottom:0}#dpsp-mailchimp-subscribe-wrapper p{margin-top:5px;margin-bottom:15px}#dpsp-mailchimp-subscribe-wrapper label{display:block;margin-bottom:5px}#dpsp-mailchimp-subscribe-wrapper input[type=email],#dpsp-mailchimp-subscribe-wrapper input[type=text]{margin-bottom:10px;width:100%}.dpsp-switch{position:relative;display:inline-block;margin-left:20px;float:right}.dpsp-page-wrapper .cmn-toggle{position:absolute;margin-left:-9999px;visibility:hidden}.dpsp-page-wrapper .cmn-toggle+label{display:block;position:relative;cursor:pointer;outline:none;user-select:none}.dpsp-page-wrapper input.cmn-toggle-round+label{padding:3px;width:36px;height:18px;background-color:#c9d6e0;border-radius:20px;transition:background .4s;box-sizing:content-box}.dpsp-page-wrapper input.cmn-toggle-round+label:after,.dpsp-page-wrapper input.cmn-toggle-round+label:before{display:block;position:absolute;top:2px;left:2px;bottom:2px;content:""}.dpsp-page-wrapper input.cmn-toggle-round+label:before{right:2px;border-radius:18px;transition:background .4s}.dpsp-page-wrapper input.cmn-toggle-round+label:after{width:20px;background-color:#fff;border-radius:100%;box-shadow:0 2px 5px rgba(0,0,0,.1);transition:margin .4s}.dpsp-page-wrapper input.cmn-toggle-round:checked+label{background-color:#41a4a9}.dpsp-page-wrapper input.cmn-toggle-round:checked+label:after{margin-left:18px}.dpsp-switch.small input.cmn-toggle-round+label{width:30px;height:15px}.dpsp-switch.small input.cmn-toggle-round+label:after{width:17px}.dpsp-switch.small input.cmn-toggle-round:checked+label:after{margin-left:15px}.wrap div.dpsp-admin-notice{position:relative;margin-top:16px}.wrap div.dpsp-admin-notice h4{font-size:16px}.wrap div.dpsp-admin-notice p{font-size:14px}.dpsp-admin-notice-activation{border-color:rgba(52,152,219,.75)}.dpsp-admin-notice-activation h4{font-size:1.05em}.dpsp-admin-notice-activation a{text-decoration:none}.dpsp-admin-notice-activation .dpsp-admin-notice-link{display:inline-block;padding:6px 8px;margin-bottom:10px;color:#3498db;font-weight:500;background:#e9e9e9;border-radius:2px;margin-right:10px}.dpsp-admin-notice-activation .dpsp-admin-notice-link span{display:inline-block;text-decoration:none;margin-right:10px}.dpsp-admin-notice-activation .dpsp-admin-notice-link:hover{color:#fff;background:rgba(52,152,219,.75)}.dpsp-admin-notice-wp-rating{border-color:rgba(52,152,219,.75)}.dpsp-admin-notice-wp-rating h4{font-size:1.05em}.dpsp-admin-notice-wp-rating p:last-of-type{margin-bottom:20px}.dpsp-admin-notice-wp-rating a{text-decoration:none}.dpsp-admin-notice-wp-rating .dpsp-admin-notice-link{display:inline-block;padding:6px 8px;margin-bottom:10px;color:#3498db;font-weight:500;background:#e9e9e9;border-radius:2px;margin-right:10px}.dpsp-admin-notice-wp-rating .dpsp-admin-notice-link span{display:inline-block;text-decoration:none;margin-right:10px}.dpsp-admin-notice-wp-rating .dpsp-admin-notice-link:hover{color:#fff;background:rgba(52,152,219,.75)}.dpsp-admin-notice-wp-rating .dashicons-star-filled{position:relative;top:1px;width:15px;height:15px;font-size:15px}.dpsp-admin-notice-opt-in-hound{position:relative;padding-left:140px;border-color:rgba(52,152,219,.75)}.dpsp-admin-notice-opt-in-hound h4{font-size:1.05em}.dpsp-admin-notice-opt-in-hound p:last-of-type{margin-bottom:20px}.dpsp-admin-notice-opt-in-hound a{text-decoration:none}.dpsp-admin-notice-opt-in-hound img{position:absolute;top:20px;left:20px;border-radius:50px;max-width:100px;height:auto}.wrap div.dpsp-admin-notice.dpsp-admin-grow-notice{display:flex;flex-flow:row}@media screen and (max-width:500px){.wrap div.dpsp-admin-notice.dpsp-admin-grow-notice{flex-flow:column}}.wrap div.dpsp-admin-notice .notice-img-wrap{padding:1em;flex:0 0 150px}.wrap div.dpsp-admin-notice .notice-img-wrap img{float:left}.wrap div.dpsp-admin-notice .notice-text-wrap{flex:1 1 auto}.wrap div.dpsp-admin-notice .notice-subtext{font-style:italic;font-size:.9em}#dpsp-feedback-form-overlay{display:none;z-index:9999;position:fixed;top:0;left:0;width:100%;height:100%;background:#000;opacity:.35}#dpsp-feedback-form{display:none;z-index:10000;position:fixed;top:10%;left:50%;background:#fff;border-radius:3px;max-width:700px;margin-left:-350px;width:100%}#dpsp-feedback-form .dpsp-header{position:relative;background:rgba(52,152,219,.75);padding:27px 35px}#dpsp-feedback-form>form{padding:30px 35px}#dpsp-feedback-form h2{color:#fff;margin-top:0;margin-bottom:0}#dpsp-feedback-form label{display:block;margin-bottom:5px;font-weight:700}#dpsp-feedback-form textarea{width:100%;margin-bottom:10px;min-height:80px}#dpsp-feedback-form input[type=email],#dpsp-feedback-form input[type=text]{width:50%;margin-bottom:10px}#dpsp-feedback-form input[type=submit]{margin-top:15px}#dpsp-feedback-form .spinner{float:none;visibility:visible;margin-top:19px}#dpsp-feedback-form .dpsp-error{display:none;margin-top:20px;margin-left:15px;color:#c0392b}#dpsp-feedback-done{display:none;position:relative;padding:35px 25px}#dpsp-feedback-done img{float:left}#dpsp-feedback-done:after{content:"";display:block;clear:both}#dpsp-feedback-done>div{position:relative;float:left;top:-10px;margin-left:40px;background:#f1f1f1;border-radius:10px;padding:10px 20px;max-width:400px}#dpsp-feedback-done>div p{font-size:1.1em}#dpsp-feedback-done>div p:first-of-type{font-weight:700}#dpsp-feedback-done>div:before{left:-30px;bottom:10px;width:25px;height:25px}#dpsp-feedback-done>div:after,#dpsp-feedback-done>div:before{content:"";display:block;position:absolute;border-radius:50%;background:#f1f1f1}#dpsp-feedback-done>div:after{left:-50px;bottom:20px;width:15px;height:15px}#dpsp-feedback-done>a{position:absolute;bottom:35px;right:35px}#dpsp-close-feedback{position:absolute;right:25px;top:50%;margin-top:-10px;color:#fff;text-decoration:none}.dpsp-statistic-bars-wrapper{padding-top:10px}.dpsp-statistic-bars-wrapper:after{content:"";display:block;width:0;clear:both}.dpsp-statistic-bar-header{opacity:.6;margin-bottom:10px;padding-bottom:5px;border-bottom:1px solid #f1f1f1}.dpsp-statistic-bar-wrapper.dpsp-statistic-bar-header:hover{background:none}.dpsp-statistic-bar-wrapper{position:relative;height:30px;padding-left:110px;padding-right:110px;transition:opacity .2s ease-in-out}.dpsp-statistic-bar-wrapper:hover{background:#f7f7f7}.dpsp-statistic-bar-wrapper label{position:absolute;left:10px;top:0;height:30px;width:109px;line-height:30px;font-weight:700;font-size:12px}.dpsp-statistic-bar-wrapper .dpsp-network-share-count{position:absolute;top:0;right:0;height:30px;width:110px;line-height:30px;font-weight:700;font-size:12px}.dpsp-statistic-bar-wrapper .dpsp-network-share-count .dpsp-count{display:inline-block;width:55px;text-align:center}.dpsp-statistic-bar-wrapper .dpsp-network-share-count .dpsp-percentage{display:inline-block;width:40px;text-align:center}.dpsp-statistic-bar-wrapper .dpsp-network-share-count .dpsp-divider{width:1px;margin:0 2px;opacity:.5}.dpsp-statistic-bar-wrapper .dpsp-statistic-bar{position:relative;top:10px;height:10px;width:100%;background:#e7e7e7;border-radius:5px}.dpsp-statistic-bar-wrapper .dpsp-statistic-bar-inner{height:10px;width:0;border-radius:5px}.dpsp-statistic-bar-wrapper .dpsp-statistic-bar-facebook .dpsp-statistic-bar-inner{background:#3a579a}.dpsp-statistic-bar-wrapper .dpsp-statistic-bar-twitter .dpsp-statistic-bar-inner{background:#00abf0}.dpsp-statistic-bar-wrapper .dpsp-statistic-bar-google-plus .dpsp-statistic-bar-inner{background:#df4a32}.dpsp-statistic-bar-wrapper .dpsp-statistic-bar-pinterest .dpsp-statistic-bar-inner{background:#c92228}.dpsp-statistic-bar-wrapper .dpsp-statistic-bar-linkedin .dpsp-statistic-bar-inner{background:#0077b5}.dpsp-statistic-bar-wrapper .dpsp-statistic-bar-stumbleupon .dpsp-statistic-bar-inner{background:#ec4b24}.dpsp-statistic-bar-wrapper .dpsp-statistic-bar-reddit .dpsp-statistic-bar-inner{background:#ff5700}.dpsp-statistic-bar-wrapper .dpsp-statistic-bar-vkontakte .dpsp-statistic-bar-inner{background:#4d75a3}.dpsp-statistic-bar-footer{opacity:.6;margin:10px 0;border-top:1px solid #f1f1f1;border-bottom:1px solid #f1f1f1}.dpsp-statistic-bar-wrapper.dpsp-statistic-bar-footer:hover{background:none}#dpsp-refresh-share-counts-wrapper:after{content:"";display:block;width:0;clear:both}#dpsp-refresh-share-counts{float:right}#opt-in-hound-promo-box{background:#fff;max-width:800px;margin:35px auto;border-radius:4px;overflow:hidden;box-shadow:0 0 20px 4px #e9e9e9}#opt-in-hound-promo-box img{max-width:100%;height:auto}#opt-in-hound-promo-box hr{margin:50px 0}#opt-in-hound-promo-box-banner{position:relative}#opt-in-hound-promo-box-inner{padding:0 50px}#opt-in-hound-promo-box .opt-in-hound-promo-box-title{font-size:28px;font-weight:700;margin:15px 0}#opt-in-hound-promo-box .opt-in-hound-promo-box-title span{font-weight:300;font-size:22px}#opt-in-hound-promo-box .opt-in-hound-promo-box-sub-title{font-size:20px;font-weight:300;line-height:1.3}#opt-in-hound-promo-box .opt-in-hound-promo-box-sub-title,#opt-in-hound-promo-box .opt-in-hound-promo-box-title{text-align:center;color:#4d5b68}#opt-in-hound-promo-box .dpsp-row{margin-bottom:35px}#opt-in-hound-promo-box .dpsp-row .opt-in-hound-promo-box-sub-title{margin-top:0}#opt-in-hound-promo-box .dpsp-col-1-3{text-align:center}#opt-in-hound-promo-box .dpsp-col-1-4{border-right:1px solid #f1f1f1}#opt-in-hound-promo-box .dpsp-col-1-4.dpsp-last{border-right:0}#opt-in-hound-promo-box .dpsp-col-1-4 img{margin:-20px 0}#opt-in-hound-promo-box .opt-in-hound-promo-box-cta{text-align:center;margin:35px 0}#opt-in-hound-promo-box .opt-in-hound-promo-box-cta.dpsp-last{margin:35px 0 50px}#opt-in-hound-promo-box .opt-in-hound-promo-box-cta .button-primary{font-size:120%;font-weight:500;height:38px;line-height:34px;padding:0 25px}#opt-in-hound-promo-box-disclaimer{max-width:800px;margin:0 auto;font-size:12px;color:#a1a1a1}.dpsp-page-extensions.dpsp-sub-page-opt-in-hound div.notice{display:none}#dpsp-deactivate-modal{display:none;z-index:9999;position:fixed;top:0;left:0;width:100%;height:100%;background:rgba(0,0,0,.35)}#dpsp-deactivate-wrapper{z-index:10000;position:fixed;top:10%;left:50%;background:#fff;border-radius:4px;max-width:700px;margin-left:-350px;width:100%;overflow:hidden}#dpsp-deactivate-wrapper p{margin-top:0;margin-bottom:10px}#dpsp-deactivate-wrapper hr{margin:25px 0;border:0;border-top:1px solid #e1e1e1}#dpsp-deactivate-wrapper textarea{min-height:65px;width:100%}#dpsp-deactivate-wrapper .dpsp-deactivate-close{line-height:26px;margin-left:10px}#dpsp-deactivate-contact-me{display:none}#dpsp-deactivate-contact-me label{display:block;margin-bottom:10px}#dpsp-deactivate-contact-me input[type=email]{display:block;min-width:250px;width:50%}#dpsp-deactivate-header{position:relative;padding:25px 20px 22px;background:#f5f5f5;border-bottom:1px solid #e1e1e1;overflow:hidden}#dpsp-deactivate-header img{position:absolute;right:15px;top:auto;bottom:-29px;max-width:80px}#dpsp-deactivate-header h3{margin:0}#dpsp-deactivate-inner{padding:20px 20px 25px}#dpsp-deactivate-footer{padding:20px;background:#f5f5f5;border-top:1px solid #e1e1e1}#dpsp-deactivate-footer a:last-of-type{float:right}.browser-window{border:1px solid rgba(52,152,219,.75);border-radius:5px;line-height:0;overflow:hidden}.browser-header{text-align:left;border-bottom:1px solid rgba(52,152,219,.75);height:20px}.browser-header:before{display:block;content:"○ ○ ○";position:relative;top:10px;left:7px;font-size:20px;color:rgba(52,152,219,.75)}@media screen and (max-width:785px){.dpsp-page-title-wrapper h2{position:relative;padding-right:50px}.dpsp-page-title-wrapper h2 .dpsp-switch{position:absolute;top:15px;right:0}.dpsp-social-platforms-sort-list{overflow:auto}}@media screen and (max-width:720px){.dpsp-col-1-4{width:50%}#dpsp-networks-selector li{width:100%;padding:0}#dpsp-networks-selector-footer{text-align:center}.dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper{width:auto}.dpsp-page-sidebar .dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper:hover input,.dpsp-page-sidebar .dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper input:focus,.dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper input{width:150px;padding-right:10px}.dpsp-settings-button-style{width:auto}.dpsp-page-content .dpsp-settings-button-style{width:49.5%}.dpsp-page-content .dpsp-section-button-style label:nth-of-type(4n){margin-right:1%}.dpsp-page-content .dpsp-section-button-style label:nth-of-type(2n){margin-right:0}.dpsp-setting-field-label{width:100%;margin-bottom:10px}.dpsp-setting-field-wrapper{margin-bottom:30px}}
assets/dist/style-frontend-jquery.1.0.0.css ADDED
@@ -0,0 +1 @@
 
1
+ @font-face{font-family:Social Pug;src:url(./socialpug.1.0.0.eot?gd6mr8);src:url(./socialpug.1.0.0.eot?#iefix) format("embedded-opentype"),url(./socialpug.1.0.0.woff) format("woff"),url(./socialpug.1.0.0.ttf) format("truetype"),url(./socialpug.1.0.0.svg#socialpug) format("svg");font-weight:400;font-style:normal}.dpsp-icon-total-share:before{line-height:20px;display:inline-block;line-height:1em}.dpsp-icon-total-share:before,.dpsp-network-btn .dpsp-network-icon:after,.dpsp-network-btn .dpsp-network-icon:before{position:absolute;top:50%;left:50%;margin-top:-10px;margin-left:-10px;width:20px;height:20px;vertical-align:middle;font-family:Social Pug;font-style:normal;font-weight:400;text-decoration:inherit;text-align:center;font-variant:normal;text-transform:none}.dpsp-network-btn .dpsp-network-icon:after,.dpsp-network-btn .dpsp-network-icon:before{display:block;line-height:20px}.dpsp-network-btn .dpsp-network-icon:after{margin-left:-20px;opacity:0}.dpsp-icon-total-share:before{content:"\e883"}.dpsp-facebook .dpsp-network-icon:after,.dpsp-facebook .dpsp-network-icon:before{content:"\e800"}.dpsp-twitter .dpsp-network-icon:after,.dpsp-twitter .dpsp-network-icon:before{content:"\e801"}.dpsp-pinterest .dpsp-network-icon:after,.dpsp-pinterest .dpsp-network-icon:before{content:"\e803"}.dpsp-linkedin .dpsp-network-icon:after,.dpsp-linkedin .dpsp-network-icon:before{content:"\e804"}.dpsp-email .dpsp-network-icon:after,.dpsp-email .dpsp-network-icon:before{content:"\e816"}.dpsp-print .dpsp-network-icon:after,.dpsp-print .dpsp-network-icon:before{content:"\e817"}.dpsp-networks-btns-wrapper.dpsp-has-button-icon-animation .dpsp-network-btn:hover .dpsp-network-icon:after,.dpsp-networks-btns-wrapper.dpsp-has-button-icon-animation .dpsp-network-btn:hover .dpsp-network-icon:before{transition:all .25s ease-in-out}.dpsp-networks-btns-wrapper.dpsp-has-button-icon-animation .dpsp-network-btn:hover .dpsp-network-icon:before{margin-left:5px;opacity:0}.dpsp-networks-btns-wrapper.dpsp-has-button-icon-animation .dpsp-network-btn:hover .dpsp-network-icon:after{margin-left:-10px;opacity:1}#dpsp-floating-sidebar{position:fixed;top:30%;z-index:9998}#dpsp-floating-sidebar.dpsp-position-left{left:0}#dpsp-floating-sidebar.dpsp-position-right{right:0}.dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar li{float:none;margin-left:0}.dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn{padding:0;width:40px}.dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon{border-color:transparent!important;background:transparent!important}.dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-has-count .dpsp-network-icon{height:22px;line-height:22px}.dpsp-button-hover .dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn:hover:before{color:#fff}.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn,.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon{border-radius:0}.dpsp-position-left.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-first,.dpsp-position-left.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-first .dpsp-network-icon{-webkit-border-top-right-radius:5px;-moz-border-radius-topright:5px;border-top-right-radius:5px}.dpsp-position-left.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-last,.dpsp-position-left.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-last .dpsp-network-icon{-webkit-border-bottom-right-radius:5px;-moz-border-radius-bottomright:5px;border-bottom-right-radius:5px}.dpsp-position-left.dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn,.dpsp-position-left.dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon{-webkit-border-top-right-radius:5px;-moz-border-radius-topright:5px;border-top-right-radius:5px;-webkit-border-bottom-right-radius:5px;-moz-border-radius-bottomright:5px;border-bottom-right-radius:5px}.dpsp-position-right.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-first,.dpsp-position-right.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-first .dpsp-network-icon{-webkit-border-top-left-radius:5px;-moz-border-radius-topleft:5px;border-top-left-radius:5px}.dpsp-position-right.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-last,.dpsp-position-right.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-last .dpsp-network-icon{-webkit-border-bottom-left-radius:5px;-moz-border-radius-bottomleft:5px;border-bottom-left-radius:5px}.dpsp-position-right.dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn,.dpsp-position-right.dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon{-webkit-border-top-left-radius:5px;-moz-border-radius-topleft:5px;border-top-left-radius:5px;-webkit-border-bottom-left-radius:5px;-moz-border-radius-bottomleft:5px;border-bottom-left-radius:5px}.dpsp-shape-rounded.dpsp-has-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon{border-radius:5px}#dpsp-floating-sidebar.dpsp-position-left.dpsp-shape-circle{left:12px}#dpsp-floating-sidebar.dpsp-position-right.dpsp-shape-circle{right:10px}.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn{margin-bottom:6px}.dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn{-webkit-border-top-right-radius:5px;-moz-border-radius-topright:5px;border-top-right-radius:5px;-webkit-border-bottom-right-radius:5px;-moz-border-radius-bottomright:5px;border-bottom-right-radius:5px}#dpsp-floating-sidebar.dpsp-style-2 .dpsp-network-btn:before{background:none}#dpsp-floating-sidebar .dpsp-networks-btns-wrapper li{position:relative;overflow:visible}#dpsp-floating-sidebar .dpsp-networks-btns-wrapper .dpsp-button-label{position:absolute;z-index:1;display:inline-block;width:auto;white-space:nowrap;top:50%;margin-top:-15px;height:30px;padding:6px 12px;color:#fff;font-size:12px;font-weight:400;line-height:18px;background:#34495e;border-radius:3px;visibility:hidden;opacity:0;transition:all .2s ease-in-out;box-sizing:border-box}#dpsp-floating-sidebar.dpsp-position-left .dpsp-networks-btns-wrapper .dpsp-button-label{left:100%}#dpsp-floating-sidebar.dpsp-position-right .dpsp-networks-btns-wrapper .dpsp-button-label{right:100%}#dpsp-floating-sidebar.dpsp-position-left .dpsp-networks-btns-wrapper li.dpsp-hover .dpsp-button-label{transform:translateX(10px);visibility:visible;opacity:1}#dpsp-floating-sidebar.dpsp-position-right .dpsp-networks-btns-wrapper li.dpsp-hover .dpsp-button-label{transform:translateX(-10px);visibility:visible;opacity:1}#dpsp-floating-sidebar .dpsp-networks-btns-wrapper .dpsp-button-label:before{content:"";display:block;position:absolute;top:50%;margin-top:-5px;border-top:5px solid transparent;border-bottom:5px solid transparent}#dpsp-floating-sidebar.dpsp-position-left .dpsp-networks-btns-wrapper .dpsp-button-label:before{left:-5px;border-right:5px solid #34495e}#dpsp-floating-sidebar.dpsp-position-right .dpsp-networks-btns-wrapper .dpsp-button-label:before{right:-5px;border-left:5px solid #34495e}#dpsp-content-top{margin-bottom:1.2em}#dpsp-content-bottom{margin-top:1.2em}.dpsp-share-text{font-weight:700;margin-bottom:10px}.dpsp-networks-btns-wrapper{list-style:none!important;padding:0!important;margin:0!important}.dpsp-networks-btns-wrapper:after{content:"";display:block;height:0;clear:both}.dpsp-networks-btns-wrapper li{float:left;overflow:hidden;-moz-transition:all .15s ease-in;-webkit-transition:all .15s ease-in;-o-transition:all .15s ease-in;transition:all .15s ease-in;list-style-type:none!important}.dpsp-networks-btns-wrapper li:before{display:none!important}.dpsp-networks-btns-wrapper li:first-child{margin-left:0!important}.dpsp-networks-btns-wrapper .dpsp-network-btn{position:relative;display:block;text-decoration:none!important;text-transform:unset!important;height:40px;min-width:40px;font-family:Arial;font-weight:700;font-size:14px;line-height:36px;vertical-align:middle;padding:0 10px 0 48px;border:2px solid;max-height:40px;width:100%;-moz-box-sizing:border-box;box-sizing:border-box;-moz-transition:all .15s ease-in;-webkit-transition:all .15s ease-in;-o-transition:all .15s ease-in;transition:all .15s ease-in;box-shadow:none;cursor:pointer}.dpsp-networks-btns-wrapper .dpsp-network-btn:focus,.dpsp-networks-btns-wrapper .dpsp-network-btn:hover{border:2px solid;box-shadow:none}.dpsp-networks-btns-wrapper .dpsp-network-btn:after{content:"";display:block;height:0;clear:both}.dpsp-networks-btns-wrapper .dpsp-network-btn .dpsp-network-icon{position:absolute;top:-2px;left:-2px;bottom:-2px;float:left;display:block;font-size:14px;line-height:36px;width:40px;text-align:center;vertical-align:middle;border:2px solid;-moz-box-sizing:border-box;box-sizing:border-box;-moz-transition:all .15s ease-in;-webkit-transition:all .15s ease-in;-o-transition:all .15s ease-in;transition:all .15s ease-in}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-no-label{padding:0 18px}.dpsp-button-style-1 .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-no-label .dpsp-network-icon{width:auto;right:-2px}.dpsp-has-buttons-count .dpsp-networks-btns-wrapper .dpsp-network-label{margin-right:10px}.dpsp-networks-btns-wrapper .dpsp-network-btn .dpsp-network-count{font-size:13px}.dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-count{position:absolute;bottom:0;left:0;width:100%;margin-left:0;font-size:11px;text-align:center;height:20px;line-height:20px}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-no-label .dpsp-network-label-wrapper{display:none}.dpsp-column-1 .dpsp-networks-btns-wrapper li{width:100%}.dpsp-column-1.dpsp-has-spacing .dpsp-networks-btns-wrapper li{margin-right:0}.dpsp-column-2 .dpsp-networks-btns-wrapper li{width:50%}.dpsp-column-2.dpsp-has-spacing .dpsp-networks-btns-wrapper li{width:49%}.dpsp-column-2 .dpsp-networks-btns-wrapper li:nth-child(2n){margin-right:0}.dpsp-column-3 .dpsp-networks-btns-wrapper li{width:33.3333%}.dpsp-column-3.dpsp-has-spacing .dpsp-networks-btns-wrapper li{width:32%}.dpsp-column-3 .dpsp-networks-btns-wrapper li:nth-child(3n){margin-right:0}.dpsp-column-4 .dpsp-networks-btns-wrapper li{width:25%}.dpsp-column-4.dpsp-has-spacing .dpsp-networks-btns-wrapper li{width:23.5%}.dpsp-column-4 .dpsp-networks-btns-wrapper li:nth-child(4n){margin-right:0}.dpsp-column-5 .dpsp-networks-btns-wrapper li{width:20%}.dpsp-column-5.dpsp-has-spacing .dpsp-networks-btns-wrapper li{width:18.4%}.dpsp-column-5 .dpsp-networks-btns-wrapper li:nth-child(5n){margin-right:0}.dpsp-column-6 .dpsp-networks-btns-wrapper li{width:16.6666%}.dpsp-column-6.dpsp-has-spacing .dpsp-networks-btns-wrapper li{width:15%}.dpsp-column-6 .dpsp-networks-btns-wrapper li:nth-child(6n){margin-right:0}.dpsp-column-2 .dpsp-networks-btns-wrapper .dpsp-network-btn,.dpsp-column-3 .dpsp-networks-btns-wrapper .dpsp-network-btn,.dpsp-column-4 .dpsp-networks-btns-wrapper .dpsp-network-btn,.dpsp-column-5 .dpsp-networks-btns-wrapper .dpsp-network-btn,.dpsp-column-6 .dpsp-networks-btns-wrapper .dpsp-network-btn{padding-right:10px}.article .dpsp-networks-btns-wrapper{display:flex;flex-wrap:wrap;justify-content:center}.article ul.dpsp-networks-btns-wrapper li{flex:0 0 auto;float:none;margin:5px;width:auto}.dpsp-no-labels .dpsp-networks-btns-wrapper .dpsp-network-btn{padding:0;text-align:center}.dpsp-no-labels:not(.dpsp-column-auto) .dpsp-networks-btns-wrapper .dpsp-network-btn:before{position:relative;left:0;float:none;display:inline-block}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-facebook,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-facebook .dpsp-network-icon{border-color:#3a579a;background:#3a579a;color:#3a579a}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-facebook:hover,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-facebook:hover .dpsp-network-icon{border-color:#334d87;background:#334d87;color:#334d87}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-twitter,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-twitter .dpsp-network-icon{border-color:#00abf0;background:#00abf0;color:#00abf0}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-twitter:hover,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-twitter:hover .dpsp-network-icon{border-color:#0099d7;background:#0099d7;color:#0099d7}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-pinterest,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-pinterest .dpsp-network-icon{border-color:#c92228;background:#c92228;color:#c92228}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-pinterest:hover,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-pinterest:hover .dpsp-network-icon{border-color:#b31e24;background:#b31e24;color:#b31e24}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-linkedin,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-linkedin .dpsp-network-icon{border-color:#0077b5;background:#0077b5;color:#0077b5}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-linkedin:hover,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-linkedin:hover .dpsp-network-icon{border-color:#00669c;background:#00669c;color:#00669c}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-email,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-email .dpsp-network-icon{border-color:#27ae60;background:#27ae60;color:#27ae60}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-email:hover,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-email:hover .dpsp-network-icon{border-color:#239e57;background:#239e57;color:#239e57}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-print,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-print .dpsp-network-icon{border-color:#bdc3c7;background:#bdc3c7;color:#bdc3c7}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-print:hover,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-print:hover .dpsp-network-icon{border-color:#afb6bb;background:#afb6bb;color:#afb6bb}.dpsp-has-button-background .dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn:before{color:#fff}.dpsp-shape-rounded .dpsp-network-btn,.dpsp-shape-rounded .dpsp-network-btn .dpsp-network-icon{-webkit-border-top-left-radius:5px;-webkit-border-bottom-left-radius:5px;-moz-border-radius-topleft:5px;-moz-border-radius-bottomleft:5px;border-top-left-radius:5px;border-bottom-left-radius:5px}.dpsp-shape-rounded .dpsp-network-btn,.dpsp-shape-rounded .dpsp-no-label.dpsp-network-btn .dpsp-network-icon{-webkit-border-top-right-radius:5px;-webkit-border-bottom-right-radius:5px;-moz-border-radius-topright:5px;-moz-border-radius-bottomright:5px;border-top-right-radius:5px;border-bottom-right-radius:5px}.dpsp-shape-circle .dpsp-network-btn{border-radius:30px}.dpsp-shape-circle .dpsp-network-btn .dpsp-network-icon{border-radius:30px;overflow:hidden}.dpsp-has-spacing .dpsp-networks-btns-wrapper li{margin-bottom:10px;margin-right:2%;margin-left:0!important}@media screen and (max-width:720px){.dpsp-hide-on-mobile{display:none}}.dpsp-button-style-1 .dpsp-network-btn{color:#fff!important;padding-left:38px}.dpsp-button-style-1 .dpsp-network-btn .dpsp-network-icon{color:#fff!important}.dpsp-show-total-share-count{position:relative}.dpsp-total-share-wrapper{position:relative;font-family:Arial;margin-top:10px;line-height:1.345;color:#5d6368}.dpsp-total-share-wrapper .dpsp-icon-total-share:before{font-size:16px;top:7px;left:-2px;margin-top:0;margin-left:0}#dpsp-floating-sidebar .dpsp-total-share-wrapper{margin-bottom:10px}#dpsp-floating-sidebar .dpsp-total-share-wrapper .dpsp-icon-total-share{display:none}.dpsp-total-share-wrapper span{display:block;font-size:9px;font-weight:700;text-transform:uppercase;text-align:center}.dpsp-total-share-wrapper .dpsp-total-share-count{font-size:15px;line-height:18px;white-space:nowrap}.dpsp-content-wrapper .dpsp-total-share-wrapper{position:absolute;width:60px;height:40px;margin-top:-21px;top:50%;padding-left:20px;box-sizing:border-box}.dpsp-content-wrapper.dpsp-show-total-share-count.dpsp-show-total-share-count-before{padding-left:70px}.dpsp-content-wrapper.dpsp-show-total-share-count.dpsp-show-total-share-count-after{padding-right:70px}.dpsp-content-wrapper.dpsp-show-total-share-count.dpsp-show-total-share-count-before .dpsp-total-share-wrapper{left:0}.dpsp-content-wrapper.dpsp-show-total-share-count.dpsp-show-total-share-count-after .dpsp-total-share-wrapper{right:0}@media print{#dpsp-floating-sidebar,.dpsp-content-wrapper,.dpsp-share-text{display:none}}
assets/dist/style-frontend.1.0.0.css ADDED
@@ -0,0 +1 @@
 
1
+ @font-face{font-family:Social Pug;src:url(./socialpug.1.0.0.eot?gd6mr8);src:url(./socialpug.1.0.0.eot?#iefix) format("embedded-opentype"),url(./socialpug.1.0.0.woff) format("woff"),url(./socialpug.1.0.0.ttf) format("truetype"),url(./socialpug.1.0.0.svg#socialpug) format("svg");font-weight:400;font-style:normal;font-display:swap}.dpsp-icon-total-share:before{line-height:20px;display:inline-block;line-height:1em}.dpsp-icon-total-share:before,.dpsp-network-btn .dpsp-network-icon:after,.dpsp-network-btn .dpsp-network-icon:before{position:absolute;top:50%;left:50%;margin-top:-10px;margin-left:-10px;width:20px;height:20px;vertical-align:middle;font-family:Social Pug;font-style:normal;font-weight:400;text-decoration:inherit;text-align:center;font-variant:normal;text-transform:none}.dpsp-network-btn .dpsp-network-icon:after,.dpsp-network-btn .dpsp-network-icon:before{display:block;line-height:20px}.dpsp-network-btn .dpsp-network-icon:after{margin-left:-20px;opacity:0}.dpsp-icon-total-share:before{content:"\e883"}.dpsp-facebook .dpsp-network-icon:after,.dpsp-facebook .dpsp-network-icon:before{content:"\e800"}.dpsp-twitter .dpsp-network-icon:after,.dpsp-twitter .dpsp-network-icon:before{content:"\e801"}.dpsp-pinterest .dpsp-network-icon:after,.dpsp-pinterest .dpsp-network-icon:before{content:"\e803"}.dpsp-linkedin .dpsp-network-icon:after,.dpsp-linkedin .dpsp-network-icon:before{content:"\e804"}.dpsp-email .dpsp-network-icon:after,.dpsp-email .dpsp-network-icon:before{content:"\e816"}.dpsp-print .dpsp-network-icon:after,.dpsp-print .dpsp-network-icon:before{content:"\e817"}.dpsp-networks-btns-wrapper.dpsp-has-button-icon-animation .dpsp-network-btn:hover .dpsp-network-icon:after,.dpsp-networks-btns-wrapper.dpsp-has-button-icon-animation .dpsp-network-btn:hover .dpsp-network-icon:before{transition:all .25s ease-in-out}.dpsp-networks-btns-wrapper.dpsp-has-button-icon-animation .dpsp-network-btn:hover .dpsp-network-icon:before{margin-left:5px;opacity:0}.dpsp-networks-btns-wrapper.dpsp-has-button-icon-animation .dpsp-network-btn:hover .dpsp-network-icon:after{margin-left:-10px;opacity:1}#dpsp-floating-sidebar{position:fixed;top:50%;transform:translateY(-50%);z-index:9998}#dpsp-floating-sidebar.dpsp-position-left{left:0}#dpsp-floating-sidebar.dpsp-position-right{right:0}.dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar li{float:none;margin-left:0}.dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn{padding:0;width:40px}.dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon{border-color:transparent!important;background:transparent!important}.dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-has-count .dpsp-network-icon{height:22px;line-height:22px}.dpsp-button-hover .dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn:hover:before{color:#fff}.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn,.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon{border-radius:0}.dpsp-position-left.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-first,.dpsp-position-left.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-first .dpsp-network-icon{-webkit-border-top-right-radius:5px;-moz-border-radius-topright:5px;border-top-right-radius:5px}.dpsp-position-left.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-last,.dpsp-position-left.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-last .dpsp-network-icon{-webkit-border-bottom-right-radius:5px;-moz-border-radius-bottomright:5px;border-bottom-right-radius:5px}.dpsp-position-left.dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn,.dpsp-position-left.dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon{-webkit-border-top-right-radius:5px;-moz-border-radius-topright:5px;border-top-right-radius:5px;-webkit-border-bottom-right-radius:5px;-moz-border-radius-bottomright:5px;border-bottom-right-radius:5px}.dpsp-position-right.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-first,.dpsp-position-right.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-first .dpsp-network-icon{-webkit-border-top-left-radius:5px;-moz-border-radius-topleft:5px;border-top-left-radius:5px}.dpsp-position-right.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-last,.dpsp-position-right.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-last .dpsp-network-icon{-webkit-border-bottom-left-radius:5px;-moz-border-radius-bottomleft:5px;border-bottom-left-radius:5px}.dpsp-position-right.dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn,.dpsp-position-right.dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon{-webkit-border-top-left-radius:5px;-moz-border-radius-topleft:5px;border-top-left-radius:5px;-webkit-border-bottom-left-radius:5px;-moz-border-radius-bottomleft:5px;border-bottom-left-radius:5px}.dpsp-shape-rounded.dpsp-has-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon{border-radius:5px}#dpsp-floating-sidebar.dpsp-position-left.dpsp-shape-circle{left:12px}#dpsp-floating-sidebar.dpsp-position-right.dpsp-shape-circle{right:10px}.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn{margin-bottom:6px}.dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn{-webkit-border-top-right-radius:5px;-moz-border-radius-topright:5px;border-top-right-radius:5px;-webkit-border-bottom-right-radius:5px;-moz-border-radius-bottomright:5px;border-bottom-right-radius:5px}#dpsp-floating-sidebar.dpsp-style-2 .dpsp-network-btn:before{background:none}#dpsp-floating-sidebar .dpsp-networks-btns-wrapper li{position:relative;overflow:visible}#dpsp-floating-sidebar .dpsp-networks-btns-wrapper .dpsp-button-label{position:absolute;z-index:1;display:inline-block;width:auto;white-space:nowrap;top:50%;margin-top:-15px;height:30px;padding:6px 12px;color:#fff;font-size:12px;font-weight:400;line-height:18px;background:#34495e;border-radius:3px;visibility:hidden;opacity:0;transition:all .2s ease-in-out;box-sizing:border-box}#dpsp-floating-sidebar.dpsp-position-left .dpsp-networks-btns-wrapper .dpsp-button-label{left:100%}#dpsp-floating-sidebar.dpsp-position-right .dpsp-networks-btns-wrapper .dpsp-button-label{right:100%}#dpsp-floating-sidebar.dpsp-position-left .dpsp-networks-btns-wrapper li.dpsp-hover .dpsp-button-label{transform:translateX(10px);visibility:visible;opacity:1}#dpsp-floating-sidebar.dpsp-position-right .dpsp-networks-btns-wrapper li.dpsp-hover .dpsp-button-label{transform:translateX(-10px);visibility:visible;opacity:1}#dpsp-floating-sidebar .dpsp-networks-btns-wrapper .dpsp-button-label:before{content:"";display:block;position:absolute;top:50%;margin-top:-5px;border-top:5px solid transparent;border-bottom:5px solid transparent}#dpsp-floating-sidebar.dpsp-position-left .dpsp-networks-btns-wrapper .dpsp-button-label:before{left:-5px;border-right:5px solid #34495e}#dpsp-floating-sidebar.dpsp-position-right .dpsp-networks-btns-wrapper .dpsp-button-label:before{right:-5px;border-left:5px solid #34495e}#dpsp-content-top{margin-bottom:1.2em}#dpsp-content-bottom{margin-top:1.2em}.dpsp-share-text{font-weight:700;margin-bottom:10px}.dpsp-networks-btns-wrapper{list-style:none!important;padding:0!important;margin:0!important}.dpsp-networks-btns-wrapper:after{content:"";display:block;height:0;clear:both}.dpsp-networks-btns-wrapper li{float:left;overflow:hidden;-moz-transition:all .15s ease-in;-webkit-transition:all .15s ease-in;-o-transition:all .15s ease-in;transition:all .15s ease-in;list-style-type:none!important}.dpsp-networks-btns-wrapper li:before{display:none!important}.dpsp-networks-btns-wrapper li:first-child{margin-left:0!important}.dpsp-networks-btns-wrapper .dpsp-network-btn{position:relative;display:block;text-decoration:none!important;text-transform:unset!important;height:40px;min-width:40px;font-family:Arial;font-weight:700;font-size:14px;line-height:36px;vertical-align:middle;padding:0 10px 0 48px;border:2px solid;max-height:40px;width:100%;-moz-box-sizing:border-box;box-sizing:border-box;-moz-transition:all .15s ease-in;-webkit-transition:all .15s ease-in;-o-transition:all .15s ease-in;transition:all .15s ease-in;box-shadow:none;cursor:pointer}.dpsp-networks-btns-wrapper .dpsp-network-btn:focus,.dpsp-networks-btns-wrapper .dpsp-network-btn:hover{border:2px solid;box-shadow:none}.dpsp-networks-btns-wrapper .dpsp-network-btn:after{content:"";display:block;height:0;clear:both}.dpsp-networks-btns-wrapper .dpsp-network-btn .dpsp-network-icon{position:absolute;top:-2px;left:-2px;bottom:-2px;float:left;display:block;font-size:14px;line-height:36px;width:40px;text-align:center;vertical-align:middle;border:2px solid;-moz-box-sizing:border-box;box-sizing:border-box;-moz-transition:all .15s ease-in;-webkit-transition:all .15s ease-in;-o-transition:all .15s ease-in;transition:all .15s ease-in}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-no-label{padding:0 18px}.dpsp-button-style-1 .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-no-label .dpsp-network-icon{width:auto;right:-2px}.dpsp-has-buttons-count .dpsp-networks-btns-wrapper .dpsp-network-label{margin-right:10px}.dpsp-networks-btns-wrapper .dpsp-network-btn .dpsp-network-count{font-size:13px}.dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-count{position:absolute;bottom:0;left:0;width:100%;margin-left:0;font-size:11px;text-align:center;height:20px;line-height:20px}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-no-label .dpsp-network-label-wrapper{display:none}.dpsp-column-1 .dpsp-networks-btns-wrapper li{width:100%}.dpsp-column-1.dpsp-has-spacing .dpsp-networks-btns-wrapper li{margin-right:0}.dpsp-column-2 .dpsp-networks-btns-wrapper li{width:50%}.dpsp-column-2.dpsp-has-spacing .dpsp-networks-btns-wrapper li{width:49%}.dpsp-column-2 .dpsp-networks-btns-wrapper li:nth-child(2n){margin-right:0}.dpsp-column-3 .dpsp-networks-btns-wrapper li{width:33.3333%}.dpsp-column-3.dpsp-has-spacing .dpsp-networks-btns-wrapper li{width:32%}.dpsp-column-3 .dpsp-networks-btns-wrapper li:nth-child(3n){margin-right:0}.dpsp-column-4 .dpsp-networks-btns-wrapper li{width:25%}.dpsp-column-4.dpsp-has-spacing .dpsp-networks-btns-wrapper li{width:23.5%}.dpsp-column-4 .dpsp-networks-btns-wrapper li:nth-child(4n){margin-right:0}.dpsp-column-5 .dpsp-networks-btns-wrapper li{width:20%}.dpsp-column-5.dpsp-has-spacing .dpsp-networks-btns-wrapper li{width:18.4%}.dpsp-column-5 .dpsp-networks-btns-wrapper li:nth-child(5n){margin-right:0}.dpsp-column-6 .dpsp-networks-btns-wrapper li{width:16.6666%}.dpsp-column-6.dpsp-has-spacing .dpsp-networks-btns-wrapper li{width:15%}.dpsp-column-6 .dpsp-networks-btns-wrapper li:nth-child(6n){margin-right:0}.dpsp-column-2 .dpsp-networks-btns-wrapper .dpsp-network-btn,.dpsp-column-3 .dpsp-networks-btns-wrapper .dpsp-network-btn,.dpsp-column-4 .dpsp-networks-btns-wrapper .dpsp-network-btn,.dpsp-column-5 .dpsp-networks-btns-wrapper .dpsp-network-btn,.dpsp-column-6 .dpsp-networks-btns-wrapper .dpsp-network-btn{padding-right:10px}.dpsp-no-labels .dpsp-networks-btns-wrapper .dpsp-network-btn{padding:0;text-align:center}.dpsp-no-labels:not(.dpsp-column-auto) .dpsp-networks-btns-wrapper .dpsp-network-btn:before{position:relative;left:0;float:none;display:inline-block}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-facebook,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-facebook .dpsp-network-icon{border-color:#3a579a;background:#3a579a;color:#3a579a}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-facebook:hover,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-facebook:hover .dpsp-network-icon{border-color:#334d87;background:#334d87;color:#334d87}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-twitter,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-twitter .dpsp-network-icon{border-color:#00abf0;background:#00abf0;color:#00abf0}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-twitter:hover,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-twitter:hover .dpsp-network-icon{border-color:#0099d7;background:#0099d7;color:#0099d7}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-pinterest,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-pinterest .dpsp-network-icon{border-color:#c92228;background:#c92228;color:#c92228}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-pinterest:hover,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-pinterest:hover .dpsp-network-icon{border-color:#b31e24;background:#b31e24;color:#b31e24}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-linkedin,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-linkedin .dpsp-network-icon{border-color:#0077b5;background:#0077b5;color:#0077b5}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-linkedin:hover,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-linkedin:hover .dpsp-network-icon{border-color:#00669c;background:#00669c;color:#00669c}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-email,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-email .dpsp-network-icon{border-color:#27ae60;background:#27ae60;color:#27ae60}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-email:hover,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-email:hover .dpsp-network-icon{border-color:#239e57;background:#239e57;color:#239e57}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-print,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-print .dpsp-network-icon{border-color:#bdc3c7;background:#bdc3c7;color:#bdc3c7}.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-print:hover,.dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-print:hover .dpsp-network-icon{border-color:#afb6bb;background:#afb6bb;color:#afb6bb}.dpsp-has-button-background .dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn:before{color:#fff}.dpsp-shape-rounded .dpsp-network-btn,.dpsp-shape-rounded .dpsp-network-btn .dpsp-network-icon{-webkit-border-top-left-radius:5px;-webkit-border-bottom-left-radius:5px;-moz-border-radius-topleft:5px;-moz-border-radius-bottomleft:5px;border-top-left-radius:5px;border-bottom-left-radius:5px}.dpsp-shape-rounded .dpsp-network-btn,.dpsp-shape-rounded .dpsp-no-label.dpsp-network-btn .dpsp-network-icon{-webkit-border-top-right-radius:5px;-webkit-border-bottom-right-radius:5px;-moz-border-radius-topright:5px;-moz-border-radius-bottomright:5px;border-top-right-radius:5px;border-bottom-right-radius:5px}.dpsp-shape-circle .dpsp-network-btn{border-radius:30px}.dpsp-shape-circle .dpsp-network-btn .dpsp-network-icon{border-radius:30px;overflow:hidden}.dpsp-has-spacing .dpsp-networks-btns-wrapper li{margin-bottom:10px;margin-right:2%;margin-left:0!important}@media screen and (max-width:720px){.dpsp-hide-on-mobile{display:none}}.dpsp-button-style-1 .dpsp-network-btn{color:#fff!important;padding-left:38px}.dpsp-button-style-1 .dpsp-network-btn .dpsp-network-icon{color:#fff!important}.dpsp-show-total-share-count{position:relative}.dpsp-total-share-wrapper{position:relative;font-family:Arial;margin-top:10px;line-height:1.345;color:#5d6368}.dpsp-total-share-wrapper .dpsp-icon-total-share:before{font-size:16px;top:7px;left:-2px;margin-top:0;margin-left:0}#dpsp-floating-sidebar .dpsp-total-share-wrapper{margin-bottom:10px}#dpsp-floating-sidebar .dpsp-total-share-wrapper .dpsp-icon-total-share{display:none}.dpsp-total-share-wrapper span{display:block;font-size:9px;font-weight:700;text-transform:uppercase;text-align:center}.dpsp-total-share-wrapper .dpsp-total-share-count{font-size:15px;line-height:18px;white-space:nowrap}.dpsp-content-wrapper .dpsp-total-share-wrapper{position:absolute;width:60px;height:40px;margin-top:-21px;top:50%;padding-left:20px;box-sizing:border-box}.dpsp-content-wrapper.dpsp-show-total-share-count.dpsp-show-total-share-count-before{padding-left:70px}.dpsp-content-wrapper.dpsp-show-total-share-count.dpsp-show-total-share-count-after{padding-right:70px}.dpsp-content-wrapper.dpsp-show-total-share-count.dpsp-show-total-share-count-before .dpsp-total-share-wrapper{left:0}.dpsp-content-wrapper.dpsp-show-total-share-count.dpsp-show-total-share-count-after .dpsp-total-share-wrapper{right:0}@media print{#dpsp-floating-sidebar,.dpsp-content-wrapper,.dpsp-share-text{display:none}}
assets/src/css/style-dashboard.css ADDED
@@ -0,0 +1,1282 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /**********************************************/
2
+ /* Fonts
3
+ /**********************************************/
4
+ @import url(https://fonts.googleapis.com/css?family=Raleway:300,400,700,800);
5
+
6
+ @font-face {
7
+ font-family: 'Social Pug';
8
+ src:url('../fonts/socialpug.eot?gd6mr8');
9
+ src:url('../fonts/socialpug.eot?#iefix') format('embedded-opentype'),
10
+ url('../fonts/socialpug.woff') format('woff'),
11
+ url('../fonts/socialpug.ttf') format('truetype'),
12
+ url('../fonts/socialpug.svg#socialpug') format('svg');
13
+ font-weight: normal;
14
+ font-style: normal;
15
+ }
16
+
17
+ [class^="dpsp-icon-"]:before, [class*=" dpsp-icon-"]:before {
18
+ font-family: "Social Pug";
19
+ font-style: normal;
20
+ font-weight: normal;
21
+
22
+ display: inline-block;
23
+ text-decoration: inherit;
24
+ text-align: center;
25
+ font-variant: normal;
26
+ text-transform: none;
27
+ line-height: 1em;
28
+ }
29
+
30
+ .dpsp-icon-ok:before { content: '\e880'; }
31
+ .dpsp-icon-remove:before { content: '\e881'; }
32
+ .dpsp-icon-edit:before { content: '\e882'; }
33
+ .dpsp-icon-facebook:before { content: '\e800'; }
34
+ .dpsp-icon-twitter:before { content: '\e801'; }
35
+ .dpsp-icon-google-plus:before { content: '\e802'; }
36
+ .dpsp-icon-pinterest:before { content: '\e803'; }
37
+ .dpsp-icon-linkedin:before { content: '\e804'; }
38
+ .dpsp-icon-email:before { content: '\e816'; }
39
+ .dpsp-icon-print:before { content: '\e817'; }
40
+
41
+
42
+ /**********************************************/
43
+ /* General
44
+ /**********************************************/
45
+
46
+ /* Transitions */
47
+ .dpsp-transition {
48
+ -moz-transition: all 0.15s ease-in;
49
+ -webkit-transition: all 0.15s ease-in;
50
+ -o-transition: all 0.15s ease-in;
51
+ transition: all 0.15s ease-in;
52
+ }
53
+
54
+ /* Grid system */
55
+ [class*="dpsp-col-"] { float: left; padding: 5px; -moz-box-sizing: border-box; box-sizing: border-box; }
56
+ .dpsp-row { margin: 0 -5px; }
57
+ .dpsp-row.dpsp-m-padding { margin: 0 -8px; }
58
+ .dpsp-row.dpsp-m-padding [class*="dpsp-col-"] { padding: 8px; }
59
+ .dpsp-row.dpsp-big-padding { margin: 0 -15px; }
60
+ .dpsp-row.dpsp-big-padding [class*="dpsp-col-"] { padding: 15px; }
61
+
62
+ .dpsp-col-1-1 { width: 100%; }
63
+ .dpsp-col-1-2 { width: 50%; }
64
+ .dpsp-col-1-3 { width: 33.3333%; }
65
+ .dpsp-col-2-3 { width: 66.6666%; }
66
+ .dpsp-col-1-4 { width: 25%; }
67
+ .dpsp-col-3-4 { width: 75%; }
68
+ .dpsp-col-1-5 { width: 20%; }
69
+ .dpsp-col-2-5 { width: 40%; }
70
+ .dpsp-col-3-5 { width: 60%; }
71
+ .dpsp-col-4-5 { width: 80%; }
72
+
73
+ .dpsp-col-3-8 { width: 37.5%; }
74
+
75
+ .dpsp-row:after { content: ''; display: block; clear: both; }
76
+
77
+ /* Admin notices */
78
+ .wrap div.dpsp-admin-notice { position: relative; margin-top: 16px; }
79
+
80
+
81
+ /* Other */
82
+ .dpsp-page-wrapper {
83
+ float: left;
84
+ position: relative;
85
+ width: 100%;
86
+ max-width: 675px;
87
+ }
88
+
89
+ .dpsp-page-wrapper hr {
90
+ border: 0;
91
+ border-bottom: 1px solid #e1e1e1;
92
+ }
93
+
94
+ h1.dpsp-page-title {
95
+ padding-right: 0;
96
+ padding-bottom: 15px;
97
+ }
98
+
99
+ .dpsp-section {
100
+ margin-bottom: 50px;
101
+ }
102
+
103
+ .dpsp-section:after {
104
+ content: '';
105
+ display: block;
106
+ clear: both;
107
+ }
108
+
109
+ .dpsp-section-title {
110
+ margin: 2.75em 0 1.3em 0;
111
+ padding-bottom: 15px;
112
+ border-bottom: 1px solid #e5e5e5;
113
+ }
114
+
115
+ .dpsp-section-title .add-new-h2,
116
+ .dpsp-section-title .add-new-h2:focus {
117
+ float: right;
118
+ padding: 3px 6px;
119
+ top: -1px;
120
+ margin-left: 15px;
121
+ box-shadow: none;
122
+ }
123
+
124
+ .dpsp-social-platforms .add-new-h2 {
125
+ display: inline-block;
126
+ padding: 8px 16px;
127
+ top: 0;
128
+ margin-left: 0;
129
+ }
130
+
131
+ .dpsp-social-platforms .add-new-h2:active {
132
+ top: 0;
133
+ margin-left: 0;
134
+ padding: 8px 16px;
135
+ }
136
+
137
+ /* Social Networks background colors */
138
+ .dpsp-background-color-network-facebook { background: #3a579a; }
139
+ .dpsp-background-color-network-twitter { background: #00abf0; }
140
+ .dpsp-background-color-network-google-plus { background: #df4a32; }
141
+ .dpsp-background-color-network-pinterest { background: #c92228; }
142
+ .dpsp-background-color-network-linkedin { background: #0077b5; }
143
+ .dpsp-background-color-network-email { background: #27ae60; }
144
+ .dpsp-background-color-network-print { background: #bdc3c7; }
145
+
146
+
147
+ /******************************************************************************************/
148
+ /* General Pages Header
149
+ /******************************************************************************************/
150
+ .dpsp-page-header { background: #41A4A9; margin-left: -20px; line-height: 60px; color: #fff; }
151
+ .dpsp-page-header .dpsp-logo { padding: 0 10px 0 20px; }
152
+ .dpsp-page-header .dpsp-logo-inner { font-family: 'Raleway'; font-weight: 700; font-size: 22px; }
153
+ .dpsp-page-header .dpsp-logo-inner span { font-weight: 300; }
154
+
155
+ .mv-grow-logo {
156
+ max-width: 50px;
157
+ display: inline-block;
158
+ vertical-align: top;
159
+ padding-right: 0.5rem;
160
+ padding-top: 0.25rem;
161
+ }
162
+
163
+ .dpsp-page-header:after { content: ''; display: block; clear: both; }
164
+
165
+ .dpsp-page-header nav { display: inline-block; margin-left: 25px; line-height: 62px; }
166
+ .dpsp-page-header nav a { display: inline-block; color: #fff; background: rgba(255,255,255,0.20); text-decoration: none; font-size: 0.9em; line-height: 1; padding: 8px 12px; border-radius: 3px; font-weight: bold; margin: 0 5px; box-shadow: 0 0 2px 2px rgba(52,152,219,0.15); }
167
+ .dpsp-page-header nav a .dashicons { font-size: 14px; height: auto; width: auto; margin-right: 5px; margin-top: -2px; }
168
+ .dpsp-page-header nav a:hover { background: rgba(255,255,255,0.30); }
169
+
170
+ #dpsp-to-premium { display: inline-block; line-height: 18px; padding: 14px 26px; color: #fff; background: #e74c3c; text-decoration: none; font-size: 13px; border-radius: 3px; font-weight: bold; }
171
+ #dpsp-to-premium .dashicons { font-size: 18px; height: auto; width: auto; margin-right: 8px; }
172
+ #dpsp-to-premium:hover { background: #ea6153; }
173
+
174
+
175
+ /******************************************************************************************/
176
+ /* General Cards
177
+ /******************************************************************************************/
178
+ .dpsp-card { margin-bottom: 2em; margin-top: 1.5em; background: #fff; box-shadow: 0 3px 10px -2px rgba(94,135,161,0.3); max-width: 675px; border-radius: 3px; box-sizing: border-box; }
179
+
180
+ .dpsp-card-header { position: relative; padding: 20px; border-bottom: 1px solid rgba(200, 215, 225, 0.5); font-size: 14px; font-weight: bold; }
181
+
182
+ .dpsp-card-inner { padding: 20px; }
183
+ .dpsp-card-inner:after { content: ''; display: block; clear: both; }
184
+
185
+ .dpsp-card-footer { position: relative; padding: 20px; border-top: 1px solid rgba(200, 215, 225, 0.5); background: rgba(200, 215, 225, 0.15); }
186
+
187
+ .dpsp-card-footer-actions { text-align: right; }
188
+ .dpsp-card-footer-actions:after { content: ''; display: block; clear: both; }
189
+ .dpsp-card-footer-actions a { float: left; color: #777; line-height: 34px; outline: 0; box-shadow: none; }
190
+ .dpsp-card-footer-actions a:hover { color: #444; }
191
+
192
+
193
+ /******************************************************************************************/
194
+ /* General Buttons
195
+ /******************************************************************************************/
196
+ .dpsp-button-primary { display: inline-block; border:none; background: #41a4a9; color: #fff !important; cursor: pointer; margin: 0; outline: 0; overflow: hidden; font-size: 13px; font-weight: 500; text-overflow: ellipsis; text-decoration: none; vertical-align: middle; box-sizing: border-box; line-height: 21px; border-radius: 3em; padding: 0.5em 2em; -webkit-appearance: none; -moz-appearance: none; appearance: none; box-shadow: none !important; }
197
+ .dpsp-button-primary:hover { color: #fff; background-color: #243c4a; }
198
+ .dpsp-button-primary:focus { color: #fff; }
199
+ .dpsp-button-primary.dpsp-active,
200
+ .dpsp-button-primary:active { border-width: 2px 1px 1px; }
201
+ .dpsp-button-primary.dpsp-hidden { display: none; }
202
+
203
+ .dpsp-button-secondary { display: inline-block; background: #fff; border-color: #c8d7e1; border-style: solid; border-width: 1px 1px 2px; color: #2e4453; cursor: pointer; margin: 0; outline: 0; overflow: hidden; font-size: 13px; font-weight: 500; text-overflow: ellipsis; text-decoration: none; vertical-align: middle; box-sizing: border-box; line-height: 21px; border-radius: 4px; padding: 5px 11px; -webkit-appearance: none; -moz-appearance: none; appearance: none; box-shadow: none !important; }
204
+ .dpsp-button-secondary:hover { color: #2e4453; border-color: #a8bece; }
205
+ .dpsp-button-secondary:focus { color: #2e4453; }
206
+ .dpsp-button-secondary.dpsp-active,
207
+ .dpsp-button-secondary:active { border-width: 2px 1px 1px; }
208
+ .dpsp-button-secondary.dpsp-hidden { display: none; }
209
+ .dpsp-button-secondary[disabled],
210
+ .dpsp-button-secondary.disabled { color: #e9eff3; background: #fff; border-color: #e9eff3; cursor: default; }
211
+
212
+
213
+ /**********************************************/
214
+ /* Sortable Networks Panel
215
+ /**********************************************/
216
+
217
+ /* Select Networks button */
218
+ #dpsp-select-networks { position: absolute; top: 50%; margin-top: -17px; right: 10px; }
219
+
220
+ /* Empty Networks Placeholder */
221
+ #dpsp-sortable-networks-empty {
222
+ display: none;
223
+ position: relative;
224
+ text-align: center;
225
+ color: #848484;
226
+ }
227
+
228
+ #dpsp-sortable-networks-empty:after {
229
+ content: '';
230
+ display: block;
231
+ width: 130px;
232
+ height: 70px;
233
+ position: absolute;
234
+ top: -17px;
235
+ right: 80px;
236
+ background: url('../img/dpsp-selectable-empty.png') no-repeat center;
237
+ background-size: 100%;
238
+ opacity: 0;
239
+ transition: all 0.15s ease-in;
240
+ }
241
+
242
+ #dpsp-sortable-networks-empty.dpsp-active {
243
+ display: block;
244
+ }
245
+
246
+ #dpsp-sortable-networks-empty.dpsp-active:after {
247
+ opacity: 1;
248
+ }
249
+
250
+ .dpsp-social-platforms-sort-list {
251
+ margin-top: 0;
252
+ margin-bottom: 0;
253
+ }
254
+
255
+ .dpsp-social-platforms-sort-list li {
256
+ position: relative;
257
+ margin: 0;
258
+ overflow: hidden;
259
+ background: #fff;
260
+ border-bottom: 1px solid #f1f1f1;
261
+ padding-top: 5px;
262
+ padding-bottom: 5px;
263
+ box-sizing: border-box;
264
+ }
265
+
266
+ .dpsp-social-platforms-sort-list li.dpsp-last {
267
+ border-bottom: 0;
268
+ border-bottom-right-radius: 3px;
269
+ border-bottom-left-radius: 3px;
270
+ }
271
+
272
+ .dpsp-social-platforms-sort-list li.ui-sortable-helper {
273
+ box-shadow: 0 3px 12px 3px rgba( 0, 0, 0, 0.1 );
274
+ }
275
+
276
+ .dpsp-social-platforms-sort-list.empty li {
277
+ background: none;
278
+ border: 2px dashed #c1c1c1;
279
+ padding: 20px;
280
+ }
281
+
282
+ .dpsp-social-platforms-sort-list li:after {
283
+ content: '';
284
+ display: block;
285
+ clear: both;
286
+ height: 0;
287
+ }
288
+
289
+ .dpsp-social-platforms-sort-list li:last-of-type {
290
+ margin-bottom: 0;
291
+ }
292
+
293
+ .dpsp-social-platforms-sort-list li.dpsp-sort-placeholder {
294
+ background: #f9f9f9;
295
+ height: 55px;
296
+ box-shadow: inset 0 3px 12px 3px rgba( 0, 0, 0, 0.02 );
297
+ border-radius: 0;
298
+ }
299
+
300
+ .dpsp-social-platforms-sort-list li .dpsp-sort-handle {
301
+ float: left;
302
+ display: block;
303
+ width: 44px;
304
+ height: 44px;
305
+ cursor: move;
306
+ }
307
+
308
+ .dpsp-social-platforms-sort-list li .dpsp-sort-handle:before {
309
+ content: "";
310
+ position: absolute;
311
+ left: 12px;
312
+ top: 23px;
313
+ width: 20px;
314
+ height: 1px;
315
+ background: #c1c1c1;
316
+ box-shadow:
317
+ 0 0.25em 0 0 #c1c1c1,
318
+ 0 0.5em 0 0 #c1c1c1;
319
+ }
320
+
321
+ .dpsp-social-platforms-sort-list li .dpsp-list-icon {
322
+ float: left;
323
+ display: block;
324
+ width: 44px;
325
+ height: 44px;
326
+ line-height: 44px;
327
+ text-align: center;
328
+ font-size: 1.1em;
329
+ }
330
+
331
+ .dpsp-social-platforms-sort-list li .dpsp-list-icon-social {
332
+ color: #fff;
333
+ }
334
+
335
+
336
+ /**
337
+ * Sort list label input field
338
+ *
339
+ */
340
+ .dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper { position: relative; float: left; padding: 8px; }
341
+
342
+ .dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper input { border: 0; line-height: 28px; width: 250px; border-radius: 3px; margin: 0; outline: 0; padding: 0 7px; font-weight: bold; font-size: 1em; color: #444; box-shadow: none; transition: background-color 0.1s ease-in-out; }
343
+ .dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper input:placeholder-shown { font-weight: normal; font-style: italic; }
344
+
345
+ .dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper input:focus,
346
+ .dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper:hover input { background: #f5f5f5; }
347
+
348
+ /* Remove styling for the edit label field from the sticky bar tool */
349
+ .dpsp-page-sticky-bar .dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper input { cursor: default; background-color: transparent !important; }
350
+
351
+
352
+ /**
353
+ * Sort list actions
354
+ *
355
+ */
356
+ .dpsp-social-platforms-sort-list li .dpsp-list-actions { float: right; margin-right: 6px; }
357
+ .dpsp-social-platforms-sort-list li .dpsp-list-actions a { position: relative; display: inline-block; color: #747474; text-decoration: none; line-height: 28px; vertical-align: middle; margin: 8px 2px 8px 0; padding: 0 6px 0 3px; border-radius: 3px; box-shadow: none; transition: background-color 0.1s ease-in-out, color 0.1s ease-in-out; }
358
+ .dpsp-social-platforms-sort-list li .dpsp-list-actions a .dashicons { position: relative; top: -1px; vertical-align: text-top; line-height: 18px; height: 18px; width: 18px; font-size: 18px; margin-right: 2px; }
359
+
360
+ .dpsp-social-platforms-sort-list li .dpsp-list-actions a:hover { background: #f4f4f4; color: #353535; }
361
+
362
+ /* Remove Edit Label action from sticky bar tool */
363
+ .dpsp-page-sticky-bar .dpsp-social-platforms-sort-list li .dpsp-list-actions .dpsp-list-edit-label { display: none; }
364
+
365
+
366
+ /**********************************************/
367
+ /* All networks selector list
368
+ /**********************************************/
369
+ #dpsp-networks-selector-wrapper {
370
+ display: none;
371
+ }
372
+
373
+ #dpsp-networks-selector {
374
+ padding: 20px;
375
+ margin: 0;
376
+ }
377
+
378
+ #dpsp-networks-selector li {
379
+ position: relative;
380
+ float: left;
381
+ width: 33.3333%;
382
+ margin-bottom: 1em;
383
+ padding: 0 10px;
384
+ box-sizing: border-box;
385
+ }
386
+
387
+ #dpsp-networks-selector:after {
388
+ content: '';
389
+ display: block;
390
+ clear: both;
391
+ height: 0;
392
+ }
393
+
394
+ #dpsp-networks-selector .dpsp-network-item {
395
+ position: relative;
396
+ overflow: hidden;
397
+ padding-left: 35px;
398
+ box-sizing: border-box;
399
+ cursor: pointer;
400
+ }
401
+
402
+ #dpsp-networks-selector .dpsp-network-item-checkbox {
403
+ position: absolute;
404
+ top: 0;
405
+ left: 0;
406
+ width: 26px;
407
+ height: 26px;
408
+ line-height: 26px;
409
+ font-size: 16px;
410
+ vertical-align: middle;
411
+ text-align: center;
412
+ color: #555;
413
+ background: #fff;
414
+ border: 2px solid #c8d7e1;
415
+ border-radius: 15px;
416
+ -webkit-box-shadow: 0 1px 1px -1px rgba(0,0,0,.1);
417
+ box-shadow: 0 1px 1px -1px rgba(0,0,0,.1);
418
+ }
419
+
420
+ #dpsp-networks-selector .dpsp-network-item-checkbox:before {
421
+ position: relative;
422
+ opacity: 0;
423
+ transition: all 0.15s ease-in;
424
+ }
425
+
426
+ #dpsp-networks-selector .dpsp-network-item:hover .dpsp-network-item-checkbox:before {
427
+ opacity: 0.15;
428
+ }
429
+
430
+ #dpsp-networks-selector .dpsp-network-item[data-checked="true"] .dpsp-network-item-checkbox:before {
431
+ opacity: 1;
432
+ }
433
+
434
+ #dpsp-networks-selector .dpsp-network-item[data-checked="true"]:hover .dpsp-network-item-checkbox:before {
435
+ opacity: 1;
436
+ }
437
+
438
+ #dpsp-networks-selector .dpsp-network-item-name-wrapper {
439
+ height: 30px;
440
+ line-height: 30px;
441
+ color: #fff;
442
+ vertical-align: middle;
443
+ padding-left: 10px;
444
+ border-radius: 3px;
445
+ -webkit-box-shadow: 0 1px 1px -1px rgba(0,0,0,.1);
446
+ box-shadow: 0 1px 1px -1px rgba(0,0,0,.1);
447
+ }
448
+
449
+ #dpsp-networks-selector .dpsp-network-item-name-wrapper .dpsp-list-icon {
450
+ display: inline-block;
451
+ margin-right: 12px;
452
+ margin-left: 5px;
453
+ }
454
+
455
+ #dpsp-networks-selector .dpsp-network-item-name-wrapper h4 {
456
+ display: inline-block;
457
+ margin: 0;
458
+ }
459
+
460
+
461
+ /**********************************************/
462
+ /* Settings fields
463
+ /**********************************************/
464
+ .dpsp-setting-field-wrapper {
465
+ position: relative;
466
+ left: auto;
467
+ margin-bottom: 12px;
468
+ min-height: 39px;
469
+ transition: opacity 0.4s ease-in-out;
470
+ }
471
+
472
+ .dpsp-setting-field-wrapper.disabled {
473
+ position: absolute;
474
+ left: -9999px;
475
+ visibility: hidden;
476
+ opacity: 0;
477
+ }
478
+
479
+ .dpsp-setting-field-wrapper.dpsp-last {
480
+ margin-bottom: 0;
481
+ }
482
+
483
+ .dpsp-setting-field-label {
484
+ position: absolute;
485
+ top: 2px;
486
+ left: 0;
487
+ display: inline-block;
488
+ width: 235px;
489
+ vertical-align: top;
490
+ padding-right: 15px;
491
+ box-sizing: border-box;
492
+ }
493
+
494
+ .dpsp-setting-field-wrapper.dpsp-has-field-label {
495
+ padding-left: 243px;
496
+ }
497
+
498
+ .dpsp-setting-field-wrapper.dpsp-has-field-label .dpsp-setting-field-inner {
499
+ position: relative;
500
+ top: -18px;
501
+ margin-left: 243px;
502
+ }
503
+
504
+ /* Text */
505
+ .dpsp-setting-field-wrapper input[type=text] {
506
+ margin: 0;
507
+ box-shadow: none;
508
+ padding: 10px 12px;
509
+ border-radius: 2px;
510
+ border: 1px solid #c8d7e1;
511
+ width: 100%;
512
+ }
513
+
514
+ .dpsp-setting-field-wrapper input[type=text]:focus {
515
+ border-color: #0087be;
516
+ box-shadow: 0 0 1px 0px #78dcfa;
517
+ }
518
+
519
+ /* Select */
520
+ .dpsp-setting-field-wrapper select {
521
+ min-width: 200px;
522
+ }
523
+
524
+ .dpsp-setting-field-select *:focus {
525
+ outline: 0 !important;
526
+ }
527
+
528
+ /* Select2 */
529
+ .dpsp-setting-field-wrapper select {
530
+ min-width: 200px;
531
+ }
532
+
533
+ .dpsp-setting-field-select *:focus {
534
+ outline: 0 !important;
535
+ }
536
+
537
+ .dpsp-setting-field-select .select2-container {
538
+ width: 100% !important;
539
+ }
540
+
541
+ .dpsp-setting-field-select .select2-selection {
542
+ border-color: #fff;
543
+ height: 39px;
544
+ border-radius: 2px;
545
+ border: 1px solid #c8d7e1;
546
+ }
547
+
548
+ .dpsp-setting-field-select .select2-selection .select2-selection__rendered {
549
+ line-height: 37px !important;
550
+ padding-left: 10px;
551
+ }
552
+
553
+ .dpsp-setting-field-select .select2-selection .select2-selection__arrow {
554
+ height: 37px;
555
+ padding-right: 10px;
556
+ }
557
+
558
+ .dpsp-select2 .select2-dropdown {
559
+ border-color: #c8d7e1;
560
+ border-radius: 0;
561
+ }
562
+
563
+ .dpsp-select2 .select2-dropdown li {
564
+ margin: 0;
565
+ line-height: 36px;
566
+ padding: 0 10px;
567
+ }
568
+
569
+ .dpsp-select2 .select2-results__option[aria-selected="true"] {
570
+ background: #e8eaeb;
571
+ }
572
+
573
+ .dpsp-select2 .select2-results__option--highlighted {
574
+ background: #00aadc !important;
575
+ }
576
+
577
+ .dpsp-select2 .select2-dropdown--below {
578
+ top: 32px;
579
+ box-shadow: 0 4px 3px 2px rgba(0,0,0,0.08);
580
+ }
581
+
582
+ .dpsp-select2 .select2-dropdown--above {
583
+ box-shadow: 0 -4px 3px 2px rgba(0,0,0,0.08);
584
+ }
585
+
586
+ .dpsp-setting-field-select .select2-container--open {
587
+ box-shadow: 0 0 3px 2px rgba(0,0,0,0.08);
588
+ }
589
+
590
+
591
+ /* Textarea */
592
+ .dpsp-setting-field-wrapper textarea {
593
+ min-height: 100px;
594
+ min-width: 450px;
595
+ border: 0;
596
+ box-shadow: none;
597
+ padding: 5px 8px;
598
+ border-radius: 3px;
599
+ }
600
+
601
+ /* Checkbox and Radio */
602
+ .dpsp-setting-field-wrapper input[type=checkbox],
603
+ .dpsp-setting-field-wrapper input[type=radio] {
604
+ display: none;
605
+ }
606
+
607
+ .dpsp-setting-field-checkbox.dpsp-single .dpsp-setting-field-label {
608
+ padding-right: 18px;
609
+ }
610
+
611
+ .dpsp-setting-field-checkbox.dpsp-multiple .dpsp-settings-field-checkbox,
612
+ .dpsp-setting-field-radio.dpsp-multiple .dpsp-settings-field-radio {
613
+ display: inline-block;
614
+ margin-right: 12px;
615
+ position: relative;
616
+ padding-left: 23px;
617
+ }
618
+
619
+ .dpsp-setting-field-checkbox input[type=checkbox] + label span,
620
+ .dpsp-setting-field-radio input[type=radio] + label span {
621
+ content: '';
622
+ display: block;
623
+ position: absolute;
624
+ width: 16px;
625
+ height: 16px;
626
+ background: #fff;
627
+ border: 1px solid #e7e7e7;
628
+ border-radius: 3px;
629
+ transition: background 0.1s ease-in-out, border-color 0.1s ease-in-out;
630
+ }
631
+
632
+ .dpsp-setting-field-radio input[type=radio] + label span {
633
+ border-radius: 50%;
634
+ }
635
+
636
+ .dpsp-setting-field-checkbox.dpsp-single input[type=checkbox] + label span {
637
+ top: 0;
638
+ right: 0;
639
+ }
640
+
641
+ .dpsp-setting-field-checkbox.dpsp-multiple input[type=checkbox] + label span,
642
+ .dpsp-setting-field-radio.dpsp-multiple input[type=radio] + label span {
643
+ top: 0;
644
+ left: 0;
645
+ }
646
+
647
+ .dpsp-setting-field-checkbox input[type=checkbox] + label span:before {
648
+ display: inline-block;
649
+ content: '\f147';
650
+ font: 400 20px/1 'dashicons';
651
+ width: 16px;
652
+ height: 16px;
653
+ line-height: 16px;
654
+ vertical-align: middle;
655
+ margin: -5px 0 0 -3px;
656
+ color: transparent;
657
+ transition: color 0.1s ease-in-out;
658
+ }
659
+
660
+ .dpsp-setting-field-radio input[type=radio] + label span:before {
661
+ content: '';
662
+ position: relative;
663
+ top: 5px;
664
+ left: 5px;
665
+ display: block;
666
+ width: 6px;
667
+ height: 6px;
668
+ border-radius: 50%;
669
+ }
670
+
671
+
672
+ .dpsp-setting-field-checkbox input[type=checkbox]:checked + label span {
673
+ background: #41a4a9;
674
+ border-color: transparent;
675
+ }
676
+
677
+ .dpsp-setting-field-checkbox input[type=checkbox]:checked + label span:before {
678
+ color: #fff;
679
+ }
680
+
681
+
682
+ .dpsp-setting-field-radio input[type=radio]:checked + label span {
683
+ background: #41a4a9;
684
+ border-color: transparent;
685
+ }
686
+
687
+ .dpsp-setting-field-radio input[type=radio]:checked + label span:before {
688
+ background: #fff;
689
+ }
690
+
691
+ /* Tooltip */
692
+ .dpsp-setting-field-tooltip-wrapper {
693
+ position: absolute;
694
+ top: 2px;
695
+ left: 217px;
696
+ display: inline-block;
697
+ width: 18px;
698
+ height: 18px;
699
+ margin-left: 5px;
700
+ }
701
+
702
+ .dpsp-setting-field-tooltip-icon:before {
703
+ content: '?';
704
+ display: inline-block;
705
+ width: 14px;
706
+ height: 14px;
707
+ line-height: 14px;
708
+ font-size: 10px;
709
+ font-weight: bold;
710
+ vertical-align: middle;
711
+ text-align: center;
712
+ color: #fff;
713
+ background: #34495e;
714
+ border-radius: 9px;
715
+ cursor: pointer;
716
+ transition: all 0.15s ease-in;
717
+ }
718
+
719
+ .dpsp-setting-field-tooltip-icon:hover:before {
720
+ background: #34495e;
721
+ }
722
+
723
+ .dpsp-setting-field-tooltip {
724
+ z-index: 10;
725
+ opacity: 0;
726
+ visibility: hidden;
727
+ position: absolute;
728
+ top: 28px;
729
+ left: -25px;
730
+ width: 220px;
731
+ background: rgba( 52, 73, 94, 0.975 );
732
+ color: #fff;
733
+ border-radius: 4px;
734
+ padding: 8px 12px;
735
+ }
736
+
737
+ .dpsp-setting-field-tooltip a {
738
+ color: rgba( 52,152,219,1 );
739
+ }
740
+
741
+ .dpsp-setting-field-tooltip:before {
742
+ content: '';
743
+ display: block;
744
+ position: absolute;
745
+ top: -6px;
746
+ left: 27px;
747
+ width: 0;
748
+ height: 0;
749
+ border-style: solid;
750
+ border-width: 0 4.5px 6px 4.5px;
751
+ border-color: transparent transparent rgba( 52, 73, 94, 0.975 ) transparent;
752
+ }
753
+
754
+
755
+ .dpsp-settings-button-style {
756
+ cursor: pointer;
757
+ width: 10%;
758
+ margin-right: 1.5%;
759
+ margin-bottom: 10px;
760
+ padding: 12px;
761
+ border-radius: 5px;
762
+ border: 1px solid transparent;
763
+ float: left;
764
+ -moz-box-sizing: border-box;
765
+ box-sizing: border-box;
766
+ }
767
+
768
+ .dpsp-setting-field-share-text input { width: 350px; }
769
+
770
+ /* Switches */
771
+ .dpsp-setting-field-wrapper .dpsp-switch { float: none; margin-left: 0; }
772
+
773
+ /* Settings - Facebook App Authorized */
774
+ .dpsp-setting-field-facebook-app-authorized { background: rgba(0, 184, 148, 0.3); padding: 9px; border-radius: 3px; color: #27ae60; }
775
+ .dpsp-setting-field-facebook-app-authorized-expired { background: rgba( 192, 57, 43, 0.3); padding: 9px; border-radius: 3px; color: #c0392b; margin-bottom: 10px; }
776
+
777
+ .dpsp-setting-field-facebook-authorize-app,
778
+ .dpsp-setting-field-facebook-app-id,
779
+ .dpsp-setting-field-facebook-app-secret { display: none; }
780
+
781
+ /**********************************************/
782
+ /* Settings page styles
783
+ /**********************************************/
784
+ .dpsp-page-wrapper .dpsp-settings-button-style .dpsp-networks-btns-wrapper li {
785
+ margin-bottom: 6px;
786
+ }
787
+
788
+ .dpsp-page-wrapper .dpsp-settings-button-style .dpsp-networks-btns-wrapper li:last-of-type {
789
+ margin-bottom: 0;
790
+ }
791
+
792
+ /* Page sidebar specific styles */
793
+ .dpsp-page-sidebar .dpsp-settings-button-style .dpsp-networks-btns-wrapper .dpsp-network-btn {
794
+ margin: 0 auto;
795
+ }
796
+
797
+ .dpsp-page-sidebar .dpsp-settings-button-style .dpsp-shape-rounded .dpsp-networks-btns-wrapper .dpsp-network-btn,
798
+ .dpsp-page-sidebar .dpsp-settings-button-style .dpsp-shape-rounded .dpsp-networks-btns-wrapper .dpsp-network-btn:before {
799
+ border-radius: 5px;
800
+ }
801
+
802
+
803
+ /* Page content specific styles */
804
+ .dpsp-page-content .dpsp-settings-button-style {
805
+ width: 24.25%;
806
+ margin-right: 1%
807
+ }
808
+
809
+ .dpsp-page-content .dpsp-section-button-style label:nth-of-type(4n) {
810
+ margin-right: 0;
811
+ }
812
+
813
+
814
+ .dpsp-settings-button-style:hover {
815
+ border-color: #e1e1e1;
816
+ }
817
+
818
+ .dpsp-settings-button-style-input {
819
+ display: none !important;
820
+ }
821
+
822
+ .dpsp-settings-button-style-input:checked + label {
823
+ border-color: rgba(52, 152, 219, 0.3);
824
+ background: rgba(52, 152, 219, 0.075);
825
+ }
826
+
827
+
828
+ /**********************************************/
829
+ /* Toolkit Page
830
+ /**********************************************/
831
+ #dpsp-toolkit-welcome { padding: 35px 25px; background: #fff; margin-left: -20px; text-align: center; overflow: hidden; }
832
+ #dpsp-toolkit-welcome h2 { font-size: 1.8em; margin-top: 0; margin-bottom: 1.6em; }
833
+ #dpsp-toolkit-welcome p { font-size: 14px; }
834
+ #dpsp-toolkit-welcome .button { margin-top: 1.6em; box-shadow: none; outline: 0; }
835
+
836
+ .dpsp-tool-wrapper { background: #fff; border-radius: 3px; overflow: hidden; }
837
+ .dpsp-tool-wrapper img { max-width: 100%; height: auto; }
838
+ .dpsp-tool-wrapper a { color: #777; text-decoration: none; }
839
+ .dpsp-tool-wrapper a:hover { color: rgba(52,152,219,0.75); }
840
+ .dpsp-tool-wrapper h4 { font-size: 15px; margin-bottom: 0; margin-top: 0; padding: 10px; text-align: center; }
841
+
842
+ .dpsp-tool-wrapper .dpsp-tool-actions { position: relative; padding: 15px; }
843
+ .dpsp-tool-wrapper .dpsp-tool-actions:after { content: ''; display: block; clear: both; }
844
+
845
+ .dpsp-tool-wrapper .dpsp-tool-actions-overlay { z-index: 1; position: absolute; top: 0; left: 0; height: 100%; width: 100%; background: rgba(255,255,255,0.6); opacity: 0; }
846
+ .dpsp-tool-wrapper .dpsp-tool-actions-overlay .spinner { float: none; visibility: visible; opacity: 1; margin: 15px 0 0 15px; }
847
+
848
+ .dpsp-tool-wrapper .dpsp-tool-actions.dpsp-active span { opacity: 0; }
849
+ .dpsp-tool-wrapper .dpsp-tool-actions.dpsp-inactive span { opacity: 0.4; }
850
+
851
+ .dpsp-tool-wrapper .dpsp-tool-actions .dpsp-tool-settings { line-height: 1; vertical-align: middle; }
852
+ .dpsp-tool-wrapper .dpsp-tool-actions .dpsp-tool-settings:focus { box-shadow: none; }
853
+ .dpsp-tool-wrapper .dpsp-tool-actions.dpsp-inactive .dpsp-tool-settings { display: none; }
854
+
855
+ .dpsp-tool-wrapper .dpsp-tool-actions .dpsp-tool-settings i { margin-right: 3px; }
856
+
857
+ .dpsp-tool-wrapper .dpsp-switch span { text-transform: uppercase; font-size: 0.85em; margin-right: 5px; }
858
+ .dpsp-tool-wrapper .dpsp-switch label { display: inline-block !important; }
859
+
860
+ .dpsp-page-toolkit .dpsp-col-3-8 { padding-top: 0 !important; }
861
+
862
+ /**********************************************/
863
+ /* Extensions Page
864
+ /**********************************************/
865
+ .dpsp-page-extensions { max-width: 1000px; }
866
+
867
+ .dpsp-page-extensions .dpsp-card { margin-top: 0; margin-bottom: 0; }
868
+
869
+ .dpsp-unavailable > a { display: block; line-height: 0; }
870
+ .dpsp-unavailable h4 { padding-bottom: 0; border-bottom: 0; border-top: 1px solid #f1f1f1; text-align: left; }
871
+ .dpsp-unavailable p.dpsp-description { margin: 0; padding: 10px; }
872
+ .dpsp-unavailable .dpsp-tool-actions { padding: 15px 10px; overflow: hidden; text-align: center; background: #f9f9f9; border-top: 1px solid #f1f1f1; }
873
+ .dpsp-unavailable .dpsp-tool-actions .button { padding-left: 25px; padding-right: 25px; }
874
+ .dpsp-unavailable .dpsp-description { height: 57px; }
875
+
876
+
877
+ /**********************************************/
878
+ /* Settings page sidebar
879
+ /**********************************************/
880
+ .dpsp-settings-sidebar {
881
+ float: left;
882
+ margin-top: 63px;
883
+ padding-left: 20px;
884
+ width: 365px;
885
+ -moz-box-sizing: border-box;
886
+ box-sizing: border-box;
887
+ }
888
+
889
+ .dpsp-settings-sidebar p {
890
+ color: #767676;
891
+ }
892
+
893
+ @media screen and ( max-width : 1225px ) {
894
+
895
+ .dpsp-settings-sidebar {
896
+ border-left: 0;
897
+ padding-left: 0;
898
+ }
899
+
900
+ }
901
+
902
+ #dpsp-settings-sidebar-social-pug-pro img { max-width: 100%; height: auto; padding: 0 20px; box-sizing: border-box; }
903
+ #dpsp-settings-sidebar-social-pug-pro h3 { text-align: center; line-height: 1.7em; font-weight: bold; }
904
+ #dpsp-settings-sidebar-social-pug-pro p { position: relative; padding-left: 45px; color: #454545; margin-bottom: 20px; }
905
+
906
+ #dpsp-settings-sidebar-social-pug-pro p .dpsp-dashicons { position: absolute; top: -5px; left: 0; display: inline-block; width: 30px; height: 30px; }
907
+ #dpsp-settings-sidebar-social-pug-pro p .dpsp-dashicons:after { content: ''; display: block; position: absolute; z-index: 1; top: -1px; left: 2px; width: 30px; height: 30px; border-radius: 20px; background: #41a4a9 }
908
+
909
+ #dpsp-settings-sidebar-social-pug-pro p .dashicons { position: absolute; top: 0; left: 0; width: 30px; height: 30px; font-size: 24px; line-height: 30px; color: #fff; z-index: 2;}
910
+ #dpsp-settings-sidebar-social-pug-pro .dpsp-button-primary { width: 100%; text-align: center; padding: 10px 0; box-sizing: border-box; }
911
+
912
+ #dpsp-settings-sidebar-opt-in-hound img { max-width: 35px; height: auto; margin-right: 10px; border-radius: 50px; vertical-align: middle; }
913
+
914
+ /**********************************************/
915
+ /* Settings page sidebar: MailChimp Subscribe
916
+ /**********************************************/
917
+ #dpsp-mailchimp-subscribe-wrapper h3 { margin-bottom: 0; }
918
+ #dpsp-mailchimp-subscribe-wrapper p { margin-top: 5px; margin-bottom: 15px; }
919
+ #dpsp-mailchimp-subscribe-wrapper label { display: block; margin-bottom: 5px; }
920
+ #dpsp-mailchimp-subscribe-wrapper input[type=text],
921
+ #dpsp-mailchimp-subscribe-wrapper input[type=email] { margin-bottom: 10px; width: 100%; }
922
+
923
+
924
+ /**********************************************/
925
+ /* Checkbox switch
926
+ /**********************************************/
927
+
928
+ /* Default */
929
+ .dpsp-switch {
930
+ position: relative;
931
+ display: inline-block;
932
+ margin-left: 20px;
933
+ float: right;
934
+ }
935
+ .dpsp-page-wrapper .cmn-toggle {
936
+ position: absolute;
937
+ margin-left: -9999px;
938
+ visibility: hidden;
939
+ }
940
+ .dpsp-page-wrapper .cmn-toggle + label {
941
+ display: block;
942
+ position: relative;
943
+ cursor: pointer;
944
+ outline: none;
945
+ user-select: none;
946
+ }
947
+ .dpsp-page-wrapper input.cmn-toggle-round + label {
948
+ padding: 3px;
949
+ width: 36px;
950
+ height: 18px;
951
+ background-color: #c9d6e0;
952
+ border-radius: 20px;
953
+ transition: background 0.4s;
954
+ box-sizing: content-box;
955
+ }
956
+ .dpsp-page-wrapper input.cmn-toggle-round + label:before,
957
+ .dpsp-page-wrapper input.cmn-toggle-round + label:after {
958
+ display: block;
959
+ position: absolute;
960
+ top: 2px;
961
+ left: 2px;
962
+ bottom: 2px;
963
+ content: "";
964
+ }
965
+ .dpsp-page-wrapper input.cmn-toggle-round + label:before {
966
+ right: 2px;
967
+ border-radius: 18px;
968
+ transition: background 0.4s;
969
+ }
970
+ .dpsp-page-wrapper input.cmn-toggle-round + label:after {
971
+ width: 20px;
972
+ background-color: #fff;
973
+ border-radius: 100%;
974
+ box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
975
+ transition: margin 0.4s;
976
+ }
977
+ .dpsp-page-wrapper input.cmn-toggle-round:checked + label {
978
+ background-color: #41a4a9;
979
+ }
980
+
981
+ .dpsp-page-wrapper input.cmn-toggle-round:checked + label:after {
982
+ margin-left: 18px;
983
+ }
984
+
985
+ /* Small */
986
+ .dpsp-switch.small input.cmn-toggle-round + label {
987
+ width: 30px;
988
+ height: 15px;
989
+ }
990
+ .dpsp-switch.small input.cmn-toggle-round + label:after {
991
+ width: 17px;
992
+ }
993
+ .dpsp-switch.small input.cmn-toggle-round:checked + label:after {
994
+ margin-left: 15px;
995
+ }
996
+
997
+
998
+ /**********************************************/
999
+ /* Admin Notices
1000
+ /**********************************************/
1001
+ .wrap div.dpsp-admin-notice { position: relative; margin-top: 16px; }
1002
+ .wrap div.dpsp-admin-notice h4 { font-size: 16px; }
1003
+ .wrap div.dpsp-admin-notice p { font-size: 14px; }
1004
+
1005
+ .dpsp-admin-notice-activation { border-color: rgba(52,152,219,0.75); }
1006
+ .dpsp-admin-notice-activation h4 { font-size: 1.05em; }
1007
+ .dpsp-admin-notice-activation a { text-decoration: none; }
1008
+ .dpsp-admin-notice-activation .dpsp-admin-notice-link { display: inline-block; padding: 6px 8px; margin-bottom: 10px; color: rgba(52,152,219,1); font-weight: 500; background: #e9e9e9; border-radius: 2px; margin-right: 10px; }
1009
+ .dpsp-admin-notice-activation .dpsp-admin-notice-link span { display: inline-block; text-decoration: none; margin-right: 10px; }
1010
+ .dpsp-admin-notice-activation .dpsp-admin-notice-link:hover { color: #fff; background: rgba(52,152,219,0.75); }
1011
+
1012
+ .dpsp-admin-notice-wp-rating { border-color: rgba(52,152,219,0.75); }
1013
+ .dpsp-admin-notice-wp-rating h4 { font-size: 1.05em; }
1014
+ .dpsp-admin-notice-wp-rating p:last-of-type { margin-bottom: 20px; }
1015
+ .dpsp-admin-notice-wp-rating a { text-decoration: none; }
1016
+ .dpsp-admin-notice-wp-rating .dpsp-admin-notice-link { display: inline-block; padding: 6px 8px; margin-bottom: 10px; color: rgba(52,152,219,1); font-weight: 500; background: #e9e9e9; border-radius: 2px; margin-right: 10px; }
1017
+ .dpsp-admin-notice-wp-rating .dpsp-admin-notice-link span { display: inline-block; text-decoration: none; margin-right: 10px; }
1018
+ .dpsp-admin-notice-wp-rating .dpsp-admin-notice-link:hover { color: #fff; background: rgba(52,152,219,0.75); }
1019
+ .dpsp-admin-notice-wp-rating .dashicons-star-filled { position: relative; top: 1px; width: 15px; height: 15px; font-size: 15px; }
1020
+
1021
+ .dpsp-admin-notice-opt-in-hound { position: relative; padding-left: 140px; border-color: rgba(52,152,219,0.75); }
1022
+ .dpsp-admin-notice-opt-in-hound h4 { font-size: 1.05em; }
1023
+ .dpsp-admin-notice-opt-in-hound p:last-of-type { margin-bottom: 20px; }
1024
+ .dpsp-admin-notice-opt-in-hound a { text-decoration: none; }
1025
+ .dpsp-admin-notice-opt-in-hound img { position: absolute; top: 20px; left: 20px; border-radius: 50px; max-width: 100px; height: auto; }
1026
+
1027
+ .wrap div.dpsp-admin-notice.dpsp-admin-grow-notice {
1028
+ display: flex;
1029
+ flex-flow: row;
1030
+ }
1031
+
1032
+ @media screen and (max-width: 500px) {
1033
+ .wrap div.dpsp-admin-notice.dpsp-admin-grow-notice {
1034
+ flex-flow: column;
1035
+ }
1036
+
1037
+ }
1038
+
1039
+ .wrap div.dpsp-admin-notice .notice-img-wrap {
1040
+ padding: 1em;
1041
+ flex: 0 0 150px;
1042
+ }
1043
+
1044
+ .wrap div.dpsp-admin-notice .notice-img-wrap img {
1045
+ float: left;
1046
+ }
1047
+
1048
+ .wrap div.dpsp-admin-notice .notice-text-wrap {
1049
+ flex: 1 1 auto;
1050
+ }
1051
+
1052
+
1053
+ .wrap div.dpsp-admin-notice .notice-subtext {
1054
+ font-style: italic;
1055
+ font-size: 0.9em;
1056
+ }
1057
+
1058
+ /**********************************************/
1059
+ /* Feedback Form
1060
+ /**********************************************/
1061
+ #dpsp-feedback-form-overlay { display: none; z-index: 9999; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: #000; opacity: 0.35; }
1062
+ #dpsp-feedback-form { display: none; z-index: 10000; position: fixed; top: 10%; left: 50%; background: #fff; border-radius: 3px; max-width: 700px; margin-left: -350px; width: 100%; }
1063
+ #dpsp-feedback-form .dpsp-header { position: relative; background: rgba(52,152,219,0.75); padding: 27px 35px; }
1064
+ #dpsp-feedback-form > form { padding: 30px 35px; }
1065
+ #dpsp-feedback-form h2 { color: #fff; margin-top: 0; margin-bottom: 0; }
1066
+ #dpsp-feedback-form label { display: block; margin-bottom: 5px; font-weight: bold; }
1067
+ #dpsp-feedback-form textarea { width: 100%; margin-bottom: 10px; min-height: 80px; }
1068
+ #dpsp-feedback-form input[type=email],
1069
+ #dpsp-feedback-form input[type=text] { width: 50%; margin-bottom: 10px; }
1070
+ #dpsp-feedback-form input[type=submit] { margin-top: 15px; }
1071
+
1072
+ #dpsp-feedback-form .spinner { float: none; visibility: visible; margin-top: 19px; }
1073
+ #dpsp-feedback-form .dpsp-error { display: none; margin-top: 20px; margin-left: 15px; color: #c0392b; }
1074
+
1075
+ #dpsp-feedback-done { display: none; position: relative; padding: 35px 25px; }
1076
+ #dpsp-feedback-done img { float: left; }
1077
+ #dpsp-feedback-done:after { content: ''; display: block; clear: both; }
1078
+
1079
+ #dpsp-feedback-done > div { position: relative; float: left; top: -10px; margin-left: 40px; background: #f1f1f1; border-radius: 10px; padding: 10px 20px; max-width: 400px; }
1080
+ #dpsp-feedback-done > div p { font-size: 1.1em; }
1081
+ #dpsp-feedback-done > div p:first-of-type { font-weight: bold; }
1082
+ #dpsp-feedback-done > div:before { content: ''; display: block; position: absolute; left: -30px; bottom: 10px; width: 25px; height: 25px; border-radius: 50%; background: #f1f1f1; }
1083
+ #dpsp-feedback-done > div:after { content: ''; display: block; position: absolute; left: -50px; bottom: 20px; width: 15px; height: 15px; border-radius: 50%; background: #f1f1f1; }
1084
+ #dpsp-feedback-done > a { position: absolute; bottom: 35px; right: 35px; }
1085
+
1086
+ #dpsp-close-feedback { position: absolute; right: 25px; top: 50%; margin-top: -10px; color: #fff; text-decoration: none; }
1087
+
1088
+
1089
+ /**********************************************/
1090
+ /* Meta-box: Statistics
1091
+ /**********************************************/
1092
+ .dpsp-statistic-bars-wrapper { padding-top: 10px; }
1093
+ .dpsp-statistic-bars-wrapper:after { content: ''; display: block; width: 0; clear: both; }
1094
+
1095
+ .dpsp-statistic-bar-header { opacity: 0.6; margin-bottom: 10px; padding-bottom: 5px; border-bottom: 1px solid #f1f1f1; }
1096
+ .dpsp-statistic-bar-wrapper.dpsp-statistic-bar-header:hover { background: none; }
1097
+
1098
+ .dpsp-statistic-bar-wrapper { position: relative; height: 30px; padding-left: 110px; padding-right: 110px; transition: opacity 0.2s ease-in-out; }
1099
+ .dpsp-statistic-bar-wrapper:hover { background: #f7f7f7; }
1100
+ .dpsp-statistic-bar-wrapper label { position: absolute; left: 10px; top: 0; height: 30px; width: 109px; line-height: 30px; font-weight: bold; font-size: 12px; }
1101
+ .dpsp-statistic-bar-wrapper .dpsp-network-share-count { position: absolute; top: 0; right: 0; height: 30px; width: 110px; line-height: 30px; font-weight: bold; font-size: 12px; }
1102
+ .dpsp-statistic-bar-wrapper .dpsp-network-share-count .dpsp-count { display: inline-block; width: 55px; text-align: center; }
1103
+ .dpsp-statistic-bar-wrapper .dpsp-network-share-count .dpsp-percentage { display: inline-block; width: 40px; text-align: center; }
1104
+ .dpsp-statistic-bar-wrapper .dpsp-network-share-count .dpsp-divider { width: 1px; margin: 0 2px; opacity: 0.5; }
1105
+ .dpsp-statistic-bar-wrapper .dpsp-statistic-bar { position: relative; top: 10px; height: 10px; width: 100%; background: #e7e7e7; border-radius: 5px; }
1106
+ .dpsp-statistic-bar-wrapper .dpsp-statistic-bar-inner { height: 10px; width: 0; border-radius: 5px; }
1107
+
1108
+ .dpsp-statistic-bar-wrapper .dpsp-statistic-bar-facebook .dpsp-statistic-bar-inner { background: #3a579a; }
1109
+ .dpsp-statistic-bar-wrapper .dpsp-statistic-bar-twitter .dpsp-statistic-bar-inner { background: #00abf0; }
1110
+ .dpsp-statistic-bar-wrapper .dpsp-statistic-bar-google-plus .dpsp-statistic-bar-inner { background: #df4a32; }
1111
+ .dpsp-statistic-bar-wrapper .dpsp-statistic-bar-pinterest .dpsp-statistic-bar-inner { background: #c92228; }
1112
+ .dpsp-statistic-bar-wrapper .dpsp-statistic-bar-linkedin .dpsp-statistic-bar-inner { background: #0077b5; }
1113
+ .dpsp-statistic-bar-wrapper .dpsp-statistic-bar-stumbleupon .dpsp-statistic-bar-inner { background: #ec4b24; }
1114
+ .dpsp-statistic-bar-wrapper .dpsp-statistic-bar-reddit .dpsp-statistic-bar-inner { background: #ff5700; }
1115
+ .dpsp-statistic-bar-wrapper .dpsp-statistic-bar-vkontakte .dpsp-statistic-bar-inner { background: #4d75a3; }
1116
+
1117
+ .dpsp-statistic-bar-footer { opacity: 0.6; margin: 10px 0; border-top: 1px solid #f1f1f1; border-bottom: 1px solid #f1f1f1; }
1118
+ .dpsp-statistic-bar-wrapper.dpsp-statistic-bar-footer:hover { background: none; }
1119
+
1120
+ #dpsp-refresh-share-counts-wrapper:after { content: ''; display: block; width: 0; clear: both; }
1121
+ #dpsp-refresh-share-counts { float: right; }
1122
+
1123
+
1124
+ /**********************************************/
1125
+ /* Opt-in Hound Promo
1126
+ /**********************************************/
1127
+ #opt-in-hound-promo-box { background: #fff; max-width: 800px; margin: 35px auto; border-radius: 4px; overflow: hidden; box-shadow: 0 0 20px 4px #e9e9e9; }
1128
+ #opt-in-hound-promo-box img { max-width: 100%; height: auto; }
1129
+ #opt-in-hound-promo-box hr { margin: 50px 0; }
1130
+
1131
+ #opt-in-hound-promo-box-banner { position: relative; }
1132
+
1133
+ #opt-in-hound-promo-box-inner { padding: 0 50px; }
1134
+
1135
+ #opt-in-hound-promo-box .opt-in-hound-promo-box-title { font-size: 28px; font-weight: bold; margin: 15px 0; }
1136
+ #opt-in-hound-promo-box .opt-in-hound-promo-box-title span { font-weight: 300; font-size: 22px; }
1137
+ #opt-in-hound-promo-box .opt-in-hound-promo-box-sub-title { font-size: 20px; font-weight: 300; line-height: 1.3; }
1138
+
1139
+ #opt-in-hound-promo-box .opt-in-hound-promo-box-title,
1140
+ #opt-in-hound-promo-box .opt-in-hound-promo-box-sub-title { text-align: center; color: #4d5b68; }
1141
+
1142
+ #opt-in-hound-promo-box .dpsp-row { margin-bottom: 35px; }
1143
+ #opt-in-hound-promo-box .dpsp-row .opt-in-hound-promo-box-sub-title { margin-top: 0; }
1144
+
1145
+ #opt-in-hound-promo-box .dpsp-col-1-3 { text-align: center; }
1146
+ #opt-in-hound-promo-box .dpsp-col-1-4 { border-right: 1px solid #f1f1f1; }
1147
+ #opt-in-hound-promo-box .dpsp-col-1-4.dpsp-last { border-right: 0; }
1148
+
1149
+ #opt-in-hound-promo-box .dpsp-col-1-4 img { margin: -20px 0; }
1150
+
1151
+ #opt-in-hound-promo-box .opt-in-hound-promo-box-cta { text-align: center; margin: 35px 0; }
1152
+ #opt-in-hound-promo-box .opt-in-hound-promo-box-cta.dpsp-last { margin: 35px 0 50px 0; }
1153
+ #opt-in-hound-promo-box .opt-in-hound-promo-box-cta .button-primary { font-size: 120%; font-weight: 500; height: 38px; line-height: 34px; padding: 0 25px; }
1154
+
1155
+ #opt-in-hound-promo-box-disclaimer { max-width: 800px; margin: 0 auto; font-size: 12px; color: #a1a1a1; }
1156
+
1157
+ .dpsp-page-extensions.dpsp-sub-page-opt-in-hound div.notice { display: none; }
1158
+
1159
+ /**********************************************/
1160
+ /* Deactivation Form
1161
+ /**********************************************/
1162
+ #dpsp-deactivate-modal { display: none; z-index: 9999; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,.35); }
1163
+ #dpsp-deactivate-wrapper { z-index: 10000; position: fixed; top: 10%; left: 50%; background: #fff; border-radius: 4px; max-width: 700px; margin-left: -350px; width: 100%; overflow: hidden; }
1164
+
1165
+ #dpsp-deactivate-wrapper p { margin-top: 0; margin-bottom: 10px; }
1166
+ #dpsp-deactivate-wrapper hr { margin: 25px 0; border: 0; border-top: 1px solid #e1e1e1; }
1167
+
1168
+ #dpsp-deactivate-wrapper textarea { min-height: 65px; width: 100%; }
1169
+ #dpsp-deactivate-wrapper .dpsp-deactivate-close { line-height: 26px; margin-left: 10px; }
1170
+
1171
+ #dpsp-deactivate-contact-me { display: none; }
1172
+ #dpsp-deactivate-contact-me label { display: block; margin-bottom: 10px; }
1173
+ #dpsp-deactivate-contact-me input[type=email] { display: block; min-width: 250px; width: 50%; }
1174
+
1175
+ #dpsp-deactivate-header { position: relative; padding: 25px 20px 22px 20px; background: #f5f5f5; border-bottom: 1px solid #e1e1e1; overflow: hidden; }
1176
+
1177
+ #dpsp-deactivate-header img { position: absolute; right: 15px; top: auto; bottom: -29px; max-width: 80px; }
1178
+ #dpsp-deactivate-header h3 { margin: 0; }
1179
+
1180
+ #dpsp-deactivate-inner { padding: 20px 20px 25px; }
1181
+
1182
+ #dpsp-deactivate-footer { padding: 20px; background: #f5f5f5; border-top: 1px solid #e1e1e1; }
1183
+ #dpsp-deactivate-footer a:last-of-type { float: right; }
1184
+
1185
+ /************************************************************/
1186
+ /* Browser Window Sketch
1187
+ /************************************************************/
1188
+ .browser-window {
1189
+ border: 1px solid rgba(52,152,219,0.75);
1190
+ border-radius: 5px;
1191
+ line-height: 0;
1192
+ overflow: hidden;
1193
+ }
1194
+ .browser-header {
1195
+ text-align: left;
1196
+ border-bottom: 1px solid rgba(52,152,219,0.75);
1197
+ height: 20px;
1198
+ }
1199
+ .browser-header:before {
1200
+ display: block;
1201
+ content: '○ ○ ○';
1202
+ position: relative;
1203
+ top: 10px;
1204
+ left: 7px;
1205
+ font-size: 20px;
1206
+ color: rgba(52,152,219,0.75);
1207
+ }
1208
+
1209
+ /**********************************************/
1210
+ /* Mobile Display
1211
+ /**********************************************/
1212
+ @media screen and ( max-width : 785px ) {
1213
+
1214
+ .dpsp-page-title-wrapper h2 {
1215
+ position: relative;
1216
+ padding-right: 50px;
1217
+ }
1218
+
1219
+ .dpsp-page-title-wrapper h2 .dpsp-switch {
1220
+ position: absolute;
1221
+ top: 15px;
1222
+ right: 0;
1223
+ }
1224
+
1225
+ .dpsp-social-platforms-sort-list {
1226
+ overflow: auto;
1227
+ }
1228
+
1229
+ }
1230
+
1231
+ @media screen and ( max-width : 720px ) {
1232
+
1233
+ .dpsp-col-1-4 {
1234
+ width: 50%;
1235
+ }
1236
+
1237
+ #dpsp-networks-selector li {
1238
+ width: 100%;
1239
+ padding: 0;
1240
+ }
1241
+
1242
+ #dpsp-networks-selector-footer {
1243
+ text-align: center;
1244
+ }
1245
+
1246
+ .dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper {
1247
+ width: auto;
1248
+ }
1249
+
1250
+ .dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper input,
1251
+ .dpsp-page-sidebar .dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper input:focus,
1252
+ .dpsp-page-sidebar .dpsp-social-platforms-sort-list li .dpsp-list-input-wrapper:hover input {
1253
+ width: 150px;
1254
+ padding-right: 10px;
1255
+ }
1256
+
1257
+ .dpsp-settings-button-style {
1258
+ width: auto;
1259
+ }
1260
+
1261
+ .dpsp-page-content .dpsp-settings-button-style {
1262
+ width: 49.5%;
1263
+ }
1264
+
1265
+ .dpsp-page-content .dpsp-section-button-style label:nth-of-type(4n) {
1266
+ margin-right: 1%;
1267
+ }
1268
+
1269
+ .dpsp-page-content .dpsp-section-button-style label:nth-of-type(2n) {
1270
+ margin-right: 0;
1271
+ }
1272
+
1273
+ .dpsp-setting-field-label {
1274
+ width: 100%;
1275
+ margin-bottom: 10px;
1276
+ }
1277
+
1278
+ .dpsp-setting-field-wrapper {
1279
+ margin-bottom: 30px;
1280
+ }
1281
+
1282
+ }
assets/src/css/style-frontend-jquery.css ADDED
@@ -0,0 +1,699 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*****************************************/
2
+ /* General: Fonts
3
+ /*****************************************/
4
+ @font-face {
5
+ font-family: 'Social Pug';
6
+ src:url('../fonts/socialpug.eot?gd6mr8');
7
+ src:url('../fonts/socialpug.eot?#iefix') format('embedded-opentype'),
8
+ url('../fonts/socialpug.woff') format('woff'),
9
+ url('../fonts/socialpug.ttf') format('truetype'),
10
+ url('../fonts/socialpug.svg#socialpug') format('svg');
11
+ font-weight: normal;
12
+ font-style: normal;
13
+ }
14
+
15
+
16
+ /*****************************************/
17
+ /* General: Icons
18
+ /*****************************************/
19
+ .dpsp-icon-total-share:before {
20
+ position: absolute;
21
+ top: 50%;
22
+ left: 50%;
23
+ margin-top: -10px;
24
+ margin-left: -10px;
25
+ width: 20px;
26
+ height: 20px;
27
+ vertical-align: middle;
28
+ line-height: 20px;
29
+ }
30
+
31
+
32
+ .dpsp-icon-total-share:before {
33
+ font-family: "Social Pug";
34
+ font-style: normal;
35
+ font-weight: normal;
36
+
37
+ display: inline-block;
38
+ text-decoration: inherit;
39
+ text-align: center;
40
+ font-variant: normal;
41
+ text-transform: none;
42
+ line-height: 1em;
43
+ }
44
+
45
+ .dpsp-network-btn .dpsp-network-icon:before,
46
+ .dpsp-network-btn .dpsp-network-icon:after {
47
+ font-family: "Social Pug";
48
+ font-style: normal;
49
+ font-weight: normal;
50
+
51
+ display: block;
52
+ text-decoration: inherit;
53
+ text-align: center;
54
+ font-variant: normal;
55
+ text-transform: none;
56
+
57
+ position: absolute;
58
+ top: 50%;
59
+ left: 50%;
60
+ margin-top: -10px;
61
+ margin-left: -10px;
62
+ width: 20px;
63
+ height: 20px;
64
+ vertical-align: middle;
65
+ line-height: 20px;
66
+ }
67
+
68
+ .dpsp-network-btn .dpsp-network-icon:after {
69
+ margin-left: -20px;
70
+ opacity: 0;
71
+ }
72
+
73
+ .dpsp-icon-total-share:before { content: '\e883'; }
74
+
75
+ .dpsp-facebook .dpsp-network-icon:before,
76
+ .dpsp-facebook .dpsp-network-icon:after { content: '\e800'; }
77
+ .dpsp-twitter .dpsp-network-icon:before,
78
+ .dpsp-twitter .dpsp-network-icon:after { content: '\e801'; }
79
+ .dpsp-pinterest .dpsp-network-icon:before,
80
+ .dpsp-pinterest .dpsp-network-icon:after { content: '\e803'; }
81
+ .dpsp-linkedin .dpsp-network-icon:before,
82
+ .dpsp-linkedin .dpsp-network-icon:after { content: '\e804'; }
83
+ .dpsp-email .dpsp-network-icon:before,
84
+ .dpsp-email .dpsp-network-icon:after { content: '\e816'; }
85
+ .dpsp-print .dpsp-network-icon:before,
86
+ .dpsp-print .dpsp-network-icon:after { content: '\e817'; }
87
+
88
+ /* Button animations */
89
+ .dpsp-networks-btns-wrapper.dpsp-has-button-icon-animation .dpsp-network-btn:hover .dpsp-network-icon:before,
90
+ .dpsp-networks-btns-wrapper.dpsp-has-button-icon-animation .dpsp-network-btn:hover .dpsp-network-icon:after {
91
+ transition: all 0.25s ease-in-out;
92
+ }
93
+
94
+ .dpsp-networks-btns-wrapper.dpsp-has-button-icon-animation .dpsp-network-btn:hover .dpsp-network-icon:before {
95
+ margin-left: 5px;
96
+ opacity: 0;
97
+ }
98
+
99
+ .dpsp-networks-btns-wrapper.dpsp-has-button-icon-animation .dpsp-network-btn:hover .dpsp-network-icon:after {
100
+ margin-left: -10px;
101
+ opacity: 1;
102
+ }
103
+
104
+ /*****************************************/
105
+ /* Floating Sidebar Buttons
106
+ /*****************************************/
107
+ #dpsp-floating-sidebar {
108
+ position: fixed;
109
+ top: 30%;
110
+ z-index: 9998;
111
+ }
112
+
113
+ #dpsp-floating-sidebar.dpsp-position-left {
114
+ left: 0;
115
+ }
116
+
117
+ #dpsp-floating-sidebar.dpsp-position-right {
118
+ right: 0;
119
+ }
120
+
121
+ .dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar li {
122
+ float: none;
123
+ margin-left: 0;
124
+ }
125
+
126
+ .dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn {
127
+ padding: 0;
128
+ width: 40px;
129
+ }
130
+
131
+ .dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon {
132
+ border-color: transparent !important;
133
+ background: transparent !important;
134
+ }
135
+
136
+ .dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-has-count .dpsp-network-icon {
137
+ height: 22px;
138
+ line-height: 22px;
139
+ }
140
+
141
+ .dpsp-button-hover .dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn:hover:before {
142
+ color: #fff;
143
+ }
144
+
145
+
146
+ /* Sidebar buttons option - rounded */
147
+ .dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn,
148
+ .dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon {
149
+ border-radius: 0;
150
+ }
151
+
152
+ .dpsp-position-left.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-first,
153
+ .dpsp-position-left.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-first .dpsp-network-icon {
154
+ -webkit-border-top-right-radius: 5px;
155
+ -moz-border-radius-topright: 5px;
156
+ border-top-right-radius: 5px;
157
+ }
158
+
159
+ .dpsp-position-left.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-last,
160
+ .dpsp-position-left.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-last .dpsp-network-icon {
161
+ -webkit-border-bottom-right-radius: 5px;
162
+ -moz-border-radius-bottomright: 5px;
163
+ border-bottom-right-radius: 5px;
164
+ }
165
+
166
+ .dpsp-position-left.dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn,
167
+ .dpsp-position-left.dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon {
168
+ -webkit-border-top-right-radius: 5px;
169
+ -moz-border-radius-topright: 5px;
170
+ border-top-right-radius: 5px;
171
+ -webkit-border-bottom-right-radius: 5px;
172
+ -moz-border-radius-bottomright: 5px;
173
+ border-bottom-right-radius: 5px;
174
+ }
175
+
176
+
177
+ .dpsp-position-right.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-first,
178
+ .dpsp-position-right.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-first .dpsp-network-icon {
179
+ -webkit-border-top-left-radius: 5px;
180
+ -moz-border-radius-topleft: 5px;
181
+ border-top-left-radius: 5px;
182
+ }
183
+
184
+ .dpsp-position-right.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-last,
185
+ .dpsp-position-right.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-last .dpsp-network-icon {
186
+ -webkit-border-bottom-left-radius: 5px;
187
+ -moz-border-radius-bottomleft: 5px;
188
+ border-bottom-left-radius: 5px;
189
+ }
190
+
191
+ .dpsp-position-right.dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn,
192
+ .dpsp-position-right.dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon {
193
+ -webkit-border-top-left-radius: 5px;
194
+ -moz-border-radius-topleft: 5px;
195
+ border-top-left-radius: 5px;
196
+ -webkit-border-bottom-left-radius: 5px;
197
+ -moz-border-radius-bottomleft: 5px;
198
+ border-bottom-left-radius: 5px;
199
+ }
200
+
201
+ .dpsp-shape-rounded.dpsp-has-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon {
202
+ border-radius: 5px;
203
+ }
204
+
205
+ /* Sidebar buttons option - circle */
206
+ #dpsp-floating-sidebar.dpsp-position-left.dpsp-shape-circle {
207
+ left: 12px;
208
+ }
209
+
210
+ #dpsp-floating-sidebar.dpsp-position-right.dpsp-shape-circle {
211
+ right: 10px;
212
+ }
213
+
214
+ /* Sidebar buttons bottom spacing */
215
+ .dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn {
216
+ margin-bottom: 6px;
217
+ }
218
+
219
+ .dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn {
220
+ -webkit-border-top-right-radius: 5px;
221
+ -moz-border-radius-topright: 5px;
222
+ border-top-right-radius: 5px;
223
+
224
+ -webkit-border-bottom-right-radius: 5px;
225
+ -moz-border-radius-bottomright: 5px;
226
+ border-bottom-right-radius: 5px;
227
+ }
228
+
229
+ /*
230
+ * Sidebar buttons style 2
231
+ */
232
+ #dpsp-floating-sidebar.dpsp-style-2 .dpsp-network-btn:before {
233
+ background: none;
234
+ }
235
+
236
+ /**
237
+ * Sidebar button hover label
238
+ *
239
+ */
240
+ #dpsp-floating-sidebar .dpsp-networks-btns-wrapper li { position: relative; overflow: visible; }
241
+
242
+ #dpsp-floating-sidebar .dpsp-networks-btns-wrapper .dpsp-button-label { position: absolute; z-index: 1; display: inline-block; width: auto; white-space: nowrap; top: 50%; margin-top: -15px; height: 30px; padding: 6px 12px; color: #fff; font-size: 12px; font-weight: normal; line-height: 18px; background: #34495e; border-radius: 3px; visibility: hidden; opacity: 0; transition: all 0.2s ease-in-out; box-sizing: border-box; }
243
+ #dpsp-floating-sidebar.dpsp-position-left .dpsp-networks-btns-wrapper .dpsp-button-label { left: 100%; }
244
+ #dpsp-floating-sidebar.dpsp-position-right .dpsp-networks-btns-wrapper .dpsp-button-label { right: 100%; }
245
+
246
+ #dpsp-floating-sidebar.dpsp-position-left .dpsp-networks-btns-wrapper li.dpsp-hover .dpsp-button-label { transform: translateX(10px); visibility: visible; opacity: 1; }
247
+ #dpsp-floating-sidebar.dpsp-position-right .dpsp-networks-btns-wrapper li.dpsp-hover .dpsp-button-label { transform: translateX(-10px); visibility: visible; opacity: 1; }
248
+
249
+ #dpsp-floating-sidebar .dpsp-networks-btns-wrapper .dpsp-button-label:before { content: ''; display: block; position: absolute; top: 50%; margin-top: -5px; border-top: 5px solid transparent; border-bottom: 5px solid transparent; }
250
+ #dpsp-floating-sidebar.dpsp-position-left .dpsp-networks-btns-wrapper .dpsp-button-label:before { left: -5px; border-right: 5px solid #34495e; }
251
+ #dpsp-floating-sidebar.dpsp-position-right .dpsp-networks-btns-wrapper .dpsp-button-label:before { right: -5px; border-left: 5px solid #34495e; }
252
+
253
+
254
+ /*****************************************/
255
+ /* Content Buttons
256
+ /*****************************************/
257
+ #dpsp-content-top { margin-bottom: 1.2em; }
258
+ #dpsp-content-bottom { margin-top: 1.2em; }
259
+
260
+ .dpsp-share-text { font-weight: bold; margin-bottom: 10px; }
261
+
262
+ /**************************************************/
263
+ /* General button styling, for content and other
264
+ /**************************************************/
265
+ .dpsp-networks-btns-wrapper {
266
+ list-style: none !important;
267
+ padding: 0 !important;
268
+ margin: 0 !important;
269
+ }
270
+
271
+ .dpsp-networks-btns-wrapper:after {
272
+ content: '';
273
+ display: block;
274
+ height: 0;
275
+ clear: both;
276
+ }
277
+
278
+ .dpsp-networks-btns-wrapper li {
279
+ float: left;
280
+ overflow: hidden;
281
+
282
+ -moz-transition: all 0.15s ease-in;
283
+ -webkit-transition: all 0.15s ease-in;
284
+ -o-transition: all 0.15s ease-in;
285
+ transition: all 0.15s ease-in;
286
+
287
+ list-style-type: none !important;
288
+ }
289
+
290
+ .dpsp-networks-btns-wrapper li:before {
291
+ display: none !important;
292
+ }
293
+
294
+ .dpsp-networks-btns-wrapper li:first-child {
295
+ margin-left: 0 !important;
296
+ }
297
+
298
+ /*
299
+ * Share button
300
+ */
301
+ .dpsp-networks-btns-wrapper .dpsp-network-btn {
302
+ position: relative;
303
+
304
+ display: block;
305
+ text-decoration: none !important;
306
+ text-transform: unset !important;
307
+ height: 40px;
308
+ min-width: 40px;
309
+
310
+ font-family: 'Arial';
311
+ font-weight: bold;
312
+ font-size: 14px;
313
+ line-height: 36px;
314
+ vertical-align: middle;
315
+
316
+ padding: 0 10px 0 48px;
317
+ border: 2px solid;
318
+ max-height: 40px;
319
+
320
+ width: 100%;
321
+ -moz-box-sizing: border-box;
322
+ box-sizing: border-box;
323
+
324
+ -moz-transition: all 0.15s ease-in;
325
+ -webkit-transition: all 0.15s ease-in;
326
+ -o-transition: all 0.15s ease-in;
327
+ transition: all 0.15s ease-in;
328
+
329
+ box-shadow: none;
330
+
331
+ cursor: pointer;
332
+ }
333
+
334
+ .dpsp-networks-btns-wrapper .dpsp-network-btn:hover {
335
+ border: 2px solid;
336
+ box-shadow: none;
337
+ }
338
+
339
+ .dpsp-networks-btns-wrapper .dpsp-network-btn:focus {
340
+ border: 2px solid;
341
+ box-shadow: none;
342
+ }
343
+
344
+ .dpsp-networks-btns-wrapper .dpsp-network-btn:after {
345
+ content: '';
346
+ display: block;
347
+ height: 0;
348
+ clear: both;
349
+ }
350
+
351
+
352
+ /*
353
+ * Button icon
354
+ */
355
+ .dpsp-networks-btns-wrapper .dpsp-network-btn .dpsp-network-icon {
356
+ position: absolute;
357
+ top: -2px;
358
+ left: -2px;
359
+ bottom: -2px;
360
+ float: left;
361
+ display: block;
362
+ font-size: 14px;
363
+ line-height: 36px;
364
+ width: 40px;
365
+ text-align: center;
366
+ vertical-align: middle;
367
+ border: 2px solid;
368
+
369
+ -moz-box-sizing: border-box;
370
+ box-sizing: border-box;
371
+
372
+ -moz-transition: all 0.15s ease-in;
373
+ -webkit-transition: all 0.15s ease-in;
374
+ -o-transition: all 0.15s ease-in;
375
+ transition: all 0.15s ease-in;
376
+ }
377
+
378
+
379
+ /*
380
+ * Buttons with no labels
381
+ */
382
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-no-label {
383
+ padding: 0 18px;
384
+ }
385
+
386
+ .dpsp-button-style-1 .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-no-label .dpsp-network-icon {
387
+ width: auto;
388
+ right: -2px;
389
+ }
390
+
391
+
392
+ /*
393
+ * Button label
394
+ */
395
+ .dpsp-has-buttons-count .dpsp-networks-btns-wrapper .dpsp-network-label {
396
+ margin-right: 10px;
397
+ }
398
+
399
+ .dpsp-networks-btns-wrapper .dpsp-network-btn .dpsp-network-count {
400
+ font-size: 13px;
401
+ }
402
+
403
+ .dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-count {
404
+ position: absolute;
405
+ bottom: 0;
406
+ left: 0;
407
+ width: 100%;
408
+ margin-left: 0;
409
+ font-size: 11px;
410
+ text-align: center;
411
+ height: 20px;
412
+ line-height: 20px;
413
+ }
414
+
415
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-no-label .dpsp-network-label-wrapper {
416
+ display: none;
417
+ }
418
+
419
+
420
+ /*
421
+ * Buttons columns
422
+ */
423
+ .dpsp-column-1 .dpsp-networks-btns-wrapper li { width: 100%; }
424
+ .dpsp-column-1.dpsp-has-spacing .dpsp-networks-btns-wrapper li { margin-right: 0; }
425
+
426
+ .dpsp-column-2 .dpsp-networks-btns-wrapper li { width: 50%; }
427
+ .dpsp-column-2.dpsp-has-spacing .dpsp-networks-btns-wrapper li { width: 49%; }
428
+ .dpsp-column-2 .dpsp-networks-btns-wrapper li:nth-child(2n) { margin-right: 0; }
429
+
430
+ .dpsp-column-3 .dpsp-networks-btns-wrapper li { width: 33.3333%; }
431
+ .dpsp-column-3.dpsp-has-spacing .dpsp-networks-btns-wrapper li { width: 32%; }
432
+ .dpsp-column-3 .dpsp-networks-btns-wrapper li:nth-child(3n) { margin-right: 0; }
433
+
434
+ .dpsp-column-4 .dpsp-networks-btns-wrapper li { width: 25%; }
435
+ .dpsp-column-4.dpsp-has-spacing .dpsp-networks-btns-wrapper li { width: 23.5%; }
436
+ .dpsp-column-4 .dpsp-networks-btns-wrapper li:nth-child(4n) { margin-right: 0; }
437
+
438
+ .dpsp-column-5 .dpsp-networks-btns-wrapper li { width: 20%; }
439
+ .dpsp-column-5.dpsp-has-spacing .dpsp-networks-btns-wrapper li { width: 18.4%; }
440
+ .dpsp-column-5 .dpsp-networks-btns-wrapper li:nth-child(5n) { margin-right: 0; }
441
+
442
+ .dpsp-column-6 .dpsp-networks-btns-wrapper li { width: 16.6666%; }
443
+ .dpsp-column-6.dpsp-has-spacing .dpsp-networks-btns-wrapper li { width: 15%; }
444
+ .dpsp-column-6 .dpsp-networks-btns-wrapper li:nth-child(6n) { margin-right: 0; }
445
+
446
+ .dpsp-column-2 .dpsp-networks-btns-wrapper .dpsp-network-btn,
447
+ .dpsp-column-3 .dpsp-networks-btns-wrapper .dpsp-network-btn,
448
+ .dpsp-column-4 .dpsp-networks-btns-wrapper .dpsp-network-btn,
449
+ .dpsp-column-5 .dpsp-networks-btns-wrapper .dpsp-network-btn,
450
+ .dpsp-column-6 .dpsp-networks-btns-wrapper .dpsp-network-btn { padding-right: 10px; }
451
+
452
+ /*
453
+ * let buttons respect the space of their siblings and wrap when needed
454
+ */
455
+ .article .dpsp-networks-btns-wrapper {
456
+ display: flex;
457
+ flex-wrap: wrap;
458
+ justify-content: center;
459
+ }
460
+
461
+ .article ul.dpsp-networks-btns-wrapper li {
462
+ flex: 0 0 auto;
463
+ float: none;
464
+ margin: 5px;
465
+ width: auto;
466
+ }
467
+
468
+ /*
469
+ * Buttons width no labels
470
+ */
471
+ .dpsp-no-labels .dpsp-networks-btns-wrapper .dpsp-network-btn { padding: 0; text-align: center; }
472
+ .dpsp-no-labels:not(.dpsp-column-auto) .dpsp-networks-btns-wrapper .dpsp-network-btn:before { position: relative; left: 0; float: none; display: inline-block; }
473
+
474
+
475
+ /*
476
+ * Buttons colors
477
+ */
478
+ /* Facebook */
479
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-facebook .dpsp-network-icon,
480
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-facebook {
481
+ border-color: #3a579a;
482
+ background: #3a579a;
483
+ color: #3a579a;
484
+ }
485
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-facebook:hover .dpsp-network-icon,
486
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-facebook:hover {
487
+ border-color: #334d87;
488
+ background: #334d87;
489
+ color: #334d87;
490
+ }
491
+
492
+ /* Twitter */
493
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-twitter .dpsp-network-icon,
494
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-twitter {
495
+ border-color: #00abf0;
496
+ background: #00abf0;
497
+ color: #00abf0;
498
+ }
499
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-twitter:hover .dpsp-network-icon,
500
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-twitter:hover {
501
+ border-color: #0099d7;
502
+ background: #0099d7;
503
+ color: #0099d7;
504
+ }
505
+
506
+ /* Pinterest */
507
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-pinterest .dpsp-network-icon,
508
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-pinterest {
509
+ border-color: #c92228;
510
+ background: #c92228;
511
+ color: #c92228;
512
+ }
513
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-pinterest:hover .dpsp-network-icon,
514
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-pinterest:hover {
515
+ border-color: #b31e24;
516
+ background: #b31e24;
517
+ color: #b31e24;
518
+ }
519
+
520
+ /* LinkedIn */
521
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-linkedin .dpsp-network-icon,
522
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-linkedin {
523
+ border-color: #0077b5;
524
+ background: #0077b5;
525
+ color: #0077b5;
526
+ }
527
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-linkedin:hover .dpsp-network-icon,
528
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-linkedin:hover {
529
+ border-color: #00669c;
530
+ background: #00669c;
531
+ color: #00669c;
532
+ }
533
+
534
+ /* Email */
535
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-email .dpsp-network-icon,
536
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-email {
537
+ border-color: #27ae60;
538
+ background: #27ae60;
539
+ color: #27ae60;
540
+ }
541
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-email:hover .dpsp-network-icon,
542
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-email:hover {
543
+ border-color: #239e57;
544
+ background: #239e57;
545
+ color: #239e57;
546
+ }
547
+
548
+ /* Print */
549
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-print .dpsp-network-icon,
550
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-print {
551
+ border-color: #bdc3c7;
552
+ background: #bdc3c7;
553
+ color: #bdc3c7;
554
+ }
555
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-print:hover .dpsp-network-icon,
556
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-print:hover {
557
+ border-color: #afb6bb;
558
+ background: #afb6bb;
559
+ color: #afb6bb;
560
+ }
561
+
562
+
563
+ /* Sidebar needs color white for icons */
564
+ .dpsp-has-button-background .dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn:before {
565
+ color: #fff;
566
+ }
567
+
568
+ /*
569
+ * Buttons Shapes
570
+ */
571
+ .dpsp-shape-rounded .dpsp-network-btn,
572
+ .dpsp-shape-rounded .dpsp-network-btn .dpsp-network-icon {
573
+ -webkit-border-top-left-radius: 5px;
574
+ -webkit-border-bottom-left-radius: 5px;
575
+ -moz-border-radius-topleft: 5px;
576
+ -moz-border-radius-bottomleft: 5px;
577
+ border-top-left-radius: 5px;
578
+ border-bottom-left-radius: 5px;
579
+ }
580
+
581
+ .dpsp-shape-rounded .dpsp-network-btn,
582
+ .dpsp-shape-rounded .dpsp-no-label.dpsp-network-btn .dpsp-network-icon {
583
+ -webkit-border-top-right-radius: 5px;
584
+ -webkit-border-bottom-right-radius: 5px;
585
+ -moz-border-radius-topright: 5px;
586
+ -moz-border-radius-bottomright: 5px;
587
+ border-top-right-radius: 5px;
588
+ border-bottom-right-radius: 5px;
589
+ }
590
+
591
+ .dpsp-shape-circle .dpsp-network-btn { border-radius: 30px; }
592
+ .dpsp-shape-circle .dpsp-network-btn .dpsp-network-icon { border-radius: 30px; overflow: hidden; }
593
+
594
+ /*
595
+ * Buttons Margins/Spacings
596
+ */
597
+ .dpsp-has-spacing .dpsp-networks-btns-wrapper li { margin-bottom: 10px; margin-right: 2%; margin-left: 0 !important; }
598
+
599
+
600
+ /*
601
+ * Buttons on mobile
602
+ */
603
+ @media screen and ( max-width : 720px ) {
604
+ .dpsp-hide-on-mobile {
605
+ display: none;
606
+ }
607
+ }
608
+
609
+
610
+ /*****************************************/
611
+ /* Button styles
612
+ /*****************************************/
613
+
614
+ /*
615
+ * Buttons Style 1
616
+ */
617
+ .dpsp-button-style-1 .dpsp-network-btn { color: #fff !important; padding-left: 38px; }
618
+ .dpsp-button-style-1 .dpsp-network-btn .dpsp-network-icon { color: #fff !important; }
619
+
620
+
621
+ /*****************************************/
622
+ /* Total shares
623
+ /*****************************************/
624
+ .dpsp-show-total-share-count {
625
+ position: relative;
626
+ }
627
+
628
+ .dpsp-total-share-wrapper {
629
+ position: relative;
630
+ font-family: 'Arial';
631
+ margin-top: 10px;
632
+ line-height: 1.345;
633
+ color: #5d6368;
634
+ }
635
+
636
+ .dpsp-total-share-wrapper .dpsp-icon-total-share:before {
637
+ font-size: 16px;
638
+ top: 7px;
639
+ left: -2px;
640
+ margin-top: 0;
641
+ margin-left: 0;
642
+ }
643
+
644
+ #dpsp-floating-sidebar .dpsp-total-share-wrapper {
645
+ margin-bottom: 10px;
646
+ }
647
+
648
+ #dpsp-floating-sidebar .dpsp-total-share-wrapper .dpsp-icon-total-share {
649
+ display: none;
650
+ }
651
+
652
+ .dpsp-total-share-wrapper span {
653
+ display: block;
654
+ font-size: 9px;
655
+ font-weight: bold;
656
+ text-transform: uppercase;
657
+ text-align: center;
658
+ }
659
+
660
+ .dpsp-total-share-wrapper .dpsp-total-share-count {
661
+ font-size: 15px;
662
+ line-height: 18px;
663
+ white-space: nowrap;
664
+ }
665
+
666
+ .dpsp-content-wrapper .dpsp-total-share-wrapper {
667
+ position: absolute;
668
+ width: 60px;
669
+ height: 40px;
670
+ margin-top: -21px;
671
+ top: 50%;
672
+ padding-left: 20px;
673
+ box-sizing: border-box;
674
+ }
675
+
676
+ .dpsp-content-wrapper.dpsp-show-total-share-count.dpsp-show-total-share-count-before {
677
+ padding-left: 70px;
678
+ }
679
+
680
+ .dpsp-content-wrapper.dpsp-show-total-share-count.dpsp-show-total-share-count-after {
681
+ padding-right: 70px;
682
+ }
683
+
684
+ .dpsp-content-wrapper.dpsp-show-total-share-count.dpsp-show-total-share-count-before .dpsp-total-share-wrapper {
685
+ left: 0;
686
+ }
687
+
688
+ .dpsp-content-wrapper.dpsp-show-total-share-count.dpsp-show-total-share-count-after .dpsp-total-share-wrapper {
689
+ right: 0;
690
+ }
691
+
692
+
693
+ @media print {
694
+
695
+ #dpsp-floating-sidebar,
696
+ .dpsp-share-text,
697
+ .dpsp-content-wrapper { display: none; }
698
+
699
+ }
assets/src/css/style-frontend.css ADDED
@@ -0,0 +1,685 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*****************************************/
2
+ /* General: Fonts
3
+ /*****************************************/
4
+ @font-face {
5
+ font-family: 'Social Pug';
6
+ src:url('../fonts/socialpug.eot?gd6mr8');
7
+ src:url('../fonts/socialpug.eot?#iefix') format('embedded-opentype'),
8
+ url('../fonts/socialpug.woff') format('woff'),
9
+ url('../fonts/socialpug.ttf') format('truetype'),
10
+ url('../fonts/socialpug.svg#socialpug') format('svg');
11
+ font-weight: normal;
12
+ font-style: normal;
13
+ font-display: swap;
14
+ }
15
+
16
+
17
+ /*****************************************/
18
+ /* General: Icons
19
+ /*****************************************/
20
+ .dpsp-icon-total-share:before {
21
+ position: absolute;
22
+ top: 50%;
23
+ left: 50%;
24
+ margin-top: -10px;
25
+ margin-left: -10px;
26
+ width: 20px;
27
+ height: 20px;
28
+ vertical-align: middle;
29
+ line-height: 20px;
30
+ }
31
+
32
+
33
+ .dpsp-icon-total-share:before {
34
+ font-family: "Social Pug";
35
+ font-style: normal;
36
+ font-weight: normal;
37
+
38
+ display: inline-block;
39
+ text-decoration: inherit;
40
+ text-align: center;
41
+ font-variant: normal;
42
+ text-transform: none;
43
+ line-height: 1em;
44
+ }
45
+
46
+ .dpsp-network-btn .dpsp-network-icon:before,
47
+ .dpsp-network-btn .dpsp-network-icon:after {
48
+ font-family: "Social Pug";
49
+ font-style: normal;
50
+ font-weight: normal;
51
+
52
+ display: block;
53
+ text-decoration: inherit;
54
+ text-align: center;
55
+ font-variant: normal;
56
+ text-transform: none;
57
+
58
+ position: absolute;
59
+ top: 50%;
60
+ left: 50%;
61
+ margin-top: -10px;
62
+ margin-left: -10px;
63
+ width: 20px;
64
+ height: 20px;
65
+ vertical-align: middle;
66
+ line-height: 20px;
67
+ }
68
+
69
+ .dpsp-network-btn .dpsp-network-icon:after {
70
+ margin-left: -20px;
71
+ opacity: 0;
72
+ }
73
+
74
+ .dpsp-icon-total-share:before { content: '\e883'; }
75
+
76
+ .dpsp-facebook .dpsp-network-icon:before,
77
+ .dpsp-facebook .dpsp-network-icon:after { content: '\e800'; }
78
+ .dpsp-twitter .dpsp-network-icon:before,
79
+ .dpsp-twitter .dpsp-network-icon:after { content: '\e801'; }
80
+ .dpsp-pinterest .dpsp-network-icon:before,
81
+ .dpsp-pinterest .dpsp-network-icon:after { content: '\e803'; }
82
+ .dpsp-linkedin .dpsp-network-icon:before,
83
+ .dpsp-linkedin .dpsp-network-icon:after { content: '\e804'; }
84
+ .dpsp-email .dpsp-network-icon:before,
85
+ .dpsp-email .dpsp-network-icon:after { content: '\e816'; }
86
+ .dpsp-print .dpsp-network-icon:before,
87
+ .dpsp-print .dpsp-network-icon:after { content: '\e817'; }
88
+
89
+ /* Button animations */
90
+ .dpsp-networks-btns-wrapper.dpsp-has-button-icon-animation .dpsp-network-btn:hover .dpsp-network-icon:before,
91
+ .dpsp-networks-btns-wrapper.dpsp-has-button-icon-animation .dpsp-network-btn:hover .dpsp-network-icon:after {
92
+ transition: all 0.25s ease-in-out;
93
+ }
94
+
95
+ .dpsp-networks-btns-wrapper.dpsp-has-button-icon-animation .dpsp-network-btn:hover .dpsp-network-icon:before {
96
+ margin-left: 5px;
97
+ opacity: 0;
98
+ }
99
+
100
+ .dpsp-networks-btns-wrapper.dpsp-has-button-icon-animation .dpsp-network-btn:hover .dpsp-network-icon:after {
101
+ margin-left: -10px;
102
+ opacity: 1;
103
+ }
104
+
105
+ /*****************************************/
106
+ /* Floating Sidebar Buttons
107
+ /*****************************************/
108
+ #dpsp-floating-sidebar {
109
+ position: fixed;
110
+ top: 50%;
111
+ transform: translateY(-50%);
112
+ z-index: 9998;
113
+ }
114
+
115
+ #dpsp-floating-sidebar.dpsp-position-left {
116
+ left: 0;
117
+ }
118
+
119
+ #dpsp-floating-sidebar.dpsp-position-right {
120
+ right: 0;
121
+ }
122
+
123
+ .dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar li {
124
+ float: none;
125
+ margin-left: 0;
126
+ }
127
+
128
+ .dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn {
129
+ padding: 0;
130
+ width: 40px;
131
+ }
132
+
133
+ .dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon {
134
+ border-color: transparent !important;
135
+ background: transparent !important;
136
+ }
137
+
138
+ .dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-has-count .dpsp-network-icon {
139
+ height: 22px;
140
+ line-height: 22px;
141
+ }
142
+
143
+ .dpsp-button-hover .dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn:hover:before {
144
+ color: #fff;
145
+ }
146
+
147
+
148
+ /* Sidebar buttons option - rounded */
149
+ .dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn,
150
+ .dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon {
151
+ border-radius: 0;
152
+ }
153
+
154
+ .dpsp-position-left.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-first,
155
+ .dpsp-position-left.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-first .dpsp-network-icon {
156
+ -webkit-border-top-right-radius: 5px;
157
+ -moz-border-radius-topright: 5px;
158
+ border-top-right-radius: 5px;
159
+ }
160
+
161
+ .dpsp-position-left.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-last,
162
+ .dpsp-position-left.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-last .dpsp-network-icon {
163
+ -webkit-border-bottom-right-radius: 5px;
164
+ -moz-border-radius-bottomright: 5px;
165
+ border-bottom-right-radius: 5px;
166
+ }
167
+
168
+ .dpsp-position-left.dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn,
169
+ .dpsp-position-left.dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon {
170
+ -webkit-border-top-right-radius: 5px;
171
+ -moz-border-radius-topright: 5px;
172
+ border-top-right-radius: 5px;
173
+ -webkit-border-bottom-right-radius: 5px;
174
+ -moz-border-radius-bottomright: 5px;
175
+ border-bottom-right-radius: 5px;
176
+ }
177
+
178
+
179
+ .dpsp-position-right.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-first,
180
+ .dpsp-position-right.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-first .dpsp-network-icon {
181
+ -webkit-border-top-left-radius: 5px;
182
+ -moz-border-radius-topleft: 5px;
183
+ border-top-left-radius: 5px;
184
+ }
185
+
186
+ .dpsp-position-right.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-last,
187
+ .dpsp-position-right.dpsp-shape-rounded .dpsp-networks-btns-sidebar .dpsp-network-btn.dpsp-last .dpsp-network-icon {
188
+ -webkit-border-bottom-left-radius: 5px;
189
+ -moz-border-radius-bottomleft: 5px;
190
+ border-bottom-left-radius: 5px;
191
+ }
192
+
193
+ .dpsp-position-right.dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn,
194
+ .dpsp-position-right.dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon {
195
+ -webkit-border-top-left-radius: 5px;
196
+ -moz-border-radius-topleft: 5px;
197
+ border-top-left-radius: 5px;
198
+ -webkit-border-bottom-left-radius: 5px;
199
+ -moz-border-radius-bottomleft: 5px;
200
+ border-bottom-left-radius: 5px;
201
+ }
202
+
203
+ .dpsp-shape-rounded.dpsp-has-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-icon {
204
+ border-radius: 5px;
205
+ }
206
+
207
+ /* Sidebar buttons option - circle */
208
+ #dpsp-floating-sidebar.dpsp-position-left.dpsp-shape-circle {
209
+ left: 12px;
210
+ }
211
+
212
+ #dpsp-floating-sidebar.dpsp-position-right.dpsp-shape-circle {
213
+ right: 10px;
214
+ }
215
+
216
+ /* Sidebar buttons bottom spacing */
217
+ .dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn {
218
+ margin-bottom: 6px;
219
+ }
220
+
221
+ .dpsp-shape-rounded.dpsp-bottom-spacing .dpsp-networks-btns-sidebar .dpsp-network-btn {
222
+ -webkit-border-top-right-radius: 5px;
223
+ -moz-border-radius-topright: 5px;
224
+ border-top-right-radius: 5px;
225
+
226
+ -webkit-border-bottom-right-radius: 5px;
227
+ -moz-border-radius-bottomright: 5px;
228
+ border-bottom-right-radius: 5px;
229
+ }
230
+
231
+ /*
232
+ * Sidebar buttons style 2
233
+ */
234
+ #dpsp-floating-sidebar.dpsp-style-2 .dpsp-network-btn:before {
235
+ background: none;
236
+ }
237
+
238
+ /**
239
+ * Sidebar button hover label
240
+ *
241
+ */
242
+ #dpsp-floating-sidebar .dpsp-networks-btns-wrapper li { position: relative; overflow: visible; }
243
+
244
+ #dpsp-floating-sidebar .dpsp-networks-btns-wrapper .dpsp-button-label { position: absolute; z-index: 1; display: inline-block; width: auto; white-space: nowrap; top: 50%; margin-top: -15px; height: 30px; padding: 6px 12px; color: #fff; font-size: 12px; font-weight: normal; line-height: 18px; background: #34495e; border-radius: 3px; visibility: hidden; opacity: 0; transition: all 0.2s ease-in-out; box-sizing: border-box; }
245
+ #dpsp-floating-sidebar.dpsp-position-left .dpsp-networks-btns-wrapper .dpsp-button-label { left: 100%; }
246
+ #dpsp-floating-sidebar.dpsp-position-right .dpsp-networks-btns-wrapper .dpsp-button-label { right: 100%; }
247
+
248
+ #dpsp-floating-sidebar.dpsp-position-left .dpsp-networks-btns-wrapper li.dpsp-hover .dpsp-button-label { transform: translateX(10px); visibility: visible; opacity: 1; }
249
+ #dpsp-floating-sidebar.dpsp-position-right .dpsp-networks-btns-wrapper li.dpsp-hover .dpsp-button-label { transform: translateX(-10px); visibility: visible; opacity: 1; }
250
+
251
+ #dpsp-floating-sidebar .dpsp-networks-btns-wrapper .dpsp-button-label:before { content: ''; display: block; position: absolute; top: 50%; margin-top: -5px; border-top: 5px solid transparent; border-bottom: 5px solid transparent; }
252
+ #dpsp-floating-sidebar.dpsp-position-left .dpsp-networks-btns-wrapper .dpsp-button-label:before { left: -5px; border-right: 5px solid #34495e; }
253
+ #dpsp-floating-sidebar.dpsp-position-right .dpsp-networks-btns-wrapper .dpsp-button-label:before { right: -5px; border-left: 5px solid #34495e; }
254
+
255
+
256
+ /*****************************************/
257
+ /* Content Buttons
258
+ /*****************************************/
259
+ #dpsp-content-top { margin-bottom: 1.2em; }
260
+ #dpsp-content-bottom { margin-top: 1.2em; }
261
+
262
+ .dpsp-share-text { font-weight: bold; margin-bottom: 10px; }
263
+
264
+ /**************************************************/
265
+ /* General button styling, for content and other
266
+ /**************************************************/
267
+ .dpsp-networks-btns-wrapper {
268
+ list-style: none !important;
269
+ padding: 0 !important;
270
+ margin: 0 !important;
271
+ }
272
+
273
+ .dpsp-networks-btns-wrapper:after {
274
+ content: '';
275
+ display: block;
276
+ height: 0;
277
+ clear: both;
278
+ }
279
+
280
+ .dpsp-networks-btns-wrapper li {
281
+ float: left;
282
+ overflow: hidden;
283
+
284
+ -moz-transition: all 0.15s ease-in;
285
+ -webkit-transition: all 0.15s ease-in;
286
+ -o-transition: all 0.15s ease-in;
287
+ transition: all 0.15s ease-in;
288
+
289
+ list-style-type: none !important;
290
+ }
291
+
292
+ .dpsp-networks-btns-wrapper li:before {
293
+ display: none !important;
294
+ }
295
+
296
+ .dpsp-networks-btns-wrapper li:first-child {
297
+ margin-left: 0 !important;
298
+ }
299
+
300
+ /*
301
+ * Share button
302
+ */
303
+ .dpsp-networks-btns-wrapper .dpsp-network-btn {
304
+ position: relative;
305
+
306
+ display: block;
307
+ text-decoration: none !important;
308
+ text-transform: unset !important;
309
+ height: 40px;
310
+ min-width: 40px;
311
+
312
+ font-family: 'Arial';
313
+ font-weight: bold;
314
+ font-size: 14px;
315
+ line-height: 36px;
316
+ vertical-align: middle;
317
+
318
+ padding: 0 10px 0 48px;
319
+ border: 2px solid;
320
+ max-height: 40px;
321
+
322
+ width: 100%;
323
+ -moz-box-sizing: border-box;
324
+ box-sizing: border-box;
325
+
326
+ -moz-transition: all 0.15s ease-in;
327
+ -webkit-transition: all 0.15s ease-in;
328
+ -o-transition: all 0.15s ease-in;
329
+ transition: all 0.15s ease-in;
330
+
331
+ box-shadow: none;
332
+
333
+ cursor: pointer;
334
+ }
335
+
336
+ .dpsp-networks-btns-wrapper .dpsp-network-btn:hover {
337
+ border: 2px solid;
338
+ box-shadow: none;
339
+ }
340
+
341
+ .dpsp-networks-btns-wrapper .dpsp-network-btn:focus {
342
+ border: 2px solid;
343
+ box-shadow: none;
344
+ }
345
+
346
+ .dpsp-networks-btns-wrapper .dpsp-network-btn:after {
347
+ content: '';
348
+ display: block;
349
+ height: 0;
350
+ clear: both;
351
+ }
352
+
353
+
354
+ /*
355
+ * Button icon
356
+ */
357
+ .dpsp-networks-btns-wrapper .dpsp-network-btn .dpsp-network-icon {
358
+ position: absolute;
359
+ top: -2px;
360
+ left: -2px;
361
+ bottom: -2px;
362
+ float: left;
363
+ display: block;
364
+ font-size: 14px;
365
+ line-height: 36px;
366
+ width: 40px;
367
+ text-align: center;
368
+ vertical-align: middle;
369
+ border: 2px solid;
370
+
371
+ -moz-box-sizing: border-box;
372
+ box-sizing: border-box;
373
+
374
+ -moz-transition: all 0.15s ease-in;
375
+ -webkit-transition: all 0.15s ease-in;
376
+ -o-transition: all 0.15s ease-in;
377
+ transition: all 0.15s ease-in;
378
+ }
379
+
380
+
381
+ /*
382
+ * Buttons with no labels
383
+ */
384
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-no-label {
385
+ padding: 0 18px;
386
+ }
387
+
388
+ .dpsp-button-style-1 .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-no-label .dpsp-network-icon {
389
+ width: auto;
390
+ right: -2px;
391
+ }
392
+
393
+
394
+ /*
395
+ * Button label
396
+ */
397
+ .dpsp-has-buttons-count .dpsp-networks-btns-wrapper .dpsp-network-label {
398
+ margin-right: 10px;
399
+ }
400
+
401
+ .dpsp-networks-btns-wrapper .dpsp-network-btn .dpsp-network-count {
402
+ font-size: 13px;
403
+ }
404
+
405
+ .dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn .dpsp-network-count {
406
+ position: absolute;
407
+ bottom: 0;
408
+ left: 0;
409
+ width: 100%;
410
+ margin-left: 0;
411
+ font-size: 11px;
412
+ text-align: center;
413
+ height: 20px;
414
+ line-height: 20px;
415
+ }
416
+
417
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-no-label .dpsp-network-label-wrapper {
418
+ display: none;
419
+ }
420
+
421
+
422
+ /*
423
+ * Buttons columns
424
+ */
425
+ .dpsp-column-1 .dpsp-networks-btns-wrapper li { width: 100%; }
426
+ .dpsp-column-1.dpsp-has-spacing .dpsp-networks-btns-wrapper li { margin-right: 0; }
427
+
428
+ .dpsp-column-2 .dpsp-networks-btns-wrapper li { width: 50%; }
429
+ .dpsp-column-2.dpsp-has-spacing .dpsp-networks-btns-wrapper li { width: 49%; }
430
+ .dpsp-column-2 .dpsp-networks-btns-wrapper li:nth-child(2n) { margin-right: 0; }
431
+
432
+ .dpsp-column-3 .dpsp-networks-btns-wrapper li { width: 33.3333%; }
433
+ .dpsp-column-3.dpsp-has-spacing .dpsp-networks-btns-wrapper li { width: 32%; }
434
+ .dpsp-column-3 .dpsp-networks-btns-wrapper li:nth-child(3n) { margin-right: 0; }
435
+
436
+ .dpsp-column-4 .dpsp-networks-btns-wrapper li { width: 25%; }
437
+ .dpsp-column-4.dpsp-has-spacing .dpsp-networks-btns-wrapper li { width: 23.5%; }
438
+ .dpsp-column-4 .dpsp-networks-btns-wrapper li:nth-child(4n) { margin-right: 0; }
439
+
440
+ .dpsp-column-5 .dpsp-networks-btns-wrapper li { width: 20%; }
441
+ .dpsp-column-5.dpsp-has-spacing .dpsp-networks-btns-wrapper li { width: 18.4%; }
442
+ .dpsp-column-5 .dpsp-networks-btns-wrapper li:nth-child(5n) { margin-right: 0; }
443
+
444
+ .dpsp-column-6 .dpsp-networks-btns-wrapper li { width: 16.6666%; }
445
+ .dpsp-column-6.dpsp-has-spacing .dpsp-networks-btns-wrapper li { width: 15%; }
446
+ .dpsp-column-6 .dpsp-networks-btns-wrapper li:nth-child(6n) { margin-right: 0; }
447
+
448
+ .dpsp-column-2 .dpsp-networks-btns-wrapper .dpsp-network-btn,
449
+ .dpsp-column-3 .dpsp-networks-btns-wrapper .dpsp-network-btn,
450
+ .dpsp-column-4 .dpsp-networks-btns-wrapper .dpsp-network-btn,
451
+ .dpsp-column-5 .dpsp-networks-btns-wrapper .dpsp-network-btn,
452
+ .dpsp-column-6 .dpsp-networks-btns-wrapper .dpsp-network-btn { padding-right: 10px; }
453
+
454
+ /*
455
+ * Buttons width no labels
456
+ */
457
+ .dpsp-no-labels .dpsp-networks-btns-wrapper .dpsp-network-btn { padding: 0; text-align: center; }
458
+ .dpsp-no-labels:not(.dpsp-column-auto) .dpsp-networks-btns-wrapper .dpsp-network-btn:before { position: relative; left: 0; float: none; display: inline-block; }
459
+
460
+
461
+ /*
462
+ * Buttons colors
463
+ */
464
+ /* Facebook */
465
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-facebook .dpsp-network-icon,
466
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-facebook {
467
+ border-color: #3a579a;
468
+ background: #3a579a;
469
+ color: #3a579a;
470
+ }
471
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-facebook:hover .dpsp-network-icon,
472
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-facebook:hover {
473
+ border-color: #334d87;
474
+ background: #334d87;
475
+ color: #334d87;
476
+ }
477
+
478
+ /* Twitter */
479
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-twitter .dpsp-network-icon,
480
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-twitter {
481
+ border-color: #00abf0;
482
+ background: #00abf0;
483
+ color: #00abf0;
484
+ }
485
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-twitter:hover .dpsp-network-icon,
486
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-twitter:hover {
487
+ border-color: #0099d7;
488
+ background: #0099d7;
489
+ color: #0099d7;
490
+ }
491
+
492
+ /* Pinterest */
493
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-pinterest .dpsp-network-icon,
494
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-pinterest {
495
+ border-color: #c92228;
496
+ background: #c92228;
497
+ color: #c92228;
498
+ }
499
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-pinterest:hover .dpsp-network-icon,
500
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-pinterest:hover {
501
+ border-color: #b31e24;
502
+ background: #b31e24;
503
+ color: #b31e24;
504
+ }
505
+
506
+ /* LinkedIn */
507
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-linkedin .dpsp-network-icon,
508
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-linkedin {
509
+ border-color: #0077b5;
510
+ background: #0077b5;
511
+ color: #0077b5;
512
+ }
513
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-linkedin:hover .dpsp-network-icon,
514
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-linkedin:hover {
515
+ border-color: #00669c;
516
+ background: #00669c;
517
+ color: #00669c;
518
+ }
519
+
520
+ /* Email */
521
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-email .dpsp-network-icon,
522
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-email {
523
+ border-color: #27ae60;
524
+ background: #27ae60;
525
+ color: #27ae60;
526
+ }
527
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-email:hover .dpsp-network-icon,
528
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-email:hover {
529
+ border-color: #239e57;
530
+ background: #239e57;
531
+ color: #239e57;
532
+ }
533
+
534
+ /* Print */
535
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-print .dpsp-network-icon,
536
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-print {
537
+ border-color: #bdc3c7;
538
+ background: #bdc3c7;
539
+ color: #bdc3c7;
540
+ }
541
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-print:hover .dpsp-network-icon,
542
+ .dpsp-networks-btns-wrapper .dpsp-network-btn.dpsp-print:hover {
543
+ border-color: #afb6bb;
544
+ background: #afb6bb;
545
+ color: #afb6bb;
546
+ }
547
+
548
+
549
+ /* Sidebar needs color white for icons */
550
+ .dpsp-has-button-background .dpsp-networks-btns-wrapper.dpsp-networks-btns-sidebar .dpsp-network-btn:before {
551
+ color: #fff;
552
+ }
553
+
554
+ /*
555
+ * Buttons Shapes
556
+ */
557
+ .dpsp-shape-rounded .dpsp-network-btn,
558
+ .dpsp-shape-rounded .dpsp-network-btn .dpsp-network-icon {
559
+ -webkit-border-top-left-radius: 5px;
560
+ -webkit-border-bottom-left-radius: 5px;
561
+ -moz-border-radius-topleft: 5px;
562
+ -moz-border-radius-bottomleft: 5px;
563
+ border-top-left-radius: 5px;
564
+ border-bottom-left-radius: 5px;
565
+ }
566
+
567
+ .dpsp-shape-rounded .dpsp-network-btn,
568
+ .dpsp-shape-rounded .dpsp-no-label.dpsp-network-btn .dpsp-network-icon {
569
+ -webkit-border-top-right-radius: 5px;
570
+ -webkit-border-bottom-right-radius: 5px;
571
+ -moz-border-radius-topright: 5px;
572
+ -moz-border-radius-bottomright: 5px;
573
+ border-top-right-radius: 5px;
574
+ border-bottom-right-radius: 5px;
575
+ }
576
+
577
+ .dpsp-shape-circle .dpsp-network-btn { border-radius: 30px; }
578
+ .dpsp-shape-circle .dpsp-network-btn .dpsp-network-icon { border-radius: 30px; overflow: hidden; }
579
+
580
+ /*
581
+ * Buttons Margins/Spacings
582
+ */
583
+ .dpsp-has-spacing .dpsp-networks-btns-wrapper li { margin-bottom: 10px; margin-right: 2%; margin-left: 0 !important; }
584
+
585
+
586
+ /*
587
+ * Buttons on mobile
588
+ */
589
+ @media screen and ( max-width : 720px ) {
590
+ .dpsp-hide-on-mobile {
591
+ display: none;
592
+ }
593
+ }
594
+
595
+
596
+ /*****************************************/
597
+ /* Button styles
598
+ /*****************************************/
599
+
600
+ /*
601
+ * Buttons Style 1
602
+ */
603
+ .dpsp-button-style-1 .dpsp-network-btn { color: #fff !important; padding-left: 38px; }
604
+ .dpsp-button-style-1 .dpsp-network-btn .dpsp-network-icon { color: #fff !important; }
605
+
606
+
607
+ /*****************************************/
608
+ /* Total shares
609
+ /*****************************************/
610
+ .dpsp-show-total-share-count {
611
+ position: relative;
612
+ }
613
+
614
+ .dpsp-total-share-wrapper {
615
+ position: relative;
616
+ font-family: 'Arial';
617
+ margin-top: 10px;
618
+ line-height: 1.345;
619
+ color: #5d6368;
620
+ }
621
+
622
+ .dpsp-total-share-wrapper .dpsp-icon-total-share:before {
623
+ font-size: 16px;
624
+ top: 7px;
625
+ left: -2px;
626
+ margin-top: 0;
627
+ margin-left: 0;
628
+ }
629
+
630
+ #dpsp-floating-sidebar .dpsp-total-share-wrapper {
631
+ margin-bottom: 10px;
632
+ }
633
+
634
+ #dpsp-floating-sidebar .dpsp-total-share-wrapper .dpsp-icon-total-share {
635
+ display: none;
636
+ }
637
+
638
+ .dpsp-total-share-wrapper span {
639
+ display: block;
640
+ font-size: 9px;
641
+ font-weight: bold;
642
+ text-transform: uppercase;
643
+ text-align: center;
644
+ }
645
+
646
+ .dpsp-total-share-wrapper .dpsp-total-share-count {
647
+ font-size: 15px;
648
+ line-height: 18px;
649
+ white-space: nowrap;
650
+ }
651
+
652
+ .dpsp-content-wrapper .dpsp-total-share-wrapper {
653
+ position: absolute;
654
+ width: 60px;
655
+ height: 40px;
656
+ margin-top: -21px;
657
+ top: 50%;
658
+ padding-left: 20px;
659
+ box-sizing: border-box;
660
+ }
661
+
662
+ .dpsp-content-wrapper.dpsp-show-total-share-count.dpsp-show-total-share-count-before {
663
+ padding-left: 70px;
664
+ }
665
+
666
+ .dpsp-content-wrapper.dpsp-show-total-share-count.dpsp-show-total-share-count-after {
667
+ padding-right: 70px;
668
+ }
669
+
670
+ .dpsp-content-wrapper.dpsp-show-total-share-count.dpsp-show-total-share-count-before .dpsp-total-share-wrapper {
671
+ left: 0;
672
+ }
673
+
674
+ .dpsp-content-wrapper.dpsp-show-total-share-count.dpsp-show-total-share-count-after .dpsp-total-share-wrapper {
675
+ right: 0;
676
+ }
677
+
678
+
679
+ @media print {
680
+
681
+ #dpsp-floating-sidebar,
682
+ .dpsp-share-text,
683
+ .dpsp-content-wrapper { display: none; }
684
+
685
+ }
assets/src/dev-entry-jquery.js ADDED
@@ -0,0 +1,4 @@
 
 
 
 
1
+ import './css/style-frontend-jquery.css'
2
+ import './css/style-dashboard.css'
3
+ import './js/front-end-jquery'
4
+ import './js/dashboard.js'
assets/src/dev-entry.js ADDED
@@ -0,0 +1,4 @@
 
 
 
 
1
+ import './css/style-frontend.css'
2
+ import './css/style-dashboard.css'
3
+ import './js/front-end'
4
+ import './js/dashboard.js'
assets/src/entry.html ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <html>
2
+ <head>
3
+ <link rel="stylesheet" href="css/style-frontend.css"/>
4
+ <link rel="stylesheet" href="css/style-frontend-jquery.css"/>
5
+ <link rel="stylesheet" href="css/style-dashboard.css"/>
6
+ <script src="js/front-end.js"></script>
7
+ <script src="js/front-end-jquery.js"></script>
8
+ <script src="js/dashboard.js"></script>
9
+ <script src="js/jquery.ui.touch-punch.min.js"></script>
10
+ </head>
11
+ <body>
12
+ Remove me
13
+ </body>
14
+ </html>
assets/src/fonts/socialpug.eot ADDED
Binary file
assets/src/fonts/socialpug.svg ADDED
@@ -0,0 +1,70 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0" standalone="no"?>
2
+ <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
3
+ <svg xmlns="http://www.w3.org/2000/svg">
4
+ <metadata>Copyright (C) 2017 by original authors @ fontello.com</metadata>
5
+ <defs>
6
+ <font id="socialpug" horiz-adv-x="1000" >
7
+ <font-face font-family="socialpug" font-weight="400" font-stretch="normal" units-per-em="1000" ascent="850" descent="-150" />
8
+ <missing-glyph horiz-adv-x="1000" />
9
+ <glyph glyph-name="facebook" unicode="&#xe800;" d="M535 843v-147h-87q-48 0-65-20t-17-60v-106h164l-22-165h-142v-424h-171v424h-142v165h142v122q0 104 58 161t155 57q82 0 127-7z" horiz-adv-x="571.4" />
10
+
11
+ <glyph glyph-name="twitter" unicode="&#xe801;" d="M904 622q-37-54-90-93 0-8 0-23 0-73-21-145t-64-139-103-117-144-82-181-30q-151 0-276 81 19-2 43-2 126 0 224 77-59 1-105 36t-64 89q19-3 34-3 24 0 48 6-63 13-104 62t-41 115v2q38-21 82-23-37 25-59 64t-22 86q0 49 25 91 68-83 164-133t208-55q-5 21-5 41 0 75 53 127t127 53q79 0 132-57 61 12 115 44-21-64-80-100 52 6 104 28z" horiz-adv-x="928.6" />
12
+
13
+ <glyph glyph-name="gplus" unicode="&#xe802;" d="M318 403v-109h181c-8-47-55-137-181-137-108 0-197 90-197 201s89 201 197 201c62 0 103-27 127-49l86 83c-55 52-127 83-213 83-176 0-318-142-318-318s142-318 318-318c184 0 306 129 306 311 0 20-3 37-5 52h-301z m682 10h-94v93h-93v-93h-94v-94h94v-94h93v94h94z" horiz-adv-x="1000" />
14
+
15
+ <glyph glyph-name="pinterest" unicode="&#xe803;" d="M0 517q0 60 21 113t58 93 85 69 103 44 113 14q88 0 164-37t123-108 47-160q0-54-10-105t-34-99-56-83-80-58-106-21q-38 0-75 18t-54 49q-5-22-15-63t-14-53-11-40-15-39-17-35-26-44-35-48l-7-3-5 6q-9 88-9 105 0 51 12 115t37 161 29 113q-18 36-18 94 0 47 29 87t74 41q34 0 53-23t19-57q0-37-24-106t-25-105q0-35 25-58t61-23q31 0 57 14t44 38 31 53 21 61 11 62 4 56q0 96-61 150t-160 54q-111 0-186-72t-75-183q0-25 7-48t15-36 15-26 7-17q0-15-8-40t-21-25q-1 0-9 1-29 9-51 31t-34 53-18 60-6 60z" horiz-adv-x="714.3" />
16
+
17
+ <glyph glyph-name="linkedin" unicode="&#xe804;" d="M195 501v-553h-184v553h184z m12 171q0-41-29-68t-75-27h-1q-46 0-74 27t-28 68q0 41 29 68t75 27 74-27 29-68z m650-407v-317h-183v296q0 59-23 92t-71 33q-35 0-58-19t-36-48q-6-17-6-45v-309h-184q1 223 1 361t0 165l-1 27h184v-80h-1q11 18 23 31t31 29 49 24 64 9q95 0 153-63t58-186z" horiz-adv-x="857.1" />
18
+
19
+ <glyph glyph-name="stumbleupon" unicode="&#xe805;" d="M593 453v66q0 23-17 40t-40 16-40-16-17-40v-342q0-98-70-167t-170-69q-99 0-169 70t-70 169v149h183v-146q0-24 17-41t40-16 40 16 17 41v346q0 95 71 163t168 67q98 0 168-68t71-164v-76l-109-32z m295-124h183v-149q0-99-70-169t-169-70q-99 0-169 69t-70 168v150l73-34 109 32v-151q0-23 16-40t41-16 40 16 16 40v154z" horiz-adv-x="1071.4" />
20
+
21
+ <glyph glyph-name="reddit" unicode="&#xe806;" d="M0 362q0 23 9 44t24 37 36 25 46 9q43 0 74-29 59 37 135 59t162 25l80 228 196-47q9 26 33 42t53 17q39 0 67-27t28-67-28-66-66-27-67 27-28 66l-164 39-67-185q84-4 157-27t129-57q33 29 76 29 23 0 45-9t37-25 24-37 9-44q0-31-15-57t-40-41q4-17 4-35 0-60-35-116t-97-97-143-64-176-24q-92 0-174 24t-143 64-97 97-35 116q0 10 2 20 0 9 2 17-24 16-38 40t-15 56z m86-133q0-55 32-102t88-84 132-57 161-21 160 21 132 57 89 84 32 102-32 104-89 85-132 56-160 21-161-21-132-56-88-85-32-104z m199 54q0 28 22 50t50 21 50-21 21-50-21-49-50-21-50 21-22 49z m53-165q12 10 33-8 6-6 13-10t14-7 13-5 14-3 13-3 14-3 14-2 15-1 17-1q76 4 133 35 21 20 35 8 10-18-12-35-58-45-156-45-105 2-152 45-26 19-8 35z m242 166q0 29 21 50t50 20 51-20 21-50-21-50-51-21-50 21-21 50z" horiz-adv-x="1000" />
22
+
23
+ <glyph glyph-name="vkontakte" unicode="&#xe807;" d="M1070 560q13-36-84-164-13-18-36-48-22-28-31-40t-17-27-7-24 8-19 18-24 32-30q2-1 2-2 79-73 107-123 2-3 4-7t4-15-1-19-14-15-33-7l-142-3q-14-2-32 3t-29 13l-11 6q-17 12-39 36t-38 43-34 33-32 8q-1 0-4-2t-10-8-12-16-9-29-4-44q0-8-2-15t-4-10l-2-3q-10-11-30-12h-64q-40-3-81 9t-74 29-57 37-40 32l-14 14q-5 5-15 17t-40 50-59 85-68 117-73 152q-4 9-4 15t2 9l2 3q9 11 32 11l153 1q7-1 13-3t9-5l3-2q9-6 13-18 11-28 26-57t23-46l9-16q16-34 31-58t27-38 23-22 19-8 15 3q1 1 3 3t7 12 7 26 5 46 0 69q-1 23-5 41t-7 26l-4 6q-14 19-47 24-8 2 3 14 8 10 21 17 29 14 133 13 46-1 75-7 12-3 19-8t12-13 5-18 2-25 0-31-2-40 0-46q0-6-1-23t0-27 2-22 6-22 13-14q4-1 9-2t15 6 21 19 29 38 38 60q33 58 60 125 2 6 5 10t6 6l3 2 2 1t8 2 11 0l160 1q22 3 36-1t17-10z" horiz-adv-x="1071.4" />
24
+
25
+ <glyph glyph-name="whatsapp" unicode="&#xe808;" d="M550 307q7 0 54-25t50-30q1-2 1-8 0-18-9-42-9-22-40-37t-57-15q-32 0-106 35-55 25-95 66t-82 103q-41 60-40 108v5q2 50 41 88 14 12 29 12 4 0 10-1t11-1q11 0 15-3t8-16q5-11 19-49t14-41q0-12-19-33t-20-26q0-3 3-8 19-41 57-76 31-30 84-57 7-4 13-4 8 0 30 27t29 28z m-114-296q71 0 136 28t112 74 75 112 28 136-28 136-75 112-112 75-136 28-135-28-112-75-75-112-28-136q0-113 67-205l-44-130 135 43q88-58 192-58z m0 771q86 0 164-34t134-89 90-135 33-163-33-163-90-134-134-90-164-34q-108 0-203 53l-233-75 76 226q-60 99-60 217 0 86 33 163t90 135 134 89 163 34z" horiz-adv-x="857.1" />
26
+
27
+ <glyph glyph-name="instagram" unicode="&#xe809;" d="M571 350q0 59-41 101t-101 42-101-42-42-101 42-101 101-42 101 42 41 101z m77 0q0-91-64-156t-155-64-156 64-64 156 64 156 156 64 155-64 64-156z m61 229q0-21-15-36t-37-15-36 15-15 36 15 36 36 15 37-15 15-36z m-280 123q-4 0-43 0t-59 0-54-2-57-5-40-11q-28-11-49-32t-33-49q-6-16-10-40t-6-58-1-53 0-59 0-43 0-43 0-59 1-53 6-58 10-40q12-28 33-49t49-32q16-6 40-11t57-5 54-2 59 0 43 0 42 0 59 0 54 2 58 5 39 11q28 11 50 32t32 49q6 16 10 40t6 58 1 53 0 59 0 43 0 43 0 59-1 53-6 58-10 40q-11 28-32 49t-50 32q-16 6-39 11t-58 5-54 2-59 0-42 0z m428-352q0-128-3-177-5-116-69-180t-179-69q-50-3-177-3t-177 3q-116 6-180 69t-69 180q-3 49-3 177t3 177q5 116 69 180t180 69q49 3 177 3t177-3q116-6 179-69t69-180q3-49 3-177z" horiz-adv-x="857.1" />
28
+
29
+ <glyph glyph-name="youtube" unicode="&#xe810;" d="M397 221l270 139-270 141v-280z m103 481q94 0 181-3t128-5l41-2q0 0 9-1t13-2 13-2 16-5 16-7 17-11 16-15q4-3 9-10t16-33 15-56q4-36 7-76t3-64v-98q1-81-10-162-4-30-14-55t-18-35l-8-9q-7-8-16-15t-17-10-16-7-16-5-13-2-13-2-9-1q-140-11-350-11-115 2-201 4t-111 4l-28 3-20 2q-20 3-30 5t-29 12-31 23q-4 3-9 10t-16 33-15 56q-4 36-7 76t-3 64v98q-1 81 10 162 4 31 14 55t18 35l8 9q8 9 16 15t17 11 16 7 16 5 13 2 13 2 9 1q140 10 350 10z" horiz-adv-x="1000" />
30
+
31
+ <glyph glyph-name="vimeo" unicode="&#xe811;" d="M896 558q-32-186-171-351t-245-237q-42-28-81-17t-66 38-43 61q-16 32-78 239t-74 223q-16 12-38 5t-44-21l-20-14-36 50q18 20 46 52t100 89 124 67q30 6 53-7t36-35 23-60 15-70 12-75 13-67q14-54 21-80t17-54 18-39 18-11q40 0 126 166 42 76 6 124t-112 2q22 126 140 188 104 54 182 8 80-46 58-174z" horiz-adv-x="901" />
32
+
33
+ <glyph glyph-name="soundcloud" unicode="&#xe812;" d="M0 221q0 16 4 44t9 31q6-3 11-32t4-43q0-14-4-42t-11-32q-13 7-13 74z m64 0q0 25 5 74t6 61q0 6 6 6 4 0 6-6 12-129 12-135 0-24-5-71t-7-59q-2-7-6-7-6 0-6 7-1 11-6 59t-5 71z m81 0q0 24 5 74t5 54q0 9 7 9 8 0 8-9 11-113 11-128t-11-136q0-8-8-8-7 0-7 8 0 7-5 59t-5 77z m92 0q0 38 2 81t4 95 3 81q0 10 9 10 10 0 10-10 1-16 6-111t4-146q0-26-5-77t-5-58q0-10-10-10-9 0-9 10-9 132-9 135z m94 0q0 55 3 160t4 128q2 12 12 12t12-12q1-32 5-133t3-155q0-25-3-72t-5-61q-2-12-12-12t-12 12q0 11-3 59t-4 74z m95 0q0 40 1 85t3 100 2 85q2 15 14 15t14-15q1-30 3-85t2-100 1-85q0-2-6-131l0 1q-2-15-14-15t-14 14q-6 129-6 131z m95-1q0 3 6 351 2 18 16 18t16-18q6-348 6-351 0-1-6-127-2-17-16-17t-16 17q-6 126-6 127z m80 213q0 82 1 155-1 10 13 18t32 12 35 5 24 2q97 0 169-72t80-179q28 13 55 13 58 0 100-45t42-111-42-110-100-46l-393 0q-6 0-10 6t-5 13q0 55 0 156t-1 183z" horiz-adv-x="1152" />
34
+
35
+ <glyph glyph-name="twitch" unicode="&#xe813;" d="M500 608v-242h-81v242h81z m222 0v-242h-81v242h81z m0-424l141 141v444h-666v-585h182v-121l121 121h222z m222 666v-565l-242-242h-182l-121-122h-121v122h-222v646l61 161h827z" horiz-adv-x="1000" />
36
+
37
+ <glyph glyph-name="behance" unicode="&#xe814;" d="M1031 661h-285v-69h285v69z m-140-238q-51 0-82-29t-34-80h227q-10 109-111 109z m9-326q35 0 68 18t42 48h123q-55-171-238-171-119 0-190 73t-70 194q0 116 72 193t188 77q77 0 134-38t86-100 28-139q0-9-1-26h-367q0-62 32-96t93-33z m-745 28h165q114 0 114 93 0 100-111 100h-168v-193z m0 299h156q44 0 69 21t26 63q0 80-106 80h-145v-164z m-155 284h332q48 0 86-8t71-26 50-54 17-86q0-101-96-147 64-17 96-64t33-114q0-41-14-76t-37-58-55-39-67-24-75-7h-341v703z" horiz-adv-x="1142.9" />
38
+
39
+ <glyph glyph-name="yummly" unicode="&#xe815;" d="M143 846c-1-1-5-2-10-2-18-3-38-9-43-12-2-2-4-2-5-1-1 1-1 0-1-2 0-2-1-2-2-2-3 3-47-21-59-32-5-5-10-9-10-8 0 1-3-3-6-9-5-8-6-13-6-21 1-7 3-14 5-16 1-2 2-3 1-3-3 0 2-9 12-24 5-7 10-13 12-13 1 0 3-1 2-2-1-4 12-13 18-13 4 0 10 4 17 10 5 6 11 10 11 10 1 0 6 3 12 7 22 15 50 19 58 9 2-2 5-4 6-3 2 1 2 1 1-1-1-2-1-6 0-9 1-3 1-11 0-18-1-6-3-15-3-18-1-4-3-12-5-17-1-6-3-12-3-14-1-1-3-9-5-17-3-8-5-18-6-22-1-4-2-8-2-9-2-2-4-11-5-21-1-2-2-5-2-8-2-5-8-26-9-31 0-2-1-6-2-8-2-4-7-25-8-31-1-2-5-18-9-34-5-16-9-32-9-34-1-3-3-9-4-14-2-6-2-11-2-12 1-1 1-3-1-3-3-1-7-30-6-51 0-17 10-53 14-53 1 0 3-2 4-5 2-7 20-24 32-31 30-17 86-19 141-7 23 5 59 17 60 20 0 1 2 2 3 1 2-2 34 14 41 20 2 1 4 2 5 1 1 0-1-13-4-27-3-15-5-28-5-29 0-2-1-7-5-21 0-3-3-5-5-5-18 0-84-16-84-19 0-2-1-2-3-1-2 1-37-12-40-16-1-1-2-2-2 0 0 2-21-9-24-12 0-1-2-3-3-3-5 0-22-11-21-13 1-2 1-2-1-1-5 3-58-52-53-57 1-1 0-1-2-1-4 0-26-46-30-66-1-3-4-31-5-38-1-17 4-42 12-60 27-57 95-84 170-68 16 4 49 16 53 20 2 2 5 4 5 3 2-1 6 0 10 4 3 3 8 7 11 9 6 4 23 20 34 32 10 11 24 32 23 34-1 1-1 2 1 2 2 0 11 16 11 19 0 1 1 3 2 4 6 4 26 59 34 94 5 20 10 37 11 39 2 5 12 5 62-1 31-4 36-4 42-5 4-1 17-3 30-6 35-5 31-5 90-17 23-4 43-8 46-9 2 0 6-1 9-2 2-1 7-2 11-2 6-1 26-5 28-6 1 0 5-1 8-2 7-2 76-16 86-19 4 0 16-3 27-5 25-5 35-7 43-8 3 0 6-1 6-1 0-1 2-2 3-2 4 0 24-3 32-5 22-4 67-11 79-13 9-1 16-2 17-3 1 0 10-1 21-2 10-1 21-2 24-3 22-4 161-7 187-3 7 1 19 2 28 3 9 1 17 4 18 5 1 1 2 1 3 1 8-5 113 31 113 38 0 1 1 2 2 2 3-1 18 7 32 17 16 12 24 28 24 47 0 17-9 39-21 55-9 13-19 23-19 20 0-1-1 0-3 1-2 2-11-1-33-12-17-8-35-16-40-18-5-2-13-5-17-7-10-5-73-21-88-23-6-1-14-2-17-3-4 0-14-1-24-2-9-2-21-3-26-3-14-2-122-2-141 0-9 0-24 2-33 3-13 1-24 2-52 5-4 0-12 1-18 2-36 5-56 8-61 8-4 1-7 1-7 1 0 1-5 2-22 4-7 1-15 2-18 3-4 1-14 3-24 4-9 2-20 4-23 4-4 1-10 2-13 2-8 2-64 12-74 14-6 1-23 4-32 5-3 0-5 1-5 1 0 1-7 2-21 4-6 0-13 2-16 2-3 1-10 2-17 3-6 1-14 3-17 3-3 1-10 2-16 2-5 1-12 2-15 2-3 1-13 3-21 4-9 1-18 2-21 2-3 1-12 2-20 3-7 1-17 2-22 2-15 2-49 5-55 5-5-1-5 0-2 16 2 9 4 21 5 28 4 24 8 50 10 60 1 3 3 11 3 15 1 5 3 16 4 23 2 7 3 17 4 22 0 4 2 10 2 13 1 2 2 9 3 16 1 6 2 13 3 15 0 2 1 8 2 13 1 5 2 12 3 16 1 6 4 22 5 33 1 4 2 11 5 26 1 3 2 10 3 17 1 6 2 14 3 17 1 7 3 17 5 28 1 4 3 18 5 29 2 12 4 25 5 30 1 5 3 18 5 28 3 10 5 24 5 30 1 7 2 13 3 15 1 1 2 7 3 14 0 6 2 13 2 15 1 2 2 9 3 15 0 6 1 12 2 13 3 4 5 36 3 48-1 7-4 15-6 17-3 3-5 6-4 7 1 0-4 4-10 7-21 11-68 9-91-4-8-5-9-6-8-16 2-26 1-54-3-78-3-14-5-28-6-30 0-2-1-9-2-14-1-6-3-13-3-16-1-3-2-8-2-12-1-3-2-10-3-15-1-5-4-25-8-43-3-19-7-39-7-44-1-5-3-15-5-23-1-8-3-17-4-21 0-4-1-11-2-16-1-5-5-24-8-43-4-19-6-36-6-37 0-3-24-17-41-23-6-2-12-5-12-7 0-2 0-2-1-1-1 1-11-2-23-6-51-17-94-19-109-4-6 6-6 8-6 29 0 23 1 28 31 139 2 8 3 16 2 16 0 1 1 3 2 3 1 1 3 5 4 9 0 4 1 8 1 8 1 0 2 4 4 15 3 15 3 16 4 17 0 0 1 1 1 2 0 1 2 7 4 14 2 6 4 14 4 17 0 3 1 7 2 9 15 42 15 100 0 133-11 25-38 44-69 50-13 2-53 3-55 1z m199-745c-1-6-4-13-5-17-1-4-2-8-2-9 0-2 0-3-11-30-4-9-7-18-6-18 1-1 0-2-2-2-2 0-7-10-6-14 0-1 0-1-1-1-2 1-5-2-7-7-6-9-19-22-26-24-2-1-4-2-4-3 0-3-2-3-22-4-17-1-23 2-30 16-5 7-4 31 1 44 2 5 4 11 4 13 0 2 1 3 2 2 2-1 3 1 4 4 2 6 26 29 31 29 1 0 1 1 0 2-1 2 0 3 1 3 3-2 22 8 25 12 1 1 2 1 2 0 0-1 2 0 5 1 5 3 40 13 46 13 2 0 2-3 1-10z m872 563c-5-1-12-2-16-3-9-2-45-15-47-18-1-2-2-2-2-1 0 1-5-1-11-3-10-6-18-7-17-4 0 4-4 11-8 11-2 0-3 1-3 2 0 5-19 11-41 12-15 2-64-12-60-16 1 0 0-3-1-4-2-3-2-7 0-14 3-13 3-39 0-51-2-5-3-13-4-20-1-7-1-12-1-12-1 0-2-5-4-18-1-5-2-12-3-15-1-4-2-10-2-15-1-5-2-12-3-16-2-7-14-78-16-88-1-8-3-18-6-37-2-8-4-19-4-24-1-4-2-12-3-15-9-50 1-74 33-81 15-4 54-1 59 3 1 1 4 2 7 2 2 0 4 1 4 3 0 1 1 2 2 2 11-2 14 7 10 25-4 17-3 28 3 58 2 13 5 27 5 31 1 4 2 11 3 14 3 17 4 20 5 28 1 4 2 11 2 15 1 5 2 12 3 16 7 36 9 49 8 51-1 1-1 3 1 4 1 0 2 4 2 8 0 4 2 15 4 23l3 16 18 8c20 10 31 13 45 10 17-3 22-22 16-57-1-6-3-13-3-16-1-3-2-8-2-12-1-3-2-10-3-15-1-5-3-19-5-32-2-12-5-26-5-32-1-5-2-10-3-12-1-1-2-7-3-15 0-7-2-15-3-19-7-36-9-66-5-80 4-10 19-25 23-24 2 1 6 0 10-2 8-5 43-3 62 3 18 5 25 12 23 21-1 4-3 10-3 14-1 4-2 8-2 9-1 2 1 16 4 32 2 16 5 33 6 38 1 5 3 14 4 22 3 14 5 28 6 36 1 3 3 17 5 30 3 14 5 28 6 31 0 4 2 11 2 16 1 5 4 17 5 27l3 18 17 9c24 12 42 15 52 9 5-3 10-9 11-13 3-8 1-34-4-62-2-9-3-14-9-52-7-41-8-46-10-56 0-5-1-11-2-13 0-2-2-8-2-12-1-5-3-13-3-17-7-38-7-55 0-70 4-7 9-11 18-16 12-6 16-6 38-6 19 0 28 1 40 6 19 7 21 11 17 29-3 16-1 44 6 77 1 7 3 18 4 23 1 6 3 19 5 29 2 9 3 18 3 19 0 1 0 2 1 3 1 3 2 9 3 21 1 7 3 14 3 16 1 2 2 8 3 13 0 5 2 12 2 14 1 4 2 10 3 15 1 5 2 11 2 14 7 34 10 71 6 89-3 16-4 18-8 26-13 25-35 37-76 39-19 1-77-14-77-20 0-2 0-2-1-1-1 1-12-4-23-10l-22-11-5 7c-7 13-19 23-34 28-15 6-47 9-61 5z m-541-3c0-1-7-2-15-2-17-2-37-7-37-11 0-1-1-1-2-1-1 1-4 0-7-3-4-5-4-6 1-26 2-7 1-27-2-43-2-9-4-19-4-24 0-4-2-13-4-20-1-7-3-17-4-22-2-17-3-22-5-27 0-2-2-10-2-17-1-7-2-13-3-14 0-1-2-7-3-15-1-7-2-15-2-17-1-2-2-8-3-13-3-17-4-25-5-32-5-28-3-69 3-82 2-3 4-8 6-12 5-11 22-28 33-32 29-12 52-13 87-4 7 2 13 4 14 4 2 0 5 2 8 3 22 9 46 17 47 16 0 0 2-4 4-8 9-19 28-27 59-27 20 1 48 8 51 13 1 1 3 2 4 3 1 0 2 5 2 12-3 39-3 46-1 55 1 5 3 13 4 18 2 18 4 30 5 35 1 3 2 9 3 14 1 5 2 12 3 15 0 3 1 9 2 14 1 5 3 18 5 28 2 9 4 18 3 19-1 1 0 3 1 5 1 3 3 10 4 16 1 7 2 15 3 19 1 6 10 56 13 71 0 5 2 11 2 15 4 14 2 41-3 51-4 9-23 24-26 21-1-1-3 0-5 1-3 3-34 4-45 1-14-3-33-10-37-13-3-3-3-6-1-17 3-14 3-41 0-57-1-5-4-18-6-29-2-10-3-20-3-20 0-1 0-3 0-4-1-2-3-11-4-18-1-6-4-22-6-32-1-3-2-10-2-15-1-5-2-10-2-12-1-1-2-8-3-15-2-7-3-14-3-15 0 0-2-10-4-22-3-18-4-20-11-23-4-2-7-4-6-4 1-1-1-2-3-2-3 0-10-2-16-5-27-10-58-2-60 16 0 3-1 7-1 9 0 5 5 46 6 46 0 0 1 2 1 5 0 3 1 9 2 13 1 4 3 12 3 16 4 22 6 36 8 45 1 4 2 12 3 17 1 6 4 25 8 42 9 51 5 76-13 87-5 2-9 5-11 5-16 3-27 5-28 5z" horiz-adv-x="1538" />
40
+
41
+ <glyph glyph-name="mail" unicode="&#xe816;" d="M580 306l258-267-789 0 259 264 135-127z m-517 355l760 0-380-362z m566-309l257 242 0-508z m-629-266l0 508 259-243z" horiz-adv-x="886" />
42
+
43
+ <glyph glyph-name="print" unicode="&#xe817;" d="M866 564c40 0 75-35 75-78l0-366c0-42-35-77-75-77l-76 0 34-153-691 0 27 153-82 0c-45 0-78 35-78 77l0 366c0 43 33 78 78 78l96 0 0 117 34 0 0 129 527 0 0-129 34 0 0-117 97 0z m-623 199l0-292 457 0 0 292-457 0z m-113-389c30 0 55 24 55 54 0 28-25 53-55 53-29 0-54-25-54-53 0-30 25-54 54-54z m63-438l567 0-47 242-484 0z m252 113l-139 0 0 35 139 0 0-35z m198 0l-139 0 0 35 139 0 0-35z" horiz-adv-x="941" />
44
+
45
+ <glyph glyph-name="website" unicode="&#xe818;" d="M294 116q14 14 34 14t36-14q32-34 0-70l-42-40q-56-56-132-56-78 0-134 56t-56 132q0 78 56 134l148 148q70 68 144 77t128-43q16-16 16-36t-16-36q-36-32-70 0-50 48-132-34l-148-146q-26-26-26-64t26-62q26-26 63-26t63 26z m450 574q56-56 56-132 0-78-56-134l-158-158q-74-72-150-72-62 0-112 50-14 14-14 34t14 36q14 14 35 14t35-14q50-48 122 24l158 156q28 28 28 64 0 38-28 62-24 26-56 31t-60-21l-50-50q-16-14-36-14t-34 14q-34 34 0 70l50 50q54 54 127 51t129-61z" horiz-adv-x="800" />
46
+
47
+ <glyph glyph-name="pocket" unicode="&#xe819;" d="M2 520q-7 215 12 270 4 9 9 16t14 12 14 10 17 10 17 8q136 0 386 2t329 2l94 0t55 0 56-3 45-6 33-10q16-9 27-24t16-29 8-40 2-42-1-50 0-50q0-207-23-327t-96-213q-70-88-165-140t-193-62-200 11-186 73-151 134-96 181q-15 52-23 267z m232 2q-26-28 15-89t104-124q2-2 39-40t54-52 47-35 57-29q11-3 22-3t20 1 19 7 16 7 16 12 12 10 12 11l3 3q9 9 60 56t86 81 68 79 35 75q-15 40-38 56t-51 9-56-26-59-48-56-56-49-51-37-33q-27 16-73 60t-82 82-73 64-55 14q-25-15-56-41z" horiz-adv-x="1136" />
48
+
49
+ <glyph glyph-name="buffer" unicode="&#xe820;" d="M0 88q11 15 32 26t49 20 40 15q19 0 34-4t33-15 25-13q47-21 260-119 19-4 36 0t39 18 24 14q20 9 77 35t87 39q4 2 42 21t60 24q13 2 28-1t23-7 23-13 18-11 16-6 18-8 11-11q3-4 4-14-10-13-31-24t-51-22-40-16q-43-20-128-62t-129-61q-7-3-21-12t-23-13-26-11-27-7-30 2l-264 123q-6 3-32 14t-51 22-54 24-46 24-22 16q-4 4-4 13z m0 268q11 15 32 25t50 20 41 15q19 0 34-4t35-15 25-14q42-19 127-58t127-59q19-5 37 0t39 17 25 14q68 32 160 72 11 5 32 17t38 19 36 11q16 3 32-1t37-17 23-13q5-3 16-6t18-8 11-11q3-5 4-14-10-14-31-25t-53-23-41-16q-48-23-135-65t-123-59q-7-3-26-14t-29-15-32-10-36 0q-214 101-260 122-6 3-44 19t-69 30-62 30-34 22q-4 4-4 14z m0 267q10 15 32 27t52 22 41 16l348 162q30 0 54-7t56-26 40-22q39-18 117-54t117-55q4-2 37-15t54-24 27-20q3-4 4-13-9-13-26-22t-43-19-35-14q-47-22-140-66t-139-67q-6-3-20-11t-23-12-25-11-27-6-28 1q-245 114-256 119-4 2-63 28t-102 46-48 30q-4 4-4 13z" horiz-adv-x="979" />
50
+
51
+ <glyph glyph-name="tumblr" unicode="&#xe821;" d="M527 108l44-132q-12-19-61-37t-99-18q-58-1-107 15t-79 41-53 59-31 67-9 66v304h-94v120q40 14 72 39t51 50 32 57 19 55 8 49q1 3 3 5t4 2h136v-237h186v-140h-186v-289q0-17 3-31t13-30 28-23 45-8q44 1 75 16z" horiz-adv-x="571.4" />
52
+
53
+ <glyph glyph-name="github" unicode="&#xe822;" d="M0 351q0 102 40 194 79 186 265 265 92 40 194 40t194-40q184-78 265-265 40-95 40-194t-40-194q-81-188-265-267-92-40-194-40t-194 40q-186 80-265 267-40 92-40 194z m78 0q0-141 84-252 83-109 217-155l0 80q0 60 40 87-20 1-47 7-51 9-87 32-91 55-91 199 0 75 50 128-23 59 5 128l20 0q10 0 25-5 39-12 87-44 61 16 120 16t121-16q39 26 73 40 32 12 46 10l12-1q27-69 5-128 50-53 50-128 0-112-55-169-30-32-79-50-41-15-91-19 41-29 41-87l0-80q129 46 213 157 82 110 82 250 0 85-33 164-32 76-90 134-56 56-134 89-80 34-163 34-82 0-164-34-75-32-134-89-56-58-90-134-33-79-33-164z" horiz-adv-x="998" />
54
+
55
+ <glyph glyph-name="xing" unicode="&#xe823;" d="M0 152l219 0 173 286-130 229-219 0 130-229z m362 90l346 608 232 0-345-608 222-392-232 0z" horiz-adv-x="940" />
56
+
57
+ <glyph glyph-name="flipboard" unicode="&#xe824;" d="M0 850h321v-1000h-321v1000z m354-354h325v-325h-325v325z m0 354h646v-321h-646v321z" horiz-adv-x="1000" />
58
+
59
+ <glyph glyph-name="telegram" unicode="&#xe825;" d="M381-3c-28 0-23 11-33 38l-84 276 646 384m-529-698c22 0 32 10 44 22l118 114-147 89m0 0l355-263c41-22 70-11 80 38l145 681c15 59-23 86-61 69l-849-328c-58-23-58-55-11-70l218-68 504 318c24 15 46 7 28-9" horiz-adv-x="1000" />
60
+
61
+ <glyph glyph-name="ok" unicode="&#xe880;" d="M933 534q0-22-16-38l-404-404-76-76q-16-15-38-15t-38 15l-76 76-202 202q-15 16-15 38t15 38l76 76q16 16 38 16t38-16l164-165 366 367q16 16 38 16t38-16l76-76q16-15 16-38z" horiz-adv-x="1000" />
62
+
63
+ <glyph glyph-name="cancel" unicode="&#xe881;" d="M724 112q0-22-15-38l-76-76q-16-15-38-15t-38 15l-164 165-164-165q-16-15-38-15t-38 15l-76 76q-16 16-16 38t16 38l164 164-164 164q-16 16-16 38t16 38l76 76q16 16 38 16t38-16l164-164 164 164q16 16 38 16t38-16l76-76q15-15 15-38t-15-38l-164-164 164-164q15-15 15-38z" horiz-adv-x="785.7" />
64
+
65
+ <glyph glyph-name="pencil" unicode="&#xe882;" d="M938 605q22-22 22-55t-22-55l-570-570q-22-21-60-38t-73-17l-235 0 0 234q0 35 17 74t38 60l570 570q23 22 55 22t55-22z m-794-426l65-64 431 433-64 63z m91-205q14 0 33 8-10 10-27 26t-50 50-56 56l-22 22q-9-21-9-32l0-78 52-52 79 0z m74 40l432 432-63 64-433-431z m469 469l67 67-165 165-67-66z" horiz-adv-x="960" />
66
+
67
+ <glyph glyph-name="share" unicode="&#xe883;" d="M650 200q62 0 106-43t44-107q0-62-44-106t-106-44-106 44-44 106q0 6 1 14t1 12l-260 156q-42-32-92-32-62 0-106 44t-44 106 44 106 106 44q54 0 92-30l260 156q0 4-1 12t-1 12q0 62 44 106t106 44 106-43 44-107q0-62-44-106t-106-44q-52 0-90 32l-262-156q2-8 2-26 0-16-2-24l262-156q36 30 90 30z" horiz-adv-x="800" />
68
+ </font>
69
+ </defs>
70
+ </svg>
assets/src/fonts/socialpug.ttf ADDED
Binary file
assets/src/fonts/socialpug.woff ADDED
Binary file
assets/src/img/dpsp-icon-sort-handle.png ADDED
Binary file
assets/src/img/dpsp-icon-tooltip.png ADDED
Binary file
assets/src/img/dpsp-selectable-empty.png ADDED
Binary file
assets/src/img/extension-bitly.png ADDED
Binary file
assets/src/img/extension-branch.png ADDED
Binary file
assets/src/img/extension-ctt.png ADDED
Binary file
assets/src/img/extension-ga-utm-tracking.png ADDED
Binary file
assets/src/img/extension-networks.png ADDED
Binary file
assets/src/img/feedback-thank-you.png ADDED
Binary file
assets/src/img/grow-logo-sq-navy.png ADDED
Binary file
assets/src/img/opt-in-hound-banner.png ADDED
Binary file
assets/src/img/opt-in-hound-icon-256x256.png ADDED
Binary file
assets/src/img/opt-in-hound-promo-pop-up.png ADDED
Binary file
assets/src/img/opt-in-hound-promo-widget.png ADDED
Binary file
assets/src/img/skyepress-banner-clouds.png ADDED
Binary file
assets/src/img/skyepress-banner.png ADDED
Binary file
assets/src/img/skyepress-promo-1.png ADDED
Binary file
assets/src/img/skyepress-promo-2.png ADDED
Binary file
assets/src/img/skyepress-promo-3.png ADDED
Binary file
assets/src/img/skyepress-social-pug-promo.png ADDED
Binary file
assets/src/img/social-pug-upgrade.png ADDED
Binary file
assets/src/img/tool-content.png ADDED
Binary file
assets/src/img/tool-follow-widget.png ADDED
Binary file
assets/src/img/tool-image-hover-pinterest.png ADDED
Binary file
assets/src/img/tool-integrations-logo-edd.png ADDED
Binary file
assets/src/img/tool-integrations-logo-pb.png ADDED
Binary file
assets/src/img/tool-integrations-logo-pms.png ADDED
Binary file
assets/src/img/tool-integrations-logo-woocommerce.png ADDED
Binary file
assets/src/img/tool-mobile.png ADDED
Binary file
assets/src/img/tool-opt-in-icon-after-content.png ADDED
Binary file
assets/src/img/tool-opt-in-icon-fly-in.png ADDED
Binary file
assets/src/img/tool-opt-in-icon-pop-up.png ADDED
Binary file
assets/src/img/tool-opt-in-icon-shortcode.png ADDED
Binary file
assets/src/img/tool-opt-in-icon-widget.png ADDED
Binary file
assets/src/img/tool-pop-up.png ADDED
Binary file
assets/src/img/tool-sidebar.png ADDED
Binary file
assets/src/js/dashboard.js ADDED
@@ -0,0 +1,611 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ jQuery( function($) {
2
+
3
+ function is_email( email ) {
4
+ var re = /^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;
5
+ return re.test(String(email).toLowerCase());
6
+ }
7
+
8
+ /*****************************************************/
9
+ /* Toolkit page
10
+ /*****************************************************/
11
+ $(document).on( 'click', '.dpsp-tool-wrapper .dpsp-switch label', function(e) {
12
+
13
+ var $actions_wrapper = $(this).closest('.dpsp-tool-actions');
14
+ var $action_settings = $actions_wrapper.find('.dpsp-tool-settings');
15
+
16
+ // Add Loading Overlay
17
+ $action_settings.fadeOut(200);
18
+ $actions_wrapper.append('<div class="dpsp-tool-actions-overlay"><div class="spinner"></div></div>');
19
+ $actions_wrapper.find('.dpsp-tool-actions-overlay').animate({opacity: 1}, 200);
20
+
21
+ // Get tool to activate/deactivate
22
+ var tool = $(this).siblings('input').data('tool');
23
+ var tool_setting = $(this).siblings('input').data('tool-activation');
24
+
25
+ if( tool != 'undefined' ) {
26
+
27
+ if( $actions_wrapper.hasClass('dpsp-inactive') ) {
28
+
29
+ activateTool( tool_setting ).done( function( response ) {
30
+ if( response == 1 ) {
31
+ $actions_wrapper.find('.dpsp-tool-actions-overlay').animate({opacity: 0}, 200, function() { $(this).remove() });
32
+ $actions_wrapper.removeClass('dpsp-inactive').addClass('dpsp-active');
33
+ $actions_wrapper.find('span').text('Active');
34
+ $action_settings.fadeIn(200);
35
+ }
36
+ });
37
+
38
+ } else {
39
+
40
+ deactivateTool( tool_setting ).done( function( response ) {
41
+ if( response == 1 ) {
42
+ $actions_wrapper.find('.dpsp-tool-actions-overlay').animate({opacity: 0}, 200, function() { $(this).remove() });
43
+ $actions_wrapper.removeClass('dpsp-active').addClass('dpsp-inactive');
44
+ $actions_wrapper.find('span').text('Inactive');
45
+
46
+ hideMenuItem( tool );
47
+ }
48
+ });
49
+
50
+ }
51
+
52
+ }
53
+
54
+ });
55
+
56
+
57
+ /*
58
+ * Make an AJAX call to activate a tool
59
+ */
60
+ function activateTool( setting ) {
61
+
62
+ var data = {
63
+ 'action' : 'dpsp_activate_tool',
64
+ 'dpsptkn' : $('#dpsptkn').val(),
65
+ 'setting' : setting
66
+ }
67
+
68
+ return $.post( ajaxurl, data, function() {});
69
+
70
+ }
71
+
72
+ /*
73
+ * Make an AJAX call to deactivate a tool
74
+ */
75
+ function deactivateTool( setting ) {
76
+
77
+ var data = {
78
+ 'action' : 'dpsp_deactivate_tool',
79
+ 'dpsptkn' : $('#dpsptkn').val(),
80
+ 'setting' : setting
81
+ }
82
+
83
+ return $.post( ajaxurl, data, function() {});
84
+
85
+ }
86
+
87
+
88
+ /*
89
+ * Hides the menu item from the WP sidebar for a given location
90
+ */
91
+ function hideMenuItem( location ) {
92
+
93
+ location = location.replace('share_', '').replace('follow_', '').replace( '_', '-' );
94
+
95
+ var $menuItems = $('#toplevel_page_dpsp-social-pug .wp-submenu li a');
96
+
97
+ $menuItems.each( function() {
98
+ if( $(this).attr('href').indexOf( location ) != -1 )
99
+ $(this).parent().hide();
100
+ });
101
+
102
+ }
103
+
104
+
105
+ /*
106
+ * Initialize jQuery select2
107
+ *
108
+ */
109
+ if( $.fn.select2 ) {
110
+ $('.dpsp-setting-field-select select').select2({
111
+ minimumResultsForSearch : Infinity
112
+ }).on('select2:open', function() {
113
+ var container = $('.select2-container').last();
114
+ container.addClass('dpsp-select2');
115
+ });
116
+ }
117
+
118
+
119
+ /*
120
+ * Initialize jQuery sortable
121
+ *
122
+ */
123
+ $( function() {
124
+ $('.dpsp-social-platforms-sort-list').sortable({
125
+ handle: '.dpsp-sort-handle',
126
+ placeholder: 'dpsp-sort-placeholder',
127
+ containment: '#wpwrap'
128
+ });
129
+ });
130
+
131
+
132
+ /*
133
+ * Social newtworks checkboxes
134
+ *
135
+ */
136
+ $(document).on( 'click', '#dpsp-networks-selector .dpsp-network-item', function() {
137
+ $this = $(this);
138
+ $checkbox = $this.children('.dpsp-network-item-checkbox');
139
+
140
+ if( $this.attr('data-checked') )
141
+ $this.removeAttr('data-checked');
142
+ else
143
+ $this.attr('data-checked', 'true');
144
+
145
+ });
146
+
147
+
148
+ $(document).on( 'click', '#dpsp-select-networks', function(e) {
149
+
150
+ e.preventDefault();
151
+
152
+ if( $('#dpsp-networks-selector-wrapper').hasClass('dpsp-active') ) {
153
+
154
+ $('#dpsp-networks-selector-wrapper').removeClass('dpsp-active');
155
+
156
+ $('#dpsp-networks-selector-wrapper').stop().fadeOut( 250, function() {
157
+
158
+ if( $('.dpsp-social-platforms-sort-list').find('li').length == 0 ) {
159
+
160
+ $('#dpsp-sortable-networks-empty').stop().fadeIn(400);
161
+ $('#dpsp-sortable-networks-empty').addClass('dpsp-active');
162
+
163
+ } else {
164
+
165
+ $('.dpsp-social-platforms-sort-list').stop().fadeIn(400);
166
+ $('.dpsp-social-platforms-sort-list').addClass('dpsp-active');
167
+
168
+ }
169
+
170
+ });
171
+
172
+ } else {
173
+
174
+ // Hide the Select Networks button
175
+ $('#dpsp-select-networks').hide();
176
+
177
+ $('#dpsp-networks-selector-wrapper').addClass('dpsp-active');
178
+
179
+ if( $('.dpsp-social-platforms-sort-list').find('li').length == 0 ) {
180
+
181
+ $('.dpsp-social-platforms-sort-list').hide();
182
+
183
+ $('#dpsp-sortable-networks-empty').removeClass('dpsp-active');
184
+ $('#dpsp-sortable-networks-empty').stop().fadeOut( 250, function() {
185
+
186
+ $('#dpsp-networks-selector-wrapper').stop().fadeIn( 250 );
187
+
188
+ });
189
+
190
+ } else {
191
+
192
+ $('.dpsp-social-platforms-sort-list').removeClass('dpsp-active');
193
+ $('.dpsp-social-platforms-sort-list').stop().fadeOut( 250, function() {
194
+
195
+ $('#dpsp-networks-selector-wrapper').stop().fadeIn( 250 );
196
+
197
+ });
198
+
199
+ }
200
+
201
+ }
202
+
203
+ });
204
+
205
+
206
+ /**
207
+ * Apply Selection button action
208
+ *
209
+ * This will look at what social networks are checked in the Networks Selector
210
+ * panel and add them to the Networks Sortable panel
211
+ *
212
+ */
213
+ $(document).on( 'click', '#dpsp-networks-selector-footer a', function(e) {
214
+
215
+ e.preventDefault();
216
+
217
+ // Show the Select Networks button
218
+ $('#dpsp-select-networks').show();
219
+
220
+ // Parse each network from the selector panel
221
+ $('#dpsp-networks-selector .dpsp-network-item').each( function() {
222
+
223
+ $this = $(this);
224
+
225
+ var dataNetwork = $this.attr('data-network');
226
+ var dataNetworkName = $this.attr('data-network-name');
227
+
228
+ if( ! $this.attr('data-checked') ) {
229
+
230
+ removeSortableNetworkItem( dataNetwork );
231
+
232
+ } else {
233
+
234
+ var alreadyInList = false;
235
+
236
+ $('.dpsp-social-platforms-sort-list li').each( function() {
237
+ if( $(this).attr('data-network') == dataNetwork )
238
+ alreadyInList = true;
239
+ });
240
+
241
+ if( alreadyInList )
242
+ return alreadyInList;
243
+
244
+ addSortableNetworkItem( dataNetwork, dataNetworkName );
245
+ }
246
+
247
+ });
248
+
249
+ // Hide Networks Selector panel
250
+ $('#dpsp-networks-selector-wrapper').removeClass('dpsp-active').stop().fadeOut( 250, function() {
251
+
252
+ // If there are no networks in the sortable list display the empty placeholder
253
+ if( $('.dpsp-social-platforms-sort-list').find('li').length == 0 ) {
254
+
255
+ $('#dpsp-sortable-networks-empty').stop().fadeIn(250);
256
+ $('#dpsp-sortable-networks-empty').addClass('dpsp-active');
257
+
258
+ // If there are no networks in the sortable list display the Networks Sortable panel
259
+ } else {
260
+
261
+ $('.dpsp-social-platforms-sort-list').stop().fadeIn(250);
262
+ $('.dpsp-social-platforms-sort-list').addClass('dpsp-active');
263
+
264
+ }
265
+
266
+ });
267
+
268
+ });
269
+
270
+
271
+ /**
272
+ * Selects the edit label field from the sortable list when the admin
273
+ * clicks on the edit label button
274
+ *
275
+ */
276
+ $(document).on( 'click', '.dpsp-list-edit-label', function(e) {
277
+
278
+ e.preventDefault();
279
+
280
+ $(this).closest('li').find( '.dpsp-list-input-wrapper input' ).focus().select();
281
+
282
+ });
283
+
284
+
285
+ /**
286
+ * Removes the social network from the sortable list when clicking
287
+ * on the .dpsp-list-remove class and also uncheckes the social
288
+ * network from the selectable networks list
289
+ *
290
+ */
291
+ $(document).on( 'click', '.dpsp-list-remove', function(e) {
292
+
293
+ e.preventDefault();
294
+
295
+ var dataNetwork = $(this).closest('li').attr('data-network');
296
+
297
+ removeSortableNetworkItem( dataNetwork );
298
+
299
+ $('#dpsp-networks-selector .dpsp-network-item[data-network="' + dataNetwork + '"]').removeAttr('data-checked');
300
+
301
+ // If there are no networks in the sortable list display the empty placeholder
302
+ if( $('.dpsp-social-platforms-sort-list').find('li').length == 0 ) {
303
+
304
+ $('#dpsp-sortable-networks-empty').stop().fadeIn(250);
305
+ $('#dpsp-sortable-networks-empty').addClass('dpsp-active');
306
+
307
+ $('.dpsp-social-platforms-sort-list').removeClass('dpsp-active');
308
+
309
+ }
310
+
311
+ });
312
+
313
+
314
+ /**
315
+ * Function that adds a given item from the Networks Sortable panel
316
+ *
317
+ */
318
+ function addSortableNetworkItem( slug, name ) {
319
+
320
+ if( slug == 'undefined')
321
+ return false;
322
+
323
+ if( name == 'undefined')
324
+ return false;
325
+
326
+ var html = '';
327
+
328
+ var location = $('input[name="dpsp_buttons_location"]').val();
329
+
330
+ html += '<li data-network="' + slug + '">';
331
+ html += '<div class="dpsp-sort-handle ui-sortable-handle"><!-- --></div>';
332
+ html += '<div class="dpsp-list-icon dpsp-list-icon-social dpsp-icon-' + slug + ' dpsp-background-color-network-' + slug + '"><!-- --></div>';
333
+ html += '<div class="dpsp-list-input-wrapper"><input type="text" placeholder="' + 'This button has no label text.' + '" name="' + location + '[networks][' + slug + '][label]" value="' + name + '"></div>';
334
+
335
+ // List item actions
336
+ html += '<div class="dpsp-list-actions">';
337
+ html += '<a class="dpsp-list-edit-label dpsp-transition" href="#"><span class="dashicons dashicons-edit"></span>' + 'Edit Label' + '</a>';
338
+ html += '<a class="dpsp-list-remove dpsp-transition" href="#"><span class="dashicons dashicons-no-alt"></span>' + 'Remove' + '</a>';
339
+ html += '</div>';
340
+ html += '</li>';
341
+
342
+ $('.dpsp-social-platforms-sort-list').append( html );
343
+
344
+ // Set the last class for the last list item
345
+ $('.dpsp-social-platforms-sort-list li').removeClass('dpsp-last');
346
+ $('.dpsp-social-platforms-sort-list li').last().addClass('dpsp-last');
347
+
348
+ }
349
+
350
+
351
+ /**
352
+ * Function that removes a given item from the Networks Sortable panel
353
+ *
354
+ */
355
+ function removeSortableNetworkItem( slug ) {
356
+
357
+ $('.dpsp-social-platforms-sort-list li[data-network="' + slug + '"]').remove();
358
+
359
+ // Set the last class for the last list item
360
+ $('.dpsp-social-platforms-sort-list li').removeClass('dpsp-last');
361
+ $('.dpsp-social-platforms-sort-list li').last().addClass('dpsp-last');
362
+
363
+ if( $('.dpsp-social-platforms-sort-list li').length == 0 ) {
364
+
365
+ $('.dpsp-social-platforms-sort-list').fadeOut(1);
366
+ $('.dpsp-social-platforms-sort-list').removeClass('dpsp-active');
367
+
368
+ }
369
+
370
+ }
371
+
372
+
373
+ $(document).ready( function() {
374
+ $('.dpsp-network-btn').attr('href', '#');
375
+ });
376
+
377
+ $(document).on( 'click', '.dpsp-network-btn', function(e) {
378
+ e.preventDefault();
379
+ $(this).closest('label').click();
380
+ });
381
+
382
+
383
+ /*
384
+ * Disable inputs for certain networks sortable panels
385
+ *
386
+ */
387
+ $(document).on( 'focus', '.dpsp-page-mobile .dpsp-list-input-wrapper input', function() {
388
+ $(this).blur();
389
+ });
390
+
391
+
392
+ /*
393
+ * Set the shape of the network buttons on page load and dynamicly
394
+ *
395
+ */
396
+ $(document).on('click', '.dpsp-setting-field-button-shape input', function() {
397
+ $(this)
398
+ .closest('.dpsp-page-wrapper')
399
+ .find('.dpsp-networks-btns-wrapper')
400
+ .parent()
401
+ .removeClass('dpsp-shape-circle dpsp-shape-rounded dpsp-shape-rectangular')
402
+ .addClass('dpsp-shape-' + $(this).val() );
403
+ });
404
+
405
+
406
+ /*
407
+ * Show and hide back-end settings tool-tips
408
+ *
409
+ */
410
+ $(document).on( 'mouseenter', '.dpsp-setting-field-tooltip-icon', function() {
411
+ $(this).siblings('div').css('opacity', 1).css('visibility', 'visible');
412
+ });
413
+ $(document).on( 'mouseleave', '.dpsp-setting-field-tooltip-icon', function() {
414
+ $(this).siblings('div').css('opacity', 0).css('visibility', 'hidden');
415
+ });
416
+
417
+ $(document).on( 'mouseenter', '.dpsp-setting-field-tooltip-wrapper.dpsp-has-link', function() {
418
+ $(this).find('div').css('opacity', 1).css('visibility', 'visible');
419
+ });
420
+ $(document).on( 'mouseleave', '.dpsp-setting-field-tooltip-wrapper.dpsp-has-link', function() {
421
+ $(this).find('div').css('opacity', 0).css('visibility', 'hidden');
422
+ });
423
+
424
+
425
+ /**
426
+ * Mark the last .dpsp-setting-field-wrapper element for each card
427
+ *
428
+ */
429
+ $(document).on( 'change', '.dpsp-setting-field-wrapper *', function() {
430
+
431
+ $('.dpsp-card-inner').each( function() {
432
+
433
+ $(this).find('.dpsp-setting-field-wrapper').removeClass('dpsp-last');
434
+ $(this).find('.dpsp-setting-field-wrapper:not(.disabled)').last().addClass('dpsp-last');
435
+
436
+ });
437
+
438
+ });
439
+
440
+ $('.dpsp-setting-field-wrapper *').first().trigger('change');
441
+
442
+
443
+ /*
444
+ * Disable / enable settings that depend on other settings
445
+ *
446
+ */
447
+ $( function() {
448
+
449
+ // Set settings options
450
+ $checkbox_shares = $('.dpsp-setting-field-show-share-count input[type=checkbox]');
451
+ $checkbox_total_shares = $('.dpsp-setting-field-show-total-share-count input[type=checkbox]');
452
+ $checkbox_count_round = $('.dpsp-setting-field-share-count-round input[type=checkbox]');
453
+
454
+ $wrapper_checkbox_count_round = $checkbox_count_round.closest('.dpsp-setting-field-wrapper');
455
+
456
+
457
+ // Disable and enable total share count position
458
+ if( !$checkbox_total_shares.is(':checked') ) {
459
+ $checkbox_total_shares.closest('.dpsp-setting-field-wrapper').next().addClass('disabled');
460
+ $checkbox_total_shares.closest('.dpsp-setting-field-wrapper').next().find('select').attr( 'disabled', true );
461
+ }
462
+
463
+ $checkbox_total_shares.change( function() {
464
+ if( !$checkbox_total_shares.is(':checked') ) {
465
+ $checkbox_total_shares.closest('.dpsp-setting-field-wrapper').next().addClass('disabled');
466
+ $checkbox_total_shares.closest('.dpsp-setting-field-wrapper').next().find('select').attr( 'disabled', true );
467
+ } else {
468
+ $checkbox_total_shares.closest('.dpsp-setting-field-wrapper').next().removeClass('disabled');
469
+ $checkbox_total_shares.closest('.dpsp-setting-field-wrapper').next().find('select').attr( 'disabled', false );
470
+ }
471
+ });
472
+
473
+
474
+ // Disable and enable share count round
475
+ // Disable and enable minimum share count
476
+ enable_disable_count_round();
477
+
478
+ $checkbox_shares.change( function() {
479
+ enable_disable_count_round();
480
+ });
481
+
482
+ $checkbox_total_shares.change( function() {
483
+ enable_disable_count_round();
484
+ });
485
+
486
+ function enable_disable_count_round() {
487
+ if( !$checkbox_total_shares.is(':checked') && !$checkbox_shares.is(':checked') ) {
488
+ $wrapper_checkbox_count_round.addClass('disabled');
489
+ $checkbox_count_round.attr( 'disabled', true );
490
+ } else {
491
+ $wrapper_checkbox_count_round.removeClass('disabled');
492
+ $checkbox_count_round.attr( 'disabled', false );
493
+ }
494
+ }
495
+
496
+ });
497
+
498
+ /**********************************************************/
499
+ /* Refresh statistics in "Share Statistics" meta-box
500
+ /**********************************************************/
501
+ $(document).on( 'click', '#dpsp-refresh-share-counts', function(e) {
502
+
503
+ e.preventDefault();
504
+
505
+ if( $(this).hasClass('disabled') )
506
+ return false;
507
+
508
+ $refresh_button = $(this);
509
+ $spinner = $refresh_button.siblings('.spinner');
510
+
511
+ $refresh_button.addClass( 'disabled' );
512
+ $spinner.css( 'visibility', 'visible' );
513
+
514
+ $('.dpsp-statistic-bar-wrapper-network').css( 'opacity', 0.6 );
515
+
516
+ var data = {
517
+ action : 'dpsp_refresh_share_counts',
518
+ nonce : $refresh_button.siblings('[name="dpsp_refresh_share_counts"]').val(),
519
+ post_id : parseInt( $('#post_ID').val() )
520
+ }
521
+
522
+ $.post( ajaxurl, data, function( response ) {
523
+
524
+ if( response ) {
525
+ $('.dpsp-statistic-bars-wrapper').replaceWith( response );
526
+ }
527
+
528
+ });
529
+
530
+ });
531
+
532
+
533
+ /**********************************************************/
534
+ /* Display the Facebook authorization fields, based on the share counts provider
535
+ /**********************************************************/
536
+ $(document).on( 'change', '[name="dpsp_settings[facebook_share_counts_provider]"]', function() {
537
+
538
+ $('.dpsp-setting-field-facebook-authorize-app').hide();
539
+ $('.dpsp-setting-field-facebook-app-id, .dpsp-setting-field-facebook-app-secret').hide();
540
+
541
+ // Authorized app
542
+ if( $(this).val() == 'authorized_app' )
543
+ $('.dpsp-setting-field-facebook-authorize-app').show();
544
+
545
+ // Own app
546
+ if( $(this).val() == 'own_app' )
547
+ $('.dpsp-setting-field-facebook-app-id, .dpsp-setting-field-facebook-app-secret').show();
548
+
549
+ });
550
+
551
+ $('[name="dpsp_settings[facebook_share_counts_provider]"]').trigger( 'change' );
552
+
553
+
554
+ /**
555
+ * Enable/disable the submit button when the users write in the textarea
556
+ *
557
+ */
558
+ $(document).on( 'keyup', '#dpsp-deactivate-modal [name=dpsp_disable_text]', function() {
559
+
560
+ if( $(this).val() != '' )
561
+ $('#dpsp-feedback-submit').attr( 'disabled', false );
562
+ else
563
+ $('#dpsp-feedback-submit').attr( 'disabled', true );
564
+
565
+ });
566
+
567
+ /**
568
+ * Enable/disable the submit button when the users completes their email address
569
+ *
570
+ */
571
+ $(document).on( 'keyup', '#dpsp-deactivate-modal [name=dpsp_disable_from]', function() {
572
+
573
+ if( is_email( $(this).val() ) )
574
+ $('#dpsp-feedback-submit').attr( 'disabled', false );
575
+ else
576
+ $('#dpsp-feedback-submit').attr( 'disabled', true );
577
+
578
+ });
579
+
580
+ $('#dpsp-feedback-submit').click(function (e) {
581
+ e.preventDefault();
582
+ $('#dpsp-deactivate-modal').hide();
583
+ $.ajax({
584
+ type: 'POST',
585
+ url: ajaxurl,
586
+ dataType: 'json',
587
+ data: {
588
+ action: 'dpsp_send_deactivation_feedback',
589
+ data: $('#dpsp-deactivate-modal form').serialize()
590
+ },
591
+ complete: function (MLHttpRequest, textStatus, errorThrown) {
592
+ $('#dpsp-deactivate-modal').remove();
593
+ window.location.href = $('.wp-admin.plugins-php tr[data-slug="social-pug"] .row-actions .deactivate a').attr('href');
594
+ }
595
+ });
596
+ });
597
+
598
+ $('#dpsp-only-deactivate').click(function (e) {
599
+ e.preventDefault();
600
+ $('#dpsp-deactivate-modal').hide();
601
+ $('#dpsp-deactivate-modal').remove();
602
+ window.location.href = $('.wp-admin.plugins-php tr[data-slug="social-pug"] .row-actions .deactivate a').attr('href');
603
+
604
+ });
605
+
606
+ $('.dpsp-deactivate-close').click(function (e) {
607
+ e.preventDefault();
608
+ $('#dpsp-deactivate-modal').hide();
609
+ });
610
+
611
+ });
assets/src/js/front-end-jquery.js ADDED
@@ -0,0 +1,105 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ jQuery( function($) {
2
+
3
+ /**
4
+ * Pull share counts
5
+ *
6
+ */
7
+ $(document).ready( function() {
8
+
9
+ if( typeof dpsp_ajax_url != 'undefined' && typeof dpsp_ajax_pull_post_share_counts_data != 'undefined' ) {
10
+
11
+ $.post( dpsp_ajax_url, dpsp_ajax_pull_post_share_counts_data, function( response ) { });
12
+
13
+ }
14
+
15
+ });
16
+
17
+
18
+ /*
19
+ * Position sidebar icons vertically
20
+ *
21
+ */
22
+ $(document).ready( function() {
23
+ $('#dpsp-floating-sidebar').css('top', ( window.innerHeight - $('#dpsp-floating-sidebar').height() ) / 2 );
24
+ });
25
+
26
+ $(window).on( 'resize', function() {
27
+ $('#dpsp-floating-sidebar').css('top', ( window.innerHeight - $('#dpsp-floating-sidebar').height() ) / 2 );
28
+ });
29
+
30
+
31
+ /**
32
+ * When entering and leaving a button, add a class of hover to the wrapping <li> element
33
+ *
34
+ */
35
+ $(document).on( 'mouseenter', '.dpsp-networks-btns-wrapper li a', function(e) {
36
+
37
+ $(this).closest('li').addClass('dpsp-hover');
38
+
39
+ });
40
+
41
+ $(document).on( 'mouseleave', '.dpsp-networks-btns-wrapper li a', function() {
42
+
43
+ $(this).closest('li').removeClass('dpsp-hover');
44
+
45
+ });
46
+
47
+
48
+ /*
49
+ * Open Pinterest overlay to select which image to pin when
50
+ * clicking on a Pin button without media attached
51
+ *
52
+ */
53
+ $(document).ready( function() {
54
+ $('.dpsp-network-btn.dpsp-pinterest').click( function(e) {
55
+
56
+ if( $(this).attr('href') != '#' )
57
+ return false;
58
+
59
+ e.preventDefault();
60
+
61
+ var elem = document.createElement('script');
62
+ elem.setAttribute('type', 'text/javascript');
63
+ elem.setAttribute('charset', 'UTF-8');
64
+ elem.setAttribute('src', 'https://assets.pinterest.com/js/pinmarklet.js');
65
+ document.body.appendChild(elem);
66
+
67
+ });
68
+ });
69
+
70
+
71
+ /**
72
+ * Print button action
73
+ *
74
+ */
75
+ $(document).ready( function() {
76
+ $('.dpsp-network-btn.dpsp-print').click( function(e) {
77
+ window.print();
78
+ });
79
+ });
80
+
81
+
82
+ /**
83
+ * Open share links in a pop-up window
84
+ *
85
+ */
86
+ $(document).on( 'click', '.dpsp-network-btn', function(e) {
87
+
88
+ if( $(this).hasClass('dpsp-twitter') && typeof window.twttr != 'undefined' )
89
+ return;
90
+
91
+ if( $(this).hasClass('dpsp-email') )
92
+ return;
93
+
94
+ e.preventDefault();
95
+
96
+ if( $(this).attr('href') == '#' )
97
+ return false;
98
+
99
+ $(this).blur();
100
+
101
+ window.open( $(this).attr('href'),'targetWindow', "toolbar=no,location=no,status=no,menubar=no,scrollbars=no,resizable=yes,width=700,height=300,top=200,left=" + ($(window).innerWidth() - 700)/2 );
102
+
103
+ });
104
+
105
+ });
assets/src/js/front-end.js ADDED
@@ -0,0 +1,80 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ function initializeButtonHover() {
2
+ const btns = document.querySelectorAll('.dpsp-networks-btns-wrapper li a')
3
+ for(const btn of btns) {
4
+ btn.addEventListener('mouseenter', ({ target }) => {
5
+ target.parentNode.classList.add('dpsp-hover')
6
+ })
7
+ btn.addEventListener('mouseleave', ({ target }) => {
8
+ target.parentNode.classList.remove('dpsp-hover')
9
+ })
10
+ }
11
+ }
12
+
13
+ function initializePinterest() {
14
+ const btns = document.querySelectorAll('.dpsp-network-btn.dpsp-pinterest')
15
+ Array.prototype.forEach.call(btns, (btn) => {
16
+ btn.addEventListener('click', (e) => {
17
+ const { target } = e
18
+
19
+ if(!/#$/.test(target.href)) {
20
+ e.stopPropagation()
21
+ e.preventDefault()
22
+ return
23
+ }
24
+
25
+ e.preventDefault()
26
+
27
+ const el = document.createElement('script');
28
+ el.setAttribute('type', 'text/javascript');
29
+ el.setAttribute('charset', 'UTF-8');
30
+ el.setAttribute('src', 'https://assets.pinterest.com/js/pinmarklet.js');
31
+ document.body.appendChild(el);
32
+ })
33
+ })
34
+ }
35
+
36
+ function initializePrint() {
37
+ const btns = document.querySelectorAll('.dpsp-network-btn.dpsp-print')
38
+ Array.prototype.forEach.call(btns, (btn) => {
39
+ btn.addEventListener('click', () => {
40
+ window.print()
41
+ })
42
+ })
43
+ }
44
+
45
+ function initializeButtons() {
46
+ const btns = document.querySelectorAll('.dpsp-network-btn')
47
+ Array.prototype.forEach.call(btns, (btn) => {
48
+ btn.addEventListener('click', (e) => {
49
+ const { target } = e
50
+
51
+ if(target.classList.contains('dpsp-email')) return
52
+
53
+ e.preventDefault()
54
+
55
+ if(/#$/.test(target.href)) {
56
+ e.stopPropagation()
57
+ return
58
+ }
59
+
60
+ target.blur()
61
+
62
+ window.open(
63
+ target.href,
64
+ 'targetWindow',
65
+ `toolbar=no,location=no,status=no,menubar=no,scrollbars=no,resizable=yes,width=700,height=300,top=200,left=${(window.innerWidth - 700)/2}`
66
+ )
67
+
68
+ })
69
+ })
70
+ }
71
+
72
+ const init = () => {
73
+ initializeButtonHover()
74
+ initializePinterest()
75
+ initializePrint()
76
+ initializeButtons()
77
+ window.removeEventListener('mousemove', init)
78
+ }
79
+
80
+ window.addEventListener('mousemove', init)
assets/src/js/jquery.ui.touch-punch.min.js ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ /*!
2
+ * jQuery UI Touch Punch 0.2.3
3
+ *
4
+ * Copyright 2011–2014, Dave Furfero
5
+ * Dual licensed under the MIT or GPL Version 2 licenses.
6
+ *
7
+ * Depends:
8
+ * jquery.ui.widget.js
9
+ * jquery.ui.mouse.js
10
+ */
11
+ !function(a){function f(a,b){if(!(a.originalEvent.touches.length>1)){a.preventDefault();var c=a.originalEvent.changedTouches[0],d=document.createEvent("MouseEvents");d.initMouseEvent(b,!0,!0,window,1,c.screenX,c.screenY,c.clientX,c.clientY,!1,!1,!1,!1,0,null),a.target.dispatchEvent(d)}}if(a.support.touch="ontouchend"in document,a.support.touch){var e,b=a.ui.mouse.prototype,c=b._mouseInit,d=b._mouseDestroy;b._touchStart=function(a){var b=this;!e&&b._mouseCapture(a.originalEvent.changedTouches[0])&&(e=!0,b._touchMoved=!1,f(a,"mouseover"),f(a,"mousemove"),f(a,"mousedown"))},b._touchMove=function(a){e&&(this._touchMoved=!0,f(a,"mousemove"))},b._touchEnd=function(a){e&&(f(a,"mouseup"),f(a,"mouseout"),this._touchMoved||f(a,"click"),e=!1)},b._mouseInit=function(){var b=this;b.element.bind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),c.call(b)},b._mouseDestroy=function(){var b=this;b.element.unbind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),d.call(b)}}}(jQuery);
inc/admin/admin-metaboxes.php ADDED
@@ -0,0 +1,136 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /*
3
+ * Meta-boxes file
4
+ *
5
+ */
6
+
7
+ /*
8
+ * Individual posts share statistics meta-box
9
+ *
10
+ */
11
+ function dpsp_meta_boxes() {
12
+
13
+ $screens = get_post_types( array( 'public' => true ) );
14
+
15
+ if( empty( $screens ) )
16
+ return;
17
+
18
+ foreach( $screens as $screen ) {
19
+
20
+ // Share statistics meta-box
21
+ add_meta_box( 'dpsp_share_statistics', __( 'Share Statistics', 'social-pug' ), 'dpsp_share_statistics_output', $screen, 'normal', 'core' );
22
+
23
+ }
24
+
25
+ }
26
+ add_action( 'add_meta_boxes', 'dpsp_meta_boxes' );
27
+
28
+
29
+ /*
30
+ * Callback for the share statistics meta-box
31
+ *
32
+ */
33
+ function dpsp_share_statistics_output( $post ) {
34
+
35
+ $networks = dpsp_get_active_networks();
36
+
37
+ if( !empty( $networks ) ) {
38
+
39
+ echo '<div class="dpsp-statistic-bars-wrapper">';
40
+
41
+ $networks_shares = get_post_meta( $post->ID, 'dpsp_networks_shares', true );
42
+ $networks_shares = ( !empty( $networks_shares ) ? $networks_shares : array() );
43
+
44
+ // Get total share counts
45
+ $total_shares = dpsp_get_post_total_share_count( $post->ID );
46
+
47
+ // Shares header
48
+ echo '<div class="dpsp-statistic-bar-wrapper dpsp-statistic-bar-header">';
49
+ echo '<label>' . __( 'Network', 'social-pug' ) . '</label>';
50
+ echo '<div class="dpsp-network-share-count"><span class="dpsp-count">' . __( 'Shares', 'social-pug' ) . '</span><span class="dpsp-divider">|</span><span class="dpsp-percentage">%</span></div>';
51
+ echo '</div>';
52
+
53
+ // Actual shares per network
54
+ foreach( $networks as $network_slug ) {
55
+
56
+ // Jump to the next one if the network by some chance does not support
57
+ // share count
58
+ if( !in_array( $network_slug, dpsp_get_networks_with_social_count() ) )
59
+ continue;
60
+
61
+ // Get current network social share count
62
+ $network_shares = ( isset($networks_shares[$network_slug]) ? $networks_shares[$network_slug] : 0 );
63
+
64
+ // Get the percentage of the total shares for current network
65
+ $share_percentage = ( $total_shares != 0 ? (float)($network_shares / $total_shares * 100) : 0 );
66
+
67
+ echo '<div class="dpsp-statistic-bar-wrapper dpsp-statistic-bar-wrapper-network">';
68
+ echo '<label>' . dpsp_get_network_name( $network_slug ) . '</label>';
69
+
70
+ echo '<div class="dpsp-statistic-bar dpsp-statistic-bar-' . $network_slug . '">';
71
+ echo '<div class="dpsp-statistic-bar-inner" style="width:' . round( $share_percentage, 1 ) . '%"></div>';
72
+ echo '</div>';
73
+
74
+ echo '<div class="dpsp-network-share-count"><span class="dpsp-count">' . $network_shares . '</span><span class="dpsp-divider">|</span><span class="dpsp-percentage">' . round( $share_percentage, 2 ) . '</span></div>';
75
+ echo '</div>';
76
+
77
+ }
78
+
79
+ // Shares footer with total count
80
+ echo '<div class="dpsp-statistic-bar-wrapper dpsp-statistic-bar-footer">';
81
+ echo '<label>' . __( 'Total shares', 'social-pug' ) . '</label>';
82
+ echo '<div class="dpsp-network-share-count"><span class="dpsp-count">' . $total_shares . '</span></div>';
83
+ echo '</div>';
84
+
85
+ // Refresh counts button
86
+ echo '<div id="dpsp-refresh-share-counts-wrapper">';
87
+ echo '<a id="dpsp-refresh-share-counts" class="button-secondary" href="#">' . __( 'Refresh shares', 'social-pug' ) . '</a>';
88
+ echo '<span class="spinner"></span>';
89
+ echo wp_nonce_field( 'dpsp_refresh_share_counts', 'dpsp_refresh_share_counts', false, false );
90
+ echo '</div>';
91
+
92
+ echo '</div>';
93
+
94
+ }
95
+
96
+ }
97
+
98
+
99
+ /**
100
+ * Ajax callback action that refreshes the social counts for the "Share Statistics"
101
+ * meta-box from each single edit post admin screen
102
+ *
103
+ */
104
+ function dpsp_refresh_share_counts() {
105
+
106
+ if( empty( $_POST['action'] ) || empty( $_POST['nonce'] ) || empty( $_POST['post_id'] ) )
107
+ return;
108
+
109
+ if( $_POST['action'] != 'dpsp_refresh_share_counts' )
110
+ return;
111
+
112
+ if( ! wp_verify_nonce( $_POST['nonce'], 'dpsp_refresh_share_counts' ) )
113
+ return;
114
+
115
+ $post_id = (int)$_POST['post_id'];
116
+
117
+ if( ! in_array( $post->post_status, array( 'future', 'draft', 'pending', 'trash', 'auto-draft' ) ) ) {
118
+
119
+ // Flush existing shares before pulling a new set
120
+ update_post_meta( $post_id, 'dpsp_networks_shares', '' );
121
+
122
+ // Get social shares from the networks
123
+ $share_counts = dpsp_pull_post_share_counts( $post_id );
124
+
125
+ // Update share counts in the db
126
+ $shares_updated = dpsp_update_post_share_counts( $post_id, $share_counts );
127
+
128
+ }
129
+
130
+ // Echos the share statistics
131
+ dpsp_share_statistics_output( get_post( $post_id ) );
132
+
133
+ wp_die();
134
+
135
+ }
136
+ add_action( 'wp_ajax_dpsp_refresh_share_counts', 'dpsp_refresh_share_counts' );
inc/admin/feedback-form/assets/css/style-admin-feedback-form.css ADDED
@@ -0,0 +1,77 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*******************************************************************************************/
2
+ /* Feedback Form Button
3
+ /*******************************************************************************************/
4
+ #dpsp-feedback-button { display: none; position: fixed; bottom: 30px; right: 20px; width: 72px; height: 72px; line-height: 80px; text-align: center; background: #fff; border-radius: 50px; box-shadow: 0 3px 10px 4px rgba(0,0,0,0.065); cursor: pointer; transition: all 0.2s ease-in-out; }
5
+ #dpsp-feedback-button:hover { box-shadow: 0 3px 10px 4px rgba(0,0,0,0.125); }
6
+
7
+ #dpsp-feedback-button img { visibility: hidden; opacity: 0; width: 54px; height: 54px; margin-top: -8px; vertical-align: middle; }
8
+ #dpsp-feedback-button.dpsp-inactive img { visibility: visible; opacity: 1; transition: all 0.2s ease-in-out; }
9
+
10
+ #dpsp-feedback-button .dpsp-close { position: absolute; left: 0; top: 1px; width: 72px; height: 72px; line-height: 72px; text-align: center; font-size: 50px; color: #d1d1d1; visibility: visible; opacity: 1; border-radius: 50px; }
11
+ #dpsp-feedback-button.dpsp-inactive .dpsp-close { visibility: hidden; opacity: 0; transition: all 0.2s ease-in-out; }
12
+
13
+ /*******************************************************************************************/
14
+ /* Feedback Form
15
+ /*******************************************************************************************/
16
+ #dpsp-feedback-form-wrapper { position: fixed; bottom: 120px; right: 20px; width: 300px; height: 385px; background: #fff; border-radius: 7px; box-shadow: 0 3px 10px 4px rgba(0,0,0,0.065); transition: all 0.2s ease-in-out; }
17
+ #dpsp-feedback-form-wrapper.dpsp-inactive { visibility: hidden; opacity: 0; bottom: 90px; }
18
+
19
+ /* Form header */
20
+ #dpsp-feedback-form-header { position: relative; background: #00a8ff; height: 70px; border-top-left-radius: 7px; border-top-right-radius: 7px; }
21
+
22
+ #dpsp-feedback-form-header-image { position: absolute; left: 50%; top: -35px; width: 70px; height: 70px; line-height: 70px; margin-left: -38px; text-align: center; background: #fff; border-radius: 50px; border: 3px solid #00a8ff; }
23
+ #dpsp-feedback-form-header-image img { width: 55px; height: 55px; vertical-align: middle; }
24
+
25
+ #dpsp-feedback-form-header strong { position: absolute; left: 0; right: 0; bottom: 8px; text-align: center; color: #fff; font-size: 13px; }
26
+
27
+ /* Form panels */
28
+ #dpsp-feedback-form-inner { position: relative; height: 255px; overflow: hidden; }
29
+
30
+ .dpsp-feedback-form-panel { position: absolute; top: 0; left: 0; padding: 15px; height: 255px; width: 300px; box-sizing: border-box; transition: left 0.25s ease-in-out; }
31
+ .dpsp-feedback-form-panel.dpsp-done { left: -320px; }
32
+ .dpsp-feedback-form-panel.dpsp-todo { left: 320px; }
33
+
34
+ .dpsp-feedback-form-panel-label { display: block; font-weight: bold; margin-bottom: 15px; }
35
+
36
+ .dpsp-feedback-form-panel input[type=radio] { display: none; }
37
+ .dpsp-feedback-form-panel label:not(.dpsp-feedback-form-panel-label) { display: block; background: #f1f1f1; color: #565656; padding: 6px 12px; border-radius: 12px; margin-bottom: 7px; transition: background 0.2s ease-in-out; }
38
+ .dpsp-feedback-form-panel label:not(.dpsp-feedback-form-panel-label):hover { background: #d1d1d1; }
39
+
40
+ .dpsp-feedback-form-panel input:checked + label { background: #00a8ff !important; color: #fff !important; }
41
+
42
+ .dpsp-feedback-form-panel textarea,
43
+ .dpsp-feedback-form-panel input[type=email] { width: 100%; padding: 10px; background: #f5f5f5; border: 2px solid transparent; border-radius: 4px; box-shadow: none; font-size: 13px; box-sizing: border-box; }
44
+ .dpsp-feedback-form-panel textarea { height: 170px; }
45
+
46
+ .dpsp-feedback-form-panel textarea:focus,
47
+ .dpsp-feedback-form-panel input[type=email]:focus { border: 2px solid rgba( 0, 168, 255, 0.5 ); }
48
+
49
+ .dpsp-feedback-form-panel .description { font-size: 11px; margin-top: 7px; }
50
+
51
+ #dpsp-feedback-form-description-char-count-1,
52
+ #dpsp-feedback-form-description-char-count-2 { text-align: right; }
53
+
54
+ #dpsp-feedback-form-description-char-count-2 { display: none; }
55
+
56
+ /* Panel 4 - Success Message */
57
+ #dpsp-feedback-form-panel-4 { display: none; text-align: center; }
58
+ #dpsp-feedback-form-panel-4 .dashicons { margin-top: 80px; width: 34px; height: 32px; line-height: 34px; vertical-align: middle; text-align: center; background: #1abc9c; color: #fff; border-radius: 50%; font-size: 28px; text-indent: -2px; padding-top: 2px; }
59
+
60
+ /* Form navigation */
61
+ #dpsp-feedback-form-navigation { display: none; position: absolute; bottom: 0; left: 0; height: 70px; width: 100%; padding: 15px; text-align: center; box-sizing: border-box; }
62
+
63
+ #dpsp-feedback-form-back,
64
+ #dpsp-feedback-form-next,
65
+ #dpsp-feedback-form-send { display: inline-block; line-height: 40px; vertical-align: middle; padding: 0 20px; text-decoration: none; font-weight: bold; font-size: 12px; border-radius: 4px; transition: background 0.2s ease-in-out; box-shadow: none; }
66
+
67
+ #dpsp-feedback-form-back { float: left; background: #f1f1f1; color: #565656; }
68
+ #dpsp-feedback-form-back:hover { background: #e1e1e1; }
69
+ #dpsp-feedback-form-next,
70
+ #dpsp-feedback-form-send { float: right; background: #00a8ff; color: #fff; }
71
+ #dpsp-feedback-form-next:hover,
72
+ #dpsp-feedback-form-send:hover { background: #0097e6; }
73
+
74
+ #dpsp-feedback-form-send { display: none; }
75
+
76
+ #dpsp-feedback-form-navigation .spinner { display: none; float: none; position: absolute; left: 50%; margin-left: -10px; top: 22px; visibility: visible; }
77
+ #dpsp-feedback-form-navigation a.dpsp-inactive { background: rgba( 0, 168, 255, 0.35 ); }
inc/admin/feedback-form/assets/img/corgi-100x100.png ADDED
Binary file
inc/admin/feedback-form/assets/js/script-admin-feedback-form.js ADDED
@@ -0,0 +1,197 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ jQuery( function($) {
2
+
3
+ function is_email( email ) {
4
+ var re = /^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;
5
+ return re.test(String(email).toLowerCase());
6
+ }
7
+
8
+ var current_panel = 1;
9
+
10
+ /**
11
+ * Trigger feedback form
12
+ *
13
+ */
14
+ $(document).on( 'click', '#dpsp-feedback-button', function() {
15
+
16
+ $(this).toggleClass('dpsp-inactive');
17
+ $('#dpsp-feedback-form-wrapper').toggleClass('dpsp-inactive');
18
+
19
+ });
20
+
21
+ /**
22
+ * Click to select the first options
23
+ *
24
+ */
25
+ $(document).on( 'click', '#dpsp-feedback-form-panel-1 .dpsp-selection-label', function() {
26
+
27
+ current_panel = 2;
28
+
29
+ $('#dpsp-feedback-form-panel-1').removeClass('dpsp-doing').addClass('dpsp-done');
30
+ $('#dpsp-feedback-form-panel-2').removeClass('dpsp-todo').addClass('dpsp-doing');
31
+
32
+ $('#dpsp-feedback-form-navigation').fadeIn(250);
33
+
34
+ setTimeout( function() {
35
+ $('#dpsp-feedback-form-panel-2 textarea').focus();
36
+ }, 300 );
37
+
38
+ });
39
+
40
+ /**
41
+ * Handle textarea functionality
42
+ *
43
+ */
44
+ $(document).on( 'keyup', '#dpsp-feedback-form-panel-2 textarea', function() {
45
+
46
+ var $textarea = $(this);
47
+
48
+ $('#dpsp-feedback-form-char-count').html( parseInt( 80 - $textarea.val().length ) );
49
+
50
+ /* Show counts */
51
+ if( $textarea.val().length > 0 ) {
52
+
53
+ $('#dpsp-feedback-form-description-char-count-1').hide();
54
+ $('#dpsp-feedback-form-description-char-count-2').show();
55
+
56
+ } else {
57
+
58
+ $('#dpsp-feedback-form-description-char-count-2').hide();
59
+ $('#dpsp-feedback-form-description-char-count-1').show();
60
+
61
+ }
62
+
63
+ /* Handle next button */
64
+ if( $textarea.val().length >= 80 ) {
65
+
66
+ $('#dpsp-feedback-form-next').removeClass('dpsp-inactive');
67
+
68
+ $('#dpsp-feedback-form-description-char-count-2').hide();
69
+
70
+ } else {
71
+
72
+ $('#dpsp-feedback-form-next').addClass('dpsp-inactive');
73
+
74
+ }
75
+
76
+ });
77
+
78
+ /**
79
+ * Handle email input functionality
80
+ *
81
+ */
82
+ $(document).on( 'keyup', '#dpsp-feedback-form-panel-3 input[type=email]', function() {
83
+
84
+ var $input = $(this);
85
+
86
+ if( is_email( $input.val() ) ) {
87
+
88
+ $('#dpsp-feedback-form-send').removeClass('dpsp-inactive');
89
+
90
+ } else {
91
+
92
+ $('#dpsp-feedback-form-send').addClass('dpsp-inactive');
93
+
94
+ }
95
+
96
+ });
97
+
98
+ /**
99
+ * Handle back button navigation
100
+ *
101
+ */
102
+ $(document).on( 'click', '#dpsp-feedback-form-back', function(e) {
103
+
104
+ e.preventDefault();
105
+
106
+ $('#dpsp-feedback-form-panel-' + current_panel ).removeClass('dpsp-doing').addClass('dpsp-todo');
107
+
108
+ current_panel--;
109
+
110
+ $('#dpsp-feedback-form-panel-' + current_panel ).removeClass('dpsp-done').addClass('dpsp-doing');
111
+
112
+ if( current_panel == 1 )
113
+ $('#dpsp-feedback-form-navigation').fadeOut(250);
114
+
115
+ if( current_panel == 3 ) {
116
+ $('#dpsp-feedback-form-next').hide();
117
+ $('#dpsp-feedback-form-send').show();
118
+ } else {
119
+ $('#dpsp-feedback-form-next').show();
120
+ $('#dpsp-feedback-form-send').hide();
121
+ }
122
+
123
+ });
124
+
125
+
126
+ /**
127
+ * Handle next button navigation
128
+ *
129
+ */
130
+ $(document).on( 'click', '#dpsp-feedback-form-next', function(e) {
131
+
132
+ e.preventDefault();
133
+
134
+ if( $(this).hasClass('dpsp-inactive') ) {
135
+ $(this).closest('#dpsp-feedback-form-wrapper').find('.dpsp-doing input, .dpsp-doing textarea').focus();
136
+ return false;
137
+ }
138
+
139
+
140
+ $('#dpsp-feedback-form-panel-' + current_panel ).removeClass('dpsp-doing').addClass('dpsp-done');
141
+
142
+ current_panel++;
143
+
144
+ $('#dpsp-feedback-form-panel-' + current_panel ).removeClass('dpsp-todo').addClass('dpsp-doing');
145
+
146
+ setTimeout( function() {
147
+ $('.dpsp-feedback-form-panel input[type=email]').focus();
148
+ }, 300 );
149
+
150
+ if( current_panel == 3 ) {
151
+ $('#dpsp-feedback-form-next').hide();
152
+ $('#dpsp-feedback-form-send').show();
153
+ } else {
154
+ $('#dpsp-feedback-form-next').show();
155
+ $('#dpsp-feedback-form-send').hide();
156
+ }
157
+
158
+ });
159
+
160
+
161
+ /**
162
+ * Handle send button
163
+ *
164
+ */
165
+ $(document).on( 'click', '#dpsp-feedback-form-send', function(e) {
166
+
167
+ e.preventDefault();
168
+
169
+ if( $(this).hasClass('dpsp-inactive') ) {
170
+ $(this).closest('#dpsp-feedback-form-wrapper').find('.dpsp-doing input, .dpsp-doing textarea').focus();
171
+ return false;
172
+ }
173
+
174
+ $('#dpsp-feedback-form-navigation a').fadeOut(250);
175
+ $('#dpsp-feedback-form-navigation .spinner').fadeIn(250);
176
+
177
+ var data = {
178
+ action : 'dpsp_ajax_send_feedback',
179
+ dpsp_token : $('#dpsp_token').val(),
180
+ type : $('#dpsp-feedback-form-panel-1').find('input[type=radio]:checked').val(),
181
+ message : $('#dpsp-feedback-form-panel-2').find('textarea').val(),
182
+ user_email : $('#dpsp-feedback-form-panel-3').find('input[type=email]').val()
183
+ }
184
+
185
+ $.post( ajaxurl, data, function( response ) {
186
+
187
+ $('.dpsp-feedback-form-panel').removeClass('dpsp-doing').fadeOut( 250, function() {
188
+ $('#dpsp-feedback-form-panel-4').removeClass('dpsp-todo').addClass('dpsp-doing').fadeIn();
189
+ });
190
+
191
+ $('#dpsp-feedback-form-navigation .spinner').fadeOut(250);
192
+
193
+ });
194
+
195
+ });
196
+
197
+ });
inc/admin/feedback-form/functions-ajax.php ADDED
@@ -0,0 +1,62 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // Exit if accessed directly
4
+ if ( ! defined( 'ABSPATH' ) ) exit;
5
+
6
+ /**
7
+ * AJAX callback to send the feedback
8
+ *
9
+ */
10
+ function dpsp_ajax_send_feedback() {
11
+
12
+ if( empty( $_POST['dpsp_token'] ) || ! wp_verify_nonce( $_POST['dpsp_token'], 'dpsp_feedback_form' ) ) {
13
+ echo 0;
14
+ wp_die();
15
+ }
16
+
17
+ $_POST = stripslashes_deep( $_POST );
18
+
19
+ if( empty( $_POST['user_email'] ) ) {
20
+ echo 0;
21
+ wp_die();
22
+ }
23
+
24
+ // Set headers
25
+ $headers = array(
26
+ "From: " . sanitize_email( $_POST['user_email'] ),
27
+ "Reply-To: " . sanitize_email( $_POST['user_email'] ),
28
+ );
29
+
30
+ // Message type
31
+ $message = 'Type:';
32
+ $message .= "\n";
33
+ $message .= "---------------------------------------------------------";
34
+ $message .= "\n";
35
+ $message .= sanitize_text_field( $_POST['type'] );
36
+
37
+ // Message content
38
+ $message .= "\n\r";
39
+ $message .= 'Message:';
40
+ $message .= "\n";
41
+ $message .= "---------------------------------------------------------";
42
+ $message .= "\n";
43
+ $message .= sanitize_text_field( $_POST['message'] );
44
+
45
+ // Message user email
46
+ $message .= "\n\r";
47
+ $message .= 'User email:';
48
+ $message .= "\n";
49
+ $message .= "---------------------------------------------------------";
50
+ $message .= "\n";
51
+ $message .= sanitize_text_field( $_POST['user_email'] );
52
+
53
+
54
+ // Send the email
55
+ $sent = wp_mail( 'support@devpups.com', 'Grow by Mediavine User Feedback', $message, $headers );
56
+
57
+ // Return
58
+ echo ( $sent ? 1 : 0 );
59
+ wp_die();
60
+
61
+ }
62
+ add_action( 'wp_ajax_dpsp_ajax_send_feedback', 'dpsp_ajax_send_feedback' );
inc/admin/feedback-form/functions.php ADDED
@@ -0,0 +1,37 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // Exit if accessed directly
4
+ if ( ! defined( 'ABSPATH' ) ) exit;
5
+
6
+
7
+ /**
8
+ * Enqueue admin scripts for the feedback form
9
+ *
10
+ */
11
+ function dpsp_enqueue_admin_scripts_feedback() {
12
+
13
+ // Plugin styles
14
+ wp_register_style( 'dpsp-style-feedback', DPSP_PLUGIN_DIR_URL . 'inc/admin/feedback-form/assets/css/style-admin-feedback-form.css', array(), DPSP_VERSION );
15
+ wp_enqueue_style( 'dpsp-style-feedback' );
16
+
17
+ // Plugin script
18
+ wp_register_script( 'dpsp-script-feedback', DPSP_PLUGIN_DIR_URL . 'inc/admin/feedback-form/assets/js/script-admin-feedback-form.js', array( 'jquery' ), DPSP_VERSION );
19
+ wp_enqueue_script( 'dpsp-script-feedback' );
20
+
21
+ }
22
+ add_action( 'dpsp_enqueue_admin_scripts', 'dpsp_enqueue_admin_scripts_feedback' );
23
+
24
+
25
+ /**
26
+ * Outputs the feedback form in the admin footer
27
+ *
28
+ */
29
+ function dpsp_output_feedback_form() {
30
+
31
+ if( empty( $_GET['page'] ) || false === strpos( $_GET['page'], 'dpsp' ) )
32
+ return;
33
+
34
+ include 'views/view-feedback-form.php';
35
+
36
+ }
37
+ add_action( 'admin_footer', 'dpsp_output_feedback_form' );
inc/admin/feedback-form/views/view-feedback-form.php ADDED
@@ -0,0 +1,99 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // Exit if accessed directly
4
+ if ( ! defined( 'ABSPATH' ) ) exit;
5
+
6
+ ?>
7
+
8
+ <!-- Feedback form button -->
9
+ <div id="dpsp-feedback-button" class="dpsp-inactive">
10
+
11
+ <img src="<?php echo DPSP_PLUGIN_DIR_URL . 'inc/admin/feedback-form/assets/src/img/corgi-100x100.png' ?>" />
12
+ <span class="dpsp-close dashicons dashicons-no-alt"></span>
13
+
14
+ </div>
15
+
16
+ <!-- Feedback form -->
17
+ <div id="dpsp-feedback-form-wrapper" class="dpsp-inactive">
18
+
19
+ <!-- Form Header -->
20
+ <div id="dpsp-feedback-form-header">
21
+
22
+ <div id="dpsp-feedback-form-header-image">
23
+ <img src="<?php echo DPSP_PLUGIN_DIR_URL . 'inc/admin/feedback-form/assets/src/img/corgi-100x100.png' ?>" />
24
+ </div>
25
+
26
+ <strong><?php echo __( "I'm here to help", 'social-pug' ); ?></strong>
27
+
28
+ </div>
29
+
30
+ <!-- Form Inner -->
31
+ <div id="dpsp-feedback-form-inner">
32
+
33
+ <!-- Panel 1 -->
34
+ <div id="dpsp-feedback-form-panel-1" class="dpsp-feedback-form-panel dpsp-doing">
35
+
36
+ <label class="dpsp-feedback-form-panel-label"><?php echo __( 'Hey there! How can I help you?', 'social-pug' ); ?></label>
37
+
38
+ <input id="dpsp-feedback-form-radio-bug" type="radio" name="issue" value="Bug" />
39
+ <label for="dpsp-feedback-form-radio-bug" class="dpsp-selection-label"><?php echo __( 'I think I found a bug. Something is not working right.', 'social-pug' ); ?></label>
40
+
41
+ <input id="dpsp-feedback-form-radio-setup" type="radio" name="issue" value="Setup" />
42
+ <label for="dpsp-feedback-form-radio-setup" class="dpsp-selection-label"><?php echo __( "I don't know how to set up the plugin.", 'social-pug' ); ?></label>
43
+
44
+ <input id="dpsp-feedback-form-radio-feature" type="radio" name="issue" value="Feature" />
45
+ <label for="dpsp-feedback-form-radio-feature" class="dpsp-selection-label"><?php echo __( 'I want to propose a new feature for the plugin.', 'social-pug' ); ?></label>
46
+
47
+ <input id="dpsp-feedback-form-radio-other" type="radio" name="issue" value="Other" />
48
+ <label for="dpsp-feedback-form-radio-other" class="dpsp-selection-label"><?php echo __( 'Some other thing...', 'social-pug' ); ?></label>
49
+
50
+ </div>
51
+
52
+ <!-- Panel 2 -->
53
+ <div id="dpsp-feedback-form-panel-2" class="dpsp-feedback-form-panel dpsp-todo">
54
+
55
+ <label class="dpsp-feedback-form-panel-label"><?php echo __( 'Please detail a bit more:', 'social-pug' ); ?></label>
56
+
57
+ <textarea placeholder="<?php echo __( 'Write the details here...', 'social-pug' ); ?>"></textarea>
58
+
59
+ <p id="dpsp-feedback-form-description-char-count-1" class="description"><?php echo __( 'Minimum 80 characters', 'social-pug' ); ?></p>
60
+ <p id="dpsp-feedback-form-description-char-count-2" class="description"><?php echo sprintf( __( '%s characters remaining', 'social-pug' ), '<span id="dpsp-feedback-form-char-count">80</span>' ); ?></p>
61
+
62
+ </div>
63
+
64
+ <!-- Panel 3 -->
65
+ <div id="dpsp-feedback-form-panel-3" class="dpsp-feedback-form-panel dpsp-todo">
66
+
67
+ <label class="dpsp-feedback-form-panel-label"><?php echo __( 'Please enter your email address:', 'social-pug' ); ?></label>
68
+
69
+ <input type="email" value="" placeholder="<?php echo __( 'Write the email address here...', 'social-pug' ); ?>" />
70
+
71
+ <p class="description"><?php echo __( "Let us know where to contact you regarding your request.", 'social-pug' ); ?></p>
72
+
73
+ </div>
74
+
75
+ <!-- Panel 4 - Success message -->
76
+ <div id="dpsp-feedback-form-panel-4" class="dpsp-feedback-form-panel dpsp-todo">
77
+
78
+ <span class="dashicons dashicons-yes"></span>
79
+ <p><?php echo __( 'Thank you for reaching out! We will get back to you as soon as possible.', 'social-pug' ); ?></p>
80
+
81
+ </div>
82
+
83
+ </div>
84
+
85
+ <!-- Form Navigation -->
86
+ <div id="dpsp-feedback-form-navigation">
87
+
88
+ <a id="dpsp-feedback-form-back" href="#"><?php echo __( 'Back', 'social-pug' ); ?></a>
89
+ <a id="dpsp-feedback-form-next" class="dpsp-inactive" href="#"><?php echo __( 'Next', 'social-pug' ); ?></a>
90
+ <a id="dpsp-feedback-form-send" class="dpsp-inactive" href="#"><?php echo __( 'Send', 'social-pug' ); ?></a>
91
+
92
+ <div class="spinner"><!-- --></div>
93
+
94
+ </div>
95
+
96
+ <!-- Nonce -->
97
+ <?php wp_nonce_field( 'dpsp_feedback_form', 'dpsp_token', false ); ?>
98
+
99
+ </div>
inc/admin/submenu-page-content.php ADDED
@@ -0,0 +1,55 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /*
3
+ * Function that creates the sub-menu item and page for the content location of the share buttons
4
+ *
5
+ *
6
+ * @return void
7
+ *
8
+ */
9
+ function dpsp_register_content_subpage() {
10
+ add_submenu_page( 'dpsp-social-pug', __('Inline Content', 'social-pug'), __('Inline Content', 'social-pug'), 'manage_options', 'dpsp-content', 'dpsp_content_subpage' );
11
+ }
12
+ add_action( 'admin_menu', 'dpsp_register_content_subpage' );
13
+
14
+
15
+ /*
16
+ * Function that adds content to the content icons subpage
17
+ *
18
+ * @return string
19
+ *
20
+ */
21
+ function dpsp_content_subpage() {
22
+
23
+ include_once 'views/view-submenu-page-content.php';
24
+
25
+ }
26
+
27
+
28
+ function dpsp_content_register_settings() {
29
+
30
+ register_setting( 'dpsp_location_content', 'dpsp_location_content', 'dpsp_content_settings_sanitize' );
31
+
32
+ }
33
+ add_action( 'admin_init', 'dpsp_content_register_settings' );
34
+
35
+
36
+ /*
37
+ * Filter and sanitize settings
38
+ *
39
+ * @param array $new_settings
40
+ *
41
+ */
42
+ function dpsp_content_settings_sanitize( $new_settings ) {
43
+
44
+ // Save default values even if values do not exist
45
+ if( !isset( $new_settings['networks'] ) )
46
+ $new_settings['networks'] = array();
47
+
48
+ if( !isset( $new_settings['button_style'] ) )
49
+ $new_settings['button_style'] = 1;
50
+
51
+ $new_settings = dpsp_array_strip_script_tags( $new_settings );
52
+
53
+ return $new_settings;
54
+
55
+ }
inc/admin/submenu-page-extensions.php ADDED
@@ -0,0 +1,27 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Function that creates the sub-menu item and page for the extra tools page
4
+ *
5
+ * @return void
6
+ *
7
+ */
8
+ function dpsp_register_extensions_subpage() {
9
+ add_submenu_page( 'dpsp-social-pug', __('Extensions', 'social-pug'), '<span style="color: orange;">' . __('Extensions', 'social-pug') . '</span>', 'manage_options', 'dpsp-extensions', 'dpsp_extensions_subpage' );
10
+ }
11
+ add_action( 'admin_menu', 'dpsp_register_extensions_subpage' );
12
+
13
+
14
+ /**
15
+ * Function that adds content to the extensions subpage
16
+ *
17
+ * @return string
18
+ *
19
+ */
20
+ function dpsp_extensions_subpage() {
21
+
22
+ if( ! empty( $_GET['sub-page'] ) && $_GET['sub-page'] == 'opt-in-hound' )
23
+ include_once 'views/view-submenu-page-extensions-sub-page-opt-in-hound.php';
24
+ else
25
+ include_once 'views/view-submenu-page-extensions.php';
26
+
27
+ }
inc/admin/submenu-page-settings.php ADDED
@@ -0,0 +1,79 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /*
3
+ * Function that creates the sub-menu item and page for the settings page
4
+ *
5
+ *
6
+ * @return void
7
+ *
8
+ */
9
+ function dpsp_register_settings_subpage() {
10
+ add_submenu_page( 'dpsp-social-pug', __('Settings', 'social-pug'), __('Settings', 'social-pug'), 'manage_options', 'dpsp-settings', 'dpsp_settings_subpage' );
11
+ }
12
+ add_action( 'admin_menu', 'dpsp_register_settings_subpage' );
13
+
14
+
15
+ /*
16
+ * Function that adds content to the settings subpage
17
+ *
18
+ * @return string
19
+ *
20
+ */
21
+ function dpsp_settings_subpage() {
22
+
23
+ include_once 'views/view-submenu-page-settings.php';
24
+
25
+ }
26
+
27
+
28
+ function dpsp_settings_register_settings() {
29
+
30
+ register_setting( 'dpsp_settings', 'dpsp_settings', 'dpsp_settings_sanitize' );
31
+
32
+ }
33
+ add_action( 'admin_init', 'dpsp_settings_register_settings' );
34
+
35
+
36
+ /**
37
+ * Filter and sanitize settings
38
+ *
39
+ * @param array $new_settings
40
+ *
41
+ */
42
+ function dpsp_settings_sanitize( $new_settings ) {
43
+
44
+ $new_settings = dpsp_array_strip_script_tags( $new_settings );
45
+
46
+ return $new_settings;
47
+
48
+ }
49
+
50
+
51
+ /**
52
+ * Hooks to generate a Facebook App access token that will be used for retrieving share counts
53
+ *
54
+ */
55
+ function dpsp_generate_facebook_app_access_token( $new_settings = array(), $old_settings = array() ) {
56
+
57
+ if( empty( $new_settings['facebook_app_id'] ) || empty( $new_settings['facebook_app_secret'] ) )
58
+ return $new_settings;
59
+
60
+
61
+ $response = wp_remote_post( add_query_arg( array( 'client_id' => trim( $new_settings['facebook_app_id'] ), 'client_secret' => trim( $new_settings['facebook_app_secret'] ), 'grant_type' => 'client_credentials' ), 'https://graph.facebook.com/oauth/access_token' ) );
62
+
63
+ if( is_wp_error( $response ) )
64
+ return $new_settings;
65
+
66
+ if( wp_remote_retrieve_response_code( $response ) !== 200 )
67
+ return $new_settings;
68
+
69
+
70
+ $body = wp_remote_retrieve_body( $response );
71
+ $body = json_decode( $body, true );
72
+
73
+ if( ! empty( $body['access_token'] ) && strpos( $body['access_token'], '|' ) !== false )
74
+ $new_settings['facebook_app_access_token'] = $body['access_token'];
75
+
76
+ return $new_settings;
77
+
78
+ }
79
+ add_filter( 'pre_update_option_dpsp_settings', 'dpsp_generate_facebook_app_access_token', 10, 2 );
inc/admin/submenu-page-sidebar.php ADDED
@@ -0,0 +1,55 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /*
4
+ * Function that creates the sub-menu item and page for the floating sidebar location of the share buttons
5
+ *
6
+ * @return void
7
+ *
8
+ */
9
+ function dpsp_register_floating_sidebar_subpage() {
10
+ add_submenu_page( 'dpsp-social-pug', __('Floating Sidebar', 'social-pug'), __('Floating Sidebar', 'social-pug'), 'manage_options', 'dpsp-sidebar', 'dpsp_sidebar_subpage' );
11
+ }
12
+ add_action( 'admin_menu', 'dpsp_register_floating_sidebar_subpage' );
13
+
14
+
15
+ /*
16
+ * Function that adds content to the floating sidebar subpage
17
+ *
18
+ * @return string
19
+ *
20
+ */
21
+ function dpsp_sidebar_subpage() {
22
+
23
+ include_once 'views/view-submenu-page-sidebar.php';
24
+
25
+ }
26
+
27
+
28
+ function dpsp_sidebar_register_settings() {
29
+
30
+ register_setting( 'dpsp_location_sidebar', 'dpsp_location_sidebar', 'dpsp_sidebar_settings_sanitize' );
31
+
32
+ }
33
+ add_action( 'admin_init', 'dpsp_sidebar_register_settings' );
34
+
35
+
36
+ /*
37
+ * Filter and sanitize settings
38
+ *
39
+ * @param array $new_settings
40
+ *
41
+ */
42
+ function dpsp_sidebar_settings_sanitize( $new_settings ) {
43
+
44
+ // Save default values even if values do not exist
45
+ if( !isset( $new_settings['networks'] ) )
46
+ $new_settings['networks'] = array();
47
+
48
+ if( !isset( $new_settings['button_style'] ) )
49
+ $new_settings['button_style'] = 1;
50
+
51
+ $new_settings = dpsp_array_strip_script_tags( $new_settings );
52
+
53
+ return $new_settings;
54
+
55
+ }
inc/admin/submenu-page-toolkit.php ADDED
@@ -0,0 +1,25 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /*
3
+ * Function that creates the sub-menu item and page for the tools page
4
+ *
5
+ *
6
+ * @return void
7
+ *
8
+ */
9
+ function dpsp_register_toolkit_subpage() {
10
+ add_submenu_page( 'dpsp-social-pug', __('Toolkit', 'social-pug'), __('Toolkit', 'social-pug'), 'manage_options', 'dpsp-toolkit', 'dpsp_toolkit_subpage' );
11
+ }
12
+ add_action( 'admin_menu', 'dpsp_register_toolkit_subpage' );
13
+
14
+
15
+ /*
16
+ * Function that adds content to the toolkit subpage
17
+ *
18
+ * @return string
19
+ *
20
+ */
21
+ function dpsp_toolkit_subpage() {
22
+
23
+ include_once 'views/view-submenu-page-toolkit.php';
24
+
25
+ }
inc/admin/views/view-submenu-page-content.php ADDED
@@ -0,0 +1,118 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <form method="post" action="options.php">
2
+
3
+ <?php
4
+ $dpsp_location_content = get_option( 'dpsp_location_content', 'not_set' );
5
+ settings_fields( 'dpsp_location_content' );
6
+ ?>
7
+
8
+ <div class="dpsp-page-wrapper dpsp-page-content wrap">
9
+
10
+ <!-- Page Title -->
11
+ <h1 class="dpsp-page-title">
12
+ <?php _e('Configure Content Sharing Buttons', 'social-pug'); ?>
13
+
14
+ <input type="hidden" name="dpsp_buttons_location" value="dpsp_location_content" />
15
+ <input type="hidden" name="dpsp_location_content[active]" value="<?php echo ( isset( $dpsp_location_content["active"] ) ? 1 : '' ); ?>" <?php echo ( !isset( $dpsp_location_content["active"] ) ? 'disabled' : '' ); ?> />
16
+ </h1>
17
+
18
+
19
+ <!-- Networks Selectable and Sortable Panels -->
20
+ <div id="dpsp-social-platforms-wrapper" class="dpsp-card">
21
+
22
+ <div class="dpsp-card-header">
23
+ <?php _e( 'Social Networks', 'social-pug' ); ?>
24
+ <a id="dpsp-select-networks" class="dpsp-button-secondary" href="#"><?php echo __( 'Select Networks', 'social-pug' ) ?></a>
25
+ </div>
26
+
27
+ <div id="dpsp-sortable-networks-empty" class="dpsp-card-inner <?php echo ( empty( $dpsp_location_content['networks'] ) ? 'dpsp-active' : '' ); ?>">
28
+ <p><?php _e( 'Select which social buttons to display', 'social-pug' ); ?></p>
29
+ </div>
30
+
31
+ <?php echo dpsp_output_sortable_networks( ( ! empty( $dpsp_location_content['networks'] ) ? $dpsp_location_content['networks'] : array() ), 'dpsp_location_content' ); ?>
32
+
33
+ <?php
34
+ $available_networks = dpsp_get_networks();
35
+ echo dpsp_output_selectable_networks( $available_networks, ( ! empty( $dpsp_location_content['networks'] ) ? $dpsp_location_content['networks'] : array() ) );
36
+ ?>
37
+
38
+ </div>
39
+
40
+
41
+ <!-- General Display Settings -->
42
+ <div class="dpsp-card">
43
+
44
+ <div class="dpsp-card-header">
45
+ <?php _e( 'Display Settings', 'social-pug' ); ?>
46
+ </div>
47
+
48
+ <div class="dpsp-card-inner">
49
+
50
+ <?php dpsp_settings_field( 'select', 'dpsp_location_content[display][shape]', ( isset($dpsp_location_content['display']['shape']) ? $dpsp_location_content['display']['shape'] : '' ), __( 'Button shape', 'social-pug' ), array( 'rectangular' => __( 'Rectangular', 'social-pug' ), 'rounded' => __( 'Rounded', 'social-pug' ), 'circle' => __( 'Circle', 'social-pug' ) ) ); ?>
51
+
52
+ <?php dpsp_settings_field( 'switch', 'dpsp_location_content[display][icon_animation]', ( isset( $dpsp_location_content['display']['icon_animation']) ? $dpsp_location_content['display']['icon_animation'] : '' ), __( 'Show icon animation', 'social-pug' ), array('yes'), __( 'Will animate the social media icon when the user hovers over the button.', 'social-pug' ) ); ?>
53
+
54
+ <?php dpsp_settings_field( 'select', 'dpsp_location_content[display][position]', ( isset($dpsp_location_content['display']['position']) ? $dpsp_location_content['display']['position'] : '' ), __( 'Buttons position', 'social-pug' ), array( 'top' => __( 'Above Content', 'social-pug' ), 'bottom' => __( 'Below Content', 'social-pug' ), 'both' => __( 'Above and Below', 'social-pug' ) ) ); ?>
55
+
56
+ <?php dpsp_settings_field( 'select', 'dpsp_location_content[display][column_count]', ( isset($dpsp_location_content['display']['column_count']) ? $dpsp_location_content['display']['column_count'] : '' ), __( 'Number of columns', 'social-pug' ), array( 'auto' => __( 'Width Auto', 'social-pug' ), '1' => __( '1 column', 'social-pug' ), '2' => __( '2 columns', 'social-pug' ), '3' => __( '3 columns', 'social-pug' ), '4' => __( '4 columns', 'social-pug' ), '5' => __( '5 columns', 'social-pug' ), '6' => __( '6 columns', 'social-pug' ) ) ); ?>
57
+
58
+ <?php dpsp_settings_field( 'text', 'dpsp_location_content[display][message]', ( isset( $dpsp_location_content['display']['message']) ? $dpsp_location_content['display']['message'] : 'Sharing is caring!' ), __( 'Share text', 'social-pug' ), '' ); ?>
59
+
60
+ <?php dpsp_settings_field( 'switch', 'dpsp_location_content[display][show_labels]', ( isset( $dpsp_location_content['display']['show_labels']) ? $dpsp_location_content['display']['show_labels'] : '' ), __( 'Show button labels', 'social-pug' ), array('yes') ); ?>
61
+
62
+ <?php dpsp_settings_field( 'switch', 'dpsp_location_content[display][spacing]', ( isset( $dpsp_location_content['display']['spacing']) ? $dpsp_location_content['display']['spacing'] : '' ), __( 'Button spacing', 'social-pug' ), array('yes') ); ?>
63
+
64
+ <?php dpsp_settings_field( 'switch', 'dpsp_location_content[display][show_mobile]', ( isset( $dpsp_location_content['display']['show_mobile']) ? $dpsp_location_content['display']['show_mobile'] : '' ), __( 'Show on mobile', 'social-pug' ), array('yes') ); ?>
65
+
66
+ <?php dpsp_settings_field( 'text', 'dpsp_location_content[display][screen_size]', ( isset( $dpsp_location_content['display']['screen_size']) ? $dpsp_location_content['display']['screen_size'] : '' ), __( 'Mobile screen width (pixels)', 'social-pug' ), '', __( 'For screen widths smaller than this value ( in pixels ) the buttons will be displayed on screen if the show on mobile option is checked.', 'social-pug' ) ); ?>
67
+
68
+ </div>
69
+
70
+ </div>
71
+
72
+
73
+ <!-- Share Counts -->
74
+ <div class="dpsp-card">
75
+
76
+ <div class="dpsp-card-header">
77
+ <?php _e( 'Buttons Share Counts', 'social-pug' ); ?>
78
+ </div>
79
+
80
+ <div class="dpsp-card-inner">
81
+
82
+ <?php dpsp_settings_field( 'switch', 'dpsp_location_content[display][show_count]', ( isset( $dpsp_location_content['display']['show_count']) ? $dpsp_location_content['display']['show_count'] : '' ), __( 'Show share count', 'social-pug' ), array('yes'), __( 'Display the share count for each social network.', 'social-pug' ) ); ?>
83
+
84
+ <?php dpsp_settings_field( 'switch', 'dpsp_location_content[display][show_count_total]', ( isset( $dpsp_location_content['display']['show_count_total']) ? $dpsp_location_content['display']['show_count_total'] : '' ), __( 'Show total share count', 'social-pug' ), array('yes'), __( 'Display the share count for all social networks.', 'social-pug' ) ); ?>
85
+
86
+ <?php dpsp_settings_field( 'select', 'dpsp_location_content[display][total_count_position]', ( isset( $dpsp_location_content['display']['total_count_position'] ) ? $dpsp_location_content['display']['total_count_position'] : '' ), __( 'Total count position', 'social-pug' ), array( 'before' => __( 'Before Buttons', 'social-pug' ), 'after' => __( 'After Buttons', 'social-pug' ) ) ); ?>
87
+
88
+ <?php dpsp_settings_field( 'switch', 'dpsp_location_content[display][count_round]', ( isset( $dpsp_location_content['display']['count_round']) ? $dpsp_location_content['display']['count_round'] : '' ), __( 'Share count round', 'social-pug' ), array('yes'), __( 'If the share count for each network is bigger than 1000 it will be rounded to one decimal ( eg. 1267 will show as 1.2k ). Applies to Total Share Counts as well.', 'social-pug' ) ); ?>
89
+
90
+ </div>
91
+
92
+ </div>
93
+
94
+
95
+ <!-- Post Type Display Settings -->
96
+ <div class="dpsp-card">
97
+
98
+ <div class="dpsp-card-header">
99
+ <?php _e( 'Post Type Display Settings', 'social-pug' ); ?>
100
+ </div>
101
+
102
+ <div class="dpsp-card-inner">
103
+
104
+ <?php dpsp_settings_field( 'checkbox', 'dpsp_location_content[post_type_display][]', ( isset( $dpsp_location_content['post_type_display']) ? $dpsp_location_content['post_type_display'] : array() ), '', dpsp_get_post_types() ); ?>
105
+
106
+ </div>
107
+
108
+ </div>
109
+
110
+
111
+ <!-- Save Changes Button -->
112
+ <input type="hidden" name="action" value="update" />
113
+ <p class="submit"><input type="submit" class="dpsp-button-primary" value="<?php _e( 'Save Changes' ); ?>" /></p>
114
+
115
+ </div>
116
+
117
+ </form>
118
+ <?php do_action( 'dpsp_submenu_page_bottom' ); ?>
inc/admin/views/view-submenu-page-extensions-sub-page-opt-in-hound.php ADDED
@@ -0,0 +1,86 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <div class="dpsp-page-wrapper dpsp-page-extensions dpsp-sub-page-opt-in-hound wrap">
2
+
3
+ <div id="opt-in-hound-promo-box">
4
+ <div id="opt-in-hound-promo-box-banner">
5
+ <img src="<?php echo DPSP_PLUGIN_DIR_URL . '/assets/src/img/opt-in-hound-banner.png'; ?>" />
6
+ </div>
7
+
8
+ <div id="opt-in-hound-promo-box-inner">
9
+
10
+ <!-- Title and Sub-title -->
11
+ <br /><h1 class="opt-in-hound-promo-box-title"><?php echo __( 'Grow Your Email List in a Simple Way', 'social-pug' ); ?><br /><span style="display: block; margin-top: 20px;"><?php echo __( 'Create beautiful email subscription popup and widget forms<br /> with just a few clicks.', 'social-pug' ); ?></span></h1>
12
+
13
+ <!-- Call to Action -->
14
+ <div class="opt-in-hound-promo-box-cta">
15
+ <a class="button-primary" href="<?php echo wp_nonce_url( admin_url( 'update.php?action=install-plugin&plugin=opt-in-hound' ), 'install-plugin_opt-in-hound' ); ?>"><?php echo __( 'Install Now', 'social-pug' ); ?></a>
16
+ </div>
17
+
18
+ <hr />
19
+
20
+ <!-- Subscribe from custom opt-ins -->
21
+ <h2 class="opt-in-hound-promo-box-sub-title"><strong><?php echo __( 'Subscribe users from custom opt-ins', 'social-pug' ); ?></strong></h2>
22
+
23
+ <div class="dpsp-row dpsp-big-padding">
24
+ <div class="dpsp-col-1-3">
25
+ <div class="browser-window">
26
+ <div class="browser-header"></div>
27
+ <img src="<?php echo DPSP_PLUGIN_DIR_URL . '/assets/src/img/tool-opt-in-icon-pop-up.png'; ?>" />
28
+ </div>
29
+ <h4><?php echo __( 'Email Opt-in Pop-up', 'social-pug' ); ?></h4>
30
+ <p><?php echo __( 'Add email opt-in pop-up forms in your posts and pages.', 'social-pug' ); ?></p>
31
+ </div>
32
+
33
+ <div class="dpsp-col-1-3">
34
+ <div class="browser-window">
35
+ <div class="browser-header"></div>
36
+ <img src="<?php echo DPSP_PLUGIN_DIR_URL . '/assets/src/img/tool-opt-in-icon-widget.png'; ?>" />
37
+ </div>
38
+ <h4><?php echo __( 'Email Opt-in Widget', 'social-pug' ); ?></h4>
39
+ <p><?php echo __( 'Add email opt-in widget forms in any widget area.', 'social-pug' ); ?></p>
40
+ </div>
41
+
42
+ <div class="dpsp-col-1-3">
43
+ <div class="browser-window">
44
+ <div class="browser-header"></div>
45
+ <img src="<?php echo DPSP_PLUGIN_DIR_URL . '/assets/src/img/tool-opt-in-icon-fly-in.png'; ?>" />
46
+ </div>
47
+ <h4><?php echo __( 'Email Opt-in Fly-in', 'social-pug' ); ?></h4>
48
+ <p><?php echo __( 'Add email opt-in fly-in forms in your posts and pages.', 'social-pug' ); ?></p>
49
+ </div>
50
+ </div>
51
+
52
+ <div class="dpsp-row dpsp-big-padding">
53
+ <div class="dpsp-col-1-3">
54
+ <div class="browser-window">
55
+ <div class="browser-header"></div>
56
+ <img src="<?php echo DPSP_PLUGIN_DIR_URL . '/assets/src/img/tool-opt-in-icon-shortcode.png'; ?>" />
57
+ </div>
58
+ <h4><?php echo __( 'Email Opt-in Shortcode', 'social-pug' ); ?></h4>
59
+ <p><?php echo __( 'Place email opt-in forms anywhere in your pages with the shortcode.', 'social-pug' ); ?></p>
60
+ </div>
61
+
62
+ <div class="dpsp-col-1-3">
63
+ <div class="browser-window">
64
+ <div class="browser-header"></div>
65
+ <img src="<?php echo DPSP_PLUGIN_DIR_URL . '/assets/src/img/tool-opt-in-icon-after-content.png'; ?>" />
66
+ </div>
67
+ <h4><?php echo __( 'Email Opt-in After Content', 'social-pug' ); ?></h4>
68
+ <p><?php echo __( 'Add email opt-in forms after your posts and pages content.', 'social-pug' ); ?></p>
69
+ </div>
70
+ </div>
71
+
72
+ <hr />
73
+
74
+ <h1 class="opt-in-hound-promo-box-title"><span style="display: block;"><?php echo __( 'Simple. Flexible. Reliable.', 'social-pug' ); ?></span></h1>
75
+
76
+ <!-- Call to Action -->
77
+ <div class="opt-in-hound-promo-box-cta">
78
+ <a class="button-primary" href="<?php echo wp_nonce_url( admin_url( 'update.php?action=install-plugin&plugin=opt-in-hound' ), 'install-plugin_opt-in-hound' ); ?>"><?php echo __( 'Install Now', 'social-pug' ); ?></a>
79
+ </div>
80
+
81
+ <br />
82
+
83
+ </div>
84
+ </div>
85
+
86
+ </div>
inc/admin/views/view-submenu-page-extensions.php ADDED
@@ -0,0 +1,102 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <div class="dpsp-page-wrapper dpsp-page-extensions wrap">
2
+
3
+ <h1 class="dpsp-page-title"><?php echo __( 'All Social Share Tools in One Plugin', 'social-pug' ); ?></h1>
4
+
5
+ <p><?php echo __( 'Get <a href="https://marketplace.mediavine.com/grow-social-pro/" target="_blank">Grow by Mediavine, Social Pro</a> to have access to even more tools and offer your users a beautiful social sharing experience.', 'social-pug' ); ?></p>
6
+
7
+ <p><?php echo __( 'To gain immediate access to the tools below, <a href="https://marketplace.mediavine.com/grow-social-pro/" target="_blank">have a look at our pricing.</a>', 'social-pug' ); ?></p>
8
+
9
+ <div class="dpsp-row dpsp-m-padding">
10
+ <?php
11
+ $tools = array();
12
+
13
+ $tools['premium_networks'] = array(
14
+ 'name' => __( 'Social Networks Pack', 'social-pug' ),
15
+ 'img' => 'assets/src/img/extension-networks.png',
16
+ 'desc' => __( 'Take advantage of all the social networks available.', 'social-pug' ),
17
+ 'url' => 'https://marketplace.mediavine.com/grow-social-pro/?utm_source=plugin-extensions&amp;utm_medium=social-networks-pack&amp;utm_campaign=social-pug#social-share-buttons'
18
+ );
19
+
20
+ $tools['share_mobile'] = array(
21
+ 'name' => __( 'Share Mobile Sticky', 'social-pug' ),
22
+ 'img' => 'assets/src/img/tool-mobile.png',
23
+ 'desc' => __( 'Add a mobile sticky share footer to your posts and pages.', 'social-pug' ),
24
+ 'url' => 'https://marketplace.mediavine.com/grow-social-pro/?utm_source=plugin-extensions&amp;utm_medium=share-mobile-sticky&amp;utm_campaign=social-pug#share-mobile-sticky'
25
+ );
26
+
27
+ $tools['share_pop_up'] = array(
28
+ 'name' => __( 'Share Pop-Up', 'social-pug' ),
29
+ 'img' => 'assets/src/img/tool-pop-up.png',
30
+ 'desc' => __( 'Add a simple share pop-up that has custom triggers.', 'social-pug' ),
31
+ 'url' => 'https://marketplace.mediavine.com/grow-social-pro/?utm_source=plugin-extensions&amp;utm_medium=share-pop-up&amp;utm_campaign=social-pug#share-pop-up'
32
+ );
33
+
34
+ $tools['share_image'] = array(
35
+ 'name' => __( 'Image Hover Pinterest Button', 'social-pug' ),
36
+ 'img' => 'assets/src/img/tool-image-hover-pinterest.png',
37
+ 'desc' => __( 'Add a Pinterest button to your single posts images when a user hovers on them.', 'social-pug' ),
38
+ 'url' => 'https://marketplace.mediavine.com/grow-social-pro/?utm_source=plugin-extensions&amp;utm_medium=share-image&amp;utm_campaign=social-pug#share-pinterest-hover'
39
+ );
40
+
41
+ $tools['follow_widget'] = array(
42
+ 'name' => __( 'Follow Buttons Widget', 'social-pug' ),
43
+ 'img' => 'assets/src/img/tool-follow-widget.png',
44
+ 'desc' => __( 'Link your social profiles with the help of the follow buttons.', 'social-pug' ),
45
+ 'url' => 'https://marketplace.mediavine.com/grow-social-pro/?utm_source=plugin-extensions&amp;utm_medium=follow-buttons-widget&amp;utm_campaign=social-pug#social-share-buttons'
46
+ );
47
+
48
+ $tools['click_to_tweet'] = array(
49
+ 'name' => __( 'Click to Tweet', 'social-pug' ),
50
+ 'img' => 'assets/src/img/extension-ctt.png',
51
+ 'desc' => __( 'Add custom tweetable quotes anywhere in your content.', 'social-pug' ),
52
+ 'url' => 'https://marketplace.mediavine.com/grow-social-pro/?utm_source=plugin-extensions&amp;utm_medium=click-to-tweet&amp;utm_campaign=social-pug#sharable-quotes'
53
+ );
54
+
55
+ $tools['branch_shortening'] = array(
56
+ 'name' => __( 'Branch Integration', 'social-pug' ),
57
+ 'img' => 'assets/src/img/extension-branch.png',
58
+ 'desc' => __( 'Shorten share links with the help of Branch.', 'social-pug' ),
59
+ 'url' => 'https://marketplace.mediavine.com/grow-social-pro/?utm_source=plugin-extensions&amp;utm_medium=share-branch&amp;utm_campaign=social-pug#share-bitly-ga'
60
+ );
61
+
62
+ $tools['bitly_shortening'] = array(
63
+ 'name' => __( 'Bitly Integration', 'social-pug' ),
64
+ 'img' => 'assets/src/img/extension-bitly.png',
65
+ 'desc' => __( 'Shorten share links with the help of Bitly.', 'social-pug' ),
66
+ 'url' => 'https://marketplace.mediavine.com/grow-social-pro/?utm_source=plugin-extensions&amp;utm_medium=share-bitly&amp;utm_campaign=social-pug#share-bitly-ga'
67
+ );
68
+
69
+ $tools['ga_utm_tracking'] = array(
70
+ 'name' => __( 'Analytics UTM Tracking', 'social-pug' ),
71
+ 'img' => 'assets/src/img/extension-ga-utm-tracking.png',
72
+ 'desc' => __( 'Track shared links with the help of the UTM parameters.', 'social-pug' ),
73
+ 'url' => 'https://marketplace.mediavine.com/grow-social-pro/?utm_source=plugin-extensions&amp;utm_medium=share-utm-tracking&amp;utm_campaign=social-pug#share-bitly-ga'
74
+ );
75
+
76
+ foreach( $tools as $tool_slug => $tool )
77
+ dpsp_output_tool_box( $tool_slug, $tool );
78
+ ?>
79
+ </div><!-- End of Share Tools -->
80
+
81
+
82
+ <?php /*
83
+ <h1 class="dpsp-page-title" style="margin-top: 25px;"><?php echo __( 'Recommended Plugins', 'social-pug' ); ?></h1>
84
+
85
+ <div class="dpsp-row dpsp-m-padding">
86
+ <?php
87
+ $tools = array();
88
+
89
+ $tools['premium_networks'] = array(
90
+ 'name' => __( 'SkyePress - Auto Post and Schedule to Social Media', 'social-pug' ),
91
+ 'img' => 'assets/src/img/skyepress-social-pug-promo.png',
92
+ 'desc' => __( 'Auto Post to your Twitter, Facebook and LinkedIn profiles and much more...', 'social-pug' ),
93
+ 'url' => admin_url( 'admin.php?page=dpsp-extensions&sub-page=skyepress' )
94
+ );
95
+
96
+ foreach( $tools as $tool_slug => $tool )
97
+ dpsp_output_tool_box( $tool_slug, $tool );
98
+ ?>
99
+ </div><!-- End of Our Plugins -->
100
+ */ ?>
101
+
102
+ </div>
inc/admin/views/view-submenu-page-settings.php ADDED
@@ -0,0 +1,92 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <div class="dpsp-page-wrapper dpsp-page-settings wrap">
2
+
3
+ <h1 class="dpsp-page-title"><?php echo __( 'Settings', 'social-pug' ); ?></h1>
4
+
5
+ <form method="post" action="options.php">
6
+
7
+ <?php
8
+ $dpsp_settings = get_option( 'dpsp_settings', 'not_set' );
9
+ settings_fields( 'dpsp_settings' );
10
+ ?>
11
+
12
+ <!-- General Settings Tab Content -->
13
+ <div id="dpsp-tab-general-settings">
14
+
15
+ <div class="dpsp-card">
16
+
17
+ <div class="dpsp-card-header">
18
+ <?php _e( 'Social Identity', 'social-pug' ); ?>
19
+ </div>
20
+
21
+ <div class="dpsp-card-inner">
22
+
23
+ <?php dpsp_settings_field( 'text', 'dpsp_settings[twitter_username]', ( isset($dpsp_settings['twitter_username']) ? $dpsp_settings['twitter_username'] : '' ), __( 'Twitter Username', 'social-pug' ), '' ); ?>
24
+ <?php dpsp_settings_field( 'switch', 'dpsp_settings[tweets_have_username]', ( isset( $dpsp_settings['tweets_have_username']) ? $dpsp_settings['tweets_have_username'] : '' ), __( 'Add Twitter Username to all tweets', 'social-pug' ), array('yes') ); ?>
25
+
26
+ </div>
27
+
28
+ </div>
29
+
30
+ <!-- Misc -->
31
+ <div id="dpsp-card-misc" class="dpsp-card">
32
+
33
+ <div class="dpsp-card-header">
34
+ <?php _e( 'Misc', 'social-pug' ); ?>
35
+ </div>
36
+
37
+ <div class="dpsp-card-inner">
38
+
39
+ <?php dpsp_settings_field( 'select', 'dpsp_settings[facebook_share_counts_provider]', ( isset($dpsp_settings['facebook_share_counts_provider']) ? $dpsp_settings['facebook_share_counts_provider'] : '' ), __( 'Facebook Share Counts Provider', 'social-pug' ), array( 'authorized_app' => __( 'Grow by Mediavine App', 'social-pug' ), 'own_app' => __( 'Facebook Graph API', 'social-pug' ) ) ); ?>
40
+
41
+ <div class="dpsp-setting-field-wrapper dpsp-setting-field-text dpsp-has-field-label dpsp-setting-field-facebook-authorize-app">
42
+
43
+ <?php $facebook_access_token = get_transient( 'dpsp_facebook_access_token' ); ?>
44
+
45
+ <?php if( ! empty( $facebook_access_token['access_token'] ) && ! empty( $facebook_access_token['expires_in'] ) ): ?>
46
+
47
+ <?php if( time() < $facebook_access_token['expires_in'] ): ?>
48
+
49
+ <div class="dpsp-setting-field-facebook-app-authorized">
50
+ <span class="dashicons dashicons-yes"></span>
51
+ <strong><?php echo __( 'Authorized', 'social-pug' ); ?></strong>
52
+ <?php echo '- ' . sprintf( __( 'Expires on %s', 'social-pug' ), date( 'F d, Y', absint( $facebook_access_token['expires_in'] ) ) ); ?>
53
+ </div>
54
+
55
+ <?php else: ?>
56
+
57
+ <div class="dpsp-setting-field-facebook-app-authorized-expired">
58
+ <span class="dashicons dashicons-warning"></span>
59
+ <strong><?php echo __( 'Authorization Expired', 'social-pug' ); ?></strong>
60
+ <?php echo '- ' . __( 'Please reauthorize.', 'social-pug' ); ?>
61
+ </div>
62
+
63
+ <a class="dpsp-button-primary" href="<?php echo add_query_arg( array( 'action' => 'authorize_facebook_app_free', 'referer' => home_url(), 'tkn' => wp_create_nonce( 'dpsp_authorize_facebook_app' ), 'client_url' => urlencode( add_query_arg( array( 'page' => 'dpsp-settings' ), admin_url( 'admin.php' ) ) ) ), 'http://apitest.devpups.com/1.0/' ); ?>"><?php echo __( 'Reauthorize Grow', 'social-pug' ); ?></a>
64
+
65
+ <?php endif; ?>
66
+
67
+ <?php else: ?>
68
+
69
+ <a class="dpsp-button-primary" href="<?php echo add_query_arg( array( 'action' => 'authorize_facebook_app_free', 'referer' => home_url(), 'tkn' => wp_create_nonce( 'dpsp_authorize_facebook_app' ), 'client_url' => urlencode( add_query_arg( array( 'page' => 'dpsp-settings' ), admin_url( 'admin.php' ) ) ) ), 'http://apitest.devpups.com/1.0/' ); ?>"><?php echo __( 'Authorize Grow', 'social-pug' ); ?></a>
70
+
71
+ <?php endif; ?>
72
+
73
+ </div>
74
+
75
+ <?php dpsp_settings_field( 'text', 'dpsp_settings[facebook_app_id]', ( isset($dpsp_settings['facebook_app_id']) ? $dpsp_settings['facebook_app_id'] : '' ), __( 'Facebook App ID', 'social-pug' ), '' ); ?>
76
+ <?php dpsp_settings_field( 'text', 'dpsp_settings[facebook_app_secret]', ( isset($dpsp_settings['facebook_app_secret']) ? $dpsp_settings['facebook_app_secret'] : '' ), __( 'Facebook App Secret', 'social-pug' ), '' ); ?>
77
+ <?php dpsp_settings_field( 'switch', 'dpsp_settings[disable_meta_tags]', ( isset($dpsp_settings['disable_meta_tags']) ? $dpsp_settings['disable_meta_tags'] : '' ), __( 'Disable Open Graph Meta Tags', 'social-pug' ), array('yes') ); ?>
78
+ <?php dpsp_settings_field( 'switch', 'dpsp_settings[twitter_share_counts]', ( isset($dpsp_settings['twitter_share_counts']) ? $dpsp_settings['twitter_share_counts'] : '' ), __( 'Enable Twitter Tweet Counts', 'social-pug' ), array('yes'), sprintf( __( 'You will need to register your website on %1$sTwitCount%2$s in order for Growto be able to return the share counts.', 'social-pug' ), '<a href="http://twitcount.com/" target="_blank">', '</a>' ) ); ?>
79
+
80
+ </div>
81
+
82
+ </div>
83
+
84
+ </div><!-- End of General Settings Tab Content -->
85
+
86
+ <input type="hidden" name="action" value="update" />
87
+ <input type="hidden" name="dpsp_settings[always_update]" value="<?php echo ( isset( $dpsp_settings['always_update'] ) && $dpsp_settings['always_update'] == 1 ? 0 : 1 ); ?>" />
88
+ <p class="submit"><input type="submit" class="dpsp-button-primary" value="<?php _e( 'Save Changes' ); ?>" /></p>
89
+ </form>
90
+ </div>
91
+
92
+ <?php do_action( 'dpsp_submenu_page_bottom' ); ?>
inc/admin/views/view-submenu-page-sidebar.php ADDED
@@ -0,0 +1,110 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <form method="post" action="options.php">
2
+ <div class="dpsp-page-wrapper dpsp-page-sidebar wrap">
3
+
4
+ <?php
5
+ $dpsp_location_sidebar = get_option( 'dpsp_location_sidebar', 'not_set' );
6
+ settings_fields( 'dpsp_location_sidebar' );
7
+ ?>
8
+
9
+
10
+ <!-- Page Title -->
11
+ <h1 class="dpsp-page-title">
12
+ <?php _e('Configure Sidebar Sharing Buttons', 'social-pug'); ?>
13
+
14
+ <input type="hidden" name="dpsp_buttons_location" value="dpsp_location_sidebar" />
15
+ <input type="hidden" name="dpsp_location_sidebar[active]" value="<?php echo ( isset( $dpsp_location_sidebar["active"] ) ? 1 : '' ); ?>" <?php echo ( !isset( $dpsp_location_sidebar["active"] ) ? 'disabled' : '' ); ?> />
16
+ </h1>
17
+
18
+ <!-- Networks Selectable and Sortable Panels -->
19
+ <div id="dpsp-social-platforms-wrapper" class="dpsp-card">
20
+
21
+ <div class="dpsp-card-header">
22
+ <?php _e( 'Social Networks', 'social-pug' ); ?>
23
+ <a id="dpsp-select-networks" class="dpsp-button-secondary" href="#"><?php echo __( 'Select Networks', 'social-pug' ) ?></a>
24
+ </div>
25
+
26
+ <div id="dpsp-sortable-networks-empty" class="dpsp-card-inner <?php echo ( empty( $dpsp_location_sidebar['networks'] ) ? 'dpsp-active' : '' ); ?>">
27
+ <p><?php _e( 'Select which social buttons to display', 'social-pug' ); ?></p>
28
+ </div>
29
+
30
+ <?php echo dpsp_output_sortable_networks( ( ! empty( $dpsp_location_sidebar['networks'] ) ? $dpsp_location_sidebar['networks'] : array() ), 'dpsp_location_sidebar' ); ?>
31
+
32
+ <?php
33
+ $available_networks = dpsp_get_networks();
34
+ echo dpsp_output_selectable_networks( $available_networks, ( ! empty( $dpsp_location_sidebar['networks'] ) ? $dpsp_location_sidebar['networks'] : array() ) );
35
+ ?>
36
+
37
+ </div>
38
+
39
+ <!-- General Display Settings -->
40
+ <div class="dpsp-card">
41
+
42
+ <div class="dpsp-card-header">
43
+ <?php _e( 'Display Settings', 'social-pug' ); ?>
44
+ </div>
45
+
46
+ <div class="dpsp-card-inner">
47
+
48
+ <?php dpsp_settings_field( 'select', 'dpsp_location_sidebar[display][shape]', $dpsp_location_sidebar['display']['shape'], __( 'Button shape', 'social-pug' ), array( 'rectangular' => __( 'Rectangular', 'social-pug' ), 'rounded' => __( 'Rounded', 'social-pug' ), 'circle' => __( 'Circle', 'social-pug' ) ) ); ?>
49
+
50
+ <?php dpsp_settings_field( 'switch', 'dpsp_location_sidebar[display][icon_animation]', ( isset( $dpsp_location_sidebar['display']['icon_animation']) ? $dpsp_location_sidebar['display']['icon_animation'] : '' ), __( 'Show icon animation', 'social-pug' ), array('yes'), __( 'Will animate the social media icon when the user hovers over the button.', 'social-pug' ) ); ?>
51
+
52
+ <?php dpsp_settings_field( 'select', 'dpsp_location_sidebar[display][position]', $dpsp_location_sidebar['display']['position'], __( 'Buttons position', 'social-pug' ), array( 'left' => __( 'Left', 'social-pug' ), 'right' => __( 'Right', 'social-pug' ) ) ); ?>
53
+
54
+ <?php dpsp_settings_field( 'switch', 'dpsp_location_sidebar[display][show_labels]', ( isset( $dpsp_location_sidebar['display']['show_labels']) ? $dpsp_location_sidebar['display']['show_labels'] : '' ), __( 'Show button labels', 'social-pug' ), array('yes') ); ?>
55
+
56
+ <?php dpsp_settings_field( 'switch', 'dpsp_location_sidebar[display][spacing]', ( isset( $dpsp_location_sidebar['display']['spacing']) ? $dpsp_location_sidebar['display']['spacing'] : '' ), __( 'Button spacing', 'social-pug' ), array('yes'), __( 'Adds bottom spacing for each button.', 'social-pug' ) ); ?>
57
+
58
+ <?php dpsp_settings_field( 'switch', 'dpsp_location_sidebar[display][show_mobile]', ( isset( $dpsp_location_sidebar['display']['show_mobile']) ? $dpsp_location_sidebar['display']['show_mobile'] : '' ), __( 'Show on mobile', 'social-pug' ), array('yes') ); ?>
59
+
60
+ <?php dpsp_settings_field( 'text', 'dpsp_location_sidebar[display][screen_size]', ( isset( $dpsp_location_sidebar['display']['screen_size']) ? $dpsp_location_sidebar['display']['screen_size'] : '' ), __( 'Mobile screen width (pixels)', 'social-pug' ), '', __( 'For screen widths smaller than this value ( in pixels ) the buttons will be displayed on screen if the show on mobile option is checked.', 'social-pug' ) ); ?>
61
+
62
+ </div>
63
+
64
+ </div>
65
+
66
+ <!-- Share Counts -->
67
+ <div class="dpsp-card">
68
+
69
+ <div class="dpsp-card-header">
70
+ <?php _e( 'Buttons Share Counts', 'social-pug' ); ?>
71
+ </div>
72
+
73
+ <div class="dpsp-card-inner">
74
+
75
+ <?php dpsp_settings_field( 'switch', 'dpsp_location_sidebar[display][show_count]', ( isset( $dpsp_location_sidebar['display']['show_count']) ? $dpsp_location_sidebar['display']['show_count'] : '' ), __( 'Show share count', 'social-pug' ), array('yes'), __( 'Display the share count for each social network.', 'social-pug' ) ); ?>
76
+
77
+ <?php dpsp_settings_field( 'switch', 'dpsp_location_sidebar[display][show_count_total]', ( isset( $dpsp_location_sidebar['display']['show_count_total']) ? $dpsp_location_sidebar['display']['show_count_total'] : '' ), __( 'Show total share count', 'social-pug' ), array('yes'), __( 'Display the share count for all social networks.', 'social-pug' ) ); ?>
78
+
79
+ <?php dpsp_settings_field( 'select', 'dpsp_location_sidebar[display][total_count_position]', ( isset( $dpsp_location_sidebar['display']['total_count_position'] ) ? $dpsp_location_sidebar['display']['total_count_position'] : '' ), __( 'Total count position', 'social-pug' ), array( 'before' => __( 'Before Buttons', 'social-pug' ), 'after' => __( 'After Buttons', 'social-pug' ) ) ); ?>
80
+
81
+ <?php dpsp_settings_field( 'switch', 'dpsp_location_sidebar[display][count_round]', ( isset( $dpsp_location_sidebar['display']['count_round']) ? $dpsp_location_sidebar['display']['count_round'] : '' ), __( 'Share count round', 'social-pug' ), array('yes'), __( 'If the share count for each network is bigger than 1000 it will be rounded to one decimal ( eg. 1267 will show as 1.2k ). Applies to Total Share Counts as well.', 'social-pug' ) ); ?>
82
+
83
+ </div>
84
+
85
+ </div>
86
+
87
+ <!-- Post Type Display Settings -->
88
+ <div class="dpsp-card">
89
+
90
+ <div class="dpsp-card-header">
91
+ <?php _e( 'Post Type Display Settings', 'social-pug' ); ?>
92
+ </div>
93
+
94
+ <div class="dpsp-card-inner">
95
+
96
+ <?php dpsp_settings_field( 'checkbox', 'dpsp_location_sidebar[post_type_display][]', ( isset( $dpsp_location_sidebar['post_type_display']) ? $dpsp_location_sidebar['post_type_display'] : array() ), '', dpsp_get_post_types() ); ?>
97
+
98
+ </div>
99
+
100
+ </div>
101
+
102
+ <!-- Save Changes Button -->
103
+ <input type="hidden" name="action" value="update" />
104
+ <p class="submit"><input type="submit" class="dpsp-button-primary" value="<?php _e( 'Save Changes' ); ?>" /></p>
105
+
106
+ </div>
107
+
108
+ </form>
109
+
110
+ <?php do_action( 'dpsp_submenu_page_bottom' ); ?>
inc/admin/views/view-submenu-page-toolkit.php ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <div class="dpsp-page-wrapper dpsp-page-toolkit wrap">
2
+
3
+ <?php wp_nonce_field( 'dpsptkn', 'dpsptkn' ); ?>
4
+
5
+ <!-- Share Tools -->
6
+ <h1 class="dpsp-page-title"><?php echo __( 'Social Share Tools', 'social-pug' ); ?></h1>
7
+
8
+ <div class="dpsp-row dpsp-m-padding">
9
+ <?php
10
+ $tools = dpsp_get_tools('share_tool');
11
+
12
+ foreach( $tools as $tool_slug => $tool )
13
+ dpsp_output_tool_box( $tool_slug, $tool );
14
+ ?>
15
+ </div><!-- End of Share Tools -->
16
+
17
+ </div>
18
+
19
+ <?php do_action( 'dpsp_submenu_page_bottom' ); ?>
inc/functions-admin.php ADDED
@@ -0,0 +1,864 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Displays the HTML of the plugin admin header
5
+ *
6
+ */
7
+ function dpsp_admin_header() {
8
+
9
+ if( empty( $_GET['page'] ) )
10
+ return;
11
+
12
+ if( false === strpos( $_GET['page'], 'dpsp' ) )
13
+ return;
14
+
15
+ $page = trim( $_GET['page'] );
16
+
17
+ echo '<div class="dpsp-page-header">';
18
+ echo '<span class="dpsp-logo">';
19
+ echo '<svg version="1.1" class="mv-grow-logo" xmlns="http://www.w3.org/2000/svg" x="0" y="0" viewBox="0 0 20 20" fill="white" xml:space="preserve">
20
+ <path d="M0 7.2c0 .1-.6 4.7 2 7.2 1.7 1.8 4.3 2 5.9 2h.9A12.7 12.7 0 014.4 14a6.7 6.7 0 01-1.6-2.3c-.3-.9-.5-1.9-.4-3 0-.7.2-1.6.5-2.4h-2l-.7.1-.1.8zM4.7 3.4l-.4.6-.8 1.8 2.4.5 1.3-2c-1-.5-1.7-.7-1.8-.7l-.7-.2z"/>
21
+ <path d="M3.3 11.5c1.1 2.8 4.3 4 5.5 4.4l-.5-.4-.4-.4a10.7 10.7 0 01-2.2-3c-.4-1-.6-1.9-.6-2.8 0-.7.2-1.4.4-2.1l.1-.2.1-.3a10.8 10.8 0 00-2.1-.4h-.3v.4a7.4 7.4 0 000 4.8zM10.6 2.8l-.6-.4-.6.4L8 4.2l2 1.3c.6-.5 1.3-1 2-1.3l-1.4-1.4zM6.5 6.6h.2l1.6 1.1a6.4 6.4 0 011.4-1.9L8 4.8l-.2-.2-.2-.1-.2.2-.1.2c-.4.4-.8 1-1 1.6h.1z"/>
22
+ <path d="M6 7.1v.2a6 6 0 00-.4 2c0 3 2.4 5.4 3.4 6.2l-.3-.5-.2-.6a12.5 12.5 0 01-.8-3.4A7 7 0 018 8.4l.1-.3a6 6 0 00-1.6-1L6.3 7h-.2V7zM15.3 3.5l-.7.1s-.8.2-1.8.7c.5.7 1 1.3 1.3 2l.5-.1a11 11 0 011.9-.4l-.8-1.7-.4-.6zM13.4 6.6l.3-.1-1-1.6-.2-.2-.2-.2-.2.1-.2.1-1.6 1.1.2.2.1.2c.5.4.8 1 1 1.5a6.6 6.6 0 011.8-1.1zM10.3 6.5l-.2-.2-.1-.1-.2.1-.1.2a5.8 5.8 0 00-1 1.6v.1h.1l.2.2c.4.5.7 1.1 1 1.8a7 7 0 011-1.8l.1-.2.2-.2c-.2-.6-.6-1-1-1.5z"/>
23
+ <path d="M8.7 8.9v-.2h-.1l-.2-.2V9h-.1c-.6 2.5.5 5 1 6.1v-.6-.6-1.1l.2-1 .1-.5.1-.4a6.9 6.9 0 00-1-2zM17 6.3h-.4c-.7 0-1.5.2-2.3.4l-.2.1-.3.1h-.2l-.2.2A6 6 0 0012 8l-.2.2-.2.2-.2.2-.1.2c-.5.6-.8 1.3-1 2l-.1.4-.1.3v.2l-.1.5v.2a12 12 0 000 3V16.4h.5l.2.1H12c1.6 0 4.2-.2 6-2 2.5-2.5 1.8-7 1.8-7.3v-.7H19a10.2 10.2 0 00-2-.1zm-.4 6.8c-1.3 1.2-3.3 1.4-4.6 1.4h-.3c0-1.3.1-3.6 1.4-4.9 1.2-1.2 3.3-1.4 4.5-1.4h.4c0 1.2 0 3.5-1.4 4.9z"/>
24
+ </svg>
25
+ ';
26
+ echo '<span class="dpsp-logo-inner">Grow by Mediavine</span>';
27
+ echo '<small class="dpsp-version">v.' . DPSP_VERSION . '</small>';
28
+ echo '</span>';
29
+
30
+ echo '<nav>';
31
+ echo '<a href="' . dpsp_get_documentation_link( $page ) . '" target="_blank"><i class="dashicons dashicons-book"></i>Documentation</a>';
32
+ //echo '<a href="https://wordpress.org/support/view/plugin-reviews/social-pug?filter=5#postform" target="_blank">5<i class="dashicons dashicons-star-filled"></i>Leave a Review</a>';
33
+ echo '</nav>';
34
+
35
+ echo '</div>';
36
+
37
+ }
38
+ add_action( 'admin_notices', 'dpsp_admin_header', 1 );
39
+
40
+
41
+ /*
42
+ * Returns the link to the docs depending on the page the user is on
43
+ *
44
+ */
45
+ function dpsp_get_documentation_link( $page ) {
46
+
47
+ $page = str_replace( 'dpsp-', '', $page );
48
+
49
+ switch( $page ) {
50
+
51
+ case 'sidebar':
52
+ $url = 'https://docs.devpups.com/social-pug/floating-sidebar-settings/';
53
+ break;
54
+
55
+ case 'content':
56
+ $url = 'https://docs.devpups.com/social-pug/before-and-after-content-settings/';
57
+ break;
58
+
59
+ default:
60
+ $url = 'https://docs.devpups.com/social-pug/';
61
+ break;
62
+ }
63
+
64
+ return $url;
65
+
66
+ }
67
+
68
+
69
+ /*
70
+ * Displays the HTML for a given tool
71
+ *
72
+ * @param array $tool
73
+ *
74
+ */
75
+ function dpsp_output_tool_box( $tool_slug, $tool ) {
76
+
77
+ echo '<div class="' . ( ! empty( $tool['admin_page'] ) ? 'dpsp-col-3-8' : 'dpsp-col-1-4' ) . '">';
78
+
79
+ echo '<div class="dpsp-tool-wrapper dpsp-card ' . ( empty($tool['admin_page']) ? 'dpsp-unavailable' : '' ) . '">';
80
+
81
+ // Tool image
82
+ if( !isset( $tool['admin_page'] ) ) {
83
+ if( empty( $tool['url'] ) )
84
+ $tool['url'] = 'http://www.devpups.com/';
85
+
86
+ echo '<a href="' . $tool['url'] . '">';
87
+ }
88
+
89
+ echo '<img src="' . DPSP_PLUGIN_DIR_URL . $tool['img'] . '" />';
90
+
91
+ if( !isset( $tool['admin_page'] ) )
92
+ echo '</a>';
93
+
94
+ // Tool name
95
+ echo '<h4 class="dpsp-tool-name">' . $tool['name'] . '</h4>';
96
+
97
+ if( !empty( $tool['desc'] ) )
98
+ echo '<p class="dpsp-description">' . $tool['desc'] . '</p>';
99
+
100
+ $tool_active = dpsp_is_tool_active( $tool_slug );
101
+
102
+ // Tool actions
103
+ echo '<div class="dpsp-tool-actions dpsp-card-footer dpsp-' . ( $tool_active ? 'active' : 'inactive' ) . '">';
104
+
105
+ if( isset( $tool['admin_page'] ) ) {
106
+
107
+ // Tool admin page
108
+ echo '<a class="dpsp-tool-settings" href="' . admin_url( $tool['admin_page'] ) . '"><i class="dashicons dashicons-admin-generic"></i>' . __( 'Settings', 'social-pug' ) . '</a>';
109
+
110
+ // Tool activation switch
111
+ echo '<div class="dpsp-switch small">';
112
+
113
+ echo ( $tool_active ? '<span>' . __( 'Active', 'social-pug' ) . '</span>' : '<span>' . __( 'Inactive', 'social-pug' ) . '</span>' );
114
+
115
+ echo '<input id="dpsp-' . $tool_slug . '-active" data-tool="' . $tool_slug . '" data-tool-activation="' . $tool['activation_setting'] . '" class="cmn-toggle cmn-toggle-round" type="checkbox" value="1"' . ( $tool_active ? 'checked' : '' ) . ' />';
116
+ echo '<label for="dpsp-' . $tool_slug . '-active"></label>';
117
+
118
+ echo '</div>';
119
+
120
+ } else {
121
+
122
+ if( empty( $tool['url'] ) )
123
+ $tool['url'] = 'http://www.devpups.com/';
124
+
125
+ echo '<a href="' . $tool['url'] . '" class="dpsp-button-primary">' . __( 'Learn More', 'social-pug' ) . '</a>';
126
+
127
+ }
128
+
129
+ echo '</div>';
130
+
131
+ echo '</div>';
132
+ echo '</div>';
133
+
134
+ }
135
+
136
+
137
+ /**
138
+ * Function that displays the HTML for a settings field
139
+ *
140
+ */
141
+ function dpsp_settings_field( $type, $name, $saved_value = '', $label = '', $options = array(), $tooltip = '', $editor_settings = array() ) {
142
+
143
+ $settings_field_slug = ( !empty($label) ? strtolower(str_replace(' ', '-', $label)) : '' );
144
+
145
+ echo '<div class="dpsp-setting-field-wrapper dpsp-setting-field-' . $type . ( is_array( $options ) && count( $options ) == 1 ? ' dpsp-single' : ( is_array( $options ) && count( $options ) > 1 ? ' dpsp-multiple' : '' ) ) . ' ' . ( !empty($label) ? 'dpsp-has-field-label dpsp-setting-field-' . $settings_field_slug : '' ) . '">';
146
+
147
+ switch( $type ) {
148
+
149
+ // Display input type text
150
+ case 'text':
151
+
152
+ echo !empty( $label ) ? '<label for="' . esc_attr( $name ) . '" class="dpsp-setting-field-label">' . $label . '</label>' : '';
153
+
154
+ echo '<input type="text" ' . ( isset( $label ) ? 'id="' . esc_attr( $name ) . '"' : '' ) . ' name="' . esc_attr( $name ) . '" value="' . esc_attr( $saved_value ) . '" />';
155
+ break;
156
+
157
+ // Display textareas
158
+ case 'textarea':
159
+ echo !empty( $label ) ? '<label for="' . esc_attr( $name ) . '" class="dpsp-setting-field-label">' . $label . '</label>' : '';
160
+
161
+ echo '<textarea ' . ( isset( $label ) ? 'id="' . esc_attr( $name ) . '"' : '' ) . ' name="' . esc_attr( $name ) . '">' . $saved_value . '</textarea>';
162
+
163
+ break;
164
+
165
+ // Display wp_editors
166
+ case 'editor':
167
+ echo !empty( $label ) ? '<label for="' . esc_attr( $name ) . '" class="dpsp-setting-field-label">' . $label . '</label>' : '';
168
+
169
+ wp_editor( $saved_value, $name, $editor_settings );
170
+
171
+ break;
172
+
173
+ // Display input type radio
174
+ case 'radio':
175
+
176
+ echo !empty( $label ) ? '<label class="dpsp-setting-field-label">' . $label . '</label>' : '';
177
+
178
+ if( !empty( $options ) ) {
179
+ foreach( $options as $option_value => $option_name ) {
180
+ echo '<input type="radio" id="' . esc_attr( $name ) . '[' . esc_attr( $option_value ) . ']' . '" name="' . esc_attr( $name ) . '" value="' . esc_attr( $option_value ) . '" ' . checked( $option_value, $saved_value, false ) . ' />';
181
+ echo '<label for="' . esc_attr( $name ) . '[' . esc_attr( $option_value ) . ']' . '" class="dpsp-settings-field-radio">' . ( isset( $option_name ) ? $option_name : $option_value ) . '<span></span></label>';
182
+ }
183
+ }
184
+ break;
185
+
186
+ // Display input type checkbox
187
+ case 'checkbox':
188
+
189
+ // If no options are passed make the main label as the label for the checkbox
190
+ if( count( $options ) == 1 ) {
191
+
192
+ if( is_array( $saved_value ) )
193
+ $saved_value = $saved_value[0];
194
+
195
+ echo '<input type="checkbox" ' . ( isset( $label ) ? 'id="' . esc_attr( $name ) . '"' : '' ) . ' name="' . esc_attr( $name ) . '" value="' . esc_attr( $options[0] ) . '" ' . checked( $options[0], $saved_value, false ) . ' />';
196
+ echo !empty( $label ) ? '<label for="' . esc_attr( $name ) . '" class="dpsp-setting-field-label">' . $label . '<span></span></label>' : '';
197
+
198
+ // Else display checkboxes just like radios
199
+ } else {
200
+
201
+ echo !empty( $label ) ? '<label class="dpsp-setting-field-label">' . $label . '</label>' : '';
202
+
203
+ if( !empty( $options ) ) {
204
+ foreach( $options as $option_value => $option_name ) {
205
+ echo '<input type="checkbox" id="' . esc_attr( $name ) . '[' . esc_attr( $option_value ) . ']' . '" name="' . esc_attr( $name ) . '" value="' . esc_attr( $option_value ) . '" ' . ( in_array( $option_value, $saved_value ) ? 'checked' : '' ) . ' />';
206
+ echo '<label for="' . esc_attr( $name ) . '[' . esc_attr( $option_value ) . ']' . '" class="dpsp-settings-field-checkbox">' . ( isset( $option_name ) ? $option_name : $option_value ) . '<span></span></label>';
207
+ }
208
+ }
209
+
210
+ }
211
+ break;
212
+
213
+ // Display switch
214
+ case 'switch':
215
+
216
+ if( count( $options ) == 1 ) {
217
+
218
+ if( is_array( $saved_value ) )
219
+ $saved_value = $saved_value[0];
220
+
221
+ echo '<div class="dpsp-switch">';
222
+ echo '<input type="checkbox" ' . ( isset( $label ) ? 'id="' . esc_attr( $name ) . '"' : '' ) . ' name="' . esc_attr( $name ) . '" class="cmn-toggle cmn-toggle-round" value="' . esc_attr( $options[0] ) . '" ' . checked( $options[0], $saved_value, false ) . ' />';
223
+ echo ! empty( $label ) ? '<label for="' . esc_attr( $name ) . '"></label>' : '';
224
+ echo '</div>';
225
+
226
+ echo ! empty( $label ) ? '<label for="' . esc_attr( $name ) . '" class="dpsp-setting-field-label">' . $label . '<span></span></label>' : '';
227
+
228
+ }
229
+
230
+ /*
231
+ $echo .= '<div class="oih-switch small">';
232
+
233
+ $echo .= '<input id="' . esc_attr( $field['name'] ) . '" name="' . esc_attr( $field['name'] ) . '" class="oih-toggle oih-toggle-round ' . ( ! empty( $field['input_class'] ) ? esc_attr( $field['input_class'] ) : '' ) . '" type="checkbox" value="1" ' . ( ! empty( $value ) ? 'checked' : '' ) . ' />';
234
+ $echo .= '<label for="' . esc_attr( $field['name'] ) . '"></label>';
235
+
236
+ $echo .= '</div>';
237
+ */
238
+
239
+ break;
240
+
241
+ case 'select':
242
+
243
+ echo !empty( $label ) ? '<label for="' . esc_attr( $name ) . '" class="dpsp-setting-field-label">' . $label . '</label>' : '';
244
+ echo '<select id="' . esc_attr( $name ) . '" name="' . esc_attr( $name ) . '">';
245
+
246
+ foreach( $options as $option_value => $option_name ) {
247
+ echo '<option value="' . esc_attr( $option_value ) . '" ' . selected( $saved_value, $option_value, false ) . '>' . $option_name . '</option>';
248
+ }
249
+
250
+ echo '</select>';
251
+
252
+ break;
253
+
254
+ case 'color-picker':
255
+ echo !empty( $label ) ? '<label for="' . esc_attr( $name ) . '" class="dpsp-setting-field-label">' . $label . '</label>' : '';
256
+
257
+ echo '<input class="dpsp-color-picker" type="text" ' . ( isset( $label ) ? 'id="' . esc_attr( $name ) . '"' : '' ) . ' name="' . esc_attr( $name ) . '" value="' . esc_attr( $saved_value ) . '" />';
258
+ break;
259
+
260
+ case 'image':
261
+ echo !empty( $label ) ? '<label for="' . esc_attr( $name ) . '" class="dpsp-setting-field-label">' . $label . '</label>' : '';
262
+
263
+ echo '<div>';
264
+
265
+ if( !empty( $saved_value['id'] ) ) {
266
+ $thumb_details = wp_get_attachment_image_src( $saved_value['id'], 'medium' );
267
+ $image_details = wp_get_attachment_image_src( $saved_value['id'], 'full' );
268
+ }
269
+
270
+ if( !empty( $thumb_details[0] ) && !empty( $image_details[0] ) ) {
271
+ $thumb_src = $thumb_details[0];
272
+ $image_src = $image_details[0];
273
+ } else {
274
+ $thumb_src = '';
275
+ $image_src = '';
276
+ $saved_value['id'] = '';
277
+ }
278
+
279
+ echo '<div>';
280
+ echo '<img src="' . esc_attr( $thumb_src ) . '">';
281
+ echo '</div>';
282
+
283
+ echo '<a class="dpsp-image-select button button-primary ' . ( !empty( $saved_value['id'] ) ? 'hidden' : '' ) . '" href="#">' . __( 'Select Image', 'social-pug' ) . '</a>';
284
+ echo '<a class="dpsp-image-remove button button-secondary ' . ( empty( $saved_value['id'] ) ? 'hidden' : '' ) . '" href="#">' . __( 'Remove Image', 'social-pug' ) . '</a>';
285
+
286
+ echo '<input class="dpsp-image-id" type="hidden" name="' . esc_attr( $name ) . '[id]" value="' . esc_attr( $saved_value['id'] ) . '" />';
287
+ echo '<input class="dpsp-image-src" type="hidden" name="' . esc_attr( $name ) . '[src]" value="' . esc_attr( $image_src ) . '" />';
288
+
289
+ echo '</div>';
290
+
291
+ break;
292
+
293
+ } // end of switch
294
+
295
+
296
+ // Tooltip
297
+ if( ! empty( $tooltip ) ) {
298
+
299
+ dpsp_output_backend_tooltip( $tooltip );
300
+
301
+ }
302
+
303
+ do_action( 'dpsp_inner_after_settings_field', $settings_field_slug, $type, $name );
304
+
305
+ echo '</div>';
306
+
307
+ }
308
+
309
+
310
+ /*
311
+ * Activates a network location
312
+ *
313
+ */
314
+ function dpsp_activate_tool() {
315
+
316
+ if( empty( $_POST['dpsptkn'] ) || !wp_verify_nonce( $_POST['dpsptkn'], 'dpsptkn' ) )
317
+ return 0;
318
+
319
+ $tool_setting = sanitize_text_field( $_POST['setting'] );
320
+
321
+ $option_name = explode( '[', $tool_setting );
322
+ $option_name = $option_name[0];
323
+
324
+ $settings = get_option( $option_name );
325
+ $active_option = str_replace( array( $option_name, '[', ']' ) , '', $tool_setting );
326
+
327
+ if( !isset( $settings[$active_option] ) ) {
328
+
329
+ $settings[$active_option] = 1;
330
+ update_option( $option_name, $settings );
331
+
332
+ echo 1;
333
+ } else
334
+ echo 0;
335
+
336
+
337
+ wp_die();
338
+
339
+ }
340
+ add_action( 'wp_ajax_dpsp_activate_tool', 'dpsp_activate_tool' );
341
+
342
+
343
+ /*
344
+ * Deactivates a network location
345
+ *
346
+ */
347
+ function dpsp_deactivate_tool() {
348
+
349
+ if( empty( $_POST['dpsptkn'] ) || !wp_verify_nonce( $_POST['dpsptkn'], 'dpsptkn' ) )
350
+ return 0;
351
+
352
+ $tool_setting = sanitize_text_field( $_POST['setting'] );
353
+
354
+ $option_name = explode( '[', $tool_setting );
355
+ $option_name = $option_name[0];
356
+
357
+ $settings = get_option( $option_name );
358
+ $active_option = str_replace( array( $option_name, '[', ']' ) , '', $tool_setting );
359
+
360
+ if( isset( $settings[$active_option] ) ) {
361
+
362
+ unset($settings[$active_option]);
363
+ update_option( $option_name, $settings );
364
+
365
+ echo 1;
366
+ } else
367
+ echo 0;
368
+
369
+
370
+ wp_die();
371
+
372
+ }
373
+ add_action( 'wp_ajax_dpsp_deactivate_tool', 'dpsp_deactivate_tool' );
374
+
375
+
376
+ /**
377
+ * Returns the HTML output with the selectable networks
378
+ *
379
+ * @param array $networks - the networks available to be sorted
380
+ * @param array $settings_networks - the networks saved for the location
381
+ *
382
+ */
383
+ function dpsp_output_selectable_networks( $networks = array(), $settings_networks ) {
384
+
385
+ $output = '<div id="dpsp-networks-selector-wrapper">';
386
+
387
+ $output .= '<ul id="dpsp-networks-selector">';
388
+
389
+ if( !empty($networks) ) {
390
+ foreach( $networks as $network_slug => $network_name ) {
391
+ $output .= '<li>';
392
+ $output .= '<div class="dpsp-network-item" data-network="' . $network_slug . '" data-network-name="' . $network_name . '" ' . ( isset( $settings_networks[$network_slug] ) ? 'data-checked="true"' : '' ) . '>';
393
+ $output .= '<div class="dpsp-network-item-checkbox dpsp-icon-ok"></div>';
394
+ $output .= '<div class="dpsp-network-item-name-wrapper dpsp-network-' . $network_slug . ' dpsp-background-color-network-' . $network_slug . '">';
395
+ $output .= '<span class="dpsp-list-icon dpsp-list-icon-social dpsp-icon-' . $network_slug . ' dpsp-background-color-network-' . $network_slug . '"><!-- --></span>';
396
+ $output .= '<h4>' . $network_name . '</h4>';
397
+ $output .= '</div>';
398
+ $output .= '</li>';
399
+ }
400
+ }
401
+
402
+ $output .= '</ul>';
403
+
404
+ $output .= '<div id="dpsp-networks-selector-footer" class="dpsp-card-footer">';
405
+ $output .= '<a href="#" class="dpsp-button-primary">' . __( 'Apply Selection', 'social-pug' ) . '</a>';
406
+ $output .= '</div>';
407
+
408
+ $output .= '</div>';
409
+
410
+ return $output;
411
+ }
412
+
413
+
414
+ /*
415
+ * Returns the HTML output with the sortable networks
416
+ *
417
+ */
418
+ function dpsp_output_sortable_networks( $networks, $settings_name ) {
419
+
420
+ $output = '<ul class="dpsp-social-platforms-sort-list sortable">';
421
+
422
+ $current_network = 1;
423
+
424
+ if( ! empty( $networks ) ) {
425
+
426
+ foreach( $networks as $network_slug => $network ) {
427
+
428
+ $output .= '<li data-network="' . $network_slug . '" ' . ( $current_network == count( $networks ) ? 'class="dpsp-last"' : '' ) . '>';
429
+
430
+ // The sort handle
431
+ $output .= '<div class="dpsp-sort-handle"><!-- --></div>';
432
+
433
+ // The social network icon
434
+ $output .= '<div class="dpsp-list-icon dpsp-list-icon-social dpsp-icon-' . $network_slug . ' dpsp-background-color-network-' . $network_slug . '"><!-- --></div>';
435
+
436
+ // The label edit field
437
+ $output .= '<div class="dpsp-list-input-wrapper">';
438
+ $output .= '<input type="text" placeholder="' . __( 'This button has no label text.', 'social-pug' ) . '" name="' . $settings_name . '[networks][' . $network_slug . '][label]" value="' . ( isset( $network['label'] ) ? esc_attr( $network['label'] ) : dpsp_get_network_name( $network_slug ) ) . '" />';
439
+ $output .= '</div>';
440
+
441
+ // List item actions
442
+ $output .= '<div class="dpsp-list-actions">';
443
+ $output .= '<a class="dpsp-list-edit-label" href="#"><span class="dashicons dashicons-edit"></span>' . __( 'Edit Label' ) . '</a>';
444
+ $output .= '<a class="dpsp-list-remove" href="#"><span class="dashicons dashicons-no-alt"></span>' . __( 'Remove' ) . '</a>';
445
+ $output .= '</div>';
446
+ $output .= '</li>';
447
+
448
+ $current_network++;
449
+
450
+ }
451
+
452
+ }
453
+
454
+ $output .= '</ul>';
455
+
456
+ return $output;
457
+ }
458
+
459
+
460
+ /*
461
+ * Outputs the HTML of the tooltip
462
+ *
463
+ * @param string tooltip - the text of the tooltip
464
+ * @param bool $return - wether to return or to output the HTML
465
+ *
466
+ */
467
+ function dpsp_output_backend_tooltip( $tooltip = '', $return = false ) {
468
+
469
+ $output = '<div class="dpsp-setting-field-tooltip-wrapper ' . ( ( strpos( $tooltip, '</a>' ) !== false ) ? 'dpsp-has-link' : '' ) . '">';
470
+ $output .= '<span class="dpsp-setting-field-tooltip-icon"></span>';
471
+ $output .= '<div class="dpsp-setting-field-tooltip dpsp-transition">' . $tooltip . '</div>';
472
+ $output .= '</div>';
473
+
474
+ if( $return )
475
+ return $output;
476
+ else
477
+ echo $output;
478
+
479
+ }
480
+
481
+
482
+ /*
483
+ * Display admin notices for our pages
484
+ *
485
+ */
486
+ function dpsp_admin_notices() {
487
+
488
+ // Exit if settings updated is not present
489
+ if( !isset( $_GET['settings-updated'] ) )
490
+ return;
491
+
492
+ $admin_page = ( isset( $_GET['page'] ) ? $_GET['page'] : '' );
493
+
494
+ // Show these notices only on dpsp pages
495
+ if( strpos( $admin_page, 'dpsp' ) === false || $admin_page == 'dpsp-register-version' )
496
+ return;
497
+
498
+ // Get messages
499
+ $message_id = ( isset( $_GET['dpsp_message_id'] ) ? $_GET['dpsp_message_id'] : 0 );
500
+ $message = dpsp_get_admin_notice_message( $message_id );
501
+
502
+ $class = ( isset( $_GET['dpsp_message_class'] ) ? $_GET['dpsp_message_class'] : 'updated' );;
503
+
504
+ if( isset( $message ) ) {
505
+
506
+ echo '<div class="dpsp-admin-notice notice is-dismissible ' . esc_attr( $class ) . '">';
507
+ echo '<p>' . esc_attr( $message ) . '</p>';
508
+ echo '</div>';
509
+ }
510
+
511
+ }
512
+ add_action( 'admin_notices', 'dpsp_admin_notices' );
513
+
514
+
515
+ /**
516
+ * Returns a human readable message given a message id
517
+ *
518
+ * @param int $message_id
519
+ *
520
+ */
521
+ function dpsp_get_admin_notice_message( $message_id ) {
522
+
523
+ $messages = apply_filters( 'dpsp_get_admin_notice_message', array(
524
+ __( 'Settings saved. If you have any form of caching, please delete the cache in order for the changes to take effect immediately.', 'social-pug' ),
525
+ __( 'Settings imported.', 'social-pug' ),
526
+ __( 'Please select an import file.', 'social-pug' ),
527
+ __( 'Import file is not valid.', 'social-pug' ),
528
+ __( 'Grow App authorized successfully.', 'social-pug' )
529
+ ));
530
+
531
+ return $messages[ $message_id ];
532
+ }
533
+
534
+
535
+ /**
536
+ * Remove dpsp query args from the URL
537
+ *
538
+ * @param array $removable_query_args - the args that WP will remove
539
+ *
540
+ */
541
+ function dpsp_removable_query_args( $removable_query_args ) {
542
+
543
+ $new_args = array( 'dpsp_message_id', 'dpsp_message_class' );
544
+
545
+ return array_merge( $new_args, $removable_query_args );
546
+
547
+ }
548
+ add_filter( 'removable_query_args', 'dpsp_removable_query_args' );
549
+
550
+
551
+ /**
552
+ * Adds a sidebar to the submenu pages for subscribing to newsletter
553
+ *
554
+ */
555
+ function dpsp_add_submenu_page_sidebar() {
556
+
557
+ // The Settings Sidebar
558
+ echo '<div class="dpsp-settings-sidebar">';
559
+
560
+ echo '<div id="dpsp-settings-sidebar-social-pug-pro" class="dpsp-card">';
561
+
562
+ echo '<div class="dpsp-card-inner">';
563
+
564
+ echo '<img data-pin-nopin="true" src="' . DPSP_PLUGIN_DIR_URL . 'assets/src/img/social-pug-upgrade.png" />';
565
+
566
+ echo '<h3>' . __( 'Skyrocket your social media marketing', 'social-pug' ) . '</h3>';
567
+
568
+ echo '<p><span class="dpsp-dashicons"><span class="dashicons dashicons-yes"></span></span>' . __( 'Force a custom image to be shared on Pinterest when using the Pinterest button.', 'social-pug' ) . '</p>';
569
+
570
+ echo '<p><span class="dpsp-dashicons"><span class="dashicons dashicons-yes"></span></span>' . __( 'Add unlimited hidden Pinterest images to your posts and pages.', 'social-pug' ) . '</p>';
571
+
572
+ echo '<p><span class="dpsp-dashicons"><span class="dashicons dashicons-yes"></span></span>' . __( 'Add a "Pin It" button that appears when visitors hover your in-post images.', 'social-pug' ) . '</p>';
573
+
574
+ echo '<p><span class="dpsp-dashicons"><span class="dashicons dashicons-yes"></span></span>' . __( 'Add custom pin descriptions and repin IDs to your in-post images.', 'social-pug' ) . '</p>';
575
+
576
+ echo '<p><span class="dpsp-dashicons"><span class="dashicons dashicons-yes"></span></span>' . __( "Recover your lost social share counts if you've ever changed your permalink structure.", 'social-pug' ) . '</p>';
577
+
578
+ echo '<p><span class="dpsp-dashicons"><span class="dashicons dashicons-yes"></span></span>' . __( 'Add unlimited "Click to Tweet" boxes so that your users can share your content on Twitter with just one click.', 'social-pug' ) . '</p>';
579
+
580
+ echo '<p><span class="dpsp-dashicons"><span class="dashicons dashicons-yes"></span></span>' . __( 'Get immediate help with priority support.', 'social-pug' ) . '</p>';
581
+
582
+ echo '<p><span class="dpsp-dashicons"><span class="dashicons dashicons-yes"></span></span>' . __( 'And much, much more...', 'social-pug' ) . '</p>';
583
+
584
+ echo '</div>';
585
+
586
+ echo '<div class="dpsp-card-footer"><a class="dpsp-button-primary" href="https://devpups.com/social-pug/?utm_source=plugin&amp;utm_medium=sidebar&amp;utm_campaign=social-pug" target="_blank">' . __( 'Upgrade to Pro', 'social-pug' ) . '</a></div>';
587
+
588
+ echo '</div>';
589
+
590
+ /*
591
+
592
+ echo '<br /><hr />';
593
+
594
+ ?>
595
+ <!-- Begin MailChimp Signup Form -->
596
+ <div id="dpsp-mailchimp-subscribe-wrapper">
597
+ <form action="//devpups.us10.list-manage.com/subscribe/post?u=391911b7881ba9ca27be83107&amp;id=e8045e44a7" method="post" id="mc-embedded-subscribe-form" name="mc-embedded-subscribe-form" class="validate" target="_blank" novalidate>
598
+
599
+ <h3><?php echo __( 'Drive More Traffic', 'social-pug' ); ?></h3>
600
+ <p><?php echo __( "Learn how to drive more traffic to your website with our free monthly tips and tricks.", 'social-pug' ); ?></p>
601
+
602
+ <div class="mc-field-group">
603
+ <label for="mce-EMAIL"><?php echo __( 'Email Address', 'social-pug' ); ?> *</label>
604
+ <input type="email" value="" name="EMAIL" class="required email" required id="mce-EMAIL">
605
+ </div>
606
+ <div class="mc-field-group">
607
+ <label for="mce-FNAME"><?php echo __( 'First Name', 'social-pug' ); ?> *</label>
608
+ <input type="text" value="" name="FNAME" class="required" required id="mce-FNAME">
609
+ </div>
610
+
611
+ <div id="mce-responses" class="clear">
612
+ <div class="response" id="mce-error-response" style="display:none"></div>
613
+ <div class="response" id="mce-success-response" style="display:none"></div>
614
+ </div> <!-- real people should not fill this in and expect good things - do not remove this or risk form bot signups-->
615
+
616
+ <div style="position: absolute; left: -5000px;" aria-hidden="true"><input type="text" name="b_391911b7881ba9ca27be83107_e8045e44a7" tabindex="-1" value=""></div>
617
+ <div class="clear"><input type="submit" value="<?php echo __( 'Stay Informed', 'social-pug' ); ?>" name="subscribe" id="mc-embedded-subscribe" class="button"></div>
618
+
619
+ </form>
620
+ </div>
621
+ <!--End mc_embed_signup-->
622
+
623
+ <?php
624
+ */
625
+
626
+
627
+ }
628
+ add_action( 'dpsp_submenu_page_bottom', 'dpsp_add_submenu_page_sidebar' );
629
+
630
+
631
+ /*
632
+ * Add admin notice on plugin activation
633
+ *
634
+ */
635
+ function dpsp_admin_notice_first_activation() {
636
+
637
+ // Get first activation of the plugin
638
+ $first_activation = get_option( 'dpsp_first_activation', '' );
639
+
640
+ if( empty($first_activation) )
641
+ return;
642
+
643
+ // Do not display this notice if user cannot activate plugins
644
+ if( !current_user_can( 'activate_plugins' ) )
645
+ return;
646
+
647
+ // Do not display this notice if plugin has been activated for more than 1 minute
648
+ if( time() - 3 * MINUTE_IN_SECONDS >= $first_activation )
649
+ return;
650
+
651
+ // Do not display this notice for users that have dismissed it
652
+ if( get_user_meta( get_current_user_id(), 'dpsp_admin_notice_first_activation', true ) != '' )
653
+ return;
654
+
655
+ // Echo the admin notice
656
+ echo '<div class="dpsp-admin-notice dpsp-admin-notice-activation notice">';
657
+
658
+ echo '<h4>' . __( 'Thank you for installing Grow by Mediavine. Let\'s start pumping up those social shares.', 'social-pug' ) . '</h4>';
659
+
660
+ echo '<a class="dpsp-admin-notice-link" href="' . add_query_arg( array( 'dpsp_admin_notice_activation' => 1 ), admin_url('admin.php?page=dpsp-toolkit') ) . '"><span class="dashicons dashicons-admin-settings"></span>' . __( 'Go to the Plugin', 'social-pug' ) . '</a>';
661
+ echo '<a class="dpsp-admin-notice-link" href="http://docs.devpups.com/?utm_source=plugin&utm_medium=plugin-activation&utm_campaign=social-pug" target="_blank"><span class="dashicons dashicons-book"></span>' . __( 'View Documentation', 'social-pug' ) . '</a>';
662
+ echo '<a class="dpsp-admin-notice-link" href="https://marketplace.mediavine.com/grow-social-pro/?utm_source=plugin&utm_medium=plugin-activation&utm_campaign=social-pug" target="_blank"><span class="dashicons dashicons-external"></span>' . __( 'Upgrade to Pro', 'social-pug' ) . '</a>';
663
+
664
+ echo '<a href="' . add_query_arg( array( 'dpsp_admin_notice_activation' => 1 ) ) . '" type="button" class="notice-dismiss"><span class="screen-reader-text">Dismiss this notice.</span></a>';
665
+
666
+ echo '</div>';
667
+
668
+ }
669
+ add_action( 'admin_notices', 'dpsp_admin_notice_first_activation' );
670
+
671
+
672
+
673
+ /**
674
+ * Add admin notice to let you know the Facebook access token has expired
675
+ *
676
+ */
677
+ function dpsp_admin_notice_facebook_access_token_expired() {
678
+
679
+ // Do not display this notice if user cannot activate plugins
680
+ if( ! current_user_can( 'activate_plugins' ) )
681
+ return;
682
+
683
+ $transient = get_transient( 'dpsp_facebook_access_token' );
684
+
685
+ // Do not display the notice of the access token is missing
686
+ if( empty( $transient['access_token'] ) || empty( $transient['expires_in'] ) )
687
+ return;
688
+
689
+ // Do not display the notice if the token isn't expired
690
+ if( time() < absint( $transient['expires_in'] ) )
691
+ return;
692
+
693
+ $settings = get_option( 'dpsp_settings', array() );
694
+
695
+ // Do not display the notice if the Facebook share count provider isn't set to Grow by Mediavine's app
696
+ if( ! empty( $settings['facebook_share_counts_provider'] ) && $settings['facebook_share_counts_provider'] != 'authorized_app' )
697
+ return;
698
+
699
+ // Echo the admin notice
700
+ echo '<div class="dpsp-admin-notice notice notice-error">';
701
+
702
+ echo '<h4>' . __( 'Grow Important Notification', 'social-pug' ) . '</h4>';
703
+
704
+ echo '<p>' . __( 'Your Grow by Mediavine Facebook app authorization has expired. Please reauthorize the app for continued Facebook share counts functionality.', 'social-pug' ) . '</p>';
705
+
706
+ echo '<p><a class="dpsp-button-primary" href="' . add_query_arg( array( 'page' => 'dpsp-settings' ), admin_url( 'admin.php' ) ) . '#dpsp-card-misc">' . __( 'Reauthorize Grow App', 'social-pug' ) . '</a></p>';
707
+
708
+ echo '</div>';
709
+
710
+ }
711
+ add_action( 'admin_notices', 'dpsp_admin_notice_facebook_access_token_expired' );
712
+
713
+
714
+ /**
715
+ * Add admin notice to anounce the removal of Google+
716
+ *
717
+ */
718
+ function dpsp_admin_notice_google_plus_removal() {
719
+
720
+ // Do not display this notice if user cannot activate plugins
721
+ if( ! current_user_can( 'activate_plugins' ) )
722
+ return;
723
+
724
+ // Don't show this if the plugin has been activated after 29th of July 2018
725
+ $first_activation = get_option( 'dpsp_first_activation', '' );
726
+
727
+ if( empty( $first_activation ) )
728
+ return;
729
+
730
+ if( $first_activation > strtotime( '2019-06-10 00:00:00' ) )
731
+ return;
732
+
733
+ // Do not display this notice for users that have dismissed it
734
+ if( get_user_meta( get_current_user_id(), 'dpsp_admin_notice_google_plus_removal', true ) != '' )
735
+ return;
736
+
737
+ // Echo the admin notice
738
+ echo '<div class="dpsp-admin-notice notice notice-error">';
739
+
740
+ echo '<h4>' . __( 'Grow by Mediavine Important Notification', 'social-pug' ) . '</h4>';
741
+
742
+ echo '<p>' . __( 'As you may already know, Google+ has shut down. As a result, with this latest update, Grow by Mediavine no longer supports Google+ functionality.', 'social-pug' ) . '</p>';
743
+
744
+ echo '<p>' . __( 'Please make sure to verify your settings and remove any Google+ buttons you may have placed within your website.', 'social-pug' ) . '</p>';
745
+
746
+ echo '<p><a href="' . add_query_arg( array( 'dpsp_admin_notice_google_plus_removal' => 1 ) ) . '">' . __( 'Thank you, I understand.', 'social-pug' ) . '</a></p>';
747
+
748
+ echo '</div>';
749
+
750
+ }
751
+ add_action( 'admin_notices', 'dpsp_admin_notice_google_plus_removal' );
752
+
753
+ /**
754
+ * Add admin notice to anounce the name change
755
+ *
756
+ */
757
+ function dpsp_admin_notice_grow_name_change() {
758
+
759
+ // Do not display this notice if user cannot activate plugins
760
+ if( ! current_user_can( 'activate_plugins' ) )
761
+ return;
762
+
763
+ // Don't show this if the plugin has been activated after 30th of Nov 2019
764
+ $first_activation = get_option( 'dpsp_first_activation', '' );
765
+
766
+ if( empty( $first_activation ) )
767
+ return;
768
+
769
+ if( $first_activation > strtotime( '2019-11-30 00:00:00' ) )
770
+ return;
771
+
772
+ // Do not display this notice for users that have dismissed it
773
+ if( get_user_meta( get_current_user_id(), 'dpsp_admin_notice_grow_name_change', true ) != '' )
774
+ return;
775
+
776
+ // Echo the admin notice
777
+ echo '<div class="dpsp-admin-notice dpsp-admin-grow-notice notice notice-info">';
778
+ echo '<div class="notice-img-wrap" >';
779
+ echo '<img src="' . DPSP_PLUGIN_DIR_URL . 'assets/src/img/grow-logo-sq-navy.png" />';
780
+ echo '</div>';
781
+ echo '<div class="notice-text-wrap">';
782
+
783
+ echo '<h4>' . __( 'Social Pug is now Grow by Mediavine!', 'social-pug' ) . '</h4>';
784
+
785
+ echo '<p>' . __( 'You\'re going to notice some new paint and a new name today and we wanted to let you know what that\'s all about. The short version is that Grow by Mediavine is the same plugin you know and love but with a new, larger development team!', 'social-pug' ) . '</p>';
786
+
787
+ echo '<p><a href="https://www.mediavine.com/social-pug-is-now-grow-mediavines-new-social-sharing-buttons-marketplace-more/" target="_blank">' . __( 'Check out the blog post', 'social-pug') . '</a>' . __( ' for all the details on this development and our exciting plans to continue Growing an already awesome plugin.', 'social-pug' ) . '</p>';
788
+
789
+ echo '<p class="notice-subtext">' . __( '(Those who are familiar with Mediavine for our full-service ad management, rest assured that this plugin is totally independent of ads and available to anyone and everyone who wants to Grow their social presence.)', 'social-pug' ) . '</p>';
790
+
791
+ echo '<p><a href="' . add_query_arg( array( 'dpsp_admin_notice_grow_name_change' => 1 ) ) . '">' . __( 'Thank you, I understand.', 'social-pug' ) . '</a></p>';
792
+
793
+ echo '</div>';
794
+ echo '</div>';
795
+
796
+ }
797
+ add_action( 'admin_notices', 'dpsp_admin_notice_grow_name_change' );
798
+
799
+
800
+ /**
801
+ * Add admin notice to anounce the removal of StumbleUpon
802
+ *
803
+ */
804
+ function dpsp_admin_notice_facebook_app_authorized() {
805
+
806
+ // Do not display this notice if user cannot activate plugins
807
+ if( ! current_user_can( 'activate_plugins' ) )
808
+ return;
809
+
810
+ $settings = get_option( 'dpsp_settings', array() );
811
+
812
+ if( ! empty( $settings['facebook_app_access_token'] ) )
813
+ return;
814
+
815
+ $access_token = get_transient( 'dpsp_facebook_access_token' );
816
+
817
+ if( ! empty( $access_token['access_token'] ) && ! empty( $access_token['expires_in'] ) )
818
+ return;
819
+
820
+ // Do not display this notice for users that have dismissed it
821
+ if( get_user_meta( get_current_user_id(), 'dpsp_admin_notice_facebook_app_authorized', true ) != '' )
822
+ return;
823
+
824
+ // Echo the admin notice
825
+ echo '<div class="dpsp-admin-notice notice notice-warning">';
826
+
827
+ echo '<a class="notice-dismiss" href="' . add_query_arg( array( 'dpsp_admin_notice_facebook_app_authorized' => 1 ) ) . '"></a>';
828
+
829
+ echo '<h4>' . __( 'Grow Notification', 'social-pug' ) . '</h4>';
830
+
831
+ echo '<p>' . __( "To activate social share counts for Facebook, connecting Grow to a Facebook App is required. Please click the button below for a step-by-step guide on how to achieve this.", 'social-pug' ) . '</p>';
832
+
833
+ echo '<p><a class="dpsp-button-primary" target="_blank" href="https://docs.devpups.com/social-pug/activate-facebook-share-counts/">Learn how to activate Facebook share counts</a></p>';
834
+
835
+ echo '</div>';
836
+
837
+ }
838
+ add_action( 'admin_notices', 'dpsp_admin_notice_facebook_app_authorized' );
839
+
840
+
841
+ /*
842
+ * Handle admin notices dismissals
843
+ *
844
+ */
845
+ function dpsp_admin_notice_dismiss() {
846
+
847
+ if( isset( $_GET['dpsp_admin_notice_activation'] ) )
848
+ add_user_meta( get_current_user_id(), 'dpsp_admin_notice_first_activation', 1, true );
849
+
850
+ if( isset( $_GET['dpsp_admin_notice_promo_opt_in_hound'] ) )
851
+ add_user_meta( get_current_user_id(), 'dpsp_admin_notice_promo_opt_in_hound', 1, true );
852
+
853
+ if( isset( $_GET['dpsp_admin_notice_google_plus_removal'] ) )
854
+ add_user_meta( get_current_user_id(), 'dpsp_admin_notice_google_plus_removal', 1, true );
855
+
856
+ if( isset( $_GET['dpsp_admin_notice_facebook_app_authorized'] ) )
857
+ add_user_meta( get_current_user_id(), 'dpsp_admin_notice_facebook_app_authorized', 1, true );
858
+
859
+ if( isset( $_GET['dpsp_admin_notice_grow_name_change'] ) )
860
+ add_user_meta( get_current_user_id(), 'dpsp_admin_notice_grow_name_change', 1, true );
861
+ }
862
+ add_action( 'admin_init', 'dpsp_admin_notice_dismiss' );
863
+
864
+
inc/functions-cron.php ADDED
@@ -0,0 +1,134 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+
4
+ /*
5
+ * Add custom schedules to use for the cron jobs
6
+ *
7
+ */
8
+ function dpsp_cron_schedules( $schedules ) {
9
+
10
+ $schedules['dpsp_2x_hourly'] = array(
11
+ 'interval' => (3600 * 2),
12
+ 'display' => __( 'Once every two hours', 'social-pug' )
13
+ );
14
+
15
+ return $schedules;
16
+
17
+ }
18
+ add_filter( 'cron_schedules', 'dpsp_cron_schedules' );
19
+
20
+
21
+ /*
22
+ * Set cron jobs
23
+ *
24
+ * @return void
25
+ *
26
+ */
27
+ function dpsp_set_cron_jobs() {
28
+
29
+ wp_schedule_event( time(), 'dpsp_2x_hourly', 'dpsp_cron_get_posts_networks_share_count');
30
+
31
+ }
32
+
33
+
34
+ /*
35
+ * Stop cron jobs
36
+ *
37
+ * @return void
38
+ *
39
+ */
40
+ function dpsp_stop_cron_jobs() {
41
+
42
+ wp_clear_scheduled_hook( 'dpsp_cron_get_posts_networks_share_count' );
43
+
44
+ }
45
+
46
+
47
+ /*
48
+ * Retreives the share counts for each post, for each network and saves
49
+ * them in the post meta
50
+ *
51
+ * @return void
52
+ *
53
+ */
54
+ function dpsp_cron_get_posts_networks_share_count() {
55
+
56
+ $settings = get_option( 'dpsp_settings', array() );
57
+
58
+ /*
59
+ * Start with getting all post types saved in every
60
+ * settings page. We only wish to get share counts for the
61
+ * posts that have these certain post types.
62
+ *
63
+ * Also get all active social networks from each of the
64
+ * settings page
65
+ *
66
+ */
67
+ $locations = dpsp_get_network_locations();
68
+ $social_networks = dpsp_get_active_networks();
69
+ $post_types = array();
70
+
71
+ foreach( $locations as $location ) {
72
+
73
+ $location_settings = get_option( 'dpsp_location_' . $location );
74
+
75
+ /*
76
+ * Get post types of settings page
77
+ *
78
+ */
79
+ if( isset( $location_settings['post_type_display'] ) )
80
+ $post_types = array_merge( $post_types, $location_settings['post_type_display'] );
81
+
82
+ }
83
+
84
+
85
+ /*
86
+ * Filter post types
87
+ *
88
+ */
89
+ $post_types = array_unique( $post_types );
90
+ $registered_post_types = get_post_types();
91
+
92
+ foreach( $post_types as $key => $post_type ) {
93
+ if( !in_array($post_type, $registered_post_types) )
94
+ unset( $post_types[$key] );
95
+ }
96
+
97
+
98
+ /*
99
+ * Get all posts for each post type saved in every
100
+ * settings page and get network share counts
101
+ *
102
+ */
103
+ $args = array( 'post_type' => $post_types, 'numberposts' => 20 );
104
+
105
+ if( ! empty( $settings['facebook_app_access_token'] ) )
106
+ $args['numberposts'] = 500;
107
+
108
+
109
+ // Get posts
110
+ $posts = get_posts( $args );
111
+
112
+
113
+ // Exit execution for following statements
114
+ if( empty( $posts ) )
115
+ return;
116
+
117
+ if( empty( $social_networks ) )
118
+ return;
119
+
120
+
121
+ // Continue if we reach this point
122
+ foreach( $posts as $post_object ) {
123
+
124
+ // Get social shares from the networks
125
+ $share_counts = dpsp_pull_post_share_counts( $post_object->ID );
126
+
127
+ // Update share counts in the db
128
+ $shares_updated = dpsp_update_post_share_counts( $post_object->ID, $share_counts );
129
+
130
+
131
+ } // End of posts loop
132
+
133
+ }
134
+ //add_action( 'dpsp_cron_get_posts_networks_share_count', 'dpsp_cron_get_posts_networks_share_count' );
inc/functions-frontend.php ADDED
@@ -0,0 +1,468 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+
4
+ /*
5
+ * Function that displays the floating sidebar sharing buttons
6
+ *
7
+ */
8
+ function dpsp_output_front_end_floating_sidebar() {
9
+
10
+ if( !dpsp_is_location_displayable( 'sidebar' ) )
11
+ return;
12
+
13
+ // Get saved settings
14
+ $settings = get_option( 'dpsp_location_sidebar', array() );
15
+
16
+ if( !isset( $settings['post_type_display'] ) || ( isset( $settings['post_type_display'] ) && !is_singular( $settings['post_type_display'] ) ) )
17
+ return;
18
+
19
+
20
+ // Classes for the wrapper
21
+ $wrapper_classes = array();
22
+ $wrapper_classes[] = ( isset( $settings['display']['spacing'] ) ? 'dpsp-bottom-spacing' : '' );
23
+ $wrapper_classes[] = ( isset( $settings['display']['position'] ) ? 'dpsp-position-' . $settings['display']['position'] : '' );
24
+ $wrapper_classes[] = ( isset( $settings['display']['shape'] ) ? 'dpsp-shape-' . $settings['display']['shape'] : '' );
25
+ $wrapper_classes[] = ( isset( $settings['display']['show_count'] ) ? 'dpsp-has-buttons-count' : '' );
26
+ $wrapper_classes[] = ( isset( $settings['display']['show_mobile'] ) ? 'dpsp-show-on-mobile' : 'dpsp-hide-on-mobile' );
27
+
28
+ // Button styles
29
+ $wrapper_classes[] = ( isset( $settings['button_style'] ) ? 'dpsp-button-style-' . $settings['button_style'] : '' );
30
+ $wrapper_classes[] = ( isset( $settings['button_style'] ) && $settings['button_style'] == 1 ? 'dpsp-has-button-background' : '' );
31
+ $wrapper_classes[] = ( isset( $settings['button_style'] ) && $settings['button_style'] == 2 ? 'dpsp-button-hover' : '' );
32
+
33
+ $wrapper_classes = implode(' ', $wrapper_classes);
34
+
35
+ $output = '<div id="dpsp-floating-sidebar" class="' . $wrapper_classes . '">';
36
+
37
+ // Total share count before buttons
38
+ if( isset( $settings['display']['show_count_total'] ) && ( !isset( $settings['display']['total_count_position'] ) || $settings['display']['total_count_position'] == 'before' ) )
39
+ $output .= dpsp_get_output_total_share_count( 'sidebar' );
40
+
41
+ // Gets the social networks buttons
42
+ if( isset( $settings['networks'] ) )
43
+ $output .= dpsp_get_output_network_buttons( $settings, 'sidebar' );
44
+
45
+ // Total share count after buttons
46
+ if( isset( $settings['display']['show_count_total'] ) && $settings['display']['total_count_position'] == 'after' )
47
+ $output .= dpsp_get_output_total_share_count( 'sidebar' );
48
+
49
+
50
+ $output .= '</div>';
51
+
52
+ // Echo the final output
53
+ echo apply_filters( 'dpsp_output_front_end_floating_sidebar', $output );
54
+
55
+ }
56
+ add_action( 'wp_footer', 'dpsp_output_front_end_floating_sidebar' );
57
+
58
+
59
+
60
+ /*
61
+ * Function that displays the sharing buttons in the post content
62
+ *
63
+ */
64
+ function dpsp_output_front_end_content( $content ) {
65
+
66
+ // Make sure the_content isn't executed in wp_head
67
+ global $wp_current_filter;
68
+
69
+ if( ! empty( $wp_current_filter ) && is_array( $wp_current_filter ) ) {
70
+
71
+ foreach( $wp_current_filter as $filter ) {
72
+
73
+ if( $filter == 'wp_head' )
74
+ return $content;
75
+
76
+ }
77
+
78
+ }
79
+
80
+ if( ! is_main_query() )
81
+ return $content;
82
+
83
+ if( ! dpsp_is_location_displayable( 'content' ) )
84
+ return $content;
85
+
86
+ // Get saved settings
87
+ $settings = dpsp_get_location_settings( 'content' );
88
+
89
+ // Get the post object
90
+ $post_obj = dpsp_get_current_post();
91
+
92
+ if( ! $post_obj )
93
+ return $content;
94
+
95
+ global $post;
96
+
97
+ if( $post_obj->ID != $post->ID )
98
+ return $content;
99
+
100
+ if( !isset( $settings['post_type_display'] ) || ( isset( $settings['post_type_display'] ) && !is_singular( $settings['post_type_display'] ) ) )
101
+ return $content;
102
+
103
+
104
+ // Set output
105
+ $output = '';
106
+
107
+ // Classes for the wrapper
108
+ $wrapper_classes = array( 'dpsp-content-wrapper' );
109
+ $wrapper_classes[] = ( isset( $settings['display']['shape'] ) ? 'dpsp-shape-' . $settings['display']['shape'] : '' );
110
+ $wrapper_classes[] = ( isset( $settings['display']['column_count'] ) ? 'dpsp-column-' . $settings['display']['column_count'] : '' );
111
+ $wrapper_classes[] = ( isset( $settings['display']['spacing'] ) ? 'dpsp-has-spacing' : '' );
112
+ $wrapper_classes[] = ( isset( $settings['display']['show_labels'] ) || isset( $settings['display']['show_count'] ) ? '' : 'dpsp-no-labels' );
113
+ $wrapper_classes[] = ( isset( $settings['display']['show_count'] ) ? 'dpsp-has-buttons-count' : '' );
114
+ $wrapper_classes[] = ( isset( $settings['display']['show_mobile'] ) ? 'dpsp-show-on-mobile' : 'dpsp-hide-on-mobile' );
115
+
116
+ // Button styles
117
+ $wrapper_classes[] = ( isset( $settings['button_style'] ) ? 'dpsp-button-style-' . $settings['button_style'] : '' );
118
+ $wrapper_classes[] = ( isset( $settings['button_style'] ) && $settings['button_style'] == 1 ? 'dpsp-has-icon-background dpsp-has-button-background' : '' );
119
+ $wrapper_classes[] = ( isset( $settings['button_style'] ) && $settings['button_style'] == 2 ? 'dpsp-has-icon-background dpsp-has-icon-dark dpsp-has-button-background' : '' );
120
+ $wrapper_classes[] = ( isset( $settings['button_style'] ) && $settings['button_style'] == 3 ? 'dpsp-has-icon-background dpsp-button-hover' : '' );
121
+ $wrapper_classes[] = ( isset( $settings['button_style'] ) && $settings['button_style'] == 4 ? 'dpsp-has-button-background dpsp-icon-hover' : '' );
122
+ $wrapper_classes[] = ( isset( $settings['button_style'] ) && $settings['button_style'] == 5 ? 'dpsp-button-hover' : '' );
123
+ $wrapper_classes[] = ( isset( $settings['button_style'] ) && $settings['button_style'] == 6 ? 'dpsp-has-icon-background' : '' );
124
+ $wrapper_classes[] = ( isset( $settings['button_style'] ) && $settings['button_style'] == 7 ? 'dpsp-icon-hover' : '' );
125
+
126
+ // Button total share counts
127
+ $show_total_count = ( ! empty( $settings['display']['show_count_total'] ) ? true : false );
128
+
129
+ $wrapper_classes[] = ( $show_total_count ? 'dpsp-show-total-share-count' : '' );
130
+ $wrapper_classes[] = ( $show_total_count ? ( ! empty( $settings['display']['total_count_position'] ) ? 'dpsp-show-total-share-count-' . $settings['display']['total_count_position'] : 'dpsp-show-total-share-count-before' ) : '' );
131
+
132
+ $wrapper_classes = implode( ' ', array_filter( $wrapper_classes ) );
133
+
134
+ // Total share count before buttons
135
+ if( isset( $settings['display']['show_count_total'] ) && ( !isset( $settings['display']['total_count_position'] ) || $settings['display']['total_count_position'] == 'before' ) )
136
+ $output .= dpsp_get_output_total_share_count( 'content' );
137
+
138
+ // Gets the social network buttons
139
+ if( isset( $settings['networks'] ) )
140
+ $output .= dpsp_get_output_network_buttons( $settings, 'content' );
141
+
142
+ // Total share count before buttons
143
+ if( isset( $settings['display']['show_count_total'] ) && $settings['display']['total_count_position'] == 'after' )
144
+ $output .= dpsp_get_output_total_share_count( 'content' );
145
+
146
+
147
+ $output = apply_filters( 'dpsp_output_front_end_content', $output );
148
+
149
+ // Wrap output for top and bottom cases
150
+ $output_top = '<div id="dpsp-content-top" class="' . $wrapper_classes . '">' . $output . '</div>';
151
+ $output_bottom = '<div id="dpsp-content-bottom" class="' . $wrapper_classes . '">' . $output . '</div>';
152
+
153
+ // Share text
154
+ if( !empty( $settings['display']['message'] ) ) {
155
+
156
+ $share_text = '<p class="dpsp-share-text">' . esc_attr( $settings['display']['message'] ) . '</p>';
157
+
158
+ $output_top = $share_text . $output_top;
159
+ $output_bottom = $share_text . $output_bottom;
160
+
161
+ }
162
+
163
+ // Concatenate output and content
164
+ if( $settings['display']['position'] == 'top' ) {
165
+ $content = $output_top . $content;
166
+ } elseif( $settings['display']['position'] == 'bottom' ) {
167
+ $content = $content . $output_bottom;
168
+ } else {
169
+ $content = $output_top . $content . $output_bottom;
170
+ }
171
+
172
+ return $content;
173
+
174
+ }
175
+ add_filter( 'the_content', 'dpsp_output_front_end_content' );
176
+ add_filter( 'woocommerce_short_description', 'dpsp_output_front_end_content' );
177
+
178
+
179
+ /**
180
+ * Returns the social network buttons
181
+ *
182
+ * @param array $settings - the current section settings for the social networks
183
+ * @param string $location - the location where the social networks will be displayed
184
+ *
185
+ */
186
+ function dpsp_get_output_network_buttons( $settings, $location = '' ) {
187
+
188
+ // Return if no networks are found
189
+ if( empty( $settings['networks'] ) )
190
+ return '';
191
+
192
+ global $post;
193
+
194
+ $wrapper_classes = array();
195
+ $wrapper_classes[] = ( isset( $settings['display']['icon_animation'] ) ? 'dpsp-has-button-icon-animation' : '' );
196
+
197
+ $wrapper_classes = implode(' ', $wrapper_classes);
198
+
199
+ // Start concatenating the output
200
+ $output = '<ul class="dpsp-networks-btns-wrapper ' . ( ! empty( $location ) ? 'dpsp-networks-btns-' . esc_attr( $location ) : '' ) . ' ' . $wrapper_classes . '">';
201
+
202
+ // Set current network and networks count
203
+ $current_network = 1;
204
+ $networks_count = count( $settings['networks'] );
205
+
206
+ // Get networks share count for this post
207
+ if( $post )
208
+ $networks_shares = apply_filters( 'dpsp_get_output_post_shares_counts', dpsp_get_post_share_counts( $post->ID ), $location );
209
+
210
+ $networks_shares = ( !empty( $networks_shares ) ? $networks_shares : array() );
211
+
212
+ // Loop throught each network and create the button
213
+ foreach( $settings['networks'] as $network_slug => $network ) {
214
+
215
+ $output .= '<li>';
216
+
217
+ // Get share count for current network
218
+ $network_shares = ( isset( $networks_shares[$network_slug] ) ? $networks_shares[$network_slug] : 0 );
219
+ $network_shares = apply_filters( 'dpsp_get_output_post_network_share_count', $network_shares, $location );
220
+
221
+ // Check to see if the share counts should be displayed
222
+ $show_share_counts = ( in_array( $network_slug, dpsp_get_networks_with_social_count() ) && isset( $settings['display']['show_count'] ) ? true : false );
223
+
224
+ // Set button classes
225
+ $button_classes = array('dpsp-network-btn');
226
+ $button_classes[] = ( isset($network_slug) ? 'dpsp-' . $network_slug : '' );
227
+ $button_classes[] = ( ( empty( $network['label'] ) || !isset( $settings['display']['show_labels'] ) ) && !isset( $settings['display']['show_count'] ) ? 'dpsp-no-label' : '' );
228
+ $button_classes[] = ( $show_share_counts ? 'dpsp-has-count' : '' );
229
+ $button_classes[] = ( $current_network == 1 ? 'dpsp-first' : '' );
230
+ $button_classes[] = ( $current_network == $networks_count ? 'dpsp-last' : '' );
231
+ // Filter the button classes
232
+ $button_classes = apply_filters( 'dpsp_button_classes', $button_classes, $location, $network_shares );
233
+ $button_classes = array_filter($button_classes);
234
+
235
+
236
+ // Get the share link for the admin / front-end
237
+ if( ! is_admin() ) {
238
+
239
+ // Get post url and title
240
+ $post_url = rawurlencode( esc_url( dpsp_get_post_url() ) );
241
+ $post_title = rawurlencode( dpsp_get_post_title() );
242
+
243
+ $network_share_link = dpsp_get_network_share_link( $network_slug, $post_url, $post_title );
244
+
245
+ } else
246
+ $network_share_link = dpsp_get_network_share_link( $network_slug, '#', '' );
247
+
248
+ /**
249
+ * Filter the "rel" attribute before adding it
250
+ *
251
+ * @param array $rel
252
+ *
253
+ */
254
+ $rel = apply_filters( 'dpsp_network_button_attribute_rel', array( 'nofollow' ) );
255
+
256
+ // Output the network button
257
+ $output .= '<a ' . ( ! empty( $rel ) ? 'rel="' . esc_attr( implode( ' ', $rel ) ) . '"' : '' ) . ' href="' . $network_share_link . '" class="' . implode( ' ', $button_classes ) . '" title="' . esc_attr( dpsp_get_link_title_attribute( $network_slug ) ) . '">';
258
+
259
+ $output .= '<span class="dpsp-network-icon"></span>';
260
+
261
+ // Social network label and count wrapper
262
+ $output .= '<span class="dpsp-network-label-wrapper">';
263
+
264
+ // Labels output
265
+ if( ( isset( $settings['display']['show_labels'] ) || is_admin() ) && $location != 'sidebar' )
266
+ $output .= '<span class="dpsp-network-label">' . esc_attr( $network['label'] ) . '</span>';
267
+
268
+ // Social count
269
+ if( $show_share_counts )
270
+ $output .= '<span class="dpsp-network-count">' . esc_attr( $network_shares ) . '</span>';
271
+
272
+ $output .= '</span>';
273
+
274
+ $output .= '</a>';
275
+
276
+ // Add the label for the floating sidebar
277
+ if( $location == 'sidebar' && ! is_admin() && ! empty( $settings['display']['show_labels'] ) && ! empty( $network['label'] ) )
278
+ $output .= '<span class="dpsp-button-label">' . esc_attr( $network['label'] ) . '</span>';
279
+
280
+ $output .= '</li>';
281
+
282
+ // Increment network count
283
+ $current_network++;
284
+ }
285
+
286
+ $output .= '</ul>';
287
+
288
+ return $output;
289
+
290
+ }
291
+
292
+
293
+ /**
294
+ * Returns the value that should be populated in the link's "title" attribute,
295
+ * based on the provided network
296
+ *
297
+ * @param string $network_slug
298
+ *
299
+ * @return string
300
+ *
301
+ */
302
+ function dpsp_get_link_title_attribute( $network_slug ) {
303
+
304
+ $title = '';
305
+ $networks = dpsp_get_networks( 'all' );
306
+
307
+ $title = sprintf( __( 'Share on %s', 'social-pug' ), $networks[$network_slug] );
308
+
309
+ if( $network_slug == 'pinterest' ) {
310
+ $title = __( 'Save to Pinterest', 'social-pug' );
311
+ }
312
+
313
+ if( $network_slug == 'email' ) {
314
+ $title = __( 'Send over email', 'social-pug' );
315
+ }
316
+
317
+ if( $network_slug == 'print' ) {
318
+ $title = __( 'Print this webpage', 'social-pug' );
319
+ }
320
+
321
+ /**
322
+ * Filter the title before returning it
323
+ *
324
+ * @param string $title
325
+ * @param string $network_slug
326
+ *
327
+ */
328
+ $title = apply_filters( 'dpsp_link_title_attribute', $title, $network_slug );
329
+
330
+ return $title;
331
+
332
+ }
333
+
334
+
335
+ /*
336
+ * Returns the HTML for the total share counts of the networks passed
337
+ * If no networks are passed, the total count for all active networks will be outputed
338
+ *
339
+ * @param string $location - the location of the share buttons
340
+ * @param array $networks - list with all networks we wish to output total for
341
+ *
342
+ * @return int
343
+ *
344
+ */
345
+ function dpsp_get_output_total_share_count( $location = '', $networks = array() ) {
346
+
347
+ global $post;
348
+
349
+ if( !$post )
350
+ return;
351
+
352
+ $total_shares = dpsp_get_post_total_share_count( $post->ID, $networks, $location );
353
+
354
+ if( is_null($total_shares) )
355
+ return '';
356
+
357
+ // HTML output
358
+ $output = '<div class="dpsp-total-share-wrapper">';
359
+ $output .= '<span class="dpsp-icon-total-share"></span>';
360
+ $output .= '<span class="dpsp-total-share-count">' . apply_filters( 'dpsp_get_output_total_share_count', $total_shares, $location ) . '</span>';
361
+ $output .= '<span>' . apply_filters( 'dpsp_total_share_count_text', __( 'shares', 'social-pug' ) ) . '</span>';
362
+ $output .= '</div>';
363
+
364
+ return $output;
365
+ }
366
+
367
+
368
+ /*
369
+ * Outputs custom inline CSS needed for certain functionality
370
+ *
371
+ */
372
+ function dpsp_output_inline_style() {
373
+
374
+ // Styling default
375
+ $output = '';
376
+
377
+ /**
378
+ * Handle locations
379
+ *
380
+ */
381
+ $locations = dpsp_get_network_locations();
382
+
383
+ foreach( $locations as $location ) {
384
+
385
+ $location_settings = dpsp_get_location_settings( $location );
386
+
387
+ // Jump to next one if location is not active
388
+ if( empty( $location_settings['active'] ) )
389
+ continue;
390
+
391
+ /**
392
+ * Mobile display
393
+ *
394
+ */
395
+ switch( $location ) {
396
+
397
+ case 'sidebar':
398
+ $tool_html_selector = '#dpsp-floating-sidebar';
399
+ break;
400
+
401
+ case 'content':
402
+ $tool_html_selector = '.dpsp-content-wrapper';
403
+ break;
404
+
405
+ default:
406
+ $tool_html_selector = '';
407
+ break;
408
+
409
+ }
410
+
411
+ if( ! empty( $tool_html_selector ) && empty( $location_settings['display']['show_mobile'] ) ) {
412
+
413
+ $mobile_screen_width = ( ! empty( $location_settings['display']['screen_size'] ) ? (int)$location_settings['display']['screen_size'] : 720 );
414
+
415
+ $output .= '
416
+ @media screen and ( max-width : ' . $mobile_screen_width . 'px ) {
417
+ ' . $tool_html_selector . '.dpsp-hide-on-mobile { display: none !important; }
418
+ }
419
+ ';
420
+
421
+ }
422
+
423
+ }
424
+
425
+ // Actually outputting the styling
426
+ echo '<style type="text/css" data-source="Social Pug">' . apply_filters( 'dpsp_output_inline_style', $output ) . '</style>';
427
+
428
+ }
429
+ add_action( 'wp_head', 'dpsp_output_inline_style' );
430
+
431
+
432
+ /*
433
+ * Output the meta tags needed by the social networks
434
+ *
435
+ */
436
+ function dpsp_output_meta_tags() {
437
+
438
+ global $post;
439
+
440
+ $settings = get_option('dpsp_settings');
441
+
442
+ if( !empty( $settings['disable_meta_tags'] ) )
443
+ return;
444
+
445
+ if( !$post )
446
+ return;
447
+
448
+ if( !is_singular() )
449
+ return;
450
+
451
+ // Facebook specific
452
+ if( ! empty( $settings['facebook_app_id'] ) )
453
+ echo '<meta property="fb:app_id" content ="' . esc_attr( $settings['facebook_app_id'] ) . '" />';
454
+
455
+ // Twitter specific
456
+ echo '<meta name="twitter:card" content="summary_large_image" />';
457
+
458
+ // Meta tags for Open Graph
459
+ echo '<meta property="og:url" content="' . esc_attr( dpsp_get_post_url() ) . '" />';
460
+ echo '<meta property="og:type" content="article" />';
461
+ echo '<meta property="og:title" content="' . esc_attr( dpsp_get_post_title() ) . '" />';
462
+ echo '<meta property="og:description" content="' . esc_attr( dpsp_get_post_description() ) . '" />';
463
+ echo '<meta property="og:image" content="' . esc_attr( dpsp_get_post_image_url() ) . '" />';
464
+
465
+ do_action( 'dpsp_output_meta_tags' );
466
+
467
+ }
468
+ add_action( 'wp_head', 'dpsp_output_meta_tags' );
inc/functions-share-counts.php ADDED
@@ -0,0 +1,597 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Not all social networks support social count.
5
+ * This function returns an array of network slugs
6
+ * for the networks that do support it
7
+ *
8
+ * @return array
9
+ *
10
+ */
11
+ function dpsp_get_networks_with_social_count() {
12
+
13
+ $networks = array(
14
+ 'facebook',
15
+ 'pinterest'
16
+ );
17
+
18
+ // Twitter share counts are handled through TwitCount ( https://www.twitcount.com/ )
19
+ $settings = get_option( 'dpsp_settings' );
20
+
21
+ if( isset( $settings['twitter_share_counts'] ) )
22
+ array_push( $networks, 'twitter' );
23
+
24
+ /**
25
+ * Filter the networks that support share counts before returning
26
+ *
27
+ * @param array
28
+ *
29
+ */
30
+ return apply_filters( 'dpsp_get_networks_with_social_count', $networks );
31
+
32
+ }
33
+
34
+
35
+ /**
36
+ * Pulls the share counts for all active networks for a certain post
37
+ *
38
+ * @param int $post_id
39
+ *
40
+ * @return array
41
+ *
42
+ */
43
+ function dpsp_pull_post_share_counts( $post_id = 0 ) {
44
+
45
+ if( $post_id === 0 )
46
+ return $share_counts;
47
+
48
+ // Get active social networks
49
+ $social_networks = dpsp_get_active_networks();
50
+
51
+ // Get saved shares
52
+ $networks_shares = get_post_meta( $post_id, 'dpsp_networks_shares', true );
53
+
54
+ if( empty( $networks_shares ) )
55
+ $networks_shares = array();
56
+
57
+ // Pass through each active social networks and grab the share counts for the post
58
+ foreach( $social_networks as $network_slug ) {
59
+
60
+ if( ! in_array( $network_slug, dpsp_get_networks_with_social_count() ) )
61
+ continue;
62
+
63
+ $share_count = dpsp_get_post_network_share_count( $post_id, $network_slug );
64
+
65
+ if( $share_count === false )
66
+ continue;
67
+
68
+ /**
69
+ * Take into account Twitter old counts from NewShareCounts and OpenShareCount
70
+ *
71
+ * The post meta "dpsp_cache_shares_twitter" was used for NewShareCounts
72
+ * The post meta "dpsp_cache_shares_twitter_2" was used for OpenShareCount
73
+ *
74
+ */
75
+ if( $network_slug == 'twitter' && isset( $networks_shares[$network_slug] ) ) {
76
+
77
+ $cached_old_twitter_shares = get_post_meta( $post_id, 'dpsp_cache_shares_twitter_2', true );
78
+
79
+ // Add the Twitter shares to the cache if they do not exist
80
+ if( $cached_old_twitter_shares == '' ) {
81
+
82
+ $cached_old_twitter_shares = absint( $networks_shares[$network_slug] );
83
+
84
+ update_post_meta( $post_id, 'dpsp_cache_shares_twitter_2', $cached_old_twitter_shares );
85
+
86
+ // Delete the post meta for NewShareCounts
87
+ delete_post_meta( $post_id, 'dpsp_cache_shares_twitter' );
88
+
89
+ }
90
+
91
+ // Add the current shares to the cached ones
92
+ $share_count += $cached_old_twitter_shares;
93
+
94
+ }
95
+
96
+ // If share counts exist for this network, check to see if the new shares
97
+ // are greater than the existing ones. If so, replace the counts
98
+ if( isset( $networks_shares[$network_slug] ) )
99
+ $networks_shares[$network_slug] = ( $share_count > (int)$networks_shares[$network_slug] ? $share_count : (int)$networks_shares[$network_slug] ) ;
100
+
101
+ // If the share counts don't exist for the network, add them
102
+ else
103
+ $networks_shares[$network_slug] = $share_count;
104
+
105
+ } // End of social_networks loop
106
+
107
+
108
+ // Remove social counts for networks that are not required
109
+ if( !empty( $networks_shares ) ) {
110
+ foreach( $networks_shares as $network_slug => $share_count ) {
111
+ if( !in_array( $network_slug, $social_networks ) )
112
+ unset( $networks_shares[ $network_slug ] );
113
+ }
114
+ }
115
+
116
+ // Return
117
+ return $networks_shares;
118
+
119
+ }
120
+
121
+
122
+ /**
123
+ * Refreshes the share counts if the share counts cache has expired
124
+ *
125
+ */
126
+ function dpsp_refresh_post_share_counts() {
127
+
128
+ if( ! is_singular() )
129
+ return;
130
+
131
+ $current_post = dpsp_get_current_post();
132
+
133
+ if( is_null( $current_post ) )
134
+ return;
135
+
136
+ if( in_array( $current_post->post_status, array( 'future', 'draft', 'pending', 'trash', 'auto-draft' ) ) )
137
+ return;
138
+
139
+ $expired = dpsp_is_post_share_counts_cache_expired( $current_post );
140
+
141
+ if( ! $expired )
142
+ return;
143
+
144
+ // Get social shares from the networks
145
+ $share_counts = dpsp_pull_post_share_counts( $current_post->ID );
146
+
147
+ // Update share counts in the db
148
+ $shares_updated = dpsp_update_post_share_counts( $current_post->ID, $share_counts );
149
+
150
+ }
151
+ add_action( 'wp_head', 'dpsp_refresh_post_share_counts', 10 );
152
+
153
+
154
+ /**
155
+ * Checks to see if the post's share counts were updated recently or not
156
+ *
157
+ * @param int $post_id
158
+ *
159
+ * @return bool
160
+ *
161
+ */
162
+ function dpsp_is_post_share_counts_cache_expired( $post_id ) {
163
+
164
+ if ( isset( $_SERVER['HTTP_USER_AGENT'] ) && preg_match( '/bot|crawl|slurp|spider/i', wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ) )
165
+ return false;
166
+
167
+ if( ! is_singular() )
168
+ return false;
169
+
170
+ // Get the post's time
171
+ $post_time = get_post_time( 'U', false, $post_id );
172
+
173
+ // Set the refresh rate, depending on how many days
174
+ // have pased since it was created
175
+ if( time() - $post_time <= 10 * DAY_IN_SECONDS )
176
+ $refresh_rate = 2;
177
+
178
+ elseif( time() - $post_time <= 20 * DAY_IN_SECONDS )
179
+ $refresh_rate = 6;
180
+
181
+ else
182
+ $refresh_rate = 12;
183
+
184
+ // Get the last updated time for the share counts
185
+ $shares_last_updated = (int)get_post_meta( $post_id, 'dpsp_networks_shares_last_updated', true );
186
+
187
+ if( $shares_last_updated >= time() - $refresh_rate * HOUR_IN_SECONDS )
188
+ return false;
189
+ else
190
+ return true;
191
+
192
+ }
193
+
194
+
195
+ /**
196
+ * Returns the share count for a post and a social network from the
197
+ * social network through an API
198
+ *
199
+ * @param int post_id - id of the post
200
+ * @param string $network_slug - slug of the social network
201
+ *
202
+ * @return mixed - bool false if something went wrong, and int if everything went well
203
+ *
204
+ */
205
+ function dpsp_get_post_network_share_count( $post_id, $network_slug ) {
206
+
207
+ if( !isset( $post_id ) && !isset( $network_slug ) )
208
+ return false;
209
+
210
+ // Plugin settings
211
+ $settings = get_option( 'dpsp_settings', array() );
212
+
213
+ // Get page url for the post
214
+ $page_url = get_permalink( $post_id );
215
+ $page_url = urlencode( $page_url );
216
+
217
+ // Default post arguments
218
+ $args = array( 'timeout' => 30 );
219
+
220
+ // Prepare urls to get remote request
221
+ switch( $network_slug ) {
222
+
223
+ case 'facebook':
224
+
225
+ $access_token = '';
226
+
227
+ if( ! empty( $settings['facebook_share_counts_provider'] ) ) {
228
+
229
+ // Grab the token from the authorized app
230
+ if( $settings['facebook_share_counts_provider'] == 'authorized_app' ) {
231
+
232
+ $transient = get_transient( 'dpsp_facebook_access_token' );
233
+ $access_token = ( ! empty( $transient['access_token'] ) ? $transient['access_token'] : '' );
234
+
235
+ }
236
+
237
+ // Grab the token from the user's own app
238
+ if( $settings['facebook_share_counts_provider'] == 'own_app' ) {
239
+
240
+ $access_token = ( ! empty( $settings['facebook_app_access_token'] ) ? $settings['facebook_app_access_token'] : '' );
241
+
242
+ }
243
+
244
+ }
245
+
246
+ if( empty( $access_token ) )
247
+ $url = 'https://graph.facebook.com/?id=' . $page_url;
248
+ else
249
+ $url = 'https://graph.facebook.com/v2.12/?id=' . $page_url . '&access_token=' . $access_token . '&fields=engagement';
250
+
251
+ break;
252
+
253
+ case 'twitter':
254
+ $url = 'https://counts.twitcount.com/counts.php?url=' . $page_url;
255
+ break;
256
+
257
+ case 'pinterest':
258
+ $url = 'http://widgets.pinterest.com/v1/urls/count.json?source=6&url=' . $page_url;
259
+ break;
260
+
261
+ case 'linkedin':
262
+ $url = 'https://www.linkedin.com/countserv/count/share?format=json&url=' . $page_url;
263
+ break;
264
+
265
+ }
266
+
267
+ // Get response from the api call
268
+ $response = wp_remote_get( $url, $args );
269
+
270
+
271
+ // Continue only if response code is 200
272
+ if( wp_remote_retrieve_response_code( $response ) == 200 ) {
273
+
274
+ $body = json_decode( wp_remote_retrieve_body( $response ), true );
275
+
276
+ // Get share value from response body
277
+ switch( $network_slug ) {
278
+
279
+ case 'facebook':
280
+ $reaction_count = isset( $body['engagement']['reaction_count'] ) ? $body['engagement']['reaction_count'] : false;
281
+ $comment_count = isset( $body['engagement']['comment_count'] ) ? $body['engagement']['comment_count'] : false;
282
+ $share_count = isset( $body['engagement']['share_count'] ) ? $body['engagement']['share_count'] : false;
283
+
284
+ $share_count = ( false !== $reaction_count && false !== $comment_count && false !== $share_count ? (int)$reaction_count + (int)$comment_count + (int)$share_count : false );
285
+
286
+ break;
287
+
288
+ case 'pinterest':
289
+ $body = wp_remote_retrieve_body( $response );
290
+ $start = strpos( $body, '(' );
291
+ $end = strpos( $body, ')', $start + 1 );
292
+ $length = $end - $start;
293
+ $body = json_decode( substr( $body, $start + 1, $length - 1 ), true );
294
+
295
+ $share_count = ( isset( $body['count'] ) ? $body['count'] : false );
296
+
297
+ break;
298
+
299
+ default:
300
+ $share_count = ( isset( $body['count'] ) ? $body['count'] : false );
301
+ break;
302
+
303
+ }
304
+
305
+ return ( $share_count ? (int)$share_count : $share_count );
306
+
307
+ } else {
308
+
309
+ return false;
310
+
311
+ }
312
+
313
+ return false;
314
+
315
+ }
316
+
317
+
318
+ /**
319
+ * Returns an array with the saved shares from the database
320
+ *
321
+ * @param $post_id
322
+ *
323
+ * @return array
324
+ *
325
+ */
326
+ function dpsp_get_post_share_counts( $post_id = 0 ) {
327
+
328
+ $network_shares = get_post_meta( $post_id, 'dpsp_networks_shares', true );
329
+
330
+ if( empty( $network_shares ) )
331
+ $network_shares = array();
332
+
333
+ /**
334
+ * Filter the post's network shares before returning them
335
+ *
336
+ * @param array $network_shares
337
+ * @param int $post_id
338
+ *
339
+ */
340
+ $network_shares = apply_filters( 'dpsp_get_post_share_counts', $network_shares, $post_id );
341
+
342
+ return $network_shares;
343
+
344
+ }
345
+
346
+
347
+ /**
348
+ * Returns the share count saved for a post given the post_id and the
349
+ * network we wish to retreive the value for
350
+ *
351
+ * @param int post_id - id of the post
352
+ * @param string $network_slug - slug of the social network
353
+ *
354
+ * @return mixed - bool false if something went wrong, and int if everything went well
355
+ *
356
+ */
357
+ function dpsp_get_post_share_count( $post_id, $network_slug ) {
358
+
359
+ if( !isset( $post_id ) && !isset( $network_slug ) )
360
+ return false;
361
+
362
+
363
+ $shares = dpsp_get_post_share_counts( $post_id );
364
+
365
+ if( isset( $shares[$network_slug] ) && in_array( $network_slug, dpsp_get_networks_with_social_count() ) )
366
+ return $shares[$network_slug];
367
+ else
368
+ return false;
369
+
370
+ }
371
+
372
+
373
+ /**
374
+ * Updates the given share counts for a post into the database
375
+ *
376
+ * @param int $post_id - the id of the post to save the shares
377
+ * @param array $shares - an array with the network shares and total shares
378
+ *
379
+ * @return bool
380
+ *
381
+ */
382
+ function dpsp_update_post_share_counts( $post_id = 0, $share_counts = array() ) {
383
+
384
+ if( empty( $post_id ) || empty( $share_counts ) )
385
+ return false;
386
+
387
+ // Update post meta with all shares
388
+ update_post_meta( $post_id, 'dpsp_networks_shares', $share_counts );
389
+
390
+ // Update post meta with total share counts
391
+ update_post_meta( $post_id, 'dpsp_networks_shares_total', array_sum( $share_counts ) );
392
+
393
+ // Update post meta with last updated timestamp
394
+ update_post_meta( $post_id, 'dpsp_networks_shares_last_updated', time() );
395
+
396
+
397
+ /**
398
+ * Do extra actions after updating the post's share counts
399
+ *
400
+ * @param int $post_id - the id of the post to save the shares
401
+ * @param array $shares - an array with the network shares and total shares
402
+ *
403
+ */
404
+ do_action( 'dpsp_update_post_share_counts', $post_id, $share_counts );
405
+
406
+ return true;
407
+
408
+ }
409
+
410
+
411
+ /**
412
+ * Updates the top shared posts array
413
+ *
414
+ * @param int $post_id - the id of the post to save the shares
415
+ * @param array $shares - an array with the network shares and total shares
416
+ *
417
+ * @return bool
418
+ *
419
+ */
420
+ function dpsp_update_top_shared_posts( $post_id = 0, $share_counts = array() ) {
421
+
422
+ if( empty( $post_id ) || empty( $share_counts ) )
423
+ return false;
424
+
425
+ // Get the post's post type
426
+ $post_type = get_post_type( $post_id );
427
+
428
+ // Get current saved top shared posts
429
+ $top_posts = get_option( 'dpsp_top_shared_posts', array() );
430
+
431
+ // Decode the top posts into an array
432
+ if( ! empty( $top_posts ) && ! is_array($top_posts) )
433
+ $top_posts = json_decode( $top_posts, ARRAY_A );
434
+
435
+
436
+ $top_posts[$post_type][$post_id] = array_sum( $share_counts );
437
+
438
+
439
+ /**
440
+ * Filter top shared posts before saving in the db
441
+ *
442
+ * @param array $top_posts
443
+ *
444
+ */
445
+ $top_posts = apply_filters( 'dpsp_top_shared_posts_raw', $top_posts );
446
+
447
+
448
+ // Filter top posts array
449
+ if( ! empty( $top_posts ) ) {
450
+ foreach( $top_posts as $post_type => $post_list ) {
451
+ if( ! empty( $top_posts[$post_type] ) ) {
452
+
453
+ // Sort descending
454
+ arsort( $top_posts[$post_type] );
455
+
456
+ // Get only first ten
457
+ $top_posts[$post_type] = array_slice( $top_posts[$post_type], 0, 10, true );
458
+
459
+ }
460
+ }
461
+ }
462
+
463
+ // Update top posts
464
+ update_option( 'dpsp_top_shared_posts', json_encode( $top_posts ) );
465
+
466
+ return true;
467
+
468
+ }
469
+ add_action( 'dpsp_update_post_share_counts', 'dpsp_update_top_shared_posts', 10, 2 );
470
+
471
+
472
+ /**
473
+ * Return total share count calculated for the social networks passed, if no social network is passed
474
+ * the total share value will be calculated for all active networks
475
+ *
476
+ * @param array $networks - the networks for which we want to return the total count
477
+ * @param string $location - the location of the share buttons
478
+ *
479
+ * @return int
480
+ *
481
+ */
482
+ function dpsp_get_post_total_share_count( $post_id = 0, $networks = array(), $location = '' ) {
483
+
484
+ if( $post_id == 0 ) {
485
+ global $post;
486
+ $post_id = $post->ID;
487
+ }
488
+
489
+ if( empty($networks) )
490
+ $networks = dpsp_get_active_networks();
491
+
492
+
493
+ // Get saved total share counts
494
+ $total_shares = get_post_meta( $post_id, 'dpsp_networks_shares_total', true );
495
+
496
+ // If the total shares are not set in the post meta, calculate them
497
+ // based on the shares for each platform
498
+ if( empty( $total_shares ) ) {
499
+
500
+ $total_shares = 0;
501
+
502
+ // Get network shares for this post
503
+ $networks_shares = get_post_meta( $post_id, 'dpsp_networks_shares', true );
504
+ $networks_shares = ( !empty( $networks_shares ) ? $networks_shares : array() );
505
+
506
+ // Pass through each network and increment the total shares counter
507
+ foreach( $networks as $network_slug )
508
+ $total_shares += ( isset($networks_shares[$network_slug]) && in_array( $network_slug, dpsp_get_networks_with_social_count() ) ? $networks_shares[$network_slug] : 0 );
509
+
510
+ }
511
+
512
+ /**
513
+ * Filter total shares before returning them
514
+ *
515
+ * @param int $total_shares
516
+ * @param string $location
517
+ *
518
+ */
519
+ $total_shares = apply_filters( 'dpsp_get_post_total_share_count', (int)$total_shares, $location );
520
+
521
+ return $total_shares;
522
+
523
+ }
524
+
525
+
526
+ /**
527
+ * Rounds the share counts
528
+ *
529
+ * @param int $share_count
530
+ * @param string $location
531
+ *
532
+ * @return int
533
+ *
534
+ */
535
+ function dpsp_round_share_counts( $share_count, $location = '' ) {
536
+
537
+ if( empty( $location ) )
538
+ return $share_count;
539
+
540
+ if( empty( $share_count ) )
541
+ return $share_count;
542
+
543
+
544
+ $location_settings = get_option( 'dpsp_location_' . $location, array() );
545
+
546
+ if( !isset( $location_settings['display']['count_round'] ) )
547
+ return $share_count;
548
+
549
+ if( is_array( $share_count ) ) {
550
+
551
+ foreach( $share_count as $key => $count ) {
552
+ if( $count / 1000 >= 1 )
553
+ $share_count[$key] = round( $count / 1000, 1 ) . 'k';
554
+ }
555
+
556
+
557
+ } else {
558
+
559
+ if( $share_count / 1000 >= 1 )
560
+ $share_count = round( $share_count / 1000, 1 ) . 'k';
561
+
562
+ }
563
+
564
+ return $share_count;
565
+
566
+ }
567
+ add_filter( 'dpsp_get_output_post_shares_counts', 'dpsp_round_share_counts', 10, 2 );
568
+ add_filter( 'dpsp_get_output_total_share_count', 'dpsp_round_share_counts', 10, 2 );
569
+
570
+
571
+ /**
572
+ * Listens for the Facebook response with the access code from the Social Pug app
573
+ *
574
+ */
575
+ function dpsp_capture_authorize_facebook_access_token() {
576
+
577
+ if( empty( $_GET['tkn'] ) || ! wp_verify_nonce( $_GET['tkn'], 'dpsp_authorize_facebook_app' ) )
578
+ return;
579
+
580
+ if( empty( $_GET['facebook_access_token'] ) )
581
+ return;
582
+
583
+ if( empty( $_GET['expires_in'] ) )
584
+ return;
585
+
586
+ $transient = array(
587
+ 'access_token' => sanitize_text_field( $_GET['facebook_access_token'] ),
588
+ 'expires_in' => time() + absint( $_GET['expires_in'] )
589
+ );
590
+
591
+ set_transient( 'dpsp_facebook_access_token', $transient );
592
+
593
+ wp_redirect( add_query_arg( array( 'page' => 'dpsp-settings', 'dpsp_message_id' => 4, 'settings-updated' => '' ), admin_url( 'admin.php' ) ) );
594
+ exit;
595
+
596
+ }
597
+ add_action( 'admin_init', 'dpsp_capture_authorize_facebook_access_token' );
inc/functions-version-update.php ADDED
@@ -0,0 +1,85 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * This file serves the purpose of updating database items when a new version of the plugin is released
4
+ *
5
+ */
6
+
7
+
8
+ /**
9
+ * Updates needed to the database when updating to version 1.5.1
10
+ *
11
+ * In this version OpenShareCount support has been removed, must default to TwitCount
12
+ *
13
+ * @param string $old_db_version - the previous version of the plugin
14
+ * @param string $new_db_version - the new version of the plugin
15
+ *
16
+ */
17
+ function dpsp_version_update_1_5_1( $old_db_version, $new_db_version ) {
18
+
19
+ // Do this only if the version is greater than 1.5.1
20
+ if( false === version_compare( $new_db_version, '1.5.1', '>=' ) )
21
+ return;
22
+
23
+ // Check to see if we've done this check before
24
+ $version_updated = get_option( 'dpsp_version_update_1_5_1', false );
25
+
26
+ if( $version_updated )
27
+ return;
28
+
29
+ // Update the main plugin settings
30
+ $settings = get_option( 'dpsp_settings', array() );
31
+
32
+ if( ! empty( $settings['twitter_share_counts'] ) )
33
+ unset( $settings['twitter_share_counts'] );
34
+
35
+ update_option( 'dpsp_settings', $settings );
36
+
37
+ // Save a true bool value in the database so we know we've done this
38
+ // version update
39
+ update_option( 'dpsp_version_update_1_5_1', 1 );
40
+
41
+ }
42
+ add_action( 'dpsp_update_database', 'dpsp_version_update_1_5_1', 10, 2 );
43
+
44
+
45
+ /**
46
+ * Updates needed to the database when updating to version 1.6.1
47
+ *
48
+ * In this version the Facebook share counts provider was added
49
+ *
50
+ * @param string $old_db_version - the previous version of the plugin
51
+ * @param string $new_db_version - the new version of the plugin
52
+ *
53
+ */
54
+ function dpsp_version_update_1_6_1( $old_db_version, $new_db_version ) {
55
+
56
+ // Do this only if the version is greater than 1.6.1
57
+ if( false === version_compare( $new_db_version, '1.6.1', '>=' ) )
58
+ return;
59
+
60
+ // Check to see if we've done this check before
61
+ $version_updated = get_option( 'dpsp_version_update_1_6_1', false );
62
+
63
+ if( $version_updated )
64
+ return;
65
+
66
+ // Update the main plugin settings
67
+ $settings = get_option( 'dpsp_settings', array() );
68
+
69
+ if( empty( $settings['facebook_share_counts_provider'] ) ) {
70
+
71
+ if( ! empty( $settings['facebook_app_id'] ) && ! empty( $settings['facebook_app_secret'] ) )
72
+ $settings['facebook_share_counts_provider'] = 'own_app';
73
+ else
74
+ $settings['facebook_share_counts_provider'] = 'authorized_app';
75
+
76
+ }
77
+
78
+ update_option( 'dpsp_settings', $settings );
79
+
80
+ // Save a true bool value in the database so we know we've done this
81
+ // version update
82
+ update_option( 'dpsp_version_update_1_6_1', 1 );
83
+
84
+ }
85
+ add_action( 'dpsp_update_database', 'dpsp_version_update_1_6_1', 10, 2 );
inc/functions.php ADDED
@@ -0,0 +1,627 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+
4
+ /**
5
+ * Returns all the tools available with all their data
6
+ *
7
+ */
8
+ function dpsp_get_tools( $type = 'all', $only_slugs = false ) {
9
+
10
+ $tools = array();
11
+
12
+ // Social share floating sidebar
13
+ $tools['share_sidebar'] = array(
14
+ 'name' => __( 'Floating Sidebar', 'social-pug' ),
15
+ 'type' => 'share_tool',
16
+ 'activation_setting' => 'dpsp_location_sidebar[active]',
17
+ 'img' => 'assets/src/img/tool-sidebar.png',
18
+ 'admin_page' => 'admin.php?page=dpsp-sidebar'
19
+ );
20
+
21
+ // Social share before and after the content
22
+ $tools['share_content'] = array(
23
+ 'name' => __( 'Inline Content', 'social-pug' ),
24
+ 'type' => 'share_tool',
25
+ 'activation_setting' => 'dpsp_location_content[active]',
26
+ 'img' => 'assets/src/img/tool-content.png',
27
+ 'admin_page' => 'admin.php?page=dpsp-content'
28
+ );
29
+
30
+ // Return only the tools of a certain type
31
+ if( $type != 'all' ) {
32
+ foreach( $tools as $tool_slug => $tool ) {
33
+ if( $tool['type'] != $type )
34
+ unset( $tools[$tool_slug] );
35
+ }
36
+ }
37
+
38
+ // Return only the slugs
39
+ if( $only_slugs )
40
+ $tools = array_keys( $tools );
41
+
42
+ return apply_filters( 'dpsp_get_tools', $tools );
43
+
44
+ }
45
+
46
+
47
+ /**
48
+ * Checks to see if the tool settings is active or not
49
+ *
50
+ */
51
+ function dpsp_is_tool_active( $tool_slug ) {
52
+
53
+ $tools = dpsp_get_tools();
54
+
55
+ if( empty( $tools[$tool_slug]['activation_setting'] ) )
56
+ return false;
57
+
58
+ $setting = $tools[$tool_slug]['activation_setting'];
59
+
60
+ $option_name = explode( '[', $setting );
61
+ $option_name = $option_name[0];
62
+
63
+ $settings = get_option( $option_name );
64
+
65
+ if( isset( $settings[ str_replace( array( $option_name, '[', ']' ) , '', $setting ) ] ) )
66
+ return true;
67
+ else
68
+ return false;
69
+
70
+ }
71
+
72
+
73
+ /**
74
+ * Returns an array with the positions where the social networks
75
+ * can be placed
76
+ *
77
+ * @return array
78
+ *
79
+ */
80
+ function dpsp_get_network_locations( $only_slugs = true ) {
81
+
82
+ $locations = array(
83
+ 'sidebar' => __( 'Floating Sidebar', 'social-pug' ),
84
+ 'content' => __( 'Content', 'social-pug' )
85
+ );
86
+
87
+ $locations = apply_filters( 'dpsp_get_network_locations', $locations );
88
+
89
+ if( $only_slugs )
90
+ $locations = array_keys( $locations );
91
+
92
+ return $locations;
93
+
94
+ }
95
+
96
+
97
+ /**
98
+ * Returns the name of a location
99
+ *
100
+ * @param string $location_slug
101
+ *
102
+ * @return string
103
+ *
104
+ */
105
+ function dpsp_get_network_location_name( $location_slug ) {
106
+
107
+ $locations = dpsp_get_network_locations( false );
108
+
109
+ if( isset( $locations[$location_slug] ) )
110
+ return $locations[$location_slug];
111
+ else
112
+ return '';
113
+
114
+ }
115
+
116
+
117
+ /**
118
+ * Checks to see if the location is active or not
119
+ *
120
+ */
121
+ function dpsp_is_location_active( $location_slug ) {
122
+
123
+ $settings = dpsp_get_location_settings( $location_slug );
124
+
125
+ if( isset( $settings['active'] ) )
126
+ return true;
127
+ else
128
+ return false;
129
+
130
+ }
131
+
132
+
133
+ /**
134
+ * Determines whether the location should be displayed or not
135
+ *
136
+ * @param string $location_slug
137
+ *
138
+ * @return bool
139
+ *
140
+ */
141
+ function dpsp_is_location_displayable( $location_slug ) {
142
+
143
+ $return = true;
144
+
145
+ // Get saved settings for the location
146
+ $settings = dpsp_get_location_settings( $location_slug );
147
+
148
+ if( empty( $settings ) )
149
+ $return = false;
150
+
151
+ if( !isset( $settings['active'] ) )
152
+ $return = false;
153
+
154
+ return apply_filters( 'dpsp_is_location_displayable', $return, $location_slug, $settings );
155
+
156
+ }
157
+
158
+
159
+ /**
160
+ * Get settings for a particular location
161
+ * This is a developer friendly function
162
+ *
163
+ * @param string $location
164
+ *
165
+ * @return mixed null | array
166
+ *
167
+ */
168
+ function dpsp_get_location_settings( $location = '' ) {
169
+
170
+ // Return null if no location is provided
171
+ if( empty( $location ) )
172
+ return null;
173
+
174
+ $location_settings = get_option( 'dpsp_location_' . $location, array() );
175
+
176
+ return apply_filters( 'dpsp_get_location_settings', $location_settings, $location );
177
+
178
+ }
179
+
180
+
181
+ /**
182
+ * Function that returns all networks
183
+ *
184
+ * @return array
185
+ *
186
+ */
187
+ function dpsp_get_networks() {
188
+
189
+ $nerworks = array(
190
+ 'facebook' => 'Facebook',
191
+ 'twitter' => 'Twitter',
192
+ 'pinterest' => 'Pinterest',
193
+ 'linkedin' => 'LinkedIn',
194
+ 'email' => 'Email',
195
+ 'print' => 'Print'
196
+ );
197
+
198
+ return apply_filters( 'dpsp_get_networks', $nerworks );
199
+
200
+ }
201
+
202
+
203
+ /**
204
+ * Function that returns the name of a social network given its slug
205
+ *
206
+ */
207
+ function dpsp_get_network_name( $slug ) {
208
+
209
+ $nerworks = dpsp_get_networks();
210
+
211
+ if( isset( $nerworks[$slug] ) )
212
+ return $nerworks[$slug];
213
+ else
214
+ return '';
215
+ }
216
+
217
+
218
+ /**
219
+ * Returns all networks that are set in every location panel
220
+ *
221
+ * @return array;
222
+ *
223
+ */
224
+ function dpsp_get_active_networks() {
225
+
226
+ $locations = dpsp_get_network_locations();
227
+ $networks = array();
228
+
229
+ foreach( $locations as $location ) {
230
+
231
+ $location_settings = get_option( 'dpsp_location_' . $location, array() );
232
+
233
+ if( isset( $location_settings['networks'] ) && !empty( $location_settings['networks'] ) ) {
234
+ foreach( $location_settings['networks'] as $network_slug => $network ) {
235
+
236
+ if( !in_array( $network_slug, $networks ) )
237
+ $networks[] = $network_slug;
238
+
239
+ }
240
+ }
241
+
242
+ }
243
+
244
+ return $networks;
245
+
246
+ }
247
+
248
+
249
+ /**
250
+ * Return an array of registered post types slugs and names
251
+ *
252
+ * @return array
253
+ *
254
+ */
255
+ function dpsp_get_post_types() {
256
+
257
+ // Get default and custom post types
258
+ $default_post_types = array( 'post', 'page' );
259
+ $custom_post_types = get_post_types( array( 'public' => true, '_builtin' => false ) );
260
+ $post_types = array_merge( $default_post_types, $custom_post_types );
261
+
262
+ // The array we wish to return
263
+ $return_post_types = array();
264
+
265
+ foreach( $post_types as $post_type ) {
266
+ $post_type_object = get_post_type_object( $post_type );
267
+
268
+ $return_post_types[$post_type] = $post_type_object->labels->singular_name;
269
+ }
270
+
271
+ return apply_filters( 'dpsp_get_post_types', $return_post_types );
272
+
273
+ }
274
+
275
+
276
+ /**
277
+ * Returns the post types that are active for all locations
278
+ *
279
+ */
280
+ function dpsp_get_active_post_types() {
281
+
282
+ $locations = dpsp_get_network_locations();
283
+ $post_types = array();
284
+
285
+ foreach( $locations as $location ) {
286
+
287
+ $location_settings = get_option( 'dpsp_location_' . $location, array() );
288
+
289
+ if( isset( $location_settings['active'] ) && !empty( $location_settings['post_type_display'] ) )
290
+ $post_types = array_merge( $post_types, $location_settings['post_type_display'] );
291
+
292
+ }
293
+
294
+ $post_types = array_unique( $post_types );
295
+
296
+ return $post_types;
297
+
298
+ }
299
+
300
+
301
+ /**
302
+ * Returns the saved option, but replaces the saved social network
303
+ * data with simple data to display in the back-end
304
+ *
305
+ * @param string $option_name
306
+ *
307
+ */
308
+ function dpsp_get_back_end_display_option( $option_name ) {
309
+
310
+ $settings = get_option($option_name);
311
+ $networks = dpsp_get_networks();
312
+
313
+ $settings_networks_count = count($settings['networks']);
314
+
315
+ if( $settings_networks_count > 2 ) {
316
+
317
+ $current_network = 0;
318
+ foreach( $settings['networks'] as $network_slug => $network ) {
319
+
320
+ if( $current_network > 2 ) {
321
+ unset( $settings['networks'][$network_slug] );
322
+ } else {
323
+ $settings['networks'][$network_slug] = array( 'label' => $networks[$network_slug] );
324
+ }
325
+
326
+ $current_network++;
327
+ }
328
+
329
+ } else {
330
+ $settings['networks'] = array(
331
+ 'facebook' => array( 'label' => 'Facebook' ),
332
+ 'twitter' => array( 'label' => 'Twitter' ),
333
+ 'pinterest' => array( 'label' => 'Pinterest' )
334
+ );
335
+ }
336
+
337
+
338
+ //Unset certain options
339
+ unset( $settings['display']['show_count'] );
340
+
341
+ return $settings;
342
+
343
+ }
344
+
345
+
346
+ /**
347
+ * Returns the share link for a social network given the network slug
348
+ *
349
+ * @param string $network_slug
350
+ * @param string $post_url
351
+ * @param string $post_title
352
+ *
353
+ * return string
354
+ *
355
+ */
356
+ function dpsp_get_network_share_link( $network_slug, $post_url = null, $post_title = null ) {
357
+
358
+ if( !isset( $network_slug ) )
359
+ return '';
360
+
361
+ if( is_null( $post_url ) )
362
+ $post_url = rawurlencode( esc_url( dpsp_get_post_url() ) );
363
+
364
+ if( is_null( $post_title ) )
365
+ $post_title = rawurlencode( dpsp_get_post_title() );
366
+
367
+
368
+ switch( $network_slug ) {
369
+
370
+ case 'facebook':
371
+ return sprintf( 'https://www.facebook.com/sharer/sharer.php?u=%1$s&t=%2$s', $post_url, $post_title );
372
+ break;
373
+
374
+ case 'twitter':
375
+ $settings = get_option( 'dpsp_settings' );
376
+
377
+ $via = ( !empty( $settings['twitter_username'] ) && !empty( $settings['tweets_have_username'] ) ) ? '&via=' . $settings['twitter_username'] : '';
378
+
379
+ return sprintf( 'https://twitter.com/intent/tweet?text=%2$s&url=%1$s%3$s', $post_url, $post_title, $via );
380
+ break;
381
+
382
+ case 'google-plus':
383
+ return sprintf( 'https://plus.google.com/share?url=%1$s', $post_url );
384
+ break;
385
+
386
+ case 'pinterest':
387
+ return '#';
388
+ break;
389
+
390
+ case 'linkedin':
391
+ return sprintf( 'https://www.linkedin.com/shareArticle?url=%1$s&title=%2$s&mini=true', $post_url, $post_title );
392
+ break;
393
+
394
+ case 'email':
395
+ return sprintf( 'mailto:?subject=%1$s&amp;body=%2$s', $post_title, $post_url );
396
+ break;
397
+
398
+ case 'print':
399
+ return '#';
400
+ break;
401
+
402
+ default:
403
+ return '';
404
+ break;
405
+ }
406
+
407
+ }
408
+
409
+
410
+ /*
411
+ * Function that adds the initial options and settings
412
+ *
413
+ */
414
+ function dpsp_default_settings() {
415
+
416
+ /*
417
+ * Add default settings for each share buttons location
418
+ */
419
+ $locations = dpsp_get_network_locations();
420
+
421
+ foreach( $locations as $location ) {
422
+
423
+ $location_settings = get_option( 'dpsp_location_' . $location, array() );
424
+
425
+ if( !empty( $location_settings ) )
426
+ continue;
427
+
428
+ // General settings for all locations
429
+ $location_settings = array(
430
+ 'active' => 1,
431
+ 'networks' => array(
432
+ 'facebook' => array( 'label' => 'Facebook' ),
433
+ 'twitter' => array( 'label' => 'Twitter' ),
434
+ 'pinterest' => array( 'label' => 'Pinterest')
435
+ ),
436
+ 'button_style' => 1,
437
+ 'display' => array(
438
+ 'shape' => 'rounded',
439
+ 'icon_animation' => 'yes',
440
+ 'show_count_total' => 'yes'
441
+ ),
442
+ 'post_type_display' => array( 'post' )
443
+ );
444
+
445
+ // Individual settings per location
446
+ switch( $location ) {
447
+
448
+ case 'sidebar':
449
+ $location_settings['display']['position'] = 'left';
450
+ break;
451
+
452
+ case 'content':
453
+ $location_settings['networks'] = array(
454
+ 'facebook' => array( 'label' => 'Share' ),
455
+ 'twitter' => array( 'label' => 'Tweet' ),
456
+ 'pinterest' => array( 'label' => 'Pin')
457
+ );
458
+ $location_settings['display']['position'] = 'top';
459
+ $location_settings['display']['column_count'] = '3';
460
+ $location_settings['display']['show_labels'] = 'yes';
461
+ $location_settings['display']['spacing'] = 'yes';
462
+ $location_settings['display']['total_count_position'] = 'after';
463
+ break;
464
+
465
+ }
466
+
467
+ // Update option with values
468
+ update_option( 'dpsp_location_' . $location, $location_settings );
469
+
470
+ }
471
+
472
+ }
473
+
474
+
475
+ /**
476
+ * Because certain widgets / plugins reset the global $post variable
477
+ * we are going to cache it when WP has just loaded, so that we have the
478
+ * original post available at all times
479
+ *
480
+ */
481
+ function dpsp_cache_post_object() {
482
+
483
+ global $dpsp_cache_wp_post;
484
+
485
+ $dpsp_cache_wp_post = null;
486
+
487
+ if( is_singular() && ! is_front_page() && ! is_home() ) {
488
+
489
+ global $post;
490
+ $dpsp_cache_wp_post = $post;
491
+
492
+ }
493
+
494
+ }
495
+ add_action( 'wp', 'dpsp_cache_post_object' );
496
+
497
+
498
+ /**
499
+ * Returns the current post object
500
+ *
501
+ * @return mixed - WP_Post | null
502
+ *
503
+ */
504
+ function dpsp_get_current_post() {
505
+
506
+ global $dpsp_cache_wp_post;
507
+
508
+ if( ! is_null( $dpsp_cache_wp_post ) )
509
+ return $dpsp_cache_wp_post;
510
+
511
+ global $post;
512
+
513
+ if( ! is_null( $post ) )
514
+ return $post;
515
+
516
+ return null;
517
+
518
+ }
519
+
520
+
521
+ /*
522
+ * Returns the url of the current post
523
+ *
524
+ * @return string
525
+ *
526
+ */
527
+ function dpsp_get_post_url() {
528
+
529
+ global $post;
530
+
531
+ $post_url = get_permalink( $post );
532
+
533
+ return apply_filters( 'dpsp_get_post_url', $post_url, $post->ID );
534
+
535
+ }
536
+
537
+
538
+ /*
539
+ * Returns the title of the current post
540
+ *
541
+ * @return string
542
+ *
543
+ */
544
+ function dpsp_get_post_title() {
545
+
546
+ global $post;
547
+
548
+ $post_title = $post->post_title;
549
+
550
+ return apply_filters( 'dpsp_get_post_title', $post_title, $post->ID );
551
+
552
+ }
553
+
554
+
555
+ /*
556
+ * Returns the a description for the current post
557
+ *
558
+ * @return string
559
+ *
560
+ */
561
+ function dpsp_get_post_description() {
562
+
563
+ global $post;
564
+
565
+ if( !empty( $post->post_excerpt ) )
566
+
567
+ $post_description = $post->post_excerpt;
568
+
569
+ elseif( !empty( $post->post_content ) ) {
570
+
571
+ $post_description = strip_shortcodes( $post->post_content );
572
+ $post_description = wp_trim_words( $post_description, apply_filters( 'dpsp_post_description_length', 15 ), '' );
573
+
574
+ } else
575
+ $post_description = '';
576
+
577
+
578
+ return apply_filters( 'dpsp_get_post_description', $post_description, $post->ID );
579
+
580
+ }
581
+
582
+
583
+ /*
584
+ * Returns the featured image src for the current post
585
+ *
586
+ * @return string
587
+ *
588
+ */
589
+ function dpsp_get_post_image_url() {
590
+
591
+ global $post;
592
+
593
+ $post_thumbnail_id = get_post_thumbnail_id( $post->ID );
594
+
595
+ $post_thumbnail_data = wp_get_attachment_image_src( $post_thumbnail_id, 'large' );
596
+
597
+ return apply_filters( 'dpsp_get_post_image_url', $post_thumbnail_data[0], $post->ID );
598
+
599
+ }
600
+
601
+
602
+ /**
603
+ * Removes the script tags from the values of an array recursivelly
604
+ *
605
+ * @param array $array
606
+ *
607
+ * @return array
608
+ *
609
+ */
610
+ function dpsp_array_strip_script_tags( $array = array() ) {
611
+
612
+ if( empty( $array ) || ! is_array( $array ) )
613
+ return array();
614
+
615
+ foreach( $array as $key => $value ) {
616
+
617
+ if( is_array( $value ) )
618
+ $array[$key] = dpsp_array_strip_script_tags( $value );
619
+
620
+ else
621
+ $array[$key] = preg_replace( '@<(script)[^>]*?>.*?</\\1>@si', '', $value );
622
+
623
+ }
624
+
625
+ return $array;
626
+
627
+ }
index.php ADDED
@@ -0,0 +1,335 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Plugin Name: Grow by Mediavine
4
+ * Plugin URI: https://marketplace.mediavine.com/grow-social-pro/
5
+ * Description: Add beautiful social sharing buttons to your posts, pages and custom post types.
6
+ * Version: 1.7.0
7
+ * Author: Mediavine
8
+ * Author URI: https://marketplace.mediavine.com/
9
+ * Text Domain: social-pug
10
+ * Domain Path: /translations/
11
+ * License: GPL2
12
+ *
13
+ * == Copyright ==
14
+ * Copyright 2016 Mediavine (www.mediavine.com)
15
+ *
16
+ * This program is free software; you can redistribute it and/or modify
17
+ * it under the terms of the GNU General Public License as published by
18
+ * the Free Software Foundation; either version 2 of the License, or
19
+ * (at your option) any later version.
20
+ * This program is distributed in the hope that it will be useful,
21
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
22
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23
+ * GNU General Public License for more details.
24
+ * You should have received a copy of the GNU General Public License
25
+ * along with this program; if not, write to the Free Software
26
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
27
+ */
28
+
29
+
30
+ Class Social_Pug {
31
+
32
+
33
+ /*
34
+ * The Constructor
35
+ *
36
+ */
37
+ public function __construct() {
38
+
39
+ // Defining constants
40
+ define('DPSP_VERSION', '1.7.0');
41
+ define('DPSP_PLUGIN_DIR', WP_PLUGIN_DIR . '/' . dirname( plugin_basename(__FILE__) ) );
42
+ define('DPSP_PLUGIN_DIR_URL', plugin_dir_url( __FILE__ ) );
43
+ define('DPSP_TRANSLATION_DIR', DPSP_PLUGIN_DIR . '/translations' );
44
+ define('DPSP_TRANSLATION_TEXTDOMAIN', 'social-pug' );
45
+
46
+ // Hooks
47
+ add_action( 'init', array( $this, 'init_translation' ) );
48
+ add_action( 'admin_menu', array( $this, 'add_main_menu_page' ), 10 );
49
+ add_action( 'admin_menu', array( $this, 'remove_main_menu_page' ), 11 );
50
+ add_action( 'admin_enqueue_scripts', array( $this, 'init_admin_scripts' ) );
51
+ add_action( 'wp_enqueue_scripts', array( $this, 'init_front_end_scripts' ) );
52
+ add_action( 'admin_init', array( $this, 'update_database' ) );
53
+
54
+ add_filter( 'admin_footer_text', array( $this, 'admin_footer_text' ) );
55
+ add_filter( 'plugin_action_links_' . plugin_basename(__FILE__), array( $this, 'add_plugin_action_links' ) );
56
+
57
+ $this->load_resources_front_end();
58
+
59
+ add_action( 'init', array( $this, 'load_resources_admin' ) );
60
+
61
+ }
62
+
63
+
64
+ /*
65
+ * Loads the translations files if they exist
66
+ *
67
+ */
68
+ public function init_translation() {
69
+
70
+ load_plugin_textdomain( 'social-pug', false, DPSP_TRANSLATION_DIR );
71
+
72
+ }
73
+
74
+
75
+ /*
76
+ * Add the main menu page
77
+ *
78
+ */
79
+ public function add_main_menu_page() {
80
+ add_menu_page( __('Grow', 'social-pug'), __('Grow', 'social-pug'), 'manage_options', 'dpsp-social-pug', '','data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDI0LjAuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHZlcnNpb249IjEuMSIgaWQ9IkxheWVyXzEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4IgoJIHZpZXdCb3g9IjAgMCAyMCAyMCIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAgMjAgMjA7IiB4bWw6c3BhY2U9InByZXNlcnZlIj4KPHN0eWxlIHR5cGU9InRleHQvY3NzIj4KCS5zdDB7ZmlsbDojMjMxRjIwO30KPC9zdHlsZT4KPGc+Cgk8cGF0aCBjbGFzcz0ic3QwIiBkPSJNMC4wOSw3LjE1Yy0wLjAzLDAuMTktMC42Niw0Ljc0LDEuODksNy4yOWMxLjcsMS43MSw0LjMsMi4wMSw1Ljg5LDIuMDFjMC4zNywwLDAuNjgtMC4wMiwwLjkyLTAuMDMKCQljLTAuNDctMC4xNS0xLjM1LTAuNDYtMi4zLTAuOTlDNS43MSwxNSw1LjAyLDE0LjUsNC40NSwxMy45NmMtMC43Mi0wLjY5LTEuMjYtMS40NS0xLjYtMi4yN0MyLjQ5LDEwLjgxLDIuMzQsOS44MiwyLjQsOC43NQoJCWMwLjA0LTAuNzksMC4yLTEuNjMsMC40OC0yLjVjLTAuMi0wLjAxLTAuMzktMC4wMS0wLjU3LTAuMDFjLTAuNzksMC0xLjMzLDAuMDctMS4zOSwwLjA4bC0wLjcyLDAuMUwwLjA5LDcuMTV6Ii8+Cgk8cGF0aCBjbGFzcz0ic3QwIiBkPSJNNC42OSwzLjQzTDQuMzIsNC4wNUM0LjI4LDQuMTIsMy44Nyw0LjgyLDMuNDksNS44NGMwLjg3LDAuMDgsMS42NywwLjI1LDIuNCwwLjQ5CgkJQzYuMjMsNS42NSw2LjY4LDQuOTYsNy4yNCw0LjNDNi4yNiwzLjg0LDUuNDgsMy42Myw1LjQsMy42MUw0LjY5LDMuNDN6Ii8+Cgk8cGF0aCBjbGFzcz0ic3QwIiBkPSJNMy4yNywxMS41MWMxLjEzLDIuNzUsNC4zNCw0LjA0LDUuNTQsNC40M2MtMC4xMi0wLjEtMC4yOC0wLjI0LTAuNDYtMC40Yy0wLjEzLTAuMTItMC4yOC0wLjI3LTAuNDMtMC40MgoJCWMtMC4yNy0wLjI3LTAuNTYtMC41OS0wLjg1LTAuOTZjLTAuNTYtMC43LTEuMDEtMS40Mi0xLjMzLTIuMTRjLTAuNC0wLjkxLTAuNjEtMS44Mi0wLjYtMi43MWMwLTAuNywwLjEzLTEuNDIsMC4zOS0yLjEzCgkJYzAuMDMtMC4wNywwLjA1LTAuMTQsMC4wOC0wLjIxQzUuNjQsNi44OSw1LjY3LDYuODIsNS43LDYuNzVDNS4wNSw2LjU0LDQuNCw2LjQxLDMuNzksNi4zM0MzLjcyLDYuMzIsMy42NCw2LjMxLDMuNTcsNi4zMQoJCUMzLjQ5LDYuMywzLjQyLDYuMjksMy4zNCw2LjI4QzMuMzIsNi4zNiwzLjMsNi40MywzLjI3LDYuNUMzLjI1LDYuNTcsMy4yMyw2LjY1LDMuMjEsNi43MkMyLjgxLDguMTMsMi42MSw5Ljg5LDMuMjcsMTEuNTF6Ii8+Cgk8cGF0aCBjbGFzcz0ic3QwIiBkPSJNMTAuNTksMi44MmwtMC41OC0wLjQ0TDkuNDIsMi44MkM5LjM2LDIuODcsOC43MiwzLjM1LDcuOTgsNC4xNUM4Ljc0LDQuNTYsOS40Miw1LjAyLDEwLDUuNTMKCQljMC41OC0wLjUxLDEuMjYtMC45NiwyLjAzLTEuMzZDMTEuMjksMy4zNiwxMC42NSwyLjg3LDEwLjU5LDIuODJ6Ii8+Cgk8cGF0aCBjbGFzcz0ic3QwIiBkPSJNNi41Myw2LjU5QzYuNiw2LjYyLDYuNjcsNi42NSw2Ljc0LDYuNjhDNy4zMiw2Ljk2LDcuODQsNy4zLDguMjksNy43MWMwLjI2LTAuNTQsMC42MS0xLjA2LDEuMDUtMS41NAoJCUM5LjM5LDYuMTEsOS40NSw2LjA1LDkuNSw2QzkuNTUsNS45NCw5LjYsNS44OSw5LjY2LDUuODRDOS4xNSw1LjM5LDguNiw1LjAyLDguMDcsNC43MkM4LDQuNjgsNy45Myw0LjY1LDcuODcsNC42MQoJCUM3LjgsNC41Nyw3LjczLDQuNTQsNy42Niw0LjVjLTAuMDUsMC4wNi0wLjEsMC4xMi0wLjE1LDAuMTdDNy40Nyw0Ljc0LDcuNDIsNC44LDcuMzgsNC44NkM3LDUuMzQsNi42Miw1Ljg5LDYuMzIsNi41CgkJQzYuMzksNi41Myw2LjQ2LDYuNTUsNi41Myw2LjU5eiIvPgoJPHBhdGggY2xhc3M9InN0MCIgZD0iTTYuMDQsNy4xMkM2LjAxLDcuMTksNS45OSw3LjI2LDUuOTYsNy4zM2MwLDAsMCwwLDAsMEM1Ljc0LDcuOTUsNS42LDguNjIsNS42LDkuMzEKCQljLTAuMDEsMi45NiwyLjQ0LDUuMzYsMy40MSw2LjJjLTAuMDctMC4xNS0wLjE3LTAuMzMtMC4yNy0wLjU1Yy0wLjA4LTAuMTctMC4xNi0wLjM1LTAuMjQtMC41NmMtMC4xMi0wLjMxLTAuMjUtMC42Ni0wLjM2LTEuMDQKCQljLTAuMjUtMC44MS0wLjQtMS42MS0wLjQ0LTIuMzZjLTAuMDUtMC44NSwwLjAzLTEuNjQsMC4yNC0yLjM3YzAuMDItMC4wOCwwLjA1LTAuMTcsMC4wOC0wLjI1YzAsMCwwLTAuMDEsMC0wLjAxCgkJQzguMDQsOC4zLDguMDcsOC4yMiw4LjEsOC4xNWMtMC40Ny0wLjQ1LTEtMC43OS0xLjU2LTEuMDZjMCwwLDAsMCwwLDBDNi40Nyw3LjA2LDYuNDEsNy4wMyw2LjM0LDdjMCwwLDAsMCwwLDAKCQlDNi4yNyw2Ljk3LDYuMiw2Ljk0LDYuMTMsNi45MUM2LjEsNi45OCw2LjA3LDcuMDUsNi4wNCw3LjEyQzYuMDQsNy4xMiw2LjA0LDcuMTIsNi4wNCw3LjEyeiIvPgoJPHBhdGggY2xhc3M9InN0MCIgZD0iTTE1LjMxLDMuNDVMMTQuNiwzLjYzYy0wLjA4LDAuMDItMC44NSwwLjIyLTEuODQsMC42OGMwLjU1LDAuNjYsMC45OSwxLjMzLDEuMzMsMi4wMQoJCWMwLjE3LTAuMDYsMC4zNC0wLjExLDAuNTEtMC4xNmMwLjU5LTAuMTYsMS4yMi0wLjI3LDEuODgtMC4zM2MtMC4zNy0xLjAxLTAuNzYtMS42OS0wLjgtMS43NkwxNS4zMSwzLjQ1eiIvPgoJPHBhdGggY2xhc3M9InN0MCIgZD0iTTEzLjQ1LDYuNTdjMC4wNy0wLjAzLDAuMTQtMC4wNiwwLjIxLTAuMDljLTAuMy0wLjYtMC42Ni0xLjE0LTEuMDMtMS42MWMtMC4wNS0wLjA2LTAuMDktMC4xMi0wLjE0LTAuMTgKCQljLTAuMDUtMC4wNi0wLjEtMC4xMi0wLjE1LTAuMThjLTAuMDcsMC4wMy0wLjEzLDAuMDctMC4yLDAuMTFjLTAuMDcsMC4wNC0wLjEzLDAuMDctMC4yLDAuMTFjLTAuNTMsMC4zLTEuMDksMC42Ny0xLjYxLDEuMTEKCQljMC4wNSwwLjA1LDAuMTEsMC4xMSwwLjE2LDAuMTZjMC4wNSwwLjA2LDAuMSwwLjExLDAuMTUsMC4xN2MwLjQyLDAuNDcsMC43NywwLjk4LDEuMDMsMS41MWMwLjQ1LTAuNCwwLjk4LTAuNzQsMS41Ny0xLjAyCgkJQzEzLjMxLDYuNjMsMTMuMzgsNi42LDEzLjQ1LDYuNTd6Ii8+Cgk8cGF0aCBjbGFzcz0ic3QwIiBkPSJNMTAuMzEsNi40OEMxMC4zMSw2LjQ4LDEwLjMxLDYuNDgsMTAuMzEsNi40OGMtMC4wNS0wLjA2LTAuMS0wLjExLTAuMTYtMC4xN2MwLDAsMCwwLDAsMAoJCUMxMC4xLDYuMjUsMTAuMDUsNi4yLDkuOTksNi4xNUM5Ljk0LDYuMiw5Ljg5LDYuMjUsOS44Myw2LjMxYzAsMCwwLDAsMCwwYy0wLjA1LDAuMDUtMC4xLDAuMTEtMC4xNiwwLjE3YzAsMCwwLDAsMCwwCgkJQzkuMjYsNi45Myw4LjksNy40NSw4LjY0LDguMDRDOC42Myw4LjA2LDguNjIsOC4wOCw4LjYxLDguMDljMC4wNywwLjAzLDAuMTMsMC4wNywwLjE4LDAuMTNsMCwwYzAsMCwwLDAsMCwwCgkJYzAsMCwwLjAxLDAuMDEsMC4wMSwwLjAxYzAuMDYsMC4wNiwwLjExLDAuMTMsMC4xNiwwLjJjMC40LDAuNTEsMC43MywxLjA5LDAuOTksMS43NWMwLjI3LTAuNjcsMC42MS0xLjI3LDEuMDMtMS43OQoJCWMwLjA1LTAuMDcsMC4xMS0wLjEzLDAuMTctMC4yYzAuMDYtMC4wNiwwLjExLTAuMTIsMC4xNy0wLjE4QzExLjA2LDcuNDMsMTAuNzEsNi45MiwxMC4zMSw2LjQ4eiIvPgoJPHBhdGggY2xhc3M9InN0MCIgZD0iTTguNzMsOC44N0M4LjcsOC44Miw4LjY2LDguNzgsOC42Miw4LjczQzguNjEsOC43Miw4LjYsOC43LDguNiw4LjY5QzguNTUsOC42Myw4LjUsOC41OCw4LjQ1LDguNTIKCQlDOC40Myw4LjU5LDguNCw4LjY2LDguMzgsOC43M2MwLDAuMDEtMC4wMSwwLjAzLTAuMDEsMC4wNEM4LjM1LDguODQsOC4zNCw4LjksOC4zMiw4Ljk2QzguMzEsOC45OSw4LjMxLDkuMDIsOC4zLDkuMDUKCQljLTAuNTcsMi40NCwwLjQ5LDUsMS4wMiw2LjA3Yy0wLjAxLTAuMTctMC4wMy0wLjM4LTAuMDMtMC42MWMtMC4wMS0wLjE5LTAuMDEtMC4zOSwwLTAuNjFjMC4wMS0wLjM0LDAuMDItMC43MiwwLjA3LTEuMTIKCQljMC4wNC0wLjM0LDAuMDgtMC42NywwLjE1LTAuOThjMC4wMy0wLjE3LDAuMDctMC4zNCwwLjExLTAuNTFjMC4wNC0wLjE0LDAuMDctMC4yOCwwLjExLTAuNDJjLTAuMjEtMC42Ni0wLjUxLTEuMzItMC45My0xLjkxCgkJQzguNzcsOC45Myw4Ljc1LDguOSw4LjczLDguODd6Ii8+Cgk8cGF0aCBjbGFzcz0ic3QwIiBkPSJNMTcuMDksNi4yNmMtMC4wNywwLTAuMTUsMC4wMS0wLjIzLDAuMDFjLTAuMDgsMC0wLjE1LDAuMDEtMC4yMywwLjAyYy0wLjcyLDAuMDYtMS41NCwwLjE5LTIuMzUsMC40NgoJCWMtMC4wNywwLjAyLTAuMTQsMC4wNS0wLjIyLDAuMDdjLTAuMDcsMC4wMy0wLjE0LDAuMDUtMC4yMSwwLjA4Yy0wLjA3LDAuMDMtMC4xNCwwLjA2LTAuMjEsMC4wOWMtMC4wNywwLjAzLTAuMTQsMC4wNi0wLjIxLDAuMDkKCQljLTAuNTYsMC4yNi0xLjEsMC42LTEuNTcsMS4wNGMtMC4wNSwwLjA1LTAuMTEsMC4xLTAuMTYsMC4xNWMtMC4wMSwwLjAxLTAuMDEsMC4wMS0wLjAyLDAuMDJjLTAuMDYsMC4wNi0wLjEyLDAuMTItMC4xOCwwLjE5CgkJYy0wLjA2LDAuMDctMC4xMSwwLjEzLTAuMTcsMC4yYy0wLjA1LDAuMDYtMC4xLDAuMTMtMC4xNSwwLjE5Yy0wLjQ2LDAuNjItMC43NywxLjMtMC45OSwyYy0wLjA0LDAuMTQtMC4wOCwwLjI4LTAuMTIsMC40MgoJCWMtMC4wMywwLjEyLTAuMDYsMC4yMy0wLjA4LDAuMzVjLTAuMDEsMC4wNS0wLjAyLDAuMTEtMC4wMywwLjE2Yy0wLjAxLDAuMDMtMC4wMSwwLjA1LTAuMDIsMC4wOGMtMC4wMywwLjEzLTAuMDUsMC4yNi0wLjA3LDAuNAoJCWMtMC4wMSwwLjA4LTAuMDIsMC4xNi0wLjAzLDAuMjRDOS43LDEzLjUzLDkuNzMsMTQuNDQsOS43NywxNWMwLjAyLDAuMzIsMC4wNSwwLjUzLDAuMDYsMC41OGMwLDAsMCwwLDAsMGMwLDAsMCwwLDAsMC4wMQoJCWwwLjAyLDAuMTdsMC4wMiwwLjE0bDAuMDEsMC4xbDAuMDMsMC4xOGwwLjAxLDAuMDRsMCwwLjAybDAsMC4wMmwwLjAxLDAuMDVsMC4xMiwwLjAybDAuMSwwLjAxbDAuMDEsMGwwLjAyLDBsMC4wMSwwbDAuMTgsMC4wMwoJCWwwLjAxLDBsMC4wMSwwbDAuMDIsMGwwLDBsMC4yNCwwLjAzYzAuMDYsMC4wMSwwLjU5LDAuMDgsMS4zNiwwLjA4YzEuNTksMCw0LjIzLTAuMyw1Ljk0LTIuMDNjMi41NS0yLjU3LDEuOS03LjEzLDEuODgtNy4zMgoJCWwtMC4xMS0wLjcybC0wLjczLTAuMWMtMC4wNi0wLjAxLTAuNTktMC4wOC0xLjM2LTAuMDhDMTcuNDcsNi4yNCwxNy4yOSw2LjI1LDE3LjA5LDYuMjZ6IE0xNi41NywxMy4xCgkJYy0xLjIyLDEuMjQtMy4yNywxLjQ1LTQuNTQsMS40NWMtMC4xMiwwLTAuMjQsMC0wLjM0LTAuMDFjLTAuMDYtMS4zNiwwLjE0LTMuNjIsMS40LTQuODljMS4yMi0xLjI0LDMuMjctMS40NSw0LjU0LTEuNDUKCQljMC4xMiwwLDAuMjMsMCwwLjM0LDAuMDFDMTguMDIsOS40MSwxNy45MSwxMS43NCwxNi41NywxMy4xeiIvPgo8L2c+Cjwvc3ZnPgo=' );
81
+ }
82
+
83
+
84
+ /*
85
+ * Remove the main menu page as we will rely only on submenu pages
86
+ *
87
+ */
88
+ public function remove_main_menu_page() {
89
+
90
+ remove_submenu_page( 'dpsp-social-pug', 'dpsp-social-pug' );
91
+
92
+ }
93
+
94
+
95
+ /*
96
+ * Enqueue scripts and styles for the admin dashboard
97
+ *
98
+ */
99
+ public function init_admin_scripts( $hook ) {
100
+
101
+ // TODO: Replace this with .env check.
102
+ $VERSION = '1.0.0';
103
+
104
+ if( strpos( $hook, 'dpsp' ) !== false ) {
105
+ wp_register_script( 'select2-js', 'https://cdnjs.cloudflare.com/ajax/libs/select2/4.0.1/js/select2.min.js', array( 'jquery' ) );
106
+ wp_enqueue_script( 'select2-js' );
107
+
108
+ wp_register_style( 'select2-css', 'https://cdnjs.cloudflare.com/ajax/libs/select2/4.0.1/css/select2.min.css' );
109
+ wp_enqueue_style( 'select2-css' );
110
+
111
+ wp_register_script( 'dpsp-touch-punch-js' , plugin_dir_url( __FILE__ ) . "assets/dist/jquery.ui.touch-punch.min.$VERSION.js", array('jquery-ui-sortable', 'jquery' ) );
112
+ wp_enqueue_script( 'dpsp-touch-punch-js' );
113
+ }
114
+
115
+ wp_register_style( 'dpsp-dashboard-style', plugin_dir_url( __FILE__ ) . "assets/dist/style-dashboard.$VERSION.css", array(), DPSP_VERSION );
116
+ wp_enqueue_style( 'dpsp-dashboard-style' );
117
+
118
+ wp_register_script( 'dpsp-dashboard-js' , plugin_dir_url( __FILE__ ) . "assets/dist/dashboard.$VERSION.js", array( 'jquery' ), DPSP_VERSION );
119
+ wp_enqueue_script( 'dpsp-dashboard-js' );
120
+
121
+ wp_register_style( 'dpsp-frontend-style', plugin_dir_url( __FILE__ ) . "assets/dist/style-frontend.$VERSION.css", array(), DPSP_VERSION );
122
+ wp_enqueue_style( 'dpsp-frontend-style' );
123
+
124
+ /**
125
+ * Enqueue additional admin scripts
126
+ *
127
+ */
128
+ do_action( 'dpsp_enqueue_admin_scripts' );
129
+
130
+ }
131
+
132
+
133
+ /*
134
+ * Enqueue scripts for the front-end
135
+ *
136
+ */
137
+ public function init_front_end_scripts() {
138
+
139
+ // TODO: Replace this with Mediavine Development Plugin stuff.
140
+ $IS_DEVELOPMENT = false;
141
+
142
+ // TODO: Replace this with .env check.
143
+ $VERSION = "1.0.0";
144
+
145
+ $settings = get_option('dpsp_settings');
146
+
147
+ if ( $IS_DEVELOPMENT ) {
148
+
149
+ if( isset($settings['optimize_javascript']) && $settings['optimize_javascript'] ) {
150
+ wp_register_style( 'mv-grow-frontend-style', plugin_dir_url( __FILE__ ) . "assets/dist/dev-entry.css" );
151
+ wp_enqueue_style( 'mv-grow-frontend-style' );
152
+
153
+ wp_register_script( 'mv-grow-frontend-bundled-js', plugin_dir_url( __FILE__ ) . 'assets/dist/dev-entry.js', array(), null, true );
154
+ wp_enqueue_script( 'mv-grow-frontend-bundled-js' );
155
+ } else {
156
+ wp_register_style( 'mv-grow-frontend-style', plugin_dir_url( __FILE__ ) . "assets/dist/dev-entry-jquery.css" );
157
+ wp_enqueue_style( 'mv-grow-frontend-style' );
158
+
159
+ wp_register_script( 'mv-grow-frontend-bundled-js', plugin_dir_url( __FILE__ ) . 'assets/dist/dev-entry-jquery.js', array('jquery'), null, true );
160
+ wp_enqueue_script( 'mv-grow-frontend-bundled-js' );
161
+ }
162
+ } else {
163
+ if( isset($settings['optimize_javascript']) && $settings['optimize_javascript'] ) {
164
+ wp_register_style( 'mv-grow-frontend-style', plugin_dir_url( __FILE__ ) . "assets/dist/style-frontend.$VERSION.css" );
165
+ wp_enqueue_style( 'mv-grow-frontend-style' );
166
+
167
+ wp_register_script( 'mv-grow-frontend-js', plugin_dir_url( __FILE__ ) . "assets/dist/front-end.$VERSION.js", array(), null, true);
168
+ wp_enqueue_script( 'mv-grow-frontend-js' );
169
+ } else {
170
+ wp_register_style( 'mv-grow-frontend-style', plugin_dir_url( __FILE__ ) . "assets/dist/style-frontend-jquery.$VERSION.css" );
171
+ wp_enqueue_style( 'mv-grow-frontend-style' );
172
+
173
+ wp_register_script( 'mv-grow-frontend-js', plugin_dir_url( __FILE__ ) . "assets/dist/front-end-jquery.$VERSION.js", array('jquery'), null, true );
174
+ wp_enqueue_script( 'mv-grow-frontend-js' );
175
+ }
176
+ }
177
+
178
+
179
+ }
180
+
181
+
182
+ /*
183
+ * Fallback for setting defaults when updating the plugin,
184
+ * as register_activation_hook does not fire for automatic updates
185
+ *
186
+ */
187
+ public function update_database() {
188
+
189
+ $dpsp_db_version = get_option( 'dpsp_version', '' );
190
+
191
+ if( $dpsp_db_version != DPSP_VERSION ) {
192
+
193
+ // Update default settings
194
+ dpsp_default_settings();
195
+ update_option( 'dpsp_version', DPSP_VERSION );
196
+
197
+ // Add first time activation
198
+ if( get_option( 'dpsp_first_activation', '' ) == '' )
199
+ update_option( 'dpsp_first_activation', time() );
200
+ else
201
+ update_option( 'dpsp_welcome_screen_got_it', 1 );
202
+
203
+ /**
204
+ * Do extra database updates on plugin update
205
+ *
206
+ * @param string $dpsp_db_version - the previous version of the plugin
207
+ * @param string DPSP_VERSION - the new (current) version of the plugin
208
+ *
209
+ */
210
+ do_action( 'dpsp_update_database', $dpsp_db_version, DPSP_VERSION );
211
+
212
+ }
213
+
214
+ }
215
+
216
+
217
+ /*
218
+ * Replace admin footer text with a rate plugin message
219
+ *
220
+ */
221
+ public function admin_footer_text( $text ) {
222
+
223
+ if( isset( $_GET['page'] ) && strpos( $_GET['page'], 'dpsp' ) !== false ) {
224
+ return sprintf( __( 'If you enjoy using <strong>Grow by Mediavine</strong>, please <a href="%s" target="_blank">leave us a ★★★★★ rating</a>. Big thank you for this!', 'social-pug' ), 'https://wordpress.org/support/view/plugin-reviews/social-pug?rate=5#postform' );
225
+ }
226
+
227
+ return $text;
228
+
229
+ }
230
+
231
+
232
+ /*
233
+ * Add extra action links in the plugins page
234
+ *
235
+ */
236
+ public function add_plugin_action_links( $links ) {
237
+
238
+ $links[] = '<a href="' . esc_url( get_admin_url( null, 'admin.php?page=dpsp-toolkit' ) ) . '">' . __( 'Settings', 'social-pug' ) . '</a>';
239
+
240
+ return $links;
241
+
242
+ }
243
+
244
+
245
+ /*
246
+ * Include plugin files for the front-end
247
+ *
248
+ */
249
+ public function load_resources_front_end() {
250
+
251
+ // Database version update file
252
+ if( file_exists( DPSP_PLUGIN_DIR . '/inc/functions-version-update.php' ) )
253
+ include_once( DPSP_PLUGIN_DIR . '/inc/functions-version-update.php' );
254
+
255
+ // Functions
256
+ if( file_exists( DPSP_PLUGIN_DIR . '/inc/functions.php' ) )
257
+ include_once( DPSP_PLUGIN_DIR . '/inc/functions.php' );
258
+
259
+ // Share counts functions
260
+ if( file_exists( DPSP_PLUGIN_DIR . '/inc/functions-share-counts.php' ) )
261
+ include_once( DPSP_PLUGIN_DIR . '/inc/functions-share-counts.php' );
262
+
263
+ // Cron jobs
264
+ if( file_exists( DPSP_PLUGIN_DIR . '/inc/functions-cron.php' ) )
265
+ include_once( DPSP_PLUGIN_DIR . '/inc/functions-cron.php' );
266
+
267
+ // Frontend rendering
268
+ if( file_exists( DPSP_PLUGIN_DIR . '/inc/functions-frontend.php' ) )
269
+ include_once( DPSP_PLUGIN_DIR . '/inc/functions-frontend.php' );
270
+
271
+ }
272
+
273
+
274
+ /*
275
+ * Include plugin files for the admin area
276
+ *
277
+ */
278
+ public function load_resources_admin() {
279
+
280
+ // Admin functions and pages
281
+ if( file_exists( DPSP_PLUGIN_DIR . '/inc/functions-admin.php' ) )
282
+ include_once( DPSP_PLUGIN_DIR . '/inc/functions-admin.php' );
283
+
284
+ if( file_exists( DPSP_PLUGIN_DIR . '/inc/admin/submenu-page-toolkit.php' ) )
285
+ include_once( DPSP_PLUGIN_DIR . '/inc/admin/submenu-page-toolkit.php' );
286
+
287
+ // Network locations admin pages
288
+ $network_locations = dpsp_get_network_locations();
289
+
290
+ foreach( $network_locations as $location_slug ) {
291
+ if( dpsp_is_location_active( $location_slug ) ) {
292
+ if( file_exists( DPSP_PLUGIN_DIR . '/inc/admin/submenu-page-' . str_replace( '_','-', $location_slug ) . '.php' ) )
293
+ include_once( DPSP_PLUGIN_DIR . '/inc/admin/submenu-page-' . str_replace( '_','-', $location_slug ) . '.php' );
294
+ }
295
+ }
296
+
297
+ if( file_exists( DPSP_PLUGIN_DIR . '/inc/admin/submenu-page-settings.php' ) )
298
+ include_once( DPSP_PLUGIN_DIR . '/inc/admin/submenu-page-settings.php' );
299
+
300
+ if( file_exists( DPSP_PLUGIN_DIR . '/inc/admin/submenu-page-extensions.php' ) )
301
+ include_once( DPSP_PLUGIN_DIR . '/inc/admin/submenu-page-extensions.php' );
302
+
303
+ // Feedback form
304
+ if( file_exists( DPSP_PLUGIN_DIR . '/inc/admin/feedback-form/functions.php' ) )
305
+ include_once( DPSP_PLUGIN_DIR . '/inc/admin/feedback-form/functions.php' );
306
+
307
+ if( file_exists( DPSP_PLUGIN_DIR . '/inc/admin/feedback-form/functions-ajax.php' ) )
308
+ include_once( DPSP_PLUGIN_DIR . '/inc/admin/feedback-form/functions-ajax.php' );
309
+
310
+ // Admin extras
311
+ if( file_exists( DPSP_PLUGIN_DIR . '/inc/admin/admin-metaboxes.php' ) )
312
+ include_once( DPSP_PLUGIN_DIR . '/inc/admin/admin-metaboxes.php' );
313
+
314
+ }
315
+
316
+ }
317
+
318
+ // Let's get the party started
319
+ new Social_Pug;
320
+
321
+
322
+
323
+ /*
324
+ * Activation hooks
325
+ *
326
+ */
327
+ register_activation_hook( __FILE__, 'dpsp_default_settings' );
328
+ register_activation_hook( __FILE__, 'dpsp_set_cron_jobs' );
329
+
330
+
331
+ /*
332
+ * Deactivation hooks
333
+ *
334
+ */
335
+ register_deactivation_hook( __FILE__, 'dpsp_stop_cron_jobs' );
readme.txt ADDED
@@ -0,0 +1,281 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ === Grow by Mediavine ===
2
+ Contributors: Mediavine, iova.mihai
3
+ Tags: social share, social sharing, social sharing buttons, social share buttons, social, social media, social share icon, social share counts, social sharing icon
4
+ Requires at least: 3.1
5
+ Tested up to: 5.3.2
6
+ Stable tag: 1.7.0
7
+ License: GPLv2 or later
8
+ License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
+
10
+ The best social sharing plugin for your WordPress website and the only social sharing plugin you will ever need.
11
+
12
+ == Description ==
13
+ **The Best Looking Social Sharing Buttons**
14
+
15
+ Grow by Mediavine is one of the easies to use social sharing plugin available. It let's you add highly customizable social share buttons that will integrate beautifully with your website's design, leading to increased interactions and social media shares.
16
+
17
+ The free version of the plugin comes with five of the biggest social media platforms, mainly Facebook, Twitter, Google+, Pinterest and LinkedIn.
18
+
19
+ For each social media platform you can customize the social share button to your liking. You can choose to have a simple social media icon share button, a share button with a bold label to catch the eye and even social sharing buttons with social share counts, so that you visitors have social media proof.
20
+
21
+ You can place the social sharing buttons before and after the post content or have them follow your readers as they scroll up and down the page, in the form of a social media floating sidebar.
22
+
23
+ **Social Share Count**: Display the posts social share count **( including Twitter )** to provide social media proof and increase your website's credibility.
24
+
25
+ **Social Share Buttons Locations**: You can place the social sharing buttons in 4 different locations of your website. You can opt in to display them before and/or after the content of your posts on whichever post type you want. Also you can choose to display the social share buttons in a floating sidebar that follows the user as he/she scrolls the page. The floating sidebar can be placed on the left or on the right side of the screen.
26
+
27
+ = Main Features =
28
+ * **Before and After Content Social Share Buttons** - Place the social share buttons right before your content, after your content or both
29
+ * **Floating Sidebar Social Share Buttons** - Make the social share buttons follow the user as he/she scrolls up and down your webpage by adding floating buttons on the left or right side of the screen
30
+ * **Social Share Counts and Total Share Counts** - Display social share counts for all social media networks, including Twitter
31
+ * **Editable Button Labels** - Edit the labels that appear in the share buttons, to maximize your engagement
32
+ * **Retina Ready Sharp Share Icons** - Grow by Mediavine uses an icon font to display the best looking social media icons on any screen
33
+
34
+ = Premium Features =
35
+ * **10+ Social Media Networks more** - Reach more people by adding any of the following social share networks StumbleUpon, Reddit, VK, Yummly, WhatsApp, Buffer, Telegram, Flipboard, Pocket, Tumblr and Email
36
+ * **Mobile Sticky Footer Social Share Buttons** - Your website needs to be mobile ready and Grow by Mediavine is here to help
37
+ * **Pop-Up Social Share Buttons** - Trigger a pop-up with the social sharing buttons when a user does an action
38
+ * **Custom Button Colors and Hover Colors** - The social networks colors are beautiful, but you don't have to limit yourself. Add any color to your social share buttons to match your website's design.
39
+ * **Shortcode for Social Share Buttons** - Place the buttons anywhere in your template files or the body of your content with the [socialpug_share] shortcode
40
+ * **Link Shortening through Bitly** - Hide long URL's behind their shorter version with the Bitly integration
41
+ * **Google Analytics UTM tracking** - Track the source of your incoming traffic with the help of the Google Analytics UTM parameters
42
+ * **Social Media Follow Buttons Widget** - Place social media follow buttons for the following social media networks: Facebook, Twitter, Google+, Pinterest, LinkedIn, Reddit, Instagram, YouTube, Vimeo, SoundCloud, Twitch, Yummly and Behance. Use the [socialpug_follow] shortcode to place the follow buttons anywere in your template files
43
+ * **Sharable Quotes ( Click to Tweet ) Feature** - Let your readers easily share a custom tweet with just one click
44
+ * **Top Social Media Shared Posts Widget** - Want to showcase your most social shared articles? No problem. You can use this widget in any widget area to add your top shared posts
45
+ * **Import / Export Settings** - Move all the settings from one website to another with just a few clicks
46
+
47
+ = Powerful Social Sharing Features =
48
+
49
+ **Social Proof**
50
+ Display social sharing counts for each social media network, for positive social media proof.
51
+
52
+ **Click to Tweet**
53
+ Let your users share your posts on Twitter with just one click.
54
+
55
+ **Social Media Custom Content**
56
+ Customize the social media images and descriptions that your users share on their social media profiles.
57
+
58
+ = Help us Translate =
59
+ We want to reach as many people as possible. Help us translate the plugin in your language and get a 20% discount code for your premium purchases. Contact us here: http://devpups.com/support/
60
+
61
+ = Documentation =
62
+
63
+ http://docs.devpups.com/
64
+
65
+ = Website =
66
+
67
+ https://marketplace.mediavine.com/grow-social-pro/
68
+
69
+ == Installation ==
70
+
71
+ 1. Upload the social-pug folder to the '/wp-content/plugins/' directory
72
+ 1. Activate the plugin through the 'Plugins' menu in WordPress
73
+ 1. Activate each location where you wish the buttons to appear
74
+
75
+
76
+ == Frequently Asked Questions ==
77
+
78
+ = What social sharing buttons are supported? =
79
+
80
+ We currently support Facebook, Twitter, Google+, Pinterest and LinkedIn as social sharing buttons in the free version. The Pro version adds many more social media networks for both social sharing and social follow.
81
+
82
+ = Can I activate tweet count for my Twitter social sharing button? =
83
+
84
+ Twitter has officially removed support for the tweet count of a URL. Luckily a third party application, namely OpenShareCount, has come to provide an alternative solution. Grow by Mediavine has partnered with OpenShareCount to provide social sharing proof for your Twitter social sharing button.
85
+
86
+ = Can I customize the social information that is being shared on social media? =
87
+
88
+ By default Grow by Mediavine will use the post's title and featured image to populate what is being shared on the social platforms. If you wish to have full control on what gets shared when a visitor uses the social sharing buttons, please visit our website and check out Grow by Mediavine premium.
89
+
90
+ = Will your social sharing plugin slow down my website? =
91
+
92
+ No. Grow by Mediavine is a lightweight plugin that was built with efficiency in mind. Unlike other social sharing plugins, Grow by Mediavine will not slow down your website.
93
+
94
+ = Can I place the social share buttons only on posts and pages? =
95
+
96
+ You can place both the inline social share buttons and the floating sidebar social sharing buttons on any custom post type that your WordPress installation has registered. You are not limited to only posts and pages.
97
+
98
+
99
+ == Screenshots ==
100
+ 1. Inline-Content social sharing buttons output
101
+ 2. Floating Sidebar social share buttons output
102
+ 3. Floating Sidebar social share buttons configuration page
103
+ 4. Before and After Content social sharing buttons configuration page
104
+
105
+
106
+ == Changelog ==
107
+
108
+ = 1.7.0 =
109
+ * ENHANCEMENT: Change name and branding to Grow by Mediavine
110
+ * ENHANCEMENT: Ensure text remains visible during icon webfont load
111
+ * ENHANCEMENT: Optimize Javascript
112
+ * ENHANCEMENT: Better accessibility for share buttons
113
+ * FIX: Better spacing for the inline links
114
+ * FIX: Total Shares won't wrap lines
115
+
116
+ = 1.6.2 =
117
+ * Fixed: Issue with Facebook social share counts not being pulled properly
118
+
119
+ = 1.6.1 =
120
+ * New: Added Facebook authentication to be able to pull Facebook social share counts
121
+ * New: Added sixth column for Inline Content buttons
122
+ * Fixed: Issue with ampersand breaking the email button
123
+
124
+ = 1.6.0 =
125
+ * New: Added Email and Print social sharing buttons
126
+ * New: Redesigned the admin interface
127
+ * New: Added button labels to the floating sidebar social sharing tool
128
+ * Misc: Removed Google+ social sharing button
129
+
130
+ = 1.5.3 =
131
+ * Fixed: Bullet point list item issues for social share buttons with certain themes
132
+
133
+ = 1.5.2 =
134
+ * Misc: Code clean-up and compatibility with latest WordPress
135
+
136
+ = 1.5.1 =
137
+ * New: Removed support for OpenShareCount and added support for TwitCount
138
+
139
+ = 1.5.0 =
140
+ * New: Add a Twitter handle to the tweet generated when clicking on the Twitter social sharing button.
141
+ * Fixed: Issue with inline social share button labels being added to Yoast meta descriptions.
142
+
143
+ = 1.4.9 =
144
+ * New: Removed support for NewShareCounts in favor of support for OpenShareCount to retrieve Twitter social share counts.
145
+
146
+ = 1.4.8 =
147
+ * Misc: Small admin user interface improvements to make the plugin more user friendly.
148
+
149
+ = 1.4.7 =
150
+ * New: Added social sharing buttons icon animation.
151
+
152
+ = 1.4.6 =
153
+ * New: Added support for the 5th column in the Inline Content Social Sharing tool.
154
+ * New: Added feedback form on plugin deactivation.
155
+
156
+ = 1.4.5 =
157
+ * New: Added social media share count statistics meta-box in admin post edit screen.
158
+ * Fixed: Issue with Facebook API not pulling social share counts.
159
+
160
+ = 1.4.4 =
161
+ * Misc: Modified the way social share counts are being pulled to improve performance.
162
+ * Misc: Added feedback form for admin users.
163
+ * Misc: Updated Facebook API version used by the plugin.
164
+
165
+ = 1.4.3 =
166
+ * Fixed: Issue with Twitter opening two pop-up share windows when Twitter's script is added to the page.
167
+
168
+ = 1.4.2 =
169
+ * Misc: Added translation support for strings that were missing it.
170
+
171
+ = 1.4.1 =
172
+ * Misc: Removed Google+ social share count support, due to Google removing it also.
173
+
174
+ = 1.4.0 =
175
+ * Misc: New design for social media buttons labels fields in admin panel to make them more visible
176
+
177
+ = 1.3.9 =
178
+ * New: Added LinkedIn button as a social sharing option
179
+ * Misc: Stylised the total social sharing counts for the inline content buttons
180
+
181
+ = 1.3.8 =
182
+ * Fixed: Display issues of the social sharing buttons on different themes
183
+ * Misc: Improved accessibility of the admin interface
184
+
185
+ = 1.3.7 =
186
+ * Misc: Code clean-up and small usability improvements in the admin area
187
+
188
+ = 1.3.6 =
189
+ * Misc: Added support for Twitter summary card with large image
190
+
191
+ = 1.3.5 =
192
+ * New: Added option to set a custom value for the mobile device screen width in order to display or hide the social media share buttons
193
+ * Misc: Updated the social media icon font
194
+
195
+ = 1.3.4 =
196
+ * New: Added Facebook App Secret field in the settings page in order to unlock Facebook's default limitations when trying to grab the share counts for a post
197
+
198
+ = 1.3.3 =
199
+ * New: Added Facebook App ID field in the settings page in order for posts to pass Facebook's App ID validation
200
+
201
+ = 1.3.2 =
202
+ * Fixed: Performed a security audit and fixed security issues
203
+
204
+ = 1.3.1 =
205
+ * Fixed: Fatal error on some websites.
206
+
207
+ = 1.3.0 =
208
+ * New: Social media share count values are pulled asynchronous for each post after the post loads
209
+ * Misc: Refactored social media share system
210
+
211
+ = 1.2.6 =
212
+ * Fixed: XSS vulnerability in plugin settings pages
213
+
214
+ = 1.2.5 =
215
+ * Misc: Small admin interface changes for improved user experience
216
+
217
+ = 1.2.4 =
218
+ * Misc: Added rel="nofollow" to all share buttons
219
+
220
+ = 1.2.3 =
221
+ * Misc: Updated the Facebook social share counts grabber, due to Facebook's recent changes
222
+
223
+ = 1.2.2 =
224
+ * Fixed: Mozilla Firefox users can now change the text labels of the social media buttons for the Inline Content share tool
225
+
226
+ = 1.2.1 =
227
+ * New: Added WooCommerce support for Inline Content buttons before and after the product's short description
228
+
229
+ = 1.2.0 =
230
+ * Misc: Code clean-up
231
+
232
+ = 1.1.9 =
233
+ * New: Share Text option for the Inline Content share buttons
234
+ * Misc: Under the hood improvements and refactoring
235
+
236
+ = 1.1.8 =
237
+ * New: Added Twitter tweet counts with the help of http://newsharecounts.com/
238
+
239
+ = 1.1.7 =
240
+ * Fixed: Bug that caused issues in the WordPress admin page in Safari browser
241
+ * Fixed: Issues with the Pinterest button on webpages served through HTTPS
242
+
243
+ = 1.1.6 =
244
+ * Misc: New optimised icon font for the icons, that is smaller in size
245
+
246
+ = 1.1.5 =
247
+ * New: Settings page with option to disable the Open Graph tags printed by Grow by Mediavine
248
+
249
+ = 1.1.4 =
250
+ * Misc: Code clean up and minor performance improvements
251
+
252
+ = 1.1.3 =
253
+ * New: New bigger Google+ icon
254
+
255
+ = 1.1.2 =
256
+ * Fixed: Needed minor CSS fixes
257
+
258
+ = 1.1.1 =
259
+ * Fixed: PHP notice when outputting the meta tags
260
+
261
+ = 1.1.0 =
262
+ * New: Redesigned the plugin's admin dashboard
263
+ * Misc: Minor performance improvements
264
+
265
+ = 1.0.4 =
266
+ * Fixed: Fetching Google+ share counts resulted in PHP warnings and counts were not fetched
267
+
268
+ = 1.0.3 =
269
+ * Fixed: CSS issue where buttons without labels and rounded corners did not get displayed correctly
270
+
271
+ = 1.0.2 =
272
+ * Fixed: Removed un-dismissable admin notification
273
+ * Misc: Changed textdomain from "socialpug" to "social-pug" to match the one on WordPress.org
274
+
275
+ = 1.0.1 =
276
+ * Fixed: Share window now opens in pop-up
277
+ * Fixed: Small bug that showed the buttons on posts when no post types where selected
278
+
279
+ = 1.0.0 =
280
+
281
+ * Initial release.
screenshot-1.png ADDED
Binary file
screenshot-2.png ADDED
Binary file
utils/after-build.js ADDED
@@ -0,0 +1,53 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ require('dotenv').config()
2
+
3
+ const fs = require('fs')
4
+ const path = require('path')
5
+ const escapeStringRegexp = require('escape-string-regexp')
6
+
7
+ const { VERSION } = process.env
8
+ const TO_REMOVE = [
9
+ 'entry.html',
10
+ 'dev-entry'
11
+ ]
12
+
13
+ try {
14
+ const outputDir = path.resolve('package.json', '..', 'assets/dist')
15
+ const outputFiles = fs.readdirSync(outputDir)
16
+
17
+ outputFiles.forEach(fileName => {
18
+ const fileWithPath = `${outputDir}/${fileName}`
19
+
20
+ if(TO_REMOVE.some(nameToRemove => fileName.includes(nameToRemove))) {
21
+ return fs.unlinkSync(fileWithPath)
22
+ }
23
+
24
+ // Replace hashes within CSS file paths
25
+ if(/css$/.test(fileName)) {
26
+ let contents = fs.readFileSync(fileWithPath, 'utf8')
27
+
28
+ outputFiles.forEach(maybeHashedFile => {
29
+ const pattern = new RegExp(`/${escapeStringRegexp(maybeHashedFile)}`, 'g')
30
+ const withVersionNumberAndPath = `./${maybeHashedFile.replace(/\.\w+\.(\w+)$/, (_, ext) =>`.${VERSION}.${ext}`)}`
31
+ contents = contents.replace(pattern, withVersionNumberAndPath)
32
+ })
33
+ fs.writeFileSync(fileWithPath, contents)
34
+ }
35
+
36
+ // Delete module splitting code in JS paths. Remove this when we need module splitting.
37
+ if(/js$/.test(fileName)) {
38
+ let contents = fs.readFileSync(fileWithPath, 'utf8')
39
+ contents = contents.replace(/parcelRequire.*\n(.*)\n.*/, (_, js) => js)
40
+ fs.writeFileSync(fileWithPath, contents)
41
+ }
42
+
43
+ // Insert hashes into filenames
44
+ const withVersionNumber = fileName
45
+ .replace(/\.\w+\.(\w+)$/, (_, ext) => `.${VERSION}.${ext}`) // Replace Parcel-generated hashes with version
46
+
47
+ return fs.renameSync(fileWithPath, `${outputDir}/${withVersionNumber}`)
48
+ })
49
+
50
+ process.exit(0)
51
+ } catch(err) {
52
+ console.log(err)
53
+ }