Component 'square'

This commit is contained in:
djmil 2023-07-31 13:35:46 +02:00
parent 6bee65d627
commit 3a9701411c
2 changed files with 19 additions and 17 deletions

View File

@ -1,24 +1,11 @@
import logo from './logo.svg';
import './App.css'; import './App.css';
function App() { function App() {
return ( return (
<div className="App"> <>
<header className="App-header"> <button className="square">X</button>
<img src={logo} className="App-logo" alt="logo" /> <button className="square">X</button>
<p> </>
Edit <code>src/App.js</code> and save to reload.
</p>
<a
className="App-link"
href="https://reactjs.org"
target="_blank"
rel="noopener noreferrer"
>
Learn React
</a>
</header>
</div>
); );
} }

View File

@ -11,3 +11,18 @@ code {
font-family: source-code-pro, Menlo, Monaco, Consolas, 'Courier New', font-family: source-code-pro, Menlo, Monaco, Consolas, 'Courier New',
monospace; monospace;
} }
.square {
background: #fff;
border: 1px solid #999;
float: left;
font-size: 24px;
font-weight: bold;
line-height: 34px;
height: 34px;
margin-right: -1px;
margin-top: -1px;
padding: 0;
text-align: center;
width: 34px;
}