@orangelogic/design-system 2.95.0 → 2.97.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/library/chunks/asset.B3vySOI-.js +431 -0
- package/library/chunks/{asset.types.6DCzTOQm.js → asset.types.KXRZEtBr.js} +127 -126
- package/library/chunks/{button.BZjbVq8t.js → button.CAa1kvwe.js} +2 -2
- package/library/chunks/{color-swatch-group.Q8ybVS0A.js → color-swatch-group.ChcPlkPU.js} +5 -5
- package/library/chunks/{color-swatch.CbL_TpRZ.js → color-swatch.DJ1kUnBQ.js} +1 -1
- package/library/chunks/{confirm-popover.bBo9aPlX.js → confirm-popover.D4x0nO5g.js} +3 -3
- package/library/chunks/content-builder.CcgZciZN.js +58 -0
- package/library/chunks/{cropper.uKGcvnPk.js → cropper.Bib8Abm3.js} +4937 -4932
- package/library/chunks/{dialog.DRW8iwh-.js → dialog.BLaxLMSc.js} +2 -2
- package/library/chunks/{dom.DURaLV1d.js → dom.0RpWet6y.js} +1 -1
- package/library/chunks/{dot-pagination.CvUr6R4S.js → dot-pagination.-nDdQxJN.js} +1 -1
- package/library/chunks/{file-on-demand.KQlA1JFF.js → file-on-demand.AzwoUvwB.js} +10 -10
- package/library/chunks/{folder-select.DxBOSyvo.js → folder-select.XpkOFzAW.js} +5 -5
- package/library/chunks/{form.nRqYei4e.js → form.Ch1cwYzO.js} +1 -1
- package/library/chunks/{header.ClxEkQPZ.js → header.BZxyeLPK.js} +1 -1
- package/library/chunks/{i18n.W6czbRms.js → i18n.BABe9hN4.js} +6 -0
- package/library/chunks/{icon-button.MqA-pNw8.js → icon-button.C2s3pHG4.js} +1 -1
- package/library/chunks/{iframe.PcSPtm_O.js → iframe.DPccxsnE.js} +1 -1
- package/library/chunks/{image.Dtdklw5q.js → image.9qwbjGNb.js} +1 -1
- package/library/chunks/{image.C-Covc0H.js → image.Cc4V85ID.js} +354 -311
- package/library/chunks/{list-editor.BnHKqD0O.js → list-editor.pVYc_70c.js} +183 -153
- package/library/chunks/{number.CCF6IxpN.js → number.B4PQLJIg.js} +32 -32
- package/library/chunks/{option.Cx54zrJq.js → option.DGXQzdtb.js} +1 -1
- package/library/chunks/{pagination.CG5odPWi.js → pagination.DZqKSA86.js} +4 -4
- package/library/chunks/{responsive.D9TUCX5p.js → responsive.Oz9HWjyQ.js} +1 -1
- package/library/chunks/{string.DfV21HEI.js → string.DUgD4c9f.js} +41 -34
- package/library/chunks/{tab-group.BLZ-qEpp.js → tab-group.BhCf9Smq.js} +4 -4
- package/library/chunks/{table.CYxWpvAC.js → table.V5PGGTfO.js} +13 -11
- package/library/chunks/{time.BNrE47-8.js → time.BiQnh9wt.js} +1 -1
- package/library/chunks/toast.D3AW3RWv.js +94 -0
- package/library/chunks/transformation.Cqz3hPaQ.js +144 -0
- package/library/chunks/{tree.CKi63r95.js → tree.DZa7k-4E.js} +1 -1
- package/library/components/alert.js +2 -2
- package/library/components/asset-link-format.js +767 -862
- package/library/components/atoms.js +12 -12
- package/library/components/border-input-group.js +1 -1
- package/library/components/breadcrumb.js +1 -1
- package/library/components/button.js +3 -3
- package/library/components/checkbox.js +1 -1
- package/library/components/color-picker.js +3 -3
- package/library/components/color-swatch-group.js +6 -6
- package/library/components/color-swatch.js +2 -2
- package/library/components/confirm-popover.js +4 -4
- package/library/components/copy-button.js +1 -1
- package/library/components/corner-position-input-group.js +2 -2
- package/library/components/cropper.js +1 -1
- package/library/components/details.js +4 -4
- package/library/components/dialog.js +3 -3
- package/library/components/dot-pagination.js +2 -2
- package/library/components/drawer.js +2 -2
- package/library/components/dropdown.js +1 -1
- package/library/components/dynamic-select.js +4 -4
- package/library/components/e-chart.js +1 -1
- package/library/components/element-clamp.js +2 -2
- package/library/components/file-on-demand.js +11 -11
- package/library/components/folder-select.js +4 -4
- package/library/components/format-bytes.js +1 -1
- package/library/components/format-date.js +1 -1
- package/library/components/format-number.js +1 -1
- package/library/components/format-time.js +2 -2
- package/library/components/header.js +2 -2
- package/library/components/icon-button.js +2 -2
- package/library/components/iframe.js +2 -2
- package/library/components/image-comparer.js +1 -1
- package/library/components/image.js +2 -2
- package/library/components/input.js +4 -7
- package/library/components/line-clamp.js +1 -1
- package/library/components/list-editor.js +6 -6
- package/library/components/masonry.js +2 -2
- package/library/components/menu-item.js +1 -1
- package/library/components/menu.js +1 -1
- package/library/components/molecules.js +5 -5
- package/library/components/option.js +2 -2
- package/library/components/organisms.js +2 -2
- package/library/components/pagination.js +5 -5
- package/library/components/popup.js +1 -1
- package/library/components/position-picker.js +1 -1
- package/library/components/progress-bar.js +1 -1
- package/library/components/progress-ring.js +1 -1
- package/library/components/radio-group.js +1 -1
- package/library/components/range.js +2 -2
- package/library/components/rating.js +1 -1
- package/library/components/relative-time.js +1 -1
- package/library/components/select.js +3 -3
- package/library/components/share-option-list.js +2 -2
- package/library/components/sidebar.js +1 -1
- package/library/components/size-input-group.js +2 -2
- package/library/components/spinner.js +1 -1
- package/library/components/split-panel.js +1 -1
- package/library/components/switch.js +1 -1
- package/library/components/tab-group.js +5 -5
- package/library/components/tab.js +2 -2
- package/library/components/table.js +5 -5
- package/library/components/tag.js +2 -2
- package/library/components/textarea.js +2 -2
- package/library/components/timecode.js +1 -1
- package/library/components/tooltip.js +1 -1
- package/library/components/tree-item.js +2 -2
- package/library/components/tree.js +2 -2
- package/library/components/typeface.js +2 -2
- package/library/components/types.js +31066 -29848
- package/library/components/video.js +554 -545
- package/library/package.json +1 -1
- package/library/packages/atoms/src/components/image/image.d.ts +15 -1
- package/library/packages/atoms/src/components/input/input.d.ts +1 -2
- package/library/packages/atoms/src/components/video/video.d.ts +3 -1
- package/library/packages/events/src/cx-asset-format-picker-delete.d.ts +6 -0
- package/library/packages/events/src/cx-asset-format-picker-select.d.ts +8 -0
- package/library/packages/events/src/cx-asset-transformation-dialog-cancel.d.ts +6 -0
- package/library/packages/events/src/cx-asset-transformation-dialog-confirm.d.ts +11 -0
- package/library/packages/events/src/cx-asset-transformation-dialog-delete.d.ts +6 -0
- package/library/packages/events/src/cx-bento-range-change.d.ts +9 -0
- package/library/packages/events/src/cx-content-builder-gallery-fetched.d.ts +10 -0
- package/library/packages/events/src/cx-lightbox-close.d.ts +6 -0
- package/library/packages/events/src/cx-lightbox-download.d.ts +11 -0
- package/library/packages/events/src/cx-timeline-data-resolved.d.ts +10 -0
- package/library/packages/events/src/cx-video-thumbnail-resolved.d.ts +8 -0
- package/library/packages/events/src/events.d.ts +12 -1
- package/library/packages/molecules/src/asset-data-display/asset-data-display.d.ts +1 -0
- package/library/packages/molecules/src/asset-format-picker/asset-format-picker.d.ts +56 -0
- package/library/packages/molecules/src/asset-format-picker/asset-format-picker.styles.d.ts +2 -0
- package/library/packages/molecules/src/asset-picker/asset-picker.d.ts +7 -0
- package/library/packages/molecules/src/cropper/cropper.d.ts +1 -0
- package/library/packages/molecules/src/cropper/react/Cropper.d.ts +1 -0
- package/library/packages/molecules/src/download-format-picker/download-format-picker.d.ts +5 -1
- package/library/packages/molecules/src/index.d.ts +1 -0
- package/library/packages/molecules/src/timeline/timeline.d.ts +18 -0
- package/library/packages/organisms/src/asset-link-format/asset-link-format.d.ts +12 -0
- package/library/packages/organisms/src/asset-link-format/components/asset-link-format-rotation/asset-link-format-rotation.d.ts +7 -7
- package/library/packages/organisms/src/asset-transformation-dialog/asset-transformation-dialog.d.ts +102 -0
- package/library/packages/organisms/src/asset-transformation-dialog/asset-transformation-dialog.styles.d.ts +2 -0
- package/library/packages/organisms/src/bento-grid/bento-grid.d.ts +57 -26
- package/library/packages/organisms/src/bento-grid/bento-layout.d.ts +44 -0
- package/library/packages/organisms/src/carousel/carousel.d.ts +3 -1
- package/library/packages/organisms/src/content-builder/components/block-picker/block-picker.d.ts +7 -0
- package/library/packages/organisms/src/content-builder/components/config-form/config-form-controller.d.ts +4 -0
- package/library/packages/organisms/src/content-builder/components/config-form/config-form.d.ts +11 -0
- package/library/packages/organisms/src/content-builder/components/config-manager/config-manager.d.ts +10 -0
- package/library/packages/organisms/src/content-builder/components/gallery-picker/gallery-picker.d.ts +6 -0
- package/library/packages/organisms/src/content-builder/configs/carousel.d.ts +6 -2
- package/library/packages/organisms/src/content-builder/configs/gallery.d.ts +6 -2
- package/library/packages/organisms/src/content-builder/configs/image.d.ts +7 -4
- package/library/packages/organisms/src/content-builder/configs/timeline.d.ts +5 -2
- package/library/packages/organisms/src/content-builder/configs/video.d.ts +11 -2
- package/library/packages/organisms/src/content-builder/configs-controller.d.ts +45 -4
- package/library/packages/organisms/src/content-builder/content-builder-constants.d.ts +2 -2
- package/library/packages/organisms/src/content-builder/content-builder.d.ts +13 -0
- package/library/packages/organisms/src/content-builder/plugins/gallery.d.ts +45 -1
- package/library/packages/organisms/src/content-builder/styleController.d.ts +26 -1
- package/library/packages/organisms/src/index.d.ts +2 -0
- package/library/packages/organisms/src/lightbox/lightbox.d.ts +79 -0
- package/library/packages/organisms/src/lightbox/lightbox.styles.d.ts +2 -0
- package/library/packages/services/src/api/asset/asset.d.ts +2 -2
- package/library/packages/services/src/api/asset/asset.types.d.ts +4 -0
- package/library/packages/tools/src/fetch-asset/fetch-asset.d.ts +2 -1
- package/library/packages/tools/src/fetch-image/fetch-image.d.ts +19 -5
- package/library/packages/types/src/asset-click-action.d.ts +3 -1
- package/library/packages/types/src/asset-format-picker.d.ts +11 -0
- package/library/packages/types/src/bento-grid.d.ts +37 -0
- package/library/packages/types/src/content-builder.d.ts +37 -1
- package/library/packages/types/src/gallery.d.ts +0 -6
- package/library/packages/utils/src/actions/asset-click.d.ts +1 -3
- package/library/packages/utils/src/custom-element/i18n.d.ts +6 -0
- package/library/packages/utils/src/index.d.ts +1 -0
- package/library/packages/utils/src/string/string.d.ts +1 -0
- package/library/packages/utils/src/transformation/index.d.ts +1 -0
- package/library/react-web-component.d.ts +236 -8
- package/library/utils.js +517 -192
- package/package.json +1 -1
- package/library/chunks/asset.Duzr3O3z.js +0 -370
- package/library/chunks/index.BgXEXk4m.js +0 -398
- package/library/chunks/toast.Bc4wpYJ1.js +0 -150
- /package/library/packages/{organisms/src/asset-link-format/asset-link-format.utils.d.ts → utils/src/transformation/transformation.d.ts} +0 -0
|
@@ -1,398 +0,0 @@
|
|
|
1
|
-
import { a as v } from "./url.Cj9cIQXJ.js";
|
|
2
|
-
import "./toast.Bc4wpYJ1.js";
|
|
3
|
-
import "./browser.BHOCIF_A.js";
|
|
4
|
-
import "./color.vLD2sNTs.js";
|
|
5
|
-
import "./modal.U1QltQKe.js";
|
|
6
|
-
import "./animate.El-MpOws.js";
|
|
7
|
-
import "./converters.DkDtLstb.js";
|
|
8
|
-
import "./custom-element.L4WJXn1j.js";
|
|
9
|
-
import "./debounce.DaHuiSGU.js";
|
|
10
|
-
import "./default-value.COZopaet.js";
|
|
11
|
-
import "./drag.DXEXVXPv.js";
|
|
12
|
-
import "./event.mFzZi4sr.js";
|
|
13
|
-
import { f as E } from "./form.nRqYei4e.js";
|
|
14
|
-
import "./i18n.W6czbRms.js";
|
|
15
|
-
import "./math.DqTA6ya4.js";
|
|
16
|
-
import "./scroll.xtO5yojm.js";
|
|
17
|
-
import { j as M } from "./dom.DURaLV1d.js";
|
|
18
|
-
import "./slot.j5oheLJC.js";
|
|
19
|
-
import "./tabbable.CcMz3mIL.js";
|
|
20
|
-
import "./user-agent.D9aPuOyL.js";
|
|
21
|
-
import "./watch.BCJD77bD.js";
|
|
22
|
-
import "./image.Dtdklw5q.js";
|
|
23
|
-
import "./number.CCF6IxpN.js";
|
|
24
|
-
import "./parse.Cu5nBDTb.js";
|
|
25
|
-
import "./responsive.D9TUCX5p.js";
|
|
26
|
-
import "./string.DfV21HEI.js";
|
|
27
|
-
import "./template.ClovJacp.js";
|
|
28
|
-
import "./time.BNrE47-8.js";
|
|
29
|
-
var m = /* @__PURE__ */ ((t) => (t.DoNothing = "do-nothing", t.DownloadAsset = "download-asset", t.ExpandAssetInFullScreen = "expand-asset-in-full-screen", t.OpenAssetOverview = "open-asset-overview", t.OpenLink = "open-link", t.OpenPage = "open-page", t.OpenSpace = "open-space", t.ShareAsset = "share-asset", t.ShowAssetInLibrary = "show-asset-in-library", t))(m || {}), L = /* @__PURE__ */ ((t) => (t.Bento = "bento", t.Carousel = "carousel", t.Grid = "grid", t.Ribbon = "ribbon", t))(L || {}), x = /* @__PURE__ */ ((t) => (t.Expand = "expand", t.Split = "split", t))(x || {}), A = /* @__PURE__ */ ((t) => (t.Api = "api", t.Manual = "manual", t))(A || {}), b = /* @__PURE__ */ ((t) => (t.Automatic = "automatic", t.Custom = "custom", t))(b || {}), d = /* @__PURE__ */ ((t) => (t.DoNothing = "do-nothing", t.OpenAssetInLibrary = "open-asset-in-library", t.OpenAssetOverview = "open-asset-overview", t.Zoom = "zoom", t))(d || {});
|
|
30
|
-
function ct(t) {
|
|
31
|
-
if (!this.ownerDocument.defaultView?.Matrix3 || !t)
|
|
32
|
-
return;
|
|
33
|
-
const e = this.ownerDocument.defaultView?.location.origin;
|
|
34
|
-
e && this.ownerDocument?.defaultView?.postMessage(
|
|
35
|
-
{
|
|
36
|
-
detail: { assetId: t, mode: "Details" },
|
|
37
|
-
type: "cx-cms5-view-asset"
|
|
38
|
-
},
|
|
39
|
-
e
|
|
40
|
-
);
|
|
41
|
-
}
|
|
42
|
-
function lt(t) {
|
|
43
|
-
if (!this.ownerDocument.defaultView?.Matrix3 || !t)
|
|
44
|
-
return;
|
|
45
|
-
const e = this.ownerDocument.defaultView?.location.origin;
|
|
46
|
-
e && this.ownerDocument?.defaultView?.postMessage(
|
|
47
|
-
{
|
|
48
|
-
detail: { assetId: t, mode: "Container" },
|
|
49
|
-
type: "cx-cms5-view-asset"
|
|
50
|
-
},
|
|
51
|
-
e
|
|
52
|
-
);
|
|
53
|
-
}
|
|
54
|
-
function ht(t, e = void 0) {
|
|
55
|
-
!this.ownerDocument.defaultView?.Matrix3 || !t || this.ownerDocument.defaultView?.open(
|
|
56
|
-
v(t, "https://", !0),
|
|
57
|
-
e ?? "_blank"
|
|
58
|
-
);
|
|
59
|
-
}
|
|
60
|
-
function ft(t) {
|
|
61
|
-
if (!this.ownerDocument.defaultView?.Matrix3 || !t)
|
|
62
|
-
return;
|
|
63
|
-
const e = this.ownerDocument.defaultView?.location.origin;
|
|
64
|
-
e && this.ownerDocument?.defaultView?.postMessage(
|
|
65
|
-
{
|
|
66
|
-
detail: { assetIds: [t] },
|
|
67
|
-
type: "cx-cms5-share-assets"
|
|
68
|
-
},
|
|
69
|
-
e
|
|
70
|
-
);
|
|
71
|
-
}
|
|
72
|
-
function mt(t, e) {
|
|
73
|
-
if (!this.ownerDocument.defaultView?.Matrix3 || !t || !e)
|
|
74
|
-
return;
|
|
75
|
-
const r = this.ownerDocument.defaultView?.location.origin;
|
|
76
|
-
r && this.ownerDocument?.defaultView?.postMessage(
|
|
77
|
-
{ detail: { assetIds: t, formats: e }, type: "cx-cms5-download-assets" },
|
|
78
|
-
r
|
|
79
|
-
);
|
|
80
|
-
}
|
|
81
|
-
function dt(t) {
|
|
82
|
-
switch (t) {
|
|
83
|
-
case m.OpenAssetOverview:
|
|
84
|
-
return d.OpenAssetOverview;
|
|
85
|
-
case m.ShowAssetInLibrary:
|
|
86
|
-
return d.OpenAssetInLibrary;
|
|
87
|
-
case m.ExpandAssetInFullScreen:
|
|
88
|
-
return d.Zoom;
|
|
89
|
-
default:
|
|
90
|
-
return t;
|
|
91
|
-
}
|
|
92
|
-
}
|
|
93
|
-
class pt {
|
|
94
|
-
constructor(e) {
|
|
95
|
-
this.currentZIndex = M(), (this.host = e).addController(this);
|
|
96
|
-
}
|
|
97
|
-
hostConnected() {
|
|
98
|
-
}
|
|
99
|
-
hostDisconnected() {
|
|
100
|
-
}
|
|
101
|
-
async activatePopup() {
|
|
102
|
-
this.currentZIndex = M();
|
|
103
|
-
}
|
|
104
|
-
}
|
|
105
|
-
class wt {
|
|
106
|
-
constructor(e, r = {}) {
|
|
107
|
-
this.element = e, this.noChildDrag = r.noChildDrag ?? !1, this.dragThreshold = r.dragThreshold ?? 5, this.isDragging = !1, this.hasDragged = !1, this.startX = 0, this.startY = 0, this.lastClientX = 0, this.lastClientY = 0, this.onMouseDown = this.onMouseDown.bind(this), this.onMouseMove = this.onMouseMove.bind(this), this.onMouseUp = this.onMouseUp.bind(this), this.onClick = this.onClick.bind(this), this.attach();
|
|
108
|
-
}
|
|
109
|
-
attach() {
|
|
110
|
-
this.element.addEventListener("mousedown", this.onMouseDown), window.addEventListener("mouseup", this.onMouseUp), window.addEventListener("mousemove", this.onMouseMove), this.element.addEventListener("click", this.onClick, !0);
|
|
111
|
-
}
|
|
112
|
-
detach() {
|
|
113
|
-
this.element.removeEventListener("mousedown", this.onMouseDown), window.removeEventListener("mouseup", this.onMouseUp), window.removeEventListener("mousemove", this.onMouseMove), this.element.removeEventListener("click", this.onClick, !0);
|
|
114
|
-
}
|
|
115
|
-
onMouseDown(e) {
|
|
116
|
-
this.noChildDrag && e.target !== this.element || (this.isDragging = !0, this.hasDragged = !1, this.startX = e.clientX, this.startY = e.clientY, this.lastClientX = e.clientX, this.lastClientY = e.clientY, e.preventDefault());
|
|
117
|
-
}
|
|
118
|
-
onMouseMove(e) {
|
|
119
|
-
if (!this.isDragging)
|
|
120
|
-
return;
|
|
121
|
-
const r = e.clientX - this.lastClientX, s = e.clientY - this.lastClientY;
|
|
122
|
-
!this.hasDragged && (Math.abs(e.clientX - this.startX) > this.dragThreshold || Math.abs(e.clientY - this.startY) > this.dragThreshold) && (this.hasDragged = !0), this.element.scrollLeft -= r, this.element.scrollTop -= s, this.lastClientX = e.clientX, this.lastClientY = e.clientY;
|
|
123
|
-
}
|
|
124
|
-
onMouseUp() {
|
|
125
|
-
this.isDragging = !1;
|
|
126
|
-
}
|
|
127
|
-
onClick(e) {
|
|
128
|
-
this.hasDragged && (e.stopImmediatePropagation(), e.preventDefault());
|
|
129
|
-
}
|
|
130
|
-
}
|
|
131
|
-
const gt = (t) => t.ctrlKey || t.metaKey;
|
|
132
|
-
function C(t, e) {
|
|
133
|
-
if (!t?.document)
|
|
134
|
-
return !1;
|
|
135
|
-
const r = "mmmmmmmmmmwwwwwww", s = "32px", o = t.document.createElement("canvas").getContext("2d"), i = (u) => o ? (o.font = `${s} ${u}, monospace`, o.measureText(r).width) : 0, a = i("monospace");
|
|
136
|
-
return i(e) !== a;
|
|
137
|
-
}
|
|
138
|
-
function Dt(t, e) {
|
|
139
|
-
if (!t?.document.fonts)
|
|
140
|
-
return !1;
|
|
141
|
-
let r = !1;
|
|
142
|
-
return t.document.fonts.forEach((s) => {
|
|
143
|
-
s.family.replace(/['"]/g, "").toLowerCase() === e.toLowerCase() && (r = !0);
|
|
144
|
-
}), r ? !0 : C(t, e);
|
|
145
|
-
}
|
|
146
|
-
function O(t) {
|
|
147
|
-
const e = /\bitalic\b/i, r = /\b(semi[-\s]?condensed|condensed)\b/i, s = (n) => {
|
|
148
|
-
const o = n.fontFamily.toLowerCase(), i = n.fontStyle.toLowerCase(), a = e.test(i), h = r.test(o);
|
|
149
|
-
let u = 0;
|
|
150
|
-
return a && (u = 1), h && (u = a ? 3 : 2), {
|
|
151
|
-
family: n.fontFamily,
|
|
152
|
-
styleRank: u,
|
|
153
|
-
weight: Number(n.fontWeight)
|
|
154
|
-
};
|
|
155
|
-
};
|
|
156
|
-
return [...t].sort((n, o) => {
|
|
157
|
-
const i = s(n), a = s(o);
|
|
158
|
-
return i.weight !== a.weight ? i.weight - a.weight : i.styleRank !== a.styleRank ? i.styleRank - a.styleRank : i.family.localeCompare(a.family);
|
|
159
|
-
});
|
|
160
|
-
}
|
|
161
|
-
function yt(t, e, r = [300, 400, 500, 700, 900], s = ["normal", "italic"]) {
|
|
162
|
-
const n = [];
|
|
163
|
-
if (C(t, e))
|
|
164
|
-
for (const o of r)
|
|
165
|
-
for (const i of s)
|
|
166
|
-
n.push({
|
|
167
|
-
fontFamily: e,
|
|
168
|
-
fontStyle: i,
|
|
169
|
-
fontWeight: o.toString(),
|
|
170
|
-
src: ""
|
|
171
|
-
});
|
|
172
|
-
return O(n);
|
|
173
|
-
}
|
|
174
|
-
function Mt(t) {
|
|
175
|
-
const e = new FormData(t), r = {};
|
|
176
|
-
return e.forEach((s, n) => {
|
|
177
|
-
if (Reflect.has(r, n)) {
|
|
178
|
-
const o = r[n];
|
|
179
|
-
Array.isArray(o) ? o.push(s) : r[n] = [r[n], s];
|
|
180
|
-
} else
|
|
181
|
-
r[n] = s;
|
|
182
|
-
}), r;
|
|
183
|
-
}
|
|
184
|
-
function I(t) {
|
|
185
|
-
const r = [...t.getRootNode().querySelectorAll("*")], s = [...t.elements], n = E.get(t), o = n ? Array.from(n) : [];
|
|
186
|
-
return [...s, ...o].sort(
|
|
187
|
-
(i, a) => r.indexOf(i) < r.indexOf(a) ? -1 : r.indexOf(i) > r.indexOf(a) ? 1 : 0
|
|
188
|
-
);
|
|
189
|
-
}
|
|
190
|
-
function Ct(t) {
|
|
191
|
-
return I(t).some(
|
|
192
|
-
(r) => r.hasAttribute("data-user-valid") || r.hasAttribute("data-user-invalid")
|
|
193
|
-
);
|
|
194
|
-
}
|
|
195
|
-
class St {
|
|
196
|
-
constructor(e = null) {
|
|
197
|
-
this.history = e !== null ? [e] : [], this.redoStack = [];
|
|
198
|
-
}
|
|
199
|
-
add(e) {
|
|
200
|
-
this.history.push(e), this.redoStack = [];
|
|
201
|
-
}
|
|
202
|
-
undo() {
|
|
203
|
-
if (this.history.length > 1) {
|
|
204
|
-
const e = this.history.pop();
|
|
205
|
-
return this.redoStack.push(e), this.getCurrent();
|
|
206
|
-
}
|
|
207
|
-
return null;
|
|
208
|
-
}
|
|
209
|
-
redo() {
|
|
210
|
-
if (this.redoStack.length > 0) {
|
|
211
|
-
const e = this.redoStack.pop();
|
|
212
|
-
return this.history.push(e), e;
|
|
213
|
-
}
|
|
214
|
-
return null;
|
|
215
|
-
}
|
|
216
|
-
getCurrent() {
|
|
217
|
-
return this.history[this.history.length - 1] || null;
|
|
218
|
-
}
|
|
219
|
-
clear() {
|
|
220
|
-
this.history = [], this.redoStack = [];
|
|
221
|
-
}
|
|
222
|
-
canUndo() {
|
|
223
|
-
return this.history.length > 1;
|
|
224
|
-
}
|
|
225
|
-
canRedo() {
|
|
226
|
-
return this.redoStack.length > 0;
|
|
227
|
-
}
|
|
228
|
-
getHistory() {
|
|
229
|
-
return [...this.history];
|
|
230
|
-
}
|
|
231
|
-
}
|
|
232
|
-
var F = /* @__PURE__ */ ((t) => (t.ArrowDown = "ArrowDown", t.ArrowLeft = "ArrowLeft", t.ArrowRight = "ArrowRight", t.ArrowUp = "ArrowUp", t.Enter = "Enter", t.Escape = "Escape", t.Tab = "Tab", t))(F || {});
|
|
233
|
-
function vt(t, e) {
|
|
234
|
-
const r = {}, s = new Set(e);
|
|
235
|
-
return Object.keys(t).forEach((n) => {
|
|
236
|
-
s.has(n) || (r[n] = t[n]);
|
|
237
|
-
}), r;
|
|
238
|
-
}
|
|
239
|
-
function Et(t, e) {
|
|
240
|
-
const r = {};
|
|
241
|
-
return e.forEach((s) => {
|
|
242
|
-
s in t && (r[s] = t[s]);
|
|
243
|
-
}), r;
|
|
244
|
-
}
|
|
245
|
-
function Lt(t) {
|
|
246
|
-
if (!t)
|
|
247
|
-
return {};
|
|
248
|
-
let e;
|
|
249
|
-
try {
|
|
250
|
-
e = JSON.parse(t);
|
|
251
|
-
} catch {
|
|
252
|
-
return {};
|
|
253
|
-
}
|
|
254
|
-
return typeof e != "object" ? {} : e;
|
|
255
|
-
}
|
|
256
|
-
function xt(t, e = !0) {
|
|
257
|
-
if (!t)
|
|
258
|
-
return [];
|
|
259
|
-
let r;
|
|
260
|
-
try {
|
|
261
|
-
r = JSON.parse(t);
|
|
262
|
-
} catch {
|
|
263
|
-
return [];
|
|
264
|
-
}
|
|
265
|
-
return Array.isArray(r) ? e ? r.filter((s) => typeof s == "string") : r : [];
|
|
266
|
-
}
|
|
267
|
-
function At(t, e) {
|
|
268
|
-
return typeof Storage < "u" && localStorage.getItem(t) !== null ? localStorage.getItem(t) : e;
|
|
269
|
-
}
|
|
270
|
-
function bt(t, e) {
|
|
271
|
-
typeof Storage < "u" && localStorage.setItem(t, e.toString());
|
|
272
|
-
}
|
|
273
|
-
const T = 10;
|
|
274
|
-
function Ot(t, e) {
|
|
275
|
-
let r = 0, s = t.length;
|
|
276
|
-
for (; r < s; ) {
|
|
277
|
-
const n = Math.floor((r + s) / 2);
|
|
278
|
-
t[n].time < e.time ? r = n + 1 : s = n;
|
|
279
|
-
}
|
|
280
|
-
t.splice(r, 0, e);
|
|
281
|
-
}
|
|
282
|
-
function k(t, e, r) {
|
|
283
|
-
return t.find(
|
|
284
|
-
(s) => s.col === e && s.row === r
|
|
285
|
-
) ?? null;
|
|
286
|
-
}
|
|
287
|
-
function V(t, e, r) {
|
|
288
|
-
return new Promise((s) => {
|
|
289
|
-
if (e > 0 && Math.abs(t.currentTime - e) < 1e-3) {
|
|
290
|
-
s();
|
|
291
|
-
return;
|
|
292
|
-
}
|
|
293
|
-
if (e === 0) {
|
|
294
|
-
const n = () => {
|
|
295
|
-
t.removeEventListener("seeked", n);
|
|
296
|
-
const o = () => {
|
|
297
|
-
t.removeEventListener("seeked", o), s();
|
|
298
|
-
};
|
|
299
|
-
t.addEventListener("seeked", o), t.currentTime = 0;
|
|
300
|
-
};
|
|
301
|
-
t.addEventListener("seeked", n), t.currentTime = r;
|
|
302
|
-
} else {
|
|
303
|
-
const n = () => {
|
|
304
|
-
t.removeEventListener("seeked", n), s();
|
|
305
|
-
};
|
|
306
|
-
t.addEventListener("seeked", n), t.currentTime = e;
|
|
307
|
-
}
|
|
308
|
-
});
|
|
309
|
-
}
|
|
310
|
-
async function* It({
|
|
311
|
-
cache: t,
|
|
312
|
-
canvas: e,
|
|
313
|
-
duration: r,
|
|
314
|
-
maxInterval: s,
|
|
315
|
-
src: n,
|
|
316
|
-
video: o
|
|
317
|
-
}) {
|
|
318
|
-
if (!e)
|
|
319
|
-
throw new Error("Canvas is required");
|
|
320
|
-
if (!o)
|
|
321
|
-
throw new Error("Video is required");
|
|
322
|
-
const { columns: i, frameHeight: a, frameWidth: h, rows: u, spriteCtx: S } = e;
|
|
323
|
-
try {
|
|
324
|
-
for (let c = 0; c < u; c++)
|
|
325
|
-
for (let l = 0; l < i; l++) {
|
|
326
|
-
const p = c * i + l, f = p * s;
|
|
327
|
-
if (f >= r)
|
|
328
|
-
continue;
|
|
329
|
-
const w = l * h, g = c * a, D = k(t[n] ?? [], l, c), y = l === i - 1 && c === u - 1 || f + s >= r;
|
|
330
|
-
D ? yield { ...D, isLastFrame: y } : (await V(o, f, s), S.drawImage(
|
|
331
|
-
o,
|
|
332
|
-
w,
|
|
333
|
-
g,
|
|
334
|
-
h,
|
|
335
|
-
a
|
|
336
|
-
), yield {
|
|
337
|
-
col: l,
|
|
338
|
-
columns: i,
|
|
339
|
-
frameHeight: a,
|
|
340
|
-
frameWidth: h,
|
|
341
|
-
index: p,
|
|
342
|
-
isLastFrame: y,
|
|
343
|
-
row: c,
|
|
344
|
-
rows: u,
|
|
345
|
-
time: Number(f.toFixed(T)),
|
|
346
|
-
x: w,
|
|
347
|
-
y: g
|
|
348
|
-
}), await new Promise(requestAnimationFrame);
|
|
349
|
-
}
|
|
350
|
-
} catch {
|
|
351
|
-
}
|
|
352
|
-
}
|
|
353
|
-
function Ft({
|
|
354
|
-
duration: t,
|
|
355
|
-
frameWidth: e,
|
|
356
|
-
playbackSpeed: r,
|
|
357
|
-
scale: s
|
|
358
|
-
}) {
|
|
359
|
-
let n = e * r / s;
|
|
360
|
-
return n > t && (n = t / 2), n;
|
|
361
|
-
}
|
|
362
|
-
export {
|
|
363
|
-
xt as A,
|
|
364
|
-
pt as C,
|
|
365
|
-
wt as D,
|
|
366
|
-
L as G,
|
|
367
|
-
St as H,
|
|
368
|
-
F as K,
|
|
369
|
-
x as O,
|
|
370
|
-
T as P,
|
|
371
|
-
A as S,
|
|
372
|
-
m as a,
|
|
373
|
-
b,
|
|
374
|
-
d as c,
|
|
375
|
-
Ct as d,
|
|
376
|
-
It as e,
|
|
377
|
-
k as f,
|
|
378
|
-
Ft as g,
|
|
379
|
-
Ot as h,
|
|
380
|
-
gt as i,
|
|
381
|
-
ct as j,
|
|
382
|
-
lt as k,
|
|
383
|
-
ht as l,
|
|
384
|
-
mt as m,
|
|
385
|
-
C as n,
|
|
386
|
-
vt as o,
|
|
387
|
-
Dt as p,
|
|
388
|
-
O as q,
|
|
389
|
-
At as r,
|
|
390
|
-
ft as s,
|
|
391
|
-
dt as t,
|
|
392
|
-
yt as u,
|
|
393
|
-
Mt as v,
|
|
394
|
-
bt as w,
|
|
395
|
-
I as x,
|
|
396
|
-
Et as y,
|
|
397
|
-
Lt as z
|
|
398
|
-
};
|
|
@@ -1,150 +0,0 @@
|
|
|
1
|
-
import { c as s } from "./capitalize.CNStXZBq.js";
|
|
2
|
-
function v(n, t) {
|
|
3
|
-
return n.filter((a, e) => e !== t);
|
|
4
|
-
}
|
|
5
|
-
function w(n, t) {
|
|
6
|
-
return n.filter((a, e) => !t.includes(e));
|
|
7
|
-
}
|
|
8
|
-
function R(n, t, a) {
|
|
9
|
-
return [...n.slice(0, t), a, ...n.slice(t)];
|
|
10
|
-
}
|
|
11
|
-
function b(n, t, a) {
|
|
12
|
-
return [...n.slice(0, t), ...a, ...n.slice(t)];
|
|
13
|
-
}
|
|
14
|
-
function p(n, t, a) {
|
|
15
|
-
return n.findIndex((e) => e[t] === a);
|
|
16
|
-
}
|
|
17
|
-
function G(n, t, a) {
|
|
18
|
-
const e = [...n], o = v(e, t);
|
|
19
|
-
let r = a;
|
|
20
|
-
return r >= n.length - 1 && (r = r + 1), R(o, r, n[t]);
|
|
21
|
-
}
|
|
22
|
-
function _(n, t, a) {
|
|
23
|
-
const e = [...n], o = w(e, t), r = a !== 0 ? t.reduce(
|
|
24
|
-
(i, d) => a > d ? i - 1 : i,
|
|
25
|
-
a
|
|
26
|
-
) : a;
|
|
27
|
-
return b(
|
|
28
|
-
o,
|
|
29
|
-
r,
|
|
30
|
-
t.map((i) => n[i])
|
|
31
|
-
);
|
|
32
|
-
}
|
|
33
|
-
function j(n, t) {
|
|
34
|
-
return n.reduce(
|
|
35
|
-
(a, e) => {
|
|
36
|
-
const o = e[t];
|
|
37
|
-
return a[o] ??= [], a[o].push(e), a;
|
|
38
|
-
},
|
|
39
|
-
{}
|
|
40
|
-
);
|
|
41
|
-
}
|
|
42
|
-
function V(n, t, a) {
|
|
43
|
-
if (!n.length)
|
|
44
|
-
return [t];
|
|
45
|
-
const e = a.findIndex(
|
|
46
|
-
(l) => l.id === t
|
|
47
|
-
), o = n[n.length - 1], r = a.findIndex(
|
|
48
|
-
(l) => l.id === o
|
|
49
|
-
);
|
|
50
|
-
if (e < 0 || r < 0)
|
|
51
|
-
return [t];
|
|
52
|
-
const c = a.reduce(
|
|
53
|
-
(l, u, x) => (l[u.id] = x, l),
|
|
54
|
-
{}
|
|
55
|
-
), i = e > r, d = i ? r : e, A = i ? e : r, f = a.slice(d, A + 1).filter((l) => !(!l || n.includes(l.id))).map((l) => l.id), g = i ? f : [...f].reverse(), h = n.includes(t) ? n.slice(0, n.indexOf(t) + 1) : [...n, ...g];
|
|
56
|
-
return h.sort((l, u) => c[l] - c[u]), h;
|
|
57
|
-
}
|
|
58
|
-
function K(n, t, a, e, o, r) {
|
|
59
|
-
const c = a + 1;
|
|
60
|
-
if (n.length < 2)
|
|
61
|
-
throw new Error("Values array must contain at least 2 elements");
|
|
62
|
-
if (a < 0 || c >= n.length)
|
|
63
|
-
throw new Error("Invalid index or not enough values to adjust");
|
|
64
|
-
if (e < 0)
|
|
65
|
-
throw new Error("Minimum value must be non-negative");
|
|
66
|
-
let i = o + t;
|
|
67
|
-
i < e && (t = e - o, i = e);
|
|
68
|
-
let d = r - t;
|
|
69
|
-
d < e && (t = r - e, i = o + t, d = e), n[a] = parseFloat(i.toFixed(2)), n[c] = parseFloat(d.toFixed(2));
|
|
70
|
-
}
|
|
71
|
-
const B = window.location.origin.includes("localhost:") ? "https://local.orangelogic.com" : window.location.origin;
|
|
72
|
-
function U(n, t, a, e = B) {
|
|
73
|
-
const o = new URL(e + "/" + n);
|
|
74
|
-
return Array.isArray(a) ? a.forEach((r) => {
|
|
75
|
-
r[1] && o.searchParams.append(r[0], r[1]);
|
|
76
|
-
}) : a && Object.keys(a).forEach((r) => {
|
|
77
|
-
a[r] && o.searchParams.append(r, a[r]);
|
|
78
|
-
}), fetch(o, t);
|
|
79
|
-
}
|
|
80
|
-
var E = /* @__PURE__ */ ((n) => (n.Desktop = "desktop", n.Mobile = "mobile", n.Tablet = "tablet", n))(E || {});
|
|
81
|
-
const M = {
|
|
82
|
-
canvasWidth: "",
|
|
83
|
-
height: "",
|
|
84
|
-
id: "desktop",
|
|
85
|
-
maxWidth: "",
|
|
86
|
-
name: s(
|
|
87
|
-
"desktop"
|
|
88
|
-
/* Desktop */
|
|
89
|
-
)
|
|
90
|
-
}, L = {
|
|
91
|
-
canvasWidth: "770px",
|
|
92
|
-
height: "",
|
|
93
|
-
id: "tablet",
|
|
94
|
-
maxWidth: "1280px",
|
|
95
|
-
name: s(
|
|
96
|
-
"tablet"
|
|
97
|
-
/* Tablet */
|
|
98
|
-
)
|
|
99
|
-
}, O = {
|
|
100
|
-
canvasWidth: "320px",
|
|
101
|
-
height: "",
|
|
102
|
-
id: "mobile",
|
|
103
|
-
maxWidth: "480px",
|
|
104
|
-
name: s(
|
|
105
|
-
"mobile"
|
|
106
|
-
/* Mobile */
|
|
107
|
-
)
|
|
108
|
-
}, H = [M, L, O];
|
|
109
|
-
var S = /* @__PURE__ */ ((n) => (n.All = "ALL", n.CanDelete = "CanDelete", n.CanDownload = "CanDownload", n.CanFind = "CanFind", n.CanManageRights = "CanManageRights", n.CanMove = "CanMove", n.CanRead = "CanRead", n.CanReadAll = "CanReadAll", n.CanReadAndWrite = "CanReadAndWrite", n.CanReadLarge = "CanReadLarge", n.CanReadMedium = "CanReadMedium", n.CanReadOriginal = "CanReadOriginal", n.CanShare = "CanShare", n.CanUpload = "CanUpload", n.CanWrite = "CanWrite", n.None = "NONE", n))(S || {}), N = /* @__PURE__ */ ((n) => (n.All = "all", n.Audio = "audio", n.Image = "image", n.Other = "other", n.Video = "video", n))(N || {}), F = /* @__PURE__ */ ((n) => (n.Content = "content", n.Template = "template", n))(F || {}), D = /* @__PURE__ */ ((n) => (n.Administrator = "Administrator", n.Designer = "Designer", n.Editor = "Editor", n))(D || {}), C = /* @__PURE__ */ ((n) => (n.Accordion = "BlockAccordion", n.Analytics = "BlockAnalytics", n.Button = "BlockButton", n.Carousel = "BlockCarousel", n.ColorSwatches = "BlockColorSwatches", n.Column = "BlockCell", n.ColumnGroup = "BlockColumns", n.Divider = "BlockDivider", n.FontKit = "BlockFontKit", n.Gallery = "BlockGallery", n.Header = "BlockHeader", n.Image = "BlockImage", n.RichText = "BlockRichText", n.SearchBox = "BlockSearchBox", n.TabGroup = "BlockTabs", n.Text = "BlockText", n.Timeline = "BlockTimeline", n.Video = "BlockVideo", n))(C || {});
|
|
110
|
-
const z = Object.values(C).filter(
|
|
111
|
-
(n) => n !== "BlockCell"
|
|
112
|
-
/* Column */
|
|
113
|
-
);
|
|
114
|
-
var T = /* @__PURE__ */ ((n) => (n.Carousel = "carousel", n.Gallery = "gallery", n))(T || {}), k = /* @__PURE__ */ ((n) => (n.Templates = "TEMPLATES", n.TranslatableAttributes = "TRANSLATABLE_ATTRIBUTES", n.TranslatableTexts = "TRANSLATABLE_TEXTS", n))(k || {});
|
|
115
|
-
const X = (n, t) => {
|
|
116
|
-
try {
|
|
117
|
-
window.Matrix3?.ShowNotification && window.Matrix3.ShowNotification(
|
|
118
|
-
n,
|
|
119
|
-
t ? {
|
|
120
|
-
notificationType: t.notificationType
|
|
121
|
-
} : void 0
|
|
122
|
-
);
|
|
123
|
-
} catch {
|
|
124
|
-
return;
|
|
125
|
-
}
|
|
126
|
-
};
|
|
127
|
-
export {
|
|
128
|
-
N as A,
|
|
129
|
-
C as B,
|
|
130
|
-
E as D,
|
|
131
|
-
F as E,
|
|
132
|
-
S as P,
|
|
133
|
-
D as T,
|
|
134
|
-
T as a,
|
|
135
|
-
k as b,
|
|
136
|
-
z as c,
|
|
137
|
-
H as d,
|
|
138
|
-
_ as e,
|
|
139
|
-
p as f,
|
|
140
|
-
j as g,
|
|
141
|
-
U as h,
|
|
142
|
-
b as i,
|
|
143
|
-
v as j,
|
|
144
|
-
R as k,
|
|
145
|
-
G as l,
|
|
146
|
-
V as m,
|
|
147
|
-
K as n,
|
|
148
|
-
w as r,
|
|
149
|
-
X as t
|
|
150
|
-
};
|