@capillarytech/creatives-library 8.0.242-alpha.1 → 8.0.242-alpha.2
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/package.json
CHANGED
|
@@ -77,6 +77,7 @@ const HTMLEditor = ({
|
|
|
77
77
|
onContextChange = null,
|
|
78
78
|
globalActions = null,
|
|
79
79
|
isLiquidEnabled = false, // Controls Liquid tab visibility in ValidationTabs
|
|
80
|
+
isFullMode = true, // Full mode vs library mode - controls layout and visibility
|
|
80
81
|
...props
|
|
81
82
|
}) => {
|
|
82
83
|
// Separate refs for main and modal editors to avoid conflicts
|
|
@@ -434,9 +435,12 @@ const HTMLEditor = ({
|
|
|
434
435
|
);
|
|
435
436
|
}
|
|
436
437
|
|
|
438
|
+
// Add library-mode class when not in full mode
|
|
439
|
+
const editorClassName = `html-editor html-editor--${variant} ${!isFullMode ? 'html-editor--library-mode' : ''} ${className}`;
|
|
440
|
+
|
|
437
441
|
return (
|
|
438
442
|
<EditorProvider value={contextValue}>
|
|
439
|
-
<div className={
|
|
443
|
+
<div className={editorClassName} {...props}>
|
|
440
444
|
{/* Editor Toolbar - Conditional based on variant */}
|
|
441
445
|
{variant === HTML_EDITOR_VARIANTS.EMAIL ? (
|
|
442
446
|
<EditorToolbar
|
|
@@ -596,6 +600,7 @@ HTMLEditor.propTypes = {
|
|
|
596
600
|
onContextChange: PropTypes.func, // Deprecated: use globalActions instead
|
|
597
601
|
globalActions: PropTypes.object,
|
|
598
602
|
isLiquidEnabled: PropTypes.bool, // Controls Liquid tab visibility in validation
|
|
603
|
+
isFullMode: PropTypes.bool, // Full mode vs library mode
|
|
599
604
|
};
|
|
600
605
|
|
|
601
606
|
HTMLEditor.defaultProps = {
|
|
@@ -623,6 +628,7 @@ HTMLEditor.defaultProps = {
|
|
|
623
628
|
onContextChange: null,
|
|
624
629
|
globalActions: null, // Redux actions for API calls
|
|
625
630
|
isLiquidEnabled: false,
|
|
631
|
+
isFullMode: true, // Default to full mode
|
|
626
632
|
};
|
|
627
633
|
|
|
628
634
|
// Export with forwardRef to allow direct access to CodeEditorPane via ref
|