mirror of
https://github.com/Polymer/polymer.git
synced 2025-02-25 18:55:30 -06:00
Change hidden to title for IE compat.
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
attr1: 'this is attr 1',
|
||||
attr2: 42,
|
||||
'aria-role': 'button',
|
||||
hidden: true,
|
||||
title: 'awesome',
|
||||
'attr-object': {foo: 'bar', nested: {'meaning': 42}, arr: [0, 'foo', true]},
|
||||
'attr-stupid': false
|
||||
},
|
||||
|
||||
@@ -220,14 +220,14 @@ suite('imperative attribute change (reflect)', function() {
|
||||
});
|
||||
|
||||
test('change non-`properties` property that natively reflects', function() {
|
||||
el.hidden = true;
|
||||
assert.strictEqual(el.hidden, true);
|
||||
el.hidden = false;
|
||||
assert.strictEqual(el.hidden, false);
|
||||
el.setAttribute('hidden', '');
|
||||
assert.strictEqual(el.hidden, true);
|
||||
el.removeAttribute('hidden');
|
||||
assert.strictEqual(el.hidden, false);
|
||||
el.title = 'awesome';
|
||||
assert.strictEqual(el.title, 'awesome');
|
||||
el.title = '';
|
||||
assert.strictEqual(el.title, '');
|
||||
el.setAttribute('title', 'super');
|
||||
assert.strictEqual(el.title, 'super');
|
||||
el.removeAttribute('title');
|
||||
assert.strictEqual(el.title, '');
|
||||
});
|
||||
|
||||
});
|
||||
@@ -238,8 +238,8 @@ suite('hostAttributes', function() {
|
||||
assert.strictEqual(basicDefault.getAttribute('attr1'), 'this is attr 1');
|
||||
assert.strictEqual(basicDefault.getAttribute('attr2'), '42');
|
||||
assert.strictEqual(basicDefault.getAttribute('aria-role'), 'button');
|
||||
assert.strictEqual(basicDefault.getAttribute('hidden'), '');
|
||||
assert.strictEqual(basicDefault.hidden, true);
|
||||
assert.strictEqual(basicDefault.getAttribute('title'), 'awesome');
|
||||
assert.strictEqual(basicDefault.title, 'awesome');
|
||||
assert.equal(basicDefault.getAttribute('attr-object'),
|
||||
JSON.stringify(configuredObject));
|
||||
assert.equal(basicDefault.hasAttribute('attr-stupid'), false);
|
||||
|
||||
Reference in New Issue
Block a user