From 36df5ce77d4e1bc55b00db3a5637b244c3c8eb2d Mon Sep 17 00:00:00 2001 From: "Joshua A. Horton" Date: Thu, 25 Jan 2024 15:23:37 +0700 Subject: [PATCH] docs(web): on SuggestionBanner.options.length --- web/src/engine/osk/src/banner/suggestionBanner.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/web/src/engine/osk/src/banner/suggestionBanner.ts b/web/src/engine/osk/src/banner/suggestionBanner.ts index 916c5a542b..6465c5b7ff 100644 --- a/web/src/engine/osk/src/banner/suggestionBanner.ts +++ b/web/src/engine/osk/src/banner/suggestionBanner.ts @@ -724,6 +724,10 @@ export class SuggestionBanner extends Banner { let displayCount = Math.min(this.currentSuggestions.length, 8); for(let i=0; i < displayCount; i++) { + // Note: options is an array of pre-built suggestion-hosting elements, with + // fixed SUGGESTIONS_LIMIT length - not a length that dynamically changes to + // match the number of suggestions available. Those without a suggestion + // are hidden, but preserved. const opt = this.options[i]; opt.minWidth = 0; // remove any previously-applied padding totalWidth += opt.collapsedWidth;