@ai-ecoverse/slicc-spectrum 2.0.2 → 2.0.3
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 -4
- package/dist/{chunk-EFJJ7K57.js → chunk-NMHCUT6N.js} +1725 -1732
- package/dist/chunk-NMHCUT6N.js.map +7 -0
- package/dist/slicc-ui.js +129 -57
- package/dist/slicc-ui.js.map +3 -3
- package/dist/types/app/command.d.ts +1 -0
- package/package.json +3 -3
- package/dist/chunk-EFJJ7K57.js.map +0 -7
package/dist/slicc-ui.js
CHANGED
|
@@ -10587,12 +10587,17 @@ var Cuts = class {
|
|
|
10587
10587
|
};
|
|
10588
10588
|
var Ends = class {
|
|
10589
10589
|
#seen = /* @__PURE__ */ new Set();
|
|
10590
|
+
#looked = /* @__PURE__ */ new Set();
|
|
10590
10591
|
#root;
|
|
10591
10592
|
#changed;
|
|
10592
10593
|
#observer = new IntersectionObserver((entries) => {
|
|
10593
10594
|
let changed2 = false;
|
|
10594
10595
|
for (const entry of entries) {
|
|
10595
10596
|
const id = entry.target.dataset.end;
|
|
10597
|
+
if (!this.#looked.has(id)) {
|
|
10598
|
+
this.#looked.add(id);
|
|
10599
|
+
changed2 = true;
|
|
10600
|
+
}
|
|
10596
10601
|
if (!entry.isIntersecting || this.#seen.has(id)) continue;
|
|
10597
10602
|
this.#seen.add(id);
|
|
10598
10603
|
changed2 = true;
|
|
@@ -10606,8 +10611,12 @@ var Ends = class {
|
|
|
10606
10611
|
has(id) {
|
|
10607
10612
|
return this.#seen.has(id);
|
|
10608
10613
|
}
|
|
10614
|
+
hidden(id) {
|
|
10615
|
+
return this.#looked.has(id) && !this.#seen.has(id);
|
|
10616
|
+
}
|
|
10609
10617
|
clear() {
|
|
10610
10618
|
this.#seen.clear();
|
|
10619
|
+
this.#looked.clear();
|
|
10611
10620
|
}
|
|
10612
10621
|
observe() {
|
|
10613
10622
|
for (const end of this.#root().querySelectorAll("[data-end]"))
|
|
@@ -49879,8 +49888,10 @@ var SliccApprovals = class extends ModelElement {
|
|
|
49879
49888
|
gone: { state: true }
|
|
49880
49889
|
};
|
|
49881
49890
|
arming = 500;
|
|
49882
|
-
#
|
|
49883
|
-
#
|
|
49891
|
+
#changed = 0;
|
|
49892
|
+
#pressed = 0;
|
|
49893
|
+
#layout = "";
|
|
49894
|
+
#moves = new ResizeObserver(() => this.#settle());
|
|
49884
49895
|
#showing = null;
|
|
49885
49896
|
#pending = /* @__PURE__ */ new Set();
|
|
49886
49897
|
#done = /* @__PURE__ */ new Set();
|
|
@@ -49890,11 +49901,6 @@ var SliccApprovals = class extends ModelElement {
|
|
|
49890
49901
|
#timer = null;
|
|
49891
49902
|
#shown = "";
|
|
49892
49903
|
#trigger = null;
|
|
49893
|
-
#full = /* @__PURE__ */ new Set();
|
|
49894
|
-
#cuts = new Cuts(
|
|
49895
|
-
() => this.renderRoot,
|
|
49896
|
-
() => this.requestUpdate()
|
|
49897
|
-
);
|
|
49898
49904
|
#ends = new Ends(
|
|
49899
49905
|
() => this.renderRoot,
|
|
49900
49906
|
() => this.requestUpdate()
|
|
@@ -49908,7 +49914,6 @@ var SliccApprovals = class extends ModelElement {
|
|
|
49908
49914
|
}
|
|
49909
49915
|
static styles = [
|
|
49910
49916
|
dialogStyles,
|
|
49911
|
-
clampCss,
|
|
49912
49917
|
i`
|
|
49913
49918
|
:host {
|
|
49914
49919
|
display: contents;
|
|
@@ -49955,9 +49960,6 @@ var SliccApprovals = class extends ModelElement {
|
|
|
49955
49960
|
inline-size: 0;
|
|
49956
49961
|
block-size: 0;
|
|
49957
49962
|
}
|
|
49958
|
-
.full-command {
|
|
49959
|
-
margin-block-start: var(--swc-spacing-100);
|
|
49960
|
-
}
|
|
49961
49963
|
.guest {
|
|
49962
49964
|
margin-block-start: var(--swc-spacing-200);
|
|
49963
49965
|
padding: var(--swc-spacing-200) var(--swc-spacing-300);
|
|
@@ -49990,16 +49992,39 @@ var SliccApprovals = class extends ModelElement {
|
|
|
49990
49992
|
margin-block-start: var(--swc-spacing-300);
|
|
49991
49993
|
font-variant-numeric: tabular-nums;
|
|
49992
49994
|
}
|
|
49995
|
+
.more {
|
|
49996
|
+
min-block-size: 1lh;
|
|
49997
|
+
}
|
|
49998
|
+
.notes {
|
|
49999
|
+
display: flex;
|
|
50000
|
+
flex-direction: column;
|
|
50001
|
+
gap: var(--swc-spacing-100);
|
|
50002
|
+
box-sizing: border-box;
|
|
50003
|
+
block-size: min(9lh, 30dvh);
|
|
50004
|
+
margin-block-start: var(--swc-spacing-200);
|
|
50005
|
+
font-size: var(--swc-font-size-75);
|
|
50006
|
+
overflow-y: auto;
|
|
50007
|
+
overscroll-behavior: contain;
|
|
50008
|
+
}
|
|
50009
|
+
.notes .hint,
|
|
50010
|
+
.notes .verdict {
|
|
50011
|
+
margin: 0;
|
|
50012
|
+
}
|
|
50013
|
+
.judge {
|
|
50014
|
+
display: flex;
|
|
50015
|
+
flex: 1 0 auto;
|
|
50016
|
+
flex-direction: column;
|
|
50017
|
+
gap: var(--swc-spacing-100);
|
|
50018
|
+
}
|
|
49993
50019
|
.judged {
|
|
49994
50020
|
display: flex;
|
|
50021
|
+
flex: 1 0 auto;
|
|
49995
50022
|
align-items: flex-start;
|
|
49996
50023
|
gap: var(--swc-spacing-100);
|
|
49997
|
-
margin-block-start: var(--swc-spacing-200);
|
|
49998
50024
|
padding: var(--swc-spacing-200) var(--swc-spacing-300);
|
|
49999
50025
|
border-radius: var(--swc-corner-radius-medium-default);
|
|
50000
50026
|
background: var(--swc-neutral-subtle-background-color-default);
|
|
50001
50027
|
color: var(--swc-neutral-content-color-default);
|
|
50002
|
-
font-size: var(--swc-font-size-75);
|
|
50003
50028
|
overflow-wrap: anywhere;
|
|
50004
50029
|
}
|
|
50005
50030
|
.judged[data-verdict='checking'],
|
|
@@ -50023,6 +50048,9 @@ var SliccApprovals = class extends ModelElement {
|
|
|
50023
50048
|
.judged p {
|
|
50024
50049
|
margin: 0;
|
|
50025
50050
|
}
|
|
50051
|
+
[slot='button'][data-action='deny'] {
|
|
50052
|
+
margin-inline-end: auto;
|
|
50053
|
+
}
|
|
50026
50054
|
.problem {
|
|
50027
50055
|
display: flex;
|
|
50028
50056
|
align-items: flex-start;
|
|
@@ -50045,7 +50073,6 @@ var SliccApprovals = class extends ModelElement {
|
|
|
50045
50073
|
this.#done.clear();
|
|
50046
50074
|
this.#closed.clear();
|
|
50047
50075
|
this.#ended.clear();
|
|
50048
|
-
this.#full.clear();
|
|
50049
50076
|
this.#ends.clear();
|
|
50050
50077
|
}
|
|
50051
50078
|
if (!port) return [];
|
|
@@ -50067,9 +50094,9 @@ var SliccApprovals = class extends ModelElement {
|
|
|
50067
50094
|
disconnectedCallback() {
|
|
50068
50095
|
super.disconnectedCallback();
|
|
50069
50096
|
this.#tick(false);
|
|
50070
|
-
clearTimeout(this.#arming);
|
|
50071
50097
|
this.#showing = null;
|
|
50072
|
-
this.#
|
|
50098
|
+
this.#layout = "";
|
|
50099
|
+
this.#moves.disconnect();
|
|
50073
50100
|
this.#ends.disconnect();
|
|
50074
50101
|
}
|
|
50075
50102
|
#tick(on2) {
|
|
@@ -50081,7 +50108,7 @@ var SliccApprovals = class extends ModelElement {
|
|
|
50081
50108
|
}
|
|
50082
50109
|
async decide(approval, decision2) {
|
|
50083
50110
|
const port = this.model?.approvals;
|
|
50084
|
-
if (!port?.decide || this.busy || decision2 !== "deny" && (!this.#
|
|
50111
|
+
if (!port?.decide || this.busy || decision2 !== "deny" && (!this.#settled(performance.now()) || !this.#whole(approval)))
|
|
50085
50112
|
return;
|
|
50086
50113
|
const live = port.list().find(({ id }) => id === approval.id);
|
|
50087
50114
|
if (decision2 === "always" && !(live && offersAlways(live))) return;
|
|
@@ -50117,17 +50144,46 @@ var SliccApprovals = class extends ModelElement {
|
|
|
50117
50144
|
const next = list6[0] ?? null;
|
|
50118
50145
|
if (next?.id === showing?.id) return;
|
|
50119
50146
|
this.#showing = next;
|
|
50120
|
-
|
|
50121
|
-
|
|
50122
|
-
|
|
50147
|
+
this.#changed = performance.now();
|
|
50148
|
+
}
|
|
50149
|
+
#settled(at) {
|
|
50150
|
+
return at - this.#changed >= this.arming;
|
|
50151
|
+
}
|
|
50152
|
+
#settle() {
|
|
50153
|
+
const dialog = this.renderRoot.querySelector("dialog");
|
|
50154
|
+
const buttons = [...this.renderRoot.querySelectorAll("[slot=button]")];
|
|
50155
|
+
const layout = JSON.stringify([
|
|
50156
|
+
dialog?.dataset.approval,
|
|
50157
|
+
dialog?.dataset.gone,
|
|
50158
|
+
buttons.map((button) => {
|
|
50159
|
+
const { left, top, width, height } = button.getBoundingClientRect();
|
|
50160
|
+
return [
|
|
50161
|
+
button.dataset.action,
|
|
50162
|
+
button.textContent,
|
|
50163
|
+
button.hasAttribute("disabled"),
|
|
50164
|
+
button.hasAttribute("pending"),
|
|
50165
|
+
...[left, top, width, height].map(Math.round)
|
|
50166
|
+
];
|
|
50167
|
+
})
|
|
50168
|
+
]);
|
|
50169
|
+
if (layout === this.#layout) return;
|
|
50170
|
+
this.#layout = layout;
|
|
50171
|
+
this.#changed = performance.now();
|
|
50172
|
+
}
|
|
50173
|
+
#click(event2, approval, decision2) {
|
|
50174
|
+
if (!this.#settled(event2.detail ? this.#pressed : performance.now())) return;
|
|
50175
|
+
void this.decide(approval, decision2);
|
|
50123
50176
|
}
|
|
50124
50177
|
updated(changed2) {
|
|
50125
50178
|
super.updated(changed2);
|
|
50126
50179
|
const all2 = this.model?.approvals?.list() ?? [];
|
|
50127
50180
|
this.#tick(this.isConnected && all2.length > 0);
|
|
50128
|
-
this.#cuts.measure();
|
|
50129
50181
|
this.#ends.observe();
|
|
50130
50182
|
const dialog = this.renderRoot.querySelector("dialog");
|
|
50183
|
+
if (dialog)
|
|
50184
|
+
for (const box of dialog.querySelectorAll("sp-alert-dialog, [slot=button]"))
|
|
50185
|
+
this.#moves.observe(box);
|
|
50186
|
+
this.#settle();
|
|
50131
50187
|
const key = dialog ? `${dialog.dataset.approval}:${dialog.dataset.gone ?? ""}:${dialog.hasAttribute("data-rejected")}` : "";
|
|
50132
50188
|
if (key === this.#shown) return;
|
|
50133
50189
|
if (dialog && !this.#shown) this.#trigger = origin();
|
|
@@ -50138,8 +50194,8 @@ var SliccApprovals = class extends ModelElement {
|
|
|
50138
50194
|
return;
|
|
50139
50195
|
}
|
|
50140
50196
|
if (!dialog.open) dialog.showModal();
|
|
50141
|
-
this.#cuts.measure();
|
|
50142
50197
|
this.#ends.observe();
|
|
50198
|
+
this.#settle();
|
|
50143
50199
|
const first2 = dialog.querySelector("[data-action=deny], [data-action=close]");
|
|
50144
50200
|
void first2.updateComplete.then(() => first2.focus());
|
|
50145
50201
|
}
|
|
@@ -50165,38 +50221,30 @@ var SliccApprovals = class extends ModelElement {
|
|
|
50165
50221
|
fill-style=${variant === "accent" ? A : "outline"}
|
|
50166
50222
|
data-action=${decision2}
|
|
50167
50223
|
?pending=${this.busy === decision2}
|
|
50168
|
-
?disabled=${!!this.busy && this.busy !== decision2}
|
|
50169
|
-
@click=${() => this
|
|
50224
|
+
?disabled=${!!this.busy && this.busy !== decision2 || decision2 !== "deny" && !this.#whole(approval)}
|
|
50225
|
+
@click=${(event2) => this.#click(event2, approval, decision2)}
|
|
50170
50226
|
>${label}</swc-button
|
|
50171
50227
|
>`;
|
|
50172
50228
|
}
|
|
50173
50229
|
#dialog(approval, key, content3) {
|
|
50174
50230
|
return i23(
|
|
50175
50231
|
key,
|
|
50176
|
-
b`<dialog role="alertdialog" aria-labelledby="title" aria-describedby="asking" data-approval=${approval.id} data-kind=${approval.kind} data-requester=${approval.requester.kind} data-gone=${this.gone?.reason ?? A} data-rejected=${!this.gone && this.failure?.id === approval.id ? "" : A} @cancel=${(event2) => this.#cancel(event2, approval)}>${content3}</dialog>`
|
|
50232
|
+
b`<dialog role="alertdialog" aria-labelledby="title" aria-describedby="asking" data-approval=${approval.id} data-kind=${approval.kind} data-requester=${approval.requester.kind} data-gone=${this.gone?.reason ?? A} data-rejected=${!this.gone && this.failure?.id === approval.id ? "" : A} @pointerdown=${() => this.#pressed = performance.now()} @cancel=${(event2) => this.#cancel(event2, approval)}>${content3}</dialog>`
|
|
50177
50233
|
);
|
|
50178
50234
|
}
|
|
50179
50235
|
#whole(approval) {
|
|
50180
|
-
const { id } = approval;
|
|
50181
50236
|
if (truncated(approval)) return false;
|
|
50182
|
-
return !approved(approval) || this.#
|
|
50237
|
+
return !approved(approval) || this.#ends.has(approval.id);
|
|
50183
50238
|
}
|
|
50184
50239
|
#gate(approval) {
|
|
50185
50240
|
if (truncated(approval)) return tooLong;
|
|
50186
|
-
|
|
50187
|
-
return this.#full.has(approval.id) ? toScroll : toShow;
|
|
50188
|
-
}
|
|
50189
|
-
#expand(id) {
|
|
50190
|
-
if (!this.#full.delete(id)) this.#full.add(id);
|
|
50191
|
-
this.requestUpdate();
|
|
50241
|
+
return this.#ends.hidden(approval.id) ? toScroll : "";
|
|
50192
50242
|
}
|
|
50193
50243
|
#command(approval, pending) {
|
|
50194
50244
|
const { id } = approval;
|
|
50195
50245
|
const text4 = approved(approval);
|
|
50196
50246
|
if (!text4) return b`<p class="hint" data-id="no-details">This request has no details.</p>`;
|
|
50197
|
-
|
|
50198
|
-
const toggle = pending && (full || this.#cuts.get(id)) ? fullCommand(full, () => this.#expand(id)) : A;
|
|
50199
|
-
return b`<pre class="command" data-command=${approval.kind === "sudo" ? "" : A} data-summary=${approval.kind === "sudo" ? A : ""}><span class="lines" data-clamp=${full ? A : id}>${approval.kind === "sudo" ? commandText(text4) : text4}${pending ? b`<span class="end" data-end=${id}></span>` : A}</span></pre>${toggle}`;
|
|
50247
|
+
return b`<pre class="command" data-command=${approval.kind === "sudo" ? "" : A} data-summary=${approval.kind === "sudo" ? A : ""}><span class="lines">${approval.kind === "sudo" ? commandText(text4) : text4}${pending ? b`<span class="end" data-end=${id}></span>` : A}</span></pre>`;
|
|
50200
50248
|
}
|
|
50201
50249
|
#request(approval, pending = false) {
|
|
50202
50250
|
if (approval.kind === "tray") return b`<p id="asking">${trayAsking(approval)}</p>`;
|
|
@@ -50211,18 +50259,17 @@ var SliccApprovals = class extends ModelElement {
|
|
|
50211
50259
|
<div class="guest" data-guest-text>${approval.text}</div>
|
|
50212
50260
|
${files.length ? b`<ul class="files" data-attachments>${files.map((file) => b`<li>${file.name} · ${file.mimeType} · ${size3(file.size)}</li>`)}</ul>` : A}`;
|
|
50213
50261
|
}
|
|
50214
|
-
#
|
|
50262
|
+
#notes(approval, gate, always) {
|
|
50215
50263
|
if (approval.kind === "tray") return A;
|
|
50216
50264
|
const note = verdictNote(approval);
|
|
50217
|
-
return b`<div class="judge" aria-live="polite">${judged(approval)}${note ? b`<p class="hint" data-verdict-note>${note}</p>` : A}</div>`;
|
|
50265
|
+
return b`<div class="notes" data-notes><div class="judge" aria-live="polite">${judged(approval)}${note ? b`<p class="hint" data-verdict-note>${note}</p>` : A}</div>${gate ? b`<p class="hint" data-allow-hint>${gate}</p>` : A}${always ? b`<p class="hint" data-always-hint>${hintOf(approval)}</p>` : A}</div>`;
|
|
50218
50266
|
}
|
|
50219
50267
|
#actions(approval, rejected, always) {
|
|
50220
50268
|
if (rejected)
|
|
50221
50269
|
return b`<swc-button slot="button" variant="secondary" fill-style="outline" data-action="close" @click=${() => this.#dismiss(approval)}>Close</swc-button>`;
|
|
50222
|
-
const whole = this.#whole(approval);
|
|
50223
50270
|
return b`${this.#button(approval, "deny", "Deny", "secondary")}
|
|
50224
|
-
${
|
|
50225
|
-
${
|
|
50271
|
+
${always ? this.#button(approval, "always", inCwd(approval) ? "Always allow in this directory" : "Always allow", "secondary") : A}
|
|
50272
|
+
${this.#button(approval, "once", "Allow once", "accent")}`;
|
|
50226
50273
|
}
|
|
50227
50274
|
render() {
|
|
50228
50275
|
if (this.gone) {
|
|
@@ -50244,8 +50291,7 @@ var SliccApprovals = class extends ModelElement {
|
|
|
50244
50291
|
if (!approval) return A;
|
|
50245
50292
|
const failure3 = this.failure?.id === approval.id ? this.failure.message : "";
|
|
50246
50293
|
const always = offersAlways(approval);
|
|
50247
|
-
const gate = this.#gate(approval);
|
|
50248
|
-
const hint2 = always && this.#whole(approval) ? hintOf(approval) : "";
|
|
50294
|
+
const gate = failure3 ? "" : this.#gate(approval);
|
|
50249
50295
|
return this.#dialog(
|
|
50250
50296
|
approval,
|
|
50251
50297
|
approval.id,
|
|
@@ -50253,11 +50299,9 @@ var SliccApprovals = class extends ModelElement {
|
|
|
50253
50299
|
<h2 id="title" slot="heading">${title(approval)}</h2>
|
|
50254
50300
|
${this.#request(approval, true)}
|
|
50255
50301
|
${approval.kind === "sudo" && approval.cwd ? b`<p class="cwd">In ${commandText(approval.cwd, false)}</p>` : A}
|
|
50256
|
-
${this.#
|
|
50257
|
-
${hint2 ? b`<p class="hint">${hint2}</p>` : A}
|
|
50258
|
-
${!failure3 && gate ? b`<p class="hint" data-allow-hint>${gate}</p>` : A}
|
|
50302
|
+
${this.#notes(approval, gate, always)}
|
|
50259
50303
|
${failure3 ? b`<p class="problem" role="alert" data-error><swc-icon-alert-triangle size="s" aria-hidden="true"></swc-icon-alert-triangle><span>${failure3}</span></p>` : b`<p class="timer" data-timer>Denied automatically in ${countdown(approval.expiresAt - this.now)}.</p>`}
|
|
50260
|
-
|
|
50304
|
+
<p class="more" data-more=${rest.length ? "" : A}>${rest.length === 1 ? "1 more request is waiting." : rest.length ? `${rest.length} more requests are waiting.` : ""}</p>
|
|
50261
50305
|
${this.#actions(approval, !!failure3, always)}
|
|
50262
50306
|
</sp-alert-dialog>`
|
|
50263
50307
|
);
|
|
@@ -51994,7 +52038,7 @@ var SliccDiffPanel = class extends ThemedElement {
|
|
|
51994
52038
|
// src/app/lucide.ts
|
|
51995
52039
|
var library = null;
|
|
51996
52040
|
function load2() {
|
|
51997
|
-
library ??= import("./chunk-
|
|
52041
|
+
library ??= import("./chunk-NMHCUT6N.js");
|
|
51998
52042
|
return library;
|
|
51999
52043
|
}
|
|
52000
52044
|
function pascal(name) {
|
|
@@ -70197,6 +70241,10 @@ var PositionCache = class {
|
|
|
70197
70241
|
}
|
|
70198
70242
|
};
|
|
70199
70243
|
var SCHEDULED = -1;
|
|
70244
|
+
function isInCollapsedEdgeGroup(panel) {
|
|
70245
|
+
const api = panel.group.api;
|
|
70246
|
+
return api.location.type === "edge" && api.isCollapsed();
|
|
70247
|
+
}
|
|
70200
70248
|
function createFocusableElement() {
|
|
70201
70249
|
const element2 = document.createElement("div");
|
|
70202
70250
|
element2.tabIndex = -1;
|
|
@@ -70270,6 +70318,7 @@ var OverlayRenderContainer = class extends CompositeDisposable {
|
|
|
70270
70318
|
return false;
|
|
70271
70319
|
}
|
|
70272
70320
|
attach(options2) {
|
|
70321
|
+
var _panel$group$api$onDi, _panel$group$api$onDi2, _panel$group$api;
|
|
70273
70322
|
const { panel, referenceContainer } = options2;
|
|
70274
70323
|
if (!this.map[panel.api.id]) {
|
|
70275
70324
|
const element2 = createFocusableElement();
|
|
@@ -70290,7 +70339,12 @@ var OverlayRenderContainer = class extends CompositeDisposable {
|
|
|
70290
70339
|
mapEntry.generation = ++this._generation;
|
|
70291
70340
|
this.cancelPendingUpdate(mapEntry);
|
|
70292
70341
|
mapEntry.referenceContainer = referenceContainer;
|
|
70293
|
-
|
|
70342
|
+
const collapsedEdge = isInCollapsedEdgeGroup(panel);
|
|
70343
|
+
mapEntry.retainPreviousGeometry = mapEntry.positioned && !collapsedEdge;
|
|
70344
|
+
if (collapsedEdge && !mapEntry.forceVisible) {
|
|
70345
|
+
mapEntry.element.style.visibility = "hidden";
|
|
70346
|
+
mapEntry.element.style.pointerEvents = "none";
|
|
70347
|
+
}
|
|
70294
70348
|
}
|
|
70295
70349
|
const generation = mapEntry.generation;
|
|
70296
70350
|
const focusContainer = mapEntry.element;
|
|
@@ -70318,18 +70372,30 @@ var OverlayRenderContainer = class extends CompositeDisposable {
|
|
|
70318
70372
|
if (this.isDisposed || (entry === null || entry === void 0 ? void 0 : entry.generation) !== generation) return;
|
|
70319
70373
|
const forceVisible = (_entry$forceVisible = entry.forceVisible) !== null && _entry$forceVisible !== void 0 ? _entry$forceVisible : false;
|
|
70320
70374
|
const clip = entry.clip;
|
|
70375
|
+
const collapsedEdge = isInCollapsedEdgeGroup(panel);
|
|
70376
|
+
const hidden = !forceVisible && (!panel.api.isVisible || collapsedEdge);
|
|
70321
70377
|
const box = this.positionCache.getPosition(referenceContainer.element);
|
|
70322
70378
|
const box2 = this.positionCache.getPosition(this.element);
|
|
70323
70379
|
const left = box.left - box2.left;
|
|
70324
70380
|
const top = box.top - box2.top;
|
|
70325
70381
|
const width = box.width;
|
|
70326
70382
|
const height = box.height;
|
|
70327
|
-
if (
|
|
70328
|
-
if (
|
|
70383
|
+
if (width === 0 || height === 0) {
|
|
70384
|
+
if (collapsedEdge && !forceVisible) {
|
|
70385
|
+
entry.retainPreviousGeometry = false;
|
|
70329
70386
|
focusContainer.style.visibility = "hidden";
|
|
70330
70387
|
focusContainer.style.pointerEvents = "none";
|
|
70388
|
+
focusContainer.style.clipPath = "";
|
|
70389
|
+
focusContainer.style.zIndex = "";
|
|
70390
|
+
return;
|
|
70391
|
+
}
|
|
70392
|
+
if (entry.retainPreviousGeometry) {
|
|
70393
|
+
if (hidden) {
|
|
70394
|
+
focusContainer.style.visibility = "hidden";
|
|
70395
|
+
focusContainer.style.pointerEvents = "none";
|
|
70396
|
+
}
|
|
70397
|
+
return;
|
|
70331
70398
|
}
|
|
70332
|
-
return;
|
|
70333
70399
|
}
|
|
70334
70400
|
entry.retainPreviousGeometry = false;
|
|
70335
70401
|
entry.positioned = true;
|
|
@@ -70337,7 +70403,7 @@ var OverlayRenderContainer = class extends CompositeDisposable {
|
|
|
70337
70403
|
setPixels(focusContainer.style, "top", top);
|
|
70338
70404
|
setPixels(focusContainer.style, "width", width);
|
|
70339
70405
|
setPixels(focusContainer.style, "height", height);
|
|
70340
|
-
if (
|
|
70406
|
+
if (!hidden) {
|
|
70341
70407
|
focusContainer.style.visibility = "";
|
|
70342
70408
|
focusContainer.style.pointerEvents = "";
|
|
70343
70409
|
} else {
|
|
@@ -70364,11 +70430,13 @@ var OverlayRenderContainer = class extends CompositeDisposable {
|
|
|
70364
70430
|
if (scheduling.pendingUpdate === SCHEDULED) scheduling.pendingUpdate = handle;
|
|
70365
70431
|
};
|
|
70366
70432
|
const visibilityChanged = () => {
|
|
70367
|
-
|
|
70368
|
-
|
|
70433
|
+
var _this$map$panel$api$i;
|
|
70434
|
+
const collapsedEdge = !((_this$map$panel$api$i = this.map[panel.api.id]) === null || _this$map$panel$api$i === void 0 ? void 0 : _this$map$panel$api$i.forceVisible) && isInCollapsedEdgeGroup(panel);
|
|
70435
|
+
if (panel.api.isVisible && !collapsedEdge) {
|
|
70436
|
+
var _this$map$panel$api$i2;
|
|
70369
70437
|
this.positionCache.invalidate();
|
|
70370
70438
|
resize();
|
|
70371
|
-
if ((_this$map$panel$api$
|
|
70439
|
+
if ((_this$map$panel$api$i2 = this.map[panel.api.id]) === null || _this$map$panel$api$i2 === void 0 ? void 0 : _this$map$panel$api$i2.retainPreviousGeometry) focusContainer.style.visibility = "";
|
|
70372
70440
|
focusContainer.style.pointerEvents = "";
|
|
70373
70441
|
} else {
|
|
70374
70442
|
focusContainer.style.visibility = "hidden";
|
|
@@ -70431,6 +70499,10 @@ var OverlayRenderContainer = class extends CompositeDisposable {
|
|
|
70431
70499
|
if (!panel.api.isVisible) return;
|
|
70432
70500
|
resize();
|
|
70433
70501
|
}),
|
|
70502
|
+
(_panel$group$api$onDi = (_panel$group$api$onDi2 = (_panel$group$api = panel.group.api).onDidCollapsedChange) === null || _panel$group$api$onDi2 === void 0 ? void 0 : _panel$group$api$onDi2.call(_panel$group$api, () => {
|
|
70503
|
+
this.positionCache.invalidate();
|
|
70504
|
+
resize();
|
|
70505
|
+
})) !== null && _panel$group$api$onDi !== void 0 ? _panel$group$api$onDi : Disposable.NONE,
|
|
70434
70506
|
referenceContainer.onDidDimensionsChange((size4) => {
|
|
70435
70507
|
applySize(size4);
|
|
70436
70508
|
}),
|
|
@@ -84578,7 +84650,7 @@ lit-html/static.js:
|
|
|
84578
84650
|
dockview-core/dist/package/main.esm.mjs:
|
|
84579
84651
|
(**
|
|
84580
84652
|
* dockview-core
|
|
84581
|
-
* @version 8.8.
|
|
84653
|
+
* @version 8.8.2
|
|
84582
84654
|
* @link https://github.com/dockview/dockview
|
|
84583
84655
|
* @license MIT
|
|
84584
84656
|
*)
|