@openrail/netzgrafik-editor-frontend 2.10.19

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.
Files changed (37) hide show
  1. package/LICENSE +202 -0
  2. package/README.md +337 -0
  3. package/dist/netzgrafik-frontend/assets/i18n/de.json +706 -0
  4. package/dist/netzgrafik-frontend/assets/i18n/en.json +706 -0
  5. package/dist/netzgrafik-frontend/assets/i18n/fr.json +706 -0
  6. package/dist/netzgrafik-frontend/favicon.ico +0 -0
  7. package/dist/netzgrafik-frontend/index.html +14 -0
  8. package/dist/netzgrafik-frontend/main.js +48605 -0
  9. package/dist/netzgrafik-frontend/main.js.map +1 -0
  10. package/dist/netzgrafik-frontend/node_modules_angular_common_locales_de_mjs.js +56 -0
  11. package/dist/netzgrafik-frontend/node_modules_angular_common_locales_de_mjs.js.map +1 -0
  12. package/dist/netzgrafik-frontend/node_modules_angular_common_locales_en_mjs.js +35 -0
  13. package/dist/netzgrafik-frontend/node_modules_angular_common_locales_en_mjs.js.map +1 -0
  14. package/dist/netzgrafik-frontend/node_modules_angular_common_locales_extra_de_mjs.js +28 -0
  15. package/dist/netzgrafik-frontend/node_modules_angular_common_locales_extra_de_mjs.js.map +1 -0
  16. package/dist/netzgrafik-frontend/node_modules_angular_common_locales_extra_en_mjs.js +28 -0
  17. package/dist/netzgrafik-frontend/node_modules_angular_common_locales_extra_en_mjs.js.map +1 -0
  18. package/dist/netzgrafik-frontend/node_modules_angular_common_locales_extra_fr_mjs.js +28 -0
  19. package/dist/netzgrafik-frontend/node_modules_angular_common_locales_extra_fr_mjs.js.map +1 -0
  20. package/dist/netzgrafik-frontend/node_modules_angular_common_locales_extra_kde_mjs.js +28 -0
  21. package/dist/netzgrafik-frontend/node_modules_angular_common_locales_extra_kde_mjs.js.map +1 -0
  22. package/dist/netzgrafik-frontend/node_modules_angular_common_locales_fr_mjs.js +84 -0
  23. package/dist/netzgrafik-frontend/node_modules_angular_common_locales_fr_mjs.js.map +1 -0
  24. package/dist/netzgrafik-frontend/node_modules_angular_common_locales_kde_mjs.js +36 -0
  25. package/dist/netzgrafik-frontend/node_modules_angular_common_locales_kde_mjs.js.map +1 -0
  26. package/dist/netzgrafik-frontend/polyfills.js +3861 -0
  27. package/dist/netzgrafik-frontend/polyfills.js.map +1 -0
  28. package/dist/netzgrafik-frontend/runtime.js +334 -0
  29. package/dist/netzgrafik-frontend/runtime.js.map +1 -0
  30. package/dist/netzgrafik-frontend/src_assets_i18n_de_json.js +14 -0
  31. package/dist/netzgrafik-frontend/src_assets_i18n_en_json.js +14 -0
  32. package/dist/netzgrafik-frontend/src_assets_i18n_fr_json.js +14 -0
  33. package/dist/netzgrafik-frontend/styles.css +155 -0
  34. package/dist/netzgrafik-frontend/styles.css.map +1 -0
  35. package/dist/netzgrafik-frontend/vendor.js +177368 -0
  36. package/dist/netzgrafik-frontend/vendor.js.map +1 -0
  37. package/package.json +35 -0
package/LICENSE ADDED
@@ -0,0 +1,202 @@
1
+
2
+ Apache License
3
+ Version 2.0, January 2004
4
+ http://www.apache.org/licenses/
5
+
6
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
+
8
+ 1. Definitions.
9
+
10
+ "License" shall mean the terms and conditions for use, reproduction,
11
+ and distribution as defined by Sections 1 through 9 of this document.
12
+
13
+ "Licensor" shall mean the copyright owner or entity authorized by
14
+ the copyright owner that is granting the License.
15
+
16
+ "Legal Entity" shall mean the union of the acting entity and all
17
+ other entities that control, are controlled by, or are under common
18
+ control with that entity. For the purposes of this definition,
19
+ "control" means (i) the power, direct or indirect, to cause the
20
+ direction or management of such entity, whether by contract or
21
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
22
+ outstanding shares, or (iii) beneficial ownership of such entity.
23
+
24
+ "You" (or "Your") shall mean an individual or Legal Entity
25
+ exercising permissions granted by this License.
26
+
27
+ "Source" form shall mean the preferred form for making modifications,
28
+ including but not limited to software source code, documentation
29
+ source, and configuration files.
30
+
31
+ "Object" form shall mean any form resulting from mechanical
32
+ transformation or translation of a Source form, including but
33
+ not limited to compiled object code, generated documentation,
34
+ and conversions to other media types.
35
+
36
+ "Work" shall mean the work of authorship, whether in Source or
37
+ Object form, made available under the License, as indicated by a
38
+ copyright notice that is included in or attached to the work
39
+ (an example is provided in the Appendix below).
40
+
41
+ "Derivative Works" shall mean any work, whether in Source or Object
42
+ form, that is based on (or derived from) the Work and for which the
43
+ editorial revisions, annotations, elaborations, or other modifications
44
+ represent, as a whole, an original work of authorship. For the purposes
45
+ of this License, Derivative Works shall not include works that remain
46
+ separable from, or merely link (or bind by name) to the interfaces of,
47
+ the Work and Derivative Works thereof.
48
+
49
+ "Contribution" shall mean any work of authorship, including
50
+ the original version of the Work and any modifications or additions
51
+ to that Work or Derivative Works thereof, that is intentionally
52
+ submitted to Licensor for inclusion in the Work by the copyright owner
53
+ or by an individual or Legal Entity authorized to submit on behalf of
54
+ the copyright owner. For the purposes of this definition, "submitted"
55
+ means any form of electronic, verbal, or written communication sent
56
+ to the Licensor or its representatives, including but not limited to
57
+ communication on electronic mailing lists, source code control systems,
58
+ and issue tracking systems that are managed by, or on behalf of, the
59
+ Licensor for the purpose of discussing and improving the Work, but
60
+ excluding communication that is conspicuously marked or otherwise
61
+ designated in writing by the copyright owner as "Not a Contribution."
62
+
63
+ "Contributor" shall mean Licensor and any individual or Legal Entity
64
+ on behalf of whom a Contribution has been received by Licensor and
65
+ subsequently incorporated within the Work.
66
+
67
+ 2. Grant of Copyright License. Subject to the terms and conditions of
68
+ this License, each Contributor hereby grants to You a perpetual,
69
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70
+ copyright license to reproduce, prepare Derivative Works of,
71
+ publicly display, publicly perform, sublicense, and distribute the
72
+ Work and such Derivative Works in Source or Object form.
73
+
74
+ 3. Grant of Patent License. Subject to the terms and conditions of
75
+ this License, each Contributor hereby grants to You a perpetual,
76
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77
+ (except as stated in this section) patent license to make, have made,
78
+ use, offer to sell, sell, import, and otherwise transfer the Work,
79
+ where such license applies only to those patent claims licensable
80
+ by such Contributor that are necessarily infringed by their
81
+ Contribution(s) alone or by combination of their Contribution(s)
82
+ with the Work to which such Contribution(s) was submitted. If You
83
+ institute patent litigation against any entity (including a
84
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
85
+ or a Contribution incorporated within the Work constitutes direct
86
+ or contributory patent infringement, then any patent licenses
87
+ granted to You under this License for that Work shall terminate
88
+ as of the date such litigation is filed.
89
+
90
+ 4. Redistribution. You may reproduce and distribute copies of the
91
+ Work or Derivative Works thereof in any medium, with or without
92
+ modifications, and in Source or Object form, provided that You
93
+ meet the following conditions:
94
+
95
+ (a) You must give any other recipients of the Work or
96
+ Derivative Works a copy of this License; and
97
+
98
+ (b) You must cause any modified files to carry prominent notices
99
+ stating that You changed the files; and
100
+
101
+ (c) You must retain, in the Source form of any Derivative Works
102
+ that You distribute, all copyright, patent, trademark, and
103
+ attribution notices from the Source form of the Work,
104
+ excluding those notices that do not pertain to any part of
105
+ the Derivative Works; and
106
+
107
+ (d) If the Work includes a "NOTICE" text file as part of its
108
+ distribution, then any Derivative Works that You distribute must
109
+ include a readable copy of the attribution notices contained
110
+ within such NOTICE file, excluding those notices that do not
111
+ pertain to any part of the Derivative Works, in at least one
112
+ of the following places: within a NOTICE text file distributed
113
+ as part of the Derivative Works; within the Source form or
114
+ documentation, if provided along with the Derivative Works; or,
115
+ within a display generated by the Derivative Works, if and
116
+ wherever such third-party notices normally appear. The contents
117
+ of the NOTICE file are for informational purposes only and
118
+ do not modify the License. You may add Your own attribution
119
+ notices within Derivative Works that You distribute, alongside
120
+ or as an addendum to the NOTICE text from the Work, provided
121
+ that such additional attribution notices cannot be construed
122
+ as modifying the License.
123
+
124
+ You may add Your own copyright statement to Your modifications and
125
+ may provide additional or different license terms and conditions
126
+ for use, reproduction, or distribution of Your modifications, or
127
+ for any such Derivative Works as a whole, provided Your use,
128
+ reproduction, and distribution of the Work otherwise complies with
129
+ the conditions stated in this License.
130
+
131
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
132
+ any Contribution intentionally submitted for inclusion in the Work
133
+ by You to the Licensor shall be under the terms and conditions of
134
+ this License, without any additional terms or conditions.
135
+ Notwithstanding the above, nothing herein shall supersede or modify
136
+ the terms of any separate license agreement you may have executed
137
+ with Licensor regarding such Contributions.
138
+
139
+ 6. Trademarks. This License does not grant permission to use the trade
140
+ names, trademarks, service marks, or product names of the Licensor,
141
+ except as required for reasonable and customary use in describing the
142
+ origin of the Work and reproducing the content of the NOTICE file.
143
+
144
+ 7. Disclaimer of Warranty. Unless required by applicable law or
145
+ agreed to in writing, Licensor provides the Work (and each
146
+ Contributor provides its Contributions) on an "AS IS" BASIS,
147
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148
+ implied, including, without limitation, any warranties or conditions
149
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150
+ PARTICULAR PURPOSE. You are solely responsible for determining the
151
+ appropriateness of using or redistributing the Work and assume any
152
+ risks associated with Your exercise of permissions under this License.
153
+
154
+ 8. Limitation of Liability. In no event and under no legal theory,
155
+ whether in tort (including negligence), contract, or otherwise,
156
+ unless required by applicable law (such as deliberate and grossly
157
+ negligent acts) or agreed to in writing, shall any Contributor be
158
+ liable to You for damages, including any direct, indirect, special,
159
+ incidental, or consequential damages of any character arising as a
160
+ result of this License or out of the use or inability to use the
161
+ Work (including but not limited to damages for loss of goodwill,
162
+ work stoppage, computer failure or malfunction, or any and all
163
+ other commercial damages or losses), even if such Contributor
164
+ has been advised of the possibility of such damages.
165
+
166
+ 9. Accepting Warranty or Additional Liability. While redistributing
167
+ the Work or Derivative Works thereof, You may choose to offer,
168
+ and charge a fee for, acceptance of support, warranty, indemnity,
169
+ or other liability obligations and/or rights consistent with this
170
+ License. However, in accepting such obligations, You may act only
171
+ on Your own behalf and on Your sole responsibility, not on behalf
172
+ of any other Contributor, and only if You agree to indemnify,
173
+ defend, and hold each Contributor harmless for any liability
174
+ incurred by, or claims asserted against, such Contributor by reason
175
+ of your accepting any such warranty or additional liability.
176
+
177
+ END OF TERMS AND CONDITIONS
178
+
179
+ APPENDIX: How to apply the Apache License to your work.
180
+
181
+ To apply the Apache License to your work, attach the following
182
+ boilerplate notice, with the fields enclosed by brackets "[]"
183
+ replaced with your own identifying information. (Don't include
184
+ the brackets!) The text should be enclosed in the appropriate
185
+ comment syntax for the file format. We also recommend that a
186
+ file or class name and description of purpose be included on the
187
+ same "printed page" as the copyright notice for easier
188
+ identification within third-party archives.
189
+
190
+ Copyright 2024 Swiss Federal Railways SBB AG
191
+
192
+ Licensed under the Apache License, Version 2.0 (the "License");
193
+ you may not use this file except in compliance with the License.
194
+ You may obtain a copy of the License at
195
+
196
+ http://www.apache.org/licenses/LICENSE-2.0
197
+
198
+ Unless required by applicable law or agreed to in writing, software
199
+ distributed under the License is distributed on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201
+ See the License for the specific language governing permissions and
202
+ limitations under the License.
package/README.md ADDED
@@ -0,0 +1,337 @@
1
+ # Netzgrafik-Editor
2
+
3
+ <details>
4
+ <summary>
5
+ Netzgrafik-Editor – designed to make better decisions.
6
+ </summary>
7
+
8
+ <br>
9
+ The product vision is to accelerate the planning and sizing of transport systems by creating an intuitive and powerful platform that uses smart projections and analyses. This will enable timetable variations or service options to be created, compared, and optimized very easily, with maximum support for the human planner during their creative process. The goal is to ensure that decisions can be made based on data-driven insights, to guarantee a smooth mobility for the future that is fast, efficient, and goal-oriented.
10
+ <br><br>
11
+
12
+ > **Flexible level of detail** - start with a rough sketch, continuously add more detail.
13
+ >
14
+ > Applicable across **different industries** - bus, train, plane.
15
+ >
16
+ > **Scales with your use-case** - from hobbyist timetabling to professional planning.
17
+ >
18
+ > **Human-centric** - timetable planning is a very complex and creative process. Netzgrafik-Editor
19
+ > supports the user by digitalizing the previously paper-driven process, while providing instant
20
+ > analysis capabilities.
21
+ >
22
+ > **Excellent and intuitive UX** - using Netzgrafik-Editor should be as easy and natural as drawing
23
+ > on a whiteboard. No training required. Analysis happens in real time.
24
+
25
+ </details>
26
+
27
+ ## Introduction
28
+
29
+ The Netzgrafik-Editor is a powerful software that enables the creation, modification, and analysis
30
+ of regular-interval timetable.
31
+
32
+ <details>
33
+ <summary>
34
+ Regular-interval timetable
35
+ </summary>
36
+
37
+ <br>
38
+
39
+ > Regular-interval timetables were first developed in Germany at the beginning of the 20th century
40
+ > to coordinate urban traffic in large cities such as Berlin.
41
+ >
42
+ > The regular schedules aim to increase the attractiveness of public transport because they’re
43
+ > easier to memorise for passengers and because the patterns make the planning of resources easier.
44
+ >
45
+ > Such constant schedules may also improve services during off-peak hours.
46
+ >
47
+ > The Dutch were in 1970 credited with the first junction system, which then was the basis for the
48
+ > Swiss regular-interval timetable in 1982.
49
+ >
50
+ > [History - The regular-interval timetable](https://houseofswitzerland.org/swissstories/history/nation-railway-enthusiasts-history-swiss-railways)
51
+ >
52
+ > [clock-faced schedules](https://en.wikipedia.org/wiki/Clock-face_scheduling)
53
+ >
54
+ > [Source](https://www.swissinfo.ch/eng/to-the-second_the-swiss-timetable-is-due-to-meticulous-planning/34102496)
55
+
56
+ </details>
57
+
58
+ ![Netzgrafik-Editor](./documentation/images/Overview_Editor_Screenshot_001.PNG)
59
+
60
+ It offers various functions to enhance the efficiency and optimization of the logistics network.
61
+ Some of the key features include:
62
+
63
+ - **Interactive drawing tool to edit the Netzgrafik:** A user-friendly and interactive graphical
64
+ editor for creating and editing regular-interval timetables. It provides a
65
+ visual interface to easily visualize and adjust the logistics network.
66
+
67
+ - **Graphic timetable (Streckengrafik):**
68
+ All lines (trainruns) defined in the Netzgrafik can be transferred into a graphical timetable
69
+ representation (Streckengrafik).
70
+
71
+ - **Perlenkette trainrun editing:** Planners can manually draw and edit the trainruns as a chain,
72
+ allowing them
73
+ to define crucial aspects of the logistics network and tailor it
74
+ to specific requirements and constraints.
75
+
76
+ - **Logistical Information Extraction:** The software extracts important logistical information from
77
+ the regular-interval timetable,
78
+ such as departure and destination stations, departure and arrival times, and train frequency.
79
+
80
+ - **Logistics Network Analysis:** Planners can analyze the logistics network based on the timetable
81
+ representation.
82
+ The software provides insights into connection coordination, transfer times, and logistical
83
+ connections, facilitating optimization and efficiency improvement.
84
+
85
+ - **Infrastructure Requirement Estimation:** Infrastructure requirements can be estimated based on
86
+ the entered timetable representation,
87
+ aiding in infrastructure planning and decision-making.
88
+
89
+ ## Origin and Open Source Collaboration
90
+
91
+ The Netzgrafik-Editor, initially developed as an internal innovation project at the
92
+ [Swiss Federal Railways (SBB CFF FFS)](https://www.sbb.ch).
93
+ The project started with a clickable prototype. From this early stage of the project,
94
+ there are still ideas and concepts that have not yet been realised, so it is always worth taking a
95
+ look [at this document](https://xd.adobe.com/view/e4664ae0-be8f-40e4-6a55-88aec9eafd8d-9257/).
96
+ The entire project has now reached a mature stage and evolved into a powerful tool with applications
97
+ beyond railways. It can now be utilized in any domain that requires regular-interval timetables as a
98
+ planning basis.
99
+
100
+ The versatility of the editor makes it suitable for various logistics planning scenarios, enabling
101
+ efficient timetable creation and analysis. The software's key features can be leveraged in a broader
102
+ context, such as:
103
+
104
+ - **Public Transportation Systems:** Other public transport networks can utilize the editor's
105
+ flexibility and features to effectively visualize and plan their transportation systems,
106
+ leading to improved efficiency and better services.
107
+
108
+ - **Educations:** The editor's capabilities can be utilized in educational institutions to demonstrate
109
+ how to create integrated timetables and what properties need to be considered during the planning
110
+ process in order to enable efficient scheduling
111
+
112
+ <details>
113
+ <summary>more ...
114
+ </summary>
115
+
116
+ By extending the scope of its application beyond railways, the Netzgrafik-Editor has the potential
117
+ to become a valuable tool in numerous sectors,
118
+ providing comprehensive control, optimization, and synchronization of time-based planning.
119
+
120
+ Due to these diverse applications of the Netzgrafik-Editor and its increasing value in various
121
+ areas,
122
+ the decision was made to release it as open source software.
123
+ This is intended to promote broad use and collaboration at the planning level,
124
+ as well as actively support the further development of new ideas from different industries so that
125
+ the editor constantly improves and,
126
+ in the best case, establishes itself as a standard tool across different public transportation
127
+ industries.
128
+
129
+ </details>
130
+
131
+ Community [participation and collaboration](CONTRIBUTING.md)
132
+ in the development process is extremely important and desired to ensure that the editor gains
133
+ diversity
134
+ and functionality and meets the needs and challenges of different application domains.
135
+ The openness of the project encourages innovation, expertise from different sectors and continuous
136
+ improvements to optimize the
137
+ planning processes.
138
+
139
+ ## Roadmap
140
+
141
+ Get an insight into the plan and future [ROADMAP.md](ROADMAP.md).
142
+
143
+ ## User Manual
144
+
145
+ The user manual can be found here [USERMANUAL.md](documentation/USERMANUAL.md)
146
+
147
+ ## Online Demo
148
+
149
+ [Extern: nge.flatland.cloud](https://nge.flatland.cloud) - powered by [Flatland Association](https://www.flatland-association.org/)
150
+
151
+ ( [Sample Netzgrafik](https://github.com/SchweizerischeBundesbahnen/netzgrafik-editor-frontend/blob/main/src/app/sample-netzgrafik/Demo_Netzgrafik_Fernverkehr_2024.json) - [How to Import JSON](https://github.com/SchweizerischeBundesbahnen/netzgrafik-editor-frontend/blob/main/documentation/technical/DATA_MODEL_JSON.md) )
152
+
153
+ ## Setup Local Demo Environment with Docker Compose
154
+
155
+ Use [extern: netzgrafik-editor-docker-compose](https://github.com/flatland-association/netzgrafik-editor-docker-compose) for a one-line setup based
156
+ on [Docker Compose](https://docs.docker.com/compose/) - powered by [Flatland Association](https://www.flatland-association.org/).
157
+
158
+ ## Getting-Started
159
+
160
+ ### Development setup
161
+
162
+ For a working local development setup, you also need to start
163
+ the [backend](https://github.com/SchweizerischeBundesbahnen/netzgrafik-editor-backend)!
164
+
165
+ ```shell
166
+ # clone project from https://github.com/SchweizerischeBundesbahnen/netzgrafik-editor-frontend
167
+ git clone https://github.com/SchweizerischeBundesbahnen/netzgrafik-editor-frontend.git
168
+
169
+ # switch into folder
170
+ cd netzgrafik-editor-frontend
171
+
172
+ ```
173
+
174
+ ```shell
175
+ # install all npm dependencies
176
+ npm install
177
+
178
+ # start ng server (connects to local backend, make sure it is set up and running)
179
+ npm run start
180
+ ```
181
+
182
+ #### The dockerized variant
183
+
184
+ ```shell
185
+ # install
186
+ apt install docker
187
+ apt install docker-compose-plugin
188
+
189
+ # build
190
+ docker compose build
191
+
192
+ # run
193
+ docker compose up
194
+ ```
195
+
196
+ #### Access to Netzgrafik-Editor frontend
197
+
198
+ > open address in browser http://localhost:4200/
199
+ >
200
+ > Login with username **user** and password **user**
201
+
202
+ #### For Nix Package Manager users
203
+
204
+ Nix users can use the `flake.nix` file to setup a development environment.
205
+
206
+ To use the flake, the Nix experimental features `nix-command` and `flakes` are required.
207
+
208
+ See [official Nix documentation](https://nixos.wiki/wiki/Flakes) for more information.
209
+
210
+ Combined with the `direnv` tool, the following commands can be used to setup the development environment each time the project folder is entered:
211
+
212
+ ```shell
213
+ # allow direnv to use the flake
214
+ echo "use flake" >> .envrc && direnv allow
215
+ ```
216
+
217
+ See [official direnv documentation](https://direnv.net/) for more information.
218
+
219
+ ### Linting
220
+
221
+ ```sh
222
+ # to fix the eventual lint issues
223
+ npm run lint
224
+
225
+ # to check that the code is correctly linted
226
+ npm run lint:fix
227
+ ```
228
+
229
+ ### Formatting
230
+
231
+ Since we use Prettier as formatter, you can freely setup you favorite IDE to support you in the way. For example, if you use VSCode, follow these steps:
232
+
233
+ - install the [Prettier extension](https://marketplace.visualstudio.com/items?itemName=esbenp.prettier-vscode)
234
+ - (optionnal: install Prettier via npm `npm install --global prettier`)
235
+ - now, if you try left-click and select "Format Document", you'll be able to format manually using Prettier
236
+
237
+ Nice to have: Format on Save
238
+
239
+ - you can enable this functionnality by opening VSCode "Settings" and activate "Editor: Format on Save" (this way, your code will be formatted each time your file is saved)
240
+ - alternatively, you can just add these lines in `settings.json` (open using `Cmd` + `shift` + `p` and search "Open User Settings (JSON)")
241
+
242
+ ```json
243
+ {
244
+ "editor.formatOnSave": true,
245
+ "editor.defaultFormatter": "esbenp.prettier-vscode"
246
+ }
247
+ ```
248
+
249
+ ```sh
250
+ # to check that the code is correctly formatted
251
+ npm run format:check
252
+
253
+ # to format the code according to Prettier rules
254
+ npm run format
255
+ ```
256
+
257
+ ### Testing
258
+
259
+ ```sh
260
+
261
+ ### Testing
262
+
263
+ ```
264
+
265
+ # just run the test once
266
+
267
+ npm run test
268
+
269
+ # or run the test in the browser
270
+
271
+ npm run test -- --browsers Chrome
272
+
273
+ ````
274
+
275
+ ## Backend API code generation
276
+
277
+ The backend API is specified using [OpenAPI](https://swagger.io/specification/) (
278
+ see `api-docs.json`).
279
+ Angular Services for the communication with the backend API are generated based on this
280
+ specification using [openapi-generator](https://github.com/openapitools/openapi-generator) and added
281
+ to the repo (see `src/app/api/generated`).
282
+
283
+ ### Update the API Version
284
+
285
+ In order to update the API Version start the local backend server.
286
+ The new spec can then be downloaded at <http://localhost:8080/v3/api-docs/>.
287
+
288
+ The new API Service files can be generated using the following command:
289
+
290
+ ```shell
291
+ npm run generate:api
292
+ ````
293
+
294
+ ## Documentation
295
+
296
+ Please consider the following information:
297
+
298
+ - [DATA MODEL](./documentation/technical/DATA_MODEL.md)
299
+
300
+ - [CODING_STANDARDS.md](CODING_STANDARDS.md)
301
+ - [CONTRIBUTING.md](CONTRIBUTING.md)
302
+
303
+ and check the
304
+ open [issues](https://github.com/SchweizerischeBundesbahnen/netzgrafik-editor-frontend/issues)
305
+ and [pull requests](https://github.com/SchweizerischeBundesbahnen/netzgrafik-editor-frontend/pulls).
306
+
307
+ ## License
308
+
309
+ This project is licensed under [Apache 2.0](LICENSE).
310
+
311
+ ## Contributing
312
+
313
+ Open-source projects thrive on collaboration and contributions from the community. All
314
+ contributors are requested to read the [CONTRIBUTING.md](CONTRIBUTING.md) file as it outlines how to
315
+ contribute to the project, including how to submit bug reports, feature requests, and pull requests.
316
+
317
+ ## Coding Standards
318
+
319
+ All contributors are requested to read the [CODING_STANDARDS.md](CODING_STANDARDS.md) file that
320
+ outlines the coding standards that you should follow when contributing to the project.
321
+
322
+ ## Code of Conduct
323
+
324
+ To ensure that the project is a welcoming and an inclusive environment for all contributors, you, it
325
+ has established a good [CODE_OF_CONDUCT.md](CODE_OF_CONDUCT.md).
326
+
327
+ ## Credits
328
+
329
+ Many thanks to all contributors for their engagement and contribution, without which this project
330
+ would not have been possible. Thank you for your current and future contribution!
331
+
332
+ [CREDITS.md](CREDITS.md)
333
+
334
+ ## Continuous Integration
335
+
336
+ This repository uses [release-please](https://github.com/googleapis/release-please) for CHANGELOG generation, the creation of GitHub releases, and version bumps for your projects.
337
+ See [CI.md](CI.md) for details.