devextreme-schematics 1.7.1 → 1.8.0-beta.0
Sign up to get free protection for your applications and to get access to all the features.
- package/package.json +7 -7
- package/src/add-app-template/schema.json +2 -2
- package/src/add-layout/files/devextreme.json +30 -1
- package/src/add-layout/files/src/app/__name__.component.scss +0 -2
- package/src/add-layout/files/src/app/__name__.component.ts +4 -2
- package/src/add-layout/files/src/app/layouts/side-nav-inner-toolbar/side-nav-inner-toolbar.component.html +1 -1
- package/src/add-layout/files/src/app/layouts/side-nav-inner-toolbar/side-nav-inner-toolbar.component.scss +0 -6
- package/src/add-layout/files/src/app/layouts/side-nav-inner-toolbar/side-nav-inner-toolbar.component.ts +14 -6
- package/src/add-layout/files/src/app/layouts/side-nav-outer-toolbar/side-nav-outer-toolbar.component.html +1 -1
- package/src/add-layout/files/src/app/layouts/side-nav-outer-toolbar/side-nav-outer-toolbar.component.scss +1 -1
- package/src/add-layout/files/src/app/layouts/side-nav-outer-toolbar/side-nav-outer-toolbar.component.ts +13 -6
- package/src/add-layout/files/src/app/layouts/single-card/single-card.component.scss +2 -4
- package/src/add-layout/files/src/app/layouts/single-card/single-card.component.ts +2 -1
- package/src/add-layout/files/src/app/not-authorized-container.ts +2 -1
- package/src/add-layout/files/src/app/shared/components/change-password-form/change-password-form.component.ts +2 -1
- package/src/add-layout/files/src/app/shared/components/create-account-form/create-account-form.component.scss +3 -5
- package/src/add-layout/files/src/app/shared/components/create-account-form/create-account-form.component.ts +2 -1
- package/src/add-layout/files/src/app/shared/components/footer/footer.component.scss +7 -4
- package/src/add-layout/files/src/app/shared/components/footer/footer.component.ts +2 -1
- package/src/add-layout/files/src/app/shared/components/header/header.component.html +9 -10
- package/src/add-layout/files/src/app/shared/components/header/header.component.scss +4 -7
- package/src/add-layout/files/src/app/shared/components/header/header.component.ts +5 -2
- package/src/add-layout/files/src/app/shared/components/login-form/login-form.component.scss +1 -4
- package/src/add-layout/files/src/app/shared/components/login-form/login-form.component.ts +2 -1
- package/src/add-layout/files/src/app/shared/components/reset-password-form/reset-password-form.component.scss +1 -3
- package/src/add-layout/files/src/app/shared/components/reset-password-form/reset-password-form.component.ts +2 -1
- package/src/add-layout/files/src/app/shared/components/side-navigation-menu/side-navigation-menu.component.scss +13 -39
- package/src/add-layout/files/src/app/shared/components/side-navigation-menu/side-navigation-menu.component.ts +2 -1
- package/src/add-layout/files/src/app/shared/components/theme-switcher/theme-switcher.component.ts +33 -0
- package/src/add-layout/files/src/app/shared/components/user-panel/user-panel.component.html +13 -18
- package/src/add-layout/files/src/app/shared/components/user-panel/user-panel.component.scss +38 -54
- package/src/add-layout/files/src/app/shared/components/user-panel/user-panel.component.ts +5 -8
- package/src/add-layout/files/src/app/shared/services/index.ts +1 -0
- package/src/add-layout/files/src/app/shared/services/theme.service.ts +49 -0
- package/src/add-layout/files/src/app/unauthenticated-content.ts +2 -1
- package/src/add-layout/files/src/dx-styles.scss +76 -52
- package/src/add-layout/files/src/themes/metadata.additional.dark.json +11 -0
- package/src/add-layout/files/src/themes/metadata.additional.json +1 -1
- package/src/add-layout/files/src/themes/metadata.base.dark.json +8 -0
- package/src/add-layout/files/src/themes/metadata.base.json +1 -1
- package/src/add-layout/files/src/variables.scss +37 -0
- package/src/add-layout/index.js +3 -0
- package/src/add-layout/index.js.map +1 -1
- package/src/add-layout/index.ts +3 -0
- package/src/add-layout/index_spec.js +12 -9
- package/src/add-layout/index_spec.js.map +1 -1
- package/src/add-layout/index_spec.ts +14 -9
- package/src/add-layout/schema.json +1 -1
- package/src/add-sample-views/files/pages/home/home.component.html +182 -34
- package/src/add-sample-views/files/pages/home/home.component.scss +19 -16
- package/src/add-sample-views/files/pages/home/home.component.ts +2 -1
- package/src/add-sample-views/files/pages/profile/profile.component.html +1 -1
- package/src/add-sample-views/files/pages/profile/profile.component.ts +2 -1
- package/src/add-sample-views/files/pages/tasks/tasks.component.html +3 -2
- package/src/add-sample-views/files/pages/tasks/tasks.component.scss +3 -0
- package/src/add-sample-views/files/pages/tasks/tasks.component.ts +3 -1
- package/src/add-sample-views/index_spec.js +2 -1
- package/src/add-sample-views/index_spec.js.map +1 -1
- package/src/add-sample-views/index_spec.ts +2 -1
- package/src/add-view/index.js +38 -11
- package/src/add-view/index.js.map +1 -1
- package/src/add-view/index.ts +41 -14
- package/src/add-view/index_spec.js +7 -4
- package/src/add-view/index_spec.js.map +1 -1
- package/src/add-view/index_spec.ts +7 -4
- package/src/install/index_spec.js +3 -2
- package/src/install/index_spec.js.map +1 -1
- package/src/install/index_spec.ts +3 -2
- package/src/install/schema.json +1 -1
- package/src/utility/latest-versions.js +2 -2
- package/src/utility/latest-versions.js.map +1 -1
- package/src/utility/latest-versions.ts +2 -2
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "devextreme-schematics",
|
3
|
-
"version": "1.
|
3
|
+
"version": "1.8.0-beta.0",
|
4
4
|
"description": "DevExtreme schematics",
|
5
5
|
"scripts": {
|
6
6
|
"build": "tsc -p tsconfig.json",
|
@@ -22,18 +22,18 @@
|
|
22
22
|
],
|
23
23
|
"schematics": "./src/collection.json",
|
24
24
|
"dependencies": {
|
25
|
-
"@angular-devkit/core": "^
|
26
|
-
"@angular-devkit/schematics": "^
|
27
|
-
"@schematics/angular": "^
|
25
|
+
"@angular-devkit/core": "^17.2.1",
|
26
|
+
"@angular-devkit/schematics": "^17.2.1",
|
27
|
+
"@schematics/angular": "^17.2.1"
|
28
28
|
},
|
29
29
|
"devDependencies": {
|
30
30
|
"@types/jasmine": "~3.10.18",
|
31
|
-
"@types/node": "
|
31
|
+
"@types/node": "ts5.2",
|
32
32
|
"@types/semver": "^7.5.7",
|
33
33
|
"jasmine": "^2.99.0",
|
34
34
|
"rxjs": "^6.6.7",
|
35
35
|
"tslint": "^5.20.1",
|
36
|
-
"typescript": "
|
36
|
+
"typescript": "~5.2.1"
|
37
37
|
},
|
38
|
-
"gitHead": "
|
38
|
+
"gitHead": "afe86ffa75cfe3ee7b9b5a78af5adcb2e3bb28f3"
|
39
39
|
}
|
@@ -39,11 +39,11 @@
|
|
39
39
|
"dxversion": {
|
40
40
|
"type": "string",
|
41
41
|
"description": "The DevExtreme version",
|
42
|
-
"default": "24.
|
42
|
+
"default": "24.2.2-beta"
|
43
43
|
},
|
44
44
|
"globalNgCliVersion": {
|
45
45
|
"type":"string",
|
46
|
-
"default": "^
|
46
|
+
"default": "^17.2.0"
|
47
47
|
},
|
48
48
|
"empty": {
|
49
49
|
"type": "boolean",
|
@@ -8,13 +8,28 @@
|
|
8
8
|
"inputFile": "<%= sourcePath %>/themes/metadata.base.json",
|
9
9
|
"outputFile": "<%= sourcePath %>/themes/generated/theme.base.css"
|
10
10
|
}
|
11
|
-
},
|
11
|
+
},
|
12
|
+
{
|
13
|
+
"command": "build-theme",
|
14
|
+
"options": {
|
15
|
+
"inputFile": "<%= sourcePath %>/themes/metadata.base.dark.json",
|
16
|
+
"outputFile": "<%= sourcePath %>/themes/generated/theme.base.dark.css"
|
17
|
+
}
|
18
|
+
},
|
19
|
+
{
|
12
20
|
"command": "build-theme",
|
13
21
|
"options": {
|
14
22
|
"inputFile": "<%= sourcePath %>/themes/metadata.additional.json",
|
15
23
|
"outputFile": "<%= sourcePath %>/themes/generated/theme.additional.css"
|
16
24
|
}
|
17
25
|
},
|
26
|
+
{
|
27
|
+
"command": "build-theme",
|
28
|
+
"options": {
|
29
|
+
"inputFile": "<%= sourcePath %>/themes/metadata.additional.dark.json",
|
30
|
+
"outputFile": "<%= sourcePath %>/themes/generated/theme.additional.dark.css"
|
31
|
+
}
|
32
|
+
},
|
18
33
|
{
|
19
34
|
"command": "export-theme-vars",
|
20
35
|
"options": {
|
@@ -22,12 +37,26 @@
|
|
22
37
|
"outputFile": "<%= sourcePath %>/themes/generated/variables.base.scss"
|
23
38
|
}
|
24
39
|
},
|
40
|
+
{
|
41
|
+
"command": "export-theme-vars",
|
42
|
+
"options": {
|
43
|
+
"inputFile": "<%= sourcePath %>/themes/metadata.base.dark.json",
|
44
|
+
"outputFile": "<%= sourcePath %>/themes/generated/variables.base.dark.scss"
|
45
|
+
}
|
46
|
+
},
|
25
47
|
{
|
26
48
|
"command": "export-theme-vars",
|
27
49
|
"options": {
|
28
50
|
"inputFile": "<%= sourcePath %>/themes/metadata.additional.json",
|
29
51
|
"outputFile": "<%= sourcePath %>/themes/generated/variables.additional.scss"
|
30
52
|
}
|
53
|
+
},
|
54
|
+
{
|
55
|
+
"command": "export-theme-vars",
|
56
|
+
"options": {
|
57
|
+
"inputFile": "<%= sourcePath %>/themes/metadata.additional.dark.json",
|
58
|
+
"outputFile": "<%= sourcePath %>/themes/generated/variables.additional.dark.scss"
|
59
|
+
}
|
31
60
|
}
|
32
61
|
]
|
33
62
|
}
|
@@ -4,11 +4,13 @@ import { AuthService, ScreenService, AppInfoService } from './shared/services';
|
|
4
4
|
@Component({
|
5
5
|
selector: '<%= prefix %>-root',
|
6
6
|
templateUrl: './<%= name %>.component.html',
|
7
|
-
styleUrls: ['./<%= name %>.component.scss']
|
7
|
+
styleUrls: ['./<%= name %>.component.scss'],
|
8
|
+
standalone: false
|
8
9
|
})
|
9
10
|
export class <%= strings.classify(name) %>Component {
|
10
11
|
@HostBinding('class') get getClass() {
|
11
|
-
|
12
|
+
const sizeClassName = Object.keys(this.screen.sizes).filter(cl => this.screen.sizes[cl]).join(' ');
|
13
|
+
return `${sizeClassName} app` ;
|
12
14
|
}
|
13
15
|
|
14
16
|
constructor(private authService: AuthService, private screen: ScreenService, public appInfo: AppInfoService) { }
|
@@ -11,7 +11,7 @@
|
|
11
11
|
<app-side-navigation-menu
|
12
12
|
[compactMode]="!menuOpened"
|
13
13
|
[selectedItem]="selectedRoute"
|
14
|
-
|
14
|
+
[ngClass]="swatchClassName"
|
15
15
|
*dxTemplate="let dataMenu of 'panel'"
|
16
16
|
(selectedItemChanged)="navigationChanged($event)"
|
17
17
|
(openMenu)="navigationClick()">
|
@@ -3,14 +3,8 @@
|
|
3
3
|
}
|
4
4
|
|
5
5
|
#navigation-header {
|
6
|
-
@import "../../../themes/generated/variables.additional.scss";
|
7
|
-
background-color: $base-accent;
|
8
6
|
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.24);
|
9
7
|
|
10
|
-
::ng-deep .menu-button .dx-icon {
|
11
|
-
color: $base-text-color;
|
12
|
-
}
|
13
|
-
|
14
8
|
:host-context(.screen-x-small) & {
|
15
9
|
padding-left: 20px;
|
16
10
|
}
|
@@ -1,18 +1,21 @@
|
|
1
1
|
import { Component, OnInit, NgModule, Input, ViewChild } from '@angular/core';
|
2
|
-
import {
|
3
|
-
import {
|
2
|
+
import { Router, NavigationEnd } from '@angular/router';
|
3
|
+
import { CommonModule } from '@angular/common';
|
4
|
+
|
4
5
|
import { DxTreeViewTypes } from 'devextreme-angular/ui/tree-view';
|
5
6
|
import { DxDrawerModule, DxDrawerTypes } from 'devextreme-angular/ui/drawer';
|
6
7
|
import { DxScrollViewModule, DxScrollViewComponent } from 'devextreme-angular/ui/scroll-view';
|
7
8
|
import { DxToolbarModule, DxToolbarTypes } from 'devextreme-angular/ui/toolbar';
|
8
|
-
import { CommonModule } from '@angular/common';
|
9
9
|
|
10
|
-
import {
|
10
|
+
import { SideNavigationMenuModule, HeaderModule } from '../../shared/components';
|
11
|
+
import { ScreenService } from '../../shared/services';
|
12
|
+
import { ThemeService } from '../../shared/services/theme.service';
|
11
13
|
|
12
14
|
@Component({
|
13
15
|
selector: 'app-side-nav-inner-toolbar',
|
14
16
|
templateUrl: './side-nav-inner-toolbar.component.html',
|
15
|
-
styleUrls: ['./side-nav-inner-toolbar.component.scss']
|
17
|
+
styleUrls: ['./side-nav-inner-toolbar.component.scss'],
|
18
|
+
standalone: false
|
16
19
|
})
|
17
20
|
export class SideNavInnerToolbarComponent implements OnInit {
|
18
21
|
@ViewChild(DxScrollViewComponent, { static: true }) scrollView!: DxScrollViewComponent;
|
@@ -28,8 +31,13 @@ export class SideNavInnerToolbarComponent implements OnInit {
|
|
28
31
|
menuRevealMode: DxDrawerTypes.RevealMode = 'expand';
|
29
32
|
minMenuSize = 0;
|
30
33
|
shaderEnabled = false;
|
34
|
+
swatchClassName = 'dx-swatch-additional';
|
31
35
|
|
32
|
-
constructor(private screen: ScreenService, private router: Router) {
|
36
|
+
constructor(protected themeService: ThemeService, private screen: ScreenService, private router: Router) {
|
37
|
+
themeService.isDark.subscribe((isDark) => {
|
38
|
+
this.swatchClassName = 'dx-swatch-additional' + (isDark ? '-dark' : '');
|
39
|
+
})
|
40
|
+
}
|
33
41
|
|
34
42
|
ngOnInit() {
|
35
43
|
this.menuOpened = this.screen.sizes['screen-large'];
|
@@ -18,7 +18,7 @@
|
|
18
18
|
<app-side-navigation-menu
|
19
19
|
[compactMode]="!menuOpened"
|
20
20
|
[selectedItem]="selectedRoute"
|
21
|
-
|
21
|
+
[ngClass]="swatchClassName"
|
22
22
|
*dxTemplate="let dataMenu of 'panel'"
|
23
23
|
(selectedItemChanged)="navigationChanged($event)"
|
24
24
|
(openMenu)="navigationClick()">
|
@@ -1,17 +1,19 @@
|
|
1
1
|
import { Component, OnInit, NgModule, Input, ViewChild } from '@angular/core';
|
2
|
-
import {
|
3
|
-
import {
|
2
|
+
import { CommonModule } from '@angular/common';
|
3
|
+
import { Router, NavigationEnd } from '@angular/router';
|
4
|
+
|
4
5
|
import { DxTreeViewTypes } from 'devextreme-angular/ui/tree-view';
|
5
6
|
import { DxDrawerModule, DxDrawerTypes } from 'devextreme-angular/ui/drawer';
|
6
7
|
import { DxScrollViewModule, DxScrollViewComponent } from 'devextreme-angular/ui/scroll-view';
|
7
|
-
import { CommonModule } from '@angular/common';
|
8
8
|
|
9
|
-
import {
|
9
|
+
import { SideNavigationMenuModule, HeaderModule } from '../../shared/components';
|
10
|
+
import { ScreenService, ThemeService } from '../../shared/services';
|
10
11
|
|
11
12
|
@Component({
|
12
13
|
selector: 'app-side-nav-outer-toolbar',
|
13
14
|
templateUrl: './side-nav-outer-toolbar.component.html',
|
14
|
-
styleUrls: ['./side-nav-outer-toolbar.component.scss']
|
15
|
+
styleUrls: ['./side-nav-outer-toolbar.component.scss'],
|
16
|
+
standalone: false
|
15
17
|
})
|
16
18
|
export class SideNavOuterToolbarComponent implements OnInit {
|
17
19
|
@ViewChild(DxScrollViewComponent, { static: true }) scrollView!: DxScrollViewComponent;
|
@@ -27,8 +29,13 @@ export class SideNavOuterToolbarComponent implements OnInit {
|
|
27
29
|
menuRevealMode: DxDrawerTypes.RevealMode = 'expand';
|
28
30
|
minMenuSize = 0;
|
29
31
|
shaderEnabled = false;
|
32
|
+
swatchClassName = 'dx-swatch-additional';
|
30
33
|
|
31
|
-
constructor(private screen: ScreenService, private router: Router) {
|
34
|
+
constructor(protected themeService: ThemeService, private screen: ScreenService, private router: Router) {
|
35
|
+
themeService.isDark.subscribe((isDark) => {
|
36
|
+
this.swatchClassName = 'dx-swatch-additional' + (isDark ? '-dark' : '');
|
37
|
+
})
|
38
|
+
}
|
32
39
|
|
33
40
|
ngOnInit() {
|
34
41
|
this.menuOpened = this.screen.sizes['screen-large'];
|
@@ -1,5 +1,3 @@
|
|
1
|
-
@import "../../../themes/generated/variables.base.scss";
|
2
|
-
|
3
1
|
:host {
|
4
2
|
width: 100%;
|
5
3
|
height: 100%;
|
@@ -26,14 +24,14 @@
|
|
26
24
|
margin-bottom: 30px;
|
27
25
|
|
28
26
|
.title {
|
29
|
-
color:
|
27
|
+
color: var(--base-text-color);
|
30
28
|
line-height: 28px;
|
31
29
|
font-weight: 500;
|
32
30
|
font-size: 24px;
|
33
31
|
}
|
34
32
|
|
35
33
|
.description {
|
36
|
-
color:
|
34
|
+
color: var(--base-text-color-alpha-7);
|
37
35
|
line-height: 18px;
|
38
36
|
}
|
39
37
|
}
|
@@ -5,7 +5,8 @@ import { DxScrollViewModule } from 'devextreme-angular/ui/scroll-view';
|
|
5
5
|
@Component({
|
6
6
|
selector: 'app-single-card',
|
7
7
|
templateUrl: './single-card.component.html',
|
8
|
-
styleUrls: ['./single-card.component.scss']
|
8
|
+
styleUrls: ['./single-card.component.scss'],
|
9
|
+
standalone: false
|
9
10
|
})
|
10
11
|
export class SingleCardComponent {
|
11
12
|
@Input()
|
@@ -10,7 +10,8 @@ import { AuthService } from '../../services';
|
|
10
10
|
|
11
11
|
@Component({
|
12
12
|
selector: 'app-change-passsword-form',
|
13
|
-
templateUrl: './change-password-form.component.html'
|
13
|
+
templateUrl: './change-password-form.component.html',
|
14
|
+
standalone: false
|
14
15
|
})
|
15
16
|
export class ChangePasswordFormComponent implements OnInit {
|
16
17
|
loading = false;
|
@@ -1,19 +1,17 @@
|
|
1
|
-
@import "../../../../themes/generated/variables.base.scss";
|
2
|
-
|
3
1
|
.create-account-form {
|
4
2
|
.policy-info {
|
5
3
|
margin: 10px 0;
|
6
|
-
color:
|
4
|
+
color: var(--base-text-color-alpha-7);
|
7
5
|
font-size: 14px;
|
8
6
|
font-style: normal;
|
9
7
|
|
10
8
|
a {
|
11
|
-
color:
|
9
|
+
color: var(--base-text-color-alpha-7);
|
12
10
|
}
|
13
11
|
}
|
14
12
|
|
15
13
|
.login-link {
|
16
|
-
color:
|
14
|
+
color: var(--base-accent);
|
17
15
|
font-size: 16px;
|
18
16
|
text-align: center;
|
19
17
|
}
|
@@ -11,7 +11,8 @@ import { AuthService } from '../../services';
|
|
11
11
|
@Component({
|
12
12
|
selector: 'app-create-account-form',
|
13
13
|
templateUrl: './create-account-form.component.html',
|
14
|
-
styleUrls: ['./create-account-form.component.scss']
|
14
|
+
styleUrls: ['./create-account-form.component.scss'],
|
15
|
+
standalone: false
|
15
16
|
})
|
16
17
|
export class CreateAccountFormComponent {
|
17
18
|
loading = false;
|
@@ -1,9 +1,12 @@
|
|
1
|
-
@import "../../../../themes/generated/variables.base.scss";
|
2
|
-
|
3
1
|
:host {
|
4
2
|
display: block;
|
5
|
-
color:
|
6
|
-
border-top: 1px solid
|
3
|
+
color: var(--base-text-color-alpha-7);
|
4
|
+
border-top: 1px solid var(--footer-border-color);
|
7
5
|
padding-top: 20px;
|
8
6
|
padding-bottom: 24px;
|
7
|
+
margin: 0 40px;
|
8
|
+
|
9
|
+
.screen-x-small & {
|
10
|
+
margin: 0 20px;
|
11
|
+
}
|
9
12
|
}
|
@@ -17,24 +17,23 @@
|
|
17
17
|
*ngIf="title"
|
18
18
|
[text]="title">
|
19
19
|
</dxi-item>
|
20
|
+
<dxi-item
|
21
|
+
location="after"
|
22
|
+
>
|
23
|
+
<ng-container *dxTemplate>
|
24
|
+
<theme-switcher></theme-switcher>
|
25
|
+
</ng-container>
|
26
|
+
</dxi-item>
|
20
27
|
<dxi-item
|
21
28
|
location="after"
|
22
29
|
locateInMenu="auto"
|
23
30
|
menuItemTemplate="menuItem">
|
24
31
|
<div *dxTemplate="let data of 'item'">
|
25
|
-
<
|
26
|
-
class="user-button authorization"
|
27
|
-
width="210px"
|
28
|
-
height="100%"
|
29
|
-
stylingMode="text">
|
30
|
-
<div *dxTemplate="let data of 'content'">
|
31
|
-
<app-user-panel [user]="user" [menuItems]="userMenuItems" menuMode="context"></app-user-panel>
|
32
|
-
</div>
|
33
|
-
</dx-button>
|
32
|
+
<app-user-panel [menuItems]="userMenuItems"></app-user-panel>
|
34
33
|
</div>
|
35
34
|
</dxi-item>
|
36
35
|
<div *dxTemplate="let data of 'menuItem'">
|
37
|
-
<app-user-panel [
|
36
|
+
<app-user-panel [menuItems]="userMenuItems" menuMode="list"></app-user-panel>
|
38
37
|
</div>
|
39
38
|
</dx-toolbar>
|
40
39
|
</header>
|
@@ -1,14 +1,11 @@
|
|
1
|
-
@import "../../../../themes/generated/variables.base.scss";
|
2
|
-
@import "../../../../dx-styles.scss";
|
3
|
-
|
4
1
|
:host {
|
5
2
|
flex: 0 0 auto;
|
6
3
|
z-index: 1;
|
7
4
|
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.24);
|
5
|
+
}
|
8
6
|
|
9
|
-
|
10
|
-
|
11
|
-
}
|
7
|
+
::ng-deep header {
|
8
|
+
background-color: var(--base-bg);
|
12
9
|
}
|
13
10
|
|
14
11
|
::ng-deep .dx-toolbar.header-toolbar .dx-toolbar-items-container .dx-toolbar-after {
|
@@ -20,7 +17,7 @@
|
|
20
17
|
}
|
21
18
|
|
22
19
|
::ng-deep .dx-toolbar .dx-toolbar-item.menu-button {
|
23
|
-
width:
|
20
|
+
width: var(--side-panel-min-width);
|
24
21
|
text-align: center;
|
25
22
|
padding: 0;
|
26
23
|
}
|
@@ -7,10 +7,12 @@ import { DxButtonModule } from 'devextreme-angular/ui/button';
|
|
7
7
|
import { DxToolbarModule } from 'devextreme-angular/ui/toolbar';
|
8
8
|
|
9
9
|
import { Router } from '@angular/router';
|
10
|
+
import {ThemeSwitcherModule} from "../theme-switcher/theme-switcher.component";
|
10
11
|
@Component({
|
11
12
|
selector: 'app-header',
|
12
13
|
templateUrl: 'header.component.html',
|
13
|
-
styleUrls: ['./header.component.scss']
|
14
|
+
styleUrls: ['./header.component.scss'],
|
15
|
+
standalone: false
|
14
16
|
})
|
15
17
|
|
16
18
|
export class HeaderComponent implements OnInit {
|
@@ -56,7 +58,8 @@ export class HeaderComponent implements OnInit {
|
|
56
58
|
CommonModule,
|
57
59
|
DxButtonModule,
|
58
60
|
UserPanelModule,
|
59
|
-
DxToolbarModule
|
61
|
+
DxToolbarModule,
|
62
|
+
ThemeSwitcherModule,
|
60
63
|
],
|
61
64
|
declarations: [ HeaderComponent ],
|
62
65
|
exports: [ HeaderComponent ]
|
@@ -1,6 +1,3 @@
|
|
1
|
-
@import "../../../../themes/generated/variables.base.scss";
|
2
|
-
|
3
|
-
|
4
1
|
.login-form {
|
5
2
|
.link {
|
6
3
|
text-align: center;
|
@@ -14,6 +11,6 @@
|
|
14
11
|
|
15
12
|
::ng-deep .form-text {
|
16
13
|
margin: 10px 0;
|
17
|
-
color:
|
14
|
+
color: var(--base-text-color-alpha-7);
|
18
15
|
}
|
19
16
|
}
|
@@ -10,7 +10,8 @@ import { AuthService } from '../../services';
|
|
10
10
|
@Component({
|
11
11
|
selector: 'app-login-form',
|
12
12
|
templateUrl: './login-form.component.html',
|
13
|
-
styleUrls: ['./login-form.component.scss']
|
13
|
+
styleUrls: ['./login-form.component.scss'],
|
14
|
+
standalone: false
|
14
15
|
})
|
15
16
|
export class LoginFormComponent {
|
16
17
|
loading = false;
|
@@ -1,12 +1,10 @@
|
|
1
|
-
@import "../../../../themes/generated/variables.base.scss";
|
2
|
-
|
3
1
|
.reset-password-form {
|
4
2
|
::ng-deep .submit-button {
|
5
3
|
margin-top: 10px;
|
6
4
|
}
|
7
5
|
|
8
6
|
.login-link {
|
9
|
-
color:
|
7
|
+
color: var(--base-accent);
|
10
8
|
font-size: 16px;
|
11
9
|
text-align: center;
|
12
10
|
}
|
@@ -11,7 +11,8 @@ const notificationText = 'We\'ve sent a link to reset your password. Check your
|
|
11
11
|
@Component({
|
12
12
|
selector: 'app-reset-password-form',
|
13
13
|
templateUrl: './reset-password-form.component.html',
|
14
|
-
styleUrls: ['./reset-password-form.component.scss']
|
14
|
+
styleUrls: ['./reset-password-form.component.scss'],
|
15
|
+
standalone: false
|
15
16
|
})
|
16
17
|
export class ResetPasswordFormComponent {
|
17
18
|
loading = false;
|
@@ -1,19 +1,18 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
:host {
|
1
|
+
:host.dx-swatch-additional,
|
2
|
+
:host.dx-swatch-additional-dark {
|
5
3
|
display: flex;
|
6
4
|
flex-direction: column;
|
7
5
|
min-height: 100%;
|
8
6
|
height: 100%;
|
9
7
|
width: 250px !important;
|
8
|
+
background-color: var(--base-bg);
|
10
9
|
|
11
|
-
.menu-container {
|
10
|
+
::ng-deep .menu-container {
|
12
11
|
min-height: 100%;
|
13
12
|
display: flex;
|
14
13
|
flex: 1;
|
15
14
|
|
16
|
-
|
15
|
+
.dx-treeview {
|
17
16
|
// ## Long text positioning
|
18
17
|
white-space: nowrap;
|
19
18
|
// ##
|
@@ -21,15 +20,17 @@
|
|
21
20
|
// ## Icon width customization
|
22
21
|
.dx-treeview-item {
|
23
22
|
padding-left: 0;
|
23
|
+
border-radius: 0;
|
24
24
|
flex-direction: row-reverse;
|
25
25
|
|
26
26
|
.dx-icon {
|
27
|
-
width:
|
27
|
+
width: var(--side-panel-min-width) !important;
|
28
28
|
margin: 0 !important;
|
29
29
|
}
|
30
30
|
}
|
31
|
+
|
31
32
|
// ##
|
32
|
-
|
33
|
+
|
33
34
|
// ## Arrow customization
|
34
35
|
.dx-treeview-node {
|
35
36
|
padding: 0 0 !important;
|
@@ -48,43 +49,16 @@
|
|
48
49
|
|
49
50
|
// ## Item levels customization
|
50
51
|
.dx-treeview-node {
|
51
|
-
&[aria-level=
|
52
|
+
&[aria-level="1"] {
|
52
53
|
font-weight: bold;
|
53
|
-
border-bottom: 1px solid $base-border-color;
|
54
54
|
}
|
55
|
-
|
56
|
-
&[aria-level=
|
55
|
+
|
56
|
+
&[aria-level="2"] .dx-treeview-item-content {
|
57
57
|
font-weight: normal;
|
58
|
-
padding: 0
|
58
|
+
padding: 0 var(--side-panel-min-width);
|
59
59
|
}
|
60
60
|
}
|
61
61
|
// ##
|
62
62
|
}
|
63
|
-
|
64
|
-
// ## Selected & Focuced items customization
|
65
|
-
::ng-deep .dx-treeview {
|
66
|
-
.dx-treeview-node-container {
|
67
|
-
.dx-treeview-node {
|
68
|
-
&.dx-state-selected:not(.dx-state-focused)> .dx-treeview-item {
|
69
|
-
background: transparent;
|
70
|
-
}
|
71
|
-
|
72
|
-
&.dx-state-selected > .dx-treeview-item * {
|
73
|
-
color: $base-accent;
|
74
|
-
}
|
75
|
-
|
76
|
-
&:not(.dx-state-focused)>.dx-treeview-item.dx-state-hover {
|
77
|
-
background-color: lighten($base-bg, 4.00);
|
78
|
-
}
|
79
|
-
}
|
80
|
-
}
|
81
|
-
}
|
82
|
-
|
83
|
-
:host-context(.dx-theme-generic) ::ng-deep.dx-treeview {
|
84
|
-
.dx-treeview-node-container .dx-treeview-node.dx-state-selected.dx-state-focused > .dx-treeview-item * {
|
85
|
-
color: inherit;
|
86
|
-
}
|
87
|
-
}
|
88
|
-
// ##
|
89
63
|
}
|
90
64
|
}
|
@@ -7,7 +7,8 @@ import * as events from 'devextreme/events';
|
|
7
7
|
@Component({
|
8
8
|
selector: 'app-side-navigation-menu',
|
9
9
|
templateUrl: './side-navigation-menu.component.html',
|
10
|
-
styleUrls: ['./side-navigation-menu.component.scss']
|
10
|
+
styleUrls: ['./side-navigation-menu.component.scss'],
|
11
|
+
standalone: false
|
11
12
|
})
|
12
13
|
export class SideNavigationMenuComponent implements AfterViewInit, OnDestroy {
|
13
14
|
@ViewChild(DxTreeViewComponent, { static: true })
|
package/src/add-layout/files/src/app/shared/components/theme-switcher/theme-switcher.component.ts
ADDED
@@ -0,0 +1,33 @@
|
|
1
|
+
import {
|
2
|
+
Component, NgModule,
|
3
|
+
} from '@angular/core';
|
4
|
+
import { CommonModule } from '@angular/common';
|
5
|
+
import { DxButtonModule } from 'devextreme-angular';
|
6
|
+
import { ThemeService } from '../../services/theme.service';
|
7
|
+
|
8
|
+
@Component({
|
9
|
+
selector: 'theme-switcher',
|
10
|
+
template: `
|
11
|
+
<dx-button
|
12
|
+
class="theme-button"
|
13
|
+
stylingMode="text"
|
14
|
+
[icon]="themeService.currentTheme === 'dark' ? 'sun' : 'moon'"
|
15
|
+
(onClick)="onButtonClick()"
|
16
|
+
></dx-button>`,
|
17
|
+
styleUrls: [],
|
18
|
+
standalone: false
|
19
|
+
})
|
20
|
+
export class ThemeSwitcherComponent {
|
21
|
+
constructor(public themeService: ThemeService) {}
|
22
|
+
|
23
|
+
onButtonClick () {
|
24
|
+
this.themeService.switchTheme();
|
25
|
+
}
|
26
|
+
}
|
27
|
+
|
28
|
+
@NgModule({
|
29
|
+
imports: [CommonModule, DxButtonModule],
|
30
|
+
declarations: [ThemeSwitcherComponent],
|
31
|
+
exports: [ThemeSwitcherComponent],
|
32
|
+
})
|
33
|
+
export class ThemeSwitcherModule { }
|