"use strict";(self.webpackChunk_jbrowse_web=self.webpackChunk_jbrowse_web||[]).push([[840],{90840:function(n,e,r){r.r(e),r.d(e,{default:function(){return Z}});var s=r(32723),i=r(33028),t=r(34795),a=(r(30969),r(59071)),o=r(72807),c=r(96074),l=r(72097),u=r(59767),d=r(68559),h=r(90934),f=r(87967),x=r(37574);function p(n){var e=n.onConfirm,r=n.onCancel,s=n.reason;return(0,x.jsxs)(u.Dialog,{open:!0,maxWidth:"xl","data-testid":"session-warning-modal",title:"Warning","aria-labelledby":"alert-dialog-title",children:[(0,x.jsxs)(a.Z,{children:[(0,x.jsx)(f.Z,{fontSize:"large"}),(0,x.jsxs)(o.Z,{children:["This link contains a cross origin config that has the following unknown plugins:",(0,x.jsx)("ul",{children:s.map((function(n){return(0,x.jsxs)("li",{children:["URL: ",n.url]},JSON.stringify(n))}))}),"Please ensure you trust the source of this link."]})]}),(0,x.jsxs)(c.Z,{children:[(0,x.jsx)(l.Z,{color:"primary",variant:"contained",onClick:function(){return e()},children:"Yes, I trust it"}),(0,x.jsx)(l.Z,{color:"secondary",variant:"contained",onClick:function(){return r()},children:"Cancel"})]})]})}function Z(n){var e=n.loader,r=n.handleClose;return(0,x.jsx)(p,{onConfirm:(0,t.Z)((0,s.Z)().mark((function n(){var t;return(0,s.Z)().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return t=JSON.parse(JSON.stringify(e.sessionTriaged.snap)),n.next=3,e.fetchPlugins(t);case 3:e.setConfigSnapshot((0,i.Z)((0,i.Z)({},t),{},{id:(0,d.x0)()})),r();case 5:case"end":return n.stop()}}),n)}))),onCancel:(0,t.Z)((0,s.Z)().mark((function n(){return(0,s.Z)().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,(0,h.Z)();case 2:r();case 3:case"end":return n.stop()}}),n)}))),reason:e.sessionTriaged.reason})}},87967:function(n,e,r){var s=r(71600);e.Z=void 0;var i=s(r(48035)),t=r(37574),a=(0,i.default)((0,t.jsx)("path",{d:"M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z"}),"Warning");e.Z=a}}]);
//# sourceMappingURL=840.c4e381ae.chunk.js.map