correct pages
BIN
book-page-0.jpg
Normal file
After Width: | Height: | Size: 11 KiB |
BIN
book-page-5.jpg
Normal file
After Width: | Height: | Size: 684 KiB |
BIN
book-page-6.jpg
Normal file
After Width: | Height: | Size: 575 KiB |
Before Width: | Height: | Size: 83 KiB |
Before Width: | Height: | Size: 89 KiB |
Before Width: | Height: | Size: 95 KiB |
Before Width: | Height: | Size: 59 KiB |
342
index.html
@ -2,193 +2,193 @@
|
|||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1" >
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<main>
|
<main>
|
||||||
|
<style>
|
||||||
|
.Shot
|
||||||
|
{
|
||||||
|
transform: perspective(1000px);
|
||||||
|
transform-style: preserve-3d;
|
||||||
|
width:500px;
|
||||||
|
height: 400px;
|
||||||
|
margin:20px auto 0 auto;
|
||||||
|
text-align:center;
|
||||||
|
transition: transform 1s;
|
||||||
|
}
|
||||||
|
.Shot[show="cover"]{ transform: perspective(800px) rotateX(-15deg) rotateY(110deg); }
|
||||||
|
.Shot[show="spine"]{ transform: perspective(2000px) rotateX(0deg) rotateY(180deg); }
|
||||||
|
.Shot[show="back" ]{ transform: perspective(1000px) rotateX(-30deg) rotateY(-60deg); }
|
||||||
|
.Shot[show="pages"]{ transform: perspective(800px) rotateX(-7deg) rotateY(0deg); }
|
||||||
|
|
||||||
<style>
|
.Book
|
||||||
.Shot
|
{
|
||||||
{
|
height:100%;
|
||||||
transform: perspective(1000px);
|
transform-style: preserve-3d;
|
||||||
transform-style: preserve-3d;
|
transform: translateZ(-100px);
|
||||||
width:500px;
|
position: relative;
|
||||||
height: 400px;
|
display:inline-block;
|
||||||
margin:20px auto 0 auto;
|
}
|
||||||
text-align:center;
|
.Spine
|
||||||
transition: transform 1s;
|
{
|
||||||
}
|
display:flex;
|
||||||
.Shot[show="cover"]{ transform: perspective(800px) rotateX(-15deg) rotateY(110deg); }
|
justify-content:space-between;
|
||||||
.Shot[show="spine"]{ transform: perspective(2000px) rotateX(0deg) rotateY(180deg); }
|
margin:0 auto;
|
||||||
.Shot[show="back" ]{ transform: perspective(1000px) rotateX(-30deg) rotateY(-60deg); }
|
position:absolute;
|
||||||
.Shot[show="pages"]{ transform: perspective(800px) rotateX(-7deg) rotateY(0deg); }
|
top:0;
|
||||||
|
left:0;
|
||||||
|
width:100%;
|
||||||
|
height:100%;
|
||||||
|
}
|
||||||
|
|
||||||
.Book
|
.Page
|
||||||
{
|
{
|
||||||
height:100%;
|
display: inline-block;
|
||||||
transform-style: preserve-3d;
|
position: relative;
|
||||||
transform: translateZ(-100px);
|
transition: transform 1s;
|
||||||
position: relative;
|
transform-style: preserve-3d;
|
||||||
display:inline-block;
|
}
|
||||||
}
|
.Page[swing="closed"]{ transform: translateX(0px) rotateY(-90deg); }
|
||||||
.Spine
|
.Page[swing="right" ]{ transform: translateX(-3px) rotateY(-20deg); }
|
||||||
{
|
.Page[swing="left" ]{ transform: translateX(3px) rotateY(-160deg); }
|
||||||
display:flex;
|
.Page .Front, .Page .Back
|
||||||
justify-content:space-between;
|
{
|
||||||
margin:0 auto;
|
float:left;
|
||||||
position:absolute;
|
position:absolute;
|
||||||
top:0;
|
top:0;
|
||||||
left:0;
|
left:0;
|
||||||
width:100%;
|
height:100%;
|
||||||
height:100%;
|
backface-visibility: hidden;
|
||||||
}
|
transform-style: preserve-3d;
|
||||||
|
transform: rotateY(180deg);
|
||||||
|
}
|
||||||
|
.Page .Back
|
||||||
|
{
|
||||||
|
transform: rotateY(0deg);
|
||||||
|
}
|
||||||
|
.Page img
|
||||||
|
{
|
||||||
|
height:100%;
|
||||||
|
width:auto;
|
||||||
|
}
|
||||||
|
|
||||||
.Page
|
.Page--Fill
|
||||||
{
|
{
|
||||||
display: inline-block;
|
display: block;
|
||||||
position: relative;
|
position:absolute;
|
||||||
transition: transform 1s;
|
top:0;
|
||||||
transform-style: preserve-3d;
|
left:0;
|
||||||
}
|
width:100%;
|
||||||
.Page[swing="closed"]{ transform: translateX(0px) rotateY(-90deg); }
|
height:100%;
|
||||||
.Page[swing="right" ]{ transform: translateX(-3px) rotateY(-20deg); }
|
}
|
||||||
.Page[swing="left" ]{ transform: translateX(3px) rotateY(-160deg); }
|
.Page--Shrink
|
||||||
.Page .Front, .Page .Back
|
{
|
||||||
{
|
height:98%;
|
||||||
float:left;
|
top:1%;
|
||||||
position:absolute;
|
}
|
||||||
top:0;
|
.Shadow--Drop::before
|
||||||
left:0;
|
{
|
||||||
height:100%;
|
transform: rotateX(90deg) translateY(-100px) translateZ(-3px);
|
||||||
backface-visibility: hidden;
|
box-shadow: 0px 100px 60px black, 0px 100px 17px black;
|
||||||
transform-style: preserve-3d;
|
display: block;
|
||||||
transform: rotateY(180deg);
|
position: absolute;
|
||||||
}
|
top: 100%;
|
||||||
.Page .Back
|
content: " ";
|
||||||
{
|
width: 100%;
|
||||||
transform: rotateY(0deg);
|
height: 8px;
|
||||||
}
|
border-radius: 39px;
|
||||||
.Page img
|
}
|
||||||
{
|
|
||||||
height:100%;
|
|
||||||
width:auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
.Page--Fill
|
.Shadow--Sheet::after
|
||||||
{
|
{
|
||||||
display: block;
|
content:" ";
|
||||||
position:absolute;
|
|
||||||
top:0;
|
|
||||||
left:0;
|
|
||||||
width:100%;
|
|
||||||
height:100%;
|
|
||||||
}
|
|
||||||
.Page--Shrink
|
|
||||||
{
|
|
||||||
height:98%;
|
|
||||||
top:1%;
|
|
||||||
}
|
|
||||||
.Shadow--Drop::before
|
|
||||||
{
|
|
||||||
transform: rotateX(90deg) translateY(-100px) translateZ(-3px);
|
|
||||||
box-shadow: 0px 100px 60px black, 0px 100px 17px black;
|
|
||||||
display: block;
|
|
||||||
position: absolute;
|
|
||||||
top: 100%;
|
|
||||||
content: " ";
|
|
||||||
width: 100%;
|
|
||||||
height: 8px;
|
|
||||||
border-radius: 39px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.Shadow--Sheet::after
|
background-size: 100% 100%;
|
||||||
{
|
background-position: 0px 0px;
|
||||||
content:" ";
|
background-image: conic-gradient(from 0deg at 0% 0%, #00000000 33%, #000000FF 75%);
|
||||||
|
|
||||||
background-size: 100% 100%;
|
display:block;
|
||||||
background-position: 0px 0px;
|
position:absolute;
|
||||||
background-image: conic-gradient(from 0deg at 0% 0%, #00000000 33%, #000000FF 75%);
|
z-index:100;
|
||||||
|
top:0;
|
||||||
|
left:0;
|
||||||
|
width:100%;
|
||||||
|
height:100%;
|
||||||
|
|
||||||
display:block;
|
backface-visibility: hidden;
|
||||||
position:absolute;
|
transform:scaleX(-1);
|
||||||
z-index:100;
|
}
|
||||||
top:0;
|
.Shadow--Sheet--Flip::after
|
||||||
left:0;
|
{
|
||||||
width:100%;
|
transform:scaleX(1);
|
||||||
height:100%;
|
}
|
||||||
|
|
||||||
backface-visibility: hidden;
|
.Shadow--Radiosity::after
|
||||||
transform:scaleX(-1);
|
{
|
||||||
}
|
content: " ";
|
||||||
.Shadow--Sheet--Flip::after
|
background-size: 100% 100%;
|
||||||
{
|
background-position: 0px 0px;
|
||||||
transform:scaleX(1);
|
background-image: radial-gradient(188% 24% at 50% 82%, #ffffff52 0%, #0000 100%);
|
||||||
}
|
display: block;
|
||||||
|
position: absolute;
|
||||||
|
bottom: 0;
|
||||||
|
left: 0;
|
||||||
|
z-index:100;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
<div class="Shot" show="cover">
|
||||||
|
<div class="Book">
|
||||||
|
<img style="display:block; height:100%; width:auto; visibility: visible;" src="book-panel-spine.jpg"/>
|
||||||
|
<div class="Page Page--Fill"> <div class="Front Shadow--Radiosity "><img src="book-panel-spine.jpg"/></div> <div class="Back Shadow--Radiosity"><img src="book-panel-spine.jpg"/></div> </div>
|
||||||
|
<div class="Spine">
|
||||||
|
<div class="Page" swing="closed"> <div class="Front Shadow--Radiosity "><img src="book-panel-front.jpg"/></div> <div class="Back Shadow--Radiosity"><img src="book-panel-front.jpg"/></div> </div>
|
||||||
|
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-0.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-0.jpg"/></div> </div>
|
||||||
|
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-0.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-0.jpg"/></div> </div>
|
||||||
|
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-0.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-0.jpg"/></div> </div>
|
||||||
|
|
||||||
.Shadow--Radiosity::after
|
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-1.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-0.jpg"/></div> </div>
|
||||||
{
|
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-3.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-2.jpg"/></div> </div>
|
||||||
content: " ";
|
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-5.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-4.jpg"/></div> </div>
|
||||||
background-size: 100% 100%;
|
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-0.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-6.jpg"/></div> </div>
|
||||||
background-position: 0px 0px;
|
|
||||||
background-image: radial-gradient(188% 24% at 50% 82%, #ffffff52 0%, #0000 100%);
|
|
||||||
display: block;
|
|
||||||
position: absolute;
|
|
||||||
bottom: 0;
|
|
||||||
left: 0;
|
|
||||||
z-index:100;
|
|
||||||
width: 100%;
|
|
||||||
height: 100%;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
||||||
<div class="Shot" show="cover">
|
|
||||||
<div class="Book">
|
|
||||||
<img style="display:block; height:100%; width:auto; visibility: hidden;" src="book-panel-spine.jpg"/>
|
|
||||||
<div class="Page Page--Fill"> <div class="Front Shadow--Radiosity "><img src="book-panel-spine.jpg"/></div> <div class="Back Shadow--Radiosity"><img src="book-panel-spine.jpg"/></div> </div>
|
|
||||||
<div class="Spine">
|
|
||||||
<div class="Page" swing="closed"> <div class="Front Shadow--Radiosity "><img src="book-panel-front.jpg"/></div> <div class="Back Shadow--Radiosity"><img src="book-panel-front.jpg"/></div> </div>
|
|
||||||
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-1.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-2.jpg"/></div> </div>
|
|
||||||
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-1.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-2.jpg"/></div> </div>
|
|
||||||
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-1.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-2.jpg"/></div> </div>
|
|
||||||
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-1.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-2.jpg"/></div> </div>
|
|
||||||
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-3.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-4.jpg"/></div> </div>
|
|
||||||
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-1.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-2.jpg"/></div> </div>
|
|
||||||
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-1.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-2.jpg"/></div> </div>
|
|
||||||
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-1.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-2.jpg"/></div> </div>
|
|
||||||
<div class="Page" swing="closed"> <div class="Front Shadow--Radiosity"><img src="book-panel-back.jpg"/></div> <div class="Back Shadow--Radiosity"><img src="book-panel-back.jpg"/></div> </div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-0.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-0.jpg"/></div> </div>
|
||||||
|
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-0.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-0.jpg"/></div> </div>
|
||||||
|
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-0.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-0.jpg"/></div> </div>
|
||||||
|
<div class="Page Page--Shrink" swing="closed"> <div class="Front Shadow--Sheet Shadow--Drop"><img src="book-page-0.jpg"/></div> <div class="Back Shadow--Sheet Shadow--Sheet--Flip"><img src="book-page-0.jpg"/></div> </div>
|
||||||
|
<div class="Page" swing="closed"> <div class="Front Shadow--Radiosity"><img src="book-panel-back.jpg"/></div> <div class="Back Shadow--Radiosity"><img src="book-panel-back.jpg"/></div> </div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<button onclick="bookPose('cover'); bookClose();">Front</button>
|
<button onclick="bookPose('cover'); bookClose();">Front</button>
|
||||||
<button onclick="bookPose('spine'); bookClose();">Spine</button>
|
<button onclick="bookPose('spine'); bookClose();">Spine</button>
|
||||||
<button onclick="bookPose('back'); bookClose();">Back</button>
|
<button onclick="bookPose('back'); bookClose();">Back</button>
|
||||||
<button onclick="bookPose('pages'); bookOpen(3);">Intro</button>
|
<button onclick="bookPose('pages'); bookOpen(4);">Intro</button>
|
||||||
<button onclick="bookPose('pages'); bookOpen(4);">Spread 1</button>
|
<button onclick="bookPose('pages'); bookOpen(5);">Days 1 & 2</button>
|
||||||
<button onclick="bookPose('pages'); bookOpen(5);">Spread 2</button>
|
<button onclick="bookPose('pages'); bookOpen(6);">Days 3 & 4</button>
|
||||||
<button onclick="bookPose('pages'); bookOpen(6);">3</button>
|
</div>
|
||||||
<button onclick="bookPose('pages'); bookOpen(7);">4</button>
|
|
||||||
</div>
|
|
||||||
</main>
|
|
||||||
<script>
|
<script>
|
||||||
let $ = query => Array.from(document.querySelectorAll(query));
|
let $ = query => Array.from(document.querySelectorAll(query));
|
||||||
let pages = $("[swing]");
|
let pages = $("[swing]");
|
||||||
let table = $(".Shot")[0];
|
let table = $(".Shot")[0];
|
||||||
let bookOpen = index =>
|
let bookOpen = index =>
|
||||||
{
|
{
|
||||||
pages.forEach((p, i)=> p.setAttribute("swing", i>index ? "right" : "left") );
|
pages.forEach((p, i)=> p.setAttribute("swing", i>index ? "right" : "left") );
|
||||||
};
|
};
|
||||||
let bookClose = () =>
|
let bookClose = () =>
|
||||||
{
|
{
|
||||||
pages.forEach(p=>p.setAttribute("swing", "closed"));
|
pages.forEach(p=>p.setAttribute("swing", "closed"));
|
||||||
};
|
};
|
||||||
let bookPose = inPanel =>
|
let bookPose = inPanel =>
|
||||||
{
|
{
|
||||||
table.setAttribute("show", inPanel);
|
table.setAttribute("show", inPanel);
|
||||||
bookClose();
|
bookClose();
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
</main>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|