Testing AwesomeButton

This commit is contained in:
mikwee 2021-10-28 19:45:19 +03:00
parent c839ee41b1
commit a3f00581fb
2 changed files with 9 additions and 9 deletions

View file

@ -17,7 +17,6 @@
font-family: "Roboto"; font-family: "Roboto";
text-decoration: underline; text-decoration: underline;
color: white; color: white;
} }/* .roots {
.roots {
display: block;
} }

View file

@ -1,5 +1,5 @@
import './App.css'; import './App.css';
import {AwesomeButton, AwesomeButtonSocial} from 'react-awesome-button'; import {AwesomeButton} from 'react-awesome-button';
import AwesomeButtonStyle from "react-awesome-button/dist/styles.css"; import AwesomeButtonStyle from "react-awesome-button/dist/styles.css";
import data from './roots.json' import data from './roots.json'
@ -10,18 +10,19 @@ function App() {
return ( return (
<div className="App"> <div className="App">
<h1 id="title">{data.title}</h1> <h1 id="title">{data.title}</h1>
{data.links.map((rootDetail, index)=>{ <AwesomeButton className="roots"></AwesomeButton>
if(socialTypes.includes(rootDetail.type)) { {/*{data.links.map((rootDetail, index)=>{
res = <button className="roots">{rootDetail.text}</button> if(rootDetail.type == "facebook") {
res = <AwesomeButton className="roots"></AwesomeButton>
} }
else if (rootDetail.type === "basic") { else if (rootDetail.type === "basic") {
res = <button className="roots">{rootDetail.text}</button> res =
} }
else { else {
// throw "One of your roots has an unrecognized type. Check out the documentation for the supported types."; // throw "One of your roots has an unrecognized type. Check out the documentation for the supported types.";
} }
return res; return res;
})} })}*/}
</div> </div>
); );
} }