-
-
Notifications
You must be signed in to change notification settings - Fork 416
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
8aaced9
commit 94826bc
Showing
12 changed files
with
219 additions
and
98 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,39 +1,38 @@ | ||
import { ISelectedTags } from './tags.model' | ||
import { IFirebaseUploadInfo } from 'src/components/FirebaseFileUploader/FirebaseFileUploader' | ||
import { IDbDoc } from './common.models' | ||
import { IConvertedFileMeta } from 'src/components/ImageInput/ImageInput' | ||
import { IUploadedFileMeta } from 'src/stores/storage' | ||
|
||
// By default all tutorial form input fields come as strings | ||
// The IHowto interface imposes the correct formats on fields | ||
// The IHowto interface can imposes the correct formats on fields | ||
// adds additional populated meta fields, and forces cover image | ||
export interface IHowto extends IHowtoFormInput { | ||
tutorial_cost: number | ||
cover_image: IFirebaseUploadInfo | ||
_created: Date | ||
_modified: Date | ||
export interface IHowto extends IHowtoFormInput, IDbDoc { | ||
cover_image: IUploadedFileMeta | ||
} | ||
|
||
export interface IHowtoStep { | ||
// *** NOTE legacy format only tracked urls - this will be removed once data upgraded | ||
// *** NOTE 2 - adding an '_animationKey' field to track when specific array element removed for | ||
images: IFirebaseUploadInfo[] | ||
images: IUploadedFileMeta[] | IConvertedFileMeta[] | ||
title: string | ||
text: string | ||
_animationKey?: string | ||
} | ||
|
||
export interface IHowtoFormInput { | ||
workspace_name: string | ||
cover_image: IFirebaseUploadInfo | null | ||
// *** NOTE legacy format only tracked urls - this will be removed once data upgraded | ||
// NOTE cover image input starts as convertedFileMeta but is transformed on upload | ||
cover_image: IUploadedFileMeta | IConvertedFileMeta[] | ||
// NOTE legacy format only tracked urls - this will be removed once data upgraded | ||
cover_image_url?: string | ||
tutorial_title: string | ||
tutorial_description: string | ||
difficulty_level: 'Easy' | 'Medium' | 'Hard' | 'Very Hard' | ||
tutorial_time: string | ||
tutorial_cost: any | ||
tutorial_extern_file_url: string | ||
tutorial_files: IFirebaseUploadInfo[] | ||
tutorial_files: IUploadedFileMeta[] | ||
steps: IHowtoStep[] | ||
id: string | ||
slug: string | ||
tags: ISelectedTags | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.