-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
165 lines (148 loc) · 6.8 KB
/
index.html
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
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Galeria de Michis</title>
<link href="assets/css/bootstrap.min.css" rel="stylesheet">
</head>
<body>
<header>
<div class="collapse bg-dark" id="navbarHeader">
<div class="container">
<div class="row">
<div class="col-sm-8 col-md-7 py-4">
<h4 class="text-white">Acerca</h4>
<p class="text-white">Consumo de API con Javascript</p>
</div>
<div class="col-sm-4 offset-md-1 py-4">
<h4 class="text-white">Contacto</h4>
<ul class="list-unstyled">
<li><a href="#" class="text-white">developersv@hotmail.com</a></li>
</ul>
</div>
</div>
</div>
</div>
<div class="navbar navbar-dark bg-dark shadow-sm">
<div class="container">
<a href="#" class="navbar-brand d-flex align-items-center">
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" aria-hidden="true" class="me-2" viewBox="0 0 24 24"><path d="M23 19a2 2 0 0 1-2 2H3a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h4l2-3h6l2 3h4a2 2 0 0 1 2 2z"/><circle cx="12" cy="13" r="4"/></svg>
<strong>GATOS</strong>
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarHeader" aria-controls="navbarHeader" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
</div>
</div>
</header>
<main>
<section class="py-1 text-center container">
<div class="row py-lg-4">
<div class="col-lg-6 col-md-8 mx-auto">
<h1 class="fw-light">Galería de Gatos</h1>
<p class="lead text-muted">La galería de Gatos se carga a usando la API https://docs.thecatapi.com</p>
</div>
</div>
</section>
<div class="bg-light p-3 rounded text-center">
<input type="button" id="btnReloadCats" class="btn btn-primary my-2" value="Cargar otros gatos">
<input type="button" id="btnOpenModal" class="btn btn-success my-2" value="Subir fotografía" data-bs-toggle="modal" data-bs-target="#exampleModal">
</div>
<div class="alert alert-danger" role="alert" id="error"></div>
<div class="album py-5 bg-light">
<div class="container">
<div class="row row-cols-1 row-cols-sm-2 row-cols-md-3 g-3">
<div class="col">
<div class="card shadow-sm">
<img id="img1" alt="Foto de gatito aleatorio" height="200" width="100%" />
<div class="card-body">
<p class="card-text"></p>
<div class="d-flex justify-content-between align-items-center">
<div class="btn-group">
<button type="button" class="btn btn-sm btn-outline-secondary" id="btnFavorito1">Favorito</button>
</div>
<small class="text-muted"></small>
</div>
</div>
</div>
</div>
<div class="col">
<div class="card shadow-sm">
<img id="img2" alt="Foto de gatito aleatorio" height="200" width="100%" />
<div class="card-body">
<p class="card-text"></p>
<div class="d-flex justify-content-between align-items-center">
<div class="btn-group">
<button type="button" class="btn btn-sm btn-outline-secondary" id="btnFavorito2">Favorito</button>
</div>
<small class="text-muted"></small>
</div>
</div>
</div>
</div>
<div class="col">
<div class="card shadow-sm">
<img id="img3" alt="Foto de gatito aleatorio" height="200" width="100%" />
<div class="card-body">
<p class="card-text"></p>
<div class="d-flex justify-content-between align-items-center">
<div class="btn-group">
<button type="button" class="btn btn-sm btn-outline-secondary" id="btnFavorito3">Favorito</button>
</div>
<small class="text-muted"></small>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<section class="py-1 text-center container">
<div class="row py-lg-4">
<div class="col-lg-6 col-md-8 mx-auto">
<h1 class="fw-light">Gatos favoritos</h1>
<p class="lead text-muted">Mis gatos favoritos</p>
</div>
</div>
</section>
<div class="album py-5 bg-light">
<div class="container">
<div class="row row-cols-1 row-cols-sm-2 row-cols-md-3 g-3" id="subContenedor">
</div>
</div>
</div>
</main>
<!-- Modal -->
<div class="modal fade" id="exampleModal" tabindex="-1" aria-labelledby="exampleModalLabel" aria-hidden="true">
<div class="modal-dialog">
<form id="frmFoto">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="exampleModalLabel">Subir foto de gatito</h5>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">
<input class="form-control form-control-lg" id="filePicCat" type="file" name="file">
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">Cerrar</button>
<button type="button" class="btn btn-primary" onclick="UploadPicCat();">Guardar</button>
</div>
</div>
</form>
</div>
</div>
<footer class="text-muted py-5">
<div class="container">
<p class="float-end mb-1">
<a href="#">Ir arriba</a>
</p>
</div>
</footer>
</body>
<script src="assets/js/bootstrap.bundle.min.js"></script>
<script src="https://code.jquery.com/jquery-3.6.0.min.js" integrity="sha256-/xUj+3OJU5yExlq6GSYGSHk7tPXikynS7ogEvDej/m4=" crossorigin="anonymous"></script>
<script src="main.js"></script>
</html>