@celljs/ta-rooms 4.15.0 → 4.15.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +4 -4
- package/web/index.js +17 -5
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@celljs/ta-rooms",
|
|
3
|
-
"version": "4.15.
|
|
3
|
+
"version": "4.15.1",
|
|
4
4
|
"description": "A pi package for Ta: rooms shared with other Ta through the relay, end to end: who asks to join and the owner's answer, your rooms and their members, your Ta friends, and links that invite",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"pi-package"
|
|
@@ -27,9 +27,9 @@
|
|
|
27
27
|
"watch": "tsc -b -w --preserveWatchOutput"
|
|
28
28
|
},
|
|
29
29
|
"devDependencies": {
|
|
30
|
-
"@celljs/ta-protocol": "4.15.
|
|
31
|
-
"@celljs/ta-relay": "4.15.
|
|
32
|
-
"@celljs/ta-web": "4.15.
|
|
30
|
+
"@celljs/ta-protocol": "4.15.1",
|
|
31
|
+
"@celljs/ta-relay": "4.15.1",
|
|
32
|
+
"@celljs/ta-web": "4.15.1",
|
|
33
33
|
"@types/react": "^19.3.0"
|
|
34
34
|
},
|
|
35
35
|
"publishConfig": {
|
package/web/index.js
CHANGED
|
@@ -2539,6 +2539,18 @@ async function revokeAll(friend, name) {
|
|
|
2539
2539
|
await callDoubles({ kind: "revokeAll", friend }).catch((error) => pi.ui.notify(message(error), "error"));
|
|
2540
2540
|
}
|
|
2541
2541
|
}
|
|
2542
|
+
function RevokeAll({ friend, name }) {
|
|
2543
|
+
const [busy, run] = useBusy();
|
|
2544
|
+
return /* @__PURE__ */ React.createElement("button", {
|
|
2545
|
+
type: "button",
|
|
2546
|
+
className: `trm-link trm-danger trm-panel-note${busy ? " ta-busy" : ""}`,
|
|
2547
|
+
"aria-busy": busy || undefined,
|
|
2548
|
+
disabled: busy,
|
|
2549
|
+
onClick: () => void run(() => revokeAll(friend, name))
|
|
2550
|
+
}, busy && /* @__PURE__ */ React.createElement("span", {
|
|
2551
|
+
className: "ta-spinner ta-busy-mark"
|
|
2552
|
+
}), /* @__PURE__ */ React.createElement("span", null, dt("revokeAll", { name })));
|
|
2553
|
+
}
|
|
2542
2554
|
function GrantRow({ grant }) {
|
|
2543
2555
|
const [busy, run] = useBusy();
|
|
2544
2556
|
return /* @__PURE__ */ React.createElement("li", {
|
|
@@ -2616,12 +2628,11 @@ function DoublesView() {
|
|
|
2616
2628
|
}, live.map((grant) => /* @__PURE__ */ React.createElement(GrantRow, {
|
|
2617
2629
|
key: grant.id,
|
|
2618
2630
|
grant
|
|
2619
|
-
}))), friends.map(([friend, name]) => /* @__PURE__ */ React.createElement(
|
|
2631
|
+
}))), friends.map(([friend, name]) => /* @__PURE__ */ React.createElement(RevokeAll, {
|
|
2620
2632
|
key: friend,
|
|
2621
|
-
|
|
2622
|
-
|
|
2623
|
-
|
|
2624
|
-
}, dt("revokeAll", { name })))), /* @__PURE__ */ React.createElement("div", {
|
|
2633
|
+
friend,
|
|
2634
|
+
name
|
|
2635
|
+
}))), /* @__PURE__ */ React.createElement("div", {
|
|
2625
2636
|
className: "trm-panel-label trm-log-label"
|
|
2626
2637
|
}, /* @__PURE__ */ React.createElement("span", null, dt("logTitle")), recent.length > 0 && /* @__PURE__ */ React.createElement("button", {
|
|
2627
2638
|
type: "button",
|
|
@@ -4285,6 +4296,7 @@ var STYLE = `
|
|
|
4285
4296
|
.trm-link { padding: 2px 4px; border: 0; border-radius: 6px; background: none; color: var(--ta-link); font: inherit; cursor: pointer; }
|
|
4286
4297
|
.trm-link:hover { background: var(--ta-hover); }
|
|
4287
4298
|
.trm-link.trm-danger { color: var(--ta-red); }
|
|
4299
|
+
.trm-link.ta-busy { position: relative; }
|
|
4288
4300
|
/* The faces: those of channels (ui.Face), or a letter in a circle in an app of before */
|
|
4289
4301
|
.ta-face { --ta-face-ring: var(--ta-side); }
|
|
4290
4302
|
.trm-chat .ta-face, .trm-panel .ta-face, .trm-head .ta-face { --ta-face-ring: var(--ta-main); }
|