@jxsuite/studio 3.0.0 → 4.1.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/README.md +5 -5
- package/dist/chunks/{2020-xp8vnwma.js → 2020-n6tfwnda.js} +2 -2
- package/dist/chunks/Overlay.dev-etqjwyf9.js +23 -0
- package/dist/chunks/cf-account-picker-en86v7x7.js +163 -0
- package/dist/chunks/{cf-settings-zj2cj1ar.js → cf-settings-45fgyx8y.js} +6 -5
- package/dist/chunks/{components-z6cnkyy1.js → components-zmx10t62.js} +6 -5
- package/dist/chunks/content-source-48xg86wj.js +49 -0
- package/dist/chunks/{convert-to-repeater-6vvx96n2.js → convert-to-repeater-43tfn7cs.js} +33 -25
- package/dist/chunks/entry-commands-e63f1xc0.js +46 -0
- package/dist/chunks/{extension-sections-kwzvpemr.js → extension-sections-txv08xxg.js} +34 -26
- package/dist/chunks/file-ops-wbh4hhsx.js +48 -0
- package/dist/chunks/files-3kfkwhk4.js +93 -0
- package/dist/chunks/{focus-trap.esm-ggawf1hy.js → focus-trap.esm-9t2drp0g.js} +6 -5
- package/dist/chunks/{format-host-8fr3545e.js → format-host-w16q81tf.js} +3 -3
- package/dist/chunks/fs-events-hrrg328g.js +21 -0
- package/dist/chunks/{git-panel-g01d93vc.js → git-panel-532whr1y.js} +22 -16
- package/dist/chunks/{index-nj44jpzj.js → index-wcnt3r9g.js} +2 -2
- package/dist/chunks/{jx-validate-jj9rnt4n.js → jx-validate-8er6gbxy.js} +6 -4
- package/dist/chunks/layers-panel-07hm7g5j.js +67 -0
- package/dist/chunks/layers-q75tj2mf.js +45 -0
- package/dist/chunks/lit-html-j055mkh8.js +22 -0
- package/dist/chunks/monaco-buffer-dqw0xxpx.js +25 -0
- package/dist/chunks/{monaco-setup-a5wkmbgh.js → monaco-setup-vx9bhp1d.js} +4 -4
- package/dist/chunks/notify-yjm79n4s.js +30 -0
- package/dist/chunks/parse-24d0gay3.js +19 -0
- package/dist/chunks/platform-ba1j1gbh.js +16 -0
- package/dist/chunks/publish-panel-v9st96ja.js +29 -0
- package/dist/chunks/quick-search-zccjp6gv.js +66 -0
- package/dist/chunks/references-3qx8fkyp.js +29 -0
- package/dist/chunks/right-panel-vm3b6kwy.js +46 -0
- package/dist/chunks/sp-overlay.dev-qgvhnxf4.js +18 -0
- package/dist/chunks/sp-popover.dev-n2etmqdp.js +9 -0
- package/dist/chunks/sp-progress-circle.dev-hryhj0es.js +15 -0
- package/dist/chunks/sp-tooltip.dev-4sastdnw.js +15 -0
- package/dist/chunks/{sp-tray.dev-64v4pxw8.js → sp-tray.dev-tkbscm06.js} +5 -5
- package/dist/chunks/{studio-wdt9y92a.js → studio-0bq6eh7v.js} +2 -2
- package/dist/chunks/studio-1ngbejft.js +181 -0
- package/dist/chunks/studio-1wagb550.js +118 -0
- package/dist/chunks/{studio-j595e748.js → studio-2b946z26.js} +172 -95
- package/dist/chunks/{studio-pkp61mh8.js → studio-3bqpr0zh.js} +25 -17
- package/dist/chunks/{studio-k4jvjcfx.js → studio-4b5z1x43.js} +46 -12
- package/dist/chunks/{studio-ry1vz5sv.js → studio-4n2b5gzb.js} +15 -13
- package/dist/chunks/{studio-p5dja96s.js → studio-4r1pv6zf.js} +2 -2
- package/dist/chunks/{studio-kvfx9z2c.js → studio-4rzyrtjz.js} +70 -31
- package/dist/chunks/{studio-tzx3xmvx.js → studio-5fx3g9jg.js} +33 -52
- package/dist/chunks/{studio-rh1cnamv.js → studio-5myknm0a.js} +565 -135
- package/dist/chunks/studio-6yw4y3my.js +91 -0
- package/dist/chunks/{studio-0rqqhrdy.js → studio-7nte2hj4.js} +2 -2
- package/dist/chunks/studio-92ab2jqe.js +282 -0
- package/dist/chunks/{studio-6z5eyjwn.js → studio-950k0dx6.js} +72 -135
- package/dist/chunks/{studio-sas7mt3k.js → studio-9ab8gqsm.js} +2 -2
- package/dist/chunks/studio-9n4mrmnb.js +184 -0
- package/dist/chunks/{studio-hcxzyk3x.js → studio-ahn3pdgx.js} +6 -6
- package/dist/chunks/studio-b55y6ewx.js +498 -0
- package/dist/chunks/{studio-s519zc99.js → studio-bgxt93ga.js} +3 -3
- package/dist/chunks/studio-cft9r4r7.js +119 -0
- package/dist/chunks/{studio-dc8s8heb.js → studio-cmb03bg5.js} +6904 -8321
- package/dist/chunks/studio-dm19q43r.js +195 -0
- package/dist/chunks/{studio-2x9zbxmx.js → studio-ef49pnzx.js} +11 -9
- package/dist/chunks/{studio-ay8wcr2b.js → studio-eqq1w638.js} +7 -9
- package/dist/chunks/{studio-5efrtn1m.js → studio-ew0djmhg.js} +23 -19
- package/dist/chunks/{studio-tr20m8g8.js → studio-f3wqjtk5.js} +39 -3
- package/dist/chunks/{studio-xntfdy1x.js → studio-fbf92ckf.js} +36 -23
- package/dist/chunks/{studio-4q0wznzf.js → studio-gcye7qka.js} +442 -126
- package/dist/chunks/{studio-7p35254k.js → studio-gfgb8pe6.js} +36 -193
- package/dist/chunks/studio-jc994dnr.js +1066 -0
- package/dist/chunks/{studio-hj2se583.js → studio-jkftxyvz.js} +69 -3423
- package/dist/chunks/{studio-5x5774ak.js → studio-kryvsw6j.js} +3 -3
- package/dist/chunks/{studio-kfpek536.js → studio-kyh9avvv.js} +2 -2
- package/dist/chunks/{studio-twsafr1e.js → studio-m3hwn7y1.js} +3 -3
- package/dist/chunks/studio-msd847zn.js +1315 -0
- package/dist/chunks/{studio-g5gdqnyd.js → studio-mtfnaqs9.js} +19 -19
- package/dist/chunks/{studio-7ejemhej.js → studio-n6j9t10q.js} +6 -6
- package/dist/chunks/{studio-vhk5fmfv.js → studio-n8b9wqwy.js} +5 -5
- package/dist/chunks/{studio-cjm7fdjf.js → studio-p4ngc046.js} +8 -104
- package/dist/chunks/studio-q43a5y9h.js +394 -0
- package/dist/chunks/studio-q7v10cg2.js +106 -0
- package/dist/chunks/{studio-6kv3apa9.js → studio-q9jd1a60.js} +27 -11
- package/dist/chunks/studio-qcy05dp8.js +1743 -0
- package/dist/chunks/{studio-a0yp7syn.js → studio-qjy2z9bv.js} +29 -132
- package/dist/chunks/{studio-2w11grav.js → studio-qq6jym04.js} +3 -3
- package/dist/chunks/{studio-3fk1ac9z.js → studio-rdx8jcxy.js} +4 -4
- package/dist/chunks/{studio-4mqb9a0j.js → studio-rn9ta2mz.js} +4 -4
- package/dist/chunks/studio-t7qb9db8.js +665 -0
- package/dist/chunks/studio-tmc5emrw.js +8 -0
- package/dist/chunks/{studio-r5xbtctf.js → studio-trxrabqf.js} +292 -2297
- package/dist/chunks/studio-wcy8trfx.js +263 -0
- package/dist/chunks/{studio-3dkcd4c5.js → studio-x4qkdat5.js} +62 -57
- package/dist/chunks/studio-x813zp48.js +195 -0
- package/dist/chunks/{studio-qpfq7xhm.js → studio-xrapxwwc.js} +22 -285
- package/dist/chunks/{studio-xm3dbxvn.js → studio-zczps70q.js} +2 -2
- package/dist/chunks/{studio-8ezdegcx.js → studio-zqazsct2.js} +40 -36
- package/dist/chunks/workspace-fjx52ryv.js +89 -0
- package/dist/iframe-entry.js +141 -56
- package/dist/manifest.json +7 -0
- package/dist/studio.js +2605 -1950
- package/favicon.ico +0 -0
- package/index.html +1 -0
- package/package.json +20 -18
- package/src/about/about-modal.ts +4 -3
- package/src/browse/library-pane.ts +57 -3
- package/src/canvas/canvas-render.ts +23 -1
- package/src/canvas/iframe-patch.ts +47 -21
- package/src/canvas/iframe-render.ts +22 -6
- package/src/commands/app-commands.ts +4 -0
- package/src/commands/command-args.ts +29 -0
- package/src/commands/context.ts +15 -1
- package/src/commands/defaults.ts +29 -1
- package/src/commands/levels.ts +16 -0
- package/src/commands/live-context.ts +3 -0
- package/src/content/collection-match.ts +267 -0
- package/src/content/entry-commands.ts +38 -29
- package/src/content/entry-fields.ts +6 -0
- package/src/editor/shortcuts.ts +5 -0
- package/src/files/file-ops.ts +10 -42
- package/src/files/files.ts +487 -59
- package/src/files/fs-events.ts +9 -0
- package/src/files/gitignore.ts +432 -0
- package/src/files/media-paths.ts +13 -42
- package/src/files/media-usage.ts +41 -131
- package/src/files/serialize-document.ts +60 -0
- package/src/format/convert-file.ts +511 -0
- package/src/format/format-choices.ts +199 -0
- package/src/grid/grid-view.ts +16 -2
- package/src/hosting/document.ts +2 -0
- package/src/hosting/layout.ts +8 -0
- package/src/media/media-open.ts +58 -0
- package/src/media/media-pane.ts +310 -0
- package/src/new-project/import-tab.ts +357 -163
- package/src/new-project/location-fields.ts +8 -5
- package/src/new-project/new-project-modal.ts +27 -34
- package/src/packages/ensure-deps.ts +14 -7
- package/src/packages/jxsuite-update.ts +11 -11
- package/src/page-params.ts +10 -46
- package/src/panels/activity-bar.ts +45 -16
- package/src/panels/ai-chat/attached-context.ts +6 -1
- package/src/panels/ai-chat/chat-view.ts +255 -13
- package/src/panels/ai-chat/composer.ts +31 -97
- package/src/panels/ai-panel.ts +116 -2
- package/src/panels/navigator-panels.ts +7 -6
- package/src/panels/settings-menu.ts +799 -0
- package/src/panels/toolbar.ts +135 -15
- package/src/platforms/cloud.ts +261 -70
- package/src/platforms/devserver.ts +67 -33
- package/src/preview/preview-overlay.ts +226 -0
- package/src/publish/publish-panel.ts +62 -2
- package/src/services/ai-ask.ts +247 -0
- package/src/services/ai-import-tools.ts +532 -0
- package/src/services/ai-models.ts +108 -1
- package/src/services/ai-project-tools.ts +20 -26
- package/src/services/ai-system-prompt.ts +88 -2
- package/src/services/ai-turn-signal.ts +70 -0
- package/src/services/connection.ts +74 -0
- package/src/services/context-manager.ts +101 -1
- package/src/services/document-assistant.ts +45 -4
- package/src/services/import-client.ts +33 -6
- package/src/services/import-run.ts +158 -0
- package/src/services/import-seed.ts +120 -0
- package/src/services/jx-validate.ts +58 -6
- package/src/services/project-adoption.ts +71 -0
- package/src/services/references.ts +0 -0
- package/src/services/settings/definitions.ts +17 -0
- package/src/services/tool-executor.ts +45 -2
- package/src/settings/contexts-section.ts +45 -3
- package/src/settings/dependencies-editor.ts +43 -23
- package/src/settings/general-settings.ts +30 -12
- package/src/settings/preferences-accounts.ts +193 -12
- package/src/settings/preferences-dialog.ts +93 -59
- package/src/settings/preferences-sections.ts +57 -0
- package/src/settings/settings-document.ts +65 -9
- package/src/studio.ts +33 -6
- package/src/tabs/transact.ts +42 -19
- package/src/types.ts +129 -7
- package/src/ui/ai-managed-connect.ts +62 -13
- package/src/ui/ai-model-picker.ts +189 -0
- package/src/ui/cf-account-picker.ts +200 -0
- package/src/ui/choice-field.ts +72 -0
- package/src/ui/layers.ts +83 -5
- package/src/utils/studio-utils.ts +22 -52
- package/styles/forced-colors.css +7 -0
- package/styles/overlays.css +256 -0
- package/styles/panels.css +13 -1
- package/styles/shell.css +147 -0
- package/dist/chunks/Overlay.dev-d2ajy6sj.js +0 -23
- package/dist/chunks/content-source-7fy9qrm0.js +0 -40
- package/dist/chunks/files-xcybanxe.js +0 -70
- package/dist/chunks/layers-panel-27essgkc.js +0 -60
- package/dist/chunks/publish-panel-09sy2bab.js +0 -22
- package/dist/chunks/quick-search-sefb61v8.js +0 -55
- package/dist/chunks/right-panel-9r32jd5j.js +0 -39
- package/dist/chunks/sp-overlay.dev-s18hymn9.js +0 -18
- package/dist/chunks/sp-popover.dev-dj9x7e7a.js +0 -9
- package/dist/chunks/sp-progress-circle.dev-0zxcyz3r.js +0 -15
- package/dist/chunks/sp-tooltip.dev-5c6d1kjz.js +0 -15
- package/dist/chunks/studio-bw5dz6km.js +0 -608
- package/dist/chunks/studio-c31yb4t6.js +0 -55
- package/src/canvas/site-style-css.ts +0 -117
|
@@ -2,7 +2,39 @@ import {
|
|
|
2
2
|
_$LH,
|
|
3
3
|
noChange,
|
|
4
4
|
nothing
|
|
5
|
-
} from "./studio-
|
|
5
|
+
} from "./studio-kryvsw6j.js";
|
|
6
|
+
|
|
7
|
+
// ../../node_modules/lit-html/development/directive.js
|
|
8
|
+
var PartType = {
|
|
9
|
+
ATTRIBUTE: 1,
|
|
10
|
+
CHILD: 2,
|
|
11
|
+
PROPERTY: 3,
|
|
12
|
+
BOOLEAN_ATTRIBUTE: 4,
|
|
13
|
+
EVENT: 5,
|
|
14
|
+
ELEMENT: 6
|
|
15
|
+
};
|
|
16
|
+
var directive = (c) => (...values) => ({
|
|
17
|
+
["_$litDirective$"]: c,
|
|
18
|
+
values
|
|
19
|
+
});
|
|
20
|
+
|
|
21
|
+
class Directive {
|
|
22
|
+
constructor(_partInfo) {}
|
|
23
|
+
get _$isConnected() {
|
|
24
|
+
return this._$parent._$isConnected;
|
|
25
|
+
}
|
|
26
|
+
_$initialize(part, parent, attributeIndex) {
|
|
27
|
+
this.__part = part;
|
|
28
|
+
this._$parent = parent;
|
|
29
|
+
this.__attributeIndex = attributeIndex;
|
|
30
|
+
}
|
|
31
|
+
_$resolve(part, props) {
|
|
32
|
+
return this.update(part, props);
|
|
33
|
+
}
|
|
34
|
+
update(_part, props) {
|
|
35
|
+
return this.render(...props);
|
|
36
|
+
}
|
|
37
|
+
}
|
|
6
38
|
|
|
7
39
|
// ../../node_modules/lit-html/development/directive-helpers.js
|
|
8
40
|
var { _ChildPart: ChildPart } = _$LH;
|
|
@@ -53,37 +85,44 @@ var removePart = (part) => {
|
|
|
53
85
|
part._$startNode.remove();
|
|
54
86
|
};
|
|
55
87
|
|
|
56
|
-
// ../../node_modules/lit-html/development/
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
["_$litDirective$"]: c,
|
|
67
|
-
values
|
|
68
|
-
});
|
|
69
|
-
|
|
70
|
-
class Directive {
|
|
71
|
-
constructor(_partInfo) {}
|
|
72
|
-
get _$isConnected() {
|
|
73
|
-
return this._$parent._$isConnected;
|
|
74
|
-
}
|
|
75
|
-
_$initialize(part, parent, attributeIndex) {
|
|
76
|
-
this.__part = part;
|
|
77
|
-
this._$parent = parent;
|
|
78
|
-
this.__attributeIndex = attributeIndex;
|
|
88
|
+
// ../../node_modules/lit-html/development/directives/live.js
|
|
89
|
+
class LiveDirective extends Directive {
|
|
90
|
+
constructor(partInfo) {
|
|
91
|
+
super(partInfo);
|
|
92
|
+
if (!(partInfo.type === PartType.PROPERTY || partInfo.type === PartType.ATTRIBUTE || partInfo.type === PartType.BOOLEAN_ATTRIBUTE)) {
|
|
93
|
+
throw new Error("The `live` directive is not allowed on child or event bindings");
|
|
94
|
+
}
|
|
95
|
+
if (!isSingleExpression(partInfo)) {
|
|
96
|
+
throw new Error("`live` bindings can only contain a single expression");
|
|
97
|
+
}
|
|
79
98
|
}
|
|
80
|
-
|
|
81
|
-
return
|
|
99
|
+
render(value) {
|
|
100
|
+
return value;
|
|
82
101
|
}
|
|
83
|
-
update(
|
|
84
|
-
|
|
102
|
+
update(part, [value]) {
|
|
103
|
+
if (value === noChange || value === nothing) {
|
|
104
|
+
return value;
|
|
105
|
+
}
|
|
106
|
+
const element = part.element;
|
|
107
|
+
const name = part.name;
|
|
108
|
+
if (part.type === PartType.PROPERTY) {
|
|
109
|
+
if (value === element[name]) {
|
|
110
|
+
return noChange;
|
|
111
|
+
}
|
|
112
|
+
} else if (part.type === PartType.BOOLEAN_ATTRIBUTE) {
|
|
113
|
+
if (!!value === element.hasAttribute(name)) {
|
|
114
|
+
return noChange;
|
|
115
|
+
}
|
|
116
|
+
} else if (part.type === PartType.ATTRIBUTE) {
|
|
117
|
+
if (element.getAttribute(name) === String(value)) {
|
|
118
|
+
return noChange;
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
setCommittedValue(part);
|
|
122
|
+
return value;
|
|
85
123
|
}
|
|
86
124
|
}
|
|
125
|
+
var live = directive(LiveDirective);
|
|
87
126
|
|
|
88
127
|
// ../../node_modules/lit-html/development/async-directive.js
|
|
89
128
|
var DEV_MODE = true;
|
|
@@ -381,7 +420,7 @@ class RepeatDirective extends Directive {
|
|
|
381
420
|
}
|
|
382
421
|
var repeat = directive(RepeatDirective);
|
|
383
422
|
|
|
384
|
-
export { PartType, directive, Directive, isPrimitive,
|
|
423
|
+
export { PartType, directive, Directive, isPrimitive, setCommittedValue, live, AsyncDirective, createRef, ref, repeat };
|
|
385
424
|
|
|
386
|
-
//# debugId=
|
|
387
|
-
//# sourceMappingURL=studio-
|
|
425
|
+
//# debugId=5774C3287549C8FE64756E2164756E21
|
|
426
|
+
//# sourceMappingURL=studio-4rzyrtjz.js.map
|
|
@@ -12,18 +12,18 @@ import {
|
|
|
12
12
|
queryAssignedElements,
|
|
13
13
|
queryAssignedNodes,
|
|
14
14
|
state
|
|
15
|
-
} from "./studio-
|
|
15
|
+
} from "./studio-zczps70q.js";
|
|
16
16
|
import {
|
|
17
17
|
css
|
|
18
|
-
} from "./studio-
|
|
18
|
+
} from "./studio-7nte2hj4.js";
|
|
19
19
|
import {
|
|
20
20
|
ifDefined,
|
|
21
21
|
styleMap
|
|
22
|
-
} from "./studio-
|
|
22
|
+
} from "./studio-m3hwn7y1.js";
|
|
23
23
|
import {
|
|
24
24
|
html,
|
|
25
25
|
nothing
|
|
26
|
-
} from "./studio-
|
|
26
|
+
} from "./studio-kryvsw6j.js";
|
|
27
27
|
import {
|
|
28
28
|
__require,
|
|
29
29
|
__toESM
|
|
@@ -385,7 +385,7 @@ class AbstractOverlay extends SpectrumElement {
|
|
|
385
385
|
document.dispatchEvent(overlayUpdateEvent);
|
|
386
386
|
}
|
|
387
387
|
static async open(triggerOrContent, interactionOrOptions, content, optionsV1) {
|
|
388
|
-
await import("./sp-overlay.dev-
|
|
388
|
+
await import("./sp-overlay.dev-qgvhnxf4.js");
|
|
389
389
|
const v2 = arguments.length === 2;
|
|
390
390
|
const overlayContent = content || triggerOrContent;
|
|
391
391
|
const overlay = new this;
|
|
@@ -1685,12 +1685,12 @@ function getOppositePlacement(placement) {
|
|
|
1685
1685
|
return oppositeSideMap[side] + placement.slice(side.length);
|
|
1686
1686
|
}
|
|
1687
1687
|
function expandPaddingObject(padding) {
|
|
1688
|
+
var _padding$top, _padding$right, _padding$bottom, _padding$left;
|
|
1688
1689
|
return {
|
|
1689
|
-
top: 0,
|
|
1690
|
-
right: 0,
|
|
1691
|
-
bottom: 0,
|
|
1692
|
-
left: 0
|
|
1693
|
-
...padding
|
|
1690
|
+
top: (_padding$top = padding.top) != null ? _padding$top : 0,
|
|
1691
|
+
right: (_padding$right = padding.right) != null ? _padding$right : 0,
|
|
1692
|
+
bottom: (_padding$bottom = padding.bottom) != null ? _padding$bottom : 0,
|
|
1693
|
+
left: (_padding$left = padding.left) != null ? _padding$left : 0
|
|
1694
1694
|
};
|
|
1695
1695
|
}
|
|
1696
1696
|
function getPaddingObject(padding) {
|
|
@@ -1766,13 +1766,9 @@ function computeCoordsFromPlacement(_ref, placement, rtl) {
|
|
|
1766
1766
|
y: reference.y
|
|
1767
1767
|
};
|
|
1768
1768
|
}
|
|
1769
|
-
|
|
1770
|
-
|
|
1771
|
-
|
|
1772
|
-
break;
|
|
1773
|
-
case "end":
|
|
1774
|
-
coords[alignmentAxis] += commonAlign * (rtl && isVertical ? -1 : 1);
|
|
1775
|
-
break;
|
|
1769
|
+
const alignment = getAlignment(placement);
|
|
1770
|
+
if (alignment) {
|
|
1771
|
+
coords[alignmentAxis] += commonAlign * (alignment === "end" ? 1 : -1) * (rtl && isVertical ? -1 : 1);
|
|
1776
1772
|
}
|
|
1777
1773
|
return coords;
|
|
1778
1774
|
}
|
|
@@ -1812,10 +1808,7 @@ async function detectOverflow(state2, options) {
|
|
|
1812
1808
|
height: rects.floating.height
|
|
1813
1809
|
} : rects.reference;
|
|
1814
1810
|
const offsetParent = await (platform.getOffsetParent == null ? undefined : platform.getOffsetParent(elements.floating));
|
|
1815
|
-
const offsetScale = await (platform.isElement == null ? undefined : platform.isElement(offsetParent))
|
|
1816
|
-
x: 1,
|
|
1817
|
-
y: 1
|
|
1818
|
-
} : {
|
|
1811
|
+
const offsetScale = await (platform.isElement == null ? undefined : platform.isElement(offsetParent)) && await (platform.getScale == null ? undefined : platform.getScale(offsetParent)) || {
|
|
1819
1812
|
x: 1,
|
|
1820
1813
|
y: 1
|
|
1821
1814
|
};
|
|
@@ -1963,12 +1956,11 @@ var arrow = (options) => ({
|
|
|
1963
1956
|
const largestPossiblePadding = clientSize / 2 - arrowDimensions[length] / 2 - 1;
|
|
1964
1957
|
const minPadding = min(paddingObject[minProp], largestPossiblePadding);
|
|
1965
1958
|
const maxPadding = min(paddingObject[maxProp], largestPossiblePadding);
|
|
1966
|
-
const min$1 = minPadding;
|
|
1967
1959
|
const max2 = clientSize - arrowDimensions[length] - maxPadding;
|
|
1968
1960
|
const center = clientSize / 2 - arrowDimensions[length] / 2 + centerToReference;
|
|
1969
|
-
const offset = clamp(
|
|
1970
|
-
const shouldAddOffset = !middlewareData.arrow && getAlignment(placement) != null && center !== offset && rects.reference[length] / 2 - (center <
|
|
1971
|
-
const alignmentOffset = shouldAddOffset ? center <
|
|
1961
|
+
const offset = clamp(minPadding, center, max2);
|
|
1962
|
+
const shouldAddOffset = !middlewareData.arrow && getAlignment(placement) != null && center !== offset && rects.reference[length] / 2 - (center < minPadding ? minPadding : maxPadding) - arrowDimensions[length] / 2 < 0;
|
|
1963
|
+
const alignmentOffset = shouldAddOffset ? center < minPadding ? center - minPadding : center - max2 : 0;
|
|
1972
1964
|
return {
|
|
1973
1965
|
[axis]: coords[axis] + alignmentOffset,
|
|
1974
1966
|
data: {
|
|
@@ -2191,23 +2183,16 @@ var shift = function(options) {
|
|
|
2191
2183
|
y
|
|
2192
2184
|
};
|
|
2193
2185
|
const overflow = await platform.detectOverflow(state2, detectOverflowOptions);
|
|
2194
|
-
const crossAxis = getSideAxis(
|
|
2186
|
+
const crossAxis = getSideAxis(placement);
|
|
2195
2187
|
const mainAxis = getOppositeAxis(crossAxis);
|
|
2196
2188
|
let mainAxisCoord = coords[mainAxis];
|
|
2197
2189
|
let crossAxisCoord = coords[crossAxis];
|
|
2190
|
+
const clampCoord = (axis, coord) => clamp(coord + overflow[axis === "y" ? "top" : "left"], coord, coord - overflow[axis === "y" ? "bottom" : "right"]);
|
|
2198
2191
|
if (checkMainAxis) {
|
|
2199
|
-
|
|
2200
|
-
const maxSide = mainAxis === "y" ? "bottom" : "right";
|
|
2201
|
-
const min2 = mainAxisCoord + overflow[minSide];
|
|
2202
|
-
const max2 = mainAxisCoord - overflow[maxSide];
|
|
2203
|
-
mainAxisCoord = clamp(min2, mainAxisCoord, max2);
|
|
2192
|
+
mainAxisCoord = clampCoord(mainAxis, mainAxisCoord);
|
|
2204
2193
|
}
|
|
2205
2194
|
if (checkCrossAxis) {
|
|
2206
|
-
|
|
2207
|
-
const maxSide = crossAxis === "y" ? "bottom" : "right";
|
|
2208
|
-
const min2 = crossAxisCoord + overflow[minSide];
|
|
2209
|
-
const max2 = crossAxisCoord - overflow[maxSide];
|
|
2210
|
-
crossAxisCoord = clamp(min2, crossAxisCoord, max2);
|
|
2195
|
+
crossAxisCoord = clampCoord(crossAxis, crossAxisCoord);
|
|
2211
2196
|
}
|
|
2212
2197
|
const limitedCoords = limiter.fn({
|
|
2213
2198
|
...state2,
|
|
@@ -2236,7 +2221,6 @@ var size = function(options) {
|
|
|
2236
2221
|
name: "size",
|
|
2237
2222
|
options,
|
|
2238
2223
|
async fn(state2) {
|
|
2239
|
-
var _state$middlewareData, _state$middlewareData2;
|
|
2240
2224
|
const {
|
|
2241
2225
|
placement,
|
|
2242
2226
|
rects,
|
|
@@ -2268,24 +2252,21 @@ var size = function(options) {
|
|
|
2268
2252
|
const maximumClippingWidth = width - overflow.left - overflow.right;
|
|
2269
2253
|
const overflowAvailableHeight = min(height - overflow[heightSide], maximumClippingHeight);
|
|
2270
2254
|
const overflowAvailableWidth = min(width - overflow[widthSide], maximumClippingWidth);
|
|
2271
|
-
const
|
|
2255
|
+
const shiftData = state2.middlewareData.shift;
|
|
2256
|
+
const noShift = !shiftData;
|
|
2272
2257
|
let availableHeight = overflowAvailableHeight;
|
|
2273
2258
|
let availableWidth = overflowAvailableWidth;
|
|
2274
|
-
if (
|
|
2259
|
+
if (shiftData != null && shiftData.enabled.x) {
|
|
2275
2260
|
availableWidth = maximumClippingWidth;
|
|
2276
2261
|
}
|
|
2277
|
-
if (
|
|
2262
|
+
if (shiftData != null && shiftData.enabled.y) {
|
|
2278
2263
|
availableHeight = maximumClippingHeight;
|
|
2279
2264
|
}
|
|
2280
2265
|
if (noShift && !alignment) {
|
|
2281
|
-
const xMin = max(overflow.left, 0);
|
|
2282
|
-
const xMax = max(overflow.right, 0);
|
|
2283
|
-
const yMin = max(overflow.top, 0);
|
|
2284
|
-
const yMax = max(overflow.bottom, 0);
|
|
2285
2266
|
if (isYAxis) {
|
|
2286
|
-
availableWidth = width - 2 *
|
|
2267
|
+
availableWidth = width - 2 * max(overflow.left, overflow.right);
|
|
2287
2268
|
} else {
|
|
2288
|
-
availableHeight = height - 2 *
|
|
2269
|
+
availableHeight = height - 2 * max(overflow.top, overflow.bottom);
|
|
2289
2270
|
}
|
|
2290
2271
|
}
|
|
2291
2272
|
await apply({
|
|
@@ -2436,7 +2417,7 @@ function getParentNode(node) {
|
|
|
2436
2417
|
function getNearestOverflowAncestor(node) {
|
|
2437
2418
|
const parentNode = getParentNode(node);
|
|
2438
2419
|
if (isLastTraversableNode(parentNode)) {
|
|
2439
|
-
return node.ownerDocument
|
|
2420
|
+
return (node.ownerDocument || node).body;
|
|
2440
2421
|
}
|
|
2441
2422
|
if (isHTMLElement(parentNode) && isOverflowElement(parentNode)) {
|
|
2442
2423
|
return parentNode;
|
|
@@ -3379,12 +3360,12 @@ class InteractionController {
|
|
|
3379
3360
|
return;
|
|
3380
3361
|
}
|
|
3381
3362
|
customElements.whenDefined("sp-overlay").then(async () => {
|
|
3382
|
-
const { Overlay } = await import("./Overlay.dev-
|
|
3363
|
+
const { Overlay } = await import("./Overlay.dev-etqjwyf9.js");
|
|
3383
3364
|
this.overlay = new Overlay;
|
|
3384
3365
|
this.overlay.open = true;
|
|
3385
3366
|
this.target[lastInteractionType] = this.type;
|
|
3386
3367
|
});
|
|
3387
|
-
import("./sp-overlay.dev-
|
|
3368
|
+
import("./sp-overlay.dev-qgvhnxf4.js");
|
|
3388
3369
|
}
|
|
3389
3370
|
get overlay() {
|
|
3390
3371
|
return this._overlay;
|
|
@@ -4009,7 +3990,7 @@ var _Overlay = class _Overlay2 extends ComputedOverlayBase {
|
|
|
4009
3990
|
return;
|
|
4010
3991
|
}
|
|
4011
3992
|
if (targetOpenState) {
|
|
4012
|
-
const focusTrap = await import("./focus-trap.esm-
|
|
3993
|
+
const focusTrap = await import("./focus-trap.esm-9t2drp0g.js");
|
|
4013
3994
|
const initialFocus = this.receivesFocus === "false" ? false : focusEl || undefined;
|
|
4014
3995
|
this._focusTrap = focusTrap.createFocusTrap(this.dialogEl, {
|
|
4015
3996
|
initialFocus,
|
|
@@ -4340,5 +4321,5 @@ var Overlay = _Overlay;
|
|
|
4340
4321
|
|
|
4341
4322
|
export { FocusVisiblePolyfillMixin, Focusable, LikeAnchor, MutationController, ObserveSlotPresence, ObserveSlotText, isIPhone, isIOS, isWebKit, isAndroid, randomID, conditionAttributeWithoutId, conditionAttributeWithId, elementResolverUpdatedSymbol, ElementResolutionController, LONGPRESS_INSTRUCTIONS, SlottableRequestEvent, Overlay };
|
|
4342
4323
|
|
|
4343
|
-
//# debugId=
|
|
4344
|
-
//# sourceMappingURL=studio-
|
|
4324
|
+
//# debugId=870A47F946E355DE64756E2164756E21
|
|
4325
|
+
//# sourceMappingURL=studio-5fx3g9jg.js.map
|