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

Popup menu tab doesn't open on the initial try #1245

Open
2 tasks done
mfendeksilverstripe opened this issue Aug 30, 2024 · 2 comments
Open
2 tasks done

Popup menu tab doesn't open on the initial try #1245

mfendeksilverstripe opened this issue Aug 30, 2024 · 2 comments

Comments

@mfendeksilverstripe
Copy link
Contributor

Module version(s) affected

5.2.4

Description

Choosing either of the default tabs (Settings or History) from the popup menu will not result in that tab being opened on the first try. Subsequent attempts will work correctly.

This scenario is relevant to only inline editable blocks.

How to reproduce

  • you need sample project install that has elemental
  • create a block page and add a content block (can use the out of the box element content)

You should have something like this:

Screenshot 2024-08-30 at 2 57 02 PM

Now choose a specific tab via the popup menu, "Settings" for example.

Screenshot 2024-08-30 at 2 57 57 PM

Expected behaviour:

I can see the Settings tab

Screenshot 2024-08-30 at 2 59 06 PM

Actual behaviour:

I can see the Content tab

Screenshot 2024-08-30 at 2 58 58 PM

Possible Solution

Clicking on the desired tab the second time will result in correct behaviour.

Additional Context

This seems to be a CMS 5 upgrade related regression.

Validations

  • Check that there isn't already an issue that reports the same bug
  • Double check that your reproduction steps work in a fresh installation of silverstripe/installer (with any code examples you've provided)
@emteknetnz
Copy link
Member

emteknetnz commented Sep 1, 2024

I can't replicate this on a base install with elemental 5.2.4 - possibly there's an interaction with custom code or a module that's been installed?

@mfendeksilverstripe
Copy link
Contributor Author

Hey @emteknetnz I tested this on a vanilla install without any custom code. Here is my composer.json:

{
    "name": "silverstripe/installer",
    "type": "silverstripe-recipe",
    "description": "The SilverStripe Framework Installer",
    "require": {
        "php": "^8",
        "silverstripe/recipe-plugin": "^2",
        "silverstripe/recipe-cms": "5.2.x-dev",
        "silverstripe-themes/simple": "~3.2.0",
        "silverstripe/login-forms": "^5",
        "dnadesign/silverstripe-elemental": "^5"
    },
    "require-dev": {
        "silverstripe/recipe-testing": "^3",
        "silverstripe/graphql-devtools": "^1.0"
    },
    "extra": {
        "resources-dir": "_resources",
        "project-files-installed": [
            "app/.htaccess",
            "app/_config.php",
            "app/_config/mimevalidator.yml",
            "app/_config/mysite.yml",
            "app/src/Page.php",
            "app/src/PageController.php",
            "behat.yml",
            "phpcs.xml.dist",
            "phpunit.xml.dist"
        ],
        "public-files-installed": [
            ".htaccess",
            "index.php",
            "web.config"
        ]
    },
    "config": {
        "process-timeout": 600,
        "allow-plugins": {
            "composer/installers": true,
            "silverstripe/vendor-plugin": true,
            "silverstripe/recipe-plugin": true
        }
    },
    "prefer-stable": true,
    "minimum-stability": "dev"
}

My source folder only contains the out of the box Page and PageController. Here are more detailed steps on how to reproduce it:

  • setup your test page with one element content block
  • reload the page so you have a clean start
  • click on the popup menu and select the settings tab

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants