// @bun
var{defineProperty:D,getOwnPropertyNames:W,getOwnPropertyDescriptor:X}=Object,Y=Object.prototype.hasOwnProperty;function Z(q){return this[q]}var U=(q)=>{var j=(H??=new WeakMap).get(q),z;if(j)return j;if(j=D({},"__esModule",{value:!0}),q&&typeof q==="object"||typeof q==="function"){for(var A of W(q))if(!Y.call(j,A))D(j,A,{get:Z.bind(q,A),enumerable:!(z=X(q,A))||z.enumerable})}return H.set(q,j),j},H;var _=(q)=>q;function $(q,j){this[q]=_.bind(null,j)}var b=(q,j)=>{for(var z in j)D(q,z,{get:j[z],enumerable:!0,configurable:!0,set:$.bind(j,z)})};var I=(q,j)=>()=>(q&&(j=q(q=0)),j);var S=import.meta.require;function O(q){let j={...N,...q};return{enabled:j.enabled??!0,outDir:j.outDir??".stx/dist/story",storyMatch:j.storyMatch??["**/*.story.stx"],storyIgnored:j.storyIgnored??["**/node_modules/**","**/dist/**","**/.stx/**"],tree:{...L,...j.tree},theme:{title:"STX Components",defaultColorScheme:"auto",darkClass:"dark",...j.theme},responsivePresets:j.responsivePresets??J,backgroundPresets:j.backgroundPresets??K,autoApplyContrastColor:j.autoApplyContrastColor??!1,setupFile:j.setupFile,port:j.port??6006}}function v(){return{...N}}var J,K,L,N;var Q=I(()=>{J=[{label:"Mobile (Small)",width:320,height:568},{label:"Mobile (Medium)",width:375,height:667},{label:"Mobile (Large)",width:414,height:896},{label:"Tablet",width:768,height:1024},{label:"Laptop",width:1024},{label:"Desktop",width:1280},{label:"Desktop (Large)",width:1920}],K=[{label:"Transparent",color:"transparent",contrastColor:"#333"},{label:"White",color:"#ffffff",contrastColor:"#333"},{label:"Light Gray",color:"#f5f5f5",contrastColor:"#333"},{label:"Dark Gray",color:"#333333",contrastColor:"#fff"},{label:"Black",color:"#000000",contrastColor:"#fff"}],L={file:"title",order:"asc",groups:[]},N={enabled:!0,outDir:".stx/dist/story",storyMatch:["**/*.story.stx"],storyIgnored:["**/node_modules/**","**/dist/**","**/.stx/**"],tree:L,theme:{title:"STX Components",defaultColorScheme:"auto",darkClass:"dark"},responsivePresets:J,backgroundPresets:K,autoApplyContrastColor:!1,port:6006}});var F={};b(F,{updateContextTree:()=>B,updateContextStoryFiles:()=>k,createContext:()=>G});import w from"path";async function G(q){let j=q.root??process.cwd(),z;try{let E=await import(w.join(j,"stx.config.ts"));z=(E.default||E).story}catch{}let A={...z,...q.config},V=O(A);return{root:j,config:V,storyFiles:[],tree:void 0,mode:q.mode}}function k(q,j){q.storyFiles=j}function B(q,j){q.tree=j}var M=I(()=>{Q()});M();export{B as updateContextTree,k as updateContextStoryFiles,G as createContext};
