mcdview 0.24.2__tar.gz → 0.24.4__tar.gz
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.
- {mcdview-0.24.2 → mcdview-0.24.4}/PKG-INFO +18 -1
- {mcdview-0.24.2 → mcdview-0.24.4}/README.md +17 -0
- {mcdview-0.24.2 → mcdview-0.24.4}/pyproject.toml +1 -1
- {mcdview-0.24.2 → mcdview-0.24.4}/templates/explorateur.html +45 -3
- {mcdview-0.24.2 → mcdview-0.24.4}/.gitignore +0 -0
- {mcdview-0.24.2 → mcdview-0.24.4}/LICENSE +0 -0
- {mcdview-0.24.2 → mcdview-0.24.4}/logo.svg +0 -0
- {mcdview-0.24.2 → mcdview-0.24.4}/mcdview.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: mcdview
|
|
3
|
-
Version: 0.24.
|
|
3
|
+
Version: 0.24.4
|
|
4
4
|
Summary: Turn a SQL data model into one self-contained, interactive HTML page
|
|
5
5
|
Project-URL: Homepage, https://github.com/Gheop/mcdview
|
|
6
6
|
Project-URL: Demo, https://gheop.github.io/mcdview/
|
|
@@ -322,6 +322,23 @@ file's header.
|
|
|
322
322
|
|
|
323
323
|
## Changelog
|
|
324
324
|
|
|
325
|
+
### v0.24.4 — Firefox initial-fit fix (2026-08-30)
|
|
326
|
+
|
|
327
|
+
- Firefox computed the first zoom-to-fit before layout settled, so a freshly
|
|
328
|
+
opened page showed the tables mis-scaled and the FK links mis-routed until
|
|
329
|
+
the first hover. The fit is now recomputed after fonts are ready and two
|
|
330
|
+
frames have painted (a no-op in Chrome, the correction Firefox needs).
|
|
331
|
+
- The panel intro-close now animates reliably (the slow transition is
|
|
332
|
+
established a frame before the transform changes, so it no longer snaps shut
|
|
333
|
+
instantly on some browsers).
|
|
334
|
+
|
|
335
|
+
### v0.24.3 — Intro reveal for the detail panel (2026-08-30)
|
|
336
|
+
|
|
337
|
+
- On first load the detail panel shows open (so its purpose is visible), then
|
|
338
|
+
slides shut over ~2s to the collapsed default — clicking a table or the
|
|
339
|
+
toggle cancels the intro and keeps the panel open. Skipped when a preference
|
|
340
|
+
is remembered or the URL opens straight on a table.
|
|
341
|
+
|
|
325
342
|
### v0.24.2 — Collapsible detail panel (2026-08-30)
|
|
326
343
|
|
|
327
344
|
- The detail panel can be collapsed to give the diagram the full width. It
|
|
@@ -300,6 +300,23 @@ file's header.
|
|
|
300
300
|
|
|
301
301
|
## Changelog
|
|
302
302
|
|
|
303
|
+
### v0.24.4 — Firefox initial-fit fix (2026-08-30)
|
|
304
|
+
|
|
305
|
+
- Firefox computed the first zoom-to-fit before layout settled, so a freshly
|
|
306
|
+
opened page showed the tables mis-scaled and the FK links mis-routed until
|
|
307
|
+
the first hover. The fit is now recomputed after fonts are ready and two
|
|
308
|
+
frames have painted (a no-op in Chrome, the correction Firefox needs).
|
|
309
|
+
- The panel intro-close now animates reliably (the slow transition is
|
|
310
|
+
established a frame before the transform changes, so it no longer snaps shut
|
|
311
|
+
instantly on some browsers).
|
|
312
|
+
|
|
313
|
+
### v0.24.3 — Intro reveal for the detail panel (2026-08-30)
|
|
314
|
+
|
|
315
|
+
- On first load the detail panel shows open (so its purpose is visible), then
|
|
316
|
+
slides shut over ~2s to the collapsed default — clicking a table or the
|
|
317
|
+
toggle cancels the intro and keeps the panel open. Skipped when a preference
|
|
318
|
+
is remembered or the URL opens straight on a table.
|
|
319
|
+
|
|
303
320
|
### v0.24.2 — Collapsible detail panel (2026-08-30)
|
|
304
321
|
|
|
305
322
|
- The detail panel can be collapsed to give the diagram the full width. It
|
|
@@ -105,6 +105,10 @@
|
|
|
105
105
|
#viewport, #panneau { transition: right .25s ease, transform .25s ease; }
|
|
106
106
|
body.panneau-reduit #viewport { right: 0; }
|
|
107
107
|
body.panneau-reduit #panneau { transform: translateX(100%); }
|
|
108
|
+
/* intro: the panel shows open over the (already full-width) diagram, then
|
|
109
|
+
slides away — so a first-time viewer sees the panel exists before it tucks */
|
|
110
|
+
body.intro-panneau #panneau { transform: none; }
|
|
111
|
+
body.intro-ferme #panneau { transition: transform 1.8s ease; }
|
|
108
112
|
/* the toggle sits on the panel's inner edge, and rides to the screen edge
|
|
109
113
|
when collapsed so it stays reachable */
|
|
110
114
|
#togglePanneau { position: absolute; top: 50%; right: 340px; z-index: 11;
|
|
@@ -502,14 +506,36 @@ function reduirePanneau(v, refit) {
|
|
|
502
506
|
if (refit) setTimeout(() => cadrer(focusCle ? [focusCle, ...voisins(focusCle)]
|
|
503
507
|
: Object.keys(elems)), 260);
|
|
504
508
|
}
|
|
509
|
+
let introTimer = null;
|
|
510
|
+
function finIntro() { // stop the intro; leave the panel wherever it now is
|
|
511
|
+
if (introTimer) { clearTimeout(introTimer); introTimer = null; }
|
|
512
|
+
document.body.classList.remove("intro-panneau", "intro-ferme");
|
|
513
|
+
}
|
|
505
514
|
(function initPanneau() {
|
|
506
515
|
let pref = null;
|
|
507
516
|
try { pref = localStorage.getItem("mcdview:panneau"); } catch (e) { /* ignore */ }
|
|
508
|
-
if (pref === "ouvert") { autoExpand = false; reduirePanneau(false); }
|
|
509
|
-
|
|
510
|
-
|
|
517
|
+
if (pref === "ouvert") { autoExpand = false; reduirePanneau(false); return; }
|
|
518
|
+
if (pref === "reduit") { autoExpand = false; reduirePanneau(true); return; }
|
|
519
|
+
// no stored choice, and not opening straight on a table (permalink): play the
|
|
520
|
+
// intro — collapsed layout (full-width diagram) but the panel visible, then it
|
|
521
|
+
// slides shut over ~2s, revealing the space it frees
|
|
522
|
+
reduirePanneau(true);
|
|
523
|
+
if (!location.hash) {
|
|
524
|
+
document.body.classList.add("intro-panneau"); // shown open on first paint
|
|
525
|
+
introTimer = setTimeout(() => {
|
|
526
|
+
// establish the slow (1.8s) transition first, then change the transform on
|
|
527
|
+
// the NEXT frame — changing duration and value in one frame is not animated
|
|
528
|
+
// reliably (Firefox especially), which made the panel snap shut instantly
|
|
529
|
+
document.body.classList.add("intro-ferme");
|
|
530
|
+
requestAnimationFrame(() => requestAnimationFrame(() => {
|
|
531
|
+
document.body.classList.remove("intro-panneau"); // now the slow close runs
|
|
532
|
+
introTimer = setTimeout(() => document.body.classList.remove("intro-ferme"), 1900);
|
|
533
|
+
}));
|
|
534
|
+
}, 1100);
|
|
535
|
+
}
|
|
511
536
|
})();
|
|
512
537
|
btnToggle.addEventListener("click", () => {
|
|
538
|
+
finIntro();
|
|
513
539
|
autoExpand = false; // the viewer decides from now on
|
|
514
540
|
reduirePanneau(!panneauReduit, true);
|
|
515
541
|
try { localStorage.setItem("mcdview:panneau", panneauReduit ? "reduit" : "ouvert"); } catch (e) { /* ignore */ }
|
|
@@ -518,6 +544,7 @@ btnToggle.addEventListener("click", () => {
|
|
|
518
544
|
// --- DBeaver-like focus mode: the table in the center, its neighbours in a star ---
|
|
519
545
|
function isoler(cle) {
|
|
520
546
|
focusCle = cle;
|
|
547
|
+
finIntro(); // a table click ends the intro and keeps the panel open below
|
|
521
548
|
if (autoExpand && panneauReduit) reduirePanneau(false, true); // reveal detail
|
|
522
549
|
survolCle = null;
|
|
523
550
|
history.replaceState(null, "", "#" + encodeURIComponent(cle));
|
|
@@ -851,6 +878,21 @@ ckAudit.addEventListener("change", () => {
|
|
|
851
878
|
if (!D.fks.some(f => f.audit)) document.getElementById("labelAudit").hidden = true;
|
|
852
879
|
dessinerLiens();
|
|
853
880
|
cadrer(Object.keys(elems));
|
|
881
|
+
// Firefox computes the first fit before layout/fonts settle, so the initial
|
|
882
|
+
// zoom and edge routing are off until a reflow (the first hover fixes it).
|
|
883
|
+
// Re-fit once fonts are ready and two frames have painted — a no-op in Chrome
|
|
884
|
+
// (same result), the correction Firefox needs. Skipped if the viewer is
|
|
885
|
+
// already on a specific table (permalink) or has taken over the view.
|
|
886
|
+
function refitInitial() {
|
|
887
|
+
// if a permalink put the viewer on a table, just redraw links against the
|
|
888
|
+
// now-settled boxes; otherwise re-fit the whole diagram
|
|
889
|
+
if (focusCle || location.hash) { dessinerLiens(); return; }
|
|
890
|
+
cadrer(Object.keys(elems));
|
|
891
|
+
dessinerLiens();
|
|
892
|
+
}
|
|
893
|
+
const deuxFrames = () => requestAnimationFrame(() => requestAnimationFrame(refitInitial));
|
|
894
|
+
if (document.fonts && document.fonts.ready) document.fonts.ready.then(deuxFrames);
|
|
895
|
+
else deuxFrames();
|
|
854
896
|
|
|
855
897
|
// --- permalink: #schema.table opens straight on that table ---
|
|
856
898
|
window.addEventListener("hashchange", () => {
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|