diff --git a/questions.html b/questions.html index a714ad9..6b159a7 100644 --- a/questions.html +++ b/questions.html @@ -19,7 +19,16 @@

Our Little Interview

-

The Who Questions

+ + +

The Who Questions

Welcome to the server! It seems like you're interested in becoming an official member, so before we accept you @@ -50,7 +59,7 @@ -

What Questions

+

The What Questions

Every server has rules, although our rules are a bit more straight forward than usual. This section tests your knowledge @@ -64,7 +73,7 @@

  • Consider this a basic filter
  • -

    Why Questions

    +

    The Why Questions

    Our server runs on a case by case basis, so naturally, instead of testing you on the rules of the land, it'd be @@ -93,6 +102,22 @@ developer or post to #feedback on Discord.

    +

    The How Questions

    +

    + Congratulations! By filling out this form, you have been given + a few basic permissions. Feel free to roam around spawn, view + our dynamic map, join our discord channel, and discover our + custom coded Civilization View. +
    + We'll let you know when the moderators have finished reviewing + your application. Till then, have fun! +

    +

    Your application is awaiting approval

    + + placeholder + placeholder + placeholder + placeholder diff --git a/resources/questions/images/64pxWhiteBox.png b/resources/questions/images/64pxWhiteBox.png new file mode 100644 index 0000000..afe3fde Binary files /dev/null and b/resources/questions/images/64pxWhiteBox.png differ diff --git a/resources/questions/scenarios.js b/resources/questions/scenarios.js index b0480ce..bf0db46 100644 --- a/resources/questions/scenarios.js +++ b/resources/questions/scenarios.js @@ -3,9 +3,17 @@ window.onload = function(){ makeScenario = function(scenario){ //output element, that other elements are attached to - let $outputElement = $("
  • ") - $outputElement.attr("id", "scenarios-"+scenario.name); - + let $trueOutputElement = $("
  • ") + $trueOutputElement.attr("id", "scenarios-"+scenario.name); + let $outputElement = $("
    ") + //Determines whether this is a jQuery Accordion + const isAccordion = true; + if(isAccordion){ + $controlElement = $(""); + $controlElement.addClass("accordion-control"); + $controlElement.append(scenario.name); + $trueOutputElement.append($controlElement); + } //Mature Content rating if(scenario.adult == true){ $adultText = $("

    (question for those over the age of 18... or those mature enough)

    "); @@ -69,12 +77,24 @@ window.onload = function(){ $outputElement.append($("

    ")); $outputElement.append($submitElement); - return $outputElement; + $trueOutputElement.append($outputElement); + return $trueOutputElement; } $.getJSON("./resources/questions/scenarios.json", "", function(data){ + $accordionElement = $("#scenarios"); + $accordionElement.addClass("accordion") for(const scenario of data.scenarios){ - $("#scenarios").append(makeScenario(scenario)); + $accordionElement.append(makeScenario(scenario)) } + + $(".accordion").on('click', '.accordion-control', function(e){ + e.preventDefault; + $(this) + .next('.accordion-panel') + .not(':animated') + .slideToggle(); + }); }); + } diff --git a/resources/questions/style.css b/resources/questions/style.css index 6cb8c28..2fc2b49 100644 --- a/resources/questions/style.css +++ b/resources/questions/style.css @@ -5,7 +5,13 @@ li, li p{ .aside{ color: rgb(250, 250, 250); } + + #scenarios li p.adult{ font-family: monospace ; color: rgb(240, 0, 100); } + +.accordion-panel { + display:none; +}