mirror of
https://github.com/WordPress/WordPress.git
synced 2024-09-10 14:48:07 +02:00
Applies changes between the Gutenberg plugin v10.4 and v10.5. It contains the latest version of WordPress packages and PHP changes applied to non-experimental features. Props youknowriad. See #52991. Built from https://develop.svn.wordpress.org/trunk@50824 git-svn-id: http://core.svn.wordpress.org/trunk@50433 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2 lines
11 KiB
JavaScript
2 lines
11 KiB
JavaScript
/*! This file is auto-generated */
|
||
this.wp=this.wp||{},this.wp.i18n=function(t){var n={};function e(r){if(n[r])return n[r].exports;var i=n[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,e),i.l=!0,i.exports}return e.m=t,e.c=n,e.d=function(t,n,r){e.o(t,n)||Object.defineProperty(t,n,{enumerable:!0,get:r})},e.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},e.t=function(t,n){if(1&n&&(t=e(t)),8&n)return t;if(4&n&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(e.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&n&&"string"!=typeof t)for(var i in t)e.d(r,i,function(n){return t[n]}.bind(null,i));return r},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,n){return Object.prototype.hasOwnProperty.call(t,n)},e.p="",e(e.s=467)}({212:function(t,n,e){var r;!function(){"use strict";var i={not_string:/[^s]/,not_bool:/[^t]/,not_type:/[^T]/,not_primitive:/[^v]/,number:/[diefg]/,numeric_arg:/[bcdiefguxX]/,json:/[j]/,not_json:/[^j]/,text:/^[^\x25]+/,modulo:/^\x25{2}/,placeholder:/^\x25(?:([1-9]\d*)\$|\(([^)]+)\))?(\+)?(0|'[^$])?(-)?(\d+)?(?:\.(\d+))?([b-gijostTuvxX])/,key:/^([a-z_][a-z_\d]*)/i,key_access:/^\.([a-z_][a-z_\d]*)/i,index_access:/^\[(\d+)\]/,sign:/^[+-]/};function o(t){return u(c(t),arguments)}function a(t,n){return o.apply(null,[t].concat(n||[]))}function u(t,n){var e,r,a,u,s,c,l,p,f,d=1,h=t.length,g="";for(r=0;r<h;r++)if("string"==typeof t[r])g+=t[r];else if("object"==typeof t[r]){if((u=t[r]).keys)for(e=n[d],a=0;a<u.keys.length;a++){if(null==e)throw new Error(o('[sprintf] Cannot access property "%s" of undefined value "%s"',u.keys[a],u.keys[a-1]));e=e[u.keys[a]]}else e=u.param_no?n[u.param_no]:n[d++];if(i.not_type.test(u.type)&&i.not_primitive.test(u.type)&&e instanceof Function&&(e=e()),i.numeric_arg.test(u.type)&&"number"!=typeof e&&isNaN(e))throw new TypeError(o("[sprintf] expecting number but found %T",e));switch(i.number.test(u.type)&&(p=e>=0),u.type){case"b":e=parseInt(e,10).toString(2);break;case"c":e=String.fromCharCode(parseInt(e,10));break;case"d":case"i":e=parseInt(e,10);break;case"j":e=JSON.stringify(e,null,u.width?parseInt(u.width):0);break;case"e":e=u.precision?parseFloat(e).toExponential(u.precision):parseFloat(e).toExponential();break;case"f":e=u.precision?parseFloat(e).toFixed(u.precision):parseFloat(e);break;case"g":e=u.precision?String(Number(e.toPrecision(u.precision))):parseFloat(e);break;case"o":e=(parseInt(e,10)>>>0).toString(8);break;case"s":e=String(e),e=u.precision?e.substring(0,u.precision):e;break;case"t":e=String(!!e),e=u.precision?e.substring(0,u.precision):e;break;case"T":e=Object.prototype.toString.call(e).slice(8,-1).toLowerCase(),e=u.precision?e.substring(0,u.precision):e;break;case"u":e=parseInt(e,10)>>>0;break;case"v":e=e.valueOf(),e=u.precision?e.substring(0,u.precision):e;break;case"x":e=(parseInt(e,10)>>>0).toString(16);break;case"X":e=(parseInt(e,10)>>>0).toString(16).toUpperCase()}i.json.test(u.type)?g+=e:(!i.number.test(u.type)||p&&!u.sign?f="":(f=p?"+":"-",e=e.toString().replace(i.sign,"")),c=u.pad_char?"0"===u.pad_char?"0":u.pad_char.charAt(1):" ",l=u.width-(f+e).length,s=u.width&&l>0?c.repeat(l):"",g+=u.align?f+e+s:"0"===c?f+s+e:s+f+e)}return g}var s=Object.create(null);function c(t){if(s[t])return s[t];for(var n,e=t,r=[],o=0;e;){if(null!==(n=i.text.exec(e)))r.push(n[0]);else if(null!==(n=i.modulo.exec(e)))r.push("%");else{if(null===(n=i.placeholder.exec(e)))throw new SyntaxError("[sprintf] unexpected placeholder");if(n[2]){o|=1;var a=[],u=n[2],c=[];if(null===(c=i.key.exec(u)))throw new SyntaxError("[sprintf] failed to parse named argument key");for(a.push(c[1]);""!==(u=u.substring(c[0].length));)if(null!==(c=i.key_access.exec(u)))a.push(c[1]);else{if(null===(c=i.index_access.exec(u)))throw new SyntaxError("[sprintf] failed to parse named argument key");a.push(c[1])}n[2]=a}else o|=2;if(3===o)throw new Error("[sprintf] mixing positional and named placeholders is not (yet) supported");r.push({placeholder:n[0],param_no:n[1],keys:n[2],sign:n[3],pad_char:n[4],align:n[5],width:n[6],precision:n[7],type:n[8]})}e=e.substring(n[0].length)}return s[t]=r}n.sprintf=o,n.vsprintf=a,"undefined"!=typeof window&&(window.sprintf=o,window.vsprintf=a,void 0===(r=function(){return{sprintf:o,vsprintf:a}}.call(n,e,n,t))||(t.exports=r))}()},30:function(t,n){t.exports=window.wp.hooks},467:function(t,n,e){"use strict";e.r(n),e.d(n,"sprintf",(function(){return s})),e.d(n,"createI18n",(function(){return w})),e.d(n,"defaultI18n",(function(){return j})),e.d(n,"setLocaleData",(function(){return S})),e.d(n,"resetLocaleData",(function(){return P})),e.d(n,"getLocaleData",(function(){return F})),e.d(n,"subscribe",(function(){return D})),e.d(n,"__",(function(){return L})),e.d(n,"_x",(function(){return T})),e.d(n,"_n",(function(){return E})),e.d(n,"_nx",(function(){return I})),e.d(n,"isRTL",(function(){return A})),e.d(n,"hasTranslation",(function(){return M}));var r=e(68),i=e.n(r),o=e(212),a=e.n(o),u=i()(console.error);function s(t){try{for(var n=arguments.length,e=new Array(n>1?n-1:0),r=1;r<n;r++)e[r-1]=arguments[r];return a.a.sprintf.apply(a.a,[t].concat(e))}catch(n){return u("sprintf error: \n\n"+n.toString()),t}}var c,l,p,f,d=e(5);c={"(":9,"!":8,"*":7,"/":7,"%":7,"+":6,"-":6,"<":5,"<=":5,">":5,">=":5,"==":4,"!=":4,"&&":3,"||":2,"?":1,"?:":1},l=["(","?"],p={")":["("],":":["?","?:"]},f=/<=|>=|==|!=|&&|\|\||\?:|\(|!|\*|\/|%|\+|-|<|>|\?|\)|:/;var h={"!":function(t){return!t},"*":function(t,n){return t*n},"/":function(t,n){return t/n},"%":function(t,n){return t%n},"+":function(t,n){return t+n},"-":function(t,n){return t-n},"<":function(t,n){return t<n},"<=":function(t,n){return t<=n},">":function(t,n){return t>n},">=":function(t,n){return t>=n},"==":function(t,n){return t===n},"!=":function(t,n){return t!==n},"&&":function(t,n){return t&&n},"||":function(t,n){return t||n},"?:":function(t,n,e){if(t)throw n;return e}};function g(t){var n=function(t){for(var n,e,r,i,o=[],a=[];n=t.match(f);){for(e=n[0],(r=t.substr(0,n.index).trim())&&o.push(r);i=a.pop();){if(p[e]){if(p[e][0]===i){e=p[e][1]||e;break}}else if(l.indexOf(i)>=0||c[i]<c[e]){a.push(i);break}o.push(i)}p[e]||a.push(e),t=t.substr(n.index+e.length)}return(t=t.trim())&&o.push(t),o.concat(a.reverse())}(t);return function(t){return function(t,n){var e,r,i,o,a,u,s=[];for(e=0;e<t.length;e++){if(a=t[e],o=h[a]){for(r=o.length,i=Array(r);r--;)i[r]=s.pop();try{u=o.apply(null,i)}catch(t){return t}}else u=n.hasOwnProperty(a)?n[a]:+a;s.push(u)}return s[0]}(n,t)}}var b={contextDelimiter:"",onMissingKey:null};function v(t,n){var e;for(e in this.data=t,this.pluralForms={},this.options={},b)this.options[e]=void 0!==n&&e in n?n[e]:b[e]}function y(t,n){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable}))),e.push.apply(e,r)}return e}function x(t){for(var n=1;n<arguments.length;n++){var e=null!=arguments[n]?arguments[n]:{};n%2?y(Object(e),!0).forEach((function(n){Object(d.a)(t,n,e[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):y(Object(e)).forEach((function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(e,n))}))}return t}v.prototype.getPluralForm=function(t,n){var e,r,i,o,a=this.pluralForms[t];return a||("function"!=typeof(i=(e=this.data[t][""])["Plural-Forms"]||e["plural-forms"]||e.plural_forms)&&(r=function(t){var n,e,r;for(n=t.split(";"),e=0;e<n.length;e++)if(0===(r=n[e].trim()).indexOf("plural="))return r.substr(7)}(e["Plural-Forms"]||e["plural-forms"]||e.plural_forms),o=g(r),i=function(t){return+o({n:t})}),a=this.pluralForms[t]=i),a(n)},v.prototype.dcnpgettext=function(t,n,e,r,i){var o,a,u;return o=void 0===i?0:this.getPluralForm(t,i),a=e,n&&(a=n+this.options.contextDelimiter+e),(u=this.data[t][a])&&u[o]?u[o]:(this.options.onMissingKey&&this.options.onMissingKey(e,t),0===o?e:r)};var _={"":{plural_forms:function(t){return 1===t?0:1}}},m=/^i18n\.(n?gettext|has_translation)(_|$)/,w=function(t,n,e){var r=new v({}),i=new Set,o=function(){i.forEach((function(t){return t()}))},a=function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"default";r.data[n]=x(x(x({},_),r.data[n]),t),r.data[n][""]=x(x({},_[""]),r.data[n][""])},u=function(t,n){a(t,n),o()},s=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default",n=arguments.length>1?arguments[1]:void 0,e=arguments.length>2?arguments[2]:void 0,i=arguments.length>3?arguments[3]:void 0,o=arguments.length>4?arguments[4]:void 0;return r.data[t]||a(void 0,t),r.dcnpgettext(t,n,e,i,o)},c=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default";return t},l=function(t,n,r){var i=s(r,n,t);return e?(i=e.applyFilters("i18n.gettext_with_context",i,t,n,r),e.applyFilters("i18n.gettext_with_context_"+c(r),i,t,n,r)):i};if(t&&u(t,n),e){var p=function(t){m.test(t)&&o()};e.addAction("hookAdded","core/i18n",p),e.addAction("hookRemoved","core/i18n",p)}return{getLocaleData:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default";return r.data[t]},setLocaleData:u,resetLocaleData:function(t,n){r.data={},r.pluralForms={},u(t,n)},subscribe:function(t){return i.add(t),function(){return i.delete(t)}},__:function(t,n){var r=s(n,void 0,t);return e?(r=e.applyFilters("i18n.gettext",r,t,n),e.applyFilters("i18n.gettext_"+c(n),r,t,n)):r},_x:l,_n:function(t,n,r,i){var o=s(i,void 0,t,n,r);return e?(o=e.applyFilters("i18n.ngettext",o,t,n,r,i),e.applyFilters("i18n.ngettext_"+c(i),o,t,n,r,i)):o},_nx:function(t,n,r,i,o){var a=s(o,i,t,n,r);return e?(a=e.applyFilters("i18n.ngettext_with_context",a,t,n,r,i,o),e.applyFilters("i18n.ngettext_with_context_"+c(o),a,t,n,r,i,o)):a},isRTL:function(){return"rtl"===l("ltr","text direction")},hasTranslation:function(t,n,i){var o,a,u=n?n+""+t:t,s=!(null===(o=r.data)||void 0===o||null===(a=o[null!=i?i:"default"])||void 0===a||!a[u]);return e&&(s=e.applyFilters("i18n.has_translation",s,t,n,i),s=e.applyFilters("i18n.has_translation_"+c(i),s,t,n,i)),s}}},k=e(30),O=w(void 0,void 0,k.defaultHooks),j=O,F=O.getLocaleData.bind(O),S=O.setLocaleData.bind(O),P=O.resetLocaleData.bind(O),D=O.subscribe.bind(O),L=O.__.bind(O),T=O._x.bind(O),E=O._n.bind(O),I=O._nx.bind(O),A=O.isRTL.bind(O),M=O.hasTranslation.bind(O)},5:function(t,n,e){"use strict";function r(t,n,e){return n in t?Object.defineProperty(t,n,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[n]=e,t}e.d(n,"a",(function(){return r}))},68:function(t,n,e){t.exports=function(t,n){var e,r,i=0;function o(){var o,a,u=e,s=arguments.length;t:for(;u;){if(u.args.length===arguments.length){for(a=0;a<s;a++)if(u.args[a]!==arguments[a]){u=u.next;continue t}return u!==e&&(u===r&&(r=u.prev),u.prev.next=u.next,u.next&&(u.next.prev=u.prev),u.next=e,u.prev=null,e.prev=u,e=u),u.val}u=u.next}for(o=new Array(s),a=0;a<s;a++)o[a]=arguments[a];return u={args:o,val:t.apply(null,o)},e?(e.prev=u,u.next=e):r=u,i===n.maxSize?(r=r.prev).next=null:i++,e=u,u.val}return n=n||{},o.clear=function(){e=null,r=null,i=0},o}}}); |