Skip to content

Commit

Permalink
Add political orientation and year of establishment for each party
Browse files Browse the repository at this point in the history
  • Loading branch information
stesiam committed Jun 6, 2024
1 parent a9604fb commit c240318
Show file tree
Hide file tree
Showing 3 changed files with 109 additions and 9 deletions.
89 changes: 81 additions & 8 deletions app/app.R
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,17 @@ ui <- add_cookie_handlers(
)
)
),
tags$th(i18n$t("New Democracy")),
tags$th(i18n$t("New Democracy"),
tags$span(class = "party-orientation",
i18n$t("Center-right/Right")),
tags$div(class = "established",
tags$div(
icon("calendar-days")
),
tags$div(
tags$p("1974"))
)
),
tags$th(tags$input(id = "nd_pct", value =40.56, type="text", placeholder="Type here", class="input input-bordered input-primary w-full max-w-xs")),
tags$th(textOutput("nd_seats"))
),
Expand All @@ -81,7 +91,16 @@ ui <- add_cookie_handlers(
)
)
),
tags$th(i18n$t("SYRIZA")),
tags$th(i18n$t("SYRIZA"),
tags$span(class = "party-orientation",
i18n$t("Center-left/Left")),
tags$div(class = "established",
tags$div(
icon("calendar-days")
),
tags$div(
tags$p("2004"))
)),
tags$th(tags$input(id = "syriza_pct", value =17.83, type="text", placeholder="Type here", class="input input-bordered input-primary w-full max-w-xs")),
tags$th(textOutput("syriza_seats"))
),
Expand All @@ -93,7 +112,16 @@ ui <- add_cookie_handlers(
)
)
),
tags$th(i18n$t("PASOK")),
tags$th(i18n$t("PASOK"),
tags$span(class = "party-orientation",
i18n$t("Center-left")),
tags$div(class = "established",
tags$div(
icon("calendar-days")
),
tags$div(
tags$p("1974"))
)),
tags$th(tags$input(id = "pasok_pct", value =11.84, type="text", placeholder="Type here", class="input input-bordered input-primary w-full max-w-xs")),
tags$th(textOutput("pasok_seats"))
),
Expand All @@ -105,7 +133,16 @@ ui <- add_cookie_handlers(
)
)
),
tags$th(i18n$t("KKE")),
tags$th(i18n$t("KKE"),
tags$span(class = "party-orientation",
i18n$t("Far-left")),
tags$div(class = "established",
tags$div(
icon("calendar-days")
),
tags$div(
tags$p("1918"))
)),
tags$th(tags$input(id = "kke_pct", value =7.69, type="text", placeholder="Type here", class="input input-bordered input-primary w-full max-w-xs")),
tags$th(textOutput("kke_seats"))
),
Expand All @@ -117,7 +154,16 @@ ui <- add_cookie_handlers(
)
)
),
tags$th(i18n$t("Elliniki Lysi")),
tags$th(i18n$t("Elliniki Lysi"),
tags$span(class = "party-orientation",
i18n$t("Right/Far-right")),
tags$div(class = "established",
tags$div(
icon("calendar-days")
),
tags$div(
tags$p("2016"))
)),
tags$th(tags$input(id = "ellisi_pct", value =4.44, type="text", placeholder="Type here", class="input input-bordered input-primary w-full max-w-xs")),
tags$th(textOutput("ellisi_seats"))
),
Expand All @@ -129,7 +175,16 @@ ui <- add_cookie_handlers(
)
)
),
tags$th(i18n$t("Niki")),
tags$th(i18n$t("Niki"),
tags$span(class = "party-orientation",
i18n$t("Far-right")),
tags$div(class = "established",
tags$div(
icon("calendar-days")
),
tags$div(
tags$p("2019"))
)),
tags$th(tags$input(id = "niki_pct", value =3.7, type="text", placeholder="Type here", class="input input-bordered input-primary w-full max-w-xs")),
tags$th(textOutput("niki_seats"))
),
Expand All @@ -141,7 +196,16 @@ ui <- add_cookie_handlers(
)
)
),
tags$th(i18n$t("Plefsi")),
tags$th(i18n$t("Plefsi"),
tags$span(class = "party-orientation",
i18n$t("Catch-all")),
tags$div(class = "established",
tags$div(
icon("calendar-days")
),
tags$div(
tags$p("2016"))
)),
tags$th(tags$input(id = "plefsi_pct", value =3.17,type="text", placeholder="Type here", class="input input-bordered input-primary w-full max-w-xs")),
tags$th(textOutput("plefsi_seats"))
),
Expand All @@ -153,7 +217,16 @@ ui <- add_cookie_handlers(
)
)
),
tags$th(i18n$t("MeRA25")),
tags$th(i18n$t("MeRA25"),
tags$span(class = "party-orientation",
i18n$t("Left")),
tags$div(class = "established",
tags$div(
icon("calendar-days")
),
tags$div(
tags$p("2018"))
)),
tags$th(tags$input(id = "mera25_pct", value =2.5, type="text", placeholder="Type here", class="input input-bordered input-primary w-full max-w-xs")),
tags$th(textOutput("mera_seats"))
),
Expand Down
18 changes: 18 additions & 0 deletions app/www/styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -56,3 +56,21 @@ html{
display: none;
}
}

.party-orientation{
display: block;
font-family: EB Garamond;
font-weight: normal;
}

.established{
display: flex;
flex-direction: row;
gap: 0.5em;
font-size: 0.8em;
align-items: center;
}

.established p{
font
}
11 changes: 10 additions & 1 deletion app/www/translations/translation_el.csv
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,13 @@ en,el
"Bonus 40 Seats (2007-2009)", "Μπόνους 40 εδρών (2007, 09)"
"Bonus 50 Seats (2012-2019)", "Μπόνους 50 εδρών (2012-2019)"
"No Bonus (2023Α)", "Αναλογική κατανομή (2023Α)"
"Proportional Bonus (2023Β-", "Αναλογικό μπόνους (2023Β-)"
"Proportional Bonus (2023Β-", "Αναλογικό μπόνους (2023Β-)"
"Center-right/Right", "Κεντροδεξια/Δεξια"
"Center-left/Left", "Κεντροαριστερα/Αριστερα"
"Center-left", "Κεντροαριστερα"
"Left/Far-left", "Αριστερα"
"Right/Far-right", "Δεξια/Ακροδεξια"
"Far-right", "Ακροδεξια"
"Catch-all", "Πολυσυλλεκτικό"
"Far-left", "Ακροαριστερα"
"Left", "Αριστερα"

0 comments on commit c240318

Please sign in to comment.