File tree Expand file tree Collapse file tree 4 files changed +5
-69
lines changed
packages/richtext-lexical/src
test/fields/collections/Lexical/e2e/main Expand file tree Collapse file tree 4 files changed +5
-69
lines changed Original file line number Diff line number Diff line change 1
1
'use client'
2
2
3
+ import { TabIndentationPlugin } from '@lexical/react/LexicalTabIndentationPlugin'
3
4
import { INDENT_CONTENT_COMMAND , OUTDENT_CONTENT_COMMAND } from 'lexical'
4
5
5
6
import type { ToolbarGroup } from '../../toolbars/types.js'
6
7
7
8
import { IndentDecreaseIcon } from '../../../lexical/ui/icons/IndentDecrease/index.js'
8
9
import { IndentIncreaseIcon } from '../../../lexical/ui/icons/IndentIncrease/index.js'
9
10
import { createClientFeature } from '../../../utilities/createClientFeature.js'
10
- import { IndentPlugin } from './plugins/index.js'
11
11
import { toolbarIndentGroupWithItems } from './toolbarIndentGroup.js'
12
12
13
13
const toolbarGroups : ToolbarGroup [ ] = [
@@ -58,7 +58,7 @@ const toolbarGroups: ToolbarGroup[] = [
58
58
export const IndentFeatureClient = createClientFeature ( {
59
59
plugins : [
60
60
{
61
- Component : IndentPlugin ,
61
+ Component : TabIndentationPlugin ,
62
62
position : 'normal' ,
63
63
} ,
64
64
] ,
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -114,7 +114,7 @@ export const LexicalEditor: React.FC<
114
114
< RichTextPlugin
115
115
contentEditable = {
116
116
< div className = "editor-scroller" >
117
- < div className = "editor" ref = { onRef } tabIndex = { - 1 } >
117
+ < div className = "editor" ref = { onRef } >
118
118
< LexicalContentEditable editorConfig = { editorConfig } />
119
119
</ div >
120
120
</ div >
Original file line number Diff line number Diff line change @@ -784,11 +784,8 @@ describe('lexicalMain', () => {
784
784
} )
785
785
} )
786
786
787
- /**
788
- * When the escape key is pressed, Firefox resets the active element to the beginning of the page instead of staying with the editor.
789
- * By applying a keydown listener when the escape key is pressed, we can programatically focus the previous element if shift+tab is pressed.
790
- */
791
- test ( 'ensure escape key can be used to move focus away from editor' , async ( ) => {
787
+ // NOTE: It's not worth it right now. Maybe later. See https://github.com/payloadcms/payload/issues/10049
788
+ test . skip ( 'ensure escape key can be used to move focus away from editor' , async ( ) => {
792
789
await navigateToLexicalFields ( )
793
790
794
791
const richTextField = page . locator ( '.rich-text-lexical' ) . first ( )
You can’t perform that action at this time.
0 commit comments