@arbidocs/blocks 0.4.92 → 0.4.94

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.
Files changed (85) hide show
  1. package/dist/agents/index.cjs +209 -209
  2. package/dist/agents/index.js +4 -4
  3. package/dist/{chunk-6XS5IJ5R.cjs → chunk-3OXWJ3CZ.cjs} +5 -5
  4. package/dist/{chunk-6XS5IJ5R.cjs.map → chunk-3OXWJ3CZ.cjs.map} +1 -1
  5. package/dist/chunk-AF6RDAJF.js +14 -0
  6. package/dist/chunk-AF6RDAJF.js.map +1 -0
  7. package/dist/chunk-AOFATOT3.cjs +196 -0
  8. package/dist/chunk-AOFATOT3.cjs.map +1 -0
  9. package/dist/chunk-D3QPYKZG.js +173 -0
  10. package/dist/chunk-D3QPYKZG.js.map +1 -0
  11. package/dist/{chunk-2ZDFVRGV.cjs → chunk-E2AAIMXO.cjs} +975 -61
  12. package/dist/chunk-E2AAIMXO.cjs.map +1 -0
  13. package/dist/{chunk-DDYXFALG.cjs → chunk-KKU7MUWE.cjs} +5 -5
  14. package/dist/{chunk-DDYXFALG.cjs.map → chunk-KKU7MUWE.cjs.map} +1 -1
  15. package/dist/{chunk-EHF63UYP.cjs → chunk-LENXDIMY.cjs} +33 -65
  16. package/dist/chunk-LENXDIMY.cjs.map +1 -0
  17. package/dist/chunk-RC25WMVB.cjs +16 -0
  18. package/dist/chunk-RC25WMVB.cjs.map +1 -0
  19. package/dist/{chunk-5YXG342J.cjs → chunk-RPCQBET5.cjs} +3 -3
  20. package/dist/{chunk-5YXG342J.cjs.map → chunk-RPCQBET5.cjs.map} +1 -1
  21. package/dist/{chunk-YFPIJUV3.cjs → chunk-RZGVMV6B.cjs} +5 -5
  22. package/dist/{chunk-YFPIJUV3.cjs.map → chunk-RZGVMV6B.cjs.map} +1 -1
  23. package/dist/{chunk-W2R7YVFM.js → chunk-WXLKMEMB.js} +970 -65
  24. package/dist/chunk-WXLKMEMB.js.map +1 -0
  25. package/dist/{chunk-BX62HJZU.js → chunk-YPKSLTL5.js} +3 -3
  26. package/dist/{chunk-BX62HJZU.js.map → chunk-YPKSLTL5.js.map} +1 -1
  27. package/dist/{chunk-5RQOVALO.js → chunk-Z3G65XHZ.js} +21 -52
  28. package/dist/chunk-Z3G65XHZ.js.map +1 -0
  29. package/dist/{chunk-W7NZRZ54.js → chunk-Z7OMEYDG.js} +3 -3
  30. package/dist/{chunk-W7NZRZ54.js.map → chunk-Z7OMEYDG.js.map} +1 -1
  31. package/dist/{chunk-UDLMLU6T.js → chunk-ZNDAXSDP.js} +3 -3
  32. package/dist/{chunk-UDLMLU6T.js.map → chunk-ZNDAXSDP.js.map} +1 -1
  33. package/dist/{chunk-5NQIBJPP.js → chunk-ZNGDEQBN.js} +5 -5
  34. package/dist/{chunk-5NQIBJPP.js.map → chunk-ZNGDEQBN.js.map} +1 -1
  35. package/dist/connect/docx.cjs +8 -6
  36. package/dist/connect/docx.cjs.map +1 -1
  37. package/dist/connect/docx.js +6 -4
  38. package/dist/connect/docx.js.map +1 -1
  39. package/dist/connect/index.cjs +44 -44
  40. package/dist/connect/index.cjs.map +1 -1
  41. package/dist/connect/index.js +14 -14
  42. package/dist/connect/index.js.map +1 -1
  43. package/dist/docx/NativeDocxEditor.d.ts +6 -0
  44. package/dist/docx/definitions/DefinedTerms.d.ts +50 -0
  45. package/dist/docx/definitions/commands.d.ts +78 -0
  46. package/dist/docx/definitions/fragment.d.ts +29 -0
  47. package/dist/docx/definitions/port.d.ts +76 -0
  48. package/dist/docx/index.cjs +53 -15
  49. package/dist/docx/index.cjs.map +1 -1
  50. package/dist/docx/index.d.ts +3 -0
  51. package/dist/docx/index.js +5 -3
  52. package/dist/docx/index.js.map +1 -1
  53. package/dist/facts/index.cjs +9 -14
  54. package/dist/facts/index.cjs.map +1 -1
  55. package/dist/facts/index.js +5 -12
  56. package/dist/facts/index.js.map +1 -1
  57. package/dist/files/index.cjs +2 -2
  58. package/dist/files/index.js +2 -2
  59. package/dist/home/index.cjs +1 -1
  60. package/dist/home/index.js +1 -1
  61. package/dist/index.cjs +845 -705
  62. package/dist/index.cjs.map +1 -1
  63. package/dist/index.js +100 -13
  64. package/dist/index.js.map +1 -1
  65. package/dist/settings/index.cjs +35 -35
  66. package/dist/settings/index.js +3 -3
  67. package/dist/shell/index.cjs +1 -1
  68. package/dist/shell/index.js +1 -1
  69. package/dist/studio/index.cjs +1 -1
  70. package/dist/studio/index.js +1 -1
  71. package/dist/tags/definitions.d.ts +92 -0
  72. package/dist/tags/glossary.d.ts +44 -0
  73. package/dist/tags/index.d.ts +2 -0
  74. package/dist/tags/ooxml.d.ts +46 -0
  75. package/dist/tags/tagTableDocx.d.ts +1 -1
  76. package/dist/workflow-canvas/index.cjs +11 -11
  77. package/dist/workflow-canvas/index.js +4 -4
  78. package/dist/workspaces/index.cjs +1 -1
  79. package/dist/workspaces/index.js +1 -1
  80. package/package.json +4 -4
  81. package/src/docx/README.md +11 -0
  82. package/dist/chunk-2ZDFVRGV.cjs.map +0 -1
  83. package/dist/chunk-5RQOVALO.js.map +0 -1
  84. package/dist/chunk-EHF63UYP.cjs.map +0 -1
  85. package/dist/chunk-W2R7YVFM.js.map +0 -1
@@ -10,12 +10,12 @@ require('../chunk-VPPX5XUF.cjs');
10
10
  var chunkPCB2BPN3_cjs = require('../chunk-PCB2BPN3.cjs');
11
11
  var chunkZW6FPIFC_cjs = require('../chunk-ZW6FPIFC.cjs');
12
12
  require('../chunk-OB5F4577.cjs');
13
+ var chunkC54XEN5T_cjs = require('../chunk-C54XEN5T.cjs');
13
14
  require('../chunk-MP6FK43E.cjs');
14
15
  require('../chunk-VGOFFCMT.cjs');
15
16
  require('../chunk-B4SRYJLM.cjs');
16
17
  require('../chunk-7UTB4PHM.cjs');
17
18
  require('../chunk-PPCATBOY.cjs');
18
- var chunkC54XEN5T_cjs = require('../chunk-C54XEN5T.cjs');
19
19
  var chunkKDG6FER6_cjs = require('../chunk-KDG6FER6.cjs');
20
20
  require('../chunk-MHVNT4J3.cjs');
21
21
  require('../chunk-DES3K4SD.cjs');
@@ -9,12 +9,12 @@ import '../chunk-4EZVCGRL.js';
9
9
  import { Callout } from '../chunk-UJE32SST.js';
10
10
  import { EmptyState } from '../chunk-P6GHJSLR.js';
11
11
  import '../chunk-S7PSMMRG.js';
12
+ import { useBlocksEnvironment } from '../chunk-76JDDMSP.js';
12
13
  import '../chunk-EWSEQEPL.js';
13
14
  import '../chunk-KZJAG7T3.js';
14
15
  import '../chunk-HOXKR26S.js';
15
16
  import '../chunk-AA3PT6KR.js';
16
17
  import '../chunk-NPLYHR2E.js';
17
- import { useBlocksEnvironment } from '../chunk-76JDDMSP.js';
18
18
  import { formatCount } from '../chunk-OXF2IFXG.js';
19
19
  import '../chunk-7F6CBP3Z.js';
20
20
  import '../chunk-VUNV25KB.js';
@@ -0,0 +1,92 @@
1
+ /**
2
+ * Defined terms. A definition is an ordinary fact carrying the workspace's "Definitions" label; its
3
+ * TERM is read from the start of its text — `"Shares" means …`, `**Business Day** shall mean …`,
4
+ * `Completion: the date …` — and facts defining the same term (one per agreement, say) are grouped,
5
+ * a confirmed one preferred over the rest, then the most recent. Pure helpers, no React: the Word
6
+ * editor inserts terms with them and the Tags page prints the glossary with them.
7
+ */
8
+ /** The label that marks a fact as a definition. */
9
+ export declare const DEFINITIONS_LABEL = "Definitions";
10
+ /** A label on a definition other than {@link DEFINITIONS_LABEL} (e.g. the agreement it is from). */
11
+ export interface DefinitionLabel {
12
+ id: string;
13
+ name: string;
14
+ }
15
+ /** A definition fact, as the host reads it. */
16
+ export interface DefinitionSource {
17
+ /** The fact's id (`fct-…`). */
18
+ id: string;
19
+ /** The fact text, as written (it may be Markdown). */
20
+ text: string;
21
+ /** A human vouched for it: preferred over unconfirmed definitions of the same term. */
22
+ confirmed?: boolean;
23
+ /** ISO time it was last written; the most recent wins between equals. */
24
+ updatedAt?: string;
25
+ /** Where it comes from: the cited document's name. */
26
+ source?: string;
27
+ /** Its other labels, e.g. the agreement ("SPA") it defines a term of. */
28
+ labels?: DefinitionLabel[];
29
+ }
30
+ /** A definition's text split into its term and the rest. */
31
+ export interface ParsedDefinition {
32
+ /** The term as written, without quotes or emphasis (`Business Day`). */
33
+ term: string;
34
+ /** What follows the term, its connecting word included (`means a day …`, `: the date …`). */
35
+ rest: string;
36
+ /** Just the meaning, the connecting word dropped (`a day …`). */
37
+ meaning: string;
38
+ }
39
+ /** A parsed definition fact. */
40
+ export interface Definition extends DefinitionSource, ParsedDefinition {
41
+ /** The term's matching key (case and whitespace folded). */
42
+ key: string;
43
+ }
44
+ /** Every definition of one term, the preferred one first. */
45
+ export interface DefinedTermGroup {
46
+ key: string;
47
+ /** The term as the preferred definition writes it. */
48
+ term: string;
49
+ /** The preferred definition (first of {@link DefinedTermGroup.definitions}). */
50
+ preferred: Definition;
51
+ definitions: Definition[];
52
+ }
53
+ /** The matching key of a term: case and whitespace folded, quotes and emphasis dropped. */
54
+ export declare function termKey(term: string): string;
55
+ /**
56
+ * Read a definition's term from the start of its text, or `null` when it does not start with one.
57
+ *
58
+ * Optional straight or curly quotes and bold markers around the term are dropped; the term is what
59
+ * comes before "means", "shall mean", "includes", "has the meaning", a colon, or a dash. A quoted
60
+ * term is taken whole, so `"Long-Stop Date" means …` keeps its hyphen.
61
+ */
62
+ export declare function parseDefinition(text: string): ParsedDefinition | null;
63
+ /** A definition parsed, or `null` when its text names no term. */
64
+ export declare function toDefinition(source: DefinitionSource): Definition | null;
65
+ /** Preferred first: confirmed, then most recently written, then by id (stable). */
66
+ export declare function compareDefinitions(a: DefinitionSource, b: DefinitionSource): number;
67
+ /** Alphabetical order of terms, as a reader sorts a glossary (case and accents folded). */
68
+ export declare const compareTerms: (a: string, b: string) => number;
69
+ /**
70
+ * Definitions grouped by term, alphabetically, each group's preferred definition first. Facts whose
71
+ * text names no term are returned apart (`unparsed`), so a host can say how many it could not read.
72
+ * With `labelId`, only definitions carrying that label (one agreement's, say) are kept.
73
+ */
74
+ export declare function groupDefinitions(sources: readonly DefinitionSource[], options?: {
75
+ labelId?: string | null;
76
+ }): {
77
+ groups: DefinedTermGroup[];
78
+ unparsed: DefinitionSource[];
79
+ };
80
+ /** The labels (agreements) definitions carry besides the Definitions label, by name. */
81
+ export declare function definitionLabels(sources: readonly DefinitionSource[]): DefinitionLabel[];
82
+ /** Groups whose term matches a typed query: prefix matches first, then any word, then anywhere. */
83
+ export declare function filterTermGroups(groups: readonly DefinedTermGroup[], query: string): DefinedTermGroup[];
84
+ /** Prefix of every bookmark a defined term links to: hidden in Word (leading underscore). */
85
+ export declare const DEFINITION_BOOKMARK_PREFIX = "_dt_";
86
+ /**
87
+ * The Word bookmark of a definition: `_dt_` and the fact id in valid bookmark characters
88
+ * (`fct-AbC12345` → `_dt_fct_AbC12345`), at most 40 characters as Word requires.
89
+ */
90
+ export declare function definitionBookmark(factId: string): string;
91
+ /** The fact id a definition bookmark names, or `null` for any other bookmark. */
92
+ export declare function definitionIdOfBookmark(name: string): string | null;
@@ -0,0 +1,44 @@
1
+ /**
2
+ * The glossary: every definition fact (optionally one agreement's), alphabetical by term, as a
3
+ * three-column table — Term, Definition, Source — printed as a Word document or as Markdown with
4
+ * the same WordprocessingML the tag tables export with (`ooxml.ts`).
5
+ */
6
+ import { type DefinitionSource } from './definitions';
7
+ /** One glossary row. */
8
+ export interface GlossaryEntry {
9
+ /** Empty for a definition whose text names no term (listed last, as written). */
10
+ term: string;
11
+ definition: string;
12
+ source: string;
13
+ factId: string;
14
+ }
15
+ export interface GlossaryLabels {
16
+ term: string;
17
+ definition: string;
18
+ source: string;
19
+ /** `{at}` is when it was printed, `YYYY-MM-DD HH:MM UTC`. */
20
+ takenAt: string;
21
+ empty: string;
22
+ }
23
+ export declare const DEFAULT_GLOSSARY_LABELS: GlossaryLabels;
24
+ export interface GlossaryOptions {
25
+ title: string;
26
+ /** When it was printed (ISO); default now. */
27
+ at?: string;
28
+ labels?: Partial<GlossaryLabels>;
29
+ }
30
+ /**
31
+ * The glossary's rows: every definition, alphabetical by term and, within a term, the preferred one
32
+ * first. Definitions whose text names no term follow, as written. `labelId` keeps one label's.
33
+ */
34
+ export declare function glossaryEntries(sources: readonly DefinitionSource[], options?: {
35
+ labelId?: string | null;
36
+ }): GlossaryEntry[];
37
+ /** The glossary as a Markdown document: a heading, when it was printed, and one table. */
38
+ export declare function glossaryMarkdown(entries: readonly GlossaryEntry[], options: GlossaryOptions): string;
39
+ /** `word/document.xml` of the glossary (exposed for tests). */
40
+ export declare function glossaryDocumentXml(entries: readonly GlossaryEntry[], options: GlossaryOptions): string;
41
+ /** The glossary as `.docx` bytes. */
42
+ export declare function glossaryDocx(entries: readonly GlossaryEntry[], options: GlossaryOptions): Uint8Array;
43
+ /** A file name for the glossary: `Glossary - SPA.docx`. */
44
+ export declare function glossaryFileName(title: string, extension: 'docx' | 'md'): string;
@@ -9,3 +9,5 @@ export { TagDetail, DEFAULT_TAG_DETAIL_LABELS, type TagDetailProps, type TagDeta
9
9
  export { TagsNav, findTagsNavItem, DEFAULT_TAGS_NAV_LABELS, type TagsNavProps, type TagsNavLabels, type TagsNavGroup, type TagsNavItem, type TagsNavSelection, } from './TagsNav';
10
10
  export { tagTableMarkdown, cellValue, cellText, parseCell, isGap, rowLinks, fieldWrites, type TagTableData, type TagTableRow, type TagTableLinks, type TagTableField, type TagTableFieldType, type TagTableFieldWrite, type TagTableMarkdownOptions, } from './tagTableModel';
11
11
  export { tagTableDocx, tagTableDocumentXml, DEFAULT_TAG_TABLE_DOCX_LABELS, TAG_TABLE_DOCX_LANDSCAPE_AFTER, type TagTableDocxLabels, type TagTableDocxOptions, } from './tagTableDocx';
12
+ export { DEFINITIONS_LABEL, DEFINITION_BOOKMARK_PREFIX, parseDefinition, toDefinition, termKey, groupDefinitions, definitionLabels, filterTermGroups, compareDefinitions, compareTerms, definitionBookmark, definitionIdOfBookmark, type DefinitionSource, type DefinitionLabel, type Definition, type DefinedTermGroup, type ParsedDefinition, } from './definitions';
13
+ export { glossaryEntries, glossaryMarkdown, glossaryDocx, glossaryDocumentXml, glossaryFileName, DEFAULT_GLOSSARY_LABELS, type GlossaryEntry, type GlossaryLabels, type GlossaryOptions, } from './glossary';
@@ -0,0 +1,46 @@
1
+ /**
2
+ * The small WordprocessingML vocabulary the tags exports write: escaped runs, paragraphs, table
3
+ * cells, an A4 page, and the minimal package around a `word/document.xml`. Zipped with `fflate`, so
4
+ * the result opens in the native Word editor and in Word without pulling the editor engine in.
5
+ */
6
+ export declare const DOCX_MIME_TYPE = "application/vnd.openxmlformats-officedocument.wordprocessingml.document";
7
+ export declare const W_NAMESPACES = "xmlns:w=\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\" xmlns:r=\"http://schemas.openxmlformats.org/officeDocument/2006/relationships\"";
8
+ /** Text as XML character data or an attribute value. */
9
+ export declare const esc: (text: string) => string;
10
+ export interface Run {
11
+ text: string;
12
+ bold?: boolean;
13
+ italic?: boolean;
14
+ muted?: boolean;
15
+ }
16
+ export declare const run: ({ text, bold, italic, muted }: Run) => string;
17
+ export declare const paragraph: (runs: Run[], style?: string) => string;
18
+ /** A table cell: its paragraphs (a cell must hold at least one), shaded when given a fill. */
19
+ export declare const cell: (paragraphs: string[], width: number, fill?: string) => string;
20
+ /** Page geometry in twips (A4), turned for landscape. */
21
+ export declare function page(landscape: boolean): {
22
+ margin: number;
23
+ textWidth: number;
24
+ sectPr: string;
25
+ };
26
+ /** `YYYY-MM-DD HH:MM` (UTC) of an ISO time, for a "taken at" line. */
27
+ export declare const minuteUtc: (at: string) => string;
28
+ /** A `word/document.xml` around body content (paragraphs, tables, then the section). */
29
+ export declare const documentXml: (body: string) => string;
30
+ /** `word/styles.xml` holding the given style definitions. */
31
+ export declare const stylesXml: (defaults: string, styles: string) => string;
32
+ /** Calibri 11pt (en-GB), 8pt after each paragraph: the document defaults the exports share. */
33
+ export declare const DOC_DEFAULTS = "<w:docDefaults><w:rPrDefault><w:rPr><w:rFonts w:ascii=\"Calibri\" w:hAnsi=\"Calibri\" w:eastAsia=\"Calibri\" w:cs=\"Calibri\"/><w:sz w:val=\"22\"/><w:szCs w:val=\"22\"/><w:lang w:val=\"en-GB\"/></w:rPr></w:rPrDefault><w:pPrDefault><w:pPr><w:spacing w:after=\"160\" w:line=\"259\" w:lineRule=\"auto\"/></w:pPr></w:pPrDefault></w:docDefaults>";
34
+ /**
35
+ * Styles of a document that is a title and a table: `Title`, the compact `TagTableCell` paragraph
36
+ * and the bordered `TagTableGrid` table.
37
+ */
38
+ export declare const TABLE_DOCUMENT_STYLES: string;
39
+ /** The minimal `.docx` package: a document, its styles, and its title and time. */
40
+ export declare function docxPackage(parts: {
41
+ document: string;
42
+ styles: string;
43
+ title: string;
44
+ /** ISO time; default now. */
45
+ at?: string;
46
+ }): Uint8Array;
@@ -6,7 +6,7 @@
6
6
  * in Word without pulling the editor engine into the tags module.
7
7
  */
8
8
  import { type TagTableData } from './tagTableModel';
9
- export declare const DOCX_MIME_TYPE = "application/vnd.openxmlformats-officedocument.wordprocessingml.document";
9
+ export { DOCX_MIME_TYPE } from './ooxml';
10
10
  /** More table columns than this (item, fields, evidence, gaps) turn the page to landscape. */
11
11
  export declare const TAG_TABLE_DOCX_LANDSCAPE_AFTER = 6;
12
12
  export interface TagTableDocxLabels {
@@ -2,7 +2,7 @@
2
2
  'use strict';
3
3
 
4
4
  var chunkMUMH3Z6K_cjs = require('../chunk-MUMH3Z6K.cjs');
5
- var chunkDDYXFALG_cjs = require('../chunk-DDYXFALG.cjs');
5
+ var chunkKKU7MUWE_cjs = require('../chunk-KKU7MUWE.cjs');
6
6
  require('../chunk-S5HZBXZA.cjs');
7
7
  require('../chunk-ZW6FPIFC.cjs');
8
8
  var chunk3US5OIDQ_cjs = require('../chunk-3US5OIDQ.cjs');
@@ -17,13 +17,13 @@ require('../chunk-2EI7NCUA.cjs');
17
17
  require('../chunk-Z5VUZ6YD.cjs');
18
18
  require('../chunk-7D737FLE.cjs');
19
19
  require('../chunk-OB5F4577.cjs');
20
+ require('../chunk-C54XEN5T.cjs');
21
+ require('../chunk-ULWRNGGE.cjs');
22
+ require('../chunk-IXALYQT7.cjs');
20
23
  require('../chunk-B4SRYJLM.cjs');
21
24
  require('../chunk-7UTB4PHM.cjs');
22
25
  require('../chunk-PPCATBOY.cjs');
23
- require('../chunk-C54XEN5T.cjs');
24
26
  require('../chunk-KDG6FER6.cjs');
25
- require('../chunk-ULWRNGGE.cjs');
26
- require('../chunk-IXALYQT7.cjs');
27
27
  require('../chunk-FX3K6LNZ.cjs');
28
28
  require('../chunk-MHVNT4J3.cjs');
29
29
  require('../chunk-DES3K4SD.cjs');
@@ -1615,7 +1615,7 @@ function triggerFields(trigger, clearOthers) {
1615
1615
  return {
1616
1616
  timezone: trigger.timezone,
1617
1617
  rrule: trigger.start === "repeat" ? trigger.rrule.trim() : none,
1618
- run_at: trigger.start === "once" ? chunkDDYXFALG_cjs.localInputToIso(trigger.runAt) : none,
1618
+ run_at: trigger.start === "once" ? chunkKKU7MUWE_cjs.localInputToIso(trigger.runAt) : none,
1619
1619
  event_kind: trigger.start === "event" ? trigger.eventKind.trim() : none,
1620
1620
  // A step signal is `workflow_signal` narrowed to one signal name.
1621
1621
  event_filter: filter ?? none,
@@ -1674,7 +1674,7 @@ function workflowRecordToBuilder(record) {
1674
1674
  ...record.skill_ref ? { workflow: record.skill_ref } : { run: { kind: "prompt", promptTemplate: record.prompt } }
1675
1675
  }
1676
1676
  ] : [];
1677
- const when = chunkDDYXFALG_cjs.workflowWhen(record);
1677
+ const when = chunkKKU7MUWE_cjs.workflowWhen(record);
1678
1678
  return {
1679
1679
  workflow: {
1680
1680
  id: record.external_id,
@@ -1688,7 +1688,7 @@ function workflowRecordToBuilder(record) {
1688
1688
  trigger: {
1689
1689
  ...DEFAULT_WORKFLOW_TRIGGER,
1690
1690
  start: when === "now" ? "manual" : when,
1691
- runAt: chunkDDYXFALG_cjs.isoToLocalInput(record.run_at),
1691
+ runAt: chunkKKU7MUWE_cjs.isoToLocalInput(record.run_at),
1692
1692
  rrule: record.rrule ?? "",
1693
1693
  timezone: record.timezone || DEFAULT_WORKFLOW_TRIGGER.timezone,
1694
1694
  eventKind: record.event_kind ?? "",
@@ -1744,7 +1744,7 @@ function triggerSummary(trigger, options = {}) {
1744
1744
  case "once":
1745
1745
  return trigger.runAt ? new Date(trigger.runAt).toLocaleString() : l.starts.once;
1746
1746
  case "repeat":
1747
- return trigger.rrule ? chunkDDYXFALG_cjs.describeRRule(trigger.rrule) : l.starts.repeat;
1747
+ return trigger.rrule ? chunkKKU7MUWE_cjs.describeRRule(trigger.rrule) : l.starts.repeat;
1748
1748
  case "event":
1749
1749
  if (isSignalTrigger(trigger))
1750
1750
  return trigger.signal ? l.signalSummary.replace("{signal}", trigger.signal) : l.stepSignals;
@@ -1803,7 +1803,7 @@ function TriggerInspector({
1803
1803
  }
1804
1804
  )
1805
1805
  ] }),
1806
- trigger.start === "repeat" && /* @__PURE__ */ jsxRuntime.jsx(chunkDDYXFALG_cjs.RecurrenceBuilder, { rrule: trigger.rrule, onChange: (rrule) => set({ rrule }) }),
1806
+ trigger.start === "repeat" && /* @__PURE__ */ jsxRuntime.jsx(chunkKKU7MUWE_cjs.RecurrenceBuilder, { rrule: trigger.rrule, onChange: (rrule) => set({ rrule }) }),
1807
1807
  trigger.start === "event" && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1.5", children: [
1808
1808
  /* @__PURE__ */ jsxRuntime.jsx(ui.Label, { className: "text-xs", children: l.event }),
1809
1809
  /* @__PURE__ */ jsxRuntime.jsxs(
@@ -1855,7 +1855,7 @@ function TriggerInspector({
1855
1855
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1.5", children: [
1856
1856
  /* @__PURE__ */ jsxRuntime.jsx(ui.Label, { className: "text-xs", children: l.agent }),
1857
1857
  /* @__PURE__ */ jsxRuntime.jsx(
1858
- chunkDDYXFALG_cjs.AgentSelect,
1858
+ chunkKKU7MUWE_cjs.AgentSelect,
1859
1859
  {
1860
1860
  agents,
1861
1861
  value: trigger.agentId,
@@ -2706,7 +2706,7 @@ function WorkflowPreview({
2706
2706
  renderIcon,
2707
2707
  testId
2708
2708
  }) {
2709
- const run = chunkDDYXFALG_cjs.useWorkflowPreview(workflow, {
2709
+ const run = chunkKKU7MUWE_cjs.useWorkflowPreview(workflow, {
2710
2710
  resolveWorkflow: (id) => workflows.find((w) => w.id === id),
2711
2711
  compose,
2712
2712
  answer
@@ -1,6 +1,6 @@
1
1
  "use client";
2
2
  import { useConnection } from '../chunk-OYMWV45N.js';
3
- import { workflowWhen, isoToLocalInput, describeRRule, RecurrenceBuilder, AgentSelect, useWorkflowPreview, localInputToIso } from '../chunk-5NQIBJPP.js';
3
+ import { workflowWhen, isoToLocalInput, describeRRule, RecurrenceBuilder, AgentSelect, useWorkflowPreview, localInputToIso } from '../chunk-ZNGDEQBN.js';
4
4
  import '../chunk-4XJZ6AAY.js';
5
5
  import '../chunk-P6GHJSLR.js';
6
6
  import { workflowSteps, dependsOn, stepLevels, isIncompleteSignal, runFields, upstreamSteps, stepDependencies, canAssign, fromPlanSteps, layoutFromPlanSteps, validateWorkflowGraph, stepConfigProblems, WorkflowRunner, skillToWorkflow, assigneeName, orderSteps, toPlanSteps } from '../chunk-PGDL26TQ.js';
@@ -15,13 +15,13 @@ import '../chunk-YU2KUMGE.js';
15
15
  import '../chunk-DDF5GPIJ.js';
16
16
  import '../chunk-XD2M6LIG.js';
17
17
  import '../chunk-S7PSMMRG.js';
18
+ import '../chunk-76JDDMSP.js';
19
+ import '../chunk-TX2ZICS7.js';
20
+ import '../chunk-ZPLG7QYF.js';
18
21
  import '../chunk-HOXKR26S.js';
19
22
  import '../chunk-AA3PT6KR.js';
20
23
  import '../chunk-NPLYHR2E.js';
21
- import '../chunk-76JDDMSP.js';
22
24
  import '../chunk-OXF2IFXG.js';
23
- import '../chunk-TX2ZICS7.js';
24
- import '../chunk-ZPLG7QYF.js';
25
25
  import '../chunk-SLSBJRWW.js';
26
26
  import '../chunk-7F6CBP3Z.js';
27
27
  import '../chunk-VUNV25KB.js';
@@ -5,9 +5,9 @@ var chunkXZIYRKLW_cjs = require('../chunk-XZIYRKLW.cjs');
5
5
  var chunkXAJIKT6Y_cjs = require('../chunk-XAJIKT6Y.cjs');
6
6
  var chunkOB5F4577_cjs = require('../chunk-OB5F4577.cjs');
7
7
  require('../chunk-C54XEN5T.cjs');
8
- var chunkKDG6FER6_cjs = require('../chunk-KDG6FER6.cjs');
9
8
  var chunk7G2LJMUG_cjs = require('../chunk-7G2LJMUG.cjs');
10
9
  var chunkULWRNGGE_cjs = require('../chunk-ULWRNGGE.cjs');
10
+ var chunkKDG6FER6_cjs = require('../chunk-KDG6FER6.cjs');
11
11
  require('../chunk-DES3K4SD.cjs');
12
12
  var react = require('react');
13
13
  var lucideReact = require('lucide-react');
@@ -3,9 +3,9 @@ import { CollapsibleSection, KeyValueRow } from '../chunk-LGBAZD37.js';
3
3
  import { MemberAvatarStack } from '../chunk-XNOASBGW.js';
4
4
  import { ActionLink } from '../chunk-S7PSMMRG.js';
5
5
  import '../chunk-76JDDMSP.js';
6
- import { fromNow, fmtDate } from '../chunk-OXF2IFXG.js';
7
6
  export { RoleBadge, WorkspaceTypeBadgeView } from '../chunk-NBV56SGU.js';
8
7
  import { ModalHeader } from '../chunk-TX2ZICS7.js';
8
+ import { fromNow, fmtDate } from '../chunk-OXF2IFXG.js';
9
9
  import '../chunk-VUNV25KB.js';
10
10
  import { createContext, useContext, useMemo, useState, useCallback, useId } from 'react';
11
11
  import { FileText, MessagesSquare, Users, Check, ChevronRight, UserPlus, LogOut, AlertCircle, Plus, ArrowUpRight, AlignLeft, Globe, CreditCard, Loader2, FolderLock } from 'lucide-react';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arbidocs/blocks",
3
- "version": "0.4.92",
3
+ "version": "0.4.94",
4
4
  "description": "Composable, domain-neutral UI blocks for ARBI apps, organised by capability (retrieval, facts, agents, workspaces, citations, collaboration) plus shell, theme and site primitives, on top of @arbidocs/react.",
5
5
  "type": "module",
6
6
  "main": "dist/index.cjs",
@@ -266,8 +266,8 @@
266
266
  "example:test:e2e": "playwright test -c examples/custom-ui/playwright.config.ts"
267
267
  },
268
268
  "dependencies": {
269
- "@arbidocs/client": "0.4.92",
270
- "@arbidocs/coedit": "0.4.92",
269
+ "@arbidocs/client": "0.4.94",
270
+ "@arbidocs/coedit": "0.4.94",
271
271
  "@dnd-kit/core": "^6.3.1",
272
272
  "@dnd-kit/sortable": "^10.0.0",
273
273
  "@dnd-kit/utilities": "^3.2.2",
@@ -293,7 +293,7 @@
293
293
  "zustand": "^5.0.14"
294
294
  },
295
295
  "peerDependencies": {
296
- "@arbidocs/react": "0.4.92",
296
+ "@arbidocs/react": "0.4.94",
297
297
  "@docx-editor.dev/core": "2.28.0",
298
298
  "@docx-editor.dev/react": "2.28.0",
299
299
  "@lexical/html": "0.35.0",
@@ -66,3 +66,14 @@ with tracked operations and refuses stale targets.
66
66
  `NativeDocxComparison` uses the same adapter and native editor for the LibreOffice
67
67
  Word redline. Pass `baseId`, `revisedId`, `title` and optionally `onCompared` to
68
68
  refresh only the generated document in your host cache. Source files stay intact.
69
+
70
+ Defined terms: give the adapter `definitions` (the workspace's facts labelled "Definitions", as
71
+ `DefinitionSource`s) and the Insert tab offers Defined term and Update definitions, and typing
72
+ `@@` in the body opens the term type-ahead. A picked term is inserted as an internal link
73
+ (`w:hyperlink w:anchor`, the definition as its tooltip) to a hidden `_dt_<fact id>` bookmark on
74
+ its definition, which is added in alphabetical order to the document's Definitions section (a
75
+ heading named "Definitions"/"Definitions and interpretation"…, else a new "Definitions" heading at
76
+ the end). Hovering a term shows its definition. Update definitions adds missing definitions,
77
+ rewords and reorders the ones the section has, and lists those never used. The terms are read from
78
+ the facts with `parseDefinition`/`groupDefinitions` (root entry), which also print the glossary
79
+ (`glossaryDocx`, `glossaryMarkdown`).