Review main Merged

76595[FEATURE] Make context menu trigger configurable

Benjamin Kott CR +2 V +2 Hard +337 −62 updated 11/15/22, 13:46

Commit message

The context menu JavaScript API was adapted to also support opening
the menu through the "contextmenu" event type (right click) only.
Configuration for the context menu was streamlined and now reflects
its purpose. The trigger can now be set to "click" or "contextmenu".

Before:
    class="t3js-contextmenutrigger"
    data-table="pages"
    data-uid="10"
    data-context="tree"

After:
    data-contextmenu-trigger="click"
    data-contextmenu-table="pages"
    data-contextmenu-uid="10"
    data-contextmenu-context="tree"

New options:
data-contextmenu-trigger:
    click:
        Opens the contextmenu click and contextmenu
    contextmenu:
        Opens the contextmenu only on contextmenu

Examples:

    <a href="#"
        data-contextmenu-trigger="click"
        data-contextmenu-table="pages"
        data-contextmenu-uid="10"
    >
    Click and Contextmenu
    </a>

    <a href="#"
        data-contextmenu-trigger="contextmenu"
        data-contextmenu-table="pages"
        data-contextmenu-uid="10"
    >
    Contextmenu only
    </a>

Legacy configuration with `.t3js-contextmenutrigger` is still
supported to avoid migration issues, but is now considered
deprecated and will be removed with TYPO3 v13.

Review

  • Code review CR +2 Done
    • Benni Mack +2
    • Andreas Kienast +1
  • Verified V +2 Done
    • Benni Mack +2
    • Andreas Kienast +1
    • core-ci +1 CI

Issues 1

Files 25

Show 5 more files

Review log 1626

Show 1 earlier messages
  1. Benjamin Kott uploaded patch set 1 11/14/22, 13:04

  1. core-ci voted on patch set 1 V -1 11/14/22, 13:13 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/33701

  2. Benjamin Kott uploaded patch set 2 11/14/22, 13:35

  3. Benjamin Kott uploaded patch set 3 11/14/22, 13:44

  4. core-ci voted on patch set 2 V -1 11/14/22, 13:47 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/33708

  5. Benjamin Kott uploaded patch set 4 11/14/22, 13:48

  6. Benjamin Kott uploaded patch set 5 11/14/22, 13:55

  7. core-ci voted on patch set 3 V -1 11/14/22, 13:55 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/33709

  8. core-ci voted on patch set 4 V -1 11/14/22, 14:00 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/33710

  9. core-ci voted on patch set 5 V +1 11/14/22, 14:03 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/33711

  10. Benjamin Kott uploaded patch set 6 11/14/22, 14:44

  11. Benjamin Kott updated the commit message in patch set 7 11/14/22, 14:47

  12. core-ci voted on patch set 6 V +1 11/14/22, 14:53 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/33714

  13. core-ci voted on patch set 7 V +1 11/14/22, 14:55 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/33715

  14. Benjamin Kott uploaded patch set 8 11/14/22, 15:09

  15. core-ci voted on patch set 8 V -1 11/14/22, 15:18 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/33717

  16. Chris Müller commented on patch set 8 CR -1 11/14/22, 16:51

    Deprecation-99084-MakeContextMenuTriggerConfigurable.rst:23

    depreacted -> deprecated

    Deprecation-99084-MakeContextMenuTriggerConfigurable.rst:29

    extension -> extensions

    Deprecation-99084-MakeContextMenuTriggerConfigurable.rst:39

    Please use "-"

    Deprecation-99084-MakeContextMenuTriggerConfigurable.rst:50

    Please use "-" (and the same length as header text).

    Feature-99084-MakeContextMenuTriggerConfigurable.rst:20

    Please use "-" and at least the same length as the header text.

    Feature-99084-MakeContextMenuTriggerConfigurable.rst:27

    Please use "-"
  17. Chris Müller uploaded patch set 9 11/14/22, 18:16

  18. Chris Müller commented on patch set 9 11/14/22, 18:17

    Deprecation-99084-MakeContextMenuTriggerConfigurable.rst:23 Reply

    Done

    Deprecation-99084-MakeContextMenuTriggerConfigurable.rst:29 Reply

    Done

    Deprecation-99084-MakeContextMenuTriggerConfigurable.rst:39 Reply

    Done

    Deprecation-99084-MakeContextMenuTriggerConfigurable.rst:50 Reply

    Done

    Feature-99084-MakeContextMenuTriggerConfigurable.rst:20 Reply

    Done

    Feature-99084-MakeContextMenuTriggerConfigurable.rst:27 Reply

    Done
  19. core-ci voted on patch set 9 V -1 11/14/22, 18:24 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/33724

  20. Benjamin Kott uploaded patch set 10 11/15/22, 07:09

  21. core-ci voted on patch set 10 V +1 11/15/22, 07:18 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/33731

  22. Benni Mack voted on patch set 10 CR +1 11/15/22, 13:02

  23. Andreas Kienast voted on patch set 10 V +1 CR +1 11/15/22, 13:10

  24. Benni Mack voted on patch set 10 V +2 CR +2 11/15/22, 13:46

  25. Benni Mack merged patch set 11 11/15/22, 13:46