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

Wrong sorting: list of languages #1497

Open
Der-K-2000 opened this issue Jun 23, 2022 · 5 comments
Open

Wrong sorting: list of languages #1497

Der-K-2000 opened this issue Jun 23, 2022 · 5 comments

Comments

@Der-K-2000
Copy link

In the list at the sidebar the list is sorted by the key, not the value. An example list from the config.php:


'languages' => [
	'danish' => 'Dänisch',
	'german' => 'Deutsch'
	'dutch' => 'Niederländisch',
]

Output will be

1. Dänisch
2. Niederländisch
3. Deutsch

...but it should be

1. Dänisch
2. Deutsch
3. Niederländisch

So the bug is: It's ordered by the array-key, not the value, which it should. And that's confusing, especially for newbies, who are only editing the text-fields.

@Der-K-2000
Copy link
Author

I was wrong. Excuse me. There is actually no sorting. Neither by key nor by value. It depends on the list you've add in the config.php. Nevertheless it would be good to sort by the values.

@takumade
Copy link

Please close this

@Der-K-2000
Copy link
Author

Please close this

Why? It's still not sorted.

@mountainash
Copy link

... but it is sorted... by the top-down line order (you said this yourself @SebastianBerlin).

Line order sorting also gives the Dev much more flexibility than a forced A->Z sort. Sorting by alphabetical would also override to all existing sites which have already set their preferred ordering.

@Der-K-2000
Copy link
Author

Well, no.

  1. There is no "flexibility" if you use multiple languages (for the admin-dashboard). In every language there has to be a different sorting and you can NOT fix that in any way.

It's a failure by construction, at least not well-wrought – and that function is necessary.

  1. Of course, there should be an option to choose, what you want, and to prevent problems with existing configs: Manual by config-file AND logical sorting by the value.

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

No branches or pull requests

3 participants