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 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.
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.
You can also link to another Pen here (use the .css
URL Extension) and we'll pull the CSS from that Pen and include it. If it's using a matching preprocessor, use the appropriate URL Extension and 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 esm.sh, which makes packages from npm not only available on a CDN, but prepares them for native JavaScript ESM 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>
<h1 id='title'>Tribute to, <span class="name">Steve Jobs</span> </h1>
</header>
<main id='main'>
<div class='imgDiv'>
<img id='image' src="https://cdn.profoto.com/cdn/053149e/contentassets/d39349344d004f9b8963df1551f24bf4/profoto-albert-watson-steve-jobs-pinned-image-original.jpg?width=1280&quality=75&format=jpg" alt="Steve Jobs Image">
</div>
<section id='aboutSteveJobs'>
<h3 id='aboutSteveJobsHeading'>About <strong>Steve Jobs</strong></h3>
<div id="tribute-info">
<p class='aboutSubSection'>
Steven Paul Jobs (/dʒɒbz/; February 24, 1955 – October 5, 2011) was an American business magnate,
industrial designer, investor, and media proprietor. He was the chairman, chief executive officer (CEO),
and co-founder of Apple Inc., the chairman and majority shareholder of Pixar, a member of The Walt
Disney Company's board of directors following its acquisition of Pixar, and the founder, chairman, and
CEO of NeXT. Jobs is widely recognized as a pioneer of the personal computer revolution of the 1970s and
1980s, along with Apple co-founder Steve Wozniak.
</p>
<p class='aboutSubSection'>
Jobs was born in San Francisco, California, and put up for adoption. He was raised in the San Francisco
Bay Area. He attended Reed College in 1972 before dropping out that same year, and traveled through
India in 1974 seeking enlightenment and studying Zen Buddhism.
</p>
<p class='aboutSubSection'>
Jobs and Wozniak co-founded Apple in 1976 to sell Wozniak's Apple I personal computer. Together the duo
gained fame and wealth a year later with the Apple II, one of the first highly successful mass-produced
microcomputers. Jobs saw the commercial potential of the Xerox Alto in 1979, which was mouse-driven and
had a graphical user interface (GUI). This led to the development of the unsuccessful Apple Lisa in
1983, followed by the breakthrough Macintosh in 1984, the first mass-produced computer with a GUI. The
Macintosh introduced the desktop publishing industry in 1985 with the addition of the Apple LaserWriter,
the first laser printer to feature vector graphics. Jobs was forced out of Apple in 1985 after a long
power struggle with the company's board and its then-CEO John Sculley. That same year, Jobs took a few
of Apple's members with him to found NeXT, a computer platform development company that specialized in
computers for higher-education and business markets. In addition, he helped to develop the visual
effects industry when he funded the computer graphics division of George Lucas's Lucasfilm in 1986. The
new company was Pixar, which produced the first 3D computer animated feature film Toy Story (1995), and
went on to become a major animation studio, producing over 20 films since then.
</p>
<p class='aboutSubSection'>
Jobs became CEO of Apple in 1997, following his company's acquisition of NeXT. He was largely
responsible for helping revive Apple, which had been on the verge of bankruptcy. He worked closely with
designer Jony Ive to develop a line of products that had larger cultural ramifications, beginning in
1997 with the "Think different" advertising campaign and leading to the iMac, iTunes, iTunes Store,
Apple Store, iPod, iPhone, App Store, and the iPad. In 2001, the original Mac OS was replaced with the
completely new Mac OS X (now known as macOS), based on NeXT's NeXTSTEP platform, giving the OS a modern
Unix-based foundation for the first time. Jobs was diagnosed with a pancreatic neuroendocrine tumor in
2003. He died of respiratory arrest related to the tumor at age 56 on October 5, 2011.
</p>
</div>
</section>
<section id='learnMore'>
<div class='alignCenter'> <a id='tribute-link' href="https://en.wikipedia.org/wiki/Steve_Jobs"
target='_blank'>Learn more about Steve Jobs</a> </div>
</section>
</main>
* {
margin: 0;
padding: 0;
}
html,body {
height:100%;
width:100%;
}
#title {
text-align: center;
padding-bottom: 0.3vw;
font-size: 4rem;
font-family: 'Bebas Neue', cursive;
}
main {
width:100%;
display:flex;
justify-content:center;
flex-direction:column;
align-items:center;
margin-bottom: 10vh;
}
#aboutSteveJobs {
width:95%;
box-sizing:border-box;
/* margin: 1rem 2.5rem; */
margin:1rem;
box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2);
}
.aboutSubSection {
font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
padding: 2rem;
font-size:1.2rem;
padding-bottom: 0;
}
.aboutSubSection:nth-last-of-type(1) {
padding-bottom:2rem;
}
#aboutSteveJobsHeading {
background-color: #FF9100;
color: white;
padding: .8rem 1rem;
font-size: 3rem;
font-family: 'Bebas Neue', cursive;
}
.alignCenter {
padding: 1rem;
font-size: 1.4rem;
font-family: 'Bebas Neue', cursive;
text-align: center;
}
#tribute-link {
display:block;
background-color: #FF9100;
color: white;
padding:8.5px 22px;
font-size: 1.7rem;
text-decoration: none;
text-transform: uppercase;
transition:background-color 0.25s;
margin-bottom:5rem;
}
.name {
color:#FF9100;
}
#tribute-link:hover {
background-color: #d17702;
cursor: pointer;
}
.tribute-info {
font-size: 2rem;
}
.imgDiv {
max-width: 100%;
height:auto;
display: flex;
justify-content: center;
align-content: center;
align-items: center;
flex-direction: column;
}
#image {
max-width: 100%;
width:auto;
height:25rem;
transition:opacity 0.3s;
}
#image:hover {
opacity: 0.3;
filter: alpha(opacity=40);
background-color: #000;
}
Also see: Tab Triggers