chore: update share button + fixes

This commit is contained in:
Cory Dransfeldt 2024-02-20 14:24:32 -08:00
parent f45eb74c0f
commit 593c2a5a09
No known key found for this signature in database
9 changed files with 37 additions and 51 deletions

View file

@ -2,22 +2,7 @@
{% render "../../assets/styles/components/share-button.css" %}
{% endcapture %}
<style>{{ css }}</style>
<script type="module" src="/assets/scripts/components/share-button.js"></script>
<share-button>
<button class="icon--small icon--center__vertical">{% tablericon "share" "Share" %}</button>
<label>
Share this page
<input
type="url"
readonly
value="{{ url }}"
onclick="this.select()"
/>
</label>
</share-button>
<style>
share-button:not(:defined) button,
share-button:defined label {
display: none;
}
</style>
<script type="module" src="/assets/scripts/components/webcare-webshare.js"></script>
<webcare-webshare share-text="{{ title }} {{ url | tagLookup: tagMap }}" share-url="{{ url }}" copy-text="{{ title }} {{ url | tagLookup: tagMap }} {{ url }}">
<button class="icon--small icon--center__vertical" disabled>{% tablericon "share" "Share" %}</button>
</webcare-webshare>