designing ebooks with web standards

60
Designing Books with Web Standards Using HTML, CSS, and JavaScript to build more than web sites. Kristofer Layon // @klayon CSS Dev // December 5, 2012 Honolulu, HI Welcome to my presentation about designing books with Web Standards. There’s a lot to cover on the topic in a 45 minute session, so I’ll do my best to explain the pros and cons of the book format, go over some sample projects, and cover a broad range of options for designing books.

Upload: kristofer-layon

Post on 11-May-2015

1.787 views

Category:

Design


1 download

DESCRIPTION

An overview of examples, frameworks, and techniques for using web standards to design a range of reading experiences for a variety of platforms and devices.

TRANSCRIPT

Page 1: Designing Ebooks with Web Standards

Designing Books with Web Standards

Using HTML, CSS, and JavaScriptto build more than web sites.

Kristofer Layon // @klayonCSS Dev // December 5, 2012

Honolulu, HI

Welcome to my presentation about designing books with Web Standards. There’s a lot to cover on the topic in a 45 minute session, so I’ll do my best to explain the pros and cons of the book format, go over some sample projects, and cover a broad range of options for designing books.

Page 2: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

This is a demo of a project that I worked on last summer. For the past 3 years I’ve been curious about the intersection of native apps for smartphones and tablets, and the web and how it is built. Coupled with this interest has been a focus on books and what they mean. This is a demo of a handcrafted proof of concept that I built with PhoneGap and a jQuery Mobile pagination plugin by Filament Group.

Page 3: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

1. Why books?

2. A simple scrolling “ebooklet”.

3. A slightly less simple, book-like app (but with fancier stuff!)

4. An ebook in HPub format.

5. App stores: new opportunities, new pains

In this presentation I’ll provide a few demos of ebook as well as other book-like reading experiences, highlight some tools, frameworks, and CSS techniques for making books, and briefly highlight some steps to distribute books.

Page 4: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

1. Why ebooks?

2. A simple scrolling “ebooklet”.

3. A slightly less simple, book-like app (but with fancier stuff!)

4. An ebook in HPub format.

5. App stores: new opportunities, new pains

First: why books?

Page 5: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

•Web standards have never worked with perfect consistency across all browsers.

• Today more than ever, they don’t behave consistently across all devices, either.

• Except for advertising and pay walls, no good way to sell content in browsers.

• AOL, Flash, Facebook, and other frameworks and platforms as the “web”.

Isn’t “one web” a myth?

Page 6: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

• They’re web standards… but they’re more.

• Like notes, rhythm, and instruments used in multiple genres of music, code standards are used to build multiple genres of the web.

•Don’t limit your use of code standards to just the web; be a cross-over artist.

•Use customer and client needs to drive the best formats for web services and products.

Code Standards: HTML, CSS, JavaScript

Page 7: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

“But I love the web, soI can’t betray her!”

So you still might be thinking: I’m used to just designing for the web. I believe in the web being for all, and accessible from any device. Why would I venture beyond designing things for browsers?

Page 8: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

Luke W

There are two reasons. First, browsers are apps. They’re one kind of app, and there’s nothing wrong with designing for other apps. Second, if your product can be expressed better as an app, that’s the right solution for you. Even someone who is as much of a web evangelist as Luke Wroblewski knows when a native mobile app is the best approach, as he recently decided with his Polar polling app.

Page 9: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

A few days ago, Luke also noted that while publishing content everywhere might be a great solution for accessibility and ubiquity, it is not necessarily a good business model. Here again, an app might be a better business model.

Page 10: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

So… what are books?

So what are books, what makes them unique, and how does this inform whether a book format makes sense for a content type, user experience, and distribution method?

Page 11: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012www.wikipedia.org

Pages

First, like web sites, books have pages. But book pages are different. Book pages are traditionally a bit more defined than web pages.

Page 12: Designing Ebooks with Web Standards

www.sil.si.edu

Control

In fact, they’re often defined in such a way that they’re controlled more by a designer than a web page typically is. In this example, especially, we see an elaborate but precise use of space for illustration and text.

Page 13: Designing Ebooks with Web Standards

www.wikipedia.org

Work

Consequently, books are quite a bit of work. It takes effort to control the user experience of a book. And when books were new, they were all handcrafted one by one. This was an incredible amount of work, and was often done by monks.

Page 14: Designing Ebooks with Web Standards

Martin Luther (1483-1546)

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

In fact, the book was partly invented by a monk, Martin Luther. He and Gutenburg came up with the concepts of the book and the press that continue to define traditional book publishing today.

Page 15: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

Of course, as books production became more automated, monks in Europe and Asia weren’t needed to design and produce books anymore. Which is why monks had to find alternative ways to earn a living.

Page 16: Designing Ebooks with Web Standards

www.wikipedia.org

Monetary value

But one of the most important differentiators for the book format is value. Content inherently has value. This is why ads have worked on the web for years, and why Google exists as an enormous business. But if you want an ad-free user experience, it’s pretty challenging on the web. Paywalls are pretty unpopular, but Amazon, Apple, and publishers have proven that people will pay for digital media.

Page 17: Designing Ebooks with Web Standards

www.fanpop.com

Market

But you can’t just hang out a shingle with your name on it and sell whatever you want to turn a profit. It’s one thing to have a frictionless mechanism for sales and distribution, but as even the biggest app store in the world has proven, you need a market for your wares as well. The market can take a number of forms: individual consumers, B2B markets between companies, and so on.

Page 18: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

Books are a social construct,not just a technology.

And people like them.

So this is why books have had value and will continue to have value. Starting out 500 years ago as a very rare and limited medium that everyday people could not own, books have been transformed many times since then to become an affordable way to consume information. Yet they still retain value; the idea of a free book is not that attractive. It either means it’s a gift or it’s an outdated edition.

Page 19: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

www.amazon.com

You’ve probably all seen the stats. This summer Amazon announced that their ebook sales now exceed their print sales by 14%, but they’re not just calling it a shift. They’re calling it a reading renaissance.

Page 20: Designing Ebooks with Web Standards

When you see numbers from September such as ebook sales being up 188 percent, after devices like the Kindle and other tablets have been out for a few years already, it’s likely that we’re still in the beginning of this trend. So as web standards designers and developers, we can still be early adopters in this space by digging in and experimenting today.

Page 21: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

www.apple.com

My prediction is that with the smaller and more affordable iPad mini providing an even stronger consumer focus on the small tablet space, this will fuel an ebook and tablet app market that is even stronger than today. Especially as school districts and parents see these devices as being solutions for education, it’s an enormous opportunity for designers and developers to participate.

Page 22: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

So if you’re still not convinced, just take a look at these forms of books from the far and recent past. Books have never meant one, static design that is unchanged. The common thread is a familiar reading user experience for cultures of that time. But as culture and technologies change, the reading user experience changes with it. But the things we read are still called books, no matter their size or shape.

Page 23: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

Even in the gray area of apps, it’s clear that many of them are quasibooks because they’re designed primarily as reading experiences. Take a sample of some common apps and look at how many are designed for either brief or sustained reading users experiences. So do we put our ebooks on the web, in book stores or reading apps, or in app stores? The answer is yes. We’re still in the Wild West.

Page 24: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

Future CSS 5 holographic hover!

But more importantly, there’s still plenty of room for design innovation. We’re not yet done designing reading experiences and integrating them with other things. At Capella Education Company where I work, we’ve been integrating ebooks and mobile solutions into our curriculum models for years. Now we’re working on integrating our courseroom discussion experience into ebooks and reading devices.

Page 25: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

• Are cherished and people own them (buy) or borrow them (library).

•Good books are often read more than once.

• The form of the book has continued to alter for centuries since the day it was invented.

• As people who design and build content, we can help influence the book’s evolution.

Books…

In summary, books continue to be cherished and the market for them seems to be growing, not shrinking. Books have sustained value despite their formats changing. So let’s participate in this space. We don’t need to draw a boundary around our skills and only design sites that reside on servers and are viewed in browsers. App and book opportunities are enormous for those who use web standards.

Page 26: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

1. Why books?

2. A simple scrolling “ebooklet”.

3. A slightly less simple, book-like app (but with fancier stuff!)

4. An ebook in HPub format.

5. App stores: new opportunities, new pains

Next, let’s look at a really simple reading application. Three years ago as I was getting really excited about mobile design, my entry point was iOS. At that time Apple was far and away at the leading edge. They had the devices, the app store, and the extensive human interface guidelines that have pretty much defined a lot of what we still do today.

Page 27: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

I’ve been partnering with a medical author on a series of medical reference apps for iOS and Android. It’s been a great project: I have a shared code based to work from and just need to distribute to the app stores separately. We do 3-4 content updates per year, and an annual renewal in the summer.

Page 28: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

I was able to get into this via a web standards based iOS framework called Nimblekit. There are other options for this out there, too. Phonegap is one of the more familiar ones, as it was acquired by Adobe so it’s marketed pretty heavily whereas Nimblekit is out of the Ukraine and doesn’t get much attention.

Page 29: Designing Ebooks with Web Standards

<meta name = "viewport"content = "initial-scale = 1.0, user-scalable = no"

charset="UTF-8" >

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

The HTML and CSS required to use a framework like this are not that different from some of the techniques used in responsive web design. For example, setting the scale of the viewport to 1. And if you don’t want users to scale the entire page, setting user-scalable to NO.

Page 30: Designing Ebooks with Web Standards

@media only screen and (max-device-width)

@media only screen and (min-device-width)

@media only screen and (orientation : portrait)

@media only screen and (orientation : landscape)

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

After that, media queries can be used to customize your layouts per device if that’s your choice.

Page 31: Designing Ebooks with Web Standards

/* Rules for iPhone 3.5” landscape */

@media only screen and(min-device-width : 321px) and(orientation : landscape) { /* styles here */

}

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

The next few screens are what I use for iOS devices.

Page 32: Designing Ebooks with Web Standards

/* Rules for iPhone 4” landscape */

@media only screen and(min-device-width : 568px) and(orientation : landscape) { /* styles here */

}

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

Page 33: Designing Ebooks with Web Standards

/* Rules for iPad portrait */

@media only screen and(min-device-width : 768px) and(orientation : portrait) { /* styles here */

}

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

Page 34: Designing Ebooks with Web Standards

/* Rules for iPad landscape */

@media only screen and(min-device-width : 1024px) and(orientation : landscape) { /* styles here */

}

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

Page 35: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

1. Why ebooks?

2. A simple scrolling “ebooklet”.

3. A slightly less simple, book-like app (but with fancier stuff!)

4. An ebook in HPub format.

5. App stores: new opportunities, new pains

Page 36: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

Here’s another similar app that I designed with another medical client. This one has a slightly different navigation pattern that leverages the standard iOS tableview navigation.

Page 37: Designing Ebooks with Web Standards

#commentForm{ position: absolute; left: 50px; top: 10px; width: 200px; height: 60px; padding: 10px; background: #2b7c62; color: #fff; -webkit-box-shadow: 0 0 30px #000; -webkit-transition: -webkit-transform 400ms ease; -webkit-transform: translate3d(-480px, 0, 0);}

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

The app also makes use of some CSS3 transitions.

Page 38: Designing Ebooks with Web Standards

#commentForm label{ float: left; display: block; color: #fff; margin-bottom: 4px;}

#commentForm input{ font-size: 1em; width: 100%;}

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

Page 39: Designing Ebooks with Web Standards

#commentForm #commentSave{ float: right; font-size: 0.75em; width: 5em;}

#commentForm.show{ -webkit-transform: translate3d(0, 0, 0);}

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

Page 40: Designing Ebooks with Web Standards

.data tbody tr { background-color: #fff; -webkit-transition: background-color 1s ease;}

.data tbody tr:nth-child(odd) { background-color: #D5F2E9;}

.data tbody tr.current { background-color: #b8d1c9;}

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

In the data record area, CSS is used to provide alternate row background colors to improve readability.

Page 41: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

1. Why ebooks?

2. A simple scrolling “ebooklet”.

3. A slightly less simple, book-like app (but with fancier stuff!)

4. An ebook in HPub format.

5. App stores: new opportunities, new pains

Something that is newer to me is the HPub format that is used by the Baker Ebook Framework.

Page 42: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

The Baker Framework web site includes a nice demo ebook that highlights how this format works.

Page 43: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

The framework supports iPhone and iPad, though I had to do some extra work to make it a universal app for both devices (their standard demo is only for iPad).

Page 44: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

There’s a similar web standards ebook framework out there for Android called Friar.

Page 45: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

There are ways to do this without having to release your reading experiences to app stores. Treesaver is a platform that delivers reading experiences to browsers, and Savory is a hosting service for these publications. It’s another option that has some similarities to reading in ebook apps and devices, but the major shortcoming here remains business model (ad rev only; no way to sell content to customers).

Page 46: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

If you’re interested in doing a bit more handcrafting of a browser-based reading experience, another option to consider is this jQuery Mobile touch-based pagination plugin by Scott Jehl. This is what I used last to create the demo that I showed at the beginning of this session.

Page 47: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

Finally, if you want to fully participate in two of the main ebook marketplaces, consider learning more about Kindle…

Page 48: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

…and iBooks. Even iBooks author, though a proprietary solution that ties only to the iBooks platform, still generates books that are mostly built from web standards plus some proprietary tagging. Because the content creation side is so nice, we’re looking into how we might have our online course production teams use the tool, then strip the extra tagging with scripts to distribute content more broadly.

Page 49: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

1. Why ebooks?

2. A simple scrolling “ebooklet”.

3. A slightly less simple, book-like app (but with fancier stuff!)

4. An ebook in HPub format.

5. App stores: new opportunities, new pains

Page 50: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

iOS Developer overview

1. It costs $99 annually to participate.2. Install Xcode.3. Create app IDs.4. Define test devices.5. Create development and distribution certificates.6. Test app in iOS Simulator.7. Test app on devices.8. Get a separate bank account for payment.9. Release app to App Store!

As I wrap up, I wanted to run through the extra steps to release content to an app store. Here I’m using iTunes as the example, but Google Play and other app stores are very similar. These steps may be less familiar to you as a web designer or developer, but they aren’t that hard to master.

Page 51: Designing Ebooks with Web Standards

As the “reading renaissance” continues, more people are commenting about these opportunities. Just the other day, Jason Kottke of kottke.org wrote about a blog post on this topic by Craig Mod.

Page 52: Designing Ebooks with Web Standards

I highly encourage you to read Craig’s piece. It’s really well articulated and highlights some great examples of standards-based reading experiences. It’s also a lovingly designed piece; I wanted to screenshot the entire thing to show you.

Page 53: Designing Ebooks with Web Standards
Page 54: Designing Ebooks with Web Standards

One of the really nice reading products that he highlights is Marco Ament’s new Magazine for iOS. It’s a new experiment in small magazine publishing by Marco, someone who has dabbled in web-based reading experiences for a long time with his popular Instapaper app.

Page 55: Designing Ebooks with Web Standards

Craig outlines a helpful manifesto around the idea of “subcompact” or micro publishing. It’s a very interesting read that might help you get excited about the possibilities of using your CSS, HTML, and JavaScript skills in the new reading renaissance.

Page 56: Designing Ebooks with Web Standards

To conclude, I’ve been working my way through Karen McGrane’s new book “Content Strategy for Mobile” and there’s some great information in it about reading.

Page 57: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

“Readability’s data shows that users are even more engaged in reading on their mobile devices than on the desktop.”

Karen McGrane page 12

As Karen demonstrates in her great presentation about this topic, the best content strategy for the web is multi-channel. This means creating and structuring content properly way upstream, which allows you to consider a variety of market, platform, and device opportunities later. With reading experiences, apps, and platforms among these opportunities, consider the role of reading in mobile.

Page 58: Designing Ebooks with Web Standards

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

“People read on their phones… a lot.A device doesn’t need to be the sizeof a book for people to want toengage it.”

Rich Ziade, Readability page 12

And do not underestimate what people will do on a phone’s smaller screen. As Rich, the CEO of Readability points out, people actually read more on their smartphones than on desktop or even on tablets! It’s because then ten to have their phones with them more. And as Brad Frost noted yesterday, anything that people can do on a desktop or laptop, they will try to do on a smartphone.

Page 59: Designing Ebooks with Web Standards

If you are interested in tools and techniques for determining markets, customer needs, and how to measure product satisfaction with any book opportunities that you might encounter or dream up, I wrote an article about my other main area of focus, product management for the web, on A List Apart this past summer. I also have presentations about product management on Slideshare.

Page 60: Designing Ebooks with Web Standards

@klayon

kristoferlayon.com

[email protected]

Designing Ebooks with Web Standards | Kristofer Layon | @klayon | CSS Dev — Dec. 5, 2012

Thank you!

Thanks for attending today, and please be in touch with questions, suggestions, or ideas about using web standards to design ebooks and other reading experiences and products!