Review main Merged

67915[TASK] Deprecate usage of jQuery in Tooltip module

Andreas Kienast CR +2 V +2 Normal +104 −21 updated 02/15/21, 07:50

Commit message

Passing jQuery objects to the methods `show()` and `hide()` of the module
`TYPO3/CMS/Backend/Tooltip` has been marked as deprecated.

The methods now check whether a NodeList or an HTMLElement is passed and
handles the tooltip actions accordingly. If a jQuery object is passed,
the old behavior is kept and a deprecation is logged in the browser's
console.

Review

  • Code review CR +2 Done
    • Benni Mack +2
    • Martin Kutschker +1
  • Verified V +2 Done
    • Benni Mack +2
    • Martin Kutschker +1
    • TYPO3com +1 CI
    • core-ci +1 CI

Issues 1

Files 5

Review log 1222

  1. Andreas Kienast uploaded patch set 1 02/13/21, 16:08

  2. TYPO3com voted on patch set 1 V +1 02/13/21, 16:16 Completed build in 07m 37s on Sat, 13 Feb, 04:16 PM Test Summary: 32611 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-9516

  3. core-ci voted on patch set 1 V +1 02/13/21, 16:19 Core CI is happy: https://core.b13.com/typo3-core/typo3.cms/-/pipelines/704

  4. Andreas Kienast uploaded patch set 2 02/13/21, 16:19

  5. Andreas Kienast uploaded patch set 3 02/13/21, 16:22

  6. TYPO3com voted on patch set 2 V +1 02/13/21, 16:28 Completed build in 08m 21s on Sat, 13 Feb, 04:28 PM Test Summary: 32611 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-9517

  7. TYPO3com voted on patch set 3 V +1 02/13/21, 16:30 Completed build in 08m 39s on Sat, 13 Feb, 04:30 PM Test Summary: 32611 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-9518

  8. core-ci voted on patch set 2 V +1 02/13/21, 16:31 Core CI is happy: https://core.b13.com/typo3-core/typo3.cms/-/pipelines/705

  9. core-ci voted on patch set 3 V +1 02/13/21, 16:37 Core CI is happy: https://core.b13.com/typo3-core/typo3.cms/-/pipelines/706

  10. Benjamin Franzke commented on patch set 3 02/13/21, 21:23

    Tooltip.ts:59

    Could we avoid importing jQuery at all, when we do: if (!(elements instanceof NodeList || elements instanceof HTMLElement)) { and then invoke .tooltip() on the passed jQuery object: (elements as JQuery).tooltip(…)
  11. Andreas Kienast commented on patch set 3 02/14/21, 07:38

    Tooltip.ts:59 Reply

    Ack
  12. Andreas Kienast uploaded patch set 4 02/14/21, 07:39

  13. TYPO3com voted on patch set 4 V +1 02/14/21, 07:47 Completed build in 07m 58s on Sun, 14 Feb, 07:47 AM Test Summary: 32611 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-9521

  14. core-ci voted on patch set 4 V +1 02/14/21, 07:50 Core CI is happy: https://core.b13.com/typo3-core/typo3.cms/-/pipelines/711

  15. Martin Kutschker commented on patch set 4 V +1 CR +1 02/14/21, 16:53

    Tooltip.ts:36

    With "options: Partial<BootstrapTooltip.Options> = {}" you can remove the classic initialization code.

    Tooltip.ts:40

    element is const within the loop.

    Tooltip.ts:67

    node is const within the loop.

    Tooltip.ts:94

    node is const within the loop.
  16. Andreas Kienast uploaded patch set 5 02/14/21, 18:35

  17. Andreas Kienast commented on patch set 5 02/14/21, 18:39

    Tooltip.ts:36 Reply

    Done

    Tooltip.ts:40 Reply

    Done

    Tooltip.ts:67 Reply

    Done

    Tooltip.ts:94 Reply

    Done
  18. TYPO3com voted on patch set 5 V +1 02/14/21, 18:42 Completed build in 07m 21s on Sun, 14 Feb, 06:42 PM Test Summary: 32611 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-9525

  19. core-ci voted on patch set 5 V +1 02/14/21, 18:45 Core CI is happy: https://core.b13.com/typo3-core/typo3.cms/-/pipelines/714

  20. Martin Kutschker voted on patch set 5 V +1 CR +1 02/14/21, 21:17

  21. Benni Mack voted on patch set 5 V +2 CR +2 02/15/21, 07:49

  22. Benni Mack merged patch set 6 02/15/21, 07:50