@acedatacloud/nexior 3.329.34 → 3.329.36

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.
Files changed (292) hide show
  1. package/dist/assets/{ApiCodeButton-B5bcZfdh.js → ApiCodeButton-DlLeisJy.js} +1 -1
  2. package/dist/assets/{Artifacts-PZ3Fn29I.js → Artifacts-DnLEgFr8.js} +1 -1
  3. package/dist/assets/{AskUserQuestionCard-DdqVjrRX.js → AskUserQuestionCard-B1hScRA3.js} +1 -1
  4. package/dist/assets/{AudioPreview-BS6RCUxd.js → AudioPreview-BvBVGmgY.js} +1 -1
  5. package/dist/assets/{Auth-I6MMJykr.js → Auth-DepRxRvb.js} +1 -1
  6. package/dist/assets/{Bare-CDYPXL4z.js → Bare-DJm7p3Ic.js} +1 -1
  7. package/dist/assets/{BotPlaceholder-DrrclSPW.js → BotPlaceholder-DokNHJF_.js} +1 -1
  8. package/dist/assets/{BottomFooter-BVpQCBC8.js → BottomFooter-CjV9TtkB.js} +1 -1
  9. package/dist/assets/{Callback-CtP7t7Q3.js → Callback-DESXG4m9.js} +1 -1
  10. package/dist/assets/{CodeSnippet-A0C7QuGm.js → CodeSnippet-BGj2s7zb.js} +1 -1
  11. package/dist/assets/{Console-xs2JQCQs.js → Console-Ci-j_7cQ.js} +1 -1
  12. package/dist/assets/{Consumption-C9BeeUKY.js → Consumption-DxpWh8Jl.js} +1 -1
  13. package/dist/assets/{Conversation-D8VdjAO1.js → Conversation-BZ4ZVWwJ.js} +1 -1
  14. package/dist/assets/{Conversation-YCenlMn0.js → Conversation-XYfVyIc_.js} +1 -1
  15. package/dist/assets/{CopyToClipboard-CukvJo1c.js → CopyToClipboard-CXUBt7va.js} +1 -1
  16. package/dist/assets/{Detail-DUf_Iov8.js → Detail-BTURfEtZ.js} +2 -2
  17. package/dist/assets/{Extra-CwJcl6Oo.js → Extra-CnoY7QZk.js} +1 -1
  18. package/dist/assets/{FilePreview-VkDLWLDv.js → FilePreview-DwxZgGx7.js} +1 -1
  19. package/dist/assets/{Hailuo-D-EWCBmd.js → Hailuo-tPqBlS9Y.js} +1 -1
  20. package/dist/assets/{History-DjpM88oz.js → History-h53ii_Ro.js} +1 -1
  21. package/dist/assets/{ImagePreview-C_v2JWDj.js → ImagePreview-i4yuCCbI.js} +1 -1
  22. package/dist/assets/{ImageWrapper-B_bAW57k.js → ImageWrapper-crmZ5EPh.js} +1 -1
  23. package/dist/assets/Index-3N-LGgmp.js +1 -0
  24. package/dist/assets/{Index-MIWnr6GR.js → Index-8HEiyPEG.js} +1 -1
  25. package/dist/assets/Index-B6mNULMD.js +1 -0
  26. package/dist/assets/{Index-DNYdfeuZ.js → Index-BBIbi9d5.js} +1 -1
  27. package/dist/assets/Index-BBba3Mzc.js +1 -0
  28. package/dist/assets/Index-BCvYz4E9.js +1 -0
  29. package/dist/assets/{Index-DmWwUQu7.js → Index-BMVkXlZJ.js} +1 -1
  30. package/dist/assets/Index-BZ_fBG9p.js +1 -0
  31. package/dist/assets/Index-BagnDrg5.js +1 -0
  32. package/dist/assets/Index-BbZv0rke.js +1 -0
  33. package/dist/assets/Index-BoOHWLI_.js +1 -0
  34. package/dist/assets/Index-Bs2PC7wy.js +1 -0
  35. package/dist/assets/Index-C-x2P8Jq.js +1 -0
  36. package/dist/assets/{Index-Cg8C0GBo.js → Index-C1Qh77G_.js} +1 -1
  37. package/dist/assets/Index-C6Bl0dek.js +1 -0
  38. package/dist/assets/Index-CDLEKoxy.js +1 -0
  39. package/dist/assets/Index-CRTFI_ra.js +1 -0
  40. package/dist/assets/Index-C_s7mnLz.js +1 -0
  41. package/dist/assets/Index-Ce8JimfC.js +1 -0
  42. package/dist/assets/{Index-DcVc-cdk.js → Index-Cs22CVrJ.js} +1 -1
  43. package/dist/assets/{Index-nx1o8wzk.js → Index-Cs_mjf2u.js} +1 -1
  44. package/dist/assets/Index-CyVtgPMo.js +1 -0
  45. package/dist/assets/{Index-DIq1rQLV.css → Index-D9srmVjK.css} +1 -1
  46. package/dist/assets/{Index-Bja-uJfm.js → Index-DC8pVYJf.js} +1 -1
  47. package/dist/assets/Index-DRMtZeJR.js +1 -0
  48. package/dist/assets/{Index-DkHadGVw.css → Index-DbxRnJBR.css} +1 -1
  49. package/dist/assets/Index-DiVE2RBO.js +1 -0
  50. package/dist/assets/{Index-BNRn4H8m.js → Index-fT9MdXfO.js} +1 -1
  51. package/dist/assets/Index-nzTv2Q_3.js +1 -0
  52. package/dist/assets/{Index-BA0m2wSz.js → Index-sO-qKjKX.js} +1 -1
  53. package/dist/assets/Index-srmapWEq.js +1 -0
  54. package/dist/assets/{Invitees-CBKwNg3i.js → Invitees-C99PFzII.js} +1 -1
  55. package/dist/assets/{List-CaQWiQnU.js → List-6OOQNlS2.js} +1 -1
  56. package/dist/assets/{List-z3TgAU3o.js → List-D7KEci41.js} +1 -1
  57. package/dist/assets/{List-mzf1oSL1.js → List-Dhsl9lUS.js} +1 -1
  58. package/dist/assets/{LocalTools-KN0n58xa.js → LocalTools-CUXDsEYo.js} +1 -1
  59. package/dist/assets/{LocalTools-D6JKzPt4.js → LocalTools-UaCeiNE2.js} +1 -1
  60. package/dist/assets/{Main-DJdyQByr.js → Main-CLf9Jha3.js} +1 -1
  61. package/dist/assets/{Message-DvNb_3Sm.js → Message-B8P8wL__.js} +1 -1
  62. package/dist/assets/{Model-D_Qhkb-h.js → Model-qPgxh0qQ.js} +1 -1
  63. package/dist/assets/{Navigator-DYBKMDhL.js → Navigator-Z60P7kn1.js} +3 -3
  64. package/dist/assets/{NotFound-DRIEcCd_.js → NotFound-DgLWon9f.js} +1 -1
  65. package/dist/assets/{Pay-pqOGXHV6.js → Pay-9AuBWATs.js} +1 -1
  66. package/dist/assets/{Player-DwN59ij5.js → Player-t2Er3IPc.js} +1 -1
  67. package/dist/assets/PromptTextarea-CnZpw6Hw.js +1 -0
  68. package/dist/assets/{RealtimeCall-DxYnQYlH.js → RealtimeCall-DDkt_tZ0.js} +1 -1
  69. package/dist/assets/{ScheduledTasks-Dh9p13ng.js → ScheduledTasks-DgBm-k6h.js} +1 -1
  70. package/dist/assets/{Status-BiRB_z6y.js → Status-CwJrINWK.js} +1 -1
  71. package/dist/assets/{Subscribe-CDJmudxF.js → Subscribe-DKJK5nF6.js} +1 -1
  72. package/dist/assets/{TabSwitcher-BxFbNz8V.js → TabSwitcher-CBAZjhJ1.js} +1 -1
  73. package/dist/assets/Tts-C2cYbfDD.js +1 -0
  74. package/dist/assets/{VideoPlayer-Mi5BhTJB.js → VideoPlayer-BlKkIuHl.js} +1 -1
  75. package/dist/assets/{alert-BZ-RGZ19.js → alert-CbBlpqcv.js} +1 -1
  76. package/dist/assets/arrow-down-WnaeLSS0.js +1 -0
  77. package/dist/assets/{arrow-down-wide-narrow-B3diMt0F.js → arrow-down-wide-narrow-C8wih4vx.js} +1 -1
  78. package/dist/assets/arrow-left-DufuqFN2.js +1 -0
  79. package/dist/assets/arrow-right-CzRSz4q4.js +1 -0
  80. package/dist/assets/arrow-up-drzCqFju.js +1 -0
  81. package/dist/assets/{avatar-DbNUBhGi.js → avatar-Dhk-wBrP.js} +1 -1
  82. package/dist/assets/{basic-Cs_gkgGB.js → basic-BHpKbBKl.js} +1 -1
  83. package/dist/assets/{box-ErmvwLo6.js → box-DU6JWvO6.js} +1 -1
  84. package/dist/assets/{boxes-lIcX9xC8.js → boxes-CfMZgSp2.js} +1 -1
  85. package/dist/assets/{brain-BBYaiJ0U.js → brain-C9clucUj.js} +1 -1
  86. package/dist/assets/{chart-no-axes-combined-UA07oKdi.js → chart-no-axes-combined-DOwBlrUn.js} +1 -1
  87. package/dist/assets/{chat-BE277PGt.js → chat-BNLQvDC8.js} +1 -1
  88. package/dist/assets/check-BcHnI0nc.js +1 -0
  89. package/dist/assets/chevron-down-D4v7QUau.js +1 -0
  90. package/dist/assets/chevron-right-9PGtREAT.js +1 -0
  91. package/dist/assets/circle-check-BzVb6e7w.js +1 -0
  92. package/dist/assets/clock-CudJy-NA.js +1 -0
  93. package/dist/assets/{codingBridge-CYe6alH0.js → codingBridge-D0_Sh5VQ.js} +1 -1
  94. package/dist/assets/{codingBridgeNotify-DE1oTMbn.js → codingBridgeNotify-BaU-20-i.js} +2 -2
  95. package/dist/assets/{coins-CLxqqlri.js → coins-DdEfOeat.js} +1 -1
  96. package/dist/assets/{collapse-EJr86ZoB.js → collapse-BUDe7Bv8.js} +1 -1
  97. package/dist/assets/{constants-dJ4RJksK.js → constants-Bq6v7ZuS.js} +1 -1
  98. package/dist/assets/{createTaskActions-D7lg7_wi.js → createTaskActions-DdDwgzyH.js} +1 -1
  99. package/dist/assets/{digitalhuman-DGBKLVSZ.js → digitalhuman-QjrrmdE_.js} +1 -1
  100. package/dist/assets/{dollar-sign-BSPTAqRP.js → dollar-sign-D9gi57KT.js} +1 -1
  101. package/dist/assets/{download-CRlrpFkF.js → download-CZXwMz2g.js} +1 -1
  102. package/dist/assets/{drawer-6sGdi_7c.js → drawer-C_8cbeMJ.js} +1 -1
  103. package/dist/assets/{dropdown-BXFl7YRh.js → dropdown-B11rh9YL.js} +1 -1
  104. package/dist/assets/{dropdown-Bi5jTRyv.js → dropdown-Bby1tkia.js} +1 -1
  105. package/dist/assets/{ellipsis-DQ-JXh1l.js → ellipsis-BLEPlJe1.js} +1 -1
  106. package/dist/assets/{esm-Dc1Vp3JP.js → esm-BWYZAV85.js} +3 -3
  107. package/dist/assets/{esm-CoSkfI2c.js → esm-C62r_Sw2.js} +1 -1
  108. package/dist/assets/{esm-DwaJHRt0.js → esm-Cp3cALhu.js} +1 -1
  109. package/dist/assets/{esm-Cip_PZ3-.js → esm-DAnVKoQl.js} +1 -1
  110. package/dist/assets/{esm-C9NG8Vrp.js → esm-DTzAbVf-.js} +2 -2
  111. package/dist/assets/esm-DXKQ2Z_U.js +1 -0
  112. package/dist/assets/{esm-DV2ej0xl.js → esm-DzX0bY7Y.js} +2 -2
  113. package/dist/assets/{external-link-CQuyfUK6.js → external-link-Dxer5yQG.js} +1 -1
  114. package/dist/assets/{eye-Cob68GKp.js → eye-BbZHbXY-.js} +1 -1
  115. package/dist/assets/{file-output-CtfM-pP_.js → file-output-BbB8Qa4f.js} +1 -1
  116. package/dist/assets/{file-text-CVYe-Dlg.js → file-text-DXF_EOcR.js} +1 -1
  117. package/dist/assets/{fish-BK3MFosN.js → fish-QP506LEw.js} +1 -1
  118. package/dist/assets/{flux-kpBJ61-A.js → flux-C7GlXv4K.js} +1 -1
  119. package/dist/assets/{folder-xrJwJ4hQ.js → folder-DEiO0JU1.js} +1 -1
  120. package/dist/assets/gauge-DLjhkJRX.js +1 -0
  121. package/dist/assets/{globe-DewY9bI1.js → globe-DnYlk8mS.js} +1 -1
  122. package/dist/assets/{grokvideo-CevWsp7R.js → grokvideo-Ce-wp7X8.js} +1 -1
  123. package/dist/assets/{hailuo-C0TD5cKV.js → hailuo-C0n1BlUe.js} +1 -1
  124. package/dist/assets/{headphones-CoB2FuvY.js → headphones-DbGJt6o-.js} +1 -1
  125. package/dist/assets/{history-ChqwA1sx.js → history-BdeFd4Se.js} +1 -1
  126. package/dist/assets/{i18n-DKpbcXFi.js → i18n-C1jUc4CA.js} +1 -1
  127. package/dist/assets/{image-9JTbfhGo.js → image-COzuHAHp.js} +1 -1
  128. package/dist/assets/{index-HueVnEkS.js → index-D2KbamIV.js} +4 -4
  129. package/dist/assets/{index.browser.esm-Dy_AYppK.js → index.browser.esm-IUjGjH9C.js} +1 -1
  130. package/dist/assets/{index.es-W0IWir34.js → index.es-7MahzVU6.js} +1 -1
  131. package/dist/assets/{info-BDWHCUui.js → info-CjU-dEjP.js} +1 -1
  132. package/dist/assets/{input-number-Dm870X3x.js → input-number-DnGrFJC4.js} +1 -1
  133. package/dist/assets/{key-round-dO2J-hTK.js → key-round-FJxJhpCB.js} +1 -1
  134. package/dist/assets/{kling-ZI4Si-yq.js → kling-m968smd-.js} +1 -1
  135. package/dist/assets/{languages-QqoyEYHt.js → languages-CDdjS8BG.js} +1 -1
  136. package/dist/assets/{laptop-BXa8R2Vm.js → laptop-nDqUxa55.js} +1 -1
  137. package/dist/assets/{lightbulb-CY7rMEhv.js → lightbulb--VfV3C2x.js} +1 -1
  138. package/dist/assets/{link-mnVkjvPN.js → link-B43DoAzy.js} +1 -1
  139. package/dist/assets/loader-circle-6GRNnXeA.js +1 -0
  140. package/dist/assets/{luma-DQGKXEU2.js → luma-QetSNes5.js} +1 -1
  141. package/dist/assets/{maestro-Bf6w5PyE.js → maestro-BU_sr8L-.js} +1 -1
  142. package/dist/assets/{maestro-CYTqc62P.js → maestro-Dg7f3xNS.js} +1 -1
  143. package/dist/assets/{mail-R1rALA82.js → mail-BxEeNP2x.js} +1 -1
  144. package/dist/assets/{message-circle-B7lC9rv4.js → message-circle-C39cnCq6.js} +1 -1
  145. package/dist/assets/{mic-XXm_qlFh.js → mic-u2eceaOj.js} +1 -1
  146. package/dist/assets/{midjourney-03rcpNTV.js → midjourney-B7XtsS0G.js} +1 -1
  147. package/dist/assets/{mobileLocalExec-DL3JBkU5.js → mobileLocalExec-DWX34QmU.js} +2 -2
  148. package/dist/assets/{mouse-pointer-2-BOZapvw4.js → mouse-pointer-2-DYhfxv2g.js} +1 -1
  149. package/dist/assets/music-2-DIRSZZAw.js +1 -0
  150. package/dist/assets/{nanobanana-BFpkQ9hD.js → nanobanana-DFkv6_am.js} +1 -1
  151. package/dist/assets/{omni-CuWltG7T.js → omni-Bfk0XgzR.js} +1 -1
  152. package/dist/assets/{openaiimage-DDEDV42_.js → openaiimage-TypXHP0b.js} +1 -1
  153. package/dist/assets/{pagination-B4WyicTK.js → pagination-Bx2rwdKO.js} +1 -1
  154. package/dist/assets/{pagination-Ch3ZD0YU.js → pagination-DI0mx7La.js} +1 -1
  155. package/dist/assets/{palette-D1F2RsSd.js → palette-DajZH23e.js} +1 -1
  156. package/dist/assets/{paperclip-DyRlfB5P.js → paperclip-CeiGa1NN.js} +1 -1
  157. package/dist/assets/{pause-88Matjz8.js → pause-B5Wi4fmq.js} +1 -1
  158. package/dist/assets/{pencil-DEwPs-h1.js → pencil-BAlIaHQT.js} +1 -1
  159. package/dist/assets/{pika-B9BtH8jE.js → pika-Bz_KYpgU.js} +1 -1
  160. package/dist/assets/{pixverse-DsjFyhBm.js → pixverse-nHlEwdRM.js} +1 -1
  161. package/dist/assets/play-BdKSwH7I.js +1 -0
  162. package/dist/assets/plus-mRzwIrZo.js +1 -0
  163. package/dist/assets/{popover-O2AvVGmo.js → popover-ZFV-9f-Y.js} +1 -1
  164. package/dist/assets/{producer-CnA0K2H9.js → producer-3uKdhRIE.js} +1 -1
  165. package/dist/assets/{producer-CE4yhHqC.js → producer-B0k42DR5.js} +1 -1
  166. package/dist/assets/{producer-D5Vp3I7K.js → producer-B8ObrtYf.js} +1 -1
  167. package/dist/assets/{producer-CysjZ5Ho.js → producer-BArQihgK.js} +1 -1
  168. package/dist/assets/{producer-DzXa0kVc.js → producer-BQN_CoQX.js} +1 -1
  169. package/dist/assets/{producer-CgbZVlyX.js → producer-BWwir-sg.js} +1 -1
  170. package/dist/assets/{producer-C9n4ici2.js → producer-BaEadrK8.js} +1 -1
  171. package/dist/assets/{producer-0Wl3-hrY.js → producer-Blx5SQRj.js} +1 -1
  172. package/dist/assets/{producer-CSr8tpG9.js → producer-Bm8L72Gu.js} +1 -1
  173. package/dist/assets/{producer-B_3gcqMY.js → producer-Bp-EFP0f.js} +1 -1
  174. package/dist/assets/{producer-CbB2dKUM.js → producer-BwbUYTKb.js} +1 -1
  175. package/dist/assets/{producer-BE7oXhRX.js → producer-C2fr3Pin.js} +1 -1
  176. package/dist/assets/{producer-BecWIOd2.js → producer-ClFMLi6f.js} +1 -1
  177. package/dist/assets/{producer-DMX5-AWP.js → producer-DMAkCnhQ.js} +1 -1
  178. package/dist/assets/{producer-DZkyJxYo.js → producer-DMC-Ypjp.js} +1 -1
  179. package/dist/assets/{producer-DvK6dOXK.js → producer-DuGest3a.js} +1 -1
  180. package/dist/assets/{producer-CVeJZZKP.js → producer-TydUhC8X.js} +1 -1
  181. package/dist/assets/{producer-BVfpDv5B.js → producer-j_7MrjGa.js} +1 -1
  182. package/dist/assets/{producer-B9ymDrd5.js → producer-wtV8-e06.js} +1 -1
  183. package/dist/assets/{qrart-BK3pdGU7.js → qrart-CIaEKetW.js} +1 -1
  184. package/dist/assets/{realtime-Cm9P734S.js → realtime-B1ZEf0bL.js} +1 -1
  185. package/dist/assets/{refresh-cw-BDmEed8N.js → refresh-cw-QDLWY-fy.js} +1 -1
  186. package/dist/assets/rotate-ccw-DP2T6aYp.js +1 -0
  187. package/dist/assets/rotate-cw-9hrXEO00.js +1 -0
  188. package/dist/assets/{row-2917HFEz.js → row-XN_1NmDQ.js} +1 -1
  189. package/dist/assets/search-C33VA7gE.js +1 -0
  190. package/dist/assets/{seedance-DNaXLwUR.js → seedance-DJPGYNu5.js} +1 -1
  191. package/dist/assets/{seedream-DD_refF5.js → seedream-nUAYGlat.js} +1 -1
  192. package/dist/assets/{select-CujkF0G4.js → select-BMxeX_Q6.js} +1 -1
  193. package/dist/assets/{serp-DXlsr4NR.js → serp-R0uBYSZf.js} +1 -1
  194. package/dist/assets/{shield-DFOZ5Lkv.js → shield-C3QqwpkZ.js} +1 -1
  195. package/dist/assets/{shuffle-Cw5d69-N.js → shuffle-DG28cSpn.js} +1 -1
  196. package/dist/assets/{slider-c_kWhhvW.js → slider-pCF5_BE2.js} +1 -1
  197. package/dist/assets/{sliders-horizontal-B4hD_yuS.js → sliders-horizontal-BnEC1R8e.js} +1 -1
  198. package/dist/assets/{solana-wallets-CXdLktRM.js → solana-wallets-1Pl2Jlpb.js} +2 -2
  199. package/dist/assets/{solana-wallets-vue-CDgANpwu.js → solana-wallets-vue-DlDFcTp8.js} +1 -1
  200. package/dist/assets/{sora-DkfKggb0.js → sora-DM9HyTsg.js} +1 -1
  201. package/dist/assets/square-BbQd6QRM.js +1 -0
  202. package/dist/assets/{suno-CUTaM9ED.js → suno-BLRI2UAL.js} +1 -1
  203. package/dist/assets/{suno-Cy3qahGj.js → suno-Bcyw0Nlp.js} +1 -1
  204. package/dist/assets/{suno-DP1W96Uo.js → suno-Bi-heWGL.js} +1 -1
  205. package/dist/assets/{suno-CeLnJ6pX.js → suno-BxIq5KoR.js} +1 -1
  206. package/dist/assets/{suno-CdctJLLF.js → suno-C9YVlJgz.js} +1 -1
  207. package/dist/assets/{suno-BXkXiY-K.js → suno-CJ4BKP6w.js} +1 -1
  208. package/dist/assets/{suno-OTeP2Qbe.js → suno-CLyjpAJS.js} +1 -1
  209. package/dist/assets/{suno-BzhSTQZl.js → suno-CitTjrMT.js} +1 -1
  210. package/dist/assets/{suno-B14a_qVe.js → suno-CmFPfcv0.js} +1 -1
  211. package/dist/assets/{suno-CryGSCVo.js → suno-D3jLPX8l.js} +1 -1
  212. package/dist/assets/{suno-DuyPAwQX.js → suno-D516lboD.js} +1 -1
  213. package/dist/assets/{suno-BZ0xZVei.js → suno-D9J4ShOX.js} +1 -1
  214. package/dist/assets/{suno-Bvgo4pUy.js → suno-DALwO_Yh.js} +1 -1
  215. package/dist/assets/{suno-BgOIfBpR.js → suno-DCbz_9oL.js} +1 -1
  216. package/dist/assets/{suno-ZT_zwqaH.js → suno-DVJtXVNr.js} +1 -1
  217. package/dist/assets/{suno-Cj06C03c.js → suno-DbafNoal.js} +1 -1
  218. package/dist/assets/{suno-gkIUmWCV.js → suno-DfmOry7Z.js} +1 -1
  219. package/dist/assets/{suno-B3kZsOKQ.js → suno-DyiCCL62.js} +1 -1
  220. package/dist/assets/{suno-C5dT6qP6.js → suno-xK7WiqQ5.js} +1 -1
  221. package/dist/assets/{switch-LdkfosbU.js → switch-BE2xBD5A.js} +1 -1
  222. package/dist/assets/{table-BKp5LY6p.js → table-hCS3Lu-E.js} +1 -1
  223. package/dist/assets/{tabs-sABJZ_9N.js → tabs-3KovSJUt.js} +1 -1
  224. package/dist/assets/{tag-DGWU4Oa3.js → tag-C2UoaZfq.js} +1 -1
  225. package/dist/assets/{taskDrawerMixin-DhokI8By.js → taskDrawerMixin-CPH1tFDk.js} +1 -1
  226. package/dist/assets/terminal-CQvHbrxf.js +1 -0
  227. package/dist/assets/{time-picker-BuglGpiD.js → time-picker-z3JpctYR.js} +1 -1
  228. package/dist/assets/{tooltip-bADrpFDW.js → tooltip-B9-_CGXS.js} +1 -1
  229. package/dist/assets/{trash-2-jmHFn8P9.js → trash-2-CQzI4SR2.js} +1 -1
  230. package/dist/assets/{triangle-alert-B1k_nXz3.js → triangle-alert-CpzfMnCj.js} +1 -1
  231. package/dist/assets/{upload-kpQsoant.js → upload-CPAboVFg.js} +1 -1
  232. package/dist/assets/{upload-DWCri-Uo.js → upload-TZ5yZ3pb.js} +1 -1
  233. package/dist/assets/user-DoRbb5Zr.js +1 -0
  234. package/dist/assets/{veo-CRqf93qR.js → veo-DO3MDPIi.js} +1 -1
  235. package/dist/assets/{video-CH9swUMD.js → video-XlqfvwNc.js} +1 -1
  236. package/dist/assets/{volume-2-5J431Jle.js → volume-2-Ba_CNfEK.js} +1 -1
  237. package/dist/assets/{wallet-C7ykUCMh.js → wallet-BAj_bz7Y.js} +1 -1
  238. package/dist/assets/{wan-CQV8SisV.js → wan-D2UlmZ9R.js} +1 -1
  239. package/dist/assets/{wand-sparkles-DMPZy37T.js → wand-sparkles-uSaWRXmg.js} +1 -1
  240. package/dist/assets/{web-DwjBSsj4.js → web-BDCq4QD2.js} +1 -1
  241. package/dist/assets/{web-CqNlDyMP.js → web-C_k03deu.js} +1 -1
  242. package/dist/assets/{web-Iq2QJ_HD.js → web-DSt5lSq7.js} +1 -1
  243. package/dist/assets/{web-D6BC12Q7.js → web-JLd2DGTq.js} +1 -1
  244. package/dist/assets/{web-Dv6Um30e.js → web-QpbsY3ZB.js} +1 -1
  245. package/dist/assets/{webextrator-DRtMVCYi.js → webextrator-B3dkXPNj.js} +1 -1
  246. package/dist/assets/{zap-BAa7yw1K.js → zap-Ccfr__j6.js} +1 -1
  247. package/dist/index.html +3 -3
  248. package/package.json +1 -1
  249. package/dist/assets/Index-3rK-ie45.js +0 -1
  250. package/dist/assets/Index-B0vtOZYU.js +0 -1
  251. package/dist/assets/Index-BAAOhVG9.js +0 -1
  252. package/dist/assets/Index-BDdryy8P.js +0 -1
  253. package/dist/assets/Index-BWhWeiAM.js +0 -1
  254. package/dist/assets/Index-Bmc3YMRF.js +0 -1
  255. package/dist/assets/Index-BuLoyPiQ.js +0 -1
  256. package/dist/assets/Index-CVCrjgJy.js +0 -1
  257. package/dist/assets/Index-CcZj8lKK.js +0 -1
  258. package/dist/assets/Index-Cfv2CsrT.js +0 -1
  259. package/dist/assets/Index-Cor6GI6u.js +0 -1
  260. package/dist/assets/Index-CwG0Wybc.js +0 -1
  261. package/dist/assets/Index-DB2Ln0Fu.js +0 -1
  262. package/dist/assets/Index-DDf8GeL7.js +0 -1
  263. package/dist/assets/Index-DGwj6IiZ.js +0 -1
  264. package/dist/assets/Index-DQeCIrDa.js +0 -1
  265. package/dist/assets/Index-DonTz-q0.js +0 -1
  266. package/dist/assets/Index-SJoi2Mcc.js +0 -1
  267. package/dist/assets/Index-rVhqsmNg.js +0 -1
  268. package/dist/assets/Index-sW5NNRv-.js +0 -1
  269. package/dist/assets/PromptTextarea-rU0VxEPx.js +0 -1
  270. package/dist/assets/Tts-BmjtT6g1.js +0 -1
  271. package/dist/assets/arrow-down-B8oqyNKL.js +0 -1
  272. package/dist/assets/arrow-left-DkUuliWv.js +0 -1
  273. package/dist/assets/arrow-right-CArIUigG.js +0 -1
  274. package/dist/assets/arrow-up-Bbc8SJs3.js +0 -1
  275. package/dist/assets/check-DV4FkQrg.js +0 -1
  276. package/dist/assets/chevron-down-W3k5n0Ah.js +0 -1
  277. package/dist/assets/chevron-right-kBdLENry.js +0 -1
  278. package/dist/assets/circle-check-CefLkQvB.js +0 -1
  279. package/dist/assets/clock-DL3k6CTu.js +0 -1
  280. package/dist/assets/esm-r5PnqmQa.js +0 -1
  281. package/dist/assets/gauge-3dRZbe6H.js +0 -1
  282. package/dist/assets/hash-4hvW7H7n.js +0 -1
  283. package/dist/assets/loader-circle-DZ_R4SoH.js +0 -1
  284. package/dist/assets/music-2-DatQtNXM.js +0 -1
  285. package/dist/assets/play-DaJSt9FF.js +0 -1
  286. package/dist/assets/plus-B69YkfCU.js +0 -1
  287. package/dist/assets/rotate-ccw-DFmQXFjQ.js +0 -1
  288. package/dist/assets/rotate-cw-DEhPjYGD.js +0 -1
  289. package/dist/assets/search--g06qalp.js +0 -1
  290. package/dist/assets/square-m-4tqqVg.js +0 -1
  291. package/dist/assets/terminal-BYTsu-BZ.js +0 -1
  292. package/dist/assets/user-Btm_bMcD.js +0 -1
@@ -1 +0,0 @@
1
- import"./rolldown-runtime--c01j_DQ.js";import{A as e,C as t,Gt as n,I as r,Jt as i,L as a,M as o,N as s,T as c,at as l,ht as u,it as d,j as f,mt as p,qt as m,rt as h,tt as g,x as _,z as v}from"./vendor-chart-Dw-P17PN.js";import{r as y,t as b}from"./select-CujkF0G4.js";import{t as x}from"./upload-DWCri-Uo.js";import{t as S}from"./tooltip-bADrpFDW.js";import{t as C}from"./alert-BZ-RGZ19.js";import{t as w}from"./drawer-6sGdi_7c.js";import{t as T}from"./input-number-Dm870X3x.js";import{t as E}from"./switch-LdkfosbU.js";import{n as D}from"./taskDrawerMixin-DhokI8By.js";import{t as O}from"./box-ErmvwLo6.js";import{t as k}from"./clock-DL3k6CTu.js";import{t as A}from"./CopyToClipboard-CukvJo1c.js";import{t as j}from"./hash-4hvW7H7n.js";import{t as M}from"./info-BDWHCUui.js";import{n as N,t as P}from"./PromptTextarea-rU0VxEPx.js";import{t as F}from"./triangle-alert-B1k_nXz3.js";import{t as I}from"./upload-kpQsoant.js";import{t as L}from"./volume-2-5J431Jle.js";import{t as R}from"./wand-sparkles-DMPZy37T.js";import{$t as ee,Gt as te,Kt as ne,Qt as re,Xt as ie,Yt as ae,Zt as oe,an as se,cn as z,en as ce,fn as B,in as le,ln as V,nn as ue,on as de,rn as fe,sn as pe,tn as me,un as H}from"./constants-dJ4RJksK.js";import{$t as he,Ai as U,Bt as W,E as G,Ht as K,Sn as ge,Vt as _e,Wt as ve,ei as q,gi as J,mr as ye,ri as Y,zt as be}from"./index-HueVnEkS.js";import{t as X}from"./ImagePreview-C_v2JWDj.js";import{t as xe}from"./Consumption-C9BeeUKY.js";import{a as Z,n as Se,r as Ce,t as we}from"./pagination-Ch3ZD0YU.js";import{t as Te}from"./VideoPlayer-Mi5BhTJB.js";import{t as Ee}from"./ApiCodeButton-B5bcZfdh.js";import{t as De}from"./BotPlaceholder-DrrclSPW.js";import{t as Oe}from"./ImageWrapper-B_bAW57k.js";import{n as ke,t as Ae}from"./AudioPreview-BS6RCUxd.js";var je=v({name:`LayoutSeedance`,components:{MagicIcon:R,ElDrawer:w,ElButton:U},mixins:[D]}),Me={class:`main flex flex-row flex-1`},Ne={class:`config w-[320px] flex-none h-full min-h-0 overflow-hidden flex flex-col bg-[var(--app-sidebar-bg)] border-r border-[var(--app-border-subtle)]`},Pe={class:`result h-full p-6 flex-1 flex flex-col min-w-0 overflow-x-hidden bg-[var(--app-content-bg)]`};function Fe(t,n,r,i,o,c){let f=l(`magic-icon`),m=l(`el-button`),h=l(`el-drawer`);return g(),s(`div`,Me,[e(`div`,Ne,[d(t.$slots,`config`,{},void 0,!0)]),e(`div`,Pe,[d(t.$slots,`result`,{},void 0,!0)]),u(a(m,{circle:``,class:`menu`,"aria-label":t.$t(`common.button.openMenu`),title:t.$t(`common.button.openMenu`),onClick:n[0]||=e=>t.drawer=!0},{default:p(()=>[a(f,{size:`1em`,"aria-hidden":`true`,focusable:`false`})]),_:1},8,[`aria-label`,`title`]),[[_,!t.tasksEmpty]]),a(h,{modelValue:t.drawer,"onUpdate:modelValue":n[1]||=e=>t.drawer=e,direction:`ltr`,"with-header":!1,size:`340px`,class:`generator-drawer`},{default:p(()=>[d(t.$slots,`config`,{},void 0,!0)]),_:3},8,[`modelValue`])])}var Ie=G(je,[[`render`,Fe],[`__scopeId`,`data-v-ff53dce1`]]),Le=v({name:`SeedancePromptInput`,components:{PromptTextarea:P},computed:{prompt:{get(){return this.$store.state.seedance?.config?.prompt},set(e){this.$store.commit(`seedance/setConfig`,{...this.$store.state.seedance?.config,prompt:e})}}},mounted(){this.prompt||=``}});function Re(e,t,n,r,i,a){let o=l(`prompt-textarea`);return g(),f(o,{modelValue:e.prompt,"onUpdate:modelValue":t[0]||=t=>e.prompt=t,title:e.$t(`seedance.name.prompt`),info:e.$t(`seedance.description.prompt`),placeholder:e.$t(`seedance.placeholder.prompt`),"min-rows":5},null,8,[`modelValue`,`title`,`info`,`placeholder`])}var ze=G(Le,[[`render`,Re]]),Be=v({name:`SeedanceModelSelector`,components:{ElSelect:y,ElOption:b,InfoIcon:Z},data(){return{options:[{value:ce,label:this.$t(`seedance.model.seedance20`)},{value:me,label:this.$t(`seedance.model.seedance20Fast`)},{value:ue,label:this.$t(`seedance.model.seedance20Mini`)},{value:ee,label:this.$t(`seedance.model.seedance15pro`)},{value:oe,label:this.$t(`seedance.model.seedance10pro`)},{value:re,label:this.$t(`seedance.model.seedance10proFast`)},{value:ie,label:this.$t(`seedance.model.seedance10liteT2v`)},{value:ae,label:this.$t(`seedance.model.seedance10liteI2v`)}]}},computed:{value:{get(){return this.$store.state.seedance?.config?.model},set(e){this.$store.commit(`seedance/setConfig`,{...this.$store.state.seedance?.config,model:e})}}},mounted(){this.value||=te}}),Ve={class:`field`},He={class:`label`},Ue={class:`box`},We={class:`title font-bold`};function Ge(t,n,r,o,u,d){let m=l(`info-icon`),_=l(`el-option`),v=l(`el-select`);return g(),s(`div`,Ve,[e(`div`,He,[e(`div`,Ue,[e(`h2`,We,i(t.$t(`seedance.name.model`)),1),a(m,{content:t.$t(`seedance.description.model`),class:`info`},null,8,[`content`])])]),a(v,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,class:`value`,placeholder:t.$t(`seedance.placeholder.select`)},{default:p(()=>[(g(!0),s(c,null,h(t.options,e=>(g(),f(_,{key:e.value,label:e.label,value:e.value},null,8,[`label`,`value`]))),128))]),_:1},8,[`modelValue`,`placeholder`])])}var Ke=G(Be,[[`render`,Ge],[`__scopeId`,`data-v-deb4c429`]]),qe=v({name:`SeedanceDurationSelector`,components:{ElSelect:y,ElOption:b,InfoIcon:Z},computed:{model(){return this.$store.state.seedance?.config?.model},capability(){return B(this.model)},options(){let e=[];this.capability.supportsAutoDuration&&e.push({value:-1,label:`${this.$t(`seedance.placeholder.seed`)} (-1)`});for(let t=this.capability.minDuration;t<=this.capability.maxDuration;t++)e.push({value:t,label:`${t}s`});return e},value:{get(){return this.$store.state.seedance?.config?.duration},set(e){this.$store.commit(`seedance/setConfig`,{...this.$store.state.seedance?.config,duration:e})}}},watch:{model(){this.clampValue()}},mounted(){this.value?this.clampValue():this.value=5},methods:{clampValue(){let e=this.value;e!==void 0&&!(e===-1&&this.capability.supportsAutoDuration)&&(e<this.capability.minDuration||e>this.capability.maxDuration)&&(this.value=5)}}}),Je={class:`field`},Ye={class:`label`},Xe={class:`box`},Ze={class:`title font-bold`};function Qe(t,n,r,o,u,d){let m=l(`info-icon`),_=l(`el-option`),v=l(`el-select`);return g(),s(`div`,Je,[e(`div`,Ye,[e(`div`,Xe,[e(`h2`,Ze,i(t.$t(`seedance.name.duration`)),1),a(m,{content:t.$t(`seedance.description.duration`),class:`info`},null,8,[`content`])])]),a(v,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,class:`value`,placeholder:t.$t(`seedance.placeholder.select`)},{default:p(()=>[(g(!0),s(c,null,h(t.options,e=>(g(),f(_,{key:e.value,label:e.label,value:e.value},null,8,[`label`,`value`]))),128))]),_:1},8,[`modelValue`,`placeholder`])])}var $e=G(qe,[[`render`,Qe],[`__scopeId`,`data-v-d61cc21b`]]),Q={[V]:0,[H]:1,[z]:2,"4k":3},et=v({name:`SeedanceResolutionSelector`,components:{InfoIcon:Z,ElTooltip:S},computed:{model(){return this.$store.state.seedance?.config?.model},capability(){return B(this.model)},options(){let e=[{value:V,label:`480p`},{value:H,label:`720p`},{value:z,label:`1080p`},{value:`4k`,label:`4k`}],t=Q[this.capability.maxResolution]??Q[`1080p`];return e.map(e=>({...e,disabled:Q[e.value]>t}))},value:{get(){return this.$store.state.seedance?.config?.resolution},set(e){this.$store.commit(`seedance/setConfig`,{...this.$store.state.seedance?.config,resolution:e})}}},watch:{model(){this.clampValue()}},mounted(){this.value?this.clampValue():this.value=this.capability.defaultResolution||`720p`},methods:{onSelect(e){e.disabled||(this.value=e.value)},clampValue(){let e=this.value,t=this.options.find(t=>t.value===e);(!e||t&&t.disabled)&&(this.value=this.capability.defaultResolution||`720p`)}}}),tt={class:`resolution`},nt={class:`header`},rt={class:`title font-bold`},it={class:`items`},at=[`onClick`];function ot(t,r,o,u,d,m){let _=l(`info-icon`),v=l(`el-tooltip`);return g(),s(`div`,tt,[e(`div`,nt,[e(`h2`,rt,i(t.$t(`seedance.name.resolution`)),1),a(_,{content:t.$t(`seedance.description.resolution`),class:`info`},null,8,[`content`])]),e(`div`,it,[(g(!0),s(c,null,h(t.options,r=>(g(),f(v,{key:r.value,content:t.$t(`seedance.message.resolutionNotSupported`),disabled:!r.disabled,placement:`top`},{default:p(()=>[e(`div`,{class:n([`item`,{active:t.value===r.value,disabled:r.disabled}]),onClick:e=>t.onSelect(r)},i(r.label),11,at)]),_:2},1032,[`content`,`disabled`]))),128))])])}var st=G(et,[[`render`,ot],[`__scopeId`,`data-v-db7e8aff`]]),ct=v({name:`SeedanceRatioSelector`,components:{InfoIcon:Z},computed:{options(){return[{value:le,label:`16:9`,w:32,h:18},{value:de,label:`9:16`,w:18,h:32},{value:`4:3`,label:`4:3`,w:28,h:21},{value:`3:4`,label:`3:4`,w:21,h:28},{value:`1:1`,label:`1:1`,w:24,h:24},{value:se,label:`21:9`,w:34,h:14},{value:pe,label:this.$t(`seedance.ratio.adaptive`),w:0,h:0}]},value:{get(){return this.$store.state.seedance?.config?.ratio},set(e){this.$store.commit(`seedance/setConfig`,{...this.$store.state.seedance?.config,ratio:e})}}},mounted(){this.value||=ne}}),lt={class:`ratio`},ut={class:`header`},dt={class:`title font-bold`},ft={class:`items`},pt=[`onClick`],mt={class:`preview`},ht={key:1,class:`rect rect-auto`},gt={class:`name`};function _t(t,r,o,u,d,f){let p=l(`info-icon`);return g(),s(`div`,lt,[e(`div`,ut,[e(`h2`,dt,i(t.$t(`seedance.name.ratio`)),1),a(p,{content:t.$t(`seedance.description.ratio`),class:`info`},null,8,[`content`])]),e(`div`,ft,[(g(!0),s(c,null,h(t.options,r=>(g(),s(`div`,{key:r.value,class:n([`item`,{active:t.value===r.value}]),onClick:e=>t.value=r.value},[e(`div`,mt,[r.w&&r.h?(g(),s(`div`,{key:0,class:`rect`,style:m({width:r.w+`px`,height:r.h+`px`})},null,4)):(g(),s(`div`,ht,`A`))]),e(`div`,gt,i(r.label),1)],10,pt))),128))])])}var vt=G(ct,[[`render`,_t],[`__scopeId`,`data-v-8ddec2dd`]]),yt=v({name:`SeedanceGenerateAudioSwitch`,components:{ElSwitch:E,InfoIcon:Z},computed:{isSupported(){let e=this.$store.state.seedance?.config?.model;return B(e).acceptsAudio},value:{get(){return this.$store.state.seedance?.config?.generate_audio??!1},set(e){this.$store.commit(`seedance/setConfig`,{...this.$store.state.seedance?.config,generate_audio:e})}}},watch:{isSupported(e){!e&&this.value&&(this.value=!1)}},mounted(){this.value===void 0&&(this.value=!1)}}),bt={key:0,class:`field`},xt={class:`label`},St={class:`box`},Ct={class:`title font-bold`},wt={class:`value`};function Tt(t,n,r,c,u,d){let f=l(`info-icon`),p=l(`el-switch`);return t.isSupported?(g(),s(`div`,bt,[e(`div`,xt,[e(`div`,St,[e(`h2`,Ct,i(t.$t(`seedance.name.generateAudio`)),1),a(f,{content:t.$t(`seedance.description.generateAudio`),class:`info`},null,8,[`content`])])]),e(`div`,wt,[a(p,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,"inline-prompt":``,"active-text":t.$t(`seedance.button.on`),"inactive-text":t.$t(`seedance.button.off`)},null,8,[`modelValue`,`active-text`,`inactive-text`])])])):o(``,!0)}var Et=G(yt,[[`render`,Tt],[`__scopeId`,`data-v-df51dfbd`]]),Dt=v({name:`SeedanceCameraFixedSwitch`,components:{ElSwitch:E,InfoIcon:Z},computed:{value:{get(){return this.$store.state.seedance?.config?.camerafixed??!1},set(e){this.$store.commit(`seedance/setConfig`,{...this.$store.state.seedance?.config,camerafixed:e})}}},mounted(){this.$store.state.seedance?.config?.camerafixed===void 0&&(this.value=!1)}}),Ot={class:`field`},kt={class:`label`},At={class:`box`},jt={class:`title font-bold`},Mt={class:`value`};function Nt(t,n,r,o,c,u){let d=l(`info-icon`),f=l(`el-switch`);return g(),s(`div`,Ot,[e(`div`,kt,[e(`div`,At,[e(`h2`,jt,i(t.$t(`seedance.name.cameraFixed`)),1),a(d,{content:t.$t(`seedance.description.cameraFixed`),class:`info`},null,8,[`content`])])]),e(`div`,Mt,[a(f,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,"inline-prompt":``,"active-text":t.$t(`seedance.button.on`),"inactive-text":t.$t(`seedance.button.off`)},null,8,[`modelValue`,`active-text`,`inactive-text`])])])}var Pt=G(Dt,[[`render`,Nt],[`__scopeId`,`data-v-ae777d61`]]),Ft=v({name:`SeedanceFirstFrameImage`,components:{UploadIcon:I,ElUpload:x,ElButton:U,InfoIcon:Z,ImagePreview:X},mixins:[K,W],data(){return{fileList:[],uploadUrl:Y()+`/api/v1/files/`}},computed:{headers(){return{Authorization:`Bearer ${this.$store.state.token.access}`}},model(){return this.$store.state.seedance?.config?.model},capability(){return B(this.model)},urls(){return this.fileList.map(e=>e?.response?.file_url)}},watch:{"capability.acceptsImage"(e){e||(this.fileList=[],this.onSetFirstFrameUrl())}},methods:{onExceed(){J.warning(this.$t(`seedance.message.uploadExceed`))},onError(){J.error(this.$t(`seedance.message.uploadError`))},onSetFirstFrameUrl(){let e=this.urls?.[0],t=(this.$store.state.seedance?.config?.images||[]).filter(e=>e?.role!==`first_frame`);e&&t.push({url:e,role:`first_frame`}),this.$store.commit(`seedance/setConfig`,{...this.$store.state.seedance?.config,images:t.length>0?t:void 0})},async onSuccess(){this.onSetFirstFrameUrl()},async onRemove(){this.onSetFirstFrameUrl()}}}),It={key:0,class:`relative`},Lt={class:`flex min-h-8 items-center pr-20`},Rt={class:`flex justify-start items-center`},zt={class:`text-sm font-bold`},Bt={key:0,class:`required-badge`};function Vt(t,n,c,u,d,m){let h=l(`info-icon`),_=l(`image-preview`),v=l(`upload-icon`),y=l(`el-button`),b=l(`el-upload`);return t.capability.acceptsImage?(g(),s(`div`,It,[e(`div`,Lt,[e(`div`,Rt,[e(`span`,zt,i(t.$t(`seedance.name.firstFrame`)),1),t.capability.requiresImage?(g(),s(`span`,Bt,i(t.$t(`seedance.name.required`)),1)):o(``,!0),a(h,{content:t.$t(`seedance.description.firstFrame`)},null,8,[`content`])])]),a(b,{ref:`uploader`,"file-list":t.fileList,"onUpdate:fileList":n[0]||=e=>t.fileList=e,name:`file`,accept:`.png,.jpg,.jpeg,.gif,.bmp,.webp`,limit:1,class:`upload-wrapper`,multiple:!1,action:t.uploadUrl,"list-type":`picture`,"on-exceed":t.onExceed,"on-error":t.onError,"on-success":t.onSuccess,"on-remove":t.onRemove,headers:t.headers},{file:p(({file:e})=>[e.url&&e.percentage!==void 0?(g(),f(_,{key:0,url:e.url,name:e.name,percentage:e.percentage,onRemove:n=>t.fileList.splice(t.fileList.indexOf(e),1)},null,8,[`url`,`name`,`percentage`,`onRemove`])):o(``,!0)]),default:p(()=>[a(y,{round:``,type:`primary`,size:`small`,class:`btn btn-upload`},{default:p(()=>[a(v,{class:`icon mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(t.$t(`seedance.button.upload`)),1)]),_:1})]),_:1},8,[`file-list`,`action`,`on-exceed`,`on-error`,`on-success`,`on-remove`,`headers`])])):o(``,!0)}var Ht=G(Ft,[[`render`,Vt],[`__scopeId`,`data-v-580c8fd6`]]),Ut=v({name:`SeedanceLastFrameImage`,components:{UploadIcon:I,ElUpload:x,ElButton:U,ImagePreview:X,InfoIcon:Z},mixins:[K,W],data(){return{fileList:[],uploadUrl:Y()+`/api/v1/files/`}},computed:{headers(){return{Authorization:`Bearer ${this.$store.state.token.access}`}},model(){return this.$store.state.seedance?.config?.model},capability(){return B(this.model)},urls(){return this.fileList.map(e=>e?.response?.file_url)}},watch:{"capability.acceptsLastFrame"(e){e||(this.fileList=[],this.onSetLastFrameUrl())}},methods:{onExceed(){J.warning(this.$t(`seedance.message.uploadExceed`))},onError(){J.error(this.$t(`seedance.message.uploadError`))},onSetLastFrameUrl(){let e=this.urls?.[0],t=(this.$store.state.seedance?.config?.images||[]).filter(e=>e?.role!==`last_frame`);e&&t.push({url:e,role:`last_frame`}),this.$store.commit(`seedance/setConfig`,{...this.$store.state.seedance?.config,images:t.length>0?t:void 0})},async onSuccess(){this.onSetLastFrameUrl()},async onRemove(){this.onSetLastFrameUrl()}}}),Wt={key:0,class:`relative`},Gt={class:`flex min-h-8 items-center pr-20`},Kt={class:`flex justify-start items-center`},qt={class:`text-sm font-bold`};function Jt(t,n,c,u,d,m){let h=l(`info-icon`),_=l(`image-preview`),v=l(`upload-icon`),y=l(`el-button`),b=l(`el-upload`);return t.capability.acceptsLastFrame?(g(),s(`div`,Wt,[e(`div`,Gt,[e(`div`,Kt,[e(`span`,qt,i(t.$t(`seedance.name.lastFrame`)),1),a(h,{content:t.$t(`seedance.description.lastFrame`)},null,8,[`content`])])]),a(b,{ref:`uploader`,"file-list":t.fileList,"onUpdate:fileList":n[0]||=e=>t.fileList=e,name:`file`,accept:`.png,.jpg,.jpeg,.gif,.bmp,.webp`,limit:1,class:`upload-wrapper`,multiple:!1,action:t.uploadUrl,"list-type":`picture`,"on-exceed":t.onExceed,"on-error":t.onError,"on-success":t.onSuccess,"on-remove":t.onRemove,headers:t.headers},{file:p(({file:e})=>[e.url&&e.percentage!==void 0?(g(),f(_,{key:0,url:e.url,name:e.name,percentage:e.percentage,onRemove:n=>t.fileList.splice(t.fileList.indexOf(e),1)},null,8,[`url`,`name`,`percentage`,`onRemove`])):o(``,!0)]),default:p(()=>[a(y,{round:``,type:`primary`,size:`small`,class:`btn btn-upload`},{default:p(()=>[a(v,{class:`icon mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(t.$t(`seedance.button.upload`)),1)]),_:1})]),_:1},8,[`file-list`,`action`,`on-exceed`,`on-error`,`on-success`,`on-remove`,`headers`])])):o(``,!0)}var Yt=G(Ut,[[`render`,Jt],[`__scopeId`,`data-v-cfc723b2`]]),Xt=v({name:`SeedanceReferenceImage`,components:{UploadIcon:I,ElUpload:x,ElButton:U,InfoIcon:Z,ImagePreview:X},mixins:[K,W],data(){return{fileList:[],uploadUrl:Y()+`/api/v1/files/`}},computed:{headers(){return{Authorization:`Bearer ${this.$store.state.token.access}`}},model(){return this.$store.state.seedance?.config?.model},capability(){return B(this.model)},urls(){return this.fileList.map(e=>e?.response?.file_url)}},watch:{"capability.acceptsReferenceImage"(e){e||(this.fileList=[],this.onSetReferenceImageUrls())}},methods:{onExceed(){J.warning(this.$t(`seedance.message.uploadExceed`))},onError(){J.error(this.$t(`seedance.message.uploadError`))},onSetReferenceImageUrls(){let e=(this.urls||[]).filter(Boolean),t=(this.$store.state.seedance?.config?.images||[]).filter(e=>e?.role!==`reference_image`);e.forEach(e=>t.push({url:e,role:`reference_image`})),this.$store.commit(`seedance/setConfig`,{...this.$store.state.seedance?.config,images:t.length>0?t:void 0})},async onSuccess(){this.onSetReferenceImageUrls()},async onRemove(){this.onSetReferenceImageUrls()}}}),Zt={key:0,class:`relative`},Qt={class:`flex min-h-8 items-center pr-20`},$t={class:`flex justify-start items-center`},en={class:`text-sm font-bold`};function tn(t,n,c,u,d,m){let h=l(`info-icon`),_=l(`image-preview`),v=l(`upload-icon`),y=l(`el-button`),b=l(`el-upload`);return t.capability.acceptsReferenceImage?(g(),s(`div`,Zt,[e(`div`,Qt,[e(`div`,$t,[e(`span`,en,i(t.$t(`seedance.name.referenceImage`)),1),a(h,{content:t.$t(`seedance.description.referenceImage`)},null,8,[`content`])])]),a(b,{ref:`uploader`,"file-list":t.fileList,"onUpdate:fileList":n[0]||=e=>t.fileList=e,name:`file`,accept:`.png,.jpg,.jpeg,.gif,.bmp,.webp`,limit:1,class:`upload-wrapper`,multiple:!1,action:t.uploadUrl,"list-type":`picture`,"on-exceed":t.onExceed,"on-error":t.onError,"on-success":t.onSuccess,"on-remove":t.onRemove,headers:t.headers},{file:p(({file:e})=>[e.url&&e.percentage!==void 0?(g(),f(_,{key:0,url:e.url,name:e.name,percentage:e.percentage,onRemove:n=>t.fileList.splice(t.fileList.indexOf(e),1)},null,8,[`url`,`name`,`percentage`,`onRemove`])):o(``,!0)]),default:p(()=>[a(y,{round:``,type:`primary`,size:`small`,class:`btn btn-upload`},{default:p(()=>[a(v,{class:`icon mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(t.$t(`seedance.button.upload`)),1)]),_:1})]),_:1},8,[`file-list`,`action`,`on-exceed`,`on-error`,`on-success`,`on-remove`,`headers`])])):o(``,!0)}var nn=G(Xt,[[`render`,tn],[`__scopeId`,`data-v-37c817a4`]]),rn=v({name:`SeedanceReferenceAudio`,components:{UploadIcon:I,ElUpload:x,ElButton:U,InfoIcon:Z},mixins:[W],data(){return{fileList:[],uploadUrl:Y()+`/api/v1/files/`}},computed:{headers(){return{Authorization:`Bearer ${this.$store.state.token.access}`}},model(){return this.$store.state.seedance?.config?.model},capability(){return B(this.model)},urls(){return this.fileList.map(e=>e?.response?.file_url)}},watch:{"capability.acceptsReferenceAudio"(e){e||(this.fileList=[],this.onSetReferenceAudios())}},methods:{onExceed(){J.warning(this.$t(`seedance.message.uploadExceed`))},onError(){J.error(this.$t(`seedance.message.uploadError`))},onSetReferenceAudios(){let e=(this.urls||[]).filter(Boolean);this.$store.commit(`seedance/setConfig`,{...this.$store.state.seedance?.config,audios:e.length>0?e.map(e=>({url:e})):void 0})},async onSuccess(){this.onSetReferenceAudios()},async onRemove(){this.onSetReferenceAudios()}}}),an={key:0,class:`relative`},on={class:`flex min-h-8 items-center pr-20`},sn={class:`flex justify-start items-center`},cn={class:`text-sm font-bold`};function ln(t,n,c,u,d,f){let m=l(`info-icon`),h=l(`upload-icon`),_=l(`el-button`),v=l(`el-upload`);return t.capability.acceptsReferenceAudio?(g(),s(`div`,an,[e(`div`,on,[e(`div`,sn,[e(`span`,cn,i(t.$t(`seedance.name.referenceAudio`)),1),a(m,{content:t.$t(`seedance.description.referenceAudio`)},null,8,[`content`])])]),a(v,{ref:`uploader`,"file-list":t.fileList,"onUpdate:fileList":n[0]||=e=>t.fileList=e,name:`file`,accept:`.mp3,.wav,.m4a,.aac,.ogg,.flac`,limit:1,class:`upload-wrapper`,multiple:!1,action:t.uploadUrl,"list-type":`text`,"on-exceed":t.onExceed,"on-error":t.onError,"on-success":t.onSuccess,"on-remove":t.onRemove,headers:t.headers},{default:p(()=>[a(_,{round:``,type:`primary`,size:`small`,class:`btn btn-upload`},{default:p(()=>[a(h,{class:`icon mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(t.$t(`seedance.button.upload`)),1)]),_:1})]),_:1},8,[`file-list`,`action`,`on-exceed`,`on-error`,`on-success`,`on-remove`,`headers`])])):o(``,!0)}var un=G(rn,[[`render`,ln],[`__scopeId`,`data-v-e8a1ca2b`]]),dn=v({name:`SeedanceReferenceVideo`,components:{UploadIcon:I,ElUpload:x,ElButton:U,InfoIcon:Z},mixins:[W],data(){return{fileList:[],uploadUrl:Y()+`/api/v1/files/`}},computed:{headers(){return{Authorization:`Bearer ${this.$store.state.token.access}`}},model(){return this.$store.state.seedance?.config?.model},capability(){return B(this.model)},urls(){return this.fileList.map(e=>e?.response?.file_url)}},watch:{"capability.acceptsReferenceVideo"(e){e||(this.fileList=[],this.onSetReferenceVideos())}},methods:{onExceed(){J.warning(this.$t(`seedance.message.uploadExceed`))},onError(){J.error(this.$t(`seedance.message.uploadError`))},onSetReferenceVideos(){let e=(this.urls||[]).filter(Boolean);this.$store.commit(`seedance/setConfig`,{...this.$store.state.seedance?.config,videos:e.length>0?e.map(e=>({url:e})):void 0})},async onSuccess(){this.onSetReferenceVideos()},async onRemove(){this.onSetReferenceVideos()}}}),fn={key:0,class:`relative`},pn={class:`flex min-h-8 items-center pr-20`},mn={class:`flex justify-start items-center`},hn={class:`text-sm font-bold`};function gn(t,n,c,u,d,f){let m=l(`info-icon`),h=l(`upload-icon`),_=l(`el-button`),v=l(`el-upload`);return t.capability.acceptsReferenceVideo?(g(),s(`div`,fn,[e(`div`,pn,[e(`div`,mn,[e(`span`,hn,i(t.$t(`seedance.name.referenceVideo`)),1),a(m,{content:t.$t(`seedance.description.referenceVideo`)},null,8,[`content`])])]),a(v,{ref:`uploader`,"file-list":t.fileList,"onUpdate:fileList":n[0]||=e=>t.fileList=e,name:`file`,accept:`.mp4,.mov,.webm,.mkv,.avi`,limit:1,class:`upload-wrapper`,multiple:!1,action:t.uploadUrl,"list-type":`text`,"on-exceed":t.onExceed,"on-error":t.onError,"on-success":t.onSuccess,"on-remove":t.onRemove,headers:t.headers},{default:p(()=>[a(_,{round:``,type:`primary`,size:`small`,class:`btn btn-upload`},{default:p(()=>[a(h,{class:`icon mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(t.$t(`seedance.button.upload`)),1)]),_:1})]),_:1},8,[`file-list`,`action`,`on-exceed`,`on-error`,`on-success`,`on-remove`,`headers`])])):o(``,!0)}var _n=G(dn,[[`render`,gn],[`__scopeId`,`data-v-123c4f63`]]),vn=v({name:`SeedanceReturnLastFrameSwitch`,components:{ElSwitch:E,InfoIcon:Z},computed:{model(){return this.$store.state.seedance?.config?.model},isSupported(){return B(this.model).acceptsReturnLastFrame},value:{get(){return this.$store.state.seedance?.config?.return_last_frame},set(e){this.$store.commit(`seedance/setConfig`,{...this.$store.state.seedance?.config,return_last_frame:e})}}},watch:{isSupported(e){!e&&this.value&&(this.value=!1)}},mounted(){this.value===void 0&&(this.value=!1)}}),yn={key:0,class:`field`},bn={class:`label`},xn={class:`box`},Sn={class:`title font-bold`},Cn={class:`value`};function wn(t,n,r,c,u,d){let f=l(`info-icon`),p=l(`el-switch`);return t.isSupported?(g(),s(`div`,yn,[e(`div`,bn,[e(`div`,xn,[e(`h2`,Sn,i(t.$t(`seedance.name.returnLastFrame`)),1),a(f,{content:t.$t(`seedance.description.returnLastFrame`),class:`info`},null,8,[`content`])])]),e(`div`,Cn,[a(p,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,"inline-prompt":``,"active-text":t.$t(`seedance.button.on`),"inactive-text":t.$t(`seedance.button.off`)},null,8,[`modelValue`,`active-text`,`inactive-text`])])])):o(``,!0)}var Tn=G(vn,[[`render`,wn],[`__scopeId`,`data-v-edea5451`]]),En=v({name:`SeedanceSeedInput`,components:{ElInputNumber:T,InfoIcon:Z},computed:{value:{get(){let e=this.$store.state.seedance?.config?.seed;return typeof e==`number`?e:-1},set(e){let t={...this.$store.state.seedance?.config||{}};t.seed=typeof e==`number`&&Number.isInteger(e)?e:-1,this.$store.commit(`seedance/setConfig`,t)}}}}),Dn={class:`field`},On={class:`label`},kn={class:`box`},An={class:`title font-bold`},jn={class:`value`};function Mn(t,n,r,o,c,u){let d=l(`info-icon`),f=l(`el-input-number`);return g(),s(`div`,Dn,[e(`div`,On,[e(`div`,kn,[e(`h2`,An,i(t.$t(`seedance.name.seed`)),1),a(d,{content:t.$t(`seedance.description.seed`),class:`info`},null,8,[`content`])])]),e(`div`,jn,[a(f,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,min:-1,max:2147483647,step:1,size:`default`,"controls-position":`right`,class:`counter`},null,8,[`modelValue`])])])}var Nn=v({name:`SeedanceConfigPanel`,components:{MagicIcon:R,ElButton:U,PromptInput:ze,ModelSelector:Ke,DurationSelector:$e,ResolutionSelector:st,RatioSelector:vt,GenerateAudioSwitch:Et,CameraFixedSwitch:Pt,ReturnLastFrameSwitch:Tn,SeedInput:G(En,[[`render`,Mn],[`__scopeId`,`data-v-685a9869`]]),FirstFrameImage:Ht,LastFrameImage:Yt,ReferenceImage:nn,ReferenceAudio:un,ReferenceVideo:_n,Consumption:xe},emits:[`generate`],computed:{config(){return this.$store.state.seedance?.config},consumption(){return ve(this.config,this.service?.cost)},service(){return this.$store.state.seedance?.service}},methods:{onGenerate(){this.$emit(`generate`)}}}),Pn={class:`flex flex-col h-full`},Fn={class:`flex-1 overflow-y-auto p-5`},In={class:`flex flex-col items-center justify-center px-5 pb-5`};function Ln(t,n,o,c,u,d){let f=l(`prompt-input`),m=l(`model-selector`),h=l(`ratio-selector`),_=l(`resolution-selector`),v=l(`duration-selector`),y=l(`generate-audio-switch`),b=l(`camera-fixed-switch`),x=l(`return-last-frame-switch`),S=l(`seed-input`),C=l(`first-frame-image`),w=l(`last-frame-image`),T=l(`reference-image`),E=l(`reference-audio`),D=l(`reference-video`),O=l(`consumption`),k=l(`magic-icon`),A=l(`el-button`);return g(),s(`div`,Pn,[e(`div`,Fn,[a(f,{class:`mb-4`}),a(m,{class:`mb-4`}),a(h,{class:`mb-4`}),a(_,{class:`mb-4`}),a(v,{class:`mb-4`}),a(y,{class:`mb-4`}),a(b,{class:`mb-4`}),a(x,{class:`mb-4`}),a(S,{class:`mb-4`}),a(C,{class:`mb-4`}),a(w,{class:`mb-4`}),a(T,{class:`mb-4`}),a(E,{class:`mb-4`}),a(D,{class:`mb-4`})]),e(`div`,In,[a(O,{value:t.consumption,service:t.service},null,8,[`value`,`service`]),a(A,{type:`primary`,class:`btn w-full`,round:``,onClick:t.onGenerate},{default:p(()=>[a(k,{class:`mr-2`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(t.$t(`seedance.button.generate`)),1)]),_:1},8,[`onClick`])])])}var Rn=G(Nn,[[`render`,Ln]]),zn=v({name:`SeedanceTaskPreview`,components:{ApplicationIcon:O,ChannelIcon:j,FullscreenIcon:N,InfoIcon:M,MagicIcon:R,TimeIcon:k,VolumeIcon:L,WarningIcon:F,CopyToClipboard:A,ElAlert:C,VideoPlayer:Te,ElTooltip:S,ElButton:U,ImageWrapper:Oe,ImagePreview:X,AudioPreview:Ae,VideoPreview:ke,ApiCodeButton:Ee},props:{modelValue:{type:Object,required:!0}},computed:{video(){return this.modelValue?.response?.data},apiCodeBody(){let e=this.modelValue?.request;if(!e)return e;let{service_tier:t,...n}=e;return n},promptText(){let e=this.modelValue?.request;if(e?.prompt)return e.prompt;let t=e?.content?.find(e=>e?.type===`text`&&e?.text);return t?.text?t.text:this.video?.prompt},referenceImages(){let e=this.collectImages();if(e.length===0)return[];let t=[],n=e.find(e=>e?.role===`first_frame`);n?.url&&t.push({url:n.url,name:`first-frame`});let r=e.find(e=>e?.role===`last_frame`);return r?.url&&t.push({url:r.url,name:`last-frame`}),e.forEach((e,n)=>{e?.url&&e.role!==`first_frame`&&e.role!==`last_frame`&&t.push({url:e.url,name:e.role||`image-${n}`})}),t},referenceAudios(){let e=this.modelValue?.request,t=(e?.audios??[]).map(e=>e?.url).filter(Boolean);return(e?.content??[]).forEach(e=>{e?.type===`audio_url`&&e?.audio_url?.url&&t.push(e.audio_url.url)}),t},referenceVideos(){let e=this.modelValue?.request,t=(e?.videos??[]).map(e=>e?.url).filter(Boolean);return(e?.content??[]).forEach(e=>{e?.type===`video_url`&&e?.video_url?.url&&t.push(e.video_url.url)}),t}},methods:{collectImages(){let e=this.modelValue?.request,t=Array.isArray(e?.images)?[...e.images]:[];return(e?.content??[]).forEach(e=>{e?.type===`image_url`&&e?.image_url?.url&&t.push({url:e.image_url.url,role:e.role})}),t},onDownload(e){window.open(e,`_blank`)}}}),Bn={class:`preview`},Vn={class:`left`},Hn={class:`main`},Un={class:`bot`},Wn={class:`datetime`},Gn={class:`info`},Kn={key:0,class:`flex justify-start items-center gap-2 mt-2 w-full overflow-x-auto`},qn={key:1,class:`prompt mt-2`},Jn={key:0},Yn={key:1},Xn={key:0,class:n({content:!0})},Zn={class:`text-[var(--el-text-color-regular)] text-xs mb-0`},Qn={key:1,class:n({content:!0})},$n={key:0,class:`mb-4`},er={key:1,class:`mb-4`},tr={key:2,class:n({operations:!0,"mt-2":!0,"mb-2":!0})},nr={key:0,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},rr={key:1,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},ir={key:2,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},ar={key:0},or={key:1},sr={key:3,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},$={class:`text-[var(--el-text-color-regular)] text-xs mb-2`},cr={key:4,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},lr={key:5,class:`text-[var(--el-text-color-regular)] text-xs mb-0`},ur={key:2,class:n({content:!0})},dr={class:`text-[var(--el-text-color-regular)] text-xs mb-2`},fr={key:0,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},pr={key:1,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},mr={key:2,class:`text-[var(--el-text-color-regular)] text-xs mb-0`},hr={key:3,class:n({content:!0})},gr={class:`text-[var(--el-text-color-regular)] text-xs mb-2`},_r={key:0,class:`text-[var(--el-text-color-regular)] text-xs mb-0`};function vr(n,u,d,m,_,v){let y=l(`capability-presentation`),b=l(`image-preview`),x=l(`audio-preview`),S=l(`video-preview`),C=l(`time-icon`),w=l(`magic-icon`),T=l(`copy-to-clipboard`),E=l(`el-alert`),D=l(`video-player`),O=l(`image-wrapper`),k=l(`el-button`),A=l(`el-tooltip`),j=l(`api-code-button`),M=l(`application-icon`),N=l(`fullscreen-icon`),P=l(`volume-icon`),F=l(`channel-icon`),I=l(`warning-icon`),L=l(`info-icon`);return g(),s(`div`,Bn,[e(`div`,Vn,[a(y,{capability:`seedance`,part:`avatar`,class:`avatar`})]),e(`div`,Hn,[e(`div`,Un,[a(y,{capability:`seedance`,part:`name`}),e(`span`,Wn,i(n.$dayjs.format(``+new Date(parseFloat((n.modelValue?.created_at||``).toString())*1e3))),1)]),e(`div`,Gn,[n.referenceImages.length>0||n.referenceAudios.length>0||n.referenceVideos.length>0?(g(),s(`div`,Kn,[(g(!0),s(c,null,h(n.referenceImages,(e,t)=>(g(),f(b,{key:`image-${t}`,url:e.url,name:e.name,closable:!1},null,8,[`url`,`name`]))),128)),(g(!0),s(c,null,h(n.referenceAudios,(e,t)=>(g(),f(x,{key:`audio-${t}`,url:e,name:`audio-${t+1}`},null,8,[`url`,`name`]))),128)),(g(!0),s(c,null,h(n.referenceVideos,(e,t)=>(g(),f(S,{key:`video-${t}`,url:e,name:`video-${t+1}`},null,8,[`url`,`name`]))),128))])):o(``,!0),n.promptText?(g(),s(`p`,qn,[r(i(n.promptText)+` `,1),n.modelValue?.response?n.video?.status===`processing`||n.video?.status===`pending`?(g(),s(`span`,Yn,` - (`+i(n.$t(`seedance.status.processing`))+`) `,1)):o(``,!0):(g(),s(`span`,Jn,` - (`+i(n.$t(`seedance.status.pending`))+`) `,1))])):o(``,!0)]),n.modelValue?.response?n.modelValue?.response?.success===!0?(g(),s(`div`,Qn,[n.video?.video_url?(g(),s(`div`,$n,[a(D,{src:n.video?.video_url},null,8,[`src`])])):o(``,!0),n.video?.last_frame_url?(g(),s(`div`,er,[a(O,{src:n.video?.last_frame_url,"raw-src":n.video?.last_frame_url},null,8,[`src`,`raw-src`])])):o(``,!0),n.video?.video_url?(g(),s(`div`,tr,[a(A,{class:`box-item`,effect:`dark`,content:n.$t(`seedance.message.downloadVideo`),placement:`top-start`},{default:p(()=>[a(k,{type:`info`,size:`small`,class:`btn-action`,onClick:u[0]||=t(e=>n.onDownload(n.video?.video_url),[`stop`])},{default:p(()=>[r(i(n.$t(`seedance.button.download`)),1)]),_:1})]),_:1},8,[`content`]),a(j,{path:`/seedance/videos`,body:n.apiCodeBody},null,8,[`body`])])):o(``,!0),a(E,{closable:!1,class:`mt-2 success`},{default:p(()=>[n.modelValue?.request?.model?(g(),s(`p`,nr,[a(M,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(n.$t(`seedance.name.model`))+`: `+i(n.modelValue?.request?.model),1)])):o(``,!0),n.video?.duration?(g(),s(`p`,rr,[a(C,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(n.$t(`seedance.name.duration`))+`: `+i(n.video?.duration)+`s `,1)])):o(``,!0),n.video?.resolution?(g(),s(`p`,ir,[a(N,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(n.$t(`seedance.name.resolution`))+`: `+i(n.video?.resolution)+` `,1),n.video?.ratio?(g(),s(`span`,ar,` · `+i(n.video?.ratio),1)):o(``,!0),n.video?.framespersecond?(g(),s(`span`,or,` · `+i(n.video?.framespersecond)+`fps`,1)):o(``,!0)])):o(``,!0),n.modelValue?.request?.generate_audio?(g(),s(`p`,sr,[a(P,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(n.$t(`seedance.name.generateAudio`))+`: `+i(n.$t(`seedance.button.on`)),1)])):o(``,!0),e(`p`,$,[a(w,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(n.$t(`seedance.name.taskId`))+`: `+i(n.modelValue?.id)+` `,1),a(T,{content:n.modelValue?.id,class:`btn-copy inline-block`},null,8,[`content`])]),n.modelValue?.elapsed?(g(),s(`p`,cr,[a(C,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(n.$t(`seedance.name.elapsed`))+`: `+i(n.modelValue?.elapsed?.toFixed(2))+`s `,1)])):o(``,!0),n.modelValue?.response?.trace_id?(g(),s(`p`,lr,[a(F,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(n.$t(`seedance.name.traceId`))+`: `+i(n.modelValue?.response?.trace_id)+` `,1),a(T,{content:n.modelValue?.response?.trace_id,class:`btn-copy inline-block`},null,8,[`content`])])):o(``,!0)]),_:1})])):n.modelValue?.response?.success===!1?(g(),s(`div`,ur,[a(E,{closable:!1,class:`failure`},{template:p(()=>[a(I,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(n.$t(`seedance.name.failure`)),1)]),default:p(()=>[e(`p`,dr,[a(w,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(n.$t(`seedance.name.taskId`))+`: `+i(n.modelValue?.id)+` `,1),a(T,{content:n.modelValue?.id,class:`btn-copy inline-block`},null,8,[`content`])]),n.modelValue?.response?.error?.message?(g(),s(`p`,fr,[a(L,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(n.$t(`seedance.name.failureReason`))+`: `+i(n.modelValue?.response?.error?.message)+` `,1),a(T,{content:n.modelValue?.response?.error?.message,class:`btn-copy inline-block`},null,8,[`content`])])):o(``,!0),n.modelValue?.elapsed?(g(),s(`p`,pr,[a(C,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(n.$t(`seedance.name.elapsed`))+`: `+i(n.modelValue?.elapsed?.toFixed(2))+`s `,1)])):o(``,!0),n.modelValue?.response?.trace_id?(g(),s(`p`,mr,[a(F,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(n.$t(`seedance.name.traceId`))+`: `+i(n.modelValue?.response?.trace_id)+` `,1),a(T,{content:n.modelValue?.response?.trace_id,class:`btn-copy inline-block`},null,8,[`content`])])):o(``,!0)]),_:1})])):(g(),s(`div`,hr,[a(E,{closable:!1,class:`info`},{template:p(()=>[a(L,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(n.$t(`seedance.name.status`)),1)]),default:p(()=>[e(`p`,gr,[a(w,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(n.$t(`seedance.name.taskId`))+`: `+i(n.modelValue?.id)+` `,1),a(T,{content:n.modelValue?.id,class:`btn-copy inline-block`},null,8,[`content`])]),n.modelValue?.response?.trace_id?(g(),s(`p`,_r,[a(F,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(n.$t(`seedance.name.traceId`))+`: `+i(n.modelValue?.response?.trace_id)+` `,1),a(T,{content:n.modelValue?.response?.trace_id,class:`btn-copy inline-block`},null,8,[`content`])])):o(``,!0)]),_:1})])):(g(),s(`div`,Xn,[a(E,{closable:!1,class:`info`},{template:p(()=>[a(C,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(n.$t(`seedance.status.pending`)),1)]),default:p(()=>[e(`p`,Zn,[a(w,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(n.$t(`seedance.name.taskId`))+`: `+i(n.modelValue?.id)+` `,1),a(T,{content:n.modelValue?.id,class:`btn-copy inline-block`},null,8,[`content`])])]),_:1})]))])])}var yr=v({name:`SeedanceRecentPanel`,components:{TaskPreview:G(zn,[[`render`,vr],[`__scopeId`,`data-v-af17440b`]]),BotPlaceholder:De,NoTasks:Ce,ScrollList:Se},props:{loading:{type:Boolean,default:!1}},emits:[`reach-top`],computed:{tasks(){return{...this.$store.state.seedance?.tasks,items:this.$store.state.seedance?.tasks?.items?.slice()}}},methods:{getScrollElement(){return this.$refs.scrollList?.getScrollElement?.()}}}),br={key:0},xr={key:2,class:`w-full h-full flex items-center justify-center`};function Sr(e,t,n,r,i,u){let d=l(`bot-placeholder`),m=l(`task-preview`),_=l(`scroll-list`),v=l(`no-tasks`);return g(),s(c,null,[e.tasks?.items===void 0?(g(),s(`div`,br,[a(d)])):e.tasks?.items?.length&&e.tasks?.items?.length>0?(g(),f(_,{key:1,ref:`scrollList`,class:`tasks w-full h-full overflow-y-auto`,loading:e.loading,onReachTop:t[0]||=t=>e.$emit(`reach-top`)},{default:p(()=>[(g(!0),s(c,null,h(e.tasks?.items,e=>(g(),f(m,{key:e.id,"model-value":e},null,8,[`model-value`]))),128))]),_:1},8,[`loading`])):o(``,!0),e.tasks?.items?.length===0?(g(),s(`div`,xr,[a(v)])):o(``,!0)],64)}var Cr=v({name:`SeedanceIndex`,components:{ConfigPanel:Rn,Layout:Ie,RecentPanel:G(yr,[[`render`,Sr]])},mixins:[_e],inject:[`initialized`],data(){return{task:void 0,job:0,loadingMore:!1,fetchingTasks:!1}},computed:{applicationsLoading(){return this.$store.state.seedance?.status?.getApplications===q.Request},tasksLoading(){return this.$store.state.seedance?.status?.getTasks===q.Request||this.fetchingTasks},credential(){return this.$store.state.seedance?.credential},config(){return this.$store.state.seedance?.config},tasks(){return this.$store.state.seedance?.tasks}},watch:{initialized:{async handler(e){e&&(await this.onGetTasks(),await this.onScrollDown(),this.job=window.setInterval(()=>{this.onGetTasks()},5e3))},immediate:!0}},async mounted(){await this.onGetService()},async unmounted(){window.clearInterval(this.job)},methods:{async onReachTop(){await we({tasks:this.tasks,loading:this.loadingMore,setLoading:e=>this.loadingMore=e,isBlocked:()=>this.tasksLoading||this.applicationsLoading,fetch:e=>this.onGetTasks({createdAtMax:e}),getScrollElement:()=>this.getTasksScrollElement()})},async onGetService(){await this.$store.dispatch(`seedance/getService`)},async onScrollDown(){await this.$nextTick();let e=this.getTasksScrollElement();e&&(e.scrollTop=e.scrollHeight)},async onGetTasks(e){if(this.applicationsLoading||this.fetchingTasks)return;let{limit:t=5,createdAtMin:n,createdAtMax:r}=e||{};this.fetchingTasks=!0;try{await this.$store.dispatch(`seedance/getTasks`,{limit:t,createdAtMin:n,createdAtMax:r})}finally{this.fetchingTasks=!1}},async onGenerate(){if(!be(this.uploadTracker,e=>this.$t(e),e=>J.warning(e)))return;let e={...this.config||{}};if(typeof e?.prompt==`string`&&(e.prompt=e.prompt.trim(),e.prompt||delete e.prompt),Array.isArray(e?.images)){e.images=e.images.filter(e=>!!e?.url);let t=e.images.some(e=>e?.role===`first_frame`),n=e.images.some(e=>e?.role===`last_frame`);!t&&n&&(e.images=e.images.map(e=>e?.role===`last_frame`?{...e,role:`first_frame`}:e))}let t=Array.isArray(e?.images)&&e.images.length>0;if(!t&&`images`in e&&delete e.images,`service_tier`in e&&delete e.service_tier,e?.model&&!fe[e.model]){J.warning(this.$t(`seedance.message.modelUnsupported`));return}let n=B(e?.model);if(n.requiresImage&&!t){J.warning(this.$t(`seedance.message.modelRequiresImage`));return}if(!n.acceptsImage&&t){J.warning(this.$t(`seedance.message.modelRejectsImage`));return}if(!n.acceptsText&&!t){J.warning(this.$t(`seedance.message.modelRequiresImage`));return}!n.acceptsAudio&&e.generate_audio&&(e.generate_audio=!1),!n.acceptsReturnLastFrame&&e.return_last_frame&&(e.return_last_frame=!1),!n.acceptsLastFrame&&t&&(e.images=e.images.filter(e=>e?.role!==`last_frame`)),n.acceptsReferenceAudio&&Array.isArray(e?.audios)&&(e.audios=e.audios.filter(e=>e?.url)),(!n.acceptsReferenceAudio||!Array.isArray(e?.audios)||e.audios.length===0)&&delete e.audios,n.acceptsReferenceVideo&&Array.isArray(e?.videos)&&(e.videos=e.videos.filter(e=>e?.url)),(!n.acceptsReferenceVideo||!Array.isArray(e?.videos)||e.videos.length===0)&&delete e.videos,!n.acceptsReferenceImage&&Array.isArray(e?.images)&&(e.images=e.images.filter(e=>e?.role!==`reference_image`),e.images.length===0&&delete e.images);let r=Array.isArray(e?.images)&&e.images.some(e=>e?.role===`reference_image`);if(Array.isArray(e?.audios)&&e.audios.length>0&&!r){J.warning(this.$t(`seedance.message.audioRequiresReferenceImage`));return}let i={...e,async:!0};if(!he())return;let a=this.credential?.token;if(!a){console.error(`no token specified`);return}J.info(this.$t(`seedance.message.startingTask`)),ye(`seedance`,ge.generate(i,{token:a})).then(()=>{J.success(this.$t(`seedance.message.startTaskSuccess`))}).catch(e=>{let t=e?.response?.data;t?.error?.code===`used_up`?J.error(this.$t(`seedance.message.usedUp`)):J.error(this.$t(`seedance.message.startTaskFailed`)+(t?.error?.message||``))}).finally(async()=>{setTimeout(async()=>{await this.onGetTasks(),await this.onScrollDown()},1e3)})},getTasksScrollElement(){return this.$refs.recentPanel?.getScrollElement?.()}}});function wr(e,t,n,r,i,o){let s=l(`config-panel`),c=l(`recent-panel`),u=l(`layout`);return g(),f(u,null,{config:p(()=>[a(s,{onGenerate:e.onGenerate},null,8,[`onGenerate`])]),result:p(()=>[a(c,{ref:`recentPanel`,loading:e.loadingMore,onReachTop:e.onReachTop},null,8,[`loading`,`onReachTop`])]),_:1})}var Tr=G(Cr,[[`render`,wr]]);export{Tr as default};
@@ -1 +0,0 @@
1
- import"./rolldown-runtime--c01j_DQ.js";import{A as e,C as t,Gt as n,I as r,Jt as i,L as a,M as o,N as s,T as c,at as l,bt as u,ht as d,it as f,j as p,mt as m,qt as h,rt as g,st as _,tt as v,x as y,z as b}from"./vendor-chart-Dw-P17PN.js";import{W as x}from"./use-deprecated-DjO24JGR.js";import{r as S,t as C}from"./select-CujkF0G4.js";import{n as w,t as T}from"./tabs-sABJZ_9N.js";import{t as E}from"./upload-DWCri-Uo.js";import{t as D}from"./tooltip-bADrpFDW.js";import{t as O}from"./alert-BZ-RGZ19.js";import{n as k,r as A}from"./radio-B0Elgaw9.js";import{t as j}from"./drawer-6sGdi_7c.js";import{n as M,t as N}from"./dropdown-BXFl7YRh.js";import{t as P}from"./input-number-Dm870X3x.js";import{t as F}from"./slider-c_kWhhvW.js";import{t as I}from"./switch-LdkfosbU.js";import{t as L}from"./arrow-down-B8oqyNKL.js";import{t as R}from"./arrow-left-DkUuliWv.js";import{t as ee}from"./arrow-right-CArIUigG.js";import{t as z}from"./arrow-up-Bbc8SJs3.js";import{n as te}from"./taskDrawerMixin-DhokI8By.js";import{t as B}from"./check-DV4FkQrg.js";import{t as ne}from"./chevron-down-W3k5n0Ah.js";import{t as re}from"./clock-DL3k6CTu.js";import{t as ie}from"./CopyToClipboard-CukvJo1c.js";import{t as ae}from"./gauge-3dRZbe6H.js";import{t as oe}from"./hash-4hvW7H7n.js";import{t as se}from"./image-9JTbfhGo.js";import{t as ce}from"./info-BDWHCUui.js";import{t as le}from"./PromptTextarea-rU0VxEPx.js";import{t as ue}from"./refresh-cw-BDmEed8N.js";import{t as V}from"./upload-kpQsoant.js";import{t as de}from"./wand-sparkles-DMPZy37T.js";import{t as H}from"./zap-BAa7yw1K.js";import{Ci as fe,wi as pe}from"./constants-dJ4RJksK.js";import{$t as U,Ai as W,Bt as G,E as K,Ht as q,Jr as me,Oi as he,Vt as ge,Wt as _e,Yr as ve,ei as ye,gi as J,mi as be,mr as Y,qr as X,ri as Z,tr as xe,xi as Se,yi as Ce,zt as we}from"./index-HueVnEkS.js";import{t as Q}from"./ImagePreview-C_v2JWDj.js";import{t as Te}from"./Consumption-C9BeeUKY.js";import{a as $,n as Ee,r as De,t as Oe}from"./pagination-Ch3ZD0YU.js";import{t as ke}from"./VideoPlayer-Mi5BhTJB.js";import{t as Ae}from"./ApiCodeButton-B5bcZfdh.js";import{t as je}from"./BotPlaceholder-DrrclSPW.js";import{t as Me}from"./ImageWrapper-B_bAW57k.js";var Ne=be(`coffee`,[[`path`,{d:`M10 2v2`,key:`7u0qdc`}],[`path`,{d:`M14 2v2`,key:`6buw04`}],[`path`,{d:`M16 8a1 1 0 0 1 1 1v8a4 4 0 0 1-4 4H7a4 4 0 0 1-4-4V9a1 1 0 0 1 1-1h14a4 4 0 1 1 0 8h-1`,key:`pwadti`}],[`path`,{d:`M6 2v2`,key:`colzsn`}]]),Pe=b({name:`LayoutMidjourney`,components:{MagicIcon:de,ElDrawer:j,ElButton:W},mixins:[te]}),Fe={class:`main flex-1 h-full flex flex-row`},Ie={class:`config w-[320px] flex-none h-full min-h-0 overflow-hidden flex flex-col bg-[var(--app-sidebar-bg)] border-r border-[var(--app-border-subtle)]`},Le={class:`results flex-1 h-full flex flex-col min-w-0 overflow-x-hidden bg-[var(--app-content-bg)]`};function Re(t,n,r,i,o,c){let u=l(`magic-icon`),p=l(`el-button`),h=l(`el-drawer`);return v(),s(`div`,Fe,[e(`div`,Ie,[f(t.$slots,`config`,{},void 0,!0)]),e(`div`,Le,[f(t.$slots,`results`,{},void 0,!0)]),d(a(p,{circle:``,class:`menu`,"aria-label":t.$t(`common.button.openMenu`),title:t.$t(`common.button.openMenu`),onClick:n[0]||=e=>t.drawer=!0},{default:m(()=>[a(u,{size:`1em`,"aria-hidden":`true`,focusable:`false`})]),_:1},8,[`aria-label`,`title`]),[[y,!t.tasksEmpty]]),a(h,{modelValue:t.drawer,"onUpdate:modelValue":n[1]||=e=>t.drawer=e,direction:`ltr`,"with-header":!1,size:`340px`,class:`drawer generator-drawer`},{default:m(()=>[f(t.$slots,`config`,{},void 0,!0)]),_:3},8,[`modelValue`])])}var ze=K(Pe,[[`render`,Re],[`__scopeId`,`data-v-fa528a88`]]),Be=b({name:`RatioSelector`,data(){return{options:[{value:`1:1`,label:`1:1`,width:20,height:20},{value:`4:3`,label:`4:3`,width:20,height:15},{value:`3:4`,label:`3:4`,width:15,height:20},{value:`16:9`,label:`16:9`,width:25,height:13},{value:`9:16`,label:`9:16`,width:13,height:25}]}},computed:{active(){return this.options.findIndex(e=>e.value===this.value)||0},value:{get(){return this.$store.state.midjourney.config.ratio},set(e){console.debug(`set ratio`,e),this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,ratio:e})}}},mounted(){this.value||=`1:1`}}),Ve={class:`text-sm font-bold mb-2 block`},He={class:`items`},Ue=[`onClick`],We={class:`name`};function Ge(t,r,a,o,l,u){return v(),s(`div`,null,[e(`span`,Ve,i(t.$t(`midjourney.name.ratio`)),1),e(`div`,He,[(v(!0),s(c,null,g(t.options,(r,a)=>(v(),s(`div`,{key:a,class:n({active:t.active===a,item:!0}),onClick:e=>t.value=r.value},[e(`div`,{class:n([`preview`,r.label])},[e(`div`,{class:`rect`,style:h({width:r.width+`px`,height:r.height+`px`})},null,4)],2),e(`p`,We,i(r.label),1)],10,Ue))),128))])])}var Ke=K(Be,[[`render`,Ge],[`__scopeId`,`data-v-b1114c34`]]),qe=!1,Je=b({name:`AdvancedSelector`,components:{ElSwitch:I},computed:{value:{get(){return this.$store.state.midjourney.config.advanced},set(e){console.debug(`set advanced`,e),this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,advanced:e})}}},mounted(){this.value===void 0&&(this.value=qe)}}),Ye={class:`field`},Xe={class:`title`};function Ze(t,n,r,o,c,u){let d=l(`el-switch`);return v(),s(`div`,Ye,[e(`h2`,Xe,i(t.$t(`midjourney.name.advanced`)),1),a(d,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,class:`value`},null,8,[`modelValue`])])}var Qe=K(Je,[[`render`,Ze],[`__scopeId`,`data-v-2d55fce2`]]),$e=b({name:`LoopSelector`,components:{ElSwitch:I,InfoIcon:$},computed:{value:{get(){return this.$store.state.midjourney?.config?.loop},set(e){console.debug(`set loop`,e),this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney?.config,loop:e})}}},mounted(){this.value===void 0&&(this.value=!1)}}),et={class:`relative`},tt={class:`flex justify-between`},nt={class:`flex justify-start items-center`},rt={class:`text-sm font-bold`},it={class:`flex justify-end items-center`};function at(t,n,r,o,c,u){let d=l(`info-icon`),f=l(`el-switch`);return v(),s(`div`,et,[e(`div`,tt,[e(`div`,nt,[e(`span`,rt,i(t.$t(`midjourney.name.loop`)),1),a(d,{content:t.$t(`midjourney.description.loop`)},null,8,[`content`])]),e(`div`,it,[a(f,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,class:`value`},null,8,[`modelValue`])])])])}var ot=K($e,[[`render`,at]]),st=`8.1`,ct=b({name:`VersionSelector`,components:{ElSelect:S,ElOption:C},props:{modelValue:{type:String,default:void 0}},emits:[`update:modelValue`],data(){return{options:[{value:`8.1`,label:`8.1`},{value:`8`,label:`8`},{value:`7`,label:`7`},{value:`6.1`,label:`6.1`},{value:`6.0`,label:`6.0`},{value:`5.2`,label:`5.2`},{value:`5.1`,label:`5.1`},{value:`5.0`,label:`5`},{value:`4`,label:`4`},{value:`3`,label:`3`},{value:`2`,label:`2`},{value:`1`,label:`1`}]}},computed:{value:{get(){return this.$store.state.midjourney.config.version},set(e){this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,version:e})}}},mounted(){this.value||=st}}),lt={class:`field`},ut={class:`text-sm font-bold`};function dt(t,n,r,o,u,d){let f=l(`el-option`),h=l(`el-select`);return v(),s(`div`,lt,[e(`span`,ut,i(t.$t(`midjourney.name.version`)),1),a(h,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,class:`value`,placeholder:t.$t(`midjourney.placeholder.select`)},{default:m(()=>[(v(!0),s(c,null,g(t.options,e=>(v(),p(f,{key:e.value,label:e.label,value:e.value},null,8,[`label`,`value`]))),128))]),_:1},8,[`modelValue`,`placeholder`])])}var ft=K(ct,[[`render`,dt],[`__scopeId`,`data-v-8e00777d`]]),pt=b({name:`HdSelector`,components:{InfoIcon:ce,ElSwitch:I,ElTooltip:D},computed:{value:{get(){return this.$store.state.midjourney.config.hd||!1},set(e){this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,hd:e})}}}}),mt={class:`field`},ht={class:`text-sm font-bold`};function gt(t,n,o,c,u,d){let f=l(`info-icon`),p=l(`el-tooltip`),h=l(`el-switch`);return v(),s(`div`,mt,[e(`span`,ht,[r(i(t.$t(`midjourney.name.hd`))+` `,1),a(p,{content:t.$t(`midjourney.description.hd`),placement:`top`},{default:m(()=>[a(f,{class:`info-icon`,size:`1em`,"aria-hidden":`true`,focusable:`false`})]),_:1},8,[`content`])]),a(h,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e},null,8,[`modelValue`])])}var _t=K(pt,[[`render`,gt],[`__scopeId`,`data-v-a97b008b`]]),vt=b({name:`ReferenceImage`,components:{UploadIcon:V,ElUpload:E,ElButton:W,InfoIcon:$,ImagePreview:Q},mixins:[q,G],emits:[`change`],data(){return{fileList:[],uploadUrl:Z()+`/api/v1/files/`}},computed:{headers(){return{Authorization:`Bearer ${this.$store.state.token.access}`}},urls(){return this.fileList.map(e=>e?.response?.file_url)}},watch:{urls:{handler(e){console.debug(`URLs changed:`,e),this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,image_url:e[0]})}}},methods:{onExceed(){J.warning(this.$t(`midjourney.message.uploadStartImageExceed`))},onError(){J.error(this.$t(`midjourney.message.uploadStartImageError`))}}}),yt={class:`relative`},bt={class:`flex min-h-8 items-center pr-20`},xt={class:`flex justify-start items-center`},St={class:`text-sm font-bold`};function Ct(t,n,o,c,u,d){let f=l(`info-icon`),p=l(`image-preview`),h=l(`upload-icon`),g=l(`el-button`),_=l(`el-upload`);return v(),s(`div`,yt,[e(`div`,bt,[e(`div`,xt,[e(`span`,St,[r(i(t.$t(`midjourney.name.imageUrl`))+` `,1),n[1]||=e(`span`,{class:`text-red-500`,"aria-hidden":`true`},`*`,-1)]),a(f,{content:t.$t(`midjourney.description.imageUrl`)},null,8,[`content`])])]),a(_,{ref:`uploader`,"file-list":t.fileList,"onUpdate:fileList":n[0]||=e=>t.fileList=e,name:`file`,limit:5,class:`upload-wrapper`,accept:`.png,.jpg,.jpeg,.gif,.bmp,.webp`,multiple:!0,"list-type":`picture`,action:t.uploadUrl,"on-exceed":t.onExceed,"on-error":t.onError,headers:t.headers},{file:m(({file:e})=>[a(p,{url:e.url||e.response?.file_url,name:e.name,percentage:e.percentage,onRemove:n=>t.fileList.splice(t.fileList.indexOf(e),1)},null,8,[`url`,`name`,`percentage`,`onRemove`])]),default:m(()=>[a(g,{round:``,type:`primary`,size:`small`,class:`btn btn-upload`},{default:m(()=>[a(h,{class:`icon mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(t.$t(`midjourney.button.uploadImageUrl`)),1)]),_:1})]),_:1},8,[`file-list`,`action`,`on-exceed`,`on-error`,`headers`])])}var wt=K(vt,[[`render`,Ct],[`__scopeId`,`data-v-6fc3a3d5`]]),Tt=b({name:`EndImageUrlInput`,components:{UploadIcon:V,ElUpload:E,ElButton:W,InfoIcon:$,ImagePreview:Q},mixins:[q,G],emits:[`change`],data(){return{fileList:[],uploadUrl:Z()+`/api/v1/files/`}},computed:{headers(){return{Authorization:`Bearer ${this.$store.state.token.access}`}},urls(){return this.fileList.map(e=>e?.response?.file_url)}},watch:{urls:{handler(e){console.debug(`URLs changed:`,e),this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,end_image_url:e[0]})}}},methods:{onExceed(){J.warning(this.$t(`midjourney.message.uploadStartImageExceed`))},onError(){J.error(this.$t(`midjourney.message.uploadEndImageError`))}}}),Et={class:`relative`},Dt={class:`flex min-h-8 items-center pr-20`},Ot={class:`flex justify-start items-center`},kt={class:`text-sm font-bold`};function At(t,n,o,c,u,d){let f=l(`info-icon`),p=l(`image-preview`),h=l(`upload-icon`),g=l(`el-button`),_=l(`el-upload`);return v(),s(`div`,Et,[e(`div`,Dt,[e(`div`,Ot,[e(`span`,kt,i(t.$t(`midjourney.name.endImageUrl`)),1),a(f,{content:t.$t(`midjourney.description.endImageUrl`)},null,8,[`content`])])]),a(_,{ref:`uploader`,"file-list":t.fileList,"onUpdate:fileList":n[0]||=e=>t.fileList=e,name:`file`,limit:5,class:`upload-wrapper`,accept:`.png,.jpg,.jpeg,.gif,.bmp,.webp`,multiple:!0,"list-type":`picture`,action:t.uploadUrl,"on-exceed":t.onExceed,"on-error":t.onError,headers:t.headers},{file:m(({file:e})=>[a(p,{url:e.url||e.response?.file_url,name:e.name,percentage:e.percentage,onRemove:n=>t.fileList.splice(t.fileList.indexOf(e),1)},null,8,[`url`,`name`,`percentage`,`onRemove`])]),default:m(()=>[a(g,{round:``,type:`primary`,size:`small`,class:`btn btn-upload`},{default:m(()=>[a(h,{class:`icon mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(t.$t(`midjourney.button.uploadImageUrl`)),1)]),_:1})]),_:1},8,[`file-list`,`action`,`on-exceed`,`on-error`,`headers`])])}var jt=K(Tt,[[`render`,At],[`__scopeId`,`data-v-86166ccd`]]),Mt=b({name:`ReferenceImage`,components:{UploadIcon:V,ElUpload:E,ElButton:W,InfoIcon:$,ImagePreview:Q},mixins:[q,G],emits:[`change`],data(){return{fileList:[],uploadUrl:Z()+`/api/v1/files/`}},computed:{headers(){return{Authorization:`Bearer ${this.$store.state.token.access}`}},urls(){return this.fileList.map(e=>e?.response?.file_url)}},watch:{urls:{handler(e){console.debug(`URLs changed:`,e),this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,image_url:e[0]})}}},methods:{onExceed(){J.warning(this.$t(`midjourney.message.uploadStartImageExceed`))},onError(){J.error(this.$t(`midjourney.message.uploadStartImageError`))}}}),Nt={class:`relative`},Pt={class:`flex min-h-8 items-center pr-20`},Ft={class:`flex justify-start items-center`},It={class:`text-sm font-bold`};function Lt(t,n,o,c,u,d){let f=l(`info-icon`),p=l(`image-preview`),h=l(`upload-icon`),g=l(`el-button`),_=l(`el-upload`);return v(),s(`div`,Nt,[e(`div`,Pt,[e(`div`,Ft,[e(`span`,It,i(t.$t(`midjourney.name.imageUrl2`)),1),a(f,{content:t.$t(`midjourney.description.imageUrl2`)},null,8,[`content`])])]),a(_,{ref:`uploader`,"file-list":t.fileList,"onUpdate:fileList":n[0]||=e=>t.fileList=e,name:`file`,limit:5,class:`upload-wrapper`,accept:`.png,.jpg,.jpeg,.gif,.bmp,.webp`,multiple:!0,"list-type":`picture`,action:t.uploadUrl,"on-exceed":t.onExceed,"on-error":t.onError,headers:t.headers},{file:m(({file:e})=>[a(p,{url:e.url||e.response?.file_url,name:e.name,percentage:e.percentage,onRemove:n=>t.fileList.splice(t.fileList.indexOf(e),1)},null,8,[`url`,`name`,`percentage`,`onRemove`])]),default:m(()=>[a(g,{round:``,type:`primary`,size:`small`,class:`btn btn-upload`},{default:m(()=>[a(h,{class:`icon mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(t.$t(`midjourney.button.uploadImageUrl`)),1)]),_:1})]),_:1},8,[`file-list`,`action`,`on-exceed`,`on-error`,`headers`])])}var Rt=K(Mt,[[`render`,Lt],[`__scopeId`,`data-v-1b7d8584`]]),zt=b({name:`StylizeSelector`,components:{ElSlider:F,InfoIcon:$,ElInputNumber:P},computed:{value:{get(){return this.$store.state.midjourney.config.stylize},set(e){console.debug(`set stylize`,e),this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,stylize:e})}}},mounted(){this.value||=100}}),Bt={class:`flex justify-between`},Vt={class:`flex justify-start items-center`},Ht={class:`text-sm font-bold`},Ut={class:`flex justify-end items-center`},Wt={class:`w-full px-2`};function Gt(t,n,r,o,c,u){let d=l(`info-icon`),f=l(`el-input-number`),p=l(`el-slider`);return v(),s(`div`,null,[e(`div`,Bt,[e(`div`,Vt,[e(`span`,Ht,i(t.$t(`midjourney.name.stylize`)),1),a(d,{content:t.$t(`midjourney.description.stylize`)},null,8,[`content`])]),e(`div`,Ut,[a(f,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,"controls-position":`right`},null,8,[`modelValue`])])]),e(`div`,Wt,[a(p,{modelValue:t.value,"onUpdate:modelValue":n[1]||=e=>t.value=e,min:0,max:100,step:1},null,8,[`modelValue`])])])}var Kt=K(zt,[[`render`,Gt]]),qt=0,Jt=b({name:`ChaosSelector`,components:{ElSlider:F,InfoIcon:$,ElInputNumber:P},computed:{value:{get(){return this.$store.state.midjourney.config.chaos},set(e){console.debug(`set quality`,e),this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,chaos:e})}}},mounted(){this.value||=qt}}),Yt={class:`flex justify-between`},Xt={class:`flex justify-start items-center`},Zt={class:`text-sm font-bold`},Qt={class:`flex justify-end items-center`},$t={class:`w-full px-2`};function en(t,n,r,o,c,u){let d=l(`info-icon`),f=l(`el-input-number`),p=l(`el-slider`);return v(),s(`div`,null,[e(`div`,Yt,[e(`div`,Xt,[e(`span`,Zt,i(t.$t(`midjourney.name.chaos`)),1),a(d,{content:t.$t(`midjourney.description.chaos`)},null,8,[`content`])]),e(`div`,Qt,[a(f,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,"controls-position":`right`},null,8,[`modelValue`])])]),e(`div`,$t,[a(p,{modelValue:t.value,"onUpdate:modelValue":n[1]||=e=>t.value=e,min:0,max:100,step:1},null,8,[`modelValue`])])])}var tn=K(Jt,[[`render`,en],[`__scopeId`,`data-v-ed158765`]]),nn=b({name:`ModelSelector`,components:{ElImage:Ce,InfoIcon:$},data(){return{options:[{value:``,label:this.$t(`midjourney.model.general`),image:`https://cdn.acedata.cloud/ebvlwg.png`},{value:`niji 5`,label:this.$t(`midjourney.model.niji`),image:`https://cdn.acedata.cloud/j6v1m7.png`}]}},computed:{active(){return this.options.findIndex(e=>e.value===this.value)},value:{get(){return this.$store.state.midjourney.config.model},set(e){this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,model:e})}}},mounted(){this.value===void 0&&(this.value=``)}}),rn={class:`flex justify-start items-center`},an={class:`text-sm font-bold`},on={class:`items`},sn=[`onClick`],cn={class:`name`};function ln(t,r,o,u,d,f){let p=l(`info-icon`),m=l(`el-image`);return v(),s(`div`,null,[e(`div`,rn,[e(`span`,an,i(t.$t(`midjourney.name.model`)),1),a(p,{content:t.$t(`midjourney.description.model`)},null,8,[`content`])]),e(`div`,on,[(v(!0),s(c,null,g(t.options,(r,o)=>(v(),s(`div`,{key:o,class:n({active:t.active===o,item:!0}),onClick:e=>t.value=r.value},[a(m,{src:r.image,fit:`cover`,class:`image`},null,8,[`src`]),e(`p`,cn,i(r.label),1)],10,sn))),128))])])}var un=K(nn,[[`render`,ln],[`__scopeId`,`data-v-ebc6758e`]]),dn=b({name:`QualitySelector`,components:{ElRadioButton:k,ElRadioGroup:A},computed:{version(){return this.$store.state.midjourney.config.version||``},isV8(){return this.version===`8`||this.version===`8.1`},options(){return this.isV8?[{label:this.$t(`midjourney.button.standard`),value:`1`},{label:this.$t(`midjourney.button.ultra`),value:`4`}]:[{label:this.$t(`midjourney.button.low`),value:`.25`},{label:this.$t(`midjourney.button.medium`),value:`.5`},{label:this.$t(`midjourney.button.high`),value:`1`}]},value:{get(){return this.$store.state.midjourney.config.quality},set(e){this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,quality:e})}}},watch:{isV8(e){(e&&this.value!==`1`&&this.value!==`4`||!e&&this.value===`4`)&&(this.value=`1`)}},mounted(){this.value||=`1`}}),fn={class:`field`},pn={class:`text-sm font-bold`};function mn(t,n,o,u,d,f){let h=l(`el-radio-button`),_=l(`el-radio-group`);return v(),s(`div`,fn,[e(`span`,pn,i(t.$t(`midjourney.name.quality`)),1),a(_,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,class:`quality`},{default:m(()=>[(v(!0),s(c,null,g(t.options,e=>(v(),p(h,{key:e.value,label:e.value},{default:m(()=>[r(i(e.label),1)]),_:2},1032,[`label`]))),128))]),_:1},8,[`modelValue`])])}var hn=K(dn,[[`render`,mn],[`__scopeId`,`data-v-10b2574d`]]),gn=b({name:`ResolutionSelector`,components:{ElSelect:S,ElOption:C},props:{modelValue:{type:String,default:void 0}},emits:[`update:modelValue`],data(){return{options:[{value:`480p`,label:`480p`},{value:`720p`,label:`720p`}]}},computed:{value:{get(){return this.$store.state.midjourney?.config?.resolution},set(e){this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,resolution:e})}}},mounted(){this.value||=fe}}),_n={class:`field`},vn={class:`title font-bold`};function yn(t,n,r,o,u,d){let f=l(`el-option`),h=l(`el-select`);return v(),s(`div`,_n,[e(`h2`,vn,i(t.$t(`midjourney.name.resolution`)),1),a(h,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,class:`value`,placeholder:t.$t(`midjourney.placeholder.select`)},{default:m(()=>[(v(!0),s(c,null,g(t.options,e=>(v(),p(f,{key:e.value,label:e.label,value:e.value},null,8,[`label`,`value`]))),128))]),_:1},8,[`modelValue`,`placeholder`])])}var bn=K(gn,[[`render`,yn],[`__scopeId`,`data-v-12537f29`]]),xn=b({name:`ImageWeightSelector`,components:{ElSlider:F,InfoIcon:$},computed:{value:{get(){return this.$store.state.midjourney.config.iw},set(e){console.debug(`set iw`,e),this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,iw:e})}}},mounted(){this.value||=1}}),Sn={class:`flex justify-between`},Cn={class:`flex justify-start items-center`},wn={class:`text-sm font-bold`},Tn={class:`flex justify-end items-center`},En={class:`w-full px-2`};function Dn(t,n,r,o,c,u){let d=l(`info-icon`),f=l(`el-input-number`),p=l(`el-slider`);return v(),s(`div`,null,[e(`div`,Sn,[e(`div`,Cn,[e(`span`,wn,i(t.$t(`midjourney.name.imageWeight`)),1),a(d,{content:t.$t(`midjourney.description.imageWeight`)},null,8,[`content`])]),e(`div`,Tn,[a(f,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,"controls-position":`right`},null,8,[`modelValue`])])]),e(`div`,En,[a(p,{modelValue:t.value,"onUpdate:modelValue":n[1]||=e=>t.value=e,min:0,max:2,step:.1},null,8,[`modelValue`])])])}var On=K(xn,[[`render`,Dn],[`__scopeId`,`data-v-b4bf1f1e`]]),kn=b({name:`WeirdSelector`,components:{ElSlider:F,ElInputNumber:P,InfoIcon:$},computed:{value:{get(){return this.$store.state.midjourney.config.weird},set(e){this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,weird:e})}}},mounted(){this.value||=0}}),An={class:`flex justify-between`},jn={class:`flex justify-start items-center`},Mn={class:`text-sm font-bold`},Nn={class:`flex justify-end items-center`},Pn={class:`w-full px-2`};function Fn(t,n,r,o,c,u){let d=l(`info-icon`),f=l(`el-input-number`),p=l(`el-slider`);return v(),s(`div`,null,[e(`div`,An,[e(`div`,jn,[e(`span`,Mn,i(t.$t(`midjourney.name.weird`)),1),a(d,{content:t.$t(`midjourney.description.weird`)},null,8,[`content`])]),e(`div`,Nn,[a(f,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,"controls-position":`right`},null,8,[`modelValue`])])]),e(`div`,Pn,[a(p,{modelValue:t.value,"onUpdate:modelValue":n[1]||=e=>t.value=e,min:0,max:1e3,step:1},null,8,[`modelValue`])])])}var In=K(kn,[[`render`,Fn]]),Ln=b({name:`VideoFromInput`,components:{VideoPlayer:ke},props:{modelValue:{type:Object,required:!1,default:void 0}},data(){return{options:{controls:[`play-large`,`play`,`progress`,`current-time`,`mute`,`captions`,`settings`,`fullscreen`]}}},computed:{config(){return this.$store.state.midjourney?.config}}}),Rn={class:`relative`},zn={class:`flex mb-2`},Bn={class:`text-sm font-bold`};function Vn(t,n,r,a,c,u){let d=l(`video-player`);return v(),s(`div`,Rn,[e(`div`,zn,[e(`span`,Bn,i(t.$t(`midjourney.name.extend`)),1)]),e(`div`,null,[t.config?.video_url?(v(),p(d,{key:0,src:t.config?.video_url,options:t.options},null,8,[`src`,`options`])):o(``,!0)])])}var Hn=K(Ln,[[`render`,Vn]]),Un=``,Wn=b({name:`StyleSelector`,components:{ElSelect:S,ElOption:C},data(){return{}},computed:{model(){return this.$store.state.midjourney.config.model},options(){return this.model?.includes(`niji`)?[{value:`cute`,label:this.$t(`midjourney.style.cute`)},{value:`expressive`,label:this.$t(`midjourney.style.expressive`)},{value:`scenic`,label:this.$t(`midjourney.style.scenic`)},{value:`original`,label:this.$t(`midjourney.style.original`)}]:[{value:`raw`,label:this.$t(`midjourney.style.raw`)}]},value:{get(){return this.$store.state.midjourney.config.style},set(e){this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,style:e})}}},watch:{model(){this.value=``}},mounted(){this.value||=Un}}),Gn={class:`field`},Kn={class:`text-sm font-bold title`},qn={class:`float-left`},Jn={class:`float-right`};function Yn(t,n,r,o,u,d){let f=l(`el-option`),h=l(`el-select`);return v(),s(`div`,Gn,[e(`span`,Kn,i(t.$t(`midjourney.name.style`)),1),a(h,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,class:`value`,placeholder:t.$t(`midjourney.placeholder.select`),clearable:``},{default:m(()=>[(v(!0),s(c,null,g(t.options,t=>(v(),p(f,{key:t.value,label:t.label,value:t.value},{default:m(()=>[e(`span`,qn,i(t.label),1),e(`span`,Jn,i(t.value),1)]),_:2},1032,[`label`,`value`]))),128))]),_:1},8,[`modelValue`,`placeholder`])])}var Xn=K(Wn,[[`render`,Yn],[`__scopeId`,`data-v-00d50831`]]),Zn=b({name:`ElementsSelector`,components:{Check:B,ElTabs:w,ElTag:he,ElIcon:x,ElTabPane:T,ElImage:Ce,ElDialog:Se,ElButton:W,InfoIcon:$},emits:[`update:modelValue`],data(){return{tab:`styles`,choosing:!1,elements:{styles:{displayName:this.$t(`midjourney.styleCategory.styles`),items:[{image:`https://cdn.acedata.cloud/94ab394d-2fa3-4fe8-b3b3-41be85720fdb.png`,label:this.$t(`midjourney.styleTag.watercolour`),value:`Watercolour`},{image:`https://cdn.acedata.cloud/c3904cc5-3184-4639-be76-46f4860c1277.png`,label:this.$t(`midjourney.styleTag.oilPainting`),value:`Oil painting`},{image:`https://cdn.acedata.cloud/a0b764bb-13b1-419b-a8e8-855ee7ffc28a.png`,label:this.$t(`midjourney.styleTag.oldPhotograph`),value:`Old Photograph`},{image:`https://cdn.acedata.cloud/04f17d89-d913-4700-a422-99fa97fa79c9.png`,label:this.$t(`midjourney.styleTag.oneLineDrawing`),value:`One-line drawing`},{image:`https://cdn.acedata.cloud/281cfaac-ec59-4f5c-ab2b-f15d7481d752.png`,label:this.$t(`midjourney.styleTag.sketchDrawing`),value:`Sketch Drawing`},{image:`https://cdn.acedata.cloud/091d68cf-533c-4b76-90be-d5983b9ba80b.png`,label:this.$t(`midjourney.styleTag.gouache`),value:`Gouache`},{image:`https://cdn.acedata.cloud/a652c6b2-f0f6-4ef4-bf1b-9053e1daf85b.png`,label:this.$t(`midjourney.styleTag.filmStyle`),value:`Film style`},{image:`https://cdn.acedata.cloud/0aaafc79-9094-4a97-a07d-a01f88d276b1.png`,label:this.$t(`midjourney.styleTag.photorealistic`),value:`Photorealistic`},{image:`https://cdn.acedata.cloud/aa6489ad-8b40-46ae-83a6-f636772084e9.png`,label:this.$t(`midjourney.styleTag.logo`),value:`Logo`},{image:`https://cdn.acedata.cloud/e3e96805-6bcd-4608-b012-a8931e75662a.png`,label:this.$t(`midjourney.styleTag.cartoon`),value:`Cartoon`},{image:`https://cdn.acedata.cloud/11d53af4-ec2d-4256-8ddc-18105df57047.png`,label:this.$t(`midjourney.styleTag.marbleStatue`),value:`Marble Statue`},{image:`https://cdn.acedata.cloud/d0109889-d2a6-49ee-9f5c-49f2033966d8.png`,label:this.$t(`midjourney.styleTag.1800S`),value:`1800s`},{image:`https://cdn.acedata.cloud/86a3fb48-1ef0-422a-809a-580892aa0b9d.png`,label:this.$t(`midjourney.styleTag.1980S`),value:`1980s`},{image:`https://cdn.acedata.cloud/8b07aae4-b6f6-45ad-a556-7206b2945025.png`,label:this.$t(`midjourney.styleTag.isometricAnime`),value:`Isometric anime`,advanced:!0},{image:`https://cdn.acedata.cloud/3be49d3c-e431-4bce-b2bb-fc53f763b348.png`,label:this.$t(`midjourney.styleTag.analyticDrawing`),value:`Analytic drawing`,advanced:!0},{image:`https://cdn.acedata.cloud/4d31c2dc-2a0b-4465-b3e8-bffd7c5fed25.png`,label:this.$t(`midjourney.styleTag.coloringBook`),value:`Coloring book`,advanced:!0},{image:`https://cdn.acedata.cloud/a19dde67-65b2-4923-8895-9e960cf050ee.png`,label:this.$t(`midjourney.styleTag.infographicDrawing`),value:`Infographic drawing`,advanced:!0},{image:`https://cdn.acedata.cloud/f57db729-8692-4524-a373-b495d14ec77e.png`,label:this.$t(`midjourney.styleTag.doubleExposure`),value:`Double exposure`,advanced:!0},{image:`https://cdn.acedata.cloud/f8ff8db0-62dc-4414-b309-7fdf2021e45c.png`,label:this.$t(`midjourney.styleTag.diagrammaticDrawing`),value:`Diagrammatic drawing`,advanced:!0},{image:`https://cdn.acedata.cloud/426447cf-dd10-4c91-b928-e7a3aa4c253a.png`,label:this.$t(`midjourney.styleTag.2DIllustration`),value:`2D illustration`,advanced:!0},{image:`https://cdn.acedata.cloud/25e0edfe-776f-4be0-9791-bb729cca81b3.png`,label:this.$t(`midjourney.styleTag.diagrammaticPortrait`),value:`Diagrammatic portrait`,advanced:!0},{image:`https://cdn.acedata.cloud/819c367c-ad03-4bf8-87a9-38ba53aa00f6.png`,label:this.$t(`midjourney.styleTag.pixelArt`),value:`Pixel art`,advanced:!0},{image:`https://cdn.acedata.cloud/2c4bbd7b-fc59-4f38-b844-762bf2366042.png`,label:this.$t(`midjourney.styleTag.darkFantasy`),value:`Dark fantasy`,advanced:!0},{image:`https://cdn.acedata.cloud/bd786eed-e3ee-4e3a-9473-acbd1ee4306c.png`,label:this.$t(`midjourney.styleTag.ukiyoEArt`),value:`Ukiyo-e art`,advanced:!0},{image:`https://cdn.acedata.cloud/1951d276-5502-428a-8694-1b311d8a5540.png`,label:this.$t(`midjourney.styleTag.paperQuilling`),value:`Paper quilling`,advanced:!0},{image:`https://cdn.acedata.cloud/4f9bcc9c-8b0e-47f4-87b9-4b4d78a8891a.png`,label:this.$t(`midjourney.styleTag.paperCutCraft`),value:`Paper cut craft`},{image:`https://cdn.acedata.cloud/4775f61f-446b-4312-b824-c91c6ecdb372.png`,label:this.$t(`midjourney.styleTag.iridescent`),value:`Iridescent`,advanced:!0},{image:`https://cdn.acedata.cloud/29fbc528-56f0-4eb0-a5a2-2312d53d55b4.png`,label:this.$t(`midjourney.styleTag.patchworkCollage`),value:`Patchwork collage`,advanced:!0},{image:`https://cdn.acedata.cloud/aa03b06a-fac8-45ec-830f-2a6e7ecab5c2.png`,label:this.$t(`midjourney.styleTag.opArt`),value:`Op art`,advanced:!0},{image:`https://cdn.acedata.cloud/29015f2a-3c9c-43c5-808a-23fbbb7bcf2f.png`,label:this.$t(`midjourney.styleTag.japaneseInk`),value:`Japanese ink`,advanced:!0},{image:`https://cdn.acedata.cloud/a65f8f7e-46a9-4ccf-8ee5-720d0c222471.png`,label:this.$t(`midjourney.styleTag.pastelDrawing`),value:`Pastel drawing`},{image:`https://cdn.acedata.cloud/a0cda2b1-b227-4230-8842-feab55edd6c7.png`,label:this.$t(`midjourney.styleTag.drippingArt`),value:`Dripping art`},{image:`https://cdn.acedata.cloud/c4aab372-ec55-4a7e-af94-4469f45c23c5.png`,label:this.$t(`midjourney.styleTag.tattooArt`),value:`Tattoo art`,advanced:!0},{image:`https://cdn.acedata.cloud/5040fbb2-6fa7-4e8f-86ac-f23c1c3e291c.png`,label:this.$t(`midjourney.styleTag.16Bit`),value:`16-Bit`,advanced:!0},{image:`https://cdn.acedata.cloud/b67249a1-36fa-443a-8b41-c167a5002e10.png`,label:this.$t(`midjourney.styleTag.8Bit`),value:`8-Bit`,advanced:!0},{image:`https://cdn.acedata.cloud/1c9600b4-6995-4dcb-b363-40ee38049151.png`,label:this.$t(`midjourney.styleTag.amber`),value:`Amber`,advanced:!0},{image:`https://cdn.acedata.cloud/e2d34946-3148-4f92-ad73-40f6f1208516.png`,label:this.$t(`midjourney.styleTag.anatomicalDrawing`),value:`Anatomical Drawing`,advanced:!0},{image:`https://cdn.acedata.cloud/19940f31-037e-4a8f-a71c-605e16ac9631.png`,label:this.$t(`midjourney.styleTag.ancient`),value:`Ancient`},{image:`https://cdn.acedata.cloud/b714b3d9-2f97-49fb-bf85-99a716bf0c78.png`,label:this.$t(`midjourney.styleTag.anime`),value:`Anime`,advanced:!0},{image:`https://cdn.acedata.cloud/d88c3080-cd54-4342-ac91-dac326ee1060.png`,label:this.$t(`midjourney.styleTag.arabic`),value:`Arabic`,advanced:!0},{image:`https://cdn.acedata.cloud/dc54b749-8e69-4252-9b90-fc1448fa9397.png`,label:this.$t(`midjourney.styleTag.blocky`),value:`Blocky`,advanced:!0},{image:`https://cdn.acedata.cloud/d8009295-2f4b-48d8-896e-46d0f5939923.png`,label:this.$t(`midjourney.styleTag.blueprint`),value:`Blueprint`,advanced:!0},{image:`https://cdn.acedata.cloud/5cc39277-16e0-46d6-9310-b0722479713b.png`,label:this.$t(`midjourney.styleTag.comicbook`),value:`Comicbook`,advanced:!0},{image:`https://cdn.acedata.cloud/b9900d01-20bc-408b-9637-779cc22c493c.png`,label:this.$t(`midjourney.styleTag.caribbean`),value:`Caribbean`,advanced:!0},{image:`https://cdn.acedata.cloud/fedabd4e-a9bb-4bb0-a4ec-8fc48bc74c78.png`,label:this.$t(`midjourney.styleTag.celestial`),value:`Celestial`,advanced:!0},{image:`https://cdn.acedata.cloud/00f1f097-1d72-435f-b47d-656f8e194dc2.png`,label:this.$t(`midjourney.styleTag.cellulose`),value:`Cellulose`,advanced:!0},{image:`https://cdn.acedata.cloud/a002bccf-6287-4b28-a5a7-c1cf5cb07734.png`,label:this.$t(`midjourney.styleTag.charcoalStyle`),value:`Charcoal Style`,advanced:!0},{image:`https://cdn.acedata.cloud/e218ab68-e430-4541-9501-02ee2d7aeda9.png`,label:this.$t(`midjourney.styleTag.chromatic`),value:`Chromatic`,advanced:!0},{image:`https://cdn.acedata.cloud/bd5a79d9-c73d-46c3-974f-932751ff8e46.png`,label:this.$t(`midjourney.styleTag.coral`),value:`Coral`,advanced:!0},{image:`https://cdn.acedata.cloud/58dd439c-cae7-434f-9a83-ac6aefd6e417.png`,label:this.$t(`midjourney.styleTag.conceptArt`),value:`Concept Art`,advanced:!0},{image:`https://cdn.acedata.cloud/767fe9f3-69d0-4e16-9060-41e6cf1b1fe1.png`,label:this.$t(`midjourney.styleTag.fibonacci`),value:`Fibonacci`,advanced:!0},{image:`https://cdn.acedata.cloud/4b78ebb1-5091-43d8-a020-88ffb3719edd.png`,label:this.$t(`midjourney.styleTag.cyberpunk`),value:`Cyberpunk`,advanced:!0},{image:`https://cdn.acedata.cloud/34d35d5c-a2e4-4e8e-aafd-3d3c08499389.png`,label:this.$t(`midjourney.styleTag.diabolic`),value:`Diabolic`,advanced:!0},{image:`https://cdn.acedata.cloud/8e29e2b4-4899-491d-a5dc-5ebbb1ff2758.png`,label:this.$t(`midjourney.styleTag.diffractionGrading`),value:`Diffraction Grading`,advanced:!0},{image:`https://cdn.acedata.cloud/996c6d93-94aa-438a-96d5-278e22e54f5f.png`,label:this.$t(`midjourney.styleTag.lightspeed`),value:`Lightspeed`,advanced:!0},{image:`https://cdn.acedata.cloud/57f3ad49-0940-44e2-a31a-a4872497bae7.png`,label:this.$t(`midjourney.styleTag.liquid`),value:`Liquid`,advanced:!0},{image:`https://cdn.acedata.cloud/a9ff43a9-dadf-4bbc-9a7a-72fd3908d39a.png`,label:this.$t(`midjourney.styleTag.dots`),value:`Dots`,advanced:!0},{image:`https://cdn.acedata.cloud/acff2bf9-1907-4a0f-be23-897c71caf60e.png`,label:this.$t(`midjourney.styleTag.dune`),value:`Dune`,advanced:!0},{image:`https://cdn.acedata.cloud/4a2abc45-ba65-4e2d-8399-8d44491c8a64.png`,label:this.$t(`midjourney.styleTag.drippingPaint`),value:`Dripping Paint`,advanced:!0},{image:`https://cdn.acedata.cloud/7dc4e93f-07a8-45ec-9e8a-89c3f619fd40.png`,label:this.$t(`midjourney.styleTag.electronicCircuitry`),value:`Electronic Circuitry`,advanced:!0},{image:`https://cdn.acedata.cloud/cf502cba-ee64-41fd-a388-93f6357fc7cc.png`,label:this.$t(`midjourney.styleTag.electrical`),value:`Electrical`,advanced:!0},{image:`https://cdn.acedata.cloud/fd6a696b-3102-4301-8fce-5a7fd401231a.png`,label:this.$t(`midjourney.styleTag.futuristic`),value:`Futuristic`,advanced:!0},{image:`https://cdn.acedata.cloud/0fe8fca5-b3d9-4fab-b390-fff7c0f4f594.png`,label:this.$t(`midjourney.styleTag.etching`),value:`Etching`,advanced:!0},{image:`https://cdn.acedata.cloud/46577726-f0ab-4750-81c6-0d4d865ba4bd.png`,label:this.$t(`midjourney.styleTag.extraterrestrial`),value:`Extraterrestrial`,advanced:!0},{image:`https://cdn.acedata.cloud/faa06af4-9988-4e39-9f13-ecdd29e1e20a.png`,label:this.$t(`midjourney.styleTag.glitchart`),value:`Glitchart`,advanced:!0},{image:`https://cdn.acedata.cloud/4380f6af-aaeb-41fd-bcaf-2efadcc3e08f.png`,label:this.$t(`midjourney.styleTag.floral`),value:`Floral`,advanced:!0},{image:`https://cdn.acedata.cloud/096683c4-8e91-4ef0-8211-8a6dcef5298d.png`,label:this.$t(`midjourney.styleTag.fractal`),value:`Fractal`,advanced:!0},{image:`https://cdn.acedata.cloud/10ce713b-a5bc-400b-a0c8-bcec4f7e6548.png`,label:this.$t(`midjourney.styleTag.preHistoric`),value:`Pre Historic`,advanced:!0},{image:`https://cdn.acedata.cloud/6382ad4e-1818-4ab1-b493-10afdb43c196.png`,label:this.$t(`midjourney.styleTag.prokaryotic`),value:`Prokaryotic`,advanced:!0},{image:`https://cdn.acedata.cloud/48205fb3-e48b-4219-ad53-d307e1e686a7.png`,label:this.$t(`midjourney.styleTag.horror`),value:`Horror`,advanced:!0},{image:`https://cdn.acedata.cloud/d0567b20-8f93-4b16-a775-8ca0708a7a50.png`,label:this.$t(`midjourney.styleTag.iceAge`),value:`Ice Age`,advanced:!0},{image:`https://cdn.acedata.cloud/cc1455a5-c139-400d-8a54-121176f196e1.png`,label:this.$t(`midjourney.styleTag.jurassic`),value:`Jurassic`,advanced:!0},{image:`https://cdn.acedata.cloud/84e2bfe2-60bb-4323-936b-18dbb1c8cfa1.png`,label:this.$t(`midjourney.styleTag.knitted`),value:`Knitted`,advanced:!0},{image:`https://cdn.acedata.cloud/2e1ffddf-daa1-4e57-bc92-d16484ef8e34.png`,label:this.$t(`midjourney.styleTag.polka`),value:`Polka`,advanced:!0},{image:`https://cdn.acedata.cloud/9c2670df-3e39-45a7-ad76-ae17502d018f.png`,label:this.$t(`midjourney.styleTag.latex`),value:`Latex`,advanced:!0},{image:`https://cdn.acedata.cloud/d4de1735-235d-461d-b93f-2bf3c280ccfe.png`,label:this.$t(`midjourney.styleTag.pastel`),value:`Pastel`,advanced:!0},{image:`https://cdn.acedata.cloud/37f26555-f634-4964-8bac-ec8a955273d4.png`,label:this.$t(`midjourney.styleTag.mandala`),value:`Mandala`,advanced:!0},{image:`https://cdn.acedata.cloud/f62aa376-1378-45a6-abd0-71bc7bbe49c7.png`,label:this.$t(`midjourney.styleTag.molecular`),value:`Molecular`,advanced:!0},{image:`https://cdn.acedata.cloud/fc135428-1835-453d-afef-aaf72a7cfcbc.png`,label:this.$t(`midjourney.styleTag.merkaba`),value:`Merkaba`,advanced:!0},{image:`https://cdn.acedata.cloud/5caf594b-0f0c-455f-b8a8-8c15a189d0dc.png`,label:this.$t(`midjourney.styleTag.mitochondria`),value:`Mitochondria`,advanced:!0},{image:`https://cdn.acedata.cloud/088e3067-0abe-4f3d-bcb8-f6937e860d1e.png`,label:this.$t(`midjourney.styleTag.graffiti`),value:`Graffiti`,advanced:!0},{image:`https://cdn.acedata.cloud/06230561-916a-4bc5-ad85-9386cf27bf1c.png`,label:this.$t(`midjourney.styleTag.graphicNovel`),value:`Graphic Novel`,advanced:!0},{image:`https://cdn.acedata.cloud/e47f7931-d588-4c4a-87c8-3f7137e7f727.png`,label:this.$t(`midjourney.styleTag.multidimensional`),value:`Multidimensional`,advanced:!0},{image:`https://cdn.acedata.cloud/d2443c93-3227-4216-afd1-b86287ac5140.png`,label:this.$t(`midjourney.styleTag.nasa`),value:`NASA`,advanced:!0},{image:`https://cdn.acedata.cloud/a86a2f67-273c-4edf-9be9-ceecc983c93d.png`,label:this.$t(`midjourney.styleTag.nebula`),value:`Nebula`,advanced:!0},{image:`https://cdn.acedata.cloud/ad1e588c-5892-48ee-a7c2-103c2b4868fc.png`,label:this.$t(`midjourney.styleTag.neon`),value:`Neon`},{image:`https://cdn.acedata.cloud/5a133976-208e-460f-8296-a4ad19809490.png`,label:this.$t(`midjourney.styleTag.nuclear`),value:`Nuclear`,advanced:!0},{image:`https://cdn.acedata.cloud/c99f5082-314b-49e9-8875-b40319ed3cfc.png`,label:this.$t(`midjourney.styleTag.orbital`),value:`Orbital`,advanced:!0},{image:`https://cdn.acedata.cloud/63809059-6ae6-49ff-ad96-ed4ae45a2464.png`,label:this.$t(`midjourney.styleTag.rayTracing`),value:`Ray Tracing`,advanced:!0},{image:`https://cdn.acedata.cloud/cdcf0c05-e7ad-421e-b513-640bcc3d04cc.png`,label:this.$t(`midjourney.styleTag.realistic`),value:`Realistic`},{image:`https://cdn.acedata.cloud/019dc7be-b0e2-4da2-94d4-191226d58dbf.png`,label:this.$t(`midjourney.styleTag.renaissance`),value:`Renaissance`,advanced:!0},{image:`https://cdn.acedata.cloud/d46d3c03-a924-4a0f-b032-e8dbca6ad37e.png`,label:this.$t(`midjourney.styleTag.retro`),value:`Retro`},{image:`https://cdn.acedata.cloud/bc13e200-6865-474b-8fe4-cf0725cf3caf.png`,label:this.$t(`midjourney.styleTag.risograph`),value:`Risograph`,advanced:!0},{image:`https://cdn.acedata.cloud/f8533acc-807b-4f03-8f39-338ee6ff5d53.png`,label:this.$t(`midjourney.styleTag.origami`),value:`Origami`,advanced:!0},{image:`https://cdn.acedata.cloud/b0ff3593-aef3-4dd2-a5f4-548c6febb2e2.png`,label:this.$t(`midjourney.styleTag.ornamental`),value:`Ornamental`,advanced:!0},{image:`https://cdn.acedata.cloud/002c6a5d-b251-43bb-b713-d133f828c0a4.png`,label:this.$t(`midjourney.styleTag.space`),value:`Space`,advanced:!0},{image:`https://cdn.acedata.cloud/641327df-93cc-4746-a55e-667dbb8c1563.png`,label:this.$t(`midjourney.styleTag.splatterPaint`),value:`Splatter Paint`,advanced:!0},{image:`https://cdn.acedata.cloud/42527f9e-6cf0-40a6-bc9b-361d2baf9bf9.png`,label:this.$t(`midjourney.styleTag.sprayPaint`),value:`Spray Paint`,advanced:!0},{image:`https://cdn.acedata.cloud/98bf8e01-9dd8-434b-81df-77cfd3627243.png`,label:this.$t(`midjourney.styleTag.squiggles`),value:`Squiggles`,advanced:!0},{image:`https://cdn.acedata.cloud/26868352-5d9a-4bcc-9926-166927a2be35.png`,label:this.$t(`midjourney.styleTag.stitching`),value:`Stitching`,advanced:!0},{image:`https://cdn.acedata.cloud/23819218-bdbc-4746-a507-7664836a4f59.png`,label:this.$t(`midjourney.styleTag.veins`),value:`Veins`,advanced:!0},{image:`https://cdn.acedata.cloud/2fd3de3d-7211-4cce-b63b-a857d7621c72.png`,label:this.$t(`midjourney.styleTag.streetArt`),value:`Street Art`,advanced:!0},{image:`https://cdn.acedata.cloud/80422ede-79fb-4149-bd0a-85bf0ac75a3d.png`,label:this.$t(`midjourney.styleTag.surreal`),value:`Surreal`},{image:`https://cdn.acedata.cloud/94956306-55de-470b-8a2a-28354d0e556f.png`,label:this.$t(`midjourney.styleTag.symmetric`),value:`Symmetric`,advanced:!0},{image:`https://cdn.acedata.cloud/0098f2a0-b089-4e64-8a86-ffa137605087.png`,label:this.$t(`midjourney.styleTag.synthWave`),value:`Synth-wave`,advanced:!0},{image:`https://cdn.acedata.cloud/f50d33b2-9c91-4939-8f2d-7b5ce185d138.png`,label:this.$t(`midjourney.styleTag.technological`),value:`Technological`,advanced:!0},{image:`https://cdn.acedata.cloud/a446a6eb-444c-4073-8a8e-6f43e65491c2.png`,label:this.$t(`midjourney.styleTag.tron`),value:`Tron`,advanced:!0},{image:`https://cdn.acedata.cloud/8026ccad-aa11-4b0d-ad81-eb870a695a81.png`,label:this.$t(`midjourney.styleTag.tropical`),value:`Tropical`,advanced:!0},{image:`https://cdn.acedata.cloud/22c16c64-068c-470e-9b80-2849297aad9a.png`,label:this.$t(`midjourney.styleTag.ultraModern`),value:`Ultra Modern`},{image:`https://cdn.acedata.cloud/f67bd4b6-3f43-4da8-bdcb-67cd39cb38f9.png`,label:this.$t(`midjourney.styleTag.wormhole`),value:`Wormhole`,advanced:!0},{image:`https://cdn.acedata.cloud/2e2a1ca9-8791-41c6-9ff0-0ac21a13d1c5.png`,label:this.$t(`midjourney.styleTag.wrinkled`),value:`Wrinkled`,advanced:!0},{image:`https://cdn.acedata.cloud/3507c78d-a065-462c-a17c-fd5ed4677644.png`,label:this.$t(`midjourney.styleTag.volcanic`),value:`Volcanic`,advanced:!0},{image:`https://cdn.acedata.cloud/69263783-0610-45b0-9ec4-acac961da092.png`,label:this.$t(`midjourney.styleTag.wetPaint`),value:`Wet Paint`,advanced:!0},{image:`https://cdn.acedata.cloud/9022fc82-d6f7-47e2-90b1-ad96fbba5257.png`,label:this.$t(`midjourney.styleTag.wildWest`),value:`Wild West`,advanced:!0},{image:`https://cdn.acedata.cloud/23de882d-4e5d-40b5-9f00-d0573c443212.png`,label:this.$t(`midjourney.styleTag.wind`),value:`Wind`,advanced:!0},{image:`https://cdn.acedata.cloud/e3a58af1-79bc-48f3-871c-36472da2584b.png`,label:this.$t(`midjourney.styleTag.miniatureFaking`),value:`Miniature Faking`,advanced:!0}]},lighting:{displayName:this.$t(`midjourney.styleCategory.lighting`),items:[{image:`https://cdn.acedata.cloud/a4b9110f-e838-4c52-8ab8-f2637ea753df.png`,label:this.$t(`midjourney.styleTag.accentLighting`),value:`Accent Lighting`},{image:`https://cdn.acedata.cloud/c4c16a69-28d7-4b38-8ea2-3ce49d5c6b07.png`,label:this.$t(`midjourney.styleTag.backlight`),value:`Backlight`},{image:`https://cdn.acedata.cloud/7fd2cd5c-7671-4b40-85a0-230de9c37234.png`,label:this.$t(`midjourney.styleTag.blacklight`),value:`Blacklight`,advanced:!0},{image:`https://cdn.acedata.cloud/a08bff6e-8a0f-4d56-aa91-576f0a9921f2.png`,label:this.$t(`midjourney.styleTag.goldenHourLight`),value:`Golden hour light`,advanced:!0},{image:`https://cdn.acedata.cloud/3cd28696-493f-4b3e-9187-9d1a4c17e95b.png`,label:this.$t(`midjourney.styleTag.candlelight`),value:`Candlelight`},{image:`https://cdn.acedata.cloud/58c9a17e-f7d5-4481-abc8-9e9b66609a4d.png`,label:this.$t(`midjourney.styleTag.concertLighting`),value:`Concert Lighting`,advanced:!0},{image:`https://cdn.acedata.cloud/efb8893c-8bd6-4c7d-8e45-6e0626f69479.png`,label:this.$t(`midjourney.styleTag.crepuscularRays`),value:`Crepuscular Rays`,advanced:!0},{image:`https://cdn.acedata.cloud/27b90e83-09b0-4339-9b2c-48fe6fe45bdd.png`,label:this.$t(`midjourney.styleTag.directSunlight`),value:`Direct Sunlight`},{image:`https://cdn.acedata.cloud/d33cb17d-e2a5-4ca3-b68a-93904d2618d7.png`,label:this.$t(`midjourney.styleTag.dust`),value:`Dust`,advanced:!0},{image:`https://cdn.acedata.cloud/3af133d0-5a86-45a9-a16e-f23e6cc68b24.png`,label:this.$t(`midjourney.styleTag.studioLighting`),value:`Studio lighting`,advanced:!0},{image:`https://cdn.acedata.cloud/6bc889b1-a563-4890-9117-7d3ded276caa.png`,label:this.$t(`midjourney.styleTag.rimLight`),value:`Rim light`,advanced:!0},{image:`https://cdn.acedata.cloud/d770265a-066b-413f-a405-a52d68e2f1c7.png`,label:this.$t(`midjourney.styleTag.volumetricLighting`),value:`Volumetric Lighting`,advanced:!0},{image:`https://cdn.acedata.cloud/7c83560a-6837-43b2-b296-f74db549accf.png`,label:this.$t(`midjourney.styleTag.fluorescent`),value:`Fluorescent`},{image:`https://cdn.acedata.cloud/6ffc8688-dfd0-4ede-a6bc-91bf8679adc9.png`,label:this.$t(`midjourney.styleTag.glowing`),value:`Glowing`,advanced:!0},{image:`https://cdn.acedata.cloud/63bc0645-ab94-4327-84b8-e226020c6c0f.png`,label:this.$t(`midjourney.styleTag.glowStick`),value:`Glow-stick`,advanced:!0},{image:`https://cdn.acedata.cloud/824111e9-7ebf-47ec-80ef-a6ad0a1d949b.png`,label:this.$t(`midjourney.styleTag.glowRadioactive`),value:`Glow Radioactive`,advanced:!0},{image:`https://cdn.acedata.cloud/9d23de16-57b3-42be-89d2-478de2666483.png`,label:this.$t(`midjourney.styleTag.lavaGlow`),value:`Lava Glow`,advanced:!0},{image:`https://cdn.acedata.cloud/d801ee47-02a0-455d-b333-76ad73a4fdcd.png`,label:this.$t(`midjourney.styleTag.moonlight`),value:`Moonlight`},{image:`https://cdn.acedata.cloud/6d1400a8-e168-46c9-89e8-5e701f8824b2.png`,label:this.$t(`midjourney.styleTag.naturalLighting`),value:`Natural Lighting`},{image:`https://cdn.acedata.cloud/9bb6c4ce-9076-41eb-8ace-43a4fa7e0c03.png`,label:this.$t(`midjourney.styleTag.neonLamp`),value:`Neon Lamp`},{image:`https://cdn.acedata.cloud/ac3fe310-3639-4fc0-b56e-4d69278bc2ca.png`,label:this.$t(`midjourney.styleTag.nightclubLighting`),value:`Nightclub Lighting`,advanced:!0},{image:`https://cdn.acedata.cloud/c9331a92-87d2-43b5-9319-24c8629bffd1.png`,label:this.$t(`midjourney.styleTag.nuclearWasteGlo`),value:`Nuclear Waste Glo`,advanced:!0},{image:`https://cdn.acedata.cloud/40ccdbfb-84a7-49f7-9999-92db58802c65.png`,label:this.$t(`midjourney.styleTag.quantumDot`),value:`Quantum Dot`,advanced:!0},{image:`https://cdn.acedata.cloud/d5411604-4e66-4187-9b37-48eb683be65e.png`,label:this.$t(`midjourney.styleTag.spotlight`),value:`Spotlight`},{image:`https://cdn.acedata.cloud/b1f16a4b-fb3d-4783-9c66-c3567e79baeb.png`,label:this.$t(`midjourney.styleTag.edgeLight`),value:`Edge light`,advanced:!0},{image:`https://cdn.acedata.cloud/97fecbc1-a164-48e2-bdf0-c69975c16d63.png`,label:this.$t(`midjourney.styleTag.coldLight`),value:`Cold light`},{image:`https://cdn.acedata.cloud/7087f2fe-f48c-4b72-95bc-c697b56e8b0e.png`,label:this.$t(`midjourney.styleTag.keyLighting`),value:`Key lighting`,advanced:!0},{image:`https://cdn.acedata.cloud/5ab92c7e-bca1-4fbc-8975-6d9fb3f15626.png`,label:this.$t(`midjourney.styleTag.ambientLight`),value:`Ambient Light`,advanced:!0},{image:`https://cdn.acedata.cloud/ac80d283-5532-4664-bbe5-42fbb9582a63.png`,label:this.$t(`midjourney.styleTag.highKeyLighting`),value:`High key lighting`,advanced:!0},{image:`https://cdn.acedata.cloud/add3524d-fc90-45a8-9edc-348bb1f79075.png`,label:this.$t(`midjourney.styleTag.lowKeyLighting`),value:`Low key lighting`,advanced:!0},{image:`https://cdn.acedata.cloud/42174ff8-3080-4004-9ae2-c2ff919e1145.png`,label:this.$t(`midjourney.styleTag.motivatedLighting`),value:`Motivated lighting`,advanced:!0},{image:`https://cdn.acedata.cloud/09f3d509-a366-44dc-be3b-b39712d0fac1.png`,label:this.$t(`midjourney.styleTag.3PointLighting`),value:`3 point lighting`,advanced:!0},{image:`https://cdn.acedata.cloud/794a114e-cd4d-4e83-a187-5e979296d125.png`,label:this.$t(`midjourney.styleTag.strobeLight`),value:`Strobe light`,advanced:!0},{image:`https://cdn.acedata.cloud/9e6ec476-3ac8-4246-964f-a1d89a6d19e9.png`,label:this.$t(`midjourney.styleTag.sunLight`),value:`Sun light`},{image:`https://cdn.acedata.cloud/4360a40b-2126-43c2-be8e-e482978e1ea6.png`,label:this.$t(`midjourney.styleTag.ultraviolet`),value:`Ultraviolet`,advanced:!0},{image:`https://cdn.acedata.cloud/8b6bea86-9ed1-4fc8-9040-8fc2b64abbff.png`,label:this.$t(`midjourney.styleTag.beautifulLighting`),value:`Beautiful Lighting`,advanced:!0},{image:`https://cdn.acedata.cloud/a8d1f754-fb35-433d-8a36-e073b0fe6fa2.png`,label:this.$t(`midjourney.styleTag.moodyLighting`),value:`Moody Lighting`,advanced:!0},{image:`https://cdn.acedata.cloud/77270807-ca3b-4d02-a9b4-badf8aa48c36.png`,label:this.$t(`midjourney.styleTag.softLighting`),value:`Soft Lighting`}]},artists:{displayName:this.$t(`midjourney.styleCategory.artists`),items:[{image:`https://cdn.acedata.cloud/160cfc29-f258-4795-b663-f687adba19bf.png`,label:this.$t(`midjourney.styleTag.michelangelo`),value:`Michelangelo`},{image:`https://cdn.acedata.cloud/ed0bf2ad-138d-4c8d-bce9-a98299b1ee83.png`,label:this.$t(`midjourney.styleTag.monet`),value:`Monet`},{image:`https://cdn.acedata.cloud/58d9b130-e7b2-4eb8-a71e-7108b3bd4c26.png`,label:this.$t(`midjourney.styleTag.paulCezanne`),value:`Paul Cezanne`,advanced:!0},{image:`https://cdn.acedata.cloud/1247615a-6e75-49e6-842a-b0fb84016d3d.png`,label:this.$t(`midjourney.styleTag.markRothko`),value:`Mark Rothko`,advanced:!0},{image:`https://cdn.acedata.cloud/a7d9d9dd-8add-43d3-942e-8d1199fe277f.png`,label:this.$t(`midjourney.styleTag.paulKlee`),value:`Paul Klee`,advanced:!0},{image:`https://cdn.acedata.cloud/caf5701a-b652-4fab-8467-0c00303d01f3.png`,label:this.$t(`midjourney.styleTag.picasso`),value:`Picasso`},{image:`https://cdn.acedata.cloud/fbb63634-659a-4d2d-bc7b-0fb3399f7061.png`,label:this.$t(`midjourney.styleTag.pietMondrian`),value:`Piet Mondrian`,advanced:!0},{image:`https://cdn.acedata.cloud/29fb173b-17b4-4b05-a63c-e31ce161fe8c.png`,label:this.$t(`midjourney.styleTag.pierreAugusteRer`),value:`Pierre Auguste Rer`,advanced:!0},{image:`https://cdn.acedata.cloud/556f8a48-0b12-49a7-b150-aed40278d3f6.png`,label:this.$t(`midjourney.styleTag.rembrandt`),value:`Rembrandt`},{image:`https://cdn.acedata.cloud/b44d947e-2a14-4db2-880d-332c1aeeb303.png`,label:this.$t(`midjourney.styleTag.reneMagritte`),value:`Rene Magritte`,advanced:!0},{image:`https://cdn.acedata.cloud/0cfcda4a-7e7f-4ec4-ad4f-b4877a900a50.png`,label:this.$t(`midjourney.styleTag.royLichtenstein`),value:`Roy Lichtenstein`,advanced:!0},{image:`https://cdn.acedata.cloud/e592bf88-d9b8-4787-88dd-9ff8e7e9268c.png`,label:this.$t(`midjourney.styleTag.salvadorDali`),value:`Salvador Dali`,advanced:!0},{image:`https://cdn.acedata.cloud/3bbde342-565b-4ea0-8a4c-42b3c109c205.png`,label:this.$t(`midjourney.styleTag.sandroBotticelli`),value:`Sandro Botticelli`,advanced:!0},{image:`https://cdn.acedata.cloud/bfdf6d50-24ab-4b5c-a3de-c8d77d858b04.png`,label:this.$t(`midjourney.styleTag.takashiMurakami`),value:`Takashi Murakami`,advanced:!0},{image:`https://cdn.acedata.cloud/bc67c0ba-614f-46f0-a6ec-047fa561fc01.png`,label:this.$t(`midjourney.styleTag.vanGogh`),value:`Van Gogh`},{image:`https://cdn.acedata.cloud/984a18fa-8050-4084-95d5-732b7ede8e37.png`,label:this.$t(`midjourney.styleTag.wassilyKandinsky`),value:`Wassily Kandinsky`,advanced:!0},{image:`https://cdn.acedata.cloud/48bce45c-6b25-4678-9be8-40707c8e5f43.png`,label:this.$t(`midjourney.styleTag.matCollishaw`),value:`Mat Collishaw`,advanced:!0},{image:`https://cdn.acedata.cloud/6b2851d0-ec8d-4c07-86ed-1eafdd70e1fe.png`,label:this.$t(`midjourney.styleTag.yayoiKusama`),value:`Yayoi Kusama`,advanced:!0},{image:`https://cdn.acedata.cloud/9d691d5c-5560-409b-b998-c979b29902e6.png`,label:this.$t(`midjourney.styleTag.igorMorski`),value:`Igor Morski`,advanced:!0},{image:`https://cdn.acedata.cloud/950cb143-ab40-4bee-80f7-092d0c2a7bc4.png`,label:this.$t(`midjourney.styleTag.shinkaiMakoto`),value:`Shinkai Makoto`},{image:`https://cdn.acedata.cloud/94adf414-a1cc-4b84-b52d-18cd2586df17.png`,label:this.$t(`midjourney.styleTag.pixar`),value:`Pixar`},{image:`https://cdn.acedata.cloud/ccd4d148-e332-4d7e-bbe6-9f1dd68082a8.png`,label:this.$t(`midjourney.styleTag.kyotoAnime`),value:`Kyoto Anime`},{image:`https://cdn.acedata.cloud/b5f5f99a-be40-4fa7-a86a-fd51578a4052.png`,label:this.$t(`midjourney.styleTag.jerryPinkney`),value:`Jerry Pinkney`,advanced:!0},{image:`https://cdn.acedata.cloud/7a4dba74-21ad-4088-89da-6a48104d811d.png`,label:this.$t(`midjourney.styleTag.hayaoMiyazaki`),value:`Hayao Miyazaki`},{image:`https://cdn.acedata.cloud/28477b7e-85d4-4803-b525-938aa2ce3383.png`,label:this.$t(`midjourney.styleTag.beatrixPotter`),value:`Beatrix Potter`,advanced:!0},{image:`https://cdn.acedata.cloud/13854cb8-c478-43c9-9f51-8ac1933b1498.png`,label:this.$t(`midjourney.styleTag.jonKlassen`),value:`Jon Klassen`,advanced:!0},{image:`https://cdn.acedata.cloud/6685c7e0-ea11-488b-a8a0-610032020dfb.png`,label:this.$t(`midjourney.styleTag.kaySage`),value:`Kay Sage`,advanced:!0},{image:`https://cdn.acedata.cloud/cb0c3490-dcd4-488f-96e0-45b9ee671182.png`,label:this.$t(`midjourney.styleTag.jeffreyCatherineJones`),value:`Jeffrey Catherine Jones`,advanced:!0},{image:`https://cdn.acedata.cloud/72f000c5-d8d6-4015-acd4-79961e53ac50.png`,label:this.$t(`midjourney.styleTag.yaacovAgam`),value:`Yaacov Agam`,advanced:!0},{image:`https://cdn.acedata.cloud/f1bd0c4d-af96-4785-99bb-3a70b7f80834.png`,label:this.$t(`midjourney.styleTag.davidHockney`),value:`David Hockney`,advanced:!0},{image:`https://cdn.acedata.cloud/ad0e89d9-214a-4599-90f1-ee5dc0b5592d.png`,label:this.$t(`midjourney.styleTag.victorMoscoso`),value:`Victor Moscoso`,advanced:!0},{image:`https://cdn.acedata.cloud/c3b004e0-f583-4a75-b6cf-0cc60c89b2cf.png`,label:this.$t(`midjourney.styleTag.raphaelite`),value:`Raphaelite`},{image:`https://cdn.acedata.cloud/9c59d174-1e1f-4ef9-b657-1beb57f58088.png`,label:this.$t(`midjourney.styleTag.stefanKoidl`),value:`Stefan Koidl`,advanced:!0},{image:`https://cdn.acedata.cloud/09485865-35a8-4456-a34c-65a8a1c8d2c2.png`,label:this.$t(`midjourney.styleTag.suiIshida`),value:`Sui Ishida`,advanced:!0},{image:`https://cdn.acedata.cloud/31442dfd-d6a8-4674-aade-8543190251b4.png`,label:this.$t(`midjourney.styleTag.swoon`),value:`Swoon`,advanced:!0},{image:`https://cdn.acedata.cloud/842beff4-d333-4388-9880-eec6fd4baa6c.png`,label:this.$t(`midjourney.styleTag.tashaTudor`),value:`Tasha Tudor`,advanced:!0},{image:`https://cdn.acedata.cloud/68c419f3-6f2c-4fbd-a251-ce289d4a9890.png`,label:this.$t(`midjourney.styleTag.tintoretto`),value:`Tintoretto`,advanced:!0},{image:`https://cdn.acedata.cloud/9a3d95da-5019-4fdd-83b9-ec334e609c9d.png`,label:this.$t(`midjourney.styleTag.theodoreRobinsor`),value:`Theodore Robinsor`,advanced:!0},{image:`https://cdn.acedata.cloud/e11cb0a6-2f0e-4d8d-aa0e-8b7378423790.png`,label:this.$t(`midjourney.styleTag.titian`),value:`Titian`,advanced:!0},{image:`https://cdn.acedata.cloud/d3e59ba8-10e6-4d58-a732-e35d579cd3fc.png`,label:this.$t(`midjourney.styleTag.wlop`),value:`WLOP`,advanced:!0},{image:`https://cdn.acedata.cloud/70f22f51-9328-4070-b9aa-578db7d4c502.png`,label:this.$t(`midjourney.styleTag.yanjunCheng`),value:`Yanjun Cheng`,advanced:!0},{image:`https://cdn.acedata.cloud/e1203ff8-cb64-409e-8ba6-06f89645a843.png`,label:this.$t(`midjourney.styleTag.yojiShinkawa`),value:`Yoji Shinkawa`,advanced:!0},{image:`https://cdn.acedata.cloud/6b6d7746-e38b-44db-98d8-51d59ed7531f.png`,label:this.$t(`midjourney.styleTag.zhelongXu`),value:`Zhelong Xu`,advanced:!0},{image:`https://cdn.acedata.cloud/13b9621b-ff7e-4377-9550-0ca82d0f1afb.png`,label:this.$t(`midjourney.styleTag.alenaAenami`),value:`Alena Aenami`,advanced:!0},{image:`https://cdn.acedata.cloud/26d30765-3201-49e9-a4a9-c7c3b8c071ef.png`,label:this.$t(`midjourney.styleTag.anntonFadeevi`),value:`Annton Fadeevi`,advanced:!0},{image:`https://cdn.acedata.cloud/9b4c2bc7-16a8-4807-ad0e-ee9bdc80f1a0.png`,label:this.$t(`midjourney.styleTag.charlieBowater`),value:`Charlie Bowater`,advanced:!0},{image:`https://cdn.acedata.cloud/2f50d67e-3d7e-4e06-a198-5926ce7f357d.png`,label:this.$t(`midjourney.styleTag.coryLoftis`),value:`Cory Loftis`,advanced:!0},{image:`https://cdn.acedata.cloud/47823270-16a6-49cc-a11d-99122a037c68.png`,label:this.$t(`midjourney.styleTag.fenghuaZhong`),value:`Fenghua Zhong`,advanced:!0},{image:`https://cdn.acedata.cloud/1a66b5fd-cbf9-4e09-b817-6effed77b5c2.png`,label:this.$t(`midjourney.styleTag.gregRutkowski`),value:`Greg Rutkowski`,advanced:!0},{image:`https://cdn.acedata.cloud/d05a459a-132b-45a8-b2f3-a978eeeb44af.png`,label:this.$t(`midjourney.styleTag.hongSoonsang`),value:`Hong SoonSang`,advanced:!0},{image:`https://cdn.acedata.cloud/020dbf7f-f026-47bd-90f1-4049407409a1.png`,label:this.$t(`midjourney.styleTag.dennisStock`),value:`Dennis Stock`,advanced:!0},{image:`https://cdn.acedata.cloud/9c1ccc1d-121e-4182-aea0-04eac840869d.png`,label:this.$t(`midjourney.styleTag.michalLisowski`),value:`Michal Lisowski`,advanced:!0},{image:`https://cdn.acedata.cloud/3292404b-e654-4c06-bcd6-5e47a2adf329.png`,label:this.$t(`midjourney.styleTag.paulLehr`),value:`Paul Lehr`,advanced:!0},{image:`https://cdn.acedata.cloud/079c6053-23ad-4dc9-8166-64c5fe2f1e1a.png`,label:this.$t(`midjourney.styleTag.rossTran`),value:`Ross Tran`,advanced:!0},{image:`https://cdn.acedata.cloud/0f267ba1-c031-4008-9ead-630a4bec886a.png`,label:this.$t(`midjourney.styleTag.antonPieck`),value:`Anton Pieck`,advanced:!0},{image:`https://cdn.acedata.cloud/574dd25f-2116-4718-aed6-7d9be3636e22.png`,label:this.$t(`midjourney.styleTag.carlBarks`),value:`Carl Barks`,advanced:!0},{image:`https://cdn.acedata.cloud/38dcdfb5-0003-46f4-8c9d-5857c95f9e59.png`,label:this.$t(`midjourney.styleTag.alphonseMucha`),value:`Alphonse Mucha`,advanced:!0},{image:`https://cdn.acedata.cloud/65f2af96-e875-41f8-9797-3d34dbdf0ea4.png`,label:this.$t(`midjourney.styleTag.andyWarhol`),value:`Andy Warhol`,advanced:!0},{image:`https://cdn.acedata.cloud/801224a0-da77-4095-8799-d288d1ec3c3d.png`,label:this.$t(`midjourney.styleTag.banksy`),value:`Banksy`,advanced:!0},{image:`https://cdn.acedata.cloud/925c6c86-9b69-45ce-a10d-a2c64d4e0db2.png`,label:this.$t(`midjourney.styleTag.franciscoDeGoya`),value:`Francisco De Goya`,advanced:!0},{image:`https://cdn.acedata.cloud/fbb81b10-c579-4dcc-a76a-c099dc0b6c20.png`,label:this.$t(`midjourney.styleTag.caravaggio`),value:`Caravaggio`,advanced:!0},{image:`https://cdn.acedata.cloud/116efedd-42ea-404e-959e-607a9766001a.png`,label:this.$t(`midjourney.styleTag.diegoRivera`),value:`Diego Rivera`,advanced:!0},{image:`https://cdn.acedata.cloud/6f2c1d37-f8ae-4d72-8db1-d9fb04df7114.png`,label:this.$t(`midjourney.styleTag.davidHockney`),value:`David Hockney`,advanced:!0},{image:`https://cdn.acedata.cloud/b74b6b97-f6d7-4a34-840c-a81c69b9d941.png`,label:this.$t(`midjourney.styleTag.marcChagall`),value:`Marc Chagall`},{image:`https://cdn.acedata.cloud/f18ac9a3-a986-4670-813b-6fb81060ed48.png`,label:this.$t(`midjourney.styleTag.edgarDegas`),value:`Edgar Degas`,advanced:!0},{image:`https://cdn.acedata.cloud/275b32e5-9995-46cc-babc-43a0d1aa5d19.png`,label:this.$t(`midjourney.styleTag.eugeneDelacroix`),value:`Eugene Delacroix`,advanced:!0},{image:`https://cdn.acedata.cloud/500edde5-973c-4ba4-aae1-1a3d53a9b27f.png`,label:this.$t(`midjourney.styleTag.francisBacon`),value:`Francis Bacon`,advanced:!0},{image:`https://cdn.acedata.cloud/f7b5cc34-a796-4f45-823c-07122ec46ef6.png`,label:this.$t(`midjourney.styleTag.fridaKahlo`),value:`Frida Kahlo`,advanced:!0},{image:`https://cdn.acedata.cloud/7e41ead3-f54f-4d5f-8353-b2770d75c41b.png`,label:this.$t(`midjourney.styleTag.garaldBrom`),value:`Garald Brom`,advanced:!0},{image:`https://cdn.acedata.cloud/4a46247a-cd9b-48fd-b247-8268d9a891bf.png`,label:this.$t(`midjourney.styleTag.gustavKlimt`),value:`Gustav Klimt`,advanced:!0},{image:`https://cdn.acedata.cloud/3793eae9-61e9-4f16-9c0c-a77c194c45bc.png`,label:this.$t(`midjourney.styleTag.henriMatisse`),value:`Henri Matisse`,advanced:!0},{image:`https://cdn.acedata.cloud/dffa261d-755b-483d-88b7-058c09efd6af.png`,label:this.$t(`midjourney.styleTag.jackKirby`),value:`Jack Kirby`,advanced:!0},{image:`https://cdn.acedata.cloud/4cda1423-455b-463f-981d-b2af8ae1dd95.png`,label:this.$t(`midjourney.styleTag.jacksonPollock`),value:`Jackson Pollock`,advanced:!0},{image:`https://cdn.acedata.cloud/d318e4bc-d69f-4e7a-b6ae-49557e3cd569.png`,label:this.$t(`midjourney.styleTag.johannesVermeer`),value:`Johannes Vermeer`,advanced:!0},{image:`https://cdn.acedata.cloud/4ee7f9d2-01c0-4043-90f3-0174878a2ce7.png`,label:this.$t(`midjourney.styleTag.jeanMichelBasquiat`),value:`Jean Michel Basquiat`,advanced:!0},{image:`https://cdn.acedata.cloud/f60eb307-78b3-4f5e-bfd9-07603bc383c9.png`,label:this.$t(`midjourney.styleTag.marcelDuchamp`),value:`Marcel Duchamp`,advanced:!0}]},material:{displayName:this.$t(`midjourney.styleCategory.material`),items:[{image:`https://cdn.acedata.cloud/f2ce056d-6a89-4b40-b026-5a60cbb1efda.png`,label:this.$t(`midjourney.styleTag.aluminum`),value:`Aluminum`},{image:`https://cdn.acedata.cloud/069c6b1f-0666-4df6-bde6-a1729b33ade1.png`,label:this.$t(`midjourney.styleTag.brick`),value:`Brick`},{image:`https://cdn.acedata.cloud/39f2cbb9-be6a-4669-a7c3-b01dfbb2b563.png`,label:this.$t(`midjourney.styleTag.bronze`),value:`Bronze`},{image:`https://cdn.acedata.cloud/42b30429-2733-41a5-aa4c-e3e0cd50528a.png`,label:this.$t(`midjourney.styleTag.carbonFiber`),value:`Carbon Fiber`},{image:`https://cdn.acedata.cloud/90eeef27-6bdb-4f36-8e17-f1bb49881258.png`,label:this.$t(`midjourney.styleTag.cardboard`),value:`Cardboard`},{image:`https://cdn.acedata.cloud/470235fb-19a8-4ba8-ac9b-236abecf0985.png`,label:this.$t(`midjourney.styleTag.cellulose`),value:`Cellulose`},{image:`https://cdn.acedata.cloud/a8621e16-b046-4300-ab24-09602f734cb9.png`,label:this.$t(`midjourney.styleTag.ceramic`),value:`Ceramic`},{image:`https://cdn.acedata.cloud/af14acf6-92ff-42f8-ae14-ce4b63237bd5.png`,label:this.$t(`midjourney.styleTag.cotton`),value:`Cotton`},{image:`https://cdn.acedata.cloud/d93e6f18-3729-46cc-aa96-9662f2abae3d.png`,label:this.$t(`midjourney.styleTag.fabric`),value:`Fabric`},{image:`https://cdn.acedata.cloud/660533aa-dac7-4968-b27e-0f085b9a67a5.png`,label:this.$t(`midjourney.styleTag.fiberOptic`),value:`Fiber Optic`},{image:`https://cdn.acedata.cloud/94be6d51-5cb3-4362-8274-7d833a88bb79.png`,label:this.$t(`midjourney.styleTag.foil`),value:`Foil`},{image:`https://cdn.acedata.cloud/b89e102d-2fef-4619-8427-94c6bfbeb832.png`,label:this.$t(`midjourney.styleTag.yarn`),value:`Yarn`,advanced:!0},{image:`https://cdn.acedata.cloud/b72ef152-11a7-4c51-b6b4-dc4308995f9e.png`,label:this.$t(`midjourney.styleTag.glass`),value:`Glass`},{image:`https://cdn.acedata.cloud/bca80e91-46ba-4793-b29c-1b5c47b201d7.png`,label:this.$t(`midjourney.styleTag.gold`),value:`Gold`,advanced:!0},{image:`https://cdn.acedata.cloud/3d1e4da5-404b-4f89-8e06-988de47208bd.png`,label:this.$t(`midjourney.styleTag.gummies`),value:`Gummies`,advanced:!0},{image:`https://cdn.acedata.cloud/8afba6b0-a8a5-49c9-bfc5-ebd7b0e12443.png`,label:this.$t(`midjourney.styleTag.latex`),value:`Latex`},{image:`https://cdn.acedata.cloud/d5c39f1c-1be0-4065-80af-e1cb4e627cf2.png`,label:this.$t(`midjourney.styleTag.leather`),value:`Leather`},{image:`https://cdn.acedata.cloud/6e41e8bd-cb0b-4504-8655-a3b1b32ac11c.png`,label:this.$t(`midjourney.styleTag.magma`),value:`Magma`},{image:`https://cdn.acedata.cloud/f816fffa-4a7f-4d60-afcb-e19b0c36d176.png`,label:this.$t(`midjourney.styleTag.metallic`),value:`Metallic`},{image:`https://cdn.acedata.cloud/74c9fe01-37e6-4d05-831a-5778eb34c521.png`,label:this.$t(`midjourney.styleTag.nickel`),value:`Nickel`,advanced:!0},{image:`https://cdn.acedata.cloud/85186eac-1806-4739-9289-8d76aac359b3.png`,label:this.$t(`midjourney.styleTag.nylon`),value:`Nylon`},{image:`https://cdn.acedata.cloud/355d9507-62fa-4c69-986f-def2f2f930c5.png`,label:this.$t(`midjourney.styleTag.paper`),value:`Paper`},{image:`https://cdn.acedata.cloud/6c2626b2-191e-4b85-a97d-e561a2b5c79b.png`,label:this.$t(`midjourney.styleTag.plastic`),value:`Plastic`,advanced:!0},{image:`https://cdn.acedata.cloud/ff0d301d-8181-463c-a276-9b4805321afd.png`,label:this.$t(`midjourney.styleTag.quartz`),value:`Quartz`},{image:`https://cdn.acedata.cloud/7b90754d-2fa5-490e-a73b-d2887525d2e6.png`,label:this.$t(`midjourney.styleTag.wrap`),value:`Wrap`,advanced:!0},{image:`https://cdn.acedata.cloud/7411e62a-546e-4cd2-8446-73c4fb8f103b.png`,label:this.$t(`midjourney.styleTag.wooden`),value:`Wooden`},{image:`https://cdn.acedata.cloud/44e8830f-4be2-471d-a9d4-aaf4913e7451.png`,label:this.$t(`midjourney.styleTag.slime`),value:`Slime`,advanced:!0},{image:`https://cdn.acedata.cloud/16b10e75-a7e7-4b87-804a-2bfc9c18096f.png`,label:this.$t(`midjourney.styleTag.engraving`),value:`Engraving`},{image:`https://cdn.acedata.cloud/b66ec7e2-fd82-4edd-a523-34b87872f544.png`,label:this.$t(`midjourney.styleTag.ivory`),value:`Ivory`},{image:`https://cdn.acedata.cloud/098b954d-1197-414e-b4bd-68e3928b9eb3.png`,label:this.$t(`midjourney.styleTag.basalt`),value:`Basalt`,advanced:!0},{image:`https://cdn.acedata.cloud/b948dd7d-939b-48b5-b37c-09e0ebd6ede6.png`,label:this.$t(`midjourney.styleTag.pine`),value:`Pine`,advanced:!0},{image:`https://cdn.acedata.cloud/4c56fc7d-94c8-4055-9d6e-3bc6662c92d7.png`,label:this.$t(`midjourney.styleTag.diamond`),value:`Diamond`},{image:`https://cdn.acedata.cloud/70de6b75-bb29-4b2a-ae8a-016db33c8184.png`,label:this.$t(`midjourney.styleTag.amethyst`),value:`Amethyst`,advanced:!0},{image:`https://cdn.acedata.cloud/8d2b60e1-c98c-4de2-8a67-4b10c0d2482a.png`,label:this.$t(`midjourney.styleTag.ruby`),value:`Ruby`,advanced:!0},{image:`https://cdn.acedata.cloud/c0f01b99-32a6-4c34-a2d8-448fab08f126.png`,label:this.$t(`midjourney.styleTag.highPolished`),value:`High polished`,advanced:!0},{image:`https://cdn.acedata.cloud/5091142a-3959-40f3-9ea5-f41a29584735.png`,label:this.$t(`midjourney.styleTag.brushed`),value:`Brushed`,advanced:!0},{image:`https://cdn.acedata.cloud/3f84ddc5-5afe-41d1-85cc-2ded7a44d859.png`,label:this.$t(`midjourney.styleTag.matte`),value:`Matte`,advanced:!0},{image:`https://cdn.acedata.cloud/655f5114-b3dd-4b9a-a3cb-94a1a814fb11.png`,label:this.$t(`midjourney.styleTag.satin`),value:`Satin`,advanced:!0},{image:`https://cdn.acedata.cloud/6ec4178e-86e6-4026-aa86-e14eb4e92097.png`,label:this.$t(`midjourney.styleTag.sandblasted`),value:`Sandblasted`,advanced:!0},{image:`https://cdn.acedata.cloud/1c9a4277-5550-4cd4-852a-c785d8505a0f.png`,label:this.$t(`midjourney.styleTag.ebony`),value:`Ebony`,advanced:!0}]},camera:{displayName:this.$t(`midjourney.styleCategory.camera`),items:[{image:`https://cdn.acedata.cloud/9bcf851a-7b94-4554-864b-edcbe0f67017.png`,label:this.$t(`midjourney.styleTag.bokeh`),value:`Bokeh`},{image:`https://cdn.acedata.cloud/f4599568-5889-4da9-8852-8b5361c54412.png`,label:this.$t(`midjourney.styleTag.aerialView`),value:`Aerial view`},{image:`https://cdn.acedata.cloud/bea180e2-9078-42bd-9392-b0ee2b372430.png`,label:this.$t(`midjourney.styleTag.shotByDslr`),value:`Shot by DSLR`,advanced:!0},{image:`https://cdn.acedata.cloud/42444cbd-5442-4093-8911-645272c08863.png`,label:this.$t(`midjourney.styleTag.360Panorama`),value:`360Panorama`},{image:`https://cdn.acedata.cloud/99875464-0be7-44da-adf5-958d2c73eb31.png`,label:this.$t(`midjourney.styleTag.panorama`),value:`Panorama`},{image:`https://cdn.acedata.cloud/e3c3a204-9210-44da-b6fc-5f9a1fea52e0.png`,label:this.$t(`midjourney.styleTag.telephotoLens`),value:`Telephoto Lens`},{image:`https://cdn.acedata.cloud/7bd1f91d-cd6d-48d1-9f07-68382a54a552.png`,label:this.$t(`midjourney.styleTag.macroShot`),value:`Macro shot`},{image:`https://cdn.acedata.cloud/09aca457-2d96-4f60-b5ec-9fedf7a3fcb9.png`,label:this.$t(`midjourney.styleTag.microscopy`),value:`Microscopy`},{image:`https://cdn.acedata.cloud/fb39b4ab-d728-456b-8905-b4c0302f4094.png`,label:this.$t(`midjourney.styleTag.magnification`),value:`Magnification`},{image:`https://cdn.acedata.cloud/b9956b79-70b1-44af-bca3-5eddd412615a.png`,label:this.$t(`midjourney.styleTag.closeUp`),value:`Close up`},{image:`https://cdn.acedata.cloud/2c6b2c92-f790-44e1-bc65-b3182aa484bd.png`,label:this.$t(`midjourney.styleTag.fullBody`),value:`Full body`},{image:`https://cdn.acedata.cloud/05c7f5a8-4a79-4a1c-a4a9-792862ad118c.png`,label:this.$t(`midjourney.styleTag.portrait`),value:`Portrait`},{image:`https://cdn.acedata.cloud/aeb48a08-f0b6-47db-8c5d-ae6f0f92b93d.png`,label:this.$t(`midjourney.styleTag.profile`),value:`Profile`},{image:`https://cdn.acedata.cloud/dd655235-8f80-43b2-823f-bdb44864bee1.png`,label:this.$t(`midjourney.styleTag.pinholeLens`),value:`Pinhole Lens`,advanced:!0},{image:`https://cdn.acedata.cloud/7ad3f221-96f6-4014-953e-853c429d5d57.png`,label:this.$t(`midjourney.styleTag.wideView`),value:`Wide view`},{image:`https://cdn.acedata.cloud/698fbcc7-5ad1-40cb-a926-95189dc9e59b.png`,label:this.$t(`midjourney.styleTag.telescopeLens`),value:`Telescope Lens`,advanced:!0},{image:`https://cdn.acedata.cloud/2e41309b-f006-483f-9843-e15f4ced6be7.png`,label:this.$t(`midjourney.styleTag.satelliteImagery`),value:`Satellite Imagery`},{image:`https://cdn.acedata.cloud/79ad137d-3015-4335-a4e3-2ed29f9b850b.png`,label:this.$t(`midjourney.styleTag.headshot`),value:`Headshot`},{image:`https://cdn.acedata.cloud/d06164a9-ba01-457f-b8cc-f0b38a87b4d5.png`,label:this.$t(`midjourney.styleTag.extremeCloseup`),value:`Extreme closeup`,advanced:!0},{image:`https://cdn.acedata.cloud/b8e10ef3-b37c-45f0-b930-be729c8d17a1.png`,label:this.$t(`midjourney.styleTag.ultrawideShot`),value:`Ultrawide shot`},{image:`https://cdn.acedata.cloud/21eaa8a4-a8f1-448d-9f00-ff8fb0213046.png`,label:this.$t(`midjourney.styleTag.birdView`),value:`Bird view`,advanced:!0},{image:`https://cdn.acedata.cloud/43fadf68-dad1-45d2-bc22-54b1b2792a00.png`,label:this.$t(`midjourney.styleTag.topView`),value:`Top view`,advanced:!0},{image:`https://cdn.acedata.cloud/f8953e9e-6daf-4a70-a691-6f89e91f0b97.png`,label:this.$t(`midjourney.styleTag.frontView`),value:`Front view`,advanced:!0},{image:`https://cdn.acedata.cloud/f2228145-dc8f-4e06-be21-5d18bf50f7cf.png`,label:this.$t(`midjourney.styleTag.sideView`),value:`Side view`,advanced:!0},{image:`https://cdn.acedata.cloud/b218d1cc-60a7-4f62-a719-b852cd6ebf03.png`,label:this.$t(`midjourney.styleTag.backView`),value:`Back view`,advanced:!0},{image:`https://cdn.acedata.cloud/186522ef-7b09-40d8-a712-43dde1266bbf.png`,label:this.$t(`midjourney.styleTag.faceShot`),value:`Face shot`},{image:`https://cdn.acedata.cloud/6a0c1136-2817-42bb-b1e3-c65a130e70cf.png`,label:this.$t(`midjourney.styleTag.chestShot`),value:`Chest shot`},{image:`https://cdn.acedata.cloud/8ac3bf91-2066-420d-8da1-5d6214ad2668.png`,label:this.$t(`midjourney.styleTag.waistShot`),value:`Waist shot`},{image:`https://cdn.acedata.cloud/2558b92f-cb3b-410e-85cd-791eb7d29c60.png`,label:this.$t(`midjourney.styleTag.extraLongShot`),value:`Extra long shot`},{image:`https://cdn.acedata.cloud/0f5c9250-55a4-4eed-8ddf-af18cb52e243.png`,label:this.$t(`midjourney.styleTag.lookUp`),value:`look up`},{image:`https://cdn.acedata.cloud/5e0df52d-e986-4851-b6ae-dc0be744713d.png`,label:this.$t(`midjourney.styleTag.isometricview`),value:`isometricview`,advanced:!0},{image:`https://cdn.acedata.cloud/0d6491dd-1f64-423c-b63b-0f2e96a258e5.png`,label:this.$t(`midjourney.styleTag.highAngleView`),value:`High angle view`,advanced:!0},{image:`https://cdn.acedata.cloud/5b68beee-c079-4a8e-84c5-cb3cc0f6c77b.png`,label:this.$t(`midjourney.styleTag.lowAngleView`),value:`Low angle view`,advanced:!0}]},emotion:{displayName:this.$t(`midjourney.styleCategory.emotion`),items:[{image:`https://cdn.acedata.cloud/033c9cd1-f5cc-448f-8d0a-e6559bbd57e3.png`,label:this.$t(`midjourney.styleTag.happy`),value:`Happy`},{image:`https://cdn.acedata.cloud/d07fbadd-78e4-4a98-bcf8-45b4805c9239.png`,label:this.$t(`midjourney.styleTag.excited`),value:`Excited`},{image:`https://cdn.acedata.cloud/aa94049d-e8fc-4e0e-97b1-afa174d99b88.png`,label:this.$t(`midjourney.styleTag.angry`),value:`Angry`},{image:`https://cdn.acedata.cloud/ede7f1d3-5ce2-4b8f-9cb9-c4bd47b80cae.png`,label:this.$t(`midjourney.styleTag.ped`),value:`ped`},{image:`https://cdn.acedata.cloud/88f9e6ba-2961-497e-ae00-9af36fa2c2d4.png`,label:this.$t(`midjourney.styleTag.disgusted`),value:`Disgusted`},{image:`https://cdn.acedata.cloud/fe91b67b-2430-424a-bf72-1a299e61f049.png`,label:this.$t(`midjourney.styleTag.supnned`),value:`supnned`},{image:`https://cdn.acedata.cloud/24dcfb80-d987-48b0-9595-82276b2a1f94.png`,label:this.$t(`midjourney.styleTag.hopeful`),value:`Hopeful`},{image:`https://cdn.acedata.cloud/f2628539-bdf5-471d-9ceb-f0731c46b593.png`,label:this.$t(`midjourney.styleTag.anxious`),value:`Anxious`},{image:`https://cdn.acedata.cloud/f280d69a-eb1b-4259-b56d-66510f38ec82.png`,label:this.$t(`midjourney.styleTag.elated`),value:`Elated`},{image:`https://cdn.acedata.cloud/94b78236-ba14-4aab-8985-3921b2146fc9.png`,label:this.$t(`midjourney.styleTag.fearful`),value:`Fearful`},{image:`https://cdn.acedata.cloud/68576d87-224f-463f-85c9-5fbeb386a035.png`,label:this.$t(`midjourney.styleTag.hateful`),value:`Hateful`},{image:`https://cdn.acedata.cloud/e0413400-096f-4072-8faf-5ef82f8cc265.png`,label:this.$t(`midjourney.styleTag.apoow`),value:`Apoow`,advanced:!0},{image:`https://cdn.acedata.cloud/c0f4b0f4-1399-468f-873a-a04f4b7929f8.png`,label:this.$t(`midjourney.styleTag.dark`),value:`Dark`,advanced:!0},{image:`https://cdn.acedata.cloud/297d5f3f-ebc9-4c9f-b656-07359b313871.png`,label:this.$t(`midjourney.styleTag.brutal`),value:`Brutal`,advanced:!0}]},chinese:{displayName:this.$t(`midjourney.styleCategory.chinese`),items:[{image:`https://cdn.acedata.cloud/b29020e5-532d-4b30-94b0-cf5405242fc6.png`,label:this.$t(`midjourney.styleTag.hanfu`),value:`Hanfu`},{image:`https://cdn.acedata.cloud/e00eb48c-8240-4468-ac15-1a9d3349b636.png`,label:this.$t(`midjourney.styleTag.cheongsam`),value:`Cheongsam`},{image:`https://cdn.acedata.cloud/87d89bc5-cb61-4780-8894-c1564bdebd66.png`,label:this.$t(`midjourney.styleTag.chineseCostume`),value:`Chinese costume`},{image:`https://cdn.acedata.cloud/811453d2-2715-44fe-8609-b0d184486b19.png`,label:this.$t(`midjourney.styleTag.chineseDress`),value:`Chinese dress`},{image:`https://cdn.acedata.cloud/2463a720-b803-4d0d-9cac-6a7d5b61001d.png`,label:this.$t(`midjourney.styleTag.wuxia`),value:`Wuxia`},{image:`https://cdn.acedata.cloud/2fbee5a1-8a5c-4bfb-a52c-895ff3f53c3c.png`,label:this.$t(`midjourney.styleTag.chinesePhoenix`),value:`Chinese phoenix`},{image:`https://cdn.acedata.cloud/53fd3a51-7739-493f-aff0-daaea74b942c.png`,label:this.$t(`midjourney.styleTag.kungfu`),value:`Kungfu`},{image:`https://cdn.acedata.cloud/bc4c6bb0-82a5-4bbb-b4e3-96a14c52aed3.png`,label:this.$t(`midjourney.styleTag.kunquOpera`),value:`Kunqu opera`,advanced:!0},{image:`https://cdn.acedata.cloud/291ca1c1-069e-4067-8b9d-1c5c11c2ff14.png`,label:this.$t(`midjourney.styleTag.cloisonne`),value:`Cloisonne`,advanced:!0},{image:`https://cdn.acedata.cloud/17e87115-06ec-4f7b-9b8e-daf782cd4d59.png`,label:this.$t(`midjourney.styleTag.porcelain`),value:`Porcelain`},{image:`https://cdn.acedata.cloud/c9cc4712-24b9-4ff8-926b-02bd626df9a9.png`,label:this.$t(`midjourney.styleTag.embroidered`),value:`Embroidered`},{image:`https://cdn.acedata.cloud/7da286ae-d1e6-4a21-8ba5-10ff7bf9d379.png`,label:this.$t(`midjourney.styleTag.jade`),value:`Jade`},{image:`https://cdn.acedata.cloud/11a2d9f8-3c29-4b0b-ae10-525928f71bce.png`,label:this.$t(`midjourney.styleTag.chinesePavilion`),value:`Chinese pavilion`,advanced:!0},{image:`https://cdn.acedata.cloud/639b5e99-8210-4525-b63f-8b89019d07f3.png`,label:this.$t(`midjourney.styleTag.plumFlower`),value:`Plum flower`},{image:`https://cdn.acedata.cloud/cc87764c-2754-4cb7-8bc3-1070b31ec62b.png`,label:this.$t(`midjourney.styleTag.forbiddenCity`),value:`Forbidden city`,advanced:!0},{image:`https://cdn.acedata.cloud/26d2f2aa-ca26-4c0e-a8c7-86a81aafc475.png`,label:this.$t(`midjourney.styleTag.peony`),value:`Peony`,advanced:!0}]},special:{displayName:this.$t(`midjourney.styleCategory.special`),items:[{image:`https://cdn.acedata.cloud/0ca0fd15-cc8d-420e-acf5-6c489e03c7ff.png`,label:this.$t(`midjourney.styleTag.unrealEngine`),value:`Unreal engine`},{image:`https://cdn.acedata.cloud/ead8ba11-6634-409e-8fea-7b31ca3974bc.png`,label:this.$t(`midjourney.styleTag.octaneRender`),value:`Octane render`},{image:`https://cdn.acedata.cloud/209f1bd9-5d44-4699-97ad-fdde73304efb.png`,label:this.$t(`midjourney.styleTag.maxonCinema4D`),value:`Maxon cinema 4D`},{image:`https://cdn.acedata.cloud/93c31b69-7af4-4d1f-99d6-114a34133613.png`,label:this.$t(`midjourney.styleTag.quixelMegascansRender`),value:`Quixel megascans render`},{image:`https://cdn.acedata.cloud/9883f161-5069-414b-9d23-bd63806c5205.png`,label:this.$t(`midjourney.styleTag.coronaRender`),value:`Corona render`},{image:`https://cdn.acedata.cloud/9c28e4af-28b2-4b97-abd4-e4f42d014f3a.png`,label:this.$t(`midjourney.styleTag.vRay`),value:`V-ray`},{image:`https://cdn.acedata.cloud/01d71ceb-7d17-4318-9914-a6a5fe0abc11.png`,label:this.$t(`midjourney.styleTag.architecturalVisualisation`),value:`Architectural visualisation`},{image:`https://cdn.acedata.cloud/e7f2cd21-2efc-4e18-b38d-3c2cbd95c5ec.png`,label:this.$t(`midjourney.styleTag.dramaticContrast`),value:`Dramatic contrast`},{image:`https://cdn.acedata.cloud/8f113377-ba6e-4fb0-bd56-df8635ab6345.png`,label:this.$t(`midjourney.styleTag.goldAndBlackTone`),value:`Gold and black tone`},{image:`https://cdn.acedata.cloud/6da8b72d-5a67-4c06-b915-8c0b5314d9c8.png`,label:this.$t(`midjourney.styleTag.whiteAndPinkTone`),value:`White and pink tone`},{image:`https://cdn.acedata.cloud/09abd535-8ab6-451f-8bce-29859429244b.png`,label:this.$t(`midjourney.styleTag.redAndBlackTone`),value:`Red and black tone`},{image:`https://cdn.acedata.cloud/81115846-7676-4edb-b7cf-df816c90de7f.png`,label:this.$t(`midjourney.styleTag.neonShades`),value:`Neon shades`},{image:`https://cdn.acedata.cloud/dfcc7a8a-e145-4824-b12b-bd29292daa5f.png`,label:this.$t(`midjourney.styleTag.richColor`),value:`Rich color`},{image:`https://cdn.acedata.cloud/38b05148-73c6-4db3-bddd-b972f27f4671.png`,label:this.$t(`midjourney.styleTag.monotone`),value:`Monotone`},{image:`https://cdn.acedata.cloud/6f6704da-1854-43d7-811f-3145fea96909.png`,label:this.$t(`midjourney.styleTag.theLowPurityTone`),value:`The low-purity tone`},{image:`https://cdn.acedata.cloud/3724b5ef-e7dd-4234-b2a2-f71c6b69b4ac.png`,label:this.$t(`midjourney.styleTag.theHighPurityTone`),value:`The high-purity tone`}]}}}},computed:{value:{get(){return this.$store.state.midjourney.config.elements||[]},set(e){this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,elements:e})}}},methods:{onToggle(e){this.value.includes(e)?this.value=this.value.filter(t=>t!==e):(this.value.push(e),this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,elements:this.value}))}}}),Qn={class:`flex justify-between`},$n={class:`flex justify-start items-center`},er={class:`text-sm font-bold`},tr={class:`flex justify-end items-center`},nr=[`onClick`],rr={class:`name`};function ir(t,o,u,d,f,h){let _=l(`info-icon`),y=l(`el-button`),b=l(`el-tag`),x=l(`check`),S=l(`el-icon`),C=l(`el-image`),w=l(`el-tab-pane`),T=l(`el-tabs`),E=l(`el-dialog`);return v(),s(`div`,null,[e(`div`,Qn,[e(`div`,$n,[e(`span`,er,i(t.$t(`midjourney.field.elements`)),1),a(_,{content:t.$t(`midjourney.description.elements`)},null,8,[`content`])]),e(`div`,tr,[a(y,{round:``,type:`primary`,size:`small`,onClick:o[0]||=e=>t.choosing=!0},{default:m(()=>[r(i(t.$t(`midjourney.button.select`)),1)]),_:1})])]),e(`div`,null,[(v(!0),s(c,null,g(t.value,(e,n)=>(v(),p(b,{key:n,closable:``,effect:`dark`,round:``,class:`mr-1 mb-1`,onClose:n=>t.onToggle(e)},{default:m(()=>[r(i(e.label),1)]),_:2},1032,[`onClose`]))),128))]),a(E,{modelValue:t.choosing,"onUpdate:modelValue":o[2]||=e=>t.choosing=e,width:`70%`},{default:m(()=>[a(T,{modelValue:t.tab,"onUpdate:modelValue":o[1]||=e=>t.tab=e},{default:m(()=>[(v(!0),s(c,null,g(t.elements,(r,o)=>(v(),p(w,{key:o,label:r.displayName,name:o,class:`pane`},{default:m(()=>[(v(!0),s(c,null,g(r.items,(r,o)=>(v(),s(`div`,{key:o,class:n({hidden:r?.advanced,item:!0,active:t.value.includes(r)}),onClick:e=>t.onToggle(r)},[a(S,{class:`icon`},{default:m(()=>[a(x,{size:`1em`,"aria-hidden":`true`,focusable:`false`})]),_:1}),a(C,{src:r.image,fit:`fill`,class:`preview`},null,8,[`src`]),e(`span`,rr,i(r.label),1)],10,nr))),128))]),_:2},1032,[`label`,`name`]))),128))]),_:1},8,[`modelValue`])]),_:1},8,[`modelValue`])])}var ar=K(Zn,[[`render`,ir],[`__scopeId`,`data-v-ec52a37e`]]),or=`fast`,sr=b({name:`ModeSelector`,components:{ElButton:W,ElDropdown:N,ArrowDown:ne,ElIcon:x,ElDropdownItem:M},data(){return{options:[{label:this.$t(`midjourney.button.fast`),value:`fast`,icon:u(H),color:`#2dc49c`},{label:this.$t(`midjourney.button.relax`),value:`relax`,icon:u(Ne),color:`#ce65e6`},{label:this.$t(`midjourney.button.turbo`),value:`turbo`,icon:u(H),color:`#ff9900`}]}},computed:{activeOption(){return this.options.find(e=>e.value===this.value)},value:{get(){return this.$store.state.midjourney.config.mode},set(e){this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,mode:e})}}},mounted(){this.value||=or},methods:{onCommand(e){console.log(`command`,e),this.value=e}}}),cr={class:`ml-2`},lr={class:`ml-1 text-sm`};function ur(t,n,r,u,d,f){let y=l(`arrow-down`),b=l(`el-icon`),x=l(`el-button`),S=l(`el-dropdown-item`),C=l(`el-dropdown-menu`),w=l(`el-dropdown`);return v(),p(w,{trigger:`click`,onCommand:t.onCommand},{dropdown:m(()=>[a(C,null,{default:m(()=>[(v(!0),s(c,null,g(t.options,(t,n)=>(v(),p(S,{key:n,class:`flex items-center justify-between`,command:t.value},{default:m(()=>[t.icon?(v(),p(_(t.icon),{key:0,style:h({color:t.color}),size:`1em`,"aria-hidden":`true`,focusable:`false`},null,8,[`style`])):o(``,!0),e(`span`,lr,i(t.label),1)]),_:2},1032,[`command`]))),128))]),_:1})]),default:m(()=>[a(x,{round:``},{default:m(()=>[t.activeOption?.icon?(v(),p(_(t.activeOption.icon),{key:0,style:h({color:t.activeOption?.color}),size:`1em`,"aria-hidden":`true`,focusable:`false`},null,8,[`style`])):o(``,!0),e(`span`,cr,i(t.activeOption?.label),1),a(b,{class:`el-icon--right`},{default:m(()=>[a(y,{size:`1em`,"aria-hidden":`true`,focusable:`false`})]),_:1})]),_:1})]),_:1},8,[`onCommand`])}var dr=K(sr,[[`render`,ur],[`__scopeId`,`data-v-8fc9d403`]]),fr=b({name:`PromptInput`,components:{PromptTextarea:le},computed:{prompt:{get(){return this.$store.state.midjourney?.config.prompt},set(e){this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney?.config,prompt:e})}}},mounted(){this.prompt||=``}});function pr(e,t,n,r,i,a){let o=l(`prompt-textarea`);return v(),p(o,{modelValue:e.prompt,"onUpdate:modelValue":t[0]||=t=>e.prompt=t,title:e.$t(`midjourney.name.prompt`),info:e.$t(`midjourney.description.prompt`),placeholder:e.$t(`midjourney.placeholder.prompt`)},null,8,[`modelValue`,`title`,`info`,`placeholder`])}var mr=K(fr,[[`render`,pr]]),hr=b({name:`ReferenceImage`,components:{UploadIcon:V,ElUpload:E,ElButton:W,InfoIcon:$,ImagePreview:Q},mixins:[q,G],emits:[`change`],data(){return{fileList:[],uploadUrl:Z()+`/api/v1/files/`}},computed:{headers(){return{Authorization:`Bearer ${this.$store.state.token.access}`}},urls(){return this.fileList.map(e=>e?.response?.file_url)}},watch:{urls:{handler(e){console.debug(`URLs changed:`,e),this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,references:e})}}},methods:{onExceed(){J.warning(this.$t(`midjourney.message.uploadReferencesExceed`))},onError(){J.error(this.$t(`midjourney.message.uploadReferencesError`))}}}),gr={class:`relative`},_r={class:`flex min-h-8 items-center pr-20`},vr={class:`flex justify-start items-center`},yr={class:`text-sm font-bold`};function br(t,n,o,c,u,d){let f=l(`info-icon`),p=l(`image-preview`),h=l(`upload-icon`),g=l(`el-button`),_=l(`el-upload`);return v(),s(`div`,gr,[e(`div`,_r,[e(`div`,vr,[e(`span`,yr,i(t.$t(`midjourney.name.referenceImage`)),1),a(f,{content:t.$t(`midjourney.description.uploadReferences`)},null,8,[`content`])])]),a(_,{ref:`uploader`,"file-list":t.fileList,"onUpdate:fileList":n[0]||=e=>t.fileList=e,name:`file`,limit:5,class:`upload-wrapper`,accept:`.png,.jpg,.jpeg,.gif,.bmp,.webp`,multiple:!0,"list-type":`picture`,action:t.uploadUrl,"on-exceed":t.onExceed,"on-error":t.onError,headers:t.headers},{file:m(({file:e})=>[a(p,{url:e.url||e.response?.file_url,name:e.name,percentage:e.percentage,onRemove:n=>t.fileList.splice(t.fileList.indexOf(e),1)},null,8,[`url`,`name`,`percentage`,`onRemove`])]),default:m(()=>[a(g,{round:``,type:`primary`,size:`small`,class:`btn btn-upload`},{default:m(()=>[a(h,{class:`icon mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(t.$t(`midjourney.button.uploadReferences`)),1)]),_:1})]),_:1},8,[`file-list`,`action`,`on-exceed`,`on-error`,`headers`])])}var xr=b({name:`ConfigPanel`,components:{ElButton:W,PromptInput:mr,ModeSelector:dr,ModelSelector:un,ElementsSelector:ar,StyleSelector:Xn,QualitySelector:hn,RatioSelector:Ke,VersionSelector:ft,HdSelector:_t,StylizeSelector:Kt,AdvancedSelector:Qe,ChaosSelector:tn,WeirdSelector:In,ImageWeightSelector:On,ReferenceImage:K(hr,[[`render`,br],[`__scopeId`,`data-v-52bbab8a`]]),ImageUrlInput:wt,EndImageUrlInput:jt,LoopSelector:ot,ResolutionSelector:bn,ImageUrlInput2:Rt,Consumption:Te,VideoFromInput:Hn,ElTabs:w,ElTabPane:T},emits:[`generate`],computed:{config(){return this.$store.state.midjourney.config},isV8(){return this.config?.version===`8`||this.config?.version===`8.1`},isNiji(){return!!this.config?.model?.includes(`niji`)},type:{get(){return this.$store.state.midjourney.config.type||`imagine`},set(e){console.debug(`set type`,e),this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney.config,type:e})}},consumption(){return _e(this.config,this.service?.cost)},service(){return this.$store.state.midjourney?.service}},mounted(){this.config.type||(this.type=pe)}}),Sr={class:`flex flex-col h-full`},Cr={class:`flex-1 min-h-0 overflow-hidden`},wr={class:`p-5`},Tr={class:`p-5`},Er={class:`p-5`},Dr={class:`flex flex-col px-5 pb-5`},Or={class:`flex gap-1`};function kr(t,n,c,u,f,h){let g=l(`model-selector`),_=l(`prompt-input`),b=l(`reference-image`),x=l(`ratio-selector`),S=l(`quality-selector`),C=l(`version-selector`),w=l(`hd-selector`),T=l(`elements-selector`),E=l(`advanced-selector`),D=l(`stylize-selector`),O=l(`weird-selector`),k=l(`chaos-selector`),A=l(`image-weight-selector`),j=l(`style-selector`),M=l(`el-tab-pane`),N=l(`video-from-input`),P=l(`image-url-input`),F=l(`end-image-url-input`),I=l(`loop-selector`),L=l(`resolution-selector`),R=l(`image-url-input2`),ee=l(`el-tabs`),z=l(`consumption`),te=l(`mode-selector`),B=l(`el-button`);return v(),s(`div`,Sr,[e(`div`,Cr,[a(ee,{modelValue:t.type,"onUpdate:modelValue":n[0]||=e=>t.type=e,class:`demo-tabs`,stretch:``},{default:m(()=>[a(M,{label:t.$t(`midjourney.tab.images`),name:`imagine`},{default:m(()=>[e(`div`,wr,[a(g,{class:`mb-2`}),a(_,{class:`mb-4`}),a(b,{class:`mb-4`}),a(x,{class:`mb-4`}),a(S,{class:`mb-4`}),t.isNiji?o(``,!0):(v(),p(C,{key:0,class:`mb-4`})),t.isV8&&!t.isNiji?(v(),p(w,{key:1,class:`mb-4`})):o(``,!0),a(T,{class:`mb-2`}),a(E,{class:`mb-2`}),d(e(`div`,null,[a(D,{class:`mb-2`}),a(O,{class:`mb-2`}),a(k,{class:`mb-2`}),t.isV8?o(``,!0):(v(),p(A,{key:0,class:`mb-2`})),a(j,{class:`mb-2`})],512),[[y,t.config?.advanced]])])]),_:1},8,[`label`]),a(M,{label:t.$t(`midjourney.tab.videos`),name:`videos`},{default:m(()=>[e(`div`,Tr,[d(a(N,{class:`mb-4`},null,512),[[y,t.config?.action===`extend`]]),a(P,{class:`mb-4`}),a(F,{class:`mb-4`}),a(I,{class:`mb-2`}),a(L,{class:`mb-4`}),a(_,{class:`mb-4`})])]),_:1},8,[`label`]),a(M,{label:t.$t(`midjourney.tab.describe`),name:`describe`},{default:m(()=>[e(`div`,Er,[a(R,{class:`mb-4`})])]),_:1},8,[`label`])]),_:1},8,[`modelValue`])]),e(`div`,Dr,[a(z,{value:t.consumption,service:t.service},null,8,[`value`,`service`]),e(`div`,Or,[t.type===`describe`?o(``,!0):(v(),p(te,{key:0})),t.config.action===`extend`?(v(),p(B,{key:1,type:`primary`,class:`btn w-full`,round:``,onClick:n[1]||=e=>t.$emit(`generate`)},{default:m(()=>[r(i(t.$t(`midjourney.button.extend`)),1)]),_:1})):(v(),p(B,{key:2,type:`primary`,class:`btn w-full`,round:``,onClick:n[2]||=e=>t.$emit(`generate`)},{default:m(()=>[r(i(t.$t(`midjourney.button.generate`)),1)]),_:1}))])])])}var Ar=K(xr,[[`render`,kr],[`__scopeId`,`data-v-56073572`]]),jr=b({name:`TaskPreview`,components:{ChannelIcon:oe,ImageIcon:se,InfoIcon:ce,LightningIcon:H,MagicIcon:de,PerformanceIcon:ae,RefreshIcon:ue,TimeIcon:re,ImageWrapper:Me,ImagePreview:Q,ElButton:W,ElTooltip:D,ElAlert:O,ElTag:he,CopyToClipboard:ie,VideoPlayer:ke,ApiCodeButton:Ae},props:{modelValue:{type:Object,required:!0},full:{type:Boolean,default:!1}},emits:[`custom`],data(){return{midjourneyImagineState:me,actionMapping:{[X.GENERATE]:`Generate`,[X.UPSCALE1]:`U1`,[X.UPSCALE2]:`U2`,[X.UPSCALE3]:`U3`,[X.UPSCALE4]:`U4`,[X.VARIATION1]:`V1`,[X.VARIATION2]:`V2`,[X.VARIATION3]:`V3`,[X.VARIATION4]:`V4`,[X.VARIATION_STRONG]:`Vary (Strong)`,[X.VARIATION_SUBTLE]:`Vary (Subtle)`,[X.UPSCALE_CREATIVE]:`Upscale (Creative)`,[X.UPSCALE_SUBTLE]:`Upscale (Subtle)`,[X.ZOOM_OUT_2X]:`Zoom Out 2x`,[X.ZOOM_OUT_1_5X]:`Zoom Out 1.5x`,[X.UPSCALE_2X]:`Upscale 2x`,[X.UPSCALE_4X]:`Upscale 4x`,[X.REDO_UPSCALE_2X]:`Redo Upscale 2x`,[X.REDO_UPSCALE_4X]:`Redo Upscale 4x`,[X.REDO_UPSCALE_SUBTLE]:`Redo Upscale (Subtle)`,[X.REDO_UPSCALE_CREATIVE]:`Redo Upscale (Creative)`,[X.SQUARE]:`Make Square`,[X.PAN_LEFT]:`Pan Left`,[X.PAN_UP]:`Pan Up`,[X.PAN_DOWN]:`Pan Down`,[X.PAN_RIGHT]:`Pan Right`,[X.REROLL]:`Reroll`},actionIconMapping:{[X.PAN_LEFT]:u(R),[X.PAN_UP]:u(z),[X.PAN_DOWN]:u(L),[X.PAN_RIGHT]:u(ee),[X.REROLL]:u(ue)},descriptionMapping:{[X.GENERATE]:this.$t(`midjourney.action.generate`),[X.UPSCALE1]:this.$t(`midjourney.action.upscale1`),[X.UPSCALE2]:this.$t(`midjourney.action.upscale2`),[X.UPSCALE3]:this.$t(`midjourney.action.upscale3`),[X.UPSCALE4]:this.$t(`midjourney.action.upscale4`),[X.VARIATION1]:this.$t(`midjourney.action.variation1`),[X.VARIATION2]:this.$t(`midjourney.action.variation2`),[X.VARIATION3]:this.$t(`midjourney.action.variation3`),[X.VARIATION4]:this.$t(`midjourney.action.variation4`),[X.VARIATION_STRONG]:this.$t(`midjourney.action.variation_strong`),[X.VARIATION_SUBTLE]:this.$t(`midjourney.action.variation_subtle`),[X.ZOOM_OUT_2X]:this.$t(`midjourney.action.zoom_out_2x`),[X.ZOOM_OUT_1_5X]:this.$t(`midjourney.action.zoom_out_1_5x`),[X.UPSCALE_2X]:this.$t(`midjourney.action.upscale_2x`),[X.UPSCALE_4X]:this.$t(`midjourney.action.upscale_4x`),[X.UPSCALE_SUBTLE]:this.$t(`midjourney.action.upscale_subtle`),[X.UPSCALE_CREATIVE]:this.$t(`midjourney.action.upscale_creative`),[X.REDO_UPSCALE_2X]:this.$t(`midjourney.action.redo_upscale_2x`),[X.REDO_UPSCALE_4X]:this.$t(`midjourney.action.redo_upscale_4x`),[X.REDO_UPSCALE_SUBTLE]:this.$t(`midjourney.action.redo_upscale_subtle`),[X.REDO_UPSCALE_CREATIVE]:this.$t(`midjourney.action.redo_upscale_creative`),[X.SQUARE]:this.$t(`midjourney.action.square`),[X.PAN_LEFT]:this.$t(`midjourney.action.pan_left`),[X.PAN_UP]:this.$t(`midjourney.action.pan_up`),[X.PAN_DOWN]:this.$t(`midjourney.action.pan_down`),[X.PAN_RIGHT]:this.$t(`midjourney.action.pan_right`),[X.REROLL]:this.$t(`midjourney.action.reroll`)}}},computed:{application(){return this.$store.state.midjourney.application},config(){return this.$store.state.midjourney?.config},service(){return this.$store.state.midjourney?.service}},methods:{getActionDescriptionWithPrice(e,t){return`${this.descriptionMapping[e]} (${_e({...this.config,action:e,mode:t},this.service?.cost)} ${this.$t(`service.unit.${this.service?.unit||`credits`}`)})`},onCustom(e){this.modelValue?.type===`imagine`&&this.$emit(`custom`,{action:e,image_id:this.modelValue?.response?.image_id})},onExtend(e,t){console.debug(`set config`,t),this.$store.commit(`midjourney/setConfig`,{...this.$store.state.midjourney?.config,video_id:t.video_id,video_url:t.video_urls?.[0],action:`extend`,type:`videos`,is_videos:!0})},onDownload(e){let t=document.createElement(`a`);t.href=e,t.download=e.split(`/`).pop(),t.click()}}}),Mr={key:0,class:`item`},Nr={class:`left`},Pr={class:`preview`},Fr={class:`bot`},Ir={class:`datetime`},Lr={class:`info`},Rr={key:0,class:`prompt`},zr={key:0},Br={key:1},Vr={key:1,class:`prompt`},Hr={key:0},Ur={class:`text-[var(--el-text-color-regular)] text-xs mb-2`},Wr={class:`text-[var(--el-text-color-regular)] text-xs mb-2`},Gr={key:0,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},Kr={class:`text-[var(--el-text-color-regular)] text-xs mb-0`},qr={class:`text-[var(--el-text-color-regular)] text-xs mb-2`},Jr={key:0,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},Yr={class:`text-[var(--el-text-color-regular)] text-xs mb-2`},Xr={class:`text-[var(--el-text-color-regular)] text-xs mb-0`},Zr={key:2},Qr={class:`text-[var(--el-text-color-regular)] text-xs mb-0`},$r={key:1,class:`item`},ei={class:`left`},ti={class:`preview`},ni={class:`bot`},ri={class:`datetime`},ii={class:`info`},ai={key:0,class:`flex justify-start items-center gap-2 mt-2 w-full overflow-x-auto`},oi={key:1,class:`prompt`},si={key:0},ci={key:1},li={key:2,class:`prompt`},ui={key:0},di={key:0,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},fi={key:1,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},pi={key:2,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},mi={key:3,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},hi={class:`text-[var(--el-text-color-regular)] text-xs mb-2`},gi={class:`text-[var(--el-text-color-regular)] text-xs mb-2`},_i={key:4,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},vi={class:`text-[var(--el-text-color-regular)] text-xs mb-0`},yi={key:0,class:`mb-4`},bi={key:1,class:n({operations:!0,"mt-2":!0,"mb-4":!0})},xi={key:0,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},Si={key:1,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},Ci={key:2,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},wi={key:3,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},Ti={class:`text-[var(--el-text-color-regular)] text-xs mb-2`},Ei={key:4,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},Di={class:`text-[var(--el-text-color-regular)] text-xs mb-2`},Oi={class:`text-[var(--el-text-color-regular)] text-xs mb-0`},ki={key:2},Ai={key:0,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},ji={key:1,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},Mi={key:2,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},Ni={key:3,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},Pi={class:`text-[var(--el-text-color-regular)] text-xs mb-0`},Fi={key:2,class:`item`},Ii={class:`left`},Li={class:`preview`},Ri={class:`bot`},zi={class:`datetime`},Bi={class:`info`},Vi={key:0,class:`prompt`},Hi={key:0},Ui={key:1},Wi={class:`text-[var(--el-text-color-regular)] text-xs mb-2`},Gi={class:`text-[var(--el-text-color-regular)] text-xs mb-2`},Ki={key:0,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},qi={class:`text-[var(--el-text-color-regular)] text-xs mb-0`},Ji={class:`mb-2`},Yi={class:`mb-2`},Xi={key:0},Zi={class:`text-sm text-[var(--el-text-color-primary)]`},Qi={class:`text-[var(--el-text-color-regular)] text-xs mb-2`},$i={key:0,class:`text-[var(--el-text-color-regular)] text-xs mb-2`},ea={class:`text-[var(--el-text-color-regular)] text-xs mb-2`},ta={key:2},na={class:`text-[var(--el-text-color-regular)] text-xs mb-0`};function ra(u,f,h,b,x,S){let C=l(`capability-presentation`),w=l(`magic-icon`),T=l(`copy-to-clipboard`),E=l(`info-icon`),D=l(`time-icon`),O=l(`channel-icon`),k=l(`el-alert`),A=l(`image-wrapper`),j=l(`el-button`),M=l(`el-tooltip`),N=l(`api-code-button`),P=l(`image-icon`),F=l(`image-preview`),I=l(`lightning-icon`),L=l(`performance-icon`),R=l(`refresh-icon`),ee=l(`video-player`),z=l(`el-tag`);return v(),s(c,null,[u.modelValue?.type===`imagine`?(v(),s(`div`,Mr,[e(`div`,Nr,[a(C,{capability:`midjourney`,part:`avatar`,class:`avatar`})]),e(`div`,Pr,[e(`div`,Fr,[a(C,{capability:`midjourney`,part:`name`}),e(`span`,Ir,i(u.$dayjs.format(``+new Date(parseFloat((u.modelValue?.created_at||``).toString())*1e3))),1)]),e(`div`,Lr,[u.modelValue?.request?.prompt?(v(),s(`p`,Rr,[r(i(u.modelValue?.request?.prompt)+` `,1),u.modelValue?.response?o(``,!0):(v(),s(`span`,zr,` - (`+i(u.$t(`midjourney.status.pending`))+`) `,1)),u.modelValue?.response?.progress!==void 0&&u.modelValue?.response?.progress!==100?(v(),s(`span`,Br,` - (`+i(u.modelValue?.response?.progress)+`%) `,1)):o(``,!0),e(`span`,null,`(`+i(u.modelValue?.request?.mode)+`)`,1)])):o(``,!0),u.modelValue?.request?.image_id?(v(),s(`p`,Vr,[r(i(u.modelValue?.request?.image_id)+` - `+i(u.modelValue?.request?.action)+` `,1),u.modelValue?.response?o(``,!0):(v(),s(`span`,Hr,` - (`+i(u.$t(`midjourney.status.pending`))+`) `,1)),e(`span`,null,`(`+i(u.modelValue?.request?.mode)+`)`,1)])):o(``,!0)]),u.modelValue?.response?.success===!1?(v(),s(`div`,{key:0,class:n({content:!0,full:u.full,failed:!0})},[a(k,{closable:!1,class:`failure`},{default:m(()=>[e(`p`,Ur,[a(w,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.taskId`))+`: `+i(u.modelValue?.id)+` `,1),a(T,{content:u.modelValue?.id},null,8,[`content`])]),e(`p`,Wr,[a(E,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.failureReason`))+`: `+i(u.modelValue?.response?.error?.message)+` `,1),a(T,{content:u.modelValue?.response?.error?.message},null,8,[`content`])]),u.modelValue?.elapsed?(v(),s(`p`,Gr,[a(D,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.elapsed`))+`: `+i(u.modelValue?.elapsed?.toFixed(2))+`s `,1)])):o(``,!0),e(`p`,Kr,[a(O,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.traceId`))+`: `+i(u.modelValue?.response?.trace_id)+` `,1),a(T,{content:u.modelValue?.response?.trace_id},null,8,[`content`])])]),_:1})],2)):o(``,!0),u.modelValue?.response?.success===!0?(v(),s(`div`,{key:1,class:n({content:!0,full:u.full})},[u.modelValue?.response?.raw_image_url?(v(),p(A,{key:0,src:u.modelValue?.response?.image_url,"raw-src":u.modelValue?.response?.raw_image_url},null,8,[`src`,`raw-src`])):o(``,!0),u.modelValue?.response?.actions?(v(),s(`div`,{key:1,class:n({operations:!0,full:u.full})},[(v(!0),s(c,null,g(u.modelValue?.response?.actions,(e,t)=>(v(),p(M,{key:t,class:`box-item`,effect:`dark`,content:u.getActionDescriptionWithPrice(e,u.modelValue?.request?.mode),placement:`top-start`},{default:m(()=>[d(a(j,{type:`info`,size:`small`,class:`btn-action`,"aria-label":u.actionIconMapping[e]?u.descriptionMapping[e]:void 0,onClick:t=>u.onCustom(e)},{default:m(()=>[u.actionIconMapping[e]?(v(),p(_(u.actionIconMapping[e]),{key:0,size:`1em`,"aria-hidden":`true`,focusable:`false`})):(v(),s(c,{key:1},[r(i(u.actionMapping[e]),1)],64))]),_:2},1032,[`aria-label`,`onClick`]),[[y,u.actionMapping[e]]])]),_:2},1032,[`content`]))),128)),a(N,{path:`/midjourney/imagine`,body:u.modelValue?.request},null,8,[`body`])],2)):o(``,!0),a(k,{closable:!1,class:`mt-2 success`},{default:m(()=>[e(`p`,qr,[a(w,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.taskId`))+`: `+i(u.modelValue?.id)+` `,1),a(T,{content:u.modelValue?.id},null,8,[`content`])]),u.modelValue?.elapsed?(v(),s(`p`,Jr,[a(D,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.elapsed`))+`: `+i(u.modelValue?.elapsed?.toFixed(2))+`s `,1)])):o(``,!0),e(`p`,Yr,[a(O,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.traceId`))+`: `+i(u.modelValue?.trace_id)+` `,1),a(T,{content:u.modelValue?.trace_id},null,8,[`content`])]),e(`p`,Xr,[a(P,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.imageId`))+`: `+i(u.modelValue?.response?.image_id)+` `,1),a(T,{content:u.modelValue?.response?.image_id},null,8,[`content`])])]),_:1})],2)):o(``,!0),u.modelValue?.response?o(``,!0):(v(),s(`div`,Zr,[a(k,{closable:!1,class:`mt-2 info`},{default:m(()=>[e(`p`,Qr,[a(w,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.taskId`))+`: `+i(u.modelValue?.id)+` `,1),a(T,{content:u.modelValue?.id},null,8,[`content`])])]),_:1})]))])])):o(``,!0),u.modelValue?.type===`videos`?(v(),s(`div`,$r,[e(`div`,ei,[a(C,{capability:`midjourney`,part:`avatar`,class:`avatar`})]),e(`div`,ti,[e(`div`,ni,[a(C,{capability:`midjourney`,part:`name`}),e(`span`,ri,i(u.$dayjs.format(``+new Date(parseFloat((u.modelValue?.created_at||``).toString())*1e3))),1)]),e(`div`,ii,[u.modelValue?.request?.image_url||u.modelValue?.request?.end_image_url?(v(),s(`div`,ai,[u.modelValue?.request?.image_url?(v(),p(F,{key:0,url:u.modelValue.request.image_url,name:u.$t(`midjourney.name.imageUrl`),closable:!1},null,8,[`url`,`name`])):o(``,!0),u.modelValue?.request?.end_image_url?(v(),p(F,{key:1,url:u.modelValue.request.end_image_url,name:u.$t(`midjourney.name.endImageUrl`),closable:!1},null,8,[`url`,`name`])):o(``,!0)])):o(``,!0),u.modelValue?.request?.prompt?(v(),s(`p`,oi,[r(i(u.modelValue?.request?.prompt)+` `,1),u.modelValue?.response?o(``,!0):(v(),s(`span`,si,` - (`+i(u.$t(`midjourney.status.pending`))+`) `,1)),u.modelValue?.response?.progress!==void 0&&u.modelValue?.response?.progress!==100?(v(),s(`span`,ci,` - (`+i(u.modelValue?.response?.progress)+`%) `,1)):o(``,!0),e(`span`,null,`(`+i(u.modelValue?.request?.mode)+`)`,1)])):o(``,!0),u.modelValue?.request?.video_id?(v(),s(`p`,li,[r(i(u.modelValue?.request?.video_id)+` - `+i(u.modelValue?.request?.action)+` `,1),u.modelValue?.response?o(``,!0):(v(),s(`span`,ui,` - (`+i(u.$t(`midjourney.status.pending`))+`) `,1)),e(`span`,null,`(`+i(u.modelValue?.request?.mode)+`)`,1)])):o(``,!0)]),u.modelValue?.response?.success===!1?(v(),s(`div`,{key:0,class:n({content:!0,full:u.full,failed:!0})},[a(k,{closable:!1,class:`failure`},{default:m(()=>[u.modelValue?.request?.action?(v(),s(`p`,di,[a(I,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.action`))+`: `+i(u.modelValue?.request?.action),1)])):o(``,!0),u.modelValue?.request?.resolution?(v(),s(`p`,fi,[a(L,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.name.resolution`))+`: `+i(u.modelValue?.request?.resolution),1)])):o(``,!0),u.modelValue?.request?.mode?(v(),s(`p`,pi,[a(D,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.name.mode`))+`: `+i(u.modelValue?.request?.mode),1)])):o(``,!0),u.modelValue?.request?.loop===void 0?o(``,!0):(v(),s(`p`,mi,[a(R,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.name.loop`))+`: `+i(u.modelValue?.request?.loop?u.$t(`midjourney.field.on`):u.$t(`midjourney.field.off`)),1)])),e(`p`,hi,[a(w,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.taskId`))+`: `+i(u.modelValue?.id)+` `,1),a(T,{content:u.modelValue?.id},null,8,[`content`])]),e(`p`,gi,[a(E,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.failureReason`))+`: `+i(u.modelValue?.response?.error?.message)+` `,1),a(T,{content:u.modelValue?.response?.error?.message},null,8,[`content`])]),u.modelValue?.elapsed?(v(),s(`p`,_i,[a(D,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.elapsed`))+`: `+i(u.modelValue?.elapsed?.toFixed(2))+`s `,1)])):o(``,!0),e(`p`,vi,[a(O,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.traceId`))+`: `+i(u.modelValue?.response?.trace_id)+` `,1),a(T,{content:u.modelValue?.response?.trace_id},null,8,[`content`])])]),_:1})],2)):o(``,!0),u.modelValue?.response?.success===!0?(v(),s(`div`,{key:1,class:n({content:!0,full:u.full})},[u.modelValue?.response.video_urls?(v(),s(`div`,yi,[a(ee,{src:u.modelValue?.response.video_urls[0]},null,8,[`src`])])):o(``,!0),u.modelValue?.response&&u.modelValue?.response?.video_urls?(v(),s(`div`,bi,[a(M,{class:`box-item`,effect:`dark`,content:u.$t(`luma.message.extendVideo`),placement:`top-start`},{default:m(()=>[a(j,{type:`info`,size:`small`,class:`btn-action`,onClick:f[0]||=t(e=>u.onExtend(e,u.modelValue?.response),[`stop`])},{default:m(()=>[r(i(u.$t(`midjourney.button.extend`)),1)]),_:1})]),_:1},8,[`content`]),a(M,{class:`box-item`,effect:`dark`,content:u.$t(`luma.message.downloadVideo`),placement:`top-start`},{default:m(()=>[a(j,{type:`info`,size:`small`,class:`btn-action`,onClick:f[1]||=t(e=>u.onDownload(u.modelValue.response.video_urls[0]),[`stop`])},{default:m(()=>[r(i(u.$t(`midjourney.button.download`)),1)]),_:1})]),_:1},8,[`content`]),a(N,{path:`/midjourney/videos`,body:u.modelValue?.request},null,8,[`body`])])):o(``,!0),a(k,{closable:!1,class:`mt-2 success`},{default:m(()=>[u.modelValue?.request?.action?(v(),s(`p`,xi,[a(I,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.action`))+`: `+i(u.modelValue?.request?.action),1)])):o(``,!0),u.modelValue?.request?.resolution?(v(),s(`p`,Si,[a(L,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.name.resolution`))+`: `+i(u.modelValue?.request?.resolution),1)])):o(``,!0),u.modelValue?.request?.mode?(v(),s(`p`,Ci,[a(D,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.name.mode`))+`: `+i(u.modelValue?.request?.mode),1)])):o(``,!0),u.modelValue?.request?.loop===void 0?o(``,!0):(v(),s(`p`,wi,[a(R,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.name.loop`))+`: `+i(u.modelValue?.request?.loop?u.$t(`midjourney.field.on`):u.$t(`midjourney.field.off`)),1)])),e(`p`,Ti,[a(w,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.taskId`))+`: `+i(u.modelValue?.id)+` `,1),a(T,{content:u.modelValue?.id},null,8,[`content`])]),u.modelValue?.elapsed?(v(),s(`p`,Ei,[a(D,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.elapsed`))+`: `+i(u.modelValue?.elapsed?.toFixed(2))+`s `,1)])):o(``,!0),e(`p`,Di,[a(O,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.traceId`))+`: `+i(u.modelValue?.trace_id)+` `,1),a(T,{content:u.modelValue?.trace_id},null,8,[`content`])]),e(`p`,Oi,[a(P,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.videoId`))+`: `+i(u.modelValue?.response?.video_id)+` `,1),a(T,{content:u.modelValue?.response?.video_id},null,8,[`content`])])]),_:1})],2)):o(``,!0),u.modelValue?.response?o(``,!0):(v(),s(`div`,ki,[a(k,{closable:!1,class:`info`},{default:m(()=>[u.modelValue?.request?.action?(v(),s(`p`,Ai,[a(I,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.action`))+`: `+i(u.modelValue?.request?.action),1)])):o(``,!0),u.modelValue?.request?.resolution?(v(),s(`p`,ji,[a(L,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.name.resolution`))+`: `+i(u.modelValue?.request?.resolution),1)])):o(``,!0),u.modelValue?.request?.mode?(v(),s(`p`,Mi,[a(D,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.name.mode`))+`: `+i(u.modelValue?.request?.mode),1)])):o(``,!0),u.modelValue?.request?.loop===void 0?o(``,!0):(v(),s(`p`,Ni,[a(R,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.name.loop`))+`: `+i(u.modelValue?.request?.loop?u.$t(`midjourney.field.on`):u.$t(`midjourney.field.off`)),1)])),e(`p`,Pi,[a(w,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.taskId`))+`: `+i(u.modelValue?.id)+` `,1),a(T,{content:u.modelValue?.id},null,8,[`content`])])]),_:1})]))])])):o(``,!0),u.modelValue?.type===`describe`?(v(),s(`div`,Fi,[e(`div`,Ii,[a(C,{capability:`midjourney`,part:`avatar`,class:`avatar`})]),e(`div`,Li,[e(`div`,Ri,[a(C,{capability:`midjourney`,part:`name`}),e(`span`,zi,i(u.$dayjs.format(``+new Date(parseFloat((u.modelValue?.created_at||``).toString())*1e3))),1)]),e(`div`,Bi,[u.modelValue?.request?.image_url?(v(),s(`p`,Vi,[r(i(u.modelValue?.request?.image_url)+` `,1),u.modelValue?.response?.descriptions?o(``,!0):(v(),s(`span`,Hi,` - (`+i(u.$t(`midjourney.status.describePending`))+`) `,1)),u.modelValue?.response?.descriptions?(v(),s(`span`,Ui,` - (`+i(u.$t(`midjourney.status.describeComplete`))+`) `,1)):o(``,!0)])):o(``,!0)]),u.modelValue?.response&&!u.modelValue?.response?.descriptions?(v(),s(`div`,{key:0,class:n({content:!0,full:u.full,failed:!0})},[a(k,{closable:!1,class:`failure`},{default:m(()=>[e(`p`,Wi,[a(w,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.taskId`))+`: `+i(u.modelValue?.id)+` `,1),a(T,{content:u.modelValue?.id},null,8,[`content`])]),e(`p`,Gi,[a(E,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.failureReason`))+`: `+i(u.modelValue?.response?.error?.message)+` `,1),a(T,{content:u.modelValue?.response?.error?.message},null,8,[`content`])]),u.modelValue?.elapsed?(v(),s(`p`,Ki,[a(D,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.elapsed`))+`: `+i(u.modelValue?.elapsed?.toFixed(2))+`s `,1)])):o(``,!0),e(`p`,qi,[a(O,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.traceId`))+`: `+i(u.modelValue?.trace_id)+` `,1),a(T,{content:u.modelValue?.trace_id},null,8,[`content`])])]),_:1})],2)):o(``,!0),u.modelValue?.response?.descriptions?(v(),s(`div`,{key:1,class:n({content:!0,full:u.full})},[e(`div`,Ji,[e(`div`,Yi,[(v(!0),s(c,null,g(u.modelValue.response.descriptions,(t,n)=>(v(),s(`div`,{key:n,class:`flex items-start`},[t===``?o(``,!0):(v(),s(`div`,Xi,[a(z,{effect:`dark`,size:`small`,type:`primary`,round:``,class:`mr-1`},{default:m(()=>[r(i(n+1),1)]),_:2},1024),e(`span`,Zi,[r(i(t)+` `,1),a(T,{content:t},null,8,[`content`])])]))]))),128))]),u.modelValue?.request?.image_url?(v(),p(A,{key:0,src:u.modelValue?.request?.image_url,"raw-src":u.modelValue?.request?.image_url,class:`image w-full rounded-lg`},null,8,[`src`,`raw-src`])):o(``,!0)]),e(`div`,{class:n({operations:!0,"mt-2":!0,"mb-2":!0,full:u.full})},[a(N,{path:`/midjourney/describe`,body:u.modelValue?.request},null,8,[`body`])],2),a(k,{closable:!1,class:`success`},{default:m(()=>[e(`p`,Qi,[a(w,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.taskId`))+`: `+i(u.modelValue?.id)+` `,1),a(T,{content:u.modelValue?.id},null,8,[`content`])]),u.modelValue?.elapsed?(v(),s(`p`,$i,[a(D,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.elapsed`))+`: `+i(u.modelValue?.elapsed?.toFixed(2))+`s `,1)])):o(``,!0),e(`p`,ea,[a(O,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.traceId`))+`: `+i(u.modelValue?.trace_id)+` `,1),a(T,{content:u.modelValue?.trace_id},null,8,[`content`])])]),_:1})],2)):o(``,!0),u.modelValue?.response?o(``,!0):(v(),s(`div`,ta,[a(k,{closable:!1,class:`info`},{default:m(()=>[e(`p`,na,[a(w,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),r(` `+i(u.$t(`midjourney.field.taskId`))+`: `+i(u.modelValue?.id)+` `,1),a(T,{content:u.modelValue?.id},null,8,[`content`])])]),_:1})]))])])):o(``,!0)],64)}var ia=b({name:`TaskList`,components:{TaskItem:K(jr,[[`render`,ra],[`__scopeId`,`data-v-183a9211`]]),BotPlaceholder:je,NoTasks:De,ScrollList:Ee},props:{loading:{type:Boolean,default:!1},floatingLoader:{type:Boolean,default:!0}},emits:[`custom`,`extend`,`reach-top`],data(){return{job:0}},computed:{tasks(){return this.$store.state.midjourney.tasks?.items},application(){return this.$store.state.midjourney.application}},methods:{getScrollElement(){return this.$refs.scrollList?.getScrollElement?.()}}}),aa={key:0,class:`p-2 flex flex-col overflow-y-auto`},oa={key:1,class:`w-full h-full flex items-center justify-center`};function sa(e,t,n,r,i,u){let d=l(`bot-placeholder`),f=l(`no-tasks`),h=l(`task-item`),_=l(`scroll-list`);return e.tasks===void 0?(v(),s(`div`,aa,[a(d)])):e.tasks&&e.tasks?.length===0?(v(),s(`div`,oa,[a(f)])):e.tasks.length>0?(v(),p(_,{key:2,ref:`scrollList`,class:`p-2 py-3 h-full flex flex-col overflow-y-auto tasks`,loading:e.loading,"floating-loader":e.floatingLoader,onReachTop:t[2]||=t=>e.$emit(`reach-top`)},{default:m(()=>[(v(!0),s(c,null,g(e.tasks,n=>(v(),p(h,{key:n.id,"model-value":n,onExtend:t[0]||=t=>e.$emit(`extend`,t),onCustom:t[1]||=t=>e.$emit(`custom`,t)},null,8,[`model-value`]))),128))]),_:1},8,[`loading`,`floating-loader`])):o(``,!0)}var ca=b({name:`MidjourneyIndex`,components:{ConfigPanel:Ar,TaskList:K(ia,[[`render`,sa]]),Layout:ze},mixins:[ge],inject:[`initialized`],data(){return{operating:!1,job:0,loadingMore:!1,fetchingTasks:!1}},computed:{tasks(){return this.$store.state.midjourney.tasks},credential(){return this.$store.state.midjourney.credential},config(){return this.$store.state.midjourney.config},loading(){return this.$store.state.midjourney.status.getApplications===ye.Request},tasksLoading(){return this.$store.state.midjourney.status.getTasks===ye.Request||this.fetchingTasks},application(){return this.$store.state.midjourney.application},finalPrompt(){let e=``;this.config.references&&this.config.references?.length>0&&(e+=`${this.config.references.join(` `)} `),this.config.prompt&&(e+=this.config.prompt),this.config.elements&&this.config.elements.length>0&&(e+=`,`+this.config.elements.map(e=>e.value).join(`,`));let t=this.config?.model?.includes(`niji`);return this.config?.model&&!e.includes(`--${this.config.model}`)&&(e+=` --${this.config.model}`),!t&&this.config?.version&&!e.includes(`--version `)&&!e.includes(`--v `)&&(e+=` --version ${this.config.version}`),this.config?.chaos&&this.config?.advanced&&!e.includes(`--chaos `)&&(e+=` --chaos ${this.config.chaos}`),this.config?.quality&&!e.includes(`--quality `)&&!e.includes(`--q `)&&this.config?.quality!==`1`&&(e+=` --quality ${this.config.quality}`),this.config?.ratio&&!e.includes(`--aspect `)&&!e.includes(`--ar `)&&this.config?.ratio!==`1:1`&&(e+=` --aspect ${this.config.ratio}`),this.config?.stylize&&!e.includes(`--stylize `)&&!e.includes(`--s `)&&this.config?.advanced&&this.config?.stylize!==100&&(e+=` --stylize ${this.config?.stylize}`),this.config?.weird&&!e.includes(`--weird `)&&!e.includes(`--w `)&&this.config?.advanced&&this.config?.weird!==0&&(e+=` --weird ${this.config.weird}`),this.config.ignore&&!e.includes(`--no `)&&(e+=` --no ${this.config.ignore}`),this.config?.iw&&!e.includes(`--iw `)&&this.config?.advanced&&this.config?.iw!==1&&(e+=` --iw ${this.config.iw}`),this.config?.style&&this.config?.advanced&&!e.includes(`--style`)&&(e+=` --style ${this.config?.style}`),!t&&this.config?.hd&&!e.includes(`--hd`)&&(e+=` --hd`),e=e.replace(/--(fast|relax|turbo) /g,``),this.config.prompt||this.config.references&&this.config.references?.length>0?e:``}},watch:{tasks:{handler(e,t){e?.items?.length>t?.items?.length&&console.debug(`new tasks detected`)},deep:!0},initialized:{async handler(e){e&&(console.debug(`layout initialized`),await this.onGetTasks(),await this.onScrollDown(),this.job=window.setInterval(()=>{this.onGetTasks()},5e3))},immediate:!0}},async mounted(){await this.onGetService()},async unmounted(){window.clearInterval(this.job)},methods:{async onReachTop(){await Oe({tasks:this.tasks,getTasks:()=>this.tasks,loading:this.loadingMore,setLoading:e=>this.loadingMore=e,isBlocked:()=>this.tasksLoading||this.loading,fetch:e=>this.onGetTasks({createdAtMax:e}),getScrollElement:()=>this.getTasksScrollElement()})},async onGetService(){console.debug(`start onGetService`),await this.$store.dispatch(`midjourney/getService`),console.debug(`end onGetService`)},async onGetApplication(){console.debug(`start onGetApplications`),await this.$store.dispatch(`midjourney/getApplications`),console.debug(`end onGetApplications`),await this.onGetTasks()},async onStartImagineTask(e){if(!U())return;let t=this.credential?.token;if(!t){console.error(`no token specified`);return}if(!e.prompt&&e.action===X.GENERATE){J.error(this.$t(`midjourney.message.promptRequired`));return}J.info(this.$t(`midjourney.message.startingTask`)),Y(`midjourney`,xe.imagine(e,{token:t})).then(()=>{J.success(this.$t(`midjourney.message.startTaskSuccess`))}).catch(e=>{(e?.response?.data)?.error?.code===`used_up`?J.error(this.$t(`midjourney.message.usedUp`)):J.error(this.$t(`midjourney.message.startTaskFailed`)+e.response?.data?.error?.message)}).finally(async()=>{setTimeout(async()=>{await this.onGetTasks(),await this.onScrollDown()},1e3)})},async onStartVideosTask(e){if(!U())return;let t=this.credential?.token;if(!t){console.error(`no token specified`);return}if(!e.prompt){J.error(this.$t(`midjourney.message.promptRequired`));return}if(e.action!==ve.EXTEND&&!e.image_url){J.error(this.$t(`midjourney.message.imageUrlRequired`));return}J.info(this.$t(`midjourney.message.startingTask`)),Y(`midjourney`,xe.videos(e,{token:t})).then(()=>{J.success(this.$t(`midjourney.message.startVideosTaskSuccess`))}).catch(e=>{(e?.response?.data)?.error?.code===`used_up`?J.error(this.$t(`midjourney.message.usedUp`)):J.error(this.$t(`midjourney.message.startVideosTaskFailed`)+e.response?.data?.error?.message)}).finally(async()=>{setTimeout(async()=>{await this.onGetTasks(),await this.onScrollDown()},1e3)})},async onStartDescribeTask(e){if(!U())return;let t=this.credential?.token;if(!t){console.error(`no token specified`);return}J.info(this.$t(`midjourney.message.startingTask`)),Y(`midjourney`,xe.describe(e,{token:t})).then(()=>{J.success(this.$t(`midjourney.message.startDescribeTaskSuccess`))}).catch(e=>{(e?.response?.data)?.error?.code===`used_up`?J.error(this.$t(`midjourney.message.usedUp`)):J.error(this.$t(`midjourney.message.startDescribeTaskFailed`)+e.response?.data?.error?.message)}).finally(async()=>{setTimeout(async()=>{await this.onGetTasks(),await this.onScrollDown()},1e3)})},async onCustom(e){let t={image_id:e.image_id,action:e.action,mode:this.config?.mode||`fast`,async:!0,version:this.config?.version,hd:this.config?.hd||!1,quality:this.config?.quality||`1`};this.onStartImagineTask(t)},async onGenerate(){if(we(this.uploadTracker,e=>this.$t(e),e=>J.warning(e))){if(console.debug(`onGenerate`,this.config),this.config?.type===`videos`){let e={video_id:this.config?.video_id,image_url:this.config?.image_url,action:this.config?.action,prompt:this.config?.prompt,end_image_url:this.config?.end_image_url,resolution:this.config?.resolution,loop:this.config?.loop,mode:this.config?.mode||`fast`,async:!0};await this.onStartVideosTask(e)}else if(this.config?.type===`imagine`){let e=this.config?.version===`8`||this.config?.version===`8.1`,t=!!(this.finalPrompt&&this.finalPrompt.includes(`--sref`)),n=!!(e&&this.config?.references&&this.config.references.length>0),r={mode:this.config?.mode||`fast`,prompt:this.finalPrompt,action:X.GENERATE,translation:this.config?.translation,async:!0,version:this.config?.version,hd:this.config?.hd||!1,quality:this.config?.quality||`1`,style_reference:t,moodboard:n};await this.onStartImagineTask(r)}else if(this.config?.type===`describe`){if(!this.config?.image_url){J.error(this.$t(`midjourney.message.imageUrlRequired`));return}let e={image_url:this.config?.image_url,async:!0};await this.onStartDescribeTask(e)}}},async onScrollDown(){await this.$nextTick();let e=this.getTasksScrollElement();e&&(e.scrollTop=e.scrollHeight)},async onGetTasks(e){if(this.loading||this.fetchingTasks){console.debug(`loading`);return}console.debug(`start onGetTasks`,e);let{limit:t=5,createdAtMin:n,createdAtMax:r}=e||{};console.debug(`limit`,t,`createdAtMin`,n,`createdAtMax`,r),this.fetchingTasks=!0;try{await this.$store.dispatch(`midjourney/getTasks`,{limit:t,createdAtMin:n,createdAtMax:r})}finally{this.fetchingTasks=!1}},getTasksScrollElement(){return this.$refs.taskList?.getScrollElement?.()}}});function la(e,t,n,r,i,o){let s=l(`config-panel`),c=l(`task-list`),u=l(`layout`);return v(),p(u,null,{config:m(()=>[a(s,{onGenerate:e.onGenerate},null,8,[`onGenerate`])]),results:m(()=>[a(c,{ref:`taskList`,loading:e.loadingMore,onCustom:e.onCustom,onReachTop:e.onReachTop},null,8,[`loading`,`onCustom`,`onReachTop`])]),_:1})}var ua=K(ca,[[`render`,la]]);export{ua as default};
@@ -1 +0,0 @@
1
- import"./rolldown-runtime--c01j_DQ.js";import{A as e,Gt as t,I as n,Jt as r,L as i,M as a,N as o,T as s,at as c,ht as l,it as u,j as d,mt as f,rt as p,tt as m,x as h,z as g}from"./vendor-chart-Dw-P17PN.js";import{r as _,t as v}from"./select-CujkF0G4.js";import{t as y}from"./upload-DWCri-Uo.js";import{t as b}from"./tooltip-bADrpFDW.js";import{t as x}from"./alert-BZ-RGZ19.js";import{n as S,r as C}from"./radio-B0Elgaw9.js";import{t as w}from"./drawer-6sGdi_7c.js";import{t as T}from"./switch-LdkfosbU.js";import{n as E}from"./taskDrawerMixin-DhokI8By.js";import{t as D}from"./clock-DL3k6CTu.js";import{t as O}from"./CopyToClipboard-CukvJo1c.js";import{t as k}from"./hash-4hvW7H7n.js";import{t as A}from"./info-BDWHCUui.js";import{t as ee}from"./PromptTextarea-rU0VxEPx.js";import{t as j}from"./triangle-alert-B1k_nXz3.js";import{t as M}from"./upload-kpQsoant.js";import{t as N}from"./wand-sparkles-DMPZy37T.js";import{ui as P}from"./constants-dJ4RJksK.js";import{$t as te,Ai as F,Bt as I,E as L,Hn as R,Ht as z,Vt as B,Wt as V,ei as H,gi as U,mr as W,ri as G,sr as K,zt as q}from"./index-HueVnEkS.js";import{t as J}from"./ImagePreview-C_v2JWDj.js";import{t as Y}from"./Consumption-C9BeeUKY.js";import{a as X,n as Z,r as Q,t as ne}from"./pagination-Ch3ZD0YU.js";import{t as re}from"./vue-plyr-wiIKa-zl.js";import{t as ie}from"./ApiCodeButton-B5bcZfdh.js";import{t as ae}from"./BotPlaceholder-DrrclSPW.js";var oe=g({name:`LayoutPika`,components:{MagicIcon:N,ElDrawer:w,ElButton:F},mixins:[E]}),se={class:`main flex flex-row flex-1`},ce={class:`config w-[320px] flex-none h-full min-h-0 overflow-hidden flex flex-col bg-[var(--app-sidebar-bg)] border-r border-[var(--app-border-subtle)]`},le={class:`result h-full p-6 flex-1 flex flex-col min-w-0 overflow-x-hidden bg-[var(--app-content-bg)]`};function ue(t,n,r,a,s,d){let p=c(`magic-icon`),g=c(`el-button`),_=c(`el-drawer`);return m(),o(`div`,se,[e(`div`,ce,[u(t.$slots,`config`,{},void 0,!0)]),e(`div`,le,[u(t.$slots,`result`,{},void 0,!0)]),l(i(g,{circle:``,class:`menu`,"aria-label":t.$t(`common.button.openMenu`),title:t.$t(`common.button.openMenu`),onClick:n[0]||=e=>t.drawer=!0},{default:f(()=>[i(p,{size:`1em`,"aria-hidden":`true`,focusable:`false`})]),_:1},8,[`aria-label`,`title`]),[[h,!t.tasksEmpty]]),i(_,{modelValue:t.drawer,"onUpdate:modelValue":n[1]||=e=>t.drawer=e,direction:`ltr`,"with-header":!1,size:`340px`,class:`generator-drawer`},{default:f(()=>[u(t.$slots,`config`,{},void 0,!0)]),_:3},8,[`modelValue`])])}var de=L(oe,[[`render`,ue],[`__scopeId`,`data-v-14cc52c3`]]),fe=g({name:`IngredientsSelector`,components:{ElSwitch:T,InfoIcon:X},computed:{value:{get(){return this.$store.state.pika?.config?.ingredients},set(e){if(!e){this.$store.commit(`pika/setConfig`,{...this.$store.state.pika?.config,ingredients:e,ingredients_mode:void 0,image_url:void 0});return}this.$store.commit(`pika/setConfig`,{...this.$store.state.pika?.config,ingredients:e,model:`2.0`})}}},mounted(){this.value===void 0&&(this.value=!1)}}),pe={class:`field`},me={class:`label`},he={class:`title font-bold`};function ge(t,n,a,s,l,u){let d=c(`info-icon`),f=c(`el-switch`);return m(),o(`div`,pe,[e(`div`,me,[e(`h2`,he,r(t.$t(`pika.name.ingredients`)),1),i(d,{content:t.$t(`pika.description.ingredients`),class:`info`},null,8,[`content`])]),i(f,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,class:`value`},null,8,[`modelValue`])])}var _e=L(fe,[[`render`,ge],[`__scopeId`,`data-v-606e1d1a`]]),ve=g({name:`EffectSelector`,components:{ElSelect:_,ElOption:v},data(){return{}},computed:{options(){return[{value:`Levitate`,label:this.$t(`pika.style.effect1`)},{value:`Decapitate`,label:this.$t(`pika.style.effect2`)},{value:`Eye-pop`,label:this.$t(`pika.style.effect3`)},{value:`Ta-da`,label:this.$t(`pika.style.effect4`)},{value:`Deflate`,label:this.$t(`pika.style.effect5`)},{value:`Crumble`,label:this.$t(`pika.style.effect6`)},{value:`Dissolve`,label:this.$t(`pika.style.effect7`)},{value:`Squish`,label:this.$t(`pika.style.effect8`)},{value:`Inflate`,label:this.$t(`pika.style.effect9`)},{value:`Melt`,label:this.$t(`pika.style.effect10`)},{value:`Cake-ify`,label:this.$t(`pika.style.effect11`)},{value:`Crush`,label:this.$t(`pika.style.effect12`)},{value:`Explode`,label:this.$t(`pika.style.effect13`)}]},value:{get(){return this.$store.state.pika?.config?.effect},set(e){this.$store.commit(`pika/setConfig`,{...this.$store.state.pika?.config,effect:e})}}}}),ye={class:`field`},be={class:`title font-bold`},xe={class:`float-left`};function Se(t,n,a,l,u,h){let g=c(`el-option`),_=c(`el-select`);return m(),o(`div`,ye,[e(`h2`,be,r(t.$t(`pika.name.effect`)),1),i(_,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,class:`value`,placeholder:t.$t(`pika.placeholder.select`),clearable:``},{default:f(()=>[(m(!0),o(s,null,p(t.options,t=>(m(),d(g,{key:t.value,label:t.label,value:t.value},{default:f(()=>[e(`span`,xe,r(t.label),1)]),_:2},1032,[`label`,`value`]))),128))]),_:1},8,[`modelValue`,`placeholder`])])}var Ce=L(ve,[[`render`,Se],[`__scopeId`,`data-v-d1c54475`]]),we=g({name:`IngredientsModelSelector`,components:{ElRadioButton:S,ElRadioGroup:C},data(){return{options:[{label:this.$t(`pika.button.precise`),value:`precise`},{label:this.$t(`pika.button.creative`),value:`creative`}]}},computed:{value:{get(){return this.$store.state.pika?.config?.ingredients_mode},set(e){this.$store.commit(`pika/setConfig`,{...this.$store.state.pika?.config,ingredients_mode:e})}}},mounted(){this.value||=P}}),Te={class:`field`},Ee={class:`title font-bold`};function De(t,a,l,u,h,g){let _=c(`el-radio-button`),v=c(`el-radio-group`);return m(),o(`div`,Te,[e(`h2`,Ee,r(t.$t(`pika.name.ingredientsModel`)),1),i(v,{modelValue:t.value,"onUpdate:modelValue":a[0]||=e=>t.value=e,class:`quality`},{default:f(()=>[(m(!0),o(s,null,p(t.options,e=>(m(),d(_,{key:e.value,label:e.value},{default:f(()=>[n(r(e.label),1)]),_:2},1032,[`label`]))),128))]),_:1},8,[`modelValue`])])}var Oe=L(we,[[`render`,De],[`__scopeId`,`data-v-b72865fa`]]),ke=g({name:`ModelSelector`,components:{ElSelect:_,ElOption:v},props:{modelValue:{type:String,default:void 0}},emits:[`update:modelValue`],data(){return{options:[{value:`2.0`,label:`2.0`},{value:`1.5`,label:`1.5`}]}},computed:{value:{get(){return this.$store.state.pika?.config?.model},set(e){this.$store.commit(`pika/setConfig`,{...this.$store.state.pika.config,model:e})}}},mounted(){this.value||=`2.0`}}),Ae={class:`field`},je={class:`title font-bold`};function Me(t,n,a,l,u,h){let g=c(`el-option`),_=c(`el-select`);return m(),o(`div`,Ae,[e(`h2`,je,r(t.$t(`pika.name.model`)),1),i(_,{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,class:`value`,placeholder:t.$t(`pika.placeholder.select`)},{default:f(()=>[(m(!0),o(s,null,p(t.options,e=>(m(),d(g,{key:e.value,label:e.label,value:e.value},null,8,[`label`,`value`]))),128))]),_:1},8,[`modelValue`,`placeholder`])])}var Ne=L(ke,[[`render`,Me],[`__scopeId`,`data-v-7b2e870a`]]),Pe=g({name:`ImageUrlInput`,components:{UploadIcon:M,ElUpload:y,ElButton:F,InfoIcon:X,ImagePreview:J},mixins:[z,I],data(){return{fileList:[],uploadUrl:G()+`/api/v1/files/`}},computed:{headers(){return{Authorization:`Bearer ${this.$store.state.token.access}`}},urls(){return this.fileList.map(e=>e.response?.file_url).filter(e=>!!e)},value(){return this.$store.state.pika?.config?.image_url}},mounted(){this.onSetStartImageUrl()},methods:{onExceed(){U.warning(this.$t(`pika.message.uploadStartImageExceed`))},onError(){U.error(this.$t(`pika.message.uploadStartImageError`))},onRemove(){this.onSetStartImageUrl()},onSetStartImageUrl(){this.$store.commit(`pika/setConfig`,{...this.$store.state.pika?.config,image_url:this.urls})},onSuccess(){this.onSetStartImageUrl()},onRemovePreview(e){let t=this.fileList.indexOf(e);t>=0&&this.fileList.splice(t,1),this.onSetStartImageUrl()}}}),Fe={class:`field`},Ie={class:`label`},Le={class:`title font-bold`},Re={class:`upload-control`};function ze(t,a,s,l,u,d){let p=c(`info-icon`),h=c(`image-preview`),g=c(`upload-icon`),_=c(`el-button`),v=c(`el-upload`);return m(),o(`div`,Fe,[e(`div`,Ie,[e(`h2`,Le,r(t.$t(`pika.name.imageUrl`)),1),i(p,{content:t.$t(`pika.description.imageUrl`),class:`info`},null,8,[`content`])]),e(`div`,Re,[i(v,{ref:`uploader`,"file-list":t.fileList,"onUpdate:fileList":a[0]||=e=>t.fileList=e,accept:`.png,.jpg,.jpeg,.gif,.bmp,.webp`,name:`file`,class:`value upload-wrapper`,limit:3,multiple:!0,"list-type":`picture`,action:t.uploadUrl,"on-exceed":t.onExceed,"on-error":t.onError,"on-remove":t.onRemove,"on-success":t.onSuccess,headers:t.headers},{file:f(({file:e})=>[i(h,{url:e.url||e.response?.file_url,name:e.name,percentage:e.percentage,onRemove:n=>t.onRemovePreview(e)},null,8,[`url`,`name`,`percentage`,`onRemove`])]),default:f(()=>[i(_,{size:`small`,type:`primary`,round:``},{default:f(()=>[i(g,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),n(` `+r(t.$t(`pika.button.uploadImageUrl`)),1)]),_:1})]),_:1},8,[`file-list`,`action`,`on-exceed`,`on-error`,`on-remove`,`on-success`,`headers`])])])}var Be=L(Pe,[[`render`,ze],[`__scopeId`,`data-v-c8a81acf`]]),Ve=g({name:`PromptInput`,components:{PromptTextarea:ee},computed:{prompt:{get(){return this.$store.state.pika?.config?.prompt},set(e){this.$store.commit(`pika/setConfig`,{...this.$store.state.pika?.config,prompt:e})}}},mounted(){this.prompt||=``}});function He(e,t,n,r,i,a){let o=c(`prompt-textarea`);return m(),d(o,{modelValue:e.prompt,"onUpdate:modelValue":t[0]||=t=>e.prompt=t,title:e.$t(`pika.name.prompt`),info:e.$t(`pika.description.prompt`),placeholder:e.$t(`pika.placeholder.prompt`)},null,8,[`modelValue`,`title`,`info`,`placeholder`])}var Ue=g({name:`PresetPanel`,components:{MagicIcon:N,ImageUrlInput:Be,ElButton:F,Consumption:Y,PromptInput:L(Ve,[[`render`,He]]),IngredientsSelector:_e,IngredientsModelSelector:Oe,ModelSelector:Ne,EffectSelector:Ce},emits:[`generate`],computed:{config(){return this.$store.state.pika?.config},consumption(){return V(this.config,this.service?.cost)},service(){return this.$store.state.pika?.service}},methods:{onGenerate(){this.$emit(`generate`)}}}),We={class:`flex flex-col h-full`},Ge={class:`flex-1 overflow-y-auto p-5`},Ke={class:`flex flex-col items-center justify-center px-5 pb-5`};function qe(t,s,l,u,p,h){let g=c(`prompt-input`),_=c(`model-selector`),v=c(`ingredients-selector`),y=c(`effect-selector`),b=c(`image-url-input`),x=c(`ingredients-model-selector`),S=c(`consumption`),C=c(`magic-icon`),w=c(`el-button`);return m(),o(`div`,We,[e(`div`,Ge,[i(g,{class:`mb-4`}),i(_,{class:`mb-4`}),i(v,{class:`mb-4`}),i(y,{class:`mb-4`}),t.config?.ingredients?(m(),d(b,{key:0,class:`mb-4`})):a(``,!0),t.config?.ingredients?(m(),d(x,{key:1,class:`mb-4`})):a(``,!0)]),e(`div`,Ke,[i(S,{value:t.consumption,service:t.service},null,8,[`value`,`service`]),i(w,{type:`primary`,class:`btn w-full`,round:``,onClick:t.onGenerate},{default:f(()=>[i(C,{class:`mr-2`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),n(` `+r(t.$t(`pika.button.generate`)),1)]),_:1},8,[`onClick`])])])}var Je=L(Ue,[[`render`,qe]]),Ye=g({name:`VideoPlayer`,components:{VuePlyr:re},props:{modelValue:{type:Object,required:!0}},data(){return{options:{quality:{default:1080,options:[1080]}}}}}),Xe=[`data-poster`],Ze=[`src`];function Qe(t,n,r,a,s,l){let u=c(`vue-plyr`);return m(),o(`div`,null,[i(u,{options:t.options,class:`video`},{default:f(()=>[e(`video`,{controls:``,playsinline:``,preload:`metadata`,"data-poster":t.modelValue?.image_url},[e(`source`,{size:`1080`,src:t.modelValue?.video_url,type:`video/mp4`},null,8,Ze)],8,Xe)]),_:1},8,[`options`])])}var $e=g({name:`TaskPreview`,components:{ChannelIcon:k,InfoIcon:A,MagicIcon:N,TimeIcon:D,WarningIcon:j,CopyToClipboard:O,ElAlert:x,VideoPlayer:L(Ye,[[`render`,Qe],[`__scopeId`,`data-v-897d9fe0`]]),ElTooltip:b,ElButton:F,ApiCodeButton:ie},props:{modelValue:{type:Object,required:!0}},data(){return{}},computed:{application(){return this.$store.state.pika?.application},config(){return this.$store.state.pika?.config},videos(){let e=[],t=this.modelValue?.request?.action;return Array.isArray(this.modelValue?.response?.data)&&this.modelValue?.response?.data?.forEach(n=>{let r=n;t&&(r.action=t),e.push(r)}),e}},methods:{onDownload(e){console.log(`on download`),window.open(e,`_blank`)},onReload(e){let t=e.target,n=new URL(t.src),r=n.searchParams.get(`retry`);if(!r)n.searchParams.set(`retry`,`1`);else if(parseInt(r)<2)n.searchParams.set(`retry`,(parseInt(r)+1).toString());else return;t.src=n.toString()},onOpenVideo(e){window.open(e,`_blank`)}}}),et={class:`left`},tt={class:`main`},nt={class:`bot`},rt={class:`datetime`},it={class:`info`},at={key:0,class:`prompt mt-2`},ot={key:0},st={key:1},ct={key:0,class:t({content:!0,failed:!0})},lt={class:`image-wrapper`},ut={key:0,class:t({operations:!0,"mt-2":!0})},dt={key:0,class:`description`},ft={class:`description`},pt={key:1,class:`description`},mt={key:1,class:t({content:!0})},ht={class:`description`},gt={class:`description`},_t={key:0,class:`description`},vt={class:`description`},yt={key:2,class:t({content:!0})},$={class:`description`};function bt(t,l,u,h,g,_){let v=c(`capability-presentation`),y=c(`VideoPlayer`),b=c(`el-button`),x=c(`el-tooltip`),S=c(`api-code-button`),C=c(`channel-icon`),w=c(`magic-icon`),T=c(`copy-to-clipboard`),E=c(`time-icon`),D=c(`el-alert`),O=c(`warning-icon`),k=c(`info-icon`);return m(!0),o(s,null,p(t.videos,(s,c)=>(m(),o(`div`,{key:c,class:`preview`},[e(`div`,et,[i(v,{capability:`pika`,part:`avatar`,class:`avatar`})]),e(`div`,tt,[e(`div`,nt,[i(v,{capability:`pika`,part:`name`}),e(`span`,rt,r(t.$dayjs.format(``+new Date(parseFloat((t.modelValue?.created_at||``).toString())*1e3))),1)]),e(`div`,it,[t.modelValue?.request?.prompt?(m(),o(`p`,at,[n(r(t.modelValue?.request?.prompt)+` `,1),t.modelValue?.response?a(``,!0):(m(),o(`span`,ot,` - (`+r(t.$t(`pika.status.pending`))+`) `,1)),s?.state===`processing`||s?.state===`pending`?(m(),o(`span`,st,` - (`+r(t.$t(`pika.status.processing`))+`) `,1)):a(``,!0)])):a(``,!0)]),t.modelValue?.response?.success===!0?(m(),o(`div`,ct,[e(`div`,lt,[i(y,{"model-value":s},null,8,[`model-value`])]),s?(m(),o(`div`,ut,[i(x,{class:`box-item`,effect:`dark`,content:t.$t(`pika.message.downloadVideo`),placement:`top-start`},{default:f(()=>[s?.video_url?(m(),d(b,{key:0,type:`info`,size:`small`,class:`btn-action`,onClick:e=>t.onDownload(s?.video_url)},{default:f(()=>[n(r(t.$t(`pika.button.download`)),1)]),_:1},8,[`onClick`])):a(``,!0)]),_:2},1032,[`content`]),i(S,{path:`/pika/videos`,body:t.modelValue?.request},null,8,[`body`])])):a(``,!0),i(D,{closable:!1,class:`mt-2 success`},{default:f(()=>[t.modelValue?.request?.model?(m(),o(`p`,dt,[i(C,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),n(` `+r(t.$t(`pika.name.model`))+`: `+r(t.modelValue?.request?.model),1)])):a(``,!0),e(`p`,ft,[i(w,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),n(` `+r(t.$t(`pika.name.taskId`))+`: `+r(t.modelValue?.id)+` `,1),i(T,{content:t.modelValue?.id,class:`btn-copy`},null,8,[`content`])]),t.modelValue?.elapsed?(m(),o(`p`,pt,[i(E,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),n(` `+r(t.$t(`pika.name.elapsed`))+`: `+r(t.modelValue?.elapsed?.toFixed(2))+`s `,1)])):a(``,!0)]),_:1})])):a(``,!0),t.modelValue?.response?.success===!1?(m(),o(`div`,mt,[i(D,{closable:!1,class:`failure`},{template:f(()=>[i(O,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),n(` `+r(t.$t(`pika.name.failure`)),1)]),default:f(()=>[e(`p`,ht,[i(w,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),n(` `+r(t.$t(`pika.name.taskId`))+`: `+r(t.modelValue?.id)+` `,1),i(T,{content:t.modelValue?.id,class:`btn-copy`},null,8,[`content`])]),e(`p`,gt,[i(k,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),n(` `+r(t.$t(`pika.name.failureReason`))+`: `+r(t.modelValue?.response?.error?.message)+` `,1),i(T,{content:t.modelValue?.response?.error?.message,class:`btn-copy`},null,8,[`content`])]),t.modelValue?.elapsed?(m(),o(`p`,_t,[i(E,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),n(` `+r(t.$t(`pika.name.elapsed`))+`: `+r(t.modelValue?.elapsed?.toFixed(2))+`s `,1)])):a(``,!0),e(`p`,vt,[i(C,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),n(` `+r(t.$t(`pika.name.traceId`))+`: `+r(t.modelValue?.response?.trace_id)+` `,1),i(T,{content:t.modelValue?.response?.trace_id,class:`btn-copy`},null,8,[`content`])])]),_:1})])):a(``,!0),!t.modelValue?.response||s?.state===`processing`||s?.state===`pending`?(m(),o(`div`,yt,[i(D,{closable:!1,class:`info`},{template:f(()=>[i(O,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),n(` `+r(t.$t(`pika.name.failure`)),1)]),default:f(()=>[e(`p`,$,[i(w,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),n(` `+r(t.$t(`pika.name.taskId`))+`: `+r(t.modelValue?.id)+` `,1),i(T,{content:t.modelValue?.id,class:`btn-copy`},null,8,[`content`])])]),_:1})])):a(``,!0)])]))),128)}var xt=g({name:`RecentPanel`,components:{TaskPreview:L($e,[[`render`,bt],[`__scopeId`,`data-v-42d25aa6`]]),BotPlaceholder:ae,NoTasks:Q,ScrollList:Z},props:{loading:{type:Boolean,default:!1}},emits:[`reach-top`],data(){return{job:0}},computed:{tasks(){return{...this.$store.state.pika?.tasks,items:this.$store.state.pika?.tasks?.items?.slice()}}},methods:{getScrollElement(){return this.$refs.scrollList?.getScrollElement?.()}}}),St={key:0},Ct={key:2,class:`w-full h-full flex items-center justify-center`};function wt(e,t,n,r,l,u){let h=c(`bot-placeholder`),g=c(`task-preview`),_=c(`scroll-list`),v=c(`no-tasks`);return m(),o(s,null,[e.tasks?.items===void 0?(m(),o(`div`,St,[i(h)])):e.tasks?.items?.length&&e.tasks?.items?.length>0?(m(),d(_,{key:1,ref:`scrollList`,class:`tasks h-full w-full overflow-y-auto`,loading:e.loading,onReachTop:t[0]||=t=>e.$emit(`reach-top`)},{default:f(()=>[(m(!0),o(s,null,p(e.tasks?.items,(e,t)=>(m(),d(g,{key:t,"model-value":e},null,8,[`model-value`]))),128))]),_:1},8,[`loading`])):a(``,!0),e.tasks?.items?.length===0?(m(),o(`div`,Ct,[i(v)])):a(``,!0)],64)}var Tt=g({name:`PikaIndex`,components:{ConfigPanel:Je,Layout:de,RecentPanel:L(xt,[[`render`,wt]])},mixins:[B],inject:[`initialized`],data(){return{task:void 0,job:0,loadingMore:!1,fetchingTasks:!1}},computed:{applicationsLoading(){return this.$store.state.pika?.status?.getApplications===H.Request},tasksLoading(){return this.$store.state.pika?.status?.getTasks===H.Request||this.fetchingTasks},service(){return this.$store.state.pika.service},credential(){return this.$store.state.pika.credential},config(){return this.$store.state.pika.config},initializing(){return this.$store.state.pika.status.getApplications===H.Request},needApply(){return this.$store.state.pika.status.getApplications===H.Success&&!this.application},application(){return this.$store.state.pika.application},applications(){return this.$store.state.pika.applications},tasks(){return this.$store.state.pika.tasks}},watch:{tasks:{handler(e,t){e?.items?.length>t?.items?.length&&console.debug(`new tasks detected`)},deep:!0},initialized:{async handler(e){e&&(console.debug(`layout initialized`),await this.onGetTasks(),await this.onScrollDown(),this.job=window.setInterval(()=>{this.onGetTasks()},5e3))},immediate:!0}},async mounted(){await this.onGetService()},async unmounted(){window.clearInterval(this.job)},methods:{async onReachTop(){await ne({tasks:this.tasks,getTasks:()=>this.tasks,loading:this.loadingMore,setLoading:e=>this.loadingMore=e,isBlocked:()=>this.tasksLoading||this.applicationsLoading,fetch:e=>this.onGetTasks({createdAtMax:e}),getScrollElement:()=>this.getTasksScrollElement()})},async onGetService(){console.debug(`start onGetService`),await this.$store.dispatch(`pika/getService`),console.debug(`end onGetService`)},async onGetApplication(){console.debug(`start onGetApplication`),await this.$store.dispatch(`pika/getApplications`),console.debug(`end onGetApplication`),await this.onGetTasks()},onApply(){K.create({application:this.application}).then(({data:e})=>{this.application=e,U.success(this.$t(`application.message.applySuccessfully`))}).catch(e=>{e?.response?.data?.code===`duplication`&&U.error(this.$t(`application.message.alreadyApplied`))})},async onScrollDown(){await this.$nextTick();let e=this.getTasksScrollElement();e&&(e.scrollTop=e.scrollHeight)},async onGetTasks(e){if(this.applicationsLoading||this.fetchingTasks){console.debug(`loading`);return}console.debug(`start onGetTasks`,e);let{limit:t=5,createdAtMin:n,createdAtMax:r}=e||{};console.debug(`limit`,t,`createdAtMin`,n,`createdAtMax`,r),this.fetchingTasks=!0;try{await this.$store.dispatch(`pika/getTasks`,{limit:t,createdAtMin:n,createdAtMax:r})}finally{this.fetchingTasks=!1}},async onGenerate(){if(!q(this.uploadTracker,e=>this.$t(e),e=>U.warning(e)))return;let e={...this.config,async:!0};if(!te())return;let t=this.credential?.token;if(!t){console.error(`no token specified`);return}U.info(this.$t(`pika.message.startingTask`)),W(`pika`,R.generate(e,{token:t})).then(()=>{U.success(this.$t(`pika.message.startTaskSuccess`)),this.$store.commit(`pika/setConfig`,{config:void 0})}).catch(e=>{(e?.response?.data)?.error?.code===`used_up`?U.error(this.$t(`pika.message.usedUp`)):U.error(this.$t(`pika.message.startTaskFailed`))}).finally(async()=>{setTimeout(async()=>{await this.onGetTasks(),await this.onScrollDown()},1e3)})},getTasksScrollElement(){return this.$refs.recentPanel?.getScrollElement?.()}}});function Et(e,t,n,r,a,o){let s=c(`config-panel`),l=c(`recent-panel`),u=c(`layout`);return m(),d(u,null,{config:f(()=>[i(s,{onGenerate:e.onGenerate},null,8,[`onGenerate`])]),result:f(()=>[i(l,{ref:`recentPanel`,class:`panel recent`,loading:e.loadingMore,onReachTop:e.onReachTop},null,8,[`loading`,`onReachTop`])]),_:1})}var Dt=L(Tt,[[`render`,Et],[`__scopeId`,`data-v-fee6c9ea`]]);export{Dt as default};
@@ -1 +0,0 @@
1
- import"./rolldown-runtime--c01j_DQ.js";import{A as e,C as t,I as n,Jt as r,L as i,M as a,N as o,S as s,T as c,at as l,ht as u,it as d,j as f,mt as p,ot as m,rt as h,tt as g,x as _,z as v}from"./vendor-chart-Dw-P17PN.js";import{W as y}from"./use-deprecated-DjO24JGR.js";import{r as b,t as x}from"./select-CujkF0G4.js";import{n as S,t as C}from"./tabs-sABJZ_9N.js";import{t as w}from"./upload-DWCri-Uo.js";import{t as T}from"./tooltip-bADrpFDW.js";import{t as E}from"./avatar-yUP-HfhX.js";import{n as D,r as O}from"./radio-B0Elgaw9.js";import{n as k,t as A}from"./collapse-EJr86ZoB.js";import{t as j}from"./drawer-6sGdi_7c.js";import{n as M,r as N,t as P}from"./dropdown-BXFl7YRh.js";import{t as F}from"./input-number-Dm870X3x.js";import{n as ee,t as I}from"./skeleton-BVbQKb45.js";import{t as L}from"./slider-c_kWhhvW.js";import{t as R}from"./switch-LdkfosbU.js";import{n as te}from"./taskDrawerMixin-DhokI8By.js";import{i as ne,n as re,r as z,t as ie}from"./Player-DwN59ij5.js";import{n as ae}from"./CodeSnippet-A0C7QuGm.js";import{t as oe}from"./download-CRlrpFkF.js";import{t as se}from"./ellipsis-DQ-JXh1l.js";import{t as ce}from"./image-9JTbfhGo.js";import{t as le}from"./loader-circle-DZ_R4SoH.js";import{t as B}from"./PromptTextarea-rU0VxEPx.js";import{t as V}from"./pause-88Matjz8.js";import{t as H}from"./play-DaJSt9FF.js";import{t as U}from"./upload-kpQsoant.js";import{t as W}from"./wand-sparkles-DMPZy37T.js";import{Jn as ue}from"./constants-dJ4RJksK.js";import{$t as de,Ai as G,Bt as fe,E as K,En as q,Vt as pe,Wt as me,ei as J,gi as Y,mr as he,ri as ge,rn as _e,sr as ve,yi as X,zi as Z,zt as ye}from"./index-HueVnEkS.js";import{t as be}from"./Consumption-C9BeeUKY.js";import{a as Q,i as xe,n as Se,r as Ce,t as we}from"./pagination-Ch3ZD0YU.js";var Te=v({name:`LayoutProducer`,components:{MagicIcon:W,ElDrawer:j,ElButton:G},mixins:[te],data(){return{preview:!1}},computed:{}}),Ee={class:`main flex flex-row flex-1`},De={class:`config w-[320px] flex-none h-full min-h-0 overflow-hidden flex flex-col bg-[var(--app-sidebar-bg)] border-r border-[var(--app-border-subtle)]`},Oe={class:`result h-full flex flex-col flex-1 min-w-0 overflow-x-hidden bg-[var(--app-content-bg)]`},ke={class:`preview h-full w-[300px] flex flex-col`};function Ae(t,n,r,a,s,c){let f=l(`magic-icon`),m=l(`el-button`),h=l(`el-drawer`);return g(),o(`div`,Ee,[e(`div`,De,[d(t.$slots,`config`,{},void 0,!0)]),e(`div`,Oe,[d(t.$slots,`result`,{},void 0,!0)]),e(`div`,ke,[d(t.$slots,`preview`,{},void 0,!0)]),u(i(m,{circle:``,class:`menu`,"aria-label":t.$t(`common.button.openMenu`),title:t.$t(`common.button.openMenu`),onClick:n[0]||=e=>t.drawer=!0},{default:p(()=>[i(f,{size:`1em`,"aria-hidden":`true`,focusable:`false`})]),_:1},8,[`aria-label`,`title`]),[[_,!t.tasksEmpty]]),i(h,{modelValue:t.drawer,"onUpdate:modelValue":n[1]||=e=>t.drawer=e,direction:`ltr`,"with-header":!1,size:`340px`,class:`drawer generator-drawer`},{default:p(()=>[d(t.$slots,`config`,{},void 0,!0)]),_:3},8,[`modelValue`])])}var je=K(Te,[[`render`,Ae],[`__scopeId`,`data-v-6461643a`]]),Me=v({name:`TypeSelector`,components:{ElSelect:b,ElOption:x,ElSwitch:R,InfoIcon:Q},data(){return{options:[{label:`FUZZ-2.0 Pro`,value:`FUZZ-2.0 Pro`,desc:this.$t(`producer.model.fuzz20proDesc`)},{label:`FUZZ-2.0`,value:`FUZZ-2.0`,desc:this.$t(`producer.model.fuzz20desc`)},{label:`FUZZ-2.0 Raw`,value:`FUZZ-2.0 Raw`,desc:this.$t(`producer.model.fuzz20rawDesc`)},{label:`FUZZ-1.1 Pro`,value:`FUZZ-1.1 Pro`,desc:this.$t(`producer.model.fuzz11proDesc`)},{label:`FUZZ-1.1`,value:`FUZZ-1.1`,desc:this.$t(`producer.model.fuzz11desc`)},{label:`FUZZ-1.0 Pro`,value:`FUZZ-1.0 Pro`,desc:this.$t(`producer.model.fuzz10proDesc`)},{label:`FUZZ-1.0`,value:`FUZZ-1.0`,desc:this.$t(`producer.model.fuzz10desc`)},{label:`FUZZ-0.8`,value:`FUZZ-0.8`,desc:this.$t(`producer.model.fuzz08desc`)}]}},computed:{custom:{get(){return this.$store.state.producer?.config?.custom||!1},set(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,custom:e})}},instrumental:{get(){return this.$store.state.producer?.config?.instrumental||!1},set(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,instrumental:e})}},model:{get(){return this.$store.state.producer?.config?.model},set(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,model:e})}}},mounted(){this.model||=ue}}),Ne={class:`mb-3`},Pe={class:`flex items-center mb-1`},Fe={class:`text-sm font-bold`},Ie={class:`model-option`},Le={class:`model-option-name`},Re={class:`model-option-desc`},ze={key:0,class:`flex items-center justify-between mb-3`},Be={class:`flex items-center`},Ve={class:`text-sm font-bold`};function He(t,n,s,u,d,m){let _=l(`el-option`),v=l(`el-select`),y=l(`info-icon`),b=l(`el-switch`);return g(),o(`div`,null,[e(`div`,Ne,[e(`div`,Pe,[e(`span`,Fe,r(t.$t(`producer.name.model`)),1)]),i(v,{modelValue:t.model,"onUpdate:modelValue":n[0]||=e=>t.model=e,class:`w-full model-select`,size:`default`,placeholder:t.$t(`producer.placeholder.select`)},{default:p(()=>[(g(!0),o(c,null,h(t.options,t=>(g(),f(_,{key:t.value,label:t.label,value:t.value},{default:p(()=>[e(`div`,Ie,[e(`span`,Le,r(t.label),1),e(`span`,Re,r(t.desc),1)])]),_:2},1032,[`label`,`value`]))),128))]),_:1},8,[`modelValue`,`placeholder`])]),t.custom?(g(),o(`div`,ze,[e(`div`,Be,[e(`span`,Ve,r(t.$t(`producer.name.instrumental`)),1),i(y,{content:t.$t(`producer.description.instrumental`)},null,8,[`content`])]),i(b,{modelValue:t.instrumental,"onUpdate:modelValue":n[1]||=e=>t.instrumental=e},null,8,[`modelValue`])])):a(``,!0)])}var Ue=K(Me,[[`render`,He],[`__scopeId`,`data-v-42496b9a`]]),We=v({name:`UploadAudio`,components:{UploadIcon:U,ElUpload:w,ElButton:G,ElRadioGroup:O,ElRadioButton:D,InfoIcon:Q},mixins:[fe],emits:[`change`],data(){return{fileList:[],uploadUrl:ge()+`/api/v1/files/`,audioPreviewUrl:null,uploading:!1}},computed:{headers(){return{Authorization:`Bearer ${this.$store.state.token.access}`}},credential(){return this.$store.state.producer.credential},config(){return this.$store.state.producer.config},urls(){return this.fileList.map(e=>e?.response?.file_url)},hasUploadedAudio(){let e=this.$store.state.producer?.config?.action;return e===`upload_extend`||e===`upload_cover`},uploadAction:{get(){return this.$store.state.producer?.config?.action||`upload_extend`},set(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,action:e})}}},watch:{urls:{handler(e){this.$emit(`change`,e)}}},methods:{onExceed(){Y.warning(this.$t(`producer.message.uploadReferencesExceed`))},onError(){this.uploading=!1,Y.error(this.$t(`producer.message.uploadReferencesError`))},async onSuccess(){let e=this.urls?.[0];if(!e){this.uploading=!1;return}this.audioPreviewUrl=e,await this.onGenerateAudioId(e)},async onGenerateAudioId(e){let t={audio_url:e},n=this.credential?.token;if(!n){console.error(`no token specified`),this.uploading=!1;return}this.uploading=!0,Y.info(this.$t(`producer.message.startingUploadAudio`));try{let e=(await q.upload(t,{token:n})).data?.data.audio_id;this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,audio_id:e,action:`upload_extend`}),Y.success(this.$t(`producer.message.startUploadAudioSuccess`))}catch(e){Y.error(e?.response?.data?.error?.message||this.$t(`producer.message.startUploadAudioFailed`))}finally{this.uploading=!1}}}}),Ge={class:`relative`},Ke={class:`flex justify-between items-center mb-2`},qe={class:`flex justify-start items-center`},Je={class:`text-sm font-bold`},Ye={key:0,class:`mb-2`},Xe=[`src`],Ze={key:1,class:`mt-1`};function Qe(t,s,c,u,d,f){let m=l(`info-icon`),h=l(`upload-icon`),_=l(`el-button`),v=l(`el-upload`),y=l(`el-radio-button`),b=l(`el-radio-group`);return g(),o(`div`,Ge,[e(`div`,Ke,[e(`div`,qe,[e(`span`,Je,r(t.$t(`producer.name.referenceAudios`)),1),i(m,{content:t.$t(`producer.description.uploadAudios`)},null,8,[`content`])]),i(v,{"file-list":t.fileList,"onUpdate:fileList":s[0]||=e=>t.fileList=e,name:`file`,limit:1,class:`upload-wrapper inline-upload`,action:t.uploadUrl,accept:`.mp3,.wav,.m4a,audio/*`,"show-file-list":!1,"on-exceed":t.onExceed,"on-error":t.onError,"on-success":t.onSuccess,headers:t.headers},{default:p(()=>[i(_,{round:``,type:`primary`,size:`small`,loading:t.uploading},{default:p(()=>[i(h,{class:`icon mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),n(` `+r(t.$t(`producer.button.uploadAudios`)),1)]),_:1},8,[`loading`])]),_:1},8,[`file-list`,`action`,`on-exceed`,`on-error`,`on-success`,`headers`])]),t.audioPreviewUrl?(g(),o(`div`,Ye,[e(`audio`,{src:t.audioPreviewUrl,controls:``,class:`w-full`},null,8,Xe)])):a(``,!0),t.hasUploadedAudio?(g(),o(`div`,Ze,[i(b,{modelValue:t.uploadAction,"onUpdate:modelValue":s[1]||=e=>t.uploadAction=e,size:`small`},{default:p(()=>[i(y,{value:`upload_extend`},{default:p(()=>[n(r(t.$t(`producer.button.extend`)),1)]),_:1}),i(y,{value:`upload_cover`},{default:p(()=>[n(r(t.$t(`producer.button.cover_music`)),1)]),_:1})]),_:1},8,[`modelValue`])])):a(``,!0)])}var $e=K(We,[[`render`,Qe],[`__scopeId`,`data-v-21707bf3`]]),et=v({name:`PromptInput`,components:{PromptTextarea:B},computed:{prompt:{get(){return this.$store.state.producer?.config?.prompt},set(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,prompt:e})}}},mounted(){this.prompt||=``}});function tt(e,t,n,r,i,a){let o=l(`prompt-textarea`);return g(),f(o,{modelValue:e.prompt,"onUpdate:modelValue":t[0]||=t=>e.prompt=t,title:e.$t(`producer.name.songDescription`),info:e.$t(`producer.description.prompt`),placeholder:e.$t(`producer.placeholder.prompt`),"min-rows":5,"max-rows":14},null,8,[`modelValue`,`title`,`info`,`placeholder`])}var nt=K(et,[[`render`,tt]]),rt=v({name:`LyricInput`,components:{MagicIcon:W,ElInput:Z,ElButton:G,InfoIcon:Q},data(){return{generatingLyrics:!1}},computed:{lyric:{get(){return this.$store.state.producer?.config?.lyric},set(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,lyric:e})}},config(){return this.$store.state.producer?.config},credential(){return this.$store.state.producer?.credential}},mounted(){this.lyric||=``},methods:{async onGenerateLyrics(){let e=this.credential?.token;if(!e)return;let t=this.config?.style||this.config?.title||`a beautiful song`;this.generatingLyrics=!0,Y.info(this.$t(`producer.message.generatingLyrics`));try{let n=(await q.lyric({prompt:t},{token:e})).data?.data;n?.text&&(this.lyric=n.text,n?.title&&!this.config?.title&&this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,lyric:n.text,title:n.title}),Y.success(this.$t(`producer.message.generateLyricsSuccess`)))}catch{Y.error(this.$t(`producer.message.generateLyricsFailed`))}finally{this.generatingLyrics=!1}}}}),it={class:`field`},at={class:`flex items-center justify-between mb-1`},ot={class:`flex items-center`},st={class:`text-sm font-bold`};function ct(t,s,c,u,d,m){let h=l(`info-icon`),_=l(`magic-icon`),v=l(`el-button`),y=l(`el-input`);return g(),o(`div`,it,[e(`div`,at,[e(`div`,ot,[e(`span`,st,r(t.$t(`producer.name.lyrics`)),1),i(h,{content:t.$t(`producer.description.lyrics`)},null,8,[`content`])]),t.config?.action===`extend`?a(``,!0):(g(),f(v,{key:0,size:`small`,loading:t.generatingLyrics,round:``,onClick:t.onGenerateLyrics},{default:p(()=>[t.generatingLyrics?a(``,!0):(g(),f(_,{key:0,class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`})),n(` `+r(t.$t(`producer.button.generate_lyrics`)),1)]),_:1},8,[`loading`,`onClick`]))]),t.config?.action===`extend`?(g(),f(y,{key:1,modelValue:t.lyric,"onUpdate:modelValue":s[1]||=e=>t.lyric=e,rows:5,type:`textarea`,class:`lyrics`,placeholder:t.$t(`producer.placeholder.extend.lyrics`)},null,8,[`modelValue`,`placeholder`])):(g(),f(y,{key:0,modelValue:t.lyric,"onUpdate:modelValue":s[0]||=e=>t.lyric=e,rows:5,type:`textarea`,class:`lyrics`,placeholder:t.$t(`producer.placeholder.lyrics`)},null,8,[`modelValue`,`placeholder`]))])}var lt=K(rt,[[`render`,ct],[`__scopeId`,`data-v-b1a497a4`]]),ut=v({name:`StyleInput`,components:{ElInput:Z,InfoIcon:Q},computed:{style:{get(){return this.$store.state.producer?.config?.style},set(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,style:e})}}}}),dt={class:`field`},ft={class:`flex items-center justify-between mb-1`},pt={class:`flex items-center`},mt={class:`text-sm font-bold`};function ht(t,n,a,s,c,u){let d=l(`info-icon`),f=l(`el-input`);return g(),o(`div`,dt,[e(`div`,ft,[e(`div`,pt,[e(`span`,mt,r(t.$t(`producer.name.style`)),1),i(d,{content:t.$t(`producer.description.style`)},null,8,[`content`])])]),i(f,{modelValue:t.style,"onUpdate:modelValue":n[0]||=e=>t.style=e,rows:2,type:`textarea`,placeholder:t.$t(`producer.placeholder.style`)},null,8,[`modelValue`,`placeholder`])])}var gt=K(ut,[[`render`,ht]]),_t=v({name:`TitleInput`,components:{ElInput:Z,InfoIcon:Q},computed:{title:{get(){return this.$store.state.producer?.config?.title},set(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,title:e})}}}}),vt={class:`field`},yt={class:`flex items-center mb-1`},bt={class:`text-sm font-bold`};function xt(t,n,a,s,c,u){let d=l(`info-icon`),f=l(`el-input`);return g(),o(`div`,vt,[e(`div`,yt,[e(`span`,bt,r(t.$t(`producer.name.title`)),1),i(d,{content:t.$t(`producer.description.title`)},null,8,[`content`])]),i(f,{modelValue:t.title,"onUpdate:modelValue":n[0]||=e=>t.title=e,placeholder:t.$t(`producer.placeholder.title`)},null,8,[`modelValue`,`placeholder`])])}var St=K(_t,[[`render`,xt]]),Ct=v({name:`ExtendFromInput`,components:{ElImage:X,ElIcon:y,ElInputNumber:F,VideoPlay:H,VideoPause:V},data(){return{}},computed:{audio(){return this.$store.state.producer?.config?.audio},value:{get(){return this.$store.state.producer?.config?.continue_at},set(e){console.debug(`set continue_at`,e),this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,continue_at:e?parseInt(e):void 0})}}},mounted(){this.value||=void 0},methods:{handleChange(e){if(e===void 0){this.value=void 0;return}e<0?this.value=0:e>this.audio?.duration?this.value=this.audio?.duration:this.value=e},useFormatDuring:z,onPlay(e){this.$store.dispatch(`producer/setAudio`,{...this.$store.state.producer.audio,...e,state:`playing`}),console.log(`on play`)},onPause(e){this.$store.dispatch(`producer/setAudio`,{...this.$store.state.producer.audio,...e,state:`paused`}),console.log(`on pause`)},onClick(e){this.$store.state?.producer?.audio?.id!==e.id&&this.onPlay({...e,progress:0})}}}),wt={class:`field`},Tt={class:`box`},Et={class:`title font-bold`},Dt={class:`input-wrapper`},Ot={class:`task`},kt={class:`left`},At=[`aria-label`,`title`],jt=[`aria-label`,`title`],Mt={key:2,class:`duration`},Nt={class:`info`},Pt={class:`title`},Ft={class:`style`};function It(n,c,d,f,h,_){let v=l(`el-input-number`),y=l(`el-image`),b=l(`video-pause`),x=l(`el-icon`),S=l(`video-play`),C=m(`loading`);return g(),o(`div`,wt,[e(`div`,Tt,[e(`h2`,Et,r(n.$t(`producer.name.extend`)),1),e(`div`,Dt,[i(v,{modelValue:n.value,"onUpdate:modelValue":c[0]||=e=>n.value=e,class:`value`,min:0,max:n.audio?.duration,controls:!1,placeholder:n.$t(`producer.placeholder.extend.continue_at`),onChange:n.handleChange},null,8,[`modelValue`,`max`,`placeholder`,`onChange`])])]),e(`div`,Ot,[n.audio?(g(),o(`div`,{key:0,class:`audio`,onClick:c[7]||=e=>n.onClick(n.audio)},[u((g(),o(`div`,kt,[i(y,{src:n.audio?.image_url,class:`cover`,fit:`cover`},null,8,[`src`]),n.audio?.audio_url&&n.$store.state?.producer?.audio?.id===n.audio.id&&n.$store.state?.producer?.audio?.state===`playing`?(g(),o(`div`,{key:0,class:`overlay`,role:`button`,tabindex:`0`,"aria-label":n.$t(`common.player.pause`),title:n.$t(`common.player.pause`),onClick:c[1]||=e=>n.onPause(n.audio),onKeydown:[c[2]||=s(t(e=>n.onPause(n.audio),[`stop`,`prevent`]),[`enter`]),c[3]||=s(t(e=>n.onPause(n.audio),[`stop`,`prevent`]),[`space`])]},[i(x,null,{default:p(()=>[i(b,{size:`1em`,"aria-hidden":`true`,focusable:`false`})]),_:1})],40,At)):a(``,!0),n.audio?.audio_url&&(n.$store.state?.producer?.audio?.id!==n.audio.id||n.$store.state?.producer?.audio?.id===n.audio.id&&n.$store.state?.producer?.audio?.state===`paused`)?(g(),o(`div`,{key:1,class:`overlay`,role:`button`,tabindex:`0`,"aria-label":n.$t(`common.player.play`),title:n.$t(`common.player.play`),onClick:c[4]||=e=>n.onPlay(n.audio),onKeydown:[c[5]||=s(t(e=>n.onPlay(n.audio),[`stop`,`prevent`]),[`enter`]),c[6]||=s(t(e=>n.onPlay(n.audio),[`stop`,`prevent`]),[`space`])]},[i(x,null,{default:p(()=>[i(S,{size:`1em`,"aria-hidden":`true`,focusable:`false`})]),_:1})],40,jt)):a(``,!0),n.audio?.duration?(g(),o(`div`,Mt,r(n.useFormatDuring(n.audio?.duration)),1)):a(``,!0)])),[[C,!n.audio?.audio_url]]),e(`div`,Nt,[e(`h2`,Pt,r(n.audio?.title),1),e(`p`,Ft,r(n.audio?.style),1)])])):a(``,!0)])])}var Lt=K(Ct,[[`render`,It],[`__scopeId`,`data-v-96005bd8`]]),Rt=v({name:`CoverFromInput`,components:{ElImage:X,ElIcon:y,VideoPlay:H,VideoPause:V},data(){return{}},computed:{audio(){return this.$store.state.producer?.config?.audio},value:{get(){return this.$store.state.producer?.config?.continue_at},set(e){console.debug(`set continue_at`,e),this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,continue_at:e?parseInt(e):void 0})}}},mounted(){this.value||=void 0},methods:{handleChange(e){e<0?this.value=0:e>this.audio?.duration?this.value=this.audio?.duration:this.value=e},useFormatDuring:z,onPlay(e){this.$store.dispatch(`producer/setAudio`,{...this.$store.state.producer.audio,...e,state:`playing`}),console.log(`on play`)},onPause(e){this.$store.dispatch(`producer/setAudio`,{...this.$store.state.producer.audio,...e,state:`paused`}),console.log(`on pause`)},onClick(e){this.$store.state?.producer?.audio?.id!==e.id&&this.onPlay({...e,progress:0})}}}),zt={class:`field`},Bt={class:`box`},Vt={class:`title font-bold`},Ht={class:`task`},Ut={class:`left`},Wt=[`aria-label`,`title`],Gt=[`aria-label`,`title`],Kt={key:2,class:`duration`},qt={class:`info`},Jt={class:`title`},Yt={class:`style`};function Xt(n,c,d,f,h,_){let v=l(`el-image`),y=l(`video-pause`),b=l(`el-icon`),x=l(`video-play`),S=m(`loading`);return g(),o(`div`,zt,[e(`div`,Bt,[e(`h2`,Vt,r(n.$t(`producer.name.cover`)),1)]),e(`div`,Ht,[n.audio?(g(),o(`div`,{key:0,class:`audio`,onClick:c[6]||=e=>n.onClick(n.audio)},[u((g(),o(`div`,Ut,[i(v,{src:n.audio?.image_url,class:`cover`,fit:`cover`},null,8,[`src`]),n.audio?.audio_url&&n.$store.state?.producer?.audio?.id===n.audio.id&&n.$store.state?.producer?.audio?.state===`playing`?(g(),o(`div`,{key:0,class:`overlay`,role:`button`,tabindex:`0`,"aria-label":n.$t(`common.player.pause`),title:n.$t(`common.player.pause`),onClick:c[0]||=e=>n.onPause(n.audio),onKeydown:[c[1]||=s(t(e=>n.onPause(n.audio),[`stop`,`prevent`]),[`enter`]),c[2]||=s(t(e=>n.onPause(n.audio),[`stop`,`prevent`]),[`space`])]},[i(b,null,{default:p(()=>[i(y,{size:`1em`,"aria-hidden":`true`,focusable:`false`})]),_:1})],40,Wt)):a(``,!0),n.audio?.audio_url&&(n.$store.state?.producer?.audio?.id!==n.audio.id||n.$store.state?.producer?.audio?.id===n.audio.id&&n.$store.state?.producer?.audio?.state===`paused`)?(g(),o(`div`,{key:1,class:`overlay`,role:`button`,tabindex:`0`,"aria-label":n.$t(`common.player.play`),title:n.$t(`common.player.play`),onClick:c[3]||=e=>n.onPlay(n.audio),onKeydown:[c[4]||=s(t(e=>n.onPlay(n.audio),[`stop`,`prevent`]),[`enter`]),c[5]||=s(t(e=>n.onPlay(n.audio),[`stop`,`prevent`]),[`space`])]},[i(b,null,{default:p(()=>[i(x,{size:`1em`,"aria-hidden":`true`,focusable:`false`})]),_:1})],40,Gt)):a(``,!0),n.audio?.duration?(g(),o(`div`,Kt,r(n.useFormatDuring(n.audio?.duration)),1)):a(``,!0)])),[[S,!n.audio?.audio_url]]),e(`div`,qt,[e(`h2`,Jt,r(n.audio?.title),1),e(`p`,Yt,r(n.audio?.style),1)])])):a(``,!0)])])}var Zt=K(Rt,[[`render`,Xt],[`__scopeId`,`data-v-9a4b0b16`]]),Qt=v({name:`VocalGenderSelector`,components:{ElRadioGroup:O,ElRadioButton:D,InfoIcon:Q},computed:{vocalGender:{get(){return this.$store.state.producer?.config?.vocal_gender||``},set(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,vocal_gender:e||void 0})}}}}),$t={class:`mb-2`},en={class:`flex items-center mb-1`},tn={class:`text-sm font-bold`};function nn(t,a,s,c,u,d){let f=l(`info-icon`),m=l(`el-radio-button`),h=l(`el-radio-group`);return g(),o(`div`,$t,[e(`div`,en,[e(`span`,tn,r(t.$t(`producer.name.vocalGender`)),1),i(f,{content:t.$t(`producer.description.vocalGender`)},null,8,[`content`])]),i(h,{modelValue:t.vocalGender,"onUpdate:modelValue":a[0]||=e=>t.vocalGender=e},{default:p(()=>[i(m,{value:``},{default:p(()=>[n(r(t.$t(`producer.gender.auto`)),1)]),_:1}),i(m,{value:`f`},{default:p(()=>[n(r(t.$t(`producer.gender.female`)),1)]),_:1}),i(m,{value:`m`},{default:p(()=>[n(r(t.$t(`producer.gender.male`)),1)]),_:1})]),_:1},8,[`modelValue`])])}var rn=K(Qt,[[`render`,nn]]),an=v({name:`AdvancedParams`,components:{ElCollapse:A,ElCollapseItem:k,ElInput:Z,ElSlider:L,ElInputNumber:F,InfoIcon:Q},data(){return{activeNames:[]}},computed:{config(){return this.$store.state.producer?.config},styleNegative:{get(){return this.$store.state.producer?.config?.style_negative||``},set(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,style_negative:e||void 0})}},lyricPrompt:{get(){return this.$store.state.producer?.config?.lyric_prompt||``},set(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,lyric_prompt:e||void 0})}},weirdness:{get(){return this.$store.state.producer?.config?.weirdness??.5},set(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,weirdness:e})}},soundStrength:{get(){return this.$store.state.producer?.config?.sound_strength??.7},set(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,sound_strength:e})}},lyricsStrength:{get(){return this.$store.state.producer?.config?.lyrics_strength??.7},set(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,lyrics_strength:e})}},seed:{get(){return this.$store.state.producer?.config?.seed},set(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,seed:e})}}},mounted(){let e=this.$store.state.producer?.config;if(!e)return;let t={};typeof e.weirdness==`number`&&e.weirdness>1&&(t.weirdness=e.weirdness/100),typeof e.sound_strength==`number`&&e.sound_strength>1&&(t.sound_strength=e.sound_strength/100),typeof e.lyrics_strength==`number`&&e.lyrics_strength>1&&(t.lyrics_strength=e.lyrics_strength/100),Object.keys(t).length>0&&this.$store.commit(`producer/setConfig`,{...e,...t})}}),on={key:0,class:`mb-3`},sn={class:`flex items-center mb-1`},cn={class:`text-xs font-bold`},ln={key:1,class:`mb-3`},un={class:`flex items-center mb-1`},dn={class:`text-xs font-bold`},fn={class:`mb-3`},pn={class:`flex items-center justify-between mb-1`},mn={class:`flex items-center`},hn={class:`text-xs font-bold`},gn={class:`text-xs text-[var(--el-text-color-secondary)]`},_n={class:`mb-3`},vn={class:`flex items-center justify-between mb-1`},yn={class:`flex items-center`},bn={class:`text-xs font-bold`},xn={class:`text-xs text-[var(--el-text-color-secondary)]`},Sn={key:2,class:`mb-3`},Cn={class:`flex items-center justify-between mb-1`},wn={class:`flex items-center`},Tn={class:`text-xs font-bold`},En={class:`text-xs text-[var(--el-text-color-secondary)]`},Dn={class:`mb-3`},On={class:`flex items-center mb-1`},kn={class:`text-xs font-bold`};function An(t,n,s,c,u,d){let m=l(`info-icon`),h=l(`el-input`),_=l(`el-slider`),v=l(`el-input-number`),y=l(`el-collapse-item`),b=l(`el-collapse`);return g(),f(b,{modelValue:t.activeNames,"onUpdate:modelValue":n[6]||=e=>t.activeNames=e,class:`advanced-collapse`},{default:p(()=>[i(y,{title:t.$t(`producer.name.advancedParams`),name:`advanced`},{default:p(()=>[t.config?.custom?(g(),o(`div`,on,[e(`div`,sn,[e(`span`,cn,r(t.$t(`producer.name.styleNegative`)),1),i(m,{content:t.$t(`producer.description.styleNegative`)},null,8,[`content`])]),i(h,{modelValue:t.styleNegative,"onUpdate:modelValue":n[0]||=e=>t.styleNegative=e,size:`small`,placeholder:t.$t(`producer.placeholder.styleNegative`)},null,8,[`modelValue`,`placeholder`])])):a(``,!0),t.config?.custom&&!t.config?.instrumental?(g(),o(`div`,ln,[e(`div`,un,[e(`span`,dn,r(t.$t(`producer.name.lyricPrompt`)),1),i(m,{content:t.$t(`producer.description.lyricPrompt`)},null,8,[`content`])]),i(h,{modelValue:t.lyricPrompt,"onUpdate:modelValue":n[1]||=e=>t.lyricPrompt=e,size:`small`,placeholder:t.$t(`producer.placeholder.lyricPrompt`)},null,8,[`modelValue`,`placeholder`])])):a(``,!0),e(`div`,fn,[e(`div`,pn,[e(`div`,mn,[e(`span`,hn,r(t.$t(`producer.name.weirdness`)),1),i(m,{content:t.$t(`producer.description.weirdness`)},null,8,[`content`])]),e(`span`,gn,r(t.weirdness??.5),1)]),i(_,{modelValue:t.weirdness,"onUpdate:modelValue":n[2]||=e=>t.weirdness=e,min:0,max:1,step:.01},null,8,[`modelValue`])]),e(`div`,_n,[e(`div`,vn,[e(`div`,yn,[e(`span`,bn,r(t.$t(`producer.name.soundStrength`)),1),i(m,{content:t.$t(`producer.description.soundStrength`)},null,8,[`content`])]),e(`span`,xn,r(t.soundStrength??.7),1)]),i(_,{modelValue:t.soundStrength,"onUpdate:modelValue":n[3]||=e=>t.soundStrength=e,min:.2,max:1,step:.01},null,8,[`modelValue`])]),t.config?.custom&&!t.config?.instrumental?(g(),o(`div`,Sn,[e(`div`,Cn,[e(`div`,wn,[e(`span`,Tn,r(t.$t(`producer.name.lyricsStrength`)),1),i(m,{content:t.$t(`producer.description.lyricsStrength`)},null,8,[`content`])]),e(`span`,En,r(t.lyricsStrength??.7),1)]),i(_,{modelValue:t.lyricsStrength,"onUpdate:modelValue":n[4]||=e=>t.lyricsStrength=e,min:0,max:1,step:.01},null,8,[`modelValue`])])):a(``,!0),e(`div`,Dn,[e(`div`,On,[e(`span`,kn,r(t.$t(`producer.name.seed`)),1),i(m,{content:t.$t(`producer.description.seed`)},null,8,[`content`])]),i(v,{modelValue:t.seed,"onUpdate:modelValue":n[5]||=e=>t.seed=e,min:0,controls:!1,size:`small`,placeholder:t.$t(`producer.placeholder.seed`),class:`w-full`},null,8,[`modelValue`,`placeholder`])])]),_:1},8,[`title`])]),_:1},8,[`modelValue`])}var jn=K(an,[[`render`,An],[`__scopeId`,`data-v-f9296888`]]),Mn=v({name:`ReplaceSectionInput`,components:{ElInputNumber:F,ElImage:X,InfoIcon:Q},computed:{audio(){return this.$store.state.producer?.config?.audio},replaceSectionStart:{get(){return this.$store.state.producer?.config?.replace_section_start},set(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,replace_section_start:e})}},replaceSectionEnd:{get(){return this.$store.state.producer?.config?.replace_section_end},set(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,replace_section_end:e})}}},methods:{onClick(e){this.$store.dispatch(`producer/setAudio`,{...this.$store.state.producer.audio,...e,state:`playing`})}}}),Nn={class:`field`},Pn={class:`flex items-center mb-2`},Fn={class:`text-sm font-bold m-0`},In={key:0,class:`task mb-2`},Ln={class:`left relative w-[50px] h-[50px] mr-3 flex-shrink-0`},Rn={class:`info flex-1 min-w-0`},zn={class:`text-sm font-bold m-0 truncate`},Bn={class:`text-xs text-[var(--el-text-color-secondary)] m-0 truncate`},Vn={class:`flex gap-2`};function Hn(t,n,s,c,d,f){let p=l(`info-icon`),h=l(`el-image`),_=l(`el-input-number`),v=m(`loading`);return g(),o(`div`,Nn,[e(`div`,Pn,[e(`h2`,Fn,r(t.$t(`producer.name.replaceSection`)),1),i(p,{content:t.$t(`producer.description.replaceSection`)},null,8,[`content`])]),t.audio?(g(),o(`div`,In,[e(`div`,{class:`audio flex items-center`,onClick:n[0]||=e=>t.onClick(t.audio)},[u((g(),o(`div`,Ln,[i(h,{src:t.audio?.image_url,class:`w-full h-full rounded`,fit:`cover`},null,8,[`src`])])),[[v,!t.audio?.audio_url]]),e(`div`,Rn,[e(`h2`,zn,r(t.audio?.title),1),e(`p`,Bn,r(t.audio?.style),1)])])])):a(``,!0),e(`div`,Vn,[i(_,{modelValue:t.replaceSectionStart,"onUpdate:modelValue":n[1]||=e=>t.replaceSectionStart=e,class:`flex-1`,min:0,max:t.audio?.duration,controls:!1,placeholder:t.$t(`producer.placeholder.replaceSectionStart`)},null,8,[`modelValue`,`max`,`placeholder`]),i(_,{modelValue:t.replaceSectionEnd,"onUpdate:modelValue":n[2]||=e=>t.replaceSectionEnd=e,class:`flex-1`,min:t.replaceSectionStart||0,max:t.audio?.duration,controls:!1,placeholder:t.$t(`producer.placeholder.replaceSectionEnd`)},null,8,[`modelValue`,`min`,`max`,`placeholder`])])])}var Un=v({name:`PresetPanel`,components:{CleanupIcon:ne,MagicIcon:W,TypeSelector:Ue,PromptInput:nt,LyricInput:lt,StyleInput:gt,TitleInput:St,ExtendFromInput:Lt,CoverFromInput:Zt,UploadAudio:$e,VocalGenderSelector:rn,AdvancedParams:jn,ReplaceSectionInput:K(Mn,[[`render`,Hn]]),ElButton:G,ElTabs:S,ElTabPane:C,Consumption:be},emits:[`generate`],computed:{config(){return this.$store.state.producer?.config},mode:{get(){return this.$store.state.producer?.config?.custom?`custom`:`simple`},set(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,custom:e===`custom`})}},consumption(){return me(this.config,this.service?.cost)},service(){return this.$store.state.producer?.service},generateButtonText(){let e=this.config?.action;return e===`extend`||e===`upload_extend`?this.$t(`producer.button.extend`):e===`cover`||e===`upload_cover`?this.$t(`producer.button.cover_music`):e===`variation`?this.$t(`producer.button.variation`):e===`replace_section`?this.$t(`producer.button.replace_section`):e===`stems`?this.$t(`producer.button.get_stems`):e===`swap_vocals`?this.$t(`producer.button.swap_vocals`):e===`swap_instrumentals`?this.$t(`producer.button.swap_instrumentals`):this.$t(`producer.button.generate`)}},methods:{onGenerate(){this.$emit(`generate`)},onClearAll(){this.$store.commit(`producer/setConfig`,{custom:this.$store.state.producer?.config?.custom||!1,instrumental:!1,prompt:``,lyric:``,style:``,title:``,model:this.$store.state.producer?.config?.model})}}}),Wn={class:`flex flex-col h-full`},Gn={class:`flex-1 min-h-0 overflow-hidden`},Kn={class:`p-5`},qn={class:`p-5`},Jn={class:`flex flex-col items-center justify-center px-5 pb-5 gap-2`},Yn={class:`flex gap-2 w-full`};function Xn(t,s,c,u,d,m){let h=l(`type-selector`),_=l(`upload-audio`),v=l(`prompt-input`),y=l(`extend-from-input`),b=l(`cover-from-input`),x=l(`replace-section-input`),S=l(`advanced-params`),C=l(`el-tab-pane`),w=l(`lyric-input`),T=l(`style-input`),E=l(`title-input`),D=l(`vocal-gender-selector`),O=l(`el-tabs`),k=l(`consumption`),A=l(`cleanup-icon`),j=l(`el-button`),M=l(`magic-icon`);return g(),o(`div`,Wn,[e(`div`,Gn,[i(O,{modelValue:t.mode,"onUpdate:modelValue":s[0]||=e=>t.mode=e,class:`producer-mode-tabs`,stretch:``},{default:p(()=>[i(C,{label:t.$t(`producer.mode.simple`),name:`simple`},{default:p(()=>[e(`div`,Kn,[i(h,{class:`mb-4`}),i(_,{class:`mb-4`}),i(v,{class:`mb-4`}),t.config?.action===`extend`?(g(),f(y,{key:0,class:`mb-4`})):a(``,!0),t.config?.action===`cover`?(g(),f(b,{key:1,class:`mb-4`})):a(``,!0),t.config?.action===`replace_section`?(g(),f(x,{key:2,class:`mb-4`})):a(``,!0),i(S,{class:`mb-4`})])]),_:1},8,[`label`]),i(C,{label:t.$t(`producer.mode.custom`),name:`custom`},{default:p(()=>[e(`div`,qn,[i(h,{class:`mb-4`}),i(_,{class:`mb-4`}),t.config?.instrumental?a(``,!0):(g(),f(w,{key:0,class:`mb-4`})),i(T,{class:`mb-4`}),i(E,{class:`mb-4`}),t.config?.instrumental?a(``,!0):(g(),f(D,{key:1,class:`mb-4`})),t.config?.action===`extend`?(g(),f(y,{key:2,class:`mb-4`})):a(``,!0),t.config?.action===`cover`?(g(),f(b,{key:3,class:`mb-4`})):a(``,!0),t.config?.action===`replace_section`?(g(),f(x,{key:4,class:`mb-4`})):a(``,!0),i(S,{class:`mb-4`})])]),_:1},8,[`label`])]),_:1},8,[`modelValue`])]),e(`div`,Jn,[i(k,{value:t.consumption,service:t.service},null,8,[`value`,`service`]),e(`div`,Yn,[i(j,{class:`flex-1`,onClick:t.onClearAll},{default:p(()=>[i(A,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),n(` `+r(t.$t(`producer.button.clear_all`)),1)]),_:1},8,[`onClick`]),i(j,{type:`primary`,class:`flex-1`,round:``,onClick:t.onGenerate},{default:p(()=>[i(M,{class:`mr-2`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),n(` `+r(t.generateButtonText),1)]),_:1},8,[`onClick`])])])])}var Zn=K(Un,[[`render`,Xn],[`__scopeId`,`data-v-acdfec88`]]),Qn=re(),$n=v({name:`TaskPreview`,components:{CodeIcon:ae,DownloadIcon:oe,MoreIcon:se,ElImage:X,ElIcon:y,ElTooltip:T,VideoPlay:H,VideoPause:V,ElDropdown:P,ElDropdownMenu:N,ElDropdownItem:M,Loading:le,ApiCodeDialog:xe},props:{modelValue:{type:Object,required:!0}},data(){return{isFetchingVideoUrl:!1,isFetchingWav:!1,apiCodeVisible:!1,apiCodePath:`/producer/audios`,apiCodeBody:{}}},computed:{loading(){return this.$store.state.producer?.status?.getApplications===J.Request},showViewCode(){return _e()},credential(){return this.$store.state.producer.credential},config(){return this.$store.state.producer.config},task(){return this.$store.state.producer?.tasks},audios(){let e=this.modelValue?.response?.data??[],t=this.modelValue?.request?.action;return t?e.map(e=>({...e,action:t})):e},application(){return this.$store.state.producer?.application},active(){return this.$store.state.producer?.tasks?.active}},methods:{useFormatDuring:z,onViewCode(){let e=this.modelValue?.request||{},t={};Object.entries(e).forEach(([e,n])=>{e===`application_id`||e===`callback_url`||n!=null&&(typeof n==`string`&&n===``||Array.isArray(n)&&n.length===0||(t[e]=n))}),this.apiCodeBody=t,this.apiCodePath=`/producer/audios`,this.apiCodeVisible=!0},onPlay(e){this.$store.dispatch(`producer/setAudio`,{...this.$store.state.producer.audio,...e,state:`playing`}),console.log(`on play`)},onPause(e){this.$store.dispatch(`producer/setAudio`,{...this.$store.state.producer.audio,...e,state:`paused`}),console.log(`on pause`)},onClick(e){this.$store.state?.producer?.audio?.id!==e.id&&this.onPlay({...e,progress:0})},onExtend(e,t){e?.stopPropagation(),console.debug(`set config`,t),this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,model:t.model,custom:!0,instrumental:!1,style:t.style,action:`extend`,audio:t,audio_id:t.id,continue_at:t.duration})},onDownload(e,t){e&&e?.stopPropagation();let n=new URL(t).pathname,r=n.substring(n.lastIndexOf(`/`)+1);fetch(t).then(e=>e.blob()).then(e=>{(0,Qn.saveAs)(e,r)})},async handleVideoDownload(e){if(e.video_url){this.onDownload(null,e.video_url);return}if(!this.isFetchingVideoUrl)try{this.isFetchingVideoUrl=!0;let t=await this.fetchVideoUrlFromApi(e?.id);console.log(`get videoUrl: ${t}`),e.video_url=t,this.onDownload(null,t)}catch(e){console.error(`get videoUrl failed:`,e),Y.error(this.$t(`producer.message.getVideoUrlFailed`))}finally{this.isFetchingVideoUrl=!1}},async fetchVideoUrlFromApi(e){return new Promise((t,n)=>{let r={audio_id:e},i=this.credential?.token;if(!i){console.error(`no token specified`),n(Error(`No token specified`));return}q.video(r,{token:i}).then(e=>{let r=e.data?.data?.video_url;r?t(r):n(Error(`Video URL not found in response`))}).catch(e=>{n(e)})})},onPreview(e,t){e?.stopPropagation(),window.open(t,`_blank`)},async onGetStems(e){await this.onGenerateAudioUrl(`stems`,e)},onCover(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,model:e.model,custom:!0,instrumental:!1,style:e.style,action:`cover`,audio:e,audio_id:e.id})},onVariation(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,model:e.model,custom:!0,style:e.style,action:`variation`,audio:e,audio_id:e.id})},async onSwapVocals(e){await this.onGenerateAudioUrl(`swap_vocals`,e)},async onSwapInstrumentals(e){await this.onGenerateAudioUrl(`swap_instrumentals`,e)},async onGetAllStems(e){await this.onGenerateAudioUrl(`all_stems`,e)},onReplaceSection(e){this.$store.commit(`producer/setConfig`,{...this.$store.state.producer?.config,model:e.model,custom:!0,instrumental:!1,style:e.style,action:`replace_section`,audio:e,audio_id:e.id,replace_section_start:0,replace_section_end:Math.min(30,e.duration||30)})},async handleWavDownload(e){if(!e?.id||this.isFetchingWav)return;let t=this.credential?.token;if(t)try{this.isFetchingWav=!0,Y.info(this.$t(`producer.message.fetchingWav`));let n=(await q.wav({audio_id:e.id},{token:t})).data?.data,r=Array.isArray(n)?n[0]?.file_url:n?.file_url||n?.audio_url;r?this.onDownload(null,r):Y.error(this.$t(`producer.message.fetchWavFailed`))}catch{Y.error(this.$t(`producer.message.fetchWavFailed`))}finally{this.isFetchingWav=!1}},async onGenerateAudioUrl(e,t){let n={action:e,audio_id:t,async:!0},r=this.credential?.token;if(!r){console.error(`no token specified`);return}Y.info(this.$t(`producer.message.startingTask`)),q.audio(n,{token:r}).then(()=>{Y.success(this.$t(`producer.message.startTaskSuccess`))}).catch(e=>{Y.error(e?.response?.data?.error?.message||this.$t(`producer.message.startTaskFailed`))}).finally(async()=>{await this.onGetTasks(),await this.onScrollDown()})},async onScrollDown(){setTimeout(()=>{let e=document.querySelector(`.tasks`);e&&(e.scrollTop=e.scrollHeight)},1e3)},async onGetTasks(){if(this.loading){console.debug(`loading`);return}await this.$store.dispatch(`producer/getTasks`,{limit:30,offset:0})}}}),er={class:`task`},tr=[`onClick`],nr={class:`left`},rr=[`aria-label`,`title`,`onClick`,`onKeydown`],ir=[`aria-label`,`title`,`onClick`,`onKeydown`],ar={key:2,class:`duration`},or={class:`info`},sr={class:`title`},cr={class:`style`},lr={class:`right`},ur={class:`el-dropdown-link`},dr={class:`flex items-center min-w-[120px]`},fr={class:`flex items-center min-w-[120px]`},pr={class:`el-dropdown-link`};function mr(d,_,v,y,b,x){let S=l(`el-image`),C=l(`video-pause`),w=l(`el-icon`),T=l(`video-play`),E=l(`download-icon`),D=l(`el-tooltip`),O=l(`Loading`),k=l(`el-dropdown-item`),A=l(`el-dropdown-menu`),j=l(`el-dropdown`),M=l(`more-icon`),N=l(`code-icon`),P=l(`api-code-dialog`),F=m(`loading`);return g(),o(`div`,er,[(g(!0),o(c,null,h(d.audios,c=>(g(),o(`div`,{key:c.id,class:`audio`,onClick:t(e=>d.onClick(c),[`stop`])},[u((g(),o(`div`,nr,[i(S,{src:c?.image_url,class:`cover`,fit:`cover`,lazy:``},null,8,[`src`]),c?.audio_url&&d.$store.state?.producer?.audio?.id===c.id&&d.$store.state?.producer?.audio?.state===`playing`?(g(),o(`div`,{key:0,class:`overlay`,role:`button`,tabindex:`0`,"aria-label":d.$t(`common.player.pause`),title:d.$t(`common.player.pause`),onClick:t(e=>d.onPause(c),[`stop`]),onKeydown:[s(t(e=>d.onPause(c),[`stop`,`prevent`]),[`enter`]),s(t(e=>d.onPause(c),[`stop`,`prevent`]),[`space`])]},[i(w,null,{default:p(()=>[i(C,{size:`1em`,"aria-hidden":`true`,focusable:`false`})]),_:1})],40,rr)):a(``,!0),c?.audio_url&&(d.$store.state?.producer?.audio?.id!==c.id||d.$store.state?.producer?.audio?.id===c.id&&d.$store.state?.producer?.audio?.state===`paused`)?(g(),o(`div`,{key:1,class:`overlay`,role:`button`,tabindex:`0`,"aria-label":d.$t(`common.player.play`),title:d.$t(`common.player.play`),onClick:t(e=>d.onPlay(c),[`stop`]),onKeydown:[s(t(e=>d.onPlay(c),[`stop`,`prevent`]),[`enter`]),s(t(e=>d.onPlay(c),[`stop`,`prevent`]),[`space`])]},[i(w,null,{default:p(()=>[i(T,{size:`1em`,"aria-hidden":`true`,focusable:`false`})]),_:1})],40,ir)):a(``,!0),c?.duration?(g(),o(`div`,ar,r(d.useFormatDuring(c?.duration)),1)):a(``,!0)])),[[F,!c?.audio_url]]),e(`div`,or,[e(`h2`,sr,r(c?.title),1),e(`p`,cr,r(c?.style),1)]),e(`div`,lr,[i(j,null,{dropdown:p(()=>[i(A,null,{default:p(()=>[i(k,{disabled:d.isFetchingVideoUrl,onClick:e=>d.handleVideoDownload(c)},{default:p(()=>[e(`div`,dr,[d.isFetchingVideoUrl?(g(),f(w,{key:0,class:`is-loading mr-2`},{default:p(()=>[i(O,{size:`1em`,"aria-hidden":`true`,focusable:`false`})]),_:1})):a(``,!0),e(`span`,null,r(d.$t(`producer.button.download_video`)),1)])]),_:1},8,[`disabled`,`onClick`]),c?.audio_url?(g(),f(k,{key:0,onClick:t(e=>d.onDownload(e,c?.audio_url),[`stop`])},{default:p(()=>[n(r(d.$t(`producer.button.download_audio`)),1)]),_:1},8,[`onClick`])):a(``,!0),i(k,{disabled:d.isFetchingWav,onClick:e=>d.handleWavDownload(c)},{default:p(()=>[e(`div`,fr,[d.isFetchingWav?(g(),f(w,{key:0,class:`is-loading mr-2`},{default:p(()=>[i(O,{size:`1em`,"aria-hidden":`true`,focusable:`false`})]),_:1})):a(``,!0),e(`span`,null,r(d.$t(`producer.button.download_wav`)),1)])]),_:1},8,[`disabled`,`onClick`])]),_:2},1024)]),default:p(()=>[e(`span`,ur,[i(D,{effect:`dark`,content:d.$t(`producer.button.download`),placement:`top`},{default:p(()=>[c?.audio_url||c?.video_url?(g(),f(E,{key:0,class:`icon icon-download`,size:`1em`,"aria-hidden":`true`,focusable:`false`})):a(``,!0)]),_:2},1032,[`content`])])]),_:2},1024),i(j,null,{dropdown:p(()=>[i(A,null,{default:p(()=>[c?.audio_url?(g(),f(k,{key:0,onClick:t(e=>d.onExtend(e,c),[`stop`])},{default:p(()=>[n(r(d.$t(`producer.button.extend`)),1)]),_:1},8,[`onClick`])):a(``,!0),c.id?(g(),f(k,{key:1,onClick:t(e=>d.onGetStems(c.id),[`stop`])},{default:p(()=>[n(r(d.$t(`producer.button.get_stems`)),1)]),_:1},8,[`onClick`])):a(``,!0),c.id?(g(),f(k,{key:2,onClick:t(e=>d.onGetAllStems(c.id),[`stop`])},{default:p(()=>[n(r(d.$t(`producer.button.all_stems`)),1)]),_:1},8,[`onClick`])):a(``,!0),i(k,{onClick:t(e=>d.onCover(c),[`stop`])},{default:p(()=>[n(r(d.$t(`producer.button.cover_music`)),1)]),_:1},8,[`onClick`]),c?.id?(g(),f(k,{key:3,onClick:t(e=>d.onVariation(c),[`stop`])},{default:p(()=>[n(r(d.$t(`producer.button.variation`)),1)]),_:1},8,[`onClick`])):a(``,!0),c?.id?(g(),f(k,{key:4,onClick:t(e=>d.onSwapVocals(c.id),[`stop`])},{default:p(()=>[n(r(d.$t(`producer.button.swap_vocals`)),1)]),_:1},8,[`onClick`])):a(``,!0),c?.id?(g(),f(k,{key:5,onClick:t(e=>d.onSwapInstrumentals(c.id),[`stop`])},{default:p(()=>[n(r(d.$t(`producer.button.swap_instrumentals`)),1)]),_:1},8,[`onClick`])):a(``,!0),c?.id?(g(),f(k,{key:6,onClick:t(e=>d.onReplaceSection(c),[`stop`])},{default:p(()=>[n(r(d.$t(`producer.button.replace_section`)),1)]),_:1},8,[`onClick`])):a(``,!0),d.showViewCode?(g(),f(k,{key:7,onClick:t(d.onViewCode,[`stop`])},{default:p(()=>[i(N,{class:`mr-1`,size:`1em`,"aria-hidden":`true`,focusable:`false`}),n(` `+r(d.$t(`common.button.viewCode`)),1)]),_:1},8,[`onClick`])):a(``,!0)]),_:2},1024)]),default:p(()=>[e(`span`,pr,[i(D,{effect:`dark`,content:d.$t(`producer.button.more`),placement:`top`},{default:p(()=>[c?.audio_url||c?.video_url?(g(),f(M,{key:0,class:`icon icon-ellipsis`,size:`1em`,"aria-hidden":`true`,focusable:`false`})):a(``,!0)]),_:2},1032,[`content`])])]),_:2},1024)])],8,tr))),128)),i(P,{visible:d.apiCodeVisible,"onUpdate:visible":_[0]||=e=>d.apiCodeVisible=e,method:`POST`,path:d.apiCodePath,body:d.apiCodeBody,token:d.$store.state.producer?.credential?.token||``},null,8,[`visible`,`path`,`body`,`token`])])}var $=v({name:`RecentPanel`,components:{ElSkeletonItem:ee,ElSkeleton:I,TaskPreview:K($n,[[`render`,mr]]),Player:ie,NoTasks:Ce,ScrollList:Se},props:{loading:{type:Boolean,default:!1}},emits:[`reach-top`],data(){return{job:0}},computed:{tasks(){return{...this.$store.state.producer?.tasks,items:this.$store.state.producer?.tasks?.items?.slice()}}},methods:{getScrollElement(){return this.$refs.scrollList?.getScrollElement?.()}}}),hr={key:0,class:`tasks`},gr={class:`left w-[70px] p-[10px] flex items-center`},_r={class:`main w-[calc(100%-70px)] flex-1 p-[10px]`},vr={key:2,class:`w-full flex-1 flex items-center justify-center`},yr={class:`h-20`};function br(t,n,r,s,d,m){let v=l(`el-skeleton-item`),y=l(`el-skeleton`),b=l(`task-preview`),x=l(`scroll-list`),S=l(`no-tasks`),C=l(`player`);return g(),o(c,null,[t.tasks?.items===void 0?(g(),o(`div`,hr,[(g(),o(c,null,h(3,t=>e(`div`,{key:t,class:`flex`},[e(`div`,gr,[i(y,{animated:``},{template:p(()=>[i(v,{variant:`image`,class:`avatar w-[50px] h-[50px]`})]),_:1})]),e(`div`,_r,[i(y,{animated:``},{template:p(()=>[i(v,{variant:`p`,class:`w-[200px] h-[15px] mb-[5px] mt-[10px]`}),i(v,{variant:`text`})]),_:1})])])),64))])):t.tasks?.items?.length&&t.tasks?.items?.length>0?(g(),f(x,{key:1,ref:`scrollList`,class:`flex-1 w-full overflow-y-auto tasks p-2`,loading:t.loading,onReachTop:n[0]||=e=>t.$emit(`reach-top`)},{default:p(()=>[(g(!0),o(c,null,h(t.tasks?.items,(e,t)=>(g(),f(b,{key:t,"model-value":e,class:`preview`},null,8,[`model-value`]))),128))]),_:1},8,[`loading`])):a(``,!0),t.tasks?.items?.length===0?(g(),o(`div`,vr,[i(S)])):a(``,!0),u(e(`div`,yr,[i(C,{namespace:`producer`})],512),[[_,!!t.$store?.state?.producer?.audio?.object]])],64)}var xr=K($,[[`render`,br]]),Sr=v({name:`TaskPreview`,components:{IconPicture:ce,ElImage:X,ElAvatar:E,ElIcon:y},computed:{audio(){return this.$store.state.producer?.audio}}}),Cr={key:0,class:`size-full overflow-hidden`},wr={class:`relative h-[300px]`},Tr={class:`flex items-center justify-center size-full bg-[var(--el-bg-color)]`},Er={class:`absolute bottom-0 left-0 right-0 m-0 p-4 text-white z-10 bg-gradient-to-t from-black/70 to-transparent`},Dr={class:`p-4`},Or={class:`flex items-center font-bold mb-2`},kr={class:`text-[var(--el-text-color-regular)] mb-2`},Ar={class:`text-xs text-[var(--el-text-color-regular)]`},jr={class:`mt-4 text-sm leading-[25px] whitespace-pre-wrap`},Mr={key:1,class:`w-full h-full`};function Nr(t,n,a,s,c,u){let d=l(`icon-picture`),f=l(`el-icon`),m=l(`el-image`),h=l(`el-avatar`);return t.audio?.object?(g(),o(`div`,Cr,[e(`div`,wr,[i(m,{src:t.audio.image_url,fit:`cover`,class:`size-full`},{error:p(()=>[e(`div`,Tr,[i(f,{class:`text-3xl`},{default:p(()=>[i(d,{size:`1em`,"aria-hidden":`true`,focusable:`false`})]),_:1})])]),_:1},8,[`src`]),e(`h2`,Er,r(t.audio?.title),1)]),e(`div`,Dr,[e(`div`,Or,[i(h,{size:30,src:t.audio?.image_url,class:`mr-2`},null,8,[`src`]),e(`span`,null,r(t.audio?.title),1)]),e(`p`,kr,r(t.audio?.style),1),e(`p`,Ar,r(t.$dayjs.format(t.audio?.created_at)),1),e(`div`,jr,[e(`p`,null,r(t.audio?.lyric),1)])])])):(g(),o(`div`,Mr))}var Pr=v({name:`ProducerIndex`,components:{Layout:je,ConfigPanel:Zn,RecentPanel:xr,PreviewPanel:K(Sr,[[`render`,Nr]])},mixins:[pe],inject:[`initialized`],data(){return{task:void 0,job:0,loadingMore:!1,fetchingTasks:!1}},computed:{applicationsLoading(){return this.$store.state.producer?.status?.getApplications===J.Request},tasksLoading(){return this.$store.state.producer?.status?.getTasks===J.Request||this.fetchingTasks},service(){return this.$store.state.producer.service},credential(){return this.$store.state.producer.credential},config(){return this.$store.state.producer.config},initializing(){return this.$store.state.producer.status.getApplications===J.Request},needApply(){return this.$store.state.producer.status.getApplications===J.Success&&!this.application},application(){return this.$store.state.producer.application},tasks(){return this.$store.state.producer.tasks},applications(){return this.$store.state.producer.applications}},watch:{tasks:{handler(e,t){e?.items?.length>t?.items?.length&&console.debug(`new tasks detected`)},deep:!0},initialized:{async handler(e){e&&(console.debug(`layout initialized`),await this.onGetTasks(),await this.onScrollDown(),this.job=window.setInterval(()=>{this.onGetTasks()},5e3))},immediate:!0}},async mounted(){await this.onGetService()},async unmounted(){window.clearInterval(this.job)},methods:{async onReachTop(){await we({tasks:this.tasks,getTasks:()=>this.tasks,loading:this.loadingMore,setLoading:e=>this.loadingMore=e,isBlocked:()=>this.tasksLoading||this.applicationsLoading,fetch:e=>this.onGetTasks({createdAtMax:e}),getScrollElement:()=>this.getTasksScrollElement()})},async onGetService(){console.debug(`start onGetService`),await this.$store.dispatch(`producer/getService`),console.debug(`end onGetService`)},async onGetApplication(){console.debug(`start onGetApplications`),await this.$store.dispatch(`producer/getApplications`),console.debug(`end onGetApplications`),await this.onGetTasks()},onApply(){ve.create({application:this.application}).then(({data:e})=>{this.application=e,Y.success(this.$t(`application.message.applySuccessfully`))}).catch(e=>{e?.response?.data?.code===`duplication`&&Y.error(this.$t(`application.message.alreadyApplied`))})},async onScrollDown(){await this.$nextTick();let e=this.getTasksScrollElement();e&&(e.scrollTop=e.scrollHeight)},async onGetTasks(e){if(this.applicationsLoading||this.fetchingTasks){console.debug(`loading`);return}console.debug(`start onGetTasks`,e);let{limit:t=5,createdAtMin:n,createdAtMax:r}=e||{};console.debug(`limit`,t,`createdAtMin`,n,`createdAtMax`,r),this.fetchingTasks=!0;try{await this.$store.dispatch(`producer/getTasks`,{limit:t,createdAtMin:n,createdAtMax:r})}finally{this.fetchingTasks=!1}},async onGenerateAudio(){if(!ye(this.uploadTracker,e=>this.$t(e),e=>Y.warning(e)))return;let e={...this.config,async:!0};if(!de())return;let t=this.credential?.token;if(!t){console.error(`no token specified`);return}Y.info(this.$t(`producer.message.startingTask`)),he(`producer`,q.audio(e,{token:t})).then(()=>{Y.success(this.$t(`producer.message.startTaskSuccess`))}).catch(e=>{Y.error(e?.response?.data?.error?.message||this.$t(`producer.message.startTaskFailed`))}).finally(async()=>{setTimeout(async()=>{await this.onGetTasks(),await this.onScrollDown()},1e3)})},getTasksScrollElement(){return this.$refs.recentPanel?.getScrollElement?.()}}});function Fr(e,t,n,r,a,o){let s=l(`config-panel`),c=l(`recent-panel`),u=l(`preview-panel`),d=l(`layout`);return g(),f(d,null,{config:p(()=>[i(s,{onGenerate:e.onGenerateAudio},null,8,[`onGenerate`])]),result:p(()=>[i(c,{ref:`recentPanel`,class:`panel recent`,loading:e.loadingMore,onReachTop:e.onReachTop},null,8,[`loading`,`onReachTop`])]),preview:p(()=>[i(u)]),_:1})}var Ir=K(Pr,[[`render`,Fr],[`__scopeId`,`data-v-23eb99dc`]]);export{Ir as default};