mirror of
https://github.com/squidfunk/mkdocs-material.git
synced 2024-06-14 11:52:32 +03:00
Updated Sponsors listing
This commit is contained in:
parent
6d59b425aa
commit
0d82ef2628
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -35,5 +35,5 @@
|
||||
{% endblock %}
|
||||
{% block scripts %}
|
||||
{{ super() }}
|
||||
<script src="{{ 'overrides/assets/javascripts/bundle.5637e9f5.min.js' | url }}"></script>
|
||||
<script src="{{ 'overrides/assets/javascripts/bundle.89b9c269.min.js' | url }}"></script>
|
||||
{% endblock %}
|
||||
|
@ -125,7 +125,7 @@ export function mountSponsorship(
|
||||
const list = getElementOrThrow(":scope > :first-child", el)
|
||||
for (const sponsor of sponsorship.sponsors)
|
||||
if (sponsor.type === "public")
|
||||
list.appendChild(renderPublicSponsor(sponsor))
|
||||
list.appendChild(renderPublicSponsor(sponsor.user))
|
||||
|
||||
/* Render combined private sponsors */
|
||||
list.appendChild(renderPrivateSponsor(
|
||||
|
@ -22,7 +22,7 @@
|
||||
|
||||
import { h } from "~/utilities"
|
||||
|
||||
import { PublicSponsor } from "_/components"
|
||||
import { SponsorUser } from "_/components"
|
||||
|
||||
/* ----------------------------------------------------------------------------
|
||||
* Functions
|
||||
@ -31,17 +31,17 @@ import { PublicSponsor } from "_/components"
|
||||
/**
|
||||
* Render public sponsor
|
||||
*
|
||||
* @param sponsor - Public sponsor
|
||||
* @param user - Sponsor user
|
||||
*
|
||||
* @returns Element
|
||||
*/
|
||||
export function renderPublicSponsor(
|
||||
sponsor: PublicSponsor
|
||||
user: SponsorUser
|
||||
): HTMLElement {
|
||||
const title = `@${sponsor.name}`
|
||||
const title = `@${user.name}`
|
||||
return (
|
||||
<a href={sponsor.url} title={title} class="mdx-sponsorship__item">
|
||||
<img src={sponsor.image} />
|
||||
<a href={user.url} title={title} class="mdx-sponsorship__item">
|
||||
<img src={user.image} />
|
||||
</a>
|
||||
)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user