Skip to content

Commit

Permalink
Fontawesome link refactor & format
Browse files Browse the repository at this point in the history
  • Loading branch information
habubey committed Apr 19, 2023
1 parent 6af43a7 commit 9ec9a8f
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 18 deletions.
26 changes: 14 additions & 12 deletions components/doc/common/doccomponent.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,19 +26,21 @@ export function DocComponent(props) {
<title>{props.title}</title>
<meta name="description" content={props.description} />
</Head>
{!props.hideTabMenu ? (<ul className="doc-tabmenu">
<li className={classNames({ 'doc-tabmenu-active': tab === 0 })}>
<button type="button" onClick={() => activateTab(0)}>
{props.header.startsWith('use') ? 'HOOK' : 'FEATURES'}
</button>
</li>
{!props.hideTabMenu ? (
<ul className="doc-tabmenu">
<li className={classNames({ 'doc-tabmenu-active': tab === 0 })}>
<button type="button" onClick={() => activateTab(0)}>
{props.header.startsWith('use') ? 'HOOK' : 'FEATURES'}
</button>
</li>

<li className={classNames({ 'doc-tabmenu-active': tab === 1 })}>
<button type="button" onClick={() => activateTab(1)}>
API
</button>
</li>
</ul>) : null}
<li className={classNames({ 'doc-tabmenu-active': tab === 1 })}>
<button type="button" onClick={() => activateTab(1)}>
API
</button>
</li>
</ul>
) : null}
<div className="doc-tabpanels">
{tab === 0 ? (
<div className="doc-tabpanel">
Expand Down
5 changes: 3 additions & 2 deletions components/doc/customicons/fontawesomedoc.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import { DocSectionCode } from '../common/docsectioncode';
import { DocSectionText } from '../common/docsectiontext';

export function FontAwesomeDoc(props) {

const code = {
basic: `
<Dropdown dropdownIcon={<i class="fa-light fa-chevron-down"></i>} />
Expand All @@ -12,7 +11,9 @@ export function FontAwesomeDoc(props) {
return (
<>
<DocSectionText {...props}>
<p><a href="https://fontawesome.com/i">Font Awesome</a> is a popular icon library with a wide range of icons.</p>
<p>
<a href="https://fontawesome.com/">Font Awesome</a> is a popular icon library with a wide range of icons.
</p>
</DocSectionText>
<DocSectionCode code={code} hideToggleCode import hideCodeSandbox hideStackBlitz />
</>
Expand Down
1 change: 0 additions & 1 deletion components/doc/customicons/imagedoc.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import { DocSectionCode } from '../common/docsectioncode';
import { DocSectionText } from '../common/docsectiontext';

export function ImageDoc(props) {

const code = {
basic: `
<Dropdown dropdownIcon={<img alt="dropdown icon" src="/icons/arrow_down.png" />} />
Expand Down
5 changes: 3 additions & 2 deletions components/doc/customicons/materialdoc.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import { DocSectionCode } from '../common/docsectioncode';
import { DocSectionText } from '../common/docsectiontext';

export function MaterialDoc(props) {

const code = {
basic: `
<Dropdown dropdownIcon={<img alt="dropdown icon" src="/icons/arrow_down.png" />} />
Expand All @@ -12,7 +11,9 @@ export function MaterialDoc(props) {
return (
<>
<DocSectionText {...props}>
<p><a href="https://fonts.google.com/icons">Material icons</a> is the official icon library based on Google Material Design.</p>
<p>
<a href="https://fonts.google.com/icons">Material icons</a> is the official icon library based on Google Material Design.
</p>
</DocSectionText>
<DocSectionCode code={code} hideToggleCode import hideCodeSandbox hideStackBlitz />
</>
Expand Down
1 change: 0 additions & 1 deletion components/doc/customicons/svgdoc.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import { DocSectionCode } from '../common/docsectioncode';
import { DocSectionText } from '../common/docsectiontext';

export function SVGDoc(props) {

const code = {
basic: `
<Dropdown dropdownIcon={<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
Expand Down

0 comments on commit 9ec9a8f

Please sign in to comment.