PageSourceSearch

https://mediafilm.ca/_nuxt/BViQQ4Sr.js

js mediafilm.ca collected 2026-10-02 06:07:27 UTC 3,922 bytes, 1 lines download raw bytes

1import{M as g,T as v,A as y,L as b,C as w,P}from"./Bck-fsQl.js";import{a as T}from"./L4Gp7wxG.js";function m(e){return{title:e.title,poster:e.poster,picture:e.picture,visible:e.visible,year:e.year,id:e.id,mfi_url:e.mfi_url,cote:e.cote,date_updated:e.date_updated,summary:e.summary_synopsis}}async function k(e){const{locale:i,sdk:o,sort:s,filter:r,q:t,attributesToSearchOn:a,fields:n=["title","mfi_url","poster","picture","year","id","cote","summary_synopsis","realisator","visible"],offset:d,matchingStrategy:c,limit:u,transform:h}=e,l=g[i];if(!l)throw new Error("Unable to get a movies index for the given locale");return await o.api.v1.mfi.search.indexes.indexUid.run.post({params:{index_uid:l},body:{attributesToRetrieve:n,filter:r,matchingStrategy:c,...t&&{q:t},...a&&{attributesToSearchOn:a},...s&&{sort:[s]},...e.pagination&&{hitsPerPage:e.pagination.hitsPerPage,page:e.pagination.page},...d&&{offset:d},...u&&{limit:u}}}).then(f=>{const p=f.data;return{data:(p.hits??[]).map(x=>h?h(x):m(x)),totalPages:p.totalPages,page:p.page,totalHits:p.totalHits,estimatedTotalHits:p.estimatedTotalHits}})}async function R(e){const{locale:i,sdk:o,sort:s,filter:r,queries:t,attributesToSearchOn:a,fields:n=["title","mfi_url","poster","picture","year","id","cote","visible"],offset:d,matchingStrategy:c,limit:u}=e,h=g[i];if(!h)throw new Error("Unable to get a movies index for the given locale");return await o.api.v1.mfi.search.advancedSearch.post({body:{index:h,attributesToRetrieve:n,filter:r,searchQueries:T(t),matchingStrategy:c,...a&&{attributesToSearchOn:a},...s&&{sort:[s]},...u&&{limit:u},...d&&{offset:d},page:e.pagination??[]}}).then(l=>{const f=l.data;return{data:f.hits.map(p=>m(p)),pagesInfo:f.pagesInfo}})}async function A(e){const{locale:i,sdk:o,query:s,limit:r=1e3}=e,t={movies:g[i],contacts:w[i],articles:y[i],lists:b[i]};for(const a in t)if(!t[a])throw new Error(`Unable to get a ${a} index for the given locale`);return await o.api.v1.mfi.search.multiRun.post({body:{q:s,locale:i,limit:r}}).then(a=>{const n=a.data,d=[],c=[],u=[],h=[];if(n.results){for(const l of n.results)switch(l.indexUid){case t.movies:d.push(...l.hits.map(m));break;case t.articles:u.push(...l.hits);break;case t.contacts:c.push(...l.hits);break;case t.lists:h.push(...l.hits);break}return{movies:d,articles:u,contacts:c,lists:h}}else throw new Error("Got unexpected response from the multi search endpoint.")})}async function I(e){const{locale:i,sdk:o,sort:s,filter:r,limit:t,offset:a}=e,n=y[i];if(!n)throw new Error("Unable to get an article index for the given locale");return await o.api.v1.mfi.search.indexes.indexUid.run.post({params:{index_uid:n},body:{filter:r,...s&&{sort:[s]},...e.pagination&&{hitsPerPage:e.pagination.hitsPerPage,page:e.pagination.page},...a&&{offset:a},...t&&{limit:t}}}).then(d=>{const c=d.data;return{data:c.hits??[],totalPages:c.totalPages,page:c.page,totalHits:c.totalHits,estimatedTotalHits:c.estimatedTotalHits}})}async function M(e){const{locale:i,sdk:o,sort:s,filter:r}=e,t=v[i];if(!t)throw new Error("Unable to get a TV schedule index for the given locale");return await o.api.v1.mfi.search.indexes.indexUid.run.post({params:{index_uid:t},body:{filter:r,...s&&{sort:Array.isArray(s)?s:[s]},...e.pagination&&{hitsPerPage:e.pagination.hitsPerPage,page:e.pagination.page}}}).then(a=>{const n=a.data;return{data:n.hits??[],totalPages:n.totalPages,page:n.page,totalHits:n.totalHits,estimatedTotalHits:n.estimatedTotalHits}})}async function S(e){const{sdk:i}=e;return await i.api.v1.mfi.search.indexes.indexUid.run.post({params:{index_uid:"channels"},body:{limit:99999}}).then(o=>o.data.hits)}async function E(e){const{sdk:i,locale:o,limit:s=5}=e,r=P[o];if(!r)throw new Error("Unable to get a movies index for the given locale");return await i.api.v1.mfi.search.indexes.indexUid.run.post({params:{index_uid:r},body:{limit:s}}).then(t=>t.data.hits)}export{k as a,M as b,I as c,R as d,A as e,S as f,E 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.