Skip to content

Commit

Permalink
perf(theme): add detail pages interface
Browse files Browse the repository at this point in the history
  • Loading branch information
wibus-wee committed Aug 13, 2022
1 parent 217b35c commit 00be7c8
Showing 1 changed file with 18 additions and 2 deletions.
20 changes: 18 additions & 2 deletions src/modules/theme/theme.interface.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,11 @@
* @author: Wibus
* @Date: 2022-08-13 23:14:55
* @LastEditors: Wibus
* @LastEditTime: 2022-08-13 23:33:06
* @LastEditTime: 2022-08-13 23:42:37
* Coding With IU
*/

import { Aggregate } from "mongoose";
import { CategoryModel } from "../category/category.model";
import { SiteDto, ThemeDto, UrlsDto } from "../configs/configs.dto";
import { PageModel } from "../page/page.model";
Expand All @@ -28,7 +29,22 @@ interface ConfigsThemeInterface {
export interface ThemeBasicInterface {
site: SiteThemeInterface, // 网站变量
configs: ConfigsThemeInterface, // 网站配置
page: PostModel | PageModel, // 针对该页面的内容
path: string, // 页面路径
url: string, // 页面url
}

export interface IndexThemeInterface extends ThemeBasicInterface {
aggregate: Aggregate<PostModel | PageModel>, // 当前页面的文章列表
}

export interface PostThemeInterface extends ThemeBasicInterface {
page: PostModel, // 针对该页面的内容
}

export interface PageThemeInterface extends ThemeBasicInterface {
page: PageModel, // 针对该页面的内容
}

export interface CategoryThemeInterface extends ThemeBasicInterface {
page: CategoryModel, // 针对该页面的内容
}

0 comments on commit 00be7c8

Please sign in to comment.