1
0
Fork 0

fix backlinks styling

This commit is contained in:
Yusuf Bera Ertan 2022-08-14 13:46:46 +03:00
parent b7784272eb
commit f9d23479d5
Signed by: dusk
GPG Key ID: 1D8F8FAF2294D6EA
3 changed files with 58 additions and 0 deletions

View File

@ -0,0 +1,18 @@
<ema:note:backlinks:nodaily>
<div class="flex-1 p-4 mt-8 bg-gray-800 rounded">
<header class="mb-2 text-xl font-semibold text-gray-100">Links to this page</header>
<ul class="space-y-1">
<backlink>
<li>
<a class="text-${theme}-600 mavenLinkBold hover:underline"
href="${backlink:note:url}">
<backlink:note:title />
</a>
<backlink:note:contexts>
<apply template="context" />
</backlink:note:contexts>
</li>
</backlink>
</ul>
</div>
</ema:note:backlinks:nodaily>

View File

@ -0,0 +1,24 @@
<div class="mb-4 overflow-auto text-sm text-gray-100">
<context>
<div class="pl-2 mt-2 border-l-2 border-${theme}-200 hover:border-${theme}-500">
<context:body>
<PandocLink class="text-gray-300">
<Internal class="font-bold opacity-50 hover:opacity-100" />
<External class="hover:underline" target="_blank" rel="noopener" />
</PandocLink>
<OrderedList class="ml-4 space-y-1 list-decimal list-inside" />
<BulletList class="ml-4 space-y-1 list-decimal list-inside" />
<Task:Checked>
<apply template="/templates/components/checkbox-checked">
<inlines />
</apply>
</Task:Checked>
<Task:Unchecked>
<apply template="/templates/components/checkbox-unchecked">
<inlines />
</apply>
</Task:Unchecked>
</context:body>
</div>
</context>
</div>

View File

@ -0,0 +1,16 @@
<ema:metadata>
<section
class="flex flex-wrap items-end justify-center my-4 space-x-2 space-y-2 font-mono text-sm">
<with var="tags">
<!-- FIXME: The use of -/tags is wrong, because we should use routeUrl using Ema's encoder
Perhaps Emanote should inject tagMetas with urls.
-->
<a title="Tag" class="px-1 bg-gray-800 rounded border-2 border-gray-700 hover:border-${theme}-700 hover:text-${theme}-500"
href="-/tags/${value}${ema:urlStrategySuffix}">
<!-- DoNotFormat -->
#<value />
<!-- DoNotFormat -->
</a>
</with>
</section>
</ema:metadata>