add sweetalert

This commit is contained in:
Alexis Gousseau 2022-04-04 14:30:39 +02:00
parent bab32d5aff
commit 16aadf2e05
6 changed files with 27 additions and 0 deletions

14
resources/js/alert.js vendored Normal file
View file

@ -0,0 +1,14 @@
// ES6 Modules or TypeScript
import Swal from 'sweetalert2'
Swal.fire({
width: 235,
imageUrl: '/loue/img/logo_bogt.png',
imageWidth: 200,
imageHeight: 200,
imageAlt: 'Logo Loué terre d\'action',
background: '#4b8764',
confirmButtonText: '<a href="https://www.loue.fr/article/Des-ruches-d-abeilles-dans-les-parcours-%c3%a0-volailles-de-Lou%c3%a9/a197.aspx" target="_blank">Je valide mon achat</a>',
confirmButtonColor: '#005621',
showCloseButton: true,
})

10
resources/themes/loue/css/_alert.scss vendored Normal file
View file

@ -0,0 +1,10 @@
.swal2-confirm{
border-radius: 0 !important;
box-shadow: 0px 5px 5px #00000069 !important;
a{
color: white;
text-transform: uppercase;
text-decoration: none;
font-family: MyriadProBold;
}
}

View file

@ -22,3 +22,4 @@ body {
@import "index";
@import "sub-page";
@import "alert";

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

View file

@ -101,6 +101,7 @@
</div>
</div>
<script src="{{ asset('js/alert.js') }}" type="text/javascript"></script>
<script src="{{ asset('js/ldcweb-cn.min.js') }}"></script>
<script>
window.LDCWebCN = new LdcwebCn({

1
webpack.mix.js vendored
View file

@ -15,6 +15,7 @@ const mix = require('laravel-mix');
BO
*/
mix.js('resources/js/app.js', 'public/js')
.js('resources/js/alert.js', 'public/js')
.sass('resources/sass/app.scss', 'public/css');
/*