Spage has uploaded a new change for review.
https://gerrit.wikimedia.org/r/69458
Change subject: Update to reflect mediawiki.ui in core.
......................................................................
Update to reflect mediawiki.ui in core.
Remove local copy of Compass scss source files (see
includes/resources/mediawiki.ui/sourcefiles instead);
Copy CSS from 1.22 core master.
Register same 'mediawiki.ui' CSS module as in 1.22 core, handle failures
in case core already declared the module.
Change-Id: I2c3143594a3249c71ce77b1218e4fa695ac4c4df
---
M Agora.hooks.php
M Agora.php
D Makefile
M README
D config.rb
M modules/css/mediawiki.ui.default.css
M modules/css/mediawiki.ui.vector.css
M modules/js/ext.agora.js
D modules/scss/components/_default.scss
D modules/scss/components/_utilities.scss
D modules/scss/components/_vector.scss
D modules/scss/components/default/_buttons.scss
D modules/scss/components/default/_forms.scss
D modules/scss/components/vector/_buttons.scss
D modules/scss/components/vector/_forms.scss
D modules/scss/mediawiki.ui.default.scss
D modules/scss/mediawiki.ui.vector.scss
D modules/scss/mixins/_all.scss
D modules/scss/mixins/_effects.scss
D modules/scss/mixins/_forms.scss
D modules/scss/mixins/_type.scss
D modules/scss/mixins/_utilities.scss
D modules/scss/settings/_all.scss
D modules/scss/settings/_colors.scss
D modules/scss/settings/_typography.scss
25 files changed, 143 insertions(+), 600 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Agora
refs/changes/58/69458/1
diff --git a/Agora.hooks.php b/Agora.hooks.php
index 55735ee..c632234 100644
--- a/Agora.hooks.php
+++ b/Agora.hooks.php
@@ -5,6 +5,30 @@
*/
class AgoraHooks {
+
+ /*
+ * Register the mediawiki.ui module. Not a hook function.
+ */
+ private static function doSetup( &$ctx ) {
+
+ // Try loading our local copy of mediawiki.ui ,
+ // but maybe core already has it if running on MW 1.22.
+ try {
+ $ctx->getResourceLoader()->register( 'mediawiki.ui',
+ array(
+ 'localBasePath' => __DIR__ . '/modules',
+ // XXX Unneeded? 'group' =>
'ext.agora.base',
+ 'skinStyles' => array(
+ 'default' =>
'css/mediawiki.ui.default.css',
+ 'vector' =>
'css/mediawiki.ui.vector.css',
+ ),
+ )
+ );
+ } catch (Exception $e) {
+ echo 'Caught exception: ', $e->getMessage(), "\n";
+ }
+ }
+
/**
* Adds Agora modules to the output.
*
@@ -22,7 +46,8 @@
// Check config for mode.
AgoraHooks::modeEnabled()
) {
- $output->addModules( array( 'ext.agora.base' ) );
+ self::doSetup( $output );
+ $res = $output->addModules( array( 'mediawiki.ui',
'ext.agora' ) );
}
return true;
}
diff --git a/Agora.php b/Agora.php
index 72f581f..a5b7262 100644
--- a/Agora.php
+++ b/Agora.php
@@ -1,38 +1,34 @@
<?php
-$localBasePath = dirname( __FILE__ );
-
$wgExtensionCredits['other'][] = array(
'path' => __FILE__,
'name' => 'Agora',
- 'version' => '0.0.1',
+ 'version' => '0.0.2',
'url' => 'https://www.mediawiki.org/wiki/Extension:Agora',
'author' => array( 'Rob Moen', 'Trevor Parscal', 'Munaf Assaf' ),
'descriptionmsg' => 'agora-desc'
);
// Hooks
-$wgAutoloadClasses['AgoraHooks'] = $localBasePath . '/Agora.hooks.php';
+
+$wgAutoloadClasses['AgoraHooks'] = __DIR__ . '/Agora.hooks.php';
+
+// Not needed if we do it in the function. $wgExtensionFunctions[] =
'AgoraHooks::doSetup';
$wgHooks['BeforePageDisplay'][] = 'AgoraHooks::onBeforePageDisplay';
//i18n
-$wgExtensionMessagesFiles['Agora'] = $localBasePath . '/Agora.i18n.php';
+$wgExtensionMessagesFiles['Agora'] = __DIR__ . '/Agora.i18n.php';
// Resource Template
$wgAgoraResourceTemplate = array(
- 'localBasePath' => $localBasePath . '/modules',
'remoteExtPath' => 'Agora/modules',
- 'group' => 'ext.agora.base',
+ // XXX Unneeded? 'group' => 'ext.agora.base',
);
$wgResourceModules += array(
- 'ext.agora.base' => $wgAgoraResourceTemplate + array(
+ 'ext.agora' => $wgAgoraResourceTemplate + array(
'scripts' => array(
- 'js/ext.agora.js',
- ),
- 'skinStyles' => array(
- 'default' => 'css/mediawiki.ui.default.css',
- 'vector' => 'css/mediawiki.ui.vector.css',
+ 'js/ext.agora',
),
'position' => 'top',
),
diff --git a/Makefile b/Makefile
deleted file mode 100644
index dea9013..0000000
--- a/Makefile
+++ /dev/null
@@ -1,24 +0,0 @@
-DATE=$(shell date +%I:%M%p)
-CHECK=\033[32m✔\033[39m
-HR=\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#
-
-build:
- @echo "\n${HR}"
- @echo "Building Agora..."
- @echo "${HR}\n"
- @compass compile
- @echo "Compiling Compass project... ${CHECK} Done"
- @rm -rf .sass-cache
- @echo "Removing .sass-cache... ${CHECK} Done"
- @echo "\n${HR}"
- @echo "Agora successfully built at ${DATE}."
- @echo "${HR}\n"
-
-all: build
-
-watch:
- @echo "\n${HR}"
- @echo "Watching SCSS files for Agora..."
- @echo "${HR}\n"
- @compass watch
- @echo "Started watching modules/scss at ${DATE}..."
diff --git a/README b/README
index 467a2c5..5811862 100644
--- a/README
+++ b/README
@@ -1,19 +1,12 @@
-# Agora extension adds new styles to MediaWiki
+# Agora extension adds new styles to MediaWiki and has some
+# utility JavaScript to enable them.
-# It is implemented in SASS and Compass. To convert the SASS to CSS, you will
need to:
+# The actual implementation of the CSS is in MediaWiki core starting with
release 1.22.
+# For earlier releases this extension has a copy of the CSS.
-Install compass. On Debian/Ubuntu, this is:
-
-sudo apt-get install ruby-compass
-
-Then, to build, run:
-
-make
-
-# To enable Agora on specific pages, please add them to the
$wgAgoraEnabledPages array.
-# To enable Agora on specific actions, please add them to the
$wgAgoraEnabledActions array.
+# To enable Agora on specific pages, add them to the $wgAgoraEnabledPages
array.
+# To enable Agora on specific actions, add them to the $wgAgoraEnabledActions
array.
# Enable Agora site-wide with $wgAgoraEnabledSiteWide = true;
-
# Example LocalSettings.php Configuration:
diff --git a/config.rb b/config.rb
deleted file mode 100644
index a5a229a..0000000
--- a/config.rb
+++ /dev/null
@@ -1,25 +0,0 @@
-# Require any additional compass plugins here.
-
-# Set this to the root of your project when deployed:
-http_path = "/"
-css_dir = "modules/css"
-sass_dir = "modules/scss"
-images_dir = "modules/img"
-javascripts_dir = "modules/js"
-
-# You can select your preferred output style here (can be overridden via the
command line):
-# output_style = :expanded or :nested or :compact or :compressed
-output_style = :expanded
-
-# To enable relative paths to assets via compass helper functions. Uncomment:
-relative_assets = true
-
-# To disable debugging comments that display the original location of your
selectors. Uncomment:
-line_comments = true
-
-
-# If you prefer the indented syntax, you might want to regenerate this
-# project again passing --syntax sass, or you can uncomment this:
-# preferred_syntax = :sass
-# and then run:
-# sass-convert -R --from scss --to sass sass scss && rm -rf sass && mv scss
sass
diff --git a/modules/css/mediawiki.ui.default.css
b/modules/css/mediawiki.ui.default.css
index 52d019e..810340c 100644
--- a/modules/css/mediawiki.ui.default.css
+++ b/modules/css/mediawiki.ui.default.css
@@ -6,28 +6,28 @@
*/
/* _effects.scss */
/* Mixins for visual effects in CSS3 */
-/* line 7, ../scss/components/_utilities.scss */
+/* line 7, sourcefiles/scss/components/_utilities.scss */
.mw-ui-flush-left {
float: left;
margin-left: 0;
padding-left: 0;
}
-/* line 11, ../scss/components/_utilities.scss */
+/* line 11, sourcefiles/scss/components/_utilities.scss */
.mw-ui-flush-right {
float: right;
margin-right: 0;
padding-right: 0;
}
-/* line 15, ../scss/components/_utilities.scss */
+/* line 15, sourcefiles/scss/components/_utilities.scss */
.mw-ui-center-block {
display: block;
margin-left: auto;
margin-right: auto;
}
-/* line 4, ../scss/components/default/_buttons.scss */
+/* line 4, sourcefiles/scss/components/default/_buttons.scss */
.mw-ui-button {
display: -moz-inline-stack;
display: inline-block;
@@ -60,7 +60,7 @@
font-weight: bold;
cursor: pointer;
}
-/* line 38, ../scss/mixins/_effects.scss */
+/* line 38, sourcefiles/scss/mixins/_effects.scss */
.mw-ui-button:hover, .mw-ui-button.mw-ui-hover {
background-color: gainsboro;
*background-color: gainsboro;
@@ -73,34 +73,39 @@
background-image: linear-gradient(top, #e9e9e9, #dcdcdc);
text-decoration: none;
}
-/* line 44, ../scss/mixins/_effects.scss */
+/* line 44, sourcefiles/scss/mixins/_effects.scss */
.mw-ui-button:active, .mw-ui-button.mw-ui-active {
background-image: none;
background-color: #c1c1c1;
text-shadow: none;
}
-/* line 54, ../scss/mixins/_effects.scss */
+/* line 54, sourcefiles/scss/mixins/_effects.scss */
.mw-ui-button:disabled, .mw-ui-button.mw-ui-disabled {
background-image: none;
background-color: #c9c9c9;
opacity: 0.5;
text-shadow: none;
}
-/* line 30, ../scss/components/default/_buttons.scss */
+/* line 30, sourcefiles/scss/components/default/_buttons.scss */
.mw-ui-button:disabled, .mw-ui-button.mw-ui-disabled {
cursor: default;
}
-/* line 36, ../scss/components/default/_buttons.scss */
+/* line 36, sourcefiles/scss/components/default/_buttons.scss */
.mw-ui-button.mw-ui-big {
font-size: 1.3em;
}
-/* line 41, ../scss/components/default/_buttons.scss */
+/* line 41, sourcefiles/scss/components/default/_buttons.scss */
.mw-ui-button.mw-ui-block {
display: block;
width: 100%;
}
-/* line 48, ../scss/components/default/_buttons.scss */
+/* line 49, sourcefiles/scss/components/default/_buttons.scss */
+a.mw-ui-button {
+ text-decoration: none;
+}
+
+/* line 56, sourcefiles/scss/components/default/_buttons.scss */
.mw-ui-button-group > * {
-webkit-border-radius: 0;
-moz-border-radius: 0;
@@ -109,7 +114,7 @@
border-radius: 0;
float: left;
}
-/* line 52, ../scss/components/default/_buttons.scss */
+/* line 60, sourcefiles/scss/components/default/_buttons.scss */
.mw-ui-button-group > *:first-child {
-moz-border-radius-topleft: 3px;
-webkit-border-top-left-radius: 3px;
@@ -118,7 +123,7 @@
-webkit-border-bottom-left-radius: 3px;
border-bottom-left-radius: 3px;
}
-/* line 57, ../scss/components/default/_buttons.scss */
+/* line 65, sourcefiles/scss/components/default/_buttons.scss */
.mw-ui-button-group > *:last-child {
-moz-border-radius-topright: 3px;
-webkit-border-top-right-radius: 3px;
@@ -128,23 +133,22 @@
border-bottom-right-radius: 3px;
}
-/* line 12, ../scss/components/default/_forms.scss */
+/* line 14, sourcefiles/scss/components/default/_forms.scss */
.mw-ui-vform {
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
width: 290px;
}
-/* line 17, ../scss/components/default/_forms.scss */
+/* line 19, sourcefiles/scss/components/default/_forms.scss */
.mw-ui-vform > div {
display: block;
margin: 0 0 15px 0;
padding: 0;
width: 100%;
}
-/* line 26, ../scss/components/default/_forms.scss */
+/* line 27, sourcefiles/scss/components/default/_forms.scss */
.mw-ui-vform > div input,
-.mw-ui-vform > div label,
.mw-ui-vform > div .mw-ui-button {
display: block;
-webkit-box-sizing: border-box;
@@ -153,7 +157,7 @@
margin: 0;
width: 100%;
}
-/* line 33, ../scss/components/default/_forms.scss */
+/* line 34, sourcefiles/scss/components/default/_forms.scss */
.mw-ui-vform > div input {
outline: 0;
border-style: solid;
@@ -162,45 +166,28 @@
color: #252525;
padding: 0.35em 0 0.35em 0.5em;
}
-/* line 12, ../scss/mixins/_forms.scss */
+/* line 12, sourcefiles/scss/mixins/_forms.scss */
.mw-ui-vform > div input:focus {
- -webkit-box-shadow: #4091ed 0px 0px 5px;
- -moz-box-shadow: #4091ed 0px 0px 5px;
box-shadow: #4091ed 0px 0px 5px;
border-color: #4091ed;
}
-/* line 37, ../scss/components/default/_forms.scss */
+/* line 38, sourcefiles/scss/components/default/_forms.scss */
.mw-ui-vform > div label {
+ display: block;
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
font-size: 0.9em;
- color: #7d7d7d;
+ color: #4a4a4a;
width: auto;
margin: 0 0 0.2em 0;
padding: 0;
}
-/* line 31, ../scss/mixins/_forms.scss */
+/* line 34, sourcefiles/scss/mixins/_forms.scss */
.mw-ui-vform > div label * {
font-weight: normal;
}
-/* line 44, ../scss/components/default/_forms.scss */
-.mw-ui-vform > div label.mw-ui-checkbox-label, .mw-ui-vform > div
label.mw-ui-radio-label {
- margin-bottom: 0.5em;
- cursor: pointer;
- vertical-align: bottom;
- line-height: normal;
- font-weight: normal;
-}
-/* line 47, ../scss/mixins/_forms.scss */
-.mw-ui-vform > div label.mw-ui-checkbox-label > input[type="checkbox"],
.mw-ui-vform > div label.mw-ui-checkbox-label > input[type="radio"],
.mw-ui-vform > div label.mw-ui-radio-label > input[type="checkbox"],
.mw-ui-vform > div label.mw-ui-radio-label > input[type="radio"] {
- width: auto;
- height: auto;
- margin: 0 0.1em 0em 0;
- padding: 0;
- border-style: solid;
- border-width: 1px;
- border-color: #c9c9c9;
- cursor: pointer;
-}
-/* line 51, ../scss/components/default/_forms.scss */
+/* line 49, sourcefiles/scss/components/default/_forms.scss */
.mw-ui-vform > div input[type="checkbox"],
.mw-ui-vform > div input[type="radio"] {
display: inline;
@@ -210,7 +197,7 @@
width: auto;
}
-/* line 66, ../scss/components/default/_forms.scss */
+/* line 65, sourcefiles/scss/components/default/_forms.scss */
.mw-ui-input {
outline: 0;
border-style: solid;
@@ -219,25 +206,23 @@
color: #252525;
padding: 0.35em 0 0.35em 0.5em;
}
-/* line 12, ../scss/mixins/_forms.scss */
+/* line 12, sourcefiles/scss/mixins/_forms.scss */
.mw-ui-input:focus {
- -webkit-box-shadow: #4091ed 0px 0px 5px;
- -moz-box-shadow: #4091ed 0px 0px 5px;
box-shadow: #4091ed 0px 0px 5px;
border-color: #4091ed;
}
-/* line 71, ../scss/components/default/_forms.scss */
-.mw-ui-block-label, .mw-ui-formlist div label {
+/* line 72, sourcefiles/scss/components/default/_forms.scss */
+.mw-ui-label {
font-size: 0.9em;
- color: #7d7d7d;
+ color: #4a4a4a;
}
-/* line 31, ../scss/mixins/_forms.scss */
-.mw-ui-block-label *, .mw-ui-formlist div label * {
+/* line 34, sourcefiles/scss/mixins/_forms.scss */
+.mw-ui-label * {
font-weight: normal;
}
-/* line 80, ../scss/components/default/_forms.scss */
+/* line 81, sourcefiles/scss/components/default/_forms.scss */
.mw-ui-checkbox-label, .mw-ui-radio-label {
margin-bottom: 0.5em;
cursor: pointer;
@@ -245,7 +230,7 @@
line-height: normal;
font-weight: normal;
}
-/* line 47, ../scss/mixins/_forms.scss */
+/* line 50, sourcefiles/scss/mixins/_forms.scss */
.mw-ui-checkbox-label > input[type="checkbox"], .mw-ui-checkbox-label >
input[type="radio"], .mw-ui-radio-label > input[type="checkbox"],
.mw-ui-radio-label > input[type="radio"] {
width: auto;
height: auto;
diff --git a/modules/css/mediawiki.ui.vector.css
b/modules/css/mediawiki.ui.vector.css
index 39c3786..5f03376 100644
--- a/modules/css/mediawiki.ui.vector.css
+++ b/modules/css/mediawiki.ui.vector.css
@@ -5,28 +5,28 @@
*/
/* _effects.scss */
/* Mixins for visual effects in CSS3 */
-/* line 7, ../scss/components/_utilities.scss */
+/* line 7, sourcefiles/scss/components/_utilities.scss */
.mw-ui-flush-left {
float: left;
margin-left: 0;
padding-left: 0;
}
-/* line 11, ../scss/components/_utilities.scss */
+/* line 11, sourcefiles/scss/components/_utilities.scss */
.mw-ui-flush-right {
float: right;
margin-right: 0;
padding-right: 0;
}
-/* line 15, ../scss/components/_utilities.scss */
+/* line 15, sourcefiles/scss/components/_utilities.scss */
.mw-ui-center-block {
display: block;
margin-left: auto;
margin-right: auto;
}
-/* line 4, ../scss/components/default/_buttons.scss */
+/* line 4, sourcefiles/scss/components/default/_buttons.scss */
.mw-ui-button {
display: -moz-inline-stack;
display: inline-block;
@@ -59,7 +59,7 @@
font-weight: bold;
cursor: pointer;
}
-/* line 38, ../scss/mixins/_effects.scss */
+/* line 38, sourcefiles/scss/mixins/_effects.scss */
.mw-ui-button:hover, .mw-ui-button.mw-ui-hover {
background-color: gainsboro;
*background-color: gainsboro;
@@ -72,34 +72,39 @@
background-image: linear-gradient(top, #e9e9e9, #dcdcdc);
text-decoration: none;
}
-/* line 44, ../scss/mixins/_effects.scss */
+/* line 44, sourcefiles/scss/mixins/_effects.scss */
.mw-ui-button:active, .mw-ui-button.mw-ui-active {
background-image: none;
background-color: #c1c1c1;
text-shadow: none;
}
-/* line 54, ../scss/mixins/_effects.scss */
+/* line 54, sourcefiles/scss/mixins/_effects.scss */
.mw-ui-button:disabled, .mw-ui-button.mw-ui-disabled {
background-image: none;
background-color: #c9c9c9;
opacity: 0.5;
text-shadow: none;
}
-/* line 30, ../scss/components/default/_buttons.scss */
+/* line 30, sourcefiles/scss/components/default/_buttons.scss */
.mw-ui-button:disabled, .mw-ui-button.mw-ui-disabled {
cursor: default;
}
-/* line 36, ../scss/components/default/_buttons.scss */
+/* line 36, sourcefiles/scss/components/default/_buttons.scss */
.mw-ui-button.mw-ui-big {
font-size: 1.3em;
}
-/* line 41, ../scss/components/default/_buttons.scss */
+/* line 41, sourcefiles/scss/components/default/_buttons.scss */
.mw-ui-button.mw-ui-block {
display: block;
width: 100%;
}
-/* line 48, ../scss/components/default/_buttons.scss */
+/* line 49, sourcefiles/scss/components/default/_buttons.scss */
+a.mw-ui-button {
+ text-decoration: none;
+}
+
+/* line 56, sourcefiles/scss/components/default/_buttons.scss */
.mw-ui-button-group > * {
-webkit-border-radius: 0;
-moz-border-radius: 0;
@@ -108,7 +113,7 @@
border-radius: 0;
float: left;
}
-/* line 52, ../scss/components/default/_buttons.scss */
+/* line 60, sourcefiles/scss/components/default/_buttons.scss */
.mw-ui-button-group > *:first-child {
-moz-border-radius-topleft: 3px;
-webkit-border-top-left-radius: 3px;
@@ -117,7 +122,7 @@
-webkit-border-bottom-left-radius: 3px;
border-bottom-left-radius: 3px;
}
-/* line 57, ../scss/components/default/_buttons.scss */
+/* line 65, sourcefiles/scss/components/default/_buttons.scss */
.mw-ui-button-group > *:last-child {
-moz-border-radius-topright: 3px;
-webkit-border-top-right-radius: 3px;
@@ -127,13 +132,13 @@
border-bottom-right-radius: 3px;
}
-/* line 3, ../scss/components/vector/_buttons.scss */
+/* line 3, sourcefiles/scss/components/vector/_buttons.scss */
.mw-ui-button {
font-family: "Helvetica Neue", "Helvetica", "Arial", sans-serif;
font-size: 1em;
line-height: 1.4em;
}
-/* line 6, ../scss/components/vector/_buttons.scss */
+/* line 6, sourcefiles/scss/components/vector/_buttons.scss */
.mw-ui-button.mw-ui-primary {
background-color: #3366bb;
*background-color: #3366bb;
@@ -148,7 +153,7 @@
text-shadow: 0 1px 1px rgba(51, 102, 187, 0.75);
border: 1px solid #3162b3;
}
-/* line 38, ../scss/mixins/_effects.scss */
+/* line 38, sourcefiles/scss/mixins/_effects.scss */
.mw-ui-button.mw-ui-primary:hover, .mw-ui-button.mw-ui-primary.mw-ui-hover {
background-color: #4779cd;
*background-color: #4779cd;
@@ -161,20 +166,20 @@
background-image: linear-gradient(top, #5b88d2, #4779cd);
text-decoration: none;
}
-/* line 44, ../scss/mixins/_effects.scss */
+/* line 44, sourcefiles/scss/mixins/_effects.scss */
.mw-ui-button.mw-ui-primary:active, .mw-ui-button.mw-ui-primary.mw-ui-active {
background-image: none;
background-color: #305faf;
text-shadow: none;
}
-/* line 54, ../scss/mixins/_effects.scss */
+/* line 54, sourcefiles/scss/mixins/_effects.scss */
.mw-ui-button.mw-ui-primary:disabled,
.mw-ui-button.mw-ui-primary.mw-ui-disabled {
background-image: none;
background-color: #3366bb;
opacity: 0.5;
text-shadow: none;
}
-/* line 10, ../scss/components/vector/_buttons.scss */
+/* line 10, sourcefiles/scss/components/vector/_buttons.scss */
.mw-ui-button.mw-ui-constructive {
background-color: #27aa65;
*background-color: #27aa65;
@@ -189,7 +194,7 @@
text-shadow: 0 1px 1px rgba(39, 170, 101, 0.75);
border: 1px solid #25a260;
}
-/* line 38, ../scss/mixins/_effects.scss */
+/* line 38, sourcefiles/scss/mixins/_effects.scss */
.mw-ui-button.mw-ui-constructive:hover,
.mw-ui-button.mw-ui-constructive.mw-ui-hover {
background-color: #2ec977;
*background-color: #2ec977;
@@ -202,20 +207,20 @@
background-image: linear-gradient(top, #3ed384, #2ec977);
text-decoration: none;
}
-/* line 44, ../scss/mixins/_effects.scss */
+/* line 44, sourcefiles/scss/mixins/_effects.scss */
.mw-ui-button.mw-ui-constructive:active,
.mw-ui-button.mw-ui-constructive.mw-ui-active {
background-image: none;
background-color: #249e5e;
text-shadow: none;
}
-/* line 54, ../scss/mixins/_effects.scss */
+/* line 54, sourcefiles/scss/mixins/_effects.scss */
.mw-ui-button.mw-ui-constructive:disabled,
.mw-ui-button.mw-ui-constructive.mw-ui-disabled {
background-image: none;
background-color: #27aa65;
opacity: 0.5;
text-shadow: none;
}
-/* line 14, ../scss/components/vector/_buttons.scss */
+/* line 14, sourcefiles/scss/components/vector/_buttons.scss */
.mw-ui-button.mw-ui-destructive {
background-color: #cc0000;
*background-color: #cc0000;
@@ -230,7 +235,7 @@
text-shadow: 0 1px 1px rgba(204, 0, 0, 0.75);
border: 1px solid #c20000;
}
-/* line 38, ../scss/mixins/_effects.scss */
+/* line 38, sourcefiles/scss/mixins/_effects.scss */
.mw-ui-button.mw-ui-destructive:hover,
.mw-ui-button.mw-ui-destructive.mw-ui-hover {
background-color: #f20000;
*background-color: #f20000;
@@ -243,13 +248,13 @@
background-image: linear-gradient(top, #ff0d0d, #f20000);
text-decoration: none;
}
-/* line 44, ../scss/mixins/_effects.scss */
+/* line 44, sourcefiles/scss/mixins/_effects.scss */
.mw-ui-button.mw-ui-destructive:active,
.mw-ui-button.mw-ui-destructive.mw-ui-active {
background-image: none;
background-color: #bd0000;
text-shadow: none;
}
-/* line 54, ../scss/mixins/_effects.scss */
+/* line 54, sourcefiles/scss/mixins/_effects.scss */
.mw-ui-button.mw-ui-destructive:disabled,
.mw-ui-button.mw-ui-destructive.mw-ui-disabled {
background-image: none;
background-color: #cc0000;
@@ -257,23 +262,22 @@
text-shadow: none;
}
-/* line 12, ../scss/components/default/_forms.scss */
+/* line 14, sourcefiles/scss/components/default/_forms.scss */
.mw-ui-vform {
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
width: 290px;
}
-/* line 17, ../scss/components/default/_forms.scss */
+/* line 19, sourcefiles/scss/components/default/_forms.scss */
.mw-ui-vform > div {
display: block;
margin: 0 0 15px 0;
padding: 0;
width: 100%;
}
-/* line 26, ../scss/components/default/_forms.scss */
+/* line 27, sourcefiles/scss/components/default/_forms.scss */
.mw-ui-vform > div input,
-.mw-ui-vform > div label,
.mw-ui-vform > div .mw-ui-button {
display: block;
-webkit-box-sizing: border-box;
@@ -282,7 +286,7 @@
margin: 0;
width: 100%;
}
-/* line 33, ../scss/components/default/_forms.scss */
+/* line 34, sourcefiles/scss/components/default/_forms.scss */
.mw-ui-vform > div input {
outline: 0;
border-style: solid;
@@ -291,45 +295,28 @@
color: #252525;
padding: 0.35em 0 0.35em 0.5em;
}
-/* line 12, ../scss/mixins/_forms.scss */
+/* line 12, sourcefiles/scss/mixins/_forms.scss */
.mw-ui-vform > div input:focus {
- -webkit-box-shadow: #4091ed 0px 0px 5px;
- -moz-box-shadow: #4091ed 0px 0px 5px;
box-shadow: #4091ed 0px 0px 5px;
border-color: #4091ed;
}
-/* line 37, ../scss/components/default/_forms.scss */
+/* line 38, sourcefiles/scss/components/default/_forms.scss */
.mw-ui-vform > div label {
+ display: block;
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
font-size: 0.9em;
- color: #7d7d7d;
+ color: #4a4a4a;
width: auto;
margin: 0 0 0.2em 0;
padding: 0;
}
-/* line 31, ../scss/mixins/_forms.scss */
+/* line 34, sourcefiles/scss/mixins/_forms.scss */
.mw-ui-vform > div label * {
font-weight: normal;
}
-/* line 44, ../scss/components/default/_forms.scss */
-.mw-ui-vform > div label.mw-ui-checkbox-label, .mw-ui-vform > div
label.mw-ui-radio-label {
- margin-bottom: 0.5em;
- cursor: pointer;
- vertical-align: bottom;
- line-height: normal;
- font-weight: normal;
-}
-/* line 47, ../scss/mixins/_forms.scss */
-.mw-ui-vform > div label.mw-ui-checkbox-label > input[type="checkbox"],
.mw-ui-vform > div label.mw-ui-checkbox-label > input[type="radio"],
.mw-ui-vform > div label.mw-ui-radio-label > input[type="checkbox"],
.mw-ui-vform > div label.mw-ui-radio-label > input[type="radio"] {
- width: auto;
- height: auto;
- margin: 0 0.1em 0em 0;
- padding: 0;
- border-style: solid;
- border-width: 1px;
- border-color: #c9c9c9;
- cursor: pointer;
-}
-/* line 51, ../scss/components/default/_forms.scss */
+/* line 49, sourcefiles/scss/components/default/_forms.scss */
.mw-ui-vform > div input[type="checkbox"],
.mw-ui-vform > div input[type="radio"] {
display: inline;
@@ -339,7 +326,7 @@
width: auto;
}
-/* line 66, ../scss/components/default/_forms.scss */
+/* line 65, sourcefiles/scss/components/default/_forms.scss */
.mw-ui-input {
outline: 0;
border-style: solid;
@@ -348,25 +335,23 @@
color: #252525;
padding: 0.35em 0 0.35em 0.5em;
}
-/* line 12, ../scss/mixins/_forms.scss */
+/* line 12, sourcefiles/scss/mixins/_forms.scss */
.mw-ui-input:focus {
- -webkit-box-shadow: #4091ed 0px 0px 5px;
- -moz-box-shadow: #4091ed 0px 0px 5px;
box-shadow: #4091ed 0px 0px 5px;
border-color: #4091ed;
}
-/* line 71, ../scss/components/default/_forms.scss */
-.mw-ui-block-label, .mw-ui-formlist div label {
+/* line 72, sourcefiles/scss/components/default/_forms.scss */
+.mw-ui-label {
font-size: 0.9em;
- color: #7d7d7d;
+ color: #4a4a4a;
}
-/* line 31, ../scss/mixins/_forms.scss */
-.mw-ui-block-label *, .mw-ui-formlist div label * {
+/* line 34, sourcefiles/scss/mixins/_forms.scss */
+.mw-ui-label * {
font-weight: normal;
}
-/* line 80, ../scss/components/default/_forms.scss */
+/* line 81, sourcefiles/scss/components/default/_forms.scss */
.mw-ui-checkbox-label, .mw-ui-radio-label {
margin-bottom: 0.5em;
cursor: pointer;
@@ -374,7 +359,7 @@
line-height: normal;
font-weight: normal;
}
-/* line 47, ../scss/mixins/_forms.scss */
+/* line 50, sourcefiles/scss/mixins/_forms.scss */
.mw-ui-checkbox-label > input[type="checkbox"], .mw-ui-checkbox-label >
input[type="radio"], .mw-ui-radio-label > input[type="checkbox"],
.mw-ui-radio-label > input[type="radio"] {
width: auto;
height: auto;
@@ -386,7 +371,7 @@
cursor: pointer;
}
-/* line 5, ../scss/components/vector/_forms.scss */
+/* line 5, sourcefiles/scss/components/vector/_forms.scss */
.mw-ui-vform,
.mw-ui-vform > div input,
.mw-ui-input {
@@ -394,3 +379,10 @@
font-size: 1em;
line-height: 1.4em;
}
+
+/* line 3, sourcefiles/scss/components/vector/_containers.scss */
+.mw-ui-container {
+ font-family: "Helvetica Neue", "Helvetica", "Arial", sans-serif;
+ font-size: 1em;
+ line-height: 1.4em;
+}
diff --git a/modules/js/ext.agora.js b/modules/js/ext.agora.js
index a9236df..d414883 100644
--- a/modules/js/ext.agora.js
+++ b/modules/js/ext.agora.js
@@ -1,4 +1,4 @@
/* Manually add mw-ui-button class to every submit input. */
jQuery( function () {
- //$( 'input[type="submit"]' ).addClass( 'mw-ui-button' );
+ $( 'input[type="submit"]' ).addClass( 'mw-ui-button' );
} );
diff --git a/modules/scss/components/_default.scss
b/modules/scss/components/_default.scss
deleted file mode 100644
index e7090eb..0000000
--- a/modules/scss/components/_default.scss
+++ /dev/null
@@ -1,3 +0,0 @@
-@import "utilities";
-@import "default/buttons";
-@import "default/forms";
\ No newline at end of file
diff --git a/modules/scss/components/_utilities.scss
b/modules/scss/components/_utilities.scss
deleted file mode 100644
index 4f1dba2..0000000
--- a/modules/scss/components/_utilities.scss
+++ /dev/null
@@ -1,17 +0,0 @@
-// Generic helper classes that could be used in many elements/layouts
-
-// --------------------------------------------------------------------------
-// Positioning
-// --------------------------------------------------------------------------
-
-.mw-ui-flush-left {
- @include agora-flush-left;
-}
-
-.mw-ui-flush-right {
- @include agora-flush-right;
-}
-
-.mw-ui-center-block {
- @include agora-center-block;
-}
\ No newline at end of file
diff --git a/modules/scss/components/_vector.scss
b/modules/scss/components/_vector.scss
deleted file mode 100644
index e52a1ed..0000000
--- a/modules/scss/components/_vector.scss
+++ /dev/null
@@ -1,3 +0,0 @@
-@import "utilities";
-@import "vector/buttons";
-@import "vector/forms";
\ No newline at end of file
diff --git a/modules/scss/components/default/_buttons.scss
b/modules/scss/components/default/_buttons.scss
deleted file mode 100644
index 1ea9a18..0000000
--- a/modules/scss/components/default/_buttons.scss
+++ /dev/null
@@ -1,61 +0,0 @@
-$buttonBorderRadius: 3px;
-
-// Button styling
-.mw-ui-button {
- // Container layout
- @include inline-block;
- padding: 0.4em 1em 0.4em 1em;
- margin: 0;
-
- // Container styling
- @include buttonColors($agoraGray);
- @include border-radius($buttonBorderRadius);
-
- // Content styling
- vertical-align: middle;
-
- text: {
- align: center;
- decoration: none;
- }
-
- font: {
- weight: bold;
- }
-
- // Interaction styling
- cursor: pointer;
-
- &:disabled,
- &.mw-ui-disabled {
- cursor: default;
- }
-
- // Button sizes and displays
- // -----------------------------------------
- &.mw-ui-big {
- font: {
- size: $baseFontSize * 1.3;
- }
- }
- &.mw-ui-block {
- display: block;
- width: 100%;
- }
-}
-
-// Button groups
-.mw-ui-button-group > * {
- @include border-radius(0);
- float: left;
-
- &:first-child{
- @include border-top-left-radius($buttonBorderRadius);
- @include border-bottom-left-radius($buttonBorderRadius);
- }
-
- &:last-child{
- @include border-top-right-radius($buttonBorderRadius);
- @include border-bottom-right-radius($buttonBorderRadius);
- }
-}
diff --git a/modules/scss/components/default/_forms.scss
b/modules/scss/components/default/_forms.scss
deleted file mode 100644
index 440669e..0000000
--- a/modules/scss/components/default/_forms.scss
+++ /dev/null
@@ -1,82 +0,0 @@
-// Form elements and layouts
-
-// --------------------------------------------------------------------------
-// Layouts
-// --------------------------------------------------------------------------
-
-// The FancyCaptcha image CAPTCHA used on WMF wikis drives the width of the
-// 'vform' stacked div design, the form can't be narrower than this.
-$captchaContainerWidth: 290px;
-$defaultFormWidth: $captchaContainerWidth;
-
-.mw-ui-vform {
- @include box-sizing(border-box);
-
- width: $defaultFormWidth;
-
- & > div {
- display: block;
- margin: 0 0 15px 0;
- padding: 0;
- width: 100%;
-
- // MW currently doesn't use the type attribute everywhere on inputs
- input,
- label,
- .mw-ui-button {
- display: block;
- @include box-sizing(border-box);
- margin: 0;
- width: 100%;
- }
-
- input {
- @include agora-field-styling; // mixins/_forms.scss
- }
-
- label {
- @include agora-label-styling;
-
- width: auto;
- margin: 0 0 0.2em 0;
- padding: 0;
-
- &.mw-ui-checkbox-label, &.mw-ui-radio-label {
- @include agora-inline-label-styling;
- }
- }
-
- // Override the above styling just for checkboxes and radio inputs
- input[type="checkbox"],
- input[type="radio"] {
- display: inline;
- @include box-sizing(content-box);
- width: auto;
- }
-
- }
-}
-
-// --------------------------------------------------------------------------
-// Elements
-// --------------------------------------------------------------------------
-
-// Apply mw-ui-input to fields individually to style them
-// You don't need to use this if <input> is within a Agora form container
-.mw-ui-input {
- @include agora-field-styling; // mixins/_forms.scss
-}
-
-// Default label styling is mw-ui-block-label
-.mw-ui-block-label, .mw-ui-formlist div label {
- @include agora-label-styling; // mixins/_forms.scss
-}
-
-// Checkbox and radio button label alignment hack
-// <label class="mw-ui-checkbox-label">
-// <input type="checkbox" />Label
-// </label>
-
-.mw-ui-checkbox-label, .mw-ui-radio-label {
- @include agora-inline-label-styling;
-}
diff --git a/modules/scss/components/vector/_buttons.scss
b/modules/scss/components/vector/_buttons.scss
deleted file mode 100644
index 8d5f0b6..0000000
--- a/modules/scss/components/vector/_buttons.scss
+++ /dev/null
@@ -1,19 +0,0 @@
-@import "../default/buttons"; // Layer Vector on top of the default settings.
-
-.mw-ui-button {
- // Button colors determined by function.
- // -----------------------------------------
- &.mw-ui-primary {
- @include buttonColors($agoraBlue);
- }
-
- &.mw-ui-constructive {
- @include buttonColors($agoraGreen);
- }
-
- &.mw-ui-destructive {
- @include buttonColors($agoraRed);
- }
-
- @include vector-type;
-}
diff --git a/modules/scss/components/vector/_forms.scss
b/modules/scss/components/vector/_forms.scss
deleted file mode 100644
index 73ea24e..0000000
--- a/modules/scss/components/vector/_forms.scss
+++ /dev/null
@@ -1,7 +0,0 @@
-@import "../default/forms"; // Layer Vector on top of the default settings.
-
-.mw-ui-vform,
-.mw-ui-vform > div input,
-.mw-ui-input {
- @include vector-type;
-}
diff --git a/modules/scss/mediawiki.ui.default.scss
b/modules/scss/mediawiki.ui.default.scss
deleted file mode 100644
index e6db523..0000000
--- a/modules/scss/mediawiki.ui.default.scss
+++ /dev/null
@@ -1,16 +0,0 @@
-/**
- * Provide Agora appearance for mw-ui-* classes when using a skin other than
- * Vector.
- * Compass builds these Agora styles from source Sass files in
- * extensions/Agora/modules/scss
- */
-
-@charset "UTF-8";
-
-@import "compass";
-
-@import "settings/all";
-
-@import "mixins/all";
-
-@import "components/default";
diff --git a/modules/scss/mediawiki.ui.vector.scss
b/modules/scss/mediawiki.ui.vector.scss
deleted file mode 100644
index ac113ee..0000000
--- a/modules/scss/mediawiki.ui.vector.scss
+++ /dev/null
@@ -1,15 +0,0 @@
-/**
- * Provide Agora appearance for mw-ui-* classes when using the Vector skin.
- * Compass builds these Agora styles from source Sass files in
- * extensions/Agora/modules/scss
- */
-
-@charset "UTF-8";
-
-@import "compass";
-
-@import "settings/all";
-
-@import "mixins/all";
-
-@import "components/vector";
diff --git a/modules/scss/mixins/_all.scss b/modules/scss/mixins/_all.scss
deleted file mode 100644
index adc48cd..0000000
--- a/modules/scss/mixins/_all.scss
+++ /dev/null
@@ -1,4 +0,0 @@
-@import "utilities";
-@import "type";
-@import "effects";
-@import "forms";
\ No newline at end of file
diff --git a/modules/scss/mixins/_effects.scss
b/modules/scss/mixins/_effects.scss
deleted file mode 100644
index 00226cb..0000000
--- a/modules/scss/mixins/_effects.scss
+++ /dev/null
@@ -1,62 +0,0 @@
-/* _effects.scss */
-
-/* Mixins for visual effects in CSS3 */
-
-// ----------------------------------------------------------------------------
-// Gradients
-// ----------------------------------------------------------------------------
-@mixin vertical-gradient ($startColor: lighten($agoraGray, 95%), $endColor:
$agoraGray) {
- // Fallback
- background-color: $endColor;
- *background-color: $endColor; // IE7
-
- // IE6-8
- @include filter-gradient($startColor, $endColor, vertical);
-
- // IE9+, Opera, Gecko, WebKit
- @include background-image(linear-gradient(top, $startColor, $endColor));
-}
-
-// ----------------------------------------------------------------------------
-// Button styling
-// ----------------------------------------------------------------------------
-@mixin buttonColors ($baseColor: $agoraGray) {
- // Background color
- @include vertical-gradient(lighten($baseColor, 7.5%), $baseColor);
-
- @if $baseColor == $agoraGray {
- color: darken($baseColor, 50%);
- @include text-shadow(0 1px 1px rgba($baseColor, 0.3));
- } @else {
- color: white;
- @include text-shadow(0 1px 1px rgba($baseColor, 0.75));
- }
-
- border: 1px solid darken($baseColor, 2%);
-
- &:hover,
- &.mw-ui-hover {
- @include vertical-gradient(lighten($baseColor, 12.5%),
lighten($baseColor, 7.5%));
- text-decoration: none;
- }
-
- &:active,
- &.mw-ui-active {
- background: {
- image: none;
- color: darken($baseColor, 3%);
- }
-
- text-shadow: none;
- }
-
- &:disabled,
- &.mw-ui-disabled {
- background: {
- image: none;
- color: $baseColor;
- }
- opacity: 0.5;
- text-shadow: none;
- }
-}
diff --git a/modules/scss/mixins/_forms.scss b/modules/scss/mixins/_forms.scss
deleted file mode 100644
index ee9089d..0000000
--- a/modules/scss/mixins/_forms.scss
+++ /dev/null
@@ -1,59 +0,0 @@
-// Font is not included.
-// For Vector, that should be layered on top with vector-type
-@mixin agora-field-styling() {
- @include reset-focus; // Removes OS field focus
-
- border: {
- style: solid;
- width: 1px;
- color: $agoraGray;
- };
-
- &:focus {
- @include box-shadow($agoraBlueShadow 0px 0px 5px);
-
- border: {
- color: $agoraBlueShadow;
- };
- }
-
- color: $agoraTextColor;
- padding: 0.35em 0 0.35em 0.5em;
-}
-
-@mixin agora-label-styling() {
- font: {
- //weight: bold;
- size: 0.9em;
- };
- color: darken($agoraGray, 30%);
-
- & * {
- font-weight: normal;
- }
-}
-
-@mixin agora-inline-label-styling() {
- margin-bottom: 0.5em;
- cursor: pointer;
- vertical-align: bottom;
- line-height: normal;
-
- font: {
- weight: normal;
- };
-
- & > input[type="checkbox"],
- & > input[type="radio"] {
- width: auto;
- height: auto;
- margin: 0 0.1em 0em 0;
- padding: 0;
- border: {
- style: solid;
- width: 1px;
- color: $agoraGray;
- }
- cursor: pointer;
- }
-}
\ No newline at end of file
diff --git a/modules/scss/mixins/_type.scss b/modules/scss/mixins/_type.scss
deleted file mode 100644
index 964d590..0000000
--- a/modules/scss/mixins/_type.scss
+++ /dev/null
@@ -1,7 +0,0 @@
-@mixin vector-type {
- font: {
- family: $baseFontFamily;
- size: $baseFontSize;
- }
- line-height: $baseLineHeight;
-}
\ No newline at end of file
diff --git a/modules/scss/mixins/_utilities.scss
b/modules/scss/mixins/_utilities.scss
deleted file mode 100644
index 71a93b6..0000000
--- a/modules/scss/mixins/_utilities.scss
+++ /dev/null
@@ -1,19 +0,0 @@
-@mixin agora-flush-left() {
- float: left;
- margin-left: 0;
- padding-left: 0;
-}
-
-@mixin agora-flush-right() {
- float: right;
- margin-right: 0;
- padding-right: 0;
-}
-
-@mixin agora-center-block() {
- display: block;
- margin: {
- left: auto;
- right: auto;
- };
-}
\ No newline at end of file
diff --git a/modules/scss/settings/_all.scss b/modules/scss/settings/_all.scss
deleted file mode 100644
index 21ac292..0000000
--- a/modules/scss/settings/_all.scss
+++ /dev/null
@@ -1,2 +0,0 @@
-@import "colors";
-@import "typography";
\ No newline at end of file
diff --git a/modules/scss/settings/_colors.scss
b/modules/scss/settings/_colors.scss
deleted file mode 100644
index 0c18bdb..0000000
--- a/modules/scss/settings/_colors.scss
+++ /dev/null
@@ -1,17 +0,0 @@
-// Grays
-// -----------------------------------------
-$agoraGray: #c9c9c9;
-$agoraTextColor: #252525;
-
-// Blues
-// -----------------------------------------
-$agoraBlue: #3366bb;
-$agoraBlueShadow: #4091ed;
-
-// Greens
-// -----------------------------------------
-$agoraGreen: #27aa65;
-
-// Reds
-// -----------------------------------------
-$agoraRed: #cc0000;
diff --git a/modules/scss/settings/_typography.scss
b/modules/scss/settings/_typography.scss
deleted file mode 100644
index 5f0cea2..0000000
--- a/modules/scss/settings/_typography.scss
+++ /dev/null
@@ -1,6 +0,0 @@
-$baseFontSize: 1em;
-$baseFontFamily: "Helvetica Neue", "Helvetica", "Arial", sans-serif;
-$baseLineHeight: 1.4 * $baseFontSize;
-$baseFontColor: $agoraTextColor;
-
-$smallFontSize: 0.75em;
\ No newline at end of file
--
To view, visit https://gerrit.wikimedia.org/r/69458
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I2c3143594a3249c71ce77b1218e4fa695ac4c4df
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Agora
Gerrit-Branch: master
Gerrit-Owner: Spage <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits