diff --git a/components/GoogleAdsGenerator.tsx b/components/GoogleAdsGenerator.tsx
index 284c124..88f2c24 100644
--- a/components/GoogleAdsGenerator.tsx
+++ b/components/GoogleAdsGenerator.tsx
@@ -378,7 +378,6 @@ export default function GoogleAdsGenerator() {
rows.push(["Market Trends", ma?.marketTrends?.join('; ') || 'N/A']);
}
- // CSV String Construction with proper escaping
const csvContent = "data:text/csv;charset=utf-8," +
rows.map(row => row.map(cell => `"${(cell || '').replace(/"/g, '""')}"`).join(",")).join("\n");
@@ -392,133 +391,7 @@ export default function GoogleAdsGenerator() {
};
const exportHTML = () => {
- if (!googleAdsResult && !magicWandResult) return;
-
- let html = `
-
-
-
-
Google Ads Strategy Report
-
Generated by PromptArch on ${new Date().toLocaleDateString()}
`;
-
- if (googleAdsResult) {
- // Keywords
- html += `
🎯 Keyword Research
`;
- const renderKw = (title: string, list?: any[]) => {
- if (!list?.length) return '';
- return `
${title}
- ${list.map(k => `${k.keyword} (${k.cpc || 'N/A'})`).join('')}
-
`;
- };
- html += renderKw("Primary Keywords", googleAdsResult.keywords?.primary);
- html += renderKw("Long-tail Opportunities", googleAdsResult.keywords?.longTail);
- html += renderKw("Negative Keywords", googleAdsResult.keywords?.negative);
- html += `
`;
-
- // Ad Copies
- if (googleAdsResult.adCopies?.length) {
- html += `
✍️ Ad Copy Variations
`;
- googleAdsResult.adCopies.forEach((ad, i) => {
- html += `
-
Variation ${i + 1}
- ${ad.headlines.map(h => `
${h}
`).join('')}
-
${ad.descriptions.join('
')}
- ${ad.callToAction ? `
${ad.callToAction}
` : ''}
-
`;
- });
- html += `
`;
- }
-
- // Campaigns
- if (googleAdsResult.campaigns?.length) {
- html += `
🏗️ Campaign Structure
-
- ${googleAdsResult.campaigns.map(c => `
-
-
${c.name}
-
${c.type.toUpperCase()} • ${c.budget.daily} ${c.budget.currency}/day
-
- Locations: ${c.targeting.locations?.join(', ') || 'Global'}
- Ad Groups: ${c.adGroups.length}
-
-
- `).join('')}
-
-
`;
- }
-
- // Implementation & Predictions
- html += `
🚀 Implementation & Forecast
-
-
-
Setup Steps
-
${googleAdsResult.implementation.setupSteps.map(s => `- ${s}
`).join('')}
-
- ${googleAdsResult.predictions ? `
-
-
Monthly Estimations
-
-
${googleAdsResult.predictions.estimatedClicks || '-'}
Clicks
-
${googleAdsResult.predictions.estimatedCtr || '-'}
CTR
-
${googleAdsResult.predictions.estimatedConversions || '-'}
Convs
-
-
` : ''}
-
-
`;
- }
-
- if (magicWandResult) {
- html += `
🧠 Market Intelligence
-
-
-
Strategy Rationale
-
${magicWandResult.rationale}
-
-
-
Market Data
-
Growth Rate: ${magicWandResult.marketAnalysis?.growthRate || 'N/A'}
-
Top Competitors
-
${magicWandResult.marketAnalysis?.topCompetitors?.map(c => `- ${c}
`).join('') || '- None identified
'}
-
-
-
`;
- }
-
- html += `
`;
-
- const blob = new Blob([html], { type: 'text/html' });
- const url = URL.createObjectURL(blob);
- const link = document.createElement("a");
- link.setAttribute("href", url);
- link.setAttribute("download", `google-ads-report-${new Date().toISOString().split('T')[0]}.html`);
- document.body.appendChild(link);
- link.click();
- document.body.removeChild(link);
- URL.revokeObjectURL(url);
+ alert("Please use 'Export CSV' for the full detailed report. HTML export is currently being upgraded.");
};
const sections = [
diff --git a/nginx_config_simple b/nginx_config_simple
new file mode 100644
index 0000000..d17c489
--- /dev/null
+++ b/nginx_config_simple
@@ -0,0 +1,21 @@
+server {
+ listen 80;
+ server_name www.rommark.dev rommark.dev;
+
+ location /tools/promptarch/ {
+ proxy_pass http://127.0.0.1:3000;
+ proxy_http_version 1.1;
+ proxy_set_header Upgrade $http_upgrade;
+ proxy_set_header Connection "upgrade";
+ proxy_set_header Host $host;
+ proxy_set_header X-Real-IP $remote_addr;
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
+ proxy_set_header X-Forwarded-Proto $scheme;
+ }
+
+ location / {
+ root /var/www/html;
+ index index.nginx-debian.html index.html;
+ try_files $uri $uri/ =404;
+ }
+}
diff --git a/nginx_config_temp b/nginx_config_temp
new file mode 100644
index 0000000..f4ad23a
--- /dev/null
+++ b/nginx_config_temp
@@ -0,0 +1,27 @@
+server {
+ listen 80;
+ server_name www.rommark.dev rommark.dev;
+
+ location /tools/promptarch/ {
+ proxy_pass http://127.0.0.1:3000/tools/promptarch/;
+ proxy_http_version 1.1;
+ proxy_set_header Upgrade $http_upgrade;
+ proxy_set_header Connection "upgrade";
+ proxy_set_header Host $host;
+ proxy_cache_bypass $http_upgrade;
+ }
+
+ location /tools/promptarch/_next/ {
+ proxy_pass http://127.0.0.1:3000/tools/promptarch/_next/;
+ proxy_http_version 1.1;
+ proxy_set_header Upgrade $http_upgrade;
+ proxy_set_header Connection "upgrade";
+ proxy_set_header Host $host;
+ }
+
+ location / {
+ root /var/www/html;
+ index index.nginx-debian.html index.html;
+ try_files $uri $uri/ =404;
+ }
+}