File: /var/www/quadcode/frontend/src/html/about/mindfulness.html
<div class="mindfulness">
<div class="container">
<div class="mindfulness__inner">
<div class="mindfulness__block-img">
<div class="mindfulness__animation" id="animation_container">
<canvas class="mindfulness__canvas" id="canvas" width="580" height="580"></canvas>
<div class="mindfulness__overlay" id="dom_overlay_container">
</div>
</div>
</div>
<div class="mindfulness__block-text">
<div class="mindfulness__title titleL">Quadcode mindfulness</div>
<div class="mindfulness__title defaultBase">
<p>We like things to be fair. A high-tech business should not only care about its profits but also give back to the community and the environment.</p>
<p><br></p>
<p>We always pursued inclusiveness by creating jobs, delivering useful products, and financially empowering and educating people of all backgrounds. As an international company with a global presence, we have committed to social accountability before our shareholders and public through sustainability and community welfare.</p>
</div>
<div class="mindfulness__link">
<a href="sustainability" class="btn-link">
<span class="btn-link__text CTABase">Sustainability policy</span>
<span class="btn-link__svg">
<svg width="12" height="8" viewBox="0 0 12 8" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M1 3.5C0.723858 3.5 0.5 3.72386 0.5 4C0.5 4.27614 0.723858 4.5 1 4.5V3.5ZM11.3536 4.35355C11.5488 4.15829 11.5488 3.84171 11.3536 3.64645L8.17157 0.464466C7.97631 0.269204 7.65973 0.269204 7.46447 0.464466C7.2692 0.659728 7.2692 0.976311 7.46447 1.17157L10.2929 4L7.46447 6.82843C7.2692 7.02369 7.2692 7.34027 7.46447 7.53553C7.65973 7.7308 7.97631 7.7308 8.17157 7.53553L11.3536 4.35355ZM1 4.5H11V3.5H1V4.5Z" fill="white"/>
</svg>
</span>
</a>
</div>
</div>
</div>
</div>
</div>
<!-- TODO: оптимизировать -->
<script>
(function (cjs, an) {
var p; // shortcut to reference prototypes
var lib={};var ss={};var img={};
lib.ssMetadata = [];
(lib.AnMovieClip = function(){
this.actionFrames = [];
this.ignorePause = false;
this.gotoAndPlay = function(positionOrLabel){
cjs.MovieClip.prototype.gotoAndPlay.call(this,positionOrLabel);
}
this.play = function(){
cjs.MovieClip.prototype.play.call(this);
}
this.gotoAndStop = function(positionOrLabel){
cjs.MovieClip.prototype.gotoAndStop.call(this,positionOrLabel);
}
this.stop = function(){
cjs.MovieClip.prototype.stop.call(this);
}
}).prototype = p = new cjs.MovieClip();
// symbols:
(lib.Tween58 = function(mode,startPosition,loop,reversed) {
if (loop == null) { loop = true; }
if (reversed == null) { reversed = false; }
var props = new Object();
props.mode = mode;
props.startPosition = startPosition;
props.labels = {};
props.loop = loop;
props.reversed = reversed;
cjs.MovieClip.apply(this,[props]);
// Layer_1
this.shape = new cjs.Shape();
this.shape.graphics.rf(["rgba(186,255,134,0.4)","rgba(255,255,255,0)"],[0,1],0,0,0,0,0,95.9).s().p("AqgKgQkWkXgBmJQABmJEWkXQEWkWGKgBQGJABEXEWQEYEXgBGJQABGJkYEXQkXEYmJgBQmKABkWkYg");
this.timeline.addTween(cjs.Tween.get(this.shape).wait(1));
this._renderFirstFrame();
}).prototype = p = new cjs.MovieClip();
p.nominalBounds = new cjs.Rectangle(-95.1,-95.1,190.3,190.3);
(lib.Tween57 = function(mode,startPosition,loop,reversed) {
if (loop == null) { loop = true; }
if (reversed == null) { reversed = false; }
var props = new Object();
props.mode = mode;
props.startPosition = startPosition;
props.labels = {};
props.loop = loop;
props.reversed = reversed;
cjs.MovieClip.apply(this,[props]);
// Layer_1
this.shape = new cjs.Shape();
this.shape.graphics.rf(["rgba(186,255,134,0.4)","rgba(255,255,255,0)"],[0,1],0,0,0,0,0,95.9).s().p("AqgKgQkWkXgBmJQABmJEWkXQEWkWGKgBQGJABEXEWQEYEXgBGJQABGJkYEXQkXEYmJgBQmKABkWkYg");
this.timeline.addTween(cjs.Tween.get(this.shape).wait(1));
this._renderFirstFrame();
}).prototype = p = new cjs.MovieClip();
p.nominalBounds = new cjs.Rectangle(-95.1,-95.1,190.3,190.3);
(lib.Tween55 = function(mode,startPosition,loop,reversed) {
if (loop == null) { loop = true; }
if (reversed == null) { reversed = false; }
var props = new Object();
props.mode = mode;
props.startPosition = startPosition;
props.labels = {};
props.loop = loop;
props.reversed = reversed;
cjs.MovieClip.apply(this,[props]);
// Layer_1
this.shape = new cjs.Shape();
this.shape.graphics.f("#77FF8E").s().p("AIHKUQgMgEgJgJQgJgJgEgMQgwilg/hgQh4i5ilAuQgxANhGA7QhWBHglAUQhPAqhbgLQhxgNiUheQA7gHAygjQAjgZAug1QA9hHARgQQAxgvA0gXQCahBCBA4QBEAeAwA4QAPARAWAhQAVAcAaAQQDoCNBSD3QAKAdgWAWQgPAQgUAAQgIAAgIgCgAC5AuQghgugVhHQgpiQBBiCQAVgrBth8QBZhlgCgwQBoClgMB+QgJBbhQBgIhCBLQgmArgTAeQgzBTAnBZg");
this.shape.setTransform(0.0337,0.0184);
this.timeline.addTween(cjs.Tween.get(this.shape).wait(1));
this._renderFirstFrame();
}).prototype = p = new cjs.MovieClip();
p.nominalBounds = new cjs.Rectangle(-58.4,-66.2,116.9,132.5);
(lib.Tween54 = function(mode,startPosition,loop,reversed) {
if (loop == null) { loop = true; }
if (reversed == null) { reversed = false; }
var props = new Object();
props.mode = mode;
props.startPosition = startPosition;
props.labels = {};
props.loop = loop;
props.reversed = reversed;
cjs.MovieClip.apply(this,[props]);
// Layer_1
this.shape = new cjs.Shape();
this.shape.graphics.rf(["rgba(255,255,255,0)","rgba(250,252,249,0.102)","rgba(234,241,228,0.392)","rgba(209,224,196,0.855)","#CDE0BE"],[0,0.192,0.502,0.894,1],0,0,0,0,0,132.7).s().p("AhvUaQhGgag1g2IviviIgCgDQgpgpgYg1QgWgygFg5QgHhHAYhEQAYhHA1g0IPcvdQBphpCUAAQCUAABpBpIOyOyQA+A9AcBSQAcBPgGBTQgFA/gMAnQgRA2glApQgOAQvSPZQgwAwg9AaQg7AahAADIgSAAQg+AAg8gXg");
this.shape.setTransform(0.0408,0.0208);
this.timeline.addTween(cjs.Tween.get(this.shape).wait(1));
this._renderFirstFrame();
}).prototype = p = new cjs.MovieClip();
p.nominalBounds = new cjs.Rectangle(-132.4,-132.9,264.9,265.9);
(lib.Tween53 = function(mode,startPosition,loop,reversed) {
if (loop == null) { loop = true; }
if (reversed == null) { reversed = false; }
var props = new Object();
props.mode = mode;
props.startPosition = startPosition;
props.labels = {};
props.loop = loop;
props.reversed = reversed;
cjs.MovieClip.apply(this,[props]);
// Layer_1
this.shape = new cjs.Shape();
this.shape.graphics.rf(["rgba(255,255,255,0)","rgba(167,232,117,0.298)"],[0,1],0,0,0,0,0,132.7).s().p("AhvUaQhGgag1g2IviviIgCgDQgpgpgYg1QgWgygFg5QgHhHAYhEQAYhHA1g0IPcvdQBphpCUAAQCUAABpBpIOyOyQA+A9AcBSQAcBPgGBTQgFA/gMAnQgRA2glApQgOAQvSPZQgwAwg9AaQg7AahAADIgSAAQg+AAg8gXg");
this.shape.setTransform(0.0408,0.0208);
this.timeline.addTween(cjs.Tween.get(this.shape).wait(1));
this._renderFirstFrame();
}).prototype = p = new cjs.MovieClip();
p.nominalBounds = new cjs.Rectangle(-132.4,-132.9,264.9,265.9);
(lib.leaf_mc = function(mode,startPosition,loop,reversed) {
if (loop == null) { loop = true; }
if (reversed == null) { reversed = false; }
var props = new Object();
props.mode = mode;
props.startPosition = startPosition;
props.labels = {};
props.loop = loop;
props.reversed = reversed;
cjs.MovieClip.apply(this,[props]);
// Layer_1
this.instance = new lib.Tween55("synched",0);
this.instance.setTransform(-19.8,-40.6);
this.instance.alpha = 0.8008;
this.timeline.addTween(cjs.Tween.get(this.instance).to({alpha:1},14).to({alpha:0.8008},15).to({alpha:1},15).to({alpha:0.8008},15).to({alpha:1},15).to({alpha:0.8008},15).to({alpha:1},15).to({alpha:0.8008},15).wait(1));
// Layer_3
this.instance_1 = new lib.Tween57("synched",0);
this.instance_1.setTransform(-5.2,-27.7);
this.instance_1.alpha = 0;
this.instance_2 = new lib.Tween58("synched",0);
this.instance_2.setTransform(-5.2,-27.7);
this.instance_2._off = true;
this.timeline.addTween(cjs.Tween.get(this.instance_1).to({_off:true,alpha:1},14).to({_off:false,alpha:0},15).to({_off:true,alpha:1},15).to({_off:false,alpha:0},15).to({_off:true,alpha:1},15).to({_off:false,alpha:0},15).to({_off:true,alpha:1},15).wait(16));
this.timeline.addTween(cjs.Tween.get(this.instance_2).to({_off:false},14).to({_off:true,alpha:0},15).to({_off:false,alpha:1},15).to({_off:true,alpha:0},15).to({_off:false,alpha:1},15).to({_off:true,alpha:0},15).to({_off:false,alpha:1},15).to({alpha:0},15).wait(1));
// Layer_2
this.shape = new cjs.Shape();
this.shape.graphics.f("#000000").s().p("AIHKUQgMgEgJgJQgJgJgEgMQgwilg/hgQh4i5ilAuQgxANhGA7QhWBHglAUQhPAqhbgLQhxgNiUheQA7gHAygjQAjgZAug1QA9hHARgQQAxgvA0gXQCahBCBA4QBEAeAwA4QAPARAWAhQAVAcAaAQQDoCNBSD3QAKAdgWAWQgPAQgUAAQgIAAgIgCgAC5AuQghgugVhHQgpiQBBiCQAVgrBth8QBZhlgCgwQBoClgMB+QgJBbhQBgIhCBLQgmArgTAeQgzBTAnBZg");
this.shape.setTransform(-19.7663,-40.5816);
this.timeline.addTween(cjs.Tween.get(this.shape).wait(120));
this._renderFirstFrame();
}).prototype = p = new cjs.MovieClip();
p.nominalBounds = new cjs.Rectangle(-100.3,-122.8,190.3,190.3);
// stage content:
(lib.QCG_Sustainability = function(mode,startPosition,loop,reversed) {
if (loop == null) { loop = true; }
if (reversed == null) { reversed = false; }
var props = new Object();
props.mode = mode;
props.startPosition = startPosition;
props.labels = {};
props.loop = loop;
props.reversed = reversed;
cjs.MovieClip.apply(this,[props]);
// Layer_1
this.shape = new cjs.Shape();
this.shape.graphics.f("#1D1D1C").s().p("ADoD2IndndQgxg5gYgeQAVARBCA4IHdHdQAxA5AYAeIhXhJg");
this.shape.setTransform(234.425,367.875);
this.shape_1 = new cjs.Shape();
this.shape_1.graphics.f("#1D1D1C").s().p("ADoD2InendQgxg5gXgeQAkAdAzAsIHdHdIBJBXIhXhJg");
this.shape_1.setTransform(207.25,367.875);
this.shape_2 = new cjs.Shape();
this.shape_2.graphics.f("#1D1D1C").s().p("Aj1DoIHdndIBXhJIhJBXIndHdQg5AxgeAYIBJhXg");
this.shape_2.setTransform(368.75,367.875);
this.shape_3 = new cjs.Shape();
this.shape_3.graphics.f("#1D1D1C").s().p("Aj1DoIHdneIBXhIIhJBXIndHdQgwAqgnAfQAdgkAsgzg");
this.shape_3.setTransform(345.9,380.35);
this.shape_4 = new cjs.Shape();
this.shape_4.graphics.f().s("#1D1D1C").ss(2).p("Aw2JpIgHgIQghghgEgyQgDgaAGgYQAJgjAagaIPVvTQAwgxBDAAQBFAAAwAxIOqOpQAfAeAOAoQAPApgEAsQgDAmgFASQgEAPgIAK");
this.shape_4.setTransform(289.6723,216.3025);
this.shape_5 = new cjs.Shape();
this.shape_5.graphics.f().s("#1D1D1C").ss(2).p("AAMSQQgmAAgkgPQglgPgbgcIvcvbQgrgtgFg/QgDggAIgfQAMgtAhghIPUvVQAegdAlgQQAlgPAoAAQBVAAA9A8IOqOqQAlAlARAwQARAwgEA1QgDArgHAXQgGAWgPARQgjAkuxO5Qg2A1hMAEg");
this.shape_5.setTransform(289.6713,261.775);
this.shape_6 = new cjs.Shape();
this.shape_6.graphics.f().s("#1D1D1C").ss(2).p("AECTAQgvAvg8AaQg7AahAADQhHADhDgaQhGgag1g1IvcvdQgogpgXg0QgXgzgFg3QgGhHAXhDQAYhGA1g1IPUvUQBohoCSAAQCUAABoBoIOqOqQA9A9AdBRQAbBOgGBTQgFA+gMAnQgRA1glApQgOAQvKPRg");
this.shape_6.setTransform(289.6655,261.8158);
this.shape_7 = new cjs.Shape();
this.shape_7.graphics.f("#1D1D1C").s().p("AggA2QhXgJhEgxQgagZgRgaQBDAuAqATQA6AaA/AAQBAAAA6gaQAqgTBDguQgiA4hDAbQg8AchDAAQgRAAgSgCg");
this.shape_7.setTransform(290.925,433.9264);
this.shape_8 = new cjs.Shape();
this.shape_8.graphics.f("#1D1D1C").s().p("Ah+CwQCLiJBEhNIAjgrQATgYAJgWQAQgsAHhAQANBGgSAtQgNAig0A8QgrAxg7A8IhqBrQgOAMgvAhQAbgkATgXg");
this.shape_8.setTransform(404.2104,312.45);
this.shape_9 = new cjs.Shape();
this.shape_9.graphics.f("#1D1D1C").s().p("ACHChIiWiTQg8g5gngpQgfghgQgVQgWghgHggQA0BEBXBXICWCSIAyAwQAVAaAVAfQgTgNglgdg");
this.shape_9.setTransform(184.45,328.25);
this.shape_10 = new cjs.Shape();
this.shape_10.graphics.f("#1D1D1C").s().p("ACZDpIjJjHQhdhagig1Qg5hYAHheQAXBkAsBIQAWAiAlAnQAVAXAsArIDKDGIA7BKIhKg7g");
this.shape_10.setTransform(180.8915,327.8);
this.shape_11 = new cjs.Shape();
this.shape_11.graphics.f("#1D1D1C").s().p("AhTCMQAFgKAFgFQAwgyATgWQAjgqAXgjQAZgwALhTQADApAAASQAAAjgLAZQgLAbgbAhQgkAvhEBIQgKAGgSAHIAHgQg");
this.shape_11.setTransform(412.175,311);
this.shape_12 = new cjs.Shape();
this.shape_12.graphics.f("#1D1D1C").s().p("AhTCMQAFgLAFgEQAugwAVgYQAjgqAXgkQAZgvALhTQADApAAASQAAAjgLAYQgLAcgbAhQgkAvhEBIQgKAGgSAHIAHgQg");
this.shape_12.setTransform(412.175,289.85);
this.shape_13 = new cjs.Shape();
this.shape_13.graphics.f("#1D1D1C").s().p("AgOAyQAPgXAHgWQAGgOAEglQADghAKgSQAMAZgFAeQgGA8gfArQgOAZgaAMQAFgYAUgYg");
this.shape_13.setTransform(417.8714,311.9);
this.shape_14 = new cjs.Shape();
this.shape_14.graphics.f("#1D1D1C").s().p("AimDaIBDhCICGiEQBOhNAvg+QAYgjARgvQAMgjANg3QAEAygMAuQgNAxgcAnQgZAigkAnIhDBDIjJDHIhKA8QAdgmAfgkg");
this.shape_14.setTransform(398.3145,312.425);
this.shape_15 = new cjs.Shape();
this.shape_15.graphics.f("#1D1D1C").s().p("Ag5APQghgFgTgRIAegCIAaAFQA1AHA2gMQAfgJAZACQgRASghAIQgOAEgsAEQgugBgNgCg");
this.shape_15.setTransform(292.2,400.2326);
this.shape_16 = new cjs.Shape();
this.shape_16.graphics.f("#1D1D1C").s().p("Ag5APQghgEgTgRIAegDQARAEAJABQA3AHA0gMQAfgJAZACQgRATghAHQgOADgsAFQgugBgNgCg");
this.shape_16.setTransform(292.2,411.4326);
this.shape_17 = new cjs.Shape();
this.shape_17.graphics.f("#1D1D1C").s().p("Ah4ADQgUgMgMgNQAcAGALABQBeAlBggaQAxgQAcgFQgaAdgtAKQgrAMgqAAQg7AAg7gXg");
this.shape_17.setTransform(291.15,404.1844);
this.shape_18 = new cjs.Shape();
this.shape_18.graphics.f("#1D1D1C").s().p("Ah4ADQgUgMgMgNIAnAIQBfAkBfgaQAxgQAcgFQgaAdgtAKQgrAMgqAAQg7AAg7gXg");
this.shape_18.setTransform(291.15,442.9344);
this.shape_19 = new cjs.Shape();
this.shape_19.graphics.f("#1D1D1C").s().p("AimDaIEIkMQAkgkAOgQQAzhJAch0QACAwgLAwQgSA2gjAyIg7A9Ig8A9IjGDJIhKA8IA8hKg");
this.shape_19.setTransform(398.2973,343.9);
this.shape_20 = new cjs.Shape();
this.shape_20.graphics.f().s("#1D1D1C").ss(2).p("A0hujIACI0QAKB0BRBTIACADIPaPZQA1A1BGAbQBDAZBHgDQBAgDA6gZQA9gbAvgvQDzj0D0j2QHpnrAIgLQA+hXAIhs");
this.shape_20.setTransform(289.6,357.8198);
this.shape_21 = new cjs.Shape();
this.shape_21.graphics.f().s("#1D1D1C").ss(2).p("AAAkZIAAIz");
this.shape_21.setTransform(420.95,292.825);
this.shape_22 = new cjs.Shape();
this.shape_22.graphics.f().s("#1D1D1C").ss(2).p("AECTAQgvAvg8AaQg7AahAADQhHADhDgaQhGgag1g1IvcvdQgogpgXg0QgXgzgFg3QgGhHAXhDQAYhGA1g1IPUvUQBohoCSAAQCUAABoBoIOqOqQA9A9AdBRQAbBOgGBTQgFA+gMAnQgRA1glApQgOAQvKPRg");
this.shape_22.setTransform(289.6655,261.8158);
this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.shape_22},{t:this.shape_21},{t:this.shape_20},{t:this.shape_19},{t:this.shape_18},{t:this.shape_17},{t:this.shape_16},{t:this.shape_15},{t:this.shape_14},{t:this.shape_13},{t:this.shape_12},{t:this.shape_11},{t:this.shape_10},{t:this.shape_9},{t:this.shape_8},{t:this.shape_7},{t:this.shape_6},{t:this.shape_5},{t:this.shape_4},{t:this.shape_3},{t:this.shape_2},{t:this.shape_1},{t:this.shape}]}).wait(120));
// Layer_1
this.instance = new lib.leaf_mc();
this.instance.setTransform(279.1,255.9,0.7301,0.7301,0,0,0,-19.8,-40.6);
this.timeline.addTween(cjs.Tween.get(this.instance).wait(120));
// Layer_1
this.shape_23 = new cjs.Shape();
this.shape_23.graphics.f("#FFFFFF").s().p("AlwagIvRvRQhzhygaikIgHr9IABAAQgGhsAkhkQAmhoBPhPIPXvXQCbibDbAAQDcAACcCbIOvOwQBiBiAhBfQAhBigEC7QAHKVgHAzIAAAFIgBAAQgNBZgnBQQgpBThCBCIuqOpQieCejfAAQjeAAieieg");
this.shape_23.setTransform(290.0535,286.0468,0.8867,0.8867);
this.timeline.addTween(cjs.Tween.get(this.shape_23).wait(120));
// Layer_1_copy
this.instance_1 = new lib.Tween53("synched",0);
this.instance_1.setTransform(289.65,318.1);
this.instance_1._off = true;
this.instance_2 = new lib.Tween54("synched",0);
this.instance_2.setTransform(289.75,318.3,2.1684,2.1684,0,0,0,0.1,0.1);
this.instance_2.alpha = 0;
this.timeline.addTween(cjs.Tween.get({}).to({state:[]}).to({state:[{t:this.instance_1}]},52).to({state:[{t:this.instance_2}]},52).wait(16));
this.timeline.addTween(cjs.Tween.get(this.instance_1).wait(52).to({_off:false},0).to({_off:true,regX:0.1,regY:0.1,scaleX:2.1684,scaleY:2.1684,x:289.75,y:318.3,alpha:0},52,cjs.Ease.quadOut).wait(16));
// Layer_1_copy
this.instance_3 = new lib.Tween53("synched",0);
this.instance_3.setTransform(289.65,318.1);
this.instance_3._off = true;
this.instance_4 = new lib.Tween54("synched",0);
this.instance_4.setTransform(289.75,318.3,2.1679,2.1679,0,0,0,0.1,0.1);
this.instance_4.alpha = 0;
this.timeline.addTween(cjs.Tween.get({}).to({state:[]}).to({state:[{t:this.instance_3}]},14).to({state:[{t:this.instance_4}]},58).wait(48));
this.timeline.addTween(cjs.Tween.get(this.instance_3).wait(14).to({_off:false},0).to({_off:true,regX:0.1,regY:0.1,scaleX:2.1679,scaleY:2.1679,x:289.75,y:318.3,alpha:0},58,cjs.Ease.quadOut).wait(48));
// Layer_1
this.instance_5 = new lib.Tween53("synched",0);
this.instance_5.setTransform(289.65,318.1);
this.instance_6 = new lib.Tween54("synched",0);
this.instance_6.setTransform(289.75,318.3,2.1684,2.1684,0,0,0,0.1,0.1);
this.instance_6.alpha = 0;
this.timeline.addTween(cjs.Tween.get({}).to({state:[{t:this.instance_5}]}).to({state:[{t:this.instance_6}]},52).wait(68));
this.timeline.addTween(cjs.Tween.get(this.instance_5).to({_off:true,regX:0.1,regY:0.1,scaleX:2.1684,scaleY:2.1684,x:289.75,y:318.3,alpha:0},52,cjs.Ease.quadOut).wait(68));
this._renderFirstFrame();
}).prototype = p = new lib.AnMovieClip();
p.nominalBounds = new cjs.Rectangle(292.4,319.9,284.80000000000007,286.80000000000007);
// library properties:
lib.properties = {
id: '30269613DE7C4AB78BA7175F37588D08',
width: 580,
height: 580,
fps: 30,
color: "#FFFFFF",
opacity: 1.00,
manifest: [],
preloads: []
};
// bootstrap callback support:
(lib.Stage = function(canvas) {
createjs.Stage.call(this, canvas);
}).prototype = p = new createjs.Stage();
p.setAutoPlay = function(autoPlay) {
this.tickEnabled = autoPlay;
}
p.play = function() { this.tickEnabled = true; this.getChildAt(0).gotoAndPlay(this.getTimelinePosition()) }
p.stop = function(ms) { if(ms) this.seek(ms); this.tickEnabled = false; }
p.seek = function(ms) { this.tickEnabled = true; this.getChildAt(0).gotoAndStop(lib.properties.fps * ms / 1000); }
p.getDuration = function() { return this.getChildAt(0).totalFrames / lib.properties.fps * 1000; }
p.getTimelinePosition = function() { return this.getChildAt(0).currentFrame / lib.properties.fps * 1000; }
an.bootcompsLoaded = an.bootcompsLoaded || [];
if(!an.bootstrapListeners) {
an.bootstrapListeners=[];
}
an.bootstrapCallback=function(fnCallback) {
an.bootstrapListeners.push(fnCallback);
if(an.bootcompsLoaded.length > 0) {
for(var i=0; i<an.bootcompsLoaded.length; ++i) {
fnCallback(an.bootcompsLoaded[i]);
}
}
};
an.compositions = an.compositions || {};
an.compositions['30269613DE7C4AB78BA7175F37588D08'] = {
getStage: function() { return exportRoot.stage; },
getLibrary: function() { return lib; },
getSpriteSheet: function() { return ss; },
getImages: function() { return img; }
};
an.compositionLoaded = function(id) {
an.bootcompsLoaded.push(id);
for(var j=0; j<an.bootstrapListeners.length; j++) {
an.bootstrapListeners[j](id);
}
}
an.getComposition = function(id) {
return an.compositions[id];
}
an.makeResponsive = function(isResp, respDim, isScale, scaleType, domContainers) {
var lastW, lastH, lastS=1;
window.addEventListener('resize', resizeCanvas);
resizeCanvas();
function resizeCanvas() {
var w = lib.properties.width, h = lib.properties.height;
var iw = window.innerWidth, ih=window.innerHeight;
var pRatio = window.devicePixelRatio || 1, xRatio=iw/w, yRatio=ih/h, sRatio=1;
if(isResp) {
if((respDim=='width'&&lastW==iw) || (respDim=='height'&&lastH==ih)) {
sRatio = lastS;
}
else if(!isScale) {
if(iw<w || ih<h)
sRatio = Math.min(xRatio, yRatio);
}
else if(scaleType==1) {
sRatio = Math.min(xRatio, yRatio);
}
else if(scaleType==2) {
sRatio = Math.max(xRatio, yRatio);
}
}
domContainers[0].width = w * pRatio * sRatio;
domContainers[0].height = h * pRatio * sRatio;
domContainers.forEach(function(container) {
container.style.width = w * sRatio + 'px';
container.style.height = h * sRatio + 'px';
});
stage.scaleX = pRatio*sRatio;
stage.scaleY = pRatio*sRatio;
lastW = iw; lastH = ih; lastS = sRatio;
stage.tickOnUpdate = false;
stage.update();
stage.tickOnUpdate = true;
}
}
an.handleSoundStreamOnTick = function(event) {
if(!event.paused){
var stageChild = stage.getChildAt(0);
if(!stageChild.paused || stageChild.ignorePause){
stageChild.syncStreamSounds();
}
}
}
an.handleFilterCache = function(event) {
if(!event.paused){
var target = event.target;
if(target){
if(target.filterCacheList){
for(var index = 0; index < target.filterCacheList.length ; index++){
var cacheInst = target.filterCacheList[index];
if((cacheInst.startFrame <= target.currentFrame) && (target.currentFrame <= cacheInst.endFrame)){
cacheInst.instance.cache(cacheInst.x, cacheInst.y, cacheInst.w, cacheInst.h);
}
}
}
}
}
}
})(createjs2 = createjs||{}, AdobeAn2 = AdobeAn||{});
var createjs, AdobeAn;
var canvas, stage, exportRoot, anim_container, dom_overlay_container, fnStartAnimation;
function last() {
canvas = document.querySelector(".mindfulness__canvas");
anim_container = document.querySelector(".mindfulness__animation");
dom_overlay_container = document.querySelector(".mindfulness__overlay");
var comp=AdobeAn2.getComposition("30269613DE7C4AB78BA7175F37588D08");
var lib=comp.getLibrary();
handleComplete2({},comp);
}
function handleComplete2(evt,comp) {
//This function is always called, irrespective of the content. You can use the variable "stage" after it is created in token create_stage.
var lib=comp.getLibrary();
var ss=comp.getSpriteSheet();
exportRoot = new lib.QCG_Sustainability();
stage = new lib.Stage(canvas);
//Registers the "tick" event listener.
fnStartAnimation = function() {
stage.addChild(exportRoot);
createjs.Ticker.framerate = lib.properties.fps;
createjs.Ticker.addEventListener("tick", stage);
}
//Code to support hidpi screens and responsive scaling.
AdobeAn2.makeResponsive(false,'both',false,1,[canvas,anim_container,dom_overlay_container]);
AdobeAn2.compositionLoaded(lib.properties.id);
fnStartAnimation();
}
</script>