hazo_ui 2.2.6 → 2.3.0
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/README.md +255 -0
- package/dist/index.cjs +2437 -4519
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +35 -63
- package/dist/index.d.ts +35 -63
- package/dist/index.js +2397 -4498
- package/dist/index.js.map +1 -1
- package/dist/styles.css +0 -127
- package/package.json +29 -41
package/dist/index.d.cts
CHANGED
|
@@ -105,89 +105,61 @@ interface HazoUiFlexInputProps extends Omit<InputProps, "type"> {
|
|
|
105
105
|
declare const HazoUiFlexInput: React.ForwardRefExoticComponent<HazoUiFlexInputProps & React.RefAttributes<HTMLInputElement>>;
|
|
106
106
|
|
|
107
107
|
/**
|
|
108
|
-
*
|
|
108
|
+
* Hazo UI Rich Text Editor - Type Definitions
|
|
109
109
|
*
|
|
110
|
-
*
|
|
110
|
+
* Type definitions for the rich text editor component including
|
|
111
|
+
* attachments, variables, and editor output interfaces.
|
|
111
112
|
*/
|
|
112
|
-
|
|
113
113
|
/**
|
|
114
|
-
*
|
|
114
|
+
* Represents a file attachment stored as base64
|
|
115
115
|
*/
|
|
116
|
-
interface
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
description: string;
|
|
121
|
-
/** Optional category for grouping (e.g., "Template Variables", "System Variables") */
|
|
122
|
-
category?: string;
|
|
116
|
+
interface RteAttachment {
|
|
117
|
+
filename: string;
|
|
118
|
+
mime_type: string;
|
|
119
|
+
data: string;
|
|
123
120
|
}
|
|
124
121
|
/**
|
|
125
|
-
*
|
|
122
|
+
* Represents a template variable that can be inserted into the editor
|
|
126
123
|
*/
|
|
127
|
-
interface
|
|
128
|
-
/** File name */
|
|
124
|
+
interface RteVariable {
|
|
129
125
|
name: string;
|
|
130
|
-
|
|
131
|
-
type: string;
|
|
132
|
-
/** File size in bytes */
|
|
133
|
-
size: number;
|
|
134
|
-
/** URL to the file (either data URL or uploaded URL) */
|
|
135
|
-
url: string;
|
|
126
|
+
description: string;
|
|
136
127
|
}
|
|
137
128
|
/**
|
|
138
|
-
*
|
|
129
|
+
* Output structure returned by the editor on change
|
|
139
130
|
*/
|
|
140
|
-
interface
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
name: string;
|
|
145
|
-
/** File type/mime type */
|
|
146
|
-
type: string;
|
|
147
|
-
/** File size in bytes */
|
|
148
|
-
size: number;
|
|
149
|
-
/** Base64 encoded data (includes data URL prefix) */
|
|
150
|
-
data: string;
|
|
131
|
+
interface RteOutput {
|
|
132
|
+
html: string;
|
|
133
|
+
plain_text: string;
|
|
134
|
+
attachments: RteAttachment[];
|
|
151
135
|
}
|
|
152
136
|
/**
|
|
153
|
-
*
|
|
137
|
+
* Props for the HazoUiRte component
|
|
154
138
|
*/
|
|
155
|
-
interface
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
variables?: Variable[];
|
|
162
|
-
/** Initial attachments array */
|
|
163
|
-
initial_attachments?: Attachment[];
|
|
164
|
-
/** Callback fired when save button is clicked - includes attachments array */
|
|
165
|
-
on_save?: (html: string, text: string, attachments: Attachment[]) => void;
|
|
166
|
-
/** Callback fired on content change */
|
|
167
|
-
on_change?: (html: string, text: string) => void;
|
|
168
|
-
/** Callback fired when attachments change */
|
|
169
|
-
on_attachments_change?: (attachments: Attachment[]) => void;
|
|
170
|
-
/** Callback fired when a file is attached for image embed - return the URL to use for the file */
|
|
171
|
-
on_file_attach?: (file: File) => Promise<string>;
|
|
172
|
-
/** Placeholder text when editor is empty */
|
|
139
|
+
interface HazoUiRteProps {
|
|
140
|
+
html?: string;
|
|
141
|
+
plain_text?: string;
|
|
142
|
+
attachments?: RteAttachment[];
|
|
143
|
+
variables?: RteVariable[];
|
|
144
|
+
on_change?: (output: RteOutput) => void;
|
|
173
145
|
placeholder?: string;
|
|
174
|
-
/** Minimum height of the editor area */
|
|
175
146
|
min_height?: string;
|
|
176
|
-
/** Maximum height of the editor area */
|
|
177
147
|
max_height?: string;
|
|
178
|
-
|
|
179
|
-
read_only?: boolean;
|
|
180
|
-
/** Whether to show the save button */
|
|
181
|
-
show_save_button?: boolean;
|
|
182
|
-
/** Custom text for the save button */
|
|
183
|
-
save_button_text?: string;
|
|
184
|
-
/** Additional CSS class for the container */
|
|
148
|
+
disabled?: boolean;
|
|
185
149
|
className?: string;
|
|
150
|
+
show_output_viewer?: boolean;
|
|
186
151
|
}
|
|
187
152
|
|
|
188
153
|
/**
|
|
189
|
-
*
|
|
154
|
+
* Hazo UI Rich Text Editor Component
|
|
155
|
+
*
|
|
156
|
+
* A comprehensive rich text editor for email template generation with
|
|
157
|
+
* variable insertion support, file attachments, and full formatting controls.
|
|
158
|
+
*/
|
|
159
|
+
|
|
160
|
+
/**
|
|
161
|
+
* HazoUiRte - Rich Text Editor Component
|
|
190
162
|
*/
|
|
191
|
-
declare
|
|
163
|
+
declare const HazoUiRte: React.FC<HazoUiRteProps>;
|
|
192
164
|
|
|
193
|
-
export { type FilterConfig, type FilterField,
|
|
165
|
+
export { type FilterConfig, type FilterField, HazoUiFlexInput, type HazoUiFlexInputProps, HazoUiFlexRadio, type HazoUiFlexRadioItem, type HazoUiFlexRadioProps, HazoUiMultiFilterDialog, HazoUiMultiSortDialog, HazoUiRte, type HazoUiRteProps, type RteAttachment, type RteOutput, type RteVariable, type SortConfig, type SortField };
|
package/dist/index.d.ts
CHANGED
|
@@ -105,89 +105,61 @@ interface HazoUiFlexInputProps extends Omit<InputProps, "type"> {
|
|
|
105
105
|
declare const HazoUiFlexInput: React.ForwardRefExoticComponent<HazoUiFlexInputProps & React.RefAttributes<HTMLInputElement>>;
|
|
106
106
|
|
|
107
107
|
/**
|
|
108
|
-
*
|
|
108
|
+
* Hazo UI Rich Text Editor - Type Definitions
|
|
109
109
|
*
|
|
110
|
-
*
|
|
110
|
+
* Type definitions for the rich text editor component including
|
|
111
|
+
* attachments, variables, and editor output interfaces.
|
|
111
112
|
*/
|
|
112
|
-
|
|
113
113
|
/**
|
|
114
|
-
*
|
|
114
|
+
* Represents a file attachment stored as base64
|
|
115
115
|
*/
|
|
116
|
-
interface
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
description: string;
|
|
121
|
-
/** Optional category for grouping (e.g., "Template Variables", "System Variables") */
|
|
122
|
-
category?: string;
|
|
116
|
+
interface RteAttachment {
|
|
117
|
+
filename: string;
|
|
118
|
+
mime_type: string;
|
|
119
|
+
data: string;
|
|
123
120
|
}
|
|
124
121
|
/**
|
|
125
|
-
*
|
|
122
|
+
* Represents a template variable that can be inserted into the editor
|
|
126
123
|
*/
|
|
127
|
-
interface
|
|
128
|
-
/** File name */
|
|
124
|
+
interface RteVariable {
|
|
129
125
|
name: string;
|
|
130
|
-
|
|
131
|
-
type: string;
|
|
132
|
-
/** File size in bytes */
|
|
133
|
-
size: number;
|
|
134
|
-
/** URL to the file (either data URL or uploaded URL) */
|
|
135
|
-
url: string;
|
|
126
|
+
description: string;
|
|
136
127
|
}
|
|
137
128
|
/**
|
|
138
|
-
*
|
|
129
|
+
* Output structure returned by the editor on change
|
|
139
130
|
*/
|
|
140
|
-
interface
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
name: string;
|
|
145
|
-
/** File type/mime type */
|
|
146
|
-
type: string;
|
|
147
|
-
/** File size in bytes */
|
|
148
|
-
size: number;
|
|
149
|
-
/** Base64 encoded data (includes data URL prefix) */
|
|
150
|
-
data: string;
|
|
131
|
+
interface RteOutput {
|
|
132
|
+
html: string;
|
|
133
|
+
plain_text: string;
|
|
134
|
+
attachments: RteAttachment[];
|
|
151
135
|
}
|
|
152
136
|
/**
|
|
153
|
-
*
|
|
137
|
+
* Props for the HazoUiRte component
|
|
154
138
|
*/
|
|
155
|
-
interface
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
variables?: Variable[];
|
|
162
|
-
/** Initial attachments array */
|
|
163
|
-
initial_attachments?: Attachment[];
|
|
164
|
-
/** Callback fired when save button is clicked - includes attachments array */
|
|
165
|
-
on_save?: (html: string, text: string, attachments: Attachment[]) => void;
|
|
166
|
-
/** Callback fired on content change */
|
|
167
|
-
on_change?: (html: string, text: string) => void;
|
|
168
|
-
/** Callback fired when attachments change */
|
|
169
|
-
on_attachments_change?: (attachments: Attachment[]) => void;
|
|
170
|
-
/** Callback fired when a file is attached for image embed - return the URL to use for the file */
|
|
171
|
-
on_file_attach?: (file: File) => Promise<string>;
|
|
172
|
-
/** Placeholder text when editor is empty */
|
|
139
|
+
interface HazoUiRteProps {
|
|
140
|
+
html?: string;
|
|
141
|
+
plain_text?: string;
|
|
142
|
+
attachments?: RteAttachment[];
|
|
143
|
+
variables?: RteVariable[];
|
|
144
|
+
on_change?: (output: RteOutput) => void;
|
|
173
145
|
placeholder?: string;
|
|
174
|
-
/** Minimum height of the editor area */
|
|
175
146
|
min_height?: string;
|
|
176
|
-
/** Maximum height of the editor area */
|
|
177
147
|
max_height?: string;
|
|
178
|
-
|
|
179
|
-
read_only?: boolean;
|
|
180
|
-
/** Whether to show the save button */
|
|
181
|
-
show_save_button?: boolean;
|
|
182
|
-
/** Custom text for the save button */
|
|
183
|
-
save_button_text?: string;
|
|
184
|
-
/** Additional CSS class for the container */
|
|
148
|
+
disabled?: boolean;
|
|
185
149
|
className?: string;
|
|
150
|
+
show_output_viewer?: boolean;
|
|
186
151
|
}
|
|
187
152
|
|
|
188
153
|
/**
|
|
189
|
-
*
|
|
154
|
+
* Hazo UI Rich Text Editor Component
|
|
155
|
+
*
|
|
156
|
+
* A comprehensive rich text editor for email template generation with
|
|
157
|
+
* variable insertion support, file attachments, and full formatting controls.
|
|
158
|
+
*/
|
|
159
|
+
|
|
160
|
+
/**
|
|
161
|
+
* HazoUiRte - Rich Text Editor Component
|
|
190
162
|
*/
|
|
191
|
-
declare
|
|
163
|
+
declare const HazoUiRte: React.FC<HazoUiRteProps>;
|
|
192
164
|
|
|
193
|
-
export { type FilterConfig, type FilterField,
|
|
165
|
+
export { type FilterConfig, type FilterField, HazoUiFlexInput, type HazoUiFlexInputProps, HazoUiFlexRadio, type HazoUiFlexRadioItem, type HazoUiFlexRadioProps, HazoUiMultiFilterDialog, HazoUiMultiSortDialog, HazoUiRte, type HazoUiRteProps, type RteAttachment, type RteOutput, type RteVariable, type SortConfig, type SortField };
|