From 10d5a5504069dad7d9acc3524f2e46aba81ec033 Mon Sep 17 00:00:00 2001 From: Don McCurdy Date: Sun, 11 Mar 2018 15:23:23 -0700 Subject: [PATCH] Add docs for 'hideable' option. --- API.md | 7 ++++--- src/dat/gui/GUI.js | 7 ++++--- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/API.md b/API.md index 01ca8f0..096e60a 100644 --- a/API.md +++ b/API.md @@ -60,10 +60,11 @@ manipulate variables and fire functions on the fly. | [params] | Object | | | | [params.name] | String | | The name of this GUI. | | [params.load] | Object | | JSON object representing the saved state of this GUI. | -| [params.auto] | Boolean | true | | | [params.parent] | dat.gui.GUI | | The GUI I'm nested in. | -| [params.closed] | Boolean | | If true, starts closed | -| [params.closeOnTop] | Boolean | | If true, close/open button shows on top of the GUI | +| [params.autoPlace] | Boolean | true | | +| [params.hideable] | Boolean | true | If true, GUI is closed by the h keypress. | +| [params.closed] | Boolean | false | If true, starts closed | +| [params.closeOnTop] | Boolean | false | If true, close/open button shows on top of the GUI | **Example** ```js diff --git a/src/dat/gui/GUI.js b/src/dat/gui/GUI.js index b33b602..37aaf00 100644 --- a/src/dat/gui/GUI.js +++ b/src/dat/gui/GUI.js @@ -80,10 +80,11 @@ const hideableGuis = []; * @param {String} [params.name] The name of this GUI. * @param {Object} [params.load] JSON object representing the saved state of * this GUI. - * @param {Boolean} [params.auto=true] * @param {dat.gui.GUI} [params.parent] The GUI I'm nested in. - * @param {Boolean} [params.closed] If true, starts closed - * @param {Boolean} [params.closeOnTop] If true, close/open button shows on top of the GUI + * @param {Boolean} [params.autoPlace=true] + * @param {Boolean} [params.hideable=true] If true, GUI is shown/hidden by h keypress. + * @param {Boolean} [params.closed=false] If true, starts closed + * @param {Boolean} [params.closeOnTop=false] If true, close/open button shows on top of the GUI */ const GUI = function(pars) { const _this = this;