Skip to content

Commit

Permalink
Fix issues with the snacker (#1440)
Browse files Browse the repository at this point in the history
* [components] fix unused snackbar kind

* [components] fix snackbar item icon prop type

* [components] fix scrollbar appearance
  • Loading branch information
vicmeow authored Aug 13, 2019
1 parent baef47c commit f285758
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion packages/@sanity/components/src/snackbar/SnackbarItem.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export default class SnackbarItem extends React.Component {
static propTypes = {
action: PropTypes.shape({
title: PropTypes.string,
icon: PropTypes.func,
icon: PropTypes.node,
callback: PropTypes.func
}),
autoDismissTimeout: PropTypes.number,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
@import "part:@sanity/base/theme/variables-style";

.root {
position: absolute;
position: fixed;
z-index: var(--zindex-modal);
bottom: 0;
right: 0;
Expand Down
2 changes: 1 addition & 1 deletion packages/@sanity/desk-tool/src/pane/DocumentsListPane.js
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ export default withRouterHOC(
if (error) {
return (
<Snackbar
kind="danger"
kind="error"
isPersisted
actionTitle="Retry"
onAction={onRetry}
Expand Down
2 changes: 1 addition & 1 deletion packages/@sanity/desk-tool/src/pane/Editor/Editor.js
Original file line number Diff line number Diff line change
Expand Up @@ -858,7 +858,7 @@ export default withRouterHOC(
)}
{transactionResult && transactionResult.type === 'error' && (
<Snackbar
kind="danger"
kind="error"
actionTitle="OK"
onAction={onClearTransactionResult}
title={transactionResult.message}
Expand Down
2 changes: 1 addition & 1 deletion packages/@sanity/desk-tool/src/pane/History.js
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ export default class History extends React.PureComponent {
/>
))}
</div>
{error && <Snackbar kind="danger" isPersisted title={error} />}
{error && <Snackbar kind="error" isPersisted title={error} />}
</div>
)
}
Expand Down

0 comments on commit f285758

Please sign in to comment.