diff --git a/package.json b/package.json index 3d0c55c0e..c1ad070fa 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "homepage": "http://evgeny-nadymov.github.io/telegram-react", "name": "telegram_react", - "version": "0.0.470", + "version": "0.0.471", "private": true, "dependencies": { "@material-ui/core": "^3.9.2", diff --git a/src/Components/ColumnMiddle/InputBoxControl.js b/src/Components/ColumnMiddle/InputBoxControl.js index 71c5470b1..25bffedce 100644 --- a/src/Components/ColumnMiddle/InputBoxControl.js +++ b/src/Components/ColumnMiddle/InputBoxControl.js @@ -627,16 +627,14 @@ class InputBoxControl extends Component {
- {content} -
+ onInput={this.handleInput} + />
p { margin: 0 0 12px; } article pre { - font-family: Menlo; - margin: 14px 0; - padding: 7px 12px; - background: #f5f8fc; - font-size: 16px; + margin: 12px 0; + padding: 6px 12px; white-space: pre-wrap; word-wrap: break-word; } diff --git a/src/Components/Message/Message.css b/src/Components/Message/Message.css index f1c988816..11932b0e4 100644 --- a/src/Components/Message/Message.css +++ b/src/Components/Message/Message.css @@ -29,20 +29,19 @@ code { } pre { + font-size: 90%; + font-family: Menlo, Monaco, Consolas, 'Courier New', monospace; + + margin-top: 6px; margin-bottom: 0; - overflow: auto; - padding: 3px; - border: 1px solid #eee; - max-height: none; - font-size: inherit; + padding: 6px 12px; + border-style: solid; + border-width: 1px; + border-radius: 4px; - display: block; - line-height: 1.42857143; - word-break: break-all; + white-space: pre-wrap; word-wrap: break-word; - color: #333; - background-color: #f5f5f5; - border-radius: 4px; + word-break: break-word; } pre code { diff --git a/src/TelegramApp.js b/src/TelegramApp.js index f98d00050..87e34cde2 100644 --- a/src/TelegramApp.js +++ b/src/TelegramApp.js @@ -39,6 +39,15 @@ const styles = theme => ({ }, code: { color: theme.palette.primary.dark + }, + pre: { + borderColor: theme.palette.divider, + color: theme.palette.primary.dark, + // background: theme.palette.primary.main + '11' + '&::selection': { + color: theme.palette.text.primary, + backgroundColor: 'highlight' + } } } }); diff --git a/src/Utils/Message.js b/src/Utils/Message.js index 8b222de0d..ee4d5b7af 100644 --- a/src/Utils/Message.js +++ b/src/Utils/Message.js @@ -207,12 +207,7 @@ function getFormattedText(text) { } case 'textEntityTypePhoneNumber': { result.push( - + {entityText} );