@mjml-agent-editor/editor 0.1.17 → 0.2.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.
@@ -38,9 +38,201 @@ var DEFAULT_LABELS = {
38
38
  exportHtml: "Export HTML",
39
39
  exportMjml: "Export MJML",
40
40
  copied: (kind) => `${kind} copied.`,
41
+ tabBlocks: "Blocks",
42
+ tabSettings: "Settings",
43
+ tabLayers: "Layers",
41
44
  searchBlocks: "Search blocks\u2026",
45
+ noBlocksMatch: "No blocks match.",
46
+ blockCategoryLayout: "Layout",
47
+ blockCategoryContent: "Content",
48
+ blockLabels: {
49
+ "mj-1-column": "1 column",
50
+ "mj-2-columns": "2 columns",
51
+ "mj-3-columns": "3 columns",
52
+ "mj-text": "Text",
53
+ "mj-image": "Image",
54
+ "mj-button": "Button",
55
+ "mj-divider": "Divider",
56
+ "mj-spacer": "Spacer",
57
+ "mj-social-group": "Social links",
58
+ "mj-navbar": "Navigation"
59
+ },
60
+ elementNames: {
61
+ "mj-wrapper": "Section group",
62
+ "mj-section": "Section",
63
+ "mj-column": "Column",
64
+ "mj-group": "Column group",
65
+ "mj-text": "Text",
66
+ "mj-button": "Button",
67
+ "mj-image": "Image",
68
+ "mj-divider": "Divider",
69
+ "mj-spacer": "Spacer",
70
+ "mj-hero": "Hero",
71
+ "mj-navbar": "Navigation",
72
+ "mj-navbar-link": "Navigation link",
73
+ "mj-social": "Social links",
74
+ "mj-social-element": "Social link",
75
+ "mj-raw": "Raw HTML"
76
+ },
42
77
  expandAll: "Expand all",
43
78
  selectAnElement: "Select an element\u2026",
79
+ settingsEmpty: "Select something in the email to edit it.",
80
+ emailSettings: "Email settings",
81
+ loadingEditor: "Loading editor\u2026",
82
+ commentOnElement: "Comment on element / section",
83
+ groupContent: "Content",
84
+ groupLayout: "Layout",
85
+ groupSpacing: "Spacing",
86
+ groupStyle: "Style",
87
+ groupAdvanced: "Advanced",
88
+ otherAttributes: "Other attributes",
89
+ removeAttribute: "Remove",
90
+ resetToDefault: "Reset to default",
91
+ selectParent: "Select parent",
92
+ duplicate: "Duplicate",
93
+ deleteElement: "Delete",
94
+ multipleSelected: (count) => `${count} elements selected \u2014 select one to edit its settings.`,
95
+ editEachSide: "Edit each side",
96
+ increase: "Increase",
97
+ decrease: "Decrease",
98
+ changeUnit: (unit) => `Unit: ${unit}. Click to change`,
99
+ noUnit: "\xD7",
100
+ sidesVertical: "Top and bottom",
101
+ sidesHorizontal: "Left and right",
102
+ sideTop: "Top",
103
+ sideRight: "Right",
104
+ sideBottom: "Bottom",
105
+ sideLeft: "Left",
106
+ linkTypeProfile: "Your profile",
107
+ linkTypeShare: "Share this page",
108
+ allScreenSizes: "Changes apply to every screen size.",
109
+ columnWidths: "Column widths",
110
+ columnRatio: (ratio) => `Columns ${ratio}`,
111
+ socialNetworks: "Networks",
112
+ addNetwork: "Add network",
113
+ navbarLinks: "Links",
114
+ addLink: "Add link",
115
+ newLinkText: "Link",
116
+ inspectorLabels: {
117
+ // Fields
118
+ contentWidth: "Width",
119
+ pageBackground: "Page background",
120
+ "pageBackground.help": "Fills the area around and behind the email.",
121
+ fullWidth: "Full-width background",
122
+ "fullWidth.help": "The background reaches the window edges; the content keeps the email width.",
123
+ padding: "Padding",
124
+ backgroundColor: "Background",
125
+ backgroundImage: "Background image",
126
+ backgroundSize: "Image size",
127
+ backgroundRepeat: "Repeat image",
128
+ backgroundPosition: "Position",
129
+ cornerRadius: "Corners",
130
+ gap: "Space between sections",
131
+ border: "Border",
132
+ alignColumns: "Align columns",
133
+ "alignColumns.help": "Where the columns sit when they don't fill the row.",
134
+ reverseColumns: "Reverse column order",
135
+ "reverseColumns.help": "Swaps the columns on desktop; on phones they still stack in their original order.",
136
+ verticalAlign: "Vertical",
137
+ width: "Width",
138
+ innerBackground: "Inner background",
139
+ "innerBackground.help": "Fills only the area inside the padding, so it needs padding to show.",
140
+ innerCornerRadius: "Inner corners",
141
+ innerBorder: "Inner border",
142
+ align: "Alignment",
143
+ font: "Font",
144
+ fontSize: "Text size",
145
+ fontWeight: "Weight",
146
+ textColor: "Text color",
147
+ lineHeight: "Line height",
148
+ letterSpacing: "Letter spacing",
149
+ textTransform: "Capitalization",
150
+ blockBackground: "Block background",
151
+ "blockBackground.help": "Fills the whole block, including its padding.",
152
+ link: "Link",
153
+ buttonColor: "Button color",
154
+ buttonPadding: "Button padding",
155
+ "buttonPadding.help": "Space between the text and the button's edge; this sets the button's size.",
156
+ spaceAround: "Space around",
157
+ "spaceAround.help": "Empty space outside the button, between it and what is next to it.",
158
+ opensIn: "Opens in",
159
+ tooltip: "Tooltip",
160
+ rel: "Link relationship",
161
+ image: "Image",
162
+ altText: "Alt text",
163
+ "altText.help": "Read by screen readers and shown when images are blocked.",
164
+ fluidOnMobile: "Full width on mobile",
165
+ "fluidOnMobile.help": "On phones the image stretches across the screen, whatever its width here.",
166
+ lineColor: "Line color",
167
+ thickness: "Thickness",
168
+ lineStyle: "Line style",
169
+ height: "Height",
170
+ socialMode: "Direction",
171
+ iconSize: "Icon size",
172
+ iconSpacing: "Space around each icon",
173
+ network: "Network",
174
+ // Brand names are the same in every language and are not keys; these two are words.
175
+ networkWebsite: "Website",
176
+ networkCustom: "Custom",
177
+ customIcon: "Custom icon",
178
+ iconColor: "Icon color",
179
+ iconPosition: "Icon side",
180
+ heroMode: "Sizing",
181
+ "heroMode.help": "Fixed keeps the height you set; Fit image follows the background image's proportions.",
182
+ backgroundWidth: "Image width",
183
+ "backgroundWidth.help": "The background image's real size in pixels, so the hero keeps its proportions.",
184
+ backgroundHeight: "Image height",
185
+ fallbackColor: "Fallback color",
186
+ "fallbackColor.help": "Shown while the image loads, or when images are blocked.",
187
+ contentPadding: "Content padding",
188
+ contentBackground: "Content background",
189
+ hamburger: "Collapse into a menu on mobile",
190
+ "hamburger.help": "On phones the links fold into a menu button.",
191
+ menuIconColor: "Menu icon color",
192
+ menuIconSize: "Menu icon size",
193
+ menuIconAlign: "Menu icon align",
194
+ baseUrl: "Link prefix",
195
+ "baseUrl.help": "Added in front of every link in the bar, full addresses included, so links then give only the path.",
196
+ // Options
197
+ alignLeft: "Left",
198
+ alignCenter: "Center",
199
+ alignRight: "Right",
200
+ alignJustify: "Justify",
201
+ alignTop: "Top",
202
+ alignMiddle: "Middle",
203
+ alignBottom: "Bottom",
204
+ weightRegular: "Regular",
205
+ weightMedium: "Medium",
206
+ weightSemibold: "Semibold",
207
+ weightBold: "Bold",
208
+ caseNone: "As typed",
209
+ caseUpper: "UPPERCASE",
210
+ caseLower: "lowercase",
211
+ caseCapitalize: "Capitalize Each Word",
212
+ targetNewTab: "New tab",
213
+ targetSameTab: "Same tab",
214
+ sizeCover: "Fill",
215
+ sizeContain: "Fit",
216
+ sizeAuto: "Original",
217
+ repeatTile: "Tile",
218
+ repeatOnce: "Once",
219
+ positionTopLeft: "Top left",
220
+ positionTopCenter: "Top",
221
+ positionTopRight: "Top right",
222
+ positionCenterLeft: "Left",
223
+ positionCenter: "Center",
224
+ positionCenterRight: "Right",
225
+ positionBottomLeft: "Bottom left",
226
+ positionBottomCenter: "Bottom",
227
+ positionBottomRight: "Bottom right",
228
+ lineSolid: "Solid",
229
+ lineDashed: "Dashed",
230
+ lineDotted: "Dotted",
231
+ modeHorizontal: "In a row",
232
+ modeVertical: "Stacked",
233
+ heroFixed: "Fixed",
234
+ heroFluid: "Fit image"
235
+ },
44
236
  attributes: "Attributes",
45
237
  style: "Style",
46
238
  rteFont: "Font",
@@ -107,7 +299,10 @@ function mergeLabels(overrides) {
107
299
  return {
108
300
  ...DEFAULT_LABELS,
109
301
  ...overrides,
110
- toolLabels: { ...DEFAULT_LABELS.toolLabels, ...overrides.toolLabels }
302
+ toolLabels: { ...DEFAULT_LABELS.toolLabels, ...overrides.toolLabels },
303
+ blockLabels: { ...DEFAULT_LABELS.blockLabels, ...overrides.blockLabels },
304
+ elementNames: { ...DEFAULT_LABELS.elementNames, ...overrides.elementNames },
305
+ inspectorLabels: { ...DEFAULT_LABELS.inspectorLabels, ...overrides.inspectorLabels }
111
306
  };
112
307
  }
113
308
 
@@ -742,6 +937,7 @@ function EditorHeader({
742
937
  {
743
938
  title: labels.previewFrameTitle,
744
939
  srcDoc: preview,
940
+ sandbox: "allow-popups allow-popups-to-escape-sandbox",
745
941
  className: cn(
746
942
  "mx-auto block h-full min-h-[80vh] rounded-md border bg-white shadow-sm",
747
943
  state.device === "Mobile" ? "w-[375px]" : "w-full max-w-[720px]"
@@ -1928,4 +2124,4 @@ export {
1928
2124
  CanvasComments,
1929
2125
  STARTER_MJML
1930
2126
  };
1931
- //# sourceMappingURL=chunk-VJRKDFM4.js.map
2127
+ //# sourceMappingURL=chunk-FTEJNUJL.js.map