PageSourceSearch

https://wbk-assets.webook.com/0.7.8.2/assets/react-i18next-Dxy0wzdl.js

js webook.com collected 2026-10-03 20:42:44 UTC 12,085 bytes, 1 lines download raw bytes

vendor: 5,123 bytes, line 1
1import{g as G,r as x,R as Q}from"./vendor-Cc9w-i99.js";function H(){return H=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var a in n)({}).hasOwnProperty.call(n,a)&&(t[a]=n[a])}return t},H.apply(null,arguments)}var _={area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0};const ee=G(_);var te=/\s([^'"/\s><]+?)[\s/>]|([^\s=]+)=\s?(".*?"|'.*?')/g;function K(t){var e={type:"tag",name:"",voidElement:!1,attrs:{},children:[]},n=t.match(/<\/?([^\s]+?)[/\s>]/);if(n&&(e.name=n[1],(ee[n[1]]||t.charAt(t.length-2)==="/")&&(e.voidElement=!0),e.name.startsWith("!--"))){var a=t.indexOf("-->");return{type:"comment",comment:a!==-1?t.slice(4,a):""}}for(var c=new RegExp(te),s=null;(s=c.exec(t))!==null;)if(s[0].trim())if(s[1]){var o=s[1].trim(),d=[o,""];o.indexOf("=")>-1&&(d=o.split("=")),e.attrs[d[0]]=d[1],c.lastIndex--}else s[2]&&(e.attrs[s[2]]=s[3].trim().substring(1,s[3].length-1));return e}var ne=/<[a-zA-Z0-9\-\!\/](?:"[^"]*"|'[^']*'|[^'">])*>/g,se=/^\s*$/,re=Object.create(null);function V(t,e){switch(e.type){case"text":return t+e.content;case"tag":return t+="<"+e.name+(e.attrs?function(n){var a=[];for(var c in n)a.push(c+'="'+n[c]+'"');return a.length?" "+a.join(" "):""}(e.attrs):"")+(e.voidElement?"/>":">"),e.voidElement?t:t+e.children.reduce(V,"")+"</"+e.name+">";case"comment":return t+"<!--"+e.comment+"-->"}}var ae={parse:function(t,e){e||(e={}),e.components||(e.components=re);var n,a=[],c=[],s=-1,o=!1;if(t.indexOf("<")!==0){var d=t.indexOf("<");a.push({type:"text",content:d===-1?t:t.substring(0,d)})}return t.replace(ne,function(m,i){if(o){if(m!=="</"+n.name+">")return;o=!1}var h,E=m.charAt(1)!=="/",w=m.startsWith("<!--"),b=i+m.length,v=t.charAt(b);if(w){var $=K(m);return s<0?(a.push($),a):((h=c[s]).children.push($),a)}if(E&&(s++,(n=K(m)).type==="tag"&&e.components[n.name]&&(n.type="component",o=!0),n.voidElement||o||!v||v==="<"||n.children.push({type:"text",content:t.slice(b,t.indexOf("<",b))}),s===0&&a.push(n),(h=c[s-1])&&h.children.push(n),c[s]=n),(!E||n.voidElement)&&(s>-1&&(n.voidElement||n.name===m.slice(2,-1))&&(s--,n=s===-1?a:c[s]),!o&&v!=="<"&&v)){h=s===-1?a:c[s].children;var l=t.indexOf("<",b),p=t.slice(b,l===-1?void 0:l);se.test(p)&&(p=" "),(l>-1&&s+h.length>=0||p!==" ")&&h.push({type:"text",content:p})}}),a},stringify:function(t){return t.reduce(function(e,n){return e+V("",n)},"")}};function I(){if(console&&console.warn){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];typeof e[0]=="string"&&(e[0]=`react-i18next:: ${e[0]}`),console.warn(...e)}}const z={};function A(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];typeof e[0]=="string"&&z[e[0]]||(typeof e[0]=="string"&&(z[e[0]]=new Date),I(...e))}const D=(t,e)=>()=>{if(t.isInitialized)e();else{const n=()=>{setTimeout(()=>{t.off("initialized",n)},0),e()};t.on("initialized",n)}};function W(t,e,n){t.loadNamespaces(e,D(t,n))}function U(t,e,n,a){typeof n=="string"&&(n=[n]),n.forEach(c=>{t.options.ns.indexOf(c)<0&&t.options.ns.push(c)}),t.loadLanguages(e,D(t,a))}function oe(t,e){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const a=e.languages[0],c=e.options?e.options.fallbackLng:!1,s=e.languages[e.languages.length-1];if(a.toLowerCase()==="cimode")return!0;const o=(d,m)=>{const i=e.services.backendConnector.state[`${d}|${m}`];return i===-1||i===2};return n.bindI18n&&n.bindI18n.indexOf("languageChanging")>-1&&e.services.backendConnector.backend&&e.isLanguageChangingTo&&!o(e.isLanguageChangingTo,t)?!1:!!(e.hasResourceBundle(a,t)||!e.services.backendConnector.backend||e.options.resources&&!e.options.partialBundledLanguages||o(a,t)&&(!c||o(s,t)))}function ie(t,e){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return!e.languages||!e.languages.length?(A("i18n.languages were undefined or empty",e.languages),!0):e.options.ignoreJSONStructure!==void 0?e.hasLoadedNamespace(t,{lng:n.lng,precheck:(c,s)=>{if(n.bindI18n&&n.bindI18n.indexOf("languageChanging")>-1&&c.services.backendConnector.backend&&c.isLanguageChangingTo&&!s(c.isLanguageChangingTo,t))return!1}}):oe(t,e,n)}const ue=/&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g,ce={"&amp;":"&","&#38;":"&","&lt;":"<","&#60;":"<","&gt;":">","&#62;":">","&apos;":"'","&#39;":"'","&quot;":'"',"&#34;":'"',"&nbsp;":" ","&#160;":" ","&copy;":"©","&#169;":"©","&reg;":"®","&#174;":"®","&hellip;":"…","&#8230;":"…","&#x2F;":"/","&#47;":"/"},le=t=>ce[t],pe=t=>t.replace(ue,le);let B={bindI18n:"languageChanged",bindI18nStore:"",transEmptyNodeValue:"",transSupportBasicHtmlNodes:!0,transWrapTextNodes:"",transKeepBasicHtmlNodesFor:["br","strong","i","p"],useSuspense:!0,unescape:pe};function fe(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};B={...B,...t}}function M(){return B}let J;function ge(t){J=t}function R(){return J}function F(t,e){if(!t)return!1;const n=t.props?t.props.children:t.children;return e?n.length>0:!!n}function P(t){if(!t)return[];const e=t.props?t.props.children:t.children;
1return t.props&&t.props.i18nIsDynamicList?k(e):e}function de(t){return Object.prototype.toString.call(t)!=="[object Array]"?!1:t.every(e=>x.isValidElement(e))}function k(t){return Array.isArray(t)?t:[t]}function me(t,e){const n={...e};return n.props=Object.assign(t.props,e.props),n}function q(t,e){if(!t)return"";let n="";const a=k(t),c=e.transSupportBasicHtmlNodes&&e.transKeepBasicHtmlNodesFor?e.transKeepBasicHtmlNodesFor:[];return a.forEach((s,o)=>{if(typeof s=="string")n+=`${s}`;else if(x.isValidElement(s)){const d=Object.keys(s.props).length,m=c.indexOf(s.type)>-1,i=s.props.children;if(!i&&m&&d===0)n+=`<${s.type}/>`;else if(!i&&(!m||d!==0))n+=`<${o}></${o}>`;else if(s.props.i18nIsDynamicList)n+=`<${o}></${o}>`;else if(m&&d===1&&typeof i=="string")n+=`<${s.type}>${i}</${s.type}>`;else{const h=q(i,e);n+=`<${o}>${h}</${o}>`}}else if(s===null)I("Trans: the passed in value is invalid - seems you passed in a null child.");else if(typeof s=="object"){const{format:d,...m}=s,i=Object.keys(m);if(i.length===1){const h=d?`${i[0]}, ${d}`:i[0];n+=`{{${h}}}`}else I("react-i18next: the passed in object contained more than one variable - the object should look like {{ value, format }} where format is optional.",s)}else I("Trans: the passed in value is invalid - seems you passed in a variable like {number} - please pass in variables for interpolation as full objects like {{number}}.",s)}),n}function he(t,e,n,a,c,s){if(e==="")return[];const o=a.transKeepBasicHtmlNodesFor||[],d=e&&new RegExp(o.map(l=>`<${l}`).join("|")).test(e);if(!t&&!d&&!s)return[e];const m={};function i(l){k(l).forEach(u=>{typeof u!="string"&&(F(u)?i(P(u)):typeof u=="object"&&!x.isValidElement(u)&&Object.assign(m,u))})}i(t);const h=ae.parse(`<0>${e}</0>`),E={...m,...c};function w(l,p,u){const g=P(l),y=v(g,p.children,u);return de(g)&&y.length===0||l.props&&l.props.i18nIsDynamicList?g:y}function b(l,p,u,g,y){l.dummy?(l.children=p,u.push(x.cloneElement(l,{key:g},y?void 0:p))):u.push(...x.Children.map([l],f=>{const r={...f.props};return delete r.i18nIsDynamicList,Q.createElement(f.type,H({},r,{key:g,ref:f.ref},y?{}:{children:p}))}))}function v(l,p,u){const g=k(l);return k(p).reduce((f,r,j)=>{const O=r.children&&r.children[0]&&r.children[0].content&&n.services.interpolator.interpolate(r.children[0].content,E,n.language);if(r.type==="tag"){let T=g[parseInt(r.name,10)];u.length===1&&!T&&(T=u[0][r.name]),T||(T={});const N=Object.keys(r.attrs).length!==0?me({props:r.attrs},T):T,S=x.isValidElement(N),L=S&&F(r,!0)&&!r.voidElement,X=d&&typeof N=="object"&&N.dummy&&!S,Z=typeof t=="object"&&t!==null&&Object.hasOwnProperty.call(t,r.name);if(typeof N=="string"){const C=n.services.interpolator.interpolate(N,E,n.language);f.push(C)}else if(F(N)||L){const C=w(N,r,u);b(N,C,f,j)}else if(X){const C=v(g,r.children,u);b(N,C,f,j)}else if(Number.isNaN(parseFloat(r.name)))if(Z){const C=w(N,r,u);b(N,C,f,j,r.voidElement)}else if(a.transSupportBasicHtmlNodes&&o.indexOf(r.name)>-1)if(r.voidElement)f.push(x.createElement(r.name,{key:`${r.name}-${j}`}));else{const C=v(g,r.children,u);f.push(x.createElement(r.name,{key:`${r.name}-${j}`},C))}else if(r.voidElement)f.push(`<${r.name} />`);else{const C=v(g,r.children,u);f.push(`<${r.name}>${C}</${r.name}>`)}else if(typeof N=="object"&&!S){const C=r.children[0]?O:null;C&&f.push(C)}else b(N,O,f,j,r.children.length!==1||!O)}else if(r.type==="text"){const T=a.transWrapTextNodes,N=s?a.unescape(n.services.interpolator.interpolate(r.content,E,n.language)):n.services.interpolator.interpolate(r.content,E,n.language);T?f.push(x.createElement(T,{key:`${r.name}-${j}`},N)):f.push(N)}return f},[])}const $=v([{dummy:!0,children:t||[]}],h,k(t||[]));return P($[0])}function ye(t){let{children:e,count:n,parent:a,i18nKey:c,context:s,tOptions:o={},values:d,defaults:m,components:i,ns:h,i18n:E,t:w,shouldUnescape:b,...v}=t;const $=E||R();if(!$)return A("You will need to pass in an i18next instance by using i18nextReactModule"),e;const l=w||$.t.bind($)||(L=>L);s&&(o.context=s);const p={...M(),...$.options&&$.options.react};let u=h||l.ns||$.options&&$.options.defaultNS;u=typeof u=="string"?[u]:u||["translation"];const g=q(e,p),y=m||g||p.transEmptyNodeValue||c,{hashTransKey:f}=p,r=c||(f?f(g||y):g||y),j=d?o.interpolation:{interpolation:{...o.interpolation,prefix:"#$?",suffix:"?$#"}},O={...o,count:n,...d,...j,defaultValue:y,ns:u},T=r?l(r,O):y,N=he(i||e,T,$,p,O,b),S=a!==void 0?a:p.defaultTransParent;return S?x.createElement(S,v,N):N}const Ne={type:"3rdParty",init(t){fe(t.options.react),ge(t)}},Y=x.createContext();class be{constructor(){this.usedNamespaces={}}addUsedNamespaces(e){e.forEach(n=>{this.usedNamespaces[n]||(this.usedNamespaces[n]=!0)})}getUsedNamespaces(){return Object.keys(this.usedNamespaces)}}function Ee(t){let{children:e,count:n,parent:a,i18nKey:c,context:s,tOptions:o={}
vendor: 2,152 bytes, line 1
1,values:d,defaults:m,components:i,ns:h,i18n:E,t:w,shouldUnescape:b,...v}=t;const{i18n:$,defaultNS:l}=x.useContext(Y)||{},p=E||$||R(),u=w||p&&p.t.bind(p);return ye({children:e,count:n,parent:a,i18nKey:c,context:s,tOptions:o,values:d,defaults:m,components:i,ns:h||u&&u.ns||l||p&&p.options&&p.options.defaultNS,i18n:p,t:w,shouldUnescape:b,...v})}const ve=(t,e)=>{const n=x.useRef();return x.useEffect(()=>{n.current=t},[t,e]),n.current};function $e(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{i18n:n}=e,{i18n:a,defaultNS:c}=x.useContext(Y)||{},s=n||a||R();if(s&&!s.reportNamespaces&&(s.reportNamespaces=new be),!s){A("You will need to pass in an i18next instance by using initReactI18next");const g=(f,r)=>typeof r=="string"?r:r&&typeof r=="object"&&typeof r.defaultValue=="string"?r.defaultValue:Array.isArray(f)?f[f.length-1]:f,y=[g,{},!1];return y.t=g,y.i18n={},y.ready=!1,y}s.options.react&&s.options.react.wait!==void 0&&A("It seems you are still using the old wait option, you may migrate to the new useSuspense behaviour.");const o={...M(),...s.options.react,...e},{useSuspense:d,keyPrefix:m}=o;let i=t||c||s.options&&s.options.defaultNS;i=typeof i=="string"?[i]:i||["translation"],s.reportNamespaces.addUsedNamespaces&&s.reportNamespaces.addUsedNamespaces(i);const h=(s.isInitialized||s.initializedStoreOnce)&&i.every(g=>ie(g,s,o));function E(){return s.getFixedT(e.lng||null,o.nsMode==="fallback"?i:i[0],m)}const[w,b]=x.useState(E);let v=i.join();e.lng&&(v=`${e.lng}${v}`);const $=ve(v),l=x.useRef(!0);x.useEffect(()=>{const{bindI18n:g,bindI18nStore:y}=o;l.current=!0,!h&&!d&&(e.lng?U(s,e.lng,i,()=>{l.current&&b(E)}):W(s,i,()=>{l.current&&b(E)})),h&&$&&$!==v&&l.current&&b(E);function f(){l.current&&b(E)}return g&&s&&s.on(g,f),y&&s&&s.store.on(y,f),()=>{l.current=!1,g&&s&&g.split(" ").forEach(r=>s.off(r,f)),y&&s&&y.split(" ").forEach(r=>s.store.off(r,f))}},[s,v]);const p=x.useRef(!0);x.useEffect(()=>{l.current&&!p.current&&b(E),p.current=!1},[s,m]);const u=[w,s,h];if(u.t=w,u.i18n=s,u.ready=h,h||!h&&!d)return u;throw new Promise(g=>{e.lng?U(s,e.lng,i,()=>g()):W(s,i,()=>g())})}export{Ee as T,Ne as i,$e as u};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.