Browse Source

StateTree: always show remove all button

David Sehnal 5 years ago
parent
commit
44664917ff
1 changed files with 2 additions and 2 deletions
  1. 2 2
      src/mol-plugin-ui/left-panel.tsx

+ 2 - 2
src/mol-plugin-ui/left-panel.tsx

@@ -167,7 +167,7 @@ export class RemoveAllButton extends PluginUIComponent<{ }> {
 
     render() {
         const count = this.plugin.state.data.tree.children.get(StateTransform.RootRef).size;
-        if (count < 2) return null;
-        return <IconButton icon='remove' onClick={this.remove} title={'Remove All'} style={{ display: 'inline-block' }} />;
+        if (count === 0) return null;
+        return <IconButton icon='remove' onClick={this.remove} title={'Remove All'} style={{ display: 'inline-block' }} small />;
     }
 }