Update: I cleaned the code as much as possible. There is still something wrong in calculation when choosing certain products but this is more about calculation than about code I guess.
Because of the code-cleaning, I decided to take the button out for now and will probably reinstall it in a future US.
As a user
I want to see the questions for 'financial issues' as well as answer possibilities
So that I know how much my menstruation costs me
INPUT
The page shows a form with 6 questions
The form shows question for 1. which menstruation products are mostly used
The form accepts choices for: tampons, pad, cup, disc, none
The form shows question for 2. how many products are in one package (only for tampon and pad)
The form accepts answer for 1 to 50
The form shows question for 3. costs of one package
The form accepts all amounts
The form shows question for 4. how much taxes are included in one package
The form accepts amounts from 0 to 30
The form shows question for 5. possible tax reduction?
The form accepts "keine Steuer, Teilsteuer, volle Steuer"
The form shows questions for 6. how often the product is changed per day (only when tampon or pad is selected)-
The form accepts amounts from 1 to 12
OUTPUT
The input values are used to calculate the output
The first output shows 1. the mainly used menstruation product and the amount of money you pay 2. per period, 3. per period-year, 4. in a menstruation-life, 5. until today (2.-5. with the according amount of taxes).
The page shows an infobox with the content "In Periotopia wären Menstruationsprodukte frei zugänglich. Schottland ist das bisher einzige Land weltweit, in dem Menstruationsartikel in öffentlichen Gebäuden per Gesetz kostenlos bereitgestellt werden müssen. In Deutschland sind es vor allem manche Universitäten, die kostenlose Produkte zur Verfügung stellen. Nur in wenigen Ländern sind Menstruationsprodukte von der Steuer befreit. In Deutschland ist sie seit 2020 zumindest reduziert"
The page shows a "Periotopia-Index"
The index is beeing calculated: free = 100%, no tax = 75%, reduced tax = 25%, full tax = 0%
To get a calculated answer, all questions must be answered
When a question is not answered an alert appears with the hint, that all fields must be filled out
Update: I cleaned the code as much as possible. There is still something wrong in calculation when choosing certain products but this is more about calculation than about code I guess.
Because of the code-cleaning, I decided to take the button out for now and will probably reinstall it in a future US.
As a user I want to see the questions for 'financial issues' as well as answer possibilities So that I know how much my menstruation costs me
INPUT
OUTPUT