1import{a as I,T as w}from"./toastr-DzMnBZAB.js";import{C as n}from"./constants-CM_nffX6.js";I.defaults.headers.common={"X-Requested-With":"XMLHttpRequest"};w.options={timeOut:1500,positionClass:"toast-top-center"};const f={};function O(e){const t=typeof e=="string"?JSON.parse(e):e;Object.entries(t).forEach(([r,i])=>f[r]=i)}function a(e){return location.origin+e}function d(e){location.href=a(e)}function u(){return n.SITE_HOSTNAME.indexOf("no-ichigo")!==-1}function l(){return n.SITE_HOSTNAME.indexOf("berrys-cafe")!==-1}function c(){return n.SITE_HOSTNAME.indexOf("novema")!==-1}function T(){return window.navigator.userAgent.indexOf("WebViewRequest")!==-1}function E(){let e=window.navigator.userAgent;return e.indexOf("Android ")!==-1&&e.indexOf("WebViewRequest")!==-1}function N(){let e=window.navigator.userAgent;return(e.indexOf("iPhone;")!==-1||e.indexOf("iPod")!==-1||e.indexOf("iPad")!==-1)&&e.indexOf("WebViewRequest")!==-1}function h(e){u()?window.document.title=e+" | éãã¡ã - ç¡æã§èªããææå°èª¬ã»å°å¥³ã³ããã¯":l()?window.document.title=e+" | å°èª¬ãµã¤ã ããªã¼ãºã«ãã§":c()&&(window.document.title=e+" | å°èª¬ãµã¤ã ãããï¼")}const x={numberFormat:e=>String(e).replace(/(\d)(?=(\d\d\d)+(?!\d))/g,"$1,"),getAxios:()=>I,getToastr:()=>w,setTitleWithSiteName:e=>h(e),setMeta({title:e,description:t,keywords:r,canonical:i}){if(h(e),t===void 0||r===void 0||i===void 0)return;function o(g,p,_,m,b){let s=document.querySelector("".concat(g,"[").concat(p,'="').concat(_,'"]'));s===null?(s=document.createElement(g),s.setAttribute(p,_),s.setAttribute(m,b),document.head.appendChild(s)):s.setAttribute(m,b)}o("meta","name","description","content",t),o("meta","name","keywords","content",r.join(", ")),o("meta","property","og:title","content",document.title),o("meta","property","og:description","content",t),o("meta","property","og:url","content",i),o("link","rel","canonical","href",i)},get isNoichigo(){return u()},get isBerrys(){return l()},get isNovema(){return c()},get isWebview(){return T()},get siteId(){return u()?n.SITE_ID_NI:l()?n.SITE_ID_BC:c()?n.SITE_ID_NV:""},get siteName(){return u()?n.SITE_NAME_NI:l()?n.SITE_NAME_BC:c()?n.SITE_NAME_NV:""},get isPc(){let e=window.navigator.userAgent;return!(e.indexOf("iPhone;")!==-1||e.indexOf("iPod")!==-1||e.indexOf("iPad")!==-1||e.indexOf("Android ")!==-1||e.indexOf("Mobile")!=-1)},get isAndroidWebview(){return E()},get isIosWebview(){return N()},getAssetsUrl(e){return a("/assets/1.0.971".concat(e))},getSiteNameById(e){return e===n.SITE_ID_NI?n.SITE_NAME_NI:e===n.SITE_ID_BC?n.SITE_NAME_BC:e===n.SITE_ID_NV?n.SITE_NAME_NV:""},getUrl:e=>a(e),getHelpUrl(e){let t=n.HELP_ARTICLE_IDS[e];return typeof t=="object"&&siteId in t&&(t=t[siteId]),a("/help/n".concat(t))},goToLoginAtThisTab(){let e="/login?back_path="+encodeURIComponent(location.pathname+location.search);return d(e)},goToLoginAtNewTab(){window.open(a("/login"))},getUrlByRouteName(e,t={}){if(e in f){let r=f[e];return Object.entries(t).forEach(([i,o])=>r=r.replace(new RegExp("{"+i+"\\??}"),o)),a(r.replace(/\/{[^}]+\\?}/g,""))}return null},replaceBackPath(){const e=document.querySelector("#header .headerLogin a");e&&e.addEventListener("click",t=>{const r=t.target.getAttribute("href"),i="back_path=/book/n"+this.$store.state.ctxt.book_id+"/"+this.$route.params.page;t.target.setAttribute("href",r.replace(/back_path=[^&]+/,i.replace(/\//g,"%2F")))})},setTitleToLastBreadCrumb(e,t){const r=document.querySelector("#breadcrumb_inner > li:last-child > a");r&&(r.querySelector(":scope > span").textContent=e,r.setAttribute("href",t))},goToNotfound:()=>d("/notfound"),showBookPagePreviewWithNewTab(e,t){let r="/book/n"+e+"/"+t;T()?d(r):window.open(a(r))},escapeHtmlCharacters(e=""){return String(e).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")},replaceNewBreadcrumb(e){const t=document.getElementById("breadcrumb");t&&(t.outerHTML=e)}};export{x as U,O as s};
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.