@wavemaker/angular-codegen 11.6.0-next.26272 → 11.6.0-next.40501
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- angular-codegen/angular-app/package-lock.json +4 -4
- angular-codegen/angular-app/package.json +8 -8
- angular-codegen/dependencies/pipe-provider.cjs.js +2 -4
- angular-codegen/dependencies/transpilation-mobile.cjs.js +2 -3
- angular-codegen/dependencies/transpilation-web.cjs.js +2 -3
- angular-codegen/package.json +1 -1
- angular-codegen/src/pages-util.js +1 -1
- angular-codegen/src/update-angular-json.js +1 -1
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
"@metrichor/jmespath": "^0.3.1",
|
|
37
37
|
"@wavemaker/focus-trap": "^1.0.0",
|
|
38
38
|
"@wavemaker/nvd3": "1.8.8",
|
|
39
|
-
"@wavemaker/variables": "11.6.0-next.
|
|
39
|
+
"@wavemaker/variables": "11.6.0-next.40501",
|
|
40
40
|
"@ztree/ztree_v3": "^3.5.48",
|
|
41
41
|
"angular-imask": "6.3.0",
|
|
42
42
|
"angular2-websocket": "0.9.7",
|
|
@@ -5947,9 +5947,9 @@
|
|
|
5947
5947
|
}
|
|
5948
5948
|
},
|
|
5949
5949
|
"node_modules/@wavemaker/variables": {
|
|
5950
|
-
"version": "11.6.0-next.
|
|
5951
|
-
"resolved": "https://registry.npmjs.org/@wavemaker/variables/-/variables-11.6.0-next.
|
|
5952
|
-
"integrity": "sha512-
|
|
5950
|
+
"version": "11.6.0-next.40501",
|
|
5951
|
+
"resolved": "https://registry.npmjs.org/@wavemaker/variables/-/variables-11.6.0-next.40501.tgz",
|
|
5952
|
+
"integrity": "sha512-PMNLtDfkdbd7CvoYuedkeFfakYCQkees5WfFpdgDb5aotUGgiHaDQ2kgyp69K6na7zElPClXUgPRuWD0l/idTQ==",
|
|
5953
5953
|
"dependencies": {
|
|
5954
5954
|
"@metrichor/jmespath": "^0.3.1",
|
|
5955
5955
|
"he": "^1.2.0",
|
|
@@ -45,9 +45,9 @@
|
|
|
45
45
|
"@awesome-cordova-plugins/vibration": "5.39.1",
|
|
46
46
|
"@babel/runtime": "^7.14.8",
|
|
47
47
|
"@metrichor/jmespath": "^0.3.1",
|
|
48
|
-
"@wavemaker/focus-trap": "^1.0.0",
|
|
49
48
|
"@wavemaker/nvd3": "1.8.8",
|
|
50
|
-
"@wavemaker/
|
|
49
|
+
"@wavemaker/focus-trap": "^1.0.0",
|
|
50
|
+
"@wavemaker/variables": "11.6.0-next.40501",
|
|
51
51
|
"@ztree/ztree_v3": "^3.5.48",
|
|
52
52
|
"angular-imask": "6.3.0",
|
|
53
53
|
"angular2-websocket": "0.9.7",
|
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
"tslib": "2.4.1",
|
|
73
73
|
"x2js": "^3.4.4",
|
|
74
74
|
"zone.js": "~0.11.4",
|
|
75
|
-
"@wavemaker/app-ng-runtime": "11.6.0-next.
|
|
75
|
+
"@wavemaker/app-ng-runtime": "11.6.0-next.40501"
|
|
76
76
|
},
|
|
77
77
|
"devDependencies": {
|
|
78
78
|
"@ampproject/rollup-plugin-closure-compiler": "^0.27.0",
|
|
@@ -83,10 +83,6 @@
|
|
|
83
83
|
"@angular/language-service": "15.2.9",
|
|
84
84
|
"@babel/plugin-transform-runtime": "^7.14.5",
|
|
85
85
|
"@compodoc/compodoc": "^1.1.19",
|
|
86
|
-
"@rollup/plugin-alias": "4.0.2",
|
|
87
|
-
"@rollup/plugin-commonjs": "24.0.0",
|
|
88
|
-
"@rollup/plugin-multi-entry": "6.0.0",
|
|
89
|
-
"@rollup/plugin-node-resolve": "15.0.1",
|
|
90
86
|
"@types/jasmine": "2.8.8",
|
|
91
87
|
"@types/jasminewd2": "2.0.3",
|
|
92
88
|
"@types/jquery": "3.3.22",
|
|
@@ -117,9 +113,13 @@
|
|
|
117
113
|
"owasp-dependency-check": "0.0.21",
|
|
118
114
|
"rimraf": "2.6.3",
|
|
119
115
|
"rollup": "3.9.1",
|
|
116
|
+
"@rollup/plugin-alias": "4.0.2",
|
|
117
|
+
"@rollup/plugin-commonjs": "24.0.0",
|
|
120
118
|
"rollup-plugin-includepaths": "0.2.3",
|
|
121
|
-
"
|
|
119
|
+
"@rollup/plugin-multi-entry": "6.0.0",
|
|
120
|
+
"@rollup/plugin-node-resolve": "15.0.1",
|
|
122
121
|
"terser": "^5.15.1",
|
|
122
|
+
"sonarqube-scanner": "^2.8.2",
|
|
123
123
|
"ts-node": "7.0.1",
|
|
124
124
|
"tslint": "~6.1.0",
|
|
125
125
|
"typescript": "4.9.5",
|
|
@@ -93985,7 +93985,6 @@ const REGEX$1 = {
|
|
|
93985
93985
|
IPOD: /iPod/i,
|
|
93986
93986
|
IPAD: /iPad/i,
|
|
93987
93987
|
MAC: /Mac/i,
|
|
93988
|
-
MACINTEL: /MacIntel/i,
|
|
93989
93988
|
ANDROID_TABLET: /android|android 3.0|xoom|sch-i800|playbook|tablet|kindle/i,
|
|
93990
93989
|
MOBILE: /Mobile/i,
|
|
93991
93990
|
WINDOWS: /Windows Phone/i,
|
|
@@ -94029,7 +94028,7 @@ const isAndroidTablet$1 = () => REGEX$1.ANDROID_TABLET.test(userAgent$1) && !((/
|
|
|
94029
94028
|
const isIphone$1 = () => REGEX$1.IPHONE.test(userAgent$1);
|
|
94030
94029
|
const isIpod$1 = () => REGEX$1.IPOD.test(userAgent$1);
|
|
94031
94030
|
const isIpad$1 = () => {
|
|
94032
|
-
return REGEX$1.IPAD.test(userAgent$1) || (window.navigator.maxTouchPoints && window.navigator.maxTouchPoints > 2 &&
|
|
94031
|
+
return REGEX$1.IPAD.test(userAgent$1) || (window.navigator.maxTouchPoints && window.navigator.maxTouchPoints > 2 && REGEX$1.MAC.test(window.navigator.platform));
|
|
94033
94032
|
};
|
|
94034
94033
|
const isIos$1 = () => isIphone$1() || isIpod$1() || isIpad$1();
|
|
94035
94034
|
const isLargeTabletLandscape$1 = (landScapeWidth, landScapeHeight) => {
|
|
@@ -120823,7 +120822,6 @@ const REGEX = {
|
|
|
120823
120822
|
IPOD: /iPod/i,
|
|
120824
120823
|
IPAD: /iPad/i,
|
|
120825
120824
|
MAC: /Mac/i,
|
|
120826
|
-
MACINTEL: /MacIntel/i,
|
|
120827
120825
|
ANDROID_TABLET: /android|android 3.0|xoom|sch-i800|playbook|tablet|kindle/i,
|
|
120828
120826
|
MOBILE: /Mobile/i,
|
|
120829
120827
|
WINDOWS: /Windows Phone/i,
|
|
@@ -120867,7 +120865,7 @@ const isAndroidTablet = () => REGEX.ANDROID_TABLET.test(userAgent) && !((/Tablet
|
|
|
120867
120865
|
const isIphone = () => REGEX.IPHONE.test(userAgent);
|
|
120868
120866
|
const isIpod = () => REGEX.IPOD.test(userAgent);
|
|
120869
120867
|
const isIpad = () => {
|
|
120870
|
-
return REGEX.IPAD.test(userAgent) || (window.navigator.maxTouchPoints && window.navigator.maxTouchPoints > 2 &&
|
|
120868
|
+
return REGEX.IPAD.test(userAgent) || (window.navigator.maxTouchPoints && window.navigator.maxTouchPoints > 2 && REGEX.MAC.test(window.navigator.platform));
|
|
120871
120869
|
};
|
|
120872
120870
|
const isIos = () => isIphone() || isIpod() || isIpad();
|
|
120873
120871
|
const isLargeTabletLandscape = (landScapeWidth, landScapeHeight) => {
|
|
@@ -57611,7 +57611,6 @@ const REGEX = {
|
|
|
57611
57611
|
IPOD: /iPod/i,
|
|
57612
57612
|
IPAD: /iPad/i,
|
|
57613
57613
|
MAC: /Mac/i,
|
|
57614
|
-
MACINTEL: /MacIntel/i,
|
|
57615
57614
|
ANDROID_TABLET: /android|android 3.0|xoom|sch-i800|playbook|tablet|kindle/i,
|
|
57616
57615
|
MOBILE: /Mobile/i,
|
|
57617
57616
|
WINDOWS: /Windows Phone/i,
|
|
@@ -57655,7 +57654,7 @@ const isAndroidTablet = () => REGEX.ANDROID_TABLET.test(userAgent) && !((/Tablet
|
|
|
57655
57654
|
const isIphone = () => REGEX.IPHONE.test(userAgent);
|
|
57656
57655
|
const isIpod = () => REGEX.IPOD.test(userAgent);
|
|
57657
57656
|
const isIpad = () => {
|
|
57658
|
-
return REGEX.IPAD.test(userAgent) || (window.navigator.maxTouchPoints && window.navigator.maxTouchPoints > 2 &&
|
|
57657
|
+
return REGEX.IPAD.test(userAgent) || (window.navigator.maxTouchPoints && window.navigator.maxTouchPoints > 2 && REGEX.MAC.test(window.navigator.platform));
|
|
57659
57658
|
};
|
|
57660
57659
|
const isIos = () => isIphone() || isIpod() || isIpad();
|
|
57661
57660
|
const isLargeTabletLandscape = (landScapeWidth, landScapeHeight) => {
|
|
@@ -61994,7 +61993,7 @@ const registerFormField = (isFormField) => {
|
|
|
61994
61993
|
const dataRole = isFormField ? 'form-field' : 'filter-field';
|
|
61995
61994
|
const formFieldErrorMsgId = 'wmform-field-error-' + generateGUId();
|
|
61996
61995
|
const validationMsg = isFormField ? `<p *ngIf="${counter}._control?.invalid && ${counter}._control?.touched && ${pCounter}.isUpdateMode"
|
|
61997
|
-
class="help-block text-danger" aria-hidden="false"
|
|
61996
|
+
class="help-block text-danger" aria-hidden="false" role="alert"
|
|
61998
61997
|
aria-live="assertive" [attr.aria-label]="${counter}.validationmessage" id="${formFieldErrorMsgId}"><span aria-hidden="true" [textContent]="${counter}.validationmessage"></span></p>` : '';
|
|
61999
61998
|
const eventsTmpl = widgetType === FormWidgetType.UPLOAD ? '' : getEventsTemplate(attrs);
|
|
62000
61999
|
const controlLayout = isMobileApp() ? 'col-xs-12' : 'col-sm-12';
|
|
@@ -57611,7 +57611,6 @@ const REGEX = {
|
|
|
57611
57611
|
IPOD: /iPod/i,
|
|
57612
57612
|
IPAD: /iPad/i,
|
|
57613
57613
|
MAC: /Mac/i,
|
|
57614
|
-
MACINTEL: /MacIntel/i,
|
|
57615
57614
|
ANDROID_TABLET: /android|android 3.0|xoom|sch-i800|playbook|tablet|kindle/i,
|
|
57616
57615
|
MOBILE: /Mobile/i,
|
|
57617
57616
|
WINDOWS: /Windows Phone/i,
|
|
@@ -57655,7 +57654,7 @@ const isAndroidTablet = () => REGEX.ANDROID_TABLET.test(userAgent) && !((/Tablet
|
|
|
57655
57654
|
const isIphone = () => REGEX.IPHONE.test(userAgent);
|
|
57656
57655
|
const isIpod = () => REGEX.IPOD.test(userAgent);
|
|
57657
57656
|
const isIpad = () => {
|
|
57658
|
-
return REGEX.IPAD.test(userAgent) || (window.navigator.maxTouchPoints && window.navigator.maxTouchPoints > 2 &&
|
|
57657
|
+
return REGEX.IPAD.test(userAgent) || (window.navigator.maxTouchPoints && window.navigator.maxTouchPoints > 2 && REGEX.MAC.test(window.navigator.platform));
|
|
57659
57658
|
};
|
|
57660
57659
|
const isIos = () => isIphone() || isIpod() || isIpad();
|
|
57661
57660
|
const isLargeTabletLandscape = (landScapeWidth, landScapeHeight) => {
|
|
@@ -61994,7 +61993,7 @@ const registerFormField = (isFormField) => {
|
|
|
61994
61993
|
const dataRole = isFormField ? 'form-field' : 'filter-field';
|
|
61995
61994
|
const formFieldErrorMsgId = 'wmform-field-error-' + generateGUId();
|
|
61996
61995
|
const validationMsg = isFormField ? `<p *ngIf="${counter}._control?.invalid && ${counter}._control?.touched && ${pCounter}.isUpdateMode"
|
|
61997
|
-
class="help-block text-danger" aria-hidden="false"
|
|
61996
|
+
class="help-block text-danger" aria-hidden="false" role="alert"
|
|
61998
61997
|
aria-live="assertive" [attr.aria-label]="${counter}.validationmessage" id="${formFieldErrorMsgId}"><span aria-hidden="true" [textContent]="${counter}.validationmessage"></span></p>` : '';
|
|
61999
61998
|
const eventsTmpl = widgetType === FormWidgetType.UPLOAD ? '' : getEventsTemplate(attrs);
|
|
62000
61999
|
const controlLayout = isMobileApp() ? 'col-xs-12' : 'col-sm-12';
|
angular-codegen/package.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
global.$=require("jquery"),global._=require("lodash"),global._WM_APP_PROPERTIES={};const cheerio=require("cheerio"),{generatePageExpressions:generatePageExpressions}=require("./expr-parser-utils"),{readFile:readFile,isMobileProject:isMobileProject}=require("./wm-utils"),nodePolyfill=require("node-window-polyfill").register(!1),getRequiredScripts=e=>{const r={wmCalendar:["./node_modules/fullcalendar/main.min.js"],wmChart:["./node_modules/d3/
|
|
1
|
+
global.$=require("jquery"),global._=require("lodash"),global._WM_APP_PROPERTIES={};const cheerio=require("cheerio"),{generatePageExpressions:generatePageExpressions}=require("./expr-parser-utils"),{readFile:readFile,isMobileProject:isMobileProject}=require("./wm-utils"),nodePolyfill=require("node-window-polyfill").register(!1),getRequiredScripts=e=>{const r={wmCalendar:["./node_modules/fullcalendar/main.min.js"],wmChart:["./node_modules/d3/d3.min.js","./node_modules/@wavemaker/nvd3/build/nv.d3.min.js"],wmChips:["./node_modules/jquery-ui/ui/widgets/sortable.js"],wmList:["./node_modules/jquery-ui/ui/widgets/droppable.js","./node_modules/jquery-ui/ui/widgets/sortable.js"],wmRichtexteditor:["./node_modules/summernote/dist/summernote-lite.min.js"],wmTable:[global._WM_PACKAGE_PATH+"/scripts/datatable/datatable.js","./node_modules/jquery-ui/ui/widgets/resizable.js"]};let t=[];return _.each(r,(r,i)=>{e("["+i+"]").length>0&&(t=t.concat(r))}),t=t.map(e=>e.replace(/^(\.\/)/,"").replace(/\//g,"-").replace(/@/g,"")),_.uniq(t)},includesCustomElement=e=>{return cheerio.load(e)('[html-custom-element="true"]').length},getPageContents=async(e,r,t,i,s,o,l)=>{try{const a=`${r}/${t}`,n=await readFile(`${a}.html`,"utf8");let u,d,m,p="{}";"LAYOUT"!==s&&(u=await readFile(`${a}.js`,"utf8"),d=await readFile(`${a}.css`,"utf8"),p=await readFile(`${a}.variables.json`,"utf8")),global._WM_APP_PROPERTIES=e,window=window||{},window._WM_APP_PROPERTIES=e;const c=(m=isMobileProject(e)?require("../dependencies/transpilation-mobile.cjs"):require("../dependencies/transpilation-web.cjs")).transpile(n),g=cheerio.load(c.markup),w=getRequiredScripts(g);return w.length>0&&(c.markup=c.markup.replace(">",` scripts-to-load="${w.join(",")}">`)),{markup:c.markup,script:u,styles:m.scopeComponentStyles(i,s,d),variables:p,expressions:l?generatePageExpressions(c.markup,p,o):"",requiredWMComponents:c.requiredWMComponents.filter(r=>!r.platformType||r.platformType===e.platformType),hasCustomElement:includesCustomElement(n)}}catch(e){throw console.error(`error occurred in transpilation of ${t}`,e),e}};module.exports={getPageContents:getPageContents};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const cheerio=require("cheerio"),{writeFile:writeFile,readFileSync:readFileSync,readDir:readDir,isMobileProject:isMobileProject}=require("./wm-utils"),markScriptsAsLazy=e=>{const s=["./node_modules/d3/
|
|
1
|
+
const cheerio=require("cheerio"),{writeFile:writeFile,readFileSync:readFileSync,readDir:readDir,isMobileProject:isMobileProject}=require("./wm-utils"),markScriptsAsLazy=e=>{const s=["./node_modules/d3/d3.min.js","./node_modules/@wavemaker/nvd3/build/nv.d3.min.js","./node_modules/fullcalendar/main.min.js","./node_modules/summernote/dist/summernote-lite.min.js",global._WM_PACKAGE_PATH+"/scripts/datatable/datatable.js","./node_modules/jquery-ui/ui/widgets/sortable.js","./node_modules/jquery-ui/ui/widgets/droppable.js","./node_modules/jquery-ui/ui/widgets/resizable.js","./node_modules/hammerjs/hammer.min.js","./node_modules/iscroll/build/iscroll.js"];let t=e.replace(/^(\.\/)/,"").replace(/\//g,"-").replace(/@/g,"");return t=t.substring(0,t.lastIndexOf(".")),t+="-NOHASH",s.includes(e)?{input:e,inject:!1,bundleName:t}:e},setBuildCustomizations=async e=>{const s=e.projects["angular-app"].architect.build,t=s.options.scripts;s.options.scripts=t.map(e=>markScriptsAsLazy(e))},addToScripts=async(e,s,t=[],i=[])=>{const n=`${s}/angular.json`;let o=readFileSync(n,!0);const a=o.projects["angular-app"].architect.build;let r=a.options.scripts;const l=`${s+"/src/app/extensions"}`,c=await readDir(l);c.length&&i.push("./src/app/extensions/"+c[0]),a.options.scripts=[...t,...r,...i],await writeFile(n,JSON.stringify(o,null,4))},updateAngularJSON=async(e,s,t,i,n,o,a,r,l,c)=>{const d=`${s}/angular.json`;let u=readFileSync(d,!0);const p=u.projects["angular-app"].architect.build;a&&a.trim().length>0&&(p.options.deployUrl=a);const m=p.options.styles;if(isMobileProject(t)){const e=m.findIndex(e=>{let s="object"==typeof e;if(s){return(s?e.input:e).includes("themes")}return!1}),s=m[e].input;m[e].bundleName="wm-android-styles",m[e].input=m[e].input.replace(new RegExp("/[a-z]*/style.css$"),`/${i.activeTheme}/android/style.css`);const t=Object.assign({},m[e]);t.input=s.replace(new RegExp("/[a-z]*/style.css$"),`/${i.activeTheme}/ios/style.css`),t.bundleName="wm-ios-styles",m.push(t);const n=m.findIndex(e=>{let s="object"==typeof e;if(s){return"src/assets/app.css"===(s?e.input:e)}return!1});m[n].bundleName="wm-android-styles";const o=Object.assign({},m[n]);o.bundleName="wm-ios-styles",m.push(o)}m.forEach((e,s)=>{let t="object"==typeof e,n=t?e.input:e;!n.includes("themes")||n.includes("/android/")||n.includes("/ios/")||(t?m[s].input=n.replace(new RegExp("/[a-z]*/style.css$"),`/${i.activeTheme}/style.css`):m[s]=n.replace(new RegExp("/[a-z]*/style.css$"),`/${i.activeTheme}/style.css`))}),await setBuildCustomizations(u);const g=p.configurations.production;if(g.aot=!1!==r.aot,g.buildOptimizer=!1!==r.buildOptimizer,c){const e=p.options.assets;e.push("src/manifest.json"),e.push("src/wmsw-worker.js"),g.serviceWorker=!0,g.ngswConfigPath="ngsw-config.json",delete p.options.customWebpackConfig}await writeFile(d,JSON.stringify(u,null,4))};module.exports={updateAngularJSON:updateAngularJSON,addToScripts:addToScripts};
|