HTML preprocessors can make writing HTML more powerful or convenient. For instance, Markdown is designed to be easier to write and read for text documents and you could write a loop in Pug.
In CodePen, whatever you write in the HTML editor is what goes within the <body>
tags in a basic HTML5 template. So you don't have access to higher-up elements like the <html>
tag. If you want to add classes there that can affect the whole document, this is the place to do it.
In CodePen, whatever you write in the HTML editor is what goes within the <body>
tags in a basic HTML5 template. If you need things in the <head>
of the document, put that code here.
The resource you are linking to is using the 'http' protocol, which may not work when the browser is using https.
CSS preprocessors help make authoring CSS easier. All of them offer things like variables and mixins to provide convenient abstractions.
It's a common practice to apply CSS to a page that styles elements such that they are consistent across all browsers. We offer two of the most popular choices: normalize.css and a reset. Or, choose Neither and nothing will be applied.
To get the best cross-browser support, it is a common practice to apply vendor prefixes to CSS properties and values that require them to work. For instance -webkit-
or -moz-
.
We offer two popular choices: Autoprefixer (which processes your CSS server-side) and -prefix-free (which applies prefixes via a script, client-side).
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.
You can apply CSS to your Pen from any stylesheet on the web. Just put a URL to it here and we'll apply it, in the order you have them, before the CSS in the Pen itself.
If the stylesheet you link to has the file extension of a preprocessor, we'll attempt to process it before applying.
You can also link to another Pen here, and we'll pull the CSS from that Pen and include it. If it's using a matching preprocessor, we'll combine the code before preprocessing, so you can use the linked Pen as a true dependency.
JavaScript preprocessors can help make authoring JavaScript easier and more convenient.
Babel includes JSX processing.
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.
You can apply a script from anywhere on the web to your Pen. Just put a URL to it here and we'll add it, in the order you have them, before the JavaScript in the Pen itself.
If the script you link to has the file extension of a preprocessor, we'll attempt to process it before applying.
You can also link to another Pen here, and we'll pull the JavaScript from that Pen and include it. If it's using a matching preprocessor, we'll combine the code before preprocessing, so you can use the linked Pen as a true dependency.
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.
Using packages here is powered by Skypack, which makes packages from npm not only available on a CDN, but prepares them for native JavaScript ES6 import
usage.
All packages are different, so refer to their docs for how they work.
If you're using React / ReactDOM, make sure to turn on Babel for the JSX processing.
If active, Pens will autosave every 30 seconds after being saved once.
If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.
If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.
Visit your global Editor Settings.
<header>
<div class="top-nav">
<ul>
<!-- Logo -->
<div class="logo">
<img src="https://app.greenrope.com/users/myteam42198/Media426.png">
</div>
<!-- Nav List -->
<li><a>Home</a></li>
<li>
<a>Contacts</a>
</li>
<li><a>Communicate</a></li>
<li><a>Automation</a></li>
<li><a>Calendar</a></li>
<li><a>Apps</a></li>
<li><a>Media Library</a></li>
<div class="right-nav">
<ul>
<li><a>Guide Me</a></li>
</ul>
</div>
</ul>
</div>
</header>
<div class="sub-nav">
<ul>
<li>Group</li>
<li class="group-selector">Test Group</li>
</ul>
</div>
<!--End Nav-->
<!--Start Main Container-->
<div class="container">
<!-- Start Flexbox -->
<div class="flex-container">
<!-- Start Flexleft -->
<div class="flex-left">
<!-- Main CRM Box -->
<div class="main-box box-style1">
<div class="main-flex-nav">
<ul>
<li onclick="toggleVisibility('overview-panel')"><a class="hover-link active-link" href="#">Overview</a></li>
<li onclick="toggleVisibility('activity-panel')"><a class="hover-link" href="#"><i class="fa fa-plus p-right" aria-hidden="true"></i>Activity</a></li>
<li onclick="toggleVisibility('opportunity-panel')"><a class="hover-link" href="#"><i class="fa fa-plus p-right" aria-hidden="true"></i>Opportunity</a></li>
<li onclick="toggleVisibility('workflow-panel')"><a class="hover-link" href="#"><i class="fa fa-plus p-right" aria-hidden="true"></i>Workflow</a></li>
<li onclick="toggleVisibility('conversion-panel')"><a class="hover-link" href="#"><i class="fa fa-plus p-right" aria-hidden="true"></i>Conversion</a></li>
</ul>
</div>
<!-- Overview Panel -->
<div class="mainbox-content overview-content" id="overview-panel">
<!-- Left Panel: Activities -->
<div class="overview-left">
<div class="lead-scoring-main">
<h3>Activity Lead Scoring</h3>
<div>
<p>Current Score:</p>
</div>
<p><span style="color:#49BD7F; font-size: 24px;">14.5 </span><a href="#"><i class="fa fa-caret-up" aria-hidden="true"></i></a></p>
</div>
</div>
<!-- Middle Panel: Opportunities -->
<div class="overview-middle">
<div class="lead-scoring-main">
<h3>Demographic Lead Scoring</h3>
<div>
<p>Current Score:</p>
</div>
<p><span style="color:#47A3E8; font-size: 24px;">14.5</span></p>
</div>
</div>
<!-- Right Panel: Revenue -->
<div class="overview-right">
<!-- Revenue Block -->
<div class="revenue-details">
<h3>Revenue Collected</h3>
<div>
<label><a href="#">All</a></label>
<label><a href="#">YTD</a></label>
<label><a href="#">MTD</a></label>
<label><a href="#">365</a></label>
<label><a href="#">30</a></label>
</div>
<p><span style="font-size: 24px; color: #49BD7F;">$5,299.04</span></p>
</div>
</div>
</div>
<!-- Activity Panel -->
<div class="mainbox-content" id="activity-panel">
<p>Add New Activity</p>
</div>
<!-- Wprkflow Panel -->
<div class="mainbox-content" id="workflow-panel">
<p>Add New Workflow</p>
</div>
<!-- Opportunity Panel -->
<div class="mainbox-content" id="opportunity-panel">
<p>Add New Opportunity</p>
</div>
<!-- Conversion Panel -->
<div class="mainbox-content" id="conversion-panel">
<p>Add New Conversion</p>
</div>
</div>
<!-- Opportunity Section -->
<div class="opp-title">
<p>Current Opportunities (2)</p>
</div>
<!-- Opportunity 1-->
<div class="item">
<div class="image">
<div class="green-dot">
<i class="fa fa-star crm-icon" aria-hidden="true"></i>
</div>
</div>
<div class="details">
<div class="box-style1">
<h1>Opportunity Name | VAR Circle Media</h1>
<img style="width: 100%; margin-top: 1%;" src="https://app.greenrope.com/users/myteam42198/Media427.png">
<!-- Left Col -->
<div class="opp-card">
<div>
<p><span>Managed By:</span> Austin Willms</p>
<p><span>Associated Contacts:</span> also associated with Circle Media</p>
<p><span>Products:</span></p>
<ul>
<li>VAR Account ($5,000.00 USD)</li>
</ul>
</div>
<!-- Mid Col -->
<div>
<p><span>Proposal Due:</span> Wed, 2017-Jun-21</p>
<p><span>Close Date:</span> Sun, 2017-May-7</p>
<p><span>Created On:</span> Fri, 2017-Apr-7 at 12:29 PM</p>
<p><span>Opportunity #:</span> 331</p>
</div>
<!-- Right Col -->
<div>
<p><span>Value:</span> $5,000</p>
<p><span>Percentage:</span> 10% Win</p>
<p><span>Weighted Value:</span> $2,000</p>
</div>
</div>
<div class="opp-edit">
<a href="#">Create new quote or invoice</a>
<a href="#">Opportunity Connected Workflow</a>
</div>
</div>
</div>
</div>
<!-- Opportunity 2 -->
<div class="item">
<div class="image">
<div>
<i class="fa fa-star crm-icon" aria-hidden="true"></i>
</div>
</div>
<div class="details">
<div class="box-style1">
<h1>Opportunity Name</h1>
<h3>Group 1: This is where the content of the note will go</h3>
<p>Due: Friday, March 1st, 2017 at 4:45pm</p>
<p>Upon completion, activate workflow: workflow name</p>
</div>
</div>
</div>
<!-- Filter Section-->
<div class="filter">
<p>Port the filter section here</p>
</div>
<!-- Start CRM Activities -->
<!-- Item 1-->
<div class="item">
<div class="image">
<div>
<i class="fa fa-sticky-note crm-icon" aria-hidden="true"></i>
</div>
</div>
<div class="details">
<div class="box-style1">
<h1>Make Note</h1>
<h3>Group 1: This is where the content of the note will go</h3>
<p>Due: Friday, March 1st, 2017 at 4:45pm</p>
<p>Upon completion, activate workflow: workflow name</p>
</div>
</div>
</div>
<!-- Test Item: 2 Col-->
<div class="item">
<div class="image">
<div>
<i class="fa fa-comment crm-icon" aria-hidden="true"></i>
</div>
</div>
<div class="details">
<div class="box-style1">
<h1>Sent Email</h1>
<div class="item-col-container">
<!-- Left Col -->
<div class="item-left">
<h3>Group 1: This is where the content of the note will go</h3>
</div>
<!-- Right Col -->
<div class="item-right">
<p>Due: Friday, March 1st, 2017 at 4:45pm</p>
<p>Upon completion, activate workflow: workflow name</p>
</div>
</div>
</div>
</div>
</div>
<!-- Item 2-->
<div class="item">
<div class="image">
<div>
<i class="fa fa-comment crm-icon" aria-hidden="true"></i>
</div>
</div>
<div class="details">
<div class="box-style1">
<h1>Send SMS</h1>
<h3>Group 1: This is where the content of the note will go</h3>
<p>Due: Friday, March 1st, 2017 at 4:45pm</p>
<p>Upon completion, activate workflow: workflow name</p>
</div>
</div>
</div>
<!-- Item 3-->
<div class="item">
<div class="image">
<div>
<i class="fa fa-globe crm-icon" aria-hidden="true"></i>
</div>
</div>
<div class="details">
<div class="box-style1">
<h1>31 Website Visits</h1>
<h3>Group 1: This is where the content of the note will go</h3>
<p>Due: Friday, March 1st, 2017 at 4:45pm</p>
<p>Upon completion, activate workflow: workflow name</p>
</div>
</div>
</div>
</div>
<!-- End Flex Left-->
<!-- Start Flex Right -->
<div class="flex-right">
<!-- Files -->
<div class="rightpane-card box-style1">
<div>
<h1 class="files-accent">Files</h1>
</div>
<div class="files-details">
<p><i class="fa fa-folder-o" aria-hidden="true"></i>Hero Image 2</p>
<p><i class="fa fa-folder-o" aria-hidden="true"></i>Ops img</p>
<p><i class="fa fa-folder-o" aria-hidden="true"></i>marketing imaage</p>
<p><i class="fa fa-folder-o" aria-hidden="true"></i>Test image 4</p>
<p><i class="fa fa-folder-o" aria-hidden="true"></i>Logo Version 2</p>
</div>
<div class="button-wrapper">
<button>Add File</button>
</div>
</div>
<!-- Documents -->
<div class="rightpane-card box-style1">
<div>
<h1 class="documents-accent">Documents</h1>
</div>
<div class="document-details">
<p><i class="fa fa-file-o" aria-hidden="true"></i>GR Employee Handbook</p>
<p><i class="fa fa-file-o" aria-hidden="true"></i>GR Doc: #1</p>
<p><i class="fa fa-file-o" aria-hidden="true"></i>GR document</p>
<p><i class="fa fa-file-o" aria-hidden="true"></i>GR NDA: 2017</p>
<p><i class="fa fa-file-o" aria-hidden="true"></i>GR NDA: 2016</p>
</div>
<div class="button-wrapper">
<button>Add Document</button>
</div>
</div>
<!-- Invoices -->
<div class="rightpane-card box-style1">
<div>
<h1 class="invoice-accent">Invoices</h1>
</div>
<div class="document-details">
<p><i class="fa fa-file-text-o" aria-hidden="true"></i>Invoice: #23</p>
<p><i class="fa fa-file-text-o" aria-hidden="true"></i>Invoice: #24</p>
</div>
<div class="button-wrapper">
<button>Add Invoice</button>
</div>
</div>
<!-- Credit Cards -->
<div class="rightpane-card box-style1">
<div>
<h1 class="credit-cards-accent">View Cards</h1>
</div>
<div class="card-details">
<p><i class="fa fa-credit-card" aria-hidden="true"></i>Card 1: Visa</p>
<p><i class="fa fa-credit-card" aria-hidden="true"></i>Card 2: Amex</p>
<p><i class="fa fa-credit-card" aria-hidden="true"></i>Card 3: Mastercard</p>
</div>
<div class="button-wrapper">
<button>View</button>
</div>
</div>
<!-- Recurring Store Payments -->
<div class="rightpane-card box-style1">
<div>
<h1 class="store-accent">Recurring Store Payments</h1>
</div>
<div class="store-details">
<p><i class="fa fa-shopping-cart" aria-hidden="true"></i>Monthly Membership</p>
<p><i class="fa fa-shopping-cart" aria-hidden="true"></i>Vars and VIP Webinar</p>
<p><i class="fa fa-shopping-cart" aria-hidden="true"></i>Monthly Newsletter</p>
</div>
<div class="button-wrapper">
<button>View</button>
</div>
</div>
</div>
<!-- End Flex Right -->
</div>
<!-- End Flex -->
</div>
body {
background-color: #F9F9F9;
font-family: 'Open Sans', sans-serif;
font-size: 16px;
font-weight: 400;
text-rendering: optimizeLegibility;
margin: 0;
}
/* Updated Nav Mockup */
.logo {
float: left;
margin-left: 10px;
}
.top-nav ul {
list-style: none;
padding: 0;
margin: 0;
background: #48454A;
overflow: hidden;
}
.top-nav li a {
float: left;
font-family: 'Open Sans', sans-serif;
padding: 19px 20px;
color: white;
font-weight: 400;
font-size: 0.9em;
display: inline-block;
cursor: pointer;
}
.right-nav {
float: right;
}
.sub-nav {
background: #fcfcfc;
padding: 10px 15px;
box-shadow: 1px 1px 2px rgba(0,0,0,0.4);
}
.sub-nav ul {
list-style: none;
padding: 0;
margin: 0;
overflow: hidden;
}
.sub-nav li {
float: left;
padding: 0px 20px;
}
.sub-nav li:first-child {
padding-left: 0px;
}
.group-selector {
border: 1px solid #48454A;
}
/*End Nav Test */
.container {
width: 100%;
margin: 2%;
}
/* Flex Containers */
.flex-container {
display: flex;
flex-flow: row wrap;
justify-content: space-around;
flex-wrap: wrap !important;
width: 100%;
}
.flex-left {
-webkit-flex: 1 0 0;
flex: 1 0 0;
margin: 1em;
}
.flex-right {
-webkit-flex: 0.75 0 0;
flex: 0.75 0 0;
margin: 1em 3em;
}
.flex-right > div:first-child {
margin-top: 0px;
}
/* End Flex Containers */
.main-box {
background: #fff;
border-radius: 2px;
display: inline-block;
height: auto;
width: 850px;
}
.box-style1 {
box-shadow: 0 1px 2px rgba(0,0,0,0.16), 0 2px 4px rgba(0,0,0,0.15);
-webkit-box-shadow: 0 1px 2px rgba(0,0,0,0.16), 0 2px 4px rgba(0,0,0,0.15);
-moz-box-shadow: 0 1px 2px rgba(0,0,0,0.16), 0 2px 4px rgba(0,0,0,0.15);
}
.main-box:after {
content: '';
position: absolute;
top: 230px;
left: 115px;
bottom: 0px;
width: 4px;
background: #979797;
height: 100%;
z-index: -1;
}
/***** Navigation for Activites Nav******/
.main-flex-nav {
width: 100%;
height: 45px;
}
.main-flex-nav ul {
list-style-type: none;
margin: 0;
padding: 0;
}
.main-flex-nav li {
display: inline;
float: left;
padding: 10px 25px;
}
.main-flex-nav a {
font-size: 18px;
color: #585858;
text-decoration: none;
font-weight: 400;
cursor: pointer;
}
.main-flex-nav i {
padding-right: 5px;
}
.hover-link {
display: inline-block;
color: #4788CD;
text-decoration: none;
}
.hover-link::after {
content: '';
display: block;
width: 0;
height: 3px;
background: #4788CD;
transition: width .5s;
}
.hover-link:hover::after {
width: 100%;
//transition: width .5s;
}
.active-link {
display: inline-block;
color: #4788CD;
text-decoration: none;
}
.active-link::after {
content: '';
display: block;
width: 100%;
height: 3px;
background: #4788CD;
}
/*** End Navigation Activites Styles ****/
/*** Toggle Styles ***/
.mainbox-content {
margin: 15px 25px 10px;
display: none;
overflow-y: scroll;
}
.mainbox-content h1 {
font-size: 1.2em;
margin: 0;
padding: 0 0 0.5em 0;
}
.mainbox-content h3 {
font-size: 16px;
font-weight: 600;
margin: 0;
color: #565656;
}
.mainbox-content p {
margin: 0;
color: #565656;
font-size: 14px;
}
.mainbox-content p:first-child {
font-size: 16px;
}
.mainbox-flex > div:last-child {
margin-top: 30px;
}
#overview-panel {
display: flex;
}
/** End Toggle Styles ***/
/* Opportunity Card Content */
.opp-card {
display: flex;
margin-top: 2%;
}
.opp-card > div {
-webkit-flex: 1 0 0;
flex: 1 0 0;
}
.opp-card > div > p {
font-size: 12px;
}
.opp-card > div:not(:first-child) {
margin-left: 5%;
}
.opp-card div > p > span {
font-weight: 600;
}
.opp-edit {
margin-top: 2%;
}
.opp-edit a {
text-decoration: none;
color: #206bb1;
font-size: 12px;
cursor: pointer;
}
.opp-edit a:not(:last-child):after {
content: " | "
}
.opp-card ul {
margin: 0;
font-size: 12px;
color: #565656;
}
/** Overview Content **/
.overview-content {
display: flex;
}
.overview-left {
-webkit-flex: 1 0 0;
flex: 1 0 0;
margin: 0 2em 0.5em 0em;
}
.overview-middle {
-webkit-flex: 1 0 0;
flex: 1 0 0;
}
.overview-right {
-webkit-flex: 1 0 0;
flex: 1 0 0;
}
.overview-right > div {
padding-bottom: 10%;
padding-left: 2em;
}
.overview-right > div:last-child {
padding-bottom: 0;
}
/*** Filter | Opportunity Section TItle ***/
.filter {
margin-left: 132px;
}
.opp-title {
margin-left: 132px;
padding-top: 25px;
}
.opp-title p, .filter p {
font-weight: 600;
color: #565656;
}
/*** Activity Timeline Styles ***/
.crm-icon {
margin: 12px 10px;
font-size: 28px;
color: white;
}
.item {
display: -webkit-box;
display: -ms-flexbox;
display: flex;
max-width: 817px;
margin: 1% auto;
}
.item .image {
padding: 1em 2em;
}
/*** 2 Col Layout for Item cards ***/
.item-col-container {
display: flex;
}
.item-left, .item-right {
flex 1 0;
-webkit-flex: 1 0;
}
/*** Circle Icon and various colors ***/
/* Default State */
.item .image > div {
position: relative;
text-align: center;
width: 50px;
height: 50px;
background: #4990E2;
border-radius: 50%;
}
/* Upcoming State: Green */
.green-dot {
background: #5cb85c !important;
}
/* Intermediary State: Yellow */
.yellow-dot {
background: #f0ad4e !important;
}
/* Overdue State: Red */
.red-dot {
background: #c0453c !important; =
}
.item .details {
position: relative;
width: 700px;
}
.item .details > div {
background: #fff;
border-radius: 2px;
padding: 0.5em 1em;
margin: 1em 0;
}
.item .details > div h1 {
color: #565656;
font-size: 1.1em;
margin: 0;
padding: 0 0 0.5em 0;
}
.item .details > div h3 {
color: #565656;
font-size: 1.0em;
font-weight: 600;
margin: 0;
padding: 0 0 0.5em 0;
}
.item .details > div p {
margin: 0;
padding: 0 0 0.5em 0;
color: #565656;
}
/*** End Activity Timeline Styles ***/
/*** Right Side Card Style ***/
.rightpane-card {
background: #fff;
border-radius: 2px;
padding: 0.5em 1em;
max-width: 275px;
margin-top: 25px;
}
.rightpane-card h1 {
font-size: 1.1em;
margin: 0;
padding: 0 0 0.5em 0;
color: #48454a;
}
.rightpane-card h3 {
font-size: 1.0em;
font-weight: 600;
margin: 0;
padding: 0 0 0.5em 0;
color: #565656;
}
.rightpane-card p {
margin: 0;
padding: 0 0 0.5em 0;
color: #565656;
}
.rightpane-card i {
padding-right: 5px;
color: #565656;
}
/********* Card Specific Styles *******/
/*** Lead Scoring: Card Style ***/
.lead-scoring h3 {
font-size: 1.1em;
}
.lead-scoring > div {
max-height: 110px;
overflow-y: auto;
}
.lead-scoring > div > p {
font-size: 13px;
}
.lead-scoring > div > p:first-child {
color: #565656;
font-weight: bold;
}
.lead-scoring i {
padding-left: 5px;
color: #565656;
}
/*** Revenue Styles ***/
.revenue-details > div {
padding: 5px 0px;
}
.revenue-details label:not(:last-child):after {
content: " \B7 ";
}
.revenue-details a {
font-size: 16px;
color: #565656;
text-decoration: none;
cursor: pointer;
}
.revenue-details h3 {
padding: 0px;
font-size: 1.1em;
}
/* Lead Scoring Styles: Mainbox*/
.lead-scoring-main > div {
padding: 5px 0px;
}
/*** Invoice Styles ***/
.invoice-details > div {
max-height: 115px;
overflow-y: auto;
padding-bottom: 5px;
}
.invoice-details h3 {
font-size: 1.1em;
}
.invoice-details a {
color: #565656;
text-decoration: underline;
font-size: 13px;
cursor: pointer;
}
/*** File | Document | Credit | Store Styles ***/
.files-details, .document-details, .card-details, .store-details {
max-height: 130px;
overflow-y: auto;
padding: 0.5em 0em;
}
.files-details p:hover, .document-details p:hover, .card-details p:hover, .store-details p:hover {
cursor: pointer;
}
/******* Accent Colors ********/
.invoice-accent, .files-accent, .credit-cards-accent, .documents-accent, .store-accent {
display: block;
text-decoration: none;
}
/******** Some Test CSS ************/
.button-wrapper {
padding: 0.5em 0em;
}
/* Background Header: Right Card */
/*General Styles*/
.invoice-background h1, .lead-background h1, .file-background h1,
.doc-background h1, .card-background h1, .store-background h1 {
color: white;
margin: 0;
padding: 0.5em;
}
/*Invoice Background*/
.invoice-background {
background: #85b2e6;
padding: 0;
margin: 0;
}
/* Lead Scoring Background */
.lead-background {
background: #85b2e6;
padding: 0;
margin: 0;
}
/* Files Background */
.file-background {
background: #85b2e6;
padding: 0;
margin: 0;
}
/* Documents Background */
.doc-background {
background: #85b2e6;
padding: 0;
margin: 0;
}
/* Cards Background */
.card-background {
background: #85b2e6;
padding: 0;
margin: 0;
}
/* Store Background */
.store-background {
background: #85b2e6;
padding: 0;
margin: 0;
}
function toggleVisibility(selectedTab) {
var content = document.getElementsByClassName('mainbox-content');
for(var i=0; i<content.length; i++) {
if(content[i].id == selectedTab) {
content[i].style.display = 'flex';
} else {
content[i].style.display = 'none';
}
}
}
Also see: Tab Triggers