render ssa/ass subs in browser
This commit is contained in:
parent
3c2d0cd3a1
commit
cc2c794ad0
26 changed files with 10493 additions and 138 deletions
|
@ -15,13 +15,23 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|||
<dom-module id="test-overlay">
|
||||
|
||||
<style>
|
||||
|
||||
:host {
|
||||
background: white;
|
||||
color: black;
|
||||
border: 1px solid black;
|
||||
}
|
||||
|
||||
:host([animated]) {
|
||||
-webkit-transition: -webkit-transform 0.3s;
|
||||
transition: transform 0.3s;
|
||||
-webkit-transform: translateY(300px);
|
||||
transform: translateY(300px);
|
||||
}
|
||||
|
||||
:host(.opened[animated]) {
|
||||
-webkit-transform: translateY(0px);
|
||||
transform: translateY(0px);
|
||||
}
|
||||
</style>
|
||||
|
||||
<template>
|
||||
|
@ -31,19 +41,62 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|||
</dom-module>
|
||||
|
||||
<script>
|
||||
(function() {
|
||||
|
||||
(function() {
|
||||
Polymer({
|
||||
|
||||
Polymer({
|
||||
is: 'test-overlay',
|
||||
|
||||
is: 'test-overlay',
|
||||
properties: {
|
||||
animated: {
|
||||
type: Boolean,
|
||||
reflectToAttribute: true
|
||||
}
|
||||
},
|
||||
|
||||
behaviors: [
|
||||
Polymer.IronOverlayBehavior
|
||||
]
|
||||
behaviors: [
|
||||
Polymer.IronOverlayBehavior
|
||||
],
|
||||
|
||||
});
|
||||
listeners: {
|
||||
'transitionend': '__onTransitionEnd'
|
||||
},
|
||||
|
||||
})();
|
||||
_renderOpened: function() {
|
||||
if (this.animated) {
|
||||
if (this.withBackdrop) {
|
||||
this.backdropElement.open();
|
||||
}
|
||||
this.classList.add('opened');
|
||||
this.fire('simple-overlay-open-animation-start');
|
||||
} else {
|
||||
Polymer.IronOverlayBehaviorImpl._renderOpened.apply(this, arguments);
|
||||
}
|
||||
},
|
||||
|
||||
_renderClosed: function() {
|
||||
if (this.animated) {
|
||||
if (this.withBackdrop) {
|
||||
this.backdropElement.close();
|
||||
}
|
||||
this.classList.remove('opened');
|
||||
this.fire('simple-overlay-close-animation-start');
|
||||
} else {
|
||||
Polymer.IronOverlayBehaviorImpl._renderClosed.apply(this, arguments);
|
||||
}
|
||||
},
|
||||
|
||||
__onTransitionEnd: function(e) {
|
||||
if (e && e.target === this) {
|
||||
if (this.opened) {
|
||||
this._finishRenderOpened();
|
||||
} else {
|
||||
this._finishRenderClosed();
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
});
|
||||
|
||||
})();
|
||||
</script>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue