source: components/Card.jsx@ aac3b2b

main
Last change on this file since aac3b2b was 87614a5, checked in by anastasovv <simon@…>, 2 years ago

Blackjack prototype

  • Property mode set to 100644
File size: 351 bytes
Line 
1import React from 'react'
2
3const Card = ( { card, pos, rotateZ } ) => {
4 const src = `/cards/${card}.png`;
5
6 return (
7 <div className="card" style={{backgroundImage: `url("${src}")`, left: `${pos?.left}vw`, top: `${pos?.top}vh`, transform: `translate(-50%, -50%) rotateZ(${rotateZ}deg)`}}>
8
9 </div>
10 )
11}
12
13export default Card
Note: See TracBrowser for help on using the repository browser.