Parcourir la source

reverted back to the left border style

luna215 il y a 6 ans
Parent
commit
0d507c3039
1 fichiers modifiés avec 1 ajouts et 4 suppressions
  1. 1 4
      src/mol-plugin/ui/controls/parameters.tsx

+ 1 - 4
src/mol-plugin/ui/controls/parameters.tsx

@@ -250,10 +250,7 @@ export class ColorControl extends SimpleParam<PD.Color> {
     }
 
     renderControl() {
-        let rgb: any[] = Color.toStyle(this.props.value).replace('rgb(', '').split(', ');
-        rgb = rgb.map(c => parseInt(c)); 
-        let secondArg = `rgb(${rgb[0]}, ${rgb[1]}, ${rgb[2]}, 0.0)`;
-        return <select value={this.props.value} onChange={this.onChange} style={{background: `linear-gradient(90deg, ${Color.toStyle(this.props.value)}, ${secondArg})`}}>
+        return <select value={this.props.value} onChange={this.onChange} style={{ borderLeft: `16px solid ${Color.toStyle(this.props.value)}` }}>
             {ColorValueOption(this.props.value)}
             {ColorOptions()}
         </select>;