@ecomcx/ecomweb-editor 1.31.0 → 1.33.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/package.json +3 -3
- package/src/locales/en/attrs.ts +10 -0
- package/src/locales/en/background.ts +17 -0
- package/src/locales/en/bindings.ts +1 -1
- package/src/locales/en/block-desc.ts +2 -0
- package/src/locales/en/block-style.ts +7 -4
- package/src/locales/en/block-titles.ts +2 -0
- package/src/locales/en/blocks.ts +12 -3
- package/src/locales/en/columns.ts +12 -0
- package/src/locales/en/controls.ts +21 -0
- package/src/locales/en/hints.ts +289 -1
- package/src/locales/en/index.ts +5 -2
- package/src/locales/en/layout.ts +32 -0
- package/src/locales/en/legacy.ts +1 -1
- package/src/locales/en/library.ts +38 -0
- package/src/locales/en/parts.ts +12 -0
- package/src/locales/en/placeholders.ts +12 -1
- package/src/locales/en/presets.ts +6 -0
- package/src/locales/en/v2.ts +21 -0
- package/src/locales/vi/attrs.ts +10 -0
- package/src/locales/vi/background.ts +17 -0
- package/src/locales/vi/bindings.ts +1 -1
- package/src/locales/vi/block-desc.ts +2 -0
- package/src/locales/vi/block-style.ts +7 -4
- package/src/locales/vi/block-titles.ts +2 -0
- package/src/locales/vi/blocks.ts +12 -3
- package/src/locales/vi/columns.ts +12 -0
- package/src/locales/vi/controls.ts +21 -0
- package/src/locales/vi/hints.ts +290 -2
- package/src/locales/vi/index.ts +5 -2
- package/src/locales/vi/layout.ts +32 -0
- package/src/locales/vi/legacy.ts +1 -1
- package/src/locales/vi/library.ts +38 -0
- package/src/locales/vi/parts.ts +12 -0
- package/src/locales/vi/placeholders.ts +12 -1
- package/src/locales/vi/presets.ts +6 -0
- package/src/locales/vi/v2.ts +21 -0
- package/src/shared/panel-store.ts +3 -3
- package/src/shared/patterns.ts +3 -52
- package/src/shared/style-panel.tsx +2 -2
- package/src/shared/types.ts +2 -0
- package/src/v2/blocks/columns-inspector.tsx +210 -0
- package/src/v2/blocks/form.tsx +4 -4
- package/src/v2/blocks/index.ts +10 -4
- package/src/v2/blocks/inline-style.ts +1 -1
- package/src/v2/blocks/layout.tsx +211 -44
- package/src/v2/blocks/media.tsx +22 -13
- package/src/v2/blocks/resize.tsx +172 -4
- package/src/v2/blocks/text.tsx +14 -7
- package/src/v2/blocks/theme.tsx +63 -19
- package/src/v2/blocks/tools.tsx +50 -5
- package/src/v2/blocks/widgets.tsx +44 -16
- package/src/v2/canvas/block-list.tsx +23 -3
- package/src/v2/canvas/canvas-css.ts +70 -4
- package/src/v2/canvas/canvas.tsx +22 -5
- package/src/v2/canvas/dnd.ts +34 -3
- package/src/v2/canvas/move-animation.ts +94 -0
- package/src/v2/canvas/spacing-viz.ts +51 -0
- package/src/v2/core/block-presets.ts +68 -0
- package/src/v2/core/host.ts +6 -1
- package/src/v2/core/structure.ts +2 -1
- package/src/v2/editor.css +238 -9
- package/src/v2/editor.tsx +8 -2
- package/src/v2/ui/attr-form.tsx +59 -12
- package/src/v2/ui/attr-hints.ts +140 -9
- package/src/v2/ui/background-panel.tsx +65 -21
- package/src/v2/ui/bindings.tsx +3 -0
- package/src/v2/ui/block-icons.tsx +152 -0
- package/src/v2/ui/block-menu.ts +22 -0
- package/src/v2/ui/block-style-panel.tsx +14 -3
- package/src/v2/ui/color-field.tsx +74 -9
- package/src/v2/ui/divider-panel.tsx +58 -0
- package/src/v2/ui/group-width.tsx +38 -0
- package/src/v2/ui/icon-picker.tsx +51 -0
- package/src/v2/ui/inserter.tsx +61 -12
- package/src/v2/ui/inspector.tsx +48 -16
- package/src/v2/ui/layout-panel.tsx +5 -47
- package/src/v2/ui/list-view.tsx +81 -7
- package/src/v2/ui/motion-panel.tsx +2 -1
- package/src/v2/ui/parts-panel.tsx +164 -0
- package/src/v2/ui/pattern-library.tsx +228 -0
- package/src/v2/ui/preset-bar.tsx +83 -0
- package/src/v2/ui/style-controls.tsx +65 -15
- package/src/v2/ui/style-supports.ts +1 -1
- package/src/v2/ui/style-tab.tsx +127 -41
- package/src/v2/ui/toolbar.tsx +52 -13
- package/src/v2/ui/unit-controls.tsx +88 -39
- package/src/locales/en/patterns.ts +0 -50
- package/src/locales/vi/patterns.ts +0 -50
- package/src/shared/patterns-kit.ts +0 -7
- package/src/shared/patterns-library.ts +0 -172
package/src/locales/vi/hints.ts
CHANGED
|
@@ -58,6 +58,17 @@ export const hints = {
|
|
|
58
58
|
"button.variant.opt.primary": "Chính",
|
|
59
59
|
"button.variant.opt.secondary": "Phụ",
|
|
60
60
|
"button.variant.opt.outline": "Viền",
|
|
61
|
+
"button.text.placeholder": "Ví dụ: Mua ngay",
|
|
62
|
+
"button.href.placeholder": "https://… hoặc /duong-dan",
|
|
63
|
+
"button.iconPosition.opt.left": "Trái chữ",
|
|
64
|
+
"button.iconPosition.opt.right": "Phải chữ",
|
|
65
|
+
"button.width.opt.auto": "Vừa chữ",
|
|
66
|
+
"button.width.opt.full": "Hết khung",
|
|
67
|
+
"tabs.tabsAlign.opt.flex-start": "Trái",
|
|
68
|
+
"tabs.tabsAlign.opt.center": "Giữa",
|
|
69
|
+
"tabs.tabsAlign.opt.flex-end": "Phải",
|
|
70
|
+
"tabs.tabsAlign.opt.space-between": "Dàn đều",
|
|
71
|
+
"button.ariaLabel.help": "Đọc thay cho chữ trên nút khi chữ chưa đủ rõ (vd \"Xem thêm\" → \"Xem thêm về gói Pro\").",
|
|
61
72
|
"button.rel.help": "Vd: nofollow, sponsored (liên kết quảng cáo)",
|
|
62
73
|
"spacer.height.help": "Cỡ có sẵn của theme (xs → 2xl) hoặc độ dài (vd 3rem, 80px)",
|
|
63
74
|
"callout.tone.opt.info": "Thông tin",
|
|
@@ -149,6 +160,7 @@ export const hints = {
|
|
|
149
160
|
"navigation.overlayMenu.label": "Thu gọn thành nút menu",
|
|
150
161
|
"navigation.overlayMenu.opt.never": "Không",
|
|
151
162
|
"navigation.overlayMenu.opt.mobile": "Điện thoại",
|
|
163
|
+
"navigation.overlayMenu.opt.tablet": "Máy tính bảng",
|
|
152
164
|
"navigation.overlayMenu.opt.always": "Luôn luôn",
|
|
153
165
|
"search.showLabel.label": "Hiện nhãn",
|
|
154
166
|
"search.buttonPosition.label": "Vị trí nút",
|
|
@@ -226,7 +238,7 @@ export const hints = {
|
|
|
226
238
|
"iconList.icon.opt.info": "Thông tin",
|
|
227
239
|
"iconList.icon.opt.alert": "Cảnh báo",
|
|
228
240
|
"iconList.icon.opt.externalLink": "Liên kết ngoài",
|
|
229
|
-
"iconBox.position.label": "Vị trí icon",
|
|
241
|
+
"iconBox.position.label": "Vị trí icon / ảnh",
|
|
230
242
|
"iconBox.position.opt.top": "Trên",
|
|
231
243
|
"iconBox.position.opt.left": "Bên trái",
|
|
232
244
|
"imageBox.src.label": "Ảnh",
|
|
@@ -239,5 +251,281 @@ export const hints = {
|
|
|
239
251
|
"counter.duration.help": "0 = hiện ngay số cuối. Người dùng chọn giảm chuyển động luôn thấy số cuối.",
|
|
240
252
|
"iconList.layout.opt.list": "Dọc",
|
|
241
253
|
"iconList.layout.opt.inline": "Hàng ngang",
|
|
242
|
-
"
|
|
254
|
+
"tabs.orientation.label": "Bố cục tab",
|
|
255
|
+
"tabs.orientation.opt.horizontal": "Ngang",
|
|
256
|
+
"tabs.orientation.opt.vertical": "Dọc",
|
|
257
|
+
"tabs.mobileAccordion.label": "Thành accordion trên điện thoại",
|
|
258
|
+
"tab.subtitle.label": "Phụ đề",
|
|
259
|
+
"tab.icon.label": "Icon của tab",
|
|
260
|
+
"accordion.columns.label": "Số cột",
|
|
261
|
+
"accordion.columns.opt.1": "1 cột",
|
|
262
|
+
"accordion.columns.opt.2": "2 cột",
|
|
263
|
+
"accordion.icon.label": "Icon mở / đóng",
|
|
264
|
+
"accordion.icon.opt.arrow": "Mũi tên",
|
|
265
|
+
"accordion.icon.opt.plus": "Dấu cộng",
|
|
266
|
+
"accordion.icon.opt.none": "Không",
|
|
267
|
+
"accordion.iconSide.label": "Vị trí icon",
|
|
268
|
+
"accordion.iconSide.opt.left": "Trái",
|
|
269
|
+
"accordion.iconSide.opt.right": "Phải",
|
|
270
|
+
"accordion.titleTag.label": "Thẻ tiêu đề mục",
|
|
271
|
+
"accordion.titleTag.help": "Chọn h2–h6 khi tiêu đề mục là một phần dàn ý trang (SEO); thường để div.",
|
|
272
|
+
"accordion.faq.label": "Đánh dấu là Câu hỏi thường gặp (FAQ Schema)",
|
|
273
|
+
"accordion.faq.help": "Google có thể hiện câu hỏi – trả lời ngay trong kết quả tìm kiếm.",
|
|
274
|
+
"buttons.orientation.label": "Hướng xếp nút",
|
|
275
|
+
"buttons.orientation.opt.horizontal": "Ngang",
|
|
276
|
+
"buttons.orientation.opt.vertical": "Dọc",
|
|
277
|
+
"button.iconOnly.label": "Chỉ hiện icon (chữ thành nhãn cho trình đọc màn hình)",
|
|
278
|
+
"button.iconReveal.label": "Icon chỉ hiện khi rê chuột",
|
|
279
|
+
"countdown.layout.label": "Bố cục",
|
|
280
|
+
"countdown.layout.opt.block": "Ô vuông",
|
|
281
|
+
"countdown.layout.opt.inline": "Một dòng",
|
|
282
|
+
"countdown.divider.label": "Dấu \":\" giữa các ô",
|
|
283
|
+
"countdown.pad.label": "Số dạng 00",
|
|
284
|
+
"countdown.postText.label": "Chữ phía sau",
|
|
285
|
+
"countdown.showDays.label": "Hiện ngày",
|
|
286
|
+
"countdown.showSeconds.label": "Hiện giây",
|
|
287
|
+
"countdown.daysLabel.label": "Nhãn \"ngày\"",
|
|
288
|
+
"countdown.hoursLabel.label": "Nhãn \"giờ\"",
|
|
289
|
+
"countdown.minutesLabel.label": "Nhãn \"phút\"",
|
|
290
|
+
"countdown.secondsLabel.label": "Nhãn \"giây\"",
|
|
291
|
+
"progressBar.value.label": "Giá trị",
|
|
292
|
+
"progressBar.max.label": "Giá trị tối đa",
|
|
293
|
+
"progressBar.prefix.label": "Tiền tố của số",
|
|
294
|
+
"progressBar.suffix.label": "Hậu tố của số",
|
|
295
|
+
"progressBar.suffix.help": "Để trống = \"%\".",
|
|
296
|
+
"progressBar.textPosition.label": "Vị trí chữ",
|
|
297
|
+
"progressBar.textPosition.opt.above": "Trên thanh",
|
|
298
|
+
"progressBar.textPosition.opt.inside": "Trong thanh",
|
|
299
|
+
"progressBar.textPosition.opt.below": "Dưới thanh",
|
|
300
|
+
"progressBar.duration.label": "Thời gian chạy (ms)",
|
|
301
|
+
"progressBar.duration.help": "0 = hiện ngay. Người dùng chọn giảm chuyển động luôn thấy thanh đầy.",
|
|
302
|
+
"iconBox.position.opt.right": "Bên phải",
|
|
303
|
+
"iconBox.media.label": "Phần đầu hộp",
|
|
304
|
+
"iconBox.media.opt.icon": "Icon",
|
|
305
|
+
"iconBox.media.opt.number": "Số",
|
|
306
|
+
"iconBox.media.opt.none": "Không",
|
|
307
|
+
"iconBox.number.label": "Số hiển thị",
|
|
308
|
+
"iconBox.iconStyle.label": "Khung icon",
|
|
309
|
+
"iconBox.iconStyle.opt.plain": "Không khung",
|
|
310
|
+
"iconBox.iconStyle.opt.circle": "Tròn",
|
|
311
|
+
"iconBox.iconStyle.opt.square": "Vuông",
|
|
312
|
+
"iconBox.hover.label": "Hiệu ứng khi rê chuột",
|
|
313
|
+
"iconBox.hover.opt.none": "Không",
|
|
314
|
+
"iconBox.hover.opt.grow": "Phóng to",
|
|
315
|
+
"iconBox.hover.opt.flip": "Lật",
|
|
316
|
+
"iconBox.linkMode.label": "Liên kết đặt ở",
|
|
317
|
+
"iconBox.linkMode.opt.title": "Tiêu đề",
|
|
318
|
+
"iconBox.linkMode.opt.box": "Cả hộp",
|
|
319
|
+
"iconBox.linkMode.opt.button": "Nút \"Xem thêm\"",
|
|
320
|
+
"iconBox.buttonText.label": "Chữ trên nút",
|
|
321
|
+
"iconBox.buttonText.help": "Trống = mũi tên →",
|
|
322
|
+
"tableOfContents.minLevel.label": "Cấp nhỏ nhất",
|
|
323
|
+
"tableOfContents.collapsible.label": "Thu gọn được (bấm tiêu đề để mở / đóng)",
|
|
324
|
+
"tableOfContents.startCollapsed.label": "Bắt đầu ở trạng thái thu gọn",
|
|
325
|
+
"tableOfContents.listStyle.label": "Kiểu danh sách",
|
|
326
|
+
"tableOfContents.listStyle.opt.numbers": "Số",
|
|
327
|
+
"tableOfContents.listStyle.opt.bullets": "Chấm",
|
|
328
|
+
"tableOfContents.listStyle.opt.none": "Không",
|
|
329
|
+
"tableOfContents.columns.label": "Số cột",
|
|
330
|
+
"tableOfContents.columns.opt.1": "1",
|
|
331
|
+
"tableOfContents.columns.opt.2": "2",
|
|
332
|
+
"tableOfContents.columns.opt.3": "3",
|
|
333
|
+
"tableOfContents.smoothScroll.label": "Cuộn mượt tới mục",
|
|
334
|
+
"tableOfContents.highlight.label": "Tô đậm mục đang đọc",
|
|
335
|
+
"formField.width.opt.third": "1/3 hàng",
|
|
336
|
+
"formField.autocomplete.label": "Trình duyệt tự điền",
|
|
337
|
+
"formField.autocomplete.help": "Giúp người dùng điền nhanh trên điện thoại.",
|
|
338
|
+
"formField.autocomplete.opt.off": "Tắt",
|
|
339
|
+
"formField.autocomplete.opt.name": "Họ tên",
|
|
340
|
+
"formField.autocomplete.opt.given-name": "Tên",
|
|
341
|
+
"formField.autocomplete.opt.family-name": "Họ",
|
|
342
|
+
"formField.autocomplete.opt.email": "Email",
|
|
343
|
+
"formField.autocomplete.opt.tel": "Số điện thoại",
|
|
344
|
+
"formField.autocomplete.opt.organization": "Công ty",
|
|
345
|
+
"formField.autocomplete.opt.street-address": "Địa chỉ",
|
|
346
|
+
"formField.autocomplete.opt.address-level1": "Tỉnh / thành",
|
|
347
|
+
"formField.autocomplete.opt.address-level2": "Quận / huyện",
|
|
348
|
+
"formField.autocomplete.opt.postal-code": "Mã bưu chính",
|
|
349
|
+
"formField.autocomplete.opt.country-name": "Quốc gia",
|
|
350
|
+
"formField.autocomplete.opt.bday": "Ngày sinh",
|
|
351
|
+
"form.notifyCc.label": "Đồng gửi (Cc)",
|
|
352
|
+
"form.notifyCc.help": "Nhiều email cách nhau bằng dấu phẩy, tối đa 5. Ô \"Email nhận\" cũng nhận nhiều địa chỉ.",
|
|
353
|
+
"form.emailSubject.label": "Tiêu đề email báo",
|
|
354
|
+
"form.emailSubject.help": "Để trống: \"[Tên website] Bài gửi mới: tên form\".",
|
|
355
|
+
"form.redirect.label": "Chuyển tới trang sau khi gửi",
|
|
356
|
+
"form.redirect.help": "Vd /cam-on. Để trống: hiện lời cảm ơn ngay dưới form.",
|
|
357
|
+
"icon.stroke.label": "Độ dày nét",
|
|
358
|
+
"icon.iconStyle.label": "Khung icon",
|
|
359
|
+
"icon.iconStyle.opt.plain": "Không khung",
|
|
360
|
+
"icon.iconStyle.opt.circle": "Tròn",
|
|
361
|
+
"icon.iconStyle.opt.square": "Vuông",
|
|
362
|
+
"icon.linkTarget.label": "Mở liên kết",
|
|
363
|
+
"icon.linkTarget.opt._self": "Cùng tab",
|
|
364
|
+
"icon.linkTarget.opt._blank": "Tab mới",
|
|
365
|
+
"iconList.columns.label": "Số cột",
|
|
366
|
+
"iconList.iconAlign.label": "Căn icon với chữ",
|
|
367
|
+
"iconList.iconAlign.opt.top": "Trên",
|
|
368
|
+
"iconList.iconAlign.opt.center": "Giữa",
|
|
369
|
+
"iconList.iconAlign.opt.bottom": "Dưới",
|
|
370
|
+
"iconList.iconStyle.label": "Khung icon",
|
|
371
|
+
"iconList.iconStyle.opt.plain": "Không khung",
|
|
372
|
+
"iconList.iconStyle.opt.circle": "Tròn",
|
|
373
|
+
"iconList.iconStyle.opt.square": "Vuông",
|
|
374
|
+
"iconList.stroke.label": "Độ dày nét",
|
|
375
|
+
"iconBox.media.opt.image": "Ảnh",
|
|
376
|
+
"iconBox.src.label": "Ảnh",
|
|
377
|
+
"iconBox.verticalAlign.label": "Căn dọc với chữ",
|
|
378
|
+
"iconBox.verticalAlign.opt.top": "Trên",
|
|
379
|
+
"iconBox.verticalAlign.opt.center": "Giữa",
|
|
380
|
+
"iconBox.verticalAlign.opt.bottom": "Dưới",
|
|
381
|
+
"iconBox.fullHeight.label": "Cao bằng ô chứa",
|
|
382
|
+
"iconBox.fullHeight.help": "Các hộp đặt cạnh nhau trong cột sẽ cao bằng nhau",
|
|
383
|
+
"testimonial.variant.label": "Kiểu",
|
|
384
|
+
"testimonial.variant.opt.card": "Thẻ",
|
|
385
|
+
"testimonial.variant.opt.plain": "Trơn",
|
|
386
|
+
"testimonial.variant.opt.bubble": "Bong bóng",
|
|
387
|
+
"testimonial.rating.label": "Sao đánh giá",
|
|
388
|
+
"testimonial.rating.help": "0 = không hiện sao",
|
|
389
|
+
"testimonial.quoteMark.label": "Hiện dấu trích ở đầu",
|
|
390
|
+
"counter.decimals.label": "Số chữ thập phân",
|
|
391
|
+
"counter.decimals.help": "Trống = theo số đã nhập (tối đa 3)",
|
|
392
|
+
"counter.titleTag.label": "Thẻ HTML của tiêu đề",
|
|
393
|
+
"counter.titleTag.opt.p": "Đoạn văn (p)",
|
|
394
|
+
"counter.titleTag.opt.div": "div",
|
|
395
|
+
"counter.titleTag.opt.h2": "H2",
|
|
396
|
+
"counter.titleTag.opt.h3": "H3",
|
|
397
|
+
"counter.titleTag.opt.h4": "H4",
|
|
398
|
+
"counter.titleTag.opt.h5": "H5",
|
|
399
|
+
"counter.titleTag.opt.h6": "H6",
|
|
400
|
+
"progressBar.decimals.label": "Số chữ thập phân",
|
|
401
|
+
"progressBar.decimals.opt.0": "1",
|
|
402
|
+
"progressBar.decimals.opt.1": "0,1",
|
|
403
|
+
"progressBar.decimals.opt.2": "0,01",
|
|
404
|
+
"progressBar.animate.label": "Chạy từ 0 khi cuộn tới",
|
|
405
|
+
"progressBar.easing.label": "Kiểu chạy",
|
|
406
|
+
"progressBar.easing.opt.ease": "Mặc định",
|
|
407
|
+
"progressBar.easing.opt.linear": "Đều",
|
|
408
|
+
"progressBar.easing.opt.ease-in": "Chậm rồi nhanh",
|
|
409
|
+
"progressBar.easing.opt.ease-out": "Nhanh rồi chậm",
|
|
410
|
+
"progressBar.easing.opt.ease-in-out": "Chậm ở hai đầu",
|
|
411
|
+
"progressBar.ariaLabel.label": "Nhãn cho trình đọc màn hình",
|
|
412
|
+
"progressBar.ariaLabel.help": "Trống = dùng nhãn của thanh",
|
|
413
|
+
"accordion.startOpen.label": "Mở sẵn khi tải trang",
|
|
414
|
+
"accordion.startOpen.help": "Mục nào đã tự bật \"Mở sẵn\" thì giữ nguyên. Nhóm \"mở một mục\" chỉ mở được mục đầu.",
|
|
415
|
+
"accordion.startOpen.opt.none": "Đóng hết",
|
|
416
|
+
"accordion.startOpen.opt.first": "Mục đầu",
|
|
417
|
+
"accordion.startOpen.opt.all": "Tất cả",
|
|
418
|
+
"tabs.iconPosition.label": "Vị trí icon",
|
|
419
|
+
"tabs.iconPosition.opt.left": "Trái",
|
|
420
|
+
"tabs.iconPosition.opt.right": "Phải",
|
|
421
|
+
"tabs.iconPosition.opt.top": "Trên",
|
|
422
|
+
"tabs.iconOnly.label": "Chỉ hiện icon",
|
|
423
|
+
"tabs.iconOnly.help": "Chữ của tab có icon được ẩn (vẫn dành cho trình đọc màn hình); tab không có icon vẫn hiện chữ",
|
|
424
|
+
"tableOfContents.showTitle.label": "Hiện tiêu đề",
|
|
425
|
+
"search.scopeSelect.label": "Ô chọn phạm vi tìm kiếm",
|
|
426
|
+
"search.scopeSelect.help": "Khách chọn tìm trong Tất cả hoặc từng loại nội dung (sản phẩm, bài viết…)",
|
|
427
|
+
"search.scopes.label": "Các loại để chọn",
|
|
428
|
+
"search.scopes.help": "Mỗi loại một mục, dạng mã:nhãn, cách nhau bằng dấu phẩy. Ví dụ: product:Sản phẩm, post:Tin tức, page:Trang",
|
|
429
|
+
"query.taxonomy.label": "Phân loại",
|
|
430
|
+
"query.taxonomy.help": "Lọc theo phân loại khác chuyên mục / thẻ, ví dụ danh mục sản phẩm (product_cat)",
|
|
431
|
+
"query.term.label": "Mục của phân loại",
|
|
432
|
+
"postTemplate.layout.opt.carousel": "Cuộn ngang",
|
|
433
|
+
"postTemplate.gap.label": "Khoảng cách giữa các thẻ",
|
|
434
|
+
"postTemplate.gap.help": "Cỡ như sm, md, lg hoặc độ dài như 16px. Để trống = 1.5rem",
|
|
435
|
+
"postTemplate.arrows.label": "Hiện nút trước / sau",
|
|
436
|
+
"postTemplate.columnsTablet.label": "Số cột trên máy tính bảng",
|
|
437
|
+
"postTemplate.columnsMobile.label": "Số cột trên điện thoại",
|
|
438
|
+
"search.collapse.label": "Thu gọn thành nút kính lúp",
|
|
439
|
+
"search.collapse.help": "Trên màn hình nhỏ chỉ hiện nút kính lúp, bấm mới mở ô nhập (khỏi phải đặt hai khối Tìm kiếm cho máy tính và điện thoại)",
|
|
440
|
+
"search.collapse.opt.never": "Không",
|
|
441
|
+
"search.collapse.opt.tablet": "Từ tablet",
|
|
442
|
+
"search.collapse.opt.mobile": "Điện thoại",
|
|
443
|
+
"query.source.label": "Nguồn bài",
|
|
444
|
+
"query.source.opt.latest": "Mới nhất",
|
|
445
|
+
"query.source.opt.manual": "Chọn tay",
|
|
446
|
+
"query.source.opt.related": "Liên quan",
|
|
447
|
+
"query.include.label": "Mã bài (chọn tay)",
|
|
448
|
+
"query.include.help": "Các mã bài cách nhau dấu phẩy, hiện đúng thứ tự này",
|
|
449
|
+
"query.include.placeholder": "12, 7, 31",
|
|
450
|
+
"query.terms.label": "Mục của phân loại",
|
|
451
|
+
"query.termMode.label": "Cách lọc",
|
|
452
|
+
"query.termMode.opt.any": "Bất kỳ mục",
|
|
453
|
+
"query.termMode.opt.all": "Đủ mọi mục",
|
|
454
|
+
"query.termMode.opt.none": "Loại trừ",
|
|
455
|
+
"query.metaKey.label": "Trường tuỳ biến",
|
|
456
|
+
"query.metaKey.help": "Lọc theo giá trị của một trường tuỳ biến (ACF…)",
|
|
457
|
+
"query.metaKey.placeholder": "gia_ban",
|
|
458
|
+
"query.metaCompare.label": "So sánh",
|
|
459
|
+
"query.metaValue.label": "Giá trị",
|
|
460
|
+
"query.dateRange.label": "Đăng trong",
|
|
461
|
+
"query.dateRange.opt.any": "Mọi lúc",
|
|
462
|
+
"query.dateRange.opt.7": "7 ngày qua",
|
|
463
|
+
"query.dateRange.opt.30": "30 ngày qua",
|
|
464
|
+
"query.dateRange.opt.90": "90 ngày qua",
|
|
465
|
+
"query.dateRange.opt.365": "Năm qua",
|
|
466
|
+
"query.after.label": "Từ ngày",
|
|
467
|
+
"query.after.placeholder": "2026-01-31",
|
|
468
|
+
"query.before.label": "Đến ngày",
|
|
469
|
+
"query.before.placeholder": "2026-12-31",
|
|
470
|
+
"query.parent.label": "Bài con của mã",
|
|
471
|
+
"query.parent.help": "Chỉ lấy bài có cha là trang / bài này (mã bài)",
|
|
472
|
+
"query.offset.label": "Bỏ qua N bài đầu",
|
|
473
|
+
"query.offset.help": "Hữu ích khi bài nổi bật đã hiện ở khối khác",
|
|
474
|
+
"query.excludeCurrent.label": "Bỏ bài đang xem",
|
|
475
|
+
"query.excludeCurrent.help": "Trên trang bài viết / sản phẩm, không lặp lại chính bài đó trong danh sách",
|
|
476
|
+
"query.authorCurrent.label": "Cùng tác giả với bài đang xem",
|
|
477
|
+
"query.urlFilters.label": "Nhận bộ lọc từ thanh lọc",
|
|
478
|
+
"query.urlFilters.help": "Khối Thanh lọc trên trang (tìm, mục, sắp xếp) sẽ lọc danh sách này",
|
|
479
|
+
"queryFilter.taxonomy.label": "Phân loại",
|
|
480
|
+
"queryFilter.taxonomy.help": "Danh mục để lọc, ví dụ danh mục sản phẩm",
|
|
481
|
+
"queryFilter.termStyle.label": "Kiểu hiện mục",
|
|
482
|
+
"queryFilter.termStyle.opt.none": "Không",
|
|
483
|
+
"queryFilter.termStyle.opt.links": "Liên kết",
|
|
484
|
+
"queryFilter.termStyle.opt.chips": "Nút lọc",
|
|
485
|
+
"queryFilter.termStyle.opt.select": "Ô chọn",
|
|
486
|
+
"queryFilter.allLabel.label": "Chữ mục Tất cả",
|
|
487
|
+
"queryFilter.allLabel.placeholder": "Tất cả",
|
|
488
|
+
"queryFilter.showSearch.label": "Có ô tìm",
|
|
489
|
+
"queryFilter.showSort.label": "Có ô sắp xếp",
|
|
490
|
+
"queryFilter.sortOptions.label": "Các cách sắp xếp",
|
|
491
|
+
"queryFilter.sortOptions.help": "Chọn trong: date_desc, date_asc, title_asc, title_desc, modified_desc, rand",
|
|
492
|
+
"queryFilter.sortOptions.placeholder": "date_desc,date_asc,title_asc",
|
|
493
|
+
"queryFilter.placeholder.label": "Chữ gợi ý ô tìm",
|
|
494
|
+
"queryFilter.submitText.label": "Chữ nút lọc",
|
|
495
|
+
"queryFilter.action.label": "Trang nhận bộ lọc",
|
|
496
|
+
"queryFilter.action.help": "Để trống = chính trang này",
|
|
497
|
+
"queryFilter.action.placeholder": "/product",
|
|
498
|
+
"search.buttonStyle.label": "Kiểu nút",
|
|
499
|
+
"search.buttonStyle.opt.text": "Chữ",
|
|
500
|
+
"search.buttonStyle.opt.icon": "Icon kính lúp",
|
|
501
|
+
"gallery.layout.label": "Kiểu xếp",
|
|
502
|
+
"gallery.layout.opt.grid": "Lưới đều",
|
|
503
|
+
"gallery.layout.opt.masonry": "Masonry",
|
|
504
|
+
"form.inputSize.label": "Cỡ ô nhập",
|
|
505
|
+
"form.inputSize.opt.sm": "Nhỏ",
|
|
506
|
+
"form.inputSize.opt.md": "Vừa",
|
|
507
|
+
"form.inputSize.opt.lg": "Lớn",
|
|
508
|
+
"map.address.label": "Địa chỉ",
|
|
509
|
+
"map.address.help": "Gõ địa chỉ hoặc tên nơi chốn (vd: 1 Phạm Văn Đồng, Hà Nội)",
|
|
510
|
+
"map.title.label": "Mô tả bản đồ",
|
|
511
|
+
"map.title.help": "Dành cho trình đọc màn hình; trống = dùng địa chỉ",
|
|
512
|
+
"map.zoom.label": "Mức phóng",
|
|
513
|
+
"map.height.label": "Chiều cao",
|
|
514
|
+
"map.mapType.label": "Kiểu bản đồ",
|
|
515
|
+
"map.mapType.opt.roadmap": "Đường phố",
|
|
516
|
+
"map.mapType.opt.satellite": "Vệ tinh",
|
|
517
|
+
"paragraph.icon.label": "Icon cạnh chữ",
|
|
518
|
+
"paragraph.iconPosition.label": "Vị trí icon",
|
|
519
|
+
"paragraph.iconPosition.opt.left": "Trái chữ",
|
|
520
|
+
"paragraph.iconPosition.opt.right": "Phải chữ",
|
|
521
|
+
"paragraph.iconTitle.label": "Chú thích icon",
|
|
522
|
+
"paragraph.iconTitle.help": "Hiện khi rê chuột vào đoạn văn.",
|
|
523
|
+
"heading.icon.label": "Icon cạnh chữ",
|
|
524
|
+
"heading.iconPosition.label": "Vị trí icon",
|
|
525
|
+
"heading.iconPosition.opt.left": "Trái chữ",
|
|
526
|
+
"heading.iconPosition.opt.right": "Phải chữ",
|
|
527
|
+
"heading.iconTitle.label": "Chú thích icon",
|
|
528
|
+
"heading.iconTitle.help": "Hiện khi rê chuột vào tiêu đề.",
|
|
529
|
+
"heading.tocTitle.label": "Tên trong mục lục",
|
|
530
|
+
"heading.tocTitle.help": "Để trống thì mục lục dùng chính chữ của tiêu đề.",
|
|
243
531
|
};
|
package/src/locales/vi/index.ts
CHANGED
|
@@ -12,6 +12,9 @@ import { blockDesc } from "./block-desc";
|
|
|
12
12
|
import { blockTitles } from "./block-titles";
|
|
13
13
|
import { blocks } from "./blocks";
|
|
14
14
|
import { controls } from "./controls";
|
|
15
|
+
import { parts } from "./parts";
|
|
16
|
+
import { columns } from "./columns";
|
|
17
|
+
import { presets } from "./presets";
|
|
15
18
|
import { hints } from "./hints";
|
|
16
19
|
import { layout } from "./layout";
|
|
17
20
|
import { legacyBasic } from "./legacy-basic";
|
|
@@ -20,8 +23,8 @@ import { motion } from "./motion";
|
|
|
20
23
|
import { background } from "./background";
|
|
21
24
|
import { blockStyle } from "./block-style";
|
|
22
25
|
import { patternLib } from "./pattern-lib";
|
|
23
|
-
import { patterns } from "./patterns";
|
|
24
26
|
import { shortcuts } from "./shortcuts";
|
|
25
27
|
import { placeholders } from "./placeholders";
|
|
28
|
+
import { library } from "./library";
|
|
26
29
|
|
|
27
|
-
export const vi = { v2, legacy, attrs, background, bindings, blockStyle, blockDesc, blockTitles, blocks, controls, hints, layout, legacyBasic, legacyDynamic, motion,
|
|
30
|
+
export const vi = { v2, legacy, attrs, background, bindings, blockStyle, blockDesc, blockTitles, blocks, controls, columns, hints, parts, presets, layout, legacyBasic, legacyDynamic, motion, library, patternLib, placeholders, shortcuts };
|
package/src/locales/vi/layout.ts
CHANGED
|
@@ -34,4 +34,36 @@ export const layout = {
|
|
|
34
34
|
between: "Dàn đều",
|
|
35
35
|
stretch: "Kéo giãn",
|
|
36
36
|
custom: "Tuỳ chỉnh",
|
|
37
|
+
groupWidth: "Độ rộng",
|
|
38
|
+
blockWidth: "Độ rộng khối",
|
|
39
|
+
bwContent: "Nội dung",
|
|
40
|
+
bwWide: "Rộng",
|
|
41
|
+
bwFull: "Đầy màn",
|
|
42
|
+
contentWidth: "Độ rộng nội dung bên trong",
|
|
43
|
+
cwFill: "Hết khối",
|
|
44
|
+
cwSite: "Theo website",
|
|
45
|
+
cwCustom: "Tự nhập",
|
|
46
|
+
cwHelp: "Chữ và khối bên trong được canh giữa theo độ rộng này; khung ngoài vẫn phủ hết bề ngang.",
|
|
47
|
+
cwValue: "Độ rộng nội dung",
|
|
48
|
+
dividerTitle: "Đường chia",
|
|
49
|
+
dividerTop: "Đường chia trên",
|
|
50
|
+
dividerBottom: "Đường chia dưới",
|
|
51
|
+
dividerNone: "Không",
|
|
52
|
+
dividerColor: "Màu (của khối kế bên)",
|
|
53
|
+
dividerHeight: "Cao",
|
|
54
|
+
dividerFlip: "Lật ngang",
|
|
55
|
+
dividerHelp: "Hình tô ở mép khối, dùng màu của khối nằm kế bên để hai khối nối liền mềm mại.",
|
|
56
|
+
divider_wave: "Sóng",
|
|
57
|
+
divider_curve: "Vòm",
|
|
58
|
+
divider_tilt: "Vát",
|
|
59
|
+
divider_triangle: "Tam giác",
|
|
60
|
+
divider_zigzag: "Răng cưa",
|
|
61
|
+
textShadow: "Bóng chữ",
|
|
62
|
+
tsX: "Lệch ngang",
|
|
63
|
+
tsY: "Lệch dọc",
|
|
64
|
+
tsBlur: "Độ nhoè",
|
|
65
|
+
tsColor: "Màu bóng",
|
|
66
|
+
writingMode: "Hướng chữ",
|
|
67
|
+
wmHorizontal: "Ngang",
|
|
68
|
+
wmVertical: "Dọc",
|
|
37
69
|
};
|
package/src/locales/vi/legacy.ts
CHANGED
|
@@ -26,7 +26,7 @@ export const legacy = {
|
|
|
26
26
|
resizeColumns: "Kéo để đổi độ rộng cột", dragPadding: "Kéo để đổi khoảng đệm",
|
|
27
27
|
style_typography: "Kiểu chữ", style_fontFamily: "Phông chữ", style_fontSize: "Cỡ chữ", style_appearance: "Giao diện", style_lineHeight: "Giãn dòng",
|
|
28
28
|
style_letterSpacing: "Giãn cách ký tự", style_decoration: "Trang trí", style_transform: "Viết hoa chữ cái", style_textAlign: "Căn chữ",
|
|
29
|
-
style_color: "Màu", style_text: "Chữ", style_background: "Nền", style_spacing: "
|
|
29
|
+
style_color: "Màu", style_text: "Chữ", style_textGradient: "Chữ chuyển màu", style_link: "Màu liên kết", style_linkHover: "Liên kết khi rê", style_background: "Nền", style_spacing: "Khoảng cách", style_padding: "Khoảng đệm (padding)",
|
|
30
30
|
style_margin: "Lề ngoài (margin)", style_gap: "Khoảng cách giữa khối con", style_width: "Chiều rộng", style_maxWidth: "Rộng tối đa", style_minHeight: "Cao tối thiểu",
|
|
31
31
|
style_border: "Viền & bo góc", style_borderWidth: "Độ dày viền", style_borderStyle: "Kiểu viền", style_borderColor: "Màu viền", style_radius: "Bo góc",
|
|
32
32
|
style_visibility: "Hiển thị", style_hide: "Ẩn theo khổ màn hình", hide_desktop: "Ẩn trên máy tính", hide_tablet: "Ẩn trên máy tính bảng", hide_mobile: "Ẩn trên điện thoại",
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/** Thư viện mẫu (hộp lớn): mẫu section, trang dựng sẵn, kiểu màu, chữ do AI viết. */
|
|
2
|
+
export const library = {
|
|
3
|
+
open: "Thư viện mẫu",
|
|
4
|
+
title: "Thư viện mẫu",
|
|
5
|
+
byDesign: "Theo thiết kế",
|
|
6
|
+
withAi: "Tạo bằng AI",
|
|
7
|
+
patterns: "Mẫu",
|
|
8
|
+
pages: "Trang",
|
|
9
|
+
categories: "Danh mục",
|
|
10
|
+
all: "Tất cả",
|
|
11
|
+
scheme: "Kiểu màu",
|
|
12
|
+
scheme_light: "Sáng",
|
|
13
|
+
scheme_dark: "Tối",
|
|
14
|
+
scheme_brand: "Màu thương hiệu",
|
|
15
|
+
searchPatterns: "Tìm mẫu",
|
|
16
|
+
searchPages: "Tìm trang",
|
|
17
|
+
countPatterns: "mẫu",
|
|
18
|
+
countPages: "trang",
|
|
19
|
+
sections: "phần",
|
|
20
|
+
page_home: "Trang chủ",
|
|
21
|
+
page_home2: "Trang chủ 2",
|
|
22
|
+
page_about: "Giới thiệu",
|
|
23
|
+
page_services: "Dịch vụ",
|
|
24
|
+
page_contact: "Liên hệ",
|
|
25
|
+
page_team: "Đội ngũ",
|
|
26
|
+
aiName: "Tên doanh nghiệp",
|
|
27
|
+
aiIndustry: "Ngành nghề",
|
|
28
|
+
aiAbout: "Giới thiệu ngắn",
|
|
29
|
+
aiTone: "Giọng văn",
|
|
30
|
+
tone_friendly: "Thân thiện",
|
|
31
|
+
tone_professional: "Chuyên nghiệp",
|
|
32
|
+
tone_luxury: "Sang trọng",
|
|
33
|
+
tone_youthful: "Trẻ trung",
|
|
34
|
+
aiRun: "Viết chữ cho các mẫu đang xem",
|
|
35
|
+
aiWorking: "AI đang viết…",
|
|
36
|
+
aiFailed: "Một vài mẫu chưa viết được — thử lại.",
|
|
37
|
+
aiBrief: "Bạn viết lại chữ cho một mẫu trang web của doanh nghiệp dưới đây. Đầu vào là mảng JSON các đoạn chữ theo thứ tự; trả về DUY NHẤT một mảng JSON cùng số phần tử, mỗi phần tử là chữ mới cùng vai trò và độ dài tương đương (tiêu đề ngắn vẫn ngắn, chữ nút 1–3 từ). Không thêm giải thích.",
|
|
38
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/** Phần của khối (content 1.26 PartSpec) và ô của phần. */
|
|
2
|
+
export const parts = {
|
|
3
|
+
box: "Khung", icon: "Icon", title: "Tiêu đề", text: "Mô tả", image: "Ảnh", quote: "Lời trích", avatar: "Ảnh đại diện", name: "Tên", role: "Chức danh",
|
|
4
|
+
quoteMark: "Dấu trích", rating: "Sao đánh giá", required: "Dấu * bắt buộc", help: "Gợi ý dưới ô", error: "Báo lỗi", success: "Báo thành công", input: "Ô nhập", map: "Khung bản đồ", number: "Số", label: "Nhãn", track: "Nền thanh", bar: "Thanh", item: "Mục",
|
|
5
|
+
paneTitle: "Tiêu đề mục", paneContent: "Nội dung mục", tabList: "Thanh tab", tab: "Nút tab", panel: "Nội dung tab", button: "Nút", caption: "Chú thích",
|
|
6
|
+
tableHead: "Ô tiêu đề", tableCell: "Ô thường", unitBox: "Ô thời gian", unitLabel: "Chữ đơn vị", content: "Vùng nội dung",
|
|
7
|
+
highlight: "Chữ tô sáng", link: "Liên kết", active: "Đang mở / chọn",
|
|
8
|
+
show: "Hiện phần này", hiddenNote: "Đang ẩn — bật công tắc để hiện và chỉnh.", normal: "Thường", hover: "Rê chuột",
|
|
9
|
+
fontSize: "Cỡ chữ", weight: "Độ đậm", align: "Căn chữ", left: "Trái", center: "Giữa", right: "Phải", iconSize: "Cỡ icon",
|
|
10
|
+
color: "Màu chữ", iconColor: "Màu icon", background: "Nền", textGradient: "Chữ chuyển màu", gradient: "Nền chuyển màu", borderWidth: "Độ dày viền", borderColor: "Màu viền", radius: "Bo góc", shadow: "Bóng", none: "Không",
|
|
11
|
+
width: "Rộng", height: "Cao", padding: "Đệm", margin: "Lề",
|
|
12
|
+
};
|
|
@@ -25,11 +25,16 @@ export const placeholders = {
|
|
|
25
25
|
calloutTitle: "Tiêu đề (không bắt buộc)…",
|
|
26
26
|
code: "// Dán hoặc gõ mã…",
|
|
27
27
|
preformatted: "Văn bản giữ nguyên khoảng trắng…",
|
|
28
|
-
buttonText: "
|
|
28
|
+
buttonText: "Chữ trên nút",
|
|
29
29
|
tabTitle: "Tên tab…",
|
|
30
30
|
addTab: "Thêm tab",
|
|
31
|
+
moveTabLeft: "Dời tab đang mở sang trái",
|
|
32
|
+
moveTabRight: "Dời tab đang mở sang phải",
|
|
31
33
|
addItem: "Thêm mục",
|
|
32
34
|
addSlide: "Thêm slide",
|
|
35
|
+
slide: "Slide",
|
|
36
|
+
prevSlide: "Slide trước",
|
|
37
|
+
nextSlide: "Slide sau",
|
|
33
38
|
addImage: "Thêm ảnh",
|
|
34
39
|
addRow: "Thêm dòng",
|
|
35
40
|
addField: "Thêm ô",
|
|
@@ -37,6 +42,8 @@ export const placeholders = {
|
|
|
37
42
|
languageAuto: "Tự nhận",
|
|
38
43
|
startAt: "Bắt đầu từ",
|
|
39
44
|
chooseLayout: "Chọn kiểu bố cục",
|
|
45
|
+
chooseColumns: "Chọn bố cục cột",
|
|
46
|
+
skip: "Bỏ qua",
|
|
40
47
|
layoutStack: "Xếp dọc",
|
|
41
48
|
layoutRow: "Hàng ngang",
|
|
42
49
|
layoutGrid: "Lưới",
|
|
@@ -92,4 +99,8 @@ export const placeholders = {
|
|
|
92
99
|
serverEmpty: "Website chưa vẽ gì cho khối này ở trang mẫu",
|
|
93
100
|
otherSettings: "Kiểu hiển thị và thuộc tính khác: thanh bên › Khối.",
|
|
94
101
|
openSettings: "Mở cài đặt",
|
|
102
|
+
cdDays: "ngày", cdHours: "giờ", cdMinutes: "phút", cdSeconds: "giây",
|
|
103
|
+
"mapAddress": "Gõ địa chỉ để hiện bản đồ…",
|
|
104
|
+
countdownZone: "Múi giờ",
|
|
105
|
+
countdownZoneLocal: "Theo máy người xem",
|
|
95
106
|
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/** Kiểu đặt sẵn + mặc định khi chèn (hàng "Kiểu" đầu bảng). */
|
|
2
|
+
export const presets = {
|
|
3
|
+
label: "Kiểu", default: "Mặc định", edited: "(đã chỉnh)", presets: "Kiểu của khối này", toDefault: "Về kiểu mặc định", remove: "Xoá kiểu",
|
|
4
|
+
saveNew: "Lưu kiểu hiện tại thành kiểu mới…", namePlaceholder: "Tên kiểu, vd Thẻ nổi", save: "Lưu", makeDefault: "Đặt kiểu hiện tại làm mặc định khi chèn",
|
|
5
|
+
defaultHint: "Áp cho khối loại này chèn từ nay về sau trên cả website. Không đổi khối đã có, không lưu chữ.",
|
|
6
|
+
};
|
package/src/locales/vi/v2.ts
CHANGED
|
@@ -20,8 +20,26 @@ export const v2 = {
|
|
|
20
20
|
insertAfter: "Thêm khối phía dưới",
|
|
21
21
|
group: "Gom vào nhóm",
|
|
22
22
|
ungroup: "Bỏ nhóm",
|
|
23
|
+
cut: "Cắt",
|
|
24
|
+
rename: "Đổi tên",
|
|
25
|
+
renameTitle: "Đổi tên khối",
|
|
26
|
+
hide: "Ẩn",
|
|
27
|
+
show: "Hiện lại",
|
|
28
|
+
hidden: "Đang ẩn",
|
|
29
|
+
outline: "Dàn ý",
|
|
30
|
+
outlineChars: "Ký tự",
|
|
31
|
+
outlineWords: "Từ",
|
|
32
|
+
outlineTime: "Đọc",
|
|
33
|
+
outlineMinutes: "phút",
|
|
34
|
+
outlineEmpty: "(Tiêu đề trống)",
|
|
35
|
+
outlineSkipped: "(nhảy cấp tiêu đề)",
|
|
36
|
+
outlineNone: "Chưa có tiêu đề nào. Tiêu đề giúp người đọc và Google hiểu bố cục trang.",
|
|
37
|
+
mediaTab: "Media",
|
|
38
|
+
searchMedia: "Tìm trong thư viện",
|
|
39
|
+
audio: "Âm thanh",
|
|
23
40
|
copy: "Sao chép",
|
|
24
41
|
copyStyle: "Chép kiểu dáng",
|
|
42
|
+
copyPasteStyle: "Chép / dán kiểu dáng",
|
|
25
43
|
pasteStyle: "Dán kiểu dáng",
|
|
26
44
|
styleCopied: "Đã chép kiểu dáng",
|
|
27
45
|
blockMenu: "Thao tác với khối",
|
|
@@ -42,6 +60,9 @@ export const v2 = {
|
|
|
42
60
|
unlink: "Bỏ liên kết",
|
|
43
61
|
linkUrl: "Địa chỉ liên kết",
|
|
44
62
|
openNewTab: "Mở tab mới",
|
|
63
|
+
buttonLink: "Liên kết của nút",
|
|
64
|
+
buttonsAlign: "Căn các nút",
|
|
65
|
+
spaceBetween: "Dàn đều hai đầu",
|
|
45
66
|
apply: "Áp dụng",
|
|
46
67
|
cancel: "Huỷ",
|
|
47
68
|
alignLeft: "Căn trái",
|
|
@@ -19,8 +19,8 @@ export interface BlockPanel {
|
|
|
19
19
|
title: string;
|
|
20
20
|
/** Loại khối áp dụng; bỏ trống hoặc "*" = mọi khối. */
|
|
21
21
|
blocks?: string[] | "*";
|
|
22
|
-
/** Tab đặt panel: "block" (mặc định)
|
|
23
|
-
tab?: "block" | "style";
|
|
22
|
+
/** Tab đặt panel: "block" (mặc định, tab Cài đặt), "style" (tab Kiểu dáng) hoặc "advanced" (tab Nâng cao, editor ≥ 1.32). Panel hiện gập sẵn. */
|
|
23
|
+
tab?: "block" | "style" | "advanced";
|
|
24
24
|
/** Thứ tự (nhỏ đứng trước, mặc định 10). */
|
|
25
25
|
order?: number;
|
|
26
26
|
/**
|
|
@@ -55,7 +55,7 @@ export function registerBlockPanel(panel: BlockPanel) {
|
|
|
55
55
|
export function unregisterBlockPanel(id: string) { const had = panels.delete(id); if (had) changed(); return had; }
|
|
56
56
|
|
|
57
57
|
/** Panel áp dụng cho một loại khối. */
|
|
58
|
-
export const blockPanelsFor = (type: string, tab: "block" | "style" = "block") => snapshot.filter((p) => (p.blocks === undefined || p.blocks === "*" || p.blocks.includes(type)) && (p.tab ?? "block") === tab);
|
|
58
|
+
export const blockPanelsFor = (type: string, tab: "block" | "style" | "advanced" = "block") => snapshot.filter((p) => (p.blocks === undefined || p.blocks === "*" || p.blocks.includes(type)) && (p.tab ?? "block") === tab);
|
|
59
59
|
/** Ô điều khiển khai CSS: của khối lõi + của mọi panel (đầu vào của controlsCss — cùng hàm website dùng). */
|
|
60
60
|
export const blockControls = () => controls;
|
|
61
61
|
export const blockPanels = () => snapshot;
|
package/src/shared/patterns.ts
CHANGED
|
@@ -1,7 +1,4 @@
|
|
|
1
1
|
import { normalizeContent } from "@ecomcx/ecomweb-content";
|
|
2
|
-
import { btn, buttons, h, p, text } from "./patterns-kit";
|
|
3
|
-
import { msgs } from "../i18n";
|
|
4
|
-
import { libraryPatterns } from "./patterns-library";
|
|
5
2
|
|
|
6
3
|
/**
|
|
7
4
|
* Mẫu (pattern): đoạn nội dung dựng sẵn (giới thiệu, tính năng, bảng giá, kêu gọi hành động…) — chèn = chép khối vào bài,
|
|
@@ -41,54 +38,8 @@ export function patternNodes(p: Pattern): Array<Record<string, unknown>> {
|
|
|
41
38
|
return ((main?.data as { content?: Array<Record<string, unknown>> } | undefined)?.content ?? []);
|
|
42
39
|
}
|
|
43
40
|
|
|
44
|
-
//
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
type L = Record<string, string>;
|
|
48
|
-
function corePatterns(t: L): Pattern[] {
|
|
49
|
-
const plan = (name: string, price: string, variant: string) => ({ type: "group", attrs: { blockStyle: "card" }, content: [
|
|
50
|
-
h(3, name), h(2, price, { style: { fontSize: { base: "2xl" } } }),
|
|
51
|
-
{ type: "bulletList", content: [1, 2, 3].map((n) => ({ type: "listItem", content: [p(`${t.item} ${n}`)] })) },
|
|
52
|
-
buttons("left", btn(t.choose, variant)),
|
|
53
|
-
] });
|
|
54
|
-
const col = (title: string) => ({ type: "column", content: [h(3, title), p(t.fText)] });
|
|
55
|
-
return [
|
|
56
|
-
{ name: "core/hero", category: "hero", title: t.hero, description: t.heroD, keywords: "hero banner cover anh bia", content: [
|
|
57
|
-
{ type: "cover", attrs: { overlay: "#000000", opacity: 55, minHeight: "70vh", contentAlign: "center" }, content: [
|
|
58
|
-
h(1, t.heroTitle, { textAlign: "center" }), p(t.heroText, { textAlign: "center" }), buttons("center", btn(t.start), btn(t.learn, "outline"))] }] },
|
|
59
|
-
{ name: "core/features-3", category: "features", title: t.features, description: t.featuresD, keywords: "features tinh nang cot", content: [
|
|
60
|
-
h(2, t.featuresTitle, { textAlign: "center" }), { type: "spacer", attrs: { height: "md" } },
|
|
61
|
-
{ type: "columns", content: [col(t.f1), col(t.f2), col(t.f3)] }] },
|
|
62
|
-
{ name: "core/cta", category: "cta", title: t.cta, description: t.ctaD, keywords: "cta call to action keu goi", content: [
|
|
63
|
-
{ type: "group", attrs: { blockStyle: "card", style: { textAlign: { base: "center" }, padding: { base: "xl", mobile: "lg" } } }, content: [
|
|
64
|
-
h(2, t.ctaTitle, { textAlign: "center" }), p(t.ctaText, { textAlign: "center" }), buttons("center", btn(t.ctaBtn))] }] },
|
|
65
|
-
{ name: "core/pricing-3", category: "pricing", title: t.pricing, description: t.pricingD, keywords: "pricing bang gia goi", content: [
|
|
66
|
-
{ type: "columns", content: [
|
|
67
|
-
{ type: "column", content: [plan(t.basic, "0đ", "outline")] },
|
|
68
|
-
{ type: "column", content: [plan(t.pro, `199k${t.perMonth}`, "primary")] },
|
|
69
|
-
{ type: "column", content: [plan(t.biz, `499k${t.perMonth}`, "outline")] }] }] },
|
|
70
|
-
{ name: "core/faq", category: "faq", title: t.faq, description: t.faqD, keywords: "faq hoi dap cau hoi", content: [
|
|
71
|
-
h(2, t.faq), ...[1, 2, 3].map((n) => ({ type: "details", attrs: { summary: `${t.q} ${n}?` }, content: [p(t.a)] }))] },
|
|
72
|
-
{ name: "core/testimonial", category: "testimonials", title: t.testimonial, description: t.testimonialD, keywords: "testimonial danh gia cam nhan", content: [
|
|
73
|
-
{ type: "pullquote", attrs: { citation: t.who }, content: [text(t.quote)] }] },
|
|
74
|
-
{ name: "core/intro", category: "text", title: t.intro, description: t.introD, keywords: "about gioi thieu media", content: [
|
|
75
|
-
{ type: "mediaText", attrs: { position: "left", width: 50, verticalAlign: "center" }, content: [h(2, t.introTitle), p(t.introText), buttons("left", btn(t.learn, "outline"))] }] },
|
|
76
|
-
{ name: "core/contact", category: "contact", title: t.contact, description: t.contactD, keywords: "contact lien he form", content: [
|
|
77
|
-
h(2, t.contactTitle), p(t.contactText),
|
|
78
|
-
{ type: "form", attrs: { submitText: t.send, successMessage: t.thanks }, content: [
|
|
79
|
-
{ type: "formField", attrs: { kind: "text", name: "name", label: t.name, required: true, width: "half" } },
|
|
80
|
-
{ type: "formField", attrs: { kind: "email", name: "email", label: t.email, required: true, width: "half" } },
|
|
81
|
-
{ type: "formField", attrs: { kind: "textarea", name: "message", label: t.message, required: true } }] }] },
|
|
82
|
-
];
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
let coreLocale: string | null = null;
|
|
86
|
-
/** Mẫu có sẵn của lõi (gọi lại với ngôn ngữ khác để đổi chữ trong mẫu). */
|
|
87
|
-
export function registerCorePatterns(locale = "vi") {
|
|
88
|
-
if (coreLocale === locale) return;
|
|
89
|
-
coreLocale = locale;
|
|
90
|
-
for (const pattern of [...corePatterns(msgs("patterns", locale)), ...libraryPatterns(locale)]) patterns.set(pattern.name, pattern);
|
|
91
|
-
changed();
|
|
92
|
-
}
|
|
41
|
+
// Lõi không còn mẫu dựng sẵn (xoá 16/11 để thiết kế lại từng mẫu có nghiên cứu); mẫu của theme / plugin vẫn đăng ký bằng registerPattern.
|
|
42
|
+
/** Giữ API cũ: ứng dụng vẫn gọi, hiện không có mẫu lõi nào để đăng ký. */
|
|
43
|
+
export function registerCorePatterns(_locale = "vi") {}
|
|
93
44
|
|
|
94
45
|
export const PATTERN_CATEGORIES = ["hero", "features", "stats", "steps", "cta", "pricing", "testimonials", "faq", "team", "logos", "contact", "text", "gallery", "header", "footer"];
|
|
@@ -256,12 +256,12 @@ export function StylePanel({ style: raw, onChange, t, device, onDeviceChange, pr
|
|
|
256
256
|
|
|
257
257
|
<Panel title={t.style_border} section="border" t={t} visible={visible} setVisible={setVisible} onReset={() => reset(["border", "radius"])}>
|
|
258
258
|
{shows("border", "border") && <>
|
|
259
|
-
{row("borderWidth", t.style_borderWidth, <ValueInput label={t.style_borderWidth} value={style.border?.width} check={ok("radius")} placeholder="1px" onCommit={(v) => setGroup("border", "width", v ?? undefined)} />)}
|
|
259
|
+
{row("borderWidth", t.style_borderWidth, <ValueInput label={t.style_borderWidth} value={typeof style.border?.width === "string" ? style.border.width : undefined} check={ok("radius")} placeholder="1px" onCommit={(v) => setGroup("border", "width", v ?? undefined)} />)}
|
|
260
260
|
{row("borderStyle", t.style_borderStyle, <Seg label={t.style_borderStyle} value={style.border?.style} onChange={(v) => setGroup("border", "style", v)}
|
|
261
261
|
options={[["solid", "—", t.border_solid], ["dashed", "- -", t.border_dashed], ["dotted", "···", t.border_dotted]]} />)}
|
|
262
262
|
{row("borderColor", t.style_borderColor, <ColorField colors={colors} label={t.style_borderColor} t={t} value={style.border?.color} onChange={(v) => setGroup("border", "color", v)} />)}
|
|
263
263
|
</>}
|
|
264
|
-
{shows("border", "radius") && row("radius", t.style_radius, <ValueInput label={t.style_radius} value={style.radius} check={ok("radius")} placeholder="8px" onCommit={(v) => set("radius", v ?? undefined)} />)}
|
|
264
|
+
{shows("border", "radius") && row("radius", t.style_radius, <ValueInput label={t.style_radius} value={typeof style.radius === "string" ? style.radius : undefined} check={ok("radius")} placeholder="8px" onCommit={(v) => set("radius", v ?? undefined)} />)}
|
|
265
265
|
</Panel>
|
|
266
266
|
|
|
267
267
|
<Panel title={t.style_visibility} section="visibility" t={t} visible={visible} setVisible={setVisible} onReset={() => reset(["hide"])}>
|