change: split file into viewer and download
This commit is contained in:
parent
5d3cce3b8b
commit
a7ea081784
6 changed files with 56 additions and 21 deletions
|
@ -9,6 +9,7 @@ import type DynamicZoneFileDownload from "./dynamic-zone/fileDownload";
|
|||
import type DynamicZoneEmbedding from "./dynamic-zone/embedding";
|
||||
import type DynamicZoneSection from "./dynamic-zone/section";
|
||||
import type DynamicZoneSpacer from "./dynamic-zone/spacer";
|
||||
import type DynamicZoneFileViewer from "./dynamic-zone/fileViewer";
|
||||
|
||||
export default interface BaseComponent {
|
||||
__component: ComponentNames;
|
||||
|
@ -25,6 +26,7 @@ export type ComponentNames =
|
|||
| "dynamic-zone.full-image"
|
||||
| "dynamic-zone.dual-column-text"
|
||||
| "dynamic-zone.column-image-text"
|
||||
| "dynamic-zone.file-viewer"
|
||||
| "dynamic-zone.file-download"
|
||||
| "dynamic-zone.embedding";
|
||||
|
||||
|
@ -38,5 +40,6 @@ export type ComponentTypes =
|
|||
| DynamicZoneFullImage
|
||||
| DynamicZoneDualColumnText
|
||||
| DynamicZoneColumnImageText
|
||||
| DynamicZoneFileViewer
|
||||
| DynamicZoneFileDownload
|
||||
| DynamicZoneEmbedding;
|
||||
|
|
|
@ -3,6 +3,5 @@ import type BaseFile from "../baseFile";
|
|||
|
||||
export default interface DynamicZoneFileDownload extends BaseComponent {
|
||||
__component: "dynamic-zone.file-download";
|
||||
enable_download: boolean;
|
||||
file: BaseFile;
|
||||
}
|
||||
|
|
7
types/component/dynamic-zone/fileViewer.ts
Normal file
7
types/component/dynamic-zone/fileViewer.ts
Normal file
|
@ -0,0 +1,7 @@
|
|||
import type BaseComponent from "../baseComponent";
|
||||
import type BaseFile from "../baseFile";
|
||||
|
||||
export default interface DynamicZoneFileViewer extends BaseComponent {
|
||||
__component: "dynamic-zone.file-viewer";
|
||||
file: BaseFile;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue