@cima-foundation/schematics 0.4.10 → 0.4.11

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.
package/.idea/vcs.xml CHANGED
@@ -1,5 +1,11 @@
1
1
  <?xml version="1.0" encoding="UTF-8"?>
2
2
  <project version="4">
3
+ <component name="CommitMessageInspectionProfile">
4
+ <profile version="1.0">
5
+ <inspection_tool class="CommitFormat" enabled="true" level="WARNING" enabled_by_default="true" />
6
+ <inspection_tool class="CommitNamingConvention" enabled="true" level="WARNING" enabled_by_default="true" />
7
+ </profile>
8
+ </component>
3
9
  <component name="VcsDirectoryMappings">
4
10
  <mapping directory="" vcs="Git" />
5
11
  </component>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cima-foundation/schematics",
3
- "version": "0.4.10",
3
+ "version": "0.4.11",
4
4
  "description": "A blank schematics",
5
5
  "scripts": {
6
6
  "build": "tsc -p tsconfig.json",
@@ -89,7 +89,7 @@
89
89
  {
90
90
  "type": "initial",
91
91
  "maximumWarning": "750kb",
92
- "maximumError": "2mb"
92
+ "maximumError": "8mb"
93
93
  },
94
94
  {
95
95
  "type": "anyComponentStyle",
@@ -32,8 +32,7 @@
32
32
  "@angular/platform-browser-dynamic": "~13.3.0",
33
33
  "@angular/router": "~13.3.0",
34
34
  "@angular/service-worker": "~13.3.0",
35
- "@cima/commons": "git+https://github.com/CIMAFoundation/ngx-cima-commons.git#v0.9.58",
36
- "@cima/dashboard": "git+https://github.com/CIMAFoundation/ngx-cima-dashboard.git#v0.4.4",
35
+ "@cima/commons": "git+https://github.com/CIMAFoundation/ngx-cima-commons.git#v0.13.6",
37
36
  "@fortawesome/fontawesome-free": "^6.3.0",
38
37
  "@kolkov/angular-editor": "2.0.0",
39
38
  "@ngneat/until-destroy": "^8.1.4",
@@ -8,29 +8,18 @@ import {
8
8
  } from '@cima/commons';
9
9
 
10
10
  const routes: Routes = [
11
- {
12
- path: '',
13
- redirectTo: '<%= dasherize(name) %>',
14
- pathMatch: 'full',
15
- },
16
-
17
11
  {
18
12
  path: '',
19
13
  component: PortalContainerComponent,
20
14
  canActivate: [AuthGuard],
21
15
  children: [
22
- {
23
- path: 'dashboard',
24
- loadChildren: () =>
25
- import('@cima/dashboard').then((m) => m.DashboardModule),
26
- },
27
16
  {
28
17
  path: 'credits',
29
18
  loadChildren: () =>
30
19
  import('./credits/credits.module').then((m) => m.CreditsModule),
31
20
  },
32
21
  {
33
- path: '<%= dasherize(name) %>',
22
+ path: '',
34
23
  loadChildren: () =>
35
24
  import('@cima/<%= dasherize(name) %>').then((m) => m.Cima<%= classify(name) %>Module),
36
25
  },
@@ -1,5 +1,3 @@
1
- <cima-credits>
2
- <ng-container tor>
3
- <cima-tor></cima-tor>
4
- </ng-container>
5
- </cima-credits>
1
+ <cima-page-container style="background-color:unset">
2
+ <commons-credits [credits]="credits"></commons-credits>
3
+ </cima-page-container>
@@ -1,15 +1,24 @@
1
- import { Component, OnInit } from '@angular/core';
2
- import { Title } from '@angular/platform-browser';
1
+ import { Component, AfterViewInit } from '@angular/core';
2
+ import {CimaConfigService, FaviconService, PortalService} from '@cima/commons';
3
3
 
4
4
  @Component({
5
5
  selector: 'cima-credits-page',
6
6
  templateUrl: './credits-page.component.html',
7
7
  styleUrls: ['./credits-page.component.scss'],
8
8
  })
9
- export class CreditsPageComponent implements OnInit {
10
- constructor(private titleService: Title) {}
9
+ export class CreditsPageComponent implements AfterViewInit {
10
+ constructor(
11
+ private portalService: PortalService,
12
+ private faviconService: FaviconService,
13
+ private configService: CimaConfigService
14
+ ) {}
11
15
 
12
- ngOnInit(): void {
13
- this.titleService.setTitle($localize`Credits`);
16
+ credits: any[]
17
+ ngAfterViewInit(): void {
18
+ this.portalService.setTitle(`Credits`);
19
+ this.faviconService.setPortalFavicon();
20
+ this.configService.getStaticCredits().subscribe((credits) => {
21
+ this.credits = credits;
22
+ } );
14
23
  }
15
24
  }
@@ -1,12 +1,17 @@
1
+ const protocol = window.location.protocol;
2
+ const hostname = window.location.hostname;
3
+ let port = window.location.port ? `:${window.location.port}` : '';
4
+
5
+ const wsProtocol = protocol === 'https:' ? 'wss:' : 'ws:';
6
+
1
7
  export const environment = {
2
- title: '<%= classify(name) %> Test App',
8
+ title: '<%= classify(name) %>',
3
9
  production: true,
4
10
  fakeData: false,
5
11
  debug: true,
6
12
  server: {
7
- baseUrl: 'https://acroweb3-portal-backend-test.cimafoundation.org',
8
- configEndpoint: '/acroweb',
9
- wsEndpoint:
10
- 'ws://acroweb3-portal-backend-test.cimafoundation.org/ws/notifier/',
13
+ baseUrl: `${protocol}//${hostname}${port}/api`,
14
+ configEndpoint: `/acroweb`,
15
+ wsEndpoint: `${wsProtocol}//${hostname}${port}/ws/notifier/`,
11
16
  },
12
17
  };
@@ -3,23 +3,15 @@
3
3
  // The list of file replacements can be found in `angular.json`.
4
4
 
5
5
  export const environment = {
6
- title: '<%= classify(name) %> Test App',
6
+ title: '<%= classify(name) %>',
7
7
  production: false,
8
8
  fakeData: false,
9
9
  debug: true,
10
10
  server: {
11
- baseUrl: 'https://acroweb3-portal-backend-test.cimafoundation.org',
11
+ baseUrl: 'https://mydewetra3-staging.cimafoundation.org/api',
12
12
  configEndpoint: '/acroweb',
13
13
  wsEndpoint:
14
- 'ws://acroweb3-portal-backend-test.cimafoundation.org/ws/notifier/',
14
+ 'wss://mydewetra3-staging.cimafoundation.org/ws/notifier/',
15
15
  },
16
16
  };
17
17
 
18
- /*
19
- * For easier debugging in development mode, you can import the following file
20
- * to ignore zone related error stack frames such as `zone.run`, `zoneDelegate.invokeTask`.
21
- *
22
- * This import should be commented out in production mode because it will have a negative impact
23
- * on performance if an error is thrown.
24
- */
25
- // import 'zone.js/plugins/zone-error'; // Included with Angular CLI.
@@ -1,6 +1,6 @@
1
1
  <cima-app-container mode="side">
2
2
  <ng-container app-menu>
3
- <a [routerLink]="['/', '<%= dasherize(name) %>']">Home</a>
3
+ <a routerLink="'./<%= dasherize(name) %>'">Home</a>
4
4
  </ng-container>
5
5
 
6
6
  <app-sidenav-tab icon="list" i18-label label="Tab Label">
@@ -17,9 +17,15 @@ export class <%= classify(name) %>AppContainerComponent implements AfterViewIni
17
17
  private portalService: PortalService,
18
18
  public translate: TranslateService,
19
19
  ) {
20
+
21
+ let portal_current_language: string = this.translate.currentLang;
22
+ if(!portal_current_language) portal_current_language = this.translate.defaultLang;
23
+ this.portalService.getPortalLabels('mydewetra', '<%= dasherize(name) %>', portal_current_language);
24
+
20
25
  this.translate.onLangChange.subscribe((event: LangChangeEvent) => {
21
26
  this.portalService.getPortalLabels('mydewetra', '<%= dasherize(name) %>', event.lang);
22
27
  });
28
+
23
29
  }
24
30
 
25
31
  ngAfterViewInit() {