Get rid of jQuery in displace event

Created on 13 May 2024, 6 months ago
Updated 13 September 2024, 2 months ago

Problem/Motivation

This is exact copy of https://www.drupal.org/project/drupal/issues/3390549 📌 Get rid of jQuery in dialog events. Needs review but for `drupalViewportOffsetChange` event.
And utilises same deprecation logic. It also required in jquery dialog replace so i marked it as beta target.

Remaining tasks

Change record Draft: https://www.drupal.org/node/3449016

Testing instructions

In fact we can test any module which uses Drupal.displace. Also modules which uses jQuery event and not vanilla js will get Deprecation message.

1. Test modules which use this Drupal.displace event `drupalViewportOffsetChange`. (Navigation, Layout Builder, Announcements, Workspaces etc)
2. In this MR also fixed Ckeditor popup and Toolbar jQuery events.

Feature request
Status

RTBC

Version

11.0 🔥

Component
Javascript 

Last updated 2 days ago

Created by

🇷🇸Serbia finnsky

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @finnsky
  • Merge request !8052#3446855 "Deprecate displace event" → (Open) created by finnsky
  • Status changed to Needs review 6 months ago
  • Pipeline finished with Failed
    6 months ago
    #171693
  • Pipeline finished with Success
    6 months ago
    #171699
  • 🇷🇸Serbia finnsky

    finnsky changed the visibility of the branch 3446855-get-rid-of to hidden.

  • Pipeline finished with Success
    6 months ago
    #171709
  • Pipeline finished with Canceled
    6 months ago
    Total: 36s
    #178987
  • Pipeline finished with Canceled
    6 months ago
    Total: 59s
    #178988
  • Pipeline finished with Success
    6 months ago
    Total: 520s
    #178990
  • Status changed to Needs work 6 months ago
  • The Needs Review Queue Bot tested this issue. It no longer applies to Drupal core. Therefore, this issue status is now "Needs work".

    This does not mean that the patch necessarily needs to be re-rolled or the MR rebased. Read the Issue Summary, the issue tags and the latest discussion here to determine what needs to be done.

    Consult the Drupal Contributor Guide to find step-by-step guides for working with issues.

  • Status changed to Needs review 6 months ago
  • Pipeline finished with Success
    6 months ago
    Total: 569s
    #181384
  • Pipeline finished with Success
    6 months ago
    Total: 513s
    #191381
  • Status changed to Needs work 3 months ago
  • 🇺🇸United States smustgrave

    Wasn't entire sure how to test this one.

    I applied the MR and tested on a view page which has dialog and didn't see any issue
    If any other recommendation can try that.

    Did leave a comment on the MR for deprecation version.

  • First commit to issue fork.
  • Pipeline finished with Canceled
    3 months ago
    Total: 94s
    #267118
  • Pipeline finished with Success
    3 months ago
    Total: 467s
    #267122
  • Status changed to Needs review 3 months ago
  • 🇮🇳India shalini_jha

    I have addressed the mentioned feedback. While updating, I also noticed that the dialog-deprecation.js file had the same issue in line state 12.0.0, so I updated that as well. Please review.

  • Status changed to Needs work 3 months ago
  • Pipeline finished with Canceled
    3 months ago
    Total: 256s
    #268483
  • Status changed to Needs review 3 months ago
  • 🇷🇸Serbia finnsky

    RE: #11

    For test you may revert this MR changes in toolbar.js locally. and when you will open close toolbar on desktop it will trigger deprecation messages.
    Also you need to set drupalSettings.suppressDeprecationErrors to true. Easiest way to do it
    core/misc/drupal.js:564 in Drupal.deprecationError remove this condition

    `drupalSettings.suppressDeprecationErrors === false &&`

  • Pipeline finished with Failed
    3 months ago
    Total: 639s
    #268486
  • Status changed to Needs work 3 months ago
  • 🇺🇸United States smustgrave

    Seems to have a few test failures

    Thanks for taking care of that version update for the deprecation message.

  • Pipeline finished with Failed
    2 months ago
    #281844
  • Status changed to Needs review 2 months ago
  • 🇷🇸Serbia finnsky

    We have broken test in navigation module. If 2 or more data-once attributes presented. Fixed here.

  • Pipeline finished with Success
    2 months ago
    Total: 646s
    #281887
  • Status changed to RTBC 2 months ago
  • 🇺🇸United States smustgrave

    Believe feedback has been addressed. Tested same way as did in #11

  • 🇳🇿New Zealand quietone

    @finnsky, Thanks for the continued work on javaScript,

    The first thing I did was change the format of URL is issue summary so I can read the issue title. There is no proposed resolution to explain the scope of this change. Is it everywhere in core or not? But I am more concerned about the testing. There are steps for testing but they are different than the steps #15. And neither of those are what was done to test this issue. Because of that I am setting to NW for manual testing and updated the remaining steps.

    Also, I read the change record and changed some formatting. Why is it ticked that this impacts "Site builders, administrators, editors"?

  • 🇳🇿New Zealand quietone

    This is a child of a critical task.

Production build 0.71.5 2024