@lobehub/ui
Version:
Lobe UI is an open-source UI component library for building AIGC web apps
1 lines • 749 B
Source Map (JSON)
{"version":3,"file":"width.mjs","names":[],"sources":["../../../src/dashboard/FilterSidebar/width.ts"],"sourcesContent":["const MIN_WIDTH = 200;\nconst MAX_WIDTH = 480;\n\nexport function clampSidebarWidth(width: number, fallback: number) {\n if (!Number.isFinite(width)) return fallback;\n return Math.min(MAX_WIDTH, Math.max(MIN_WIDTH, Math.round(width)));\n}\n\nexport const sidebarWidth = {\n collapse: 80,\n max: MAX_WIDTH,\n min: MIN_WIDTH,\n narrow: 264,\n wide: 300,\n};\n"],"mappings":";AAAA,MAAM,YAAY;AAClB,MAAM,YAAY;AAElB,SAAgB,kBAAkB,OAAe,UAAkB;CACjE,IAAI,CAAC,OAAO,SAAS,KAAK,GAAG,OAAO;CACpC,OAAO,KAAK,IAAI,WAAW,KAAK,IAAI,WAAW,KAAK,MAAM,KAAK,CAAC,CAAC;AACnE;AAEA,MAAa,eAAe;CAC1B,UAAU;CACV,KAAK;CACL,KAAK;CACL,QAAQ;CACR,MAAM;AACR"}