constrained-editor-plugin icon indicating copy to clipboard operation
constrained-editor-plugin copied to clipboard

Hover message in toggleHighlightOfEditableAreas

Open cdietrich opened this issue 10 months ago • 1 comments

Hi, we current produce something like

{
    "range": {
        "startLineNumber": 4,
        "startColumn": 1,
        "endLineNumber": 9,
        "endColumn": 1
    },
    "options": {
        "className": "editableArea--multi-line"
    },
    "hoverMessage": "xxxxxxx"
}

whilst the api seems to be (meanwhile?!?)

  //     [
  //       {
  //         range: {
  //           startLineNumber: 3,
  //           startColumn: 0,
  //           endLineNumber: 10,
  //           endColumn: 0,
  //         },
  //         options: {
  //           className: "myContentClass",
  //           hoverMessage: {
  //             value: "This is a hover message",
  //           },
  //         },
  //       },
  //     ]

cdietrich avatar Feb 13 '25 20:02 cdietrich

possible fix:

if (restriction.label) {
          decoration.options.hoverMessage = {value: restriction.label};
        }

cdietrich avatar Feb 13 '25 20:02 cdietrich