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

Custom sorting for page contributors #198

Open
ziadbkh opened this issue Aug 11, 2023 · 7 comments
Open

Custom sorting for page contributors #198

ziadbkh opened this issue Aug 11, 2023 · 7 comments
Labels

Comments

@ziadbkh
Copy link

ziadbkh commented Aug 11, 2023

I would like to report an issue on the Page mechanics page at /page_mechanics. Description of the issue:
Can we do a custom sort for the contributors of the page based on how they appear in the metadata?

@bedroesb
Copy link
Member

This is a difficult one, since the contributors are a built in include in the layout of the website, so parameters are not a possible route. I could add a website wide option in the _config.yml file, but I m always a bit hesitant with that 🤔

@ziadbkh
Copy link
Author

ziadbkh commented Aug 11, 2023

I am not sure about the website-wide option as I think the order needs to be more flexible as it might change across different pages depending on the roles, contributions, and modification date ...
Very difficult for me to help more without understanding what happens in the background! :(

@ziadbkh
Copy link
Author

ziadbkh commented Aug 11, 2023

Is it possible to keep the order as it appears in the list? without using any parameter.
This is more comprehensive, if the user wants to order alphabetically, they can put the names in the list in this order. If it does not matter, they can list the names any way they want.

@bedroesb
Copy link
Member

In other places where we use the theme, we don't want to give priority to contributors since they change all the time, and for that we use the (un)fair - alphabetical order (depends how you see it ;)). Out of experience I can tell that people do not place the names alphabetically by themselves, and the fact that it is done automatically takes out any debate.

Long story short, the automatic sorting should stay as an option to take out possible 'drama' that comes with author listings ;)

@ziadbkh
Copy link
Author

ziadbkh commented Aug 11, 2023

Last attempt! How about if the first string in the list is sorted, the list will be sorted from the second element. Otherwise, it does the usual behaviour? or too much!

@bedroesb
Copy link
Member

You mean the word unsorted so the list will be used as is, and without it it gives the usual alphabetical sorted list? ;)

@ziadbkh
Copy link
Author

ziadbkh commented Aug 16, 2023

yes for this case it should be unsorted.
but also the first keyword will act as a parameter to customise whatever you want with the list, for example, to sort according to the roles or group by role and sort within the groups ...

@bedroesb bedroesb changed the title Issue on page: Page mechanics Custom sorting for page contributors Dec 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants