Matthias Mullie has uploaded a new change for review.
https://gerrit.wikimedia.org/r/113066
Change subject: Remove Flow's mw.ui overrides
......................................................................
Remove Flow's mw.ui overrides
Change-Id: I8dd6b8304dc8941ef4f27566375c77269eafb05f
---
M Resources.php
D modules/mediawiki.ui/styles/agora-override-buttons.less
D modules/mediawiki.ui/styles/agora-override-forms.less
D modules/mediawiki.ui/styles/mixins/buttons.less
4 files changed, 0 insertions(+), 293 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Flow
refs/changes/66/113066/1
diff --git a/Resources.php b/Resources.php
index 25af6fc..a46076a 100644
--- a/Resources.php
+++ b/Resources.php
@@ -14,12 +14,6 @@
'base/styles/actionbox.less',
'base/styles/various.less',
'base/styles/preview.less',
- /*
- * This is CSS that adds to/overrides Agora styles,
meant to be
- * moved to mediawiki.ui at a later point
- */
- 'mediawiki.ui/styles/agora-override-buttons.less',
- 'mediawiki.ui/styles/agora-override-forms.less',
),
'skinStyles' => array(
'vector' => array(
diff --git a/modules/mediawiki.ui/styles/agora-override-buttons.less
b/modules/mediawiki.ui/styles/agora-override-buttons.less
deleted file mode 100644
index 22d7598..0000000
--- a/modules/mediawiki.ui/styles/agora-override-buttons.less
+++ /dev/null
@@ -1,146 +0,0 @@
-// based on Flow Prototype/Design/Iteration 5 "Buttons & Flyout Options"
-
-@import 'settings/colors.less';
-@import 'mixins/buttons.less';
-
-.mw-ui-button {
- font-weight: bold;
- border-radius: 3px;
- cursor: pointer;
- text-shadow: none;
- font-family: sans-serif;
- font-size: 14px;
-
- // Firefox forces an !important line-height on inputs, meaning we can't
- // override it - workaround is to set line-height to normal everywhere
else
- // too, and use padding accomplish the same thing.
- // @see
http://stackoverflow.com/questions/3650530/firefox-line-height-issue-with-input-fields
- line-height: normal;
- padding-top: 7px;
- padding-bottom: 7px;
-
- // Firefox adds some "special padding" around an input's value - in
order to
- // have both a & input-like buttons look exactly the same, get rid of
that!
- // @see http://ovms.co/2010/06/fix-firefox-button-padding/
- &::-moz-focus-inner {
- padding: 0 !important;
- border: 0 none !important;
- }
-
- // if button is followed by another button, add some space in between
- + .mw-ui-button{
- margin-left: 8px;
- }
-
- .buttonColors(
- // normal
- @neutral-base, // background
- #898989, //text
- #ccc, //border
-
- // hover
- @neutral-base,
- #898989,
-
- // active
- @neutral-active,
- #898989,
-
- // disabled
- @neutral-base,
- #898989
- );
-
- &.mw-ui-constructive {
- .buttonColors(
- // normal
- @constructive-base, // background
- #fff, // text
- #00af8b, // border
-
- // hover
- @constructive-base,
- #fff,
-
- // active
- @constructive-active,
- #fff,
-
- // disabled
- @neutral-base,
- #898989
- );
-
- // override borders
- border: 0px transparent;
-
- &:disabled {
- border: 1px solid #ccc;
- }
- }
-
- // TODO: mw-ui-progressive (blue) for intermediate steps from Agora
specs.
-
- &.mw-ui-destructive {
- .buttonColors(
- // normal
- @destructive-base, // background
- #fff, // text
- @destructive-base, // border
-
- // hover
- @destructive-base,
- #fff,
-
- // active
- @destructive-active,
- #fff,
-
- // disabled
- @neutral-base,
- #898989
- );
-
- &.mw-ui-destructive-medium {
- .buttonColors(
- // normal
- @destructive-medium-base, // background
- #fff, // text
- @destructive-medium-base, // border
-
- // hover
- @destructive-medium-base,
- #fff,
-
- // active
- @destructive-medium-active,
- #fff,
-
- // disabled
- @neutral-base,
- #898989
- );
- }
-
- &.mw-ui-destructive-low {
- .buttonColors(
- // normal
- @destructive-low-base, // background
- #fff, // text
- @destructive-low-base, // border
-
- // hover
- @destructive-low-base,
- #fff,
-
- // active
- @destructive-low-active,
- #fff,
-
- // disabled
- @neutral-base,
- #898989
- );
- }
- }
-}
diff --git a/modules/mediawiki.ui/styles/agora-override-forms.less
b/modules/mediawiki.ui/styles/agora-override-forms.less
deleted file mode 100644
index 320fbfd..0000000
--- a/modules/mediawiki.ui/styles/agora-override-forms.less
+++ /dev/null
@@ -1,57 +0,0 @@
-// .flow-container ensures greater specificity than core rules
-.flow-container {
- .field-placeholder-styling(@color: #aaa) {
- font-style: italic;
- font-weight: normal;
- color: @color;
- }
-
- .mw-ui-input {
- border: 1px solid #e6e6e5;
- color: #6d6e70;
-
- padding: 6px 10px 6px 15px;
-
- &:hover {
- border: 1px solid #c0c0c0;
- }
-
- &:focus {
- box-shadow: 7px 0 0 #347bff inset;
- border: 1px solid #c0c0c0;
- }
-
- /*
- * Duplication because browsers ignore groups containing an
invalid selector.
- * Only one of the below is valid per-browser.
- * @see http://stackoverflow.com/a/2610741
- */
- &::-webkit-input-placeholder { // webkit
- .field-placeholder-styling;
- }
- &::-moz-placeholder { // FF 4-18
- .field-placeholder-styling;
- }
- &:-moz-placeholder { // FF >= 19
- .field-placeholder-styling;
- }
- &:-ms-input-placeholder { // IE >= 10
- .field-placeholder-styling;
- }
- }
-
- // make it similar to .mw-ui-button
- a.mw-ui-input,
- input.mw-ui-input {
- display: inline-block;
- vertical-align: middle;
-
- height: 34px;
- }
-
- // padding messes up textarea's right scroll bar & bottom right resize
grabber
- // in FF, so hide it as long as it's not necessary
- textarea.mw-ui-input:empty {
- overflow: hidden;
- }
-}
diff --git a/modules/mediawiki.ui/styles/mixins/buttons.less
b/modules/mediawiki.ui/styles/mixins/buttons.less
deleted file mode 100644
index b3161f3..0000000
--- a/modules/mediawiki.ui/styles/mixins/buttons.less
+++ /dev/null
@@ -1,84 +0,0 @@
-// primary & secondary are basically background & border colors;
xx-contrast-color is a contrasting color, used for text and other effects
-.buttonColors(
- @primary-color: @neutral-base, // background color
- @primary-contrast-color: #909090, // text color
- @secondary-color: #ccc, // border color
-
- @hover-primary-color: darken(@primary-color, 5%), // background color
- @hover-primary-contrast-color: @primary-contrast-color, // text color
-
- @active-primary-color: darken(@primary-color, 10%), // background color
- @active-primary-contrast-color: @primary-contrast-color, // text color
-
- @inactive-primary-color: #fff, // background color
- @inactive-primary-contrast-color: @primary-contrast-color // text color
-) {
- color: @primary-contrast-color !important;
- background: @primary-color;
- border: 1px solid @secondary-color;
-
- &:hover,
- &.mw-ui-hover {
- color: @hover-primary-contrast-color !important;
- background: @hover-primary-color;
-
- box-shadow: 0px 1px 0px 0px rgba(0,0,0,.05), inset 0px -2px 0px
0px rgba(0,0,0,.20);
- -webkit-box-shadow: 0px 1px 0px 0px rgba(0,0,0,.05), inset 0px
-2px 0px 0px rgba(0,0,0,.20);
- -moz-box-shadow: 0px 1px 0px 0px rgba(0,0,0,.05), inset 0px
-2px 0px 0px rgba(0,0,0,.20);
- }
-
- &:active,
- &.mw-ui-active {
- color: @active-primary-contrast-color !important;
- background: @active-primary-color;
-
- box-shadow: 0px 0px 0px 0px transparent;
- -webkit-box-shadow: 0px 0px 0px 0px transparent;
- -moz-box-shadow: 0px 0px 0px 0px transparent;
- }
-
- &:disabled,
- &.mw-ui-disabled {
- color: @inactive-primary-contrast-color !important;
- background: @inactive-primary-color;
- }
-
-
- // text-only, borderless text-button for secondary or "quiet" actions.
- &.mw-ui-quiet {
- border: 1px solid transparent;
- box-shadow: 0px 0px 0px 0px transparent;
- -webkit-box-shadow: 0px 0px 0px 0px transparent;
- -moz-box-shadow: 0px 0px 0px 0px transparent;
- background: none;
-
- .darkerColor(@primary-color, @primary-contrast-color);
-
- &:hover,
- &.mw-ui-hover {
- .darkerColor(@hover-primary-color,
@hover-primary-contrast-color);
- }
-
- &:active,
- &.mw-ui-active {
- .darkerColor(@active-primary-color,
@active-primary-contrast-color);
- }
-
- &:disabled,
- &.mw-ui-disabled {
- .darkerColor(@inactive-primary-color,
@inactive-primary-contrast-color);
- }
- }
-}
-
-/**
- * Mixin to help automatically set the correct text color:
- * * Primary color is preferred
- * * Unless it's too bright, which would hurt legibility
- */
-.darkerColor(@primary-color, @secondary-color) {
- color: @primary-color !important;
-}
-.darkerColor(@primary-color, @secondary-color) when (lightness(@primary-color)
> 80%) {
- color: @secondary-color !important;
-}
--
To view, visit https://gerrit.wikimedia.org/r/113066
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I8dd6b8304dc8941ef4f27566375c77269eafb05f
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Flow
Gerrit-Branch: master
Gerrit-Owner: Matthias Mullie <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits