Skip to content

The OSINT investigator's workbench. One case, one folder, every tool. Local-first: your media and your investigations never leave your machine.

JavaScript

Remove Date it from Compare's All dates strip (#91)

OsintMeThat7b86b325169a
diff --git a/README.md b/README.md
index fda0623..a1376ed 100644
--- a/README.md
+++ b/README.md
@@ -62,7 +62,7 @@ to fix a point on the map.*
| **Inspect** | Reads any photo or video closely: sharpest-frame capture onto a strip, frame adjustments, editable crop and ELA hints. Frames and edits are kept with the file as you make them; a frame or an adjusted video enters the Media Library only when you save it to the case. |
| **Collage** | Lays out frames and images from any number of files on one canvas, with per-piece warp, scale, rotate and crop, and auto-stitch to solve a panorama's layout. Saved as you go; the picture it exports is case media. |
| **Satellite** | Coordinates or a place name become an imagery crop. The search bar proposes matches as you type: saved work, coordinates and a bundled city list answer offline, and the geocoder fills in the rest once you pause. Select-area capture with an optional scale bar and north arrow, map rotation, measurement tools, a right-click menu on any point, stacked overlays (borders, roads, railways, power lines, fires, night lights), your own KML, KMZ, GeoJSON, GPX or My Maps layers, GeoConfirmed conflicts narrowed to a period, and editable AOI grids for area review. Esri/OSM by default, plus the Esri Wayback archive, Sentinel-2 with a date calendar and a cloud-ceiling slider, and Sentinel-1 radar passes; add a Mapbox or Google key for more basemaps. Open it in several tabs and they stay in sync. |
-| **Compare** | Links two dated map views for side-by-side, swipe, fade or blink, with Difference highlights laid over any of them. All dates lists every picture of a point and narrows down when a change appeared. Ground-anchored notes, shapes, numbered markers and measurements follow both maps. Editable sessions and rendered previews stay in the case; attributed PNG/GIF copies go to exports. |
+| **Compare** | Links two dated map views for side-by-side, swipe, fade or blink, with Difference highlights laid over any of them. All dates lists every picture of a point, oldest first, to set on either side. Ground-anchored notes, shapes, numbered markers and measurements follow both maps. Editable sessions and rendered previews stay in the case; attributed PNG/GIF copies go to exports. |
| **Detect** | Sweeps drawn areas of Sentinel-2 for vessels, fires, construction, burn scars and other changes, and of Sentinel-1 radar for vessels, razed buildings, new structures and floods through cloud, once or as a saved routine. Only a candidate you keep becomes a case pin, dated by the passes that found it. |
| **Coords & Sky** | Convert common coordinate formats, copy the result, open map or geocoding links, and read the sun and moon at that point on a date: rise, set, azimuth, altitude, twilights, moon phase and bright-limb angle, in local time and UTC, computed offline. |
| **Geo Proof** | Start a named proof from a reusable house style, or from a published post whose pictures become its panels. Compose case panels in a grid or free layout, turn or crop them, annotate with colored shapes, fills, symbols, numbered markers, blur boxes, freehand and text, state every place and every source the proof argues, and export `proof.png` plus a re-editable spec. |
@@ -91,8 +91,8 @@ Detect sweeps an area for what appeared, and the map takes layers made elsewhere
- Build your own analyzer from rules on bands, indices, ground classes or radar,
with checks that turn red when a rule stops holding. Five examples ship with
theirs.
-- A candidate opens in Compare with one press, and All dates in Compare narrows
- down between which two pictures a change appeared.
+- A candidate opens in Compare with one press, and All dates in Compare lists
+ every picture of a point to set on either side.
- Satellite, Compare and Detect share one camera, and a middle-drag turns any map.
- Inspect keeps one work per file, saved as you go, and Collage is a tab of its own.
- Open KML, KMZ, GeoJSON and GPX files or a public My Maps as map layers, and add
diff --git a/docs/RELEASE_NOTES.md b/docs/RELEASE_NOTES.md
index 51eb9fa..b015eff 100644
--- a/docs/RELEASE_NOTES.md
+++ b/docs/RELEASE_NOTES.md
@@ -29,8 +29,8 @@ maps made elsewhere on yours.
- Compare opens on Wayback a year back against today's World Imagery, with no
key needed.
-- **All dates** lists every dated picture of a point and narrows down when a
- change appeared.
+- **All dates** lists every dated picture of a point, oldest first, to set on
+ either side.
- Sentinel-1 radar passes are a basemap in Satellite, Compare and Detect.
- A saved comparison stands on the map, dated A → B, and reopens in Compare.
- "Change assist" is now **Difference**, a switch over any of the four views.
diff --git a/docs/SPEC.md b/docs/SPEC.md
index 235d6e8..2424008 100644
--- a/docs/SPEC.md
+++ b/docs/SPEC.md
@@ -198,7 +198,7 @@ proof for publication.
| ✅ **A claim from where you are** | Files a claim from Details, a Board row or a Graph node with the entity already seated, asking a count and a condition where its family calls for them and writing the sentence from the fields. |
| ✅ **Radar Detect** | Five Sentinel-1 analyzers (vessels, any change, razed buildings, new structures, floods) through the user's own radar layer, calibrated on real scenes, held to one track. |
| ✅ **Sentinel-1 basemap** | Radar passes as a dated basemap in Satellite, Compare and Detect, named by day, UTC time and direction. |
-| ✅ **All dates** | Lists every dated picture of the point in Compare and narrows down, a question at a time, between which two a change appeared. |
+| ✅ **All dates** | Lists every dated picture of the point in Compare, oldest first, to set on either side. |
| ✅ **Copernicus where it is needed** | Detect and Compare say in the middle of the tool what Copernicus still lacks, with the free account, the Sentinel-2 configuration and the Sentinel-1 layer form field by field. |
| ✅ **A candidate in Compare** | Opens a Detect candidate in Compare on the passes that found it, or against high-resolution imagery for a thing present on one pass. |
| ✅ **Sizes in Detect** | Right-clicks Detect's map for its own point menu, measures a hull with a ruler, sizes each candidate along its footprint, walks the largest first, and hides the drawing or blinks A against B from the review. |
diff --git a/docs/UI.md b/docs/UI.md
index b66a082..fc5570b 100644
--- a/docs/UI.md
+++ b/docs/UI.md
@@ -1322,14 +1322,6 @@ ceiling and a radar pass off the pair's track are greyed. **Show pictures** draw
each one small from the tile proxy, priced before it is pressed and cached once
read, and a view that moved says so rather than refreshing on its own.
-**Date it** answers "between which two pictures did this appear". With a picture
-without the thing on A and one with it on B, A the older, it shows the middle
-picture between them on B and asks: *It is there*, *Not yet*, or *Can't tell* for
-cloud or a look that settles nothing. Each answer halves what is left, so a year
-of passes takes a handful of looks, and Undo takes one back. It ends on a
-sentence to copy — absent on one date, present on the next, and how many
-pictures between them could not tell.
-
Difference opens no column: its strip joins the view's own controls in the footer
under the stage, and its full settings open above that strip only from the gear.
The strip keeps one width through a read, so the panel hanging from it stays put;
diff --git a/frontend/src/lib/guide.js b/frontend/src/lib/guide.js
index e4754e0..36169fa 100644
--- a/frontend/src/lib/guide.js
+++ b/frontend/src/lib/guide.js
@@ -231,8 +231,8 @@ export const GUIDE = [
text: 'Read two locked views side by side, by swipe, fade or blink. On a matched pair, Difference highlights what changed over any of them; notes, shapes and stamped markers stay editable in the saved comparison and appear in its outputs.',
},
{
- label: 'All dates, and when it appeared',
- text: 'With the same dated archive on both sides, All dates lists every picture of the point under the crosshair. Put one without the thing on A and one with it on B, and Date it halves the gap until they are neighbours.',
+ label: 'All dates of one point',
+ text: 'With the same dated archive on both sides, All dates lists every picture of the point under the crosshair, oldest first. Press one to show it on B, or its A button to show it on A.',
},
{
label: 'Detect sweeps ground, once or again and again',
diff --git a/frontend/src/lib/map/passStrip.js b/frontend/src/lib/map/passStrip.js
index bd35c86..b47a175 100644
--- a/frontend/src/lib/map/passStrip.js
+++ b/frontend/src/lib/map/passStrip.js
@@ -1,13 +1,9 @@
/**
- * Every dated picture of one point, in a row, and the bracket that dates a change.
+ * Every dated picture of one point, in a row.
*
- * Compare reads two pictures. Dating an event asks a different question: not
- * "what changed between A and B" but "between which two pictures did it
- * appear". The strip lists every picture the archive A and B share holds for
- * the point in the middle of the view, oldest to newest, and the bracket halves
- * the gap between a picture where the thing is absent and one where it is
- * present until they are neighbours, a question at a time: log2 of the gap
- * rather than the whole of it.
+ * Compare reads two pictures. The strip lists every picture the archive A and
+ * B share holds for the point in the middle of the view, oldest to newest, so
+ * either side can be set to any of them with one press.
*
* Three archives answer it: Sentinel-2 days, Sentinel-1 passes of one track,
* and the Esri Wayback releases that changed the point. The lookups are the
@@ -78,8 +74,7 @@ export function lookupPath(archive, { lat, lon, zoom }, window) {
* The strip's rows, oldest first, whatever archive answered.
*
* `usable` is false for a Sentinel-2 day over the cloud ceiling, and for a
- * radar pass off the track the pair is read on: both are shown, neither is
- * offered to the bracket.
+ * radar pass off the track the pair is read on: both are shown greyed.
*/
export function stripEntries(archive, answer, { maxcc = 100, track = '' } = {}) {
if (archive === WAYBACK_ID) {
@@ -132,83 +127,6 @@ export function entryOf(entries, archive, side) {
return day ? entries.find((entry) => entry.key === day) ?? null : null;
}
-// -- the bracket ------------------------------------------------------------------
-
-/**
- * A bracket from what A and B show: A before the thing, B after it.
- * Null when they do not make one — a side the strip does not hold, or A not
- * older than B.
- */
-export function startBracket(entries, before, after) {
- if (!before || !after) return null;
- const from = entries.indexOf(before);
- const to = entries.indexOf(after);
- if (from < 0 || to < 0 || from >= to) return null;
- return { before: before.key, after: after.key, probe: null, skipped: [], history: [] };
-}
-
-/** The usable rows strictly between the bracket's ends. */
-export function between(entries, bracket) {
- const from = entries.findIndex((entry) => entry.key === bracket.before);
- const to = entries.findIndex((entry) => entry.key === bracket.after);
- if (from < 0 || to < 0) return [];
- return entries.slice(from + 1, to)
- .filter((entry) => entry.usable && !bracket.skipped.includes(entry.key));
-}
-
-/** The next row to look at: the middle of what is left, or null when done. */
-export function nextProbe(entries, bracket) {
- const left = between(entries, bracket);
- return left.length ? left[Math.floor((left.length - 1) / 2)] : null;
-}
-
-/**
- * The bracket after one answer about the probe.
- *
- * `there` moves the "after" end to the probe, `absent` the "before" end, and
- * `unclear` (cloud, a smear, a look that settles nothing) drops the probe
- * without moving either. Every answer can be taken back.
- */
-export function answerProbe(bracket, verdict) {
- const probe = bracket.probe;
- if (!probe) return bracket;
- const history = [...bracket.history, { before: bracket.before, after: bracket.after, skipped: bracket.skipped }];
- if (verdict === 'there') return { ...bracket, after: probe, probe: null, history };
- if (verdict === 'absent') return { ...bracket, before: probe, probe: null, history };
- return { ...bracket, skipped: [...bracket.skipped, probe], probe: null, history };
-}
-
-/** Take the last answer back. */
-export function undoAnswer(bracket) {
- const last = bracket.history.at(-1);
- if (!last) return bracket;
- return { ...bracket, ...last, probe: null, history: bracket.history.slice(0, -1) };
-}
-
-/** Whether nothing usable is left between the ends. */
-export function settled(entries, bracket) {
- return !nextProbe(entries, bracket);
-}
-
-/**
- * The finding, in a sentence the analyst can paste into a note. It says how
- * many pictures between the ends could not settle it, because "between the
- * 3rd and the 18th" hides a cloudy week that "no clear pass between" does not.
- */
-export function bracketSentence(entries, bracket, label) {
- const before = entries.find((entry) => entry.key === bracket.before);
- const after = entries.find((entry) => entry.key === bracket.after);
- if (!before || !after) return '';
- const name = (entry) => (entry.time ? `${entry.date} ${entry.time.slice(0, 5)} UTC` : entry.date);
- const from = entries.indexOf(before);
- const to = entries.indexOf(after);
- const unread = entries.slice(from + 1, to).length;
- const tail = unread
- ? `; ${unread === 1 ? 'one picture' : `${unread} pictures`} between them could not tell`
- : '';
- return `Absent on ${name(before)}, present on ${name(after)} (${label})${tail}.`;
-}
-
// -- pictures ------------------------------------------------------------------------
/** How big a picture of the view is drawn in the strip, in CSS px. */
diff --git a/frontend/src/lib/map/passStrip.test.js b/frontend/src/lib/map/passStrip.test.js
index 0e3dafe..1d7aa7e 100644
--- a/frontend/src/lib/map/passStrip.test.js
+++ b/frontend/src/lib/map/passStrip.test.js
@@ -1,17 +1,11 @@
import { describe, expect, it } from 'vitest';
import {
- answerProbe,
- between,
- bracketSentence,
entryOf,
lookupPath,
lookupWindow,
- nextProbe,
- startBracket,
stripArchive,
stripEntries,
thumbTiles,
- undoAnswer,
} from './passStrip.js';
const s2 = (date) => ({ present: true, provider: 'sentinel2', sentinel: { date, layer: 'TRUE_COLOR', maxcc: 100 } });
@@ -59,41 +53,6 @@ describe('the strip', () => {
});
});
-describe('dating a change', () => {
- const rows = stripEntries('sentinel2', optical, { maxcc: 30 });
- const start = () => startBracket(rows, rows[0], rows[6]);
-
- it('needs A older than B, both on the strip', () => {
- expect(startBracket(rows, rows[6], rows[0])).toBe(null);
- expect(startBracket(rows, null, rows[0])).toBe(null);
- expect(between(rows, start()).map((row) => row.date)).toEqual(
- ['2026-05-08', '2026-05-18', '2026-05-23', '2026-05-28']); // the cloudy 13th left out
- });
-
- it('halves the gap an answer at a time until the ends are neighbours', () => {
- let bracket = start();
- const ask = () => ({ ...bracket, probe: nextProbe(rows, bracket).key });
- bracket = ask();
- expect(bracket.probe).toBe('2026-05-18');
- bracket = answerProbe(bracket, 'there'); // it is on the 18th
- bracket = ask();
- expect(bracket.probe).toBe('2026-05-08');
- bracket = answerProbe(bracket, 'absent'); // not yet on the 8th
- expect(nextProbe(rows, bracket)).toBe(null);
- expect(bracketSentence(rows, bracket, 'Sentinel-2')).toBe(
- 'Absent on 2026-05-08, present on 2026-05-18 (Sentinel-2); one picture between them could not tell.');
- });
-
- it('drops a picture that settles nothing, and takes an answer back', () => {
- let bracket = { ...start(), probe: '2026-05-18' };
- bracket = answerProbe(bracket, 'unclear');
- expect(between(rows, bracket).map((row) => row.date)).not.toContain('2026-05-18');
- const undone = undoAnswer(bracket);
- expect(between(rows, undone).map((row) => row.date)).toContain('2026-05-18');
- expect(undoAnswer(undone)).toBe(undone);
- });
-});
-
describe('pictures of the view', () => {
const sentinel = { tile_size: 512, max_native_zoom: 14, max_zoom: 18 };
diff --git a/frontend/src/tools/Compare.svelte b/frontend/src/tools/Compare.svelte
index 411f92e..e67a69f 100644
--- a/frontend/src/tools/Compare.svelte
+++ b/frontend/src/tools/Compare.svelte
@@ -2220,7 +2220,7 @@
onmode={setMode} ondifference={setDifference} onswap={swapSides} />
<button class="btn btn-sm" class:active={stripOpen} disabled={!archive} aria-pressed={stripOpen}
onclick={() => (stripOpen = !stripOpen)}
- title={archive ? 'Every dated picture of this point, and when a change appeared'
+ title={archive ? 'Every dated picture of this point'
: 'Show the same dated archive on A and B to list its pictures'}>
<Icon name="clock" size={13} /> All dates
</button>
diff --git a/frontend/src/tools/compare/PassStrip.svelte b/frontend/src/tools/compare/PassStrip.svelte
index f6327e6..e4fd25c 100644
--- a/frontend/src/tools/compare/PassStrip.svelte
+++ b/frontend/src/tools/compare/PassStrip.svelte
@@ -1,13 +1,10 @@
<script>
/**
- * Every dated picture of the point under the crosshair, and the bracket that
- * dates a change on them.
+ * Every dated picture of the point under the crosshair.
*
* It opens on the archive A and B share, lists what that archive holds for
* the middle of the view from oldest to newest, and puts any row on either
- * side with one press. Narrowing starts from A (the thing absent) and B (the
- * thing there) and shows the middle picture on B, one question at a time,
- * until the two ends are neighbours. The pure part is `lib/map/passStrip.js`.
+ * side with one press. The pure part is `lib/map/passStrip.js`.
*
* The list costs one request for the Copernicus archives and none for Esri,
* and is read only when the strip opens or the analyst asks again. Pictures
@@ -19,17 +16,11 @@
import { orbitMark } from '../../lib/radar.js';
import {
THUMB,
- answerProbe,
- between,
- bracketSentence,
entryOf,
lookupPath,
lookupWindow,
- nextProbe,
- startBracket,
stripEntries,
thumbTiles,
- undoAnswer,
} from '../../lib/map/passStrip.js';
let {
@@ -57,8 +48,6 @@
let note = $state('');
let readAt = $state(null);
let pictures = $state(null); // the view the pictures were drawn for, or null
- let bracket = $state(null);
- let copied = $state(false);
// Radar compares one track: the track is the pass on B, or on A.
const track = $derived(archive === 'sentinel1' ? (b?.radar?.time || a?.radar?.time || '') : '');
@@ -66,9 +55,6 @@
const onA = $derived(entryOf(entries, archive, a));
const onB = $derived(entryOf(entries, archive, b));
const moved = $derived(!!readAt && distance(readAt, view) > 1000);
- const left = $derived(bracket ? between(entries, bracket).length : 0);
- const done = $derived(!!bracket && !bracket.probe && !left);
- const canNarrow = $derived(!bracket && !!startBracket(entries, onA, onB));
const perPicture = $derived(pictures ? thumbTiles({ ...pictures }, provider).length : 0);
const priced = $derived(thumbTiles({ ...view, viewWidth }, provider).length * entries.length);
@@ -86,7 +72,6 @@
try {
answer = await api.get(lookupPath(archive, at, lookupWindow(a, b)));
readAt = at;
- bracket = null;
pictures = null;
if (metered) onbilled();
} catch (error) {
@@ -110,39 +95,6 @@
onassign(letter, entry);
}
- function probe(next) {
- const row = nextProbe(entries, next);
- bracket = row ? { ...next, probe: row.key } : next;
- const before = entries.find((entry) => entry.key === bracket.before);
- const after = entries.find((entry) => entry.key === bracket.after);
- if (before) onassign('a', before);
- if (row) onassign('b', row);
- else if (after) onassign('b', after);
- }
-
- function narrow() {
- const start = startBracket(entries, onA, onB);
- if (start) probe(start);
- }
-
- function answerIt(verdict) {
- probe(answerProbe(bracket, verdict));
- }
-
- function undo() {
- probe(undoAnswer(bracket));
- }
-
- async function copy() {
- try {
- await navigator.clipboard.writeText(bracketSentence(entries, bracket, NAMES[archive]));
- copied = true;
- setTimeout(() => (copied = false), 1500);
- } catch {
- copied = false;
- }
- }
-
const label = (entry) => (entry.time ? `${entry.date} ${entry.time.slice(0, 5)}` : entry.date);
const tileUrl = (entry, tile) => `/api/tiles/${variantFor(entry)}/${tile.z}/${tile.x}/${tile.y}`;
</script>
@@ -179,8 +131,7 @@
{#each entries as entry (entry.key)}
{@const isA = onA?.key === entry.key}
{@const isB = onB?.key === entry.key}
- {@const inside = bracket && between(entries, bracket).includes(entry)}
- <li class:off={!entry.usable} class:inside class:probe={bracket?.probe === entry.key}>
+ <li class:off={!entry.usable}>
<button class="card" disabled={!entry.usable && archive === 'sentinel2'}
onclick={(event) => assign(event.altKey ? 'a' : 'b', entry)}
title={entry.usable ? 'Show on B · Alt to show on A'
@@ -210,30 +161,6 @@
{/if}
{/if}
- {#if entries.length}
- <footer class="bracket">
- {#if !bracket}
- {#if canNarrow}
- <span class="hint">A shows it absent and B present? Narrow it down one picture at a time.</span>
- <button class="btn btn-sm btn-primary" onclick={narrow}>Date it</button>
- {:else}
- <span class="hint">Put a picture without it on A and one with it on B, A the older, to date when it appeared.</span>
- {/if}
- {:else if bracket.probe}
- <span class="question">Is it there on B, <strong class="mono">{label(entries.find((entry) => entry.key === bracket.probe))}</strong>?
- <span class="hint">{left} left to check</span></span>
- <button class="btn btn-sm" onclick={() => answerIt('there')}>It is there</button>
- <button class="btn btn-sm" onclick={() => answerIt('absent')}>Not yet</button>
- <button class="btn btn-sm" onclick={() => answerIt('unclear')} title="Cloud, a smear, or a look that settles nothing">Can’t tell</button>
- {#if bracket.history.length}<button class="linkish" onclick={undo}>Undo</button>{/if}
- {:else if done}
- <span class="question">{bracketSentence(entries, bracket, NAMES[archive])}</span>
- <button class="btn btn-sm" onclick={copy}>{copied ? 'Copied' : 'Copy'}</button>
- {#if bracket.history.length}<button class="linkish" onclick={undo}>Undo</button>{/if}
- <button class="linkish" onclick={() => (bracket = null)}>Done</button>
- {/if}
- </footer>
- {/if}
</section>
<style>
@@ -264,11 +191,7 @@
position: relative;
flex: 0 0 auto;
display: grid;
- border: 1px solid transparent;
- border-radius: var(--r-sm);
}
- li.inside { border-color: color-mix(in srgb, var(--accent) 40%, transparent); }
- li.probe { border-color: var(--accent); }
li.off { opacity: 0.45; }
.card {
display: grid;
@@ -311,14 +234,6 @@
.tag.b { background: var(--side-b, #f59e0b); color: #0b0d11; }
.set { display: none; border: 1px solid var(--glass-line, var(--border)); color: var(--glass-muted, var(--text-3)); }
li:hover .set { display: block; }
- .bracket {
- display: flex;
- flex-wrap: wrap;
- align-items: center;
- gap: 8px;
- font-size: var(--fs-xs);
- }
- .question { color: var(--glass-ink, var(--text-1)); }
.linkish {
background: none;
border: 0;
diff --git a/frontend/src/tools/compare/PassStrip.svelte.test.js b/frontend/src/tools/compare/PassStrip.svelte.test.js
index 52c8b3c..81ee99b 100644
--- a/frontend/src/tools/compare/PassStrip.svelte.test.js
+++ b/frontend/src/tools/compare/PassStrip.svelte.test.js
@@ -68,17 +68,3 @@ it('shows a picture on B with a press, and on A from its own button', async () =
target.querySelectorAll('li')[1].querySelector('.set').click();
expect(onassign).toHaveBeenLastCalledWith('a', expect.objectContaining({ date: '2026-05-08' }));
});
-
-it('dates a change by halving the gap, and says what it found', async () => {
- open();
- await settle();
- button('Date it').click(); await settle();
- expect(target.textContent).toContain('Is it there on B, 2026-05-13?');
- button('It is there').click(); await settle();
- expect(target.textContent).toContain('Is it there on B, 2026-05-08?');
- button('Not yet').click(); await settle();
- expect(target.textContent).toContain(
- 'Absent on 2026-05-08, present on 2026-05-13 (Sentinel-2).');
- button('Undo').click(); await settle();
- expect(target.textContent).toContain('Is it there on B, 2026-05-08?');
-});