@spteck/react-controls-v2 2.4.3 → 2.5.1
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/{LocalizationProvider-CvSHuk0e.js → LocalizationProvider-CBc0PcyH.js} +140 -48
- package/dist/LocalizationProvider-CJ2mjvH-.cjs +2 -0
- package/dist/{ar-BPzd6WER.js → ar-D78_ioot.js} +93 -1
- package/dist/{ar-CBSdRr5Q.cjs → ar-DbkaJtO2.cjs} +2 -2
- package/dist/{az-DoZjCfF0.cjs → az-Cf7y5UC1.cjs} +2 -2
- package/dist/{az-MWX-WDgc.js → az-OomGCL5f.js} +93 -1
- package/dist/{bg-CvRGS4sF.js → bg-OQDPULfM.js} +93 -1
- package/dist/{bg-DI8UD_HF.cjs → bg-nghgX11u.cjs} +2 -2
- package/dist/{bs-aXQgChJT.js → bs-BYdzDqQ_.js} +93 -1
- package/dist/{bs-DQhZlEEo.cjs → bs-CMdfvb33.cjs} +2 -2
- package/dist/{ca-BCXCXzgh.js → ca-9lGrM-T0.js} +93 -1
- package/dist/{ca-DSC32tOX.cjs → ca-C8cBXf9y.cjs} +2 -2
- package/dist/components/BackgroundImage/BackgroundImage.d.ts +4 -0
- package/dist/components/BackgroundImage/IBackgroundImageProps.d.ts +14 -0
- package/dist/components/BackgroundImage/index.d.ts +3 -0
- package/dist/components/BackgroundImage/useBackgroundImageStyles.d.ts +4 -0
- package/dist/components/Blockquote/Blockquote.d.ts +4 -0
- package/dist/components/Blockquote/IBlockquoteProps.d.ts +21 -0
- package/dist/components/Blockquote/index.d.ts +4 -0
- package/dist/components/Blockquote/useBlockquoteStyles.d.ts +6 -0
- package/dist/components/ColorPicker/ColorPicker.d.ts +51 -0
- package/dist/components/ColorPicker/ColorPickerAlpha.d.ts +4 -0
- package/dist/components/ColorPicker/ColorPickerBlock.d.ts +4 -0
- package/dist/components/ColorPicker/ColorPickerChrome.d.ts +4 -0
- package/dist/components/ColorPicker/ColorPickerCircle.d.ts +4 -0
- package/dist/components/ColorPicker/ColorPickerColorful.d.ts +4 -0
- package/dist/components/ColorPicker/ColorPickerCompact.d.ts +4 -0
- package/dist/components/ColorPicker/ColorPickerEditableInput.d.ts +4 -0
- package/dist/components/ColorPicker/ColorPickerEditableInputHSLA.d.ts +4 -0
- package/dist/components/ColorPicker/ColorPickerEditableInputRGBA.d.ts +4 -0
- package/dist/components/ColorPicker/ColorPickerHue.d.ts +4 -0
- package/dist/components/ColorPicker/ColorPickerInteractive.d.ts +6 -0
- package/dist/components/ColorPicker/ColorPickerSaturation.d.ts +4 -0
- package/dist/components/ColorPicker/ColorPickerShadeSlider.d.ts +4 -0
- package/dist/components/ColorPicker/ColorPickerSketch.d.ts +4 -0
- package/dist/components/ColorPicker/ColorPickerSlider.d.ts +4 -0
- package/dist/components/ColorPicker/ColorPickerSwatch.d.ts +4 -0
- package/dist/components/ColorPicker/ColorPickerTheme.d.ts +4 -0
- package/dist/components/ColorPicker/ColorPickerWheel.d.ts +4 -0
- package/dist/components/ColorPicker/IColorPickerProps.d.ts +297 -0
- package/dist/components/ColorPicker/colorConvert.d.ts +72 -0
- package/dist/components/ColorPicker/index.d.ts +25 -0
- package/dist/components/ColorPicker/useColorPickerStyles.d.ts +30 -0
- package/dist/components/CompactCalendar/CalendarGrid.d.ts +4 -0
- package/dist/components/CompactCalendar/CalendarHeader.d.ts +4 -0
- package/dist/components/CompactCalendar/CompactCalendar.d.ts +4 -0
- package/dist/components/CompactCalendar/EventsList.d.ts +4 -0
- package/dist/components/CompactCalendar/ICalendarGridProps.d.ts +32 -0
- package/dist/components/CompactCalendar/ICalendarHeaderProps.d.ts +15 -0
- package/dist/components/CompactCalendar/ICompactCalendarProps.d.ts +54 -0
- package/dist/components/CompactCalendar/IEventsListProps.d.ts +21 -0
- package/dist/components/CompactCalendar/index.d.ts +12 -0
- package/dist/components/CompactCalendar/resolveLocale.d.ts +12 -0
- package/dist/components/CompactCalendar/useCompactCalendarEvents.d.ts +12 -0
- package/dist/components/CompactCalendar/useCompactCalendarStyles.d.ts +26 -0
- package/dist/components/Dropzone/Dropzone.d.ts +31 -0
- package/dist/components/Dropzone/DropzoneContext.d.ts +20 -0
- package/dist/components/Dropzone/DropzoneFullScreen.d.ts +19 -0
- package/dist/components/Dropzone/DropzoneStatus.d.ts +9 -0
- package/dist/components/Dropzone/IDropzoneProps.d.ts +102 -0
- package/dist/components/Dropzone/index.d.ts +8 -0
- package/dist/components/Dropzone/mime-types.d.ts +39 -0
- package/dist/components/Dropzone/useDropzoneStyles.d.ts +12 -0
- package/dist/components/InlineSVG/IInlineSVGProps.d.ts +40 -0
- package/dist/components/InlineSVG/InlineSVG.d.ts +4 -0
- package/dist/components/InlineSVG/index.d.ts +5 -0
- package/dist/components/InlineSVG/useInlineSVG.d.ts +30 -0
- package/dist/components/InlineSVG/useInlineSVGStyles.d.ts +4 -0
- package/dist/components/Marquee/IMarqueeProps.d.ts +28 -0
- package/dist/components/Marquee/Marquee.d.ts +4 -0
- package/dist/components/Marquee/index.d.ts +4 -0
- package/dist/components/Marquee/useMarqueeStyles.d.ts +6 -0
- package/dist/components/OTPField/IOTPFieldProps.d.ts +49 -0
- package/dist/components/OTPField/OTPField.d.ts +8 -0
- package/dist/components/OTPField/index.d.ts +3 -0
- package/dist/components/OTPField/useOTPField.d.ts +25 -0
- package/dist/components/OTPField/useOTPFieldStyles.d.ts +23 -0
- package/dist/components/RichTextEditor/IRichTextEditorProps.d.ts +230 -0
- package/dist/components/RichTextEditor/Icons.d.ts +43 -0
- package/dist/components/RichTextEditor/RichTextEditor.d.ts +163 -0
- package/dist/components/RichTextEditor/RichTextEditorColorControl.d.ts +4 -0
- package/dist/components/RichTextEditor/RichTextEditorColorPickerControl.d.ts +4 -0
- package/dist/components/RichTextEditor/RichTextEditorContent.d.ts +4 -0
- package/dist/components/RichTextEditor/RichTextEditorContext.d.ts +20 -0
- package/dist/components/RichTextEditor/RichTextEditorControl.d.ts +22 -0
- package/dist/components/RichTextEditor/RichTextEditorControlsGroup.d.ts +4 -0
- package/dist/components/RichTextEditor/RichTextEditorFontFamilyControl.d.ts +4 -0
- package/dist/components/RichTextEditor/RichTextEditorLinkControl.d.ts +4 -0
- package/dist/components/RichTextEditor/RichTextEditorSourceCodeControl.d.ts +6 -0
- package/dist/components/RichTextEditor/RichTextEditorToolbar.d.ts +4 -0
- package/dist/components/RichTextEditor/controls.d.ts +125 -0
- package/dist/components/RichTextEditor/extensions.d.ts +12 -0
- package/dist/components/RichTextEditor/index.d.ts +15 -0
- package/dist/components/RichTextEditor/useRichTextEditorStyles.d.ts +28 -0
- package/dist/components/Skeleton/ISkeletonLoaderProps.d.ts +102 -0
- package/dist/components/Skeleton/SkeletonLoader.d.ts +4 -0
- package/dist/components/Skeleton/index.d.ts +5 -0
- package/dist/components/Skeleton/useSkeletonExtract.d.ts +4 -0
- package/dist/components/Skeleton/useSkeletonLoaderStyles.d.ts +11 -0
- package/dist/components/Skeleton/useSkeletonShared.d.ts +25 -0
- package/dist/components/Spoiler/ISpoilerProps.d.ts +30 -0
- package/dist/components/Spoiler/Spoiler.d.ts +4 -0
- package/dist/components/Spoiler/index.d.ts +3 -0
- package/dist/components/Spoiler/useSpoilerStyles.d.ts +13 -0
- package/dist/components/Spotlight/ISpotlightProps.d.ts +181 -0
- package/dist/components/Spotlight/Spotlight.d.ts +27 -0
- package/dist/components/Spotlight/SpotlightAction.d.ts +5 -0
- package/dist/components/Spotlight/SpotlightActionsGroup.d.ts +5 -0
- package/dist/components/Spotlight/SpotlightActionsList.d.ts +5 -0
- package/dist/components/Spotlight/SpotlightEmpty.d.ts +5 -0
- package/dist/components/Spotlight/SpotlightFooter.d.ts +5 -0
- package/dist/components/Spotlight/SpotlightRoot.d.ts +5 -0
- package/dist/components/Spotlight/SpotlightSearch.d.ts +5 -0
- package/dist/components/Spotlight/defaultSpotlightFilter.d.ts +9 -0
- package/dist/components/Spotlight/index.d.ts +12 -0
- package/dist/components/Spotlight/useSpotlight.d.ts +59 -0
- package/dist/components/Spotlight/useSpotlightStyles.d.ts +17 -0
- package/dist/components/Stepper/IStepperProps.d.ts +54 -0
- package/dist/components/Stepper/Stepper.d.ts +9 -0
- package/dist/components/Stepper/StepperCompleted.d.ts +9 -0
- package/dist/components/Stepper/StepperStep.d.ts +20 -0
- package/dist/components/Stepper/index.d.ts +3 -0
- package/dist/components/Stepper/useStepperStepStyles.d.ts +21 -0
- package/dist/components/Stepper/useStepperStyles.d.ts +11 -0
- package/dist/components/Timeline/ITimelineProps.d.ts +42 -0
- package/dist/components/Timeline/Timeline.d.ts +6 -0
- package/dist/components/Timeline/TimelineItem.d.ts +15 -0
- package/dist/components/Timeline/index.d.ts +3 -0
- package/dist/components/Timeline/useTimelineItemStyles.d.ts +19 -0
- package/dist/components/Timeline/useTimelineStyles.d.ts +9 -0
- package/dist/components/calendarControl/models/IAttendee.d.ts +5 -0
- package/dist/components/calendarControl/models/IEvents.d.ts +21 -0
- package/dist/{cs-B0C33FJt.cjs → cs-B_90ZpDL.cjs} +2 -2
- package/dist/{cs-VHWnqXwJ.js → cs-nVY__F1s.js} +93 -1
- package/dist/{cy-qF-aNCW-.js → cy-DcW2RMnM.js} +93 -1
- package/dist/{cy-BNabORao.cjs → cy-YdAkRgN7.cjs} +2 -2
- package/dist/{da-BmgXTEXm.cjs → da-3S6dCKx6.cjs} +2 -2
- package/dist/{da-rR5TnSBw.js → da-DlZaxKzd.js} +93 -1
- package/dist/{de-DbeDjRNp.js → de-DMQCCsxB.js} +93 -1
- package/dist/{de-B4w38-0d.cjs → de-cBD6cQjC.cjs} +2 -2
- package/dist/{el-Cgk6VsxL.cjs → el-C861pBjb.cjs} +2 -2
- package/dist/{el-DDeD6FiX.js → el-DWGl8fc0.js} +93 -1
- package/dist/{es-dvKffn6Q.js → es--B6susjn.js} +93 -1
- package/dist/{es-3ugMIZuA.cjs → es-7wJEQTAK.cjs} +2 -2
- package/dist/{et-CIIzxbat.cjs → et-BDQwGJeu.cjs} +2 -2
- package/dist/{et-DgZFBtK7.js → et-CNiq2LnL.js} +93 -1
- package/dist/{eu-C6r1_PRy.js → eu-B4UCvLGV.js} +93 -1
- package/dist/{eu-BUNUOJ7E.cjs → eu-Bis1mMYp.cjs} +2 -2
- package/dist/{fi-q6BFPHtt.cjs → fi-Bish9bFy.cjs} +2 -2
- package/dist/{fi-CzOKgmjK.js → fi-C1YgTvJp.js} +93 -1
- package/dist/{fr-D0cDkdbn.js → fr-Dn0f3XKj.js} +93 -1
- package/dist/{fr-BEnCZ733.cjs → fr-mNj_7F7p.cjs} +2 -2
- package/dist/{ga-BXyKTnJr.cjs → ga-DHGpUClX.cjs} +2 -2
- package/dist/{ga-0A7ndSzw.js → ga-lrKtfvqw.js} +93 -1
- package/dist/{gl-DR1C-hSi.cjs → gl-BaGwE_dH.cjs} +2 -2
- package/dist/{gl-BNwj4XAu.js → gl-Bcp6x2zx.js} +93 -1
- package/dist/{he-BPiZ6D5h.js → he-6cRlkGst.js} +93 -1
- package/dist/{he-OD1Ex2Fw.cjs → he-CyBuj0mX.cjs} +2 -2
- package/dist/{hi-Dt9FvBmh.cjs → hi-C9Y--qfd.cjs} +2 -2
- package/dist/{hi-CSgtp9Yg.js → hi-sWnw2IKq.js} +93 -1
- package/dist/hooks/useLocalizationStrings.d.ts +10 -0
- package/dist/{hr-CDSSj52Q.js → hr-DVYuTFrR.js} +93 -1
- package/dist/{hr-DMzwNhar.cjs → hr-_DB2jbdD.cjs} +2 -2
- package/dist/{hu-Bc-rChfV.cjs → hu-B6P_13vr.cjs} +2 -2
- package/dist/{hu-TDJYiDOB.js → hu-Ds35ELag.js} +93 -1
- package/dist/{id-CwndN9HH.cjs → id-CD6_OeAS.cjs} +2 -2
- package/dist/{id-B3IF5pnh.js → id-D3-zrJWX.js} +93 -1
- package/dist/index.cjs +48 -33
- package/dist/index.d.ts +14 -0
- package/dist/index.js +10631 -4137
- package/dist/{it-BLET318M.js → it-7v9Dp1d5.js} +93 -1
- package/dist/{it-DaYS5Vil.cjs → it-BqWJuJRG.cjs} +2 -2
- package/dist/{ja-NxwXLaKV.js → ja-HEhZtJlu.js} +93 -1
- package/dist/{ja-BYA2LXHy.cjs → ja-_IB67CHC.cjs} +2 -2
- package/dist/{kk-Ctrvuqlz.cjs → kk-1zP-M5hA.cjs} +2 -2
- package/dist/{kk-CceJcjtl.js → kk-vjMXRcfC.js} +93 -1
- package/dist/{ko-evIcpTG8.cjs → ko-Bh_npcwe.cjs} +2 -2
- package/dist/{ko-cS_OE967.js → ko-k4Pa7puV.js} +93 -1
- package/dist/localization/ILibraryStrings.d.ts +132 -0
- package/dist/localization/index.d.ts +2 -2
- package/dist/{lt-CYTLGgh6.cjs → lt-Bcs_RvUC.cjs} +2 -2
- package/dist/{lt-CZ-kk_5b.js → lt-DiJ0TBtG.js} +93 -1
- package/dist/{lv-COjitD3w.cjs → lv-DXbttzfD.cjs} +2 -2
- package/dist/{lv-BTvPpEjc.js → lv-Dsam0ieq.js} +93 -1
- package/dist/{mk-CSSyI3El.js → mk-6gVlhUMj.js} +93 -1
- package/dist/{mk-B-LF5gVL.cjs → mk-CwexdV8N.cjs} +2 -2
- package/dist/{ms-CzEvkib0.cjs → ms-DbohV4fa.cjs} +2 -2
- package/dist/{ms-Dz5JnKJ1.js → ms-LR8UEBWu.js} +93 -1
- package/dist/{nb-DkgTg1et.js → nb-BCuhLUFv.js} +93 -1
- package/dist/{nb-B1KWSX94.cjs → nb-XSnogBcy.cjs} +2 -2
- package/dist/{nl-knWqo2aX.cjs → nl-C3fB4nMe.cjs} +2 -2
- package/dist/{nl-CQ5eoxw2.js → nl-Cjbk_uDE.js} +93 -1
- package/dist/{pl-BQJfOizT.js → pl-3SZu8o4v.js} +93 -1
- package/dist/{pl-Ce6dq53t.cjs → pl-BJHabrpe.cjs} +2 -2
- package/dist/providers.cjs +1 -1
- package/dist/providers.js +1 -1
- package/dist/{pt-b0p7DoD0.js → pt-BRvCnjwa.js} +93 -1
- package/dist/{pt-BVqTnGkF.cjs → pt-BqRRasV7.cjs} +2 -2
- package/dist/{ro-sbBtUVJV.js → ro-B051tdWj.js} +93 -1
- package/dist/{ro-DqJMfhmX.cjs → ro-BCq9yIk8.cjs} +2 -2
- package/dist/{ru-Dm2NAQyK.cjs → ru-B-TiRA2D.cjs} +2 -2
- package/dist/{ru-ofzbka6D.js → ru-wGNmtZwA.js} +93 -1
- package/dist/{sk-BtpdNCPC.js → sk-BEUsTaCT.js} +93 -1
- package/dist/{sk-BNe6CHG-.cjs → sk-Btf7EoeH.cjs} +2 -2
- package/dist/{sl-BKmEUGyu.cjs → sl-Cs0S-Rru.cjs} +2 -2
- package/dist/{sl-B4GsKLu6.js → sl-Dt-Wix4R.js} +93 -1
- package/dist/{sr-C76YVpkQ.js → sr-Cj6FjoPV.js} +93 -1
- package/dist/{sr-Dwya5lwF.cjs → sr-Jxn52mZC.cjs} +2 -2
- package/dist/{sv-PesX57cX.js → sv-C5PBTvZZ.js} +93 -1
- package/dist/{sv-BGL2G9Vm.cjs → sv-DqwVwzYH.cjs} +2 -2
- package/dist/{th-DEv6shFI.cjs → th-CnqYsyp5.cjs} +2 -2
- package/dist/{th-CbCNOBnR.js → th-DEMLnNto.js} +93 -1
- package/dist/{tr-B0TPxXKS.js → tr-7wlGJ97W.js} +93 -1
- package/dist/{tr-BB-QonGE.cjs → tr-BiSE3U_v.cjs} +2 -2
- package/dist/{uk-_9cNoBNe.js → uk-B2JY5Ka3.js} +93 -1
- package/dist/{uk-B-3fLKpR.cjs → uk-YsR97h-O.cjs} +2 -2
- package/dist/{vi-Dx6pJ0ir.cjs → vi-BqlBS0CX.cjs} +2 -2
- package/dist/{vi-B8SfqLW6.js → vi-By1JUTa6.js} +93 -1
- package/dist/{zh-DD0ml2HG.cjs → zh-C3amwoRq.cjs} +2 -2
- package/dist/{zh-DqHnbp6B.js → zh-SZ0W4ZGV.js} +93 -1
- package/package.json +20 -1
- package/dist/LocalizationProvider-BbfcY9z3.cjs +0 -2
|
@@ -0,0 +1,230 @@
|
|
|
1
|
+
import { Editor } from '@tiptap/react';
|
|
2
|
+
import { IBaseProps } from '../baseComponentProps/IBaseProps';
|
|
3
|
+
/**
|
|
4
|
+
* Visual variant of the RichTextEditor
|
|
5
|
+
*/
|
|
6
|
+
export type RichTextEditorVariant = 'default' | 'subtle';
|
|
7
|
+
/**
|
|
8
|
+
* Labels for all RichTextEditor controls (used for aria-label and title attributes)
|
|
9
|
+
*/
|
|
10
|
+
export interface IRichTextEditorLabels {
|
|
11
|
+
boldControlLabel: string;
|
|
12
|
+
hrControlLabel: string;
|
|
13
|
+
italicControlLabel: string;
|
|
14
|
+
underlineControlLabel: string;
|
|
15
|
+
strikeControlLabel: string;
|
|
16
|
+
clearFormattingControlLabel: string;
|
|
17
|
+
linkControlLabel: string;
|
|
18
|
+
unlinkControlLabel: string;
|
|
19
|
+
bulletListControlLabel: string;
|
|
20
|
+
orderedListControlLabel: string;
|
|
21
|
+
h1ControlLabel: string;
|
|
22
|
+
h2ControlLabel: string;
|
|
23
|
+
h3ControlLabel: string;
|
|
24
|
+
h4ControlLabel: string;
|
|
25
|
+
h5ControlLabel: string;
|
|
26
|
+
h6ControlLabel: string;
|
|
27
|
+
blockquoteControlLabel: string;
|
|
28
|
+
alignLeftControlLabel: string;
|
|
29
|
+
alignCenterControlLabel: string;
|
|
30
|
+
alignRightControlLabel: string;
|
|
31
|
+
alignJustifyControlLabel: string;
|
|
32
|
+
codeControlLabel: string;
|
|
33
|
+
codeBlockControlLabel: string;
|
|
34
|
+
subscriptControlLabel: string;
|
|
35
|
+
superscriptControlLabel: string;
|
|
36
|
+
colorPickerControlLabel: string;
|
|
37
|
+
unsetColorControlLabel: string;
|
|
38
|
+
highlightControlLabel: string;
|
|
39
|
+
undoControlLabel: string;
|
|
40
|
+
redoControlLabel: string;
|
|
41
|
+
colorControlLabel: (color: string) => string;
|
|
42
|
+
sourceCodeControlLabel: string;
|
|
43
|
+
linkEditorInputLabel: string;
|
|
44
|
+
linkEditorInputPlaceholder: string;
|
|
45
|
+
linkEditorExternalLink: string;
|
|
46
|
+
linkEditorInternalLink: string;
|
|
47
|
+
linkEditorSave: string;
|
|
48
|
+
colorPickerCancel: string;
|
|
49
|
+
colorPickerClear: string;
|
|
50
|
+
colorPickerColorPicker: string;
|
|
51
|
+
colorPickerPalette: string;
|
|
52
|
+
colorPickerSave: string;
|
|
53
|
+
colorPickerColorLabel: (color: string) => string;
|
|
54
|
+
tasksControlLabel: string;
|
|
55
|
+
tasksSinkLabel: string;
|
|
56
|
+
tasksLiftLabel: string;
|
|
57
|
+
fontFamilyControlLabel: string;
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* Props for the main RichTextEditor component
|
|
61
|
+
*/
|
|
62
|
+
export interface IRichTextEditorProps extends IBaseProps {
|
|
63
|
+
/** Tiptap editor instance */
|
|
64
|
+
editor: Editor | null;
|
|
65
|
+
/** Whether code highlight styles should be added @default true */
|
|
66
|
+
withCodeHighlightStyles?: boolean;
|
|
67
|
+
/** Whether typography styles should be added @default true */
|
|
68
|
+
withTypographyStyles?: boolean;
|
|
69
|
+
/** Labels overrides for controls */
|
|
70
|
+
labels?: Partial<IRichTextEditorLabels>;
|
|
71
|
+
/** Visual variant @default 'default' */
|
|
72
|
+
variant?: RichTextEditorVariant;
|
|
73
|
+
/** Called when source code toggle is clicked */
|
|
74
|
+
onSourceCodeTextSwitch?: (isSourceCodeModeActive: boolean) => void;
|
|
75
|
+
/** Called when editor content changes — receives HTML string and JSON content */
|
|
76
|
+
onContentChange?: (html: string, json: Record<string, unknown>) => void;
|
|
77
|
+
/** Called when editor gains focus */
|
|
78
|
+
onFocus?: (event: FocusEvent) => void;
|
|
79
|
+
/** Called when editor loses focus */
|
|
80
|
+
onBlur?: (event: FocusEvent) => void;
|
|
81
|
+
/** Called when the editor is first created */
|
|
82
|
+
onCreate?: () => void;
|
|
83
|
+
/** Called when the text selection changes */
|
|
84
|
+
onSelectionChange?: () => void;
|
|
85
|
+
/** Font family applied to the editor content area.
|
|
86
|
+
* Accepts any CSS font-family value — works with `useBrandCenterFonts().defaultFont?.name`
|
|
87
|
+
* or a plain string like `'Inter, sans-serif'`. */
|
|
88
|
+
fontFamily?: string;
|
|
89
|
+
/** Font families available in the FontFamily toolbar picker.
|
|
90
|
+
* Typically populated from `useBrandCenterFonts().fontFamilyNames`. */
|
|
91
|
+
fontFamilies?: string[];
|
|
92
|
+
/** Child editor components */
|
|
93
|
+
children: React.ReactNode;
|
|
94
|
+
/** Additional className */
|
|
95
|
+
className?: string;
|
|
96
|
+
/** Inline styles */
|
|
97
|
+
style?: React.CSSProperties;
|
|
98
|
+
}
|
|
99
|
+
/**
|
|
100
|
+
* Props for the RichTextEditor.Toolbar component
|
|
101
|
+
*/
|
|
102
|
+
export interface IRichTextEditorToolbarProps {
|
|
103
|
+
/** Whether to use sticky positioning @default false */
|
|
104
|
+
sticky?: boolean;
|
|
105
|
+
/** Top offset when sticky @default 0 */
|
|
106
|
+
stickyOffset?: React.CSSProperties['top'];
|
|
107
|
+
/** Children (controls and control groups) */
|
|
108
|
+
children: React.ReactNode;
|
|
109
|
+
/** Additional className */
|
|
110
|
+
className?: string;
|
|
111
|
+
/** Inline styles */
|
|
112
|
+
style?: React.CSSProperties;
|
|
113
|
+
}
|
|
114
|
+
/**
|
|
115
|
+
* Props for the RichTextEditor.ControlsGroup component
|
|
116
|
+
*/
|
|
117
|
+
export interface IRichTextEditorControlsGroupProps {
|
|
118
|
+
/** Children (controls) */
|
|
119
|
+
children: React.ReactNode;
|
|
120
|
+
/** Additional className */
|
|
121
|
+
className?: string;
|
|
122
|
+
/** Inline styles */
|
|
123
|
+
style?: React.CSSProperties;
|
|
124
|
+
}
|
|
125
|
+
/**
|
|
126
|
+
* Props for the RichTextEditor.Control base component
|
|
127
|
+
*/
|
|
128
|
+
export interface IRichTextEditorControlProps {
|
|
129
|
+
/** Whether the control is active @default false */
|
|
130
|
+
active?: boolean;
|
|
131
|
+
/** Whether the control can be interacted with @default true */
|
|
132
|
+
interactive?: boolean;
|
|
133
|
+
/** Whether the control is disabled */
|
|
134
|
+
disabled?: boolean;
|
|
135
|
+
/** Click handler */
|
|
136
|
+
onClick?: (event: React.MouseEvent<HTMLButtonElement>) => void;
|
|
137
|
+
/** Mouse down handler */
|
|
138
|
+
onMouseDown?: (event: React.MouseEvent<HTMLButtonElement>) => void;
|
|
139
|
+
/** Aria label */
|
|
140
|
+
'aria-label'?: string;
|
|
141
|
+
/** Title tooltip text */
|
|
142
|
+
title?: string;
|
|
143
|
+
/** Children */
|
|
144
|
+
children?: React.ReactNode;
|
|
145
|
+
/** Additional className */
|
|
146
|
+
className?: string;
|
|
147
|
+
/** Inline styles */
|
|
148
|
+
style?: React.CSSProperties;
|
|
149
|
+
}
|
|
150
|
+
/**
|
|
151
|
+
* Props for control with icon
|
|
152
|
+
*/
|
|
153
|
+
export interface IRichTextEditorControlBaseProps extends IRichTextEditorControlProps {
|
|
154
|
+
/** Icon component */
|
|
155
|
+
icon?: React.FC<{
|
|
156
|
+
style: React.CSSProperties;
|
|
157
|
+
}>;
|
|
158
|
+
}
|
|
159
|
+
/**
|
|
160
|
+
* Props for the RichTextEditor.Content component
|
|
161
|
+
*/
|
|
162
|
+
export interface IRichTextEditorContentProps {
|
|
163
|
+
/** Additional className */
|
|
164
|
+
className?: string;
|
|
165
|
+
/** Inline styles */
|
|
166
|
+
style?: React.CSSProperties;
|
|
167
|
+
}
|
|
168
|
+
/**
|
|
169
|
+
* Props for the RichTextEditor.Link control
|
|
170
|
+
*/
|
|
171
|
+
export interface IRichTextEditorLinkControlProps extends Omit<IRichTextEditorControlBaseProps, 'onClick'> {
|
|
172
|
+
/** Whether external link tooltip should be disabled @default false */
|
|
173
|
+
disableTooltips?: boolean;
|
|
174
|
+
/** Initial state for whether the link should open externally @default false */
|
|
175
|
+
initialExternal?: boolean;
|
|
176
|
+
}
|
|
177
|
+
/**
|
|
178
|
+
* Props for the RichTextEditor.Color control
|
|
179
|
+
*/
|
|
180
|
+
export interface IRichTextEditorColorControlProps {
|
|
181
|
+
/** Color value (e.g. '#ef457e') */
|
|
182
|
+
color: string;
|
|
183
|
+
/** Additional className */
|
|
184
|
+
className?: string;
|
|
185
|
+
/** Inline styles */
|
|
186
|
+
style?: React.CSSProperties;
|
|
187
|
+
}
|
|
188
|
+
/**
|
|
189
|
+
* Props for the RichTextEditor.ColorPicker control
|
|
190
|
+
*/
|
|
191
|
+
export interface IRichTextEditorColorPickerControlProps {
|
|
192
|
+
/** List of colors for the palette */
|
|
193
|
+
colors: string[];
|
|
194
|
+
/** Additional className */
|
|
195
|
+
className?: string;
|
|
196
|
+
/** Inline styles */
|
|
197
|
+
style?: React.CSSProperties;
|
|
198
|
+
}
|
|
199
|
+
/**
|
|
200
|
+
* Configuration for the createControl factory
|
|
201
|
+
*/
|
|
202
|
+
export interface ICreateControlProps {
|
|
203
|
+
label: keyof IRichTextEditorLabels;
|
|
204
|
+
icon: React.FC<{
|
|
205
|
+
style: React.CSSProperties;
|
|
206
|
+
}>;
|
|
207
|
+
isActive?: {
|
|
208
|
+
name: string;
|
|
209
|
+
attributes?: Record<string, unknown> | string;
|
|
210
|
+
};
|
|
211
|
+
isDisabled?: (editor: Editor | null) => boolean;
|
|
212
|
+
operation: {
|
|
213
|
+
name: string;
|
|
214
|
+
attributes?: Record<string, unknown> | string;
|
|
215
|
+
};
|
|
216
|
+
}
|
|
217
|
+
/**
|
|
218
|
+
* Props for the RichTextEditor.FontFamily control
|
|
219
|
+
*/
|
|
220
|
+
export interface IRichTextEditorFontFamilyControlProps {
|
|
221
|
+
/** List of font family names to display in the picker.
|
|
222
|
+
* When omitted, the control reads fonts from context
|
|
223
|
+
* (see `fontFamilies` on IRichTextEditorProps). */
|
|
224
|
+
fontFamilies?: string[];
|
|
225
|
+
/** Additional className */
|
|
226
|
+
className?: string;
|
|
227
|
+
/** Inline styles */
|
|
228
|
+
style?: React.CSSProperties;
|
|
229
|
+
}
|
|
230
|
+
//# sourceMappingURL=IRichTextEditorProps.d.ts.map
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
interface IconProps extends React.ComponentProps<'svg'> {
|
|
3
|
+
}
|
|
4
|
+
export declare function IconBold(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
export declare function IconItalic(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
export declare function IconUnderline(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export declare function IconStrikethrough(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export declare function IconClearFormatting(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export declare function IconH1(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
export declare function IconH2(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export declare function IconH3(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
export declare function IconH4(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
export declare function IconH5(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
14
|
+
export declare function IconH6(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
15
|
+
export declare function IconList(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
16
|
+
export declare function IconListNumbers(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
export declare function IconUnlink(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
18
|
+
export declare function IconBlockquote(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
export declare function IconAlignLeft(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
20
|
+
export declare function IconAlignRight(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
21
|
+
export declare function IconAlignCenter(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
22
|
+
export declare function IconAlignJustified(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
23
|
+
export declare function IconSubscript(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
24
|
+
export declare function IconSuperscript(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
25
|
+
export declare function IconCode(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
26
|
+
export declare function IconHighlight(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
27
|
+
export declare function IconLineDashed(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
28
|
+
export declare function IconCircleOff(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
29
|
+
export declare function IconColorPicker(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
30
|
+
export declare function IconX(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
31
|
+
export declare function IconPalette(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
32
|
+
export declare function IconCheck(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
33
|
+
export declare function IconLink(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
34
|
+
export declare function IconExternalLink(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
35
|
+
export declare function IconArrowBackUp(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
36
|
+
export declare function IconArrowForwardUp(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
37
|
+
export declare function IconListCheck(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
38
|
+
export declare function IconIndentIncrease(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
39
|
+
export declare function IconIndentDecrease(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
40
|
+
export declare function IconBraces(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
41
|
+
export declare function IconTypography(props: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
42
|
+
export {};
|
|
43
|
+
//# sourceMappingURL=Icons.d.ts.map
|
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
import { IRichTextEditorProps } from './IRichTextEditorProps';
|
|
2
|
+
import * as React from "react";
|
|
3
|
+
/**
|
|
4
|
+
* Fluent UI 9 RichTextEditor — a wrapper around TipTap with toolbar controls,
|
|
5
|
+
* link editing, color picking, and full localization support.
|
|
6
|
+
*
|
|
7
|
+
* Uses the compound component pattern with static sub-components:
|
|
8
|
+
* ```
|
|
9
|
+
* <RichTextEditor editor={editor}>
|
|
10
|
+
* <RichTextEditor.Toolbar>
|
|
11
|
+
* <RichTextEditor.ControlsGroup>
|
|
12
|
+
* <RichTextEditor.Bold />
|
|
13
|
+
* <RichTextEditor.Italic />
|
|
14
|
+
* </RichTextEditor.ControlsGroup>
|
|
15
|
+
* </RichTextEditor.Toolbar>
|
|
16
|
+
* <RichTextEditor.Content />
|
|
17
|
+
* </RichTextEditor>
|
|
18
|
+
* ```
|
|
19
|
+
*/
|
|
20
|
+
export declare const RichTextEditor: React.FC<IRichTextEditorProps> & {
|
|
21
|
+
Toolbar: React.FC<import('./IRichTextEditorProps').IRichTextEditorToolbarProps>;
|
|
22
|
+
Content: React.FC<import('./IRichTextEditorProps').IRichTextEditorContentProps>;
|
|
23
|
+
ControlsGroup: React.FC<import('./IRichTextEditorProps').IRichTextEditorControlsGroupProps>;
|
|
24
|
+
Control: React.ForwardRefExoticComponent<import('./IRichTextEditorProps').IRichTextEditorControlProps & React.RefAttributes<HTMLButtonElement>>;
|
|
25
|
+
ControlBase: React.ForwardRefExoticComponent<import('./IRichTextEditorProps').IRichTextEditorControlBaseProps & {
|
|
26
|
+
icon: React.FC<{
|
|
27
|
+
style: React.CSSProperties;
|
|
28
|
+
}>;
|
|
29
|
+
} & React.RefAttributes<HTMLButtonElement>>;
|
|
30
|
+
Bold: {
|
|
31
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
32
|
+
displayName: string;
|
|
33
|
+
};
|
|
34
|
+
Italic: {
|
|
35
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
36
|
+
displayName: string;
|
|
37
|
+
};
|
|
38
|
+
Underline: {
|
|
39
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
40
|
+
displayName: string;
|
|
41
|
+
};
|
|
42
|
+
Strikethrough: {
|
|
43
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
44
|
+
displayName: string;
|
|
45
|
+
};
|
|
46
|
+
ClearFormatting: {
|
|
47
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
48
|
+
displayName: string;
|
|
49
|
+
};
|
|
50
|
+
H1: {
|
|
51
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
52
|
+
displayName: string;
|
|
53
|
+
};
|
|
54
|
+
H2: {
|
|
55
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
56
|
+
displayName: string;
|
|
57
|
+
};
|
|
58
|
+
H3: {
|
|
59
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
60
|
+
displayName: string;
|
|
61
|
+
};
|
|
62
|
+
H4: {
|
|
63
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
64
|
+
displayName: string;
|
|
65
|
+
};
|
|
66
|
+
H5: {
|
|
67
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
68
|
+
displayName: string;
|
|
69
|
+
};
|
|
70
|
+
H6: {
|
|
71
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
72
|
+
displayName: string;
|
|
73
|
+
};
|
|
74
|
+
BulletList: {
|
|
75
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
76
|
+
displayName: string;
|
|
77
|
+
};
|
|
78
|
+
OrderedList: {
|
|
79
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
80
|
+
displayName: string;
|
|
81
|
+
};
|
|
82
|
+
Blockquote: {
|
|
83
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
84
|
+
displayName: string;
|
|
85
|
+
};
|
|
86
|
+
Link: React.FC<import('./IRichTextEditorProps').IRichTextEditorLinkControlProps>;
|
|
87
|
+
Unlink: {
|
|
88
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
89
|
+
displayName: string;
|
|
90
|
+
};
|
|
91
|
+
AlignLeft: {
|
|
92
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
93
|
+
displayName: string;
|
|
94
|
+
};
|
|
95
|
+
AlignRight: {
|
|
96
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
97
|
+
displayName: string;
|
|
98
|
+
};
|
|
99
|
+
AlignCenter: {
|
|
100
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
101
|
+
displayName: string;
|
|
102
|
+
};
|
|
103
|
+
AlignJustify: {
|
|
104
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
105
|
+
displayName: string;
|
|
106
|
+
};
|
|
107
|
+
Code: {
|
|
108
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
109
|
+
displayName: string;
|
|
110
|
+
};
|
|
111
|
+
CodeBlock: {
|
|
112
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
113
|
+
displayName: string;
|
|
114
|
+
};
|
|
115
|
+
Subscript: {
|
|
116
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
117
|
+
displayName: string;
|
|
118
|
+
};
|
|
119
|
+
Superscript: {
|
|
120
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
121
|
+
displayName: string;
|
|
122
|
+
};
|
|
123
|
+
Color: React.FC<import('./IRichTextEditorProps').IRichTextEditorColorControlProps>;
|
|
124
|
+
ColorPicker: React.FC<import('./IRichTextEditorProps').IRichTextEditorColorPickerControlProps>;
|
|
125
|
+
Highlight: {
|
|
126
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
127
|
+
displayName: string;
|
|
128
|
+
};
|
|
129
|
+
UnsetColor: {
|
|
130
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
131
|
+
displayName: string;
|
|
132
|
+
};
|
|
133
|
+
Hr: {
|
|
134
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
135
|
+
displayName: string;
|
|
136
|
+
};
|
|
137
|
+
Undo: {
|
|
138
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
139
|
+
displayName: string;
|
|
140
|
+
};
|
|
141
|
+
Redo: {
|
|
142
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
143
|
+
displayName: string;
|
|
144
|
+
};
|
|
145
|
+
TaskList: {
|
|
146
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
147
|
+
displayName: string;
|
|
148
|
+
};
|
|
149
|
+
TaskListSink: {
|
|
150
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
151
|
+
displayName: string;
|
|
152
|
+
};
|
|
153
|
+
TaskListLift: {
|
|
154
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
155
|
+
displayName: string;
|
|
156
|
+
};
|
|
157
|
+
SourceCode: React.FC<{
|
|
158
|
+
className?: string;
|
|
159
|
+
style?: React.CSSProperties;
|
|
160
|
+
}>;
|
|
161
|
+
FontFamily: React.FC<import('./IRichTextEditorProps').IRichTextEditorFontFamilyControlProps>;
|
|
162
|
+
};
|
|
163
|
+
//# sourceMappingURL=RichTextEditor.d.ts.map
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { IRichTextEditorColorPickerControlProps } from './IRichTextEditorProps';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
export declare const RichTextEditorColorPickerControl: React.FC<IRichTextEditorColorPickerControlProps>;
|
|
4
|
+
//# sourceMappingURL=RichTextEditorColorPickerControl.d.ts.map
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { Editor } from '@tiptap/react';
|
|
2
|
+
import { IRichTextEditorLabels, RichTextEditorVariant } from './IRichTextEditorProps';
|
|
3
|
+
export interface IRichTextEditorContextValue {
|
|
4
|
+
editor: Editor | null;
|
|
5
|
+
labels: IRichTextEditorLabels;
|
|
6
|
+
withCodeHighlightStyles: boolean;
|
|
7
|
+
withTypographyStyles: boolean;
|
|
8
|
+
variant: RichTextEditorVariant;
|
|
9
|
+
onSourceCodeTextSwitch?: (isSourceCodeModeActive: boolean) => void;
|
|
10
|
+
onContentChange?: (html: string, json: Record<string, unknown>) => void;
|
|
11
|
+
onFocus?: (event: FocusEvent) => void;
|
|
12
|
+
onBlur?: (event: FocusEvent) => void;
|
|
13
|
+
onCreate?: () => void;
|
|
14
|
+
onSelectionChange?: () => void;
|
|
15
|
+
fontFamily?: string;
|
|
16
|
+
fontFamilies?: string[];
|
|
17
|
+
}
|
|
18
|
+
export declare const RichTextEditorProvider: import('react').Provider<IRichTextEditorContextValue | null>;
|
|
19
|
+
export declare function useRichTextEditorContext(): IRichTextEditorContextValue;
|
|
20
|
+
//# sourceMappingURL=RichTextEditorContext.d.ts.map
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { IRichTextEditorControlProps, IRichTextEditorControlBaseProps, ICreateControlProps } from './IRichTextEditorProps';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
/**
|
|
4
|
+
* Base control button for the RichTextEditor toolbar.
|
|
5
|
+
*/
|
|
6
|
+
export declare const RichTextEditorControl: React.ForwardRefExoticComponent<IRichTextEditorControlProps & React.RefAttributes<HTMLButtonElement>>;
|
|
7
|
+
/**
|
|
8
|
+
* Control button with an icon.
|
|
9
|
+
*/
|
|
10
|
+
export declare const RichTextEditorControlBase: React.ForwardRefExoticComponent<IRichTextEditorControlBaseProps & {
|
|
11
|
+
icon: React.FC<{
|
|
12
|
+
style: React.CSSProperties;
|
|
13
|
+
}>;
|
|
14
|
+
} & React.RefAttributes<HTMLButtonElement>>;
|
|
15
|
+
/**
|
|
16
|
+
* Factory function to create a toolbar control with a specific editor operation.
|
|
17
|
+
*/
|
|
18
|
+
export declare function createControl({ label, isActive, operation, icon, isDisabled, }: ICreateControlProps): {
|
|
19
|
+
(props: IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
20
|
+
displayName: string;
|
|
21
|
+
};
|
|
22
|
+
//# sourceMappingURL=RichTextEditorControl.d.ts.map
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { IRichTextEditorFontFamilyControlProps } from './IRichTextEditorProps';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
export declare const RichTextEditorFontFamilyControl: React.FC<IRichTextEditorFontFamilyControlProps>;
|
|
4
|
+
//# sourceMappingURL=RichTextEditorFontFamilyControl.d.ts.map
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
export declare const BoldControl: {
|
|
2
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
displayName: string;
|
|
4
|
+
};
|
|
5
|
+
export declare const ItalicControl: {
|
|
6
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
displayName: string;
|
|
8
|
+
};
|
|
9
|
+
export declare const UnderlineControl: {
|
|
10
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
displayName: string;
|
|
12
|
+
};
|
|
13
|
+
export declare const StrikeThroughControl: {
|
|
14
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
15
|
+
displayName: string;
|
|
16
|
+
};
|
|
17
|
+
export declare const ClearFormattingControl: {
|
|
18
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
displayName: string;
|
|
20
|
+
};
|
|
21
|
+
export declare const UnlinkControl: {
|
|
22
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
23
|
+
displayName: string;
|
|
24
|
+
};
|
|
25
|
+
export declare const BulletListControl: {
|
|
26
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
27
|
+
displayName: string;
|
|
28
|
+
};
|
|
29
|
+
export declare const OrderedListControl: {
|
|
30
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
31
|
+
displayName: string;
|
|
32
|
+
};
|
|
33
|
+
export declare const H1Control: {
|
|
34
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
35
|
+
displayName: string;
|
|
36
|
+
};
|
|
37
|
+
export declare const H2Control: {
|
|
38
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
39
|
+
displayName: string;
|
|
40
|
+
};
|
|
41
|
+
export declare const H3Control: {
|
|
42
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
43
|
+
displayName: string;
|
|
44
|
+
};
|
|
45
|
+
export declare const H4Control: {
|
|
46
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
47
|
+
displayName: string;
|
|
48
|
+
};
|
|
49
|
+
export declare const H5Control: {
|
|
50
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
51
|
+
displayName: string;
|
|
52
|
+
};
|
|
53
|
+
export declare const H6Control: {
|
|
54
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
55
|
+
displayName: string;
|
|
56
|
+
};
|
|
57
|
+
export declare const BlockquoteControl: {
|
|
58
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
59
|
+
displayName: string;
|
|
60
|
+
};
|
|
61
|
+
export declare const AlignLeftControl: {
|
|
62
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
63
|
+
displayName: string;
|
|
64
|
+
};
|
|
65
|
+
export declare const AlignRightControl: {
|
|
66
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
67
|
+
displayName: string;
|
|
68
|
+
};
|
|
69
|
+
export declare const AlignCenterControl: {
|
|
70
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
71
|
+
displayName: string;
|
|
72
|
+
};
|
|
73
|
+
export declare const AlignJustifyControl: {
|
|
74
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
75
|
+
displayName: string;
|
|
76
|
+
};
|
|
77
|
+
export declare const SubscriptControl: {
|
|
78
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
79
|
+
displayName: string;
|
|
80
|
+
};
|
|
81
|
+
export declare const SuperscriptControl: {
|
|
82
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
83
|
+
displayName: string;
|
|
84
|
+
};
|
|
85
|
+
export declare const CodeControl: {
|
|
86
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
87
|
+
displayName: string;
|
|
88
|
+
};
|
|
89
|
+
export declare const CodeBlockControl: {
|
|
90
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
91
|
+
displayName: string;
|
|
92
|
+
};
|
|
93
|
+
export declare const HighlightControl: {
|
|
94
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
95
|
+
displayName: string;
|
|
96
|
+
};
|
|
97
|
+
export declare const HrControl: {
|
|
98
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
99
|
+
displayName: string;
|
|
100
|
+
};
|
|
101
|
+
export declare const UnsetColorControl: {
|
|
102
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
103
|
+
displayName: string;
|
|
104
|
+
};
|
|
105
|
+
export declare const UndoControl: {
|
|
106
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
107
|
+
displayName: string;
|
|
108
|
+
};
|
|
109
|
+
export declare const RedoControl: {
|
|
110
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
111
|
+
displayName: string;
|
|
112
|
+
};
|
|
113
|
+
export declare const TaskListControl: {
|
|
114
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
115
|
+
displayName: string;
|
|
116
|
+
};
|
|
117
|
+
export declare const TaskListSinkControl: {
|
|
118
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
119
|
+
displayName: string;
|
|
120
|
+
};
|
|
121
|
+
export declare const TaskListLiftControl: {
|
|
122
|
+
(props: import('./IRichTextEditorProps').IRichTextEditorControlBaseProps): import("react/jsx-runtime").JSX.Element;
|
|
123
|
+
displayName: string;
|
|
124
|
+
};
|
|
125
|
+
//# sourceMappingURL=controls.d.ts.map
|