mirror of
https://github.com/futurepress/epub.js.git
synced 2025-10-02 14:49:16 +02:00
added grunt js and updates css for sliding
This commit is contained in:
parent
8858c8f5dd
commit
d19d0f068c
8 changed files with 47 additions and 21 deletions
BIN
.DS_Store
vendored
BIN
.DS_Store
vendored
Binary file not shown.
32
css/main.css
32
css/main.css
|
@ -9,10 +9,11 @@ body {
|
|||
width: 100%;
|
||||
height: 100%;
|
||||
/* left: 40px; */
|
||||
-webkit-transform: translate(40px, 0);
|
||||
-moz-transform: translate(40px, 0);
|
||||
/* -webkit-transform: translate(40px, 0);
|
||||
-moz-transform: translate(40px, 0); */
|
||||
|
||||
border-radius: 5px 0px 0px 5px;
|
||||
/* border-radius: 5px 0px 0px 5px; */
|
||||
border-radius: 5px;
|
||||
background: #fff;
|
||||
overflow: hidden;
|
||||
-webkit-transition: -webkit-transform .5s;
|
||||
|
@ -23,6 +24,7 @@ body {
|
|||
box-shadow: inset 0 0 50px rgba(0,0,0,.1);
|
||||
}
|
||||
|
||||
|
||||
#titlebar {
|
||||
|
||||
height: 8%;
|
||||
|
@ -125,7 +127,12 @@ body {
|
|||
padding: 10px 0;
|
||||
}
|
||||
|
||||
#controls #open {
|
||||
#opener {
|
||||
padding: 10px 10px;
|
||||
float: left;
|
||||
}
|
||||
|
||||
#opener #open {
|
||||
width: 25px;
|
||||
}
|
||||
|
||||
|
@ -335,6 +342,8 @@ input:-moz-placeholder {
|
|||
#main {
|
||||
-webkit-transform: translate(0, 0);
|
||||
-moz-transform: translate(0, 0);
|
||||
-webkit-transition: -webkit-transform .3s;
|
||||
-moz-transition: -moz-transform .3s;
|
||||
}
|
||||
|
||||
#main.closed {
|
||||
|
@ -347,21 +356,6 @@ input:-moz-placeholder {
|
|||
margin: 0 50px 0 50px;
|
||||
}
|
||||
|
||||
#open {
|
||||
position: fixed;
|
||||
top: 10px;
|
||||
left: 0;
|
||||
z-index: 110;
|
||||
display: block;
|
||||
|
||||
-webkit-transition: -webkit-transform .5s;
|
||||
-moz-transition: -moz-transform .5s;
|
||||
}
|
||||
|
||||
#sidebar.open #open {
|
||||
-webkit-transform: translate(260px, 0);
|
||||
-moz-transform: translate(260px, 0);
|
||||
}
|
||||
|
||||
#toc {
|
||||
width: 260px;
|
||||
|
|
|
@ -6,7 +6,7 @@ FPR.app.init = (function($){
|
|||
"use strict";
|
||||
var Book,
|
||||
offline = false,
|
||||
sidebarWidth = 40,
|
||||
sidebarWidth = 0,
|
||||
windowWidth;
|
||||
|
||||
function init(bookURL){
|
||||
|
|
22
grunt.js
Normal file
22
grunt.js
Normal file
|
@ -0,0 +1,22 @@
|
|||
module.exports = function(grunt) {
|
||||
|
||||
// Project configuration.
|
||||
grunt.initConfig({
|
||||
pkg: '<json:package.json>',
|
||||
meta: {
|
||||
banner: '/*! <%= pkg.name %> - v<%= pkg.version %> - ' +
|
||||
'<%= grunt.template.today("yyyy-mm-dd") %> */'
|
||||
},
|
||||
min: {
|
||||
dist: {
|
||||
src: ['<banner>', 'fpjs/render/*.js'],
|
||||
dest: 'dist/built.min.js'
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
// Default task(s).
|
||||
grunt.registerTask('default', ['min']);
|
||||
|
||||
};
|
||||
|
|
@ -53,7 +53,7 @@
|
|||
<body>
|
||||
<div id="sidebar">
|
||||
<div id="controls">
|
||||
<a id="open"><img src="img/menu-icon.png"></a>
|
||||
|
||||
<input id="search" placeholder="search">
|
||||
<a id="network"><img id="store" src="img/save.png"></a>
|
||||
<a id="setting"><img id="settings" src="img/settings.png"></a>
|
||||
|
@ -66,6 +66,9 @@
|
|||
|
||||
</div>
|
||||
<div id="main">
|
||||
<div id="opener">
|
||||
<a id="open"><img src="img/menu-icon.png"></a>
|
||||
</div>
|
||||
<div id="titlebar">
|
||||
<span id="book-title"></span>
|
||||
<span id="title-seperator"> – </span>
|
||||
|
|
7
package.json
Normal file
7
package.json
Normal file
|
@ -0,0 +1,7 @@
|
|||
{
|
||||
"name": "FuturePress",
|
||||
"version": "0.1.0",
|
||||
"devDependencies": {
|
||||
"grunt": "0.3.17"
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue