clavarium 0.2.282-next.1 → 0.2.284-next.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.
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "clavarium",
3
- "version": "0.2.282-next.1",
3
+ "version": "0.2.284-next.1",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "clavarium",
9
- "version": "0.2.282-next.1",
9
+ "version": "0.2.284-next.1",
10
10
  "license": "MIT",
11
11
  "dependencies": {
12
12
  "@xterm/addon-fit": "^0.11.0",
@@ -14,7 +14,7 @@
14
14
  "clavarium-binder": "0.1.59-next.1",
15
15
  "clavarium-docket": "0.1.2-next.2",
16
16
  "clavarium-parley": "0.17.50-next.1",
17
- "clavarium-tether": "0.1.0-next.48",
17
+ "clavarium-tether": "0.1.0-next.49",
18
18
  "mammoth": "1.13.0",
19
19
  "mermaid": "11.17.2",
20
20
  "node-pty": "^1.1.0",
@@ -800,9 +800,9 @@
800
800
  }
801
801
  },
802
802
  "node_modules/clavarium-tether": {
803
- "version": "0.1.0-next.48",
804
- "resolved": "https://registry.npmjs.org/clavarium-tether/-/clavarium-tether-0.1.0-next.48.tgz",
805
- "integrity": "sha512-1u20NVKTNEWpBBj7gA80ig1LOO3cMpZkdw7U//yjXoKAMVoHWkYn7TZOLQZlSJwS7VYrC2cYhlAX96D18DDEgA==",
803
+ "version": "0.1.0-next.49",
804
+ "resolved": "https://registry.npmjs.org/clavarium-tether/-/clavarium-tether-0.1.0-next.49.tgz",
805
+ "integrity": "sha512-r2TNj/eC6U5drx4GDxo05iZKPwJ8M4cgq4l6IQhMDdys61x9Q1TKp9gTY7WFa4TOVQ1k8prRwChgvFB9kOWAXA==",
806
806
  "license": "MIT",
807
807
  "bin": {
808
808
  "tether": "bin/cli.mjs",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "clavarium",
3
- "version": "0.2.282-next.1",
3
+ "version": "0.2.284-next.1",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "description": "A conversation is a VM with a terminal in it. Everything else is a folder.",
@@ -47,7 +47,7 @@
47
47
  "clavarium-binder": "0.1.59-next.1",
48
48
  "clavarium-docket": "0.1.2-next.2",
49
49
  "clavarium-parley": "0.17.50-next.1",
50
- "clavarium-tether": "0.1.0-next.48",
50
+ "clavarium-tether": "0.1.0-next.49",
51
51
  "mammoth": "1.13.0",
52
52
  "mermaid": "11.17.2",
53
53
  "node-pty": "^1.1.0",
package/web/app.js CHANGED
@@ -1293,7 +1293,7 @@
1293
1293
  /* NEEDS YOU: whatever its date, until its owner acts; hidden ones too (they said so). */
1294
1294
  const needs = conversations.filter(needsYou).sort((a, b) => activityOf(b) - activityOf(a));
1295
1295
  if (needs.length && section(NEEDS, 'Needs you', needs)) top.append(...unfolding(NEEDS, needs.map((c) => itemButton(c, true))));
1296
- /* RECENT: by when it was last used; the last four, then all. Never a hidden one. Only once there
1296
+ /* RECENT: by when it was last used; up to seven awake, then all. Never a hidden one. Only once there
1297
1297
  are groups: before, the one list below says the same, in the order chosen by hand. */
1298
1298
  /* One in Needs you just above is not said twice. */
1299
1299
  /* The last day only: what is older is found in its group. */
@@ -1301,9 +1301,14 @@
1301
1301
  /* Asleep ones go to the bottom of Recent: they are frozen, not what you came back to. */
1302
1302
  const recent = conversations.filter((c) => (c.hidden !== true || c.name === current) && !needsYou(c) && activityOf(c) >= dayAgo)
1303
1303
  .sort((a, b) => (Number(a.asleep === true) - Number(b.asleep === true)) || (activityOf(b) - activityOf(a)));
1304
- const few = 4;
1304
+ /* In sight (03-11, his rule): up to seven awake ones, and the one open even asleep (it never vanishes
1305
+ under the eyes); the rest -- asleep, or past seven -- under the arrow. */
1306
+ const inSight = recent.filter((c) => c.asleep !== true).slice(0, 7);
1307
+ const openOne = recent.find((c) => c.name === current);
1308
+ if (openOne && !inSight.includes(openOne)) inSight.push(openOne);
1309
+ const few = inSight.length;
1305
1310
  if (recent.length && groups.length && section(RECENT, 'Recent', recent)) {
1306
- top.append(...unfolding(RECENT, recent.slice(0, showAllRecent ? recent.length : few).map((c) => itemButton(c, true))));
1311
+ top.append(...unfolding(RECENT, (showAllRecent ? recent : recent.filter((c) => inSight.includes(c))).map((c) => itemButton(c, true))));
1307
1312
  if (recent.length > few) {
1308
1313
  const more = document.createElement('button'); more.type = 'button'; more.className = 'inline more-recent';
1309
1314
  /* A chevron, centred: the words for the pointer and for a screen reader. */