Esanders has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/183151

Change subject: Break out theme-specific CSS
......................................................................

Break out theme-specific CSS

Change-Id: I903e55a892a72424c8857529021b3b3eeaaee295
---
M .docs/eg-iframe.html
M build/modules.json
M demos/ve/desktop.html
M demos/ve/mobile.html
A src/themes/apex/dialogs.css
A src/themes/apex/widgets.css
A src/themes/mediawiki/dialogs.css
A src/themes/mediawiki/widgets.css
M src/ui/styles/dialogs/ve.ui.FindAndReplaceDialog.css
M src/ui/styles/widgets/ve.ui.SurfaceWidget.css
10 files changed, 95 insertions(+), 24 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/VisualEditor/VisualEditor 
refs/changes/51/183151/1

diff --git a/.docs/eg-iframe.html b/.docs/eg-iframe.html
index 96160cc..eff7586 100644
--- a/.docs/eg-iframe.html
+++ b/.docs/eg-iframe.html
@@ -49,6 +49,10 @@
                <!-- visualEditor.desktop.build -->
                <link rel=stylesheet 
href="../src/ui/styles/ve.ui.DesktopContext.css">
 
+               <!-- visualEditor.theme.apex -->
+               <link rel=stylesheet href="../src/themes/apex/dialogs.css">
+               <link rel=stylesheet href="../src/themes/apex/widgets.css">
+
                <!-- example styles -->
                <style>
                        body {
diff --git a/build/modules.json b/build/modules.json
index dc9b3e9..d0423b3 100644
--- a/build/modules.json
+++ b/build/modules.json
@@ -504,11 +504,24 @@
                        "visualEditor.desktop.standalone"
                ]
        },
+       "visualEditor.theme.apex": {
+               "styles": [
+                       "src/themes/apex/dialogs.css",
+                       "src/themes/apex/widgets.css"
+               ]
+       },
+       "visualEditor.theme.mediawiki": {
+               "styles": [
+                       "src/themes/mediawiki/dialogs.css",
+                       "src/themes/mediawiki/widgets.css"
+               ]
+       },
        "visualEditor.desktop": {
                "dependencies": [
                        "oojs-ui-apex",
                        "visualEditor.core",
-                       "visualEditor.desktop.build"
+                       "visualEditor.desktop.build",
+                       "visualEditor.theme.apex"
                ]
        },
        "visualEditor.desktop.build": {
@@ -528,7 +541,8 @@
                "dependencies": [
                        "oojs-ui-mediawiki",
                        "visualEditor.core",
-                       "visualEditor.mobile.build"
+                       "visualEditor.mobile.build",
+                       "visualEditor.theme.mediawiki"
                ]
        },
        "visualEditor.mobile.build": {
diff --git a/demos/ve/desktop.html b/demos/ve/desktop.html
index 143bce5..c6ac1ec 100644
--- a/demos/ve/desktop.html
+++ b/demos/ve/desktop.html
@@ -58,6 +58,10 @@
                <!-- visualEditor.desktop.build -->
                <link rel=stylesheet 
href="../../src/ui/styles/ve.ui.DesktopContext.css">
 
+               <!-- visualEditor.theme.apex -->
+               <link rel=stylesheet href="../../src/themes/apex/dialogs.css">
+               <link rel=stylesheet href="../../src/themes/apex/widgets.css">
+
                <!-- visualEditor.standalone.demo -->
                <link rel=stylesheet href="../../demos/ve/demo.css">
 
diff --git a/demos/ve/mobile.html b/demos/ve/mobile.html
index 2d1b523..d5f95e0 100644
--- a/demos/ve/mobile.html
+++ b/demos/ve/mobile.html
@@ -59,6 +59,10 @@
                <link rel=stylesheet 
href="../../src/ui/styles/ve.ui.MobileSurface.css">
                <link rel=stylesheet 
href="../../src/ui/styles/widgets/ve.ui.MobileContextOptionWidget.css">
 
+               <!-- visualEditor.theme.mediawiki -->
+               <link rel=stylesheet 
href="../../src/themes/mediawiki/dialogs.css">
+               <link rel=stylesheet 
href="../../src/themes/mediawiki/widgets.css">
+
                <!-- visualEditor.standalone.demo -->
                <link rel=stylesheet href="../../demos/ve/demo.css">
 
diff --git a/src/themes/apex/dialogs.css b/src/themes/apex/dialogs.css
new file mode 100644
index 0000000..744e526
--- /dev/null
+++ b/src/themes/apex/dialogs.css
@@ -0,0 +1,13 @@
+/*!
+ * VisualEditor Apex theme dialog customizations.
+ *
+ * @copyright 2011-2014 VisualEditor Team and others; see 
http://ve.mit-license.org
+ */
+
+/* ve.ui.FindAndReplaceDialog */
+
+.ve-ui-findAndReplaceDialog-focusedIndexLabel {
+       padding: 0.7em 0;
+       right: 1.4em;
+       color: #888;
+}
diff --git a/src/themes/apex/widgets.css b/src/themes/apex/widgets.css
new file mode 100644
index 0000000..33ae534
--- /dev/null
+++ b/src/themes/apex/widgets.css
@@ -0,0 +1,30 @@
+/*!
+ * VisualEditor Apex theme widget customizations.
+ *
+ * @copyright 2011-2014 VisualEditor Team and others; see 
http://ve.mit-license.org
+ */
+
+/* ve.ui.SurfaceWidget */
+
+.ve-ui-surfaceWidget-surface {
+       border: 1px solid #ddd;
+}
+
+.ve-ui-surfaceWidget-toolbar > .oo-ui-toolbar-bar {
+       border: 1px solid #ddd;
+       border-radius: 0.25em;
+       border-bottom-right-radius: 0;
+       border-bottom-left-radius: 0;
+       border-bottom-width: 0;
+}
+
+.ve-ui-surfaceWidget > .ve-ui-debugBar {
+       border: 1px solid #ddd;
+       border-top-width: 0;
+}
+
+.ve-ui-surfaceWidget > div:last-child {
+       border-radius: 0.25em;
+       border-top-right-radius: 0;
+       border-top-left-radius: 0;
+}
diff --git a/src/themes/mediawiki/dialogs.css b/src/themes/mediawiki/dialogs.css
new file mode 100644
index 0000000..104081c
--- /dev/null
+++ b/src/themes/mediawiki/dialogs.css
@@ -0,0 +1,13 @@
+/*!
+ * VisualEditor MediaWiki theme dialog customizations.
+ *
+ * @copyright 2011-2014 VisualEditor Team and others; see 
http://ve.mit-license.org
+ */
+
+/* ve.ui.FindAndReplaceDialog */
+
+.ve-ui-findAndReplaceDialog-focusedIndexLabel {
+       padding: 0.7em 0;
+       right: 1.4em;
+       color: #888;
+}
diff --git a/src/themes/mediawiki/widgets.css b/src/themes/mediawiki/widgets.css
new file mode 100644
index 0000000..879e588
--- /dev/null
+++ b/src/themes/mediawiki/widgets.css
@@ -0,0 +1,11 @@
+/*!
+ * VisualEditor MediaWiki theme widget customizations.
+ *
+ * @copyright 2011-2014 VisualEditor Team and others; see 
http://ve.mit-license.org
+ */
+
+/* ve.ui.SurfaceWidget */
+
+.ve-ui-surfaceWidget {
+       border: 1px solid #ccc;
+}
diff --git a/src/ui/styles/dialogs/ve.ui.FindAndReplaceDialog.css 
b/src/ui/styles/dialogs/ve.ui.FindAndReplaceDialog.css
index 6b3e9aa..9bf6d6b 100644
--- a/src/ui/styles/dialogs/ve.ui.FindAndReplaceDialog.css
+++ b/src/ui/styles/dialogs/ve.ui.FindAndReplaceDialog.css
@@ -36,8 +36,6 @@
 
 .ve-ui-findAndReplaceDialog-focusedIndexLabel {
        position: absolute;
-       right: 1.4em;
-       color: #888;
 }
 
 /* @noflip */
diff --git a/src/ui/styles/widgets/ve.ui.SurfaceWidget.css 
b/src/ui/styles/widgets/ve.ui.SurfaceWidget.css
index d480483..3e1039e 100644
--- a/src/ui/styles/widgets/ve.ui.SurfaceWidget.css
+++ b/src/ui/styles/widgets/ve.ui.SurfaceWidget.css
@@ -4,10 +4,6 @@
  * @copyright 2011-2014 VisualEditor Team and others; see 
http://ve.mit-license.org
  */
 
-.ve-ui-surfaceWidget-surface {
-       border: 1px solid #ddd;
-}
-
 .ve-ui-surfaceWidget-surface .ve-ce-documentNode {
        padding: 1.875em; /* 1.5/0.8 */
 }
@@ -16,22 +12,6 @@
        font-size: 1.25em;
 }
 
-.ve-ui-surfaceWidget-toolbar > .oo-ui-toolbar-bar {
-       border: 1px solid #ddd;
-       border-radius: 0.25em;
-       border-bottom-right-radius: 0;
-       border-bottom-left-radius: 0;
-       border-bottom-width: 0;
-}
-
 .ve-ui-surfaceWidget > .ve-ui-debugBar {
-       border: 1px solid #ddd;
-       border-top-width: 0;
        margin: 0;
 }
-
-.ve-ui-surfaceWidget > div:last-child {
-       border-radius: 0.25em;
-       border-top-right-radius: 0;
-       border-top-left-radius: 0;
-}
\ No newline at end of file

-- 
To view, visit https://gerrit.wikimedia.org/r/183151
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I903e55a892a72424c8857529021b3b3eeaaee295
Gerrit-PatchSet: 1
Gerrit-Project: VisualEditor/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Esanders <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to