uhc-portal-components-react 0.2.1 → 0.2.3
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/CHANGELOG.md +20 -0
- package/dist/ClinicalActionButton.d.ts.map +1 -1
- package/dist/ClinicalActionButton.js +1 -1
- package/dist/ClinicalArtifactEditorV2.d.ts +1 -0
- package/dist/ClinicalArtifactEditorV2.d.ts.map +1 -1
- package/dist/ClinicalArtifactEditorV2.js +2 -2
- package/dist/ClinicalArtifactPropertiesV2.d.ts +1 -0
- package/dist/ClinicalArtifactPropertiesV2.d.ts.map +1 -1
- package/dist/ClinicalArtifactPropertiesV2.js +5 -2
- package/dist/ClinicalBundleDraftEditor.d.ts +6 -1
- package/dist/ClinicalBundleDraftEditor.d.ts.map +1 -1
- package/dist/ClinicalBundleDraftEditor.js +15 -6
- package/dist/ProfileProtectionGateV2.d.ts +2 -1
- package/dist/ProfileProtectionGateV2.d.ts.map +1 -1
- package/dist/ProfileProtectionGateV2.js +6 -2
- package/dist/styles.css +19 -9
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,26 @@
|
|
|
2
2
|
|
|
3
3
|
## Unreleased
|
|
4
4
|
|
|
5
|
+
## 0.2.3 - 2026-10-09
|
|
6
|
+
|
|
7
|
+
- Keep the section-removal action at the far edge of its section while still
|
|
8
|
+
exposing the same hover and keyboard-focus hint as other icon actions.
|
|
9
|
+
|
|
10
|
+
## 0.2.2 - 2026-10-09
|
|
11
|
+
|
|
12
|
+
- Name the exact localized FHIR resource in the V2 editor heading without a
|
|
13
|
+
redundant resource-type subtitle.
|
|
14
|
+
- Keep terminology candidates in the existing selection dropdown and report a
|
|
15
|
+
successful zero-result search explicitly, clearing stale results whenever
|
|
16
|
+
the query or governed coding-system selection changes.
|
|
17
|
+
- Give the V2 profile-unlock panel an explicit light/dark accent surface and
|
|
18
|
+
support PIN-recovery actions inside the PIN fallback only after a rejected
|
|
19
|
+
PIN, while keeping unrelated profile actions separate.
|
|
20
|
+
- Use compact, accessible add/remove section actions with destructive
|
|
21
|
+
confirmation, semantic action colours and matching hover/focus hints.
|
|
22
|
+
- Let hosts place downloads, credential generation and update metadata in the
|
|
23
|
+
same responsive document footer as the final submit action.
|
|
24
|
+
|
|
5
25
|
## 0.2.1 - 2026-10-08
|
|
6
26
|
|
|
7
27
|
- Add the opt-in `ProfileProtectionGateV2`, which identifies the exact
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ClinicalActionButton.d.ts","sourceRoot":"","sources":["../src/ClinicalActionButton.tsx"],"names":[],"mappings":"AAAA,MAAM,MAAM,kBAAkB,GAAG,KAAK,GAAG,MAAM,GAAG,QAAQ,CAAA;AAE1D,sFAAsF;AACtF,wBAAgB,oBAAoB,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,QAAgB,EAAE,OAAO,EAAE,EAAE,QAAQ,CAAC;IACxF,IAAI,EAAE,kBAAkB,CAAA;IACxB,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,OAAO,EAAE,MAAM,IAAI,CAAA;CACpB,CAAC,+
|
|
1
|
+
{"version":3,"file":"ClinicalActionButton.d.ts","sourceRoot":"","sources":["../src/ClinicalActionButton.tsx"],"names":[],"mappings":"AAAA,MAAM,MAAM,kBAAkB,GAAG,KAAK,GAAG,MAAM,GAAG,QAAQ,CAAA;AAE1D,sFAAsF;AACtF,wBAAgB,oBAAoB,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,QAAgB,EAAE,OAAO,EAAE,EAAE,QAAQ,CAAC;IACxF,IAAI,EAAE,kBAAkB,CAAA;IACxB,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,OAAO,EAAE,MAAM,IAAI,CAAA;CACpB,CAAC,+BAUD"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
/** Compact clinical action; authorization and callback behavior remain host-owned. */
|
|
3
3
|
export function ClinicalActionButton({ kind, label, disabled = false, onClick }) {
|
|
4
|
-
return _jsx("button", { type: "button", className: `uhcp-clinical-icon-action uhcp-clinical-icon-action-${kind}`, "aria-label": label, title: label, disabled: disabled, onClick: onClick, children: _jsx(ActionIcon, { kind: kind }) });
|
|
4
|
+
return _jsx("button", { type: "button", className: `uhcp-clinical-icon-action uhcp-clinical-icon-action-${kind}`, "aria-label": label, title: label, "data-tooltip": label, disabled: disabled, onClick: onClick, children: _jsx(ActionIcon, { kind: kind }) });
|
|
5
5
|
}
|
|
6
6
|
function ActionIcon({ kind }) {
|
|
7
7
|
if (kind === 'add')
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ClinicalArtifactEditorV2.d.ts","sourceRoot":"","sources":["../src/ClinicalArtifactEditorV2.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,kDAAkD,CAAA;AAGlG,OAAO,EAOL,KAAK,wBAAwB,EAC9B,MAAM,mCAAmC,CAAA;AAC1C,OAAO,KAAK,EAEV,gCAAgC,EAChC,qBAAqB,EACrB,6BAA6B,EAC7B,2BAA2B,EAC3B,4BAA4B,EAC5B,yBAAyB,EACzB,+BAA+B,EAChC,MAAM,6BAA6B,CAAA;AAEpC,MAAM,MAAM,8BAA8B,GAAG,QAAQ,CAAC;IACpD,OAAO,EAAE,MAAM,CAAA;IACf,YAAY,EAAE,MAAM,CAAA;IACpB,MAAM,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAA;IACxC,WAAW,CAAC,EAAE,MAAM,CAAA;CACrB,CAAC,CAAA;AAEF,MAAM,MAAM,uBAAuB,GAAG,qBAAqB,GAAG,QAAQ,CAAC;IACrE,cAAc,CAAC,EAAE,SAAS,8BAA8B,EAAE,CAAA;CAC3D,CAAC,CAAA;AAEF,MAAM,MAAM,uBAAu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AAE,MAAM,CAAC,CAAC,KAAK,IAAI,CAAA;IAC7D,mBAAmB,CAAC,EAAE,CAAC,MAAM,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,EAAE,OAAO,EAAE,MAAM,KAAK,SAAS,8BAA8B,EAAE,CAAA;IAC9H,YAAY,EAAE,CAAC,KAAK,EAAE,uBAAuB,KAAK,OAAO,CAAC,0BAA0B,GAAG,2BAA2B,GAAG,SAAS,CAAC,CAAA;IAC/H,QAAQ,EAAE,MAAM,IAAI,CAAA;IACpB,UAAU,EAAE,CAAC,MAAM,EAAE,0BAA0B,KAAK,IAAI,CAAA;CACzD,CAAC,CAAA;AAEF,0FAA0F;AAC1F,wBAAgB,wBAAwB,CAAC,EAAE,OAAO,EAAE,gBAAgB,EAAE,IAAI,EAAE,MAAM,EAAE,oBAAoB,EAAE,aAAkB,EAAE,MAAa,EAAE,QAA2D,EAAE,UAAU,EAAE,UAAU,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,sBAAsB,EAAE,QAAQ,EAAE,mBAAmB,EAAE,YAAY,EAAE,QAAQ,EAAE,UAAU,EAAE,EAAE,6BAA6B,+BAyDjY"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
import {
|
|
2
|
+
import { jsxs as _jsxs, jsx as _jsx } from "react/jsx-runtime";
|
|
3
3
|
import { useId, useRef, useState } from 'react';
|
|
4
4
|
import { ClinicalEditorLayer } from './ClinicalEditorLayer.js';
|
|
5
5
|
import { readClinicalAttachment } from './ClinicalArtifactEditor.js';
|
|
@@ -54,7 +54,7 @@ export function ClinicalArtifactEditorV2({ request, authoringContext, copy, fiel
|
|
|
54
54
|
setSaving(false);
|
|
55
55
|
}
|
|
56
56
|
}
|
|
57
|
-
return _jsx(ClinicalEditorLayer, { onDismiss: onCancel, children: _jsxs("section", { className: "uhcp-clinical-editor uhcp-clinical-editor-v2", role: "dialog", "aria-modal": "true", "aria-labelledby": titleId, children: [_jsxs("header", { children: [_jsxs("div", { children: [
|
|
57
|
+
return _jsx(ClinicalEditorLayer, { onDismiss: onCancel, children: _jsxs("section", { className: "uhcp-clinical-editor uhcp-clinical-editor-v2", role: "dialog", "aria-modal": "true", "aria-labelledby": titleId, children: [_jsxs("header", { children: [_jsxs("div", { children: [_jsxs("h2", { id: titleId, children: [copy.title, " ", resourceTypeLabel || request.resourceType] }), _jsx("p", { children: copy.description })] }), _jsx("button", { type: "button", "aria-label": copy.close, onClick: onCancel, children: "\u00D7" })] }), _jsxs("form", { onSubmit: event => { event.preventDefault(); void submit(); }, children: [fields.filter(field => visibleClaims.includes(field.claim)).map(field => _jsxs("div", { className: "uhcp-progressive-field-v2", children: [!field.required ? _jsx("button", { type: "button", className: "uhcp-remove-field-v2", "aria-label": `${copy.removeField}: ${fieldLabel(field.claim)}`, onClick: () => { setVisibleClaims(current => current.filter(claim => claim !== field.claim)); if (field.kind === 'documents')
|
|
58
58
|
setAttachments([]); setClaims(current => { const next = { ...current }; delete next[field.claim]; if (field.codeClaim)
|
|
59
59
|
delete next[field.codeClaim]; if (field.displayClaim)
|
|
60
60
|
delete next[field.displayClaim]; return next; }); }, children: "\u00D7" }) : null, field.kind === 'documents' ? _jsx(DocumentReferencesPropertyV2, { copy: copy, attachments: attachments, onFiles: files => { void Promise.all(files.map(readClinicalAttachment)).then(next => setAttachments(current => [...current, ...next])).catch(reason => setError(reason instanceof Error ? reason.message : String(reason))); }, onRemove: id => setAttachments(current => current.filter(attachment => attachment.id !== id)) })
|
|
@@ -33,6 +33,7 @@ export declare function CodedConceptPropertyV2({ resourceType, textClaim, codeCl
|
|
|
33
33
|
searchTerminology: string;
|
|
34
34
|
terminologyLoading: string;
|
|
35
35
|
terminologyUnavailable: string;
|
|
36
|
+
terminologyEmpty?: string;
|
|
36
37
|
terminologySources: string;
|
|
37
38
|
selectCandidate: string;
|
|
38
39
|
clearCoding: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"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,IAAI,CAAA;CAAE,CAAC,sCAG9Q;AAED,wBAAgB,4BAA4B,CAAC,EAAE,IAAI,EAAE,WAAW,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,QAAQ,CAAC;IAC9F,IAAI,EAAE,QAAQ,CAAC;QAAE,SAAS,EAAE,MAAM,CAAC;QAAC,YAAY,EAAE,MAAM,CAAC;QAAC,cAAc,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;IACnF,WAAW,EAAE,SAAS,0BAA0B,EAAE,CAAA;IAClD,OAAO,EAAE,CAAC,KAAK,EAAE,SAAS,IAAI,EAAE,KAAK,IAAI,CAAA;IACzC,QAAQ,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAA;CAC/B,CAAC,+BAKD"}
|
|
@@ -19,6 +19,7 @@ export function CodedConceptPropertyV2({ resourceType, textClaim, codeClaim, dis
|
|
|
19
19
|
const [candidates, setCandidates] = useState([]);
|
|
20
20
|
const [busy, setBusy] = useState(false);
|
|
21
21
|
const [failed, setFailed] = useState(false);
|
|
22
|
+
const [searched, setSearched] = useState(false);
|
|
22
23
|
useEffect(() => {
|
|
23
24
|
if (!loadTerminologySources)
|
|
24
25
|
return;
|
|
@@ -38,6 +39,7 @@ export function CodedConceptPropertyV2({ resourceType, textClaim, codeClaim, dis
|
|
|
38
39
|
return;
|
|
39
40
|
setBusy(true);
|
|
40
41
|
setFailed(false);
|
|
42
|
+
setSearched(false);
|
|
41
43
|
try {
|
|
42
44
|
let governedSources = selectedSources;
|
|
43
45
|
if (!governedSources.length && loadTerminologySources) {
|
|
@@ -48,6 +50,7 @@ export function CodedConceptPropertyV2({ resourceType, textClaim, codeClaim, dis
|
|
|
48
50
|
setSelectedSources(governedSources);
|
|
49
51
|
}
|
|
50
52
|
setCandidates(await searchTerminology({ resourceType, claim: codeClaim, language: locale, text: query.trim(), taxonomyId, limit: 20, ...(governedSources.length ? { sources: governedSources } : {}) }));
|
|
53
|
+
setSearched(true);
|
|
51
54
|
}
|
|
52
55
|
catch {
|
|
53
56
|
setCandidates([]);
|
|
@@ -57,7 +60,7 @@ export function CodedConceptPropertyV2({ resourceType, textClaim, codeClaim, dis
|
|
|
57
60
|
setBusy(false);
|
|
58
61
|
}
|
|
59
62
|
};
|
|
60
|
-
return _jsxs("div", { className: "uhcp-clinical-property-v2 uhcp-coded-concept-property-v2", children: [_jsxs("span", { className: "uhcp-clinical-editor-field-heading", children: [_jsxs("label", { htmlFor: `${codeClaim}-query`, children: [label, required ? ' *' : ''] }), textClaim ? _jsx(ClinicalSpeechInputButton, { resourceType: resourceType, claim: textClaim, locale: locale, fieldLabel: label, onTranscript: transcript => { setQuery(transcript); onChange({ text: transcript, code: '', display: '' }); } }) : null] }), _jsxs("div", { className: "uhcp-coded-concept-query-v2", children: [_jsx("input", { id: `${codeClaim}-query`, "aria-label": label, required: required, readOnly: Boolean(code), value: code ? (text || query || display) : query, onChange: event => { setQuery(event.currentTarget.value); onChange({ text: event.currentTarget.value, code: '', display: '' }); } }), _jsx("button", { type: "button", className: "uhcp-icon-button-v2", "aria-label": copy.searchTerminology, title: copy.searchTerminology, disabled: Boolean(code) || busy || query.trim().length < 2, onClick: () => void search(), children: _jsx("svg", { "aria-hidden": "true", viewBox: "0 0 24 24", children: _jsx("path", { d: "m21 21-4.35-4.35m1.35-5.65a7 7 0 1 1-14 0 7 7 0 0 1 14 0Z" }) }) }), code ? _jsx("button", { type: "button", className: "uhcp-clear-code-v2", "aria-label": copy.clearCoding, title: copy.clearCoding, onClick: () => { setQuery(''); setCandidates([]); onChange({ text: '', code: '', display: '' }); }, children: "\u00D7" }) : null] }), sources.length ? _jsxs("fieldset", { className: "uhcp-coding-sources-v2", children: [_jsx("legend", { children: copy.terminologySources }), sources.map(source => _jsxs("label", { children: [_jsx("input", { type: "checkbox", checked: selectedSources.includes(source.id), onChange: event =>
|
|
63
|
+
return _jsxs("div", { className: "uhcp-clinical-property-v2 uhcp-coded-concept-property-v2", children: [_jsxs("span", { className: "uhcp-clinical-editor-field-heading", children: [_jsxs("label", { htmlFor: `${codeClaim}-query`, children: [label, required ? ' *' : ''] }), textClaim ? _jsx(ClinicalSpeechInputButton, { resourceType: resourceType, claim: textClaim, locale: locale, fieldLabel: label, onTranscript: transcript => { setQuery(transcript); onChange({ text: transcript, code: '', display: '' }); } }) : null] }), _jsxs("div", { className: "uhcp-coded-concept-query-v2", children: [_jsx("input", { id: `${codeClaim}-query`, "aria-label": label, required: required, readOnly: Boolean(code), value: code ? (text || query || display) : query, onChange: event => { setQuery(event.currentTarget.value); setCandidates([]); setSearched(false); setFailed(false); onChange({ text: event.currentTarget.value, code: '', display: '' }); } }), _jsx("button", { type: "button", className: "uhcp-icon-button-v2", "aria-label": copy.searchTerminology, title: copy.searchTerminology, disabled: Boolean(code) || busy || query.trim().length < 2, onClick: () => void search(), children: _jsx("svg", { "aria-hidden": "true", viewBox: "0 0 24 24", children: _jsx("path", { d: "m21 21-4.35-4.35m1.35-5.65a7 7 0 1 1-14 0 7 7 0 0 1 14 0Z" }) }) }), code ? _jsx("button", { type: "button", className: "uhcp-clear-code-v2", "aria-label": copy.clearCoding, title: copy.clearCoding, onClick: () => { setQuery(''); setCandidates([]); onChange({ text: '', code: '', display: '' }); }, children: "\u00D7" }) : null] }), sources.length ? _jsxs("fieldset", { className: "uhcp-coding-sources-v2", children: [_jsx("legend", { children: copy.terminologySources }), sources.map(source => _jsxs("label", { children: [_jsx("input", { type: "checkbox", checked: selectedSources.includes(source.id), onChange: event => { const checked = event.currentTarget.checked; setSelectedSources(current => checked ? [...new Set([...current, source.id])] : current.filter(value => value !== source.id)); setCandidates([]); setSearched(false); setFailed(false); } }), source.label || source.id] }, source.id))] }) : null, busy ? _jsx("small", { role: "status", children: copy.terminologyLoading }) : null, failed ? _jsx("small", { role: "alert", children: copy.terminologyUnavailable }) : null, searched && !busy && !failed && candidates.length === 0 ? _jsx("small", { role: "status", children: copy.terminologyEmpty || copy.terminologyUnavailable }) : null, candidates.length ? _jsxs("label", { children: [copy.selectCandidate, _jsxs("select", { "aria-label": copy.selectCandidate, value: selectedToken, onChange: event => {
|
|
61
64
|
const candidate = candidates.find(value => `${value.system}|${value.code}` === event.currentTarget.value);
|
|
62
65
|
if (!candidate)
|
|
63
66
|
return;
|
|
@@ -65,7 +68,7 @@ export function CodedConceptPropertyV2({ resourceType, textClaim, codeClaim, dis
|
|
|
65
68
|
setQuery(localText);
|
|
66
69
|
onChange({ text: localText, code: `${candidate.system}|${candidate.code}`, display: candidate.display });
|
|
67
70
|
setCandidates([]);
|
|
68
|
-
}, children: [_jsx("option", { value: "" }), candidates.map(candidate => _jsxs("option", { value: `${candidate.system}|${candidate.code}`, children: [candidate.display, " (", candidate.code, ")"] }, `${candidate.system}|${candidate.code}`))] })] }) : null, code ? _jsxs("div", { className: "uhcp-selected-code-v2", children: [_jsxs("label", { children: [copy.canonicalCode, _jsx("input", { "aria-label": copy.canonicalCode, readOnly: true, value: code })] }), _jsxs("label", { children: [copy.canonicalDisplay, _jsx("input", { "aria-label": copy.canonicalDisplay, readOnly: true, value: display })] })] }) : null] });
|
|
71
|
+
}, children: [_jsx("option", { value: "" }), candidates.map(candidate => _jsxs("option", { value: `${candidate.system}|${candidate.code}`, children: [candidate.text && candidate.text !== candidate.display ? `${candidate.text} — ${candidate.display}` : candidate.display, " (", candidate.code, ")"] }, `${candidate.system}|${candidate.code}`))] })] }) : null, code ? _jsxs("div", { className: "uhcp-selected-code-v2", children: [_jsxs("label", { children: [copy.canonicalCode, _jsx("input", { "aria-label": copy.canonicalCode, readOnly: true, value: code })] }), _jsxs("label", { children: [copy.canonicalDisplay, _jsx("input", { "aria-label": copy.canonicalDisplay, readOnly: true, value: display })] })] }) : null] });
|
|
69
72
|
}
|
|
70
73
|
export function CodedSelectPropertyV2({ label, value, required, options, onChange }) {
|
|
71
74
|
return _jsxs("label", { className: "uhcp-clinical-property-v2", children: [label, required ? ' *' : '', _jsxs("select", { "aria-label": label, required: required, value: value, onChange: event => onChange(event.currentTarget.value), children: [_jsx("option", { value: "" }), options.map(option => _jsx("option", { value: option.value, children: option.label }, option.value))] })] });
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { type ReactNode } from 'react';
|
|
1
2
|
import 'gdc-common-utils-ts/utils/allergy-intolerance-entry-editor';
|
|
2
3
|
import 'gdc-common-utils-ts/utils/condition-entry-editor';
|
|
3
4
|
import 'gdc-common-utils-ts/utils/document-reference-entry-editor';
|
|
@@ -33,6 +34,8 @@ export type ClinicalBundleDraftEditorCopy = Readonly<{
|
|
|
33
34
|
resourceType?: string;
|
|
34
35
|
addSection?: string;
|
|
35
36
|
addEntry?: string;
|
|
37
|
+
removeSection?: string;
|
|
38
|
+
removeSectionConfirm?: string;
|
|
36
39
|
chooseResource?: string;
|
|
37
40
|
edit: string;
|
|
38
41
|
remove: string;
|
|
@@ -72,6 +75,8 @@ export type ClinicalBundleDraftEditorProps = Readonly<{
|
|
|
72
75
|
bundle: ClinicalBundleDraft;
|
|
73
76
|
}>) => void;
|
|
74
77
|
}>;
|
|
78
|
+
/** Host-owned document actions rendered beside the final submit action. */
|
|
79
|
+
documentActions?: ReactNode;
|
|
75
80
|
}>;
|
|
76
81
|
type StagedArtifact = Readonly<{
|
|
77
82
|
schema: ClinicalBundleDraftSchema;
|
|
@@ -84,7 +89,7 @@ type StagedArtifact = Readonly<{
|
|
|
84
89
|
* It owns no authorization or persistence: the host supplies subject and
|
|
85
90
|
* provenance and only `onSubmitDraft` may cross a persistence boundary.
|
|
86
91
|
*/
|
|
87
|
-
export declare function ClinicalBundleDraftEditor({ schemas, authoringContext, copy, locale, timeZone, taxonomyId, fieldLabel, resourceTypeLabel, searchTerminology, loadTerminologySources, initialBundle, onDraftChange, onSubmitDraft, editorVersion, editorV2Copy, artifactCredentialAction, }: ClinicalBundleDraftEditorProps): import("react").JSX.Element;
|
|
92
|
+
export declare function ClinicalBundleDraftEditor({ schemas, authoringContext, copy, locale, timeZone, taxonomyId, fieldLabel, resourceTypeLabel, searchTerminology, loadTerminologySources, initialBundle, onDraftChange, onSubmitDraft, editorVersion, editorV2Copy, artifactCredentialAction, documentActions, }: ClinicalBundleDraftEditorProps): import("react").JSX.Element;
|
|
88
93
|
export declare function combineClinicalDrafts(artifacts: readonly StagedArtifact[], authoringContext: ClinicalArtifactAuthoringContext, documentTitle: string): ClinicalBundleDraft;
|
|
89
94
|
export type ClinicalBundleDraftEditorV2Props = Omit<ClinicalBundleDraftEditorProps, 'editorVersion' | 'editorV2Copy'> & Readonly<{
|
|
90
95
|
editorV2Copy: ImmunizationArtifactEditorCopyV2;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ClinicalBundleDraftEditor.d.ts","sourceRoot":"","sources":["../src/ClinicalBundleDraftEditor.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ClinicalBundleDraftEditor.d.ts","sourceRoot":"","sources":["../src/ClinicalBundleDraftEditor.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAgC,KAAK,SAAS,EAAE,MAAM,OAAO,CAAA;AAMpE,OAAO,4DAA4D,CAAA;AACnE,OAAO,kDAAkD,CAAA;AACzD,OAAO,2DAA2D,CAAA;AAClE,OAAO,qDAAqD,CAAA;AAC5D,OAAO,6DAA6D,CAAA;AACpE,OAAO,oDAAoD,CAAA;AAC3D,OAAO,kDAAkD,CAAA;AACzD,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,kDAAkD,CAAA;AACnG,OAAO,EAEL,KAAK,gCAAgC,EACrC,KAAK,qBAAqB,EAC1B,KAAK,0BAA0B,EAE/B,KAAK,sBAAsB,EAC3B,KAAK,yBAAyB,EAC9B,KAAK,4BAA4B,EACjC,KAAK,+BAA+B,EACrC,MAAM,6BAA6B,CAAA;AAEpC,OAAO,EAEL,KAAK,gCAAgC,EACtC,MAAM,mCAAmC,CAAA;AAC1C,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,+BAA+B,CAAA;AAG5E,MAAM,MAAM,yBAAyB,GAAG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ACnG,CAAC,CAAA;IACF,2EAA2E;IAC3E,eAAe,CAAC,EAAE,SAAS,CAAA;CAC5B,CAAC,CAAA;AAEF,KAAK,cAAc,GAAG,QAAQ,CAAC;IAC7B,MAAM,EAAE,yBAAyB,CAAA;IACjC,KAAK,EAAE,qBAAqB,CAAA;CAC7B,CAAC,CAAA;AAYF;;;;;;GAMG;AACH,wBAAgB,yBAAyB,CAAC,EACxC,OAAO,EACP,gBAAgB,EAChB,IAAI,EACJ,MAAa,EACb,QAAQ,EACR,UAAU,EACV,UAAU,EACV,iBAAiB,EACjB,iBAAiB,EACjB,sBAAsB,EACtB,aAAa,EACb,aAAa,EACb,aAAa,EACb,aAAoB,EACpB,YAAY,EACZ,wBAAwB,EACxB,eAAe,GAChB,EAAE,8BAA8B,+BAoKhC;AAWD,wBAAgB,qBAAqB,CACnC,SAAS,EAAE,SAAS,cAAc,EAAE,EACpC,gBAAgB,EAAE,gCAAgC,EAClD,aAAa,EAAE,MAAM,GACpB,mBAAmB,CAsDrB;AAED,MAAM,MAAM,gCAAgC,GAAG,IAAI,CAAC,8BAA8B,EAAE,eAAe,GAAG,cAAc,CAAC,GAAG,QAAQ,CAAC;IAC/H,YAAY,EAAE,gCAAgC,CAAA;CAC/C,CAAC,CAAA;AAEF,kFAAkF;AAClF,wBAAgB,2BAA2B,CAAC,KAAK,EAAE,gCAAgC,+BAElF"}
|
|
@@ -24,7 +24,7 @@ import { SchemaClinicalArtifactEditorV2 } from './SchemaClinicalArtifactEditorV2
|
|
|
24
24
|
* It owns no authorization or persistence: the host supplies subject and
|
|
25
25
|
* provenance and only `onSubmitDraft` may cross a persistence boundary.
|
|
26
26
|
*/
|
|
27
|
-
export function ClinicalBundleDraftEditor({ schemas, authoringContext, copy, locale = 'en', timeZone, taxonomyId, fieldLabel, resourceTypeLabel, searchTerminology, loadTerminologySources, initialBundle, onDraftChange, onSubmitDraft, editorVersion = 'v1', editorV2Copy, artifactCredentialAction, }) {
|
|
27
|
+
export function ClinicalBundleDraftEditor({ schemas, authoringContext, copy, locale = 'en', timeZone, taxonomyId, fieldLabel, resourceTypeLabel, searchTerminology, loadTerminologySources, initialBundle, onDraftChange, onSubmitDraft, editorVersion = 'v1', editorV2Copy, artifactCredentialAction, documentActions, }) {
|
|
28
28
|
const [artifacts, setArtifacts] = useState(() => importedArtifacts(initialBundle, schemas));
|
|
29
29
|
const [editor, setEditor] = useState();
|
|
30
30
|
const [resourceChooser, setResourceChooser] = useState();
|
|
@@ -74,21 +74,30 @@ export function ClinicalBundleDraftEditor({ schemas, authoringContext, copy, loc
|
|
|
74
74
|
setSubmitting(false);
|
|
75
75
|
}
|
|
76
76
|
}
|
|
77
|
-
return _jsxs("section", { className: "uhcp-clinical-bundle-draft", "data-clinical-bundle-draft": true, children: [_jsxs("header", { children: [_jsx("h2", { children: copy.title }), _jsx("p", { children: copy.description })] }), notice ? _jsx("p", { role: "status", children: notice }) : null, error ? _jsx("p", { role: "alert", className: "uhcp-clinical-editor-error", children: error }) : null, availableSections.length ? _jsxs("div", { className: "uhcp-clinical-bundle-draft-create", children: [_jsxs("label", { children: [copy.section || 'Section', _jsx("select", { value: availableSections.some(section => section.label === selectedSection) ? selectedSection : availableSections[0]?.label, onChange: (event) => setSelectedSection(event.currentTarget.value), children: availableSections.map(section => _jsx("option", { value: section.label, children: section.label }, section.label)) })] }),
|
|
77
|
+
return _jsxs("section", { className: "uhcp-clinical-bundle-draft", "data-clinical-bundle-draft": true, children: [_jsxs("header", { children: [_jsx("h2", { children: copy.title }), _jsx("p", { children: copy.description })] }), notice ? _jsx("p", { role: "status", children: notice }) : null, error ? _jsx("p", { role: "alert", className: "uhcp-clinical-editor-error", children: error }) : null, availableSections.length ? _jsxs("div", { className: "uhcp-clinical-bundle-draft-create", children: [_jsxs("label", { children: [copy.section || 'Section', _jsx("select", { value: availableSections.some(section => section.label === selectedSection) ? selectedSection : availableSections[0]?.label, onChange: (event) => setSelectedSection(event.currentTarget.value), children: availableSections.map(section => _jsx("option", { value: section.label, children: section.label }, section.label)) })] }), _jsx("button", { type: "button", onClick: () => {
|
|
78
78
|
const label = availableSections.some(section => section.label === selectedSection) ? selectedSection : availableSections[0]?.label;
|
|
79
79
|
if (!label)
|
|
80
80
|
return;
|
|
81
81
|
setActiveSections(current => [...current, label]);
|
|
82
82
|
const nextAvailable = availableSections.find(section => section.label !== label);
|
|
83
83
|
setSelectedSection(nextAvailable?.label ?? '');
|
|
84
|
-
},
|
|
84
|
+
}, className: "uhcp-add-section-button", children: copy.addSection || copy.add })] }) : null, sections.filter(section => activeSections.includes(section.label)).map(({ label, schemas: sectionSchemas }) => {
|
|
85
85
|
const sectionArtifacts = artifacts.filter((artifact) => artifact.schema.sectionLabel === label);
|
|
86
|
-
return _jsxs("details", { open: true, children: [_jsxs("summary", { children: [label, " (", sectionArtifacts.length, ")"] }),
|
|
86
|
+
return _jsxs("details", { open: true, children: [_jsxs("summary", { children: [label, " (", sectionArtifacts.length, ")"] }), _jsx("button", { type: "button", className: "uhcp-remove-section-button", "aria-label": `${copy.removeSection || copy.remove} ${label}`, title: `${copy.removeSection || copy.remove} ${label}`, "data-tooltip": `${copy.removeSection || copy.remove} ${label}`, onClick: () => {
|
|
87
|
+
if (sectionArtifacts.length && !window.confirm(copy.removeSectionConfirm || `Removing this section will delete all its draft entries. Continue?`))
|
|
88
|
+
return;
|
|
89
|
+
setArtifacts(current => current.filter(artifact => artifact.schema.sectionLabel !== label));
|
|
90
|
+
setActiveSections(current => current.filter(section => section !== label));
|
|
91
|
+
if (resourceChooser?.sectionLabel === label)
|
|
92
|
+
setResourceChooser(undefined);
|
|
93
|
+
if (editor?.schema.sectionLabel === label)
|
|
94
|
+
setEditor(undefined);
|
|
95
|
+
}, children: "\u2212" }), _jsx("button", { type: "button", className: "uhcp-add-entry-button", "aria-label": copy.addEntry || copy.add, title: copy.addEntry || copy.add, "data-tooltip": copy.addEntry || copy.add, onClick: () => {
|
|
87
96
|
if (sectionSchemas.length === 1)
|
|
88
97
|
setEditor({ schema: sectionSchemas[0] });
|
|
89
98
|
else
|
|
90
99
|
setResourceChooser({ sectionLabel: label, schemaKey: schemaKey(sectionSchemas[0]) });
|
|
91
|
-
}, children:
|
|
100
|
+
}, children: "+" }), resourceChooser?.sectionLabel === label ? _jsxs("div", { className: "uhcp-clinical-bundle-resource-choice", children: [_jsxs("label", { children: [copy.resourceType || 'Resource type', _jsx("select", { value: resourceChooser.schemaKey, onChange: event => setResourceChooser({ sectionLabel: label, schemaKey: event.currentTarget.value }), children: sectionSchemas.map(candidate => _jsx("option", { value: schemaKey(candidate), children: resourceTypeLabel?.(candidate.schema.resourceType) || candidate.artifactLabel }, schemaKey(candidate))) })] }), _jsx("button", { type: "button", onClick: () => {
|
|
92
101
|
const selected = sectionSchemas.find(candidate => schemaKey(candidate) === resourceChooser.schemaKey);
|
|
93
102
|
if (selected)
|
|
94
103
|
setEditor({ schema: selected });
|
|
@@ -107,7 +116,7 @@ export function ClinicalBundleDraftEditor({ schemas, authoringContext, copy, loc
|
|
|
107
116
|
}).catch(reason => setError(reason instanceof Error ? reason.message : String(reason)));
|
|
108
117
|
}, children: artifactCredentialAction.isCreated(artifact.draft) ? artifactCredentialAction.viewLabel : artifactCredentialAction.createLabel }) : null, _jsx(ClinicalActionButton, { kind: "edit", label: `${copy.edit} ${title}`, onClick: () => setEditor({ schema: artifact.schema, draft: artifact.draft }) }), _jsx(ClinicalActionButton, { kind: "delete", label: `${copy.remove} ${title}`, onClick: () => setArtifacts((current) => current.filter((candidate) => candidate.draft.id !== artifact.draft.id)) })] })] }, artifact.draft.id);
|
|
109
118
|
}) })] }, label);
|
|
110
|
-
}), activeSections.length === 0 ? _jsx("p", { children: copy.empty }) : null,
|
|
119
|
+
}), activeSections.length === 0 ? _jsx("p", { children: copy.empty }) : null, _jsxs("footer", { "data-testid": "clinical-document-actions", children: [documentActions ? _jsx("div", { className: "uhcp-clinical-document-secondary-actions", children: documentActions }) : null, _jsx("button", { type: "button", className: "uhcp-clinical-document-submit", disabled: artifacts.length === 0 || submitting, onClick: () => void submitDraft(), children: submitting ? copy.submitting : copy.submit })] }), editor && editorVersion === 'v2' && editor.schema.schema.resourceType === 'Immunization' && editorV2Copy ? _jsx(ImmunizationArtifactEditorV2, { request: editorRequest(editor), authoringContext: authoringContext, copy: editorV2Copy, locale: locale, timeZone: timeZone, taxonomyId: taxonomyId, fieldLabel: fieldLabel, resourceTypeLabel: resourceTypeLabel?.(editor.schema.schema.resourceType) || editor.schema.artifactLabel, searchTerminology: searchTerminology, loadTerminologySources: loadTerminologySources, saveArtifact: async (draft) => stageArtifact(draft), onCancel: () => setEditor(undefined), onReadback: () => setEditor(undefined) }) : editor && editorVersion === 'v2' && editorV2Copy ? _jsx(SchemaClinicalArtifactEditorV2, { request: editorRequest(editor), schema: editor.schema.schema, authoringContext: authoringContext, copy: editorV2Copy, locale: locale, timeZone: timeZone, taxonomyId: taxonomyId, fieldLabel: fieldLabel, resourceTypeLabel: resourceTypeLabel?.(editor.schema.schema.resourceType) || editor.schema.artifactLabel, searchTerminology: searchTerminology, loadTerminologySources: loadTerminologySources, saveArtifact: async (draft) => stageArtifact(draft), onCancel: () => setEditor(undefined), onReadback: () => setEditor(undefined) }) : editor ? _jsx(ClinicalArtifactEditor, { request: editorRequest(editor), schema: editor.schema.schema, operationSchema: editor.schema.operationSchema, authoringContext: authoringContext, copy: copy.editor, locale: locale, timeZone: timeZone, taxonomyId: taxonomyId, fieldLabel: fieldLabel, resourceTypeLabel: resourceTypeLabel?.(editor.schema.schema.resourceType) || editor.schema.artifactLabel, searchTerminology: searchTerminology, loadTerminologySources: loadTerminologySources, saveArtifact: async (draft) => stageArtifact(draft), onCancel: () => setEditor(undefined), onReadback: () => setEditor(undefined) }) : null] });
|
|
111
120
|
}
|
|
112
121
|
function editorRequest(editor) {
|
|
113
122
|
return {
|
|
@@ -7,6 +7,7 @@ export type ProfileProtectionGateV2Props = Readonly<{
|
|
|
7
7
|
onUnlock?: (pin: string) => ProfileUnlockResult | Promise<ProfileUnlockResult>;
|
|
8
8
|
onPasskeyUnlock?: () => void | Promise<void>;
|
|
9
9
|
onRetry?: () => void;
|
|
10
|
+
pinFailureActions?: ReactNode;
|
|
10
11
|
secondaryActions?: ReactNode;
|
|
11
12
|
children: ReactNode;
|
|
12
13
|
}>;
|
|
@@ -16,5 +17,5 @@ export type ProfileProtectionGateV2Props = Readonly<{
|
|
|
16
17
|
* The host resolves translations, authority and the opaque profile id. This
|
|
17
18
|
* component renders only human-readable metadata and never selects a target.
|
|
18
19
|
*/
|
|
19
|
-
export declare function ProfileProtectionGateV2({ state, target, copy, onUnlock, onPasskeyUnlock, onRetry, secondaryActions, children, }: ProfileProtectionGateV2Props): import("react").JSX.Element;
|
|
20
|
+
export declare function ProfileProtectionGateV2({ state, target, copy, onUnlock, onPasskeyUnlock, onRetry, pinFailureActions, secondaryActions, children, }: ProfileProtectionGateV2Props): import("react").JSX.Element;
|
|
20
21
|
//# sourceMappingURL=ProfileProtectionGateV2.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ProfileProtectionGateV2.d.ts","sourceRoot":"","sources":["../src/ProfileProtectionGateV2.tsx"],"names":[],"mappings":"AAEA,OAAO,EAA+C,KAAK,SAAS,EAAE,MAAM,OAAO,CAAA;AACnF,OAAO,KAAK,EACV,uBAAuB,EACvB,sBAAsB,EACtB,yBAAyB,EACzB,mBAAmB,EACpB,MAAM,gBAAgB,CAAA;AAEvB,MAAM,MAAM,4BAA4B,GAAG,QAAQ,CAAC;IAClD,KAAK,EAAE,sBAAsB,CAAA;IAC7B,MAAM,EAAE,yBAAyB,CAAA;IACjC,IAAI,EAAE,uBAAuB,CAAA;IAC7B,QAAQ,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,mBAAmB,GAAG,OAAO,CAAC,mBAAmB,CAAC,CAAA;IAC9E,eAAe,CAAC,EAAE,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAA;IAC5C,OAAO,CAAC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@@ import { useEffect, useRef, useState } from 'react';
|
|
|
7
7
|
* The host resolves translations, authority and the opaque profile id. This
|
|
8
8
|
* component renders only human-readable metadata and never selects a target.
|
|
9
9
|
*/
|
|
10
|
-
export function ProfileProtectionGateV2({ state, target, copy, onUnlock, onPasskeyUnlock, onRetry, secondaryActions, children, }) {
|
|
10
|
+
export function ProfileProtectionGateV2({ state, target, copy, onUnlock, onPasskeyUnlock, onRetry, pinFailureActions, secondaryActions, children, }) {
|
|
11
11
|
const [pin, setPin] = useState('');
|
|
12
12
|
const [error, setError] = useState('');
|
|
13
13
|
const [busy, setBusy] = useState(false);
|
|
14
|
+
const [pinRejected, setPinRejected] = useState(false);
|
|
14
15
|
const input = useRef(null);
|
|
15
16
|
useEffect(() => {
|
|
16
17
|
setPin('');
|
|
17
18
|
setError('');
|
|
19
|
+
setPinRejected(false);
|
|
18
20
|
}, [state, target.title, target.subtitle]);
|
|
19
21
|
async function unlock(event) {
|
|
20
22
|
event.preventDefault();
|
|
@@ -32,8 +34,10 @@ export function ProfileProtectionGateV2({ state, target, copy, onUnlock, onPassk
|
|
|
32
34
|
if (result === 'unlocked') {
|
|
33
35
|
setPin('');
|
|
34
36
|
setError('');
|
|
37
|
+
setPinRejected(false);
|
|
35
38
|
return;
|
|
36
39
|
}
|
|
40
|
+
setPinRejected(result === 'invalid-pin');
|
|
37
41
|
setError(result === 'invalid-pin'
|
|
38
42
|
? copy.invalidPin
|
|
39
43
|
: result === 'temporarily-locked'
|
|
@@ -75,5 +79,5 @@ export function ProfileProtectionGateV2({ state, target, copy, onUnlock, onPassk
|
|
|
75
79
|
: state === 'unavailable'
|
|
76
80
|
? copy.unavailableBody
|
|
77
81
|
: copy.unlockBody;
|
|
78
|
-
return (_jsxs("section", { className: "uhcp-profile-gate uhcp-profile-gate-v2", "aria-live": "polite", children: [_jsxs("div", { className: "uhcp-profile-target", children: [target.icon && _jsx("img", { src: target.icon.src, alt: target.icon.alt, width: target.icon.width, height: target.icon.height }), _jsxs("div", { className: "uhcp-profile-target-copy", children: [_jsx("span", { className: "uhcp-profile-target-eyebrow", children: target.eyebrow }), _jsx("strong", { children: target.title }), target.subtitle && _jsx("span", { children: target.subtitle })] }), target.badges?.length ? _jsx("ul", { className: "uhcp-profile-target-badges", "aria-label": target.eyebrow, children: target.badges.map(badge => _jsx("li", { children: badge }, badge)) }) : null, target.details?.length ? _jsx("dl", { className: "uhcp-profile-target-details", children: target.details.map(detail => _jsxs("div", { children: [_jsx("dt", { children: detail.label }), _jsx("dd", { children: detail.value })] }, `${detail.label}:${detail.value}`)) }) : null] }), _jsxs("div", { className: "uhcp-profile-gate-copy", children: [_jsx("h1", { children: title }), _jsx("p", { children: body })] }), state === 'locked' && onPasskeyUnlock && _jsx("button", { type: "button", "data-portal-action": "unlock-profile-with-passkey", disabled: busy, onClick: unlockWithPasskey, children: copy.unlockWithPasskey }), state === 'locked' && _jsxs("details", { className: "uhcp-profile-pin-fallback", open: !onPasskeyUnlock, children: [_jsx("summary", { children: onPasskeyUnlock ? copy.usePinInstead : copy.pinLabel }), _jsxs("form", { onSubmit: unlock, children: [_jsxs("label", { children: [copy.pinLabel, _jsx("input", { ref: input, type: "password", inputMode: "numeric", minLength: 6, autoComplete: "current-password", value: pin, onChange: (event) => setPin(event.target.value) })] }), error && _jsx("p", { role: "alert", className: "uhcp-error", children: error }), _jsx("button", { type: "submit", "data-portal-action": "unlock-profile", disabled: busy, children: copy.unlock })] })] }), state === 'unavailable' && onRetry && _jsx("button", { type: "button", onClick: onRetry, children: copy.retry }), secondaryActions && _jsx("div", { className: "uhcp-profile-gate-secondary", children: secondaryActions })] }));
|
|
82
|
+
return (_jsxs("section", { className: "uhcp-profile-gate uhcp-profile-gate-v2", "aria-live": "polite", children: [_jsxs("div", { className: "uhcp-profile-target", children: [target.icon && _jsx("img", { src: target.icon.src, alt: target.icon.alt, width: target.icon.width, height: target.icon.height }), _jsxs("div", { className: "uhcp-profile-target-copy", children: [_jsx("span", { className: "uhcp-profile-target-eyebrow", children: target.eyebrow }), _jsx("strong", { children: target.title }), target.subtitle && _jsx("span", { children: target.subtitle })] }), target.badges?.length ? _jsx("ul", { className: "uhcp-profile-target-badges", "aria-label": target.eyebrow, children: target.badges.map(badge => _jsx("li", { children: badge }, badge)) }) : null, target.details?.length ? _jsx("dl", { className: "uhcp-profile-target-details", children: target.details.map(detail => _jsxs("div", { children: [_jsx("dt", { children: detail.label }), _jsx("dd", { children: detail.value })] }, `${detail.label}:${detail.value}`)) }) : null] }), _jsxs("div", { className: "uhcp-profile-gate-copy", children: [_jsx("h1", { children: title }), _jsx("p", { children: body })] }), state === 'locked' && onPasskeyUnlock && _jsx("button", { type: "button", "data-portal-action": "unlock-profile-with-passkey", disabled: busy, onClick: unlockWithPasskey, children: copy.unlockWithPasskey }), state === 'locked' && _jsxs("details", { className: "uhcp-profile-pin-fallback", open: !onPasskeyUnlock, children: [_jsx("summary", { children: onPasskeyUnlock ? copy.usePinInstead : copy.pinLabel }), _jsxs("form", { onSubmit: unlock, children: [_jsxs("label", { children: [copy.pinLabel, _jsx("input", { ref: input, type: "password", inputMode: "numeric", minLength: 6, autoComplete: "current-password", value: pin, onChange: (event) => setPin(event.target.value) })] }), error && _jsx("p", { role: "alert", className: "uhcp-error", children: error }), _jsx("button", { type: "submit", "data-portal-action": "unlock-profile", disabled: busy, children: copy.unlock })] }), pinRejected && pinFailureActions ? _jsx("div", { className: "uhcp-profile-pin-recovery", children: pinFailureActions }) : null] }), state === 'unavailable' && onRetry && _jsx("button", { type: "button", onClick: onRetry, children: copy.retry }), secondaryActions && _jsx("div", { className: "uhcp-profile-gate-secondary", children: secondaryActions })] }));
|
|
79
83
|
}
|
package/dist/styles.css
CHANGED
|
@@ -161,15 +161,15 @@ html[data-theme='dark'] .uhcp-brand-artwork-dark { display: block !important; }
|
|
|
161
161
|
.uhcp-profile-gate label { color: var(--uhcp-muted); display: grid; gap: .45rem; }
|
|
162
162
|
.uhcp-profile-gate input { background: var(--uhcp-panel); border: 1px solid var(--uhcp-border); border-radius: .75rem; color: var(--uhcp-text); padding: .8rem; }
|
|
163
163
|
.uhcp-profile-gate button { background: linear-gradient(135deg, var(--uhcp-action-start), var(--uhcp-action-end)); border: 0; border-radius: .75rem; color: #fff; cursor: pointer; font: inherit; font-weight: 800; padding: .8rem 1rem; }
|
|
164
|
-
.uhcp-profile-gate-v2 { gap: 1rem; }
|
|
165
|
-
.uhcp-profile-target { background: var(--uhcp-
|
|
164
|
+
.uhcp-profile-gate-v2 { background: linear-gradient(145deg, color-mix(in srgb, var(--uhcp-surface-accent) 76%, var(--uhcp-panel)), var(--uhcp-panel-muted)); border: 1px solid color-mix(in srgb, var(--uhcp-turquoise) 30%, var(--uhcp-border)); border-radius: 1.5rem; box-shadow: 0 1.2rem 3rem color-mix(in srgb, var(--uhcp-text) 10%, transparent); gap: 1rem; }
|
|
165
|
+
.uhcp-profile-target { background: linear-gradient(135deg, color-mix(in srgb, var(--uhcp-surface-accent) 80%, var(--uhcp-panel)), color-mix(in srgb, var(--uhcp-turquoise) 12%, var(--uhcp-panel))); border: 1px solid color-mix(in srgb, var(--uhcp-turquoise) 38%, var(--uhcp-border)); border-radius: 1rem; display: grid; gap: .8rem; padding: 1rem; }
|
|
166
166
|
.uhcp-profile-target > img { border-radius: .75rem; object-fit: contain; }
|
|
167
167
|
.uhcp-profile-target-copy { display: grid; gap: .2rem; }
|
|
168
168
|
.uhcp-profile-target-copy > strong { color: var(--uhcp-text); font-size: 1.2rem; }
|
|
169
169
|
.uhcp-profile-target-copy > span:last-child { color: var(--uhcp-muted); }
|
|
170
170
|
.uhcp-profile-target-eyebrow { color: var(--uhcp-muted); font-size: .78rem; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
|
|
171
171
|
.uhcp-profile-target-badges { display: flex; flex-wrap: wrap; gap: .45rem; list-style: none; margin: 0; padding: 0; }
|
|
172
|
-
.uhcp-profile-target-badges li { background: var(--uhcp-panel); border: 1px solid var(--uhcp-border); border-radius: 999px; color: var(--uhcp-text); padding: .35rem .65rem; }
|
|
172
|
+
.uhcp-profile-target-badges li { background: color-mix(in srgb, var(--uhcp-turquoise) 13%, var(--uhcp-panel)); border: 1px solid color-mix(in srgb, var(--uhcp-turquoise) 36%, var(--uhcp-border)); border-radius: 999px; color: var(--uhcp-text); padding: .35rem .65rem; }
|
|
173
173
|
.uhcp-profile-target-details { margin: 0; }
|
|
174
174
|
.uhcp-profile-target-details > div { display: grid; gap: .2rem; grid-template-columns: minmax(8rem, auto) 1fr; }
|
|
175
175
|
.uhcp-profile-target-details dt { color: var(--uhcp-muted); }
|
|
@@ -177,7 +177,11 @@ html[data-theme='dark'] .uhcp-brand-artwork-dark { display: block !important; }
|
|
|
177
177
|
.uhcp-profile-pin-fallback { border-top: 1px solid var(--uhcp-border); padding-top: .8rem; }
|
|
178
178
|
.uhcp-profile-pin-fallback summary { color: var(--uhcp-text); cursor: pointer; font-weight: 700; }
|
|
179
179
|
.uhcp-profile-pin-fallback form { margin-top: .8rem; }
|
|
180
|
+
.uhcp-profile-pin-recovery { display: flex; justify-content: flex-start; margin-top: .7rem; }
|
|
181
|
+
.uhcp-profile-pin-recovery button { background: transparent; border: 1px solid var(--uhcp-border); color: var(--uhcp-text); }
|
|
180
182
|
.uhcp-profile-gate-secondary { border-top: 1px solid var(--uhcp-border); display: grid; gap: .6rem; padding-top: .8rem; }
|
|
183
|
+
.uhcp-profile-gate-secondary .uhcp-add-profile-action { align-items: center; background: transparent; border: 1px solid color-mix(in srgb, var(--uhcp-turquoise) 35%, var(--uhcp-border)); color: var(--uhcp-text); display: inline-flex; gap: .65rem; justify-content: flex-start; }
|
|
184
|
+
.uhcp-profile-gate-secondary .uhcp-add-profile-action::first-letter { color: var(--uhcp-turquoise); font-size: 1.25em; }
|
|
181
185
|
.uhcp-error { color: #c64747 !important; }
|
|
182
186
|
.uhcp-shell { background: var(--uhcp-surface); color: var(--uhcp-text); min-height: 100vh; }
|
|
183
187
|
.uhcp-main { min-height: calc(100vh - 4.5rem); }
|
|
@@ -520,29 +524,35 @@ html[data-theme='dark'] .uhcp-brand-artwork-dark { display: block !important; }
|
|
|
520
524
|
.uhcp-clinical-bundle-draft { background:var(--uhcp-panel); border:1px solid var(--uhcp-border); border-radius:1.5rem; color:var(--uhcp-text); display:grid; gap:1rem; padding:1.25rem; }
|
|
521
525
|
.uhcp-clinical-bundle-draft>header h2,.uhcp-clinical-bundle-draft>header p { margin:.15rem 0; }
|
|
522
526
|
.uhcp-clinical-bundle-draft>header p,.uhcp-clinical-bundle-draft details>p { color:var(--uhcp-muted); }
|
|
523
|
-
.uhcp-clinical-bundle-draft details { background:var(--uhcp-panel-muted); border:1px solid var(--uhcp-border); border-radius:1rem; padding:.85rem 1rem; }
|
|
527
|
+
.uhcp-clinical-bundle-draft details { background:var(--uhcp-panel-muted); border:1px solid var(--uhcp-border); border-radius:1rem; padding:.85rem 1rem; position:relative; }
|
|
524
528
|
.uhcp-clinical-bundle-draft summary { cursor:pointer; font-weight:800; }
|
|
525
529
|
.uhcp-clinical-bundle-draft-create { align-items:end; background:var(--uhcp-panel-muted); border:1px solid var(--uhcp-border); border-radius:1rem; display:grid; gap:.8rem; grid-template-columns:minmax(10rem,1fr) minmax(10rem,1fr) auto; padding:1rem; }
|
|
526
530
|
.uhcp-clinical-bundle-draft-create label { display:grid; gap:.35rem; font-weight:700; }
|
|
527
531
|
.uhcp-clinical-bundle-draft-create select { background:var(--uhcp-panel); border:1px solid var(--uhcp-border); border-radius:.7rem; color:var(--uhcp-text); font:inherit; min-height:2.75rem; padding:.55rem .7rem; }
|
|
528
|
-
.uhcp-clinical-bundle-draft-create button { background:
|
|
532
|
+
.uhcp-clinical-bundle-draft-create button.uhcp-add-section-button { background:color-mix(in srgb,var(--uhcp-turquoise) 13%,var(--uhcp-panel)); border:1px solid color-mix(in srgb,var(--uhcp-turquoise) 45%,var(--uhcp-border)); border-radius:.75rem; color:var(--uhcp-text); cursor:pointer; font:inherit; font-weight:800; min-height:2.75rem; padding:.65rem 1rem; }
|
|
529
533
|
.uhcp-clinical-bundle-draft-create button:disabled { cursor:not-allowed; opacity:.5; }
|
|
534
|
+
.uhcp-clinical-bundle-draft .uhcp-add-entry-button { background:var(--uhcp-emerald); border:0; border-radius:.65rem; color:#fff; cursor:pointer; font-size:1.3rem; font-weight:900; height:2.5rem; margin-top:.65rem; width:2.5rem; }
|
|
535
|
+
.uhcp-clinical-bundle-draft .uhcp-remove-section-button { background:color-mix(in srgb,#c64747 12%,var(--uhcp-panel)); border:1px solid color-mix(in srgb,#c64747 42%,var(--uhcp-border)); border-radius:.6rem; color:#a72f2f; cursor:pointer; font-size:1.25rem; font-weight:900; height:2.25rem; position:absolute; right:.7rem; top:.55rem; width:2.25rem; }
|
|
530
536
|
.uhcp-clinical-bundle-draft ul { display:grid; gap:.55rem; list-style:none; margin:.8rem 0 0; padding:0; }
|
|
531
537
|
.uhcp-clinical-bundle-draft li { align-items:center; background:var(--uhcp-panel); border:1px solid var(--uhcp-border); border-radius:.8rem; display:flex; gap:1rem; justify-content:space-between; padding:.7rem; }
|
|
532
538
|
.uhcp-clinical-bundle-draft li>span { display:flex; gap:.45rem; }
|
|
533
539
|
.uhcp-clinical-bundle-draft li>span:first-child { align-items:flex-start; flex-direction:column; min-width:0; }
|
|
534
540
|
.uhcp-clinical-bundle-draft li strong { overflow-wrap:anywhere; }
|
|
535
541
|
.uhcp-clinical-bundle-draft li small { color:var(--uhcp-muted); }
|
|
536
|
-
.uhcp-clinical-bundle-draft>footer { display:flex; justify-content:
|
|
537
|
-
.uhcp-clinical-
|
|
538
|
-
.uhcp-clinical-bundle-draft>footer
|
|
542
|
+
.uhcp-clinical-bundle-draft>footer { align-items:center; background:var(--uhcp-panel-muted); border:1px solid var(--uhcp-border); border-radius:1rem; display:flex; gap:.75rem; justify-content:space-between; padding:.7rem .8rem; }
|
|
543
|
+
.uhcp-clinical-document-secondary-actions { align-items:center; display:flex; flex:1; flex-wrap:wrap; gap:.65rem; min-width:0; }
|
|
544
|
+
.uhcp-clinical-bundle-draft>footer .uhcp-clinical-document-submit { background:var(--uhcp-emerald); border:0; border-radius:.75rem; color:#fff; cursor:pointer; flex:0 0 auto; font:inherit; font-weight:800; padding:.75rem 1rem; }
|
|
545
|
+
.uhcp-clinical-bundle-draft>footer .uhcp-clinical-document-submit:disabled { cursor:not-allowed; opacity:.5; }
|
|
546
|
+
.uhcp-clinical-bundle-draft .uhcp-clinical-entry-credential-action { background:color-mix(in srgb,var(--uhcp-attention) 24%,var(--uhcp-panel)); border:1px solid color-mix(in srgb,var(--uhcp-attention) 58%,var(--uhcp-border)); color:var(--uhcp-text); }
|
|
547
|
+
.uhcp-clinical-bundle-draft button[data-tooltip]:not(.uhcp-remove-section-button),.uhcp-clinical-icon-action[data-tooltip] { position:relative; }
|
|
548
|
+
.uhcp-clinical-bundle-draft button[data-tooltip]:is(:hover,:focus-visible)::after,.uhcp-clinical-icon-action[data-tooltip]:is(:hover,:focus-visible)::after { background:var(--uhcp-text); border-radius:.45rem; bottom:calc(100% + .45rem); color:var(--uhcp-panel); content:attr(data-tooltip); font-size:.78rem; font-weight:700; left:50%; max-width:16rem; padding:.35rem .5rem; pointer-events:none; position:absolute; transform:translateX(-50%); white-space:nowrap; z-index:50; }
|
|
539
549
|
.uhcp-clinical-editor-attachments { border:1px solid var(--uhcp-border); border-radius:.85rem; display:grid; gap:.65rem; grid-column:1/-1; padding:.85rem; }
|
|
540
550
|
.uhcp-clinical-editor-attachments label { display:grid; gap:.35rem; }
|
|
541
551
|
.uhcp-clinical-editor-attachments input[type=file] { border:1px dashed var(--uhcp-border); border-radius:.7rem; padding:.65rem; }
|
|
542
552
|
.uhcp-clinical-editor-attachments ul { display:grid; gap:.4rem; list-style:none; margin:0; padding:0; }
|
|
543
553
|
.uhcp-clinical-editor-attachments li { align-items:center; background:var(--uhcp-panel-muted); border-radius:.65rem; display:flex; justify-content:space-between; padding:.5rem .65rem; }
|
|
544
554
|
.uhcp-clinical-editor-attachments li button { background:transparent; border:0; color:var(--uhcp-text); cursor:pointer; font-size:1.2rem; }
|
|
545
|
-
@media (max-width:720px) { .uhcp-clinical-bundle-draft-create { grid-template-columns:1fr; } }
|
|
555
|
+
@media (max-width:720px) { .uhcp-clinical-bundle-draft-create { grid-template-columns:1fr; } .uhcp-clinical-bundle-draft>footer { align-items:stretch; flex-direction:column; } .uhcp-clinical-bundle-draft>footer .uhcp-clinical-document-submit { align-self:flex-end; } }
|
|
546
556
|
.uhcp-clinical-title { font-weight: 800; margin: 0; }
|
|
547
557
|
.uhcp-clinical-type { color: var(--uhcp-muted); font-size: .72rem; font-weight: 800; letter-spacing: .06em; margin: .35rem 0 0; text-transform: uppercase; }
|
|
548
558
|
.uhcp-clinical-date, .uhcp-clinical-empty { color: var(--uhcp-muted); margin: .35rem 0 0; }
|
package/package.json
CHANGED