@doenet/v06-to-v07 0.7.24-dev.477 → 0.7.24-dev.480
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/{index-B6XSSTr-.js → index-CoQ1l7jN.js} +141 -43
- package/{index-B6XSSTr-.js.map → index-CoQ1l7jN.js.map} +1 -1
- package/index.js +1 -1
- package/package.json +1 -1
- package/{sha256-DT5xJ2Hv-DF9EMVpM-Co0rpFKO.js → sha256-DT5xJ2Hv-COfUNpbs-D3zfFexD.js} +2 -2
- package/{sha256-DT5xJ2Hv-DF9EMVpM-Co0rpFKO.js.map → sha256-DT5xJ2Hv-COfUNpbs-D3zfFexD.js.map} +1 -1
|
@@ -11211,7 +11211,13 @@ const DEPRECATION_REGISTRY = {
|
|
|
11211
11211
|
"isLatex",
|
|
11212
11212
|
"anchor",
|
|
11213
11213
|
"positionFromAnchor"
|
|
11214
|
-
])
|
|
11214
|
+
]),
|
|
11215
|
+
// `align` was the only mode an ODE system could ever be rendered in:
|
|
11216
|
+
// its LaTeX carries `&` alignment markers and its own `\tag`/`\notag`
|
|
11217
|
+
// (equation numbering is controlled by `number`), none of which are
|
|
11218
|
+
// legal in the delimiters the other modes of the math renderer supply.
|
|
11219
|
+
// The mode is now fixed by the component, so the attribute is dropped.
|
|
11220
|
+
odeSystem: ignoredAttributes("odeSystem", ["renderMode"])
|
|
11215
11221
|
},
|
|
11216
11222
|
attributeValueRenames: {
|
|
11217
11223
|
// The label sits beside the input in DOM order, which mirrors with the
|
|
@@ -45851,7 +45857,7 @@ async function cidFromArrayBuffer(data) {
|
|
|
45851
45857
|
await crypto.subtle.digest("SHA-256", new Uint8Array());
|
|
45852
45858
|
digest = (data2) => crypto.subtle.digest("SHA-256", data2);
|
|
45853
45859
|
} catch (e22) {
|
|
45854
|
-
const sha256 = (await import("./sha256-DT5xJ2Hv-
|
|
45860
|
+
const sha256 = (await import("./sha256-DT5xJ2Hv-COfUNpbs-D3zfFexD.js").then((n2) => n2.s)).default;
|
|
45855
45861
|
digest = (data2) => sha256(data2, {
|
|
45856
45862
|
asBytes: true
|
|
45857
45863
|
});
|
|
@@ -54553,9 +54559,9 @@ function preprocessAttributesObject(attributesObject) {
|
|
|
54553
54559
|
}
|
|
54554
54560
|
if (attrSpec.toLowerCase === true) {
|
|
54555
54561
|
if (attrSpec.defaultValue !== void 0 && attrSpec.defaultValue !== null) {
|
|
54556
|
-
attrSpec.defaultValue =
|
|
54557
|
-
|
|
54558
|
-
).toLowerCase();
|
|
54562
|
+
attrSpec.defaultValue = Array.isArray(attrSpec.defaultValue) ? attrSpec.defaultValue.map(
|
|
54563
|
+
(entry) => typeof entry === "string" ? entry.toLowerCase() : entry
|
|
54564
|
+
) : String(attrSpec.defaultValue).toLowerCase();
|
|
54559
54565
|
}
|
|
54560
54566
|
if (Array.isArray(attrSpec.validValues)) {
|
|
54561
54567
|
attrSpec.validValues = attrSpec.validValues.map((entry) => ({
|
|
@@ -78496,10 +78502,28 @@ class MathComponent extends InlineComponent {
|
|
|
78496
78502
|
Object.assign(attributes, returnNumberDisplayAttributes());
|
|
78497
78503
|
attributes.displayDigits.highlighted = true;
|
|
78498
78504
|
attributes.renderMode = {
|
|
78499
|
-
description:
|
|
78505
|
+
description: "How the math is rendered.",
|
|
78500
78506
|
createComponentOfType: "text",
|
|
78501
78507
|
createStateVariable: "renderMode",
|
|
78502
78508
|
defaultValue: "inline",
|
|
78509
|
+
toLowerCase: true,
|
|
78510
|
+
// The math renderer understands two further modes, neither of
|
|
78511
|
+
// which `<math>` can reach. `numbered` needs an `equationTag` state
|
|
78512
|
+
// variable to fill its `\tag{}`, and only the equation components
|
|
78513
|
+
// (`<me>`, `<men>`, `<odeSystem>`) define one. `align` needs `&`
|
|
78514
|
+
// alignment markers in the LaTeX, which the math-expressions
|
|
78515
|
+
// expression underlying `<math>` cannot carry — that mode is
|
|
78516
|
+
// reached through components like `<md>` instead.
|
|
78517
|
+
validValues: [
|
|
78518
|
+
{
|
|
78519
|
+
value: "inline",
|
|
78520
|
+
description: "Render inline with the surrounding text."
|
|
78521
|
+
},
|
|
78522
|
+
{
|
|
78523
|
+
value: "display",
|
|
78524
|
+
description: "Render as a centered equation on its own line."
|
|
78525
|
+
}
|
|
78526
|
+
],
|
|
78503
78527
|
public: true,
|
|
78504
78528
|
forRenderer: true
|
|
78505
78529
|
};
|
|
@@ -98685,6 +98709,24 @@ const Sectioning = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.definePr
|
|
|
98685
98709
|
Theorem,
|
|
98686
98710
|
externalContent
|
|
98687
98711
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
98712
|
+
const NUMBERED_MARKER_VALUES = [
|
|
98713
|
+
{ value: "1", description: "Arabic numerals: 1, 2, 3, …" },
|
|
98714
|
+
{ value: "a", description: "Lowercase letters: a, b, c, …" },
|
|
98715
|
+
{ value: "A", description: "Uppercase letters: A, B, C, …" },
|
|
98716
|
+
{
|
|
98717
|
+
value: "i",
|
|
98718
|
+
description: "Lowercase roman numerals: i, ii, iii, …"
|
|
98719
|
+
},
|
|
98720
|
+
{
|
|
98721
|
+
value: "I",
|
|
98722
|
+
description: "Uppercase roman numerals: I, II, III, …"
|
|
98723
|
+
}
|
|
98724
|
+
];
|
|
98725
|
+
const UNNUMBERED_MARKER_VALUES = [
|
|
98726
|
+
{ value: "disc", description: "A filled circle." },
|
|
98727
|
+
{ value: "circle", description: "A hollow circle." },
|
|
98728
|
+
{ value: "square", description: "A filled square." }
|
|
98729
|
+
];
|
|
98688
98730
|
class Ol extends BlockComponent {
|
|
98689
98731
|
constructor(args) {
|
|
98690
98732
|
super(args);
|
|
@@ -98720,7 +98762,8 @@ class Ol extends BlockComponent {
|
|
|
98720
98762
|
createStateVariable: "marker",
|
|
98721
98763
|
defaultValue: null,
|
|
98722
98764
|
forRenderer: true,
|
|
98723
|
-
|
|
98765
|
+
suggestedValues: NUMBERED_MARKER_VALUES,
|
|
98766
|
+
description: "Marker style for the list items: `1`, `a`, `A`, `i`, or `I`. The value is matched on its first character, so a decorated form such as `1.` or `a)` selects the same style. Defaults to a style chosen by the list's nesting level."
|
|
98724
98767
|
};
|
|
98725
98768
|
let scoredSectionAttributes = returnScoredSectionAttributes();
|
|
98726
98769
|
Object.assign(attributes, scoredSectionAttributes);
|
|
@@ -98817,6 +98860,17 @@ class Ul extends Ol {
|
|
|
98817
98860
|
summary: "An unordered list"
|
|
98818
98861
|
};
|
|
98819
98862
|
static rendererType = "list";
|
|
98863
|
+
static createAttributesObject() {
|
|
98864
|
+
let attributes = super.createAttributesObject();
|
|
98865
|
+
const { suggestedValues: _numberedMarkers, ...inheritedMarker } = attributes.marker;
|
|
98866
|
+
attributes.marker = {
|
|
98867
|
+
...inheritedMarker,
|
|
98868
|
+
toLowerCase: true,
|
|
98869
|
+
validValues: UNNUMBERED_MARKER_VALUES,
|
|
98870
|
+
description: "Marker style for the list items: `disc`, `circle`, or `square`. Defaults to a style chosen by the list's nesting level."
|
|
98871
|
+
};
|
|
98872
|
+
return attributes;
|
|
98873
|
+
}
|
|
98820
98874
|
static returnStateVariableDefinitions() {
|
|
98821
98875
|
let stateVariableDefinitions = super.returnStateVariableDefinitions();
|
|
98822
98876
|
stateVariableDefinitions.numbered = {
|
|
@@ -98996,14 +99050,6 @@ class ODESystem extends InlineComponent {
|
|
|
98996
99050
|
description: "The value of the independent variable at which the initial conditions are specified."
|
|
98997
99051
|
};
|
|
98998
99052
|
Object.assign(attributes, returnNumberDisplayAttributes());
|
|
98999
|
-
attributes.renderMode = {
|
|
99000
|
-
createComponentOfType: "text",
|
|
99001
|
-
createStateVariable: "renderMode",
|
|
99002
|
-
defaultValue: "align",
|
|
99003
|
-
public: true,
|
|
99004
|
-
forRenderer: true,
|
|
99005
|
-
description: 'How to format the rendered system of equations (e.g. "align").'
|
|
99006
|
-
};
|
|
99007
99053
|
attributes.chunkSize = {
|
|
99008
99054
|
createComponentOfType: "number",
|
|
99009
99055
|
createStateVariable: "chunkSize",
|
|
@@ -99301,6 +99347,11 @@ class ODESystem extends InlineComponent {
|
|
|
99301
99347
|
targetVariableName: "initialCondition1",
|
|
99302
99348
|
description: "The initial value of the first dependent variable at the initial independent-variable value."
|
|
99303
99349
|
};
|
|
99350
|
+
stateVariableDefinitions.renderMode = {
|
|
99351
|
+
forRenderer: true,
|
|
99352
|
+
returnDependencies: () => ({}),
|
|
99353
|
+
definition: () => ({ setValue: { renderMode: "align" } })
|
|
99354
|
+
};
|
|
99304
99355
|
stateVariableDefinitions.equationTag = {
|
|
99305
99356
|
description: "The displayed equation number tag (when equation numbering is enabled).",
|
|
99306
99357
|
public: true,
|
|
@@ -155591,6 +155642,29 @@ let Graph$1 = class Graph extends BlockComponent {
|
|
|
155591
155642
|
attributes.grid = {
|
|
155592
155643
|
createComponentOfType: "text",
|
|
155593
155644
|
valueForTrue: "medium",
|
|
155645
|
+
suggestedValues: [
|
|
155646
|
+
{ value: "none", description: "Draw no grid lines." },
|
|
155647
|
+
{
|
|
155648
|
+
value: "medium",
|
|
155649
|
+
description: "Draw grid lines at the major tick marks. Used when `grid` is given with no value."
|
|
155650
|
+
},
|
|
155651
|
+
{
|
|
155652
|
+
value: "dense",
|
|
155653
|
+
description: "Draw grid lines at the major and minor tick marks."
|
|
155654
|
+
},
|
|
155655
|
+
// Two examples of the numeric form, which the named spacings
|
|
155656
|
+
// would otherwise hide: an author scanning a list of three
|
|
155657
|
+
// words has no reason to guess that spacings can be given
|
|
155658
|
+
// explicitly.
|
|
155659
|
+
{
|
|
155660
|
+
value: "1 1",
|
|
155661
|
+
description: "Draw grid lines every 1 unit in x and every 1 unit in y. Any two positive numbers can be given this way."
|
|
155662
|
+
},
|
|
155663
|
+
{
|
|
155664
|
+
value: "2 2",
|
|
155665
|
+
description: "Draw grid lines every 2 units in x and every 2 units in y."
|
|
155666
|
+
}
|
|
155667
|
+
],
|
|
155594
155668
|
description: 'Grid line spacing on the graph: none, medium, dense, or two positive numbers giving the x and y spacing, such as grid="1 0.5".'
|
|
155595
155669
|
};
|
|
155596
155670
|
Object.assign(attributes, returnNumberDisplayAttributes());
|
|
@@ -225554,6 +225628,36 @@ class DataFrame extends BaseComponent {
|
|
|
225554
225628
|
}
|
|
225555
225629
|
}
|
|
225556
225630
|
const { mean, std, variance, median, quantileSeq } = Context.math;
|
|
225631
|
+
const STATISTIC_VALUES = [
|
|
225632
|
+
{ value: "mean", description: "The arithmetic mean." },
|
|
225633
|
+
{ value: "stdev", description: "The standard deviation." },
|
|
225634
|
+
{ value: "variance", description: "The variance." },
|
|
225635
|
+
{ value: "stderr", description: "The standard error." },
|
|
225636
|
+
{
|
|
225637
|
+
value: "count",
|
|
225638
|
+
description: "The number of non-missing values."
|
|
225639
|
+
},
|
|
225640
|
+
{ value: "minimum", description: "The smallest value." },
|
|
225641
|
+
{ value: "quartile1", description: "The first quartile." },
|
|
225642
|
+
{ value: "median", description: "The median." },
|
|
225643
|
+
{ value: "quartile3", description: "The third quartile." },
|
|
225644
|
+
{ value: "maximum", description: "The largest value." },
|
|
225645
|
+
{
|
|
225646
|
+
value: "range",
|
|
225647
|
+
description: "The maximum minus the minimum."
|
|
225648
|
+
},
|
|
225649
|
+
{ value: "sum", description: "The sum of the values." }
|
|
225650
|
+
];
|
|
225651
|
+
const DEFAULT_STATISTICS = [
|
|
225652
|
+
"mean",
|
|
225653
|
+
"stdev",
|
|
225654
|
+
"count",
|
|
225655
|
+
"minimum",
|
|
225656
|
+
"quartile1",
|
|
225657
|
+
"median",
|
|
225658
|
+
"quartile3",
|
|
225659
|
+
"maximum"
|
|
225660
|
+
];
|
|
225557
225661
|
class SummaryStatistics extends BlockComponent {
|
|
225558
225662
|
constructor(args) {
|
|
225559
225663
|
super(args);
|
|
@@ -225584,6 +225688,24 @@ class SummaryStatistics extends BlockComponent {
|
|
|
225584
225688
|
createComponentOfType: "textList",
|
|
225585
225689
|
createStateVariable: "statisticsToDisplayPrelim",
|
|
225586
225690
|
defaultValue: ["default"],
|
|
225691
|
+
toLowerCase: true,
|
|
225692
|
+
// `default` and `all` are selections over the statistics rather
|
|
225693
|
+
// than statistics of their own, so they are listed here rather
|
|
225694
|
+
// than in `STATISTIC_VALUES`.
|
|
225695
|
+
//
|
|
225696
|
+
// The component sets `excludeFromSchema`, so these values do not
|
|
225697
|
+
// yet reach autocomplete or the reference docs; what they buy
|
|
225698
|
+
// today is the runtime validation — an unrecognized statistic is
|
|
225699
|
+
// dropped with an info diagnostic instead of being ignored in
|
|
225700
|
+
// silence.
|
|
225701
|
+
validValues: [
|
|
225702
|
+
{
|
|
225703
|
+
value: "default",
|
|
225704
|
+
description: `The default selection: ${DEFAULT_STATISTICS.join(", ")}.`
|
|
225705
|
+
},
|
|
225706
|
+
{ value: "all", description: "Every statistic listed here." },
|
|
225707
|
+
...STATISTIC_VALUES
|
|
225708
|
+
],
|
|
225587
225709
|
description: 'Which summary statistics to display (or "default" / "all").'
|
|
225588
225710
|
};
|
|
225589
225711
|
attributes.byCategoryColumn = {
|
|
@@ -225615,35 +225737,11 @@ class SummaryStatistics extends BlockComponent {
|
|
|
225615
225737
|
}
|
|
225616
225738
|
}),
|
|
225617
225739
|
definition: function({ dependencyValues }) {
|
|
225618
|
-
|
|
225619
|
-
"mean",
|
|
225620
|
-
"stdev",
|
|
225621
|
-
"variance",
|
|
225622
|
-
"stderr",
|
|
225623
|
-
"count",
|
|
225624
|
-
"minimum",
|
|
225625
|
-
"quartile1",
|
|
225626
|
-
"median",
|
|
225627
|
-
"quartile3",
|
|
225628
|
-
"maximum",
|
|
225629
|
-
"range",
|
|
225630
|
-
"sum"
|
|
225631
|
-
];
|
|
225740
|
+
const options = STATISTIC_VALUES.map((entry) => entry.value);
|
|
225632
225741
|
let statisticsToDisplay = [];
|
|
225633
|
-
let desiredStats = dependencyValues.statisticsToDisplayPrelim
|
|
225634
|
-
(x2) => x2.toLowerCase()
|
|
225635
|
-
);
|
|
225742
|
+
let desiredStats = dependencyValues.statisticsToDisplayPrelim;
|
|
225636
225743
|
if (desiredStats.includes("default")) {
|
|
225637
|
-
statisticsToDisplay = [
|
|
225638
|
-
"mean",
|
|
225639
|
-
"stdev",
|
|
225640
|
-
"count",
|
|
225641
|
-
"minimum",
|
|
225642
|
-
"quartile1",
|
|
225643
|
-
"median",
|
|
225644
|
-
"quartile3",
|
|
225645
|
-
"maximum"
|
|
225646
|
-
];
|
|
225744
|
+
statisticsToDisplay = [...DEFAULT_STATISTICS];
|
|
225647
225745
|
} else if (desiredStats.includes("all")) {
|
|
225648
225746
|
statisticsToDisplay = [...options];
|
|
225649
225747
|
} else {
|
|
@@ -237192,4 +237290,4 @@ export {
|
|
|
237192
237290
|
getDefaultExportFromCjs$1 as g,
|
|
237193
237291
|
updateSyntaxFromV06toV07 as u
|
|
237194
237292
|
};
|
|
237195
|
-
//# sourceMappingURL=index-
|
|
237293
|
+
//# sourceMappingURL=index-CoQ1l7jN.js.map
|