Skip to content

Commit 79b87da

Browse files
Code refactoring
1 parent df2dfa7 commit 79b87da

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

templates/index.html

+14-1
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,13 @@
55
<meta charset="utf-8">
66
<meta name="viewport" content="width=device-width,initial-scale=1.0">
77
<title>Portfolio Website</title>
8+
9+
<!-- Favicon -->
810
<link rel="icon" type="image/x-icon" href="{% static 'images/favicon.ico' %}">
11+
912
<!-- Custom CSS -->
1013
<link href="{% static 'css/styles.css' %}" rel="stylesheet">
14+
1115
</head>
1216
<body>
1317
<div class="container-fluid px-0">
@@ -132,6 +136,7 @@ <h2 class="fw-bold">About</h2>
132136
</div>
133137
</div>
134138
<div class="container">
139+
135140
{% if about_data %}
136141
<div class="row">
137142

@@ -153,6 +158,7 @@ <h5>{{ about.title }}</h5>
153158
{% else %}
154159
<h5 class="text-primary text-center">No Data</h5>
155160
{% endif %}
161+
156162
</div>
157163
</section>
158164
<!-- End About -->
@@ -170,6 +176,7 @@ <h2 class="fw-bold">Projects</h2>
170176
</div>
171177
</div>
172178
<div class="container">
179+
173180
{% if project_data %}
174181
<div class="row">
175182

@@ -208,13 +215,15 @@ <h5 class="card-title mb-3">{{ project.name }}</h5>
208215
{% else %}
209216
<h5 class="text-primary text-center">No Data</h5>
210217
{% endif %}
218+
211219
</div>
212220
</section>
213221
<!-- End Projects -->
214222

215223
<!-- Contact -->
216224
<section class="bg-primary p-5 p-sm-5 mt-5">
217225
<div class="container">
226+
218227
{% if contact_data %}
219228
<ul class="nav justify-content-center my-3">
220229
{% for contact in contact_data %}
@@ -237,10 +246,12 @@ <h5 class="text-primary text-center">No Data</h5>
237246
</a>
238247
</li>
239248
{% endfor %}
249+
240250
</ul>
241251
{% else %}
242252
<h5 class="bg-primary text-white text-center">No Data</h5>
243253
{% endif %}
254+
244255
</div>
245256
</section>
246257
<!-- End Contact-->
@@ -251,6 +262,7 @@ <h5 class="bg-primary text-white text-center">No Data</h5>
251262

252263
<!-- Footer -->
253264
<footer class="text-center py-4">
265+
254266
{% if footer_data %}
255267
<div class="container px-5 mb-2">
256268
{% for footer in footer_data %}
@@ -260,11 +272,12 @@ <h5 class="bg-primary text-white text-center">No Data</h5>
260272
{% else %}
261273
<h5 class="text-primary text-center">No Data</h5>
262274
{% endif %}
275+
263276
</footer>
264277
<!-- End Footer -->
265278

266279
<!-- Bootstrap JS -->
267280
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/js/bootstrap.bundle.min.js"></script>
268281

269282
</body>
270-
</html>
283+
</html>

0 commit comments

Comments
 (0)