Bug #64165

Mixed up configuration options of the Abbreviation RTE plugin

Added by Alexander Stehlik over 5 years ago. Updated over 1 year ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
RTE (rtehtmlarea + ckeditor)
Target version:
-
Start date:
2015-01-07
Due date:
% Done:

100%

TYPO3 Version:
7
PHP Version:
5.5
Tags:
Complexity:
medium
Is Regression:
No
Sprint Focus:

Description

As far as I understand it there seems to be a mixup of configuration options in the abbreviation / acronym plugin of the rtehtmlarea RTE.

In the Abbreviation.js file there options are currently used:

this.pageTSConfiguration.noAcronym
this.pageTSConfiguration.noAbbr

As far as I understand it, these option should disable the acronym / abbreviation tabs. So when both are set to FALSE, the button is not available. Makes sense.

What does not make sense is that these options are also used to determine if there are predefined acronyms or abbreviations.

The main error is that the values are overwritten in the buildJavascriptConfiguration() method of the Abbreviation PHP Plugin class.

Another error is that these settings are used to determine, if the fieldsets with the predefined values should be rendered. This should be totally independent configuration options IMO.


Related issues

Duplicates TYPO3 Core - Feature #63040: RTE: Add configuration property buttons.abbreviation.removeFieldsets Closed 2014-11-17

Associated revisions

Revision 5a758362 (diff)
Added by Stanislas Rolland over 5 years ago

[BUGFIX] RTE: Mixed up configuration options of the Acronym button

The Acronym button will be enabled even when no acronym record exists.
The Abbreviation tab will be shown even if no acronym record of this
type exists; in such case, the predefined abbreviation fieldset will not be shown.
However, the Acronym tab will not be shown if no acronym record of this
type exists. If the current selection is empty and not within an abbr
tag, the Abbreviation fieldset will not be show. If the current
selection is empty and not within an acronym tag, the Acronym fieldset
will not be show.

Releases: 6.2
Resolves: #64165
Change-Id: I590acd8d2ee10f2e9509ecb15c9b65876a363eda
Reviewed-on: http://review.typo3.org/36725
Tested-by: Alexander Stehlik <>
Reviewed-by: Stanislas Rolland <>
Tested-by: Stanislas Rolland <>

Revision ff108e1e (diff)
Added by Stanislas Rolland about 5 years ago

[FEATURE] RTE: Add property buttons.abbreviation.removeFieldsets

The configuration property specifies a list of fieldsets to remove from
the abbreviation dialogue. Possible string values are: acronym,
definedAcronym, abbreviation, definedAbbreviation

Releases: master
Resolves: #63040
Resolves: #64165

Change-Id: I8c25279d8aa00b33f285ef8091d3f92ca25c1e1d
Reviewed-on: http://review.typo3.org/34287
Reviewed-by: Stanislas Rolland <>
Tested-by: Stanislas Rolland <>

History

#1 Updated by Gerrit Code Review over 5 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/35863

#2 Updated by Gerrit Code Review over 5 years ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/35863

#3 Updated by Stanislas Rolland over 5 years ago

  • Description updated (diff)

This is a duplicate of #63040 with a different solution.

Properties noAbbr and noAcronym should only be used to determine whether the predefined abbreviations or predefined acronyms fieldsets should be shown as they indicate that such predefined items exist or not.

Property removeAcronymTab is missing to specify that the Acronym tab should not be shown.

As the acronym tag is deprecated, this is the only property really needed. It would not make much sense to remove the abbreviation tab.

Please review and test this change: http://review.typo3.org/34287

#4 Updated by Alexander Stehlik over 5 years ago

Thank you for the pointer :)

I'll have a look at it when Gerrit is back online.

#5 Updated by Stanislas Rolland over 5 years ago

I think that the plugin works as intended: if no records are found, the button is disabled, if no records of one of the two types is found, the corresponding tab is removed.

#6 Updated by Alexander Stehlik over 5 years ago

You could still set manual abbreviations / acronyms, right?

IMO this is a bug. Only the select fields should be hidden if no records are found.

The tabs and the button should never disappear because no records exist.

Can you explain why the buttons / tabs should be hidden?

#7 Updated by Stanislas Rolland over 5 years ago

Alexander Stehlik wrote:

You could still set manual abbreviations / acronyms, right?

IMO this is a bug. Only the select fields should be hidden if no records are found.

The tabs and the button should never disappear because no records exist.

Can you explain why the buttons / tabs should be hidden?

I agree with you, this is an historical bug. And it should be fixed on TYPO3 CMS 7.

But I am concerned that if we fix this in 6.2, the user will have no way to remove the acronym tab. And some installations may see it suddenly appear... Perhaps we could keep the abbreviation tab if no abbreviation record exists.

#8 Updated by Stanislas Rolland over 5 years ago

There is another bug in the handling of the fieldsets of this plugin. If no text is currently selected, the ad hoc abbreviation/acronym fieldsets should not be available because this causes an empty tag to be inserted.

#9 Updated by Alexander Stehlik over 5 years ago

I see, thanks for your explanations.

I guess this issue can be closed an we should concentrate on cleaning this up in https://review.typo3.org/#/c/34287/ :)

#10 Updated by Stanislas Rolland over 5 years ago

  • Status changed from Under Review to Closed

#11 Updated by Gerrit Code Review over 5 years ago

  • Status changed from Closed to Under Review

Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/34287

#12 Updated by Gerrit Code Review over 5 years ago

Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/34287

#13 Updated by Gerrit Code Review over 5 years ago

Patch set 1 for branch TYPO3_6-2 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/36725

#14 Updated by Gerrit Code Review over 5 years ago

Patch set 6 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/34287

#15 Updated by Stanislas Rolland over 5 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

#16 Updated by Benni Mack over 1 year ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF