Skip to content

Commit

Permalink
feat: add description - how to delete info (#292)
Browse files Browse the repository at this point in the history
* feat: add description - how to delete info

* style: new line

* style: removes extra line

* fix: correction of text
  • Loading branch information
alex-krasn authored Jun 5, 2020
1 parent 3b29a35 commit 1c39800
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 3 deletions.
4 changes: 4 additions & 0 deletions src/common/localization/en-us.ts
Original file line number Diff line number Diff line change
Expand Up @@ -384,6 +384,10 @@ export const english: IAppStrings = {
name: "Select multiple words",
description: "Click and hold on word. Then, hover over additional words.",
},
deleteAllLabelsForTag: {
name: "Delete all labels for a tag",
description: "Select all labels for a tag on document and press 'delete' key"
}
},
headers: {
keyboardShortcuts: "Keyboard shortcuts",
Expand Down
4 changes: 4 additions & 0 deletions src/common/localization/es-cl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -387,6 +387,10 @@ export const spanish: IAppStrings = {
name: "Selección de palabras múltiples",
description: "Haga clic y mantenga presionada la palabra, luego desplace el cursor sobre otras palabras para seleccionar varias palabras a la vez.",
},
deleteAllLabelsForTag: {
name: "Eliminar información asociada a una etiqueta",
description: "Seleccione todas las etiquetas para una etiqueta en el documento y presione la tecla 'delete'"
}
},
headers: {
keyboardShortcuts: "Atajos de teclado",
Expand Down
4 changes: 4 additions & 0 deletions src/common/strings.ts
Original file line number Diff line number Diff line change
Expand Up @@ -380,6 +380,10 @@ export interface IAppStrings {
name: string,
description: string,
},
deleteAllLabelsForTag: {
name: string,
description: string;
}
},
headers: {
keyboardShortcuts: string,
Expand Down
14 changes: 11 additions & 3 deletions src/react/components/shell/keyboardShortcuts.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,14 @@ import "./keyboardShortcuts.scss";
export interface IHotKeysModalState {
showModal: boolean;
}
interface IKey {
interface IKeyItem {
key: string;
description: string;
}
interface ITipsItem {
name: string;
description: string;
}

export const KeyboardShortcuts: React.FC = () => {
const dark: ICustomizations = {
Expand All @@ -29,7 +33,7 @@ export const KeyboardShortcuts: React.FC = () => {
const [showModal, setShowModal] = useState(false);
const closeModal = () => setShowModal(false);

const shortcutsItems: IKey[] = [
const shortcutsItems: IKeyItem[] = [
{
key: strings.shortcuts.squareBrackets.keys.leftBracket,
description: strings.shortcuts.squareBrackets.description.prevWord,
Expand Down Expand Up @@ -69,7 +73,7 @@ export const KeyboardShortcuts: React.FC = () => {

];

const tipsItems = [
const tipsItems: ITipsItem[] = [
{
name: strings.shortcuts.tips.quickLabeling.name,
description: strings.shortcuts.tips.quickLabeling.description,
Expand All @@ -82,6 +86,10 @@ export const KeyboardShortcuts: React.FC = () => {
name: strings.shortcuts.tips.multipleWordSelection.name,
description: strings.shortcuts.tips.multipleWordSelection.description,
},
{
name: strings.shortcuts.tips.deleteAllLabelsForTag.name,
description: strings.shortcuts.tips.deleteAllLabelsForTag.description,
}
];
const ShortcutsListItems = ({ items }): JSX.Element => {
return items.map((item, idx) => (
Expand Down

0 comments on commit 1c39800

Please sign in to comment.