Attach (recommended) or Link to PDF file [here:] Can't see how to attach a pdf here, but it is simple to create. Add a form object textbox to a pdf and make sure the option for "Multiline" is true.

Steps to reproduce the problem:
1.  Open a document with a Textbox that is set to Multiline.
2. Attempt to hit the Enter key to go to a new line.

What is the expected behavior? The cursor goes to a new line.

What went wrong? It does not go to a new line.

Link to a viewer: It can be reproduced on mozilla.github.io/pdf.js

I corrected the issue by altering the pdf.js file like this
element.addEventListener("keydown", event => { 
[...]
--} else if (event.key === "Enter") {
++ } else if (event.key === "Enter" && !this.data.multiLine) {

Our initial testing is coming through clean, and hopefully something like this code can be committed to the project in the future.

const data = this.data;
    const { width, height } = getRectDims(data.rect);
    const svg = this.svgFactory.create(
      width,
      height,
       true
    );
    
    
    const line = this.svgFactory.createElement("svg:line");
    line.setAttribute("x1", data.rect[2] - data.lineCoordinates[0]);
    line.setAttribute("y1", data.rect[3] - data.lineCoordinates[1]);
    line.setAttribute("x2", data.rect[2] - data.lineCoordinates[2]);
    line.setAttribute("y2", data.rect[3] - data.lineCoordinates[3]);
    
    
    line.setAttribute("stroke-width", data.borderStyle.width || 1);
    line.setAttribute("stroke", "transparent");
    line.setAttribute("fill", "transparent");
    svg.append(line);
    this.container.append(svg);
    
    
    this._createPopup(line, data);
    return this.container;
  }
}
class SquareAnnotationElement extends AnnotationElement {