Skip to content

Commit

Permalink
feat: adding providers placeholder
Browse files Browse the repository at this point in the history
  • Loading branch information
nexus49 committed Aug 5, 2024
1 parent 800bc10 commit 56ef5ad
Show file tree
Hide file tree
Showing 5 changed files with 126 additions and 3 deletions.
26 changes: 26 additions & 0 deletions charts/example-resources/assets/providers.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{
"name": "overview",
"luigiConfigFragment": [
{
"data": {
"nodes": [
{
"pathSegment": "providers",
"label": "Providers",
"entityType": "main",
"loadingIndicator": {
"enabled": false
},
"keepSelectedForChildren": true,
"url": "https://fiddle.luigi-project.io/examples/microfrontends/multipurpose.html",
"children": [ ],
"context": {
"title": "Catalog of Active Providers",
"content": " "
}
}
]
}
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{{- if .Values.contentConfigurations.providers }}
apiVersion: core.openmfp.io/v1alpha1
kind: ContentConfiguration
metadata:
name: providers
namespace: {{ .Release.Namespace }}
spec:
inlineConfiguration:
content: |-
{{ .Files.Get "assets/providers.json" | nindent 6 }}
contentType: json
{{- end }}
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ matches the snapshot:
]
}
contentType: json
matches the snapshot (gardener:
matches the snapshot (gardener):
1: |
apiVersion: core.openmfp.io/v1alpha1
kind: ContentConfiguration
Expand Down Expand Up @@ -130,3 +130,81 @@ matches the snapshot (gardener:
]
}
contentType: json
matches the snapshot (providers):
1: |
apiVersion: core.openmfp.io/v1alpha1
kind: ContentConfiguration
metadata:
name: home
namespace: NAMESPACE
spec:
inlineConfiguration:
content: |2-
{
"name": "overview",
"luigiConfigFragment": [
{
"data": {
"nodes": [
{
"entityType": "global",
"pathSegment": "home",
"hideFromNav": true,
"defineEntity": {
"id": "main"
},
"children": [
{
"pathSegment": "overview",
"label": "Overview",
"icon": "home",
"url": "https://fiddle.luigi-project.io/examples/microfrontends/multipurpose.html",
"context": {
"title": "Welcome to OpenMFP Portal",
"content": " "
}
}
]
}
]
}
}
]
}
contentType: json
2: |
apiVersion: core.openmfp.io/v1alpha1
kind: ContentConfiguration
metadata:
name: providers
namespace: NAMESPACE
spec:
inlineConfiguration:
content: |2-
{
"name": "overview",
"luigiConfigFragment": [
{
"data": {
"nodes": [
{
"pathSegment": "providers",
"label": "Providers",
"entityType": "main",
"loadingIndicator": {
"enabled": false
},
"keepSelectedForChildren": true,
"url": "https://fiddle.luigi-project.io/examples/microfrontends/multipurpose.html",
"children": [ ],
"context": {
"title": "Catalog of Active Providers",
"content": " "
}
}
]
}
}
]
}
contentType: json
8 changes: 7 additions & 1 deletion charts/example-resources/tests/content-configs_test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,15 @@ tests:
- it: matches the snapshot
asserts:
- matchSnapshot: {}
- it: matches the snapshot (gardener
- it: matches the snapshot (gardener)
set:
contentConfigurations:
gardener: true
asserts:
- matchSnapshot: {}
- it: matches the snapshot (providers)
set:
contentConfigurations:
providers: true
asserts:
- matchSnapshot: {}
3 changes: 2 additions & 1 deletion charts/example-resources/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@ accounts:

contentConfigurations:
home: true
gardener: false
gardener: false
providers: false

0 comments on commit 56ef5ad

Please sign in to comment.