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.
div.c-box.c-box01
h1.u-mt-vh.u-mx-20per.u-fontSize-40.c-parapara NorthDetail
p.u-mx-20per.u-mb-3.u-fontSize-20.c-appearance From Hokkaido to the world<br>Engineering from Hokkaido to the world,<br>Aiming to create valuable services for the future of the digital society<br>Aiming to create valuable services
p.u-mx-20per.u-mb-1.u-fontSize-20.c-appearance We believe in the future of a democratic digital society, and we are committed to promoting businesses that adapt to an era of revolutionizing society based on fundamental technologies such as cloud, mobile, IoT, blockchain, and AI. With this mission, we believe in a democratic and digital society future, and we will promote businesses that adapt to the times to revolutionize society based on key technologies such as cloud, mobile, IoT, blockchain, and AI.
p.u-mx-20per.u-mb-6.u-fontSize-20.c-appearance In the 21st century, we will move toward an open, autonomous, decentralized, diversity-oriented society that prioritizes things, emotions, empathy, and humanity, and that asks why do we do what we do? The society is shifting to a society centered on Why do we do it?<br>Aiming to create valuable services in this age of digital society, North Details will develop engineering services not only in Hokkaido and Japan, but also in the world, with an awareness of making things under the slogan Create Social Value and a commitment to making things. We will develop engineering not only in Hokkaido and Japan, but also in the world.
div.c-cube-box.c-cube-box01
ul.c-cube
- for (var cc = 0; cc < 6; cc++)
li
ul.c-cube.c-cube-large
- for (var hh = 0; hh < 6; hh++)
li
div.c-cube-box.c-cube-box02
ul.c-cube
- for (var cc = 0; cc < 6; cc++)
li
ul.c-cube.c-cube-large
- for (var hh = 0; hh < 6; hh++)
li
div.c-cube-box.c-cube-box03
ul.c-cube
- for (var cc = 0; cc < 6; cc++)
li
ul.c-cube.c-cube-large
- for (var hh = 0; hh < 6; hh++)
li
div.c-box.c-box02
h2.u-mx-20per.u-fontSize-30.c-parapara About us
p.u-mx-20per.u-mb-3.u-fontSize-20.c-appearance From Hokkaido to the world<br>Engineering from Hokkaido to the world,<br>Aiming to create valuable services for the future of the digital society<br>Aiming to create valuable services
p.u-mx-20per.u-mb-1.u-fontSize-20.c-appearance We believe in the future of a democratic digital society, and we are committed to promoting businesses that adapt to an era of revolutionizing society based on fundamental technologies such as cloud, mobile, IoT, blockchain, and AI. With this mission, we believe in a democratic and digital society future, and we will promote businesses that adapt to the times to revolutionize society based on key technologies such as cloud, mobile, IoT, blockchain, and AI.
p.u-mx-20per.u-mb-6.u-fontSize-20.c-appearance In the 21st century, we will move toward an open, autonomous, decentralized, diversity-oriented society that prioritizes things, emotions, empathy, and humanity, and that asks why do we do what we do? The society is shifting to a society centered on Why do we do it?<br>Aiming to create valuable services in this age of digital society, North Details will develop engineering services not only in Hokkaido and Japan, but also in the world, with an awareness of making things under the slogan Create Social Value and a commitment to making things. We will develop engineering not only in Hokkaido and Japan, but also in the world.
div.c-cube-box.c-cube-box04
ul.c-cube
- for (var cc = 0; cc < 6; cc++)
li
ul.c-cube.c-cube-large
- for (var hh = 0; hh < 6; hh++)
li
div.c-cube-box.c-cube-box05
ul.c-cube
- for (var cc = 0; cc < 6; cc++)
li
ul.c-cube.c-cube-large
- for (var hh = 0; hh < 6; hh++)
li
div.c-box.c-box03
h2.u-mx-20per.u-fontSize-30.c-parapara Concept
p.u-mx-20per.u-mb-3.u-fontSize-20.c-appearance From Hokkaido to the world<br>Engineering from Hokkaido to the world,<br>Aiming to create valuable services for the future of the digital society<br>Aiming to create valuable services
p.u-mx-20per.u-mb-1.u-fontSize-20.c-appearance We believe in the future of a democratic digital society, and we are committed to promoting businesses that adapt to an era of revolutionizing society based on fundamental technologies such as cloud, mobile, IoT, blockchain, and AI. With this mission, we believe in a democratic and digital society future, and we will promote businesses that adapt to the times to revolutionize society based on key technologies such as cloud, mobile, IoT, blockchain, and AI.
p.u-mx-20per.u-mb-6.u-fontSize-20.c-appearance In the 21st century, we will move toward an open, autonomous, decentralized, diversity-oriented society that prioritizes things, emotions, empathy, and humanity, and that asks why do we do what we do? The society is shifting to a society centered on Why do we do it?<br>Aiming to create valuable services in this age of digital society, North Details will develop engineering services not only in Hokkaido and Japan, but also in the world, with an awareness of making things under the slogan Create Social Value and a commitment to making things. We will develop engineering not only in Hokkaido and Japan, but also in the world.
div.c-cube-box.c-cube-box06
ul.c-cube
- for (var cc = 0; cc < 6; cc++)
li
ul.c-cube.c-cube-large
- for (var hh = 0; hh < 6; hh++)
li
div.c-cube-box.c-cube-box07
ul.c-cube
- for (var cc = 0; cc < 6; cc++)
li
ul.c-cube.c-cube-large
- for (var hh = 0; hh < 6; hh++)
li
div.c-box.c-box04
h2.u-mx-20per.u-fontSize-30.c-parapara Privacy Policy
p.u-mx-20per.u-mb-3.u-fontSize-20.c-appearance From Hokkaido to the world<br>Engineering from Hokkaido to the world,<br>Aiming to create valuable services for the future of the digital society<br>Aiming to create valuable services
p.u-mx-20per.u-mb-1.u-fontSize-20.c-appearance We believe in the future of a democratic digital society, and we are committed to promoting businesses that adapt to an era of revolutionizing society based on fundamental technologies such as cloud, mobile, IoT, blockchain, and AI. With this mission, we believe in a democratic and digital society future, and we will promote businesses that adapt to the times to revolutionize society based on key technologies such as cloud, mobile, IoT, blockchain, and AI.
p.u-mx-20per.u-mb-6.u-fontSize-20.c-appearance In the 21st century, we will move toward an open, autonomous, decentralized, diversity-oriented society that prioritizes things, emotions, empathy, and humanity, and that asks why do we do what we do? The society is shifting to a society centered on Why do we do it?<br>Aiming to create valuable services in this age of digital society, North Details will develop engineering services not only in Hokkaido and Japan, but also in the world, with an awareness of making things under the slogan Create Social Value and a commitment to making things. We will develop engineering not only in Hokkaido and Japan, but also in the world.
div.c-cube-box.c-cube-box08
ul.c-cube
- for (var cc = 0; cc < 6; cc++)
li
ul.c-cube.c-cube-large
- for (var hh = 0; hh < 6; hh++)
li
div.c-cube-box.c-cube-box09
ul.c-cube
- for (var cc = 0; cc < 6; cc++)
li
ul.c-cube.c-cube-large
- for (var hh = 0; hh < 6; hh++)
li
div.c-cube-box.c-cube-box10
ul.c-cube
- for (var cc = 0; cc < 6; cc++)
li
ul.c-cube.c-cube-large
- for (var hh = 0; hh < 6; hh++)
li
div.p-collage
div.p-collage-tree
ul.p-collage-element
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/flower01.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/flower02.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/flower03.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/flower04.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/flower05.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/flower06.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/flower07.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/flower08.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/flower09.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/flower10.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/flower11.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/flower12.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/flower13.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/bill01.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/bill02.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/bill03.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/bill04.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/bill05.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/bill06.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/bill07.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/bill08.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/bill09.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/bill10.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/bill11.png")
li
img(src="https://www.northdetail.co.jp/wp-content/uploads/2024/04/bill12.png")
p.u-fontSize-40.c-parapara Q.E.D.٩(๑❛ᴗ❛๑)۶
div.line-box
ul.linesL
- for (var ll = 0; ll < 12; ll++)
li
ul.linesR
- for (var rr = 0; rr < 12; rr++)
li
/*---------------------------------------------------------
前にどこかで『みっくすぶれんどもーどなんて使う?』って
会話があったので使ってみた。
使いようによっては勝手に見やすくしてくれるので便利は便利
ユーザビリティ的にクリアなのかどうか門脇さんに聞いてみたい
---------------------------------------------------------*/
/*--reSet--*/
*{
margin:0;
padding:0;
color:#fff;
font-family:Courier;
box-sizing:border-box;
text-shadow:0 0 5px #fff;
}
body{
width:100%;
overflow-x:hidden;
}
/*--moDule--*/
.u-mb-1{margin-bottom:.5em;}
.u-mb-3{margin-bottom:1.5em;}
.u-mb-6{margin-bottom:3em;}
.u-mt-vh{margin-top:100vh}
.u-mx-20per{margin-left:20%;margin-right:20%;}
.u-fontSize-20{font-size:20px;}
.u-fontSize-30{font-size:30px;}
.u-fontSize-40{font-size:40px;}
.u-justifyContent-right{justify-content:right;}
/*--teXt--*/
.c-appearance{
margin-top:6em;
opacity:0;
transition:all .5s ease;
&.js-switch_on{
margin-top:0;
opacity:1;
}
}
/*--paraPara--*/
.c-parapara{
display:flex;
white-space:wrap;
word-wrap:break-word;
height:2em;
position:relative;
overflow:hidden;
span{
line-height:2;
display:block;
width:.75em;
position:relative;
top:2em;
}
}
@for $i from 0 to 15{
.c-parapara.js-switch_on span:nth-child(#{$i + 1}){
animation:guruguru 1s steps(36,end) #{$i * .25}s 1 forwards;
}
}
@keyframes guruguru {
0%{top:2em;}
100%{top:-70em;}
}
/*--cubeComponents--*/
.c-box{
position:relative;
transform-style:preserve-3d;
/* &.c-box04::after{
content:'';
width:100%;
height:40%;
position:absolute;
top:30%;
left:0;
background:repeating-linear-gradient(#333, #333 50px, #fff 50px, #fff 100px);
mix-blend-mode:difference;
transform:skewy(-10deg);
opacity:1;
transition:all 1s ease;
}*/
}
.c-cube-box{
display:none;
position:absolute;
&01,
&06,
&09{
left:36px;
}
&05{
left:36px;
transform:scale(1.5);
}
&10{
left:36px;
transform:scale(2);
}
&03,
&07,
&08{
right:36px;
}
&02,
&04{
right:36px;
transform:scale(1.5);
}
}
.c-cube{
list-style:none;
margin:0 auto;
width:60px;
height:60px;
position:relative;
transform-origin:50% 50% -30px;
transform-style:preserve-3d;
animation:kurukuru 12s linear infinite;
li{
font-size:0;
width:60px;
height:60px;
border:2px solid #ccc;
position:absolute;
opacity:.5;
&:nth-child(2){
transform:translateZ(-60px);
}
&:nth-child(3){
transform-origin:bottom;
transform:rotateX(90deg);
}
&:nth-child(4){
transform-origin:top;
transform:rotateX(-90deg);
}
&:nth-child(5){
transform-origin:left;
transform:rotateY(90deg);
}
&:last-child{
transform-origin:right;
transform:rotateY(-90deg);
}
}
&-large{
width:120px;
height:120px;
position:absolute;
transform-origin:50% 50% -60px;
top:-30px;
left:calc(50% - 60px);
animation:kurukuru 5s linear infinite;
li{
width:120px;
height:120px;
&:nth-child(2){
transform:translateZ(-120px);
}
}
}
}
@keyframes kurukuru{
0% {transform:rotateX(0turn) rotateY(0turn) rotateZ(0turn);}
100% {transform:rotateX(1turn) rotateY(2turn) rotateZ(1turn)}
}
/*--proDuct--*/
.p-collage{
margin-top:500px;
height:475vh;
position:relative;
pointer-events:none;
&:after{
content:"";
width:100%;
height:80px;
position:fixed;
bottom:0;
left:0;
background:#333;
transition:all 1s ease;
opacity:0;
}
&-tree{
width:100%;
height:150px;
position:fixed;
bottom:80px;
left:-100%;
background:url("https://www.northdetail.co.jp/wp-content/uploads/2024/04/tree-1024x68.png") bottom repeat-x;
z-index:2;
opacity:0;
transition:all .25s ease;
}
&-element{
list-style:none;
width:1010px;
height:480px;
position:fixed;
bottom:40px;
left:50%;
transform:translateX(-50%);
z-index:1;
li{
display:none;
position:absolute;
&:nth-child(1){
z-index:2;
}
&:nth-child(2){
z-index:3;
}
&:nth-child(3){
z-index:7;
}
&:nth-child(4){
z-index:9;
}
&:nth-child(5){
z-index:10;
}
&:nth-child(6){
z-index:11;
}
&:nth-child(7){
z-index:17;
}
&:nth-child(8){
z-index:18;
}
&:nth-child(9){
z-index:19;
}
&:nth-child(10){
z-index:20;
}
&:nth-child(11){
z-index:22;
}
&:nth-child(12){
z-index:24;
}
&:nth-child(13){
z-index:25;
}
&:nth-child(14){
z-index:1;
}
&:nth-child(15){
z-index:4;
}
&:nth-child(16){
z-index:5;
}
&:nth-child(17){
z-index:6;
}
&:nth-child(18){
z-index:8;
}
&:nth-child(19){
z-index:12;
}
&:nth-child(20){
z-index:13;
}
&:nth-child(21){
z-index:14;
}
&:nth-child(22){
z-index:15;
}
&:nth-child(23){
z-index:16;
}
&:nth-child(24){
z-index:21;
}
&:nth-child(25){
z-index:23;
}
}
}
p{
position:absolute;
bottom:0;
right:20px;
z-index:3;
}
&.js-switch_on{
&:after{
opacity:1;
}
.p-collage-tree{
left:0;
opacity:1;
}
}
}
/*--eFFect--*/
.line-box{
height:100vh;
width:100%;
position:fixed;
top:0;
left:0;
background:#333;
overflow:hidden;
z-index:-1;
opacity:.75;
ul{
list-style:none;
height:100%;
transform-style:preserve-3d;
li{
width:1px;
height:100%;
position:absolute;
left:0;
bottom:0;
background:#aaa;
transform-origin:bottom;
opacity:.75;
}
}
.linesR{
position:absolute;
top:20%;
right:10%;
transform:rotate(-135deg);
li{
opacity:.25;
}
}
}
@for $i from 0 to 12{
.line-box li:nth-child(#{$i + 1}) {
animation:line #{($i * .2) + 1}s linear infinite;
}
}
@keyframes line{
0% {transform:perspective(100px) rotateZ(90deg) rotateX(-1deg);}
100% {transform:perspective(100px) rotateZ(0deg) rotateX(-50deg);}
}
/*---------------------------------------------------------------------------------------------
いつものようにjQueryによる実装(。◕ˇдˇ◕。)/
スクロールイベントで制御しているのは以下三点(絶対値指定しているものは可動領域も制御)
1.指定した要素がスクロールによって画面下部から50pxの位置にきたら発火@L15-22
※50pxマージンを設けたのは視野効果が見えないところで終わってしまうのを回避するため
2.立方体のパララックス効果(スクロール依存速度制御/動的可動領域制御)@L24-58
※分かりやすいように全てcss@top値を制御、切れ目を考慮してフェード制御@基準点はL27に記載
3.コラージュCGの表示・非表示制御@L59-66
※1つ1つ設定するとあまりにも冗長になる懸念があったため等間隔制御にした
---------------------------------------------------------------------------------------------*/
$(window).on('load scroll', function() {
let windowH = $(window).height();
let scrollT = $(window).scrollTop();
/*--scrollTrigger--*/
$('.c-parapara,.c-appearance,.p-collage').each(function(){
const pos_trigger = $(this).offset().top;
if (scrollT > pos_trigger - windowH + 50){
$(this).addClass('js-switch_on');
}else{
$(this).removeClass('js-switch_on');
}
})
/*--paraLLax--*/
const pos_box01 = $('.c-box01').offset().top;
const h_box01 = $('.c-box01').height();
if(pos_box01 < scrollT + windowH && scrollT < pos_box01 + h_box01){
// $('.c-cube-box01').css({top:(scrollT - pos_box01) + 'px'}).fadeIn('1000');@upperFixed
$('.c-cube-box01').css({top:(scrollT - pos_box01) * 2 + windowH + 'px'}).fadeIn('1000');
$('.c-cube-box02').css({top:(pos_box01 - scrollT) * 1.5 + (windowH / 3) + 'px'}).fadeIn('1000');
$('.c-cube-box03').css({top:(pos_box01 - scrollT) / 3 + windowH + 'px'}).fadeIn('1000');
}else{
$('.c-cube-box01,.c-cube-box02,.c-cube-box03').fadeOut('1500');//.removeAttr('style')
}
const pos_box02 = $('.c-box02').offset().top;
const h_box02 = $('.c-box02').height();
if(pos_box02 < scrollT + windowH && scrollT < pos_box02 + h_box02){
$('.c-cube-box04').css({top:(scrollT - pos_box02) * 2 + windowH + 'px'}).fadeIn('1000');
$('.c-cube-box05').css({top:(pos_box02 - scrollT) + (windowH / 2) + 'px'}).fadeIn('1000');
}else{
$('.c-cube-box04,.c-cube-box05').fadeOut('1500');
}
const pos_box03 = $('.c-box03').offset().top;
const h_box03 = $('.c-box03').height();
if(pos_box03 < scrollT + windowH && scrollT < pos_box03 + h_box03){
$('.c-cube-box06').css({top:(pos_box03 - scrollT) / 1.6 + (windowH / 3) + 'px'}).fadeIn('1000');
$('.c-cube-box07').css({top:(scrollT - pos_box03) / 3 + (windowH / 2) + 'px'}).fadeIn('1000');
}else{
$('.c-cube-box06,.c-cube-box07').fadeOut('1500');
}
const pos_box04 = $('.c-box04').offset().top;
const h_box04 = $('.c-box04').height();
if(pos_box04 < scrollT + windowH && scrollT < pos_box04 + h_box04){
$('.c-cube-box08').css({top:(pos_box04 - scrollT) / 1.75 + (windowH / 2) + 'px'}).fadeIn('1000');
$('.c-cube-box09').css({top:(pos_box04 - scrollT) * 1.3333 + (windowH / 5) + 'px'}).fadeIn('1000');
$('.c-cube-box10').css({top:(scrollT - pos_box04) / 3 + 500 + 'px'}).fadeIn('1000');
}else{
$('.c-cube-box08,.c-cube-box09,.c-cube-box10').fadeOut('1500');
}
$('.p-collage-element li').each(function(i){
const pos_collage = $('.p-collage').offset().top;
if(pos_collage < scrollT - (i * windowH * 0.15) + (windowH * 0.2)){
$('.p-collage-element li').eq(24 - i).fadeIn('1000');
}else{
$('.p-collage-element li').eq(24 - i).fadeOut('1000');
}
})
})
/*--paraparaText--*/
$(".c-parapara").each(function() {
let text = $.trim(this.textContent),
html = "";
text.split("").forEach(function(parapara) {
const count = 35;
const paratext = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";
let characterGroup = paratext.length;
let string = "";
for(var i=0; i<count; i++){
string += paratext[Math.floor(Math.random()*characterGroup)];
}
html += "<span>" + string + parapara + "</span>";
});
this.innerHTML = html;
})
Also see: Tab Triggers