From 89ef96fe27629af73314bb3b79f0f28b97b332d4 Mon Sep 17 00:00:00 2001 From: Shiny Date: Sat, 24 Mar 2018 18:18:38 +0800 Subject: [PATCH] Bump to 0.13.1 --- README.md | 1 + lib/index.js | 3 ++- package.json | 2 +- src/TextTruncate.js | 1 + 4 files changed, 5 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index d1f876e..47521ce 100644 --- a/README.md +++ b/README.md @@ -42,6 +42,7 @@ var TextTruncate = require('react-text-truncate'); // CommonJS or UMD ## Changelog +* 0.13.1 Fix react warning of `maxCalculateTimes` * 0.13.0 Shows all of the text when `line` is falsely, add `maxCalculateTimes` to prevent infinite loop * 0.12.1 Update peerDependencies to support React 16 * 0.12.0 Added new prop: `textElement` for customize text render diff --git a/lib/index.js b/lib/index.js index 02c4a60..93b1d63 100644 --- a/lib/index.js +++ b/lib/index.js @@ -289,7 +289,8 @@ textElement = _props2.textElement, textTruncateChild = _props2.textTruncateChild, truncateText = _props2.truncateText, - props = _objectWithoutProperties(_props2, ['element', 'text', 'style', 'containerClassName', 'line', 'onCalculated', 'onTruncated', 'textElement', 'textTruncateChild', 'truncateText']); + maxCalculateTimes = _props2.maxCalculateTimes, + props = _objectWithoutProperties(_props2, ['element', 'text', 'style', 'containerClassName', 'line', 'onCalculated', 'onTruncated', 'textElement', 'textTruncateChild', 'truncateText', 'maxCalculateTimes']); var fontWeight = style.fontWeight, fontStyle = style.fontStyle, diff --git a/package.json b/package.json index 5047abf..e07effc 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "react-text-truncate", - "version": "0.13.0", + "version": "0.13.1", "description": "Truncate text for React.js", "main": "lib/index.js", "scripts": { diff --git a/src/TextTruncate.js b/src/TextTruncate.js index 0d62d20..546dae2 100644 --- a/src/TextTruncate.js +++ b/src/TextTruncate.js @@ -216,6 +216,7 @@ export default class TextTruncate extends Component { textElement, textTruncateChild, truncateText, + maxCalculateTimes, ...props } = this.props;