Skip to content

Commit cd52f92

Browse files
authored
Merge pull request #1087 from ReactTooltip/docs/frigade-sponsor
Frigade sponsorship
2 parents cc91763 + cac5110 commit cd52f92

File tree

8 files changed

+77
-4
lines changed

8 files changed

+77
-4
lines changed

README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,14 @@ Please check our [troubleshooting section](https://react-tooltip.com/docs/troubl
123123
If you can't find your problem here, make sure there isn't [an open issue](https://github.com/ReactTooltip/react-tooltip/issues) already covering it.
124124
If there isn't, feel free to [submit a new issue](https://github.com/ReactTooltip/react-tooltip/issues/new/choose).
125125

126+
## Sponsors
127+
128+
<a href="https://frigade.com/?source=react-tooltip">
129+
<img alt="Frigade" style="height: 250px" src="docs/static/img/sponsors/frigade.png" />
130+
</a>
131+
132+
React Tooltip is proud to be sponsored by [Frigade](https://frigade.com/?source=react-tooltip), a developer tool for building better product onboarding: guided tours, getting started checklists, announcements, etc.
133+
126134
## Article
127135

128136
[How I insert sass into react component](https://medium.com/@wwayne_me/how-i-insert-sass-into-my-npm-react-component-b46b9811c226#.gi4hxu44a)
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
/* eslint-disable import/no-unresolved */
2+
import React from 'react'
3+
import AdsContainerElement from '@site/src/components/AdsContainerElement'
4+
import BannerFrigade from '@site/src/components/BannerFrigade'
5+
import './styles.css'
6+
7+
const AdsContainer = () => {
8+
return (
9+
<div className="fixed">
10+
<BannerFrigade />
11+
<AdsContainerElement />
12+
</div>
13+
)
14+
}
15+
16+
export default AdsContainer
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
.fixed {
2+
position: fixed;
3+
}

docs/src/components/AdsContainerElement/styles.css

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
.carbon-ads {
2-
position: fixed;
32
display: grid;
43
row-gap: 16px;
54
}
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
/* eslint-disable import/no-unresolved */
2+
import React from 'react'
3+
// @ts-ignore
4+
import LogoFrigade from '@site/static/img/sponsors/frigade.png'
5+
6+
const BannerFrigade = () => {
7+
return (
8+
<div className="sponsor-frigade">
9+
<a
10+
href="https://frigade.com/?source=react-tooltip"
11+
title="Frigade"
12+
target="_blank"
13+
rel="noreferrer"
14+
>
15+
<img src={LogoFrigade} alt="Frigade" />
16+
</a>
17+
</div>
18+
)
19+
}
20+
21+
export default BannerFrigade

docs/src/components/HomepageSponsored/index.tsx

Lines changed: 27 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
/* eslint-disable react/require-default-props */
12
/* eslint-disable import/no-unresolved */
23
/* eslint-disable @typescript-eslint/no-var-requires */
34
/* eslint-disable global-require */
@@ -7,7 +8,9 @@ import styles from './styles.module.css'
78

89
type FeatureItem = {
910
title: string
10-
Svg: React.ComponentType<React.ComponentProps<'svg'>>
11+
Svg?: React.ComponentType<React.ComponentProps<'svg'>>
12+
// eslint-disable-next-line @typescript-eslint/no-explicit-any, react/no-unused-prop-types
13+
src?: any
1114
link: string
1215
}
1316

@@ -24,6 +27,14 @@ const FeatureList: FeatureItem[] = [
2427
},
2528
]
2629

30+
const SponsorList: FeatureItem[] = [
31+
{
32+
title: 'Frigade',
33+
src: require('@site/static/img/sponsors/frigade.png').default,
34+
link: 'https://frigade.com/?source=react-tooltip',
35+
},
36+
]
37+
2738
function Feature({ title, Svg, link }: FeatureItem) {
2839
return (
2940
<div className={clsx('col col--6')}>
@@ -39,6 +50,21 @@ function Feature({ title, Svg, link }: FeatureItem) {
3950
export default function HomepageSponsored(): JSX.Element {
4051
return (
4152
<section className={styles.features}>
53+
<div className="container">
54+
<h3 className={styles.sponsoredTitle}>Sponsored by</h3>
55+
<div className="row">
56+
{SponsorList.map(({ link, title, src }, idx) => (
57+
// eslint-disable-next-line react/no-array-index-key
58+
<div key={idx} className={clsx('col col--12')}>
59+
<div className="text--center">
60+
<a href={link} title={title} target="_blank" rel="noreferrer">
61+
<img src={src} alt={title} width={480} />
62+
</a>
63+
</div>
64+
</div>
65+
))}
66+
</div>
67+
</div>
4268
<div className="container">
4369
<h3 className={styles.sponsoredTitle}>Powered by</h3>
4470
<div className="row">

docs/src/theme/TOC/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
/* eslint-disable import/no-unresolved */
22
import React from 'react'
33
import TOC from '@theme-original/TOC'
4-
import AdsContainerElement from '@site/src/components/AdsContainerElement'
4+
import AdsContainer from '@site/src/components/AdsContainer'
55

66
export default function TOCWrapper(props) {
77
return (
88
<>
99
<TOC {...props} />
10-
<AdsContainerElement />
10+
<AdsContainer />
1111
{/* <ins
1212
className="adsbygoogle"
1313
style={{ display: 'block', position: 'fixed', width: '300px', height: '600px' }}

docs/static/img/sponsors/frigade.png

441 KB
Loading

0 commit comments

Comments
 (0)