mage-ai 0.8.81__py3-none-any.whl → 0.8.82__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of mage-ai might be problematic. Click here for more details.

Files changed (92) hide show
  1. mage_ai/server/constants.py +1 -1
  2. mage_ai/server/frontend_dist/404.html +2 -2
  3. mage_ai/server/frontend_dist/404.html.html +2 -2
  4. mage_ai/server/frontend_dist/_next/static/QB08hs4sID1RqTCyVc19P/_buildManifest.js +1 -0
  5. mage_ai/server/frontend_dist/_next/static/chunks/1005-2ad5a1b201c2e742.js +1 -0
  6. mage_ai/server/frontend_dist/_next/static/chunks/{1424-fbc7f741303c0aa0.js → 1424-c6b0d89ffb4a10b9.js} +1 -1
  7. mage_ai/server/frontend_dist/_next/static/chunks/3077-5a56c22fbc5626c8.js +1 -0
  8. mage_ai/server/frontend_dist/_next/static/chunks/3714-d472531256ed5cf5.js +1 -0
  9. mage_ai/server/frontend_dist/_next/static/chunks/547-f3f2ccd9dcde9459.js +1 -0
  10. mage_ai/server/frontend_dist/_next/static/chunks/7400-e5e39ae07de554b2.js +1 -0
  11. mage_ai/server/frontend_dist/_next/static/chunks/{8180-325d712ecbed97ce.js → 8180-0c53312021451bb7.js} +1 -1
  12. mage_ai/server/frontend_dist/_next/static/chunks/8735-1a3d39946add4aea.js +1 -0
  13. mage_ai/server/frontend_dist/_next/static/chunks/894-6290def8665695eb.js +1 -0
  14. mage_ai/server/frontend_dist/_next/static/chunks/8957-6d3f5778166f4294.js +1 -0
  15. mage_ai/server/frontend_dist/_next/static/chunks/9270-e35a5eb3dae4c3ca.js +1 -0
  16. mage_ai/server/frontend_dist/_next/static/chunks/pages/{_app-b25383366d854e8e.js → _app-13fb8342c87983a1.js} +1 -1
  17. mage_ai/server/frontend_dist/_next/static/chunks/pages/files-8b81ef90680f3f72.js +1 -0
  18. mage_ai/server/frontend_dist/_next/static/chunks/pages/manage-9e96b956c26fbc92.js +1 -0
  19. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipeline-runs-3260a2dac8df672e.js +1 -0
  20. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills/{[...slug]-9e519ad50f639e00.js → [...slug]-a4fbf12642923051.js} +1 -1
  21. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/edit-fe65c89f1e86b4b8.js +1 -0
  22. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/monitors/{block-runs-302e1bd9fbf39994.js → block-runs-5c02b08404dbdd20.js} +1 -1
  23. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runtime-25a125d43569c70d.js +1 -0
  24. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/{monitors-5244d6c5d80af010.js → monitors-092f364100995ba6.js} +1 -1
  25. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/runs/{[run]-90170de1e6fe8f04.js → [run]-50e60f6b49eed3f0.js} +1 -1
  26. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/{runs-88994d0bcf41cf9e.js → runs-ed9903520a27f4c8.js} +1 -1
  27. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/settings-55748e7fcf738d91.js +1 -0
  28. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/triggers/{[...slug]-456d84426ffe5025.js → [...slug]-1725c0871027ae05.js} +1 -1
  29. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/{triggers-05f43f9eaf6528db.js → triggers-0d2c9f28ae21cde8.js} +1 -1
  30. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines-2f4b987a8dba3484.js +1 -0
  31. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/account/profile-3ca183fdcb571bde.js +1 -0
  32. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/preferences-3b26db0dd0962783.js +1 -0
  33. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/sync-data-bd5e22e49c1f7bc2.js +1 -0
  34. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/users-85073f9cc09fabf7.js +1 -0
  35. mage_ai/server/frontend_dist/_next/static/chunks/pages/terminal-0d2260ad08dfe44a.js +1 -0
  36. mage_ai/server/frontend_dist/_next/static/chunks/pages/triggers-d74d0f163157ba65.js +1 -0
  37. mage_ai/server/frontend_dist/files.html +25 -0
  38. mage_ai/server/frontend_dist/index.html +2 -2
  39. mage_ai/server/frontend_dist/manage.html +5 -5
  40. mage_ai/server/frontend_dist/pipeline-runs.html +5 -5
  41. mage_ai/server/frontend_dist/pipelines/[pipeline]/backfills/[...slug].html +5 -5
  42. mage_ai/server/frontend_dist/pipelines/[pipeline]/backfills.html +5 -5
  43. mage_ai/server/frontend_dist/pipelines/[pipeline]/edit.html +2 -2
  44. mage_ai/server/frontend_dist/pipelines/[pipeline]/logs.html +5 -5
  45. mage_ai/server/frontend_dist/pipelines/[pipeline]/monitors/block-runs.html +5 -5
  46. mage_ai/server/frontend_dist/pipelines/[pipeline]/monitors/block-runtime.html +5 -5
  47. mage_ai/server/frontend_dist/pipelines/[pipeline]/monitors.html +5 -5
  48. mage_ai/server/frontend_dist/pipelines/[pipeline]/runs/[run].html +5 -5
  49. mage_ai/server/frontend_dist/pipelines/[pipeline]/runs.html +5 -5
  50. mage_ai/server/frontend_dist/pipelines/[pipeline]/settings.html +5 -5
  51. mage_ai/server/frontend_dist/pipelines/[pipeline]/syncs.html +5 -5
  52. mage_ai/server/frontend_dist/pipelines/[pipeline]/triggers/[...slug].html +5 -5
  53. mage_ai/server/frontend_dist/pipelines/[pipeline]/triggers.html +5 -5
  54. mage_ai/server/frontend_dist/pipelines/[pipeline].html +2 -2
  55. mage_ai/server/frontend_dist/pipelines.html +5 -5
  56. mage_ai/server/frontend_dist/settings/account/profile.html +5 -5
  57. mage_ai/server/frontend_dist/settings/workspace/preferences.html +5 -5
  58. mage_ai/server/frontend_dist/settings/workspace/sync-data.html +5 -5
  59. mage_ai/server/frontend_dist/settings/workspace/users.html +5 -5
  60. mage_ai/server/frontend_dist/settings.html +2 -2
  61. mage_ai/server/frontend_dist/sign-in.html +14 -14
  62. mage_ai/server/frontend_dist/terminal.html +5 -5
  63. mage_ai/server/frontend_dist/test.html +3 -3
  64. mage_ai/server/frontend_dist/triggers.html +5 -5
  65. {mage_ai-0.8.81.dist-info → mage_ai-0.8.82.dist-info}/METADATA +1 -1
  66. {mage_ai-0.8.81.dist-info → mage_ai-0.8.82.dist-info}/RECORD +72 -68
  67. mage_ai/server/frontend_dist/_next/static/K62oaHK5x3k16vVxdvIWf/_buildManifest.js +0 -1
  68. mage_ai/server/frontend_dist/_next/static/chunks/1005-38fa861ca54679db.js +0 -1
  69. mage_ai/server/frontend_dist/_next/static/chunks/3077-187a4db6073d95df.js +0 -1
  70. mage_ai/server/frontend_dist/_next/static/chunks/547-833b70469e82cb2b.js +0 -1
  71. mage_ai/server/frontend_dist/_next/static/chunks/5540-1025c6b3e65558b3.js +0 -1
  72. mage_ai/server/frontend_dist/_next/static/chunks/6567-2488118bb39a9d99.js +0 -1
  73. mage_ai/server/frontend_dist/_next/static/chunks/8957-6edafc5a2521efdf.js +0 -1
  74. mage_ai/server/frontend_dist/_next/static/chunks/9129-8ae88897c3817909.js +0 -1
  75. mage_ai/server/frontend_dist/_next/static/chunks/pages/manage-eba67ac0edfdea1b.js +0 -1
  76. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipeline-runs-128dd171c6fff7ac.js +0 -1
  77. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/edit-d90d32812b2be89e.js +0 -1
  78. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runtime-7635e7031335de0f.js +0 -1
  79. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/settings-3c42f05001416811.js +0 -1
  80. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines-c73dab1d63317556.js +0 -1
  81. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/account/profile-f5626eb662337ad5.js +0 -1
  82. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/preferences-292e840e9386335e.js +0 -1
  83. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/sync-data-353dc1ef2fadf70b.js +0 -1
  84. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/users-cd838435ed1b8383.js +0 -1
  85. mage_ai/server/frontend_dist/_next/static/chunks/pages/terminal-d15ea617ef145b32.js +0 -1
  86. mage_ai/server/frontend_dist/_next/static/chunks/pages/triggers-df30a0006fd775b8.js +0 -1
  87. /mage_ai/server/frontend_dist/_next/static/{K62oaHK5x3k16vVxdvIWf → QB08hs4sID1RqTCyVc19P}/_middlewareManifest.js +0 -0
  88. /mage_ai/server/frontend_dist/_next/static/{K62oaHK5x3k16vVxdvIWf → QB08hs4sID1RqTCyVc19P}/_ssgManifest.js +0 -0
  89. {mage_ai-0.8.81.dist-info → mage_ai-0.8.82.dist-info}/LICENSE +0 -0
  90. {mage_ai-0.8.81.dist-info → mage_ai-0.8.82.dist-info}/WHEEL +0 -0
  91. {mage_ai-0.8.81.dist-info → mage_ai-0.8.82.dist-info}/entry_points.txt +0 -0
  92. {mage_ai-0.8.81.dist-info → mage_ai-0.8.82.dist-info}/top_level.txt +0 -0
@@ -0,0 +1 @@
1
+ (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7869],{59739:function(e,n,t){"use strict";var r=t(56669);function o(){}function i(){}i.resetWarningCache=o,e.exports=function(){function e(e,n,t,o,i,u){if(u!==r){var c=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw c.name="Invariant Violation",c}}function n(){return e}e.isRequired=e;var t={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:n,element:e,elementType:e,instanceOf:n,node:e,objectOf:n,oneOf:n,oneOfType:n,shape:n,exact:n,checkPropTypes:i,resetWarningCache:o};return t.PropTypes=t,t}},47329:function(e,n,t){e.exports=t(59739)()},56669:function(e){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},44152:function(e,n,t){"use strict";t.d(n,{r:function(){return l}});var r=t(82684);const o=e=>{let n;const t=new Set,r=(e,r)=>{const o="function"===typeof e?e(n):e;if(o!==n){const e=n;n=r?o:Object.assign({},n,o),t.forEach((t=>t(n,e)))}},o=()=>n,i={setState:r,getState:o,subscribe:e=>(t.add(e),()=>t.delete(e)),destroy:()=>t.clear()};return n=e(r,o,i),i};var i=t(81550);const{useSyncExternalStoreWithSelector:u}=i;const c=e=>{const n="function"===typeof e?(e=>e?o(e):o)(e):e,t=(e,t)=>function(e,n=e.getState,t){const o=u(e.subscribe,e.getState,e.getServerState||e.getState,n,t);return(0,r.useDebugValue)(o),o}(n,e,t);return Object.assign(t,n),t};var s=e=>e?c(e):c;const l=e=>{const n=s((()=>e)),t=(Object.keys(e),(e,t)=>{n.setState((n=>{return{[e]:(r=n[e],o=t,"function"==typeof o?o(r):o)};var r,o}))});return{useGlobalState:e=>{const o=(0,r.useCallback)((n=>n[e]),[e]);return[n(o),(0,r.useCallback)((n=>t(e,n)),[e])]},getGlobalState:e=>n.getState()[e],setGlobalState:t,subscribe:(e,t)=>{n.subscribe(((n,r)=>{n[e]!==r[e]&&t(n[e])}))}}}},1589:function(e,n,t){"use strict";var r=t(82684);var o="function"===typeof Object.is?Object.is:function(e,n){return e===n&&(0!==e||1/e===1/n)||e!==e&&n!==n},i=r.useState,u=r.useEffect,c=r.useLayoutEffect,s=r.useDebugValue;function l(e){var n=e.getSnapshot;e=e.value;try{var t=n();return!o(e,t)}catch(r){return!0}}var a="undefined"===typeof window||"undefined"===typeof window.document||"undefined"===typeof window.document.createElement?function(e,n){return n()}:function(e,n){var t=n(),r=i({inst:{value:t,getSnapshot:n}}),o=r[0].inst,a=r[1];return c((function(){o.value=t,o.getSnapshot=n,l(o)&&a({inst:o})}),[e,t,n]),u((function(){return l(o)&&a({inst:o}),e((function(){l(o)&&a({inst:o})}))}),[e]),s(t),t};n.useSyncExternalStore=void 0!==r.useSyncExternalStore?r.useSyncExternalStore:a},73847:function(e,n,t){"use strict";var r=t(82684),o=t(48216);var i="function"===typeof Object.is?Object.is:function(e,n){return e===n&&(0!==e||1/e===1/n)||e!==e&&n!==n},u=o.useSyncExternalStore,c=r.useRef,s=r.useEffect,l=r.useMemo,a=r.useDebugValue;n.useSyncExternalStoreWithSelector=function(e,n,t,r,o){var f=c(null);if(null===f.current){var d={hasValue:!1,value:null};f.current=d}else d=f.current;f=l((function(){function e(e){if(!s){if(s=!0,u=e,e=r(e),void 0!==o&&d.hasValue){var n=d.value;if(o(n,e))return c=n}return c=e}if(n=c,i(u,e))return n;var t=r(e);return void 0!==o&&o(n,t)?n:(u=e,c=t)}var u,c,s=!1,l=void 0===t?null:t;return[function(){return e(n())},null===l?void 0:function(){return e(l())}]}),[n,t,r,o]);var p=u(e,f[0],f[1]);return s((function(){d.hasValue=!0,d.value=p}),[p]),a(p),p}},48216:function(e,n,t){"use strict";e.exports=t(1589)},81550:function(e,n,t){"use strict";e.exports=t(73847)},1210:function(e,n,t){"use strict";t.d(n,{Z:function(){return P}});var r=t(82394),o=t(21831),i=t(82684),u=t(47999),c=t(49894),s=t(93461),l=t(57384),a=t(41424),f=t(72454),d=t(28598);function p(e,n){var t=e.children;return(0,d.jsx)(f.HS,{ref:n,children:t})}var v=i.forwardRef(p),h=t(32063),b=t(85019),g=t(82531),y=t(66166),j=t(3055),O=t(49125),m=t(91427),x=t(24141);function w(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function S(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?w(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):w(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var P=function(e){var n,t=e.after,r=e.afterHidden,p=e.afterWidth,w=e.afterWidthOverride,P=e.before,k=e.beforeWidth,C=e.breadcrumbs,Z=e.children,E=e.errors,_=e.headerMenuItems,D=e.headerOffset,M=e.mainContainerHeader,F=e.navigationItems,R=e.setErrors,T=e.subheaderChildren,I=e.title,V=e.uuid,H=(0,x.i)().width,N="dashboard_after_width_".concat(V),W="dashboard_before_width_".concat(V),U=(0,i.useRef)(null),B=(0,i.useState)(w?p:(0,m.U2)(N,p)),A=B[0],z=B[1],G=(0,i.useState)(!1),K=G[0],X=G[1],L=(0,i.useState)(P?Math.max((0,m.U2)(W,k),13*O.iI):null),Y=L[0],q=L[1],J=(0,i.useState)(!1),Q=J[0],$=J[1],ee=(0,i.useState)(null)[1],ne=g.ZP.projects.list({},{revalidateOnFocus:!1}).data,te=null===ne||void 0===ne?void 0:ne.projects,re=[];C?re.push.apply(re,(0,o.Z)(C)):(null===te||void 0===te?void 0:te.length)>=1&&re.push.apply(re,[{label:function(){var e;return null===(e=te[0])||void 0===e?void 0:e.name},linkProps:{href:"/"}},{bold:!0,label:function(){return I}}]),(0,i.useEffect)((function(){null===U||void 0===U||!U.current||K||Q||null===ee||void 0===ee||ee(U.current.getBoundingClientRect().width)}),[K,A,Q,Y,U,ee,H]),(0,i.useEffect)((function(){K||(0,m.t8)(N,A)}),[r,K,A,N]),(0,i.useEffect)((function(){Q||(0,m.t8)(W,Y)}),[Q,Y,W]);var oe=(0,y.Z)(p);return(0,i.useEffect)((function(){w&&oe!==p&&z(p)}),[w,p,oe]),(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(l.Z,{title:I}),(0,d.jsx)(a.Z,{breadcrumbs:re,menuItems:_,project:null===te||void 0===te?void 0:te[0],version:null===te||void 0===te||null===(n=te[0])||void 0===n?void 0:n.version}),(0,d.jsxs)(f.Nk,{children:[0!==(null===F||void 0===F?void 0:F.length)&&(0,d.jsx)(f.lm,{showMore:!0,children:(0,d.jsx)(b.Z,{navigationItems:F,showMore:!0})}),(0,d.jsx)(s.Z,{flex:1,flexDirection:"column",children:(0,d.jsxs)(h.Z,{after:t,afterHeightOffset:j.Mz,afterHidden:r,afterMousedownActive:K,afterWidth:A,before:P,beforeHeightOffset:j.Mz,beforeMousedownActive:Q,beforeWidth:f.k1+(P?Y:0),headerOffset:D,hideAfterCompletely:!0,leftOffset:P?f.k1:null,mainContainerHeader:M,mainContainerRef:U,setAfterMousedownActive:X,setAfterWidth:z,setBeforeMousedownActive:$,setBeforeWidth:q,children:[T&&(0,d.jsx)(v,{children:T}),Z]})})]}),E&&(0,d.jsx)(u.Z,{disableClickOutside:!0,isOpen:!0,onClickOutside:function(){return null===R||void 0===R?void 0:R(null)},children:(0,d.jsx)(c.Z,S(S({},E),{},{onClose:function(){return null===R||void 0===R?void 0:R(null)}}))})]})}},66176:function(e,n,t){"use strict";var r=t(82394),o=t(91835),i=(t(82684),t(9518)),u=t(23831),c=t(73942),s=t(49125),l=t(28598);function a(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function f(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?a(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):a(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var d=i.default.div.withConfig({displayName:"ProgressBar__ProgressBarContainerStyle",componentId:"sc-10x9ojc-0"})(["border-radius:","px;height:","px;overflow:hidden;position:relative;width:100%;",""],c.BG,.75*s.iI,(function(e){return"\n background-color: ".concat((e.theme.monotone||u.Z.monotone).grey200,";\n ")})),p=i.default.div.withConfig({displayName:"ProgressBar__ProgressBarStyle",componentId:"sc-10x9ojc-1"})(["height:inherit;position:absolute;"," "," "," ",""],(function(e){return!e.danger&&"\n background-color: ".concat((e.theme.progress||u.Z.progress).positive,";\n ")}),(function(e){return e.progress&&"\n width: ".concat(e.progress,"%;\n ")}),(function(e){return e.danger&&"\n background-color: ".concat((e.theme.progress||u.Z.progress).negative,";\n ")}),(function(e){return e.animateProgress&&"\n animation: animate-progress ".concat(e.animateProgress.duration,"ms linear forwards;\n\n @keyframes animate-progress {\n 0% {\n width: ").concat(e.animateProgress.start,"%;\n }\n\n 100% {\n width: ").concat(e.animateProgress.end,"%;\n }\n }\n ")}));n.Z=function(e){var n=(0,o.Z)({},e);return(0,l.jsx)(d,f(f({},n),{},{children:(0,l.jsx)(p,f({},n))}))}},55389:function(e,n,t){"use strict";t.r(n),t.d(n,{default:function(){return J}});var r=t(77837),o=t(38860),i=t.n(o),u=t(82394),c=t(75582),s=t(17717),l=t(82684),a=t(37958),f=t(83455),d=t(48591),p=t(1210),v=t(6404),h=t(91207),b=t(47999),g=t(67971),y=t(62084),j=t(19711),O=t(16115),m=t(64318),x=t(54405),w=t(41150),S=t(28598);var P=function(e){var n=e.children,t=e.fileVersionsVisible,r=e.onSave,o=e.setFilesVersionsVisible,i=(0,l.useState)(null),u=i[0],c=i[1],s=(0,l.useRef)(null),a=(0,l.useRef)(null),f=(0,l.useMemo)((function(){return[{disabled:!r,keyTextGroups:[[(0,x.V5)()?O.RJ:O.hE,O.SS]],label:function(){return"Save"},onClick:function(){return r?r():null},uuid:"save"}]}),[r]),d=(0,l.useMemo)((function(){return[{label:function(){return t?"Hide versions":"Show versions"},onClick:function(){return o(!t)},uuid:"versions"}]}),[t,o]),p="FileHeaderMenu/index",v=(0,w.y)(),h=v.registerOnKeyDown,P=v.unregisterOnKeyDown;return(0,l.useEffect)((function(){return function(){P(p)}}),[P,p]),h(p,(function(e,n){null!==u&&(n[O.QK]?c((function(e){return 0===e?2:e-1})):n[O.DY]&&c((function(e){return 2===e?0:e+1})))}),[u,c]),(0,S.jsx)(b.Z,{onClickOutside:function(){return c(null)},open:!0,style:{position:"relative"},children:(0,S.jsxs)(g.Z,{children:[(0,S.jsxs)("div",{style:{position:"relative"},children:[(0,S.jsx)(m.u,{highlighted:0===u,onClick:function(){return c((function(e){return 0===e?null:0}))},onMouseEnter:function(){return c((function(e){return null!==e?0:null}))},ref:s,children:(0,S.jsx)(j.ZP,{children:"File"})}),(0,S.jsx)(y.Z,{items:f,onClickCallback:function(){return c(null)},open:0===u,parentRef:s,uuid:"FileHeaderMenu/file"})]}),(0,S.jsxs)("div",{style:{position:"relative"},children:[(0,S.jsx)(m.u,{highlighted:1===u,onClick:function(){return c((function(e){return 1===e?null:1}))},onMouseEnter:function(){return c((function(e){return null!==e?1:null}))},ref:a,children:(0,S.jsx)(j.ZP,{children:"Edit"})}),(0,S.jsx)(y.Z,{items:d,onClickCallback:function(){return c(null)},open:1===u,parentRef:a,uuid:"FileHeaderMenu/edit"})]}),n]})})},k=t(38488),C=t(23351),Z=t(82531),E=t(9518),_=t(23831),D=t(82386),M=t(3055),F=t(37391),R=72-D.uX+M.Mz,T=E.default.div.withConfig({displayName:"indexstyle__HeaderStyle",componentId:"sc-11pty4f-0"})(["height:","px;top:","px;z-index:3;",""],72,M.Mz,(function(e){return"\n background-color: ".concat((e.theme.background||_.Z.background).codeArea,";\n ")})),I=E.default.div.withConfig({displayName:"indexstyle__MenuStyle",componentId:"sc-11pty4f-1"})(["height:","px;position:relative;z-index:1;",""],36,(function(e){return"\n border-bottom: 1px solid ".concat((e.theme.borders||_.Z.borders).medium,";\n ")})),V=E.default.div.withConfig({displayName:"indexstyle__TabsStyle",componentId:"sc-11pty4f-2"})([""," height:","px;overflow-x:auto;position:sticky;width:100%;z-index:0;"],(0,F.y$)(),36),H=t(91427),N=t(24224),W="open_files";function U(e){(0,H.t8)(W,e)}var B=t(96510),A=t(51504),z=t(9728);function G(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function K(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?G(Object(t),!0).forEach((function(n){(0,u.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):G(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function X(e){var n=e.split(s.sep);return n[n.length-1]}var L=function(){var e=(0,a.j)("apiReloads"),n=(0,c.Z)(e,2)[1],t=(0,l.useRef)(null),r=(0,l.useRef)(null),o=(0,l.useCallback)((function(e){r.current||(r.current={}),r.current=K(K({},r.current),e)}),[r]),i=(0,l.useState)([]),s=i[0],b=i[1],g=(0,l.useState)(null),y=g[0],j=g[1],m=(0,l.useState)({}),x=m[0],E=m[1],_=(0,l.useState)(!1),D=_[0],M=_[1],F=(0,l.useMemo)((function(){return s.reduce((function(e,n){var t=X(n);return e[t]||(e[t]=[]),e[t].push(n),e}),{})}),[s]),G=(0,l.useCallback)((function(e){U(e),b(e)}),[]),L=(0,l.useCallback)((function(e){G(function(e){var n=(0,H.U2)(W,[]);return n.includes(e)||n.push(e),U(n),n}(e))}),[G]),Y=(0,l.useCallback)((function(e){o((0,u.Z)({},e,null)),E((function(n){return K(K({},n),{},(0,u.Z)({},e,!1))}));var n=function(e){var n=(0,H.U2)(W,[]),t=(0,N.Od)(n,(function(n){return n===e}));return U(t),t}(e);G(n),y===e&&(null===n||void 0===n?void 0:n.length)>=1&&j(n[n.length-1]),0===(null===n||void 0===n?void 0:n.length)&&j(null)}),[y,o,G]),q=(0,l.useCallback)((function(e,n){n||(L(e),j(e))}),[L]);(0,l.useEffect)((function(){var e=(0,H.U2)(W,[]);G(e),j((function(n){return!n&&(null===e||void 0===e?void 0:e.length)>=1?e[0]:n}))}),[G]);var J=Z.ZP.files.list(),Q=J.data,$=J.mutate,ee=(0,l.useMemo)((function(){return(null===Q||void 0===Q?void 0:Q.files)||[]}),[Q]),ne=(0,z.VI)(null,{},[],{uuid:"FilesPage"}),te=(0,c.Z)(ne,1)[0],re="Files/index",oe=(0,w.y)(),ie=(oe.disableGlobalKeyboardShortcuts,oe.registerOnKeyDown),ue=oe.unregisterOnKeyDown;(0,l.useEffect)((function(){return function(){ue(re)}}),[ue,re]),ie(re,(function(e,n){var t=Object.entries(x).reduce((function(e,n){var t=(0,c.Z)(n,2),r=t[0];return t[1]?e.concat(r):e}),[]);if((0,A.y)([O.zX,O.hS],n)&&(null===t||void 0===t?void 0:t.length)>=1){e.preventDefault();var r="You have changes that are unsaved: ".concat(t.join(", "),". ")+"Click cancel and save your changes before reloading page.";"undefined"!==typeof location&&window.confirm(r)&&location.reload()}}),[x]);var ce=(0,l.useMemo)((function(){return(0,S.jsx)(k.Z,{filePaths:s,filesTouched:x,isSelectedFilePath:function(e,n){return e===n},onClickTab:function(e){return j(e)},onClickTabClose:function(e){return Y(e)},renderTabTitle:function(e){var n=X(e),t=F[n];return t&&(null===t||void 0===t?void 0:t.length)>=2?e:n},selectedFilePath:y})}),[x,s,F,Y,y]),se=(0,l.useMemo)((function(){return(0,S.jsx)(v.Z,{fetchFileTree:$,files:ee,onClickFile:function(e){return q(e)},onClickFolder:function(e){return q(e,!0)},onCreateFile:function(e){var n=e.path;return q(n)},ref:t})}),[$,t,ee,q]),le=(0,f.Db)((function(e){return Z.ZP.file_contents.useUpdate((null===e||void 0===e?void 0:e.path)&&encodeURIComponent(null===e||void 0===e?void 0:e.path))({file_content:e})}),{onSuccess:function(e){return(0,B.wD)(e,{callback:function(e){var t=e.file_content;n((function(e){return K(K({},e),{},(0,u.Z)({},"FileVersions/".concat(null===t||void 0===t?void 0:t.path),Number(new Date)))})),o((0,u.Z)({},null===t||void 0===t?void 0:t.path,null))},onErrorCallback:function(e,n){return te({errors:n,response:e})}})}}),ae=(0,c.Z)(le,1)[0],fe=(0,l.useCallback)((function(e,n){ae(K(K({},n),{},{content:e})),E((function(e){return K(K({},e),{},(0,u.Z)({},null===n||void 0===n?void 0:n.path,!1))}))}),[E,ae]),de=(0,l.useMemo)((function(){return null===s||void 0===s?void 0:s.map((function(e){return(0,S.jsx)("div",{style:{display:y===e?null:"none"},children:(0,S.jsx)(d.Z,{uuid:"FileEditor/".concat(decodeURIComponent(e)),children:(0,S.jsx)(h.Z,{active:y===e,disableRefreshWarning:!0,filePath:e,hideHeaderButtons:!0,onContentChange:function(n){return o((0,u.Z)({},e,n))},saveFile:fe,selectedFilePath:y,setErrors:te,setFilesTouched:E})})},e)}))}),[s,fe,y,o,te]),pe=(0,l.useMemo)((function(){return(0,S.jsx)(P,{fileVersionsVisible:D,onSave:function(){var e,n;(null===r||void 0===r||null===(e=r.current)||void 0===e||null===(n=e[y])||void 0===n?void 0:n.length)>=1&&fe(r.current[y],{path:y})},setFilesVersionsVisible:M})}),[r,D,fe,y,M]);return(0,S.jsx)(p.Z,{after:(0,S.jsx)(d.Z,{uuid:"FileVersions/".concat(y?decodeURIComponent(y):""),children:(0,S.jsx)(C.Z,{selectedFilePath:y,setErrors:te})}),afterHidden:!(D&&y),before:se,headerOffset:R,mainContainerHeader:(null===s||void 0===s?void 0:s.length)>=1&&(0,S.jsxs)(T,{children:[(0,S.jsx)(I,{children:pe}),(0,S.jsx)(V,{children:ce})]}),title:"Files",uuid:"Files/index",children:de})},Y=t(41788);function q(){return(0,S.jsx)(L,{})}q.getInitialProps=(0,r.Z)(i().mark((function e(){return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",{});case 1:case"end":return e.stop()}}),e)})));var J=(0,Y.Z)(q)},99017:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/files",function(){return t(55389)}])}},function(e){e.O(0,[844,7607,7011,8789,1424,1005,8180,3714,9270,894,9774,2888,179],(function(){return n=99017,e(e.s=n);var n}));var n=e.O();_N_E=n}]);
@@ -0,0 +1 @@
1
+ (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8867],{59739:function(e,n,t){"use strict";var r=t(56669);function o(){}function i(){}i.resetWarningCache=o,e.exports=function(){function e(e,n,t,o,i,c){if(c!==r){var a=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw a.name="Invariant Violation",a}}function n(){return e}e.isRequired=e;var t={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:n,element:e,elementType:e,instanceOf:n,node:e,objectOf:n,oneOf:n,oneOfType:n,shape:n,exact:n,checkPropTypes:i,resetWarningCache:o};return t.PropTypes=t,t}},47329:function(e,n,t){e.exports=t(59739)()},56669:function(e){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},1210:function(e,n,t){"use strict";t.d(n,{Z:function(){return Z}});var r=t(82394),o=t(21831),i=t(82684),c=t(47999),a=t(49894),s=t(93461),u=t(57384),l=t(41424),d=t(72454),f=t(28598);function p(e,n){var t=e.children;return(0,f.jsx)(d.HS,{ref:n,children:t})}var h=i.forwardRef(p),m=t(32063),b=t(85019),v=t(82531),x=t(66166),O=t(3055),R=t(49125),A=t(91427),S=t(24141);function E(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function g(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?E(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):E(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var Z=function(e){var n,t=e.after,r=e.afterHidden,p=e.afterWidth,E=e.afterWidthOverride,Z=e.before,T=e.beforeWidth,_=e.breadcrumbs,k=e.children,w=e.errors,j=e.headerMenuItems,C=e.headerOffset,P=e.mainContainerHeader,D=e.navigationItems,y=e.setErrors,N=e.subheaderChildren,I=e.title,M=e.uuid,W=(0,S.i)().width,L="dashboard_after_width_".concat(M),H="dashboard_before_width_".concat(M),U=(0,i.useRef)(null),F=(0,i.useState)(E?p:(0,A.U2)(L,p)),X=F[0],Y=F[1],K=(0,i.useState)(!1),B=K[0],z=K[1],G=(0,i.useState)(Z?Math.max((0,A.U2)(H,T),13*R.iI):null),V=G[0],q=G[1],Q=(0,i.useState)(!1),$=Q[0],J=Q[1],ee=(0,i.useState)(null)[1],ne=v.ZP.projects.list({},{revalidateOnFocus:!1}).data,te=null===ne||void 0===ne?void 0:ne.projects,re=[];_?re.push.apply(re,(0,o.Z)(_)):(null===te||void 0===te?void 0:te.length)>=1&&re.push.apply(re,[{label:function(){var e;return null===(e=te[0])||void 0===e?void 0:e.name},linkProps:{href:"/"}},{bold:!0,label:function(){return I}}]),(0,i.useEffect)((function(){null===U||void 0===U||!U.current||B||$||null===ee||void 0===ee||ee(U.current.getBoundingClientRect().width)}),[B,X,$,V,U,ee,W]),(0,i.useEffect)((function(){B||(0,A.t8)(L,X)}),[r,B,X,L]),(0,i.useEffect)((function(){$||(0,A.t8)(H,V)}),[$,V,H]);var oe=(0,x.Z)(p);return(0,i.useEffect)((function(){E&&oe!==p&&Y(p)}),[E,p,oe]),(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(u.Z,{title:I}),(0,f.jsx)(l.Z,{breadcrumbs:re,menuItems:j,project:null===te||void 0===te?void 0:te[0],version:null===te||void 0===te||null===(n=te[0])||void 0===n?void 0:n.version}),(0,f.jsxs)(d.Nk,{children:[0!==(null===D||void 0===D?void 0:D.length)&&(0,f.jsx)(d.lm,{showMore:!0,children:(0,f.jsx)(b.Z,{navigationItems:D,showMore:!0})}),(0,f.jsx)(s.Z,{flex:1,flexDirection:"column",children:(0,f.jsxs)(m.Z,{after:t,afterHeightOffset:O.Mz,afterHidden:r,afterMousedownActive:B,afterWidth:X,before:Z,beforeHeightOffset:O.Mz,beforeMousedownActive:$,beforeWidth:d.k1+(Z?V:0),headerOffset:C,hideAfterCompletely:!0,leftOffset:Z?d.k1:null,mainContainerHeader:P,mainContainerRef:U,setAfterMousedownActive:z,setAfterWidth:Y,setBeforeMousedownActive:J,setBeforeWidth:q,children:[N&&(0,f.jsx)(h,{children:N}),k]})})]}),w&&(0,f.jsx)(c.Z,{disableClickOutside:!0,isOpen:!0,onClickOutside:function(){return null===y||void 0===y?void 0:y(null)},children:(0,f.jsx)(a.Z,g(g({},w),{},{onClose:function(){return null===y||void 0===y?void 0:y(null)}}))})]})}},85307:function(e,n,t){"use strict";t.d(n,{$W:function(){return u},cl:function(){return l},cv:function(){return d},dE:function(){return s}});var r=t(9518),o=t(23831),i=t(73942),c=t(49125),a=t(37391),s=r.default.div.withConfig({displayName:"indexstyle__SectionStyle",componentId:"sc-7a1uhf-0"})(["border-radius:","px;padding:","px;",""],i.n_,c.cd*c.iI,(function(e){return"\n background-color: ".concat((e.theme.background||o.Z.background).popup,";\n ")})),u=r.default.div.withConfig({displayName:"indexstyle__CodeEditorStyle",componentId:"sc-7a1uhf-1"})(["padding-top:","px;",""],c.cd*c.iI,(function(e){return"\n background-color: ".concat((e.theme.background||o.Z.background).codeTextarea,";\n ")})),l=r.default.div.withConfig({displayName:"indexstyle__TableContainerStyle",componentId:"sc-7a1uhf-2"})(["overflow:auto;max-height:90vh;width:100%;"," "," "," "," ",""],a.w5,(function(e){return e.hideHorizontalScrollbar&&"\n overflow-x: hidden;\n "}),(function(e){return e.width&&"\n width: ".concat(e.width,";\n ")}),(function(e){return e.height&&"\n height: ".concat(e.height,";\n ")}),(function(e){return e.maxHeight&&"\n max-height: ".concat(e.maxHeight,";\n ")})),d=r.default.div.withConfig({displayName:"indexstyle__HeaderRowStyle",componentId:"sc-7a1uhf-3"})(["padding:","px;"," "," ",""],2*c.iI,(function(e){return"\n background-color: ".concat((e.theme||o.Z).interactive.defaultBackground,";\n border-bottom: ").concat(i.YF,"px ").concat(i.M8," ").concat((e.theme||o.Z).borders.medium,";\n ")}),(function(e){return e.padding&&"\n padding: ".concat(e.padding,"px;\n ")}),(function(e){return e.rounded&&"\n border-top-left-radius: ".concat(i.n_,"px;\n border-top-right-radius: ").concat(i.n_,"px;\n ")}))},65597:function(e,n,t){"use strict";t.d(n,{f:function(){return a}});var r=t(9518),o=t(23831),i=t(49125),c=t(73942),a=r.default.div.withConfig({displayName:"Tablestyle__PopupContainerStyle",componentId:"sc-8ammqd-0"})(["position:absolute;max-height:","px;z-index:10;border-radius:","px;padding:","px;"," "," "," ",""],58*i.iI,c.TR,2*i.iI,(function(e){return"\n box-shadow: ".concat((e.theme.shadow||o.Z.shadow).popup,";\n background-color: ").concat((e.theme.interactive||o.Z.interactive).defaultBackground,";\n ")}),(function(e){return e.leftOffset&&"\n left: ".concat(e.leftOffset,"px;\n ")}),(function(e){return e.topOffset&&"\n top: ".concat(e.topOffset,"px;\n ")}),(function(e){return e.width&&"\n width: ".concat(e.width,"px;\n ")}))},86422:function(e,n,t){"use strict";t.d(n,{$W:function(){return p},DA:function(){return f},HX:function(){return b},J8:function(){return m},L8:function(){return c},Lq:function(){return l},Qj:function(){return v},Ut:function(){return A},V4:function(){return R},VZ:function(){return h},dO:function(){return d},f2:function(){return O},iZ:function(){return x},t6:function(){return a},tf:function(){return u}});var r,o,i,c,a,s=t(82394);!function(e){e.DYNAMIC="dynamic",e.DYNAMIC_CHILD="dynamic_child",e.REDUCE_OUTPUT="reduce_output"}(c||(c={})),function(e){e.MARKDOWN="markdown",e.PYTHON="python",e.R="r",e.SQL="sql",e.YAML="yaml"}(a||(a={}));var u,l,d=(r={},(0,s.Z)(r,a.MARKDOWN,"MD"),(0,s.Z)(r,a.PYTHON,"PY"),(0,s.Z)(r,a.R,"R"),(0,s.Z)(r,a.SQL,"SQL"),(0,s.Z)(r,a.YAML,"YAML"),r);!function(e){e.CALLBACK="callback",e.CHART="chart",e.CUSTOM="custom",e.DATA_EXPORTER="data_exporter",e.DATA_LOADER="data_loader",e.DBT="dbt",e.EXTENSION="extension",e.SCRATCHPAD="scratchpad",e.SENSOR="sensor",e.MARKDOWN="markdown",e.TRANSFORMER="transformer"}(u||(u={})),function(e){e.BLUE="blue",e.GREY="grey",e.PINK="pink",e.PURPLE="purple",e.TEAL="teal",e.YELLOW="yellow"}(l||(l={}));var f,p=[u.CHART,u.CUSTOM,u.DATA_EXPORTER,u.DATA_LOADER,u.SCRATCHPAD,u.SENSOR,u.MARKDOWN,u.TRANSFORMER],h=[u.DATA_EXPORTER,u.DATA_LOADER],m=[u.DATA_EXPORTER,u.DATA_LOADER,u.TRANSFORMER],b=[u.DATA_EXPORTER,u.DATA_LOADER,u.DBT,u.TRANSFORMER],v=[u.CHART,u.SCRATCHPAD,u.SENSOR,u.MARKDOWN],x=[u.CALLBACK,u.CHART,u.EXTENSION,u.SCRATCHPAD,u.MARKDOWN];!function(e){e.EXECUTED="executed",e.FAILED="failed",e.NOT_EXECUTED="not_executed",e.UPDATED="updated"}(f||(f={}));var O=[u.CUSTOM,u.DATA_EXPORTER,u.DATA_LOADER,u.TRANSFORMER],R=(o={},(0,s.Z)(o,u.EXTENSION,"Callback"),(0,s.Z)(o,u.CUSTOM,"Custom"),(0,s.Z)(o,u.DATA_EXPORTER,"Data exporter"),(0,s.Z)(o,u.DATA_LOADER,"Data loader"),(0,s.Z)(o,u.EXTENSION,"Extension"),(0,s.Z)(o,u.SCRATCHPAD,"Scratchpad"),(0,s.Z)(o,u.SENSOR,"Sensor"),(0,s.Z)(o,u.MARKDOWN,"Markdown"),(0,s.Z)(o,u.TRANSFORMER,"Transformer"),o),A=[u.DATA_LOADER,u.TRANSFORMER,u.DATA_EXPORTER,u.SENSOR];i={},(0,s.Z)(i,u.DATA_EXPORTER,"DE"),(0,s.Z)(i,u.DATA_LOADER,"DL"),(0,s.Z)(i,u.SCRATCHPAD,"SP"),(0,s.Z)(i,u.SENSOR,"SR"),(0,s.Z)(i,u.MARKDOWN,"MD"),(0,s.Z)(i,u.TRANSFORMER,"TF")},70120:function(e,n,t){"use strict";t.r(n),t.d(n,{default:function(){return K}});var r=t(77837),o=t(75582),i=t(38860),c=t.n(i),a=t(82684),s=t(83455),u=t(60328),l=t(47999),d=t(57722),f=t(67971),p=t(87372),h=t(11135),m=t(86673),b=t(58180),v=t(19711),x=t(82944),O=t(70902),R=t(82531),A=t(10503),S=t(86422),E=t(73899),g=t(99994),Z=t(85307),T=t(49125),_=t(96510),k=t(90211),w=t(28598);var j,C=function(e){var n=e.clusterType,t=e.fetchWorkspaces,r=(0,a.useState)(),i=r[0],c=r[1],u=(0,a.useState)(),l=u[0],j=u[1],C=(0,a.useState)(),P=C[0],D=C[1],y=(0,a.useState)(null),N=y[0],I=y[1],M=(0,a.useState)(),W=M[0],L=M[1],H=(0,a.useState)(),U=H[0],F=H[1],X=(0,s.Db)(R.ZP.workspaces.useCreate(),{onSuccess:function(e){return(0,_.wD)(e,{callback:function(e){e.success?(t(),c(!1)):j(e.error_message)},onErrorCallback:function(e){var n=e.error,t=n.errors,r=n.message;console.log(t,r)}})}}),Y=(0,o.Z)(X,2),K=Y[0],B=Y[1].isLoading,z=[[(0,w.jsx)(v.ZP,{bold:!0,color:E.cM,children:"Workspace name"},"workspace_name_label"),(0,w.jsx)(x.Z,{label:"ecs"===n?"Spaces will be replaced by underscores":"Spaces will be replaced by hyphens",monospace:!0,onChange:function(e){e.preventDefault(),L(e.target.value)},placeholder:"Name your new workspace",value:W},"workspace_name_input")]];return"k8s"===n&&z.push([(0,w.jsx)(v.ZP,{bold:!0,color:E.cM,children:"Service account name (optional)"},"service_account_name"),(0,w.jsx)(x.Z,{label:"Name of service account to be attached to stateful set",monospace:!0,onChange:function(e){e.preventDefault(),F(e.target.value)},placeholder:"Service account name",value:U},"service_account_name_label")]),(0,w.jsx)(w.Fragment,{children:i?(0,w.jsxs)(w.Fragment,{children:[(0,w.jsx)(p.Z,{default:!0,level:5,monospace:!0,children:"Configure your workspace"}),(0,w.jsx)(b.Z,{columnFlex:[null,3],rows:z}),"k8s"===n&&(0,w.jsxs)(w.Fragment,{children:[(0,w.jsx)(m.Z,{mt:1,children:(0,w.jsxs)(f.Z,{alignItems:"center",children:[(0,w.jsx)(v.ZP,{default:!0,monospace:!0,children:"Configure container"}),(0,w.jsx)(m.Z,{ml:1}),(0,w.jsx)(O.Z,{checked:P,onCheck:function(){return D((function(e){return!e}))}})]})}),P&&(0,w.jsx)(m.Z,{mt:1,children:(0,w.jsx)(Z.$W,{children:(0,w.jsx)(d.Z,{autoHeight:!0,language:S.t6.YAML,onChange:function(e){I(e)},tabSize:2,value:N||void 0,width:"100%"})})})]}),B&&(0,w.jsx)(m.Z,{mt:1,children:(0,w.jsx)(v.ZP,{small:!0,warning:!0,children:"This may take up to a few minutes... Once the service is created, it may take another 5-10 minutes for the service to be accessible."})}),!B&&l&&(0,w.jsxs)(w.Fragment,{children:[(0,w.jsx)(m.Z,{mt:1,children:(0,w.jsx)(v.ZP,{danger:!0,small:!0,children:"Failed to create instance, see error below."})}),(0,w.jsx)(m.Z,{mt:1,children:(0,w.jsx)(v.ZP,{danger:!0,small:!0,children:l})})]}),(0,w.jsx)(m.Z,{my:2,children:(0,w.jsxs)(f.Z,{children:[(0,w.jsx)(h.ZP,{background:E.a$,bold:!0,inline:!0,loading:B,onClick:function(){return K({workspace:{cluster_type:n,container_config:P&&N,name:(e=W,"ecs"===n?(0,k.We)(e,"_"):(0,k.We)(e,"-")),service_account_name:U}});var e},uuid:"workspaces/create",children:"Create"}),(0,w.jsx)(m.Z,{ml:1}),(0,w.jsx)(h.ZP,{bold:!0,inline:!0,onClick:function(){return c(!1)},uuid:"workspaces/cancel",children:"Cancel"})]})})]}):(0,w.jsx)(h.ZP,{background:g.eW,beforeElement:(0,w.jsx)(A.mm,{size:2.5*T.iI}),bold:!0,inline:!0,onClick:function(){L((0,k.Y6)()),c(!0)},uuid:"workspaces/new",children:"Create new workspace"})})},P=t(62084),D=t(41788),y=t(21831),N=t(1210),I=t(72454),M=t(81132),W=t(9736);function L(e,n){var t=e.owner,r=e.roles,o=[{Icon:A.Vz,id:j.WORKSPACES,isSelected:function(){return j.WORKSPACES===n},label:function(){return"Workspaces"},linkProps:{href:"/manage"}}];return(t||r===M.No.ADMIN)&&o.push({Icon:A.NO,id:j.USERS,isSelected:function(){return j.USERS===n},label:function(){return"Users"},linkProps:{href:"/manage/users"}}),(!(0,W.YB)()||r<=M.No.EDITOR)&&o.push({Icon:A.Zr,id:j.SETTINGS,isSelected:function(){return j.SETTINGS===n},label:function(){return"Settings"},linkProps:{href:"/manage/settings"}}),o}!function(e){e.WORKSPACES="workspaces",e.USERS="users",e.SETTINGS="settings"}(j||(j={}));var H=function(e){var n=e.breadcrumbs,t=void 0===n?[]:n,r=e.children,o=e.pageName,i=e.subheaderChildren,c=(0,W.PR)()||{};return(0,w.jsx)(N.Z,{afterWidth:I.k1,breadcrumbs:[{bold:!0,label:function(){return"Workspaces"}}].concat((0,y.Z)(t)),navigationItems:L(c,o),subheaderChildren:i,title:"Workspaces",uuid:"workspaces/index",children:r})},U=t(73942),F=t(65597);function X(e){var n=e.fetchWorkspaces,t=e.instance,r=e.clusterType,i=(0,a.useRef)(null),c=(0,a.useState)(),d=c[0],p=c[1],h=(0,a.useState)(),b=h[0],x=h[1],O=t.name,S=(t.task_arn,{cluster_type:r}),E=(0,s.Db)(R.ZP.workspaces.useUpdate(O,S),{onSuccess:function(e){return(0,_.wD)(e,{callback:function(){n(),p(!1)},onErrorCallback:function(e){var n=e.error,t=n.errors,r=n.message;console.log(t,r)}})}}),g=(0,o.Z)(E,1)[0],Z=(0,s.Db)(R.ZP.workspaces.useDelete(O,S),{onSuccess:function(e){return(0,_.wD)(e,{callback:function(){n(),p(!1)},onErrorCallback:function(e){var n=e.error,t=n.errors,r=n.message;console.log(t,r)}})}}),k=(0,o.Z)(Z,1)[0],j=(0,a.useMemo)((function(){var e=t.status,n=[{label:function(){return(0,w.jsx)(v.ZP,{children:"Delete workspace"})},onClick:function(){return x(!0)},uuid:"delete_workspace"}];return"STOPPED"===e?n.unshift({label:function(){return(0,w.jsx)(v.ZP,{children:"Resume instance"})},onClick:function(){return g({workspace:{action:"resume",cluster_type:r,name:t.name,task_arn:t.task_arn}})},uuid:"resume_instance"}):"RUNNING"===e&&n.unshift({label:function(){return(0,w.jsx)(v.ZP,{children:"Stop instance"})},onClick:function(){return g({workspace:{action:"stop",cluster_type:r,name:t.name,task_arn:t.task_arn}})},uuid:"stop_instance"}),n}),[r,t,g]);return(0,w.jsx)(w.Fragment,{children:"ecs"===r&&(0,w.jsxs)("div",{ref:i,style:{position:"relative",zIndex:"1"},children:[(0,w.jsx)(u.Z,{iconOnly:!0,onClick:function(){return p(!d)},children:(0,w.jsx)(A.mH,{size:2*T.iI})}),(0,w.jsx)(l.Z,{disableEscape:!0,onClickOutside:function(){p(!1),x(!1)},open:d,children:b?(0,w.jsxs)(F.f,{leftOffset:30*-T.iI,topOffset:3*-T.iI,width:30*T.iI,children:[(0,w.jsx)(v.ZP,{children:"Are you sure you want to delete"}),(0,w.jsx)(v.ZP,{children:"this instance? You may not be"}),(0,w.jsx)(v.ZP,{children:"able to recover your data."}),(0,w.jsx)(m.Z,{mt:1}),(0,w.jsxs)(f.Z,{children:[(0,w.jsx)(u.Z,{danger:!0,onClick:k,children:"Confirm"}),(0,w.jsx)(m.Z,{ml:1}),(0,w.jsx)(u.Z,{default:!0,onClick:function(){return x(!1)},children:"Cancel"})]})]}):(0,w.jsx)(P.Z,{items:j,left:25*-T.iI,open:d,parentRef:i,topOffset:3*-T.iI,uuid:"workspaces/more_actions",width:25*T.iI})})]})})}function Y(){var e=R.ZP.statuses.list().data,n=(0,a.useMemo)((function(){var n,t;return(null===e||void 0===e||null===(n=e.statuses)||void 0===n||null===(t=n[0])||void 0===t?void 0:t.instance_type)||"ecs"}),[e]),t=R.ZP.workspaces.list({cluster_type:n},{refreshInterval:5e3,revalidateOnFocus:!0}),r=t.data,o=t.mutate,i=(0,a.useMemo)((function(){var e;return null===r||void 0===r||null===(e=r.workspaces)||void 0===e?void 0:e.filter((function(e){return e.name}))}),[r]);return(0,w.jsx)(H,{pageName:j.WORKSPACES,subheaderChildren:(0,w.jsx)(C,{clusterType:n,fetchWorkspaces:o}),children:(0,w.jsx)(b.Z,{columnFlex:[2,4,2,3,1,null],columns:[{uuid:"Status"},{uuid:"Instance Name"},{uuid:"Type"},{uuid:"Public IP address"},{uuid:"Open"},{label:function(){return""},uuid:"Actions"}],rows:null===i||void 0===i?void 0:i.map((function(e){var t=e.instance,r=t.ip,i=t.name,c=t.status,a=t.type,s="http://".concat(r);return"ecs"===n&&(s="http://".concat(r,":6789")),[(0,w.jsx)(u.Z,{borderRadius:U.D7,danger:"STOPPED"===c,default:"PROVISIONING"===c,notClickable:!0,padding:"6px",primary:"RUNNING"===c,warning:"PENDING"===c,children:(0,k.vg)(c)},"status"),(0,w.jsx)(v.ZP,{children:i},"name"),(0,w.jsx)(v.ZP,{children:(0,k.vg)(a)},"type"),(0,w.jsx)(v.ZP,{children:r},"ip"),(0,w.jsx)(u.Z,{iconOnly:!0,onClick:function(){return window.open(s)},children:(0,w.jsx)(A.M0,{size:2*T.iI})},"open_button"),(0,w.jsx)(X,{clusterType:n,fetchWorkspaces:o,instance:t},"more_actions")]}))})})}Y.getInitialProps=(0,r.Z)(c().mark((function e(){return c().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",{});case 1:case"end":return e.stop()}}),e)})));var K=(0,D.Z)(Y)},13157:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/manage",function(){return t(70120)}])}},function(e){e.O(0,[844,7607,8789,1424,1005,8180,9270,9774,2888,179],(function(){return n=13157,e(e.s=n);var n}));var n=e.O();_N_E=n}]);
@@ -0,0 +1 @@
1
+ (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1009],{1210:function(e,t,r){"use strict";r.d(t,{Z:function(){return Z}});var n=r(82394),i=r(21831),o=r(82684),u=r(47999),s=r(49894),a=r(93461),c=r(57384),l=r(41424),f=r(72454),d=r(28598);function p(e,t){var r=e.children;return(0,d.jsx)(f.HS,{ref:t,children:r})}var v=o.forwardRef(p),h=r(32063),b=r(85019),O=r(82531),j=r(66166),g=r(3055),m=r(49125),y=r(91427),P=r(24141);function w(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function x(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?w(Object(r),!0).forEach((function(t){(0,n.Z)(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):w(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}var Z=function(e){var t,r=e.after,n=e.afterHidden,p=e.afterWidth,w=e.afterWidthOverride,Z=e.before,E=e.beforeWidth,_=e.breadcrumbs,D=e.children,C=e.errors,M=e.headerMenuItems,S=e.headerOffset,A=e.mainContainerHeader,k=e.navigationItems,I=e.setErrors,N=e.subheaderChildren,H=e.title,R=e.uuid,L=(0,P.i)().width,W="dashboard_after_width_".concat(R),F="dashboard_before_width_".concat(R),V=(0,o.useRef)(null),T=(0,o.useState)(w?p:(0,y.U2)(W,p)),U=T[0],B=T[1],Q=(0,o.useState)(!1),z=Q[0],X=Q[1],G=(0,o.useState)(Z?Math.max((0,y.U2)(F,E),13*m.iI):null),q=G[0],J=G[1],K=(0,o.useState)(!1),Y=K[0],$=K[1],ee=(0,o.useState)(null)[1],te=O.ZP.projects.list({},{revalidateOnFocus:!1}).data,re=null===te||void 0===te?void 0:te.projects,ne=[];_?ne.push.apply(ne,(0,i.Z)(_)):(null===re||void 0===re?void 0:re.length)>=1&&ne.push.apply(ne,[{label:function(){var e;return null===(e=re[0])||void 0===e?void 0:e.name},linkProps:{href:"/"}},{bold:!0,label:function(){return H}}]),(0,o.useEffect)((function(){null===V||void 0===V||!V.current||z||Y||null===ee||void 0===ee||ee(V.current.getBoundingClientRect().width)}),[z,U,Y,q,V,ee,L]),(0,o.useEffect)((function(){z||(0,y.t8)(W,U)}),[n,z,U,W]),(0,o.useEffect)((function(){Y||(0,y.t8)(F,q)}),[Y,q,F]);var ie=(0,j.Z)(p);return(0,o.useEffect)((function(){w&&ie!==p&&B(p)}),[w,p,ie]),(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(c.Z,{title:H}),(0,d.jsx)(l.Z,{breadcrumbs:ne,menuItems:M,project:null===re||void 0===re?void 0:re[0],version:null===re||void 0===re||null===(t=re[0])||void 0===t?void 0:t.version}),(0,d.jsxs)(f.Nk,{children:[0!==(null===k||void 0===k?void 0:k.length)&&(0,d.jsx)(f.lm,{showMore:!0,children:(0,d.jsx)(b.Z,{navigationItems:k,showMore:!0})}),(0,d.jsx)(a.Z,{flex:1,flexDirection:"column",children:(0,d.jsxs)(h.Z,{after:r,afterHeightOffset:g.Mz,afterHidden:n,afterMousedownActive:z,afterWidth:U,before:Z,beforeHeightOffset:g.Mz,beforeMousedownActive:Y,beforeWidth:f.k1+(Z?q:0),headerOffset:S,hideAfterCompletely:!0,leftOffset:Z?f.k1:null,mainContainerHeader:A,mainContainerRef:V,setAfterMousedownActive:X,setAfterWidth:B,setBeforeMousedownActive:$,setBeforeWidth:J,children:[N&&(0,d.jsx)(v,{children:N}),D]})})]}),C&&(0,d.jsx)(u.Z,{disableClickOutside:!0,isOpen:!0,onClickOutside:function(){return null===I||void 0===I?void 0:I(null)},children:(0,d.jsx)(s.Z,x(x({},C),{},{onClose:function(){return null===I||void 0===I?void 0:I(null)}}))})]})}},66050:function(e,t,r){"use strict";var n;r.d(t,{V:function(){return n}}),function(e){e.CANCELLED="cancelled",e.COMPLETED="completed",e.FAILED="failed",e.INITIAL="initial",e.RUNNING="running"}(n||(n={}))},92597:function(e,t,r){"use strict";r.r(t);var n=r(77837),i=r(82394),o=r(38860),u=r.n(o),s=r(82684),a=r(34376),c=r(1210),l=r(67971),f=r(51099),d=r(97496),p=r(41788),v=r(55378),h=r(86673),b=r(19711),O=r(82531),j=r(47409),g=r(66050),m=r(49125),y=r(33766),P=r(59e3),w=r(28598);function x(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Z(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?x(Object(r),!0).forEach((function(t){(0,i.Z)(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):x(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function E(){var e=(0,a.useRouter)(),t=(0,s.useState)(null),r=t[0],n=t[1],i=(0,P.iV)(),o=null!==i&&void 0!==i&&i.page?i.page:0,u={_limit:f.Q,_offset:o*f.Q};null!==i&&void 0!==i&&i.status&&(u.status=i.status);var p=O.ZP.pipeline_runs.list(u,{refreshInterval:3e3,revalidateOnFocus:!0}),x=p.data,E=p.mutate,_=(0,s.useMemo)((function(){return(null===x||void 0===x?void 0:x.pipeline_runs)||[]}),[x]),D=(0,s.useMemo)((function(){var e;return(null===x||void 0===x||null===(e=x.metadata)||void 0===e?void 0:e.count)||[]}),[x]);return(0,w.jsxs)(c.Z,{errors:r,setErrors:n,title:"Pipeline runs",uuid:"pipeline_runs/index",children:[(0,w.jsx)(h.Z,{mx:2,my:1,children:(0,w.jsxs)(l.Z,{alignItems:"center",children:[(0,w.jsx)(b.ZP,{bold:!0,default:!0,large:!0,children:"Filter runs by status:"}),(0,w.jsx)(h.Z,{mr:1}),(0,w.jsxs)(v.Z,{compact:!0,defaultColor:!0,fitContent:!0,onChange:function(t){t.preventDefault(),"all"===t.target.value?e.push("/pipeline-runs"):(0,y.u7)({page:0,status:t.target.value})},paddingRight:4*m.iI,placeholder:"Select run status",value:(null===i||void 0===i?void 0:i.status)||"all",children:[(0,w.jsx)("option",{value:"all",children:"All statuses"},"all_statuses"),Object.values(g.V).map((function(e){return(0,w.jsx)("option",{value:e,children:j.Do[e]},e)}))]})]})}),(0,w.jsx)(d.Z,{fetchPipelineRuns:E,pipelineRuns:_,setErrors:n}),(0,w.jsx)(h.Z,{p:2,children:(0,w.jsx)(f.Z,{maxPages:9,onUpdate:function(t){var r=Number(t),n=Z(Z({},i),{},{page:r>=0?r:0});e.push("/pipeline-runs","/pipeline-runs?".concat((0,P.uM)(n)))},page:Number(o),totalPages:Math.ceil(D/f.Q)})})]})}E.getInitialProps=(0,n.Z)(u().mark((function e(){return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",{});case 1:case"end":return e.stop()}}),e)}))),t.default=(0,p.Z)(E)},33766:function(e,t,r){"use strict";r.d(t,{O2:function(){return f},g_:function(){return p},u7:function(){return d}});var n=r(75582),i=r(82394),o=r(34376),u=r.n(o),s=r(59e3),a=r(24224);function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function l(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?c(Object(r),!0).forEach((function(t){(0,i.Z)(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):c(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}var f="_offset";function d(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t.preserveParams,i=t.pushHistory,o=t.replaceParams,a=(0,s.iV)(),c={};r&&r.forEach((function(e){a[e]&&(c[e]=a[e])}));var f,d=o?c:a;f=window.location.pathname;var p=i?u().push:u().replace,v=l(l({},d),e);Object.entries(e).forEach((function(e){var t=(0,n.Z)(e,2),r=t[0],i=t[1];"undefined"!==typeof i&&null!==i||delete v[r]}));var h=(0,s.uM)(v);h.length>=1&&(h="?".concat(h));var b="".concat(f.split("?")[0]).concat(h);return p(u().router.pathname,b,{shallow:!0})}function p(e,t,r){var i=r.addingMultipleValues,o=r.isList,u=r.itemsPerPage,s=r.pushHistory,c=void 0!==s&&s,p=r.resetLimitParams,v=l({},e);i?Object.entries(t).forEach((function(e){var t=(0,n.Z)(e,2),r=t[0],i=t[1];if(Array.isArray(i)){var o="".concat(r,"[]");v[o]=i.map(String)}})):o?Object.entries(t).forEach((function(e){var t=(0,n.Z)(e,2),r=t[0],i=t[1],o=String(i),u="".concat(r,"[]"),s=v[u];s&&Array.isArray(s)?(s=s.map(String)).includes(o)?v[u]=(0,a.Od)(s,(function(e){return e===o})):v[u]=s.concat(o):v[u]=[o]})):v=l(l({},v),t),p&&(v._limit=u||20,v[f]=0),d(v,{pushHistory:c})}},60710:function(e,t,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/pipeline-runs",function(){return r(92597)}])}},function(e){e.O(0,[844,7607,1424,1005,8180,8312,9774,2888,179],(function(){return t=60710,e(e.s=t);var t}));var t=e.O();_N_E=t}]);
@@ -1 +1 @@
1
- (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6780],{2850:function(e,n,t){"use strict";t.d(n,{M:function(){return a},W:function(){return l}});var r=t(9518),i=t(3055),l=34*t(49125).iI,a=r.default.div.withConfig({displayName:"indexstyle__BeforeStyle",componentId:"sc-12ee2ib-0"})(["min-height:calc(100vh - ","px);"],i.Mz)},56681:function(e,n,t){"use strict";t.d(n,{G7:function(){return y},ZP:function(){return O},u$:function(){return x}});var r=t(75582),i=t(82394),l=t(26304),a=t(32316),c=t(22673),s=t(48957),o=t(86673),u=t(19711),d=t(58180),p=t(49125),f=t(19395),v=t(7715),b=t(28598),h=["height","heightOffset","pipeline","selectedRun","selectedTab","setSelectedTab"];function m(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function j(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?m(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):m(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var x=76,g={uuid:"Run details"},Z={uuid:"Dependency tree"},y=[Z,g];function O(e){var n=e.height,t=e.heightOffset,i=e.pipeline,m=e.selectedRun,O=e.selectedTab,k=e.setSelectedTab,_=j({},(0,l.Z)(e,h));m?_.blockStatus=(0,f.IJ)(null===m||void 0===m?void 0:m.block_runs):_.noStatus=!0;var P=(0,v.Kn)(null===m||void 0===m?void 0:m.variables)?j({},null===m||void 0===m?void 0:m.variables):(null===m||void 0===m?void 0:m.variables)||{},I=null===m||void 0===m?void 0:m.event_variables;if(I&&(0,v.Kn)(I)&&!(0,v.Qr)(I))if((0,v.Kn)(P)&&P.hasOwnProperty("event")){var w=(0,v.Kn)(P.event)?P.event:{};P.event=j(j({},w),I)}else P.event=j({},I);var S=[];P&&JSON.stringify(P,null,2).split("\n").forEach((function(e){S.push(" ".concat(e))}));var D=m&&[["Run ID",null===m||void 0===m?void 0:m.id],["Variables",(0,b.jsx)(c.Z,{language:"json",small:!0,source:S.join("\n")},"variable_value")]],C=m&&(0,b.jsx)(o.Z,{pb:p.cd,px:p.cd,children:(0,b.jsx)(d.Z,{alignTop:!0,columnFlex:[null,1],columnMaxWidth:function(e){return 1===e?"100px":null},rows:D.map((function(e,n){var t=(0,r.Z)(e,2),i=t[0],l=t[1];return[(0,b.jsx)(u.ZP,{monospace:!0,muted:!0,children:i},"key_".concat(n)),(0,b.jsx)(u.ZP,{monospace:!0,textOverflow:!0,children:l},"val_".concat(n))]})),uuid:"LogDetail"})}),E=O&&k;return(0,b.jsxs)(b.Fragment,{children:[E&&(0,b.jsx)(o.Z,{py:p.cd,children:(0,b.jsx)(a.Z,{onClickTab:k,selectedTabUUID:null===O||void 0===O?void 0:O.uuid,tabs:y})}),(!E||Z.uuid===(null===O||void 0===O?void 0:O.uuid))&&(0,b.jsx)(s.Z,j(j({},_),{},{height:n,heightOffset:(t||0)+(E?x:0),pipeline:i})),g.uuid===(null===O||void 0===O?void 0:O.uuid)&&C]})}},58122:function(e,n,t){"use strict";t.d(n,{CL:function(){return f},FS:function(){return v},JZ:function(){return h},e7:function(){return m},v0:function(){return p},wx:function(){return b}});var r=t(75582),i=t(82394),l=t(43313),a=t(93348),c=t(1286),s=t(90211),o=t(84779);function u(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function d(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?u(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):u(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function p(e){var n=e.statistics,t=Object.keys(n),r=Array(l.Dy.length).fill(0);return 0===t.length?null:(t.forEach((function(e){if(l.Dy.includes(e)){var t=l.CC[e],i=n[e],a=i,c=!1,s=[2,3],u=l.Ub[e],d=l.oH[e],p=l.OD[e];if(l.y_.includes(e))c=!0,s=[2,1,2];else if(e in l.Sq){i=(0,o.Jw)(i,0);var f=l.Sq[e];a=n[f]}var v={columnFlexNumbers:s,name:t,progress:c,rate:a,successDirection:d,warning:p};l.y_.includes(e)||(v.value=i),r[u]=v}})),r)}function f(e){var n=e.columnTypes,t=void 0===n?{}:n,r=e.statistics,i=Object.keys(r);if(0===i.length)return null;var a=Object.values(t),o=a.length,u=[];u.push({name:"Column count",successDirection:l.oH.column_count,value:(0,s.x6)(o)}),i.forEach((function(e){if(l.Zu.includes(e)){var n=l.CC[e],t=r[e],i=l.OD[e];u.push({name:n,successDirection:l.oH[e],value:(0,s.x6)(t),warning:i})}}));var d=(0,c.QO)(a),p=d.countCategory,f=d.countDatetime,v=d.countNumerical;return u.push({name:"Categorical Features",rate:p/o,value:(0,s.x6)(p)},{name:"Numerical Features",rate:v/o,value:(0,s.x6)(v)},{name:"Datetime Features",rate:f/o,value:(0,s.x6)(f)}),u}function v(e){return"string"===typeof e?e:JSON.stringify(e)}function b(e,n){var t,r;return null===e||void 0===e||null===(t=e.find((function(e){var t=e.block;return n(t)})))||void 0===t||null===(r=t.variables)||void 0===r?void 0:r.map((function(e){var n=e.value;return d(d({},e),{},{value:v(n)})}))}function h(e,n){return n===a.Xm.TIME?e.push({uuid:"execution_date",value:"<run datetime>"}):n===a.Xm.EVENT&&e.push({uuid:"event",value:"<trigger event>"}),e}function m(e){return e?Object.entries(e).reduce((function(e,n){var t=(0,r.Z)(n,2),l=t[0],a=t[1],c=a;try{c=JSON.parse(a)}catch(s){}return d(d({},e),{},(0,i.Z)({},l,c))}),{}):e}},18025:function(e,n,t){"use strict";t.d(n,{J:function(){return s},U:function(){return c}});var r=t(9518),i=t(23831),l=t(73942),a=t(49125),c=r.default.div.withConfig({displayName:"indexstyle__CardStyle",componentId:"sc-m7tlau-0"})(["border-radius:","px;border-style:solid;border-width:2px;height:","px;margin-right:","px;padding:","px;width:","px;"," ",""],l.TR,14*a.iI,a.cd*a.iI,a.cd*a.iI,40*a.iI,(function(e){return!e.selected&&"\n border-color: ".concat((e.theme.borders||i.Z.borders).light,";\n ")}),(function(e){return e.selected&&"\n border-color: ".concat((e.theme.interactive||i.Z.interactive).linkPrimary,";\n ")})),s=r.default.div.withConfig({displayName:"indexstyle__DateSelectionContainer",componentId:"sc-m7tlau-1"})(["border-radius:","px;padding:","px;"," "," ",""],l.n_,a.tr,(function(e){return"\n background-color: ".concat((e.theme.interactive||i.Z.interactive).defaultBackground,";\n ")}),(function(e){return e.absolute&&"\n position: absolute;\n z-index: 2;\n right: 0;\n top: ".concat(2.5*a.iI,"px;\n ")}),(function(e){return e.topPosition&&"\n top: -".concat(42*a.iI,"px;\n ")}))},43526:function(e,n,t){"use strict";t.d(n,{I7:function(){return r},IB:function(){return s},VV:function(){return l},_7:function(){return a},rn:function(){return c}});var r,i=t(66050),l="datetime",a="code",c=i.V;!function(e){e.SECOND="second",e.MINUTE="minute",e.HOUR="hour",e.DAY="day",e.WEEK="week",e.MONTH="month",e.YEAR="year",e.CUSTOM="custom"}(r||(r={}));var s=[r.MINUTE,r.HOUR,r.DAY,r.WEEK,r.MONTH,r.YEAR,r.CUSTOM]},52769:function(e,n,t){"use strict";t.d(n,{C:function(){return r}});var r="global"},2713:function(e,n,t){"use strict";var r=t(82394),i=t(44495),l=t(67971),a=t(55378),c=t(86673),s=t(19711),o=t(18025),u=t(49125),d=t(24224),p=t(28598);function f(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function v(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?f(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):f(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}n.Z=function(e){var n=e.selectedDate,t=e.selectedTime,r=e.setSelectedDate,f=e.setSelectedTime,b=e.topPosition;return(0,p.jsxs)(o.J,{absolute:!0,topPosition:b,children:[(0,p.jsx)(i.ZP,{onChange:r,value:n}),(0,p.jsx)(c.Z,{mb:2}),(0,p.jsxs)(l.Z,{alignItems:"center",children:[(0,p.jsx)(s.ZP,{default:!0,large:!0,children:"Time (UTC):"}),(0,p.jsx)(c.Z,{pr:2}),(0,p.jsx)(a.Z,{compact:!0,monospace:!0,onChange:function(e){e.preventDefault(),f((function(n){return v(v({},n),{},{hour:e.target.value})}))},paddingRight:5*u.iI,placeholder:"HH",value:null===t||void 0===t?void 0:t.hour,children:(0,d.m5)(24,0).map((function(e){return String(e).padStart(2,"0")})).map((function(e){return(0,p.jsx)("option",{value:e,children:e},"hour_".concat(e))}))}),(0,p.jsx)(c.Z,{px:1,children:(0,p.jsx)(s.ZP,{bold:!0,large:!0,children:":"})}),(0,p.jsx)(a.Z,{compact:!0,monospace:!0,onChange:function(e){e.preventDefault(),f((function(n){return v(v({},n),{},{minute:e.target.value})}))},paddingRight:5*u.iI,placeholder:"MM",value:null===t||void 0===t?void 0:t.minute,children:(0,d.m5)(60,0).map((function(e){return String(e).padStart(2,"0")})).map((function(e){return(0,p.jsx)("option",{value:e,children:e},"minute_".concat(e))}))})]})]})}},22673:function(e,n,t){"use strict";var r=t(82684),i=t(68792),l=t(31811),a=t(9518),c=t(65292),s=t(23831),o=t(2005),u=t(49125),d=t(28598);n.Z=function(e){var n=e.language,t=e.maxWidth,p=e.showLineNumbers,f=e.small,v=e.source,b=e.wrapLines,h=(0,r.useContext)(a.ThemeContext);function m(e){var r=e.value;return(0,d.jsx)(l.Z,{customStyle:{backgroundColor:(h.background||s.Z.background).popup,border:"none",borderRadius:"none",boxShadow:"none",fontFamily:o.Vp,fontSize:f?12:14,marginBottom:0,marginTop:0,maxWidth:t,paddingBottom:2*u.iI,paddingTop:2*u.iI},language:n,lineNumberStyle:{color:(h.content||s.Z.content).muted},showLineNumbers:p,style:c._4,useInlineStyles:!0,wrapLines:b,children:r})}return(0,d.jsx)(i.D,{components:{code:function(e){var n=e.children;return(0,d.jsx)(m,{value:n})}},children:v})}},32316:function(e,n,t){"use strict";t.d(n,{Z:function(){return h}});var r=t(82684),i=t(60328),l=t(67971),a=t(882),c=t(86673),s=t(19711),o=t(99994),u=t(9518),d=t(49125),p=t(37391),f=u.default.div.withConfig({displayName:"indexstyle__TabsContainerStyle",componentId:"sc-segf7l-0"})(["padding-left:","px;padding-right:","px;"," "," ",""],d.cd*d.iI,d.cd*d.iI,(function(e){return e.noPadding&&"\n padding: 0;\n "}),(function(e){return e.allowScroll&&"\n overflow: auto;\n "}),p.w5),v=t(66653),b=t(28598);var h=function(e){var n=e.allowScroll,t=e.contained,u=e.noPadding,p=e.onClickTab,h=e.selectedTabUUID,m=e.small,j=e.tabs,x=(0,r.useMemo)((function(){var e=j.length,n=[];return j.forEach((function(t,r){var u=t.Icon,f=t.IconSelected,j=t.label,x=t.uuid,g=x===h,Z=g&&f||u,y=j?j():x,O=(0,b.jsxs)(l.Z,{alignItems:"center",children:[Z&&(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)(Z,{default:!g,size:2*d.iI}),(0,b.jsx)(c.Z,{mr:1})]}),(0,b.jsx)(s.ZP,{bold:!0,default:!g,noWrapping:!0,small:!0,children:y})]});r>=1&&e>=2&&n.push((0,b.jsx)("div",{style:{marginLeft:1.5*d.iI}},"spacing-".concat(x))),g?n.push((0,b.jsx)(a.Z,{backgroundGradient:o.yr,backgroundPanel:!0,borderLess:!0,borderWidth:2,compact:m,onClick:function(e){(0,v.j)(e),p(t)},paddingUnitsHorizontal:2,paddingUnitsVertical:1.25,small:m,children:O},x)):n.push((0,b.jsx)("div",{style:{padding:2},children:(0,b.jsx)(i.Z,{borderLess:!0,compact:m,default:!0,onClick:function(e){(0,v.j)(e),p(t)},outline:!0,small:m,children:O})},"button-tab-".concat(x)))})),n}),[p,h,m,j]),g=(0,b.jsx)(l.Z,{alignItems:"center",children:x});return t?g:(0,b.jsx)(f,{allowScroll:n,noPadding:u,children:g})}},12625:function(e,n,t){"use strict";t.r(n),t.d(n,{default:function(){return ie}});var r=t(75582),i=t(77837),l=t(82394),a=t(38860),c=t.n(a),s=t(82684),o=t(83455),u=t(34376),d=t(43526),p=t(60328),f=t(34744),v=t(67971),b=t(87372),h=t(51099),m=t(60547),j=t(97496),x=t(47409),g=t(52769),Z=t(55378),y=t(86673),O=t(54283),k=t(58180),_=t(19711),P=t(82531),I=t(56681),w=t(10503),S=t(2850),D=t(49125),C=t(59920),E=t(90211),N=t(58122),T=t(19395),M=t(33766),L=t(7715),F=t(9736),U=t(96510),A=t(66653),R=t(59e3),H=t(28598);function V(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function B(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?V(Object(t),!0).forEach((function(n){(0,l.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):V(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var z=function(e){var n=e.backfill,t=e.errors,i=e.fetchBackfill,l=e.pipeline,a=e.setErrors,c=e.variables,V=(0,F.Ct)(),z=(0,u.useRouter)(),Y=n||{},W=Y.block_uuid,J=Y.end_datetime,K=Y.id,G=Y.interval_type,q=Y.interval_units,X=Y.name,Q=Y.pipeline_run_dates,$=Y.start_datetime,ee=Y.status,ne=Y.total_run_count,te=Y.variables,re=void 0===te?{}:te,ie=l.uuid,le=(0,R.iV)(),ae={_limit:40,_offset:40*(null!==le&&void 0!==le&&le.page?le.page:0)};null!==le&&void 0!==le&&le.status&&(ae.status=le.status);var ce=P.ZP.pipeline_runs.list(B(B({},ae),{},{backfill_id:K}),{refreshInterval:3e3,revalidateOnFocus:!0},{pauseFetch:!K}),se=ce.data,oe=ce.mutate,ue=!($&&J&&G&&q),de=!ee,pe=(0,s.useMemo)((function(){return(de?Q:null===se||void 0===se?void 0:se.pipeline_runs)||[]}),[se,Q,de]),fe=(0,s.useMemo)((function(){var e;return(null===se||void 0===se||null===(e=se.metadata)||void 0===e?void 0:e.count)||[]}),[se]),ve=(0,s.useState)(null),be=ve[0],he=ve[1],me=(0,s.useMemo)((function(){var e=null!==le&&void 0!==le&&le.page?le.page:0;return(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(j.Z,{disableRowSelect:de,emptyMessage:null!==le&&void 0!==le&&le.status?"No runs available":'No runs available. Please complete backfill configuration by clicking "Edit backfill" above.',fetchPipelineRuns:oe,onClickRow:function(e){return he((function(n){var t=pe[e];return(null===n||void 0===n?void 0:n.id)!==t.id?t:null}))},pipelineRuns:pe,selectedRun:be,setErrors:a}),(0,H.jsx)(y.Z,{p:2,children:(0,H.jsx)(h.Z,{maxPages:9,onUpdate:function(e){var n=Number(e),t=B(B({},le),{},{page:n>=0?n:0});z.push("/pipelines/[pipeline]/backfills/[...slug]","/pipelines/".concat(ie,"/backfills/").concat(K,"?").concat((0,R.uM)(t)))},page:Number(e),totalPages:Math.ceil(fe/40)})})]})}),[oe,K,pe,ie,le,z,be,de,fe]),je=(0,s.useState)(I.G7[0]),xe=je[0],ge=je[1],Ze=(0,o.Db)(P.ZP.backfills.useUpdate(K),{onSuccess:function(e){return(0,U.wD)(e,{callback:function(){i(),oe()},onErrorCallback:function(e,n){return a({errors:n,response:e})}})}}),ye=(0,r.Z)(Ze,2),Oe=ye[0],ke=ye[1].isLoading,_e=(0,s.useMemo)((function(){return!!ee&&(d.rn.CANCELLED!==ee&&d.rn.FAILED!==ee)}),[ee]),Pe=(0,s.useMemo)((function(){return ee&&d.rn.CANCELLED!==ee&&d.rn.FAILED!==ee&&d.rn.INITIAL!==ee&&d.rn.RUNNING!==ee}),[ee]),Ie=(0,s.useMemo)((function(){var e={default:!0,size:1.5*D.iI},n=[[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.VW,B({},e)),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Backfill type"})]},"backfill_type_label"),(0,H.jsx)(_.ZP,{monospace:!0,children:W?d._7:d.VV},"backfill_type")],[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.rs,B({},e)),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Status"})]},"backfill_status_label"),(0,H.jsx)(_.ZP,{danger:d.rn.CANCELLED===ee||d.rn.FAILED==ee,default:d.rn.INITIAL===ee,monospace:!0,muted:!ee,success:d.rn.RUNNING===ee||d.rn.COMPLETED===ee,children:ee||"inactive"},"backfill_status")]];return W||n.push.apply(n,[[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.aw,B({},e)),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Start date and time"})]},"backfill_start_date_label"),(0,H.jsx)(_.ZP,{monospace:!0,children:(0,T.Vx)($)},"backfill_start_date")],[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.aw,B({},e)),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"End date and time"})]},"backfill_end_date_label"),(0,H.jsx)(_.ZP,{monospace:!0,children:(0,T.Vx)(J)},"backfill_end_date")],[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.Pf,B({},e)),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Interval type"})]},"interval_type_label"),(0,H.jsx)(_.ZP,{monospace:!0,children:G&&(0,E.kC)(G)},"interval_type")],[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.Pf,B({},e)),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Interval units"})]},"interval_units_label"),(0,H.jsx)(_.ZP,{monospace:!0,children:q},"interval_units")],[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.qZ,B({},e)),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Total runs"})]},"total_runs_label"),(0,H.jsx)(_.ZP,{monospace:!0,children:ne},"total_runs")]]),(0,H.jsx)(k.Z,{columnFlex:[null,1],rows:n})}),[W,J,G,q,$,ee,ne]),we=(0,s.useMemo)((function(){return re||{}}),[re]),Se=(0,s.useMemo)((function(){var e,n=[];return(0,L.Qr)(we)?n=(0,N.wx)(c,(function(e){return e.uuid===g.C})):Object.entries(we).forEach((function(e){var t=(0,r.Z)(e,2),i=t[0],l=t[1];n.push({uuid:i,value:(0,N.FS)(l)})})),"undefined"!==typeof n&&null!==(e=n)&&void 0!==e&&e.length?(0,H.jsx)(k.Z,{columnFlex:[null,1],rows:n.map((function(e){var n=e.uuid,t=e.value;return[(0,H.jsx)(_.ZP,{default:!0,monospace:!0,small:!0,children:n},"settings_variable_label_".concat(n)),(0,H.jsx)(_.ZP,{monospace:!0,small:!0,children:t},"settings_variable_".concat(n))]}))}):null}),[we,c]);return(0,H.jsx)(H.Fragment,{children:(0,H.jsxs)(m.Z,{afterHidden:!be,before:(0,H.jsxs)(S.M,{children:[(0,H.jsxs)(y.Z,{mb:D.HN,pt:D.cd,px:D.cd,children:[(0,H.jsx)(y.Z,{mb:D.cd,children:(0,H.jsx)(w.yg,{size:5*D.iI})}),(0,H.jsx)(b.Z,{children:X})]}),(0,H.jsx)(y.Z,{px:D.cd,children:(0,H.jsx)(b.Z,{level:5,children:"Settings"})}),(0,H.jsx)(f.Z,{light:!0,mt:1,short:!0}),Ie,Se&&(0,H.jsxs)(y.Z,{my:D.HN,children:[(0,H.jsx)(y.Z,{px:D.cd,children:(0,H.jsx)(b.Z,{level:5,children:"Runtime variables"})}),(0,H.jsx)(f.Z,{light:!0,mt:1,short:!0}),Se]})]}),beforeWidth:34*D.iI,breadcrumbs:[{label:function(){return"Backfills"},linkProps:{as:"/pipelines/".concat(ie,"/backfills"),href:"/pipelines/[pipeline]/backfills"}},{label:function(){return X},linkProps:{as:"/pipelines/".concat(ie,"/backfills/").concat(K),href:"/pipelines/[pipeline]/backfills/[...slug]"}}],buildSidekick:function(e){return(0,I.ZP)(B(B({},e),{},{selectedRun:be,selectedTab:xe,setSelectedTab:ge}))},errors:t,pageName:C.M.BACKFILLS,pipeline:l,setErrors:a,subheader:(0,H.jsxs)(v.Z,{alignItems:"center",children:[!Pe&&(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(p.Z,{beforeIcon:_e?(0,H.jsx)(w.dz,{size:2*D.iI}):(0,H.jsx)(w.Py,{inverted:!(d.rn.CANCELLED===ee||d.rn.FAILED===ee),size:2*D.iI}),danger:_e,disabled:ue,loading:ke,onClick:function(e){(0,A.j)(e),Oe({backfill:{status:_e?d.rn.CANCELLED:d.rn.INITIAL}})},outline:!0,success:!_e&&!(d.rn.CANCELLED===ee||d.rn.FAILED===ee)&&!ue,children:_e?"Cancel backfill":d.rn.CANCELLED===ee||d.rn.FAILED===ee?"Retry backfill":"Start backfill"}),(0,H.jsx)(y.Z,{mr:D.cd})]}),!V&&(0,H.jsxs)(H.Fragment,{children:[ee===x.VO.COMPLETED?(0,H.jsx)(_.ZP,{bold:!0,default:!0,large:!0,children:"Filter runs by status:"}):(0,H.jsx)(p.Z,{linkProps:{as:"/pipelines/".concat(ie,"/backfills/").concat(K,"/edit"),href:"/pipelines/[pipeline]/backfills/[...slug]"},noHoverUnderline:!0,outline:!0,sameColorAsText:!0,children:"Edit backfill"}),(0,H.jsx)(y.Z,{mr:D.cd})]}),!de&&(0,H.jsxs)(Z.Z,{compact:!0,defaultColor:!0,onChange:function(e){e.preventDefault(),"all"===e.target.value?z.push("/pipelines/[pipeline]/backfills/[...slug]","/pipelines/".concat(ie,"/backfills/").concat(K)):(0,M.u7)({page:0,status:e.target.value})},paddingRight:4*D.iI,placeholder:"Select run status",value:(null===le||void 0===le?void 0:le.status)||"all",children:[(0,H.jsx)("option",{value:"all",children:"All statuses"},"all_statuses"),Object.values(x.VO).map((function(e){return(0,H.jsx)("option",{value:e,children:x.Do[e]},e)}))]})]}),title:function(){return X},uuid:"backfill/detail",children:[(0,H.jsx)(y.Z,{mt:D.cd,px:D.cd,children:(0,H.jsx)(b.Z,{level:5,children:"Runs for this backfill"})}),(0,H.jsx)(f.Z,{light:!0,mt:D.cd,short:!0}),se?me:(0,H.jsx)(y.Z,{m:2,children:(0,H.jsx)(O.Z,{inverted:!0})})]})})},Y=t(2713),W=t(47999),J=t(93461),K=t(82944),G=[{label:function(){return"Date and time window"},description:function(){return"Backfill between a date and time range."},uuid:d.VV}],q=t(18025);function X(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function Q(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?X(Object(t),!0).forEach((function(n){(0,l.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):X(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var $=function(e){var n=e.backfill,t=e.errors,i=e.fetchBackfill,l=e.pipeline,a=e.setErrors,c=(e.variables,(0,u.useRouter)()),h=(0,s.useState)(),j=h[0],x=h[1],g=j||{},O=g.block_uuid,I=g.id,S=g.interval_type,M=g.interval_units,F=(g.end_datetime,g.start_datetime,g.name),A=l.uuid,R=(0,s.useState)({}),V=R[0],B=(R[1],(0,s.useState)(O?d._7:d.VV)),z=B[0],X=B[1],$=(0,s.useState)(!1),ee=$[0],ne=$[1],te=(0,s.useState)(!1),re=te[0],ie=te[1],le=(0,s.useState)(null),ae=le[0],ce=le[1],se=(0,s.useState)(null),oe=se[0],ue=se[1],de=(0,s.useState)({hour:"00",minute:"00"}),pe=de[0],fe=de[1],ve=(0,s.useState)({hour:"00",minute:"00"}),be=ve[0],he=ve[1];(0,s.useEffect)((function(){if(n){x(n);var e=n.start_datetime;if(e){var t=e.split(" ")[1];ue((0,T.eI)(e)),he({hour:t.substring(0,2),minute:t.substring(3,5)})}var r=n.end_datetime;if(r){var i=r.split(" ")[1];ce((0,T.eI)(r)),fe({hour:i.substring(0,2),minute:i.substring(3,5)})}}}),[n]);var me=(0,s.useMemo)((function(){var e=[[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.KJ,{default:!0,size:1.5*D.iI}),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Backfill name"})]},"model_name_detail"),(0,H.jsx)(K.Z,{monospace:!0,onChange:function(e){e.preventDefault(),x((function(n){return Q(Q({},n),{},{name:e.target.value})}))},placeholder:"Name this backfill",value:F},"model_name_input_detail")]];return d.VV===z&&e.push.apply(e,[[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.aw,{default:!0,size:1.5*D.iI}),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Start date and time"})]},"start_time"),(0,H.jsxs)("div",{style:{minHeight:"".concat(5.75*D.iI,"px")},children:[!ee&&(0,H.jsx)(K.Z,{monospace:!0,onClick:function(){return ne((function(e){return!e}))},onFocus:function(){return ne(!0)},placeholder:"YYYY-MM-DD HH:MM",value:oe?"".concat(oe.toISOString().split("T")[0]," ").concat(null===be||void 0===be?void 0:be.hour,":").concat(null===be||void 0===be?void 0:be.minute):""}),(0,H.jsx)("div",{style:{width:"400px"},children:(0,H.jsx)(W.Z,{disableEscape:!0,onClickOutside:function(){return ne(!1)},open:ee,style:{position:"relative"},children:(0,H.jsx)(Y.Z,{selectedDate:oe,selectedTime:be,setSelectedDate:ue,setSelectedTime:he,topPosition:!0})})})]},"start_time_input")],[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.aw,{default:!0,size:1.5*D.iI}),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"End date and time"})]},"end_time"),(0,H.jsxs)("div",{style:{minHeight:"".concat(5.75*D.iI,"px")},children:[!re&&(0,H.jsx)(K.Z,{monospace:!0,onClick:function(){return ie((function(e){return!e}))},onFocus:function(){return ie(!0)},placeholder:"YYYY-MM-DD HH:MM",value:ae?"".concat(ae.toISOString().split("T")[0]," ").concat(null===pe||void 0===pe?void 0:pe.hour,":").concat(null===pe||void 0===pe?void 0:pe.minute):""}),(0,H.jsx)("div",{style:{width:"400px"},children:(0,H.jsx)(W.Z,{disableEscape:!0,onClickOutside:function(){return ie(!1)},open:re,style:{position:"relative"},children:(0,H.jsx)(Y.Z,{selectedDate:ae,selectedTime:pe,setSelectedDate:ce,setSelectedTime:fe,topPosition:!0})})})]},"end_time_input")],[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.Pf,{default:!0,size:1.5*D.iI}),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Interval type"})]},"interval_type"),(0,H.jsxs)(Z.Z,{monospace:!0,onChange:function(e){e.preventDefault(),x((function(n){return Q(Q({},n),{},{interval_type:e.target.value})}))},placeholder:"Time spacing between each backfill",value:S,children:[!S&&(0,H.jsx)("option",{value:""}),d.IB.map((function(e){return(0,H.jsx)("option",{value:e,children:(0,E.kC)(e)},e)}))]},"interval_type_input")],[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.Pf,{default:!0,size:1.5*D.iI}),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Interval units"})]},"interval_units"),(0,H.jsx)(K.Z,{disabled:!S,monospace:!0,onChange:function(e){e.preventDefault(),x((function(n){return Q(Q({},n),{},{interval_units:e.target.value})}))},placeholder:S?"Number of ".concat(S).concat(S!==d.I7.CUSTOM?"s":""," between each backfill"):"Interval type is required",type:"number",value:M},"interval_unit_input")]]),(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(y.Z,{mb:2,px:D.cd,children:(0,H.jsx)(b.Z,{children:"Settings"})}),(0,H.jsx)(f.Z,{light:!0,short:!0}),(0,H.jsx)(k.Z,{columnFlex:[null,1],rows:e})]})}),[ae,oe,S,M,F,z,ee,re,pe,be]),je=(0,o.Db)(P.ZP.backfills.useUpdate(I),{onSuccess:function(e){return(0,U.wD)(e,{callback:function(){i(),c.push("/pipelines/[pipeline]/backfills/[...slug]","/pipelines/".concat(A,"/backfills/").concat(I))},onErrorCallback:function(e,n){return a({errors:n,response:e})}})}}),xe=(0,r.Z)(je,2),ge=xe[0],Ze=xe[1].isLoading,ye=(0,s.useCallback)((function(){var e=Q(Q({},(0,L.GL)(j,["name"])),{},{end_datetime:null,interval_type:null,interval_units:null,start_datetime:null,variables:(0,N.e7)(V)});return d._7===z||(e.interval_type=S,e.interval_units=M,e.end_datetime=ae&&null!==pe&&void 0!==pe&&pe.hour&&null!==pe&&void 0!==pe&&pe.minute?"".concat(ae.toISOString().split("T")[0]," ").concat(null===pe||void 0===pe?void 0:pe.hour,":").concat(null===pe||void 0===pe?void 0:pe.minute,":00"):null,e.start_datetime=oe&&null!==be&&void 0!==be&&be.hour&&null!==be&&void 0!==be&&be.minute?"".concat(oe.toISOString().split("T")[0]," ").concat(null===be||void 0===be?void 0:be.hour,":").concat(null===be||void 0===be?void 0:be.minute,":00"):null),ge({backfill:e})}),[ae,oe,S,M,j,V,z,pe,be]),Oe=(0,s.useMemo)((function(){return d._7===z?!O:!(ae&&oe&&S&&M)}),[O,ae,oe,S,M,z,pe,be]);return(0,H.jsxs)(m.Z,{breadcrumbs:[{label:function(){return"Backfills"},linkProps:{as:"/pipelines/".concat(A,"/backfills"),href:"/pipelines/[pipeline]/backfills"}},{label:function(){return null===j||void 0===j?void 0:j.name},linkProps:{as:"/pipelines/".concat(A,"/backfills/").concat(I),href:"/pipelines/[pipeline]/backfills/[...slug]"}}],errors:t,pageName:C.M.BACKFILLS,pipeline:l,setErrors:a,subheader:(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(p.Z,{disabled:Oe,loading:Ze,onClick:ye,outline:!0,primary:!0,children:"Save changes"}),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(p.Z,{linkProps:{href:"/pipelines/[pipeline]/backfills/[...slug]",as:"/pipelines/".concat(A,"/backfills/").concat(I)},noHoverUnderline:!0,outline:!0,sameColorAsText:!0,children:"Cancel"})]}),title:function(){return"Edit ".concat(null===j||void 0===j?void 0:j.name)},uuid:"backfill/edit",children:[(0,H.jsxs)(y.Z,{p:D.cd,children:[(0,H.jsxs)(y.Z,{mb:2,children:[(0,H.jsx)(b.Z,{children:"Backfill type"}),(0,H.jsx)(_.ZP,{muted:!0,children:"How would you like this pipeline to be backfilled?"})]}),(0,H.jsx)(v.Z,{children:G.map((function(e){var n=e.label,t=e.description,r=e.uuid,i=z===r,l=z&&!i;return(0,H.jsx)(p.Z,{noBackground:!0,noBorder:!0,noPadding:!0,onClick:function(){X(r)},children:(0,H.jsx)(q.U,{selected:i,children:(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(J.Z,{children:(0,H.jsx)("input",{checked:i,type:"radio"})}),(0,H.jsx)(y.Z,{mr:D.cd}),(0,H.jsxs)(J.Z,{alignItems:"flex-start",flexDirection:"column",children:[(0,H.jsx)(b.Z,{bold:!0,default:!i&&!l,level:5,muted:!i&&l,children:n()}),(0,H.jsx)(_.ZP,{default:!i&&!l,leftAligned:!0,muted:l,children:t()})]})]})})},r)}))})]}),(0,H.jsx)(y.Z,{mt:5,children:me})]})},ee=t(41788);function ne(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function te(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?ne(Object(t),!0).forEach((function(n){(0,l.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):ne(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function re(e){var n=e.backfillId,t=e.pipelineUUID,r=e.subpath,i=(0,s.useState)(null),l=i[0],a=i[1],c=P.ZP.variables.pipelines.list(t,{},{revalidateOnFocus:!1}).data,o=(0,s.useMemo)((function(){return null===c||void 0===c?void 0:c.variables}),[c]),u=P.ZP.pipelines.detail(t,{includes_content:!1,includes_outputs:!1},{revalidateOnFocus:!1}).data,d=(0,s.useMemo)((function(){return te(te({},null===u||void 0===u?void 0:u.pipeline),{},{uuid:t})}),[u,t]),p=P.ZP.backfills.detail(n,{include_preview_runs:!0}),f=p.data,v=p.mutate,b=(0,s.useMemo)((function(){return null===f||void 0===f?void 0:f.backfill}),[f]);return"edit"===r?(0,H.jsx)($,{backfill:b,errors:l,fetchBackfill:v,pipeline:d,setErrors:a,variables:o}):(0,H.jsx)(z,{backfill:b,errors:l,fetchBackfill:v,pipeline:d,setErrors:a,variables:o})}re.getInitialProps=function(){var e=(0,i.Z)(c().mark((function e(n){var t,i,l,a,s,o;return c().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t=n.query,i=t.pipeline,l=t.slug,!Array.isArray(l)){e.next=4;break}return a=(0,r.Z)(l,2),s=a[0],o=a[1],e.abrupt("return",{backfillId:s,pipelineUUID:i,subpath:o});case 4:return e.abrupt("return",{pipelineUUID:i});case 5:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}();var ie=(0,ee.Z)(re)},53664:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/pipelines/[pipeline]/backfills/[...slug]",function(){return t(12625)}])}},function(e){e.O(0,[844,7607,5896,4804,1774,9350,5872,4495,1424,1005,8180,547,8957,1286,8312,9774,2888,179],(function(){return n=53664,e(e.s=n);var n}));var n=e.O();_N_E=n}]);
1
+ (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6780],{2850:function(e,n,t){"use strict";t.d(n,{M:function(){return a},W:function(){return l}});var r=t(9518),i=t(3055),l=34*t(49125).iI,a=r.default.div.withConfig({displayName:"indexstyle__BeforeStyle",componentId:"sc-12ee2ib-0"})(["min-height:calc(100vh - ","px);"],i.Mz)},56681:function(e,n,t){"use strict";t.d(n,{G7:function(){return y},ZP:function(){return O},u$:function(){return x}});var r=t(75582),i=t(82394),l=t(26304),a=t(32316),c=t(22673),s=t(48957),o=t(86673),u=t(19711),d=t(58180),p=t(49125),f=t(19395),v=t(7715),b=t(28598),h=["height","heightOffset","pipeline","selectedRun","selectedTab","setSelectedTab"];function m(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function j(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?m(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):m(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var x=76,g={uuid:"Run details"},Z={uuid:"Dependency tree"},y=[Z,g];function O(e){var n=e.height,t=e.heightOffset,i=e.pipeline,m=e.selectedRun,O=e.selectedTab,k=e.setSelectedTab,_=j({},(0,l.Z)(e,h));m?_.blockStatus=(0,f.IJ)(null===m||void 0===m?void 0:m.block_runs):_.noStatus=!0;var P=(0,v.Kn)(null===m||void 0===m?void 0:m.variables)?j({},null===m||void 0===m?void 0:m.variables):(null===m||void 0===m?void 0:m.variables)||{},I=null===m||void 0===m?void 0:m.event_variables;if(I&&(0,v.Kn)(I)&&!(0,v.Qr)(I))if((0,v.Kn)(P)&&P.hasOwnProperty("event")){var w=(0,v.Kn)(P.event)?P.event:{};P.event=j(j({},w),I)}else P.event=j({},I);var S=[];P&&JSON.stringify(P,null,2).split("\n").forEach((function(e){S.push(" ".concat(e))}));var D=m&&[["Run ID",null===m||void 0===m?void 0:m.id],["Variables",(0,b.jsx)(c.Z,{language:"json",small:!0,source:S.join("\n")},"variable_value")]],C=m&&(0,b.jsx)(o.Z,{pb:p.cd,px:p.cd,children:(0,b.jsx)(d.Z,{alignTop:!0,columnFlex:[null,1],columnMaxWidth:function(e){return 1===e?"100px":null},rows:D.map((function(e,n){var t=(0,r.Z)(e,2),i=t[0],l=t[1];return[(0,b.jsx)(u.ZP,{monospace:!0,muted:!0,children:i},"key_".concat(n)),(0,b.jsx)(u.ZP,{monospace:!0,textOverflow:!0,children:l},"val_".concat(n))]})),uuid:"LogDetail"})}),E=O&&k;return(0,b.jsxs)(b.Fragment,{children:[E&&(0,b.jsx)(o.Z,{py:p.cd,children:(0,b.jsx)(a.Z,{onClickTab:k,selectedTabUUID:null===O||void 0===O?void 0:O.uuid,tabs:y})}),(!E||Z.uuid===(null===O||void 0===O?void 0:O.uuid))&&(0,b.jsx)(s.Z,j(j({},_),{},{height:n,heightOffset:(t||0)+(E?x:0),pipeline:i})),g.uuid===(null===O||void 0===O?void 0:O.uuid)&&C]})}},58122:function(e,n,t){"use strict";t.d(n,{CL:function(){return f},FS:function(){return v},JZ:function(){return h},e7:function(){return m},v0:function(){return p},wx:function(){return b}});var r=t(75582),i=t(82394),l=t(43313),a=t(93348),c=t(1286),s=t(90211),o=t(84779);function u(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function d(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?u(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):u(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function p(e){var n=e.statistics,t=Object.keys(n),r=Array(l.Dy.length).fill(0);return 0===t.length?null:(t.forEach((function(e){if(l.Dy.includes(e)){var t=l.CC[e],i=n[e],a=i,c=!1,s=[2,3],u=l.Ub[e],d=l.oH[e],p=l.OD[e];if(l.y_.includes(e))c=!0,s=[2,1,2];else if(e in l.Sq){i=(0,o.Jw)(i,0);var f=l.Sq[e];a=n[f]}var v={columnFlexNumbers:s,name:t,progress:c,rate:a,successDirection:d,warning:p};l.y_.includes(e)||(v.value=i),r[u]=v}})),r)}function f(e){var n=e.columnTypes,t=void 0===n?{}:n,r=e.statistics,i=Object.keys(r);if(0===i.length)return null;var a=Object.values(t),o=a.length,u=[];u.push({name:"Column count",successDirection:l.oH.column_count,value:(0,s.x6)(o)}),i.forEach((function(e){if(l.Zu.includes(e)){var n=l.CC[e],t=r[e],i=l.OD[e];u.push({name:n,successDirection:l.oH[e],value:(0,s.x6)(t),warning:i})}}));var d=(0,c.QO)(a),p=d.countCategory,f=d.countDatetime,v=d.countNumerical;return u.push({name:"Categorical Features",rate:p/o,value:(0,s.x6)(p)},{name:"Numerical Features",rate:v/o,value:(0,s.x6)(v)},{name:"Datetime Features",rate:f/o,value:(0,s.x6)(f)}),u}function v(e){return"string"===typeof e?e:JSON.stringify(e)}function b(e,n){var t,r;return null===e||void 0===e||null===(t=e.find((function(e){var t=e.block;return n(t)})))||void 0===t||null===(r=t.variables)||void 0===r?void 0:r.map((function(e){var n=e.value;return d(d({},e),{},{value:v(n)})}))}function h(e,n){return n===a.Xm.TIME?e.push({uuid:"execution_date",value:"<run datetime>"}):n===a.Xm.EVENT&&e.push({uuid:"event",value:"<trigger event>"}),e}function m(e){return e?Object.entries(e).reduce((function(e,n){var t=(0,r.Z)(n,2),l=t[0],a=t[1],c=a;try{c=JSON.parse(a)}catch(s){}return d(d({},e),{},(0,i.Z)({},l,c))}),{}):e}},18025:function(e,n,t){"use strict";t.d(n,{J:function(){return s},U:function(){return c}});var r=t(9518),i=t(23831),l=t(73942),a=t(49125),c=r.default.div.withConfig({displayName:"indexstyle__CardStyle",componentId:"sc-m7tlau-0"})(["border-radius:","px;border-style:solid;border-width:2px;height:","px;margin-right:","px;padding:","px;width:","px;"," ",""],l.TR,14*a.iI,a.cd*a.iI,a.cd*a.iI,40*a.iI,(function(e){return!e.selected&&"\n border-color: ".concat((e.theme.borders||i.Z.borders).light,";\n ")}),(function(e){return e.selected&&"\n border-color: ".concat((e.theme.interactive||i.Z.interactive).linkPrimary,";\n ")})),s=r.default.div.withConfig({displayName:"indexstyle__DateSelectionContainer",componentId:"sc-m7tlau-1"})(["border-radius:","px;padding:","px;"," "," ",""],l.n_,a.tr,(function(e){return"\n background-color: ".concat((e.theme.interactive||i.Z.interactive).defaultBackground,";\n ")}),(function(e){return e.absolute&&"\n position: absolute;\n z-index: 2;\n right: 0;\n top: ".concat(2.5*a.iI,"px;\n ")}),(function(e){return e.topPosition&&"\n top: -".concat(42*a.iI,"px;\n ")}))},43526:function(e,n,t){"use strict";t.d(n,{I7:function(){return r},IB:function(){return s},VV:function(){return l},_7:function(){return a},rn:function(){return c}});var r,i=t(66050),l="datetime",a="code",c=i.V;!function(e){e.SECOND="second",e.MINUTE="minute",e.HOUR="hour",e.DAY="day",e.WEEK="week",e.MONTH="month",e.YEAR="year",e.CUSTOM="custom"}(r||(r={}));var s=[r.MINUTE,r.HOUR,r.DAY,r.WEEK,r.MONTH,r.YEAR,r.CUSTOM]},52769:function(e,n,t){"use strict";t.d(n,{C:function(){return r}});var r="global"},2713:function(e,n,t){"use strict";var r=t(82394),i=t(44495),l=t(67971),a=t(55378),c=t(86673),s=t(19711),o=t(18025),u=t(49125),d=t(24224),p=t(28598);function f(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function v(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?f(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):f(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}n.Z=function(e){var n=e.selectedDate,t=e.selectedTime,r=e.setSelectedDate,f=e.setSelectedTime,b=e.topPosition;return(0,p.jsxs)(o.J,{absolute:!0,topPosition:b,children:[(0,p.jsx)(i.ZP,{onChange:r,value:n}),(0,p.jsx)(c.Z,{mb:2}),(0,p.jsxs)(l.Z,{alignItems:"center",children:[(0,p.jsx)(s.ZP,{default:!0,large:!0,children:"Time (UTC):"}),(0,p.jsx)(c.Z,{pr:2}),(0,p.jsx)(a.Z,{compact:!0,monospace:!0,onChange:function(e){e.preventDefault(),f((function(n){return v(v({},n),{},{hour:e.target.value})}))},paddingRight:5*u.iI,placeholder:"HH",value:null===t||void 0===t?void 0:t.hour,children:(0,d.m5)(24,0).map((function(e){return String(e).padStart(2,"0")})).map((function(e){return(0,p.jsx)("option",{value:e,children:e},"hour_".concat(e))}))}),(0,p.jsx)(c.Z,{px:1,children:(0,p.jsx)(s.ZP,{bold:!0,large:!0,children:":"})}),(0,p.jsx)(a.Z,{compact:!0,monospace:!0,onChange:function(e){e.preventDefault(),f((function(n){return v(v({},n),{},{minute:e.target.value})}))},paddingRight:5*u.iI,placeholder:"MM",value:null===t||void 0===t?void 0:t.minute,children:(0,d.m5)(60,0).map((function(e){return String(e).padStart(2,"0")})).map((function(e){return(0,p.jsx)("option",{value:e,children:e},"minute_".concat(e))}))})]})]})}},22673:function(e,n,t){"use strict";var r=t(82684),i=t(68792),l=t(31811),a=t(9518),c=t(65292),s=t(23831),o=t(2005),u=t(49125),d=t(28598);n.Z=function(e){var n=e.language,t=e.maxWidth,p=e.showLineNumbers,f=e.small,v=e.source,b=e.wrapLines,h=(0,r.useContext)(a.ThemeContext);function m(e){var r=e.value;return(0,d.jsx)(l.Z,{customStyle:{backgroundColor:(h.background||s.Z.background).popup,border:"none",borderRadius:"none",boxShadow:"none",fontFamily:o.Vp,fontSize:f?12:14,marginBottom:0,marginTop:0,maxWidth:t,paddingBottom:2*u.iI,paddingTop:2*u.iI},language:n,lineNumberStyle:{color:(h.content||s.Z.content).muted},showLineNumbers:p,style:c._4,useInlineStyles:!0,wrapLines:b,children:r})}return(0,d.jsx)(i.D,{components:{code:function(e){var n=e.children;return(0,d.jsx)(m,{value:n})}},children:v})}},32316:function(e,n,t){"use strict";t.d(n,{Z:function(){return h}});var r=t(82684),i=t(60328),l=t(67971),a=t(882),c=t(86673),s=t(19711),o=t(99994),u=t(9518),d=t(49125),p=t(37391),f=u.default.div.withConfig({displayName:"indexstyle__TabsContainerStyle",componentId:"sc-segf7l-0"})(["padding-left:","px;padding-right:","px;"," "," ",""],d.cd*d.iI,d.cd*d.iI,(function(e){return e.noPadding&&"\n padding: 0;\n "}),(function(e){return e.allowScroll&&"\n overflow: auto;\n "}),p.w5),v=t(66653),b=t(28598);var h=function(e){var n=e.allowScroll,t=e.contained,u=e.noPadding,p=e.onClickTab,h=e.selectedTabUUID,m=e.small,j=e.tabs,x=(0,r.useMemo)((function(){var e=j.length,n=[];return j.forEach((function(t,r){var u=t.Icon,f=t.IconSelected,j=t.label,x=t.uuid,g=x===h,Z=g&&f||u,y=j?j():x,O=(0,b.jsxs)(l.Z,{alignItems:"center",children:[Z&&(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)(Z,{default:!g,size:2*d.iI}),(0,b.jsx)(c.Z,{mr:1})]}),(0,b.jsx)(s.ZP,{bold:!0,default:!g,noWrapping:!0,small:!0,children:y})]});r>=1&&e>=2&&n.push((0,b.jsx)("div",{style:{marginLeft:1.5*d.iI}},"spacing-".concat(x))),g?n.push((0,b.jsx)(a.Z,{backgroundGradient:o.yr,backgroundPanel:!0,borderLess:!0,borderWidth:2,compact:m,onClick:function(e){(0,v.j)(e),p(t)},paddingUnitsHorizontal:2,paddingUnitsVertical:1.25,small:m,children:O},x)):n.push((0,b.jsx)("div",{style:{padding:2},children:(0,b.jsx)(i.Z,{borderLess:!0,compact:m,default:!0,onClick:function(e){(0,v.j)(e),p(t)},outline:!0,small:m,children:O})},"button-tab-".concat(x)))})),n}),[p,h,m,j]),g=(0,b.jsx)(l.Z,{alignItems:"center",children:x});return t?g:(0,b.jsx)(f,{allowScroll:n,noPadding:u,children:g})}},12625:function(e,n,t){"use strict";t.r(n),t.d(n,{default:function(){return ie}});var r=t(75582),i=t(77837),l=t(82394),a=t(38860),c=t.n(a),s=t(82684),o=t(83455),u=t(34376),d=t(43526),p=t(60328),f=t(34744),v=t(67971),b=t(87372),h=t(51099),m=t(60547),j=t(97496),x=t(47409),g=t(52769),Z=t(55378),y=t(86673),O=t(54283),k=t(58180),_=t(19711),P=t(82531),I=t(56681),w=t(10503),S=t(2850),D=t(49125),C=t(59920),E=t(90211),N=t(58122),T=t(19395),M=t(33766),L=t(7715),F=t(9736),U=t(96510),A=t(66653),R=t(59e3),H=t(28598);function V(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function B(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?V(Object(t),!0).forEach((function(n){(0,l.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):V(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var z=function(e){var n=e.backfill,t=e.errors,i=e.fetchBackfill,l=e.pipeline,a=e.setErrors,c=e.variables,V=(0,F.Ct)(),z=(0,u.useRouter)(),Y=n||{},W=Y.block_uuid,J=Y.end_datetime,K=Y.id,G=Y.interval_type,q=Y.interval_units,X=Y.name,Q=Y.pipeline_run_dates,$=Y.start_datetime,ee=Y.status,ne=Y.total_run_count,te=Y.variables,re=void 0===te?{}:te,ie=l.uuid,le=(0,R.iV)(),ae={_limit:40,_offset:40*(null!==le&&void 0!==le&&le.page?le.page:0)};null!==le&&void 0!==le&&le.status&&(ae.status=le.status);var ce=P.ZP.pipeline_runs.list(B(B({},ae),{},{backfill_id:K}),{refreshInterval:3e3,revalidateOnFocus:!0},{pauseFetch:!K}),se=ce.data,oe=ce.mutate,ue=!($&&J&&G&&q),de=!ee,pe=(0,s.useMemo)((function(){return(de?Q:null===se||void 0===se?void 0:se.pipeline_runs)||[]}),[se,Q,de]),fe=(0,s.useMemo)((function(){var e;return(null===se||void 0===se||null===(e=se.metadata)||void 0===e?void 0:e.count)||[]}),[se]),ve=(0,s.useState)(null),be=ve[0],he=ve[1],me=(0,s.useMemo)((function(){var e=null!==le&&void 0!==le&&le.page?le.page:0;return(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(j.Z,{disableRowSelect:de,emptyMessage:null!==le&&void 0!==le&&le.status?"No runs available":'No runs available. Please complete backfill configuration by clicking "Edit backfill" above.',fetchPipelineRuns:oe,onClickRow:function(e){return he((function(n){var t=pe[e];return(null===n||void 0===n?void 0:n.id)!==t.id?t:null}))},pipelineRuns:pe,selectedRun:be,setErrors:a}),(0,H.jsx)(y.Z,{p:2,children:(0,H.jsx)(h.Z,{maxPages:9,onUpdate:function(e){var n=Number(e),t=B(B({},le),{},{page:n>=0?n:0});z.push("/pipelines/[pipeline]/backfills/[...slug]","/pipelines/".concat(ie,"/backfills/").concat(K,"?").concat((0,R.uM)(t)))},page:Number(e),totalPages:Math.ceil(fe/40)})})]})}),[oe,K,pe,ie,le,z,be,de,fe]),je=(0,s.useState)(I.G7[0]),xe=je[0],ge=je[1],Ze=(0,o.Db)(P.ZP.backfills.useUpdate(K),{onSuccess:function(e){return(0,U.wD)(e,{callback:function(){i(),oe()},onErrorCallback:function(e,n){return a({errors:n,response:e})}})}}),ye=(0,r.Z)(Ze,2),Oe=ye[0],ke=ye[1].isLoading,_e=(0,s.useMemo)((function(){return!!ee&&(d.rn.CANCELLED!==ee&&d.rn.FAILED!==ee)}),[ee]),Pe=(0,s.useMemo)((function(){return ee&&d.rn.CANCELLED!==ee&&d.rn.FAILED!==ee&&d.rn.INITIAL!==ee&&d.rn.RUNNING!==ee}),[ee]),Ie=(0,s.useMemo)((function(){var e={default:!0,size:1.5*D.iI},n=[[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.VW,B({},e)),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Backfill type"})]},"backfill_type_label"),(0,H.jsx)(_.ZP,{monospace:!0,children:W?d._7:d.VV},"backfill_type")],[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.rs,B({},e)),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Status"})]},"backfill_status_label"),(0,H.jsx)(_.ZP,{danger:d.rn.CANCELLED===ee||d.rn.FAILED==ee,default:d.rn.INITIAL===ee,monospace:!0,muted:!ee,success:d.rn.RUNNING===ee||d.rn.COMPLETED===ee,children:ee||"inactive"},"backfill_status")]];return W||n.push.apply(n,[[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.aw,B({},e)),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Start date and time"})]},"backfill_start_date_label"),(0,H.jsx)(_.ZP,{monospace:!0,children:(0,T.Vx)($)},"backfill_start_date")],[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.aw,B({},e)),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"End date and time"})]},"backfill_end_date_label"),(0,H.jsx)(_.ZP,{monospace:!0,children:(0,T.Vx)(J)},"backfill_end_date")],[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.Pf,B({},e)),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Interval type"})]},"interval_type_label"),(0,H.jsx)(_.ZP,{monospace:!0,children:G&&(0,E.kC)(G)},"interval_type")],[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.Pf,B({},e)),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Interval units"})]},"interval_units_label"),(0,H.jsx)(_.ZP,{monospace:!0,children:q},"interval_units")],[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.qZ,B({},e)),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Total runs"})]},"total_runs_label"),(0,H.jsx)(_.ZP,{monospace:!0,children:ne},"total_runs")]]),(0,H.jsx)(k.Z,{columnFlex:[null,1],rows:n})}),[W,J,G,q,$,ee,ne]),we=(0,s.useMemo)((function(){return re||{}}),[re]),Se=(0,s.useMemo)((function(){var e,n=[];return(0,L.Qr)(we)?n=(0,N.wx)(c,(function(e){return e.uuid===g.C})):Object.entries(we).forEach((function(e){var t=(0,r.Z)(e,2),i=t[0],l=t[1];n.push({uuid:i,value:(0,N.FS)(l)})})),"undefined"!==typeof n&&null!==(e=n)&&void 0!==e&&e.length?(0,H.jsx)(k.Z,{columnFlex:[null,1],rows:n.map((function(e){var n=e.uuid,t=e.value;return[(0,H.jsx)(_.ZP,{default:!0,monospace:!0,small:!0,children:n},"settings_variable_label_".concat(n)),(0,H.jsx)(_.ZP,{monospace:!0,small:!0,children:t},"settings_variable_".concat(n))]}))}):null}),[we,c]);return(0,H.jsx)(H.Fragment,{children:(0,H.jsxs)(m.Z,{afterHidden:!be,before:(0,H.jsxs)(S.M,{children:[(0,H.jsxs)(y.Z,{mb:D.HN,pt:D.cd,px:D.cd,children:[(0,H.jsx)(y.Z,{mb:D.cd,children:(0,H.jsx)(w.yg,{size:5*D.iI})}),(0,H.jsx)(b.Z,{children:X})]}),(0,H.jsx)(y.Z,{px:D.cd,children:(0,H.jsx)(b.Z,{level:5,children:"Settings"})}),(0,H.jsx)(f.Z,{light:!0,mt:1,short:!0}),Ie,Se&&(0,H.jsxs)(y.Z,{my:D.HN,children:[(0,H.jsx)(y.Z,{px:D.cd,children:(0,H.jsx)(b.Z,{level:5,children:"Runtime variables"})}),(0,H.jsx)(f.Z,{light:!0,mt:1,short:!0}),Se]})]}),beforeWidth:34*D.iI,breadcrumbs:[{label:function(){return"Backfills"},linkProps:{as:"/pipelines/".concat(ie,"/backfills"),href:"/pipelines/[pipeline]/backfills"}},{label:function(){return X},linkProps:{as:"/pipelines/".concat(ie,"/backfills/").concat(K),href:"/pipelines/[pipeline]/backfills/[...slug]"}}],buildSidekick:function(e){return(0,I.ZP)(B(B({},e),{},{selectedRun:be,selectedTab:xe,setSelectedTab:ge}))},errors:t,pageName:C.M.BACKFILLS,pipeline:l,setErrors:a,subheader:(0,H.jsxs)(v.Z,{alignItems:"center",children:[!Pe&&(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(p.Z,{beforeIcon:_e?(0,H.jsx)(w.dz,{size:2*D.iI}):(0,H.jsx)(w.Py,{inverted:!(d.rn.CANCELLED===ee||d.rn.FAILED===ee),size:2*D.iI}),danger:_e,disabled:ue,loading:ke,onClick:function(e){(0,A.j)(e),Oe({backfill:{status:_e?d.rn.CANCELLED:d.rn.INITIAL}})},outline:!0,success:!_e&&!(d.rn.CANCELLED===ee||d.rn.FAILED===ee)&&!ue,children:_e?"Cancel backfill":d.rn.CANCELLED===ee||d.rn.FAILED===ee?"Retry backfill":"Start backfill"}),(0,H.jsx)(y.Z,{mr:D.cd})]}),!V&&(0,H.jsxs)(H.Fragment,{children:[ee===x.VO.COMPLETED?(0,H.jsx)(_.ZP,{bold:!0,default:!0,large:!0,children:"Filter runs by status:"}):(0,H.jsx)(p.Z,{linkProps:{as:"/pipelines/".concat(ie,"/backfills/").concat(K,"/edit"),href:"/pipelines/[pipeline]/backfills/[...slug]"},noHoverUnderline:!0,outline:!0,sameColorAsText:!0,children:"Edit backfill"}),(0,H.jsx)(y.Z,{mr:D.cd})]}),!de&&(0,H.jsxs)(Z.Z,{compact:!0,defaultColor:!0,onChange:function(e){e.preventDefault(),"all"===e.target.value?z.push("/pipelines/[pipeline]/backfills/[...slug]","/pipelines/".concat(ie,"/backfills/").concat(K)):(0,M.u7)({page:0,status:e.target.value})},paddingRight:4*D.iI,placeholder:"Select run status",value:(null===le||void 0===le?void 0:le.status)||"all",children:[(0,H.jsx)("option",{value:"all",children:"All statuses"},"all_statuses"),Object.values(x.VO).map((function(e){return(0,H.jsx)("option",{value:e,children:x.Do[e]},e)}))]})]}),title:function(){return X},uuid:"backfill/detail",children:[(0,H.jsx)(y.Z,{mt:D.cd,px:D.cd,children:(0,H.jsx)(b.Z,{level:5,children:"Runs for this backfill"})}),(0,H.jsx)(f.Z,{light:!0,mt:D.cd,short:!0}),se?me:(0,H.jsx)(y.Z,{m:2,children:(0,H.jsx)(O.Z,{inverted:!0})})]})})},Y=t(2713),W=t(47999),J=t(93461),K=t(82944),G=[{label:function(){return"Date and time window"},description:function(){return"Backfill between a date and time range."},uuid:d.VV}],q=t(18025);function X(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function Q(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?X(Object(t),!0).forEach((function(n){(0,l.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):X(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var $=function(e){var n=e.backfill,t=e.errors,i=e.fetchBackfill,l=e.pipeline,a=e.setErrors,c=(e.variables,(0,u.useRouter)()),h=(0,s.useState)(),j=h[0],x=h[1],g=j||{},O=g.block_uuid,I=g.id,S=g.interval_type,M=g.interval_units,F=(g.end_datetime,g.start_datetime,g.name),A=l.uuid,R=(0,s.useState)({}),V=R[0],B=(R[1],(0,s.useState)(O?d._7:d.VV)),z=B[0],X=B[1],$=(0,s.useState)(!1),ee=$[0],ne=$[1],te=(0,s.useState)(!1),re=te[0],ie=te[1],le=(0,s.useState)(null),ae=le[0],ce=le[1],se=(0,s.useState)(null),oe=se[0],ue=se[1],de=(0,s.useState)({hour:"00",minute:"00"}),pe=de[0],fe=de[1],ve=(0,s.useState)({hour:"00",minute:"00"}),be=ve[0],he=ve[1];(0,s.useEffect)((function(){if(n){x(n);var e=n.start_datetime;if(e){var t=e.split(" ")[1];ue((0,T.eI)(e)),he({hour:t.substring(0,2),minute:t.substring(3,5)})}var r=n.end_datetime;if(r){var i=r.split(" ")[1];ce((0,T.eI)(r)),fe({hour:i.substring(0,2),minute:i.substring(3,5)})}}}),[n]);var me=(0,s.useMemo)((function(){var e=[[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.KJ,{default:!0,size:1.5*D.iI}),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Backfill name"})]},"model_name_detail"),(0,H.jsx)(K.Z,{monospace:!0,onChange:function(e){e.preventDefault(),x((function(n){return Q(Q({},n),{},{name:e.target.value})}))},placeholder:"Name this backfill",value:F},"model_name_input_detail")]];return d.VV===z&&e.push.apply(e,[[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.aw,{default:!0,size:1.5*D.iI}),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Start date and time"})]},"start_time"),(0,H.jsxs)("div",{style:{minHeight:"".concat(5.75*D.iI,"px")},children:[!ee&&(0,H.jsx)(K.Z,{monospace:!0,onClick:function(){return ne((function(e){return!e}))},onFocus:function(){return ne(!0)},placeholder:"YYYY-MM-DD HH:MM",value:oe?"".concat(oe.toISOString().split("T")[0]," ").concat(null===be||void 0===be?void 0:be.hour,":").concat(null===be||void 0===be?void 0:be.minute):""}),(0,H.jsx)("div",{style:{width:"400px"},children:(0,H.jsx)(W.Z,{disableEscape:!0,onClickOutside:function(){return ne(!1)},open:ee,style:{position:"relative"},children:(0,H.jsx)(Y.Z,{selectedDate:oe,selectedTime:be,setSelectedDate:ue,setSelectedTime:he,topPosition:!0})})})]},"start_time_input")],[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.aw,{default:!0,size:1.5*D.iI}),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"End date and time"})]},"end_time"),(0,H.jsxs)("div",{style:{minHeight:"".concat(5.75*D.iI,"px")},children:[!re&&(0,H.jsx)(K.Z,{monospace:!0,onClick:function(){return ie((function(e){return!e}))},onFocus:function(){return ie(!0)},placeholder:"YYYY-MM-DD HH:MM",value:ae?"".concat(ae.toISOString().split("T")[0]," ").concat(null===pe||void 0===pe?void 0:pe.hour,":").concat(null===pe||void 0===pe?void 0:pe.minute):""}),(0,H.jsx)("div",{style:{width:"400px"},children:(0,H.jsx)(W.Z,{disableEscape:!0,onClickOutside:function(){return ie(!1)},open:re,style:{position:"relative"},children:(0,H.jsx)(Y.Z,{selectedDate:ae,selectedTime:pe,setSelectedDate:ce,setSelectedTime:fe,topPosition:!0})})})]},"end_time_input")],[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.Pf,{default:!0,size:1.5*D.iI}),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Interval type"})]},"interval_type"),(0,H.jsx)(Z.Z,{monospace:!0,onChange:function(e){e.preventDefault(),x((function(n){return Q(Q({},n),{},{interval_type:e.target.value})}))},placeholder:"Time spacing between each backfill",value:S,children:d.IB.map((function(e){return(0,H.jsx)("option",{value:e,children:(0,E.kC)(e)},e)}))},"interval_type_input")],[(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(w.Pf,{default:!0,size:1.5*D.iI}),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(_.ZP,{default:!0,children:"Interval units"})]},"interval_units"),(0,H.jsx)(K.Z,{disabled:!S,monospace:!0,onChange:function(e){e.preventDefault(),x((function(n){return Q(Q({},n),{},{interval_units:e.target.value})}))},placeholder:S?"Number of ".concat(S).concat(S!==d.I7.CUSTOM?"s":""," between each backfill"):"Interval type is required",type:"number",value:M},"interval_unit_input")]]),(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(y.Z,{mb:2,px:D.cd,children:(0,H.jsx)(b.Z,{children:"Settings"})}),(0,H.jsx)(f.Z,{light:!0,short:!0}),(0,H.jsx)(k.Z,{columnFlex:[null,1],rows:e})]})}),[ae,oe,S,M,F,z,ee,re,pe,be]),je=(0,o.Db)(P.ZP.backfills.useUpdate(I),{onSuccess:function(e){return(0,U.wD)(e,{callback:function(){i(),c.push("/pipelines/[pipeline]/backfills/[...slug]","/pipelines/".concat(A,"/backfills/").concat(I))},onErrorCallback:function(e,n){return a({errors:n,response:e})}})}}),xe=(0,r.Z)(je,2),ge=xe[0],Ze=xe[1].isLoading,ye=(0,s.useCallback)((function(){var e=Q(Q({},(0,L.GL)(j,["name"])),{},{end_datetime:null,interval_type:null,interval_units:null,start_datetime:null,variables:(0,N.e7)(V)});return d._7===z||(e.interval_type=S,e.interval_units=M,e.end_datetime=ae&&null!==pe&&void 0!==pe&&pe.hour&&null!==pe&&void 0!==pe&&pe.minute?"".concat(ae.toISOString().split("T")[0]," ").concat(null===pe||void 0===pe?void 0:pe.hour,":").concat(null===pe||void 0===pe?void 0:pe.minute,":00"):null,e.start_datetime=oe&&null!==be&&void 0!==be&&be.hour&&null!==be&&void 0!==be&&be.minute?"".concat(oe.toISOString().split("T")[0]," ").concat(null===be||void 0===be?void 0:be.hour,":").concat(null===be||void 0===be?void 0:be.minute,":00"):null),ge({backfill:e})}),[ae,oe,S,M,j,V,z,pe,be]),Oe=(0,s.useMemo)((function(){return d._7===z?!O:!(ae&&oe&&S&&M)}),[O,ae,oe,S,M,z,pe,be]);return(0,H.jsxs)(m.Z,{breadcrumbs:[{label:function(){return"Backfills"},linkProps:{as:"/pipelines/".concat(A,"/backfills"),href:"/pipelines/[pipeline]/backfills"}},{label:function(){return null===j||void 0===j?void 0:j.name},linkProps:{as:"/pipelines/".concat(A,"/backfills/").concat(I),href:"/pipelines/[pipeline]/backfills/[...slug]"}}],errors:t,pageName:C.M.BACKFILLS,pipeline:l,setErrors:a,subheader:(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(p.Z,{disabled:Oe,loading:Ze,onClick:ye,outline:!0,primary:!0,children:"Save changes"}),(0,H.jsx)(y.Z,{mr:1}),(0,H.jsx)(p.Z,{linkProps:{href:"/pipelines/[pipeline]/backfills/[...slug]",as:"/pipelines/".concat(A,"/backfills/").concat(I)},noHoverUnderline:!0,outline:!0,sameColorAsText:!0,children:"Cancel"})]}),title:function(){return"Edit ".concat(null===j||void 0===j?void 0:j.name)},uuid:"backfill/edit",children:[(0,H.jsxs)(y.Z,{p:D.cd,children:[(0,H.jsxs)(y.Z,{mb:2,children:[(0,H.jsx)(b.Z,{children:"Backfill type"}),(0,H.jsx)(_.ZP,{muted:!0,children:"How would you like this pipeline to be backfilled?"})]}),(0,H.jsx)(v.Z,{children:G.map((function(e){var n=e.label,t=e.description,r=e.uuid,i=z===r,l=z&&!i;return(0,H.jsx)(p.Z,{noBackground:!0,noBorder:!0,noPadding:!0,onClick:function(){X(r)},children:(0,H.jsx)(q.U,{selected:i,children:(0,H.jsxs)(v.Z,{alignItems:"center",children:[(0,H.jsx)(J.Z,{children:(0,H.jsx)("input",{checked:i,type:"radio"})}),(0,H.jsx)(y.Z,{mr:D.cd}),(0,H.jsxs)(J.Z,{alignItems:"flex-start",flexDirection:"column",children:[(0,H.jsx)(b.Z,{bold:!0,default:!i&&!l,level:5,muted:!i&&l,children:n()}),(0,H.jsx)(_.ZP,{default:!i&&!l,leftAligned:!0,muted:l,children:t()})]})]})})},r)}))})]}),(0,H.jsx)(y.Z,{mt:5,children:me})]})},ee=t(41788);function ne(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function te(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?ne(Object(t),!0).forEach((function(n){(0,l.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):ne(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function re(e){var n=e.backfillId,t=e.pipelineUUID,r=e.subpath,i=(0,s.useState)(null),l=i[0],a=i[1],c=P.ZP.variables.pipelines.list(t,{},{revalidateOnFocus:!1}).data,o=(0,s.useMemo)((function(){return null===c||void 0===c?void 0:c.variables}),[c]),u=P.ZP.pipelines.detail(t,{includes_content:!1,includes_outputs:!1},{revalidateOnFocus:!1}).data,d=(0,s.useMemo)((function(){return te(te({},null===u||void 0===u?void 0:u.pipeline),{},{uuid:t})}),[u,t]),p=P.ZP.backfills.detail(n,{include_preview_runs:!0}),f=p.data,v=p.mutate,b=(0,s.useMemo)((function(){return null===f||void 0===f?void 0:f.backfill}),[f]);return"edit"===r?(0,H.jsx)($,{backfill:b,errors:l,fetchBackfill:v,pipeline:d,setErrors:a,variables:o}):(0,H.jsx)(z,{backfill:b,errors:l,fetchBackfill:v,pipeline:d,setErrors:a,variables:o})}re.getInitialProps=function(){var e=(0,i.Z)(c().mark((function e(n){var t,i,l,a,s,o;return c().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t=n.query,i=t.pipeline,l=t.slug,!Array.isArray(l)){e.next=4;break}return a=(0,r.Z)(l,2),s=a[0],o=a[1],e.abrupt("return",{backfillId:s,pipelineUUID:i,subpath:o});case 4:return e.abrupt("return",{pipelineUUID:i});case 5:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}();var ie=(0,ee.Z)(re)},53664:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/pipelines/[pipeline]/backfills/[...slug]",function(){return t(12625)}])}},function(e){e.O(0,[844,7607,5896,4804,1774,9350,5872,4495,1424,1005,8180,547,3714,8957,1286,8312,9774,2888,179],(function(){return n=53664,e(e.s=n);var n}));var n=e.O();_N_E=n}]);