Skip to content

Commit

Permalink
fix: is-hotkey imports
Browse files Browse the repository at this point in the history
  • Loading branch information
shahriar-shojib committed Sep 29, 2023
1 parent bbbd8ed commit b8be697
Show file tree
Hide file tree
Showing 20 changed files with 29 additions and 25 deletions.
3 changes: 3 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -187,5 +187,8 @@
"node": "^14.13.1 || >=16.0.0",
"npm": "please-use-yarn",
"yarn": ">=1.22.0"
},
"dependencies": {
"is-hotkey": "0.2.0"
}
}
2 changes: 1 addition & 1 deletion packages/autoformat/src/onKeyDownAutoformat.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import {
Value,
WithPlatePlugin,
} from '@udecode/plate-common';
import isHotkey from 'is-hotkey';
import { isHotkey } from 'is-hotkey';
import { Range } from 'slate';

import { AutoformatPlugin, AutoformatRule, AutoformatTextRule } from './types';
Expand Down
2 changes: 1 addition & 1 deletion packages/break/src/exit-break/onKeyDownExitBreak.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import {
Value,
WithPlatePlugin,
} from '@udecode/plate-common';
import isHotkey from 'is-hotkey';
import { isHotkey } from 'is-hotkey';

import { exitBreak } from './transforms/exitBreak';
import { ExitBreakPlugin } from './types';
Expand Down
2 changes: 1 addition & 1 deletion packages/break/src/soft-break/onKeyDownSoftBreak.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import {
Value,
WithPlatePlugin,
} from '@udecode/plate-common';
import isHotkey from 'is-hotkey';
import { isHotkey } from 'is-hotkey';

import { SoftBreakPlugin } from './types';

Expand Down
2 changes: 1 addition & 1 deletion packages/caption/src/components/CaptionTextarea.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import {
useEditorRef,
useElement,
} from '@udecode/plate-common';
import isHotkey from 'is-hotkey';
import { isHotkey } from 'is-hotkey';
import { TextareaAutosizeProps } from 'react-textarea-autosize';
import { Path } from 'slate';
import { useReadOnly } from 'slate-react';
Expand Down
2 changes: 1 addition & 1 deletion packages/caption/src/onKeyDownCaption.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import {
getPluginTypes,
KeyboardHandler,
} from '@udecode/plate-common';
import isHotkey from 'is-hotkey';
import { isHotkey } from 'is-hotkey';

import { captionGlobalStore } from './captionGlobalStore';
import { CaptionPlugin } from './createCaptionPlugin';
Expand Down
2 changes: 1 addition & 1 deletion packages/caption/src/withCaption.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {
Value,
WithPlatePlugin,
} from '@udecode/plate-common';
import isHotkey from 'is-hotkey';
import { isHotkey } from 'is-hotkey';
import { Range } from 'slate';

import { captionGlobalStore } from './captionGlobalStore';
Expand Down
2 changes: 1 addition & 1 deletion packages/code-block/src/onKeyDownCodeBlock.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import {
Value,
withoutNormalizing,
} from '@udecode/plate-common';
import isHotkey from 'is-hotkey';
import { isHotkey } from 'is-hotkey';

import { getCodeLineType } from './options/getCodeLineType';
import { getCodeLineEntry } from './queries/getCodeLineEntry';
Expand Down
2 changes: 1 addition & 1 deletion packages/combobox/src/onKeyDownCombobox.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import {
PlateEditor,
Value,
} from '@udecode/plate-common';
import isHotkey from 'is-hotkey';
import { isHotkey } from 'is-hotkey';

import {
comboboxActions,
Expand Down
2 changes: 1 addition & 1 deletion packages/indent-list/src/onKeyDownIndentList.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {
Value,
WithPlatePlugin,
} from '@udecode/plate-common';
import isHotkey from 'is-hotkey';
import { isHotkey } from 'is-hotkey';

import {
IndentListPlugin,
Expand Down
2 changes: 1 addition & 1 deletion packages/list/src/onKeyDownList.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import {
Value,
WithPlatePlugin,
} from '@udecode/plate-common';
import isHotkey from 'is-hotkey';
import { isHotkey } from 'is-hotkey';
import { castArray } from 'lodash';
import { Range } from 'slate';

Expand Down
2 changes: 1 addition & 1 deletion packages/mention/src/handlers/mentionOnKeyDownHandler.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { PlateEditor, Value } from '@udecode/plate-common';
import isHotkey from 'is-hotkey';
import { isHotkey } from 'is-hotkey';

import { findMentionInput } from '../queries/index';
import { removeMentionInput } from '../transforms/index';
Expand Down
2 changes: 1 addition & 1 deletion packages/mention/src/handlers/moveSelectionByOffset.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { moveSelection, PlateEditor, Value } from '@udecode/plate-common';
import isHotkey from 'is-hotkey';
import { isHotkey } from 'is-hotkey';
import { Range } from 'slate';

import { KeyboardEventHandler } from './KeyboardEventHandler';
Expand Down
2 changes: 1 addition & 1 deletion packages/plate-utils/src/plate/onKeyDownToggleElement.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import {
WithPlatePlugin,
} from '@udecode/plate-core';
import { Value } from '@udecode/slate';
import isHotkey from 'is-hotkey';
import { isHotkey } from 'is-hotkey';
import { castArray } from 'lodash';

export const onKeyDownToggleElement =
Expand Down
2 changes: 1 addition & 1 deletion packages/plate-utils/src/plate/onKeyDownToggleMark.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import {
} from '@udecode/plate-core';
import { Value } from '@udecode/slate';
import { toggleMark } from '@udecode/slate-utils';
import isHotkey from 'is-hotkey';
import { isHotkey } from 'is-hotkey';

export const onKeyDownToggleMark =
<V extends Value = Value, E extends PlateEditor<V> = PlateEditor<V>>(
Expand Down
2 changes: 1 addition & 1 deletion packages/reset-node/src/onKeyDownResetNode.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {
Value,
WithPlatePlugin,
} from '@udecode/plate-common';
import isHotkey from 'is-hotkey';
import { isHotkey } from 'is-hotkey';

import { ResetNodePlugin } from './types';

Expand Down
2 changes: 1 addition & 1 deletion packages/selection/src/useHooksBlockSelection.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import {
Value,
WithPlatePlugin,
} from '@udecode/plate-common';
import isHotkey from 'is-hotkey';
import { isHotkey } from 'is-hotkey';

import {
blockSelectionActions,
Expand Down
2 changes: 1 addition & 1 deletion packages/table/src/onKeyDownTable.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import {
Value,
WithPlatePlugin,
} from '@udecode/plate-common';
import isHotkey from 'is-hotkey';
import { isHotkey } from 'is-hotkey';

import { keyShiftEdges } from './constants';
import {
Expand Down
2 changes: 1 addition & 1 deletion packages/table/src/transforms/overrideSelectionFromCell.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import {
TRange,
Value,
} from '@udecode/plate-common';
import isHotkey from 'is-hotkey';
import { isHotkey } from 'is-hotkey';

import { keyShiftEdges } from '../constants';
import { getCellTypes } from '../utils/index';
Expand Down
15 changes: 8 additions & 7 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -14093,20 +14093,20 @@ __metadata:
languageName: node
linkType: hard

"is-hotkey@npm:0.2.0, is-hotkey@npm:^0.2.0":
version: 0.2.0
resolution: "is-hotkey@npm:0.2.0"
checksum: 62047b3137a9cdc257f834626fff0f730e1e0aeac033fcee81da5c60bcfeb03cac11b0141bf8b293f19bab6e58f0daea1bc7f41962cc0187f8a4e65e3942792a
languageName: node
linkType: hard

"is-hotkey@npm:^0.1.6":
version: 0.1.8
resolution: "is-hotkey@npm:0.1.8"
checksum: 0fd88b39c4295106ca57c2bd3f8feb2a96c80f3218ab1ccd16860185e3a337be24d54d200f35872cf47ee529ed21759350e6454406f6ce2e6abe9d7153de5c9a
languageName: node
linkType: hard

"is-hotkey@npm:^0.2.0":
version: 0.2.0
resolution: "is-hotkey@npm:0.2.0"
checksum: 62047b3137a9cdc257f834626fff0f730e1e0aeac033fcee81da5c60bcfeb03cac11b0141bf8b293f19bab6e58f0daea1bc7f41962cc0187f8a4e65e3942792a
languageName: node
linkType: hard

"is-inside-container@npm:^1.0.0":
version: 1.0.0
resolution: "is-inside-container@npm:1.0.0"
Expand Down Expand Up @@ -20824,6 +20824,7 @@ __metadata:
eslint-plugin-testing-library: "npm:^5.11.0"
eslint-plugin-unicorn: "npm:^47.0.0"
eslint-plugin-unused-imports: "npm:^3.0.0"
is-hotkey: "npm:0.2.0"
jest: "npm:29.7.0"
jest-environment-jsdom: "npm:^29.6.1"
patch-package: "npm:^7.0.2"
Expand Down

0 comments on commit b8be697

Please sign in to comment.