Change the type of the container property, in the TextLayerRenderParameters typedef (issue 14716)

Given that the textLayer-code has been using a `DocumentFragment` ever since PR 3356 (back in 2013), simply updating the type of the `container` property should be fine.
This patch also tries to, ever so slightly, improve the grammar of a couple of other properties in the typedef.
This commit is contained in:
Jonas Jenwald 2022-03-24 22:33:11 +01:00
parent db4f3adc5e
commit 7f0589c74a

View File

@ -27,15 +27,16 @@ import {
* render (the object is returned by the page's `getTextContent` method). * render (the object is returned by the page's `getTextContent` method).
* @property {ReadableStream} [textContentStream] - Text content stream to * @property {ReadableStream} [textContentStream] - Text content stream to
* render (the stream is returned by the page's `streamTextContent` method). * render (the stream is returned by the page's `streamTextContent` method).
* @property {HTMLElement} container - HTML element that will contain text runs. * @property {DocumentFragment} container - The DOM node that will contain the
* text runs.
* @property {import("./display_utils").PageViewport} viewport - The target * @property {import("./display_utils").PageViewport} viewport - The target
* viewport to properly layout the text runs. * viewport to properly layout the text runs.
* @property {Array<HTMLElement>} [textDivs] - HTML elements that are correspond * @property {Array<HTMLElement>} [textDivs] - HTML elements that correspond to
* to the text items of the textContent input. This is output and shall be * the text items of the textContent input.
* initially be set to empty array. * This is output and shall initially be set to an empty array.
* @property {Array<string>} [textContentItemsStr] - Strings that correspond to * @property {Array<string>} [textContentItemsStr] - Strings that correspond to
* the `str` property of the text items of textContent input. This is output * the `str` property of the text items of the textContent input.
* and shall be initially be set to empty array. * This is output and shall initially be set to an empty array.
* @property {number} [timeout] - Delay in milliseconds before rendering of the * @property {number} [timeout] - Delay in milliseconds before rendering of the
* text runs occurs. * text runs occurs.
* @property {boolean} [enhanceTextSelection] - Whether to turn on the text * @property {boolean} [enhanceTextSelection] - Whether to turn on the text