@go-mailer/easy-email-extensions 5.0.6 → 5.0.8

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.
@@ -1,8 +1,8 @@
1
1
  import React from 'react';
2
- import { InputWithUnitProps } from '../../../components/Form/InputWithUnit';
3
2
  import { UseFieldConfig } from 'react-final-form';
4
- export declare function Width({ inline, unitOptions, config, }: {
3
+ export declare function Width({ inline, config, pixelMode, }: {
5
4
  inline?: boolean;
6
- unitOptions?: InputWithUnitProps['unitOptions'];
7
5
  config?: UseFieldConfig<any>;
6
+ /** Store as px (0–600) and display as % of 600px. Default is % storage (0–100%). */
7
+ pixelMode?: boolean;
8
8
  }): React.JSX.Element;
@@ -0,0 +1,2 @@
1
+ import React from 'react';
2
+ export declare function CountdownPanel(): React.JSX.Element;
@@ -0,0 +1,20 @@
1
+ import { IBlockData } from '@go-mailer/easy-email-core';
2
+ export declare const CountdownBlockType = "go-mailer-countdown";
3
+ export declare const COUNTDOWN_API_URL = "http://localhost:4010/images/countdown";
4
+ export type ICountdownBlock = IBlockData<{
5
+ endDate: string;
6
+ timezone: string;
7
+ backgroundColor: string;
8
+ textColor: string;
9
+ fontSize: string;
10
+ format: string;
11
+ width: string;
12
+ height: string;
13
+ link: string;
14
+ 'container-background-color': string;
15
+ /** Cached GIF URL returned by the countdown API — used in the render. */
16
+ gifUrl: string;
17
+ }, Record<string, never>>;
18
+ /** POST to the countdown API and return the GIF URL. */
19
+ export declare function fetchCountdownGif(endDate: string): Promise<string>;
20
+ export declare const CountdownBlock: import("@go-mailer/easy-email-core").IBlock<ICountdownBlock>;
@@ -4,6 +4,7 @@ export type IVideoBlock = IBlockData<{
4
4
  src: string;
5
5
  href: string;
6
6
  width: string;
7
+ height: string;
7
8
  'container-background-color': string;
8
9
  }, Record<string, never>>;
9
10
  export declare const VideoBlock: import("@go-mailer/easy-email-core").IBlock<IVideoBlock>;
@@ -9,5 +9,7 @@ export interface ImageUploaderProps {
9
9
  value: string;
10
10
  label: React.ReactNode;
11
11
  }>;
12
+ /** If true, opens the file picker immediately on mount when value is empty. */
13
+ autoTrigger?: boolean;
12
14
  }
13
15
  export declare function ImageUploader(props: ImageUploaderProps): React.JSX.Element;
@@ -7,5 +7,10 @@ export interface NativeSliderProps {
7
7
  step?: number;
8
8
  /** If true the value badge shows a % suffix instead of px */
9
9
  percentMode?: boolean;
10
+ /**
11
+ * When set alongside percentMode, the badge shows both the % value and its
12
+ * pixel equivalent — e.g. "50% · 300px" — where pixelMax is the 100% px value.
13
+ */
14
+ pixelMax?: number;
10
15
  }
11
- export declare function NativeSlider({ value, onChange, min, max, step, percentMode, }: NativeSliderProps): React.JSX.Element;
16
+ export declare function NativeSlider({ value, onChange, min, max, step, percentMode, pixelMax, }: NativeSliderProps): React.JSX.Element;
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ export interface NativeStepperProps {
3
+ value?: number;
4
+ onChange?: (val: number) => void;
5
+ min?: number;
6
+ max?: number;
7
+ step?: number;
8
+ }
9
+ export declare function NativeStepper({ value, onChange, min, max, step, }: NativeStepperProps): React.JSX.Element;
@@ -14,6 +14,7 @@ import { AutoCompleteProps } from './AutoComplete';
14
14
  import { InputSearchProps } from '@arco-design/web-react/es/Input';
15
15
  import { ColorPickerField } from './ColorPickerField';
16
16
  import { NativeSliderProps } from './NativeSlider';
17
+ import { NativeStepperProps } from './NativeStepper';
17
18
  export { RichTextField } from './RichTextField';
18
19
  export declare const TextField: (props: import("./enhancer").EnhancerProps & Omit<InputProps, "value" | "onChange" | "mutators">) => import("react").JSX.Element;
19
20
  export declare const InputWithUnitField: (props: import("./enhancer").EnhancerProps & Omit<InputWithUnitProps, "value" | "onChange" | "mutators">) => import("react").JSX.Element;
@@ -21,6 +22,7 @@ export declare const SearchField: (props: import("./enhancer").EnhancerProps & O
21
22
  export declare const TextAreaField: (props: import("./enhancer").EnhancerProps & Omit<TextAreaProps, "value" | "onChange" | "mutators">) => import("react").JSX.Element;
22
23
  export declare const NumberField: (props: import("./enhancer").EnhancerProps & Omit<InputNumberProps, "value" | "onChange" | "mutators">) => import("react").JSX.Element;
23
24
  export declare const SliderField: (props: import("./enhancer").EnhancerProps & Omit<NativeSliderProps, "value" | "onChange" | "mutators">) => import("react").JSX.Element;
25
+ export declare const StepperField: (props: import("./enhancer").EnhancerProps & Omit<NativeStepperProps, "value" | "onChange" | "mutators">) => import("react").JSX.Element;
24
26
  export declare const UploadField: (props: import("./enhancer").EnhancerProps & Omit<UploadFieldProps, "value" | "onChange" | "mutators">) => import("react").JSX.Element;
25
27
  export declare const ImageUploaderField: (props: import("./enhancer").EnhancerProps & Omit<ImageUploaderProps, "value" | "onChange" | "mutators">) => import("react").JSX.Element;
26
28
  export declare const SelectField: (props: import("./enhancer").EnhancerProps & Omit<SelectProps, "value" | "onChange" | "mutators">) => import("react").JSX.Element;
package/lib/index.js CHANGED
@@ -1,4 +1,4 @@
1
- export { e as Align, A as AttributePanel, f as AttributesPanelWrapper, af as AutoCompleteField, l as Background, o as BackgroundColor, d as BlockAttributeConfigurationManager, B as BlockLayer, Q as BlockMarketManager, R as BlockMaskWrapper, r as Border, v as BorderColor, y as BorderStyle, E as BorderWidth, ai as CheckboxField, J as ClassName, h as CollapseWrapper, C as Color, am as ColorPickerField, i as Condition, j as ContainerBackgroundColor, D as Decoration, P as DefaultPageConfigPanel, p as Direction, ak as EditGridTabField, aj as EditTabField, a1 as ExtensionContext, a2 as ExtensionProvider, F as FontFamily, w as FontSize, z as FontStyle, G as FontWeight, $ as GoMailerLayout, H as Height, ac as ImageUploaderField, al as InlineTextField, a6 as InputWithUnitField, X as InteractivePrompt, L as LetterSpacing, m as LineHeight, q as Link, t as Margin, a0 as MergeTagBadgePrompt, x as MergeTags, M as MjmlToJson, N as NavbarLinkPadding, a9 as NumberField, I as Padding, K as PresetColorsProvider, a4 as RICH_TEXT_TOOL_BAR, ag as RadioGroupField, ao as RichTextField, a7 as SearchField, ad as SelectField, S as SelectionRangeProvider, ap as ShadowDom, O as ShortcutToolbar, Y as SimpleLayout, aa as SliderField, U as SourceCodePanel, Z as StandardLayout, ah as SwitchField, T as TextAlign, a8 as TextAreaField, k as TextDecoration, a5 as TextField, n as TextTransform, ae as TreeSelectField, _ as TwoColumnLayout, ab as UploadField, V as VerticalAlign, W as Width, an as enhancer, b as getBlockTitle, g as getContextMergeTags, a as getIconNameByBlockType, s as setIconsMap, u as useAIContext, a3 as useExtensionProps } from "./index2.js";
1
+ export { e as Align, A as AttributePanel, f as AttributesPanelWrapper, ag as AutoCompleteField, l as Background, o as BackgroundColor, d as BlockAttributeConfigurationManager, B as BlockLayer, Q as BlockMarketManager, R as BlockMaskWrapper, r as Border, v as BorderColor, y as BorderStyle, E as BorderWidth, aj as CheckboxField, J as ClassName, h as CollapseWrapper, C as Color, an as ColorPickerField, i as Condition, j as ContainerBackgroundColor, D as Decoration, P as DefaultPageConfigPanel, p as Direction, al as EditGridTabField, ak as EditTabField, a1 as ExtensionContext, a2 as ExtensionProvider, F as FontFamily, w as FontSize, z as FontStyle, G as FontWeight, $ as GoMailerLayout, H as Height, ad as ImageUploaderField, am as InlineTextField, a6 as InputWithUnitField, X as InteractivePrompt, L as LetterSpacing, m as LineHeight, q as Link, t as Margin, a0 as MergeTagBadgePrompt, x as MergeTags, M as MjmlToJson, N as NavbarLinkPadding, a9 as NumberField, I as Padding, K as PresetColorsProvider, a4 as RICH_TEXT_TOOL_BAR, ah as RadioGroupField, ap as RichTextField, a7 as SearchField, ae as SelectField, S as SelectionRangeProvider, aq as ShadowDom, O as ShortcutToolbar, Y as SimpleLayout, aa as SliderField, U as SourceCodePanel, Z as StandardLayout, ab as StepperField, ai as SwitchField, T as TextAlign, a8 as TextAreaField, k as TextDecoration, a5 as TextField, n as TextTransform, af as TreeSelectField, _ as TwoColumnLayout, ac as UploadField, V as VerticalAlign, W as Width, ao as enhancer, b as getBlockTitle, g as getContextMergeTags, a as getIconNameByBlockType, s as setIconsMap, u as useAIContext, a3 as useExtensionProps } from "./index2.js";
2
2
  import "react";
3
3
  import "@go-mailer/easy-email-editor";
4
4
  import "@go-mailer/easy-email-core";