Skip to content

Commit

Permalink
docs: Add event to badge
Browse files Browse the repository at this point in the history
  • Loading branch information
lneugebauer committed Aug 25, 2024
1 parent 84fae8c commit 2ba877d
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 8 deletions.
5 changes: 2 additions & 3 deletions docs/components/NCBadge.vue
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
<script setup lang="ts">
import type {NCBadge} from "./types.js";
interface Props {
alt: string
eventName: string | null,
link: string
size: 'small' | 'medium'
src: string
Expand All @@ -13,7 +12,7 @@ const props = defineProps<Props>()

<template>
<a :href="link">
<img class="badge" :class="[size]" :src="src" :alt="alt"/>
<img class="badge" :class="[size]" :src="src" :alt="alt" :data-umami-event="eventName"/>
</a>
</template>

Expand Down
5 changes: 0 additions & 5 deletions docs/components/types.d.ts

This file was deleted.

5 changes: 5 additions & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,18 +30,21 @@ import payPalBadge from './assets/images/donate_with_paypal.svg';
<NCStoreBadges>
<NCBadge
alt="Get it on Play Store"
event-name="get-it-on-play-store-button"
link="https://play.google.com/store/apps/details?id=de.lukasneugebauer.nextcloudcookbook"
size="medium"
src="https://play.google.com/intl/en_us/badges/images/generic/en_badge_web_generic.png"
/>
<NCBadge
alt="Get it on GitHub"
event-name="get-it-on-github-button"
link="https://github.com/lneugebauer/nextcloud-cookbook/releases"
size="medium"
:src="gitHubBadge"
/>
<NCBadge
alt="Get it on F-Droid"
event-name="get-it-on-f-droid-button"
link="https://f-droid.org/packages/de.lukasneugebauer.nextcloudcookbook/"
size="medium"
src="https://fdroid.gitlab.io/artwork/badge/get-it-on.png"
Expand Down Expand Up @@ -70,12 +73,14 @@ import payPalBadge from './assets/images/donate_with_paypal.svg';
<NCDonationBadges>
<NCBadge
alt="Donate using Liberapay"
event-name="donate-using-liberapay-button"
link="https://liberapay.com/lneugebauer/donate"
size="small"
src="https://liberapay.com/assets/widgets/donate.svg"
/>
<NCBadge
alt="Donate using PayPal"
event-name="donate-using-paypal-button"
link="https://www.paypal.com/donate/?hosted_button_id=ECDNN8PS3SSMQ"
size="small"
:src="payPalBadge"
Expand Down

0 comments on commit 2ba877d

Please sign in to comment.