@@ -1025,11 +1025,24 @@ export const EXPORT_IMG_RATIO_OPTIONS: ReadonlyArray<ImageRatioOption> = [
10251025 SixteenByNineRatioOption
10261026] ;
10271027
1028+ export type ExportResolutionOption =
1029+ | keyof typeof RESOLUTIONS
1030+ | '1280x720'
1031+ | '1920x1080'
1032+ | '2560x1440'
1033+ | '3840x2160'
1034+ | '1600x900'
1035+ | '1024x768'
1036+ | '1280x960'
1037+ | '1600x1200'
1038+ | '1920x1440'
1039+ | '2048x1536' ;
1040+
10281041export type ImageResolutionOption = {
1029- id : keyof typeof RESOLUTIONS ;
1042+ id : ExportResolutionOption ;
10301043 label : string ;
10311044 available : boolean ;
1032- scale : number ;
1045+ scale ? : number ;
10331046 getSize : ( screenW : number , screenH : number ) => { width : number ; height : number } ;
10341047} ;
10351048
@@ -1055,9 +1068,90 @@ export const TwoXResolutionOption: ImageResolutionOption = {
10551068 } )
10561069} ;
10571070
1071+ // Fixed dimension options
1072+ export const Resolution1920x1080Option : ImageResolutionOption = {
1073+ id : '1920x1080' ,
1074+ label : '1920 × 1080 (16:9)' ,
1075+ available : true ,
1076+ getSize : ( ) => ( { width : 1920 , height : 1080 } )
1077+ } ;
1078+
1079+ export const Resolution1280x720Option : ImageResolutionOption = {
1080+ id : '1280x720' ,
1081+ label : '1280 × 720 (16:9)' ,
1082+ available : true ,
1083+ getSize : ( ) => ( { width : 1280 , height : 720 } )
1084+ } ;
1085+
1086+ export const Resolution2560x1440Option : ImageResolutionOption = {
1087+ id : '2560x1440' ,
1088+ label : '2560 × 1440 (16:9)' ,
1089+ available : true ,
1090+ getSize : ( ) => ( { width : 2560 , height : 1440 } )
1091+ } ;
1092+
1093+ export const Resolution3840x2160Option : ImageResolutionOption = {
1094+ id : '3840x2160' ,
1095+ label : '3840 × 2160 (16:9)' ,
1096+ available : true ,
1097+ getSize : ( ) => ( { width : 3840 , height : 2160 } )
1098+ } ;
1099+
1100+ export const Resolution1600x900Option : ImageResolutionOption = {
1101+ id : '1600x900' ,
1102+ label : '1600 × 900 (16:9)' ,
1103+ available : true ,
1104+ getSize : ( ) => ( { width : 1600 , height : 900 } )
1105+ } ;
1106+
1107+ export const Resolution1024x768Option : ImageResolutionOption = {
1108+ id : '1024x768' ,
1109+ label : '1024 × 768 (4:3)' ,
1110+ available : true ,
1111+ getSize : ( ) => ( { width : 1024 , height : 768 } )
1112+ } ;
1113+
1114+ export const Resolution1280x960Option : ImageResolutionOption = {
1115+ id : '1280x960' ,
1116+ label : '1280 × 960 (4:3)' ,
1117+ available : true ,
1118+ getSize : ( ) => ( { width : 1280 , height : 960 } )
1119+ } ;
1120+
1121+ export const Resolution1600x1200Option : ImageResolutionOption = {
1122+ id : '1600x1200' ,
1123+ label : '1600 × 1200 (4:3)' ,
1124+ available : true ,
1125+ getSize : ( ) => ( { width : 1600 , height : 1200 } )
1126+ } ;
1127+
1128+ export const Resolution1920x1440Option : ImageResolutionOption = {
1129+ id : '1920x1440' ,
1130+ label : '1920 × 1440 (4:3)' ,
1131+ available : true ,
1132+ getSize : ( ) => ( { width : 1920 , height : 1440 } )
1133+ } ;
1134+
1135+ export const Resolution2048x1536Option : ImageResolutionOption = {
1136+ id : '2048x1536' ,
1137+ label : '2048 × 1536 (4:3)' ,
1138+ available : true ,
1139+ getSize : ( ) => ( { width : 2048 , height : 1536 } )
1140+ } ;
1141+
10581142export const EXPORT_IMG_RESOLUTION_OPTIONS : ReadonlyArray < ImageResolutionOption > = [
10591143 OneXResolutionOption ,
1060- TwoXResolutionOption
1144+ TwoXResolutionOption ,
1145+ Resolution1280x720Option ,
1146+ Resolution1920x1080Option ,
1147+ Resolution2560x1440Option ,
1148+ Resolution3840x2160Option ,
1149+ Resolution1600x900Option ,
1150+ Resolution1024x768Option ,
1151+ Resolution1280x960Option ,
1152+ Resolution1600x1200Option ,
1153+ Resolution1920x1440Option ,
1154+ Resolution2048x1536Option
10611155] ;
10621156
10631157export const EXPORT_DATA_TYPE = keyMirror ( {
0 commit comments