Skip to content

Commit

Permalink
Update index.html
Browse files Browse the repository at this point in the history
  • Loading branch information
davespser authored Dec 7, 2024
1 parent 689df1d commit 85f508c
Showing 1 changed file with 29 additions and 4 deletions.
33 changes: 29 additions & 4 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,26 @@
<link rel="stylesheet" href="style.css"
<style>
<!-- Contenedor del menú -->
<div id="menu-container">
<div class="menu-item" data-action="option1">
<span>🔧</span> Opción 1
</div>
menu-item {
background-color: #3498db;
clip-path: polygon(0% 0%, 100% 0%, 85% 100%, 0% 100%);
padding: 10px;
margin-bottom: 5px;
cursor: pointer;
color: white;
}
.menu-content {
display: none;
padding: 10px;
background-color: #f1f1f1;
border: 1px solid #ccc;
}
#toggle:checked + .menu-content {
display: block;
}
.hidden-input {
display: none;
}
<div class="menu-item" data-action="option2">
<span>🎵</span> Opción 2
</div>
Expand Down Expand Up @@ -43,6 +59,15 @@
<body>

<div id="menu-button">Abrir Menú</div>
<div id="menu-container">
<label for="toggle" class="menu-item" data-action="option1">
<span>🔧</span> Opción 1
</label>
<input type="checkbox" id="toggle" class="hidden-input">
<div class="menu-content">
<p>Este es el contenido desplegable.</p>
</div>
</div


<script type="module" src="js/app.js"></script>
Expand Down

0 comments on commit 85f508c

Please sign in to comment.