import { SourceMapGenerator, RawSourceMap, SourceMapConsumer } from 'source-map-js'; import { k as Extracted, j as PostCSSOptions, h as StyleOptions, I as InternalStyleOptions, l as LoaderContext } from "../packem_shared/types.d-DbmFO7y3.js"; import { RollupLogger } from '@visulima/packem-share/utils'; import { Result } from 'postcss-load-config'; import { NapiResolveOptions } from 'oxc-resolver'; import 'cssnano'; import 'lightningcss'; import 'postcss'; import '@visulima/packem-share/types'; import 'sass'; import 'sass-embedded'; import 'stylus'; import 'rollup'; declare const arrayFmt: (array: string[]) => string; interface Concatenated { css: string; map: SourceMapGenerator; } declare const concat: (extracted: Extracted[]) => Promise; declare const loadModule: (moduleId: string, cwd: string, logger: RollupLogger) => Promise; interface Mode { emit: InternalStyleOptions["emit"]; extract: InternalStyleOptions["extract"]; inject: InternalStyleOptions["inject"]; inline: InternalStyleOptions["inline"]; } type PCSSOption = "parser" | "plugin" | "stringifier" | "syntax"; declare const inferModeOption: (mode: StyleOptions["mode"], logger?: Pick) => Mode; declare const inferOption: >(option: OptionInput, defaultValue: TDefine) => OptionType; declare const inferSourceMapOption: (sourceMap: StyleOptions["sourceMap"]) => LoaderContext["sourceMap"]; declare const inferHandlerOption: ; }>(option: T | boolean | undefined, alias: T["alias"]) => T | false; declare const ensurePCSSOption: (option: T | string, type: PCSSOption, cwd: string, logger: RollupLogger) => Promise; declare const ensurePCSSPlugins: (plugins: PostCSSOptions["plugins"], cwd: string, logger: RollupLogger) => Promise; type OptionInput = T | boolean | undefined; type OptionType> = TDefine | false | T; declare const resolve: (ids: string[], userOptions: ResolveOptions) => string; interface ResolveOptions extends NapiResolveOptions { baseDirs?: string[]; caller?: string; logger?: { debug?: (log: { [key: string]: unknown; message: string; }) => void; warn?: (log: { [key: string]: unknown; message: string; }) => void; }; } declare const safeId: (id: string, ...salt: string[]) => string; declare class MapModifier { private readonly map?; constructor(map?: RawSourceMap | string); modify(f: (m: RawSourceMap) => void): this; modifySources(op: (source: string) => string): this; resolve(directory?: string): this; relative(directory?: string): this; toObject(): RawSourceMap | undefined; toString(): string | undefined; toConsumer(): SourceMapConsumer | undefined; toCommentData(): string; toCommentFile(fileName: string): string; } declare const getMap: (code: string, id?: string) => string | undefined; declare const stripMap: (code: string) => string; declare const mm: (map?: RawSourceMap | string) => MapModifier; declare const hasModuleSpecifier: (url: string) => boolean; declare const getUrlOfPartial: (url: string) => string; declare const normalizeUrl: (url: string) => string; export { type ResolveOptions, arrayFmt, concat, ensurePCSSOption, ensurePCSSPlugins, getMap, getUrlOfPartial, hasModuleSpecifier, inferHandlerOption, inferModeOption, inferOption, inferSourceMapOption, loadModule, mm, normalizeUrl, resolve, safeId, stripMap };