add precommit hook for linting and automatic eslint fixes + update eslint packages (#2862)
* chore: add precommit hook for eslint fixes, fix linting issues * chore: add eslint import sort plugin
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
// @ts-nocheck
|
||||
import { NodeView } from 'prosemirror-view'
|
||||
import { Node as ProseMirrorNode } from 'prosemirror-model'
|
||||
import { NodeView } from 'prosemirror-view'
|
||||
|
||||
export function updateColumns(node: ProseMirrorNode, colgroup: Element, table: Element, cellMinWidth: number, overrideCol?: number, overrideValue?: any) {
|
||||
let totalWidth = 0
|
||||
|
||||
@@ -1,34 +1,35 @@
|
||||
import {
|
||||
callOrReturn,
|
||||
getExtensionField,
|
||||
mergeAttributes,
|
||||
Node,
|
||||
ParentConfig,
|
||||
mergeAttributes,
|
||||
getExtensionField,
|
||||
callOrReturn,
|
||||
} from '@tiptap/core'
|
||||
import { TextSelection } from 'prosemirror-state'
|
||||
import {
|
||||
tableEditing,
|
||||
columnResizing,
|
||||
goToNextCell,
|
||||
addColumnBefore,
|
||||
addColumnAfter,
|
||||
deleteColumn,
|
||||
addRowBefore,
|
||||
addColumnBefore,
|
||||
addRowAfter,
|
||||
addRowBefore,
|
||||
CellSelection,
|
||||
columnResizing,
|
||||
deleteColumn,
|
||||
deleteRow,
|
||||
deleteTable,
|
||||
fixTables,
|
||||
goToNextCell,
|
||||
mergeCells,
|
||||
setCellAttr,
|
||||
splitCell,
|
||||
tableEditing,
|
||||
toggleHeader,
|
||||
toggleHeaderCell,
|
||||
setCellAttr,
|
||||
fixTables,
|
||||
CellSelection,
|
||||
} from 'prosemirror-tables'
|
||||
import { NodeView } from 'prosemirror-view'
|
||||
import { TextSelection } from 'prosemirror-state'
|
||||
|
||||
import { TableView } from './TableView'
|
||||
import { createTable } from './utilities/createTable'
|
||||
import { deleteTableWhenAllCellsSelected } from './utilities/deleteTableWhenAllCellsSelected'
|
||||
import { TableView } from './TableView'
|
||||
|
||||
export interface TableOptions {
|
||||
HTMLAttributes: Record<string, any>,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import {
|
||||
NodeType, Fragment,
|
||||
Fragment,
|
||||
Node as ProsemirrorNode,
|
||||
Schema,
|
||||
NodeType, Schema,
|
||||
} from 'prosemirror-model'
|
||||
|
||||
export function createCell(cellType: NodeType, cellContent?: Fragment<Schema> | ProsemirrorNode<Schema> | Array<ProsemirrorNode<Schema>>): ProsemirrorNode | null | undefined {
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import { Schema, Fragment, Node as ProsemirrorNode } from 'prosemirror-model'
|
||||
import { Fragment, Node as ProsemirrorNode, Schema } from 'prosemirror-model'
|
||||
|
||||
import { createCell } from './createCell'
|
||||
import { getTableNodeTypes } from './getTableNodeTypes'
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import { KeyboardShortcutCommand, findParentNodeClosestToPos } from '@tiptap/core'
|
||||
import { findParentNodeClosestToPos, KeyboardShortcutCommand } from '@tiptap/core'
|
||||
|
||||
import { isCellSelection } from './isCellSelection'
|
||||
|
||||
export const deleteTableWhenAllCellsSelected: KeyboardShortcutCommand = ({ editor }) => {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Schema, NodeType } from 'prosemirror-model'
|
||||
import { NodeType, Schema } from 'prosemirror-model'
|
||||
|
||||
export function getTableNodeTypes(schema: Schema): { [key: string]: NodeType } {
|
||||
if (schema.cached.tableNodeTypes) {
|
||||
|
||||
Reference in New Issue
Block a user