2022-04-27 14:11:52 +02:00
import { S as Ae , i as ze , s as Be , e as m , k as S , t as C , c as g , a as k , d , m as T , h as F , b as _ , g as q , F as u , j as J , E as x , q as $ , w as ee , x as le , y as te , o as B , B as ie , n as R , p as W , G as se , J as Se , H as ce , l as ue } from "./index-b6ec56f3.js" ; import { A as Te , S as je , L as Le } from "./Avatar-16a27348.js" ; import { b as Oe , a as ae } from "./stores-5ebb319f.js" ; function Pe ( r , e ) { if ( ! e ) return 0 ; if ( r . duration ) return r . duration ; const i = e . spec . events . filter ( a => a . parent === r . id ) ; if ( i . length > 0 ) { let a = i . reduce ( ( l , n ) => l + ( n . duration ? n . duration : 0 ) , 0 ) ; return a += 5 * ( i . length - 1 ) , a } } function de ( r , e ) { e . update ( i => { const a = i . favoriteEvents ; let l = null ; return a . includes ( r ) ? l = Object . assign ( { } , i , { favoriteEvents : a . filter ( n => n !== r ) } ) : ( a . push ( r ) , l = Object . assign ( i , { favoriteEvents : a } ) ) , l } ) } function qe ( r ) { let e , i , a , l , n , t = r [ 1 ] . title + "" , s , o , f ; return { c ( ) { e = m ( "div" ) , i = m ( "div" ) , l = S ( ) , n = m ( "div" ) , s = C ( t ) , this . h ( ) } , l ( v ) { e = g ( v , "DIV" , { class : ! 0 } ) ; var c = k ( e ) ; i = g ( c , "DIV" , { class : ! 0 } ) , k ( i ) . forEach ( d ) , l = T ( c ) , n = g ( c , "DIV" , { class : ! 0 } ) ; var h = k ( n ) ; s = F ( h , t ) , h . forEach ( d ) , c . forEach ( d ) , this . h ( ) } , h ( ) { _ ( i , "class" , a = "w-1 rounded-l-sm " + r [ 1 ] . style ) , _ ( n , "class" , o = ( r [ 0 ] === "big" ? "px-2 py-0.5" : "px-1.5 py-0.5" ) + " rounded-r-sm bg-gray-100 uppercase" ) , _ ( e , "class" , f = "flex " + ( r [ 0 ] === "big" ? "h-6 text-sm" : "h-5 text-xs" ) ) } , m ( v , c ) { q ( v , e , c ) , u ( e , i ) , u ( e , l ) , u ( e , n ) , u ( n , s ) } , p ( v , [ c ] ) { c & 2 && a !== ( a = "w-1 rounded-l-sm " + v [ 1 ] . style ) && _ ( i , "class" , a ) , c & 2 && t !== ( t = v [ 1 ] . title + "" ) && J ( s , t ) , c & 1 && o !== ( o = ( v [ 0 ] === "big" ? "px-2 py-0.5" : "px-1.5 py-0.5" ) + " rounded-r-sm bg-gray-100 uppercase" ) && _ ( n , "class" , o ) , c & 1 && f !== ( f = "flex " + ( v [ 0 ] === "big" ? "h-6 text-sm" : "h-5 text-xs" ) ) && _ ( e , "class" , f ) } , i : x , o : x , d ( v ) { v && d ( e ) } } } function Ce ( r , e , i ) { let a , { event : l = { } } = e , { size : n = null } = e ; const t = { panel : { title : "Panelov\xE1 debata" , style : "bg-custom-red text-white" } , talk : { title : "P\u0159edn\xE1\u0161ka" , style : "bg-custom-green text-white" } , workshop : { title : "Workshop" , style : "bg-custom-blue text-white" } , other : { title : "Ostatn\xED" , style : "bg-custom-yellow" } , lightning : { title : "Bleskov\xE1 p\u0159edn\xE1\u0161ka" , style : "bg-pink-400" } , "lightning-series" : { title : "P\xE1smo bleskov\xFDch p\u0159edn\xE1\u0161ek" , style : "bg-pink-400" } } ; return r . $$set = s => { "event" in s && i ( 2 , l = s . event ) , "size" in s && i ( 0 , n = s . size ) } , r . $$ . update = ( ) => { r . $$ . dirty & 4 && i ( 1 , a = t [ l . type ] ) } , [ n , a , l ] } class Fe extends Ae { constructor ( e ) { super ( ) ; ze ( this , e , Ce , qe , Be , { event : 2 , size : 0 } ) } } function he ( r , e , i ) { const a = r . slice ( ) ; return a [ 12 ] = e [ i ] , a } function _e ( r , e , i ) { const a = r . slice ( ) ; return a [ 15 ] = e [ i ] , a } function ve ( r , e , i ) { const a = r . slice ( ) ; return a [ 18 ] = e [ i ] , a } function pe ( r , e , i ) { const a = r . slice ( ) ; return a [ 15 ] = e [ i ] , a } function me ( r ) { let e , i , a = r [ 5 ] ( r [ 0 ] . speakers ) , l = [ ] ; for ( let t = 0 ; t < a . length ; t += 1 ) l [ t ] = ge ( pe ( r , a , t ) ) ; const n = t => B ( l [ t ] , 1 , 1 , ( ) => { l [ t ] = null } ) ; return { c ( ) { e = m ( "div" ) ; for ( let t = 0 ; t < l . length ; t += 1 ) l [ t ] . c ( ) ; this . h ( ) } , l ( t ) { e = g ( t , "DIV" , { class : ! 0 } ) ; var s = k ( e ) ; for ( let o = 0 ; o < l . length ; o += 1 ) l [ o ] . l ( s ) ; s . forEach ( d ) , this . h ( ) } , h ( ) { _ ( e , "class" , "mt-1 mb-2 flex flex-wrap gap-2" ) } , m ( t , s ) { q ( t , e , s ) ; for ( let o = 0 ; o < l . length ; o += 1 ) l [ o ] . m ( e , null ) ; i = ! 0 } , p ( t , s ) { if ( s & 33 ) { a = t [ 5 ] ( t [ 0 ] . speakers ) ; let o ; for ( o = 0 ; o < a . length ; o += 1 ) { const f = pe ( t , a , o ) ; l [ o ] ? ( l [ o ] . p ( f , s ) , $ ( l [ o ] , 1 ) ) : ( l [ o ] = ge ( f ) , l [ o ] . c ( ) , $ ( l [ o ] , 1 ) , l [ o ] . m ( e , null ) ) } for ( R ( ) , o = a . length ; o < l . length ; o += 1 ) n ( o ) ; W ( ) } } , i ( t ) { if ( ! i ) { for ( let s = 0 ; s < a . length ; s += 1 ) $ ( l [ s ] ) ; i = ! 0 } } , o ( t ) { l = l . filter ( Boolean ) ; for ( let s = 0 ; s < l . length ; s += 1 ) B ( l [ s ] ) ; i = ! 1 } , d ( t ) { t && d ( e ) , se ( l , t ) } } } function ge ( r ) { let e , i , a , l , n , t = r [ 15 ] . name + "" , s , o , f , v ; return i = new Te ( { props : { speaker : r [ 15 ] , size : "extra-small" } } ) , { c ( ) { e = m ( "div" ) , ee ( i . $$ . fragment ) , a = S ( ) , l = m ( "div" ) , n = m ( "a" ) , s = C ( t ) , f = S ( ) , this . h ( ) } , l ( c ) { e = g ( c , "DIV" , { class : ! 0 } ) ; var h = k ( e ) ; le ( i . $$ . fragment , h ) , a = T ( h ) , l = g ( h , "DIV" , { class : ! 0 } ) ; var b = k ( l ) ; n = g ( b , "A" , { href : ! 0 } ) ; var D = k ( n ) ; s = F ( D , t ) , D . forEach ( d ) , b . forEach ( d ) , f = T ( h ) , h . forEach ( d ) , this . h ( ) } , h ( ) { _ ( n , "href" , o = "/lide?id=" + r [ 15 ] . id ) , _ ( l , "class" , "m-auto" ) , _ ( e , "class" , "flex gap-1.5" ) } , m ( c , h ) { q ( c , e , h ) , te ( i , e , null ) , u ( e , a ) , u ( e , l ) , u ( l , n ) , u ( n , s ) , u ( e , f ) , v = ! 0 } , p ( c , h ) { const b = { } ; h & 1 && ( b . speaker = c [ 15 ] ) , i . $set ( b ) , ( ! v || h & 1 ) && t !== ( t = c [ 15 ] . name + "" ) && J ( s , t ) , ( ! v || h & 1 && o !== ( o = "/lide?id=" + c [ 15 ] . id ) ) && _ ( n , "href" , o ) } , i ( c ) { v || ( $ ( i . $$ . fragment , c ) , v = ! 0 ) } , o ( c ) { B ( i . $$ . fragment , c ) , v = ! 1 } , d ( c )