@ag2/weave 0.11.0 → 0.13.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 +15 -0
- package/dist/components/activity-item/ActivityHeader.css.d.ts +5 -0
- package/dist/components/activity-item/ActivityHeader.d.ts +11 -0
- package/dist/components/activity-item/ActivityItem.css.d.ts +18 -0
- package/dist/components/activity-item/ActivityItem.d.ts +43 -0
- package/dist/components/activity-item/index.d.ts +2 -0
- package/dist/components/avatar/Avatar.d.ts +1 -1
- package/dist/components/icon/Icon.d.ts +1 -1
- package/dist/components/index.d.ts +2 -0
- package/dist/components/orb-background/OrbBackground.css.d.ts +3 -0
- package/dist/components/orb-background/OrbBackground.d.ts +7 -0
- package/dist/components/orb-background/index.d.ts +2 -0
- package/dist/components/orb-background/orbAppearance.d.ts +2 -0
- package/dist/components/orb-background/orbField.d.ts +1 -0
- package/dist/components/panel-switch/PanelSwitch.d.ts +2 -0
- package/dist/components/sidebar/SidebarItem.d.ts +1 -1
- package/dist/index.js +526 -53
- package/dist/index.js.map +1 -1
- package/dist/style.css +235 -12
- package/package.json +3 -2
package/dist/index.js
CHANGED
|
@@ -4947,7 +4947,7 @@ const e$x = /* @__PURE__ */ new Map([
|
|
|
4947
4947
|
const e$w = a$T.forwardRef((r2, t2) => /* @__PURE__ */ a$T.createElement(p$5, { ref: t2, ...r2, weights: e$x }));
|
|
4948
4948
|
e$w.displayName = "SunIcon";
|
|
4949
4949
|
const s$4 = e$w;
|
|
4950
|
-
const H = /* @__PURE__ */ new Map([
|
|
4950
|
+
const H$1 = /* @__PURE__ */ new Map([
|
|
4951
4951
|
[
|
|
4952
4952
|
"bold",
|
|
4953
4953
|
/* @__PURE__ */ a$T.createElement(a$T.Fragment, null, /* @__PURE__ */ a$T.createElement("path", { d: "M224,44H32A12,12,0,0,0,20,56V192a20,20,0,0,0,20,20H216a20,20,0,0,0,20-20V56A12,12,0,0,0,224,44ZM44,116H76v24H44Zm56,0H212v24H100ZM212,68V92H44V68ZM44,164H76v24H44Zm56,24V164H212v24Z" }))
|
|
@@ -4973,7 +4973,7 @@ const H = /* @__PURE__ */ new Map([
|
|
|
4973
4973
|
/* @__PURE__ */ a$T.createElement(a$T.Fragment, null, /* @__PURE__ */ a$T.createElement("path", { d: "M224,52H32a4,4,0,0,0-4,4V192a12,12,0,0,0,12,12H216a12,12,0,0,0,12-12V56A4,4,0,0,0,224,52ZM36,108H84v40H36Zm56,0H220v40H92ZM220,60v40H36V60ZM36,192V156H84v40H40A4,4,0,0,1,36,192Zm180,4H92V156H220v36A4,4,0,0,1,216,196Z" }))
|
|
4974
4974
|
]
|
|
4975
4975
|
]);
|
|
4976
|
-
const o$a = a$T.forwardRef((a2, r2) => /* @__PURE__ */ a$T.createElement(p$5, { ref: r2, ...a2, weights: H }));
|
|
4976
|
+
const o$a = a$T.forwardRef((a2, r2) => /* @__PURE__ */ a$T.createElement(p$5, { ref: r2, ...a2, weights: H$1 }));
|
|
4977
4977
|
o$a.displayName = "TableIcon";
|
|
4978
4978
|
const n$e = o$a;
|
|
4979
4979
|
const e$v = /* @__PURE__ */ new Map([
|
|
@@ -6124,7 +6124,7 @@ const Input = forwardRef(
|
|
|
6124
6124
|
}
|
|
6125
6125
|
);
|
|
6126
6126
|
const Form_css_ts_vanilla = "";
|
|
6127
|
-
var Body$
|
|
6127
|
+
var Body$2 = "_1699xxt1";
|
|
6128
6128
|
var Card = "_1699xxt8";
|
|
6129
6129
|
var CardTone = createRuntimeFn({ defaultClassName: "", variantClassNames: { variant: { Surface: "_1699xxt9", SurfaceVariant: "_1699xxta", Background: "_1699xxtb", Primary: "_1699xxtc", Secondary: "_1699xxtd", Success: "_1699xxte", Warning: "_1699xxtf", Critical: "_1699xxtg" } }, defaultVariants: {}, compoundVariants: [] });
|
|
6130
6130
|
var Children = "_1699xxt4";
|
|
@@ -6147,7 +6147,7 @@ const FormRow = forwardRef(
|
|
|
6147
6147
|
}) : after;
|
|
6148
6148
|
return /* @__PURE__ */ jsx(FormContext.Provider, { value: context, children: /* @__PURE__ */ jsxs("div", { ref, ...props, "data-weave-form-row": true, className: classNames(Row$1, className), children: [
|
|
6149
6149
|
before && /* @__PURE__ */ jsx("div", { "data-weave-form-before": true, children: before }),
|
|
6150
|
-
/* @__PURE__ */ jsxs("div", { className: Body$
|
|
6150
|
+
/* @__PURE__ */ jsxs("div", { className: Body$2, "data-weave-form-body": true, children: [
|
|
6151
6151
|
title && /* @__PURE__ */ jsx("div", { className: Label$4, id: labelId, children: title }),
|
|
6152
6152
|
description && /* @__PURE__ */ jsx("div", { className: Description$1, id: descriptionId, children: description }),
|
|
6153
6153
|
children && /* @__PURE__ */ jsx("div", { className: Children, "data-weave-form-children": true, children })
|
|
@@ -8251,8 +8251,8 @@ const containRe = /paint|layout|strict|content/;
|
|
|
8251
8251
|
const isNotNone = (value) => !!value && value !== "none";
|
|
8252
8252
|
let isWebKitValue;
|
|
8253
8253
|
function isContainingBlock(elementOrCss) {
|
|
8254
|
-
const
|
|
8255
|
-
return isNotNone(
|
|
8254
|
+
const css2 = isElement(elementOrCss) ? getComputedStyle$1(elementOrCss) : elementOrCss;
|
|
8255
|
+
return isNotNone(css2.transform) || isNotNone(css2.translate) || isNotNone(css2.scale) || isNotNone(css2.rotate) || isNotNone(css2.perspective) || !isWebKit() && (isNotNone(css2.backdropFilter) || isNotNone(css2.filter)) || willChangeRe.test(css2.willChange || "") || containRe.test(css2.contain || "");
|
|
8256
8256
|
}
|
|
8257
8257
|
function getContainingBlock(element) {
|
|
8258
8258
|
let currentNode = getParentNode(element);
|
|
@@ -8335,9 +8335,9 @@ function getFrameElement(win) {
|
|
|
8335
8335
|
return win.parent && Object.getPrototypeOf(win.parent) ? win.frameElement : null;
|
|
8336
8336
|
}
|
|
8337
8337
|
function getCssDimensions(element) {
|
|
8338
|
-
const
|
|
8339
|
-
let width = parseFloat(
|
|
8340
|
-
let height = parseFloat(
|
|
8338
|
+
const css2 = getComputedStyle$1(element);
|
|
8339
|
+
let width = parseFloat(css2.width) || 0;
|
|
8340
|
+
let height = parseFloat(css2.height) || 0;
|
|
8341
8341
|
const hasOffset = isHTMLElement(element);
|
|
8342
8342
|
const offsetWidth = hasOffset ? element.offsetWidth : width;
|
|
8343
8343
|
const offsetHeight = hasOffset ? element.offsetHeight : height;
|
|
@@ -8428,9 +8428,9 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
|
|
|
8428
8428
|
while (currentIFrame && offsetWin !== currentWin) {
|
|
8429
8429
|
const iframeScale = getScale(currentIFrame);
|
|
8430
8430
|
const iframeRect = currentIFrame.getBoundingClientRect();
|
|
8431
|
-
const
|
|
8432
|
-
const left = iframeRect.left + (currentIFrame.clientLeft + parseFloat(
|
|
8433
|
-
const top = iframeRect.top + (currentIFrame.clientTop + parseFloat(
|
|
8431
|
+
const css2 = getComputedStyle$1(currentIFrame);
|
|
8432
|
+
const left = iframeRect.left + (currentIFrame.clientLeft + parseFloat(css2.paddingLeft)) * iframeScale.x;
|
|
8433
|
+
const top = iframeRect.top + (currentIFrame.clientTop + parseFloat(css2.paddingTop)) * iframeScale.y;
|
|
8434
8434
|
x *= iframeScale.x;
|
|
8435
8435
|
y *= iframeScale.y;
|
|
8436
8436
|
width *= iframeScale.x;
|
|
@@ -10834,11 +10834,11 @@ function makeStyleTag() {
|
|
|
10834
10834
|
}
|
|
10835
10835
|
return tag;
|
|
10836
10836
|
}
|
|
10837
|
-
function injectStyles(tag,
|
|
10837
|
+
function injectStyles(tag, css2) {
|
|
10838
10838
|
if (tag.styleSheet) {
|
|
10839
|
-
tag.styleSheet.cssText =
|
|
10839
|
+
tag.styleSheet.cssText = css2;
|
|
10840
10840
|
} else {
|
|
10841
|
-
tag.appendChild(document.createTextNode(
|
|
10841
|
+
tag.appendChild(document.createTextNode(css2));
|
|
10842
10842
|
}
|
|
10843
10843
|
}
|
|
10844
10844
|
function insertStyleTag(tag) {
|
|
@@ -15493,7 +15493,7 @@ function mountAliveMark(container, opts) {
|
|
|
15493
15493
|
function now() {
|
|
15494
15494
|
return window.performance && performance.now ? performance.now() : Date.now();
|
|
15495
15495
|
}
|
|
15496
|
-
function
|
|
15496
|
+
function rnd2(a2, b) {
|
|
15497
15497
|
return a2 + Math.random() * (b - a2);
|
|
15498
15498
|
}
|
|
15499
15499
|
function setA(el, name, val) {
|
|
@@ -15527,7 +15527,7 @@ function mountAliveMark(container, opts) {
|
|
|
15527
15527
|
if (!sleeping)
|
|
15528
15528
|
doBlink(Math.random() < o2.doubleBlinkChance);
|
|
15529
15529
|
scheduleBlink();
|
|
15530
|
-
},
|
|
15530
|
+
}, rnd2(o2.blinkMin, o2.blinkMax) * 1e3 * mult);
|
|
15531
15531
|
}
|
|
15532
15532
|
function doBlink(dbl) {
|
|
15533
15533
|
var t2 = now();
|
|
@@ -15561,18 +15561,18 @@ function mountAliveMark(container, opts) {
|
|
|
15561
15561
|
clearTimeout(driftT);
|
|
15562
15562
|
driftT = setTimeout(function() {
|
|
15563
15563
|
if (!reduced && !sleeping && !gazing) {
|
|
15564
|
-
tgtX =
|
|
15565
|
-
tgtY =
|
|
15564
|
+
tgtX = rnd2(-o2.driftX, o2.driftX);
|
|
15565
|
+
tgtY = rnd2(-o2.driftY, o2.driftY);
|
|
15566
15566
|
}
|
|
15567
15567
|
scheduleDrift();
|
|
15568
|
-
},
|
|
15568
|
+
}, rnd2(o2.driftMin, o2.driftMax) * 1e3);
|
|
15569
15569
|
}
|
|
15570
15570
|
function frame(t2) {
|
|
15571
15571
|
if (!running)
|
|
15572
15572
|
return;
|
|
15573
15573
|
var dt = last ? Math.min(0.05, (t2 - last) / 1e3) : 0.016;
|
|
15574
15574
|
last = t2;
|
|
15575
|
-
var
|
|
15575
|
+
var ease2 = function(tau) {
|
|
15576
15576
|
return reduced ? 1 : 1 - Math.exp(-dt / tau);
|
|
15577
15577
|
};
|
|
15578
15578
|
if (t2 - rectAt > 250) {
|
|
@@ -15589,7 +15589,7 @@ function mountAliveMark(container, opts) {
|
|
|
15589
15589
|
tgtY = 0;
|
|
15590
15590
|
}
|
|
15591
15591
|
}
|
|
15592
|
-
dreamAmt += ((sleeping ? 1 : 0) - dreamAmt) *
|
|
15592
|
+
dreamAmt += ((sleeping ? 1 : 0) - dreamAmt) * ease2(0.12);
|
|
15593
15593
|
if (dreamAmt < 1e-3)
|
|
15594
15594
|
dreamAmt = 0;
|
|
15595
15595
|
if (dreamAmt > 0.999)
|
|
@@ -15632,8 +15632,8 @@ function mountAliveMark(container, opts) {
|
|
|
15632
15632
|
tgtX = 0;
|
|
15633
15633
|
tgtY = 0;
|
|
15634
15634
|
}
|
|
15635
|
-
curX += (tgtX - curX) *
|
|
15636
|
-
curY += (tgtY - curY) *
|
|
15635
|
+
curX += (tgtX - curX) * ease2(0.18);
|
|
15636
|
+
curY += (tgtY - curY) * ease2(0.18);
|
|
15637
15637
|
setA(look, "transform", "translate(" + curX.toFixed(3) + " " + curY.toFixed(3) + ")");
|
|
15638
15638
|
var sl = lidAt(animL, t2), sr = lidAt(animR, t2);
|
|
15639
15639
|
if (animL && t2 - animL.t0 >= animL.dur)
|
|
@@ -15650,7 +15650,7 @@ function mountAliveMark(container, opts) {
|
|
|
15650
15650
|
"transform",
|
|
15651
15651
|
"translate(" + rx + " " + y + ") scale(1 " + sr.toFixed(3) + ") translate(" + -rx + " " + -y + ")"
|
|
15652
15652
|
);
|
|
15653
|
-
tiltCur += (c2.tilt - tiltCur) *
|
|
15653
|
+
tiltCur += (c2.tilt - tiltCur) * ease2(0.22);
|
|
15654
15654
|
var tstr = pillT(tiltCur.toFixed(3));
|
|
15655
15655
|
setA(swipe, "transform", tstr);
|
|
15656
15656
|
setA(clip, "transform", tstr);
|
|
@@ -15781,6 +15781,353 @@ const StackedAvatar = as(
|
|
|
15781
15781
|
)
|
|
15782
15782
|
);
|
|
15783
15783
|
const ComposeIcon = Icons.Compose;
|
|
15784
|
+
const PAL = {
|
|
15785
|
+
ember: { c: [249, 163, 88], r: [242, 102, 30] },
|
|
15786
|
+
pink: { c: [248, 206, 254], r: [229, 138, 240] },
|
|
15787
|
+
sky: { c: [173, 219, 255], r: [74, 95, 208] },
|
|
15788
|
+
mint: { c: [160, 226, 191], r: [46, 143, 94] },
|
|
15789
|
+
lemon: { c: [240, 227, 69], r: [141, 191, 58] },
|
|
15790
|
+
lilac: { c: [242, 212, 255], r: [154, 166, 255] },
|
|
15791
|
+
forest: { c: [10, 138, 68], r: [4, 90, 44] },
|
|
15792
|
+
cream: { c: [244, 246, 186], r: [201, 161, 74] }
|
|
15793
|
+
};
|
|
15794
|
+
const W = 1200;
|
|
15795
|
+
const H = 800;
|
|
15796
|
+
const TILT = -46.7 * Math.PI / 180;
|
|
15797
|
+
const RATIO = 0.5;
|
|
15798
|
+
const MAXR = 300;
|
|
15799
|
+
const rnd = (a2, b) => a2 + Math.random() * (b - a2);
|
|
15800
|
+
const lerp = (a2, b, t2) => a2 + (b - a2) * t2;
|
|
15801
|
+
const mix = (a2, b, t2) => a2.map((v, i2) => lerp(v, b[i2], t2));
|
|
15802
|
+
const css = (a2) => `rgb(${a2.map(Math.round).join(",")})`;
|
|
15803
|
+
const ease = (t2) => t2 < 0.5 ? 2 * t2 * t2 : 1 - (-2 * t2 + 2) ** 2 / 2;
|
|
15804
|
+
const make = (x, y, vx, vy, r2, name, from) => ({
|
|
15805
|
+
x,
|
|
15806
|
+
y,
|
|
15807
|
+
vx,
|
|
15808
|
+
vy,
|
|
15809
|
+
r: r2,
|
|
15810
|
+
rd: from ? from.rd : r2,
|
|
15811
|
+
name,
|
|
15812
|
+
c0: from ? from.c : PAL[name].c.slice(),
|
|
15813
|
+
r0: from ? from.rr : PAL[name].r.slice(),
|
|
15814
|
+
c: PAL[name].c.slice(),
|
|
15815
|
+
rr: PAL[name].r.slice(),
|
|
15816
|
+
ct: from ? 0 : 1,
|
|
15817
|
+
age: 0,
|
|
15818
|
+
wob: from ? 1 : 0
|
|
15819
|
+
});
|
|
15820
|
+
const cur = (o2) => ({ c: mix(o2.c0, o2.c, ease(o2.ct)), r: mix(o2.r0, o2.rr, ease(o2.ct)) });
|
|
15821
|
+
function startOrbField(element) {
|
|
15822
|
+
const canvas = element;
|
|
15823
|
+
const ctx = canvas.getContext("2d");
|
|
15824
|
+
if (!ctx)
|
|
15825
|
+
return () => void 0;
|
|
15826
|
+
let orbs = [];
|
|
15827
|
+
let target = 3;
|
|
15828
|
+
let targetTime = 0;
|
|
15829
|
+
let spawnTime = 0;
|
|
15830
|
+
let last = performance.now();
|
|
15831
|
+
let raf = 0;
|
|
15832
|
+
const motion2 = window.matchMedia("(prefers-reduced-motion: reduce)");
|
|
15833
|
+
const pickName = (exclude = []) => {
|
|
15834
|
+
const taken = /* @__PURE__ */ new Set([...exclude, ...orbs.filter((o2) => !o2.leaving).map((o2) => o2.name)]);
|
|
15835
|
+
let pool = Object.keys(PAL).filter((n2) => !taken.has(n2) && n2 !== "ember");
|
|
15836
|
+
if (!pool.length)
|
|
15837
|
+
pool = Object.keys(PAL).filter((n2) => !exclude.includes(n2) && n2 !== "ember");
|
|
15838
|
+
return pool[Math.floor(Math.random() * pool.length)];
|
|
15839
|
+
};
|
|
15840
|
+
[
|
|
15841
|
+
[0.2, 0.25],
|
|
15842
|
+
[0.82, 0.78],
|
|
15843
|
+
[0.85, 0.2]
|
|
15844
|
+
].forEach(([px, py]) => {
|
|
15845
|
+
const o2 = make(
|
|
15846
|
+
W * px + rnd(-60, 60),
|
|
15847
|
+
H * py + rnd(-50, 50),
|
|
15848
|
+
rnd(-0.6, 0.6),
|
|
15849
|
+
rnd(-0.6, 0.6),
|
|
15850
|
+
rnd(150, 210),
|
|
15851
|
+
pickName()
|
|
15852
|
+
);
|
|
15853
|
+
o2.age = 2;
|
|
15854
|
+
orbs.push(o2);
|
|
15855
|
+
});
|
|
15856
|
+
const spawn = () => {
|
|
15857
|
+
const side = Math.floor(Math.random() * 4);
|
|
15858
|
+
const r2 = rnd(120, 180);
|
|
15859
|
+
const speed = rnd(0.9, 1.7);
|
|
15860
|
+
let x = rnd(80, W - 80);
|
|
15861
|
+
let y = rnd(80, H - 80);
|
|
15862
|
+
if (side === 0)
|
|
15863
|
+
x = -r2;
|
|
15864
|
+
else if (side === 1)
|
|
15865
|
+
x = W + r2;
|
|
15866
|
+
else if (side === 2)
|
|
15867
|
+
y = -r2;
|
|
15868
|
+
else
|
|
15869
|
+
y = H + r2;
|
|
15870
|
+
const tx = rnd(W * 0.25, W * 0.75);
|
|
15871
|
+
const ty = rnd(H * 0.25, H * 0.75);
|
|
15872
|
+
const d = Math.hypot(tx - x, ty - y);
|
|
15873
|
+
orbs.push(make(x, y, (tx - x) / d * speed, (ty - y) / d * speed, r2, pickName()));
|
|
15874
|
+
};
|
|
15875
|
+
const collide = (dt) => {
|
|
15876
|
+
for (let i2 = 0; i2 < orbs.length; i2 += 1) {
|
|
15877
|
+
for (let j = i2 + 1; j < orbs.length; j += 1) {
|
|
15878
|
+
const a2 = orbs[i2];
|
|
15879
|
+
const b = orbs[j];
|
|
15880
|
+
if (a2.age >= 0.8 && b.age >= 0.8) {
|
|
15881
|
+
const dx = b.x - a2.x;
|
|
15882
|
+
const dy = b.y - a2.y;
|
|
15883
|
+
const u = dx * Math.cos(TILT) + dy * Math.sin(TILT);
|
|
15884
|
+
const v = -dx * Math.sin(TILT) + dy * Math.cos(TILT);
|
|
15885
|
+
const R = (a2.rd + b.rd) * 0.92;
|
|
15886
|
+
if (u * u / (R * R) + v * v / (R * R * RATIO * RATIO) < 1) {
|
|
15887
|
+
const big = a2.r >= b.r ? a2 : b;
|
|
15888
|
+
const small = big === a2 ? b : a2;
|
|
15889
|
+
const da = Math.min(small.r * small.r, 14e3 * dt);
|
|
15890
|
+
small.r = Math.sqrt(Math.max(0, small.r * small.r - da));
|
|
15891
|
+
small.rd = Math.min(small.rd, small.r + 6);
|
|
15892
|
+
big.r = Math.sqrt(big.r * big.r + da);
|
|
15893
|
+
const cs = cur(small);
|
|
15894
|
+
const cb = cur(big);
|
|
15895
|
+
const k = Math.min(0.08, da / (big.r * big.r));
|
|
15896
|
+
big.c0 = mix(cb.c, cs.c, k * 3);
|
|
15897
|
+
big.r0 = mix(cb.r, cs.r, k * 3);
|
|
15898
|
+
big.c = mix(big.c, cs.c, k * 3);
|
|
15899
|
+
big.rr = mix(big.rr, cs.r, k * 3);
|
|
15900
|
+
small.x += (big.x - small.x) * 0.05;
|
|
15901
|
+
small.y += (big.y - small.y) * 0.05;
|
|
15902
|
+
if (small.r < 10) {
|
|
15903
|
+
orbs.splice(orbs.indexOf(small), 1);
|
|
15904
|
+
big.wob = 1;
|
|
15905
|
+
const c2 = cur(big);
|
|
15906
|
+
big.name = pickName([big.name]);
|
|
15907
|
+
big.c0 = c2.c;
|
|
15908
|
+
big.r0 = c2.r;
|
|
15909
|
+
big.c = PAL[big.name].c.slice();
|
|
15910
|
+
big.rr = PAL[big.name].r.slice();
|
|
15911
|
+
big.ct = 0;
|
|
15912
|
+
if (big.r > MAXR) {
|
|
15913
|
+
const from = cur(big);
|
|
15914
|
+
orbs.splice(orbs.indexOf(big), 1);
|
|
15915
|
+
for (let n2 = 0; n2 < 2; n2 += 1) {
|
|
15916
|
+
const angle = n2 * Math.PI + rnd(-0.4, 0.4);
|
|
15917
|
+
const speed = rnd(1.4, 2.2);
|
|
15918
|
+
orbs.push(
|
|
15919
|
+
make(
|
|
15920
|
+
big.x,
|
|
15921
|
+
big.y,
|
|
15922
|
+
Math.cos(angle) * speed + big.vx,
|
|
15923
|
+
Math.sin(angle) * speed + big.vy,
|
|
15924
|
+
big.r * 0.42,
|
|
15925
|
+
pickName(),
|
|
15926
|
+
{ rd: big.r * 0.5, c: from.c, rr: from.r }
|
|
15927
|
+
)
|
|
15928
|
+
);
|
|
15929
|
+
}
|
|
15930
|
+
}
|
|
15931
|
+
return;
|
|
15932
|
+
}
|
|
15933
|
+
}
|
|
15934
|
+
}
|
|
15935
|
+
}
|
|
15936
|
+
}
|
|
15937
|
+
};
|
|
15938
|
+
const step = (dt) => {
|
|
15939
|
+
spawnTime += dt;
|
|
15940
|
+
targetTime += dt;
|
|
15941
|
+
if (targetTime > (target === 3 ? 8 : 11)) {
|
|
15942
|
+
targetTime = 0;
|
|
15943
|
+
target = target === 3 ? 2 : 3;
|
|
15944
|
+
if (target === 2 && orbs.length > 2) {
|
|
15945
|
+
const oldest = orbs.filter((o2) => !o2.leaving).sort((a2, b) => b.age - a2.age)[0];
|
|
15946
|
+
if (oldest) {
|
|
15947
|
+
oldest.leaving = true;
|
|
15948
|
+
const d = Math.hypot(oldest.x - W / 2, oldest.y - H / 2) || 1;
|
|
15949
|
+
oldest.lx = (oldest.x - W / 2) / d;
|
|
15950
|
+
oldest.ly = (oldest.y - H / 2) / d;
|
|
15951
|
+
}
|
|
15952
|
+
}
|
|
15953
|
+
}
|
|
15954
|
+
if (spawnTime > 2.4 && orbs.filter((o2) => !o2.leaving).length < target) {
|
|
15955
|
+
spawnTime = 0;
|
|
15956
|
+
spawn();
|
|
15957
|
+
}
|
|
15958
|
+
orbs.forEach((orb) => {
|
|
15959
|
+
const o2 = orb;
|
|
15960
|
+
o2.age += dt;
|
|
15961
|
+
o2.x += o2.vx * dt * 60;
|
|
15962
|
+
o2.y += o2.vy * dt * 60;
|
|
15963
|
+
o2.vx *= 0.999;
|
|
15964
|
+
o2.vy *= 0.999;
|
|
15965
|
+
const k = 0.03 * dt * 60;
|
|
15966
|
+
if (o2.leaving) {
|
|
15967
|
+
o2.vx += (o2.lx ?? 0) * k;
|
|
15968
|
+
o2.vy += (o2.ly ?? 0) * k;
|
|
15969
|
+
} else if (o2.age > 3) {
|
|
15970
|
+
if (o2.x < W * 0.08)
|
|
15971
|
+
o2.vx += k;
|
|
15972
|
+
if (o2.x > W * 0.92)
|
|
15973
|
+
o2.vx -= k;
|
|
15974
|
+
if (o2.y < H * 0.1)
|
|
15975
|
+
o2.vy += k;
|
|
15976
|
+
if (o2.y > H * 0.9)
|
|
15977
|
+
o2.vy -= k;
|
|
15978
|
+
orbs.forEach((q) => {
|
|
15979
|
+
if (q !== o2 && !q.leaving) {
|
|
15980
|
+
const dx = o2.x - q.x;
|
|
15981
|
+
const dy = o2.y - q.y;
|
|
15982
|
+
const d = Math.hypot(dx, dy) || 1;
|
|
15983
|
+
if (d < 420) {
|
|
15984
|
+
o2.vx += dx / d * 6e-3 * dt * 60;
|
|
15985
|
+
o2.vy += dy / d * 6e-3 * dt * 60;
|
|
15986
|
+
}
|
|
15987
|
+
}
|
|
15988
|
+
});
|
|
15989
|
+
}
|
|
15990
|
+
const speed = Math.hypot(o2.vx, o2.vy);
|
|
15991
|
+
const cap = o2.leaving ? 4 : 2.2;
|
|
15992
|
+
if (speed > cap) {
|
|
15993
|
+
o2.vx *= cap / speed;
|
|
15994
|
+
o2.vy *= cap / speed;
|
|
15995
|
+
}
|
|
15996
|
+
o2.rd = lerp(o2.rd, o2.r, 1 - Math.exp(-dt * 5));
|
|
15997
|
+
o2.ct = Math.min(1, o2.ct + dt * 1.4);
|
|
15998
|
+
o2.wob = Math.max(0, o2.wob - dt * 1.1);
|
|
15999
|
+
});
|
|
16000
|
+
collide(dt);
|
|
16001
|
+
orbs = orbs.filter((o2) => {
|
|
16002
|
+
const m2 = o2.leaving ? o2.rd * 1.6 : 400;
|
|
16003
|
+
return o2.x > -m2 && o2.x < W + m2 && o2.y > -m2 && o2.y < H + m2;
|
|
16004
|
+
});
|
|
16005
|
+
};
|
|
16006
|
+
const draw = () => {
|
|
16007
|
+
ctx.clearRect(0, 0, W, H);
|
|
16008
|
+
orbs.forEach((o2) => {
|
|
16009
|
+
const c2 = cur(o2);
|
|
16010
|
+
const w2 = o2.rd * 1.35;
|
|
16011
|
+
const wob = o2.wob > 0 ? Math.sin((1 - o2.wob) * 20) * 0.16 * o2.wob : 0;
|
|
16012
|
+
ctx.save();
|
|
16013
|
+
ctx.translate(o2.x, o2.y);
|
|
16014
|
+
ctx.rotate(TILT);
|
|
16015
|
+
ctx.scale(1 + wob, (1 - wob) * RATIO);
|
|
16016
|
+
const gradient = ctx.createRadialGradient(0, 0, 0, 0, 0, w2);
|
|
16017
|
+
gradient.addColorStop(0, css(c2.c));
|
|
16018
|
+
gradient.addColorStop(0.62, css(c2.c));
|
|
16019
|
+
gradient.addColorStop(1, css(c2.r));
|
|
16020
|
+
ctx.fillStyle = gradient;
|
|
16021
|
+
ctx.beginPath();
|
|
16022
|
+
ctx.arc(0, 0, w2, 0, Math.PI * 2);
|
|
16023
|
+
ctx.fill();
|
|
16024
|
+
ctx.restore();
|
|
16025
|
+
});
|
|
16026
|
+
};
|
|
16027
|
+
const resize = () => {
|
|
16028
|
+
const dpr = Math.min(window.devicePixelRatio || 1, 2);
|
|
16029
|
+
const width = Math.max(1, canvas.clientWidth);
|
|
16030
|
+
const height = Math.max(1, canvas.clientHeight);
|
|
16031
|
+
canvas.width = Math.round(width * dpr);
|
|
16032
|
+
canvas.height = Math.round(height * dpr);
|
|
16033
|
+
const scale = Math.max(width / W, height / H);
|
|
16034
|
+
ctx.setTransform(
|
|
16035
|
+
dpr * scale,
|
|
16036
|
+
0,
|
|
16037
|
+
0,
|
|
16038
|
+
dpr * scale,
|
|
16039
|
+
dpr * (width - W * scale) / 2,
|
|
16040
|
+
dpr * (height - H * scale) / 2
|
|
16041
|
+
);
|
|
16042
|
+
draw();
|
|
16043
|
+
};
|
|
16044
|
+
const tick = (now) => {
|
|
16045
|
+
step(Math.min(0.05, (now - last) / 1e3));
|
|
16046
|
+
last = now;
|
|
16047
|
+
draw();
|
|
16048
|
+
raf = window.requestAnimationFrame(tick);
|
|
16049
|
+
};
|
|
16050
|
+
const syncMotion = () => {
|
|
16051
|
+
window.cancelAnimationFrame(raf);
|
|
16052
|
+
last = performance.now();
|
|
16053
|
+
if (!motion2.matches && !document.hidden)
|
|
16054
|
+
raf = window.requestAnimationFrame(tick);
|
|
16055
|
+
};
|
|
16056
|
+
resize();
|
|
16057
|
+
syncMotion();
|
|
16058
|
+
const observer = new ResizeObserver(resize);
|
|
16059
|
+
observer.observe(canvas);
|
|
16060
|
+
motion2.addEventListener("change", syncMotion);
|
|
16061
|
+
document.addEventListener("visibilitychange", syncMotion);
|
|
16062
|
+
return () => {
|
|
16063
|
+
window.cancelAnimationFrame(raf);
|
|
16064
|
+
observer.disconnect();
|
|
16065
|
+
motion2.removeEventListener("change", syncMotion);
|
|
16066
|
+
document.removeEventListener("visibilitychange", syncMotion);
|
|
16067
|
+
};
|
|
16068
|
+
}
|
|
16069
|
+
const orbOpacityForSurface = (surface, prefersDark) => {
|
|
16070
|
+
const perceptual = surface.match(/^okl(?:ab|ch)\(\s*([\d.]+)(%?)/);
|
|
16071
|
+
if (perceptual) {
|
|
16072
|
+
const lightness = Number(perceptual[1]) / (perceptual[2] ? 100 : 1);
|
|
16073
|
+
return lightness < 0.6 ? 0.35 : 0.85;
|
|
16074
|
+
}
|
|
16075
|
+
const srgb = surface.match(/^color\(srgb\s+([\d.]+)\s+([\d.]+)\s+([\d.]+)/);
|
|
16076
|
+
if (srgb) {
|
|
16077
|
+
const brightness2 = Number(srgb[1]) * 0.2126 + Number(srgb[2]) * 0.7152 + Number(srgb[3]) * 0.0722;
|
|
16078
|
+
return brightness2 < 0.5 ? 0.35 : 0.85;
|
|
16079
|
+
}
|
|
16080
|
+
const channels = surface.match(/^rgba?\(\s*([\d.]+)[,\s]+([\d.]+)[,\s]+([\d.]+)/);
|
|
16081
|
+
if (!channels)
|
|
16082
|
+
return prefersDark ? 0.35 : 0.85;
|
|
16083
|
+
const brightness = Number(channels[1]) * 0.2126 + Number(channels[2]) * 0.7152 + Number(channels[3]) * 0.0722;
|
|
16084
|
+
return brightness < 128 ? 0.35 : 0.85;
|
|
16085
|
+
};
|
|
16086
|
+
const OrbBackground_css_ts_vanilla = "";
|
|
16087
|
+
var OrbBackground$1 = "gde17n1";
|
|
16088
|
+
var OrbBackgroundHost = "gde17n0";
|
|
16089
|
+
const OrbBackground = ({ className, appearance }) => {
|
|
16090
|
+
const ref = useRef(null);
|
|
16091
|
+
useEffect(() => {
|
|
16092
|
+
if (!ref.current)
|
|
16093
|
+
return void 0;
|
|
16094
|
+
return startOrbField(ref.current);
|
|
16095
|
+
}, []);
|
|
16096
|
+
useEffect(() => {
|
|
16097
|
+
var _a;
|
|
16098
|
+
const canvas = ref.current;
|
|
16099
|
+
if (!canvas)
|
|
16100
|
+
return void 0;
|
|
16101
|
+
const scheme = (_a = window.matchMedia) == null ? void 0 : _a.call(window, "(prefers-color-scheme: dark)");
|
|
16102
|
+
const sync = () => {
|
|
16103
|
+
let opacity = orbOpacityForSurface(getComputedStyle(canvas).color, (scheme == null ? void 0 : scheme.matches) ?? false);
|
|
16104
|
+
if (appearance)
|
|
16105
|
+
opacity = appearance === "dark" ? 0.35 : 0.85;
|
|
16106
|
+
canvas.style.opacity = String(opacity);
|
|
16107
|
+
};
|
|
16108
|
+
sync();
|
|
16109
|
+
const observer = new MutationObserver(sync);
|
|
16110
|
+
let ancestor = canvas.parentElement;
|
|
16111
|
+
while (ancestor) {
|
|
16112
|
+
observer.observe(ancestor, { attributes: true, attributeFilter: ["class", "style"] });
|
|
16113
|
+
ancestor = ancestor.parentElement;
|
|
16114
|
+
}
|
|
16115
|
+
scheme == null ? void 0 : scheme.addEventListener("change", sync);
|
|
16116
|
+
return () => {
|
|
16117
|
+
observer.disconnect();
|
|
16118
|
+
scheme == null ? void 0 : scheme.removeEventListener("change", sync);
|
|
16119
|
+
};
|
|
16120
|
+
}, [appearance]);
|
|
16121
|
+
return /* @__PURE__ */ jsx("canvas", { ref, className: classNames(OrbBackground$1, className), "aria-hidden": "true" });
|
|
16122
|
+
};
|
|
16123
|
+
const SplashScreen_css_ts_vanilla = "";
|
|
16124
|
+
var SplashScreen$1 = "wf38060";
|
|
16125
|
+
var SplashScreenFooter = "wf38061";
|
|
16126
|
+
const SplashScreen = ({ children }) => /* @__PURE__ */ jsxs(Box, { className: classNames(SplashScreen$1, OrbBackgroundHost), direction: "Column", children: [
|
|
16127
|
+
/* @__PURE__ */ jsx(OrbBackground, {}),
|
|
16128
|
+
children,
|
|
16129
|
+
/* @__PURE__ */ jsx(Box, { className: SplashScreenFooter, shrink: "No", alignItems: "Center", justifyContent: "Center", children: /* @__PURE__ */ jsx(Text, { size: "H2", align: "Center", children: "AG2 Space" }) })
|
|
16130
|
+
] });
|
|
15784
16131
|
const Starfield_css_ts_vanilla = "";
|
|
15785
16132
|
var Starfield$1 = "_4j0z2c1";
|
|
15786
16133
|
var StarfieldHost = "_4j0z2c0";
|
|
@@ -15888,14 +16235,6 @@ const Starfield = ({ className }) => {
|
|
|
15888
16235
|
}, []);
|
|
15889
16236
|
return /* @__PURE__ */ jsx("canvas", { ref: canvasRef, className: classNames(Starfield$1, className), "aria-hidden": true });
|
|
15890
16237
|
};
|
|
15891
|
-
const SplashScreen_css_ts_vanilla = "";
|
|
15892
|
-
var SplashScreen$1 = "wf38060";
|
|
15893
|
-
var SplashScreenFooter = "wf38061";
|
|
15894
|
-
const SplashScreen = ({ children }) => /* @__PURE__ */ jsxs(Box, { className: classNames(SplashScreen$1, StarfieldHost), direction: "Column", children: [
|
|
15895
|
-
/* @__PURE__ */ jsx(Starfield, {}),
|
|
15896
|
-
children,
|
|
15897
|
-
/* @__PURE__ */ jsx(Box, { className: SplashScreenFooter, shrink: "No", alignItems: "Center", justifyContent: "Center", children: /* @__PURE__ */ jsx(Text, { size: "H2", align: "Center", children: "AG2 Space" }) })
|
|
15898
|
-
] });
|
|
15899
16238
|
const style_css_ts_vanilla = "";
|
|
15900
16239
|
var PageCanvas$1 = "_18hg0vg1";
|
|
15901
16240
|
var PageContent$1 = "_18hg0vge _8nex5a1 _8nex5a0";
|
|
@@ -16893,14 +17232,14 @@ const UnreadBadge = as(
|
|
|
16893
17232
|
const ActivityRow_css_ts_vanilla = "";
|
|
16894
17233
|
var ActivityRow$1 = createRuntimeFn({ defaultClassName: "_3hdcuo0 _8nex5a1 _8nex5a0 x4g6300 x4g6301", variantClassNames: { layout: { panel: "_3hdcuo1", card: "_3hdcuo2" }, unread: { true: "_3hdcuo3" }, read: { true: "_3hdcuo4" }, selected: { true: "_3hdcuo5" } }, defaultVariants: { layout: "panel" }, compoundVariants: [] });
|
|
16895
17234
|
var Avatar = "_3hdcuo6";
|
|
16896
|
-
var Body = "_3hdcuo7";
|
|
17235
|
+
var Body$1 = "_3hdcuo7";
|
|
16897
17236
|
var Footer$1 = "_3hdcuoh";
|
|
16898
17237
|
var Header = "_3hdcuo8";
|
|
16899
17238
|
var Meta = "_3hdcuoi";
|
|
16900
17239
|
var Preview = "_3hdcuog";
|
|
16901
17240
|
var Reason = createRuntimeFn({ defaultClassName: "_3hdcuo9", variantClassNames: { tone: { you: "_3hdcuoa", agent: "_3hdcuob", participant: "_3hdcuoc" } }, defaultVariants: {}, compoundVariants: [] });
|
|
16902
|
-
var Time = "_3hdcuoe";
|
|
16903
|
-
var Title = "_3hdcuof";
|
|
17241
|
+
var Time$1 = "_3hdcuoe";
|
|
17242
|
+
var Title$1 = "_3hdcuof";
|
|
16904
17243
|
var Where = "_3hdcuod";
|
|
16905
17244
|
const ActivityRow = as(
|
|
16906
17245
|
({
|
|
@@ -16934,7 +17273,7 @@ const ActivityRow = as(
|
|
|
16934
17273
|
ref,
|
|
16935
17274
|
children: [
|
|
16936
17275
|
/* @__PURE__ */ jsx("span", { className: Avatar, children: avatar }),
|
|
16937
|
-
/* @__PURE__ */ jsxs("span", { className: Body, children: [
|
|
17276
|
+
/* @__PURE__ */ jsxs("span", { className: Body$1, children: [
|
|
16938
17277
|
/* @__PURE__ */ jsxs("span", { className: Header, children: [
|
|
16939
17278
|
/* @__PURE__ */ jsx("span", { className: Reason({ tone: read ? "participant" : reasonTone }), children: reason2 }),
|
|
16940
17279
|
/* @__PURE__ */ jsxs("span", { className: Where, children: [
|
|
@@ -16942,7 +17281,7 @@ const ActivityRow = as(
|
|
|
16942
17281
|
where
|
|
16943
17282
|
] })
|
|
16944
17283
|
] }),
|
|
16945
|
-
layout === "card" && title && /* @__PURE__ */ jsx("span", { className: Title, children: title }),
|
|
17284
|
+
layout === "card" && title && /* @__PURE__ */ jsx("span", { className: Title$1, children: title }),
|
|
16946
17285
|
/* @__PURE__ */ jsx("span", { className: Preview, children: preview }),
|
|
16947
17286
|
/* @__PURE__ */ jsxs("span", { className: Footer$1, children: [
|
|
16948
17287
|
!read && (count2 > 0 || unread > 0) && /* @__PURE__ */ jsx(UnreadBadgeCenter, { children: /* @__PURE__ */ jsx(
|
|
@@ -16956,7 +17295,7 @@ const ActivityRow = as(
|
|
|
16956
17295
|
unreadLabel && /* @__PURE__ */ jsx("span", { children: unreadLabel }),
|
|
16957
17296
|
meta2 && /* @__PURE__ */ jsx("span", { className: Meta, children: meta2 })
|
|
16958
17297
|
] }),
|
|
16959
|
-
/* @__PURE__ */ jsx("span", { className: Time, children: time })
|
|
17298
|
+
/* @__PURE__ */ jsx("span", { className: Time$1, children: time })
|
|
16960
17299
|
] })
|
|
16961
17300
|
]
|
|
16962
17301
|
}
|
|
@@ -17169,7 +17508,7 @@ const EmptyState = as(
|
|
|
17169
17508
|
}, ref) => /* @__PURE__ */ jsx(Component, { className: classNames(EmptyState$1, className), ...props, ref, children: /* @__PURE__ */ jsx(PageHeroEmpty, { compact, children: /* @__PURE__ */ jsx(PageHero, { icon: icon2, title, subTitle: description ?? subTitle, children: action2 ?? children }) }) })
|
|
17170
17509
|
);
|
|
17171
17510
|
const PanelSwitch_css_ts_vanilla = "";
|
|
17172
|
-
var Attention = "e7d7gk4";
|
|
17511
|
+
var Attention$1 = "e7d7gk4";
|
|
17173
17512
|
var Count = "e7d7gk5";
|
|
17174
17513
|
var CountPill = "e7d7gk6";
|
|
17175
17514
|
var Folds = "e7d7gk9";
|
|
@@ -17195,12 +17534,13 @@ const PanelSwitch = as(
|
|
|
17195
17534
|
count: count2,
|
|
17196
17535
|
countStyle = "Plain",
|
|
17197
17536
|
labelled = false,
|
|
17537
|
+
iconOnly = false,
|
|
17198
17538
|
attention = false,
|
|
17199
17539
|
className,
|
|
17200
17540
|
...props
|
|
17201
17541
|
}, ref) => {
|
|
17202
17542
|
const hasCount = count2 !== void 0 && count2 > 0;
|
|
17203
|
-
const showLabel = selected || labelled;
|
|
17543
|
+
const showLabel = (selected || labelled) && !iconOnly;
|
|
17204
17544
|
const showCount = showLabel && hasCount;
|
|
17205
17545
|
const countPill = showCount && selected && countStyle === "Pill";
|
|
17206
17546
|
const name = [
|
|
@@ -17216,7 +17556,8 @@ const PanelSwitch = as(
|
|
|
17216
17556
|
"aria-label": name,
|
|
17217
17557
|
title: label,
|
|
17218
17558
|
"data-selected": selected || void 0,
|
|
17219
|
-
"data-labelled": labelled || void 0,
|
|
17559
|
+
"data-labelled": labelled && !iconOnly || void 0,
|
|
17560
|
+
"data-icon-only": iconOnly || void 0,
|
|
17220
17561
|
"data-count-pill": countPill || void 0,
|
|
17221
17562
|
className: classNames(PanelSwitch$1, className),
|
|
17222
17563
|
...props,
|
|
@@ -17224,7 +17565,7 @@ const PanelSwitch = as(
|
|
|
17224
17565
|
children: [
|
|
17225
17566
|
/* @__PURE__ */ jsxs("span", { className: Glyph, children: [
|
|
17226
17567
|
/* @__PURE__ */ jsx(Icon$2, { src: icon2, size: "compact" }),
|
|
17227
|
-
attention && !selected && /* @__PURE__ */ jsx("span", { className: Attention })
|
|
17568
|
+
attention && !selected && /* @__PURE__ */ jsx("span", { className: Attention$1 })
|
|
17228
17569
|
] }),
|
|
17229
17570
|
showLabel && /* @__PURE__ */ jsx(Text, { as: "span", size: "H6", className: classNames(Label, Folds), "aria-hidden": true, children: label }),
|
|
17230
17571
|
showCount && /* @__PURE__ */ jsx(
|
|
@@ -17243,14 +17584,14 @@ const PanelSwitch = as(
|
|
|
17243
17584
|
}
|
|
17244
17585
|
);
|
|
17245
17586
|
const PeopleLine_css_ts_vanilla = "";
|
|
17246
|
-
var Face = "kev8vj2";
|
|
17587
|
+
var Face$1 = "kev8vj2";
|
|
17247
17588
|
var Faces = "kev8vj1";
|
|
17248
17589
|
var Live = "kev8vj3";
|
|
17249
17590
|
var PeopleLine$1 = "kev8vj0 _8nex5a1 _8nex5a0";
|
|
17250
17591
|
var Summary = "kev8vj4";
|
|
17251
17592
|
var Working = "kev8vj6";
|
|
17252
17593
|
const PeopleLineFace = as(
|
|
17253
|
-
({ as: Component = "span", size: size2 = "small", className, ...props }, ref) => /* @__PURE__ */ jsx(Component, { "data-size": size2, className: classNames(Face, className), ...props, ref })
|
|
17594
|
+
({ as: Component = "span", size: size2 = "small", className, ...props }, ref) => /* @__PURE__ */ jsx(Component, { "data-size": size2, className: classNames(Face$1, className), ...props, ref })
|
|
17254
17595
|
);
|
|
17255
17596
|
const PeopleLine = as(
|
|
17256
17597
|
({ as: Component = "div", faces, status = "Default", className, children, ...props }, ref) => /* @__PURE__ */ jsxs(
|
|
@@ -17269,14 +17610,14 @@ const PeopleLine = as(
|
|
|
17269
17610
|
)
|
|
17270
17611
|
);
|
|
17271
17612
|
const RoomHeader_css_ts_vanilla = "";
|
|
17272
|
-
var Controls = "cv0ofl6";
|
|
17613
|
+
var Controls$1 = "cv0ofl6";
|
|
17273
17614
|
var Divider = "cv0ofl7";
|
|
17274
17615
|
var Identity = "cv0ofl3";
|
|
17275
17616
|
var Mark = "cv0ofl2";
|
|
17276
|
-
var Name = "cv0ofl4";
|
|
17617
|
+
var Name$1 = "cv0ofl4";
|
|
17277
17618
|
var RoomHeader$1 = "cv0ofl0 _8nex5a1 _8nex5a0";
|
|
17278
17619
|
var Row = "cv0ofl1";
|
|
17279
|
-
var Spacer = "cv0ofl5";
|
|
17620
|
+
var Spacer$1 = "cv0ofl5";
|
|
17280
17621
|
const RoomHeaderMark = as(
|
|
17281
17622
|
({ as: Component = "span", faces, className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
17282
17623
|
Component,
|
|
@@ -17302,17 +17643,17 @@ const RoomHeader = as(
|
|
|
17302
17643
|
}, ref) => /* @__PURE__ */ jsx(Component, { className: classNames(RoomHeader$1, className), ...props, ref, children: /* @__PURE__ */ jsxs("div", { className: Row, children: [
|
|
17303
17644
|
mark,
|
|
17304
17645
|
/* @__PURE__ */ jsxs("div", { className: Identity, children: [
|
|
17305
|
-
/* @__PURE__ */ jsx(Text, { as: nameAs, size: "H5", truncate: true, className: Name, children: name }),
|
|
17646
|
+
/* @__PURE__ */ jsx(Text, { as: nameAs, size: "H5", truncate: true, className: Name$1, children: name }),
|
|
17306
17647
|
people
|
|
17307
17648
|
] }),
|
|
17308
|
-
/* @__PURE__ */ jsx("div", { className: Spacer }),
|
|
17309
|
-
controls && /* @__PURE__ */ jsx("div", { className: Controls, children: controls }),
|
|
17649
|
+
/* @__PURE__ */ jsx("div", { className: Spacer$1 }),
|
|
17650
|
+
controls && /* @__PURE__ */ jsx("div", { className: Controls$1, children: controls }),
|
|
17310
17651
|
controls && panels && /* @__PURE__ */ jsx("div", { className: Divider, "aria-hidden": true }),
|
|
17311
17652
|
panels
|
|
17312
17653
|
] }) })
|
|
17313
17654
|
);
|
|
17314
17655
|
const Composer_css_ts_vanilla = "";
|
|
17315
|
-
var Actions = "_1ejw1qz3";
|
|
17656
|
+
var Actions$1 = "_1ejw1qz3";
|
|
17316
17657
|
var ActionsAfter = "_1ejw1qz5";
|
|
17317
17658
|
var ActionsBefore = "_1ejw1qz4";
|
|
17318
17659
|
var Composer$1 = "_1ejw1qz0";
|
|
@@ -17334,7 +17675,7 @@ const Composer = as(
|
|
|
17334
17675
|
/* @__PURE__ */ jsxs("div", { className: Surface, children: [
|
|
17335
17676
|
context,
|
|
17336
17677
|
/* @__PURE__ */ jsx("div", { className: Content, children }),
|
|
17337
|
-
(actionsBefore || actionsAfter) && /* @__PURE__ */ jsxs("div", { className: Actions, children: [
|
|
17678
|
+
(actionsBefore || actionsAfter) && /* @__PURE__ */ jsxs("div", { className: Actions$1, children: [
|
|
17338
17679
|
/* @__PURE__ */ jsx("div", { className: ActionsBefore, children: actionsBefore }),
|
|
17339
17680
|
/* @__PURE__ */ jsx("div", { className: ActionsAfter, children: actionsAfter })
|
|
17340
17681
|
] }),
|
|
@@ -17689,6 +18030,133 @@ const InspectorTab = as(
|
|
|
17689
18030
|
}
|
|
17690
18031
|
)
|
|
17691
18032
|
);
|
|
18033
|
+
const ActivityItem_css_ts_vanilla = "";
|
|
18034
|
+
var Action = "_1wyqgiii _8nex5a1 _8nex5a0 x4g6300";
|
|
18035
|
+
var Actions = "_1wyqgiie _1wyqgii9";
|
|
18036
|
+
var ActivityItem$1 = "_1wyqgii0 _8nex5a1 _8nex5a0";
|
|
18037
|
+
var Attention = "_1wyqgiif";
|
|
18038
|
+
var AttentionBreathing = "_1wyqgiih";
|
|
18039
|
+
var Body = "_1wyqgiia _1wyqgii9";
|
|
18040
|
+
var Face = "_1wyqgii4";
|
|
18041
|
+
var Head = "_1wyqgii3";
|
|
18042
|
+
var Main = "_1wyqgii2 _8nex5a1 _8nex5a0 x4g6300";
|
|
18043
|
+
var Name = "_1wyqgii5";
|
|
18044
|
+
var ObjectRow = "_1wyqgiid _1wyqgii9";
|
|
18045
|
+
var Replies = "_1wyqgiib _8nex5a1 _8nex5a0 x4g6300 _1wyqgii9";
|
|
18046
|
+
var RepliesUnread = "_1wyqgiic";
|
|
18047
|
+
var SelectedBar = "_1wyqgii1";
|
|
18048
|
+
var Time = "_1wyqgii7";
|
|
18049
|
+
var UnreadDot = "_1wyqgii8";
|
|
18050
|
+
var What = "_1wyqgii6";
|
|
18051
|
+
const ActivityItem = as(
|
|
18052
|
+
({
|
|
18053
|
+
as: Component = "div",
|
|
18054
|
+
avatar,
|
|
18055
|
+
name,
|
|
18056
|
+
what,
|
|
18057
|
+
time,
|
|
18058
|
+
body,
|
|
18059
|
+
unread = false,
|
|
18060
|
+
read = false,
|
|
18061
|
+
attention,
|
|
18062
|
+
selected = false,
|
|
18063
|
+
replies,
|
|
18064
|
+
object,
|
|
18065
|
+
actions,
|
|
18066
|
+
actionsShown = false,
|
|
18067
|
+
onOpen,
|
|
18068
|
+
label,
|
|
18069
|
+
className,
|
|
18070
|
+
...props
|
|
18071
|
+
}, ref) => /* @__PURE__ */ jsxs(
|
|
18072
|
+
Component,
|
|
18073
|
+
{
|
|
18074
|
+
"data-read": read || void 0,
|
|
18075
|
+
"data-selected": selected || void 0,
|
|
18076
|
+
className: classNames(ActivityItem$1, className),
|
|
18077
|
+
...props,
|
|
18078
|
+
ref,
|
|
18079
|
+
children: [
|
|
18080
|
+
selected && /* @__PURE__ */ jsx("span", { "aria-hidden": true, className: SelectedBar }),
|
|
18081
|
+
attention && /* @__PURE__ */ jsx(
|
|
18082
|
+
"span",
|
|
18083
|
+
{
|
|
18084
|
+
"aria-hidden": true,
|
|
18085
|
+
className: classNames(Attention, attention === "breathing" && AttentionBreathing)
|
|
18086
|
+
}
|
|
18087
|
+
),
|
|
18088
|
+
/* @__PURE__ */ jsxs(
|
|
18089
|
+
"button",
|
|
18090
|
+
{
|
|
18091
|
+
type: "button",
|
|
18092
|
+
className: Main,
|
|
18093
|
+
"aria-label": [
|
|
18094
|
+
label ?? `${name} ${what}, ${time}`,
|
|
18095
|
+
unread && "unread",
|
|
18096
|
+
attention && "needs you"
|
|
18097
|
+
].filter(Boolean).join(", "),
|
|
18098
|
+
"aria-current": selected ? "true" : void 0,
|
|
18099
|
+
onClick: onOpen,
|
|
18100
|
+
children: [
|
|
18101
|
+
/* @__PURE__ */ jsxs("span", { className: Head, children: [
|
|
18102
|
+
/* @__PURE__ */ jsx("span", { className: Face, children: avatar }),
|
|
18103
|
+
/* @__PURE__ */ jsx(Text, { as: "span", size: "H6", className: Name, children: name }),
|
|
18104
|
+
/* @__PURE__ */ jsx(Text, { as: "span", size: "T300", className: What, children: what }),
|
|
18105
|
+
/* @__PURE__ */ jsx(Text, { as: "span", size: "T200", className: Time, children: time }),
|
|
18106
|
+
unread && /* @__PURE__ */ jsx("span", { "aria-hidden": true, className: UnreadDot })
|
|
18107
|
+
] }),
|
|
18108
|
+
body && /* @__PURE__ */ jsx(Text, { as: "span", size: "T300", className: Body, children: body })
|
|
18109
|
+
]
|
|
18110
|
+
}
|
|
18111
|
+
),
|
|
18112
|
+
object && /* @__PURE__ */ jsx("div", { className: ObjectRow, children: object }),
|
|
18113
|
+
replies && /* @__PURE__ */ jsxs("button", { type: "button", className: Replies, onClick: replies.onOpen, children: [
|
|
18114
|
+
/* @__PURE__ */ jsx(Text, { as: "span", size: "L400", children: replies.total }),
|
|
18115
|
+
replies.unread && /* @__PURE__ */ jsxs(Text, { as: "span", size: "L400", className: RepliesUnread, children: [
|
|
18116
|
+
"· ",
|
|
18117
|
+
replies.unread
|
|
18118
|
+
] })
|
|
18119
|
+
] }),
|
|
18120
|
+
actions && /* @__PURE__ */ jsx("div", { className: Actions, "data-pinned": actionsShown || void 0, children: actions })
|
|
18121
|
+
]
|
|
18122
|
+
}
|
|
18123
|
+
)
|
|
18124
|
+
);
|
|
18125
|
+
const ActivityItemAction = as(
|
|
18126
|
+
({ as: Component = "button", label, icon: icon2, primary = false, className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
18127
|
+
Component,
|
|
18128
|
+
{
|
|
18129
|
+
type: Component === "button" ? "button" : void 0,
|
|
18130
|
+
"aria-label": label,
|
|
18131
|
+
title: label,
|
|
18132
|
+
"data-labelled": !icon2 || void 0,
|
|
18133
|
+
"data-primary": primary || void 0,
|
|
18134
|
+
className: classNames(Action, className),
|
|
18135
|
+
...props,
|
|
18136
|
+
ref,
|
|
18137
|
+
children: icon2 ? /* @__PURE__ */ jsx(Icon$2, { src: icon2, size: "standard" }) : /* @__PURE__ */ jsx(Text, { as: "span", size: "B400", children: label })
|
|
18138
|
+
}
|
|
18139
|
+
)
|
|
18140
|
+
);
|
|
18141
|
+
const ActivityHeader_css_ts_vanilla = "";
|
|
18142
|
+
var ActivityHeader$1 = "_1yfy4k20 _8nex5a1 _8nex5a0";
|
|
18143
|
+
var Controls = "_1yfy4k23";
|
|
18144
|
+
var Spacer = "_1yfy4k24";
|
|
18145
|
+
var Title = "_1yfy4k22";
|
|
18146
|
+
var TitleRow = "_1yfy4k21";
|
|
18147
|
+
const ActivityHeader = as(
|
|
18148
|
+
({ as: Component = "div", title, actions, filters, after, className, ...props }, ref) => /* @__PURE__ */ jsxs(Component, { className: classNames(ActivityHeader$1, className), ...props, ref, children: [
|
|
18149
|
+
/* @__PURE__ */ jsxs("div", { className: TitleRow, children: [
|
|
18150
|
+
/* @__PURE__ */ jsx(Text, { as: "h2", size: "H6", className: Title, children: title }),
|
|
18151
|
+
actions
|
|
18152
|
+
] }),
|
|
18153
|
+
(filters || after) && /* @__PURE__ */ jsxs("div", { className: Controls, children: [
|
|
18154
|
+
filters,
|
|
18155
|
+
/* @__PURE__ */ jsx("span", { "aria-hidden": true, className: Spacer }),
|
|
18156
|
+
after
|
|
18157
|
+
] })
|
|
18158
|
+
] })
|
|
18159
|
+
);
|
|
17692
18160
|
function ActionGroup({ actions, hint: hint$1 }) {
|
|
17693
18161
|
return /* @__PURE__ */ jsxs("div", { className: actionSection, children: [
|
|
17694
18162
|
/* @__PURE__ */ jsx("div", { className: actionGroup, role: "group", "aria-label": "Draft a PR request", children: actions.map((action$1) => /* @__PURE__ */ jsxs(
|
|
@@ -17714,6 +18182,9 @@ export {
|
|
|
17714
18182
|
AGENT_STATE_MARKS,
|
|
17715
18183
|
ActionGroup,
|
|
17716
18184
|
ActivityGroup,
|
|
18185
|
+
ActivityHeader,
|
|
18186
|
+
ActivityItem,
|
|
18187
|
+
ActivityItemAction,
|
|
17717
18188
|
ActivityRow,
|
|
17718
18189
|
AgentGlyph,
|
|
17719
18190
|
AgentMark,
|
|
@@ -17767,6 +18238,8 @@ export {
|
|
|
17767
18238
|
MenuItem,
|
|
17768
18239
|
Modal,
|
|
17769
18240
|
NavCollapseRow,
|
|
18241
|
+
OrbBackground,
|
|
18242
|
+
OrbBackgroundHost,
|
|
17770
18243
|
Overlay,
|
|
17771
18244
|
OverlayBackdrop,
|
|
17772
18245
|
OverlayCenter,
|