Pen Settings



CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource


Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource


Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.


Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.


                <!DOCTYPE html>
<!-- Space Crawl adapted for CSS Tricks Tutorial -->
<html lang="en" >
  <meta charset="UTF-8">
  <title>Star Wars API</title>
	<link rel="stylesheet" type="text/css" href="stylesheet.css">
	<link href="|Montserrat+Subrayada&display=swap" rel="stylesheet">
<!-- partial:index.partial.html -->
<audio id="swmusic" loop >
	<source src="">
<div id="wrapper">
<img id="logo" src="">

	<h1 id="toptext">CHARACTER STATS</h1>
	<button id="controlbtn">PLAY MUSIC</button>

	<label for="query">Search for a Character: </label>

	<input id="one">
	<button id="submit">SUBMIT</button>
<div id="output">
    <h1 id="name"></h1>
	<h1 id="birth_year"></h1>
	<h1 id="gender"></h1>
	<h1 id="height"></h1>
	<h1 id="mass"></h1>
	<h1 id="hair_color"></h1>
	<h1 id="eye_color"></h1>
	<h1 id="skin_color"></h1>		
  <script src=''></script>
    <script  src="./script.js"></script>



body {
	background:url('') #000;  
	background-size: cover;
	background-repeat: no-repeat;
	overflow: hidden;
	height: 100%;
	width: 100%;

#wrapper {
	text-align: center;
	max-width: 960px;
	margin: 32px auto;
	color: white;
    font-family: 'Montserrat', sans-serif;

#toptext {
	margin-top: 0px;
	margin-bottom: 25px;

label {
  color: white;
  padding: 10px;

button {
  background-color: black;
  color: white;
  border: 2px solid yellow;
  border-radius: 12px;	
  font-size: 18px;
  margin-left: 5px

#controlbtn {
	margin-bottom: 15px; 

button:hover {
  background-color: yellow;
  color: black;  
  cursor: pointer;	
#logo {
	margin: 0 auto;
	max-width: 300px;
	max-height: 300px;

#output {
	color: yellow;
	transform: perspective(200px) rotateX(20deg);
	animation: crawl 25s linear;
	animation-fill-mode: forwards;
	animation-play-state: paused;	
  position: relative;
  z-index: -1; 

@keyframes crawl {
	0% {
		transform: perspective(200px) rotateX(20deg) translateY(425px);
		opacity: 1;
	75% {
		opacity: 0;
	100% {
		transform: perspective(200px) rotateX(20deg) translateY(-1200px);
		opacity: 0;



                window.onload = () =>  {
	function searchAPI() {
	let query = $("#one").val().toLowerCase();
		.then(res => res.json())
		.then((out) => {
		 let name = "NAME: " + out.results[0].name;
		 let height = "HEIGHT(CM): " + out.results[0].height;
		 let birth_year = "BIRTH YEAR: " + out.results[0].birth_year;
		 let gender = "GENDER: " + out.results[0].gender;
		 let hair_color = "HAIR COLOR: " + out.results[0].hair_color;
		 let eye_color = "EYE COLOR: " + out.results[0].eye_color;
		 let mass = "MASS(KG): " + out.results[0].mass;
		 let skin_color = "SKIN COLOR: " + out.results[0].skin_color;

		document.getElementById("name").innerHTML = name;
		document.getElementById("birth_year").innerHTML = birth_year;
		document.getElementById("height").innerHTML = height;
		document.getElementById("gender").innerHTML = gender;
		document.getElementById("hair_color").innerHTML = hair_color;
		document.getElementById("eye_color").innerHTML = eye_color;
		document.getElementById("mass").innerHTML = mass;
		document.getElementById("skin_color").innerHTML = skin_color;
document.getElementById('output').style.visibility = "visible";
			$('#output').css("animation-play-state", "running");


$("#submit").click(function () {
  setTimeout(function () {
  }, 10);


var musicbutton = document.getElementById('controlbtn');

var isPlaying = false;

musicbutton.addEventListener('click', function (){

	if(isPlaying == false){
		isPlaying = true;
		musicbutton.innerHTML = 'PAUSE MUSIC';

	} else{
		isPlaying = false;
		musicbutton.innerHTML = 'PLAY MUSIC';