Skip to content

Commit ba5459f

Browse files
authored
Merge pull request #6983 from Fireentity/fix/6244-duplicate-footer
Fix/6244 duplicate footer
2 parents ed2195f + 295fbaf commit ba5459f

2 files changed

Lines changed: 34 additions & 35 deletions

File tree

  • src
    • components/SistentNavigation
    • sections/Projects/Sistent/components

src/components/SistentNavigation/index.js

Lines changed: 32 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import { useLocation } from "@reach/router";
1212
const TOC = () => {
1313
const [expand, setExpand] = useState(false);
1414
const location = useLocation();
15-
const [expandIdenity, setExpandIdentity] = useState(
15+
const [expandIdentity, setExpandIdentity] = useState(
1616
location.pathname.includes("/identity")
1717
);
1818
const [expandComponent, setExpandComponent] = useState(
@@ -28,7 +28,7 @@ const TOC = () => {
2828
<TOCWrapper>
2929
<div className="go-back">
3030
<Link to="/projects/sistent">
31-
<HiOutlineChevronLeft />
31+
<HiOutlineChevronLeft/>
3232
<h4>Table of Contents</h4>
3333
</Link>
3434
<div className="toc-toggle-btn">
@@ -62,18 +62,19 @@ const TOC = () => {
6262
</li>
6363
<li>
6464
<div>
65-
<li
65+
<div
66+
type="button"
6667
className="toc-sub-heading identity"
6768
onClick={() => setExpandIdentity((prev) => !prev)}
6869
>
6970
Identity
70-
{expandIdenity ?
71-
<IoIosArrowDown style={{ zIndex: 2 }} /> :
72-
<IoIosArrowForward style={{ zIndex: 2 }} />
71+
{expandIdentity ?
72+
<IoIosArrowDown style={{ zIndex: 2 }}/> :
73+
<IoIosArrowForward style={{ zIndex: 2 }}/>
7374
}
74-
</li>
75-
{expandIdenity && (
76-
<div className="identity-sublinks">
75+
</div>
76+
{expandIdentity && (
77+
<ul className="identity-sublinks">
7778
<li>
7879
<Link
7980
to="/projects/sistent/identity/color"
@@ -119,42 +120,40 @@ const TOC = () => {
119120
Typography
120121
</Link>
121122
</li>
122-
</div>
123+
</ul>
123124
)}
124125
</div>
125126
</li>
126127
<li>
127128
<div>
128-
<li
129+
<div
129130
className="toc-sub-heading components"
130131
onClick={() => setExpandComponent((prev) => !prev)}
131132
>
132133
Components
133134
{expandComponent ?
134-
<IoIosArrowDown style={{ zIndex: 2 }} /> :
135-
<IoIosArrowForward style={{ zIndex: 2 }} />
135+
<IoIosArrowDown style={{ zIndex: 2 }}/> :
136+
<IoIosArrowForward style={{ zIndex: 2 }}/>
136137
}
137-
</li>
138+
</div>
138139
{expandComponent && (
139-
<div className="components-sublinks">
140-
<li>
141-
{sortedComponentArray.map((component) => (
142-
<li key={component.id}>
143-
<Link
144-
to={component.url}
145-
className={`toc-sub-heading toc-sub-inline components-item ${
146-
location.pathname.split("/")[4] === component.url.split("/")[4]
147-
? "active"
148-
: ""
149-
}`}
150-
activeClassName="active"
151-
>
152-
{component.name}
153-
</Link>
154-
</li>
155-
))}
156-
</li>
157-
</div>
140+
<ul className="components-sublinks">
141+
{sortedComponentArray.map((component) => (
142+
<li key={component.id}>
143+
<Link
144+
to={component.url}
145+
className={`toc-sub-heading toc-sub-inline components-item ${
146+
location.pathname.split("/")[4] === component.url.split("/")[4]
147+
? "active"
148+
: ""
149+
}`}
150+
activeClassName="active"
151+
>
152+
{component.name}
153+
</Link>
154+
</li>
155+
))}
156+
</ul>
158157
)}
159158
</div>
160159
</li>

src/sections/Projects/Sistent/components/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,14 +57,14 @@ const SistentComponents = () => {
5757
</div>
5858
<div>
5959
<div className="card_bottom">
60-
<a className="learn" href={comp.url}>
60+
<div className="learn" href={comp.url}>
6161
<div className="learn-more">
6262
<div>Learn more</div>
6363
<div className="icon">
6464
<FaArrowRight />
6565
</div>
6666
</div>
67-
</a>
67+
</div>
6868
</div>
6969
</div>
7070
</div>

0 commit comments

Comments
 (0)