Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

Template:ShipBoxTooltip: Difference between revisions

Template page
m Fix class name. Change padding: to padding-right:
m Increase width found an instance where the content did not fit.
 
(18 intermediate revisions by the same user not shown)
Line 1: Line 1:
<includeonly><onlyinclude>{{#css:
<includeonly><onlyinclude>{{#css:


.uniwiki-ship-tooltip table,
.sbtt {
.uniwiki-ship-tooltip tr,
   width: 100%;
.uniwiki-ship-tooltip td {
   background-color: transparent;
  margin: 0;
  padding: 0;
  vertical-align: top;
  }
  }


td.sbtt-image {
.sbtt td.sbtt-image {
   position: relative;
   position: relative;
   padding-right: 5px;
   padding-right: 5px;
   width: 80px;
   vertical-align: top;
  }
  }


.uniwiki-ship-tooltip .left a img {
.sbtt sbtt-image a img {
   border: 1px solid #272727;
   border: 1px solid #272727;
  }
  }


.techcornersmall {
.sbtt .techcornersmall {
   position: absolute;
   position: absolute;
   top: 0;
   top: 0;
   left: 0;
   left: 2px;
  margin-left: 2px;
  margin-top: 0;
  }
  }


/* header */
/* header */
.sbtt-header {
.sbtt .sbtt-header {
   margin-bottom: 5px;
   margin-bottom: 5px;
   border-bottom: 1px solid #272727;
   border-bottom: 1px solid #272727;
Line 36: Line 29:
  }
  }


.sbtt-ship-name {
.sbtt .sbtt-ship-name {
   height: 20px;
   height: 20px;
   white-space: nowrap;
   white-space: nowrap;
Line 43: Line 36:
  }
  }


.sbtt-ship-category {
.sbtt .sbtt-ship-category {
   font-size: 11px;
   font-size: 11px;
   line-height: 10px;
   line-height: 11px;
  }
  }


.sbtt-ship-group {
.sbtt .sbtt-ship-group {
   white-space: nowrap;
   white-space: nowrap;
   color: orange;
   color: orange;
  }
  }


.sbtt-ship-hull {
.sbtt .sbtt-ship-hull {
   white-space: nowrap;
   white-space: nowrap;
  }
  }


/* Highlights */
/* Highlights */
.sbtt-highlights {
.sbtt .sbtt-highlights {
   padding-bottom: 5px;
   padding-bottom: 5px;
  }
  }


.sbtt-highlights div {
.sbtt .sbtt-highlights div {
   height: 10px;
   height: 10px;
   color: khaki;
   color: khaki;
Line 69: Line 62:
  }
  }


/* Ship attributes */
/* *** Ship attributes *** */
.sbtt-attributes {
.sbtt .sbtt-attributes {
  float: left;
   width: 180px;
   width: 170px;
  }
  }


.sbtt-attributes div {
.sbtt .sbtt-attributes div {
  display: inline-block;
   float: left;
   float: left;
   margin-right: 3px;
   margin-right: 3px;
Line 89: Line 80:
}}
}}
{{Tooltip
{{Tooltip
|1={{#if:{{{shipname}}}
| 1={{#if: {{{shipname|}}} |[[{{{shipname}}}]] |{{Co|red|! parameter shipname missing !}} }}
| [[{{{shipname}}}]]
| 2=<table class="sbtt">
| parameter shipname missing
  <tr>
}}
   <td class="sbtt-image">{{#if: {{{shipimg|}}}
 
    | [[Image:{{{shipimg}}}|128x128px|link=]]
|2=<div class='uniwiki-ship-tooltip'>
    |  {{#if: {{{shipid|}}}
  <table cellspacing='0' cellpadding='0' style='width:100%;'>
        | {{Imageserver|types|{{{shipid}}}|render|size=128}}
   <tr>
        | [[Image:No-image.png|128x128px|link=]]
  <td class='left sbtt-image'>[[Image:{{#if:{{{shipimg|}}}|{{{shipimg}}}|No-image.png}}|80x80px|{{{shipname}}}]]{{#if:{{{tech|}}}|<div class='techcornersmall'>[[Image:CornerT{{{tech|2}}}s.png|link=]]</div>|}}</td>
        }}
  <td>
    }}
    <div class="sbtt-header">
    {{#if:{{{tech|}}} |<div class="techcornersmall">[[Image:CornerT{{{tech}}}s.png|link=]]</div> }}
    <div class="sbtt-ship-name">{{{shipname}}}</div>
  </td>
    <div class="sbtt-ship-category"><span class="sbtt-ship-group">{{{grouping|Unique Ships}}}</span> <span class="sbtt-ship-hull">{{{hulltype|Unknown Class}}}</span></div>
  <td>
  <div class="sbtt-header">
    <div class="sbtt-ship-name">{{{shipname}}}</div>
    <div class="sbtt-ship-category"><span class="sbtt-ship-group">{{{grouping|}}}</span> <span class="sbtt-ship-hull">{{{hulltype|}}}</span></div>
  </div>
  {{#if: {{{highlights1|}}} {{{highlights2|}}} {{{highlights3|}}} {{{highlights4|}}}
    |<div class="sbtt-highlights"><!--
-->  {{#if: {{{highlights1|}}}|<div>[[Image:Icon_highlights.png|10x10px]]{{{highlights1|}}}</div>}}<!--
-->  {{#if: {{{highlights2|}}}|<div>[[Image:Icon_highlights.png|10x10px]]{{{highlights2|}}}</div>}}<!--
-->  {{#if: {{{highlights3|}}}|<div>[[Image:Icon_highlights.png|10x10px]]{{{highlights3|}}}</div>}}<!--
-->  {{#if: {{{highlights4|}}}|<div>[[Image:Icon_highlights.png|10x10px]]{{{highlights4|}}}</div>}}
     </div>
     </div>
    {{#if: {{{highlights1|}}}
  }}
    |<div class="sbtt-highlights">
  <div class="sbtt-attributes">
      <div>[[Image:Icon_highlights.png|10x10px]]{{{highlights1|}}}</div><!--
    <div>[[Image:icon_hi_slot.png|15x15px|link=]]{{#if: {{{highs|}}}
-->  {{#if: {{{highlights2|}}}|<div>[[Image:Icon_highlights.png|10x10px]]{{{highlights2|}}}</div>}}<!--
        | {{{highs}}} ({{#if: {{{launchers|}}} |{{{launchers}}} |0 }}/{{#if: {{{turrets|}}} |{{{turrets}}} |0 }})
-->  {{#if: {{{highlights3|}}}|<div>[[Image:Icon_highlights.png|10x10px]]{{{highlights3|}}}</div>}}<!--
        | 0 }} [[Image:icon_mid_slot.png|15x15px|link=]]{{#if: {{{mediums|}}} |{{{mediums}}} |0 }} [[Image:icon_low_slot.png|15x15px|link=]]{{#if: {{{lows|}}} |{{{lows}}} |0 }}
-->  {{#if: {{{highlights4|}}}|<div>[[Image:Icon_highlights.png|10x10px]]{{{highlights4|}}}</div>}}
    </div>
    }}
    <div class="sbtt-attributes">
    <div>[[Image:icon_hi_slot.png|15x15px|high slots]]{{{highs|0}}}({{{launchers|0}}}/{{{turrets|0}}}) [[Image:icon_mid_slot.png|15x15px|middle slots]]{{{mediums|0}}} [[Image:icon_low_slot.png|15x15px|low slots]]{{{lows|0}}}</div>
    <div>[[Image:icon_powergrid.png|15x15px|powergrid]]{{{powergrid|0 MW}}} [[Image:icon_cpu.png|15x15px|cpu output]]{{{cpu|0 tf}}}</div>
    <div>[[Image:Icon_velocity.png|15x15px|max. velocity]]{{{maxvelocity|0 m/s}}}</div>
    <div>[[Image:Icon_capacity.png|15x15px|cargo capacity]]{{{cargohold|0 m&#179;}}}</div>
     </div>
     </div>
   </td>
    <div>[[Image:icon_powergrid.png|15x15px|link=]]{{#if: {{{powergrid|}}} |{{{powergrid}}} |0 MW }} [[Image:icon_cpu.png|15x15px|link=]]{{#if: {{{cpu|}}} |{{{cpu}}} |0 tf }}</div>
   </tr>
    <div>[[Image:Icon_velocity.png|15x15px|link=]]{{#if: {{{maxvelocity|}}} |{{{maxvelocity}}} |0 m/s }}</div>
  </table>
    <div>[[Image:Icon_capacity.png|15x15px|link=]]{{#if: {{{cargohold|}}} |{{{cargohold}}} |0 m&#179; }}</div>
</div>
   </div>
}}</onlyinclude></includeonly><noinclude>
   </td>
{{documentation}}
  </tr>
</noinclude>
</table>
}}</onlyinclude></includeonly><noinclude>{{documentation}}</noinclude>