Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ add another resource

JavaScript

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

Packages

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.

Behavior

Auto Save

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.

HTML

              
                .text
	input(type="text")
.checkbox
	input(type="checkbox")
.radio
	input(type="radio" name='radio')
	input(type="radio" name='radio')
.color
	input(type="color" value='#E91E63')
.range
	input(type="range")
.button
	input(type="button" value='Button')
.file
	label(for="file") Upload 
		ion-icon(name="cloud-upload-outline")
	input#file(type="file")
.date
	input(type="date")
.number
	input(type="number" value="0")
              
            
!

CSS

              
                body {
	display: grid;
	place-content: center;
	height: 100vh;
	margin: 0;
	grid-template: repeat(3,1fr) / repeat(3,1fr);
	overflow: hidden;
	* { outline: none; }
}
div {
	display: grid;
	place-content: center;
}
// Text
input[type=text] {
	appearance: none;
	border: none;
	outline: none;
	border-bottom: .2em solid #E91E63;
	background: rgba(#E91E63, .2);
	border-radius: .2em .2em 0 0;
	padding: .4em;
	color: #E91E63;
}
// Checkbox
input[type=checkbox] {
	appearance: none;
  background-color: #fff;
  margin: 0;
	font: inherit;
  color: currentColor;
  width: 1.15em;
  height: 1.15em;
  border: 0.15em solid #E91E63;
  border-radius: 0.15em;
  transform: translateY(-0.075em);
	display: grid;
  place-content: center;
	&::before {
		content: "";
		width: 0.65em;
		height: 0.65em;
		transform: scale(0);
		transition: 120ms transform ease-in-out;
		box-shadow: inset 1em 1em #E91E63;
		background-color: CanvasText;
		clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%);
		transform-origin: left top;
	}
	&:checked::before {
		transform: scale(1);
	}
}
// Radio
div.radio {
	display: grid;
	grid-template-columns: 1fr 1fr;
	grid-gap: .2em;
	margin-left: -2em;
}
input[type=radio] {
	appearance: none;
  background-color: #fff;
  margin: 0;
	font: inherit;
  color: #E91E63;
  width: 1.15em;
  height: 1.15em;
  border: 0.15em solid currentColor;
  border-radius: 50%;
	display: grid;
  place-content: center;
	&::before {
		content: "";
		width: 0.65em;
		height: 0.65em;
		border-radius: 50%;
		transform: scale(0);
		transition: 120ms transform ease-in-out;
		box-shadow: inset 1em 1em #E91E63;
		background-color: CanvasText;
		transform-origin: top bottom;
	}
	&:checked::before {
		transform: scale(1);
	}
}
// Color
input[type=color] { 
	padding: 0;
	border: none;
	width: 2em;
	height: 2em;
	border-radius: 50%;
	&::-webkit-color-swatch {
		border: none;
		border-radius: 50%;
	}
	&::-webkit-color-swatch-wrapper {
		padding: 0;
	}
}
// Range
input[type=range] {
	appearance: none;
	background: transparent;
	width: 8em;
	@mixin slider-thumb {
		appearance: none;
		width: 1.5em;
		height: 1.5em;
		border-radius: 50%;
		background: transparent;
		border: .2em solid #E91E63;
	}
	@mixin slider-track {
		background: #E91E63;
		width: 100%;
		border-radius: 1vmin;
		height: .5em;
	}
	&::-webkit-slider-thumb { margin-top: -8px; @include slider-thumb }
	&::-moz-range-thumb { @include slider-thumb }
	&::-ms-thumb { @include slider-thumb }
	&::-webkit-slider-runnable-track { @include slider-track }
	&::-moz-range-track { @include slider-track }
	&::-ms-track { @include slider-track }
}
// Button
input[type=button] {
	appearance: none;
	border: .2em solid #E91E63;
	background: hsl(0 0 0/0);
	padding: .85em 1.5em;
	color: #E91E63;
	border-radius: 2em;
	transition: 1s;
	&:hover, &:focus, &:active {
		background: #E91E63;
		color: #fff;
	}
}
// File
input[type=file] { display: none; }
label[for=file] {
	display: grid;
	grid-auto-flow: column;
	grid-gap: .5em;
	justify-items: center;
	align-content: center;
	color: #E91E63;
	border: .2em solid #E91E63;
	background: hsl(0 0 0/0);
	padding: .85em 1.5em;
	color: #E91E63;
	border-radius: 2em;
	transition: 1s;
	&:hover, &:focus, &:active {
		background: #E91E63;
		color: #fff;
	}
}
// Date
input[type=date] {
	border: .2em solid #E91E63;
	padding: .8em .9em;
	border-radius: 2em;
	color: #E91E63;
	// &::-webkit-datetime-edit { padding: 1em; }
	// &::-webkit-datetime-edit-fields-wrapper { background: rgba(#E91E63, .2); }
	&::-webkit-datetime-edit-text { color: red; padding: 0 0.3em; }
	// &::-webkit-datetime-edit-month-field { color: #E91E63; }
	// &::-webkit-datetime-edit-day-field { color: #E91E63; }
	// &::-webkit-datetime-edit-year-field { color: #E91E63; }
	&::-webkit-inner-spin-button { display: none; }
	&::-webkit-calendar-picker-indicator {
		background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23E91E63' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='18' rx='2' ry='2'/%3E%3Cline x1='16' y1='2' x2='16' y2='6'/%3E%3Cline x1='8' y1='2' x2='8' y2='6'/%3E%3Cline x1='3' y1='10' x2='21' y2='10'/%3E%3C/svg%3E"); 
	}
}
// Number
input[type=number] {
	width: 3em;
	padding: 0.5em;
	border: .2em solid #E91E63;
	border-radius: 1em;
	text-align: center;
	color: #E91E63;
	appearance: textfield;
	margin: 0;
	&::-webkit-inner-spin-button {
		opacity: 1;
		background: red;
	}
}
              
            
!

JS

              
                
              
            
!
999px

Console