Skip to content

Commit

Permalink
webp image selection
Browse files Browse the repository at this point in the history
  • Loading branch information
feruzm committed Dec 3, 2023
1 parent 4939186 commit acd16f4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ export const DeckThreadsFormToolbarImagePicker = ({ onAddImage }: Props) => {

const checkFile = (filename: string) => {
const filenameLow = filename.toLowerCase();
return ["jpg", "jpeg", "gif", "png"].some((el) => filenameLow.endsWith(el));
return ["jpg", "jpeg", "gif", "png", "webp"].some((el) => filenameLow.endsWith(el));
};

const fileInputChanged = (e: React.ChangeEvent<HTMLInputElement>): void => {
Expand Down
2 changes: 1 addition & 1 deletion src/common/components/editor-toolbar/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,7 @@ export class EditorToolbar extends Component<Props> {

checkFile = (filename: string) => {
const filenameLow = filename.toLowerCase();
return ["jpg", "jpeg", "gif", "png"].some((el) => filenameLow.endsWith(el));
return ["jpg", "jpeg", "gif", "png", "webp"].some((el) => filenameLow.endsWith(el));
};

render() {
Expand Down

0 comments on commit acd16f4

Please sign in to comment.