-
Notifications
You must be signed in to change notification settings - Fork 9
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
1e6ec9e
commit 9f538d8
Showing
15 changed files
with
322 additions
and
120 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
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 |
---|---|---|
@@ -0,0 +1,5 @@ | ||
export function removeUndefinedAndNullFields<T>(value: Partial<T>): Partial<T> { | ||
return Object.fromEntries(Object.entries(value).filter(([, value]) => (value ?? undefined) !== undefined)) as Partial< | ||
T | ||
>; | ||
} |
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,36 +1,34 @@ | ||
import { UploadWidgetLocale } from "@bytescale/upload-widget/modules/locales/UploadWidgetLocale"; | ||
|
||
export const UploaderLocaleEnUs: UploadWidgetLocale = { | ||
"error!": "Error!", | ||
"done": "Done", | ||
"addAnotherFile": "Add another file...", | ||
"addAnotherImage": "Add another image...", | ||
"cancel": "cancel", | ||
"cancelInPreviewWindow": "Cancel", | ||
"cancelled!": "cancelled", | ||
"continue": "Continue", | ||
"customValidationFailed": "Failed to validate file.", | ||
"crop": "Crop", | ||
"finish": "Finished", | ||
"finishIcon": true, | ||
"image": "Image", | ||
"maxFilesReached": "Maximum number of files:", | ||
"maxImagesReached": "Maximum number of images:", | ||
"maxSize": "File size limit:", | ||
"next": "Next", | ||
"of": "of", | ||
"orDragDropFile": "...or drag and drop a file.", | ||
"orDragDropFiles": "...or drag and drop files.", | ||
"orDragDropImage": "...or drag and drop an image.", | ||
"orDragDropImages": "...or drag and drop images.", | ||
"pleaseWait": "Please wait...", | ||
"removed!": "removed", | ||
"remove": "remove", | ||
"skip": "Skip", | ||
"unsupportedFileType": "File type not supported.", | ||
"uploadFile": "Upload a File", | ||
"uploadFiles": "Upload a File", // We've now chosen to use singular tense for the upload button. | ||
"uploadImage": "Upload an Image", | ||
"uploadImages": "Upload an Image", // We've now chosen to use singular tense for the upload button. | ||
"processingFile": "Processing file..." | ||
export const UploadWidgetLocaleEnUs: UploadWidgetLocale = { | ||
addAnotherFileBtn: "Add another file...", | ||
addAnotherImageBtn: "Add another image...", | ||
cancelBtn: "cancel", | ||
cancelBtnClicked: "cancelled", | ||
cancelPreviewBtn: "Cancel", | ||
continueBtn: "Continue", | ||
cropBtn: "Crop", | ||
customValidationFailed: "Failed to validate file.", | ||
doneBtn: "Done", | ||
fileSizeLimitPrefix: "File size limit:", | ||
finishBtn: "Finished", | ||
finishBtnIcon: true, | ||
imageCropNumberPrefix: "Image", | ||
maxFilesReachedPrefix: "Maximum number of files:", | ||
maxImagesReachedPrefix: "Maximum number of images:", | ||
orDragDropFile: "...or drag and drop a file.", | ||
orDragDropFileMulti: "...or drag and drop files.", | ||
orDragDropImage: "...or drag and drop an image.", | ||
orDragDropImageMulti: "...or drag and drop images.", | ||
processingFile: "Processing file...", | ||
removeBtn: "remove", | ||
removeBtnClicked: "removed", | ||
submitBtnError: "Error!", | ||
submitBtnLoading: "Please wait...", | ||
unsupportedFileType: "File type not supported.", | ||
uploadFileBtn: "Upload a File", | ||
uploadFileMultiBtn: "Upload a File", // We support differentiation even though our default locale does not. | ||
uploadImageBtn: "Upload an Image", | ||
uploadImageMultiBtn: "Upload an Image", // We support differentiation even though our default locale does not. | ||
xOfY: "of" | ||
}; |
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,34 +1,32 @@ | ||
export interface UploadWidgetLocale { | ||
"addAnotherFile": string; | ||
"addAnotherImage": string; | ||
"cancel": string; | ||
"cancelInPreviewWindow": string; | ||
"cancelled!": string; | ||
"continue": string; | ||
"crop": string; | ||
"customValidationFailed": string; | ||
"done": string; | ||
"error!": string; | ||
"finish": string; | ||
"finishIcon": boolean; | ||
"image": string; | ||
"maxFilesReached": string; | ||
"maxImagesReached": string; | ||
"maxSize": string; | ||
"next": string; | ||
"of": string; | ||
"orDragDropFile": string; | ||
"orDragDropFiles": string; | ||
"orDragDropImage": string; | ||
"orDragDropImages": string; | ||
"pleaseWait": string; | ||
"processingFile": string; | ||
"remove": string; | ||
"removed!": string; | ||
"skip": string; | ||
"unsupportedFileType": string; | ||
"uploadFile": string; | ||
"uploadFiles": string; | ||
"uploadImage": string; | ||
"uploadImages": string; | ||
addAnotherFileBtn: string; | ||
addAnotherImageBtn: string; | ||
cancelBtn: string; | ||
cancelBtnClicked: string; | ||
cancelPreviewBtn: string; | ||
continueBtn: string; | ||
cropBtn: string; | ||
customValidationFailed: string; | ||
doneBtn: string; | ||
fileSizeLimitPrefix: string; | ||
finishBtn: string; | ||
finishBtnIcon: boolean; | ||
imageCropNumberPrefix: string; | ||
maxFilesReachedPrefix: string; | ||
maxImagesReachedPrefix: string; | ||
orDragDropFile: string; | ||
orDragDropFileMulti: string; | ||
orDragDropImage: string; | ||
orDragDropImageMulti: string; | ||
processingFile: string; | ||
removeBtn: string; | ||
removeBtnClicked: string; | ||
submitBtnError: string; | ||
submitBtnLoading: string; | ||
unsupportedFileType: string; | ||
uploadFileBtn: string; | ||
uploadFileMultiBtn: string; | ||
uploadImageBtn: string; | ||
uploadImageMultiBtn: string; | ||
xOfY: string; | ||
} |
Oops, something went wrong.