@davmash/bygone 0.10.1 → 0.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +19 -0
- package/README.md +32 -0
- package/bin/bygone.js +8 -1
- package/cli/commandSpec.js +11 -2
- package/cli/completions.js +9 -8
- package/cli/correspondence.js +71 -0
- package/cli/present.js +61 -16
- package/cli/tour.js +8 -1
- package/cli/tourExport.js +1 -1
- package/completions/_bygone +5 -3
- package/completions/bygone +5 -5
- package/completions/bygone.fish +2 -0
- package/docs/change-tour-format.md +60 -6
- package/docs/correspondence.md +259 -0
- package/docs/generating-change-tours.md +3 -0
- package/docs/present.md +3 -0
- package/docs/releasing.md +11 -0
- package/media/diff.worker.js +10 -9
- package/media/webview.css +1 -1
- package/out/changeCorrespondence.js +739 -0
- package/out/changeTour.js +1359 -960
- package/out/gitComparison.js +4 -0
- package/out/standalone-main.js +3268 -1337
- package/out/tourCoverage.js +1852 -1448
- package/package.json +2 -2
- package/schemas/change-tour-source.schema.json +48 -3
- package/web/export-runtime.json +5 -5
- package/web/index.html +12 -0
- package/web/presenter.css +81 -0
- package/web/web-host.js +23 -20
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@davmash/bygone",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.11.0",
|
|
4
4
|
"description": "See how change happened. Visual diff and file history.",
|
|
5
5
|
"author": "David Mashburn",
|
|
6
6
|
"license": "MIT",
|
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
"electron"
|
|
41
41
|
],
|
|
42
42
|
"dependencies": {
|
|
43
|
-
"electron": "^43.
|
|
43
|
+
"electron": "^43.8.3",
|
|
44
44
|
"electron-updater": "^6.8.9",
|
|
45
45
|
"js-yaml": "^4.3.0"
|
|
46
46
|
}
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
"additionalProperties": false,
|
|
8
8
|
"required": ["version", "anchors", "connections", "chapters"],
|
|
9
9
|
"properties": {
|
|
10
|
-
"version": { "enum": [1, 2, 4, 5] },
|
|
10
|
+
"version": { "enum": [1, 2, 4, 5, 6] },
|
|
11
11
|
"opening": { "$ref": "#/$defs/passage" },
|
|
12
12
|
"conclusion": { "$ref": "#/$defs/passage" },
|
|
13
13
|
"title": { "$ref": "#/$defs/nonEmptyString" },
|
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
"$ref": "#/$defs/nonEmptyString",
|
|
16
16
|
"description": "Optional native window title for the tour presenter. Use a short label such as a pull request number when multiple tours may be open."
|
|
17
17
|
},
|
|
18
|
+
"correspondence": { "$ref": "#/$defs/nonEmptyString", "description": "Repository-relative validated correspondence artifact; requires version 6." },
|
|
18
19
|
"sourceUrl": { "type": "string", "minLength": 1 },
|
|
19
20
|
"details": { "$ref": "#/$defs/details" },
|
|
20
21
|
"range": {
|
|
@@ -72,7 +73,7 @@
|
|
|
72
73
|
},
|
|
73
74
|
"allOf": [
|
|
74
75
|
{
|
|
75
|
-
"if": { "properties": { "version": { "
|
|
76
|
+
"if": { "properties": { "version": { "enum": [5, 6] } } },
|
|
76
77
|
"then": {
|
|
77
78
|
"properties": {
|
|
78
79
|
"chapters": { "$ref": "#/$defs/purposeChapters" },
|
|
@@ -127,7 +128,7 @@
|
|
|
127
128
|
}
|
|
128
129
|
},
|
|
129
130
|
{
|
|
130
|
-
"if": { "properties": { "version": { "enum": [2, 4, 5] } }, "required": ["version"] },
|
|
131
|
+
"if": { "properties": { "version": { "enum": [2, 4, 5, 6] } }, "required": ["version"] },
|
|
131
132
|
"then": {
|
|
132
133
|
"properties": {
|
|
133
134
|
"chapters": {
|
|
@@ -144,9 +145,47 @@
|
|
|
144
145
|
}
|
|
145
146
|
}
|
|
146
147
|
}
|
|
148
|
+
},
|
|
149
|
+
{
|
|
150
|
+
"if": {
|
|
151
|
+
"properties": {
|
|
152
|
+
"version": {
|
|
153
|
+
"enum": [
|
|
154
|
+
1,
|
|
155
|
+
2,
|
|
156
|
+
4,
|
|
157
|
+
5
|
|
158
|
+
]
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
},
|
|
162
|
+
"then": {
|
|
163
|
+
"properties": {
|
|
164
|
+
"correspondence": false,
|
|
165
|
+
"chapters": {
|
|
166
|
+
"$ref": "#/$defs/legacySymbolChapters"
|
|
167
|
+
},
|
|
168
|
+
"tours": {
|
|
169
|
+
"additionalProperties": {
|
|
170
|
+
"properties": {
|
|
171
|
+
"chapters": {
|
|
172
|
+
"$ref": "#/$defs/legacySymbolChapters"
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
}
|
|
147
179
|
}
|
|
148
180
|
],
|
|
149
181
|
"$defs": {
|
|
182
|
+
"legacySymbolChapters": {
|
|
183
|
+
"items": { "properties": { "scenes": {
|
|
184
|
+
"items": { "properties": { "steps": {
|
|
185
|
+
"items": { "properties": { "symbol": false } }
|
|
186
|
+
} } }
|
|
187
|
+
} } }
|
|
188
|
+
},
|
|
150
189
|
"legacyFramingChapters": {
|
|
151
190
|
"items": {
|
|
152
191
|
"allOf": [
|
|
@@ -276,6 +315,7 @@
|
|
|
276
315
|
}
|
|
277
316
|
},
|
|
278
317
|
"step": {
|
|
318
|
+
"not": { "anyOf": [{ "required": ["symbol", "image"] }, { "required": ["symbol", "connection"] }] },
|
|
279
319
|
"type": "object",
|
|
280
320
|
"additionalProperties": false,
|
|
281
321
|
"required": ["id", "title", "body", "focus"],
|
|
@@ -284,6 +324,11 @@
|
|
|
284
324
|
"title": { "$ref": "#/$defs/nonEmptyString" },
|
|
285
325
|
"body": { "$ref": "#/$defs/nonEmptyString" },
|
|
286
326
|
"focus": { "$ref": "#/$defs/nonEmptyString" },
|
|
327
|
+
"symbol": {
|
|
328
|
+
"type": "object", "additionalProperties": false,
|
|
329
|
+
"properties": {"relation": {"$ref": "#/$defs/nonEmptyString"}, "symbol": {"$ref": "#/$defs/nonEmptyString"}},
|
|
330
|
+
"oneOf": [{"required": ["relation"]}, {"required": ["symbol"]}]
|
|
331
|
+
},
|
|
287
332
|
"image": {
|
|
288
333
|
"type": "object", "additionalProperties": false,
|
|
289
334
|
"required": ["file", "revision", "alt"],
|
package/web/export-runtime.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schema": 1,
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.11.0",
|
|
4
4
|
"assets": {
|
|
5
|
-
"web/presenter.css": "sha256-
|
|
6
|
-
"media/webview.css": "sha256-
|
|
7
|
-
"web/web-host.js": "sha256-
|
|
5
|
+
"web/presenter.css": "sha256-UsJZl/OYwt1v1G57hlkuuvVH3VU2tdT8zz8DdXmEXyA=",
|
|
6
|
+
"media/webview.css": "sha256-GiajYKzkQfLMRBlFze7TtXtdvxqYAIGukFbgEDZpFdI=",
|
|
7
|
+
"web/web-host.js": "sha256-X4Y//onjgzIv0frhnDAhOdOEzjPpUiquJoJh4zRB8oo=",
|
|
8
8
|
"media/webview.js": "sha256-pnnG4JuNqHLjkKDQy4kJ1lOtBt7UyPqUSQPIvsur2s4=",
|
|
9
9
|
"media/editor.worker.js": "sha256-qWbRV7U57PL25iH34w5bTeMJ0D1QDMulvRzYEPBRKnI=",
|
|
10
|
-
"media/diff.worker.js": "sha256-
|
|
10
|
+
"media/diff.worker.js": "sha256-QphF2PTO5YfP8QFMIUyQsBk3v+w9/Pi6wPsXifCR1aU="
|
|
11
11
|
}
|
|
12
12
|
}
|
package/web/index.html
CHANGED
|
@@ -31,6 +31,7 @@
|
|
|
31
31
|
<nav id="tour-navigator-tabs" class="tour-navigator-tabs" aria-label="Tour navigator">
|
|
32
32
|
<button type="button" data-tour-navigator="tour" aria-controls="tour-navigator-tour" aria-selected="true" title="Browse tour scenes">Tour <span id="tour-scene-count" class="tour-rail-count"></span></button>
|
|
33
33
|
<button type="button" data-tour-navigator="files" aria-controls="tour-navigator-files" aria-selected="false" title="Browse changed files">Files <span id="tour-file-count" class="tour-rail-count"></span></button>
|
|
34
|
+
<button id="correspondence-tab" type="button" title="Explore inferred symbol mappings across the pinned comparison" data-tour-navigator="symbols" aria-controls="tour-navigator-symbols" aria-selected="false" hidden>Symbols</button>
|
|
34
35
|
<button type="button" data-tour-navigator="commits" aria-controls="tour-navigator-commits" aria-selected="false" title="Browse revisions">Commits</button>
|
|
35
36
|
</nav>
|
|
36
37
|
<div class="tour-navigator-content">
|
|
@@ -63,6 +64,16 @@
|
|
|
63
64
|
<label id="tour-file-filter" class="file-tree-filter"><input id="tour-show-all-files" type="checkbox"><span id="tour-file-filter-label">Show all files</span><span id="tour-visible-file-count"></span></label>
|
|
64
65
|
<nav id="tour-files" class="tour-files" aria-label="Changed files"></nav>
|
|
65
66
|
</section>
|
|
67
|
+
<section id="tour-navigator-symbols" class="tour-navigator-panel" data-tour-navigator-panel="symbols" hidden>
|
|
68
|
+
<p id="correspondence-status" role="status"></p>
|
|
69
|
+
<label>Find a symbol <input id="correspondence-filter" type="search" placeholder="Name or path"></label>
|
|
70
|
+
<label><input id="correspondence-all" type="checkbox"> Include unchanged local symbols</label>
|
|
71
|
+
<label title="Includes before-only and after-only declarations without an accepted match; these are not confirmed additions or deletions."><input id="correspondence-unmatched" type="checkbox" checked> Include added or removed local symbols</label>
|
|
72
|
+
<p id="correspondence-selection" aria-live="polite"></p>
|
|
73
|
+
<button id="correspondence-context" type="button" title="Show complete source and destination files with declarations highlighted" hidden>Show file context</button>
|
|
74
|
+
<nav id="correspondence-list" aria-label="Symbol tree"></nav>
|
|
75
|
+
<details id="correspondence-analysis"><summary>Analysis details</summary><div id="correspondence-limitations"></div></details>
|
|
76
|
+
</section>
|
|
66
77
|
<section id="tour-navigator-commits" class="tour-navigator-panel" data-tour-navigator-panel="commits" hidden>
|
|
67
78
|
<div id="tour-history-controls" class="tour-evidence-controls" hidden>
|
|
68
79
|
<div class="tour-selection-toolbar">
|
|
@@ -181,6 +192,7 @@
|
|
|
181
192
|
<span id="tour-directory-narration-context" class="tour-directory-narration-context" hidden>Narration describes the overview</span>
|
|
182
193
|
</nav>
|
|
183
194
|
<div id="file-info" class="header-align-diff">Choose a compare command to render a diff.</div>
|
|
195
|
+
<button id="file-symbol-context" class="header-align-diff" type="button" title="Switch between the symbol comparison and its full file context" hidden>Show file context</button>
|
|
184
196
|
<div id="status-banner" class="status-banner header-align-diff" role="status" aria-live="polite" aria-atomic="true" hidden></div>
|
|
185
197
|
<div id="directory-return-toolbar" class="directory-return-toolbar header-align-diff" hidden>
|
|
186
198
|
<button id="back-to-directory" class="directory-return-button" type="button" title="Show directory comparison (Cmd/Ctrl+[)" aria-label="Show directory comparison">
|
package/web/presenter.css
CHANGED
|
@@ -1579,3 +1579,84 @@ body.tour-bookend.tour-discussion #tour-narrative-resizer { display: none; }
|
|
|
1579
1579
|
|
|
1580
1580
|
.tour-route-chapter { margin-top: 1.5em; }
|
|
1581
1581
|
.tour-route-chapter > .tour-route { margin-top: 1em; padding-left: 1em; border-left: 2px solid var(--tour-border); }
|
|
1582
|
+
|
|
1583
|
+
/* Optional, revision-pinned symbol correspondence exploration. */
|
|
1584
|
+
#tour-navigator-symbols { padding: 12px; overflow: auto; }
|
|
1585
|
+
#tour-navigator-symbols label { display: block; margin: 8px 0; }
|
|
1586
|
+
#correspondence-filter { width: 100%; box-sizing: border-box; }
|
|
1587
|
+
.correspondence-tree, .correspondence-tree ul { list-style: none; margin: 0; padding: 0; }
|
|
1588
|
+
.correspondence-tree ul { margin-left: 11px; padding-left: 10px; border-left: 1px solid var(--tour-border); }
|
|
1589
|
+
.correspondence-heading { display: flex; align-items: flex-start; gap: 3px; margin: 3px 0; }
|
|
1590
|
+
.correspondence-toggle { flex: 0 0 18px; width: 18px; padding: 8px 0; background: none; border: 0; color: var(--tour-muted); cursor: pointer; }
|
|
1591
|
+
.correspondence-toggle[hidden] { display: block !important; visibility: hidden; }
|
|
1592
|
+
.correspondence-file-label { min-width: 0; padding: 8px 2px; border: 0; background: none; color: inherit; font: inherit; font-size: 12px; font-weight: 600; overflow-wrap: anywhere; text-align: left; cursor: pointer; }
|
|
1593
|
+
.correspondence-file + .correspondence-file { margin-top: 12px; }
|
|
1594
|
+
.correspondence-item { display: flex; flex: 1; min-width: 0; flex-direction: column; align-items: flex-start; gap: 3px; text-align: left; padding: 7px; border: 1px solid transparent; border-radius: 4px; background: none; color: inherit; cursor: pointer; font: inherit; }
|
|
1595
|
+
.correspondence-item strong { font-size: 12px; font-weight: 500; overflow-wrap: anywhere; }
|
|
1596
|
+
.correspondence-item[data-change-kind="added"] > strong { color: var(--vscode-gitDecoration-addedResourceForeground, #8ed6a5); }
|
|
1597
|
+
.correspondence-item[data-change-kind="modified"] > strong { color: var(--vscode-gitDecoration-modifiedResourceForeground, #e2b36b); }
|
|
1598
|
+
.correspondence-item[data-change-kind="deleted"] > strong { color: var(--vscode-gitDecoration-deletedResourceForeground, #f48771); }
|
|
1599
|
+
.correspondence-item span { font-size: 12px; overflow-wrap: anywhere; color: var(--tour-muted); }
|
|
1600
|
+
.correspondence-location { display: none; }
|
|
1601
|
+
.correspondence-item.is-relocated .correspondence-location, .correspondence-item:hover .correspondence-location, .correspondence-item[aria-pressed="true"] .correspondence-location, .correspondence-item:focus-visible .correspondence-location { display: block; }
|
|
1602
|
+
.is-context > .correspondence-heading > .correspondence-item { opacity: .65; }
|
|
1603
|
+
.correspondence-item:hover, .correspondence-file-label:hover { background: var(--vscode-list-hoverBackground, #ffffff0d); }
|
|
1604
|
+
.correspondence-item:focus-visible, .correspondence-toggle:focus-visible, .correspondence-file-label:focus-visible { outline: 2px solid var(--vscode-focusBorder, #58a6ff); outline-offset: -2px; }
|
|
1605
|
+
.correspondence-item[aria-pressed="true"] { outline: 1px solid var(--vscode-focusBorder, #58a6ff); }
|
|
1606
|
+
#correspondence-status, #correspondence-selection, #correspondence-limitations { font-size: 12px; overflow-wrap: anywhere; }
|
|
1607
|
+
#correspondence-analysis { margin-top: 16px; border-top: 1px solid var(--tour-border); padding-top: 12px; }
|
|
1608
|
+
#correspondence-limitations details { margin: 12px 0; }
|
|
1609
|
+
#correspondence-limitations summary { cursor: pointer; line-height: 1.5; }
|
|
1610
|
+
.correspondence-diagnostics { list-style: none; margin: 8px 0; padding: 0; }
|
|
1611
|
+
.correspondence-diagnostics li { padding: 10px 0; border-top: 1px solid var(--tour-border); }
|
|
1612
|
+
.correspondence-diagnostics p { margin: 5px 0; }
|
|
1613
|
+
.correspondence-diagnostics code { font-size: 12px; color: var(--tour-muted); }
|
|
1614
|
+
.correspondence-diagnostic-location { display: block; margin-top: 6px; padding: 3px 0; font: inherit; color: inherit; overflow-wrap: anywhere; text-align: left; }
|
|
1615
|
+
button.correspondence-diagnostic-location { background: none; border: 0; text-decoration: underline; cursor: pointer; }
|
|
1616
|
+
button.correspondence-diagnostic-location:focus-visible { outline: 2px solid var(--vscode-focusBorder, #58a6ff); }
|
|
1617
|
+
|
|
1618
|
+
.tour-navigator-tabs:has(#correspondence-tab:not([hidden])) { grid-template-columns: repeat(4, minmax(0, 1fr)); }
|
|
1619
|
+
|
|
1620
|
+
.file-symbols { margin: 4px 0 8px 16px; font-size: 12px; }
|
|
1621
|
+
.file-symbols[hidden] { display: none; }
|
|
1622
|
+
.has-file-symbols { position: relative; }
|
|
1623
|
+
.has-file-symbols > .tour-file { padding-right: 32px; }
|
|
1624
|
+
.file-symbol-toggle {
|
|
1625
|
+
position: absolute;
|
|
1626
|
+
top: 5px;
|
|
1627
|
+
right: 4px;
|
|
1628
|
+
width: 24px;
|
|
1629
|
+
height: 28px;
|
|
1630
|
+
padding: 0;
|
|
1631
|
+
font: inherit;
|
|
1632
|
+
font-size: 16px;
|
|
1633
|
+
line-height: 1;
|
|
1634
|
+
color: var(--tour-muted);
|
|
1635
|
+
background: transparent;
|
|
1636
|
+
border: 0;
|
|
1637
|
+
border-radius: 4px;
|
|
1638
|
+
cursor: pointer;
|
|
1639
|
+
}
|
|
1640
|
+
.file-symbol-toggle:hover { color: var(--tour-body); background: var(--bygone-hover); }
|
|
1641
|
+
.file-symbol-toggle:focus-visible { outline: 2px solid var(--vscode-focusBorder, #58a6ff); }
|
|
1642
|
+
.tour-file[data-change-kind="added"] { --file-status-color: var(--vscode-gitDecoration-addedResourceForeground, #8ed6a5); }
|
|
1643
|
+
.tour-file[data-change-kind="deleted"] { --file-status-color: var(--vscode-gitDecoration-deletedResourceForeground, #f48771); }
|
|
1644
|
+
.tour-file[data-change-kind="modified"] { --file-status-color: var(--vscode-gitDecoration-modifiedResourceForeground, #e2b36b); }
|
|
1645
|
+
.tour-file[data-change-kind="renamed"] { --file-status-color: var(--vscode-gitDecoration-renamedResourceForeground, #73c991); }
|
|
1646
|
+
.tour-file[data-change-kind]:not(.is-comparison-empty) .tour-file-path,
|
|
1647
|
+
.tour-file[data-change-kind]:not(.is-comparison-empty) .tour-file-marker { color: var(--file-status-color, var(--tour-body)); }
|
|
1648
|
+
.correspondence-file-label[aria-current="true"] { outline: 1px solid var(--vscode-focusBorder, #58a6ff); }
|
|
1649
|
+
#correspondence-context, #file-symbol-context {
|
|
1650
|
+
width: fit-content;
|
|
1651
|
+
max-width: 100%;
|
|
1652
|
+
margin-top: 6px;
|
|
1653
|
+
margin-bottom: 6px;
|
|
1654
|
+
padding: 5px 9px;
|
|
1655
|
+
color: var(--tour-accent-bright);
|
|
1656
|
+
background: var(--bygone-selection);
|
|
1657
|
+
border: 1px solid var(--tour-border);
|
|
1658
|
+
border-radius: 4px;
|
|
1659
|
+
cursor: pointer;
|
|
1660
|
+
font: inherit;
|
|
1661
|
+
}
|
|
1662
|
+
#correspondence-context:hover, #file-symbol-context:hover { background: var(--bygone-hover); }
|