Use BEM
BEM Modifiers should be @mixins.
Good:
@mixin primary-button--small {
padding: 0.7777777778em 2.5em;
&.primary-button--ghost-light,
Use BEM
BEM Modifiers should be @mixins.
Good:
@mixin primary-button--small {
padding: 0.7777777778em 2.5em;
&.primary-button--ghost-light,
function pictureTemplate(photo) { | |
return html` | |
<picture class="picture lazy"> | |
<data-src | |
sizes="100vw" | |
srcset="${photo.fields.file.url}?fm=${SETTINGS.imageType}&w=768&q=${SETTINGS.quality} 768w, | |
${photo.fields.file.url}?fm=${SETTINGS.imageType}&w=992&q=${SETTINGS.quality} 992w, | |
${photo.fields.file.url}?fm=${SETTINGS.imageType}&w=1200&q=${SETTINGS.quality} 1200w, | |
${photo.fields.file.url}?fm=${SETTINGS.imageType}&w=1536&q=${SETTINGS.quality} 1536w, | |
${photo.fields.file.url}?fm=${SETTINGS.imageType}&w=1984&q=${SETTINGS.quality} 1984w, |
import React from "react"; | |
import "./ResponsiveImage.scss"; | |
class ResponsiveImage extends React.Component { | |
render() { | |
const responsiveImage = this.props.photo; | |
const baseURL = responsiveImage.fields.image.fields.file.url; | |
const caption = responsiveImage.fields.caption; | |
return ( | |
<figure className="responsive-image" key={`${responsiveImage.sys.id}`}> |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>RaffleBot</title> | |
</head> | |
<body> | |
<div class="centered"> | |
<h1>RaffleBot</h1> | |
<button id="raffle" class="alert">Raffle Time!!!</button> | |
</div> |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>RaffleBot</title> | |
</head> | |
<body> | |
<div class="centered"> | |
<h1>RaffleBot</h1> | |
<button id="raffle" class="alert">Raffle Time!!!</button> | |
</div> |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>RaffleBot</title> | |
</head> | |
<body> | |
<div class="centered"> | |
<h1>RaffleBot</h1> | |
<button id="raffle" class="alert">Raffle Time!!!</button> | |
</div> |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>RaffleBot</title> | |
</head> | |
<body> | |
<div class="centered"> | |
<h1>RaffleBot</h1> | |
<button id="raffle" class="alert">Raffle Time!!!</button> | |
</div> |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Page Title</title> | |
</head> | |
<body> | |
<p>You can close the HTML, CSS, and Output panels. You will not need them since we will be working in the browser's console! :)</p> | |
<p>All you need is the Javascript panel!</p> | |
</body> | |
</html> |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Page Title</title> | |
</head> | |
<body> | |
<p>You can close the HTML, CSS, and Output panels. You will not need them since we will be working in the browser's console! :)</p> | |
<p>All you need is the Javascript panel!</p> | |
</body> | |
</html> |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Page Title</title> | |
</head> | |
<body> | |
<p>You can close the HTML, CSS, and Output panels. You will not need them since we will be working in the browser's console! :)</p> | |
<p>All you need is the Javascript panel!</p> | |
</body> | |
</html> |