
import { UDSCSSPruneVarsOptions } from "../css/theme.js";
import { AcceptedPlugin } from "postcss";

//#region ../css/dist/postcss/pruneVars.d.mts
//#region src/postcss/pruneVars.d.ts
interface UDSPruneVarsPlugin {
  postcssPlugin: 'uds-prune-vars';
  plugins: AcceptedPlugin[];
}
/**
 * Ready-to-use PostCSS plugin that removes unused UDS token CSS variables
 * (and any other unused CSS variables) from generated CSS.
 *
 * Runtime-configurable UDS variables and icon color variables are always
 * preserved. Additional variables can be preserved via the `safelist` option
 * using string prefixes or regular expressions.
 *
 * Must run after all CSS has been generated (e.g. after Tailwind).
 *
 * @example
 * ```js
 * // postcss.config.js
 * const { udsPruneVars } = require('@yahoo/uds/postcss');
 *
 * module.exports = {
 *   plugins: [udsPruneVars({ safelist: ['--app-theme-'] })],
 * };
 * ```
 */
declare const udsPruneVars: (options?: UDSCSSPruneVarsOptions) => UDSPruneVarsPlugin; //#endregion
//#endregion
export { type UDSPruneVarsPlugin, udsPruneVars };