2022-01-09 08:35:28 -08:00
|
|
|
const mix = require("laravel-mix");
|
2017-05-31 12:34:05 -07:00
|
|
|
|
2020-04-27 22:41:33 -07:00
|
|
|
// This generates a file called app.css, which we use
|
|
|
|
// later on to build all.css
|
2017-05-31 12:34:05 -07:00
|
|
|
mix
|
2022-01-09 08:35:28 -08:00
|
|
|
.options({
|
|
|
|
processCssUrls: false,
|
|
|
|
processFontUrls: true,
|
|
|
|
clearConsole: false,
|
|
|
|
})
|
|
|
|
.less("./node_modules/admin-lte/build/less/AdminLTE.less", "css/build")
|
|
|
|
.less("./resources/assets/less/app.less", "css/build")
|
|
|
|
.less("./resources/assets/less/overrides.less", "css/build")
|
|
|
|
.styles(
|
|
|
|
[
|
2022-07-07 14:22:08 -07:00
|
|
|
|
2022-01-09 08:35:28 -08:00
|
|
|
"./node_modules/bootstrap/dist/css/bootstrap.css",
|
2022-07-07 14:22:08 -07:00
|
|
|
"./node_modules/@fortawesome/fontawesome-free/css/all.css",
|
2022-01-09 08:35:28 -08:00
|
|
|
"./public/css/build/AdminLTE.css",
|
|
|
|
"./node_modules/bootstrap-datepicker/dist/css/bootstrap-datepicker.standalone.css",
|
|
|
|
"./node_modules/bootstrap-colorpicker/dist/css/bootstrap-colorpicker.css",
|
|
|
|
"./node_modules/blueimp-file-upload/css/jquery.fileupload.css",
|
|
|
|
"./node_modules/blueimp-file-upload/css/jquery.fileupload-ui.css",
|
|
|
|
"./node_modules/ekko-lightbox/dist/ekko-lightbox.css",
|
|
|
|
"./node_modules/bootstrap-table/dist/bootstrap-table.css",
|
|
|
|
"./public/css/build/app.css",
|
|
|
|
"./node_modules/select2/dist/css/select2.css",
|
|
|
|
"./public/css/build/overrides.css",
|
|
|
|
],
|
|
|
|
"./public/css/dist/all.css"
|
|
|
|
)
|
|
|
|
.version();
|
|
|
|
|
2020-04-27 22:41:33 -07:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Copy, minify and version signature-pad.css
|
|
|
|
*/
|
|
|
|
mix
|
2022-01-09 08:35:28 -08:00
|
|
|
.copy("./resources/assets/css/signature-pad.css", "./public/css/dist")
|
|
|
|
.minify("./public/css/dist/signature-pad.css");
|
2017-05-31 12:34:05 -07:00
|
|
|
|
2022-07-07 14:22:08 -07:00
|
|
|
/**
|
|
|
|
* Copy, minify and version signature-pad.css
|
|
|
|
*/
|
|
|
|
mix
|
|
|
|
.copy("./node_modules/@fortawesome/fontawesome-free/webfonts", "./public/css/webfonts")
|
|
|
|
|
2024-07-08 07:12:37 -07:00
|
|
|
/**
|
|
|
|
* Copy BS tables js file
|
|
|
|
*/
|
|
|
|
mix
|
|
|
|
.copy( './node_modules/bootstrap-table/dist/bootstrap-table-locale-all.min.js', 'public/js/dist' )
|
|
|
|
|
2020-04-27 22:41:33 -07:00
|
|
|
// Combine main SnipeIT JS files
|
2022-01-09 08:35:28 -08:00
|
|
|
mix
|
|
|
|
.js(
|
2020-04-27 22:41:33 -07:00
|
|
|
[
|
2023-12-12 13:49:57 -08:00
|
|
|
"./resources/assets/js/snipeit.js", //this is the actual Snipe-IT JS - require()s bootstrap.js
|
2022-01-09 08:35:28 -08:00
|
|
|
"./resources/assets/js/snipeit_modals.js",
|
2020-04-27 22:41:33 -07:00
|
|
|
],
|
2022-01-09 08:35:28 -08:00
|
|
|
"./public/js/build/app.js" //because of compiling - this does not work very well :(
|
|
|
|
)
|
2020-03-28 00:08:21 -07:00
|
|
|
|
2020-04-27 22:41:33 -07:00
|
|
|
// Convert the skins to CSS
|
2022-01-09 08:35:28 -08:00
|
|
|
mix.less(
|
|
|
|
"./resources/assets/less/skins/skin-blue.less",
|
2023-05-01 18:05:06 -07:00
|
|
|
"css/dist/skins",
|
2022-01-09 08:35:28 -08:00
|
|
|
);
|
|
|
|
mix.less(
|
|
|
|
"./resources/assets/less/skins/skin-red.less",
|
2023-05-01 18:05:06 -07:00
|
|
|
"css/dist/skins",
|
2022-01-09 08:35:28 -08:00
|
|
|
);
|
|
|
|
mix.less(
|
|
|
|
"./resources/assets/less/skins/skin-contrast.less",
|
2023-05-01 18:05:06 -07:00
|
|
|
"css/dist/skins",
|
2022-01-09 08:35:28 -08:00
|
|
|
);
|
|
|
|
mix.less(
|
|
|
|
"./resources/assets/less/skins/skin-green.less",
|
2023-05-01 18:05:06 -07:00
|
|
|
"css/dist/skins",
|
2022-01-09 08:35:28 -08:00
|
|
|
);
|
|
|
|
mix.less(
|
|
|
|
"./resources/assets/less/skins/skin-green-dark.less",
|
2023-05-01 18:05:06 -07:00
|
|
|
"css/dist/skins",
|
2022-01-09 08:35:28 -08:00
|
|
|
);
|
|
|
|
mix.less(
|
|
|
|
"./resources/assets/less/skins/skin-black.less",
|
2023-05-01 18:05:06 -07:00
|
|
|
"css/dist/skins",
|
2022-01-09 08:35:28 -08:00
|
|
|
);
|
|
|
|
mix.less(
|
|
|
|
"./resources/assets/less/skins/skin-black-dark.less",
|
2023-05-01 18:05:06 -07:00
|
|
|
"css/dist/skins",
|
2022-01-09 08:35:28 -08:00
|
|
|
);
|
|
|
|
mix.less(
|
|
|
|
"./resources/assets/less/skins/skin-red-dark.less",
|
2023-05-01 18:05:06 -07:00
|
|
|
"css/dist/skins",
|
2022-01-09 08:35:28 -08:00
|
|
|
);
|
|
|
|
mix.less(
|
|
|
|
"./resources/assets/less/skins/skin-purple.less",
|
2023-05-01 18:05:06 -07:00
|
|
|
"css/dist/skins",
|
2022-01-09 08:35:28 -08:00
|
|
|
);
|
|
|
|
mix.less(
|
|
|
|
"./resources/assets/less/skins/skin-purple-dark.less",
|
2023-05-01 18:05:06 -07:00
|
|
|
"css/dist/skins",
|
2022-01-09 08:35:28 -08:00
|
|
|
);
|
|
|
|
mix.less(
|
|
|
|
"./resources/assets/less/skins/skin-yellow.less",
|
2023-05-01 18:05:06 -07:00
|
|
|
"css/dist/skins",
|
2022-01-09 08:35:28 -08:00
|
|
|
);
|
|
|
|
mix.less(
|
|
|
|
"./resources/assets/less/skins/skin-yellow-dark.less",
|
2023-05-01 18:05:06 -07:00
|
|
|
"css/dist/skins",
|
2022-01-09 08:35:28 -08:00
|
|
|
);
|
|
|
|
mix.less(
|
|
|
|
"./resources/assets/less/skins/skin-blue-dark.less",
|
2023-05-01 18:05:06 -07:00
|
|
|
"css/dist/skins",
|
2022-01-09 08:35:28 -08:00
|
|
|
);
|
|
|
|
mix.less(
|
|
|
|
"./resources/assets/less/skins/skin-orange-dark.less",
|
2023-05-01 18:05:06 -07:00
|
|
|
"css/dist/skins",
|
2022-01-09 08:35:28 -08:00
|
|
|
);
|
|
|
|
mix.less(
|
|
|
|
"./resources/assets/less/skins/skin-orange.less",
|
2023-05-01 18:05:06 -07:00
|
|
|
"css/dist/skins",
|
2022-01-09 08:35:28 -08:00
|
|
|
);
|
2020-03-28 00:08:21 -07:00
|
|
|
|
2020-04-27 22:41:33 -07:00
|
|
|
/**
|
|
|
|
* Combine bootstrap table css
|
|
|
|
*/
|
2022-01-09 08:35:28 -08:00
|
|
|
mix
|
|
|
|
.combine(
|
2020-04-27 22:41:33 -07:00
|
|
|
[
|
2022-01-09 08:35:28 -08:00
|
|
|
"./node_modules/bootstrap-table/dist/bootstrap-table.css",
|
|
|
|
"./node_modules/bootstrap-table/dist/extensions/sticky-header/bootstrap-table-sticky-header.css",
|
2023-09-28 07:12:44 -07:00
|
|
|
"./resources/assets/css/dragtable.css",
|
2020-04-27 22:41:33 -07:00
|
|
|
],
|
2022-01-09 08:35:28 -08:00
|
|
|
"public/css/dist/bootstrap-table.css"
|
|
|
|
)
|
|
|
|
.version();
|
2020-04-27 22:41:33 -07:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Combine JS
|
|
|
|
*/
|
2022-01-09 08:35:28 -08:00
|
|
|
mix.combine(
|
|
|
|
[
|
|
|
|
// lots of node_modules here - should this be subsumed by require()?
|
|
|
|
"./node_modules/jquery/dist/jquery.js",
|
|
|
|
"./node_modules/select2/dist/js/select2.full.min.js",
|
|
|
|
"./node_modules/admin-lte/dist/js/adminlte.min.js",
|
|
|
|
"./node_modules/tether/dist/js/tether.js",
|
2023-11-28 15:01:41 -08:00
|
|
|
"./node_modules/jquery-ui/dist/jquery-ui.js",
|
2022-01-09 08:35:28 -08:00
|
|
|
"./node_modules/jquery-slimscroll/jquery.slimscroll.js",
|
|
|
|
"./node_modules/jquery.iframe-transport/jquery.iframe-transport.js",
|
|
|
|
"./node_modules/blueimp-file-upload/js/jquery.fileupload.js",
|
|
|
|
"./node_modules/bootstrap-colorpicker/dist/js/bootstrap-colorpicker.js",
|
|
|
|
"./node_modules/bootstrap-datepicker/dist/js/bootstrap-datepicker.js",
|
|
|
|
"./node_modules/ekko-lightbox/dist/ekko-lightbox.js",
|
|
|
|
"./resources/assets/js/extensions/pGenerator.jquery.js",
|
|
|
|
"./node_modules/chart.js/dist/Chart.js",
|
|
|
|
"./resources/assets/js/signature_pad.js",
|
2023-11-13 18:15:18 -08:00
|
|
|
"./node_modules/jquery-validation/dist/jquery.validate.js",
|
2022-01-09 08:35:28 -08:00
|
|
|
"./node_modules/list.js/dist/list.js",
|
2023-09-28 07:06:55 -07:00
|
|
|
"./node_modules/clipboard/dist/clipboard.js",
|
2022-01-09 08:35:28 -08:00
|
|
|
],
|
|
|
|
"public/js/build/vendor.js" // this file seems OK!
|
|
|
|
);
|
2020-04-27 22:41:33 -07:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Combine bootstrap table js
|
|
|
|
*/
|
|
|
|
mix
|
2022-01-09 08:35:28 -08:00
|
|
|
.combine(
|
2020-04-27 22:41:33 -07:00
|
|
|
[
|
2023-09-15 13:53:34 -07:00
|
|
|
"./resources/assets/js/dragtable.js",
|
2020-04-27 22:41:33 -07:00
|
|
|
'./node_modules/bootstrap-table/dist/bootstrap-table.js',
|
2021-04-05 22:01:11 -07:00
|
|
|
'./node_modules/bootstrap-table/dist/extensions/mobile/bootstrap-table-mobile.js',
|
2020-04-27 22:41:33 -07:00
|
|
|
'./node_modules/bootstrap-table/dist/extensions/export/bootstrap-table-export.js',
|
|
|
|
'./node_modules/bootstrap-table/dist/extensions/cookie/bootstrap-table-cookie.js',
|
2023-09-15 12:28:28 -07:00
|
|
|
'./node_modules/bootstrap-table/dist/extensions/sticky-header/bootstrap-table-sticky-header.js',
|
2024-03-26 02:50:01 -07:00
|
|
|
'./node_modules/bootstrap-table/dist/extensions/addrbar/bootstrap-table-addrbar.js',
|
2020-04-27 22:41:33 -07:00
|
|
|
'./resources/assets/js/extensions/jquery.base64.js',
|
2022-05-05 12:22:20 -07:00
|
|
|
'./node_modules/tableexport.jquery.plugin/tableExport.min.js',
|
|
|
|
'./node_modules/tableexport.jquery.plugin/libs/jsPDF/jspdf.umd.min.js',
|
2021-04-05 22:01:11 -07:00
|
|
|
'./resources/assets/js/FileSaver.min.js',
|
|
|
|
'./node_modules/xlsx/dist/xlsx.core.min.js',
|
2020-04-27 22:41:33 -07:00
|
|
|
'./node_modules/bootstrap-table/dist/extensions/sticky-header/bootstrap-table-sticky-header.js',
|
|
|
|
'./node_modules/bootstrap-table/dist/extensions/toolbar/bootstrap-table-toolbar.js'
|
|
|
|
],
|
|
|
|
'public/js/dist/bootstrap-table.js'
|
|
|
|
).version();
|
|
|
|
|
2022-01-09 08:35:28 -08:00
|
|
|
mix
|
|
|
|
.combine(
|
|
|
|
["./public/js/build/vendor.js", "./public/js/build/app.js"],
|
|
|
|
"./public/js/dist/all.js"
|
|
|
|
)
|
|
|
|
.version();
|
2020-04-27 22:41:33 -07:00
|
|
|
|
2021-04-26 17:27:28 -07:00
|
|
|
/**
|
|
|
|
* Copy, minify and version skins
|
|
|
|
*/
|
|
|
|
mix
|
2022-01-09 08:35:28 -08:00
|
|
|
.minify([
|
|
|
|
"./public/css/dist/skins/skin-green.css",
|
|
|
|
"./public/css/dist/skins/skin-green-dark.css",
|
|
|
|
"./public/css/dist/skins/skin-black.css",
|
|
|
|
"./public/css/dist/skins/skin-black-dark.css",
|
|
|
|
"./public/css/dist/skins/skin-blue.css",
|
|
|
|
"./public/css/dist/skins/skin-blue-dark.css",
|
|
|
|
"./public/css/dist/skins/skin-yellow.css",
|
|
|
|
"./public/css/dist/skins/skin-yellow-dark.css",
|
|
|
|
"./public/css/dist/skins/skin-red.css",
|
|
|
|
"./public/css/dist/skins/skin-red-dark.css",
|
|
|
|
"./public/css/dist/skins/skin-purple.css",
|
|
|
|
"./public/css/dist/skins/skin-purple-dark.css",
|
|
|
|
"./public/css/dist/skins/skin-orange.css",
|
|
|
|
"./public/css/dist/skins/skin-orange-dark.css",
|
|
|
|
"./public/css/dist/skins/skin-contrast.css",
|
|
|
|
])
|
|
|
|
.version();
|