nav tabs on admin dashboard
This commit is contained in:
19
node_modules/laravel-mix/src/builder/Entry.js
generated
vendored
19
node_modules/laravel-mix/src/builder/Entry.js
generated
vendored
@@ -58,8 +58,17 @@ class Entry {
|
||||
);
|
||||
}
|
||||
|
||||
let vendorPath = extraction.output
|
||||
? new File(extraction.output)
|
||||
let outputPath = extraction.output;
|
||||
|
||||
// If the extraction output path begins with a slash (forward or backward)
|
||||
// then the path from the public directory determined below will be wrong
|
||||
// on Windows, as a drive letter will be incorrectly prepended to
|
||||
// (e.g. '/dist/vendor' -> 'C:\dist\vendor').
|
||||
let startsWithSlash = ['\\', '/'].indexOf(outputPath[0]) >= 0;
|
||||
outputPath = startsWithSlash ? outputPath.substr(1) : outputPath;
|
||||
|
||||
let vendorPath = outputPath
|
||||
? new File(outputPath)
|
||||
.pathFromPublic(Config.publicPath)
|
||||
.replace(/\.js$/, '')
|
||||
.replace(/\\/g, '/')
|
||||
@@ -104,7 +113,11 @@ class Entry {
|
||||
*/
|
||||
normalizePath(output, fallback) {
|
||||
// All output paths need to start at the project's public dir.
|
||||
if (!output.pathFromPublic().startsWith('/' + Config.publicPath)) {
|
||||
let pathFromPublicDir = output.pathFromPublic();
|
||||
if (
|
||||
!pathFromPublicDir.startsWith('/' + Config.publicPath) &&
|
||||
!pathFromPublicDir.startsWith('\\' + Config.publicPath)
|
||||
) {
|
||||
output = new File(
|
||||
path.join(Config.publicPath, output.pathFromPublic())
|
||||
);
|
||||
|
||||
16
node_modules/laravel-mix/src/builder/WebpackConfig.js
generated
vendored
16
node_modules/laravel-mix/src/builder/WebpackConfig.js
generated
vendored
@@ -1,9 +1,8 @@
|
||||
let webpack = require('webpack');
|
||||
|
||||
let webpackDefaultConfig = require('./webpack-default');
|
||||
let Entry = require('./Entry');
|
||||
let webpackRules = require('./webpack-rules');
|
||||
let webpackPlugins = require('./webpack-plugins');
|
||||
let webpackDefaultConfig = require('./webpack-default');
|
||||
|
||||
process.noDeprecation = true;
|
||||
|
||||
@@ -37,7 +36,7 @@ class WebpackConfig {
|
||||
buildEntry() {
|
||||
let entry = new Entry();
|
||||
|
||||
if (! Mix.bundlingJavaScript) {
|
||||
if (!Mix.bundlingJavaScript) {
|
||||
entry.addDefault();
|
||||
}
|
||||
|
||||
@@ -64,12 +63,9 @@ class WebpackConfig {
|
||||
filename: '[name].js',
|
||||
chunkFilename: '[name].js',
|
||||
publicPath: Mix.isUsing('hmr')
|
||||
? http +
|
||||
'://' +
|
||||
Config.hmrOptions.host +
|
||||
':' +
|
||||
Config.hmrOptions.port +
|
||||
'/'
|
||||
? `${http}://${Config.hmrOptions.host}:${
|
||||
Config.hmrOptions.port
|
||||
}/`
|
||||
: '/'
|
||||
};
|
||||
|
||||
@@ -107,7 +103,7 @@ class WebpackConfig {
|
||||
*/
|
||||
buildResolving() {
|
||||
this.webpackConfig.resolve = {
|
||||
extensions: ['*', '.js', '.jsx', '.vue'],
|
||||
extensions: ['*', '.wasm', '.mjs', '.js', '.jsx', '.json', '.vue'],
|
||||
|
||||
alias: {
|
||||
vue$: 'vue/dist/vue.common.js'
|
||||
|
||||
23
node_modules/laravel-mix/src/builder/webpack-default.js
generated
vendored
23
node_modules/laravel-mix/src/builder/webpack-default.js
generated
vendored
@@ -1,7 +1,12 @@
|
||||
let TerserPlugin = require('terser-webpack-plugin');
|
||||
let OptimizeCSSAssetsPlugin = require('optimize-css-assets-webpack-plugin');
|
||||
|
||||
module.exports = function() {
|
||||
return {
|
||||
context: Mix.paths.root(),
|
||||
|
||||
mode: Mix.inProduction() ? 'production' : 'development',
|
||||
|
||||
entry: {},
|
||||
|
||||
output: {},
|
||||
@@ -16,17 +21,33 @@ module.exports = function() {
|
||||
timings: false,
|
||||
children: false,
|
||||
errorDetails: false,
|
||||
entrypoints: false,
|
||||
performance: Mix.inProduction(),
|
||||
chunks: false,
|
||||
modules: false,
|
||||
reasons: false,
|
||||
source: false,
|
||||
publicPath: false
|
||||
publicPath: false,
|
||||
builtAt: false
|
||||
},
|
||||
|
||||
performance: {
|
||||
hints: false
|
||||
},
|
||||
|
||||
optimization: Mix.inProduction()
|
||||
? {
|
||||
minimizer: [
|
||||
new TerserPlugin(Config.terser),
|
||||
new OptimizeCSSAssetsPlugin({
|
||||
cssProcessorPluginOptions: {
|
||||
preset: ['default', Config.cssNano]
|
||||
}
|
||||
})
|
||||
]
|
||||
}
|
||||
: {},
|
||||
|
||||
devtool: Config.sourcemaps,
|
||||
|
||||
devServer: {
|
||||
|
||||
26
node_modules/laravel-mix/src/builder/webpack-plugins.js
generated
vendored
26
node_modules/laravel-mix/src/builder/webpack-plugins.js
generated
vendored
@@ -5,7 +5,6 @@ let BuildCallbackPlugin = require('../webpackPlugins/BuildCallbackPlugin');
|
||||
let CustomTasksPlugin = require('../webpackPlugins/CustomTasksPlugin');
|
||||
let ManifestPlugin = require('../webpackPlugins/ManifestPlugin');
|
||||
let MockEntryPlugin = require('../webpackPlugins/MockEntryPlugin');
|
||||
let UglifyJSPlugin = require('uglifyjs-webpack-plugin');
|
||||
|
||||
module.exports = function() {
|
||||
let plugins = [];
|
||||
@@ -19,14 +18,11 @@ module.exports = function() {
|
||||
|
||||
// Activate better error feedback in the console.
|
||||
plugins.push(
|
||||
new FriendlyErrorsWebpackPlugin({ clearConsole: Config.clearConsole })
|
||||
new FriendlyErrorsWebpackPlugin({
|
||||
clearConsole: Config.clearConsole
|
||||
})
|
||||
);
|
||||
|
||||
// Add support for webpack 3 scope hoisting.
|
||||
if (Mix.inProduction()) {
|
||||
plugins.push(new webpack.optimize.ModuleConcatenationPlugin());
|
||||
}
|
||||
|
||||
// Activate support for Mix_ .env definitions.
|
||||
plugins.push(
|
||||
MixDefinitionsPlugin.build({
|
||||
@@ -36,27 +32,19 @@ module.exports = function() {
|
||||
})
|
||||
);
|
||||
|
||||
if (!Mix.components.get('version') && Mix.isUsing('hmr')) {
|
||||
plugins.push(new webpack.NamedModulesPlugin());
|
||||
}
|
||||
|
||||
// Add some general Webpack loader options.
|
||||
plugins.push(
|
||||
new webpack.LoaderOptionsPlugin({
|
||||
minimize: Mix.inProduction(),
|
||||
minimize: Mix.isUsing('purifyCss') ? false : Mix.inProduction(),
|
||||
options: {
|
||||
context: __dirname,
|
||||
output: { path: './' }
|
||||
output: {
|
||||
path: './'
|
||||
}
|
||||
}
|
||||
})
|
||||
);
|
||||
|
||||
// If we're in production environment, with Uglification turned on, we'll
|
||||
// clean up and minify all of the user's JS and CSS automatically.
|
||||
if (Mix.inProduction() && Config.uglify) {
|
||||
plugins.push(new UglifyJSPlugin(Config.uglify));
|
||||
}
|
||||
|
||||
// Handle all custom, non-webpack tasks.
|
||||
plugins.push(new ManifestPlugin());
|
||||
|
||||
|
||||
2
node_modules/laravel-mix/src/builder/webpack-rules.js
generated
vendored
2
node_modules/laravel-mix/src/builder/webpack-rules.js
generated
vendored
@@ -10,7 +10,7 @@ module.exports = function() {
|
||||
// Add support for loading images.
|
||||
rules.push({
|
||||
// only include svg that doesn't have font in the path or file name by using negative lookahead
|
||||
test: /(\.(png|jpe?g|gif)$|^((?!font).)*\.svg$)/,
|
||||
test: /(\.(png|jpe?g|gif|webp)$|^((?!font).)*\.svg$)/,
|
||||
loaders: [
|
||||
{
|
||||
loader: 'file-loader',
|
||||
|
||||
Reference in New Issue
Block a user