Skip to content

Commit

Permalink
increasting size quantity and inserting information
Browse files Browse the repository at this point in the history
  • Loading branch information
devajmeireles committed Jan 25, 2024
1 parent 15c78c8 commit dfe5afa
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion app/Enums/Examples/Form/Upload.php
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ public function mount(): void
{
// We get all files and map the contents of the files
// to ensure a necessary structure for the component.
$this->photo = collect(File::allFiles(public_path('storage/images')))->map(fn (SplFileInfo $file) => [
$this->photos = collect(File::allFiles(public_path('storage/images')))->map(fn (SplFileInfo $file) => [
'name' => $file->getFilename(),
'extension' => $file->getExtension(),
'size' => $file->getSize(),
Expand Down
Binary file added public/assets/demo/laravel.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/assets/demo/livewire.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 6 additions & 1 deletion resources/views/documentation/form/upload.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@
<x-section title="Prepare the Usage" anchor="static-prepare-the-usage">
<p>
1. Use the Livewire component <x-block>mount</x-block> method to prepare and store
the files in a property that will be bind to the component into the Blade:
the files in a property that will be bind in the component Blade file:
</p>
<x-code :contents="$prepareStaticUsage" disable-copy />
<p>2. Prepare the Blade file of the component:</p>
Expand All @@ -110,6 +110,11 @@
<x-preview>
<livewire:documentation.form.upload.static />
</x-preview>
<p class="mt-4">
Keep in mind that in all this example we use existing images in the application,
however you can bring your existing images, for example, on S3. The code is
yours, you can do whatever you want.
</p>
</x-section>
<x-slot:navigation>
<x-slot:back>
Expand Down

0 comments on commit dfe5afa

Please sign in to comment.