function populateToolboxOption(
  folder,
  guiState,
  toolboxes,
  defaultToolboxName,
  onChange,
) {
  setTooltip(
    folder
      .add(guiState, 'toolboxName')
      .options(Object.keys(toolboxes))
      .name('toolbox')
      .onChange((value) => {
        guiState.toolboxName = value;
        onChange('toolbox', toolboxes[value]);
      }),
    'The toolbox used by Blockly.',
  );
  if (guiState.toolboxName !== defaultToolboxName) {
    openFolderIfOptionSelected(folder, guiState, guiState.options, ['toolbox']);
  }
}
Populate the toolbox option.
@param {dat.GUI} folder The dat.GUI folder.
@param {Object} guiState The GUI state.
@param {Object<string,Blockly.utils.toolbox.ToolboxDefinition>} toolboxes The
    registered toolboxes.
@param {string} defaultToolboxName The default toolbox name.
@param {function(string, *):void} onChange On Change method.