diff --git a/core/flyout_button.js b/core/flyout_button.js
index 93b1505a8..ca3d49ab6 100644
--- a/core/flyout_button.js
+++ b/core/flyout_button.js
@@ -95,7 +95,7 @@ Blockly.FlyoutButton = function(workspace, targetWorkspace, xml, isLabel) {
* @type {?string}
* @private
*/
- this.cssClass_ = xml.getAttribute('class') || null;
+ this.cssClass_ = xml.getAttribute('web-style') || null;
};
/**
diff --git a/tests/playground.html b/tests/playground.html
index 0167e89a1..66a3e2514 100644
--- a/tests/playground.html
+++ b/tests/playground.html
@@ -591,7 +591,7 @@ h1 {
-
+