Skip to content

Commit bf6a05f

Browse files
Merge pull request #24 from catenax-ng/feature/TRACEFOSS-xxx-editor-config
Added editor config.
2 parents 758981b + e5a0ef3 commit bf6a05f

File tree

15 files changed

+759
-59
lines changed

15 files changed

+759
-59
lines changed

.dockerignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
**/node_modules/
22
**/dist
3-
.git
3+
.git

.editorconfig

Lines changed: 699 additions & 0 deletions
Large diffs are not rendered by default.

.eslintignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ node_modules
22
dist
33

44
src/main.ts
5-
src/polyfills.ts
5+
src/polyfills.ts

.lintstagedrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
22
"*.(js|ts|json|md|css|scss|html)": ["npm run format", "npm run lint"]
3-
}
3+
}

.prettierrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@
55
"printWidth": 120,
66
"tabWidth": 2,
77
"arrowParens": "avoid"
8-
}
8+
}

CODE_OF_CONDUCT.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Community Code of Conduct
22

3-
**Version 1.2
3+
**Version 1.2
44
August 19, 2020**
55

66
## Our Pledge

INSTALL.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ This variable points to the desired api
2525
This variable is used to set the base path of the application. (Should be set if application runs as a subtopic)
2626

2727
`CATENAX_PORTAL_BACKEND_DOMAIN`
28-
This variable is needed for security, to be more explicit, for the security headers of a request.
29-
The domain of the corresponding backend should be used here.
28+
This variable is needed for security, to be more explicit, for the security headers of a request.
29+
The domain of the corresponding backend should be used here.
3030
An example value could be: `catena-x.net`
3131

3232
# Helm deployment
@@ -52,13 +52,13 @@ ingress:
5252
cert-manager.io/cluster-issuer: letsencrypt-prod
5353
hosts:
5454
- host: "${FE_HOST_URL}"
55-
paths:
55+
paths:
5656
- path: /
57-
pathType: Prefix
57+
pathType: Prefix
5858
tls:
5959
- hosts:
6060
- "${FE_HOST_URL}"
61-
secretName: "${FE_HOST_URL}-tls"
61+
secretName: "${FE_HOST_URL}-tls"
6262

6363
```
6464

@@ -129,5 +129,5 @@ The operator can set any environment variable in the container by using one or m
129129

130130
#### `${dockerImage}`
131131

132-
While not strictly a means of identifying a container, you can specify a version of an image you’d like to run the container with by adding `image[:tag]` to the command. For example, `docker run 002b3c518f5852f7fd5e9e46c0ea1ab4d76b697d33d5022af1a69e1a909645ea`.
132+
While not strictly a means of identifying a container, you can specify a version of an image you’d like to run the container with by adding `image[:tag]` to the command. For example, `docker run 002b3c518f5852f7fd5e9e46c0ea1ab4d76b697d33d5022af1a69e1a909645ea`.
133133
Images can be pulled [here](https://github.com/eclipse-tractusx/traceability-foss-frontend/pkgs/container/traceability-foss-frontend).

README.md

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<div style="display: flex; align-items: center;justify-content: center;align-content: center;">
2-
<img src="src/assets/images/logo.svg" alt="Trace-X - Product Traceability FOSS Frontend (TRACE-FOSS)" style="width:200px;"/>
3-
<h1 style="margin: 10px 0 0 10px">Traceability FOSS Frontend</h1>
2+
<img src="src/assets/images/logo.svg" alt="Trace-X - Product Traceability FOSS Frontend (TRACE-FOSS)" style="width:200px;"/>
3+
<h1 style="margin: 10px 0 0 10px">Traceability FOSS Frontend</h1>
44
</div>
55

66
[![Apache 2 License](https://img.shields.io/badge/License-Apache_2.0-blue.svg)](https://github.com/eclipse-tractusx/traceability-foss-frontend/LICENSE)
@@ -18,21 +18,21 @@ This saves costs by seamlessly tracking parts and creates trust through clearly
1818

1919
This application serves as a user entry point to the Catena-X network.
2020

21-
It's written in Typescript based on the `Angular` framework.
22-
We decided on using Angular because of two important aspects.
23-
Firstly, Angular comes with `strict guidelines`, which makes it harder to start working on for new developers, but for established developers it is `easy to start working with`.
24-
Secondly, Angular `scales` perfectly in the long run. Because of the restricted possibilities and stricted guidelines it is hard to implement multiple solutions for the same problem. e.g. Storing data or routing.
21+
It's written in Typescript based on the `Angular` framework.
22+
We decided on using Angular because of two important aspects.
23+
Firstly, Angular comes with `strict guidelines`, which makes it harder to start working on for new developers, but for established developers it is `easy to start working with`.
24+
Secondly, Angular `scales` perfectly in the long run. Because of the restricted possibilities and stricted guidelines it is hard to implement multiple solutions for the same problem. e.g. Storing data or routing.
2525
With that in mind it made sense it chose Angular for an `open source` project.
2626

2727
Source files are exposed statically through the NGINX web server.
2828
TRACE-FOSS product composes of the backend and frontend repositories, backend repository can be found under [GitHub repository](https://github.com/catenax-ng/tx-traceability-foss-backend).
2929

3030
### Challenges and solutions
3131

32-
"Visualisation of traceability" is one of our most important feature, but once was one of our biggest problems.
33-
We wanted to achieve something that is `visually pleasing`, is `easy to use` and `performs` very good in a `browser application`.
34-
Our first approach was to use HTML canvas. But it turned out it is hard to perform accurate actions inside a canvas. That is why we decided on using the [D3 library](https://d3js.org/).
35-
D3.js is a JavaScript library for manipulating documents based on data. D3 helps you bring data to life using HTML, SVG, and CSS.
32+
"Visualisation of traceability" is one of our most important feature, but once was one of our biggest problems.
33+
We wanted to achieve something that is `visually pleasing`, is `easy to use` and `performs` very good in a `browser application`.
34+
Our first approach was to use HTML canvas. But it turned out it is hard to perform accurate actions inside a canvas. That is why we decided on using the [D3 library](https://d3js.org/).
35+
D3.js is a JavaScript library for manipulating documents based on data. D3 helps you bring data to life using HTML, SVG, and CSS.
3636
Because it uses SVGs, we knew it will perform great. And we are able to have pinpoint accuracy when it comes to user actions.
3737

3838
## Getting started
@@ -59,7 +59,7 @@ Find [here](docs/configuration.md) documentation to support you during the devel
5959

6060
### Setup changelog generation
6161

62-
Follow these instructions: [GIT-CHGLOG](https://github.com/git-chglog/git-chglog#installation)
62+
Follow these instructions: [GIT-CHGLOG](https://github.com/git-chglog/git-chglog#installation)
6363
You can generate a changelog when running `git-chglog -o CHANGELOG.md`
6464

6565
## Application authentication
@@ -185,16 +185,16 @@ All done!
185185

186186
## How to contribute
187187

188-
TBD
188+
TBD
189189
For now, we are following the angular guidelines which can be found here: [Angulars how to contribute](https://github.com/angular/angular-cli/blob/main/CONTRIBUTING.md)
190190

191191
## Branching system and release workflow
192192

193193
We are using the [GitHub Flow](https://docs.github.com/en/get-started/quickstart/github-flow) for our branching system.
194194

195-
The general idea behind this approach is that you keep the main code in a constant deployable state.
196-
You start off with the main branch, then a developer creates a feature branch directly from main.
197-
After the feature is developed the code is reviewed and tested on the branch.
195+
The general idea behind this approach is that you keep the main code in a constant deployable state.
196+
You start off with the main branch, then a developer creates a feature branch directly from main.
197+
After the feature is developed the code is reviewed and tested on the branch.
198198
Only after the code is stable it can be merged to main.
199199

200200
<img src="docs/images/github-flow-branching-model.jpeg" height="60%" width="60%"/>

src/app/modules/shared/modules/notification/presentation/notification.component.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ describe('NotificationsInboxComponent', () => {
6161
const menuActionsConfig = [];
6262

6363
return renderComponent(
64-
`<app-notification
64+
`<app-notification
6565
[queuedAndRequestedNotifications$]='queuedAndRequestedNotifications$'
6666
[receivedNotifications$]='receivedNotifications$'
6767
[translationContext]="'commonInvestigation'"

src/app/modules/shared/modules/relations/RELATIONS.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,13 @@
88

99
<h2>This Module is responsible for the visualisation of relations between assets.</h2>
1010
<h4>"A high level of transparency across the supplier network" -> This module tackles the channels to provide an
11-
intuitive and clear visualisation for exactly that.
11+
intuitive and clear visualisation for exactly that.
1212
The visualisation is done in a tree-like structure. By visualising the relations between assets like this,
1313
it is easy to understand and follow.
1414

1515
## Structure
1616

17-
The module can be found in this location: `src/app/modules/page/parts/relations`.
17+
The module can be found in this location: `src/app/modules/page/parts/relations`.
1818
Relations is a submodule of parts because it is only available within parts and has no separate access point.
1919

2020
"Relations" is set up like every other module.
@@ -25,10 +25,10 @@ Relations is a submodule of parts because it is only available within parts and
2525

2626
## Architecture
2727

28-
The diagram is built with [d3.js](https://github.com/d3/d3). It uses SVGs to render any shape or form.
28+
The diagram is built with [d3.js](https://github.com/d3/d3). It uses SVGs to render any shape or form.
2929
The implementation of `d3` and the custom implementation for displaying the tree can be found in `d3.tree.ts`.
3030
The class `RelationTree` expects a config. This config should provide all necessary event handlers, properties and the
31-
main element.
31+
main element.
3232
The main element should be a `figure` element. The result of the tree is displayed there as an SVG.
3333

3434
There are two important state variables you should keep track of. These are `openElements` and `loadedElements`.
@@ -44,10 +44,10 @@ With this one-dimensional approach, it is easy to detect and handle changes.
4444

4545
### loadedElements
4646

47-
Loaded elements has a similar structure to open Elements. But with one exception,
47+
Loaded elements has a similar structure to open Elements. But with one exception,
4848
the value is `not a list of ids`, it contains `detailed information about an `already downloaded` asset.
4949

50-
With this approach, we can reduce the load on the network.
50+
With this approach, we can reduce the load on the network.
5151
In addition to that, we are preloading the children of an opened asset. By doing that we provide nearly a seamless
5252
navigation.
5353

0 commit comments

Comments
 (0)