"use strict";var __defProp=Object.defineProperty,__getOwnPropDesc=Object.getOwnPropertyDescriptor,__getOwnPropNames=Object.getOwnPropertyNames,__hasOwnProp=Object.prototype.hasOwnProperty,__name=(target,value)=>__defProp(target,"name",{value:value,configurable:!0}),__export=(target,all)=>{for(var name in all)__defProp(target,name,{get:all[name],enumerable:!0})},__copyProps=(to,from,except,desc)=>{if(from&&"object"==typeof from||"function"==typeof from)for(let key of __getOwnPropNames(from))__hasOwnProp.call(to,key)||key===except||__defProp(to,key,{get:()=>from[key],enumerable:!(desc=__getOwnPropDesc(from,key))||desc.enumerable});return to},__toCommonJS=mod=>__copyProps(__defProp({},"__esModule",{value:!0}),mod),__async=(__this,__arguments,generator)=>new Promise((resolve,reject)=>{var fulfilled=value=>{try{step(generator.next(value))}catch(e){reject(e)}},rejected=value=>{try{step(generator.throw(value))}catch(e){reject(e)}},step=x=>x.done?resolve(x.value):Promise.resolve(x.value).then(fulfilled,rejected);step((generator=generator.apply(__this,__arguments)).next())}),meta_exports={};__export(meta_exports,{getMeta:()=>getMeta});var getMeta=__name(function(_0){return __async(this,arguments,function*({link:link,providerContext:providerContext}){try{const{axios:axios,cheerio:cheerio}=providerContext,url=link,data=(yield axios.get(url)).data,$=cheerio.load(data),title=($("h1").text().trim()||url.split("/").filter(Boolean).pop()||"").replace("Index of /","").replace(/\/$/,""),links=[],directLinks=[];$("table tbody tr").each((i,element)=>{const linkElement=$(element).find("td:first-child a"),itemTitle=linkElement.text().trim(),itemLink=linkElement.attr("href");if(itemTitle&&itemLink&&"../"!==itemTitle&&"Parent Directory"!==itemTitle){const fullLink=itemLink;if(itemTitle.endsWith("/")){const cleanTitle=itemTitle.replace(/\/$/,"");links.push({episodesLink:link+itemLink,title:cleanTitle})}else(itemTitle.includes(".mp4")||itemTitle.includes(".mkv")||itemTitle.includes(".avi")||itemTitle.includes(".mov"))&&directLinks.push({title:itemTitle,link:fullLink})}}),directLinks.length>0&&links.push({title:title+" (Direct Files)",directLinks:directLinks});const type=links.some(link2=>{var _a,_b;return(null==(_a=link2.episodesLink)?void 0:_a.includes("Season"))||(null==(_b=link2.episodesLink)?void 0:_b.includes("S0"))})||directLinks.length>1?"series":"movie";return{title:title,synopsis:"Content from 111477.xyz directory",image:`https://placehold.jp/23/000000/ffffff/300x450.png?text=${encodeURIComponent(title)}&css=%7B%22background%22%3A%22%20-webkit-gradient(linear%2C%20left%20bottom%2C%20left%20top%2C%20from(%233f3b3b)%2C%20to(%23000000))%22%2C%22text-transform%22%3A%22%20capitalize%22%7D`,imdbId:"",type:type,linkList:links}}catch(err){return console.error("111477 meta error:",err),{title:"",synopsis:"",image:"",imdbId:"",type:"movie",linkList:[]}}})},"getMeta");exports.getMeta=getMeta;