Skip to content
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

Feature: Add json button to search page #562

Merged
merged 5 commits into from
Apr 5, 2024

Conversation

Bilelkihal
Copy link
Collaborator

Demo

Capture.video.du.05-04-2024.07.41.43.webm

@Bilelkihal Bilelkihal added the enhancement New feature or request label Apr 5, 2024
@Bilelkihal Bilelkihal self-assigned this Apr 5, 2024
Copy link
Collaborator

@syphax-bouazzouni syphax-bouazzouni left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This JSON button need to follow the same design as on the other places; rounded and not at that place.
Currentyl we have
image
Or
image
Or
image

@syphax-bouazzouni
Copy link
Collaborator

Changed it to this
image

@syphax-bouazzouni syphax-bouazzouni merged commit 64d480f into development Apr 5, 2024
4 checks passed
syphax-bouazzouni added a commit that referenced this pull request Apr 5, 2024
* add json button ui to search page

* extract json_link method from annotator controller to application controller

* build the search page json link using json_link method

* move the search json button down besides the advanced options button

* remove this usage of api_params instead of direct params in search controller

---------

Co-authored-by: Syphax Bouazzouni <gs_bouazzouni@esi.dz>
syphax-bouazzouni added a commit that referenced this pull request Apr 5, 2024
…earch json icon (#563)

* Fix: Annotator fast context special chars issues & statistics page syntax error (#561)

* fix statistics page syntax error

* update ontoportal instances home section title

* fix fast context option in annotator page

* remove special chars from annotator's input on submit to avoid errors

* Feature: Add json button to search page (#562)

* add json button ui to search page

* extract json_link method from annotator controller to application controller

* build the search page json link using json_link method

* move the search json button down besides the advanced options button

* remove this usage of api_params instead of direct params in search controller

---------

Co-authored-by: Syphax Bouazzouni <gs_bouazzouni@esi.dz>

---------

Co-authored-by: Bilel Kihal <61744974+Bilelkihal@users.noreply.github.com>
syphax-bouazzouni added a commit that referenced this pull request May 22, 2024
…e mappings cloud and OntoPortal URIs (#564)

* Fix: Annotator fast context special chars issues & statistics page syntax error (#561)

* fix statistics page syntax error

* update ontoportal instances home section title

* fix fast context option in annotator page

* remove special chars from annotator's input on submit to avoid errors

* Feature: Add json button to search page (#562)

* add json button ui to search page

* extract json_link method from annotator controller to application controller

* build the search page json link using json_link method

* move the search json button down besides the advanced options button

* remove this usage of api_params instead of direct params in search controller

---------

Co-authored-by: Syphax Bouazzouni <gs_bouazzouni@esi.dz>

* Feature: Adding Content Finder Page (#511)

* Adding Content Finder Page

* use ontologies selector instead of the url input

* Change the controller to add use the accept headers

- use the Net::HTTP instead of Linked::Client::HTTP to use the accept header

* use ontologies selector in the content finder page

* use the rest_url helper instead of the global variable REST_URI

* remove content finder link from the topnav

* close the array items in navitems method that causes an error

* use Faraday instead of Net::HTTP

* Remove result in content_finder_controller and use this.element.textContent

* use this.contentTarget.textContent instead element in the content finder

* Add html view using the concept details component

* use tool layout for the content finder page

---------

Co-authored-by: Syphax Bouazzouni <gs_bouazzouni@esi.dz>

* Feature: Add ontology concepts exporters to diffrent formats (xml, ntriples, turtle)  (#547)

* add feature to display resouce content in different formats

* Add download and copy buttons to the raw data section

* Add css to highlight the content of turtle and ntriples

* Add the copy functionality to the resource raw data

for formts: json, xml, ntriples and turtle

* Remove the clipboard component and change the HTML title to Raw Data

* Add clipboard component to the resource-content

* Use Net::HTTP instead of Linked::Client::HTTP to include accept header

* Add the content formats for instances and Properties

* Remove copy_concept_content method in clipboard component

* Use the highlight-js in the metadata controller and remove content_finder_controller

* Remove code duplication for content formats

- add content_formats method in application helper and use it for concepts, properties and instances

* Remove content finder controller from index.js

* Small fix: remove a condition in metadata_downloader

* Add content_formats method to ontologies_helper and remove it from application_helper

* Use Faraday instead of Net::HTTP

* Add helpers for content finder controller

* change content finder route to /ontologies/:acronym/:id/serialize/:output_format

* Add concept details component to schemes and collections and fix code

* rename the metadata downloader controller  and remove the result value

* update the concept formats tab UI to use icons and open in modal

* update the content finder page code to re-use concept format code

* update the content formats icons to use the primary color of the portal

* extract commun code in content finder and concept formats in a concern

* extract rdf highlighter component from concept format and content finder

* rename the concept formats file and action to content_serlizer

* in content finder don't call the backend serializer if format is html

* fix the content finder container width

* clean unused css code for the content finder

* extract link_to_format_modal function in the concept details component

* abstract the usage of a highlighter from the dependency  highlight.js

* update instance details page to use the concept details component

---------

Co-authored-by: Syphax bouazzouni <gs_bouazzouni@esi.dz>

* Feature: update admin page UI to use vertical tabs (#566)

* create vertical_tabs component

* use the vertical tabs component in the admin page

* enable sort in the users admin table

* fix the padding and marging  of the metadata administration page

* fix analytics admin page locals

* fix an error in table component after rebasing the branch

* remove an unused file

* remove the paths escaping in the actions of  user admin table

* add again the link to API for the users admin page

* implement for the vertical tabs  the option to save the selected tab

* Feature: Add indexation admin page (#567)

* create vertical_tabs component

* use the vertical tabs component in the admin page

* add search admin page

* translate the admin search tab to french

* create number_input helper for Input::NumberComponent

* make the regular button hide the loading state after request processed

* remove an unused file

* translate the search admin page to french and english

* Feature: Update search input in homepage and topnav to use the indexed content (#505)

* fix styling warning of flex "end" deperection

* fix search input text overflowing out of the container

* add  search content by rdfs label in additoon of skos prefLabel

* implement search redirection to the good page

* use ontologies_content_autocomplete helper in homepage and topnav

* add the search ontology content route

* clean unused agent search code from this branch

* move the code in search helper to a concern

* re-integrate  search input loader code to show a loader while searching

* Feature: Improve Browse page  performance (#572)

* optimize fetched  attributes in the browse page in API mode

* update ontologies browse to use API or Index

* add cache for the fair_score and submission endpoint

* internationalize a sentence in the browse and ontologies selector  views

* fix browse hasFormality and isOfType filters

* prfioritize API filtring  over the index in the browse page

* fix a bug with edit submission returning nil error on submission

* Feature: Add OntoPortal tools age (#559)

* add tools page

* extract search input in the search page to re-use in url checker tool

* internationlize the tools page

* add tools link to the footer

* fix the tools page block widths

* add top padding to tools cards

* Feature: Add concepts mappings button in search page results (#569)

* add mappings to concepts search results

* fix mapping count in concept page

* add new more from this ontology icon

* move concept_mappings_loader function to mappings helper

* remove indesired comment from _concept_mappings.html.haml file

* put url escape functions in a separate helper

* Feature: Add search bars for the instances, properties, collections and schemes pages  (#550)

* remove forgotten binding.pry's  from the code

* add the option to the tree link component to open in modals

* add type value to properties show view

* create paginated search list helpers

* update instances UI and add search bar

* add a search bar to the properties show page

* add a search bar for the collections show page

* implement a search bar  for the  schemes show page

* add search icon to the concepts search box

* fix a typo in the search content concerns

* move _instace_details file to _details

* remove top padding from the search bar in  properties and instances tree

* implement selected in the paginated_list_component

* use link_last_part in the tree link component to get the label from id

* prioritize the label from the id in the ontology search content

* remvoe top padding from search bar in the schemes and collection tree

* translate missing word in the properties details view

* clean the ontologies routes by defining a scope a removing duplicates

* remove agent code not relevant in this branch

* fix left padding of collections, schemes and properties views

* fix  tree autoclicking for collections, instances and schemes

* move the html rendering from the search concern to helper

* fix tests after changing the routes

* translate missing words in the new ontologies section search bars

* remove no more used instances js code

* Feature: Update concept mappings table style (#574)

* fix search page search button style

* fix search page json button style

* update concepts mappings table style

* add back chip button overflow wraping in concepts mappings table

* Fix: submission date and summary not ready (#576)

* fix the copy of creation date on new submission

* fix ontology viewer to hidde the data sections if any submission ready

* prevent infinite redirection in the ontology controller show action

* Feature: Improve browse page search ranking and performance  (#575)

* enhance the ontology search input to include ontology names

* fix new instances of page rendering

* add browse page search ranking if API mode

* include  views by default to be cached and filter them by request after

* remove no more used instances of controller and helpers code

* Feature: Add terms and conditions to signup and  footer links (#579)

* put terms and conditions check box in register page in french and english

* add terms and conditions link to the config file

* make the acceptation of the terms and conditions required for user registration

* update the style of the register form errors

* add terms and conditions links to the footer

* add terms_and_conditions to login_flows_test

* fix login flow integration test after adding terms and conditions

* clean the config sample file

---------

Co-authored-by: Syphax bouazzouni <gs_bouazzouni@esi.dz>

* Fix: new instance search feature to filter strictly only NamedIndividual  (#581)

* fix the paginated list selected value ti not select on each new page

* fix instance search type filter to not include everything

* Feature: Dynamic routes for ontologies content dereferencement (#568)

* Add uri redirection for /ontologies/:acronym/:id to the appropriate page

* small fixes: remove binding.pry and return resource_id in find_type_by_search

* Add copy agroportal link functionality

- this functionality is using the ClipboardComponent because it works the same but differ only in the content and icon
- the clipboard component has been changed to accept title and icon

* redirect to content finder page when no type is valid

* Updated route to use redirect action instead of show_redirection

* Use default icon and title arguments in the Clipboard Component

* rename and internationalize clipboard component titles

* small fix: remove % from svg icon

* Add the copy title to the components section in en.yml and fr.yml

* Show the generated uri when user hover over the copy link icon

* Make the dynamic route content negotiable

- based on the accept header we will
  - if "text/html" we will redirect to the agroportal page
  - else we will call the api and get the content serialized in the format specified and return it

* update serialize content to return accept_header

* translate copy_original_uri and copy_portal_uri to french

* reuse search content concern in uri redirection concern

* remove duplicate link_last_part method

* update the ontology redirection action to use ontology URI if resource_id nil

* update the content serializer to translate ntriples to an html table if asked for html format

* in the ontology redirection by default redirect to content finder with in html format

* remove the ":" from the copy the portal URI tooltip text

* change the order of the icons in the link_with_action  component

---------

Co-authored-by: Syphax bouazzouni <gs_bouazzouni@esi.dz>

* Feature: Update mappings page (#538)

* install D3 js and display a sample of ontology mappings bubbles

* add zoom feature for mappings bubble view

* fix bubble view style in mappings page

* fix a scss selector in the annotator css that affects all a tags

* mappings page layout

* add ontologies select in mappings page

* add upload new mappings in mappings page

* add mappings table turbo frame

* display the table view for ontology mappings

* fix turbo frame issue in mappings page

* Make the modal work in mappings table

* improve mappings table view style

* make mappings bubbles grow in a log way instead of a linear way

* Highlighting mappings for the selected bubble

* enable bubble deselection in mappings page

* disable non highlighted bubbles in mappings page

* show mappings page bubbles mappings in modal

* make mappings page bubbles modal show correct values

* customize mappings page bubbles tooltip

* Link the table and the bubble view in mappings page

* show highlighted bubbles with a gradient color related to the number of mappings

* upload mappings in a separate tab

* add concepts mappings to search page results

* fix upload mappings tab style

* display ontologies in ontologies selector

* finalize ontologies selector design

* put ontologies selector in the modal component

* fix ontologies result display in ontologies selector

* Make ontologies selector search bar work

* show ontologies results count in ontologies selector

* make groups filter work in ontologies selector

* make filter by categories work in ontologies selector

* add ontologies selector loading animation

* make submission related filters work for ontologies selector

* make select all work in ontologies selector

* make retired ontologies and views filters work in ontologies selector

* show tab selected checks count in ontologies selector

* Add loading animation to ontologies selector

* make ontology selection work in ontologies selector

* make ontologies selector component

* remove duplicated cross icon in ontologies selector

* replace use cases of the old ontologies selector

* convert ontologies selector ui component into a helper

* replace 'selector' by 'ontologies_selector' in ontologies controller

* enhance mapping page ontologies filtring style

* add search page mappings count

* add mappings bubble view to the ontology details page

* make upload mappings work in mapping page

* change seach results more ontologies button icon

* fix concepts table mappings count

* add a loading animation to the mappings bubble view

* extract mappings page tab sections into partials

* add internationalization to mappings page

* clean mappings bubble view code

* give more significant name for mappings ontologies table route

* Clean mappings controller code

* remove mappings search page part from main mappings PR

* update new mapping form style

* fix mappings section style and add search to its table in summary page

* fix create new mapping for concept issue

* fix upload mappings example style issue

* update mappings ontologies table style

* update the style the search filter of mappings table in mappings tab section

* fix mappings bubble view modal link value

* replace var by let in mappings visu stimulus controller

* make hard coded mappings-bubble-view id by a dynamic

* remove undesired #getLastPartOfUrl function from mappings vizu stimulus controller

* extract #init_mappings_section_bubble_view() to a separate function in mappings visu  stimulus controller

* Add a default value for zoomRatio stimulus value in mappings visu controller

* Add a default value for type stimulus value in mappings visu controller

* refactor submit function in mappings visu stimulus controller

* refactor select bubble method in mappings visu stimulus controller

* put center_scroll method inside draw bubble method to not repeat code in mappings visu stimulus controller

* refactor normalization ration function in mappings visu stimulus controller

* use a better comprehensive helper for the empty modal in mappings page

* add a legend for mappings bubble view

* add back external mappings to mappings table view, and clean visu stimulus controller

* move rest_url function to application_helper to be used by views

* set table container box-sizing to not overflow if padding set

* remove the new created to mappings actions and use the count action

* remove the no more used loader action

* move some mappings helpers and remove unused ones

* use component helpers instead calling render & use reveal component

* remove no more used partials in mappings

* refactor and clean the mappings stimulus controller

* extract from mappings stimulus the drawBubble logic in a file

* fix mappings bubble view legend (bubble size)

* fix search page results broken links (#583)

* Fix: admin delete submission route (#585)

* add back admin routes to fix delete submission

* remove admin duplicated routes

* Fix: Restore the new sample text of the annotator and recommender (#593)

* restore the new sample text of the annotator and recommender

* add french translation for annotator and recommender sample text

* Fix: search results selected language  (#595)

* add language param to search results links

* use helpers.request_lang instead of passing lang variable in search aggregator

* make the selection of the closest preflabel to the query case unsensitive

* Fix: new instance details page, properties selected property display and browse page ontology type filter (#596)

* fix the auto selection of isOfType filter on browse page

* fix search properties redirection to use propertyid not instanceid

* fix admin ontologies visits sorting

* fix ontologies browse page to show ontologies with no submissions

* fix the sort by dates order in browse page

* add apikey to the fairness cache key

* show in the search box result "ontology view" for views

* Feature: add a script to import or export CSV of the i18n locals (#597)

* Fix: Remove duplicated ontology scheme rows (#584)

* remove duplicated ontology scheme rows

* move the concept details row duplication logic to filter_properties function

* clean concept details component code

* reject bottom set keys from leftover in concepts details component

* fix skos-xl not been displayed in the raw data section

* fix: summary page for ontologies with no submissions

* Fix: Note thread show action (#606)

* Fix undefined method error

Resolves #308

* escape username when creating an ontology subscribtion

* fix missing roots message for nil classes

---------

Co-authored-by: Jennifer Vendetti <vendetti@stanford.edu>

* Fix: user reset password internationalisation issue (#605)

* fix user reset password internationalisation issue

* get user info in reset password

* fix card message component image

* fix: trim the copied text in the clipboard stimulus controller (#611)

* Feature: Add recommender system tests (#599)

* install Webmock gem

* setup recommender page test

* mock recommender api results in recommender system test

* add test edit text area and submit in recommender test

* disable webmock after the test ends in recommender test

* make add comment/proposal buttons smaller

* remove non related code to recommender tests PR

* put the a correct recommendations fixture

* check the number of results in recommender test

* check the number of the highlighted annotations in recommender test

* Disable webmock before each test to insure the non mocking of the different requests

* use dynamic host and apikey in recommender webmocking

* Feature:  add htaccess URIs redirection modal help (#580)

* Add uri redirection for /ontologies/:acronym/:id to the appropriate page

* small fixes: remove binding.pry and return resource_id in find_type_by_search

* Add copy agroportal link functionality

- this functionality is using the ClipboardComponent because it works the same but differ only in the content and icon
- the clipboard component has been changed to accept title and icon

* redirect to content finder page when no type is valid

* Updated route to use redirect action instead of show_redirection

* Use default icon and title arguments in the Clipboard Component

* rename and internationalize clipboard component titles

* small fix: remove % from svg icon

* Add the copy title to the components section in en.yml and fr.yml

* Show the generated uri when user hover over the copy link icon

* Make the dynamic route content negotiable

- based on the accept header we will
  - if "text/html" we will redirect to the agroportal page
  - else we will call the api and get the content serialized in the format specified and return it

* update serialize content to return accept_header

* translate copy_original_uri and copy_portal_uri to french

* reuse search content concern in uri redirection concern

* remove duplicate link_last_part method

* Add htaccess functionality

* Add apache and nginx instruction for htaccess redirection

* Clean te code in the view file

* Add OntologiesRedirectionController

- remove redirect and generate_htaccess from ontologies_controller
- clean code the generate_htaccess method
- add "ontology_portal_uri" in @Identifiers

* Regroupe routes

* Make ontologies_redirection controller and refactor generate_htaccess code

* Internationalization of redirection rewrite rules modal

* Add note for url that has #

* link contact support button to the feedback page

* Change regex to redirect only url of type: /path/resource_id

- for urls that has the # it will redirect to the ontology page

* Add ontology redirection based on the accept header format

* move the ontology redirection route to the bottom to have less priority

* Change rewrite rules note using alert component

* Add /ontologies/ACRONYM/download?format=FORMAT route

* ontology redirection  based on the accept header using /ontologies/acronym/download route

* Add redirect assertion in ontologies controller test

* Fix content serialization when calling /ontologies/:acronym/:id

* create private function for accept header and remove ontology redirection

* remove generate_rewrite_rules function

* remove redirect assertion in ontologies controller test

* change htaccess route to /ontologies/:acronym/htaccess

* fix copy internal links in LinkFieldComponent

* add raw to copy internal links in identifiers card

* return all response and add text/n3 format in content serializer

* escape id when redirecting to content_finder

* choose the right result from the results of search content

* add algorithm to choose the right accept header, not_acceptable if no format valid

* add an additional security to the uri redirection to have an exact match

* make the check resolvability icon clickable & redirect to the tool page

* make the check resolvability extend to accept equivalent formats

* move the redirection function from ontologies_controller to uri concern

* fix check_resolvability_tool to redirect to the full url not only the path

- the problem was because everytime it is redirecting to the uri.path and uri.path does not include the ?format parameter
- add the octet-stream accept header in the accepted format for xml

* add reference to the url of the original file when format not acceptable

* put again the resolvability timeout to 5 secondes

---------

Co-authored-by: Syphax bouazzouni <gs_bouazzouni@esi.dz>

* Fix: Release 2.8.0 grouped issues - Summary, Concept, Notes, Mappings pages (#613)

* fix hidden multiple synonyms in concept details

* remove unecessary search icon from concepts, instances and schemes trees search inputs

* fix the style of add comment and add proposal buttons

* include page url auto in the errors page feedback form

* add the selected bubble to the mappings legend tooltip

* update the fix of hidden synonyms to prevent possible breaks

* fix concept details raw data values alignement to use divs breaking line

* fix recommender result ontology link to redirect to UI not API

* fix summary ofaire tooltip breaking to a new line the card header

* fix opening the concept tree view link in a new tab showing only html

* fix french dates internationalization

* fix edit submission up front help message in english version

* handle the case of ontologies returning an error when roots are called

* add no properties alert message to the ontology viewer

* prevent ontology show redirection if summaryOnly  show summary directly

* localize the mappings vizualization legend text

---------

Co-authored-by: Syphax Bouazzouni <gs_bouazzouni@esi.dz>

* fix data tables warning issue (#624)

---------

Co-authored-by: Bilel Kihal <61744974+Bilelkihal@users.noreply.github.com>
Co-authored-by: Imad Bourouche <ji_bourouche@esi.dz>
Co-authored-by: Jennifer Vendetti <vendetti@stanford.edu>
Bilelkihal added a commit that referenced this pull request Jun 12, 2024
…e mappings cloud and OntoPortal URIs (#564)

* Fix: Annotator fast context special chars issues & statistics page syntax error (#561)

* fix statistics page syntax error

* update ontoportal instances home section title

* fix fast context option in annotator page

* remove special chars from annotator's input on submit to avoid errors

* Feature: Add json button to search page (#562)

* add json button ui to search page

* extract json_link method from annotator controller to application controller

* build the search page json link using json_link method

* move the search json button down besides the advanced options button

* remove this usage of api_params instead of direct params in search controller

---------

Co-authored-by: Syphax Bouazzouni <gs_bouazzouni@esi.dz>

* Feature: Adding Content Finder Page (#511)

* Adding Content Finder Page

* use ontologies selector instead of the url input

* Change the controller to add use the accept headers

- use the Net::HTTP instead of Linked::Client::HTTP to use the accept header

* use ontologies selector in the content finder page

* use the rest_url helper instead of the global variable REST_URI

* remove content finder link from the topnav

* close the array items in navitems method that causes an error

* use Faraday instead of Net::HTTP

* Remove result in content_finder_controller and use this.element.textContent

* use this.contentTarget.textContent instead element in the content finder

* Add html view using the concept details component

* use tool layout for the content finder page

---------

Co-authored-by: Syphax Bouazzouni <gs_bouazzouni@esi.dz>

* Feature: Add ontology concepts exporters to diffrent formats (xml, ntriples, turtle)  (#547)

* add feature to display resouce content in different formats

* Add download and copy buttons to the raw data section

* Add css to highlight the content of turtle and ntriples

* Add the copy functionality to the resource raw data

for formts: json, xml, ntriples and turtle

* Remove the clipboard component and change the HTML title to Raw Data

* Add clipboard component to the resource-content

* Use Net::HTTP instead of Linked::Client::HTTP to include accept header

* Add the content formats for instances and Properties

* Remove copy_concept_content method in clipboard component

* Use the highlight-js in the metadata controller and remove content_finder_controller

* Remove code duplication for content formats

- add content_formats method in application helper and use it for concepts, properties and instances

* Remove content finder controller from index.js

* Small fix: remove a condition in metadata_downloader

* Add content_formats method to ontologies_helper and remove it from application_helper

* Use Faraday instead of Net::HTTP

* Add helpers for content finder controller

* change content finder route to /ontologies/:acronym/:id/serialize/:output_format

* Add concept details component to schemes and collections and fix code

* rename the metadata downloader controller  and remove the result value

* update the concept formats tab UI to use icons and open in modal

* update the content finder page code to re-use concept format code

* update the content formats icons to use the primary color of the portal

* extract commun code in content finder and concept formats in a concern

* extract rdf highlighter component from concept format and content finder

* rename the concept formats file and action to content_serlizer

* in content finder don't call the backend serializer if format is html

* fix the content finder container width

* clean unused css code for the content finder

* extract link_to_format_modal function in the concept details component

* abstract the usage of a highlighter from the dependency  highlight.js

* update instance details page to use the concept details component

---------

Co-authored-by: Syphax bouazzouni <gs_bouazzouni@esi.dz>

* Feature: update admin page UI to use vertical tabs (#566)

* create vertical_tabs component

* use the vertical tabs component in the admin page

* enable sort in the users admin table

* fix the padding and marging  of the metadata administration page

* fix analytics admin page locals

* fix an error in table component after rebasing the branch

* remove an unused file

* remove the paths escaping in the actions of  user admin table

* add again the link to API for the users admin page

* implement for the vertical tabs  the option to save the selected tab

* Feature: Add indexation admin page (#567)

* create vertical_tabs component

* use the vertical tabs component in the admin page

* add search admin page

* translate the admin search tab to french

* create number_input helper for Input::NumberComponent

* make the regular button hide the loading state after request processed

* remove an unused file

* translate the search admin page to french and english

* Feature: Update search input in homepage and topnav to use the indexed content (#505)

* fix styling warning of flex "end" deperection

* fix search input text overflowing out of the container

* add  search content by rdfs label in additoon of skos prefLabel

* implement search redirection to the good page

* use ontologies_content_autocomplete helper in homepage and topnav

* add the search ontology content route

* clean unused agent search code from this branch

* move the code in search helper to a concern

* re-integrate  search input loader code to show a loader while searching

* Feature: Improve Browse page  performance (#572)

* optimize fetched  attributes in the browse page in API mode

* update ontologies browse to use API or Index

* add cache for the fair_score and submission endpoint

* internationalize a sentence in the browse and ontologies selector  views

* fix browse hasFormality and isOfType filters

* prfioritize API filtring  over the index in the browse page

* fix a bug with edit submission returning nil error on submission

* Feature: Add OntoPortal tools age (#559)

* add tools page

* extract search input in the search page to re-use in url checker tool

* internationlize the tools page

* add tools link to the footer

* fix the tools page block widths

* add top padding to tools cards

* Feature: Add concepts mappings button in search page results (#569)

* add mappings to concepts search results

* fix mapping count in concept page

* add new more from this ontology icon

* move concept_mappings_loader function to mappings helper

* remove indesired comment from _concept_mappings.html.haml file

* put url escape functions in a separate helper

* Feature: Add search bars for the instances, properties, collections and schemes pages  (#550)

* remove forgotten binding.pry's  from the code

* add the option to the tree link component to open in modals

* add type value to properties show view

* create paginated search list helpers

* update instances UI and add search bar

* add a search bar to the properties show page

* add a search bar for the collections show page

* implement a search bar  for the  schemes show page

* add search icon to the concepts search box

* fix a typo in the search content concerns

* move _instace_details file to _details

* remove top padding from the search bar in  properties and instances tree

* implement selected in the paginated_list_component

* use link_last_part in the tree link component to get the label from id

* prioritize the label from the id in the ontology search content

* remvoe top padding from search bar in the schemes and collection tree

* translate missing word in the properties details view

* clean the ontologies routes by defining a scope a removing duplicates

* remove agent code not relevant in this branch

* fix left padding of collections, schemes and properties views

* fix  tree autoclicking for collections, instances and schemes

* move the html rendering from the search concern to helper

* fix tests after changing the routes

* translate missing words in the new ontologies section search bars

* remove no more used instances js code

* Feature: Update concept mappings table style (#574)

* fix search page search button style

* fix search page json button style

* update concepts mappings table style

* add back chip button overflow wraping in concepts mappings table

* Fix: submission date and summary not ready (#576)

* fix the copy of creation date on new submission

* fix ontology viewer to hidde the data sections if any submission ready

* prevent infinite redirection in the ontology controller show action

* Feature: Improve browse page search ranking and performance  (#575)

* enhance the ontology search input to include ontology names

* fix new instances of page rendering

* add browse page search ranking if API mode

* include  views by default to be cached and filter them by request after

* remove no more used instances of controller and helpers code

* Feature: Add terms and conditions to signup and  footer links (#579)

* put terms and conditions check box in register page in french and english

* add terms and conditions link to the config file

* make the acceptation of the terms and conditions required for user registration

* update the style of the register form errors

* add terms and conditions links to the footer

* add terms_and_conditions to login_flows_test

* fix login flow integration test after adding terms and conditions

* clean the config sample file

---------

Co-authored-by: Syphax bouazzouni <gs_bouazzouni@esi.dz>

* Fix: new instance search feature to filter strictly only NamedIndividual  (#581)

* fix the paginated list selected value ti not select on each new page

* fix instance search type filter to not include everything

* Feature: Dynamic routes for ontologies content dereferencement (#568)

* Add uri redirection for /ontologies/:acronym/:id to the appropriate page

* small fixes: remove binding.pry and return resource_id in find_type_by_search

* Add copy agroportal link functionality

- this functionality is using the ClipboardComponent because it works the same but differ only in the content and icon
- the clipboard component has been changed to accept title and icon

* redirect to content finder page when no type is valid

* Updated route to use redirect action instead of show_redirection

* Use default icon and title arguments in the Clipboard Component

* rename and internationalize clipboard component titles

* small fix: remove % from svg icon

* Add the copy title to the components section in en.yml and fr.yml

* Show the generated uri when user hover over the copy link icon

* Make the dynamic route content negotiable

- based on the accept header we will
  - if "text/html" we will redirect to the agroportal page
  - else we will call the api and get the content serialized in the format specified and return it

* update serialize content to return accept_header

* translate copy_original_uri and copy_portal_uri to french

* reuse search content concern in uri redirection concern

* remove duplicate link_last_part method

* update the ontology redirection action to use ontology URI if resource_id nil

* update the content serializer to translate ntriples to an html table if asked for html format

* in the ontology redirection by default redirect to content finder with in html format

* remove the ":" from the copy the portal URI tooltip text

* change the order of the icons in the link_with_action  component

---------

Co-authored-by: Syphax bouazzouni <gs_bouazzouni@esi.dz>

* Feature: Update mappings page (#538)

* install D3 js and display a sample of ontology mappings bubbles

* add zoom feature for mappings bubble view

* fix bubble view style in mappings page

* fix a scss selector in the annotator css that affects all a tags

* mappings page layout

* add ontologies select in mappings page

* add upload new mappings in mappings page

* add mappings table turbo frame

* display the table view for ontology mappings

* fix turbo frame issue in mappings page

* Make the modal work in mappings table

* improve mappings table view style

* make mappings bubbles grow in a log way instead of a linear way

* Highlighting mappings for the selected bubble

* enable bubble deselection in mappings page

* disable non highlighted bubbles in mappings page

* show mappings page bubbles mappings in modal

* make mappings page bubbles modal show correct values

* customize mappings page bubbles tooltip

* Link the table and the bubble view in mappings page

* show highlighted bubbles with a gradient color related to the number of mappings

* upload mappings in a separate tab

* add concepts mappings to search page results

* fix upload mappings tab style

* display ontologies in ontologies selector

* finalize ontologies selector design

* put ontologies selector in the modal component

* fix ontologies result display in ontologies selector

* Make ontologies selector search bar work

* show ontologies results count in ontologies selector

* make groups filter work in ontologies selector

* make filter by categories work in ontologies selector

* add ontologies selector loading animation

* make submission related filters work for ontologies selector

* make select all work in ontologies selector

* make retired ontologies and views filters work in ontologies selector

* show tab selected checks count in ontologies selector

* Add loading animation to ontologies selector

* make ontology selection work in ontologies selector

* make ontologies selector component

* remove duplicated cross icon in ontologies selector

* replace use cases of the old ontologies selector

* convert ontologies selector ui component into a helper

* replace 'selector' by 'ontologies_selector' in ontologies controller

* enhance mapping page ontologies filtring style

* add search page mappings count

* add mappings bubble view to the ontology details page

* make upload mappings work in mapping page

* change seach results more ontologies button icon

* fix concepts table mappings count

* add a loading animation to the mappings bubble view

* extract mappings page tab sections into partials

* add internationalization to mappings page

* clean mappings bubble view code

* give more significant name for mappings ontologies table route

* Clean mappings controller code

* remove mappings search page part from main mappings PR

* update new mapping form style

* fix mappings section style and add search to its table in summary page

* fix create new mapping for concept issue

* fix upload mappings example style issue

* update mappings ontologies table style

* update the style the search filter of mappings table in mappings tab section

* fix mappings bubble view modal link value

* replace var by let in mappings visu stimulus controller

* make hard coded mappings-bubble-view id by a dynamic

* remove undesired #getLastPartOfUrl function from mappings vizu stimulus controller

* extract #init_mappings_section_bubble_view() to a separate function in mappings visu  stimulus controller

* Add a default value for zoomRatio stimulus value in mappings visu controller

* Add a default value for type stimulus value in mappings visu controller

* refactor submit function in mappings visu stimulus controller

* refactor select bubble method in mappings visu stimulus controller

* put center_scroll method inside draw bubble method to not repeat code in mappings visu stimulus controller

* refactor normalization ration function in mappings visu stimulus controller

* use a better comprehensive helper for the empty modal in mappings page

* add a legend for mappings bubble view

* add back external mappings to mappings table view, and clean visu stimulus controller

* move rest_url function to application_helper to be used by views

* set table container box-sizing to not overflow if padding set

* remove the new created to mappings actions and use the count action

* remove the no more used loader action

* move some mappings helpers and remove unused ones

* use component helpers instead calling render & use reveal component

* remove no more used partials in mappings

* refactor and clean the mappings stimulus controller

* extract from mappings stimulus the drawBubble logic in a file

* fix mappings bubble view legend (bubble size)

* fix search page results broken links (#583)

* Fix: admin delete submission route (#585)

* add back admin routes to fix delete submission

* remove admin duplicated routes

* Fix: Restore the new sample text of the annotator and recommender (#593)

* restore the new sample text of the annotator and recommender

* add french translation for annotator and recommender sample text

* Fix: search results selected language  (#595)

* add language param to search results links

* use helpers.request_lang instead of passing lang variable in search aggregator

* make the selection of the closest preflabel to the query case unsensitive

* Fix: new instance details page, properties selected property display and browse page ontology type filter (#596)

* fix the auto selection of isOfType filter on browse page

* fix search properties redirection to use propertyid not instanceid

* fix admin ontologies visits sorting

* fix ontologies browse page to show ontologies with no submissions

* fix the sort by dates order in browse page

* add apikey to the fairness cache key

* show in the search box result "ontology view" for views

* Feature: add a script to import or export CSV of the i18n locals (#597)

* Fix: Remove duplicated ontology scheme rows (#584)

* remove duplicated ontology scheme rows

* move the concept details row duplication logic to filter_properties function

* clean concept details component code

* reject bottom set keys from leftover in concepts details component

* fix skos-xl not been displayed in the raw data section

* fix: summary page for ontologies with no submissions

* Fix: Note thread show action (#606)

* Fix undefined method error

Resolves #308

* escape username when creating an ontology subscribtion

* fix missing roots message for nil classes

---------

Co-authored-by: Jennifer Vendetti <vendetti@stanford.edu>

* Fix: user reset password internationalisation issue (#605)

* fix user reset password internationalisation issue

* get user info in reset password

* fix card message component image

* fix: trim the copied text in the clipboard stimulus controller (#611)

* Feature: Add recommender system tests (#599)

* install Webmock gem

* setup recommender page test

* mock recommender api results in recommender system test

* add test edit text area and submit in recommender test

* disable webmock after the test ends in recommender test

* make add comment/proposal buttons smaller

* remove non related code to recommender tests PR

* put the a correct recommendations fixture

* check the number of results in recommender test

* check the number of the highlighted annotations in recommender test

* Disable webmock before each test to insure the non mocking of the different requests

* use dynamic host and apikey in recommender webmocking

* Feature:  add htaccess URIs redirection modal help (#580)

* Add uri redirection for /ontologies/:acronym/:id to the appropriate page

* small fixes: remove binding.pry and return resource_id in find_type_by_search

* Add copy agroportal link functionality

- this functionality is using the ClipboardComponent because it works the same but differ only in the content and icon
- the clipboard component has been changed to accept title and icon

* redirect to content finder page when no type is valid

* Updated route to use redirect action instead of show_redirection

* Use default icon and title arguments in the Clipboard Component

* rename and internationalize clipboard component titles

* small fix: remove % from svg icon

* Add the copy title to the components section in en.yml and fr.yml

* Show the generated uri when user hover over the copy link icon

* Make the dynamic route content negotiable

- based on the accept header we will
  - if "text/html" we will redirect to the agroportal page
  - else we will call the api and get the content serialized in the format specified and return it

* update serialize content to return accept_header

* translate copy_original_uri and copy_portal_uri to french

* reuse search content concern in uri redirection concern

* remove duplicate link_last_part method

* Add htaccess functionality

* Add apache and nginx instruction for htaccess redirection

* Clean te code in the view file

* Add OntologiesRedirectionController

- remove redirect and generate_htaccess from ontologies_controller
- clean code the generate_htaccess method
- add "ontology_portal_uri" in @Identifiers

* Regroupe routes

* Make ontologies_redirection controller and refactor generate_htaccess code

* Internationalization of redirection rewrite rules modal

* Add note for url that has #

* link contact support button to the feedback page

* Change regex to redirect only url of type: /path/resource_id

- for urls that has the # it will redirect to the ontology page

* Add ontology redirection based on the accept header format

* move the ontology redirection route to the bottom to have less priority

* Change rewrite rules note using alert component

* Add /ontologies/ACRONYM/download?format=FORMAT route

* ontology redirection  based on the accept header using /ontologies/acronym/download route

* Add redirect assertion in ontologies controller test

* Fix content serialization when calling /ontologies/:acronym/:id

* create private function for accept header and remove ontology redirection

* remove generate_rewrite_rules function

* remove redirect assertion in ontologies controller test

* change htaccess route to /ontologies/:acronym/htaccess

* fix copy internal links in LinkFieldComponent

* add raw to copy internal links in identifiers card

* return all response and add text/n3 format in content serializer

* escape id when redirecting to content_finder

* choose the right result from the results of search content

* add algorithm to choose the right accept header, not_acceptable if no format valid

* add an additional security to the uri redirection to have an exact match

* make the check resolvability icon clickable & redirect to the tool page

* make the check resolvability extend to accept equivalent formats

* move the redirection function from ontologies_controller to uri concern

* fix check_resolvability_tool to redirect to the full url not only the path

- the problem was because everytime it is redirecting to the uri.path and uri.path does not include the ?format parameter
- add the octet-stream accept header in the accepted format for xml

* add reference to the url of the original file when format not acceptable

* put again the resolvability timeout to 5 secondes

---------

Co-authored-by: Syphax bouazzouni <gs_bouazzouni@esi.dz>

* Fix: Release 2.8.0 grouped issues - Summary, Concept, Notes, Mappings pages (#613)

* fix hidden multiple synonyms in concept details

* remove unecessary search icon from concepts, instances and schemes trees search inputs

* fix the style of add comment and add proposal buttons

* include page url auto in the errors page feedback form

* add the selected bubble to the mappings legend tooltip

* update the fix of hidden synonyms to prevent possible breaks

* fix concept details raw data values alignement to use divs breaking line

* fix recommender result ontology link to redirect to UI not API

* fix summary ofaire tooltip breaking to a new line the card header

* fix opening the concept tree view link in a new tab showing only html

* fix french dates internationalization

* fix edit submission up front help message in english version

* handle the case of ontologies returning an error when roots are called

* add no properties alert message to the ontology viewer

* prevent ontology show redirection if summaryOnly  show summary directly

* localize the mappings vizualization legend text

---------

Co-authored-by: Syphax Bouazzouni <gs_bouazzouni@esi.dz>

* fix data tables warning issue (#624)

---------

Co-authored-by: Bilel Kihal <61744974+Bilelkihal@users.noreply.github.com>
Co-authored-by: Imad Bourouche <ji_bourouche@esi.dz>
Co-authored-by: Jennifer Vendetti <vendetti@stanford.edu>
Bilelkihal added a commit that referenced this pull request Jun 12, 2024
* add json button ui to search page

* extract json_link method from annotator controller to application controller

* build the search page json link using json_link method

* move the search json button down besides the advanced options button

* remove this usage of api_params instead of direct params in search controller

---------

Co-authored-by: Syphax Bouazzouni <gs_bouazzouni@esi.dz>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants