mirror of
https://github.com/welton89/RRBEC.git
synced 2026-04-05 21:45:41 +00:00
tentanto implementar uma modal
This commit is contained in:
Binary file not shown.
Binary file not shown.
@@ -44,6 +44,7 @@ INSTALLED_APPS = [
|
||||
'clients',
|
||||
'comandas',
|
||||
'categories',
|
||||
'home',
|
||||
]
|
||||
|
||||
MIDDLEWARE = [
|
||||
|
||||
BIN
gestaoRaul/home/__pycache__/admin.cpython-310.pyc
Normal file
BIN
gestaoRaul/home/__pycache__/admin.cpython-310.pyc
Normal file
Binary file not shown.
BIN
gestaoRaul/home/__pycache__/apps.cpython-310.pyc
Normal file
BIN
gestaoRaul/home/__pycache__/apps.cpython-310.pyc
Normal file
Binary file not shown.
BIN
gestaoRaul/home/__pycache__/models.cpython-310.pyc
Normal file
BIN
gestaoRaul/home/__pycache__/models.cpython-310.pyc
Normal file
Binary file not shown.
BIN
gestaoRaul/home/migrations/__pycache__/__init__.cpython-310.pyc
Normal file
BIN
gestaoRaul/home/migrations/__pycache__/__init__.cpython-310.pyc
Normal file
Binary file not shown.
@@ -3,7 +3,10 @@
|
||||
|
||||
|
||||
{% block 'head' %}
|
||||
<link rel="stylesheet" href="{% static 'mesas/css/mesas.css' %}">
|
||||
<link rel="stylesheet" href="{% static 'products/css/products.css' %}">
|
||||
<script src="{% static 'products/js/products.js' %}"></script>
|
||||
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.2.3/dist/js/bootstrap.bundle.min.js"></script>
|
||||
|
||||
{% endblock %}
|
||||
|
||||
{% block 'title' %}
|
||||
@@ -18,10 +21,15 @@ Produtos
|
||||
|
||||
<body>
|
||||
<div class="grid-container">
|
||||
<button type="button" class="btn btn-primary" data-bs-toggle="modal" data-bs-target="#exampleModal">
|
||||
Abrir Modal
|
||||
</button>
|
||||
|
||||
{% for product in products %}
|
||||
|
||||
<div class="card">{{product.name}}</div>
|
||||
<div class="card">
|
||||
{{product.name}}
|
||||
</div>
|
||||
|
||||
{% endfor %}
|
||||
|
||||
@@ -29,5 +37,31 @@ Produtos
|
||||
</div>
|
||||
</body>
|
||||
|
||||
{% comment %} <dialog open>
|
||||
<h2>Titulo modal</h2>
|
||||
<p>texto qualquer</p>
|
||||
</dialog> {% endcomment %}
|
||||
|
||||
|
||||
|
||||
<div class="modal fade" id="exampleModal" tabindex="-1" aria-labelledby="exampleModalLabel" aria-hidden="true">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title" id="exampleModalLabel">Título do Modal</h5>
|
||||
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
Conteúdo do seu modal.
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">Fechar</button>
|
||||
<button type="button" class="btn btn-primary">Salvar mudanças</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
{% endblock %}
|
||||
@@ -7,6 +7,7 @@
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@5.2.3/dist/css/bootstrap.min.css">
|
||||
<link rel="stylesheet" href="{% static 'base.css' %}">
|
||||
{% block 'head' %}{% endblock %}
|
||||
<title> {% block 'title' %}{% endblock %} </title>
|
||||
|
||||
@@ -0,0 +1,77 @@
|
||||
/* style.css */
|
||||
|
||||
.modal {
|
||||
display: none; /* Oculta o modal por padrão */
|
||||
position: fixed; /* Posiciona o modal fixo na tela */
|
||||
z-index: 1; /* Garante que o modal fique acima de outros elementos */
|
||||
left: 0;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
overflow: auto; /* Permite rolagem se o conteúdo for muito grande */
|
||||
background-color: rgba(0,0,0,0.4); /* Fundo escurecido */
|
||||
}
|
||||
|
||||
.modal-content {
|
||||
background-color: #fefefe;
|
||||
margin: 15% auto; /* 15% from the top and centered */
|
||||
padding: 20px;
|
||||
border: 1px solid #888;
|
||||
width: 80%;
|
||||
}
|
||||
|
||||
.close {
|
||||
color: #aaa;
|
||||
float: right;
|
||||
font-size: 28px;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.close:hover,
|
||||
.close:focus {
|
||||
color: black;
|
||||
text-decoration: none;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.grid-container {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(2, 1fr);
|
||||
gap: 20px;
|
||||
max-width: 1100px; /* Define a largura máxima do grid */
|
||||
margin: 0 auto; /* Centraliza o grid na página */
|
||||
}
|
||||
|
||||
.card {
|
||||
width: 100%;
|
||||
height: 80px;
|
||||
background-color: #f2f2f2;
|
||||
border-radius: 15px;
|
||||
box-shadow: 5px 5px 10px rgba(0, 0, 0, 0.2);
|
||||
text-align: center;
|
||||
line-height: 120px; /* Centraliza o texto verticalmente */
|
||||
font-size: 20px;
|
||||
font-weight: bold;
|
||||
color: #333;
|
||||
transition: transform 0.2s;
|
||||
}
|
||||
|
||||
.card:hover {
|
||||
transform: scale(1.05);
|
||||
box-shadow: 10px 10px 20px rgba(0, 0, 0, 0.3);
|
||||
}
|
||||
|
||||
|
||||
dialog::backdrop {
|
||||
background-color: rgb(0 0 0 / .5);
|
||||
}
|
||||
|
||||
dialog {
|
||||
border: none;
|
||||
border-radius: .5rem;
|
||||
box-shadow: 0 0 1em rgb(0 0 0 / .3);
|
||||
width: 80%;
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,2 @@
|
||||
|
||||
|
||||
Reference in New Issue
Block a user