Template:FAQ: Difference between revisions

Jump to navigation Jump to search
Update template to latest and greatest now correctly flowing boxes.
(Expand FAQ box to full width but don't flow over floating elements)
(Update template to latest and greatest now correctly flowing boxes.)
Line 4: Line 4:
|source    = https://wiki.descent-community.org
|source    = https://wiki.descent-community.org
|reference = I'm just a reference
|reference = I'm just a reference
}}</noinclude><includeonly>{{ #vardefine: def_icon | {{#if: {{{icon|}}} | {{{icon|}}} | [[File:Icon_-_Descent.png|50px]]}}
}}<includeonly>{{ #vardefine: def_icon | {{#if: {{{icon|}}} | {{{icon|}}} | [[File:Icon_-_Descent.png|50px]]}}
}}{{#if:{{{question|}}} |
}}{{#if:{{{question|}}} |
   {{#if:{{{answer|}}} |
   {{#if:{{{answer|}}} |
     {{#if:{{{source|}}} |
     {{#if:{{{source|}}} |
       {{#if:{{{reference|}}} |
       {{#if:{{{reference|}}} |
         <div style="margin-bottom:5px; background-color:lightgrey; padding:5px; border-top-left-radius:10px; border-top-right-radius:10px; border-bottom-right-radius:10px; border-bottom-left-radius:10px;min-width:270px;overflow:hidden;">
         <div style="vertical-align:bottom; margin-bottom:5px; background-color:lightgrey; padding:5px; border-top-left-radius:10px; border-top-right-radius:10px; border-bottom-right-radius:10px; border-bottom-left-radius:10px;min-width:270px;overflow:hidden;">
        {{{!}} style="width:100%"
          <div style="display:table;width:100%;">
        {{!}} align="left" colspan="2" {{!}} '''{{{question|}}}'''
            <div style="display:table-caption;width:100%">'''{{{question|}}}'''</div>
        {{!}}-
            <div style="width:100%; vertical-align: middle; display:table-row;">
        {{!}} width="55px" {{!}} {{#var: def_icon}}
              <div style="text-align:center; width:55px; display:table-cell; vertical-align: middle;">{{#var: def_icon}}</div>
        {{!}} <div style="display:inline-block; border:1px solid RGB(85,172,238); border-top-left-radius: 15px; border-top-right-radius: 15px; border-bottom-right-radius: 15px; border-bottom-left-radius: 15px; padding:7px; background-color:white;"> {{{answer|}}}</div>
              <div style="min-height:64px; display:flex; flex-wrap: wrap; align-items: center;">
        {{!}}-
                <div style="border:1px solid RGB(85,172,238); border-top-left-radius:15px; border-top-right-radius:15px; border-bottom-right-radius:15px; border-bottom-left-radius:15px; padding:7px; background-color:white;">{{{answer|}}}</div>
        {{!}} align="right" colspan="2" {{!}} {{Source|{{{source|}}}}} {{{reference|}}}
                <div style="align-self:flex-end; flex-grow:1; text-align:right;">{{Source|{{{source|}}}}} {{{reference|}}}</div>
        {{!}}-
              </div>
        {{!}}}
            </div>
          </div>
         </div>
         </div>
       }}
       }}

Navigation menu