Fixed multi component i18n strings and added serverside impressum
Signed-off-by: Tuan-Dat Tran <tuan-dat.tran@tudattr.dev>
This commit is contained in:
@@ -9,13 +9,10 @@ pub fn Header() -> Element {
|
||||
rsx! {
|
||||
nav {
|
||||
div {
|
||||
// class: "justify-between p-4 space-x-8",
|
||||
class: "container mx-auto p-4",
|
||||
class: "container mx-auto py-4",
|
||||
|
||||
ul {
|
||||
class:"flex flex-col justify-between items-center sm:flex-row justify-center space-y-2 sm:space-y-0 sm:space-s-4",
|
||||
|
||||
// class:"flex flex-col sm:flex-row justify-center items-center sm:space-x-8 space-y-8 sm:space-y-0",
|
||||
class:"flex flex-col justify-between items-center justify-center space-y-2 sm:flex-row sm:space-y-0 sm:space-s-4",
|
||||
li {
|
||||
Link {
|
||||
to: Route::Home {},
|
||||
@@ -26,7 +23,6 @@ pub fn Header() -> Element {
|
||||
li { HeaderLink { url: Route::Home {}, text: translate!(i18, "headers.home")} },
|
||||
li { HeaderLink { url: Route::CV {}, text: translate!(i18, "headers.cv") } },
|
||||
li { HeaderLink { url: Route::PublicationsProjects {}, text: translate!(i18, "headers.publications_projects") } },
|
||||
li { HeaderLink { url: Route::Consulting {}, text: translate!(i18, "headers.consulting") } },
|
||||
li { HeaderLink { url: Route::Impressum {}, text: translate!(i18, "headers.about") } },
|
||||
li { LanguageButtonGroup {} },
|
||||
},
|
||||
@@ -44,9 +40,15 @@ fn LanguageButtonGroup() -> Element {
|
||||
|
||||
rsx! {
|
||||
div {
|
||||
class: "rounded-md shadow-sm justify-end",
|
||||
button { class: "px-4 py-2 text-sm font-medium text-gray-900 bg-white border border-gray-200 rounded-s-lg hover:bg-gray-100 hover:text-blue-700 focus:z-10 focus:ring-2 focus:ring-blue-700 focus:text-blue-700 dark:bg-gray-800 dark:border-gray-700 dark:text-white dark:hover:text-white dark:hover:bg-gray-700 dark:focus:ring-blue-500 dark:focus:text-white", onclick: change_to_english, label { { translate!(i18, "headers.language_buttons.english") } } },
|
||||
button { class: "px-4 py-2 text-sm font-medium text-gray-900 bg-white border border-gray-200 rounded-e-lg hover:bg-gray-100 hover:text-blue-700 focus:z-10 focus:ring-2 focus:ring-blue-700 focus:text-blue-700 dark:bg-gray-800 dark:border-gray-700 dark:text-white dark:hover:text-white dark:hover:bg-gray-700 dark:focus:ring-blue-500 dark:focus:text-white", onclick: change_to_german, label { { translate!(i18, "headers.language_buttons.german") } } }
|
||||
class: "rounded-md shadow-sm justify-end",
|
||||
button {
|
||||
class: "px-4 py-2 text-sm font-medium text-gray-900 bg-white border border-gray-200 rounded-s-lg hover:bg-gray-100 hover:text-blue-700 focus:z-10 focus:ring-2 focus:ring-blue-700 focus:text-blue-700 dark:bg-gray-800 dark:border-gray-700 dark:text-white dark:hover:text-white dark:hover:bg-gray-700 dark:focus:ring-blue-500 dark:focus:text-white",
|
||||
onclick: change_to_english,
|
||||
label { { translate!(i18, "headers.language_buttons.english") } } },
|
||||
button {
|
||||
class: "px-4 py-2 text-sm font-medium text-gray-900 bg-white border border-gray-200 rounded-e-lg hover:bg-gray-100 hover:text-blue-700 focus:z-10 focus:ring-2 focus:ring-blue-700 focus:text-blue-700 dark:bg-gray-800 dark:border-gray-700 dark:text-white dark:hover:text-white dark:hover:bg-gray-700 dark:focus:ring-blue-500 dark:focus:text-white",
|
||||
onclick: change_to_german,
|
||||
label { { translate!(i18, "headers.language_buttons.german") } } }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user