WordPress / twentytwenty

Twenty Twenty is included in Core as of WordPress 5.3 🎉 To report any issues, please go here: https://core.trac.wordpress.org/newticket
Other
301 stars 140 forks source link

Conditional loading of language/locale specific css and php files #970

Closed nukaga closed 4 years ago

nukaga commented 5 years ago

Description In the current site design, the title is too large in Japanese and Chinese. The center alignment is also extraordinary.

https://github.com/WordPress/twentytwenty/issues/118#issuecomment-541292567 https://github.com/WordPress/twentytwenty/issues/118#issuecomment-538964579

Solution Is it possible to separate the title and body CSS in several languages?

waviaei commented 5 years ago

I think a possible neat and WordPress-like solution is, for example;

and so on . A conditional or auto-loading of language specific php would be nice too, because then we can dequeue the latin font, and replace with, e.g., ja font if only the site is ja.

I know that Justin Tadlock's Hybrid theme series has had this customization for a long time. I have contributed to his Stargazer theme's ja.css. Also as a bonus, this way, it makes easier for polyglot community to add contribute language specific files later its release.

https://github.com/justintadlock/stargazer

I believe in latest Hybrid core system, the relevant codes are around here: https://themehybrid.com/docs/hybrid-core-i18n https://github.com/justintadlock/hybrid-core/tree/master/src/Lang

Would this be feasible solution to adopt this into twentytwenty? (event better, the core?) (of course, not adding the Hybrid-Core into twentytwenty but adopting some relevant codes)

ianbelanger79 commented 4 years ago

Has been moved to trac https://core.trac.wordpress.org/ticket/48800