-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
* Fixes #14201 by catching and displaying render errors * fix lint issues
- Loading branch information
1 parent
bb3c9f3
commit 895343d
Showing
3 changed files
with
75 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
src/core_plugins/kibana/public/dashboard/panel/panel_error.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import React from 'react'; | ||
import PropTypes from 'prop-types'; | ||
|
||
export function PanelError({ error }) { | ||
return ( | ||
<div className="load-error"> | ||
<span aria-hidden="true" className="kuiIcon fa-exclamation-triangle"/> | ||
<span>{error}</span> | ||
</div> | ||
); | ||
} | ||
|
||
PanelError.PropTypes = { | ||
error: PropTypes.oneOfType([ | ||
PropTypes.string, | ||
PropTypes.node | ||
]), | ||
}; | ||
|