"use strict";(globalThis.webpackChunk_jbrowse_web=globalThis.webpackChunk_jbrowse_web||[]).push([[7025],{17025:(e,t,a)=>{a.r(t),a.d(t,{default:()=>m});var o=a(66204),n=a(80846),r=a(29520),l=a(80013),c=a(46338),s=a(62301),u=a(7146),i=a(35421);const m=(0,n.observer)((function(e){const{model:t,handleClose:a}=e,[n,m]=(0,o.useState)(""),d=n.match(/^[A-Za-z][A-Za-z0-9]$/);return o.createElement(i.Dialog,{open:!0,onClose:a,title:"Sort by tag"},o.createElement(r.Z,null,o.createElement(l.Z,null,"Set the tag to sort by"),o.createElement(l.Z,{color:"textSecondary"},"Examples: HP for haplotype, RG for read group, etc."),o.createElement(c.Z,{value:n,onChange:e=>m(e.target.value),placeholder:"Enter tag name",inputProps:{maxLength:2,"data-testid":"sort-tag-name-input"},error:2===n.length&&!d,helperText:2!==n.length||d?"":"Not a valid tag",autoComplete:"off","data-testid":"sort-tag-name"}),o.createElement(s.Z,null,o.createElement(u.Z,{variant:"contained",color:"primary",type:"submit",autoFocus:!0,onClick:()=>{t.setSortedBy("tag",n),a()}},"Submit"),o.createElement(u.Z,{variant:"contained",color:"secondary",onClick:()=>a()},"Cancel"))))}))}}]);
//# sourceMappingURL=7025.b43f3087.chunk.js.map