Skip to content

Commit

Permalink
fix(site): navigate to correct site for current language when searchi…
Browse files Browse the repository at this point in the history
…ng components (#1622)
  • Loading branch information
marswong authored and paranoidjk committed Jul 29, 2017
1 parent 31b565c commit 78e4f8b
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion site/desktop/src/template/Layout/Header.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,11 @@ export default class Header extends React.Component {
});
}

handleSearch = value => this.context.router.push({ pathname: value });
handleSearch = (value) => {
this.context.router.push({
pathname: this.context.intl.locale === 'zh-CN' ? `${value}-cn` : value,
});
}

handleSelectFilter = (value, option) => (
option.props['data-label'].indexOf(value.toLowerCase()) > -1
Expand Down

0 comments on commit 78e4f8b

Please sign in to comment.