Skip to content

Conversation

@pedro-mendonca
Copy link
Member

Problem

As described in #1788, there are several inconsistencies in the breadcrumbs:

  • Glossary edit/delete miss the base 'Locale' link
  • Projects and Translation sets have links on the last item (current page)
  • Projects and Translation sets don't have action item for Delete/Edit/Import/Permissions, etc.
  • Glossaries and Locales show correctly the last item without link.

Solution

  • Add a parameter to gp_breadcrumb_project() with extra optional items, with backwards compatibility. If no extra items, the last item (project->name) is used without link. If not empty, all the links are outputed and the extra items are appended (Translation Set, Glossary, action, etc)

Testing Instructions

Navigate through all the possible pages:

  1. Locales
  2. Locales / Locale
  3. Locales / Locale / Glossary
  4. Locales / Locale / Glossary / (Delete|Edit|Import)
  5. Projects
  6. Projects / Project
  7. Projects / Project / (Delete|Edit|Permissions|Import|Etc)
  8. Projects / Project / Set
  9. Projects / Project / Set / (Delete|Edit|Create)
  10. Projects / Project / Set / Project Glossary
  11. Projects / Project / Set / Project Glossary / (Delete|Edit|Create)

Etc.

Screenshots

Locales and Global glossaries

imagem
imagem
imagem
imagem
imagem
imagem

Projects

imagem
imagem
imagem
imagem
imagem
imagem
imagem
imagem
imagem
imagem

Translation Sets and Project glossaries

imagem
imagem
imagem
imagem
imagem
imagem
imagem
imagem
imagem


Fixes #1788

Copy link
Member

@amieiro amieiro left a comment

Choose a reason for hiding this comment

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

I have just reviewed the code and the functionality, and it works nice. Good job!
I have suggested two small changes in the gp_breadcrumb_projectfunction. Please, take a look and then I will merge this PR. Thank you!

@pedro-mendonca
Copy link
Member Author

Thanks for the review @amieiro
I've added your suggestions and linted it.
It's ready :)

@amieiro amieiro enabled auto-merge (squash) February 23, 2024 11:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Breadcrumbs: All the items have links including the last one (current), only some have ending actions

2 participants