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

XWIKI-21773: Admin section: make the WYSIWYG section pass webstandard tests #2794

Merged
merged 4 commits into from
Feb 12, 2024

Conversation

Sereza7
Copy link
Contributor

@Sereza7 Sereza7 commented Jan 16, 2024

Jira URL

https://jira.xwiki.org/browse/XWIKI-21773

Changes

Description

  • Fixed the input labels
  • Removed the comment from the test for WYSIWYG

Clarifications

  • It's not the same fix as XWIKI-21523 because we can't rely on javascript enhancements of the form, and we need to provide the label for the input that gets hidden by javascript.

Executed Tests

  • Successfully passed mvn clean install -f xwiki-platform-distribution/xwiki-platform-distribution-flavor/xwiki-platform-distribution-flavor-test/xwiki-platform-distribution-flavor-test-webstandards -Dxwiki.test.startXWiki=false

Expected merging strategy

  • Prefers squash: Yes
  • Only on master.

… tests

* Fixed the input labels

Note: This change successfully passes webstandards for section=WYSIWYG.
It's not the same fix as XWIKI-21523 because we can't rely on javascript enhancements of the form, and we need to provide the label for the input that gets hidden by javascript.
… tests

* Removed the comment from the test for WYSIWYG
@@ -218,7 +218,7 @@

#macro (displayCKEditorConfigProperty $configDoc $propName $action)
<dt>
<label>$configDoc.displayPrettyName($propName)</label>
<label for="CKEditor.ConfigClass_0_${propName}">$configDoc.displayPrettyName($propName)</label>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're sure the xobject is always at index 0 here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From what I could see, this is always the first object with this name that gets displayed, so it's always indexed 0.
I don't think there's much variation in this UI.

Similar to #2642 (comment)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is always the first object with this name that gets displayed, so it's always indexed 0.

First object doesn't necessarily mean indexed at 0. e.g. you can add two xobject in a document, and then remove the first one. If you try that you'll see that now the first xobject in the document is indexed at 1.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in aaf80f3 👍

Running mvn clean install -f xwiki-platform-distribution/xwiki-platform-distribution-flavor/xwiki-platform-distribution-flavor-test/xwiki-platform-distribution-flavor-test-webstandards -Dxwiki.test.startXWiki=false again only highlighted violations unrelated to the objectives of this PR. Manual tests looked good too:
21773-nonHardcoded

Sereza7 and others added 2 commits February 12, 2024 15:14
… tests

* Replaced the hard coded number value with a more robust computed one.
@surli surli merged commit f4714e7 into xwiki:master Feb 12, 2024
1 check passed
Sereza7 added a commit to Sereza7/xwiki-platform that referenced this pull request Feb 12, 2024
… tests (xwiki#2794)

* Fixed the input labels
* Removed the comment from the test for WYSIWYG
* Replaced the hard coded number value with a more robust computed one.
Sereza7 added a commit to Sereza7/xwiki-platform that referenced this pull request Feb 12, 2024
… tests (xwiki#2794)

* Fixed the input labels
* Removed the comment from the test for WYSIWYG
* Replaced the hard coded number value with a more robust computed one.
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

Successfully merging this pull request may close these issues.

2 participants