Skip to content
Scott Cummings edited this page Oct 31, 2013 · 1 revision

##Book Config Property book Defines the specifics of the book.

###Properties

  • font [String] - the default font family of all text in the storybook.
  • startOnPage [Number] - automatically navigates the book to the specified page of storybook on load (mostly used for debug).
  • pageWidth [Number] - the width of all storybook pages in pixels.
  • pageHeight [Number] - the height of all storybook pages in pixels.
  • previousPageButton [Object] - the position, dimensions and filename of the button the navigates the storybook backwards.
  • nextPageButton [Object] - the position, dimensions and filename of the button the navigates the storybook forward.
  • pageBackground [Object] - the default background color and/or image of a page.
  • oddPageBackground [Object] - the default background color and/or image of an odd page (supersedes the pageBackground property).
  • evenPageBackground [Object] - the default background color and/or image of an even page (supersedes the pageBackground property).
  • margin [Number] - the margin around the book as a percentage of the viewport
  • pageTurnDuration [Number] - the time (in milliseconds) it takes to turn a page
  • pageSlideDuration [Number] - the time (in milliseconds) it takes to translate from the left page to the right page

###JSON Example book: { font: "Georgia", startOnPage: 20, pageWidth: 768, pageHeight: 1024, previousPageButton: { url: "images/prev-page-button.png", x: 1, y: 50, width: "50px", height: "50px" }, nextPageButton: { url: "images/next-page-button.png", horizontalAlign: "RIGHT", x: 1, y: 50, width: "50px", height: "50px" }, pageBackground: { color: "#fefefe" }, oddPageBackground: { color: "#fdfdfd" }, evenPageBackground: { color: "#f9f9f9" }, margin: 2, pageTurnDuration: 1000, pageSlideDuration: 200 }

Clone this wiki locally