addCheckboxAction = (
    name,
    callback,
    folderName,
    defaultValue,
    tooltip,
  ) => {
    actions[name] = !!defaultValue;
    let folder = actionsFolder;
    if (folderName) {
      if (actionSubFolders[folderName]) {
        folder = actionSubFolders[folderName];
      } else {
        folder = actionsFolder.addFolder(folderName);
        folder.open();
        actionSubFolders[folderName] = folder;
      }
    }
    const controller = folder.add(actions, name);
    tooltip && setTooltip(controller, tooltip);
    name && controller.name(name);
    controller.listen().onFinishChange((value) => {
      callback(workspace, value);
    });

    return controller;
  }
Add a custom checkbox action to the list of playground actions.
@param {string} name The action label.
@param {function(!Blockly.Workspace,boolean):void} callback The callback to
    call when the action is clicked.
@param {string=} folderName Optional folder to place the action under.
@param {boolean=} defaultValue Default value.
@param {string=} tooltip Optional tooltip to set.
@returns {dat.GUIController} The GUI controller.