mage-ai 0.9.12__py3-none-any.whl → 0.9.14__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 (325) hide show
  1. mage_ai/ai/generator.py +1 -1
  2. mage_ai/ai/generator_cmds.py +1 -1
  3. mage_ai/ai/llm_pipeline_wizard.py +31 -17
  4. mage_ai/api/policies/BlockPolicy.py +1 -0
  5. mage_ai/api/policies/PipelineRunPolicy.py +1 -0
  6. mage_ai/api/policies/PipelineSchedulePolicy.py +12 -0
  7. mage_ai/api/policies/TagPolicy.py +18 -0
  8. mage_ai/api/presenters/BlockRunPresenter.py +4 -1
  9. mage_ai/api/presenters/PipelineRunPresenter.py +2 -0
  10. mage_ai/api/presenters/PipelineSchedulePresenter.py +9 -2
  11. mage_ai/api/presenters/TagPresenter.py +3 -0
  12. mage_ai/api/resources/BackfillResource.py +6 -3
  13. mage_ai/api/resources/BlockResource.py +2 -0
  14. mage_ai/api/resources/BlockRunResource.py +18 -12
  15. mage_ai/api/resources/DatabaseResource.py +23 -0
  16. mage_ai/api/resources/GitBranchResource.py +8 -1
  17. mage_ai/api/resources/GlobalDataProductResource.py +5 -2
  18. mage_ai/api/resources/PipelineResource.py +30 -14
  19. mage_ai/api/resources/PipelineScheduleResource.py +157 -1
  20. mage_ai/api/resources/SearchResultResource.py +1 -0
  21. mage_ai/api/resources/TagResource.py +16 -3
  22. mage_ai/data_integrations/sources/constants.py +1 -0
  23. mage_ai/data_preparation/git/__init__.py +18 -0
  24. mage_ai/data_preparation/models/block/__init__.py +34 -11
  25. mage_ai/data_preparation/models/block/dbt/utils/__init__.py +37 -10
  26. mage_ai/data_preparation/models/block/integration/__init__.py +1 -1
  27. mage_ai/data_preparation/models/block/sql/__init__.py +44 -2
  28. mage_ai/data_preparation/models/custom_templates/utils.py +14 -4
  29. mage_ai/data_preparation/models/global_data_product/__init__.py +8 -0
  30. mage_ai/data_preparation/models/pipeline.py +4 -0
  31. mage_ai/data_preparation/models/variable.py +5 -2
  32. mage_ai/data_preparation/repo_manager.py +28 -16
  33. mage_ai/io/clickhouse.py +9 -6
  34. mage_ai/io/redshift.py +9 -10
  35. mage_ai/io/utils.py +3 -1
  36. mage_ai/orchestration/db/migrations/README.md +39 -2
  37. mage_ai/orchestration/db/migrations/env.py +1 -0
  38. mage_ai/orchestration/db/migrations/versions/386bcfebd48d_create_tag_and_tagassociation_tables.py +59 -0
  39. mage_ai/orchestration/db/models/schedules.py +29 -2
  40. mage_ai/orchestration/db/models/tags.py +57 -0
  41. mage_ai/orchestration/pipeline_scheduler.py +7 -7
  42. mage_ai/orchestration/triggers/global_data_product.py +41 -40
  43. mage_ai/orchestration/triggers/utils.py +11 -1
  44. mage_ai/server/constants.py +1 -1
  45. mage_ai/server/frontend_dist/404.html +2 -2
  46. mage_ai/server/frontend_dist/404.html.html +2 -2
  47. mage_ai/server/frontend_dist/_next/static/CNjkRIWPaAu1yJUmIaX_q/_buildManifest.js +1 -0
  48. mage_ai/server/frontend_dist/_next/static/chunks/1005-a2f0e3ee378ef02b.js +1 -0
  49. mage_ai/server/frontend_dist/_next/static/chunks/1424-fca78f21a81a7183.js +1 -0
  50. mage_ai/server/frontend_dist/_next/static/chunks/1484-87d4d4a698ac63dc.js +1 -0
  51. mage_ai/server/frontend_dist/_next/static/chunks/2485-39885e5335888821.js +1 -0
  52. mage_ai/server/frontend_dist/_next/static/chunks/2786-f71862671f66d948.js +1 -0
  53. mage_ai/server/frontend_dist/_next/static/chunks/3391-6f0a0a5c254cd7f2.js +1 -0
  54. mage_ai/server/frontend_dist/_next/static/chunks/3881-131cf690e54c23a3.js +1 -0
  55. mage_ai/server/frontend_dist/_next/static/chunks/437-331193bd9b2fe777.js +1 -0
  56. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/4822-045cc7cdd7c95163.js → frontend_dist/_next/static/chunks/4822-ee62acb1927c8150.js} +1 -1
  57. mage_ai/server/frontend_dist/_next/static/chunks/547-bd961ea93f3eb98b.js +1 -0
  58. mage_ai/server/frontend_dist/_next/static/chunks/6299-fcb702d0f3d3291b.js +1 -0
  59. mage_ai/server/frontend_dist/_next/static/chunks/6422-0cdd6e596dcd43b6.js +1 -0
  60. mage_ai/server/frontend_dist/_next/static/chunks/{6786-77c7e36678abb2c6.js → 6786-55e1bca3c897d5ee.js} +1 -1
  61. mage_ai/server/frontend_dist/_next/static/chunks/7496-7e4dd11e3f3b8e79.js +1 -0
  62. mage_ai/server/frontend_dist/_next/static/chunks/7722-76c724a66240561b.js +1 -0
  63. mage_ai/server/frontend_dist/_next/static/chunks/7815-8b68b0eb665fcd2d.js +1 -0
  64. mage_ai/server/frontend_dist/_next/static/chunks/8190-d38ed1133030797d.js +1 -0
  65. mage_ai/server/frontend_dist/_next/static/chunks/8952-9d6fa18fa9378989.js +1 -0
  66. mage_ai/server/frontend_dist/_next/static/chunks/9605-9332e1686c46da7d.js +1 -0
  67. mage_ai/server/frontend_dist/_next/static/chunks/pages/_app-9dae6fa5126cf001.js +1 -0
  68. mage_ai/server/frontend_dist/_next/static/chunks/pages/files-2dc2a0dfc0ff620d.js +1 -0
  69. mage_ai/server/frontend_dist/_next/static/chunks/pages/global-data-products/[...slug]-6d3d53624debede6.js +1 -0
  70. mage_ai/server/frontend_dist/_next/static/chunks/pages/global-data-products-2756fe6d9decae4a.js +1 -0
  71. mage_ai/server/frontend_dist/_next/static/chunks/pages/manage/settings-6577159a0af52a78.js +1 -0
  72. mage_ai/server/frontend_dist/_next/static/chunks/pages/manage-6815a3ece7dc1678.js +1 -0
  73. mage_ai/server/frontend_dist/_next/static/chunks/pages/overview-7f790238fe70d9ab.js +1 -0
  74. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipeline-runs-33c7f2550add0719.js +1 -0
  75. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills/[...slug]-07e4a3a674e83578.js +1 -0
  76. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills-b8b4bed1e8e50068.js +1 -0
  77. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/edit-54cb4936accdd2d9.js +1 -0
  78. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/logs-d331e98ad103b13e.js +1 -0
  79. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runs-d87d0c21758a2d7c.js +1 -0
  80. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runtime-68e1b861ef4fc0d7.js +1 -0
  81. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/monitors-9fa0c4ce1c921a41.js +1 -0
  82. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/runs/[run]-d5ef19ca1f9931de.js +1 -0
  83. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/runs-4a2671811a153411.js +1 -0
  84. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/settings-8872a6e00280f58c.js +1 -0
  85. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/syncs-484581ae34a1c596.js +1 -0
  86. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/triggers/[...slug]-ce11db27e4af7869.js +1 -0
  87. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/triggers-624a2d7cbe6303b4.js +1 -0
  88. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines-1169f4eecf752033.js +1 -0
  89. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/settings/account/profile-d2224a447987fa69.js → frontend_dist/_next/static/chunks/pages/settings/account/profile-c3ff06a12baa40a2.js} +1 -1
  90. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/preferences-60b4398d7ae00206.js +1 -0
  91. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/sync-data-dd827816bf4a7908.js → frontend_dist/_next/static/chunks/pages/settings/workspace/sync-data-05b53444f0e7449b.js} +1 -1
  92. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/sign-in-097aa0bef1e34cdb.js → frontend_dist/_next/static/chunks/pages/sign-in-a5e9561a6c0d2e38.js} +1 -1
  93. mage_ai/server/frontend_dist/_next/static/chunks/pages/templates/{[...slug]-78a07e7fe8973811.js → [...slug]-c21b269750441494.js} +1 -1
  94. mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/templates-19df643f52679d5a.js → frontend_dist/_next/static/chunks/pages/templates-ce2a29d477a6ce94.js} +1 -1
  95. mage_ai/server/frontend_dist/_next/static/chunks/pages/triggers-71bbb30dd9b57f80.js +1 -0
  96. mage_ai/server/frontend_dist/_next/static/chunks/pages/version-control-1dc780d52fbd1573.js +1 -0
  97. mage_ai/server/frontend_dist/files.html +2 -2
  98. mage_ai/server/frontend_dist/global-data-products/[...slug].html +2 -2
  99. mage_ai/server/frontend_dist/global-data-products.html +2 -2
  100. mage_ai/server/frontend_dist/index.html +2 -2
  101. mage_ai/server/frontend_dist/manage/settings.html +2 -2
  102. mage_ai/server/frontend_dist/manage/users/[user].html +2 -2
  103. mage_ai/server/frontend_dist/manage/users/new.html +2 -2
  104. mage_ai/server/frontend_dist/manage/users.html +2 -2
  105. mage_ai/server/frontend_dist/manage.html +2 -2
  106. mage_ai/server/frontend_dist/overview.html +2 -2
  107. mage_ai/server/frontend_dist/pipeline-runs.html +2 -2
  108. mage_ai/server/frontend_dist/pipelines/[pipeline]/backfills/[...slug].html +2 -2
  109. mage_ai/server/frontend_dist/pipelines/[pipeline]/backfills.html +2 -2
  110. mage_ai/server/frontend_dist/pipelines/[pipeline]/edit.html +2 -2
  111. mage_ai/server/frontend_dist/pipelines/[pipeline]/logs.html +2 -2
  112. mage_ai/server/frontend_dist/pipelines/[pipeline]/monitors/block-runs.html +2 -2
  113. mage_ai/server/frontend_dist/pipelines/[pipeline]/monitors/block-runtime.html +2 -2
  114. mage_ai/server/frontend_dist/pipelines/[pipeline]/monitors.html +2 -2
  115. mage_ai/server/frontend_dist/pipelines/[pipeline]/runs/[run].html +2 -2
  116. mage_ai/server/frontend_dist/pipelines/[pipeline]/runs.html +2 -2
  117. mage_ai/server/frontend_dist/pipelines/[pipeline]/settings.html +2 -2
  118. mage_ai/server/frontend_dist/pipelines/[pipeline]/syncs.html +2 -2
  119. mage_ai/server/frontend_dist/pipelines/[pipeline]/triggers/[...slug].html +2 -2
  120. mage_ai/server/frontend_dist/pipelines/[pipeline]/triggers.html +2 -2
  121. mage_ai/server/frontend_dist/pipelines/[pipeline].html +2 -2
  122. mage_ai/server/frontend_dist/pipelines.html +2 -2
  123. mage_ai/server/frontend_dist/settings/account/profile.html +2 -2
  124. mage_ai/server/frontend_dist/settings/workspace/preferences.html +2 -2
  125. mage_ai/server/frontend_dist/settings/workspace/sync-data.html +2 -2
  126. mage_ai/server/frontend_dist/settings/workspace/users.html +2 -2
  127. mage_ai/server/frontend_dist/settings.html +2 -2
  128. mage_ai/server/frontend_dist/sign-in.html +11 -11
  129. mage_ai/server/frontend_dist/templates/[...slug].html +2 -2
  130. mage_ai/server/frontend_dist/templates.html +2 -2
  131. mage_ai/server/frontend_dist/terminal.html +2 -2
  132. mage_ai/server/frontend_dist/test.html +3 -3
  133. mage_ai/server/frontend_dist/triggers.html +2 -2
  134. mage_ai/server/frontend_dist/version-control.html +2 -2
  135. mage_ai/server/frontend_dist_base_path_template/404.html +2 -2
  136. mage_ai/server/frontend_dist_base_path_template/404.html.html +2 -2
  137. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/1005-a2f0e3ee378ef02b.js +1 -0
  138. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/1424-fca78f21a81a7183.js +1 -0
  139. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/1484-87d4d4a698ac63dc.js +1 -0
  140. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/2485-39885e5335888821.js +1 -0
  141. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/2786-f71862671f66d948.js +1 -0
  142. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3391-6f0a0a5c254cd7f2.js +1 -0
  143. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3881-131cf690e54c23a3.js +1 -0
  144. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/437-331193bd9b2fe777.js +1 -0
  145. mage_ai/server/{frontend_dist/_next/static/chunks/4822-045cc7cdd7c95163.js → frontend_dist_base_path_template/_next/static/chunks/4822-ee62acb1927c8150.js} +1 -1
  146. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/547-bd961ea93f3eb98b.js +1 -0
  147. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/6299-fcb702d0f3d3291b.js +1 -0
  148. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/6422-0cdd6e596dcd43b6.js +1 -0
  149. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/{6786-77c7e36678abb2c6.js → 6786-55e1bca3c897d5ee.js} +1 -1
  150. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/7496-7e4dd11e3f3b8e79.js +1 -0
  151. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/7722-76c724a66240561b.js +1 -0
  152. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/7815-8b68b0eb665fcd2d.js +1 -0
  153. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/8190-d38ed1133030797d.js +1 -0
  154. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/8952-9d6fa18fa9378989.js +1 -0
  155. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/9605-9332e1686c46da7d.js +1 -0
  156. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/_app-9dae6fa5126cf001.js +1 -0
  157. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/files-2dc2a0dfc0ff620d.js +1 -0
  158. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/global-data-products/[...slug]-6d3d53624debede6.js +1 -0
  159. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/global-data-products-2756fe6d9decae4a.js +1 -0
  160. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/manage/settings-6577159a0af52a78.js +1 -0
  161. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/manage-6815a3ece7dc1678.js +1 -0
  162. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/overview-7f790238fe70d9ab.js +1 -0
  163. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipeline-runs-33c7f2550add0719.js +1 -0
  164. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/backfills/[...slug]-07e4a3a674e83578.js +1 -0
  165. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/backfills-b8b4bed1e8e50068.js +1 -0
  166. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/edit-54cb4936accdd2d9.js +1 -0
  167. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/logs-d331e98ad103b13e.js +1 -0
  168. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runs-d87d0c21758a2d7c.js +1 -0
  169. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runtime-68e1b861ef4fc0d7.js +1 -0
  170. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/monitors-9fa0c4ce1c921a41.js +1 -0
  171. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/runs/[run]-d5ef19ca1f9931de.js +1 -0
  172. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/runs-4a2671811a153411.js +1 -0
  173. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/settings-8872a6e00280f58c.js +1 -0
  174. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/syncs-484581ae34a1c596.js +1 -0
  175. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/triggers/[...slug]-ce11db27e4af7869.js +1 -0
  176. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/triggers-624a2d7cbe6303b4.js +1 -0
  177. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines-1169f4eecf752033.js +1 -0
  178. mage_ai/server/{frontend_dist/_next/static/chunks/pages/settings/account/profile-d2224a447987fa69.js → frontend_dist_base_path_template/_next/static/chunks/pages/settings/account/profile-c3ff06a12baa40a2.js} +1 -1
  179. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/preferences-60b4398d7ae00206.js +1 -0
  180. mage_ai/server/{frontend_dist/_next/static/chunks/pages/settings/workspace/sync-data-dd827816bf4a7908.js → frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/sync-data-05b53444f0e7449b.js} +1 -1
  181. mage_ai/server/{frontend_dist/_next/static/chunks/pages/sign-in-097aa0bef1e34cdb.js → frontend_dist_base_path_template/_next/static/chunks/pages/sign-in-a5e9561a6c0d2e38.js} +1 -1
  182. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/templates/{[...slug]-78a07e7fe8973811.js → [...slug]-c21b269750441494.js} +1 -1
  183. mage_ai/server/{frontend_dist/_next/static/chunks/pages/templates-19df643f52679d5a.js → frontend_dist_base_path_template/_next/static/chunks/pages/templates-ce2a29d477a6ce94.js} +1 -1
  184. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/triggers-71bbb30dd9b57f80.js +1 -0
  185. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/version-control-1dc780d52fbd1573.js +1 -0
  186. mage_ai/server/frontend_dist_base_path_template/_next/static/yJvL-3bfsNF3WCStZ10Dm/_buildManifest.js +1 -0
  187. mage_ai/server/frontend_dist_base_path_template/files.html +2 -2
  188. mage_ai/server/frontend_dist_base_path_template/global-data-products/[...slug].html +2 -2
  189. mage_ai/server/frontend_dist_base_path_template/global-data-products.html +2 -2
  190. mage_ai/server/frontend_dist_base_path_template/index.html +2 -2
  191. mage_ai/server/frontend_dist_base_path_template/manage/settings.html +2 -2
  192. mage_ai/server/frontend_dist_base_path_template/manage/users/[user].html +2 -2
  193. mage_ai/server/frontend_dist_base_path_template/manage/users/new.html +2 -2
  194. mage_ai/server/frontend_dist_base_path_template/manage/users.html +2 -2
  195. mage_ai/server/frontend_dist_base_path_template/manage.html +2 -2
  196. mage_ai/server/frontend_dist_base_path_template/overview.html +2 -2
  197. mage_ai/server/frontend_dist_base_path_template/pipeline-runs.html +2 -2
  198. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/backfills/[...slug].html +2 -2
  199. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/backfills.html +2 -2
  200. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/edit.html +2 -2
  201. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/logs.html +2 -2
  202. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/monitors/block-runs.html +2 -2
  203. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/monitors/block-runtime.html +2 -2
  204. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/monitors.html +2 -2
  205. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/runs/[run].html +2 -2
  206. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/runs.html +2 -2
  207. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/settings.html +2 -2
  208. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/syncs.html +2 -2
  209. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/triggers/[...slug].html +2 -2
  210. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/triggers.html +2 -2
  211. mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline].html +2 -2
  212. mage_ai/server/frontend_dist_base_path_template/pipelines.html +2 -2
  213. mage_ai/server/frontend_dist_base_path_template/settings/account/profile.html +2 -2
  214. mage_ai/server/frontend_dist_base_path_template/settings/workspace/preferences.html +2 -2
  215. mage_ai/server/frontend_dist_base_path_template/settings/workspace/sync-data.html +2 -2
  216. mage_ai/server/frontend_dist_base_path_template/settings/workspace/users.html +2 -2
  217. mage_ai/server/frontend_dist_base_path_template/settings.html +2 -2
  218. mage_ai/server/frontend_dist_base_path_template/sign-in.html +11 -11
  219. mage_ai/server/frontend_dist_base_path_template/templates/[...slug].html +2 -2
  220. mage_ai/server/frontend_dist_base_path_template/templates.html +2 -2
  221. mage_ai/server/frontend_dist_base_path_template/terminal.html +2 -2
  222. mage_ai/server/frontend_dist_base_path_template/test.html +3 -3
  223. mage_ai/server/frontend_dist_base_path_template/triggers.html +2 -2
  224. mage_ai/server/frontend_dist_base_path_template/version-control.html +2 -2
  225. mage_ai/server/server.py +53 -27
  226. mage_ai/services/spark/spark.py +75 -2
  227. mage_ai/streaming/constants.py +1 -0
  228. mage_ai/streaming/sources/kafka.py +17 -9
  229. mage_ai/tests/data_preparation/models/custom_templates/__init__.py +0 -0
  230. mage_ai/tests/data_preparation/models/custom_templates/test_utils.py +36 -0
  231. mage_ai/tests/data_preparation/models/test_block.py +48 -0
  232. mage_ai/tests/data_preparation/test_repo_manager.py +19 -1
  233. mage_ai/tests/server/test_server.py +20 -2
  234. mage_ai/tests/services/spark/__init__.py +0 -0
  235. mage_ai/tests/services/spark/test_spark.py +52 -0
  236. {mage_ai-0.9.12.dist-info → mage_ai-0.9.14.dist-info}/METADATA +1 -1
  237. {mage_ai-0.9.12.dist-info → mage_ai-0.9.14.dist-info}/RECORD +245 -233
  238. mage_ai/server/frontend_dist/_next/static/RdDEYzOW6lfmOEilKsz4V/_buildManifest.js +0 -1
  239. mage_ai/server/frontend_dist/_next/static/chunks/1005-2f8ef0e28c917767.js +0 -1
  240. mage_ai/server/frontend_dist/_next/static/chunks/1424-a2cd1bfc708a323b.js +0 -1
  241. mage_ai/server/frontend_dist/_next/static/chunks/1484-a07f74ae5c40141c.js +0 -1
  242. mage_ai/server/frontend_dist/_next/static/chunks/2485-b569baad92049d6b.js +0 -1
  243. mage_ai/server/frontend_dist/_next/static/chunks/2786-acce6ea0d9b4898e.js +0 -1
  244. mage_ai/server/frontend_dist/_next/static/chunks/3654-14ee3eacc42b118a.js +0 -1
  245. mage_ai/server/frontend_dist/_next/static/chunks/3881-0eb04f7f7a244347.js +0 -1
  246. mage_ai/server/frontend_dist/_next/static/chunks/437-d43ccff3a064a528.js +0 -1
  247. mage_ai/server/frontend_dist/_next/static/chunks/547-4ad2cdae967055b6.js +0 -1
  248. mage_ai/server/frontend_dist/_next/static/chunks/6299-cf188c1b7a1bc33c.js +0 -1
  249. mage_ai/server/frontend_dist/_next/static/chunks/7496-ab1be388ae09d362.js +0 -1
  250. mage_ai/server/frontend_dist/_next/static/chunks/7722-a74e6f977993e75e.js +0 -1
  251. mage_ai/server/frontend_dist/_next/static/chunks/7815-fbd99c8f259d9e8b.js +0 -1
  252. mage_ai/server/frontend_dist/_next/static/chunks/8952-98e54b14c1af492f.js +0 -1
  253. mage_ai/server/frontend_dist/_next/static/chunks/pages/_app-74805cf1296fd50f.js +0 -1
  254. mage_ai/server/frontend_dist/_next/static/chunks/pages/files-bcdaa82adcca891d.js +0 -1
  255. mage_ai/server/frontend_dist/_next/static/chunks/pages/global-data-products/[...slug]-abdbda772d94c386.js +0 -1
  256. mage_ai/server/frontend_dist/_next/static/chunks/pages/global-data-products-01f8ef10e87ec236.js +0 -1
  257. mage_ai/server/frontend_dist/_next/static/chunks/pages/manage/settings-950fbcb72961eb3c.js +0 -1
  258. mage_ai/server/frontend_dist/_next/static/chunks/pages/manage-c6fd44191c812edf.js +0 -1
  259. mage_ai/server/frontend_dist/_next/static/chunks/pages/overview-6e46ed84cf3f4e9d.js +0 -1
  260. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipeline-runs-1d52bba72442c53f.js +0 -1
  261. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills/[...slug]-8c33956a28fb4fa8.js +0 -1
  262. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills-b28d151c32c2a469.js +0 -1
  263. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/edit-e1708e5576cd26d1.js +0 -1
  264. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/logs-0f3468d52020dcbf.js +0 -1
  265. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runs-489d02937d5f4695.js +0 -1
  266. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runtime-544475d8e841638f.js +0 -1
  267. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/monitors-e117a99f334b6022.js +0 -1
  268. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/runs/[run]-f1ef481c7beb8aef.js +0 -1
  269. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/runs-ab52e3174c3dcf64.js +0 -1
  270. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/settings-3e290f7d76c68b3f.js +0 -1
  271. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/syncs-1ac4dc91ec394c6d.js +0 -1
  272. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/triggers/[...slug]-4753de69f7e366c5.js +0 -1
  273. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/triggers-cf285c43759e9b2a.js +0 -1
  274. mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines-3f86e7f1c8d63beb.js +0 -1
  275. mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/preferences-b2354688508b0755.js +0 -1
  276. mage_ai/server/frontend_dist/_next/static/chunks/pages/triggers-cacb24e3632cfdfc.js +0 -1
  277. mage_ai/server/frontend_dist/_next/static/chunks/pages/version-control-5a6e3a62fef551f1.js +0 -1
  278. mage_ai/server/frontend_dist_base_path_template/_next/static/4dbzHNz2XwS_s6Z0qsIGO/_buildManifest.js +0 -1
  279. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/1005-2f8ef0e28c917767.js +0 -1
  280. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/1424-a2cd1bfc708a323b.js +0 -1
  281. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/1484-a07f74ae5c40141c.js +0 -1
  282. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/2485-b569baad92049d6b.js +0 -1
  283. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/2786-acce6ea0d9b4898e.js +0 -1
  284. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3654-14ee3eacc42b118a.js +0 -1
  285. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3881-0eb04f7f7a244347.js +0 -1
  286. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/437-d43ccff3a064a528.js +0 -1
  287. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/547-4ad2cdae967055b6.js +0 -1
  288. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/6299-cf188c1b7a1bc33c.js +0 -1
  289. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/7496-ab1be388ae09d362.js +0 -1
  290. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/7722-a74e6f977993e75e.js +0 -1
  291. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/7815-fbd99c8f259d9e8b.js +0 -1
  292. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/8952-98e54b14c1af492f.js +0 -1
  293. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/_app-74805cf1296fd50f.js +0 -1
  294. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/files-bcdaa82adcca891d.js +0 -1
  295. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/global-data-products/[...slug]-abdbda772d94c386.js +0 -1
  296. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/global-data-products-01f8ef10e87ec236.js +0 -1
  297. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/manage/settings-950fbcb72961eb3c.js +0 -1
  298. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/manage-c6fd44191c812edf.js +0 -1
  299. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/overview-6e46ed84cf3f4e9d.js +0 -1
  300. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipeline-runs-1d52bba72442c53f.js +0 -1
  301. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/backfills/[...slug]-8c33956a28fb4fa8.js +0 -1
  302. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/backfills-b28d151c32c2a469.js +0 -1
  303. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/edit-e1708e5576cd26d1.js +0 -1
  304. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/logs-0f3468d52020dcbf.js +0 -1
  305. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runs-489d02937d5f4695.js +0 -1
  306. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/monitors/block-runtime-544475d8e841638f.js +0 -1
  307. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/monitors-e117a99f334b6022.js +0 -1
  308. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/runs/[run]-f1ef481c7beb8aef.js +0 -1
  309. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/runs-ab52e3174c3dcf64.js +0 -1
  310. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/settings-3e290f7d76c68b3f.js +0 -1
  311. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/syncs-1ac4dc91ec394c6d.js +0 -1
  312. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/triggers/[...slug]-4753de69f7e366c5.js +0 -1
  313. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/triggers-cf285c43759e9b2a.js +0 -1
  314. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines-3f86e7f1c8d63beb.js +0 -1
  315. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/preferences-b2354688508b0755.js +0 -1
  316. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/triggers-cacb24e3632cfdfc.js +0 -1
  317. mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/version-control-5a6e3a62fef551f1.js +0 -1
  318. /mage_ai/server/frontend_dist/_next/static/{RdDEYzOW6lfmOEilKsz4V → CNjkRIWPaAu1yJUmIaX_q}/_middlewareManifest.js +0 -0
  319. /mage_ai/server/frontend_dist/_next/static/{RdDEYzOW6lfmOEilKsz4V → CNjkRIWPaAu1yJUmIaX_q}/_ssgManifest.js +0 -0
  320. /mage_ai/server/frontend_dist_base_path_template/_next/static/{4dbzHNz2XwS_s6Z0qsIGO → yJvL-3bfsNF3WCStZ10Dm}/_middlewareManifest.js +0 -0
  321. /mage_ai/server/frontend_dist_base_path_template/_next/static/{4dbzHNz2XwS_s6Z0qsIGO → yJvL-3bfsNF3WCStZ10Dm}/_ssgManifest.js +0 -0
  322. {mage_ai-0.9.12.dist-info → mage_ai-0.9.14.dist-info}/LICENSE +0 -0
  323. {mage_ai-0.9.12.dist-info → mage_ai-0.9.14.dist-info}/WHEEL +0 -0
  324. {mage_ai-0.9.12.dist-info → mage_ai-0.9.14.dist-info}/entry_points.txt +0 -0
  325. {mage_ai-0.9.12.dist-info → mage_ai-0.9.14.dist-info}/top_level.txt +0 -0
@@ -1 +0,0 @@
1
- (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[643],{90659:function(e,n,t){"use strict";var r=t(67403),i={"text/plain":"Text","text/html":"Url",default:"Text"};e.exports=function(e,n){var t,o,l,c,s,u,a=!1;n||(n={}),t=n.debug||!1;try{if(l=r(),c=document.createRange(),s=document.getSelection(),(u=document.createElement("span")).textContent=e,u.ariaHidden="true",u.style.all="unset",u.style.position="fixed",u.style.top=0,u.style.clip="rect(0, 0, 0, 0)",u.style.whiteSpace="pre",u.style.webkitUserSelect="text",u.style.MozUserSelect="text",u.style.msUserSelect="text",u.style.userSelect="text",u.addEventListener("copy",(function(r){if(r.stopPropagation(),n.format)if(r.preventDefault(),"undefined"===typeof r.clipboardData){t&&console.warn("unable to use e.clipboardData"),t&&console.warn("trying IE specific stuff"),window.clipboardData.clearData();var o=i[n.format]||i.default;window.clipboardData.setData(o,e)}else r.clipboardData.clearData(),r.clipboardData.setData(n.format,e);n.onCopy&&(r.preventDefault(),n.onCopy(r.clipboardData))})),document.body.appendChild(u),c.selectNodeContents(u),s.addRange(c),!document.execCommand("copy"))throw new Error("copy command was unsuccessful");a=!0}catch(d){t&&console.error("unable to copy using execCommand: ",d),t&&console.warn("trying IE specific stuff");try{window.clipboardData.setData(n.format||"text",e),n.onCopy&&n.onCopy(window.clipboardData),a=!0}catch(d){t&&console.error("unable to copy using clipboardData: ",d),t&&console.error("falling back to prompt"),o=function(e){var n=(/mac os x/i.test(navigator.userAgent)?"\u2318":"Ctrl")+"+C";return e.replace(/#{\s*key\s*}/g,n)}("message"in n?n.message:"Copy to clipboard: #{key}, Enter"),window.prompt(o,e)}}finally{s&&("function"==typeof s.removeRange?s.removeRange(c):s.removeAllRanges()),u&&document.body.removeChild(u),l()}return a}},11984:function(e,n,t){"use strict";function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}Object.defineProperty(n,"__esModule",{value:!0}),n.CopyToClipboard=void 0;var i=c(t(82684)),o=c(t(90659)),l=["text","onCopy","options","children"];function c(e){return e&&e.__esModule?e:{default:e}}function s(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function u(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?s(Object(t),!0).forEach((function(n){j(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):s(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function a(e,n){if(null==e)return{};var t,r,i=function(e,n){if(null==e)return{};var t,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)t=o[r],n.indexOf(t)>=0||(i[t]=e[t]);return i}(e,n);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)t=o[r],n.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(i[t]=e[t])}return i}function d(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function p(e,n){for(var t=0;t<n.length;t++){var r=n[t];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function f(e,n){return f=Object.setPrototypeOf||function(e,n){return e.__proto__=n,e},f(e,n)}function h(e){var n=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var t,r=g(e);if(n){var i=g(this).constructor;t=Reflect.construct(r,arguments,i)}else t=r.apply(this,arguments);return m(this,t)}}function m(e,n){if(n&&("object"===r(n)||"function"===typeof n))return n;if(void 0!==n)throw new TypeError("Derived constructors may only return object or undefined");return v(e)}function v(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function g(e){return g=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},g(e)}function j(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}var x=function(e){!function(e,n){if("function"!==typeof n&&null!==n)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),n&&f(e,n)}(s,e);var n,t,r,c=h(s);function s(){var e;d(this,s);for(var n=arguments.length,t=new Array(n),r=0;r<n;r++)t[r]=arguments[r];return j(v(e=c.call.apply(c,[this].concat(t))),"onClick",(function(n){var t=e.props,r=t.text,l=t.onCopy,c=t.children,s=t.options,u=i.default.Children.only(c),a=(0,o.default)(r,s);l&&l(r,a),u&&u.props&&"function"===typeof u.props.onClick&&u.props.onClick(n)})),e}return n=s,(t=[{key:"render",value:function(){var e=this.props,n=(e.text,e.onCopy,e.options,e.children),t=a(e,l),r=i.default.Children.only(n);return i.default.cloneElement(r,u(u({},t),{},{onClick:this.onClick}))}}])&&p(n.prototype,t),r&&p(n,r),Object.defineProperty(n,"prototype",{writable:!1}),s}(i.default.PureComponent);n.CopyToClipboard=x,j(x,"defaultProps",{onCopy:void 0,options:void 0})},64866:function(e,n,t){"use strict";var r=t(11984).CopyToClipboard;r.CopyToClipboard=r,e.exports=r},67403:function(e){e.exports=function(){var e=document.getSelection();if(!e.rangeCount)return function(){};for(var n=document.activeElement,t=[],r=0;r<e.rangeCount;r++)t.push(e.getRangeAt(r));switch(n.tagName.toUpperCase()){case"INPUT":case"TEXTAREA":n.blur();break;default:n=null}return e.removeAllRanges(),function(){"Caret"===e.type&&e.removeAllRanges(),e.rangeCount||t.forEach((function(n){e.addRange(n)})),n&&n.focus()}}},70543:function(e,n,t){"use strict";t.d(n,{IY:function(){return o},Jf:function(){return i},NR:function(){return l},b7:function(){return r}});var r="edit",i={uuid:"All files"},o={uuid:"Files in pipeline"},l=[i,o]},2850:function(e,n,t){"use strict";t.d(n,{M:function(){return l},W:function(){return o}});var r=t(38626),i=t(3055),o=34*t(49125).iI,l=r.default.div.withConfig({displayName:"indexstyle__BeforeStyle",componentId:"sc-12ee2ib-0"})(["min-height:calc(100vh - ","px);"],i.Mz)},56681:function(e,n,t){"use strict";t.d(n,{G7:function(){return y},ZP:function(){return _},u$:function(){return x}});var r=t(75582),i=t(82394),o=t(26304),l=t(32316),c=t(22673),s=t(48952),u=t(86673),a=t(19711),d=t(87815),p=t(49125),f=t(19395),h=t(7715),m=t(28598),v=["height","heightOffset","pipeline","selectedRun","selectedTab","setSelectedTab"];function g(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function j(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 x=76,b={uuid:"Run details"},Z={uuid:"Dependency tree"},y=[Z,b];function _(e){var n=e.height,t=e.heightOffset,i=e.pipeline,g=e.selectedRun,_=e.selectedTab,O=e.setSelectedTab,P=j({},(0,o.Z)(e,v));g?P.blockStatus=(0,f.IJ)(null===g||void 0===g?void 0:g.block_runs):P.noStatus=!0;var w=(0,h.Kn)(null===g||void 0===g?void 0:g.variables)?j({},null===g||void 0===g?void 0:g.variables):(null===g||void 0===g?void 0:g.variables)||{},S=null===g||void 0===g?void 0:g.event_variables;if(S&&(0,h.Kn)(S)&&!(0,h.Qr)(S))if((0,h.Kn)(w)&&w.hasOwnProperty("event")){var k=(0,h.Kn)(w.event)?w.event:{};w.event=j(j({},k),S)}else w.event=j({},S);var I=[];w&&JSON.stringify(w,null,2).split("\n").forEach((function(e){I.push(" ".concat(e))}));var C=g&&[["Run ID",null===g||void 0===g?void 0:g.id],["Variables",(0,m.jsx)(c.Z,{language:"json",small:!0,source:I.join("\n")},"variable_value")]],E=g&&(0,m.jsx)(u.Z,{pb:p.cd,px:p.cd,children:(0,m.jsx)(d.Z,{alignTop:!0,columnFlex:[null,1],columnMaxWidth:function(e){return 1===e?"100px":null},rows:C.map((function(e,n){var t=(0,r.Z)(e,2),i=t[0],o=t[1];return[(0,m.jsx)(a.ZP,{monospace:!0,muted:!0,children:i},"key_".concat(n)),(0,m.jsx)(a.ZP,{monospace:!0,textOverflow:!0,children:o},"val_".concat(n))]})),uuid:"LogDetail"})}),T=_&&O;return(0,m.jsxs)(m.Fragment,{children:[T&&(0,m.jsx)(u.Z,{py:p.cd,children:(0,m.jsx)(l.Z,{onClickTab:O,selectedTabUUID:null===_||void 0===_?void 0:_.uuid,tabs:y})}),(!T||Z.uuid===(null===_||void 0===_?void 0:_.uuid))&&(0,m.jsx)(s.Z,j(j({},P),{},{height:n,heightOffset:(t||0)+(T?x:0),pipeline:i})),b.uuid===(null===_||void 0===_?void 0:_.uuid)&&E]})}},58122:function(e,n,t){"use strict";t.d(n,{FS:function(){return s},JZ:function(){return a},e7:function(){return d},wx:function(){return u}});var r=t(75582),i=t(82394),o=t(93348);function l(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function c(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?l(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):l(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function s(e){return"string"===typeof e?e:JSON.stringify(e)}function u(e,n){var t,r;return null===e||void 0===e||null===(t=e.find((function(e){var t=e.block;return n(t)})))||void 0===t||null===(r=t.variables)||void 0===r?void 0:r.map((function(e){var n=e.value;return c(c({},e),{},{value:s(n)})}))}function a(e,n){return n===o.Xm.TIME?e.push({uuid:"execution_date",value:"<run datetime>"}):n===o.Xm.EVENT&&e.push({uuid:"event",value:"<trigger event>"}),e}function d(e){return e?Object.entries(e).reduce((function(e,n){var t=(0,r.Z)(n,2),o=t[0],l=t[1],s=l;try{s=JSON.parse(l)}catch(u){}return c(c({},e),{},(0,i.Z)({},o,s))}),{}):e}},18025:function(e,n,t){"use strict";t.d(n,{J:function(){return s},U:function(){return c}});var r=t(38626),i=t(23831),o=t(73942),l=t(49125),c=r.default.div.withConfig({displayName:"indexstyle__CardStyle",componentId:"sc-m7tlau-0"})(["border-radius:","px;border-style:solid;border-width:2px;height:","px;margin-right:","px;padding:","px;width:","px;"," ",""],o.TR,14*l.iI,l.cd*l.iI,l.cd*l.iI,40*l.iI,(function(e){return!e.selected&&"\n border-color: ".concat((e.theme.borders||i.Z.borders).light,";\n ")}),(function(e){return e.selected&&"\n border-color: ".concat((e.theme.interactive||i.Z.interactive).linkPrimary,";\n ")})),s=r.default.div.withConfig({displayName:"indexstyle__DateSelectionContainer",componentId:"sc-m7tlau-1"})(["border-radius:","px;padding:","px;"," "," ",""],o.n_,l.tr,(function(e){return"\n background-color: ".concat((e.theme.interactive||i.Z.interactive).defaultBackground,";\n ")}),(function(e){return e.absolute&&"\n position: absolute;\n z-index: 2;\n right: 0;\n top: ".concat(2.5*l.iI,"px;\n ")}),(function(e){return e.topPosition&&"\n top: -".concat(42*l.iI,"px;\n ")}))},51099:function(e,n,t){"use strict";t.d(n,{Q:function(){return a}});t(82684);var r=t(60328),i=t(67971),o=t(86673),l=t(22341),c=t(73899),s=t(49125),u=t(28598),a=22;n.Z=function(e){var n=e.page,t=e.maxPages,a=e.onUpdate,d=e.totalPages,p=[],f=t;if(f>d)p=Array.from({length:d},(function(e,n){return n}));else{var h=Math.floor(f/2),m=n-h;n+h>=d?(m=d-f+2,f-=2):n-h<=0?(m=0,f-=2):(f-=4,m=n-Math.floor(f/2)),p=Array.from({length:f},(function(e,n){return n+m}))}return(0,u.jsx)(u.Fragment,{children:d>0&&(0,u.jsxs)(i.Z,{alignItems:"center",children:[(0,u.jsx)(r.Z,{disabled:0===n,onClick:function(){return a(n-1)},children:(0,u.jsx)(l.Hd,{size:1.5*s.iI,stroke:"#AEAEAE"})}),!p.includes(0)&&(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(o.Z,{ml:1,children:(0,u.jsx)(r.Z,{onClick:function(){return a(0)},borderLess:!0,noBackground:!0,children:1})},0),!p.includes(1)&&(0,u.jsx)(o.Z,{ml:1,children:(0,u.jsx)(r.Z,{notClickable:!0,noBackground:!0,noPadding:!0,children:"..."})},0)]}),p.map((function(e){return(0,u.jsx)(o.Z,{ml:1,children:(0,u.jsx)(r.Z,{onClick:function(){e!==n&&a(e)},notClickable:e===n,backgroundColor:e===n&&c.a$,borderLess:!0,noBackground:!0,children:e+1})},e)})),!p.includes(d-1)&&(0,u.jsxs)(u.Fragment,{children:[!p.includes(d-2)&&(0,u.jsx)(o.Z,{ml:1,children:(0,u.jsx)(r.Z,{notClickable:!0,noBackground:!0,noPadding:!0,children:"..."})},0),(0,u.jsx)(o.Z,{ml:1,children:(0,u.jsx)(r.Z,{onClick:function(){return a(d-1)},borderLess:!0,noBackground:!0,children:d})},d-1)]}),(0,u.jsx)(o.Z,{ml:1}),(0,u.jsx)(r.Z,{disabled:n===d-1,onClick:function(){return a(n+1)},children:(0,u.jsx)(l.Kw,{size:1.5*s.iI,stroke:"#AEAEAE"})})]})})}},52769:function(e,n,t){"use strict";t.d(n,{C:function(){return r}});var r="global"},2713:function(e,n,t){"use strict";var r=t(82394),i=t(44495),o=t(67971),l=t(55378),c=t(86673),s=t(19711),u=t(18025),a=t(49125),d=t(24224),p=t(28598);function f(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function h(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?f(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):f(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}n.Z=function(e){var n=e.selectedDate,t=e.selectedTime,r=e.setSelectedDate,f=e.setSelectedTime,m=e.topPosition;return(0,p.jsxs)(u.J,{absolute:!0,topPosition:m,children:[(0,p.jsx)(i.ZP,{onChange:r,value:n}),(0,p.jsx)(c.Z,{mb:2}),(0,p.jsxs)(o.Z,{alignItems:"center",children:[(0,p.jsx)(s.ZP,{default:!0,large:!0,children:"Time (UTC):"}),(0,p.jsx)(c.Z,{pr:2}),(0,p.jsx)(l.Z,{compact:!0,monospace:!0,onChange:function(e){e.preventDefault(),f((function(n){return h(h({},n),{},{hour:e.target.value})}))},paddingRight:5*a.iI,placeholder:"HH",value:null===t||void 0===t?void 0:t.hour,children:(0,d.m5)(24,0).map((function(e){return String(e).padStart(2,"0")})).map((function(e){return(0,p.jsx)("option",{value:e,children:e},"hour_".concat(e))}))}),(0,p.jsx)(c.Z,{px:1,children:(0,p.jsx)(s.ZP,{bold:!0,large:!0,children:":"})}),(0,p.jsx)(l.Z,{compact:!0,monospace:!0,onChange:function(e){e.preventDefault(),f((function(n){return h(h({},n),{},{minute:e.target.value})}))},paddingRight:5*a.iI,placeholder:"MM",value:null===t||void 0===t?void 0:t.minute,children:(0,d.m5)(60,0).map((function(e){return String(e).padStart(2,"0")})).map((function(e){return(0,p.jsx)("option",{value:e,children:e},"minute_".concat(e))}))})]})]})}},22673:function(e,n,t){"use strict";var r=t(82684),i=t(68792),o=t(31811),l=t(38626),c=t(65292),s=t(23831),u=t(2005),a=t(49125),d=t(28598);n.Z=function(e){var n=e.language,t=e.maxWidth,p=e.showLineNumbers,f=e.small,h=e.source,m=e.wrapLines,v=(0,r.useContext)(l.ThemeContext);function g(e){var r=e.value;return(0,d.jsx)(o.Z,{customStyle:{backgroundColor:(v.background||s.Z.background).popup,border:"none",borderRadius:"none",boxShadow:"none",fontFamily:u.Vp,fontSize:f?12:14,marginBottom:0,marginTop:0,maxWidth:t,paddingBottom:2*a.iI,paddingTop:2*a.iI},language:n,lineNumberStyle:{color:(v.content||s.Z.content).muted},showLineNumbers:p,style:c._4,useInlineStyles:!0,wrapLines:m,children:r})}return(0,d.jsx)(i.D,{components:{code:function(e){var n=e.children;return(0,d.jsx)(g,{value:n})}},children:h})}},65730:function(e,n,t){"use strict";var r,i=t(82394),o=(t(82684),t(64866)),l=t(21764),c=t(67971),s=t(10919),u=t(86673),a=t(19711),d=t(46261),p=t(22341),f=t(49125),h=t(28598);function m(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function v(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?m(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):m(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}!function(e){e.LEFT="left",e.RIGHT="right"}(r||(r={})),n.Z=function(e){var n,t=e.children,i=e.copiedText,m=e.iconPosition,g=void 0===m?r.LEFT:m,j=e.inverted,x=e.linkProps,b=e.linkText,Z=e.monospace,y=e.muted,_=e.small,O=e.toastMessage,P=e.withCopyIcon;return t?n=(0,h.jsx)("span",{children:t}):P&&(n=(0,h.jsx)(s.Z,v(v({href:"#",inline:!0,muted:y,preventDefault:!0,sameColorAsText:!0,small:_},x),{},{children:(0,h.jsxs)(c.Z,{alignItems:"center",children:[g===r.LEFT&&(0,h.jsx)(u.Z,{mr:b?1:0,children:(0,h.jsx)(c.Z,{alignItems:"center",children:(0,h.jsx)(p.CK,{inverted:j,muted:y,size:2*f.iI})})}),b&&(0,h.jsx)(a.ZP,{inverted:j,monospace:Z,muted:y,small:_,children:b}),g===r.RIGHT&&(0,h.jsx)(u.Z,{ml:b?1:0,children:(0,h.jsx)(c.Z,{alignItems:"center",children:(0,h.jsx)(p.CK,{inverted:j,muted:y})})})]})}))),(0,h.jsx)(d.Z,{block:!0,label:"Copy",size:null,widthFitContent:!0,children:(0,h.jsx)(o.CopyToClipboard,{onCopy:function(){return l.Am.success(O||"Successfully copied to clipboard.",{position:l.Am.POSITION.BOTTOM_RIGHT,toastId:i})},text:i,children:n})})}},32316:function(e,n,t){"use strict";t.d(n,{Z:function(){return v}});var r=t(82684),i=t(60328),o=t(67971),l=t(882),c=t(86673),s=t(19711),u=t(99994),a=t(38626),d=t(49125),p=t(37391),f=a.default.div.withConfig({displayName:"indexstyle__TabsContainerStyle",componentId:"sc-segf7l-0"})(["padding-left:","px;padding-right:","px;"," "," ",""],d.cd*d.iI,d.cd*d.iI,(function(e){return e.noPadding&&"\n padding: 0;\n "}),(function(e){return e.allowScroll&&"\n overflow: auto;\n "}),p.w5),h=t(66653),m=t(28598);var v=function(e){var n=e.allowScroll,t=e.compact,a=e.contained,p=e.noPadding,v=e.onClickTab,g=e.regularSizeText,j=e.selectedTabUUID,x=e.small,b=e.tabs,Z=(0,r.useMemo)((function(){var e=b.length,n=[];return b.forEach((function(r,a){var p=r.Icon,f=r.IconSelected,b=r.label,Z=r.uuid,y=Z===j,_=y&&f||p,O=b?b():Z,P=(0,m.jsxs)(o.Z,{alignItems:"center",children:[_&&(0,m.jsxs)(m.Fragment,{children:[(0,m.jsx)(_,{default:!y,size:2*d.iI}),(0,m.jsx)(c.Z,{mr:1})]}),(0,m.jsx)(s.ZP,{bold:!0,default:!y,noWrapping:!0,small:!g,children:O})]});a>=1&&e>=2&&n.push((0,m.jsx)("div",{style:{marginLeft:1.5*d.iI}},"spacing-".concat(Z))),y?n.push((0,m.jsx)(l.Z,{backgroundGradient:u.yr,backgroundPanel:!0,borderLess:!0,borderWidth:2,compact:t||x,onClick:function(e){(0,h.j)(e),v(r)},paddingUnitsHorizontal:1.75,paddingUnitsVertical:1.25,small:x,children:P},Z)):n.push((0,m.jsx)("div",{style:{padding:2},children:(0,m.jsx)(i.Z,{borderLess:!0,compact:t||x,default:!0,onClick:function(e){(0,h.j)(e),v(r)},outline:!0,small:x,children:P})},"button-tab-".concat(Z)))})),n}),[t,v,j,x,b]),y=(0,m.jsx)(o.Z,{alignItems:"center",children:Z});return a?y:(0,m.jsx)(f,{allowScroll:n,noPadding:p,children:y})}},70422:function(e,n,t){"use strict";t.r(n),t.d(n,{default:function(){return Le}});var r,i=t(75582),o=t(77837),l=t(82394),c=t(38860),s=t.n(c),u=t(82684),a=t(83455),d=t(34376),p=t(60328),f=t(34744),h=t(67971),m=t(87372),v=t(10919),g=t(51099),j=t(60547),x=t(97496),b=t(47409),Z=t(93348),y=t(52769),_=t(55378),O=t(86673),P=t(54283),w=t(87815),S=t(19711),k=t(46261),I=t(82531),C=t(56681),E=t(2850),T=t(86422),D=t(22341),M=t(49125),N=t(59920),A=t(24224);!function(e){e.AWS="aws_event"}(r||(r={}));var U=[{label:function(){return"AWS"},uuid:r.AWS}],R=(0,A.HK)(U,(function(e){return e.uuid})),H=t(66050),F=t(58122),L=t(19395),W=t(25958),z=t(33766),q=t(7715),V=t(9736),B=t(96510),X=t(66653),K=t(59e3),Y=t(28598);function J(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function G(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?J(Object(t),!0).forEach((function(n){(0,l.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):J(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var Q=function(e){var n=e.errors,t=e.fetchPipelineSchedule,r=e.pipeline,o=e.pipelineSchedule,l=e.setErrors,c=e.variables,s=(0,d.useRouter)(),U=(0,V.Ct)(),J=(r||{}).uuid,Q=o||{},$=Q.id,ee=Q.event_matchers,ne=Q.name,te=Q.schedule_interval,re=Q.schedule_type,ie=Q.settings,oe=Q.sla,le=Q.start_time,ce=Q.status,se=Q.variables,ue=void 0===se?{}:se,ae=(0,K.iV)(),de={_limit:30,_offset:30*(null!==ae&&void 0!==ae&&ae.page?ae.page:0)};null!==ae&&void 0!==ae&&ae.status&&(de.status=ae.status),null!==o&&void 0!==o&&o.global_data_product_uuid&&(de.global_data_product_uuid=null===o||void 0===o?void 0:o.global_data_product_uuid);var pe=I.ZP.pipeline_runs.pipeline_schedules.list($,de,{refreshInterval:3e3,revalidateOnFocus:!0}),fe=pe.data,he=pe.mutate,me=(0,u.useMemo)((function(){return(null===fe||void 0===fe?void 0:fe.pipeline_runs)||[]}),[fe]),ve=(0,u.useMemo)((function(){var e;return(null===fe||void 0===fe||null===(e=fe.metadata)||void 0===e?void 0:e.count)||[]}),[fe]),ge=(0,u.useState)(null),je=ge[0],xe=ge[1],be=(0,u.useMemo)((function(){var e=null!==ae&&void 0!==ae&&ae.page?ae.page:0;return(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)(x.Z,{fetchPipelineRuns:he,onClickRow:function(e){return xe((function(n){var t=me[e];return(null===n||void 0===n?void 0:n.id)!==t.id?t:null}))},pipelineRuns:me,selectedRun:je,setErrors:l}),(0,Y.jsx)(O.Z,{p:2,children:(0,Y.jsx)(g.Z,{maxPages:9,onUpdate:function(e){var n=Number(e),t=G(G({},ae),{},{page:n>=0?n:0});s.push("/pipelines/[pipeline]/triggers/[...slug]","/pipelines/".concat(J,"/triggers/").concat($,"?").concat((0,K.uM)(t)))},page:Number(e),totalPages:Math.ceil(ve/30)})})]})}),[he,me,$,J,ae,s,je,l,ve]),Ze=(0,u.useState)(C.G7[0]),ye=Ze[0],_e=Ze[1],Oe=(0,a.Db)((function(e){return I.ZP.pipeline_schedules.useUpdate(e.id)({pipeline_schedule:(0,q.gR)(e,["id"])})}),{onSuccess:function(e){return(0,B.wD)(e,{callback:function(){t()},onErrorCallback:function(e,n){return l({errors:n,response:e})}})}}),Pe=(0,i.Z)(Oe,2),we=Pe[0],Se=Pe[1].isLoading,ke=I.ZP.pipeline_triggers.pipelines.list(J),Ie=ke.data,Ce=ke.mutate,Ee=(0,u.useMemo)((function(){return(0,A.HK)((null===Ie||void 0===Ie?void 0:Ie.pipeline_triggers)||[],(function(e){return e.name}))}),[Ie]),Te=(0,u.useMemo)((function(){return!(null===Ee||void 0===Ee||!Ee[null===o||void 0===o?void 0:o.name])}),[o,Ee]),De=(0,a.Db)(I.ZP.pipeline_triggers.pipelines.useCreate(J),{onSuccess:function(e){return(0,B.wD)(e,{callback:function(){Ce()},onErrorCallback:function(e,n){return l({errors:n,response:e})}})}}),Me=(0,i.Z)(De,2),Ne=Me[0],Ae=Me[1].isLoading,Ue=(0,u.useMemo)((function(){return Z.fq.ACTIVE===ce}),[ce]),Re=(0,u.useMemo)((function(){var e,n,t={default:!0,size:1.5*M.iI},r=[[(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(D.VW,G({},t)),(0,Y.jsx)(O.Z,{mr:1}),(0,Y.jsx)(S.ZP,{default:!0,children:"Trigger type"})]},"trigger_type_label"),(0,Y.jsx)(S.ZP,{monospace:!0,children:null===(e=Z.Z4[re])||void 0===e?void 0:e.call(Z.Z4)},"trigger_type")],[(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(D.rs,G({},t)),(0,Y.jsx)(O.Z,{mr:1}),(0,Y.jsx)(S.ZP,{default:!0,children:"Status"})]},"trigger_status_label"),(0,Y.jsx)(S.ZP,{danger:!Ue,monospace:!0,success:Ue,children:ce},"trigger_status")]];if(oe){var i=(0,L.gU)(oe),o=i.time,l=i.unit,c=1===o?l:"".concat(l,"s");r.push([(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(D.kI,G({},t)),(0,Y.jsx)(O.Z,{mr:1}),(0,Y.jsx)(S.ZP,{default:!0,children:"SLA"})]},"trigger_sla_label"),(0,Y.jsx)(S.ZP,{monospace:!0,children:"".concat(o," ").concat(c)},"trigger_sla")])}(te&&r.push([(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(D.Pf,G({},t)),(0,Y.jsx)(O.Z,{mr:1}),(0,Y.jsx)(S.ZP,{default:!0,children:"Frequency"})]},"trigger_frequency_label"),(0,Y.jsx)(S.ZP,{monospace:!0,children:te.replace("@","")},"trigger_frequency")]),le&&r.push([(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(D.aw,G({},t)),(0,Y.jsx)(O.Z,{mr:1}),(0,Y.jsx)(S.ZP,{default:!0,children:"Start date"})]},"trigger_start_date_label"),(0,Y.jsx)(S.ZP,{monospace:!0,children:le},"trigger_start_date")]),null!==ie&&void 0!==ie&&ie.skip_if_previous_running)&&r.push([(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(k.Z,{default:!0,label:"Skip current run if any previous runs are still in progress",size:1.5*M.iI,widthFitContent:!0}),(0,Y.jsx)(O.Z,{mr:1}),(0,Y.jsx)(S.ZP,{default:!0,children:"Skip if running"})]},"trigger_skip_if_running"),(0,Y.jsx)(S.ZP,{monospace:!0,children:null===(n=ie.skip_if_previous_running)||void 0===n?void 0:n.toString()},"trigger_skip_if_running_label")]);return null!==ie&&void 0!==ie&&ie.allow_blocks_to_fail&&r.push([(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(k.Z,{default:!0,label:"Trigger runs will continue running blocks if other unrelated blocks fail",size:1.5*M.iI,widthFitContent:!0}),(0,Y.jsx)(O.Z,{mr:1}),(0,Y.jsx)(S.ZP,{default:!0,children:"Allow blocks to fail"})]},"trigger_allow_blocks_to_fail"),(0,Y.jsx)(S.ZP,{monospace:!0,children:ie.allow_blocks_to_fail.toString()},"trigger_allow_blocks_to_fail_label")]),(0,Y.jsx)(w.Z,{columnFlex:[null,1],rows:r})}),[Ue,te,re,ie,oe,le,ce]),He=(0,u.useMemo)((function(){return ue||{}}),[ue]),Fe=(0,u.useMemo)((function(){var e,n=[];return(0,q.Qr)(He)?n=(0,F.wx)(c,(function(e){return e.uuid===y.C})):Object.entries(He).forEach((function(e){var t=(0,i.Z)(e,2),r=t[0],o=t[1];b.sZ!==r&&n.push({uuid:r,value:(0,F.FS)(o)})})),"undefined"!==typeof(n=(0,F.JZ)(n||[],re))&&null!==(e=n)&&void 0!==e&&e.length?(0,Y.jsx)(w.Z,{columnFlex:[null,1],rows:n.map((function(e){var n=e.uuid,t=e.value;return[(0,Y.jsx)(S.ZP,{default:!0,monospace:!0,small:!0,children:n},"settings_variable_label_".concat(n)),(0,Y.jsx)(S.ZP,{monospace:!0,small:!0,children:t},"settings_variable_".concat(n))]}))}):null}),[re,He,c]),Le=(0,u.useMemo)((function(){var e,n,t=[],i=null===He||void 0===He||null===(e=He[b.sZ])||void 0===e?void 0:e.blocks;return null===r||void 0===r||null===(n=r.blocks)||void 0===n||n.forEach((function(e){var n=e.type,r=e.uuid;if(T.tf.DBT===n){var o,l=(null===i||void 0===i||null===(o=i[r])||void 0===o?void 0:o.configuration)||{},c=l.flags,s=l.prefix,u=l.suffix,a=(0,W.IU)(e).name;(c||s||u)&&t.push({flags:c,prefix:s,suffix:u,uuid:a})}})),"undefined"!==typeof t&&null!==t&&void 0!==t&&t.length?(0,Y.jsx)(w.Z,{columnFlex:[1,null],rows:t.map((function(e){var n=e.flags,t=e.prefix,r=e.suffix,i=e.uuid;return[(0,Y.jsxs)(S.ZP,{monospace:!0,small:!0,children:[t&&(0,Y.jsx)(S.ZP,{inline:!0,monospace:!0,muted:!0,small:!0,children:t}),i,r&&(0,Y.jsx)(S.ZP,{inline:!0,monospace:!0,muted:!0,small:!0,children:r})]},"settings_variable_label_".concat(i)),(0,Y.jsx)(S.ZP,{monospace:!0,muted:!0,small:!0,children:n&&n.join(", ")},"settings_variable_".concat(i))]}))}):null}),[r,He]),We=(0,u.useMemo)((function(){return(0,Y.jsx)(w.Z,{columnFlex:[null,1],columns:[{uuid:"Provider"},{uuid:"Event"}],rows:null===ee||void 0===ee?void 0:ee.map((function(e,n){var t=e.event_type,r=e.name;return[(0,Y.jsx)(S.ZP,{default:!0,monospace:!0,children:R[t].label()},"".concat(t,"_").concat(n,"_label")),(0,Y.jsx)(S.ZP,{monospace:!0,children:r},"".concat(t,"_").concat(n,"_name"))]}))})}),[ee]);return(0,Y.jsxs)(j.Z,{afterHidden:!je,before:(0,Y.jsxs)(E.M,{children:[(0,Y.jsxs)(O.Z,{mb:M.HN,pt:M.cd,px:M.cd,children:[(0,Y.jsxs)(O.Z,{mb:M.cd,children:[Z.Xm.TIME===re&&(0,Y.jsx)(D.kO,{size:5*M.iI}),Z.Xm.EVENT===re&&(0,Y.jsx)(D.Jp,{size:5*M.iI}),Z.Xm.API===re&&(0,Y.jsx)(D.Bf,{size:5*M.iI}),!re&&(0,Y.jsx)(D.VW,{size:5*M.iI})]}),(0,Y.jsx)(m.Z,{children:ne})]}),(0,Y.jsx)(O.Z,{px:M.cd,children:(0,Y.jsx)(m.Z,{level:5,children:"Settings"})}),(0,Y.jsx)(f.Z,{light:!0,mt:1,short:!0}),Re,(null===ee||void 0===ee?void 0:ee.length)>=1&&(0,Y.jsxs)(O.Z,{my:M.HN,children:[(0,Y.jsx)(O.Z,{px:M.cd,children:(0,Y.jsx)(m.Z,{level:5,children:"Events"})}),(0,Y.jsx)(f.Z,{light:!0,mt:1,short:!0}),We]}),Fe&&(0,Y.jsxs)(O.Z,{my:M.HN,children:[(0,Y.jsx)(O.Z,{px:M.cd,children:(0,Y.jsx)(m.Z,{level:5,children:"Runtime variables"})}),(0,Y.jsx)(f.Z,{light:!0,mt:1,short:!0}),Fe]}),Le&&(0,Y.jsxs)(O.Z,{my:M.HN,children:[(0,Y.jsx)(O.Z,{px:M.cd,children:(0,Y.jsx)(m.Z,{level:5,children:"dbt runtime settings"})}),(0,Y.jsx)(f.Z,{light:!0,mt:1,short:!0}),Le]}),(0,Y.jsx)(O.Z,{my:M.HN,children:(0,Y.jsxs)(O.Z,{px:M.cd,children:[(0,Y.jsxs)(m.Z,{level:5,children:[Te&&"Trigger exists in code",!Te&&"Store trigger in code"]}),(0,Y.jsx)(O.Z,{mt:1,children:(0,Y.jsxs)(S.ZP,{default:!0,children:["Save or update the trigger and its settings in the pipeline\u2019s metadata and version control the trigger using Git. For more information, please read the ",(0,Y.jsx)(v.Z,{href:"https://docs.mage.ai/guides/triggers/configure-triggers-in-code",openNewWindow:!0,children:"documentation"}),"."]})}),(0,Y.jsxs)(O.Z,{mt:M.cd,children:[!Ie&&(0,Y.jsx)(P.Z,{inverted:!0}),Ie&&(0,Y.jsxs)(p.Z,{disabled:!(null!==o&&void 0!==o&&o.id),loading:Ae,onClick:function(){Ne({pipeline_trigger:{pipeline_schedule_id:null===o||void 0===o?void 0:o.id}})},secondary:!0,children:[Te&&"Update trigger in code",!Te&&"Save trigger in code"]})]})]})})]}),beforeWidth:E.W,breadcrumbs:[{label:function(){return"Triggers"},linkProps:{as:"/pipelines/".concat(J,"/triggers"),href:"/pipelines/[pipeline]/triggers"}},{label:function(){return ne},linkProps:{as:"/pipelines/".concat(J,"/triggers/").concat($),href:"/pipelines/[pipeline]/triggers/[...slug]"}}],buildSidekick:function(e){return(0,C.ZP)(G(G({},e),{},{selectedRun:je,selectedTab:ye,setSelectedTab:_e}))},errors:n,pageName:N.M.TRIGGERS,pipeline:r,setErrors:l,subheader:(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(p.Z,{beforeIcon:Ue?(0,Y.jsx)(D.dz,{size:2*M.iI}):(0,Y.jsx)(D.Py,{inverted:!U,size:2*M.iI}),danger:Ue&&!U,loading:Se,onClick:function(e){(0,X.j)(e),we({id:$,status:Ue?Z.fq.INACTIVE:Z.fq.ACTIVE})},outline:!0,success:!Ue&&!U,children:Ue?"Pause trigger":"Start trigger"}),(0,Y.jsx)(O.Z,{mr:M.cd}),!U&&(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)(p.Z,{linkProps:{as:"/pipelines/".concat(J,"/triggers/").concat($,"/edit"),href:"/pipelines/[pipeline]/triggers/[...slug]"},noHoverUnderline:!0,outline:!0,sameColorAsText:!0,children:"Edit trigger"}),(0,Y.jsx)(O.Z,{mr:M.cd})]}),(0,Y.jsxs)(_.Z,{compact:!0,defaultColor:!0,onChange:function(e){e.preventDefault(),"all"===e.target.value?s.push("/pipelines/[pipeline]/triggers/[...slug]","/pipelines/".concat(J,"/triggers/").concat($)):(0,z.u7)({page:0,status:e.target.value})},paddingRight:4*M.iI,placeholder:"Select run status",value:(null===ae||void 0===ae?void 0:ae.status)||"all",children:[(0,Y.jsx)("option",{value:"all",children:"All statuses"},"all_statuses"),Object.values(H.V).map((function(e){return(0,Y.jsx)("option",{value:e,children:b.Do[e]},e)}))]})]}),title:function(){return ne},uuid:"triggers/detail",children:[(0,Y.jsx)(O.Z,{mt:M.cd,px:M.cd,children:(0,Y.jsx)(m.Z,{level:5,children:"Runs for this trigger"})}),(0,Y.jsx)(f.Z,{light:!0,mt:M.cd,short:!0}),be]})},$=t(21831),ee=t(92083),ne=t.n(ee),te=t(21764),re=t(2713),ie=t(38341),oe=t(47999),le=t(22673),ce=t(65730),se=t(38626),ue=t(16634),ae=t(82944),de=t(44162);function pe(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function fe(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?pe(Object(t),!0).forEach((function(n){(0,l.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):pe(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var he=function(e){var n=e.blocks,t=e.updateVariables,r=e.variables,i=(0,u.useContext)(se.ThemeContext),o=(0,u.useCallback)((function(e,n){return t((function(){var t=(null===r||void 0===r?void 0:r.__mage_variables)||{},i=(null===t||void 0===t?void 0:t.blocks)||{},o=i[e]||{},c=(null===o||void 0===o?void 0:o.configuration)||{};return fe(fe({},r),{},{__mage_variables:fe(fe({},t),{},{blocks:fe(fe({},i),{},(0,l.Z)({},e,fe(fe({},o),{},{configuration:fe(fe({},c),n)})))})})}))}),[t,r]);return(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)(m.Z,{children:"dbt runtime settings"}),(0,Y.jsx)(O.Z,{mt:M.Mq,children:(0,Y.jsx)(w.Z,{columnFlex:[1,null,null,null],columns:[{uuid:"Block"},{uuid:"Flags"},{uuid:"Prefix"},{uuid:"Suffix"}],compact:!0,rows:null===n||void 0===n?void 0:n.map((function(e){var n,t,l,c=e.type,s=e.uuid,u=(0,W.IU)(e).name,a=(0,de.qn)(c,{blockColor:e.color,theme:i}).accent,d=null===r||void 0===r||null===(n=r.__mage_variables)||void 0===n||null===(t=n.blocks)||void 0===t||null===(l=t[s])||void 0===l?void 0:l.configuration,p=d||{},f=p.prefix,m=p.suffix,v=(null===d||void 0===d?void 0:d.flags)||[],g=!(null===v||void 0===v||!v.includes(W.Dy));return[(0,Y.jsx)(k.Z,{block:!0,label:(0,Y.jsx)(S.ZP,{monospace:!0,small:!0,children:s}),size:null,widthFitContent:!0,children:(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(ue.Z,{color:a,size:1.5*M.iI,square:!0}),(0,Y.jsx)(O.Z,{mr:1}),(0,Y.jsxs)(S.ZP,{monospace:!0,small:!0,children:[f&&(0,Y.jsx)(S.ZP,{default:!0,inline:!0,monospace:!0,small:!0,children:f}),u,m&&(0,Y.jsx)(S.ZP,{default:!0,inline:!0,monospace:!0,small:!0,children:m})]})]})},"uuid-".concat(s)),(0,Y.jsx)(h.Z,{alignItems:"center",children:(0,Y.jsx)(ie.Z,{checked:g,label:W.Dy,monospace:!0,onClick:function(){return o(s,{flags:g?(0,A.Od)(v,(function(e){return W.Dy===e})):v.concat(W.Dy)})},small:!0})},"flags-".concat(s)),(0,Y.jsx)(ae.Z,{compact:!0,monospace:!0,onChange:function(e){return o(s,{prefix:e.target.value})},placeholder:"N+, +",small:!0,value:f,width:10*M.iI},"prefix-".concat(s)),(0,Y.jsx)(ae.Z,{compact:!0,monospace:!0,onChange:function(e){return o(s,{suffix:e.target.value})},placeholder:"+, +N",small:!0,value:m,width:10*M.iI},"suffix-".concat(s))]}))})})]})},me=t(93461),ve=t(26304),ge=t(23831),je=t(2005),xe=t(31012),be=["children","large","lineHeight","ordered"];function Ze(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function ye(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?Ze(Object(t),!0).forEach((function(n){(0,l.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):Ze(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var _e=(0,se.css)([""," "," "," "," "," "," "," "," "," ",""],(function(e){return!e.muted&&"\n color: ".concat((e.theme.content||ge.Z.content).default,";\n ")}),(function(e){return e.muted&&"\n color: ".concat((e.theme.content||ge.Z.content).muted,";\n ")}),(function(e){return e.inverted&&"\n color: ".concat((e.theme.content||ge.Z.content).inverted,";\n ")}),(function(e){return e.color&&"\n color: ".concat(e.color,";\n ")}),(function(e){return!e.monospace&&"\n font-family: ".concat(je.ry,";\n ")}),(function(e){return e.monospace&&"\n font-family: ".concat(je.Vp,";\n ")}),(function(e){return e.large&&"\n ".concat(xe.x_,"\n ")}),(function(e){return!e.large&&!e.small&&"\n ".concat(xe.i3,"\n ")}),(function(e){return e.small&&"\n ".concat(xe.J5,"\n ")}),(function(e){return e.lineHeight&&"\n line-height: ".concat(e.lineHeight,"px !important;\n ")})),Oe=se.default.ul.withConfig({displayName:"List__UnorderedListStyle",componentId:"sc-1f6yhbi-0"})(["",""],_e),Pe=se.default.ol.withConfig({displayName:"List__OrderedListStyle",componentId:"sc-1f6yhbi-1"})(["",""],_e),we=se.default.li.withConfig({displayName:"List__ListItemStyle",componentId:"sc-1f6yhbi-2"})(["",""],(function(e){return e.large&&e.marginTop&&"\n margin-top: ".concat(1*M.iI,"px;\n ")}));var Se=function(e){var n=e.children,t=e.large,r=e.lineHeight,i=e.ordered,o=(0,ve.Z)(e,be),l=i?Pe:Oe;return(0,Y.jsx)(l,ye(ye({large:t,lineHeight:r},o),{},{children:u.Children.map(n,(function(e,n){var r;return(0,Y.jsx)(we,ye(ye({large:t,marginTop:n>=1},o),{},{children:u.cloneElement(e)}),(null===(r=e.props)||void 0===r?void 0:r.key)||n)}))}))},ke=t(98781),Ie=t(70902),Ce=t(18025),Ee=t(90211);function Te(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function De(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?Te(Object(t),!0).forEach((function(n){(0,l.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):Te(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var Me=function(e){var n=[{description:function(){return"This pipeline will run continuously on an interval or just once."},label:function(){return"Schedule"},uuid:Z.Xm.TIME},{description:function(){return"This pipeline will run when a specific event occurs."},label:function(){return"Event"},uuid:Z.Xm.EVENT},{description:function(){return"Run this pipeline when you make an API call."},label:function(){return"API"},uuid:Z.Xm.API}];return e?n.slice(0,1):n};var Ne=function(e){var n=e.errors,t=e.fetchPipelineSchedule,r=e.pipeline,o=e.pipelineSchedule,c=e.setErrors,s=e.variables,g=(0,d.useRouter)(),x=null===r||void 0===r?void 0:r.uuid,P=null===o||void 0===o?void 0:o.id,k=(null===r||void 0===r?void 0:r.type)===ke.qL.STREAMING,C=(0,u.useState)([]),E=C[0],R=C[1],H=(0,u.useState)(!1),W=H[0],z=H[1],V=(0,u.useState)(!1),X=V[0],K=V[1],J=(0,u.useState)(),G=J[0],Q=J[1],ee=(0,u.useState)({}),se=ee[0],ue=ee[1],de=(0,u.useState)(null),pe=de[0],fe=de[1],ve=(0,u.useState)(!1),ge=ve[0],je=ve[1],xe=(0,u.useState)(null),be=xe[0],Ze=xe[1],ye=(0,u.useMemo)((function(){return(0,F.wx)(s,(function(e){return e.uuid===y.C}))}),[s]),_e=pe||{},Oe=_e.name,Pe=_e.schedule_interval,we=_e.schedule_type,Te=_e.settings,Ne=void 0===Te?{}:Te,Ae=(_e.sla,_e.start_time),Ue=_e.variables,Re=void 0===Ue?{}:Ue;(0,u.useEffect)((function(){Ne&&Q(Ne)}),[Ne]);var He=(0,u.useState)(null),Fe=He[0],Le=He[1],We=(0,u.useState)({hour:"00",minute:"00"}),ze=We[0],qe=We[1],Ve=(0,u.useState)({dayOfMonth:null,dayOfWeek:null,hour:null,minute:null,second:null}),Be=Ve[0],Xe=Ve[1],Ke=I.ZP.event_rules.detail(Z.Xm.EVENT===we?"aws":null).data,Ye=(0,u.useMemo)((function(){var e;return(null===Ke||void 0===Ke||null===(e=Ke.event_rule)||void 0===e?void 0:e.rules)||[]}),[Ke]),Je=(0,u.useMemo)((function(){return(0,A.HK)(Ye,(function(e){return e.name}))}),[Ye]),Ge=(0,a.Db)(I.ZP.pipeline_schedules.useUpdate(P),{onSuccess:function(e){return(0,B.wD)(e,{callback:function(){t(),g.push("/pipelines/[pipeline]/triggers/[...slug]","/pipelines/".concat(x,"/triggers/").concat(P))},onErrorCallback:function(e,n){return c({errors:n,response:e})}})}}),Qe=(0,i.Z)(Ge,2),$e=Qe[0],en=Qe[1].isLoading,nn=(0,u.useMemo)((function(){return Re||{}}),[Re]);(0,u.useEffect)((function(){if(Ae){var e=Ae.split(" ")[1];Le((0,L.eI)(Ae)),qe({hour:e.substring(0,2),minute:e.substring(3,5)});var n=ne()(Ae).utc();Xe({dayOfMonth:n.date(),dayOfWeek:n.day(),hour:n.hours(),minute:n.minutes(),second:n.seconds()})}else{var t=new Date;Le(t),qe({hour:String(t.getUTCHours()).padStart(2,"0"),minute:String(t.getUTCMinutes()).padStart(2,"0")})}}),[Ae]),(0,u.useEffect)((function(){nn&&Object.keys(nn).length>0&&z(!0)}),[nn]),(0,u.useEffect)((function(){ue(W?null===ye||void 0===ye?void 0:ye.reduce((function(e,n){var t=n.uuid,r=n.value;return De(De({},e),{},(0,l.Z)({},t,nn[t]||r))}),{}):null)}),[ye,W,nn]);var tn=(0,u.useMemo)((function(){return Pe&&!Object.values(Z.U5).includes(Pe)}),[Pe]);(0,u.useEffect)((function(){if(o&&!pe){R(o.event_matchers),(null===o||void 0===o?void 0:o.schedule_interval)&&!Object.values(Z.U5).includes(null===o||void 0===o?void 0:o.schedule_interval)?(Ze(null===o||void 0===o?void 0:o.schedule_interval),fe(De(De({},o),{},{schedule_interval:"custom"}))):fe(k?De(De({},o),{},{schedule_interval:Z.U5.ONCE}):o);var e=o.sla;if(e){K(!0);var n=(0,L.gU)(e),t=n.time,r=n.unit;fe((function(e){return De(De({},e),{},{slaAmount:t,slaUnit:r})}))}}}),[k,o,pe,Pe]);var rn=(0,u.useMemo)((function(){return!(null===G||void 0===G||!G.landing_time_enabled)}),[G]),on=(0,u.useMemo)((function(){return Z.Xm.TIME!==we||![Z.U5.DAILY,Z.U5.HOURLY,Z.U5.MONTHLY,Z.U5.WEEKLY].includes(Pe)}),[Pe,we]),ln=(0,u.useMemo)((function(){return rn&&!on}),[on,rn]),cn=(0,u.useCallback)((function(){var e=De(De({},(0,q.GL)(pe,["name","schedule_type"])),{},{event_matchers:[],schedule_interval:null,start_time:null,variables:(0,F.e7)(se)});if(ln){var n=Be.dayOfMonth,t=Be.dayOfWeek,r=Be.hour,i=Be.minute,l=Be.second,c=ne()("2023-07-01").utc();(0,Ee.HW)(n)&&(c=c.date(n)),(0,Ee.HW)(t)&&(c=c.day(t)),(0,Ee.HW)(r)&&(c=c.hours(r)),(0,Ee.HW)(i)&&(c=c.minutes(i)),(0,Ee.HW)(l)&&(c=c.seconds(l)),e.schedule_interval=tn?be:pe.schedule_interval,e.start_time=c.toISOString()}else Z.Xm.EVENT===pe.schedule_type?e.event_matchers=E:(e.schedule_interval=tn?be:pe.schedule_interval,e.start_time=Fe&&null!==ze&&void 0!==ze&&ze.hour&&null!==ze&&void 0!==ze&&ze.minute?"".concat(Fe.toISOString().split("T")[0]," ").concat(null===ze||void 0===ze?void 0:ze.hour,":").concat(null===ze||void 0===ze?void 0:ze.minute,":00"):null);if(X){var s=null===pe||void 0===pe?void 0:pe.slaAmount,u=null===pe||void 0===pe?void 0:pe.slaUnit;if(!s||isNaN(s)||!u)return void te.Am.error("Please enter a valid SLA",{position:te.Am.POSITION.BOTTOM_RIGHT,toastId:"sla_error"});e.sla=(0,L.vJ)(s,u)}else null!==o&&void 0!==o&&o.sla&&(e.sla=0);e.settings=G,$e({pipeline_schedule:e})}),[be,Fe,X,E,tn,Be,o,se,pe,G,ln,ze,$e]),sn=(0,u.useMemo)((function(){if(null===o||void 0===o||!o.runtime_average)return"Trigger doesn\u2019t have enough history to estimate runtime.";var e=Number(null===o||void 0===o?void 0:o.runtime_average),n=Math.max(Math.floor(e/3600),0),t=Math.max(Math.floor((e-60*n*60)/60),0),r=Math.max(Math.floor(e-(60*n*60+60*t)),0),i=[];return n>=1&&i.push((0,Ee._6)("hour",n,!0)),t>=1&&i.push((0,Ee._6)("minute",t,!0)),r>=1&&i.push((0,Ee._6)("second",r,!0)),i.join(" ")}),[o]),un=(0,u.useMemo)((function(){if(!ln)return null;var e=[(0,Y.jsxs)(O.Z,{mr:1,children:[(0,Y.jsx)(O.Z,{mb:1,children:(0,Y.jsx)(S.ZP,{bold:!0,default:!0,small:!0,children:"Minute"})}),(0,Y.jsxs)(_.Z,{compact:!0,monospace:!0,onChange:function(e){Xe((function(n){return De(De({},n),{},{minute:e.target.value})}))},value:(null===Be||void 0===Be?void 0:Be.minute)||"",children:[(0,Y.jsx)("option",{value:""}),(0,A.w6)(60).map((function(e,n){return(0,Y.jsx)("option",{value:n,children:n>=10?String(n):"0".concat(n)},n)}))]})]},"Minute"),(0,Y.jsxs)(O.Z,{mr:1,children:[(0,Y.jsx)(O.Z,{mb:1,children:(0,Y.jsx)(S.ZP,{bold:!0,default:!0,small:!0,children:"Second"})}),(0,Y.jsxs)(_.Z,{compact:!0,monospace:!0,onChange:function(e){Xe((function(n){return De(De({},n),{},{second:e.target.value})}))},value:(null===Be||void 0===Be?void 0:Be.second)||"",children:[(0,Y.jsx)("option",{value:""}),(0,A.w6)(60).map((function(e,n){return(0,Y.jsx)("option",{value:n,children:n>=10?String(n):"0".concat(n)},n)}))]})]},"Second")];return[Z.U5.DAILY,Z.U5.MONTHLY,Z.U5.WEEKLY].includes(Pe)&&e.unshift((0,Y.jsxs)(O.Z,{mr:1,children:[(0,Y.jsx)(O.Z,{mb:1,children:(0,Y.jsx)(S.ZP,{bold:!0,default:!0,small:!0,children:"Hour"})}),(0,Y.jsxs)(_.Z,{compact:!0,monospace:!0,onChange:function(e){Xe((function(n){return De(De({},n),{},{hour:e.target.value})}))},value:(null===Be||void 0===Be?void 0:Be.hour)||"",children:[(0,Y.jsx)("option",{value:""}),(0,A.w6)(24).map((function(e,n){return(0,Y.jsx)("option",{value:n,children:n>=10?String(n):"0".concat(n)},n)}))]})]},"Hour")),Z.U5.WEEKLY===Pe?e.unshift((0,Y.jsxs)(O.Z,{mr:1,children:[(0,Y.jsx)(O.Z,{mb:1,children:(0,Y.jsx)(S.ZP,{bold:!0,default:!0,small:!0,children:"Day of the week"})}),(0,Y.jsxs)(_.Z,{compact:!0,monospace:!0,onChange:function(e){Xe((function(n){return De(De({},n),{},{dayOfWeek:e.target.value})}))},value:(null===Be||void 0===Be?void 0:Be.dayOfWeek)||"",children:[(0,Y.jsx)("option",{value:""}),(0,Y.jsx)("option",{value:6,children:"Sunday"}),(0,Y.jsx)("option",{value:0,children:"Monday"}),(0,Y.jsx)("option",{value:1,children:"Tuesday"}),(0,Y.jsx)("option",{value:2,children:"Wednesday"}),(0,Y.jsx)("option",{value:3,children:"Thursday"}),(0,Y.jsx)("option",{value:4,children:"Friday"}),(0,Y.jsx)("option",{value:5,children:"Saturday"})]})]},"Day of the week")):Z.U5.MONTHLY===Pe&&e.unshift((0,Y.jsxs)(O.Z,{mr:1,children:[(0,Y.jsx)(O.Z,{mb:1,children:(0,Y.jsx)(S.ZP,{bold:!0,default:!0,small:!0,children:"Day of the month"})}),(0,Y.jsxs)(_.Z,{compact:!0,monospace:!0,onChange:function(e){Xe((function(n){return De(De({},n),{},{dayOfMonth:e.target.value})}))},value:(null===Be||void 0===Be?void 0:Be.dayOfMonth)||"",children:[(0,Y.jsx)("option",{value:""}),(0,A.w6)(31).map((function(e,n){return(0,Y.jsx)("option",{value:n+1,children:n+1>=10?String(n+1):"0".concat(n+1)},n+1)}))]})]},"Day of the month")),(0,Y.jsx)(h.Z,{children:e})}),[Be,Pe,ln]),an=(0,u.useMemo)((function(){var e=[[(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(D.KJ,{default:!0,size:1.5*M.iI}),(0,Y.jsx)(O.Z,{mr:1}),(0,Y.jsx)(S.ZP,{default:!0,children:"Trigger name"})]},"trigger_name_detail"),(0,Y.jsx)(ae.Z,{monospace:!0,onChange:function(e){e.preventDefault(),fe((function(n){return De(De({},n),{},{name:e.target.value})}))},placeholder:"Name this trigger",value:Oe},"trigger_name_input_detail")],[(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(D.Pf,{default:!0,size:1.5*M.iI}),(0,Y.jsx)(O.Z,{mr:1}),(0,Y.jsx)(S.ZP,{default:!0,children:"Frequency"})]},"frequency"),(0,Y.jsxs)("div",{children:[(0,Y.jsxs)(_.Z,{monospace:!0,onChange:function(e){e.preventDefault();var n=e.target.value;fe((function(e){return De(De({},e),{},{schedule_interval:n})}))},placeholder:"Choose the frequency to run",value:Pe,children:[Object.values(Z.U5).map((function(e){return(0,Y.jsx)("option",{value:e,children:e.substring(1)},e)})),(0,Y.jsx)("option",{value:"custom",children:"custom"},"custom")]}),(0,Y.jsx)(O.Z,{mt:1,p:1,children:(0,Y.jsxs)(S.ZP,{muted:!0,small:!0,children:["If you don\u2019t see the frequency option you need, select ",(0,Y.jsx)(S.ZP,{inline:!0,monospace:!0,small:!0,children:"custom"})," and enter CRON syntax."]})})]},"frequency_input")]];return ln&&(e.push([(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(D.rs,{default:!0,size:1.5*M.iI}),(0,Y.jsx)(O.Z,{mr:1}),(0,Y.jsx)(S.ZP,{default:!0,children:"Enable landing time"})]},"frequency"),(0,Y.jsxs)("div",{children:[(0,Y.jsx)(Ie.Z,{checked:rn,disabled:on,onCheck:function(){Q((function(e){return De(De({},e),{},{landing_time_enabled:!rn})}))}}),(0,Y.jsxs)(O.Z,{mt:1,p:1,children:[on&&(0,Y.jsxs)(S.ZP,{muted:!0,small:!0,children:["In order to enable landing time, the trigger\u2019s frequency must be ",Z.U5.HOURLY,", ",Z.U5.DAILY,", ",Z.U5.WEEKLY,", or ",Z.U5.MONTHLY,"."]}),!on&&(0,Y.jsx)(S.ZP,{muted:!0,small:!0,children:"Instead of starting at a specific time, this trigger will schedule pipeline runs at a time where it will finish by the specified time below."})]})]},"frequency_input")]),e.push([(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(D.Pf,{default:!0,size:1.5*M.iI}),(0,Y.jsx)(O.Z,{mr:1}),(0,Y.jsx)(S.ZP,{default:!0,children:"Average runtime"})]},"runtime_average"),(0,Y.jsx)(h.Z,{alignItems:"center",style:{minHeight:"".concat(5.75*M.iI,"px")},children:(0,Y.jsx)(S.ZP,{monospace:!0,children:sn})},"runtime_average_value")])),e.push([(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(D.aw,{default:!0,size:1.5*M.iI}),(0,Y.jsx)(O.Z,{mr:1}),(0,Y.jsxs)(S.ZP,{default:!0,children:[ln&&"Pipeline complete by",!ln&&"Start date and time"]})]},"start_time"),ln?un:(0,Y.jsxs)("div",{style:{minHeight:"".concat(5.75*M.iI,"px")},children:[!ge&&(0,Y.jsx)(ae.Z,{monospace:!0,onClick:function(){return je((function(e){return!e}))},placeholder:"YYYY-MM-DD HH:MM",value:Fe?"".concat(Fe.toISOString().split("T")[0]," ").concat(null===ze||void 0===ze?void 0:ze.hour,":").concat(null===ze||void 0===ze?void 0:ze.minute):""}),(0,Y.jsx)("div",{style:{width:"400px"},children:(0,Y.jsx)(oe.Z,{disableEscape:!0,onClickOutside:function(){return je(!1)},open:ge,style:{position:"relative"},children:(0,Y.jsx)(re.Z,{selectedDate:Fe,selectedTime:ze,setSelectedDate:Le,setSelectedTime:qe,topPosition:!0})})})]},"start_time_input")]),k&&e.splice(1,1),tn&&e.splice(2,0,[(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(D.EK,{default:!0,size:1.5*M.iI}),(0,Y.jsx)(O.Z,{mr:1}),(0,Y.jsx)(S.ZP,{default:!0,children:"Cron expression"})]},"cron_expression"),(0,Y.jsxs)("div",{children:[(0,Y.jsx)(ae.Z,{monospace:!0,onChange:function(e){e.preventDefault(),Ze(e.target.value)},placeholder:"* * * * *",value:be}),(0,Y.jsxs)(O.Z,{mt:1,p:1,children:[(0,Y.jsxs)(S.ZP,{muted:!0,small:!0,children:["If you want this pipeline to trigger every 1 minute, the CRON syntax is ",(0,Y.jsx)(S.ZP,{inline:!0,monospace:!0,small:!0,children:"*/1 * * * *"}),"."]}),(0,Y.jsxs)(S.ZP,{muted:!0,small:!0,children:["For more CRON syntax examples, check out this ",(0,Y.jsx)(v.Z,{href:"https://crontab.guru/",openNewWindow:!0,small:!0,children:"resource"}),"."]})]})]},"cron_expression_input")]),(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)(O.Z,{mb:2,px:M.cd,children:(0,Y.jsx)(m.Z,{children:"Settings"})}),(0,Y.jsx)(f.Z,{light:!0,short:!0}),(0,Y.jsx)(w.Z,{columnFlex:[null,1],rows:e})]})}),[be,Fe,tn,k,on,rn,un,Oe,sn,Pe,ge,ln,ze]),dn=(0,u.useCallback)((function(e,n){R((function(t){return Object.entries(n).forEach((function(n){var r=(0,i.Z)(n,2),o=r[0],l=r[1];t[e][o]=l})),(0,$.Z)(t)}))}),[R]),pn=(0,u.useMemo)((function(){return(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)(O.Z,{mb:M.cd,px:M.cd,children:(0,Y.jsx)(m.Z,{children:"Settings"})}),(0,Y.jsx)(f.Z,{light:!0,short:!0}),(0,Y.jsx)(w.Z,{columnFlex:[null,1],rows:[[(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(D.KJ,{default:!0,size:1.5*M.iI}),(0,Y.jsx)(O.Z,{mr:1}),(0,Y.jsx)(S.ZP,{default:!0,children:"Trigger name"})]},"trigger_name_event"),(0,Y.jsx)(ae.Z,{monospace:!0,onChange:function(e){e.preventDefault(),fe((function(n){return De(De({},n),{},{name:e.target.value})}))},placeholder:"Name this trigger",value:Oe},"trigger_name_input_event")]]}),(0,Y.jsxs)(O.Z,{mb:2,mt:5,px:M.cd,children:[(0,Y.jsx)(m.Z,{children:"Events"}),(0,Y.jsxs)(S.ZP,{muted:!0,children:["Add 1 or more event that will trigger this pipeline to run.",(0,Y.jsx)("br",{}),"If you add more than 1 event, this pipeline will trigger if any of the events are received."]}),(0,Y.jsxs)(O.Z,{mt:M.Mq,children:[(0,Y.jsx)(S.ZP,{bold:!0,large:!0,children:"AWS events"}),(0,Y.jsxs)(S.ZP,{muted:!0,children:["In order to retrieve all the possible AWS events you can trigger your pipeline from,",(0,Y.jsx)("br",{}),"you\u2019ll need to set 3 environment variables (",(0,Y.jsx)(v.Z,{href:"https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-envvars.html",openNewWindow:!0,underline:!0,children:"more info here"}),"):"]}),(0,Y.jsx)(O.Z,{mt:1,children:(0,Y.jsxs)(Se,{monospace:!0,ordered:!0,children:[(0,Y.jsx)(S.ZP,{monospace:!0,children:"AWS_REGION_NAME"}),(0,Y.jsx)(S.ZP,{monospace:!0,children:"AWS_ACCESS_KEY_ID"}),(0,Y.jsx)(S.ZP,{monospace:!0,children:"AWS_SECRET_ACCESS_KEY"})]})})]})]}),(0,Y.jsx)(f.Z,{light:!0,short:!0}),(null===E||void 0===E?void 0:E.length)>=1&&(0,Y.jsx)(w.Z,{alignTop:!0,columnFlex:[1,1,2,null],columns:[{uuid:"Provider"},{uuid:"Event"},{uuid:"Pattern"},{label:function(){return""},uuid:"delete"}],rows:null===E||void 0===E?void 0:E.map((function(e,n){var t=e.event_type,r=e.name,i=e.pattern,o=e.id||"".concat(t,"-").concat(r,"-").concat(n,"-").concat(JSON.stringify(i)),l=[];return i&&JSON.stringify(i,null,2).split("\n").forEach((function(e){l.push(" ".concat(e))})),[(0,Y.jsx)(_.Z,{monospace:!0,onChange:function(e){return dn(n,{event_type:e.target.value})},placeholder:"Event provider",value:t||"",children:U.map((function(e){var n=e.label,t=e.uuid;return(0,Y.jsx)("option",{value:t,children:n()},t)}))},"event-provider-".concat(o)),(0,Y.jsx)(_.Z,{monospace:!0,onChange:function(e){var t,r=e.target.value,i=null===(t=Je[r])||void 0===t?void 0:t.event_pattern;dn(n,{name:r,pattern:i?JSON.parse(i):null})},placeholder:"Event name",value:r,children:Ye.map((function(e){var n=e.name;return(0,Y.jsx)("option",{value:n,children:n},n)}))},"event-name-".concat(o)),i&&(0,Y.jsx)(le.Z,{language:"json",small:!0,source:l.join("\n")}),(0,Y.jsx)(p.Z,{default:!0,iconOnly:!0,noBackground:!0,onClick:function(){return R((function(e){return(0,A.oM)(e,n)}))},children:(0,Y.jsx)(D.rF,{default:!0,size:2*M.iI})},"remove_event")]}))}),(0,Y.jsx)(O.Z,{p:M.cd,children:(0,Y.jsx)(p.Z,{beforeIcon:(0,Y.jsx)(D.mm,{size:2*M.iI}),onClick:function(){return R((function(e){return e.concat({})}))},outline:!0,children:"Add event matcher"})})]})}),[E,Ye,Je,Oe,dn]),fn=!0,hn=(0,u.useMemo)((function(){var e,n="";return n="".concat(window.origin,"/api/pipeline_schedules/").concat(null===o||void 0===o?void 0:o.id,"/pipeline_runs"),null!==o&&void 0!==o&&o.token&&(n="".concat(n,"/").concat(o.token)),(e=window.location.port)&&(n=n.replace(e,"6789")),(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)(O.Z,{mb:M.cd,px:M.cd,children:(0,Y.jsx)(m.Z,{children:"Settings"})}),(0,Y.jsx)(f.Z,{light:!0,short:!0}),(0,Y.jsx)(w.Z,{columnFlex:[null,1],rows:[[(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(D.KJ,{default:!0,size:1.5*M.iI}),(0,Y.jsx)(O.Z,{mr:1}),(0,Y.jsx)(S.ZP,{default:!0,children:"Trigger name"})]},"trigger_name_api"),(0,Y.jsx)(ae.Z,{monospace:!0,onChange:function(e){e.preventDefault(),fe((function(n){return De(De({},n),{},{name:e.target.value})}))},placeholder:"Name this trigger",value:Oe},"trigger_name_input_api")]]}),(0,Y.jsxs)(O.Z,{mb:2,mt:5,px:M.cd,children:[(0,Y.jsx)(m.Z,{children:"Endpoint"}),(0,Y.jsxs)(S.ZP,{muted:!0,children:["Make a ",(0,Y.jsx)(S.ZP,{bold:!0,inline:!0,monospace:!0,children:"POST"})," request to the following endpoint:"]}),(0,Y.jsx)(O.Z,{mt:M.Mq,children:(0,Y.jsx)(ce.Z,{copiedText:n,linkText:n,monospace:!0,withCopyIcon:!0})})]}),(0,Y.jsxs)(O.Z,{mb:2,mt:5,px:M.cd,children:[(0,Y.jsx)(m.Z,{children:"Payload"}),(0,Y.jsx)(S.ZP,{muted:!0,children:"You can optionally include runtime variables in your request payload. These runtime variables are accessible from within each pipeline block."}),(0,Y.jsx)(O.Z,{mt:M.Mq,children:(0,Y.jsx)(ce.Z,{withCopyIcon:!0,copiedText:'{\n "pipeline_run": {\n "variables": {\n "key1": "value1",\n "key2": "value2"\n }\n }\n}\n',children:(0,Y.jsx)(le.Z,{language:"json",small:!0,source:'\n {\n "pipeline_run": {\n "variables": {\n "key1": "value1",\n "key2": "value2"\n }\n }\n }\n'})})})]}),(0,Y.jsxs)(O.Z,{mb:2,mt:5,px:M.cd,children:[(0,Y.jsx)(m.Z,{children:"Sample cURL command"}),(0,Y.jsx)(O.Z,{mt:M.Mq,children:(0,Y.jsx)(le.Z,{language:"bash",small:!0,source:"\n curl -X POST ".concat(n,' \\\n --header \'Content-Type: application/json\' \\\n --data \'\n {\n "pipeline_run": {\n "variables": {\n "key1": "value1",\n "key2": "value2"\n }\n }\n }\'\n')})})]})]})}),[Oe,o,fn]),mn=!we||Z.Xm.TIME===we&&!(k&&Fe||!k&&Fe&&Pe)||Z.Xm.EVENT===we&&(!(null!==E&&void 0!==E&&E.length)||!E.every((function(e){var n=e.event_type,t=e.name;return n&&t}))),vn=(0,u.useMemo)((function(){var e;return(null===r||void 0===r||null===(e=r.blocks)||void 0===e?void 0:e.filter((function(e){var n=e.type;return T.tf.DBT===n})))||[]}),[r]),gn=(0,u.useMemo)((function(){return(0,Y.jsxs)(O.Z,{p:M.cd,children:[(0,Y.jsxs)(O.Z,{mb:M.HN,children:[(0,Y.jsx)(m.Z,{children:"Pipeline run settings"}),(0,Y.jsx)(O.Z,{mt:M.Mq,children:(0,Y.jsx)(h.Z,{alignItems:"center",children:(0,Y.jsx)(ie.Z,{checked:null===G||void 0===G?void 0:G.allow_blocks_to_fail,label:"Keep running pipeline even if blocks fail",onClick:function(){return Q((function(e){return De(De({},e),{},{allow_blocks_to_fail:!(null!==G&&void 0!==G&&G.allow_blocks_to_fail)})}))}})})}),Z.Xm.TIME===we&&(0,Y.jsx)(O.Z,{mt:M.Mq,children:(0,Y.jsx)(h.Z,{alignItems:"center",children:(0,Y.jsx)(ie.Z,{checked:null===G||void 0===G?void 0:G.skip_if_previous_running,label:"Skip run if previous run still in progress",onClick:function(){return Q((function(e){return De(De({},e),{},{skip_if_previous_running:!(null!==G&&void 0!==G&&G.skip_if_previous_running)})}))}})})}),(0,Y.jsxs)(O.Z,{mt:M.Mq,children:[(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(O.Z,{mr:2,children:(0,Y.jsx)(Ie.Z,{checked:X,onCheck:function(e){K(e),e||fe((function(e){return De(De({},e),{},{slaAmount:0})}))}})}),(0,Y.jsx)(S.ZP,{default:!0,monospace:!0,children:"Configure trigger SLA"})]}),X&&(0,Y.jsx)(w.Z,{columnFlex:[null,1],rows:[[(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(D.aw,{default:!0,size:1.5*M.iI}),(0,Y.jsx)(O.Z,{mr:1}),(0,Y.jsx)(S.ZP,{default:!0,children:"SLA"})]},"sla_detail"),(0,Y.jsxs)(h.Z,{children:[(0,Y.jsx)(me.Z,{flex:1,children:(0,Y.jsx)(ae.Z,{fullWidth:!0,monospace:!0,noBorder:!0,onChange:function(e){e.preventDefault(),fe((function(n){return De(De({},n),{},{slaAmount:e.target.value})}))},placeholder:"Time",value:null===pe||void 0===pe?void 0:pe.slaAmount})}),(0,Y.jsx)(me.Z,{flex:1,children:(0,Y.jsx)(_.Z,{fullWidth:!0,monospace:!0,noBorder:!0,onChange:function(e){e.preventDefault(),fe((function(n){return De(De({},n),{},{slaUnit:e.target.value})}))},placeholder:"Select time unit",small:!0,value:null===pe||void 0===pe?void 0:pe.slaUnit,children:Object.keys(L.tL).map((function(e){return(0,Y.jsx)("option",{value:e,children:"".concat(e,"(s)")},e)}))})})]},"sla_input_detail")]]})]})]}),(0,Y.jsxs)(O.Z,{mb:M.HN,children:[(0,Y.jsx)(m.Z,{children:"Runtime variables"}),!(0,q.Qr)(ye)&&(0,Y.jsxs)(O.Z,{mt:M.Mq,children:[(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(O.Z,{mr:2,children:(0,Y.jsx)(Ie.Z,{checked:W,onCheck:z})}),(0,Y.jsx)(S.ZP,{monospace:!0,muted:!0,children:"Overwrite global variables"})]}),W&&se&&Object.entries(se).length>0&&(0,Y.jsx)(O.Z,{mt:1,children:(0,Y.jsx)(w.Z,{columnFlex:[null,1],columns:[{uuid:"Variable"},{uuid:"Value"}],rows:Object.entries(se).reduce((function(e,n){var t=(0,i.Z)(n,2),r=t[0],o=t[1];return b.sZ===r?e:e.concat([[(0,Y.jsx)(S.ZP,{default:!0,monospace:!0,children:r},"variable_".concat(r)),(0,Y.jsx)(ae.Z,{borderless:!0,monospace:!0,onChange:function(e){e.preventDefault(),ue((function(n){return De(De({},n),{},(0,l.Z)({},r,e.target.value))}))},paddingHorizontal:0,placeholder:"Variable value",value:o},"variable_uuid_input_".concat(r))]])}),[])})})]})]}),(null===vn||void 0===vn?void 0:vn.length)>=1&&(0,Y.jsx)(O.Z,{mb:M.HN,children:(0,Y.jsx)(he,{blocks:vn,updateVariables:ue,variables:De(De({},nn),se)})})]})}),[vn,X,ye,W,se,pe,we,nn,K,z,ue,G]);return(0,Y.jsx)(Y.Fragment,{children:(0,Y.jsxs)(j.Z,{after:gn,breadcrumbs:[{label:function(){return"Triggers"},linkProps:{as:"/pipelines/".concat(x,"/triggers"),href:"/pipelines/[pipeline]/triggers"}},{label:function(){return null===o||void 0===o?void 0:o.name},linkProps:{as:"/pipelines/".concat(x,"/triggers/").concat(P),href:"/pipelines/[pipeline]/triggers/[...slug]"}}],errors:n,pageName:N.M.TRIGGERS,pipeline:r,setErrors:c,subheader:(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(p.Z,{disabled:mn,loading:en,onClick:cn,outline:!0,primary:!0,children:"Save changes"}),(0,Y.jsx)(O.Z,{mr:1}),(0,Y.jsx)(p.Z,{linkProps:{href:"/pipelines/[pipeline]/triggers/[...slug]",as:"/pipelines/".concat(x,"/triggers/").concat(P)},noHoverUnderline:!0,outline:!0,sameColorAsText:!0,children:"Cancel"})]}),title:function(){return"Edit ".concat(null===o||void 0===o?void 0:o.name)},uuid:"triggers/edit",children:[(0,Y.jsxs)(O.Z,{p:M.cd,children:[(0,Y.jsxs)(O.Z,{mb:2,children:[(0,Y.jsx)(m.Z,{children:"Trigger type"}),(0,Y.jsx)(S.ZP,{muted:!0,children:"How would you like this pipeline to be triggered?"})]}),(0,Y.jsx)(h.Z,{children:Me(k).map((function(e){var n=e.label,t=e.description,r=e.uuid,i=we===r,o=we&&!i;return(0,Y.jsx)(p.Z,{noBackground:!0,noBorder:!0,noPadding:!0,onClick:function(){Z.Xm.EVENT!==r||null!==E&&void 0!==E&&E.length||R([{}]),fe((function(e){return De(De({},e),{},{schedule_type:r})}))},children:(0,Y.jsx)(Ce.U,{selected:i,children:(0,Y.jsxs)(h.Z,{alignItems:"center",children:[(0,Y.jsx)(me.Z,{children:(0,Y.jsx)("input",{checked:i,type:"radio"})}),(0,Y.jsx)(O.Z,{mr:M.cd}),(0,Y.jsxs)(me.Z,{alignItems:"flex-start",flexDirection:"column",children:[(0,Y.jsx)(m.Z,{bold:!0,default:!i&&!o,level:5,muted:!i&&o,children:n()}),(0,Y.jsx)(S.ZP,{default:!i&&!o,leftAligned:!0,muted:o,children:t()})]})]})})},r)}))})]}),(0,Y.jsxs)(O.Z,{mt:5,children:[Z.Xm.TIME===we&&an,Z.Xm.EVENT===we&&pn,Z.Xm.API===we&&hn]})]})})},Ae=t(41788),Ue=t(70543);function Re(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function He(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?Re(Object(t),!0).forEach((function(n){(0,l.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):Re(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function Fe(e){var n=e.pipelineScheduleId,t=e.pipelineUUID,r=e.subpath,i=Ue.b7===r,o=(0,u.useState)(null),l=o[0],c=o[1],s=I.ZP.variables.pipelines.list(t,{},{revalidateOnFocus:!1}).data,a=null===s||void 0===s?void 0:s.variables,d=I.ZP.pipeline_schedules.detail(n,{_format:i?"with_runtime_average":null}),p=d.data,f=d.mutate,h=null===p||void 0===p?void 0:p.pipeline_schedule,m=I.ZP.pipelines.detail(t,{includes_content:!1,includes_outputs:!1},{revalidateOnFocus:!1}).data,v=He(He({},null===m||void 0===m?void 0:m.pipeline),{},{uuid:t});return i?(0,Y.jsx)(Ne,{errors:l,fetchPipelineSchedule:f,pipeline:v,pipelineSchedule:h,setErrors:c,variables:a}):(0,Y.jsx)(Q,{errors:l,fetchPipelineSchedule:f,pipeline:v,pipelineSchedule:h,setErrors:c,variables:a})}Fe.getInitialProps=function(){var e=(0,o.Z)(s().mark((function e(n){var t,r,o,l,c,u;return s().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t=n.query,r=t.pipeline,o=t.slug,!Array.isArray(o)){e.next=4;break}return l=(0,i.Z)(o,2),c=l[0],u=l[1],e.abrupt("return",{pipelineScheduleId:c,pipelineUUID:r,subpath:u});case 4:return e.abrupt("return",{pipelineUUID:r});case 5:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}();var Le=(0,Ae.Z)(Fe)},95488:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/pipelines/[pipeline]/triggers/[...slug]",function(){return t(70422)}])}},function(e){e.O(0,[844,9902,426,1774,8792,7849,4495,1424,1005,7815,3654,547,8952,7496,9774,2888,179],(function(){return n=95488,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([[4249],{58122:function(e,n,t){"use strict";t.d(n,{FS:function(){return l},JZ:function(){return s},e7:function(){return d},wx:function(){return a}});var r=t(75582),i=t(82394),o=t(93348);function c(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function u(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?c(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):c(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function l(e){return"string"===typeof e?e:JSON.stringify(e)}function a(e,n){var t,r;return null===e||void 0===e||null===(t=e.find((function(e){var t=e.block;return n(t)})))||void 0===t||null===(r=t.variables)||void 0===r?void 0:r.map((function(e){var n=e.value;return u(u({},e),{},{value:l(n)})}))}function s(e,n){return n===o.Xm.TIME?e.push({uuid:"execution_date",value:"<run datetime>"}):n===o.Xm.EVENT&&e.push({uuid:"event",value:"<trigger event>"}),e}function d(e){return e?Object.entries(e).reduce((function(e,n){var t=(0,r.Z)(n,2),o=t[0],c=t[1],l=c;try{l=JSON.parse(c)}catch(a){}return u(u({},e),{},(0,i.Z)({},o,l))}),{}):e}},97225:function(e,n,t){"use strict";var r=t(75582),i=t(12691),o=t.n(i),c=t(82684),u=t(83455),l=t(34376),a=t(60328),s=t(16634),d=t(47999),p=t(67971),f=t(10919),h=t(93348),g=t(62609),v=t(86673),m=t(87815),b=t(19711),x=t(46261),j=t(82531),Z=t(22341),y=t(66050),_=t(49125),P=t(45838),O=t(9736),w=t(96510),k=t(66653),C=t(28598),E=1.5*_.iI;n.Z=function(e){var n=e.disableActions,t=e.fetchPipelineSchedules,i=e.highlightRowOnHover,I=e.includeCreatedAtColumn,S=e.includePipelineColumn,T=e.pipeline,A=e.pipelineSchedules,D=e.pipelineTriggersByName,N=e.selectedSchedule,M=e.setErrors,H=e.setSelectedSchedule,V=e.stickyHeader,Y=null===T||void 0===T?void 0:T.uuid,R=(0,l.useRouter)(),F=(0,c.useRef)({}),B=(0,c.useState)(null),W=B[0],z=B[1],L=(0,c.useState)(0),q=L[0],J=L[1],K=(0,c.useState)(0),U=K[0],Q=K[1],X=(0,u.Db)((function(e){return j.ZP.pipeline_schedules.useUpdate(e.id)({pipeline_schedule:e})}),{onSuccess:function(e){return(0,w.wD)(e,{callback:function(){null===t||void 0===t||t()},onErrorCallback:function(e,n){return M({errors:n,response:e})}})}}),G=(0,r.Z)(X,1)[0],$=(0,u.Db)((function(e){return j.ZP.pipeline_schedules.useDelete(e)()}),{onSuccess:function(e){return(0,w.wD)(e,{callback:function(){null===t||void 0===t||t(),Y?R.push("/pipelines/[pipeline]/triggers","/pipelines/".concat(Y,"/triggers")):null===t||void 0===t||t()},onErrorCallback:function(e,n){return M({errors:n,response:e})}})}}),ee=(0,r.Z)($,1)[0],ne=[],te=[];return n||(ne.push.apply(ne,[null,null,1]),te.push.apply(te,[{label:function(){return""},uuid:"action"},{uuid:"Info"},{uuid:"Type"}])),ne.push.apply(ne,[n?1:null]),te.push.apply(te,[{uuid:"Name"}]),n||(ne.push.apply(ne,[null]),te.push.apply(te,[{uuid:"Frequency"}])),ne.push.apply(ne,[null,null,null]),te.push.apply(te,[{uuid:"Runs"},{uuid:"Latest status"},{uuid:"Logs"}]),n||(0,O.Ct)()||(ne.push.apply(ne,[null]),te.push({label:function(){return""},uuid:"edit/delete"})),!n&&S&&(te.splice(2,0,{uuid:"Pipeline"}),ne.splice(2,0,2)),!n&&I&&(te.splice(3,0,{uuid:"Created at"}),ne.splice(3,0,null)),(0,C.jsx)(P.cl,{overflowVisible:!0,children:0===A.length?(0,C.jsx)(v.Z,{px:3,py:1,children:(0,C.jsx)(b.ZP,{bold:!0,default:!0,monospace:!0,muted:!0,children:"No triggers available"})}):(0,C.jsx)(m.Z,{columnFlex:ne,columns:te,highlightRowOnHover:i,isSelectedRow:function(e){return A[e].id===(null===N||void 0===N?void 0:N.id)},onClickRow:H?function(e){return null===H||void 0===H?void 0:H(A[e])}:null,rowVerticalPadding:6,rows:A.map((function(e,t){var r,i=e.id,u=e.created_at,l=e.pipeline_runs_count,m=e.pipeline_uuid,j=e.last_pipeline_run_status,P=e.name,w=e.schedule_interval,T=e.status,A=Y||m;F.current[i]=(0,c.createRef)(),h.fq.ACTIVE===T?r=(0,C.jsx)(s.Z,{size:E,success:!0}):h.fq.INACTIVE===T&&(r=(0,C.jsx)(s.Z,{borderSize:1,size:E,square:!0,warning:!0}));var N,M=[];n?M.push.apply(M,[(0,C.jsx)(b.ZP,{bold:!0,children:P},"trigger_name_".concat(t))]):M.push.apply(M,[(0,C.jsx)(a.Z,{iconOnly:!0,noBackground:!0,noBorder:!0,noPadding:!0,onClick:function(n){(0,k.j)(n),G({id:e.id,status:h.fq.ACTIVE===T?h.fq.INACTIVE:h.fq.ACTIVE})},children:h.fq.ACTIVE===T?(0,C.jsx)(Z.dz,{muted:!0,size:2*_.iI}):(0,C.jsx)(Z.Py,{default:!0,size:2*_.iI})},"toggle_trigger_".concat(t)),(0,C.jsxs)(p.Z,{alignItems:"center",flexDirection:"row",children:[(0,C.jsx)(x.Z,{block:!0,label:T,size:E,widthFitContent:!0,children:r}),(null===D||void 0===D?void 0:D[P])&&(0,C.jsxs)(C.Fragment,{children:[(0,C.jsx)(v.Z,{mr:1}),(0,C.jsx)(x.Z,{block:!0,label:"This trigger is saved in code.",size:E,widthFitContent:!0,children:(0,C.jsx)(Z.EK,{default:!0,size:E})})]})]},"trigger_status_".concat(t)),(0,C.jsx)(b.ZP,{default:!0,monospace:!0,children:null===(N=h.Z4[e.schedule_type])||void 0===N?void 0:N.call(h.Z4)},"trigger_type_".concat(t)),(0,C.jsx)(o(),{as:"/pipelines/".concat(A,"/triggers/").concat(i),href:"/pipelines/[pipeline]/triggers/[...slug]",passHref:!0,children:(0,C.jsx)(f.Z,{bold:!0,onClick:function(e){(0,k.j)(e),R.push("/pipelines/[pipeline]/triggers/[...slug]","/pipelines/".concat(A,"/triggers/").concat(i))},sameColorAsText:!0,children:P})},"trigger_name_".concat(t))]);return n||M.push.apply(M,[(0,C.jsx)(b.ZP,{default:!0,monospace:!0,children:w},"trigger_frequency_".concat(t))]),M.push.apply(M,[(0,C.jsx)(b.ZP,{default:!0,monospace:!0,children:l},"trigger_run_count_".concat(t)),(0,C.jsx)(b.ZP,{danger:y.V.FAILED===j,default:!j,monospace:!0,success:y.V.COMPLETED===j,warning:y.V.CANCELLED===j,children:j||"N/A"},"latest_run_status_".concat(t)),(0,C.jsx)(a.Z,{default:!0,iconOnly:!0,noBackground:!0,onClick:function(){return R.push("/pipelines/".concat(A,"/logs?pipeline_schedule_id[]=").concat(i))},children:(0,C.jsx)(Z.B4,{default:!0,size:2*_.iI})},"logs_button_".concat(t))]),n||(0,O.Ct)()||M.push((0,C.jsxs)(p.Z,{children:[(0,C.jsx)(a.Z,{default:!0,iconOnly:!0,noBackground:!0,onClick:function(){return R.push("/pipelines/".concat(A,"/triggers/").concat(i,"/edit"))},title:"Edit",children:(0,C.jsx)(Z.I8,{default:!0,size:2*_.iI})}),(0,C.jsx)(v.Z,{mr:1}),(0,C.jsx)(a.Z,{default:!0,iconOnly:!0,noBackground:!0,onClick:function(){var e,n,t,r;z(i),J((null===(e=F.current[i])||void 0===e||null===(n=e.current)||void 0===n?void 0:n.offsetTop)||0),Q((null===(t=F.current[i])||void 0===t||null===(r=t.current)||void 0===r?void 0:r.offsetLeft)||0)},ref:F.current[i],title:"Delete",children:(0,C.jsx)(Z.rF,{default:!0,size:2*_.iI})}),(0,C.jsx)(d.Z,{onClickOutside:function(){return z(null)},open:W===i,children:(0,C.jsx)(g.Z,{danger:!0,left:(U||0)-286,onCancel:function(){return z(null)},onClick:function(){z(null),ee(i)},title:"Are you sure you want to delete the trigger ".concat(P,"?"),top:(q||0)-(t<=1?40:96),width:40*_.iI})})]},"edit_delete_buttons_".concat(t))),!n&&S&&M.splice(2,0,(0,C.jsx)(b.ZP,{default:!0,monospace:!0,children:A},"pipeline_name_".concat(t))),!n&&I&&M.splice(3,0,(0,C.jsx)(b.ZP,{default:!0,monospace:!0,children:u},"created_at_".concat(t))),M})),stickyHeader:V,uuid:"pipeline-triggers"})})}},51099:function(e,n,t){"use strict";t.d(n,{Q:function(){return s}});t(82684);var r=t(60328),i=t(67971),o=t(86673),c=t(22341),u=t(73899),l=t(49125),a=t(28598),s=22;n.Z=function(e){var n=e.page,t=e.maxPages,s=e.onUpdate,d=e.totalPages,p=[],f=t;if(f>d)p=Array.from({length:d},(function(e,n){return n}));else{var h=Math.floor(f/2),g=n-h;n+h>=d?(g=d-f+2,f-=2):n-h<=0?(g=0,f-=2):(f-=4,g=n-Math.floor(f/2)),p=Array.from({length:f},(function(e,n){return n+g}))}return(0,a.jsx)(a.Fragment,{children:d>0&&(0,a.jsxs)(i.Z,{alignItems:"center",children:[(0,a.jsx)(r.Z,{disabled:0===n,onClick:function(){return s(n-1)},children:(0,a.jsx)(c.Hd,{size:1.5*l.iI,stroke:"#AEAEAE"})}),!p.includes(0)&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(o.Z,{ml:1,children:(0,a.jsx)(r.Z,{onClick:function(){return s(0)},borderLess:!0,noBackground:!0,children:1})},0),!p.includes(1)&&(0,a.jsx)(o.Z,{ml:1,children:(0,a.jsx)(r.Z,{notClickable:!0,noBackground:!0,noPadding:!0,children:"..."})},0)]}),p.map((function(e){return(0,a.jsx)(o.Z,{ml:1,children:(0,a.jsx)(r.Z,{onClick:function(){e!==n&&s(e)},notClickable:e===n,backgroundColor:e===n&&u.a$,borderLess:!0,noBackground:!0,children:e+1})},e)})),!p.includes(d-1)&&(0,a.jsxs)(a.Fragment,{children:[!p.includes(d-2)&&(0,a.jsx)(o.Z,{ml:1,children:(0,a.jsx)(r.Z,{notClickable:!0,noBackground:!0,noPadding:!0,children:"..."})},0),(0,a.jsx)(o.Z,{ml:1,children:(0,a.jsx)(r.Z,{onClick:function(){return s(d-1)},borderLess:!0,noBackground:!0,children:d})},d-1)]}),(0,a.jsx)(o.Z,{ml:1}),(0,a.jsx)(r.Z,{disabled:n===d-1,onClick:function(){return s(n+1)},children:(0,a.jsx)(c.Kw,{size:1.5*l.iI,stroke:"#AEAEAE"})})]})})}},93348:function(e,n,t){"use strict";t.d(n,{TR:function(){return d},U5:function(){return l},Xm:function(){return o},Z4:function(){return s},fq:function(){return u},kJ:function(){return a}});var r,i,o,c=t(82394);!function(e){e.API="api",e.EVENT="event",e.TIME="time"}(o||(o={}));var u,l,a,s=(r={},(0,c.Z)(r,o.API,(function(){return"API"})),(0,c.Z)(r,o.EVENT,(function(){return"event"})),(0,c.Z)(r,o.TIME,(function(){return"schedule"})),r);!function(e){e.ACTIVE="active",e.INACTIVE="inactive"}(u||(u={})),function(e){e.ONCE="@once",e.HOURLY="@hourly",e.DAILY="@daily",e.WEEKLY="@weekly",e.MONTHLY="@monthly"}(l||(l={})),function(e){e.CREATED_AT="created_at",e.NAME="name",e.PIPELINE="pipeline_uuid",e.STATUS="status",e.TYPE="schedule_type"}(a||(a={}));var d=(i={},(0,c.Z)(i,a.CREATED_AT,"Created at"),(0,c.Z)(i,a.NAME,"Name"),(0,c.Z)(i,a.PIPELINE,"Pipeline"),(0,c.Z)(i,a.STATUS,"Status"),(0,c.Z)(i,a.TYPE,"Type"),i)},52769:function(e,n,t){"use strict";t.d(n,{C:function(){return r}});var r="global"},29237:function(e,n,t){"use strict";var r=t(38626),i=t(67971),o=t(86673),c=t(19711),u=t(23831),l=t(73942),a=t(37391),s=t(49125),d=t(28598),p=(0,r.css)(["padding:","px;padding-bottom:","px;padding-top:","px;"],2*s.iI,1.5*s.iI,1.5*s.iI),f=r.default.div.withConfig({displayName:"Panel__PanelStyle",componentId:"sc-1ct8cgl-0"})(["border-radius:","px;overflow:hidden;"," "," "," "," "," "," "," "," "," "," "," ",""],l.n_,(function(e){return e.fullWidth&&"\n width: 100%;\n "}),(function(e){return!e.borderless&&"\n border: 1px solid ".concat((e.theme.interactive||u.Z.interactive).defaultBorder,";\n ")}),(function(e){return e.success&&"\n background-color: ".concat((e.theme.background||u.Z.background).successLight,";\n ")}),(function(e){return e.success&&!e.borderless&&"\n border: 1px solid ".concat((e.theme.background||u.Z.background).success,";\n ")}),(function(e){return!e.dark&&!e.success&&"\n background-color: ".concat((e.theme.background||u.Z.background).panel,";\n ")}),(function(e){return e.dark&&"\n background-color: ".concat((e.theme.background||u.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=r.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(e){return"\n background-color: ".concat((e.theme.background||u.Z.background).chartBlock,";\n border-bottom: 1px solid ").concat((e.theme.interactive||u.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=r.default.div.withConfig({displayName:"Panel__ContentStyle",componentId:"sc-1ct8cgl-2"})(["overflow-y:auto;padding:","px;height:100%;"," "," "," "," ",""],1.75*s.iI,a.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 "})),v=r.default.div.withConfig({displayName:"Panel__FooterStyle",componentId:"sc-1ct8cgl-3"})(["border-style:",";border-top-width:","px;padding:","px;"],l.M8,l.YF,1.75*s.iI);n.Z=function(e){var n=e.borderless,t=e.children,r=e.containerRef,u=e.contentContainerRef,l=e.dark,a=e.footer,s=e.fullHeight,p=void 0===s||s,m=e.fullWidth,b=void 0===m||m,x=e.header,j=e.headerHeight,Z=e.headerIcon,y=e.headerPaddingVertical,_=e.headerTitle,P=e.maxHeight,O=e.maxWidth,w=e.minWidth,k=e.noPadding,C=e.overflowVisible,E=e.subtitle,I=e.success;return(0,d.jsxs)(f,{borderless:n,dark:l,fullHeight:p,fullWidth:b,maxHeight:P,maxWidth:O,minWidth:w,overflowVisible:C,ref:r,success:I,children:[(x||_)&&(0,d.jsxs)(h,{headerPaddingVertical:y,height:j,children:[x&&x,_&&(0,d.jsx)(i.Z,{alignItems:"center",justifyContent:"space-between",children:(0,d.jsxs)(i.Z,{alignItems:"center",children:[Z&&Z,(0,d.jsx)(o.Z,{ml:Z?1:0,children:(0,d.jsx)(c.ZP,{bold:!0,default:!0,children:_})})]})})]}),(0,d.jsxs)(g,{maxHeight:P,noPadding:k,overflowVisible:C,ref:u,children:[E&&(0,d.jsx)(o.Z,{mb:2,children:(0,d.jsx)(c.ZP,{default:!0,children:E})}),t]}),a&&(0,d.jsx)(v,{children:a})]})}},6087:function(e,n,t){"use strict";t.r(n),t.d(n,{default:function(){return pe}});var r=t(77837),i=t(82394),o=t(75582),c=t(38860),u=t.n(c),l=t(12691),a=t.n(l),s=t(82684),d=t(83455),p=t(34376),f=t(60328),h=t(48952),g=t(34744),v=t(67971),m=t(87372),b=t(11135),x=t(10919),j=t(51099),Z=t(60547),y=t(93348),_=t(41788),P=t(29237),O=t(86673),w=t(87815),k=t(19711),C=t(38435),E=t(82944),I=t(70902),S=t(23831),T=t(38626),A=t(73942),D=t(49125),N=T.default.div.withConfig({displayName:"indexstyle__ToggleStyle",componentId:"sc-f9kt7n-0"})(["padding:","px ","px;border-radius:","px;",""],1.5*D.iI,2*D.iI,A.n_,(function(e){return"\n border: 1px solid ".concat((e.theme||S.Z).borders.light,";\n background-color: ").concat((e.theme||S.Z).background.popup,";\n ")})),M=t(90211),H=t(58122),V=t(28598);function Y(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function R(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?Y(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):Y(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var F="".concat(D.iI,"px ").concat(3*D.iI,"px");var B=function(e){var n=e.initialPipelineSchedulePayload,t=e.onCancel,r=e.onSuccess,c=e.variables,u=(0,s.useState)(!1),l=u[0],a=u[1],d=(0,s.useState)({}),p=d[0],h=d[1],g=(0,s.useState)(c||{}),b=g[0],x=g[1],j=(0,s.useMemo)((function(){return R(R({},n),{},{name:(0,M.Y6)(),variables:l?(0,H.e7)(b):null})}),[n,l,b]),Z=function(e,n){var t={borderless:!0,key:"variable_uuid_input_".concat(e),monospace:!0,onChange:function(n){n.preventDefault(),x((function(t){return R(R({},t),{},(0,i.Z)({},e,n.target.value))}))},paddingHorizontal:0,placeholder:"Variable value",value:n};return p[e]?(0,V.jsx)(C.Z,R(R({},t),{},{rows:1,value:n})):(0,V.jsx)(E.Z,R({},t))};return(0,s.useEffect)((function(){var e=Object.entries(b).reduce((function(e,n){var t=(0,o.Z)(n,2),r=t[0],c=t[1],u=(0,M.Pb)(c)&&"object"===typeof JSON.parse(c)&&!Array.isArray(JSON.parse(c))&&null!==JSON.parse(c);return R(R({},e),{},(0,i.Z)({},r,u))}),{});h(e)}),[]),(0,V.jsxs)(P.Z,{footer:(0,V.jsxs)(v.Z,{alignItems:"center",fullWidth:!0,justifyContent:"flex-end",children:[(0,V.jsx)(f.Z,{onClick:function(){r({pipeline_schedule:j}),t()},padding:F,primaryAlternate:!0,children:"Run now"}),(0,V.jsx)(O.Z,{mr:1}),(0,V.jsx)(f.Z,{borderColor:S.Z.background.page,onClick:t,padding:F,secondary:!0,children:"Cancel"})]}),header:(0,V.jsx)(m.Z,{level:5,children:"Run pipeline now"}),maxHeight:"90vh",minWidth:85*D.iI,subtitle:"Creates a new trigger and immediately runs the current pipeline once.",children:[(0,V.jsx)(N,{children:(0,V.jsxs)(v.Z,{alignItems:"center",children:[(0,V.jsx)(O.Z,{mr:2,children:(0,V.jsx)(I.Z,{checked:l,onCheck:a})}),(0,V.jsx)(k.ZP,{bold:!0,large:!0,children:"Overwrite runtime variables"})]})}),l&&b&&Object.entries(b).length>0&&(0,V.jsx)(O.Z,{mt:2,children:(0,V.jsx)(w.Z,{columnFlex:[null,1],columns:[{uuid:"Variable"},{uuid:"Value"}],rows:Object.entries(b).map((function(e){var n=(0,o.Z)(e,2),t=n[0],r=n[1];return[(0,V.jsx)(k.ZP,{default:!0,monospace:!0,children:t},"variable_".concat(t)),Z(t,r)]}))})})]})},W=t(37391),z=T.default.div.withConfig({displayName:"indexstyle__ContainerStyle",componentId:"sc-1xgfh62-0"})(["border-bottom:1px solid ",";padding:","px;"],S.Z.borders.medium,D.tr),L=T.default.div.withConfig({displayName:"indexstyle__CardsStyle",componentId:"sc-1xgfh62-1"})([""," height:80px;display:flex;overflow-x:scroll;"],W.w5),q=T.default.div.withConfig({displayName:"indexstyle__VariableCardStyle",componentId:"sc-1xgfh62-2"})(["background-color:",";border-radius:","px;flex-shrink:0;margin-right:","px;padding:","px;"],S.Z.background.output,A.n_,D.iI,D.tr),J=t(73899);var K=function(e){var n=e.hasOverride,t=e.scheduleType,r=e.variables,i=e.variablesOverride,c=[];return Object.entries(r).forEach((function(e){var n=(0,o.Z)(e,2),t=n[0],r=n[1],u=null===i||void 0===i?void 0:i[t];c.push({uuid:t,value:(0,H.FS)(u||r)})})),(0,H.JZ)(c,t),(0,V.jsxs)(z,{children:[(0,V.jsx)(O.Z,{mb:2,children:(0,V.jsxs)(k.ZP,{bold:!0,large:!0,monospace:!0,muted:!0,children:["Runtime variables",n&&" (override)"]})}),(0,V.jsx)(L,{noScrollbarTrackBackground:!0,children:r&&c.map((function(e){var n=e.uuid,t=e.value;return(0,V.jsxs)(q,{children:[(0,V.jsx)(k.ZP,{monospace:!0,small:!0,children:n}),(0,V.jsx)(k.ZP,{color:J.Or,monospace:!0,small:!0,children:(0,H.FS)(t)})]})}))})]})},U=t(54283),Q=t(46261),X=t(97225),G=t(82531),$=t(22341),ee=t(52769),ne=t(59920),te=t(42305),re=t(24224),ie=t(7715),oe=t(9736),ce=t(96510),ue=t(59e3),le=t(99497);function ae(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function se(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?ae(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):ae(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function de(e){var n=e.pipeline,t=(0,p.useRouter)(),r=(0,oe.Ct)(),c=n.uuid,u=(0,s.useState)(null),l=u[0],_=u[1],P=G.ZP.variables.pipelines.list(c,{global_only:!0},{revalidateOnFocus:!1}).data,w=null===P||void 0===P?void 0:P.variables,C=(0,ue.iV)(),E=null!==C&&void 0!==C&&C.page?C.page:0,I=G.ZP.pipeline_schedules.pipelines.list(c,{_limit:j.Q,_offset:(null!==C&&void 0!==C&&C.page?C.page:0)*j.Q},{refreshInterval:7500}),S=I.data,T=I.mutate,A=(0,s.useMemo)((function(){return(null===S||void 0===S?void 0:S.pipeline_schedules)||[]}),[S]),N=function(e){return(0,d.Db)(G.ZP.pipeline_schedules.pipelines.useCreate(c),{onSuccess:function(n){return(0,ce.wD)(n,{callback:function(n){var t=n.pipeline_schedule.id;null===e||void 0===e||e(t)},onErrorCallback:function(e,n){return _({errors:n,response:e})}})}})},Y=N((function(e){return t.push("/pipelines/[pipeline]/triggers/[...slug]","/pipelines/".concat(null===n||void 0===n?void 0:n.uuid,"/triggers/").concat(e,"/edit"))})),R=(0,o.Z)(Y,2),F=R[0],W=R[1].isLoading,z=N(T),L=(0,o.Z)(z,2),q=L[0],J=L[1].isLoading,ae=(0,s.useMemo)((function(){var e;return null===(e=(0,H.wx)(w,(function(e){return e.uuid===ee.C})))||void 0===e?void 0:e.reduce((function(e,n){var t=n.uuid,r=n.value;return se(se({},e),{},(0,i.Z)({},t,r))}),{})}),[w]),de={name:(0,M.Y6)(),schedule_interval:y.U5.ONCE,schedule_type:y.Xm.TIME,start_time:(0,te.d$)((new Date).toISOString(),{dayAgo:!0,utcFormat:!0}),status:y.fq.ACTIVE},pe=(0,le.dd)((function(){return(0,V.jsx)(B,{initialPipelineSchedulePayload:de,onCancel:ge,onSuccess:q,variables:ae})}),{},[w,ae],{background:!0,uuid:"run_pipeline_now_popup"}),fe=(0,o.Z)(pe,2),he=fe[0],ge=fe[1],ve=(0,s.useState)(),me=ve[0],be=ve[1],xe=(0,s.useMemo)((function(){var e=null===me||void 0===me?void 0:me.variables,n=!(0,ie.Qr)(e),t=n?null===me||void 0===me?void 0:me.variables:(0,ie.Qr)(ae)?null:ae;return function(i){var o=i.height-(t?151:80);return(0,V.jsxs)(V.Fragment,{children:[t&&(0,V.jsx)(K,{hasOverride:n,scheduleType:null===me||void 0===me?void 0:me.schedule_type,variables:ae,variablesOverride:e}),!t&&(0,V.jsxs)(O.Z,{p:D.cd,children:[(0,V.jsx)(k.ZP,{children:"This pipeline has no runtime variables."}),!r&&(0,V.jsxs)(O.Z,{mt:1,children:[(0,V.jsx)(a(),{as:"/pipelines/".concat(c,"/edit?sideview=variables"),href:"/pipelines/[pipeline]/edit",passHref:!0,children:(0,V.jsx)(x.Z,{primary:!0,children:"Click here"})})," ",(0,V.jsx)(k.ZP,{inline:!0,children:"to add variables to this pipeline."})]})]}),(0,V.jsx)(h.Z,se(se({},i),{},{height:o,noStatus:!0}))]})}}),[r,c,null===me||void 0===me?void 0:me.schedule_type,null===me||void 0===me?void 0:me.variables,ae]),je=(0,s.useMemo)((function(){var e;return(null===S||void 0===S||null===(e=S.metadata)||void 0===e?void 0:e.count)||[]}),[S]),Ze=G.ZP.pipeline_triggers.pipelines.list(c),ye=Ze.data,_e=(Ze.mutate,(0,s.useMemo)((function(){return(0,re.HK)((null===ye||void 0===ye?void 0:ye.pipeline_triggers)||[],(function(e){return e.name}))}),[ye]));return(0,V.jsxs)(Z.Z,{breadcrumbs:[{label:function(){return"Triggers"}}],buildSidekick:xe,errors:l,pageName:ne.M.TRIGGERS,pipeline:n,setErrors:_,subheaderBackgroundImage:"".concat(t.basePath,"/images/banner-shape-purple-peach.jpg"),subheaderButton:(0,V.jsx)(b.ZP,{beforeElement:(0,V.jsx)($.mm,{size:2.5*D.iI}),blackBorder:!0,inline:!0,loading:W,noHoverUnderline:!0,onClick:function(){return F({pipeline_schedule:{name:(0,M.Y6)()}})},sameColorAsText:!0,uuid:"PipelineDetailPage/add_new_schedule",children:"Create new trigger"}),subheaderText:(0,V.jsx)(k.ZP,{bold:!0,large:!0,children:"Run this pipeline using a schedule, event, or API."}),title:function(e){var n=e.name;return"".concat(n," triggers")},uuid:"".concat(ne.M.TRIGGERS,"_").concat(c),children:[(0,V.jsx)(O.Z,{mt:D.cd,px:D.cd,children:(0,V.jsxs)(v.Z,{justifyContent:"space-between",children:[(0,V.jsx)(m.Z,{level:5,children:"Pipeline triggers"}),(0,V.jsx)(Q.Z,{appearBefore:!0,default:!0,fullSize:!0,label:"Creates an @once trigger and runs pipeline immediately",widthFitContent:!0,children:(0,V.jsx)(f.Z,{beforeIcon:(0,V.jsx)($.JM,{inverted:!0,size:2*D.iI}),disabled:r,loading:J,onClick:(0,ie.Qr)(ae)?function(){return q({pipeline_schedule:de})}:he,outline:!0,success:!r,children:"Run pipeline now"})})]})}),(0,V.jsx)(g.Z,{light:!0,mt:D.cd,short:!0}),S?(0,V.jsxs)(V.Fragment,{children:[(0,V.jsx)(X.Z,{fetchPipelineSchedules:T,pipeline:n,pipelineSchedules:A,pipelineTriggersByName:_e,selectedSchedule:me,setErrors:_,setSelectedSchedule:be}),(0,V.jsx)(O.Z,{p:2,children:(0,V.jsx)(j.Z,{maxPages:9,onUpdate:function(e){var n=Number(e),r=se(se({},C),{},{page:n>=0?n:0});t.push("/pipelines/[pipeline]/triggers","/pipelines/".concat(c,"/triggers?").concat((0,ue.uM)(r)))},page:Number(E),totalPages:Math.ceil(je/j.Q)})})]}):(0,V.jsx)(O.Z,{m:2,children:(0,V.jsx)(U.Z,{inverted:!0})})]})}de.getInitialProps=function(){var e=(0,r.Z)(u().mark((function e(n){var t;return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=n.query.pipeline,e.abrupt("return",{pipeline:{uuid:t}});case 2:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}();var pe=(0,_.Z)(de)},42305:function(e,n,t){"use strict";t.d(n,{A5:function(){return x},AY:function(){return j},BP:function(){return b},JX:function(){return m},OC:function(){return d},Pc:function(){return Z},Ro:function(){return y},Tz:function(){return v},Y_:function(){return P},d$:function(){return g},jV:function(){return _},lJ:function(){return O},n1:function(){return f},s8:function(){return a},vk:function(){return o},yD:function(){return s}});var r,i,o,c=t(82394),u=t(92083),l=t.n(u);!function(e){e.TODAY="today",e.WEEK="week",e.MONTH="month"}(o||(o={}));var a=(r={},(0,c.Z)(r,o.TODAY,"today"),(0,c.Z)(r,o.WEEK,"last 7 days"),(0,c.Z)(r,o.MONTH,"last 30 days"),r),s=(i={},(0,c.Z)(i,o.TODAY,0),(0,c.Z)(i,o.WEEK,6),(0,c.Z)(i,o.MONTH,29),i),d="YYYY-MM-DD HH:mm:ss",p="YYYY-MM-DD HH:mm",f="YYYY-MM-DD",h="MMMM D, YYYY";function g(e,n){var t=n.dayAgo,r=n.includeSeconds,i=n.utcFormat,o=l()(e),c=p;return i&&(o=o.utc()),t&&(o=o.subtract(1,"days")),r&&(c=d),o.format(c)}function v(e){var n=g((new Date).toISOString(),{includeSeconds:!0,utcFormat:!0});return null!==e&&void 0!==e&&e.dateObj?new Date(n):n}function m(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return l().unix(e).format(null!==n&&void 0!==n&&n.withSeconds?d:p)}function b(e,n,t){return l()(e).utc().hours(+n).minutes(+t).format()}function x(e){return l()(e).unix()}function j(e,n,t,r){var i="".concat(e.toISOString().split("T")[0]," ").concat(n,":").concat(t);return r?"".concat(i,":").concat(r):i}function Z(e){var n=l().unix(+e).utc();return{date:n.toDate(),hour:String(n.hour()),minute:String(n.minute())}}function y(e,n){var t=l().utc(),r=l().utc();null!==n&&void 0!==n&&n.localTime&&(t=l()().local(),r=l()().local());var i=(t=t.subtract(e,"days")).format(h),o=r.format(h);return null!==n&&void 0!==n&&n.endDateOnly?o:"".concat(i," - ").concat(o)}function _(e,n){var t=null!==n&&void 0!==n&&n.localTime?l()().local():l().utc();if(e===o.WEEK){var r=s[o.WEEK];t=t.subtract(r,"days")}else if(e===o.MONTH){var i=s[o.MONTH];t=t.subtract(i,"days")}return null!==n&&void 0!==n&&n.isoString?t.startOf("day").toISOString():t.startOf("day").format(d)}function P(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:90,n=new Date,t=[],r=0;r<e;r++)t.unshift(n.toISOString().split("T")[0]),n.setDate(n.getDate()-1);return t}function O(e){return e.padStart(2,"0")}},40183:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/pipelines/[pipeline]/triggers",function(){return t(6087)}])}},function(e){e.O(0,[844,9902,426,1774,1424,1005,7815,3654,547,8952,9774,2888,179],(function(){return n=40183,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([[1221],{1210:function(e,n,t){"use strict";t.d(n,{Z:function(){return O}});var i=t(82394),o=t(21831),r=t(82684),u=t(47999),l=t(49894),c=t(93461),s=t(57384),a=t(41424),d=t(72454),p=t(28598);function f(e,n){var t=e.children;return(0,p.jsx)(d.HS,{ref:n,children:t})}var h=r.forwardRef(f),v=t(32063),m=t(85019),b=t(82531),j=t(66166),g=t(3055),x=t(49125),y=t(91427),Z=t(24141);function w(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 C(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?w(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):w(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var O=function(e){var n,t=e.addProjectBreadcrumbToCustomBreadcrumbs,i=e.after,f=e.afterHidden,w=e.afterWidth,O=e.afterWidthOverride,k=e.before,P=e.beforeWidth,E=e.breadcrumbs,I=e.children,T=e.errors,_=e.headerMenuItems,S=e.headerOffset,A=e.mainContainerHeader,M=e.navigationItems,D=e.setErrors,R=e.subheaderChildren,B=e.title,N=e.uuid,L=(0,Z.i)().width,G="dashboard_after_width_".concat(N),Y="dashboard_before_width_".concat(N),H=(0,r.useRef)(null),U=(0,r.useState)(O?w:(0,y.U2)(G,w)),V=U[0],z=U[1],W=(0,r.useState)(!1),F=W[0],q=W[1],Q=(0,r.useState)(k?Math.max((0,y.U2)(Y,P),13*x.iI):null),K=Q[0],$=Q[1],J=(0,r.useState)(!1),X=J[0],ee=J[1],ne=(0,r.useState)(null)[1],te=b.ZP.projects.list({},{revalidateOnFocus:!1}).data,ie=null===te||void 0===te?void 0:te.projects,oe={label:function(){var e;return null===ie||void 0===ie||null===(e=ie[0])||void 0===e?void 0:e.name},linkProps:{href:"/"}},re=[];E?(t&&re.push(oe),re.push.apply(re,(0,o.Z)(E))):(null===ie||void 0===ie?void 0:ie.length)>=1&&re.push.apply(re,[oe,{bold:!0,label:function(){return B}}]),(0,r.useEffect)((function(){null===H||void 0===H||!H.current||F||X||null===ne||void 0===ne||ne(H.current.getBoundingClientRect().width)}),[F,V,X,K,H,ne,L]),(0,r.useEffect)((function(){F||(0,y.t8)(G,V)}),[f,F,V,G]),(0,r.useEffect)((function(){X||(0,y.t8)(Y,K)}),[X,K,Y]);var ue=(0,j.Z)(w);return(0,r.useEffect)((function(){O&&ue!==w&&z(w)}),[O,w,ue]),(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)(s.Z,{title:B}),(0,p.jsx)(a.Z,{breadcrumbs:re,menuItems:_,project:null===ie||void 0===ie?void 0:ie[0],version:null===ie||void 0===ie||null===(n=ie[0])||void 0===n?void 0:n.version}),(0,p.jsxs)(d.Nk,{children:[0!==(null===M||void 0===M?void 0:M.length)&&(0,p.jsx)(d.lm,{showMore:!0,children:(0,p.jsx)(m.Z,{navigationItems:M,showMore:!0})}),(0,p.jsx)(c.Z,{flex:1,flexDirection:"column",children:(0,p.jsxs)(v.Z,{after:i,afterHeightOffset:g.Mz,afterHidden:f,afterMousedownActive:F,afterWidth:V,before:k,beforeHeightOffset:g.Mz,beforeMousedownActive:X,beforeWidth:d.k1+(k?K:0),headerOffset:S,hideAfterCompletely:!0,leftOffset:k?d.k1:null,mainContainerHeader:A,mainContainerRef:H,setAfterMousedownActive:q,setAfterWidth:z,setBeforeMousedownActive:ee,setBeforeWidth:$,children:[R&&(0,p.jsx)(h,{children:R}),I]})})]}),T&&(0,p.jsx)(u.Z,{disableClickOutside:!0,isOpen:!0,onClickOutside:function(){return null===D||void 0===D?void 0:D(null)},children:(0,p.jsx)(l.Z,C(C({},T),{},{onClose:function(){return null===D||void 0===D?void 0:D(null)}}))})]})}},64651:function(e,n,t){"use strict";t.d(n,{d:function(){return r}});var i=t(98781),o=t(90211),r=function(e,n){var t=[{label:function(){return"Standard (batch)"},onClick:function(){return e({pipeline:{name:(0,o.Y6)()}})},uuid:"Pipelines/NewPipelineMenu/standard"},{label:function(){return"Data integration"},onClick:function(){return e({pipeline:{name:(0,o.Y6)(),type:i.qL.INTEGRATION}})},uuid:"Pipelines/NewPipelineMenu/integration"},{label:function(){return"Streaming"},onClick:function(){return e({pipeline:{name:(0,o.Y6)(),type:i.qL.STREAMING}})},uuid:"Pipelines/NewPipelineMenu/streaming"}];return null!==n&&void 0!==n&&n.showBrowseTemplates&&t.push({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"}),t}},50316:function(e,n,t){"use strict";t.d(n,{B:function(){return p}});var i=t(82394),o=t(30264),r=t(11135),u=t(22341),l=t(99994),c=t(49125),s=t(28598);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}var p={bold:!0,greyBorder:!0,paddingBottom:9,paddingTop:9};n.Z=function(e){var n=e.addButtonMenuOpen,t=e.addButtonMenuRef,i=e.isLoading,a=e.label,f=e.menuItems,h=e.onClick,v=e.onClickCallback;return(0,s.jsx)(o.Z,{disableKeyboardShortcuts:!0,items:f,onClickCallback:v,onClickOutside:v,open:n,parentRef:t,roundedStyle:!0,topOffset:1,uuid:"Table/Toolbar/NewItemMenu",children:(0,s.jsx)(r.ZP,d(d({},p),{},{background:l.eW,beforeElement:(0,s.jsx)(u.mm,{size:2.5*c.iI}),loading:i,onClick:function(e){e.preventDefault(),null===h||void 0===h||h()},uuid:"shared/AddButton/index",children:a}))})}},93348:function(e,n,t){"use strict";t.d(n,{TR:function(){return d},U5:function(){return c},Xm:function(){return r},Z4:function(){return a},fq:function(){return l},kJ:function(){return s}});var i,o,r,u=t(82394);!function(e){e.API="api",e.EVENT="event",e.TIME="time"}(r||(r={}));var l,c,s,a=(i={},(0,u.Z)(i,r.API,(function(){return"API"})),(0,u.Z)(i,r.EVENT,(function(){return"event"})),(0,u.Z)(i,r.TIME,(function(){return"schedule"})),i);!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"}(c||(c={})),function(e){e.CREATED_AT="created_at",e.NAME="name",e.PIPELINE="pipeline_uuid",e.STATUS="status",e.TYPE="schedule_type"}(s||(s={}));var d=(o={},(0,u.Z)(o,s.CREATED_AT,"Created at"),(0,u.Z)(o,s.NAME,"Name"),(0,u.Z)(o,s.PIPELINE,"Pipeline"),(0,u.Z)(o,s.STATUS,"Status"),(0,u.Z)(o,s.TYPE,"Type"),o)},12257:function(e,n,t){"use strict";t.r(n),t.d(n,{default:function(){return Le}});var i=t(77837),o=t(75582),r=t(82394),u=t(38860),l=t.n(u),c=t(12691),s=t.n(c),a=t(83455),d=t(82684),p=t(34376),f=t(2485),h=t(60328),v=t(79891),m=t(1210),b=t(93461),j=t(67971),g=t(87372),x=t(11135),y=t(29237),Z=t(86673),w=t(19711),C=t(38435),O=t(82944),k=t(28598);var P=function(e){var n=e.description,t=e.isLoading,i=e.maxWidth,o=e.minWidth,r=e.noEmptyValue,u=e.onClose,l=e.onSave,c=e.textArea,s=e.title,a=e.value,p=(0,d.useRef)(null),f=(0,d.useState)(a),v=f[0],m=f[1],b=c?C.Z:O.Z;return(0,d.useEffect)((function(){var e;null===p||void 0===p||null===(e=p.current)||void 0===e||e.focus()}),[]),(0,k.jsxs)(y.Z,{maxWidth:i,minWidth:o,children:[(0,k.jsx)(w.ZP,{bold:!0,children:s}),(0,k.jsx)(Z.Z,{mt:1,children:(0,k.jsx)(b,{monospace:!0,onChange:function(e){return m(e.target.value)},ref:p,rows:c?7:null,value:v})}),n&&(0,k.jsx)(Z.Z,{mt:2,children:(0,k.jsx)(w.ZP,{muted:!0,small:!0,children:n})}),(0,k.jsx)(Z.Z,{mt:3,children:(0,k.jsxs)(j.Z,{children:[(0,k.jsx)(x.ZP,{bold:!0,inline:!0,loading:t,onClick:function(){v===a||r&&!v?u():l(v)},outline:!0,primary:!0,uuid:"Inputs/InputModal/SaveInput",children:"Save"}),(0,k.jsx)(Z.Z,{ml:1}),(0,k.jsx)(h.Z,{onClick:u,children:"Cancel"})]})})]})},E=t(10919),I=t(98781),T=t(41788),_=t(54283),S=t(87815),A=t(55264),M=t(70902),D=t(50316),R=t(18283),B=t(47999),N=t(30264),L=t(62609),G=t(38626),Y=t(23831),H=t(73942),U=t(37391),V=t(49125),z=74*V.iI,W=48*V.iI,F=G.default.div.withConfig({displayName:"indexstyle__ContainerStyle",componentId:"sc-18n432u-0"})(["position:absolute;border-radius:","px;overflow:hidden;width:","px;display:none;"," "," "," "," ",""],H.n_,z,(function(e){return"\n background-color: ".concat((e.theme||Y.Z).background.panel,";\n border: ").concat(H.mP,"px ").concat(H.M8," ").concat((e.theme||Y.Z).interactive.defaultBackground,";\n box-shadow: ").concat((e.theme.shadow||Y.Z.shadow).window,";\n ")}),(function(e){return e.display&&"\n display: block;\n "}),(function(e){return e.compact&&"\n width: ".concat(.75*z,"px;\n ")}),(function(e){return"undefined"!==typeof e.left&&"\n left: ".concat(e.left,"px;\n ")}),(function(e){return"undefined"!==typeof e.top&&"\n top: ".concat(e.top,"px;\n ")})),q=G.default.div.withConfig({displayName:"indexstyle__MainStyle",componentId:"sc-18n432u-1"})(["display:flex;border-radius:","px;overflow:hidden;height:","px;"," ",""],H.n_,W,(function(e){return"\n background-color: ".concat((e.theme||Y.Z).background.content,";\n border: ").concat(H.YF,"px ").concat(H.M8," ").concat((e.theme||Y.Z).interactive.defaultBackground,";\n ")}),(function(e){return e.compact&&"\n height: ".concat(W/2,"px;\n ")})),Q=G.default.aside.withConfig({displayName:"indexstyle__BeforeStyle",componentId:"sc-18n432u-2"})(["width:100%;overflow:auto;"," ",""],U.w5,(function(e){return"\n border-right: ".concat(H.YF,"px ").concat(H.M8," ").concat((e.theme||Y.Z).background.panel,";\n ")})),K=G.default.div.withConfig({displayName:"indexstyle__ContentStyle",componentId:"sc-18n432u-3"})(["width:100%;overflow:auto;",""],U.w5),$=(0,G.css)(["display:flex;align-items:center;justify-content:space-between;padding:","px ","px;"],V.iI,2*V.iI),J=G.default.div.withConfig({displayName:"indexstyle__OptionStyle",componentId:"sc-18n432u-4"})([""," padding-top:","px;padding-bottom:","px;&:hover{cursor:pointer;","}",""],$,1.5*V.iI,1.5*V.iI,(function(e){return"\n background-color: ".concat((e.theme||Y.Z).monotone.black,";\n ")}),(function(e){return e.highlighted&&"\n background-color: ".concat((e.theme||Y.Z).monotone.black,";\n ")})),X=G.default.div.withConfig({displayName:"indexstyle__ToggleValueStyle",componentId:"sc-18n432u-5"})([""," ",""],$,(function(e){return"\n border-bottom: ".concat(H.YF,"px ").concat(H.M8," ").concat((e.theme||Y.Z).borders.medium2,";\n ")})),ee=t(22341),ne=t(33766),te=t(90211);function ie(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 oe(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?ie(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):ie(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var re,ue=function(e){var n,t,i,u=e.children,l=e.compact,c=e.onClickCallback,s=e.onClickOutside,a=e.onSecondaryClick,p=e.open,f=e.options,v=void 0===f?{}:f,m=e.parentRef,g=e.query,x=e.setOpen,y=e.toggleValueMapping,C=(0,d.useState)(null),O=C[0],P=C[1],E=(0,d.useState)(v),I=E[0],T=E[1];(0,d.useEffect)((function(){T(v)}),[v]);var _=((null===m||void 0===m||null===(n=m.current)||void 0===n||null===(t=n.getBoundingClientRect)||void 0===t?void 0:t.call(n))||{}).top,S=void 0===_?0:_,A=Object.keys(v);return(0,k.jsxs)(B.Z,{onClickOutside:s,open:!0,children:[(0,k.jsx)("div",{ref:m,children:u}),(0,k.jsxs)(F,{compact:l,display:p,top:S-5,children:[(0,k.jsxs)(q,{compact:l,children:[(0,k.jsx)(b.Z,{flex:"1",children:(0,k.jsx)(Q,{children:A.map((function(e){return(0,k.jsxs)(J,{highlighted:O===e,onMouseEnter:function(){return P(e)},children:[(0,k.jsx)(w.ZP,{children:(0,te.kC)(e)}),(0,k.jsx)(ee._Q,{})]},e)}))})}),(0,k.jsx)(b.Z,{flex:"2",children:(0,k.jsx)(K,{children:O&&Object.entries((null===(i=I||v)||void 0===i?void 0:i[O])||{}).map((function(e){var n,t=(0,o.Z)(e,2),i=t[0],u=t[1];return(0,k.jsxs)(X,{children:[(0,k.jsx)(w.ZP,{children:(null===y||void 0===y||null===(n=y[O])||void 0===n?void 0:n[i])||(0,te.J3)((0,te.kC)(i))}),(0,k.jsx)(M.Z,{checked:u,onCheck:function(){return T((function(e){return oe(oe({},e),{},(0,r.Z)({},O,oe(oe({},null===e||void 0===e?void 0:e[O]),{},(0,r.Z)({},i,!u))))}))}})]},i)}))})})]}),(0,k.jsx)(Z.Z,{m:1,children:(0,k.jsxs)(j.Z,{children:[(0,k.jsx)(h.Z,{onClick:function(){var e=Object.entries(I).reduce((function(e,n){var t=(0,o.Z)(n,2),i=t[0],r=t[1],u=[];return Object.entries(r).forEach((function(e){var n=(0,o.Z)(e,2),t=n[0];return n[1]&&u.push(t)})),e[i]=u,e}),{});null===c||void 0===c||c(g,e),(0,ne.g_)(g,e,{addingMultipleValues:!0,pushHistory:!0})},secondary:!0,children:"Apply"}),(0,k.jsx)(Z.Z,{mr:1}),(0,k.jsx)(h.Z,{noBackground:!0,onClick:function(){x(!1),null===a||void 0===a||a()},children:"Defaults"})]})})]})]})},le=t(46261),ce="".concat(1.5*V.iI,"px"),se=40*V.iI;!function(e){e[e.SECONDARY=1]="SECONDARY",e[e.DELETE=2]="DELETE"}(re||(re={}));var ae={autoHide:!0,size:null,widthFitContent:!0},de=t(7715),pe=t(9736),fe=t(91427),he="pipeline_list_filters",ve="pipeline_list_group_bys";function me(e){return(0,fe.t8)(he,e),e}function be(e){return(0,fe.t8)(ve,e),e}function je(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 ge(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?je(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):je(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var xe=function(e){var n=e.addButtonProps,t=e.deleteRowProps,i=e.filterOptions,r=void 0===i?{}:i,u=e.filterValueLabelMapping,l=e.groupButtonProps,c=e.moreActionsMenuItems,s=e.onFilterApply,a=e.query,f=void 0===a?{}:a,h=e.searchProps,v=e.secondaryActionButtonProps,m=e.selectedRowId,g=e.setSelectedRow,y=(0,pe.Ct)(),C=(0,p.useRouter)(),P=(0,d.useRef)(null),E=(0,d.useRef)(null),I=(0,d.useRef)(null),T=(0,d.useRef)(null),_=(0,d.useRef)(null),S=(0,d.useState)(!1),A=S[0],M=S[1],G=(0,d.useState)(!1),Y=G[0],U=G[1],z=(0,d.useState)(!1),W=z[0],F=z[1],q=(0,d.useState)(!1),Q=q[0],K=q[1],$=(0,d.useState)(null),J=$[0],X=$[1],ne=!m,te=(0,d.useCallback)((function(){return M(!1)}),[]),ie=(0,d.useCallback)((function(){return U(!1)}),[]),oe=(0,d.useCallback)((function(){return F(!1)}),[]),fe=(0,d.useCallback)((function(){return K(null)}),[]),he=(0,d.useCallback)((function(){return X(null)}),[]),ve=v||{},be=ve.Icon,je=ve.confirmationDescription,xe=ve.confirmationMessage,ye=ve.isLoading,Ze=ve.label,we=ve.onClick,Ce=ve.openConfirmationDialogue,Oe=ve.tooltip,ke=t||{},Pe=ke.confirmationMessage,Ee=ke.isLoading,Ie=ke.item,Te=ke.onDelete,_e=h||{},Se=_e.placeholder,Ae=_e.onChange,Me=_e.value,De=(0,d.useMemo)((function(){return Object.entries(r).reduce((function(e,n){var t=(0,o.Z)(n,2),i=t[0],r=t[1];return e[i]={},r.forEach((function(n){var t,o=(null===(t=f["".concat(i,"[]")])||void 0===t?void 0:t.includes(n))||!1;e[i][n]=o})),e}),{})}),[r,f]),Re=n||{},Be=Re.label,Ne=Re.menuItems,Le=Re.isLoading,Ge=(0,d.useMemo)((function(){return(0,k.jsx)(D.Z,{addButtonMenuOpen:A,addButtonMenuRef:P,isLoading:Le,label:Be,menuItems:Ne,onClick:function(){return M((function(e){return!e}))},onClickCallback:te})}),[Be,Ne,A,te,Le]),Ye=(0,d.useMemo)((function(){return(0,de.dw)(De)}),[De]),He=(0,d.useMemo)((function(){return(0,k.jsx)(ue,{compact:!0,onClickCallback:function(e,n){s&&(null===s||void 0===s||s(e,n)),ie&&(null===ie||void 0===ie||ie())},onClickOutside:ie,onSecondaryClick:function(){me({}),C.push("/pipelines")},open:Y,options:De,parentRef:E,query:f,setOpen:U,toggleValueMapping:u,children:(0,k.jsx)(x.ZP,ge(ge({},D.B),{},{afterElement:Ye>0?(0,k.jsx)(R.Z,{cyan:!0,noVerticalPadding:!0,children:(0,k.jsx)(w.ZP,{bold:!0,inverted:!0,children:Ye})}):null,beforeElement:(0,k.jsx)(ee.wn,{size:2*V.iI}),onClick:function(){return U((function(e){return!e}))},uuid:"Table/Toolbar/FilterButton",children:"Filter"}))})}),[ie,Y,De,u,Ye,s,f,C]),Ue=l||{},Ve=Ue.groupByLabel,ze=Ue.menuItems,We=(0,d.useMemo)((function(){return(0,k.jsx)(N.Z,{disableKeyboardShortcuts:!0,items:ze,onClickCallback:oe,onClickOutside:oe,open:W,parentRef:I,roundedStyle:!0,topOffset:1,uuid:"Table/Toolbar/GroupMenu",children:(0,k.jsx)(x.ZP,ge(ge({},D.B),{},{beforeElement:(0,k.jsx)(ee.ZA,{size:2.5*V.iI}),onClick:function(){F((function(e){return!e}))},uuid:"Table/Toolbar/GroupButton",children:Ve?"Grouped by ".concat(Ve):"Group"}))})}),[oe,W,Ve,ze]),Fe=(0,d.useMemo)((function(){return(0,k.jsx)(N.Z,{disableKeyboardShortcuts:!0,items:c,onClickCallback:fe,onClickOutside:fe,open:Q,parentRef:T,roundedStyle:!0,topOffset:1,uuid:"Table/Toolbar/MoreActionsMenu",children:(0,k.jsx)(le.Z,ge(ge({},ae),{},{label:"More actions",children:(0,k.jsx)(x.ZP,{Icon:ee.mH,bold:!0,disabled:ne,greyBorder:!0,onClick:function(){return K((function(e){return!e}))},smallIcon:!0,uuid:"Table/Toolbar/MoreActionsButton"})}))})}),[fe,ne,Q,c]);return(0,k.jsxs)(j.Z,{alignItems:"center",children:[Ge,(0,k.jsx)(Z.Z,{mr:ce}),He,(null===ze||void 0===ze?void 0:ze.length)>0&&(0,k.jsx)(Z.Z,{ml:ce,children:We}),!y&&we&&(0,k.jsxs)(Z.Z,{ml:ce,children:[(0,k.jsx)(le.Z,ge(ge({},ae),{},{label:Oe,children:(0,k.jsx)(x.ZP,{Icon:!ye&&be,bold:!0,disabled:ne,greyBorder:!0,loading:ye,onClick:Ce?function(){return X(re.SECONDARY)}:we,smallIcon:!0,uuid:"Table/Toolbar/SecondaryActionButton",children:Ze})})),(0,k.jsx)(B.Z,{onClickOutside:he,open:J===re.SECONDARY,children:(0,k.jsx)(L.Z,{onCancel:he,onClick:function(){we(),he(),g(null)},subtitle:je,title:xe,top:58,width:se})})]}),!y&&Te&&(0,k.jsxs)(Z.Z,{ml:ce,children:[(0,k.jsx)(le.Z,ge(ge({},ae),{},{label:"Delete ".concat(Ie),children:(0,k.jsx)(x.ZP,{Icon:!Ee&&ee.rF,bold:!0,disabled:ne,greyBorder:!0,loading:Ee,onClick:function(){return X(re.DELETE)},smallIcon:!0,uuid:"Table/Toolbar/DeleteButton"})})),(0,k.jsx)(B.Z,{onClickOutside:he,open:J===re.DELETE,children:(0,k.jsx)(L.Z,{danger:!0,onCancel:he,onClick:function(){Te(m),he(),g(null)},subtitle:Pe,title:"Are you sure you want to delete the ".concat(Ie," ").concat(m,"?"),top:58,width:se})})]}),!y&&(null===c||void 0===c?void 0:c.length)>0&&(0,k.jsx)(Z.Z,{ml:ce,children:Fe}),Ae&&(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(Z.Z,{ml:ce}),(0,k.jsx)(b.Z,{flex:1,children:(0,k.jsx)(O.Z,{afterIcon:Me?(0,k.jsx)(ee.x8,{}):null,afterIconClick:function(){var e;Ae(""),null===_||void 0===_||null===(e=_.current)||void 0===e||e.focus()},afterIconSize:1.5*V.iI,beforeIcon:(0,k.jsx)(ee.HN,{}),borderRadius:H.n_,defaultColor:!0,fullWidth:!0,greyBorder:!0,maxWidth:60*V.iI,onChange:function(e){return Ae(e.target.value)},paddingVertical:9,placeholder:Se||null,ref:_,value:Me})})]})]})},ye=t(82531),Ze=t(86422),we=t(9728),Ce=t(3055),Oe=t(27337),ke=t(18908),Pe=t(93348),Ee=t(45838),Ie=t(96510),Te=t(59e3),_e=t(64651),Se=t(66653),Ae=t(24224),Me=t(99497);function De(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 Re(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?De(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):De(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var Be={borderRadius:H.BG,iconOnly:!0,noBackground:!0,noBorder:!0,outline:!0,padding:"4px"};function Ne(){var e=(0,p.useRouter)(),n=(0,d.useRef)(null),t=(0,d.useState)(null),i=t[0],u=t[1],l=(0,d.useState)(null),c=l[0],x=l[1],C=(0,d.useState)({}),O=C[0],T=C[1],D=(0,d.useState)(null),R=D[0],B=D[1],N=(0,Te.iV)(),L=(0,Te.DQ)(N,[I.$1.STATUS,I.$1.TAG,I.$1.TYPE]),G=ye.ZP.pipelines.list(Re(Re({},L),{},{include_schedules:1})),H=G.data,U=G.mutate,z=(0,d.useMemo)((function(){var e=(null===H||void 0===H?void 0:H.pipelines)||[];if(c){var n=c.toLowerCase();e=e.filter((function(e){var t=e.name,i=e.description,o=e.uuid;return(null===t||void 0===t?void 0:t.toLowerCase().includes(n))||(null===o||void 0===o?void 0:o.toLowerCase().includes(n))||(null===i||void 0===i?void 0:i.toLowerCase().includes(n))}))}return e}),[null===H||void 0===H?void 0:H.pipelines,c]),W=ye.ZP.projects.list(),F=W.data,q=W.mutate,Q=(0,d.useMemo)((function(){var e;return null===F||void 0===F||null===(e=F.projects)||void 0===e?void 0:e[0]}),[F]),K=null===N||void 0===N?void 0:N[I.$1.GROUP];(0,d.useEffect)((function(){var e={};if(K)be((0,r.Z)({},K,!0));else{var n,t=(0,fe.U2)(ve,{});t&&Object.entries(t).forEach((function(e){var t=(0,o.Z)(e,2),i=t[0],r=t[1];!n&&r&&(n=i)})),n&&(e[I.$1.GROUP]=n)}if((0,de.Qr)(L)){var i={},u=(0,fe.U2)(he,{});u&&Object.entries(u).forEach((function(e){var n=(0,o.Z)(e,2),t=n[0],r=n[1];i[t]=[],Object.entries(r).forEach((function(e){var n=(0,o.Z)(e,2),r=n[0];n[1]&&i[t].push(r)}))})),(0,de.Qr)(i)||(e=Re(Re({},e),i))}else{var l={};Object.entries(L).forEach((function(e){var n=(0,o.Z)(e,2),t=n[0],i=n[1];l[t]={};var r,u=i;(Array.isArray(u)||(u=[u]),u&&Array.isArray(u))&&(null===(r=u)||void 0===r||r.forEach((function(e){l[t][e]=!0})))})),me(l)}(0,de.Qr)(e)||(0,ne.u7)(e,{pushHistory:!1})}),[K,L]),(0,d.useEffect)((function(){(0,Ie.bB)(H,B)}),[H]);var $=function(e){return(0,a.Db)(ye.ZP.pipelines.useCreate(),{onSuccess:function(n){return(0,Ie.wD)(n,{callback:function(n){var t=n.pipeline.uuid;null===e||void 0===e||e(t)},onErrorCallback:function(e,n){return B({errors:n,response:e})}})}})},J=$((function(n){return e.push("/pipelines/[pipeline]/edit","/pipelines/".concat(n,"/edit"))})),X=(0,o.Z)(J,2),ie=X[0],oe=X[1].isLoading,re=$((function(){return null===U||void 0===U?void 0:U()})),ue=(0,o.Z)(re,2),le=ue[0],ce=ue[1].isLoading,se=(0,a.Db)((function(e){return ye.ZP.pipelines.useUpdate(e.uuid)({pipeline:e})}),{onSuccess:function(e){return(0,Ie.wD)(e,{callback:function(e){var n=e.pipeline.uuid;T((function(e){return Re(Re({},e),{},(0,r.Z)({},n,!1))})),U(),null===Ue||void 0===Ue||Ue(),u(null)},onErrorCallback:function(e,n){var t,i=null===e||void 0===e||null===(t=e.url_parameters)||void 0===t?void 0:t.pk;T((function(e){return Re(Re({},e),{},(0,r.Z)({},i,!1))})),B({errors:n,response:e})}})}}),ae=(0,o.Z)(se,2),pe=ae[0],je=ae[1].isLoading,ge=(0,a.Db)((function(e){return ye.ZP.pipelines.useDelete(e)()}),{onSuccess:function(e){return(0,Ie.wD)(e,{callback:function(){null===U||void 0===U||U()},onErrorCallback:function(e,n){return B({errors:n,response:e})}})}}),De=(0,o.Z)(ge,2),Ne=De[0],Le=De[1].isLoading,Ge=(0,Me.dd)((function(e){var n=e.pipeline,t=e.pipelineDescription,o=e.pipelineName;return(0,k.jsx)(P,{isLoading:je,minWidth:55*V.iI,noEmptyValue:!!o,onClose:Ue,onSave:function(e){var t=n||i;if(t){var u=t.uuid,l={uuid:u};o?l.name=e:l.description=e,T((function(e){return Re(Re({},e),{},(0,r.Z)({},u,!0))})),pe(l)}},textArea:!o,title:o?"Rename pipeline":"Edit description",value:o||t})}),{},[je,i],{background:!0,uuid:"rename_pipeline_and_save"}),Ye=(0,o.Z)(Ge,2),He=Ye[0],Ue=Ye[1],Ve=(0,Me.dd)((function(){return(0,k.jsx)(we.BC,{children:(0,k.jsx)(f.Z,{contained:!0,onClickCustomTemplate:function(e){ie({pipeline:{custom_template_uuid:null===e||void 0===e?void 0:e.template_uuid,name:(0,te.Y6)()}}).then((function(){Fe()}))},showBreadcrumbs:!0,tabs:[Oe.A2]})})}),{},[],{background:!0,uuid:"browse_templates"}),ze=(0,o.Z)(Ve,2),We=ze[0],Fe=ze[1],qe=(0,d.useMemo)((function(){return(0,_e.d)(ie,{showBrowseTemplates:We})}),[ie,We]),Qe=ye.ZP.tags.list().data,Ke=(0,d.useMemo)((function(){return(0,Ae.YC)((null===Qe||void 0===Qe?void 0:Qe.tags)||[],(function(e){return e.uuid}))}),[Qe]),$e=(0,d.useMemo)((function(){return(0,k.jsx)(xe,{addButtonProps:{isLoading:oe,label:"New",menuItems:qe},deleteRowProps:{confirmationMessage:"This is irreversible and will immediately delete everything associated with the pipeline, including its blocks, triggers, runs, logs, and history.",isLoading:Le,item:"pipeline",onDelete:function(){window.confirm("Are you sure you want to delete pipeline ".concat(null===i||void 0===i?void 0:i.uuid,"?"))&&Ne(null===i||void 0===i?void 0:i.uuid)}},filterOptions:{status:Object.values(I.QK),tag:Ke.map((function(e){return e.uuid})),type:Object.values(I.qL)},filterValueLabelMapping:{tag:Ke.reduce((function(e,n){var t=n.uuid;return Re(Re({},e),{},(0,r.Z)({},t,t))}),{}),type:I.G7},groupButtonProps:{groupByLabel:K,menuItems:[{beforeIcon:K===I.r0.STATUS?(0,k.jsx)(ee.Jr,{fill:Y.Z.content.default,size:1.5*V.iI}):(0,k.jsx)(ee.Cd,{muted:!0,size:1.5*V.iI}),label:function(){return(0,te.kC)(I.r0.STATUS)},onClick:function(){var e=K===I.r0.STATUS?null:I.r0.STATUS;e||be({}),(0,ne.u7)((0,r.Z)({},I.$1.GROUP,e),{pushHistory:!0})},uuid:"Pipelines/GroupMenu/Status"},{beforeIcon:K===I.r0.TAG?(0,k.jsx)(ee.Jr,{fill:Y.Z.content.default,size:1.5*V.iI}):(0,k.jsx)(ee.Cd,{muted:!0,size:1.5*V.iI}),label:function(){return(0,te.kC)(I.r0.TAG)},onClick:function(){var e=K===I.r0.TAG?null:I.r0.TAG;e||be({}),(0,ne.u7)((0,r.Z)({},I.$1.GROUP,e),{pushHistory:!0})},uuid:"Pipelines/GroupMenu/Tag"},{beforeIcon:K===I.r0.TYPE?(0,k.jsx)(ee.Jr,{fill:Y.Z.content.default,size:1.5*V.iI}):(0,k.jsx)(ee.Cd,{muted:!0,size:1.5*V.iI}),label:function(){return(0,te.kC)(I.r0.TYPE)},onClick:function(){var e=K===I.r0.TYPE?null:I.r0.TYPE;e||be({}),(0,ne.u7)((0,r.Z)({},I.$1.GROUP,e),{pushHistory:!0})},uuid:"Pipelines/GroupMenu/Type"}]},moreActionsMenuItems:[{label:function(){return"Rename pipeline"},onClick:function(){return He({pipelineName:null===i||void 0===i?void 0:i.name})},uuid:"Pipelines/MoreActionsMenu/Rename"},{label:function(){return"Edit description"},onClick:function(){return He({pipelineDescription:null===i||void 0===i?void 0:i.description})},uuid:"Pipelines/MoreActionsMenu/EditDescription"}],onFilterApply:function(e,n){Object.values(n).every((function(e){return!(null!==e&&void 0!==e&&e.length)}))&&me({})},query:L,searchProps:{onChange:x,value:c},secondaryActionButtonProps:{Icon:ee.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===i||void 0===i?void 0:i.uuid,"?"),isLoading:ce,onClick:function(){return le({pipeline:{clone_pipeline_uuid:null===i||void 0===i?void 0:i.uuid}})},openConfirmationDialogue:!0,tooltip:"Clone pipeline"},selectedRowId:null===i||void 0===i?void 0:i.uuid,setSelectedRow:u})}),[le,Ne,K,ce,oe,Le,qe,L,c,null===i||void 0===i?void 0:i.description,null===i||void 0===i?void 0:i.name,null===i||void 0===i?void 0:i.uuid,He,Ke]),Je=(0,we.VI)(null,{},[],{uuid:"pipelines/list"}),Xe=(0,o.Z)(Je,1)[0],en=(0,a.Db)(ye.ZP.projects.useUpdate(null===Q||void 0===Q?void 0:Q.name),{onSuccess:function(e){return(0,Ie.wD)(e,{callback:function(){q()},onErrorCallback:function(e,n){return Xe({errors:n,response:e})}})}}),nn=(0,o.Z)(en,2),tn=nn[0],on=nn[1].isLoading,rn=(0,d.useCallback)((function(e){return tn({project:e})}),[tn]),un=(0,Me.dd)((function(){return(0,k.jsxs)(y.Z,{maxWidth:60*V.iI,children:[(0,k.jsx)(Z.Z,{mb:1,children:(0,k.jsx)(g.Z,{children:"Help improve Mage"})}),(0,k.jsx)(Z.Z,{mb:V.cd,children:(0,k.jsx)(w.ZP,{default:!0,children:"Please contribute usage statistics to help improve the developer experience for you and everyone in the community \ud83e\udd1d."})}),(0,k.jsx)(Z.Z,{mb:V.cd,children:(0,k.jsx)(y.Z,{success:!0,children:(0,k.jsxs)(j.Z,{alignItems:"center",children:[(0,k.jsx)(ee.Yo,{size:5*V.iI,success:!0}),(0,k.jsx)(Z.Z,{mr:1}),(0,k.jsx)(b.Z,{children:(0,k.jsx)(w.ZP,{children:"All usage statistics are completely anonymous. It\u2019s impossible for Mage to know which statistics belongs to whom."})})]})})}),(0,k.jsx)(Z.Z,{mb:V.cd,children:(0,k.jsxs)(w.ZP,{default:!0,children:["By opting into sending usage statistics to ",(0,k.jsx)(E.Z,{href:"https://www.mage.ai",openNewWindow:!0,children:"Mage"}),", it\u2019ll help the team and community of contributors (",(0,k.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,k.jsx)(Z.Z,{mb:V.cd,children:(0,k.jsx)(w.ZP,{default:!0,children:"In addition to helping reduce potential errors, you\u2019ll help inform which features are useful and which need work."})}),(0,k.jsx)(Z.Z,{mb:V.cd,children:(0,k.jsxs)(j.Z,{alignItems:"center",justifyContent:"space-between",children:[(0,k.jsx)(w.ZP,{bold:!0,children:"I want to help make Mage more powerful for everyone"}),(0,k.jsx)(Z.Z,{mr:V.cd}),(0,k.jsx)(M.Z,{checked:!0,onCheck:function(){window.confirm("Are you sure you don\u2019t want to help everyone in the community?")&&rn({help_improve_mage:!1}).then((function(){return sn()}))}})]})}),on&&(0,k.jsx)(Z.Z,{mb:V.cd,children:(0,k.jsx)(_.Z,{inverted:!0})}),(0,k.jsx)(Z.Z,{mb:V.cd,children:(0,k.jsxs)(w.ZP,{muted:!0,small:!0,children:["To learn more about how this works, please check out the ",(0,k.jsx)(E.Z,{href:"https://docs.mage.ai/contributing/statistics/overview",openNewWindow:!0,small:!0,children:"documentation"}),"."]})}),(0,k.jsx)(h.Z,{onClick:function(){return rn({help_improve_mage:!0}).then((function(){return sn()}))},secondary:!0,children:"Close"})]})}),{},[Q],{background:!0,hideCallback:function(){rn({help_improve_mage:!0})},uuid:"help_mage"}),ln=(0,o.Z)(un,2),cn=ln[0],sn=ln[1];(0,d.useEffect)((function(){Q&&null===(null===Q||void 0===Q?void 0:Q.help_improve_mage)&&cn()}),[Q,cn]);var an=(0,d.useMemo)((function(){var e={};null===z||void 0===z||z.forEach((function(n,t){var i=n[K];if(I.r0.STATUS===K){var o=n.schedules,r=void 0===o?[]:o,u=r.length;i=r.find((function(e){var n=e.status;return Pe.fq.ACTIVE===n}))?I.QK.ACTIVE:u>=1?I.QK.INACTIVE:I.QK.NO_SCHEDULES}else if(I.r0.TAG===K){i=(null===n||void 0===n?void 0:n.tags)?(0,Ae.YC)(n.tags,(function(e){return e})).join(", "):""}e[i]||(e[i]=[]),e[i].push(t)}));var n=[],t=[];return I.r0.STATUS===K?Object.values(I.QK).forEach((function(i){n.push(e[i]),t.push((0,te.vg)(i))})):I.r0.TAG===K?(0,Ae.YC)(Object.keys(e),(function(e){return e})).forEach((function(i){n.push(e[i]),i?t.push(i.split(", ").map((function(e,n){return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)("div",{style:{marginLeft:n>=1?4:0}},"".concat(e,"-").concat(n,"-spacing")),(0,k.jsx)(v.Z,{small:!0,children:(0,k.jsx)(w.ZP,{children:e})},"".concat(e,"-").concat(n))]})}))):t.push("No tags")})):I.r0.TYPE===K&&Object.values(I.qL).forEach((function(i){n.push(e[i]),t.push(I.G7[i])})),{rowGroupHeaders:t,rowsGroupedByIndex:n}}),[K,z]),dn=an.rowGroupHeaders,pn=an.rowsGroupedByIndex;return(0,k.jsx)(m.Z,{errors:R,setErrors:B,subheaderChildren:$e,title:"Pipelines",uuid:"pipelines/index",children:0===(null===z||void 0===z?void 0:z.length)?(0,k.jsx)(Z.Z,{px:3,py:1,children:H?(0,k.jsx)(w.ZP,{bold:!0,default:!0,monospace:!0,muted:!0,children:"No pipelines available"}):(0,k.jsx)(_.Z,{inverted:!0,large:!0})}):(0,k.jsx)(Ee.cl,{includePadding:!!K,maxHeight:"calc(100vh - ".concat(Ce.Mz+74,"px)"),children:(0,k.jsx)(S.Z,{columnFlex:[null,null,null,2,null,null,1,null,null,null],columns:[{label:function(){return""},uuid:"action"},{uuid:(0,te.kC)(I.r0.STATUS)},{uuid:"Name"},{uuid:"Description"},{uuid:(0,te.kC)(I.r0.TYPE)},{uuid:"Updated at"},{uuid:"Tags"},{uuid:"Blocks"},{uuid:"Triggers"},{center:!0,label:function(){return""},uuid:"Actions"}],isSelectedRow:function(e){var n;return(null===(n=z[e])||void 0===n?void 0:n.uuid)===(null===i||void 0===i?void 0:i.uuid)},onClickRow:function(e){return u((function(n){var t=z[e];return(null===n||void 0===n?void 0:n.uuid)!==(null===t||void 0===t?void 0:t.uuid)?t:null}))},onDoubleClickRow:function(n){e.push("/pipelines/[pipeline]/edit","/pipelines/".concat(z[n].uuid,"/edit"))},ref:n,renderRightClickMenuItems:function(n){var t=z[n];return[{label:function(){return"Edit description"},onClick:function(){return He({pipeline:t,pipelineDescription:null===t||void 0===t?void 0:t.description})},uuid:"edit_description"},{label:function(){return"Rename"},onClick:function(){return He({pipeline:t,pipelineName:null===t||void 0===t?void 0:t.name})},uuid:"rename"},{label:function(){return"Clone"},onClick:function(){return le({pipeline:{clone_pipeline_uuid:null===t||void 0===t?void 0:t.uuid}})},uuid:"clone"},{label:function(){return"Add/Remove tags"},onClick:function(){e.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(){e.push("/templates?object_type=".concat(ke.R,"&new=1&pipeline_uuid=").concat(null===t||void 0===t?void 0:t.uuid))},uuid:"create_custom_template"},{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,"?"))&&Ne(null===t||void 0===t?void 0:t.uuid)},uuid:"delete"}]},rowGroupHeaders:dn,rows:z.map((function(n,t){var i=n.blocks,o=n.description,u=n.schedules,l=n.tags,c=n.type,a=n.updated_at,d=n.uuid,p=i.filter((function(e){var n=e.type;return Ze.tf.SCRATCHPAD!==n})).length,f=u.length,v=u.find((function(e){var n=e.status;return Pe.fq.ACTIVE===n})),m=(0,k.jsx)("div",{children:(0,k.jsx)(A.Z,{tags:null===l||void 0===l?void 0:l.map((function(e){return{uuid:e}}))})},"pipeline_tags_".concat(t));return[f>=1||O[d]?(0,k.jsx)(h.Z,{iconOnly:!0,loading:!!O[d],noBackground:!0,noBorder:!0,noPadding:!0,onClick:function(e){(0,Se.j)(e),T((function(e){return Re(Re({},e),{},(0,r.Z)({},d,!0))})),pe(Re(Re({},n),{},{status:v?Pe.fq.INACTIVE:Pe.fq.ACTIVE}))},children:v?(0,k.jsx)(ee.dz,{muted:!0,size:2*V.iI}):(0,k.jsx)(ee.Py,{default:!0,size:2*V.iI})}):null,(0,k.jsx)(w.ZP,{default:!v,monospace:!0,success:!!v,children:v?Pe.fq.ACTIVE:f>=1?Pe.fq.INACTIVE:"no schedules"},"pipeline_status_".concat(t)),(0,k.jsx)(s(),{as:"/pipelines/".concat(d),href:"/pipelines/[pipeline]",passHref:!0,children:(0,k.jsx)(E.Z,{sameColorAsText:!0,children:d})},"pipeline_name_".concat(t)),(0,k.jsx)(w.ZP,{default:!0,title:o,width:90*V.iI,children:o},"pipeline_description_".concat(t)),(0,k.jsx)(w.ZP,{children:I.G7[c]},"pipeline_type_".concat(t)),(0,k.jsx)(w.ZP,{monospace:!0,small:!0,title:a,children:a?a.slice(0,-3):(0,k.jsx)(k.Fragment,{children:"\u2014"})},"pipeline_updated_at_".concat(t)),m,(0,k.jsx)(w.ZP,{default:0===p,monospace:!0,children:p},"pipeline_block_count_".concat(t)),(0,k.jsx)(w.ZP,{default:0===f,monospace:!0,children:f},"pipeline_trigger_count_".concat(t)),(0,k.jsxs)(b.Z,{flex:1,justifyContent:"flex-end",children:[(0,k.jsx)(h.Z,Re(Re({},Be),{},{onClick:function(){e.push("/pipelines/[pipeline]","/pipelines/".concat(d))},title:"Detail",children:(0,k.jsx)(ee.UY,{default:!0,size:2*V.iI})})),(0,k.jsx)(Z.Z,{mr:1}),(0,k.jsx)(h.Z,Re(Re({},Be),{},{onClick:function(){e.push("/pipelines/[pipeline]/logs","/pipelines/".concat(d,"/logs"))},title:"Logs",children:(0,k.jsx)(ee.$B,{default:!0,size:2*V.iI})}))]},"chevron_icon_".concat(t))]})),rowsGroupedByIndex:pn,stickyHeader:!0})})})}Ne.getInitialProps=(0,i.Z)(l().mark((function e(){return l().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",{});case 1:case"end":return e.stop()}}),e)})));var Le=(0,T.Z)(Ne)},79274:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/pipelines",function(){return t(12257)}])}},function(e){e.O(0,[844,9902,426,1774,8792,8789,4259,9055,1424,1005,7815,3654,8952,7722,4822,1484,2485,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([[3853],{1210:function(e,n,t){"use strict";t.d(n,{Z:function(){return P}});var r=t(82394),i=t(21831),o=t(82684),c=t(47999),u=t(49894),l=t(93461),a=t(57384),s=t(41424),d=t(72454),f=t(28598);function p(e,n){var t=e.children;return(0,f.jsx)(d.HS,{ref:n,children:t})}var h=o.forwardRef(p),m=t(32063),g=t(85019),b=t(82531),j=t(66166),v=t(3055),y=t(49125),x=t(91427),O=t(24141);function w(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function Z(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?w(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):w(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var P=function(e){var n,t=e.addProjectBreadcrumbToCustomBreadcrumbs,r=e.after,p=e.afterHidden,w=e.afterWidth,P=e.afterWidthOverride,_=e.before,k=e.beforeWidth,I=e.breadcrumbs,S=e.children,C=e.errors,H=e.headerMenuItems,N=e.headerOffset,D=e.mainContainerHeader,W=e.navigationItems,E=e.setErrors,z=e.subheaderChildren,M=e.title,A=e.uuid,B=(0,O.i)().width,R="dashboard_after_width_".concat(A),F="dashboard_before_width_".concat(A),T=(0,o.useRef)(null),L=(0,o.useState)(P?w:(0,x.U2)(R,w)),V=L[0],U=L[1],Y=(0,o.useState)(!1),Q=Y[0],X=Y[1],G=(0,o.useState)(_?Math.max((0,x.U2)(F,k),13*y.iI):null),J=G[0],q=G[1],K=(0,o.useState)(!1),$=K[0],ee=K[1],ne=(0,o.useState)(null)[1],te=b.ZP.projects.list({},{revalidateOnFocus:!1}).data,re=null===te||void 0===te?void 0:te.projects,ie={label:function(){var e;return null===re||void 0===re||null===(e=re[0])||void 0===e?void 0:e.name},linkProps:{href:"/"}},oe=[];I?(t&&oe.push(ie),oe.push.apply(oe,(0,i.Z)(I))):(null===re||void 0===re?void 0:re.length)>=1&&oe.push.apply(oe,[ie,{bold:!0,label:function(){return M}}]),(0,o.useEffect)((function(){null===T||void 0===T||!T.current||Q||$||null===ne||void 0===ne||ne(T.current.getBoundingClientRect().width)}),[Q,V,$,J,T,ne,B]),(0,o.useEffect)((function(){Q||(0,x.t8)(R,V)}),[p,Q,V,R]),(0,o.useEffect)((function(){$||(0,x.t8)(F,J)}),[$,J,F]);var ce=(0,j.Z)(w);return(0,o.useEffect)((function(){P&&ce!==w&&U(w)}),[P,w,ce]),(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(a.Z,{title:M}),(0,f.jsx)(s.Z,{breadcrumbs:oe,menuItems:H,project:null===re||void 0===re?void 0:re[0],version:null===re||void 0===re||null===(n=re[0])||void 0===n?void 0:n.version}),(0,f.jsxs)(d.Nk,{children:[0!==(null===W||void 0===W?void 0:W.length)&&(0,f.jsx)(d.lm,{showMore:!0,children:(0,f.jsx)(g.Z,{navigationItems:W,showMore:!0})}),(0,f.jsx)(l.Z,{flex:1,flexDirection:"column",children:(0,f.jsxs)(m.Z,{after:r,afterHeightOffset:v.Mz,afterHidden:p,afterMousedownActive:Q,afterWidth:V,before:_,beforeHeightOffset:v.Mz,beforeMousedownActive:$,beforeWidth:d.k1+(_?J:0),headerOffset:N,hideAfterCompletely:!0,leftOffset:_?d.k1:null,mainContainerHeader:D,mainContainerRef:T,setAfterMousedownActive:X,setAfterWidth:U,setBeforeMousedownActive:ee,setBeforeWidth:q,children:[z&&(0,f.jsx)(h,{children:z}),S]})})]}),C&&(0,f.jsx)(c.Z,{disableClickOutside:!0,isOpen:!0,onClickOutside:function(){return null===E||void 0===E?void 0:E(null)},children:(0,f.jsx)(u.Z,Z(Z({},C),{},{onClose:function(){return null===E||void 0===E?void 0:E(null)}}))})]})}},2850:function(e,n,t){"use strict";t.d(n,{M:function(){return c},W:function(){return o}});var r=t(38626),i=t(3055),o=34*t(49125).iI,c=r.default.div.withConfig({displayName:"indexstyle__BeforeStyle",componentId:"sc-12ee2ib-0"})(["min-height:calc(100vh - ","px);"],i.Mz)},79585:function(e,n,t){"use strict";t.d(n,{DQ:function(){return s},HY:function(){return c},SA:function(){return d},WH:function(){return o},eC:function(){return l},fF:function(){return u},tC:function(){return a}});var r=t(81132),i=t(9736),o="Workspace",c="Preferences",u="Git settings",l="Users",a="Account",s="Profile",d=function(e){var n=e.owner,t=e.roles,d=e.project_access,f=[{linkProps:{href:"/settings/workspace/preferences"},uuid:c}];(n||t===r.No.ADMIN||0!==(2&d))&&f.push({linkProps:{href:"/settings/workspace/users"},uuid:l}),(!(0,i.YB)()||t<=r.No.EDITOR)&&f.push({linkProps:{href:"/settings/workspace/sync-data"},uuid:u});var p=[{items:f,uuid:o}];return(0,i.YB)()?p.concat([{items:[{linkProps:{href:"/settings/account/profile"},uuid:s}],uuid:a}]):p}},30775:function(e,n,t){"use strict";t.d(n,{Z:function(){return Z}});var r=t(1210),i=t(82394),o=t(12691),c=t.n(o),u=t(10919),l=t(86673),a=t(19711),s=t(38626),d=t(23831),f=t(49125),p=t(90880),h=(f.iI,s.default.div.withConfig({displayName:"indexstyle__SectionTitleStyle",componentId:"sc-1y8dyue-0"})(["padding:","px ","px;"],1*f.iI,2.5*f.iI)),m=s.default.div.withConfig({displayName:"indexstyle__ItemStyle",componentId:"sc-1y8dyue-1"})([""," padding:","px ","px;"," ",""],(0,p.eR)(),1.5*f.iI,2.5*f.iI,(function(e){return!e.selected&&"\n &:hover {\n background-color: ".concat((e.theme.background||d.Z.background).codeArea,";\n }\n ")}),(function(e){return e.selected&&"\n background-color: ".concat((e.theme.background||d.Z.background).codeTextarea,";\n ")})),g=t(28598),b=t(82684);function j(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function v(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?j(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):j(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var y=function(e){var n=e.isItemSelected,t=e.sections;return(0,g.jsx)(l.Z,{py:f.Gg,children:null===t||void 0===t?void 0:t.map((function(e){var t=e.items,r=e.title,i=e.uuid;return(0,g.jsxs)(l.Z,{children:[(0,g.jsx)(h,{children:(0,g.jsx)(a.ZP,{bold:!0,muted:!0,small:!0,uppercase:!0,children:r?r():i})}),null===t||void 0===t?void 0:t.map((function(e){var t=e.label,r=e.linkProps,o=e.onClick,l=e.uuid,a=t?t():l,s=(0,g.jsx)(m,{selected:null===n||void 0===n?void 0:n(v(v({},e),{},{uuidWorkspace:i})),children:a});return r?(0,b.createElement)(c(),v(v({},r),{},{key:l,passHref:!0}),(0,g.jsx)(u.Z,{block:!0,noHoverUnderline:!0,noOutline:!0,sameColorAsText:!0,children:s})):(0,g.jsx)(u.Z,{block:!0,noHoverUnderline:!0,noOutline:!0,onClick:o,preventDefault:!0,sameColorAsText:!0,children:s},l)}))]},i)}))})},x=t(2850),O=t(79585),w=t(9736);var Z=function(e){var n=e.after,t=e.afterHidden,i=e.children,o=e.uuidItemSelected,c=e.uuidWorkspaceSelected,u=(0,w.PR)()||{};return(0,g.jsx)(r.Z,{after:n,afterHidden:!n||t,afterWidth:n?50*f.iI:0,afterWidthOverride:!0,before:(0,g.jsx)(x.M,{children:(0,g.jsx)(y,{isItemSelected:function(e){var n=e.uuid,t=e.uuidWorkspace;return c===t&&o===n},sections:(0,O.SA)(u)})}),beforeWidth:x.W,title:"Settings",uuid:"settings/index",children:i})}},21853:function(e,n,t){"use strict";t.d(n,{Z:function(){return S}});var r=t(82394),i=t(75582),o=t(82684),c=t(83455),u=t(60328),l=t(34744),a=t(93461),s=t(67971),d=t(87372),f=t(10919),p=t(29237),h=t(86673),m=t(19711),g=t(82944),b=t(70902),j=t(82531),v=t(38626),y=t(23831),x=t(73942),O=t(49125),w=v.default.div.withConfig({displayName:"indexstyle__ContainerStyle",componentId:"sc-1b0w59t-0"})(["border-radius:","px;padding:","px;",""],x.n_,O.cd*O.iI,(function(e){return"\n background-color: ".concat((e.theme.background||y.Z.background).codeArea,";\n ")})),Z=t(96510),P=t(9728),_=t(28598);function k(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function 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}var S=function(e){var n=e.cancelButtonText,t=e.contained,v=e.header,y=e.onCancel,x=e.onSaveSuccess,k=(0,P.VI)(null,{},[],{uuid:"settings/workspace/preferences"}),S=(0,i.Z)(k,1)[0],C=(0,o.useState)(null),H=C[0],N=C[1],D=j.ZP.projects.list(),W=D.data,E=D.mutate,z=(0,o.useMemo)((function(){var e;return null===W||void 0===W||null===(e=W.projects)||void 0===e?void 0:e[0]}),[W]),M=z||{},A=M.name,B=M.project_uuid;(0,o.useEffect)((function(){H||N(z)}),[z,H]);var R=(0,c.Db)(j.ZP.projects.useUpdate(A),{onSuccess:function(e){return(0,Z.wD)(e,{callback:function(e){var n=e.project;E(),N(n),x&&(null===x||void 0===x||x(n))},onErrorCallback:function(e,n){return S({errors:n,response:e})}})}}),F=(0,i.Z)(R,2),T=F[0],L=F[1].isLoading,V=(0,o.useCallback)((function(e){return T({project:e})}),[T]),U=(0,_.jsxs)(_.Fragment,{children:[v,(0,_.jsxs)(p.Z,{noPadding:!0,children:[(0,_.jsxs)(h.Z,{p:O.cd,children:[(0,_.jsx)(h.Z,{mb:1,children:(0,_.jsx)(d.Z,{level:5,children:"Project name"})}),(0,_.jsx)(m.ZP,{default:!0,monospace:!0,children:A})]}),(0,_.jsx)(l.Z,{light:!0}),(0,_.jsxs)(h.Z,{p:O.cd,children:[(0,_.jsx)(h.Z,{mb:1,children:(0,_.jsx)(d.Z,{level:5,children:"Project UUID"})}),(0,_.jsx)(m.ZP,{default:!!B,monospace:!0,muted:!B,children:B||"Not required"})]}),(0,_.jsx)(l.Z,{light:!0}),(0,_.jsx)(h.Z,{p:O.cd,children:(0,_.jsxs)(s.Z,{alignItems:"center",justifyContent:"space-between",children:[(0,_.jsxs)(a.Z,{flexDirection:"column",children:[(0,_.jsx)(h.Z,{mb:1,children:(0,_.jsx)(d.Z,{level:5,children:"Help improve Mage"})}),(0,_.jsxs)(m.ZP,{default:!0,children:["Please contribute usage statistics to help improve the developer experience for you and everyone in the community. Learn more ",(0,_.jsx)(f.Z,{href:"https://docs.mage.ai/contributing/statistics/overview",openNewWindow:!0,children:"here"}),"."]})]}),(0,_.jsx)(h.Z,{mr:O.cd}),(0,_.jsx)(b.Z,{checked:null===H||void 0===H?void 0:H.help_improve_mage,onCheck:function(){return N((function(e){return I(I({},e),{},{help_improve_mage:!(null!==H&&void 0!==H&&H.help_improve_mage)})}))}})]})})]}),(0,_.jsx)(h.Z,{mt:O.HN}),(0,_.jsx)(p.Z,{noPadding:!0,children:(0,_.jsxs)(h.Z,{p:O.cd,children:[(0,_.jsx)(h.Z,{mb:1,children:(0,_.jsx)(d.Z,{level:5,children:"Features"})}),Object.entries((null===H||void 0===H?void 0:H.features)||{}).map((function(e){var n=(0,i.Z)(e,2),t=n[0],o=n[1];return(0,_.jsxs)(s.Z,{alignItems:"center",justifyContent:"space-between",children:[(0,_.jsx)(m.ZP,{default:!0,monospace:!0,children:t}),(0,_.jsx)(h.Z,{mr:O.cd}),(0,_.jsx)(b.Z,{checked:!!o,onCheck:function(){return N((function(e){return I(I({},e),{},{features:I(I({},null===H||void 0===H?void 0:H.features),{},(0,r.Z)({},t,!o))})}))}})]},t)}))]})}),(0,_.jsx)(h.Z,{mt:O.HN}),(0,_.jsx)(p.Z,{noPadding:!0,children:(0,_.jsxs)(h.Z,{p:O.cd,children:[(0,_.jsx)(h.Z,{mb:1,children:(0,_.jsx)(d.Z,{level:5,children:"OpenAI"})}),(0,_.jsx)(g.Z,{label:"API key",monospace:!0,onChange:function(e){return N((function(n){return I(I({},n),{},{openai_api_key:e.target.value})}))},primary:!0,setContentOnMount:!0,value:(null===H||void 0===H?void 0:H.openai_api_key)||""})]})}),(0,_.jsx)(h.Z,{mt:O.HN}),(0,_.jsxs)(s.Z,{alignItems:"center",children:[(0,_.jsx)(u.Z,{loading:L,onClick:function(){V({features:null===H||void 0===H?void 0:H.features,help_improve_mage:null===H||void 0===H?void 0:H.help_improve_mage,openai_api_key:null===H||void 0===H?void 0:H.openai_api_key})},primary:!0,children:"Save project settings"}),y&&(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(h.Z,{mr:O.cd}),(0,_.jsx)(u.Z,{onClick:y,secondary:!0,children:n||"Cancel"})]})]})]});return t?(0,_.jsx)(w,{children:U}):U}},76096:function(e,n,t){"use strict";var r=t(82394),i=t(26304),o=(t(82684),t(33591)),c=t(28598),u=["children","fullHeight","gutter","style"];function l(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function a(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?l(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):l(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,r=e.gutter,l=e.style,s=void 0===l?{}:l,d=(0,i.Z)(e,u),f=a({},s);return r&&(f.paddingLeft=r,f.paddingRight=f.paddingLeft),t&&(f.height="100%"),(0,c.jsx)(o.Col,a(a({},d),{},{style:f,children:n}))}},97361:function(e,n,t){"use strict";var r=t(82394),i=t(26304),o=t(82684),c=t(33591),u=t(28598),l=["children","fullHeight","gutter","justifyContent","style"];function a(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function s(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?a(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):a(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}n.Z=function(e){var n=e.children,t=e.fullHeight,r=e.gutter,a=e.justifyContent,d=e.style,f=void 0===d?{}:d,p=(0,i.Z)(e,l),h=s({},f);return r&&(h.marginLeft=-1*r,h.marginRight=h.marginLeft),t&&(h.height="100%"),(0,u.jsx)(c.Row,s(s({},p),{},{justifyContent:a,style:h,children:o.Children.map(n,(function(e,n){return e&&o.cloneElement(e,{gutter:r,key:n})}))}))}},29237:function(e,n,t){"use strict";var r=t(38626),i=t(67971),o=t(86673),c=t(19711),u=t(23831),l=t(73942),a=t(37391),s=t(49125),d=t(28598),f=(0,r.css)(["padding:","px;padding-bottom:","px;padding-top:","px;"],2*s.iI,1.5*s.iI,1.5*s.iI),p=r.default.div.withConfig({displayName:"Panel__PanelStyle",componentId:"sc-1ct8cgl-0"})(["border-radius:","px;overflow:hidden;"," "," "," "," "," "," "," "," "," "," "," ",""],l.n_,(function(e){return e.fullWidth&&"\n width: 100%;\n "}),(function(e){return!e.borderless&&"\n border: 1px solid ".concat((e.theme.interactive||u.Z.interactive).defaultBorder,";\n ")}),(function(e){return e.success&&"\n background-color: ".concat((e.theme.background||u.Z.background).successLight,";\n ")}),(function(e){return e.success&&!e.borderless&&"\n border: 1px solid ".concat((e.theme.background||u.Z.background).success,";\n ")}),(function(e){return!e.dark&&!e.success&&"\n background-color: ".concat((e.theme.background||u.Z.background).panel,";\n ")}),(function(e){return e.dark&&"\n background-color: ".concat((e.theme.background||u.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=r.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(e){return"\n background-color: ".concat((e.theme.background||u.Z.background).chartBlock,";\n border-bottom: 1px solid ").concat((e.theme.interactive||u.Z.interactive).defaultBorder,";\n ")}),(function(e){return e.height&&"\n height: ".concat(e.height,"px;\n ")}),f,(function(e){return e.headerPaddingVertical&&"\n padding-bottom: ".concat(e.headerPaddingVertical,"px;\n padding-top: ").concat(e.headerPaddingVertical,"px;\n ")})),m=r.default.div.withConfig({displayName:"Panel__ContentStyle",componentId:"sc-1ct8cgl-2"})(["overflow-y:auto;padding:","px;height:100%;"," "," "," "," ",""],1.75*s.iI,a.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 "})),g=r.default.div.withConfig({displayName:"Panel__FooterStyle",componentId:"sc-1ct8cgl-3"})(["border-style:",";border-top-width:","px;padding:","px;"],l.M8,l.YF,1.75*s.iI);n.Z=function(e){var n=e.borderless,t=e.children,r=e.containerRef,u=e.contentContainerRef,l=e.dark,a=e.footer,s=e.fullHeight,f=void 0===s||s,b=e.fullWidth,j=void 0===b||b,v=e.header,y=e.headerHeight,x=e.headerIcon,O=e.headerPaddingVertical,w=e.headerTitle,Z=e.maxHeight,P=e.maxWidth,_=e.minWidth,k=e.noPadding,I=e.overflowVisible,S=e.subtitle,C=e.success;return(0,d.jsxs)(p,{borderless:n,dark:l,fullHeight:f,fullWidth:j,maxHeight:Z,maxWidth:P,minWidth:_,overflowVisible:I,ref:r,success:C,children:[(v||w)&&(0,d.jsxs)(h,{headerPaddingVertical:O,height:y,children:[v&&v,w&&(0,d.jsx)(i.Z,{alignItems:"center",justifyContent:"space-between",children:(0,d.jsxs)(i.Z,{alignItems:"center",children:[x&&x,(0,d.jsx)(o.Z,{ml:x?1:0,children:(0,d.jsx)(c.ZP,{bold:!0,default:!0,children:w})})]})})]}),(0,d.jsxs)(m,{maxHeight:Z,noPadding:k,overflowVisible:I,ref:u,children:[S&&(0,d.jsx)(o.Z,{mb:2,children:(0,d.jsx)(c.ZP,{default:!0,children:S})}),t]}),a&&(0,d.jsx)(g,{children:a})]})}},87372:function(e,n,t){"use strict";var r,i,o,c,u,l,a,s,d=t(82394),f=t(26304),p=t(26653),h=t(38626),m=t(33591),g=t(23831),b=t(2005),j=t(31012),v=t(19711),y=t(49125),x=t(86673),O=t(28598),w=["children","condensed","inline","level","marketing","spacingBelow"];function Z(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function P(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?Z(Object(t),!0).forEach((function(n){(0,d.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):Z(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||g.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(b.iI,";\n ")}),(function(e){return!e.monospace&&1===Number(e.weightStyle)&&"\n font-family: ".concat(b.LX,";\n ")}),(function(e){return!e.monospace&&2===Number(e.weightStyle)&&"\n font-family: ".concat(b.LX,";\n ")}),(function(e){return!e.monospace&&3===Number(e.weightStyle)&&"\n font-family: ".concat(b.ry,";\n ")}),(function(e){return!e.monospace&&4===Number(e.weightStyle)&&"\n font-family: ".concat(b.YC,";\n ")}),(function(e){return!e.monospace&&5===Number(e.weightStyle)&&"\n font-family: ".concat(b.nF,";\n ")}),(function(e){return!e.monospace&&(6===Number(e.weightStyle)||e.bold)&&"\n font-family: ".concat(b.nF,";\n ")}),(function(e){return!e.monospace&&7===Number(e.weightStyle)&&"\n font-family: ".concat(b.nF,";\n ")}),(function(e){return!e.monospace&&8===Number(e.weightStyle)&&"\n font-family: ".concat(b.nF,";\n ")}),(function(e){return e.lineHeightAuto&&"\n line-height: normal !important;\n "})),k=h.default.div.withConfig({displayName:"Headline__HeadlineContainerStyle",componentId:"sc-12jzt2e-0"})(["",""],(function(e){return"\n color: ".concat((e.theme.content||g.Z.content).active,";\n ")})),I=h.default.h1.withConfig({displayName:"Headline__H1HeroStyle",componentId:"sc-12jzt2e-1"})([""," font-size:42px;line-height:56px;"," "," ",""],_,m.media.md(r||(r=(0,p.Z)(["\n ","\n "])),j.aQ),m.media.lg(i||(i=(0,p.Z)(["\n ","\n "])),j.aQ),m.media.xl(o||(o=(0,p.Z)(["\n ","\n "])),j.aQ)),S=h.default.h1.withConfig({displayName:"Headline__H1Style",componentId:"sc-12jzt2e-2"})([""," ",""],_,j.MJ),C=h.default.h1.withConfig({displayName:"Headline__H1MarketingStyle",componentId:"sc-12jzt2e-3"})([""," "," "," "," "," ",""],_,m.media.xs(c||(c=(0,p.Z)(["\n font-size: ","px;\n line-height: ","px;\n "])),6*y.iI,7*y.iI),m.media.sm(u||(u=(0,p.Z)(["\n font-size: ","px;\n line-height: ","px;\n "])),6*y.iI,7*y.iI),m.media.md(l||(l=(0,p.Z)(["\n font-size: ","px;\n line-height: ","px;\n "])),6*y.iI,7*y.iI),m.media.lg(a||(a=(0,p.Z)(["\n font-size: ","px;\n line-height: ","px;\n "])),6*y.iI,7*y.iI),m.media.xl(s||(s=(0,p.Z)(["\n font-size: ","px;\n line-height: ","px;\n "])),6*y.iI,7*y.iI)),H=h.default.h2.withConfig({displayName:"Headline__H2Style",componentId:"sc-12jzt2e-4"})([""," ",""],_,j.BL),N=h.default.h3.withConfig({displayName:"Headline__H3Style",componentId:"sc-12jzt2e-5"})([""," font-size:24px;line-height:32px;"],_),D=h.default.h4.withConfig({displayName:"Headline__H4Style",componentId:"sc-12jzt2e-6"})([""," font-size:20px;line-height:28px;"],_),W=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(j.MJ,"\n ")}),(function(e){return 2===e.level&&"\n ".concat(j.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 "})),z=function(e){var n,t=e.children,r=e.condensed,i=e.inline,o=e.level,c=e.marketing,u=e.spacingBelow,l=(0,f.Z)(e,w);i?n=E:0===Number(o)?n=I:1===Number(o)?n=c?C:S:2===Number(o)?n=H:3===Number(o)?n=N:4===Number(o)?n=D:5===Number(o)&&(n=W);var a=(0,O.jsxs)(n,P(P({},l),{},{level:o,children:[u&&(0,O.jsx)(x.Z,{mb:r?2:3,children:t}),!u&&t]}));return i?a:(0,O.jsx)(k,{children:a})};z.defaultProps={level:3,weightStyle:6},n.Z=z},42949:function(e,n,t){"use strict";t.r(n);var r=t(77837),i=t(38860),o=t.n(i),c=t(76096),u=t(21853),l=t(41788),a=t(97361),s=t(30775),d=t(86673),f=t(49125),p=t(79585),h=t(28598);function m(){return(0,h.jsx)(s.Z,{uuidItemSelected:p.HY,uuidWorkspaceSelected:p.WH,children:(0,h.jsx)(d.Z,{p:f.cd,children:(0,h.jsx)(a.Z,{justifyContent:"center",children:(0,h.jsx)(c.Z,{xl:8,xxl:6,children:(0,h.jsx)(u.Z,{})})})})})}m.getInitialProps=(0,r.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,l.Z)(m)},33323:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/settings/workspace/preferences",function(){return t(42949)}])},80022:function(e,n,t){"use strict";function r(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}t.d(n,{Z:function(){return r}})},15544:function(e,n,t){"use strict";function r(e){return r=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},r(e)}t.d(n,{Z:function(){return r}})},99177:function(e,n,t){"use strict";function r(e,n){return r=Object.setPrototypeOf||function(e,n){return e.__proto__=n,e},r(e,n)}function i(e,n){if("function"!==typeof n&&null!==n)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),n&&r(e,n)}t.d(n,{Z:function(){return i}})},93189:function(e,n,t){"use strict";t.d(n,{Z:function(){return o}});var r=t(12539),i=t(80022);function o(e,n){if(n&&("object"===r(n)||"function"===typeof n))return n;if(void 0!==n)throw new TypeError("Derived constructors may only return object or undefined");return(0,i.Z)(e)}}},function(e){e.O(0,[844,1424,1005,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],{1210:function(e,n,t){"use strict";t.d(n,{Z:function(){return E}});var r=t(82394),i=t(21831),o=t(82684),u=t(47999),c=t(49894),l=t(93461),s=t(57384),a=t(41424),d=t(72454),f=t(28598);function p(e,n){var t=e.children;return(0,f.jsx)(d.HS,{ref:n,children:t})}var h=o.forwardRef(p),g=t(32063),v=t(85019),j=t(82531),b=t(66166),m=t(3055),y=t(49125),O=t(91427),Z=t(24141);function x(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function _(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,r.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 E=function(e){var n,t=e.addProjectBreadcrumbToCustomBreadcrumbs,r=e.after,p=e.afterHidden,x=e.afterWidth,E=e.afterWidthOverride,P=e.before,C=e.beforeWidth,w=e.breadcrumbs,A=e.children,k=e.errors,I=e.headerMenuItems,T=e.headerOffset,S=e.mainContainerHeader,D=e.navigationItems,N=e.setErrors,M=e.subheaderChildren,L=e.title,R=e.uuid,H=(0,Z.i)().width,V="dashboard_after_width_".concat(R),B="dashboard_before_width_".concat(R),z=(0,o.useRef)(null),F=(0,o.useState)(E?x:(0,O.U2)(V,x)),U=F[0],q=F[1],W=(0,o.useState)(!1),Y=W[0],Q=W[1],J=(0,o.useState)(P?Math.max((0,O.U2)(B,C),13*y.iI):null),K=J[0],X=J[1],G=(0,o.useState)(!1),$=G[0],ee=G[1],ne=(0,o.useState)(null)[1],te=j.ZP.projects.list({},{revalidateOnFocus:!1}).data,re=null===te||void 0===te?void 0:te.projects,ie={label:function(){var e;return null===re||void 0===re||null===(e=re[0])||void 0===e?void 0:e.name},linkProps:{href:"/"}},oe=[];w?(t&&oe.push(ie),oe.push.apply(oe,(0,i.Z)(w))):(null===re||void 0===re?void 0:re.length)>=1&&oe.push.apply(oe,[ie,{bold:!0,label:function(){return L}}]),(0,o.useEffect)((function(){null===z||void 0===z||!z.current||Y||$||null===ne||void 0===ne||ne(z.current.getBoundingClientRect().width)}),[Y,U,$,K,z,ne,H]),(0,o.useEffect)((function(){Y||(0,O.t8)(V,U)}),[p,Y,U,V]),(0,o.useEffect)((function(){$||(0,O.t8)(B,K)}),[$,K,B]);var ue=(0,b.Z)(x);return(0,o.useEffect)((function(){E&&ue!==x&&q(x)}),[E,x,ue]),(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(s.Z,{title:L}),(0,f.jsx)(a.Z,{breadcrumbs:oe,menuItems:I,project:null===re||void 0===re?void 0:re[0],version:null===re||void 0===re||null===(n=re[0])||void 0===n?void 0:n.version}),(0,f.jsxs)(d.Nk,{children:[0!==(null===D||void 0===D?void 0:D.length)&&(0,f.jsx)(d.lm,{showMore:!0,children:(0,f.jsx)(v.Z,{navigationItems:D,showMore:!0})}),(0,f.jsx)(l.Z,{flex:1,flexDirection:"column",children:(0,f.jsxs)(g.Z,{after:r,afterHeightOffset:m.Mz,afterHidden:p,afterMousedownActive:Y,afterWidth:U,before:P,beforeHeightOffset:m.Mz,beforeMousedownActive:$,beforeWidth:d.k1+(P?K:0),headerOffset:T,hideAfterCompletely:!0,leftOffset:P?d.k1:null,mainContainerHeader:S,mainContainerRef:z,setAfterMousedownActive:Q,setAfterWidth:q,setBeforeMousedownActive:ee,setBeforeWidth:X,children:[M&&(0,f.jsx)(h,{children:M}),A]})})]}),k&&(0,f.jsx)(u.Z,{disableClickOutside:!0,isOpen:!0,onClickOutside:function(){return null===N||void 0===N?void 0:N(null)},children:(0,f.jsx)(c.Z,_(_({},k),{},{onClose:function(){return null===N||void 0===N?void 0:N(null)}}))})]})}},97225:function(e,n,t){"use strict";var r=t(75582),i=t(12691),o=t.n(i),u=t(82684),c=t(83455),l=t(34376),s=t(60328),a=t(16634),d=t(47999),f=t(67971),p=t(10919),h=t(93348),g=t(62609),v=t(86673),j=t(87815),b=t(19711),m=t(46261),y=t(82531),O=t(22341),Z=t(66050),x=t(49125),_=t(45838),E=t(9736),P=t(96510),C=t(66653),w=t(28598),A=1.5*x.iI;n.Z=function(e){var n=e.disableActions,t=e.fetchPipelineSchedules,i=e.highlightRowOnHover,k=e.includeCreatedAtColumn,I=e.includePipelineColumn,T=e.pipeline,S=e.pipelineSchedules,D=e.pipelineTriggersByName,N=e.selectedSchedule,M=e.setErrors,L=e.setSelectedSchedule,R=e.stickyHeader,H=null===T||void 0===T?void 0:T.uuid,V=(0,l.useRouter)(),B=(0,u.useRef)({}),z=(0,u.useState)(null),F=z[0],U=z[1],q=(0,u.useState)(0),W=q[0],Y=q[1],Q=(0,u.useState)(0),J=Q[0],K=Q[1],X=(0,c.Db)((function(e){return y.ZP.pipeline_schedules.useUpdate(e.id)({pipeline_schedule:e})}),{onSuccess:function(e){return(0,P.wD)(e,{callback:function(){null===t||void 0===t||t()},onErrorCallback:function(e,n){return M({errors:n,response:e})}})}}),G=(0,r.Z)(X,1)[0],$=(0,c.Db)((function(e){return y.ZP.pipeline_schedules.useDelete(e)()}),{onSuccess:function(e){return(0,P.wD)(e,{callback:function(){null===t||void 0===t||t(),H?V.push("/pipelines/[pipeline]/triggers","/pipelines/".concat(H,"/triggers")):null===t||void 0===t||t()},onErrorCallback:function(e,n){return M({errors:n,response:e})}})}}),ee=(0,r.Z)($,1)[0],ne=[],te=[];return n||(ne.push.apply(ne,[null,null,1]),te.push.apply(te,[{label:function(){return""},uuid:"action"},{uuid:"Info"},{uuid:"Type"}])),ne.push.apply(ne,[n?1:null]),te.push.apply(te,[{uuid:"Name"}]),n||(ne.push.apply(ne,[null]),te.push.apply(te,[{uuid:"Frequency"}])),ne.push.apply(ne,[null,null,null]),te.push.apply(te,[{uuid:"Runs"},{uuid:"Latest status"},{uuid:"Logs"}]),n||(0,E.Ct)()||(ne.push.apply(ne,[null]),te.push({label:function(){return""},uuid:"edit/delete"})),!n&&I&&(te.splice(2,0,{uuid:"Pipeline"}),ne.splice(2,0,2)),!n&&k&&(te.splice(3,0,{uuid:"Created at"}),ne.splice(3,0,null)),(0,w.jsx)(_.cl,{overflowVisible:!0,children:0===S.length?(0,w.jsx)(v.Z,{px:3,py:1,children:(0,w.jsx)(b.ZP,{bold:!0,default:!0,monospace:!0,muted:!0,children:"No triggers available"})}):(0,w.jsx)(j.Z,{columnFlex:ne,columns:te,highlightRowOnHover:i,isSelectedRow:function(e){return S[e].id===(null===N||void 0===N?void 0:N.id)},onClickRow:L?function(e){return null===L||void 0===L?void 0:L(S[e])}:null,rowVerticalPadding:6,rows:S.map((function(e,t){var r,i=e.id,c=e.created_at,l=e.pipeline_runs_count,j=e.pipeline_uuid,y=e.last_pipeline_run_status,_=e.name,P=e.schedule_interval,T=e.status,S=H||j;B.current[i]=(0,u.createRef)(),h.fq.ACTIVE===T?r=(0,w.jsx)(a.Z,{size:A,success:!0}):h.fq.INACTIVE===T&&(r=(0,w.jsx)(a.Z,{borderSize:1,size:A,square:!0,warning:!0}));var N,M=[];n?M.push.apply(M,[(0,w.jsx)(b.ZP,{bold:!0,children:_},"trigger_name_".concat(t))]):M.push.apply(M,[(0,w.jsx)(s.Z,{iconOnly:!0,noBackground:!0,noBorder:!0,noPadding:!0,onClick:function(n){(0,C.j)(n),G({id:e.id,status:h.fq.ACTIVE===T?h.fq.INACTIVE:h.fq.ACTIVE})},children:h.fq.ACTIVE===T?(0,w.jsx)(O.dz,{muted:!0,size:2*x.iI}):(0,w.jsx)(O.Py,{default:!0,size:2*x.iI})},"toggle_trigger_".concat(t)),(0,w.jsxs)(f.Z,{alignItems:"center",flexDirection:"row",children:[(0,w.jsx)(m.Z,{block:!0,label:T,size:A,widthFitContent:!0,children:r}),(null===D||void 0===D?void 0:D[_])&&(0,w.jsxs)(w.Fragment,{children:[(0,w.jsx)(v.Z,{mr:1}),(0,w.jsx)(m.Z,{block:!0,label:"This trigger is saved in code.",size:A,widthFitContent:!0,children:(0,w.jsx)(O.EK,{default:!0,size:A})})]})]},"trigger_status_".concat(t)),(0,w.jsx)(b.ZP,{default:!0,monospace:!0,children:null===(N=h.Z4[e.schedule_type])||void 0===N?void 0:N.call(h.Z4)},"trigger_type_".concat(t)),(0,w.jsx)(o(),{as:"/pipelines/".concat(S,"/triggers/").concat(i),href:"/pipelines/[pipeline]/triggers/[...slug]",passHref:!0,children:(0,w.jsx)(p.Z,{bold:!0,onClick:function(e){(0,C.j)(e),V.push("/pipelines/[pipeline]/triggers/[...slug]","/pipelines/".concat(S,"/triggers/").concat(i))},sameColorAsText:!0,children:_})},"trigger_name_".concat(t))]);return n||M.push.apply(M,[(0,w.jsx)(b.ZP,{default:!0,monospace:!0,children:P},"trigger_frequency_".concat(t))]),M.push.apply(M,[(0,w.jsx)(b.ZP,{default:!0,monospace:!0,children:l},"trigger_run_count_".concat(t)),(0,w.jsx)(b.ZP,{danger:Z.V.FAILED===y,default:!y,monospace:!0,success:Z.V.COMPLETED===y,warning:Z.V.CANCELLED===y,children:y||"N/A"},"latest_run_status_".concat(t)),(0,w.jsx)(s.Z,{default:!0,iconOnly:!0,noBackground:!0,onClick:function(){return V.push("/pipelines/".concat(S,"/logs?pipeline_schedule_id[]=").concat(i))},children:(0,w.jsx)(O.B4,{default:!0,size:2*x.iI})},"logs_button_".concat(t))]),n||(0,E.Ct)()||M.push((0,w.jsxs)(f.Z,{children:[(0,w.jsx)(s.Z,{default:!0,iconOnly:!0,noBackground:!0,onClick:function(){return V.push("/pipelines/".concat(S,"/triggers/").concat(i,"/edit"))},title:"Edit",children:(0,w.jsx)(O.I8,{default:!0,size:2*x.iI})}),(0,w.jsx)(v.Z,{mr:1}),(0,w.jsx)(s.Z,{default:!0,iconOnly:!0,noBackground:!0,onClick:function(){var e,n,t,r;U(i),Y((null===(e=B.current[i])||void 0===e||null===(n=e.current)||void 0===n?void 0:n.offsetTop)||0),K((null===(t=B.current[i])||void 0===t||null===(r=t.current)||void 0===r?void 0:r.offsetLeft)||0)},ref:B.current[i],title:"Delete",children:(0,w.jsx)(O.rF,{default:!0,size:2*x.iI})}),(0,w.jsx)(d.Z,{onClickOutside:function(){return U(null)},open:F===i,children:(0,w.jsx)(g.Z,{danger:!0,left:(J||0)-286,onCancel:function(){return U(null)},onClick:function(){U(null),ee(i)},title:"Are you sure you want to delete the trigger ".concat(_,"?"),top:(W||0)-(t<=1?40:96),width:40*x.iI})})]},"edit_delete_buttons_".concat(t))),!n&&I&&M.splice(2,0,(0,w.jsx)(b.ZP,{default:!0,monospace:!0,children:S},"pipeline_name_".concat(t))),!n&&k&&M.splice(3,0,(0,w.jsx)(b.ZP,{default:!0,monospace:!0,children:c},"created_at_".concat(t))),M})),stickyHeader:R,uuid:"pipeline-triggers"})})}},51099:function(e,n,t){"use strict";t.d(n,{Q:function(){return a}});t(82684);var r=t(60328),i=t(67971),o=t(86673),u=t(22341),c=t(73899),l=t(49125),s=t(28598),a=22;n.Z=function(e){var n=e.page,t=e.maxPages,a=e.onUpdate,d=e.totalPages,f=[],p=t;if(p>d)f=Array.from({length:d},(function(e,n){return n}));else{var h=Math.floor(p/2),g=n-h;n+h>=d?(g=d-p+2,p-=2):n-h<=0?(g=0,p-=2):(p-=4,g=n-Math.floor(p/2)),f=Array.from({length:p},(function(e,n){return n+g}))}return(0,s.jsx)(s.Fragment,{children:d>0&&(0,s.jsxs)(i.Z,{alignItems:"center",children:[(0,s.jsx)(r.Z,{disabled:0===n,onClick:function(){return a(n-1)},children:(0,s.jsx)(u.Hd,{size:1.5*l.iI,stroke:"#AEAEAE"})}),!f.includes(0)&&(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(o.Z,{ml:1,children:(0,s.jsx)(r.Z,{onClick:function(){return a(0)},borderLess:!0,noBackground:!0,children:1})},0),!f.includes(1)&&(0,s.jsx)(o.Z,{ml:1,children:(0,s.jsx)(r.Z,{notClickable:!0,noBackground:!0,noPadding:!0,children:"..."})},0)]}),f.map((function(e){return(0,s.jsx)(o.Z,{ml:1,children:(0,s.jsx)(r.Z,{onClick:function(){e!==n&&a(e)},notClickable:e===n,backgroundColor:e===n&&c.a$,borderLess:!0,noBackground:!0,children:e+1})},e)})),!f.includes(d-1)&&(0,s.jsxs)(s.Fragment,{children:[!f.includes(d-2)&&(0,s.jsx)(o.Z,{ml:1,children:(0,s.jsx)(r.Z,{notClickable:!0,noBackground:!0,noPadding:!0,children:"..."})},0),(0,s.jsx)(o.Z,{ml:1,children:(0,s.jsx)(r.Z,{onClick:function(){return a(d-1)},borderLess:!0,noBackground:!0,children:d})},d-1)]}),(0,s.jsx)(o.Z,{ml:1}),(0,s.jsx)(r.Z,{disabled:n===d-1,onClick:function(){return a(n+1)},children:(0,s.jsx)(u.Kw,{size:1.5*l.iI,stroke:"#AEAEAE"})})]})})}},66050:function(e,n,t){"use strict";var r;t.d(n,{V:function(){return r}}),function(e){e.CANCELLED="cancelled",e.COMPLETED="completed",e.FAILED="failed",e.INITIAL="initial",e.RUNNING="running",e.UPSTREAM_FAILED="upstream_failed",e.CONDITION_FAILED="condition_failed"}(r||(r={}))},93348:function(e,n,t){"use strict";t.d(n,{TR:function(){return d},U5:function(){return l},Xm:function(){return o},Z4:function(){return a},fq:function(){return c},kJ:function(){return s}});var r,i,o,u=t(82394);!function(e){e.API="api",e.EVENT="event",e.TIME="time"}(o||(o={}));var c,l,s,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(e){e.ACTIVE="active",e.INACTIVE="inactive"}(c||(c={})),function(e){e.ONCE="@once",e.HOURLY="@hourly",e.DAILY="@daily",e.WEEKLY="@weekly",e.MONTHLY="@monthly"}(l||(l={})),function(e){e.CREATED_AT="created_at",e.NAME="name",e.PIPELINE="pipeline_uuid",e.STATUS="status",e.TYPE="schedule_type"}(s||(s={}));var d=(i={},(0,u.Z)(i,s.CREATED_AT,"Created at"),(0,u.Z)(i,s.NAME,"Name"),(0,u.Z)(i,s.PIPELINE,"Pipeline"),(0,u.Z)(i,s.STATUS,"Status"),(0,u.Z)(i,s.TYPE,"Type"),i)},46756:function(e,n,t){"use strict";t.r(n);var r=t(77837),i=t(82394),o=t(75582),u=t(38860),c=t.n(u),l=t(82684),s=t(34376),a=t(1210),d=t(67971),f=t(51099),p=t(41788),h=t(55378),g=t(86673),v=t(19711),j=t(97225),b=t(82531),m=t(93348),y=t(49125),O=t(33766),Z=t(59e3),x=t(28598);function _(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function E(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?_(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):_(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function P(){var e=(0,s.useRouter)(),n=(0,Z.iV)(),t=null!==n&&void 0!==n&&n.page?n.page:0,r=(null===n||void 0===n?void 0:n.order_by)||m.kJ.CREATED_AT,i={_limit:f.Q,_offset:t*f.Q,order_by:r},u=b.ZP.pipeline_schedules.list(i,{refreshInterval:7500,revalidateOnFocus:!0}),c=u.data,p=u.mutate,_=(0,l.useMemo)((function(){return(null===c||void 0===c?void 0:c.pipeline_schedules)||[]}),[c]),P=(0,l.useMemo)((function(){var e;return(null===c||void 0===c||null===(e=c.metadata)||void 0===e?void 0:e.count)||[]}),[c]);return(0,x.jsxs)(a.Z,{title:"Triggers",uuid:"triggers/index",children:[(0,x.jsx)(g.Z,{mx:2,my:1,children:(0,x.jsxs)(d.Z,{alignItems:"center",children:[(0,x.jsx)(v.ZP,{bold:!0,default:!0,large:!0,children:"Sort runs by:"}),(0,x.jsx)(g.Z,{mr:1}),(0,x.jsx)(h.Z,{compact:!0,defaultColor:!0,fitContent:!0,onChange:function(e){e.preventDefault(),(0,O.u7)({order_by:e.target.value,page:0})},paddingRight:4*y.iI,placeholder:"Select column",value:r||m.kJ.CREATED_AT,children:Object.entries(m.TR).map((function(e){var n=(0,o.Z)(e,2),t=n[0],r=n[1];return(0,x.jsx)("option",{value:t,children:r},t)}))})]})}),(0,x.jsx)(j.Z,{fetchPipelineSchedules:p,highlightRowOnHover:!0,includeCreatedAtColumn:!0,includePipelineColumn:!0,pipelineSchedules:_,stickyHeader:!0}),(0,x.jsx)(g.Z,{p:2,children:(0,x.jsx)(f.Z,{maxPages:9,onUpdate:function(t){var r=Number(t),i=E(E({},n),{},{page:r>=0?r:0});e.push("/triggers","/triggers?".concat((0,Z.uM)(i)))},page:Number(t),totalPages:Math.ceil(P/f.Q)})})]})}P.getInitialProps=(0,r.Z)(c().mark((function e(){return c().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",{});case 1:case"end":return e.stop()}}),e)}))),n.default=(0,p.Z)(P)},33766:function(e,n,t){"use strict";t.d(n,{O2:function(){return d},g_:function(){return p},u7:function(){return f}});var r=t(75582),i=t(82394),o=t(34376),u=t.n(o),c=t(59e3),l=t(24224);function s(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function a(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?s(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):s(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var d="_offset";function f(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},t=n.preserveParams,i=n.pushHistory,o=n.replaceParams,l=(0,c.iV)(),s={};t&&t.forEach((function(e){l[e]&&(s[e]=l[e])}));var d,f=o?s:l;d=window.location.pathname;var p=i?u().push:u().replace,h=a(a({},f),e);Object.entries(e).forEach((function(e){var n=(0,r.Z)(e,2),t=n[0],i=n[1];"undefined"!==typeof i&&null!==i||delete h[t]}));var g=(0,c.uM)(h);g.length>=1&&(g="?".concat(g));var v="".concat(d.split("?")[0]).concat(g),j=u().router.basePath;return j&&v.startsWith(j)&&(v=v.replace(j,"")),p(u().router.pathname,v,{shallow:!0})}function p(e,n,t){var i=t.addingMultipleValues,o=t.isList,u=t.itemsPerPage,c=t.pushHistory,s=void 0!==c&&c,p=t.resetLimitParams,h=a({},e);i?Object.entries(n).forEach((function(e){var n=(0,r.Z)(e,2),t=n[0],i=n[1];if(Array.isArray(i)){var o="".concat(t,"[]");h[o]=i.map(String)}})):o?Object.entries(n).forEach((function(e){var n=(0,r.Z)(e,2),t=n[0],i=n[1],o=String(i),u="".concat(t,"[]"),c=h[u];c&&Array.isArray(c)?(c=c.map(String)).includes(o)?h[u]=(0,l.Od)(c,(function(e){return e===o})):h[u]=c.concat(o):h[u]=[o]})):h=a(a({},h),n),p&&(h._limit=u||20,h[d]=0),f(h,{pushHistory:s})}},59733:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/triggers",function(){return t(46756)}])},80022:function(e,n,t){"use strict";function r(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}t.d(n,{Z:function(){return r}})},15544:function(e,n,t){"use strict";function r(e){return r=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},r(e)}t.d(n,{Z:function(){return r}})},99177:function(e,n,t){"use strict";function r(e,n){return r=Object.setPrototypeOf||function(e,n){return e.__proto__=n,e},r(e,n)}function i(e,n){if("function"!==typeof n&&null!==n)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),n&&r(e,n)}t.d(n,{Z:function(){return i}})},93189:function(e,n,t){"use strict";t.d(n,{Z:function(){return o}});var r=t(12539),i=t(80022);function o(e,n){if(n&&("object"===r(n)||"function"===typeof n))return n;if(void 0!==n)throw new TypeError("Derived constructors may only return object or undefined");return(0,i.Z)(e)}}},function(e){e.O(0,[844,1424,1005,7815,9774,2888,179],(function(){return n=59733,e(e.s=n);var n}));var n=e.O();_N_E=n}]);