JSDoc complete type check

This commit is contained in:
barsdeveloper
2022-10-09 11:43:28 +02:00
parent 91e1e0885e
commit cdc5e5b91b
68 changed files with 1603 additions and 648 deletions

View File

@@ -4,7 +4,7 @@ import MouseMoveDraggable from "../input/mouse/MouseMoveDraggable"
/** @typedef {import("../element/WindowElement").default} WindowElement */
/** @extends {SelectableDraggableTemplate<WindowElement>} */
/** @extends {IDraggableTemplate<WindowElement>} */
export default class WindowTemplate extends IDraggableTemplate {
static windowName = html`Window`
@@ -12,7 +12,7 @@ export default class WindowTemplate extends IDraggableTemplate {
toggleAdvancedDisplayHandler
getDraggableElement() {
return this.element.querySelector(".ueb-window-top")
return /** @type {WindowElement} */(this.element.querySelector(".ueb-window-top"))
}
createDraggableObject() {
@@ -35,7 +35,9 @@ export default class WindowTemplate extends IDraggableTemplate {
return html`
<div class="ueb-window">
<div class="ueb-window-top">
<div class="ueb-window-name">${this.constructor.windowName}</div>
<div class="ueb-window-name ueb-ellipsis-nowrap-text">${
// @ts-expect-error
this.constructor.windowName}</div>
<div class="ueb-window-close">
<svg viewBox="0 0 32 32" xmlns="http://www.w3.org/2000/svg">
<line x1="2" y1="2" x2="30" y2="30" stroke="currentColor" stroke-width="4" />