Skip to content

Sometimes all elements are collapsed by default, unable to change state #11

@sypets

Description

@sypets

Update: Problem might be due to using outdated browser. So, better alternative might be updating browser. See compat. matrix: https://developer.mozilla.org/en-US/docs/Web/API/Element/ariaExpanded#browser_compatibility


It has been reported at least twice since extension was activated. At first I could not reproduce it, but after switching browser from Chromium to Firefox, I could.

It was reported that all elements were collapsed. It was possible to expand individual elements, but after reloading the page, the behaviour was the same (all elements collapsed).

Overrall, we saw 2 different problems:

  1. when element was collapsed, this was not saved. Looks similar to Collapse state is not saved in user settings #1 and Collapse state is still not saved in user settings #7 and seemed to be fixed with [BUGFIX] Make sure state is stored in user settings #10
  2. (this issue) all elements collapsed, not possible to change behaviour. Depends on Browser

I will create PR.

Possible solution

changing

- if (btn.ariaExpanded == 'true') {
+ if (btn.getAttribute('aria-expanded') == 'true') {

in PageModuleCollapse.js

was reported to work.

Info

Behaviour may be browser-dependant, see also

Versions

  • TYPO3: 11.5.38
  • container: 2.3.6
  • collapse: latest 1.0.0 (or latest "main")

reproduced with

  • Firefox 115.12.0esr (64-bit) "Extended Support Release", Xubuntu (Linux)

Note: I usually do not use Firefox, this might be an outdated version. The other colleagues are usually under Windows using automatically updated versions.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions