From 6c71a668f25cf728697d5574e7602e739482d04b Mon Sep 17 00:00:00 2001 From: Roman Hotsiy Date: Wed, 24 Jan 2018 11:53:21 +0200 Subject: [PATCH] fix: wrap text in code samples --- src/components/SourceCode/SourceCode.tsx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/components/SourceCode/SourceCode.tsx b/src/components/SourceCode/SourceCode.tsx index 8773c90314..8f40d4565f 100644 --- a/src/components/SourceCode/SourceCode.tsx +++ b/src/components/SourceCode/SourceCode.tsx @@ -9,8 +9,11 @@ const StyledPre = styled.pre` font-family: ${props => props.theme.code.fontFamily}; font-size: ${props => props.theme.code.fontSize}; overflow-x: auto; - font-size: 0.9em; margin: 0; + + word-break: break-all; + word-wrap: break-word; + white-space: pre-wrap; `; export interface SourceCodeProps {