From cbd1402e935c05e9d7660e214940e05afdd766d8 Mon Sep 17 00:00:00 2001 From: futa-ikeda Date: Wed, 3 Dec 2025 17:32:16 -0500 Subject: [PATCH 1/2] fix(search): Fix a11y issue with nested interactive controls --- .../components/resource-card/resource-card.component.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/app/shared/components/resource-card/resource-card.component.html b/src/app/shared/components/resource-card/resource-card.component.html index 0f5d574f9..96d5794fe 100644 --- a/src/app/shared/components/resource-card/resource-card.component.html +++ b/src/app/shared/components/resource-card/resource-card.component.html @@ -4,6 +4,8 @@

{{ cardTypeLabel() | translate }}

+
+

@@ -111,8 +113,6 @@

[hasSupplements]="resource().hasSupplementalResource" /> } -

-

From 9ffdb1e090afc63f85abc720886196b773ad6516 Mon Sep 17 00:00:00 2001 From: futa-ikeda Date: Fri, 12 Dec 2025 09:25:58 -0500 Subject: [PATCH 2/2] fix(search): Match CSS to what was there prior --- .../resource-card.component.html | 192 +++++++++--------- .../resource-card.component.scss | 4 + 2 files changed, 100 insertions(+), 96 deletions(-) diff --git a/src/app/shared/components/resource-card/resource-card.component.html b/src/app/shared/components/resource-card/resource-card.component.html index 96d5794fe..b4e25fbc9 100644 --- a/src/app/shared/components/resource-card/resource-card.component.html +++ b/src/app/shared/components/resource-card/resource-card.component.html @@ -1,118 +1,118 @@
- +

{{ cardTypeLabel() | translate }}

-
-

- - {{ displayTitle() | fixSpecialChar }} - -

+
+

+ + {{ displayTitle() | fixSpecialChar }} + +

- @if (isWithdrawn()) { - {{ 'resourceCard.labels.withdrawn' | translate }} - } + @if (isWithdrawn()) { + {{ 'resourceCard.labels.withdrawn' | translate }} + } - @let orcidValues = orcids(); - @if (orcidValues.length && orcidValues[0]) { - - orcid - - } -
+ @let orcidValues = orcids(); + @if (orcidValues.length && orcidValues[0]) { + + orcid + + } +
- @if (affiliatedEntities().length > 0) { -
- @for (affiliatedEntity of affiliatedEntities().slice(0, limit); track $index) { - - {{ affiliatedEntity.name }}{{ $last ? '' : ', ' }} - - } - @if (resource().creators.length > limit) { -

-  {{ 'resourceCard.andCountMore' | translate: { count: resource().creators.length - limit } }} -

- } -
+ @if (affiliatedEntities().length > 0) { +
+ @for (affiliatedEntity of affiliatedEntities().slice(0, limit); track $index) { + + {{ affiliatedEntity.name }}{{ $last ? '' : ', ' }} + } - - @if (resource().isPartOf) { -
-

{{ 'resourceCard.labels.from' | translate }}

- - {{ resource().isPartOf!.name }} - -
+ @if (resource().creators.length > limit) { +

+  {{ 'resourceCard.andCountMore' | translate: { count: resource().creators.length - limit } }} +

} +
+ } - @if (resource().isContainedBy) { -
-

{{ 'resourceCard.labels.from' | translate }}

- - {{ resource().isContainedBy!.name }} - -
- } + @if (resource().isPartOf) { +
+

{{ 'resourceCard.labels.from' | translate }}

+ + {{ resource().isPartOf!.name }} + +
+ } - @if (dateFields().length > 0) { -
- @for (dateField of dateFields(); track $index) { -

{{ dateField.label | translate }}: {{ dateField.date | date: 'MMMM d, y' : 'UTC' }}

+ @if (resource().isContainedBy) { +
+

{{ 'resourceCard.labels.from' | translate }}

+ + {{ resource().isContainedBy!.name }} + +
+ } - @if (!$last && !isSmall()) { -

- {{ '|' }} -

- } - } -
- } + @if (dateFields().length > 0) { +
+ @for (dateField of dateFields(); track $index) { +

{{ dateField.label | translate }}: {{ dateField.date | date: 'MMMM d, y' : 'UTC' }}

- @if (resource().context) { -
-

-
+ @if (!$last && !isSmall()) { +

+ {{ '|' }} +

+ } } +
+ } - @if ( - resource().resourceType === ResourceType.Registration || - resource().resourceType === ResourceType.RegistrationComponent - ) { - - } + @if (resource().context) { +
+

+
+ } + + @if ( + resource().resourceType === ResourceType.Registration || + resource().resourceType === ResourceType.RegistrationComponent + ) { + + }

diff --git a/src/app/shared/components/resource-card/resource-card.component.scss b/src/app/shared/components/resource-card/resource-card.component.scss index e32881448..6561b9e4d 100644 --- a/src/app/shared/components/resource-card/resource-card.component.scss +++ b/src/app/shared/components/resource-card/resource-card.component.scss @@ -12,6 +12,10 @@ font-weight: 400; } + a { + font-weight: 700; + } + .break-line { border: none; border-top: 1px solid var(--grey-2);