WordPress/wp-includes/js/dist/dom.min.js

2 lines
8.0 KiB
JavaScript
Raw Normal View History

/*! This file is auto-generated */
Block Editor: Update WordPress Packages. The following package versions were changed: @wordpress/a11y: 2.5.1 -> 2.6.0 @wordpress/annotations: 1.9.0 -> 1.10.0 @wordpress/api-fetch: 3.8.0 -> 3.9.0 @wordpress/blob: 2.5.1 -> 2.6.0 @wordpress/block-directory: 1.2.0 -> 1.3.0 @wordpress/block-editor: 3.4.0 -> 3.5.0 @wordpress/block-library: 2.11.0 -> 2.12.0 @wordpress/blocks: 6.9.0 -> 6.10.0 @wordpress/components: 8.5.0 -> 9.0.0 @wordpress/compose: 3.9.0 -> 3.10.0 @wordpress/core-data: 2.9.0 -> 2.10.0 @wordpress/data: 4.11.0 -> 4.12.0 @wordpress/data-controls: 1.5.0 -> 1.6.0 @wordpress/dom: 2.6.0 -> 2.7.0 @wordpress/dom-ready: 2.5.1 -> 2.6.0 @wordpress/e2e-test-utils: 4.0.0 -> 4.1.0 @wordpress/edit-post: 3.10.0 -> 3.11.0 @wordpress/editor: 9.9.0 -> 9.10.0 @wordpress/format-library: 1.11.0 -> 1.12.0 @wordpress/i18n: 3.7.0 -> 3.8.0 @wordpress/is-shallow-equal: 1.6.1 -> 1.7.0 @wordpress/keycodes: 2.7.0 -> 2.8.0 @wordpress/list-reusable-blocks: 1.10.0 -> 1.11.0 @wordpress/media-utils: 1.4.0 -> 1.5.0 @wordpress/notices: 1.10.0 -> 1.11.0 @wordpress/nux: 3.9.0 -> 3.10.0 @wordpress/plugins: 2.9.0 -> 2.10.0 @wordpress/priority-queue: 1.3.1 -> 1.4.0 @wordpress/rich-text: 3.9.0 -> 3.10.0 @wordpress/scripts: 6.1.1 -> 6.2.0 @wordpress/server-side-render: 1.5.0 -> 1.6.0 @wordpress/viewport: 2.10.0 -> 2.11.0 The following package was added: @wordpress/keyboard-shortcuts Props gziolo. Fixes #49204. Built from https://develop.svn.wordpress.org/trunk@47106 git-svn-id: http://core.svn.wordpress.org/trunk@46906 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-22 23:06:21 +01:00
this.wp=this.wp||{},this.wp.dom=function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=388)}({2:function(e,t){!function(){e.exports=this.lodash}()},388:function(e,t,n){"use strict";n.r(t);var r={};n.r(r),n.d(r,"find",(function(){return u}));var o={};n.r(o),n.d(o,"isTabbableIndex",(function(){return d})),n.d(o,"find",(function(){return p})),n.d(o,"findPrevious",(function(){return m})),n.d(o,"findNext",(function(){return h}));var i=["[tabindex]","a[href]","button:not([disabled])",'input:not([type="hidden"]):not([disabled])',"select:not([disabled])","textarea:not([disabled])","iframe","object","embed","area[href]","[contenteditable]:not([contenteditable=false])"].join(",");function a(e){return e.offsetWidth>0||e.offsetHeight>0||e.getClientRects().length>0}function u(e){var t=e.querySelectorAll(i);return Array.from(t).filter((function(e){return!!a(e)&&("AREA"!==e.nodeName||function(e){var t=e.closest("map[name]");if(!t)return!1;var n=document.querySelector('img[usemap="#'+t.name+'"]');return!!n&&a(n)}(e))}))}var c=n(2);function l(e){var t=e.getAttribute("tabindex");return null===t?0:parseInt(t,10)}function d(e){return-1!==l(e)}function f(e,t){return{element:e,index:t}}function s(e){return e.element}function g(e,t){var n=l(e.element),r=l(t.element);return n===r?e.index-t.index:n-r}function v(e){return e.filter(d).map(f).sort(g).map(s).reduce((t={},function(e,n){var r=n.nodeName,o=n.type,i=n.checked,a=n.name;if("INPUT"!==r||"radio"!==o||!a)return e.concat(n);var u=t.hasOwnProperty(a);if(!i&&u)return e;if(u){var l=t[a];e=Object(c.without)(e,l)}return t[a]=n,e.concat(n)}),[]);var t}function p(e){return v(u(e))}function m(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document.activeElement,t=u(document.body),n=t.indexOf(e);return t.length=n,Object(c.last)(v(t))}function h(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document.activeElement,t=u(document.body),n=t.indexOf(e),r=t.slice(n+1).filter((function(t){return!e.contains(t)}));return Object(c.first)(v(r))}var b=window.getComputedStyle,C=window.Node,N=C.TEXT_NODE,E=C.ELEMENT_NODE,y=C.DOCUMENT_POSITION_PRECEDING,R=C.DOCUMENT_POSITION_FOLLOWING;function O(e,t,n){if(Object(c.includes)(["INPUT","TEXTAREA"],e.tagName))return e.selectionStart===e.selectionEnd&&(t?0===e.selectionStart:e.value.length===e.selectionStart);if(!e.isContentEditable)return!0;var r=window.getSelection();if(!r.rangeCount)return!1;var o=r.getRangeAt(0).cloneRange(),i=function(e){var t=e.anchorNode,n=e.focusNode,r=e.anchorOffset,o=e.focusOffset,i=t.compareDocumentPosition(n);return!(i&y)&&(!!(i&R)||(0!==i||r<=o))}(r),a=r.isCollapsed;a||o.collapse(!i);var u=T(o);if(!u)return!1;var l=window.getComputedStyle(e),d=parseInt(l.lineHeight,10)||0;if(!a&&u.height>d&&i===t)return!1;var f=parseInt(l["padding".concat(t?"Top":"Bottom")],10)||0,s=3*parseInt(d,10)/4,g=e.getBoundingClientRect();if(!(t?g.top+f>u.top-s:g.bottom-f<u.bottom+s))return!1;if(n)return!0;var v="rtl"===l.direction?!t:t,p=v?g.left+1:g.right-1,m=t?g.top+s:g.bottom-s,h=x(document,p,m,e);if(!h)return!1;var b=v?"left":"right",C=T(h);return Math.abs(C[b]-u[b])<=1}function w(e,t){return O(e,t)}function S(e,t){return O(e,t,!0)}function T(e){if(!e.collapsed)return e.getBoundingClientRec