View Issue Details

This bug affects 1 person(s).
 12
IDProjectCategoryView StatusLast Update
12349Bug reportsData Entry (non public)public2021-11-01 16:15
ReporterDeveloperChris Assigned Togabrieljenik  
PriorityhighSeverityminor 
Status closedResolutionfixed 
Product Version4.1.7 
Summary12349: RTL languages not dispayed correctly in the admin editor
Description

When editing questions etc using the wysiwyg editor is incorrectly set as LTR

Editors for RTL languages should display in RTL

This can cause layout issues as users incorrectly apply unnecessary text alignment

Steps To Reproduce

Create a dual language survey where the secondary language is Arabic

Create a question and switch to the Arabic tab

Toolbars are displayed LTR
Text is displayed LTR

View source code:
Editor utilises LTR in its styling.

Additional Information

One suggestion may be to switch your admin language to the alternate language. While that works its very clumsy and the alternate problem occurs. In other words the English editor is now displaying in RTL.

TagsNo tags attached.
Attached Files
Bug heat12
Complete LimeSurvey version number (& build)Version 2.64.7+170404, ALL LS3, Version 4.1.6+200220
I will donate to the project if issue is resolvedNo
BrowserFirefox
Database type & versionNA
Server OS (if known)NA
Webserver software & version (if known)NA
PHP VersionNA

Relationships

related to 15030 closeddominikvitt Css and font issue, Arabic is not displayed properly. 

Users monitoring this issue

There are no users monitoring this issue.

Activities

ollehar

ollehar

2017-04-28 15:30

administrator   ~43494

Do you know if this is possible, Carsten?

c_schmitz

c_schmitz

2018-02-15 11:53

administrator   ~46505

Last edited: 2021-03-19 10:09

Sure it is. Correct behaviour should be that the CKEditor RTL orientation should be the one of the survey language, not admin interface language.

ollehar

ollehar

2018-02-15 13:45

administrator   ~46525

Last edited: 2021-03-19 10:09

Can you please update to the latest version first, 2.73? Thank you. Let me know if the problem persists.

cdorin

cdorin

2019-08-14 14:45

reporter   ~53176

Last edited: 2021-03-19 10:09

I will close it - new bug report with SS reported here 15030

DeveloperChris

DeveloperChris

2019-10-14 05:42

reporter   ~54015

Last edited: 2021-03-19 10:09

Not sure why this was closed but the issue persists into LimeSurvey Version 3.19.1

I have tested on the demo site.

The linked issue 15030 is about the administration interface when it is set to Arabic. not when the admin interface is English but you are trying to compose Arabic questions.

DeveloperChris

DeveloperChris

2019-10-14 05:45

reporter   ~54016

Last edited: 2021-03-19 10:09

I have attached some example images from https://demo.limesurvey.org/index.php?r=admin/questions/sa/editquestion/surveyid/344972/gid/92/qid/2562

DeveloperChris

DeveloperChris

2019-10-14 05:48

reporter   ~54017

Last edited: 2021-03-19 10:09

Sorry made a mistake here is the second image

DeveloperChris

DeveloperChris

2019-10-14 07:18

reporter   ~54018

Last edited: 2021-03-19 10:09

A workaround for the issue, but it only works for Arabic and would have to be modified for other rtl languages like Hebrew

Create a custom admin theme
Add a custom JavaScript file to the config.xml file in your custom admin theme

    <js>
        <filename>arfix.js</filename>
    </js>

create a js file in the scripts subfolder (may have to create this folder)
in my case I added the file arfix.js

in that file add the following code
jQuery(document).ready(function( $ ) {

  $('a[href="#ar"]').click(function(){
      $("#ar iframe").contents().find("html").attr("dir","rtl");
      $("#ar iframe").contents().find("html").attr("lang","ar");
  });

});

flush the admin theme from the global settings file

Now when an author clicks on the Arabic editor tab the language direction will be changed to RTL

DeveloperChris

DeveloperChris

2019-10-14 07:19

reporter   ~54019

Last edited: 2021-03-19 10:09

sorry for the bad formatting above it seems the editor here has a few bugs as well...

cdorin

cdorin

2019-11-03 15:54

reporter   ~54349

Last edited: 2021-03-19 10:09

Hey @DeveloperChris,

I will check it again asap. thanks for the heads up!

ollehar

ollehar

2020-02-24 14:57

administrator   ~56166

Last edited: 2021-03-19 10:09

Won't fix, LS2 is no longer supported. Please check if the issue persists in LS3 and LS4.

DeveloperChris

DeveloperChris

2020-02-24 23:26

reporter   ~56190

Last edited: 2021-03-19 10:09

This is a problem that started in LS2 but continues in LS3 and is considerably worse in LS4

I am not sure why you closed this bug without at least checking to see that it had been resolved.

The reason why it is considerably worse in LS4 is because LS4 has changed the way the editor and tabs work and rather than reload the editor and content it just switches the content in and out, rendering my previous hack as unworkable.

DenisChenu

DenisChenu

2020-02-25 08:02

developer   ~56191

Last edited: 2021-03-19 10:09

@DeveloperChris : please report another issue for 4.X

Else : did 4.X RTL functionality work good in 4.X without the HTML editor ?

PS : i think too we must have a clean RTL system

ollehar

ollehar

2020-02-25 10:04

administrator   ~56196

Last edited: 2021-03-19 10:09

I am not sure why you closed this bug without at least checking to see that it had been resolved.

Time.

Thanks for checking.

DeveloperChris

DeveloperChris

2020-02-25 23:50

reporter   ~56202

Last edited: 2021-03-19 10:09

This is the second time it has been closed without doing any due diligence, Bugs don't go away just because you close a bug report. I had already reported this bug continued into LS3, and LS4 is not yet up to a standard we can use. For example take a quick look at the question type selector. It includes a "Browser Check" question type which looks like its a hangover from debugging and as this is in a release it brings into question how well tested the code actually is. https://bugs.limesurvey.org/view.php?id=12349#c54015

"Not sure why this was closed but the issue persists into LimeSurvey Version 3.19.1"

A simple request to check LS4 would have been sufficient, but for someone who is trying to help by at the very minimum reporting issues (we are also financial supporters) we find it is a slap in the face to have our efforts discarded without thought.

Thanks Denis. I'd love to repeat everything I have done in a new report. But I don't have the "Time"

cdorin

cdorin

2020-10-20 13:00

reporter   ~60298

Last edited: 2021-03-19 10:09

Hey @DeveloperChris - we will be reverting to the old LS view in LS4.4 next month. I will move this ticket to acknowledged and assigned it to myself.
Thank you for your contributions!

cdorin

cdorin

2020-12-23 11:20

reporter   ~61075

Last edited: 2021-03-19 10:09

Hello @DeveloperChris , 4.4.0 RC1 has been released. Could you please check if everything is fine now :) ?

c_schmitz

c_schmitz

2021-03-19 10:09

administrator   ~63459

Last edited: 2021-03-19 10:09

I can confirm that this issue is still not resolved.

gabrieljenik

gabrieljenik

2021-05-13 21:40

manager   ~64405

https://github.com/LimeSurvey/LimeSurvey/pull/1879

Corrected it for the editor of both the question and help, as well as for subquestions and answers.
We can apply the correction on other places as well.

Added a function to twig extensions as to check if the language is RTL. That function feeds the editor settings

gabrieljenik

gabrieljenik

2021-05-20 12:54

manager   ~64487

Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=31802

gabrieljenik

gabrieljenik

2021-05-21 10:29

manager   ~64499

Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=31812

gabrieljenik

gabrieljenik

2021-06-10 11:45

manager   ~64828

Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=32016

gabrieljenik

gabrieljenik

2021-11-01 16:15

manager   ~67032

Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=32844

Related Changesets

LimeSurvey: master 76b17d75

2021-05-20 12:54:42

gabrieljenik


Committer: GitHub Details Diff
Fixed issue 12349: RTL languages not dispayed correctly in the admin editor (#1879)

Co-authored-by: encuestabizdevgit <devgit@encuesta.biz>
Affected Issues
12349
mod - application/config/internal.php Diff File
mod - application/controllers/admin/htmleditor_pop.php Diff File
mod - application/core/LS_Twig_Extension.php Diff File
mod - application/helpers/admin/htmleditor_helper.php Diff File
mod - application/views/admin/htmleditor/pop_editor_view.php Diff File
mod - application/views/admin/survey/prepareEditorScript_view.php Diff File
mod - application/views/questionAdministration/answerOptionRow.twig Diff File
mod - application/views/questionAdministration/subquestionRow.twig Diff File
mod - application/views/questionAdministration/textElements.php Diff File
mod - assets/packages/modaleditor/js/modaleditor.js Diff File

LimeSurvey: master daba9f0f

2021-05-20 12:54:42

gabrieljenik


Committer: ollehar Details Diff
Fixed issue 12349: RTL languages not dispayed correctly in the admin editor (#1879)

Co-authored-by: encuestabizdevgit <devgit@encuesta.biz>
Affected Issues
12349
mod - application/config/internal.php Diff File
mod - application/controllers/admin/htmleditor_pop.php Diff File
mod - application/core/LS_Twig_Extension.php Diff File
mod - application/helpers/admin/htmleditor_helper.php Diff File
mod - application/views/admin/htmleditor/pop_editor_view.php Diff File
mod - application/views/admin/survey/prepareEditorScript_view.php Diff File
mod - application/views/questionAdministration/answerOptionRow.twig Diff File
mod - application/views/questionAdministration/subquestionRow.twig Diff File
mod - application/views/questionAdministration/textElements.php Diff File
mod - assets/packages/modaleditor/js/modaleditor.js Diff File

LimeSurvey: master f620df67

2021-05-20 12:54:42

gabrieljenik


Committer: ollehar Details Diff
Fixed issue 12349: RTL languages not dispayed correctly in the admin editor (#1879)

Co-authored-by: encuestabizdevgit <devgit@encuesta.biz>
Affected Issues
12349
mod - application/config/internal.php Diff File
mod - application/controllers/admin/htmleditor_pop.php Diff File
mod - application/core/LS_Twig_Extension.php Diff File
mod - application/helpers/admin/htmleditor_helper.php Diff File
mod - application/views/admin/htmleditor/pop_editor_view.php Diff File
mod - application/views/admin/survey/prepareEditorScript_view.php Diff File
mod - application/views/questionAdministration/answerOptionRow.twig Diff File
mod - application/views/questionAdministration/subquestionRow.twig Diff File
mod - application/views/questionAdministration/textElements.php Diff File
mod - assets/packages/modaleditor/js/modaleditor.js Diff File

LimeSurvey: master 756c9dc6

2021-10-01 21:35:23

gabrieljenik

Details Diff
Fixed issue 12349: RTL languages not dispayed correctly in the admin editor

- Fixed alignment of some html elements
Affected Issues
12349
mod - application/views/admin/globalsettings/_general.php Diff File
mod - assets/packages/adminbasics/build/adminbasics.css Diff File
mod - assets/packages/adminbasics/build/adminbasics.min.css Diff File
mod - assets/packages/adminbasics/build/adminbasics.rtl.css Diff File
mod - assets/packages/adminbasics/build/adminbasics.rtl.min.css Diff File
mod - assets/packages/adminbasics/scss/000-lime-admin-common.scss Diff File

Issue History

Date Modified Username Field Change
2017-04-27 05:32 DeveloperChris New Issue
2017-04-28 14:57 ollehar Assigned To => ollehar
2017-04-28 14:57 ollehar Status new => assigned
2017-04-28 15:30 ollehar Assigned To ollehar => c_schmitz
2017-04-28 15:30 ollehar Note Added: 43494
2017-05-03 18:00 LouisGac Priority none => urgent
2018-02-15 11:53 c_schmitz Assigned To c_schmitz => ollehar
2018-02-15 11:53 c_schmitz Note Added: 46505
2018-02-15 13:45 ollehar Status assigned => feedback
2018-02-15 13:45 ollehar Note Added: 46525
2019-08-14 14:45 cdorin Assigned To ollehar => cdorin
2019-08-14 14:45 cdorin Status feedback => closed
2019-08-14 14:45 cdorin Resolution open => not fixable
2019-08-14 14:45 cdorin Note Added: 53176
2019-08-14 14:45 cdorin Relationship added related to 15030
2019-10-14 05:42 DeveloperChris Status closed => feedback
2019-10-14 05:42 DeveloperChris Resolution not fixable => reopened
2019-10-14 05:42 DeveloperChris Note Added: 54015
2019-10-14 05:45 DeveloperChris File Added: 2019-10-14 14_12_48-LimeSurvey.png
2019-10-14 05:45 DeveloperChris File Added: 2019-10-14 14_13_43-LimeSurvey.png
2019-10-14 05:45 DeveloperChris Note Added: 54016
2019-10-14 05:45 DeveloperChris Status feedback => assigned
2019-10-14 05:48 DeveloperChris File Deleted: 2019-10-14 14_13_43-LimeSurvey.png
2019-10-14 05:48 DeveloperChris File Added: 2019-10-14 14_13_43-LimeSurvey.png
2019-10-14 05:48 DeveloperChris Note Added: 54017
2019-10-14 07:18 DeveloperChris Note Added: 54018
2019-10-14 07:19 DeveloperChris Note Added: 54019
2019-11-03 15:54 cdorin Note Added: 54349
2020-02-24 14:57 ollehar Status assigned => closed
2020-02-24 14:57 ollehar Note Added: 56166
2020-02-24 23:26 DeveloperChris Status closed => feedback
2020-02-24 23:26 DeveloperChris Complete LimeSurvey version number (& build) Version 2.64.7+170404 => Version 2.64.7+170404, ALL LS3, Version 4.1.6+200220
2020-02-24 23:26 DeveloperChris Note Added: 56190
2020-02-25 08:02 DenisChenu Note Added: 56191
2020-02-25 10:04 ollehar Note Added: 56196
2020-02-25 23:50 DeveloperChris Note Added: 56202
2020-02-25 23:50 DeveloperChris Status feedback => assigned
2020-02-27 00:23 c_schmitz Product Version 2.64.x => 4.1.7
2020-05-27 15:43 cdorin Priority urgent => high
2020-10-20 13:00 cdorin Note Added: 60298
2020-10-20 13:01 cdorin Status assigned => acknowledged
2020-12-23 11:20 cdorin Note Added: 61075
2020-12-23 11:20 cdorin Assigned To cdorin =>
2020-12-23 11:20 cdorin Status acknowledged => feedback
2021-03-19 10:09 c_schmitz Note Added: 63459
2021-03-19 10:09 c_schmitz Status feedback => confirmed
2021-03-19 10:09 c_schmitz Sync to Zoho Project => |Yes|
2021-05-13 21:40 gabrieljenik Note Added: 64405
2021-05-17 16:10 gabrieljenik Assigned To => gabrieljenik
2021-05-17 16:10 gabrieljenik Status confirmed => ready for testing
2021-05-20 12:54 gabrieljenik Changeset attached => LimeSurvey master 76b17d75
2021-05-20 12:54 gabrieljenik Note Added: 64487
2021-05-20 12:54 gabrieljenik Resolution reopened => fixed
2021-05-21 10:29 ollehar Changeset attached => LimeSurvey master daba9f0f
2021-05-21 10:29 gabrieljenik Note Added: 64499
2021-06-10 11:45 ollehar Changeset attached => LimeSurvey master f620df67
2021-06-10 11:45 gabrieljenik Note Added: 64828
2021-07-13 08:56 c_schmitz Status ready for testing => closed
2021-11-01 16:15 gabrieljenik Changeset attached => LimeSurvey master 756c9dc6
2021-11-01 16:15 gabrieljenik Note Added: 67032