mage-ai 0.9.46__py3-none-any.whl → 0.9.48__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 (405) hide show
  1. mage_ai/api/operations/base.py +27 -5
  2. mage_ai/api/policies/GlobalHookPolicy.py +1 -1
  3. mage_ai/api/policies/IntegrationSourcePolicy.py +62 -0
  4. mage_ai/api/policies/OauthPolicy.py +6 -6
  5. mage_ai/api/presenters/GlobalHookPresenter.py +1 -1
  6. mage_ai/api/presenters/IntegrationSourcePresenter.py +9 -2
  7. mage_ai/api/presenters/PipelinePresenter.py +3 -0
  8. mage_ai/api/presenters/PipelineRunPresenter.py +8 -3
  9. mage_ai/api/presenters/PipelineSchedulePresenter.py +22 -1
  10. mage_ai/api/resources/BlockResource.py +5 -0
  11. mage_ai/api/resources/DataProviderResource.py +2 -0
  12. mage_ai/api/resources/IntegrationSourceResource.py +149 -2
  13. mage_ai/data_integrations/sources/constants.py +5 -0
  14. mage_ai/data_integrations/utils/scheduler.py +57 -2
  15. mage_ai/data_preparation/executors/block_executor.py +30 -2
  16. mage_ai/data_preparation/executors/pipeline_executor.py +19 -4
  17. mage_ai/data_preparation/models/block/__init__.py +75 -32
  18. mage_ai/data_preparation/models/block/data_integration/constants.py +3 -0
  19. mage_ai/data_preparation/models/block/data_integration/mixins.py +6 -6
  20. mage_ai/data_preparation/models/block/data_integration/utils.py +198 -39
  21. mage_ai/data_preparation/models/block/sql/bigquery.py +2 -2
  22. mage_ai/data_preparation/models/block/sql/snowflake.py +2 -2
  23. mage_ai/data_preparation/models/block/sql/trino.py +2 -2
  24. mage_ai/data_preparation/models/block/sql/utils/shared.py +20 -3
  25. mage_ai/data_preparation/models/block/utils.py +53 -29
  26. mage_ai/data_preparation/models/global_hooks/constants.py +50 -1
  27. mage_ai/data_preparation/models/global_hooks/models.py +148 -84
  28. mage_ai/data_preparation/models/global_hooks/predicates.py +316 -0
  29. mage_ai/data_preparation/models/pipeline.py +7 -0
  30. mage_ai/data_preparation/models/pipelines/integration_pipeline.py +0 -1
  31. mage_ai/data_preparation/models/project/__init__.py +0 -2
  32. mage_ai/data_preparation/preferences.py +29 -18
  33. mage_ai/data_preparation/repo_manager.py +12 -2
  34. mage_ai/data_preparation/sync/__init__.py +2 -0
  35. mage_ai/data_preparation/templates/constants.py +14 -0
  36. mage_ai/data_preparation/templates/data_exporters/chroma.py +24 -0
  37. mage_ai/data_preparation/templates/data_exporters/streaming/rabbitmq.yaml +7 -0
  38. mage_ai/data_preparation/templates/data_loaders/chroma.py +27 -0
  39. mage_ai/data_preparation/templates/repo/io_config.yaml +3 -0
  40. mage_ai/io/base.py +1 -0
  41. mage_ai/io/chroma.py +162 -0
  42. mage_ai/io/config.py +8 -0
  43. mage_ai/orchestration/db/models/schedules.py +169 -34
  44. mage_ai/orchestration/pipeline_scheduler.py +59 -89
  45. mage_ai/server/constants.py +1 -1
  46. mage_ai/server/frontend_dist/404.html +2 -2
  47. mage_ai/server/frontend_dist/_next/static/chunks/{1749-9a6276b2918fdae1.js → 1749-bf512b4dabbab7fa.js} +1 -1
  48. mage_ai/server/frontend_dist/_next/static/chunks/1952-0f9a12782f0aaae6.js +1 -0
  49. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/2714-1e79e9f2e998b544.js → frontend_dist/_next/static/chunks/2714-68fef54789d7eaeb.js} +1 -1
  50. mage_ai/server/frontend_dist/_next/static/chunks/2717-14191a781cf2f286.js +1 -0
  51. mage_ai/server/frontend_dist/_next/static/chunks/3419-a7a52bcaaa687b07.js +1 -0
  52. mage_ai/server/frontend_dist/_next/static/chunks/3437-e81a62f33337ca06.js +1 -0
  53. mage_ai/server/frontend_dist/_next/static/chunks/3943-3cb1f765210dd7a4.js +1 -0
  54. mage_ai/server/frontend_dist/_next/static/chunks/4138-2c16e6d2f22246cd.js +1 -0
  55. mage_ai/server/frontend_dist/_next/static/chunks/4267-cb102e060a43d9bd.js +1 -0
  56. mage_ai/server/frontend_dist/_next/static/chunks/{4366-93e09e5a4a7e182c.js → 4366-3e52497942acbafe.js} +1 -1
  57. mage_ai/server/frontend_dist/_next/static/chunks/{4783-1a21d9be47574bba.js → 4783-422429203610c318.js} +1 -1
  58. mage_ai/server/frontend_dist/_next/static/chunks/{5499-76cf8f023c6b0985.js → 5499-c2853ef57d39fde8.js} +1 -1
  59. mage_ai/server/frontend_dist/_next/static/chunks/5810-e26a0768db1cfdba.js +1 -0
  60. mage_ai/server/frontend_dist/_next/static/chunks/{5896-14e5a23b1c6a0769.js → 5896-7b8e36634d7d94eb.js} +1 -1
  61. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/6285-e9b45335bfb9ccaf.js → frontend_dist/_next/static/chunks/6285-648f9a732e100b2f.js} +1 -1
  62. mage_ai/server/frontend_dist/_next/static/chunks/6798-b904395b0c18647b.js +1 -0
  63. mage_ai/server/frontend_dist/_next/static/chunks/6990-303bb87fc50f1755.js +1 -0
  64. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/7022-070ec0144a4d029c.js → frontend_dist/_next/static/chunks/7022-e76cae3ba5ee5312.js} +1 -1
  65. mage_ai/server/frontend_dist/_next/static/chunks/{7361-694e1e4fb9c97d68.js → 7361-6c5c9063b9f91700.js} +1 -1
  66. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/7858-d9df72e95e438284.js → frontend_dist/_next/static/chunks/7858-26a5a5d04fa3c703.js} +1 -1
  67. mage_ai/server/frontend_dist/_next/static/chunks/{8146-92e7ccfed169ee9c.js → 8146-27f0e31f309897a5.js} +1 -1
  68. mage_ai/server/frontend_dist/_next/static/chunks/8264-9d6a7cea289e29ff.js +1 -0
  69. mage_ai/server/frontend_dist/_next/static/chunks/845-9a73c65fe3fdc328.js +1 -0
  70. mage_ai/server/frontend_dist/_next/static/chunks/8487-608d62c0eef1f29a.js +1 -0
  71. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/1845-5ce774d5ab81ed57.js → frontend_dist/_next/static/chunks/8731-2f78ec7b7760be8f.js} +1 -1
  72. mage_ai/server/frontend_dist/_next/static/chunks/90-93d18aaecef0685b.js +1 -0
  73. mage_ai/server/frontend_dist/_next/static/chunks/9264-727704fc34e74ae0.js +1 -0
  74. mage_ai/server/frontend_dist/_next/static/chunks/9618-4eb49cdbd1ba11d7.js +1 -0
  75. mage_ai/server/frontend_dist/_next/static/chunks/9624-48fba6b4e6966fb7.js +1 -0
  76. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/976-18c98af60b76f1a7.js → frontend_dist/_next/static/chunks/976-0a8c2c4d7acd957b.js} +1 -1
  77. mage_ai/server/frontend_dist/_next/static/chunks/pages/_app-8254de4f793643d0.js +1 -0
  78. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/block-layout-a24cb24b6f08bbc9.js → frontend_dist/_next/static/chunks/pages/block-layout-b926f6eb1ee9a53b.js} +1 -1
  79. mage_ai/server/frontend_dist/_next/static/chunks/pages/compute-a9402b51e9fe748e.js +1 -0
  80. mage_ai/server/frontend_dist/_next/static/chunks/pages/files-85cecae037fd7a70.js +1 -0
  81. mage_ai/server/frontend_dist/_next/static/chunks/pages/global-data-products/{[...slug]-cfd68e760ae00958.js → [...slug]-c3c9523ea8072c11.js} +1 -1
  82. mage_ai/server/frontend_dist/_next/static/chunks/pages/{global-data-products-c3b79ef31007f95b.js → global-data-products-4d046f15202a1c8d.js} +1 -1
  83. mage_ai/server/frontend_dist/_next/static/chunks/pages/global-hooks/[...slug]-286133386c97a2b6.js +1 -0
  84. mage_ai/server/frontend_dist/_next/static/chunks/pages/{global-hooks-e561ae38cf5592e8.js → global-hooks-3da370825153056c.js} +1 -1
  85. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/manage/files-449a022f2f0f2d94.js → frontend_dist/_next/static/chunks/pages/manage/files-39b73da5a15590f6.js} +1 -1
  86. mage_ai/server/frontend_dist/_next/static/chunks/pages/manage/{settings-60845f0b59142f32.js → settings-666748ff5d101411.js} +1 -1
  87. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/manage/users/[user]-9384c5f1efa2ac18.js → frontend_dist/_next/static/chunks/pages/manage/users/[user]-be27631e67dbe070.js} +1 -1
  88. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/manage/users/new-abd8571907664fdf.js → frontend_dist/_next/static/chunks/pages/manage/users/new-1932ce64823b372b.js} +1 -1
  89. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/manage/users-28a930b148d99766.js → frontend_dist/_next/static/chunks/pages/manage/users-ed509c75cf23f0f5.js} +1 -1
  90. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/manage-f83deb790548693b.js → frontend_dist/_next/static/chunks/pages/manage-1feebec1124123fc.js} +1 -1
  91. mage_ai/server/frontend_dist/_next/static/chunks/pages/{oauth-8bb62c4f6a511c43.js → oauth-e9b8f19c30381c28.js} +1 -1
  92. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/overview-f0c40645f385f23f.js → frontend_dist/_next/static/chunks/pages/overview-7b2ba2d5405c05fe.js} +1 -1
  93. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipeline-runs-70fc3351bd11025f.js +1 -0
  94. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills/[...slug]-6ee3b88a5bb4ce94.js +1 -0
  95. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills-c9cf383bc13ce7b8.js +1 -0
  96. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/dashboard-571c0962333b92f0.js → frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/dashboard-7bca6f718b939934.js} +1 -1
  97. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/edit-c119f630038b0685.js +1 -0
  98. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/logs-146051325c92d742.js +1 -0
  99. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/monitors/{block-runs-ddddcddd2f74b4f6.js → block-runs-15d307e6ba934a56.js} +1 -1
  100. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runtime-4a238307feddb522.js → frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runtime-f6196e563b960e5c.js} +1 -1
  101. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/monitors-e051057d9fe94f23.js → frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/monitors-25dbd73201d99e80.js} +1 -1
  102. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/runs/[run]-06e55db757959ef8.js +1 -0
  103. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/runs-2d20b2cd08907afd.js → frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/runs-ec3c45cfa027db58.js} +1 -1
  104. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/settings-495e877aa7ed709e.js +1 -0
  105. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/syncs-49adfeed5157d92b.js +1 -0
  106. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/triggers/[...slug]-6143e028225390f5.js +1 -0
  107. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/triggers-0886f6320fef7131.js +1 -0
  108. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines-e82a763d742cc034.js +1 -0
  109. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/account/profile-50d20fa715d454af.js +1 -0
  110. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/permissions/{[...slug]-b78b1be5b9ed84b9.js → [...slug]-2bbd63b7e93a8600.js} +1 -1
  111. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/{permissions-37b78a436eeab258.js → permissions-4ea156c39608caab.js} +1 -1
  112. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/preferences-f3c29ec53ee35795.js +1 -0
  113. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/roles/{[...slug]-db05a80d18c168e5.js → [...slug]-64ec8928d2542f3c.js} +1 -1
  114. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/{roles-f55c77e4f46c8d33.js → roles-835e6ec2a48ec583.js} +1 -1
  115. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/{sync-data-2a1f8737561fdd94.js → sync-data-0769149af025de30.js} +1 -1
  116. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/users/{[...slug]-e3bf6e5d8bb250c4.js → [...slug]-612a65c42bcadef0.js} +1 -1
  117. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/{users-20f0a050a42a015d.js → users-e3365b4029a8db33.js} +1 -1
  118. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/sign-in-99e2748e3c1d57a3.js → frontend_dist/_next/static/chunks/pages/sign-in-f3a33e8f83abdb58.js} +1 -1
  119. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/templates/[...slug]-f44ccd1499ffd23a.js → frontend_dist/_next/static/chunks/pages/templates/[...slug]-f264097bf8120f31.js} +1 -1
  120. mage_ai/server/frontend_dist/_next/static/chunks/pages/{templates-1bfaa1c50e844813.js → templates-406e13cc5c4caab4.js} +1 -1
  121. mage_ai/server/frontend_dist/_next/static/chunks/pages/{terminal-ed121e305169cf1c.js → terminal-ef8ad878e5e7bb2f.js} +1 -1
  122. mage_ai/server/frontend_dist/_next/static/chunks/pages/triggers-a90728798f964700.js +1 -0
  123. mage_ai/server/frontend_dist/_next/static/chunks/pages/version-control-0e0c2713a2922be7.js +1 -0
  124. mage_ai/server/frontend_dist/_next/static/xxcdnITr3IkTdETH5ghqw/_buildManifest.js +1 -0
  125. mage_ai/server/frontend_dist/block-layout.html +2 -2
  126. mage_ai/server/frontend_dist/compute.html +5 -5
  127. mage_ai/server/frontend_dist/files.html +5 -5
  128. mage_ai/server/frontend_dist/global-data-products/[...slug].html +5 -5
  129. mage_ai/server/frontend_dist/global-data-products.html +5 -5
  130. mage_ai/server/frontend_dist/global-hooks/[...slug].html +5 -5
  131. mage_ai/server/frontend_dist/global-hooks.html +5 -5
  132. mage_ai/server/frontend_dist/index.html +2 -2
  133. mage_ai/server/frontend_dist/manage/files.html +5 -5
  134. mage_ai/server/frontend_dist/manage/settings.html +5 -5
  135. mage_ai/server/frontend_dist/manage/users/[user].html +5 -5
  136. mage_ai/server/frontend_dist/manage/users/new.html +5 -5
  137. mage_ai/server/frontend_dist/manage/users.html +5 -5
  138. mage_ai/server/frontend_dist/manage.html +5 -5
  139. mage_ai/server/frontend_dist/oauth.html +4 -4
  140. mage_ai/server/frontend_dist/overview.html +5 -5
  141. mage_ai/server/frontend_dist/pipeline-runs.html +5 -5
  142. mage_ai/server/frontend_dist/pipelines/[pipeline]/backfills/[...slug].html +5 -5
  143. mage_ai/server/frontend_dist/pipelines/[pipeline]/backfills.html +5 -5
  144. mage_ai/server/frontend_dist/pipelines/[pipeline]/dashboard.html +5 -5
  145. mage_ai/server/frontend_dist/pipelines/[pipeline]/edit.html +2 -2
  146. mage_ai/server/frontend_dist/pipelines/[pipeline]/logs.html +5 -5
  147. mage_ai/server/frontend_dist/pipelines/[pipeline]/monitors/block-runs.html +5 -5
  148. mage_ai/server/frontend_dist/pipelines/[pipeline]/monitors/block-runtime.html +5 -5
  149. mage_ai/server/frontend_dist/pipelines/[pipeline]/monitors.html +5 -5
  150. mage_ai/server/frontend_dist/pipelines/[pipeline]/runs/[run].html +5 -5
  151. mage_ai/server/frontend_dist/pipelines/[pipeline]/runs.html +5 -5
  152. mage_ai/server/frontend_dist/pipelines/[pipeline]/settings.html +5 -5
  153. mage_ai/server/frontend_dist/pipelines/[pipeline]/syncs.html +5 -5
  154. mage_ai/server/frontend_dist/pipelines/[pipeline]/triggers/[...slug].html +5 -5
  155. mage_ai/server/frontend_dist/pipelines/[pipeline]/triggers.html +5 -5
  156. mage_ai/server/frontend_dist/pipelines/[pipeline].html +2 -2
  157. mage_ai/server/frontend_dist/pipelines.html +5 -5
  158. mage_ai/server/frontend_dist/settings/account/profile.html +5 -5
  159. mage_ai/server/frontend_dist/settings/workspace/permissions/[...slug].html +5 -5
  160. mage_ai/server/frontend_dist/settings/workspace/permissions.html +5 -5
  161. mage_ai/server/frontend_dist/settings/workspace/preferences.html +5 -5
  162. mage_ai/server/frontend_dist/settings/workspace/roles/[...slug].html +5 -5
  163. mage_ai/server/frontend_dist/settings/workspace/roles.html +5 -5
  164. mage_ai/server/frontend_dist/settings/workspace/sync-data.html +5 -5
  165. mage_ai/server/frontend_dist/settings/workspace/users/[...slug].html +5 -5
  166. mage_ai/server/frontend_dist/settings/workspace/users.html +5 -5
  167. mage_ai/server/frontend_dist/settings.html +2 -2
  168. mage_ai/server/frontend_dist/sign-in.html +24 -24
  169. mage_ai/server/frontend_dist/templates/[...slug].html +5 -5
  170. mage_ai/server/frontend_dist/templates.html +5 -5
  171. mage_ai/server/frontend_dist/terminal.html +5 -5
  172. mage_ai/server/frontend_dist/test.html +5 -5
  173. mage_ai/server/frontend_dist/triggers.html +5 -5
  174. mage_ai/server/frontend_dist/version-control.html +5 -5
  175. mage_ai/server/frontend_dist_base_path_template/404.html +2 -2
  176. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/{1749-9a6276b2918fdae1.js → 1749-bf512b4dabbab7fa.js} +1 -1
  177. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/1952-0f9a12782f0aaae6.js +1 -0
  178. mage_ai/server/{frontend_dist/_next/static/chunks/2714-1e79e9f2e998b544.js → frontend_dist_base_path_template/_next/static/chunks/2714-68fef54789d7eaeb.js} +1 -1
  179. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/2717-14191a781cf2f286.js +1 -0
  180. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3419-a7a52bcaaa687b07.js +1 -0
  181. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3437-e81a62f33337ca06.js +1 -0
  182. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3943-3cb1f765210dd7a4.js +1 -0
  183. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/4138-2c16e6d2f22246cd.js +1 -0
  184. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/4267-cb102e060a43d9bd.js +1 -0
  185. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/{4366-93e09e5a4a7e182c.js → 4366-3e52497942acbafe.js} +1 -1
  186. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/{4783-1a21d9be47574bba.js → 4783-422429203610c318.js} +1 -1
  187. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/{5499-76cf8f023c6b0985.js → 5499-c2853ef57d39fde8.js} +1 -1
  188. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/5810-e26a0768db1cfdba.js +1 -0
  189. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/{5896-14e5a23b1c6a0769.js → 5896-7b8e36634d7d94eb.js} +1 -1
  190. mage_ai/server/{frontend_dist/_next/static/chunks/6285-e9b45335bfb9ccaf.js → frontend_dist_base_path_template/_next/static/chunks/6285-648f9a732e100b2f.js} +1 -1
  191. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/6798-b904395b0c18647b.js +1 -0
  192. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/6990-303bb87fc50f1755.js +1 -0
  193. mage_ai/server/{frontend_dist/_next/static/chunks/7022-070ec0144a4d029c.js → frontend_dist_base_path_template/_next/static/chunks/7022-e76cae3ba5ee5312.js} +1 -1
  194. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/{7361-694e1e4fb9c97d68.js → 7361-6c5c9063b9f91700.js} +1 -1
  195. mage_ai/server/{frontend_dist/_next/static/chunks/7858-d9df72e95e438284.js → frontend_dist_base_path_template/_next/static/chunks/7858-26a5a5d04fa3c703.js} +1 -1
  196. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/{8146-92e7ccfed169ee9c.js → 8146-27f0e31f309897a5.js} +1 -1
  197. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/8264-9d6a7cea289e29ff.js +1 -0
  198. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/845-9a73c65fe3fdc328.js +1 -0
  199. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/8487-608d62c0eef1f29a.js +1 -0
  200. mage_ai/server/{frontend_dist/_next/static/chunks/1845-5ce774d5ab81ed57.js → frontend_dist_base_path_template/_next/static/chunks/8731-2f78ec7b7760be8f.js} +1 -1
  201. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/90-93d18aaecef0685b.js +1 -0
  202. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/9264-727704fc34e74ae0.js +1 -0
  203. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/9618-4eb49cdbd1ba11d7.js +1 -0
  204. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/9624-48fba6b4e6966fb7.js +1 -0
  205. mage_ai/server/{frontend_dist/_next/static/chunks/976-18c98af60b76f1a7.js → frontend_dist_base_path_template/_next/static/chunks/976-0a8c2c4d7acd957b.js} +1 -1
  206. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/_app-8254de4f793643d0.js +1 -0
  207. mage_ai/server/{frontend_dist/_next/static/chunks/pages/block-layout-a24cb24b6f08bbc9.js → frontend_dist_base_path_template/_next/static/chunks/pages/block-layout-b926f6eb1ee9a53b.js} +1 -1
  208. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/compute-a9402b51e9fe748e.js +1 -0
  209. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/files-85cecae037fd7a70.js +1 -0
  210. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/global-data-products/{[...slug]-cfd68e760ae00958.js → [...slug]-c3c9523ea8072c11.js} +1 -1
  211. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/{global-data-products-c3b79ef31007f95b.js → global-data-products-4d046f15202a1c8d.js} +1 -1
  212. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/global-hooks/[...slug]-286133386c97a2b6.js +1 -0
  213. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/{global-hooks-e561ae38cf5592e8.js → global-hooks-3da370825153056c.js} +1 -1
  214. mage_ai/server/{frontend_dist/_next/static/chunks/pages/manage/files-449a022f2f0f2d94.js → frontend_dist_base_path_template/_next/static/chunks/pages/manage/files-39b73da5a15590f6.js} +1 -1
  215. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/manage/{settings-60845f0b59142f32.js → settings-666748ff5d101411.js} +1 -1
  216. mage_ai/server/{frontend_dist/_next/static/chunks/pages/manage/users/[user]-9384c5f1efa2ac18.js → frontend_dist_base_path_template/_next/static/chunks/pages/manage/users/[user]-be27631e67dbe070.js} +1 -1
  217. mage_ai/server/{frontend_dist/_next/static/chunks/pages/manage/users/new-abd8571907664fdf.js → frontend_dist_base_path_template/_next/static/chunks/pages/manage/users/new-1932ce64823b372b.js} +1 -1
  218. mage_ai/server/{frontend_dist/_next/static/chunks/pages/manage/users-28a930b148d99766.js → frontend_dist_base_path_template/_next/static/chunks/pages/manage/users-ed509c75cf23f0f5.js} +1 -1
  219. mage_ai/server/{frontend_dist/_next/static/chunks/pages/manage-f83deb790548693b.js → frontend_dist_base_path_template/_next/static/chunks/pages/manage-1feebec1124123fc.js} +1 -1
  220. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/{oauth-8bb62c4f6a511c43.js → oauth-e9b8f19c30381c28.js} +1 -1
  221. mage_ai/server/{frontend_dist/_next/static/chunks/pages/overview-f0c40645f385f23f.js → frontend_dist_base_path_template/_next/static/chunks/pages/overview-7b2ba2d5405c05fe.js} +1 -1
  222. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipeline-runs-70fc3351bd11025f.js +1 -0
  223. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/backfills/[...slug]-6ee3b88a5bb4ce94.js +1 -0
  224. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/backfills-c9cf383bc13ce7b8.js +1 -0
  225. mage_ai/server/{frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/dashboard-571c0962333b92f0.js → frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/dashboard-7bca6f718b939934.js} +1 -1
  226. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/edit-c119f630038b0685.js +1 -0
  227. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/logs-146051325c92d742.js +1 -0
  228. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/monitors/{block-runs-ddddcddd2f74b4f6.js → block-runs-15d307e6ba934a56.js} +1 -1
  229. mage_ai/server/{frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runtime-4a238307feddb522.js → frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runtime-f6196e563b960e5c.js} +1 -1
  230. mage_ai/server/{frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/monitors-e051057d9fe94f23.js → frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/monitors-25dbd73201d99e80.js} +1 -1
  231. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/runs/[run]-06e55db757959ef8.js +1 -0
  232. mage_ai/server/{frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/runs-2d20b2cd08907afd.js → frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/runs-ec3c45cfa027db58.js} +1 -1
  233. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/settings-495e877aa7ed709e.js +1 -0
  234. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/syncs-49adfeed5157d92b.js +1 -0
  235. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/triggers/[...slug]-6143e028225390f5.js +1 -0
  236. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/triggers-0886f6320fef7131.js +1 -0
  237. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines-e82a763d742cc034.js +1 -0
  238. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/account/profile-50d20fa715d454af.js +1 -0
  239. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/permissions/{[...slug]-b78b1be5b9ed84b9.js → [...slug]-2bbd63b7e93a8600.js} +1 -1
  240. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/{permissions-37b78a436eeab258.js → permissions-4ea156c39608caab.js} +1 -1
  241. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/preferences-f3c29ec53ee35795.js +1 -0
  242. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/roles/{[...slug]-db05a80d18c168e5.js → [...slug]-64ec8928d2542f3c.js} +1 -1
  243. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/{roles-f55c77e4f46c8d33.js → roles-835e6ec2a48ec583.js} +1 -1
  244. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/{sync-data-2a1f8737561fdd94.js → sync-data-0769149af025de30.js} +1 -1
  245. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/users/{[...slug]-e3bf6e5d8bb250c4.js → [...slug]-612a65c42bcadef0.js} +1 -1
  246. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/{users-20f0a050a42a015d.js → users-e3365b4029a8db33.js} +1 -1
  247. mage_ai/server/{frontend_dist/_next/static/chunks/pages/sign-in-99e2748e3c1d57a3.js → frontend_dist_base_path_template/_next/static/chunks/pages/sign-in-f3a33e8f83abdb58.js} +1 -1
  248. mage_ai/server/{frontend_dist/_next/static/chunks/pages/templates/[...slug]-f44ccd1499ffd23a.js → frontend_dist_base_path_template/_next/static/chunks/pages/templates/[...slug]-f264097bf8120f31.js} +1 -1
  249. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/{templates-1bfaa1c50e844813.js → templates-406e13cc5c4caab4.js} +1 -1
  250. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/{terminal-ed121e305169cf1c.js → terminal-ef8ad878e5e7bb2f.js} +1 -1
  251. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/triggers-a90728798f964700.js +1 -0
  252. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/version-control-0e0c2713a2922be7.js +1 -0
  253. mage_ai/server/frontend_dist_base_path_template/_next/static/gDn6inKdLyj35NvURBSCV/_buildManifest.js +1 -0
  254. mage_ai/server/frontend_dist_base_path_template/block-layout.html +2 -2
  255. mage_ai/server/frontend_dist_base_path_template/compute.html +5 -5
  256. mage_ai/server/frontend_dist_base_path_template/files.html +5 -5
  257. mage_ai/server/frontend_dist_base_path_template/global-data-products/[...slug].html +5 -5
  258. mage_ai/server/frontend_dist_base_path_template/global-data-products.html +5 -5
  259. mage_ai/server/frontend_dist_base_path_template/global-hooks/[...slug].html +5 -5
  260. mage_ai/server/frontend_dist_base_path_template/global-hooks.html +5 -5
  261. mage_ai/server/frontend_dist_base_path_template/index.html +2 -2
  262. mage_ai/server/frontend_dist_base_path_template/manage/files.html +5 -5
  263. mage_ai/server/frontend_dist_base_path_template/manage/settings.html +5 -5
  264. mage_ai/server/frontend_dist_base_path_template/manage/users/[user].html +5 -5
  265. mage_ai/server/frontend_dist_base_path_template/manage/users/new.html +5 -5
  266. mage_ai/server/frontend_dist_base_path_template/manage/users.html +5 -5
  267. mage_ai/server/frontend_dist_base_path_template/manage.html +5 -5
  268. mage_ai/server/frontend_dist_base_path_template/oauth.html +4 -4
  269. mage_ai/server/frontend_dist_base_path_template/overview.html +5 -5
  270. mage_ai/server/frontend_dist_base_path_template/pipeline-runs.html +5 -5
  271. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/backfills/[...slug].html +5 -5
  272. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/backfills.html +5 -5
  273. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/dashboard.html +5 -5
  274. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/edit.html +2 -2
  275. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/logs.html +5 -5
  276. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/monitors/block-runs.html +5 -5
  277. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/monitors/block-runtime.html +5 -5
  278. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/monitors.html +5 -5
  279. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/runs/[run].html +5 -5
  280. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/runs.html +5 -5
  281. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/settings.html +5 -5
  282. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/syncs.html +5 -5
  283. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/triggers/[...slug].html +5 -5
  284. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/triggers.html +5 -5
  285. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline].html +2 -2
  286. mage_ai/server/frontend_dist_base_path_template/pipelines.html +5 -5
  287. mage_ai/server/frontend_dist_base_path_template/settings/account/profile.html +5 -5
  288. mage_ai/server/frontend_dist_base_path_template/settings/workspace/permissions/[...slug].html +5 -5
  289. mage_ai/server/frontend_dist_base_path_template/settings/workspace/permissions.html +5 -5
  290. mage_ai/server/frontend_dist_base_path_template/settings/workspace/preferences.html +5 -5
  291. mage_ai/server/frontend_dist_base_path_template/settings/workspace/roles/[...slug].html +5 -5
  292. mage_ai/server/frontend_dist_base_path_template/settings/workspace/roles.html +5 -5
  293. mage_ai/server/frontend_dist_base_path_template/settings/workspace/sync-data.html +5 -5
  294. mage_ai/server/frontend_dist_base_path_template/settings/workspace/users/[...slug].html +5 -5
  295. mage_ai/server/frontend_dist_base_path_template/settings/workspace/users.html +5 -5
  296. mage_ai/server/frontend_dist_base_path_template/settings.html +2 -2
  297. mage_ai/server/frontend_dist_base_path_template/sign-in.html +20 -20
  298. mage_ai/server/frontend_dist_base_path_template/templates/[...slug].html +5 -5
  299. mage_ai/server/frontend_dist_base_path_template/templates.html +5 -5
  300. mage_ai/server/frontend_dist_base_path_template/terminal.html +5 -5
  301. mage_ai/server/frontend_dist_base_path_template/test.html +5 -5
  302. mage_ai/server/frontend_dist_base_path_template/triggers.html +5 -5
  303. mage_ai/server/frontend_dist_base_path_template/version-control.html +5 -5
  304. mage_ai/server/server.py +11 -3
  305. mage_ai/services/k8s/job_manager.py +1 -0
  306. mage_ai/settings/repo.py +3 -0
  307. mage_ai/shared/files.py +47 -0
  308. mage_ai/shared/models.py +1 -0
  309. mage_ai/streaming/constants.py +1 -0
  310. mage_ai/streaming/sinks/postgres.py +2 -0
  311. mage_ai/streaming/sinks/rabbitmq.py +76 -0
  312. mage_ai/streaming/sinks/sink_factory.py +4 -0
  313. mage_ai/streaming/sources/nats_js.py +12 -1
  314. mage_ai/tests/api/operations/test_operations_with_hooks.py +136 -91
  315. mage_ai/tests/api/policies/test_oauth_policy.py +38 -0
  316. mage_ai/tests/data_preparation/executors/test_block_executor.py +2 -0
  317. mage_ai/tests/data_preparation/models/global_hooks/test_global_hooks.py +33 -8
  318. mage_ai/tests/data_preparation/models/global_hooks/test_hook.py +82 -38
  319. mage_ai/tests/data_preparation/models/global_hooks/test_predicates.py +803 -0
  320. mage_ai/tests/data_preparation/models/global_hooks/test_utils.py +6 -1
  321. mage_ai/tests/data_preparation/models/test_block.py +26 -0
  322. mage_ai/tests/data_preparation/models/test_pipeline.py +15 -0
  323. mage_ai/tests/factory.py +40 -2
  324. mage_ai/tests/orchestration/test_pipeline_scheduler.py +82 -1
  325. mage_ai/tests/services/k8s/test_job_manager.py +16 -0
  326. mage_ai/tests/shared/mixins.py +60 -23
  327. mage_ai/tests/streaming/sinks/test_rabbitmq.py +36 -0
  328. {mage_ai-0.9.46.dist-info → mage_ai-0.9.48.dist-info}/METADATA +7 -4
  329. {mage_ai-0.9.46.dist-info → mage_ai-0.9.48.dist-info}/RECORD +335 -321
  330. {mage_ai-0.9.46.dist-info → mage_ai-0.9.48.dist-info}/WHEEL +1 -1
  331. mage_ai/server/frontend_dist/_next/static/9jB4XPuz6BzxBcG9VNao5/_buildManifest.js +0 -1
  332. mage_ai/server/frontend_dist/_next/static/chunks/1952-ac7722e8b1ab88fe.js +0 -1
  333. mage_ai/server/frontend_dist/_next/static/chunks/3419-f8d518d024e7b5c8.js +0 -1
  334. mage_ai/server/frontend_dist/_next/static/chunks/3943-9e1105393a3be0de.js +0 -1
  335. mage_ai/server/frontend_dist/_next/static/chunks/4267-fd4d8049e83178de.js +0 -1
  336. mage_ai/server/frontend_dist/_next/static/chunks/5810-12eadc488265d55b.js +0 -1
  337. mage_ai/server/frontend_dist/_next/static/chunks/595-0d174b1f9fbfce4f.js +0 -1
  338. mage_ai/server/frontend_dist/_next/static/chunks/600-705fe234320ec5de.js +0 -1
  339. mage_ai/server/frontend_dist/_next/static/chunks/6333-bc1b433b428a9095.js +0 -1
  340. mage_ai/server/frontend_dist/_next/static/chunks/722-a1584445357a276c.js +0 -1
  341. mage_ai/server/frontend_dist/_next/static/chunks/8264-0d582a6ca33c3dfa.js +0 -1
  342. mage_ai/server/frontend_dist/_next/static/chunks/8487-032ef9b17d20aad9.js +0 -1
  343. mage_ai/server/frontend_dist/_next/static/chunks/90-a7308bae028d7001.js +0 -1
  344. mage_ai/server/frontend_dist/_next/static/chunks/9264-1d4f0327d42fed91.js +0 -1
  345. mage_ai/server/frontend_dist/_next/static/chunks/9618-2c5045255ac5a6e7.js +0 -1
  346. mage_ai/server/frontend_dist/_next/static/chunks/9624-334e7db5c84cb4ea.js +0 -1
  347. mage_ai/server/frontend_dist/_next/static/chunks/pages/_app-ebef928183f9a3bb.js +0 -1
  348. mage_ai/server/frontend_dist/_next/static/chunks/pages/compute-419775ca1293b354.js +0 -1
  349. mage_ai/server/frontend_dist/_next/static/chunks/pages/files-0f2d4be6fdca86ca.js +0 -1
  350. mage_ai/server/frontend_dist/_next/static/chunks/pages/global-hooks/[...slug]-77edfa32d000e88b.js +0 -1
  351. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipeline-runs-b35d37bfba8fbccc.js +0 -1
  352. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills/[...slug]-10e9a2d19541caa2.js +0 -1
  353. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills-c8d3a5289ab93f88.js +0 -1
  354. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/edit-ff7e9108502f5716.js +0 -1
  355. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/logs-ef680455ae54ccbe.js +0 -1
  356. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/runs/[run]-0691711636fa95c7.js +0 -1
  357. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/settings-2914e326a5f1ffe0.js +0 -1
  358. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/syncs-b75bf17498e87354.js +0 -1
  359. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/triggers/[...slug]-3a7500e6e53084d3.js +0 -1
  360. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/triggers-c0e551d265a8d467.js +0 -1
  361. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines-e47db5c3eaf683af.js +0 -1
  362. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/account/profile-55ac955dfa9a5a8d.js +0 -1
  363. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/preferences-29c92a9bc54ae5cd.js +0 -1
  364. mage_ai/server/frontend_dist/_next/static/chunks/pages/triggers-572d82d6eb7a5d43.js +0 -1
  365. mage_ai/server/frontend_dist/_next/static/chunks/pages/version-control-2d26d80370a2e481.js +0 -1
  366. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/1952-ac7722e8b1ab88fe.js +0 -1
  367. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3419-f8d518d024e7b5c8.js +0 -1
  368. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3943-9e1105393a3be0de.js +0 -1
  369. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/4267-fd4d8049e83178de.js +0 -1
  370. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/5810-12eadc488265d55b.js +0 -1
  371. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/595-0d174b1f9fbfce4f.js +0 -1
  372. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/600-705fe234320ec5de.js +0 -1
  373. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/6333-bc1b433b428a9095.js +0 -1
  374. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/722-a1584445357a276c.js +0 -1
  375. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/8264-0d582a6ca33c3dfa.js +0 -1
  376. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/8487-032ef9b17d20aad9.js +0 -1
  377. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/90-a7308bae028d7001.js +0 -1
  378. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/9264-1d4f0327d42fed91.js +0 -1
  379. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/9618-2c5045255ac5a6e7.js +0 -1
  380. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/9624-334e7db5c84cb4ea.js +0 -1
  381. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/_app-ebef928183f9a3bb.js +0 -1
  382. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/compute-419775ca1293b354.js +0 -1
  383. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/files-0f2d4be6fdca86ca.js +0 -1
  384. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/global-hooks/[...slug]-77edfa32d000e88b.js +0 -1
  385. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipeline-runs-b35d37bfba8fbccc.js +0 -1
  386. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/backfills/[...slug]-10e9a2d19541caa2.js +0 -1
  387. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/backfills-c8d3a5289ab93f88.js +0 -1
  388. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/edit-ff7e9108502f5716.js +0 -1
  389. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/logs-ef680455ae54ccbe.js +0 -1
  390. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/runs/[run]-0691711636fa95c7.js +0 -1
  391. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/settings-2914e326a5f1ffe0.js +0 -1
  392. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/syncs-b75bf17498e87354.js +0 -1
  393. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/triggers/[...slug]-3a7500e6e53084d3.js +0 -1
  394. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/triggers-c0e551d265a8d467.js +0 -1
  395. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines-e47db5c3eaf683af.js +0 -1
  396. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/account/profile-55ac955dfa9a5a8d.js +0 -1
  397. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/preferences-29c92a9bc54ae5cd.js +0 -1
  398. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/triggers-572d82d6eb7a5d43.js +0 -1
  399. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/version-control-2d26d80370a2e481.js +0 -1
  400. mage_ai/server/frontend_dist_base_path_template/_next/static/uPDjJYpJMst1q6psbRyte/_buildManifest.js +0 -1
  401. /mage_ai/server/frontend_dist/_next/static/{9jB4XPuz6BzxBcG9VNao5 → xxcdnITr3IkTdETH5ghqw}/_ssgManifest.js +0 -0
  402. /mage_ai/server/frontend_dist_base_path_template/_next/static/{uPDjJYpJMst1q6psbRyte → gDn6inKdLyj35NvURBSCV}/_ssgManifest.js +0 -0
  403. {mage_ai-0.9.46.dist-info → mage_ai-0.9.48.dist-info}/LICENSE +0 -0
  404. {mage_ai-0.9.46.dist-info → mage_ai-0.9.48.dist-info}/entry_points.txt +0 -0
  405. {mage_ai-0.9.46.dist-info → mage_ai-0.9.48.dist-info}/top_level.txt +0 -0
@@ -1 +0,0 @@
1
- (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1221],{8666:function(e,n,i){"use strict";var t;i.d(n,{b:function(){return t}}),function(e){e.BLOCK="block",e.PIPELINE="pipeline"}(t||(t={}))},30229:function(e,n,i){"use strict";i.d(n,{TR:function(){return f},U5:function(){return c},Wb:function(){return p},Xm:function(){return u},Z4:function(){return s},fq:function(){return l},gm:function(){return d},kJ:function(){return a}});var t,o,u,r=i(82394);!function(e){e.API="api",e.EVENT="event",e.TIME="time"}(u||(u={}));var l,c,s=(t={},(0,r.Z)(t,u.API,(function(){return"API"})),(0,r.Z)(t,u.EVENT,(function(){return"event"})),(0,r.Z)(t,u.TIME,(function(){return"schedule"})),t);!function(e){e.ACTIVE="active",e.INACTIVE="inactive"}(l||(l={})),function(e){e.ONCE="@once",e.HOURLY="@hourly",e.DAILY="@daily",e.WEEKLY="@weekly",e.MONTHLY="@monthly",e.ALWAYS_ON="@always_on"}(c||(c={}));var d,a,p=[c.ONCE,c.HOURLY,c.DAILY,c.WEEKLY,c.MONTHLY];!function(e){e.INTERVAL="frequency[]",e.STATUS="status[]",e.TAG="tag[]",e.TYPE="type[]"}(d||(d={})),function(e){e.CREATED_AT="created_at",e.NAME="name",e.PIPELINE="pipeline_uuid",e.STATUS="status",e.TYPE="schedule_type"}(a||(a={}));var f=(o={},(0,r.Z)(o,a.CREATED_AT,"Created at"),(0,r.Z)(o,a.NAME,"Name"),(0,r.Z)(o,a.PIPELINE,"Pipeline"),(0,r.Z)(o,a.STATUS,"Active"),(0,r.Z)(o,a.TYPE,"Type"),o)},31882:function(e,n,i){"use strict";var t=i(38626),o=i(71180),u=i(55485),r=i(30160),l=i(44897),c=i(72473),s=i(70515),d=i(61896),a=i(28598),p=t.default.div.withConfig({displayName:"Chip__ChipStyle",componentId:"sc-1ok73g-0"})(["display:inline-block;"," "," "," "," "," ",""],(function(e){return!e.primary&&"\n background-color: ".concat((e.theme.background||l.Z.background).tag,";\n ")}),(function(e){return e.primary&&"\n background-color: ".concat((e.theme.chart||l.Z.chart).primary,";\n ")}),(function(e){return!e.small&&"\n border-radius: ".concat((s.iI+d.Al)/2,"px;\n height: ").concat(1.5*s.iI+d.Al,"px;\n padding: ").concat(s.iI/1.5,"px ").concat(1.25*s.iI,"px;\n ")}),(function(e){return e.small&&"\n border-radius: ".concat((s.iI/2+d.Al)/2,"px;\n height: ").concat(d.Al+s.iI/2+2,"px;\n padding: ").concat(s.iI/4,"px ").concat(s.iI,"px;\n ")}),(function(e){return e.xsmall&&"\n border-radius: ".concat((s.iI/1+d.Al)/1,"px;\n height: ").concat(20,"px;\n padding: 4px 6px;\n ")}),(function(e){return e.border&&"\n border: 1px solid ".concat((e.theme.content||l.Z.content).muted,";\n ")}));n.Z=function(e){var n=e.border,i=e.children,t=e.disabled,l=e.label,d=e.monospace,f=e.onClick,v=e.primary,h=e.small,m=e.xsmall;return(0,a.jsx)(p,{border:n,primary:v,small:h,xsmall:m,children:(0,a.jsx)(o.ZP,{basic:!0,disabled:t,noBackground:!0,noPadding:!0,onClick:f,transparent:!0,children:(0,a.jsxs)(u.ZP,{alignItems:"center",children:[i,l&&(0,a.jsx)(r.ZP,{monospace:d,small:h,xsmall:m,children:l}),!t&&f&&(0,a.jsx)("div",{style:{marginLeft:2}}),!t&&f&&(0,a.jsx)(c.x8,{default:v,muted:!v,size:h?s.iI:1.25*s.iI})]})})})}},55620:function(e,n,i){"use strict";i.r(n),i.d(n,{default:function(){return Te}});var t=i(77837),o=i(21831),u=i(75582),r=i(82394),l=i(38860),c=i.n(l),s=i(12691),d=i.n(s),a=i(82684),p=i(69864),f=i(34376),v=i(52749),h=i(60523),m=i(71180),g=i(90299),b=i(31882),x=i(94629),Z=i(97618),j=i(55485),C=i(85854),_=i(93369),w=i(65956),I=i(38276),k=i(30160),y=i(35576),P=i(17488),T=i(28598);var A=function(e){var n=e.description,i=e.isLoading,t=e.maxWidth,o=e.minWidth,u=e.noEmptyValue,r=e.onClose,l=e.onSave,c=e.textArea,s=e.title,d=e.value,p=(0,a.useRef)(null),f=(0,a.useState)(d),v=f[0],h=f[1],g=c?y.Z:P.Z;return(0,a.useEffect)((function(){var e;null===p||void 0===p||null===(e=p.current)||void 0===e||e.focus()}),[]),(0,T.jsxs)(w.Z,{maxWidth:t,minWidth:o,children:[(0,T.jsx)(k.ZP,{bold:!0,children:s}),(0,T.jsx)(I.Z,{mt:1,children:(0,T.jsx)(g,{monospace:!0,onChange:function(e){return h(e.target.value)},ref:p,rows:c?7:null,value:v})}),n&&(0,T.jsx)(I.Z,{mt:2,children:(0,T.jsx)(k.ZP,{muted:!0,small:!0,children:n})}),(0,T.jsx)(I.Z,{mt:3,children:(0,T.jsxs)(j.ZP,{children:[(0,T.jsx)(_.ZP,{bold:!0,inline:!0,loading:i,onClick:function(){v===d||u&&!v?r():l(v)},outline:!0,primary:!0,uuid:"Inputs/InputModal/SaveInput",children:"Save"}),(0,T.jsx)(I.Z,{ml:1}),(0,T.jsx)(m.ZP,{onClick:r,children:"Cancel"})]})})]})},E=i(48670),S=i(57653),O=i(55729),M=i(93808),D=i(82359),N=i(4190),R=i(75499),L=i(48381),U=i(69650),G=i(85544),Y=i(35686),B=i(44897),H=i(42631),V=i(44425),W=i(72473),$=i(23780),z=i(8666),q=i(46684),K=i(53808),Q="pipeline_list_filters",X="pipeline_list_group_bys",F="pipeline_list_sort_column_index",J="pipeline_list_sort_direction",ee="pipeline_list_selected_tab_uuid";function ne(e){return(0,K.t8)(Q,e),e}function ie(e){return(0,K.t8)(X,e),e}var te=i(32929),oe=i(44898),ue=i(70515),re=i(30229),le=i(81655),ce=i(31608),se=i(81728),de=i(3917),ae=i(72619),pe=i(69419),fe=i(65458),ve=i(15610),he=i(86735),me=i(42122),ge=i(3314),be=i(70320),xe=i(89538),Ze=i(44952);function je(e,n){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);n&&(t=t.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),i.push.apply(i,t)}return i}function Ce(e){for(var n=1;n<arguments.length;n++){var i=null!=arguments[n]?arguments[n]:{};n%2?je(Object(i),!0).forEach((function(n){(0,r.Z)(e,n,i[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):je(Object(i)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(i,n))}))}return e}var _e={Icon:W.Pf,label:function(){return"Recently viewed"},uuid:"recent"},we={Icon:W.vd,label:function(){return"All pipelines"},uuid:"all"},Ie=[we,_e],ke="tab",ye={borderRadius:"".concat(H.BG,"px"),iconOnly:!0,noBackground:!0,noBorder:!0,outline:!0,padding:"4px"};function Pe(){var e,n=(0,f.useRouter)(),i=(0,a.useRef)(null),t=(0,a.useRef)(null),l=(0,a.useState)(null),c=l[0],s=l[1],_=(0,a.useState)(null),y=_[0],P=_[1],M=(0,a.useState)(null),H=M[0],je=M[1],Pe=(0,a.useState)(null),Te=Pe[0],Ae=Pe[1],Ee=(0,a.useState)(null),Se=Ee[0],Oe=Ee[1],Me=(0,a.useState)({}),De=Me[0],Ne=Me[1],Re=(0,a.useState)(null),Le=Re[0],Ue=Re[1],Ge=(0,pe.iV)(),Ye=(0,pe.DQ)(Ge,[S.$1.STATUS,S.$1.TAG,S.$1.TYPE]);(0,a.useEffect)((function(){var e;s(null===i||void 0===i||null===(e=i.current)||void 0===e?void 0:e.getBoundingClientRect().height)}),[Ge,i]);var Be=Y.ZP.projects.list(),He=Be.data,Ve=Be.mutate,We=(0,a.useMemo)((function(){var e;return null===He||void 0===He||null===(e=He.projects)||void 0===e?void 0:e[0]}),[He]),$e=(0,a.useMemo)((function(){var e;return(0,be.h)(null===We||void 0===We||null===(e=We.features)||void 0===e?void 0:e[D.d.LOCAL_TIMEZONE])}),[null===We||void 0===We?void 0:We.features]),ze=(0,a.useMemo)((function(){var e;return null===We||void 0===We||null===(e=We.features)||void 0===e?void 0:e[D.d.OPERATION_HISTORY]}),[We]),qe=(0,a.useMemo)((function(){return $e?le.O$:{}}),[$e]),Ke=Y.ZP.pipelines.list(Ce(Ce({},Ye),{},{include_schedules:1})),Qe=Ke.data,Xe=Ke.mutate,Fe=(0,a.useMemo)((function(){return(null===Ge||void 0===Ge?void 0:Ge[S.$1.HISTORY_DAYS])||7}),[Ge]),Je=Y.ZP.pipelines.list(Ce(Ce({},Ye),{},(e={},(0,r.Z)(e,S.$1.HISTORY_DAYS,(0,se.HW)(Fe)?Number(Fe):Fe),(0,r.Z)(e,"include_schedules",1),e)),{},{pauseFetch:!ze}),en=Je.data,nn=Je.mutate,tn=(0,a.useCallback)((function(e){var n=e||[];if(Se){var i=Se.toLowerCase();n=n.filter((function(e){var n=e.name,t=e.description,o=e.uuid;return(null===n||void 0===n?void 0:n.toLowerCase().includes(i))||(null===o||void 0===o?void 0:o.toLowerCase().includes(i))||(null===t||void 0===t?void 0:t.toLowerCase().includes(i))}))}return n}),[Se]),on=(0,a.useMemo)((function(){var e=tn((null===Qe||void 0===Qe?void 0:Qe.pipelines)||[]);if(null!==Ge&&void 0!==Ge&&Ge[S.$1.TAG]){var n=Ge[S.$1.TAG];e=e.filter((function(e){var i=e.tags;return i.some((function(e){return n.includes(e)}))||0===i.length&&n.includes(S.$1.NO_TAGS)}))}return e}),[Qe,tn,Ge]),un=(0,a.useMemo)((function(){return tn((null===en||void 0===en?void 0:en.pipelines)||[])}),[en,tn]),rn=(0,a.useMemo)((function(){return(0,he.HK)(on,(function(e){return e.uuid}))}),[on]),ln=(0,a.useMemo)((function(){return(0,he.HK)(un,(function(e){return e.uuid}))}),[un]),cn=(0,a.useCallback)((function(e){var n,i,t,o;return null===e||void 0===e||null===(n=e[2])||void 0===n||null===(i=n.props)||void 0===i||null===(t=i.children)||void 0===t||null===(o=t.props)||void 0===o?void 0:o.children}),[]),sn=(0,a.useMemo)((function(){return(null===H||void 0===H?void 0:H.length)>0?null===H||void 0===H?void 0:H.map((function(e){var n=cn(e);return null===rn||void 0===rn?void 0:rn[n]})):on}),[cn,H,on,rn]),dn=(0,a.useMemo)((function(){return(null===Te||void 0===Te?void 0:Te.length)>0?null===Te||void 0===Te?void 0:Te.map((function(e){var n=cn(e);return null===ln||void 0===ln?void 0:ln[n]})):un}),[cn,Te,un,ln]),an=(0,a.useMemo)((function(){return[1,2,3,4,5,6,8,9]}),[]),pn=null===Ge||void 0===Ge?void 0:Ge[le.lG.SORT_COL_IDX],fn=null===Ge||void 0===Ge?void 0:Ge[le.lG.SORT_DIRECTION],vn=(0,a.useMemo)((function(){return pn?{columnIndex:+pn,sortDirection:fn||le.sh.ASC}:void 0}),[pn,fn]),hn=null===Ge||void 0===Ge?void 0:Ge[S.$1.GROUP],mn=(0,a.useMemo)((function(){return null===Ge||void 0===Ge?void 0:Ge.tab}),[Ge]),gn=(0,p.Db)((function(e){var n=e.pipelineUUID,i=e.filesOnly,t=void 0!==i&&i;return Y.ZP.downloads.pipelines.useCreate(n)({download:{ignore_folder_structure:t}})}),{onSuccess:function(e){return(0,ae.wD)(e,{callback:function(){var n=e.data.download.token;(0,Ze.K)(n)},onErrorCallback:function(e,n){return Ue({errors:n,response:e})}})}}),bn=(0,u.Z)(gn,1)[0];(0,a.useEffect)((function(){var e,n={};if(pn&&an.includes(+pn))(0,K.t8)(F,pn),fn&&(0,K.t8)(J,fn);else{var i=(0,K.U2)(F,null),t=(0,K.U2)(J,le.sh.ASC);null!==i&&(n[le.lG.SORT_COL_IDX]=i,n[le.lG.SORT_DIRECTION]=t)}ze&&(mn?(0,K.t8)(ee,mn):n.tab=(0,K.U2)(ee,null===Ie||void 0===Ie||null===(e=Ie[0])||void 0===e?void 0:e.uuid));if(hn)ie((0,r.Z)({},hn,!0));else{var o,l=(0,K.U2)(X,{});l&&Object.entries(l).forEach((function(e){var n=(0,u.Z)(e,2),i=n[0],t=n[1];!o&&t&&(o=i)})),o&&(n[S.$1.GROUP]=o)}if((0,me.Qr)(Ye)){var c={},s=(0,K.U2)(Q,{});s&&Object.entries(s).forEach((function(e){var n=(0,u.Z)(e,2),i=n[0],t=n[1];c[i]=[],Object.entries(t).forEach((function(e){var n=(0,u.Z)(e,2),t=n[0];n[1]&&c[i].push(t)}))})),(0,me.Qr)(c)||(n=Ce(Ce({},n),c))}else{var d={};Object.entries(Ye).forEach((function(e){var n=(0,u.Z)(e,2),i=n[0],t=n[1];d[i]={};var o,r=t;(Array.isArray(r)||(r=[r]),r&&Array.isArray(r))&&(null===(o=r)||void 0===o||o.forEach((function(e){d[i][e]=!0})))})),ne(d)}(0,me.Qr)(n)||(0,ve.u7)(n,{pushHistory:!1})}),[hn,ze,Ye,mn,an,pn,fn]),(0,a.useEffect)((function(){(0,ae.bB)(Qe,Ue)}),[Qe]);var xn=function(e){return(0,p.Db)(Y.ZP.pipelines.useCreate(),{onSuccess:function(n){return(0,ae.wD)(n,{callback:function(n){var i=n.pipeline.uuid;null===e||void 0===e||e(i)},onErrorCallback:function(e,n){return Ue({errors:n,response:e})}})}})},Zn=xn((function(e){return n.push("/pipelines/[pipeline]/edit","/pipelines/".concat(e,"/edit"))})),jn=(0,u.Z)(Zn,2),Cn=jn[0],_n=jn[1].isLoading,wn=xn((function(){null===Xe||void 0===Xe||Xe(),null===nn||void 0===nn||nn()})),In=(0,u.Z)(wn,2),kn=In[0],yn=In[1].isLoading,Pn=(0,p.Db)((function(e){return Y.ZP.pipelines.useUpdate(e.uuid)({pipeline:e})}),{onSuccess:function(e){return(0,ae.wD)(e,{callback:function(e){var n=e.pipeline.uuid;Ne((function(e){return Ce(Ce({},e),{},(0,r.Z)({},n,!1))})),Xe(),null===nn||void 0===nn||nn(),null===Un||void 0===Un||Un(),P(null)},onErrorCallback:function(e,n){var i,t=null===e||void 0===e||null===(i=e.url_parameters)||void 0===i?void 0:i.pk;Ne((function(e){return Ce(Ce({},e),{},(0,r.Z)({},t,!1))})),Ue({errors:n,response:e})}})}}),Tn=(0,u.Z)(Pn,2),An=Tn[0],En=Tn[1].isLoading,Sn=(0,p.Db)((function(e){return Y.ZP.pipelines.useDelete(e)()}),{onSuccess:function(e){return(0,ae.wD)(e,{callback:function(){null===Xe||void 0===Xe||Xe(),null===nn||void 0===nn||nn()},onErrorCallback:function(e,n){return Ue({errors:n,response:e})}})}}),On=(0,u.Z)(Sn,2),Mn=On[0],Dn=On[1].isLoading,Nn=(0,xe.dd)((function(e){var n=e.pipeline,i=e.pipelineDescription,t=e.pipelineName;return(0,T.jsx)(A,{isLoading:En,minWidth:55*ue.iI,noEmptyValue:!!t,onClose:Un,onSave:function(e){var i=n||y;if(i){var o=i.uuid,u={uuid:o};t?u.name=e:u.description=e,Ne((function(e){return Ce(Ce({},e),{},(0,r.Z)({},o,!0))})),An(u)}},textArea:!t,title:t?"Rename pipeline":"Edit description for ".concat(null===n||void 0===n?void 0:n.uuid),value:t||i})}),{},[En,y],{background:!0,uuid:"rename_pipeline_and_save"}),Rn=(0,u.Z)(Nn,2),Ln=Rn[0],Un=Rn[1],Gn=(0,xe.dd)((function(){return(0,T.jsx)($.BC,{children:(0,T.jsx)(h.Z,{contained:!0,onClickCustomTemplate:function(e){Cn({pipeline:{custom_template_uuid:null===e||void 0===e?void 0:e.template_uuid,name:(0,se.Y6)()}}).then((function(){Hn()}))},showBreadcrumbs:!0,tabs:[te.A2]})})}),{},[Cn],{background:!0,uuid:"browse_templates"}),Yn=(0,u.Z)(Gn,2),Bn=Yn[0],Hn=Yn[1],Vn=(0,xe.dd)((function(e){var n=e.cancelButtonText,i=(e.header,e.onCancel),t=e.onSaveSuccess;return(0,T.jsx)($.BC,{children:(0,T.jsx)(O.Z,{cancelButtonText:n,contained:!0,header:(0,T.jsx)(I.Z,{mb:ue.HN,children:(0,T.jsxs)(w.Z,{children:[(0,T.jsx)(k.ZP,{warning:!0,children:"You need to add an OpenAI API key to your project before you can generate pipelines using AI."}),(0,T.jsx)(I.Z,{mt:1,children:(0,T.jsxs)(k.ZP,{warning:!0,children:["Read ",(0,T.jsx)(E.Z,{href:"https://help.openai.com/en/articles/4936850-where-do-i-find-my-secret-api-key",openNewWindow:!0,children:"OpenAI\u2019s documentation"})," to get your API key."]})})]})}),onCancel:function(){null===i||void 0===i||i(),zn()},onSaveSuccess:function(e){Ve(),zn(),null===t||void 0===t||t(e)}})})}),{},[Ve],{background:!0,uuid:"configure_project"}),Wn=(0,u.Z)(Vn,2),$n=Wn[0],zn=Wn[1],qn=(0,xe.dd)((function(){return(0,T.jsx)($.BC,{children:(0,T.jsx)(v.Z,{createPipeline:Cn,isLoading:_n,onClose:Xn})})}),{},[Cn,_n],{background:!0,disableClickOutside:!0,disableCloseButton:!0,uuid:"AI_modal"}),Kn=(0,u.Z)(qn,2),Qn=Kn[0],Xn=Kn[1],Fn=(0,a.useMemo)((function(){return(0,fe.d)(Cn,{showAIModal:function(){null!==We&&void 0!==We&&We.openai_api_key?Qn():$n({onSaveSuccess:function(){Qn()}})},showBrowseTemplates:Bn})}),[Cn,We,Qn,Bn,$n]),Jn=Y.ZP.tags.list().data,ei=(0,a.useMemo)((function(){return(0,he.YC)((null===Jn||void 0===Jn?void 0:Jn.tags)||[],(function(e){return e.uuid}))}),[Jn]),ni=(0,a.useMemo)((function(){return(0,T.jsx)(G.Z,{addButtonProps:{isLoading:_n,label:"New",menuItems:Fn},deleteRowProps:{confirmationMessage:"This is irreversible and will immediately delete everything associated with the pipeline, including its blocks, triggers, runs, logs, and history.",isLoading:Dn,item:"pipeline",onDelete:function(){window.confirm("Are you sure you want to delete pipeline ".concat(null===y||void 0===y?void 0:y.uuid,"?"))&&Mn(null===y||void 0===y?void 0:y.uuid)}},extraActionButtonProps:{Icon:W.oX,confirmationDescription:"Cloning the selected pipeline will create a new pipeline with the same configuration and code blocks. The blocks use the same block files as the original pipeline. Pipeline triggers, runs, backfills, and logs are not copied over to the new pipeline.",confirmationMessage:"Do you want to clone the pipeline ".concat(null===y||void 0===y?void 0:y.uuid,"?"),isLoading:yn,onClick:function(){return kn({pipeline:{clone_pipeline_uuid:null===y||void 0===y?void 0:y.uuid}})},openConfirmationDialogue:!0,tooltip:"Clone pipeline"},filterOptions:{status:S.kA,tag:[S.$1.NO_TAGS].concat((0,o.Z)(ei.map((function(e){return e.uuid})))),type:Object.values(S.qL)},filterValueLabelMapping:{status:S.kA.reduce((function(e,n){return Ce(Ce({},e),{},(0,r.Z)({},n,(0,se.J3)((0,se.kC)(n))))}),{}),tag:Ce((0,r.Z)({},S.$1.NO_TAGS,"No tags"),ei.reduce((function(e,n){var i=n.uuid;return Ce(Ce({},e),{},(0,r.Z)({},i,i))}),{})),type:S.G7},groupButtonProps:{groupByLabel:hn,menuItems:[{beforeIcon:hn===S.r0.STATUS?(0,T.jsx)(W.Jr,{fill:B.Z.content.default,size:1.5*ue.iI}):(0,T.jsx)(W.Cd,{muted:!0,size:1.5*ue.iI}),label:function(){return(0,se.kC)(S.r0.STATUS)},onClick:function(){var e=hn===S.r0.STATUS?null:S.r0.STATUS;e||ie({}),(0,ve.u7)((0,r.Z)({},S.$1.GROUP,e),{pushHistory:!0})},uuid:"Pipelines/GroupMenu/Status"},{beforeIcon:hn===S.r0.TAG?(0,T.jsx)(W.Jr,{fill:B.Z.content.default,size:1.5*ue.iI}):(0,T.jsx)(W.Cd,{muted:!0,size:1.5*ue.iI}),label:function(){return(0,se.kC)(S.r0.TAG)},onClick:function(){var e=hn===S.r0.TAG?null:S.r0.TAG;e||ie({}),(0,ve.u7)((0,r.Z)({},S.$1.GROUP,e),{pushHistory:!0})},uuid:"Pipelines/GroupMenu/Tag"},{beforeIcon:hn===S.r0.TYPE?(0,T.jsx)(W.Jr,{fill:B.Z.content.default,size:1.5*ue.iI}):(0,T.jsx)(W.Cd,{muted:!0,size:1.5*ue.iI}),label:function(){return(0,se.kC)(S.r0.TYPE)},onClick:function(){var e=hn===S.r0.TYPE?null:S.r0.TYPE;e||ie({}),(0,ve.u7)((0,r.Z)({},S.$1.GROUP,e),{pushHistory:!0})},uuid:"Pipelines/GroupMenu/Type"}]},moreActionsMenuItems:[{label:function(){return"Rename pipeline"},onClick:function(){return Ln({pipelineName:null===y||void 0===y?void 0:y.name})},uuid:"Pipelines/MoreActionsMenu/Rename"},{label:function(){return"Edit description"},onClick:function(){return Ln({pipeline:y,pipelineDescription:null===y||void 0===y?void 0:y.description})},uuid:"Pipelines/MoreActionsMenu/EditDescription"}],onClickFilterDefaults:function(){ne({}),n.push("/pipelines")},onFilterApply:function(e,n){Object.values(n).every((function(e){return!(null!==e&&void 0!==e&&e.length)}))&&ne({})},query:Ye,searchProps:{onChange:Oe,value:Se},selectedRowId:null===y||void 0===y?void 0:y.uuid,setSelectedRow:P})}),[kn,Mn,hn,yn,_n,Dn,Fn,Ye,n,Se,y,Ln,ei]),ii=(0,$.VI)(null,{},[],{uuid:"pipelines/list"}),ti=(0,u.Z)(ii,1)[0],oi=(0,p.Db)(Y.ZP.projects.useUpdate(null===We||void 0===We?void 0:We.name),{onSuccess:function(e){return(0,ae.wD)(e,{callback:function(){Ve()},onErrorCallback:function(e,n){return ti({errors:n,response:e})}})}}),ui=(0,u.Z)(oi,2),ri=ui[0],li=ui[1].isLoading,ci=(0,a.useCallback)((function(e){return ri({project:e})}),[ri]),si=(0,xe.dd)((function(){return(0,T.jsxs)(w.Z,{maxWidth:60*ue.iI,children:[(0,T.jsx)(I.Z,{mb:1,children:(0,T.jsx)(C.Z,{children:"Help improve Mage"})}),(0,T.jsx)(I.Z,{mb:ue.cd,children:(0,T.jsx)(k.ZP,{default:!0,children:"Please contribute usage statistics to help improve the developer experience for you and everyone in the community \ud83e\udd1d."})}),(0,T.jsx)(I.Z,{mb:ue.cd,children:(0,T.jsx)(w.Z,{success:!0,children:(0,T.jsxs)(j.ZP,{alignItems:"center",children:[(0,T.jsx)(W.Yo,{size:5*ue.iI,success:!0}),(0,T.jsx)(I.Z,{mr:1}),(0,T.jsx)(Z.Z,{children:(0,T.jsx)(k.ZP,{children:"All usage statistics are completely anonymous. It\u2019s impossible for Mage to know which statistics belongs to whom."})})]})})}),(0,T.jsx)(I.Z,{mb:ue.cd,children:(0,T.jsxs)(k.ZP,{default:!0,children:["By opting into sending usage statistics to ",(0,T.jsx)(E.Z,{href:"https://www.mage.ai",openNewWindow:!0,children:"Mage"}),", it\u2019ll help the team and community of contributors (",(0,T.jsx)(E.Z,{href:"https://www.mage.ai/chat",openNewWindow:!0,children:"Magers"}),") learn what\u2019s going wrong with the tool and what improvements can be made."]})}),(0,T.jsx)(I.Z,{mb:ue.cd,children:(0,T.jsx)(k.ZP,{default:!0,children:"In addition to helping reduce potential errors, you\u2019ll help inform which features are useful and which need work."})}),(0,T.jsx)(I.Z,{mb:ue.cd,children:(0,T.jsxs)(j.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,T.jsx)(k.ZP,{bold:!0,children:"I want to help make Mage more powerful for everyone"}),(0,T.jsx)(I.Z,{mr:ue.cd}),(0,T.jsx)(U.Z,{checked:!0,onCheck:function(){window.confirm("Are you sure you don\u2019t want to help everyone in the community?")&&ci({help_improve_mage:!1}).then((function(){return pi()}))}})]})}),li&&(0,T.jsx)(I.Z,{mb:ue.cd,children:(0,T.jsx)(N.Z,{inverted:!0})}),(0,T.jsx)(I.Z,{mb:ue.cd,children:(0,T.jsxs)(k.ZP,{muted:!0,small:!0,children:["To learn more about how this works, please check out the ",(0,T.jsx)(E.Z,{href:"https://docs.mage.ai/contributing/statistics/overview",openNewWindow:!0,small:!0,children:"documentation"}),"."]})}),(0,T.jsx)(m.ZP,{onClick:function(){return ci({help_improve_mage:!0}).then((function(){return pi()}))},secondary:!0,children:"Close"})]})}),{},[We],{background:!0,hideCallback:function(){ci({help_improve_mage:!0})},uuid:"help_mage"}),di=(0,u.Z)(si,2),ai=di[0],pi=di[1];(0,a.useEffect)((function(){We&&null===(null===We||void 0===We?void 0:We.help_improve_mage)&&ai()}),[We,ai]);var fi=(0,a.useCallback)((function(e){var n={};null===e||void 0===e||e.forEach((function(e,i){var t=null===e||void 0===e?void 0:e[hn];if(S.r0.STATUS===hn){var o=(e||{}).schedules,u=void 0===o?[]:o,r=u.length;t=u.find((function(e){var n=e.status;return re.fq.ACTIVE===n}))?S.QK.ACTIVE:r>=1?S.QK.INACTIVE:S.QK.NO_SCHEDULES}else if(S.r0.TAG===hn){t=(null===e||void 0===e?void 0:e.tags)?(0,he.YC)(e.tags,(function(e){return e})).join(", "):""}n[t]||(n[t]=[]),n[t].push(i)}));var i=[],t=[];S.r0.STATUS===hn?Object.values(S.QK).forEach((function(e){i.push(n[e]),t.push((0,se.vg)(e))})):S.r0.TAG===hn?(0,he.YC)(Object.keys(n),(function(e){return e})).forEach((function(e){i.push(n[e]),e?t.push(e.split(", ").map((function(e,n){return(0,T.jsxs)(T.Fragment,{children:[(0,T.jsx)("div",{style:{marginLeft:n>=1?4:0}},"".concat(e,"-").concat(n,"-spacing")),(0,T.jsx)(b.Z,{small:!0,children:(0,T.jsx)(k.ZP,{children:e})},"".concat(e,"-").concat(n))]})}))):t.push("No tags")})):S.r0.TYPE===hn&&Object.values(S.qL).forEach((function(e){i.push(n[e]),t.push(S.G7[e])}));var o=[],u=[];return null===i||void 0===i||i.forEach((function(e,n){"undefined"!==typeof e&&null!==e&&(null===e||void 0===e?void 0:e.length)>=1&&(u.push(e),o.push(null===t||void 0===t?void 0:t[n]))})),{rowGroupHeaders:o,rowsGroupedByIndex:u}}),[hn]),vi=(0,a.useMemo)((function(){return fi(sn)}),[fi,sn]),hi=vi.rowGroupHeaders,mi=vi.rowsGroupedByIndex,gi=(0,a.useMemo)((function(){return fi(dn)}),[fi,dn]),bi=gi.rowGroupHeaders,xi=gi.rowsGroupedByIndex,Zi=(0,a.useCallback)((function(e,i,o,u,l){return(0,T.jsx)(R.Z,{columnFlex:[null,null,null,2,null,null,null,1,null,null,null],columns:[{label:function(){return""},uuid:"action"},{uuid:(0,se.kC)(S.r0.STATUS)},{uuid:"Name"},{uuid:"Description"},{uuid:(0,se.kC)(S.r0.TYPE)},Ce(Ce({},qe),{},{uuid:"Updated at"}),Ce(Ce({},qe),{},{uuid:"Created at"}),{uuid:"Tags"},{uuid:"Blocks"},{uuid:"Triggers"},{center:!0,label:function(){return""},uuid:"Actions"}],defaultSortColumnIndex:2,getUniqueRowIdentifier:cn,isSelectedRow:function(e){var n;return(null===(n=i[e])||void 0===n?void 0:n.uuid)===(null===y||void 0===y?void 0:y.uuid)},localStorageKeySortColIdx:F,localStorageKeySortDirection:J,onClickRow:function(e){return P((function(n){var t=i[e];return(null===n||void 0===n?void 0:n.uuid)!==(null===t||void 0===t?void 0:t.uuid)?t:null}))},onDoubleClickRow:function(e){n.push("/pipelines/[pipeline]/edit","/pipelines/".concat(i[e].uuid,"/edit"))},ref:t,renderRightClickMenuItems:function(e){var t=i[e];return[{label:function(){return"Edit description"},onClick:function(){return Ln({pipeline:t,pipelineDescription:null===t||void 0===t?void 0:t.description})},uuid:"edit_description"},{label:function(){return"Rename"},onClick:function(){return Ln({pipeline:t,pipelineName:null===t||void 0===t?void 0:t.name})},uuid:"rename"},{label:function(){return"Clone"},onClick:function(){return kn({pipeline:{clone_pipeline_uuid:null===t||void 0===t?void 0:t.uuid}})},uuid:"clone"},{label:function(){return"Download (keep folder structure)"},onClick:function(){bn({pipelineUUID:null===t||void 0===t?void 0:t.uuid,filesOnly:!1})},uuid:"download_keep_folder_structure"},{label:function(){return"Download (without folder structure)"},onClick:function(){bn({pipelineUUID:null===t||void 0===t?void 0:t.uuid,filesOnly:!0})},uuid:"download_without_folder_structure"},{label:function(){return"Add/Remove tags"},onClick:function(){n.push("/pipelines/[pipeline]/settings","/pipelines/".concat(null===t||void 0===t?void 0:t.uuid,"/settings"))},uuid:"add_tags"},{label:function(){return"Create template"},onClick:function(){n.push("/templates?object_type=".concat(oe.R,"&new=1&pipeline_uuid=").concat(null===t||void 0===t?void 0:t.uuid))},uuid:"create_custom_template"},{label:function(){return"Create global data product"},onClick:function(){n.push("/global-data-products?object_type=".concat(z.b.PIPELINE,"&new=1&object_uuid=").concat(null===t||void 0===t?void 0:t.uuid))},uuid:"create_global_data_product"},{label:function(){return"Delete"},onClick:function(){window.confirm("Are you sure you want to delete pipeline ".concat(null===t||void 0===t?void 0:t.uuid,"?"))&&Mn(null===t||void 0===t?void 0:t.uuid)},uuid:"delete"}]},rightClickMenuHeight:252,rightClickMenuWidth:30*ue.iI,rowGroupHeaders:o,rows:null===e||void 0===e?void 0:e.map((function(e,i){var t=e.blocks,o=e.created_at,u=e.description,l=e.schedules,c=e.tags,s=e.type,a=e.updated_at,p=e.uuid,f=t.filter((function(e){var n=e.type;return V.tf.SCRATCHPAD!==n})).length,v=l.length,h=l.find((function(e){var n=e.status;return re.fq.ACTIVE===n})),g=(0,T.jsx)("div",{children:(0,T.jsx)(L.Z,{tags:null===c||void 0===c?void 0:c.map((function(e){return{uuid:e}}))})},"pipeline_tags_".concat(i));return[v>=1||De[p]?(0,T.jsx)(m.ZP,{iconOnly:!0,loading:!!De[p],noBackground:!0,noBorder:!0,noPadding:!0,onClick:function(n){(0,ge.j)(n),Ne((function(e){return Ce(Ce({},e),{},(0,r.Z)({},p,!0))})),An(Ce(Ce({},e),{},{status:h?re.fq.INACTIVE:re.fq.ACTIVE}))},children:h?(0,T.jsx)(W.dz,{muted:!0,size:2*ue.iI}):(0,T.jsx)(W.Py,{default:!0,size:2*ue.iI})}):null,(0,T.jsx)(k.ZP,{default:!h,monospace:!0,success:!!h,children:h?re.fq.ACTIVE:v>=1?re.fq.INACTIVE:"no schedules"},"pipeline_status_".concat(i)),(0,T.jsx)(d(),{as:"/pipelines/".concat(p),href:"/pipelines/[pipeline]",passHref:!0,children:(0,T.jsx)(E.Z,{sameColorAsText:!0,children:p})},"pipeline_name_".concat(i)),(0,T.jsx)(k.ZP,{default:!0,preWrap:!0,title:u,children:u},"pipeline_description_".concat(i)),(0,T.jsx)(k.ZP,{children:S.G7[s]},"pipeline_type_".concat(i)),(0,T.jsx)(k.ZP,{monospace:!0,small:!0,title:a?(0,de._6)(a):null,children:a?(0,de.XG)(a,$e):(0,T.jsx)(T.Fragment,{children:"\u2014"})},"pipeline_updated_at_".concat(i)),(0,T.jsx)(k.ZP,{monospace:!0,small:!0,title:o?(0,de._6)(o):null,children:o?(0,de.XG)(o.slice(0,19),$e):(0,T.jsx)(T.Fragment,{children:"\u2014"})},"pipeline_created_at_".concat(i)),g,(0,T.jsx)(k.ZP,{default:0===f,monospace:!0,children:f},"pipeline_block_count_".concat(i)),(0,T.jsx)(k.ZP,{default:0===v,monospace:!0,children:v},"pipeline_trigger_count_".concat(i)),(0,T.jsxs)(Z.Z,{flex:1,justifyContent:"flex-end",children:[(0,T.jsx)(m.ZP,Ce(Ce({},ye),{},{onClick:function(){bn({pipelineUUID:p})},title:"Download (keep folder structure)",children:(0,T.jsx)(W.vc,{default:!0,size:2*ue.iI})})),(0,T.jsx)(I.Z,{mr:1}),(0,T.jsx)(m.ZP,Ce(Ce({},ye),{},{onClick:function(){n.push("/pipelines/[pipeline]","/pipelines/".concat(p))},title:"Detail",children:(0,T.jsx)(W.UY,{default:!0,size:2*ue.iI})})),(0,T.jsx)(I.Z,{mr:1}),(0,T.jsx)(m.ZP,Ce(Ce({},ye),{},{onClick:function(){n.push("/pipelines/[pipeline]/logs","/pipelines/".concat(p,"/logs"))},title:"Logs",children:(0,T.jsx)(W.$B,{default:!0,size:2*ue.iI})}))]},"chevron_icon_".concat(i))]})),rowsGroupedByIndex:u,setRowsSorted:l,sortableColumnIndexes:an,sortedColumn:vn,stickyHeader:!0})}),[kn,Mn,bn,$e,cn,De,n,y,Ne,P,Ln,an,vn,qe,An]),ji=(0,a.useMemo)((function(){return Zi(on,sn,hi,mi,je)}),[on,sn,Zi,hi,mi,je]),Ci=(0,a.useMemo)((function(){return Zi(un,dn,bi,xi,Ae)}),[un,dn,Zi,bi,xi,Ae]),_i=(0,a.useMemo)((function(){return(null===on||void 0===on?void 0:on.length)||0}),[on]),wi=(0,a.useMemo)((function(){return(null===un||void 0===un?void 0:un.length)||0}),[un]),Ii=(0,a.useMemo)((function(){return(!ze||we.uuid===mn)&&!_i||ze&&_e.uuid===mn&&!wi}),[ze,_i,wi,mn]);return(0,T.jsxs)(x.Z,{errors:Le,setErrors:Ue,subheaderChildren:ni,title:"Pipelines",uuid:"pipelines/index",children:[ze&&(0,T.jsx)(I.Z,{pb:hn?0:ue.cd,pt:ue.cd,px:ue.cd,ref:i,children:(0,T.jsx)(g.Z,{noPadding:!0,onClickTab:function(e){var n=e.uuid;return(0,ve.u7)((0,r.Z)({},ke,n),{pushHistory:!0})},regularSizeText:!0,selectedTabUUID:mn,tabs:Ie})}),Ii?(0,T.jsx)(I.Z,{p:ue.Mq,children:Qe?(0,T.jsx)(k.ZP,{bold:!0,default:!0,monospace:!0,muted:!0,children:"No pipelines available"}):(0,T.jsx)(N.Z,{inverted:!0,large:!0})}):null,(0,T.jsxs)(ce.cl,{hide:Ii,includePadding:!!hn,maxHeight:"calc(100vh - ".concat(q.Mz+74+(c||0),"px)"),children:[(!ze||we.uuid===mn)&&ji,ze&&_e.uuid===mn&&Ci]})]})}Pe.getInitialProps=(0,t.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 Te=(0,M.Z)(Pe)},44952:function(e,n,i){"use strict";i.d(n,{K:function(){return o}});var t=i(4383);function o(e){var n=(0,t.ZP)("downloads",e),i=document.createElement("a");i.href=n,document.body.appendChild(i),i.click(),window.URL.revokeObjectURL(n),document.body.removeChild(i)}},79274:function(e,n,i){(window.__NEXT_P=window.__NEXT_P||[]).push(["/pipelines",function(){return i(55620)}])}},function(e){e.O(0,[2678,1154,844,5820,6639,1124,341,1751,1821,4267,600,8487,8264,7858,5499,4366,722,5810,1769,1550,90,9264,5544,1952,9774,2888,179],(function(){return n=79274,e(e.s=n);var n}));var n=e.O();_N_E=n}]);
@@ -1 +0,0 @@
1
- (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6308],{65956:function(n,e,t){"use strict";var i=t(38626),o=t(55485),r=t(38276),c=t(30160),a=t(44897),l=t(42631),d=t(47041),u=t(70515),s=t(28598),h=(0,i.css)(["padding:","px;padding-bottom:","px;padding-top:","px;"],2*u.iI,1.5*u.iI,1.5*u.iI),f=i.default.div.withConfig({displayName:"Panel__PanelStyle",componentId:"sc-1ct8cgl-0"})(["border-radius:","px;overflow:hidden;"," "," "," "," "," "," "," "," "," "," "," ",""],l.n_,(function(n){return n.fullWidth&&"\n width: 100%;\n "}),(function(n){return!n.borderless&&"\n border: 1px solid ".concat((n.theme.interactive||a.Z.interactive).defaultBorder,";\n ")}),(function(n){return n.success&&"\n background-color: ".concat((n.theme.background||a.Z.background).successLight,";\n ")}),(function(n){return n.success&&!n.borderless&&"\n border: 1px solid ".concat((n.theme.background||a.Z.background).success,";\n ")}),(function(n){return!n.dark&&!n.success&&"\n background-color: ".concat((n.theme.background||a.Z.background).panel,";\n ")}),(function(n){return n.dark&&"\n background-color: ".concat((n.theme.background||a.Z.background).content,";\n ")}),(function(n){return!n.fullHeight&&"\n height: fit-content;\n "}),(function(n){return n.maxHeight&&"\n max-height: ".concat(n.maxHeight,";\n ")}),(function(n){return n.maxWidth&&"\n max-width: ".concat(n.maxWidth,"px;\n ")}),(function(n){return n.minWidth&&"\n min-width: ".concat(n.minWidth,"px;\n\n @media (max-width: ").concat(n.minWidth,"px) {\n min-width: 0;\n }\n ")}),(function(n){return n.borderless&&"\n border: none;\n "}),(function(n){return n.overflowVisible&&"\n overflow: visible;\n "})),p=i.default.div.withConfig({displayName:"Panel__HeaderStyle",componentId:"sc-1ct8cgl-1"})(["border-top-left-radius:","px;border-top-right-radius:","px;"," "," "," ",""],l.n_,l.n_,(function(n){return"\n background-color: ".concat((n.theme.background||a.Z.background).chartBlock,";\n border-bottom: 1px solid ").concat((n.theme.interactive||a.Z.interactive).defaultBorder,";\n ")}),(function(n){return n.height&&"\n height: ".concat(n.height,"px;\n ")}),h,(function(n){return n.headerPaddingVertical&&"\n padding-bottom: ".concat(n.headerPaddingVertical,"px;\n padding-top: ").concat(n.headerPaddingVertical,"px;\n ")})),m=i.default.div.withConfig({displayName:"Panel__ContentStyle",componentId:"sc-1ct8cgl-2"})(["overflow-y:auto;padding:","px;height:100%;"," "," "," "," ",""],1.75*u.iI,d.w5,(function(n){return n.height&&"\n height: ".concat(n.height,"px;\n ")}),(function(n){return n.maxHeight&&"\n max-height: calc(".concat(n.maxHeight," - ").concat(15*u.iI,"px);\n ")}),(function(n){return n.noPadding&&"\n padding: 0;\n "}),(function(n){return n.overflowVisible&&"\n overflow: visible;\n "})),g=i.default.div.withConfig({displayName:"Panel__FooterStyle",componentId:"sc-1ct8cgl-3"})(["border-style:",";border-top-width:","px;padding:","px;"],l.M8,l.YF,1.75*u.iI);e.Z=function(n){var e=n.borderless,t=n.children,i=n.containerRef,a=n.contentContainerRef,l=n.dark,d=n.footer,u=n.fullHeight,h=void 0===u||u,x=n.fullWidth,b=void 0===x||x,y=n.header,w=n.headerHeight,v=n.headerIcon,_=n.headerPaddingVertical,j=n.headerTitle,I=n.maxHeight,Z=n.maxWidth,N=n.minWidth,H=n.noPadding,P=n.overflowVisible,k=n.subtitle,S=n.success;return(0,s.jsxs)(f,{borderless:e,dark:l,fullHeight:h,fullWidth:b,maxHeight:I,maxWidth:Z,minWidth:N,overflowVisible:P,ref:i,success:S,children:[(y||j)&&(0,s.jsxs)(p,{headerPaddingVertical:_,height:w,children:[y&&y,j&&(0,s.jsx)(o.ZP,{alignItems:"center",justifyContent:"space-between",children:(0,s.jsxs)(o.ZP,{alignItems:"center",children:[v&&v,(0,s.jsx)(r.Z,{ml:v?1:0,children:(0,s.jsx)(c.ZP,{bold:!0,default:!0,children:j})})]})})]}),(0,s.jsxs)(m,{maxHeight:I,noPadding:H,overflowVisible:P,ref:a,children:[k&&(0,s.jsx)(r.Z,{mb:2,children:(0,s.jsx)(c.ZP,{default:!0,children:k})}),t]}),d&&(0,s.jsx)(g,{children:d})]})}},85854:function(n,e,t){"use strict";var i,o,r,c,a,l,d,u,s=t(82394),h=t(26304),f=t(26653),p=t(38626),m=t(33591),g=t(44897),x=t(95363),b=t(61896),y=t(30160),w=t(70515),v=t(38276),_=t(28598),j=["children","condensed","inline","level","marketing","spacingBelow"];function I(n,e){var t=Object.keys(n);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(n);e&&(i=i.filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),t.push.apply(t,i)}return t}function Z(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{};e%2?I(Object(t),!0).forEach((function(e){(0,s.Z)(n,e,t[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(t)):I(Object(t)).forEach((function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(t,e))}))}return n}var N=(0,p.css)([""," margin:0;"," "," "," "," "," "," "," "," "," "," "," "," "," ",""],y.IH,(function(n){return n.color&&"\n color: ".concat(n.color,"\n ")}),(function(n){return n.yellow&&"\n color: ".concat((n.theme.accent||g.Z.accent).yellow,";\n ")}),(function(n){return n.center&&"\n text-align: center;\n "}),(function(n){return!n.monospace&&0===Number(n.weightStyle)&&"\n font-family: ".concat(x.iI,";\n ")}),(function(n){return!n.monospace&&1===Number(n.weightStyle)&&"\n font-family: ".concat(x.LX,";\n ")}),(function(n){return!n.monospace&&2===Number(n.weightStyle)&&"\n font-family: ".concat(x.LX,";\n ")}),(function(n){return!n.monospace&&3===Number(n.weightStyle)&&"\n font-family: ".concat(x.ry,";\n ")}),(function(n){return!n.monospace&&4===Number(n.weightStyle)&&"\n font-family: ".concat(x.YC,";\n ")}),(function(n){return!n.monospace&&5===Number(n.weightStyle)&&"\n font-family: ".concat(x.nF,";\n ")}),(function(n){return!n.monospace&&(6===Number(n.weightStyle)||n.bold)&&"\n font-family: ".concat(x.nF,";\n ")}),(function(n){return!n.monospace&&7===Number(n.weightStyle)&&"\n font-family: ".concat(x.nF,";\n ")}),(function(n){return!n.monospace&&8===Number(n.weightStyle)&&"\n font-family: ".concat(x.nF,";\n ")}),(function(n){return n.lineHeightAuto&&"\n line-height: normal !important;\n "}),(function(n){return n.strikethrough&&"\n text-decoration: line-through;\n "})),H=p.default.div.withConfig({displayName:"Headline__HeadlineContainerStyle",componentId:"sc-12jzt2e-0"})(["",""],(function(n){return"\n color: ".concat((n.theme.content||g.Z.content).active,";\n ")})),P=p.default.h1.withConfig({displayName:"Headline__H1HeroStyle",componentId:"sc-12jzt2e-1"})([""," font-size:42px;line-height:56px;"," "," ",""],N,m.media.md(i||(i=(0,f.Z)(["\n ","\n "])),b.aQ),m.media.lg(o||(o=(0,f.Z)(["\n ","\n "])),b.aQ),m.media.xl(r||(r=(0,f.Z)(["\n ","\n "])),b.aQ)),k=p.default.h1.withConfig({displayName:"Headline__H1Style",componentId:"sc-12jzt2e-2"})([""," ",""],N,b.MJ),S=p.default.h1.withConfig({displayName:"Headline__H1MarketingStyle",componentId:"sc-12jzt2e-3"})([""," "," "," "," "," ",""],N,m.media.xs(c||(c=(0,f.Z)(["\n font-size: ","px;\n line-height: ","px;\n "])),6*w.iI,7*w.iI),m.media.sm(a||(a=(0,f.Z)(["\n font-size: ","px;\n line-height: ","px;\n "])),6*w.iI,7*w.iI),m.media.md(l||(l=(0,f.Z)(["\n font-size: ","px;\n line-height: ","px;\n "])),6*w.iI,7*w.iI),m.media.lg(d||(d=(0,f.Z)(["\n font-size: ","px;\n line-height: ","px;\n "])),6*w.iI,7*w.iI),m.media.xl(u||(u=(0,f.Z)(["\n font-size: ","px;\n line-height: ","px;\n "])),6*w.iI,7*w.iI)),C=p.default.h2.withConfig({displayName:"Headline__H2Style",componentId:"sc-12jzt2e-4"})([""," ",""],N,b.BL),z=p.default.h3.withConfig({displayName:"Headline__H3Style",componentId:"sc-12jzt2e-5"})([""," font-size:24px;line-height:32px;"],N),O=p.default.h4.withConfig({displayName:"Headline__H4Style",componentId:"sc-12jzt2e-6"})([""," font-size:20px;line-height:28px;"],N),W=p.default.h5.withConfig({displayName:"Headline__H5Style",componentId:"sc-12jzt2e-7"})([""," font-size:18px;line-height:26px;"],N),V=p.default.span.withConfig({displayName:"Headline__SpanStyle",componentId:"sc-12jzt2e-8"})([""," "," "," "," ",""],N,(function(n){return 1===n.level&&"\n ".concat(b.MJ,"\n ")}),(function(n){return 2===n.level&&"\n ".concat(b.BL,"\n ")}),(function(n){return 3===n.level&&"\n font-size: 24px;\n line-height: 32px;\n "}),(function(n){return 4===n.level&&"\n font-size: 20px;\n line-height: 28px;\n "})),B=function(n){var e,t=n.children,i=n.condensed,o=n.inline,r=n.level,c=n.marketing,a=n.spacingBelow,l=(0,h.Z)(n,j);o?e=V:0===Number(r)?e=P:1===Number(r)?e=c?S:k:2===Number(r)?e=C:3===Number(r)?e=z:4===Number(r)?e=O:5===Number(r)&&(e=W);var d=(0,_.jsxs)(e,Z(Z({},l),{},{level:r,children:[a&&(0,_.jsx)(v.Z,{mb:i?2:3,children:t}),!a&&t]}));return o?d:(0,_.jsx)(H,{children:d})};B.defaultProps={level:3,weightStyle:6},e.Z=B},86627:function(n,e,t){"use strict";t.r(e);var i=t(77837),o=t(38860),r=t.n(o),c=t(65956),a=t(93808),l=t(28274),d=t(38276),u=t(36043),s=t(35686),h=t(70515),f=t(24755),p=t(50178),m=t(28598);function g(){var n=((0,p.PR)()||{}).id,e=s.ZP.users.detail(n),t=e.data,i=e.mutate,o=null===t||void 0===t?void 0:t.user;return(0,m.jsx)(l.Z,{uuidItemSelected:f.DQ,uuidWorkspaceSelected:f.tC,children:(0,m.jsx)(d.Z,{p:h.cd,children:(0,m.jsx)(c.Z,{children:(0,m.jsx)(u.Z,{disabledFields:["roles"],onSaveSuccess:i,user:o})})})})}g.getInitialProps=(0,i.Z)(r().mark((function n(){return r().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.abrupt("return",{});case 1:case"end":return n.stop()}}),n)}))),e.default=(0,a.Z)(g)},10736:function(n,e,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/settings/account/profile",function(){return t(86627)}])}},function(n){n.O(0,[2678,1154,844,4267,600,8487,8264,8432,6043,9774,2888,179],(function(){return e=10736,n(n.s=e);var e}));var e=n.O();_N_E=e}]);
@@ -1 +0,0 @@
1
- (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3853],{55729:function(e,n,t){"use strict";t.d(n,{Z:function(){return L}});var i=t(82394),r=t(75582),o=t(82684),c=t(69864),l=t(71180),a=t(15338),d=t(97618),s=t(55485),u=t(85854),p=t(48670),f=t(65956),h=t(82359),g=t(57114),m=t(38276),j=t(30160),x=t(17488),v=t(69650),b=t(12468),y=t(35686),Z=t(38626),w=t(44897),O=t(42631),P=t(70515),_=Z.default.div.withConfig({displayName:"indexstyle__ContainerStyle",componentId:"sc-1b0w59t-0"})(["border-radius:","px;padding:","px;",""],O.n_,P.cd*P.iI,(function(e){return"\n background-color: ".concat((e.theme.background||w.Z.background).codeArea,";\n ")})),k=t(72473),I=t(72191),C=t(81728),S=t(72619),H=t(70320),N=t(23780),z=t(28598);function D(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,i)}return t}function E(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?D(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):D(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var L=function(e){var n,t,Z,w=e.cancelButtonText,O=e.contained,D=e.header,L=e.onCancel,W=e.onSaveSuccess,M=(0,N.VI)(null,{},[],{uuid:"settings/workspace/preferences"}),V=(0,r.Z)(M,1)[0],B=(0,o.useState)(null),A=B[0],F=B[1],R=(0,o.useState)(!1),T=R[0],U=R[1],X=y.ZP.projects.list(),q=X.data,Q=X.mutate,Y=(0,o.useMemo)((function(){var e;return null===q||void 0===q||null===(e=q.projects)||void 0===e?void 0:e[0]}),[q]),J=Y||{},G=J.name,K=J.openai_api_key,$=J.project_uuid,ee=(0,o.useMemo)((function(){return"demo.mage.ai"===window.location.hostname}),[]);(0,o.useEffect)((function(){A||F(Y)}),[Y,A]);var ne=(0,c.Db)(y.ZP.projects.useUpdate(G),{onSuccess:function(e){return(0,S.wD)(e,{callback:function(e){var n,t=e.project;Q(),F(t),U(!1),(0,H.h)(null===t||void 0===t||null===(n=t.features)||void 0===n?void 0:n[h.d.LOCAL_TIMEZONE]),W&&(null===W||void 0===W||W(t))},onErrorCallback:function(e,n){return V({errors:n,response:e})}})}}),te=(0,r.Z)(ne,2),ie=te[0],re=te[1].isLoading,oe=(0,o.useCallback)((function(e){return ie({project:e})}),[ie]),ce=(0,z.jsxs)(z.Fragment,{children:[D,(0,z.jsxs)(f.Z,{noPadding:!0,children:[(0,z.jsxs)(m.Z,{p:P.cd,children:[(0,z.jsx)(m.Z,{mb:1,children:(0,z.jsx)(u.Z,{level:5,children:"Project name"})}),(0,z.jsx)(j.ZP,{default:!0,monospace:!0,children:G})]}),(0,z.jsx)(a.Z,{light:!0}),(0,z.jsxs)(m.Z,{p:P.cd,children:[(0,z.jsx)(m.Z,{mb:1,children:(0,z.jsx)(u.Z,{level:5,children:"Project UUID"})}),(0,z.jsx)(j.ZP,{default:!!$,monospace:!0,muted:!$,children:$||"Not required"})]}),(0,z.jsx)(a.Z,{light:!0}),(0,z.jsx)(m.Z,{p:P.cd,children:(0,z.jsxs)(s.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,z.jsxs)(d.Z,{flexDirection:"column",children:[(0,z.jsx)(m.Z,{mb:1,children:(0,z.jsx)(u.Z,{level:5,children:"Help improve Mage"})}),(0,z.jsxs)(j.ZP,{default:!0,children:["Please contribute usage statistics to help improve the developer experience for you and everyone in the community. Learn more ",(0,z.jsx)(p.Z,{href:"https://docs.mage.ai/contributing/statistics/overview",openNewWindow:!0,children:"here"}),"."]})]}),(0,z.jsx)(m.Z,{mr:P.cd}),(0,z.jsx)(v.Z,{compact:!0,checked:null===A||void 0===A?void 0:A.help_improve_mage,onCheck:function(){return F((function(e){return E(E({},e),{},{help_improve_mage:!(null!==A&&void 0!==A&&A.help_improve_mage)})}))}})]})})]}),(0,z.jsx)(m.Z,{mt:P.HN}),(0,z.jsx)(g.Z,{description:"Global settings that are applied to all pipelines in this project.",title:"Pipeline settings",children:(0,z.jsx)(g.S,{description:"Every time a trigger is created or updated in this pipeline, automatically persist it in code.",title:"Save triggers in code automatically",toggleSwitch:{checked:!(null===A||void 0===A||null===(n=A.pipelines)||void 0===n||null===(t=n.settings)||void 0===t||null===(Z=t.triggers)||void 0===Z||!Z.save_in_code_automatically),onCheck:function(e){return F((function(n){var t,i,r,o,c,l;return E(E({},n),{},{pipelines:E(E({},null===n||void 0===n?void 0:n.pipelines),{},{settings:E(E({},null===n||void 0===n||null===(t=n.pipelines)||void 0===t?void 0:t.settings),{},{triggers:E(E({},null===n||void 0===n||null===(i=n.pipelines)||void 0===i||null===(r=i.settings)||void 0===r?void 0:r.triggers),{},{save_in_code_automatically:e(null===n||void 0===n||null===(o=n.pipelines)||void 0===o||null===(c=o.settings)||void 0===c||null===(l=c.triggers)||void 0===l?void 0:l.save_in_code_automatically)})})})})}))}}})}),(0,z.jsx)(m.Z,{mt:P.HN}),(0,z.jsx)(f.Z,{noPadding:!0,overflowVisible:!0,children:(0,z.jsxs)(m.Z,{p:P.cd,children:[(0,z.jsx)(m.Z,{mb:1,children:(0,z.jsx)(u.Z,{level:5,children:"Features"})}),Object.entries((null===A||void 0===A?void 0:A.features)||{}).map((function(e,n){var t=(0,r.Z)(e,2),o=t[0],c=t[1];return(0,z.jsx)(m.Z,{mt:0===n?0:1,children:(0,z.jsxs)(s.ZP,{alignItems:"center",children:[(0,z.jsx)(v.Z,{checked:!!c,compact:!0,onCheck:function(){return F((function(e){return E(E({},e),{},{features:E(E({},null===A||void 0===A?void 0:A.features),{},(0,i.Z)({},o,!c))})}))}}),(0,z.jsx)(m.Z,{mr:P.cd}),(0,z.jsxs)(d.Z,{children:[(0,z.jsx)(j.ZP,{default:!c,monospace:!0,children:(0,C.vg)(o)}),o===h.d.LOCAL_TIMEZONE&&(0,z.jsx)(m.Z,{ml:1,children:(0,z.jsx)(b.Z,{block:!0,description:"Display dates in local timezone. Please note that certain pages (e.g. Monitor page) or components (e.g. Pipeline run bar charts) may still be in UTC time. Dates in local time will have a timezone offset in the timestamp (e.g. -07:00).",lightBackground:!0,muted:!0,size:I._k})})]})]})},o)}))]})}),(0,z.jsx)(m.Z,{mt:P.HN}),(0,z.jsx)(f.Z,{noPadding:!0,children:(0,z.jsxs)(m.Z,{p:P.cd,children:[(0,z.jsx)(m.Z,{mb:1,children:(0,z.jsx)(u.Z,{level:5,children:"OpenAI"})}),K&&!T?(0,z.jsxs)(s.ZP,E(E({},s.A0),{},{children:[(0,z.jsx)(j.ZP,{default:!0,monospace:!0,children:"API key: ********"}),(0,z.jsx)(l.ZP,{iconOnly:!0,onClick:function(){return U(!0)},secondary:!0,title:"Edit",children:(0,z.jsx)(k.I8,{size:I.bL})})]})):(0,z.jsx)(x.Z,{disabled:ee,label:ee?"Entering API key is disabled on demo":"API key",monospace:!0,onChange:function(e){return F((function(n){return E(E({},n),{},{openai_api_key:e.target.value})}))},primary:!0,setContentOnMount:!0,value:(null===A||void 0===A?void 0:A.openai_api_key)||""})]})}),(0,z.jsx)(m.Z,{mt:P.HN}),(0,z.jsxs)(s.ZP,{alignItems:"center",children:[(0,z.jsx)(l.ZP,{loading:re,onClick:function(){oe({features:null===A||void 0===A?void 0:A.features,help_improve_mage:null===A||void 0===A?void 0:A.help_improve_mage,openai_api_key:null===A||void 0===A?void 0:A.openai_api_key,pipelines:null===A||void 0===A?void 0:A.pipelines})},primary:!0,children:"Save project settings"}),L&&(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(m.Z,{mr:P.cd}),(0,z.jsx)(l.ZP,{onClick:L,secondary:!0,children:w||"Cancel"})]})]})]});return O?(0,z.jsx)(_,{children:ce}):ce}},70320:function(e,n,t){"use strict";t.d(n,{h:function(){return c},q:function(){return o}});var i=t(78419),r=t(53808);function o(){return(0,r.U2)(i.am,null)||!1}function c(e){return"undefined"!==typeof e&&(0,r.t8)(i.am,e),e}},46568:function(e,n,t){"use strict";var i=t(82394),r=t(26304),o=(t(82684),t(33591)),c=t(28598),l=["children","fullHeight","gutter","style"];function a(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,i)}return t}function d(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,i.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}n.Z=function(e){var n=e.children,t=e.fullHeight,i=e.gutter,a=e.style,s=void 0===a?{}:a,u=(0,r.Z)(e,l),p=d({},s);return i&&(p.paddingLeft=i,p.paddingRight=p.paddingLeft),t&&(p.height="100%"),(0,c.jsx)(o.Col,d(d({},u),{},{style:p,children:n}))}},82682:function(e,n,t){"use strict";var i=t(82394),r=t(26304),o=t(82684),c=t(33591),l=t(28598),a=["children","fullHeight","gutter","justifyContent","style"];function d(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,i)}return t}function s(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?d(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):d(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}n.Z=function(e){var n=e.children,t=e.fullHeight,i=e.gutter,d=e.justifyContent,u=e.style,p=void 0===u?{}:u,f=(0,r.Z)(e,a),h=s({},p);return i&&(h.marginLeft=-1*i,h.marginRight=h.marginLeft),t&&(h.height="100%"),(0,l.jsx)(c.Row,s(s({},f),{},{justifyContent:d,style:h,children:o.Children.map(n,(function(e,n){return e&&o.cloneElement(e,{gutter:i,key:n})}))}))}},57114:function(e,n,t){"use strict";t.d(n,{S:function(){return y},Z:function(){return Z}});var i=t(82684),r=t(15338),o=t(97618),c=t(55485),l=t(85854),a=t(65956),d=t(82394),s=t(44085),u=t(38276),p=t(30160),f=t(17488),h=t(69650),g=t(72473),m=t(8193),j=t(70515),x=t(28598);function v(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,i)}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,d.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 y=function(e){var n,t=e.children,i=e.description,r=e.invalid,l=e.selectInput,a=e.textInput,d=e.title,v=e.toggleSwitch,y=e.warning;return(0,x.jsx)(u.Z,{p:j.cd,children:(0,x.jsxs)(c.ZP,{alignItems:"center",children:[(0,x.jsxs)(c.ZP,{flexDirection:"column",children:[(0,x.jsxs)(p.ZP,{danger:r,default:!0,large:!0,warning:y,children:[d," ",r&&(0,x.jsx)(p.ZP,{danger:!0,inline:!0,large:!0,children:"is required"})]}),i&&"string"===typeof i&&(0,x.jsx)(p.ZP,{muted:!0,small:!0,children:i}),i&&"string"!==typeof i&&i]}),(0,x.jsx)(u.Z,{mr:j.cd}),(0,x.jsxs)(o.Z,{flex:1,justifyContent:"flex-end",children:[t,a&&(0,x.jsx)(f.Z,b({afterIcon:(0,x.jsx)(g.I8,{}),afterIconClick:function(e,n){var t;null===n||void 0===n||null===(t=n.current)||void 0===t||t.focus()},afterIconSize:m.Z,alignRight:!0,autoComplete:"off",large:!0,noBackground:!0,noBorder:!0,fullWidth:!0,paddingHorizontal:0,paddingVertical:0,setContentOnMount:!0},a)),l&&(0,x.jsx)(s.Z,b(b({},l),{},{afterIcon:(0,x.jsx)(g._M,{}),afterIconSize:m.Z,alignRight:!0,autoComplete:"off",large:!0,noBackground:!0,noBorder:!0,paddingHorizontal:0,paddingVertical:0,setContentOnMount:!0,children:null===l||void 0===l||null===(n=l.options)||void 0===n?void 0:n.map((function(e){var n=e.label,t=e.value;return(0,x.jsx)("option",{value:t,children:n||t},t)}))})),v&&(0,x.jsx)(h.Z,{checked:!(null===v||void 0===v||!v.checked),compact:!0,onCheck:null===v||void 0===v?void 0:v.onCheck})]})]})})},Z=function(e){var n=e.children,t=e.description,d=e.headerChildren,s=e.title;return(0,x.jsxs)(a.Z,{noPadding:!0,children:[(0,x.jsx)(u.Z,{p:j.cd,children:(0,x.jsxs)(c.ZP,{alignItems:"center",children:[(0,x.jsxs)(o.Z,{flex:1,flexDirection:"column",children:[(0,x.jsx)(l.Z,{level:4,children:s}),t&&"string"===typeof t&&(0,x.jsx)(u.Z,{mt:1,children:(0,x.jsx)(p.ZP,{muted:!0,children:t})}),t&&"string"!==typeof t&&t]}),d]})}),i.Children.map(n,(function(e,n){return(0,x.jsxs)("div",{children:[(0,x.jsx)(r.Z,{light:!0}),e]},"".concat(s,"-").concat(n))}))]})}},8193:function(e,n,t){"use strict";t.d(n,{N:function(){return a},Z:function(){return l}});var i=t(38626),r=t(44897),o=t(42631),c=t(70515),l=2*c.iI,a=i.default.div.withConfig({displayName:"indexstyle__ContainerStyle",componentId:"sc-1ck7mzt-0"})(["border-radius:","px;padding:","px;",""],o.n_,c.cd*c.iI,(function(e){return"\n background-color: ".concat((e.theme.background||r.Z.background).codeArea,";\n ")}))},65956:function(e,n,t){"use strict";var i=t(38626),r=t(55485),o=t(38276),c=t(30160),l=t(44897),a=t(42631),d=t(47041),s=t(70515),u=t(28598),p=(0,i.css)(["padding:","px;padding-bottom:","px;padding-top:","px;"],2*s.iI,1.5*s.iI,1.5*s.iI),f=i.default.div.withConfig({displayName:"Panel__PanelStyle",componentId:"sc-1ct8cgl-0"})(["border-radius:","px;overflow:hidden;"," "," "," "," "," "," "," "," "," "," "," ",""],a.n_,(function(e){return e.fullWidth&&"\n width: 100%;\n "}),(function(e){return!e.borderless&&"\n border: 1px solid ".concat((e.theme.interactive||l.Z.interactive).defaultBorder,";\n ")}),(function(e){return e.success&&"\n background-color: ".concat((e.theme.background||l.Z.background).successLight,";\n ")}),(function(e){return e.success&&!e.borderless&&"\n border: 1px solid ".concat((e.theme.background||l.Z.background).success,";\n ")}),(function(e){return!e.dark&&!e.success&&"\n background-color: ".concat((e.theme.background||l.Z.background).panel,";\n ")}),(function(e){return e.dark&&"\n background-color: ".concat((e.theme.background||l.Z.background).content,";\n ")}),(function(e){return!e.fullHeight&&"\n height: fit-content;\n "}),(function(e){return e.maxHeight&&"\n max-height: ".concat(e.maxHeight,";\n ")}),(function(e){return e.maxWidth&&"\n max-width: ".concat(e.maxWidth,"px;\n ")}),(function(e){return e.minWidth&&"\n min-width: ".concat(e.minWidth,"px;\n\n @media (max-width: ").concat(e.minWidth,"px) {\n min-width: 0;\n }\n ")}),(function(e){return e.borderless&&"\n border: none;\n "}),(function(e){return e.overflowVisible&&"\n overflow: visible;\n "})),h=i.default.div.withConfig({displayName:"Panel__HeaderStyle",componentId:"sc-1ct8cgl-1"})(["border-top-left-radius:","px;border-top-right-radius:","px;"," "," "," ",""],a.n_,a.n_,(function(e){return"\n background-color: ".concat((e.theme.background||l.Z.background).chartBlock,";\n border-bottom: 1px solid ").concat((e.theme.interactive||l.Z.interactive).defaultBorder,";\n ")}),(function(e){return e.height&&"\n height: ".concat(e.height,"px;\n ")}),p,(function(e){return e.headerPaddingVertical&&"\n padding-bottom: ".concat(e.headerPaddingVertical,"px;\n padding-top: ").concat(e.headerPaddingVertical,"px;\n ")})),g=i.default.div.withConfig({displayName:"Panel__ContentStyle",componentId:"sc-1ct8cgl-2"})(["overflow-y:auto;padding:","px;height:100%;"," "," "," "," ",""],1.75*s.iI,d.w5,(function(e){return e.height&&"\n height: ".concat(e.height,"px;\n ")}),(function(e){return e.maxHeight&&"\n max-height: calc(".concat(e.maxHeight," - ").concat(15*s.iI,"px);\n ")}),(function(e){return e.noPadding&&"\n padding: 0;\n "}),(function(e){return e.overflowVisible&&"\n overflow: visible;\n "})),m=i.default.div.withConfig({displayName:"Panel__FooterStyle",componentId:"sc-1ct8cgl-3"})(["border-style:",";border-top-width:","px;padding:","px;"],a.M8,a.YF,1.75*s.iI);n.Z=function(e){var n=e.borderless,t=e.children,i=e.containerRef,l=e.contentContainerRef,a=e.dark,d=e.footer,s=e.fullHeight,p=void 0===s||s,j=e.fullWidth,x=void 0===j||j,v=e.header,b=e.headerHeight,y=e.headerIcon,Z=e.headerPaddingVertical,w=e.headerTitle,O=e.maxHeight,P=e.maxWidth,_=e.minWidth,k=e.noPadding,I=e.overflowVisible,C=e.subtitle,S=e.success;return(0,u.jsxs)(f,{borderless:n,dark:a,fullHeight:p,fullWidth:x,maxHeight:O,maxWidth:P,minWidth:_,overflowVisible:I,ref:i,success:S,children:[(v||w)&&(0,u.jsxs)(h,{headerPaddingVertical:Z,height:b,children:[v&&v,w&&(0,u.jsx)(r.ZP,{alignItems:"center",justifyContent:"space-between",children:(0,u.jsxs)(r.ZP,{alignItems:"center",children:[y&&y,(0,u.jsx)(o.Z,{ml:y?1:0,children:(0,u.jsx)(c.ZP,{bold:!0,default:!0,children:w})})]})})]}),(0,u.jsxs)(g,{maxHeight:O,noPadding:k,overflowVisible:I,ref:l,children:[C&&(0,u.jsx)(o.Z,{mb:2,children:(0,u.jsx)(c.ZP,{default:!0,children:C})}),t]}),d&&(0,u.jsx)(m,{children:d})]})}},85854:function(e,n,t){"use strict";var i,r,o,c,l,a,d,s,u=t(82394),p=t(26304),f=t(26653),h=t(38626),g=t(33591),m=t(44897),j=t(95363),x=t(61896),v=t(30160),b=t(70515),y=t(38276),Z=t(28598),w=["children","condensed","inline","level","marketing","spacingBelow"];function O(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,i)}return t}function P(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?O(Object(t),!0).forEach((function(n){(0,u.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):O(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var _=(0,h.css)([""," margin:0;"," "," "," "," "," "," "," "," "," "," "," "," "," ",""],v.IH,(function(e){return e.color&&"\n color: ".concat(e.color,"\n ")}),(function(e){return e.yellow&&"\n color: ".concat((e.theme.accent||m.Z.accent).yellow,";\n ")}),(function(e){return e.center&&"\n text-align: center;\n "}),(function(e){return!e.monospace&&0===Number(e.weightStyle)&&"\n font-family: ".concat(j.iI,";\n ")}),(function(e){return!e.monospace&&1===Number(e.weightStyle)&&"\n font-family: ".concat(j.LX,";\n ")}),(function(e){return!e.monospace&&2===Number(e.weightStyle)&&"\n font-family: ".concat(j.LX,";\n ")}),(function(e){return!e.monospace&&3===Number(e.weightStyle)&&"\n font-family: ".concat(j.ry,";\n ")}),(function(e){return!e.monospace&&4===Number(e.weightStyle)&&"\n font-family: ".concat(j.YC,";\n ")}),(function(e){return!e.monospace&&5===Number(e.weightStyle)&&"\n font-family: ".concat(j.nF,";\n ")}),(function(e){return!e.monospace&&(6===Number(e.weightStyle)||e.bold)&&"\n font-family: ".concat(j.nF,";\n ")}),(function(e){return!e.monospace&&7===Number(e.weightStyle)&&"\n font-family: ".concat(j.nF,";\n ")}),(function(e){return!e.monospace&&8===Number(e.weightStyle)&&"\n font-family: ".concat(j.nF,";\n ")}),(function(e){return e.lineHeightAuto&&"\n line-height: normal !important;\n "}),(function(e){return e.strikethrough&&"\n text-decoration: line-through;\n "})),k=h.default.div.withConfig({displayName:"Headline__HeadlineContainerStyle",componentId:"sc-12jzt2e-0"})(["",""],(function(e){return"\n color: ".concat((e.theme.content||m.Z.content).active,";\n ")})),I=h.default.h1.withConfig({displayName:"Headline__H1HeroStyle",componentId:"sc-12jzt2e-1"})([""," font-size:42px;line-height:56px;"," "," ",""],_,g.media.md(i||(i=(0,f.Z)(["\n ","\n "])),x.aQ),g.media.lg(r||(r=(0,f.Z)(["\n ","\n "])),x.aQ),g.media.xl(o||(o=(0,f.Z)(["\n ","\n "])),x.aQ)),C=h.default.h1.withConfig({displayName:"Headline__H1Style",componentId:"sc-12jzt2e-2"})([""," ",""],_,x.MJ),S=h.default.h1.withConfig({displayName:"Headline__H1MarketingStyle",componentId:"sc-12jzt2e-3"})([""," "," "," "," "," ",""],_,g.media.xs(c||(c=(0,f.Z)(["\n font-size: ","px;\n line-height: ","px;\n "])),6*b.iI,7*b.iI),g.media.sm(l||(l=(0,f.Z)(["\n font-size: ","px;\n line-height: ","px;\n "])),6*b.iI,7*b.iI),g.media.md(a||(a=(0,f.Z)(["\n font-size: ","px;\n line-height: ","px;\n "])),6*b.iI,7*b.iI),g.media.lg(d||(d=(0,f.Z)(["\n font-size: ","px;\n line-height: ","px;\n "])),6*b.iI,7*b.iI),g.media.xl(s||(s=(0,f.Z)(["\n font-size: ","px;\n line-height: ","px;\n "])),6*b.iI,7*b.iI)),H=h.default.h2.withConfig({displayName:"Headline__H2Style",componentId:"sc-12jzt2e-4"})([""," ",""],_,x.BL),N=h.default.h3.withConfig({displayName:"Headline__H3Style",componentId:"sc-12jzt2e-5"})([""," font-size:24px;line-height:32px;"],_),z=h.default.h4.withConfig({displayName:"Headline__H4Style",componentId:"sc-12jzt2e-6"})([""," font-size:20px;line-height:28px;"],_),D=h.default.h5.withConfig({displayName:"Headline__H5Style",componentId:"sc-12jzt2e-7"})([""," font-size:18px;line-height:26px;"],_),E=h.default.span.withConfig({displayName:"Headline__SpanStyle",componentId:"sc-12jzt2e-8"})([""," "," "," "," ",""],_,(function(e){return 1===e.level&&"\n ".concat(x.MJ,"\n ")}),(function(e){return 2===e.level&&"\n ".concat(x.BL,"\n ")}),(function(e){return 3===e.level&&"\n font-size: 24px;\n line-height: 32px;\n "}),(function(e){return 4===e.level&&"\n font-size: 20px;\n line-height: 28px;\n "})),L=function(e){var n,t=e.children,i=e.condensed,r=e.inline,o=e.level,c=e.marketing,l=e.spacingBelow,a=(0,p.Z)(e,w);r?n=E:0===Number(o)?n=I:1===Number(o)?n=c?S:C:2===Number(o)?n=H:3===Number(o)?n=N:4===Number(o)?n=z:5===Number(o)&&(n=D);var d=(0,Z.jsxs)(n,P(P({},a),{},{level:o,children:[l&&(0,Z.jsx)(y.Z,{mb:i?2:3,children:t}),!l&&t]}));return r?d:(0,Z.jsx)(k,{children:d})};L.defaultProps={level:3,weightStyle:6},n.Z=L},72191:function(e,n,t){"use strict";t.d(n,{_k:function(){return o},bL:function(){return r},l2:function(){return c},nz:function(){return l}});var i=t(70515),r=(i.iI,2*i.iI),o=2.5*i.iI,c=3*i.iI,l=3.5*i.iI},61316:function(e,n,t){"use strict";t.r(n);var i=t(77837),r=t(38860),o=t.n(r),c=t(46568),l=t(55729),a=t(93808),d=t(82682),s=t(28274),u=t(38276),p=t(70515),f=t(24755),h=t(28598);function g(){return(0,h.jsx)(s.Z,{uuidItemSelected:f.HY,uuidWorkspaceSelected:f.WH,children:(0,h.jsx)(u.Z,{p:p.cd,children:(0,h.jsx)(d.Z,{justifyContent:"center",children:(0,h.jsx)(c.Z,{xl:8,xxl:6,children:(0,h.jsx)(l.Z,{})})})})})}g.getInitialProps=(0,i.Z)(o().mark((function e(){return o().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",{});case 1:case"end":return e.stop()}}),e)}))),n.default=(0,a.Z)(g)},33323:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/settings/workspace/preferences",function(){return t(61316)}])}},function(e){e.O(0,[2678,1154,844,4267,600,8487,8264,8432,9774,2888,179],(function(){return n=33323,e(e.s=n);var n}));var n=e.O();_N_E=n}]);
@@ -1 +0,0 @@
1
- (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[585],{94629:function(n,e,t){"use strict";t.d(e,{Z:function(){return w}});var r=t(82394),i=t(21831),o=t(82684),u=t(50724),c=t(82555),l=t(97618),a=t(70613),s=t(68487),d=t(68899),f=t(28598);function p(n,e){var t=n.children,r=n.noPadding;return(0,f.jsx)(d.HS,{noPadding:r,ref:e,children:t})}var v=o.forwardRef(p),h=t(62547),g=t(82571),m=t(35686),b=t(98464),O=t(46684),j=t(70515),x=t(53808),P=t(19183);function y(n,e){var t=Object.keys(n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(n);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),t.push.apply(t,r)}return t}function Z(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{};e%2?y(Object(t),!0).forEach((function(e){(0,r.Z)(n,e,t[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(t)):y(Object(t)).forEach((function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(t,e))}))}return n}function E(n,e){var t,r=n.addProjectBreadcrumbToCustomBreadcrumbs,p=n.after,y=n.afterHeader,E=n.afterHidden,w=n.afterWidth,I=n.afterWidthOverride,_=n.appendBreadcrumbs,T=n.before,A=n.beforeWidth,C=n.breadcrumbs,k=n.children,S=n.errors,N=n.headerMenuItems,M=n.headerOffset,D=n.hideAfterCompletely,R=n.mainContainerHeader,H=n.navigationItems,U=n.setAfterHidden,L=n.setErrors,Y=n.subheaderChildren,V=n.subheaderNoPadding,B=n.title,W=n.uuid,F=(0,P.i)().width,z="dashboard_after_width_".concat(W),X="dashboard_before_width_".concat(W),J=(0,o.useRef)(null),Q=(0,o.useState)(I?w:(0,x.U2)(z,w)),q=Q[0],K=Q[1],$=(0,o.useState)(!1),G=$[0],nn=$[1],en=(0,o.useState)(T?Math.max((0,x.U2)(X,A),13*j.iI):null),tn=en[0],rn=en[1],on=(0,o.useState)(!1),un=on[0],cn=on[1],ln=(0,o.useState)(null)[1],an=m.ZP.projects.list({},{revalidateOnFocus:!1}).data,sn=null===an||void 0===an?void 0:an.projects,dn={label:function(){var n;return null===sn||void 0===sn||null===(n=sn[0])||void 0===n?void 0:n.name},linkProps:{href:"/"}},fn=[];C&&(r&&fn.push(dn),fn.push.apply(fn,(0,i.Z)(C))),(null===C||void 0===C||!C.length||_)&&(null===sn||void 0===sn?void 0:sn.length)>=1&&(null!==C&&void 0!==C&&C.length||fn.unshift({bold:!_,label:function(){return B}}),fn.unshift(dn)),(0,o.useEffect)((function(){null===J||void 0===J||!J.current||G||un||null===ln||void 0===ln||ln(J.current.getBoundingClientRect().width)}),[G,q,un,tn,J,ln,F]),(0,o.useEffect)((function(){G||(0,x.t8)(z,q)}),[E,G,q,z]),(0,o.useEffect)((function(){un||(0,x.t8)(X,tn)}),[un,tn,X]);var pn=(0,b.Z)(w);return(0,o.useEffect)((function(){I&&pn!==w&&K(w)}),[I,w,pn]),(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(a.Z,{title:B}),(0,f.jsx)(s.Z,{breadcrumbs:fn,menuItems:N,project:null===sn||void 0===sn?void 0:sn[0],version:null===sn||void 0===sn||null===(t=sn[0])||void 0===t?void 0:t.version}),(0,f.jsxs)(d.Nk,{ref:e,children:[0!==(null===H||void 0===H?void 0:H.length)&&(0,f.jsx)(d.lm,{showMore:!0,children:(0,f.jsx)(g.Z,{navigationItems:H,showMore:!0})}),(0,f.jsx)(l.Z,{flex:1,flexDirection:"column",children:(0,f.jsxs)(h.Z,{after:p,afterHeader:y,afterHeightOffset:O.Mz,afterHidden:E,afterMousedownActive:G,afterWidth:q,before:T,beforeHeightOffset:O.Mz,beforeMousedownActive:un,beforeWidth:d.k1+(T?tn:0),headerOffset:M,hideAfterCompletely:!U||D,leftOffset:T?d.k1:null,mainContainerHeader:R,mainContainerRef:J,setAfterHidden:U,setAfterMousedownActive:nn,setAfterWidth:K,setBeforeMousedownActive:cn,setBeforeWidth:rn,children:[Y&&(0,f.jsx)(v,{noPadding:V,children:Y}),k]})})]}),S&&(0,f.jsx)(u.Z,{disableClickOutside:!0,isOpen:!0,onClickOutside:function(){return null===L||void 0===L?void 0:L(null)},children:(0,f.jsx)(c.Z,Z(Z({},S),{},{onClose:function(){return null===L||void 0===L?void 0:L(null)}}))})]})}var w=o.forwardRef(E)},48381:function(n,e,t){"use strict";var r=t(82684),i=t(31882),o=t(55485),u=t(30160),c=t(86735),l=t(28598);e.Z=function(n){var e=n.onClickTag,t=n.tags,a=void 0===t?[]:t,s=(0,r.useMemo)((function(){return(null===a||void 0===a?void 0:a.length)||0}),[a]),d=(0,r.useMemo)((function(){return(0,c.YC)(a||[],"uuid")}),[a]);return(0,l.jsx)(o.ZP,{alignItems:"center",flexWrap:"wrap",children:null===d||void 0===d?void 0:d.reduce((function(n,t){return n.push((0,l.jsx)("div",{style:{marginBottom:2,marginRight:s>=2?4:0,marginTop:2},children:(0,l.jsx)(i.Z,{onClick:e?function(){return e(t)}:null,small:!0,children:(0,l.jsx)(u.ZP,{children:t.uuid})})},"tag-".concat(t.uuid))),n}),[])})}},16488:function(n,e,t){"use strict";t.d(e,{IJ:function(){return h},M8:function(){return E},Vx:function(){return j},XM:function(){return Z},_U:function(){return v},eI:function(){return O},gU:function(){return P},lO:function(){return A},ri:function(){return m},tL:function(){return x},vJ:function(){return y},xH:function(){return b}});var r,i=t(82394),o=t(92083),u=t.n(o),c=t(3917),l=t(4383),a=t(30229),s=t(42122),d=t(86735);function f(n,e){var t=Object.keys(n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(n);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),t.push.apply(t,r)}return t}function p(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{};e%2?f(Object(t),!0).forEach((function(e){(0,i.Z)(n,e,t[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(t)):f(Object(t)).forEach((function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(t,e))}))}return n}var v=function(n){return!!n&&!Object.values(a.U5).includes(n)};function h(n){return null===n||void 0===n?void 0:n.reduce((function(n,e){var t=e.block_uuid,r=e.completed_at,o=e.started_at,c=e.status,l=null;o&&r&&(l=u()(r).valueOf()-u()(o).valueOf());return p(p({},n),{},(0,i.Z)({},t,{runtime:l,status:c}))}),{})}var g,m=function(n){var e=[{description:function(){return"This pipeline will run continuously on an interval or just once."},label:function(){return"Schedule"},uuid:a.Xm.TIME},{description:function(){return"This pipeline will run when a specific event occurs."},label:function(){return"Event"},uuid:a.Xm.EVENT},{description:function(){return"Run this pipeline when you make an API call."},label:function(){return"API"},uuid:a.Xm.API}];return n?e.slice(0,1):e};function b(n){var e=(0,s.gR)(n,[a.gm.INTERVAL,a.gm.TYPE]),t=n[a.gm.INTERVAL];t&&(e["schedule_interval[]"]=encodeURIComponent(t));var r=n[a.gm.TYPE];return r&&(e["schedule_type[]"]=r),e}function O(n){if(!n)return null;var e=new Date(u()(n).valueOf()),t=Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds());return new Date(t)}function j(n){return"string"!==typeof n?n:O(n.split("+")[0]).toISOString().split(".")[0]}!function(n){n.DAY="day",n.HOUR="hour",n.MINUTE="minute",n.SECOND="second"}(g||(g={}));var x=(r={},(0,i.Z)(r,g.DAY,86400),(0,i.Z)(r,g.HOUR,3600),(0,i.Z)(r,g.MINUTE,60),(0,i.Z)(r,g.SECOND,1),r);function P(n){var e=g.SECOND,t=n;return n%86400===0?(t/=86400,e=g.DAY):n%3600===0?(t/=3600,e=g.HOUR):n%60===0&&(t/=60,e=g.MINUTE),{time:t,unit:e}}function y(n,e){return n*x[e]}function Z(n,e,t){var r="".concat(n.toISOString().split("T")[0]," ").concat(null===e||void 0===e?void 0:e.hour,":").concat(null===e||void 0===e?void 0:e.minute);if(null!==t&&void 0!==t&&t.includeSeconds&&(r=r.concat(":00")),null!==t&&void 0!==t&&t.localTimezone){var i=u()(n);i.set("hour",+(null===e||void 0===e?void 0:e.hour)||0),i.set("minute",+(null===e||void 0===e?void 0:e.minute)||0),i.set("second",0),r=i.format(c.lE),null!==t&&void 0!==t&&t.convertToUtc&&(r=(0,c.d$)(r,{includeSeconds:null===t||void 0===t?void 0:t.includeSeconds,utcFormat:!0}))}return r}function E(n){var e,t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r="",i=!0;return i&&(t?r="".concat(window.origin,"/api/pipeline_schedules/").concat(null===n||void 0===n?void 0:n.id,"/api_trigger"):(r="".concat(window.origin,"/api/pipeline_schedules/").concat(null===n||void 0===n?void 0:n.id,"/pipeline_runs"),null!==n&&void 0!==n&&n.token&&(r="".concat(r,"/").concat(n.token)))),i&&(e=window.location.port)&&(r=r.replace(e,l.QT)),r}function w(n,e,t){return n.match(/[*,-/]/)?{additionalOffset:0,cronValue:n}:function(n,e,t){var r=t.indexOf(n),i=0;if(e<0)for(var o=0;o>e;o--)0===r?(r=t.length-1,i-=1):r-=1;else if(e>0)for(var u=0;u<e;u++)r===t.length-1?(r=0,i+=1):r+=1;return{additionalOffset:i,cronValue:String(t[r]||n)}}(+n,e,t)}var I=(0,d.m5)(60),_=(0,d.m5)(24),T=(0,c.Cs)();function A(n,e){if(!n)return n;var t=u()().local().format("Z"),r=t.split(":"),i="-"===t[0],o=3===r[0].length?Number(r[0].slice(1)):Number(r[0]),c=Number(r[1]);(i&&!e||!i&&e)&&(o=-o,c=-c);var l=n.split(" "),a=l[0],s=l[1],d=l[2],f=w(a,c,I),p=w(s,o+f.additionalOffset,_);if(l[0]=f.cronValue,l[1]=p.cronValue,0!==(null===p||void 0===p?void 0:p.additionalOffset)){var v=w(d,p.additionalOffset,T);l[2]=v.cronValue}return l.join(" ")}},70320:function(n,e,t){"use strict";t.d(e,{h:function(){return u},q:function(){return o}});var r=t(78419),i=t(53808);function o(){return(0,i.U2)(r.am,null)||!1}function u(n){return"undefined"!==typeof n&&(0,i.t8)(r.am,n),n}},55072:function(n,e,t){"use strict";t.d(e,{Et:function(){return f},Q:function(){return d}});t(82684);var r=t(71180),i=t(55485),o=t(38276),u=t(31748),c=t(72473),l=t(79633),a=t(70515),s=t(28598),d=30,f=9;e.ZP=function(n){var e=n.page,t=n.maxPages,d=n.onUpdate,f=n.totalPages,p=[],v=t;if(v>f)p=Array.from({length:f},(function(n,e){return e}));else{var h=Math.floor(v/2),g=e-h;e+h>=f?(g=f-v+2,v-=2):e-h<=0?(g=0,v-=2):(v-=4,g=e-Math.floor(v/2)),p=Array.from({length:v},(function(n,e){return e+g}))}return(0,s.jsx)(s.Fragment,{children:f>0&&(0,s.jsxs)(i.ZP,{alignItems:"center",children:[(0,s.jsx)(r.ZP,{disabled:0===e,onClick:function(){return d(e-1)},children:(0,s.jsx)(c.Hd,{size:1.5*a.iI,stroke:u.Av})}),!p.includes(0)&&(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(o.Z,{ml:1,children:(0,s.jsx)(r.ZP,{borderLess:!0,noBackground:!0,onClick:function(){return d(0)},children:1})},0),!p.includes(1)&&(0,s.jsx)(o.Z,{ml:1,children:(0,s.jsx)(r.ZP,{noBackground:!0,noPadding:!0,notClickable:!0,children:"..."})},0)]}),p.map((function(n){return(0,s.jsx)(o.Z,{ml:1,children:(0,s.jsx)(r.ZP,{backgroundColor:n===e&&l.a$,borderLess:!0,noBackground:!0,notClickable:n===e,onClick:function(){n!==e&&d(n)},children:n+1})},n)})),!p.includes(f-1)&&(0,s.jsxs)(s.Fragment,{children:[!p.includes(f-2)&&(0,s.jsx)(o.Z,{ml:1,children:(0,s.jsx)(r.ZP,{noBackground:!0,noPadding:!0,notClickable:!0,children:"..."})},0),(0,s.jsx)(o.Z,{ml:1,children:(0,s.jsx)(r.ZP,{borderLess:!0,noBackground:!0,onClick:function(){return d(f-1)},children:f})},f-1)]}),(0,s.jsx)(o.Z,{ml:1}),(0,s.jsx)(r.ZP,{disabled:e===f-1,onClick:function(){return d(e+1)},children:(0,s.jsx)(c.Kw,{size:1.5*a.iI,stroke:u.Av})})]})})}},30229:function(n,e,t){"use strict";t.d(e,{TR:function(){return p},U5:function(){return l},Wb:function(){return f},Xm:function(){return o},Z4:function(){return a},fq:function(){return c},gm:function(){return s},kJ:function(){return d}});var r,i,o,u=t(82394);!function(n){n.API="api",n.EVENT="event",n.TIME="time"}(o||(o={}));var c,l,a=(r={},(0,u.Z)(r,o.API,(function(){return"API"})),(0,u.Z)(r,o.EVENT,(function(){return"event"})),(0,u.Z)(r,o.TIME,(function(){return"schedule"})),r);!function(n){n.ACTIVE="active",n.INACTIVE="inactive"}(c||(c={})),function(n){n.ONCE="@once",n.HOURLY="@hourly",n.DAILY="@daily",n.WEEKLY="@weekly",n.MONTHLY="@monthly",n.ALWAYS_ON="@always_on"}(l||(l={}));var s,d,f=[l.ONCE,l.HOURLY,l.DAILY,l.WEEKLY,l.MONTHLY];!function(n){n.INTERVAL="frequency[]",n.STATUS="status[]",n.TAG="tag[]",n.TYPE="type[]"}(s||(s={})),function(n){n.CREATED_AT="created_at",n.NAME="name",n.PIPELINE="pipeline_uuid",n.STATUS="status",n.TYPE="schedule_type"}(d||(d={}));var p=(i={},(0,u.Z)(i,d.CREATED_AT,"Created at"),(0,u.Z)(i,d.NAME,"Name"),(0,u.Z)(i,d.PIPELINE,"Pipeline"),(0,u.Z)(i,d.STATUS,"Active"),(0,u.Z)(i,d.TYPE,"Type"),i)},31882:function(n,e,t){"use strict";var r=t(38626),i=t(71180),o=t(55485),u=t(30160),c=t(44897),l=t(72473),a=t(70515),s=t(61896),d=t(28598),f=r.default.div.withConfig({displayName:"Chip__ChipStyle",componentId:"sc-1ok73g-0"})(["display:inline-block;"," "," "," "," "," ",""],(function(n){return!n.primary&&"\n background-color: ".concat((n.theme.background||c.Z.background).tag,";\n ")}),(function(n){return n.primary&&"\n background-color: ".concat((n.theme.chart||c.Z.chart).primary,";\n ")}),(function(n){return!n.small&&"\n border-radius: ".concat((a.iI+s.Al)/2,"px;\n height: ").concat(1.5*a.iI+s.Al,"px;\n padding: ").concat(a.iI/1.5,"px ").concat(1.25*a.iI,"px;\n ")}),(function(n){return n.small&&"\n border-radius: ".concat((a.iI/2+s.Al)/2,"px;\n height: ").concat(s.Al+a.iI/2+2,"px;\n padding: ").concat(a.iI/4,"px ").concat(a.iI,"px;\n ")}),(function(n){return n.xsmall&&"\n border-radius: ".concat((a.iI/1+s.Al)/1,"px;\n height: ").concat(20,"px;\n padding: 4px 6px;\n ")}),(function(n){return n.border&&"\n border: 1px solid ".concat((n.theme.content||c.Z.content).muted,";\n ")}));e.Z=function(n){var e=n.border,t=n.children,r=n.disabled,c=n.label,s=n.monospace,p=n.onClick,v=n.primary,h=n.small,g=n.xsmall;return(0,d.jsx)(f,{border:e,primary:v,small:h,xsmall:g,children:(0,d.jsx)(i.ZP,{basic:!0,disabled:r,noBackground:!0,noPadding:!0,onClick:p,transparent:!0,children:(0,d.jsxs)(o.ZP,{alignItems:"center",children:[t,c&&(0,d.jsx)(u.ZP,{monospace:s,small:h,xsmall:g,children:c}),!r&&p&&(0,d.jsx)("div",{style:{marginLeft:2}}),!r&&p&&(0,d.jsx)(l.x8,{default:v,muted:!v,size:h?a.iI:1.25*a.iI})]})})})}},72191:function(n,e,t){"use strict";t.d(e,{_k:function(){return o},bL:function(){return i},l2:function(){return u},nz:function(){return c}});var r=t(70515),i=(r.iI,2*r.iI),o=2.5*r.iI,u=3*r.iI,c=3.5*r.iI},77174:function(n,e,t){"use strict";t.r(e);var r=t(77837),i=t(82394),o=t(75582),u=t(38860),c=t.n(u),l=t(82684),a=t(34376),s=t(94629),d=t(55485),f=t(55072),p=t(93808),v=t(82359),h=t(44085),g=t(38276),m=t(30160),b=t(29624),O=t(35686),j=t(30229),x=t(70515),P=t(15610),y=t(69419),Z=t(70320),E=t(28598);function w(n,e){var t=Object.keys(n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(n);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),t.push.apply(t,r)}return t}function I(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{};e%2?w(Object(t),!0).forEach((function(e){(0,i.Z)(n,e,t[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(t)):w(Object(t)).forEach((function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(t,e))}))}return n}function _(){var n=(0,a.useRouter)(),e=(0,l.useState)(null),t=e[0],r=e[1],i=(0,y.iV)(),u=null!==i&&void 0!==i&&i.page?i.page:0,c=(null===i||void 0===i?void 0:i.order_by)||j.kJ.CREATED_AT,p=O.ZP.projects.list().data,w=(0,l.useMemo)((function(){var n;return null===p||void 0===p||null===(n=p.projects)||void 0===n?void 0:n[0]}),[p]),_=((0,l.useMemo)((function(){var n;return(0,Z.h)(null===w||void 0===w||null===(n=w.features)||void 0===n?void 0:n[v.d.LOCAL_TIMEZONE])}),[null===w||void 0===w?void 0:w.features]),{_limit:f.Q,_offset:u*f.Q,order_by:c}),T=O.ZP.pipeline_schedules.list(_,{refreshInterval:7500,revalidateOnFocus:!0}),A=T.data,C=T.mutate,k=(0,l.useMemo)((function(){return(null===A||void 0===A?void 0:A.pipeline_schedules)||[]}),[A]),S=(0,l.useMemo)((function(){var n;return(null===A||void 0===A||null===(n=A.metadata)||void 0===n?void 0:n.count)||[]}),[A]);return(0,E.jsxs)(s.Z,{errors:t,setErrors:r,title:"Triggers",uuid:"triggers/index",children:[(0,E.jsx)(g.Z,{mx:2,my:1,children:(0,E.jsxs)(d.ZP,{alignItems:"center",children:[(0,E.jsx)(m.ZP,{bold:!0,default:!0,large:!0,children:"Sort runs by:"}),(0,E.jsx)(g.Z,{mr:1}),(0,E.jsx)(h.Z,{compact:!0,defaultColor:!0,fitContent:!0,onChange:function(n){n.preventDefault(),(0,P.u7)({order_by:n.target.value,page:0})},paddingRight:4*x.iI,placeholder:"Select column",value:c||j.kJ.CREATED_AT,children:Object.entries(j.TR).map((function(n){var e=(0,o.Z)(n,2),t=e[0],r=e[1];return(0,E.jsx)("option",{value:t,children:r},t)}))})]})}),(0,E.jsx)(b.Z,{fetchPipelineSchedules:C,highlightRowOnHover:!0,includeCreatedAtColumn:!0,includePipelineColumn:!0,pipelineSchedules:k,setErrors:r,stickyHeader:!0}),(0,E.jsx)(g.Z,{p:2,children:(0,E.jsx)(f.ZP,{maxPages:9,onUpdate:function(e){var t=Number(e),r=I(I({},i),{},{page:t>=0?t:0});n.push("/triggers","/triggers?".concat((0,y.uM)(r)))},page:Number(u),totalPages:Math.ceil(S/f.Q)})})]})}_.getInitialProps=(0,r.Z)(c().mark((function n(){return c().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.abrupt("return",{});case 1:case"end":return n.stop()}}),n)}))),e.default=(0,p.Z)(_)},59733:function(n,e,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/triggers",function(){return t(77174)}])},80022:function(n,e,t){"use strict";function r(n){if(void 0===n)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n}t.d(e,{Z:function(){return r}})},15544:function(n,e,t){"use strict";function r(n){return r=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},r(n)}t.d(e,{Z:function(){return r}})},13692:function(n,e,t){"use strict";t.d(e,{Z:function(){return i}});var r=t(61049);function i(n,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");n.prototype=Object.create(e&&e.prototype,{constructor:{value:n,writable:!0,configurable:!0}}),e&&(0,r.Z)(n,e)}},93189:function(n,e,t){"use strict";t.d(e,{Z:function(){return o}});var r=t(12539),i=t(80022);function o(n,e){if(e&&("object"===r(e)||"function"===typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return(0,i.Z)(n)}},61049:function(n,e,t){"use strict";function r(n,e){return r=Object.setPrototypeOf||function(n,e){return n.__proto__=e,n},r(n,e)}t.d(e,{Z:function(){return r}})}},function(n){n.O(0,[2678,1154,844,4267,600,8487,8264,7858,5499,9624,9774,2888,179],(function(){return e=59733,n(n.s=e);var e}));var e=n.O();_N_E=e}]);
@@ -1 +0,0 @@
1
- (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2858],{94629:function(e,n,r){"use strict";r.d(n,{Z:function(){return C}});var t=r(82394),o=r(21831),i=r(82684),l=r(50724),c=r(82555),u=r(97618),s=r(70613),a=r(68487),d=r(68899),h=r(28598);function f(e,n){var r=e.children,t=e.noPadding;return(0,h.jsx)(d.HS,{noPadding:t,ref:n,children:r})}var m=i.forwardRef(f),v=r(62547),b=r(82571),g=r(35686),p=r(98464),j=r(46684),x=r(70515),Z=r(53808),P=r(19183);function y(e,n){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);n&&(t=t.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),r.push.apply(r,t)}return r}function _(e){for(var n=1;n<arguments.length;n++){var r=null!=arguments[n]?arguments[n]:{};n%2?y(Object(r),!0).forEach((function(n){(0,t.Z)(e,n,r[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):y(Object(r)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))}))}return e}function w(e,n){var r,t=e.addProjectBreadcrumbToCustomBreadcrumbs,f=e.after,y=e.afterHeader,w=e.afterHidden,C=e.afterWidth,k=e.afterWidthOverride,S=e.appendBreadcrumbs,O=e.before,I=e.beforeWidth,T=e.breadcrumbs,E=e.children,A=e.errors,N=e.headerMenuItems,R=e.headerOffset,M=e.hideAfterCompletely,D=e.mainContainerHeader,B=e.navigationItems,H=e.setAfterHidden,L=e.setErrors,F=e.subheaderChildren,G=e.subheaderNoPadding,V=e.title,Y=e.uuid,U=(0,P.i)().width,q="dashboard_after_width_".concat(Y),W="dashboard_before_width_".concat(Y),z=(0,i.useRef)(null),K=(0,i.useState)(k?C:(0,Z.U2)(q,C)),Q=K[0],X=K[1],J=(0,i.useState)(!1),$=J[0],ee=J[1],ne=(0,i.useState)(O?Math.max((0,Z.U2)(W,I),13*x.iI):null),re=ne[0],te=ne[1],oe=(0,i.useState)(!1),ie=oe[0],le=oe[1],ce=(0,i.useState)(null)[1],ue=g.ZP.projects.list({},{revalidateOnFocus:!1}).data,se=null===ue||void 0===ue?void 0:ue.projects,ae={label:function(){var e;return null===se||void 0===se||null===(e=se[0])||void 0===e?void 0:e.name},linkProps:{href:"/"}},de=[];T&&(t&&de.push(ae),de.push.apply(de,(0,o.Z)(T))),(null===T||void 0===T||!T.length||S)&&(null===se||void 0===se?void 0:se.length)>=1&&(null!==T&&void 0!==T&&T.length||de.unshift({bold:!S,label:function(){return V}}),de.unshift(ae)),(0,i.useEffect)((function(){null===z||void 0===z||!z.current||$||ie||null===ce||void 0===ce||ce(z.current.getBoundingClientRect().width)}),[$,Q,ie,re,z,ce,U]),(0,i.useEffect)((function(){$||(0,Z.t8)(q,Q)}),[w,$,Q,q]),(0,i.useEffect)((function(){ie||(0,Z.t8)(W,re)}),[ie,re,W]);var he=(0,p.Z)(C);return(0,i.useEffect)((function(){k&&he!==C&&X(C)}),[k,C,he]),(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(s.Z,{title:V}),(0,h.jsx)(a.Z,{breadcrumbs:de,menuItems:N,project:null===se||void 0===se?void 0:se[0],version:null===se||void 0===se||null===(r=se[0])||void 0===r?void 0:r.version}),(0,h.jsxs)(d.Nk,{ref:n,children:[0!==(null===B||void 0===B?void 0:B.length)&&(0,h.jsx)(d.lm,{showMore:!0,children:(0,h.jsx)(b.Z,{navigationItems:B,showMore:!0})}),(0,h.jsx)(u.Z,{flex:1,flexDirection:"column",children:(0,h.jsxs)(v.Z,{after:f,afterHeader:y,afterHeightOffset:j.Mz,afterHidden:w,afterMousedownActive:$,afterWidth:Q,before:O,beforeHeightOffset:j.Mz,beforeMousedownActive:ie,beforeWidth:d.k1+(O?re:0),headerOffset:R,hideAfterCompletely:!H||M,leftOffset:O?d.k1:null,mainContainerHeader:D,mainContainerRef:z,setAfterHidden:H,setAfterMousedownActive:ee,setAfterWidth:X,setBeforeMousedownActive:le,setBeforeWidth:te,children:[F&&(0,h.jsx)(m,{noPadding:G,children:F}),E]})})]}),A&&(0,h.jsx)(l.Z,{disableClickOutside:!0,isOpen:!0,onClickOutside:function(){return null===L||void 0===L?void 0:L(null)},children:(0,h.jsx)(c.Z,_(_({},A),{},{onClose:function(){return null===L||void 0===L?void 0:L(null)}}))})]})}var C=i.forwardRef(w)},85385:function(e,n,r){"use strict";r.d(n,{Qq:function(){return m},Z7:function(){return v},cH:function(){return o},du:function(){return h},fp:function(){return d},j5:function(){return f},uM:function(){return a}});var t,o,i=r(82394),l=r(57653),c=r(82359),u=r(72473),s=r(86735),a="sideview",d=90;!function(e){e.ADDON_BLOCKS="addon_blocks",e.BLOCK_SETTINGS="block_settings",e.CALLBACKS="callbacks",e.CHARTS="charts",e.DATA="data",e.EXTENSIONS="power_ups",e.FILE_VERSIONS="file_versions",e.GRAPHS="graphs",e.INTERACTIONS="interactions",e.REPORTS="reports",e.SECRETS="secrets",e.SETTINGS="settings",e.TERMINAL="terminal",e.TREE="tree",e.VARIABLES="variables"}(o||(o={}));o.BLOCK_SETTINGS,o.CALLBACKS,o.CHARTS,o.DATA,o.EXTENSIONS,o.TREE;var h=[o.DATA];function f(e){var n,r,t,i=[{key:o.TREE,label:"Tree"},{buildLabel:function(e){var n=(e.pipeline||{}).widgets,r=void 0===n?[]:n;return(null===r||void 0===r?void 0:r.length)>=1?"Charts (".concat(r.length,")"):"Charts"},key:o.CHARTS},{buildLabel:function(e){var n=e.variables;return(null===n||void 0===n?void 0:n.length)>=1?"Variables (".concat(n.length,")"):"Variables"},key:o.VARIABLES},{buildLabel:function(e){var n=e.secrets;return(null===n||void 0===n?void 0:n.length)>=1?"Secrets (".concat(n.length,")"):"Secrets"},key:o.SECRETS}];return l.qL.PYSPARK!==(null===e||void 0===e||null===(n=e.pipeline)||void 0===n?void 0:n.type)&&i.push.apply(i,[{buildLabel:function(e){e.pipeline;return"Add-on blocks"},key:o.ADDON_BLOCKS},{buildLabel:function(e){var n=(e.pipeline||{}).extensions,r=void 0===n?{}:n,t=0;return Object.values(r).forEach((function(e){var n=e.blocks;t+=(null===n||void 0===n?void 0:n.length)||0})),t>=1?"Power ups (".concat(t,")"):"Power ups"},key:o.EXTENSIONS}]),i.push.apply(i,[{key:o.DATA,label:"Data"},{key:o.TERMINAL,label:"Terminal"},{key:o.BLOCK_SETTINGS,label:"Block settings"}]),null!==e&&void 0!==e&&null!==(r=e.project)&&void 0!==r&&null!==(t=r.features)&&void 0!==t&&t[c.d.INTERACTIONS]&&i.push({key:o.INTERACTIONS,label:"Interactions"}),i}function m(e){return(0,s.HK)(f(e),(function(e){return e.key}))}var v=(t={},(0,i.Z)(t,o.ADDON_BLOCKS,u.EJ),(0,i.Z)(t,o.BLOCK_SETTINGS,u.JG),(0,i.Z)(t,o.CALLBACKS,u.AQ),(0,i.Z)(t,o.CHARTS,u.GQ),(0,i.Z)(t,o.DATA,u.iA),(0,i.Z)(t,o.EXTENSIONS,u.Bf),(0,i.Z)(t,o.INTERACTIONS,u.yd),(0,i.Z)(t,o.SECRETS,u.Yo),(0,i.Z)(t,o.SETTINGS,u.Zr),(0,i.Z)(t,o.TERMINAL,u.oI),(0,i.Z)(t,o.TREE,u.mp),(0,i.Z)(t,o.VARIABLES,u.LO),t)},89706:function(e,n,r){"use strict";r.d(n,{JD:function(){return v},Lu:function(){return i},PF:function(){return h},dT:function(){return l},n6:function(){return s},nB:function(){return m},oy:function(){return f},xF:function(){return d}});var t,o,i,l,c=r(82394),u=r(44425);!function(e){e.CSV="csv",e.JSON="json",e.MD="md",e.PY="py",e.R="r",e.SH="sh",e.SQL="sql",e.TXT="txt",e.YAML="yaml",e.YML="yml"}(i||(i={})),function(e){e.INIT_PY="__init__.py",e.METADATA_YAML="metadata.yaml",e.REQS_TXT="requirements.txt"}(l||(l={}));var s=[i.PY,i.SQL],a=[i.JSON,i.MD,i.PY,i.R,i.SH,i.SQL,i.TXT,i.YAML,i.YML],d=new RegExp(a.map((function(e){return".".concat(e,"$")})).join("|")),h=(new RegExp(a.map((function(e){return".".concat(e,"$")})).join("|")),"charts"),f="pipelines",m=(t={},(0,c.Z)(t,i.MD,u.t6.MARKDOWN),(0,c.Z)(t,i.JSON,i.JSON),(0,c.Z)(t,i.PY,u.t6.PYTHON),(0,c.Z)(t,i.R,u.t6.R),(0,c.Z)(t,i.SQL,u.t6.SQL),(0,c.Z)(t,i.TXT,"text"),(0,c.Z)(t,i.YAML,u.t6.YAML),(0,c.Z)(t,i.YML,u.t6.YAML),t),v=(o={},(0,c.Z)(o,u.t6.MARKDOWN,i.MD),(0,c.Z)(o,u.t6.PYTHON,i.PY),(0,c.Z)(o,u.t6.R,i.R),(0,c.Z)(o,u.t6.SQL,i.SQL),(0,c.Z)(o,u.t6.YAML,i.YAML),(0,c.Z)(o,"text",i.TXT),o)},72098:function(e,n,r){"use strict";var t;r.d(n,{U:function(){return t}}),function(e){e.PYSPARK="pysparkkernel",e.PYTHON3="python3"}(t||(t={}))},40109:function(e,n,r){"use strict";r.d(n,{f:function(){return g},h:function(){return v}});var t=r(82394),o=r(82684),i=r(34376),l=r(93369),c=r(72473),u=r(70515),s=r(69419),a=r(53808),d=r(28598);var h=function(e){var n=e.oauthResponse,r=(0,i.useRouter)(),t=(0,o.useMemo)((function(){return n||{}}),[n]),h=t.url,f=t.redirect_query_params,m=void 0===f?{}:f;return(0,d.jsx)(d.Fragment,{children:h&&(0,d.jsx)(l.ZP,{beforeElement:(0,d.jsx)(c._8,{size:2*u.iI}),bold:!0,inline:!0,onClick:function(){var e=(0,s.iV)(h).state;(0,a.t8)(e,m),r.push(h)},uuid:"SignForm/google",children:"Sign in with Google"})})};var f=function(e){var n=e.oauthResponse,r=(0,i.useRouter)(),t=(0,o.useMemo)((function(){return n||{}}),[n]),h=t.url,f=t.redirect_query_params,m=void 0===f?{}:f;return(0,d.jsx)(d.Fragment,{children:h&&(0,d.jsx)(l.ZP,{beforeElement:(0,d.jsx)(c.Dg,{size:2*u.iI}),bold:!0,inline:!0,onClick:function(){var e=(0,s.iV)(h).state;m&&(0,a.t8)(e,m),r.push(h)},uuid:"SignForm/active_directory",children:"Sign in with Microsoft"})})};var m,v,b=function(e){var n=e.oauthResponse,r=(0,i.useRouter)(),t=(0,o.useMemo)((function(){return n||{}}),[n]),c=t.url,u=t.redirect_query_params,h=void 0===u?{}:u;return(0,d.jsx)(d.Fragment,{children:c&&(0,d.jsx)(l.ZP,{bold:!0,inline:!0,onClick:function(){var e=(0,s.iV)(c).state;(0,a.t8)(e,h),r.push(c)},uuid:"SignForm/okta",children:"Sign in with Okta"})})};!function(e){e.ACTIVE_DIRECTORY="active_directory",e.GITHUB="github",e.GOOGLE="google",e.OKTA="okta"}(v||(v={}));var g=(m={},(0,t.Z)(m,v.ACTIVE_DIRECTORY,f),(0,t.Z)(m,v.GOOGLE,h),(0,t.Z)(m,v.OKTA,b),m)},57653:function(e,n,r){"use strict";r.d(n,{$1:function(){return v},G7:function(){return p},LM:function(){return j},Mj:function(){return x},QK:function(){return m},RH:function(){return g},a_:function(){return P},fj:function(){return y},kA:function(){return Z},qL:function(){return c},r0:function(){return b}});var t,o,i,l,c,u=r(75582),s=r(82394),a=r(72473),d=r(72098);function h(e,n){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);n&&(t=t.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),r.push.apply(r,t)}return r}function f(e){for(var n=1;n<arguments.length;n++){var r=null!=arguments[n]?arguments[n]:{};n%2?h(Object(r),!0).forEach((function(n){(0,s.Z)(e,n,r[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):h(Object(r)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))}))}return e}!function(e){e.INTEGRATION="integration",e.PYTHON="python",e.PYSPARK="pyspark",e.STREAMING="streaming"}(c||(c={}));var m,v,b,g=(t={},(0,s.Z)(t,c.INTEGRATION,"Integration"),(0,s.Z)(t,c.PYTHON,"Python"),(0,s.Z)(t,c.PYSPARK,"PySpark"),(0,s.Z)(t,c.STREAMING,"Streaming"),t),p=(o={},(0,s.Z)(o,c.INTEGRATION,"Integration"),(0,s.Z)(o,c.PYTHON,"Standard"),(0,s.Z)(o,c.PYSPARK,"PySpark"),(0,s.Z)(o,c.STREAMING,"Streaming"),o),j="all",x=(c.PYTHON,c.INTEGRATION,c.STREAMING,i={},(0,s.Z)(i,j,a.ie),(0,s.Z)(i,c.INTEGRATION,a.YC),(0,s.Z)(i,c.PYTHON,a.El),(0,s.Z)(i,c.STREAMING,a.dB),i);!function(e){e.ACTIVE="active",e.INACTIVE="inactive",e.NO_SCHEDULES="no_schedules",e.RETRY="retry",e.RETRY_INCOMPLETE_BLOCK_RUNS="retry_incomplete_block_runs"}(m||(m={})),function(e){e.GROUP="group_by",e.HISTORY_DAYS="from_history_days",e.NO_TAGS="no_tags",e.STATUS="status[]",e.TAG="tag[]",e.TYPE="type[]"}(v||(v={})),function(e){e.STATUS="status",e.TAG="tag",e.TYPE="type"}(b||(b={}));var Z=[m.ACTIVE,m.INACTIVE,m.NO_SCHEDULES],P=(l={},(0,s.Z)(l,c.PYTHON,d.U.PYTHON3),(0,s.Z)(l,c.PYSPARK,d.U.PYSPARK),l),y=Object.entries(P).reduce((function(e,n){var r=(0,u.Z)(n,2),t=r[0],o=r[1];return f(f({},e),{},(0,s.Z)({},o,t))}),{})},65956:function(e,n,r){"use strict";var t=r(38626),o=r(55485),i=r(38276),l=r(30160),c=r(44897),u=r(42631),s=r(47041),a=r(70515),d=r(28598),h=(0,t.css)(["padding:","px;padding-bottom:","px;padding-top:","px;"],2*a.iI,1.5*a.iI,1.5*a.iI),f=t.default.div.withConfig({displayName:"Panel__PanelStyle",componentId:"sc-1ct8cgl-0"})(["border-radius:","px;overflow:hidden;"," "," "," "," "," "," "," "," "," "," "," ",""],u.n_,(function(e){return e.fullWidth&&"\n width: 100%;\n "}),(function(e){return!e.borderless&&"\n border: 1px solid ".concat((e.theme.interactive||c.Z.interactive).defaultBorder,";\n ")}),(function(e){return e.success&&"\n background-color: ".concat((e.theme.background||c.Z.background).successLight,";\n ")}),(function(e){return e.success&&!e.borderless&&"\n border: 1px solid ".concat((e.theme.background||c.Z.background).success,";\n ")}),(function(e){return!e.dark&&!e.success&&"\n background-color: ".concat((e.theme.background||c.Z.background).panel,";\n ")}),(function(e){return e.dark&&"\n background-color: ".concat((e.theme.background||c.Z.background).content,";\n ")}),(function(e){return!e.fullHeight&&"\n height: fit-content;\n "}),(function(e){return e.maxHeight&&"\n max-height: ".concat(e.maxHeight,";\n ")}),(function(e){return e.maxWidth&&"\n max-width: ".concat(e.maxWidth,"px;\n ")}),(function(e){return e.minWidth&&"\n min-width: ".concat(e.minWidth,"px;\n\n @media (max-width: ").concat(e.minWidth,"px) {\n min-width: 0;\n }\n ")}),(function(e){return e.borderless&&"\n border: none;\n "}),(function(e){return e.overflowVisible&&"\n overflow: visible;\n "})),m=t.default.div.withConfig({displayName:"Panel__HeaderStyle",componentId:"sc-1ct8cgl-1"})(["border-top-left-radius:","px;border-top-right-radius:","px;"," "," "," ",""],u.n_,u.n_,(function(e){return"\n background-color: ".concat((e.theme.background||c.Z.background).chartBlock,";\n border-bottom: 1px solid ").concat((e.theme.interactive||c.Z.interactive).defaultBorder,";\n ")}),(function(e){return e.height&&"\n height: ".concat(e.height,"px;\n ")}),h,(function(e){return e.headerPaddingVertical&&"\n padding-bottom: ".concat(e.headerPaddingVertical,"px;\n padding-top: ").concat(e.headerPaddingVertical,"px;\n ")})),v=t.default.div.withConfig({displayName:"Panel__ContentStyle",componentId:"sc-1ct8cgl-2"})(["overflow-y:auto;padding:","px;height:100%;"," "," "," "," ",""],1.75*a.iI,s.w5,(function(e){return e.height&&"\n height: ".concat(e.height,"px;\n ")}),(function(e){return e.maxHeight&&"\n max-height: calc(".concat(e.maxHeight," - ").concat(15*a.iI,"px);\n ")}),(function(e){return e.noPadding&&"\n padding: 0;\n "}),(function(e){return e.overflowVisible&&"\n overflow: visible;\n "})),b=t.default.div.withConfig({displayName:"Panel__FooterStyle",componentId:"sc-1ct8cgl-3"})(["border-style:",";border-top-width:","px;padding:","px;"],u.M8,u.YF,1.75*a.iI);n.Z=function(e){var n=e.borderless,r=e.children,t=e.containerRef,c=e.contentContainerRef,u=e.dark,s=e.footer,a=e.fullHeight,h=void 0===a||a,g=e.fullWidth,p=void 0===g||g,j=e.header,x=e.headerHeight,Z=e.headerIcon,P=e.headerPaddingVertical,y=e.headerTitle,_=e.maxHeight,w=e.maxWidth,C=e.minWidth,k=e.noPadding,S=e.overflowVisible,O=e.subtitle,I=e.success;return(0,d.jsxs)(f,{borderless:n,dark:u,fullHeight:h,fullWidth:p,maxHeight:_,maxWidth:w,minWidth:C,overflowVisible:S,ref:t,success:I,children:[(j||y)&&(0,d.jsxs)(m,{headerPaddingVertical:P,height:x,children:[j&&j,y&&(0,d.jsx)(o.ZP,{alignItems:"center",justifyContent:"space-between",children:(0,d.jsxs)(o.ZP,{alignItems:"center",children:[Z&&Z,(0,d.jsx)(i.Z,{ml:Z?1:0,children:(0,d.jsx)(l.ZP,{bold:!0,default:!0,children:y})})]})})]}),(0,d.jsxs)(v,{maxHeight:_,noPadding:k,overflowVisible:S,ref:c,children:[O&&(0,d.jsx)(i.Z,{mb:2,children:(0,d.jsx)(l.ZP,{default:!0,children:O})}),r]}),s&&(0,d.jsx)(b,{children:s})]})}},35185:function(e,n,r){"use strict";var t=r(82394),o=r(91835),i=(r(82684),r(38626)),l=r(44897),c=r(42631),u=r(70515),s=r(28598);function a(e,n){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);n&&(t=t.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),r.push.apply(r,t)}return r}function d(e){for(var n=1;n<arguments.length;n++){var r=null!=arguments[n]?arguments[n]:{};n%2?a(Object(r),!0).forEach((function(n){(0,t.Z)(e,n,r[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):a(Object(r)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))}))}return e}var h=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*u.iI,(function(e){return"\n background-color: ".concat((e.theme.monotone||l.Z.monotone).grey200,";\n ")})),f=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||l.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||l.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,s.jsx)(h,d(d({},n),{},{children:(0,s.jsx)(f,d({},n))}))}},58024:function(e,n,r){"use strict";r.r(n),r.d(n,{default:function(){return Se}});var t=r(77837),o=r(38860),i=r.n(o),l=r(93808),c=r(82394),u=r(75582),s=r(54407),a=r.n(s),d=r(82684),h=r(69864),f=r(71180),m=r(15338),v=r(55485),b=r(85854),g=r(44085),p=r(38276),j=r(4190),x=r(30160),Z=r(35576),P=r(17488),y=r(12468),_=r(35686),w=r(72473),C="clone",k="delete",S="fetch",O="merge",I="pull",T="push",E="rebase",A="git_remote_name",N="git_repository_name",R={uuid:"Branches"},M={uuid:"Files"},D={uuid:"Push"},B={uuid:"Setup"},H=[B,R,M,D],L=r(70515),F=r(81728),G=r(72619),V=r(28598);var Y=function(e){var n=e.actionRemoteName,r=e.branch,t=e.branches,o=e.fetchBranch,i=e.fetchBranches,l=e.remotes,s=e.setActionRemoteName,a=e.showError,C=(0,d.useState)(""),S=C[0],I=C[1],T=(0,d.useState)(null),A=T[0],N=T[1],R=(0,d.useState)(null),D=R[0],H=R[1],Y=(0,d.useState)(null),U=Y[0],q=Y[1],W=(0,d.useState)(""),z=W[0],K=W[1],Q=(0,d.useMemo)((function(){return null===l||void 0===l?void 0:l.find((function(e){return e.name===n}))}),[n,l]),X=(0,d.useMemo)((function(){return(null===t||void 0===t?void 0:t.concat((null===Q||void 0===Q?void 0:Q.refs)||[]))||[]}),[t,Q]),J=(0,h.Db)(_.ZP.git_custom_branches.useCreate(),{onSuccess:function(e){return(0,G.wD)(e,{callback:function(){o(),i(),K("")},onErrorCallback:function(e,n){return a({errors:n,response:e})}})}}),$=(0,u.Z)(J,2),ee=$[0],ne=$[1].isLoading,re=(0,h.Db)(_.ZP.git_custom_branches.useCreate(),{onSuccess:function(e){return(0,G.wD)(e,{callback:function(){o()},onErrorCallback:function(e,n){return a({errors:n,response:e})}})}}),te=(0,u.Z)(re,2),oe=te[0],ie=te[1].isLoading,le=(0,h.Db)(_.ZP.git_custom_branches.useUpdate(null===r||void 0===r?void 0:r.name),{onSuccess:function(e){return(0,G.wD)(e,{callback:function(e){var n=e.git_custom_branch.progress;o(),I(""),N(""),H(n),q("")},onErrorCallback:function(e,n){return a({errors:n,response:e})}})}}),ce=(0,u.Z)(le,2),ue=ce[0],se=ce[1].isLoading;return(0,V.jsxs)(V.Fragment,{children:[(0,V.jsxs)(p.Z,{mb:L.HN,children:[(0,V.jsxs)(b.Z,{children:["Branches",t?" (".concat(null===t||void 0===t?void 0:t.length,")"):""]}),(0,V.jsx)(p.Z,{mt:L.Mq,children:(0,V.jsxs)(v.ZP,{children:[(0,V.jsxs)("div",{children:[(0,V.jsx)(p.Z,{mb:1,children:(0,V.jsx)(x.ZP,{bold:!0,muted:!0,children:"Remote"})}),(0,V.jsx)(g.Z,{beforeIcon:(0,V.jsx)(w.VW,{}),beforeIconSize:1.5*L.iI,monospace:!0,onChange:function(e){return s(e.target.value)},placeholder:"Choose a remote",value:n||"",children:null===l||void 0===l?void 0:l.map((function(e){var n=e.name;return(0,V.jsx)("option",{value:n,children:n},n)}))})]}),(0,V.jsx)(p.Z,{mr:1}),(0,V.jsxs)("div",{children:[(0,V.jsx)(p.Z,{mb:1,children:(0,V.jsx)(x.ZP,{bold:!0,muted:!0,children:"Current branch"})}),(0,V.jsxs)(v.ZP,{alignItems:"center",children:[(0,V.jsx)(y.Z,{fullSize:!0,label:"Choose a different branch to switch branches",widthFitContent:!0,children:(0,V.jsx)(g.Z,{beforeIcon:(0,V.jsx)(w.I0,{muted:!1}),beforeIconSize:2*L.iI,monospace:!0,onChange:function(e){return oe({git_custom_branch:{name:e.target.value}})},value:null===r||void 0===r?void 0:r.name,children:(null===r||void 0===r?void 0:r.name)&&(null===t||void 0===t?void 0:t.map((function(e){var n=e.name;return(0,V.jsx)("option",{value:n,children:n},n)})))})}),(0,V.jsx)(p.Z,{mr:L.cd}),ie&&(0,V.jsx)(j.Z,{inverted:!0})]})]})]})}),(0,V.jsx)(p.Z,{mt:L.Mq,children:(0,V.jsxs)(v.ZP,{alignItems:"center",children:[(0,V.jsx)(P.Z,{label:"New branch name",monospace:!0,onChange:function(e){var n;return K(null===e||void 0===e||null===(n=e.target)||void 0===n?void 0:n.value)},value:z||""}),(0,V.jsx)(p.Z,{mr:1}),(0,V.jsx)(f.ZP,{beforeIcon:(0,V.jsx)(w.mm,{size:2*L.iI}),disabled:!z,loading:ne,onClick:function(){ee({git_custom_branch:{name:z}})},primary:!0,children:"Create new branch"})]})})]}),(0,V.jsxs)(p.Z,{mb:L.HN,children:[(0,V.jsx)(b.Z,{children:"Actions"}),(0,V.jsxs)(p.Z,{mt:L.Mq,children:[(0,V.jsxs)(p.Z,{mb:L.Mq,children:[(0,V.jsx)(p.Z,{mb:1,children:(0,V.jsx)(x.ZP,{bold:!0,muted:!0,children:"Compare branch"})}),(null===r||void 0===r?void 0:r.name)&&(0,V.jsx)(x.ZP,{monospace:!0,children:null===r||void 0===r?void 0:r.name})]}),(0,V.jsxs)(v.ZP,{alignItems:"center",children:[(0,V.jsxs)("div",{children:[(0,V.jsx)(p.Z,{mb:1,children:(0,V.jsx)(x.ZP,{bold:!0,muted:!0,children:"Base branch"})}),(0,V.jsx)(g.Z,{beforeIcon:(0,V.jsx)(w.I0,{}),beforeIconSize:1.5*L.iI,monospace:!0,onChange:function(e){return q(e.target.value)},placeholder:"Choose a branch",value:U,children:null===X||void 0===X?void 0:X.map((function(e){var n=e.name;return(0,V.jsx)("option",{value:n,children:n},n)}))})]}),(0,V.jsx)(p.Z,{mr:1}),(0,V.jsxs)("div",{children:[(0,V.jsx)(p.Z,{mb:1,children:(0,V.jsx)(x.ZP,{bold:!0,muted:!0,children:"Action"})}),(0,V.jsxs)(g.Z,{onChange:function(e){return N(e.target.value)},placeholder:"Choose action",value:A||"",children:[(0,V.jsx)("option",{value:O,children:(0,F.vg)(O)}),(0,V.jsx)("option",{value:E,children:(0,F.vg)(E)}),(0,V.jsx)("option",{value:k,children:(0,F.vg)(k)})]})]})]}),A&&[O,E].includes(A)&&(0,V.jsxs)(p.Z,{mt:L.cd,children:[(0,V.jsx)(p.Z,{mb:1,children:(0,V.jsxs)(x.ZP,{bold:!0,muted:!0,children:["Message for ",A]})}),(0,V.jsx)(Z.Z,{monospace:!0,onChange:function(e){return I(e.target.value)},value:S||""})]}),(0,V.jsxs)(p.Z,{mt:L.cd,children:[(0,V.jsx)(f.ZP,{beforeIcon:(0,V.jsx)(w.Bf,{size:2*L.iI}),disabled:!A||!U,loading:se,onClick:function(){(k!==A||"undefined"!==typeof location&&window.confirm("Are you sure you want to delete branch ".concat(U,"?")))&&ue({git_custom_branch:(0,c.Z)({action_type:A,message:S},A,{base_branch:U})})},primary:!0,children:A?(0,F.vg)(A):"Execute action"}),D&&(0,V.jsx)(p.Z,{mt:L.cd,children:(0,V.jsx)(x.ZP,{default:!0,monospace:!0,preWrap:!0,children:D})})]})]})]}),(0,V.jsxs)(p.Z,{mb:L.HN,children:[(0,V.jsx)(p.Z,{mb:L.HN,children:(0,V.jsx)(m.Z,{light:!0})}),(0,V.jsxs)(v.ZP,{children:[(0,V.jsx)(f.ZP,{beforeIcon:(0,V.jsx)(w.Hd,{}),linkProps:{href:"/version-control?tab=".concat(B.uuid)},noBackground:!0,noHoverUnderline:!0,sameColorAsText:!0,children:B.uuid}),(0,V.jsx)(p.Z,{mr:1}),(0,V.jsxs)(f.ZP,{afterIcon:(0,V.jsx)(w.Kw,{}),linkProps:{href:"/version-control?tab=".concat(M.uuid)},noHoverUnderline:!0,sameColorAsText:!0,secondary:!0,children:["Next: ",M.uuid]})]})]})]})},U=r(90299),q=r(32013),W=r(98777),z=r(48670),K=r(75499);function Q(e,n){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);n&&(t=t.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),r.push.apply(r,t)}return r}function X(e){for(var n=1;n<arguments.length;n++){var r=null!=arguments[n]?arguments[n]:{};n%2?Q(Object(r),!0).forEach((function(n){(0,c.Z)(e,n,r[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Q(Object(r)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))}))}return e}var J={base_branch:null,body:null,compare_branch:null,repository:null,title:null};var $=function(e){var n=e.actionRemoteName,r=e.branch,t=e.branches,o=e.fetchBranch,i=e.loading,l=e.remotes,s=e.repositories,a=e.repositoryName,y=e.setActionRemoteName,C=e.setRepositoryName,k=e.showError,S=(0,d.useState)((null===r||void 0===r?void 0:r.name)||""),O=S[0],I=S[1],E=(0,d.useState)(null),A=E[0],N=E[1],R=(0,d.useState)(null),D=R[0],B=R[1],H=(0,d.useState)(J),Y=H[0],U=H[1],Q=(0,h.Db)(_.ZP.git_custom_branches.useUpdate(null===r||void 0===r?void 0:r.name),{onSuccess:function(e){return(0,G.wD)(e,{callback:function(e){var n=e.git_custom_branch,r=n.error,t=n.progress;r?(N(r),B(null)):(o(),N(null),B(t))},onErrorCallback:function(e,n){return k({errors:n,response:e})}})}}),$=(0,u.Z)(Q,2),ee=$[0],ne=$[1].isLoading,re=_.ZP.pull_requests.list({repository:a},{},{pauseFetch:!a}),te=re.data,oe=re.mutate,ie=(0,d.useMemo)((function(){return(null===te||void 0===te?void 0:te.pull_requests)||[]}),[te]),le=(0,d.useMemo)((function(){return(0,V.jsx)(K.Z,{columnFlex:[null,null,null,null],columns:[{uuid:"Title"},{uuid:"Author"},{uuid:"Created"},{uuid:"Last modified"}],onClickRow:function(e){var n,r=null===ie||void 0===ie||null===(n=ie[e])||void 0===n?void 0:n.url;r&&window.open(r,"_blank")},rows:null===ie||void 0===ie?void 0:ie.map((function(e){var n=e.created_at,r=e.last_modified,t=e.title,o=e.url,i=e.user;return[(0,V.jsx)(z.Z,{default:!0,href:o,monospace:!0,openNewWindow:!0,small:!0,children:t},"title"),(0,V.jsx)(x.ZP,{default:!0,monospace:!0,small:!0,children:i},"user"),(0,V.jsx)(x.ZP,{default:!0,monospace:!0,small:!0,children:n},"createdAt"),(0,V.jsx)(x.ZP,{default:!0,monospace:!0,small:!0,children:r||"-"},"lastModified")]})),uuid:"pull-requests"})}),[ie]),ce=_.ZP.git_custom_branches.list({repository:a},{},{pauseFetch:!a}).data,ue=(0,d.useMemo)((function(){return(null===ce||void 0===ce?void 0:ce.git_custom_branches)||[]}),[ce]);(0,d.useEffect)((function(){null!==Y&&void 0!==Y&&Y.compare_branch||null===ue||void 0===ue||!ue.find((function(e){return e.name===(null===r||void 0===r?void 0:r.name)}))||U((function(e){return X(X({},e),{},{compare_branch:null===r||void 0===r?void 0:r.name})}))}),[r,ue,Y]);var se=(0,h.Db)(_.ZP.pull_requests.useCreate(),{onSuccess:function(e){return(0,G.wD)(e,{callback:function(){oe(),U(J)},onErrorCallback:function(e,n){return k({errors:n,response:e})}})}}),ae=(0,u.Z)(se,2),de=ae[0],he=ae[1].isLoading;return(0,V.jsxs)(V.Fragment,{children:[(0,V.jsxs)(p.Z,{mb:L.HN,children:[(0,V.jsx)(p.Z,{mb:1,children:(0,V.jsx)(b.Z,{children:(0,F.vg)(T)})}),(0,V.jsxs)(p.Z,{mt:L.Mq,children:[(0,V.jsxs)(v.ZP,{children:[(0,V.jsxs)("div",{children:[(0,V.jsx)(p.Z,{mb:1,children:(0,V.jsx)(x.ZP,{bold:!0,muted:!0,children:"Remote"})}),i&&(0,V.jsx)(j.Z,{inverted:!0}),!i&&(0,V.jsx)(g.Z,{beforeIcon:(0,V.jsx)(w.VW,{}),beforeIconSize:1.5*L.iI,monospace:!0,onChange:function(e){return y(e.target.value)},placeholder:"Choose remote",value:n||"",children:null===l||void 0===l?void 0:l.map((function(e){var n=e.name;return(0,V.jsx)("option",{value:n,children:n},n)}))})]}),(0,V.jsx)(p.Z,{mr:1}),(0,V.jsxs)("div",{children:[(0,V.jsx)(p.Z,{mb:1,children:(0,V.jsx)(x.ZP,{bold:!0,muted:!0,children:"Branch"})}),(0,V.jsxs)(g.Z,{beforeIcon:(0,V.jsx)(w.I0,{}),beforeIconSize:1.5*L.iI,monospace:!0,onChange:function(e){return I(e.target.value)},placeholder:"Choose branch",value:O||"",children:[(0,V.jsx)("option",{value:""}),null===t||void 0===t?void 0:t.map((function(e){var n=e.name;return(0,V.jsx)("option",{value:n,children:n},n)}))]})]})]}),(0,V.jsx)(p.Z,{mt:L.cd,children:(0,V.jsxs)(f.ZP,{beforeIcon:(0,V.jsx)(w.Bf,{size:2*L.iI}),disabled:!n||!O,loading:ne,onClick:function(){B(null),ee({git_custom_branch:(0,c.Z)({action_type:T},T,{branch:O,remote:n})})},primary:!0,children:[(0,F.vg)(T)," ",n," ",n&&O]})}),(D||A)&&(0,V.jsx)(p.Z,{mt:L.cd,children:(0,V.jsx)(x.ZP,{danger:!!A,default:!!D,monospace:!0,preWrap:!0,children:D||A})})]})]}),(0,V.jsxs)(p.Z,{mb:L.HN,children:[(0,V.jsx)(p.Z,{mb:1,children:(0,V.jsx)(b.Z,{children:"Create pull request"})}),(0,V.jsxs)(p.Z,{mt:L.Mq,children:[i&&(0,V.jsx)(j.Z,{inverted:!0}),!i&&(0,V.jsxs)(V.Fragment,{children:[(0,V.jsxs)(v.ZP,{children:[(0,V.jsxs)("div",{children:[(0,V.jsx)(p.Z,{mb:1,children:(0,V.jsx)(x.ZP,{bold:!0,muted:!0,children:"Repository"})}),(0,V.jsx)(g.Z,{beforeIcon:(0,V.jsx)(w.fy,{}),beforeIconSize:1.5*L.iI,monospace:!0,onChange:function(e){return C(e.target.value)},placeholder:"Choose repository",value:a||"",children:null===s||void 0===s?void 0:s.map((function(e){var n=e.name;return(0,V.jsx)("option",{value:n,children:n},n)}))})]}),(0,V.jsx)(p.Z,{mr:1}),(0,V.jsxs)("div",{children:[(0,V.jsx)(p.Z,{mb:1,children:(0,V.jsx)(x.ZP,{bold:!0,muted:!0,children:"Base branch"})}),a&&!ce&&(0,V.jsx)(j.Z,{inverted:!0}),(!a||ce)&&(0,V.jsx)(g.Z,{beforeIcon:(0,V.jsx)(w.I0,{}),beforeIconSize:1.5*L.iI,disabled:!a,monospace:!0,onChange:function(e){return U((function(n){return X(X({},n),{},{base_branch:e.target.value})}))},placeholder:"Choose branch",value:(null===Y||void 0===Y?void 0:Y.base_branch)||"",children:null===ue||void 0===ue?void 0:ue.map((function(e){var n=e.name;return(0,V.jsx)("option",{value:n,children:n},n)}))})]}),(0,V.jsx)(p.Z,{mr:1}),(0,V.jsxs)("div",{children:[(0,V.jsx)(p.Z,{mb:1,children:(0,V.jsx)(x.ZP,{bold:!0,muted:!0,children:"Compare branch"})}),a&&!ce&&(0,V.jsx)(j.Z,{inverted:!0}),(!a||ce||(null===Y||void 0===Y?void 0:Y.compare_branch))&&(0,V.jsxs)(g.Z,{beforeIcon:(0,V.jsx)(w.I0,{}),beforeIconSize:1.5*L.iI,disabled:!a,monospace:!0,onChange:function(e){return U((function(n){return X(X({},n),{},{compare_branch:e.target.value})}))},placeholder:"Choose branch",value:(null===Y||void 0===Y?void 0:Y.compare_branch)||"",children:[!(null!==ue&&void 0!==ue&&ue.length)&&(null===Y||void 0===Y?void 0:Y.compare_branch)&&(0,V.jsx)("option",{value:null===Y||void 0===Y?void 0:Y.compare_branch,children:null===Y||void 0===Y?void 0:Y.compare_branch}),null===ue||void 0===ue?void 0:ue.map((function(e){var n=e.name;return(0,V.jsx)("option",{value:n,children:n},n)}))]})]})]}),(0,V.jsx)(p.Z,{mt:1,children:(0,V.jsx)(P.Z,{label:"Title",monospace:!0,onChange:function(e){return U((function(n){return X(X({},n),{},{title:e.target.value})}))},value:(null===Y||void 0===Y?void 0:Y.title)||""})}),(0,V.jsx)(p.Z,{mt:1,children:(0,V.jsx)(Z.Z,{label:"Description",monospace:!0,onChange:function(e){return U((function(n){return X(X({},n),{},{body:e.target.value})}))},value:(null===Y||void 0===Y?void 0:Y.body)||""})}),(0,V.jsx)(p.Z,{mt:L.cd,children:(0,V.jsx)(f.ZP,{beforeIcon:(0,V.jsx)(w.Bf,{size:2*L.iI}),disabled:!a||!(null!==Y&&void 0!==Y&&Y.title)||!(null!==Y&&void 0!==Y&&Y.base_branch)||!(null!==Y&&void 0!==Y&&Y.compare_branch),loading:he,onClick:function(){de({pull_request:X(X({},Y),{},{repository:a})})},primary:!0,children:"Create new pull request"})})]})]}),(0,V.jsx)(p.Z,{mt:L.Mq,children:(0,V.jsx)(q.Z,{visibleMapping:{0:!a},children:(0,V.jsxs)(W.Z,{noPaddingContent:!0,title:te?"Pull requests (".concat(null===ie||void 0===ie?void 0:ie.length,")"):"Pull requests",children:[!a&&(0,V.jsx)(p.Z,{p:L.cd,children:(0,V.jsx)(x.ZP,{muted:!0,children:"Please select a repository to view open pull requests."})}),a&&(0,V.jsxs)(V.Fragment,{children:[!te&&(0,V.jsx)(p.Z,{p:L.cd,children:(0,V.jsx)(j.Z,{inverted:!0})}),te&&le]})]})})})]}),(0,V.jsxs)(p.Z,{mb:L.HN,children:[(0,V.jsx)(p.Z,{mb:L.HN,children:(0,V.jsx)(m.Z,{light:!0})}),(0,V.jsx)(v.ZP,{children:(0,V.jsx)(f.ZP,{beforeIcon:(0,V.jsx)(w.Hd,{}),linkProps:{href:"/version-control?tab=".concat(M.uuid)},noBackground:!0,noHoverUnderline:!0,sameColorAsText:!0,children:M.uuid})})]})]})},ee=r(94629),ne=r(10553),re=r(70652),te=r(97618),oe=r(38626),ie=oe.default.div.withConfig({displayName:"indexstyle__SpacingStyle",componentId:"sc-el09vr-0"})(["margin-top:","px;"],.5*L.iI),le=r(42122);function ce(e,n){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);n&&(t=t.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),r.push.apply(r,t)}return r}function ue(e){for(var n=1;n<arguments.length;n++){var r=null!=arguments[n]?arguments[n]:{};n%2?ce(Object(r),!0).forEach((function(n){(0,c.Z)(e,n,r[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ce(Object(r)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))}))}return e}var se=function(e){var n=e.branch,r=e.fetchBranch,t=e.modifiedFiles,o=e.setSelectedFilePath,i=e.showError,l=e.stagedFiles,c=e.untrackedFiles,s=(0,d.useRef)(null),a=(0,d.useState)(""),g=a[0],P=a[1],y=(0,d.useState)({}),C=y[0],k=y[1],S=(0,d.useState)({}),O=S[0],I=S[1],T=(0,d.useMemo)((function(){return Object.keys(t).concat(Object.keys(c)).sort()}),[t,c]),E=(0,d.useMemo)((function(){return Object.keys(l||{})}),[l]),A=(0,d.useMemo)((function(){return E.length}),[E]),N=(0,d.useMemo)((function(){return Object.keys(C).length===(null===T||void 0===T?void 0:T.length)}),[C,T]),M=(0,d.useMemo)((function(){return Object.keys(O).length===(null===E||void 0===E?void 0:E.length)}),[O,E]),B=(0,d.useMemo)((function(){return{onErrorCallback:function(e,n){return i({errors:n,response:e})}}}),[i]),H=(0,d.useMemo)((function(){return{onSuccess:function(e){return(0,G.wD)(e,ue({callback:function(){r(),k({})}},B))}}}),[r,B]),Y=(0,d.useMemo)((function(){return _.ZP.git_custom_branches.useUpdate(null===n||void 0===n?void 0:n.name)}),[n]),U=(0,h.Db)(Y,H),Q=(0,u.Z)(U,2),X=Q[0],J=Q[1].isLoading,$=(0,h.Db)(Y,H),ee=(0,u.Z)($,2),ne=ee[0],oe=ee[1].isLoading,ce=(0,h.Db)(Y,{onSuccess:function(e){return(0,G.wD)(e,ue({callback:function(){r(),I({})}},B))}}),se=(0,u.Z)(ce,2),ae=se[0],de=se[1].isLoading,he=(0,d.useCallback)((function(e,n,r,t,o){var i=(null===e||void 0===e?void 0:e.length)>=1;return(0,V.jsxs)(V.Fragment,{children:[(0,V.jsx)(z.Z,{block:!0,noHoverUnderline:!0,onClick:function(){r(o?{}:t)},preventDefault:!0,children:(0,V.jsxs)(v.ZP,{alignItems:"center",flexDirection:"row",children:[(0,V.jsx)(re.Z,{checked:i&&o,disabled:!i}),(0,V.jsx)(p.Z,{mr:1}),(0,V.jsx)(x.ZP,{bold:!0,children:i&&o?"Unselect all":"Select all"})]})}),e.map((function(e){return(0,V.jsx)(ie,{children:(0,V.jsx)(z.Z,{block:!0,noHoverUnderline:!0,onClick:function(){return r((function(n){var r=ue({},n);return!(null!==r&&void 0!==r&&r[e])?r[e]=!0:delete r[e],r}))},preventDefault:!0,children:(0,V.jsxs)(v.ZP,{alignItems:"center",flexDirection:"row",children:[(0,V.jsx)(re.Z,{checked:!(null===n||void 0===n||!n[e])}),(0,V.jsx)(p.Z,{mr:1}),(0,V.jsx)(x.ZP,{default:!0,monospace:!0,children:e})]})})},e)}))]})}),[]),fe=(0,d.useMemo)((function(){return(0,le.Qr)(C)}),[C]),me=_.ZP.git_custom_branches.detail("with_logs",{_format:"with_logs"}),ve=me.data,be=me.mutate,ge=(0,d.useMemo)((function(){var e;return(null===ve||void 0===ve||null===(e=ve.git_custom_branch)||void 0===e?void 0:e.logs)||[]}),[ve]),pe=(0,h.Db)(_.ZP.git_custom_branches.useUpdate(null===n||void 0===n?void 0:n.name),{onSuccess:function(e){return(0,G.wD)(e,{callback:function(){be(),r(),P("")},onErrorCallback:function(e,n){return i({errors:n,response:e})}})}}),je=(0,u.Z)(pe,2),xe=je[0],Ze=je[1].isLoading,Pe=(0,d.useMemo)((function(){return(0,V.jsx)(K.Z,{columnFlex:[1,1,1],columns:[{uuid:"Author"},{uuid:"Date"},{uuid:"Message"}],rows:ge.map((function(e){var n=e.author,r=e.date,t=e.message;return[(0,V.jsx)(x.ZP,{default:!0,monospace:!0,small:!0,children:null===n||void 0===n?void 0:n.name},"author"),(0,V.jsx)(x.ZP,{default:!0,monospace:!0,small:!0,children:r},"date"),(0,V.jsx)(x.ZP,{default:!0,monospace:!0,small:!0,children:t},"message")]})),uuid:"git-branch-logs"})}),[ge]);return(0,V.jsxs)(V.Fragment,{children:[(0,V.jsx)(p.Z,{mb:L.HN,children:(0,V.jsxs)(v.ZP,{children:[(0,V.jsxs)(te.Z,{flex:1,flexDirection:"column",children:[(0,V.jsxs)(b.Z,{children:["Not staged ",(null===T||void 0===T?void 0:T.length)>=1&&"(".concat(null===T||void 0===T?void 0:T.length,")")]}),(0,V.jsx)(p.Z,{my:L.cd,children:(0,V.jsx)(m.Z,{light:!0})}),(0,V.jsx)(p.Z,{mb:L.cd,children:(0,V.jsxs)(v.ZP,{flexDirection:"row",children:[(0,V.jsx)(f.ZP,{compact:!0,disabled:fe||de||oe,loading:J,onClick:function(){X({git_custom_branch:{action_type:"add",files:Object.keys(C)}}).then((function(e){var n,r=e.data;null!==r&&void 0!==r&&r.git_custom_branch&&(null===s||void 0===s||null===(n=s.current)||void 0===n||n.focus())}))},primary:!0,children:"Add files"}),(0,V.jsx)(p.Z,{mr:1}),(0,V.jsx)(f.ZP,{compact:!0,disabled:fe||J||de,loading:oe,noBackground:!0,onClick:function(){"undefined"!==typeof location&&window.confirm("Are you sure you want to undo all changes in the selected files?")&&ne({git_custom_branch:{action_type:"checkout",files:Object.keys(C)}})},children:"Checkout files"})]})}),he(T,C,k,ue(ue({},t),c),N)]}),(0,V.jsx)(p.Z,{mr:L.cd}),(0,V.jsxs)(te.Z,{flex:1,flexDirection:"column",children:[(0,V.jsxs)(b.Z,{children:["Staged files ",(null===E||void 0===E?void 0:E.length)>=1&&"(".concat(null===E||void 0===E?void 0:E.length,")")]}),(0,V.jsx)(p.Z,{my:L.cd,children:(0,V.jsx)(m.Z,{light:!0})}),(0,V.jsx)(p.Z,{mb:L.cd,children:(0,V.jsx)(v.ZP,{flexDirection:"row",children:(0,V.jsx)(f.ZP,{compact:!0,disabled:(0,le.Qr)(O)||J||oe,loading:de,onClick:function(){ae({git_custom_branch:{action_type:"reset",files:Object.keys(O)}})},secondary:!0,children:"Reset files"})})}),he(E,O,I,l,M)]})]})}),(0,V.jsxs)(p.Z,{mb:L.HN,children:[(0,V.jsx)(p.Z,{mb:1,children:(0,V.jsx)(b.Z,{children:"Commit"})}),(0,V.jsx)(p.Z,{mb:L.cd,children:(0,V.jsx)(q.Z,{children:(0,V.jsx)(W.Z,{noPaddingContent:!0,title:A>=1?"Staged files (".concat(A,")"):"No staged files",children:null===E||void 0===E?void 0:E.map((function(e){return(0,V.jsx)(p.Z,{my:1,px:L.cd,children:(0,V.jsxs)(v.ZP,{justifyContent:"space-between",children:[(0,V.jsx)(z.Z,{default:!0,monospace:!0,onClick:function(){return o((function(n){return n===e?null:e}))},warning:null===t||void 0===t?void 0:t[e],children:e}),(0,V.jsx)(p.Z,{mr:1}),(null===t||void 0===t?void 0:t[e])&&(0,V.jsx)(x.ZP,{warning:!0,children:"Modified after staging"})]})},e)}))})})}),(0,V.jsx)(Z.Z,{label:"Commit message",monospace:!0,onChange:function(e){return P(e.target.value)},ref:s,value:g||""}),(0,V.jsx)(p.Z,{mt:L.cd,children:(0,V.jsxs)(v.ZP,{alignItems:"center",children:[(0,V.jsxs)(f.ZP,{disabled:0===A||!((null===g||void 0===g?void 0:g.length)>=1),loading:Ze,onClick:function(){xe({git_custom_branch:{action_type:"commit",message:g}})},primary:!0,children:["Commit ",(0,F._6)("file",A,!0)," with message"]}),0===A&&(0,V.jsxs)(V.Fragment,{children:[(0,V.jsx)(p.Z,{mr:1}),(0,V.jsx)(x.ZP,{danger:!0,small:!0,children:"Please stage at least 1 file before committing."})]})]})})]}),(0,V.jsx)(p.Z,{mb:L.HN,children:(0,V.jsx)(q.Z,{children:(0,V.jsxs)(W.Z,{noPaddingContent:!0,title:"Logs",children:[!ve&&(0,V.jsx)(p.Z,{p:L.cd,children:(0,V.jsx)(j.Z,{inverted:!0})}),ve&&Pe]})})}),(0,V.jsxs)(p.Z,{mb:L.HN,children:[(0,V.jsx)(p.Z,{mb:L.HN,children:(0,V.jsx)(m.Z,{light:!0})}),(0,V.jsxs)(v.ZP,{children:[(0,V.jsx)(f.ZP,{beforeIcon:(0,V.jsx)(w.Hd,{}),linkProps:{href:"/version-control?tab=".concat(R.uuid)},noBackground:!0,noHoverUnderline:!0,sameColorAsText:!0,children:R.uuid}),(0,V.jsx)(p.Z,{mr:1}),(0,V.jsxs)(f.ZP,{afterIcon:(0,V.jsx)(w.Kw,{}),linkProps:fe?{href:"/version-control?tab=".concat(D.uuid)}:null,noHoverUnderline:!0,primary:fe,sameColorAsText:!0,secondary:!fe,children:["Next: ",D.uuid]})]})]})]})},ae=r(12691),de=r.n(ae),he=r(34376),fe=r(40109),me=r(69419),ve=r(53808);var be=function(e){var n=e.actionRemoteName,r=e.branch,t=e.fetchBranch,o=e.loading,i=e.remotes,l=e.setActionRemoteName,s=e.showError,a=(0,he.useRouter)(),Z=(0,d.useRef)(null),y=(0,d.useState)(null),k=y[0],O=y[1],T=(0,d.useState)(null),E=T[0],A=T[1],N=(0,d.useState)(null),M=N[0],D=N[1],B=(0,d.useState)(null),H=B[0],Y=B[1],U=(0,d.useState)(!1),Q=U[0],X=U[1],J=(0,d.useState)(null),$=J[0],ee=J[1],ne=(0,d.useState)(""),re=ne[0],oe=ne[1],ie=(0,d.useState)(""),le=ie[0],ce=ie[1],ue=(0,d.useState)(null),se=ue[0],ae=ue[1],be=(0,d.useMemo)((function(){return!(null===r||void 0===r||!r.name)}),[r]),ge=(0,d.useMemo)((function(){return null===r||void 0===r?void 0:r.access_token_exists}),[r]);(0,d.useEffect)((function(){var e,n;null!==r&&void 0!==r&&null!==(e=r.sync_config)&&void 0!==e&&e.repo_path&&null===se&&ae(null===r||void 0===r||null===(n=r.sync_config)||void 0===n?void 0:n.repo_path)}),[r,se]);var pe=(0,d.useMemo)((function(){var e,r;return null===i||void 0===i||null===(e=i.find((function(e){return e.name===n})))||void 0===e||null===(r=e.refs)||void 0===r?void 0:r.map((function(e){var n=e.name.split("/");return{name:n[n.length-1]}}))}),[n,i]),je=(0,h.Db)(_.ZP.syncs.useCreate(),{onSuccess:function(e){return(0,G.wD)(e,{callback:function(){t(),X(!1)},onErrorCallback:function(e,n){return s({errors:n,response:e})}})}}),xe=(0,u.Z)(je,2),Ze=xe[0],Pe=xe[1].isLoading,ye=(0,h.Db)(_.ZP.oauths.useUpdate("github"),{onSuccess:function(e){return(0,G.wD)(e,{callback:function(){return window.location.href=window.location.href.split("?")[0]},onErrorCallback:function(e,n){return s({errors:n,response:e})}})}}),_e=(0,u.Z)(ye,2),we=_e[0],Ce=_e[1].isLoading,ke=(0,h.Db)(_.ZP.git_custom_branches.useUpdate(null===r||void 0===r?void 0:r.name),{onSuccess:function(e){return(0,G.wD)(e,{callback:function(e){var n=e.git_custom_branch,r=n.error,o=n.progress;r?(A(r),Y(null)):(t(),O(null),A(null),D(null),Y(o))},onErrorCallback:function(e,n){return s({errors:n,response:e})}})}}),Se=(0,u.Z)(ke,2),Oe=Se[0],Ie=Se[1].isLoading,Te=(0,h.Db)(_.ZP.git_custom_branches.useUpdate(null===r||void 0===r?void 0:r.name),{onSuccess:function(e){return(0,G.wD)(e,{callback:function(){t(),oe(""),ce("")},onErrorCallback:function(e,n){return s({errors:n,response:e})}})}}),Ee=(0,u.Z)(Te,2),Ae=Ee[0],Ne=Ee[1].isLoading,Re=(0,h.Db)(_.ZP.git_custom_branches.useUpdate(null===r||void 0===r?void 0:r.name),{onSuccess:function(e){return(0,G.wD)(e,{callback:function(){t(),ee(null)},onErrorCallback:function(e,n){ee(null),s({errors:n,response:e})}})}}),Me=(0,u.Z)(Re,2),De=Me[0],Be=Me[1].isLoading,He=_.ZP.oauths.detail(fe.h.GITHUB,{redirect_uri:encodeURIComponent(window.location.href)}),Le=He.data,Fe=He.mutate,Ge=(0,d.useMemo)((function(){return(null===Le||void 0===Le?void 0:Le.oauth)||{}}),[Le]),Ve=(0,h.Db)(_.ZP.oauths.useCreate(),{onSuccess:function(e){return(0,G.wD)(e,{callback:function(){Fe()},onErrorCallback:function(e,n){s({errors:n,response:e})}})}}),Ye=(0,u.Z)(Ve,2),Ue=Ye[0],qe=Ye[1].isLoading,We=(0,me.iV)()||{},ze=We.access_token,Ke=We.provider;(0,d.useEffect)((function(){!Ge||null!==Ge&&void 0!==Ge&&Ge.authenticated||!ze||Ue({oauth:{provider:Ke||fe.h.GITHUB,token:ze}})}),[ze,Ue,Ge,Ke]);var Qe=(0,d.useMemo)((function(){return null===i||void 0===i?void 0:i.map((function(e){var r=e.name,t=e.refs,o=e.urls;return(0,V.jsxs)(p.Z,{mt:L.Mq,children:[(0,V.jsx)(p.Z,{mb:1,children:(0,V.jsxs)(v.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,V.jsxs)(te.Z,{alignItems:"center",children:[(0,V.jsx)(x.ZP,{bold:!0,children:r}),(0,V.jsx)(p.Z,{mx:1,children:(0,V.jsx)(w._Q,{muted:!0})}),null===o||void 0===o?void 0:o.map((function(e){return(0,V.jsx)(p.Z,{mr:1,children:(0,V.jsx)(x.ZP,{default:!0,monospace:!0,small:!0,children:e})},e)}))]}),(0,V.jsx)(p.Z,{mr:1}),(0,V.jsx)(f.ZP,{compact:!0,disabled:Be&&$!==r,iconOnly:!0,loading:Be&&$===r,noBackground:!0,onClick:function(){"undefined"!==typeof location&&window.confirm("Are you sure you want to remove remote ".concat(r,"?"))&&(ee(r),De({git_custom_branch:{action_type:"remove_remote",remote:{name:r}}}).then((function(){n===r&&l(null)})))},small:!0,title:"Remote remote ".concat(r),children:(0,V.jsx)(w.rF,{})})]})}),(0,V.jsx)(q.Z,{children:(0,V.jsxs)(W.Z,{noPaddingContent:!0,smallTitle:!0,title:"Refs (".concat(null===t||void 0===t?void 0:t.length,")"),children:[0===(null===t||void 0===t?void 0:t.length)&&(0,V.jsx)(p.Z,{p:L.cd,children:(0,V.jsx)(x.ZP,{muted:!0,children:"This remote has no refs."})}),(null===t||void 0===t?void 0:t.length)>=1&&(0,V.jsx)(K.Z,{columnFlex:[1,1,1],columns:[{uuid:"Ref"},{uuid:"Author"},{uuid:"Date"},{uuid:"Message"}],rows:t.map((function(e){var n,r=e.commit,t=e.name;return[(0,V.jsx)(x.ZP,{default:!0,monospace:!0,small:!0,children:t},"ref-name"),(0,V.jsx)(x.ZP,{default:!0,monospace:!0,small:!0,children:null===r||void 0===r||null===(n=r.author)||void 0===n?void 0:n.name},"author"),(0,V.jsx)(x.ZP,{default:!0,monospace:!0,small:!0,children:null===r||void 0===r?void 0:r.date},"date"),(0,V.jsx)(x.ZP,{default:!0,monospace:!0,small:!0,children:null===r||void 0===r?void 0:r.message},"message")]})),uuid:"git-branch-remotes-refs"})]})}),(0,V.jsx)(p.Z,{mt:L.Mq,children:(0,V.jsx)(m.Z,{light:!0})})]},r)}))}),[Be,$,i,De]);return(0,V.jsxs)(V.Fragment,{children:[Le&&(0,V.jsxs)(p.Z,{mb:L.HN,children:[(null===Ge||void 0===Ge?void 0:Ge.authenticated)&&(0,V.jsxs)(V.Fragment,{children:[(0,V.jsx)(f.ZP,{beforeIcon:(0,V.jsx)(w.fy,{size:2*L.iI}),disabled:!0,children:"Successfully authenticated with GitHub"}),(0,V.jsx)(p.Z,{my:1,children:(0,V.jsx)(x.ZP,{muted:!0,children:"You can pull, push, and create pull requests on GitHub."})}),(0,V.jsx)(f.ZP,{loading:Ce,onClick:function(){return we({oauth:{action_type:"reset"}})},warning:!0,children:"Reset GitHub authentication"})]}),!(null!==Ge&&void 0!==Ge&&Ge.authenticated)&&(null===Ge||void 0===Ge?void 0:Ge.url)&&(0,V.jsxs)(V.Fragment,{children:[ge&&(0,V.jsxs)(p.Z,{mb:2,children:[(0,V.jsx)(f.ZP,{disabled:!0,children:"Using access token from Git Settings"}),(0,V.jsx)(p.Z,{mt:1,children:(0,V.jsx)(x.ZP,{muted:!0,children:"Some features may not work unless you authenticate with GitHub."})})]}),(0,V.jsx)(f.ZP,{beforeIcon:(0,V.jsx)(w.fy,{size:2*L.iI}),loading:qe,onClick:function(){var e=null===Ge||void 0===Ge?void 0:Ge.url,n=(0,me.iV)(e).state;(0,ve.t8)(n,(null===Ge||void 0===Ge?void 0:Ge.redirect_query_params)||{}),a.push(e)},primary:!0,children:"Authenticate with GitHub"}),(0,V.jsx)(p.Z,{mt:1,children:(0,V.jsx)(x.ZP,{muted:!0,children:"Authenticating with GitHub will allow you to pull, push, and create pull requests on GitHub."})})]})]}),(0,V.jsxs)(p.Z,{mb:L.HN,children:[(0,V.jsx)(b.Z,{children:"Setup"}),(0,V.jsxs)(p.Z,{mt:L.Mq,children:[(0,V.jsxs)(p.Z,{mb:1,children:[(0,V.jsx)(x.ZP,{bold:!0,large:!0,children:be?"Git init directory":"Initialize Git directory"}),!be&&(0,V.jsxs)(x.ZP,{muted:!0,children:["Enter the directory you want to initialize git in. For example, ",(0,V.jsx)(x.ZP,{bold:!0,inline:!0,monospace:!0,muted:!0,children:"/home/src/default_repo"}),"."]}),be&&(0,V.jsxs)(x.ZP,{muted:!0,children:["If the directory below is blank, then the current working directory will be used to initialize git.",(0,V.jsx)("br",{}),"If git hasn\u2019t been initialized in the directory below, Mage will automatically run git init for you."]})]}),(0,V.jsxs)(v.ZP,{alignItems:"center",children:[(0,V.jsx)(P.Z,{disabled:be&&!Q,label:"Git directory",monospace:!0,onChange:function(e){return ae(e.target.value)},ref:Z,value:se||""}),(0,V.jsx)(p.Z,{mr:1}),(!be||Q)&&(0,V.jsxs)(V.Fragment,{children:[(0,V.jsx)(f.ZP,{compact:!0,disabled:!be&&!se,loading:Pe,onClick:function(){Ze({sync:{repo_path:se}})},primary:!0,small:!0,children:"Save"}),be&&(0,V.jsxs)(V.Fragment,{children:[(0,V.jsx)(p.Z,{mr:1}),(0,V.jsx)(z.Z,{onClick:function(){return X(!1)},preventDefault:!0,sameColorAsText:!0,small:!0,children:"Cancel"})]})]}),be&&!Q&&(0,V.jsx)(z.Z,{onClick:function(){X(!0),setTimeout((function(){var e;return null===Z||void 0===Z||null===(e=Z.current)||void 0===e?void 0:e.focus()}),1)},preventDefault:!0,sameColorAsText:!0,small:!0,children:"Edit"})]})]})]}),be&&(0,V.jsxs)(V.Fragment,{children:[(0,V.jsxs)(p.Z,{mb:L.HN,children:[(0,V.jsxs)(b.Z,{children:["Remotes",!o&&i?" (".concat(null===i||void 0===i?void 0:i.length,")"):""]}),o&&(0,V.jsx)(p.Z,{mt:L.Mq,children:(0,V.jsx)(j.Z,{inverted:!0})}),!o&&Qe,(0,V.jsx)(p.Z,{mt:L.Mq,children:(0,V.jsxs)(v.ZP,{alignItems:"flex-start",children:[(0,V.jsx)(P.Z,{label:"New remote name",monospace:!0,onChange:function(e){var n;return oe(null===e||void 0===e||null===(n=e.target)||void 0===n?void 0:n.value)},value:re||""}),(0,V.jsx)(p.Z,{mr:1}),(0,V.jsxs)(v.ZP,{flexDirection:"column",children:[(0,V.jsx)(P.Z,{label:"Remote URL",monospace:!0,onChange:function(e){var n;return ce(null===e||void 0===e||null===(n=e.target)||void 0===n?void 0:n.value)},value:le||""}),(0,V.jsx)(p.Z,{mt:1,children:(0,V.jsxs)(x.ZP,{muted:!0,small:!0,children:["Use the https URL if you",(0,V.jsx)("br",{}),"authenticated with GitHub above."]})})]}),(0,V.jsx)(p.Z,{mr:1}),(0,V.jsx)(f.ZP,{beforeIcon:(0,V.jsx)(w.mm,{size:2*L.iI}),disabled:!re||!le,loading:Ne,onClick:function(){Ae({git_custom_branch:{action_type:"add_remote",remote:{name:re,url:le}}})},primary:!0,children:"Create new remote"})]})})]}),(0,V.jsxs)(p.Z,{mb:L.HN,children:[(0,V.jsx)(b.Z,{children:"Actions"}),(0,V.jsxs)(p.Z,{mt:L.Mq,children:[(0,V.jsxs)(p.Z,{mb:L.Mq,children:[(0,V.jsx)(p.Z,{mb:1,children:(0,V.jsx)(x.ZP,{bold:!0,muted:!0,children:"Current branch"})}),(null===r||void 0===r?void 0:r.name)&&(0,V.jsxs)(v.ZP,{alignItems:"center",children:[(0,V.jsx)(x.ZP,{monospace:!0,children:null===r||void 0===r?void 0:r.name}),(0,V.jsx)(p.Z,{mr:L.cd}),(0,V.jsx)(de(),{href:"/version-control?tab=".concat(R.uuid),passHref:!0,children:(0,V.jsx)(z.Z,{small:!0,children:"Switch branch"})})]})]}),(0,V.jsxs)(v.ZP,{children:[(0,V.jsxs)(g.Z,{onChange:function(e){return D(e.target.value)},placeholder:"Action",value:M||"",children:[(0,V.jsx)("option",{value:S,children:(0,F.vg)(S)}),(0,V.jsx)("option",{value:I,children:(0,F.vg)(I)}),(0,V.jsx)("option",{value:"reset",children:(0,F.vg)("reset --hard")}),(0,V.jsx)("option",{value:C,children:(0,F.vg)(C)})]}),(0,V.jsx)(p.Z,{mr:1}),(0,V.jsx)(g.Z,{beforeIcon:(0,V.jsx)(w.VW,{}),beforeIconSize:1.5*L.iI,monospace:!0,onChange:function(e){return l(e.target.value)},placeholder:"Remote",value:n||"",children:null===i||void 0===i?void 0:i.map((function(e){var n=e.name;return(0,V.jsx)("option",{value:n,children:n},n)}))}),![S,C].includes(M)&&(0,V.jsx)(p.Z,{ml:1,children:(0,V.jsxs)(g.Z,{beforeIcon:(0,V.jsx)(w.I0,{}),beforeIconSize:1.5*L.iI,monospace:!0,onChange:function(e){return O(e.target.value)},value:k||"",children:[(0,V.jsx)("option",{value:"",children:"All branches"}),null===pe||void 0===pe?void 0:pe.map((function(e){var n=e.name;return(0,V.jsx)("option",{value:n,children:n},n)}))]})})]}),(0,V.jsxs)(p.Z,{mt:L.cd,children:[(0,V.jsx)(f.ZP,{beforeIcon:(0,V.jsx)(w.Bf,{size:2*L.iI}),disabled:!M||!n,loading:Ie,onClick:function(){Y(null),(M!==C||"undefined"!==typeof location&&window.confirm("Are you sure you want to clone remote ".concat(n,"? This will ")+"overwrite all your local changes and may reset any settings you may have configured for your local Git repo. This action cannot be undone."))&&Oe({git_custom_branch:(0,c.Z)({action_type:M},M,{branch:k,remote:n})})},primary:!0,children:M?(0,F.vg)(M):"Execute action"}),(H||E)&&(0,V.jsx)(p.Z,{mt:L.cd,children:(0,V.jsx)(x.ZP,{danger:!!E,default:!!H,monospace:!0,preWrap:!0,children:H||E})})]})]})]}),(0,V.jsxs)(p.Z,{mb:L.HN,children:[(0,V.jsx)(p.Z,{mb:L.HN,children:(0,V.jsx)(m.Z,{light:!0})}),(0,V.jsx)(v.ZP,{children:(0,V.jsxs)(f.ZP,{afterIcon:(0,V.jsx)(w.Kw,{}),linkProps:{href:"/version-control?tab=".concat(R.uuid)},noHoverUnderline:!0,sameColorAsText:!0,secondary:!0,children:["Next: ",R.uuid]})})]})]})]})},ge=r(95363),pe=oe.default.div.withConfig({displayName:"indexstyle__DiffContainerStyle",componentId:"sc-1fo4nus-0"})(["pre{font-family:",";}"],ge.Vp),je={codeFoldGutter:{},content:{},contentText:{},diffAdded:{},diffContainer:{},diffRemoved:{},emptyGutter:{},emptyLine:{},gutter:{},highlightedGutter:{},highlightedLine:{},line:{},lineNumber:{},marker:{},splitView:{},titleBlock:{},variables:{dark:{addedBackground:"#044B53",addedColor:"white",addedGutterBackground:"#034148",addedGutterColor:"#8c8c8c",codeFoldBackground:"#262831",codeFoldContentColor:"#555a7b",codeFoldGutterBackground:"#21232b",diffViewerBackground:"#2e303c",diffViewerColor:"#FFF",diffViewerTitleBackground:"#2f323e",diffViewerTitleBorderColor:"#353846",diffViewerTitleColor:"#555a7b",emptyLineBackground:"#363946",gutterBackground:"#2c2f3a",gutterBackgroundDark:"#262933",gutterColor:"#464c67",highlightBackground:"#2a3967",highlightGutterBackground:"#2d4077",removedBackground:"#632F34",removedColor:"white",removedGutterBackground:"#632b30",removedGutterColor:"#8c8c8c",wordAddedBackground:"#055d67",wordRemovedBackground:"#7d383f"},light:{addedBackground:"#e6ffed",addedColor:"#24292e",addedGutterBackground:"#cdffd8",addedGutterColor:"#212529",codeFoldBackground:"#f1f8ff",codeFoldContentColor:"#212529",codeFoldGutterBackground:"#dbedff",diffViewerBackground:"#fff",diffViewerColor:"212529",diffViewerTitleBackground:"#fafbfc",diffViewerTitleBorderColor:"#eee",diffViewerTitleColor:"#212529",emptyLineBackground:"#fafbfc",gutterBackground:"#f7f7f7",gutterBackgroundDark:"#f3f1f1",gutterColor:"#212529",highlightBackground:"#fffbdd",highlightGutterBackground:"#fff5b1",removedBackground:"#ffeef0",removedColor:"#24292e",removedGutterBackground:"#ffdce0",removedGutterColor:"#212529",wordAddedBackground:"#acf2bd",wordRemovedBackground:"#fdb8c0"}},wordAdded:{},wordDiff:{},wordRemoved:{}},xe=r(53005),Ze=r(15610),Pe=r(86735),ye=r(23780);function _e(e,n){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);n&&(t=t.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),r.push.apply(r,t)}return r}function we(e){for(var n=1;n<arguments.length;n++){var r=null!=arguments[n]?arguments[n]:{};n%2?_e(Object(r),!0).forEach((function(n){(0,c.Z)(e,n,r[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):_e(Object(r)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))}))}return e}var Ce=function(){var e=(0,d.useRef)(null),n=(0,d.useRef)(null),r=(0,ye.VI)(null,{},[],{uuid:"VersionControlPage"}),t=(0,u.Z)(r,1)[0],o=(0,d.useState)(null),i=o[0],l=o[1],h=(0,d.useState)(null),f=h[0],v=h[1],b=(0,d.useState)(H[0]),Z=b[0],P=b[1],w=(0,me.iV)();(0,d.useEffect)((function(){null!==w&&void 0!==w&&w.tab&&P(H.find((function(e){return e.uuid===(null===w||void 0===w?void 0:w.tab)})))}),[w]);var C=_.ZP.git_custom_branches.list({include_remote_branches:1}),k=C.data,S=C.mutate,O=(0,d.useMemo)((function(){return null===k||void 0===k?void 0:k.git_custom_branches}),[k]),I=_.ZP.git_custom_branches.detail("current",{_format:"with_files"}),T=I.data,E=I.mutate,F=(0,d.useMemo)((function(){return(null===T||void 0===T?void 0:T.git_custom_branch)||{}}),[T]),G=(0,d.useMemo)((function(){return(null===F||void 0===F?void 0:F.files)||[]}),[F]),q=_.ZP.git_custom_branches.detail("with_remotes",{_format:"with_remotes"}),W=q.data,z=q.mutate,K=(0,d.useMemo)((function(){return null===W||void 0===W?void 0:W.git_custom_branch}),[W]),Q=(0,d.useMemo)((function(){return(null===K||void 0===K?void 0:K.remotes)||[]}),[K]),X=(0,d.useState)(null),J=X[0],re=X[1],te=(0,d.useCallback)((function(e){(0,ve.t8)(A,e),re(e)}),[]);(0,d.useEffect)((function(){var e=(0,ve.U2)(A,null);if(W&&e){var n=null===Q||void 0===Q?void 0:Q.find((function(n){return n.name===e}));te(n?null===n||void 0===n?void 0:n.name:null)}}),[W,Q,te]);var oe=(0,d.useState)((0,ve.U2)(N,"")),ie=oe[0],ce=oe[1],ue=(0,d.useCallback)((function(e){(0,ve.t8)(N,e),ce(e)}),[]),ae=(0,d.useMemo)((function(){return(0,Pe.Tw)(Q.reduce((function(e,n){var r;return e.concat((null===n||void 0===n||null===(r=n.repository_names)||void 0===r?void 0:r.map((function(e){var r;return{name:e,url:null===n||void 0===n||null===(r=n.urls)||void 0===r?void 0:r[0]}})))||[])}),[]),(function(e){return e.name}))}),[Q]);(0,d.useEffect)((function(){var e=(0,ve.U2)(N,null);if(W&&e){var n=null===ae||void 0===ae?void 0:ae.find((function(n){return n.name===e}));ue(n?null===n||void 0===n?void 0:n.name:null)}}),[W,ae,ue]);var de=_.ZP.git_files.detail(f?encodeURIComponent(f):null,{base_branch:i}),he=de.data,fe=de.mutate,ge=(0,d.useMemo)((function(){return null===he||void 0===he?void 0:he.git_file}),[he]);(0,d.useEffect)((function(){i&&fe()}),[i,fe]),(0,d.useEffect)((function(){null!==he&&void 0!==he&&he.error&&t({errors:null===he||void 0===he?void 0:he.error,response:he})}),[he,t]);var _e=(0,d.useMemo)((function(){var e,n,r;return{modifiedFiles:null===F||void 0===F||null===(e=F.modified_files)||void 0===e?void 0:e.reduce((function(e,n){return we(we({},e),{},(0,c.Z)({},n,!0))}),{}),stagedFiles:null===F||void 0===F||null===(n=F.staged_files)||void 0===n?void 0:n.reduce((function(e,n){return we(we({},e),{},(0,c.Z)({},n,!0))}),{}),untrackedFiles:null===F||void 0===F||null===(r=F.untracked_files)||void 0===r?void 0:r.reduce((function(e,n){return we(we({},e),{},(0,c.Z)({},n,!0))}),{})}}),[F]),Ce=_e.modifiedFiles,ke=void 0===Ce?{}:Ce,Se=_e.stagedFiles,Oe=void 0===Se?{}:Se,Ie=_e.untrackedFiles,Te=void 0===Ie?{}:Ie;(0,d.useEffect)((function(){f&&(0,le.Qr)(ke)&&(0,le.Qr)(Oe)&&(0,le.Qr)(Te)&&v(null)}),[ke,f,Oe,Te]);var Ee=(0,d.useMemo)((function(){return(null===G||void 0===G?void 0:G.length)>=1?(0,V.jsx)(ne.Z,{allowEmptyFolders:!0,disableContextMenu:!0,fetchFileTree:E,files:G,isFileDisabled:function(){return!1},onClickFile:function(e){v((function(r){if(!r||r!==e){var t;if(!i)null===n||void 0===n||null===(t=n.current)||void 0===t||t.focus();return e}return null}))},ref:e,renderAfterContent:function(e){var n,r,t=e.children,o=(null===t||void 0===t?void 0:t.length)>=1,i=(0,xe.a9)(e);o&&(i="".concat(i,"/"));var l={};return null!==ke&&void 0!==ke&&ke[i]?(n="M",r="Modified",l.warning=!0):null!==Te&&void 0!==Te&&Te[i]?(n="U",r="Untracked",l.danger=!0):null!==Oe&&void 0!==Oe&&Oe[i]&&(n="S",r="Staged",l.success=!0),o&&!n?null:(0,V.jsx)(p.Z,{mx:1,children:(0,V.jsx)(y.Z,{appearBefore:!0,label:r,widthFitContent:!0,children:(0,V.jsx)(x.ZP,we(we({},l),{},{monospace:!0,rightAligned:!0,small:!0,children:n}))})})},useRootFolder:!0}):(0,V.jsx)(p.Z,{p:L.cd,children:(0,V.jsx)(x.ZP,{monospace:!0,muted:!0,children:"No files modified"})})}),[i,E,e,G,ke,n,v,Oe,Te]),Ae=(0,d.useMemo)((function(){return!he||!ge||f&&(null===ge||void 0===ge?void 0:ge.filename)!==f}),[he,ge,f]),Ne=(0,d.useMemo)((function(){if(!f)return null;var e=ge||{},n=e.content,r=e.content_from_base;return(0,V.jsxs)(pe,{children:[!i&&(0,V.jsx)(p.Z,{p:L.cd,children:(0,V.jsx)(x.ZP,{muted:!0,children:"Please select a base branch to see the file diffs."})}),(null===ge||void 0===ge?void 0:ge.error)&&(0,V.jsx)(p.Z,{p:L.cd,children:(0,V.jsx)(x.ZP,{danger:!0,monospace:!0,preWrap:!0,children:null===ge||void 0===ge?void 0:ge.error})}),i&&!(null!==ge&&void 0!==ge&&ge.error)&&(0,V.jsxs)(V.Fragment,{children:[Ae&&(0,V.jsx)(p.Z,{p:L.cd,children:(0,V.jsx)(j.Z,{inverted:!0})}),!Ae&&(0,V.jsx)(a(),{compareMethod:s.DiffMethod.WORDS,newValue:n||"",oldValue:r||"",renderContent:function(e){return(0,V.jsx)(x.ZP,{monospace:!0,children:e})},splitView:!0,styles:je,useDarkTheme:!0})]})]})}),[i,ge,Ae,f]),Re=(0,d.useMemo)((function(){return T&&null!==F&&void 0!==F&&F.name?H:H.slice(0,1)}),[F,T]),Me=(0,d.useMemo)((function(){return(0,V.jsxs)(V.Fragment,{children:[(0,V.jsx)("div",{style:{marginBottom:.5*L.iI,marginTop:.5*L.iI},children:(0,V.jsx)(U.Z,{compact:!0,onClickTab:function(e){var n=e.uuid;(0,Ze.u7)({tab:n})},selectedTabUUID:null===Z||void 0===Z?void 0:Z.uuid,tabs:Re})}),(0,V.jsx)(m.Z,{light:!0})]})}),[Z,Re]),De=(0,d.useMemo)((function(){return(0,V.jsx)(be,{actionRemoteName:J,branch:F,fetchBranch:function(){E(),z()},loading:!W,remotes:Q,setActionRemoteName:te,showError:t})}),[J,F,W,E,z,Q,te,t]),Be=(0,d.useMemo)((function(){return(0,V.jsx)(Y,{actionRemoteName:J,branch:F,branches:O,fetchBranch:E,fetchBranches:S,remotes:Q,setActionRemoteName:te,showError:t})}),[J,F,O,E,S,Q,te,t]),He=(0,d.useMemo)((function(){return(0,V.jsx)(se,{branch:F,fetchBranch:E,modifiedFiles:ke,setSelectedFilePath:v,showError:t,stagedFiles:Oe,untrackedFiles:Te})}),[F,E,ke,v,t,Oe,Te]),Le=(0,d.useMemo)((function(){return(0,V.jsx)($,{actionRemoteName:J,branch:F,branches:O,fetchBranch:E,loading:!W,modifiedFiles:ke,remotes:Q,repositories:ae,repositoryName:ie,setActionRemoteName:te,setRepositoryName:ue,showError:t,stagedFiles:Oe})}),[J,F,O,W,E,ke,Q,ae,ie,te,ue,t,Oe]);return(0,V.jsx)(ee.Z,{after:Ne,afterHidden:!f,afterWidth:40*L.iI,before:(0,V.jsxs)(V.Fragment,{children:[(0,V.jsx)(p.Z,{p:1,children:(0,V.jsx)(g.Z,{compact:!0,label:"Base branch",onChange:function(e){return l(e.target.value)},ref:n,small:!0,value:i||"",children:null===O||void 0===O?void 0:O.map((function(e){var n=e.name;return(0,V.jsx)("option",{value:n,children:n},n)}))})}),Ee]}),mainContainerHeader:Me,title:"Version control",uuid:"Version control/index",children:(0,V.jsxs)(p.Z,{p:L.cd,children:[!T&&(0,V.jsx)(j.Z,{inverted:!0}),T&&(0,V.jsxs)(V.Fragment,{children:[B.uuid===(null===Z||void 0===Z?void 0:Z.uuid)&&De,R.uuid===(null===Z||void 0===Z?void 0:Z.uuid)&&Be,M.uuid===(null===Z||void 0===Z?void 0:Z.uuid)&&He,D.uuid===(null===Z||void 0===Z?void 0:Z.uuid)&&Le]})]})})};function ke(){return(0,V.jsx)(Ce,{})}ke.getInitialProps=(0,t.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 Se=(0,l.Z)(ke)},75302:function(e,n,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/version-control",function(){return r(58024)}])}},function(e){e.O(0,[2678,1154,844,7011,6965,4267,600,8487,8264,7858,5499,4366,553,9774,2888,179],(function(){return n=75302,e(e.s=n);var n}));var n=e.O();_N_E=n}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1952],{52749:function(e,n,t){var i=t(82394),r=t(82684),o=t(71180),l=t(55485),d=t(93369),c=t(7267),u=t(38276),s=t(30160),a=t(35576),p=t(17488),f=t(72473),h=t(4015),v=t(70515),m=t(81728),j=t(28598);function g(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,i)}return t}function x(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,i.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}n.Z=function(e){var n,t,i,g,b=e.createPipeline,Z=e.isLoading,y=e.onClose,P=(0,r.useRef)(null),O=(0,r.useState)(!1),w=O[0],k=O[1],I=(0,r.useState)({name:(0,m.Y6)()}),C=I[0],_=I[1];return(0,r.useEffect)((function(){var e;null===P||void 0===P||null===(e=P.current)||void 0===e||e.focus()}),[]),(0,j.jsxs)(h.Nk,{children:[(0,j.jsx)(h.I5,{children:(0,j.jsx)(l.ZP,{alignItems:"center",justifyContent:"center",children:(0,j.jsx)(f.xq,{size:5*v.iI,warning:!0})})}),(0,j.jsx)(h.gI,{children:(0,j.jsxs)(u.Z,{py:1,children:[(0,j.jsx)(u.Z,{mb:1,children:(0,j.jsx)(s.ZP,{default:!0,children:"New pipeline"})}),(0,j.jsx)(s.ZP,{textOverflow:!0,children:"Using AI"})]})}),(0,j.jsxs)(h.gI,{children:[(0,j.jsx)(s.ZP,{default:!0,children:"Name"}),(0,j.jsx)(p.Z,{alignRight:!0,noBackground:!0,noBorder:!0,onChange:function(e){return _((function(n){return x(x({},n),{},{name:e.target.value})}))},paddingVertical:v.iI,placeholder:"Enter pipeline name...",value:(null===C||void 0===C?void 0:C.name)||""})]}),(0,j.jsx)(h.gI,{children:(0,j.jsxs)(l.ZP,{flexDirection:"column",fullWidth:!0,children:[(0,j.jsx)(u.Z,{mb:2,pt:1,children:(0,j.jsx)(s.ZP,{default:!0,children:"Describe what the pipeline should do"})}),(0,j.jsxs)(u.Z,{pb:1,pr:v.cd,children:[(0,j.jsx)(a.Z,{fullWidth:!0,onChange:function(e){return _((function(n){return x(x({},n),{},{llm:{request:{pipeline_description:e.target.value},use_case:c.z.GENERATE_PIPELINE_WITH_DESCRIPTION}})}))},placeholder:"Type the pipeline purpose...",ref:P,rows:8,value:(null===C||void 0===C||null===(n=C.llm)||void 0===n||null===(t=n.request)||void 0===t?void 0:t.pipeline_description)||""}),(Z||w)&&(0,j.jsx)(u.Z,{mt:1,children:(0,j.jsx)(s.ZP,{warning:!0,children:"Pipeline is being generated using AI based on your description above..."})})]})]})}),(0,j.jsx)(h.$b,{children:(0,j.jsxs)(l.ZP,{fullWidth:!0,children:[(0,j.jsx)(d.ZP,{bold:!0,centerText:!0,disabled:!(null!==C&&void 0!==C&&C.name)||!(null!==C&&void 0!==C&&null!==(i=C.llm)&&void 0!==i&&null!==(g=i.request)&&void 0!==g&&g.pipeline_description),loading:Z||w,onClick:function(){k(!0),b({pipeline:C}).then((function(){return k(!1)}))},primary:!0,tabIndex:0,uuid:"AIControlPanel/CreatePipeline",children:"Create pipeline"}),y&&(0,j.jsx)(u.Z,{ml:1,children:(0,j.jsx)(o.ZP,{onClick:y,tabIndex:0,children:"Cancel"})})]})})]})}},60523:function(e,n,t){var i=t(21831),r=t(82394),o=t(82684),l=t(38626),d=t(34376),c=t(54750),u=t(71180),s=t(90299),a=t(44898),p=t(55485),f=t(88328),h=t(38276),v=t(4190),m=t(48381),j=t(5755),g=t(30160),x=t(35686),b=t(72473),Z=t(84649),y=t(32929),P=t(15610),O=t(19183),w=t(28598);function k(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,i)}return t}function I(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?k(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):k(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}n.Z=function(e){var n,t=e.contained,r=e.defaultLinkUUID,k=e.defaultTab,C=e.objectType,_=e.onClickCustomTemplate,S=e.pipelineUUID,M=e.showAddingNewTemplates,N=e.showBreadcrumbs,A=e.tabs,E=(0,d.useRouter)(),D=(0,o.useContext)(l.ThemeContext),T=(0,O.i)(),B=T.height,R=T.width,U=(0,o.useMemo)((function(){return A||y.dP}),[A]),H=(0,o.useState)(M||!1),z=H[0],q=H[1],L=(0,o.useState)(r?y.qy.find((function(e){return e.uuid===r})):y.qy[0]),F=L[0],W=L[1],G=(0,o.useState)(k?U.find((function(e){return e.uuid===(null===k||void 0===k?void 0:k.uuid)})):U[0]),V=G[0],Y=G[1],X=(0,o.useState)(null),$=X[0],Q=X[1],J=x.ZP.custom_templates.list({object_type:a.Z},{},{pauseFetch:y.n9.uuid!==(null===V||void 0===V?void 0:V.uuid)}),K=J.data,ee=J.mutate,ne=(0,o.useMemo)((function(){var e=(null===K||void 0===K?void 0:K.custom_templates)||[];return null!==F&&void 0!==F&&F.filterTemplates?null===F||void 0===F?void 0:F.filterTemplates(e):e}),[K,F]),te=x.ZP.custom_templates.list({object_type:a.R},{},{pauseFetch:y.A2.uuid!==(null===V||void 0===V?void 0:V.uuid)}),ie=te.data,re=te.mutate,oe=(0,o.useMemo)((function(){var e=(null===ie||void 0===ie?void 0:ie.custom_templates)||[];return null!==F&&void 0!==F&&F.filterTemplates?null===F||void 0===F?void 0:F.filterTemplates(e):e}),[ie,F]),le=(0,o.useMemo)((function(){return y.qy.map((function(e){var n=e.Icon,t=e.label,i=e.selectedBackgroundColor,r=e.selectedIconProps,o=e.uuid,l=(null===F||void 0===F?void 0:F.uuid)===o,d=I({size:Z.ZG},l&&r?r:{});return(0,w.jsx)(Z.wj,{onClick:function(){return W(e)},selected:l,children:(0,w.jsxs)(p.ZP,{alignItems:"center",children:[(0,w.jsx)(Z.ze,{backgroundColor:l&&i?i(D):null,children:n?(0,w.jsx)(n,I({},d)):(0,w.jsx)(b.pd,I({},d))}),(0,w.jsx)(g.ZP,{bold:!0,large:!0,children:t?t():o})]})},o)}))}),[F,D]),de=(0,o.useMemo)((function(){return y.hS.map((function(e){var n=e.Icon,t=e.label,i=e.selectedBackgroundColor,r=e.selectedIconProps,o=e.uuid,l=(null===F||void 0===F?void 0:F.uuid)===o,d=I({size:Z.ZG},l&&r?r:{});return(0,w.jsx)(Z.wj,{onClick:function(){return W(e)},selected:l,children:(0,w.jsxs)(p.ZP,{alignItems:"center",children:[(0,w.jsx)(Z.ze,{backgroundColor:l&&i?i(D):null,children:n?(0,w.jsx)(n,I({},d)):(0,w.jsx)(b.pd,I({},d))}),(0,w.jsx)(g.ZP,{bold:!0,large:!0,children:t?t():o})]})},o)}))}),[F,D]),ce=(0,o.useMemo)((function(){return null===ne||void 0===ne?void 0:ne.map((function(e){var n=e.description,t=e.name,r=e.tags,o=e.template_uuid,l=e.user,d=[];return null!==r&&void 0!==r&&r.length?d.push.apply(d,(0,i.Z)(r)):null!==l&&void 0!==l&&l.username&&d.push(null===l||void 0===l?void 0:l.username),(0,w.jsxs)(Z.UE,{onClick:function(){_?_(e):E.push("/templates/[...slug]","/templates/".concat(encodeURIComponent(o)))},children:[(0,w.jsx)(Z.Tj,{children:(0,w.jsx)(g.ZP,{bold:!0,monospace:!0,textOverflow:!0,children:t||o})}),(0,w.jsx)(Z.SL,{children:(0,w.jsx)(g.ZP,{default:!!n,italic:!n,muted:!n,textOverflowLines:2,children:n||"No description"})}),(0,w.jsx)(Z.EN,{children:(null===d||void 0===d?void 0:d.length)>=1&&(0,w.jsx)(m.Z,{tags:null===d||void 0===d?void 0:d.map((function(e){return{uuid:e}}))})})]},o)}))}),[ne,_,E]),ue=(0,o.useMemo)((function(){return null===oe||void 0===oe?void 0:oe.map((function(e){var n=e.description,t=e.name,r=e.tags,o=e.template_uuid,l=e.user,d=[];return null!==r&&void 0!==r&&r.length?d.push.apply(d,(0,i.Z)(r)):null!==l&&void 0!==l&&l.username&&d.push(null===l||void 0===l?void 0:l.username),(0,w.jsxs)(Z.UE,{onClick:function(){_?_(e):E.push("/templates/[...slug]","/templates/".concat(encodeURIComponent(o),"?object_type=").concat(a.R))},children:[(0,w.jsx)(Z.Tj,{children:(0,w.jsx)(g.ZP,{bold:!0,monospace:!0,textOverflow:!0,children:t||o})}),(0,w.jsx)(Z.SL,{children:(0,w.jsx)(g.ZP,{default:!!n,italic:!n,muted:!n,textOverflowLines:2,children:n||"No description"})}),(0,w.jsx)(Z.EN,{children:(null===d||void 0===d?void 0:d.length)>=1&&(0,w.jsx)(m.Z,{tags:null===d||void 0===d?void 0:d.map((function(e){return{uuid:e}}))})})]},o)}))}),[oe,_,E]),se=(0,o.useMemo)((function(){if(!N)return null;var e=[];return z?e.push.apply(e,[{label:function(){return"Templates"},onClick:function(){q(!1)}},{bold:!0,label:function(){return"New custom template"}}]):e.push({label:function(){return"Templates"}}),(0,w.jsx)(Z.FX,{children:(0,w.jsx)(c.Z,{breadcrumbs:e})})}),[z,N]),ae=(0,o.useMemo)((function(){return N?36:0}),[N]),pe=(0,o.useMemo)((function(){return B-ae}),[B,ae]);if(z)return n=a.R===C&&S?(0,w.jsx)(f.Z,{onMutateSuccess:re,pipelineUUID:S,templateAttributes:F&&(null===F||void 0===F?void 0:F.uuid)!==(null===y.qy||void 0===y.qy?void 0:y.qy[0].uuid)?{pipeline_type:null===F||void 0===F?void 0:F.uuid}:null,templateUUID:null===$||void 0===$?void 0:$.template_uuid}):(0,w.jsx)(j.Z,{contained:t,heightOffset:ae,onCreateCustomTemplate:t?function(e){Q(e)}:null,onMutateSuccess:ee,templateAttributes:F&&(null===F||void 0===F?void 0:F.uuid)!==(null===y.qy||void 0===y.qy?void 0:y.qy[0].uuid)?{block_type:null===F||void 0===F?void 0:F.uuid}:null,templateUUID:null===$||void 0===$?void 0:$.template_uuid}),t?(0,w.jsxs)(w.Fragment,{children:[N&&se,(0,w.jsx)(Z.Rd,{height:pe,width:R,children:n})]}):n;var fe=(0,w.jsxs)(Z.Nk,{children:[(0,w.jsxs)(Z.bC,{height:t?pe:null,children:[(0,w.jsx)(Z.Yf,{children:(0,w.jsx)(s.Z,{noPadding:!0,onClickTab:function(e){t?Y(e):(0,P.u7)({object_type:y.A2.uuid===e.uuid?a.R:a.Z})},selectedTabUUID:null===V||void 0===V?void 0:V.uuid,tabs:U})}),(0,w.jsxs)(Z.wl,{contained:t,heightOffset:ae,children:[y.n9.uuid===(null===V||void 0===V?void 0:V.uuid)&&le,y.A2.uuid===(null===V||void 0===V?void 0:V.uuid)&&de]})]}),(0,w.jsxs)(Z.w5,{children:[y.n9.uuid===(null===V||void 0===V?void 0:V.uuid)&&(0,w.jsx)(Z.HS,{children:(0,w.jsx)(u.ZP,{beforeIcon:(0,w.jsx)(b.mm,{size:Z.ZG}),onClick:function(){q(!0)},primary:!0,children:"New block template"})}),y.n9.uuid===(null===V||void 0===V?void 0:V.uuid)&&(0,w.jsxs)(w.Fragment,{children:[!K&&(0,w.jsx)(h.Z,{p:2,children:(0,w.jsx)(v.Z,{inverted:!0})}),K&&!(null!==ce&&void 0!==ce&&ce.length)&&(0,w.jsxs)(h.Z,{p:2,children:[(0,w.jsx)(g.ZP,{children:"There are currently no templates matching your search."}),(0,w.jsx)("br",{}),(0,w.jsx)(g.ZP,{children:"Add a new template by clicking the button above."})]}),(null===ce||void 0===ce?void 0:ce.length)>=1&&(0,w.jsx)(Z.n8,{children:ce})]}),y.A2.uuid===(null===V||void 0===V?void 0:V.uuid)&&(0,w.jsxs)(w.Fragment,{children:[!ie&&(0,w.jsx)(h.Z,{p:2,children:(0,w.jsx)(v.Z,{inverted:!0})}),ie&&!(null!==ue&&void 0!==ue&&ue.length)&&(0,w.jsxs)(h.Z,{p:2,children:[(0,w.jsx)(g.ZP,{children:"There are currently no templates matching your search."}),(0,w.jsx)("br",{}),(0,w.jsx)(g.ZP,{children:'Add a new template by right-clicking a pipeline row from the Pipelines page and selecting "Create template".'})]}),(null===ue||void 0===ue?void 0:ue.length)>=1&&(0,w.jsx)(Z.n8,{children:ue})]})]})]});return t?(0,w.jsxs)(w.Fragment,{children:[N&&se,(0,w.jsx)(Z.Rd,{height:pe,width:R,children:fe})]}):fe}},94629:function(e,n,t){t.d(n,{Z:function(){return k}});var i=t(82394),r=t(21831),o=t(82684),l=t(50724),d=t(82555),c=t(97618),u=t(70613),s=t(68487),a=t(68899),p=t(28598);function f(e,n){var t=e.children,i=e.noPadding;return(0,p.jsx)(a.HS,{noPadding:i,ref:n,children:t})}var h=o.forwardRef(f),v=t(62547),m=t(82571),j=t(35686),g=t(98464),x=t(46684),b=t(70515),Z=t(53808),y=t(19183);function P(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,i)}return t}function O(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?P(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):P(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function w(e,n){var t,i=e.addProjectBreadcrumbToCustomBreadcrumbs,f=e.after,P=e.afterHeader,w=e.afterHidden,k=e.afterWidth,I=e.afterWidthOverride,C=e.appendBreadcrumbs,_=e.before,S=e.beforeWidth,M=e.breadcrumbs,N=e.children,A=e.errors,E=e.headerMenuItems,D=e.headerOffset,T=e.hideAfterCompletely,B=e.mainContainerHeader,R=e.navigationItems,U=e.setAfterHidden,H=e.setErrors,z=e.subheaderChildren,q=e.subheaderNoPadding,L=e.title,F=e.uuid,W=(0,y.i)().width,G="dashboard_after_width_".concat(F),V="dashboard_before_width_".concat(F),Y=(0,o.useRef)(null),X=(0,o.useState)(I?k:(0,Z.U2)(G,k)),$=X[0],Q=X[1],J=(0,o.useState)(!1),K=J[0],ee=J[1],ne=(0,o.useState)(_?Math.max((0,Z.U2)(V,S),13*b.iI):null),te=ne[0],ie=ne[1],re=(0,o.useState)(!1),oe=re[0],le=re[1],de=(0,o.useState)(null)[1],ce=j.ZP.projects.list({},{revalidateOnFocus:!1}).data,ue=null===ce||void 0===ce?void 0:ce.projects,se={label:function(){var e;return null===ue||void 0===ue||null===(e=ue[0])||void 0===e?void 0:e.name},linkProps:{href:"/"}},ae=[];M&&(i&&ae.push(se),ae.push.apply(ae,(0,r.Z)(M))),(null===M||void 0===M||!M.length||C)&&(null===ue||void 0===ue?void 0:ue.length)>=1&&(null!==M&&void 0!==M&&M.length||ae.unshift({bold:!C,label:function(){return L}}),ae.unshift(se)),(0,o.useEffect)((function(){null===Y||void 0===Y||!Y.current||K||oe||null===de||void 0===de||de(Y.current.getBoundingClientRect().width)}),[K,$,oe,te,Y,de,W]),(0,o.useEffect)((function(){K||(0,Z.t8)(G,$)}),[w,K,$,G]),(0,o.useEffect)((function(){oe||(0,Z.t8)(V,te)}),[oe,te,V]);var pe=(0,g.Z)(k);return(0,o.useEffect)((function(){I&&pe!==k&&Q(k)}),[I,k,pe]),(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)(u.Z,{title:L}),(0,p.jsx)(s.Z,{breadcrumbs:ae,menuItems:E,project:null===ue||void 0===ue?void 0:ue[0],version:null===ue||void 0===ue||null===(t=ue[0])||void 0===t?void 0:t.version}),(0,p.jsxs)(a.Nk,{ref:n,children:[0!==(null===R||void 0===R?void 0:R.length)&&(0,p.jsx)(a.lm,{showMore:!0,children:(0,p.jsx)(m.Z,{navigationItems:R,showMore:!0})}),(0,p.jsx)(c.Z,{flex:1,flexDirection:"column",children:(0,p.jsxs)(v.Z,{after:f,afterHeader:P,afterHeightOffset:x.Mz,afterHidden:w,afterMousedownActive:K,afterWidth:$,before:_,beforeHeightOffset:x.Mz,beforeMousedownActive:oe,beforeWidth:a.k1+(_?te:0),headerOffset:D,hideAfterCompletely:!U||T,leftOffset:_?a.k1:null,mainContainerHeader:B,mainContainerRef:Y,setAfterHidden:U,setAfterMousedownActive:ee,setAfterWidth:Q,setBeforeMousedownActive:le,setBeforeWidth:ie,children:[z&&(0,p.jsx)(h,{noPadding:q,children:z}),N]})})]}),A&&(0,p.jsx)(l.Z,{disableClickOutside:!0,isOpen:!0,onClickOutside:function(){return null===H||void 0===H?void 0:H(null)},children:(0,p.jsx)(d.Z,O(O({},A),{},{onClose:function(){return null===H||void 0===H?void 0:H(null)}}))})]})}var k=o.forwardRef(w)},65458:function(e,n,t){t.d(n,{d:function(){return s}});var i=t(13507),r=t(72473),o=t(57653),l=t(70515),d=t(81728),c=t(28598),u=1.5*l.iI,s=function(e,n){var t=[{beforeIcon:(0,c.jsx)(r.X5,{}),label:function(){return"Standard (batch)"},onClick:function(){return e({pipeline:{name:(0,d.Y6)()}})},uuid:"Pipelines/NewPipelineMenu/standard"},{beforeIcon:(0,c.jsx)(r.ZG,{}),label:function(){return"Data integration"},onClick:function(){return e({pipeline:{name:(0,d.Y6)(),type:o.qL.INTEGRATION}})},uuid:"Pipelines/NewPipelineMenu/integration"},{beforeIcon:(0,c.jsx)(i.Z,{size:u}),label:function(){return"Streaming"},onClick:function(){return e({pipeline:{name:(0,d.Y6)(),type:o.qL.STREAMING}})},uuid:"Pipelines/NewPipelineMenu/streaming"}];return null!==n&&void 0!==n&&n.showBrowseTemplates&&t.push({beforeIcon:(0,c.jsx)(r.zQ,{}),label:function(){return"From a template"},onClick:function(){var e;return null===n||void 0===n||null===(e=n.showBrowseTemplates)||void 0===e?void 0:e.call(n)},uuid:"Pipelines/NewPipelineMenu/custom_template"}),null!==n&&void 0!==n&&n.showAIModal&&t.push({beforeIcon:(0,c.jsx)(r.xq,{}),label:function(){return"Using AI (beta)"},onClick:function(){var e;return null===n||void 0===n||null===(e=n.showAIModal)||void 0===e?void 0:e.call(n)},uuid:"Pipelines/NewPipelineMenu/AI_modal"}),t}},4015:function(e,n,t){t.d(n,{$b:function(){return s},I5:function(){return c},Nk:function(){return d},gI:function(){return u}});var i=t(38626),r=t(44897),o=t(42631),l=t(70515),d=i.default.div.withConfig({displayName:"indexstyle__ContainerStyle",componentId:"sc-h093u4-0"})([""," ",""],(function(e){return!e.width&&"\n width: ".concat(40*l.iI,"px;\n ")}),(function(e){return e.width&&"\n width: ".concat(e.width,"px;\n ")})),c=i.default.div.withConfig({displayName:"indexstyle__HeaderStyle",componentId:"sc-h093u4-1"})(["padding:","px;",""],2.5*l.iI,(function(e){return"\n background-color: ".concat((e.theme.background||r.Z.background).dashboard,";\n border-left: 1px solid ").concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n border-right: 1px solid ").concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n border-top-left-radius: ").concat(o.n_,"px;\n border-top-right-radius: ").concat(o.n_,"px;\n border-top: 1px solid ").concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n ")})),u=i.default.div.withConfig({displayName:"indexstyle__RowStyle",componentId:"sc-h093u4-2"})(["align-items:center;justify-content:space-between;",""],(function(e){return"\n background-color: ".concat((e.theme.background||r.Z.background).dashboard,";\n border-left: 1px solid ").concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n border-right: 1px solid ").concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n border-top: 1px solid ").concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n display: ").concat((null===e||void 0===e?void 0:e.display)||"flex",";\n padding-bottom: ").concat(1*l.iI+((null===e||void 0===e?void 0:e.paddingVerticalAddition)||0),"px;\n padding-left: ").concat(l.cd*l.iI,"px;\n padding-top: ").concat(1*l.iI+((null===e||void 0===e?void 0:e.paddingVerticalAddition)||0),"px;\n ")})),s=i.default.div.withConfig({displayName:"indexstyle__FooterStyle",componentId:"sc-h093u4-3"})(["padding:","px ","px;",""],2.5*l.iI,2*l.iI,(function(e){return"\n background-color: ".concat((e.theme.background||r.Z.background).panel,";\n border-bottom-left-radius: ").concat(o.n_,"px;\n border-bottom-right-radius: ").concat(o.n_,"px;\n border-bottom: 1px solid ").concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n border-left: 1px solid ").concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n border-right: 1px solid ").concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n ")}))},48381:function(e,n,t){var i=t(82684),r=t(31882),o=t(55485),l=t(30160),d=t(86735),c=t(28598);n.Z=function(e){var n=e.onClickTag,t=e.tags,u=void 0===t?[]:t,s=(0,i.useMemo)((function(){return(null===u||void 0===u?void 0:u.length)||0}),[u]),a=(0,i.useMemo)((function(){return(0,d.YC)(u||[],"uuid")}),[u]);return(0,c.jsx)(o.ZP,{alignItems:"center",flexWrap:"wrap",children:null===a||void 0===a?void 0:a.reduce((function(e,t){return e.push((0,c.jsx)("div",{style:{marginBottom:2,marginRight:s>=2?4:0,marginTop:2},children:(0,c.jsx)(r.Z,{onClick:n?function(){return n(t)}:null,small:!0,children:(0,c.jsx)(l.ZP,{children:t.uuid})})},"tag-".concat(t.uuid))),e}),[])})}},55729:function(e,n,t){t.d(n,{Z:function(){return T}});var i=t(82394),r=t(75582),o=t(82684),l=t(69864),d=t(71180),c=t(15338),u=t(97618),s=t(55485),a=t(85854),p=t(48670),f=t(65956),h=t(82359),v=t(57114),m=t(38276),j=t(30160),g=t(17488),x=t(69650),b=t(12468),Z=t(35686),y=t(38626),P=t(44897),O=t(42631),w=t(70515),k=y.default.div.withConfig({displayName:"indexstyle__ContainerStyle",componentId:"sc-1b0w59t-0"})(["border-radius:","px;padding:","px;",""],O.n_,w.cd*w.iI,(function(e){return"\n background-color: ".concat((e.theme.background||P.Z.background).codeArea,";\n ")})),I=t(72473),C=t(72191),_=t(81728),S=t(72619),M=t(70320),N=t(23780),A=t(28598);function E(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,i)}return t}function D(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,i.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 T=function(e){var n,t,y,P=e.cancelButtonText,O=e.contained,E=e.header,T=e.onCancel,B=e.onSaveSuccess,R=(0,N.VI)(null,{},[],{uuid:"settings/workspace/preferences"}),U=(0,r.Z)(R,1)[0],H=(0,o.useState)(null),z=H[0],q=H[1],L=(0,o.useState)(!1),F=L[0],W=L[1],G=Z.ZP.projects.list(),V=G.data,Y=G.mutate,X=(0,o.useMemo)((function(){var e;return null===V||void 0===V||null===(e=V.projects)||void 0===e?void 0:e[0]}),[V]),$=X||{},Q=$.name,J=$.openai_api_key,K=$.project_uuid,ee=(0,o.useMemo)((function(){return"demo.mage.ai"===window.location.hostname}),[]);(0,o.useEffect)((function(){z||q(X)}),[X,z]);var ne=(0,l.Db)(Z.ZP.projects.useUpdate(Q),{onSuccess:function(e){return(0,S.wD)(e,{callback:function(e){var n,t=e.project;Y(),q(t),W(!1),(0,M.h)(null===t||void 0===t||null===(n=t.features)||void 0===n?void 0:n[h.d.LOCAL_TIMEZONE]),B&&(null===B||void 0===B||B(t))},onErrorCallback:function(e,n){return U({errors:n,response:e})}})}}),te=(0,r.Z)(ne,2),ie=te[0],re=te[1].isLoading,oe=(0,o.useCallback)((function(e){return ie({project:e})}),[ie]),le=(0,A.jsxs)(A.Fragment,{children:[E,(0,A.jsxs)(f.Z,{noPadding:!0,children:[(0,A.jsxs)(m.Z,{p:w.cd,children:[(0,A.jsx)(m.Z,{mb:1,children:(0,A.jsx)(a.Z,{level:5,children:"Project name"})}),(0,A.jsx)(j.ZP,{default:!0,monospace:!0,children:Q})]}),(0,A.jsx)(c.Z,{light:!0}),(0,A.jsxs)(m.Z,{p:w.cd,children:[(0,A.jsx)(m.Z,{mb:1,children:(0,A.jsx)(a.Z,{level:5,children:"Project UUID"})}),(0,A.jsx)(j.ZP,{default:!!K,monospace:!0,muted:!K,children:K||"Not required"})]}),(0,A.jsx)(c.Z,{light:!0}),(0,A.jsx)(m.Z,{p:w.cd,children:(0,A.jsxs)(s.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,A.jsxs)(u.Z,{flexDirection:"column",children:[(0,A.jsx)(m.Z,{mb:1,children:(0,A.jsx)(a.Z,{level:5,children:"Help improve Mage"})}),(0,A.jsxs)(j.ZP,{default:!0,children:["Please contribute usage statistics to help improve the developer experience for you and everyone in the community. Learn more ",(0,A.jsx)(p.Z,{href:"https://docs.mage.ai/contributing/statistics/overview",openNewWindow:!0,children:"here"}),"."]})]}),(0,A.jsx)(m.Z,{mr:w.cd}),(0,A.jsx)(x.Z,{compact:!0,checked:null===z||void 0===z?void 0:z.help_improve_mage,onCheck:function(){return q((function(e){return D(D({},e),{},{help_improve_mage:!(null!==z&&void 0!==z&&z.help_improve_mage)})}))}})]})})]}),(0,A.jsx)(m.Z,{mt:w.HN}),(0,A.jsx)(v.Z,{description:"Global settings that are applied to all pipelines in this project.",title:"Pipeline settings",children:(0,A.jsx)(v.S,{description:"Every time a trigger is created or updated in this pipeline, automatically persist it in code.",title:"Save triggers in code automatically",toggleSwitch:{checked:!(null===z||void 0===z||null===(n=z.pipelines)||void 0===n||null===(t=n.settings)||void 0===t||null===(y=t.triggers)||void 0===y||!y.save_in_code_automatically),onCheck:function(e){return q((function(n){var t,i,r,o,l,d;return D(D({},n),{},{pipelines:D(D({},null===n||void 0===n?void 0:n.pipelines),{},{settings:D(D({},null===n||void 0===n||null===(t=n.pipelines)||void 0===t?void 0:t.settings),{},{triggers:D(D({},null===n||void 0===n||null===(i=n.pipelines)||void 0===i||null===(r=i.settings)||void 0===r?void 0:r.triggers),{},{save_in_code_automatically:e(null===n||void 0===n||null===(o=n.pipelines)||void 0===o||null===(l=o.settings)||void 0===l||null===(d=l.triggers)||void 0===d?void 0:d.save_in_code_automatically)})})})})}))}}})}),(0,A.jsx)(m.Z,{mt:w.HN}),(0,A.jsx)(f.Z,{noPadding:!0,overflowVisible:!0,children:(0,A.jsxs)(m.Z,{p:w.cd,children:[(0,A.jsx)(m.Z,{mb:1,children:(0,A.jsx)(a.Z,{level:5,children:"Features"})}),Object.entries((null===z||void 0===z?void 0:z.features)||{}).map((function(e,n){var t=(0,r.Z)(e,2),o=t[0],l=t[1];return(0,A.jsx)(m.Z,{mt:0===n?0:1,children:(0,A.jsxs)(s.ZP,{alignItems:"center",children:[(0,A.jsx)(x.Z,{checked:!!l,compact:!0,onCheck:function(){return q((function(e){return D(D({},e),{},{features:D(D({},null===z||void 0===z?void 0:z.features),{},(0,i.Z)({},o,!l))})}))}}),(0,A.jsx)(m.Z,{mr:w.cd}),(0,A.jsxs)(u.Z,{children:[(0,A.jsx)(j.ZP,{default:!l,monospace:!0,children:(0,_.vg)(o)}),o===h.d.LOCAL_TIMEZONE&&(0,A.jsx)(m.Z,{ml:1,children:(0,A.jsx)(b.Z,{block:!0,description:"Display dates in local timezone. Please note that certain pages (e.g. Monitor page) or components (e.g. Pipeline run bar charts) may still be in UTC time. Dates in local time will have a timezone offset in the timestamp (e.g. -07:00).",lightBackground:!0,muted:!0,size:C._k})})]})]})},o)}))]})}),(0,A.jsx)(m.Z,{mt:w.HN}),(0,A.jsx)(f.Z,{noPadding:!0,children:(0,A.jsxs)(m.Z,{p:w.cd,children:[(0,A.jsx)(m.Z,{mb:1,children:(0,A.jsx)(a.Z,{level:5,children:"OpenAI"})}),J&&!F?(0,A.jsxs)(s.ZP,D(D({},s.A0),{},{children:[(0,A.jsx)(j.ZP,{default:!0,monospace:!0,children:"API key: ********"}),(0,A.jsx)(d.ZP,{iconOnly:!0,onClick:function(){return W(!0)},secondary:!0,title:"Edit",children:(0,A.jsx)(I.I8,{size:C.bL})})]})):(0,A.jsx)(g.Z,{disabled:ee,label:ee?"Entering API key is disabled on demo":"API key",monospace:!0,onChange:function(e){return q((function(n){return D(D({},n),{},{openai_api_key:e.target.value})}))},primary:!0,setContentOnMount:!0,value:(null===z||void 0===z?void 0:z.openai_api_key)||""})]})}),(0,A.jsx)(m.Z,{mt:w.HN}),(0,A.jsxs)(s.ZP,{alignItems:"center",children:[(0,A.jsx)(d.ZP,{loading:re,onClick:function(){oe({features:null===z||void 0===z?void 0:z.features,help_improve_mage:null===z||void 0===z?void 0:z.help_improve_mage,openai_api_key:null===z||void 0===z?void 0:z.openai_api_key,pipelines:null===z||void 0===z?void 0:z.pipelines})},primary:!0,children:"Save project settings"}),T&&(0,A.jsxs)(A.Fragment,{children:[(0,A.jsx)(m.Z,{mr:w.cd}),(0,A.jsx)(d.ZP,{onClick:T,secondary:!0,children:P||"Cancel"})]})]})]});return O?(0,A.jsx)(k,{children:le}):le}},57114:function(e,n,t){t.d(n,{S:function(){return Z},Z:function(){return y}});var i=t(82684),r=t(15338),o=t(97618),l=t(55485),d=t(85854),c=t(65956),u=t(82394),s=t(44085),a=t(38276),p=t(30160),f=t(17488),h=t(69650),v=t(72473),m=t(8193),j=t(70515),g=t(28598);function x(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,i)}return t}function b(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,u.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 Z=function(e){var n,t=e.children,i=e.description,r=e.invalid,d=e.selectInput,c=e.textInput,u=e.title,x=e.toggleSwitch,Z=e.warning;return(0,g.jsx)(a.Z,{p:j.cd,children:(0,g.jsxs)(l.ZP,{alignItems:"center",children:[(0,g.jsxs)(l.ZP,{flexDirection:"column",children:[(0,g.jsxs)(p.ZP,{danger:r,default:!0,large:!0,warning:Z,children:[u," ",r&&(0,g.jsx)(p.ZP,{danger:!0,inline:!0,large:!0,children:"is required"})]}),i&&"string"===typeof i&&(0,g.jsx)(p.ZP,{muted:!0,small:!0,children:i}),i&&"string"!==typeof i&&i]}),(0,g.jsx)(a.Z,{mr:j.cd}),(0,g.jsxs)(o.Z,{flex:1,justifyContent:"flex-end",children:[t,c&&(0,g.jsx)(f.Z,b({afterIcon:(0,g.jsx)(v.I8,{}),afterIconClick:function(e,n){var t;null===n||void 0===n||null===(t=n.current)||void 0===t||t.focus()},afterIconSize:m.Z,alignRight:!0,autoComplete:"off",large:!0,noBackground:!0,noBorder:!0,fullWidth:!0,paddingHorizontal:0,paddingVertical:0,setContentOnMount:!0},c)),d&&(0,g.jsx)(s.Z,b(b({},d),{},{afterIcon:(0,g.jsx)(v._M,{}),afterIconSize:m.Z,alignRight:!0,autoComplete:"off",large:!0,noBackground:!0,noBorder:!0,paddingHorizontal:0,paddingVertical:0,setContentOnMount:!0,children:null===d||void 0===d||null===(n=d.options)||void 0===n?void 0:n.map((function(e){var n=e.label,t=e.value;return(0,g.jsx)("option",{value:t,children:n||t},t)}))})),x&&(0,g.jsx)(h.Z,{checked:!(null===x||void 0===x||!x.checked),compact:!0,onCheck:null===x||void 0===x?void 0:x.onCheck})]})]})})},y=function(e){var n=e.children,t=e.description,u=e.headerChildren,s=e.title;return(0,g.jsxs)(c.Z,{noPadding:!0,children:[(0,g.jsx)(a.Z,{p:j.cd,children:(0,g.jsxs)(l.ZP,{alignItems:"center",children:[(0,g.jsxs)(o.Z,{flex:1,flexDirection:"column",children:[(0,g.jsx)(d.Z,{level:4,children:s}),t&&"string"===typeof t&&(0,g.jsx)(a.Z,{mt:1,children:(0,g.jsx)(p.ZP,{muted:!0,children:t})}),t&&"string"!==typeof t&&t]}),u]})}),i.Children.map(n,(function(e,n){return(0,g.jsxs)("div",{children:[(0,g.jsx)(r.Z,{light:!0}),e]},"".concat(s,"-").concat(n))}))]})}},8193:function(e,n,t){t.d(n,{N:function(){return c},Z:function(){return d}});var i=t(38626),r=t(44897),o=t(42631),l=t(70515),d=2*l.iI,c=i.default.div.withConfig({displayName:"indexstyle__ContainerStyle",componentId:"sc-1ck7mzt-0"})(["border-radius:","px;padding:","px;",""],o.n_,l.cd*l.iI,(function(e){return"\n background-color: ".concat((e.theme.background||r.Z.background).codeArea,";\n ")}))}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3419],{23192:function(n,e,t){t.d(e,{fi:function(){return B},lG:function(){return Y}});var o=t(82394),r=t(75582),i=t(82684),u=t(12691),c=t.n(u),l=t(34376),a=t.n(l),d=t(38626),s=t(69864),p=t(40761),f=t(41143),v=t(71180),b=t(39867),h=t(55485),m=t(48670),j=t(57653),g=t(38276),O=t(75499),x=t(30160),y=t(12468),P=t(35686),Z=t(89706),k=t(11498),_=t(72473),S=t(81655),C=t(70515),w=t(3917),L=t(55283),T=t(86735),D=t(72619),R=t(74052),M=t(69419),I=t(70320),E=t(28598);function N(n,e){var t=Object.keys(n);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(n);e&&(o=o.filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),t.push.apply(t,o)}return t}function A(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{};e%2?N(Object(t),!0).forEach((function(e){(0,o.Z)(n,e,t[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(t)):N(Object(t)).forEach((function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(t,e))}))}return n}var Y=[0,1,3,4,5],B={0:"status",1:"block_uuid",3:"created_at",4:"started_at",5:"completed_at"};e.ZP=function(n){var e=n.blockRuns,t=n.onClickRow,o=n.pipeline,u=n.selectedRun,l=n.setErrors,N=n.sortableColumnIndexes,Y=(0,I.q)(),B=(0,i.useContext)(d.ThemeContext),F=(0,i.useState)(null),U=F[0],X=F[1],H=(0,i.useState)(null),Q=H[0],G=H[1],z=o||{},J=z.uuid,K=z.type,q=(0,i.useMemo)((function(){return o.blocks||[]}),[o]),V=(0,i.useMemo)((function(){return(0,T.HK)(q,(function(n){return n.uuid}))}),[q]),$=(0,i.useMemo)((function(){return j.qL.INTEGRATION===K}),[K]),W=(0,i.useMemo)((function(){return j.qL.PYTHON===K}),[K]),nn=(0,M.iV)(),en=null===nn||void 0===nn?void 0:nn[S.lG.SORT_COL_IDX],tn=(0,i.useMemo)((function(){return en?{columnIndex:+en,sortDirection:(null===nn||void 0===nn?void 0:nn[S.lG.SORT_DIRECTION])||S.sh.ASC}:void 0}),[nn,en]),on=(0,i.useMemo)((function(){var n,e;return null===(n=new p.Z)||void 0===n||null===(e=n.decodedToken)||void 0===e?void 0:e.token}),[]),rn=(0,s.Db)((function(n){var e=n.blockUUID,t=n.pipelineRunId;return P.ZP.block_outputs.pipelines.downloads.detailAsync(null===o||void 0===o?void 0:o.uuid,e,{pipeline_run_id:t,token:on},{onDownloadProgress:function(n){return X((Number((null===n||void 0===n?void 0:n.loaded)||0)/1e6).toFixed(3))},responseType:k.E.BLOB})}),{onSuccess:function(n){return(0,D.wD)(n,{callback:function(n){G(null),(0,R.uS)(n,"block_output.".concat(Z.Lu.CSV))},onErrorCallback:function(n,e){return null===l||void 0===l?void 0:l({errors:e,response:n})}})}}),un=(0,r.Z)(rn,2),cn=un[0],ln=un[1].isLoading,an=Y?S.O$:{},dn=[{uuid:"Status"},{uuid:"Block"},{uuid:"Trigger"},A(A({},an),{},{uuid:"Created at"}),A(A({},an),{},{uuid:"Started at"}),A(A({},an),{},{uuid:"Completed at"}),{uuid:"Logs"}];return W&&dn.push({uuid:"Output"}),(0,E.jsx)(O.Z,{columnFlex:[1,2,2,1,1,1,null,null],columns:dn,isSelectedRow:function(n){return e[n].id===(null===u||void 0===u?void 0:u.id)},onClickRow:t,rows:null===e||void 0===e?void 0:e.map((function(n){var e,t,o,r,u=n||{},l=u.block_uuid,d=u.completed_at,s=u.created_at,p=u.id,j=u.pipeline_run_id,O=u.pipeline_schedule_id,P=u.pipeline_schedule_name,Z=u.started_at,k=u.status,T=l,D=T.split(":"),R=Q===p&&ln;$&&(T=D[0],o=D[1],r=D[2]);var M=V[T];M||(M=V[D[0]]);var I=[(0,i.createElement)(x.ZP,A(A({},(0,S.NC)(k)),{},{key:"".concat(p,"_status")}),k),(0,E.jsx)(c(),{as:"/pipelines/".concat(J,"/edit?block_uuid=").concat(T),href:"/pipelines/[pipeline]/edit",passHref:!0,children:(0,E.jsxs)(m.Z,{bold:!0,fitContentWidth:!0,verticalAlignContent:!0,children:[(0,E.jsx)(b.Z,{color:(0,L.qn)(null===(e=M)||void 0===e?void 0:e.type,{blockColor:null===(t=M)||void 0===t?void 0:t.color,theme:B}).accent,size:1.5*C.iI,square:!0}),(0,E.jsx)(g.Z,{mr:1}),(0,E.jsxs)(x.ZP,{monospace:!0,sky:!0,children:[T,o&&":",o&&(0,E.jsx)(x.ZP,{default:!0,inline:!0,monospace:!0,children:o}),r>=0&&":",r>=0&&(0,E.jsx)(x.ZP,{default:!0,inline:!0,monospace:!0,children:r})]})]})},"".concat(p,"_block_uuid")),(0,E.jsx)(c(),{as:"/pipelines/".concat(J,"/triggers/").concat(O),href:"/pipelines/[pipeline]/triggers/[...slug]",passHref:!0,children:(0,E.jsx)(m.Z,{bold:!0,sky:!0,children:P})},"".concat(p,"_trigger")),(0,E.jsx)(x.ZP,{default:!0,monospace:!0,small:!0,title:s?(0,w._6)(s):null,children:Y?(0,w.XG)(s,Y):(0,w.d$)(s,{includeSeconds:!0})},"".concat(p,"_created_at")),(0,E.jsx)(x.ZP,{default:!0,monospace:!0,small:!0,title:Z?(0,w._6)(Z):null,children:Z?Y?(0,w.XG)(Z,Y):(0,w.d$)(Z,{includeSeconds:!0}):(0,E.jsx)(E.Fragment,{children:"\u2014"})},"".concat(p,"_started_at")),(0,E.jsx)(x.ZP,{default:!0,monospace:!0,small:!0,title:d?(0,w._6)(d):null,children:d?Y?(0,w.XG)(d,Y):(0,w.d$)(d,{includeSeconds:!0}):(0,E.jsx)(E.Fragment,{children:"\u2014"})},"".concat(p,"_completed_at")),(0,E.jsx)(v.ZP,{default:!0,iconOnly:!0,noBackground:!0,onClick:function(){return a().push("/pipelines/".concat(J,"/logs?block_run_id[]=").concat(p))},children:(0,E.jsx)(_.UL,{default:!0,size:2*C.iI})},"".concat(p,"_logs"))];return W&&I.push((0,E.jsx)(h.ZP,{alignItems:"center",justifyContent:"center",children:(0,E.jsx)(y.Z,{appearBefore:!0,autoHide:!R,block:!0,forceVisible:R,label:R?"".concat(U||0,"mb downloaded..."):"Save block run output as CSV file (not supported for dynamic blocks)",size:null,children:(0,E.jsx)(v.ZP,{default:!0,disabled:!W||!(f.V.COMPLETED===k)||ln,iconOnly:!0,loading:R,noBackground:!0,onClick:function(){X(null),G(p),cn({blockUUID:T,pipelineRunId:j})},children:(0,E.jsx)(_.vc,{default:!0,size:2*C.iI})})})},"".concat(p,"_save_output"))),I})),sortableColumnIndexes:N,sortedColumn:tn,uuid:"block-runs"})}},74052:function(n,e,t){t.d(e,{Dp:function(){return j},OF:function(){return g},Q9:function(){return x},Rt:function(){return b},Rz:function(){return P},h8:function(){return O},k1:function(){return h},uS:function(){return y},zv:function(){return Z}});var o=t(21831),r=t(82394),i=t(92083),u=t.n(i),c=t(48339),l=t(53808),a=t(3917),d=t(86735),s=t(81728),p=t(70320);function f(n,e){var t=Object.keys(n);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(n);e&&(o=o.filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),t.push.apply(t,o)}return t}function v(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{};e%2?f(Object(t),!0).forEach((function(e){(0,r.Z)(n,e,t[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(t)):f(Object(t)).forEach((function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(t,e))}))}return n}function b(n){var e={},t={};return null===n||void 0===n||n.forEach((function(n){var o=n.content,r=n.outputs,i=n.type,u=n.uuid;(null===r||void 0===r?void 0:r.length)>=1&&(e[u]=r.map((function(n){if("object"===typeof n){var e=n||{},t=e.sample_data,o=e.shape,r=e.text_data,i=e.type;return t?{data:v({shape:o},t),type:i}:r&&(0,s.Pb)(r)?JSON.parse(r):r}return{data:String(n),type:c.Gi.TEXT}}))),t[i]||(t[i]={}),t[i][u]=o})),{content:t,messages:e}}function h(n,e,t){n.forEach((function(n){(0,l.t8)("".concat(t,"/").concat(n.uuid,"/codeCollapsed"),(0,l.Od)("".concat(e,"/").concat(n.uuid,"/codeCollapsed"))),(0,l.t8)("".concat(t,"/").concat(n.uuid,"/outputCollapsed"),(0,l.Od)("".concat(e,"/").concat(n.uuid,"/outputCollapsed")))}))}function m(n){return"".concat(n,"/").concat(l.kP)}function j(n){return(0,l.U2)(m(n),[])}function g(n,e){var t=j(n);t.includes(e)||(0,l.t8)(m(n),[].concat((0,o.Z)(t),[e]))}function O(n,e){var t=j(n).filter((function(n){return n!==e}));(0,l.t8)(m(n),t)}function x(n,e){var t=(0,d.HK)(e,(function(n){return n.uuid}));return n.map((function(n){return t[n]})).filter((function(n){return!!n}))}var y=function(n,e){var t=window.URL.createObjectURL(n),o=document.createElement("a");o.href=t,o.download=e,document.body.appendChild(o),o.click(),o.remove()};function P(n,e){var t,o=(0,p.q)(),r=null===e||void 0===e?void 0:e.isPipelineUpdating,i=null===e||void 0===e?void 0:e.pipelineContentTouched,c=null===e||void 0===e?void 0:e.pipelineLastSaved;if(i)t="Unsaved changes";else if(r)t="Saving changes...";else if(c){var l=u()().utc().unix();if(null!==e&&void 0!==e&&e.displayRelative&&l-c<3600){var d=u().unix(l-(l-c)).utc().fromNow();t="Saved ".concat(d)}else{var s=(0,a.JX)(c/1e3);null!==n&&void 0!==n&&n.updated_at&&(s=(0,a.XG)(null===n||void 0===n?void 0:n.updated_at,o)),t="Last saved ".concat(s)}}else t="All changes saved";return t}function Z(n){var e=n.type,t=n.uuid;return"".concat(e,"s/").concat(t,".py")}},8955:function(n,e,t){t.d(e,{G7:function(){return y},ZP:function(){return P},u$:function(){return g}});var o=t(75582),r=t(82394),i=t(26304),u=t(90299),c=t(9134),l=t(24138),a=t(38276),d=t(30160),s=t(75499),p=t(70515),f=t(16488),v=t(42122),b=t(28598),h=["height","heightOffset","pipeline","selectedRun","selectedTab","setSelectedTab"];function m(n,e){var t=Object.keys(n);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(n);e&&(o=o.filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),t.push.apply(t,o)}return t}function j(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{};e%2?m(Object(t),!0).forEach((function(e){(0,r.Z)(n,e,t[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(t)):m(Object(t)).forEach((function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(t,e))}))}return n}var g=76,O={uuid:"Run details"},x={uuid:"Dependency tree"},y=[x,O];function P(n){var e=n.height,t=n.heightOffset,r=n.pipeline,m=n.selectedRun,P=n.selectedTab,Z=n.setSelectedTab,k=j({},(0,i.Z)(n,h));m?k.blockStatus=(0,f.IJ)(null===m||void 0===m?void 0:m.block_runs):k.noStatus=!0;var _=(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)||{},S=null===m||void 0===m?void 0:m.event_variables;if(S&&(0,v.Kn)(S)&&!(0,v.Qr)(S))if((0,v.Kn)(_)&&_.hasOwnProperty("event")){var C=(0,v.Kn)(_.event)?_.event:{};_.event=j(j({},C),S)}else _.event=j({},S);var w=[];_&&JSON.stringify(_,null,2).split("\n").forEach((function(n){w.push(" ".concat(n))}));var L=m&&[["Run ID",null===m||void 0===m?void 0:m.id],["Variables",(0,b.jsx)(c.Z,{language:"json",small:!0,source:w.join("\n")},"variable_value")]],T=m&&(0,b.jsx)(a.Z,{pb:p.cd,px:p.cd,children:(0,b.jsx)(s.Z,{alignTop:!0,columnFlex:[null,1],columnMaxWidth:function(n){return 1===n?"100px":null},rows:L.map((function(n,e){var t=(0,o.Z)(n,2),r=t[0],i=t[1];return[(0,b.jsx)(d.ZP,{monospace:!0,muted:!0,children:r},"key_".concat(e)),(0,b.jsx)(d.ZP,{monospace:!0,textOverflow:!0,children:i},"val_".concat(e))]})),uuid:"LogDetail"})}),D=P&&Z;return(0,b.jsxs)(b.Fragment,{children:[D&&(0,b.jsx)(a.Z,{py:p.cd,children:(0,b.jsx)(u.Z,{onClickTab:Z,selectedTabUUID:null===P||void 0===P?void 0:P.uuid,tabs:y})}),(!D||x.uuid===(null===P||void 0===P?void 0:P.uuid))&&(0,b.jsx)(l.ZP,j(j({},k),{},{height:e,heightOffset:(t||0)+(D?g:0),pipeline:r})),O.uuid===(null===P||void 0===P?void 0:P.uuid)&&T]})}},55072:function(n,e,t){t.d(e,{Et:function(){return p},Q:function(){return s}});t(82684);var o=t(71180),r=t(55485),i=t(38276),u=t(31748),c=t(72473),l=t(79633),a=t(70515),d=t(28598),s=30,p=9;e.ZP=function(n){var e=n.page,t=n.maxPages,s=n.onUpdate,p=n.totalPages,f=[],v=t;if(v>p)f=Array.from({length:p},(function(n,e){return e}));else{var b=Math.floor(v/2),h=e-b;e+b>=p?(h=p-v+2,v-=2):e-b<=0?(h=0,v-=2):(v-=4,h=e-Math.floor(v/2)),f=Array.from({length:v},(function(n,e){return e+h}))}return(0,d.jsx)(d.Fragment,{children:p>0&&(0,d.jsxs)(r.ZP,{alignItems:"center",children:[(0,d.jsx)(o.ZP,{disabled:0===e,onClick:function(){return s(e-1)},children:(0,d.jsx)(c.Hd,{size:1.5*a.iI,stroke:u.Av})}),!f.includes(0)&&(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(i.Z,{ml:1,children:(0,d.jsx)(o.ZP,{borderLess:!0,noBackground:!0,onClick:function(){return s(0)},children:1})},0),!f.includes(1)&&(0,d.jsx)(i.Z,{ml:1,children:(0,d.jsx)(o.ZP,{noBackground:!0,noPadding:!0,notClickable:!0,children:"..."})},0)]}),f.map((function(n){return(0,d.jsx)(i.Z,{ml:1,children:(0,d.jsx)(o.ZP,{backgroundColor:n===e&&l.a$,borderLess:!0,noBackground:!0,notClickable:n===e,onClick:function(){n!==e&&s(n)},children:n+1})},n)})),!f.includes(p-1)&&(0,d.jsxs)(d.Fragment,{children:[!f.includes(p-2)&&(0,d.jsx)(i.Z,{ml:1,children:(0,d.jsx)(o.ZP,{noBackground:!0,noPadding:!0,notClickable:!0,children:"..."})},0),(0,d.jsx)(i.Z,{ml:1,children:(0,d.jsx)(o.ZP,{borderLess:!0,noBackground:!0,onClick:function(){return s(p-1)},children:p})},p-1)]}),(0,d.jsx)(i.Z,{ml:1}),(0,d.jsx)(o.ZP,{disabled:e===p-1,onClick:function(){return s(e+1)},children:(0,d.jsx)(c.Kw,{size:1.5*a.iI,stroke:u.Av})})]})})}},89706:function(n,e,t){t.d(e,{JD:function(){return b},Lu:function(){return i},PF:function(){return p},dT:function(){return u},n6:function(){return a},nB:function(){return v},oy:function(){return f},xF:function(){return s}});var o,r,i,u,c=t(82394),l=t(44425);!function(n){n.CSV="csv",n.JSON="json",n.MD="md",n.PY="py",n.R="r",n.SH="sh",n.SQL="sql",n.TXT="txt",n.YAML="yaml",n.YML="yml"}(i||(i={})),function(n){n.INIT_PY="__init__.py",n.METADATA_YAML="metadata.yaml",n.REQS_TXT="requirements.txt"}(u||(u={}));var a=[i.PY,i.SQL],d=[i.JSON,i.MD,i.PY,i.R,i.SH,i.SQL,i.TXT,i.YAML,i.YML],s=new RegExp(d.map((function(n){return".".concat(n,"$")})).join("|")),p=(new RegExp(d.map((function(n){return".".concat(n,"$")})).join("|")),"charts"),f="pipelines",v=(o={},(0,c.Z)(o,i.MD,l.t6.MARKDOWN),(0,c.Z)(o,i.JSON,i.JSON),(0,c.Z)(o,i.PY,l.t6.PYTHON),(0,c.Z)(o,i.R,l.t6.R),(0,c.Z)(o,i.SQL,l.t6.SQL),(0,c.Z)(o,i.TXT,"text"),(0,c.Z)(o,i.YAML,l.t6.YAML),(0,c.Z)(o,i.YML,l.t6.YAML),o),b=(r={},(0,c.Z)(r,l.t6.MARKDOWN,i.MD),(0,c.Z)(r,l.t6.PYTHON,i.PY),(0,c.Z)(r,l.t6.R,i.R),(0,c.Z)(r,l.t6.SQL,i.SQL),(0,c.Z)(r,l.t6.YAML,i.YAML),(0,c.Z)(r,"text",i.TXT),r)},9134:function(n,e,t){var o=t(82684),r=t(21124),i=t(68432),u=t(38626),c=t(65292),l=t(44897),a=t(95363),d=t(70515),s=t(28598);e.Z=function(n){var e=n.language,t=n.maxWidth,p=n.showLineNumbers,f=n.small,v=n.source,b=n.wrapLines,h=(0,o.useContext)(u.ThemeContext);function m(n){var o=n.value;return(0,s.jsx)(i.Z,{customStyle:{backgroundColor:(h.background||l.Z.background).popup,border:"none",borderRadius:"none",boxShadow:"none",fontFamily:a.Vp,fontSize:f?12:14,marginBottom:0,marginTop:0,maxWidth:t,paddingBottom:2*d.iI,paddingTop:2*d.iI},language:e,lineNumberStyle:{color:(h.content||l.Z.content).muted},showLineNumbers:p,style:c._4,useInlineStyles:!0,wrapLines:b,children:o})}return(0,s.jsx)(r.D,{components:{code:function(n){var e=n.children;return(0,s.jsx)(m,{value:e})}},children:v})}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3943],{4611:function(e,n,t){t.d(n,{f:function(){return o}});var i=t(38626),r=t(44897),u=t(70515),l=t(42631),o=i.default.div.withConfig({displayName:"Tablestyle__PopupContainerStyle",componentId:"sc-8ammqd-0"})(["position:absolute;max-height:","px;z-index:10;border-radius:","px;padding:","px;"," "," "," ",""],58*u.iI,l.TR,2*u.iI,(function(e){return"\n box-shadow: ".concat((e.theme.shadow||r.Z.shadow).popup,";\n background-color: ").concat((e.theme.interactive||r.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 ")}))},53943:function(e,n,t){var i=t(82394),r=t(75582),u=t(12691),l=t.n(u),o=t(69864),c=t(82684),a=t(34376),s=t(71180),d=t(70652),p=t(50724),f=t(97618),h=t(55485),v=t(48670),m=t(44265),g=t(89515),x=t(38276),b=t(4190),_=t(75499),j=t(48381),E=t(30160),I=t(35686),O=t(44897),y=t(42631),P=t(72473),Z=t(81655),C=t(72191),w=t(39643),k=t(4611),N=t(30229),D=t(31608),T=t(70515),L=t(3917),A=t(16488),R=t(86735),S=t(50178),V=t(72619),F=t(3314),U=t(69419),M=t(70320),Y=t(44688),H=t(28598);function G(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,i)}return t}function B(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,i.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}var z={monospace:!0,small:!0};function X(e){var n=e.cancelingRunId,t=e.disabled,i=e.isLoadingCancelPipeline,u=e.onCancel,l=e.onSuccess,a=e.pipelineRun,d=e.setCancelingRunId,f=e.setErrors,v=e.setShowConfirmationId,g=e.showConfirmationId,_=(0,S.Ct)(),j=a||{},Z=j.id,w=j.pipeline_schedule_id,D=j.pipeline_schedule_token,T=j.pipeline_schedule_type,L=j.status,A=i&&Z===n&&m.VO.RUNNING===L,R=(0,U.iV)(),F=(0,c.useMemo)((function(){return(null!==R&&void 0!==R&&R.page?+R.page:0)>0}),[null===R||void 0===R?void 0:R.page]),M=(0,o.Db)(N.Xm.API===T&&D?I.ZP.pipeline_runs.pipeline_schedules.useCreateWithParent(w,D):I.ZP.pipeline_runs.pipeline_schedules.useCreate(w),{onSuccess:function(e){return(0,V.wD)(e,{callback:function(){l()},onErrorCallback:function(e,n){return null===f||void 0===f?void 0:f({errors:n,response:e})}})}}),Y=(0,r.Z)(M,1)[0],G=(0,c.useCallback)((function(){v(null),Y({pipeline_run:{backfill_id:null===a||void 0===a?void 0:a.backfill_id,event_variables:(null===a||void 0===a?void 0:a.event_variables)||{},execution_date:null===a||void 0===a?void 0:a.execution_date,pipeline_schedule_id:null===a||void 0===a?void 0:a.pipeline_schedule_id,pipeline_uuid:null===a||void 0===a?void 0:a.pipeline_uuid,variables:(null===a||void 0===a?void 0:a.variables)||{}}})}),[Y,a,v]),B=(0,c.useCallback)((function(){v(null),d(Z),u({id:Z,status:m.VO.CANCELLED})}),[u,Z,d,v]);return(0,H.jsxs)("div",{style:{position:"relative"},children:[(0,H.jsx)(s.ZP,{backgroundColor:A&&O.Z.accent.yellow,beforeIcon:m.VO.INITIAL!==L&&!t&&(0,H.jsxs)(H.Fragment,{children:[m.VO.COMPLETED===L&&(0,H.jsx)(P.Jr,{size:C.bL}),[m.VO.FAILED,m.VO.CANCELLED].includes(L)&&(0,H.jsx)(P.Py,{inverted:m.VO.CANCELLED===L&&!_,size:C.bL}),[m.VO.RUNNING].includes(L)&&(0,H.jsx)(b.Z,{color:A?O.Z.status.negative:O.Z.monotone.white,small:!0})]}),borderRadius:"".concat(y.D7,"px"),danger:m.VO.FAILED===L&&!_,default:m.VO.INITIAL===L,disabled:t||_,loading:!a,onClick:function(e){e.stopPropagation(),v(Z)},padding:"6px",primary:m.VO.RUNNING===L&&!A&&!_,warning:m.VO.CANCELLED===L&&!_,children:t?"Ready":A?"Canceling":m.Do[L]}),(0,H.jsx)(p.Z,{onClickOutside:function(){return v(null)},open:g===Z,children:(0,H.jsxs)(k.f,{children:[[m.VO.RUNNING,m.VO.INITIAL].includes(L)&&(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(E.ZP,{bold:!0,color:"#9ECBFF",children:"Run is in progress"}),(0,H.jsx)(x.Z,{mb:1}),(0,H.jsxs)(E.ZP,{children:["This pipeline run is currently ongoing. Retrying will cancel",(0,H.jsx)("br",{}),"the current pipeline run."]}),(0,H.jsx)(E.ZP,{}),(0,H.jsx)(x.Z,{mt:1,children:(0,H.jsxs)(h.ZP,{children:[(0,H.jsx)(s.ZP,{onClick:function(){B(),G()},children:"Retry run"}),(0,H.jsx)(x.Z,{ml:1}),(0,H.jsx)(s.ZP,{onClick:B,children:"Cancel run"})]})})]}),[m.VO.CANCELLED,m.VO.FAILED,m.VO.COMPLETED].includes(L)&&(0,H.jsxs)(H.Fragment,{children:[(0,H.jsxs)(E.ZP,{bold:!0,color:"#9ECBFF",children:["Run ",L]}),(0,H.jsx)(x.Z,{mb:1}),(0,H.jsxs)(E.ZP,{children:["Retry the run with changes you have made to the pipeline.",F?(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)("br",{}),"Note that the retried run may appear on a previous page."]}):null]}),(0,H.jsx)(x.Z,{mb:1}),(0,H.jsx)(s.ZP,{onClick:G,children:"Retry run"})]})]})})]})}n.Z=function(e){var n=e.allowBulkSelect,t=e.allowDelete,u=e.deletePipelineRun,b=e.disableKeyboardNav,O=e.disableRowSelect,k=e.emptyMessage,N=void 0===k?"No runs available":k,U=e.fetchPipelineRuns,G=e.hideTriggerColumn,K=e.includePipelineTags,Q=e.onClickRow,W=e.pipelineRuns,q=e.selectedRun,J=e.selectedRuns,$=e.setSelectedRun,ee=e.setSelectedRuns,ne=e.setErrors,te=(0,a.useRouter)(),ie=(0,S.Ct)(),re=(0,M.q)(),ue=(0,c.useRef)({}),le=(0,c.useState)(null),oe=le[0],ce=le[1],ae=(0,c.useState)(null),se=ae[0],de=ae[1],pe=(0,c.useState)(null),fe=pe[0],he=pe[1],ve=(0,c.useState)(0),me=ve[0],ge=ve[1],xe=(0,c.useState)(0),be=xe[0],_e=xe[1],je=(0,o.Db)((function(e){var n=e.id,t=e.status;return I.ZP.pipeline_runs.useUpdate(n)({pipeline_run:{status:t}})}),{onSuccess:function(e){return(0,V.wD)(e,{callback:function(){ce(null),null===U||void 0===U||U()},onErrorCallback:function(e,n){ce(null),null===ne||void 0===ne||ne({errors:n,response:e})}})}}),Ee=(0,r.Z)(je,2),Ie=Ee[0],Oe=Ee[1].isLoading,ye="PipelineDetail/Runs/Table",Pe="pipeline-runs",Ze=(0,c.useCallback)((function(e){if(!e)return null;var n=W.findIndex((function(n){return n.id===e.id}));return n>=0?n:null}),[W]),Ce=(0,Y.y)(),we=Ce.registerOnKeyDown,ke=Ce.unregisterOnKeyDown;(0,c.useEffect)((function(){return function(){ke(ye)}}),[ke,ye]),we(ye,(function(e,n){var t=n[w.Bu],i=n[w.kD];$&&!b&&(t||i)&&$((function(n){var r=Ze(n);if(null!==r){if(e.repeat)return e.preventDefault(),n;if(t){var u=r-1;return u<0&&(u=W.length-1),W[u]}if(i){var l=r+1;return l>=W.length&&(l=0),W[l]}}return n}))}),[W,$]),(0,c.useEffect)((function(){var e=Ze(q);if(null!==e){var n=(0,Z.w4)({rowIndex:e,uuid:Pe}),t=document.getElementById(n);t&&t.scrollIntoView({behavior:"smooth",block:"center"})}}),[Ze,q]);var Ne=re?Z.O$:{},De=[null,1],Te=[{uuid:"Status"},{uuid:"Pipeline"}];G||(De.push(1),Te.push({uuid:"Trigger"})),K&&(De.push(null),Te.push({uuid:"Pipeline tags"})),De.push.apply(De,[1,1,1,null,null]),Te.push.apply(Te,[B(B({},Ne),{},{uuid:"Execution date"}),B(B({},Ne),{},{uuid:"Started at"}),B(B({},Ne),{},{uuid:"Completed at"}),{uuid:"Execution time"},{uuid:"Block runs"},{uuid:"Logs"}]),t&&!ie&&(De.push.apply(De,[null]),Te.push({label:function(){return""},uuid:"Delete"}));var Le=(0,c.useMemo)((function(){return W.every((function(e){var n=e.id;return!(null===J||void 0===J||!J[n])}))}),[W,J]);n&&(De.unshift(null),Te.unshift({label:function(){return(0,H.jsx)(d.Z,{checked:Le,onClick:function(){var e=(0,R.HK)(W||[],(function(e){return e.id}));ee(Le?{}:e)}})},uuid:"Selected"})),!O&&Q&&(De.push(null),Te.push({label:function(){return""},uuid:"action"}));var Ae=(0,c.useCallback)((function(e,n){if(Q&&ee&&n&&n.metaKey){var t=W[e];ee((function(e){var n=!(null===e||void 0===e||!e[t.id]);return B(B({},e),{},(0,i.Z)({},t.id,n?null:t))}))}else Q&&Q(e)}),[Q,W,ee]);return(0,H.jsx)(D.cl,{minHeight:30*T.iI,overflowVisible:!!se,children:0===(null===W||void 0===W?void 0:W.length)?(0,H.jsx)(x.Z,{px:3,py:1,children:(0,H.jsx)(E.ZP,{bold:!0,default:!0,monospace:!0,muted:!0,children:N})}):(0,H.jsx)(_.Z,{columnFlex:De,columns:Te,isSelectedRow:function(e){return!O&&W[e].id===(null===q||void 0===q?void 0:q.id)},onClickRow:O?null:Ae,rowVerticalPadding:6,rows:null===W||void 0===W?void 0:W.map((function(e,r){var o=e.block_runs_count,a=e.completed_block_runs_count,b=e.completed_at,_=e.execution_date,I=e.id,w=e.pipeline_schedule_id,k=e.pipeline_schedule_name,N=e.pipeline_tags,D=e.pipeline_uuid,T=e.started_at,R=e.status;ue.current[I]=(0,c.createRef)();var S,V,M=!I&&!R,Y="".concat(a," out of ").concat(o," block runs completed"),q=(0,H.jsx)(j.Z,{tags:null===N||void 0===N?void 0:N.map((function(e){return{uuid:e}}))},"row_pipeline_tags_".concat(r)),$=[];r>0&&W[r-1].execution_date===e.execution_date&&W[r-1].pipeline_schedule_id===e.pipeline_schedule_id?($=[(0,H.jsx)(x.Z,{ml:1,children:(0,H.jsxs)(h.ZP,{alignItems:"center",children:[(0,H.jsx)(P.TT,{size:C.bL,useStroke:!0}),(0,H.jsx)(s.ZP,{borderRadius:"".concat(y.D7,"px"),notClickable:!0,padding:"6px",children:(0,H.jsx)(E.ZP,{muted:!0,children:m.Do[R]})})]})},"row_status"),(0,H.jsx)(E.ZP,{default:!0,monospace:!0,muted:!0,children:D},"row_pipeline_uuid")],G||$.push((0,H.jsx)(E.ZP,{default:!0,monospace:!0,muted:!0,children:"-"},"row_trigger_retry")),K&&$.push(q),(S=$).push.apply(S,[(0,H.jsx)(E.ZP,{default:!0,monospace:!0,muted:!0,children:"-"},"row_date_retry"),(0,c.createElement)(E.ZP,B(B({},z),{},{key:"row_started_at",muted:!0,title:T?(0,L._6)(T):null}),T?re?(0,L.XG)(T,re):(0,A.Vx)(T):(0,H.jsx)(H.Fragment,{children:"\u2014"})),(0,c.createElement)(E.ZP,B(B({},z),{},{key:"row_completed_at",muted:!0,title:b?(0,L._6)(b):null}),b?re?(0,L.XG)(b,re):(0,A.Vx)(b):(0,H.jsx)(H.Fragment,{children:"\u2014"})),(0,c.createElement)(E.ZP,B(B({},z),{},{default:!0,key:"row_execution_time",title:T&&b?(0,L.Qf)({endDatetime:b,showFullFormat:!0,startDatetime:T}):null}),T&&b?(0,L.Qf)({endDatetime:b,startDatetime:T}):(0,H.jsx)(H.Fragment,{children:"\u2014"})),(0,H.jsx)(l(),{as:"/pipelines/".concat(D,"/runs/").concat(I),href:"/pipelines/[pipeline]/runs/[run]",passHref:!0,children:(0,H.jsx)(v.Z,{bold:!0,muted:!0,title:Y,children:"".concat(a," / ").concat(o)})},"row_block_runs"),(0,H.jsx)(s.ZP,{default:!0,iconOnly:!0,noBackground:!0,onClick:function(e){e.stopPropagation(),te.push("/pipelines/".concat(D,"/logs?pipeline_run_id[]=").concat(I))},children:(0,H.jsx)(P.UL,{default:!0,size:C.bL})},"row_logs")])):($=[(0,H.jsx)(X,{cancelingRunId:oe,disabled:M,isLoadingCancelPipeline:Oe,onCancel:Ie,onSuccess:U,pipelineRun:e,setCancelingRunId:ce,setErrors:ne,setShowConfirmationId:de,showConfirmationId:se},"row_retry_button"),(0,H.jsx)(E.ZP,{default:!0,monospace:!0,children:D},"row_pipeline_uuid")],G||$.push((0,H.jsx)(l(),{as:"/pipelines/".concat(D,"/triggers/").concat(w),href:"/pipelines/[pipeline]/triggers/[...slug]",passHref:!0,children:(0,H.jsx)(v.Z,{bold:!0,sky:!0,children:k})},"row_trigger")),K&&$.push(q),(V=$).push.apply(V,[(0,c.createElement)(E.ZP,B(B({},z),{},{default:!0,key:"row_date",title:_?(0,L._6)(_):null}),_?re?(0,L.XG)(_,re):(0,A.Vx)(_):(0,H.jsx)(H.Fragment,{children:"\u2014"})),(0,c.createElement)(E.ZP,B(B({},z),{},{default:!0,key:"row_started_at",title:T?(0,L._6)(T):null}),T?re?(0,L.XG)(T,re):(0,A.Vx)(T):(0,H.jsx)(H.Fragment,{children:"\u2014"})),(0,c.createElement)(E.ZP,B(B({},z),{},{default:!0,key:"row_completed_at",title:b?(0,L._6)(b):null}),b?re?(0,L.XG)(b,re):(0,A.Vx)(b):(0,H.jsx)(H.Fragment,{children:"\u2014"})),(0,c.createElement)(E.ZP,B(B({},z),{},{default:!0,key:"row_execution_time",title:T&&b?(0,L.Qf)({endDatetime:b,showFullFormat:!0,startDatetime:T}):null}),T&&b?(0,L.Qf)({endDatetime:b,startDatetime:T}):(0,H.jsx)(H.Fragment,{children:"\u2014"})),(0,H.jsx)(l(),{as:"/pipelines/".concat(D,"/runs/").concat(I),href:"/pipelines/[pipeline]/runs/[run]",passHref:!0,children:(0,H.jsx)(v.Z,{bold:!0,disabled:M,sky:!0,title:Y,children:M?"":"".concat(a," / ").concat(o)})},"row_block_runs"),(0,H.jsx)(s.ZP,{default:!0,disabled:M,iconOnly:!0,noBackground:!0,onClick:function(e){e.stopPropagation(),te.push("/pipelines/".concat(D,"/logs?pipeline_run_id[]=").concat(I))},children:(0,H.jsx)(P.UL,{default:!0,size:C.bL})},"row_logs")]));if(t&&!ie&&$.push((0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(s.ZP,{default:!0,iconOnly:!0,noBackground:!0,onClick:function(e){var n,t,i,r;(0,F.j)(e),he(I),ge((null===(n=ue.current[I])||void 0===n||null===(t=n.current)||void 0===t?void 0:t.offsetTop)||0),_e((null===(i=ue.current[I])||void 0===i||null===(r=i.current)||void 0===r?void 0:r.offsetLeft)||0)},ref:ue.current[I],title:"Delete",children:(0,H.jsx)(P.rF,{default:!0,size:C.bL})}),(0,H.jsx)(p.Z,{onClickOutside:function(){return he(null)},open:fe===I,children:(0,H.jsx)(g.Z,{danger:!0,left:(be||0)-Z.nH,onCancel:function(){return he(null)},onClick:function(){he(null),u(I)},title:"Are you sure you want to delete this run (id ".concat(I,' for trigger "').concat(k,'")?'),top:(me||0)-(r<=1?Z.oz:Z.OK),width:Z.Xx})})]})),n){var le=!(null===J||void 0===J||!J[I]);$.unshift((0,H.jsx)(d.Z,{checked:le,onClick:function(n){n.stopPropagation(),ee((function(n){return B(B({},n),{},(0,i.Z)({},I,le?null:e))}))}},"selected-pipeline-run-".concat(I)))}return!O&&Q&&$.push((0,H.jsx)(f.Z,{flex:1,justifyContent:"flex-end",children:(0,H.jsx)(P._Q,{default:!0,size:C.bL})})),$})),uuid:Pe})})}},48381:function(e,n,t){var i=t(82684),r=t(31882),u=t(55485),l=t(30160),o=t(86735),c=t(28598);n.Z=function(e){var n=e.onClickTag,t=e.tags,a=void 0===t?[]:t,s=(0,i.useMemo)((function(){return(null===a||void 0===a?void 0:a.length)||0}),[a]),d=(0,i.useMemo)((function(){return(0,o.YC)(a||[],"uuid")}),[a]);return(0,c.jsx)(u.ZP,{alignItems:"center",flexWrap:"wrap",children:null===d||void 0===d?void 0:d.reduce((function(e,t){return e.push((0,c.jsx)("div",{style:{marginBottom:2,marginRight:s>=2?4:0,marginTop:2},children:(0,c.jsx)(r.Z,{onClick:n?function(){return n(t)}:null,small:!0,children:(0,c.jsx)(l.ZP,{children:t.uuid})})},"tag-".concat(t.uuid))),e}),[])})}},16488:function(e,n,t){t.d(n,{IJ:function(){return v},M8:function(){return y},Vx:function(){return _},XM:function(){return O},_U:function(){return h},eI:function(){return b},gU:function(){return E},lO:function(){return k},ri:function(){return g},tL:function(){return j},vJ:function(){return I},xH:function(){return x}});var i,r=t(82394),u=t(92083),l=t.n(u),o=t(3917),c=t(4383),a=t(30229),s=t(42122),d=t(86735);function p(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,i)}return t}function f(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?p(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):p(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var h=function(e){return!!e&&!Object.values(a.U5).includes(e)};function v(e){return null===e||void 0===e?void 0:e.reduce((function(e,n){var t=n.block_uuid,i=n.completed_at,u=n.started_at,o=n.status,c=null;u&&i&&(c=l()(i).valueOf()-l()(u).valueOf());return f(f({},e),{},(0,r.Z)({},t,{runtime:c,status:o}))}),{})}var m,g=function(e){var n=[{description:function(){return"This pipeline will run continuously on an interval or just once."},label:function(){return"Schedule"},uuid:a.Xm.TIME},{description:function(){return"This pipeline will run when a specific event occurs."},label:function(){return"Event"},uuid:a.Xm.EVENT},{description:function(){return"Run this pipeline when you make an API call."},label:function(){return"API"},uuid:a.Xm.API}];return e?n.slice(0,1):n};function x(e){var n=(0,s.gR)(e,[a.gm.INTERVAL,a.gm.TYPE]),t=e[a.gm.INTERVAL];t&&(n["schedule_interval[]"]=encodeURIComponent(t));var i=e[a.gm.TYPE];return i&&(n["schedule_type[]"]=i),n}function b(e){if(!e)return null;var n=new Date(l()(e).valueOf()),t=Date.UTC(n.getFullYear(),n.getMonth(),n.getDate(),n.getHours(),n.getMinutes(),n.getSeconds());return new Date(t)}function _(e){return"string"!==typeof e?e:b(e.split("+")[0]).toISOString().split(".")[0]}!function(e){e.DAY="day",e.HOUR="hour",e.MINUTE="minute",e.SECOND="second"}(m||(m={}));var j=(i={},(0,r.Z)(i,m.DAY,86400),(0,r.Z)(i,m.HOUR,3600),(0,r.Z)(i,m.MINUTE,60),(0,r.Z)(i,m.SECOND,1),i);function E(e){var n=m.SECOND,t=e;return e%86400===0?(t/=86400,n=m.DAY):e%3600===0?(t/=3600,n=m.HOUR):e%60===0&&(t/=60,n=m.MINUTE),{time:t,unit:n}}function I(e,n){return e*j[n]}function O(e,n,t){var i="".concat(e.toISOString().split("T")[0]," ").concat(null===n||void 0===n?void 0:n.hour,":").concat(null===n||void 0===n?void 0:n.minute);if(null!==t&&void 0!==t&&t.includeSeconds&&(i=i.concat(":00")),null!==t&&void 0!==t&&t.localTimezone){var r=l()(e);r.set("hour",+(null===n||void 0===n?void 0:n.hour)||0),r.set("minute",+(null===n||void 0===n?void 0:n.minute)||0),r.set("second",0),i=r.format(o.lE),null!==t&&void 0!==t&&t.convertToUtc&&(i=(0,o.d$)(i,{includeSeconds:null===t||void 0===t?void 0:t.includeSeconds,utcFormat:!0}))}return i}function y(e){var n,t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],i="",r=!0;return r&&(t?i="".concat(window.origin,"/api/pipeline_schedules/").concat(null===e||void 0===e?void 0:e.id,"/api_trigger"):(i="".concat(window.origin,"/api/pipeline_schedules/").concat(null===e||void 0===e?void 0:e.id,"/pipeline_runs"),null!==e&&void 0!==e&&e.token&&(i="".concat(i,"/").concat(e.token)))),r&&(n=window.location.port)&&(i=i.replace(n,c.QT)),i}function P(e,n,t){return e.match(/[*,-/]/)?{additionalOffset:0,cronValue:e}:function(e,n,t){var i=t.indexOf(e),r=0;if(n<0)for(var u=0;u>n;u--)0===i?(i=t.length-1,r-=1):i-=1;else if(n>0)for(var l=0;l<n;l++)i===t.length-1?(i=0,r+=1):i+=1;return{additionalOffset:r,cronValue:String(t[i]||e)}}(+e,n,t)}var Z=(0,d.m5)(60),C=(0,d.m5)(24),w=(0,o.Cs)();function k(e,n){if(!e)return e;var t=l()().local().format("Z"),i=t.split(":"),r="-"===t[0],u=3===i[0].length?Number(i[0].slice(1)):Number(i[0]),o=Number(i[1]);(r&&!n||!r&&n)&&(u=-u,o=-o);var c=e.split(" "),a=c[0],s=c[1],d=c[2],p=P(a,o,Z),f=P(s,u+p.additionalOffset,C);if(c[0]=p.cronValue,c[1]=f.cronValue,0!==(null===f||void 0===f?void 0:f.additionalOffset)){var h=P(d,f.additionalOffset,w);c[2]=h.cronValue}return c.join(" ")}},44265:function(e,n,t){t.d(n,{Az:function(){return a},BF:function(){return c},Do:function(){return d},IK:function(){return o},P0:function(){return r},VO:function(){return l},sZ:function(){return s}});var i,r,u=t(82394),l=t(41143).V,o=[l.FAILED,l.COMPLETED,l.RUNNING,l.CANCELLED,l.INITIAL],c=[l.INITIAL,l.RUNNING],a=[l.CANCELLED,l.COMPLETED,l.FAILED],s="__mage_variables",d=(i={},(0,u.Z)(i,l.CANCELLED,"Cancelled"),(0,u.Z)(i,l.COMPLETED,"Done"),(0,u.Z)(i,l.FAILED,"Failed"),(0,u.Z)(i,l.INITIAL,"Ready"),(0,u.Z)(i,l.RUNNING,"Running"),i);!function(e){e.PIPELINE_UUID="pipeline_uuid[]",e.STATUS="status[]",e.TAG="pipeline_tag[]"}(r||(r={}))},30229:function(e,n,t){t.d(n,{TR:function(){return f},U5:function(){return c},Wb:function(){return p},Xm:function(){return u},Z4:function(){return a},fq:function(){return o},gm:function(){return s},kJ:function(){return d}});var i,r,u,l=t(82394);!function(e){e.API="api",e.EVENT="event",e.TIME="time"}(u||(u={}));var o,c,a=(i={},(0,l.Z)(i,u.API,(function(){return"API"})),(0,l.Z)(i,u.EVENT,(function(){return"event"})),(0,l.Z)(i,u.TIME,(function(){return"schedule"})),i);!function(e){e.ACTIVE="active",e.INACTIVE="inactive"}(o||(o={})),function(e){e.ONCE="@once",e.HOURLY="@hourly",e.DAILY="@daily",e.WEEKLY="@weekly",e.MONTHLY="@monthly",e.ALWAYS_ON="@always_on"}(c||(c={}));var s,d,p=[c.ONCE,c.HOURLY,c.DAILY,c.WEEKLY,c.MONTHLY];!function(e){e.INTERVAL="frequency[]",e.STATUS="status[]",e.TAG="tag[]",e.TYPE="type[]"}(s||(s={})),function(e){e.CREATED_AT="created_at",e.NAME="name",e.PIPELINE="pipeline_uuid",e.STATUS="status",e.TYPE="schedule_type"}(d||(d={}));var f=(r={},(0,l.Z)(r,d.CREATED_AT,"Created at"),(0,l.Z)(r,d.NAME,"Name"),(0,l.Z)(r,d.PIPELINE,"Pipeline"),(0,l.Z)(r,d.STATUS,"Active"),(0,l.Z)(r,d.TYPE,"Type"),r)},31882:function(e,n,t){var i=t(38626),r=t(71180),u=t(55485),l=t(30160),o=t(44897),c=t(72473),a=t(70515),s=t(61896),d=t(28598),p=i.default.div.withConfig({displayName:"Chip__ChipStyle",componentId:"sc-1ok73g-0"})(["display:inline-block;"," "," "," "," "," ",""],(function(e){return!e.primary&&"\n background-color: ".concat((e.theme.background||o.Z.background).tag,";\n ")}),(function(e){return e.primary&&"\n background-color: ".concat((e.theme.chart||o.Z.chart).primary,";\n ")}),(function(e){return!e.small&&"\n border-radius: ".concat((a.iI+s.Al)/2,"px;\n height: ").concat(1.5*a.iI+s.Al,"px;\n padding: ").concat(a.iI/1.5,"px ").concat(1.25*a.iI,"px;\n ")}),(function(e){return e.small&&"\n border-radius: ".concat((a.iI/2+s.Al)/2,"px;\n height: ").concat(s.Al+a.iI/2+2,"px;\n padding: ").concat(a.iI/4,"px ").concat(a.iI,"px;\n ")}),(function(e){return e.xsmall&&"\n border-radius: ".concat((a.iI/1+s.Al)/1,"px;\n height: ").concat(20,"px;\n padding: 4px 6px;\n ")}),(function(e){return e.border&&"\n border: 1px solid ".concat((e.theme.content||o.Z.content).muted,";\n ")}));n.Z=function(e){var n=e.border,t=e.children,i=e.disabled,o=e.label,s=e.monospace,f=e.onClick,h=e.primary,v=e.small,m=e.xsmall;return(0,d.jsx)(p,{border:n,primary:h,small:v,xsmall:m,children:(0,d.jsx)(r.ZP,{basic:!0,disabled:i,noBackground:!0,noPadding:!0,onClick:f,transparent:!0,children:(0,d.jsxs)(u.ZP,{alignItems:"center",children:[t,o&&(0,d.jsx)(l.ZP,{monospace:s,small:v,xsmall:m,children:o}),!i&&f&&(0,d.jsx)("div",{style:{marginLeft:2}}),!i&&f&&(0,d.jsx)(c.x8,{default:h,muted:!h,size:v?a.iI:1.25*a.iI})]})})})}}}]);