JSFiddle - React, Tailwind, and code Playground

by Aaron von Schassen

HTML

<div>
  <a onclick="myFunction();" class="first"><h1>Zurück</h1></a>
  <a onclick="myFunction2();" class="second"><h1>Vor</h1></a>
</div>

CSS

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

div {
  display: flex;
  position: fixed; /*oder position: absolute*/
  top: 0;
  flex-flow: row;
  height: 100%;
  width: 100%;
}

a {
  width: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.first {
  background: yellow;
  opacity: 0.3;
}

.second {
  background: red;
  opacity: 0.3;
}

JavaScript

function myFunction() {
	alert("zurück");
}

function myFunction2() {
	alert("vor");
}