@nakafa/aksara-contracts 6.4.0 → 7.0.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/dist/assessment/catalog.d.ts +30 -6
- package/dist/assessment/catalog.js +33 -10
- package/dist/assessment/choice.d.ts +10 -0
- package/dist/assessment/closure.d.ts +2 -1
- package/dist/assessment/closure.js +43 -62
- package/dist/assessment/document.d.ts +18 -0
- package/dist/assessment/document.js +10 -0
- package/dist/assessment/figure.d.ts +47605 -1555
- package/dist/assessment/figure.js +14 -217
- package/dist/assessment/hash.d.ts +274 -4
- package/dist/assessment/inline.d.ts +25 -0
- package/dist/assessment/inline.js +22 -3
- package/dist/assessment/interaction.d.ts +10 -0
- package/dist/assessment/item.d.ts +864 -0
- package/dist/assessment/item.js +10 -2
- package/dist/assessment/locales.d.ts +10 -0
- package/dist/assessment/locales.js +58 -0
- package/dist/assessment/paper.d.ts +1349 -12
- package/dist/assessment/paper.js +93 -9
- package/dist/assessment/part.d.ts +5 -0
- package/dist/assessment/profile.d.ts +4 -4
- package/dist/assessment/rows.d.ts +1409 -0
- package/dist/assessment/rows.js +44 -0
- package/dist/assessment/scalar.d.ts +1 -1
- package/dist/assessment/scoring.d.ts +1 -1
- package/dist/assessment/snapshot.d.ts +376 -20
- package/dist/assessment/structure.d.ts +6 -0
- package/dist/assessment/structure.js +22 -2
- package/dist/locale.d.ts +9 -9
- package/dist/locale.js +4 -3
- package/dist/program/snapshot/hash.d.ts +2 -2
- package/dist/program/snapshot/spec.d.ts +2 -2
- package/dist/projection/material.d.ts +10 -0
- package/dist/projection/material.js +1 -1
- package/dist/quran/attribution.d.ts +2 -2
- package/dist/quran/identity.d.ts +31 -10
- package/dist/quran/identity.js +15 -3
- package/dist/quran/provenance.d.ts +16 -16
- package/dist/quran/provenance.js +4 -1
- package/dist/quran/snapshot/hash.d.ts +2 -2
- package/dist/quran/snapshot/row/hash.d.ts +48 -15
- package/dist/quran/snapshot/row.d.ts +18 -8
- package/dist/quran/snapshot/spec.d.ts +2 -2
- package/dist/quran/source.d.ts +17 -7
- package/dist/quran/source.js +13 -1
- package/dist/quran/spec.d.ts +4 -4
- package/dist/quran/spec.js +2 -1
- package/dist/release/current/evidence.d.ts +9 -9
- package/dist/release/current/state.d.ts +11 -11
- package/dist/release/hash.d.ts +2 -2
- package/dist/release/identity.d.ts +1 -1
- package/dist/release/lifecycle.d.ts +7 -7
- package/dist/release/policy.d.ts +1 -1
- package/dist/release/snapshot/data.d.ts +37 -11
- package/dist/release/snapshot/evidence/assessment.d.ts +1 -1
- package/dist/release/snapshot/evidence/program.d.ts +1 -1
- package/dist/release/snapshot/evidence/quran.d.ts +1 -1
- package/dist/release/snapshot/evidence.d.ts +3 -3
- package/dist/release/snapshot/verify.d.ts +180 -12
- package/dist/release/spec.d.ts +13 -13
- package/dist/release/verify.d.ts +2 -2
- package/dist/runtime/spec.d.ts +6 -6
- package/dist/runtime/verify.d.ts +4 -4
- package/dist/transport/group.d.ts +111 -33
- package/dist/transport/request.d.ts +1174 -114
- package/dist/transport/response.d.ts +64 -64
- package/dist/transport/snapshot.d.ts +74 -22
- package/dist/visual/base/layout.d.ts +27 -0
- package/dist/visual/base/layout.js +35 -0
- package/dist/visual/base/math.d.ts +523 -0
- package/dist/visual/base/math.js +72 -0
- package/dist/visual/base/media.d.ts +13 -0
- package/dist/visual/base/media.js +25 -0
- package/dist/visual/biology.d.ts +203 -0
- package/dist/visual/biology.js +108 -0
- package/dist/visual/card.d.ts +32 -0
- package/dist/visual/card.js +30 -0
- package/dist/visual/catalog.d.ts +28633 -0
- package/dist/visual/catalog.js +73 -0
- package/dist/visual/chemistry/atom.d.ts +79 -0
- package/dist/visual/chemistry/atom.js +109 -0
- package/dist/visual/chemistry/electron.d.ts +41 -0
- package/dist/visual/chemistry/electron.js +69 -0
- package/dist/visual/chemistry/laws.d.ts +86 -0
- package/dist/visual/chemistry/laws.js +117 -0
- package/dist/visual/chemistry/particles.d.ts +114 -0
- package/dist/visual/chemistry/particles.js +149 -0
- package/dist/visual/chemistry/periodic.d.ts +52 -0
- package/dist/visual/chemistry/periodic.js +85 -0
- package/dist/visual/chemistry/reaction.d.ts +60 -0
- package/dist/visual/chemistry/reaction.js +76 -0
- package/dist/visual/entry.d.ts +42 -0
- package/dist/visual/entry.js +48 -0
- package/dist/visual/mathematics/chart.d.ts +30 -0
- package/dist/{assessment → visual/mathematics}/chart.js +26 -18
- package/dist/visual/mathematics/charts.d.ts +118 -0
- package/dist/visual/mathematics/charts.js +100 -0
- package/dist/visual/mathematics/function.d.ts +82 -0
- package/dist/visual/mathematics/function.js +102 -0
- package/dist/visual/mathematics/geometry.d.ts +222 -0
- package/dist/visual/mathematics/geometry.js +81 -0
- package/dist/visual/mathematics/line.d.ts +179 -0
- package/dist/visual/mathematics/line.js +156 -0
- package/dist/visual/mathematics/number.d.ts +21 -0
- package/dist/visual/mathematics/number.js +53 -0
- package/dist/visual/physics/measurement.d.ts +66 -0
- package/dist/visual/physics/measurement.js +85 -0
- package/dist/visual/physics/motion.d.ts +85 -0
- package/dist/visual/physics/motion.js +110 -0
- package/dist/visual/physics/parabolic.d.ts +42 -0
- package/dist/visual/physics/parabolic.js +56 -0
- package/dist/visual/physics/velocity.d.ts +112 -0
- package/dist/visual/physics/velocity.js +144 -0
- package/dist/visual/politics.d.ts +92 -0
- package/dist/visual/politics.js +76 -0
- package/package.json +13 -5
- package/dist/assessment/chart.d.ts +0 -62
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
import { Schema } from "effect";
|
|
2
|
+
import { byIds, cardFields, DecimalSeparatorSchema, TextSchema, } from "#contracts/visual/card";
|
|
3
|
+
import { answerAt, figure } from "#contracts/visual/entry";
|
|
4
|
+
/** The routes the average velocity lab compares. */
|
|
5
|
+
const AVERAGE_CASES = ["straight", "bank", "loop"];
|
|
6
|
+
/** The trips the velocity and speed lab compares. */
|
|
7
|
+
const VELOCITY_CASES = ["forward", "partialReturn", "backToStart"];
|
|
8
|
+
/** The routes the displacement and distance lab compares. */
|
|
9
|
+
const DISPLACEMENT_CASES = ["straight", "turn", "return"];
|
|
10
|
+
/** The two directions an observer can see a target move. */
|
|
11
|
+
const DIRECTIONS = ["left", "right"];
|
|
12
|
+
/** The cases of relative motion. */
|
|
13
|
+
const RELATIVE_CASES = ["same-direction", "opposite-direction"];
|
|
14
|
+
/** The motions of the vertical lab: a ball thrown up, or dropped. */
|
|
15
|
+
const VERTICAL_MODES = ["throw", "drop"];
|
|
16
|
+
/** Props of `AverageVelocitySpeedLab`: average velocity against average speed. */
|
|
17
|
+
function averageVelocityLab(rich) {
|
|
18
|
+
return figure(Schema.Struct({
|
|
19
|
+
...cardFields(rich),
|
|
20
|
+
decimalSeparator: Schema.optionalKey(DecimalSeparatorSchema),
|
|
21
|
+
labels: Schema.Struct({
|
|
22
|
+
chooseCase: TextSchema,
|
|
23
|
+
factLabels: Schema.Struct({
|
|
24
|
+
displacement: rich,
|
|
25
|
+
distance: rich,
|
|
26
|
+
speed: rich,
|
|
27
|
+
time: rich,
|
|
28
|
+
velocity: rich,
|
|
29
|
+
}),
|
|
30
|
+
modeLabels: byIds(AVERAGE_CASES, rich),
|
|
31
|
+
viewLabel: TextSchema,
|
|
32
|
+
}),
|
|
33
|
+
}));
|
|
34
|
+
}
|
|
35
|
+
/** Props of `InstantaneousVelocitySpeedLab`: velocity and speed at one moment. */
|
|
36
|
+
function instantaneousLab(rich) {
|
|
37
|
+
return figure(Schema.Struct({
|
|
38
|
+
...cardFields(rich),
|
|
39
|
+
labels: Schema.Struct({
|
|
40
|
+
chooseMoment: TextSchema,
|
|
41
|
+
factLabels: Schema.Struct({ speed: rich, time: rich, velocity: rich }),
|
|
42
|
+
viewLabel: TextSchema,
|
|
43
|
+
}),
|
|
44
|
+
}));
|
|
45
|
+
}
|
|
46
|
+
/** Props of `VelocitySpeedLab`: a trip that goes and comes back. */
|
|
47
|
+
function velocitySpeedLab(rich) {
|
|
48
|
+
return figure(Schema.Struct({
|
|
49
|
+
...cardFields(rich),
|
|
50
|
+
labels: Schema.Struct({
|
|
51
|
+
chooseCase: TextSchema,
|
|
52
|
+
factLabels: Schema.Struct({
|
|
53
|
+
displacement: rich,
|
|
54
|
+
distance: rich,
|
|
55
|
+
speed: rich,
|
|
56
|
+
velocity: rich,
|
|
57
|
+
}),
|
|
58
|
+
modeLabels: byIds(VELOCITY_CASES, rich),
|
|
59
|
+
viewLabel: TextSchema,
|
|
60
|
+
}),
|
|
61
|
+
}));
|
|
62
|
+
}
|
|
63
|
+
/** Props of `DisplacementDistanceLab`: the path walked against the change of place. */
|
|
64
|
+
function displacementLab(rich) {
|
|
65
|
+
return figure(Schema.Struct({
|
|
66
|
+
...cardFields(rich),
|
|
67
|
+
labels: Schema.Struct({
|
|
68
|
+
chooseCase: TextSchema,
|
|
69
|
+
factLabels: Schema.Struct({
|
|
70
|
+
displacement: rich,
|
|
71
|
+
distance: rich,
|
|
72
|
+
meaning: rich,
|
|
73
|
+
vector: rich,
|
|
74
|
+
}),
|
|
75
|
+
meanings: byIds(DISPLACEMENT_CASES, rich),
|
|
76
|
+
modeLabels: byIds(DISPLACEMENT_CASES, rich),
|
|
77
|
+
viewLabel: TextSchema,
|
|
78
|
+
}),
|
|
79
|
+
}), answerAt(["labels", "meanings"]));
|
|
80
|
+
}
|
|
81
|
+
/** Props of `StoppingDistanceLab`: reaction distance plus braking distance. */
|
|
82
|
+
function stoppingDistanceLab(rich) {
|
|
83
|
+
return figure(Schema.Struct({
|
|
84
|
+
...cardFields(rich),
|
|
85
|
+
labels: Schema.Struct({
|
|
86
|
+
brakingDistance: rich,
|
|
87
|
+
chooseSpeed: TextSchema,
|
|
88
|
+
reactionDistance: rich,
|
|
89
|
+
speed: rich,
|
|
90
|
+
stoppingDistance: rich,
|
|
91
|
+
viewLabel: TextSchema,
|
|
92
|
+
}),
|
|
93
|
+
}));
|
|
94
|
+
}
|
|
95
|
+
/** Props of `RelativeMovementLab`: motion seen from a moving observer. */
|
|
96
|
+
function relativeMovementLab(rich) {
|
|
97
|
+
return figure(Schema.Struct({
|
|
98
|
+
...cardFields(rich),
|
|
99
|
+
labels: Schema.Struct({
|
|
100
|
+
chooseCase: TextSchema,
|
|
101
|
+
directionLabels: byIds(DIRECTIONS, rich),
|
|
102
|
+
factLabels: Schema.Struct({
|
|
103
|
+
observer: rich,
|
|
104
|
+
relativeVelocity: rich,
|
|
105
|
+
target: rich,
|
|
106
|
+
visibleDirection: rich,
|
|
107
|
+
}),
|
|
108
|
+
modeLabels: byIds(RELATIVE_CASES, rich),
|
|
109
|
+
viewLabel: TextSchema,
|
|
110
|
+
}),
|
|
111
|
+
}));
|
|
112
|
+
}
|
|
113
|
+
/** Props of `VerticalMovementLab`: throws up, throws down, and free fall. */
|
|
114
|
+
function verticalMovementLab(rich) {
|
|
115
|
+
return figure(Schema.Struct({
|
|
116
|
+
...cardFields(rich),
|
|
117
|
+
decimalSeparator: Schema.optionalKey(DecimalSeparatorSchema),
|
|
118
|
+
labels: Schema.Struct({
|
|
119
|
+
condition: TextSchema,
|
|
120
|
+
finalVelocity: rich,
|
|
121
|
+
initialCondition: rich,
|
|
122
|
+
maxHeight: rich,
|
|
123
|
+
modeLabels: byIds(VERTICAL_MODES, rich),
|
|
124
|
+
time: rich,
|
|
125
|
+
viewLabel: TextSchema,
|
|
126
|
+
}),
|
|
127
|
+
}));
|
|
128
|
+
}
|
|
129
|
+
/**
|
|
130
|
+
* The labs of velocity, distance, and relative motion. The meaning of each
|
|
131
|
+
* route says what its displacement shows, so it is answer state; every other
|
|
132
|
+
* label names a quantity the reader measures.
|
|
133
|
+
*/
|
|
134
|
+
export function velocityVisuals(rich) {
|
|
135
|
+
return {
|
|
136
|
+
AverageVelocitySpeedLab: averageVelocityLab(rich),
|
|
137
|
+
DisplacementDistanceLab: displacementLab(rich),
|
|
138
|
+
InstantaneousVelocitySpeedLab: instantaneousLab(rich),
|
|
139
|
+
RelativeMovementLab: relativeMovementLab(rich),
|
|
140
|
+
StoppingDistanceLab: stoppingDistanceLab(rich),
|
|
141
|
+
VelocitySpeedLab: velocitySpeedLab(rich),
|
|
142
|
+
VerticalMovementLab: verticalMovementLab(rich),
|
|
143
|
+
};
|
|
144
|
+
}
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import { Schema } from "effect";
|
|
2
|
+
import { type RichSlot } from "#contracts/visual/card";
|
|
3
|
+
/**
|
|
4
|
+
* The politics charts and tables. Each draws sourced data that the component
|
|
5
|
+
* holds, and its labels name the series, so no prop holds answer state.
|
|
6
|
+
*/
|
|
7
|
+
export declare function politicsVisuals<E>(rich: RichSlot<E>): {
|
|
8
|
+
KimPlusElectabilityChart: import("#contracts/visual/entry").VisualEntry<Schema.Struct<{
|
|
9
|
+
readonly description: RichSlot<E>;
|
|
10
|
+
readonly title: RichSlot<E>;
|
|
11
|
+
readonly footnote: RichSlot<E>;
|
|
12
|
+
readonly labels: Schema.Struct<{
|
|
13
|
+
electability: RichSlot<E>;
|
|
14
|
+
notAnswering: Schema.Trimmed;
|
|
15
|
+
}>;
|
|
16
|
+
}>>;
|
|
17
|
+
MerahPutihCabinetChart: import("#contracts/visual/entry").VisualEntry<Schema.Struct<{
|
|
18
|
+
readonly description: RichSlot<E>;
|
|
19
|
+
readonly title: RichSlot<E>;
|
|
20
|
+
readonly footnote: RichSlot<E>;
|
|
21
|
+
readonly labels: Schema.Struct<{
|
|
22
|
+
cabinet: RichSlot<E>;
|
|
23
|
+
}>;
|
|
24
|
+
}>>;
|
|
25
|
+
MerahPutihCompositionChart: import("#contracts/visual/entry").VisualEntry<Schema.Struct<{
|
|
26
|
+
readonly description: RichSlot<E>;
|
|
27
|
+
readonly title: RichSlot<E>;
|
|
28
|
+
readonly footnote: RichSlot<E>;
|
|
29
|
+
readonly labels: Schema.Struct<{
|
|
30
|
+
female: RichSlot<E>;
|
|
31
|
+
gender: Schema.Trimmed;
|
|
32
|
+
incumbent: RichSlot<E>;
|
|
33
|
+
male: RichSlot<E>;
|
|
34
|
+
minister: Schema.Trimmed;
|
|
35
|
+
new: RichSlot<E>;
|
|
36
|
+
nonPoliticians: RichSlot<E>;
|
|
37
|
+
politicalStatus: Schema.Trimmed;
|
|
38
|
+
politicians: RichSlot<E>;
|
|
39
|
+
}>;
|
|
40
|
+
}>>;
|
|
41
|
+
NepotismStage: import("#contracts/visual/entry").VisualEntry<Schema.Struct<{
|
|
42
|
+
readonly description: Schema.optionalKey<RichSlot<E>>;
|
|
43
|
+
readonly labels: Schema.Struct<{
|
|
44
|
+
readonly delivery: RichSlot<E>;
|
|
45
|
+
readonly election: RichSlot<E>;
|
|
46
|
+
readonly selection: RichSlot<E>;
|
|
47
|
+
}>;
|
|
48
|
+
readonly title: RichSlot<E>;
|
|
49
|
+
}>>;
|
|
50
|
+
NepotismStateTable: import("#contracts/visual/entry").VisualEntry<Schema.Struct<{
|
|
51
|
+
readonly caption: RichSlot<E>;
|
|
52
|
+
readonly labels: Schema.Struct<{
|
|
53
|
+
readonly corruptionIndex: RichSlot<E>;
|
|
54
|
+
readonly country: RichSlot<E>;
|
|
55
|
+
readonly good: RichSlot<E>;
|
|
56
|
+
readonly goodGovernanceIndex: RichSlot<E>;
|
|
57
|
+
readonly governanceQualityCategory: RichSlot<E>;
|
|
58
|
+
readonly judicialEfficiencyIndex: RichSlot<E>;
|
|
59
|
+
readonly low: RichSlot<E>;
|
|
60
|
+
readonly medium: RichSlot<E>;
|
|
61
|
+
}>;
|
|
62
|
+
}>>;
|
|
63
|
+
PorkBarrelBudgetChart: import("#contracts/visual/entry").VisualEntry<Schema.Struct<{
|
|
64
|
+
readonly description: RichSlot<E>;
|
|
65
|
+
readonly title: RichSlot<E>;
|
|
66
|
+
readonly footnote: RichSlot<E>;
|
|
67
|
+
readonly labels: Schema.Struct<{
|
|
68
|
+
budget: RichSlot<E>;
|
|
69
|
+
}>;
|
|
70
|
+
readonly yLabel: Schema.Trimmed;
|
|
71
|
+
}>>;
|
|
72
|
+
PorkBarrelElectabilityChart: import("#contracts/visual/entry").VisualEntry<Schema.Struct<{
|
|
73
|
+
readonly description: RichSlot<E>;
|
|
74
|
+
readonly title: RichSlot<E>;
|
|
75
|
+
readonly footnote: RichSlot<E>;
|
|
76
|
+
readonly labels: Schema.Struct<{
|
|
77
|
+
aniesMuhaimin: RichSlot<E>;
|
|
78
|
+
ganjarMahfud: RichSlot<E>;
|
|
79
|
+
prabowoGibran: RichSlot<E>;
|
|
80
|
+
}>;
|
|
81
|
+
readonly yLabel: Schema.Trimmed;
|
|
82
|
+
}>>;
|
|
83
|
+
PorkBarrelFundChart: import("#contracts/visual/entry").VisualEntry<Schema.Struct<{
|
|
84
|
+
readonly description: RichSlot<E>;
|
|
85
|
+
readonly title: RichSlot<E>;
|
|
86
|
+
readonly footnote: RichSlot<E>;
|
|
87
|
+
readonly labels: Schema.Struct<{
|
|
88
|
+
fund: RichSlot<E>;
|
|
89
|
+
}>;
|
|
90
|
+
readonly yLabel: Schema.Trimmed;
|
|
91
|
+
}>>;
|
|
92
|
+
};
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import { Schema } from "effect";
|
|
2
|
+
import { cardFields, TextSchema } from "#contracts/visual/card";
|
|
3
|
+
import { figure } from "#contracts/visual/entry";
|
|
4
|
+
/** The card, the source footnote, and the words of a sourced politics chart. */
|
|
5
|
+
function sourcedChart(rich, labels) {
|
|
6
|
+
return Schema.Struct({
|
|
7
|
+
...cardFields(rich),
|
|
8
|
+
footnote: rich,
|
|
9
|
+
labels: Schema.Struct(labels),
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
/** Props of a sourced chart whose value axis has a plain label. */
|
|
13
|
+
function axisChart(rich, labels) {
|
|
14
|
+
return Schema.Struct({
|
|
15
|
+
...sourcedChart(rich, labels).fields,
|
|
16
|
+
yLabel: TextSchema,
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
/** Props of `NepotismStage`: the three stages of a good democratic process. */
|
|
20
|
+
function nepotismStage(rich) {
|
|
21
|
+
return figure(Schema.Struct({
|
|
22
|
+
description: Schema.optionalKey(rich),
|
|
23
|
+
labels: Schema.Struct({
|
|
24
|
+
delivery: rich,
|
|
25
|
+
election: rich,
|
|
26
|
+
selection: rich,
|
|
27
|
+
}),
|
|
28
|
+
title: rich,
|
|
29
|
+
}));
|
|
30
|
+
}
|
|
31
|
+
/** Props of `NepotismStateTable`: governance indices of several countries. */
|
|
32
|
+
function nepotismStateTable(rich) {
|
|
33
|
+
return figure(Schema.Struct({
|
|
34
|
+
caption: rich,
|
|
35
|
+
labels: Schema.Struct({
|
|
36
|
+
corruptionIndex: rich,
|
|
37
|
+
country: rich,
|
|
38
|
+
good: rich,
|
|
39
|
+
goodGovernanceIndex: rich,
|
|
40
|
+
governanceQualityCategory: rich,
|
|
41
|
+
judicialEfficiencyIndex: rich,
|
|
42
|
+
low: rich,
|
|
43
|
+
medium: rich,
|
|
44
|
+
}),
|
|
45
|
+
}));
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* The politics charts and tables. Each draws sourced data that the component
|
|
49
|
+
* holds, and its labels name the series, so no prop holds answer state.
|
|
50
|
+
*/
|
|
51
|
+
export function politicsVisuals(rich) {
|
|
52
|
+
return {
|
|
53
|
+
KimPlusElectabilityChart: figure(sourcedChart(rich, { electability: rich, notAnswering: TextSchema })),
|
|
54
|
+
MerahPutihCabinetChart: figure(sourcedChart(rich, { cabinet: rich })),
|
|
55
|
+
MerahPutihCompositionChart: figure(sourcedChart(rich, {
|
|
56
|
+
female: rich,
|
|
57
|
+
gender: TextSchema,
|
|
58
|
+
incumbent: rich,
|
|
59
|
+
male: rich,
|
|
60
|
+
minister: TextSchema,
|
|
61
|
+
new: rich,
|
|
62
|
+
nonPoliticians: rich,
|
|
63
|
+
politicalStatus: TextSchema,
|
|
64
|
+
politicians: rich,
|
|
65
|
+
})),
|
|
66
|
+
NepotismStage: nepotismStage(rich),
|
|
67
|
+
NepotismStateTable: nepotismStateTable(rich),
|
|
68
|
+
PorkBarrelBudgetChart: figure(axisChart(rich, { budget: rich })),
|
|
69
|
+
PorkBarrelElectabilityChart: figure(axisChart(rich, {
|
|
70
|
+
aniesMuhaimin: rich,
|
|
71
|
+
ganjarMahfud: rich,
|
|
72
|
+
prabowoGibran: rich,
|
|
73
|
+
})),
|
|
74
|
+
PorkBarrelFundChart: figure(axisChart(rich, { fund: rich })),
|
|
75
|
+
};
|
|
76
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nakafa/aksara-contracts",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "7.0.0",
|
|
4
4
|
"description": "Schemas and verification contracts for Nakafa content releases.",
|
|
5
5
|
"homepage": "https://github.com/nakafaai/aksara#readme",
|
|
6
6
|
"license": "SEE LICENSE IN LICENSE",
|
|
@@ -52,10 +52,6 @@
|
|
|
52
52
|
"types": "./dist/assessment/catalog.d.ts",
|
|
53
53
|
"import": "./dist/assessment/catalog.js"
|
|
54
54
|
},
|
|
55
|
-
"./assessment/chart": {
|
|
56
|
-
"types": "./dist/assessment/chart.d.ts",
|
|
57
|
-
"import": "./dist/assessment/chart.js"
|
|
58
|
-
},
|
|
59
55
|
"./assessment/choice": {
|
|
60
56
|
"types": "./dist/assessment/choice.d.ts",
|
|
61
57
|
"import": "./dist/assessment/choice.js"
|
|
@@ -559,6 +555,18 @@
|
|
|
559
555
|
"./tree": {
|
|
560
556
|
"types": "./dist/tree.d.ts",
|
|
561
557
|
"import": "./dist/tree.js"
|
|
558
|
+
},
|
|
559
|
+
"./visual/card": {
|
|
560
|
+
"types": "./dist/visual/card.d.ts",
|
|
561
|
+
"import": "./dist/visual/card.js"
|
|
562
|
+
},
|
|
563
|
+
"./visual/catalog": {
|
|
564
|
+
"types": "./dist/visual/catalog.d.ts",
|
|
565
|
+
"import": "./dist/visual/catalog.js"
|
|
566
|
+
},
|
|
567
|
+
"./visual/entry": {
|
|
568
|
+
"types": "./dist/visual/entry.d.ts",
|
|
569
|
+
"import": "./dist/visual/entry.js"
|
|
562
570
|
}
|
|
563
571
|
},
|
|
564
572
|
"imports": {
|
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
import { Schema } from "effect";
|
|
2
|
-
/**
|
|
3
|
-
* Props of `Chart`: categories along one axis and one or more series of
|
|
4
|
-
* values drawn as bars or lines over them, the data of a bar chart, a line
|
|
5
|
-
* chart, a histogram, or both marks at once. The data is the figure, so a
|
|
6
|
-
* learner reads the same values that the figure draws. Every series has a
|
|
7
|
-
* name, because no meaning may ride on color alone.
|
|
8
|
-
*/
|
|
9
|
-
export declare const ChartPropsSchema: Schema.Struct<{
|
|
10
|
-
/**
|
|
11
|
-
* How the bars of a chart that has bars stand: `apart` leaves a gap between
|
|
12
|
-
* neighboring categories, as a bar chart does, and `touching` closes it, as a
|
|
13
|
-
* histogram of classes does. A chart of lines alone has no bars to place.
|
|
14
|
-
*/
|
|
15
|
-
readonly bars: Schema.optionalKey<Schema.Literals<readonly ["apart", "touching"]>>;
|
|
16
|
-
readonly categories: Schema.NonEmptyArray<Schema.Trimmed>;
|
|
17
|
-
readonly description: Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
18
|
-
readonly marks: Schema.optionalKey<Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
19
|
-
readonly type: Schema.Literals<readonly ["bold", "italic", "underline", "code", "subscript", "superscript"]>;
|
|
20
|
-
}>, Schema.Struct<{
|
|
21
|
-
readonly attrs: Schema.Struct<{
|
|
22
|
-
readonly href: Schema.String;
|
|
23
|
-
}>;
|
|
24
|
-
readonly type: Schema.Literal<"link">;
|
|
25
|
-
}>]>>>;
|
|
26
|
-
readonly text: Schema.String;
|
|
27
|
-
readonly type: Schema.Literal<"text">;
|
|
28
|
-
}>, Schema.Struct<{
|
|
29
|
-
readonly attrs: Schema.Struct<{
|
|
30
|
-
readonly latex: Schema.Trimmed;
|
|
31
|
-
}>;
|
|
32
|
-
readonly type: Schema.Literal<"mathInline">;
|
|
33
|
-
}>]>>;
|
|
34
|
-
readonly series: Schema.NonEmptyArray<Schema.Struct<{
|
|
35
|
-
readonly label: Schema.Trimmed;
|
|
36
|
-
readonly mark: Schema.Literals<readonly ["bar", "line"]>;
|
|
37
|
-
readonly values: Schema.NonEmptyArray<Schema.NullOr<Schema.Finite>>;
|
|
38
|
-
}>>;
|
|
39
|
-
readonly title: Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
40
|
-
readonly marks: Schema.optionalKey<Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
41
|
-
readonly type: Schema.Literals<readonly ["bold", "italic", "underline", "code", "subscript", "superscript"]>;
|
|
42
|
-
}>, Schema.Struct<{
|
|
43
|
-
readonly attrs: Schema.Struct<{
|
|
44
|
-
readonly href: Schema.String;
|
|
45
|
-
}>;
|
|
46
|
-
readonly type: Schema.Literal<"link">;
|
|
47
|
-
}>]>>>;
|
|
48
|
-
readonly text: Schema.String;
|
|
49
|
-
readonly type: Schema.Literal<"text">;
|
|
50
|
-
}>, Schema.Struct<{
|
|
51
|
-
readonly attrs: Schema.Struct<{
|
|
52
|
-
readonly latex: Schema.Trimmed;
|
|
53
|
-
}>;
|
|
54
|
-
readonly type: Schema.Literal<"mathInline">;
|
|
55
|
-
}>]>>;
|
|
56
|
-
readonly valueLabel: Schema.optionalKey<Schema.Trimmed>;
|
|
57
|
-
readonly valueRange: Schema.optionalKey<Schema.Struct<{
|
|
58
|
-
readonly max: Schema.Finite;
|
|
59
|
-
readonly min: Schema.Finite;
|
|
60
|
-
}>>;
|
|
61
|
-
}>;
|
|
62
|
-
export type ChartProps = typeof ChartPropsSchema.Type;
|