monto-email-builder 1.2.2 → 1.2.4

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.
Files changed (52) hide show
  1. package/README.md +1 -1
  2. package/dist/App/InspectorDrawer/ConfigurationPanel/index.d.ts.map +1 -1
  3. package/dist/App/InspectorDrawer/ConfigurationPanel/input-panels/TextSidebarPanel.d.ts +2 -1
  4. package/dist/App/InspectorDrawer/ConfigurationPanel/input-panels/TextSidebarPanel.d.ts.map +1 -1
  5. package/dist/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/ColorInput/BaseColorInput.d.ts.map +1 -1
  6. package/dist/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/FontStyleInput.d.ts +8 -0
  7. package/dist/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/FontStyleInput.d.ts.map +1 -0
  8. package/dist/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/FontWeightInput.d.ts.map +1 -1
  9. package/dist/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/LetterSpacingInput.d.ts +8 -0
  10. package/dist/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/LetterSpacingInput.d.ts.map +1 -0
  11. package/dist/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/LineHeightInput.d.ts +8 -0
  12. package/dist/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/LineHeightInput.d.ts.map +1 -0
  13. package/dist/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/RadioGroupInput.d.ts.map +1 -1
  14. package/dist/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/TextDecorationInput.d.ts +9 -0
  15. package/dist/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/TextDecorationInput.d.ts.map +1 -0
  16. package/dist/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/TextFormatGroup.d.ts +8 -0
  17. package/dist/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/TextFormatGroup.d.ts.map +1 -0
  18. package/dist/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/style-inputs/MultiStylePropertyPanel.d.ts.map +1 -1
  19. package/dist/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/style-inputs/SingleStylePropertyPanel.d.ts.map +1 -1
  20. package/dist/App/InspectorDrawer/ToggleInspectorPanelButton.d.ts.map +1 -1
  21. package/dist/App/InspectorDrawer/index.d.ts.map +1 -1
  22. package/dist/App/SamplesDrawer/ToggleSamplesPanelButton.d.ts.map +1 -1
  23. package/dist/App/TemplatePanel/MainTabsGroup.d.ts.map +1 -1
  24. package/dist/App/TemplatePanel/index.d.ts.map +1 -1
  25. package/dist/EmailBuilder/index.d.ts +16 -0
  26. package/dist/EmailBuilder/index.d.ts.map +1 -1
  27. package/dist/HtmlEditor/index.d.ts.map +1 -1
  28. package/dist/chunks/{chunk-CxhtzHBZ.js → chunk-_7XTjFEi.js} +220 -80
  29. package/dist/documents/blocks/Text/TextEditor.d.ts.map +1 -1
  30. package/dist/documents/blocks/Text/TextEditorRich.d.ts +3 -0
  31. package/dist/documents/blocks/Text/TextEditorRich.d.ts.map +1 -0
  32. package/dist/documents/blocks/Text/textDom.d.ts +70 -0
  33. package/dist/documents/blocks/Text/textDom.d.ts.map +1 -0
  34. package/dist/documents/blocks/Text/variableCatalog.d.ts +23 -0
  35. package/dist/documents/blocks/Text/variableCatalog.d.ts.map +1 -0
  36. package/dist/documents/blocks/helpers/TStyle.d.ts +4 -0
  37. package/dist/documents/blocks/helpers/TStyle.d.ts.map +1 -1
  38. package/dist/documents/blocks/helpers/block-wrappers/EditorBlockWrapper.d.ts.map +1 -1
  39. package/dist/documents/blocks/helpers/block-wrappers/TuneMenu.d.ts.map +1 -1
  40. package/dist/documents/editor/EditorContext.d.ts +85 -0
  41. package/dist/documents/editor/EditorContext.d.ts.map +1 -1
  42. package/dist/documents/editor/collectTemplateVariables.d.ts +51 -0
  43. package/dist/documents/editor/collectTemplateVariables.d.ts.map +1 -0
  44. package/dist/documents/editor/core.d.ts +717 -4
  45. package/dist/documents/editor/core.d.ts.map +1 -1
  46. package/dist/documents/editor/flushActiveTextEditorToDocument.d.ts +6 -0
  47. package/dist/documents/editor/flushActiveTextEditorToDocument.d.ts.map +1 -0
  48. package/dist/html-editor.js +144 -127
  49. package/dist/index.d.ts +2 -1
  50. package/dist/index.d.ts.map +1 -1
  51. package/dist/index.js +5180 -2860
  52. package/package.json +16 -15
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Email Builder - 邮件模板编辑器组件库
2
2
 
3
- > node >= 18 + pnpm 10
3
+ > node >= 18+ + pnpm 10
4
4
 
5
5
  一个功能完整的邮件模板编辑器 React 组件,可以在其他 React 项目中使用。
6
6
 
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/App/InspectorDrawer/ConfigurationPanel/index.tsx"],"names":[],"mappings":"AA6BA,MAAM,CAAC,OAAO,UAAU,kBAAkB,4CA+CzC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/App/InspectorDrawer/ConfigurationPanel/index.tsx"],"names":[],"mappings":"AA6BA,MAAM,CAAC,OAAO,UAAU,kBAAkB,4CAsDzC"}
@@ -1,8 +1,9 @@
1
1
  import { TextProps } from 'monto-email-block-text';
2
2
  type TextSidebarPanelProps = {
3
+ blockId: string;
3
4
  data: TextProps;
4
5
  setData: (v: TextProps) => void;
5
6
  };
6
- export default function TextSidebarPanel({ data, setData }: TextSidebarPanelProps): import("react/jsx-runtime").JSX.Element;
7
+ export default function TextSidebarPanel({ blockId, data, setData }: TextSidebarPanelProps): import("react/jsx-runtime").JSX.Element;
7
8
  export {};
8
9
  //# sourceMappingURL=TextSidebarPanel.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"TextSidebarPanel.d.ts","sourceRoot":"","sources":["../../../../../src/App/InspectorDrawer/ConfigurationPanel/input-panels/TextSidebarPanel.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,SAAS,EAAmB,MAAM,wBAAwB,CAAC;AAOpE,KAAK,qBAAqB,GAAG;IAC3B,IAAI,EAAE,SAAS,CAAC;IAChB,OAAO,EAAE,CAAC,CAAC,EAAE,SAAS,KAAK,IAAI,CAAC;CACjC,CAAC;AACF,MAAM,CAAC,OAAO,UAAU,gBAAgB,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,EAAE,qBAAqB,2CA+BhF"}
1
+ {"version":3,"file":"TextSidebarPanel.d.ts","sourceRoot":"","sources":["../../../../../src/App/InspectorDrawer/ConfigurationPanel/input-panels/TextSidebarPanel.tsx"],"names":[],"mappings":"AAMA,OAAO,EAAE,SAAS,EAA4C,MAAM,wBAAwB,CAAC;AAqD7F,KAAK,qBAAqB,GAAG;IAC3B,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,SAAS,CAAC;IAChB,OAAO,EAAE,CAAC,CAAC,EAAE,SAAS,KAAK,IAAI,CAAC;CACjC,CAAC;AAEF,MAAM,CAAC,OAAO,UAAU,gBAAgB,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,EAAE,qBAAqB,2CAovBzF"}
@@ -1 +1 @@
1
- {"version":3,"file":"BaseColorInput.d.ts","sourceRoot":"","sources":["../../../../../../../../src/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/ColorInput/BaseColorInput.tsx"],"names":[],"mappings":"AAgBA,KAAK,KAAK,GACN;IACE,QAAQ,EAAE,IAAI,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,KAAK,IAAI,CAAC;IACzC,YAAY,EAAE,MAAM,GAAG,IAAI,CAAC;CAC7B,GACD;IACE,QAAQ,EAAE,KAAK,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,YAAY,EAAE,MAAM,CAAC;CACtB,CAAC;AACN,MAAM,CAAC,OAAO,UAAU,UAAU,CAAC,EAAE,KAAK,EAAE,YAAY,EAAE,QAAQ,EAAE,QAAQ,EAAE,EAAE,KAAK,2CA8DpF"}
1
+ {"version":3,"file":"BaseColorInput.d.ts","sourceRoot":"","sources":["../../../../../../../../src/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/ColorInput/BaseColorInput.tsx"],"names":[],"mappings":"AAgCA,KAAK,KAAK,GACN;IACE,QAAQ,EAAE,IAAI,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,KAAK,IAAI,CAAC;IACzC,YAAY,EAAE,MAAM,GAAG,IAAI,CAAC;CAC7B,GACD;IACE,QAAQ,EAAE,KAAK,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,YAAY,EAAE,MAAM,CAAC;CACtB,CAAC;AACN,MAAM,CAAC,OAAO,UAAU,UAAU,CAAC,EAAE,KAAK,EAAE,YAAY,EAAE,QAAQ,EAAE,QAAQ,EAAE,EAAE,KAAK,2CA0EpF"}
@@ -0,0 +1,8 @@
1
+ type Props = {
2
+ label: string;
3
+ defaultValue: string;
4
+ onChange: (value: string) => void;
5
+ };
6
+ export default function FontStyleInput({ label, defaultValue, onChange }: Props): import("react/jsx-runtime").JSX.Element;
7
+ export {};
8
+ //# sourceMappingURL=FontStyleInput.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"FontStyleInput.d.ts","sourceRoot":"","sources":["../../../../../../../src/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/FontStyleInput.tsx"],"names":[],"mappings":"AAOA,KAAK,KAAK,GAAG;IACX,KAAK,EAAE,MAAM,CAAC;IACd,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CACnC,CAAC;AACF,MAAM,CAAC,OAAO,UAAU,cAAc,CAAC,EAAE,KAAK,EAAE,YAAY,EAAE,QAAQ,EAAE,EAAE,KAAK,2CAoB9E"}
@@ -1 +1 @@
1
- {"version":3,"file":"FontWeightInput.d.ts","sourceRoot":"","sources":["../../../../../../../src/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/FontWeightInput.tsx"],"names":[],"mappings":"AAMA,KAAK,KAAK,GAAG;IACX,KAAK,EAAE,MAAM,CAAC;IACd,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CACnC,CAAC;AACF,MAAM,CAAC,OAAO,UAAU,eAAe,CAAC,EAAE,KAAK,EAAE,YAAY,EAAE,QAAQ,EAAE,EAAE,KAAK,2CAe/E"}
1
+ {"version":3,"file":"FontWeightInput.d.ts","sourceRoot":"","sources":["../../../../../../../src/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/FontWeightInput.tsx"],"names":[],"mappings":"AAOA,KAAK,KAAK,GAAG;IACX,KAAK,EAAE,MAAM,CAAC;IACd,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CACnC,CAAC;AACF,MAAM,CAAC,OAAO,UAAU,eAAe,CAAC,EAAE,KAAK,EAAE,YAAY,EAAE,QAAQ,EAAE,EAAE,KAAK,2CAoB/E"}
@@ -0,0 +1,8 @@
1
+ type Props = {
2
+ label: string;
3
+ defaultValue: number | string | null | undefined;
4
+ onChange: (value: number | null) => void;
5
+ };
6
+ export default function LetterSpacingInput({ label, defaultValue, onChange }: Props): import("react/jsx-runtime").JSX.Element;
7
+ export {};
8
+ //# sourceMappingURL=LetterSpacingInput.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LetterSpacingInput.d.ts","sourceRoot":"","sources":["../../../../../../../src/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/LetterSpacingInput.tsx"],"names":[],"mappings":"AAiBA,KAAK,KAAK,GAAG;IACX,KAAK,EAAE,MAAM,CAAC;IACd,YAAY,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,GAAG,SAAS,CAAC;IACjD,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,KAAK,IAAI,CAAC;CAC1C,CAAC;AACF,MAAM,CAAC,OAAO,UAAU,kBAAkB,CAAC,EAAE,KAAK,EAAE,YAAY,EAAE,QAAQ,EAAE,EAAE,KAAK,2CA2BlF"}
@@ -0,0 +1,8 @@
1
+ type Props = {
2
+ label: string;
3
+ defaultValue: number | null | undefined;
4
+ onChange: (value: number | null) => void;
5
+ };
6
+ export default function LineHeightInput({ label, defaultValue, onChange }: Props): import("react/jsx-runtime").JSX.Element;
7
+ export {};
8
+ //# sourceMappingURL=LineHeightInput.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LineHeightInput.d.ts","sourceRoot":"","sources":["../../../../../../../src/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/LineHeightInput.tsx"],"names":[],"mappings":"AAOA,KAAK,KAAK,GAAG;IACX,KAAK,EAAE,MAAM,CAAC;IACd,YAAY,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,CAAC;IACxC,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,KAAK,IAAI,CAAC;CAC1C,CAAC;AACF,MAAM,CAAC,OAAO,UAAU,eAAe,CAAC,EAAE,KAAK,EAAE,YAAY,EAAE,QAAQ,EAAE,EAAE,KAAK,2CAyB/E"}
@@ -1 +1 @@
1
- {"version":3,"file":"RadioGroupInput.d.ts","sourceRoot":"","sources":["../../../../../../../src/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/RadioGroupInput.tsx"],"names":[],"mappings":"AAIA,KAAK,KAAK,GAAG;IACX,KAAK,EAAE,MAAM,GAAG,GAAG,CAAC,OAAO,CAAC;IAC5B,QAAQ,EAAE,GAAG,CAAC,OAAO,GAAG,GAAG,CAAC,OAAO,EAAE,CAAC;IACtC,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;CAC/B,CAAC;AACF,MAAM,CAAC,OAAO,UAAU,eAAe,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAE,YAAY,EAAE,QAAQ,EAAE,EAAE,KAAK,2CAsBzF"}
1
+ {"version":3,"file":"RadioGroupInput.d.ts","sourceRoot":"","sources":["../../../../../../../src/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/RadioGroupInput.tsx"],"names":[],"mappings":"AAIA,KAAK,KAAK,GAAG;IACX,KAAK,EAAE,MAAM,GAAG,GAAG,CAAC,OAAO,CAAC;IAC5B,QAAQ,EAAE,GAAG,CAAC,OAAO,GAAG,GAAG,CAAC,OAAO,EAAE,CAAC;IACtC,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;CAC/B,CAAC;AACF,MAAM,CAAC,OAAO,UAAU,eAAe,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAE,YAAY,EAAE,QAAQ,EAAE,EAAE,KAAK,2CAyBzF"}
@@ -0,0 +1,9 @@
1
+ export type TextDecorationValue = 'none' | 'underline' | 'line-through' | 'underline line-through';
2
+ type Props = {
3
+ label: string;
4
+ defaultValue: string;
5
+ onChange: (value: TextDecorationValue) => void;
6
+ };
7
+ export default function TextDecorationInput({ label, defaultValue, onChange }: Props): import("react/jsx-runtime").JSX.Element;
8
+ export {};
9
+ //# sourceMappingURL=TextDecorationInput.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TextDecorationInput.d.ts","sourceRoot":"","sources":["../../../../../../../src/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/TextDecorationInput.tsx"],"names":[],"mappings":"AAOA,MAAM,MAAM,mBAAmB,GAAG,MAAM,GAAG,WAAW,GAAG,cAAc,GAAG,wBAAwB,CAAC;AAEnG,KAAK,KAAK,GAAG;IACX,KAAK,EAAE,MAAM,CAAC;IACd,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,CAAC,KAAK,EAAE,mBAAmB,KAAK,IAAI,CAAC;CAChD,CAAC;AACF,MAAM,CAAC,OAAO,UAAU,mBAAmB,CAAC,EAAE,KAAK,EAAE,YAAY,EAAE,QAAQ,EAAE,EAAE,KAAK,2CAsBnF"}
@@ -0,0 +1,8 @@
1
+ import { TStyle } from '../../../../../../documents/blocks/helpers/TStyle';
2
+ type Props = {
3
+ value: TStyle;
4
+ onChange: (style: TStyle) => void;
5
+ };
6
+ export default function TextFormatGroup({ value, onChange }: Props): import("react/jsx-runtime").JSX.Element;
7
+ export {};
8
+ //# sourceMappingURL=TextFormatGroup.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TextFormatGroup.d.ts","sourceRoot":"","sources":["../../../../../../../src/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/inputs/TextFormatGroup.tsx"],"names":[],"mappings":"AAQA,OAAO,EAAE,MAAM,EAAE,MAAM,mDAAmD,CAAC;AAmB3E,KAAK,KAAK,GAAG;IACX,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CACnC,CAAC;AACF,MAAM,CAAC,OAAO,UAAU,eAAe,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAE,EAAE,KAAK,2CAgDjE"}
@@ -1 +1 @@
1
- {"version":3,"file":"MultiStylePropertyPanel.d.ts","sourceRoot":"","sources":["../../../../../../../src/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/style-inputs/MultiStylePropertyPanel.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,MAAM,EAAE,MAAM,mDAAmD,CAAC;AAI3E,KAAK,4BAA4B,GAAG;IAClC,KAAK,EAAE,CAAC,MAAM,MAAM,CAAC,EAAE,CAAC;IACxB,KAAK,EAAE,MAAM,GAAG,SAAS,GAAG,IAAI,CAAC;IACjC,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CACnC,CAAC;AACF,MAAM,CAAC,OAAO,UAAU,uBAAuB,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,QAAQ,EAAE,EAAE,4BAA4B,2CAQvG"}
1
+ {"version":3,"file":"MultiStylePropertyPanel.d.ts","sourceRoot":"","sources":["../../../../../../../src/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/style-inputs/MultiStylePropertyPanel.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,MAAM,EAAE,MAAM,mDAAmD,CAAC;AAW3E,KAAK,4BAA4B,GAAG;IAClC,KAAK,EAAE,CAAC,MAAM,MAAM,CAAC,EAAE,CAAC;IACxB,KAAK,EAAE,MAAM,GAAG,SAAS,GAAG,IAAI,CAAC;IACjC,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CACnC,CAAC;AACF,MAAM,CAAC,OAAO,UAAU,uBAAuB,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,QAAQ,EAAE,EAAE,4BAA4B,2CAyBvG"}
@@ -1 +1 @@
1
- {"version":3,"file":"SingleStylePropertyPanel.d.ts","sourceRoot":"","sources":["../../../../../../../src/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/style-inputs/SingleStylePropertyPanel.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,MAAM,EAAE,MAAM,mDAAmD,CAAC;AAU3E,KAAK,uBAAuB,GAAG;IAC7B,IAAI,EAAE,MAAM,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CACnC,CAAC;AACF,MAAM,CAAC,OAAO,UAAU,wBAAwB,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,QAAQ,EAAE,EAAE,uBAAuB,2CAwClG"}
1
+ {"version":3,"file":"SingleStylePropertyPanel.d.ts","sourceRoot":"","sources":["../../../../../../../src/App/InspectorDrawer/ConfigurationPanel/input-panels/helpers/style-inputs/SingleStylePropertyPanel.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,MAAM,EAAE,MAAM,mDAAmD,CAAC;AAc3E,KAAK,uBAAuB,GAAG;IAC7B,IAAI,EAAE,MAAM,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CACnC,CAAC;AACF,MAAM,CAAC,OAAO,UAAU,wBAAwB,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,QAAQ,EAAE,EAAE,uBAAuB,2CAgDlG"}
@@ -1 +1 @@
1
- {"version":3,"file":"ToggleInspectorPanelButton.d.ts","sourceRoot":"","sources":["../../../src/App/InspectorDrawer/ToggleInspectorPanelButton.tsx"],"names":[],"mappings":"AAOA,MAAM,CAAC,OAAO,UAAU,0BAA0B,4CAkBjD"}
1
+ {"version":3,"file":"ToggleInspectorPanelButton.d.ts","sourceRoot":"","sources":["../../../src/App/InspectorDrawer/ToggleInspectorPanelButton.tsx"],"names":[],"mappings":"AAQA,MAAM,CAAC,OAAO,UAAU,0BAA0B,4CAkBjD"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/App/InspectorDrawer/index.tsx"],"names":[],"mappings":"AAUA,eAAO,MAAM,sBAAsB,MAAM,CAAC;AAE1C,MAAM,CAAC,OAAO,UAAU,eAAe,4CAuDtC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/App/InspectorDrawer/index.tsx"],"names":[],"mappings":"AAeA,eAAO,MAAM,sBAAsB,MAAM,CAAC;AAE1C,MAAM,CAAC,OAAO,UAAU,eAAe,4CAgEtC"}
@@ -1 +1 @@
1
- {"version":3,"file":"ToggleSamplesPanelButton.d.ts","sourceRoot":"","sources":["../../../src/App/SamplesDrawer/ToggleSamplesPanelButton.tsx"],"names":[],"mappings":"AAeA,MAAM,CAAC,OAAO,UAAU,wBAAwB,4CAG/C"}
1
+ {"version":3,"file":"ToggleSamplesPanelButton.d.ts","sourceRoot":"","sources":["../../../src/App/SamplesDrawer/ToggleSamplesPanelButton.tsx"],"names":[],"mappings":"AAgBA,MAAM,CAAC,OAAO,UAAU,wBAAwB,4CAG/C"}
@@ -1 +1 @@
1
- {"version":3,"file":"MainTabsGroup.d.ts","sourceRoot":"","sources":["../../../src/App/TemplatePanel/MainTabsGroup.tsx"],"names":[],"mappings":"AAQA,MAAM,CAAC,OAAO,UAAU,aAAa,4CAuDpC"}
1
+ {"version":3,"file":"MainTabsGroup.d.ts","sourceRoot":"","sources":["../../../src/App/TemplatePanel/MainTabsGroup.tsx"],"names":[],"mappings":"AAWA,MAAM,CAAC,OAAO,UAAU,aAAa,4CAuDpC"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/App/TemplatePanel/index.tsx"],"names":[],"mappings":"AA8BA,MAAM,CAAC,OAAO,UAAU,aAAa,4CAgHpC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/App/TemplatePanel/index.tsx"],"names":[],"mappings":"AA+BA,MAAM,CAAC,OAAO,UAAU,aAAa,4CAkHpC"}
@@ -1,5 +1,6 @@
1
1
  import React from 'react';
2
2
  import { Language } from '../i18n';
3
+ import { type EmailBuilderVariableInput, type EmailTemplateVariableItem } from '../documents/editor/collectTemplateVariables';
3
4
  import { TEditorConfiguration } from '../documents/editor/core';
4
5
  import theme from '../theme';
5
6
  export interface EmailBuilderProps {
@@ -71,6 +72,15 @@ export interface EmailBuilderProps {
71
72
  * @param isOpen 侧边栏是否打开
72
73
  */
73
74
  onInspectorDrawerToggle?: (isOpen: boolean) => void;
75
+ /** 联系人属性列表:用于 Text 变量面板动态扩展 Contacts 变量 */
76
+ contactAttributes?: import('../documents/editor/EditorContext').ContactAttribute[];
77
+ /**
78
+ * 已有模板的变量默认值。集成方只需传 `attribute` + `default`(或 `variable: "{{name}}"`),
79
+ * 组件会按正文内插入式变量匹配 `variableInstanceId`;也可选传 `variableInstanceId` 精确写入一条。
80
+ * 仅更新 `variableDefaults`;未在正文中出现的变量名会被忽略。
81
+ * 仅 `variables` 变化时会在当前文档上合并,不替换整份文档。
82
+ */
83
+ variables?: EmailBuilderVariableInput[];
74
84
  }
75
85
  /**
76
86
  * EmailBuilder 组件暴露的方法
@@ -81,7 +91,13 @@ export interface EmailBuilderRef {
81
91
  * @param callback 回调函数,接收 json 和 html 作为参数
82
92
  */
83
93
  getData: (callback: (json: TEditorConfiguration, html: string) => void) => void;
94
+ /**
95
+ * 获取模板中插入式联系人变量列表(Text 块 `{{attribute}}` + 侧栏默认值)
96
+ * @param callback 接收形如 `[{ id, variableInstanceId, variable: "{{email}}", type: "user", attribute: "email", default: "..." }]`(variableDefaults 按 variableInstanceId 存)
97
+ */
98
+ getVariables: (callback: (items: EmailTemplateVariableItem[]) => void) => void;
84
99
  }
100
+ export type { EmailBuilderVariableInput, EmailTemplateVariableItem };
85
101
  /**
86
102
  * EmailBuilder 组件
87
103
  *
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/EmailBuilder/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmE,MAAM,OAAO,CAAC;AAqBxF,OAAO,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AACnC,OAAO,EAAE,oBAAoB,EAAE,MAAM,0BAA0B,CAAC;AAChE,OAAO,KAAK,MAAM,UAAU,CAAC;AAqB7B,MAAM,WAAW,iBAAiB;IAChC;;;OAGG;IACH,eAAe,CAAC,EAAE,oBAAoB,CAAC;IAEvC;;;;OAIG;IACH,Q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