mystmd 1.3.19__py3-none-any.whl → 1.3.20__py3-none-any.whl
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.
- {mystmd-1.3.19.dist-info → mystmd-1.3.20.dist-info}/METADATA +4 -3
- mystmd-1.3.20.dist-info/RECORD +9 -0
- {mystmd-1.3.19.dist-info → mystmd-1.3.20.dist-info}/WHEEL +1 -1
- mystmd_py/myst.cjs +495 -257
- mystmd-1.3.19.dist-info/RECORD +0 -9
- {mystmd-1.3.19.dist-info → mystmd-1.3.20.dist-info}/entry_points.txt +0 -0
- {mystmd-1.3.19.dist-info → mystmd-1.3.20.dist-info}/licenses/LICENSE +0 -0
mystmd_py/myst.cjs
CHANGED
@@ -1344,13 +1344,13 @@ var require_object_create = __commonJS({
|
|
1344
1344
|
return temp;
|
1345
1345
|
};
|
1346
1346
|
var NullProtoObjectViaIFrame = function() {
|
1347
|
-
var
|
1347
|
+
var iframe4 = documentCreateElement("iframe");
|
1348
1348
|
var JS = "java" + SCRIPT + ":";
|
1349
1349
|
var iframeDocument;
|
1350
|
-
|
1351
|
-
html7.appendChild(
|
1352
|
-
|
1353
|
-
iframeDocument =
|
1350
|
+
iframe4.style.display = "none";
|
1351
|
+
html7.appendChild(iframe4);
|
1352
|
+
iframe4.src = String(JS);
|
1353
|
+
iframeDocument = iframe4.contentWindow.document;
|
1354
1354
|
iframeDocument.open();
|
1355
1355
|
iframeDocument.write(scriptTag("document.F=Object"));
|
1356
1356
|
iframeDocument.close();
|
@@ -9403,7 +9403,7 @@ var require_es_regexp_constructor = __commonJS({
|
|
9403
9403
|
var length = string2.length;
|
9404
9404
|
var index5 = 0;
|
9405
9405
|
var result = "";
|
9406
|
-
var
|
9406
|
+
var brackets2 = false;
|
9407
9407
|
var chr;
|
9408
9408
|
for (; index5 <= length; index5++) {
|
9409
9409
|
chr = charAt(string2, index5);
|
@@ -9411,13 +9411,13 @@ var require_es_regexp_constructor = __commonJS({
|
|
9411
9411
|
result += chr + charAt(string2, ++index5);
|
9412
9412
|
continue;
|
9413
9413
|
}
|
9414
|
-
if (!
|
9414
|
+
if (!brackets2 && chr === ".") {
|
9415
9415
|
result += "[\\s\\S]";
|
9416
9416
|
} else {
|
9417
9417
|
if (chr === "[") {
|
9418
|
-
|
9418
|
+
brackets2 = true;
|
9419
9419
|
} else if (chr === "]") {
|
9420
|
-
|
9420
|
+
brackets2 = false;
|
9421
9421
|
}
|
9422
9422
|
result += chr;
|
9423
9423
|
}
|
@@ -9430,7 +9430,7 @@ var require_es_regexp_constructor = __commonJS({
|
|
9430
9430
|
var result = "";
|
9431
9431
|
var named = [];
|
9432
9432
|
var names = {};
|
9433
|
-
var
|
9433
|
+
var brackets2 = false;
|
9434
9434
|
var ncg = false;
|
9435
9435
|
var groupid = 0;
|
9436
9436
|
var groupname = "";
|
@@ -9440,11 +9440,11 @@ var require_es_regexp_constructor = __commonJS({
|
|
9440
9440
|
if (chr === "\\") {
|
9441
9441
|
chr = chr + charAt(string2, ++index5);
|
9442
9442
|
} else if (chr === "]") {
|
9443
|
-
|
9444
|
-
} else if (!
|
9443
|
+
brackets2 = false;
|
9444
|
+
} else if (!brackets2)
|
9445
9445
|
switch (true) {
|
9446
9446
|
case chr === "[":
|
9447
|
-
|
9447
|
+
brackets2 = true;
|
9448
9448
|
break;
|
9449
9449
|
case chr === "(":
|
9450
9450
|
if (exec3(IS_NCG, stringSlice(string2, index5 + 1))) {
|
@@ -45547,13 +45547,13 @@ var require_css_syntax_error = __commonJS({
|
|
45547
45547
|
let css = this.source;
|
45548
45548
|
if (color2 == null)
|
45549
45549
|
color2 = pico.isColorSupported;
|
45550
|
-
let
|
45550
|
+
let aside2 = (text7) => text7;
|
45551
45551
|
let mark2 = (text7) => text7;
|
45552
45552
|
let highlight = (text7) => text7;
|
45553
45553
|
if (color2) {
|
45554
45554
|
let { bold, gray, red } = pico.createColors(true);
|
45555
45555
|
mark2 = (text7) => bold(red(text7));
|
45556
|
-
|
45556
|
+
aside2 = (text7) => gray(text7);
|
45557
45557
|
if (terminalHighlight) {
|
45558
45558
|
highlight = (text7) => terminalHighlight(text7);
|
45559
45559
|
}
|
@@ -45574,13 +45574,13 @@ var require_css_syntax_error = __commonJS({
|
|
45574
45574
|
this.endColumn + padding2
|
45575
45575
|
);
|
45576
45576
|
let subLine = line2.slice(subLineStart, subLineEnd);
|
45577
|
-
let spacing3 =
|
45578
|
-
return mark2(">") +
|
45577
|
+
let spacing3 = aside2(gutter.replace(/\d/g, " ")) + line2.slice(0, Math.min(this.column - 1, padding2 - 1)).replace(/[^\t]/g, " ");
|
45578
|
+
return mark2(">") + aside2(gutter) + highlight(subLine) + "\n " + spacing3 + mark2("^");
|
45579
45579
|
}
|
45580
|
-
let spacing2 =
|
45581
|
-
return mark2(">") +
|
45580
|
+
let spacing2 = aside2(gutter.replace(/\d/g, " ")) + line2.slice(0, this.column - 1).replace(/[^\t]/g, " ");
|
45581
|
+
return mark2(">") + aside2(gutter) + highlight(line2) + "\n " + spacing2 + mark2("^");
|
45582
45582
|
}
|
45583
|
-
return " " +
|
45583
|
+
return " " + aside2(gutter) + highlight(line2);
|
45584
45584
|
}).join("\n");
|
45585
45585
|
}
|
45586
45586
|
toString() {
|
@@ -49636,18 +49636,18 @@ var require_parser3 = __commonJS({
|
|
49636
49636
|
let last = false;
|
49637
49637
|
let open2 = false;
|
49638
49638
|
let params = [];
|
49639
|
-
let
|
49639
|
+
let brackets2 = [];
|
49640
49640
|
while (!this.tokenizer.endOfFile()) {
|
49641
49641
|
token = this.tokenizer.nextToken();
|
49642
49642
|
type2 = token[0];
|
49643
49643
|
if (type2 === "(" || type2 === "[") {
|
49644
|
-
|
49645
|
-
} else if (type2 === "{" &&
|
49646
|
-
|
49647
|
-
} else if (type2 ===
|
49648
|
-
|
49644
|
+
brackets2.push(type2 === "(" ? ")" : "]");
|
49645
|
+
} else if (type2 === "{" && brackets2.length > 0) {
|
49646
|
+
brackets2.push("}");
|
49647
|
+
} else if (type2 === brackets2[brackets2.length - 1]) {
|
49648
|
+
brackets2.pop();
|
49649
49649
|
}
|
49650
|
-
if (
|
49650
|
+
if (brackets2.length === 0) {
|
49651
49651
|
if (type2 === ";") {
|
49652
49652
|
node3.source.end = this.getPosition(token[2]);
|
49653
49653
|
node3.source.end.offset++;
|
@@ -49721,18 +49721,18 @@ var require_parser3 = __commonJS({
|
|
49721
49721
|
);
|
49722
49722
|
}
|
49723
49723
|
colon(tokens) {
|
49724
|
-
let
|
49724
|
+
let brackets2 = 0;
|
49725
49725
|
let prev, token, type2;
|
49726
49726
|
for (let [i2, element5] of tokens.entries()) {
|
49727
49727
|
token = element5;
|
49728
49728
|
type2 = token[0];
|
49729
49729
|
if (type2 === "(") {
|
49730
|
-
|
49730
|
+
brackets2 += 1;
|
49731
49731
|
}
|
49732
49732
|
if (type2 === ")") {
|
49733
|
-
|
49733
|
+
brackets2 -= 1;
|
49734
49734
|
}
|
49735
|
-
if (
|
49735
|
+
if (brackets2 === 0 && type2 === ":") {
|
49736
49736
|
if (!prev) {
|
49737
49737
|
this.doubleColon(token);
|
49738
49738
|
} else if (prev[0] === "word" && prev[1] === "progid") {
|
@@ -49930,7 +49930,7 @@ var require_parser3 = __commonJS({
|
|
49930
49930
|
let type2 = null;
|
49931
49931
|
let colon = false;
|
49932
49932
|
let bracket = null;
|
49933
|
-
let
|
49933
|
+
let brackets2 = [];
|
49934
49934
|
let customProperty = start[1].startsWith("--");
|
49935
49935
|
let tokens = [];
|
49936
49936
|
let token = start;
|
@@ -49940,12 +49940,12 @@ var require_parser3 = __commonJS({
|
|
49940
49940
|
if (type2 === "(" || type2 === "[") {
|
49941
49941
|
if (!bracket)
|
49942
49942
|
bracket = token;
|
49943
|
-
|
49943
|
+
brackets2.push(type2 === "(" ? ")" : "]");
|
49944
49944
|
} else if (customProperty && colon && type2 === "{") {
|
49945
49945
|
if (!bracket)
|
49946
49946
|
bracket = token;
|
49947
|
-
|
49948
|
-
} else if (
|
49947
|
+
brackets2.push("}");
|
49948
|
+
} else if (brackets2.length === 0) {
|
49949
49949
|
if (type2 === ";") {
|
49950
49950
|
if (colon) {
|
49951
49951
|
this.decl(tokens, customProperty);
|
@@ -49963,16 +49963,16 @@ var require_parser3 = __commonJS({
|
|
49963
49963
|
} else if (type2 === ":") {
|
49964
49964
|
colon = true;
|
49965
49965
|
}
|
49966
|
-
} else if (type2 ===
|
49967
|
-
|
49968
|
-
if (
|
49966
|
+
} else if (type2 === brackets2[brackets2.length - 1]) {
|
49967
|
+
brackets2.pop();
|
49968
|
+
if (brackets2.length === 0)
|
49969
49969
|
bracket = null;
|
49970
49970
|
}
|
49971
49971
|
token = this.tokenizer.nextToken();
|
49972
49972
|
}
|
49973
49973
|
if (this.tokenizer.endOfFile())
|
49974
49974
|
end = true;
|
49975
|
-
if (
|
49975
|
+
if (brackets2.length > 0)
|
49976
49976
|
this.unclosedBracket(bracket);
|
49977
49977
|
if (end && colon) {
|
49978
49978
|
if (!customProperty) {
|
@@ -102293,7 +102293,7 @@ var require_parse5 = __commonJS({
|
|
102293
102293
|
const stack = [ast];
|
102294
102294
|
let block5 = ast;
|
102295
102295
|
let prev = ast;
|
102296
|
-
let
|
102296
|
+
let brackets2 = 0;
|
102297
102297
|
const length = input3.length;
|
102298
102298
|
let index4 = 0;
|
102299
102299
|
let depth = 0;
|
@@ -102329,12 +102329,12 @@ var require_parse5 = __commonJS({
|
|
102329
102329
|
continue;
|
102330
102330
|
}
|
102331
102331
|
if (value === CHAR_LEFT_SQUARE_BRACKET2) {
|
102332
|
-
|
102332
|
+
brackets2++;
|
102333
102333
|
let next;
|
102334
102334
|
while (index4 < length && (next = advance())) {
|
102335
102335
|
value += next;
|
102336
102336
|
if (next === CHAR_LEFT_SQUARE_BRACKET2) {
|
102337
|
-
|
102337
|
+
brackets2++;
|
102338
102338
|
continue;
|
102339
102339
|
}
|
102340
102340
|
if (next === CHAR_BACKSLASH) {
|
@@ -102342,8 +102342,8 @@ var require_parse5 = __commonJS({
|
|
102342
102342
|
continue;
|
102343
102343
|
}
|
102344
102344
|
if (next === CHAR_RIGHT_SQUARE_BRACKET2) {
|
102345
|
-
|
102346
|
-
if (
|
102345
|
+
brackets2--;
|
102346
|
+
if (brackets2 === 0) {
|
102347
102347
|
break;
|
102348
102348
|
}
|
102349
102349
|
}
|
@@ -132021,7 +132021,7 @@ var require_stringify4 = __commonJS({
|
|
132021
132021
|
var formats = require_formats();
|
132022
132022
|
var has3 = Object.prototype.hasOwnProperty;
|
132023
132023
|
var arrayPrefixGenerators = {
|
132024
|
-
brackets: function
|
132024
|
+
brackets: function brackets2(prefix2) {
|
132025
132025
|
return prefix2 + "[]";
|
132026
132026
|
},
|
132027
132027
|
comma: "comma",
|
@@ -132421,9 +132421,9 @@ var require_parse6 = __commonJS({
|
|
132421
132421
|
return;
|
132422
132422
|
}
|
132423
132423
|
var key2 = options.allowDots ? givenKey.replace(/\.([^.[]+)/g, "[$1]") : givenKey;
|
132424
|
-
var
|
132424
|
+
var brackets2 = /(\[[^[\]]*])/;
|
132425
132425
|
var child = /(\[[^[\]]*])/g;
|
132426
|
-
var segment = options.depth > 0 &&
|
132426
|
+
var segment = options.depth > 0 && brackets2.exec(key2);
|
132427
132427
|
var parent2 = segment ? key2.slice(0, segment.index) : key2;
|
132428
132428
|
var keys2 = [];
|
132429
132429
|
if (parent2) {
|
@@ -165994,7 +165994,7 @@ var require_bl = __commonJS({
|
|
165994
165994
|
var require_ora = __commonJS({
|
165995
165995
|
"../../node_modules/ora/index.js"(exports2, module2) {
|
165996
165996
|
"use strict";
|
165997
|
-
var
|
165997
|
+
var readline2 = require("readline");
|
165998
165998
|
var chalk7 = require_source();
|
165999
165999
|
var cliCursor3 = require_cli_cursor();
|
166000
166000
|
var cliSpinners = require_cli_spinners();
|
@@ -166047,7 +166047,7 @@ var require_ora = __commonJS({
|
|
166047
166047
|
if (process.platform === "win32") {
|
166048
166048
|
return;
|
166049
166049
|
}
|
166050
|
-
this.rl =
|
166050
|
+
this.rl = readline2.createInterface({
|
166051
166051
|
input: process.stdin,
|
166052
166052
|
output: this.mutedStream
|
166053
166053
|
});
|
@@ -193891,7 +193891,7 @@ var {
|
|
193891
193891
|
} = import_index.default;
|
193892
193892
|
|
193893
193893
|
// src/version.ts
|
193894
|
-
var version = "1.3.
|
193894
|
+
var version = "1.3.20";
|
193895
193895
|
var version_default = version;
|
193896
193896
|
|
193897
193897
|
// ../myst-cli/dist/build/build.js
|
@@ -196304,6 +196304,9 @@ var licenses = {
|
|
196304
196304
|
"any-OSI": {
|
196305
196305
|
name: "Any OSI License"
|
196306
196306
|
},
|
196307
|
+
"any-OSI-perl-modules": {
|
196308
|
+
name: "Any OSI License - Perl Modules"
|
196309
|
+
},
|
196307
196310
|
"Apache-1.0": {
|
196308
196311
|
name: "Apache License 1.0",
|
196309
196312
|
free: true
|
@@ -196409,6 +196412,9 @@ var licenses = {
|
|
196409
196412
|
"Boehm-GC": {
|
196410
196413
|
name: "Boehm-Demers-Weiser GC License"
|
196411
196414
|
},
|
196415
|
+
"Boehm-GC-without-fee": {
|
196416
|
+
name: "Boehm-Demers-Weiser GC License (without fee)"
|
196417
|
+
},
|
196412
196418
|
Borceux: {
|
196413
196419
|
name: "Borceux license"
|
196414
196420
|
},
|
@@ -196771,6 +196777,14 @@ var licenses = {
|
|
196771
196777
|
name: "Creative Commons Public Domain Dedication and Certification",
|
196772
196778
|
CC: true
|
196773
196779
|
},
|
196780
|
+
"CC-PDM-1.0": {
|
196781
|
+
name: "Creative Commons Public Domain Mark 1.0 Universal",
|
196782
|
+
CC: true
|
196783
|
+
},
|
196784
|
+
"CC-SA-1.0": {
|
196785
|
+
name: "Creative Commons Share Alike 1.0 Generic",
|
196786
|
+
CC: true
|
196787
|
+
},
|
196774
196788
|
"CC0-1.0": {
|
196775
196789
|
name: "Creative Commons Zero v1.0 Universal",
|
196776
196790
|
free: true,
|
@@ -196943,6 +196957,9 @@ var licenses = {
|
|
196943
196957
|
"DocBook-Schema": {
|
196944
196958
|
name: "DocBook Schema License"
|
196945
196959
|
},
|
196960
|
+
"DocBook-Stylesheet": {
|
196961
|
+
name: "DocBook Stylesheet License"
|
196962
|
+
},
|
196946
196963
|
"DocBook-XML": {
|
196947
196964
|
name: "DocBook XML License"
|
196948
196965
|
},
|
@@ -197087,6 +197104,9 @@ var licenses = {
|
|
197087
197104
|
GD: {
|
197088
197105
|
name: "GD License"
|
197089
197106
|
},
|
197107
|
+
"generic-xts": {
|
197108
|
+
name: "Generic XTS License"
|
197109
|
+
},
|
197090
197110
|
"GFDL-1.1-invariants-only": {
|
197091
197111
|
name: "GNU Free Documentation License v1.1 only - invariants"
|
197092
197112
|
},
|
@@ -197333,6 +197353,9 @@ var licenses = {
|
|
197333
197353
|
"Inner-Net-2.0": {
|
197334
197354
|
name: "Inner Net License v2.0"
|
197335
197355
|
},
|
197356
|
+
InnoSetup: {
|
197357
|
+
name: "Inno Setup License"
|
197358
|
+
},
|
197336
197359
|
Intel: {
|
197337
197360
|
name: "Intel Open Source License",
|
197338
197361
|
osi: true,
|
@@ -197547,6 +197570,9 @@ var licenses = {
|
|
197547
197570
|
Minpack: {
|
197548
197571
|
name: "Minpack License"
|
197549
197572
|
},
|
197573
|
+
MIPS: {
|
197574
|
+
name: "MIPS License"
|
197575
|
+
},
|
197550
197576
|
MirOS: {
|
197551
197577
|
name: "The MirOS Licence",
|
197552
197578
|
osi: true
|
@@ -197563,6 +197589,9 @@ var licenses = {
|
|
197563
197589
|
"MIT-advertising": {
|
197564
197590
|
name: "Enlightenment License (e16)"
|
197565
197591
|
},
|
197592
|
+
"MIT-Click": {
|
197593
|
+
name: "MIT Click License"
|
197594
|
+
},
|
197566
197595
|
"MIT-CMU": {
|
197567
197596
|
name: "CMU License"
|
197568
197597
|
},
|
@@ -198064,6 +198093,9 @@ var licenses = {
|
|
198064
198093
|
"Sendmail-8.23": {
|
198065
198094
|
name: "Sendmail License 8.23"
|
198066
198095
|
},
|
198096
|
+
"Sendmail-Open-Source-1.1": {
|
198097
|
+
name: "Sendmail Open Source License v1.1"
|
198098
|
+
},
|
198067
198099
|
"SGI-B-1.0": {
|
198068
198100
|
name: "SGI Free Software License B v1.0"
|
198069
198101
|
},
|
@@ -198106,6 +198138,9 @@ var licenses = {
|
|
198106
198138
|
osi: true,
|
198107
198139
|
free: true
|
198108
198140
|
},
|
198141
|
+
"SMAIL-GPL": {
|
198142
|
+
name: "SMAIL General Public License"
|
198143
|
+
},
|
198109
198144
|
SMLNJ: {
|
198110
198145
|
name: "Standard ML of New Jersey License",
|
198111
198146
|
free: true
|
@@ -198190,6 +198225,9 @@ var licenses = {
|
|
198190
198225
|
"TGPPL-1.0": {
|
198191
198226
|
name: "Transitive Grace Period Public Licence 1.0"
|
198192
198227
|
},
|
198228
|
+
ThirdEye: {
|
198229
|
+
name: "ThirdEye License"
|
198230
|
+
},
|
198193
198231
|
threeparttable: {
|
198194
198232
|
name: "threeparttable License"
|
198195
198233
|
},
|
@@ -198208,6 +198246,9 @@ var licenses = {
|
|
198208
198246
|
"TPL-1.0": {
|
198209
198247
|
name: "THOR Public License 1.0"
|
198210
198248
|
},
|
198249
|
+
TrustedQSL: {
|
198250
|
+
name: "TrustedQSL License"
|
198251
|
+
},
|
198211
198252
|
TTWL: {
|
198212
198253
|
name: "Text-Tabs+Wrap License"
|
198213
198254
|
},
|
@@ -198306,6 +198347,9 @@ var licenses = {
|
|
198306
198347
|
name: "Do What The F*ck You Want To Public License",
|
198307
198348
|
free: true
|
198308
198349
|
},
|
198350
|
+
wwl: {
|
198351
|
+
name: "WWL License"
|
198352
|
+
},
|
198309
198353
|
X11: {
|
198310
198354
|
name: "X11 License",
|
198311
198355
|
free: true
|
@@ -198415,7 +198459,7 @@ function correctLicense(license) {
|
|
198415
198459
|
function createURL(id, cc, osi) {
|
198416
198460
|
var _a6, _b;
|
198417
198461
|
if (cc) {
|
198418
|
-
const match3 = /^([
|
198462
|
+
const match3 = /^([CBYSAND0ZEROPDM-]+)(?:(?:-)([0-9].[0-9]))?(?:(?:-)([A-Z]{2,3}))?$/.exec(id);
|
198419
198463
|
if (!match3) {
|
198420
198464
|
throw new Error("Creative Commons license not found");
|
198421
198465
|
}
|
@@ -198450,6 +198494,9 @@ function createURL(id, cc, osi) {
|
|
198450
198494
|
case "CC-PDDC":
|
198451
198495
|
link4 = "/publicdomain/";
|
198452
198496
|
break;
|
198497
|
+
case "CC-PDM":
|
198498
|
+
link4 = "/publicdomain/mark/1.0/";
|
198499
|
+
break;
|
198453
198500
|
default:
|
198454
198501
|
break;
|
198455
198502
|
}
|
@@ -203271,11 +203318,16 @@ function createHtmlId(identifier) {
|
|
203271
203318
|
}
|
203272
203319
|
function transferTargetAttrs(sourceNode, destNode, vfile2) {
|
203273
203320
|
if (sourceNode.label) {
|
203274
|
-
if (destNode.label && vfile2) {
|
203321
|
+
if (destNode.label && vfile2 && destNode.label !== sourceNode.label) {
|
203275
203322
|
fileWarn(vfile2, `label "${destNode.label}" replaced with "${sourceNode.label}"`, {
|
203276
203323
|
node: destNode
|
203277
203324
|
});
|
203278
203325
|
}
|
203326
|
+
if (destNode.label && vfile2 && destNode.label === sourceNode.label) {
|
203327
|
+
fileWarn(vfile2, `duplicate label "${destNode.label}" replacement`, {
|
203328
|
+
node: destNode
|
203329
|
+
});
|
203330
|
+
}
|
203279
203331
|
destNode.label = sourceNode.label;
|
203280
203332
|
delete sourceNode.label;
|
203281
203333
|
}
|
@@ -204602,6 +204654,8 @@ var NotebookCellTags;
|
|
204602
204654
|
NotebookCellTags2["removeCell"] = "remove-cell";
|
204603
204655
|
NotebookCellTags2["removeInput"] = "remove-input";
|
204604
204656
|
NotebookCellTags2["removeOutput"] = "remove-output";
|
204657
|
+
NotebookCellTags2["skipExecution"] = "skip-execution";
|
204658
|
+
NotebookCellTags2["raisesException"] = "raises-exception";
|
204605
204659
|
})(NotebookCellTags || (NotebookCellTags = {}));
|
204606
204660
|
var ParseTypesEnum;
|
204607
204661
|
(function(ParseTypesEnum2) {
|
@@ -222168,6 +222222,12 @@ var defaultHtmlToMdastOptions = {
|
|
222168
222222
|
attrs.alt = node3.properties.alt;
|
222169
222223
|
return h4(node3, "image", attrs);
|
222170
222224
|
},
|
222225
|
+
iframe(h4, node3) {
|
222226
|
+
const attrs = addClassAndIdentifier(node3);
|
222227
|
+
attrs.src = String(node3.properties.src || "");
|
222228
|
+
attrs.width = "100%";
|
222229
|
+
return h4(node3, "iframe", attrs);
|
222230
|
+
},
|
222171
222231
|
figure(h4, node3) {
|
222172
222232
|
const attrs = addClassAndIdentifier(node3);
|
222173
222233
|
return h4(node3, "container", attrs, all5(h4, node3));
|
@@ -236886,6 +236946,8 @@ function tryRender(file, node3, value, opts) {
|
|
236886
236946
|
output: (opts === null || opts === void 0 ? void 0 : opts.mathML) ? "mathml" : void 0,
|
236887
236947
|
macros: { ...builtInMacros, ...simplifiedMacros },
|
236888
236948
|
strict: (f3, m2) => {
|
236949
|
+
if (f3 === "newLineInDisplayMode")
|
236950
|
+
return;
|
236889
236951
|
warnings2.push(`${f3}, ${m2}`);
|
236890
236952
|
}
|
236891
236953
|
});
|
@@ -237262,7 +237324,7 @@ function blockToFigureTransform(mdast2, opts) {
|
|
237262
237324
|
const caption3 = (_d2 = (_b = (_a7 = block5.data) === null || _a7 === void 0 ? void 0 : _a7.caption) !== null && _b !== void 0 ? _b : (_c = block5.data) === null || _c === void 0 ? void 0 : _c["fig-cap"]) !== null && _d2 !== void 0 ? _d2 : (_e = block5.data) === null || _e === void 0 ? void 0 : _e["tbl-cap"];
|
237263
237325
|
if (caption3) {
|
237264
237326
|
const kind = (_g = (_f = block5.data) === null || _f === void 0 ? void 0 : _f.kind) !== null && _g !== void 0 ? _g : ((_h = block5.data) === null || _h === void 0 ? void 0 : _h["tbl-cap"]) ? "table" : "figure";
|
237265
|
-
const children = (_j = parser3(caption3).children) !== null && _j !== void 0 ? _j : [];
|
237327
|
+
const children = typeof caption3 === "string" ? (_j = parser3(caption3).children) !== null && _j !== void 0 ? _j : [] : caption3;
|
237266
237328
|
children.push(...block5.children);
|
237267
237329
|
const container4 = {
|
237268
237330
|
type: "container",
|
@@ -238278,9 +238340,6 @@ function joinGatesTransform(tree, file) {
|
|
238278
238340
|
return node3;
|
238279
238341
|
});
|
238280
238342
|
}
|
238281
|
-
var joinGatesPlugin = () => (tree, file) => {
|
238282
|
-
joinGatesTransform(tree, file);
|
238283
|
-
};
|
238284
238343
|
|
238285
238344
|
// ../myst-transforms/dist/glossary.js
|
238286
238345
|
function glossaryTransform(mdast2, file) {
|
@@ -239346,6 +239405,7 @@ function basicTransformations(tree, file, opts) {
|
|
239346
239405
|
headingLabelTransform(tree);
|
239347
239406
|
admonitionBlockquoteTransform(tree);
|
239348
239407
|
admonitionHeadersTransform(tree);
|
239408
|
+
joinGatesTransform(tree, file);
|
239349
239409
|
blockNestingTransform(tree);
|
239350
239410
|
blockMetadataTransform(tree, file);
|
239351
239411
|
blockToFigureTransform(tree, opts);
|
@@ -281868,6 +281928,10 @@ var codeCellDirective = {
|
|
281868
281928
|
},
|
281869
281929
|
options: {
|
281870
281930
|
...commonDirectiveOptions("code-cell"),
|
281931
|
+
caption: {
|
281932
|
+
type: "myst",
|
281933
|
+
doc: "A parsed caption for the code output."
|
281934
|
+
},
|
281871
281935
|
tags: {
|
281872
281936
|
type: String,
|
281873
281937
|
alias: ["tag"],
|
@@ -281879,7 +281943,7 @@ var codeCellDirective = {
|
|
281879
281943
|
doc: "The code to be executed and displayed."
|
281880
281944
|
},
|
281881
281945
|
run(data, vfile2) {
|
281882
|
-
var _a6, _b;
|
281946
|
+
var _a6, _b, _c;
|
281883
281947
|
const code7 = {
|
281884
281948
|
type: "code",
|
281885
281949
|
lang: data.arg,
|
@@ -281898,7 +281962,10 @@ var codeCellDirective = {
|
|
281898
281962
|
data: {}
|
281899
281963
|
};
|
281900
281964
|
addCommonDirectiveOptions(data, block5);
|
281901
|
-
|
281965
|
+
if ((_b = data.options) === null || _b === void 0 ? void 0 : _b.caption) {
|
281966
|
+
block5.data.caption = [{ type: "paragraph", children: data.options.caption }];
|
281967
|
+
}
|
281968
|
+
const tags = parseTags((_c = data.options) === null || _c === void 0 ? void 0 : _c.tags, vfile2, data.node);
|
281902
281969
|
if (tags)
|
281903
281970
|
block5.data.tags = tags;
|
281904
281971
|
return [block5];
|
@@ -282127,14 +282194,14 @@ var iframeDirective = {
|
|
282127
282194
|
body: { type: "myst", doc: "If provided, this will be the iframe caption." },
|
282128
282195
|
run(data) {
|
282129
282196
|
var _a6, _b, _c, _d2, _e, _f, _g;
|
282130
|
-
const
|
282197
|
+
const iframe4 = {
|
282131
282198
|
type: "iframe",
|
282132
282199
|
src: data.arg,
|
282133
282200
|
width: (_a6 = data.options) === null || _a6 === void 0 ? void 0 : _a6.width,
|
282134
282201
|
align: (_b = data.options) === null || _b === void 0 ? void 0 : _b.align
|
282135
282202
|
};
|
282136
282203
|
if ((_c = data.options) === null || _c === void 0 ? void 0 : _c.placeholder) {
|
282137
|
-
|
282204
|
+
iframe4.children = [
|
282138
282205
|
{
|
282139
282206
|
type: "image",
|
282140
282207
|
placeholder: true,
|
@@ -282147,13 +282214,13 @@ var iframeDirective = {
|
|
282147
282214
|
];
|
282148
282215
|
}
|
282149
282216
|
if (!data.body) {
|
282150
|
-
addCommonDirectiveOptions(data,
|
282151
|
-
return [
|
282217
|
+
addCommonDirectiveOptions(data, iframe4);
|
282218
|
+
return [iframe4];
|
282152
282219
|
}
|
282153
282220
|
const container4 = {
|
282154
282221
|
type: "container",
|
282155
282222
|
kind: "figure",
|
282156
|
-
children: [
|
282223
|
+
children: [iframe4, { type: "caption", children: data.body }]
|
282157
282224
|
};
|
282158
282225
|
addCommonDirectiveOptions(data, container4);
|
282159
282226
|
return [container4];
|
@@ -285701,13 +285768,13 @@ var asideDirective = {
|
|
285701
285768
|
children: data.arg
|
285702
285769
|
});
|
285703
285770
|
}
|
285704
|
-
const
|
285771
|
+
const aside2 = {
|
285705
285772
|
type: "aside",
|
285706
285773
|
kind: data.name == "aside" || data.name == "margin" ? void 0 : data.name,
|
285707
285774
|
children
|
285708
285775
|
};
|
285709
|
-
addCommonDirectiveOptions(data,
|
285710
|
-
return [
|
285776
|
+
addCommonDirectiveOptions(data, aside2);
|
285777
|
+
return [aside2];
|
285711
285778
|
}
|
285712
285779
|
};
|
285713
285780
|
|
@@ -287777,7 +287844,7 @@ var MARKDOWN_IT_CONFIG = {
|
|
287777
287844
|
}
|
287778
287845
|
}
|
287779
287846
|
};
|
287780
|
-
var EXCLUDE_TLDS = ["py", "md", "dot", "next", "so"];
|
287847
|
+
var EXCLUDE_TLDS = ["py", "md", "dot", "next", "so", "es"];
|
287781
287848
|
|
287782
287849
|
// ../myst-parser/dist/tokensToMyst.js
|
287783
287850
|
var import_he = __toESM(require_he(), 1);
|
@@ -288161,10 +288228,11 @@ var defaultMdast = {
|
|
288161
288228
|
math_inline_double: {
|
288162
288229
|
type: "math",
|
288163
288230
|
noCloseToken: true,
|
288164
|
-
|
288231
|
+
isLeaf: true,
|
288165
288232
|
getAttrs(t2) {
|
288166
288233
|
var _a6;
|
288167
288234
|
return {
|
288235
|
+
value: t2.content.trim(),
|
288168
288236
|
enumerated: (_a6 = t2.meta) === null || _a6 === void 0 ? void 0 : _a6.enumerated
|
288169
288237
|
};
|
288170
288238
|
}
|
@@ -288172,11 +288240,12 @@ var defaultMdast = {
|
|
288172
288240
|
math_block: {
|
288173
288241
|
type: "math",
|
288174
288242
|
noCloseToken: true,
|
288175
|
-
|
288243
|
+
isLeaf: true,
|
288176
288244
|
getAttrs(t2) {
|
288177
288245
|
var _a6;
|
288178
288246
|
const name3 = t2.info || void 0;
|
288179
288247
|
return {
|
288248
|
+
value: t2.content.trim(),
|
288180
288249
|
...normalizeLabel(name3),
|
288181
288250
|
enumerated: (_a6 = t2.meta) === null || _a6 === void 0 ? void 0 : _a6.enumerated
|
288182
288251
|
};
|
@@ -288185,11 +288254,12 @@ var defaultMdast = {
|
|
288185
288254
|
math_block_label: {
|
288186
288255
|
type: "math",
|
288187
288256
|
noCloseToken: true,
|
288188
|
-
|
288257
|
+
isLeaf: true,
|
288189
288258
|
getAttrs(t2) {
|
288190
288259
|
var _a6;
|
288191
288260
|
const name3 = t2.info || void 0;
|
288192
288261
|
return {
|
288262
|
+
value: t2.content.trim(),
|
288193
288263
|
...normalizeLabel(name3),
|
288194
288264
|
enumerated: (_a6 = t2.meta) === null || _a6 === void 0 ? void 0 : _a6.enumerated
|
288195
288265
|
};
|
@@ -288198,11 +288268,12 @@ var defaultMdast = {
|
|
288198
288268
|
amsmath: {
|
288199
288269
|
type: "math",
|
288200
288270
|
noCloseToken: true,
|
288201
|
-
|
288271
|
+
isLeaf: true,
|
288202
288272
|
getAttrs(t2, tokens, index4, state) {
|
288203
288273
|
var _a6;
|
288204
288274
|
const tight = computeAmsmathTightness(state.src, t2.map);
|
288205
288275
|
const attrs = {
|
288276
|
+
value: t2.content.trim(),
|
288206
288277
|
enumerated: (_a6 = t2.meta) === null || _a6 === void 0 ? void 0 : _a6.enumerated
|
288207
288278
|
};
|
288208
288279
|
if (tight)
|
@@ -289247,63 +289318,6 @@ var exerciseDirectives = [
|
|
289247
289318
|
solutionEndDirective
|
289248
289319
|
];
|
289249
289320
|
|
289250
|
-
// ../myst-ext-reactive/dist/index.js
|
289251
|
-
var reactiveRole = {
|
289252
|
-
name: "r:range",
|
289253
|
-
alias: ["r:dynamic", "r:display"],
|
289254
|
-
body: {
|
289255
|
-
type: String,
|
289256
|
-
required: true
|
289257
|
-
},
|
289258
|
-
run(data) {
|
289259
|
-
const parsedContent = Object.fromEntries(data.body.split('", ').map((part) => {
|
289260
|
-
const [name3, value] = part.replace(/",?\s?$/, "").split('="');
|
289261
|
-
if (name3.startsWith("r")) {
|
289262
|
-
const transformed = `${name3.slice(1).toLowerCase()}Function`;
|
289263
|
-
return [transformed, value];
|
289264
|
-
}
|
289265
|
-
return [name3, value];
|
289266
|
-
}));
|
289267
|
-
return [
|
289268
|
-
{
|
289269
|
-
type: data.name,
|
289270
|
-
...parsedContent
|
289271
|
-
}
|
289272
|
-
];
|
289273
|
-
}
|
289274
|
-
};
|
289275
|
-
var reactiveDirective = {
|
289276
|
-
name: "r:var",
|
289277
|
-
options: {
|
289278
|
-
name: {
|
289279
|
-
type: String,
|
289280
|
-
required: true
|
289281
|
-
},
|
289282
|
-
value: {
|
289283
|
-
type: String
|
289284
|
-
},
|
289285
|
-
rValue: {
|
289286
|
-
type: String
|
289287
|
-
},
|
289288
|
-
format: {
|
289289
|
-
type: String
|
289290
|
-
}
|
289291
|
-
},
|
289292
|
-
run(data) {
|
289293
|
-
var _a6;
|
289294
|
-
const { name: name3, value, rValue, format } = (_a6 = data.options) !== null && _a6 !== void 0 ? _a6 : {};
|
289295
|
-
return [
|
289296
|
-
{
|
289297
|
-
type: "r:var",
|
289298
|
-
name: name3,
|
289299
|
-
value,
|
289300
|
-
valueFunction: rValue,
|
289301
|
-
format
|
289302
|
-
}
|
289303
|
-
];
|
289304
|
-
}
|
289305
|
-
};
|
289306
|
-
|
289307
289321
|
// ../myst-ext-tabs/dist/index.js
|
289308
289322
|
var tabSetDirective = {
|
289309
289323
|
name: "tab-set",
|
@@ -289367,7 +289381,6 @@ function parseMyst(session, content3, file, opts) {
|
|
289367
289381
|
directives: [
|
289368
289382
|
cardDirective,
|
289369
289383
|
...gridDirectives,
|
289370
|
-
reactiveDirective,
|
289371
289384
|
proofDirective,
|
289372
289385
|
...exerciseDirectives,
|
289373
289386
|
...tabDirectives,
|
@@ -289376,7 +289389,7 @@ function parseMyst(session, content3, file, opts) {
|
|
289376
289389
|
extensions: {
|
289377
289390
|
frontmatter: !(opts === null || opts === void 0 ? void 0 : opts.ignoreFrontmatter)
|
289378
289391
|
},
|
289379
|
-
roles: [
|
289392
|
+
roles: [...(_d2 = (_c = session.plugins) === null || _c === void 0 ? void 0 : _c.roles) !== null && _d2 !== void 0 ? _d2 : []],
|
289380
289393
|
vfile: vfile2
|
289381
289394
|
});
|
289382
289395
|
logMessagesFromVFile(session, vfile2);
|
@@ -289393,7 +289406,7 @@ var import_node_path16 = __toESM(require("path"), 1);
|
|
289393
289406
|
var import_nbtx = __toESM(require_cjs2(), 1);
|
289394
289407
|
|
289395
289408
|
// ../myst-cli/dist/version.js
|
289396
|
-
var version2 = "1.3.
|
289409
|
+
var version2 = "1.3.20";
|
289397
289410
|
var version_default2 = version2;
|
289398
289411
|
|
289399
289412
|
// ../myst-cli/dist/utils/headers.js
|
@@ -303127,6 +303140,10 @@ function reduceOutputs(session, mdast2, file, writeFolder, opts) {
|
|
303127
303140
|
const cache = castSession(session);
|
303128
303141
|
outputs.forEach((node3) => {
|
303129
303142
|
var _a6, _b, _c;
|
303143
|
+
if (node3.visibility === "remove" || node3.visibility === "hide") {
|
303144
|
+
node3.type = "__delete__";
|
303145
|
+
return;
|
303146
|
+
}
|
303130
303147
|
if (!((_a6 = node3.data) === null || _a6 === void 0 ? void 0 : _a6.length) && !((_b = node3.children) === null || _b === void 0 ? void 0 : _b.length)) {
|
303131
303148
|
node3.type = "__delete__";
|
303132
303149
|
return;
|
@@ -303169,6 +303186,9 @@ function reduceOutputs(session, mdast2, file, writeFolder, opts) {
|
|
303169
303186
|
]
|
303170
303187
|
};
|
303171
303188
|
htmlTransform(htmlTree);
|
303189
|
+
if (selectAll("image", htmlTree).find((htmlImage) => !htmlImage.url)) {
|
303190
|
+
return void 0;
|
303191
|
+
}
|
303172
303192
|
return htmlTree.children;
|
303173
303193
|
} else if (content_type.startsWith("image/")) {
|
303174
303194
|
const path44 = writeCachedOutputToFile(session, hash, cache.$outputs[hash], writeFolder, {
|
@@ -303287,11 +303307,11 @@ function isCellBlock(node3) {
|
|
303287
303307
|
}
|
303288
303308
|
function codeBlockRaisesException(node3) {
|
303289
303309
|
var _a6, _b, _c;
|
303290
|
-
return !!((_c = (_b = (_a6 = node3.data) === null || _a6 === void 0 ? void 0 : _a6.tags) === null || _b === void 0 ? void 0 : _b.includes) === null || _c === void 0 ? void 0 : _c.call(_b,
|
303310
|
+
return !!((_c = (_b = (_a6 = node3.data) === null || _a6 === void 0 ? void 0 : _a6.tags) === null || _b === void 0 ? void 0 : _b.includes) === null || _c === void 0 ? void 0 : _c.call(_b, NotebookCellTags.raisesException));
|
303291
303311
|
}
|
303292
303312
|
function codeBlockSkipsExecution(node3) {
|
303293
303313
|
var _a6, _b, _c;
|
303294
|
-
return !!((_c = (_b = (_a6 = node3.data) === null || _a6 === void 0 ? void 0 : _a6.tags) === null || _b === void 0 ? void 0 : _b.includes) === null || _c === void 0 ? void 0 : _c.call(_b,
|
303314
|
+
return !!((_c = (_b = (_a6 = node3.data) === null || _a6 === void 0 ? void 0 : _a6.tags) === null || _b === void 0 ? void 0 : _b.includes) === null || _c === void 0 ? void 0 : _c.call(_b, NotebookCellTags.skipExecution));
|
303295
303315
|
}
|
303296
303316
|
function isInlineExpression(node3) {
|
303297
303317
|
return node3.type === "inlineExpression";
|
@@ -303402,7 +303422,6 @@ async function kernelExecutionTransform(tree, vfile2, opts) {
|
|
303402
303422
|
// ../myst-execute/dist/manager.js
|
303403
303423
|
var import_which4 = __toESM(require_lib16(), 1);
|
303404
303424
|
var import_node_child_process = require("child_process");
|
303405
|
-
var readline = __toESM(require("readline"), 1);
|
303406
303425
|
|
303407
303426
|
// ../myst-execute/node_modules/chalk/source/vendor/ansi-styles/index.js
|
303408
303427
|
var ANSI_BACKGROUND_OFFSET3 = 10;
|
@@ -303894,36 +303913,6 @@ var chalkStderr3 = createChalk3({ level: stderrColor3 ? stderrColor3.level : 0 }
|
|
303894
303913
|
var source_default3 = chalk3;
|
303895
303914
|
|
303896
303915
|
// ../myst-execute/dist/manager.js
|
303897
|
-
async function findExistingJupyterServer(session) {
|
303898
|
-
const pythonPath = import_which4.default.sync("python");
|
303899
|
-
const listProc = (0, import_node_child_process.spawn)(pythonPath, ["-m", "jupyter_server", "list", "--json"]);
|
303900
|
-
const reader = readline.createInterface({ input: listProc.stdout });
|
303901
|
-
const servers = [];
|
303902
|
-
for await (const line2 of reader) {
|
303903
|
-
let server;
|
303904
|
-
try {
|
303905
|
-
server = JSON.parse(line2);
|
303906
|
-
} catch {
|
303907
|
-
}
|
303908
|
-
if ((server === null || server === void 0 ? void 0 : server.base_url) !== void 0) {
|
303909
|
-
servers.push(server);
|
303910
|
-
}
|
303911
|
-
}
|
303912
|
-
if (!servers.length) {
|
303913
|
-
return void 0;
|
303914
|
-
}
|
303915
|
-
servers.sort((a2, b) => a2.pid - b.pid);
|
303916
|
-
for (const entry of servers) {
|
303917
|
-
const response = await session.fetch(`${entry.url}?token=${entry.token}`);
|
303918
|
-
if (response.ok) {
|
303919
|
-
return {
|
303920
|
-
baseUrl: entry.url,
|
303921
|
-
token: entry.token
|
303922
|
-
};
|
303923
|
-
}
|
303924
|
-
}
|
303925
|
-
return void 0;
|
303926
|
-
}
|
303927
303916
|
async function launchJupyterServer(contentPath, log) {
|
303928
303917
|
log.info(`\u{1F680} ${source_default3.yellowBright("Starting new Jupyter server")}`);
|
303929
303918
|
const pythonPath = import_which4.default.sync("python");
|
@@ -304080,7 +304069,7 @@ async function transformMdast(session, opts) {
|
|
304080
304069
|
const pipe = unified().use(reconstructHtmlPlugin).use(htmlPlugin, { htmlHandlers }).use(basicTransformationsPlugin, {
|
304081
304070
|
parser: (content3) => parseMyst(session, content3, file),
|
304082
304071
|
firstDepth: (titleDepth !== null && titleDepth !== void 0 ? titleDepth : 1) + (frontmatter.content_includes_title ? 0 : 1)
|
304083
|
-
}).use(inlineMathSimplificationPlugin).use(mathPlugin, { macros: frontmatter.math }).use(glossaryPlugin).use(abbreviationPlugin, { abbreviations: frontmatter.abbreviations }).use(indexIdentifierPlugin).use(enumerateTargetsPlugin, { state })
|
304072
|
+
}).use(inlineMathSimplificationPlugin).use(mathPlugin, { macros: frontmatter.math }).use(glossaryPlugin).use(abbreviationPlugin, { abbreviations: frontmatter.abbreviations }).use(indexIdentifierPlugin).use(enumerateTargetsPlugin, { state });
|
304084
304073
|
(_c = session.plugins) === null || _c === void 0 ? void 0 : _c.transforms.forEach((t2) => {
|
304085
304074
|
if (t2.stage !== "document")
|
304086
304075
|
return;
|
@@ -306058,7 +306047,7 @@ var handlers3 = {
|
|
306058
306047
|
state.write("\\end{frame}\n\n");
|
306059
306048
|
return;
|
306060
306049
|
}
|
306061
|
-
if (node3.visibility === "remove")
|
306050
|
+
if (node3.visibility === "remove" || node3.visibility === "hide")
|
306062
306051
|
return;
|
306063
306052
|
if (metadataTags.includes("no-tex"))
|
306064
306053
|
return;
|
@@ -306100,9 +306089,8 @@ var handlers3 = {
|
|
306100
306089
|
},
|
306101
306090
|
code(node3, state) {
|
306102
306091
|
var _a6;
|
306103
|
-
if (node3.visibility === "remove")
|
306092
|
+
if (node3.visibility === "remove" || node3.visibility === "hide")
|
306104
306093
|
return;
|
306105
|
-
}
|
306106
306094
|
addIndexEntries(node3, state);
|
306107
306095
|
let start = "\\begin{verbatim}\n";
|
306108
306096
|
let end = "\n\\end{verbatim}";
|
@@ -306840,7 +306828,7 @@ function getDefaultCaptionSupplement(kind) {
|
|
306840
306828
|
return `${domain.slice(0, 1).toUpperCase()}${domain.slice(1)}`;
|
306841
306829
|
}
|
306842
306830
|
var containerHandler2 = (node3, state) => {
|
306843
|
-
var _a6, _b;
|
306831
|
+
var _a6, _b, _c;
|
306844
306832
|
if (state.data.isInTable) {
|
306845
306833
|
fileError(state.file, "Unable to render typst figure inside table", {
|
306846
306834
|
node: node3,
|
@@ -306887,6 +306875,13 @@ var containerHandler2 = (node3, state) => {
|
|
306887
306875
|
state.data.isInBlockquote = prevIsInBlockquote;
|
306888
306876
|
return;
|
306889
306877
|
}
|
306878
|
+
if ((_c = node3.enumerator) === null || _c === void 0 ? void 0 : _c.endsWith(".1")) {
|
306879
|
+
state.write(`#set figure(numbering: "${node3.enumerator}")
|
306880
|
+
`);
|
306881
|
+
state.write(`#counter(figure.where(kind: "${kind}")).update(0)
|
306882
|
+
|
306883
|
+
`);
|
306884
|
+
}
|
306890
306885
|
if (nonCaptions && nonCaptions.length > 1) {
|
306891
306886
|
const allSubFigs = nonCaptions.filter((item) => item.type === "container").length === nonCaptions.length;
|
306892
306887
|
state.useMacro('#import "@preview/subpar:0.1.1"');
|
@@ -306998,8 +306993,8 @@ var textOnlyReplacements3 = {
|
|
306998
306993
|
"\xA9": "#emoji.copyright ",
|
306999
306994
|
"\xAE": "#emoji.reg ",
|
307000
306995
|
"\u2122": "#emoji.tm ",
|
307001
|
-
"<": "\\<
|
307002
|
-
">": "\\>
|
306996
|
+
"<": "\\<",
|
306997
|
+
">": "\\>",
|
307003
306998
|
"\xA0": "~",
|
307004
306999
|
"\u202F": "~"
|
307005
307000
|
// eslint-disable-next-line no-irregular-whitespace
|
@@ -307055,9 +307050,11 @@ var mathReplacements2 = {
|
|
307055
307050
|
"\xD7": "times",
|
307056
307051
|
\u0391: "A",
|
307057
307052
|
\u03B1: "alpha",
|
307053
|
+
"\u{1D736}": "alpha",
|
307058
307054
|
\u0392: "B",
|
307059
307055
|
\u03B2: "beta",
|
307060
307056
|
\u00DF: "beta",
|
307057
|
+
"\u{1D737}": "beta",
|
307061
307058
|
\u0393: "Gamma",
|
307062
307059
|
\u03B3: "gamma",
|
307063
307060
|
\u0394: "Delta",
|
@@ -307065,6 +307062,7 @@ var mathReplacements2 = {
|
|
307065
307062
|
\u03B4: "delta",
|
307066
307063
|
\u0395: "E",
|
307067
307064
|
\u03B5: "epsilon",
|
307065
|
+
"\u{1D774}": "epsilon",
|
307068
307066
|
\u0396: "Z",
|
307069
307067
|
\u03B6: "zeta",
|
307070
307068
|
\u0397: "H",
|
@@ -307196,12 +307194,34 @@ function isEmptyNode(node3) {
|
|
307196
307194
|
return false;
|
307197
307195
|
}
|
307198
307196
|
var typstStrings = {
|
307199
|
-
",": (state) => state.data.inFunction ? "comma" : ",",
|
307197
|
+
",": (state) => state.data.inFunction && state._currentFunctions.slice(-1)[0] !== "text" ? "comma" : ",",
|
307200
307198
|
"&": (state) => state.data.inArray ? "," : "&",
|
307201
307199
|
"/": "\\/",
|
307202
307200
|
";": "\\;",
|
307203
|
-
"~": "med"
|
307204
|
-
|
307201
|
+
"~": "med",
|
307202
|
+
'"': '\\"'
|
307203
|
+
};
|
307204
|
+
var brackets = {
|
307205
|
+
"[": "bracket.l",
|
307206
|
+
"]": "bracket.r",
|
307207
|
+
"{": "brace.l",
|
307208
|
+
"}": "brace.r",
|
307209
|
+
"(": "paren.l",
|
307210
|
+
")": "paren.r",
|
307211
|
+
"|": "bar.v"
|
307212
|
+
};
|
307213
|
+
function createBrackets(scale) {
|
307214
|
+
return (state, node3) => {
|
307215
|
+
var _a6;
|
307216
|
+
const args = node3.args;
|
307217
|
+
node3.args = [];
|
307218
|
+
const b = ((_a6 = args === null || args === void 0 ? void 0 : args[0].content) === null || _a6 === void 0 ? void 0 : _a6[0]).content;
|
307219
|
+
const typstB = brackets[b];
|
307220
|
+
if (!typstB)
|
307221
|
+
throw new Error(`Undefined left bracket: ${b}`);
|
307222
|
+
return `#scale(x: ${scale}, y: ${scale})[$${typstB}$]`;
|
307223
|
+
};
|
307224
|
+
}
|
307205
307225
|
function splitStrings(node3) {
|
307206
307226
|
var _a6, _b, _c;
|
307207
307227
|
if (((_b = (_a6 = node3.args) === null || _a6 === void 0 ? void 0 : _a6[0].content) === null || _b === void 0 ? void 0 : _b.length) === 1 && ((_c = node3.args) === null || _c === void 0 ? void 0 : _c[0].content)[0].type === "string") {
|
@@ -307209,14 +307229,23 @@ function splitStrings(node3) {
|
|
307209
307229
|
}
|
307210
307230
|
}
|
307211
307231
|
var typstMacros = {
|
307232
|
+
$: "\\$",
|
307212
307233
|
cdot: "dot.op",
|
307213
307234
|
to: "arrow.r",
|
307214
307235
|
rightarrow: "arrow.r",
|
307236
|
+
Rightarrow: "arrow.r.double",
|
307215
307237
|
leftarrow: "arrow.l",
|
307238
|
+
Leftarrow: "arrow.l.double",
|
307216
307239
|
leftrightarrow: "arrow.l.r",
|
307217
307240
|
gets: "arrow.l",
|
307241
|
+
rightharpoonup: "harpoon.rt",
|
307242
|
+
rightharpoondown: "harpoon.rb",
|
307243
|
+
leftharpoonup: "harpoon.lt",
|
307244
|
+
leftharpoondown: "harpoon.lb",
|
307218
307245
|
infin: "infinity",
|
307246
|
+
// This is a mathjax only thing, https://docs.mathjax.org/en/v2.7-latest/tex.html#i
|
307219
307247
|
infty: "infinity",
|
307248
|
+
// oo
|
307220
307249
|
nonumber: "",
|
307221
307250
|
int: "integral",
|
307222
307251
|
iint: "integral.double",
|
@@ -307227,8 +307256,11 @@ var typstMacros = {
|
|
307227
307256
|
return "root";
|
307228
307257
|
},
|
307229
307258
|
vec: "arrow",
|
307259
|
+
check: "caron",
|
307260
|
+
bar: "macron",
|
307230
307261
|
mathbf: "bold",
|
307231
307262
|
boldsymbol: "bold",
|
307263
|
+
bf: "bold",
|
307232
307264
|
mathrm: "upright",
|
307233
307265
|
textrm: "upright",
|
307234
307266
|
rm: "upright",
|
@@ -307244,6 +307276,12 @@ var typstMacros = {
|
|
307244
307276
|
splitStrings(node3);
|
307245
307277
|
return "^";
|
307246
307278
|
},
|
307279
|
+
bigl: createBrackets("120%"),
|
307280
|
+
bigr: createBrackets("120%"),
|
307281
|
+
big: createBrackets("120%"),
|
307282
|
+
Bigl: createBrackets("180%"),
|
307283
|
+
Bigr: createBrackets("180%"),
|
307284
|
+
Big: createBrackets("180%"),
|
307247
307285
|
left: (state, node3) => {
|
307248
307286
|
var _a6;
|
307249
307287
|
const args = node3.args;
|
@@ -307259,8 +307297,11 @@ var typstMacros = {
|
|
307259
307297
|
return "|";
|
307260
307298
|
if (left2 === ".")
|
307261
307299
|
return "";
|
307300
|
+
if (left2 === "lbrack")
|
307301
|
+
return "[";
|
307262
307302
|
throw new Error(`Undefined left bracket: ${left2}`);
|
307263
307303
|
},
|
307304
|
+
lbrack: "[",
|
307264
307305
|
right: (state, node3) => {
|
307265
307306
|
var _a6;
|
307266
307307
|
const args = node3.args;
|
@@ -307276,18 +307317,38 @@ var typstMacros = {
|
|
307276
307317
|
return "|";
|
307277
307318
|
if (right2 === ".")
|
307278
307319
|
return "";
|
307320
|
+
if (right2 === "rbrack")
|
307321
|
+
return "]";
|
307279
307322
|
throw new Error(`Undefined right bracket: ${right2}`);
|
307280
307323
|
},
|
307324
|
+
rbrack: "]",
|
307281
307325
|
operatorname: (state, node3) => {
|
307282
307326
|
var _a6;
|
307283
307327
|
const text7 = (_a6 = node3.args) === null || _a6 === void 0 ? void 0 : _a6.slice(-1)[0];
|
307284
307328
|
node3.args = [{ type: "macro", content: "text", args: [text7] }];
|
307285
307329
|
return "op";
|
307286
307330
|
},
|
307331
|
+
mathop: "op",
|
307287
307332
|
"\\": (state, node3) => {
|
307333
|
+
var _a6;
|
307288
307334
|
node3.args = [];
|
307289
|
-
if (state.data.inArray)
|
307335
|
+
if (state.data.inArray) {
|
307336
|
+
state.data.previousMatRows = ((_a6 = state.data.previousMatRows) !== null && _a6 !== void 0 ? _a6 : 0) + 1;
|
307337
|
+
if (state._value.slice(-1) === "]")
|
307338
|
+
state.addWhitespace();
|
307290
307339
|
return ";";
|
307340
|
+
}
|
307341
|
+
return "\\\n";
|
307342
|
+
},
|
307343
|
+
cr: (state, node3) => {
|
307344
|
+
var _a6;
|
307345
|
+
node3.args = [];
|
307346
|
+
if (state.data.inArray) {
|
307347
|
+
state.data.previousMatRows = ((_a6 = state.data.previousMatRows) !== null && _a6 !== void 0 ? _a6 : 0) + 1;
|
307348
|
+
if (state._value.slice(-1) === "]")
|
307349
|
+
state.addWhitespace();
|
307350
|
+
return ";";
|
307351
|
+
}
|
307291
307352
|
return "\\\n";
|
307292
307353
|
},
|
307293
307354
|
sim: "tilde",
|
@@ -307295,15 +307356,20 @@ var typstMacros = {
|
|
307295
307356
|
simeq: "tilde.eq",
|
307296
307357
|
ne: "!=",
|
307297
307358
|
phi: "phi.alt",
|
307359
|
+
varphi: "phi.alt",
|
307298
307360
|
varepsilon: "epsilon",
|
307299
307361
|
propto: "prop",
|
307300
307362
|
doteq: "dot(eq)",
|
307301
307363
|
ge: "gt.eq",
|
307302
307364
|
geq: "gt.eq",
|
307365
|
+
gg: "gt.double",
|
307303
307366
|
le: "lt.eq",
|
307304
307367
|
leq: "lt.eq",
|
307368
|
+
ll: "lt.double",
|
307305
307369
|
neq: "eq.not",
|
307306
307370
|
otimes: "times.circle",
|
307371
|
+
circ: "compose",
|
307372
|
+
vert: "bar.v",
|
307307
307373
|
dot: "dot",
|
307308
307374
|
ddot: "dot.double",
|
307309
307375
|
dots: "dots.h",
|
@@ -307315,6 +307381,7 @@ var typstMacros = {
|
|
307315
307381
|
cap: "sect",
|
307316
307382
|
cup: "union",
|
307317
307383
|
widehat: "hat",
|
307384
|
+
widetilde: "tilde",
|
307318
307385
|
// Spaces
|
307319
307386
|
",": "thin",
|
307320
307387
|
":": "med",
|
@@ -307322,9 +307389,14 @@ var typstMacros = {
|
|
307322
307389
|
"!": "#h(-1em)",
|
307323
307390
|
quad: "quad",
|
307324
307391
|
qquad: "wide",
|
307392
|
+
wedge: "and",
|
307325
307393
|
prod: "product",
|
307394
|
+
lfloor: "floor.l",
|
307395
|
+
rfloor: "floor.r",
|
307396
|
+
implies: "arrow.r.double.long",
|
307326
307397
|
biggl: "",
|
307327
307398
|
biggr: "",
|
307399
|
+
" ": '" "',
|
307328
307400
|
mathbb: (state, node3) => {
|
307329
307401
|
var _a6, _b, _c, _d2, _e;
|
307330
307402
|
const text7 = (_e = (_d2 = (_c = (_b = (_a6 = node3.args) === null || _a6 === void 0 ? void 0 : _a6.slice(-1)[0]) === null || _b === void 0 ? void 0 : _b.content) === null || _c === void 0 ? void 0 : _c[0]) === null || _d2 === void 0 ? void 0 : _d2.content) !== null && _e !== void 0 ? _e : "";
|
@@ -307347,16 +307419,62 @@ var typstMacros = {
|
|
307347
307419
|
state.useMacro('#import "@preview/ouset:0.2.0": *');
|
307348
307420
|
node3.args = (_a6 = node3.args) === null || _a6 === void 0 ? void 0 : _a6.reverse();
|
307349
307421
|
return "underset";
|
307422
|
+
},
|
307423
|
+
overrightarrow: (state, node3) => {
|
307424
|
+
var _a6;
|
307425
|
+
(_a6 = node3.args) === null || _a6 === void 0 ? void 0 : _a6.push({ type: "argument", content: [{ type: "macro", content: "arrow" }] });
|
307426
|
+
return "accent";
|
307427
|
+
},
|
307428
|
+
overleftarrow: (state, node3) => {
|
307429
|
+
var _a6;
|
307430
|
+
(_a6 = node3.args) === null || _a6 === void 0 ? void 0 : _a6.push({ type: "argument", content: [{ type: "macro", content: "arrow.l" }] });
|
307431
|
+
return "accent";
|
307432
|
+
},
|
307433
|
+
middle: (state) => {
|
307434
|
+
var _a6;
|
307435
|
+
return `mat(delim: #("|", none), ${";".repeat((_a6 = state.data.previousMatRows) !== null && _a6 !== void 0 ? _a6 : 1)})`;
|
307436
|
+
},
|
307437
|
+
stackrel: (state, node3) => {
|
307438
|
+
var _a6;
|
307439
|
+
const args = (_a6 = node3.args) === null || _a6 === void 0 ? void 0 : _a6.reverse();
|
307440
|
+
node3.args = [];
|
307441
|
+
state.writeChildren(args === null || args === void 0 ? void 0 : args[0]);
|
307442
|
+
state.write("^");
|
307443
|
+
state.writeChildren(args === null || args === void 0 ? void 0 : args[1]);
|
307444
|
+
return "";
|
307445
|
+
},
|
307446
|
+
color: (state, node3) => {
|
307447
|
+
var _a6, _b, _c;
|
307448
|
+
const [fill3, children] = (_a6 = node3.args) !== null && _a6 !== void 0 ? _a6 : [];
|
307449
|
+
const color2 = (_c = (_b = fill3.content) === null || _b === void 0 ? void 0 : _b[0]) === null || _c === void 0 ? void 0 : _c.content;
|
307450
|
+
node3.args = [];
|
307451
|
+
state.openFunction(`#text(fill: ${color2})`, { openToken: "[$", closeToken: "$]" });
|
307452
|
+
state.writeChildren(children);
|
307453
|
+
state.closeFunction();
|
307454
|
+
return "";
|
307350
307455
|
}
|
307351
307456
|
};
|
307457
|
+
var matrixEnv = (delim) => (state, node3) => {
|
307458
|
+
state.data.inArray = true;
|
307459
|
+
state.data.previousMatRows = 0;
|
307460
|
+
state.openFunction("mat");
|
307461
|
+
state.write(`delim: ${delim ? `"${delim}"` : "#none"},`);
|
307462
|
+
state.writeChildren(node3);
|
307463
|
+
state.closeFunction();
|
307464
|
+
state.data.inArray = false;
|
307465
|
+
};
|
307352
307466
|
var typstEnvs = {
|
307353
|
-
array: (
|
307354
|
-
|
307355
|
-
|
307356
|
-
|
307467
|
+
array: matrixEnv(),
|
307468
|
+
matrix: matrixEnv(),
|
307469
|
+
pmatrix: matrixEnv("("),
|
307470
|
+
bmatrix: matrixEnv("["),
|
307471
|
+
Bmatrix: matrixEnv("{"),
|
307472
|
+
vmatrix: matrixEnv("|"),
|
307473
|
+
aligned(state, node3) {
|
307474
|
+
state.writeChildren(node3);
|
307475
|
+
},
|
307476
|
+
["aligned*"](state, node3) {
|
307357
307477
|
state.writeChildren(node3);
|
307358
|
-
state.closeFunction();
|
307359
|
-
state.data.inArray = false;
|
307360
307478
|
}
|
307361
307479
|
};
|
307362
307480
|
|
@@ -307368,11 +307486,20 @@ function parseLatex2(value) {
|
|
307368
307486
|
boldsymbol: { signature: "m" },
|
307369
307487
|
left: { signature: "m" },
|
307370
307488
|
right: { signature: "m" },
|
307489
|
+
Big: { signature: "m" },
|
307490
|
+
Bigr: { signature: "m" },
|
307491
|
+
Bigl: { signature: "m" },
|
307492
|
+
big: { signature: "m" },
|
307493
|
+
bigr: { signature: "m" },
|
307494
|
+
bigl: { signature: "m" },
|
307371
307495
|
dot: { signature: "m" },
|
307372
307496
|
ddot: { signature: "m" },
|
307373
307497
|
hat: { signature: "m" },
|
307374
307498
|
tilde: { signature: "m" },
|
307499
|
+
check: { signature: "m" },
|
307500
|
+
bar: { signature: "m" },
|
307375
307501
|
widehat: { signature: "m" },
|
307502
|
+
widetilde: { signature: "m" },
|
307376
307503
|
overset: { signature: "m m" },
|
307377
307504
|
underset: { signature: "m m" },
|
307378
307505
|
overbrace: { signature: "m" },
|
@@ -307380,7 +307507,14 @@ function parseLatex2(value) {
|
|
307380
307507
|
overparen: { signature: "m" },
|
307381
307508
|
underbrace: { signature: "m" },
|
307382
307509
|
underline: { signature: "m" },
|
307383
|
-
underparen: { signature: "m" }
|
307510
|
+
underparen: { signature: "m" },
|
307511
|
+
overrightarrow: { signature: "m" },
|
307512
|
+
overleftarrow: { signature: "m" },
|
307513
|
+
stackrel: { signature: "m m" },
|
307514
|
+
mathop: { signature: "m" },
|
307515
|
+
bf: { signature: "m" },
|
307516
|
+
textstyle: { signature: "m" }
|
307517
|
+
// color: { signature: 'm m' }, // This doesn't work, changing it below manually
|
307384
307518
|
}
|
307385
307519
|
}).processSync({ value });
|
307386
307520
|
const content3 = file.result.content;
|
@@ -307393,7 +307527,7 @@ function walkLatex2(node3) {
|
|
307393
307527
|
const content3 = node3.content.map((n) => walkLatex2(n));
|
307394
307528
|
let skip = 0;
|
307395
307529
|
const parsed = content3.reduce((list6, next, i2, array) => {
|
307396
|
-
var _a6;
|
307530
|
+
var _a6, _b, _c, _d2, _e, _f, _g;
|
307397
307531
|
if (skip > 0) {
|
307398
307532
|
skip -= 1;
|
307399
307533
|
return list6;
|
@@ -307404,12 +307538,39 @@ function walkLatex2(node3) {
|
|
307404
307538
|
next.args = args;
|
307405
307539
|
skip += nodesRemoved;
|
307406
307540
|
}
|
307541
|
+
if (next.type === "macro" && next.content === "color") {
|
307542
|
+
const { args, nodesRemoved } = gobbleArguments(array.slice(i2 + 1), "m");
|
307543
|
+
next.type = "macro";
|
307544
|
+
next.args = [...(_b = (_a6 = next.args) === null || _a6 === void 0 ? void 0 : _a6.slice(1)) !== null && _b !== void 0 ? _b : [], ...args];
|
307545
|
+
skip += nodesRemoved;
|
307546
|
+
}
|
307547
|
+
if (next.type === "macro" && next.content === "textstyle") {
|
307548
|
+
next.content = "text";
|
307549
|
+
}
|
307407
307550
|
if (next.type === "macro" && (next.content === "overbrace" || next.content === "underbrace")) {
|
307408
307551
|
const { args, nodesRemoved } = gobbleArguments(array.slice(i2 + 1), "m");
|
307409
307552
|
if (args[0].content.length === 1 && args[0].content[0].type === "macro" && (args[0].content[0].content === "^" && next.content === "overbrace" || args[0].content[0].content === "_" && next.content === "underbrace")) {
|
307410
|
-
next.args = [...(
|
307553
|
+
next.args = [...(_c = next.args) !== null && _c !== void 0 ? _c : [], ...args[0].content[0].args];
|
307411
307554
|
skip += nodesRemoved;
|
307412
307555
|
}
|
307556
|
+
if (args[0].content.length === 1 && args[0].content[0].type === "string" && (args[0].content[0].content === "^" && next.content === "overbrace" || args[0].content[0].content === "_" && next.content === "underbrace")) {
|
307557
|
+
const { args: doubleArgs, nodesRemoved: doubleNodesRemoved } = gobbleArguments(array.slice(i2 + 1), "m m");
|
307558
|
+
next.args = [...(_d2 = next.args) !== null && _d2 !== void 0 ? _d2 : [], doubleArgs[1]];
|
307559
|
+
skip += doubleNodesRemoved;
|
307560
|
+
}
|
307561
|
+
}
|
307562
|
+
if (next.type === "macro" && next.content === "middle" && ((_e = array[i2 + 1]) === null || _e === void 0 ? void 0 : _e.content) === "|") {
|
307563
|
+
skip += 1;
|
307564
|
+
}
|
307565
|
+
if (next.type === "group" && ((_g = (_f = next.content) === null || _f === void 0 ? void 0 : _f.find) === null || _g === void 0 ? void 0 : _g.call(_f, (n) => n.type === "macro" && n.content === "over"))) {
|
307566
|
+
const children = next.content;
|
307567
|
+
next.type = "macro";
|
307568
|
+
next.content = "frac";
|
307569
|
+
const index4 = children.findIndex((n) => n.type === "macro" && n.content === "over");
|
307570
|
+
next.args = [
|
307571
|
+
{ type: "argument", content: children.slice(0, index4) },
|
307572
|
+
{ type: "argument", content: children.slice(index4 + 1) }
|
307573
|
+
];
|
307413
307574
|
}
|
307414
307575
|
list6.push(next);
|
307415
307576
|
return list6;
|
@@ -307442,7 +307603,12 @@ var State4 = class {
|
|
307442
307603
|
}
|
307443
307604
|
addWhitespace() {
|
307444
307605
|
const lastChar = this.value.slice(-1);
|
307445
|
-
if (!this._value
|
307606
|
+
if (!this._value)
|
307607
|
+
return;
|
307608
|
+
if (lastChar.match(/^(["\s_^{(-])$/))
|
307609
|
+
return;
|
307610
|
+
const lastTwoChar = this.value.slice(-2);
|
307611
|
+
if (!this._value || lastTwoChar === ")[" || lastTwoChar === "[$")
|
307446
307612
|
return;
|
307447
307613
|
this._value += " ";
|
307448
307614
|
}
|
@@ -307451,7 +307617,7 @@ var State4 = class {
|
|
307451
307617
|
return;
|
307452
307618
|
if (this._scriptsSimplified && str2 === "(") {
|
307453
307619
|
this.addWhitespace();
|
307454
|
-
} else if (str2.match(/^([}
|
307620
|
+
} else if (str2.match(/^([})_^.,;!])$/) || str2 === '\\"') {
|
307455
307621
|
} else {
|
307456
307622
|
this.addWhitespace();
|
307457
307623
|
}
|
@@ -307472,7 +307638,7 @@ var State4 = class {
|
|
307472
307638
|
get _functionCount() {
|
307473
307639
|
return this._currentFunctions.length;
|
307474
307640
|
}
|
307475
|
-
openFunction(command) {
|
307641
|
+
openFunction(command, { openToken, closeToken } = {}) {
|
307476
307642
|
if (command === "text") {
|
307477
307643
|
this.addWhitespace();
|
307478
307644
|
} else {
|
@@ -307482,8 +307648,8 @@ var State4 = class {
|
|
307482
307648
|
this.data.inFunction = true;
|
307483
307649
|
this._simplify = command === "_" || command === "^";
|
307484
307650
|
this._lastFunction = this._value.length;
|
307485
|
-
this._value += command === "text" ? '"' : "(";
|
307486
|
-
this._closeToken.push(command === "text" ? '"' : ")");
|
307651
|
+
this._value += openToken !== null && openToken !== void 0 ? openToken : command === "text" ? '"' : "(";
|
307652
|
+
this._closeToken.push(closeToken !== null && closeToken !== void 0 ? closeToken : command === "text" ? '"' : ")");
|
307487
307653
|
}
|
307488
307654
|
closeFunction() {
|
307489
307655
|
this._value += this._closeToken.pop() || ")";
|
@@ -307613,7 +307779,7 @@ function resolveRecursiveCommands(plugins3) {
|
|
307613
307779
|
return newPlugins;
|
307614
307780
|
}
|
307615
307781
|
var math5 = (node3, state) => {
|
307616
|
-
var _a6;
|
307782
|
+
var _a6, _b;
|
307617
307783
|
const { value, macros: macros18 } = texToTypst(node3.value);
|
307618
307784
|
macros18 === null || macros18 === void 0 ? void 0 : macros18.forEach((macro2) => {
|
307619
307785
|
state.useMacro(macro2);
|
@@ -307621,6 +307787,13 @@ var math5 = (node3, state) => {
|
|
307621
307787
|
const { identifier: label } = (_a6 = normalizeLabel(node3.label)) !== null && _a6 !== void 0 ? _a6 : {};
|
307622
307788
|
addMacrosToState2(value, state);
|
307623
307789
|
state.ensureNewLine();
|
307790
|
+
if ((_b = node3.enumerator) === null || _b === void 0 ? void 0 : _b.endsWith(".1")) {
|
307791
|
+
state.write(`#set math.equation(numbering: "(${node3.enumerator})")
|
307792
|
+
`);
|
307793
|
+
state.write(`#counter(math.equation).update(0)
|
307794
|
+
|
307795
|
+
`);
|
307796
|
+
}
|
307624
307797
|
state.write(`$ ${value} $${label ? ` <${label}>` : ""}
|
307625
307798
|
|
307626
307799
|
`);
|
@@ -307705,6 +307878,54 @@ var tableCellHandler = (node3, state) => {
|
|
307705
307878
|
state.write("],\n");
|
307706
307879
|
};
|
307707
307880
|
|
307881
|
+
// ../myst-to-typst/dist/proofs.js
|
307882
|
+
var proof = `
|
307883
|
+
#let proof(body, heading: [], kind: "proof", supplement: "Proof", labelName: none, color: blue, float: true) = {
|
307884
|
+
let stroke = 1pt + color.lighten(90%)
|
307885
|
+
let fill = color.lighten(90%)
|
307886
|
+
let title
|
307887
|
+
set figure.caption(position: top)
|
307888
|
+
set figure(placement: none)
|
307889
|
+
show figure.caption.where(body: heading): (it) => {
|
307890
|
+
block(width: 100%, stroke: stroke, fill: fill, inset: 8pt, it)
|
307891
|
+
}
|
307892
|
+
place(auto, float: float, block(width: 100%, [
|
307893
|
+
#figure(kind: kind, supplement: supplement, gap: 0pt, [
|
307894
|
+
#set align(left);
|
307895
|
+
#set figure.caption(position: bottom)
|
307896
|
+
#block(width: 100%, fill: luma(253), stroke: stroke, inset: 8pt)[#body]
|
307897
|
+
], caption: heading)
|
307898
|
+
#if(labelName != none){label(labelName)}
|
307899
|
+
]))
|
307900
|
+
}`;
|
307901
|
+
function writeProof(node3, state, kind) {
|
307902
|
+
state.useMacro(proof);
|
307903
|
+
const title = select("admonitionTitle", node3);
|
307904
|
+
const supplement = getDefaultCaptionSupplement(kind);
|
307905
|
+
state.write(`#proof(kind: "${kind}", supplement: "${supplement}", labelName: ${node3.identifier ? `"${node3.identifier}"` : "none"}`);
|
307906
|
+
if (title) {
|
307907
|
+
state.write(", heading: [");
|
307908
|
+
state.renderChildren(title);
|
307909
|
+
state.write("])[\n");
|
307910
|
+
} else {
|
307911
|
+
state.write(")[\n");
|
307912
|
+
}
|
307913
|
+
state.renderChildren(node3);
|
307914
|
+
state.write("]");
|
307915
|
+
state.ensureNewLine();
|
307916
|
+
}
|
307917
|
+
var proofHandlers = {
|
307918
|
+
proof(node3, state) {
|
307919
|
+
writeProof(node3, state, node3.kind || "proof");
|
307920
|
+
},
|
307921
|
+
exercise(node3, state) {
|
307922
|
+
writeProof(node3, state, "exercise");
|
307923
|
+
},
|
307924
|
+
solution(node3, state) {
|
307925
|
+
writeProof(node3, state, "solution");
|
307926
|
+
}
|
307927
|
+
};
|
307928
|
+
|
307708
307929
|
// ../myst-to-typst/dist/index.js
|
307709
307930
|
var admonition2 = `#let admonition(body, heading: none, color: blue) = {
|
307710
307931
|
let stroke = (left: 2pt + color.darken(20%))
|
@@ -307745,25 +307966,6 @@ var tabItem = `
|
|
307745
307966
|
#block(width: 100%, inset: (x: 8pt, bottom: 8pt))[#body]
|
307746
307967
|
])
|
307747
307968
|
}`;
|
307748
|
-
var proof = `
|
307749
|
-
#let proof(body, heading: [], kind: "proof", supplement: "Proof", labelName: none, color: blue, float: true) = {
|
307750
|
-
let stroke = 1pt + color.lighten(90%)
|
307751
|
-
let fill = color.lighten(90%)
|
307752
|
-
let title
|
307753
|
-
set figure.caption(position: top)
|
307754
|
-
set figure(placement: none)
|
307755
|
-
show figure.caption.where(body: heading): (it) => {
|
307756
|
-
block(width: 100%, stroke: stroke, fill: fill, inset: 8pt, it)
|
307757
|
-
}
|
307758
|
-
place(auto, float: float, block(width: 100%, [
|
307759
|
-
#figure(kind: kind, supplement: supplement, gap: 0pt, [
|
307760
|
-
#set align(left);
|
307761
|
-
#set figure.caption(position: bottom)
|
307762
|
-
#block(width: 100%, fill: luma(253), stroke: stroke, inset: 8pt)[#body]
|
307763
|
-
], caption: heading)
|
307764
|
-
#if(labelName != none){label(labelName)}
|
307765
|
-
]))
|
307766
|
-
}`;
|
307767
307969
|
var INDENT = " ";
|
307768
307970
|
var linkHandler = (node3, state) => {
|
307769
307971
|
const href = node3.url;
|
@@ -307776,6 +307978,16 @@ var linkHandler = (node3, state) => {
|
|
307776
307978
|
state.write("]");
|
307777
307979
|
}
|
307778
307980
|
};
|
307981
|
+
function prevCharacterIsText(parent2, node3) {
|
307982
|
+
var _a6, _b;
|
307983
|
+
const ind = (_a6 = parent2 === null || parent2 === void 0 ? void 0 : parent2.children) === null || _a6 === void 0 ? void 0 : _a6.findIndex((n) => n === node3);
|
307984
|
+
if (!ind)
|
307985
|
+
return false;
|
307986
|
+
const prev = (_b = parent2 === null || parent2 === void 0 ? void 0 : parent2.children) === null || _b === void 0 ? void 0 : _b[ind - 1];
|
307987
|
+
if (!(prev === null || prev === void 0 ? void 0 : prev.value))
|
307988
|
+
return false;
|
307989
|
+
return (prev === null || prev === void 0 ? void 0 : prev.type) === "text" && !!prev.value.match(/[a-zA-Z0-9\-_]$/) || false;
|
307990
|
+
}
|
307779
307991
|
function nextCharacterIsText(parent2, node3) {
|
307780
307992
|
var _a6, _b;
|
307781
307993
|
const ind = (_a6 = parent2 === null || parent2 === void 0 ? void 0 : parent2.children) === null || _a6 === void 0 ? void 0 : _a6.findIndex((n) => n === node3);
|
@@ -307791,13 +308003,15 @@ var handlers4 = {
|
|
307791
308003
|
state.text(node3.value);
|
307792
308004
|
},
|
307793
308005
|
paragraph(node3, state) {
|
307794
|
-
|
308006
|
+
const { identifier } = node3;
|
308007
|
+
const after = identifier ? ` <${identifier}>` : void 0;
|
308008
|
+
state.renderChildren(node3, 2, { after });
|
307795
308009
|
},
|
307796
308010
|
heading(node3, state) {
|
307797
|
-
const { depth, identifier, enumerated } = node3;
|
308011
|
+
const { depth, identifier, enumerated, implicit } = node3;
|
307798
308012
|
state.write(`${Array(depth).fill("=").join("")} `);
|
307799
308013
|
state.renderChildren(node3);
|
307800
|
-
if (enumerated !== false && identifier) {
|
308014
|
+
if (enumerated !== false && identifier && !implicit) {
|
307801
308015
|
state.write(` <${identifier}>`);
|
307802
308016
|
}
|
307803
308017
|
state.write("\n\n");
|
@@ -307808,7 +308022,7 @@ var handlers4 = {
|
|
307808
308022
|
return;
|
307809
308023
|
if (metadataTags.includes("no-pdf"))
|
307810
308024
|
return;
|
307811
|
-
if (node3.visibility === "remove")
|
308025
|
+
if (node3.visibility === "remove" || node3.visibility === "hide")
|
307812
308026
|
return;
|
307813
308027
|
if (metadataTags.includes("page-break") || metadataTags.includes("new-page")) {
|
307814
308028
|
state.write("#pagebreak(weak: true)\n");
|
@@ -307850,9 +308064,8 @@ var handlers4 = {
|
|
307850
308064
|
},
|
307851
308065
|
code(node3, state) {
|
307852
308066
|
var _a6;
|
307853
|
-
if (node3.visibility === "remove")
|
308067
|
+
if (node3.visibility === "remove" || node3.visibility === "hide")
|
307854
308068
|
return;
|
307855
|
-
}
|
307856
308069
|
let ticks = "```";
|
307857
308070
|
while (node3.value.includes(ticks)) {
|
307858
308071
|
ticks += "`";
|
@@ -307917,8 +308130,9 @@ ${node3.value}
|
|
307917
308130
|
}
|
307918
308131
|
},
|
307919
308132
|
strong(node3, state, parent2) {
|
308133
|
+
const prev = prevCharacterIsText(parent2, node3);
|
307920
308134
|
const next = nextCharacterIsText(parent2, node3);
|
307921
|
-
if (nodeOnlyHasTextChildren(node3) && !next) {
|
308135
|
+
if (nodeOnlyHasTextChildren(node3) && !(prev || next)) {
|
307922
308136
|
state.write("*");
|
307923
308137
|
state.renderChildren(node3);
|
307924
308138
|
state.write("*");
|
@@ -307927,8 +308141,9 @@ ${node3.value}
|
|
307927
308141
|
}
|
307928
308142
|
},
|
307929
308143
|
emphasis(node3, state, parent2) {
|
308144
|
+
const prev = prevCharacterIsText(parent2, node3);
|
307930
308145
|
const next = nextCharacterIsText(parent2, node3);
|
307931
|
-
if (nodeOnlyHasTextChildren(node3) && !next) {
|
308146
|
+
if (nodeOnlyHasTextChildren(node3) && !prev && !next) {
|
307932
308147
|
state.write("_");
|
307933
308148
|
state.renderChildren(node3);
|
307934
308149
|
state.write("_");
|
@@ -308038,9 +308253,9 @@ ${node3.value}
|
|
308038
308253
|
legend: captionHandler2,
|
308039
308254
|
captionNumber: () => void 0,
|
308040
308255
|
crossReference(node3, state, parent2) {
|
308041
|
-
var _a6
|
308042
|
-
if (node3.
|
308043
|
-
const url =
|
308256
|
+
var _a6;
|
308257
|
+
if (node3.remoteBaseUrl) {
|
308258
|
+
const url = node3.remoteBaseUrl + (node3.url === "/" ? "" : (_a6 = node3.url) !== null && _a6 !== void 0 ? _a6 : "") + (node3.html_id ? `#${node3.html_id}` : "");
|
308044
308259
|
linkHandler({ ...node3, url }, state);
|
308045
308260
|
return;
|
308046
308261
|
}
|
@@ -308129,23 +308344,6 @@ ${node3.value}
|
|
308129
308344
|
state.renderChildren(node3);
|
308130
308345
|
state.write("\n]\n\n");
|
308131
308346
|
},
|
308132
|
-
proof(node3, state) {
|
308133
|
-
state.useMacro(proof);
|
308134
|
-
const title = select("admonitionTitle", node3);
|
308135
|
-
const kind = node3.kind || "proof";
|
308136
|
-
const supplement = getDefaultCaptionSupplement(kind);
|
308137
|
-
state.write(`#proof(kind: "${kind}", supplement: "${supplement}", labelName: ${node3.identifier ? `"${node3.identifier}"` : "none"}`);
|
308138
|
-
if (title) {
|
308139
|
-
state.write(", heading: [");
|
308140
|
-
state.renderChildren(title);
|
308141
|
-
state.write("])[");
|
308142
|
-
} else {
|
308143
|
-
state.write(")[");
|
308144
|
-
}
|
308145
|
-
state.renderChildren(node3);
|
308146
|
-
state.write("]");
|
308147
|
-
state.ensureNewLine();
|
308148
|
-
},
|
308149
308347
|
card(node3, state) {
|
308150
308348
|
var _a6;
|
308151
308349
|
if (node3.url) {
|
@@ -308167,7 +308365,8 @@ ${node3.value}
|
|
308167
308365
|
},
|
308168
308366
|
footer() {
|
308169
308367
|
return;
|
308170
|
-
}
|
308368
|
+
},
|
308369
|
+
...proofHandlers
|
308171
308370
|
};
|
308172
308371
|
var TypstSerializer = class {
|
308173
308372
|
constructor(file, tree, opts) {
|
@@ -308218,7 +308417,7 @@ var TypstSerializer = class {
|
|
308218
308417
|
this.renderChildren({ children: node3 }, trailingNewLines, opts);
|
308219
308418
|
return;
|
308220
308419
|
}
|
308221
|
-
const { delim = "", trimEnd: trimEnd2 = true } = opts;
|
308420
|
+
const { delim = "", trimEnd: trimEnd2 = true, after } = opts;
|
308222
308421
|
const numChildren = (_b = (_a6 = node3.children) === null || _a6 === void 0 ? void 0 : _a6.length) !== null && _b !== void 0 ? _b : 0;
|
308223
308422
|
(_c = node3.children) === null || _c === void 0 ? void 0 : _c.forEach((child, index4) => {
|
308224
308423
|
if (!child)
|
@@ -308237,6 +308436,8 @@ var TypstSerializer = class {
|
|
308237
308436
|
});
|
308238
308437
|
if (trimEnd2)
|
308239
308438
|
this.trimEnd();
|
308439
|
+
if (after)
|
308440
|
+
this.write(after);
|
308240
308441
|
for (let i2 = trailingNewLines; i2--; )
|
308241
308442
|
this.addNewLine();
|
308242
308443
|
}
|
@@ -308443,6 +308644,23 @@ async function localArticleToTypstTemplated(session, file, templateOptions, opts
|
|
308443
308644
|
macros: [],
|
308444
308645
|
commands: {}
|
308445
308646
|
};
|
308647
|
+
const state = session.store.getState();
|
308648
|
+
const projectFrontmatter = (_a6 = selectors_exports.selectLocalProjectConfig(state, projectPath !== null && projectPath !== void 0 ? projectPath : ".")) !== null && _a6 !== void 0 ? _a6 : {};
|
308649
|
+
if (file === selectors_exports.selectCurrentProjectFile(state)) {
|
308650
|
+
partDefinitions.forEach((def) => {
|
308651
|
+
var _a7;
|
308652
|
+
const part = extractTypstPart(session, { type: "root", children: [] }, {}, def, projectFrontmatter, templateYml);
|
308653
|
+
if (Array.isArray(part)) {
|
308654
|
+
part.forEach((item) => {
|
308655
|
+
collected = mergeTypstTemplateImports(collected, item);
|
308656
|
+
});
|
308657
|
+
parts[def.id] = part.map(({ value }) => value);
|
308658
|
+
} else if (part != null) {
|
308659
|
+
collected = mergeTypstTemplateImports(collected, part);
|
308660
|
+
parts[def.id] = (_a7 = part === null || part === void 0 ? void 0 : part.value) !== null && _a7 !== void 0 ? _a7 : "";
|
308661
|
+
}
|
308662
|
+
});
|
308663
|
+
}
|
308446
308664
|
const hasGlossaries = false;
|
308447
308665
|
const results = await Promise.all(content3.map(async ({ mdast: mdast2, frontmatter: frontmatter2, references }, ind) => {
|
308448
308666
|
await finalizeMdast(session, mdast2, frontmatter2, fileArticles[ind].file, {
|
@@ -308479,8 +308697,7 @@ async function localArticleToTypstTemplated(session, file, templateOptions, opts
|
|
308479
308697
|
frontmatter = content3[0].frontmatter;
|
308480
308698
|
typstContent = results[0].value;
|
308481
308699
|
} else {
|
308482
|
-
|
308483
|
-
frontmatter = (_a6 = selectors_exports.selectLocalProjectConfig(state, projectPath !== null && projectPath !== void 0 ? projectPath : ".")) !== null && _a6 !== void 0 ? _a6 : {};
|
308700
|
+
frontmatter = projectFrontmatter;
|
308484
308701
|
const { dir, name: name3, ext: ext2 } = import_node_path46.default.parse(output2);
|
308485
308702
|
typstContent = "";
|
308486
308703
|
let fileInd = 0;
|
@@ -308709,7 +308926,7 @@ var paragraph2 = (state, node3) => {
|
|
308709
308926
|
state.closeBlock();
|
308710
308927
|
};
|
308711
308928
|
var block3 = (state, node3) => {
|
308712
|
-
if (node3.visibility === "remove")
|
308929
|
+
if (node3.visibility === "remove" || node3.visibility === "hide")
|
308713
308930
|
return;
|
308714
308931
|
const metadataTags = getMetadataTags(node3);
|
308715
308932
|
if (metadataTags.includes("page-break") || metadataTags.includes("new-page")) {
|
@@ -311117,7 +311334,7 @@ var handlers5 = {
|
|
311117
311334
|
state.renderInline(node3, "title");
|
311118
311335
|
},
|
311119
311336
|
block(node3, state) {
|
311120
|
-
if (node3.visibility === "remove")
|
311337
|
+
if (node3.visibility === "remove" || node3.visibility === "hide")
|
311121
311338
|
return;
|
311122
311339
|
state.renderChildren(node3);
|
311123
311340
|
},
|
@@ -316326,7 +316543,7 @@ var CODE_BLOCK_KEYS = [
|
|
316326
316543
|
"caption"
|
316327
316544
|
];
|
316328
316545
|
function code6(node3, _3, state, info) {
|
316329
|
-
const nodeCodeBlockKeys = Object.
|
316546
|
+
const nodeCodeBlockKeys = Object.entries(node3).filter(([k, v]) => CODE_BLOCK_KEYS.includes(k) && v != null);
|
316330
316547
|
if (!nodeCodeBlockKeys.length) {
|
316331
316548
|
return handle5.code(node3, _3, state, info);
|
316332
316549
|
}
|
@@ -316348,6 +316565,10 @@ function code6(node3, _3, state, info) {
|
|
316348
316565
|
var IMAGE_DIRECTIVE_OPTS = ["class", "width", "align"];
|
316349
316566
|
var IMAGE_OPTS = IMAGE_DIRECTIVE_OPTS.concat("title", "alt");
|
316350
316567
|
function image5(node3, _3, state, info) {
|
316568
|
+
var _a6;
|
316569
|
+
if ((_a6 = node3 === null || node3 === void 0 ? void 0 : node3.data) === null || _a6 === void 0 ? void 0 : _a6.altTextIsAutoGenerated) {
|
316570
|
+
delete node3.alt;
|
316571
|
+
}
|
316351
316572
|
const nodeImageDirectiveKeys = Object.keys(node3).filter((k) => IMAGE_DIRECTIVE_OPTS.includes(k));
|
316352
316573
|
if (!nodeImageDirectiveKeys.length)
|
316353
316574
|
return handle5.image(node3, void 0, state, info);
|
@@ -316403,15 +316624,18 @@ function containerValidator(node3, file) {
|
|
316403
316624
|
var FIGURE_OPTS = ["label", "class", "width", "align", "title", "alt", "placeholder"];
|
316404
316625
|
var TABLE_KEYS = ["headerRows", "label", "class", "width", "align"];
|
316405
316626
|
function container3(node3, _3, state, info) {
|
316406
|
-
var _a6, _b, _c;
|
316627
|
+
var _a6, _b, _c, _d2;
|
316407
316628
|
const captionNode = select("caption", node3);
|
316408
316629
|
const legendNode = select("legend", node3);
|
316409
316630
|
const children = [...(captionNode === null || captionNode === void 0 ? void 0 : captionNode.children) || [], ...(legendNode === null || legendNode === void 0 ? void 0 : legendNode.children) || []];
|
316410
316631
|
if (node3.kind === "figure") {
|
316411
316632
|
const imageNodes = selectAll("image", node3);
|
316412
316633
|
const imageNode = imageNodes.find((img2) => !img2.placeholder);
|
316634
|
+
if ((_a6 = imageNode === null || imageNode === void 0 ? void 0 : imageNode.data) === null || _a6 === void 0 ? void 0 : _a6.altTextIsAutoGenerated) {
|
316635
|
+
delete imageNode.alt;
|
316636
|
+
}
|
316413
316637
|
const placeholderNode = imageNodes.find((img2) => img2.placeholder);
|
316414
|
-
const url = (
|
316638
|
+
const url = (_c = (_b = imageNode === null || imageNode === void 0 ? void 0 : imageNode.urlSource) !== null && _b !== void 0 ? _b : imageNode === null || imageNode === void 0 ? void 0 : imageNode.url) !== null && _c !== void 0 ? _c : `#${node3.source.label}`;
|
316415
316639
|
if (!url)
|
316416
316640
|
return "";
|
316417
316641
|
const combinedNode = { type: "container", url, children };
|
@@ -316422,7 +316646,7 @@ function container3(node3, _3, state, info) {
|
|
316422
316646
|
combinedNode[key2] = val;
|
316423
316647
|
});
|
316424
316648
|
if (placeholderNode) {
|
316425
|
-
combinedNode["placeholder"] = (
|
316649
|
+
combinedNode["placeholder"] = (_d2 = placeholderNode.urlSource) !== null && _d2 !== void 0 ? _d2 : placeholderNode.url;
|
316426
316650
|
}
|
316427
316651
|
const options = {
|
316428
316652
|
argsKey: "url",
|
@@ -316567,12 +316791,32 @@ function tabItem2(node3, _3, state, info) {
|
|
316567
316791
|
const handler = writeFlowDirective("tab-item", node3.title, { keys: ["sync", "selected"] });
|
316568
316792
|
return handler(node3, _3, state, info);
|
316569
316793
|
}
|
316794
|
+
function iframe3(node3, _3, state, info) {
|
316795
|
+
const handler = writeStaticDirective("iframe", { argsKey: "src", keys: IMAGE_DIRECTIVE_OPTS });
|
316796
|
+
return handler(node3, _3, state, info);
|
316797
|
+
}
|
316798
|
+
function aside(node3, _3, state, info) {
|
316799
|
+
var _a6;
|
316800
|
+
const name3 = (_a6 = node3.kind) !== null && _a6 !== void 0 ? _a6 : "aside";
|
316801
|
+
const admonitionTitle3 = select("admonitionTitle", node3);
|
316802
|
+
const args = admonitionTitle3 ? state.containerPhrasing(admonitionTitle3, info) : "";
|
316803
|
+
const nodeCopy = {
|
316804
|
+
...node3,
|
316805
|
+
children: node3.children.filter((n) => n.type !== "admonitionTitle")
|
316806
|
+
};
|
316807
|
+
const options = {
|
316808
|
+
keys: ["class"]
|
316809
|
+
};
|
316810
|
+
return writeFlowDirective(name3, args, options)(nodeCopy, _3, state, info);
|
316811
|
+
}
|
316570
316812
|
var directiveHandlers2 = {
|
316571
316813
|
code: code6,
|
316572
316814
|
image: image5,
|
316573
316815
|
container: container3,
|
316574
316816
|
admonition: admonition4,
|
316575
316817
|
details: details2,
|
316818
|
+
iframe: iframe3,
|
316819
|
+
aside,
|
316576
316820
|
card,
|
316577
316821
|
grid: writeFlowDirective("grid", void 0, {
|
316578
316822
|
keys: ["columns"],
|
@@ -316599,7 +316843,7 @@ function comment6(node3, _3, state) {
|
|
316599
316843
|
});
|
316600
316844
|
}
|
316601
316845
|
function block4(node3, _3, state, info) {
|
316602
|
-
if (node3.visibility === "remove")
|
316846
|
+
if (node3.visibility === "remove" || node3.visibility === "hide")
|
316603
316847
|
return "";
|
316604
316848
|
const meta2 = node3.meta ? ` ${node3.meta}` : "";
|
316605
316849
|
const content3 = state.containerFlow(node3, info);
|
@@ -316653,7 +316897,7 @@ function labelWrapper(handler) {
|
|
316653
316897
|
const ident = (_a6 = node3.identifier) !== null && _a6 !== void 0 ? _a6 : node3.label;
|
316654
316898
|
const prefix2 = ident ? `(${ident})=
|
316655
316899
|
` : "";
|
316656
|
-
return `${prefix2}${handler(node3, _3, state, info)}`;
|
316900
|
+
return `${node3.implicit ? "" : prefix2}${handler(node3, _3, state, info)}`;
|
316657
316901
|
};
|
316658
316902
|
}
|
316659
316903
|
function crossReference3(node3, _3, state, info) {
|
@@ -332377,14 +332621,8 @@ var Session = class {
|
|
332377
332621
|
token: process.env.JUPYTER_TOKEN
|
332378
332622
|
};
|
332379
332623
|
} else {
|
332380
|
-
|
332381
|
-
|
332382
|
-
this.log.debug(`Found existing server on: ${existing.appUrl}`);
|
332383
|
-
partialServerSettings = existing;
|
332384
|
-
} else {
|
332385
|
-
this.log.debug(`Launching jupyter server on ${this.sourcePath()}`);
|
332386
|
-
partialServerSettings = await launchJupyterServer(this.sourcePath(), this.log);
|
332387
|
-
}
|
332624
|
+
this.log.debug(`Launching jupyter server on ${this.sourcePath()}`);
|
332625
|
+
partialServerSettings = await launchJupyterServer(this.sourcePath(), this.log);
|
332388
332626
|
}
|
332389
332627
|
const serverSettings = import_services.ServerConnection.makeSettings(partialServerSettings);
|
332390
332628
|
const kernelManager = new import_services.KernelManager({ serverSettings });
|