@riboseinc/anafero-cli 0.0.68 → 0.0.69

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/bootstrap.js CHANGED
@@ -72258,6 +72258,9 @@ ${JSON.stringify(keyString)}: ${valueCursor}`;
72258
72258
  });
72259
72259
 
72260
72260
  // ../anafero/util/graph-query.mts
72261
+ function findValue(relations, subj, pred) {
72262
+ return relations.find(([s, p]) => s === subj && p === pred)?.[2] ?? null;
72263
+ }
72261
72264
  function resolveChain(relations, chain, subj_) {
72262
72265
  if (chain.length === 1) {
72263
72266
  return relations.filter((rel) => rel[1] === chain[0] && (!subj_ || rel[0] === subj_)).map((rel) => [rel[0], rel[2]]);
@@ -72371,6 +72374,7 @@ ${JSON.stringify(keyString)}: ${valueCursor}`;
72371
72374
  dedupeResourceRelationList: () => dedupeResourceRelationList,
72372
72375
  extractRelationsForIndexing: () => extractRelationsForIndexing,
72373
72376
  fillInLocale: () => fillInLocale,
72377
+ findValue: () => findValue,
72374
72378
  gatherDescribedResourcesFromJsonifiedProseMirrorNode: () => gatherDescribedResourcesFromJsonifiedProseMirrorNode,
72375
72379
  gatherTextFromJsonifiedProseMirrorNode: () => gatherTextFromJsonifiedProseMirrorNode,
72376
72380
  getAllParentPaths: () => getAllParentPaths,