mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-15 06:52:04 +00:00
feat(documents): share document picker, clinician document list, mobile QR
This commit is contained in:
1 parent
9ff39b5846
commit
fdc0f83a47
12 files changed
+649
-17
No files matched your search
@@ -125,6 +125,7 @@ describe("loadShareViewData — KVNR default OFF", () => {
|
||||
kind: "LAB_REPORT",
|
||||
documentDate: "2026-01-15",
|
||||
byteSize: 12345,
|
||||
mimeType: "application/pdf",
|
||||
servingClass: "inline",
|
||||
},
|
||||
{
|
||||
@@ -133,6 +134,7 @@ describe("loadShareViewData — KVNR default OFF", () => {
|
||||
kind: "OTHER",
|
||||
documentDate: null,
|
||||
byteSize: 6789,
|
||||
mimeType: "application/msword",
|
||||
servingClass: "attachment",
|
||||
},
|
||||
]);
|
||||
|
||||
@@ -36,6 +36,13 @@ export interface ShareViewDocument {
|
||||
/** Filing date (YYYY-MM-DD at UTC) or null. */
|
||||
documentDate: string | null;
|
||||
byteSize: number;
|
||||
/**
|
||||
* The stored content type (metadata, never bytes). The recipient view uses
|
||||
* it to pick the inline surface — an image tag for `image/*`, a framed PDF
|
||||
* for `application/pdf` — within the Class A carve-out. Class B types are
|
||||
* download-only regardless.
|
||||
*/
|
||||
mimeType: string;
|
||||
servingClass: DocumentServingClass;
|
||||
}
|
||||
|
||||
@@ -119,6 +126,7 @@ async function loadShareDocuments(
|
||||
? document.documentDate.toISOString().slice(0, 10)
|
||||
: null,
|
||||
byteSize: document.byteSize,
|
||||
mimeType: document.mimeType,
|
||||
servingClass: servingClassFor(document.mimeType),
|
||||
}));
|
||||
}
|
||||
Reference in new issue
Block a user