Skip to content
This repository has been archived by the owner on May 19, 2020. It is now read-only.

Commit

Permalink
refactor(toolbarTip): refactor code - I258
Browse files Browse the repository at this point in the history
Signed-off-by: Shrey Sachdeva <[email protected]>
  • Loading branch information
sachdeva-shrey authored and jolanglinais committed Mar 6, 2020
1 parent cb39d1f commit d7a4055
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions src/FormattingToolbar/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -675,7 +675,7 @@ export default class FormatToolbar extends React.Component {
undoIcon.width(),
undoIcon.padding(),
undoIcon.vBox(),
'Undo (' + tips.MOD + '+Z)',
`Undo (${tips.MOD}+Z)`,
'toolbar-2x2'
)
}
Expand All @@ -687,7 +687,7 @@ export default class FormatToolbar extends React.Component {
redoIcon.width(),
redoIcon.padding(),
redoIcon.vBox(),
'Redo (' + tips.MOD + '+Y)',
`Redo (${tips.MOD}+Y)`,
'toolbar-2x3'
)
}
Expand Down
6 changes: 3 additions & 3 deletions src/FormattingToolbar/toolbarTooltip.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@ export const capitalizeWord = word => capitalizeFirst(word) + sliceWord(word);

export const identifyBlock = (block) => {
const typeBeginning = firstTwoLetters(block);
if(typeBeginning === 'bl') return 'Quote (' + MOD + '+Q)';
if(typeBeginning === 'ul') return 'Bulleted List (' + MOD + '+Shift+8)';
if(typeBeginning === 'ol') return 'Numbered List (' + MOD + '+Shift+7)';
if(typeBeginning === 'bl') return `Quote (${MOD}+Q)`;
if(typeBeginning === 'ul') return `Bulleted List (${MOD}+Shift+8)`;
if(typeBeginning === 'ol') return `Numbered List (${MOD}+Shift+7)`;
return null;
};
2 changes: 1 addition & 1 deletion src/icons/bold.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import React from 'react';

import * as tips from '../FormattingToolbar/toolbarTooltip';

export const type = () => 'Bold (' + tips.MOD + '+B)';
export const type = () => `Bold (${tips.MOD}+B)`;

export const height = () => '25px';

Expand Down
2 changes: 1 addition & 1 deletion src/icons/code.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import React from 'react';

import * as tips from '../FormattingToolbar/toolbarTooltip';

export const type = () => 'Code (' + tips.MOD + "+Alt+C)";
export const type = () => `Code (${tips.MOD}+Alt+C)`;

export const height = () => '25px';

Expand Down
2 changes: 1 addition & 1 deletion src/icons/italic.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import React from 'react';

import * as tips from '../FormattingToolbar/toolbarTooltip';

export const type = () => 'Italic (' + tips.MOD + '+I)';
export const type = () => `Italic (${tips.MOD}+I)`;

export const height = () => '25px';

Expand Down

0 comments on commit d7a4055

Please sign in to comment.