fix: Revert itemscope defined as boolean attribute

pull/8414/head
aMediocreDad 4 years ago
parent aa4d0fc264
commit d63bab922e
No known key found for this signature in database
GPG Key ID: 253246939B19E311

@ -364,7 +364,6 @@ const attribute_lookup: { [key in BooleanAttributes]: AttributeMetadata } & { [k
indeterminate: { applies_to: ['input'] },
inert: {},
ismap: { property_name: 'isMap', applies_to: ['img'] },
itemscope: {},
loop: { applies_to: ['audio', 'bgsound', 'video'] },
multiple: { applies_to: ['input', 'select'] },
muted: { applies_to: ['audio', 'video'] },

@ -13,7 +13,6 @@ const _boolean_attributes = [
'hidden',
'inert',
'ismap',
'itemscope',
'loop',
'multiple',
'muted',

@ -1,11 +1,4 @@
// There is no relationship between the attribute name and the document node https://developer.mozilla.org/en-US/docs/Web/HTML/Microdata
export default {
props: {
itemscope: true
},
test({ assert, target, component }) {
const div = target.querySelector('div');
assert.ok(div.itemscope);
component.itemscope = false;
assert.ok(!div.itemscope);
}
html: '<div itemscope />'
};

@ -1,5 +1 @@
<script>
export let itemscope;
</script>
<div {itemscope} />
<div itemscope />

Loading…
Cancel
Save