"use strict";(self.webpackChunk_jbrowse_web=self.webpackChunk_jbrowse_web||[]).push([[6082],{56082:function(e,o,n){n.r(o),n.d(o,{default:function(){return Z}});var r=n(96234),t=n(30969),c=n(22714),l=n(83483),s=n(64501),i=n(32343),a=n(93138),u=n(93717),d=n(18189),h=n(80975),j=n(53033),v=n(28599),g=n(14008),x=n(78017),C=n(37574),b=(0,c.Z)((function(e){return{closeButton:{position:"absolute",right:e.spacing(1),top:e.spacing(1),color:e.palette.grey[500]}}}));function f(e){if(e instanceof Object){var o=e,n=o.r,r=o.g,t=o.b;return"rgb(".concat(n,",").concat(r,",").concat(t,")")}return e}function Z(e){var o=e.model,n=e.handleClose,c=b(),Z=(0,t.useState)(!1),p=(0,r.Z)(Z,2),k=p[0],w=p[1];return(0,C.jsxs)(l.Z,{open:!0,onClose:n,children:[(0,C.jsxs)(s.Z,{children:["Select either an overall color, or the positive/negative colors. Note that density renderers only work properly with positive/negative colors",(0,C.jsx)(i.Z,{"aria-label":"close",className:c.closeButton,onClick:n,children:(0,C.jsx)(g.Z,{})})]}),(0,C.jsxs)(a.Z,{children:[(0,C.jsx)(u.Z,{checked:!k,onClick:function(){return w(!1)},control:(0,C.jsx)(d.Z,{}),label:"Overall color"}),(0,C.jsx)(u.Z,{checked:k,onClick:function(){return w(!0)},control:(0,C.jsx)(d.Z,{}),label:"Positive/negative color"}),k?(0,C.jsxs)(C.Fragment,{children:[(0,C.jsx)(h.Z,{children:"Positive color"}),(0,C.jsx)(x.Ie,{onChange:function(e){o.setPosColor(f(e.rgb)),o.setColor(void 0)}}),(0,C.jsx)(h.Z,{children:"Negative color"}),(0,C.jsx)(x.Ie,{onChange:function(e){o.setNegColor(f(e.rgb)),o.setColor(void 0)}})]}):(0,C.jsxs)(C.Fragment,{children:[(0,C.jsx)(h.Z,{children:"Overall color"}),(0,C.jsx)(x.Ie,{onChange:function(e){o.setColor(f(e.rgb))}})]})]}),(0,C.jsxs)(j.Z,{children:[(0,C.jsx)(v.Z,{onClick:function(){o.setPosColor(void 0),o.setNegColor(void 0),o.setColor(void 0)},color:"secondary",variant:"contained",children:"Restore default"}),(0,C.jsx)(v.Z,{variant:"contained",color:"primary",type:"submit",onClick:function(){n()},children:"Submit"})]})]})}}}]);
//# sourceMappingURL=6082.3de867c9.chunk.js.map