Fix missing return docs
This commit is contained in:
parent
df4ad646b4
commit
af0736851d
|
@ -94,7 +94,7 @@ class DOM {
|
|||
* @param {string} [options.id] ID to set for the element.
|
||||
* @param {HTMLElement} [options.target] Target element to automatically append to.
|
||||
* @param {HTMLElement} [child] Child node to add.
|
||||
* @returns HTMLElement
|
||||
* @returns {HTMLElement} The created HTML element.
|
||||
*/
|
||||
createElement(tag, options = {}, child = null) {
|
||||
return DOMManager.createElement(tag, options, child);
|
||||
|
|
|
@ -120,6 +120,7 @@ function alert(title, content) {
|
|||
* @param {string} [options.cancelText=Cancel] Text for the cancel button.
|
||||
* @param {callable} [options.onConfirm=NOOP] Callback to occur when clicking the submit button.
|
||||
* @param {callable} [options.onCancel=NOOP] Callback to occur when clicking the cancel button.
|
||||
* @returns {string} The key used for this modal.
|
||||
* @memberof BdApi
|
||||
*/
|
||||
function showConfirmationModal(title, content, options = {}) {
|
||||
|
|
|
@ -49,6 +49,7 @@ const UI = {
|
|||
* @param {string} [options.cancelText=Cancel] Text for the cancel button.
|
||||
* @param {callable} [options.onConfirm=NOOP] Callback to occur when clicking the submit button.
|
||||
* @param {callable} [options.onCancel=NOOP] Callback to occur when clicking the cancel button.
|
||||
* @returns {string} The key used for this modal.
|
||||
*/
|
||||
showConfirmationModal(title, content, options = {}) {
|
||||
return Modals.showConfirmationModal(title, content, options);
|
||||
|
@ -76,7 +77,7 @@ const UI = {
|
|||
* @param {string} [options.type="info" | "error" | "warning" | "success"] Type for the notice. Will affect the color.
|
||||
* @param {Array<{label: string, onClick: function}>} [options.buttons] Buttons that should be added next to the notice text.
|
||||
* @param {number} [options.timeout=10000] Timeout until the notice is closed. Will not fire when set to `0`.
|
||||
* @returns {function}
|
||||
* @returns {function} A callback for closing the notice. Passing `true` as first parameter closes immediately without transitioning out.
|
||||
*/
|
||||
showNotice(content, options = {}) {
|
||||
return Notices.show(content, options);
|
||||
|
|
|
@ -51,6 +51,7 @@ const Utils = {
|
|||
/**
|
||||
* Takes a string of HTML and escapes it using the browser's own escaping mechanism.
|
||||
* @param {String} html - HTML to be escaped.
|
||||
* @return {string} Escaped HTML string.
|
||||
*/
|
||||
escapeHTML(html) {
|
||||
return Utilities.escapeHTML(html);
|
||||
|
|
Loading…
Reference in New Issue