Skip to content

Commit 6423968

Browse files
committed
[add] Contact Support button to TOC
- swizzle TOCItems to inject a support link below TOC - button links to dhtmlx.com technical support page - styles scoped via CSS module
1 parent 95211b0 commit 6423968

2 files changed

Lines changed: 35 additions & 0 deletions

File tree

src/theme/TOCItems/index.js

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
import TOCItems from '@theme-original/TOCItems';
2+
import styles from './styles.module.css';
3+
4+
export default function TOCItemsWrapper(props) {
5+
return (
6+
<>
7+
<TOCItems {...props} />
8+
<div className={styles.contactSupportLinkWrapper}>
9+
Need more help?
10+
<a
11+
href="https://dhtmlx.com/docs/technical-support.shtml"
12+
target="_blank"
13+
rel="noopener noreferrer"
14+
className={`${styles.contactSupportLink} pagination-nav__link`}
15+
>
16+
Contact Support
17+
</a>
18+
</div>
19+
</>
20+
);
21+
}
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
.contactSupportLinkWrapper {
2+
display: flex;
3+
flex-direction: column;
4+
justify-content: start;
5+
align-items: start;
6+
gap: 0.5rem;
7+
margin: 1rem;
8+
}
9+
10+
.contactSupportLink {
11+
font-size: var(--ifm-h4-font-size);
12+
font-weight: var(--ifm-heading-font-weight);
13+
text-align: center;
14+
}

0 commit comments

Comments
 (0)