@ntix/components-scorad 1.0.3 → 1.0.5
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 +0 -4
- package/dist/@ntix/components-scorad.es.js +31 -18
- package/dist/@ntix/components-scorad.umd.js +11 -11
- package/dist/HTMLScoradValueElement.d.ts +37 -0
- package/dist/ScoradData.d.ts +1 -1
- package/dist/ScoradExtentData.d.ts +11 -7
- package/dist/ScoradExtentWeights.d.ts +1 -1
- package/dist/ScoradIntensityData.d.ts +11 -7
- package/dist/ScoradResources.d.ts +11 -0
- package/dist/ScoradScore.d.ts +14 -1
- package/dist/ScoradSubjectiveData.d.ts +7 -3
- package/dist/component.d.ts +35 -7
- package/dist/componentsScoradLogger.d.ts +8 -0
- package/dist/constants.d.ts +19 -4
- package/dist/extent/component.d.ts +45 -8
- package/dist/getScoradScore.d.ts +1 -2
- package/dist/index.d.ts +1 -0
- package/dist/intensity/component.d.ts +39 -7
- package/dist/label/component.d.ts +1 -1
- package/dist/options/component.d.ts +4 -7
- package/dist/subjective/component.d.ts +40 -7
- package/dist/weightings/component.d.ts +30 -7
- package/docs/HTMLScoradValueElement.md +35 -0
- package/docs/README.md +36 -0
- package/docs/ScoradData.md +13 -0
- package/docs/ScoradExtentData.md +63 -0
- package/docs/ScoradExtentWeights.md +13 -0
- package/docs/ScoradIntensityData.md +64 -0
- package/docs/ScoradResources.md +41 -0
- package/docs/ScoradScore.md +47 -0
- package/docs/ScoradSubjectiveData.md +32 -0
- package/docs/component.md +68 -0
- package/docs/componentsScoradLogger.md +14 -0
- package/docs/constants.md +99 -0
- package/docs/extent.component.md +86 -0
- package/docs/getScoradScore.md +25 -0
- package/docs/intensity.component.md +77 -0
- package/docs/selectScoradWeights.md +25 -0
- package/docs/subjective.component.md +77 -0
- package/docs/validateScoradData.md +26 -0
- package/docs/weightings.component.md +59 -0
- package/package.json +4 -2
|
@@ -1,18 +1,22 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @
|
|
2
|
+
* @module
|
|
3
|
+
* @group Data
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* Represents the single assessment of the six clinical signs from a representative lesion area.
|
|
3
7
|
* Used for calculating the Intensity Score (B).
|
|
4
8
|
*/
|
|
5
9
|
export type ScoradIntensityData = {
|
|
6
|
-
/**
|
|
10
|
+
/** Erythema (Redness). */
|
|
7
11
|
erythema: number;
|
|
8
|
-
/**
|
|
12
|
+
/** Oedema and Papulation (Swelling/Bumps). */
|
|
9
13
|
oedemaPapulation: number;
|
|
10
|
-
/**
|
|
14
|
+
/** Oozing and Crusting. */
|
|
11
15
|
oozingCrusting: number;
|
|
12
|
-
/**
|
|
16
|
+
/** Excoriations (Scratch marks). */
|
|
13
17
|
excoriations: number;
|
|
14
|
-
/**
|
|
18
|
+
/** Lichenification (Skin thickening). */
|
|
15
19
|
lichenification: number;
|
|
16
|
-
/**
|
|
20
|
+
/** Xerosis (Dryness). */
|
|
17
21
|
xerosis: number;
|
|
18
22
|
};
|
|
@@ -1,9 +1,20 @@
|
|
|
1
1
|
import { ScoradData } from './ScoradData';
|
|
2
|
+
/**
|
|
3
|
+
Localization and UI resources for the SCORAD component.
|
|
4
|
+
Maps data keys to human-readable labels and descriptions for display in the UI.
|
|
5
|
+
*/
|
|
2
6
|
export declare const ScoradResources: ScoradResourceMap<ScoradData>;
|
|
7
|
+
/**
|
|
8
|
+
A single resource item containing UI text strings.
|
|
9
|
+
*/
|
|
3
10
|
export type ScoradResource = {
|
|
4
11
|
text: string;
|
|
5
12
|
description: string;
|
|
6
13
|
};
|
|
14
|
+
/**
|
|
15
|
+
A recursive type that mirrors the structure of a SCORAD data record,
|
|
16
|
+
replacing leaf values with ScoradResource objects.
|
|
17
|
+
*/
|
|
7
18
|
export type ScoradResourceMap<T> = {
|
|
8
19
|
[P in keyof T]: T[P] extends object ? ScoradResourceMap<T[P]> : ScoradResource;
|
|
9
20
|
};
|
package/dist/ScoradScore.d.ts
CHANGED
|
@@ -1,7 +1,20 @@
|
|
|
1
|
-
/**
|
|
1
|
+
/**
|
|
2
|
+
* @module
|
|
3
|
+
* @group Data
|
|
4
|
+
*/
|
|
5
|
+
/** Computed SCORAD values representing the three clinical sections and the final sum.
|
|
6
|
+
*/
|
|
2
7
|
export type ScoradScore = {
|
|
8
|
+
/** Extent (Surface Area): The percentage of body surface area affected, weighted by age.
|
|
9
|
+
*/
|
|
3
10
|
A: number;
|
|
11
|
+
/** Intensity: The sum of the six clinical sign grades (Erythema, Oedema, etc.).
|
|
12
|
+
*/
|
|
4
13
|
B: number;
|
|
14
|
+
/** Subjective Symptoms: The sum of patient-reported pruritus and sleeplessness scores.
|
|
15
|
+
*/
|
|
5
16
|
C: number;
|
|
17
|
+
/** The final calculated score using the standard formula: A/5 + 7B/2 + C.
|
|
18
|
+
*/
|
|
6
19
|
total: number;
|
|
7
20
|
};
|
|
@@ -1,10 +1,14 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @
|
|
2
|
+
* @module
|
|
3
|
+
* @group Data
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* Represents the patient-reported scores for subjective symptoms (Itch/Sleeplessness).
|
|
3
7
|
* Used for calculating the Subjective Score (C).
|
|
4
8
|
*/
|
|
5
9
|
export type ScoradSubjectiveData = {
|
|
6
|
-
/**
|
|
10
|
+
/** Visual Analog Scale (VAS) score (0-10) for Pruritus (Itch) over the last 3 days/nights. */
|
|
7
11
|
pruritus: number;
|
|
8
|
-
/**
|
|
12
|
+
/** Visual Analog Scale (VAS) score (0-10) for Sleeplessness over the last 3 days/nights. */
|
|
9
13
|
sleeplessness: number;
|
|
10
14
|
};
|
package/dist/component.d.ts
CHANGED
|
@@ -1,15 +1,43 @@
|
|
|
1
1
|
import { HTMLComponentElement, EventEmitter } from '@ntix/components-core';
|
|
2
2
|
import { ScoradData } from './ScoradData';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
3
|
+
import { HTMLScoradValueElement } from './HTMLScoradValueElement';
|
|
4
|
+
/**
|
|
5
|
+
* Root component for calculating and displaying the total SCORAD (SCORing Atopic Dermatitis).
|
|
6
|
+
*
|
|
7
|
+
* This component aggregates data from Extent, Intensity, and Subjective sub-components
|
|
8
|
+
* to calculate the final clinical score.
|
|
9
|
+
*/
|
|
10
|
+
export declare class HTMLScoradElement extends HTMLComponentElement<HTMLScoradValueElement<ScoradData>> {
|
|
8
11
|
connectedCallback(): void;
|
|
12
|
+
/**
|
|
13
|
+
* Value is readonly
|
|
14
|
+
* @group Properties
|
|
15
|
+
*/
|
|
16
|
+
readonly: boolean;
|
|
17
|
+
/**
|
|
18
|
+
* The current value of the component.
|
|
19
|
+
* @group Properties
|
|
20
|
+
*/
|
|
9
21
|
value: ScoradData;
|
|
22
|
+
/**
|
|
23
|
+
* Show the errors from validation on the components
|
|
24
|
+
* @group Properties
|
|
25
|
+
* */
|
|
10
26
|
showErrors: boolean;
|
|
11
27
|
afterRender(): void;
|
|
12
28
|
render(): import('@ntix/components-renderer').HTMLLiteralResult;
|
|
13
|
-
|
|
14
|
-
|
|
29
|
+
/**
|
|
30
|
+
* Fired immediately as the user interacts with the input (high frequency).
|
|
31
|
+
*
|
|
32
|
+
* @param detail - The current value during input.
|
|
33
|
+
* @group Events
|
|
34
|
+
*/
|
|
35
|
+
readonly valueInput: EventEmitter<ScoradData>;
|
|
36
|
+
/**
|
|
37
|
+
* Fired when the value is finalized or "committed" by the user.
|
|
38
|
+
*
|
|
39
|
+
* @param detail - The final updated value.
|
|
40
|
+
* @group Events
|
|
41
|
+
*/
|
|
42
|
+
readonly valueChange: EventEmitter<ScoradData>;
|
|
15
43
|
}
|
|
@@ -1 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @module
|
|
3
|
+
* @group Utils
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
Internal logger instance for @ntix/components-scorad.
|
|
7
|
+
Configured with a dedicated namespace and the resolved {@link logLevel}.
|
|
8
|
+
*/
|
|
1
9
|
export declare const componentsScoradLogger: import('@ntix/components-core').ILogger;
|
package/dist/constants.d.ts
CHANGED
|
@@ -3,20 +3,35 @@ import { ScoradExtentData } from './ScoradExtentData';
|
|
|
3
3
|
import { ScoradExtentWeights } from './ScoradExtentWeights';
|
|
4
4
|
import { ScoradIntensityData } from './ScoradIntensityData';
|
|
5
5
|
import { ScoradSubjectiveData } from './ScoradSubjectiveData';
|
|
6
|
+
/** Maximum percentage value allowed for any body region in the Extent (A) calculation. */
|
|
6
7
|
export declare const SCORAD_EXTENT_MAX_VALUE: number;
|
|
8
|
+
/** Maximum grade (0-3) allowed for clinical signs in the Intensity (B) calculation. */
|
|
7
9
|
export declare const SCORAD_INTENSITY_MAX_VALUE: number;
|
|
10
|
+
/** Maximum value (0-10) allowed for patient-reported symptoms in the Subjective (C) calculation. */
|
|
8
11
|
export declare const SCORAD_SUBJECTIVE_MAX_VALUE: number;
|
|
12
|
+
/** Initial state for SCORAD Extent data.
|
|
13
|
+
All regions are initialized as non-null to satisfy record constraints.
|
|
14
|
+
*/
|
|
9
15
|
export declare const SCORAD_EXTENT_DEFAULT: ScoradExtentData;
|
|
16
|
+
/** Initial state for SCORAD Intensity data.
|
|
17
|
+
Represents a baseline where no clinical signs have been graded.
|
|
18
|
+
*/
|
|
10
19
|
export declare const SCORAD_INTENSITY_DEFAULT: ScoradIntensityData;
|
|
20
|
+
/** Initial state for SCORAD Subjective data.
|
|
21
|
+
Represents a baseline for pruritus and sleeplessness.
|
|
22
|
+
*/
|
|
11
23
|
export declare const SCORAD_SUBJECTIVE_DEFAULT: ScoradSubjectiveData;
|
|
24
|
+
/** Global default state for a complete SCORAD assessment.
|
|
25
|
+
Uses adult weighting by default.
|
|
26
|
+
*/
|
|
12
27
|
export declare const SCORAD_DEFAULT: ScoradData;
|
|
13
28
|
/**
|
|
14
|
-
|
|
15
|
-
|
|
29
|
+
Configuration map for the Body Surface Area (BSA) weights for adult SCORAD Extent (A) calculation.
|
|
30
|
+
The values are decimals representing the percentage of total BSA.
|
|
16
31
|
*/
|
|
17
32
|
export declare const SCORAD_ADULT_WEIGHTS: ScoradExtentWeights;
|
|
18
33
|
/**
|
|
19
|
-
|
|
20
|
-
|
|
34
|
+
Configuration map for the Body Surface Area (BSA) weights for child SCORAD Extent (A) calculation.
|
|
35
|
+
The head and neck area is proportionally larger than in adults.
|
|
21
36
|
*/
|
|
22
37
|
export declare const SCORAD_CHILD_WEIGHTS: ScoradExtentWeights;
|
|
@@ -1,24 +1,61 @@
|
|
|
1
1
|
import { HTMLComponentElement, EventEmitter } from '@ntix/components-core';
|
|
2
2
|
import { ScoradExtentData } from '../ScoradExtentData';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
3
|
+
import { HTMLScoradValueElement } from '../HTMLScoradValueElement';
|
|
4
|
+
/**
|
|
5
|
+
* Interactive SVG component for calculating the 'Extent' (A) section of the SCORAD score.
|
|
6
|
+
*
|
|
7
|
+
* Users can interact with different body regions (head, trunk, limbs) via pointer gestures
|
|
8
|
+
* or keyboard input to define the percentage of affected surface area. The component
|
|
9
|
+
* supports different surface area weightings based on the `child` attribute.
|
|
10
|
+
*/
|
|
11
|
+
export declare class HTMLScoradExtentElement extends HTMLComponentElement<HTMLScoradValueElement<ScoradExtentData>> {
|
|
8
12
|
connectedCallback(): void;
|
|
9
13
|
disconnectedCallback(): void;
|
|
10
14
|
private handleFocusIn;
|
|
11
15
|
private handleFocusOut;
|
|
16
|
+
/**
|
|
17
|
+
* Extent score is to be weighted as a child or adult
|
|
18
|
+
* @group Properties
|
|
19
|
+
*/
|
|
12
20
|
child: boolean;
|
|
21
|
+
/**
|
|
22
|
+
* Value is readonly
|
|
23
|
+
* @group Properties
|
|
24
|
+
*/
|
|
13
25
|
readonly: boolean;
|
|
14
|
-
committedValue
|
|
26
|
+
private committedValue;
|
|
27
|
+
/**
|
|
28
|
+
* The current value of the component.
|
|
29
|
+
* @group Properties
|
|
30
|
+
*/
|
|
15
31
|
value: ScoradExtentData;
|
|
32
|
+
/**
|
|
33
|
+
* Subjective SCORAD score (A)
|
|
34
|
+
* @group Properties
|
|
35
|
+
*/
|
|
16
36
|
score?: number;
|
|
17
37
|
setValue: (value: ScoradExtentData) => void;
|
|
38
|
+
/**
|
|
39
|
+
* validation errors
|
|
40
|
+
* shows as has-errors attribute
|
|
41
|
+
* @group Properties
|
|
42
|
+
*/
|
|
18
43
|
errors?: Record<string, string>;
|
|
19
44
|
afterRender(): void;
|
|
20
45
|
resizeCallback(): void;
|
|
21
46
|
render(): import('@ntix/components-renderer').HTMLLiteralResult;
|
|
22
|
-
|
|
23
|
-
|
|
47
|
+
/**
|
|
48
|
+
* Fired immediately as the user interacts with the input (high frequency).
|
|
49
|
+
*
|
|
50
|
+
* @param detail - The current value during input.
|
|
51
|
+
* @group Events
|
|
52
|
+
*/
|
|
53
|
+
readonly valueInput: EventEmitter<ScoradExtentData>;
|
|
54
|
+
/**
|
|
55
|
+
* Fired when the value is finalized or "committed" by the user.
|
|
56
|
+
*
|
|
57
|
+
* @param detail - The final updated value.
|
|
58
|
+
* @group Events
|
|
59
|
+
*/
|
|
60
|
+
readonly valueChange: EventEmitter<ScoradExtentData>;
|
|
24
61
|
}
|
package/dist/getScoradScore.d.ts
CHANGED
|
@@ -2,9 +2,8 @@ import { Result } from '@ntix/components-core';
|
|
|
2
2
|
import { ScoradData } from './ScoradData';
|
|
3
3
|
import { ScoradScore } from './ScoradScore';
|
|
4
4
|
/**
|
|
5
|
-
*
|
|
5
|
+
* Calculates the final composite SCORAD score (A/5 + 7B/2 + C) from the raw data.
|
|
6
6
|
* @param data - The complete ScoradData input object.
|
|
7
|
-
* @param weights - The BSA weighting configuration (defaults to adult weights).
|
|
8
7
|
* @returns The final SCORAD score, rounded to two decimal places.
|
|
9
8
|
*/
|
|
10
9
|
export declare const getScoradScore: (data: ScoradData | null | undefined) => Result<ScoradScore>;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,18 +1,50 @@
|
|
|
1
1
|
import { HTMLComponentElement, EventEmitter } from '@ntix/components-core';
|
|
2
2
|
import { ScoradIntensityData } from '../ScoradIntensityData';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
3
|
+
import { HTMLScoradValueElement } from '../HTMLScoradValueElement';
|
|
4
|
+
/**
|
|
5
|
+
* Component for assessing the 'Intensity' (B) criteria of the SCORAD score.
|
|
6
|
+
*
|
|
7
|
+
* It renders a list of clinical signs (e.g., Erythema, Edema, Oozing) and allows
|
|
8
|
+
* the user to grade each on a scale of 0 to 3 using integrated option pickers.
|
|
9
|
+
*/
|
|
10
|
+
export declare class HTMLScoradIntensityElement extends HTMLComponentElement<HTMLScoradValueElement<ScoradIntensityData>> {
|
|
8
11
|
connectedCallback(): void;
|
|
12
|
+
/**
|
|
13
|
+
* Value is readonly
|
|
14
|
+
* @group Properties
|
|
15
|
+
*/
|
|
9
16
|
readonly: boolean;
|
|
17
|
+
/**
|
|
18
|
+
* The current value of the component.
|
|
19
|
+
* @group Properties
|
|
20
|
+
*/
|
|
10
21
|
value: ScoradIntensityData;
|
|
22
|
+
/**
|
|
23
|
+
* Subjective SCORAD score (B)
|
|
24
|
+
* @group Properties
|
|
25
|
+
*/
|
|
11
26
|
score?: number;
|
|
27
|
+
/**
|
|
28
|
+
* validation errors
|
|
29
|
+
* shows as has-errors attribute
|
|
30
|
+
* @group Properties
|
|
31
|
+
*/
|
|
12
32
|
errors?: Record<string, string>;
|
|
13
33
|
afterRender(): void;
|
|
14
34
|
render(): import('@ntix/components-renderer').HTMLLiteralResult;
|
|
15
35
|
renderLevel(name: keyof ScoradIntensityData): import('@ntix/components-renderer').HTMLLiteralResult;
|
|
16
|
-
|
|
17
|
-
|
|
36
|
+
/**
|
|
37
|
+
* Fired immediately as the user interacts with the input (high frequency).
|
|
38
|
+
*
|
|
39
|
+
* @param detail - The current value during input.
|
|
40
|
+
* @group Events
|
|
41
|
+
*/
|
|
42
|
+
readonly valueInput: EventEmitter<ScoradIntensityData>;
|
|
43
|
+
/**
|
|
44
|
+
* Fired when the value is finalized or "committed" by the user.
|
|
45
|
+
*
|
|
46
|
+
* @param detail - The final updated value.
|
|
47
|
+
* @group Events
|
|
48
|
+
*/
|
|
49
|
+
readonly valueChange: EventEmitter<ScoradIntensityData>;
|
|
18
50
|
}
|
|
@@ -4,7 +4,7 @@ export interface HTMLScoradLabelElementEventMap extends HTMLElementEventMap {
|
|
|
4
4
|
export declare class HTMLScoradLabelElement extends HTMLComponentElement<HTMLScoradLabelElementEventMap> {
|
|
5
5
|
connectedCallback(): void;
|
|
6
6
|
diconnectedCallback(): void;
|
|
7
|
-
|
|
7
|
+
private handleClick;
|
|
8
8
|
text: string;
|
|
9
9
|
description?: string;
|
|
10
10
|
render(): import('@ntix/components-renderer').HTMLLiteralResult;
|
|
@@ -1,9 +1,6 @@
|
|
|
1
1
|
import { HTMLComponentElement, EventEmitter } from '@ntix/components-core';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
'value-change': CustomEvent<number>;
|
|
5
|
-
}
|
|
6
|
-
export declare class HTMLScoradOptionsElement extends HTMLComponentElement<HTMLScoradOptionsElementEventMap> {
|
|
2
|
+
import { HTMLScoradValueElement } from '../HTMLScoradValueElement';
|
|
3
|
+
export declare class HTMLScoradOptionsElement extends HTMLComponentElement<HTMLScoradValueElement<number>> {
|
|
7
4
|
connectedCallback(): void;
|
|
8
5
|
disconnectedCallback(): void;
|
|
9
6
|
private handleFocusIn;
|
|
@@ -20,6 +17,6 @@ export declare class HTMLScoradOptionsElement extends HTMLComponentElement<HTMLS
|
|
|
20
17
|
text: string[];
|
|
21
18
|
render(): import('@ntix/components-renderer').HTMLLiteralResult;
|
|
22
19
|
afterRender(): void;
|
|
23
|
-
valueInput: EventEmitter<number>;
|
|
24
|
-
valueChange: EventEmitter<number>;
|
|
20
|
+
readonly valueInput: EventEmitter<number>;
|
|
21
|
+
readonly valueChange: EventEmitter<number>;
|
|
25
22
|
}
|
|
@@ -1,17 +1,50 @@
|
|
|
1
1
|
import { HTMLComponentElement, EventEmitter } from '@ntix/components-core';
|
|
2
2
|
import { ScoradSubjectiveData } from '../ScoradSubjectiveData';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
3
|
+
import { HTMLScoradValueElement } from '../HTMLScoradValueElement';
|
|
4
|
+
/**
|
|
5
|
+
* Component for assessing the 'Subjective' (C) criteria of the SCORAD score.
|
|
6
|
+
*
|
|
7
|
+
* It provides visual analog scales (VAS) for patients to self-report symptoms
|
|
8
|
+
* such as pruritus (itching) and insomnia (sleep loss) over the last 3 days.
|
|
9
|
+
*/
|
|
10
|
+
export declare class HTMLScoradSubjectiveElement extends HTMLComponentElement<HTMLScoradValueElement<ScoradSubjectiveData>> {
|
|
8
11
|
connectedCallback(): void;
|
|
12
|
+
/**
|
|
13
|
+
* Value is readonly
|
|
14
|
+
* @group Properties
|
|
15
|
+
*/
|
|
16
|
+
readonly: boolean;
|
|
17
|
+
/**
|
|
18
|
+
* The current value of the component.
|
|
19
|
+
* @group Properties
|
|
20
|
+
*/
|
|
9
21
|
value: ScoradSubjectiveData;
|
|
22
|
+
/**
|
|
23
|
+
* Subjective SCORAD score (C)
|
|
24
|
+
* @group Properties
|
|
25
|
+
*/
|
|
10
26
|
score?: number;
|
|
27
|
+
/**
|
|
28
|
+
* validation errors
|
|
29
|
+
* shows as has-errors attribute
|
|
30
|
+
* @group Properties
|
|
31
|
+
*/
|
|
11
32
|
errors?: Record<string, string>;
|
|
12
33
|
afterRender(): void;
|
|
13
34
|
render(): import('@ntix/components-renderer').HTMLLiteralResult;
|
|
14
35
|
renderLevel(name: keyof ScoradSubjectiveData): import('@ntix/components-renderer').HTMLLiteralResult;
|
|
15
|
-
|
|
16
|
-
|
|
36
|
+
/**
|
|
37
|
+
* Fired immediately as the user interacts with the input (high frequency).
|
|
38
|
+
*
|
|
39
|
+
* @param detail - The current value during input.
|
|
40
|
+
* @group Events
|
|
41
|
+
*/
|
|
42
|
+
readonly valueInput: EventEmitter<ScoradSubjectiveData>;
|
|
43
|
+
/**
|
|
44
|
+
* Fired when the value is finalized or "committed" by the user.
|
|
45
|
+
*
|
|
46
|
+
* @param detail - The final updated value.
|
|
47
|
+
* @group Events
|
|
48
|
+
*/
|
|
49
|
+
readonly valueChange: EventEmitter<ScoradSubjectiveData>;
|
|
17
50
|
}
|
|
@@ -1,13 +1,36 @@
|
|
|
1
1
|
import { HTMLComponentElement, EventEmitter } from '@ntix/components-core';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
2
|
+
import { HTMLScoradValueElement } from '../HTMLScoradValueElement';
|
|
3
|
+
/**
|
|
4
|
+
* A toggle component to switch between 'Adult' and 'Child' SCORAD calculation weightings.
|
|
5
|
+
* This component maps a boolean state to specific clinical weighting logic,
|
|
6
|
+
* primarily influencing the surface area calculation in the Extent (Section A) component.
|
|
7
|
+
*/
|
|
8
|
+
export declare class HTMLScoradWeightingsElement extends HTMLComponentElement<HTMLScoradValueElement<boolean>> {
|
|
7
9
|
connectedCallback(): void;
|
|
10
|
+
/**
|
|
11
|
+
* Value is readonly
|
|
12
|
+
* @group Properties
|
|
13
|
+
*/
|
|
14
|
+
readonly: boolean;
|
|
15
|
+
/**
|
|
16
|
+
* The current value of the component.
|
|
17
|
+
* @group Properties
|
|
18
|
+
*/
|
|
8
19
|
value: boolean;
|
|
9
20
|
afterRender(): void;
|
|
10
21
|
render(): import('@ntix/components-renderer').HTMLLiteralResult;
|
|
11
|
-
|
|
12
|
-
|
|
22
|
+
/**
|
|
23
|
+
* Fired immediately as the user interacts with the input (high frequency).
|
|
24
|
+
*
|
|
25
|
+
* @param detail - The current value during input.
|
|
26
|
+
* @group Events
|
|
27
|
+
*/
|
|
28
|
+
readonly valueInput: EventEmitter<boolean>;
|
|
29
|
+
/**
|
|
30
|
+
* Fired when the value is finalized or "committed" by the user.
|
|
31
|
+
*
|
|
32
|
+
* @param detail - The final updated value.
|
|
33
|
+
* @group Events
|
|
34
|
+
*/
|
|
35
|
+
readonly valueChange: EventEmitter<boolean>;
|
|
13
36
|
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
[**@ntix/components-scorad**](README.md)
|
|
2
|
+
|
|
3
|
+
***
|
|
4
|
+
|
|
5
|
+
## Interfaces
|
|
6
|
+
|
|
7
|
+
### HTMLScoradValueElement
|
|
8
|
+
|
|
9
|
+
Common interface for SCORAD input elements.
|
|
10
|
+
|
|
11
|
+
This interface defines the standard reactive contract for components that manage a generic score value.
|
|
12
|
+
|
|
13
|
+
#### Extends
|
|
14
|
+
|
|
15
|
+
- `HTMLElementEventMap`
|
|
16
|
+
|
|
17
|
+
#### Type Parameters
|
|
18
|
+
|
|
19
|
+
| Type Parameter | Description |
|
|
20
|
+
| ------ | ------ |
|
|
21
|
+
| `T` | The data type of the SCORAD value |
|
|
22
|
+
|
|
23
|
+
#### Events
|
|
24
|
+
|
|
25
|
+
| Event | Modifier | Type | Description |
|
|
26
|
+
| ------ | ------ | ------ | ------ |
|
|
27
|
+
| <a id="value-change"></a> `value-change` | `readonly` | `CustomEvent`\<`T`\> | Fired when the value is finalized or "committed" by the user. **Param** The final updated value of type [T](#t). |
|
|
28
|
+
| <a id="value-input"></a> `value-input` | `readonly` | `CustomEvent`\<`T`\> | Fired immediately as the user interacts with the input (high frequency). **Param** The current value of type [T](#t) during input. |
|
|
29
|
+
|
|
30
|
+
#### Properties
|
|
31
|
+
|
|
32
|
+
| Property | Modifier | Type | Description |
|
|
33
|
+
| ------ | ------ | ------ | ------ |
|
|
34
|
+
| <a id="readonly"></a> `readonly` | `public` | `boolean` | Value is readonly |
|
|
35
|
+
| <a id="value"></a> `value` | `readonly` | `T` | The current value of the component. |
|
package/docs/README.md
ADDED
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
**@ntix/components-scorad**
|
|
2
|
+
|
|
3
|
+
***
|
|
4
|
+
|
|
5
|
+
## Components
|
|
6
|
+
|
|
7
|
+
- [component](component.md)
|
|
8
|
+
- [extent/component](extent.component.md)
|
|
9
|
+
- [HTMLScoradValueElement](HTMLScoradValueElement.md)
|
|
10
|
+
- [intensity/component](intensity.component.md)
|
|
11
|
+
- [subjective/component](subjective.component.md)
|
|
12
|
+
- [weightings/component](weightings.component.md)
|
|
13
|
+
|
|
14
|
+
## Data
|
|
15
|
+
|
|
16
|
+
- [constants](constants.md)
|
|
17
|
+
- [ScoradData](ScoradData.md)
|
|
18
|
+
- [ScoradExtentData](ScoradExtentData.md)
|
|
19
|
+
- [ScoradExtentWeights](ScoradExtentWeights.md)
|
|
20
|
+
- [ScoradIntensityData](ScoradIntensityData.md)
|
|
21
|
+
- [ScoradScore](ScoradScore.md)
|
|
22
|
+
- [ScoradSubjectiveData](ScoradSubjectiveData.md)
|
|
23
|
+
- [selectScoradWeights](selectScoradWeights.md)
|
|
24
|
+
|
|
25
|
+
## Functions
|
|
26
|
+
|
|
27
|
+
- [getScoradScore](getScoradScore.md)
|
|
28
|
+
- [validateScoradData](validateScoradData.md)
|
|
29
|
+
|
|
30
|
+
## Resources
|
|
31
|
+
|
|
32
|
+
- [ScoradResources](ScoradResources.md)
|
|
33
|
+
|
|
34
|
+
## Utils
|
|
35
|
+
|
|
36
|
+
- [componentsScoradLogger](componentsScoradLogger.md)
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
[**@ntix/components-scorad**](README.md)
|
|
2
|
+
|
|
3
|
+
***
|
|
4
|
+
|
|
5
|
+
## Type Aliases
|
|
6
|
+
|
|
7
|
+
### ScoradExtentData
|
|
8
|
+
|
|
9
|
+
```ts
|
|
10
|
+
type ScoradExtentData = object;
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
Represents the raw percentage affected (0-100) for each of the six SCORAD regions.
|
|
14
|
+
|
|
15
|
+
#### Properties
|
|
16
|
+
|
|
17
|
+
##### anteriorTrunk
|
|
18
|
+
|
|
19
|
+
```ts
|
|
20
|
+
anteriorTrunk: number;
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
Percentage (0-100) of the Anterior Trunk region affected.
|
|
24
|
+
|
|
25
|
+
##### genitals
|
|
26
|
+
|
|
27
|
+
```ts
|
|
28
|
+
genitals: number;
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
Percentage (0-100) of the Genital region affected.
|
|
32
|
+
|
|
33
|
+
##### headNeck
|
|
34
|
+
|
|
35
|
+
```ts
|
|
36
|
+
headNeck: number;
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
Percentage (0-100) of the Head and Neck region affected.
|
|
40
|
+
|
|
41
|
+
##### lowerLimbs
|
|
42
|
+
|
|
43
|
+
```ts
|
|
44
|
+
lowerLimbs: number;
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
Percentage (0-100) of the Lower Limbs region affected.
|
|
48
|
+
|
|
49
|
+
##### posteriorTrunk
|
|
50
|
+
|
|
51
|
+
```ts
|
|
52
|
+
posteriorTrunk: number;
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
Percentage (0-100) of the Posterior Trunk region affected.
|
|
56
|
+
|
|
57
|
+
##### upperLimbs
|
|
58
|
+
|
|
59
|
+
```ts
|
|
60
|
+
upperLimbs: number;
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
Percentage (0-100) of the Upper Limbs region affected.
|