Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletter Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds
Arrow up icon
GO TO TOP
Learning Ionic

You're reading from   Learning Ionic Discover a simpler approach to modern mobile application development with Ionic framework and learn how to create elegant hybrid apps with HTML5 and AngularJS

Arrow left icon
Product type Paperback
Published in Jul 2015
Publisher
ISBN-13 9781783552603
Length 388 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Author (1):
Arrow left icon
 Ravulavaru Ravulavaru
Author Profile Icon Ravulavaru
Ravulavaru
Arrow right icon
View More author details
Toc

Table of Contents (19) Chapters Close

Learning Ionic
Credits
Foreword
About the Author
Acknowledgments
About the Reviewers
www.PacktPub.com
Preface
1. Ionic – Powered by AngularJS FREE CHAPTER 2. Welcome to Ionic 3. Ionic CSS Components and Navigation 4. Ionic and SCSS 5. Ionic Directives and Services 6. Building a Bookstore App 7. Cordova and ngCordova 8. Building a Messaging App 9. Releasing the Ionic App Additional Topics and Tips Index

Building a swatch


In order to understand the preceding process a bit better, we will build a theme of our own, overriding variables and classes. We will scaffold a side menu app, and then change its default look and feel.

To scaffold a new side menu app run this:

ionic start -a "Example 15" -i app.example.fifteen example15 sidemenu

Next, using the cd command, go to the example15 folder and run this:

ionic setup sass

This will download and set up the SCSS dependencies for your project. Open ionic.app.scss. The idea here is not to change any markup or add new classes, but rather to modify the appropriate variables to reflect our new theme.

Note

This is not the only way in which you can theme your application. You can modify your markup, add appropriate classes that reflect your brand (for example, button-mybrand or bar-mybrand), and then create variables and classes appropriately in SCSS.

We will be theming the side menu app in shades of teal. The first thing we will do is modify the $stable variable...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime
Visually different images