diff --git a/projects/website-angular/src/app/content/detail/icon-detail/icon-detail.component.html b/projects/website-angular/src/app/content/detail/icon-detail/icon-detail.component.html index 7f96191..eb021f8 100644 --- a/projects/website-angular/src/app/content/detail/icon-detail/icon-detail.component.html +++ b/projects/website-angular/src/app/content/detail/icon-detail/icon-detail.component.html @@ -1,117 +1,144 @@ @if (loading()) { -
- -
+
+ +
} @else if (error()) { -
-

Icon not found

-

The requested icon could not be found.

-
+
+

Icon not found

+

The requested icon could not be found.

+
} @else if (icon()) { -
- -
-
-

{{ icon()!.name }}

+
+ +
+

{{ icon()!.name }}

+
+ +
@if (icon()!.iconCategories?.length) { -
- @for (cat of icon()!.iconCategories; track cat) { - {{ cat }} - } -
+
Categories
+
+ @for (cat of icon()!.iconCategories; track cat) { + {{ cat }} + } +
}
-
- +
+ @if (icon()!.summation) { +
Description
+
+ }
-
- - - @if (icon()!.summation) { - -

Description

-

-
- } - - @if (icon()!.iconCuratorName || icon()!.iconDesignerName) { - -

Credits

-
+
@if (icon()!.iconCuratorName) { -
- Curator: - @if (icon()!.iconCuratorOrcidId) { - - {{ icon()!.iconCuratorName }} - open_in_new - - } @else { - {{ icon()!.iconCuratorName }} - } -
+
+ Curator + @if (icon()!.iconCuratorOrcidId) { + + {{ icon()!.iconCuratorName }} + open_in_new + + } @else { + {{ icon()!.iconCuratorName }} + } +
} +
+
@if (icon()!.iconDesignerName) { -
- Designer: - @if (icon()!.iconDesignerUrl) { - - {{ icon()!.iconDesignerName }} - open_in_new - - } @else { - {{ icon()!.iconDesignerName }} - } -
+
+ Designer + @if (icon()!.iconDesignerUrl) { + + {{ icon()!.iconDesignerName }} + open_in_new + + } @else { + {{ icon()!.iconDesignerName }} + } +
}
- - } - - @if (getUniProtReferences().length) { - -

External References

-
- @for (ref of getUniProtReferences(); track ref) { - + - - } - - @if (icon()!.iconPhysicalEntities?.length) { - -

Physical Entities ({{ icon()!.iconPhysicalEntities.length }})

-
- - - - - - - - - - - @for (entity of icon()!.iconPhysicalEntities; track entity.stId) { +
+ @if (icon()!.iconPhysicalEntities?.length) { +
+ Physical Entities ({{ icon()!.iconPhysicalEntities.length }}) +
+
+
NameIdentifierTypeCompartment
+ + + + + + + + + + @for (entity of icon()!.iconPhysicalEntities; track + entity.stId) { - } - -
NameIdentifierTypeCompartment
- {{ entity.displayName || entity.name }} + {{ + entity.displayName || entity.name + }} {{ entity.stId }} {{ entity.type }} {{ entity.compartments }}
+ } + + +
+ }
-
- } -
+
+
+
+
} diff --git a/projects/website-angular/src/app/content/detail/icon-detail/icon-detail.component.scss b/projects/website-angular/src/app/content/detail/icon-detail/icon-detail.component.scss index bad649b..073c859 100644 --- a/projects/website-angular/src/app/content/detail/icon-detail/icon-detail.component.scss +++ b/projects/website-angular/src/app/content/detail/icon-detail/icon-detail.component.scss @@ -32,6 +32,84 @@ gap: 16px; } +.icon-summary { + width: 100%; + margin: 16px; + + h1 { + border-bottom: 1px solid var(--primary); + padding: 0 0 16px; + font-size: 1.5rem; + + a { + color: var(--primary); + text-decoration: none; + + &:hover { + text-decoration: underline; + } + } + } + + .summary-fields { + margin: 0; + + .summary-row { + display: flex; + gap: 12px; + padding: 6px 0; + border-bottom: 1px solid var(--outline, #eee); + + .download-link { + display: inline-flex; + align-items: center; + gap: 4px; + color: var(--primary); + text-decoration: none; + margin-right: 16px; + + &:hover { + text-decoration: underline; + } + + .material-symbols-rounded { + font-size: 16px; + } + } + + .icon-preview { + display: flex; + flex: 1; + align-items: center; + justify-content: center; + padding: 12px; + + img { + height: 150px; + width: auto; + max-width: 100%; + max-height: 100%; + object-fit: contain; + } + } + + &:last-child { + border-bottom: none; + } + + dt { + font-weight: 600; + min-width: 100px; + flex-shrink: 0; + } + + dd { + margin: 0; + } + } + } +} + .icon-header { display: flex; align-items: flex-start; @@ -48,25 +126,6 @@ font-size: 1.5rem; } } - - .icon-preview { - flex-shrink: 0; - width: 120px; - height: 120px; - display: flex; - align-items: center; - justify-content: center; - border: 1px solid var(--outline, #ddd); - border-radius: 8px; - padding: 12px; - background: white; - - img { - max-width: 100%; - max-height: 100%; - object-fit: contain; - } - } } .icon-categories { @@ -151,7 +210,8 @@ h2 { width: 100%; border-collapse: collapse; - th, td { + th, + td { padding: 10px 14px; text-align: left; border-bottom: 1px solid var(--outline, #ddd); diff --git a/projects/website-angular/src/app/content/detail/icon-detail/icon-detail.component.ts b/projects/website-angular/src/app/content/detail/icon-detail/icon-detail.component.ts index e8cb120..cb19078 100644 --- a/projects/website-angular/src/app/content/detail/icon-detail/icon-detail.component.ts +++ b/projects/website-angular/src/app/content/detail/icon-detail/icon-detail.component.ts @@ -1,9 +1,9 @@ -import {Component, inject, OnInit, signal} from '@angular/core'; -import {ActivatedRoute, RouterLink} from '@angular/router'; -import {MatProgressSpinner} from '@angular/material/progress-spinner'; -import {PageLayoutComponent} from '../../../page-layout/page-layout.component'; -import {TileComponent} from '../../../reactome-components/tile/tile.component'; -import {IconService, IconEntry} from '../../../../services/icon.service'; +import { Component, inject, OnInit, signal } from '@angular/core'; +import { ActivatedRoute, RouterLink } from '@angular/router'; +import { MatProgressSpinner } from '@angular/material/progress-spinner'; +import { PageLayoutComponent } from '../../../page-layout/page-layout.component'; +import { TileComponent } from '../../../reactome-components/tile/tile.component'; +import { IconService, IconEntry } from '../../../../services/icon.service'; @Component({ selector: 'app-icon-detail', @@ -45,8 +45,13 @@ export class IconDetailComponent implements OnInit { return stId ? `https://reactome.org/icon/${stId}.svg` : ''; } + getPngUrl(): string { + const stId = this.icon()?.stId; + return stId ? `https://reactome.org/icon/${stId}.png` : ''; + } + getUniProtReferences(): string[] { const refs = this.icon()?.iconReferences ?? []; - return refs.filter(r => !r.includes(':')); + return refs.filter((r) => !r.includes(':')); } } diff --git a/projects/website-angular/src/app/content/detail/interactor-detail/interactor-detail.component.html b/projects/website-angular/src/app/content/detail/interactor-detail/interactor-detail.component.html index a1efee2..8a11ce4 100644 --- a/projects/website-angular/src/app/content/detail/interactor-detail/interactor-detail.component.html +++ b/projects/website-angular/src/app/content/detail/interactor-detail/interactor-detail.component.html @@ -1,91 +1,105 @@ @if (loading()) { -
- -
+
+ +
} @else if (error()) { -
-

Interactor not found

-

No interaction data could be found for "{{ acc() }}".

-
+
+

Interactor not found

+

No interaction data could be found for "{{ acc() }}".

+
} @else { -
- -
-

- {{ displayName() }} -

-
-
-
Type
-
{{ interactorType() }}
-
- @if (species()) { -
-
Species
-
{{ species() }}
-
- } - @if (synonyms().length) { -
-
Synonyms
-
{{ synonyms().join(', ') }}
-
- } -
-
-
- - @if (interactions().length) { - -

Interaction Partners ({{ interactions().length }})

-
- - - - - - - - - - - - @for (interaction of interactions(); track interaction.dbId) { +
+ +
+

+ {{ + displayName() + }} +

+
+
+
Type
+
{{ interactorType() }}
+
+ @if (species()) { +
+
Species
+
{{ species() }}
+
+ } @if (synonyms().length) { +
+
Synonyms
+
{{ synonyms().join(", ") }}
+
+ } @if (interactions().length) { +
+
Interaction Partners ({{ interactions().length }})
+
+
Accession#EntitiesReactome EntityConfidence ScoreEvidence (IntAct)
+ + + + + + + + + + + @for (interaction of interactions(); track interaction.dbId) { - + - + - } - -
Accession#EntitiesReactome EntityConfidence ScoreEvidence (IntAct)
- {{ interaction.identifier }} + {{ interaction.identifier }} {{ interaction.entitiesCount ?? '' }}{{ interaction.entitiesCount ?? "" }} @if (entityMap()[interaction.identifier]; as entities) { - @for (entity of entities; track entity.stId) { - {{ entity.displayName }} - } - } + @for (entity of entities; track entity.stId) { + {{ entity.displayName }} + } } {{ interaction.score | number:'1.3-3' }}{{ interaction.score | number : "1.3-3" }} @if (interaction.evidenceURL) { - - {{ interaction.evidenceCount }} pieces of evidence - open_in_new - + + {{ interaction.evidenceCount }} pieces of evidence + open_in_new + } @else { - {{ interaction.evidenceCount }} + {{ interaction.evidenceCount }} }
+ } + + + +
+ } @else { +
+

No interaction partners found.

-
- } @else { - -

No interaction partners found.

-
- } -
+ } + +
+ +
} diff --git a/projects/website-angular/src/app/content/detail/interactor-detail/interactor-detail.component.scss b/projects/website-angular/src/app/content/detail/interactor-detail/interactor-detail.component.scss index 8442555..c9470ed 100644 --- a/projects/website-angular/src/app/content/detail/interactor-detail/interactor-detail.component.scss +++ b/projects/website-angular/src/app/content/detail/interactor-detail/interactor-detail.component.scss @@ -33,8 +33,12 @@ } .interactor-summary { + width: 100%; + margin: 16px; + h1 { - margin: 0 0 16px; + border-bottom: 1px solid var(--primary); + padding: 0 0 16px; font-size: 1.5rem; a { @@ -86,7 +90,8 @@ h2 { width: 100%; border-collapse: collapse; - th, td { + th, + td { padding: 10px 14px; text-align: left; border-bottom: 1px solid var(--outline, #ddd);