During the week June 24th a mass of Drupal folks will converge on Dublin, Ireland for Drupal Dev Days. This year, in addition to the three days of DrupalCamp that is happening (June 28-30), there is also a week of sprints leading up to the camp, and to the Drupal 8 code freeze deadline. This is it. If it's going to be in Drupal 8, it needs to happen before the end of June.
See You at Drupalcamp Austin
Blog postWe're pleased as punch to be sponsoring DrupalCamp Austin in Austin, Texas from June 21st through 23rd. This year's camp is packed, with one day of all-day workshops, several half-day workshops, three tracks of sessions over two days, and two keynotes.
We'd Like to Sponsor Your User Group
Blog postWe're happy to announce a new program to sponsor user groups around the world: Meetup Memberships. We're giving user groups FREE access to the entire Drupalize.Me library on days that you have meetups or camps planned. It's like having a Drupalize.Me instructor show up at your event, anywhere, anytime! Here's how it works:
Sass' nesting feature makes it easy to organize your CSS in a way that makes it clear which selectors are related and generally provides a cleaner, clearer stylesheet. In this lesson we'll look at nesting, how to use it, and talk about making sure you don't nest unnecessarily.
Sass has a neat way of managing comments, where you can choose to either compile the comments, or not, from your scss. We're going to take a quick look at the two comment styles, and see how they appear (or don't) in our finished, compiled CSS.
Now that we have Ruby and Sass ready to go and working, let's also get our handy dandy mixin library, Compass, installed as well. We'll be using the command line in this lesson, but it's super simple to get this installed, and then we'll create a project to make sure everything is firing correctly. We'll look at a GUI tool to do this in another lesson.
Additional resources
We've looked at how easy it is to set Sass and Compass up from the command line, but for folks who prefer a nice GUI application, there are a few options available. Scout is a free Sass/Compass application that works cross-platform. In this lesson, we'll get Scout set up and see how it works to watch our projects.
Notes on Installing Scout:
- On OSX, If you double-click the .dmg and you get an error message saying you can't open this because it's from an unrecognized developer, control-click on the .dmg and select "Open" from the menu, then select "Open" from the dialogue box to open the .dmg installer.
- After installing Scout, OSX may again prevent you from opening it (depending on your security preferences) when it auto-opens it after installation. Navigate to where you installed it (i.e. "Applications"), control-click on the Scout icon, select open from the menu, and select "Open" from the dialogue box once again.
- If you get an error about Java, "No Java runtime present, requesting install," see the Scout GitHub issue queue for a solution.
Additional resources
In this podcast episode, Building Lullabot.com, Addi is joined by the Lullabot team that worked on the new Lullabot.com redesign and upgrade. The conversation covers a lot of the lessons learned from doing an internal project on the side of regular client work.
In order to get started with Sass, we're going to need to install it. There is really only one major prerequisite for using Sass, and that's that you will need to have Ruby installed. Ruby is a very popular language, which Sass is written in. Ruby is easy to install, and once you have it installed, you won't need to really work with Ruby directly. Some systems come with Ruby already installed, like OS X, but if you don't have Ruby installed it only takes a few minutes. In this lesson we will be installing Sass and Ruby on Windows, because Windows does not have Ruby installed for us already. Once we have Ruby installed, we'll use the command line to quickly install Sass, which is the same on all systems. Then we'll do a quick test to make sure it is working properly. There are apps that you can use to do all of this for you using a GUI, but we want to start with the fundamental pieces, and we'll cover the GUI applications in another lesson.
Additional resources
In this lesson we're going to review a lot of the special terms that are used in Sass. Different categories of features you can use with Sass have their own names, and are used in specific ways in the Sass world. We're also going to take a look at scss versus sass, and get a feel for how Sass code looks before and after compilation.
Whenever people speak about Sass, they normally also mention Compass in the same breath. It isn't always clear what the difference between these tools are. Compass is a library that adds lots of new features to your standard Sass setup. In this lesson, we'll discuss why you want to use Compass, then take a look at the Compass documentation and the main features that it provides for you.
Additional resources
Learning Sass and Compass
CourseSass is in a class of tools called CSS preprocessors. CSS preprocessors have been around for a while now, but they've really started to gain in popularity in the last several years. In this lesson we'll find out what a CSS preprocessor is, what the benefits of using one are, and which ones are popular today.
Additional resources
In this lesson we're going to do a quick comparison between the two most popular CSS preprocessors in use today, Sass ad LESS. We'll look at the similarities between these two, as well as the main differences.
In this series, we're going to be covering CSS preprocessors. Mainly we're going to be covering Sass, along with a related library, called Compass. While not used only on Drupal sites, it's a good thing to have in your arsenal of skills, especially if you do front-end design work.
To wrap everything up, we're going to show you how to extend beyond what we've covered in just the Sass and Compass basics, with other libraries that you can use with Sass.
In this lesson we take a look at compass mixins. We concentrate on a single mixin in the Typography category to show how a compass mixin can save lots of time and make your sass file much cleaner. We will take a look at how to create a horizontal list with a single include that handles all the necessary floats, paddings, margins, and everything we normally write in CSS but is now just a mixin away.
NOTE: Support of Dreditor has been nominal for a while. It's still the preferred tool for enhancing Drupal's issue queue, but keeping track of what the "official" version is can be tricky. For now, we recommend https://dreditor.github.io/. There's also been work happening to incorporate many of Dreditor's features right into Drupal.org itself. See https://www.drupal.org/project/drupalorg/issues/1673278
Dreditor is a great community tool that assists with things like patch reviews, and generally interacting with the Drupal.org issue queue. Dreditor is not a Drupal module, but is a plugin script you use in your browser. In this lesson, Joe walks through how to get Dreditor installed (on Chrome and Firefox), and then shows you how to use it to make your work in the issue queues more efficient.
Additional resources
On the eve of DrupalCon Portland, we're happy to be able to get another free community video out, Installing and Using Dreditor. What's more exciting though, is that this video is part of our Community Tools workshop, and in an effort to spread Drupal community involvement further than where we can show up to run this free workshop, we're putting all of our materials and notes online for everyone to use freely, with the Community Tools curriculum.
A Workshop is Born
This Friday's podcast, The Mysterious Drupal Entity has Kyle, Joe, and Blake joined by Greg Dunlap to talk about Drupal entities. What are they? Why do we have them? What do they look like in Drupal 8? We look at it from both the developer and site builder sides to try and get a grip on a topic that leaves a lot of people scratching their heads.
Revisions are an important concept in a content management system. Keeping track of all the edits that have been made to a particular entity over the course of its lifetime. A paper trail or sorts. This lesson takes a look at what is required in order to make our Entities support revisions.
If you've worked with Drupal's node system and enabled revisions then you've seen Drupal's basic revision handling in action. Every time you save a node, it creates a new version of that node. You can roll back to previous versions and keep track of how a piece of content has changed over time. Entity API also supports the concept of revisions and in this lesson we're going to take a look at adding revision support for our video entities.
In order to take advantage of this feature, we'll need to modify our database schema to accommodate storing multiple versions of the same entity. We'll move all fields that we want to make "revisionable" into a separate table and set up a new unique version ID field so that we can keep track of revisions.
Then we will update our hook_entity_info
implementation to tell the API that we want to use the revision system and make some changes to the code in our VideoEntityController
so that when an entity is updated we save a revision instead of overwriting the current data.
Finally we'll need to write a simple UI for viewing older versions of our video entity because the Entity API does not provide us with this code by default.