mirror of
https://github.com/BookStackApp/BookStack.git
synced 2024-11-24 17:44:22 +08:00
85154fff69
Replaces the old suggestion of setting JS head 'window.uploadLimit' variable. This new env option will be used by back-end validation and front-end libs/logic too. Limits already likely exist within prod environments at a PHP and webserver level but this allows an app-level limit and centralises the option on the BookStack side into the .env Closes #3033
16 lines
659 B
PHP
16 lines
659 B
PHP
{{--
|
|
@url - URL to upload to.
|
|
@placeholder - Placeholder text
|
|
@successMessage
|
|
--}}
|
|
<div component="dropzone"
|
|
option:dropzone:url="{{ $url }}"
|
|
option:dropzone:success-message="{{ $successMessage ?? '' }}"
|
|
option:dropzone:remove-message="{{ trans('components.image_upload_remove') }}"
|
|
option:dropzone:upload-limit="{{ config('app.upload_limit') }}"
|
|
option:dropzone:upload-limit-message="{{ trans('errors.server_upload_limit') }}"
|
|
option:dropzone:timeout-message="{{ trans('errors.file_upload_timeout') }}"
|
|
|
|
class="dropzone-container text-center">
|
|
<button type="button" class="dz-message">{{ $placeholder }}</button>
|
|
</div> |