File size: 3,836 Bytes
56bf851
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
import React, { useState } from "react";

const TroubleshootingGuide = ({ generatedDataLink, onDownload }) => {
  const [isExpanded, setIsExpanded] = useState(false);

  return (
    <div className="troubleshooting-guide" style={{ marginTop: "1rem" }}>
      <button
        className="btn btn-outline btn-small"
        onClick={() => setIsExpanded(!isExpanded)}
        style={{
          display: "flex",
          alignItems: "center",
          gap: "0.5rem",
          fontSize: "0.875rem",
          padding: "0.5rem 1rem",
        }}
      >
        {isExpanded ? "πŸ”½" : "πŸ”"} Troubleshooting Guide
      </button>

      {isExpanded && (
        <div
          className="troubleshooting-content"
          style={{
            marginTop: "1rem",
            padding: "1rem",
            background: "var(--bg-tertiary)",
            borderRadius: "8px",
            border: "1px solid var(--border-color)",
            fontSize: "0.875rem",
            lineHeight: "1.6",
          }}
        >
          <h5 style={{ marginBottom: "1rem", color: "var(--text-primary)" }}>
            πŸ› οΈ Common Issues and Solutions
          </h5>

          <div
            className="troubleshooting-section"
            style={{ marginBottom: "1rem" }}
          >
            <strong>πŸ“± Preview not working?</strong>
            <ul style={{ marginTop: "0.5rem", paddingLeft: "1.5rem" }}>
              <li>
                This is normal! Browser security prevents previewing some files
              </li>
              <li>Your data has been generated successfully</li>
              <li>Click the download button to get your file</li>
            </ul>
          </div>

          <div
            className="troubleshooting-section"
            style={{ marginBottom: "1rem" }}
          >
            <strong>πŸ’Ύ Download not working?</strong>
            <ul style={{ marginTop: "0.5rem", paddingLeft: "1.5rem" }}>
              <li>Check if your browser blocked popups</li>
              <li>
                Try right-clicking the download button and select "Open in new
                tab"
              </li>
              <li>Copy the link and paste it in a new browser tab</li>
            </ul>
          </div>

          <div
            className="troubleshooting-section"
            style={{ marginBottom: "1rem" }}
          >
            <strong>πŸ”— Direct download link:</strong>
            <div
              style={{
                marginTop: "0.5rem",
                padding: "0.5rem",
                background: "var(--bg-secondary)",
                borderRadius: "4px",
                fontFamily: "monospace",
                fontSize: "0.75rem",
                wordBreak: "break-all",
                border: "1px solid var(--border-color)",
              }}
            >
              {generatedDataLink}
            </div>
            <div style={{ marginTop: "0.5rem", textAlign: "center" }}>
              <button
                className="btn btn-small"
                onClick={() => navigator.clipboard.writeText(generatedDataLink)}
                style={{ fontSize: "0.75rem", padding: "0.25rem 0.5rem" }}
              >
                πŸ“‹ Copy Link
              </button>
            </div>
          </div>

          <div className="troubleshooting-section">
            <strong>❓ Still having issues?</strong>
            <ul style={{ marginTop: "0.5rem", paddingLeft: "1.5rem" }}>
              <li>Try using a different browser (Chrome, Firefox, Safari)</li>
              <li>Disable browser extensions temporarily</li>
              <li>Check if your antivirus is blocking downloads</li>
              <li>Contact support if problems persist</li>
            </ul>
          </div>
        </div>
      )}
    </div>
  );
};

export default TroubleshootingGuide;