merge from dev
This commit is contained in:
parent
1c8f02ce0f
commit
33b01d778c
911 changed files with 34157 additions and 57125 deletions
|
@ -50,14 +50,34 @@ Example:
|
|||
observer: 'queryChanged'
|
||||
},
|
||||
|
||||
/**
|
||||
* If true, the query attribute is assumed to be a complete media query
|
||||
* string rather than a single media feature.
|
||||
*/
|
||||
full: {
|
||||
type: Boolean,
|
||||
value: false
|
||||
},
|
||||
|
||||
/**
|
||||
* @type {function(MediaQueryList)}
|
||||
*/
|
||||
_boundMQHandler: {
|
||||
value: function() {
|
||||
return this.queryHandler.bind(this);
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* @type {MediaQueryList}
|
||||
*/
|
||||
_mq: {
|
||||
value: null
|
||||
}
|
||||
},
|
||||
|
||||
attached: function() {
|
||||
this.style.display = 'none';
|
||||
this.queryChanged();
|
||||
},
|
||||
|
||||
|
@ -84,7 +104,7 @@ Example:
|
|||
if (!query) {
|
||||
return;
|
||||
}
|
||||
if (query[0] !== '(') {
|
||||
if (!this.full && query[0] !== '(') {
|
||||
query = '(' + query + ')';
|
||||
}
|
||||
this._mq = window.matchMedia(query);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue