aboutsummaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorMatt Mayer <[email protected]>2024-04-19 13:51:10 +0700
committerGitHub <[email protected]>2024-04-19 08:51:10 +0200
commit48ab524ebb9fbabd84a7aff131605c56f5b87429 (patch)
treee39dc89b9a6f096c9334fd7e70a6c358cad1d30a /docs
parent100abacfc1b31f7d5bb771e94027ce9120666620 (diff)
downloadfaker-48ab524ebb9fbabd84a7aff131605c56f5b87429.tar.xz
faker-48ab524ebb9fbabd84a7aff131605c56f5b87429.zip
docs: add donate links (#2806)
Diffstat (limited to 'docs')
-rw-r--r--docs/.vitepress/config.ts7
-rw-r--r--docs/.vitepress/theme/index.css30
-rw-r--r--docs/index.md5
3 files changed, 42 insertions, 0 deletions
diff --git a/docs/.vitepress/config.ts b/docs/.vitepress/config.ts
index 37218522..e92efc8e 100644
--- a/docs/.vitepress/config.ts
+++ b/docs/.vitepress/config.ts
@@ -125,6 +125,13 @@ const config: UserConfig<DefaultTheme.Config> = {
{ icon: 'mastodon', link: 'https://fosstodon.org/@faker_js' },
{ icon: 'x', link: 'https://twitter.com/faker_js' },
{ icon: 'github', link: 'https://github.com/faker-js/faker' },
+ {
+ icon: {
+ svg: '<svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>Open Collective</title><path d="M12 0C5.373 0 0 5.373 0 12s5.373 12 12 12c2.54 0 4.894-.79 6.834-2.135l-3.107-3.109a7.715 7.715 0 1 1 0-13.512l3.107-3.109A11.943 11.943 0 0 0 12 0zm9.865 5.166l-3.109 3.107A7.67 7.67 0 0 1 19.715 12a7.682 7.682 0 0 1-.959 3.727l3.109 3.107A11.943 11.943 0 0 0 24 12c0-2.54-.79-4.894-2.135-6.834z"/></svg>',
+ },
+ link: 'https://opencollective.com/fakerjs',
+ ariaLabel: 'Open Collective',
+ },
],
algolia:
diff --git a/docs/.vitepress/theme/index.css b/docs/.vitepress/theme/index.css
index fd51def4..d0fd27b0 100644
--- a/docs/.vitepress/theme/index.css
+++ b/docs/.vitepress/theme/index.css
@@ -74,3 +74,33 @@ table td ul li {
.dark .VPHero .action:not(:last-child) a.VPButton.alt {
color: var(--vp-button-brand-text) !important;
}
+
+.opencollective {
+ margin-top: 48px;
+ display: flex;
+ flex-direction: column;
+ justify-content: center;
+ align-items: center;
+ text-align: center;
+}
+
+.opencollective a {
+ margin-top: 24px;
+ border-radius: 20px;
+ padding: 0 20px;
+ line-height: 38px;
+ font-size: 14px;
+ display: inline-block;
+ border: 1px solid transparent;
+ text-align: center;
+ font-weight: 600;
+ white-space: nowrap;
+ text-decoration: none;
+
+ color: var(--vp-button-alt-text);
+ border-color: var(--vp-button-brand-bg) !important;
+ transition:
+ color 0.25s,
+ border-color 0.25s,
+ background-color 0.25s;
+}
diff --git a/docs/index.md b/docs/index.md
index f3318e73..36b71577 100644
--- a/docs/index.md
+++ b/docs/index.md
@@ -39,3 +39,8 @@ features:
title: Localization
details: Pick a locale to generate realistic looking Names, Addresses, and Phone Numbers.
---
+
+<div class="opencollective">
+ Faker is freely available to use for commercial and non-commercial purposes under the MIT license. The development of Faker is guided by an international team of volunteer maintainers. If you use Faker in your project, please consider making a one-off or recurring donation via Open Collective.
+ <a target="_blank" href="https://opencollective.com/fakerjs">Support Faker on OpenCollective</a>
+</div>