Download the PHP package brucelampson/laravel-spark-camera without Composer
On this page you can find all versions of the php package brucelampson/laravel-spark-camera. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download brucelampson/laravel-spark-camera
More information about brucelampson/laravel-spark-camera
Files in brucelampson/laravel-spark-camera
Package laravel-spark-camera
Short Description Profile photo camera support for Laravel Spark.
License MIT
Informations about the package laravel-spark-camera
Profile Photo Camera support for Laravel Spark
This package adds support for capturing images from your computer or phone camera.
Installation
-
Run
composer require eusebiu/laravel-spark-camera
-
Add
Eusebiu\LaravelSparkCamera\CameraServiceProvider::class
to yourproviders
array inconfig/app.php
-
Run
php artisan vendor:publish --provider="Eusebiu\LaravelSparkCamera\CameraServiceProvider" --tag=assets
-
Edit
resources/views/vendor/spark/settings/profile/update-profile-photo.blade.php
:- Add
@include('camera::camera-modal')
right before closing the last div. - Add the Camera button
<button type="button" class="btn btn-primary" :disabled="form.busy" @click="openCamera">Camera</button>
. - It should look like this.
- Add
-
Edit
resources/assets/js/spark-components/settings/profile/update-profile-photo.js
:- Add
var camera = require('./update-profile-photo-camera');
at the top. - Change the
mixins
option tomixins: [base, camera]
.
- Add
-
Run
npm install --save webcamjs
-
Run
npm run dev
- Edit
resources/sass/app.scss
and add the following css
This package uses WebcamJS, so if you want to configure it, overide the
configureWebcamjs
method in yourupdate-profile-photo.js
file.