2 lines
5.0 KiB
JavaScript
2 lines
5.0 KiB
JavaScript
!function(){function t(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function e(t,e){for(var n=0;n<e.length;n++){var c=e[n];c.enumerable=c.enumerable||!1,c.configurable=!0,"value"in c&&(c.writable=!0),Object.defineProperty(t,c.key,c)}}function n(t,n,c){return n&&e(t.prototype,n),c&&e(t,c),t}(window.webpackJsonp=window.webpackJsonp||[]).push([[8],{tpRh:function(e,c,o){"use strict";o.r(c),o.d(c,"EventsModule",function(){return D});var a,r=o("ofXK"),b=o("fXoL"),i=o("LRne"),u=o("JIr8"),s=o("qZ0a"),l=o("jn67"),f=o("tk/3"),h=o("vHPH"),v=l.a+"events.json",g=((a=function(){function e(n,c){t(this,e),this.http=n,this.logger=c,this.events=this.getEvents()}return n(e,[{key:"getEvents",value:function(){var t=this,e=this.http.get(v).pipe(Object(u.a)(function(e){return t.logger.error(new Error("".concat(v," request failed: ").concat(e.message))),Object(i.a)([])}),Object(s.a)());return e.connect(),e}}]),e}()).\u0275fac=function(t){return new(t||a)(b.Xb(f.a),b.Xb(h.a))},a.\u0275prov=b.Kb({token:a,factory:a.\u0275fac}),a);function p(t,e){1&t&&(b.Tb(0,"div"),b.Tb(1,"p"),b.Ac(2,"We don't have any upcoming speaking engagements at the moment."),b.Sb(),b.Tb(3,"p"),b.Ac(4,"Until something comes up, make sure you check our "),b.Tb(5,"a",4),b.Ac(6,"YouTube channel"),b.Sb(),b.Ac(7," and follow us on "),b.Tb(8,"a",5),b.Ac(9,"social media"),b.Sb(),b.Ac(10,"."),b.Sb(),b.Tb(11,"p"),b.Ac(12,"If you want us to be part of your event reach out on "),b.Tb(13,"a",6),b.Ac(14,"devrel@angular.io"),b.Sb(),b.Ac(15,"!"),b.Sb(),b.Sb())}function T(t,e){if(1&t&&(b.Tb(0,"tr"),b.Tb(1,"th"),b.Tb(2,"a",7),b.Ac(3),b.Sb(),b.Sb(),b.Tb(4,"td"),b.Ac(5),b.Sb(),b.Tb(6,"td"),b.Tb(7,"div"),b.Ac(8),b.Sb(),b.Sb(),b.Sb()),2&t){var n=e.$implicit,c=b.ec(2);b.Cb(2),b.kc("href",n.linkUrl,b.uc),b.kc("title",n.tooltip),b.Cb(1),b.Bc(n.name),b.Cb(2),b.Bc(n.location),b.Cb(3),b.Cc(" ",c.getEventDates(n)," ")}}function d(t,e){if(1&t&&(b.Tb(0,"table",2),b.Tb(1,"thead"),b.Tb(2,"tr"),b.Tb(3,"th"),b.Ac(4,"Event"),b.Sb(),b.Tb(5,"th"),b.Ac(6,"Location"),b.Sb(),b.Tb(7,"th"),b.Ac(8,"Date"),b.Sb(),b.Sb(),b.Sb(),b.Tb(9,"tbody"),b.zc(10,T,9,5,"tr",3),b.Sb(),b.Sb()),2&t){var n=b.ec();b.Cb(10),b.jc("ngForOf",n.upcomingEvents)}}function S(t,e){if(1&t&&(b.Tb(0,"tr"),b.Tb(1,"th"),b.Tb(2,"a",7),b.Ac(3),b.Sb(),b.Sb(),b.Tb(4,"td"),b.Ac(5),b.Sb(),b.Tb(6,"td"),b.Tb(7,"div"),b.Ac(8),b.Sb(),b.Sb(),b.Sb()),2&t){var n=e.$implicit,c=b.ec();b.Cb(2),b.kc("href",n.linkUrl,b.uc),b.kc("title",n.tooltip),b.Cb(1),b.Bc(n.name),b.Cb(2),b.Bc(n.location),b.Cb(3),b.Cc(" ",c.getEventDates(n)," ")}}var m,w=["January","February","March","April","May","June","July","August","September","October","November","December"],C=((m=function(){function e(n){t(this,e),this.eventsService=n}return n(e,[{key:"ngOnInit",value:function(){var t=this;this.eventsService.events.subscribe(function(e){t.pastEvents=e.filter(function(t){return new Date(t.date.end).getTime()<Date.now()-864e5}).sort(function(t,e){return y(t.date,e.date)?1:-1}),t.upcomingEvents=e.filter(function(t){return new Date(t.date.end).getTime()>=Date.now()-864e5}).sort(function(t,e){return y(t.date,e.date)?-1:1})})}},{key:"getEventDates",value:function(t){var e;if(t.workshopsDate){var n=A(t.date)+" (conference)",c=A(t.workshopsDate)+" (workshops)";e=y(t.workshopsDate,t.date)?"".concat(c,", ").concat(n):"".concat(n,", ").concat(c)}else e=A(t.date);return e="".concat(e,", ").concat(new Date(t.date.end).getUTCFullYear())}}]),e}()).\u0275fac=function(t){return new(t||m)(b.Ob(g))},m.\u0275cmp=b.Ib({type:m,selectors:[["aio-events"]],decls:18,vars:3,consts:[[4,"ngIf"],["class","is-full-width",4,"ngIf"],[1,"is-full-width"],[4,"ngFor","ngForOf"],["href","https://www.youtube.com/angular"],["href","https://twitter.com/angular"],["href","mailto:devrel@angular.io"],[3,"href","title"]],template:function(t,e){1&t&&(b.Tb(0,"h2"),b.Ac(1,"Where we'll be presenting:"),b.Sb(),b.zc(2,p,16,0,"div",0),b.zc(3,d,11,1,"table",1),b.Pb(4,"br"),b.Tb(5,"h2"),b.Ac(6,"Where we already presented:"),b.Sb(),b.Tb(7,"table",2),b.Tb(8,"thead"),b.Tb(9,"tr"),b.Tb(10,"th"),b.Ac(11,"Event"),b.Sb(),b.Tb(12,"th"),b.Ac(13,"Location"),b.Sb(),b.Tb(14,"th"),b.Ac(15,"Date"),b.Sb(),b.Sb(),b.Sb(),b.Tb(16,"tbody"),b.zc(17,S,9,5,"tr",3),b.Sb(),b.Sb()),2&t&&(b.Cb(2),b.jc("ngIf",!(null!=e.upcomingEvents&&e.upcomingEvents.length)),b.Cb(1),b.jc("ngIf",null==e.upcomingEvents?null:e.upcomingEvents.length),b.Cb(14),b.jc("ngForOf",e.pastEvents))},directives:[r.k,r.j],encapsulation:2}),m);function A(t){var e=new Date(t.start),n=new Date(t.end),c="".concat(w[e.getUTCMonth()]," ").concat(e.getUTCDate());return e.getUTCMonth()!==n.getUTCMonth()?c="".concat(c," - ").concat(w[n.getUTCMonth()]," ").concat(n.getUTCDate()):e.getUTCDate()!==n.getUTCDate()&&(c="".concat(c,"-").concat(n.getUTCDate())),c}function y(t,e){return t.start<e.start||t.start===e.start&&t.end<e.end}var k,D=((k=function e(){t(this,e),this.customElementComponent=C}).\u0275mod=b.Mb({type:k}),k.\u0275inj=b.Lb({factory:function(t){return new(t||k)},providers:[g],imports:[[r.c]]}),k)}}])}();
|
|
//# sourceMappingURL=events-events-module-es5.6447f4bc09fdcfbb5676.js.map
|