From 89b79bb373fafeddfdd688b16ce7055f663499a0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bartosz=20Dziewo=C5=84ski?= Date: Thu, 23 Apr 2015 13:52:12 +0200 Subject: [PATCH] Update for changes in OOjs UI (Ib40e3477) Depends on I175fe468 in VisualEditor core. Bug: T91152 Change-Id: I08c80cec84242eabd3da5bd3c829022df3e21636 --- .../styles/ve.init.mw.ViewPageTarget-apex.css | 6 +++- .../ve.init.mw.ViewPageTarget-monobook.css | 33 ++++++++++--------- .../ve.init.mw.ViewPageTarget-vector.css | 10 +++++- .../init/styles/ve.init.mw.ViewPageTarget.css | 1 - .../ui/themes/vector/ve.ui.MWFormatTool.css | 8 ++--- 5 files changed, 35 insertions(+), 23 deletions(-) diff --git a/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget-apex.css b/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget-apex.css index 86c5e703b7..7ad7e31e74 100644 --- a/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget-apex.css +++ b/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget-apex.css @@ -9,10 +9,14 @@ margin-top: 0.8em; } +.ve-ui-overlay-global { + /* Match skin's font-size */ + font-size: 0.8em; +} + .ve-init-mw-viewPageTarget-toolbar { margin: -0.6em -3em 0.8em -3em; position: relative; - font-size: 1.3em; } .ve-init-mw-viewPageTarget-toolbar .oo-ui-toolbar-bar { diff --git a/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget-monobook.css b/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget-monobook.css index b8ab7c185f..b7214ff73b 100644 --- a/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget-monobook.css +++ b/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget-monobook.css @@ -5,16 +5,28 @@ * @license The MIT License (MIT); see LICENSE.txt */ +.ve-ui-overlay-global { + /* Enforce different font-size for all UI elements of VisualEditor */ + font-size: 1.28em; /* 0.8em / x-small */ +} + +.ve-init-target { + /* Enforce different font-size for all UI elements of VisualEditor. The difference is tiny, but + enough to make the icon containers 23.813px rather than 24px and thus the icons blurry */ + font-size: 1.00787401575em; /* 0.8em / x-small / 127% */ +} + +.ve-init-target .ve-ce-surface.mw-body-content, +.ve-ui-overlay-global .ve-ce-surface.mw-body-content { + /* Match skin's font-size for the surface content */ + font-size: 0.992187499998em; /* 1/1.00787401575 */ +} + .ve-init-mw-viewPageTarget-toolbar { margin: -0.6em -0.8em 1em -0.8em; - /* Correct for Monobook's x-small font on the root toolbar */ - font-size: 1.25em; - line-height: 1.5em; } .ve-init-target > .ve-ui-debugBar { - /* Correct for Monobook's x-small font */ - font-size: 1.25em; border-top: 1px solid #ccc; } @@ -27,17 +39,6 @@ margin: 0.8em -0.8em -0.8em -0.8em; } -.ve-ui-overlay { - /* Mimic #globalWrapper */ - font-size: 127%; -} - -.ve-ui-overlay-global, -.ve-init-mw-viewPageTarget-windowManager-welcome { - /* Mimic #globalWrapper + Correct for Monobook's x-small font on the root overlay */ - font-size: 1.5875em; -} - .ve-ui-overlay-global { /* So that the overlay always appears over the site logo, search box and personal tools */ z-index: 4; diff --git a/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget-vector.css b/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget-vector.css index 8b7ba80448..099bf148c1 100644 --- a/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget-vector.css +++ b/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget-vector.css @@ -22,10 +22,18 @@ padding: 0 1.143em; /* surface-margin-left (1em) / (mw-body-content font-size) 0.875em */ } -.ve-init-mw-viewPageTarget-surface .oo-ui-menuSelectWidget { +.ve-init-target, +.ve-ui-overlay-global { + /* Enforce different font-size for all UI elements of VisualEditor */ font-size: 0.8em; } +.ve-init-target .ve-ce-surface.mw-body-content, +.ve-ui-overlay-global .ve-ce-surface.mw-body-content { + /* Match skin's font-size for the surface content */ + font-size: 1.09375em; /* 0.875/0.8 */ +} + .ve-init-mw-viewPageTarget-toolbar { margin: -1em -1em 1em -1em; position: relative; diff --git a/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget.css b/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget.css index 0876bd2865..639de36e8a 100644 --- a/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget.css +++ b/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget.css @@ -29,7 +29,6 @@ } .ve-init-mw-viewPageTarget-toolbar-actions { - font-size: 0.8em; vertical-align: top; padding: 0.25em; } diff --git a/modules/ve-mw/ui/themes/vector/ve.ui.MWFormatTool.css b/modules/ve-mw/ui/themes/vector/ve.ui.MWFormatTool.css index 438c8c960a..21b5f9d1a0 100644 --- a/modules/ve-mw/ui/themes/vector/ve.ui.MWFormatTool.css +++ b/modules/ve-mw/ui/themes/vector/ve.ui.MWFormatTool.css @@ -11,19 +11,19 @@ } .oo-ui-menuToolGroup .oo-ui-tool-name-heading1 .oo-ui-tool-title { - font-size: 144%; /* 0.8 * 180% */ + font-size: 180%; } .oo-ui-menuToolGroup .oo-ui-tool-name-heading2 .oo-ui-tool-title { - font-size: 120%; /* 0.8 * 150% */ + font-size: 150%; } .oo-ui-menuToolGroup .oo-ui-tool-name-heading3 .oo-ui-tool-title { - font-size: 94%; /* 0.8 * 117% */ + font-size: 117%; } .oo-ui-menuToolGroup .oo-ui-tool-name-heading4 .oo-ui-tool-title, .oo-ui-menuToolGroup .oo-ui-tool-name-heading5 .oo-ui-tool-title, .oo-ui-menuToolGroup .oo-ui-tool-name-heading6 .oo-ui-tool-title { - font-size: 80%; /* 0.8 * 100% */ + font-size: 100%; }