ts4nfdi / terminology-service-suite

The SemLookP Widgets project is a collection of interactive widgets designed to ease the integration of terminology service functions into third-party applications.
https://ts4nfdi.github.io/terminology-service-suite/comp/latest/
MIT License
12 stars 2 forks source link

CrossRefTabWidget: EntityLinks not possible whithout passing entity response #68

Open VincentKneip opened 3 months ago

VincentKneip commented 3 months ago

Currently, the CrossRefTabWidget executes a query and passes the extracted cross references of the queried entity as strings to the CrossRefTabPresentation widget.

This causes a problem of not being able to add labels or links to the values listed under cross references in the entities' response. Within the OLS4 v2 api, this information is often provided in the response at the key linkedEntities.

Below you can see a comparison of the current situation and the enhanced version (from EBI) for the term iri http://www.ebi.ac.uk/efo/EFO_0009644:

current (no links, no labels) enhanced (links, labels, badges) (view at EBI's page here)
grafik grafik

CrossRefTabPresentation would have to receive the whole response to add this functionality, which we want to avoid though as it would force users of our service to deal with our model objects instead of simple string values.

I would therefore suggest adding an alternative Presentation-widget which receives the whole entity response, but is not publicly usable, so we hide the model architecture from users, but still provide the functionality for the CrossRefTabWidget. Users could then decide to either use CrossRefTabWidget, including the functionality, or CrossRefTabPresentation (if the cross references should be provided manually), not including the functionality

VincentKneip commented 2 months ago

After discussing, we decided to do the following: