import { z } from 'zod';

export type Environment = 'development' | 'test' | 'production';

export interface ConfigLoader {
  load(): Record<string, unknown>;
  readonly priority: number;
}

export interface ConfigManagerOptions {
  environment?: Environment;
  configPath?: string;
  loaders?: ConfigLoader[];
}

export type DeepPartial<T> = T extends object
  ? {
      [P in keyof T]?: DeepPartial<T[P]>;
    }
  : T;

export type ConfigSchema = z.ZodSchema<unknown>;

export interface ProviderConfig {
  name: string;
  enabled: boolean;
  [key: string]: unknown;
}
