@ -36,6 +36,12 @@ const handleSearchSubmit = () => {
router . push ( localePath ( '/products/search/' + searchKeyword . value ) ) ;
searchKeyword . value = '' ;
}
watch ( locale , ( nVal , oVal ) => {
if ( nVal !== oVal ) {
router . push ( localePath ( '/' ) ) ;
}
} )
< / script >
< template >
@ -44,9 +50,9 @@ const handleSearchSubmit = () => {
< div class = "container" >
< a class = "navbar-brand" href = "javascript:;" >
< div class = "logo" @click ="router.push(localeLocation('/'))" >
< img :src ="logoImg" alt = "prodio" >
<!-- < img :src ="logoImg" alt = "prodio" > -- >
WEISEN
< / div >
< p > since 2002 < / p >
< / a >
< button ref = "navbarToggler" class = "navbar-toggler" type = "button" data -bs -toggle = " collapse "
data - bs - target = "#navbarText" aria - controls = "navbarText" aria - expanded = "false" aria - label = "Toggle navigation" >
@ -55,13 +61,7 @@ const handleSearchSubmit = () => {
< div class = "collapse navbar-collapse" id = "navbarText" >
< ul class = "navbar-nav ms-auto" >
< li class = "nav-item" >
< div class = "nav-link" > { { $t ( 'aboutus' ) } } < / div >
< ul class = "dropdown-menu" >
< li > < a class = "dropdown-item" href = "javascript:;" @click ="goRoute(localeLocation('/about/company'))" > {{
$t ( 'About.company' ) } } < / a > < / li >
< li > < a class = "dropdown-item" href = "javascript:;" @click ="goRoute(localeLocation('/about/concept'))" > {{
$t ( 'About.concept' ) } } < / a > < / li >
< / ul >
< div class = "nav-link" @click ="goRoute(localeLocation('/about/company'))" > {{ $ t ( ' aboutus ' ) }} < / div >
< / li >
< li class = "nav-item" >
< div class = "nav-link" data -toggle = " dropdown " data -submenu > { { $t ( 'products' ) } } < / div >
@ -80,15 +80,7 @@ const handleSearchSubmit = () => {
< / div >
< / li >
< li class = "nav-item" >
< div class = "nav-link" > { { $t ( 'news' ) } } < / div >
< ul class = "dropdown-menu" >
< li > < a class = "dropdown-item" @click ="goRoute(localeLocation('/social/news'))" > {{ $ t ( ' Social.news ' )
} } < / a > < / li >
< li > < a class = "dropdown-item" @click ="goRoute(localeLocation('/social/activity'))" > {{
$t ( 'Social.activity' ) } } < / a > < / li >
< li > < a class = "dropdown-item" @click ="goRoute(localeLocation('/social/esg'))" > {{
$t ( 'Social.esg' ) } } < / a > < / li >
< / ul >
< div class = "nav-link" @click ="goRoute(localeLocation('/social/news'))" > {{ $ t ( ' news ' ) }} < / div >
< / li >
< li class = "nav-item" >
< div class = "nav-link" > { { $t ( 'contact' ) } } < / div >
@ -100,11 +92,11 @@ const handleSearchSubmit = () => {
< / ul >
< / li >
< / ul >
< div class = "landBtnGroup btn-group" >
<!-- < div class = "landBtnGroup btn-group" >
< NuxtLink class = "btn chBtn" : class = "{ active: locale === 'tw' }" :to ="switchLocalePath('tw')" > 繁 < / NuxtLink >
< NuxtLink class = "btn chBtn" : class = "{ active: locale === 'cn' }" :to ="switchLocalePath('cn')" > 简 < / NuxtLink >
< NuxtLink class = "btn chBtn" : class = "{ active: locale === 'en' }" :to ="switchLocalePath('en')" > EN < / NuxtLink >
< / div >
< / div > -- >
< form class = "searchBar" @submit ="handleSearchSubmit" >
< input class = "form-control form-control-sm bg-silver border-0" type = "search"
placeholder = "產品搜尋"
@ -125,8 +117,10 @@ const handleSearchSubmit = () => {
< div class = "row gx-lg-5 justify-content-between mb-5" >
< div class = "col-12 col-lg-auto" >
< a class = "logoGroup" href = "javascript:;" @click ="router.push(localeLocation('/'))" >
< div class = "logo" > < img :src ="logoImg" alt = "" > < / div >
< p > since 2002 < / p >
< div class = "logo" >
<!-- < img :src ="logoImg" alt = "" > -- >
WEISEN
< / div >
< / a >
<!-- < div class = "share_link" >
< a href = "#" > < div class = "item fb" > < i class = "fa-brands fa-facebook-f" > < / i > < / div > < / a >
@ -148,8 +142,7 @@ const handleSearchSubmit = () => {
< div class = "col-12 col-lg" >
< div class = "fTitle" > Company < / div >
< div class = "info_link" >
< a target = "_blank" : href = "'https://www.google.com.tw/maps/place/' + config[locale].address"
v - if = "config[locale].address" >
< a href = "javascript:void(0);" >
< i class = "fa-solid fa-map-location-dot" > < / i >
< div class = "text" > { { config [ locale ] . address } } < / div >
< / a >
@ -178,6 +171,6 @@ const handleSearchSubmit = () => {
< / div >
< / div >
< / div >
< div class = "copyright" > { { $t( 'copyright' ) } } < / div >
< div class = "copyright" > { { config[ locale ] . copyright } } < / div >
< / footer >
< / template >