@socialgen_user/socialgen 2.3.5 → 2.3.7

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 (36) hide show
  1. package/.output/nitro.json +1 -1
  2. package/.output/public/_nuxt/{DiCtzVeW.js → 1ESij7sf.js} +1 -1
  3. package/.output/public/_nuxt/{C5uDHZ0c.js → 8t3Wih-_.js} +2 -2
  4. package/.output/public/_nuxt/{BBjanQfM.js → CpvOZWox.js} +1 -1
  5. package/.output/public/_nuxt/{CnfGkdc7.js → DO1pBuIJ.js} +1 -1
  6. package/.output/public/_nuxt/{DPe4ptnz.js → DR2NdyVN.js} +1 -1
  7. package/.output/public/_nuxt/JDUjn-YJ.js +91 -0
  8. package/.output/public/_nuxt/builds/latest.json +1 -1
  9. package/.output/public/_nuxt/builds/meta/dd531369-b462-4ab9-9c49-be9d1a58097d.json +1 -0
  10. package/.output/public/_nuxt/{BI1zNDAE.js → wZeFhB0j.js} +1 -1
  11. package/.output/public/mobile-demo.html +788 -0
  12. package/.output/server/chunks/_/nitro.mjs +109 -102
  13. package/.output/server/chunks/build/client.precomputed.mjs +1 -1
  14. package/.output/server/chunks/build/client.precomputed.mjs.map +1 -1
  15. package/.output/server/chunks/build/entry-styles.BcjSvkjT.mjs +8 -0
  16. package/.output/server/chunks/build/entry-styles.BcjSvkjT.mjs.map +1 -0
  17. package/.output/server/chunks/build/{pages-N8VcQ5jK.mjs → pages-DAxeAK3-.mjs} +438 -47
  18. package/.output/server/chunks/build/pages-DAxeAK3-.mjs.map +1 -0
  19. package/.output/server/chunks/build/server.mjs +1 -1
  20. package/.output/server/chunks/build/styles.mjs +3 -3
  21. package/.output/server/chunks/routes/api/files/_...path_.get.mjs +1 -0
  22. package/.output/server/chunks/routes/api/files/_...path_.get.mjs.map +1 -1
  23. package/.output/server/chunks/routes/api/media.get.mjs +80 -50
  24. package/.output/server/chunks/routes/api/media.get.mjs.map +1 -1
  25. package/.output/server/package.json +1 -1
  26. package/data/history.json +30 -10
  27. package/data/history_generations.json +222 -0
  28. package/data/last_session.json +25 -26
  29. package/data/templates.json +40 -0
  30. package/package.json +1 -1
  31. package/public/mobile-demo.html +788 -0
  32. package/.output/public/_nuxt/CqJK17qQ.js +0 -91
  33. package/.output/public/_nuxt/builds/meta/899c178a-f247-4574-bc2b-c6f700198071.json +0 -1
  34. package/.output/server/chunks/build/entry-styles.CDUzpOBt.mjs +0 -8
  35. package/.output/server/chunks/build/entry-styles.CDUzpOBt.mjs.map +0 -1
  36. package/.output/server/chunks/build/pages-N8VcQ5jK.mjs.map +0 -1
@@ -1,6 +1,6 @@
1
1
  import { defineComponent, ref, watch, computed, mergeProps, unref, isRef, nextTick, useSSRContext } from 'vue';
2
- import { ssrRenderAttrs, ssrInterpolate, ssrRenderClass, ssrRenderComponent, ssrRenderAttr, ssrIncludeBooleanAttr, ssrLooseContain, ssrLooseEqual, ssrRenderList, ssrRenderStyle } from 'vue/server-renderer';
3
- import { Settings, X, Check, Edit2, Trash2, FileText, Copy, LayoutTemplate, Plus, Code, Wand2, Globe, Sparkles, Bookmark, Clock, CheckCircle2, AlertCircle, RotateCcw, Film, Upload, Scissors, Music, RefreshCw, Play, ZoomOut, ZoomIn, ShieldAlert, Pause, Volume2, VolumeX, Download, FolderOpen } from 'lucide-vue-next';
2
+ import { ssrRenderAttrs, ssrInterpolate, ssrRenderClass, ssrRenderComponent, ssrIncludeBooleanAttr, ssrRenderAttr, ssrLooseContain, ssrLooseEqual, ssrRenderList, ssrRenderStyle } from 'vue/server-renderer';
3
+ import { Settings, X, Check, Edit2, Trash2, FileText, Copy, LayoutTemplate, Plus, Code, AlertCircle, RefreshCw, Film, Upload, Music, Clock, Sparkles, Eye, Bookmark, Wand2, Globe, CheckCircle2, RotateCcw, Scissors, Play, ZoomOut, ZoomIn, ShieldAlert, Pause, Volume2, VolumeX } from 'lucide-vue-next';
4
4
  import { _ as _sfc_main$3 } from './TableCard-0mU9UOj0.mjs';
5
5
  import { z } from 'zod';
6
6
 
@@ -69,6 +69,7 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
69
69
  const templateFormError = ref("");
70
70
  const copiedAiPrompt = ref(false);
71
71
  const showAiPasteBox = ref(false);
72
+ const showAiPromptView = ref(false);
72
73
  const aiImportJsonText = ref("");
73
74
  const templateForm = ref({
74
75
  id: "",
@@ -81,6 +82,86 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
81
82
  promptDirective: "",
82
83
  sampleJsonText: ""
83
84
  });
85
+ const masterVisionPromptText = computed(() => `Bertindaklah sebagai Lead Design Technologist & Senior Frontend Engineer untuk SocialGen (Dynamic Visual Engine for High-CPM Meta Monetization).
86
+
87
+ Saya melampirkan screenshot / gambar desain kartu visual media sosial.
88
+
89
+ Tugas Anda:
90
+ Analisis tata letak visual, dekorasi, tipografi, warna, bingkai, dan struktur konten pada gambar ini, lalu ubah menjadi template visual kustom SocialGen dalam format 1 objek JSON valid persis seperti ini:
91
+
92
+ {
93
+ "id": "slug-unik-kebab-case",
94
+ "name": "Nama Template Unik (Awali dengan Emoji, misal: \u{1F4F0} Orange Pill Hero & News Tablet)",
95
+ "category": "Kategori Template (misal: Edukasi, Finansial, Berita Viral, Ranking, Perbandingan)",
96
+ "description": "Deskripsi singkat 1-2 kalimat mengenai gaya visual dan kegunaan template ini.",
97
+ "layoutType": "custom",
98
+ "customHtml": "<div class=\\"my-container\\">\\n <!-- Header / Hero Section -->\\n <div class=\\"my-hero\\">\\n <div class=\\"my-subtitle\\">{{ data.subtitle }}</div>\\n <div class=\\"my-title-box\\">\\n <h1 class=\\"my-title\\">{{ data.title }}</h1>\\n </div>\\n </div>\\n\\n <!-- Body / Main Content Visual Structure (Tablet / Frame / Pill Cards) -->\\n <div class=\\"my-frame-box\\">\\n {{#each data.items}}\\n <div class=\\"my-item-card\\">\\n <div class=\\"my-item-dot\\"></div>\\n <div class=\\"my-item-text\\">{{ text }}</div>\\n </div>\\n {{/each}}\\n </div>\\n\\n <!-- Footer / Source Attribution -->\\n <div class=\\"my-footer\\">\\n <span class=\\"my-source\\">{{ data.footerNote }}</span>\\n </div>\\n</div>",
99
+ "customCss": ".my-container { width: 100%; max-width: 960px; margin: 0 auto; display: flex; flex-direction: column; gap: 28px; box-sizing: border-box; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; } .my-hero { display: flex; flex-direction: column; gap: 12px; } .my-subtitle { font-size: 24px; font-weight: 800; color: #ffffff; text-shadow: 0 2px 8px rgba(0,0,0,0.4); } .my-title-box { background: #ffffff; border-radius: 24px; padding: 22px 32px; box-shadow: 0 12px 28px rgba(0,0,0,0.25); } .my-title { margin: 0; font-size: 56px; font-weight: 900; line-height: 1.1; color: #d84e1f; text-transform: uppercase; } .my-frame-box { display: flex; flex-direction: column; gap: 16px; background: rgba(30, 41, 59, 0.9); border-radius: 32px; padding: 26px; border: 2px solid rgba(255,255,255,0.15); box-shadow: 0 20px 40px rgba(0,0,0,0.35); } .my-item-card { display: flex; align-items: flex-start; gap: 16px; background: #ffffff; border-radius: 18px; padding: 20px 24px; border-left: 8px solid #eb6a37; box-shadow: 0 4px 12px rgba(0,0,0,0.06); } .my-item-dot { width: 14px; height: 14px; min-width: 14px; border-radius: 50%; background: #f5b027; margin-top: 6px; } .my-item-text { font-size: 22px; font-weight: 700; line-height: 1.45; color: #1e293b; margin: 0; } .my-footer { display: flex; justify-content: center; } .my-source { font-size: 17px; font-weight: 700; color: rgba(255,255,255,0.9); background: rgba(15,23,42,0.6); padding: 10px 22px; border-radius: 999px; border: 1px solid rgba(255,255,255,0.2); text-shadow: 0 1px 3px rgba(0,0,0,0.4); }",
100
+ "sampleData": {
101
+ "templateId": "slug-unik-kebab-case",
102
+ "layoutType": "custom",
103
+ "title": "CONTOH JUDUL BESAR KAPITAL SESUAI GAMBAR",
104
+ "subtitle": "Contoh subjudul pengantar informatif sesuai konteks gambar",
105
+ "category": "KATEGORI KONTEN",
106
+ "watermark": "@SocialGen",
107
+ "theme": "sunset-orange",
108
+ "footerNote": "Sumber: Lembaga Riset / Instansi Resmi (domain.go.id / .org) 2026",
109
+ "methodologyBadge": "Metodologi Riset Resmi 2026",
110
+ "disclaimer": "Ringkasan data edukasi \u2022 Bukan nasihat resmi",
111
+ "sourceUrl": "https://domain-resmi.org",
112
+ "reelsDuration": 30,
113
+ "caption": "Pertanyaan pemantik interaksi netizen? Tulis pendapatmu di bawah! \u{1F447} #hashtags",
114
+ "items": [
115
+ { "text": "Poin penjelasan pertama yang ringkas dan padat (maksimal 20 kata per poin)..." },
116
+ { "text": "Poin penjelasan kedua yang mereplikasi isi kartu pada gambar..." },
117
+ { "text": "Poin penjelasan ketiga yang melengkapi data infografis..." }
118
+ ]
119
+ },
120
+ "promptDirective": "FORMAT STRUKTUR JSON:\\n- 'templateId': Wajib cantumkan 'slug-unik-kebab-case'.\\n- 'layoutType': Wajib 'custom'.\\n- 'title': Judul utama singkat, padat, kapital (2-4 kata) yang menonjol.\\n- 'subtitle': Subjudul informatif 1 baris (6-10 kata) sebagai pengantar.\\n- 'footerNote': WAJIB cantumkan nama lembaga/sumber data riset resmi & tahun data.\\n- 'items': Array berisi 3 hingga 5 objek dengan properti 'text' (1-2 kalimat ringkas padat)."
121
+ }
122
+
123
+ =======================================================
124
+ PANDUAN STANDAR WAJIB ARSITEKTUR TEMPLATE SOCIALGEN:
125
+
126
+ 1. ATURAN KRUSIAL KODE HTML (JANGAN PERNAH DIHAPUS):
127
+ - Kolom \\"customHtml\\" WAJIB berupa string HTML utuh dengan seluruh tag pembuka & penutup <div>, <h1>, <p>, <span>.
128
+ - DILARANG KERAS hanya menulis variabel {{ data.title }} {{ data.items }} tanpa tag pembungkus HTML dan class CSS!
129
+ - Semua tanda kutip dua atribut di dalam JSON wajib di-escape (misal: class=\\"my-card\\").
130
+
131
+ 2. KESERASIAN ID TEMPLATE (ID MATCHING):
132
+ - Field root \\"id\\" dan field \\"sampleData.templateId\\" HARUS BERNILAI SAMA PERSIS (contoh: \\"orange-pill-hero\\").
133
+ - Jangan menggunakan ID yang berbeda antara root dan sampleData karena sistem SocialGen auto-switch menggunakan ID ini.
134
+
135
+ 3. KANVAS RESPONSIVE MULTI-FORMAT (FEED 4:5 & REELS 9:16):
136
+ - SocialGen mengekspor konten ke Feed 4:5 (1080x1350) dan Story/Reels 9:16 (1080x1920).
137
+ - JANGAN PERNAH memberi tinggi mati (height: 1350px) pada kontainer utama!
138
+ - Kontainer terluar WAJIB menggunakan:
139
+ width: 100%; max-width: 960px; margin: 0 auto; display: flex; flex-direction: column;
140
+ - Dengan aturan ini, kartu akan selalu berada tepat di tengah (center) dan berada di dalam Safe Zone baik pada format Feed maupun Reels.
141
+
142
+ 4. JANGAN DUPLIKASI HEADER & FOOTER GLOBAL SOCIALGEN:
143
+ - SocialGen SUDAH otomatis merender Top Metadata Bar (Category Badge & Watermark @SocialGen) di bagian paling atas kanvas.
144
+ - SocialGen SUDAH otomatis merender Bottom Callout (\\"\u{1F4AC} Drop your opinion below \u2022 Share to your feed \u2197\\" & Disclaimer) di bagian paling bawah.
145
+ - Oleh karena itu, customHtml HANYA fokus mendesain kartu konten di bagian tengah:
146
+ * Header kartu (Subtitle + Judul Besar)
147
+ * Badan kartu (mockup tablet, framed box, kartu list pil/bubble)
148
+ * Sumber data (footerNote) di bagian bawah kartu
149
+
150
+ 5. TIPOGRAFI STANDAR 1080px (READABILITY V2.3.4):
151
+ - Kanvas beresolusi 1080px lebar. Agar terbaca jelas di HP tanpa zoom:
152
+ * Judul Utama (title): font-size: 52px \u2013 64px (font-weight: 900, line-height: 1.08 - 1.15)
153
+ * Subjudul (subtitle): font-size: 22px \u2013 26px (font-weight: 700-800)
154
+ * Teks Kartu Poin (items): font-size: 20px \u2013 24px (font-weight: 700, line-height: 1.45)
155
+ * Sumber Data (footerNote): font-size: 16px \u2013 18px (font-weight: 600-700)
156
+
157
+ 6. MURNI CSS EKSPLISIT DI 'customCss':
158
+ - Karena aplikasi sudah di-compile, jangan mengandalkan arbitrary Tailwind baru (seperti text-[55px] atau bg-[#123456]).
159
+ - Semua warna, background, border, radius, bayangan, font-size, dan flexbox WAJIB ditulis lengkap dan eksplisit di \\"customCss\\".
160
+
161
+ 7. KREDIBILITAS TIER 1 (META CPM MONETIZATION):
162
+ - Selalu sertakan field \\"methodologyBadge\\", \\"disclaimer\\", dan \\"sourceUrl\\" di sampleData untuk lolos verifikasi transparansi data audiens Tier 1.
163
+
164
+ Keluarkan HANYA 1 objek JSON valid tanpa markdown formatting (\`\`\`json) agar bisa langsung diimpor otomatis ke aplikasi SocialGen.`);
84
165
  const filteredTemplates = computed(() => {
85
166
  if (!templateSearch.value.trim()) return templatesList.value;
86
167
  const q = templateSearch.value.toLowerCase();
@@ -129,21 +210,31 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
129
210
  });
130
211
  watch(
131
212
  () => props.options.backgroundSource,
132
- () => {
133
- const max = activeVideoMaxOffset.value;
134
- if ((props.options.videoStartOffset || 0) > max) {
135
- updateOption("videoStartOffset", max);
213
+ (newVal, oldVal) => {
214
+ if (oldVal !== void 0 && newVal !== oldVal) {
215
+ updateOption("videoStartOffset", 0);
216
+ } else {
217
+ const max = activeVideoMaxOffset.value;
218
+ if ((props.options.videoStartOffset || 0) > max) {
219
+ updateOption("videoStartOffset", max);
220
+ }
136
221
  }
137
- }
222
+ },
223
+ { immediate: true }
138
224
  );
139
225
  watch(
140
226
  () => props.options.musicFile,
141
- () => {
142
- const max = activeAudioMaxOffset.value;
143
- if ((props.options.audioStartOffset || 0) > max) {
144
- updateOption("audioStartOffset", max);
227
+ (newVal, oldVal) => {
228
+ if (oldVal !== void 0 && newVal !== oldVal) {
229
+ updateOption("audioStartOffset", 0);
230
+ } else {
231
+ const max = activeAudioMaxOffset.value;
232
+ if ((props.options.audioStartOffset || 0) > max) {
233
+ updateOption("audioStartOffset", max);
234
+ }
145
235
  }
146
- }
236
+ },
237
+ { immediate: true }
147
238
  );
148
239
  const isUploading = ref(false);
149
240
  ref(null);
@@ -253,9 +344,41 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
253
344
  }
254
345
  }
255
346
  );
347
+ const mobileSubTab = ref("content");
348
+ const showMobileJsonSheet = ref(false);
349
+ const THEME_SWATCHES = [
350
+ { id: "blue-tech", name: "Blue Tech", color: "#0284c7" },
351
+ { id: "emerald-finance", name: "Emerald Finance", color: "#059669" },
352
+ { id: "slate-education", name: "Slate Education", color: "#64748b" },
353
+ { id: "dark-contrast", name: "Dark Contrast", color: "#1e293b" },
354
+ { id: "crimson-alert", name: "Crimson Alert", color: "#e11d48" },
355
+ { id: "amber-gold", name: "Amber Gold", color: "#d97706" },
356
+ { id: "cyber-violet", name: "Cyber Violet", color: "#7c3aed" },
357
+ { id: "sunset-orange", name: "Sunset Orange", color: "#ea580c" },
358
+ { id: "nordic-frost", name: "Nordic Frost", color: "#0891b2" },
359
+ { id: "monochrome-luxe", name: "Monochrome Luxe", color: "#475569" }
360
+ ];
361
+ function getTemplateIcon(layoutType, id) {
362
+ const key = (id || layoutType || "").toLowerCase();
363
+ if (key.includes("orange") || key.includes("news")) return "\u{1F4F0}";
364
+ if (key.includes("edu") || key.includes("infografis")) return "\u{1F4DC}";
365
+ if (key.includes("breaking") || key.includes("alert")) return "\u{1F6A8}";
366
+ if (key.includes("stat")) return "\u{1F3AF}";
367
+ if (key.includes("table") || key.includes("matrix")) return "\u{1F4CA}";
368
+ if (key.includes("versus") || key.includes("debate")) return "\u2694\uFE0F";
369
+ if (key.includes("receipt")) return "\u{1F9FE}";
370
+ if (key.includes("tierlist")) return "\u{1F396}\uFE0F";
371
+ if (key.includes("leaderboard") || key.includes("list")) return "\u{1F3C6}";
372
+ if (key.includes("quote")) return "\u{1F4AC}";
373
+ if (key.includes("timeline")) return "\u23F3";
374
+ if (key.includes("barchart")) return "\u{1F4C8}";
375
+ return "\u{1F3A8}";
376
+ }
256
377
  function updateOption(key, val) {
257
378
  emit("update:options", { ...props.options, [key]: val });
258
379
  }
380
+ const isCopyingManualTopic = ref(false);
381
+ const copiedManualTopic = ref(false);
259
382
  function formatDate(isoStr) {
260
383
  if (!isoStr) return "";
261
384
  try {
@@ -266,7 +389,7 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
266
389
  }
267
390
  }
268
391
  return (_ctx, _push, _parent, _attrs) => {
269
- var _a2, _b2, _c, _d, _e, _f, _g, _h;
392
+ var _a2, _b2, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s;
270
393
  _push(`<div${ssrRenderAttrs(mergeProps({ class: "flex flex-col gap-3 text-slate-100" }, _attrs))}>`);
271
394
  if (unref(showNicheModal)) {
272
395
  _push(`<div class="fixed inset-0 z-50 bg-black/80 backdrop-blur-sm flex items-center justify-center p-4"><div class="bg-slate-900 border border-slate-700 rounded-3xl max-w-xl w-full p-5 shadow-2xl flex flex-col gap-4 text-xs max-h-[90vh] overflow-y-auto custom-scrollbar"><div class="flex items-center justify-between pb-3 border-b border-slate-800"><div><h3 class="text-sm font-black text-white flex items-center gap-2">`);
@@ -377,9 +500,14 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
377
500
  } else {
378
501
  _push(`<!---->`);
379
502
  }
380
- _push(`<div class="p-3 rounded-2xl bg-gradient-to-r from-sky-950/60 via-indigo-950/40 to-slate-900 border border-sky-500/30 flex flex-col gap-2.5"><div class="flex flex-col sm:flex-row sm:items-center justify-between gap-2"><div class="flex items-center gap-2"><span class="text-xl">\u{1F916}</span><div><h4 class="text-xs font-black text-white">Buat Template Otomatis dari Screenshot / Gambar</h4><p class="text-[10px] text-slate-400">Punya referensi gambar desain? Salin prompt AI dan kirim bersama screenshot ke ChatGPT / Claude / Gemini.</p></div></div><div class="flex items-center gap-1.5 shrink-0"><button type="button" class="${ssrRenderClass([unref(copiedAiPrompt) ? "bg-emerald-600 text-white" : "bg-sky-600 hover:bg-sky-500 text-white", "px-2.5 py-1.5 rounded-xl text-xs font-bold transition flex items-center gap-1.5 shadow"])}">`);
503
+ _push(`<div class="p-3 rounded-2xl bg-gradient-to-r from-sky-950/60 via-indigo-950/40 to-slate-900 border border-sky-500/30 flex flex-col gap-2.5"><div class="flex flex-col sm:flex-row sm:items-center justify-between gap-2"><div class="flex items-center gap-2"><span class="text-xl">\u{1F916}</span><div><h4 class="text-xs font-black text-white">Buat Template Otomatis dari Screenshot / Gambar</h4><p class="text-[10px] text-slate-400">Punya referensi gambar desain? Salin prompt AI dan kirim bersama screenshot ke ChatGPT / Claude / Gemini.</p></div></div><div class="flex items-center gap-1.5 shrink-0 flex-wrap"><button type="button" class="${ssrRenderClass([unref(copiedAiPrompt) ? "bg-emerald-600 text-white" : "bg-sky-600 hover:bg-sky-500 text-white", "px-2.5 py-1.5 rounded-xl text-xs font-bold transition flex items-center gap-1.5 shadow"])}">`);
381
504
  _push(ssrRenderComponent(unref(Copy), { class: "w-3.5 h-3.5" }, null, _parent));
382
- _push(`<span>${ssrInterpolate(unref(copiedAiPrompt) ? "\u2713 Prompt Tersalin!" : "Salin Prompt Bantuan AI")}</span></button><button type="button" class="px-2.5 py-1.5 rounded-xl bg-slate-800 hover:bg-slate-700 text-slate-200 text-xs font-bold transition flex items-center gap-1"><span>\u{1F4E5} Tempel JSON dari AI</span></button></div></div>`);
505
+ _push(`<span>${ssrInterpolate(unref(copiedAiPrompt) ? "\u2713 Prompt Tersalin!" : "Salin Prompt Bantuan AI")}</span></button><button type="button" class="px-2 py-1.5 rounded-xl bg-slate-800 hover:bg-slate-700 text-slate-200 text-xs font-bold transition flex items-center gap-1"${ssrRenderAttr("title", unref(showAiPromptView) ? "Sembunyikan teks prompt" : "Lihat / salin teks prompt manual di HP")}><span>${ssrInterpolate(unref(showAiPromptView) ? "Tutup Teks" : "\u{1F441}\uFE0F Lihat Teks Prompt")}</span></button><button type="button" class="px-2.5 py-1.5 rounded-xl bg-slate-800 hover:bg-slate-700 text-slate-200 text-xs font-bold transition flex items-center gap-1"><span>\u{1F4E5} Tempel JSON</span></button></div></div>`);
506
+ if (unref(showAiPromptView)) {
507
+ _push(`<div class="mt-1 flex flex-col gap-2 p-2.5 rounded-xl bg-slate-950/90 border border-sky-500/40"><div class="flex items-center justify-between"><label class="text-[10px] font-bold text-sky-400">Teks Lengkap Prompt Bantuan AI (Bisa ditandai/disalin manual di HP):</label><button class="text-[10px] text-slate-400 hover:text-white">\u2715 Tutup</button></div><textarea readonly rows="6" class="w-full bg-slate-900 border border-slate-700 rounded-lg p-2 text-[11px] text-sky-200 font-mono select-all focus:outline-none focus:border-sky-500 custom-scrollbar">${ssrInterpolate(unref(masterVisionPromptText))}</textarea></div>`);
508
+ } else {
509
+ _push(`<!---->`);
510
+ }
383
511
  if (unref(showAiPasteBox)) {
384
512
  _push(`<div class="mt-1 flex flex-col gap-2 p-2.5 rounded-xl bg-slate-950/90 border border-sky-500/40"><label class="text-[10px] font-bold text-sky-400">Tempelkan respon JSON dari AI di sini:</label><textarea rows="4" placeholder="Tempelkan respon JSON dari AI di sini (contoh: { &quot;name&quot;: &quot;...&quot;, &quot;layoutType&quot;: &quot;custom&quot;, &quot;customHtml&quot;: &quot;...&quot;, &quot;sampleData&quot;: {...} })..." class="w-full bg-slate-900 border border-slate-700 rounded-lg p-2 text-xs text-sky-200 font-mono focus:outline-none focus:border-sky-500">${ssrInterpolate(unref(aiImportJsonText))}</textarea><div class="flex justify-end gap-2"><button type="button" class="px-2.5 py-1 rounded-lg text-[10px] font-bold text-slate-400 hover:text-white"> Tutup </button><button type="button" class="px-3 py-1 rounded-lg bg-emerald-600 hover:bg-emerald-500 text-white text-[10px] font-bold shadow"> Terapkan ke Form Otomatis </button></div></div>`);
385
513
  } else {
@@ -404,7 +532,190 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
404
532
  } else {
405
533
  _push(`<!---->`);
406
534
  }
407
- _push(`<div class="flex flex-wrap items-center justify-between gap-2.5 p-3.5 bg-slate-900/90 border border-slate-800 rounded-2xl shadow-lg"><div><h2 class="text-xs font-black text-white flex items-center gap-2">`);
535
+ _push(`<div class="flex lg:hidden flex-col gap-3 pb-24"><div class="flex items-center justify-between gap-1 p-1 bg-slate-900/95 border border-slate-800 rounded-2xl shadow-lg sticky top-0 z-20 backdrop-blur-md"><div class="flex items-center gap-1 overflow-x-auto no-scrollbar flex-1 py-0.5"><button type="button" class="${ssrRenderClass([unref(mobileSubTab) === "content" ? "bg-sky-500 text-white shadow font-black" : "text-slate-400 hover:text-white", "px-2.5 py-1.5 rounded-xl text-xs font-bold flex items-center gap-1 shrink-0 transition"])}"><span>\u{1F4DD} Konten</span></button><button type="button" class="${ssrRenderClass([unref(mobileSubTab) === "design" ? "bg-sky-500 text-white shadow font-black" : "text-slate-400 hover:text-white", "px-2.5 py-1.5 rounded-xl text-xs font-bold flex items-center gap-1 shrink-0 transition"])}"><span>\u{1F3A8} Template</span></button><button type="button" class="${ssrRenderClass([unref(mobileSubTab) === "media" ? "bg-sky-500 text-white shadow font-black" : "text-slate-400 hover:text-white", "px-2.5 py-1.5 rounded-xl text-xs font-bold flex items-center gap-1 shrink-0 transition"])}"><span>\u{1F3AC} Media</span></button><button type="button" class="${ssrRenderClass([unref(mobileSubTab) === "ai" ? "bg-sky-500 text-white shadow font-black" : "text-slate-400 hover:text-white", "px-2.5 py-1.5 rounded-xl text-xs font-bold flex items-center gap-1 shrink-0 transition"])}"><span>\u26A1 AI Topic</span></button><button type="button" class="${ssrRenderClass([unref(mobileSubTab) === "history" ? "bg-sky-500 text-white shadow font-black" : "text-slate-400 hover:text-white", "px-2.5 py-1.5 rounded-xl text-xs font-bold flex items-center gap-1 shrink-0 transition"])}"><span>\u{1F4BE} Draft</span></button></div><button type="button" class="px-2 py-1.5 rounded-xl bg-slate-800 hover:bg-slate-700 text-[10px] font-mono font-bold text-sky-300 border border-slate-700 flex items-center gap-0.5 shrink-0 ml-1" title="Buka RAW JSON Editor"><span>&lt;/&gt; JSON</span></button></div>`);
536
+ if (unref(mobileSubTab) === "content") {
537
+ _push(`<div class="flex flex-col gap-3">`);
538
+ if (unref(jsonFormatError) || __props.validationError || unref(mismatchState)) {
539
+ _push(`<div class="${ssrRenderClass([unref(jsonFormatError) || __props.validationError ? "bg-rose-950/80 border-rose-500/60 text-rose-200" : "bg-amber-950/80 border-amber-500/60 text-amber-200", "p-3.5 rounded-2xl border text-xs shadow-lg space-y-2.5 animate-in fade-in"])}"><div class="flex items-start gap-2.5">`);
540
+ _push(ssrRenderComponent(unref(AlertCircle), {
541
+ class: ["w-4 h-4 shrink-0 mt-0.5", unref(jsonFormatError) || __props.validationError ? "text-rose-400" : "text-amber-400"]
542
+ }, null, _parent));
543
+ _push(`<div class="min-w-0 flex-1"><div class="font-black text-white text-xs">${ssrInterpolate(unref(jsonFormatError) ? "Sintaks JSON Tidak Valid" : unref(mismatchState) ? "Perbedaan Format Template" : "Data Belum Sesuai Template")}</div><p class="text-[11px] mt-0.5 leading-relaxed opacity-90">`);
544
+ if (unref(jsonFormatError)) {
545
+ _push(`<span>${ssrInterpolate(unref(jsonFormatError))}</span>`);
546
+ } else if (unref(mismatchState)) {
547
+ _push(`<span> Data JSON saat ini dibuat untuk template <b class="underline text-white">${ssrInterpolate(((_b2 = unref(mismatchState).matchedTarget) == null ? void 0 : _b2.name) || unref(mismatchState).jsonTemplateId)}</b>, sedangkan template aktif saat ini adalah <b class="underline text-white">${ssrInterpolate(unref(activeTemplate).name)}</b>. </span>`);
548
+ } else {
549
+ _push(`<span>${ssrInterpolate(__props.validationError)}</span>`);
550
+ }
551
+ _push(`</p></div></div><div class="flex items-center gap-2 pt-1 border-t border-white/10 flex-wrap"><button type="button" class="px-3 py-1.5 rounded-xl bg-white text-slate-950 text-xs font-black shadow transition active:scale-95 flex items-center gap-1.5">`);
552
+ _push(ssrRenderComponent(unref(RefreshCw), { class: "w-3.5 h-3.5" }, null, _parent));
553
+ _push(`<span>Pakai Sampel ${ssrInterpolate(unref(activeTemplate).name)}</span></button>`);
554
+ if (((_c = unref(mismatchState)) == null ? void 0 : _c.isKnown) && unref(mismatchState).matchedTarget) {
555
+ _push(`<button type="button" class="px-2.5 py-1.5 rounded-xl bg-amber-500/20 hover:bg-amber-500/40 text-amber-300 border border-amber-500/40 text-xs font-bold transition flex items-center gap-1 active:scale-95"><span>Beralih ke ${ssrInterpolate(unref(mismatchState).matchedTarget.name)}</span></button>`);
556
+ } else {
557
+ _push(`<!---->`);
558
+ }
559
+ _push(`<button type="button" class="px-2.5 py-1.5 rounded-xl bg-slate-800 text-slate-200 text-xs font-bold border border-slate-700 transition ml-auto active:scale-95"><span>&lt;/&gt; Buka JSON</span></button></div></div>`);
560
+ } else {
561
+ _push(`<div class="p-2.5 rounded-xl bg-slate-900/60 border border-slate-800 flex items-center justify-between text-[11px] shadow-sm"><div class="flex items-center gap-2 text-slate-300 truncate"><span class="w-2 h-2 rounded-full bg-emerald-400 shrink-0"></span><span class="text-slate-400">Template Aktif:</span><span class="font-extrabold text-white truncate">${ssrInterpolate(unref(activeTemplate).name)}</span></div><button type="button" class="text-[10px] text-sky-400 hover:text-sky-300 font-bold shrink-0 ml-2 transition" title="Muat ulang sampel data template aktif"> Reset ke Sampel </button></div>`);
562
+ }
563
+ _push(`<div class="p-3.5 bg-slate-900/90 border border-slate-800 rounded-2xl space-y-1.5 shadow-md"><div class="flex items-center justify-between"><label class="text-xs font-extrabold text-white flex items-center gap-1.5"><span>Judul Utama (Title)</span></label><span class="text-[9px] text-sky-400 font-bold uppercase tracking-wider">Wajib</span></div><input type="text"${ssrRenderAttr("value", __props.modelValue.title)} placeholder="Judul Utama Konten..." class="w-full bg-slate-950 border border-slate-800 rounded-xl px-3 py-2 text-xs text-white font-bold focus:outline-none focus:border-sky-500 transition"></div><div class="p-3.5 bg-slate-900/90 border border-slate-800 rounded-2xl space-y-1.5 shadow-md"><label class="text-xs font-bold text-slate-300">Subtitle / Penjelasan Ringkas</label><textarea rows="2" placeholder="Ringkasan atau penjelas judul..." class="w-full bg-slate-950 border border-slate-800 rounded-xl p-2.5 text-xs text-slate-200 focus:outline-none focus:border-sky-500 transition resize-none leading-relaxed">${ssrInterpolate(__props.modelValue.subtitle || "")}</textarea></div><div class="grid grid-cols-1 sm:grid-cols-2 gap-2.5"><div class="p-3 bg-slate-900/90 border border-slate-800 rounded-2xl space-y-1 shadow-md"><label class="text-[11px] font-bold text-slate-400">Watermark Handle</label><input type="text"${ssrRenderAttr("value", __props.modelValue.watermark || "@SocialGen")} placeholder="@NamaAkun" class="w-full bg-slate-950 border border-slate-800 rounded-xl px-2.5 py-1.5 text-sky-400 font-bold text-xs focus:outline-none focus:border-sky-500"></div><div class="p-3 bg-slate-900/90 border border-slate-800 rounded-2xl space-y-1 shadow-md"><label class="text-[11px] font-bold text-slate-400">Sumber (Footer Note)</label><input type="text"${ssrRenderAttr("value", __props.modelValue.footerNote || "")} placeholder="Source: Data Wire 2026..." class="w-full bg-slate-950 border border-slate-800 rounded-xl px-2.5 py-1.5 text-slate-300 text-xs focus:outline-none focus:border-sky-500"></div></div><div class="p-3.5 bg-slate-900/90 border border-slate-800 rounded-2xl space-y-2 shadow-md"><div class="flex items-center justify-between"><span class="text-xs font-bold text-slate-300">Viral Caption &amp; Hashtags</span><button type="button" class="text-[11px] font-bold text-sky-400 hover:text-sky-300 flex items-center gap-1 active:scale-95 transition">`);
564
+ _push(ssrRenderComponent(unref(Copy), { class: "w-3 h-3" }, null, _parent));
565
+ _push(`<span>Salin Caption</span></button></div><textarea rows="3" placeholder="Tulis caption reels / post di sini..." class="w-full bg-slate-950 border border-slate-800 rounded-xl p-2.5 text-xs text-slate-200 focus:outline-none focus:border-sky-500 leading-relaxed resize-none">${ssrInterpolate(__props.modelValue.caption || "")}</textarea></div></div>`);
566
+ } else if (unref(mobileSubTab) === "design") {
567
+ _push(`<div class="flex flex-col gap-3"><div class="p-3.5 bg-slate-900/90 border border-slate-800 rounded-2xl space-y-2.5 shadow-md"><div class="flex items-center justify-between"><div><span class="text-xs font-extrabold text-white">Pilih Format Template (${ssrInterpolate(unref(templatesList).length)})</span><p class="text-[10px] text-slate-400">Geser ke kanan untuk melihat semua format</p></div><button type="button" class="text-[10px] font-bold text-sky-400 hover:text-sky-300 flex items-center gap-1 bg-slate-800 px-2 py-1 rounded-lg border border-slate-700">`);
568
+ _push(ssrRenderComponent(unref(Settings), { class: "w-3 h-3" }, null, _parent));
569
+ _push(`<span>Kelola</span></button></div>`);
570
+ if (unref(mismatchState) || __props.validationError || unref(jsonFormatError)) {
571
+ _push(`<div class="p-2.5 rounded-xl bg-amber-950/70 border border-amber-500/40 text-amber-200 text-xs flex items-center justify-between shadow"><div class="flex items-center gap-1.5 truncate"><span class="text-sm">\u26A0\uFE0F</span><span class="text-[11px] truncate">`);
572
+ if (unref(mismatchState)) {
573
+ _push(`<span>Format JSON milik: <b>${ssrInterpolate(((_d = unref(mismatchState).matchedTarget) == null ? void 0 : _d.name) || unref(mismatchState).jsonTemplateId)}</b></span>`);
574
+ } else if (unref(jsonFormatError)) {
575
+ _push(`<span>Sintaks JSON tidak valid</span>`);
576
+ } else {
577
+ _push(`<span>${ssrInterpolate(__props.validationError)}</span>`);
578
+ }
579
+ _push(`</span></div><button type="button" class="px-2.5 py-1 rounded-lg bg-amber-500 text-slate-950 font-black text-[10px] shrink-0 active:scale-95 shadow ml-2"> Pakai Sampel </button></div>`);
580
+ } else {
581
+ _push(`<!---->`);
582
+ }
583
+ _push(`<div class="flex gap-2 overflow-x-auto no-scrollbar py-1"><!--[-->`);
584
+ ssrRenderList(unref(templatesList), (t) => {
585
+ _push(`<button type="button" class="${ssrRenderClass([unref(selectedTemplateId) === t.id ? "bg-slate-950 border-sky-500 shadow-lg shadow-sky-500/20" : "bg-slate-950/70 border-slate-800 hover:border-slate-700", "shrink-0 w-28 p-2.5 rounded-2xl border text-center flex flex-col items-center gap-1.5 transition active:scale-95"])}"><div class="w-8 h-8 rounded-xl bg-slate-800 flex items-center justify-center text-sm shadow">${ssrInterpolate(getTemplateIcon(t.layoutType, t.id))}</div><span class="text-[10px] font-black text-white leading-tight truncate w-full">${ssrInterpolate(t.name)}</span><span class="${ssrRenderClass([t.isBuiltin ? "bg-slate-800 text-slate-400" : "bg-purple-950 text-purple-300 border border-purple-800", "text-[8px] font-bold px-1.5 py-0.2 rounded uppercase tracking-wider"])}">${ssrInterpolate(t.isBuiltin ? t.category : "\u2B50 Kustom")}</span></button>`);
586
+ });
587
+ _push(`<!--]--></div></div><div class="p-3.5 bg-slate-900/90 border border-slate-800 rounded-2xl space-y-2.5 shadow-md"><div class="flex items-center justify-between"><span class="text-xs font-extrabold text-white">Tema Warna (Visual Swatches)</span><span class="text-[10px] text-sky-400 font-bold">${ssrInterpolate(__props.modelValue.theme || "blue-tech")}</span></div><div class="grid grid-cols-5 gap-2.5 py-1"><!--[-->`);
588
+ ssrRenderList(THEME_SWATCHES, (swatch) => {
589
+ _push(`<button type="button" class="flex flex-col items-center gap-1 p-1 rounded-xl transition"${ssrRenderAttr("title", swatch.name)}><div class="${ssrRenderClass([__props.modelValue.theme === swatch.id ? "ring-2 ring-white ring-offset-2 ring-offset-slate-950 scale-105" : "border-white/10 hover:border-white/40", "w-8 h-8 rounded-full border-2 transition transform active:scale-90"])}" style="${ssrRenderStyle({ backgroundColor: swatch.color })}"></div><span class="text-[8px] text-slate-400 truncate w-full text-center">${ssrInterpolate(swatch.name.split(" ")[0])}</span></button>`);
590
+ });
591
+ _push(`<!--]--></div></div><div class="p-3.5 bg-slate-900/90 border border-slate-800 rounded-2xl flex flex-col gap-3 shadow-md"><div class="flex items-center justify-between"><div class="flex flex-col"><span class="text-xs font-bold text-white">Buat Template Kustom</span><span class="text-[10px] text-slate-400">Punya referensi kartu baru? Tambahkan ke sistem.</span></div><button type="button" class="px-3 py-1.5 rounded-xl bg-gradient-to-r from-sky-600 to-indigo-600 hover:from-sky-500 text-white text-xs font-bold shadow flex items-center gap-1.5 active:scale-95 transition">`);
592
+ _push(ssrRenderComponent(unref(Plus), { class: "w-3.5 h-3.5" }, null, _parent));
593
+ _push(`<span>+ Buat Template</span></button></div><div class="pt-2.5 border-t border-slate-800/80 flex items-center justify-between gap-2"><span class="text-[10px] text-slate-400 flex items-center gap-1"><span>\u{1F916} Prompt AI Buat Template</span></span><div class="flex items-center gap-1.5"><button type="button" class="px-2.5 py-1 rounded-lg bg-sky-600/20 hover:bg-sky-600/40 text-sky-300 text-[10px] font-bold border border-sky-500/30 flex items-center gap-1 transition active:scale-95">`);
594
+ _push(ssrRenderComponent(unref(Copy), { class: "w-3 h-3" }, null, _parent));
595
+ _push(`<span>${ssrInterpolate(unref(copiedAiPrompt) ? "\u2713 Tersalin" : "Salin Prompt")}</span></button><button type="button" class="px-2 py-1 rounded-lg bg-slate-800 text-slate-300 text-[10px] font-bold border border-slate-700"><span>${ssrInterpolate(unref(showAiPromptView) ? "Tutup" : "Lihat")}</span></button></div></div>`);
596
+ if (unref(showAiPromptView)) {
597
+ _push(`<div class="p-2 rounded-xl bg-slate-950 border border-sky-500/40"><p class="text-[9px] text-slate-400 mb-1">Kirim prompt ini bersama screenshot kartu ke ChatGPT / Gemini / Claude untuk menghasilkan HTML &amp; CSS template:</p><textarea readonly rows="5" class="w-full bg-slate-900 border border-slate-700 rounded-lg p-2 text-[10px] text-sky-200 font-mono select-all focus:outline-none custom-scrollbar">${ssrInterpolate(unref(masterVisionPromptText))}</textarea></div>`);
598
+ } else {
599
+ _push(`<!---->`);
600
+ }
601
+ _push(`</div></div>`);
602
+ } else if (unref(mobileSubTab) === "media") {
603
+ _push(`<div class="flex flex-col gap-3"><div class="p-3.5 bg-slate-900/90 border border-slate-800 rounded-2xl space-y-2.5 shadow-md"><div class="flex items-center justify-between"><label class="text-xs font-extrabold text-sky-400 flex items-center gap-1.5">`);
604
+ _push(ssrRenderComponent(unref(Film), { class: "w-4 h-4" }, null, _parent));
605
+ _push(`<span>Background Video</span></label><button${ssrIncludeBooleanAttr(unref(isUploading)) ? " disabled" : ""} type="button" class="px-2.5 py-1 rounded-xl bg-sky-950/60 border border-sky-500/40 text-sky-300 text-[10px] font-bold flex items-center gap-1">`);
606
+ _push(ssrRenderComponent(unref(Upload), { class: "w-3 h-3" }, null, _parent));
607
+ _push(`<span>Upload MP4</span></button></div><select${ssrRenderAttr("value", __props.options.backgroundSource || "random")} class="w-full bg-slate-950 border border-slate-800 rounded-xl px-3 py-2 text-slate-200 text-xs font-semibold focus:outline-none focus:border-sky-500"><option value="random">\u{1F500} Acak Video</option><!--[-->`);
608
+ ssrRenderList(unref(availableVideos), (v) => {
609
+ _push(`<option${ssrRenderAttr("value", v)}>${ssrInterpolate(v.replace(".mp4", "").replace(/_/g, " "))}</option>`);
610
+ });
611
+ _push(`<!--]--><option value="pexels">\u{1F310} Pexels API (Auto HD)</option></select><div class="pt-1 space-y-1"><div class="flex items-center justify-between text-[11px]"><span class="text-slate-400 font-mono"> \u2702\uFE0F Mulai Detik: <strong class="text-sky-300 font-bold">${ssrInterpolate(Math.min(__props.options.videoStartOffset || 0, unref(activeVideoMaxOffset)))}s</strong> / ${ssrInterpolate(unref(activeVideoDuration))}s </span><button type="button" class="text-[10px] text-sky-400 hover:text-white"> Reset 0s </button></div><input type="range" min="0"${ssrRenderAttr("max", unref(activeVideoMaxOffset))} step="1"${ssrRenderAttr("value", Math.min(__props.options.videoStartOffset || 0, unref(activeVideoMaxOffset)))} class="w-full h-1.5 bg-slate-950 rounded appearance-none cursor-pointer accent-sky-400"></div></div><div class="p-3.5 bg-slate-900/90 border border-slate-800 rounded-2xl space-y-2.5 shadow-md"><div class="flex items-center justify-between"><label class="text-xs font-extrabold text-purple-400 flex items-center gap-1.5">`);
612
+ _push(ssrRenderComponent(unref(Music), { class: "w-4 h-4" }, null, _parent));
613
+ _push(`<span>Musik Reels</span></label><button${ssrIncludeBooleanAttr(unref(isUploading)) ? " disabled" : ""} type="button" class="px-2.5 py-1 rounded-xl bg-purple-950/60 border border-purple-500/40 text-purple-300 text-[10px] font-bold flex items-center gap-1">`);
614
+ _push(ssrRenderComponent(unref(Upload), { class: "w-3 h-3" }, null, _parent));
615
+ _push(`<span>Upload MP3</span></button></div><select${ssrRenderAttr("value", __props.options.musicFile || "random")} class="w-full bg-slate-950 border border-slate-800 rounded-xl px-3 py-2 text-slate-200 text-xs font-semibold focus:outline-none focus:border-purple-500"><option value="random">\u{1F500} Acak Musik</option><!--[-->`);
616
+ ssrRenderList(unref(availableAudio), (a) => {
617
+ _push(`<option${ssrRenderAttr("value", a)}>${ssrInterpolate(a.replace(".mp3", "").replace(/_/g, " "))}</option>`);
618
+ });
619
+ _push(`<!--]--></select><div class="pt-1 space-y-1"><div class="flex items-center justify-between text-[11px]"><span class="text-slate-400 font-mono"> \u2702\uFE0F Mulai Intro: <strong class="text-purple-300 font-bold">${ssrInterpolate(Math.min(__props.options.audioStartOffset || 0, unref(activeAudioMaxOffset)))}s</strong> / ${ssrInterpolate(unref(activeAudioDuration))}s </span><button type="button" class="text-[10px] text-purple-400 hover:text-white"> Reset 0s </button></div><input type="range" min="0"${ssrRenderAttr("max", unref(activeAudioMaxOffset))} step="1"${ssrRenderAttr("value", Math.min(__props.options.audioStartOffset || 0, unref(activeAudioMaxOffset)))} class="w-full h-1.5 bg-slate-950 rounded appearance-none cursor-pointer accent-purple-400"></div></div><div class="p-3.5 bg-slate-900/90 border border-slate-800 rounded-2xl flex items-center justify-between shadow-md"><label class="text-xs font-bold text-slate-300 flex items-center gap-1.5">`);
620
+ _push(ssrRenderComponent(unref(Clock), { class: "w-3.5 h-3.5 text-emerald-400" }, null, _parent));
621
+ _push(`<span>Durasi Reels:</span></label><div class="flex items-center gap-1.5"><!--[-->`);
622
+ ssrRenderList([7, 10, 15, 30, 60], (d) => {
623
+ _push(`<button type="button" class="${ssrRenderClass([__props.modelValue.reelsDuration === d ? "bg-emerald-500 text-white shadow" : "bg-slate-950 text-slate-400 border border-slate-800", "px-2.5 py-1 rounded-xl text-xs font-bold transition"])}">${ssrInterpolate(d)}s </button>`);
624
+ });
625
+ _push(`<!--]--></div></div><div class="p-3 bg-slate-900/90 border border-slate-800 rounded-2xl space-y-1.5 shadow-md"><span class="text-[11px] font-bold text-slate-400 uppercase tracking-wider block">Format Output Aktif</span><div class="grid grid-cols-3 gap-2"><label class="${ssrRenderClass([((_e = __props.options.outputs) == null ? void 0 : _e.feed) !== false ? "bg-sky-500/10 border-sky-500/40 text-sky-200" : "bg-slate-950 border-slate-800 text-slate-500", "flex items-center gap-1.5 p-2 rounded-xl border text-xs cursor-pointer select-none"])}"><input type="checkbox"${ssrIncludeBooleanAttr(((_f = __props.options.outputs) == null ? void 0 : _f.feed) !== false) ? " checked" : ""} class="rounded text-sky-500"><span class="font-bold">Feed 4:5</span></label><label class="${ssrRenderClass([((_g = __props.options.outputs) == null ? void 0 : _g.story) !== false ? "bg-indigo-500/10 border-indigo-500/40 text-indigo-200" : "bg-slate-950 border-slate-800 text-slate-500", "flex items-center gap-1.5 p-2 rounded-xl border text-xs cursor-pointer select-none"])}"><input type="checkbox"${ssrIncludeBooleanAttr(((_h = __props.options.outputs) == null ? void 0 : _h.story) !== false) ? " checked" : ""} class="rounded text-indigo-500"><span class="font-bold">Story 9:16</span></label><label class="${ssrRenderClass([((_i = __props.options.outputs) == null ? void 0 : _i.reels) !== false ? "bg-emerald-500/10 border-emerald-500/40 text-emerald-200" : "bg-slate-950 border-slate-800 text-slate-500", "flex items-center gap-1.5 p-2 rounded-xl border text-xs cursor-pointer select-none"])}"><input type="checkbox"${ssrIncludeBooleanAttr(((_j = __props.options.outputs) == null ? void 0 : _j.reels) !== false) ? " checked" : ""} class="rounded text-emerald-500"><span class="font-bold">Reels MP4</span></label></div></div></div>`);
626
+ } else if (unref(mobileSubTab) === "ai") {
627
+ _push(`<div class="flex flex-col gap-3"><div class="p-4 rounded-3xl bg-gradient-to-br from-indigo-950/80 via-slate-900 to-sky-950/80 border border-sky-500/30 space-y-3 shadow-xl"><div class="flex items-center justify-between"><span class="text-xs font-black text-sky-300 uppercase tracking-wider flex items-center gap-1.5">`);
628
+ _push(ssrRenderComponent(unref(Sparkles), { class: "w-4 h-4 text-sky-400" }, null, _parent));
629
+ _push(` Auto-Topic AI Generator </span><span class="text-[9px] px-2 py-0.5 rounded-full bg-emerald-500/20 text-emerald-400 font-bold border border-emerald-500/30">${ssrInterpolate(unref(selectedModel))}</span></div><div class="grid grid-cols-2 gap-2"><div class="space-y-1"><label class="text-[10px] font-bold text-slate-400">Pilih Niche</label><select class="w-full bg-slate-950 border border-slate-800 rounded-xl px-2.5 py-2 text-xs text-white font-bold focus:outline-none"><!--[-->`);
630
+ ssrRenderList(unref(nichesList), (n) => {
631
+ _push(`<option${ssrRenderAttr("value", n.id)}${ssrIncludeBooleanAttr(Array.isArray(unref(selectedNicheId)) ? ssrLooseContain(unref(selectedNicheId), n.id) : ssrLooseEqual(unref(selectedNicheId), n.id)) ? " selected" : ""}>${ssrInterpolate(n.name)}</option>`);
632
+ });
633
+ _push(`<!--]--></select></div><div class="space-y-1"><label class="text-[10px] font-bold text-slate-400">Bahasa Konten</label><select class="w-full bg-slate-950 border border-slate-800 rounded-xl px-2.5 py-2 text-xs text-emerald-300 font-bold focus:outline-none"><option value="id"${ssrIncludeBooleanAttr(Array.isArray(unref(selectedLanguage)) ? ssrLooseContain(unref(selectedLanguage), "id") : ssrLooseEqual(unref(selectedLanguage), "id")) ? " selected" : ""}>\u{1F1EE}\u{1F1E9} Indonesia</option><option value="en"${ssrIncludeBooleanAttr(Array.isArray(unref(selectedLanguage)) ? ssrLooseContain(unref(selectedLanguage), "en") : ssrLooseEqual(unref(selectedLanguage), "en")) ? " selected" : ""}>\u{1F1FA}\u{1F1F8} English</option><option value="es"${ssrIncludeBooleanAttr(Array.isArray(unref(selectedLanguage)) ? ssrLooseContain(unref(selectedLanguage), "es") : ssrLooseEqual(unref(selectedLanguage), "es")) ? " selected" : ""}>\u{1F1EA}\u{1F1F8} Espa\xF1ol</option><option value="ja"${ssrIncludeBooleanAttr(Array.isArray(unref(selectedLanguage)) ? ssrLooseContain(unref(selectedLanguage), "ja") : ssrLooseEqual(unref(selectedLanguage), "ja")) ? " selected" : ""}>\u{1F1EF}\u{1F1F5} \u65E5\u672C\u8A9E</option><option value="de"${ssrIncludeBooleanAttr(Array.isArray(unref(selectedLanguage)) ? ssrLooseContain(unref(selectedLanguage), "de") : ssrLooseEqual(unref(selectedLanguage), "de")) ? " selected" : ""}>\u{1F1E9}\u{1F1EA} Deutsch</option></select></div></div><button${ssrIncludeBooleanAttr(__props.isGenerating || __props.isAutoTopicLoading) ? " disabled" : ""} type="button" class="w-full py-3 rounded-2xl bg-gradient-to-r from-sky-500 via-indigo-600 to-purple-600 text-white font-black text-xs shadow-xl shadow-sky-500/25 flex items-center justify-center gap-2 active:scale-98 transition disabled:opacity-50">`);
634
+ _push(ssrRenderComponent(unref(Sparkles), {
635
+ class: ["w-4 h-4", { "animate-spin": __props.isAutoTopicLoading }]
636
+ }, null, _parent));
637
+ _push(`<span>${ssrInterpolate(__props.isAutoTopicLoading ? "Meriset Data Viral..." : "\u2728 Auto-Topic Viral Baru")}</span></button></div><div class="p-3.5 bg-slate-900/90 border border-purple-500/30 rounded-2xl space-y-2.5 shadow-md"><div class="flex items-center justify-between"><div class="flex items-center gap-1.5">`);
638
+ _push(ssrRenderComponent(unref(FileText), { class: "w-4 h-4 text-purple-400" }, null, _parent));
639
+ _push(`<span class="text-xs font-black text-white">Master Prompt Riset Topik AI</span></div><button type="button" class="px-2 py-0.5 rounded-lg bg-purple-950/60 border border-purple-500/40 text-purple-300 text-[10px] font-bold flex items-center gap-1 hover:text-white">`);
640
+ _push(ssrRenderComponent(unref(Eye), { class: "w-3 h-3" }, null, _parent));
641
+ _push(`<span>Buka Detail</span></button></div><p class="text-[11px] text-slate-400 leading-relaxed"> Salin prompt riset cerdas ini ke <b>ChatGPT / Gemini / Claude</b> untuk riset topik konten viral terbaru sesuai niche &amp; template yang aktif (bebas bentrok riwayat): </p><div class="flex items-center gap-2"><button${ssrIncludeBooleanAttr(unref(isCopyingManualTopic)) ? " disabled" : ""} type="button" class="flex-1 px-3 py-2.5 rounded-xl bg-gradient-to-r from-purple-600 to-indigo-600 hover:from-purple-500 text-white text-xs font-bold shadow-lg transition flex items-center justify-center gap-1.5 active:scale-95 disabled:opacity-50">`);
642
+ if (unref(copiedManualTopic)) {
643
+ _push(ssrRenderComponent(unref(Check), { class: "w-3.5 h-3.5 text-emerald-300" }, null, _parent));
644
+ } else {
645
+ _push(ssrRenderComponent(unref(Copy), { class: "w-3.5 h-3.5" }, null, _parent));
646
+ }
647
+ _push(`<span>${ssrInterpolate(unref(isCopyingManualTopic) ? "Menyiapkan Prompt..." : unref(copiedManualTopic) ? "\u2713 Master Prompt Tersalin!" : "Salin Master Prompt Topik")}</span></button><button type="button" title="Lihat teks prompt manual lengkap" class="px-3 py-2.5 rounded-xl bg-slate-800 text-slate-300 text-xs font-bold border border-slate-700 hover:bg-slate-700 transition">`);
648
+ _push(ssrRenderComponent(unref(Eye), { class: "w-3.5 h-3.5" }, null, _parent));
649
+ _push(`</button></div></div></div>`);
650
+ } else if (unref(mobileSubTab) === "history") {
651
+ _push(`<div class="flex flex-col gap-3"><div class="flex items-center justify-between bg-slate-900/90 p-1 rounded-2xl border border-slate-800 text-xs font-bold shadow-md"><button type="button" class="${ssrRenderClass([unref(activeTab) === "drafts" ? "bg-amber-500 text-slate-950 font-black shadow" : "text-slate-400 hover:text-white", "flex-1 py-1.5 px-3 rounded-xl transition text-center"])}"><span>Drafts (${ssrInterpolate(__props.drafts.length)})</span></button><button type="button" class="${ssrRenderClass([unref(activeTab) === "history" ? "bg-purple-600 text-white font-black shadow" : "text-slate-400 hover:text-white", "flex-1 py-1.5 px-3 rounded-xl transition text-center"])}"><span>Riwayat (${ssrInterpolate(__props.history.length)})</span></button></div>`);
652
+ if (unref(activeTab) === "drafts") {
653
+ _push(`<div class="flex flex-col gap-2"><div class="flex items-center justify-between px-1"><span class="text-[11px] font-bold text-slate-400 uppercase tracking-wider">Daftar Draft Tersimpan</span><button type="button" class="text-[11px] font-bold text-amber-400 hover:text-amber-300 flex items-center gap-1">`);
654
+ _push(ssrRenderComponent(unref(Bookmark), { class: "w-3 h-3" }, null, _parent));
655
+ _push(`<span>+ Simpan Draft</span></button></div>`);
656
+ if (__props.drafts.length === 0) {
657
+ _push(`<div class="text-center py-10 text-slate-500 text-xs bg-slate-900/50 rounded-2xl border border-slate-800"> Belum ada draft tersimpan. </div>`);
658
+ } else {
659
+ _push(`<!---->`);
660
+ }
661
+ _push(`<!--[-->`);
662
+ ssrRenderList(__props.drafts, (draft, dIdx) => {
663
+ _push(`<div class="p-3 rounded-2xl border bg-slate-900/80 border-slate-800 hover:border-amber-500/40 flex items-center justify-between cursor-pointer active:scale-98 transition shadow"><div class="flex-1 pr-2 truncate"><div class="font-extrabold text-xs text-white truncate">${ssrInterpolate(draft.title || "Tanpa Judul")}</div><div class="text-[10px] text-slate-400 font-mono">${ssrInterpolate(draft.category || "Draft")}</div></div><button type="button" class="p-1.5 text-slate-400 hover:text-rose-400 rounded-lg transition">`);
664
+ _push(ssrRenderComponent(unref(Trash2), { class: "w-3.5 h-3.5" }, null, _parent));
665
+ _push(`</button></div>`);
666
+ });
667
+ _push(`<!--]--></div>`);
668
+ } else {
669
+ _push(`<div class="flex flex-col gap-2"><div class="flex items-center justify-between px-1"><span class="text-[11px] font-bold text-slate-400 uppercase tracking-wider">Riwayat Generasi Terakhir</span>`);
670
+ if (__props.history.length > 0) {
671
+ _push(`<button type="button" class="text-[10px] font-bold text-rose-400 hover:text-rose-300"> Hapus Semua </button>`);
672
+ } else {
673
+ _push(`<!---->`);
674
+ }
675
+ _push(`</div>`);
676
+ if (__props.history.length === 0) {
677
+ _push(`<div class="text-center py-10 text-slate-500 text-xs bg-slate-900/50 rounded-2xl border border-slate-800"> Belum ada riwayat pembuatan. </div>`);
678
+ } else {
679
+ _push(`<!---->`);
680
+ }
681
+ _push(`<!--[-->`);
682
+ ssrRenderList(__props.history, (item, hIdx) => {
683
+ _push(`<div class="p-3 rounded-2xl border bg-slate-900/80 border-slate-800 hover:border-purple-500/40 flex items-center justify-between cursor-pointer active:scale-98 transition shadow"><div class="flex-1 pr-2 truncate"><div class="font-extrabold text-xs text-white truncate">${ssrInterpolate(item.title)}</div><div class="text-[10px] text-slate-400 font-mono">${ssrInterpolate(item.category)} \u2022 ${ssrInterpolate(formatDate(item.generatedAt))}</div></div><button type="button" class="p-1.5 text-slate-400 hover:text-rose-400 rounded-lg transition">`);
684
+ _push(ssrRenderComponent(unref(Trash2), { class: "w-3.5 h-3.5" }, null, _parent));
685
+ _push(`</button></div>`);
686
+ });
687
+ _push(`<!--]--></div>`);
688
+ }
689
+ _push(`</div>`);
690
+ } else {
691
+ _push(`<!---->`);
692
+ }
693
+ if (unref(showMobileJsonSheet)) {
694
+ _push(`<div class="fixed inset-0 z-50 bg-black/80 backdrop-blur-sm flex flex-col justify-end"><div class="w-full max-h-[80vh] bg-slate-900 border-t border-slate-700 rounded-t-3xl p-4 flex flex-col gap-3 shadow-2xl animate-in slide-in-from-bottom"><div class="flex items-center justify-between pb-2 border-b border-slate-800"><div class="flex items-center gap-2"><span class="text-xs font-bold text-white font-mono">&lt;/&gt; RAW JSON SocialGen</span><span class="text-[9px] px-1.5 py-0.2 rounded-full bg-sky-500/20 text-sky-300 font-mono">Format V2</span></div><button type="button" class="w-7 h-7 rounded-full bg-slate-800 flex items-center justify-center text-xs text-slate-400 hover:text-white"> \u2715 </button></div>`);
695
+ if (unref(mismatchState) || unref(jsonFormatError) || __props.validationError) {
696
+ _push(`<div class="${ssrRenderClass([unref(jsonFormatError) || __props.validationError ? "bg-rose-950/80 border-rose-500/50 text-rose-200" : "bg-amber-950/80 border-amber-500/50 text-amber-200", "p-2.5 rounded-xl border text-[11px] flex items-center justify-between gap-2 shadow"])}"><div class="flex items-center gap-1.5 truncate"><span>\u26A0\uFE0F</span><span class="truncate">`);
697
+ if (unref(jsonFormatError)) {
698
+ _push(`<span>${ssrInterpolate(unref(jsonFormatError))}</span>`);
699
+ } else if (unref(mismatchState)) {
700
+ _push(`<span>JSON untuk template: <b>${ssrInterpolate(((_k = unref(mismatchState).matchedTarget) == null ? void 0 : _k.name) || unref(mismatchState).jsonTemplateId)}</b></span>`);
701
+ } else {
702
+ _push(`<span>${ssrInterpolate(__props.validationError)}</span>`);
703
+ }
704
+ _push(`</span></div>`);
705
+ if (((_l = unref(mismatchState)) == null ? void 0 : _l.isKnown) && unref(mismatchState).matchedTarget) {
706
+ _push(`<button type="button" class="px-2 py-0.5 rounded-lg bg-amber-500 text-slate-950 font-bold text-[10px] shrink-0 active:scale-95 shadow"> Ganti Template </button>`);
707
+ } else {
708
+ _push(`<!---->`);
709
+ }
710
+ _push(`</div>`);
711
+ } else {
712
+ _push(`<!---->`);
713
+ }
714
+ _push(`<textarea rows="8" spellcheck="false" class="w-full bg-slate-950 text-sky-200 text-xs font-mono p-3 rounded-xl border border-slate-800 focus:outline-none focus:border-sky-500/50 resize-y leading-relaxed" placeholder="Paste Content JSON here...">${ssrInterpolate(unref(rawJsonInput))}</textarea><div class="flex items-center justify-between gap-2"><button type="button" class="px-3 py-2 rounded-xl bg-slate-800 hover:bg-slate-700 text-xs font-bold text-amber-400"> Pakai Sample </button><button type="button" class="px-3 py-2 rounded-xl bg-slate-800 hover:bg-slate-700 text-xs font-bold text-sky-400"> Format JSON </button><button type="button" class="px-4 py-2 rounded-xl bg-sky-500 hover:bg-sky-400 text-xs font-bold text-white shadow-lg"> Selesai </button></div></div></div>`);
715
+ } else {
716
+ _push(`<!---->`);
717
+ }
718
+ _push(`</div><div class="hidden lg:flex flex-col gap-3"><div class="flex flex-wrap items-center justify-between gap-2.5 p-3.5 bg-slate-900/90 border border-slate-800 rounded-2xl shadow-lg"><div><h2 class="text-xs font-black text-white flex items-center gap-2">`);
408
719
  _push(ssrRenderComponent(unref(Wand2), { class: "w-3.5 h-3.5 text-sky-400" }, null, _parent));
409
720
  _push(` Content Studio </h2><p class="text-[10px] text-slate-400">Multi-Format Studio</p></div><div class="flex items-center gap-1.5 flex-wrap"><div class="flex items-center gap-1 bg-slate-950 p-1 rounded-xl border border-slate-800 mr-1.5 shadow-inner"><select class="bg-transparent text-[11px] font-bold text-sky-300 focus:outline-none px-2 py-0.5 cursor-pointer max-w-[130px] truncate" title="Pilih Niche Konten"><!--[-->`);
410
721
  ssrRenderList(unref(nichesList), (n) => {
@@ -525,7 +836,7 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
525
836
  if (unref(mismatchState)) {
526
837
  _push(`<div class="${ssrRenderClass([unref(mismatchState).isKnown ? "bg-amber-500/10 border-amber-500/30" : "bg-rose-500/10 border-rose-500/30", "mx-2.5 mt-2.5 p-2 rounded-xl border text-xs transition-all shadow-md flex flex-col sm:flex-row sm:items-center justify-between gap-2"])}"><div class="${ssrRenderClass([unref(mismatchState).isKnown ? "text-amber-300" : "text-rose-300", "flex items-center gap-1.5 text-[11px]"])}"><span class="text-sm">\u26A0\uFE0F</span>`);
527
838
  if (unref(mismatchState).isKnown) {
528
- _push(`<span> JSON ini dibuat untuk template <b class="underline">${ssrInterpolate((_b2 = unref(mismatchState).matchedTarget) == null ? void 0 : _b2.name)}</b> (<span class="font-mono text-[10px]">${ssrInterpolate(unref(mismatchState).jsonTemplateId)}</span>) </span>`);
839
+ _push(`<span> JSON ini dibuat untuk template <b class="underline">${ssrInterpolate((_m = unref(mismatchState).matchedTarget) == null ? void 0 : _m.name)}</b> (<span class="font-mono text-[10px]">${ssrInterpolate(unref(mismatchState).jsonTemplateId)}</span>) </span>`);
529
840
  } else {
530
841
  _push(`<span> Template dengan ID &quot;<span class="font-mono text-[10px]">${ssrInterpolate(unref(mismatchState).jsonTemplateId)}</span>&quot; tidak ditemukan di sistem. </span>`);
531
842
  }
@@ -573,7 +884,7 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
573
884
  ssrRenderList([7, 10, 15, 30, 60], (d) => {
574
885
  _push(`<button class="${ssrRenderClass([(__props.modelValue.reelsDuration || 30) === d ? "bg-emerald-500/20 border-emerald-500/60 text-emerald-300" : "bg-slate-950 border-slate-800 text-slate-400 hover:text-white", "px-2 py-0.5 text-[10px] font-bold rounded-lg border transition"])}">${ssrInterpolate(d === 60 ? "1m" : d + "s")}</button>`);
575
886
  });
576
- _push(`<!--]--></div></div><div class="grid grid-cols-3 gap-2 pt-1.5 border-t border-slate-800"><label class="${ssrRenderClass([((_c = __props.options.outputs) == null ? void 0 : _c.feed) !== false ? "bg-sky-500/10 border-sky-500/40 text-sky-200" : "bg-slate-950/50 border-slate-800 text-slate-500", "flex items-center gap-1.5 p-1.5 rounded-xl border text-[11px] cursor-pointer transition select-none"])}"><input type="checkbox"${ssrIncludeBooleanAttr(((_d = __props.options.outputs) == null ? void 0 : _d.feed) !== false) ? " checked" : ""} class="rounded text-sky-500 focus:ring-0 bg-slate-900 border-slate-700 w-3 h-3"><span class="font-bold">Feed 4:5</span></label><label class="${ssrRenderClass([((_e = __props.options.outputs) == null ? void 0 : _e.story) !== false ? "bg-indigo-500/10 border-indigo-500/40 text-indigo-200" : "bg-slate-950/50 border-slate-800 text-slate-500", "flex items-center gap-1.5 p-1.5 rounded-xl border text-[11px] cursor-pointer transition select-none"])}"><input type="checkbox"${ssrIncludeBooleanAttr(((_f = __props.options.outputs) == null ? void 0 : _f.story) !== false) ? " checked" : ""} class="rounded text-indigo-500 focus:ring-0 bg-slate-900 border-slate-700 w-3 h-3"><span class="font-bold">Story 9:16</span></label><label class="${ssrRenderClass([((_g = __props.options.outputs) == null ? void 0 : _g.reels) !== false ? "bg-emerald-500/10 border-emerald-500/40 text-emerald-200" : "bg-slate-950/50 border-slate-800 text-slate-500", "flex items-center gap-1.5 p-1.5 rounded-xl border text-[11px] cursor-pointer transition select-none"])}"><input type="checkbox"${ssrIncludeBooleanAttr(((_h = __props.options.outputs) == null ? void 0 : _h.reels) !== false) ? " checked" : ""} class="rounded text-emerald-500 focus:ring-0 bg-slate-900 border-slate-700 w-3 h-3"><span class="font-bold">Reels MP4</span></label></div></div><button${ssrIncludeBooleanAttr(!__props.isValid || __props.isGenerating || !!unref(jsonFormatError)) ? " disabled" : ""} class="${ssrRenderClass([[
887
+ _push(`<!--]--></div></div><div class="grid grid-cols-3 gap-2 pt-1.5 border-t border-slate-800"><label class="${ssrRenderClass([((_n = __props.options.outputs) == null ? void 0 : _n.feed) !== false ? "bg-sky-500/10 border-sky-500/40 text-sky-200" : "bg-slate-950/50 border-slate-800 text-slate-500", "flex items-center gap-1.5 p-1.5 rounded-xl border text-[11px] cursor-pointer transition select-none"])}"><input type="checkbox"${ssrIncludeBooleanAttr(((_o = __props.options.outputs) == null ? void 0 : _o.feed) !== false) ? " checked" : ""} class="rounded text-sky-500 focus:ring-0 bg-slate-900 border-slate-700 w-3 h-3"><span class="font-bold">Feed 4:5</span></label><label class="${ssrRenderClass([((_p = __props.options.outputs) == null ? void 0 : _p.story) !== false ? "bg-indigo-500/10 border-indigo-500/40 text-indigo-200" : "bg-slate-950/50 border-slate-800 text-slate-500", "flex items-center gap-1.5 p-1.5 rounded-xl border text-[11px] cursor-pointer transition select-none"])}"><input type="checkbox"${ssrIncludeBooleanAttr(((_q = __props.options.outputs) == null ? void 0 : _q.story) !== false) ? " checked" : ""} class="rounded text-indigo-500 focus:ring-0 bg-slate-900 border-slate-700 w-3 h-3"><span class="font-bold">Story 9:16</span></label><label class="${ssrRenderClass([((_r = __props.options.outputs) == null ? void 0 : _r.reels) !== false ? "bg-emerald-500/10 border-emerald-500/40 text-emerald-200" : "bg-slate-950/50 border-slate-800 text-slate-500", "flex items-center gap-1.5 p-1.5 rounded-xl border text-[11px] cursor-pointer transition select-none"])}"><input type="checkbox"${ssrIncludeBooleanAttr(((_s = __props.options.outputs) == null ? void 0 : _s.reels) !== false) ? " checked" : ""} class="rounded text-emerald-500 focus:ring-0 bg-slate-900 border-slate-700 w-3 h-3"><span class="font-bold">Reels MP4</span></label></div></div><button${ssrIncludeBooleanAttr(!__props.isValid || __props.isGenerating || !!unref(jsonFormatError)) ? " disabled" : ""} class="${ssrRenderClass([[
577
888
  !__props.isValid || __props.isGenerating || !!unref(jsonFormatError) ? "bg-slate-800 text-slate-500 cursor-not-allowed border border-slate-700" : "bg-gradient-to-r from-sky-500 via-blue-600 to-indigo-600 text-white hover:from-sky-400 hover:to-indigo-500 shadow-sky-500/25 active:scale-[0.99]"
578
889
  ], "w-full py-3 px-4 rounded-xl font-black text-xs tracking-wide shadow-xl transition flex items-center justify-center gap-2"])}">`);
579
890
  if (__props.isGenerating) {
@@ -581,7 +892,7 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
581
892
  } else {
582
893
  _push(ssrRenderComponent(unref(Play), { class: "w-3.5 h-3.5 fill-current" }, null, _parent));
583
894
  }
584
- _push(`<span>${ssrInterpolate(__props.isGenerating ? __props.generateStage || "Rendering Content..." : "GENERATE CONTENT")}</span></button></div>`);
895
+ _push(`<span>${ssrInterpolate(__props.isGenerating ? __props.generateStage || "Rendering Content..." : "GENERATE CONTENT")}</span></button></div></div>`);
585
896
  };
586
897
  }
587
898
  });
@@ -600,11 +911,14 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
600
911
  selectedMusic: {},
601
912
  videoStartOffset: { default: 0 },
602
913
  audioStartOffset: { default: 0 },
914
+ isGenerating: { type: Boolean, default: false },
915
+ generateStage: { default: "" },
603
916
  generatedResult: {}
604
917
  },
605
918
  emits: ["update:videoStartOffset", "update:audioStartOffset"],
606
919
  setup(__props, { emit: __emit }) {
607
920
  const props = __props;
921
+ const emit = __emit;
608
922
  const KNOWN_DURATIONS = {
609
923
  "neon_cyber_grid.mp4": 8,
610
924
  "financial_pulse_flow.mp4": 8,
@@ -639,8 +953,10 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
639
953
  const showSafeZones = ref(false);
640
954
  const showOffsetEditor = ref(false);
641
955
  const copied = ref(false);
642
- const isOpeningFolder = ref(false);
956
+ ref(false);
643
957
  const zoomScale = ref(1);
958
+ const baseCanvasWidth = computed(() => activeTab.value === "feed" ? 360 : 300);
959
+ const baseCanvasHeight = computed(() => activeTab.value === "feed" ? 450 : 533.33);
644
960
  const videoElement = ref(null);
645
961
  const audioElement = ref(null);
646
962
  const isPlaying = ref(true);
@@ -672,6 +988,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
672
988
  lastTimestamp = timestamp;
673
989
  rafId = requestAnimationFrame(updatePlaybackTimeline);
674
990
  }
991
+ const dynamicDurations = ref({});
675
992
  watch(totalDuration, (newDur) => {
676
993
  if (currentTime.value > newDur) {
677
994
  currentTime.value = 0;
@@ -708,6 +1025,29 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
708
1025
  audioElement.value.currentTime = Math.min(targetA, audioFileDuration.value - 0.1);
709
1026
  }
710
1027
  }
1028
+ watch(
1029
+ () => props.selectedVideo,
1030
+ (newVal, oldVal) => {
1031
+ if (oldVal !== void 0 && newVal !== oldVal) {
1032
+ emit("update:videoStartOffset", 0);
1033
+ currentTime.value = 0;
1034
+ if (videoElement.value) {
1035
+ videoElement.value.currentTime = 0;
1036
+ }
1037
+ }
1038
+ }
1039
+ );
1040
+ watch(
1041
+ () => props.selectedMusic,
1042
+ (newVal, oldVal) => {
1043
+ if (oldVal !== void 0 && newVal !== oldVal) {
1044
+ emit("update:audioStartOffset", 0);
1045
+ if (audioElement.value) {
1046
+ audioElement.value.currentTime = 0;
1047
+ }
1048
+ }
1049
+ }
1050
+ );
711
1051
  watch(
712
1052
  () => props.videoStartOffset,
713
1053
  (newVal) => {
@@ -735,8 +1075,8 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
735
1075
  () => activeVideoSrc.value,
736
1076
  () => {
737
1077
  const filename = props.selectedVideo || "";
738
- if (KNOWN_DURATIONS[filename]) {
739
- videoFileDuration.value = KNOWN_DURATIONS[filename];
1078
+ if (dynamicDurations.value[filename] || KNOWN_DURATIONS[filename]) {
1079
+ videoFileDuration.value = dynamicDurations.value[filename] || KNOWN_DURATIONS[filename];
740
1080
  }
741
1081
  nextTick(() => {
742
1082
  seekToRelative(0);
@@ -747,8 +1087,8 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
747
1087
  () => activeAudioSrc.value,
748
1088
  () => {
749
1089
  const filename = props.selectedMusic || "";
750
- if (KNOWN_DURATIONS[filename]) {
751
- audioFileDuration.value = KNOWN_DURATIONS[filename];
1090
+ if (dynamicDurations.value[filename] || KNOWN_DURATIONS[filename]) {
1091
+ audioFileDuration.value = dynamicDurations.value[filename] || KNOWN_DURATIONS[filename];
752
1092
  }
753
1093
  }
754
1094
  );
@@ -770,7 +1110,15 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
770
1110
  );
771
1111
  return (_ctx, _push, _parent, _attrs) => {
772
1112
  const _component_TableCard = _sfc_main$3;
773
- _push(`<div${ssrRenderAttrs(mergeProps({ class: "flex flex-col gap-2.5 h-full text-slate-100 min-h-0 justify-between" }, _attrs))}><div class="flex flex-wrap items-center justify-between gap-2 p-2.5 bg-slate-900/90 border border-slate-800 rounded-2xl shadow-lg flex-shrink-0"><div class="flex items-center gap-1 bg-slate-950 p-1 rounded-xl border border-slate-800 text-xs font-bold"><button class="${ssrRenderClass([unref(activeTab) === "feed" ? "bg-sky-500 text-white shadow-md" : "text-slate-400 hover:text-white", "px-3 py-1.5 rounded-lg transition"])}"> Feed 4:5 </button><button class="${ssrRenderClass([unref(activeTab) === "story" ? "bg-indigo-500 text-white shadow-md" : "text-slate-400 hover:text-white", "px-3 py-1.5 rounded-lg transition"])}"> Story 9:16 </button><button class="${ssrRenderClass([unref(activeTab) === "reels" ? "bg-emerald-500 text-white shadow-md" : "text-slate-400 hover:text-white", "px-3 py-1.5 rounded-lg transition flex items-center gap-1.5"])}"><span>Reels 9:16 (Video)</span>`);
1113
+ _push(`<div${ssrRenderAttrs(mergeProps({ class: "flex flex-col gap-2.5 h-full text-slate-100 min-h-0 justify-between relative" }, _attrs))}>`);
1114
+ if (__props.isGenerating) {
1115
+ _push(`<div class="absolute inset-0 z-50 bg-slate-950/85 backdrop-blur-md rounded-2xl flex flex-col items-center justify-center p-6 text-center animate-in fade-in duration-200"><div class="relative flex items-center justify-center mb-5"><div class="w-20 h-20 rounded-full border-4 border-sky-500/20 border-t-sky-400 border-r-indigo-500 animate-spin"></div><div class="absolute inset-0 flex items-center justify-center">`);
1116
+ _push(ssrRenderComponent(unref(Sparkles), { class: "w-8 h-8 text-sky-400 animate-pulse" }, null, _parent));
1117
+ _push(`</div></div><h3 class="text-base font-black text-white tracking-wide mb-1.5"> Sedang Men-generate Konten... </h3><p class="text-xs text-sky-300 font-bold mb-4 flex items-center gap-2"><span class="w-2 h-2 rounded-full bg-sky-400 animate-ping"></span><span>${ssrInterpolate(__props.generateStage || "Merender Gambar & Video Reels...")}</span></p><div class="w-64 max-w-full bg-slate-900 border border-slate-800 rounded-full h-2.5 overflow-hidden shadow-inner mb-3"><div class="h-full bg-gradient-to-r from-sky-500 via-indigo-500 to-purple-500 rounded-full animate-pulse w-full"></div></div><span class="text-[10px] text-slate-400 font-mono tracking-wider uppercase"> Multi-Format Studio Engine \u2022 Mohon Tunggu Sebentar </span></div>`);
1118
+ } else {
1119
+ _push(`<!---->`);
1120
+ }
1121
+ _push(`<div class="flex flex-wrap items-center justify-between gap-2 p-2.5 bg-slate-900/90 border border-slate-800 rounded-2xl shadow-lg flex-shrink-0"><div class="flex items-center gap-1 bg-slate-950 p-1 rounded-xl border border-slate-800 text-xs font-bold"><button class="${ssrRenderClass([unref(activeTab) === "feed" ? "bg-sky-500 text-white shadow-md" : "text-slate-400 hover:text-white", "px-3 py-1.5 rounded-lg transition"])}"> Feed 4:5 </button><button class="${ssrRenderClass([unref(activeTab) === "story" ? "bg-indigo-500 text-white shadow-md" : "text-slate-400 hover:text-white", "px-3 py-1.5 rounded-lg transition"])}"> Story 9:16 </button><button class="${ssrRenderClass([unref(activeTab) === "reels" ? "bg-emerald-500 text-white shadow-md" : "text-slate-400 hover:text-white", "px-3 py-1.5 rounded-lg transition flex items-center gap-1.5"])}"><span>Reels 9:16 (Video)</span>`);
774
1122
  if (unref(activeTab) === "reels" && unref(isPlaying)) {
775
1123
  _push(`<span class="w-1.5 h-1.5 rounded-full bg-white animate-pulse"></span>`);
776
1124
  } else {
@@ -796,7 +1144,14 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
796
1144
  } else {
797
1145
  _push(`<!---->`);
798
1146
  }
799
- _push(`</div></div><div class="relative flex-1 min-h-0 bg-slate-950/80 border border-slate-800/80 rounded-2xl flex items-center justify-center p-3 overflow-auto shadow-inner custom-scrollbar"><div class="transition-transform duration-200 ease-out origin-center flex-shrink-0" style="${ssrRenderStyle({ transform: `scale(${unref(zoomScale)})` })}">`);
1147
+ _push(`</div></div><div class="relative flex-1 min-h-0 bg-slate-950/80 border border-slate-800/80 rounded-2xl flex p-4 overflow-auto shadow-inner custom-scrollbar"><div class="m-auto flex-shrink-0 relative transition-all duration-200 ease-out" style="${ssrRenderStyle({
1148
+ width: `${Math.round(unref(baseCanvasWidth) * unref(zoomScale))}px`,
1149
+ height: `${Math.round(unref(baseCanvasHeight) * unref(zoomScale))}px`
1150
+ })}"><div class="origin-top-left transition-transform duration-200 ease-out absolute top-0 left-0" style="${ssrRenderStyle({
1151
+ width: `${unref(baseCanvasWidth)}px`,
1152
+ height: `${unref(baseCanvasHeight)}px`,
1153
+ transform: `scale(${unref(zoomScale)})`
1154
+ })}">`);
800
1155
  if (unref(activeTab) === "feed") {
801
1156
  _push(`<div class="relative shadow-2xl rounded-2xl overflow-hidden border border-slate-700/80 flex-shrink-0" style="width:360px;height:450px;"><div style="width:1080px;height:1350px;transform:scale(0.333333);transform-origin:top left;">`);
802
1157
  _push(ssrRenderComponent(_component_TableCard, {
@@ -832,7 +1187,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
832
1187
  }
833
1188
  _push(`</div>`);
834
1189
  }
835
- _push(`</div></div>`);
1190
+ _push(`</div></div></div>`);
836
1191
  if (unref(activeTab) === "reels") {
837
1192
  _push(`<div class="flex flex-col bg-slate-900/95 border border-slate-800 rounded-2xl p-2.5 gap-2 shadow-xl flex-shrink-0 text-xs"><div class="flex items-center justify-between gap-3"><button class="p-2 rounded-xl bg-emerald-600 hover:bg-emerald-500 text-white font-bold transition flex items-center gap-1.5 shadow-md"${ssrRenderAttr("title", unref(isPlaying) ? "Pause Preview" : "Putar Preview")}>`);
838
1193
  if (unref(isPlaying)) {
@@ -868,19 +1223,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
868
1223
  } else {
869
1224
  _push(ssrRenderComponent(unref(Copy), { class: "w-3.5 h-3.5" }, null, _parent));
870
1225
  }
871
- _push(`<span>${ssrInterpolate(unref(copied) ? "Tersalin!" : "Copy Caption")}</span></button></div><textarea rows="2" class="w-full bg-slate-950 text-slate-200 text-xs p-2 rounded-xl border border-slate-800 focus:outline-none focus:border-sky-500/50 resize-none leading-relaxed font-sans" placeholder="Caption will appear here...">${ssrInterpolate(__props.data.caption)}</textarea></div>`);
872
- if (__props.generatedResult) {
873
- _push(`<div class="flex flex-wrap items-center justify-between gap-2 p-3 bg-emerald-950/40 border border-emerald-500/40 rounded-2xl shadow-xl flex-shrink-0"><div><div class="flex items-center gap-2 text-xs font-black text-emerald-300">`);
874
- _push(ssrRenderComponent(unref(Check), { class: "w-4 h-4 text-emerald-400" }, null, _parent));
875
- _push(` Render Selesai (${ssrInterpolate((__props.generatedResult.durationMs / 1e3).toFixed(1))}s) </div><div class="text-[11px] text-slate-400 font-mono mt-0.5">${ssrInterpolate(__props.generatedResult.jobId)}</div></div><div class="flex items-center gap-2"><a${ssrRenderAttr("href", `/api/download?jobId=${__props.generatedResult.jobId}`)} download class="inline-flex items-center gap-1.5 px-4 py-2 bg-emerald-600 hover:bg-emerald-500 text-white rounded-xl text-xs font-black shadow-lg transition">`);
876
- _push(ssrRenderComponent(unref(Download), { class: "w-3.5 h-3.5" }, null, _parent));
877
- _push(`<span>Download ZIP</span></a><button${ssrIncludeBooleanAttr(unref(isOpeningFolder)) ? " disabled" : ""} class="inline-flex items-center gap-1.5 px-4 py-2 bg-slate-800 hover:bg-slate-700 text-slate-200 border border-slate-700 rounded-xl text-xs font-bold transition">`);
878
- _push(ssrRenderComponent(unref(FolderOpen), { class: "w-3.5 h-3.5 text-amber-400" }, null, _parent));
879
- _push(`<span>Open Folder</span></button></div></div>`);
880
- } else {
881
- _push(`<!---->`);
882
- }
883
- _push(`</div>`);
1226
+ _push(`<span>${ssrInterpolate(unref(copied) ? "Tersalin!" : "Copy Caption")}</span></button></div><textarea rows="2" class="w-full bg-slate-950 text-slate-200 text-xs p-2 rounded-xl border border-slate-800 focus:outline-none focus:border-sky-500/50 resize-none leading-relaxed font-sans" placeholder="Caption will appear here...">${ssrInterpolate(__props.data.caption)}</textarea></div></div>`);
884
1227
  };
885
1228
  }
886
1229
  });
@@ -1268,6 +1611,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
1268
1611
  const toastMessage = ref("");
1269
1612
  const toastType = ref("success");
1270
1613
  const mobileTab = ref("editor");
1614
+ const showMobileCanvasModal = ref(false);
1271
1615
  const systemStatus = ref(null);
1272
1616
  const validationState = computed(() => {
1273
1617
  const res = ContentDataSchema.safeParse(contentData.value);
@@ -1364,7 +1708,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
1364
1708
  });
1365
1709
  if (res == null ? void 0 : res.success) {
1366
1710
  generatedResult.value = res;
1367
- showToast(`Sukses dirender dalam ${(res.durationMs / 1e3).toFixed(1)} detik!`);
1711
+ showToast(`\u2705 Generate selesai! Berhasil dirender dalam ${(res.durationMs / 1e3).toFixed(1)} detik.`, "success");
1368
1712
  }
1369
1713
  } catch (err) {
1370
1714
  showToast("Gagal render: " + (((_a = err.data) == null ? void 0 : _a.statusMessage) || err.message), "error");
@@ -1374,10 +1718,10 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
1374
1718
  }
1375
1719
  }
1376
1720
  return (_ctx, _push, _parent, _attrs) => {
1377
- var _a, _b;
1721
+ var _a, _b, _c, _d, _e, _f;
1378
1722
  const _component_DashboardControls = _sfc_main$2;
1379
1723
  const _component_LivePreview = _sfc_main$1;
1380
- _push(`<div${ssrRenderAttrs(mergeProps({ class: "h-screen w-screen bg-slate-950 text-slate-100 flex flex-col font-sans selection:bg-sky-500 selection:text-white overflow-hidden" }, _attrs))}><header class="h-14 flex-shrink-0 border-b border-slate-800/80 bg-slate-900/60 backdrop-blur sticky top-0 z-30 px-3 sm:px-6 flex items-center justify-between"><div class="flex items-center gap-2.5 sm:gap-3"><div class="w-8 h-8 rounded-xl bg-gradient-to-tr from-sky-500 via-indigo-600 to-purple-600 flex items-center justify-center font-black text-white shadow-md shadow-sky-500/20 text-xs"> SG </div><div><h1 class="text-sm font-extrabold tracking-tight text-white flex items-center gap-1.5 sm:gap-2"> SocialGen <span class="text-[9px] sm:text-[10px] font-bold px-2 py-0.5 rounded-full bg-slate-800 text-slate-300 border border-slate-700"> v${ssrInterpolate(((_a = unref(systemStatus)) == null ? void 0 : _a.version) || "2.3.5")}</span></h1></div></div><div class="flex items-center gap-2 sm:gap-3 text-xs">`);
1724
+ _push(`<div${ssrRenderAttrs(mergeProps({ class: "h-screen w-screen bg-slate-950 text-slate-100 flex flex-col font-sans selection:bg-sky-500 selection:text-white overflow-hidden" }, _attrs))}><header class="h-14 flex-shrink-0 border-b border-slate-800/80 bg-slate-900/60 backdrop-blur sticky top-0 z-30 px-3 sm:px-6 flex items-center justify-between"><div class="flex items-center gap-2.5 sm:gap-3"><div class="w-8 h-8 rounded-xl bg-gradient-to-tr from-sky-500 via-indigo-600 to-purple-600 flex items-center justify-center font-black text-white shadow-md shadow-sky-500/20 text-xs"> SG </div><div><h1 class="text-sm font-extrabold tracking-tight text-white flex items-center gap-1.5 sm:gap-2"> SocialGen <span class="text-[9px] sm:text-[10px] font-bold px-2 py-0.5 rounded-full bg-slate-800 text-slate-300 border border-slate-700"> v${ssrInterpolate(((_a = unref(systemStatus)) == null ? void 0 : _a.version) || "2.3.7")}</span></h1></div></div><div class="flex items-center gap-2 sm:gap-3 text-xs">`);
1381
1725
  if ((_b = unref(systemStatus)) == null ? void 0 : _b.geminiActive) {
1382
1726
  _push(`<span class="px-2.5 py-0.5 sm:py-1 rounded-full bg-emerald-500/10 text-emerald-400 border border-emerald-500/20 font-semibold text-[10px] sm:text-[11px]"> \u25CF AI Connected </span>`);
1383
1727
  } else {
@@ -1391,9 +1735,11 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
1391
1735
  }
1392
1736
  _push(`</button></div></div>`);
1393
1737
  if (unref(toastMessage)) {
1394
- _push(`<div class="${ssrRenderClass([unref(toastType) === "success" ? "bg-slate-900 text-slate-100 border-sky-500/50 shadow-sky-950/50" : "bg-rose-950 text-rose-200 border-rose-500/50", "fixed bottom-6 right-6 z-50 flex items-center gap-3 px-4 py-3 rounded-2xl shadow-2xl text-xs font-bold border transition-all"])}"><div class="flex items-center gap-2">`);
1738
+ _push(`<div class="${ssrRenderClass([unref(toastType) === "success" ? "bg-slate-900 text-slate-100 border-sky-500/50 shadow-sky-950/50" : unref(toastType) === "info" ? "bg-slate-900 text-sky-200 border-indigo-500/50 shadow-indigo-950/50" : "bg-rose-950 text-rose-200 border-rose-500/50", "fixed bottom-20 lg:bottom-6 right-4 lg:right-6 z-50 flex items-center gap-3 px-4 py-3 rounded-2xl shadow-2xl text-xs font-bold border transition-all max-w-[90vw]"])}"><div class="flex items-center gap-2">`);
1395
1739
  if (unref(toastType) === "success") {
1396
1740
  _push(`<span class="text-emerald-400">\u25CF</span>`);
1741
+ } else if (unref(toastType) === "info") {
1742
+ _push(`<span class="text-sky-400">\u2139\uFE0F</span>`);
1397
1743
  } else {
1398
1744
  _push(`<span class="text-rose-400">\u26A0\uFE0F</span>`);
1399
1745
  }
@@ -1444,11 +1790,56 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
1444
1790
  "onUpdate:videoStartOffset": ($event) => unref(options).videoStartOffset = $event,
1445
1791
  "audio-start-offset": unref(options).audioStartOffset,
1446
1792
  "onUpdate:audioStartOffset": ($event) => unref(options).audioStartOffset = $event,
1447
- "generated-result": unref(generatedResult)
1793
+ "is-generating": unref(isGenerating),
1794
+ "generate-stage": unref(generateStage)
1448
1795
  }, null, _parent));
1449
1796
  _push(`</section></main>`);
1450
1797
  if (unref(mobileTab) === "editor") {
1451
- _push(`<button class="lg:hidden fixed bottom-5 left-1/2 -translate-x-1/2 z-40 px-5 py-2.5 rounded-full bg-gradient-to-r from-sky-500 to-indigo-600 text-white font-extrabold text-xs shadow-2xl border border-sky-400/40 flex items-center gap-2 hover:opacity-95"><span>\u{1F441}\uFE0F Lihat Preview Canvas</span></button>`);
1798
+ _push(`<button type="button" class="lg:hidden fixed bottom-20 right-4 z-40 px-4 py-2.5 rounded-full bg-gradient-to-r from-sky-500 to-indigo-600 hover:from-sky-400 hover:to-indigo-500 text-white font-black text-xs shadow-2xl border border-sky-400/40 flex items-center gap-1.5 active:scale-95 transition"><span class="text-sm">\u{1F441}\uFE0F</span><span>Intip Canvas</span></button>`);
1799
+ } else {
1800
+ _push(`<!---->`);
1801
+ }
1802
+ if (unref(mobileTab) === "editor") {
1803
+ _push(`<div class="lg:hidden fixed bottom-0 left-0 right-0 z-30 h-16 px-4 bg-slate-900/95 backdrop-blur-lg border-t border-slate-800 flex items-center justify-between gap-3 shadow-2xl"><div class="flex flex-col"><span class="text-[9px] font-bold text-slate-400 uppercase tracking-wider">Output</span><div class="flex items-center gap-1 text-[10px] font-bold text-sky-400">`);
1804
+ if (((_c = unref(options).outputs) == null ? void 0 : _c.feed) !== false) {
1805
+ _push(`<span>Feed</span>`);
1806
+ } else {
1807
+ _push(`<!---->`);
1808
+ }
1809
+ if (((_d = unref(options).outputs) == null ? void 0 : _d.feed) !== false && ((_e = unref(options).outputs) == null ? void 0 : _e.reels) !== false) {
1810
+ _push(`<span>\u2022</span>`);
1811
+ } else {
1812
+ _push(`<!---->`);
1813
+ }
1814
+ if (((_f = unref(options).outputs) == null ? void 0 : _f.reels) !== false) {
1815
+ _push(`<span>Reels</span>`);
1816
+ } else {
1817
+ _push(`<!---->`);
1818
+ }
1819
+ _push(`</div></div><button${ssrIncludeBooleanAttr(unref(isGenerating) || !unref(validationState).isValid) ? " disabled" : ""} type="button" class="flex-1 py-3 px-4 rounded-2xl bg-gradient-to-r from-sky-500 to-indigo-600 hover:from-sky-400 hover:to-indigo-500 text-white font-black text-xs tracking-wide shadow-xl shadow-sky-500/25 flex items-center justify-center gap-2 active:scale-95 transition disabled:opacity-50">`);
1820
+ if (unref(isGenerating)) {
1821
+ _push(`<span class="animate-spin">\u{1F504}</span>`);
1822
+ } else {
1823
+ _push(`<span>\u{1F680}</span>`);
1824
+ }
1825
+ _push(`<span>${ssrInterpolate(unref(isGenerating) ? unref(generateStage) || "Rendering Content..." : "GENERATE SEKARANG")}</span></button></div>`);
1826
+ } else {
1827
+ _push(`<!---->`);
1828
+ }
1829
+ if (unref(showMobileCanvasModal)) {
1830
+ _push(`<div class="lg:hidden fixed inset-0 z-50 bg-slate-950 flex flex-col justify-between overflow-hidden animate-in slide-in-from-bottom"><div class="h-14 px-4 bg-slate-900/95 border-b border-slate-800 flex items-center justify-between shrink-0 shadow-md"><div class="flex items-center gap-2"><span class="w-2 h-2 rounded-full bg-emerald-400 animate-ping"></span><span class="text-xs font-black text-white">Preview Canvas Penuh</span></div><button type="button" class="px-3 py-1.5 rounded-xl bg-slate-800 hover:bg-slate-700 text-xs font-bold text-slate-200 border border-slate-700 flex items-center gap-1 active:scale-95 transition"><span>\u2715 Tutup Preview</span></button></div><div class="flex-1 overflow-hidden p-2 flex flex-col min-h-0">`);
1831
+ _push(ssrRenderComponent(_component_LivePreview, {
1832
+ data: unref(contentData),
1833
+ "selected-video": unref(options).backgroundSource,
1834
+ "selected-music": unref(options).musicFile,
1835
+ "video-start-offset": unref(options).videoStartOffset,
1836
+ "onUpdate:videoStartOffset": ($event) => unref(options).videoStartOffset = $event,
1837
+ "audio-start-offset": unref(options).audioStartOffset,
1838
+ "onUpdate:audioStartOffset": ($event) => unref(options).audioStartOffset = $event,
1839
+ "is-generating": unref(isGenerating),
1840
+ "generate-stage": unref(generateStage)
1841
+ }, null, _parent));
1842
+ _push(`</div><div class="h-16 px-4 bg-slate-900/95 border-t border-slate-800 flex items-center justify-between gap-2 shrink-0"><button type="button" class="flex-1 py-2.5 rounded-xl bg-slate-800 hover:bg-slate-700 text-xs font-bold text-slate-200 active:scale-95 transition"> \u270F\uFE0F Lanjut Edit Form </button><button${ssrIncludeBooleanAttr(unref(isGenerating) || !unref(validationState).isValid) ? " disabled" : ""} type="button" class="flex-1 py-2.5 rounded-xl bg-gradient-to-r from-sky-500 to-indigo-600 text-xs font-bold text-white shadow-lg active:scale-95 transition disabled:opacity-50"> \u{1F680} Langsung Render </button></div></div>`);
1452
1843
  } else {
1453
1844
  _push(`<!---->`);
1454
1845
  }
@@ -1464,4 +1855,4 @@ _sfc_main.setup = (props, ctx) => {
1464
1855
  };
1465
1856
 
1466
1857
  export { _sfc_main as default };
1467
- //# sourceMappingURL=pages-N8VcQ5jK.mjs.map
1858
+ //# sourceMappingURL=pages-DAxeAK3-.mjs.map