AUR web interface

**This is the bug tracker for the AUR web interface.**

Use this tracker to report bugs or make feature requests regarding the behaviour or implementation of the AUR software.
Please read the Reporting Bug Guidelines before filing a new task.
http://wiki.archlinux.org/index.php/Reporting_Bug_Guidelines

- Please report bugs related to Arch Linux official packages here: http://bugs.archlinux.org/index.php?project=1
- Please report bugs for [community] packages here: http://bugs.archlinux.org/index.php?project=5
- For any packages in the AUR contact the maintainer or leave a comment on the package's detail page.

Source Code:
https://projects.archlinux.org/aurweb.git/
Tasklist

FS#57737 - Aurweb has no RTL support

Attached to Project: AUR web interface
Opened by Yaron Shahrabani (yaron) - Wednesday, 07 March 2018, 09:21 GMT
Last edited by Eli Schwartz (eschwartz) - Wednesday, 07 March 2018, 12:40 GMT
Task Type Bug Report
Category Backend
Status Unconfirmed
Assigned To No-one
Architecture All
Severity Medium
Priority Normal
Reported Version 4.6.0
Due in Version Undecided
Due Date Undecided
Percent Complete 0%
Votes 1
Private No

Details

Description:
The aurweb UI is translated to both Hebrew and Arabic, these languages are written from Right to Left (aka RTL).
Some CSS changes are needed to enable full support.
First there should be some condition indicating whether the language is RTL or LTR and then select an additional CSS file according to the selection (the rules that make the change will have !important at the end, something like: "float: right !important" for example).

I can create a pull request for the CSS but I'm not familiar with the code to enable conditional CSS selection.

Thanks!
This task depends upon

Comment by Eli Schwartz (eschwartz) - Wednesday, 07 March 2018, 12:54 GMT
Well, see https://developer.mozilla.org/en-US/docs/Web/CSS/direction

But simply globally enabling this doesn't entirely have the right effect regarding some of the layout elements...

If you can get this to work, please submit a patch as per the project contribution guidelines described in https://git.archlinux.org/aurweb.git/tree/doc/CodingGuidelines
Comment by Yaron Shahrabani (yaron) - Thursday, 08 March 2018, 07:35 GMT
Yeah I kinda figured that, furthermore, we can't change the top banner because it's not AUR specific.

Can I have your assistance with all the CSS selection part? I will try to come up with a good working CSS sheet and I'll submit it as a PR.
Comment by Yaron Shahrabani (yaron) - Thursday, 08 March 2018, 12:56 GMT
Looking good but still needs more work, I need to make some decisions regarding usability and breaking RTL and then I'll be able to submit the patch, I can post my CSS in the meanwhile if you'd like to take a look.
Comment by Yaron Shahrabani (yaron) - Sunday, 15 July 2018, 08:48 GMT
Hey, I was thinking, all the help I actually need is the mechanism to load a different CSS when selecting a certain language, I will create the patch on top of that, will you be able to assist me with that?
Comment by Yaron Shahrabani (yaron) - Monday, 27 August 2018, 11:07 GMT
Main screen looking good, I don't know how to create a different CSS file when selecting a language, otherwise I would just create a pull request for it.
   aur_rtl.png (160.4 KiB)
Comment by Eli Schwartz (eschwartz) - Monday, 27 August 2018, 18:22 GMT
You could just use PHP to check for the $LANG variable (which we set to the user's current language) and, depending on whether a language-specific CSS file exists, include it in the rendered HTML.

Alternatives include setting the CSS selector :lang() but as per https://developer.mozilla.org/en-US/docs/Web/CSS/:lang#Specifications you cannot really specify multiple languages for one rule that way...

Loading...