fix types nesting (#7914)

`Partial` is only 1 level deep. We don't want it to be recursively deep,
that's for the plugin itself to decide. But the parts under `theme`
should all be optional.
This commit is contained in:
Robin Malfait 2022-03-22 11:53:40 +01:00 committed by GitHub
parent c6b3f96f85
commit 949bcb3548
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

23
types/config.d.ts vendored
View File

@ -304,19 +304,20 @@ interface RequiredConfig {
}
interface OptionalConfig {
important: ImportantConfig
prefix: PrefixConfig
separator: SeparatorConfig
safelist: SafelistConfig
presets: PresetsConfig
future: FutureConfig
experimental: ExperimentalConfig
darkMode: DarkModeConfig
theme: ThemeConfig
corePlugins: CorePluginsConfig
plugins: PluginsConfig
important: Partial<ImportantConfig>
prefix: Partial<PrefixConfig>
separator: Partial<SeparatorConfig>
safelist: Partial<SafelistConfig>
presets: Partial<PresetsConfig>
future: Partial<FutureConfig>
experimental: Partial<ExperimentalConfig>
darkMode: Partial<DarkModeConfig>
theme: Partial<ThemeConfig>
corePlugins: Partial<CorePluginsConfig>
plugins: Partial<PluginsConfig>
/** Custom */
[key: string]: any
}
export type Config = RequiredConfig & Partial<OptionalConfig>