@nowline/embed 0.0.0-dev.20261004032054.g2cf911c → 0.0.0-dev.20261004034025.gb82abb3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/meta.json +26 -8
- package/dist/nowline.esm.js +61 -11
- package/dist/nowline.esm.js.map +3 -3
- package/dist/nowline.min.js +66 -66
- package/dist/nowline.min.js.map +4 -4
- package/package.json +6 -6
package/dist/meta.json
CHANGED
|
@@ -8613,6 +8613,11 @@
|
|
|
8613
8613
|
],
|
|
8614
8614
|
"format": "esm"
|
|
8615
8615
|
},
|
|
8616
|
+
"../layout/dist/nodes/content-extent.js": {
|
|
8617
|
+
"bytes": 1830,
|
|
8618
|
+
"imports": [],
|
|
8619
|
+
"format": "esm"
|
|
8620
|
+
},
|
|
8616
8621
|
"../layout/dist/nodes/footnote-node.js": {
|
|
8617
8622
|
"bytes": 1658,
|
|
8618
8623
|
"imports": [
|
|
@@ -8707,7 +8712,7 @@
|
|
|
8707
8712
|
"format": "esm"
|
|
8708
8713
|
},
|
|
8709
8714
|
"../layout/dist/nodes/include-node.js": {
|
|
8710
|
-
"bytes":
|
|
8715
|
+
"bytes": 5600,
|
|
8711
8716
|
"imports": [
|
|
8712
8717
|
{
|
|
8713
8718
|
"path": "../layout/dist/calendar.js",
|
|
@@ -8724,6 +8729,11 @@
|
|
|
8724
8729
|
"kind": "import-statement",
|
|
8725
8730
|
"original": "../style-resolution.js"
|
|
8726
8731
|
},
|
|
8732
|
+
{
|
|
8733
|
+
"path": "../layout/dist/nodes/content-extent.js",
|
|
8734
|
+
"kind": "import-statement",
|
|
8735
|
+
"original": "./content-extent.js"
|
|
8736
|
+
},
|
|
8727
8737
|
{
|
|
8728
8738
|
"path": "../layout/dist/nodes/swimlane-node.js",
|
|
8729
8739
|
"kind": "import-statement",
|
|
@@ -8759,7 +8769,7 @@
|
|
|
8759
8769
|
"format": "esm"
|
|
8760
8770
|
},
|
|
8761
8771
|
"../layout/dist/nodes/roadmap-node.js": {
|
|
8762
|
-
"bytes":
|
|
8772
|
+
"bytes": 41491,
|
|
8763
8773
|
"imports": [
|
|
8764
8774
|
{
|
|
8765
8775
|
"path": "../layout/dist/band-scale.js",
|
|
@@ -8816,6 +8826,11 @@
|
|
|
8816
8826
|
"kind": "import-statement",
|
|
8817
8827
|
"original": "./anchor-node.js"
|
|
8818
8828
|
},
|
|
8829
|
+
{
|
|
8830
|
+
"path": "../layout/dist/nodes/content-extent.js",
|
|
8831
|
+
"kind": "import-statement",
|
|
8832
|
+
"original": "./content-extent.js"
|
|
8833
|
+
},
|
|
8819
8834
|
{
|
|
8820
8835
|
"path": "../layout/dist/nodes/footnote-node.js",
|
|
8821
8836
|
"kind": "import-statement",
|
|
@@ -8845,7 +8860,7 @@
|
|
|
8845
8860
|
"format": "esm"
|
|
8846
8861
|
},
|
|
8847
8862
|
"../layout/dist/layout.js": {
|
|
8848
|
-
"bytes":
|
|
8863
|
+
"bytes": 62016,
|
|
8849
8864
|
"imports": [
|
|
8850
8865
|
{
|
|
8851
8866
|
"path": "../core/dist/index.js",
|
|
@@ -9337,7 +9352,7 @@
|
|
|
9337
9352
|
"imports": [],
|
|
9338
9353
|
"exports": [],
|
|
9339
9354
|
"inputs": {},
|
|
9340
|
-
"bytes":
|
|
9355
|
+
"bytes": 3418513
|
|
9341
9356
|
},
|
|
9342
9357
|
"dist/nowline.min.js": {
|
|
9343
9358
|
"imports": [],
|
|
@@ -10508,6 +10523,9 @@
|
|
|
10508
10523
|
"../layout/dist/nodes/anchor-node.js": {
|
|
10509
10524
|
"bytesInOutput": 833
|
|
10510
10525
|
},
|
|
10526
|
+
"../layout/dist/nodes/content-extent.js": {
|
|
10527
|
+
"bytesInOutput": 250
|
|
10528
|
+
},
|
|
10511
10529
|
"../layout/dist/nodes/footnote-node.js": {
|
|
10512
10530
|
"bytesInOutput": 412
|
|
10513
10531
|
},
|
|
@@ -10518,16 +10536,16 @@
|
|
|
10518
10536
|
"bytesInOutput": 2883
|
|
10519
10537
|
},
|
|
10520
10538
|
"../layout/dist/nodes/include-node.js": {
|
|
10521
|
-
"bytesInOutput":
|
|
10539
|
+
"bytesInOutput": 1441
|
|
10522
10540
|
},
|
|
10523
10541
|
"../layout/dist/nodes/milestone-node.js": {
|
|
10524
10542
|
"bytesInOutput": 2015
|
|
10525
10543
|
},
|
|
10526
10544
|
"../layout/dist/nodes/roadmap-node.js": {
|
|
10527
|
-
"bytesInOutput":
|
|
10545
|
+
"bytesInOutput": 8775
|
|
10528
10546
|
},
|
|
10529
10547
|
"../layout/dist/layout.js": {
|
|
10530
|
-
"bytesInOutput":
|
|
10548
|
+
"bytesInOutput": 12618
|
|
10531
10549
|
},
|
|
10532
10550
|
"../layout/dist/layout-insights.js": {
|
|
10533
10551
|
"bytesInOutput": 1202
|
|
@@ -10587,7 +10605,7 @@
|
|
|
10587
10605
|
"bytesInOutput": 257
|
|
10588
10606
|
}
|
|
10589
10607
|
},
|
|
10590
|
-
"bytes":
|
|
10608
|
+
"bytes": 670665
|
|
10591
10609
|
}
|
|
10592
10610
|
}
|
|
10593
10611
|
}
|
package/dist/nowline.esm.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! @nowline/embed 0.0.0-dev.
|
|
1
|
+
/*! @nowline/embed 0.0.0-dev.20261004034025.gb82abb3 sha=b82abb3 built=2026-10-03T23:38:27-04:00 */
|
|
2
2
|
var __create = Object.create;
|
|
3
3
|
var __defProp = Object.defineProperty;
|
|
4
4
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
@@ -35143,6 +35143,29 @@ function buildAnchors(anchors, ctx, milestoneXs) {
|
|
|
35143
35143
|
return out;
|
|
35144
35144
|
}
|
|
35145
35145
|
|
|
35146
|
+
// ../layout/dist/nodes/content-extent.js
|
|
35147
|
+
function maxLeafItemRightX(swimlanes) {
|
|
35148
|
+
let max = 0;
|
|
35149
|
+
for (const lane of swimlanes) {
|
|
35150
|
+
max = Math.max(max, maxTrackChildRightX(lane.children));
|
|
35151
|
+
if (lane.nested.length > 0) {
|
|
35152
|
+
max = Math.max(max, maxLeafItemRightX(lane.nested));
|
|
35153
|
+
}
|
|
35154
|
+
}
|
|
35155
|
+
return max;
|
|
35156
|
+
}
|
|
35157
|
+
function maxTrackChildRightX(children) {
|
|
35158
|
+
let max = 0;
|
|
35159
|
+
for (const child of children) {
|
|
35160
|
+
if (child.kind === "item") {
|
|
35161
|
+
max = Math.max(max, child.box.x + child.box.width);
|
|
35162
|
+
} else {
|
|
35163
|
+
max = Math.max(max, maxTrackChildRightX(child.children));
|
|
35164
|
+
}
|
|
35165
|
+
}
|
|
35166
|
+
return max;
|
|
35167
|
+
}
|
|
35168
|
+
|
|
35146
35169
|
// ../layout/dist/nodes/footnote-node.js
|
|
35147
35170
|
function buildFootnotes(footnotes, ctx, chartBottomY) {
|
|
35148
35171
|
const entries = [];
|
|
@@ -35538,22 +35561,20 @@ function buildIncludeRegions(regions, ctx, startY, deps) {
|
|
|
35538
35561
|
const nestedSwimlanes = [];
|
|
35539
35562
|
let cursorY = innerStartY;
|
|
35540
35563
|
let bandIndex = 0;
|
|
35541
|
-
let nestedContentRightX = childCtx.timeline.originX;
|
|
35542
35564
|
for (const lane of region.content.swimlanes.values()) {
|
|
35543
35565
|
childCtx.nextParallelId = 0;
|
|
35544
35566
|
childCtx.nextGroupId = 0;
|
|
35545
|
-
const { positioned, usedHeight
|
|
35567
|
+
const { positioned, usedHeight } = new SwimlaneNode({ lane, bandIndex }, deps).place({ x: childCtx.timeline.originX, y: cursorY }, childCtx);
|
|
35546
35568
|
nestedSwimlanes.push(positioned);
|
|
35547
35569
|
cursorY += usedHeight;
|
|
35548
35570
|
bandIndex++;
|
|
35549
|
-
if (usedRightX > nestedContentRightX)
|
|
35550
|
-
nestedContentRightX = usedRightX;
|
|
35551
35571
|
}
|
|
35552
35572
|
const innerEndY = cursorY;
|
|
35553
35573
|
const regionHeight = Math.max(ctx.bandScale.bandwidth(), innerEndY - y + REGION_INSET_BOTTOM);
|
|
35554
35574
|
const boxX = 0;
|
|
35555
35575
|
const { chromeRightX } = includeChromeGeometry(boxX, label, region.sourcePath);
|
|
35556
|
-
const
|
|
35576
|
+
const barsRightX = maxLeafItemRightX(nestedSwimlanes);
|
|
35577
|
+
const naturalRightX = Math.max(chromeRightX, barsRightX) + INCLUDE_CONTENT_RIGHT_PAD_PX;
|
|
35557
35578
|
const boxWidth = Math.min(ctx.chartRightX - boxX, naturalRightX - boxX);
|
|
35558
35579
|
const box = {
|
|
35559
35580
|
x: boxX,
|
|
@@ -35963,6 +35984,33 @@ var RoadmapNode = class {
|
|
|
35963
35984
|
ctx.swimlaneBottomY = y;
|
|
35964
35985
|
timeline.box.height = ctx.chartBottomY - timeline.box.y;
|
|
35965
35986
|
const milestones = buildMilestones(resolved.content.milestones, ctx);
|
|
35987
|
+
let maxContentRightX = maxLeafItemRightX(swimlanes);
|
|
35988
|
+
for (const inc of includes) {
|
|
35989
|
+
maxContentRightX = Math.max(maxContentRightX, maxLeafItemRightX(inc.nestedSwimlanes));
|
|
35990
|
+
}
|
|
35991
|
+
for (const e of datePinnedEntries) {
|
|
35992
|
+
maxContentRightX = Math.max(maxContentRightX, e.centerX + e.radius);
|
|
35993
|
+
}
|
|
35994
|
+
for (const m of milestones) {
|
|
35995
|
+
maxContentRightX = Math.max(maxContentRightX, m.center.x + m.radius);
|
|
35996
|
+
}
|
|
35997
|
+
const tickDays = calendar2.daysPerUnit(scale.unit);
|
|
35998
|
+
const overflowDays = (maxContentRightX - originX) / ppd;
|
|
35999
|
+
const paddedDays = overflowDays > 0 ? Math.ceil(overflowDays / tickDays) * tickDays : 0;
|
|
36000
|
+
if (paddedDays > spanDays) {
|
|
36001
|
+
const extendedEndDate = addDays(startDate, paddedDays);
|
|
36002
|
+
const extendedWidth = paddedDays * ppd;
|
|
36003
|
+
const extendedScale = new TimeScale({
|
|
36004
|
+
domain: [startDate, extendedEndDate],
|
|
36005
|
+
range: [originX, originX + extendedWidth],
|
|
36006
|
+
calendar: calendar2
|
|
36007
|
+
});
|
|
36008
|
+
ctx.scale = extendedScale;
|
|
36009
|
+
timeline.endDate = extendedEndDate;
|
|
36010
|
+
timeline.box.width = extendedWidth;
|
|
36011
|
+
timeline.ticks = buildHeaderTicks(extendedScale, scale, calendar2, locale2);
|
|
36012
|
+
growChartRightX(ctx, originX + extendedWidth + GUTTER_PX);
|
|
36013
|
+
}
|
|
35966
36014
|
const allMarkerEntries = datePinnedEntries.map((e) => ({
|
|
35967
36015
|
id: e.id,
|
|
35968
36016
|
centerX: e.centerX,
|
|
@@ -36805,16 +36853,18 @@ function computeDateWindow(file, ctx, resolved, today, scale) {
|
|
|
36805
36853
|
const startRaw = propValue(props, "start");
|
|
36806
36854
|
const startDate = parseDate(startRaw) ?? defaultStartDate(today);
|
|
36807
36855
|
const lengthRaw = propValue(props, "length");
|
|
36856
|
+
let minDays = 0;
|
|
36808
36857
|
if (lengthRaw) {
|
|
36809
36858
|
const days = literalDays(lengthRaw, ctx.cal);
|
|
36810
36859
|
if (days > 0) {
|
|
36811
|
-
|
|
36860
|
+
minDays = days;
|
|
36812
36861
|
}
|
|
36813
36862
|
}
|
|
36814
|
-
const contentDays = computeContentEndDay(resolved, ctx, startDate, today);
|
|
36863
|
+
const contentDays = computeContentEndDay(resolved, ctx, startDate, minDays > 0 ? void 0 : today);
|
|
36815
36864
|
const tickDays = daysPerUnit(scale.unit, ctx.cal);
|
|
36816
36865
|
const padded = contentDays > 0 ? Math.ceil(contentDays / tickDays) * tickDays : 4 * ctx.cal.daysPerWeek;
|
|
36817
|
-
|
|
36866
|
+
const finalDays = Math.max(minDays, padded);
|
|
36867
|
+
return { startDate, endDate: addDays(startDate, Math.max(1, finalDays)) };
|
|
36818
36868
|
}
|
|
36819
36869
|
function defaultStartDate(today) {
|
|
36820
36870
|
const ref = today ?? /* @__PURE__ */ new Date();
|
|
@@ -39961,8 +40011,8 @@ function effectiveTheme(theme, systemTheme) {
|
|
|
39961
40011
|
}
|
|
39962
40012
|
|
|
39963
40013
|
// src/index.ts
|
|
39964
|
-
var version = true ? "0.0.0-dev.
|
|
39965
|
-
var sha = true ? "
|
|
40014
|
+
var version = true ? "0.0.0-dev.20261004034025.gb82abb3" : "0.0.0";
|
|
40015
|
+
var sha = true ? "b82abb3" : "unknown";
|
|
39966
40016
|
var DEFAULT_SELECTOR = "pre code.language-nowline, code.language-nowline";
|
|
39967
40017
|
var initialConfig = {
|
|
39968
40018
|
theme: "auto",
|