Usuário(a):Mathglot/Testes

Origem: Wikipédia, a enciclopédia livre.

Test ambox margin fiddling[editar | editar código-fonte]

First, let's include an Expand section here as a tester:

Per en:Template talk:Expand section#How do I remove the left margin?.

Generated table from rendered source (prettified)

The generated table looks like this (prettified):

<table class="plainlinks metadata ambox mbox-small-left ambox-content" role="presentation">
  <tbody>
    <tr>
      <td class="mbox-image"><a href="/wiki/Ficheiro:Wiki_letter_w.svg" class="image"><img alt="Wiki letter w.svg" src="//upload.wikimedia.org/wikipedia/commons/thumb/6/6c/Wiki_letter_w.svg/20px-Wiki_letter_w.svg.png" decoding="async" width="20" height="20" srcset="//upload.wikimedia.org/wikipedia/commons/thumb/6/6c/Wiki_letter_w.svg/30px-Wiki_letter_w.svg.png 1.5x, //upload.wikimedia.org/wikipedia/commons/thumb/6/6c/Wiki_letter_w.svg/40px-Wiki_letter_w.svg.png 2x" data-file-width="44" data-file-height="44" /></a></td>
      <td class="mbox-text"><div class="mbox-text-span">Esta seção requer <span class="plainlinks"><a class="external text" href="https://pt.wikipedia.org/w/index.php?title=Predefini%C3%A7%C3%A3o:Expandir_se%C3%A7%C3%A3o&action=edit">expansão</a></span>.</div>
      </td>
    </tr>
  </tbody>
</table>

The mbox-text-span cell contains the text, which can be styled using a class modifier in common.css; e.g.:

  • .mbox-text-span{color:red; margin-left:1em;border-left:10px solid blue}

will turn the text color red, and add a thick blue left border but all of that inside the box, but the box itself retains its original margin position and border style.

There's a zillion classes on the page (my skin is vector), so hard to figure out what to set.

The class for ambox-notice (extracted from rendered page of Predefinição:Expandir seção) is ambox-notice. The css for it is by skin, and is mostly this piece: body.skin-vector .mw-parser-output table.ambox-notice,body.skin-cologneblue .mw-parser-output table.ambox-notice,body.skin-modern .mw-parser-output table.ambox-notice,body.skin-monobook .mw-parser-output table.ambox-notice,body.skin-timeless .mw-parser-output table.ambox-notice{border-left:10px solid #93C9FF}

Class for ambox is:

table.ambox,body.skin-cologneblue .mw-parser-output table.ambox,body.skin-modern .mw-parser-output table.ambox,body.skin-monobook .mw-parser-output table.ambox,body.skin-timeless .mw-parser-output table.ambox{margin:0 10%;border:1px solid #C7C7C7;border-left:10px solid #93C9FF;background-color:#FAFAFA;box-sizing:border-box}

Try .mw-parser-output table.ambox-notice{margin-left:1em} in common.jss. Mathglot (discussão) 17h52min de 25 de outubro de 2021 (UTC)

nothing; neither did various others. but this changed the text inside the box (and added a text border) but not the box itself:
  • .mbox-text-span{color:red; margin-left:1em;border-left:10px solid blue}
So that isn't right, but at least is hitting the element text. Mathglot (discussão) 18h22min de 25 de outubro de 2021 (UTC)

Tried tweaking .mbox-small-left (early on, in common.jss rev. 62307766) and then again later in rev. 62308060‎ (diff) as inspired by a comment by DesertPipeline (diff) but they didn't work either.