-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: offer multiple sorting options for attributions #2481
Conversation
ad706ad
to
049fe76
Compare
src/Frontend/Components/ResourceDetailsTabs/ResourceDetailsTabs.tsx
Outdated
Show resolved
Hide resolved
src/Frontend/Components/ResourceDetailsTabs/ResourceDetailsTabs.tsx
Outdated
Show resolved
Hide resolved
src/shared/text.ts
Outdated
byCriticality: 'By Criticality', | ||
}, | ||
tooltips: { | ||
search: 'Search signals by name, license name, copyright text and version', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
better to group semantically than by technical function. so this would be part of "attributionColumn".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed it as suggested. However, I don't quite agree with you here. The name "attributionColumn" indicates grouping the texts by components. Hence, we will either eventually end up defining the same text multiple times or using texts from other components. The name "tooltips", on the other hand, can be understood as the user-facing behavior in the frontend. So these texts could, for example be used for the tooltips in the auditView and in the attributionView.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, good point. one needs to see if the text is reused or not. it seems to me this one is not. what do you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In this case it probably doesn't matter, since we are using different texts anyway. But in general I don't think that it is a good idea to start grouping the texts by components.
f50c90b
to
0e4cf5f
Compare
@@ -44,6 +44,8 @@ export const text = { | |||
source: 'Source', | |||
useAutocompleteSuggestion: | |||
'Adopt all coordinates and legal information from suggestion', | |||
sortTooltip: 'Sort', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it would be better to say "Sorting" here because then we match the noun "Filter" instead of using the verb "sort".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, I read "filter" as a verb too. In this case it matches, that's why I chose "sort".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok, but it currently says "filters", not "filter"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I removed the "s"
6cfe0db
to
2fb5ac4
Compare
… selected - add toggle state for critical signals progress bar to store - extend sorting algorithm to consider criticality - only sort by criticality if criticality progress bar is selected - extend test of sorting - fix hydration condition of signals web-worker Signed-off-by: Anton Bauhofer <anton.bauhofer@tngtech.com>
2fb5ac4
to
75d89bd
Compare
Summary of changes
add toggle state for critical signals progress bar to store
extend sorting algorithm to consider criticality
extend test of sorting
Context and reason for change
There is highlighting for critical signals but before this change it was still hard to find critical signals in long lists of signals coming from e.g. ScanCode.
How can the changes be tested
Open an input file that contains critical signals and look at the sorting.