@seed-hypermedia/client 0.0.74 → 0.0.76

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.
@@ -4,13 +4,13 @@ import {
4
4
  documentContainsLinkToChild,
5
5
  documentHasSelfQuery,
6
6
  shouldAutoLinkParent
7
- } from "./chunk-F5IDLVWW.mjs";
7
+ } from "./chunk-E2S3ZLBH.mjs";
8
8
  import "./chunk-JT57MV7Y.mjs";
9
9
  import "./chunk-PJ2RFT5A.mjs";
10
- import "./chunk-RFDFZV7U.mjs";
10
+ import "./chunk-YYQPNBQK.mjs";
11
11
  import "./chunk-LVAHHQIK.mjs";
12
12
  import "./chunk-DR3HJ6BV.mjs";
13
- import "./chunk-BXEZSVNI.mjs";
13
+ import "./chunk-EGDF5YHG.mjs";
14
14
  import "./chunk-7P6ASYW6.mjs";
15
15
  export {
16
16
  autoLinkChildToParent,
@@ -7,8 +7,8 @@ import {
7
7
  emitFrontmatter,
8
8
  parseDraftFilename,
9
9
  slugify
10
- } from "./chunk-344BPFU7.mjs";
11
- import "./chunk-BXEZSVNI.mjs";
10
+ } from "./chunk-7UUGEBS3.mjs";
11
+ import "./chunk-EGDF5YHG.mjs";
12
12
  import "./chunk-7P6ASYW6.mjs";
13
13
  export {
14
14
  blocksToMarkdown,
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  createCapability,
3
3
  resolveCapability
4
- } from "./chunk-5GJCMBPK.mjs";
4
+ } from "./chunk-3NKBUTZO.mjs";
5
5
  import "./chunk-LVAHHQIK.mjs";
6
6
  import "./chunk-IT5LLTMP.mjs";
7
7
  import "./chunk-DR3HJ6BV.mjs";
8
- import "./chunk-BXEZSVNI.mjs";
8
+ import "./chunk-EGDF5YHG.mjs";
9
9
  import "./chunk-3TPCJCVO.mjs";
10
10
  import "./chunk-7P6ASYW6.mjs";
11
11
  export {
@@ -7,7 +7,7 @@ import {
7
7
  import {
8
8
  entityQueryPathToHmIdPath,
9
9
  packBaseId
10
- } from "./chunk-BXEZSVNI.mjs";
10
+ } from "./chunk-EGDF5YHG.mjs";
11
11
 
12
12
  // src/capability.ts
13
13
  import { base58btc } from "multiformats/bases/base58";
@@ -6,7 +6,7 @@ import {
6
6
  HMBlockSchema,
7
7
  codePointLength,
8
8
  toNumber
9
- } from "./chunk-BXEZSVNI.mjs";
9
+ } from "./chunk-EGDF5YHG.mjs";
10
10
 
11
11
  // src/editorblock-to-hmblock.ts
12
12
  function toHMBlockType(editorBlockType) {
@@ -15,7 +15,7 @@ import {
15
15
  HMActionSchema,
16
16
  HMRequestSchema,
17
17
  packHmId
18
- } from "./chunk-BXEZSVNI.mjs";
18
+ } from "./chunk-EGDF5YHG.mjs";
19
19
 
20
20
  // src/client.ts
21
21
  import { encode as cborEncode } from "@ipld/dag-cbor";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  unpackHmId
3
- } from "./chunk-BXEZSVNI.mjs";
3
+ } from "./chunk-EGDF5YHG.mjs";
4
4
 
5
5
  // src/blocks-to-markdown.ts
6
6
  var FM_STRING_KEYS = [
@@ -7,12 +7,12 @@ import {
7
7
  } from "./chunk-PJ2RFT5A.mjs";
8
8
  import {
9
9
  resolveDocumentState
10
- } from "./chunk-RFDFZV7U.mjs";
10
+ } from "./chunk-YYQPNBQK.mjs";
11
11
  import {
12
12
  entityQueryPathToHmIdPath,
13
13
  packHmId,
14
14
  unpackHmId
15
- } from "./chunk-BXEZSVNI.mjs";
15
+ } from "./chunk-EGDF5YHG.mjs";
16
16
 
17
17
  // src/auto-link.ts
18
18
  import { CID } from "multiformats/cid";
@@ -273,6 +273,21 @@ var HMDocumentMetadataSchema = z.object({
273
273
  * agents for its audience — on the gateway, each site brings its own agents backend.
274
274
  */
275
275
  agentServerUrl: z.string().optional(),
276
+ /**
277
+ * Agents this space publishes to its readers: `{[agentId]: order}`, where each id names an agent
278
+ * on {@link agentServerUrl} and the number is its position in the picker.
279
+ *
280
+ * This is what makes a space's agents reachable by someone who just arrived: an agent server
281
+ * only ever lists agents you own or collaborate on, so a reader cannot discover them by asking.
282
+ * Named here, the client fetches each one by id, which the server serves to any signed account
283
+ * once the agent is public-read.
284
+ *
285
+ * Only ids and order live here — an agent's name and icon are read from the agent itself, so
286
+ * renaming one never strands a stale copy in a signed document. Values are typed loosely
287
+ * because removal leaves a null attribute behind rather than dropping the key; `parseSpaceAgentIds`
288
+ * in @shm/ui/agents/space-agents is the reader for this field.
289
+ */
290
+ spaceAgents: z.record(z.unknown()).optional(),
276
291
  layout: z.union([z.literal("Seed/Experimental/Newspaper"), z.literal("")]).optional(),
277
292
  displayPublishTime: z.string().optional(),
278
293
  displayAuthor: z.string().optional(),
@@ -307,17 +322,18 @@ var DOCUMENT_ATTRIBUTE_DESCRIPTIONS = {
307
322
  cover: "Wide cover image shown in headers and cards.",
308
323
  siteUrl: "Published website URL for a space.",
309
324
  agentServerUrl: "Agents server readers of this space connect to.",
310
- layout: "Legacy site header layout setting.",
325
+ spaceAgents: "Agents this space publishes to its readers, by id and order.",
326
+ layout: "Legacy space header layout setting.",
311
327
  displayPublishTime: "Publication date shown to readers.",
312
328
  displayAuthor: "Author byline shown to readers.",
313
- seedExperimentalLogo: "Logo shown in the site header.",
329
+ seedExperimentalLogo: "Logo shown in the space header.",
314
330
  seedExperimentalHomeOrder: "Legacy ordering preference for a space home page.",
315
331
  showOutline: "Whether to show the document outline.",
316
332
  showActivity: "Whether to show document activity and tools.",
317
333
  contentWidth: "Width of the document content area.",
318
334
  childrenType: "Layout of the document\u2019s root-level blocks.",
319
- theme: "Visual settings for a site.",
320
- "theme.headerLayout": "Alignment of the site header.",
335
+ theme: "Visual settings for a space.",
336
+ "theme.headerLayout": "Alignment of the space header.",
321
337
  importCategories: "Categories retained from an imported document.",
322
338
  importTags: "Tags retained from an imported document.",
323
339
  title: "Legacy document title; new documents use name.",
@@ -9,7 +9,7 @@ import {
9
9
  import {
10
10
  hmIdPathToEntityQueryPath,
11
11
  packHmId
12
- } from "./chunk-BXEZSVNI.mjs";
12
+ } from "./chunk-EGDF5YHG.mjs";
13
13
 
14
14
  // src/comment.ts
15
15
  import { decode as cborDecode, encode as cborEncode } from "@ipld/dag-cbor";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  codePointLength
3
- } from "./chunk-BXEZSVNI.mjs";
3
+ } from "./chunk-EGDF5YHG.mjs";
4
4
 
5
5
  // src/tei-to-blocks.ts
6
6
  function generateBlockId() {
@@ -2,7 +2,7 @@ import {
2
2
  entityQueryPathToHmIdPath,
3
3
  parseFragment,
4
4
  unpackHmId
5
- } from "./chunk-BXEZSVNI.mjs";
5
+ } from "./chunk-EGDF5YHG.mjs";
6
6
 
7
7
  // src/hm-resolver.ts
8
8
  async function resolveHypermediaUrl(url, opts) {
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  teiToBlocks
3
- } from "./chunk-RQRUU25M.mjs";
3
+ } from "./chunk-HYCHOIRR.mjs";
4
4
  import {
5
5
  embeddedPdfToBlocks
6
6
  } from "./chunk-52P3E6H6.mjs";
@@ -1,12 +1,12 @@
1
1
  import {
2
2
  resolveId
3
- } from "./chunk-MSGTSCBL.mjs";
3
+ } from "./chunk-I6T7E6NR.mjs";
4
4
  import {
5
5
  createSeedClient
6
- } from "./chunk-SLA7HDTC.mjs";
6
+ } from "./chunk-6ZDWVCC2.mjs";
7
7
  import {
8
8
  unpackHmId
9
- } from "./chunk-BXEZSVNI.mjs";
9
+ } from "./chunk-EGDF5YHG.mjs";
10
10
 
11
11
  // src/resource-read.ts
12
12
  async function resolveIdWithClient(rawId, options = {}) {
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  isSurrogate
3
- } from "./chunk-BXEZSVNI.mjs";
3
+ } from "./chunk-EGDF5YHG.mjs";
4
4
 
5
5
  // src/hmblock-to-editorblock.ts
6
6
  function toEditorBlockType(hmBlockType) {
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  packHmId,
3
3
  unpackHmId
4
- } from "./chunk-BXEZSVNI.mjs";
4
+ } from "./chunk-EGDF5YHG.mjs";
5
5
 
6
6
  // src/document-state.ts
7
7
  async function resolveDocumentState(client, targetId) {
package/dist/client.mjs CHANGED
@@ -1,13 +1,13 @@
1
1
  import {
2
2
  createSeedClient,
3
3
  deserializeQueryString
4
- } from "./chunk-SLA7HDTC.mjs";
4
+ } from "./chunk-6ZDWVCC2.mjs";
5
5
  import "./chunk-CBELM7KX.mjs";
6
6
  import "./chunk-JT57MV7Y.mjs";
7
7
  import "./chunk-PJ2RFT5A.mjs";
8
8
  import "./chunk-LVAHHQIK.mjs";
9
9
  import "./chunk-DR3HJ6BV.mjs";
10
- import "./chunk-BXEZSVNI.mjs";
10
+ import "./chunk-EGDF5YHG.mjs";
11
11
  import "./chunk-7P6ASYW6.mjs";
12
12
  export {
13
13
  createSeedClient,
package/dist/comment.mjs CHANGED
@@ -4,11 +4,11 @@ import {
4
4
  deleteComment,
5
5
  trimTrailingEmptyBlocks,
6
6
  updateComment
7
- } from "./chunk-PQEZHGRI.mjs";
7
+ } from "./chunk-FT4OR5WY.mjs";
8
8
  import "./chunk-N3P7S5YZ.mjs";
9
9
  import "./chunk-LVAHHQIK.mjs";
10
10
  import "./chunk-DR3HJ6BV.mjs";
11
- import "./chunk-BXEZSVNI.mjs";
11
+ import "./chunk-EGDF5YHG.mjs";
12
12
  import "./chunk-7P6ASYW6.mjs";
13
13
  export {
14
14
  commentRecordIdFromBlob,
@@ -4,8 +4,8 @@ import {
4
4
  followToDocument,
5
5
  resolveDocumentState,
6
6
  resolveEditableDocument
7
- } from "./chunk-RFDFZV7U.mjs";
8
- import "./chunk-BXEZSVNI.mjs";
7
+ } from "./chunk-YYQPNBQK.mjs";
8
+ import "./chunk-EGDF5YHG.mjs";
9
9
  import "./chunk-7P6ASYW6.mjs";
10
10
  export {
11
11
  describeRedirect,
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  editorBlockToHMBlock,
3
3
  editorBlocksToHMBlockNodes
4
- } from "./chunk-NPKHESR6.mjs";
4
+ } from "./chunk-5ARN5GTL.mjs";
5
5
  import "./chunk-N3P7S5YZ.mjs";
6
- import "./chunk-BXEZSVNI.mjs";
6
+ import "./chunk-EGDF5YHG.mjs";
7
7
  import "./chunk-7P6ASYW6.mjs";
8
8
  export {
9
9
  editorBlockToHMBlock,
@@ -1,8 +1,8 @@
1
1
  import {
2
2
  resolveHypermediaUrl,
3
3
  resolveId
4
- } from "./chunk-MSGTSCBL.mjs";
5
- import "./chunk-BXEZSVNI.mjs";
4
+ } from "./chunk-I6T7E6NR.mjs";
5
+ import "./chunk-EGDF5YHG.mjs";
6
6
  import "./chunk-7P6ASYW6.mjs";
7
7
  export {
8
8
  resolveHypermediaUrl,