Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,7 @@ workflows:
filters:
branches:
only:
- free
- thrive-authors-update
# This is stage env for production QA releases
- "build-prod-staging":
context : org-global
Expand Down
17 changes: 13 additions & 4 deletions src/shared/components/Contentful/TracksFilter/TracksFilter.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,16 @@ export class TracksFilterInner extends Component {
const { authorList } = this.state;
this.setState({
authorList: _.concat(authorList, _.map(
_.sortBy(results.items, i => i.fields.name.toLowerCase()),
item => ({ label: item.fields.name, selected: false }),
_.sortBy(
results.items,
i => (i.fields.tcHandle
? i.fields.tcHandle.toLowerCase() : i.fields.name.toLowerCase()),
),
item => ({
label: item.fields.tcHandle
? item.fields.tcHandle : item.fields.name,
selected: false,
}),
)),
});
}
Expand Down Expand Up @@ -149,6 +157,7 @@ export class TracksFilterInner extends Component {
{mediaMatches => (
<Dropdown
label="Authors"
placeholder="Type author name or handle"
options={updatedAuthorList}
size="xs"
onChange={(authors) => {
Expand Down Expand Up @@ -231,8 +240,8 @@ export class TracksFilterInner extends Component {
TracksFilterInner.defaultProps = {
onClose: () => {},
onApply: () => {},
selectedAuthor: DEF_SELECTED_AUTHOR,
authorList: [{ label: DEF_SELECTED_AUTHOR, selected: true }],
selectedAuthor: '',
authorList: [{ label: DEF_SELECTED_AUTHOR, selected: false }],
startDate: moment('2001-01-02'),
endDate: moment(),
tags: [],
Expand Down