@mindbill/react 0.9.2 → 0.9.4

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 CHANGED
@@ -56,6 +56,8 @@ This is the minimum safe browser integration. A permanent Partner API key must n
56
56
 
57
57
  `BillReviewForm` is the native, controlled review surface. Known bill values and payer documents remain explicit and editable before submission.
58
58
 
59
+ When you use `ConnectedBillLifecycle`, payer selection is batteries-included: the component searches MindBill's claims-administrator directory, sends the current claim number for pattern matching, explains name and claim-number evidence, shows delivery availability, and only preselects a high-confidence exact name or alias match. For a controlled `BillReviewForm`, provide the same behavior with `onSearchClaimsAdministrators={(query, claimNumber) => ...}`; return `BillReviewPayer` records with optional `confidence`, `recommended`, and `signals` fields.
60
+
59
61
  ```tsx
60
62
  import { BillReviewForm } from "@mindbill/react";
61
63
 
package/dist/index.d.ts CHANGED
@@ -67,9 +67,25 @@ type BillReviewPayer = {
67
67
  name: string;
68
68
  hasElectronic?: boolean;
69
69
  states?: string[];
70
+ confidence?: "high" | "medium" | "directory";
71
+ recommended?: boolean;
72
+ signals?: Array<{
73
+ kind: "name" | "claim_number";
74
+ state: "match" | "warning";
75
+ label: string;
76
+ }>;
70
77
  };
71
78
  type BillReviewFeatures = {
72
79
  authorizationNumber?: boolean;
80
+ serviceDateRange?: boolean;
81
+ wcabNumber?: boolean;
82
+ codingPresets?: boolean;
83
+ };
84
+ type BillReviewClaimPatternStatus = {
85
+ state: "match" | "warning" | "unknown";
86
+ label: string;
87
+ detail?: string;
88
+ suggestion?: string;
73
89
  };
74
90
  type BillReviewData = {
75
91
  bill: {
@@ -96,14 +112,21 @@ type BillReviewData = {
96
112
  };
97
113
  patient: {
98
114
  name: string;
115
+ firstName?: string;
116
+ middleName?: string;
117
+ lastName?: string;
99
118
  dob?: string;
100
119
  };
101
120
  injury: {
102
121
  claimNumber?: string;
103
122
  employer?: string;
104
123
  doi?: string;
124
+ injuryEndDate?: string;
125
+ cumulativeTrauma?: boolean;
126
+ adjNumber?: string;
105
127
  claimsAdminId?: string;
106
128
  claimsAdminName?: string;
129
+ claimPatternStatus?: BillReviewClaimPatternStatus;
107
130
  };
108
131
  options?: {
109
132
  billingProviders?: BillReviewBillingProvider[];
@@ -113,6 +136,20 @@ type BillReviewData = {
113
136
  };
114
137
  type BillReviewSaveInput = {
115
138
  claimsAdminId: string;
139
+ patientOverrides?: {
140
+ firstName: string;
141
+ middleName?: string;
142
+ lastName: string;
143
+ dob?: string;
144
+ };
145
+ injuryOverrides?: {
146
+ claimNumber?: string;
147
+ employer?: string;
148
+ doi?: string;
149
+ injuryEndDate?: string;
150
+ cumulativeTrauma?: boolean;
151
+ adjNumber?: string;
152
+ };
116
153
  dos: string;
117
154
  dosEnd?: string | null;
118
155
  authorizationNumber?: string | null;
@@ -137,7 +174,7 @@ type BillReviewFormProps = {
137
174
  onAddAttachment: (file: File, documentType: BillReviewDocumentType, description?: string) => Promise<void>;
138
175
  onRemoveAttachment: (attachmentId: string) => Promise<void>;
139
176
  onOpenAttachment?: (attachment: BillReviewAttachment) => void;
140
- onSearchClaimsAdministrators?: (query: string) => Promise<BillReviewPayer[]>;
177
+ onSearchClaimsAdministrators?: (query: string, claimNumber?: string) => Promise<BillReviewPayer[]>;
141
178
  className?: string;
142
179
  style?: CSSProperties;
143
180
  appearance?: MindBillAppearance;
@@ -147,6 +184,16 @@ type BillReviewFormProps = {
147
184
  type BillReviewDraft = {
148
185
  claimsAdminId: string;
149
186
  claimsAdminName: string;
187
+ patientFirstName: string;
188
+ patientMiddleName: string;
189
+ patientLastName: string;
190
+ patientDob: string;
191
+ claimNumber: string;
192
+ employer: string;
193
+ doi: string;
194
+ injuryEndDate: string;
195
+ cumulativeTrauma: boolean;
196
+ adjNumber: string;
150
197
  dos: string;
151
198
  dosEnd: string;
152
199
  authorizationNumber: string;
@@ -307,7 +354,7 @@ type BillLifecycleClientOptions = {
307
354
  };
308
355
  type BillLifecycleClient = {
309
356
  getLifecycle: (signal?: AbortSignal) => Promise<BillLifecycleData>;
310
- searchClaimsAdministrators: (query: string) => Promise<BillReviewPayer[]>;
357
+ searchClaimsAdministrators: (query: string, claimNumber?: string) => Promise<BillReviewPayer[]>;
311
358
  saveReview: (input: BillReviewSaveInput) => Promise<BillLifecycleData>;
312
359
  submitBill: (input: BillReviewSaveInput, route: BillSubmissionRoute) => Promise<BillLifecycleData>;
313
360
  addAttachment: (file: File, documentType: BillReviewDocumentType, description?: string) => Promise<BillLifecycleData>;