PageSourceSearch

https://www.ottohub.cn/assets/seigaApi-CaS7khpJ.js

js ottohub.cn collected 2026-10-06 13:14:40 UTC 2,341 bytes, 1 lines download raw bytes

1import{l as e,o as t,s as n,u as r}from"./apiResponse-C8fEm_-L.js";import{o as i}from"./blogMeta-BvgcPzkT.js";var a=`https://seiga.ottohub.cn`;function o(e){let t=Number(e);return Number.isFinite(t)?t:0}function s(e){return typeof e==`string`?e:e==null?void 0:String(e)}async function c(t,n){let r=await fetch(e(`/api/seiga/${t}`,{token:n}),{cache:`no-store`}),i=await r.json().catch(()=>null);if(i&&typeof i==`object`&&i.status===`error`)throw Error(typeof i.message==`string`?i.message:`获取静画详情失败`);if(!r.ok)throw Error(`获取静画详情失败`);let a=i&&typeof i==`object`&&i.data?i.data:i??{},c=Array.isArray(a.pages)?a.pages:[],l=[];for(let e of c){if(!e||typeof e!=`object`)continue;let t=e;l.push({page_no:o(t.page_no),original_url:s(t.original_url),preview_url:s(t.preview_url)})}return l.sort((e,t)=>e.page_no-t.page_no),{sid:o(a.sid)||o(t),uid:o(a.uid),title:s(a.title),description:s(a.description),page_count:o(a.page_count)||l.length||void 0,is_gore:o(a.is_gore)||void 0,is_fanwork:o(a.is_fanwork)||void 0,pages:l}}function l(e){return e.preview_url||e.original_url}function u(t,n){fetch(e(`/api/seiga/${encodeURIComponent(String(t))}`,{token:n}),{cache:`no-store`,keepalive:!0}).catch(()=>{})}function d(e){return`${a}/seiga/${encodeURIComponent(String(e))}`}function f(e){return e.coverPreviewUrl||e.coverUrl}function p(e){return i(e)}function m(e){let t=o(e.sid);if(!t)return null;let n=s(e.title)?.trim()||``;return{sid:t,uid:o(e.uid),title:n,coverUrl:s(e.cover_url),coverPreviewUrl:s(e.cover_preview_url)||s(e.cover_url),pageCount:o(e.page_count),width:o(e.width)||void 0,height:o(e.height)||void 0,isHall:p(e.is_hall),isFanwork:p(e.is_fanwork),isAi:p(e.is_ai),isGore:p(e.is_gore),collection:s(e.collection)?.trim()||void 0}}function h(e){if(!e||typeof e!=`object`)return[];let t=e,n=Array.isArray(t.seiga_list)?t.seiga_list:Array.isArray(t.data?.seiga_list)?t.data.seiga_list:[],r=[];for(let e of n){if(!e||typeof e!=`object`)continue;let t=m(e);t&&r.push(t)}return r}
1function g(t,n){return e(`/api/seiga/new`,r({offset:t,num:20,is_gore:0},n))}async function _(e,r,i=`加载静画失败`){try{let a=await fetch(g(e,r),{cache:`no-store`}),o=await t(a),s=n(a,o,{fallback:i});return s?{ok:!1,message:s}:{ok:!0,list:h(o)}}catch{return{ok:!1,message:i}}}export{f as a,u as i,_ as n,d as o,c as r,l as s,a as t};

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.