Commit 30cd11c5 authored by 杨思琦's avatar 杨思琦

Merge branch 'devNew' into 'master'

parents eb6de231 c16cc472
Pipeline #91888 canceled with stages
const slash = require('slash2'); const slash = require('slash2');
const proxy = require('./proxy'); const proxy = require('./proxy');
const defaultSetting = require('./defaultSetting'); const defaultSetting = require('./defaultSetting');
const cesiumBuild = "../node_modules/@wisdom-cesium/panda_cesium_source/lib";
const cesiumSource = '../node_modules/@wisdom-cesium/panda_cesium_source/lib';
const pkgName = require('../package.json').name; const pkgName = require('../package.json').name;
// eslint-disable-next-line import/order // eslint-disable-next-line import/order
const { NODE_ENV } = process.env; const { NODE_ENV } = process.env;
...@@ -100,30 +98,7 @@ module.exports = { ...@@ -100,30 +98,7 @@ module.exports = {
}, },
javascriptEnabled: true, javascriptEnabled: true,
}, },
copy: [
{
from: path.join(pkgName, cesiumBuild, './Workers'),
to: 'Workers',
},
{
from: path.join(pkgName, cesiumSource, 'Assets'),
to: 'Assets',
},
{
from: path.join(pkgName, cesiumSource, 'Widgets'),
to: 'Widgets',
},
{
from: path.join(pkgName, cesiumSource, 'ThirdParty'),
to: 'ThirdParty',
},
],
define: {
// eslint-disable-next-line no-useless-escape
CESIUM_BASE_URL: JSON.stringify(CESIUM_BASE_URL).replace(/\"/g, ''),
},
alias: { alias: {
cesium: path.resolve(__dirname, cesiumSource),
'@esri/arcgis-html-sanitizer': path.resolve( '@esri/arcgis-html-sanitizer': path.resolve(
__dirname, __dirname,
'../node_modules/@esri/arcgis-html-sanitizer/dist/esm/index.js', '../node_modules/@esri/arcgis-html-sanitizer/dist/esm/index.js',
......
...@@ -80,26 +80,26 @@ export async function addCSSRules(opts) { ...@@ -80,26 +80,26 @@ export async function addCSSRules(opts) {
...userConfig.cssLoader, ...userConfig.cssLoader,
}); });
rule // rule
.use('postcss-loader') // .use('postcss-loader')
.loader(require.resolve('@umijs/bundler-webpack/compiled/postcss-loader')) // .loader(require.resolve('@umijs/bundler-webpack/compiled/postcss-loader'))
.options({ // .options({
postcssOptions: { // postcssOptions: {
ident: 'postcss', // ident: 'postcss',
plugins: [ // plugins: [
require('../compiled/postcss-flexbugs-fixes'), // require('../compiled/postcss-flexbugs-fixes'),
require('postcss-preset-env')({ // require('postcss-preset-env')({
browsers: opts.browsers, // browsers: opts.browsers,
autoprefixer: { // autoprefixer: {
flexbox: 'no-2009', // flexbox: 'no-2009',
...userConfig.autoprefixer, // ...userConfig.autoprefixer,
}, // },
stage: 3, // stage: 3,
}), // }),
].concat(userConfig.extraPostCSSPlugins || []), // ].concat(userConfig.extraPostCSSPlugins || []),
...userConfig.postcssLoader, // ...userConfig.postcssLoader,
}, // },
}); // });
if (loader) { if (loader) {
rule rule
......
...@@ -70,30 +70,30 @@ function createCSSRule({ ...@@ -70,30 +70,30 @@ function createCSSRule({
), ),
); );
rule // rule
.use('postcss-loader') // .use('postcss-loader')
.loader(require.resolve('postcss-loader')) // .loader(require.resolve('postcss-loader'))
.options( // .options(
deepmerge( // deepmerge(
{ // {
ident: 'postcss', // ident: 'postcss',
plugins: () => [ // plugins: () => [
require('postcss-flexbugs-fixes'), // require('postcss-flexbugs-fixes'),
require('postcss-preset-env')({ // require('postcss-preset-env')({
// TODO: set browsers // // TODO: set browsers
autoprefixer: { // autoprefixer: {
...config.autoprefixer, // ...config.autoprefixer,
overrideBrowserslist: browserslist, // overrideBrowserslist: browserslist,
}, // },
// https://cssdb.org/ // // https://cssdb.org/
stage: 3, // stage: 3,
}), // }),
...(config.extraPostCSSPlugins ? config.extraPostCSSPlugins : []), // ...(config.extraPostCSSPlugins ? config.extraPostCSSPlugins : []),
], // ],
}, // },
config.postcssLoader || {}, // config.postcssLoader || {},
), // ),
); // );
if (loader) { if (loader) {
rule rule
...@@ -196,4 +196,4 @@ function css({ ...@@ -196,4 +196,4 @@ function css({
module.exports = { module.exports = {
createCSSRule, createCSSRule,
css css
} }
\ No newline at end of file
...@@ -59,7 +59,10 @@ module.exports = require('./webpack.base.babel')({ ...@@ -59,7 +59,10 @@ module.exports = require('./webpack.base.babel')({
test: /[\\/]node_modules[\\/]/, test: /[\\/]node_modules[\\/]/,
name(module) { name(module) {
const packageName = module.context.match(/[\\/]node_modules[\\/](.*?)([\\/]|$)/)[1]; const packageName = module.context.match(/[\\/]node_modules[\\/](.*?)([\\/]|$)/)[1];
return `npm.${packageName.replace('@', '')}`; // @ts-ignore
if (['@wisdom-components', 'swiper'].indexOf(packageName) === -1) {
return `npm.${packageName.replace('@', '')}`;
}
}, },
}, },
bizComponent: { bizComponent: {
...@@ -69,6 +72,13 @@ module.exports = require('./webpack.base.babel')({ ...@@ -69,6 +72,13 @@ module.exports = require('./webpack.base.babel')({
test: /[\\/]src[\\/]components[\\/]/, test: /[\\/]src[\\/]components[\\/]/,
name: 'biz-component', name: 'biz-component',
}, },
layouts: {
chunks: 'all',
minSize: 0,
maxInitialRequests: 10,
test: /[\\/]src[\\/]layouts[\\/]/,
name: 'layouts',
},
arcgis_views: { arcgis_views: {
chunks: 'all', chunks: 'all',
minSize: 0, minSize: 0,
......
...@@ -99,16 +99,16 @@ ...@@ -99,16 +99,16 @@
"@ant-design/colors": "^5.0.1", "@ant-design/colors": "^5.0.1",
"@ant-design/icons": "^4.0.0", "@ant-design/icons": "^4.0.0",
"@ant-design/pro-form": "1.70.1", "@ant-design/pro-form": "1.70.1",
"@ant-design/pro-layout": "^6.24.1", "@ant-design/pro-layout": "6.38.11",
"@ant-design/pro-list": "1.21.71", "@ant-design/pro-list": "1.21.71",
"@ant-design/pro-skeleton": "^1.0.0-beta.2", "@ant-design/pro-skeleton": "^1.0.0-beta.2",
"@ant-design/pro-table": "2.76.4", "@ant-design/pro-table": "2.77.1",
"@ant-design/pro-utils": "^1.10.4", "@ant-design/pro-utils": "1.42.4",
"@ant-design/pro-provider": "1.8.1",
"@babel/polyfill": "7.4.3", "@babel/polyfill": "7.4.3",
"@babel/runtime": "^7.10.5", "@babel/runtime": "^7.10.5",
"@congcongcai/jieba.js": "0.0.3", "@congcongcai/jieba.js": "0.0.3",
"@esri/calcite-colors": "6.0.3", "@esri/calcite-colors": "6.0.3",
"@wisdom-cesium/cesium": "^1.1.49",
"@wisdom-cesium/krpano": "1.0.29-60", "@wisdom-cesium/krpano": "1.0.29-60",
"@wisdom-components/basictable": "^1.5.16", "@wisdom-components/basictable": "^1.5.16",
"@wisdom-components/empty": "^1.4.1", "@wisdom-components/empty": "^1.4.1",
...@@ -117,7 +117,7 @@ ...@@ -117,7 +117,7 @@
"@wisdom-map/arcgismap":"^2.0.49", "@wisdom-map/arcgismap":"^2.0.49",
"@wisdom-map/basemap":"^2.0.2", "@wisdom-map/basemap":"^2.0.2",
"@wisdom-map/util":"1.2.9", "@wisdom-map/util":"1.2.9",
"@wisdom-utils/components": "0.1.364", "@wisdom-utils/components": "0.1.370",
"@wisdom-utils/runtime": "0.0.51", "@wisdom-utils/runtime": "0.0.51",
"@wisdom-utils/utils": "0.1.408", "@wisdom-utils/utils": "0.1.408",
"animate.css": "^4.1.1", "animate.css": "^4.1.1",
...@@ -132,7 +132,7 @@ ...@@ -132,7 +132,7 @@
"history": "4.9.0", "history": "4.9.0",
"hoist-non-react-statics": "3.3.0", "hoist-non-react-statics": "3.3.0",
"immer": "3.0.0", "immer": "3.0.0",
"immutable": "^4.0.0-rc.12", "immutable": "^4.0.0",
"jquery": "^3.7.0", "jquery": "^3.7.0",
"js-base64": "^3.5.2", "js-base64": "^3.5.2",
"js-cookie": "^2.2.1", "js-cookie": "^2.2.1",
...@@ -152,6 +152,7 @@ ...@@ -152,6 +152,7 @@
"rc-cascader": "^2.3.2", "rc-cascader": "^2.3.2",
"rc-queue-anim": "^2.0.0", "rc-queue-anim": "^2.0.0",
"react": "17.0.2", "react": "17.0.2",
"react-file-viewer": "^1.2.1",
"react-activation": "^0.9.9", "react-activation": "^0.9.9",
"react-dom": "17.0.2", "react-dom": "17.0.2",
"react-draggable": "^4.4.3", "react-draggable": "^4.4.3",
...@@ -174,7 +175,8 @@ ...@@ -174,7 +175,8 @@
"sha1": "^1.1.1", "sha1": "^1.1.1",
"sm4js": "^0.0.6", "sm4js": "^0.0.6",
"styled-components": "4.2.0", "styled-components": "4.2.0",
"swiper": "6.8.4" "swiper": "6.8.4",
"xlsx": "^0.17.3"
}, },
"devDependencies": { "devDependencies": {
"@babel/cli": "7.4.3", "@babel/cli": "7.4.3",
...@@ -271,11 +273,6 @@ ...@@ -271,11 +273,6 @@
"ora": "^5.1.0", "ora": "^5.1.0",
"path-to-regexp": "^2.4.0", "path-to-regexp": "^2.4.0",
"plop": "2.3.0", "plop": "2.3.0",
"postcss": "7.0.32",
"postcss-flexbugs-fixes": "4.2.1",
"postcss-loader": "3.0.0",
"postcss-preset-env": "6.7.0",
"postcss-safe-parser": "^4.0.2",
"pre-commit": "1.2.2", "pre-commit": "1.2.2",
"prettier": "1.17.0", "prettier": "1.17.0",
"querystring-browser": "^1.0.4", "querystring-browser": "^1.0.4",
......
No preview for this file type
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment