Skip to content

Commit

Permalink
add title tooltip for the browser filters chips
Browse files Browse the repository at this point in the history
  • Loading branch information
syphax-bouazzouni committed Apr 26, 2023
1 parent 57c04c5 commit 1eca78d
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions app/views/ontologies/browse.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,10 @@
= render SwitchInputComponent.new(id:'filter-private', name:'private_only', checked: @show_private_only) do
Show private ontology only
%div.browse-filter{style:'border: none'}
= render SwitchInputComponent.new(id:'filter-views', name:'views', checked: @show_views) do
Show ontology views
= render SwitchInputComponent.new(id:'filter-retired', name:'retired',checked: @show_retired) do
Show retired ontologies
= render SwitchInputComponent.new(id:'filter-views', name:'views', checked: @show_views) do
Show ontology views
= render SwitchInputComponent.new(id:'filter-retired', name:'retired',checked: @show_retired) do
Show retired ontologies

- @filters.each do |key, values|
- if session[:user]&.admin? || key != :missingStatus
Expand All @@ -69,8 +69,9 @@
.collapse{id: "browse-#{key}-filter", class: "#{values[2].positive? ? 'show': ''}"}
.browse-filter-checks-container
- values.first.each do |object|
%div.mr-2
= render ChipsComponent.new(name: object["acronym"], value: (object["acronym"] || object["id"]), checked: values[1]&.include?(object["id"])) do |c|
%div.mr-2{data: {controller: 'tooltip'}, title: object["name"] || object["acronym"] || object["id"] }
= render ChipsComponent.new(name: object["acronym"], value: (object["acronym"] || object["id"]),
checked: values[1]&.include?(object["id"])) do |c|
- c.count do
%div.ml-1
= turbo_frame_tag "count_#{key}_#{object["id"]}" do
Expand Down

0 comments on commit 1eca78d

Please sign in to comment.