refactor: omit redundant null prop type for HTMLElements

This commit is contained in:
metonym 2022-01-12 13:19:29 -10:00
commit 3989768842
5 changed files with 6 additions and 6 deletions

View file

@ -90,7 +90,7 @@
/**
* Obtain a reference to the list HTML element
* @type {null | HTMLDivElement}
* @type {HTMLDivElement}
*/
export let listRef = null;

View file

@ -6,7 +6,7 @@
/**
* Specify an element or list of elements to trigger the context menu.
* If no element is specified, the context menu applies to the entire window
* @type {null | HTMLElement | HTMLElement[]}
* @type {HTMLElement | HTMLElement[]}
*/
export let target = null;

View file

@ -21,7 +21,7 @@
/**
* Obtain a reference to the input HTML element
* @type {null | HTMLInputElement}
* @type {HTMLInputElement}
*/
export let ref = null;

View file

@ -136,13 +136,13 @@
/**
* Obtain a reference to the field box element
* @type {null | HTMLDivElement}
* @type {HTMLDivElement}
*/
export let fieldRef = null;
/**
* Obtain a reference to the selection element
* @type {null | HTMLDivElement}
* @type {HTMLDivElement}
*/
export let selectionRef = null;

View file

@ -22,7 +22,7 @@
/**
* Finds the nearest parent tree node
* @param {HTMLElement} node
* @returns {null | HTMLElement}
* @returns {HTMLElement}
*/
function findParentTreeNode(node) {
if (node.classList.contains("bx--tree-parent-node")) return node;