From a997d90ab0d994c1c4bcd8a1f3b98d7e2bb6c44a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maur=C3=ADcio=20Meneghini=20Fauth?= Date: Mon, 3 Apr 2023 17:07:56 -0300 Subject: [PATCH] Fix some JSDoc types MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [ci skip] Signed-off-by: MaurĂ­cio Meneghini Fauth --- js/src/database/operations.ts | 2 +- js/src/designer/database.ts | 20 +++++++++---------- js/src/jqplot/plugins/jqplot.byteFormatter.ts | 2 +- js/src/modules/config.ts | 2 +- js/src/setup/scripts.ts | 2 +- js/src/sql.ts | 2 +- js/src/table/operations.ts | 6 +++--- js/src/table/zoom_plot_jqplot.ts | 4 ++-- 8 files changed, 20 insertions(+), 20 deletions(-) diff --git a/js/src/database/operations.ts b/js/src/database/operations.ts index 103810b7cf..6e99c12394 100644 --- a/js/src/database/operations.ts +++ b/js/src/database/operations.ts @@ -153,7 +153,7 @@ AJAX.registerOnload('database/operations.js', function () { event.preventDefault(); var $link = $(this); /** - * @var {String} question String containing the question to be asked for confirmation + * @var {string} question String containing the question to be asked for confirmation */ var question = window.Messages.strDropDatabaseStrongWarning + ' '; question += window.sprintf( diff --git a/js/src/designer/database.ts b/js/src/designer/database.ts index f9ae456ff0..fb51a516bf 100644 --- a/js/src/designer/database.ts +++ b/js/src/designer/database.ts @@ -22,7 +22,7 @@ var DesignerOfflineDB = (function () { var datastore = null; /** - * @param {String} table + * @param {string} table * @return {IDBTransaction} */ designerDB.getTransaction = function (table) { @@ -30,7 +30,7 @@ var DesignerOfflineDB = (function () { }; /** - * @param {String} table + * @param {string} table * @return {IDBObjectStore} */ designerDB.getObjectStore = function (table) { @@ -41,7 +41,7 @@ var DesignerOfflineDB = (function () { /** * @param {IDBTransaction} transaction - * @param {String} table + * @param {string} table * @return {IDBObjectStore} */ designerDB.getCursorRequest = function (transaction, table) { @@ -90,8 +90,8 @@ var DesignerOfflineDB = (function () { }; /** - * @param {String} table - * @param {String} id + * @param {string} table + * @param {string} id * @param {Function} callback */ designerDB.loadObject = function (table, id, callback): void { @@ -111,7 +111,7 @@ var DesignerOfflineDB = (function () { }; /** - * @param {String} table + * @param {string} table * @param {Function} callback */ designerDB.loadAllObjects = function (table, callback): void { @@ -141,7 +141,7 @@ var DesignerOfflineDB = (function () { }; /** - * @param {String} table + * @param {string} table * @param {Function} callback */ designerDB.loadFirstObject = function (table, callback): void { @@ -170,7 +170,7 @@ var DesignerOfflineDB = (function () { }; /** - * @param {String} table + * @param {string} table * @param {Object} obj * @param {Function} callback */ @@ -193,8 +193,8 @@ var DesignerOfflineDB = (function () { }; /** - * @param {String} table - * @param {String} id + * @param {string} table + * @param {string} id * @param {Function} callback */ designerDB.deleteObject = function (table, id, callback): void { diff --git a/js/src/jqplot/plugins/jqplot.byteFormatter.ts b/js/src/jqplot/plugins/jqplot.byteFormatter.ts index 13280c6712..d7359f7176 100644 --- a/js/src/jqplot/plugins/jqplot.byteFormatter.ts +++ b/js/src/jqplot/plugins/jqplot.byteFormatter.ts @@ -37,7 +37,7 @@ import $ from 'jquery'; * * @param index * - * @return {String} + * @return {string} */ $.jqplot.byteFormatter = function (index) { var i = index || 0; diff --git a/js/src/modules/config.ts b/js/src/modules/config.ts index 7d19e019a1..d80f6e25eb 100644 --- a/js/src/modules/config.ts +++ b/js/src/modules/config.ts @@ -310,7 +310,7 @@ function registerFieldValidator (id, type, onKeyUp, params) { /** * Returns validation functions associated with form field * - * @param {String} fieldId form field id + * @param {string} fieldId form field id * @param {boolean} onKeyUpOnly see registerFieldValidator * * @return {any[]} of [function, parameters to be passed to function] diff --git a/js/src/setup/scripts.ts b/js/src/setup/scripts.ts index c855548c7b..f45a5a7e15 100644 --- a/js/src/setup/scripts.ts +++ b/js/src/setup/scripts.ts @@ -64,7 +64,7 @@ $(function () { * Calls server-side validation procedures * * @param {Element} parent input field in
or
- * @param {String} id validator id + * @param {string} id validator id * @param {object} values values hash {element1_id: value, ...} * * @return {boolean|void} diff --git a/js/src/sql.ts b/js/src/sql.ts index d654db99cd..ab4a44f1d6 100644 --- a/js/src/sql.ts +++ b/js/src/sql.ts @@ -1193,7 +1193,7 @@ function browseForeignDialog ($thisA) { /** * Get the auto saved query key - * @return {String} + * @return {string} */ function getAutoSavedKey () { var db = $('input[name="db"]').val(); diff --git a/js/src/table/operations.ts b/js/src/table/operations.ts index 0312c87a02..70425c2cb1 100644 --- a/js/src/table/operations.ts +++ b/js/src/table/operations.ts @@ -32,7 +32,7 @@ AJAX.registerTeardown('table/operations.js', function () { */ var confirmAndPost = function (linkObject, action): void { /** - * @var {String} question String containing the question to be asked for confirmation + * @var {string} question String containing the question to be asked for confirmation */ var question = ''; if (action === 'TRUNCATE') { @@ -275,7 +275,7 @@ AJAX.registerOnload('table/operations.js', function () { event.preventDefault(); var $link = $(this); /** - * @var {String} question String containing the question to be asked for confirmation + * @var {string} question String containing the question to be asked for confirmation */ var question = window.Messages.strDropTableStrongWarning + ' '; question += window.sprintf(window.Messages.strDoYouReally, $link[0].getAttribute('data-query')); @@ -307,7 +307,7 @@ AJAX.registerOnload('table/operations.js', function () { event.preventDefault(); var $link = $(this); /** - * @var {String} question String containing the question to be asked for confirmation + * @var {string} question String containing the question to be asked for confirmation */ var question = window.Messages.strDropTableStrongWarning + ' '; question += window.sprintf( diff --git a/js/src/table/zoom_plot_jqplot.ts b/js/src/table/zoom_plot_jqplot.ts index 588814dd2f..e8550c8045 100644 --- a/js/src/table/zoom_plot_jqplot.ts +++ b/js/src/table/zoom_plot_jqplot.ts @@ -28,7 +28,7 @@ function displayHelp () { /** * Extend the array object for max function * @param {number[]} array - * @return {int} + * @return {number} **/ Array.max = function (array) { return Math.max.apply(Math, array); @@ -37,7 +37,7 @@ Array.max = function (array) { /** * Extend the array object for min function * @param {number[]} array - * @return {int} + * @return {number} **/ Array.min = function (array) { return Math.min.apply(Math, array);