-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add LocaleSwitcher #89
Changes from all commits
116f6c2
63db349
8738d2f
1acad0b
c52b76a
585ebef
cff968b
35ebf6f
6c99e58
c80ea33
5601be7
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,3 @@ | ||
.headerRow {} | ||
.headerRow {} | ||
.headerRowBackground {} | ||
.headerRowContainer {} |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,7 +4,7 @@ import PropTypes from 'prop-types' | |
import { ExtensionPoint, useRuntime } from 'vtex.render-runtime' | ||
import TopMenu from './components/TopMenu' | ||
import Spacer from './components/Helpers/Spacer' | ||
import { logo, collapsible, icons, searchBar, login } from './defaults' | ||
import { logo, collapsible, icons, searchBar, login, localeSwitcher } from './defaults' | ||
|
||
import styles from './store-header.css' | ||
import useDevice from './hooks/useDevice' | ||
|
@@ -20,6 +20,7 @@ const Header = ({ | |
logoSize, | ||
showSearchBar, | ||
showLogin, | ||
showLocaleSwitcher, | ||
iconClasses, | ||
labelClasses, | ||
collapsibleAnimation, | ||
|
@@ -46,6 +47,7 @@ const Header = ({ | |
logoSize, | ||
showSearchBar, | ||
showLogin, | ||
showLocaleSwitcher, | ||
iconClasses, | ||
labelClasses, | ||
collapsibleAnimation, | ||
|
@@ -95,6 +97,7 @@ Header.propTypes = { | |
...icons.propTypes, | ||
...logo.propTypes, | ||
...collapsible.propTypes, | ||
...localeSwitcher.propTypes, | ||
} | ||
|
||
Header.defaultProps = { | ||
|
@@ -104,6 +107,7 @@ Header.defaultProps = { | |
...icons.defaultProps, | ||
...logo.defaultProps, | ||
...collapsible.defaultProps, | ||
...localeSwitcher.defaultProps, | ||
} | ||
|
||
Header.schema = { | ||
|
@@ -134,6 +138,12 @@ Header.schema = { | |
default: true, | ||
isLayout: true, | ||
}, | ||
showLocaleSwitcher: { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I wasn't able to see this configuration in the storefront, can you take a look into that? |
||
title: 'admin/editor.header.show.localeswitcher.title', | ||
type: 'boolean', | ||
default: true, | ||
isLayout: true, | ||
}, | ||
}, | ||
} | ||
|
||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,6 +5,7 @@ | |
"login", | ||
"category-menu", | ||
"search-bar", | ||
"locale-switcher", | ||
"theme", | ||
"user-address", | ||
"menu", | ||
|
@@ -47,6 +48,7 @@ | |
"minicart", | ||
"login", | ||
"search-bar", | ||
"locale-switcher", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You should create an independent block for So it will work with the |
||
"menu-link", | ||
"category-menu", | ||
"menu", | ||
|
@@ -87,6 +89,7 @@ | |
"minicart", | ||
"login", | ||
"search-bar", | ||
"locale-switcher", | ||
"menu-link", | ||
"category-menu", | ||
"menu", | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this appear on
/admin
? It's not working for me