Skip to content

Commit

Permalink
Fix package lock and typos after #7890 (#10304)
Browse files Browse the repository at this point in the history
  • Loading branch information
ellatrix authored Oct 3, 2018
1 parent 9a442fb commit 4691baf
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
1 change: 1 addition & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions packages/rich-text/src/apply-format.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,12 @@ import { normaliseFormats } from './normalise-formats';
* given `endIndex`. Indices are retrieved from the selection if none are
* provided.
*
* @param {Object} record Record to modify.
* @param {Object} value Value to modify.
* @param {Object} format Format to apply.
* @param {number} startIndex Start index.
* @param {number} endIndex End index.
*
* @return {Object} A new record with the format applied.
* @return {Object} A new value with the format applied.
*/
export function applyFormat(
{ formats, text, start, end },
Expand Down
10 changes: 5 additions & 5 deletions test/e2e/test-plugins/deprecated-node-matcher/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,13 @@
},
} );

function torichText( value ) {
function toRichTextValue( value ) {
return _.map( value, function( subValue ) {
return subValue.children;
} );
}

function fromrichText( value ) {
function fromRichTextValue( value ) {
return _.map( value, function( subValue ) {
return {
children: subValue,
Expand All @@ -65,10 +65,10 @@
return el( 'blockquote', {},
el( RichText, {
multiline: 'p',
value: torichText( attributes.value ),
value: toRichTextValue( attributes.value ),
onChange: function( nextValue ) {
setAttributes( {
value: fromrichText( nextValue ),
value: fromRichTextValue( nextValue ),
} );
},
} )
Expand All @@ -77,7 +77,7 @@
save: function( { attributes } ) {
return el( 'blockquote', {},
el( RichText.Content, {
value: torichText( attributes.value ),
value: toRichTextValue( attributes.value ),
} )
);
},
Expand Down

0 comments on commit 4691baf

Please sign in to comment.