diff --git a/package.json b/package.json index 5289f3a76..992970812 100644 --- a/package.json +++ b/package.json @@ -41,17 +41,17 @@ "less-loader": "^11.1.0", "mini-css-extract-plugin": "^2.7.5", "npm-run-all": "^4.1.5", - "prettier": "^3.0.0", "postcss": "^8.4.21", "postcss-loader": "^7.1.0", + "prettier": "^3.0.0", "style-loader": "^3.3.1", "terser-webpack-plugin": "^5.3.7", "ts-node": "^10.9.1", "typescript": "^4.9.5", "webpack": "^5.75.0", "webpack-bundle-analyzer": "^4.8.0", - "webpack-cli": "^5.0.1", - "webpack-dev-server": "^4.11.1", - "webpack-merge": "^5.8.0" + "webpack-cli": "^5.1.4", + "webpack-dev-server": "^4.15.1", + "webpack-merge": "^5.9.0" } } diff --git a/packages/fineui/src/core/wrapper/layout/flex/flex.horizontal.js b/packages/fineui/src/core/wrapper/layout/flex/flex.horizontal.js index 7489d30a7..04801dd0e 100644 --- a/packages/fineui/src/core/wrapper/layout/flex/flex.horizontal.js +++ b/packages/fineui/src/core/wrapper/layout/flex/flex.horizontal.js @@ -51,7 +51,7 @@ export class FlexHorizontalLayout extends Layout { if (o.columnSize.length > 0) { return o.columnSize.indexOf("fill") >= 0 || o.columnSize.indexOf("auto") >= 0; } - + return some(o.items, (i, item) => { if (item.width === "fill" || item.width === "auto") { return true; @@ -87,7 +87,7 @@ export class FlexHorizontalLayout extends Layout { } } if (columnSize > 0) { - w.element.width(this._optimiseGap(columnSize)); + w.element.css({ width: this._optimiseGap(columnSize) }); } if (columnSize === "fill") { w.element.addClass("f-f"); @@ -103,7 +103,7 @@ export class FlexHorizontalLayout extends Layout { w.element.addClass("l-c"); } this._handleGap(w, item, i); - + return w; } diff --git a/packages/fineui/src/without_Jquery_Polyfill.js b/packages/fineui/src/without_Jquery_Polyfill.js new file mode 100644 index 000000000..369bc3a7f --- /dev/null +++ b/packages/fineui/src/without_Jquery_Polyfill.js @@ -0,0 +1,14 @@ +export * from './worker.js'; + +// "!src/base/single/input/file.js", +// "!src/case/ztree/**/*.js", +import * as _case from './case'; +import * as _widget from './widget'; +import { _global } from "@/core/0.foundation"; + +const fuiExport = { + ..._case, + ..._widget +}; + +Object.assign(_global.BI, fuiExport); diff --git a/packages/fineui/webpack/attachments.js b/packages/fineui/webpack/attachments.js index 6bb4b8110..d4c62fa4a 100644 --- a/packages/fineui/webpack/attachments.js +++ b/packages/fineui/webpack/attachments.js @@ -21,6 +21,7 @@ const basicAttachmentMap = { ]), js_bundle: sync(["src/bundle.js"]), js_worker: sync(["src/worker.js"]), + js_without_Jquery_polyfill: sync(["src/without_Jquery_Polyfill.js"]), }; const bundleCss = uniq([].concat(basicAttachmentMap.less, basicAttachmentMap.ui, sync(["public/less/app.less", "public/less/**/*.less"]))); @@ -38,9 +39,14 @@ const fineuiForWorker = [].concat( basicAttachmentMap.ts ); +const fineuiWithout_Jquery_Polyfill = [].concat( + basicAttachmentMap.js_withoutJquery, + basicAttachmentMap.ts +); + module.exports = { fineui: uniq(fineui), fineuiForWorker: uniq(fineuiForWorker), - fineuiForV8Export: uniq(fineuiForWorker), + fineuiWithout_Jquery_Polyfill: uniq(fineuiWithout_Jquery_Polyfill), bundleCss, }; diff --git a/packages/fineui/webpack/webpack.common.js b/packages/fineui/webpack/webpack.common.js index 530372b1a..1e7ce36b4 100644 --- a/packages/fineui/webpack/webpack.common.js +++ b/packages/fineui/webpack/webpack.common.js @@ -25,6 +25,8 @@ function git(command) { module.exports = { entry: { fineui: attachments.fineui, + "fineui.worker": attachments.fineuiForWorker, + "fineui_without_jquery_polyfill": attachments.fineuiWithout_Jquery_Polyfill, }, externals: { lodash: "_", diff --git a/packages/fineui/webpack/webpack.dev.js b/packages/fineui/webpack/webpack.dev.js index e858e890b..3b795e02d 100644 --- a/packages/fineui/webpack/webpack.dev.js +++ b/packages/fineui/webpack/webpack.dev.js @@ -16,5 +16,12 @@ module.exports = merge(common, { devServer: { port: 9001, // liveReload: true, + client: { + logging: 'error', + overlay: { + errors: true, + warnings: false, + }, + }, } }); diff --git a/packages/fineui/webpack/webpack.prod.js b/packages/fineui/webpack/webpack.prod.js index aa32489ea..6df850f63 100644 --- a/packages/fineui/webpack/webpack.prod.js +++ b/packages/fineui/webpack/webpack.prod.js @@ -10,9 +10,7 @@ module.exports = merge(common, { entry: { "fineui.min": attachments.fineui, "fineui.worker.min": attachments.fineuiForWorker, - "fineui.worker": attachments.fineuiForWorker, - "fineui_without_jquery_polyfill.min": attachments.fineuiForWorker, - "fineui_without_jquery_polyfill": attachments.fineuiForWorker, + "fineui_without_jquery_polyfill.min": attachments.fineuiWithout_Jquery_Polyfill, }, output: {