diff --git a/Composer/packages/client/src/components/ErrorPopup/ErrorPopup.tsx b/Composer/packages/client/src/components/ErrorPopup/ErrorPopup.tsx index 5ad0500380..152b5f3878 100644 --- a/Composer/packages/client/src/components/ErrorPopup/ErrorPopup.tsx +++ b/Composer/packages/client/src/components/ErrorPopup/ErrorPopup.tsx @@ -18,9 +18,8 @@ type ErrorPopupProps = { onDismiss: () => void; }; -const formatErrorTitle = (error: StateError): string => { - const { summary } = error; - if (!summary) return ''; +const formatErrorTitle = (summary: string): string => { + if (!summary) return formatMessage('Error'); return summary.length > 20 ? summary.substring(0, 20) + '...' : summary; }; @@ -62,7 +61,7 @@ export const ErrorPopup = (props: ErrorPopupProps) => { } }, [props.error]); - const title = props.error ? formatErrorTitle(props.error) : ''; + const title = formatErrorTitle(props?.error?.summary); const detail = props.error ? formatErrorDetail(props.error) : ''; return ( diff --git a/Composer/packages/client/src/components/ErrorPopup/styles.js b/Composer/packages/client/src/components/ErrorPopup/styles.js index 0e5469357c..f6b83bbbcb 100644 --- a/Composer/packages/client/src/components/ErrorPopup/styles.js +++ b/Composer/packages/client/src/components/ErrorPopup/styles.js @@ -6,10 +6,11 @@ import { FontWeights, FontSizes } from 'office-ui-fabric-react/lib/Styling'; import { NeutralColors, SharedColors } from '@uifabric/fluent-theme'; export const consoleStyle = css` - background: ${NeutralColors.black}; - color: ${NeutralColors.white}; + background: ${NeutralColors.gray20}; padding: 15px; margin-bottom: 20px; + overflow-y: auto; + max-height: 434px; a { color: ${SharedColors.blueMagenta10};