Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-25689

Share the move up and move down reordering logic of the class editor with Live Data

    XMLWordPrintable

Details

    • Improvement
    • Resolution: Unresolved
    • Major
    • None
    • 18.9.0
    • Edit, Live Data
    • None
    • Unknown

    Description

      XWIKI-24755 adds move up and move down buttons to the class editor, so that XClass properties can be reordered without dragging. They are implemented by the xwiki-reorder-controls widget, a jQuery module served from the skin.

      Live Data has the same need, for its column headers and for the column and sort panels, but it cannot use that widget: it is written in Vue, bundled from xwiki-platform-node, and it can neither load skin files nor rely on jQuery DOM moves. Without a shared implementation, Live Data would have to duplicate the logic, and the two editors would drift apart.

      Proposal

      • Extract the framework-agnostic parts into a small xwiki-platform-node package:
        • the move and boundary logic;
        • the arrow key mapping;
        • the live region announcing the new position to screen readers.
      • Turn the current jQuery code into the class editor adapter of that package.
      • Add a Vue adapter for Live Data later on.

      Until then, the widget of XWIKI-24755 stays internal and is not advertised as a reusable API.

      This was raised in the review of https://github.com/xwiki/xwiki-platform/pull/6267.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              Lucas C Charpentier Lucas
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated: