Spaces:
Runtime error
Runtime error
Commit
·
13942c8
1
Parent(s):
390a6d5
Update templates/output.html
Browse files- templates/output.html +141 -41
templates/output.html
CHANGED
|
@@ -1,72 +1,172 @@
|
|
| 1 |
<!DOCTYPE html>
|
| 2 |
-
<html
|
| 3 |
<head>
|
| 4 |
-
<
|
| 5 |
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
| 6 |
-
<
|
|
|
|
| 7 |
<style>
|
| 8 |
body {
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
padding: 0;
|
| 13 |
-
display: flex;
|
| 14 |
-
justify-content: center;
|
| 15 |
-
align-items: center;
|
| 16 |
-
min-height: 100vh;
|
| 17 |
}
|
| 18 |
-
|
| 19 |
-
|
| 20 |
max-width: 800px;
|
| 21 |
-
|
| 22 |
-
|
|
|
|
| 23 |
border-radius: 10px;
|
| 24 |
-
box-shadow:
|
| 25 |
}
|
|
|
|
| 26 |
h1 {
|
| 27 |
text-align: center;
|
| 28 |
-
color: #333333;
|
| 29 |
margin-bottom: 30px;
|
| 30 |
}
|
| 31 |
-
|
|
|
|
| 32 |
text-align: center;
|
| 33 |
-
margin-
|
| 34 |
}
|
| 35 |
-
|
|
|
|
| 36 |
max-width: 100%;
|
| 37 |
-
|
| 38 |
-
border: 1px solid #ddd;
|
| 39 |
border-radius: 5px;
|
|
|
|
|
|
|
|
|
|
| 40 |
}
|
| 41 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 42 |
text-align: center;
|
| 43 |
-
margin-top:
|
| 44 |
}
|
| 45 |
-
|
| 46 |
-
|
| 47 |
-
background-color: #
|
| 48 |
-
color:
|
|
|
|
| 49 |
border: none;
|
| 50 |
-
padding: 10px 20px;
|
| 51 |
-
cursor: pointer;
|
| 52 |
border-radius: 5px;
|
| 53 |
-
|
| 54 |
-
|
|
|
|
| 55 |
}
|
| 56 |
-
|
| 57 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 58 |
}
|
| 59 |
</style>
|
| 60 |
</head>
|
| 61 |
<body>
|
| 62 |
-
<div
|
| 63 |
-
<h1>
|
| 64 |
-
<div
|
| 65 |
-
<img src="{{ url_for('
|
|
|
|
|
|
|
|
|
|
| 66 |
</div>
|
| 67 |
-
<div
|
| 68 |
-
<
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 69 |
</div>
|
| 70 |
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 71 |
</body>
|
| 72 |
-
</html>
|
|
|
|
| 1 |
<!DOCTYPE html>
|
| 2 |
+
<html>
|
| 3 |
<head>
|
| 4 |
+
<title>Generated Image</title>
|
| 5 |
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
| 6 |
+
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@5.5.0/dist/css/bootstrap.min.css">
|
| 7 |
+
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css">
|
| 8 |
<style>
|
| 9 |
body {
|
| 10 |
+
background-color: #000000;
|
| 11 |
+
color: #ffffff;
|
| 12 |
+
font-family: Arial, sans-serif;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 13 |
}
|
| 14 |
+
|
| 15 |
+
.container {
|
| 16 |
max-width: 800px;
|
| 17 |
+
margin: 0 auto;
|
| 18 |
+
padding: 40px;
|
| 19 |
+
background-color: #222222;
|
| 20 |
border-radius: 10px;
|
| 21 |
+
box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
|
| 22 |
}
|
| 23 |
+
|
| 24 |
h1 {
|
| 25 |
text-align: center;
|
|
|
|
| 26 |
margin-bottom: 30px;
|
| 27 |
}
|
| 28 |
+
|
| 29 |
+
.image-container {
|
| 30 |
text-align: center;
|
| 31 |
+
margin-bottom: 30px;
|
| 32 |
}
|
| 33 |
+
|
| 34 |
+
img {
|
| 35 |
max-width: 100%;
|
| 36 |
+
height: auto;
|
|
|
|
| 37 |
border-radius: 5px;
|
| 38 |
+
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
|
| 39 |
+
transition: all 0.3s ease;
|
| 40 |
+
cursor: pointer;
|
| 41 |
}
|
| 42 |
+
|
| 43 |
+
.enlarged {
|
| 44 |
+
position: fixed;
|
| 45 |
+
top: 0;
|
| 46 |
+
left: 0;
|
| 47 |
+
width: 100%;
|
| 48 |
+
height: 100%;
|
| 49 |
+
background-color: rgba(0, 0, 0, 0.9);
|
| 50 |
+
display: flex;
|
| 51 |
+
justify-content: center;
|
| 52 |
+
align-items: center;
|
| 53 |
+
z-index: 9999;
|
| 54 |
+
}
|
| 55 |
+
|
| 56 |
+
.enlarged img {
|
| 57 |
+
max-width: 90%;
|
| 58 |
+
max-height: 90%;
|
| 59 |
+
border-radius: 5px;
|
| 60 |
+
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
|
| 61 |
+
}
|
| 62 |
+
|
| 63 |
+
.button-container {
|
| 64 |
text-align: center;
|
| 65 |
+
margin-top: 30px;
|
| 66 |
}
|
| 67 |
+
|
| 68 |
+
.btn {
|
| 69 |
+
background-color: #4CAF50;
|
| 70 |
+
color: #ffffff;
|
| 71 |
+
padding: 12px 24px;
|
| 72 |
border: none;
|
|
|
|
|
|
|
| 73 |
border-radius: 5px;
|
| 74 |
+
cursor: pointer;
|
| 75 |
+
font-size: 16px;
|
| 76 |
+
transition: background-color 0.3s ease;
|
| 77 |
}
|
| 78 |
+
|
| 79 |
+
.btn:hover {
|
| 80 |
+
background-color: #45a049;
|
| 81 |
+
}
|
| 82 |
+
|
| 83 |
+
.image-details {
|
| 84 |
+
text-align: center;
|
| 85 |
+
margin-top: 30px;
|
| 86 |
+
font-size: 16px;
|
| 87 |
+
}
|
| 88 |
+
|
| 89 |
+
.social-buttons {
|
| 90 |
+
text-align: center;
|
| 91 |
+
margin-top: 30px;
|
| 92 |
+
}
|
| 93 |
+
|
| 94 |
+
.social-button {
|
| 95 |
+
display: inline-block;
|
| 96 |
+
margin-right: 10px;
|
| 97 |
+
}
|
| 98 |
+
|
| 99 |
+
.social-icon {
|
| 100 |
+
color: #ffffff;
|
| 101 |
+
font-size: 24px;
|
| 102 |
+
transition: color 0.3s ease;
|
| 103 |
+
}
|
| 104 |
+
|
| 105 |
+
.social-icon:hover {
|
| 106 |
+
color: #4CAF50;
|
| 107 |
+
}
|
| 108 |
+
|
| 109 |
+
footer {
|
| 110 |
+
padding: 20px;
|
| 111 |
+
text-align: center;
|
| 112 |
+
}
|
| 113 |
+
|
| 114 |
+
/* Responsive Styles */
|
| 115 |
+
@media only screen and (max-width: 500px) {
|
| 116 |
+
.container {
|
| 117 |
+
padding: 20px;
|
| 118 |
+
}
|
| 119 |
}
|
| 120 |
</style>
|
| 121 |
</head>
|
| 122 |
<body>
|
| 123 |
+
<div class="container">
|
| 124 |
+
<h1>Generated Image</h1>
|
| 125 |
+
<div class="image-container">
|
| 126 |
+
<img src="{{ url_for('output_files', filename='filename') }}" alt="Generated Image" onclick="toggleImageSize(this)">
|
| 127 |
+
</div>
|
| 128 |
+
<div class="button-container">
|
| 129 |
+
<a href="/output_files/output.png" class="btn btn-success" onclick="downloadImage()"><i class="fas fa-download"></i> Download Image</a>
|
| 130 |
</div>
|
| 131 |
+
<div class="image-details">
|
| 132 |
+
<p>Image Size: 1200x800 pixels</p>
|
| 133 |
+
<p>File Format: JPEG</p>
|
| 134 |
+
</div>
|
| 135 |
+
<div class="social-buttons">
|
| 136 |
+
<span class="social-button">
|
| 137 |
+
<a href="https://www.facebook.com/octaeldrith" class="social-icon"><i class="fab fa-facebook"></i></a>
|
| 138 |
+
</span>
|
| 139 |
+
<span class="social-button">
|
| 140 |
+
<a href="https://twitter.com/ims_eldrith" class="social-icon"><i class="fab fa-twitter"></i></a>
|
| 141 |
+
</span>
|
| 142 |
+
<span class="social-button">
|
| 143 |
+
<a href="https://www.instagram.com/ims_eldrith" class="social-icon"><i class="fab fa-instagram"></i></a>
|
| 144 |
+
</span>
|
| 145 |
+
<span class="social-button">
|
| 146 |
+
<a href="https://linkedin.com/in/ashiq-hussain" class="social-icon"><i class="fab fa-linkedin"></i></a>
|
| 147 |
+
</span>
|
| 148 |
</div>
|
| 149 |
</div>
|
| 150 |
+
|
| 151 |
+
<script>
|
| 152 |
+
function downloadImage() {
|
| 153 |
+
var link = document.createElement('a');
|
| 154 |
+
link.href = '/output_files/filename';
|
| 155 |
+
link.download = 'generated_image.jpg';
|
| 156 |
+
link.click();
|
| 157 |
+
}
|
| 158 |
+
|
| 159 |
+
function toggleImageSize(image) {
|
| 160 |
+
if (image.classList.contains('enlarged')) {
|
| 161 |
+
image.classList.remove('enlarged');
|
| 162 |
+
} else {
|
| 163 |
+
image.classList.add('enlarged');
|
| 164 |
+
}
|
| 165 |
+
}
|
| 166 |
+
</script>
|
| 167 |
+
<footer>
|
| 168 |
+
<p>Built with ❤️ by <a href="https://codegenius.me" style="color: red;">Ashiq Hussain Mir</a></p>
|
| 169 |
+
</footer>
|
| 170 |
+
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.5.0/dist/js/bootstrap.bundle.min.js"></script>
|
| 171 |
</body>
|
| 172 |
+
</html>
|