@lax-wp/editor 0.4.13 → 0.4.15-beta.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 +25 -0
- package/dist/api/audit.d.ts +79 -0
- package/dist/api/derivedRulebook.d.ts +470 -0
- package/dist/api/documentVersions.d.ts +519 -0
- package/dist/api/effectiveRules.d.ts +372 -0
- package/dist/api/methodology.d.ts +62 -0
- package/dist/api/playbook.d.ts +604 -0
- package/dist/api/promotions.d.ts +1432 -0
- package/dist/api/r1.d.ts +1097 -0
- package/dist/api/r1.fixtures.d.ts +111 -0
- package/dist/api/redlineJobs.d.ts +377 -0
- package/dist/api/redlineStream.d.ts +2979 -0
- package/dist/api/redlines.d.ts +504 -0
- package/dist/api/regsync.d.ts +2355 -0
- package/dist/api/ruleAuthoring.d.ts +305 -0
- package/dist/api/ruleBuilder.d.ts +1009 -0
- package/dist/api/ruleOverrides.d.ts +31 -0
- package/dist/api/ruleStats.d.ts +84 -0
- package/dist/api/rulesCatalog.d.ts +234 -0
- package/dist/api/versions.d.ts +76 -0
- package/dist/api/workspace.d.ts +41 -0
- package/dist/components/EditorSidebar.d.ts +4 -1
- package/dist/components/audit/AuditView.d.ts +8 -0
- package/dist/components/capturededits/AddAsRuleModal.d.ts +8 -0
- package/dist/components/capturededits/CapturedEditCard.d.ts +15 -0
- package/dist/components/capturededits/CapturedEditsTray.d.ts +4 -0
- package/dist/components/capturededits/capturedEditIntent.d.ts +23 -0
- package/dist/components/common/EscDropdown.d.ts +2 -0
- package/dist/components/compliance/MethodologyPanel.d.ts +14 -0
- package/dist/components/compliance/RegSyncPanel.d.ts +18 -0
- package/dist/components/compliance/index.d.ts +8 -0
- package/dist/components/compliance/primitives.d.ts +41 -0
- package/dist/components/documents/DocumentVersionHistory.d.ts +12 -0
- package/dist/components/documents/documentDiff.d.ts +68 -0
- package/dist/components/documents/index.d.ts +4 -0
- package/dist/components/flowdown/FlowdownPanel.d.ts +28 -0
- package/dist/components/flowdown/FlowdownRowCard.d.ts +27 -0
- package/dist/components/flowdown/flowdownModel.d.ts +150 -0
- package/dist/components/history/PlaybookVersionHistory.d.ts +10 -0
- package/dist/components/history/versionDiff.d.ts +14 -0
- package/dist/components/playbook/AllPlaybooksView.d.ts +41 -0
- package/dist/components/playbook/DerivedRulebookView.d.ts +9 -0
- package/dist/components/playbook/DraftedRulePreview.d.ts +17 -0
- package/dist/components/playbook/EffectiveRulesView.d.ts +11 -0
- package/dist/components/playbook/NewRuleDrawer.d.ts +11 -0
- package/dist/components/playbook/PlaybookCard.d.ts +13 -0
- package/dist/components/playbook/PlaybookPage.d.ts +29 -0
- package/dist/components/playbook/PlaybookPanel.d.ts +73 -0
- package/dist/components/playbook/PromotionSuggestions.d.ts +1 -0
- package/dist/components/playbook/ReprioritizeDialog.d.ts +16 -0
- package/dist/components/playbook/RuleDetail.d.ts +27 -0
- package/dist/components/playbook/RuleEditorFields.d.ts +42 -0
- package/dist/components/playbook/RuleEditorModal.d.ts +27 -0
- package/dist/components/playbook/RulePerformancePanel.d.ts +4 -0
- package/dist/components/playbook/RuleRow.d.ts +26 -0
- package/dist/components/playbook/ThisDocumentView.d.ts +45 -0
- package/dist/components/playbook/ViewTabs.d.ts +8 -0
- package/dist/components/playbook/index.d.ts +14 -0
- package/dist/components/playbook/predicateSummary.d.ts +10 -0
- package/dist/components/playbook/primitives.d.ts +82 -0
- package/dist/components/playbook/useFocusTrap.d.ts +6 -0
- package/dist/components/playbook/usePlaybookData.d.ts +161 -0
- package/dist/components/playbook/usePlaybookLabel.d.ts +18 -0
- package/dist/components/r1/ApprovalPanel.d.ts +10 -0
- package/dist/components/r1/CandidateRuleCard.d.ts +8 -0
- package/dist/components/r1/ExecSummaryPanel.d.ts +23 -0
- package/dist/components/r1/PrimeUploadPanel.d.ts +8 -0
- package/dist/components/r1/ReviewStartControls.d.ts +24 -0
- package/dist/components/r1/ReviewSummaryTab.d.ts +38 -0
- package/dist/components/r1/index.d.ts +13 -0
- package/dist/components/r1/primitives.d.ts +59 -0
- package/dist/components/redline/AiReviewPanel.d.ts +194 -0
- package/dist/components/redline/RedlineHoverCard.d.ts +13 -0
- package/dist/components/redline/RedlineItem.d.ts +12 -0
- package/dist/components/redline/ReviewCard.d.ts +49 -0
- package/dist/components/redline/index.d.ts +6 -0
- package/dist/components/redline/reviewItems.d.ts +49 -0
- package/dist/components/redline/reviewPrefs.d.ts +18 -0
- package/dist/components/redline/useRunScopedCards.d.ts +16 -0
- package/dist/components/rulebuilder/AuthorForms.d.ts +28 -0
- package/dist/components/rulebuilder/CandidateQueue.d.ts +21 -0
- package/dist/components/rulebuilder/DraftPane.d.ts +12 -0
- package/dist/components/rulebuilder/RuleBuilderPanel.d.ts +6 -0
- package/dist/components/rulebuilder/RuleCard.d.ts +16 -0
- package/dist/components/rulebuilder/TestBench.d.ts +10 -0
- package/dist/components/rulebuilder/VocabularyPanel.d.ts +26 -0
- package/dist/components/rulebuilder/index.d.ts +13 -0
- package/dist/components/rulebuilder/primitives.d.ts +54 -0
- package/dist/components/rulebuilder/useRuleBuilder.d.ts +291 -0
- package/dist/components/sidebar/ExpandableSidebar.d.ts +2 -0
- package/dist/components/sidebar/WorkspaceRetentionPanel.d.ts +18 -0
- package/dist/components/sidebar/content/TrackChangesContent.d.ts +8 -0
- package/dist/components/sidebar/content/anonymization-page/PIIAnonymization.d.ts +1 -1
- package/dist/components/sidebar/content/anonymization-page/PiiIdleView.d.ts +12 -0
- package/dist/components/sidebar/content/anonymization-page/PiiRecoveryView.d.ts +16 -0
- package/dist/components/sidebar/content/anonymization-page/PiiSummaryView.d.ts +34 -0
- package/dist/components/sidebar/content/anonymization-page/PiiUnavailableView.d.ts +1 -0
- package/dist/components/sidebar/content/anonymization-page/RestoreConfirmDialog.d.ts +9 -0
- package/dist/components/sidebar/content/anonymization-page/anonymizationUtils.d.ts +38 -17
- package/dist/components/sidebar/content/anonymization-page/piiVault.d.ts +18 -0
- package/dist/components/sidebar/content/index.d.ts +0 -1
- package/dist/components/toolbar/AutocompletionToggle.d.ts +1 -0
- package/dist/components/trackChanges/TrackChangesCards.d.ts +1 -0
- package/dist/components/trackChanges/index.d.ts +2 -0
- package/dist/components/trackChanges/utils.d.ts +5 -0
- package/dist/config/EditorConfig.d.ts +197 -73
- package/dist/constants/Extensions.d.ts +12 -0
- package/dist/constants/playbook.d.ts +108 -0
- package/dist/contexts/CapturedEditsContext.d.ts +56 -0
- package/dist/contexts/EditorShellContext.d.ts +4 -1
- package/dist/editor.css +1 -1
- package/dist/extensions/AnonymizedText.d.ts +31 -2
- package/dist/extensions/VariableText.d.ts +20 -0
- package/dist/extensions/index.d.ts +1 -1
- package/dist/extensions/plugins/CapturedEditsPlugin.d.ts +90 -0
- package/dist/extensions/plugins/MarkHighlightPlugin.d.ts +0 -1
- package/dist/extensions/plugins/RedlinePlugin.d.ts +9 -0
- package/dist/extensions/redline/changeTypes.d.ts +70 -0
- package/dist/extensions/redline/constants.d.ts +25 -0
- package/dist/extensions/redline/engine/blockNodes.d.ts +31 -0
- package/dist/extensions/redline/engine/clipboard.d.ts +16 -0
- package/dist/extensions/redline/engine/deletion.d.ts +34 -0
- package/dist/extensions/redline/engine/formatSplit.d.ts +16 -0
- package/dist/extensions/redline/engine/insertion.d.ts +26 -0
- package/dist/extensions/redline/engine/predicates.d.ts +73 -0
- package/dist/extensions/redline/engine/textReplace.d.ts +19 -0
- package/dist/extensions/redline/id.d.ts +7 -0
- package/dist/extensions/redline/index.d.ts +36 -0
- package/dist/extensions/redline/plugin.d.ts +34 -0
- package/dist/extensions/redline/query/scan.d.ts +52 -0
- package/dist/extensions/redline/review/applyChange.d.ts +25 -0
- package/dist/extensions/redline/review/index.d.ts +1 -0
- package/dist/extensions/redline/review/nodeResolvers.d.ts +29 -0
- package/dist/extensions/redline/review/pairedNodes.d.ts +38 -0
- package/dist/extensions/redline/review/structuralRevert.d.ts +20 -0
- package/dist/extensions/redline/review/textResolver.d.ts +9 -0
- package/dist/extensions/redline/schema/marks.d.ts +65 -0
- package/dist/extensions/redline/schema/shared.d.ts +34 -0
- package/dist/extensions/redline/session.d.ts +71 -0
- package/dist/extensions/redline/types.d.ts +24 -0
- package/dist/extensions/trackedChanges/TrackedChanges.d.ts +64 -0
- package/dist/extensions/trackedChanges/constants.d.ts +34 -0
- package/dist/extensions/trackedChanges/engine.d.ts +32 -0
- package/dist/extensions/trackedChanges/index.d.ts +13 -0
- package/dist/extensions/trackedChanges/marks.d.ts +20 -0
- package/dist/extensions/trackedChanges/normalize.d.ts +2 -0
- package/dist/extensions/trackedChanges/plugin.d.ts +32 -0
- package/dist/extensions/trackedChanges/query.d.ts +3 -0
- package/dist/extensions/trackedChanges/review.d.ts +34 -0
- package/dist/extensions/trackedChanges/types.d.ts +72 -0
- package/dist/extensions/trackedChanges/utils.d.ts +20 -0
- package/dist/hooks/useMediaQuery.d.ts +2 -0
- package/dist/hooks/useRedlineHover.d.ts +17 -0
- package/dist/hooks/useRedlineReview.d.ts +83 -0
- package/dist/index.d.ts +46 -0
- package/dist/index.es.js +38491 -22189
- package/dist/index.umd.js +224 -125
- package/dist/utils/cdts.d.ts +37 -0
- package/dist/utils/groundingAdapter.d.ts +36 -0
- package/package.json +39 -33
|
@@ -0,0 +1,291 @@
|
|
|
1
|
+
import { type BuilderRule, type CapabilityStatus, type FieldCatalogEntry, type TaxonomyNode } from "@/api/ruleBuilder";
|
|
2
|
+
import { type AuthoredRuleDraft, type AuthorExample } from "@/api/ruleAuthoring";
|
|
3
|
+
export type BuilderMode = "describe" | "examples" | "import";
|
|
4
|
+
/**
|
|
5
|
+
* A drafted rule plus where it came from and whether it is stored yet.
|
|
6
|
+
* `savedId` is what gates revise: the revise route addresses a STORED rule,
|
|
7
|
+
* so an uncommitted draft has nothing to revise against.
|
|
8
|
+
*/
|
|
9
|
+
export interface Draft {
|
|
10
|
+
origin: "text" | "examples" | "candidate";
|
|
11
|
+
rule: BuilderRule;
|
|
12
|
+
warnings: string[];
|
|
13
|
+
changes: AuthoredRuleDraft["changes"];
|
|
14
|
+
savedId: string | null;
|
|
15
|
+
}
|
|
16
|
+
export interface CandidateReview {
|
|
17
|
+
rule: BuilderRule;
|
|
18
|
+
state: "pending" | "accepted" | "rejected";
|
|
19
|
+
/** Set when the accept write failed, so the row can show why. */
|
|
20
|
+
error?: string;
|
|
21
|
+
}
|
|
22
|
+
export declare const useRuleBuilder: (initialPlaybookId?: string) => {
|
|
23
|
+
playbooks: import("zod").objectOutputType<{
|
|
24
|
+
id: import("zod").ZodString;
|
|
25
|
+
workspace_id: import("zod").ZodOptional<import("zod").ZodString>;
|
|
26
|
+
name: import("zod").ZodString;
|
|
27
|
+
regime: import("zod").ZodOptional<import("zod").ZodString>;
|
|
28
|
+
kind: import("zod").ZodOptional<import("zod").ZodString>;
|
|
29
|
+
scope: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodObject<{
|
|
30
|
+
category: import("zod").ZodOptional<import("zod").ZodString>;
|
|
31
|
+
domain: import("zod").ZodOptional<import("zod").ZodString>;
|
|
32
|
+
type: import("zod").ZodOptional<import("zod").ZodString>;
|
|
33
|
+
subtype: import("zod").ZodOptional<import("zod").ZodString>;
|
|
34
|
+
}, "passthrough", import("zod").ZodTypeAny, import("zod").objectOutputType<{
|
|
35
|
+
category: import("zod").ZodOptional<import("zod").ZodString>;
|
|
36
|
+
domain: import("zod").ZodOptional<import("zod").ZodString>;
|
|
37
|
+
type: import("zod").ZodOptional<import("zod").ZodString>;
|
|
38
|
+
subtype: import("zod").ZodOptional<import("zod").ZodString>;
|
|
39
|
+
}, import("zod").ZodTypeAny, "passthrough">, import("zod").objectInputType<{
|
|
40
|
+
category: import("zod").ZodOptional<import("zod").ZodString>;
|
|
41
|
+
domain: import("zod").ZodOptional<import("zod").ZodString>;
|
|
42
|
+
type: import("zod").ZodOptional<import("zod").ZodString>;
|
|
43
|
+
subtype: import("zod").ZodOptional<import("zod").ZodString>;
|
|
44
|
+
}, import("zod").ZodTypeAny, "passthrough">>>>;
|
|
45
|
+
version: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
46
|
+
effective_from: import("zod").ZodOptional<import("zod").ZodString>;
|
|
47
|
+
read_only: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
48
|
+
bundled: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
49
|
+
rules: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodObject<{
|
|
50
|
+
id: import("zod").ZodString;
|
|
51
|
+
playbook_id: import("zod").ZodString;
|
|
52
|
+
workspace_id: import("zod").ZodOptional<import("zod").ZodString>;
|
|
53
|
+
name: import("zod").ZodOptional<import("zod").ZodString>;
|
|
54
|
+
category: import("zod").ZodString;
|
|
55
|
+
default_severity: import("zod").ZodString;
|
|
56
|
+
verbatim_excerpt: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
57
|
+
standard_position: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
58
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
59
|
+
}, "passthrough", import("zod").ZodTypeAny, import("zod").objectOutputType<{
|
|
60
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
61
|
+
}, import("zod").ZodTypeAny, "passthrough">, import("zod").objectInputType<{
|
|
62
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
63
|
+
}, import("zod").ZodTypeAny, "passthrough">>>;
|
|
64
|
+
rationale: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
65
|
+
suggested_text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
66
|
+
authority: import("zod").ZodOptional<import("zod").ZodString>;
|
|
67
|
+
mandatory: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
68
|
+
read_only: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
69
|
+
source: import("zod").ZodOptional<import("zod").ZodString>;
|
|
70
|
+
}, "passthrough", import("zod").ZodTypeAny, import("zod").objectOutputType<{
|
|
71
|
+
id: import("zod").ZodString;
|
|
72
|
+
playbook_id: import("zod").ZodString;
|
|
73
|
+
workspace_id: import("zod").ZodOptional<import("zod").ZodString>;
|
|
74
|
+
name: import("zod").ZodOptional<import("zod").ZodString>;
|
|
75
|
+
category: import("zod").ZodString;
|
|
76
|
+
default_severity: import("zod").ZodString;
|
|
77
|
+
verbatim_excerpt: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
78
|
+
standard_position: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
79
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
80
|
+
}, "passthrough", import("zod").ZodTypeAny, import("zod").objectOutputType<{
|
|
81
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
82
|
+
}, import("zod").ZodTypeAny, "passthrough">, import("zod").objectInputType<{
|
|
83
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
84
|
+
}, import("zod").ZodTypeAny, "passthrough">>>;
|
|
85
|
+
rationale: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
86
|
+
suggested_text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
87
|
+
authority: import("zod").ZodOptional<import("zod").ZodString>;
|
|
88
|
+
mandatory: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
89
|
+
read_only: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
90
|
+
source: import("zod").ZodOptional<import("zod").ZodString>;
|
|
91
|
+
}, import("zod").ZodTypeAny, "passthrough">, import("zod").objectInputType<{
|
|
92
|
+
id: import("zod").ZodString;
|
|
93
|
+
playbook_id: import("zod").ZodString;
|
|
94
|
+
workspace_id: import("zod").ZodOptional<import("zod").ZodString>;
|
|
95
|
+
name: import("zod").ZodOptional<import("zod").ZodString>;
|
|
96
|
+
category: import("zod").ZodString;
|
|
97
|
+
default_severity: import("zod").ZodString;
|
|
98
|
+
verbatim_excerpt: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
99
|
+
standard_position: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
100
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
101
|
+
}, "passthrough", import("zod").ZodTypeAny, import("zod").objectOutputType<{
|
|
102
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
103
|
+
}, import("zod").ZodTypeAny, "passthrough">, import("zod").objectInputType<{
|
|
104
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
105
|
+
}, import("zod").ZodTypeAny, "passthrough">>>;
|
|
106
|
+
rationale: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
107
|
+
suggested_text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
108
|
+
authority: import("zod").ZodOptional<import("zod").ZodString>;
|
|
109
|
+
mandatory: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
110
|
+
read_only: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
111
|
+
source: import("zod").ZodOptional<import("zod").ZodString>;
|
|
112
|
+
}, import("zod").ZodTypeAny, "passthrough">>, "many">>;
|
|
113
|
+
}, import("zod").ZodTypeAny, "passthrough">[];
|
|
114
|
+
playbook: import("zod").objectOutputType<{
|
|
115
|
+
id: import("zod").ZodString;
|
|
116
|
+
workspace_id: import("zod").ZodOptional<import("zod").ZodString>;
|
|
117
|
+
name: import("zod").ZodString;
|
|
118
|
+
regime: import("zod").ZodOptional<import("zod").ZodString>;
|
|
119
|
+
kind: import("zod").ZodOptional<import("zod").ZodString>;
|
|
120
|
+
scope: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodObject<{
|
|
121
|
+
category: import("zod").ZodOptional<import("zod").ZodString>;
|
|
122
|
+
domain: import("zod").ZodOptional<import("zod").ZodString>;
|
|
123
|
+
type: import("zod").ZodOptional<import("zod").ZodString>;
|
|
124
|
+
subtype: import("zod").ZodOptional<import("zod").ZodString>;
|
|
125
|
+
}, "passthrough", import("zod").ZodTypeAny, import("zod").objectOutputType<{
|
|
126
|
+
category: import("zod").ZodOptional<import("zod").ZodString>;
|
|
127
|
+
domain: import("zod").ZodOptional<import("zod").ZodString>;
|
|
128
|
+
type: import("zod").ZodOptional<import("zod").ZodString>;
|
|
129
|
+
subtype: import("zod").ZodOptional<import("zod").ZodString>;
|
|
130
|
+
}, import("zod").ZodTypeAny, "passthrough">, import("zod").objectInputType<{
|
|
131
|
+
category: import("zod").ZodOptional<import("zod").ZodString>;
|
|
132
|
+
domain: import("zod").ZodOptional<import("zod").ZodString>;
|
|
133
|
+
type: import("zod").ZodOptional<import("zod").ZodString>;
|
|
134
|
+
subtype: import("zod").ZodOptional<import("zod").ZodString>;
|
|
135
|
+
}, import("zod").ZodTypeAny, "passthrough">>>>;
|
|
136
|
+
version: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
137
|
+
effective_from: import("zod").ZodOptional<import("zod").ZodString>;
|
|
138
|
+
read_only: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
139
|
+
bundled: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
140
|
+
rules: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodObject<{
|
|
141
|
+
id: import("zod").ZodString;
|
|
142
|
+
playbook_id: import("zod").ZodString;
|
|
143
|
+
workspace_id: import("zod").ZodOptional<import("zod").ZodString>;
|
|
144
|
+
name: import("zod").ZodOptional<import("zod").ZodString>;
|
|
145
|
+
category: import("zod").ZodString;
|
|
146
|
+
default_severity: import("zod").ZodString;
|
|
147
|
+
verbatim_excerpt: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
148
|
+
standard_position: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
149
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
150
|
+
}, "passthrough", import("zod").ZodTypeAny, import("zod").objectOutputType<{
|
|
151
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
152
|
+
}, import("zod").ZodTypeAny, "passthrough">, import("zod").objectInputType<{
|
|
153
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
154
|
+
}, import("zod").ZodTypeAny, "passthrough">>>;
|
|
155
|
+
rationale: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
156
|
+
suggested_text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
157
|
+
authority: import("zod").ZodOptional<import("zod").ZodString>;
|
|
158
|
+
mandatory: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
159
|
+
read_only: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
160
|
+
source: import("zod").ZodOptional<import("zod").ZodString>;
|
|
161
|
+
}, "passthrough", import("zod").ZodTypeAny, import("zod").objectOutputType<{
|
|
162
|
+
id: import("zod").ZodString;
|
|
163
|
+
playbook_id: import("zod").ZodString;
|
|
164
|
+
workspace_id: import("zod").ZodOptional<import("zod").ZodString>;
|
|
165
|
+
name: import("zod").ZodOptional<import("zod").ZodString>;
|
|
166
|
+
category: import("zod").ZodString;
|
|
167
|
+
default_severity: import("zod").ZodString;
|
|
168
|
+
verbatim_excerpt: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
169
|
+
standard_position: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
170
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
171
|
+
}, "passthrough", import("zod").ZodTypeAny, import("zod").objectOutputType<{
|
|
172
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
173
|
+
}, import("zod").ZodTypeAny, "passthrough">, import("zod").objectInputType<{
|
|
174
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
175
|
+
}, import("zod").ZodTypeAny, "passthrough">>>;
|
|
176
|
+
rationale: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
177
|
+
suggested_text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
178
|
+
authority: import("zod").ZodOptional<import("zod").ZodString>;
|
|
179
|
+
mandatory: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
180
|
+
read_only: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
181
|
+
source: import("zod").ZodOptional<import("zod").ZodString>;
|
|
182
|
+
}, import("zod").ZodTypeAny, "passthrough">, import("zod").objectInputType<{
|
|
183
|
+
id: import("zod").ZodString;
|
|
184
|
+
playbook_id: import("zod").ZodString;
|
|
185
|
+
workspace_id: import("zod").ZodOptional<import("zod").ZodString>;
|
|
186
|
+
name: import("zod").ZodOptional<import("zod").ZodString>;
|
|
187
|
+
category: import("zod").ZodString;
|
|
188
|
+
default_severity: import("zod").ZodString;
|
|
189
|
+
verbatim_excerpt: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
190
|
+
standard_position: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
191
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
192
|
+
}, "passthrough", import("zod").ZodTypeAny, import("zod").objectOutputType<{
|
|
193
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
194
|
+
}, import("zod").ZodTypeAny, "passthrough">, import("zod").objectInputType<{
|
|
195
|
+
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
196
|
+
}, import("zod").ZodTypeAny, "passthrough">>>;
|
|
197
|
+
rationale: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
198
|
+
suggested_text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
199
|
+
authority: import("zod").ZodOptional<import("zod").ZodString>;
|
|
200
|
+
mandatory: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
201
|
+
read_only: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
202
|
+
source: import("zod").ZodOptional<import("zod").ZodString>;
|
|
203
|
+
}, import("zod").ZodTypeAny, "passthrough">>, "many">>;
|
|
204
|
+
}, import("zod").ZodTypeAny, "passthrough"> | undefined;
|
|
205
|
+
playbookId: string;
|
|
206
|
+
setPlaybookId: import("react").Dispatch<import("react").SetStateAction<string>>;
|
|
207
|
+
playbooksError: string;
|
|
208
|
+
reloadPlaybooks: () => Promise<void>;
|
|
209
|
+
authoring: CapabilityStatus;
|
|
210
|
+
probeAuthoring: () => Promise<void>;
|
|
211
|
+
fieldsStatus: CapabilityStatus;
|
|
212
|
+
taxonomyStatus: CapabilityStatus;
|
|
213
|
+
reloadFields: () => Promise<void>;
|
|
214
|
+
reloadTaxonomy: () => Promise<void>;
|
|
215
|
+
predicates: import("zod").objectOutputType<{
|
|
216
|
+
kind: import("zod").ZodString;
|
|
217
|
+
description: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
218
|
+
subject: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
219
|
+
params: import("zod").ZodEffects<import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodArray<import("zod").ZodString, "many">>>, string[], string[] | null | undefined>;
|
|
220
|
+
}, import("zod").ZodTypeAny, "passthrough">[];
|
|
221
|
+
predicatesError: string;
|
|
222
|
+
reloadPredicates: () => Promise<void>;
|
|
223
|
+
fields: FieldCatalogEntry[];
|
|
224
|
+
taxonomy: TaxonomyNode[];
|
|
225
|
+
mode: BuilderMode;
|
|
226
|
+
setMode: import("react").Dispatch<import("react").SetStateAction<BuilderMode>>;
|
|
227
|
+
draft: Draft | null;
|
|
228
|
+
draftBusy: boolean;
|
|
229
|
+
draftError: string;
|
|
230
|
+
draftFromText: (text: string) => Promise<void>;
|
|
231
|
+
draftFromExamples: (examples: AuthorExample[], guidance: string) => Promise<void>;
|
|
232
|
+
reviseDraft: (instruction: string) => Promise<void>;
|
|
233
|
+
commitDraft: () => Promise<void>;
|
|
234
|
+
clearDraft: () => void;
|
|
235
|
+
candidates: CandidateReview[];
|
|
236
|
+
ingestErrors: import("zod").objectOutputType<{
|
|
237
|
+
paragraph_n: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodNumber>>;
|
|
238
|
+
problem: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
239
|
+
excerpt: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
240
|
+
}, import("zod").ZodTypeAny, "passthrough">[];
|
|
241
|
+
ingestBusy: boolean;
|
|
242
|
+
ingestError: string;
|
|
243
|
+
importDocument: (file: File) => Promise<void>;
|
|
244
|
+
acceptCandidate: (index: number, rule: BuilderRule) => Promise<void>;
|
|
245
|
+
rejectCandidate: (index: number) => void;
|
|
246
|
+
openCandidate: (candidate: BuilderRule) => void;
|
|
247
|
+
testResult: {
|
|
248
|
+
superseded: import("zod").objectOutputType<{
|
|
249
|
+
rule_id: import("zod").ZodString;
|
|
250
|
+
playbook_id: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
251
|
+
winner_rule_id: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
252
|
+
reason: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
253
|
+
authority: import("zod").ZodOptional<import("zod").ZodString>;
|
|
254
|
+
source: import("zod").ZodOptional<import("zod").ZodString>;
|
|
255
|
+
}, import("zod").ZodTypeAny, "passthrough">[];
|
|
256
|
+
rules_fired: import("zod").objectOutputType<{
|
|
257
|
+
outcome: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
258
|
+
fires: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodBoolean>>;
|
|
259
|
+
rationale: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
260
|
+
suggested_text: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
261
|
+
fallback_text: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
262
|
+
walkaway_text: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
263
|
+
text_before: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
264
|
+
text_after: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
265
|
+
category: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
266
|
+
severity: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
267
|
+
action: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
268
|
+
text_provenance: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
269
|
+
citation: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
270
|
+
playbook_id: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
271
|
+
rule_id: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
272
|
+
playbook_regime: import("zod").ZodOptional<import("zod").ZodString>;
|
|
273
|
+
verbatim_excerpt: import("zod").ZodOptional<import("zod").ZodString>;
|
|
274
|
+
}, "passthrough", import("zod").ZodTypeAny, import("zod").objectOutputType<{
|
|
275
|
+
playbook_id: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
276
|
+
rule_id: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
277
|
+
playbook_regime: import("zod").ZodOptional<import("zod").ZodString>;
|
|
278
|
+
verbatim_excerpt: import("zod").ZodOptional<import("zod").ZodString>;
|
|
279
|
+
}, import("zod").ZodTypeAny, "passthrough">, import("zod").objectInputType<{
|
|
280
|
+
playbook_id: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
281
|
+
rule_id: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodString>>;
|
|
282
|
+
playbook_regime: import("zod").ZodOptional<import("zod").ZodString>;
|
|
283
|
+
verbatim_excerpt: import("zod").ZodOptional<import("zod").ZodString>;
|
|
284
|
+
}, import("zod").ZodTypeAny, "passthrough">>>;
|
|
285
|
+
}, import("zod").ZodTypeAny, "passthrough">[];
|
|
286
|
+
} | null;
|
|
287
|
+
testBusy: boolean;
|
|
288
|
+
testError: string;
|
|
289
|
+
runTest: (clauseText: string) => Promise<void>;
|
|
290
|
+
};
|
|
291
|
+
export type RuleBuilderState = ReturnType<typeof useRuleBuilder>;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { type PlaybookApiConfig } from "@/api/playbook";
|
|
2
|
+
export interface WorkspaceRetentionPanelProps {
|
|
3
|
+
/** The workspace to keep — the `{id}` in the persist path. */
|
|
4
|
+
workspaceId: string;
|
|
5
|
+
/**
|
|
6
|
+
* Base URL / auth / caller workspace, same prop as PlaybookPanel and
|
|
7
|
+
* EffectiveRulesView. Omit when the host has already configured the module.
|
|
8
|
+
*/
|
|
9
|
+
api?: PlaybookApiConfig;
|
|
10
|
+
/** Human label for the workspace; falls back to the id. */
|
|
11
|
+
workspaceName?: string;
|
|
12
|
+
/** Inactivity window the server enforces (default 7 days). */
|
|
13
|
+
inactivityDays?: number;
|
|
14
|
+
/** Notified after a confirmed 204, e.g. to refresh a workspace list. */
|
|
15
|
+
onKept?: (workspaceId: string) => void;
|
|
16
|
+
className?: string;
|
|
17
|
+
}
|
|
18
|
+
export declare const WorkspaceRetentionPanel: ({ workspaceId, api, workspaceName, inactivityDays, onKept, className, }: WorkspaceRetentionPanelProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export interface TrackChangesContentProps {
|
|
2
|
+
onClose?: () => void;
|
|
3
|
+
}
|
|
4
|
+
/**
|
|
5
|
+
* M8 — review sidebar: pending suggestions grouped by id and author with
|
|
6
|
+
* accept / reject / bulk actions, all driven by the M4 command façade.
|
|
7
|
+
*/
|
|
8
|
+
export declare const TrackChangesContent: ({ onClose }: TrackChangesContentProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
export interface PIIAnonymizationProps {
|
|
2
2
|
onClose?: () => void;
|
|
3
3
|
}
|
|
4
|
-
export declare const PIIAnonymization: ({ onClose
|
|
4
|
+
export declare const PIIAnonymization: ({ onClose }: PIIAnonymizationProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Idle / anonymizing view (panel spec §1, §7.1–7.2): hero card, the single
|
|
3
|
+
* explicit Anonymize action with a real request state (no fake progress),
|
|
4
|
+
* and any transient banners (zero-PII, errors, restored).
|
|
5
|
+
*/
|
|
6
|
+
import type { ReactNode } from "react";
|
|
7
|
+
export interface PiiIdleViewProps {
|
|
8
|
+
anonymizing: boolean;
|
|
9
|
+
onAnonymize: () => void;
|
|
10
|
+
banners?: ReactNode;
|
|
11
|
+
}
|
|
12
|
+
export declare const PiiIdleView: ({ anonymizing, onAnonymize, banners }: PiiIdleViewProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Recovery states (panel spec §5, §7.8): the doc carries placeholders but
|
|
3
|
+
* the local vault is gone. `recovering` auto-fires GET /v1/pii/tags;
|
|
4
|
+
* 404 → counts-only summary with disabled reveals (no retry — a 404 will
|
|
5
|
+
* not improve); 503 → error banner with Retry.
|
|
6
|
+
*/
|
|
7
|
+
import type { ReactNode } from "react";
|
|
8
|
+
export interface PiiRecoveryViewProps {
|
|
9
|
+
/** "recovering" while the GET is in flight; otherwise the failure kind. */
|
|
10
|
+
phase: "recovering" | 404 | 503;
|
|
11
|
+
/** Placeholders found in the doc — the 404 counts-only summary input. */
|
|
12
|
+
placeholders: string[];
|
|
13
|
+
onRetry: () => void;
|
|
14
|
+
banners?: ReactNode;
|
|
15
|
+
}
|
|
16
|
+
export declare const PiiRecoveryView: ({ phase, placeholders, onRetry, banners }: PiiRecoveryViewProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Anonymized-summary view (panel spec §2): success banner, category groups
|
|
3
|
+
* derived from placeholder naming, per-row reveal-on-demand of originals,
|
|
4
|
+
* vault caption, Restore footer. Also reused by the recovery-404 state as a
|
|
5
|
+
* counts-only summary (no originals, reveals disabled, no Restore).
|
|
6
|
+
*/
|
|
7
|
+
import { type ReactNode } from "react";
|
|
8
|
+
export type PiiCategoryId = "person" | "organization" | "location" | "email" | "phone" | "url" | "money" | "date" | "time" | "id" | "other";
|
|
9
|
+
export declare const CATEGORY_ORDER: PiiCategoryId[];
|
|
10
|
+
export declare const CATEGORY_LABELS: Record<PiiCategoryId, string>;
|
|
11
|
+
/** Strip `[` `]`, then longest-prefix match against the service entity types. */
|
|
12
|
+
export declare function categoryForPlaceholder(placeholder: string): PiiCategoryId;
|
|
13
|
+
export interface PiiSummaryEntry {
|
|
14
|
+
placeholder: string;
|
|
15
|
+
/** Absent in the counts-only (recovery-404) rendering. */
|
|
16
|
+
original?: string;
|
|
17
|
+
}
|
|
18
|
+
export interface PiiSummaryViewProps {
|
|
19
|
+
entries: PiiSummaryEntry[];
|
|
20
|
+
/** Total items replaced (`entity_count`). Defaults to `entries.length`. */
|
|
21
|
+
entityCount?: number;
|
|
22
|
+
/** §7.4 success banner. Off in the recovery-404 counts-only rendering. */
|
|
23
|
+
showSuccessBanner?: boolean;
|
|
24
|
+
/** §7.4 vault caption. Off when no originals are stored locally. */
|
|
25
|
+
showVaultCaption?: boolean;
|
|
26
|
+
/** Recovery-404: eyes disabled, tooltip "Original not available". */
|
|
27
|
+
revealsDisabled?: boolean;
|
|
28
|
+
/** Transient banners rendered above the summary. */
|
|
29
|
+
banners?: ReactNode;
|
|
30
|
+
/** Footer "Restore original text". Omitted → no footer. */
|
|
31
|
+
onRestore?: () => void;
|
|
32
|
+
restoring?: boolean;
|
|
33
|
+
}
|
|
34
|
+
export declare const PiiSummaryView: ({ entries, entityCount, showSuccessBanner, showVaultCaption, revealsDisabled, banners, onRestore, restoring, }: PiiSummaryViewProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const PiiUnavailableView: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export type PiiConfirmAction = "restore" | "anonymize";
|
|
2
|
+
export interface RestoreConfirmDialogProps {
|
|
3
|
+
open: boolean;
|
|
4
|
+
action: PiiConfirmAction;
|
|
5
|
+
pendingCount: number;
|
|
6
|
+
onCancel: () => void;
|
|
7
|
+
onConfirm: () => void;
|
|
8
|
+
}
|
|
9
|
+
export declare const RestoreConfirmDialog: ({ open, ...rest }: RestoreConfirmDialogProps) => import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -1,24 +1,45 @@
|
|
|
1
1
|
import type { Editor } from "@tiptap/react";
|
|
2
|
-
import type {
|
|
3
|
-
export declare function setShowValue(editor: Editor, showValue: boolean, filter?: Set<string>): void;
|
|
2
|
+
import type { PiiVault } from "./piiVault";
|
|
4
3
|
/**
|
|
5
4
|
* Replace `anonymizedLink` marks in the document with the editor's default
|
|
6
|
-
* `link` mark
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
5
|
+
* `link` mark, restoring the original URL from the VAULT (post-scrub docs
|
|
6
|
+
* carry no original values in `anonymizedData` — the vault is the only
|
|
7
|
+
* source). Marks whose placeholder is not in the vault are left untouched so
|
|
8
|
+
* they stay recoverable. `target` / `rel` / `class` are carried over.
|
|
10
9
|
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
10
|
+
* Dispatched with `addToHistory: false` — restore must not enter the undo
|
|
11
|
+
* stack (collab disables UndoRedo; the repo's programmatic-change idiom).
|
|
13
12
|
*/
|
|
14
|
-
export declare function revertAnonymizedLinksToLinks(editor: Editor,
|
|
15
|
-
export declare function revertToPlainText(editor: Editor, filter?: Set<string>): void;
|
|
16
|
-
export declare function buildTagsFromEditor(editor: Editor): Record<string, ApiTagEntry[]>;
|
|
17
|
-
export type AnonymizedVariableRevealState = 'placeholder' | 'revealed';
|
|
13
|
+
export declare function revertAnonymizedLinksToLinks(editor: Editor, vault: PiiVault): void;
|
|
18
14
|
/**
|
|
19
|
-
*
|
|
20
|
-
*
|
|
15
|
+
* Replace `anonymizedText` nodes with their original plain text, read from
|
|
16
|
+
* the VAULT keyed by the node's placeholder (post-scrub attrs carry no
|
|
17
|
+
* `value`). Nodes whose placeholder is missing from the vault are left
|
|
18
|
+
* untouched so they stay recoverable. Byte-identical to the vault values.
|
|
19
|
+
*
|
|
20
|
+
* Dispatched with `addToHistory: false` (see revertAnonymizedLinksToLinks).
|
|
21
|
+
*/
|
|
22
|
+
export declare function revertToPlainText(editor: Editor, vault: PiiVault): void;
|
|
23
|
+
/**
|
|
24
|
+
* Clear the PII flags on `variableText` nodes (see `setVariablePii` in
|
|
25
|
+
* extensions/VariableText.ts) so they render their `value` again. A masked
|
|
26
|
+
* variable keeps its own `value` attr, so unlike the two helpers above this
|
|
27
|
+
* does not depend on the vault — but when the vault holds the node's
|
|
28
|
+
* placeholder, that entry wins (the backend may have scrubbed the value).
|
|
29
|
+
*
|
|
30
|
+
* Dispatched with `addToHistory: false` (see revertAnonymizedLinksToLinks).
|
|
31
|
+
*/
|
|
32
|
+
export declare function revertVariablePii(editor: Editor, vault: PiiVault): void;
|
|
33
|
+
/**
|
|
34
|
+
* Whether a serialized doc (`editor.getJSON()`) carries anonymization:
|
|
35
|
+
* any `anonymizedText` node, PII-flagged `variableText` node, or
|
|
36
|
+
* `anonymizedLink` mark.
|
|
37
|
+
*/
|
|
38
|
+
export declare function isDocAnonymized(docJson: Record<string, unknown>): boolean;
|
|
39
|
+
/**
|
|
40
|
+
* Unique placeholders present in a serialized doc — `anonymizedText` and
|
|
41
|
+
* PII-flagged `variableText` `placeholder` attrs plus `anonymizedLink`
|
|
42
|
+
* `anonymizedVariable`s. Used by the recovery view to render a counts-only
|
|
43
|
+
* summary when the vault is gone.
|
|
21
44
|
*/
|
|
22
|
-
export declare function
|
|
23
|
-
revealState?: AnonymizedVariableRevealState;
|
|
24
|
-
}): Set<string>;
|
|
45
|
+
export declare function collectDocPlaceholders(docJson: Record<string, unknown>): string[];
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Per-document PII vault, persisted in localStorage (same fail-soft pattern
|
|
3
|
+
* as `components/redline/reviewPrefs.ts`).
|
|
4
|
+
*
|
|
5
|
+
* lax.piiVault.{documentId} JSON Record<string, string> — the flat
|
|
6
|
+
* placeholder → original map returned by
|
|
7
|
+
* POST /v1/pii/anonymize. This is the ONLY
|
|
8
|
+
* client-side home of original values; the
|
|
9
|
+
* document itself carries none post-scrub.
|
|
10
|
+
*
|
|
11
|
+
* All helpers fail soft (SSR / privacy mode): reads return null, writes are
|
|
12
|
+
* best-effort. When the vault is gone, the panel recovers it via
|
|
13
|
+
* GET /v1/pii/tags/{document_id}.
|
|
14
|
+
*/
|
|
15
|
+
export type PiiVault = Record<string, string>;
|
|
16
|
+
export declare const loadPiiVault: (documentId: string) => PiiVault | null;
|
|
17
|
+
export declare const savePiiVault: (documentId: string, tags: PiiVault) => void;
|
|
18
|
+
export declare const clearPiiVault: (documentId: string) => void;
|
|
@@ -4,4 +4,3 @@ export { AddElementContent, type AddElementContentProps } from './AddElementCont
|
|
|
4
4
|
export { ShareDocumentContent, type ShareDocumentContentProps } from './ShareDocumentContent';
|
|
5
5
|
export { ImageContent, type ImageContentProps, type ImageData } from './ImageContent';
|
|
6
6
|
export { PIIAnonymization, type PIIAnonymizationProps } from './anonymization-page/PIIAnonymization';
|
|
7
|
-
export { AnonymizationSettings, type AnonymizationSettingsProps } from './anonymization-page/AnonymizationSettings';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const AutocompletionToggle: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const TrackChangesCards: () => import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export declare const TRACK_CHANGES_CARD_WIDTH = 300;
|
|
2
|
+
export declare const TRACK_CHANGES_CARD_GUTTER = 16;
|
|
3
|
+
export declare const TRACK_CHANGES_CARDS_WIDTH: number;
|
|
4
|
+
/** "just now" / "5m ago" / "3h ago", falling back to a short date. */
|
|
5
|
+
export declare function relativeTime(createdAt: number | null): string;
|