nextcloud-vue icon indicating copy to clipboard operation
nextcloud-vue copied to clipboard

[DRAFT] fix(NcTimezonePicker): new design with l10n

Open ShGKme opened this issue 3 months ago โ€ข 12 comments

โ˜‘๏ธ Resolves

  • Based on https://github.com/nextcloud-libraries/nextcloud-vue/pull/7522
  • Adding more information to each timezone, including l10n

๐Ÿ–ผ๏ธ Screenshots

๐Ÿš๏ธ Before ๐Ÿก After (EN)
image image
DE UA FR AR
image image image image

๐Ÿ Checklist

  • [ ] โ›‘๏ธ Tests are included or are not applicable
  • [ ] ๐Ÿ“˜ Component documentation has been extended, updated or is not applicable
  • [ ] 2๏ธโƒฃ Backport to stable8 for maintained Vue 2 version or not applicable

ShGKme avatar Sep 17 '25 11:09 ShGKme

Very very nice @ShGKme ! Is it possible to cut the " Time" text, as it is very repeated.

In a general case โ€” no. It is a browser-provided timezone string, and it is different for every language. For example, "heure : " in French or "ั‡ะฐั:" in Ukrainian. It is already a short variant.

ShGKme avatar Sep 17 '25 12:09 ShGKme

Also, every part (except for timezoneID like "Europe/Berlin") adds ~50ms component init time ๐Ÿ˜ถ

  • Shot name "Germany Time" - +50ms
  • Offset value "GMT+1" - +50ms
  • Local current time "10:10 PM" - +50ms
  • Actual offset for sorting - +50ms

So removing any part makes the component faster :D

Optimised as much as possible to have the init happen only once and only when needed

ShGKme avatar Sep 17 '25 12:09 ShGKme

Also, every part (except for timezoneID like "Europe/Berlin") adds ~50ms component init time ๐Ÿ˜ถ

Oof :O bummer, would be really nice to stay under 100ms.

But if we cut e.g. the offset value, and the technical name, then it's a bit less nicely usable and searchable.

jancborchardt avatar Sep 17 '25 13:09 jancborchardt

@jancborchardt Maybe this would be useful โ€” examples of available formats in different languages:

Link

ShGKme avatar Sep 17 '25 13:09 ShGKme

@ShGKme bit of a mess โ€ฆ in English, shortGeneric is a bit better, but in German thatโ€™s quite bad. (Just showing "MEZ" a bunch.)

If we just go for one, is it possible to say that e.g. in English and others we use "shortGeneric", and in German we use "Timezone ID"? Sorry to overcomplicate it, but the system doesnโ€™t seem to make it simple. :\

jancborchardt avatar Sep 17 '25 15:09 jancborchardt

is it possible

Yes, but the question will be - for which languages do we want an exception

and in German we use "Timezone ID"

ID is a technical non-translated value. Maybe at least a long name? Or City + Short?

MEZ (Berlin)

ShGKme avatar Sep 17 '25 16:09 ShGKme

@ShGKme but if we use shortGeneric + city, we still use 2*50ms, right? So maybe it's fine to just go with your pull request as is, and then iterating based off that if we see specific issues?

jancborchardt avatar Sep 17 '25 17:09 jancborchardt

From the visual side, I like this, but what belongs to what can be a bit confusing. Could separators be added between the items? Or alternatively just the top/bottom padding increased (although that compromises on information density).

kra-mo avatar Sep 18 '25 08:09 kra-mo

although that compromises on information density

On second thought, and after playing with it a bit, just bumping the top/bottom padding might be the better option anyway as for separators, we would need to increase the padding slightly too and they actually introduce a bit of noise themselves.

kra-mo avatar Sep 18 '25 08:09 kra-mo

Separators only for reference

image

kra-mo avatar Sep 18 '25 08:09 kra-mo

From the visual side, I like this, but what belongs to what can be a bit confusing. Could separators be added between the items? Or alternatively just the top/bottom padding increased (although that compromises on information density).

Technically - yes, but I'd avoid such changes in this PR.

We have this style in popovers list items in all the selecting (incl. tag select, user select), action menus, contenteditable autocomplete and etc.

If we want to change the style of the items, I'd insist on changing them in the design, not in a timezone picker specifically...

Here I can propose to increase the internal block padding.

ShGKme avatar Sep 26 '25 22:09 ShGKme

Here I can propose to increase the internal block padding.

Yes, I can agree with that

kra-mo avatar Sep 29 '25 09:09 kra-mo