Skip to content
This repository was archived by the owner on Mar 4, 2020. It is now read-only.

feat(Dropdown): add loading prop #729

Merged
merged 25 commits into from
Jan 24, 2019
Merged

feat(Dropdown): add loading prop #729

merged 25 commits into from
Jan 24, 2019

Conversation

layershifter
Copy link
Member

@layershifter layershifter commented Jan 15, 2019

BREAKING CHANGES

1. Rename toggleButton to toggleIndicator

Reason: this slot is not a button, it cannot be focused or be selected in native select, too.

Before

<Dropdown toggleButton />

After

<Dropdown toggleIndicator />

2. toggleIndicator is visible by default

Reason: it's a common UI behavior to show toggles by default.

Before

<Dropdown />
<Dropdown toggleButton />

After

<Dropdown />
<Dropdown toggleIndicator={false} />

Customizing loadingMessage

image

<Dropdown loadingMessage={{ content: <Loader size="large" /> }} />

image

<Dropdown />

@layershifter layershifter force-pushed the feat/dropdown-loading branch from e00bad1 to 6d08667 Compare January 17, 2019 09:59

fontWeight: 'bold',
}),
}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We have a task for cleaning up styles in Dropdown, we should separate variables between components and them meaningful.

@layershifter layershifter changed the title [WIP] feat(Dropdown): add loading prop feat(Dropdown): add loading prop Jan 17, 2019
Copy link
Contributor

@kuzhelov kuzhelov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

overall I support the vector of changes, but would like to discuss couple of moments (where had left comments) before merge

….com/stardust-ui/react into feat/dropdown-loading

# Conflicts:
#	CHANGELOG.md
#	docs/src/examples/components/Dropdown/index.tsx
#	src/components/Dropdown/Dropdown.tsx
…at/dropdown-loading

# Conflicts:
#	CHANGELOG.md
#	docs/src/components/CodeSnippet.tsx
}),
!loading &&
items.length === 0 &&
ListItem.create(noResultsMessage, {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

….com/stardust-ui/react into feat/dropdown-loading

# Conflicts:
#	CHANGELOG.md
#	src/components/Dropdown/Dropdown.tsx
@layershifter layershifter merged commit aca94f8 into master Jan 24, 2019
@layershifter layershifter deleted the feat/dropdown-loading branch January 24, 2019 11:34
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants