From 1f3b4eaeb637e149f36b72b7272db0b48a5dd5e0 Mon Sep 17 00:00:00 2001 From: Joongi Kim Date: Tue, 2 Jun 2015 12:34:22 +0900 Subject: [PATCH] Fix for IE. * Ensure rule.propertyInfo is correctly set in style-properties.html. It was checking a wrong attribute: rule.properties instead of rule.propertyInfo before calling decorateRule(). * Fix a condition check in custom-style.html when propertyInfo is null or undefined. --- src/lib/custom-style.html | 2 +- src/lib/style-properties.html | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/lib/custom-style.html b/src/lib/custom-style.html index 41424ecfd5..2322a931e7 100644 --- a/src/lib/custom-style.html +++ b/src/lib/custom-style.html @@ -107,7 +107,7 @@ rule.selector = 'body'; } var css = rule.cssText = rule.parsedCssText; - if (rule.propertyInfo.cssText) { + if (rule.propertyInfo && rule.propertyInfo.cssText) { // TODO(sorvell): factor better // remove property assignments so next function isn't confused css = css.replace(propertyUtils.rx.VAR_ASSIGN, ''); diff --git a/src/lib/style-properties.html b/src/lib/style-properties.html index 33d9f52e74..dd1e44d45a 100644 --- a/src/lib/style-properties.html +++ b/src/lib/style-properties.html @@ -165,7 +165,7 @@ applyProperties: function(rule, props) { var output = ''; // dynamically added sheets may not be decorated so ensure they are. - if (!rule.properties) { + if (!rule.propertyInfo) { this.decorateRule(rule); } if (rule.propertyInfo.cssText) { @@ -349,4 +349,4 @@ })(); - \ No newline at end of file +