From 9d9875184de9cea837a71ed02181adb3a9e05250 Mon Sep 17 00:00:00 2001 From: Huy Nguyen Date: Tue, 10 Dec 2024 10:40:43 +0700 Subject: [PATCH] chore: update styles for the dfr render template --- app-config.json | 2 +- packages/components/src/constants/app-config.json | 2 +- packages/mock-app/src/constants/app-config.json | 2 +- packages/mock-app/src/templates/v0.5.0/dfr.hbs | 5 +++++ 4 files changed, 8 insertions(+), 3 deletions(-) diff --git a/app-config.json b/app-config.json index 84eb1221..3325b334 100644 --- a/app-config.json +++ b/app-config.json @@ -4199,7 +4199,7 @@ "context": ["https://test.uncefact.org/vocabulary/untp/dfr/0.5.0/"], "renderTemplate": [ { - "template": " Digital Facility Record
FACILITY RECORD

{{credentialSubject.name}}

{{credentialSubject.description}}

Country
{{credentialSubject.countryOfOperation}}
Address
{{!-- TODO 1: plain text --}} {{!--
{{credentialSubject.address.streetAddress}} {{credentialSubject.address.addressLocality}}, {{credentialSubject.address.postalCode}}
--}} {{!-- TODO 2: confirm --}} {{!-- {{credentialSubject.address.streetAddress}} --}} {{!-- TODO 3: confirm --}} {{credentialSubject.address.streetAddress}} {{credentialSubject.address.addressLocality}}, {{credentialSubject.address.postalCode}}
Processes
{{#each credentialSubject.processCategory}} {{name}} {{/each}}
Geolocation
{{!-- TODO: confirm --}}
Show on map
Declarations
{{#each credentialSubject.conformityClaim}}
Conformance:
{{#if conformance}}Yes{{else}}No{{/if}}
Assessed: {{assessmentDate}}
{{conformityEvidence.linkName}}

{{referenceRegulation.name}} administered in {{referenceRegulation.jurisdictionCountry}} by {{referenceRegulation.administeredBy.name}}

{{referenceStandard.name}} issued by {{referenceStandard.issuingParty.name}}

{{#each declaredValue}}

{{metricName}} is {{metricValue.value}}{{metricValue.unit}}

Score: {{score}} | Accuracy {{accuracy}}

{{/each}}
Evidence
{{/each}}
Issuing details
Issued by
Valid from
{{validFrom}}
Valid until
{{validUntil}}
", + "template": " Digital Facility Record
FACILITY RECORD

{{credentialSubject.name}}

{{credentialSubject.description}}

Country
{{credentialSubject.countryOfOperation}}
Address
{{!-- TODO 1: plain text --}} {{!--
{{credentialSubject.address.streetAddress}} {{credentialSubject.address.addressLocality}}, {{credentialSubject.address.postalCode}}
--}} {{!-- TODO 2: confirm --}} {{!-- {{credentialSubject.address.streetAddress}} --}} {{!-- TODO 3: confirm --}} {{credentialSubject.address.streetAddress}} {{credentialSubject.address.addressLocality}}, {{credentialSubject.address.postalCode}}
Processes
{{#each credentialSubject.processCategory}} {{name}} {{/each}}
Geolocation
Show on map
Declarations
{{#each credentialSubject.conformityClaim}}
Conformance:
{{#if conformance}}Yes{{else}}No{{/if}}
Assessed: {{assessmentDate}}
{{conformityEvidence.linkName}}

{{referenceRegulation.name}} administered in {{referenceRegulation.jurisdictionCountry}} by {{referenceRegulation.administeredBy.name}}

{{referenceStandard.name}} issued by {{referenceStandard.issuingParty.name}}

{{#each declaredValue}}

{{metricName}} is {{metricValue.value}}{{metricValue.unit}}

Score: {{score}} | Accuracy {{accuracy}}

{{/each}}
Evidence
{{/each}}
Issuing details
Issued by
Valid from
{{validFrom}}
Valid until
{{validUntil}}
", "@type": "WebRenderingTemplate2022" } ], diff --git a/packages/components/src/constants/app-config.json b/packages/components/src/constants/app-config.json index 84eb1221..3325b334 100644 --- a/packages/components/src/constants/app-config.json +++ b/packages/components/src/constants/app-config.json @@ -4199,7 +4199,7 @@ "context": ["https://test.uncefact.org/vocabulary/untp/dfr/0.5.0/"], "renderTemplate": [ { - "template": " Digital Facility Record
FACILITY RECORD

{{credentialSubject.name}}

{{credentialSubject.description}}

Country
{{credentialSubject.countryOfOperation}}
Address
{{!-- TODO 1: plain text --}} {{!--
{{credentialSubject.address.streetAddress}} {{credentialSubject.address.addressLocality}}, {{credentialSubject.address.postalCode}}
--}} {{!-- TODO 2: confirm --}} {{!-- {{credentialSubject.address.streetAddress}} --}} {{!-- TODO 3: confirm --}} {{credentialSubject.address.streetAddress}} {{credentialSubject.address.addressLocality}}, {{credentialSubject.address.postalCode}}
Processes
{{#each credentialSubject.processCategory}} {{name}} {{/each}}
Geolocation
{{!-- TODO: confirm --}}
Show on map
Declarations
{{#each credentialSubject.conformityClaim}}
Conformance:
{{#if conformance}}Yes{{else}}No{{/if}}
Assessed: {{assessmentDate}}
{{conformityEvidence.linkName}}

{{referenceRegulation.name}} administered in {{referenceRegulation.jurisdictionCountry}} by {{referenceRegulation.administeredBy.name}}

{{referenceStandard.name}} issued by {{referenceStandard.issuingParty.name}}

{{#each declaredValue}}

{{metricName}} is {{metricValue.value}}{{metricValue.unit}}

Score: {{score}} | Accuracy {{accuracy}}

{{/each}}
Evidence
{{/each}}
Issuing details
Issued by
Valid from
{{validFrom}}
Valid until
{{validUntil}}
", + "template": " Digital Facility Record
FACILITY RECORD

{{credentialSubject.name}}

{{credentialSubject.description}}

Country
{{credentialSubject.countryOfOperation}}
Address
{{!-- TODO 1: plain text --}} {{!--
{{credentialSubject.address.streetAddress}} {{credentialSubject.address.addressLocality}}, {{credentialSubject.address.postalCode}}
--}} {{!-- TODO 2: confirm --}} {{!-- {{credentialSubject.address.streetAddress}} --}} {{!-- TODO 3: confirm --}} {{credentialSubject.address.streetAddress}} {{credentialSubject.address.addressLocality}}, {{credentialSubject.address.postalCode}}
Processes
{{#each credentialSubject.processCategory}} {{name}} {{/each}}
Geolocation
Show on map
Declarations
{{#each credentialSubject.conformityClaim}}
Conformance:
{{#if conformance}}Yes{{else}}No{{/if}}
Assessed: {{assessmentDate}}
{{conformityEvidence.linkName}}

{{referenceRegulation.name}} administered in {{referenceRegulation.jurisdictionCountry}} by {{referenceRegulation.administeredBy.name}}

{{referenceStandard.name}} issued by {{referenceStandard.issuingParty.name}}

{{#each declaredValue}}

{{metricName}} is {{metricValue.value}}{{metricValue.unit}}

Score: {{score}} | Accuracy {{accuracy}}

{{/each}}
Evidence
{{/each}}
Issuing details
Issued by
Valid from
{{validFrom}}
Valid until
{{validUntil}}
", "@type": "WebRenderingTemplate2022" } ], diff --git a/packages/mock-app/src/constants/app-config.json b/packages/mock-app/src/constants/app-config.json index 84eb1221..3325b334 100644 --- a/packages/mock-app/src/constants/app-config.json +++ b/packages/mock-app/src/constants/app-config.json @@ -4199,7 +4199,7 @@ "context": ["https://test.uncefact.org/vocabulary/untp/dfr/0.5.0/"], "renderTemplate": [ { - "template": " Digital Facility Record
FACILITY RECORD

{{credentialSubject.name}}

{{credentialSubject.description}}

Country
{{credentialSubject.countryOfOperation}}
Address
{{!-- TODO 1: plain text --}} {{!--
{{credentialSubject.address.streetAddress}} {{credentialSubject.address.addressLocality}}, {{credentialSubject.address.postalCode}}
--}} {{!-- TODO 2: confirm --}} {{!-- {{credentialSubject.address.streetAddress}} --}} {{!-- TODO 3: confirm --}} {{credentialSubject.address.streetAddress}} {{credentialSubject.address.addressLocality}}, {{credentialSubject.address.postalCode}}
Processes
{{#each credentialSubject.processCategory}} {{name}} {{/each}}
Geolocation
{{!-- TODO: confirm --}}
Show on map
Declarations
{{#each credentialSubject.conformityClaim}}
Conformance:
{{#if conformance}}Yes{{else}}No{{/if}}
Assessed: {{assessmentDate}}
{{conformityEvidence.linkName}}

{{referenceRegulation.name}} administered in {{referenceRegulation.jurisdictionCountry}} by {{referenceRegulation.administeredBy.name}}

{{referenceStandard.name}} issued by {{referenceStandard.issuingParty.name}}

{{#each declaredValue}}

{{metricName}} is {{metricValue.value}}{{metricValue.unit}}

Score: {{score}} | Accuracy {{accuracy}}

{{/each}}
Evidence
{{/each}}
Issuing details
Issued by
Valid from
{{validFrom}}
Valid until
{{validUntil}}
", + "template": " Digital Facility Record
FACILITY RECORD

{{credentialSubject.name}}

{{credentialSubject.description}}

Country
{{credentialSubject.countryOfOperation}}
Address
{{!-- TODO 1: plain text --}} {{!--
{{credentialSubject.address.streetAddress}} {{credentialSubject.address.addressLocality}}, {{credentialSubject.address.postalCode}}
--}} {{!-- TODO 2: confirm --}} {{!-- {{credentialSubject.address.streetAddress}} --}} {{!-- TODO 3: confirm --}} {{credentialSubject.address.streetAddress}} {{credentialSubject.address.addressLocality}}, {{credentialSubject.address.postalCode}}
Processes
{{#each credentialSubject.processCategory}} {{name}} {{/each}}
Geolocation
Show on map
Declarations
{{#each credentialSubject.conformityClaim}}
Conformance:
{{#if conformance}}Yes{{else}}No{{/if}}
Assessed: {{assessmentDate}}
{{conformityEvidence.linkName}}

{{referenceRegulation.name}} administered in {{referenceRegulation.jurisdictionCountry}} by {{referenceRegulation.administeredBy.name}}

{{referenceStandard.name}} issued by {{referenceStandard.issuingParty.name}}

{{#each declaredValue}}

{{metricName}} is {{metricValue.value}}{{metricValue.unit}}

Score: {{score}} | Accuracy {{accuracy}}

{{/each}}
Evidence
{{/each}}
Issuing details
Issued by
Valid from
{{validFrom}}
Valid until
{{validUntil}}
", "@type": "WebRenderingTemplate2022" } ], diff --git a/packages/mock-app/src/templates/v0.5.0/dfr.hbs b/packages/mock-app/src/templates/v0.5.0/dfr.hbs index 64749825..1368f7fd 100644 --- a/packages/mock-app/src/templates/v0.5.0/dfr.hbs +++ b/packages/mock-app/src/templates/v0.5.0/dfr.hbs @@ -566,6 +566,11 @@ min-width: 100%; } } + + div:has(.facility-record) .facility-record .declarations, + div:has(.facility-record) .facility-record section { + padding: 0px; + }