In this article, I will introduce you to pre-formatted Shortcodes that
can be added to the Median UI Template. Note that these Shortcodes only work if you use Median UI 1.6, higher
or lower versions cannot use.
The way to add these codes is very simple, you just need to add
Posts or Pages and then switch to HTML View
to add them, pay attention to change the parts you
color .
With this layout, your photos will display up to 3 images per row on
the Desktop, can display multiple rows. On Mobile photos will display in a single row and can be dragged
horizontally to see all photos.
However, here is how to create related posts manually. We will use it in case we want to display the article as we want at any
position in the article.
<div class="pRelate notranslate">
<!--[ Related title ]-->
<b>Related posts:</b>
<ul>
<li><a href="URL 1">Template Median UI AMP 1.6</a></li>
<li><a href="URL 2">Font Template Median UI</a></li>
<li><a href="URL 3">Short code Template Median UI</a></li>
</ul>
</div>
The biggest headache when using tables is that on mobile, it will
look very ugly when there are too many columns or too long rows. In Median UI 1.6 this problem has been fixed. The table will be dragged horizontally on both mobile and desktop
when the row is too long or many columns.
Table of Content (TOC) will be added automatically under H1 - H6 tags
as you can see on the right side of this article. However, you can also add a hand if you don't want it to
automatically display all.
With this manual you need to add
id=...on each title tag like<h2 id="Blockquote">
This table of contents will also automatically get from the H1 - H6
tags, but semi-automatically because it must add code to the position
you want to display.
<details class='sp toc'>
<summary data-show='Show' data-hide='Hide'>Table of Contents</summary>
<div class='toC' id='toContent'></div>
</details>
<!--[ Script to activate ToC ]-->
<script>document.addEventListener('DOMContentLoaded', () =>
new TableOfContents({
from: document.querySelector('#postBody'),
to: document.querySelector('#toContent')
}).generateToc()
);</script>
If you want to display the code in the article, you can do it in 3
ways. The first way is to insert
codelike this with the <code>code</code>. The second way we will do the following, corresponding to each piece
of code is also how it displays:
However, it should be noted that it must be converted
<to <and >into >before adding it.
<div class="pre preH"><pre>Code here</pre></div>
<div class="pre html"><pre>HTML here</pre></div>
<div class="pre js"><pre>JS here</pre></div>
<div class="pre css"><pre>CSS here</pre></div>
There is also a third way is to add Multi Tabs Code as follows:
<details class="sp notranslate">
<summary data-show="Show" data-hide="Show">Content:</summary>
<p>This is the demo content for the hidden content section. This feature is available in Median UI 1.6.</p><div class="widget HTML" data-version="2" id="HTML02">
<div class="widget-content">
<div class="adB" data-text="Ads go here"></div>
<script wfd-invisible="true">/*<![CDATA[*/ function insertAfter(tbh,tgt) {var prt = tgt.parentNode; if (prt.lastChild == tgt) {prt.appendChild(tbh);} else {prt.insertBefore(tbh,tgt.nextSibling);}} var tgt = document.getElementById('postBody'); var midAd02 = document.getElementById('HTML02');var showAd02 = tgt.getElementsByTagName('p'); if (showAd02.length > 0) {insertAfter(midAd02,showAd02[20]);}; /*]]>*/</script>
</div>
</div>
</details>
Demo
Content:
This is the demo content for the hidden content section. This feature is
available in Median UI 1.6.
Accordion / Toggle Menu
<div class="showH">
<!--[ Accordion line 1 ]-->
<details class="ac">
<summary>Accordion line 1</summary>
<div class="aC">
<p>Epcot is an amusement park at Walt Disney World Resort that features exciting attractions, international pavilions, and fireworks. Award-winning and seasonal specials.</p>
</div>
</details>
<!--[ Accordion line 2 ]-->
<details class="ac">
<summary>Accordion line 2</summary>
<div class="aC">
<p>Epcot is an amusement park at Walt Disney World Resort with interesting attractions, international pavilion and fireworks.
Award-winning and special seasonal events.</p> </div>
Award-winning and special seasonal events.</p> </details>
<!--[ Accordion line 3 ]-->
<details class="ac">
<summary>Accordion line 3</summary>
<div class="aC">
<p>Epcot is an amusement park The location at Walt Disney World Resort features exciting attractions, international pavilions, and fireworks. Award-winning and seasonal specials.</p>
</div>
</details>
<!--[ Accordion line 4 ]-->
<details class="ac alt">
<summary>Accordion line 4</summary>
<div class="aC">
<p>Epcot is an amusement park at Walt Disney World Resort with interesting attractions,
Award-winning and special seasonal events.</p> </div>
</details>
</div>
Demo
Accordion line 1
Epcot is an amusement park at Walt Disney World Resort that
features exciting attractions, international pavilions, and
fireworks. Award-winning and special seasonal events.
Accordion line 2
Epcot is an amusement park at Walt Disney World Resort that
features exciting attractions, international pavilions, and
fireworks. Award-winning and special seasonal events.
Accordion line 3
Epcot is an amusement park at Walt Disney World Resort that
features exciting attractions, international pavilions, and
fireworks. Award-winning and special seasonal events.
Accordion line 4
Epcot is an amusement park at Walt Disney World Resort that
features exciting attractions, international pavilions, and
fireworks. Award-winning and special seasonal events.
Notes (notes)
Epcot is an amusement park at Walt Disney World Resort that features
exciting attractions, international pavilions, and fireworks.
Award-winning and special seasonal events.
<p class="note notranslate">Epcot is an amusement park at Walt Disney World Resort that features exciting attractions, international pavilions, and fireworks. Award-winning and special seasonal events.</p>
Warning! Epcot is an amusement park at Walt Disney World
Resort that features exciting attractions, international pavilions, and
fireworks. Award-winning and special seasonal events.
<p class="note wr notranslate"><b>Warning!</b><br>Epcot is an amusement park at Walt Disney World Resort that features exciting attractions, international pavilions, and fireworks. Award-winning and special seasonal events.</p>
0 Comments: