simple-links/src/types/config.d.ts
Fascinated b9093d75fe
Some checks failed
Publish Docker Image / docker (push) Failing after 33s
migrate to yml config (so I can comment the config)
2023-07-13 10:12:07 +01:00

58 lines
977 B
TypeScript

import { YAMLMap } from "js-yaml";
export interface Config {
configVersion: string;
name: string;
description: string;
avatar: string;
background: {
showBackground: boolean;
blur: boolean;
darken: {
enabled: boolean;
amount: number;
};
backgroundImage: string;
};
theme: string;
infoCard: {
transparency: number;
};
discord: {
id: string;
};
options: {
showSourceLink: boolean;
};
metadata: {
title: string;
description: string;
themeColor: string;
authors: {
name: string;
url: string;
}[];
};
links: {
title: string;
url: string;
icon: string;
color:
| {
normal: string;
}
| string;
}[];
socialLinks: {
icon: string;
color: string;
url: string;
}[];
}
// Parse the YAML content and convert it to the defined type
declare module "*.yml" {
const content: YAMLMap & Config;
export default content;
}