oasis-editor 0.0.229 → 0.0.231
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/OasisEditorApp-IDmEjhGJ.js +1 -0
- package/dist/app/controllers/EditorCommandsController.d.ts +2 -1
- package/dist/app/controllers/useEditorStyle.d.ts +2 -1
- package/dist/core/commands/builtinCommands.d.ts +1 -1
- package/dist/core/commands/publicCommandTypes.d.ts +2 -1
- package/dist/core/commands/textFormatting.d.ts +3 -1
- package/dist/defaultToolbar-D9PBASVE.js +1 -0
- package/dist/oasis-editor.css +1 -1
- package/dist/oasis-editor.js +1 -1
- package/dist/oasis-editor.umd.cjs +1 -1
- package/dist/plugins/internal/essentialsCapabilities.d.ts +2 -1
- package/dist/ui/app/createAppCommandsController.d.ts +2 -0
- package/dist/ui/app/createEditorCommandRuntime.d.ts +1 -0
- package/dist/ui/app/createEditorInteractionRuntime.d.ts +1 -0
- package/dist/ui/components/Toolbar/controls/UnderlineControl.d.ts +1 -1
- package/dist/ui/utils/IconManager.d.ts +2 -0
- package/dist/ui/utils/customIcons.d.ts +1 -4
- package/package.json +5 -2
- package/dist/OasisEditorApp-Dkk2-Ed0.js +0 -1
- package/dist/defaultToolbar-6IjbWowg.js +0 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
|
+
import { EditorUnderlineStyle, EditorParagraphListStyle, EditorParagraphStyle, EditorSection, EditorSectionBreakType, EditorState, EditorTextStyle } from '../../core/model.js';
|
|
1
2
|
import { ImageBorderPatch } from '../../core/commands/image.js';
|
|
2
|
-
import { EditorParagraphListStyle, EditorParagraphStyle, EditorSection, EditorSectionBreakType, EditorState, EditorTextStyle } from '../../core/model.js';
|
|
3
3
|
import { TextCaseMode } from '../../core/commands/text.js';
|
|
4
4
|
import { BooleanStyleKey, ParagraphStyleKey, ToolbarStyleState } from '../../ui/toolbarStyleState.js';
|
|
5
5
|
import { EditorLogger } from '../../utils/logger.js';
|
|
@@ -20,6 +20,7 @@ declare function createEditorCommandsControllerImpl(deps: EditorCommandsControll
|
|
|
20
20
|
applyBooleanStyleCommand: (key: BooleanStyleKey) => void;
|
|
21
21
|
applyToggleCharacterBorderCommand: () => void;
|
|
22
22
|
applyValueStyleCommand: <K extends "styleId" | "fontFamily" | "fontSize" | "color" | "highlight" | "shading" | "language" | "textEffect" | "link" | "underlineStyle">(key: K, value: EditorTextStyle[K] | null) => void;
|
|
23
|
+
applyUnderlineStyleCommand: (style: EditorUnderlineStyle | null) => void;
|
|
23
24
|
applyChangeTextCaseCommand: (mode: TextCaseMode) => void;
|
|
24
25
|
applyClearFormattingCommand: () => void;
|
|
25
26
|
applyParagraphStyleCommand: <K extends ParagraphStyleKey>(key: K, value: EditorParagraphStyle[K] | null) => void;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { EditorState, EditorTextStyle } from '../../core/model.js';
|
|
1
|
+
import { EditorUnderlineStyle, EditorState, EditorTextStyle } from '../../core/model.js';
|
|
2
2
|
import { ToolbarStyleState, BooleanStyleKey } from '../../ui/toolbarStyleState.js';
|
|
3
3
|
import { createEditorCommandsController } from './EditorCommandsController.js';
|
|
4
4
|
type ValueStyleKey = "styleId" | "fontFamily" | "fontSize" | "color" | "highlight" | "shading" | "language" | "textEffect" | "link" | "underlineStyle";
|
|
@@ -18,6 +18,7 @@ declare function createEditorStyleControllerImpl(deps: UseEditorStyleProps): {
|
|
|
18
18
|
clearPendingCaretTextStyle: () => void;
|
|
19
19
|
toolbarStyleState: () => ToolbarStyleState;
|
|
20
20
|
applyToolbarValueStyleCommand: <K extends ValueStyleKey>(key: K, value: EditorTextStyle[K] | null) => void;
|
|
21
|
+
applyToolbarUnderlineStyleCommand: (style: EditorUnderlineStyle | null) => void;
|
|
21
22
|
applyToolbarBooleanStyleCommand: (key: BooleanStyleKey) => void;
|
|
22
23
|
};
|
|
23
24
|
export {};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const OASIS_BUILTIN_COMMANDS: readonly ["selectAll", "selectWord", "selectSentence", "selectParagraph", "selectCollapse", "selectText", "selectRange", "insertFootnote", "insertText", "insertEquation", "updateEquation", "insertTableOfContents", "updateTableOfContents", "pastePlainText", "paste", "pasteAsPlainText", "pasteMergeFormatting", "formatPainter", "formatPainterContinuous", "cancelFormatPainter", "bold", "italic", "underline", "doubleUnderline", "wordUnderline", "strike", "doubleStrike", "smallCaps", "allCaps", "hidden", "noProof", "webHidden", "specVanish", "contextualAlternates", "characterBorder", "shadow", "emboss", "engrave", "outline", "superscript", "subscript", "link", "unlink", "alignLeft", "alignCenter", "alignRight", "alignJustify", "orderedList", "bulletList", "find", "replace", "replaceAll", "toggleTrackChanges", "acceptRevisions", "rejectRevisions", "acceptAllRevisions", "rejectAllRevisions", "nextRevision", "previousRevision", "nextComment", "previousComment", "newComment", "replyComment", "editComment", "toggleCommentsPanel", "resolveComment", "reopenComment", "deleteComment", "toggleShowMargins", "toggleShowParagraphMarks", "togglePreciseFonts", "undo", "redo", "pageBreak", "lineBreak", "columnBreak", "splitBlock", "insertNonBreakingSpace", "insertNonBreakingHyphen", "insertOptionalHyphen", "insertEmDash", "insertEllipsis", "insertCopyright", "insertRegistered", "insertTrademark", "setFontFamily", "setFontSize", "increaseFontSize", "decreaseFontSize", "growFont1", "shrinkFont1", "changeTextCase", "clearFormatting", "setColor", "setHighlight", "setTextShading", "setStyleId", "setCharacterStyleId", "setUnderlineStyle", "setUnderlineColor", "setCharacterScale", "setCharacterSpacing", "setRunSnapToGrid", "setFitText", "setBaselineShift", "setEmphasisMark", "setTextEffect", "setKerning", "setLigatures", "setNumberSpacing", "setNumberForm", "setStylisticSet", "documentStyles", "print", "copy", "cut", "newDocument", "exportDocx", "exportPdf", "importDocument", "insertHtml", "insertImage", "editImageAlt", "insertImageCaption", "imageContext", "imageWidthCm", "imageHeightCm", "imageCrop", "imageCropAspect", "imageCropShape", "imageCropFill", "imageCropFit", "imageCropReset", "imageFlip", "imageRotate", "imageBorder", "imageTransparency", "resetImage", "outdent", "indent", "moveParagraphsUp", "moveParagraphsDown", "togglePageBreakBefore", "toggleKeepWithNext", "toggleKeepLinesTogether", "toggleWidowControl", "toggleParagraphBidi", "setParagraphBidi", "setParagraphAlign", "sortParagraphs", "promote", "demote", "resetParagraphFormatting", "setParagraphTabStops", "setOutlineLevel", "setSpacingAfter", "setSpacingBefore", "setContextualSpacing", "setMirrorIndents", "setLineRule", "setTextDirection", "setSuppressAutoHyphens", "setSuppressLineNumbers", "setKinsoku", "setOverflowPunct", "setWordWrap", "setAutoSpaceDE", "setAutoSpaceDN", "setAdjustRightInd", "setTopLinePunct", "setPageBreakBefore", "setKeepWithNext", "setKeepLinesTogether", "setWidowControl", "setIndentLeft", "setIndentRight", "setIndentFirstLine", "setIndentHanging", "setSpecialIndent", "setParagraphShading", "applyParagraphBorders", "applyHorizontalLine", "setDropCap", "setLineHeight", "setListFormat", "setListStartAt", "setListLevel", "toggleOrientation", "setOrientation", "sectionBreakNextPage", "sectionBreakContinuous", "sectionBreakEvenPage", "sectionBreakOddPage", "sectionBreakNextColumn", "setPageMargins", "setMarginsPreset", "setSectionPageNumbering", "setPaperSize", "setPaperSizePreset", "setColumns", "setColumnsPreset", "setSectionVerticalAlign", "setSectionStart", "setSectionBidi", "setHyphenation", "editHeader", "editFooter", "editFirstPageHeader", "editEvenPageHeader", "editFirstPageFooter", "editEvenPageFooter", "insertPageNumber", "insertPageNumberXOfY", "placePageNumberTop", "placePageNumberBottom", "insertBookmark", "removeBookmark", "insertDateField", "insertDateTime", "insertCrossReference", "setNoteOptions", "exitHeaderFooter", "setDifferentFirstPage", "setDifferentOddEven", "applyDocumentTheme", "setDocumentColorScheme", "setDocumentFontScheme", "setDocumentParagraphSpacing", "setDocumentEffects", "setDocumentPageColor", "setDocumentWatermark", "setDocumentPageBorder", "setDocumentDesignDefault", "tableContext", "tableMerge", "tableSplit", "tableInsertColumnBefore", "tableInsertColumnAfter", "tableDeleteColumn", "tableDeleteCells", "tableInsertRowBefore", "tableInsertRowAfter", "tableDeleteRow", "tableCellShading", "tableCellBorders", "tableCellNoBorders", "tableApplyBorderPreset", "toggleTableDrawBorders", "toggleTableGridlines", "tableWidth100", "tableAlignLeft", "tableAlignCenter", "tableAlignRight", "tableSetCellVerticalAlign", "tableSetCellTextDirection", "tableToText", "textToTable", "tableSplitAtRow", "tableSortAscending", "tableSortDescending", "tableDelete", "tableRepeatHeaderRows", "tableSetCellMargins", "tableSetCellSpacing", "tableSetTableIndent", "tableSetAlignment", "tableFormula", "tableSelectCell", "tableSelectRow", "tableSelectColumn", "tableSelectTable", "tableSetRowHeight", "tableSetBreakAcrossPages", "tableSetHeaderRow", "tableSetColumnWidth", "tableSetTableWidth", "tableSetCellWidth", "tableSetCellNoWrap", "tableSetCellFitText", "tableToggleHeaderRow", "tableToggleTotalRow", "tableToggleBandedRows", "tableToggleFirstColumn", "tableToggleLastColumn", "tableToggleBandedColumns", "setTableStyle", "tableToggleAutoFit", "tableAutoFit", "tableDistributeColumns", "tableDistributeRows", "insertTable", "insertShape", "setShapeFill", "setShapeOutline", "setShapeOutlineWidth", "alignFloatingObject", "reorderFloatingObject", "nudgeFloatingObject", "setFloatingFixedPosition", "setFloatingRotation", "setFloatingWrapPreset", "setFloatingWrapText", "setFloatingPositionPreset", "setShapePreset", "setTextBoxTextDirection", "setTextBoxVerticalAlign", "editTextBoxAlt", "rotateTextBox", "textBoxWidthCm", "textBoxHeightCm", "openSymbolDialog", "openEquationDialog", "tableProperties"];
|
|
1
|
+
export declare const OASIS_BUILTIN_COMMANDS: readonly ["selectAll", "selectWord", "selectSentence", "selectParagraph", "selectCollapse", "selectText", "selectRange", "insertFootnote", "insertText", "insertEquation", "updateEquation", "insertTableOfContents", "updateTableOfContents", "pastePlainText", "paste", "pasteAsPlainText", "pasteMergeFormatting", "formatPainter", "formatPainterContinuous", "cancelFormatPainter", "bold", "italic", "underline", "doubleUnderline", "wordUnderline", "strike", "doubleStrike", "smallCaps", "allCaps", "hidden", "noProof", "webHidden", "specVanish", "contextualAlternates", "characterBorder", "shadow", "emboss", "engrave", "outline", "superscript", "subscript", "link", "unlink", "alignLeft", "alignCenter", "alignRight", "alignJustify", "orderedList", "bulletList", "find", "replace", "replaceAll", "toggleTrackChanges", "acceptRevisions", "rejectRevisions", "acceptAllRevisions", "rejectAllRevisions", "nextRevision", "previousRevision", "nextComment", "previousComment", "newComment", "replyComment", "editComment", "toggleCommentsPanel", "resolveComment", "reopenComment", "deleteComment", "toggleShowMargins", "toggleShowParagraphMarks", "togglePreciseFonts", "undo", "redo", "pageBreak", "lineBreak", "columnBreak", "splitBlock", "insertNonBreakingSpace", "insertNonBreakingHyphen", "insertOptionalHyphen", "insertEmDash", "insertEllipsis", "insertCopyright", "insertRegistered", "insertTrademark", "setFontFamily", "setFontSize", "increaseFontSize", "decreaseFontSize", "growFont1", "shrinkFont1", "changeTextCase", "clearFormatting", "setColor", "setHighlight", "setTextShading", "setStyleId", "setCharacterStyleId", "setUnderlineStyle", "applyUnderlineStyle", "setUnderlineColor", "setCharacterScale", "setCharacterSpacing", "setRunSnapToGrid", "setFitText", "setBaselineShift", "setEmphasisMark", "setTextEffect", "setKerning", "setLigatures", "setNumberSpacing", "setNumberForm", "setStylisticSet", "documentStyles", "print", "copy", "cut", "newDocument", "exportDocx", "exportPdf", "importDocument", "insertHtml", "insertImage", "editImageAlt", "insertImageCaption", "imageContext", "imageWidthCm", "imageHeightCm", "imageCrop", "imageCropAspect", "imageCropShape", "imageCropFill", "imageCropFit", "imageCropReset", "imageFlip", "imageRotate", "imageBorder", "imageTransparency", "resetImage", "outdent", "indent", "moveParagraphsUp", "moveParagraphsDown", "togglePageBreakBefore", "toggleKeepWithNext", "toggleKeepLinesTogether", "toggleWidowControl", "toggleParagraphBidi", "setParagraphBidi", "setParagraphAlign", "sortParagraphs", "promote", "demote", "resetParagraphFormatting", "setParagraphTabStops", "setOutlineLevel", "setSpacingAfter", "setSpacingBefore", "setContextualSpacing", "setMirrorIndents", "setLineRule", "setTextDirection", "setSuppressAutoHyphens", "setSuppressLineNumbers", "setKinsoku", "setOverflowPunct", "setWordWrap", "setAutoSpaceDE", "setAutoSpaceDN", "setAdjustRightInd", "setTopLinePunct", "setPageBreakBefore", "setKeepWithNext", "setKeepLinesTogether", "setWidowControl", "setIndentLeft", "setIndentRight", "setIndentFirstLine", "setIndentHanging", "setSpecialIndent", "setParagraphShading", "applyParagraphBorders", "applyHorizontalLine", "setDropCap", "setLineHeight", "setListFormat", "setListStartAt", "setListLevel", "toggleOrientation", "setOrientation", "sectionBreakNextPage", "sectionBreakContinuous", "sectionBreakEvenPage", "sectionBreakOddPage", "sectionBreakNextColumn", "setPageMargins", "setMarginsPreset", "setSectionPageNumbering", "setPaperSize", "setPaperSizePreset", "setColumns", "setColumnsPreset", "setSectionVerticalAlign", "setSectionStart", "setSectionBidi", "setHyphenation", "editHeader", "editFooter", "editFirstPageHeader", "editEvenPageHeader", "editFirstPageFooter", "editEvenPageFooter", "insertPageNumber", "insertPageNumberXOfY", "placePageNumberTop", "placePageNumberBottom", "insertBookmark", "removeBookmark", "insertDateField", "insertDateTime", "insertCrossReference", "setNoteOptions", "exitHeaderFooter", "setDifferentFirstPage", "setDifferentOddEven", "applyDocumentTheme", "setDocumentColorScheme", "setDocumentFontScheme", "setDocumentParagraphSpacing", "setDocumentEffects", "setDocumentPageColor", "setDocumentWatermark", "setDocumentPageBorder", "setDocumentDesignDefault", "tableContext", "tableMerge", "tableSplit", "tableInsertColumnBefore", "tableInsertColumnAfter", "tableDeleteColumn", "tableDeleteCells", "tableInsertRowBefore", "tableInsertRowAfter", "tableDeleteRow", "tableCellShading", "tableCellBorders", "tableCellNoBorders", "tableApplyBorderPreset", "toggleTableDrawBorders", "toggleTableGridlines", "tableWidth100", "tableAlignLeft", "tableAlignCenter", "tableAlignRight", "tableSetCellVerticalAlign", "tableSetCellTextDirection", "tableToText", "textToTable", "tableSplitAtRow", "tableSortAscending", "tableSortDescending", "tableDelete", "tableRepeatHeaderRows", "tableSetCellMargins", "tableSetCellSpacing", "tableSetTableIndent", "tableSetAlignment", "tableFormula", "tableSelectCell", "tableSelectRow", "tableSelectColumn", "tableSelectTable", "tableSetRowHeight", "tableSetBreakAcrossPages", "tableSetHeaderRow", "tableSetColumnWidth", "tableSetTableWidth", "tableSetCellWidth", "tableSetCellNoWrap", "tableSetCellFitText", "tableToggleHeaderRow", "tableToggleTotalRow", "tableToggleBandedRows", "tableToggleFirstColumn", "tableToggleLastColumn", "tableToggleBandedColumns", "setTableStyle", "tableToggleAutoFit", "tableAutoFit", "tableDistributeColumns", "tableDistributeRows", "insertTable", "insertShape", "setShapeFill", "setShapeOutline", "setShapeOutlineWidth", "alignFloatingObject", "reorderFloatingObject", "nudgeFloatingObject", "setFloatingFixedPosition", "setFloatingRotation", "setFloatingWrapPreset", "setFloatingWrapText", "setFloatingPositionPreset", "setShapePreset", "setTextBoxTextDirection", "setTextBoxVerticalAlign", "editTextBoxAlt", "rotateTextBox", "textBoxWidthCm", "textBoxHeightCm", "openSymbolDialog", "openEquationDialog", "tableProperties"];
|
|
2
2
|
export type OasisBuiltinCommand = (typeof OASIS_BUILTIN_COMMANDS)[number];
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { CommandRef } from './CommandRef.js';
|
|
2
|
-
import { EditorPageMargins, EditorPosition, EditorMathExpression, EditorPageBorder, EditorTabStop, EditorWatermark } from '../model.js';
|
|
2
|
+
import { EditorPageMargins, EditorPosition, EditorMathExpression, EditorUnderlineStyle, EditorPageBorder, EditorTabStop, EditorWatermark } from '../model.js';
|
|
3
3
|
import { SectionPageNumberFormat } from './pageNumber.js';
|
|
4
4
|
import { TextCaseMode } from './text.js';
|
|
5
5
|
import { TableBorderPreset, TableRowHeight } from './table.js';
|
|
@@ -167,6 +167,7 @@ export interface OasisCommandPayloads {
|
|
|
167
167
|
setStyleId: string;
|
|
168
168
|
setCharacterStyleId: string;
|
|
169
169
|
setUnderlineStyle: string | null;
|
|
170
|
+
applyUnderlineStyle: EditorUnderlineStyle | null;
|
|
170
171
|
setUnderlineColor: string | null;
|
|
171
172
|
setCharacterScale: number | null;
|
|
172
173
|
setCharacterSpacing: number | null;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { EditorState, EditorTextStyle } from '../model.js';
|
|
1
|
+
import { EditorState, EditorTextStyle, EditorUnderlineStyle } from '../model.js';
|
|
2
2
|
import { ToggleableTextStyleKey, ValueTextStyleKey } from '../textStyle/textStyleKeys.js';
|
|
3
3
|
export declare function toggleTextStyle(state: EditorState, key: ToggleableTextStyleKey): EditorState;
|
|
4
4
|
/**
|
|
@@ -6,6 +6,8 @@ export declare function toggleTextStyle(state: EditorState, key: ToggleableTextS
|
|
|
6
6
|
* text content, revisions, and links.
|
|
7
7
|
*/
|
|
8
8
|
export declare function clearSelectedTextFormatting(state: EditorState): EditorState;
|
|
9
|
+
/** Apply or remove underline and its variant in one selection mutation. */
|
|
10
|
+
export declare function applyUnderlineStyle(state: EditorState, style: EditorUnderlineStyle | null): EditorState;
|
|
9
11
|
export declare function setTextStyleValue<K extends ValueTextStyleKey>(state: EditorState, key: K, value: EditorTextStyle[K] | null): EditorState;
|
|
10
12
|
/**
|
|
11
13
|
* Nudge the font size of the selected runs by a fixed delta in points
|