@biolibs/bionet-panels 0.1.0 → 0.2.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 +34 -0
- package/dist/freezer.d.ts.map +1 -1
- package/dist/freezer.js +1 -0
- package/dist/freezer.js.map +1 -1
- package/dist/history.d.ts.map +1 -1
- package/dist/history.js +1 -0
- package/dist/history.js.map +1 -1
- package/dist/index.d.ts +5 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +5 -0
- package/dist/index.js.map +1 -1
- package/dist/parts.d.ts.map +1 -1
- package/dist/parts.js +1 -0
- package/dist/parts.js.map +1 -1
- package/dist/people.d.ts.map +1 -1
- package/dist/people.js +1 -0
- package/dist/people.js.map +1 -1
- package/dist/public.d.ts +77 -0
- package/dist/public.d.ts.map +1 -0
- package/dist/public.js +73 -0
- package/dist/public.js.map +1 -0
- package/dist/sharing.d.ts.map +1 -1
- package/dist/sharing.js +1 -0
- package/dist/sharing.js.map +1 -1
- package/dist/window.d.ts.map +1 -1
- package/dist/window.js +1 -0
- package/dist/window.js.map +1 -1
- package/package.json +3 -2
- package/panels.css +6 -0
- package/src/freezer.tsx +2 -0
- package/src/history.tsx +2 -0
- package/src/index.ts +5 -0
- package/src/parts.tsx +2 -0
- package/src/people.tsx +2 -0
- package/src/public.tsx +175 -0
- package/src/sharing.tsx +2 -0
- package/src/window.tsx +2 -0
package/README.md
CHANGED
|
@@ -46,6 +46,40 @@ used on its own inside one:
|
|
|
46
46
|
|
|
47
47
|
Every colour comes from `@biolibs/bionet-theme`, and no rule reaches outside `.bionet`.
|
|
48
48
|
|
|
49
|
+
## A lab's public page
|
|
50
|
+
|
|
51
|
+
What a lab shows the world, and what it can see of another lab. These take what was fetched and
|
|
52
|
+
checked as plain values, so they can be drawn on a server:
|
|
53
|
+
|
|
54
|
+
```tsx
|
|
55
|
+
import { fetchInventory, originMatches, readInventory, verifyInventory } from "@biolibs/bionet";
|
|
56
|
+
import { Held, LabPage, PeerAnswered, PeerSilent } from "@biolibs/bionet-panels";
|
|
57
|
+
|
|
58
|
+
const mine = readInventory(published);
|
|
59
|
+
const checks = await verifyInventory(mine);
|
|
60
|
+
|
|
61
|
+
<LabPage name="The Wren Lab" note="A worked example, not a real freezer.">
|
|
62
|
+
<Held parts={mine.inventory.parts} checks={checks} origin={ORIGIN}
|
|
63
|
+
bound={originMatches(mine.inventory.lab.origin, ORIGIN)} />
|
|
64
|
+
<h2>What we can see of The Thistle Lab</h2>
|
|
65
|
+
<PeerAnswered found={await fetchInventory(PEER)} mine={mine.inventory.parts} />
|
|
66
|
+
</LabPage>
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
| Piece | Shows |
|
|
70
|
+
|---|---|
|
|
71
|
+
| `LabPage` | The frame: the mark, the lab's name, a line about what it is |
|
|
72
|
+
| `Held` | What the lab holds, and what the signature over that list settles |
|
|
73
|
+
| `PeerAnswered` | Another lab that answered: what it has that this one does not, and what both have, by checksum |
|
|
74
|
+
| `PeerSilent` | Another lab that did not answer, said without accusing it |
|
|
75
|
+
| `PartsTable`, `WhatASignatureSettles` | The pieces those are made of |
|
|
76
|
+
|
|
77
|
+
They carry the wording as well as the markup. What a signature settles, and what it does not, has to
|
|
78
|
+
be said the same way on every lab's page.
|
|
79
|
+
|
|
80
|
+
Everything else in this package uses hooks and is marked `"use client"`, for frameworks that draw on
|
|
81
|
+
a server first.
|
|
82
|
+
|
|
49
83
|
## Testing
|
|
50
84
|
|
|
51
85
|
`test/panels.test.ts` renders each panel to text against a real lab, and checks that the stylesheet
|
package/dist/freezer.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"freezer.d.ts","sourceRoot":"","sources":["../src/freezer.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"freezer.d.ts","sourceRoot":"","sources":["../src/freezer.tsx"],"names":[],"mappings":"AAEA,wEAAwE;AACxE,OAAO,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAM5D;;;;;GAKG;AACH,eAAO,MAAM,QAAQ,GAAI,MAAM,IAAI,CAAC,SAAS,EAAE,QAAQ,GAAG,MAAM,CAAC,KAAG,MAAsE,CAAC;AAE3I,oGAAoG;AACpG,wBAAgB,OAAO,uCAoBtB;AAED,8BAA8B;AAC9B,wBAAgB,QAAQ,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,EAAE;IAAE,IAAI,EAAE,SAAS,CAAC;IAAC,KAAK,EAAE,SAAS,EAAE,CAAA;CAAE,+BA4BhF;AAED,gEAAgE;AAChE,wBAAgB,OAAO,CAAC,EAAE,IAAI,EAAE,EAAE;IAAE,IAAI,EAAE,SAAS,CAAA;CAAE,+BA4BpD"}
|
package/dist/freezer.js
CHANGED
package/dist/freezer.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"freezer.js","sourceRoot":"","sources":["../src/freezer.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"freezer.js","sourceRoot":"","sources":["../src/freezer.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAIb,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AAEjC,MAAM,KAAK,GAAG,CAAC,IAAc,EAAE,IAAY,EAAU,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC,IAAI,EAAE,CAAC,CAAC;AAEpG;;;;;GAKG;AACH,MAAM,CAAC,MAAM,QAAQ,GAAG,CAAC,IAAwC,EAAU,EAAE,CAAC,GAAG,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,IAAI,KAAK,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,IAAI,CAAC,IAAI,EAAE,EAAE,CAAC;AAE3I,oG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C,EAAE,SAAS,EAAC,WAAW,aAC7G,gBAAO,IAAI,EAAC,QAAQ,EAAC,IAAI,EAAC,QAAQ,EAAC,GAAG,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,WAAW,EAAC,UAAU,EAAC,QAAQ,QAAC,SAAS,EAAC,KAAK,gBAAY,iBAAiB,GAAG,EACnI,iBAAQ,IAAI,EAAC,QAAQ,EAAC,SAAS,EAAC,OAAO,oBAAa,IAChD,GACH,EACL,uBAAI,iBAAQ,IAAI,EAAC,QAAQ,EAAC,SAAS,EAAC,OAAO,EAAC,OAAO,EAAE,GAAG,EAAE,CAAC,KAAK,GAAG,CAAC,QAAQ,EAAE,EAAE,IAAI,EAAE,IAAI,CAAC,IAAI,EAAE,CAAC,uBAAiB,GAAK,IACrH,CACN,CAAC;AACJ,CAAC"}
|
package/dist/history.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"history.d.ts","sourceRoot":"","sources":["../src/history.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"history.d.ts","sourceRoot":"","sources":["../src/history.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AAGjE;;;;;;GAMG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,IAAI,CAAC,SAAS,EAAE,IAAI,CAAC,EAAE,GAAG,EAAE,IAAI,CAAC,OAAO,EAAE,OAAO,GAAG,OAAO,GAAG,QAAQ,CAAC,GAAG,MAAM,CAwBpH;AAED,qGAAqG;AACrG,wBAAgB,OAAO,CAAC,EAAE,KAAU,EAAE,EAAE;IAAE,KAAK,CAAC,EAAE,MAAM,CAAA;CAAE,sCA4BzD"}
|
package/dist/history.js
CHANGED
package/dist/history.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"history.js","sourceRoot":"","sources":["../src/history.tsx"],"names":[],"mappings":"
|
|
1
|
+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CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,GAAG,KAAK,KAAK,CAAC,MAAM,CAAC,EAAE,MAAM,IAAI,SAAS,GAAM,EAClG,uBAAK,aAAa,CAAC,KAAK,EAAE,GAAG,CAAC,GAAM,EACpC,uBAAK,KAAK,CAAC,MAAM,KAAK,SAAS,IAAI,eAAM,SAAS,EAAC,OAAO,EAAC,KAAK,EAAE,KAAK,CAAC,MAAM,IAAI,EAAE,YAAG,KAAK,CAAC,MAAM,GAAQ,GAAM,KAJ1G,KAAK,CAAC,EAAE,CAKZ,CACN,CAAC,GACI,IACF,EACP,CAAC,GAAG,IAAI,MAAM,CAAC,MAAM,GAAG,KAAK,CAAC,MAAM,IAAI,kBAAQ,IAAI,EAAC,QAAQ,EAAC,SAAS,EAAC,OAAO,EAAC,OAAO,EAAE,GAAG,EAAE,CAAC,MAAM,CAAC,IAAI,CAAC,0BAAY,MAAM,CAAC,MAAM,IAAU,IACvI,CACX,CAAC;AACJ,CAAC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -16,6 +16,10 @@
|
|
|
16
16
|
* - `history.tsx` — every signed change, and what became of it
|
|
17
17
|
* - `sharing.tsx` — what other labs are shown, and the lab's web peer
|
|
18
18
|
* - `parts.tsx` — the small pieces they are made of
|
|
19
|
+
* - `public.tsx` — a lab's public page: what it holds, and what it can see of another lab
|
|
20
|
+
*
|
|
21
|
+
* Everything but `public.tsx` uses hooks and is marked `"use client"`, for frameworks that draw on a
|
|
22
|
+
* server first. The public page's pieces take plain values and can be drawn there.
|
|
19
23
|
*/
|
|
20
24
|
export * from "./window.js";
|
|
21
25
|
export * from "./freezer.js";
|
|
@@ -23,4 +27,5 @@ export * from "./people.js";
|
|
|
23
27
|
export * from "./history.js";
|
|
24
28
|
export * from "./sharing.js";
|
|
25
29
|
export * from "./parts.js";
|
|
30
|
+
export * from "./public.js";
|
|
26
31
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,cAAc,CAAC;AAC7B,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -16,6 +16,10 @@
|
|
|
16
16
|
* - `history.tsx` — every signed change, and what became of it
|
|
17
17
|
* - `sharing.tsx` — what other labs are shown, and the lab's web peer
|
|
18
18
|
* - `parts.tsx` — the small pieces they are made of
|
|
19
|
+
* - `public.tsx` — a lab's public page: what it holds, and what it can see of another lab
|
|
20
|
+
*
|
|
21
|
+
* Everything but `public.tsx` uses hooks and is marked `"use client"`, for frameworks that draw on a
|
|
22
|
+
* server first. The public page's pieces take plain values and can be drawn there.
|
|
19
23
|
*/
|
|
20
24
|
export * from "./window.js";
|
|
21
25
|
export * from "./freezer.js";
|
|
@@ -23,4 +27,5 @@ export * from "./people.js";
|
|
|
23
27
|
export * from "./history.js";
|
|
24
28
|
export * from "./sharing.js";
|
|
25
29
|
export * from "./parts.js";
|
|
30
|
+
export * from "./public.js";
|
|
26
31
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,cAAc,CAAC;AAC7B,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC"}
|
package/dist/parts.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"parts.d.ts","sourceRoot":"","sources":["../src/parts.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"parts.d.ts","sourceRoot":"","sources":["../src/parts.tsx"],"names":[],"mappings":"AAEA,+CAA+C;AAC/C,OAAO,EAAuD,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAC5F,OAAO,KAAK,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAGpE,oGAAoG;AACpG,eAAO,MAAM,WAAW,kCAAyB,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAkD,CAAC;AAE5H,qEAAqE;AACrE,wBAAgB,GAAG,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAE,EAAE;IAAE,KAAK,EAAE,CAAC,IAAI,EAAE,QAAQ,KAAK,OAAO,CAAC;QAAE,EAAE,EAAE,OAAO,CAAA;KAAE,CAAC,CAAC;IAAC,QAAQ,EAAE,SAAS,CAAC;IAAC,SAAS,CAAC,EAAE,MAAM,CAAA;CAAE,+BAWnJ;AAED,4DAA4D;AAC5D,wBAAgB,IAAI,CAAC,EAAE,KAAK,EAAE,KAAc,EAAE,EAAE;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,KAAK,CAAC,EAAE,MAAM,CAAA;CAAE,+BAQhF;AAED,qGAAqG;AACrG,wBAAgB,OAAO,uCAItB;AAED;;;;;GAKG;AACH,wBAAgB,SAAS,CAAC,IAAI,EAAE,QAAQ,GAAG,MAAM,CAUhD;AAED,6EAA6E;AAC7E,wBAAgB,UAAU,CAAC,EAAE,IAAI,EAAE,EAAE;IAAE,IAAI,EAAE,QAAQ,CAAA;CAAE,+BAOtD;AAED,iDAAiD;AACjD,wBAAgB,SAAS,CAAC,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,WAAW,CAAC,QAAQ,CAAC,CAAA;CAAE,+BAQtE"}
|
package/dist/parts.js
CHANGED
package/dist/parts.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"parts.js","sourceRoot":"","sources":["../src/parts.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"parts.js","sourceRoot":"","sources":["../src/parts.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAEb,+CAA+C;AAC/C,OAAO,EAAE,aAAa,EAAE,UAAU,EAAE,QAAQ,EAAkC,MAAM,OAAO,CAAC;AAE5F,OAAO,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AAEnD,oGAAoG;AACpG,MAAM,CAAC,MAAM,WAAW,GAAG,aAAa,CAAmC,CAAC,KAAK,EAAE,EAAE,CAAC,SAAS,CAAC,SAAS,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC,CAAC;AAE5H,qEAAqE;AACrE,MAAM,UAAU,GAAG,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAoG;IAClJ,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAC;IACxC,MAAM,MAAM,GAAG,KAAK,EAAE,KAAiC,EAAE,EAAE;QACzD,KAAK,CAAC,cAAc,EAAE,CAAC;QACvB,MAAM,IAAI,GAAG,KAAK,CAAC,aAAa,CAAC;QACjC,OAAO,CAAC,IAAI,CAAC,CAAC;QACd,MAAM,EAAE,EAAE,EAAE,GAAG,MAAM,KAAK,CAAC,IAAI,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC;QAC/C,OAAO,CAAC,KAAK,CAAC,CAAC;QACf,IAAI,EAAE;YAAE,IAAI,CAAC,KAAK,EAAE,CAAC;IACvB,CAAC,CAAC;IACF,OAAO,eAAM,SAAS,EAAE,SAAS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aAAG,SAAS,EAAC,WAAW,6BAAa,yBAAO,MAAM,CAAC,WAAW,GAAQ,oFAAgF,IAClJ,CACP,CAAC;AACJ,CAAC"}
|
package/dist/people.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"people.d.ts","sourceRoot":"","sources":["../src/people.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"people.d.ts","sourceRoot":"","sources":["../src/people.tsx"],"names":[],"mappings":"AAMA,qGAAqG;AACrG,wBAAgB,MAAM,uCA4CrB"}
|
package/dist/people.js
CHANGED
package/dist/people.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"people.js","sourceRoot":"","sources":["../src/people.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"people.js","sourceRoot":"","sources":["../src/people.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAEb,8DAA8D;AAC9D,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;AAEvC,qGAAqG;AACrG,MAAM,UAAU,MAAM;IACpB,MAAM,KAAK,GAAG,MAAM,EAAE,CAAC;IACvB,MAAM,GAAG,GAAG,MAAM,EAAE,CAAC;IACrB,MAAM,GAAG,GAAG,KAAK,EAAE,GAAG,CAAC;IACvB,IAAI,KAAK,KAAK,IAAI,IAAI,GAAG,KAAK,IAAI,IAAI,GAAG,KAAK,SAAS;QAAE,OAAO,IAAI,CAAC;IACrE,OAAO,CACL,8BACE,mBAAS,SAAS,EAAC,MAAM,aACvB,6CAA0B,EAC1B,4BACE,0BAAO,yBAAI,kCAAe,EAAA,gCAAa,EAAA,kCAAe,EAAA,cAAM,IAAK,GAAQ,EACzE,0BACG,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,CACvB,cAAkB,SAAS,EAAE,G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AU,EAAE,KAAK,GAAI,IAAQ,EACrH,0CAAiB,gBAAO,IAAI,EAAC,QAAQ,EAAC,QAAQ,QAAC,SAAS,EAAE,GAAG,GAAI,IAAQ,EACzE,kCAAS,kBAAQ,IAAI,EAAC,MAAM,aAAC,iBAAQ,KAAK,EAAC,QAAQ,qDAA8C,EAAA,iBAAQ,KAAK,EAAC,QAAQ,gEAAyD,IAAS,IAAQ,EACjM,iBAAQ,IAAI,EAAC,QAAQ,+BAAwB,IACzC,EACL,KAAK,CAAC,IAAI,CAAC,MAAM,KAAK,IAAI,CAAC,CAAC,CAAC,CAC5B,eAAK,SAAS,EAAC,QAAQ,aACrB,0BAAK,eAAM,SAAS,EAAC,OAAO,wCAA+B,EAAA,KAAC,IAAI,IAAC,KAAK,EAAE,KAAK,CAAC,IAAI,CAAC,MAAM,EAAE,KAAK,EAAC,iBAAiB,GAAG,IAAM,EAC3H,eAAM,SAAS,EAAC,MAAM,YAAE,KAAK,CAAC,IAAI,CAAC,MAAM,GAAQ,IAC7C,CACP,CAAC,CAAC,CAAC,YAAG,SAAS,EAAC,WAAW,oFAAwE,IAC5F,CACX,CAAC,CAAC,CAAC,YAAG,SAAS,EAAC,WAAW,4DAAgD,IAC3E,CACJ,CAAC;AACJ,CAAC"}
|
package/dist/public.d.ts
ADDED
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* What a lab shows the world, and what it can see of another lab.
|
|
3
|
+
*
|
|
4
|
+
* These are for a lab's public page. They take what was fetched and checked as plain values and
|
|
5
|
+
* draw it; none of them fetches, signs or holds state, so they can be drawn on a server.
|
|
6
|
+
*
|
|
7
|
+
* They also carry the wording. What a signature settles, and what it does not, has to be said the
|
|
8
|
+
* same way on every lab's page — a page that words it itself will sooner or later claim more than
|
|
9
|
+
* the checks support.
|
|
10
|
+
*/
|
|
11
|
+
import type { ReactNode } from "react";
|
|
12
|
+
import { type FetchedInventory, type InventoryPart } from "@biolibs/bionet";
|
|
13
|
+
import type { SignatureCheck } from "@biolibs/opencloning";
|
|
14
|
+
/**
|
|
15
|
+
* The parts in one list whose checksums are not in another.
|
|
16
|
+
*
|
|
17
|
+
* @param mine - What this lab holds.
|
|
18
|
+
* @param theirs - What the other lab holds.
|
|
19
|
+
* @returns What they have that this lab does not. Names play no part: a part is its checksum.
|
|
20
|
+
*/
|
|
21
|
+
export declare function onlyTheirs(mine: readonly InventoryPart[], theirs: readonly InventoryPart[]): InventoryPart[];
|
|
22
|
+
/**
|
|
23
|
+
* The parts two lists both hold, by checksum.
|
|
24
|
+
*
|
|
25
|
+
* @param mine - What this lab holds.
|
|
26
|
+
* @param theirs - What the other lab holds.
|
|
27
|
+
* @returns This lab's entries for the parts both have.
|
|
28
|
+
*/
|
|
29
|
+
export declare function heldByBoth(mine: readonly InventoryPart[], theirs: readonly InventoryPart[]): InventoryPart[];
|
|
30
|
+
/**
|
|
31
|
+
* The frame of a lab's public page: the mark, the lab's name, and a line about what it is.
|
|
32
|
+
*
|
|
33
|
+
* @param props - `name` and `note` are the lab's; `children` is the rest of the page.
|
|
34
|
+
*/
|
|
35
|
+
export declare function LabPage({ name, note, children }: {
|
|
36
|
+
name: string;
|
|
37
|
+
note?: string | null;
|
|
38
|
+
children: ReactNode;
|
|
39
|
+
}): import("react").JSX.Element;
|
|
40
|
+
/** A table of parts: name, length, and whether each is on offer. `checksums` adds that column. */
|
|
41
|
+
export declare function PartsTable({ parts, checksums }: {
|
|
42
|
+
parts: readonly InventoryPart[];
|
|
43
|
+
checksums?: boolean;
|
|
44
|
+
}): import("react").JSX.Element;
|
|
45
|
+
/**
|
|
46
|
+
* What this lab holds, and what the signature over that list settles.
|
|
47
|
+
*
|
|
48
|
+
* @param props - `parts` is the published list; `checks` is one check per signature over it;
|
|
49
|
+
* `origin` is the address this page is served from; `bound` is whether the list names that address.
|
|
50
|
+
*/
|
|
51
|
+
export declare function Held({ parts, checks, origin, bound }: {
|
|
52
|
+
parts: readonly InventoryPart[];
|
|
53
|
+
checks: readonly SignatureCheck[];
|
|
54
|
+
origin: string;
|
|
55
|
+
bound: boolean;
|
|
56
|
+
}): import("react").JSX.Element;
|
|
57
|
+
/** The caveat every reader is owed, in the same words everywhere. */
|
|
58
|
+
export declare function WhatASignatureSettles(): import("react").JSX.Element;
|
|
59
|
+
/**
|
|
60
|
+
* Another lab that answered, beside what this lab holds.
|
|
61
|
+
*
|
|
62
|
+
* @param props - `found` is what was fetched from the other lab and checked; `mine` is this lab's list.
|
|
63
|
+
*/
|
|
64
|
+
export declare function PeerAnswered({ found, mine }: {
|
|
65
|
+
found: FetchedInventory;
|
|
66
|
+
mine: readonly InventoryPart[];
|
|
67
|
+
}): import("react").JSX.Element;
|
|
68
|
+
/**
|
|
69
|
+
* Another lab that did not answer.
|
|
70
|
+
*
|
|
71
|
+
* @param props - `address` is where it was asked for; `why` is what went wrong.
|
|
72
|
+
*/
|
|
73
|
+
export declare function PeerSilent({ address, why }: {
|
|
74
|
+
address: string;
|
|
75
|
+
why: string;
|
|
76
|
+
}): import("react").JSX.Element;
|
|
77
|
+
//# sourceMappingURL=public.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"public.d.ts","sourceRoot":"","sources":["../src/public.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AACvC,OAAO,EAAW,KAAK,gBAAgB,EAAE,KAAK,aAAa,EAAE,MAAM,iBAAiB,CAAC;AACrF,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAG3D;;;;;;GAMG;AACH,wBAAgB,UAAU,CAAC,IAAI,EAAE,SAAS,aAAa,EAAE,EAAE,MAAM,EAAE,SAAS,aAAa,EAAE,GAAG,aAAa,EAAE,CAG5G;AAED;;;;;;GAMG;AACH,wBAAgB,UAAU,CAAC,IAAI,EAAE,SAAS,aAAa,EAAE,EAAE,MAAM,EAAE,SAAS,aAAa,EAAE,GAAG,aAAa,EAAE,CAG5G;AAED;;;;GAIG;AACH,wBAAgB,OAAO,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAAC,QAAQ,EAAE,SAAS,CAAA;CAAE,+BAmB5G;AAED,kGAAkG;AAClG,wBAAgB,UAAU,CAAC,EAAE,KAAK,EAAE,SAAiB,EAAE,EAAE;IAAE,KAAK,EAAE,SAAS,aAAa,EAAE,CAAC;IAAC,SAAS,CAAC,EAAE,OAAO,CAAA;CAAE,+BAgBhH;AAED;;;;;GAKG;AACH,wBAAgB,IAAI,CAAC,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE;IACrD,KAAK,EAAE,SAAS,aAAa,EAAE,CAAC;IAAC,MAAM,EAAE,SAAS,cAAc,EAAE,CAAC;IAAC,MAAM,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,OAAO,CAAC;CACpG,+BAiBA;AAED,qEAAqE;AACrE,wBAAgB,qBAAqB,gCAQpC;AAED;;;;GAIG;AACH,wBAAgB,YAAY,CAAC,EAAE,KAAK,EAAE,IAAI,EAAE,EAAE;IAAE,KAAK,EAAE,gBAAgB,CAAC;IAAC,IAAI,EAAE,SAAS,aAAa,EAAE,CAAA;CAAE,+BA6BxG;AAED;;;;GAIG;AACH,wBAAgB,UAAU,CAAC,EAAE,OAAO,EAAE,GAAG,EAAE,EAAE;IAAE,OAAO,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,MAAM,CAAA;CAAE,+BAW5E"}
|
package/dist/public.js
ADDED
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
+
import { settled } from "@biolibs/bionet";
|
|
3
|
+
import { Mark } from "@biolibs/bionet-react";
|
|
4
|
+
/**
|
|
5
|
+
* The parts in one list whose checksums are not in another.
|
|
6
|
+
*
|
|
7
|
+
* @param mine - What this lab holds.
|
|
8
|
+
* @param theirs - What the other lab holds.
|
|
9
|
+
* @returns What they have that this lab does not. Names play no part: a part is its checksum.
|
|
10
|
+
*/
|
|
11
|
+
export function onlyTheirs(mine, theirs) {
|
|
12
|
+
const have = new Set(mine.map((part) => part.checksum));
|
|
13
|
+
return theirs.filter((part) => !have.has(part.checksum));
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* The parts two lists both hold, by checksum.
|
|
17
|
+
*
|
|
18
|
+
* @param mine - What this lab holds.
|
|
19
|
+
* @param theirs - What the other lab holds.
|
|
20
|
+
* @returns This lab's entries for the parts both have.
|
|
21
|
+
*/
|
|
22
|
+
export function heldByBoth(mine, theirs) {
|
|
23
|
+
const have = new Set(theirs.map((part) => part.checksum));
|
|
24
|
+
return mine.filter((part) => have.has(part.checksum));
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* The frame of a lab's public page: the mark, the lab's name, and a line about what it is.
|
|
28
|
+
*
|
|
29
|
+
* @param props - `name` and `note` are the lab's; `children` is the rest of the page.
|
|
30
|
+
*/
|
|
31
|
+
export function LabPage({ name, note, children }) {
|
|
32
|
+
return (_jsx("div", { className: "bionet", children: _jsxs("main", { className: "page", children: [_jsxs("div", { className: "title", children: [_jsx(Mark, { size: 40 }), _jsx("h1", { children: name })] }), note !== null && note !== undefined && _jsx("p", { className: "dim", children: note }), _jsxs("p", { className: "small dim", children: ["This lab publishes what it holds at", " ", _jsx("a", { href: "/.well-known/bionet.json", children: _jsx("code", { children: "/.well-known/bionet.json" }) }), ", signed, so that a cloning plan can be acted on and not just read. Parts are named by checksum, because a name agrees with nothing."] }), children] }) }));
|
|
33
|
+
}
|
|
34
|
+
/** A table of parts: name, length, and whether each is on offer. `checksums` adds that column. */
|
|
35
|
+
export function PartsTable({ parts, checksums = false }) {
|
|
36
|
+
return (_jsxs("table", { children: [_jsx("thead", { children: _jsxs("tr", { children: [_jsx("th", { children: "Part" }), _jsx("th", { children: "Length" }), checksums && _jsx("th", { children: "Checksum" }), _jsx("th", { children: "On offer" })] }) }), _jsx("tbody", { children: parts.map((part) => (_jsxs("tr", { children: [_jsxs("td", { children: [part.name, part.note !== null && _jsxs(_Fragment, { children: [_jsx("br", {}), _jsx("span", { className: "dim small", children: part.note })] })] }), _jsx("td", { className: "nowrap", children: _jsxs("code", { children: [part.length, " bp", part.circular ? " ○" : ""] }) }), checksums && _jsx("td", { className: "dim", children: _jsxs("code", { children: [part.checksum.slice(0, 22), "\u2026"] }) }), _jsx("td", { className: part.available ? "good" : "bad", children: part.available ? "yes" : "no" })] }, part.checksum))) })] }));
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* What this lab holds, and what the signature over that list settles.
|
|
40
|
+
*
|
|
41
|
+
* @param props - `parts` is the published list; `checks` is one check per signature over it;
|
|
42
|
+
* `origin` is the address this page is served from; `bound` is whether the list names that address.
|
|
43
|
+
*/
|
|
44
|
+
export function Held({ parts, checks, origin, bound }) {
|
|
45
|
+
const holds = checks.length > 0 && checks.every((check) => check.ok);
|
|
46
|
+
return (_jsxs("section", { children: [_jsx("h2", { children: "What we hold" }), parts.length === 0 ? _jsx("p", { className: "dim", children: "Nothing is listed at the moment." }) : _jsx(PartsTable, { parts: parts, checksums: true }), _jsxs("p", { className: "small dim", children: [checks.length === 0 ? "This list is not signed, so it claims nothing about who published it." : (_jsxs(_Fragment, { children: ["Signed by ", checks.map((check) => _jsxs("code", { children: [check.fingerprint, " "] }, check.public_key)), holds ? "— the signature holds over this list as served." : "— the signature does not hold."] })), " ", "Bound to ", _jsx("code", { children: origin }), ": ", bound ? "yes" : "no", "."] })] }));
|
|
47
|
+
}
|
|
48
|
+
/** The caveat every reader is owed, in the same words everywhere. */
|
|
49
|
+
export function WhatASignatureSettles() {
|
|
50
|
+
return (_jsx("p", { className: "small dim", children: "None of that says this lab is who it says it is. The address does that work, and only as far as whoever typed it already trusted it. What a signature settles is that this list has not changed since it was published, and that it was published by whoever holds that key." }));
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* Another lab that answered, beside what this lab holds.
|
|
54
|
+
*
|
|
55
|
+
* @param props - `found` is what was fetched from the other lab and checked; `mine` is this lab's list.
|
|
56
|
+
*/
|
|
57
|
+
export function PeerAnswered({ found, mine }) {
|
|
58
|
+
const theirs = found.signed.inventory.parts;
|
|
59
|
+
const only = onlyTheirs(mine, theirs);
|
|
60
|
+
const both = heldByBoth(mine, theirs);
|
|
61
|
+
return (_jsxs(_Fragment, { children: [_jsxs("p", { children: [_jsx("strong", { children: found.signed.inventory.lab.name }), " answered at ", _jsx("code", { children: found.origin }), " with", " ", theirs.length, " ", theirs.length === 1 ? "part" : "parts", ".", " ", settled(found)
|
|
62
|
+
? _jsx("span", { className: "good", children: "Its signature holds and it was served from the address it names." })
|
|
63
|
+
: _jsx("span", { className: "bad", children: "Its signature or its address does not check out, so nothing below is settled." })] }), _jsx(WhatASignatureSettles, {}), _jsx("h3", { children: "What they have that we do not" }), only.length === 0 ? _jsx("p", { className: "small", children: "Nothing. Everything they list, we hold too." }) : _jsx(PartsTable, { parts: only }), _jsx("h3", { children: "What we both have" }), both.length === 0 ? _jsx("p", { className: "small", children: "Nothing in common, by checksum." }) : (_jsxs("p", { className: "small", children: [both.map((part) => _jsxs("code", { children: [part.name, " "] }, part.checksum)), "\u2014 matched by checksum, so it does not matter what either of us calls them."] })), _jsx("p", { className: "small dim", children: "Fetched from that lab when this page was drawn, not copied. Nothing here fetches a part: finding out who has a plasmid is as far as software goes, and the rest is an email and a padded envelope." })] }));
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* Another lab that did not answer.
|
|
67
|
+
*
|
|
68
|
+
* @param props - `address` is where it was asked for; `why` is what went wrong.
|
|
69
|
+
*/
|
|
70
|
+
export function PeerSilent({ address, why }) {
|
|
71
|
+
return (_jsxs(_Fragment, { children: [_jsxs("p", { children: ["We point at ", _jsx("code", { children: address }), " and it did not answer."] }), _jsxs("p", { className: "small dim", children: ["The reason given was: ", why, ". A lab that cannot be reached is not a lab that is lying \u2014 it may be down, or moved, or never have existed. All this page can honestly say is that the address did not answer when it was asked."] })] }));
|
|
72
|
+
}
|
|
73
|
+
//# sourceMappingURL=public.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"public.js","sourceRoot":"","sources":["../src/public.tsx"],"names":[],"mappings":";AAWA,OAAO,EAAE,OAAO,EAA6C,MAAM,iBAAiB,CAAC;AAErF,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAE7C;;;;;;GAMG;AACH,MAAM,UAAU,UAAU,CAAC,IAA8B,EAAE,MAAgC;IACzF,MAAM,IAAI,GAAG,IAAI,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC;IACxD,OAAO,MAAM,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC;AAC3D,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,UAAU,CAAC,IAA8B,EAAE,MAAgC;IACzF,MAAM,IAAI,GAAG,IAAI,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC;IAC1D,OAAO,IAAI,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC;AACxD,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,OAAO,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,QAAQ,EAA+D;IAC3G,OAAO,CACL,cAAK,SAAS,EAAC,QAAQ,YACrB,gBAAM,SAA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G,SAAS,EAAC,WAAW,uCACC,GAAG,8MAGxB,IACH,CACJ,CAAC;AACJ,CAAC"}
|
package/dist/sharing.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sharing.d.ts","sourceRoot":"","sources":["../src/sharing.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"sharing.d.ts","sourceRoot":"","sources":["../src/sharing.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAI5D;;;;;;GAMG;AACH,wBAAgB,WAAW,CAAC,KAAK,EAAE,SAAS,SAAS,EAAE,EAAE,KAAK,EAAE,SAAS,SAAS,EAAE,GAAG,SAAS,EAAE,CAGjG;AAED,yHAAyH;AACzH,wBAAgB,OAAO,uCAiDtB"}
|
package/dist/sharing.js
CHANGED
package/dist/sharing.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sharing.js","sourceRoot":"","sources":["../src/sharing.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"sharing.js","sourceRoot":"","sources":["../src/sharing.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAEb,kEAAkE;AAClE,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAEjC,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;AAEvC;;;;;;GAMG;AACH,MAAM,UAAU,WAAW,CAAC,KAA2B,EAAE,KAA2B;IAClF,MAAM,OAAO,GAAG,IAAI,GAAG,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC,OAAO,IAAI,IAAI,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IA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G,IAAC,KAAK,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,GAAG,CAAC,SAAS,EAAE,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC,CAAC,EAAE,SAAS,EAAC,KAAK,aACnF,gBAAO,IAAI,EAAC,MAAM,EAAC,WAAW,EAAC,6BAA6B,EAAC,YAAY,EAAE,KAAK,CAAC,IAAI,CAAC,GAAG,IAAI,EAAE,EAAE,UAAU,EAAE,KAAK,GAAI,EACtH,iBAAQ,IAAI,EAAC,QAAQ,EAAC,SAAS,EAAC,OAAO,8BAAuB,IAC1D,EACL,KAAK,CAAC,IAAI,CAAC,OAAO,KAAK,IAAI,IAAI,YAAG,SAAS,EAAC,MAAM,YAAE,KAAK,CAAC,IAAI,CAAC,OAAO,GAAK,EAC5E,eAAK,SAAS,EAAC,QAAQ,aACrB,0BAAK,eAAM,SAAS,EAAC,OAAO,8BAAqB,EAAC,GAAG,CAAC,EAAE,KAAK,IAAI,IAAI,KAAC,IAAI,IAAC,KAAK,EAAE,GAAG,CAAC,EAAE,EAAE,KAAK,EAAC,SAAS,GAAG,IAAO,EACnH,eAAM,SAAS,EAAC,MAAM,YAAE,GAAG,CAAC,EAAE,GAAQ,EACtC,aAAG,SAAS,EAAC,WAAW,0DAA0C,wCAAuB,kDAA8C,IACnI,IACE,IACT,CACJ,CAAC;AACJ,CAAC"}
|
package/dist/window.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"window.d.ts","sourceRoot":"","sources":["../src/window.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"window.d.ts","sourceRoot":"","sources":["../src/window.tsx"],"names":[],"mappings":"AAoBA,yCAAyC;AACzC,eAAO,MAAM,IAAI,sDAAuD,CAAC;AAEzE,mBAAmB;AACnB,MAAM,MAAM,GAAG,GAAG,CAAC,OAAO,IAAI,CAAC,CAAC,MAAM,CAAC,CAAC;AAExC;;;;;GAKG;AACH,wBAAgB,SAAS,CAAC,EAAE,GAAG,EAAE,KAAiB,EAAE,IAAI,EAAE,EAAE;IAAE,GAAG,CAAC,EAAE,GAAG,CAAC;IAAC,IAAI,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAA;CAAE,+BAGjH;AA2CD,0DAA0D;AAC1D,wBAAgB,GAAG,gCAYlB;AAED,sCAAsC;AACtC,wBAAgB,KAAK,uCA0BpB;AAED,+CAA+C;AAC/C,wBAAgB,OAAO,uCAYtB"}
|
package/dist/window.js
CHANGED
package/dist/window.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"window.js","sourceRoot":"","sources":["../src/window.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"window.js","sourceRoot":"","sources":["../src/window.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAEb;;;;;;;;;GASG;AACH,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACjC,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,uBAAuB,CAAC;AACnE,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,GAAG,EAAE,WAAW,EAAE,SAAS,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AAC9E,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAEvC,yCAAyC;AACzC,MAAM,CAAC,MAAM,IAAI,GAAG,CAAC,SAAS,EAAE,QAAQ,EAAE,SAAS,EAAE,SAAS,CAAU,CAAC;AAKzE;;;;;GAKG;AACH,MAAM,UAAU,SAAS,CAAC,EAAE,GAAG,EAAE,KAAK,GAAG,SAAS,EAAE,IAAI,EAA0D;IAChH,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|
package/package.json
CHANGED
|
@@ -5,7 +5,8 @@
|
|
|
5
5
|
"dependencies": {
|
|
6
6
|
"@biolibs/bionet": "^1.2.0",
|
|
7
7
|
"@biolibs/bionet-client": "^0.1.0",
|
|
8
|
-
"@biolibs/bionet-react": "^0.1.
|
|
8
|
+
"@biolibs/bionet-react": "^0.1.1",
|
|
9
|
+
"@biolibs/opencloning": "^2.0.0"
|
|
9
10
|
},
|
|
10
11
|
"description": "The parts of a Bionet lab application, ready to place: the freezer, the people, the history, what other labs are shown, and a whole window that puts them together, in a light theme and a dark one",
|
|
11
12
|
"engines": {
|
|
@@ -52,5 +53,5 @@
|
|
|
52
53
|
],
|
|
53
54
|
"type": "module",
|
|
54
55
|
"types": "dist/index.d.ts",
|
|
55
|
-
"version": "0.
|
|
56
|
+
"version": "0.2.0"
|
|
56
57
|
}
|
package/panels.css
CHANGED
|
@@ -53,3 +53,9 @@
|
|
|
53
53
|
.bionet .dot.waiting { background: var(--bionet-held) }
|
|
54
54
|
.bionet .trouble { background: color-mix(in srgb, var(--bionet-attention) 12%, transparent); border: 1px solid var(--bionet-attention); border-radius: 8px; padding: .55rem .8rem; display: flex; justify-content: space-between; gap: 1rem }
|
|
55
55
|
.bionet .note { border-left: 3px solid var(--bionet-held); padding: .1rem 0 .1rem .7rem; font-size: .9rem }
|
|
56
|
+
.bionet h3 { font-size: .92rem; margin: 1.2rem 0 .3rem }
|
|
57
|
+
.bionet a { color: inherit; text-decoration-color: var(--bionet-dim); text-underline-offset: 2px }
|
|
58
|
+
.bionet .good { color: var(--bionet-good) } .bionet .bad { color: var(--bionet-attention) }
|
|
59
|
+
.bionet main.page { max-width: 46rem; margin: 0 auto; padding: 3rem 1.25rem 6rem; overflow: visible; font-size: 15px; line-height: 1.65 }
|
|
60
|
+
.bionet main.page .title { margin-bottom: .6rem } .bionet main.page h1 { font-size: 1.6rem }
|
|
61
|
+
.bionet main.page h2 { font-size: 1.1rem; margin: 2.4rem 0 .6rem; padding-bottom: .3rem; border-bottom: 1px solid var(--bionet-rule) }
|
package/src/freezer.tsx
CHANGED
package/src/history.tsx
CHANGED
package/src/index.ts
CHANGED
|
@@ -16,6 +16,10 @@
|
|
|
16
16
|
* - `history.tsx` — every signed change, and what became of it
|
|
17
17
|
* - `sharing.tsx` — what other labs are shown, and the lab's web peer
|
|
18
18
|
* - `parts.tsx` — the small pieces they are made of
|
|
19
|
+
* - `public.tsx` — a lab's public page: what it holds, and what it can see of another lab
|
|
20
|
+
*
|
|
21
|
+
* Everything but `public.tsx` uses hooks and is marked `"use client"`, for frameworks that draw on a
|
|
22
|
+
* server first. The public page's pieces take plain values and can be drawn there.
|
|
19
23
|
*/
|
|
20
24
|
export * from "./window.js";
|
|
21
25
|
export * from "./freezer.js";
|
|
@@ -23,3 +27,4 @@ export * from "./people.js";
|
|
|
23
27
|
export * from "./history.js";
|
|
24
28
|
export * from "./sharing.js";
|
|
25
29
|
export * from "./parts.js";
|
|
30
|
+
export * from "./public.js";
|
package/src/parts.tsx
CHANGED
package/src/people.tsx
CHANGED
package/src/public.tsx
ADDED
|
@@ -0,0 +1,175 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* What a lab shows the world, and what it can see of another lab.
|
|
3
|
+
*
|
|
4
|
+
* These are for a lab's public page. They take what was fetched and checked as plain values and
|
|
5
|
+
* draw it; none of them fetches, signs or holds state, so they can be drawn on a server.
|
|
6
|
+
*
|
|
7
|
+
* They also carry the wording. What a signature settles, and what it does not, has to be said the
|
|
8
|
+
* same way on every lab's page — a page that words it itself will sooner or later claim more than
|
|
9
|
+
* the checks support.
|
|
10
|
+
*/
|
|
11
|
+
import type { ReactNode } from "react";
|
|
12
|
+
import { settled, type FetchedInventory, type InventoryPart } from "@biolibs/bionet";
|
|
13
|
+
import type { SignatureCheck } from "@biolibs/opencloning";
|
|
14
|
+
import { Mark } from "@biolibs/bionet-react";
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* The parts in one list whose checksums are not in another.
|
|
18
|
+
*
|
|
19
|
+
* @param mine - What this lab holds.
|
|
20
|
+
* @param theirs - What the other lab holds.
|
|
21
|
+
* @returns What they have that this lab does not. Names play no part: a part is its checksum.
|
|
22
|
+
*/
|
|
23
|
+
export function onlyTheirs(mine: readonly InventoryPart[], theirs: readonly InventoryPart[]): InventoryPart[] {
|
|
24
|
+
const have = new Set(mine.map((part) => part.checksum));
|
|
25
|
+
return theirs.filter((part) => !have.has(part.checksum));
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
/**
|
|
29
|
+
* The parts two lists both hold, by checksum.
|
|
30
|
+
*
|
|
31
|
+
* @param mine - What this lab holds.
|
|
32
|
+
* @param theirs - What the other lab holds.
|
|
33
|
+
* @returns This lab's entries for the parts both have.
|
|
34
|
+
*/
|
|
35
|
+
export function heldByBoth(mine: readonly InventoryPart[], theirs: readonly InventoryPart[]): InventoryPart[] {
|
|
36
|
+
const have = new Set(theirs.map((part) => part.checksum));
|
|
37
|
+
return mine.filter((part) => have.has(part.checksum));
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
/**
|
|
41
|
+
* The frame of a lab's public page: the mark, the lab's name, and a line about what it is.
|
|
42
|
+
*
|
|
43
|
+
* @param props - `name` and `note` are the lab's; `children` is the rest of the page.
|
|
44
|
+
*/
|
|
45
|
+
export function LabPage({ name, note, children }: { name: string; note?: string | null; children: ReactNode }) {
|
|
46
|
+
return (
|
|
47
|
+
<div className="bionet">
|
|
48
|
+
<main className="page">
|
|
49
|
+
<div className="title">
|
|
50
|
+
<Mark size={40} />
|
|
51
|
+
<h1>{name}</h1>
|
|
52
|
+
</div>
|
|
53
|
+
{note !== null && note !== undefined && <p className="dim">{note}</p>}
|
|
54
|
+
<p className="small dim">
|
|
55
|
+
This lab publishes what it holds at{" "}
|
|
56
|
+
<a href="/.well-known/bionet.json"><code>/.well-known/bionet.json</code></a>, signed, so that a
|
|
57
|
+
cloning plan can be acted on and not just read. Parts are named by checksum, because a name
|
|
58
|
+
agrees with nothing.
|
|
59
|
+
</p>
|
|
60
|
+
{children}
|
|
61
|
+
</main>
|
|
62
|
+
</div>
|
|
63
|
+
);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
/** A table of parts: name, length, and whether each is on offer. `checksums` adds that column. */
|
|
67
|
+
export function PartsTable({ parts, checksums = false }: { parts: readonly InventoryPart[]; checksums?: boolean }) {
|
|
68
|
+
return (
|
|
69
|
+
<table>
|
|
70
|
+
<thead><tr><th>Part</th><th>Length</th>{checksums && <th>Checksum</th>}<th>On offer</th></tr></thead>
|
|
71
|
+
<tbody>
|
|
72
|
+
{parts.map((part) => (
|
|
73
|
+
<tr key={part.checksum}>
|
|
74
|
+
<td>{part.name}{part.note !== null && <><br /><span className="dim small">{part.note}</span></>}</td>
|
|
75
|
+
<td className="nowrap"><code>{part.length} bp{part.circular ? " ○" : ""}</code></td>
|
|
76
|
+
{checksums && <td className="dim"><code>{part.checksum.slice(0, 22)}…</code></td>}
|
|
77
|
+
<td className={part.available ? "good" : "bad"}>{part.available ? "yes" : "no"}</td>
|
|
78
|
+
</tr>
|
|
79
|
+
))}
|
|
80
|
+
</tbody>
|
|
81
|
+
</table>
|
|
82
|
+
);
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
/**
|
|
86
|
+
* What this lab holds, and what the signature over that list settles.
|
|
87
|
+
*
|
|
88
|
+
* @param props - `parts` is the published list; `checks` is one check per signature over it;
|
|
89
|
+
* `origin` is the address this page is served from; `bound` is whether the list names that address.
|
|
90
|
+
*/
|
|
91
|
+
export function Held({ parts, checks, origin, bound }: {
|
|
92
|
+
parts: readonly InventoryPart[]; checks: readonly SignatureCheck[]; origin: string; bound: boolean;
|
|
93
|
+
}) {
|
|
94
|
+
const holds = checks.length > 0 && checks.every((check) => check.ok);
|
|
95
|
+
return (
|
|
96
|
+
<section>
|
|
97
|
+
<h2>What we hold</h2>
|
|
98
|
+
{parts.length === 0 ? <p className="dim">Nothing is listed at the moment.</p> : <PartsTable parts={parts} checksums />}
|
|
99
|
+
<p className="small dim">
|
|
100
|
+
{checks.length === 0 ? "This list is not signed, so it claims nothing about who published it." : (
|
|
101
|
+
<>
|
|
102
|
+
Signed by {checks.map((check) => <code key={check.public_key}>{check.fingerprint} </code>)}
|
|
103
|
+
{holds ? "— the signature holds over this list as served." : "— the signature does not hold."}
|
|
104
|
+
</>
|
|
105
|
+
)}{" "}
|
|
106
|
+
Bound to <code>{origin}</code>: {bound ? "yes" : "no"}.
|
|
107
|
+
</p>
|
|
108
|
+
</section>
|
|
109
|
+
);
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
/** The caveat every reader is owed, in the same words everywhere. */
|
|
113
|
+
export function WhatASignatureSettles() {
|
|
114
|
+
return (
|
|
115
|
+
<p className="small dim">
|
|
116
|
+
None of that says this lab is who it says it is. The address does that work, and only as far as
|
|
117
|
+
whoever typed it already trusted it. What a signature settles is that this list has not changed
|
|
118
|
+
since it was published, and that it was published by whoever holds that key.
|
|
119
|
+
</p>
|
|
120
|
+
);
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
/**
|
|
124
|
+
* Another lab that answered, beside what this lab holds.
|
|
125
|
+
*
|
|
126
|
+
* @param props - `found` is what was fetched from the other lab and checked; `mine` is this lab's list.
|
|
127
|
+
*/
|
|
128
|
+
export function PeerAnswered({ found, mine }: { found: FetchedInventory; mine: readonly InventoryPart[] }) {
|
|
129
|
+
const theirs = found.signed.inventory.parts;
|
|
130
|
+
const only = onlyTheirs(mine, theirs);
|
|
131
|
+
const both = heldByBoth(mine, theirs);
|
|
132
|
+
return (
|
|
133
|
+
<>
|
|
134
|
+
<p>
|
|
135
|
+
<strong>{found.signed.inventory.lab.name}</strong> answered at <code>{found.origin}</code> with{" "}
|
|
136
|
+
{theirs.length} {theirs.length === 1 ? "part" : "parts"}.{" "}
|
|
137
|
+
{settled(found)
|
|
138
|
+
? <span className="good">Its signature holds and it was served from the address it names.</span>
|
|
139
|
+
: <span className="bad">Its signature or its address does not check out, so nothing below is settled.</span>}
|
|
140
|
+
</p>
|
|
141
|
+
<WhatASignatureSettles />
|
|
142
|
+
<h3>What they have that we do not</h3>
|
|
143
|
+
{only.length === 0 ? <p className="small">Nothing. Everything they list, we hold too.</p> : <PartsTable parts={only} />}
|
|
144
|
+
<h3>What we both have</h3>
|
|
145
|
+
{both.length === 0 ? <p className="small">Nothing in common, by checksum.</p> : (
|
|
146
|
+
<p className="small">
|
|
147
|
+
{both.map((part) => <code key={part.checksum}>{part.name} </code>)}
|
|
148
|
+
— matched by checksum, so it does not matter what either of us calls them.
|
|
149
|
+
</p>
|
|
150
|
+
)}
|
|
151
|
+
<p className="small dim">
|
|
152
|
+
Fetched from that lab when this page was drawn, not copied. Nothing here fetches a part: finding
|
|
153
|
+
out who has a plasmid is as far as software goes, and the rest is an email and a padded envelope.
|
|
154
|
+
</p>
|
|
155
|
+
</>
|
|
156
|
+
);
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
/**
|
|
160
|
+
* Another lab that did not answer.
|
|
161
|
+
*
|
|
162
|
+
* @param props - `address` is where it was asked for; `why` is what went wrong.
|
|
163
|
+
*/
|
|
164
|
+
export function PeerSilent({ address, why }: { address: string; why: string }) {
|
|
165
|
+
return (
|
|
166
|
+
<>
|
|
167
|
+
<p>We point at <code>{address}</code> and it did not answer.</p>
|
|
168
|
+
<p className="small dim">
|
|
169
|
+
The reason given was: {why}. A lab that cannot be reached is not a lab that is lying — it may be
|
|
170
|
+
down, or moved, or never have existed. All this page can honestly say is that the address did
|
|
171
|
+
not answer when it was asked.
|
|
172
|
+
</p>
|
|
173
|
+
</>
|
|
174
|
+
);
|
|
175
|
+
}
|
package/src/sharing.tsx
CHANGED