1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7369],{2540:(e,t,a)=>{a.d(t,{R:()=>o,T:()=>s});let s={chat:"/api/chatgpt",ocr_vision:"/api/chatgpt",transcribe:"/api/transcribe",retelling_transcribe:"/api/transcribe",retelling_oral_feedback:"/api/retelling/oral-feedback",proofreading_lt:"/api/check",translate:"/api/translate",tts:"/api/tts",illustration_writing_lab:"/api/lab/illustration-writing/attempt",evaluate:"/api/ai/evaluate"},r={"/api/chatgpt":"chat","/api/ai/evaluate":"evaluate","/api/transcribe":"transcribe","/api/retelling/oral-feedback":"retelling_oral_feedback","/api/check":"proofreading_lt","/api/translate":"translate","/api/tts":"tts","/api/lab/illustration-writing/attempt":"illustration_writing_lab"};function o(e){var t;let a=function(e){let t=e.trim();if(!t)return null;try{let e=t.startsWith("http://")||t.startsWith("https://")?new URL(t).pathname:t.split("?")[0];if(!e.startsWith("/api/"))return null;return e.replace(/\/+$/,"")||null}catch(e){return null}}(e);return a&&null!=(t=r[a])?t:null}},11079:(e,t,a)=>{a.d(t,{S:()=>n});var s=a(44378),r=a(86023),o=a(98802);async function n(e,t){if(!e.trim())return{errors:[],checkStatus:"idle"};let a=await (0,s.c0)(e,t);if(!a.success)return console.warn("Grammar check API failed:",a.error),{errors:[],checkStatus:"unavailable"};let n=a.data,i=(null==n?void 0:n.checkStatus)==="unavailable"?"unavailable":"ok";if(!(null==n?void 0:n.matches))return{errors:[],checkStatus:i};let l=(0,r.Bs)({matches:n.matches},e),{kept:c}=(0,o.Qs)(e,l);return{errors:c,checkStatus:i}}},17156:(e,t,a)=>{a.d(t,{BILLABLE_API:()=>s});let s={chatGpt:"/api/chatgpt",evaluate:"/api/ai/evaluate",translate:"/api/translate",tts:"/api/tts",check:"/api/check",transcribe:"/api/transcribe"}},17991:(e,t,a)=>{a.d(t,{mj:()=>o,on:()=>n});var s=a(95155),r=a(12115);function o(e){switch(e){case"error":default:return{backgroundColor:"#ff6b6b",borderColor:"#d32f2f",lightBackgroun
1d:"rgba(211, 47, 47, 0.2)"};case"warning":return{backgroundColor:"#ffa726",borderColor:"#ed6c02",lightBackground:"rgba(237, 108, 2, 0.2)"};case"info":return{backgroundColor:"#42a5f5",borderColor:"#1976d2",lightBackground:"rgba(25, 118, 210, 0.2)"}}}function n(e){let{text:t,errors:a,selectedErrorId:n,onErrorClick:i,renderError:l}=e;if(!t||0===a.length)return t;let c=[],u=0;return[...a].sort((e,t)=>e.offset-t.offset).forEach(e=>{e.offset>u&&c.push(t.substring(u,e.offset));let a=t.substring(e.offset,e.offset+e.length),g=n===e.id;if(l)c.push(r.createElement(r.Fragment,{key:"error-".concat(e.id)},l(e,a,g)));else{let t=o(e.severity);c.push((0,s.jsx)("span",{style:{backgroundColor:t.lightBackground,borderBottom:g?"3px solid ".concat(t.borderColor):"2px solid ".concat(t.borderColor),borderRadius:"2px",transition:"all 0.3s ease-in-out",cursor:i?"pointer":"default",display:"inline",opacity:g?.6:.3,transform:g?"scale(1.02)":"scale(1)",fontSize:"inherit",lineHeight:"inherit",fontFamily:"inherit",boxShadow:g?"0 0 8px ".concat(t.borderColor,"40"):"none"},title:e.message,onClick:i?()=>i(e):void 0,onMouseEnter:e=>{!g&&i&&(e.currentTarget.style.transform="scale(1.02)",e.currentTarget.style.opacity="0.5")},onMouseLeave:e=>{g||(e.currentTarget.style.transform="scale(1)",e.currentTarget.style.opacity="0.3")},children:a},"error-".concat(e.id)))}u=e.offset+e.length}),u<t.length&&c.push(t.substring(u)),c.length>0?c:t}},44378:(e,t,a)=>{a.d(t,{uE:()=>f,chatGPT:()=>b,c0:()=>w,translate:()=>k});var s=a(10802),r=a(96103),o=a(17156);class n{static createApiError(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=new Date().toISOString();return e instanceof Error?{code:this.getErrorCode(e),message:this.getErrorMessage(e),details:{stack:e.stack,...t},timestamp:a}:{code:"UNKNOWN_ERROR",message:"䏿ãªã¨ã©ã¼ãçºçãã¾ãã",details:{originalError:e,...t},timestamp:a}}static getErrorCode(e){let t=e.message.toLowerCase();return t.includes("network")||t.includes("fetch")?"NETWORK_ERROR":"AbortError"===e.name||t.includes("timeout")||t.includes("aborted")?"TIMEOUT_ERROR":t.includes("unauthorized")||t.includes("401")?"AUTH_ERROR":t.includes("forbidden")||t.includes("403")?"PERMISSION_ERROR":t.includes("not found")||t.includes("404")?"NOT_FOUND_ERROR":t.includes("server")||t.includes("500")?"SERVER_ERROR":"API_ERROR"}static getErrorMessage(e){let t=e.message.toLowerCase();return t.includes("network")||t.includes("fetch")?"ãããã¯ã¼ã¯æ¥ç¶ã«åé¡ãããã¾ããã¤ã³ã¿ã¼ãããæ¥ç¶ã確èªãã¦ãã ããã":"AbortError"===e.name||t.includes("timeout")||t.includes("aborted")?"ãªã¯ã¨ã¹ããã¿ã¤ã ã¢ã¦ããã¾ããããã°ããæéãããã¦å試è¡ãã¦ãã ããã":t.includes("unauthorized")||t.includes("401")?"èªè¨¼ã«å¤±æãã¾ããããã°ã¤ã³ãç´ãã¦ãã ããã":t.includes("forbidden")||t.includes("403")?"ãã®æä½ãå®è¡ããæ¨©éãããã¾ããã":t.includes("not found")||t.includes("404")?"è¦æ±ããããªã½ã¼ã¹ãè¦ã¤ããã¾ããã":t.includes("server")||t.includes("500")?"ãµã¼ãã¼ã¨ã©ã¼ãçºçãã¾ããããã°ããæéãããã¦å試è¡ãã¦ãã ããã":e.message||"䏿ãªã¨ã©ã¼ãçºçãã¾ãã"}static logError(e,t){}static getUserMessage(e){return e.message}static isRetryable(e){return["NETWORK_ERROR","TIMEOUT_ERROR","SERVER_ERROR"].includes(e.code)}static getHttpStatus(e){switch(e.code){case"AUTH_ERROR":return 401;case"PERMISSION_ERROR":return 403;case"NOT_FOUND_ERROR":return 404;case"SERVER_ERROR":default:return 500;case"NETWORK_ERROR":case"TIMEOUT_ERROR":return 503}}}let{createApiError:i,logError:l,getUserMessage:c,isRetryable:u,getHttpStatus:g}=n;var h=a(97443),d=a(66279),m=a(2540);class p{async getEndpoint(e){let t={chatGpt:o.BILLABLE_API.chatGpt,translate:o.BILLABLE_API.translate,ziseDaiEigo:o.BILLABLE_API.translate,textToSpeech:o.BILLABLE_API.tts};if(t[e])return t[e];try{if(await (0,s.authenticated)())return await (0,s.getToken)()?r.F9[e]:r.KI[e];return r.KI[e]}catch(t){return console.warn("èªè¨¼ãã§ãã¯å¤±æãããã©ã«ãã¨ã³ããã¤ã³ãã使ç¨:",t),r.KI[e]}}async getAuthHeaders(){try{if(await (0,s.authenticated)()){let e=await (0,s.getToken)();return e?{Authorization:"Bearer ".concat(e)}:{}}return{}}catch(e){return console.warn("èªè¨¼ãããã¼åå¾å¤±æ:",e),{}}}getCacheKey(e,t){let a="{}";return t.body&&"object"==typeof t.body&&(a=JSON.stringify(this.sortObjectKeys(t.body))),"".concat(e,":").concat(t.method,":").concat(a)}sortObjectKeys(e){if(null===e||"object"!=typeof e)return e;if(Array.isArray(e))return e.map(e=>this.sortObjectKeys(e));let t={};
1return Object.keys(e).sort().forEach(a=>{t[a]=this.sortObjectKeys(e[a])}),t}getFromCache(e){let t=this.cache.get(e);return t?Date.now()-t.timestamp>this.CACHE_DURATION?(this.cache.delete(e),null):t.data:null}setCache(e,t){this.cache.set(e,{data:t,timestamp:Date.now()})}async fetchWithRetry(e,t){let a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:3,s=null;for(let r=0;r<=a;r++)try{let a=new AbortController,s=setTimeout(()=>a.abort(),t.timeout||1e4);if(t.signal){if(t.signal.aborted)throw clearTimeout(s),new DOMException("Aborted","AbortError");t.signal.addEventListener("abort",()=>{a.abort()})}let r=await fetch(e,{method:t.method,headers:{"Content-Type":"application/json",...t.headers},body:t.body?JSON.stringify(t.body):void 0,signal:a.signal});return clearTimeout(s),r}catch(e){if(s=e,r<a){if((null==e?void 0:e.name)==="AbortError")throw e;await new Promise(e=>setTimeout(e,1e3*Math.pow(2,r)))}}throw s||Error("Max retries exceeded")}async request(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{method:"GET"};try{if(!1!==t.cache&&"GET"===t.method){let a=this.getCacheKey(e,t),s=this.getFromCache(a);if(s)return{data:s,success:!0,message:"Data retrieved from cache"}}let a={...await this.getAuthHeaders(),...t.headers},s=await this.fetchWithRetry(e,{...t,headers:a});if(!s.ok){let t=s.statusText;try{let e=await s.json(),a=e.message||("string"==typeof e.details?e.details:e.details?JSON.stringify(e.details):void 0)||e.error;a&&(t=a)}catch(e){}let a=(0,m.R)(e);throw a&&(0,d.H)({feature:a,route:e,statusCode:s.status,kind:"http_error",message:"HTTP ".concat(s.status,": ").concat(t)}),Error("HTTP ".concat(s.status,": ").concat(t))}let r=await s.json();if(!1!==t.cache&&"GET"===t.method){let a=this.getCacheKey(e,t);this.setCache(a,r)}return{data:r,success:!0,message:"Request successful"}}catch(s){if(!(0,d.X)(s)){let t=(0,m.R)(e),a=s instanceof Error?s.message:String(s);t&&!a.startsWith("HTTP ")&&(0,d.H)({feature:t,route:e,kind:"network",message:a})}let a=n.createApiError(s,{component:"ApiClient",action:"request",requestId:Math.random().toString(36).substring(7)});return n.logError(a,{originalError:s,url:e,method:t.method}),{data:null,success:!1,error:n.getUserMessage(a),message:"Request failed",errorDetails:a}}}async authenticatedRequest(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{method:"GET"},a=await this.getEndpoint(e);return this.request(a,t)}async translate(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"auto",a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"JA",r=await (0,s.authenticated)().catch(()=>!1),o={};if(!r){let e=(0,h.f)();e&&(o["x-client-id"]=e)}return f.request("/api/translate",{method:"POST",headers:o,body:{detected_source_language:t,text:e,target_lang:a}})}async chatGPT(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"gpt-4o-mini",a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:.1,s=arguments.length>3?arguments[3]:void 0;return f.request("/api/chatgpt",{method:"POST",timeout:6e4,body:{model:t,messages:e,temperature:a,...(null==s?void 0:s.response_format)&&{response_format:s.response_format},...(null==s?void 0:s.max_tokens)&&{max_tokens:s.max_tokens}},...(null==s?void 0:s.signal)&&{signal:s.signal},...(null==s?void 0:s.headers)&&{headers:s.headers}})}async grammarCheck(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"en-US";return f.request("/api/check",{method:"POST",body:{text:e,language:t},timeout:35e3,retries:1})}async getUserData(e){return f.request("/api/transable?user_email=".concat(encodeURIComponent(e)),{method:"GET"})}clearCache(){this.cache.clear()}clearCacheByPattern(e){for(let t of this.cache.keys())t.includes(e)&&this.cache.delete(t)}constructor(){this.cache=new Map,this.CACHE_DURATION=3e5}}let f=new p,{request:y,translate:k,chatGPT:b,grammarCheck:w,getUserData:E,clearCache:_,clearCacheByPattern:R}=f},66279:(e,t,a)=>{a.d(t,{X:()=>l,H:()=>i});var s=a(2540);let r=new Set(Object.keys(s.T)),o=new Set(["http_error","network","invalid_response"]);function n(e){return"string"!=typeof e?null:e.trim()||null}function i(e){if("function"!=typeof fetch)return;let t=function(e){var t,a,i,l;if(!e||"object"!=typeof e)return null;
1let c=n(e.feature);if(!c||!r.has(c))return null;let u=null!=(t=n(e.route))?t:s.T[c];if(u.startsWith("http://")||u.startsWith("https://"))try{u=new URL(u).pathname}catch(e){return null}if(!u.startsWith("/api/"))return null;let g="number"!=typeof(a=e.statusCode)||!Number.isInteger(a)||a<100||a>599?null:a,h=(i=e.kind,"string"==typeof i&&o.has(i)?i:null!==g?"http_error":"network");return{feature:c,route:u.slice(0,120),statusCode:g,kind:h,message:(null!=(l=n(e.message))?l:"client error").slice(0,160)}}(e);if(t)try{fetch("/api/client-errors",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(t),keepalive:!0}).catch(()=>void 0)}catch(e){}}function l(e){return!!e&&"object"==typeof e&&"AbortError"===("name"in e?String(e.name):"")}},86023:(e,t,a)=>{a.d(t,{Bs:()=>n});let s=[{id:"POSSESSIVE_APOSTROPHE",ja:{message:"æææ ¼ã®çç¥ç¬¦å·ï¼'ï¼ãæãã¦ããå¯è½æ§ãããã¾ã",shortMessage:"æææ ¼"}},{id:"MORFOLOGIK",ja:{message:"ã¹ãã«ãã¹ã®å¯è½æ§ãããã¾ã",shortMessage:"ã¹ãã«"}},{id:"HUNSPELL",ja:{message:"ã¹ãã«ãã¹ã®å¯è½æ§ãããã¾ã",shortMessage:"ã¹ãã«"}}],r=[{test:e=>/possessive apostrophe|apostrophe.*missing|missing.*apostrophe/i.test(e),ja:{message:"æææ ¼ã®çç¥ç¬¦å·ï¼'ï¼ãæãã¦ããå¯è½æ§ãããã¾ã",shortMessage:"æææ ¼"}},{test:e=>/repeated a word|you repeated/i.test(e),ja:{message:"åãèªãéè¤ãã¦ãã¾ã",shortMessage:"éè¤"}},{test:e=>/pronoun|third.?person|subject.?verb|verb agreement|usually used with/i.test(e),ja:{message:"主èªã¨åè©ã®ä¸è´ã«åé¡ãããã¾ã",shortMessage:"åè©ã®ä¸è´"}},{test:e=>/use .+ instead of|article|a vs an|an vs a/i.test(e),ja:{message:"å è©ï¼a/anï¼ã®ä½¿ãæ¹ã確èªãã¦ãã ãã",shortMessage:"å è©"}},{test:e=>/uppercase|capital letter|starts with an uppercase/i.test(e),ja:{message:"æã®å§ãã®å¤§æåã確èªãã¦ãã ãã",shortMessage:"大æå"}},{test:e=>/duplicate|repeated/i.test(e),ja:{message:"éè¤ããèªå¥ãæ¤åºããã¾ãã",shortMessage:"éè¤"}},{test:e=>/comma|punctuation/i.test(e),ja:{message:"å¥èªç¹ã®ä½¿ãæ¹ã確èªãã¦ãã ãã",shortMessage:"å¥èªç¹"}},{test:e=>/contraction|contracted form/i.test(e),ja:{message:"ç縮形ï¼don't ãªã©ï¼ã®æ¸ãæ¹ã確èªãã¦ãã ãã",shortMessage:"ç縮形"}},{test:e=>/possible spelling mistake|spelling mistake|possible typo/i.test(e),ja:{message:"ã¹ãã«ãã¹ã®å¯è½æ§ãããã¾ã",shortMessage:"ã¹ãã«"}}],o={grammar:{message:"ææ³ã¨ã©ã¼ãæ¤åºããã¾ãã",shortMessage:"ææ³"},misspelling:{message:"表è¨ä¸ã®åé¡ãæ¤åºããã¾ãã",shortMessage:"表è¨"},spelling:{message:"ã¹ãã«ãã¹ã®å¯è½æ§ãããã¾ã",shortMessage:"ã¹ãã«"},typos:{message:"ã¿ã¤ããã¹ã®å¯è½æ§ãããã¾ã",shortMessage:"ã¿ã¤ããã¹"},typographical:{message:"表è¨ã®åé¡ãæ¤åºããã¾ãã",shortMessage:"表è¨"},duplication:{message:"åãèªãéè¤ãã¦ãã¾ã",shortMessage:"éè¤"},confused_words:{message:"æ··åããããåèªã使ããã¦ãã¾ã",shortMessage:"èªå½"},verb_agreement:{message:"主èªã¨åè©ã®ä¸è´ã«åé¡ãããã¾ã",shortMessage:"åè©ã®ä¸è´"},subject_verb_agreement:{message:"主èªã¨åè©ã®ä¸è´ã«åé¡ãããã¾ã",shortMessage:"åè©ã®ä¸è´"},style:{message:"ã¹ã¿ã¤ã«ã®æ¹åãææ¡ããã¦ãã¾ã",shortMessage:"ã¹ã¿ã¤ã«"},redundancy:{message:"åé·ãªè¡¨ç¾ã使ããã¦ãã¾ã",shortMessage:"åé·"},word_choice:{message:"ããé©åãªåèªã®é¸æãææ¡ããã¦ãã¾ã",shortMessage:"èªå½"},clarity:{message:"ããæç¢ºãªè¡¨ç¾ãææ¡ããã¦ãã¾ã",shortMessage:"æç¢ºã"},whitespace:{message:"ã¹ãã¼ã¹ã®ä½¿ãæ¹ã確èªãã¦ãã ãã",shortMessage:"ã¹ãã¼ã¹"},punctuation:{message:"å¥èªç¹ã®ä½¿ãæ¹ã確èªãã¦ãã ãã",shortMessage:"å¥èªç¹"},casing:{message:"大æåã»å°æåã®ä½¿ãæ¹ã確èªãã¦ãã ãã",shortMessage:"大æåå°æå"},formatting:{message:"æ¸å¼ã確èªãã¦ãã ãã",shortMessage:"æ¸å¼"},inconsistency:{message:"表è¨ã®ãããæ¤åºããã¾ãã",shortMessage:"ãã"},terminology:{message:"ç¨èªã®ä½¿ãæ¹ã確èªãã¦ãã ãã",shortMessage:"ç¨èª"},register:{message:"æä½ï¼ãã©ã¼ãã«ãï¼ã確èªãã¦ãã ãã",shortMessage:"æä½"},locale_violation:{message:"ãã±ã¼ã«ã«åã£ã表è¨ã確èªãã¦ãã ãã",shortMessage:"ãã±ã¼ã«"},uncategorized:{message:"åé¡ãæ¤åºããã¾ãã",shortMessage:"è¦ç¢ºèª"},other:{message:"åé¡ãæ¤åºããã¾ãã",shortMessage:"è¦ç¢ºèª"}};function n(e,t){let a=null==e?void 0:e.matches;if(!a||0===a.length)return[];let n=t.length,i=new Set,l=[];for(let e=0;e<a.length;e++){var c,u,g;let h=function(e,t){if(!e||"object"!=typeof e)return null;let a=e.rule&&"object"==typeof e.rule?e.rule:{},s="number"==typeof e.offset?e.offset:0,r="number"==typeof e.length?e.length:0,o="string"==typeof a.id&&a.id||"string"==typeof e.ruleId&&e.ruleId||"unknown-".concat(t),n="string"==typeof a.issueType&&a.issueType||"unknown",i=(Array.isArray(e.replacements)?e.replacements:[]).map(e=>e&&"object"==typeof e&&"string"==typeof e.value?{value:e.value}:null).filter(e=>null!==e),l=e.context&&"object"==typeof e.context?e.context:null,c=a.category&&"object"==typeof a.category?a.category:void 0;return{ruleId:o,offset:s,length:r,message:"string"==typeof e.message?e.message:"Grammar error",shortMessage:"string"==typeof e.shortMessage?e.shortMessage:"string"==typeof e.message?e.message:"Error",replacements:i,context:{text:"string"==typeof(null==l?void 0:l.text)?l.text:"",offset:"number"==typeof(null==l?void 0:l.offset)?l.offset:s,length:"number"==typeof(null==l?void 0:l.length)?l.length:r},rule:{id:o,issueType:n,description:"string"==typeof a.description?a.description:"",category:c?{id:"string"==typeof c.id?c.id:"",name:"string"==typeof c.name?c.name:""}:void 0},sentence:"string"==typeof e.sentence?e.sentence:void 0}}(a[e],e);
1if(!h)continue;let d=Math.max(0,Math.min(h.offset,n)),m=n-d,p=Math.max(0,Math.min(h.length,m));if(0===p||d>=n)continue;let f=t.substring(d,d+p),y=h.rule.id||h.ruleId||"unknown-".concat(e),k="".concat(y,"-").concat(d,"-").concat(p);if(i.has(k))continue;i.add(k);let b=h.rule.issueType||"unknown",w=function(e,t){let a=(e||"").toLowerCase(),s=(t||"").toUpperCase(),r=new Set(["grammar","spelling","misspelling","typos","typographical","confused_words","verb_agreement","subject_verb_agreement"]),o=new Set(["style","redundancy","word_choice","clarity","whitespace","punctuation","casing"]);return r.has(a)?"error":o.has(a)?"warning":s.includes("MORFOLOGIK")||s.includes("HUNSPELL")||s.includes("SPELLING")||s.includes("TYPOS")?"error":s.includes("STYLE")||s.includes("REDUNDANCY")?"warning":"info"}(b,y),E=h.replacements&&h.replacements.length>0?h.replacements[0].value:void 0,_=null==(c=h.replacements)?void 0:c.map(e=>e.value),R=h.message,v=h.shortMessage||h.message.substring(0,50)||"Error",M=function(e,t,a){let s={grammar:"ææ³ã¨ã©ã¼ãæ¤åºããã¾ããã",spelling:"ã¹ãã«ãã¹ãæ¤åºããã¾ããã",misspelling:"ã¹ãã«ãã¹ãæ¤åºããã¾ããã",typos:"ã¿ã¤ããã¹ãæ¤åºããã¾ããã",typographical:"表è¨ã®åé¡ãæ¤åºããã¾ããã",duplication:"åãèªãéè¤ãã¦ãã¾ãã",confused_words:"æ··åããããåèªã使ããã¦ãã¾ãã",verb_agreement:"åè©ã®ä¸è´ã«åé¡ãããã¾ãã",subject_verb_agreement:"主èªã¨åè©ã®ä¸è´ã«åé¡ãããã¾ãã",style:"ã¹ã¿ã¤ã«ã®æ¹åãææ¡ããã¦ãã¾ãã",redundancy:"åé·ãªè¡¨ç¾ã使ããã¦ãã¾ãã",word_choice:"ããé©åãªåèªã®é¸æãææ¡ããã¦ãã¾ãã",clarity:"ããæç¢ºãªè¡¨ç¾ãææ¡ããã¦ãã¾ãã",whitespace:"ã¹ãã¼ã¹ã®ä½¿ãæ¹ã確èªãã¦ãã ããã",punctuation:"å¥èªç¹ã®ä½¿ãæ¹ã確èªãã¦ãã ããã",casing:"大æåã»å°æåã®ä½¿ãæ¹ã確èªãã¦ãã ããã"}[e.toLowerCase()]||(t?"ã".concat(t,"ãã«åé¡ãæ¤åºããã¾ããã"):"åé¡ãæ¤åºããã¾ããã");return a?"".concat(s,' ä¿®æ£æ¡: "').concat(a,'"'):s}(b,f,E),{message:O,shortMessage:S}=function(e){let{message:t,shortMessage:a}=function(e){let t=(e.issueType||"").toLowerCase(),a=(e.ruleId||"").toUpperCase(),n="".concat(e.ltMessage," ").concat(e.ltShortMessage).trim();for(let e of s)if(a.includes(e.id))return{...e.ja,source:"ruleId"};for(let e of r)if(e.test(n))return{...e.ja,source:"messagePattern"};let i=o[t];return i?{...i,source:"issueType"}:a&&function(e){let t=e.toUpperCase();return!(t.includes("POSSESSIVE_APOSTROPHE")||t.includes("A_VS_AN")||t.includes("EN_A_VS_AN"))&&(t.includes("MORFOLOGIK")||t.includes("HUNSPELL")||t.includes("SPELLING")&&!t.includes("CONTRACTION"))}(a)?{message:"ã¹ãã«ãã¹ã®å¯è½æ§ãããã¾ã",shortMessage:"ã¹ãã«",source:"ruleHeuristic"}:e.errorText?{message:"ã".concat(e.errorText,"ãã«åé¡ãæ¤åºããã¾ãã"),shortMessage:"è¦ç¢ºèª",source:"fallback"}:{message:"åé¡ãæ¤åºããã¾ãã",shortMessage:"è¦ç¢ºèª",source:"fallback"}}(e);return{message:t,shortMessage:a}}({issueType:b,ruleId:y,ltMessage:R,ltShortMessage:v,errorText:f,japaneseExplanation:M,categoryId:null==(u=h.rule.category)?void 0:u.id}),T={id:k,offset:d,length:p,message:O,shortMessage:S,messageEn:R,shortMessageEn:v,severity:w,suggestion:E,suggestions:_,context:(null==(g=h.context)?void 0:g.text)||void 0,explanation:h.rule.description||void 0,issueType:b,japaneseExplanation:M,learningTip:{grammar:"åºæ¬çãªææ³ã«ã¼ã«ã復ç¿ãã¾ãããã",spelling:"ã¹ãã«ãã§ãã¯æ©è½ãæ´»ç¨ãã¾ãããã",misspelling:"ã¹ãã«ãã§ãã¯æ©è½ãæ´»ç¨ãã¾ãããã",typos:"å
¥åå¾ã«ããä¸åº¦è¦ç´ãã¦ã¿ã¾ãããã",verb_agreement:"主èªãåæ°ãè¤æ°ãã確èªãã¦ããåè©ãé¸ã³ã¾ãããã",subject_verb_agreement:"主èªã¨åè©ã®æ°ãä¸è´ãã¦ããã確èªãã¾ãããã",style:"ããèªç¶ãªè¡¨ç¾ãå¿ããã¾ãããã",word_choice:"æèã«åã£ãé©åãªåèªãé¸ã³ã¾ãããã"}[b.toLowerCase()]||"ç¹°ãè¿ãç·´ç¿ãã¦æ¹åãã¾ãããã",ruleId:y,detectionSource:"languagetool"};l.push(T)}return l}},97443:(e,t,a)=>{a.d(t,{f:()=>r});let s="transable_client_id";function r(){try{let e=localStorage.getItem(s);return e||(e="undefined"!=typeof crypto&&crypto.randomUUID?crypto.randomUUID():"".concat(Date.now(),"-").concat(Math.random().toString(36).substring(2,15)),localStorage.setItem(s,e)),e}catch(e){return console.error("Client IDåå¾ã¨ã©ã¼:",e),"temp-".concat(Date.now(),"-").concat(Math.random().toString(36).substring(2,15))}}},98802:(e,t,a)=>{a.d(t,{Mk:()=>c,Qs:()=>u,uo:()=>i});let s="proofreading_lt_ignored_words",r=new Set(["izakaya","konnyaku","ramen","sushi","sashimi","tempura","tofu","miso","wasabi","matcha","udon","soba","yakitori","onigiri","bento","okonomiyaki","takoyaki","gyoza","sake","shochu","karaoke","anime","manga","kimono","yukata","tatami","futon","origami","haiku","emoji","otaku","senpai","sensei","dojo","karate","judo","kendo","sumo","shinkansen","torii","onsen","ryokan","yen"].map(e=>
1e.toLowerCase())),o=new Set(["yamada","sato","satou","suzuki","tanaka","watanabe","takahashi","ito","itou","nakamura","kobayashi","kato","katou","yoshida","yamamoto","sasaki","yamaguchi","matsumoto","inoue","kimura","hayashi","shimizu","saito","saitou","yamazaki","mori","abe","ikeda","hashimoto","ishikawa","yamashita","nakajima","fujita","ogawa","goto","gotou","okada","hasegawa","murakami","kondo","kondou","ishii","sakamoto","endo","endou","aoki","fujii","nishimura","fukuda","ota","outa","miura","fujiwara","okamoto","matsuda","nakagawa","nakano","harada","ono","takeuchi","tamura","kaneko","wada","nakayama","ishida","ueda","morita","hara","shibata","sakai","kudo","kudou","yokoyama","miyazaki","miyamoto","uchida","takagi","ando","andou","taniguchi","ohno","matsui","maruyama","imai","takada","fujimoto","sugiyama","chiba","murata","hirano","otsuka","ootsuka","kubota","sakurai","nishida","shimada","kinoshita","nomura","tsuji","iwata","matsuo","kawaguchi","sugimoto","takeda","arai","kojima","maebashi","gunma","takasaki","kiryu","isesaki","tokyo","osaka","kyoto","yokohama","nagoya","sapporo","fukuoka","hiroshima","sendai","kobe","kawasaki","saitama","shizuoka","niigata","kanazawa","nara","nagasaki","kagoshima","okinawa","hokkaido","honshu","kyushu","shikoku","fuji","hakone","nikko","kamakura","asakusa","shibuya","shinjuku","akihabara","ueno","ginza","harajuku"].map(e=>e.toLowerCase()));function n(e){return e.trim().toLowerCase()}function i(e){let t=(e.issueType||"").toLowerCase();if("misspelling"===t||"spelling"===t||"typographical"===t)return!0;let a=(e.ruleId||"").toUpperCase();return a.includes("MORFOLOGIK")||a.includes("HUNSPELL")||a.includes("SPELLING")||a.includes("TYPOS")||a.includes("SPELLER")}function l(){try{let e=localStorage.getItem(s);if(!e)return[];let t=JSON.parse(e);if(!Array.isArray(t))return[];return t.filter(e=>"string"==typeof e).map(e=>n(e)).filter(Boolean)}catch(e){return[]}}function c(e){let t=n(e);if(!t)return;let a=new Set(l());a.add(t),localStorage.setItem(s,JSON.stringify([...a]))}function u(e,t,a){var s;let c=new Set((null!=(s=null==a?void 0:a.sessionIgnoredWords)?s:l()).map(e=>n(e))),u=[],g=[];for(let a of t){if("llm"===a.detectionSource||!i(a)){u.push(a);continue}let t=e.slice(a.offset,a.offset+a.length)||a.shortMessage||"";if(function(e){let t=n(e);return!!t&&r.has(t)}(t)){g.push({error:a,reason:"loanword_whitelist",span:t});continue}if(function(e){let t=n(e);return!!t&&o.has(t)}(t)){g.push({error:a,reason:"proper_name_whitelist",span:t});continue}if(c.has(n(t))){g.push({error:a,reason:"session_ignore",span:t});continue}u.push(a)}return{kept:u,filtered:g}}[...r,...o]}}]);
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.