react-edit-to-html 1.1.4 → 1.1.5

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/src/App.d.ts CHANGED
@@ -1,3 +1,3 @@
1
1
  import { default as React } from 'react';
2
2
  import { HtmlEditorProps } from './types';
3
- export default function HtmlEditor({ tableSchemas, placeholders, defaultLogo, defaultBanner, headerTitle, headerSubtitle, headerLogo, typographySizes, typographyWeights, typographyFonts, templatingLanguage, loopSyntax, onChange, onExport, onExportPdf, initialBlocks, defaultStyles, showImportHtml, showImportPdf, showClearCanvas, showPreview, showExport, showExportPdf, customButtonStyles, customButtonClassNames }?: HtmlEditorProps): React.JSX.Element;
3
+ export default function HtmlEditor({ tableSchemas, placeholders, defaultLogo, defaultBanner, headerTitle, headerSubtitle, headerLogo, typographySizes, typographyWeights, typographyFonts, templatingLanguage, loopSyntax, onChange, onExport, onExportPdf, initialBlocks, defaultStyles, showImportHtml, showImportPdf, showClearCanvas, showPreview, showExport, showExportPdf, customButtonStyles, customButtonClassNames, customActionComponents }?: HtmlEditorProps): React.JSX.Element;
@@ -97,4 +97,22 @@ export interface HtmlEditorProps {
97
97
  customButtonStyles?: Record<string, React.CSSProperties>;
98
98
  /** Allows passing custom CSS class names dynamically to customize/override button class sheets for header actions */
99
99
  customButtonClassNames?: Record<string, string>;
100
+ /** Allows passing completely custom React components or labels for header actions. Receives an onClick prop to trigger the action. */
101
+ customActionComponents?: {
102
+ importHtml?: (props: {
103
+ onClick: () => void;
104
+ }) => React.ReactNode;
105
+ importPdf?: (props: {
106
+ onClick: () => void;
107
+ }) => React.ReactNode;
108
+ preview?: (props: {
109
+ onClick: () => void;
110
+ }) => React.ReactNode;
111
+ exportPdf?: (props: {
112
+ onClick: () => void;
113
+ }) => React.ReactNode;
114
+ export?: (props: {
115
+ onClick: () => void;
116
+ }) => React.ReactNode;
117
+ };
100
118
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-edit-to-html",
3
- "version": "1.1.4",
3
+ "version": "1.1.5",
4
4
  "author": "BEO Software (https://beo-software.in/)",
5
5
  "homepage": "https://beo-software.in/",
6
6
  "license": "SEE LICENSE IN LICENSE",