summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/jetpack/_inc/build/widgets/social-icons/social-icons-admin.min.js')
-rw-r--r--plugins/jetpack/_inc/build/widgets/social-icons/social-icons-admin.min.js2
1 files changed, 2 insertions, 0 deletions
diff --git a/plugins/jetpack/_inc/build/widgets/social-icons/social-icons-admin.min.js b/plugins/jetpack/_inc/build/widgets/social-icons/social-icons-admin.min.js
new file mode 100644
index 00000000..ad5be6b8
--- /dev/null
+++ b/plugins/jetpack/_inc/build/widgets/social-icons/social-icons-admin.min.js
@@ -0,0 +1,2 @@
+/* Do not modify this file directly. It is compiled from other files. */
+!function(t){var i=null;function e(i){i.find(".jetpack-social-icons-widget-list").sortable({items:"> .jetpack-social-icons-widget-item",handle:".handle",cursor:"move",placeholder:"jetpack-social-icons-widget-item ui-state-placeholder",containment:i,forcePlaceholderSize:!0,update:function(){n(t(this).parents(".form").find(".widget-control-save"))}})}function n(i){t(document.body).hasClass("wp-customizer")&&i.length&&i.trigger("click").hide()}t(document).ready(function(){t(document).on("click",".jetpack-social-icons-widget.add-button button",function(i){var e,n,o,c,a;i.preventDefault(),e=t(t.trim(t("#tmpl-jetpack-widget-social-icons-template").html())),c=(o=(n=t(this).parents(".widget-content")).find(".jetpack-social-icons-widget-list")).data("url-icon-id"),a=o.data("url-icon-name"),e.find(".jetpack-widget-social-icons-url input").attr("id",c).attr("name",a+"[]"),o.append(e),n.find(".jetpack-social-icons-widget-item:last").find("input:first").trigger("focus")}),t(document).on("click",".jetpack-widget-social-icons-remove-item-button",function(i){i.preventDefault();var e=t(this).parents(".form").find(".widget-control-save");t(this).parents(".jetpack-social-icons-widget-item").remove(),n(e)}),t(document).on("click",'div.widget[id*="jetpack_widget_social_icons"] .widget-title, div.widget[id*="jetpack_widget_social_icons"] .widget-action',function(){t(this).parents("#available-widgets").length||e(t(this).parents('.widget[id*="jetpack_widget_social_icons"]'))}),t(document).on("widget-added",function(t,i){i.is('[id*="jetpack_widget_social_icons"]')&&(t.preventDefault(),e(i))}),t(document).on("widget-updated",function(t,i){i.is('[id*="jetpack_widget_social_icons"]')&&(t.preventDefault(),e(i))}),t(document).on("focusout",'input[name*="jetpack_widget_social_icons"]',function(){n(t(this).parents(".form").find(".widget-control-save"))}),t(document).on("keydown",'input[name*="jetpack_widget_social_icons"]',function(i){13===i.keyCode&&n(t(this).parents(".form").find(".widget-control-save"))}),t(document).on("keyup",'input[name*="jetpack_widget_social_icons"]',function(){clearTimeout(i),i=setTimeout(function(){n(t(this).parents(".form").find(".widget-control-save"))},1e3)}),t(document).on("change",'select[name*="jetpack_widget_social_icons"]',function(){n(t(this).parents(".form").find(".widget-control-save"))})})}(jQuery); \ No newline at end of file