Skip to content

Commit 3dfd350

Browse files
committed
fix: Style link-to helper in other states.
1 parent 7e199dd commit 3dfd350

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

packages/@css-blocks/ember/src/TemplateAnalyzingRewriter.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -158,8 +158,8 @@ export class TemplateAnalyzingRewriter implements ASTPluginWithDeps {
158158
node.hash.pairs = node.hash.pairs.filter(a => this.elementAnalyzer.isAttributeAnalyzed(a.key)[0] === null).filter(a => !attrToStateMap[a.key]);
159159

160160
for (let attr of Object.keys(attrMap)) {
161-
if (attr === "class") {
162-
let element = attrMap[attr];
161+
let element = attrMap[attr];
162+
if (element) {
163163
this.debug(element.forOptimizer(this.cssBlocksOpts)[0].toString());
164164
let attrValue = this.buildClassValue(true, element);
165165
let hash = this.syntax.builders.pair(attr, attrValue!);

private-packages/fixtures-ember-v2/ember-app/tests/integration/template-discovery-test.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ module("Acceptance | Template Discovery", function(hooks) {
3030
assert.ok(varIsPresent("#reset-stylesheet-selector", "reset-stylesheet-selector"), "Vanilla CSS styles in app.css are preserved");
3131
});
3232

33-
skip("Ember Builtins Integration", async function(assert) {
33+
test("Ember Builtins Integration", async function(assert) {
3434
await visit("/ember-builtins", "Navigated to test case");
3535
assert.equal(currentURL(), "/ember-builtins");
3636
assert.ok(varIsPresent("#link-to-helper", "link-to-helper"), "Link-to helpers receive classes");
@@ -87,7 +87,7 @@ module("Acceptance | Template Discovery", function(hooks) {
8787
assert.ok(varIsPresent("#addon-component-sub-class", "addon-component-block-class-state"), "Sub-class state applied when enabled");
8888
});
8989

90-
skip("Lazy Engine Block Integration", async function(assert) {
90+
test("Lazy Engine Block Integration", async function(assert) {
9191
await visit("/@css-blocks-fixtures-v2/ember-lazy-engine");
9292
assert.equal(currentURL(), "/@css-blocks-fixtures-v2/ember-lazy-engine", "Navigated to test case");
9393
assert.ok(varIsPresent("#scope", "in-repo-lazy-engine-scope"), "Scope style applied to root element");

0 commit comments

Comments
 (0)