🚧 working on submit

Co-authored-by: Sindre Kjelsrud <kjelsrudsindre@gmail.com>
This commit is contained in:
haraldnilsen 2024-01-07 17:03:04 +01:00
parent b732a46ca1
commit 7ffea02700
4 changed files with 23 additions and 4 deletions

View file

@ -15,7 +15,7 @@
let helpfulness:string
const handleFormUpdate = () => {
if (knowledge != "" && empathy != "" && helpfulness != "") {
if (knowledge && empathy && helpfulness) {
dispatch("update", true)
}

View file

@ -24,7 +24,7 @@
class={`${questionNum == 0 || questionNum % 4 != 0 ? "hidden" : "bg-primary text-bg hover:bg-bg hover:text-primary"} font-bold uppercase border-primary border-2 rounded-full px-8 py-3`}>
Send inn svar
</button>
<button disabled={(questionNum != 0 && questionNum % 4 == 0) || !answeredAll} class={`flex items-center gap-2 text-primary font-semibold ${questionNum != 0 && questionNum % 4 == 0 && "opacity-50"}`} on:click={() => gotoNextPage(questionNum)}>
<button disabled={(questionNum != 0 && questionNum % 4 == 0) || !answeredAll} class={`flex items-center gap-2 text-primary font-semibold ${(questionNum != 0 && questionNum % 4 == 0) || !answeredAll && "opacity-50"}`} on:click={() => gotoNextPage(questionNum)}>
Neste spørsmål
<ArrowChevron width=16 direction="right"/>
</button>