Skip to content

Commit d1ebd75

Browse files
Killusionskfenner
authored andcommitted
feat(maps-ng): add maps-ng
1 parent 97835c4 commit d1ebd75

File tree

116 files changed

+9109
-15
lines changed

Some content is hidden

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

116 files changed

+9109
-15
lines changed

.docs-composerrc.mts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,12 @@ export const config: Config = {
1010
'projects/charts-ng',
1111
'projects/dashboards-ng',
1212
'projects/native-charts-ng',
13-
'projects/element-translate-ng'
13+
'projects/element-translate-ng',
14+
{
15+
packageDir: 'projects/maps-ng',
16+
publicEntrypoint: 'docs.ts',
17+
publicTsconfig: 'tsconfig.docs.json'
18+
}
1419
],
1520
typedocJson: 'src/assets/typedoc/**/docs.json',
1621
generate: {

.github/workflows/build-and-test.yaml

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,14 @@ on:
66
required: true
77
SIEMENS_NPM_USER:
88
required: true
9+
MAPTILER_KEY:
10+
required: true
911
pull_request:
1012

13+
env:
14+
MAPTILER_KEY: ${{ secrets.MAPTILER_KEY }}
15+
MAPTILER_URL: https://api.maptiler.com/maps/voyager/style.json?key=${{ secrets.MAPTILER_KEY }}
16+
1117
jobs:
1218
build:
1319
runs-on: ubuntu-24.04
@@ -28,7 +34,7 @@ jobs:
2834
- run: npm run prepare-brand
2935
- run: npm run build:all:update-translatable-keys # Output is needed in dist for providing default translations
3036
- run: git diff --exit-code "projects/**/*-translatable-keys.interface.ts"
31-
- run: npm run build:examples
37+
- run: npm run build:examples --define="maptilerKey='$MAPTILER_KEY'" --define="maptilerUrl='$MAPTILER_URL'"
3238
- run: npm run dashboards-demo:build:demo -- --progress=false
3339
- run: npm run dashboards-demo:build:webcomponents -- --progress=false
3440
- run: npm run dashboards-demo:build:mfe -- --progress=false
@@ -65,6 +71,7 @@ jobs:
6571
- run: npm run lib:test -- --watch=false --progress=false --code-coverage
6672
- run: npm run charts:test -- --watch=false --progress=false
6773
- run: npm run dashboards:test -- --watch=false --progress=false
74+
- run: npm run maps:test -- --watch=false --progress=false
6875
# TODO: Upload coverage reports
6976

7077
aot:
@@ -86,7 +93,7 @@ jobs:
8693
SIEMENS_NPM_TOKEN: ${{ secrets.SIEMENS_NPM_TOKEN }}
8794
- run: npm ci --prefer-offline --no-audit --include=optional
8895
- run: npm run prepare-brand
89-
- run: npm run build:examples:aot
96+
- run: npm run build:examples:aot --define="maptilerKey='$MAPTILER_KEY'" --define="maptilerUrl='$MAPTILER_URL'"
9097

9198
e2e:
9299
runs-on: ubuntu-24.04

.github/workflows/publish-documentation.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ jobs:
1010
secrets:
1111
SIEMENS_NPM_TOKEN: ${{ secrets.SIEMENS_NPM_TOKEN }}
1212
SIEMENS_NPM_USER: ${{ secrets.SIEMENS_NPM_USER }}
13+
MAPTILER_KEY: ${{ secrets.MAPTILER_KEY }}
1314

1415
publish-documentation:
1516
runs-on: ubuntu-24.04

.github/workflows/release.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ jobs:
88
secrets:
99
SIEMENS_NPM_TOKEN: ${{ secrets.SIEMENS_NPM_TOKEN }}
1010
SIEMENS_NPM_USER: ${{ secrets.SIEMENS_NPM_USER }}
11+
MAPTILER_KEY: ${{ secrets.MAPTILER_KEY }}
1112

1213
publish:
1314
runs-on: ubuntu-24.04

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,9 @@ testem.log
5252
messages.json
5353
__pycache__
5454

55+
# Environment variables
56+
/src/environments/environment.local.ts
57+
5558
# System Files
5659
.DS_Store
5760
Thumbs.db

.releaserc.js

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,12 @@ export default {
7676
pkgRoot: 'dist/@siemens/dashboards-ng'
7777
}
7878
],
79+
[
80+
'@semantic-release/npm',
81+
{
82+
pkgRoot: 'dist/@siemens/maps-ng'
83+
}
84+
],
7985
[
8086
'@semantic-release/npm',
8187
{
@@ -131,6 +137,13 @@ export default {
131137
npmPublish: false
132138
}
133139
],
140+
[
141+
'@semantic-release/npm',
142+
{
143+
pkgRoot: 'projects/maps-ng',
144+
npmPublish: false
145+
}
146+
],
134147
// Root package.json only needs version update
135148
// This must be AFTER all other package updates as this will update the peer dependencies.
136149
[

angular.json

Lines changed: 48 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,11 @@
5656
"extractLicenses": false,
5757
"sourceMap": true,
5858
"optimization": false,
59-
"namedChunks": true
59+
"namedChunks": true,
60+
"define": {
61+
"maptilerKey": "''",
62+
"maptilerUrl": "''"
63+
}
6064
},
6165
"configurations": {
6266
"production": {
@@ -78,6 +82,14 @@
7882
}
7983
]
8084
},
85+
"local-maps": {
86+
"fileReplacements": [
87+
{
88+
"replace": "src/environments/environment.ts",
89+
"with": "src/environments/environment.local-maps.ts"
90+
}
91+
]
92+
},
8193
"aot": {
8294
"aot": true,
8395
"sourceMap": false,
@@ -94,6 +106,9 @@
94106
"configurations": {
95107
"production": {
96108
"buildTarget": "element-examples:build:production"
109+
},
110+
"local": {
111+
"buildTarget": "element-examples:build:local"
97112
}
98113
}
99114
},
@@ -374,6 +389,38 @@
374389
}
375390
}
376391
},
392+
"maps-ng": {
393+
"projectType": "library",
394+
"root": "projects/maps-ng",
395+
"sourceRoot": "projects/maps-ng/src",
396+
"prefix": "si",
397+
"architect": {
398+
"build": {
399+
"builder": "@angular-devkit/build-angular:ng-packagr",
400+
"options": {
401+
"tsConfig": "projects/maps-ng/tsconfig.lib.json",
402+
"project": "projects/maps-ng/ng-package.json"
403+
}
404+
},
405+
"test": {
406+
"builder": "@angular-devkit/build-angular:karma",
407+
"options": {
408+
"builderMode": "application",
409+
"polyfills": ["zone.js", "zone.js/testing"],
410+
"tsConfig": "projects/maps-ng/tsconfig.spec.json",
411+
"karmaConfig": "projects/maps-ng/karma.conf.cjs",
412+
"codeCoverageExclude": ["projects/maps-ng/src/**/*.module.ts"]
413+
}
414+
},
415+
"lint": {
416+
"builder": "@angular-eslint/builder:lint",
417+
"options": {
418+
"lintFilePatterns": ["projects/maps-ng/**/*.ts", "projects/maps-ng/**/*.html"],
419+
"eslintConfig": "projects/maps-ng/eslint.config.js"
420+
}
421+
}
422+
}
423+
},
377424
"dashboards-ng": {
378425
"projectType": "library",
379426
"root": "projects/dashboards-ng",

docs/components/index.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@ documentation.
7575
## M
7676

7777
- [Main-Detail Container](layout-navigation/main-detail-container.md)
78+
- [Maps](maps/maps.md)
7879
- [Menu](buttons-menus/menu.md)
7980
- [Micro charts](charts/micro-charts.md)
8081
- [Modals](layout-navigation/modals.md)
370 KB
Loading
427 KB
Loading

0 commit comments

Comments
 (0)