mediawiki-extensions-Visual.../modules/ve/ce/styles/ve.ce.Surface.css
Timo Tijhof 57960a73bd Add .csslintrc file and fix remaining warnings
Adding a fairly loose .csslintrc file so that our code
passes it.

The following options cause warnings in our code and have been
disabled for now:

* adjoining-classes
  > Don't use adjoining classes.
  > .ve-ui-widget-disabled.ve-ui-textInputWidget textarea:focus {

* box-sizing
  > The box-sizing property isn't supported in IE6 and IE7.
  > box-sizing: border-box;

* box-model
  > Using width with border can sometimes make elements larger than you expect.
  > border: solid 1px #ccc;
  > Using width with padding can sometimes make elements larger than you expect.
  > padding: 0 0.75em 0 0.75em;
  > Using width with border-right can sometimes make elements larger than you expect.
  > border-right: 1px solid #eee;

* fallback-colors
  > Fallback background-color (hex or RGB) should precede RGBA background-color.
  > background-color: rgba(104,171,255,0.1);

* important
  > Use of !important
  > position: relative !important;

* outline-none
  > Outlines shouldn't be hidden unless other visual changes are made.
  > .ve-ce-documentNode[contenteditable="true"]:focus {

* qualified-headings
  > Heading (h1) should not be qualified.
  > .ve-ce-branchNode h1:empty:before,

* universal-selector
  > The universal selector (*) is known to be slow.
  > .ve-ce-protectedNode * {

* unqualified-attributes
  > Unqualified attribute selectors are known to be slow.
  > .ve-ce-documentNode[contenteditable="true"]:focus {

Fixes made:
* modules/ve/ce/styles/ve.ce.Surface.css:
 [L66:C2] margin can't be used with display: inline.
* modules/ve/ui/styles/ve.ui.css: Unknown @ rule: @-ms-keyframes
 Internet Explorer < 10 doesn't support keyframes. IE10+ supports
 the standard property. I don't think ms-keyframes ever existed
 http://caniuse.com/css-animation. ms-transform did exist
 http://caniuse.com/transform.

Change-Id: I728a48e489c079e1c94a506bb00c245de9551eb6
2013-06-05 11:07:00 +00:00

75 lines
1.4 KiB
CSS

/*!
* VisualEditor ContentEditable Surface styles.
*
* @copyright 2011-2013 VisualEditor Team and others; see AUTHORS.txt
* @license The MIT License (MIT); see LICENSE.txt
*/
.ve-ce-surface {
overflow: hidden;
font-size: 1em; /* to look more like MediaWiki use: 0.8em */;
}
.ve-ce-surface-textarea {
position: absolute;
z-index: -1;
filter: alpha(opacity=0);
opacity: 0;
color: white;
background-color: #fff;
border: none;
padding: 0;
margin: 0;
width: 1px;
}
.ve-ce-surface-textarea:focus {
outline: none;
}
.ve-ce-surface-cursor {
position: absolute;
background-color: #000;
width: 1px;
display: none;
}
/* @noflip */
.ve-ce-surface-phantoms {
position: absolute;
top: 0;
left: 0;
opacity: 0.75;
}
.ve-ce-surface-paste {
display: none;
height: 1px;
left: 0;
filter: alpha(opacity=0);
opacity: 0;
overflow: hidden;
position: fixed;
top: 0;
width: 1px;
}
.ve-ce-surface-paste * {
height: 1px !important;
width: 1px !important;
}
/* MediaWiki PHP Parser does not wrap text inside image captions in <p> but we do (cause we have to).
* Let's make those <p> looks like they are not there by proper CSS styling.
*/
/*csslint overqualified-elements:false */
.ve-ce-surface .thumbcaption p.ve-ce-generated-wrapper {
display: inline;
padding: 0;
line-height: inherit;
}
.ve-ce-surface .thumbcaption .ve-ce-branchNode-slug {
display: none;
}