Rename types.ts to types.d.ts
This commit is contained in:
201
src/types.d.ts
vendored
Normal file
201
src/types.d.ts
vendored
Normal file
@ -0,0 +1,201 @@
|
||||
import { AstroComponentFactory } from 'astro/dist/runtime/server';
|
||||
|
||||
export interface Post {
|
||||
id: string;
|
||||
slug: string;
|
||||
|
||||
publishDate: Date;
|
||||
title: string;
|
||||
description?: string;
|
||||
|
||||
image?: string;
|
||||
|
||||
canonical?: string | URL;
|
||||
permalink?: string;
|
||||
|
||||
draft?: boolean;
|
||||
|
||||
excerpt?: string;
|
||||
category?: string;
|
||||
tags?: Array<string>;
|
||||
author?: string;
|
||||
|
||||
Content: AstroComponentFactory;
|
||||
content?: string;
|
||||
|
||||
readingTime?: number;
|
||||
}
|
||||
|
||||
export interface MetaSEO {
|
||||
title?: string;
|
||||
description?: string;
|
||||
image?: string;
|
||||
|
||||
canonical?: string | URL;
|
||||
noindex?: boolean;
|
||||
nofollow?: boolean;
|
||||
|
||||
ogTitle?: string;
|
||||
ogType?: string;
|
||||
}
|
||||
|
||||
export interface Image {
|
||||
src: string;
|
||||
alt?: string;
|
||||
}
|
||||
|
||||
export interface Video {
|
||||
src: string;
|
||||
type?: string;
|
||||
}
|
||||
|
||||
export interface Widget {
|
||||
id?: string;
|
||||
isDark?: boolean;
|
||||
bg?: string;
|
||||
classes?: Record<string, string>;
|
||||
}
|
||||
|
||||
export interface Headline {
|
||||
title?: string;
|
||||
subtitle?: string;
|
||||
tagline?: string;
|
||||
classes?: Record<string, string>;
|
||||
}
|
||||
|
||||
interface TeamMember {
|
||||
name?: string;
|
||||
job?: string;
|
||||
image?: Image;
|
||||
socials?: Array<Social>;
|
||||
description?: string;
|
||||
classes?: Record<string, string>;
|
||||
}
|
||||
|
||||
interface Social {
|
||||
icon?: string;
|
||||
href?: string;
|
||||
}
|
||||
|
||||
export interface Stat {
|
||||
amount?: number;
|
||||
title?: string;
|
||||
icon?: string;
|
||||
}
|
||||
|
||||
export interface Item {
|
||||
title?: string;
|
||||
description?: string;
|
||||
icon?: string;
|
||||
classes?: Record<string, string>;
|
||||
callToAction?: CallToAction;
|
||||
image?: Image;
|
||||
}
|
||||
|
||||
export interface Price {
|
||||
title?: string;
|
||||
description?: string;
|
||||
price?: number;
|
||||
period?: string;
|
||||
items?: Array<Item>;
|
||||
callToAction?: CallToAction;
|
||||
hasRibbon?: boolean;
|
||||
ribbonTitle?: string;
|
||||
}
|
||||
|
||||
export interface Testimonial {
|
||||
title?: string;
|
||||
testimonial?: string;
|
||||
name?: string;
|
||||
job?: string;
|
||||
image?: Image;
|
||||
}
|
||||
|
||||
// COMPONENTS
|
||||
export interface CallToAction {
|
||||
targetBlank: boolean;
|
||||
text?: string;
|
||||
icon?: string;
|
||||
href?: string;
|
||||
classes?: Record<string, string>;
|
||||
}
|
||||
|
||||
export interface ItemGrid {
|
||||
items?: Array<Item>;
|
||||
columns?: number;
|
||||
defaultIcon?: string;
|
||||
classes?: Record<string, string>;
|
||||
}
|
||||
|
||||
export interface Collapse {
|
||||
iconUp?: string;
|
||||
iconDown?: string;
|
||||
items?: Array<Item>;
|
||||
columns?: number;
|
||||
classes?: Record<string, string>;
|
||||
}
|
||||
|
||||
// WIDGETS
|
||||
export interface Hero extends Headline, Widget {
|
||||
image?: Image;
|
||||
callToAction1?: CallToAction;
|
||||
callToAction2?: CallToAction;
|
||||
isReversed?: boolean;
|
||||
}
|
||||
|
||||
export interface Team extends Headline, Widget {
|
||||
team?: Array<TeamMember>;
|
||||
}
|
||||
|
||||
export interface Stats extends Headline, Widget {
|
||||
stats?: Array<Stat>;
|
||||
}
|
||||
|
||||
export interface Pricing extends Headline, Widget {
|
||||
prices?: Array<Price>;
|
||||
}
|
||||
|
||||
export interface Testimonials extends Headline, Widget {
|
||||
testimonials?: Array<Testimonial>;
|
||||
callToAction?: CallToAction;
|
||||
}
|
||||
|
||||
export interface Clients extends Headline, Widget {
|
||||
icons?: Array<string>;
|
||||
images?: Array<Image>;
|
||||
}
|
||||
|
||||
export interface Features extends Headline, Widget {
|
||||
image?: Image;
|
||||
video?: Video;
|
||||
items: Array<Item>;
|
||||
columns: number;
|
||||
callToAction1?: CallToAction;
|
||||
callToAction2?: CallToAction;
|
||||
isReversed?: boolean;
|
||||
}
|
||||
|
||||
export interface Faqs extends Headline, Widget {
|
||||
iconUp?: string;
|
||||
iconDown?: string;
|
||||
items?: Array<Item>;
|
||||
columns?: number;
|
||||
}
|
||||
|
||||
export interface Steps extends Headline, Widget {
|
||||
items: Array<{
|
||||
title: string;
|
||||
description?: string;
|
||||
icon?: string;
|
||||
classes?: Record<string, string>;
|
||||
}>;
|
||||
image?: string | any; // TODO: find HTMLElementProps
|
||||
isReversed?: boolean;
|
||||
}
|
||||
|
||||
export interface Content extends Headline, Widget {
|
||||
image?: string;
|
||||
items?: Array<Item>;
|
||||
columns?: number;
|
||||
isReversed?: boolean;
|
||||
}
|
Reference in New Issue
Block a user