Add SVG as acceptable file type in markdown (#1341)

This commit is contained in:
Caleb J. Acosta 2022-08-11 02:20:19 -05:00 committed by GitHub
parent 747fa38290
commit d59e2cf4b9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View file

@ -61,7 +61,7 @@ defmodule LivebookWeb.SessionLive do
|> prune_outputs()
|> prune_cell_sources()
|> allow_upload(:cell_image,
accept: ~w(.jpg .jpeg .png .gif),
accept: ~w(.jpg .jpeg .png .gif .svg),
max_entries: 1,
max_file_size: 5_000_000
)}

View file

@ -17,7 +17,7 @@ defmodule LivebookWeb.SessionLive.CellUploadComponent do
</h3>
<%= if @uploads.cell_image.errors != [] do %>
<div class="error-box">
Invalid image file. The image must be either GIF, JPEG, or PNG and cannot exceed 5MB in size.
Invalid image file. The image must be either GIF, JPEG, SVG or PNG and cannot exceed 5MB in size.
</div>
<% end %>
<%= if @error_message do %>