提交 1a9063e3 编写于 作者: J Johan Preynat

Fix indentation

上级 a84f7db8
...@@ -11,7 +11,7 @@ var state = {}; ...@@ -11,7 +11,7 @@ var state = {};
themes after page is loaded and when navigation changed themes after page is loaded and when navigation changed
*/ */
function hasChanged(ctx) { function hasChanged(ctx) {
console.log('page has changed', ctx); console.log('page has changed', ctx); // eslint-disable-line no-console
setState(ctx); setState(ctx);
if (!started) { if (!started) {
...@@ -26,7 +26,7 @@ function hasChanged(ctx) { ...@@ -26,7 +26,7 @@ function hasChanged(ctx) {
/* /*
Update current state Update current state
data-level="{{ page.level }}" data-level="{{ page.level }}"
data-chapter-title="{{ page.title }}" data-chapter-title="{{ page.title }}"
data-filepath="{{ file.path }}" data-filepath="{{ file.path }}"
data-basepath="{{ './'|resolveFile }}" data-basepath="{{ './'|resolveFile }}"
...@@ -43,11 +43,11 @@ function setState(newState) { ...@@ -43,11 +43,11 @@ function setState(newState) {
state.book = newState.book; state.book = newState.book;
// Deprecated // Deprecated
state.$book = $('.book'); state.$book = $('.book');
state.revision = state.gitbook.time; state.revision = state.gitbook.time;
state.level = state.page.level; state.level = state.page.level;
state.filepath = state.file.path; state.filepath = state.file.path;
state.chapterTitle = state.page.title; state.chapterTitle = state.page.title;
state.innerLanguage = state.book.language || ''; state.innerLanguage = state.book.language || '';
// Absolute url to the root of the book (inner book) // Absolute url to the root of the book (inner book)
...@@ -70,6 +70,6 @@ function getState() { ...@@ -70,6 +70,6 @@ function getState() {
module.exports = { module.exports = {
hasChanged: hasChanged, hasChanged: hasChanged,
setState: setState, setState: setState,
getState: getState getState: getState
}; };
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册