Skip to content

Commit bb59c51

Browse files
Merge branch 'master_update_to_24.2_stable' of https://github.com/GoodDayForSurf/devextreme-cli into update-versions
# Conflicts: # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-generic-large-tasks-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-generic-large-user-panel-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-generic-small-tasks-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-generic-small-user-panel-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-generic-xsmall-tasks-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-generic-xsmall-user-panel-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-material-large-add-view-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-material-large-home-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-material-large-profile-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-material-large-tasks-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-material-large-toggle-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-material-large-user-panel-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-material-small-add-view-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-material-small-home-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-material-small-profile-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-material-small-tasks-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-material-small-toggle-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-material-small-user-panel-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-material-xsmall-add-view-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-material-xsmall-home-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-material-xsmall-profile-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-material-xsmall-tasks-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-material-xsmall-toggle-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-inner-toolbar-material-xsmall-user-panel-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-generic-large-tasks-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-generic-large-user-panel-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-generic-small-tasks-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-generic-small-user-panel-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-generic-xsmall-tasks-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-generic-xsmall-user-panel-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-material-large-add-view-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-material-large-home-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-material-large-profile-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-material-large-tasks-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-material-large-toggle-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-material-large-user-panel-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-material-small-add-view-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-material-small-home-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-material-small-profile-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-material-small-tasks-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-material-small-toggle-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-material-small-user-panel-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-material-xsmall-add-view-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-material-xsmall-home-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-material-xsmall-profile-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-material-xsmall-tasks-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-material-xsmall-toggle-snap.png # packages/devextreme-cli/testing/__tests__/__image_snapshots__/side-nav-outer-toolbar-material-xsmall-user-panel-snap.png
2 parents 02a3858 + 2eaee55 commit bb59c51

File tree

235 files changed

+1772
-1901
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

235 files changed

+1772
-1901
lines changed

.github/workflows/applications.yml

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ jobs:
2222
- react
2323
- react-ts
2424
NODE:
25-
- 16
2625
- 18
2726
OS:
2827
- ubuntu-latest
@@ -49,10 +48,18 @@ jobs:
4948
id: setup-chrome
5049
- run: ${{ steps.setup-chrome.outputs.chrome-path }} --version
5150

51+
- name: Set Legacy-peer-deps=true
52+
run: npm config set legacy-peer-deps true
53+
5254
- name: Create ${{ matrix.APPROACH }} application
5355
run: npm run create-template -- -- -e ${{ matrix.APPROACH }} ${{ env.TOOLING_VERSION_PARAM }}
5456
timeout-minutes: 30
5557

58+
- name: Install Internal Packages
59+
uses: DevExpress/github-actions/install-internal-package@main
60+
with:
61+
working-directory: packages/devextreme-cli/testing/sandbox/${{ matrix.APPROACH }}/my-app
62+
5663
- name: Lint created application
5764
if: ${{ matrix.OS != 'windows-latest' }}
5865
run: npm run lint-template -- -- -e ${{ matrix.APPROACH }} ${{ env.TOOLING_VERSION_PARAM }}
@@ -85,7 +92,7 @@ jobs:
8592
- name: Set up Node.js and restore cache
8693
uses: actions/setup-node@v3
8794
with:
88-
node-version: 16
95+
node-version: 18
8996
cache: 'npm'
9097
cache-dependency-path: '**/package-lock.json'
9198

.github/workflows/lint.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@ jobs:
1717
uses: actions/checkout@v2
1818

1919
- name: Use Node.js
20-
uses: actions/setup-node@v2
20+
uses: actions/setup-node@v3
2121
with:
22-
node-version: '14'
22+
node-version: '18'
2323

2424
- name: Run npm install
2525
run: npm install --no-package-lock --no-audit --no-fund

.github/workflows/themebuilder.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ jobs:
77
strategy:
88
fail-fast: false
99
matrix:
10-
NODE: [ 16, 18 ]
10+
NODE: [ 18 ]
1111

1212
runs-on: ubuntu-latest
1313
name: ThemeBuilder

lerna.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@
22
"packages": [
33
"packages/*"
44
],
5-
"version": "1.6.9"
5+
"version": "1.8.0-beta.0"
66
}

packages/devextreme-cli/package-lock.json

Lines changed: 10 additions & 9 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/devextreme-cli/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "devextreme-cli",
3-
"version": "1.6.9",
3+
"version": "1.8.0-beta.0",
44
"description": "DevExtreme CLI",
55
"keywords": [
66
"devexpress",
@@ -43,7 +43,7 @@
4343
"minimist": "^1.2.8",
4444
"mustache": "^3.2.1",
4545
"prompts": "^2.4.2",
46-
"sass": "^1.71.0",
46+
"sass": "^1.77.6",
4747
"semver": "^5.7.2",
4848
"strip-bom": "^4.0.0"
4949
},

packages/devextreme-cli/src/applications/application.angular.js

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,7 @@ const latestVersions = require('../utility/latest-versions');
1010
const { extractToolingVersion, toolingVersionOptionName } = require('../utility/extract-tooling-version');
1111
const schematicsVersion = latestVersions['devextreme-schematics'] || 'latest';
1212

13-
const minNgCliVersion = new semver('16.0.0');
14-
const ngCliWithStandalone = new semver('17.0.0');
13+
const minNgCliVersion = new semver('17.0.0');
1514

1615
async function runSchematicCommand(schematicCommand, options, evaluatingOptions) {
1716
const collectionName = 'devextreme-schematics';
@@ -40,9 +39,10 @@ async function runNgCommand(commandArguments, commandOptions, commandConfig) {
4039
const hasNg = await hasSutableNgCli();
4140
const toolingVersion = extractToolingVersion(commandOptions);
4241
const npmCommandName = hasNg && !toolingVersion ? 'ng' : 'npx';
42+
const [minCliLtsVersion] = minNgCliVersion.version.split('.');
4343
const ngCommandArguments = hasNg && !toolingVersion
4444
? []
45-
: ['-p', '@angular/cli@v15-lts', 'ng'];
45+
: ['-p', `@angular/cli@v${minCliLtsVersion}-lts`, 'ng'];
4646

4747
ngCommandArguments.push(...commandArguments);
4848
return runCommand(npmCommandName, ngCommandArguments, commandConfig);
@@ -76,21 +76,18 @@ const install = async(options) => {
7676

7777
const create = async(appName, options) => {
7878
const layout = await getLayoutInfo(options.layout);
79-
const currentNgVersion = ngVersion.getNgCliVersion().version;
8079

8180
const commandArguments = [
8281
'new',
8382
appName,
8483
'--style=scss',
8584
'--routing=false',
8685
'--skip-tests=true',
87-
'--skip-install=true'
86+
'--skip-install=true',
87+
'--standalone=false',
88+
'--ssr=false'
8889
];
8990

90-
if(ngCliWithStandalone.compare(currentNgVersion) <= 0) {
91-
commandArguments.push('--standalone=false');
92-
}
93-
9491
await runNgCommand(commandArguments, options);
9592

9693
const appPath = path.join(process.cwd(), appName);
@@ -128,7 +125,8 @@ const changeMainTs = (appPath) => {
128125
moduleWorker.insertImport(filePath, 'devextreme/ui/themes', 'themes', true);
129126

130127
const fileContent = fs.readFileSync(filePath).toString();
131-
const firstChaptStr = 'platformBrowserDynamic().bootstrapModule(AppModule)';
128+
const bootstrapPattern = /platformBrowserDynamic\(\)\.bootstrapModule\(\s*AppModule\s*(?:,\s*\{[^}]*\})?\s*\)/;
129+
const firstChaptStr = fileContent.match(bootstrapPattern)[0];
132130
const lastChaptStr = '.catch(err => console.error(err));';
133131

134132
fs.writeFileSync(

packages/devextreme-cli/src/applications/application.react.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,9 @@ const addTemplate = (appPath, appName, templateOptions) => {
100100

101101
const styles = [
102102
'./themes/generated/theme.additional.css',
103+
'./themes/generated/theme.additional.dark.css',
103104
'./themes/generated/theme.base.css',
105+
'./themes/generated/theme.base.dark.css',
104106
'devextreme/dist/css/dx.common.css'
105107
];
106108

packages/devextreme-cli/src/applications/application.vue.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,9 @@ const addTemplate = (appPath, appName, templateOptions) => {
7777
const applicationTemplatePath = path.join(templateCreator.getTempaltePath('vue-v3'), 'application');
7878
const styles = [
7979
'./themes/generated/theme.additional.css',
80+
'./themes/generated/theme.additional.dark.css',
8081
'./themes/generated/theme.base.css',
82+
'./themes/generated/theme.base.dark.css',
8183
'devextreme/dist/css/dx.common.css'
8284
];
8385

packages/devextreme-cli/src/commands.json

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@
5757
"description": "Specifies base theme name (default value is generic.light)"
5858
}, {
5959
"name": "--input-file",
60-
"description": "Specifies file name with input data (a .json file with metadata or a .less/.scss file with Bootstrap variables)"
60+
"description": "Specifies file name with input data (a .json file with metadata or a .scss file with Bootstrap 5 variables)"
6161
}, {
6262
"name": "--make-swatch",
6363
"description": "If present, adds a CSS scope to each CSS rule (.dx-swatch-xxx), where xxx is the value from the --output-color-scheme parameter"
@@ -76,9 +76,6 @@
7676
}, {
7777
"name": "--remove-external-resources",
7878
"description": "When present, removes links to external resources, such as fonts. The theme will use local fallbacks instead. Available from DevExtreme v20.2.7."
79-
}, {
80-
"name": "--bootstrap-version",
81-
"description": "Specifies Bootstrap version 4 or 5 if '--input-file' is a '.scss' file. Available from DevExtreme v21.1.5. Default value: 4."
8279
}]
8380
}, {
8481
"name": "export-theme-vars",
@@ -89,7 +86,7 @@
8986
"description": "Specifies base theme name (default value is generic.light)"
9087
}, {
9188
"name": "--input-file",
92-
"description": "Specifies file name with input data (a .json file with metadata or a .less/.scss file with Bootstrap variables)"
89+
"description": "Specifies file name with input data (a .json file with metadata or a .scss file with Bootstrap 5 variables)"
9390
}, {
9491
"name": "--output-format",
9592
"description": "Specifies the format of output variables (less or scss) (default value is less or the extension extracted from the --output-file value (if it contains any))"
@@ -112,7 +109,7 @@
112109
"description": "Specifies base theme name (default value is generic.light)"
113110
}, {
114111
"name": "--input-file",
115-
"description": "Specifies file name with input data (a .json file with metadata or a .less/.scss file with Bootstrap variables)"
112+
"description": "Specifies file name with input data (a .json file with metadata or a .scss file with Bootstrap 5 variables)"
116113
}, {
117114
"name": "--output-file",
118115
"description": "Specifies output file name"

0 commit comments

Comments
 (0)