You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
rpg-cards-ng/src/types.d.ts

51 lines
731 B
TypeScript

interface KV<V> {
[key: string]: V;
}
interface TextNode {
type: 'text';
text: string;
}
interface SimpleNode {
type: string;
}
interface ContentNode {
type: string;
content: (ContentNode | TextNode | SimpleNode)[];
attrs?: object;
}
interface Card {
id: string;
name: string;
count: number;
tags: string[];
icon: string;
content: (ContentNode | SimpleNode)[];
backIcon?: string;
color?: string;
}
interface Deck {
id: string;
name: string;
description: string;
color: string;
icon: string;
cards: Card[];
cardWidth: number;
cardHeight: number;
titleFontSize?: number;
}
interface Settings {
color: string;
}
interface StoredStuff {
decks: Deck[];
defaults: Settings;
}