diff --git a/FCLauncher/src/index.html b/FCLauncher/src/index.html index 58af275..4718290 100644 --- a/FCLauncher/src/index.html +++ b/FCLauncher/src/index.html @@ -8,11 +8,9 @@ - + + + @@ -27,7 +25,9 @@ - + + +

diff --git a/FCLauncher/src/main.js b/FCLauncher/src/main.js index c5d1047..8aaa995 100644 --- a/FCLauncher/src/main.js +++ b/FCLauncher/src/main.js @@ -10,17 +10,13 @@ async function greet() { } window.addEventListener("DOMContentLoaded", () => { - greetInputEl = document.querySelector("#greet-input"); - greetMsgEl = document.querySelector("#greet-msg"); - document.querySelector("#greet-form").addEventListener("submit", (e) => { - e.preventDefault(); - greet(); - }); + + document.getElementById("idsButton").addEventListener("click", viewIds); + console.log("testing"); }); function packSelect() { document.getElementById("myDropdown").classList.toggle("show"); - } function load() { @@ -38,16 +34,23 @@ window.onload = async function() { } function addModpacks(modpacks) { + var dropdown = document.getElementById("Modpacks"); modpacks.sort(); modpacks.reverse(); for (let i = 0; i < modpacks.length; i++){ var opt = document.createElement("option"); - opt.text = modpacks[i]; - opt.value = 'somethings value'; + opt.text = modpacks[i].name; + opt.value = modpacks[i].id; dropdown.options.add(opt); } } +function viewIds() { + var packId = document.getElementById("Modpacks"); + var selectedId = packId.value; + document.getElementById("showTheId").textContent = selectedId; + console.log(selectedId); +} //window.onclick = function(event) { diff --git a/FCLauncher/src/styles.css b/FCLauncher/src/styles.css index 0362200..18ebadf 100644 --- a/FCLauncher/src/styles.css +++ b/FCLauncher/src/styles.css @@ -68,10 +68,14 @@ button { font-size: 1em; font-weight: 500; font-family: inherit; - color: #0f0f0f; + color: #4df3ff; background-color: #ffffff; transition: border-color 0.25s; box-shadow: 0 2px 2px rgba(0, 0, 0, 0.2); + width: 300px; + display: flex; + justify-content: center; + align-self: center; } button { @@ -141,7 +145,7 @@ button { z-index: 1; } -.dropdown-content a { +#text { color: black; padding: 12px 16px; text-decoration: none;