@nowline/embed 0.0.0-dev.20261020002921.g70f418b → 0.0.0-dev.20261020011950.gce8a91f
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 +21 -11
- package/dist/nowline.esm.js +52 -27
- package/dist/nowline.esm.js.map +2 -2
- package/dist/nowline.min.js +54 -54
- package/dist/nowline.min.js.map +3 -3
- package/package.json +6 -6
package/dist/meta.json
CHANGED
|
@@ -5035,7 +5035,7 @@
|
|
|
5035
5035
|
"format": "esm"
|
|
5036
5036
|
},
|
|
5037
5037
|
"../layout/dist/frame-tab-geometry.js": {
|
|
5038
|
-
"bytes":
|
|
5038
|
+
"bytes": 5765,
|
|
5039
5039
|
"imports": [],
|
|
5040
5040
|
"format": "esm"
|
|
5041
5041
|
},
|
|
@@ -6291,8 +6291,13 @@
|
|
|
6291
6291
|
"format": "esm"
|
|
6292
6292
|
},
|
|
6293
6293
|
"../layout/dist/layout-context.js": {
|
|
6294
|
-
"bytes":
|
|
6294
|
+
"bytes": 4220,
|
|
6295
6295
|
"imports": [
|
|
6296
|
+
{
|
|
6297
|
+
"path": "../core/dist/index.js",
|
|
6298
|
+
"kind": "import-statement",
|
|
6299
|
+
"original": "@nowline/core"
|
|
6300
|
+
},
|
|
6296
6301
|
{
|
|
6297
6302
|
"path": "../layout/dist/calendar.js",
|
|
6298
6303
|
"kind": "import-statement",
|
|
@@ -6698,7 +6703,7 @@
|
|
|
6698
6703
|
"format": "esm"
|
|
6699
6704
|
},
|
|
6700
6705
|
"../layout/dist/nodes/swimlane-node.js": {
|
|
6701
|
-
"bytes":
|
|
6706
|
+
"bytes": 10428,
|
|
6702
6707
|
"imports": [
|
|
6703
6708
|
{
|
|
6704
6709
|
"path": "../layout/dist/capacity.js",
|
|
@@ -9899,7 +9904,7 @@
|
|
|
9899
9904
|
"format": "esm"
|
|
9900
9905
|
},
|
|
9901
9906
|
"../layout/dist/index.js": {
|
|
9902
|
-
"bytes":
|
|
9907
|
+
"bytes": 5102,
|
|
9903
9908
|
"imports": [
|
|
9904
9909
|
{
|
|
9905
9910
|
"path": "../layout/dist/calendar-resolver.js",
|
|
@@ -10262,13 +10267,18 @@
|
|
|
10262
10267
|
"format": "esm"
|
|
10263
10268
|
},
|
|
10264
10269
|
"../renderer/dist/svg/swimlanes.js": {
|
|
10265
|
-
"bytes":
|
|
10270
|
+
"bytes": 10947,
|
|
10266
10271
|
"imports": [
|
|
10267
10272
|
{
|
|
10268
10273
|
"path": "../layout/dist/index.js",
|
|
10269
10274
|
"kind": "import-statement",
|
|
10270
10275
|
"original": "@nowline/layout"
|
|
10271
10276
|
},
|
|
10277
|
+
{
|
|
10278
|
+
"path": "../renderer/dist/svg/icons.js",
|
|
10279
|
+
"kind": "import-statement",
|
|
10280
|
+
"original": "./icons.js"
|
|
10281
|
+
},
|
|
10272
10282
|
{
|
|
10273
10283
|
"path": "../renderer/dist/svg/item.js",
|
|
10274
10284
|
"kind": "import-statement",
|
|
@@ -10636,7 +10646,7 @@
|
|
|
10636
10646
|
"imports": [],
|
|
10637
10647
|
"exports": [],
|
|
10638
10648
|
"inputs": {},
|
|
10639
|
-
"bytes":
|
|
10649
|
+
"bytes": 3707043
|
|
10640
10650
|
},
|
|
10641
10651
|
"dist/nowline.min.js": {
|
|
10642
10652
|
"imports": [],
|
|
@@ -11484,7 +11494,7 @@
|
|
|
11484
11494
|
"bytesInOutput": 3272
|
|
11485
11495
|
},
|
|
11486
11496
|
"../layout/dist/frame-tab-geometry.js": {
|
|
11487
|
-
"bytesInOutput":
|
|
11497
|
+
"bytesInOutput": 374
|
|
11488
11498
|
},
|
|
11489
11499
|
"../layout/dist/header-logo.js": {
|
|
11490
11500
|
"bytesInOutput": 450
|
|
@@ -11649,7 +11659,7 @@
|
|
|
11649
11659
|
"bytesInOutput": 100
|
|
11650
11660
|
},
|
|
11651
11661
|
"../layout/dist/layout-context.js": {
|
|
11652
|
-
"bytesInOutput":
|
|
11662
|
+
"bytesInOutput": 1290
|
|
11653
11663
|
},
|
|
11654
11664
|
"../layout/dist/nodes/item-node.js": {
|
|
11655
11665
|
"bytesInOutput": 1704
|
|
@@ -11685,7 +11695,7 @@
|
|
|
11685
11695
|
"bytesInOutput": 1503
|
|
11686
11696
|
},
|
|
11687
11697
|
"../layout/dist/nodes/swimlane-node.js": {
|
|
11688
|
-
"bytesInOutput":
|
|
11698
|
+
"bytesInOutput": 1878
|
|
11689
11699
|
},
|
|
11690
11700
|
"../layout/dist/nodes/include-node.js": {
|
|
11691
11701
|
"bytesInOutput": 1433
|
|
@@ -11817,7 +11827,7 @@
|
|
|
11817
11827
|
"bytesInOutput": 6255
|
|
11818
11828
|
},
|
|
11819
11829
|
"../renderer/dist/svg/swimlanes.js": {
|
|
11820
|
-
"bytesInOutput":
|
|
11830
|
+
"bytesInOutput": 3086
|
|
11821
11831
|
},
|
|
11822
11832
|
"../renderer/dist/svg/timeline.js": {
|
|
11823
11833
|
"bytesInOutput": 2753
|
|
@@ -11856,7 +11866,7 @@
|
|
|
11856
11866
|
"bytesInOutput": 257
|
|
11857
11867
|
}
|
|
11858
11868
|
},
|
|
11859
|
-
"bytes":
|
|
11869
|
+
"bytes": 675243
|
|
11860
11870
|
}
|
|
11861
11871
|
}
|
|
11862
11872
|
}
|
package/dist/nowline.esm.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! @nowline/embed 0.0.0-dev.
|
|
1
|
+
/*! @nowline/embed 0.0.0-dev.20261020011950.gce8a91f sha=ce8a91f built=2026-10-20T01:14:35Z */
|
|
2
2
|
var __create = Object.create;
|
|
3
3
|
var __defProp = Object.defineProperty;
|
|
4
4
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
@@ -23270,6 +23270,8 @@ function routeDependencies(requests, obstacles, pixelsPerDay) {
|
|
|
23270
23270
|
// ../layout/dist/frame-tab-geometry.js
|
|
23271
23271
|
var FRAME_TAB_TITLE_PX_PER_CHAR = 6.5;
|
|
23272
23272
|
var FRAME_TAB_OWNER_PX_PER_CHAR = 5;
|
|
23273
|
+
var FRAME_TAB_OWNER_GLYPH_PX = 10;
|
|
23274
|
+
var FRAME_TAB_OWNER_GLYPH_GAP_PX = 3;
|
|
23273
23275
|
var FRAME_TAB_INNER_GAP_PX = 6;
|
|
23274
23276
|
var FRAME_TAB_LEFT_INSET_PX = 12;
|
|
23275
23277
|
var FRAME_TAB_RIGHT_INSET_PX = 12;
|
|
@@ -23282,9 +23284,11 @@ function frameTabGeometry(boxX, title, owner, capacityBadgeWidth = 0, footnoteIn
|
|
|
23282
23284
|
let cursorX = titleX + titleTextWidth;
|
|
23283
23285
|
let ownerTextWidth = 0;
|
|
23284
23286
|
let ownerX = 0;
|
|
23287
|
+
let ownerTextX = 0;
|
|
23285
23288
|
if (owner) {
|
|
23286
|
-
ownerTextWidth =
|
|
23289
|
+
ownerTextWidth = FRAME_TAB_OWNER_GLYPH_PX + FRAME_TAB_OWNER_GLYPH_GAP_PX + owner.length * FRAME_TAB_OWNER_PX_PER_CHAR;
|
|
23287
23290
|
ownerX = cursorX + FRAME_TAB_INNER_GAP_PX;
|
|
23291
|
+
ownerTextX = ownerX + FRAME_TAB_OWNER_GLYPH_PX + FRAME_TAB_OWNER_GLYPH_GAP_PX;
|
|
23288
23292
|
cursorX = ownerX + ownerTextWidth;
|
|
23289
23293
|
}
|
|
23290
23294
|
let badgeX = 0;
|
|
@@ -23306,6 +23310,7 @@ function frameTabGeometry(boxX, title, owner, capacityBadgeWidth = 0, footnoteIn
|
|
|
23306
23310
|
footnoteIndicatorWidth,
|
|
23307
23311
|
titleX,
|
|
23308
23312
|
ownerX,
|
|
23313
|
+
ownerTextX,
|
|
23309
23314
|
badgeX,
|
|
23310
23315
|
footnoteRightX,
|
|
23311
23316
|
tabX,
|
|
@@ -32764,6 +32769,21 @@ function scheduledItemDays(ctx, item) {
|
|
|
32764
32769
|
}
|
|
32765
32770
|
return scheduled.days;
|
|
32766
32771
|
}
|
|
32772
|
+
function withNestedTeams(teams) {
|
|
32773
|
+
const out = new Map(teams);
|
|
32774
|
+
const visit = (team) => {
|
|
32775
|
+
for (const member of team.content) {
|
|
32776
|
+
if (!isTeamDeclaration(member))
|
|
32777
|
+
continue;
|
|
32778
|
+
if (member.name && !out.has(member.name))
|
|
32779
|
+
out.set(member.name, member);
|
|
32780
|
+
visit(member);
|
|
32781
|
+
}
|
|
32782
|
+
};
|
|
32783
|
+
for (const team of teams.values())
|
|
32784
|
+
visit(team);
|
|
32785
|
+
return out;
|
|
32786
|
+
}
|
|
32767
32787
|
function createLayoutContext(source, shared, chart, init2) {
|
|
32768
32788
|
return {
|
|
32769
32789
|
cal: shared.cal,
|
|
@@ -32779,7 +32799,7 @@ function createLayoutContext(source, shared, chart, init2) {
|
|
|
32779
32799
|
// pixels-per-day scale.
|
|
32780
32800
|
sizes: resolveSizes(source.content.sizes, shared.cal),
|
|
32781
32801
|
labels: source.content.labels,
|
|
32782
|
-
teams: source.content.teams,
|
|
32802
|
+
teams: withNestedTeams(source.content.teams),
|
|
32783
32803
|
persons: source.content.persons,
|
|
32784
32804
|
symbols: source.config.symbols,
|
|
32785
32805
|
footnoteIndex: init2.footnotes?.index ?? /* @__PURE__ */ new Map(),
|
|
@@ -34494,12 +34514,17 @@ function resolveLaneCapacity(lane, style, symbols) {
|
|
|
34494
34514
|
var TAB_TOP_Y = 10;
|
|
34495
34515
|
var TAB_BOTTOM_Y = 38;
|
|
34496
34516
|
var TAB_GUTTER_PX = 8;
|
|
34497
|
-
function
|
|
34498
|
-
const title = lane.title ?? lane.name ?? "";
|
|
34499
|
-
if (!title)
|
|
34500
|
-
return 0;
|
|
34517
|
+
function resolveLaneOwner(lane, ctx) {
|
|
34501
34518
|
const ownerRaw = propValue(lane.properties, "owner");
|
|
34502
|
-
|
|
34519
|
+
if (!ownerRaw)
|
|
34520
|
+
return void 0;
|
|
34521
|
+
const team = ctx.teams.get(ownerRaw);
|
|
34522
|
+
if (team)
|
|
34523
|
+
return { text: team.title ?? ownerRaw, kind: "team" };
|
|
34524
|
+
const person = ctx.persons.get(ownerRaw);
|
|
34525
|
+
if (person)
|
|
34526
|
+
return { text: person.title ?? ownerRaw, kind: "person" };
|
|
34527
|
+
return { text: ownerRaw, kind: "team" };
|
|
34503
34528
|
}
|
|
34504
34529
|
function collectFootnoteIndicators(lane, ctx) {
|
|
34505
34530
|
if (!lane.name)
|
|
@@ -34544,7 +34569,11 @@ var SwimlaneNode = class {
|
|
|
34544
34569
|
const { capacity, badgeWidthPx } = resolveLaneCapacity(lane, style, ctx.symbols);
|
|
34545
34570
|
const footnoteIndicators = collectFootnoteIndicators(lane, ctx);
|
|
34546
34571
|
const footnoteIndicatorWidthPx = footnoteIndicators.length > 0 ? estimateTextWidth(footnoteIndicators.join(","), LANE_CAPACITY_BADGE_FONT_SIZE_PX) : 0;
|
|
34547
|
-
const
|
|
34572
|
+
const boxX = 0;
|
|
34573
|
+
const owner = resolveLaneOwner(lane, ctx);
|
|
34574
|
+
const title = lane.title ?? lane.name ?? "";
|
|
34575
|
+
const tab = title ? frameTabGeometry(boxX, title, owner?.text, badgeWidthPx, footnoteIndicatorWidthPx) : null;
|
|
34576
|
+
const tabRightX = tab?.rightX ?? 0;
|
|
34548
34577
|
const firstChildDesiredX = firstChildStartX(lane, laneLeftX, ctx);
|
|
34549
34578
|
const canAlignFirstRowWithTab = !lane.title || firstChildDesiredX === void 0 || firstChildDesiredX >= tabRightX + TAB_GUTTER_PX;
|
|
34550
34579
|
const startY = origin.y + (canAlignFirstRowWithTab ? TAB_TOP_Y : TAB_BOTTOM_Y);
|
|
@@ -34554,18 +34583,11 @@ var SwimlaneNode = class {
|
|
|
34554
34583
|
const bandHeight = Math.max(step + 32, tabOffset + track.packer.usedHeight() + 16);
|
|
34555
34584
|
const usedRightX = Math.max(track.packer.usedRightX(), tabRightX);
|
|
34556
34585
|
const box = {
|
|
34557
|
-
x:
|
|
34586
|
+
x: boxX,
|
|
34558
34587
|
y: origin.y,
|
|
34559
34588
|
width: 0,
|
|
34560
34589
|
height: bandHeight
|
|
34561
34590
|
};
|
|
34562
|
-
const ownerRaw = propValue(lane.properties, "owner");
|
|
34563
|
-
let ownerDisplay;
|
|
34564
|
-
if (ownerRaw) {
|
|
34565
|
-
const team = ctx.teams.get(ownerRaw);
|
|
34566
|
-
const person = ctx.persons.get(ownerRaw);
|
|
34567
|
-
ownerDisplay = team?.title ?? person?.title ?? ownerRaw;
|
|
34568
|
-
}
|
|
34569
34591
|
const utilization = capacity ? (() => {
|
|
34570
34592
|
const { warn, over } = resolveLaneUtilizationThresholds(lane, ctx.styleCtx.defaults);
|
|
34571
34593
|
return computeLaneUtilization({
|
|
@@ -34579,17 +34601,17 @@ var SwimlaneNode = class {
|
|
|
34579
34601
|
return {
|
|
34580
34602
|
positioned: {
|
|
34581
34603
|
id: lane.name,
|
|
34582
|
-
title
|
|
34604
|
+
title,
|
|
34583
34605
|
box,
|
|
34584
34606
|
bandIndex,
|
|
34585
34607
|
children,
|
|
34586
34608
|
nested: [],
|
|
34587
34609
|
style,
|
|
34588
|
-
owner:
|
|
34610
|
+
owner: owner?.text,
|
|
34611
|
+
ownerKind: owner?.kind,
|
|
34589
34612
|
footnoteIndicators,
|
|
34590
34613
|
capacity,
|
|
34591
|
-
|
|
34592
|
-
footnoteIndicatorWidth: footnoteIndicatorWidthPx,
|
|
34614
|
+
tab,
|
|
34593
34615
|
utilization
|
|
34594
34616
|
},
|
|
34595
34617
|
usedHeight: bandHeight,
|
|
@@ -39492,10 +39514,10 @@ function renderSwimlane(s, options, idPrefix, palette, fonts) {
|
|
|
39492
39514
|
const ownerText3 = palette.swimlane.ownerText;
|
|
39493
39515
|
const footnoteColor = palette.swimlane.footnoteIndicator;
|
|
39494
39516
|
const parts = [];
|
|
39495
|
-
|
|
39517
|
+
const tab = s.tab;
|
|
39518
|
+
if (tab) {
|
|
39496
39519
|
const LANE_BADGE_FONT_SIZE_PX = 10;
|
|
39497
39520
|
const footnoteIndicatorText = s.footnoteIndicators.length > 0 ? s.footnoteIndicators.join(",") : "";
|
|
39498
|
-
const tab = frameTabGeometry(s.box.x, s.title, s.owner, s.capacityBadgeWidth, s.footnoteIndicatorWidth);
|
|
39499
39521
|
const tabH = FRAME_TAB_HEIGHT_PX;
|
|
39500
39522
|
const tabY = s.box.y + 10;
|
|
39501
39523
|
const labelY = tabY + FRAME_TAB_LABEL_BASELINE_OFFSET_PX;
|
|
@@ -39519,13 +39541,16 @@ function renderSwimlane(s, options, idPrefix, palette, fonts) {
|
|
|
39519
39541
|
fill: tabText
|
|
39520
39542
|
}, s.title));
|
|
39521
39543
|
if (s.owner) {
|
|
39544
|
+
const glyph = CAPACITY_ICON_SVG[s.ownerKind === "person" ? "person" : "people"];
|
|
39545
|
+
const glyphSize = FRAME_TAB_OWNER_GLYPH_PX;
|
|
39546
|
+
parts.push(`<svg x="${num(tab.ownerX)}" y="${num(labelY - glyphSize * 0.85)}" width="${num(glyphSize)}" height="${num(glyphSize)}" viewBox="${glyph.viewBox}" style="color:${escAttr(ownerText3)}" aria-hidden="true">${glyph.body}</svg>`);
|
|
39522
39547
|
parts.push(textTag({
|
|
39523
|
-
x: num(tab.
|
|
39548
|
+
x: num(tab.ownerTextX),
|
|
39524
39549
|
y: num(labelY),
|
|
39525
39550
|
"font-family": fonts[s.style.font],
|
|
39526
39551
|
"font-size": 10,
|
|
39527
39552
|
fill: ownerText3
|
|
39528
|
-
},
|
|
39553
|
+
}, s.owner));
|
|
39529
39554
|
}
|
|
39530
39555
|
if (s.capacity) {
|
|
39531
39556
|
parts.push(renderCapacitySuffix(s.capacity, tab.badgeX, labelY, LANE_BADGE_FONT_SIZE_PX, fonts[s.style.font], ownerText3));
|
|
@@ -40874,8 +40899,8 @@ function effectiveTheme(theme, systemTheme) {
|
|
|
40874
40899
|
}
|
|
40875
40900
|
|
|
40876
40901
|
// src/index.ts
|
|
40877
|
-
var version = true ? "0.0.0-dev.
|
|
40878
|
-
var sha = true ? "
|
|
40902
|
+
var version = true ? "0.0.0-dev.20261020011950.gce8a91f" : "0.0.0";
|
|
40903
|
+
var sha = true ? "ce8a91f" : "unknown";
|
|
40879
40904
|
var DEFAULT_SELECTOR = "pre code.language-nowline, code.language-nowline";
|
|
40880
40905
|
var initialConfig = {
|
|
40881
40906
|
theme: "auto",
|