From adfa60ef149e5240c72b97101ea2ac3d80190823 Mon Sep 17 00:00:00 2001 From: Antonin Delpeuch Date: Fri, 20 Apr 2018 19:51:33 +0200 Subject: [PATCH] Fix scrolling in Wikidata schema --- .../dialogs/schema-alignment-dialog.html | 10 ++++++---- .../dialogs/schema-alignment-dialog.js | 3 +++ .../module/scripts/schema-alignment-tab.html | 19 +++++++++++-------- .../dialogs/schema-alignment-dialog.css | 7 +++++-- 4 files changed, 25 insertions(+), 14 deletions(-) diff --git a/extensions/wikidata/module/scripts/dialogs/schema-alignment-dialog.html b/extensions/wikidata/module/scripts/dialogs/schema-alignment-dialog.html index ddca9f39f..7e05b6ea4 100644 --- a/extensions/wikidata/module/scripts/dialogs/schema-alignment-dialog.html +++ b/extensions/wikidata/module/scripts/dialogs/schema-alignment-dialog.html @@ -8,11 +8,13 @@
  • -

    -
    -
    +
    +

    +
    -
    +
    +
    +
    diff --git a/extensions/wikidata/module/scripts/dialogs/schema-alignment-dialog.js b/extensions/wikidata/module/scripts/dialogs/schema-alignment-dialog.js index aff2be2ac..bf5f895bb 100644 --- a/extensions/wikidata/module/scripts/dialogs/schema-alignment-dialog.js +++ b/extensions/wikidata/module/scripts/dialogs/schema-alignment-dialog.js @@ -195,6 +195,9 @@ SchemaAlignmentDialog.switchTab = function(targetTab) { this._schemaPanel.height(panelHeight); this._issuesPanel.height(panelHeight); this._previewPanel.height(panelHeight); + // Resize the inside of the schema panel + var headerHeight = this._schemaElmts.schemaHeader.outerHeight(); + this._schemaElmts.canvas.height(panelHeight - headerHeight - 10); } SchemaAlignmentDialog.isSetUp = function() { diff --git a/extensions/wikidata/module/scripts/schema-alignment-tab.html b/extensions/wikidata/module/scripts/schema-alignment-tab.html index d66c6d0a0..5bff5236c 100644 --- a/extensions/wikidata/module/scripts/schema-alignment-tab.html +++ b/extensions/wikidata/module/scripts/schema-alignment-tab.html @@ -1,14 +1,17 @@
    -
    -

    -
    -
    -
    -
    -
    +
    +
    +

    +
    +
    -
    +
    +
    +
    +
    +
    +
    diff --git a/extensions/wikidata/module/styles/dialogs/schema-alignment-dialog.css b/extensions/wikidata/module/styles/dialogs/schema-alignment-dialog.css index 7ab25a48b..a4deb9eda 100644 --- a/extensions/wikidata/module/styles/dialogs/schema-alignment-dialog.css +++ b/extensions/wikidata/module/styles/dialogs/schema-alignment-dialog.css @@ -19,6 +19,10 @@ height: 100%; } +#schema-alignment-tab { + overflow: hidden; +} + .main-view-panel-tab-header { margin-top: 9px; margin-left: 7px; @@ -41,9 +45,8 @@ } .schema-alignment-dialog-canvas { - padding: 0px - margin-top: 3px; background: white; + overflow-y: auto; } .schema-alignment-dialog-statements-area {