Use referenced svg to reduce dom count

This commit is contained in:
Sam Carlton 2020-11-20 13:02:45 -06:00
parent 538a2f6a81
commit f729cf37cf

View file

@ -32,6 +32,17 @@
<div class="search-results py-8">
<svg style="display: none;">
<defs>
<path
id="chevron-right"
fill-rule="evenodd"
d="M7.293 14.707a1 1 0 010-1.414L10.586 10 7.293 6.707a1 1 0 011.414-1.414l4 4a1 1 0 010 1.414l-4 4a1 1 0 01-1.414 0z"
clip-rule="evenodd"
/>
</defs>
</svg>
<ul class="results-container rounded-lg border border-gray-700 divide-y divide-gray-700 bg-gradient-to-br from-darker to-dark neumorphic-shadow-outer px-5">
<li
v-if="results.length === 0"
@ -60,23 +71,15 @@
<span class="">{{ app.text }}</span>
</div>
</div>
<!-- <div class="hidden md:block">
<div>
</div>
</div> -->
</div>
</div>
<div>
<!-- Heroicon name: chevron-right -->
<svg
class="h-5 w-5 text-gray-400"
viewBox="0 0 20 20"
fill="currentColor">
<path
fill-rule="evenodd"
d="M7.293 14.707a1 1 0 010-1.414L10.586 10 7.293 6.707a1 1 0 011.414-1.414l4 4a1 1 0 010 1.414l-4 4a1 1 0 01-1.414 0z"
clip-rule="evenodd" />
fill="currentColor"
>
<use href="#chevron-right" />
</svg>
</div>
</div>