Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: add missing exports from extensions #53

Merged
merged 1 commit into from
Jan 23, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/extensions/behavior/Selection/commands.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ import {isCodeBlock} from '../../../utils/nodes';
import {GapCursorSelection} from '../../behavior/Cursor/GapCursorSelection';
import {createFakeParagraphNear} from '../../../utils/selection';

export {createFakeParagraphNear};

export enum Direction {
up = 'up',
right = 'right',
Expand Down
2 changes: 2 additions & 0 deletions src/extensions/behavior/Selection/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
import type {ExtensionAuto} from '../../../core';
import {selection} from './selection';

export * as SelectionCommands from './commands';

export const Selection: ExtensionAuto = (builder) => {
builder.addPlugin(selection);
};
7 changes: 7 additions & 0 deletions src/extensions/markdown/CodeBlock/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,13 @@ import {resetCodeblock} from './commands';
import {cbAction, cbType, codeBlock, langAttr} from './const';
import {handlePaste} from './handle-paste';

export {resetCodeblock} from './commands';
export {
codeBlock as codeBlockNodeName,
langAttr as codeBlockLangAttr,
cbType as codeBlockType,
} from './const';

export type CodeBlockOptions = {
codeBlockKey?: string | null;
};
Expand Down
4 changes: 3 additions & 1 deletion src/extensions/markdown/Link/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,10 @@ import {markTypeFactory} from '../../../utils/schema';
import {LinkActionMeta, LinkActionParams, linkCommand} from './actions';
import {linkPasteEnhance} from './paste-plugin';

export type {LinkActionParams} from './actions';
export type {LinkActionParams, LinkActionMeta} from './actions';
export {linkCommand} from './actions';
export {normalizeUrlFactory} from './utils';
export {removeLink} from './commands';

export const link = 'link';
const linkAction = 'link';
Expand Down
4 changes: 3 additions & 1 deletion src/extensions/markdown/Table/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@ import {spec} from './spec';
import {toYfm} from './toYfm';
import {createTableAction, deleteTableAction} from './actions';

export {TableNode} from './const';
export {TableNode, TableAttrs, CellAlign as TableCellAlign} from './const';
export * as TableHelpers from './helpers';
export * as TableActions from './actions';

export const Table: ExtensionAuto = (builder) => {
builder
Expand Down
1 change: 1 addition & 0 deletions src/extensions/yfm/YfmTable/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import {fixPastedTableBodies} from './paste';
const action = 'createYfmTable';

export {YfmTableNode} from './const';
export {convertToYfmTable} from './commands/convert-table';
export {yfmTableType, yfmTableBodyType, yfmTableRowType, yfmTableCellType} from './utils';
export type YfmTableOptions = YfmTableSpecOptions;
export const YfmTable: ExtensionWithOptions<YfmTableOptions> = (builder, options) => {
Expand Down
8 changes: 7 additions & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,11 @@ export {markInputRule, nodeInputRule, inlineNodeInputRule} from './utils/inputru
export {findMark, isMarkActive} from './utils/marks';
export {findFirstTextblockChild, isNodeEmpty, isCodeBlock, isSelectableNode} from './utils/nodes';
export {nodeTypeFactory, markTypeFactory, isSameNodeType} from './utils/schema';
export {isTextSelection, isNodeSelection, isWholeSelection, get$Cursor} from './utils/selection';
export {
isTextSelection,
isNodeSelection,
isWholeSelection,
get$Cursor,
findSelectedNodeOfType,
} from './utils/selection';
export * from './table-utils';