-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #44 from UNIZAR-30226-2024-03/dinamic-pages
Dinamic pages
- Loading branch information
Showing
13 changed files
with
182 additions
and
111 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
--- | ||
import TagsTabs from '@components/TagsTabs.astro'; | ||
const {audio} = Astro.params | ||
console.log(audio) | ||
--- | ||
|
||
<div class="flex flex-col gap-3"> | ||
<h2 class="text-xl font-medium">Modifica tu audio</h2> | ||
<form class="flex flex-col items-center gap-3 pt-4" onsubmit="uploadAudio(event)"> | ||
<div class="flex flex-row items-center w-full gap-3"> | ||
|
||
<section class="flex flex-col"> | ||
<input type="file" id="addFoto" name="photo" class=" text-white p-2 rounded-md hidden" onchange="previewImage(event)" /> | ||
<div class=" w-64 aspect-square mt-2 cursor-pointer bg-[#333] rounded-md border-2 border-[#c5c5c5] flex justify-center items-center" onclick="document.getElementById('addFoto').click();"> | ||
<img id="preview" class="w-64 aspect-square rounded-md hidden" /> | ||
<svg xmlns="http://www.w3.org/2000/svg" width="70" height="70" viewBox="0 0 24 24" fill="none" stroke="#c5c5c5" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" class="icon icon-tabler icons-tabler-outline icon-tabler-photo"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M15 8h.01" /><path d="M3 6a3 3 0 0 1 3 -3h12a3 3 0 0 1 3 3v12a3 3 0 0 1 -3 3h-12a3 3 0 0 1 -3 -3v-12z" /><path d="M3 16l5 -5c.928 -.893 2.072 -.893 3 0l5 5" /><path d="M14 14l1 -1c.928 -.893 2.072 -.893 3 0l3 3" /></svg> | ||
</div> | ||
</section> | ||
<section class="h-64 flex flex-col items-start gap-4"> | ||
<div class="h-20 flex flex-row justify-start gap-4"> | ||
|
||
<div class="flex flex-col gap-1"> | ||
<label>Nombre del audio</label> | ||
<input type="text" name="name" class="w-80 h-10 rounded-md bg-[#333] border-2 border-[#c5c5c5] text-white p-2 outline-none" placeholder="Nombre" /> | ||
</div> | ||
<div class="flex flex-col gap-1"> | ||
<label >Participantes</label> | ||
<input type="text" name="featurings" class="w-80 h-10 rounded-md bg-[#333] border-2 border-[#c5c5c5] text-white p-2 outline-none" placeholder="Usuario" /> | ||
</div> | ||
<div class="flex flex-row gap-2 items-center mt-4 "> | ||
<label>Privado</label> | ||
<input type="checkbox" name="private" /> | ||
</div> | ||
|
||
</div> | ||
<div class="w-full h-full"> | ||
<TagsTabs subject="audio"/> | ||
</div> | ||
</section> | ||
</div> | ||
<div class="w-full flex flex-col gap-2"> | ||
<input type="file" id="file" name="audio"/> | ||
<audio id="audio" controls class="w-full"></audio> | ||
</div> | ||
<input type="submit" class=" bg-bluePB px-4 py-1 rounded-sm" value="Subir"/> | ||
</form> | ||
</div> | ||
|
||
<script is:inline> | ||
function previewImage(event) { | ||
var reader = new FileReader(); | ||
reader.onload = function(){ | ||
var output = document.getElementById('preview'); | ||
output.style.display = 'block'; | ||
output.src = reader.result; | ||
}; | ||
reader.readAsDataURL(event.target.files[0]); | ||
} | ||
function uploadAudio(event){ | ||
event.preventDefault(); | ||
|
||
} | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
Oops, something went wrong.