Compare commits

...

648 Commits

Author SHA1 Message Date
qo-op 866271a453 ASTROPORT/ScuttleButt is unmaintained PLEASE INSTALL AstrXbian 2021-05-09 19:41:45 +02:00
qo-op ec067d5690 [Astroport/KODI - astrXbian](https://git.p2p.legal/axiom-team/astrXbian) 2021-03-11 13:11:41 +01:00
qo-op e78474f952 ${RANDOM:0:2} 2020-12-15 01:32:58 +01:00
qo-op 8ceef7e5a8 .old 2020-12-14 21:49:23 +01:00
qo-op 204e851c1b timestamp=$(date -u +%s%N | cut -b1-13) 2020-12-14 21:48:07 +01:00
qo-op 0a8ec2f6e7 better 2020-12-12 21:41:15 +01:00
qo-op b11b7dc207 new jaklis 2020-12-12 21:00:01 +01:00
qo-op 6748274034 correct 2020-12-12 16:53:28 +01:00
qo-op 2401d61911 missing " 2020-12-12 16:22:54 +01:00
qo-op 9ee494795d corrections 2020-12-12 16:18:34 +01:00
qo-op 3ef7320051 g1_profil 2020-12-12 03:25:16 +01:00
qo-op b1b9d2b2e8 initV correction 2020-12-12 02:21:08 +01:00
qo-op 938e2a3b67 multiply install modulation 2020-12-12 01:17:47 +01:00
qo-op 48970b176b using cesium+/gchange+ instead of scuttlebutt 2020-12-12 00:56:07 +01:00
qo-op 7d91c5ce31 GCHANGE+ or CESIUM+ 2020-12-09 02:24:02 +01:00
qo-op d63c56632d Add jaklis/.env in ~/.bashrc? no, yes? 2020-12-08 21:36:54 +01:00
qo-op 0cf78d0700 Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-12-08 21:34:35 +01:00
qo-op 35b3dbd8fd Using CESIUMPLUS=https://g1.data.le-sou.org 2020-12-08 21:34:13 +01:00
qo-op 3ab51f570d comment 2020-12-08 21:30:05 +01:00
qo-op 0617c426f0 xbian/FASTRXBIAN.uniq 2020-12-08 21:29:50 +01:00
qo-op 34675fa5c3 XZUID 2020-12-08 19:58:24 +01:00
qo-op 196dab744f SITE_NAME = 'ASTROPORT _PROFIL_ (_LOGIN_) (_MDP_)' 2020-12-08 19:17:56 +01:00
qo-op 6189737a16 jaklis/.env >> ~/.bashrc 2020-12-08 19:17:43 +01:00
poka 913ae5a16d remove zen/tools/__pycache__/ -> .gitignore 2020-12-08 18:36:48 +01:00
poka 5c65c8fb55 Add tool to convert ipfs ID to pubkey 2020-12-08 18:01:42 +01:00
poka 042e66a091 Use python only, no bash anymore ... 2020-12-08 17:05:04 +01:00
qo-op a1ad3390d8 Sending IPFSTRYME message to $liking_me if ISO already config BOOT 2020-12-08 14:01:35 +01:00
qo-op 8efc0075ba https://copylaradio.com 2020-12-08 13:44:45 +01:00
qo-op 714d21c304 xbian/FASTRXBIAN 2020-12-08 13:42:30 +01:00
qo-op 9675ac7dce FASTRXBIAN for films 2020-12-08 13:37:59 +01:00
qo-op 45fa171ed2 ipfs pin OR NOT 2020-12-08 04:58:43 +01:00
qo-op 2cb216c26e http://localhost:8080/ipns/_XBIANKEY_/xbian/ASTRXBIAN 2020-12-08 04:55:13 +01:00
qo-op b93baa65a4 echo "__________________________________________" 2020-12-08 04:28:45 +01:00
qo-op 47b7f2b08e Delete OLD 'ipfstryme' messages from $liking_me 2020-12-08 04:08:29 +01:00
qo-op 253db07744 Sending IPFSTRYME message to $liking_me 2020-12-08 03:48:54 +01:00
qo-op 11569b5d8a [[ ! $foundIp && ! $isLAN ]] 2020-12-08 03:36:10 +01:00
qo-op b364682ca3 CREATE Vstream/Pastebin file format 2020-12-08 03:31:00 +01:00
qo-op c02ac02e1a CREATE ~/.zen/ipfs/xbian/$XZUID FROM ~/astroport/ 2020-12-08 03:25:22 +01:00
qo-op 887696d967 ipfs cat /ipns/$NODEIPNS/xbian/$XZUID 2020-12-08 03:23:05 +01:00
qo-op f8966720ab ! -f 2020-12-08 02:39:04 +01:00
qo-op be23bccef8 ${peer} 2020-12-08 02:33:58 +01:00
qo-op 12e95c6e00 path error 2020-12-08 02:26:57 +01:00
qo-op 5846b4607b AstXbian ipfs sharing 2020-12-08 02:22:33 +01:00
qo-op 418b0a27bb go on Xbian ISOconfig / Vstream /Pastebin IPNS share 2020-12-08 01:47:34 +01:00
qo-op e8c08856a3 Astroport Vstream addon site 2020-12-07 16:32:25 +01:00
qo-op e9a15eb2e0 kodi/vstream site rename to astroport 2020-12-07 16:31:21 +01:00
qo-op 26ff016710 /var/log/ipfs.log was missing 2020-12-07 16:30:48 +01:00
qo-op 31eb15852c Special Xbian init.d config 2020-12-07 16:29:04 +01:00
qo-op c432c3d3f9 ipfs_SWARM_refresh.sh 2020-12-07 14:45:13 +01:00
qo-op 2ccbfaa344 error correction 2020-12-07 14:44:49 +01:00
qo-op 466640cb91 CREATE SYSTEMD ipfs SERVICE 2020-12-07 14:43:45 +01:00
qo-op e6dce5a44b ~/.zen/A_allow_ip.txt contains IP of my friends 2020-12-06 21:43:10 +01:00
qo-op bee7812705 remove /etc/init.d/ipfs (already in AstrXbian ISO) 2020-12-06 21:39:11 +01:00
qo-op 57f1fdf316 swarm control 2020-12-06 21:29:37 +01:00
qo-op 46ecb32eca swarm control code upgrade 2020-12-06 20:10:35 +01:00
qo-op 19b747ae7f better code 2020-12-06 02:38:19 +01:00
qo-op 1fdad03398 Astroport ID publish in bashrc 2020-12-06 02:11:31 +01:00
qo-op ba09a353f7 UPDATE ~/.bashrc OK 2020-12-06 02:09:28 +01:00
qo-op 1f1a10e7f6 Add $YOU $IPFSNODEID $G1PUB to ~/.bashrc 2020-12-06 02:08:16 +01:00
qo-op b7854c23b5 update_bashrc.sh 2020-12-06 02:04:54 +01:00
qo-op 884d04eb27 .ssb => .zen 2020-12-06 02:00:07 +01:00
qo-op 29e74e3585 .install/update_bashrc.sh 2020-12-06 01:54:01 +01:00
qo-op b89a1642db DEBIAN / XBIAN 2020-12-06 01:34:04 +01:00
qo-op a71c68e75e jaklis new 2020-12-05 02:20:11 +01:00
qo-op 319447f332 NOT WORKING 2020-12-05 02:10:53 +01:00
qo-op 1b0e27ac06 mmm 2020-12-05 02:09:46 +01:00
qo-op bdcca1e213 PeerID 2020-12-05 01:40:51 +01:00
qo-op 7f5fe12277 EXTEND ~/.bashrc 2020-12-05 01:17:58 +01:00
qo-op dc067180f4 775 2020-12-05 00:52:05 +01:00
qo-op e2267718bc first friend is oasis 2020-12-05 00:50:22 +01:00
qo-op 765741151c NODEIPFSID starts with 12D3KooW 2020-12-05 00:10:19 +01:00
qo-op 4f2a93813b 2jQUH4HfHxdTesjCjvMCx1VJgA5AnpuvrWRq1swfRdsS 2020-12-05 00:01:15 +01:00
qo-op 4b11c248eb oasis default bootstrap new ID
12D3KooWBYme2BsNUrtx4mEdNX6Yioa9AV7opWzQp6nrPs6ZKabN
2020-12-04 23:31:28 +01:00
qo-op b9749733b7 ISO first boot autoconfig 2020-12-04 19:48:27 +01:00
qo-op fc0af52605 1st ISO boot autoconfig 2020-12-04 19:42:28 +01:00
qo-op 458bc04e86 $(which zenity) == "" 2020-12-04 15:38:46 +01:00
qo-op fc470fd922 CREATE gchange+ profile 2020-12-04 15:16:16 +01:00
qo-op 3a67c6f679 jaklis 2020-12-04 14:46:53 +01:00
qo-op 6b134195ea cesium-messaging becomes jaklis 2020-12-04 14:45:56 +01:00
qo-op 990ad2ccd7 150x150 2020-12-04 14:31:20 +01:00
qo-op 31585937c1 ~/.zen/astroport/1stRUNconfig.sh 2020-12-04 13:45:47 +01:00
qo-op ae8c4c5724 Choisissez le répertoire à partager par IPFS avec vos amis 2020-12-04 13:40:38 +01:00
qo-op 39a053d136 Create secret key files 2020-12-04 04:09:01 +01:00
qo-op c43852458b run from ~/.config/autostart/Astroport_X_config.desktop 2020-12-04 04:06:24 +01:00
qo-op ac61d1784a hey going further 2020-12-04 02:55:16 +01:00
qo-op c7709f8fb3 libprotoc 3.6.1 vs 3.0.0 2020-12-04 02:26:05 +01:00
qo-op 5c1bd5f82d pkey.Type = crypto_pb2.KeyType.Ed25519 trouble between libprotoc 3.6.1 and libprotoc 3.0.0 2020-12-04 02:25:03 +01:00
qo-op 13163b25e0 FirstXRUNconfig.sh 2020-12-04 01:22:50 +01:00
qo-op 634ece1a58 Fist X run script. Config Astroport 2020-12-04 00:27:47 +01:00
qo-op 3a758185d2 astroport logo 2020-12-04 00:27:08 +01:00
qo-op df565c7297 new jaklis release 2020-12-04 00:26:41 +01:00
qo-op eb5618513d new jaklis release 2020-12-04 00:20:04 +01:00
qo-op cd95ab64ac CHECk if I am liking him either 2020-12-03 16:52:07 +01:00
qo-op 38cf19de97 My friend did not sent ipfstryme message... 2020-12-03 16:10:29 +01:00
qo-op 2f6d30ca38 messages... 2020-12-03 16:03:40 +01:00
qo-op e11269b8e1 chmod 755 2020-12-03 15:53:44 +01:00
qo-op 8e67c82ece Option Message to /tmp/A_liking_me_NO_ipfstryme.txt 2020-12-03 15:51:47 +01:00
qo-op 26f658b4fb I have $friend_of_mine_count friends amoung $liking_me_count liking me people 2020-12-03 13:37:24 +01:00
qo-op cc45584292 ./jaklis.py set -A mon_avatar.png 2020-12-03 12:10:38 +01:00
qo-op 03114014d2 latest gchange messaging 2020-12-03 02:46:55 +01:00
qo-op c98fde5028 sending IPFSTRYME message to my $friend 2020-12-03 01:30:07 +01:00
qo-op 07ef6ce428 cesium messaging jaklis 2020-12-02 22:45:10 +01:00
qo-op b9ede3d0bc CREATE init.d ipfs start/stop script 2020-12-02 15:35:20 +01:00
qo-op fca5581679 #TODO:
# 1. Get gchange in-friends list
# 2. Read gchange+ message from them and find their IPFS tryme address
# 3. Compare with out-friends list and add their address to bootstrap, connect swarm peers
# 4. Send message to not yet in-friends to install Astroport.
2020-12-02 15:18:00 +01:00
qo-op 4ac5123c58 TODO GET ALL MY GCHANGE FRIENDS AND SEND THEM my IPFS Address 2020-12-02 15:07:43 +01:00
qo-op 5b69fb0500 IPFS vstream test list 2020-11-30 21:01:40 +01:00
qo-op 54be96467f adding gchange swarm control 2020-11-30 19:21:30 +01:00
qo-op f2f3492e67 INIT with gchange 2020-11-30 18:42:36 +01:00
qo-op ed79274990 IPFS kodi vstream plugin ~/.kodi/addons/plugin.video.vstream/resources/sites/ipfs.py 2020-11-30 18:13:52 +01:00
qo-op 3326a0cf52 Add /vstream U2B pastebin lists 2020-11-30 17:15:46 +01:00
qo-op e6c017bd63 /home/pi/.zen/secret.dunikey as default cesium-messaging identity 2020-11-30 16:08:05 +01:00
qo-op 188afff413 /home/pi/.zen/secret.dunikey as default cesium-messaging identity 2020-11-30 16:07:11 +01:00
qo-op 8f6fb7e161 Add cesium-messaging code 2020-11-30 16:03:47 +01:00
qo-op 724b85dbeb update bootstrap & correct systemctl 2020-11-24 23:51:55 +01:00
qo-op 4435aa559f JuneLAND 2020-11-18 22:20:41 +01:00
qo-op 1752f68a76 cp -f /tmp/init_IPFS_with_cesium_loginKEY.sh ~/.zen/astroport/zen/tools/ 2020-11-17 22:57:59 +01:00
qo-op 3179a6be2d Please rm -f ~/.zen/secret* before running $ME 2020-11-17 11:49:20 +01:00
qo-op 1e70f7296f manual jq command to change ipfs node id 2020-11-17 11:44:43 +01:00
qo-op b732185603 bip 2020-11-17 11:43:05 +01:00
qo-op 57e120418f -arg PrivKey 2020-11-17 11:42:07 +01:00
qo-op 423f989471 jq ARG passing 2020-11-17 02:01:40 +01:00
qo-op 23e30e1832 ~/.zen/secret(s) are 440 ! 2020-11-17 01:14:39 +01:00
qo-op f44487d086 ~/.zen/secret.june 2020-11-17 01:12:03 +01:00
qo-op b3ea878591 miz simplest salt & pepper 2020-11-17 01:07:32 +01:00
qo-op 68dfb47542 cd /tmp; rm -f /tmp/init_IPFS_with_cesium_loginKEY.sh; wget https://git.p2p.legal/axiom-team/astroport/raw/master/zen/tools/init_IPFS_with_cesium_loginKEY.sh; bash ./init_IPFS_with_cesium_loginKEY.sh 2020-11-16 23:34:09 +01:00
qo-op 4160685c32 -> Read your Cesium messages to find how to Bootstrap your node 2020-11-16 23:29:47 +01:00
qo-op c33f1e3e0a Hit ENTER again to continue 2020-11-16 23:22:18 +01:00
qo-op 21dbdaf9cf ask for credentials, or run diceware to make a Cesium secret.dunikey, SSB secret and IPFS node ID 2020-11-16 23:09:57 +01:00
qo-op a8859ce293 Cesium key can become IPFSNODEID 2020-11-16 23:01:37 +01:00
qo-op 2ea0185d6b Cesium key can become IPFSNODEID 2020-11-16 22:53:22 +01:00
qo-op f6f4ea2bbf No parking logo 2020-11-12 12:52:49 +01:00
qo-op 4718d142ca JuneLAND 2020-11-12 04:54:31 +01:00
qo-op bf4d088033 PrivKey 2020-11-12 03:31:48 +01:00
qo-op 15438ffc05 create ipfs id from /tmp/secret.dunikey 2020-11-12 01:57:54 +01:00
qo-op a719820ccb create_ipfsnodeid_from_tmp_secret.dunikey.py 2020-11-11 18:54:49 +01:00
qo-op dc904751e8 create pubsec secret.dunikey and convert into IPFS Identity 2020-11-07 00:38:03 +01:00
qo-op e78ed00209 Experimental.P2pHttpProxy true 2020-11-06 00:49:18 +01:00
qo-op b2a4010d00 ipfs-update_v1.6.0 & ipfs 0.7.0 2020-11-06 00:27:52 +01:00
qo-op 44c681c31a gchange+ lon lat source 2020-09-16 01:44:19 +02:00
qo-op c1e2b25a6e not authorizing wallet self choosen name 2020-09-15 22:52:18 +02:00
qo-op 896ff9032b now, g1sms wallet name can be choosen with "N pseudo" (if pseudo is not G1member) 2020-09-15 22:42:13 +02:00
qo-op 75ec620ad3 fi 2020-09-15 21:36:25 +02:00
qo-op 31206e2f84 remove ssb-server automatic restart, could be a nightmare for lowpower machine 2020-09-15 21:33:52 +02:00
qo-op 849162d8ba sms antispam message 2020-09-14 16:32:30 +02:00
qo-op 3e0f689dd3 MIZ 2020-09-14 00:03:04 +02:00
qo-op 56e973b9e7 small change 2020-09-10 12:46:50 +02:00
qo-op c57879a90b OK 2020-09-05 00:05:03 +02:00
qo-op 713e782db6 UPGRADE to Cesium 1.6.7 2020-09-05 00:03:16 +02:00
qo-op 61805ef6c9 $AMOUNTZEN ZEN 2020-09-04 23:20:40 +02:00
qo-op 0c769eaa0b ouah tout ça 2020-08-07 04:18:20 +02:00
qo-op b1c2dee9a0 correct REC _CopyLaRadio url 2020-06-25 04:33:07 +02:00
qo-op cba243cf5f less log 2020-06-24 17:13:18 +02:00
qo-op 717212b8c8 + joli 2020-06-23 14:53:57 +02:00
qo-op dcce6d7501 arrangements 2020-06-23 14:49:52 +02:00
qo-op 8b35369380 bottom page hidden on mobile 2020-06-23 14:25:03 +02:00
qo-op d0d82e0597 [Pure bash Bible](https://github.com/dylanaraps/pure-bash-bible) 2020-06-21 22:25:54 +02:00
qo-op 275161b890 # $MY_PATH/zen/gchange_MONITOR.sh & 2020-06-21 22:05:32 +02:00
qo-op 9f196e1ceb restart ssb-server is a pain 2020-06-18 02:55:32 +02:00
qo-op 18a7955264 Avec des logiciels libres, vous avez enfin le choix ! 2020-06-17 23:53:37 +02:00
qo-op d5fd981eb4 ~/.zen/ssb-server.start 2020-06-17 21:29:28 +02:00
qo-op a401b4ae65 sudo adduser $YOU www-data 2020-06-16 23:00:52 +02:00
qo-op b15698f30d header("Access-Control-Allow-Origin: *"); 2020-06-16 18:35:56 +02:00
qo-op d9481491ce JuneLand 2020-06-16 07:39:21 +02:00
qo-op b681bbe1e1 buttons 2020-06-16 07:34:22 +02:00
qo-op c2c9c47109 FAQ https://pad.p2p.legal/s/astroport_FAQ 2020-06-16 07:26:43 +02:00
qo-op cbc2ef2417 $CHECKSWARM 2020-06-16 06:36:18 +02:00
qo-op afe4113ee0 debug and correct 2020-06-16 06:29:58 +02:00
qo-op 9c863fe4bd beauty 2020-06-16 04:01:23 +02:00
qo-op 9868988938 Vous avez besoin d'aide? <a href="mailto:support@qo-op.com">Envoyez un email.</a> 2020-06-16 03:58:23 +02:00
qo-op eab989b3f1 Get Wallet geoloc + avatar (60 mn cache) 2020-06-15 22:06:24 +02:00
qo-op 2059565e62 aris poetry + scuttlebutt & minetest gif 2020-06-15 20:56:13 +02:00
qo-op 50d7761608 just phone 2020-06-15 20:55:09 +02:00
qo-op 51d5995393 rewriting play minetest 2020-06-15 19:59:42 +02:00
qo-op 758b97c9f0 Vous avez $AMOUNTLOVE LOVE sur votre compte. Installez https://cesium.app 2020-06-15 04:13:01 +02:00
qo-op a6c8922545 CLEAN ipfs_swarm 2020-06-15 04:06:27 +02:00
qo-op e610cd2051 visualise passport play juneland 2020-06-15 03:25:56 +02:00
qo-op 17586b81ef play 2020-06-15 02:37:36 +02:00
qo-op d5f7f254f2 source $HOME/.profile 2020-06-14 23:35:06 +02:00
qo-op a5980aec1c g1sms 2020-06-14 23:26:21 +02:00
qo-op 2c33befcf9 push it 2020-06-14 23:23:34 +02:00
qo-op df2968fc4b home 2020-06-14 23:07:42 +02:00
qo-op 15aac892f4 allez commit 2020-06-14 22:26:31 +02:00
qo-op bb640c322b missing ; 2020-06-13 13:38:03 +02:00
qo-op 231caf7395 double auth have to be checked now 2020-06-13 13:37:10 +02:00
qo-op dfe7d2df69 git merge trouble 2020-06-13 13:33:13 +02:00
qo-op 09ca7a8b77 check sbotc is working every 5 mn instead of 1 2020-06-13 13:30:51 +02:00
qo-op 1dbee81e86 ssb-server control & restart 2020-06-13 13:11:20 +02:00
qo-op 16d6594825 time adjustments 2020-06-13 13:02:13 +02:00
qo-op dab8abde99 arrange it 2020-06-12 17:11:28 +02:00
qo-op 8b7b086a3c Utilisez https://cesium.app et https://gchange.fr ! 2020-06-12 17:03:48 +02:00
qo-op f507f175a9 tools path corrected
duniter_server=$(/home/$YOU/.zen/astroport/zen/tools/duniter_getnode.sh)
2020-06-12 16:54:03 +02:00
qo-op 4f16a5dec0 N Pseudo correction (Pb with silkaj timeout !!!) 2020-06-12 16:49:43 +02:00
qo-op f73ab4a140 duniter_server=$(/home/$YOU/.zen/astroport/zen/tools/tools/duniter_getnode.sh) 2020-06-12 16:28:59 +02:00
qo-op 4f80642d90 -mmin +5 2020-06-12 13:03:18 +02:00
qo-op 70784d68d6 hardening silkaj connexion 2020-06-12 12:54:58 +02:00
qo-op fc63a21702 images & juneland video 2020-06-12 12:16:24 +02:00
qo-op b531ce2f4d Add duniter curl testing 2020-06-12 12:15:43 +02:00
qo-op 3711893827 Connectez 2020-06-12 01:57:14 +02:00
qo-op 52546b641f ssb-server
while true; do   ssb-server start;   sleep 3; done
2020-06-12 00:49:57 +02:00
qo-op cb9f38b801 réseaux cesium/gchange/scuttlebutt 2020-06-12 00:43:34 +02:00
qo-op c3c78201e3 loveland 1,2,3 2020-06-12 00:39:15 +02:00
qo-op 072549fa70 pubkey to emoji 2020-06-11 23:29:04 +02:00
qo-op 30b482249f 50km radius 2020-06-11 13:04:43 +02:00
qo-op 985cedf4ef title 2020-06-11 00:49:03 +02:00
qo-op 75933498b2 p2p port forward G1sms 2020-06-09 21:52:29 +02:00
qo-op 3360d5865d Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-06-09 21:50:12 +02:00
qo-op b5dd23ac71 double auth g1billet API 2020-06-09 21:45:18 +02:00
qo-op d69b9f4e8e Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-06-09 21:40:15 +02:00
qo-op b895261c94 web API phone + val => sms_ASTROPORT sms_AUTH 2020-06-09 16:48:50 +02:00
poka 83f25350b1 Enable oasis for ARM 2020-06-09 15:01:10 +02:00
qo-op 2722a14d72 | cut -d '.' -f 1 2020-06-08 14:52:31 +02:00
poka d68f9277d8 Check if ARM, don't install patchwork 2020-06-08 13:53:32 +02:00
qo-op fdece33952 & 2020-06-08 04:04:25 +02:00
qo-op 21b9a1f702 Ajouter sa géolocalisation dans Cesium+ permet de voir les annonces à 10km autour de chez soi... 2020-06-08 03:54:51 +02:00
qo-op 839e2c3bb6 no podcast 2020-06-08 02:23:08 +02:00
qo-op f529525469 podcast 2020-06-08 00:02:41 +02:00
qo-op d7ed05fae2 astrologo 2020-06-08 00:01:56 +02:00
qo-op d6179e0bc5 support@qo-op.com 2020-06-07 20:19:23 +02:00
qo-op 53328d2df9 best top 2020-06-07 01:53:31 +02:00
qo-op c47183f6a3 try to control ssb-server
#!/bin/bash
while true; do
  ssb-server start
  sleep 3
done
2020-06-06 16:09:53 +02:00
qo-op 98866e605f oasis --allow-host oasis.astroport.com --host oasis.astroport.com & 2020-06-06 14:50:38 +02:00
qo-op 78333587ef correct ssb-server freezing/ restart 2020-06-06 14:43:18 +02:00
qo-op b8025902d6 pas de parrain ADMIN LOG g1sms "$parrain ABSENT" (search) 2020-06-06 14:27:22 +02:00
qo-op 67b0e9c63c JEU 0 2020-06-06 14:08:49 +02:00
poka 4590d6e279 Update README.md 2020-06-06 13:46:21 +02:00
qo-op 6eab2d213f time 2020-06-06 12:47:12 +02:00
qo-op 0e25807292 [[ $timestamp -lt $last_ts ]] 2020-06-06 05:28:58 +02:00
qo-op 49d2aa56ff echo "$TODAY 12:12 - OFFICIAL BETA TESTING" 2020-06-06 05:22:18 +02:00
qo-op 6756d1ba43 TODO -> send sbotc message (private or zip attached?) with ssb/ipfs swarm reports 2020-06-06 05:03:55 +02:00
qo-op f028ce98fa uniq /tmp/ssb-friends.txt 2020-06-06 04:55:23 +02:00
qo-op 304176bf40 classify friends... 2020-06-06 04:51:00 +02:00
qo-op 9e35153c17 SSBFRIEND 2020-06-06 04:45:00 +02:00
qo-op 2b8505d6f9 $MY_PATH/zen/ssb_INIT.sh 12:12 2020-06-06 04:06:24 +02:00
qo-op de515799c4 source /home/$YOU/.profile 2020-06-06 03:54:36 +02:00
qo-op 1e2d73327a sbotc problem!! stop oasis, restart ssb-server... 2020-06-06 03:49:24 +02:00
qo-op 8c5867f67d arrange it 2020-06-06 03:26:58 +02:00
qo-op 22ab82c9fc OUI 2020-06-06 02:47:37 +02:00
poka fcede9de86 fix init ssb 2020-06-06 00:39:39 +02:00
poka 99261d36c0 add lib to init scripts 2020-06-06 00:36:44 +02:00
poka b4bdd426a1 Refactor reset_keys scripts 2020-06-06 00:21:07 +02:00
poka 61dfffbcab fix ipfs init alone script 2020-06-06 00:14:13 +02:00
poka a5c9ac52ee Add ipfs init script to pkg 2020-06-06 00:04:06 +02:00
poka 3663dffd58 Add ipfs init script to debug 2020-06-05 23:47:11 +02:00
qo-op 5e4d4f2a3f 80 8021 2020-06-05 19:58:27 +02:00
qo-op 3307529922 vvvv 2020-06-05 19:33:00 +02:00
qo-op cfdc9242d9 https://opencollective.com/monnaie-libre 2020-06-05 19:22:39 +02:00
qo-op 8c5c13142b https://astroport.com/our-developers/index.html 2020-06-05 19:13:45 +02:00
qo-op 98b294968f lines are changing 2020-06-05 19:12:22 +02:00
qo-op 6c10b182c9 il ne reste presque rien à finir... pour terminer Astroport ensemble 2020-06-05 18:58:58 +02:00
qo-op 06f59821e9 ^3000 2020-06-05 18:33:54 +02:00
qo-op 1ba3349fc9 wlcemnds 2020-06-05 18:24:59 +02:00
qo-op 803794199b " : 2020-06-05 18:06:05 +02:00
qo-op 7db9124c28 Jeu de société 2020-06-05 18:00:16 +02:00
qo-op 85c6bc6349 move donation G1 2020-06-05 17:56:27 +02:00
qo-op d310bbcf78 astroport logo merci @attilax 2020-06-05 17:54:10 +02:00
qo-op cbf971eacd coming slowly 2020-06-05 17:48:13 +02:00
qo-op da9434e6a7 - Exemples de services activables sur votre Station Astroport - 2020-06-05 17:23:53 +02:00
qo-op 5568d586a8 A_money 2020-06-05 17:21:52 +02:00
qo-op 9fe206e66a Station "saveur" : G1sms 2020-06-05 17:20:28 +02:00
qo-op 68851fafcd son réseau anoptique restaure la paix. 2020-06-05 17:03:01 +02:00
qo-op 8e1f51fcda Tu recevras une clef pour te libérer des services privés du vieux monde 2020-06-05 16:41:30 +02:00
poka 317b629934 Add piwik following 2020-06-05 13:17:58 +02:00
poka d71a7dcb43 Change socials network links 2020-06-05 13:12:50 +02:00
poka 68d7a19f85 Add piwik following 2020-06-05 12:37:14 +02:00
poka aebc6d2404 Add piwik following 2020-06-05 12:34:07 +02:00
qo-op 5101b4f16e commit 2020-06-04 16:32:17 +02:00
poka c4ca80e045 Fix text 2020-06-04 16:29:46 +02:00
poka ea3c90b822 correctly kill ssb-server 2020-06-04 16:23:35 +02:00
poka 3e0469f94c Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-06-04 16:19:29 +02:00
poka 5015ba21e4 correctly kill ssb-server 2020-06-04 16:19:22 +02:00
qo-op 49bfecdfa5 TODO use sbotc message to benefit from ./zen/ssb_GET_zenyta.sh harvesting 2020-06-04 16:14:51 +02:00
qo-op 1abbc5bc3e youtube-dl goes to your localhost mpd jukebox 2020-06-04 16:09:03 +02:00
qo-op 66d8e04f45 su $YOU -c mkdir -p /home/$YOU/.zen/music/${artist}/${song}/ 2020-06-04 16:07:23 +02:00
poka 3dbc6ee5b4 Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-06-04 16:04:00 +02:00
poka 59a437a985 open browser tabs 2020-06-04 16:03:50 +02:00
qo-op d38037b087 [[ $er ]] && echo $er 2020-06-04 15:49:29 +02:00
qo-op 448fea3844 /home/$YOU/ 2020-06-04 15:46:32 +02:00
qo-op d3bc8293f1 http://localhost:10010/_CopyLaRadio 2020-06-04 15:37:49 +02:00
qo-op 1ff8cfc231 event.target.port=10010 change port 2020-06-04 15:34:41 +02:00
qo-op 0a792d96e9 ./_CopyLaRadio/youtube-dl.php 2020-06-04 15:24:51 +02:00
qo-op 9c3a5ee2ba www/LOVELand/_CopyLaRadio/youtube-dl.php 2020-06-04 15:21:02 +02:00
poka 77854bd1e8 Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-06-04 15:13:00 +02:00
poka af55b644bf disable lan test for oasis 2020-06-04 15:12:55 +02:00
qo-op 47a7f511c5 Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-06-04 15:02:38 +02:00
poka a8d98f2d84 Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-06-04 15:00:19 +02:00
poka 24d9214db4 don't start patchwork 2020-06-04 15:00:16 +02:00
qo-op dca26d3cdf _CopyLaRadio 2020-06-04 14:57:51 +02:00
qo-op ecbf6b090c sync 2020-06-04 14:52:13 +02:00
poka 0103d39cfb Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-06-04 14:41:19 +02:00
poka 84be32ae06 fix patchwork 2020-06-04 14:41:15 +02:00
qo-op e6bb3d1f87 /home/pi/.zen/astroport/zen/_CopyLaRadio is now /var/www/loveland/_CopyLaRadio 2020-06-04 14:31:36 +02:00
qo-op 19b8c3914e /var/www/loveland/_CopyLaRadio 2020-06-04 14:30:04 +02:00
poka 83e93dafd9 Fix nodename ping test 2020-06-04 14:14:49 +02:00
poka c68c45a2c5 Change way to install patchwork and launch it 2020-06-04 14:08:18 +02:00
poka df051d7c19 Add final test to nodename 2020-06-04 13:07:13 +02:00
qo-op a95046ae0b get zenyta message types received from http://localhost:10011/REC/youtube-dl.php 2020-06-04 06:33:12 +02:00
qo-op 72a6a7bef6 CopyLaRadio sbotc zenyta command 2020-06-04 06:23:22 +02:00
qo-op 02cb67d2b5 /REC 2020-06-04 05:37:43 +02:00
qo-op 188ce403cc Les liens "IPFS" fonctionnent une fois astroport installé sur votre ordinateur. 2020-06-04 04:01:33 +02:00
qo-op 6922f46fb6 Les liens "IPFS" fonctionnent une fois astroport installé sur votre ordinateur. utilisateur pi pour activer les espaces DIY 2020-06-04 03:59:06 +02:00
poka d7164cf2f8 Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-06-04 01:49:06 +02:00
poka 5c6baa8d93 Open loveland in browser 2020-06-04 01:48:59 +02:00
qo-op 82918451ce CodiMD is your PAD, Facebook is closing soon. You are the Internet. Let's do it. 2020-06-04 01:46:27 +02:00
qo-op 430b2cb846 son activation forme un réseau qui restaure la paix 2020-06-04 01:26:46 +02:00
poka d60d40e10c fix nslookup timeout 2020-06-04 00:59:26 +02:00
poka b146a2cab8 Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-06-04 00:53:03 +02:00
poka 1bfe475ffa fix nslookup timeout 2020-06-04 00:52:58 +02:00
qo-op 5488baac1b Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-06-04 00:24:01 +02:00
poka 270c81d543 Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-06-04 00:23:37 +02:00
qo-op 1d865d2c66 Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-06-04 00:23:33 +02:00
poka 2de3ea65f0 Install patchwork and loveland 2020-06-04 00:23:31 +02:00
qo-op 1f2299476f Rompr config 2020-06-04 00:21:58 +02:00
qo-op 90613312ff Rompr config 2020-06-04 00:21:24 +02:00
qo-op 02d584022b dream catcher. living leaving digital nightmare system 2020-06-04 00:19:58 +02:00
qo-op b20ad96d70 Rompr config 2020-06-04 00:17:13 +02:00
qo-op 0b8d89b9e5 Rompr config 2020-06-04 00:16:27 +02:00
poka fef6d459d7 patch nodename for pingable adress 2020-06-04 00:06:18 +02:00
qo-op 8eb3caa92a carte des Junistes 2020-06-03 22:18:03 +02:00
qo-op 5ca4330691 le robot gentil qui aime jouer à vous aider. 2020-06-03 20:53:10 +02:00
qo-op 6be1fb794a Astroport. le robot gentil qui aime jouer à nous aider.^3000 vous dit bonjour 2020-06-03 20:51:18 +02:00
qo-op 98006d6187 une [PLANETE] Heureu(x)se(s) vers UN Futur PLUS Humain(s) est possible. 2020-06-03 20:48:38 +02:00
qo-op a1ca2449e6 Reçois 3.14 'June' mon ami(e)s 2020-06-03 20:37:55 +02:00
qo-op 91d13bae75 et patiente un peu... tu entres un monde Zen. 2020-06-03 20:35:13 +02:00
qo-op 7dabc096fd là, tu démarres le jeu <br>avec 314 Zen 2020-06-03 20:30:44 +02:00
qo-op 7545a25923 oasis shaping 2020-06-03 20:27:31 +02:00
qo-op d9c10fb529 <br><br><br><br><br><br><br> 2020-06-03 20:19:38 +02:00
qo-op e32c713a40 echo 'vous n avez pas encore de conscience numerique'
echo 'mise a jour de votre systeme... en cours'
        echo 'https://git.p2p.legal/axiom-team/astroport'
2020-06-03 19:56:33 +02:00
qo-op 34ba54d067 push it, push it real hard 2020-06-03 19:17:50 +02:00
qo-op e86e8f0047 Tu vas recevoir une clef... Puis tu vas apprendre à t'en servir. 2020-06-03 18:45:54 +02:00
qo-op e2a26c0d9c clic clac 2020-06-03 18:30:24 +02:00
qo-op 083b86c843 piwik.p2p.legal 2020-06-03 17:39:19 +02:00
qo-op 44389cd31d timeout.sh 2020-06-03 02:09:46 +02:00
qo-op 77e4ad22bd bold 2020-06-03 01:57:14 +02:00
qo-op 626dfeff0e joie 2020-06-02 18:58:37 +02:00
qo-op 2665f169d3 href white style 2020-06-02 18:51:26 +02:00
qo-op 4094fce69f ées ô 2020-06-02 18:45:42 +02:00
qo-op 5d81360cf0 LOVE land 2020-06-02 16:38:38 +02:00
qo-op c9409542f9 remove dependancy 2020-06-02 16:26:55 +02:00
qo-op 76b7a5c8a7 TweenMax.min.js 2020-06-02 16:26:26 +02:00
qo-op 0a1be0349b install alpha base station 2020-06-02 16:09:01 +02:00
qo-op 1ddf4fcd77 Un cube de presque 1 hectare de pixels de coté où vous pourrez bâtir gratuitement 2020-06-02 05:02:07 +02:00
qo-op 9cd4aa5f51 sa structure en essaims, empèche l'extraction de vos données par tout système d'information global 2020-06-02 05:00:39 +02:00
qo-op 2ac30b5551 no video here 2020-06-02 04:46:12 +02:00
qo-op 2883488152 Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-06-02 04:39:32 +02:00
qo-op 8e2d6cbccb video background 2020-06-02 04:39:21 +02:00
qo-op a8add2b247 website prepare 2020-06-02 04:38:42 +02:00
poka 57914b08b2 Change footer copyright 2020-06-01 23:05:06 +02:00
qo-op 5c7d6dd9b4 more is better 2020-06-01 22:25:12 +02:00
qo-op 1dc9b1fc0f kill your internet and make it born again 2020-06-01 19:20:09 +02:00
qo-op a042f9d2bc Les possibilités sont sans limites 2020-06-01 16:14:54 +02:00
qo-op 9d7355100d push push push 2020-06-01 16:14:20 +02:00
qo-op 366849ab2d a new day is rising 2020-06-01 05:26:19 +02:00
qo-op a6664f4e40 engine warming up 2020-06-01 05:04:39 +02:00
qo-op 579efc64b5 wooooooo 2020-06-01 04:27:12 +02:00
qo-op 9c28d9c421 page building 2020-06-01 02:39:34 +02:00
qo-op cf989e21eb astroport loveland 2020-06-01 01:21:00 +02:00
qo-op e1d65e0f88 cleaning future astroport launch 2020-06-01 01:13:31 +02:00
qo-op 81ac3ced98 logo 2020-05-31 23:19:36 +02:00
qo-op 5e05ed73dc logo 2020-05-31 23:17:24 +02:00
qo-op 27c8d0f7a5 youpi 2020-05-31 23:16:28 +02:00
poka 42cde56ee4 Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-05-31 23:14:21 +02:00
poka 06a3c64e7e Add partenairs to A site 2020-05-31 23:14:16 +02:00
qo-op 6204ac01ae Aaa 2020-05-31 22:42:34 +02:00
qo-op fc1b2ab287 translate & adapt 2020-05-31 22:32:22 +02:00
qo-op 0a279fb673 A 2020-05-31 21:38:18 +02:00
qo-op f5f7a59293 Solving the angel problem 2020-05-31 13:12:04 +02:00
qo-op 5efeb4233c jq silkaj problem solved 2020-05-29 17:43:20 +02:00
qo-op 6e3f8e1ba0 sudo ipfs-update install 0.5.1 2020-05-29 16:53:22 +02:00
qo-op ea312009b1 hyperweb is waiting for you 2020-05-29 15:32:16 +02:00
qo-op e273f9ca95 TODO AKE DOUBLE AUTH.... !!! before creating account. 2020-05-29 03:04:34 +02:00
qo-op 436e23d691 Utilisez vos identifiants dans Cesium et Gchange pour activer votre clef... 2020-05-29 02:58:43 +02:00
qo-op 9573c4382d just make it right this time 2020-05-29 02:53:46 +02:00
qo-op 3651351701 duniter-g1.p2p.legal 2020-05-28 21:07:10 +02:00
qo-op 6f8535a440 [Astroport] Clefs 2020-05-28 21:04:29 +02:00
qo-op c37b6c4c1c https://cesium.app 2020-05-28 21:00:16 +02:00
qo-op 2295a91577 / 2020-05-28 20:56:31 +02:00
qo-op 9320d5e906 Astroport 2020-05-28 20:54:06 +02:00
qo-op 1940be248f Unités monétaires Libres disponibles 2020-05-28 20:50:55 +02:00
qo-op 00a8b8ab36 DNowWi2znAKJpzxR1z5EKm7cU7rfySzihJ2Gzbdp78Sx G1PUb 2020-05-28 20:43:25 +02:00
qo-op ad5a916312 g1sms connect 2020-05-28 20:38:53 +02:00
qo-op 0330d5c087 PHONE control SMS 2020-05-28 20:34:39 +02:00
qo-op b67b3733b1 log > /dev/null 2020-05-28 20:22:16 +02:00
qo-op c7b5d2fa4e YOU and IPFSNODEID coming from init.sh 2020-05-28 20:17:15 +02:00
qo-op 1de65f9612 LOVE bank 2020-05-28 20:11:22 +02:00
qo-op 1752c23917 last row 2020-05-28 20:07:35 +02:00
qo-op 41f8ad49c8 ugly patch. 2020-05-28 20:06:02 +02:00
qo-op 3d2be75fec pubkey from dunikey 2020-05-28 20:00:30 +02:00
qo-op b270216e4d escape 2020-05-28 19:52:53 +02:00
qo-op e532f9a066 g1barre 2020-05-28 18:26:03 +02:00
qo-op 2266bf3b7e git in git is git problem 2020-05-28 18:24:46 +02:00
qo-op ea71477627 g1barre 2020-05-28 18:22:10 +02:00
qo-op 05b1971710 LOG g1SMS Station to /tmp/g1sms.log 2020-05-28 18:14:46 +02:00
qo-op 0481948db8 SMS COMMAND from LOVELAND entrance 2020-05-28 17:55:06 +02:00
qo-op 12ffbf5d97 CREATE g1sms WALLET 2020-05-28 17:49:55 +02:00
qo-op b0de34e30c add station wallet finance bar - TODO adapt php to LOVELand 2020-05-28 17:36:24 +02:00
qo-op f1dc8af4e1 Add ssb-server to OASIS 2020-05-28 17:27:27 +02:00
qo-op 681ae26d26 install ssb-server ## ADD SSB-SERVER FOR PRIVATE SSB MESSAGING (TODO: integrate Feedless modules on LOVELand Portal) 2020-05-28 17:12:15 +02:00
qo-op 9c31bf6e13 bash is creole language 2020-05-28 17:01:11 +02:00
qo-op dea9c80989 daft punk edit 2020-05-28 16:59:53 +02:00
qo-op 0f0e1d9bd5 iptubes update 2020-05-28 16:10:43 +02:00
qo-op 737415eb49 for hashfile in /tmp/loveland_entrance/* 2020-05-28 16:10:18 +02:00
qo-op c32557d35c which gammu-smsd 2020-05-28 16:07:55 +02:00
qo-op c9f9873642 simple SMS send 2020-05-27 17:44:38 +02:00
qo-op 59d6f745ca about 2020-05-27 16:00:44 +02:00
qo-op d7cfdf9fc3 count=$((count+1)) 2020-05-26 22:06:25 +02:00
qo-op 8931334d51 /tmp/ssb-friends_ALERT.txt 2020-05-26 22:05:11 +02:00
qo-op 480a8c72ff ipfs swarm peers 2020-05-26 21:49:16 +02:00
qo-op 38e4e1e82c private.publish 2020-05-26 21:47:57 +02:00
qo-op 0128b16da0 not a SSB friend trying to connect to IPFS swarm 2020-05-26 21:45:44 +02:00
qo-op 91cdaffbf4 strict SSB/IPFS connection 2020-05-26 21:37:45 +02:00
qo-op bfc5b6048f refresh full bootstrap 2020-05-26 21:33:12 +02:00
qo-op 8d155a01c2 carte personnelle et interactive 2020-05-26 20:51:40 +02:00
qo-op 5e55b1a3cd Construction de votre carte personnelle et interactive du Territoire 2020-05-26 20:26:19 +02:00
qo-op 8cafaeef67 LoveLand 2020-05-26 20:08:29 +02:00
qo-op 9b01a099eb Feedless Map 2020-05-26 20:06:23 +02:00
qo-op 6fa5976f31 Zapp LOVELand ZApp carte interactive 2020-05-26 20:05:58 +02:00
qo-op 4088309869 swarm#0 ADN modification restore 2020-05-26 17:28:09 +02:00
qo-op 052d045644 26 2020-05-26 17:20:23 +02:00
qo-op 53371ed2d9 h 2020-05-26 17:20:02 +02:00
qo-op 3c3f92fac7 bootstrap change 2020-05-26 17:18:47 +02:00
qo-op e043d7c21b TEMP bootsrap refresh 2020-05-26 17:09:13 +02:00
qo-op f90ba3f0bc change oasis "ipfs id" 2020-05-26 17:01:07 +02:00
qo-op 38d2ef5488 fd42:feed:feed:feed openvpn filtering 2020-05-26 16:47:07 +02:00
qo-op 946293a869 Oeuvre dynamique en Intelligence Collective 2020-05-26 12:30:01 +02:00
qo-op b342fddb3f REC done by REC Machine 2020-05-26 04:32:57 +02:00
qo-op 94e9b4f849 24 2020-05-26 04:20:31 +02:00
qo-op 07c76661cc 72 2020-05-26 04:20:00 +02:00
qo-op 9e4824087c 48 hours 2020-05-26 04:16:18 +02:00
qo-op 7419b2518b lltag -a "$artist" -A "$album" -t "$fulltitle" "~/.zen/audio/$fulltitle.mp3" 2020-05-26 04:14:33 +02:00
qo-op 465e9e85b2 mv "$MP3" "~/.zen/audio/$fulltitle.mp3" 2020-05-26 04:11:42 +02:00
qo-op d8c7725ec5 mesure et mp3 tagging 2020-05-26 04:03:16 +02:00
qo-op 8a13c26f91 Actual Internet is a place full of virus 2020-05-25 23:23:16 +02:00
qo-op 1c67ed9a35 Discover "LOVE Land" the 1st Libre Metaverse interface, a living digital space 2020-05-25 23:20:50 +02:00
qo-op 47a518c196 target="astroport" 2020-05-25 23:15:43 +02:00
qo-op 8bc0e5eed7 https://pad.p2p.legal/astroport-BV/slide 2020-05-25 23:04:48 +02:00
qo-op 240eb1a320 target="ipfs" 2020-05-25 23:01:40 +02:00
qo-op 99fee58488 animated gif & ascii art 2020-05-25 23:00:30 +02:00
qo-op 8582694230 Les liens IPFS fonctionnent exclusivement sur une Station faisant partie du Swarm#0 ! 2020-05-25 22:57:32 +02:00
qo-op b5bd8a92c9 Simulation organique = Bio-mimétisme digital de la VIE
Radio, TV, Web... et HyperWeb par et pour les gens
Science et Innovation : Unité de mesure, Jeu Ange/Démon, ...
2020-05-25 22:45:13 +02:00
qo-op bb06918710 LOVE Land - is LIFE - is LOVE 2020-05-25 22:38:02 +02:00
qo-op 9a7202e9e0 ipfstryme NOT isLAN FROM tail, v4, v6 2020-05-25 21:38:25 +02:00
qo-op 95c7e1d21e ipfstryme correction + ipfstrymev6 addition in SSB feed 2020-05-25 21:24:33 +02:00
qo-op 099b049825 REMOVE youtube-dl -> loveland.sh JOB 2020-05-23 18:31:15 +02:00
qo-op aafd1b2104 00:01 7th of the month => reevaluate Datastore.StorageMax $diskSize 2020-05-23 18:21:57 +02:00
qo-op aecfde52ec loveland is getting beautiful 2020-05-23 18:14:44 +02:00
qo-op 3c226be0b7 $USER = $YOU 2020-05-23 18:10:10 +02:00
qo-op ac88b5f642 ipfs p2p PROPAGATION WITH 'zen/ipfs_OPEN_ports.sh' 2020-05-23 17:31:32 +02:00
qo-op 54763906ac g1sms_proxy.conf 2020-05-23 17:15:42 +02:00
qo-op 3656b2e71a LHOST instead of LPORT 2020-05-23 14:51:11 +02:00
qo-op a122561e48 http://nodename:10099/ = double auth 2020-05-23 05:02:58 +02:00
qo-op f93275edfe host:10099 -> ipfs p2p localhost:10097 2020-05-23 05:02:11 +02:00
qo-op 98c50e06e2 LOVELAND ENTRANCE RECEIVED 2020-05-23 04:07:37 +02:00
qo-op 8da5e36b75 cron $PATH correction 2020-05-23 03:57:01 +02:00
qo-op 60e7d9ec17 mkdir("/tmp/loveland_entrance"); 2020-05-23 03:49:00 +02:00
qo-op bcbb2ed11c sms_loveland.php 2020-05-23 03:40:03 +02:00
qo-op f31891acb6 g1sms LOVELAND ENTRANCE published on http://127.0.0.1:10099/sms_loveland.php 2020-05-23 03:28:26 +02:00
qo-op 41693e8b00 ipfs p2p forward g1sms:10099 to all swarm node 2020-05-23 03:05:05 +02:00
qo-op 135f4647c9 g1sms 2020-05-23 02:24:49 +02:00
qo-op 5cb9809df2 G1SMS loveland entrance localhost:10099 ("ipfs p2p" forwarded) 2020-05-23 02:20:43 +02:00
qo-op 5c635d0a13 www/LOVELand/g1sms/ 2020-05-23 02:14:39 +02:00
qo-op a6ba0d7b65 lalala 2020-05-23 00:32:12 +02:00
qo-op 7b3f403a3d hop la 2020-05-23 00:31:17 +02:00
qo-op d5d5edda0d rewriting chapters 2020-05-23 00:06:53 +02:00
qo-op e0e44ca529 cleaning 2020-05-22 23:55:27 +02:00
qo-op 619ece36eb count=$((count+1)) 2020-05-22 23:38:57 +02:00
qo-op ae0dfdc48a ............. 2020-05-22 23:14:38 +02:00
qo-op e489a73efa astroport.frama.site 2020-05-22 23:05:34 +02:00
qo-op 9b24d19788 astroport.frama.site 2020-05-22 22:59:04 +02:00
qo-op 17d4e1faab g1.le-sou.org 2020-05-22 17:23:09 +02:00
qo-op 6bb21d6225 souveraineté 2020-05-22 17:21:45 +02:00
poka acf10ca9ef [Nestcloud] Fix php version 2020-05-22 17:06:27 +02:00
qo-op 9aa00d692b remove last dot only from reverse lookup 2020-05-22 15:15:03 +02:00
qo-op ab61a64807 better nsloopkup result parsing 2020-05-22 14:56:59 +02:00
qo-op 360097cec0 natools 755 2020-05-22 03:42:59 +02:00
qo-op f981fe62ed natools 755 2020-05-22 03:42:34 +02:00
qo-op 2b638d6995 \ 2020-05-21 21:07:07 +02:00
qo-op 8ff7ff3c50 Passerelle IPFS 2020-05-21 16:09:11 +02:00
qo-op 52bfccb31e french LOVELand 2020-05-21 15:51:30 +02:00
qo-op dfd392597b buttons 2020-05-21 15:49:24 +02:00
qo-op 945261aadb Participating @attilax @poka @josselinchevalay @ben @mlsuyt @tuxmain @qo-op @manutopik @yyy @borispaing @paulart @guenoel @jeanluc @nox @pruls @cel @andrestaltz @Dan ... I have to stop... to many people... 2020-05-21 15:42:39 +02:00
qo-op 430a520142 Grâce aux données extraites du vieux "Web 2.0" 2020-05-21 12:08:39 +02:00
qo-op 89c11dfb73 Interagissons collectivement. Entre amis, tout simplement! 2020-05-21 12:06:40 +02:00
qo-op 78dc7550d2 Une planète vivante où les humains vivent heureux 2020-05-21 12:05:47 +02:00
qo-op 006eab5b0e "Metavers" personnel 2020-05-21 12:04:53 +02:00
qo-op 6fbc55a7ae intelligence collective 2020-05-21 12:04:19 +02:00
qo-op 8475c8ecef nous formons le "LOVE Land" 2020-05-21 12:02:14 +02:00
qo-op f596fb51db Recentré, créé par les Humains qui le compose. 2020-05-21 12:00:55 +02:00
qo-op 88498adaf3 Pour une planète Heureuse 2020-05-21 11:41:28 +02:00
qo-op 1d709d2c38 ipfs task todo/done system + sbotc basic dialog 2020-05-21 11:33:30 +02:00
qo-op afd7c29b7c Pour une planète Heureuse 2020-05-21 11:32:43 +02:00
qo-op 90d54acb30 cleaning done 2020-05-21 02:35:06 +02:00
qo-op a3b2babb33 better convention respect 2020-05-21 02:34:16 +02:00
qo-op f5ddebb252 remove file being in gitignore 2020-05-21 02:11:38 +02:00
qo-op d2ef8d267d df -h ~/.ipfs/ | tail -n 1 | awk '{print $4}' 2020-05-21 01:59:19 +02:00
qo-op d8779b3b4f duniter-g1.p2p.legal 2020-05-21 01:55:54 +02:00
qo-op 2d4752a5b4 port / path correction 2020-05-21 00:53:28 +02:00
qo-op e7d26b4fe2 YOU missing... 2020-05-21 00:50:22 +02:00
qo-op 67006ce3e4 links --public 2020-05-21 00:45:35 +02:00
qo-op 2078666dfa TRY ME 2020-05-21 00:04:07 +02:00
qo-op 61d312a64c adapt 100** service port. & get nodename from IPFS 2020-05-21 00:02:19 +02:00
qo-op 981c650229 upgrade natools.py 2020-05-20 23:42:40 +02:00
poka eb5a7e40ac Fix php-fpm version reload 2020-05-20 22:49:40 +02:00
poka 0a679c753b Replace nodename function in install scripts 2020-05-20 22:32:06 +02:00
poka 5348b4f1dd [install] Try to fix permission for ipfs 2020-05-20 22:14:56 +02:00
qo-op b8d73a60dc lowercase patch 2020-05-20 21:56:04 +02:00
poka 0c1569e5ce [Install] Fix stuff 2020-05-20 21:54:31 +02:00
poka 95088fd166 [Install] Fix ipfs user permissions 2020-05-20 21:24:32 +02:00
poka 16d34f08e4 [Install] Fix ipfs user permissions 2020-05-20 21:22:22 +02:00
poka 0ae43511cf Add options to install 2020-05-20 21:09:22 +02:00
poka 4cdc9bec9a Fix NC 2020-05-20 21:00:12 +02:00
poka 33d8fdb3d0 Fix user open browser 2020-05-20 20:54:01 +02:00
poka ca55490187 Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-05-20 20:48:57 +02:00
poka 31e55f05ae [Improve script reading, fix phpversion in template] 2020-05-20 20:48:49 +02:00
qo-op 1afcea29c1 doc images + jukebox prefs albumart in .gitignore 2020-05-20 20:04:49 +02:00
qo-op 78bc0663b8 + @benoit Version: 0.4 2020-05-20 18:37:59 +02:00
qo-op c0f074de19 add -w option for LAN situation, but WAN access through NAT + never output empty 2020-05-20 18:37:06 +02:00
qo-op f538db2835 fe80::208:a2ff:fe0c:20d8 ipv6 address for oasis.astroport.com bootstrap 2020-05-20 17:53:10 +02:00
qo-op 8f98a16418 ipfs config documentation 2020-05-20 17:51:33 +02:00
qo-op 6e8c671789 In case try nsloopkup timeout => get /etc/hostname 2020-05-20 15:02:00 +02:00
poka d0d36a6f5b Fix install 2020-05-20 03:09:08 +02:00
poka 129cd9f048 Fix install 2020-05-20 03:06:22 +02:00
poka f6eaac0202 Fix install 2020-05-20 03:04:40 +02:00
poka 97ae8a7da7 Fix install 2020-05-20 03:02:57 +02:00
poka fca6751183 Fix install 2020-05-20 02:56:59 +02:00
poka a7b91e26ba Fix install 2020-05-20 02:16:53 +02:00
poka 6738ce8ffa Fix install 2020-05-20 02:10:50 +02:00
poka 7280fe49fb Fix install 2020-05-20 02:06:08 +02:00
poka 14a38a4735 Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-05-20 02:01:28 +02:00
poka 03434728cf Fix install 2020-05-20 02:01:24 +02:00
qo-op aa37de10ec Dans le code!!! Ajoutez vos questions, TODO, idée d'amélioration, question sur ce que fait le code... 2020-05-19 23:01:36 +02:00
qo-op a74f3a99e2 ;event.target.protocol='http:'; 2020-05-19 22:43:20 +02:00
poka f1e5bc7a8f Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-05-19 22:25:31 +02:00
poka 497002bf4c fix colors 2020-05-19 22:25:25 +02:00
qo-op 8aead95a7e +[[ ! $(which mpd) ]] && sudo apt-get update 2020-05-19 22:20:31 +02:00
qo-op e6a1e2b02c rebug 2020-05-19 22:15:44 +02:00
qo-op c2c82e2df7 bug \ 2020-05-19 22:14:38 +02:00
poka f548387540 Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-05-19 22:09:33 +02:00
poka 21484c09a5 [Nextcloud] add php version detection 2020-05-19 22:09:28 +02:00
qo-op f135d0d842 BUILT FROM GNU CORE BASH TECHNOLOGY 2020-05-19 22:04:14 +02:00
qo-op c9105da738 ipns indexing Node DHT & Zen nano DHT 2020-05-19 22:01:47 +02:00
poka e8cff93034 Fix OS check 2020-05-19 21:28:09 +02:00
poka 843e30551c Fix install NC 2020-05-19 21:17:23 +02:00
poka d9db3073b8 Remove sudo variables ... 2020-05-19 21:05:27 +02:00
poka e81f55d73a Add environment variables for root 2020-05-19 20:54:50 +02:00
poka ef7c7b3355 [nextcloud] little fix 2020-05-19 20:47:35 +02:00
poka 949e5b7a18 Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-05-19 20:43:40 +02:00
poka 412bad810b [Nextcloud] Change php install 2020-05-19 20:43:35 +02:00
qo-op f03cdd6ffb **'Give Your App a Unique Name in your #Swarm0"** 2020-05-19 19:02:05 +02:00
poka 31162f0864 Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-05-19 18:41:06 +02:00
poka 6979edc247 Change environnement variables session 2020-05-19 18:40:50 +02:00
qo-op 0cb99322e7 full relative swarm0 Metaverse is used by Ghost & Gobelins. Blob can be anything. like a coding School... 2020-05-19 18:19:23 +02:00
qo-op 66e4c919fa ZenTAG mechanic is maintaning the Index/DATA relation (chained in time into nano ipns DHT) 2020-05-19 18:15:51 +02:00
qo-op a7cfbe2022 SSB_Stations_Swarm0 2020-05-19 18:12:07 +02:00
qo-op 89733d3899 SSB_Stations_Swarm0 2020-05-19 18:11:09 +02:00
qo-op 0171dd60f3 DOCS - similar concepts & mechanics Samza DB over IPFS 2020-05-19 18:01:05 +02:00
poka 1db58a0160 [Nextcloud] Fix templates folder location 2020-05-19 17:28:20 +02:00
poka 53e52e9b41 [Nextcloud] Fix nodename script location 2020-05-19 17:25:14 +02:00
poka e5d026cf53 Add data-dir in .zen/nextcloud for nextcloud flavor 2020-05-19 17:22:46 +02:00
qo-op 24f2ddc0e7 Industrial Global Economy (now collapsing !?) 2020-05-19 06:18:22 +02:00
qo-op 34333f8b57 The Tomato 🍅 p2p market 2020-05-19 06:16:34 +02:00
qo-op a8228fa1a6 [**DEMO #Swarm0**](https://oasis.astroport.com) 2020-05-19 06:15:13 +02:00
qo-op 21f00b76bc Activate The 100km Metaverse mini-Worlds radar mode and filter information from Transiscope/Gchange 2020-05-19 06:13:49 +02:00
qo-op 6d02feed32 🍅 2020-05-19 06:11:49 +02:00
qo-op 85d40903dc 🍅 2020-05-19 06:10:49 +02:00
qo-op 1450ec74dc better 2020-05-19 06:07:02 +02:00
qo-op 6b18744404 md problem 2020-05-19 05:54:21 +02:00
qo-op f7909e326e astroport is an open protocol telecommunication switch !!! 2020-05-19 05:51:08 +02:00
qo-op 35f8d9f3d8 The Carrot 🥕 making and "Know How" sharing economy example. 2020-05-19 05:37:51 +02:00
qo-op 7863028055 OASIS RULES. App to DApp 1.2.3 2020-05-19 05:07:06 +02:00
qo-op 1e32385e51 https://git.p2p.legal/axiom-team/astroport/src/master/g1sms/Readme.md 2020-05-19 05:05:51 +02:00
qo-op 02cf351c9b /src/master/g1sms/Readme.md 2020-05-19 05:05:02 +02:00
qo-op 8871eb14ba DEMONSTRATION 2020-05-19 04:59:55 +02:00
qo-op 2160de282c hop 2020-05-19 04:57:11 +02:00
qo-op c0c00aa369 LA PUnTA 2020-05-19 02:39:21 +02:00
qo-op b32f241265 LA PUTA 2020-05-19 02:39:03 +02:00
qo-op b39e994479 GROGol traduction 2020-05-19 02:26:21 +02:00
qo-op ef66f622dd Metaverse interface in live buidling process 2020-05-19 02:19:01 +02:00
qo-op e28ceade28 +This is a mesage with love from outer space 2020-05-19 02:14:50 +02:00
qo-op 3e6ba7fcc2 LIFE 2020-05-19 02:10:15 +02:00
qo-op a57fc710c9 it behaves like the blob creature 2020-05-19 02:07:32 +02:00
qo-op 912c1c0773 README and Ask in Issue!!!!! 2020-05-19 02:05:08 +02:00
qo-op c10e4731fc #open-collective-donations 2020-05-18 22:38:06 +02:00
qo-op 6b5e4ba537 WELCOME. Read the code step by step to undertand poor rookie, stop think and think it is. Try, Fail? Think. EVOLVE !!!!
RTFM Bastard. I love U
2020-05-18 22:36:11 +02:00
qo-op 589ac8fd3f mkdir -p /home/$YOU/.zen/ipfs/.$IPFSNODEID/TASK/loveland_entrance 2020-05-18 21:42:44 +02:00
qo-op ca060a51cf ffmpeg -ss 00:00:00.000 -i blob.mp4 -pix_fmt rgb24 -r 10 -s 320x240 -t 00:00:10.000 blob.gif 2020-05-18 07:30:01 +02:00
qo-op 6276aae951 BLOB CREATURE 2020-05-18 07:29:07 +02:00
qo-op 9d1137ff04 10010 2020-05-18 07:15:21 +02:00
qo-op fff0e34ca2 flight programmed at gate zero... 2020-05-18 07:14:02 +02:00
qo-op b4313d6b36 Feedless 2020-05-18 07:08:22 +02:00
qo-op 79cc0de1ca /tmp/oasis.conf 2020-05-18 07:01:57 +02:00
qo-op aef8d7b5a2 NODENAME=$nodename 2020-05-18 06:55:39 +02:00
qo-op 0d201be50b loveland 2020-05-18 06:49:21 +02:00
qo-op 05c339c041 __ ____ _ __________ __
/ /   / __ \ |  / / ____/ /   ____ _____  ____/ /
  / /   / / / / | / / __/ / /   / __ `/ __ \/ __  /
 / /___/ /_/ /| |/ / /___/ /___/ /_/ / / / / /_/ /
/_____/\____/ |___/_____/_____/\__,_/_/ /_/\__,_/
2020-05-18 06:45:31 +02:00
qo-op 992be40be0 ./zen/ipfs_SWARM_refresh.sh 2020-05-18 06:38:46 +02:00
qo-op 581eeba35b multiport Love LAND nodename 2020-05-18 05:49:04 +02:00
qo-op 15c9f6eb4b starwars lol www/oasis.conf 2020-05-18 04:35:36 +02:00
qo-op 28f61cd2cb /usr/games/ 2020-05-18 04:02:31 +02:00
qo-op d5466612cb rainbow 2020-05-18 03:58:04 +02:00
poka dd5748cd2c Merge branch 'master' of https://git.p2p.legal/axiom-team/astroport 2020-05-18 00:55:48 +02:00
poka 320ec4907d change ipfs swarm check 2020-05-18 00:55:43 +02:00
qo-op 9b6111cec1 loveland coming... 2020-05-17 23:44:45 +02:00
qo-op 2f5c7d87ce ~/.zen/ipfs/.$ipfsnodeid/G1SSB/_g1.cesium_name 2020-05-17 22:13:55 +02:00
qo-op 8f5a291eab Is "ipfs_swarm/.$id/G1SSB/_ssb.whoami" my SSB friend 2020-05-17 21:21:42 +02:00
qo-op 2d95af9ac0 Astroport datastructure check -> BAN peer 2020-05-17 21:15:35 +02:00
poka 63f5c5ef2b fix ipfs install 2020-05-17 20:59:34 +02:00
poka 1d74d8eb53 fix ipfs install 2020-05-17 20:57:41 +02:00
poka 9698f70ad8 fix ipfs install 2020-05-17 20:54:08 +02:00
poka 2bf7772c76 fix ipfs install 2020-05-17 20:53:07 +02:00
poka 09e8cca92c fix ipfs install 2020-05-17 20:48:50 +02:00
qo-op 6502cde0a0 brut nature 2020-05-17 20:37:49 +02:00
qo-op 48cfc30e9b brut nature 2020-05-17 20:19:32 +02:00
qo-op a0ea409d88 push 2020-05-17 20:18:09 +02:00
poka e45b6da1f1 Fix errors states of ipfs_alone install 2020-05-17 20:05:07 +02:00
poka 958b7183d7 Fix permission in .ipfs folder 2020-05-17 19:58:54 +02:00
poka c0886ef06f Fix install loading 2020-05-17 19:50:29 +02:00
poka d9f5c1a1ef Add Nextcloud flavour 2020-05-17 19:46:59 +02:00
qo-op bb6f39dbf4 ipfs.service template inside EOF (no more curl for it) 2020-05-17 12:04:05 +02:00
qo-op e74a76bfc8 isLAN 2020-05-17 11:56:39 +02:00
qo-op d283e2363d bonjour 2020-05-17 10:43:44 +02:00
qo-op 8d8814c416 DEV 2020-05-17 03:37:29 +02:00
poka 4ea5e78222 install lolcat 2020-05-16 21:22:04 +02:00
qo-op 0e31bf40c1 # [Open Collective DONATIONS](https://opencollective.com/monnaie-libre) 2020-05-16 17:07:43 +02:00
qo-op f43af98271 Devil/angel Game resolver 2020-05-16 16:59:49 +02:00
qo-op 6c789e8bcd Astroport Similar Organic Life Form : Blob creature 2020-05-16 16:54:34 +02:00
qo-op 26e1fb82cf chamalow onboarding 2020-05-16 16:52:35 +02:00
qo-op 80ec25371f Then A, B, C, D, E, F, G, H, I, J, K, ... and as much as it has to be can share knwowledge and tanforms (-) into (+) 2020-05-16 15:45:23 +02:00
qo-op a2450b8a96 protocol not defined yet 2020-05-16 15:43:28 +02:00
qo-op e0fd676523 Traduction GROgol 2020-05-16 15:36:14 +02:00
qo-op 8c65f05b6e (-) + (+) + (+) = (+) 2020-05-16 15:34:10 +02:00
qo-op 958194dfc2 translations 2020-05-16 15:30:51 +02:00
qo-op b347664a15 OASIS RULES 2020-05-16 15:28:00 +02:00
qo-op a1c6c12414 [Latest version HERE](https://git.p2p.legal/axiom-team/astroport/src/master/g1sms/Readme.md) 2020-05-16 15:26:01 +02:00
qo-op b36d9be460 To replace "\+33" whith "\+_YOUR_COUNTRY_CODE_", please run
grep -rl '\+33' ./  | xargs sed -i 's/\+33/\+_YOUR_COUNTRY_CODE_/g'
2020-05-16 15:22:05 +02:00
qo-op e38f6ce438 include important tools in ```/usr/local/bin``` for easy use from all system 2020-05-16 15:18:28 +02:00
qo-op fb2afd4cb2 🥕 2020-05-16 15:01:12 +02:00
qo-op b024d779df showme 2020-05-16 14:45:52 +02:00
qo-op 8eba0bae48 explanations 2020-05-16 14:39:04 +02:00
qo-op 5914cf2731 OASIS RULES 2020-05-16 14:30:19 +02:00
qo-op aeaf0f847f biologic 2020-05-16 06:30:33 +02:00
qo-op 168c9a2b12 TODO make gif tu push to SSB 2020-05-16 06:28:12 +02:00
qo-op cb63dfabc9 Blob 2020-05-16 06:22:44 +02:00
qo-op c051222145 http://localhost:10010 2020-05-16 06:19:08 +02:00
qo-op 18b0122fa4 # Blind Test
http://bafybeih7db77yipxh2rafynjj3dj262b2giuel4f52qq2ibvzhy3l2rvgu.ipfs.localhost:8080/rb4-oOKIZQ8.mp3

Could you listen to this track? HOURA!!!
Then your Astroport Station is active and is or have been connected to #Swarm0
2020-05-16 06:03:22 +02:00
qo-op 63b3673e6b nodename Core command used to find make http://$NODENAME:10010 Portal 2020-05-16 05:29:15 +02:00
qo-op e52bccb7ef add your flavour to the Astroport. 2020-05-16 05:27:31 +02:00
qo-op 6c9052b8bf Zicmama Layer 2020-05-16 04:48:11 +02:00
qo-op ac2b9d5436 MIZ quality OK 2020-05-16 04:38:04 +02:00
qo-op 9a7cad52c5 microservice ready 2020-05-16 04:37:10 +02:00
2103 changed files with 121486 additions and 2300 deletions

4
.gitignore vendored
View File

@ -1,2 +1,6 @@
.profile
www/LOVELand/jukebox/prefs
www/LOVELand/jukebox/albumart
www/LOVELand/g1barre/img/qrcodes
zen/tools/scraping/transiscope/transiscope.json
zen/tools/__pycache__

View File

@ -0,0 +1,9 @@
[Desktop Entry]
Type=Application
Exec=~/.zen/astroport/1stRUNconfig.sh
X-GNOME-Autostart-enabled=true
NoDisplay=false
Hidden=false
Name[fr_FR]=Astroport_X_config.desktop
Comment[fr_FR]=First time RUN config script
X-GNOME-Autostart-Delay=0

File diff suppressed because it is too large Load Diff

View File

@ -1,6 +1,6 @@
#!/bin/bash
[[ -f ~/.bash_aliases && ! -z $(cat ~/.bash_aliases | grep c_red) ]] && exit 1
[[ -f ~/.bash_aliases && ! -z $(cat ~/.bash_aliases | grep c_red) ]] && exit 0
echo 'export c_blinkfast="\033[6m"
export c_light="\033[1m"

136
.install/ipfs_alone.sh Normal file → Executable file
View File

@ -5,16 +5,6 @@ MY_PATH="`dirname \"$0\"`" # relative
MY_PATH="`( cd \"$MY_PATH\" && pwd )`" # absolutized and normalized
ME="${0##*/}"
# Ask user password on start
sudo true
# CHECK if daemon is already running
[[ $(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1) ]] \
&& echo "ipfs daemon already running. EVERYTHING OK!" \
&& ipfs id && echo "ipfs swarm peers" && ipfs swarm peers \
&& echo "ipfs bootstrap list" && ipfs bootstrap list \
&& echo "Please RUN : sudo systemctl stop ipfs" && exit 0
# CHECK not root user !!
if [ "$EUID" -eq 0 ]
then echo -e "${c_red}DO NOT EXECUTE AS root. Choose a user for your Astroport Station (we like pi)$c_"
@ -22,58 +12,126 @@ if [ "$EUID" -eq 0 ]
else echo -e "${c_yellow}OK $USER, let's go!$c_";
fi
[[ -d ~/.ipfs ]] && echo "IPFS install exist, please remove backup before execute this script" && exit 1
# Ask user password on start
sudo true
echo -e "${c_yellow}Onboarding IPFS...$c_"
## Error funciton
err() {
echo -e "${c_red}$1$c_"
exit 1
}
# CHECK if daemon is already running
if [[ $(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1) ]]; then
echo "ipfs daemon already running...! Must STOP ipfs AND remove ~/.ipfs to install again !!"
ipfs id && echo "ipfs swarm peers: " && ipfs swarm peers
echo "ipfs bootstrap list: " && ipfs bootstrap list
echo "Please RUN : sudo systemctl stop ipfs"
exit 1
fi
[[ -d ~/.ipfs ]] && echo "IPFS install exist! Please remove or backup before executing this script" && exit 1
echo -e "${c_yellow}Astroport IPFS Layer installation...$c_"
# CHECK node IP isLAN?
myIP=$(hostname -I | awk '{print $1}')
isLAN=$(echo $myIP | grep -E "/(^127\.)|(^192\.168\.)|(^10\.)|(^172\.1[6-9]\.)|(^172\.2[0-9]\.)|(^172\.3[0-1]\.)|(^::1$)|(^[fF][cCdD])/")
MACHINE_TYPE=`uname -m`
[ ${MACHINE_TYPE} == 'x86_64' ] && curl -s https://dist.ipfs.io/ipfs-update/v1.5.2/ipfs-update_v1.5.2_linux-amd64.tar.gz -o $MY_PATH/ipfs-update.tar.gz || err+="Download ipfs-update"
[ ${MACHINE_TYPE:0:3} == 'arm' ] && curl -s https://dist.ipfs.io/ipfs-update/v1.5.2/ipfs-update_v1.5.2_linux-arm.tar.gz -o $MY_PATH/ipfs-update.tar.gz || err+="Download ipfs-update"
[ ! -f $MY_PATH/ipfs-update.tar.gz ] && echo "Your $MACHINE_TYPE is not supported yet... Please add an issue." && exit 1
echo "INSTALL ipfs-update"
sudo tar -xvzf $MY_PATH/ipfs-update.tar.gz -C /usr/src/ || err+="Untar ipfs-update"
if [ ${MACHINE_TYPE} == 'x86_64' ]; then
curl -s https://dist.ipfs.io/ipfs-update/v1.6.0/ipfs-update_v1.6.0_linux-amd64.tar.gz -o $MY_PATH/ipfs-update.tar.gz
elif [ ${MACHINE_TYPE:0:3} == 'arm' ]; then
curl -s https://dist.ipfs.io/ipfs-update/v1.6.0/ipfs-update_v1.6.0_linux-arm.tar.gz -o $MY_PATH/ipfs-update.tar.gz
else
[ ! -f $MY_PATH/ipfs-update.tar.gz ] && err "Your $MACHINE_TYPE is not supported yet... Please add an issue."
fi
echo "INSTALL ipfs-update >>>>>>>>>>>>>>>>>>>>>>>>>>"
sudo tar -xvzf $MY_PATH/ipfs-update.tar.gz -C /usr/src/ || err "Untar ipfs-update"
rm $MY_PATH/ipfs-update.tar.gz
cd /usr/src/ipfs-update/
sudo ./install.sh || err+="Install ipfs-update"
sudo ./install.sh || err "Install ipfs-update"
cd $MY_PATH
echo "INSTALL latest ipfs"
sudo ipfs-update install latest || err+="Install IPFS"
echo "INSTALL ipfs 0.7.0 >>>>>>>>>>>>>>>>>>>>>>>>>>"
sudo ipfs-update install 0.7.0 || err "Install IPFS"
## DEBIAN
echo "CREATE SYSTEMD ipfs SERVICE >>>>>>>>>>>>>>>>>>"
cat > /tmp/ipfs.service <<EOF
[Unit]
Description=IPFS daemon
After=network.target
[Service]
User=_USER_
ExecStart=/usr/local/bin/ipfs daemon --enable-pubsub-experiment --enable-namesys-pubsub --enable-gc
Restart=on-failure
[Install]
WantedBy=multi-user.target
EOF
echo "CREATE SYSTEMD ipfs SERVICE"
curl -s https://git.p2p.legal/axiom-team/astroport/raw/master/.install/templates/ipfs/ipfs.service -o /tmp/ipfs.service
sudo cp -f /tmp/ipfs.service /etc/systemd/system/
sudo sed -i "s/_USER/$USER/g" /etc/systemd/system/ipfs.service
sudo systemctl daemon-reload || err+="Restart IPFS"
sudo systemctl enable ipfs || err+="Enable IPFS daemon"
sudo sed -i "s/_USER_/$USER/g" /etc/systemd/system/ipfs.service
[[ -d ~/.ipfs ]] && sudo chown -R $USER:$USER ~/.ipfs
## Special Xbian init.d config
if [[ $USER == "xbian" && -f ~/.zen/astroport/.install/templates/ipfs/ipfs-initV.sh ]]; then
sudo cp ~/.zen/astroport/.install/templates/ipfs/ipfs-initV.sh /etc/init.d/ipfs
sudo chmod 755 /etc/init.d/ipfs
sudo touch /var/log/ipfs.log && sudo chown xbian /var/log/ipfs.log
sudo service ipfs enable
else
sudo systemctl daemon-reload || err "Restart IPFS"
sudo systemctl enable ipfs || err "Enable IPFS daemon"
fi
# INIT ipfs
ipfs init -p lowpower || exit 1
# ipfs init -p server ## Uncomment for server infrastructure
[[ $isLAN ]] && ipfs init -p lowpower \
|| ipfs init -p server
# TODO try ipfs init --profile=badgerds (for better performance)
# https://discuss.ipfs.io/t/adding-content-to-ipfs-is-quite-slow-any-ideas-on-why-and-how-to-speed-things-up/8135/3
sudo chown -R $USER:$USER ~/.ipfs || exit 1
# ACTIVATE CONFIG OPTIONS
# PUBSUB
###########################################
# ACTIVATE IPFS OPTIONS: #swarm0 INIT
###########################################
### IMPORTANT !!!!!!! IMPORTANT !!!!!!
###########################################
# DHT PUBSUB mode
ipfs config Pubsub.Router gossipsub
# MAXSTORAGE
# MAXSTORAGE = 1/2 available
availableDiskSize=$(df -P ~/ | awk 'NR>1{sum+=$4}END{print sum}')
diskSize="$((availableDiskSize / 2))"
ipfs config Datastore.StorageMax $diskSize
## PORT FORWARD (SSH)
## Activate Rapid "ipfs p2p"
ipfs config --json Experimental.Libp2pStreamMounting true
ipfs config --json Experimental.P2pHttpProxy true
######### UPDATE BOOTSTRAP LIST ###########
######### MAKE DEFAULT BOOTSTRAP TO oasis.astroport.com 2jQUH4HfHxdTesjCjvMCx1VJgA5AnpuvrWRq1swfRdsS ###########
ipfs bootstrap rm --all
ipfs bootstrap add /dnsaddr/rec.copylaradio.com/tcp/4001/ipfs/Qmb6Gyy3KFWTxWh4v6fBeh5ANxAF6YAahWQtokmsNsqGda
ipfs bootstrap add /ip4/51.15.166.54/tcp/4001/p2p/Qmb6Gyy3KFWTxWh4v6fBeh5ANxAF6YAahWQtokmsNsqGda
ipfs bootstrap add /ip6/fd42:feed:feed:feed::1/tcp/4001/p2p/Qmb6Gyy3KFWTxWh4v6fBeh5ANxAF6YAahWQtokmsNsqGda
ipfs bootstrap add /dnsaddr/oasis.astroport.com/tcp/4001/ipfs/12D3KooWBYme2BsNUrtx4mEdNX6Yioa9AV7opWzQp6nrPs6ZKabN
ipfs bootstrap add /ip4/51.15.166.54/tcp/4001/p2p/12D3KooWBYme2BsNUrtx4mEdNX6Yioa9AV7opWzQp6nrPs6ZKabN
ipfs bootstrap add /ip4/51.15.166.54/udp/4001/quic/p2p/12D3KooWBYme2BsNUrtx4mEdNX6Yioa9AV7opWzQp6nrPs6ZKabN
ipfs bootstrap add /ip6/fe80::208:a2ff:fe0c:20d8/tcp/4001/p2p/12D3KooWBYme2BsNUrtx4mEdNX6Yioa9AV7opWzQp6nrPs6ZKabN
###########################################
# TODO: ADD some other bootstrap NODES
###########################################
sudo systemctl restart ipfs || err+="Restart IPFS daemon"
sudo systemctl start ipfs || err "Start IPFS daemon"
sleep 10
sleep 3
[[ ! $(ipfs swarm peers) ]] && echo "${c_red}No peers found in swarm. Please open issue :https://git.p2p.legal/axiom-team/astroport/issues" && exit 1
echo "Peers: " && ipfs swarm peers && sleep 0.3
#[[ ! $(ipfs swarm peers) =~ "/ip4/" ]] && err "No peers found in swarm. Please open issue :https://git.p2p.legal/axiom-team/astroport/issues"
} # this ensures the entire script is downloaded #
# IPFS CONFIG documentation: https://github.com/ipfs/go-ipfs/blob/master/docs/config.md#addressesswarm

Binary file not shown.

Binary file not shown.

View File

@ -8,23 +8,34 @@
MY_PATH="`dirname \"$0\"`" # relative
MY_PATH="`( cd \"$MY_PATH\" && pwd )`" # absolutized and normalized
ME="${0##*/}"
########################################################################
YOU=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1) || er+=" ipfs daemon not running"
IPFSNODEID=$(ipfs id -f='<id>\n') || er+=" ipfs id problem"
WHOAMI=$(sbotc whoami | jq -r .id) || er+=" sbotc whoami problem"
[[ "$YOU" == "" || "$IPFSNODEID" == "" || "$WHOAMI" == "" ]] && echo "ERROR : $er " && exit 1
########################################################################
#### DO NOT RUN AS ROOT
[[ $USER == "root" ]] && echo "DO NOT RUN AS root!! Use regular USER with sudo AUTHORISATION" && exit 1
#### APACHE NOT SUPPORTED
is_apache_running=$(ps auxf --sort=+utime | grep -w apache | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1);
[[ $is_apache_running ]] && echo "SORRY ONLY nginx is supported. EXIT" && exit 1
#### ARM / X64 NOT USED THERE
MACHINE_TYPE=`uname -m`
[ ${MACHINE_TYPE:0:3} == 'arm' ] && isARM="YES"
YOU=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1);
[[ ! $YOU ]] && echo "EXIT! PLEASE INSTALL & RUN ipfs daemon WITH curl -s https://git.p2p.legal/axiom-team/astroport/raw/master/.install/ipfs_alone.sh | bash " \
&& exit 1
IPFSNODEID=$(ipfs id -f='<id>\n')
### UPDATE apt cache
sudo apt-get update
### Adding YOU to www-data group
sudo adduser $YOU www-data
##################################
## INSTALL
## INSTALL RAINBOW ASCII ;)
[[ ! $(which figlet) ]] && sudo apt install figlet -y
[[ ! $(which lolcat) ]] && sudo apt install lolcat -y
echo '
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
______ __ ____ ___
/ ____/___ ____ __ __/ / ____ _/ __ \____ _____/ (_)___
/ / / __ \/ __ \/ / / / / / __ `/ /_/ / __ `/ __ / / __ \
@ -32,39 +43,41 @@ echo '
\____/\____/ .___/\__, /_____/\__,_/_/ |_|\__,_/\__,_/_/\____/
/_/ /____/
Multimedia Layer installation
'
######## YOUTUBE-DL ##########
if [[ ! $(which youtube-dl) ]]; then
sudo wget https://yt-dl.org/downloads/latest/youtube-dl -O /usr/local/bin/youtube-dl || exit 1
sudo chmod a+rx /usr/local/bin/youtube-dl
sudo chown $USER /usr/local/bin/youtube-dl
fi
# AUDIO LAYER
sudo apt-get update
sudo apt-get install libid3-tools mpd mpc lame -y || err=1
sudo apt-get install lame sox libsox-fmt-mp3 eyed3 python-chardet imagemagick curl -y #libav-tools || err=1
sudo apt-get install ca-certificates git-core binutils rsync alsa-utils bc espeak mpg321 fuse atomicparsley -y || err=1
## CONFIG MPD
sudo cp -f /home/$YOU/.zen/astroport/.install/templates/copylaradio/mpd.conf /etc/mpd.conf
sudo sed -i "s/_USER_/$USER/g" /etc/mpd.conf || err=1
mkdir ~/.config/mpd && sudo cp -f /etc/mpd.conf ~/.config/mpd/mpd.conf && sudo chown $USER ~/.config/mpd/mpd.conf
Multimedia Layer (https://www.copylaradio.com)
' | lolcat
## MULTIMEDIA
## VIDEO & AUDIO & PLAYLISTS ~/.zen/ DIR
mkdir -p ~/.zen/video
mkdir -p ~/.zen/audio
mkdir -p ~/.zen/playlists
## CHOWN mpd FILES STRUCTURE (
echo "TODO: CHECK if mpd start after a reboot !!"
sudo chown -R $USER /var/lib/mpd/ /var/run/mpd /run/mpd /var/log/mpd
sudo service mpd restart || err=1
## TODO add to system start (/etc/rc.local?)
######## YOUTUBE-DL ##########
if [[ ! $(which youtube-dl) ]]; then
sudo wget https://yt-dl.org/downloads/latest/youtube-dl -O /usr/local/bin/youtube-dl || err=1
sudo chmod a+rx /usr/local/bin/youtube-dl
sudo chown $YOU /usr/local/bin/youtube-dl
fi
###############################
# MPD/MPC RompR AUDIO LAYER
###############################
if [[ ! $(which mpd) ]]; then
sudo apt-get install libid3-tools mpd mpc lame ffmpeg lsof lltag inotify-tools bc -y || err=1
sudo apt-get install lame sox libsox-fmt-mp3 eyed3 python-chardet imagemagick curl -y || err=1 #libav-tools unavailable on some system
sudo apt-get install ca-certificates git-core binutils rsync alsa-utils bc espeak mpg321 fuse atomicparsley -y || err=1
## CONFIG MPD
sudo cp -f /home/$YOU/.zen/astroport/.install/templates/copylaradio/mpd.conf /etc/mpd.conf
sudo sed -i "s/_USER_/$YOU/g" /etc/mpd.conf || err=1
mkdir ~/.config/mpd && sudo cp -f /etc/mpd.conf ~/.config/mpd/mpd.conf && sudo chown $YOU ~/.config/mpd/mpd.conf
## CHOWN mpd FILES STRUCTURE
sudo chown -R $YOU /var/lib/mpd/ /var/run/mpd /run/mpd /var/log/mpd
sudo service mpd restart || err=1
fi
### INSTALL NGINX
echo '
echo '++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
_
____ ____ _(_)___ _ __
/ __ \/ __ `/ / __ \| |/_/
@ -72,42 +85,14 @@ echo '
/_/ /_/\__, /_/_/ /_/_/|_|
/____/
'
install
' | lolcat
sudo apt-get install fail2ban nginx ssl-cert php-curl php-sqlite3 php-gd php-json php-xml php-mbstring php-fpm sqlite -y || err=1
# CONFIG NGINX - LOVE LAND FRONTAL WEB PAGE
sudo cp -f /home/$YOU/.zen/astroport/www/loveland.conf /etc/nginx/conf.d/
PHPVERSION=$(ps auxf | grep php-fpm | grep -v -E 'color=auto|grep' | head -n 1 | grep -oP '(?<=\().*(?=\))' | awk -F '/' '{print $4}')
sudo sed -i "s/_PHPVERSION_/$PHPVERSION/g" /etc/nginx/conf.d/loveland.conf
nodename=$(cat /etc/hostname)
echo "ENTER Station accessible Network name !!! Suggestion : $nodename"
read nodename
[[ $nodename == "" ]] && echo "Are you sure? Hit ENTER to keep $nodename)" && read nodename
[[ $nodename == "" ]] && nodename=$(cat /etc/hostname)
sudo sed -i "s/_SERVERNAME_/$nodename/g" /etc/nginx/conf.d/loveland.conf
echo "INSTALL LOVELand WebSite"
if [[ ! -L /var/www/loveland ]]; then
sudo ln -s /home/$YOU/.zen/astroport/www/LOVELand /var/www/loveland
fi
sudo chmod -R 777 /var/www/loveland/jukebox/albumart
sudo chmod -R 777 /var/www/loveland/jukebox/prefs
# Disabling default website
sudo rm -f /etc/nginx/sites-enabled/default
sudo systemctl restart nginx || err=1
# KILL RUNNING OASIS
kill -9 $(ps auxf --sort=+utime | grep -w oasis | grep -v -E 'color=auto|grep' | tail -n 1 | awk '{print $2}')
echo "REstarting OASIS with good $nodename & network config"
[[ ! $(which nslookup) ]] && sudo apt-get install lolcat dnsutils -y
echo '
echo '++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
__ ___ _ ___
/ |/ /_ __ ____ ____ _____ ___ ___ (_)___/__ \
/ /|_/ / / / / / __ \/ __ `/ __ `__ \/ _ \ / / ___// _/
@ -116,37 +101,164 @@ echo '
/____/
' | lolcat
myip=$(hostname -I | awk '{print $1}')
# Check if IP is from reserved LAN addresses
isLAN=$(echo $myip | grep -E "/(^127\.)|(^192\.168\.)|(^10\.)|(^172\.1[6-9]\.)|(^172\.2[0-9]\.)|(^172\.3[0-1]\.)|(^::1$)|(^[fF][cCdD])/")
# Find 1st route gateway
myRouter=$(sudo route -n | head -n 3 | tail -n 1 | awk '{print $2}')
# Ask to the router its name (BOX DNS or system defined)
[[ $isLAN ]] && nodename=$(sudo nslookup $myip $myRouter | head -n 1 | awk -F ' = ' '{print $2}' | sed 's/\.[^.]*$//') \
|| nodename=$(sudo nslookup $myip | head -n 1 | awk -F ' = ' '{print $2}' | sed 's/\.[^.]*$//')
echo $nodename
myIP=$(hostname -I | awk '{print $1}' | head -n 1)
isLAN=$(echo $myIP | grep -E "/(^127\.)|(^192\.168\.)|(^10\.)|(^172\.1[6-9]\.)|(^172\.2[0-9]\.)|(^172\.3[0-1]\.)|(^::1$)|(^[fF][cCdD])/")
if [[ ! $isLAN ]]; then
oasis --allow-host $nodename 2>&1>/dev/null &
echo "BE CAREFULL your SSB identity could be publicly controled..."
echo "TODO correct 'Not Found' error (cors problem related)"
else
oasis --allow-host $nodename --host $nodename 2>&1>/dev/null &
# Ask to the router its name (BOX DNS or system defined)
[[ -f /home/$YOU/.zen/astroport/zen/tools/nodename ]] && NODENAME=$(/home/$YOU/.zen/astroport/zen/tools/nodename) \
|| NODENAME=$(curl -s https://git.p2p.legal/axiom-team/astroport/raw/master/zen/tools/nodename | bash) ## RUNNING ALONE !!
echo $NODENAME
######################################
### LAUNCHIN OASIS = SSB HTTP interface
######################################
echo '
_
____ ____ ______(_)____
/ __ \/ __ `/ ___/ / ___/
/ /_/ / /_/ (__ ) (__ )
\____/\__,_/____/_/____/
SSB DEMO HTTP interface
' | lolcat
# IN CASE, KILL RUNNING OASIS
isOASIS=$(ps auxf --sort=+utime | grep -w oasis | grep -v -E 'color=auto|grep' | tail -n 1 | awk '{print $2}')
[[ $isOASIS ]] && sudo kill -9 $isOASIS
echo "Starting OASIS with good $NODENAME & network config"
echo "TODO: add to your /etc/rc.local or systemd or initV !!!"
#if [[ ! $isLAN ]]; then
# ### TODO: unlock oasis restrictions!! CANNOT MAKE PRIVATE MESSAGE => Feddless.social CAN add it as module on loveland portal!!)
# oasis --allow-host $NODENAME --host $NODENAME --public 2>&1>/dev/null &
# echo "--public = OASIS STATION IS IN VIEWING MODE ONLY..."
#else
# oasis --allow-host $NODENAME --host $NODENAME 2>&1>/dev/null &
#fi
#sleep 5
echo '
__ ____ _ __________ __
/ / / __ \ | / / ____/ / ____ _____ ____/ /
/ / / / / / | / / __/ / / / __ `/ __ \/ __ /
/ /___/ /_/ /| |/ / /___/ /___/ /_/ / / / / /_/ /
/_____/\____/ |___/_____/_____/\__,_/_/ /_/\__,_/
Portal
' | lolcat
###
echo "INSTALL LOVELand WebSite. Linking to /var/www ..."
if [[ ! -L /var/www/loveland ]]; then
sudo ln -s /home/$YOU/.zen/astroport/www/LOVELand /var/www/loveland
fi
sleep 5
echo "JUKEBOX init"
[[ -d /var/www/loveland/jukebox/albumart ]] && sudo chmod -R 777 /var/www/loveland/jukebox/albumart
[[ -d /var/www/loveland/jukebox/prefs ]] && sudo chmod -R 777 /var/www/loveland/jukebox/prefs
[[ -d /var/www/loveland/g1barre/img/qrcodes ]] && sudo chmod -R 777 /var/www/loveland/g1barre/img/qrcodes
# CONFIG NGINX - LOVE LAND FRONTAL WEB PAGE
echo "$NODENAME" | figlet -f slant | lolcat
## Write NODENAME to IPFS
echo "$NODENAME" > /home/$YOU/.zen/ipfs/.$IPFSNODEID/G1SSB/_nodename
PHPVERSION=$(ps auxf | grep php-fpm | grep -v -E 'color=auto|grep' | head -n 1 | grep -oP '(?<=\().*(?=\))' | awk -F '/' '{print $4}')
### ASTROPORT STATION LOVELAND PORTAL
sudo sed "s/_PHPVERSION_/$PHPVERSION/g" /home/$YOU/.zen/astroport/www/loveland.conf > /tmp/loveland.conf
sudo sed -i "s/_MY_NODE_NAME_/$NODENAME/g" /tmp/loveland.conf
sudo sed -i "s/_PORT_/10010/g" /tmp/loveland.conf
sudo sed -i "s/_APPLI_//g" /tmp/loveland.conf
sudo cp -f /tmp/loveland.conf /etc/nginx/conf.d/loveland.conf
### GCHANGE G1 Zen
sudo rm -f /etc/nginx/conf.d/gchange.conf
sudo sed "s/_PHPVERSION_/$PHPVERSION/g" /home/$YOU/.zen/astroport/www/loveland.conf > /tmp/gchange.conf
sudo sed -i "s/_MY_NODE_NAME_/$NODENAME/g" /tmp/gchange.conf
sudo sed -i "s/_PORT_/10020/g" /tmp/gchange.conf
sudo sed -i "s/_APPLI_/gchange/g" /tmp/gchange.conf
sudo cp -f /tmp/gchange.conf /etc/nginx/conf.d/gchange.conf
### CESIUM G1 Zen
sudo sed "s/_PHPVERSION_/$PHPVERSION/g" /home/$YOU/.zen/astroport/www/loveland.conf > /tmp/cesium.conf
sudo sed -i "s/_MY_NODE_NAME_/$NODENAME/g" /tmp/cesium.conf
sudo sed -i "s/_PORT_/10030/g" /tmp/cesium.conf
sudo sed -i "s/_APPLI_/cesium/g" /tmp/cesium.conf
sudo cp -f /tmp/cesium.conf /etc/nginx/conf.d/cesium.conf
### JUKEBOX RompR CopyLaRadio
if [[ $(which mpd) ]]; then
sudo sed "s/_PHPVERSION_/$PHPVERSION/g" /home/$YOU/.zen/astroport/www/loveland.conf > /tmp/jukebox.conf
sudo sed -i "s/_MY_NODE_NAME_/$NODENAME/g" /tmp/jukebox.conf
sudo sed -i "s/_PORT_/10011/g" /tmp/jukebox.conf
sudo sed -i "s/_APPLI_/jukebox/g" /tmp/jukebox.conf
sudo cp -f /tmp/jukebox.conf /etc/nginx/conf.d/jukebox.conf
fi
### SSB OASIS Zen (PROXY MODE 10040 -> 3000)
if [[ $(which oasis) ]]; then
sudo sed "s/_MY_NODE_NAME_/$NODENAME/g" /home/$YOU/.zen/astroport/www/oasis.conf > /tmp/oasis.conf
sudo sed -i "s/_PORT_/10040/g" /tmp/oasis.conf
sudo sed -i "s/_LHOST_/$NODENAME:3000/g" /tmp/oasis.conf
sudo sed -i "s/_APPLI_//g" /tmp/oasis.conf
sudo cp -f /tmp/oasis.conf /etc/nginx/conf.d/oasis.conf
# TRICK: COULD BE USED TO ADD .htpasswod ACCESS CONTROL AND REMOVE --public
# TODO use "ipfs p2p" to AGREGATE ALL OASIS on ONE (not ALL like G1SMS) ?
# NEED G1PUB to be identified with same MEMBER owner in 'zen/ipfs_OPEN_ports.sh'?
fi
### G1SMS propagation to localhost:10099 / 10097 ("ipfs p2p" forwarded)
if [[ $(which gammu) ]]; then
# DIRECT MODE
sudo sed "s/_PHPVERSION_/$PHPVERSION/g" /home/$YOU/.zen/astroport/www/loveland.conf > /tmp/g1sms.conf
sudo sed -i "s/_MY_NODE_NAME_/$NODENAME/g" /tmp/g1sms.conf
sudo sed -i "s/_PORT_/10099/g" /tmp/g1sms.conf
sudo sed -i "s/_APPLI_/g1sms/g" /tmp/g1sms.conf
sudo cp -f /tmp/g1sms.conf /etc/nginx/conf.d/g1sms.conf
else
# PROXY MODE (10099 -> 10097) ### ipfs p2p PROPAGATION WITH 'zen/ipfs_OPEN_ports.sh'
sudo sed "s/_MY_NODE_NAME_/$NODENAME/g" /home/$YOU/.zen/astroport/www/oasis.conf > /tmp/g1sms_proxy.conf
sudo sed -i "s/_PORT_/10099/g" /tmp/g1sms_proxy.conf
sudo sed -i "s/_LHOST_/127\.0\.0\.1\:10097/g" /tmp/g1sms_proxy.conf
sudo sed -i "s/_APPLI_/g1sms/g" /tmp/g1sms_proxy.conf
sudo cp -f /tmp/g1sms_proxy.conf /etc/nginx/conf.d/g1sms_proxy.conf
fi
##### RESTART NGINX
sudo systemctl restart nginx || err=1
if [[ $err ]]; then
echo -e "${c_red}Installation de LOVELand bizarre??$c_"
echo "PLEASE... POST YOUR ISSUE! https://git.p2p.legal/axiom-team/astroport/issues"
exit 1
else
echo -e "${c_green}LOVE Land a été installé avec succès$c_"
echo "LoveLand Portal link http://$nodename (TRY ME)
Add ScuttleButt Astroport PUB Invitation in http://$nodename:3000/settings
oasis.astroport.com:8008::@UeiA9iqZ0/XTjmYBht230KGr44bsr+Tl5BXSUDFv8vo=.ed25519~jd9Z4y/d/xZCF7bfuSgQSiSGLMeWFhwMosKUFhFxeEY="
exit 0
echo -e "LoveLand Portal link http://$NODENAME:10010 (TRY ME)
Add ScuttleButt Astroport PUB Invitation:
${c_green}With Patchwork: "Join a server"$c_
Or with Oasis: http://$NODENAME:3000/settings (dev mode, still buggy)
${c_light}oasis.astroport.com:8008::@UeiA9iqZ0/XTjmYBht230KGr44bsr+Tl5BXSUDFv8vo=.ed25519~jd9Z4y/d/xZCF7bfuSgQSiSGLMeWFhwMosKUFhFxeEY=" $c_
fi
# Open LOVEland in browser
URL="http://$NODENAME"
path=$(which xdg-open || which gnome-open)
xo ()
{
for var in "$@"; do
$path "$var";
sleep 0.5
done
}
[[ -n $path ]] && xo $URL:10010 $URL:10020 $URL:10030 > /dev/null
} # for script being completely downloaded before run

188
.install/mpd_rompr.sh Executable file
View File

@ -0,0 +1,188 @@
#!/bin/bash
########################################################################
# Author: Fred (support@qo-op.com)
# Version: 0.3
# License: AGPL-3.0 (https://choosealicense.com/licenses/agpl-3.0/)
########################################################################
{
MY_PATH="`dirname \"$0\"`" # relative
MY_PATH="`( cd \"$MY_PATH\" && pwd )`" # absolutized and normalized
ME="${0##*/}"
########################################################################
YOU=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1) || er+=" ipfs daemon not running"
IPFSNODEID=$(ipfs id -f='<id>\n') || er+=" ipfs id problem"
WHOAMI=$(sbotc whoami | jq -r .id) || er+=" sbotc whoami problem"
[[ "$YOU" == "" || "$IPFSNODEID" == "" || "$WHOAMI" == "" ]] && echo "ERROR : $er " && exit 1
########################################################################
#### DO NOT RUN AS ROOT
[[ $USER == "root" ]] && echo "DO NOT RUN AS root!! Use regular USER with sudo AUTHORISATION" && exit 1
#### APACHE NOT SUPPORTED
is_apache_running=$(ps auxf --sort=+utime | grep -w apache | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1);
[[ $is_apache_running ]] && echo "SORRY ONLY nginx is supported. EXIT" && exit 1
#### ARM / X64 NOT USED THERE
MACHINE_TYPE=`uname -m`
[ ${MACHINE_TYPE:0:3} == 'arm' ] && isARM="YES"
### UPDATE apt cache
sudo apt-get update
### Adding YOU to www-data group
sudo adduser $YOU www-data
##################################
## INSTALL RAINBOW ASCII ;)
[[ ! $(which figlet) ]] && sudo apt install figlet -y
[[ ! $(which lolcat) ]] && sudo apt install lolcat -y
echo '
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
______ __ ____ ___
/ ____/___ ____ __ __/ / ____ _/ __ \____ _____/ (_)___
/ / / __ \/ __ \/ / / / / / __ `/ /_/ / __ `/ __ / / __ \
/ /___/ /_/ / /_/ / /_/ / /___/ /_/ / _, _/ /_/ / /_/ / / /_/ /
\____/\____/ .___/\__, /_____/\__,_/_/ |_|\__,_/\__,_/_/\____/
/_/ /____/
Multimedia Layer (https://www.copylaradio.com)
' | lolcat
## MULTIMEDIA
## VIDEO & AUDIO & PLAYLISTS ~/.zen/ DIR
mkdir -p ~/astroport/films
mkdir -p ~/astroport/animes
mkdir -p ~/astroport/series
mkdir -p ~/astroport/docus
mkdir -p ~/astroport/musiques
mkdir -p ~/.zen/video
mkdir -p ~/.zen/audio
mkdir -p ~/.zen/playlists
######## YOUTUBE-DL ##########
if [[ ! $(which youtube-dl) ]]; then
sudo wget https://yt-dl.org/downloads/latest/youtube-dl -O /usr/local/bin/youtube-dl || err=1
sudo chmod a+rx /usr/local/bin/youtube-dl
sudo chown $YOU /usr/local/bin/youtube-dl
fi
###############################
# MPD/MPC RompR AUDIO LAYER
###############################
if [[ ! $(which mpd) ]]; then
sudo apt-get install libid3-tools mpd mpc lame ffmpeg lsof lltag inotify-tools bc -y || err=1
sudo apt-get install lame sox libsox-fmt-mp3 eyed3 python-chardet imagemagick curl -y || err=1 #libav-tools unavailable on some system
sudo apt-get install ca-certificates git-core binutils rsync alsa-utils bc espeak mpg321 fuse atomicparsley -y || err=1
## CONFIG MPD
sudo cp -f /home/$YOU/.zen/astroport/.install/templates/copylaradio/mpd.conf /etc/mpd.conf
sudo sed -i "s/_USER_/$YOU/g" /etc/mpd.conf || err=1
mkdir ~/.config/mpd && sudo cp -f /etc/mpd.conf ~/.config/mpd/mpd.conf && sudo chown $YOU ~/.config/mpd/mpd.conf
## CHOWN mpd FILES STRUCTURE
sudo chown -R $YOU /var/lib/mpd/ /var/run/mpd /run/mpd /var/log/mpd
sudo service mpd restart || err=1
fi
### INSTALL NGINX
echo '++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
_
____ ____ _(_)___ _ __
/ __ \/ __ `/ / __ \| |/_/
/ / / / /_/ / / / / /> <
/_/ /_/\__, /_/_/ /_/_/|_|
/____/
install
' | lolcat
sudo apt-get install fail2ban nginx ssl-cert php-curl php-sqlite3 php-gd php-json php-xml php-mbstring php-fpm sqlite -y || err=1
[[ ! $(which nslookup) ]] && sudo apt-get install lolcat dnsutils -y
echo '++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
__ ___ _ ___
/ |/ /_ __ ____ ____ _____ ___ ___ (_)___/__ \
/ /|_/ / / / / / __ \/ __ `/ __ `__ \/ _ \ / / ___// _/
/ / / / /_/ / / / / / /_/ / / / / / / __/ / (__ )/_/
/_/ /_/\__, / /_/ /_/\__,_/_/ /_/ /_/\___/ /_/____/(_)
/____/
' | lolcat
myIP=$(hostname -I | awk '{print $1}' | head -n 1)
isLAN=$(echo $myIP | grep -E "/(^127\.)|(^192\.168\.)|(^10\.)|(^172\.1[6-9]\.)|(^172\.2[0-9]\.)|(^172\.3[0-1]\.)|(^::1$)|(^[fF][cCdD])/")
# Ask to the router its name (BOX DNS or system defined)
[[ -f /home/$YOU/.zen/astroport/zen/tools/nodename ]] && NODENAME=$(/home/$YOU/.zen/astroport/zen/tools/nodename) \
|| NODENAME=$(curl -s https://git.p2p.legal/axiom-team/astroport/raw/master/zen/tools/nodename | bash) ## RUNNING ALONE !!
echo $NODENAME
echo '
__ ____ _ __________ __
/ / / __ \ | / / ____/ / ____ _____ ____/ /
/ / / / / / | / / __/ / / / __ `/ __ \/ __ /
/ /___/ /_/ /| |/ / /___/ /___/ /_/ / / / / /_/ /
/_____/\____/ |___/_____/_____/\__,_/_/ /_/\__,_/
Portal
' | lolcat
###
echo "INSTALL LOVELand WebSite. Linking to /var/www ..."
if [[ ! -L /var/www/loveland ]]; then
sudo ln -s /home/$YOU/.zen/astroport/www/LOVELand /var/www/loveland
fi
echo "JUKEBOX init"
[[ -d /var/www/loveland/jukebox/albumart ]] && sudo chmod -R 777 /var/www/loveland/jukebox/albumart
[[ -d /var/www/loveland/jukebox/prefs ]] && sudo chmod -R 777 /var/www/loveland/jukebox/prefs
[[ -d /var/www/loveland/g1barre/img/qrcodes ]] && sudo chmod -R 777 /var/www/loveland/g1barre/img/qrcodes
# CONFIG NGINX - LOVE LAND FRONTAL WEB PAGE
echo "$NODENAME" | figlet -f slant | lolcat
## Write NODENAME to IPFS
echo "$NODENAME" > /home/$YOU/.zen/ipfs/.$IPFSNODEID/G1SSB/_nodename
PHPVERSION=$(ps auxf | grep php-fpm | grep -v -E 'color=auto|grep' | head -n 1 | grep -oP '(?<=\().*(?=\))' | awk -F '/' '{print $4}')
### JUKEBOX RompR CopyLaRadio
if [[ $(which mpd) ]]; then
sudo sed "s/_PHPVERSION_/$PHPVERSION/g" /home/$YOU/.zen/astroport/www/loveland.conf > /tmp/jukebox.conf
sudo sed -i "s/_MY_NODE_NAME_/$NODENAME/g" /tmp/jukebox.conf
sudo sed -i "s/_PORT_/80/g" /tmp/jukebox.conf
sudo sed -i "s/_APPLI_/jukebox/g" /tmp/jukebox.conf
sudo cp -f /tmp/jukebox.conf /etc/nginx/conf.d/jukebox.conf
fi
##### RESTART NGINX
sudo systemctl restart nginx || err=1
if [[ $err ]]; then
echo -e "${c_red}Installation de bizarre??$c_"
echo "PLEASE... POST YOUR ISSUE! https://git.p2p.legal/axiom-team/astroport/issues"
exit 1
else
echo -e "${c_green}Installation réalisée avec succès$c_"
echo -e "Astroport JUKEBOX http://$NODENAME (TRY ME)"
fi
# Open in browser
URL="http://$NODENAME"
path=$(which xdg-open || which gnome-open)
xo ()
{
for var in "$@"; do
$path "$var";
sleep 0.5
done
}
[[ -n $path ]] && xo $URL:80 > /dev/null
} # for script being completely downloaded before run

View File

@ -0,0 +1,35 @@
# Automatic install of Nextcloud on Debian 8/9/10
## Use
Set good variables for your use case at the beginning of install.sh:
```
nc_domain="" # Votre nom de domaine pour votre nextcloud. Si vide il prendra le premier argument que vous passerez, sinon le hostname de votre machine
nc_port=80 # Numéro de port d'écoute de nginx
admin_user="admin" # Le pseudo du compte admin
admin_pass="admin" # Le mot de passe que vous désirez pour le compte admin
db_pass="" # Le mot de passe que vous désirez pour MariaDB. Si vide, un mot de passe aléatoire sécurisé sera choisi
isSSL=false # true si nextcloud et nginx doivent être configuré en https
configMaria=auto # Mettez manual ou auto, attention auto est expérimental et vraiment pas recommendé
p2env=false # true si vous êtes dans un environnement p2p.legal
```
Then:
```
chmod u+x install.sh
./install.sh
```
You can change the ssl state of your instance after the installation if you need.
Just execute ssl.sh:
`./ssl.sh`
If you prefere, you can download this script directly via:
```
wget https://dev-nextcloud.p2p.legal/installeur/install-nextcloud.tar.gz
tar -zxvf install-nextcloud.tar.gz
./install.sh 2>&1 | tee loginstall.log
```

186
.install/nextcloud/install.sh Executable file
View File

@ -0,0 +1,186 @@
#!/bin/bash
################################################################################
# Author: poka (poka@p2p.legal)
# Version: 0.1
# License: AGPL-3.0 (https://choosealicense.com/licenses/agpl-3.0/)
################################################################################
### Variables ###
nc_domain="" # Votre nom de domaine pour votre nextcloud. Si vide il prendra le premier argument que vous passerez, sinon le hostname de votre machine
nc_port=10050 # Numéro de port d'écoute de nginx
YOU=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1)
admin_user="$YOU" # Le pseudo du compte admin
admin_pass="0penS0urce!" # Le mot de passe que vous désirez pour le compte admin
db_pass="" # Le mot de passe que vous désirez pour MariaDB. Si vide, un mot de passe aléatoire sécurisé sera choisi
data_dir="/home/$YOU/.zen/nextcloud" # Le répertoir data de nextcloud, toutes les données utilisateurs s'y trouvent
isSSL=false # true si nextcloud et nginx doivent être configuré en https
configMaria=auto # Mettez manual ou auto, attention auto est expérimental et vraiment pas recommendé
p2env=false # true si vous êtes dans un environnement p2p.legal
#################
if [ "$EUID" -ne 0 ]
then echo -e "${c_red}Veuillez executez ce script en root$c_"
exit 1
fi
## Atroport config
echo -e "${c_yellow}Getting local hostname...$c_"
nc_domain=$(/home/$YOU/.zen/astroport/zen/tools/nodename)
templates="/home/$YOU/.zen/astroport/.install/nextcloud/templates"
## Set var
[[ -z $nc_domain ]] && nc_domain=$1
[[ -z $nc_domain ]] && nc_domain=$(echo $HOSTNAME.p2p.legal)
[[ -z $db_pass ]] && db_pass="$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1)" && echo "Votre mot de passe mysql nextcloud est : $db_pass" >> /root/nextcloud_mysql_pwd.txt
db_pass_root="$(cat /dev/urandom | tr -dc 'a-zA-Z0-9~!@#$%^&*_-' | fold -w 32 | head -n 1)"
if [[ p2env == "true" ]]; then
cd /nextcloud/templates/
else
[[ ! -e $templates ]] && echo -e "${c_red}Erreur: Le dossier templates n'existe pas, installation impossible.$c_" && exit 1
cd $templates
fi
## Update system packages
apt install -y lsb-release apt-transport-https ca-certificates
apt update -y
apt install nginx mariadb-server apt-transport-https curl gnupg2 git lsb-release ssl-cert ca-certificates apt-transport-https tree locate software-properties-common dirmngr screen htop net-tools zip unzip curl ffmpeg ghostscript libfile-fcntllock-perl -y
systemctl start nginx || (echo -e "${c_red}Erreur quelque part ...$c_" && exit 1)
systemctl start mariadb || (echo -e "${c_red}Erreur quelque part ...$c_" && exit 1)
systemctl enable mariadb || (echo -e "${c_red}Erreur quelque part ...$c_" && exit 1)
systemctl enable nginx || (echo -e "${c_red}Erreur quelque part ...$c_" && exit 1)
echo -e "${c_yellow} === Installing php ... ===$c_"
apt install php php-fpm php-xml php-curl php-gd php php-cgi php-cli php-zip php-mysql php-mbstring php-intl php-json php-bz2 php-ldap php-apcu imagemagick php-imagick php-smbclient -y
export PHPVERSION=$(ps auxf | grep php-fpm | grep -v -E 'color=auto|grep' | head -n 1 | grep -oP '(?<=\().*(?=\))' | awk -F '/' '{print $4}')
echo -e "${c_yellow} === Configuring php ... ===$c_"
[[ ! -e /etc/php/$PHPVERSION/cli/php.ini.bak ]] && (bash configure_php.sh || (echo -e "${c_red}Erreur quelque part ...$c_" && exit 1)) || echo "PHP déjà configuré, skip"
echo -e "${c_yellow} === Configure MariaDB ===$c_"
configMariaManual() {
mysql_secure_installation || (echo -e "${c_red}Erreur quelque part ...$c_" && exit 1)
}
configMariaAuto() {
mysql -e "UPDATE mysql.user SET Password = PASSWORD('$db_pass_root') WHERE User = 'root'"
isLocalhostUsers=$(mysql -e "select user from mysql.user;" | grep "localhost")
isTestDB=$(mysql -e "show databases" | grep "test")
[[ -n $isLocalhostUsers ]] && mysql -e "DROP USER ''@'localhost'; DROP USER ''@'$(hostname)'"
[[ -n $isTestDB ]] && mysql -e "DROP DATABASE test"
mysql -e "FLUSH PRIVILEGES"
}
[[ $configMaria == "auto" ]] && configMariaAuto || configMariaManual
[[ ! -e /etc/mysql/my.cnf.bak ]] && (mv /etc/mysql/my.cnf /etc/mysql/my.cnf.bak && cp my.cnf /etc/mysql/ && service mysql restart) || echo "MariaDB déjà configuré, skip"
echo -e "${c_yellow} === Create and configure database... ===$c_"
isDBCreate=$(mysql -e "show databases" | grep "nextcloud")
[[ -z $isDBCreate ]] && mysql -e "CREATE DATABASE nextcloud;CREATE USER 'nextcloud'@'localhost' IDENTIFIED BY \"$db_pass\";GRANT ALL PRIVILEGES ON nextcloud.* TO 'nextcloud'@'localhost';FLUSH PRIVILEGES;ALTER DATABASE nextcloud CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci;" || echo "La base de donnée de nextcloud est déjà créé, skip"
echo -e "${c_yellow} === Installing and configure Redis... ===$c_"
apt install redis-server php-redis -y
[[ ! -e /etc/redis/redis.conf.bak ]] && cp /etc/redis/redis.conf /etc/redis/redis.conf.bak || echo "Redis est déjà configuré, skip"
sed -i "s/port 6379/port 0/" /etc/redis/redis.conf
sed -i "s/redis.sock/redis-server.sock/" /etc/redis/redis.conf
sed -i s/\#\ unixsocket/\unixsocket/g /etc/redis/redis.conf
sed -i "s/unixsocketperm 700/unixsocketperm 770/" /etc/redis/redis.conf
sed -i "s/# maxclients 10000/maxclients 512/" /etc/redis/redis.conf
usermod -a -G redis www-data || (echo -e "${c_red}Erreur quelque part ...$c_" && exit 1)
[[ ! -e /etc/sysctl.conf.bak ]] && cp /etc/sysctl.conf /etc/sysctl.conf.bak || echo "sysctl est déjà configuré, skip"
sed -i '$avm.overcommit_memory = 1' /etc/sysctl.conf
service redis-server restart || (echo -e "${c_red}Erreur quelque part ...$c_" && exit 1)
echo -e "${c_yellow} === Installing NextCloud... ===$c_"
if [[ ! -e /var/www/nextcloud ]]; then
mkdir /var/www/nextcloud
chown www-data:www-data /var/www/nextcloud
chmod 750 /var/www/nextcloud || (echo -e "${c_red}Erreur quelque part ...$c_" && exit 1)
wget https://download.nextcloud.com/server/releases/latest.tar.bz2
tar -xjf latest.tar.bz2 -C /var/www && chown -R www-data:www-data /var/www/ && rm -f latest.tar.bz2
fi
if [[ ! -e $data_dir ]]; then
mkdir -p $data_dir
chown www-data:www-data $data_dir
chmod 750 $data_dir || (echo -e "${c_red}Erreur quelque part ...$c_" && exit 1)
fi
## Add local IP as secondary trust domain
# Prefere occ methode ...
# sed -i "/0 => '$nc_domain'.*/a \ 1 => '$ip_local:$nc_port'," /var/www/nextcloud/config/config.php
ip_local=$(/sbin/ifconfig | sed -En 's/127.0.0.1//;s/.*inet (addr:)?(([0-9]*\.){3}[0-9]*).*/\2/p')
[[ $nc_port == 80 ]] && nc_port_loc="" || nc_port_loc=":$nc_port"
[[ -e /var/www/nextcloud/config/config.php ]] && isNCConfig=$(cat /var/www/nextcloud/config/config.php | grep "'installed' => true")
[[ -z "$isNCConfig" ]] && sudo -u www-data php /var/www/nextcloud/occ maintenance:install --database "mysql" --database-name "nextcloud" --database-user "nextcloud" --database-pass "$db_pass" --admin-user "$admin_user" --admin-pass "$admin_pass" --data-dir "$data_dir"
sleep 0.2
sudo -u www-data php /var/www/nextcloud/occ config:system:set mysql.utf8mb4 --type boolean --value="true"
sudo -u www-data php /var/www/nextcloud/occ config:system:set trusted_domains 0 --value=$nc_domain
sudo -u www-data php /var/www/nextcloud/occ config:system:set trusted_domains 1 --value=$ip_local$nc_port_loc
sudo -u www-data php /var/www/nextcloud/occ config:system:set overwrite.cli.url --value=$nc_domain
isNCConfigAdd=$(cat /var/www/nextcloud/config/config.php | grep "activity_expire_days")
if [[ -z "$isNCConfigAdd" ]]; then
sudo -u www-data sed -i 's/^[ ]*//' /var/www/nextcloud/config/config.php
sudo -u www-data sed -i '/);/d' /var/www/nextcloud/config/config.php
cat config_complete.php >> /var/www/nextcloud/config/config.php
fi
sudo -u www-data sed -i "s/output_buffering=.*/output_buffering=0/" /var/www/nextcloud/.user.ini
sudo -u www-data php /var/www/nextcloud/occ app:disable survey_client
sudo -u www-data php /var/www/nextcloud/occ app:disable firstrunwizard
sudo -u www-data php /var/www/nextcloud/occ app:enable admin_audit
sudo -u www-data php /var/www/nextcloud/occ app:enable files_pdfviewer
echo -e "${c_yellow} === Configure nginx ... ===$c_"
cp nextcloud.conf /etc/nginx/conf.d/
cp *optimization.conf /etc/nginx/
sed -i "s/NC_DOMAIN/$nc_domain/" /etc/nginx/conf.d/nextcloud.conf
sed -i "s/NC_PORT/$nc_port/" /etc/nginx/conf.d/nextcloud.conf
sed -i "s/_PHPVERSION/$PHPVERSION/" /etc/nginx/conf.d/nextcloud.conf
sed -i "s/80 default_server;/81 default_server;/" /etc/nginx/sites-enabled/default
chmod u+x ../ssl.sh
if [[ $isSSL == "false" ]]; then
../ssl.sh nonssl
else
../ssl.sh certif
../ssl.sh ssl
fi
echo -e "${c_yellow} === Mise en place des scripts et crons ... ===$c_"
[[ ! -e /opt/scripts ]] && mkdir /opt/scripts
cp nc_optimize.sh /opt/scripts/
cp upgrade.sh /opt/scripts/
cp occ /opt/scripts/
echo "alias occ='/opt/scripts/occ'" >> ~/.bashrc
alias occ='/opt/scripts/occ'
[[ -z $(crontab -l | grep "/var/www/nextcloud/cron.php") ]] && (crontab -l ; echo "*/5 * * * * sudo -u www-data /usr/bin/php -f /var/www/nextcloud/cron.php > /dev/null 2>&1") | crontab -u root - || echo "cron nextcloud ever set, skip"
[[ -z $(crontab -l | grep "/opt/scripts/optimize.sh") ]] && (crontab -l ; echo "5 1 * * * /opt/scripts/optimize.sh > /dev/null 2>&1") | crontab -u root - || echo "cron optimize ever set, skip"
sudo -u www-data php /var/www/nextcloud/occ background:cron
sudo -u www-data php /var/www/nextcloud/occ db:add-missing-indices
sudo -u www-data php /var/www/nextcloud/occ db:convert-filecache-bigint
echo -e "${c_yellow} === Restarting services ... ===$c_"
service php$PHPVERSION-fpm restart && service nginx restart && service mysql restart && service redis-server restart || (echo -e "${c_red}Impossible de reloader les service$c_" && exit 1)
bash /opt/scripts/nc_optimize.sh
usermod -aG www-data $YOU
echo -e "${c_green}Nextcloud a été installé avec succès !\nOuverture...$c_"
URL="http://$nc_domain:$nc_port"
[[ -x $BROWSER ]] && su -c "exec \"$BROWSER\" \"$URL\"" $YOU > /dev/null
path=$(which xdg-open || which gnome-open) && su -c "exec \"$path\" \"$URL\"" $YOU > /dev/null
echo -e "${c_yellow}Can't find browser$c_"

69
.install/nextcloud/ssl.sh Executable file
View File

@ -0,0 +1,69 @@
#!/bin/bash
if [ "$EUID" -ne 0 ]
then echo "Veuillez executez ce script en root"
exit 1
fi
domain=$(cat /etc/nginx/conf.d/nextcloud.conf | grep server_name | awk '{ print $2 }')
domain=$(echo ${domain::-1})
[[ ! $1 =~ ^(ssl|nonssl|certif)$ ]] && echo "Veuillez choisir ssl, nonssl ou certif pour créer un certificat ssl" && exit 1
ssl(){
sed -i "s/'overwriteprotocol' => 'http'/'overwriteprotocol' => 'https'/" /var/www/nextcloud/config/config.php
sed -i "s/http/https/" /etc/nginx/conf.d/nextcloud.conf
sed -i "s/fastcgi_param HTTPS off/fastcgi_param HTTPS on/" /etc/nginx/conf.d/nextcloud.conf
sed -i "s/listen 443;/listen 443 ssl;/" /etc/nginx/conf.d/nextcloud.conf
[[ ! -e /etc/nginx/includes ]] && mkdir /etc/nginx/includes
cp .install_templates/ssl.conf /etc/nginx/includes/
sed -i "/fastcgi_hide_header X-Powered-By;/a \ include includes/ssl.conf;\n ssl_certificate /etc/letsencrypt/live/$domain/fullchain.pem;\n ssl_certificate_key /etc/letsencrypt/live/$domain/privkey.pem;" /etc/nginx/conf.d/nextcloud.conf
}
nonssl(){
sed -i "s/'overwriteprotocol' => 'https'/'overwriteprotocol' => 'http'/" /var/www/nextcloud/config/config.php
sed -i "s/https/http/" /etc/nginx/conf.d/nextcloud.conf
sed -i "s/fastcgi_param HTTPS on/fastcgi_param HTTPS off/" /etc/nginx/conf.d/nextcloud.conf
sed -i '/ssl.conf;/d' /etc/nginx/conf.d/nextcloud.conf
sed -i '/ssl_certificate/d' /etc/nginx/conf.d/nextcloud.conf
}
install_certbot(){
sudo apt update
if [[ $(grep buster /etc/os-release) ]]; then
[[ -z $(cat /etc/apt/sources.list | grep "buster-backports main") ]] && echo "deb http://deb.debian.org/debian buster-backports main" >> /etc/apt/sources.list
sudo apt install certbot python-certbot-nginx -t buster-backports -y
elif [[ $(grep stretch /etc/os-release) ]]; then
sudo apt install certbot python-certbot-nginx -y
elif [[ $(grep -E '16.|17.|18.|19.' /etc/os-release) ]]; then
sudo apt install software-properties-common
sudo add-apt-repository universe
sudo add-apt-repository ppa:certbot/certbot
sudo apt update
sudo apt install certbot python-certbot-nginx
else
echo "OS non supporté pour certbot." && exit 1
fi
}
create_certificate() {
cd .install_templates
certbot --nginx certonly --non-interactive --agree-tos -m $USER@$domain -d $domain && echo "Le certificat de $domain a bien été déployé" || echo "Une erreur s'est produite lors de la création du certificat SSL"
## Cronification
[[ ! -e /opt/scripts ]] && mkdir /opt/scripts
cp ssl_renew.sh /opt/scripts/
[[ -z $(crontab -l | grep "/opt/scripts/ssl_renew.sh") ]] && (crontab -l ; echo "12 2 * * 1 /opt/scripts/ssl_renew.sh") | crontab -u root -
}
certif() {
[[ -z $(which certbot) ]] && install_certbot
[[ -n /etc/letsencrypt/live/$domain/fullchain.pem ]] && create_certificate
}
$@
service nginx reload
exit 0

View File

@ -0,0 +1,52 @@
'activity_expire_days' => 14,
'auth.bruteforce.protection.enabled' => true,
'blacklisted_files' =>
array (
0 => '.htaccess',
1 => 'Thumbs.db',
2 => 'thumbs.db',
),
'cron_log' => true,
'enable_previews' => true,
'enabledPreviewProviders' =>
array (
0 => 'OC\\Preview\\PNG',
1 => 'OC\\Preview\\JPEG',
2 => 'OC\\Preview\\GIF',
3 => 'OC\\Preview\\BMP',
4 => 'OC\\Preview\\XBitmap',
5 => 'OC\\Preview\\Movie',
6 => 'OC\\Preview\\PDF',
7 => 'OC\\Preview\\MP3',
8 => 'OC\\Preview\\TXT',
9 => 'OC\\Preview\\MarkDown',
),
'filesystem_check_changes' => 0,
'filelocking.enabled' => 'true',
'htaccess.RewriteBase' => '/',
'integrity.check.disabled' => false,
'knowledgebaseenabled' => false,
'logfile' => '/var/log/nextcloud.log',
'loglevel' => 2,
'logtimezone' => 'Europe/Paris',
'log_rotate_size' => 104857600,
'maintenance' => false,
'memcache.local' => '\\OC\\Memcache\\APCu',
'memcache.locking' => '\\OC\\Memcache\\Redis',
'overwriteprotocol' => 'https',
'preview_max_x' => 1024,
'preview_max_y' => 768,
'preview_max_scale_factor' => 1,
'redis' =>
array (
'host' => '/var/run/redis/redis-server.sock',
'port' => 0,
'timeout' => 0.0,
),
'quota_include_external_storage' => false,
'share_folder' => '/Shares',
'skeletondirectory' => '',
'theme' => '',
'trashbin_retention_obligation' => 'auto, 7',
'updater.release.channel' => 'stable',
);

View File

@ -0,0 +1,50 @@
cp /etc/php/$PHPVERSION/fpm/pool.d/www.conf /etc/php/$PHPVERSION/fpm/pool.d/www.conf.bak
cp /etc/php/$PHPVERSION/cli/php.ini /etc/php/$PHPVERSION/cli/php.ini.bak
cp /etc/php/$PHPVERSION/fpm/php.ini /etc/php/$PHPVERSION/fpm/php.ini.bak
cp /etc/php/$PHPVERSION/fpm/php-fpm.conf /etc/php/$PHPVERSION/fpm/php-fpm.conf.bak
sed -i "s/;env\[HOSTNAME\] = /env[HOSTNAME] = /" /etc/php/$PHPVERSION/fpm/pool.d/www.conf
sed -i "s/;env\[TMP\] = /env[TMP] = /" /etc/php/$PHPVERSION/fpm/pool.d/www.conf
sed -i "s/;env\[TMPDIR\] = /env[TMPDIR] = /" /etc/php/$PHPVERSION/fpm/pool.d/www.conf
sed -i "s/;env\[TEMP\] = /env[TEMP] = /" /etc/php/$PHPVERSION/fpm/pool.d/www.conf
sed -i "s/;env\[PATH\] = /env[PATH] = /" /etc/php/$PHPVERSION/fpm/pool.d/www.conf
sed -i "s/pm.max_children = .*/pm.max_children = 240/" /etc/php/$PHPVERSION/fpm/pool.d/www.conf
sed -i "s/pm.start_servers = .*/pm.start_servers = 20/" /etc/php/$PHPVERSION/fpm/pool.d/www.conf
sed -i "s/pm.min_spare_servers = .*/pm.min_spare_servers = 10/" /etc/php/$PHPVERSION/fpm/pool.d/www.conf
sed -i "s/pm.max_spare_servers = .*/pm.max_spare_servers = 20/" /etc/php/$PHPVERSION/fpm/pool.d/www.conf
sed -i "s/;pm.max_requests = 500/pm.max_requests = 500/" /etc/php/$PHPVERSION/fpm/pool.d/www.conf
sed -i "s/output_buffering =.*/output_buffering = 'Off'/" /etc/php/$PHPVERSION/cli/php.ini
sed -i "s/max_execution_time =.*/max_execution_time = 1800/" /etc/php/$PHPVERSION/cli/php.ini
sed -i "s/max_input_time =.*/max_input_time = 3600/" /etc/php/$PHPVERSION/cli/php.ini
sed -i "s/post_max_size =.*/post_max_size = 10240M/" /etc/php/$PHPVERSION/cli/php.ini
sed -i "s/upload_max_filesize =.*/upload_max_filesize = 10240M/" /etc/php/$PHPVERSION/cli/php.ini
sed -i "s/max_file_uploads =.*/max_file_uploads = 100/" /etc/php/$PHPVERSION/cli/php.ini
sed -i "s/;date.timezone.*/date.timezone = Europe\/\Paris/" /etc/php/$PHPVERSION/cli/php.ini
## sed -i "s/;session.cookie_secure.*/session.cookie_secure = True/" /etc/php/$PHPVERSION/cli/php.ini # Bug if not using ssl
sed -i "s/memory_limit = 128M/memory_limit = 512M/" /etc/php/$PHPVERSION/fpm/php.ini
sed -i "s/output_buffering =.*/output_buffering = 'Off'/" /etc/php/$PHPVERSION/fpm/php.ini
sed -i "s/max_execution_time =.*/max_execution_time = 1800/" /etc/php/$PHPVERSION/fpm/php.ini
sed -i "s/max_input_time =.*/max_input_time = 3600/" /etc/php/$PHPVERSION/fpm/php.ini
sed -i "s/post_max_size =.*/post_max_size = 10240M/" /etc/php/$PHPVERSION/fpm/php.ini
sed -i "s/upload_max_filesize =.*/upload_max_filesize = 10240M/" /etc/php/$PHPVERSION/fpm/php.ini
sed -i "s/max_file_uploads =.*/max_file_uploads = 100/" /etc/php/$PHPVERSION/fpm/php.ini
sed -i "s/;date.timezone.*/date.timezone = Europe\/\Paris/" /etc/php/$PHPVERSION/fpm/php.ini
## sed -i "s/;session.cookie_secure.*/session.cookie_secure = True/" /etc/php/$PHPVERSION/fpm/php.ini # Bug if not using ssl
sed -i "s/;opcache.enable=.*/opcache.enable=1/" /etc/php/$PHPVERSION/fpm/php.ini
sed -i "s/;opcache.enable_cli=.*/opcache.enable_cli=1/" /etc/php/$PHPVERSION/fpm/php.ini
sed -i "s/;opcache.memory_consumption=.*/opcache.memory_consumption=128/" /etc/php/$PHPVERSION/fpm/php.ini
sed -i "s/;opcache.interned_strings_buffer=.*/opcache.interned_strings_buffer=8/" /etc/php/$PHPVERSION/fpm/php.ini
sed -i "s/;opcache.max_accelerated_files=.*/opcache.max_accelerated_files=10000/" /etc/php/$PHPVERSION/fpm/php.ini
sed -i "s/;opcache.revalidate_freq=.*/opcache.revalidate_freq=1/" /etc/php/$PHPVERSION/fpm/php.ini
sed -i "s/;opcache.save_comments=.*/opcache.save_comments=1/" /etc/php/$PHPVERSION/fpm/php.ini
sed -i "s/;emergency_restart_threshold =.*/emergency_restart_threshold = 10/" /etc/php/$PHPVERSION/fpm/php-fpm.conf
sed -i "s/;emergency_restart_interval =.*/emergency_restart_interval = 1m/" /etc/php/$PHPVERSION/fpm/php-fpm.conf
sed -i "s/;process_control_timeout =.*/process_control_timeout = 10s/" /etc/php/$PHPVERSION/fpm/php-fpm.conf
sed -i "s/09,39.*/# &/" /etc/cron.d/php
(crontab -l ; echo "09,39 * * * * /usr/lib/php/sessionclean 2>&1") | crontab -u root -
cp /etc/ImageMagick-6/policy.xml /etc/ImageMagick-6/policy.xml.bak
sed -i "s/rights\=\"none\" pattern\=\"PS\"/rights\=\"read\|write\" pattern\=\"PS\"/" /etc/ImageMagick-6/policy.xml
sed -i "s/rights\=\"none\" pattern\=\"EPI\"/rights\=\"read\|write\" pattern\=\"EPI\"/" /etc/ImageMagick-6/policy.xml
sed -i "s/rights\=\"none\" pattern\=\"PDF\"/rights\=\"read\|write\" pattern\=\"PDF\"/" /etc/ImageMagick-6/policy.xml
sed -i "s/rights\=\"none\" pattern\=\"XPS\"/rights\=\"read\|write\" pattern\=\"XPS\"/" /etc/ImageMagick-6/policy.xml
service php$PHPVERSION-fpm restart && service nginx restart

View File

@ -0,0 +1,79 @@
[client]
default-character-set = utf8mb4
port = 3306
socket = /var/run/mysqld/mysqld.sock
[mysqld_safe]
log_error=/var/log/mysql/mysql_error.log
nice = 0
socket = /var/run/mysqld/mysqld.sock
[mysqld]
basedir = /usr
bind-address = 127.0.0.1
binlog_format = ROW
bulk_insert_buffer_size = 16M
character-set-server = utf8mb4
collation-server = utf8mb4_general_ci
concurrent_insert = 2
connect_timeout = 5
datadir = /var/lib/mysql
default_storage_engine = InnoDB
expire_logs_days = 10
general_log_file = /var/log/mysql/mysql.log
general_log = 0
innodb_buffer_pool_size = 1024M
innodb_buffer_pool_instances = 1
innodb_flush_log_at_trx_commit = 2
innodb_log_buffer_size = 32M
innodb_max_dirty_pages_pct = 90
innodb_large_prefix = on
innodb_file_format = barracuda
innodb_file_per_table = 1
innodb_open_files = 400
innodb_io_capacity = 4000
innodb_flush_method = O_DIRECT
key_buffer_size = 128M
lc_messages_dir = /usr/share/mysql
lc_messages = en_US
log_bin = /var/log/mysql/mariadb-bin
log_bin_index = /var/log/mysql/mariadb-bin.index
log_error=/var/log/mysql/mysql_error.log
log_slow_verbosity = query_plan
log_warnings = 2
long_query_time = 1
max_allowed_packet = 16M
max_binlog_size = 100M
max_connections = 200
max_heap_table_size = 64M
myisam_recover_options = BACKUP
myisam_sort_buffer_size = 512M
port = 3306
pid-file = /var/run/mysqld/mysqld.pid
query_cache_limit = 2M
query_cache_size = 64M
query_cache_type = 1
query_cache_min_res_unit = 2k
read_buffer_size = 2M
read_rnd_buffer_size = 1M
skip-external-locking
skip-name-resolve
slow_query_log_file = /var/log/mysql/mariadb-slow.log
slow-query-log = 1
socket = /var/run/mysqld/mysqld.sock
sort_buffer_size = 4M
table_open_cache = 400
thread_cache_size = 128
tmp_table_size = 64M
tmpdir = /tmp
transaction_isolation = READ-COMMITTED
user = mysql
wait_timeout = 600
[mysqldump]
max_allowed_packet = 16M
quick
quote-names
[isamchk]
key_buffer = 16M

View File

@ -0,0 +1,10 @@
#!/bin/bash
redis-cli -s /var/run/redis/redis-server.sock <<EOF
FLUSHALL
quit
EOF
sudo -u www-data php /var/www/nextcloud/occ files:scan --all
sudo -u www-data php /var/www/nextcloud/occ files:scan-app-data
exit 0

View File

@ -0,0 +1,149 @@
upstream php-handler {
server unix:/var/run/php/php_PHPVERSION-fpm.sock;
}
server {
listen NC_PORT;
listen 443;
listen [::]:443 ssl;
server_name NC_DOMAIN;
add_header X-Content-Type-Options nosniff;
add_header X-XSS-Protection "1; mode=block";
add_header X-Robots-Tag none;
add_header X-Download-Options noopen;
add_header X-Permitted-Cross-Domain-Policies none;
add_header Referrer-Policy no-referrer;
set_real_ip_from 192.168.9.1;
set_real_ip_from 192.168.9.6;
# Remove X-Powered-By, which is an information leak
fastcgi_hide_header X-Powered-By;
add_header X-Frame-Options "SAMEORIGIN";
# Path to the root of your installation
root /var/www/nextcloud/;
location = /robots.txt {
allow all;
log_not_found off;
access_log off;
}
# The following 2 rules are only needed for the user_webfinger app.
# Uncomment it if you're planning to use this app.
#rewrite ^/.well-known/host-meta /public.php?service=host-meta last;
#rewrite ^/.well-known/host-meta.json /public.php?service=host-meta-json
# last;
location = /.well-known/carddav {
return 301 https://$host/remote.php/dav;
}
location = /.well-known/caldav {
return 301 https://$host/remote.php/dav;
}
# set max upload size
client_max_body_size 512M;
fastcgi_buffers 64 4K;
# Enable gzip but do not remove ETag headers
gzip on;
gzip_vary on;
gzip_comp_level 4;
gzip_min_length 256;
gzip_proxied expired no-cache no-store private no_last_modified no_etag auth;
gzip_types application/atom+xml application/javascript application/json application/ld+json application/manifest+json application/rss+xml application/vnd.geo+json application/vnd.ms-fontobject application/x-font-ttf application/x-web-app-manifest+json application/xhtml+xml application/xml font/opentype image/bmp image/svg+xml image/x-icon text/cache-manifest text/css text/plain text/vcard text/vnd.rim.location.xloc text/vtt text/x-component text/x-cross-domain-policy;
# Uncomment if your server is build with the ngx_pagespeed module
# This module is currently not supported.
#pagespeed off;
location / {
rewrite ^ /index.php;
}
location ~ ^/(?:build|tests|config|lib|3rdparty|templates|data)/ {
deny all;
}
location ~ ^/(?:\.|autotest|occ|issue|indie|db_|console) {
deny all;
}
location ~ ^\/(?:index|remote|public|cron|core\/ajax\/update|status|ocs\/v[12]|updater\/.+|oc[ms]-provider\/.+)\.php(?:$|\/) {
fastcgi_split_path_info ^(.+?\.php)(\/.*|)$;
try_files $fastcgi_script_name =404;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param HTTPS on;
# Avoid sending the security headers twice
fastcgi_param modHeadersAvailable true;
# Enable pretty urls
fastcgi_param front_controller_active true;
fastcgi_pass php-handler;
fastcgi_intercept_errors on;
fastcgi_request_buffering off;
}
location ~ ^\/(?:updater|oc[ms]-provider)(?:$|\/) {
try_files $uri/ =404;
index index.php;
}
# Adding the cache control header for js and css files
# Make sure it is BELOW the PHP block
location ~ \.(?:css|js|woff2?|svg|gif)$ {
try_files $uri /index.php$request_uri;
add_header Cache-Control "public, max-age=15778463";
# Add headers to serve security related headers (It is intended to
# have those duplicated to the ones above)
# Before enabling Strict-Transport-Security headers please read into
# this topic first.
# add_header Strict-Transport-Security "max-age=15768000; includeSubDomains; preload;";
#
# WARNING: Only add the preload option once you read about
# the consequences in https://hstspreload.org/. This option
# will add the domain to a hardcoded list that is shipped
# in all major browsers and getting removed from this list
# could take several months.
add_header X-Content-Type-Options nosniff;
add_header X-XSS-Protection "1; mode=block";
add_header X-Robots-Tag none;
add_header X-Download-Options noopen;
add_header X-Permitted-Cross-Domain-Policies none;
add_header Referrer-Policy no-referrer;
# Optional: Don't log access to assets
access_log off;
}
location ~ \.(?:png|html|ttf|ico|jpg|jpeg)$ {
try_files $uri /index.php$request_uri;
# Optional: Don't log access to other assets
access_log off;
}
location ^~ /apps/rainloop/app/data {
deny all;
}
location ~ \.(?:flv|mp4|mov|m4a)$ {
# mp4;
# mp4_buffer_size 100M;
# mp4_max_buffer_size 1024M;
fastcgi_split_path_info ^(.+?.php)(\/.*|)$;
include fastcgi_params;
include php_optimization.conf;
fastcgi_pass php-handler;
fastcgi_param HTTPS on;
}
location ~ ^\/nextcloud/(?:updater|oc[ms]-provider)(?:$|\/) {
try_files $uri/ =404;
index index.php;
}
}

View File

@ -0,0 +1,6 @@
#/bin/bash
sudo -u www-data php /var/www/nextcloud/occ $@
exit 0

View File

@ -0,0 +1,17 @@
fastcgi_hide_header X-Powered-By;
fastcgi_read_timeout 3600;
fastcgi_send_timeout 3600;
fastcgi_connect_timeout 3600;
fastcgi_buffers 64 64K;
fastcgi_buffer_size 256k;
fastcgi_busy_buffers_size 3840K;
fastcgi_cache_key $http_cookie$request_method$host$request_uri;
fastcgi_cache_use_stale error timeout invalid_header http_500;
fastcgi_ignore_headers Cache-Control Expires Set-Cookie;
gzip on;
gzip_vary on;
gzip_comp_level 4;
gzip_min_length 256;
gzip_proxied expired no-cache no-store private no_last_modified no_etag auth;
gzip_types application/atom+xml application/javascript application/json application/ld+json application/manifest+json application/rss+xml application/vnd.geo+json application/vnd.ms-fontobject application/x-font-ttf application/x-web-app-manifest+json application/xhtml+xml application/xml font/opentype image/bmp image/svg+xml image/x-icon text/cache-manifest text/css text/plain text/vcard text/vnd.rim.location.xloc text/vtt text/x-component text/x-cross-domain-policy;
gzip_disable "MSIE [1-6]\.";

View File

@ -0,0 +1,8 @@
#!/bin/bash
find /var/www/ -type f -print0 | xargs -0 chmod 0640
find /var/www/ -type d -print0 | xargs -0 chmod 0750
chown -R www-data:www-data /var/www/
chown -R www-data:www-data /var/nextcloud/
chmod 0644 /var/www/nextcloud/.htaccess
chmod 0644 /var/www/nextcloud/.user.ini
exit 0

View File

@ -0,0 +1,9 @@
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param modHeadersAvailable true;
fastcgi_param front_controller_active true;
fastcgi_intercept_errors on;
fastcgi_request_buffering off;
fastcgi_cache_valid 404 1m;
fastcgi_cache_valid any 1h;
fastcgi_cache_methods GET HEAD;

View File

@ -0,0 +1,16 @@
ssl_session_timeout 4h;
ssl_session_cache shared:SSL:50m;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_ciphers 'ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:DHE-RSA-AES128-CBC-SHA:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA256:ECDHE-ECDSA-AES128-SHA:ECDHE-RSA-AES256-SHA384:ECDHE-RSA-AES128-SHA:ECDHE-ECDSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA:ECDHE-RSA-AES256-SHA:ECDHE-ECDSA-DES-CBC3-SHA:ECDHE-RSA-DES-CBC3-SHA:AES128-GCM-SHA256:AES256-GCM-SHA384:AES128-SHA256:AES256-SHA256:AES128-SHA:AES256-SHA:DES-CBC3-SHA:!DSS';
ssl_prefer_server_ciphers on;
add_header Strict-Transport-Security max-age=15768000;
ssl_stapling on;
ssl_stapling_verify on;
resolver 8.8.8.8 8.8.4.4 valid=86400;
resolver_timeout 10;
ssl_session_tickets on;

View File

@ -0,0 +1,26 @@
#!/bin/bash
log="/var/log/ssl_renew.log"
date=$(date +%d-%m-%Y)
renew=$(certbot renew --pre-hook "service nginx stop" --post-hook "service nginx start")
echo "####################################################################################" >> $log
echo "#################################### $date ####################################" >> $log
echo "####################################################################################" >> $log
echo "$renew" >> $log
if [[ $renew = *"No hooks were run"* ]]; then
echo "Rien n'a été fait" >> $log
else
sleep 5
/etc/init.d/nginx stop
sleep 1
killall nginx
sleep 3
/etc/init.d/nginx restart &>> $log
echo "Des certificats ont été renouvellés" >> $log
fi
exit 0

View File

@ -0,0 +1,15 @@
#!/bin/bash
/usr/sbin/service nginx stop
sudo -u www-data php /var/www/nextcloud/updater/updater.phar
sudo -u www-data php /var/www/nextcloud/occ status
sudo -u www-data php /var/www/nextcloud/occ -V
sudo -u www-data php /var/www/nextcloud/occ db:add-missing-indices
sudo -u www-data php /var/www/nextcloud/occ db:convert-filecache-bigint
sudo -u www-data sed -i "s/output_buffering=.*/output_buffering=O/" /var/www/nextcloud/.user.ini
sudo -u www-data php /var/www/nextcloud/occ update:check
sudo -u www-data php /var/www/nextcloud/occ app:update --all
/usr/sbin/service php7.3-fpm restart
/usr/sbin/service nginx restart
exit 0

37
.install/sys_checkOS.sh Executable file
View File

@ -0,0 +1,37 @@
#!/bin/bash
astroVars="OS ARM YOU ipfsnodeid ASTROZEN ASTRONODE myProfile"
export YOU=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1)
export ipfsnodeid=$(ipfs id -f='<id>\n')
export ASTROZEN="/home/$YOU/.zen"
export ASTRONODE="$ASTROZEN/ipfs/.$ipfsnodeid"
export myProfile="$ASTRONODE/profile"
[[ ! -d $ASTRONODE ]] && mkdir -p $ASTRONODE
## Check system kind
[[ $(uname -a | grep arm) ]] && export ARM=yes || unset ARM
if [[ $(grep -E '19.3|19.4' /etc/os-release) ]]; then export OS=buster;
elif [[ $(grep -E 'stretch|18.|19.' /etc/os-release) ]]; then export OS=stretch;
else export OS=buster;
fi
[[ -e $myProfile ]] && rm $myProfile
touch $myProfile
for i in $astroVars; do
[[ ! $(grep "$i=" $myProfile) && -n ${!i} ]] && echo "export $i=${!i}" >> $myProfile
done
# Export for user
[[ -n $(grep "/.zen/ipfs/" ~/.bashrc) ]] && sed -i -n '/\/.zen\/ipfs/!p' ~/.bashrc
[[ -n $(grep "# ASTROPORT " ~/.bashrc) ]] && sed -i -n '/# ASTROPORT /!p' ~/.bashrc
echo -e "# ASTROPORT ENVIRONMENT VARIABLE\n. /home/$YOU/.zen/ipfs/.$ipfsnodeid/profile" >> ~/.bashrc
# Export for root (obsolete)
#[[ -n $(sudo grep "/.zen/ipfs/" /root/.bashrc) ]] && sudo sed -i -n '/\/.zen\/ipfs/!p' /root/.bashrc
#[[ -n $(sudo grep "# ASTROPORT " /root/.bashrc) ]] && sudo sed -i -n '/# ASTROPORT /!p' /root/.bashrc
#echo -e "# ASTROPORT ENVIRONMENT VARIABLE\n. /home/$YOU/.zen/ipfs/.$ipfsnodeid/profile" | sudo tee -a /root/.bashrc
[[ $1 != "noexec" ]] && exec bash

View File

@ -15,13 +15,12 @@ PATH=/sbin:/usr/sbin:/bin:/usr/bin:/usr/local/bin
DESC="ipfs daemon"
NAME=ipfs
DAEMON=/usr/local/bin/ipfs
DAEMON_ARGS="daemon"
DAEMON_ARGS="daemon --enable-pubsub-experiment --enable-namesys-pubsub --enable-gc"
PIDFILE=/var/run/$NAME.pid
SCRIPTNAME=/etc/init.d/$NAME
IPFS_PATH=/media/data/.ipfs
IPFS_USER=root
IPFS_PATH=/home/xbian/.ipfs
IPFS_USER=xbian
# Exit if the package is not installed
[ -x "$DAEMON" ] || exit 0
@ -48,7 +47,7 @@ do_start() {
|| return 1
start-stop-daemon --start --quiet --pidfile $PIDFILE --make-pidfile \
--background --chuid $IPFS_USER --no-close \
--exec /usr/bin/env IPFS_PATH="$IPFS_PATH" $DAEMON 2>>$IPFS_PATH/logs/daemon.log 1>/dev/null \
--exec /usr/bin/env IPFS_PATH="$IPFS_PATH" $DAEMON 2>>/var/log/ipfs.log 1>/dev/null \
-- $DAEMON_ARGS \
|| return 2
}
@ -99,4 +98,4 @@ case "$1" in
echo "Usage: $SCRIPTNAME {start|stop|status|restart}" >&2
exit 3
;;
esac
esac

34
.install/update_bashrc.sh Executable file
View File

@ -0,0 +1,34 @@
#!/bin/bash
########################################################################
# Author: Fred (support@qo-op.com)
# Version: 2020.12.06
# License: AGPL-3.0 (https://choosealicense.com/licenses/agpl-3.0/)
########################################################################
# update_bashrc.sh
# Add $YOU $IPFSNODEID $G1PUB to ~/.bashrc
source ~/.bashrc
[[ $YOU != "" && $IPFSNODEID != "" && $G1PUB != "" ]] && er+="bashrc already updated"
YOU=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1) || er+=" ipfs daemon not running"
IPFSNODEID=$(ipfs id -f='<id>\n') || er+=" ipfs id problem"
[[ -f ~/.zen/secret.dunikey ]] && G1PUB=$(cat ~/.zen/secret.dunikey | grep 'pub:' | cut -d ' ' -f 2) || er+=" ~/.zen/secret.dunikey missing cannot find G1PUB"
[[ $er != "" ]] && echo "$er" && exit 1
echo "### ASTROPORT IDENTITY ###" >> ~/.bashrc
echo "YOU=$YOU" >> ~/.bashrc
echo "G1PUB=$G1PUB" >> ~/.bashrc
echo "IPFSNODEID=$IPFSNODEID" >> ~/.bashrc
## Add jaklis/.env ?
# cat ~/.zen/astroport/zen/jaklis/.env >> ~/.bashrc
source ~/.bashrc
echo "UPDATE ~/.bashrc OK"
tail -n 4 ~/.bashrc
exit 0

8
.install/youtube-dl.sh Executable file
View File

@ -0,0 +1,8 @@
#!/bin/bash
########################################################################
######## YOUTUBE-DL ##########
if [[ ! $(which youtube-dl) ]]; then
sudo wget https://yt-dl.org/downloads/latest/youtube-dl -O /usr/local/bin/youtube-dl || exit 1
sudo chmod a+rx /usr/local/bin/youtube-dl
sudo chown $USER /usr/local/bin/youtube-dl
fi

113
1stRUNconfig.sh Executable file
View File

@ -0,0 +1,113 @@
#!/bin/bash
########################################################################
# Author: Fred (support@qo-op.com)
# Version: 2020.12.04
# License: AGPL-3.0 (https://choosealicense.com/licenses/agpl-3.0/)
########################################################################
#
# This script is run from ~/.config/autostart/Astroport_X_config.desktop
#
########################################################################
# Create secret key files
# ~/.zen/secret.june
# ~/.zen/secret.dunikey
# ~/.zen/secret.ipfs & /tmp/config.ipfs
# ~/.zen/ipfs.sync
########################################################################
[[ $(which zenity) == "" ]] && echo "Please! sudo apt install zenity. EXIT" && exit 1
[[ -f ~/.zen/ipfs.sync ]] && echo "CONFIG ALREADY DONE" && source ~/.zen/ipfs.sync && exit 0
function cleanTMP
{
rm -f /tmp/secret.june /tmp/secret.dunikey /tmp/config.ipfs /tmp/secret.ipfs /tmp/secret.all
}
# NB: 2> >(grep -v 'GtkDialog' >&2) remove zenity console warning
zenity --question --width 300 --text "Initialiser votre station Astroport?" 2> >(grep -v 'GtkDialog' >&2)
[ $? == 1 ] && exit 1
########################################################################
# LOGIN (=SALT)
salt="$(~/.zen/astroport/zen/tools/diceware.sh 3 | xargs)"
# PASS (=PEPPER)
pepper="$(~/.zen/astroport/zen/tools/diceware.sh 3 | xargs)"
g1_profil=$(zenity --entry --width 300 --text "Nom de votre machine" --title "Astroport -- Profil" --entry-text="$(hostname)" 2> >(grep -v 'GtkDialog' >&2));
g1_salt=$(zenity --entry --width 300 --text "Identifiant gchange/cesium (sel)" --title "Astroport - Sel" --entry-text="$salt" 2> >(grep -v 'GtkDialog' >&2));
[ ${#g1_salt} -lt 8 ] && zenity --warning --width 300 --text "Identifiant doit faire plus de 8 caractères!!" 2> >(grep -v 'GtkDialog' >&2) && cleanTMP && exit 1
g1_pepper=$(zenity --entry --width 300 --text "Mot de passe gchange/cesium (poivre)" --title "Astroport - Poivre" --entry-text="$pepper" 2> >(grep -v 'GtkDialog' >&2));
echo "CREATING /tmp/secret.june"
echo "$g1_salt" > /tmp/secret.june
echo "$g1_pepper" >> /tmp/secret.june
echo "________________ https://gchange.fr ________________" > /tmp/secret.all
cat /tmp/secret.june >> /tmp/secret.all
########################################################################
echo "CREATING /tmp/secret.dunikey"
python3 ~/.zen/astroport/zen/tools/key_create_dunikey.py "$g1_salt" "$g1_pepper"
g1pub=$(cat /tmp/secret.dunikey | grep "pub" | cut -d ' ' -f 2)
g1sec=$(cat /tmp/secret.dunikey | grep "sec" | cut -d ' ' -f 2)
echo "" >> /tmp/secret.all
echo "_________________ https://cesium.app _______________" >> /tmp/secret.all
cat /tmp/secret.dunikey >> /tmp/secret.all
echo "" >> /tmp/secret.all
########################################################################
echo "CREATING /tmp/config.ipfs"
ipfs_ID=$(python3 ~/.zen/astroport/zen/tools/create_ipfsnodeid_from_tmp_secret.dunikey.py)
echo $ipfs_ID > /tmp/secret.ipfs && source /tmp/secret.ipfs
jq -r --arg PeerID "$PeerID" '.Identity.PeerID=$PeerID' ~/.ipfs/config > /tmp/config.tmp
jq -r --arg PrivKEY "$PrivKEY" '.Identity.PrivKey=$PrivKEY' /tmp/config.tmp > /tmp/config.ipfs
rm /tmp/config.tmp
echo "" >> /tmp/secret.all
echo "_____________________ IPFS ________________________" >> /tmp/secret.all
cat /tmp/secret.ipfs >> /tmp/secret.all
echo "" >> /tmp/secret.all
## Which directory to sync with IPFS
IPFS_sync_directory=$(zenity --file-selection --title="Choisissez le répertoire à partager par IPFS avec vos amis" --directory 2> >(grep -v 'GtkDialog' >&2))
[[ ! -d $IPFS_sync_directory ]] && zenity --warning --width 300 --text "Aucun répertoire... ANNULATION" 2> >(grep -v 'GtkDialog' >&2) && cleanTMP && exit 1
echo "IPFS_SYNC_DIR=$IPFS_sync_directory" >> /tmp/secret.all
########################################################################
echo "Copy new keys?"
zenity --width=971 --height=600 --title "Validation de votre configuration" --text-info --filename="/tmp/secret.all" 2> >(grep -v 'GtkDialog' >&2)
[ $? == 1 ] && cleanTMP && exit 1
[[ -f ~/.zen/secret.dunikey.old ]] && zenity --warning --width 300 --text "ANNULATION! Il existe déjà une sauvegarde d'anciennes clefs... support@qo-op.com" 2> >(grep -v 'GtkDialog' >&2) && cleanTMP && exit 1
mv ~/.zen/secret.june ~/.zen/secret.june.old
mv /tmp/secret.june ~/.zen/secret.june
mv ~/.zen/secret.dunikey ~/.zen/secret.dunikey.old
mv /tmp/secret.dunikey ~/.zen/secret.dunikey
mv ~/.zen/secret.ipfs ~/.zen/secret.ipfs.old
mv /tmp/secret.ipfs ~/.zen/secret.ipfs
mv ~/.ipfs/config ~/.ipfs/config.old
mv /tmp/config.ipfs ~/.ipfs/config
rm /tmp/secret.all
# WRITE ~/.zen/ipfs.sync CONFIG
echo "IPFS_SYNC_DIR=$IPFS_sync_directory" > ~/.zen/ipfs.sync
# CREATE gchange+ profile
# cd ~/.zen/astroport/zen/jaklis
# ./jaklis.py --key "~/.zen/secret.dunikey" --node "https://data.gchange.fr" set --name "$g1_profil" --avatar "~/.zen/astroport/logo.png"
# ERROR
echo "OK. Restart now"
zenity --warning --width 300 --text "Veuillez redémarrer l'ordinateur pour activer votre configuration..." 2> >(grep -v 'GtkDialog' >&2)
exit 0

207
ISOconfig.sh Executable file
View File

@ -0,0 +1,207 @@
#!/bin/bash
########################################################################
# Author: Fred (support@qo-op.com)
# Version: 2020.12.05
# License: AGPL-3.0 (https://choosealicense.com/licenses/agpl-3.0/)
########################################################################
# AUTOMATIC version of interactive 1stRUNconfig.sh
# This script can run from ~/.config/autostart/Astroport_X_config.desktop
#
########################################################################
# Create secret key files
# ~/.zen/secret.june
# ~/.zen/secret.dunikey
# ~/.zen/secret.ipfs & /tmp/config.ipfs
# ~/.zen/ipfs.sync
########################################################################
# CHECK IF CONFIG ALREADY DONE !! Remove ~/.zen/ipfs ~/.zen/secret ~/.zen/ipfs.sync
if [[ -f ~/.zen/ipfs.sync ]]; then
echo "CONFIG ALREADY DONE"
source ~/.zen/ipfs.sync
# NEW BOOT! SEND ipfstryme message to my friends...
cd ~/.zen/astroport/zen/jaklis
# GET LIST of issuer(s) who likes me
for liking_me in $(./jaklis.py like | jq -r '.likes[].issuer');
do
# CHECk if I am liking him either
friend_of_mine=$(./jaklis.py like -p $liking_me | jq -r '.yours');
echo "Sending IPFSTRYME message to $liking_me"
[[ $friend_of_mine != null ]] && ./jaklis.py send -d $liking_me -t "ipfstryme" -f ~/.zen/ipfs/.${IPFSNODEID}/tryme.addr
done
cd -
exit 0
fi
# CHECK INTERNET CONNECTIVITY !!
ping -q -w 1 -c 1 `ip r | grep default | cut -d ' ' -f 3` > /dev/null && echo ok || (echo "NO INTERNET CONNEXION" && exit 1)
########################################################################
########################################################################
echo "CREATING Gchange credentials"
########################################################################
salt="$(~/.zen/astroport/zen/tools/diceware.sh 3 | xargs)"
[[ $salt == "" ]] && echo "ERROR" && exit 1
pepper="$(~/.zen/astroport/zen/tools/diceware.sh 3 | xargs)"
g1_salt="$salt"
g1_pepper="$pepper"
echo "CREATING /tmp/secret.june"
echo "$g1_salt" > /tmp/secret.june
echo "$g1_pepper" >> /tmp/secret.june
########################################################################
########################################################################
echo "CREATING /tmp/secret.dunikey"
########################################################################
python3 ~/.zen/astroport/zen/tools/key_create_dunikey.py "$g1_salt" "$g1_pepper"
g1pub=$(cat /tmp/secret.dunikey | grep "pub" | cut -d ' ' -f 2)
g1sec=$(cat /tmp/secret.dunikey | grep "sec" | cut -d ' ' -f 2)
########################################################################
########################################################################
echo "CREATING /tmp/config.ipfs"
########################################################################
ipfs_ID=$(python3 ~/.zen/astroport/zen/tools/create_ipfsnodeid_from_tmp_secret.dunikey.py)
echo $ipfs_ID > /tmp/secret.ipfs && source /tmp/secret.ipfs
[[ $PrivKEY == "" ]] && echo "ERROR" && exit 1
jq -r --arg PeerID "$PeerID" '.Identity.PeerID=$PeerID' ~/.ipfs/config > /tmp/config.tmp
jq -r --arg PrivKEY "$PrivKEY" '.Identity.PrivKey=$PrivKEY' /tmp/config.tmp > /tmp/config.ipfs
rm /tmp/config.tmp
#
IPFSNODEID=$PeerID
echo $IPFSNODEID
## Declare directory transfered in IPFS
IPFS_sync_directory="$HOME/astroport"
########################################################################
# INSTALL KEYS
########################################################################
timestamp=$(date -u +%s%N | cut -b1-13)
[[ -f ~/.zen/secret.june ]] && mv ~/.zen/secret.june ~/.zen/secret.june.old.$timestamp
mv /tmp/secret.june ~/.zen/secret.june
[[ -f ~/.zen/secret.dunikey ]] && mv ~/.zen/secret.dunikey ~/.zen/secret.dunikey.old.$timestamp
mv /tmp/secret.dunikey ~/.zen/secret.dunikey
[[ -f ~/.zen/secret.ipfs ]] && mv ~/.zen/secret.ipfs ~/.zen/secret.ipfs.old.$timestamp
mv /tmp/secret.ipfs ~/.zen/secret.ipfs
[[ -f ~/.ipfs/config ]] && mv ~/.ipfs/config ~/.ipfs/config.old.$timestamp
mv /tmp/config.ipfs ~/.ipfs/config
########################################################################
echo "INIT ~/.zen/ipfs/.${IPFSNODEID}"
########################################################################
rm -Rf ~/.zen/ipfs
mkdir -p ~/.zen/ipfs/.${IPFSNODEID}/G1SSB
########################################################################
# Give $XZUID to your (gchange friends) to add in Vstream Astroport and access your sharings
# IPNS link to "pastebin list" http://localhost:8181/ipns/$IPNSKEY/xbian/$XZUID
########################################################################
XZUID=$(~/.zen/astroport/zen/tools/diceware.sh 1 | xargs)${RANDOM:0:2}$(~/.zen/astroport/zen/tools/diceware.sh 1 | xargs)
echo "CREATE ~/.zen/ipfs/xbian/$XZUID"
mkdir -p ~/.zen/ipfs/xbian
touch ~/.zen/ipfs/xbian/$XZUID
# https://github.com/Kodi-vStream/venom-xbmc-addons/wiki/Voir-et-partager-sa-biblioth%C3%A8que-priv%C3%A9e#d%C3%A9clarer-des-films
echo "$XZUID" > ~/.zen/ipfs/.${IPFSNODEID}/_xbian.zuid
########################################################################
########################################################################
echo "CREATE + profile"
########################################################################
cd ~/.zen/astroport/zen/jaklis
./jaklis.py -n "https://g1.data.e-is.pro" set --name "$XZUID" --avatar "$HOME/.zen/astroport/logo.png" #CESIUM+
./jaklis.py -n "https://data.gchange.fr" set --name "$XZUID" --avatar "$HOME/.zen/astroport/logo.png" #GCHANGE+
########################################################################
########################################################################
echo "BECOME FRIEND with oasis (1st bootstrap)"
########################################################################
./jaklis.py -n "https://g1.data.e-is.pro" like -p 2jQUH4HfHxdTesjCjvMCx1VJgA5AnpuvrWRq1swfRdsS -s 5
./jaklis.py -n "https://data.gchange.fr" like -p 2jQUH4HfHxdTesjCjvMCx1VJgA5AnpuvrWRq1swfRdsS -s 5
########################################################################
echo "RESTART ipfs"
########################################################################
sudo service ipfs restart
echo ".... WAIT for SWARM to connect ..."
sleep 10
ipfs swarm peers
########################################################################
echo 'EXTEND ~/.bashrc'
########################################################################
~/.zen/astroport/.install/update_bashrc.sh
echo "Configure .kodi/addons/plugin.video.vstream/resources/sites/astroport.py"
cp -f ~/.zen/astroport/.install/.kodi/addons/plugin.video.vstream/resources/sites/astroport.py \
~/.kodi/addons/plugin.video.vstream/resources/sites/astroport.py
# CREATE xbian IPNSKEY used to publish ~/.zen/ipfs_swarm/xbian (contains all XZUID pastebin files)
ipfs key rm xbian
IPNSKEY=$(ipfs key gen xbian)
sed -i "s/_IPNSKEY_/$IPNSKEY/g" ~/.kodi/addons/plugin.video.vstream/resources/sites/astroport.py
sed -i "s/_PROFIL_/$XZUID/g" ~/.kodi/addons/plugin.video.vstream/resources/sites/astroport.py
sed -i "s/_LOGIN_/$salt/g" ~/.kodi/addons/plugin.video.vstream/resources/sites/astroport.py
sed -i "s/_MDP_/$pepper/g" ~/.kodi/addons/plugin.video.vstream/resources/sites/astroport.py
~/.zen/astroport/zen/cesium_IPFS_swarm.sh
~/.zen/astroport/zen/ipfs_SWARM_refresh.sh
########################################################################
echo 'SEND "ipfstryme" message'
########################################################################
echo "" > ~/.zen/ipfs/.${IPFSNODEID}/tryme.addr # ERASE
for tryme in $(ipfs id | jq -r .Addresses[]);
do
isLAN=$(echo $tryme | cut -f3 -d '/' | grep -E "(^127\.)|(^192\.168\.)|(^fd42\:)|(^10\.)|(^172\.1[6-9]\.)|(^172\.2[0-9]\.)|(^172\.3[0-1]\.)|(^::1$)|(^[fF][cCdD])/")
[[ ! $isLAN && $tryme != "" ]] && echo "$tryme" >> ~/.zen/ipfs/.${IPFSNODEID}/tryme.addr && echo "$tryme"
done
echo 'SEND ipfstryme to oasis' # Add your bootstrap Pub here
./jaklis.py -n "https://g1.data.le-sou.org" send -d 2jQUH4HfHxdTesjCjvMCx1VJgA5AnpuvrWRq1swfRdsS -t "ipfstryme" -f ~/.zen/ipfs/.${IPFSNODEID}/tryme.addr
./jaklis.py -n "https://data.gchange.fr" send -d 2jQUH4HfHxdTesjCjvMCx1VJgA5AnpuvrWRq1swfRdsS -t "ipfstryme" -f ~/.zen/ipfs/.${IPFSNODEID}/tryme.addr
########################################################################
echo 'INSTALL Astroport cron_MINUTE'
########################################################################
~/.zen/astroport/zen/cron_VRFY.sh
# Run only once: comment /etc/rc.local (su - xbian -c "~/.zen/astroport/ISOconfig.sh")
# sudo sed -i s/su/\#su/g /etc/rc.local
# BETTER NOT: Send new 'ipfstryme' message on each boot is done instead
echo "CHANGE hostname"
astrxbian=$(hostname)
sudo sed -i "s/$astrxbian/$XZUID/g" /etc/hostname
sudo sed -i "s/$astrxbian/$XZUID/g" /etc/hosts
echo "CHANGE DNS" # Avoid provider restrictions
sudo mv /etc/resolv.conf /etc/resolv.conf.old
sudo cat > /etc/resolv.conf <<EOF
domain home
search home
nameserver 80.67.169.12 80.67.169.40 94.247.43.254 2001:67c:13e4:1::37
# FFDN.org opennic.org = ns8.he.de + ns5.ru
EOF
sudo chattr +i /etc/resolv.conf
# WRITE ~/.zen/ipfs.sync CONFIG (meaning DONE)
echo "IPFS_SYNC_DIR=$IPFS_sync_directory" > ~/.zen/ipfs.sync
# RESIZING / partition
# sudo btrfs filesystem resize max /
########################################################################
echo 'REBOOT NOW...'
########################################################################
sudo reboot
exit 0

177
README.md
View File

@ -1,14 +1,24 @@
# NOUVELLE VERSION
Le développement
```
___ __ __
/ | _____/ /__________ ____ ____ _____/ /_
/ /| | / ___/ __/ ___/ __ \/ __ \/ __ \/ ___/ __/
/ ___ |(__ ) /_/ / / /_/ / /_/ / /_/ / / / /_
/_/ |_/____/\__/_/ \____/ .___/\____/_/ \__/
/_/ |_/____/\__/_/ \____/ .___/\____/_/ \__/ / KODI
/_/
__HyperWeb 5D - Metavers Numérique centré sur l'Humain__
```
continue sur [Astroport/KODI - astrXbian](https://git.p2p.legal/axiom-team/astrXbian)
---
> ATTENTION ce code n'est plus maintenu... nous vous invitons désormais à utilisez [Astroport/KODI](https://git.p2p.legal/axiom-team/astrXbian)
# __Human Centric Telecommunication System__
## [is Not an Astroport](./ANA)
@ -21,6 +31,8 @@ An asynchronous, anoptic, friend of friend (P2P) network.
Le rêve d'un Internet sans GAFAM, sans Datacenter. Hébergé et opéré par nous tous...
Un réseau asynchrone, anoptique, qui fonctionne par ami d'ami (P2P).
[GROGol traduction](https://translate.google.fr/translate?sl=en&tl=fr&u=https%3A%2F%2Fgit.p2p.legal/axiom-team/astroport/src/master/README.md)
---
| FR | EN | DE | ES | PT | IT | NL | RU | PL |
@ -33,20 +45,50 @@ Un réseau asynchrone, anoptique, qui fonctionne par ami d'ami (P2P).
Astroport is an ecosystem of several open sources applications forming a global mesh of meshes restructuring the network from Humans point of view not Machine POV.
### It is autonomous, doesn't need permanent connectivity and is Human centered ONLY. [It behaves like The "BLOB creature"](https://www.youtube.com/results?search_query=blob+creature)
### It is autonomous, doesn't need permanent connectivity and is Human centered ONLY. [It behaves like The "BLOB creature"](https://git.p2p.legal/axiom-team/astroport#-help-our-open-collective-with-donations)
It's using:
- **ScuttleButt** as friendship, personnal blockchain & disconnected communication (SSB) layer
- **IPFS** as distributed storage, media transport & file sharing layer
- **Duniter/Ḡ1** Libre currency monetary layer
- **ScuttleButt** as friendship, relative confidence, personnal blockchain & asynchronous, disconnect friendly, communication (SSB) layer, and 5Mb max file size storage.
- **IPFS** as distributed storage, incremental backup, media transport & file sharing layer between friends through **Zen Contracts**.
- **Duniter** First Libre currency monetary layer. Based on a sidechain strict consensus blockchain producing a Libre Money called June (Ḡ1). Actual fixed conversion rate is **1 Ḡ1 = 100 Zen**
Astroport is forging a Key compatible with this 3 digital tools and Universe.
So you can use them together with Oasis, Cesium and Gchange.
### THE FLAVORS
Some extra interface are being developped. NextCloud. Minetest.
And plenty other to come...
Each hosted astroport station will be able to have different "flavors", i.e. different software interconnected with it.
To join Alpha stage #Swarm0
The base is a crystal with three branches, this is the Lapunta key in "The Castle in the Sky": G1 + SSB + IPFS.
The Lapunta key is the **responsible numerical identity which allows to start its relativistic #Swarm0** using the Astroport engine.
We can then add 'flavors' to the base which then becomes a Metaverse
**Metaverse is the experience of each of the interconnection of its information channels**
G1sms, Nextcloud, G1Dab, G1Tx, Cesium, Gchange, Transiscope, Oasis, Feedless, Youtube, Torrent, Minetest, etc...
We will even be able to add new applications simply ! It's everyone's taste in Metavers.
These tastes are like doors that we open or close to data flows thanks to the astroport, by its Stations (x64, Rpi, VirtualBox), its keys and your friends.
The **Minetest flavor**, which is actively developped, will teleport you into the private digital worlds of your Scuttlebutt friends.
The **Nextcloud flavor** will allow you a nearly infinite storage in the IPFS.
Applications connected to Astroport are considered as modules, synchronized channels with push/pull capacities, step by step integrated
1. Scraper / Pusher
2. API : Read / Write
3. IPFS full index/data conversion.
### Rapid overview how an App can become an Astroport Module and then be a DApp
In Astroport Loveland Metaverse every Station have a relative SSB view of the whole...
So many stations are part of the unique #Swarm0 relative to each "$YOU" Station.
Each Station have some software installed on it. Once "Fat Protocol Layer" is activated. **Your Astroport PC have new Power(S)**.
IPFS layer is always adapting to Half of your avalaible HDD space (better USB3 SSD ... technology ask @attilax)
Your LOCAL Apps can benefit from backup / replication / cryptographic file sharing / teleportation features !!
Depending on App and Data structure, different operations are requested.
[Get your App transformed to DApp is easy as 1, 2, 3](https://git.p2p.legal/axiom-team/astroport/src/master/g1sms/Readme.md)?
Want to join and try Alpha stage #Swarm0 ?
## #SWARM0
@ -58,7 +100,7 @@ To join Alpha stage #Swarm0
/_//_/ /____/ |__/|__/\__,_/_/ /_/ /_/ /_/\____/
```
Activated and meshed layers, your node will create its #Swarm0
Activated and meshed layers, your node will create and connect to its #Swarm0
A special view and access to its network and data through friends only.
#swarm0 is the inner IPFS Metaverse structure and shape the same way our SSB friends are.
@ -71,9 +113,9 @@ By default, shared ipfs data are encrypted (ed25519), but is not "private"...
Share the same ~/.ipfs/swarm.key with your friends to "HARDEN" your shield
## Installation: Debian 10 (armv7/arm64/amd64) and Ubuntu/Mint 64bits ONLY !
**WARNING: This is an alpha stage development! Please try... Open issues and help corrections PLEASE**
**WARNING: This is an alpha stage development! Please FOLLOW INSTRUCTIONS!!! Open issues and help corrections. Thank you.**
### 0 - OPTIONNAL : Create a new user "pi"
### 0 - OPTIONAL : Create a new user "pi"
Only if you don't have "ipfs daemon" already running !!
continue the install with the user you are already using instead.
@ -84,21 +126,41 @@ usermod -aG sudo pi
su - pi
```
### 1 - Automatic install
If you are sure about the code and you don't have .ssb and .ipfs folders, you can run automatic install:
```
curl -s https://git.p2p.legal/axiom-team/astroport/raw/master/install.sh | bash
```
:coffee:
### 1 - IPFS - **Install and start “ipfs daemon”**
Else you can follow steps 2,3 and 4 to check code gradually.
WE ENCOURAGE YOU TO READ CODE YOU ARE DOWNLOADING AND EXECUTING
### 2 - IPFS - **Install and start “ipfs daemon”**
* Semi manual (so you can read code)
**WE ENCOURAGE YOU TO ALWAYS READ CODE YOU ARE DOWNLOADING AND EXECUTING or trust a friend only!!**
---
#### JOINING FOUNDATION TEAM !!!
**IMPORTANT !!!**
- Read the [Pure bash Bible](https://github.com/dylanaraps/pure-bash-bible)
- DO NOT RUN AUTOMATIC INSTALL BUT DO "STEP BY STEP" CODE EXECUTION
- Do make your report and follow https://pad.p2p.legal/s/astroport-landing#
- Do you know https://asciinema.org/? Record your session as a movie (join it to your issues)
> WELCOME
* Semi manual (so you can run the code step by step)
```
# to do so
curl -s https://git.p2p.legal/axiom-team/astroport/raw/master/.install/ipfs_alone.sh -o /tmp/ipfsA.sh
xed /tmp/ipfsA.sh
# If you are happy with what you read and understood. RUN
geany /tmp/ipfsA.sh
# If you are happy with what you read and understood. RUN it
chmod +x /tmp/ipfsA.sh && /tmp/ipfsA.sh
```
* Full automatic (you trust this git depot)
* Full automatic (you trust this script from this git depot)
```
curl -s https://git.p2p.legal/axiom-team/astroport/raw/master/.install/ipfs_alone.sh | bash
@ -106,66 +168,71 @@ curl -s https://git.p2p.legal/axiom-team/astroport/raw/master/.install/ipfs_alon
[How your SSB and IPFS swarm are kept in sync](https://git.p2p.legal/axiom-team/astroport/src/master/zen/ssb_IPFS_swarm.sh)?
### 2 - G1 SSB - **Create your “secrets” 🔑 from credentials and activate your Astroport Station 🛸**
### 3 - G1 SSB - **Create your “secrets” 🔑 from credentials and activate your Astroport Station 🛸**
[Look at the code generating your G1SSB Identity](https://git.p2p.legal/axiom-team/astroport/src/master/zen/tools/make_G1SSB_secret.sh).
```
# ONCE YOU READ and AGREE. Run TrustFull QUICK Install !!
# ONCE YOU READ, RUN step by step and AGREE !!! Run QUICK Install...
curl -s https://git.p2p.legal/axiom-team/astroport/raw/master/zen/tools/make_G1SSB_secret.sh | bash
```
**Astroport #Swarm0 makes you enter a "Virtual Private IPFS Swarm" shared with Scuttlebutt friends**
All files are in ```~/.zen``` and ```~/.ssb_astroport```
All files are located in ```~/.zen``` and ```~/.ssb_astroport``` (linked to ```~/.ssb```)
You Astroport Station is working as a "multi-channel switch"
Every minute, it "listen" to all its connected channels and run small routines to make actions between them.
Your Astroport Station is working as a "multi-channel Switch", Apps are seen as push/pull communication channels.
Every minute, it "listens" to all its connected "channels" and run small routines to make actions between them.
During alpha period, your Station will ```git pull``` fresh code from this git every 5 mn.
**So you benefit from fresh code** located in ```~/.zen/astroport```
**Fresh code** is located in ```~/.zen/astroport```
**IMPORTANT!! BACKUP YOUR KEYS!**
```
~/.zen/secret.astroport.key
~/.zen/secret.dunikey
~/.ssb/secret ( + ".json's" for easier SSB recovery)
~/.zen/secret.astroport.key # this Station $WHOAMI "LaPunta" Key, containing login/password to create your "gchange account"
~/.zen/secret.dunikey # Cesium Key, the June G1 wallet of you Key.
~/.ssb/secret ( + ".json's" for easier SSB recovery) # ScuttleButt ID + connectors
```
KEEP them safe.
KEEP them safe.
This way you could recover your data from #Swarm0
### Portal - LOVELand - Interface
### 4 - DEMONSTRATION _ LOVELand _ Metaverse Interface: https://oasis.astroport.com
Local Web Control Interface (& [CopyLaRadio](https://copylaradio.com) experimental Layer)
**$YOU Local basic 100km Web Control for Zen p2p markets**
(+ coming [Minetest](https://minetest.net), [NextCloud](https://nextcloud.com/), [CopyLaRadio](https://www.copylaradio.com), .... **Adding your App is easy as "1 2 3"**)
```
curl -s https://git.p2p.legal/axiom-team/astroport/raw/master/.install/loveland.sh | bash
```
## Quick tour of "flavours" Astroport Stations could have:
---
## Quick tour of Astroport Stations "flavours" (alpha):
- A 100 km local area Information System around your Cesium location
- [gchange_MONITOR!!](https://git.p2p.legal/axiom-team/astroport/src/master/zen/gchange_MONITOR.sh) Connect to [Gchange](https://gchange.fr) market
- A Nextcloud / IPFS Hub [Rock64 experimental Station](https://rock64.p2p.legal/)
- A Nextcloud / IPFS Hub [Cloud Attilax Station](https://cloudattilax.axiom-team.fr/) [Rock64 Station](https://rock64.p2p.legal/)
- Minetest Mini Worlds (SSB in sync) [Txmn.tk experimental Station](https://diaspora.normandie-libre.fr/posts/171127)
- Minetest Mini Worlds (SSB in sync) [Txmn.tk Station](https://diaspora.normandie-libre.fr/posts/171127)
- **Explore ScuttleButt UNIVERSE**
- Choose your prefered ScuttleButt client to reach the Metaverse
- [Patchwork](http://dinosaur.is/patchwork-downloader/)
- [Oasis](https://github.com/fraction/oasis)
- [Feedless](https://github.com/rogeriochaves/feedless)
- [Manyverse](https://manyver.se)
- [others](https://scuttlebot.io/apps/index.html) & plenty to come !!
- **Experimentations in SSB & G1 UNIVERSE**
- **Experimentations with SSB & G1 UNIVERSE**
- Reward SSB likes with [ssb-g1-tip](https://git.p2p.legal/axiom-team/ssb-g1-tip)
- **Experimentations in IPFS UNIVERSE**
- **Experimentations into IPFS Zen UNIVERSE**
- Copy [Audio](https://git.p2p.legal/axiom-team/astroport/src/master/zen/ssb_GET_zenyta.sh) and [Video](https://git.p2p.legal/axiom-team/astroport/src/master/zen/ssb_GET_zenytv.sh) from Youtube.
- Publish [contracts in ZenTag](https://git.p2p.legal/axiom-team/astroport/src/master/zen/zen_MAKE.sh) IPNS link to control ipfs availability of files.
- Publish [contracts in ZenTag](https://git.p2p.legal/axiom-team/astroport/src/master/zen/zen_MAKE.sh)
- ZenTag counters, IPNS nano DHT to control ipfs availability of files.
![](https://pad.p2p.legal/uploads/upload_bfcde4526535bce2cfb12c2e0497587d.png)
@ -182,13 +249,19 @@ Chat with us https://chat.axiom-team.fr/channel/astroport
/ \\ //\ |\ || | /
\_X \/\//--\| \|| _|_\_ #HyperWeb 5D
# BASED ON GNU CORE BASH TECHNOLOGY
# BUILT FROM GNU CORE BASH TECHNOLOGY
https://www.gnu.org/software/coreutils/
```
---
Maintainers @qo-op & @poka & ...
# [OASIS RULES, Docs and Roadmap](https://git.p2p.legal/axiom-team/astroport/src/master/g1sms/Readme.md)
Participating @attilax @poka @josselinchevalay @ben @mlsuyt @tuxmain @qo-op @manutopik @yyy @borispaing @paulart @guenoel @jeanluc @nox @pruls @cel @andrestaltz @Dan ... I have to stop... to many people...
# EXERNAL DOCUMENTATION
- [IPFS CLI commands](https://docs.ipfs.io/reference/api/cli/)
- [sbotc documentation and examples](https://pad.p2p.legal/scuttlebot#sbotc--documentation)
KEEP COOL, BE SAFE, BE FREE
```
@ -199,3 +272,29 @@ KEEP COOL, BE SAFE, BE FREE
/____/\___/_/ /_/
```
### Astroport is Human centered & Nature inspired
- Similar to Organic Life Form
[![Blob creature](https://git.p2p.legal/axiom-team/astroport/raw/master/blob.gif)](https://www.youtube.com/watch?v=W_FaOWZQdz0)
[![#Swarm0 Clusters](https://git.p2p.legal/axiom-team/astroport/raw/master/doc/images/LIFE.gif)](http://www.ventrella.com/Clusters/)
- Devil/angel Game resolver :
- [SSB viewer link](https://viewer.scuttlebot.io/%25TzYboJss10k83csj3khLkGGc5km9zoR%2FAx6RG6z6yEo%3D.sha256)
- [Youtube link](https://www.youtube.com/watch?v=sxiKlOK3EJY)
- [#Swarm0 link](http://127.0.0.1:8080/ipfs/QmXs9374jUX6y8s3rSYxHb9LtkCKCxXGGwAVMbQgWBTbJa/sxiKlOK3EJY.mp4)
# [>>>>>>> Help our Open Collective with DONATIONS](https://opencollective.com/monnaie-libre)
### Web 2.0 is dangerous!! You only have window and an apple already biten.
Actual Internet is a place full of virus. But we are lucky a **Free Software Universe is lying inside of it**.
Now you must KNOW it exists, to be SAFE!
[HOW MANY PEOPLE ARE ALREADY OWNING YOUR DATA ???](https://monitor.firefox.com/) **<<< check your "digital ghost"**
> WE are building the **"HyperWeb Cyberspace"** with Base Stations and "Spacecraft(s) UX" (ZApp)
[Discover "LOVE Land" the 1st Libre Metaverse interface, a living digital space](https://oasis.astroport.com)

11147
REVE.sh Executable file

File diff suppressed because it is too large Load Diff

BIN
blob.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 MiB

View File

@ -1,139 +0,0 @@
#!/bin/bash
########################################################################
# Author: Fred (support@qo-op.com)
# Version: 0.3
# License: AGPL-3.0 (https://choosealicense.com/licenses/agpl-3.0/)
########################################################################
# ASTROPORT COMMAND RECEIVER & DISPACHER
# Rise Up by unid@chan && Run corresponding command.sh
########################################################################
# NOT WORKING YET
# TODO! CONVERT G1SMS+ FROM PHONE TO MULTICHANNEL
########################################################################
MY_PATH="`dirname \"$0\"`" # relative
MY_PATH="`( cd \"$MY_PATH\" && pwd )`" # absolutized and normalized
source ./g1sms/functions.sh
exit 0
# REWRITING .... NEEDED
SOURCE="$1" # id@channel
COMMAND="$2" # command received (message, comment, ...)
[[ $SOURCE == "" ]] && SOURCE="unid@channel"
[[ $COMMAND == "" ]] && COMMAND="cmd arg1 arg2 ..."
SOURCEH=$(echo -n $SOURCE | sha512sum | cut -d ' ' -f 1) # Hash SOURCE
SRC=$(echo "$SOURCE" | cut -d '@' -f 1)
CHAN=$(echo "$SOURCE" | cut -d '@' -f 2)
CMD=$(echo "$COMMAND" | awk '{print toupper($1)}') # CMD is first word
########################################################################
# ANTI SPAM
##################################################################
NOspam
##################################################################
# Handle commands CMD
##################################################################
case "$CMD" in
# RAZ MEMERUID?
RAZ)
MEMBERUID=$(echo "$COMMAND" | awk '{print $2}' | grep -E "([A-Za-z0-9\-\_]+$)")
./shell/chan_RAZ.sh "$SOURCE" "$MEMBERUID"&
;;
# HELP
HELP)
./shell/chan_HELP.sh "$SOURCE" &
;;
# NEW MEMERUID?
NEW)
MEMBERUID=$(echo "$COMMAND" | awk '{print $2}' | grep -E "([A-Za-z0-9\-\_]+$)")
./shell/chan_NEW.sh "$SOURCE" "$MEMBERUID" &
;;
# PAY DESTINATION! MONEY!
PAY)
DESTINATION=$(echo "$COMMAND" | awk '{print tolower($2)}' | grep -E "[a-z0-9._%+-]+@[a-z0-9._%+-]")
MONEY=$(echo "$COMMAND" | awk '{print $3}' | grep -E "^\-?[0-9]+$")
if [[ "$DEST" != "" && "$MONEY" != "" ]]; then
./shell/chan_PAY.sh "$SOURCE" "$DEST" "$MONEY" &
else
./shell/chan_ERROR.sh "$SOURCE" "PAY DESTINATION! MONEY!" &
fi
;;
# VIR AMOUNT! VIRDEST! PERIOD? TIME?
VIR)
AMOUNT=$(echo "$COMMAND" | awk '{print $2}' | grep -E "^\-?[0-9]+$")
VIRDEST=$(echo "$COMMAND" | awk '{print $3}' | grep -E "([A-Za-z0-9\-\_]+$)")
PERIOD=$(echo "$COMMAND" | awk '{print toupper($4)}' | grep -E "([A-Za-z0-9\-\_]+$)")
TIME=$(echo "$COMMAND" | awk '{print $5}' | grep -E "^\-?[0-9]+$")
if [[ "$VIRDEST" != "" && "$AMOUNT" != "" && "$PERIOD" != "" && "$TIME" != "" ]]; then
./shell/chan_VIR.sh "$SOURCE" "$VIRDEST" "$AMOUNT" "$PERIOD" "$TIME" &
else
./shell/chan_ERROR.sh "$SOURCE" "VIR AMOUNT! VIRDEST! PERIOD? TIME?" &
fi
;;
# BAL
BAL)
./shell/chan_COUNT.sh "$SOURCE" &
;;
# EMAIL MAIL!
EMAIL)
MAIL=$(echo "$COMMAND" | awk '{print tolower($2)}' | grep -E "[a-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,4}")
if [[ "$MAIL" != "" ]]; then
./shell/chan_EMAIL.sh "$SOURCE" "$MAIL" &
else
./shell/chan_ERROR.sh "$SOURCE" "EMAIL MAIL!" &
fi
;;
# BILL VAL!
BILL)
VAL=$(echo "$COMMAND" | awk '{print $2}' | grep -E "^\-?[0-9]+$")
if [[ "$VAL" != "" ]]; then
./shell/chan_BILLET.sh "$SOURCE" "$VAL" &
else
./shell/chan_ERROR.sh "$SOURCE" "BILL VAL!" &
fi
;;
# CHK W1! W2! W3? W4? W5? W6? W7?
CHK)
W1=$(echo "$COMMAND" | awk '{print tolower($2)}' | grep -E "^[a-z0-9]+$")
W2=$(echo "$COMMAND" | awk '{print tolower($3)}' | grep -E "^[a-z0-9]+$")
W3=$(echo "$COMMAND" | awk '{print tolower($4)}' | grep -E "^[a-z0-9]+$")
W4=$(echo "$COMMAND" | awk '{print tolower($5)}' | grep -E "^[a-z0-9]+$")
W5=$(echo "$COMMAND" | awk '{print tolower($6)}' | grep -E "^[a-z0-9]+$")
W6=$(echo "$COMMAND" | awk '{print tolower($7)}' | grep -E "^[a-z0-9]+$")
W7=$(echo "$COMMAND" | awk '{print tolower($8)}' | grep -E "^[a-z0-9]+$")
if [[ "$W1" != "" && "$W2" != "" ]]; then
./shell/chan_BILLETCHK.sh "$SOURCE" "$W1" "$W2" "$W3" "$W4" "$W5" "$W6" "$W7" &
else
./shell/chan_ERROR.sh "$SOURCE" "CHK W1! W2! W3? W4? W5? W6? W7?" &
fi
;;
CMD)
echo "==================================================="
echo "HELLO $SOURCE your ASTROPORT suit is $SOURCEH"
echo "RUN ./command_received.sh \"$SOURCE\" \"$COMMAND\""
;;
ACK|DELIVERED|PENDING|FAILED)
exit 0
;;
*)
echo "$SOURCE :: UNKNOWN $COMMAND"
exit 1
;;
esac
exit 0

View File

@ -8,43 +8,66 @@ MY_PATH="`dirname \"$0\"`" # relative
MY_PATH="`( cd \"$MY_PATH\" && pwd )`" # absolutized and normalized
ME="${0##*/}"
source $HOME/.profile
# CORRECT PATH
[[ ! $(echo $PATH | grep "/usr/local/bin") ]] && export PATH="$PATH:/usr/local/bin"
[[ ! $(echo $PATH | grep "HOME/.local/bin") ]] && export PATH="$PATH:$HOME/.local/bin"
[[ ! $(echo $PATH | grep "/usr/games") ]] && export PATH="$PATH:/usr/games"
#### INIT STATION PARAMETERS
[[ -f $MY_PATH/../secret.astroport.key ]] && source $MY_PATH/../secret.astroport.key # DEPRECATED now using ~/.bashrc
export YOU=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1)
source /home/$YOU/.profile
[[ $IPFSNODEID ]] && export IPFSNODEID=$IPFSNODEID || export IPFSNODEID=$(ipfs id -f='<id>\n')
########################################################################
# HELP DEVLT: Search "TODO" in code
# Write what you thing about the situation
# AND how you would like to 'fix it'...
# Then friends can read and enhance solution.
# WARNING: This script must be processing less than 1 minute, so do not charge too much this script
# _ _____ ____ _ _______ ________ ____
# | | / / | / __ \/ | / / _/ | / / ____/ / / /
# | | /| / / /| | / /_/ / |/ // // |/ / / __ / / /
# | |/ |/ / ___ |/ _, _/ /| // // /| / /_/ / /_/_/
# |__/|__/_/ |_/_/ |_/_/ |_/___/_/ |_/\____/ (_|_)
########################################################################
# NB: 'figlet' is used for labeling code trunks
########################################################################
### MODIFY WITH GREAT CARE!!! MUST BE BUG FREE !!!!!
### EVERY STATION RUN THIS SCRIPT EVERY MINUTE.
export isMinetestRunning=$(ps auxf --sort=+utime | grep -w minetest | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d ' ' -f 1)
export isG1smsRunning=$(ps auxf --sort=+utime | grep -w gammu | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d ' ' -f 1)
#isNextcloudRunning=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d ' ' -f 1)
### ACTIVATE DIFFERENT FLAVOURS
export isKodiRunning=$(ps auxf --sort=+utime | grep -w kodi | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d ' ' -f 1)
# ? isNextcloudRunning=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d ' ' -f 1)
### DETECT FLAVOURS (TODO: Publish and share into ipfs/.12D3KooW***/ )
########################################################################
[[ ! $(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d ' ' -f 1) ]] \
&& echo "ipfs daemon not running. EXIT" \
&& exit 1
cd $MY_PATH
export YOU=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1);
export IPFSNODEID=$(ipfs id -f='<id>\n')
# CORRECT PATH
[[ ! $(echo $PATH | grep "/usr/local/bin") ]] && export PATH="$PATH:/usr/local/bin"
[[ ! $(echo $PATH | grep "~/.local/bin") ]] && export PATH="$PATH:~/.local/bin"
ipfsnodeid=$(ipfs id -f='<id>\n')
g1pub=$(cat ~/.ssb/secret.dunikey | grep 'pub:' | cut -d ' ' -f 2)
# UNIVERSAL TIME (TODO ntpdate, but sudo problem)
# WHAT UNIVERSAL TIME is it ?
minute=$(date -u +%M)
heure=$(date -u +%H)
timebar="$heure:$minute"
jourdelasemaine=$(date +%w)
jourdumois=$(date +%d)
numerosemaine=$(date +%V)
dayoftheweek=$(date +%w)
dayofthemonth=$(date +%d)
weeknumber=$(date +%V)
echo $timebar
#
# _________
# / ____< /________ ___ _____
# / / __ / / ___/ __ `__ \/ ___/
#/ /_/ // (__ ) / / / / (__ )
#\____//_/____/_/ /_/ /_/____/
#
# $MY_PATH/g1sms/sms_ASTROPORT.sh
# TIME NTP SYNC: TODO: Problem being root (stickybit INSTALL?)
# G1Tx. G1sms. G1Dab Zen economy needs precise time sync (RpiZero !!)
# Tx rates is limited by Station time synchronisation.
# sudo ntpdate ntp.pool.org
# ____ _______ __ __
@ -55,15 +78,12 @@ echo $timebar
#
#
# ACTIVATE 5 MN "git pull" update
[[ $(($minute % 5)) == 0 ]] && sleep $((1 + RANDOM % 12)) && cd $MY_PATH && git pull
if [[ $(($minute % 5)) == 0 ]]; then
#######################################
sleep $((1 + RANDOM % 12))
git pull
fi
# __________ ____ __ ________ ___________
# / ___/ ___// __ ) \ \ / _/ __ \/ ____/ ___/
# \__ \\__ \/ __ | _____\ \ / // /_/ / /_ \__ \
# ___/ /__/ / /_/ / /_____/ / _/ // ____/ __/ ___/ /
# /____/____/_____/ /_/ /___/_/ /_/ /____/
#
# __ __ _____ ____
# __/ // /_/ ___/ ______ __________ ___ / __ \
# /_ _ __/\__ \ | /| / / __ `/ ___/ __ `__ \/ / / /
@ -71,8 +91,18 @@ echo $timebar
# /_//_/ /____/|__/|__/\__,_/_/ /_/ /_/ /_/\____/
#
##################################################################
# REFRESH IPFS SWARM DATA EVERY 12 minutes
[[ $(($minute % 12)) == 0 ]] && sleep $((1 + RANDOM % 10)) && $MY_PATH/zen/ssb_IPFS_swarm.sh
# REFRESH IPFS SWARM DATA EVERY 12 & 15 minutes
[[ $(($minute % 12)) == 0 ]] && sleep $((1 + RANDOM % 10)) && $MY_PATH/zen/gchange_IPFS_swarm.sh &
[[ $(($minute % 15)) == 0 ]] && sleep $((1 + RANDOM % 10)) && $MY_PATH/zen/ipfs_SWARM_refresh.sh &
# Transfert ~/astroport/films to IPFS and make Vstream/ASTROPORT indexes on IPNS
if [[ "$timebar" == "03:03" ]]; then
$MY_PATH/zen/xbian_vstream.sh &
fi
## TODO investigate could breaks "ipfs p2p" forwards ?
##################################################################
# _________ _______ __ _ __
@ -88,66 +118,79 @@ echo $timebar
##################################################################
##################################################################
# __ __ __
# __/ // /_____ ___ ____ __ __/ /__ __
# /_ _ __/_ / / _ \/ __ \/ / / / __/ | / /
# /_ _ __/ / /_/ __/ / / / /_/ / /_ | |/ /
# /_//_/ /___/\___/_/ /_/\__, /\__/ |___/
# /____/
# SSB message 2 "youtube-dl"
##################################################################
# RANDOMLY RUN SSB GET zenytv (avoid simultaneous run in swarm)
randh=$((1 + RANDOM % 24))
# [[ $(($heure % $randh)) == 0 ]] && sleep $((1 + RANDOM % 10)) && $MY_PATH/zen/ssb_GET_zenytv.sh
# MIDNIGHT:01 : ZENBOT CLEANING & UPDATE
##################################################################
randh=$((1 + RANDOM % 24))
# [[ $(($heure % $randh)) == 0 ]] && sleep $((1 + RANDOM % 10)) && $MY_PATH/zen/ssb_GET_zenyta.sh
##################################################################
if [[ "$timebar" == "00:01" ]]; then
echo '
# ____ ____ ____ ___
# / __ \/ __ \ _ / __ < /
# / / / / / / / (_) / / / / /
# / /_/ / /_/ / _ / /_/ / /
# \____/\____/ (_) \____/_/
#
# Clean & Upgrade + Log rotation + git pull
##################################################################
# MIDNIGHT:01 : ZENBOT CLEANING & UPDATE
if [[ "$timebar" == "00:01" ]]; then
sleep $((1 + RANDOM % 10))
# UPGRADE youtube-dl
# MAINTENANCE
'
sleep $((1 + RANDOM % 5)) ### Be careful if random sleep is not activated...
############################## That swarm could become an aggressive blob !!
### PEACE & LOVE software is processing... We are HyperWeb people here.
# DEFCON 5 quiet behaviour so Please keep cool, take care and be zen.
# GOOD BYE GOOGLE, AMAZON, FACEBOOK, APPLE, MICROSOFT. We don't need you.
##################################################################
# REFRESH & UPGRADE youtube-dl
youtube-dl --rm-cache-dir
youtube-dl -U
sleep $((1 + RANDOM % 10))
# LOG ROTATE EVERY SUNDAY
[[ $jourdelasemaine == 0 ]] && mv -f /tmp/astroport.log ~/.zen/astroport.$numerosemaine.log # LOG BACKUP FOR 1 YEAR !!
sleep $((1 + RANDOM % 10))
# GIT PULL
git pull # UPDATE CODE git pull
# Clear 24h ssb_GET markers
rm ~/.zen/zenytv.last.ts
rm ~/.zen/zenyta.last.ts
# SYNC SSB Friends with IPFS SWARM
$MY_PATH/zen/ssb_IPFS_swarm.sh
fi
#### DESYNC
sleep $((1 + RANDOM % 5))
##################################################################
# ssb_INIT + LOG ROTATE EVERY SUNDAY # TODO /var/log/ + logrotate (& tempfiles in /tmp in RAMFS)
if [[ $dayoftheweek == 0 ]]; then
$MY_PATH/zen/gchange_INIT.sh &
# ACTIVATE IF CRON LOGGING
#tar cvzf ~/.zen/astroport.$weeknumber.log.tgz /tmp/astroport.log # LOG BACKUP FOR 1 YEAR !!
fi
#### DESYNC
sleep $((1 + RANDOM % 5))
##################################################################
# _____ __ __ ___
# / ___// /_____ _________ _____ ____ / |/ /___ __ __
# \__ \/ __/ __ \/ ___/ __ `/ __ `/ _ \ / /|_/ / __ `/ |/_/
# ___/ / /_/ /_/ / / / /_/ / /_/ / __/ / / / / /_/ /> <
# /____/\__/\____/_/ \__,_/\__, /\___/ /_/ /_/\__,_/_/|_|
# /____/
# Always 1/2 HDD for IPFS size - dicotomic adaptation
# UPDATE ON 7th EVERY MONTH
# GIT UPDATE
./git-update.sh
git pull # UPDATE CODE git pull
##################################################################
echo '
_________ ______
____ ___ ____ /_ __/ | / ____/
/_ / / _ \/ __ \ / / / /| |/ / __
/ /_/ __/ / / / / / / ___ / /_/ /
/___/\___/_/ /_/ /_/ /_/ |_\____/
REFRESHing ZenTAG nano DHTs = Zen File ECONOMY
'
# ./zen/ipns_TAG_refresh.sh
##################################################################
if [[ $dayofthemonth == 7 ]]; then
availableDiskSize=$(df -P ~/ | awk 'NR>1{sum+=$4}END{print sum}')
diskSize="$((availableDiskSize / 2))"
ipfs config Datastore.StorageMax $diskSize
echo '
_____ __ __ ___
/ ___// /_____ _________ _____ ____ / |/ /___ __ __
\__ \/ __/ __ \/ ___/ __ `/ __ `/ _ \ / /|_/ / __ `/ |/_/
___/ / /_/ /_/ / / / /_/ / /_/ / __/ / / / / /_/ /> <
/____/\__/\____/_/ \__,_/\__, /\___/ /_/ /_/\__,_/_/|_|
/____/
# 1/2 HDD for IPFS size - dicotomic adaptation 7th EVERY MONTH
#
# TODO: Read parameters from ipfs, publish status to swarm, could be use for youtube-dl or other kind of heavy ipfs input Station election.
#
if [[ $jourdumois == 7 ]]; then
availableDiskSize=$(df -P ~/ | awk 'NR>1{sum+=$4}END{print sum}')
diskSize="$((availableDiskSize / 2))"
ipfs config Datastore.StorageMax $diskSize
'
echo "StorageMax = $diskSize"
fi
##################################################################
fi

Binary file not shown.

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,21 @@
/*!
* Font Awesome v4.6.3 by @davegandy - http://fontawesome.io - @fontawesome
* License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License)
*/
@import url('//use.fontawesome.com/releases/v4.6.3/css/font-awesome-css.min.css');
/* FONT PATH
* -------------------------- */
@font-face {
font-family: 'FontAwesome';
src: url('//use.fontawesome.com/releases/v4.6.3/fonts/fontawesome-webfont.eot');
src: url('//use.fontawesome.com/releases/v4.6.3/fonts/fontawesome-webfont.eot?#iefix') format('embedded-opentype'),
url('//use.fontawesome.com/releases/v4.6.3/fonts/fontawesome-webfont.woff2') format('woff2'),
url('//use.fontawesome.com/releases/v4.6.3/fonts/fontawesome-webfont.woff') format('woff'),
url('//use.fontawesome.com/releases/v4.6.3/fonts/fontawesome-webfont.ttf') format('truetype'),
url('//use.fontawesome.com/releases/v4.6.3/fonts/fontawesome-webfont.svg#fontawesomeregular') format('svg');
font-weight: normal;
font-style: normal;
}
/*
Embed code 8184005927
*/

View File

@ -0,0 +1,19 @@
window.FontAwesomeCdnConfig = {
autoA11y: {
enabled: true
},
asyncLoading: {
enabled: true,
},
reporting: {
enabled: true,
domains: "localhost, *.dev"
},
useUrl: "use.fontawesome.com",
faCdnUrl: "https://cdn.fontawesome.com:443",
code: "8184005927",
webFontLoaderVersion: "1.6.24"
};
!function(){function a(a){var b,c=[],d=document,e=d.documentElement.doScroll,f="DOMContentLoaded",g=(e?/^loaded|^c/:/^loaded|^i|^c/).test(d.readyState);g||d.addEventListener(f,b=function(){for(d.removeEventListener(f,b),g=1;b=c.shift();)b()}),g?setTimeout(a,0):c.push(a)}function b(a,b){var c=!1;return a.split(",").forEach(function(a){var d=new RegExp(a.trim().replace(".","\\.").replace("*","(.*)"));b.match(d)&&(c=!0)}),c}function c(a){"undefined"!=typeof MutationObserver&&new MutationObserver(a).observe(document,{childList:!0,subtree:!0})}function d(a){var b,c,d,e;a=a||"fa",b=document.querySelectorAll("."+a),Array.prototype.forEach.call(b,function(a){c=a.getAttribute("title"),a.setAttribute("aria-hidden","true"),d=a.nextElementSibling?!a.nextElementSibling.classList.contains("sr-only"):!0,c&&d&&(e=document.createElement("span"),e.innerHTML=c,e.classList.add("sr-only"),a.parentNode.insertBefore(e,a.nextSibling))})}!function(){function a(a){this.el=a;for(var b=a.className.replace(/^\s+|\s+$/g,"").split(/\s+/),c=0;c<b.length;c++)d.call(this,b[c])}function b(a,b,c){Object.defineProperty?Object.defineProperty(a,b,{get:c}):a.__defineGetter__(b,c)}if(!("undefined"==typeof window.Element||"classList"in document.documentElement)){var c=Array.prototype,d=c.push,e=c.splice,f=c.join;a.prototype={add:function(a){this.contains(a)||(d.call(this,a),this.el.className=this.toString())},contains:function(a){return-1!=this.el.className.indexOf(a)},item:function(a){return this[a]||null},remove:function(a){if(this.contains(a)){for(var b=0;b<this.length&&this[b]!=a;b++);e.call(this,b,1),this.el.className=this.toString()}},toString:function(){return f.call(this," ")},toggle:function(a){return this.contains(a)?this.remove(a):this.add(a),this.contains(a)}},window.DOMTokenList=a,b(Element.prototype,"classList",function(){return new a(this)})}}();var e,f,g,h,i,j,k,l,m,n,o={isIE:function(a,b){var c,d="IE",e=document.createElement("B"),f=document.documentElement;return a&&(d+=" "+a,b&&(d=b+" "+d)),e.innerHTML="<!--[if "+d+']><b id="fitest"></b><![endif]-->',f.appendChild(e),c=!!document.getElementById("fitest"),f.removeChild(e),c}},p={load:function(a){var b=document.createElement("link");b.href=a,b.media="all",b.rel="stylesheet",document.getElementsByTagName("head")[0].appendChild(b)},loadAsync:function(a,b,c,d){var e,f=document.createElement("script"),g={},h="n4",i=function(){},j=document.scripts[0];window.WebFontConfig||(window.WebFontConfig={}),g=window.WebFontConfig,g.custom||(g.custom={}),g.custom.families||(g.custom.families=[]),g.custom.urls||(g.custom.urls=[]),g.custom.testStrings||(g.custom.testStrings={}),g.custom.families.push(b),g.custom.urls.push(a),g.custom.testStrings[b]=c,e=g.fontactive||i,g.fontactive=function(a,c){var d=(window.FontAwesomeHooks||{}).loaded||i;e(a,c),b===a&&h===c&&d()},f.src=d,j.parentNode.insertBefore(f,j)}},q={load:function(a){var b=document.createElement("script"),c=document.scripts[0];b.src=a,c.parentNode.appendChild(b)}};if(window.FontAwesomeCdnConfig&&(e=window.FontAwesomeCdnConfig,f=e.useUrl,g=e.faCdnUrl,h=e.code,i="FontAwesome",j="fa",k="",l=e.webFontLoaderVersion,e.autoA11y.enabled&&(a(d.bind(d,"fa")),c(d.bind(d,"fa"))),e.reporting.enabled&&b(e.reporting.domains,location.host)&&q.load(g+"/js/stats.js"),n="https://"+f+"/"+h+".css",m="https://"+f+"/webfontloader/"+l+"/webfontloader.js",e.asyncLoading.enabled?p.loadAsync(n,i,k,m):p.load(n)),window.FortAwesomeConfig){var r;e=window.FortAwesomeConfig,f=e.useUrl,h=e.code,i=e.familyName,j=e.prefix,k=e.testString,l=e.webFontLoaderVersion,e.autoA11y.enabled&&(a(d.bind(d,j)),c(d.bind(d,j))),r=o.isIE(8,"lte")?h+"-sd":h,n="https://"+f+"/"+r+".css",m="https://use.fonticons.com/webfontloader/"+l+"/webfontloader.js",e.asyncLoading.enabled?p.loadAsync(n,i,k,m):p.load(n)}}();

View File

@ -0,0 +1,52 @@
<!DOCTYPE html>
<html style=""><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Marketo Forms 2 Cross Domain request proxy frame</title>
<script src="forms2.js"></script>
<script>
(function (){
var $ = MktoForms2.$;
if(!window.parent || window.parent == window){
return;
}
$(window).on("message", function (e){
var origin = e.originalEvent.origin;
var message = e.originalEvent.data;
try{
message = $.parseJSON(message);
}catch(ex){
return; //our messages are always JSON
}
if(message && message.mktoRequest && message.mktoRequest.ajaxParams){
var p = message.mktoRequest.ajaxParams;
var params = { type:"POST", dataType:"json", url:p.url, data:p.data, crossDomain:false, jsonp:false };
params.success = function (data){
window.parent.postMessage(JSON.stringify({
mktoResponse:{
"for":message.mktoRequest.id,
error:false,
data:data
}
}), origin);
}
params.error = function (error, code, errMessage){
var e = error.responseJSON || errMessage;
window.parent.postMessage(JSON.stringify({
mktoResponse:{
"for":message.mktoRequest.id,
error:true,
data:e
}
}), origin)
}
$.ajax(params);
}
});
window.parent.postMessage(JSON.stringify({mktoReady:true}), "*");
})()
</script>
</head>
<body>
<h2>This page is used by Marketo Forms 2 to proxy cross domain AJAX requests.</h2>
</body></html>

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,287 @@
(function(g){var window=this;/*
Copyright The Closure Library Authors.
SPDX-License-Identifier: Apache-2.0
*/
var A2=function(a){a.S("cardstatechange",g.YK(a)&&g.ZK(a)?1:0)},nsa=function(a){if(/-[a-z]/.test("pollChoiceIndex"))return null;
if(g.Zj&&a.dataset){if(g.Nc()&&!("pollChoiceIndex"in a.dataset))return null;a=a.dataset.pollChoiceIndex;return void 0===a?null:a}return a.getAttribute("data-"+g.jd("pollChoiceIndex"))},osa=function(a){return Math.pow(a,3)},psa=function(a){return 3*a*a-2*a*a*a},B2=function(a,b){var c=g.xo("use_default_events_client")?void 0:g.Qq;
(0,g.y)(b,function(d){d={csn:a,ve:g.Yr(d),eventType:4};var e={al:g.es(a),bj:a};"UNDEFINED_CSN"==a?g.rs("visualElementShown",d,e):c?g.fq("visualElementShown",d,c,e):g.Rq("visualElementShown",d,e)})},C2=function(a,b){var c=g.xo("use_default_events_client")?void 0:g.Qq;
(0,g.y)(b,function(d){var e=void 0;e=void 0===e?!1:e;d={csn:a,ve:g.Yr(d),eventType:e?16:8};e={al:g.es(a),bj:a,CE:e};"UNDEFINED_CSN"==a?g.rs("visualElementHidden",d,e):c?g.fq("visualElementHidden",d,c,e):g.Rq("visualElementHidden",d,e)})},F2=function(a){a=g.Pa(a);
delete D2[a];g.Mb(D2)&&E2&&E2.stop()},rsa=function(){E2||(E2=new g.I(function(){qsa()},20));
var a=E2;a.isActive()||a.start()},qsa=function(){var a=(0,g.H)();
g.zb(D2,function(b){ssa(b,a)});
g.Mb(D2)||rsa()},G2=function(a,b,c,d){g.Fn.call(this);
if(!Array.isArray(a)||!Array.isArray(b))throw Error("Start and end parameters must be arrays");if(a.length!=b.length)throw Error("Start and end points must be the same length");this.w=a;this.G=b;this.duration=c;this.C=d;this.coords=[];this.progress=this.F=0;this.B=null},ssa=function(a,b){b<a.startTime&&(a.endTime=b+a.endTime-a.startTime,a.startTime=b);
a.progress=(b-a.startTime)/(a.endTime-a.startTime);1<a.progress&&(a.progress=1);a.F=1E3/(b-a.B);a.B=b;tsa(a,a.progress);1==a.progress?(a.o=0,F2(a),a.Fc(),a.pm()):a.eb()&&a.Ut()},tsa=function(a,b){g.Ma(a.C)&&(b=a.C(b));
a.coords=Array(a.w.length);for(var c=0;c<a.w.length;c++)a.coords[c]=(a.G[c]-a.w[c])*b+a.w[c]},usa=function(a,b){g.Je.call(this,a);
this.coords=b.coords;this.x=b.coords[0];this.y=b.coords[1];this.z=b.coords[2];this.duration=b.duration;this.progress=b.progress;this.fps=b.F;this.state=b.o},H2=function(a,b,c,d,e){G2.call(this,b,c,d,e);
this.element=a},I2=function(a,b,c,d,e){if(2!=b.length||2!=c.length)throw Error("Start and end points must be 2D");
H2.call(this,a,b,c,d,e)},J2=function(a){g.A.call(this);
this.u=a||window;this.o=[]},vsa=function(a,b,c,d){c=(0,g.x)(c,d||a.u);
b=g.Np(b,"change",c,"iv-card-poll-choice-input");a.o.push(b)},K2=function(a){return a.baseUrl||null},L2=function(a,b){return(0,g.ue)((0,g.Cc)(a,b,void 0),function(c){return!!c})},wsa=function(a,b,c){function d(tb){var nb=tb.hovercardButton;
if(!nb)return null;nb=nb.subscribeButtonRenderer;if(!nb)return null;var Yd=f(nb.unsubscribedButtonText),qf=f(nb.subscribedButtonText);if(nb.subscribed){var Kh=f(nb.subscriberCountWithUnsubscribeText);var Lh=f(nb.subscriberCountText)}else Kh=f(nb.subscriberCountText),Lh=f(nb.subscriberCountWithSubscribeText);var ag=null;return tb.signinEndpoint&&(ag=g.Hb(tb,"signinEndpoint","webNavigationEndpointData","url"),!ag)?null:Yd&&(qf||ag)?{subscribed:nb.subscribed,subscribeText:Yd,subscribeCount:Kh,unsubscribeText:qf,
unsubscribeCount:Lh,enabled:nb.enabled,signinUrl:ag,classic:tb.useClassicSubscribeButton}:null}
function e(tb){if(tb){var nb=[],Yd=tb.videoId;Yd&&nb.push("v="+Yd);(Yd=tb.playlistId)&&nb.push("list="+Yd);(tb=tb.startTimeSeconds)&&nb.push("t="+tb);return"/watch?"+nb.join("&")}}
function f(tb){if(!tb)return null;var nb=tb.simpleText;return nb?nb:tb.runs?(0,g.Cc)(tb.runs,function(Yd){return Yd.text}).join(""):null}
b=b.endscreenElementRenderer;if(!b)return null;var k=b.style,l=b.endpoint||{},m=null,n=null,p=null,t=null,u=null,z=null,C=!1,D=null,E=null,F=null,G=null,fa=null;if("VIDEO"==k)m=l.urlEndpoint?l.urlEndpoint.url:e(l.watchEndpoint),n=!1,p=a,t=f(b.videoDuration);else if("PLAYLIST"==k)m=l.urlEndpoint?l.urlEndpoint.url:e(l.watchEndpoint),n=!1,p=a,u=f(b.playlistLength);else if("CHANNEL"==k){if(C=g.Hb(l,"browseEndpoint","browseId"))z=C,m="/channel/"+z;n=!1;p="new";(C=!!b.isSubscribe)?D=d(b):E=f(b.subscribersText)}else"WEBSITE"==
k?((F=g.Hb(l,"urlEndpoint","url"))&&(m=F),n=!0,p="new",F=b.icon.thumbnails[0].url):"CREATOR_MERCHANDISE"==k&&(b.productPrice&&(G=f(b.productPrice)),b.additionalFeesText&&(fa=f(b.additionalFeesText)),(n=g.Hb(l,"urlEndpoint","url"))&&(m=n),n=!0,p="new");a=g.Hb(b,"title","accessibility","accessibilityData","label");var oa=b.endpoint?b.endpoint.clickTrackingParams:null,kc="";if(b.metadata){var Rc=f(b.metadata);Rc&&(kc=Rc)}return{id:"element-"+c,type:k,title:f(b.title),metadata:kc,callToAction:f(b.callToAction),
Ow:b.image,iconUrl:F,left:parseFloat(b.left),width:parseFloat(b.width),top:parseFloat(b.top),aspectRatio:parseFloat(b.aspectRatio),startMs:parseInt(b.startMs,10),endMs:parseInt(b.endMs,10),videoDuration:t,playlistLength:u,channelId:z,subscribeButton:D,subscribersText:E,isSubscribe:C,targetUrl:m,cG:n,Ob:{itct:oa},LO:p,Rk:a?a:null,gG:b.isPlaceholder,impressionUrls:L2(b.impressionUrls||[],K2),UF:L2(b.hovercardShowUrls||[],K2),clickUrls:L2(l.loggingUrls||[],K2),visualElement:g.Wr(b.trackingParams),productPrice:G,
additionalFeesText:fa}},M2=function(a,b){var c={};
c.startMs=parseInt(a.startMs,10);c.impressionUrls=L2(a.impressionUrls||[],K2);a.trackingParams&&(c.visualElement=g.Wr(a.trackingParams));c.elements=L2(a.elements||[],function(d,e){return wsa(b,d,e)});
return c},N2=function(a){g.vL.call(this,a);
this.A=this.u=null;this.o={};this.F={};this.C=this.w=null;this.I=[];a=a.N();this.P=g.Ry(a)||g.Ty(a);this.M=!0;this.G=0;this.B=new g.Gr(this);g.B(this,this.B);this.B.L(this.player,g.lC("creatorendscreen"),this.UG);this.B.L(this.player,"crx_creatorendscreen",this.VG);this.B.L(this.player,"resize",this.Xy);this.B.L(window,"focus",this.JN);this.load();var b=g.oe("STYLE");(document.getElementsByTagName("HEAD")[0]||document.body).appendChild(b);g.Ge(this,function(){g.te(b)});
b.sheet&&(b.sheet.insertRule(".ytp-ce-playlist-icon {background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASBAMAAACk4JNkAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAIVBMVEVMaXGzs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7P///91E4wTAAAACXRSTlMArBbpVOtYrReN+x2FAAAAAWJLR0QKaND0VgAAACFJREFUCNdjYCAWzIQAFBaZ6hgVYLKcJnBWGEyWvYGASwCXtBf7m4i3CQAAAABJRU5ErkJggg==) no-repeat center;background-size:18px;width:18px;height:18px}",0),b.sheet.insertRule(".ytp-ce-size-853 .ytp-ce-playlist-icon, .ytp-ce-size-1280 .ytp-ce-playlist-icon, .ytp-ce-size-1920 .ytp-ce-playlist-icon {background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYBAMAAAASWSDLAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAJ1BMVEVMaXGzs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7P///9RfzIKAAAAC3RSTlMAvDeyLvxYtDK9Ogx4T1QAAAABYktHRAyBs1FjAAAAK0lEQVQY02NgoBjshgO8HJoYwKiAMGAD92YHJM7uMCTO9gaEHs4FlPuZAQC8Fj8x/xHjxwAAAABJRU5ErkJggg==) no-repeat center;background-size:24px;width:24px;height:24px}",
0))},xsa=function(a){return a.player.getVideoData().lc?"current":a.P?"new":"current"},O2=function(a){return"creator-endscreen-editor"===a.player.N().playerStyle},P2=function(a,b,c){c=void 0===c?!0:c;
g.fR(a.player.app,"creatorendscreen",void 0);a.w&&(a.w.dispose(),a.w=null,a.C.dispose(),a.C=null);for(var d in a.o)a.o[d].dispose();a.o={};a.F={};0<a.I.length&&(a.I.forEach(function(l){l.dispose()}),a.I.length=0);
a.G=0;if((a.u=b)&&b.elements){c&&ysa(a);c=[];d=new g.iC(b.startMs,0x7ffffffffffff,{id:"ytp-ce-in-endscreen",namespace:"creatorendscreen"});c.push(d);a.player.N().o||(a.w=new g.R({D:"div",H:"ytp-ce-shadow"}),g.iL(a.player,a.w.element,4),a.C=new g.lN(a.w,200));for(d=0;d<b.elements.length;++d){var e=b.elements[d],f=zsa(a,e);a.o[e.id]=f;a.F[e.id]=e;g.iL(a.player,f.element,4);var k=new g.iC(e.startMs,e.endMs,{id:"ytp-ce-element-"+e.id,namespace:"creatorendscreen"});c.push(k);Asa(a,f,e)}g.eL(a.player,c);
a.Xy()}},ysa=function(a){var b=g.bs(),c=g.ds();
c&&b&&a.u.visualElement&&g.ys(c,b,a.u.visualElement)},zsa=function(a,b){var c=null;
switch(b.type){case "VIDEO":c={D:"div",Y:["ytp-ce-element","ytp-ce-video"],O:{tabindex:"0","aria-label":b.Rk||"","aria-hidden":"true"},J:[{D:"div",H:"ytp-ce-element-shadow"},{D:"div",H:"ytp-ce-covering-image",O:Q2(b)},{D:"div",H:"ytp-ce-covering-shadow-top"},{D:"a",H:"ytp-ce-covering-overlay",O:{href:R2(a,b.targetUrl),tabindex:"-1"},J:[{D:"div",Y:["ytp-ce-video-title","yt-ui-ellipsis","yt-ui-ellipsis-2"],O:{dir:g.Ln(b.title||"")},W:b.title},{D:"div",H:"ytp-ce-video-duration",W:b.videoDuration}]}]};
c=new g.R(c);break;case "PLAYLIST":c={D:"div",Y:["ytp-ce-element","ytp-ce-playlist"],O:{tabindex:"0","aria-label":b.Rk||"","aria-hidden":"true"},J:[{D:"div",H:"ytp-ce-element-shadow"},{D:"div",H:"ytp-ce-covering-image",O:Q2(b)},{D:"div",H:"ytp-ce-covering-shadow-top"},{D:"a",H:"ytp-ce-covering-overlay",O:{href:R2(a,b.targetUrl),tabindex:"-1"},J:[{D:"div",Y:["ytp-ce-playlist-title","yt-ui-ellipsis","yt-ui-ellipsis-2"],O:{dir:g.Ln(b.title||"")},W:b.title},{D:"div",H:"ytp-ce-playlist-count",J:[{D:"div",
H:"ytp-ce-playlist-icon"},{D:"div",H:"ytp-ce-playlist-count-text",W:b.playlistLength}]}]}]};c=new g.R(c);break;case "CHANNEL":c={D:"div",Y:["ytp-ce-element","ytp-ce-channel",b.isSubscribe?"ytp-ce-channel-this":"ytp-ce-channel-that"],O:{tabindex:"0","aria-label":b.Rk||"","aria-hidden":"true"},J:[{D:"div",H:"ytp-ce-element-shadow"},{D:"div",H:"ytp-ce-expanding-overlay",J:[{D:"div",H:"ytp-ce-expanding-overlay-hider"},{D:"div",H:"ytp-ce-expanding-overlay-background"},{D:"div",H:"ytp-ce-expanding-overlay-content",
J:[{D:"div",H:"ytp-ce-expanding-overlay-body",J:[{D:"div",H:"ytp-ce-expanding-overlay-body-padding",J:[{D:"a",Y:["ytp-ce-channel-title","ytp-ce-link"],O:{href:R2(a,b.targetUrl),target:"_blank",tabindex:"-1",dir:g.Ln(b.title||"")},W:b.title},b.subscribeButton?{D:"div",H:"ytp-ce-subscribe-container",J:[{D:"div",H:"ytp-ce-channel-subscribe"}]}:"",b.subscribersText?{D:"div",H:"ytp-ce-channel-subscribers-text",W:b.subscribersText}:"",b.metadata?{D:"div",Y:["ytp-ce-channel-metadata","yt-ui-ellipsis","yt-ui-ellipsis-3"],
W:b.metadata}:""]}]}]}]},{D:"div",H:"ytp-ce-expanding-image",O:Q2(b)}]};c=new g.R(c);var d=g.ae(document,"div","ytp-ce-channel-subscribe",c.element)[0];if(b.subscribeButton&&b.channelId){g.J(d,"ytp-ce-subscribe-button");if(a.player.N().o){var e=null;var f=b.Ob.itct}else e="endscreen",f=null;e=new g.yQ(b.subscribeButton.subscribeText,b.subscribeButton.subscribeCount,b.subscribeButton.unsubscribeText,b.subscribeButton.unsubscribeCount,b.subscribeButton.enabled,b.subscribeButton.classic,b.channelId,
!!b.subscribeButton.subscribed,e,f,b.subscribeButton.signinUrl,a.player);d.appendChild(e.element);a.I.push(e)}break;case "WEBSITE":c={D:"div",Y:["ytp-ce-element","ytp-ce-website"],O:{tabindex:"0","aria-label":b.Rk||"","aria-hidden":"true"},J:[{D:"div",H:"ytp-ce-element-shadow"},{D:"div",H:"ytp-ce-expanding-overlay",J:[{D:"div",H:"ytp-ce-expanding-overlay-hider"},{D:"div",H:"ytp-ce-expanding-overlay-background"},{D:"div",H:"ytp-ce-expanding-overlay-content",J:[{D:"div",H:"ytp-ce-expanding-overlay-body",
J:[{D:"div",H:"ytp-ce-expanding-overlay-body-padding",J:[{D:"div",H:"ytp-ce-website-title",O:{dir:g.Ln(b.title||"")},W:b.title},{D:"div",H:"ytp-ce-website-metadata",W:b.metadata},{D:"a",Y:["ytp-ce-website-goto","ytp-ce-link"],O:{href:R2(a,b.targetUrl),target:"_blank",tabindex:"-1"},W:b.callToAction}]}]}]}]},{D:"div",H:"ytp-ce-expanding-image",O:Q2(b)},{D:"div",H:"ytp-ce-expanding-icon",O:Bsa(b.iconUrl)}]};c=new g.R(c);break;case "CREATOR_MERCHANDISE":c="",b.productPrice&&(c={D:"div",H:"ytp-ce-merchandise-price-container",
J:[{D:"div",H:"ytp-ce-merchandise-price",W:b.productPrice}]},b.additionalFeesText&&c.J.push({D:"div",H:"ytp-ce-merchandise-additional-fees",W:b.additionalFeesText})),c={D:"div",Y:["ytp-ce-element","ytp-ce-merchandise"],O:{tabindex:"0","aria-label":b.Rk||"","aria-hidden":"true"},J:[{D:"div",H:"ytp-ce-element-shadow"},{D:"div",H:"ytp-ce-expanding-overlay",J:[{D:"div",H:"ytp-ce-expanding-overlay-hider"},{D:"div",H:"ytp-ce-expanding-overlay-background"},{D:"div",H:"ytp-ce-expanding-overlay-content",J:[{D:"div",
H:"ytp-ce-expanding-overlay-body",J:[{D:"div",H:"ytp-ce-expanding-overlay-body-padding",J:[{D:"div",H:"ytp-ce-merchandise-title",O:{dir:g.Ln(b.title||"")},W:b.title},c,{D:"div",H:"ytp-ce-merchandise-metadata",W:b.metadata},{D:"a",Y:["ytp-ce-merchandise-goto","ytp-ce-link"],O:{href:R2(a,b.targetUrl),target:"_blank",tabindex:"-1"},W:b.callToAction}]}]}]}]},{D:"div",H:"ytp-ce-expanding-image",O:Q2(b)},{D:"div",H:"ytp-ce-merchandise-invideo-cta-container",J:[{D:"div",H:"ytp-ce-merchandise-invideo-cta",
W:b.callToAction}]}]},c=new g.R(c)}b.gG&&g.J(c.element,"ytp-ce-placeholder");return c},Q2=function(a){if(a.Ow)var b=a.Ow.thumbnails;
return Bsa(b?b[b.length-1].url:null)},Bsa=function(a){return a?{style:"background-image: url("+a+")"}:{}},Asa=function(a,b,c){function d(){k(1)}
function e(){k(-1)}
b.ka("mouseenter",(0,g.x)(a.Xs,a,b,c));b.ka("mouseleave",(0,g.x)(a.au,a,b,c));a.player.N().o||b.ka("click",(0,g.x)(function(l){g.J(l.element,"ytp-ce-element-hover")},a,b));
b.ka("click",(0,g.x)(a.yA,a,c));b.ka("keypress",(0,g.x)(a.yA,a,c));b.ka("focus",(0,g.x)(function(l,m){this.Xs(l,m)},a,b,c));
b.ka("blur",(0,g.x)(function(l,m){this.au(l,m)},a,b,c));
b.ka("touchstart",(0,g.x)(a.Xs,a,b,c));var f=g.ce("ytp-ce-expanding-overlay-hider",b.element);f&&b.L(f,"touchstart",function(l){l=l||window.event;l.cancelBubble=!0;l.stopPropagation&&l.stopPropagation();g.Dn(b.element,"ytp-ce-element-hover");g.Dn(b.element,"ytp-ce-force-expand")});
b.ka("keydown",(0,g.x)(function(l,m){this.M=9==m.keyCode&&!m.shiftKey},a,b));
var k=(0,g.x)(function(l,m,n){this.G+=n;0<this.G?(g.J(l.element,"ytp-ce-force-expand"),S2(this,m.id,!0)):(g.Dn(l.element,"ytp-ce-force-expand"),g.Dn(l.element,"ytp-ce-element-hover"),S2(this,m.id,!1))},a,b,c);
c=(0,g.x)(function(l,m){m&&(l.ka("blur",g.Qa(function(){"none"!=m.style.display&&a.M&&m.focus()})),l.L(m,"focus",d),l.L(m,"blur",e))},a,b);
c(g.ce("ytp-sb-subscribe",b.element));c(g.ce("ytp-sb-unsubscribe",b.element));b.ka("focus",d);b.ka("blur",e)},R2=function(a,b){var c=a.player.N();
if(b){if(b.startsWith("//"))return c.protocol+":"+b;if(b.startsWith("/"))return g.tz(c)+b}else return"";return b},S2=function(a,b,c){a.w&&(c?a.C.show():a.C.hide());
for(var d in a.o)d!=b&&g.K(a.o[d].element,"ytp-ce-element-shadow-show",c)},T2=function(a,b,c){function d(){f||(e++,e==b.length&&(k.stop(),c&&c()))}
if(!b||0==b.length||O2(a))c&&c();else{b=Csa(a,b);var e=0,f=!1,k=new g.I(function(){f=!0;c&&c()},1E3,a);
k.start();for(a=0;a<b.length;a++)g.cr(b[a],d)}},U2=function(a,b,c){T2(a,b.clickUrls,c);
(a=g.ds())&&b.cG&&g.zs(a,b.visualElement)},Csa=function(a,b){var c=a.player.getVideoData().clientPlaybackNonce,d=a.player.getCurrentTime().toFixed(2);
c={CPN:c,AD_CPN:c,MT:d};d=[];for(var e=0;e<b.length;e++)d.push(Dsa(b[e],c));return d},Dsa=function(a,b){return a.replace(/%5B[a-zA-Z_:]+%5D|\[[a-zA-Z_:]+\]/g,function(c){var d=unescape(c);
d=d.substring(1,d.length-1);return b[d]?escape(b[d]):c})},Esa=function(a){return Array.isArray(a)&&a.length?a[0]:a},V2=function(a){return"string"===typeof a?a:""},W2=function(a,b,c){for(var d in b)if(b[d]==a)return a;
return c},Gsa=function(a){var b=Fsa;
if(null==a)return null;if(g.La(a)){var c=[];(0,g.y)(a,function(d){(d=b(d))&&c.push(d)});
return c}return(a=b(a))?[a]:[]},Hsa=function(a){this.externalId=a},Isa=function(a,b,c,d){this.value=a;
this.target=b;this.showLinkIcon=c;this.o=d},X2=function(a){if(!a)return null;
var b=g.wc(V2(a.value));b=g.uc(b);if(!b)return null;var c=W2(a.target,Jsa,"current");if(null==c)a=null;else{var d=a.show_link_icon;a=new Isa(b,c,"true"==d||"false"==d?"true"==d:!0,null!=a.pause_on_navigation?a.pause_on_navigation:!0)}return a},Y2=function(a){return a.value?a.value:null},Ksa=function(a,b,c,d){this.type=a;
this.trigger=b;this.url=c;this.subscribeData=d},Fsa=function(a){if(!a)return null;
var b=W2(a.type,Lsa),c=W2(a.trigger,Msa),d=Esa(a.url);d=X2(d?d:null);a=Esa(a.subscribeData);var e=a?a:null;e?(a=V2(e.external_user_id),e=V2(e.subscription_token),a=a&&e?new Hsa(a):null):a=null;return b?new Ksa(b,c,d,a):null},Z2=function(a,b,c,d,e){this.id=a;
this.type=b;this.style=c;this.o=d||[];this.data=e},Nsa=function(a,b){return g.Xa(a.o,b,void 0)},Osa=function(a,b){return a.id.replace(/[^a-z0-9-]/gi,"-")+"-"+b.toString()},Psa=function(a,b){this.merchant=a;
this.price=b},Qsa=function(a){this.o=a},Rsa=function(a,b,c){b&&(c?$2(a,(0,g.Cc)(b,g.Qa(function(d,e){return g.dn(e,d)},c))):$2(a,b))},$2=function(a,b,c,d){var e=1,f=-1;
if(c){var k=!1;var l=function(){e--;e||k||(clearTimeout(f),k=!0,c())};
f=setTimeout(function(){k=!0;c()},1E3)}(0,g.y)(b||[],function(m){e++;
g.cr(m,l)});
d&&(e++,0!=d&&a.o.sendVideoStatsEngageEvent(d,l))},Ssa=function(a,b,c,d,e,f,k){this.o=a;
this.w=b;this.A=c;this.videoData=d;this.logger=e;this.K=f;this.u=k},a3=function(a,b){this.o=a;
this.w=b},Vsa=function(a,b){var c=[];
(0,g.y)(b.choices,function(k){c.push(Tsa(b,k))},a);
var d={D:"ul",O:{role:"radiogroup"},J:c},e={};b.ej&&(e["aria-label"]=g.gM("$POLL_TITLE \u2013 Connectez-vous pour r\u00e9pondre au sondage.",{POLL_TITLE:b.title}));var f=["iv-card","iv-card-poll"];d=[{D:"div",H:"iv-card-content",J:[b3("h2",e,b.title),{D:"form",J:[{D:"fieldset",J:[d]}]}]}];b.ej&&(f.push("iv-card-unavailable"),d.push({D:"div",Y:["iv-card-sign-in"],J:[{D:"h2",W:"Vous voulez voter\u00a0?"},{D:"a",Y:["iv-card-sign-in-button","iv-button"],O:{href:Y2(b.ej)},J:[{D:"span",Y:["iv-button-content"],
W:"Se connecter"}]}]}));f=new g.R({D:"div",Y:f,J:d});d=f.element;Usa(b,d);vsa(a.o.o,d,g.Qa(a.A,b),a);(0,g.y)(g.be("iv-card-poll-choice-input",d),function(k){this.o.o.ka(k,"focus",g.Qa(this.u,!0));this.o.o.ka(k,"blur",g.Qa(this.u,!1))},a);
b.ej&&(d=g.ce("iv-card-sign-in-button",d),a.w(d,b.ej,b.id,b.Ob,b.Gc.click,5));return f},Wsa=function(a,b,c){var d=["yt-badge",
"standalone-ypc-badge-renderer-icon",b.eP?"standalone-ypc-badge-renderer-icon-purchased":"standalone-ypc-badge-renderer-icon-available"],e={};d=b.fG&&b.kw?{D:"span",Y:d,O:e,W:b.kw}:"";c={D:"div",Y:["iv-card",c],J:[{D:"a",H:"iv-click-target",O:{href:Y2(b.url)},J:[c3(b.jj,d?{D:"div",H:"iv-card-image-text",J:[d,b.priceText]}:""),{D:"div",H:"iv-card-content",J:[{D:"h2",H:"iv-card-primary-link",W:b.title},d3(a,b)]}]}]};c=new g.R(c);e3(a,g.be("iv-click-target",c.element),b,b.url);return c},f3=function(a){return a.customMessage?
b3("div","iv-card-message",a.customMessage):""},c3=function(a,b){var c="background-image: url("+a+");",d=[];
b&&d.push(b);return{D:"div",H:"iv-card-image",O:{style:c},J:d}},d3=function(a,b){if(!b.metaInfo||0==b.metaInfo.length)return"";
var c=[];(0,g.y)(b.metaInfo,function(d){c.push(b3("li","",d))},a);
return{D:"ul",H:"iv-card-meta-info",J:c}},Tsa=function(a,b){return{D:"li",
H:Osa(a,b.index),J:[{D:"label",J:[{D:"input",H:"iv-card-poll-choice-input",O:{type:"checkbox",role:"radio",name:a.id.replace(/[^a-z0-9-]/gi,"-")+b.index.toString(),value:b.index.toString(),"data-poll-choice-index":b.index.toString()}},{D:"span",H:"iv-card-poll-choice-text",J:[{D:"span",H:"iv-card-poll-choice-percent"},b3("span",void 0,b.desc)]}]},{D:"div",H:"iv-card-poll-result",J:[{D:"div",H:"iv-card-poll-result-bar"}]}]}},b3=function(a,b,c){b?"string"===typeof b?b={"class":b}:Array.isArray(b)&&
(b={"class":b.join(" ")}):b={};
b.dir=g.Ln(c);return{D:a,O:b,W:c}},Xsa=function(a){if(!a.customMessage)return"";
var b=["iv-card-action","iv-card-primary-link"],c={};a.qn&&(b.push("iv-card-action-icon"),c.style="background-image: url("+a.qn+");");c.dir=g.Ln(a.customMessage);var d=[{D:"span",W:a.customMessage}];a.showLinkIcon&&(d.push("\u00a0"),d.push({D:"span",H:"iv-card-link-icon"}));return{D:"div",Y:b,O:c,J:d}},Usa=function(a,b){var c=0;
(0,g.y)(a.choices,function(m){c+=m.count});
c=c||1;for(var d=0;d<a.choices.length;d++){var e=a.choices[d],f=g.ce(Osa(a,e.index),b);e=e.count/c;null==a.Ce&&(e=0);g.K(f.getElementsByTagName("label")[0],"iv-card-poll-choice-checked",a.Ce==d);f.getElementsByTagName("input")[0].checked=a.Ce==d;var k=Math.floor(100*e).toFixed(0),l=g.ce("iv-card-poll-choice-percent",f);g.ye(l,g.gM("$PERCENT\u00a0%",{PERCENT:k}));f=g.ce("iv-card-poll-result-bar",f);g.sh(f,"transform","scaleX("+e.toFixed(2)+")")}g.K(b,"iv-card-poll-voted",null!=a.Ce);g.K(b,"iv-card-poll-expanded",
null!=a.Ce&&1<a.choices.length)},e3=function(a,b,c,d){d&&(0,g.y)(b,function(e){this.w(e,d,c.id,c.Ob,c.Gc.click,5)},a)},Ysa=function(a){var b;
(b=a)&&!(b=1<a.length?"/"==a.charAt(0)&&"/"!=a.charAt(1):"/"==a)&&(b=a.replace(/^(https?:)?\/\//,""),b=b.split("/",1),b=!b||1>b.length||!b[0]?[]:b[0].toLowerCase().split(".").reverse(),b="com"==b[0]&&"youtube"==b[1]||"be"==b[0]&&"youtu"==b[1]);return b?-1==a.indexOf("/redirect?"):!1},Zsa=function(a,b){return b?b:Ysa(a)?"current":"new"},g3=function(a,b){g.A.call(this);
var c=this;this.Ka=a;this.context=b;this.dv=!1;this.ga=new Map;this.ma=new Map;this.context.K.addEventListener(g.lC("annotations_module"),function(d){(d=c.ga.get(d))&&d.apply(c)});
this.context.K.addEventListener("crx_annotations_module",function(d){(d=c.ma.get(d))&&d.apply(c)})},$sa=function(a,b,c,d,e){var f=Y2(b);
if(f){var k=Zsa(f,b.target),l=(0,g.x)(function(){b.o&&this.context.K.pauseVideo();var m=this.context.videoData.lc||!1,n=g.mq(f||"");m&&n&&(n.v||n.list)?g.rT(this.context.K.app,n.v,c,n.list,!1,void 0):g.GN(f||"","current"==k?"_top":void 0,c)},a);
"new"==k&&(l(),l=null);$2(a.context.logger,d,l,e);Ysa(f)||(a=g.ds(),d=c.itct,a&&d&&g.zs(a,g.Wr(d)))}},ata=function(a){if(a.urlEndpoint&&a.urlEndpoint.url)return a.urlEndpoint.url;
if(a.watchEndpoint&&a.watchEndpoint.videoId){var b="/watch?v="+a.watchEndpoint.videoId;a.watchEndpoint.playlistId&&(b+="&list="+a.watchEndpoint.playlistId);a.watchEndpoint.index&&(b+="&index="+a.watchEndpoint.index);a.watchEndpoint.startTimeSeconds&&(b+="&t="+a.watchEndpoint.startTimeSeconds);return b}return null},h3=function(a,b,c){return{Yx:(a.impressionLoggingUrlsV2s||[]).map(function(d){return d.baseUrl}),
click:(c.loggingUrls||[]).map(function(d){return d.baseUrl}),
close:(b.dismissLoggingUrlsV2s||[]).map(function(d){return d.baseUrl}),
qC:(b.impressionLoggingUrlsV2s||[]).map(function(d){return d.baseUrl}),
Vp:(b.clickLoggingUrlsV2s||[]).map(function(d){return d.baseUrl})}},k3=function(a,b,c){g3.call(this,b,c);
var d=this;this.u=a;this.aa=this.Ia=this.B=this.Ea=!1;this.ha=null;this.ba=new g.I(g.Ia,c.A.Wa?4E3:3E3);g.B(this,this.ba);this.za=new g.I(g.Ia);g.B(this,this.za);this.G=new a3(c,(0,g.x)(this.yk,this),(0,g.x)(this.Co,this));this.U=new g.R({D:"div",H:"iv-drawer",O:{id:"iv-drawer"},J:[{D:"div",H:"iv-drawer-header",O:{"aria-role":"heading"},J:[{D:"span",H:"iv-drawer-header-text"},{D:"button",Y:["iv-drawer-close-button","ytp-button"],O:{"aria-label":"Masquer les fiches",tabindex:"0"}}]},{D:"div",H:"iv-drawer-content"}]});
g.B(this,this.U);this.C=this.U.element;this.oa=new g.lN(this.U,330);g.B(this,this.oa);this.Ca=g.ce("iv-drawer-header-text",this.C);this.A=g.ce("iv-drawer-content",this.C);this.w=[];this.Aa=this.R=this.F=this.da=this.o=null;this.V=[];this.addCueRange(0,1E3*c.videoData.lengthSeconds,"",function(){d.Ia&&i3(d,"YOUTUBE_DRAWER_AUTO_OPEN")},function(){(d.Ia=d.B)&&j3(d)});
this.M=this.I=this.Z=null;this.P=0},bta=function(a,b){b.data.autoOpenMs&&a.addCueRange(b.data.autoOpenMs,0x8000000000000,"",function(){i3(a,"YOUTUBE_DRAWER_AUTO_OPEN")});
b.data.autoCloseMs&&a.addCueRange(b.data.autoCloseMs,0x8000000000000,"",function(){j3(a)});
var c=b.data.headerText;g.ye(a.Ca,c);a.R&&a.R.setAttribute("title",c);a.Z=g.Wr(b.data.trackingParams);a.M=g.Wr(b.data.closeTrackingParams);a.I=g.Wr(b.data.iconTrackingParams)},cta=function(a,b){var c=b.cardId?b.cardId:"cr:"+a.P;
if(b.content.simpleCardContentRenderer){if(!b.cueRanges.length)return;var d=b.content.simpleCardContentRenderer,e=b.teaser.simpleCardTeaserRenderer,f=b.icon?b.icon.infoCardIconRenderer:null;c={id:c,timestamp:a.P,type:"simple",teaserText:g.T(e.message),teaserDurationMs:parseInt(b.cueRanges[0].teaserDurationMs,10),startMs:parseInt(b.cueRanges[0].startCardActiveMs,10),autoOpen:!!b.autoOpen,Ob:l3(a,c,b,d),sponsored:!1,Gc:h3(d,e,d.command),de:d.trackingParams?g.Wr(d.trackingParams):null,Yd:e.trackingParams?
g.Wr(e.trackingParams):null,yd:f&&f.trackingParams?g.Wr(f.trackingParams):null,imageUrl:m3(d.image.thumbnails,290).url,displayDomain:d.displayDomain?g.T(d.displayDomain):null,showLinkIcon:!!d.showLinkIcon,qn:null,title:d.title?g.T(d.title):"",customMessage:d.callToAction?g.T(d.callToAction):"",url:d.command.urlEndpoint.url?X2({pause_on_navigation:!a.context.videoData.va,target:"new",value:d.command.urlEndpoint.url}):null};n3(a,c)}else if(b.content.collaboratorInfoCardContentRenderer){if(!b.cueRanges.length)return;
d=b.content.collaboratorInfoCardContentRenderer;e=b.teaser.simpleCardTeaserRenderer;f=b.icon?b.icon.infoCardIconRenderer:null;c={id:c,timestamp:a.P,type:"collaborator",teaserText:g.T(e.message),teaserDurationMs:parseInt(b.cueRanges[0].teaserDurationMs,10),startMs:parseInt(b.cueRanges[0].startCardActiveMs,10),autoOpen:!!b.autoOpen,Ob:l3(a,c,b,d),sponsored:!1,Gc:h3(d,e,d.endpoint),de:d.trackingParams?g.Wr(d.trackingParams):null,Yd:e.trackingParams?g.Wr(e.trackingParams):null,yd:f&&f.trackingParams?
g.Wr(f.trackingParams):null,channelId:d.endpoint.browseEndpoint.browseId,customMessage:d.customText?g.T(d.customText):null,wB:m3(d.channelAvatar.thumbnails,290).url,title:d.channelName?g.T(d.channelName):"",metaInfo:[d.subscriberCountText?g.T(d.subscriberCountText):""],url:X2({pause_on_navigation:!a.context.videoData.va,target:"new",value:d.endpoint.browseEndpoint.canonicalBaseUrl?d.endpoint.browseEndpoint.canonicalBaseUrl:"/channel/"+d.endpoint.browseEndpoint.browseId})};n3(a,c)}else if(b.content.playlistInfoCardContentRenderer){if(!b.cueRanges.length)return;
d=b.content.playlistInfoCardContentRenderer;e=b.teaser.simpleCardTeaserRenderer;f=b.icon?b.icon.infoCardIconRenderer:null;c={id:c,timestamp:a.P,type:"playlist",teaserText:g.T(e.message),teaserDurationMs:parseInt(b.cueRanges[0].teaserDurationMs,10),startMs:parseInt(b.cueRanges[0].startCardActiveMs,10),autoOpen:!!b.autoOpen,Ob:l3(a,c,b,d),sponsored:!1,Gc:h3(d,e,d.action),de:d.trackingParams?g.Wr(d.trackingParams):null,Yd:e.trackingParams?g.Wr(e.trackingParams):null,yd:f&&f.trackingParams?g.Wr(f.trackingParams):
null,jj:m3(d.playlistThumbnail.thumbnails,258).url,customMessage:d.customMessage?g.T(d.customMessage):null,playlistVideoCount:g.T(d.playlistVideoCount),title:d.playlistTitle?g.T(d.playlistTitle):"",metaInfo:[d.channelName?g.T(d.channelName):"",d.videoCountText?g.T(d.videoCountText):""],url:X2({pause_on_navigation:!a.context.videoData.va,target:"new",value:ata(d.action)})};n3(a,c)}else if(b.content.videoInfoCardContentRenderer){if(!b.cueRanges.length)return;d=b.content.videoInfoCardContentRenderer;
e=b.teaser.simpleCardTeaserRenderer;f=b.icon?b.icon.infoCardIconRenderer:null;c={id:c,timestamp:a.P,type:"video",teaserText:g.T(e.message),teaserDurationMs:parseInt(b.cueRanges[0].teaserDurationMs,10),startMs:parseInt(b.cueRanges[0].startCardActiveMs,10),autoOpen:!!b.autoOpen,Ob:l3(a,c,b,d),sponsored:!1,Gc:h3(d,e,d.action),de:d.trackingParams?g.Wr(d.trackingParams):null,Yd:e.trackingParams?g.Wr(e.trackingParams):null,yd:f&&f.trackingParams?g.Wr(f.trackingParams):null,jj:m3(d.videoThumbnail.thumbnails,
258).url,videoDuration:d.lengthString?g.T(d.lengthString):null,customMessage:d.customMessage?g.T(d.customMessage):null,title:d.videoTitle?g.T(d.videoTitle):"",metaInfo:[d.channelName?g.T(d.channelName):"",d.viewCountText?g.T(d.viewCountText):""],isLiveNow:!!d.badge,url:X2({pause_on_navigation:!a.context.videoData.va,target:"new",value:ata(d.action)})};n3(a,c)}a.P++},m3=function(a,b){for(var c=-1,d=-1,e=0;e<a.length;e++){if(a[e].height==b||290==a[e].width)return a[e];
((a[e].height||0)<b||290>(a[e].width||0))&&(0>c||(a[c].height||0)<(a[e].height||0)||(a[c].width||0)<(a[e].width||0))?c=e:((a[e].height||0)>=b||290<=(a[e].width||0))&&(0>d||(a[d].height||0)>(a[e].height||0)||(a[d].width||0)>(a[e].width||0))&&(d=e)}return a[0<=d?d:c]},l3=function(a,b,c,d){return{feature:c.feature?c.feature:"cards",
src_vid:a.context.videoData.videoId,annotation_id:b,ei:a.context.videoData.eventId,itct:d.trackingParams}},eta=function(a,b){var c=dta(a,b);
c&&(c==a.o&&(a.o=null),a.u.removeCueRange(c.card.id),g.te(c.er),g.db(a.w,c),a.un(),o3(a))},i3=function(a,b,c){if(!a.B){a.oa.show();
a.da=new g.I(function(){g.J(a.context.K.getRootNode(),g.lM.IV_DRAWER_OPEN)},0);
a.da.start();a.ha=g.Ep(a.A,"mousewheel",(0,g.x)(a.OL,a));a.B=!0;var d=g.ds();d&&a.Z&&a.M&&B2(d,[a.Z,a.M]);var e={TRIGGER_TYPE:b};(0,g.y)(a.w,function(f){f.Cy||(f.Cy=!0,Rsa(a.context.logger,f.card.Gc.Yx,e));d&&B2(d,[f.card.de])});
A2(a.u);c&&(a.F=new g.I(function(){a.wa=a.R;a.Aa.focus()},330),a.F.start())}},j3=function(a){a.B&&(a.oa.hide(),g.Fp(a.ha),a.ha=null,g.Dn(a.context.K.getRootNode(),g.lM.IV_DRAWER_OPEN),a.B=!1,A2(a.u),a.F&&a.F.stop(),a.F=new g.I(function(){a.wa&&(a.wa.focus(),a.wa=null)},330),a.F.start())},fta=function(a){var b=g.ce("iv-drawer-close-button",a.C);
a.context.o.ka(b,"click",a.iE,a);a.context.o.ka(a.A,"touchend",function(){a.ba.start()});
a.context.o.ka(a.A,"scroll",a.yE,a);a.context.u.subscribe("onHideControls",function(){a.aa=!0});
a.context.u.subscribe("onShowControls",function(){a.aa=!1});
a.context.u.subscribe("onVideoAreaChange",function(){a.aa=g.Bn(a.u.getRootNode(),"ytp-autohide")});
a.V.push(g.Oo("iv-button-shown",a.oG,a));a.V.push(g.Oo("iv-button-hidden",a.nG,a));a.V.push(g.Oo("iv-teaser-shown",a.rG,a));a.V.push(g.Oo("iv-teaser-hidden",a.qG,a));a.V.push(g.Oo("iv-teaser-clicked",a.pG,a))},n3=function(a,b){a.Ea||(g.Cn(a.ua(),[g.lM.STOP_EVENT_PROPAGATION,
"iv-drawer-manager"]),g.iL(a.u,a.C,5),fta(a),a.R=g.ce("ytp-cards-button",a.u.getRootNode()),a.Aa=g.ce("iv-drawer-close-button",a.C),a.Ea=!0);eta(a,b.id);var c=gta(a,b);if(c){var d={card:b,er:c.element,Cy:!1},e=hta(a,d);g.kb(a.w,e,0,d);c.ca(a.A,e);a.un();b.autoOpen?a.addCueRange(b.startMs,0x8000000000000,b.id,g.Qa(a.vO,d)):(c=1E3*a.context.K.getCurrentTime(),5E3>c&&c>b.startMs&&a.bC(d),a.addCueRange(b.startMs,b.startMs+1,b.id,g.Qa(a.bC,d)),o3(a))}},gta=function(a,b){switch(b.type){case "simple":var c=
a.G;
var d=b.displayDomain?{D:"div",H:"iv-card-image-text",W:b.displayDomain}:"";var e=Xsa(b);d={D:"div",Y:["iv-card"],J:[{D:"a",H:"iv-click-target",O:{href:Y2(b.url)},J:[c3(b.imageUrl,d),{D:"div",H:"iv-card-content",J:[b3("h2",void 0,b.title),e]}]}]};d=new g.R(d);e3(c,g.be("iv-click-target",d.element),b,b.url);return d;case "collaborator":return c=a.G,d={D:"div",Y:["iv-card","iv-card-channel"],J:[{D:"a",Y:["iv-click-target"],O:{href:Y2(b.url),"data-ytid":b.channelId},J:[c3(b.wB),{D:"div",H:"iv-card-content",
J:[f3(b),{D:"h2",H:"iv-card-primary-link",W:b.title},d3(c,b)]}]}]},d=new g.R(d),e3(c,g.be("iv-click-target",d.element),b,b.url),d;case "episode":return Wsa(a.G,b,"iv-card-episode");case "movie":return Wsa(a.G,b,"iv-card-movie");case "playlist":return c=a.G,d={D:"div",Y:["iv-card","iv-card-playlist"],J:[{D:"a",H:"iv-click-target",O:{href:Y2(b.url)},J:[c3(b.jj,{D:"div",H:"iv-card-image-overlay",J:[{D:"span",H:"iv-card-playlist-video-count",W:b.playlistVideoCount}]}),{D:"div",H:"iv-card-content",J:[f3(b),
b3("h2","iv-card-primary-link",b.title),d3(c,b)]}]}]},d=new g.R(d),e3(c,g.be("iv-click-target",d.element),b,b.url),d;case "poll":return Vsa(a.G,b);case "productListing":c=a.G;var f=!g.ab(b.offers);d=["iv-card"];e="";var k=Xsa(b);f&&(d.push("iv-card-product-listing"),e="iv-card-primary-link",f=b.offers[0],k=[],f.price&&k.push({D:"div",H:"iv-card-offer-price",W:f.price}),f.merchant&&k.push({D:"div",H:"iv-card-offer-merchant",W:f.merchant}),k={D:"div",J:k});d={D:"div",Y:d,O:{tabindex:"0"},J:[{D:"a",
Y:["iv-card-image","iv-click-target"],O:{style:"background-image: url("+b.imageUrl+");",href:Y2(b.url),"aria-hidden":"true",tabindex:"-1"}},{D:"div",H:"iv-card-content",J:[b.sponsored?{D:"div",H:"iv-card-sponsored",J:["Lien commercial",{D:"div",H:"iv-ad-info-container",J:[{D:"div",H:"iv-ad-info",W:"{{adInfo}}"},{D:"div",H:"iv-ad-info-icon-container",J:[{D:"div",H:"iv-ad-info-icon"},{D:"div",H:"iv-ad-info-callout"}]}]}]}:"",{D:"a",H:"iv-click-target",O:{href:Y2(b.url)},J:[b3("h2",e,b.title),k]}]}]};
d=new g.R(d);e=g.oe("span");g.ye(e,"Vous voyez ce produit, car nous pensons qu'il est pertinent pour la vid\u00e9o. Il se peut que le marchand r\u00e9mun\u00e8re Google.");d.qb(e,"adInfo");e3(c,g.be("iv-click-target",d.element),b,b.url);return d;case "video":return c=a.G,d=b.isLiveNow?{D:"span",Y:["yt-badge","yt-badge-live"],W:"EN DIRECT MAINTENANT"}:"",d={D:"div",Y:["iv-card","iv-card-video"],J:[{D:"a",H:"iv-click-target",O:{href:Y2(b.url)},J:[c3(b.jj,b.videoDuration?{D:"span",H:"iv-card-video-duration",
W:b.videoDuration}:""),{D:"div",H:"iv-card-content",J:[f3(b),b3("h2","iv-card-primary-link",b.title),d3(c,b),d]}]}]},d=new g.R(d),e3(c,g.be("iv-click-target",d.element),b,b.url),d}return null},hta=function(a,b){if(0==a.w.length)return 0;
var c=g.Ya(a.w,function(d){return b.card.startMs>d.card.startMs||b.card.startMs==d.card.startMs&&b.card.timestamp>=d.card.timestamp?!0:!1});
return-1==c?0:c+1},ita=function(a){return a.o?"productListing"==a.o.card.type:(0,g.ti)(a.w,function(b){return"productListing"==b.card.type})},o3=function(a){g.K(a.u.getRootNode(),"ytp-cards-shopping-active",ita(a))},jta=function(a,b){if(a.U.Ha()){var c=new G2([0,
a.A.scrollTop],[0,b.er.offsetTop],600,psa);a.context.w.ka(c,"animate",function(d){a.A.scrollTop=d.y});
a.context.w.ka(c,"finish",function(d){a.A.scrollTop=d.y});
c.play()}else g.Qu(a.U,!0),a.A.scrollTop=b.er.offsetTop,g.Qu(a.U,!1)},p3=function(a){return a.o&&a.o.card?a.o.card:a.w[0]&&a.w[0].card?a.w[0].card:null},dta=function(a,b){return g.Xa(a.w,function(c){return c.card.id==b})},q3=function(a,b,c){g3.call(this,a,b);
this.annotation=c;this.isActive=!1},kta=function(a){var b=a.annotation.data;
"start_ms"in b&&"end_ms"in b&&a.addCueRange(a.annotation.data.start_ms,a.annotation.data.end_ms,a.annotation.id,function(){a.show()},function(){a.hide()})},r3=function(a,b,c){q3.call(this,a,b,c);
this.u=null;this.F=!1;this.w=null;this.A=!1;this.o=this.C=this.B=null},s3=function(a,b,c){q3.call(this,a,b,c);
this.I=this.B=this.P=!1;this.F=5E3;this.A=null;this.G=g.ne("DIV","iv-promo-contents");this.u=this.w=this.o=null;this.C=new g.I(function(){this.o.setAttribute("aria-hidden",!0);g.Oh(this.w,!1);g.Oh(this.u,!0)},700,this);
g.B(this,this.C)},lta=function(a){var b=a.annotation.data;
if("cta"==a.annotation.style)var c=6;else if("video"==a.annotation.style||"playlist"==a.annotation.style)c=7;a.F=b.collapse_delay_ms||a.F;var d=["iv-promo","iv-promo-inactive"];a.ua().setAttribute("aria-hidden",!0);a.ua().setAttribute("aria-label","Promotion");a.ua().tabIndex=0;var e=a.annotation.jc(),f=b.image_url;if(f){var k=g.ne("DIV",["iv-promo-img","iv-click-target"]);f=g.ne("IMG",{src:f,"aria-hidden":"true"});k.appendChild(f);b.video_duration&&!b.is_live?(f=g.ne("SPAN","iv-promo-video-duration",
b.video_duration),k.appendChild(f)):b.playlist_length&&(f=g.ne("SPAN","iv-promo-playlist-length",b.playlist_length.toString()),k.appendChild(f));e&&a.yk(k,e,a.annotation.id,b.session_data,void 0,c)}e?(f=g.ne("A","iv-promo-txt"),g.Yc(f,Y2(e)),a.o=f):a.o=g.ne("DIV","iv-promo-txt");switch(a.annotation.style){case "cta":case "website":var l=g.ne("P",null,g.ne("STRONG",null,b.text_line_1));var m=g.ne("P",null,g.ne("SPAN","iv-promo-link",b.text_line_2));if(f=b.text_line_3){d.push("iv-promo-website-card-cta-redesign");
g.P(a.context.A.experiments,"web_action_cta_larger_ui")&&d.push("iv-promo-website-card-cta-larger-ui");var n=g.ne("BUTTON",["iv-promo-round-expand-icon","ytp-button"]);f=g.ne("BUTTON",["iv-button","iv-promo-button"],g.ne("SPAN","iv-button-content",f));var p=g.ne("DIV","iv-promo-button-container");p.appendChild(f);e&&a.yk(a.ua(),e,a.annotation.id,b.session_data,void 0,c)}g.J(a.o,"iv-click-target");e&&a.yk(a.o,e,a.annotation.id,b.session_data,void 0,c);break;case "playlist":case "video":l=g.ne("P",
null,g.ne("SPAN",null,b.text_line_1)),m=g.ne("P",null,g.ne("STRONG",null,b.text_line_2)),b.is_live&&(l=m,m=g.ne("SPAN",["yt-badge","iv-promo-badge-live"],"EN DIRECT MAINTENANT")),g.J(a.o,"iv-click-target"),e&&a.yk(a.o,e,a.annotation.id,b.session_data,void 0,c),d.push("iv-promo-video")}l&&a.o.appendChild(l);m&&a.o.appendChild(m);a.G.appendChild(a.o);p&&a.G.appendChild(p);c=g.ne("DIV","iv-promo-actions");a.u=g.ne("BUTTON",["iv-promo-expand","ytp-button"]);a.u.title="Agrandir";a.context.o.ka(a.u,"click",
g.Qa(a.hs,5E3),a);c.appendChild(a.u);g.Oh(a.u,!1);a.context.o.ka(a.ua(),"mouseover",a.xF,a);a.context.o.ka(a.ua(),"mouseout",a.wF,a);a.context.o.ka(a.ua(),"touchend",g.Qa(a.hs,5E3),a);a.w=g.ne("BUTTON",["iv-promo-close","ytp-button"]);a.w.title="Fermer";a.context.o.ka(a.w,"click","cta"==a.annotation.style&&b.text_line_3?a.pF:a.oF,a);c.appendChild(a.w);g.Cn(a.ua(),d);k&&(a.ua().appendChild(k),n&&k.appendChild(n));a.ua().appendChild(a.G);a.ua().appendChild(c)},mta=function(a){a.B||a.I||a.A||(g.J(a.ua(),
"iv-promo-collapsed"),a.B=!0,a.C.start())},nta=function(a){a.C.stop();
a.B&&(g.En(a.ua(),["iv-promo-collapsed","iv-promo-collapsed-no-delay"]),a.B=!1,a.o&&a.o.removeAttribute("aria-hidden"),g.Oh(a.u,!1),g.Oh(a.w,!0))},ota=function(a,b){a.A||(a.A=g.Uf(function(){t3(this);
mta(this)},b,a))},t3=function(a){a.A&&(g.v.clearTimeout(a.A),a.A=null)},u3=function(a){g.vL.call(this,a);
this.P=!1;this.I=0;this.F={};this.V=new Qsa(a);this.B=new g.Gr(this);g.B(this,this.B);this.C=this.w=null;this.B.L(this.player,"onVideoAreaChange",(0,g.x)(this.S,this,"onVideoAreaChange"));this.B.L(this.player,"onHideControls",(0,g.x)(this.S,this,"onHideControls"));this.B.L(this.player,"onShowControls",(0,g.x)(this.S,this,"onShowControls"));this.B.L(this.player,"resize",(0,g.x)(this.S,this,"resize"));this.B.L(this.player,"presentingplayerstatechange",(0,g.x)(this.S,this,"presentingplayerstatechange"));
this.subscribe("presentingplayerstatechange",this.lM,this);this.subscribe("resize",this.pp,this);this.player.N().I.subscribe("vast_info_card_add",this.iB,this);this.U=new g.Gr(this);g.B(this,this.U);this.R=g.ne("DIV","video-custom-annotations");this.u=new g.R({D:"div",Y:["ytp-player-content","ytp-iv-player-content"]});g.B(this,this.u);g.iL(this.player,this.u.element,4);this.u.hide();this.A=new g.R({D:"div",Y:["ytp-iv-video-content"]});g.B(this,this.A);g.qe(this.A.element,g.ne("DIV","video-annotations",
this.R));this.G=this.o=null;this.M=[];pta(this)&&this.load();var b=g.oe("STYLE");(document.getElementsByTagName("HEAD")[0]||document.body).appendChild(b);g.Ge(this,function(){g.te(b)});
if(a=b.sheet)a.insertRule(".iv-promo .iv-promo-contents .iv-promo-txt .iv-promo-link:after {background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUBAMAAAB/pwA+AAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAHlBMVEVMaXH////////////////////////////////////Z6AnKAAAACXRSTlMA+/A2IuI1mJIldm0CAAAAAWJLR0QB/wIt3gAAAEVJREFUCNdjYGCYCQUMBJlACOIzIDElIcyZkwxgojOVWWDMSQauMKYySySUOSnBdSaUOZ0lEsac2YqwYiZ+JhwgM7E5HACgzVCI/YJ59AAAAABJRU5ErkJggg==) no-repeat center;background-size:10px;width:10px;height:10px}",
0),a.insertRule(".iv-promo .iv-promo-actions .iv-promo-close:after {background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAkAAAAJBAMAAAASvxsjAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAJFBMVEVMaXH///////////////////////////////////////////9tKdXLAAAAC3RSTlMAVaQDpaimqQbl5rjXUFUAAAABYktHRAH/Ai3eAAAAPUlEQVQI12MQMmAwEmDwDmaOTmAw39663YCBuXp2MQMDQ+fOBgYG5ujVwQwMptvbgeLaxczVCQwiBgxmAgBkXg1FN5iwiAAAAABJRU5ErkJggg==) no-repeat center;background-size:9px;width:9px;height:9px}",
0),a.insertRule(".iv-promo .iv-promo-actions .iv-promo-expand:after {background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAQAAAAJBAMAAADnQZCTAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAJFBMVEVMaXHMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMz////eMKB4AAAAC3RSTlMAOpE7k5Uvj5kpfRaQSaQAAAABYktHRAsf18TAAAAAHklEQVQI12MQYGBQZmBwTWCo0GSo6AKRQDZQRIABADXXA/UkIpvtAAAAAElFTkSuQmCC) no-repeat center;background-size:4px 9px;width:4px;height:9px}",0),a.insertRule(".iv-promo-website-card-cta-redesign .iv-promo-round-expand-icon:after {background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAQAAAD9CzEMAAAAAmJLR0QA/4ePzL8AAAAJcEhZcwAACxMAAAsTAQCanBgAAAAHdElNRQfgCgUUEztsNfqrAAAAXklEQVRYw+3Uuw2AQAwEUUNXfBpDIvBRMhQwJJAScNrA0r4CdiQHjjAzK4NGKucPAFmCnZcmwcTphBNO9CTGH4VB+/Zm6YlYis9fhedXz38FNvFriCCl808iw8ysrBu65gCeuV/CfgAAAABJRU5ErkJggg==) no-repeat center;background-size:18px 18px;width:18px;height:18px}",
0),a.insertRule(".iv-card-link-icon {background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASBAMAAACk4JNkAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAGFBMVEVMaXG7u7u7u7u7u7u7u7u7u7u7u7v///+WKTAlAAAABnRSTlMAFdQWbGj9GiOuAAAAAWJLR0QHFmGI6wAAAEhJREFUCNdjYACBNCBgQGMxMKrBWEJJaRAJRjVlKEsoSQDIAqtSZICwgEIQFkgIZBRECMxiBqsCsVjAqsCygQwwFgMeFgQgswBg2xjLrfC4mgAAAABJRU5ErkJggg==) no-repeat center;background-size:9px;width:9px;height:9px}",0),a.insertRule(".iv-card-playlist-video-count:after {background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYBAMAAAASWSDLAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAJFBMVEVMaXH///////////////////////////////////////////9tKdXLAAAAC3RSTlMAvDeyLvxYtDK9Ogx4T1QAAAABYktHRAH/Ai3eAAAAK0lEQVQY02NgoBjshgO8HJoYwKiAMGAD92YHJM7uMCTO9gaEHs4FlPuZAQC8Fj8x/xHjxwAAAABJRU5ErkJggg==) no-repeat center;background-size:24px;width:24px;height:24px}",
0),a.insertRule(".iv-drawer-close-button:after {background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAMAgMAAAArG7R0AAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAACVBMVEVMaXH////////OZTV/AAAAAnRSTlMAoKBFbtAAAAABYktHRAH/Ai3eAAAAKUlEQVQI12MIYGBlSGGQBMIUBjbHCQyM0xwYGDIZwBjEBomB5EBqgGoBolQGzYuy51cAAAAASUVORK5CYII=) no-repeat center;background-size:12px;width:12px;height:12px}",0),a.insertRule(".iv-ad-info-icon {background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAALCAMAAACecocUAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAVFBMVEVMaXGUlJSYmJiZmZmYmJiXl5eZmZmZmZmWlpaVlZWOjo6ZmZmSkpKXl5eYmJiYmJiZmZmZmZmZmZmZmZmYmJiJiYmXl5eZmZmYmJiWlpaZmZn///+81lbeAAAAGnRSTlMAE5DM80DliTMMEjccWIM5p1UjaTQNgB5cLlr5mgUAAAABYktHRBsCYNSkAAAAVElEQVQI102NRw7AIBADhw7ppIf/PzQLJ/ZgWSNrFlDaWKMVcs6HmGLwTqjEME6CFDrAXBYIGhNh3TJEg02wHydctvFc7sbrvnXZV8/zfs3T+7u/P7CrAso35YfPAAAAAElFTkSuQmCC) no-repeat center;background-size:11px;width:11px;height:11px}",
0),a.insertRule(".annotation-close-button {background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAALVBMVEVMaXEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA/Pz9aWloBAQGZmZlbW1v///+X9wUzAAAACHRSTlMANprf+g6lyRmB9hUAAAABYktHRA5vvTBPAAAAWUlEQVQI12NgYBAycVZkAIKwDiBIZWBgrQAx2gMY2DrAIIFBomPWju6VHY0MGh1rbu891dHEYNGx9+yd2x3NDB4d3XfO7uhoQTDgUnDFcO1wA+FWwC2FOQMAdKg6tUSAFEAAAAAASUVORK5CYII=) no-repeat center}",0),a.insertRule(".annotation-link-icon {background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACIAAAAiCAMAAAANmfvwAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAUVBMVEVMaXH////////////////////////////////////////////////////////////////////////////////////////////////////////JzkR1AAAAGnRSTlMAfXf+c3xsdGdv/GJoXPtXXflSVk5L7DBH9VeFfsQAAAABYktHRAH/Ai3eAAAAgElEQVQ4y93SSQ6AIAwFULSOOOJs739Qf9SF0VA2uNCu+psHaQJK7cVCqY+Rg92PXA++Q84KnCR03UIRJrFEKMEgZYFQhpyzQHSBWJJAdIVUENtJ3SC0mu3EdOh7zXZiBrRdzQLJ0Y1GfOlpVstD3HaZktX9X/gvRCxvxL6FR7IBS1RTM5xIpLoAAAAASUVORK5CYII=) no-repeat center}",
0)},qta=function(){var a=g.ne("DIV",["annotation",
"annotation-type-custom"]);g.Oh(a,!1);return a},rta=function(a){switch(a){case "annotation-editor":case "live-dashboard":return!0}return!1},pta=function(a){var b=a.player.N();
a=a.player.getVideoData();return 1==(b.annotationsLoadPolicy||a.annotationsLoadPolicy)&&!a.SC||b.I.get(a.videoId)||g.KB(a)||g.LB(a)?!0:!1},sta=function(a,b,c){a.P=!0;
a.C=g.Eq(b,c)},tta=function(a,b){for(var c={},d=0;d<b.attributes.length;d++){var e=b.attributes[d];
c[e.name]=e.nodeValue}for(d=0;d<b.childNodes.length;d++)if(e=b.childNodes[d],g.Na(e)&&1==e.nodeType){if(c[e.tagName])var f=c[e.tagName];else if("data"==e.tagName){0<e.childNodes.length&&(f=e.childNodes[0].nodeValue,c[e.tagName]="string"==typeof f?f.trim():f);continue}else f=[],c[e.tagName]=f;e&&"TEXT"==e.tagName?1==e.childNodes.length&&3==e.childNodes[0].nodeType?f.push(e.childNodes[0].nodeValue):f.push(""):e&&f.push(tta(a,e))}return c},uta=function(a,b,c){return!(a.loaded&&a.I==b&&a.player.getVideoData().videoId==
c)},xta=function(a){var b=a.player.getVideoData();
if(b.be){var c=a.player.N().I.get(b.videoId);if(c){var d={format:"XML",Zd:{},method:"POST",withCredentials:!0};d.Fc=(0,g.x)(function(e,f,k){uta(this,e,f)||(e=g.yq(k)&&k.responseXML?k.responseXML:null)&&v3(this,e)},a,a.I,b.videoId);
g.Vp()&&(d.Fc=vta(a,d.Fc));d.sb={ic_only:"1"};wta(d,c);a.P=!0;g.Eq(b.be,d)}}},wta=function(a,b){a.method="POST";
a.sb=a.sb||{};b.zn&&(a.sb.ic_coll=b.zn);b.An&&(a.sb.ic_xml=b.An);b.Pm&&(a.sb.ic_track=b.Pm)},yta=function(a){var b=new g.R({D:"div"});
g.Oh(b.element,!1);var c=new k3(a.player,b.element,w3(a));g.B(c,b);b.ca(a.u.element);c.Em();return c},w3=function(a){if(!a.G){var b=new J2(a);
g.B(a,b);var c=new g.C1(a);g.B(a,c);a.G=new Ssa(b,c,a.player.N(),a.player.getVideoData(),a.V,a.player,a.Oh)}return a.G},v3=function(a,b){var c=!1,d=b.getElementsByTagName("annotations");
if(d&&!(1>d.length)&&(d=d[0].getAttribute("itct"))){var e=g.ds();if(e){var f=g.bs();f&&g.ts(g.xo("use_default_events_client")?void 0:g.Qq,e,f,[g.Wr(d)])}}d=b.getElementsByTagName("annotation");for(e=0;e<d.length;e++){var k=tta(a,d[e]);f=null;try{if(k){var l=k.id,m=/.+/;var n="string"===typeof l&&null!=m&&null!=l&&l.match(m)?l:"";var p=W2(k.type,zta),t=W2(k.style,Ata),u=V2(k.data),z=0!=u.length?JSON.parse(u):{},C=Gsa(k.action);f=n&&p?new Z2(n,p,t,C,z):null}else f=null}catch(fa){}if(f){a:{switch(f.type){case "branding":case "promotion":k=
!0;break a}k=!1}if(k){k=a;m=f;var D=qta(),E=null;switch(m.type){case "branding":if(k.player.N().Ca)break;k.u.element.appendChild(D);E=new r3(D,w3(k),m);break;case "promotion":g.iL(k.player,D,4),E=new s3(D,w3(k),m)}E&&E.Em();if(k=E)g.B(a,k),a.F[f.id]=k}else if("card"==f.type||"drawer"==f.type){a.o||(a.o=yta(a),g.B(a,a.o));if("card"==f.type){if(c=a.o,E=f&&f.data&&f.data.card_type)switch(k=f.data.tracking||{},k={Yx:k.impression,click:k.click,close:k.close,qC:k.teaser_impression,Vp:k.teaser_click},m=
f.data.tracking_params||{},D=null,E){case "collaborator":f={id:f.id,timestamp:f.data.timestamp||0,type:f.data.card_type,teaserText:f.data.teaser_text,teaserDurationMs:f.data.teaser_duration_ms,startMs:f.data.start_ms,autoOpen:f.data.auto_open||!1,Ob:f.data.session_data||{},sponsored:f.data.sponsored||!1,Gc:k,de:m.card?g.Wr(m.card):null,Yd:m.teaser?g.Wr(m.teaser):null,yd:m.icon?g.Wr(m.icon):null,channelId:f.data.channel_id,customMessage:f.data.custom_message?f.data.custom_message:null,wB:f.data.image_url,
title:f.data.title,metaInfo:f.data.meta_info,url:X2({pause_on_navigation:f.data.pause_on_navigation,target:f.data.target||"new",value:f.data.url})};n3(c,f);break;case "episode":case "movie":f={id:f.id,timestamp:f.data.timestamp||0,type:f.data.card_type,teaserText:f.data.teaser_text,teaserDurationMs:f.data.teaser_duration_ms,startMs:f.data.start_ms,autoOpen:f.data.auto_open||!1,Ob:f.data.session_data||{},sponsored:f.data.sponsored||!1,Gc:k,de:m.card?g.Wr(m.card):null,Yd:m.teaser?g.Wr(m.teaser):null,
yd:m.icon?g.Wr(m.icon):null,jj:f.data.image_url,kw:f.data.badge_symbol||"",priceText:f.data.price_text||"",title:f.data.title,metaInfo:f.data.meta_info,fG:!!f.data.is_paygated,eP:!!f.data.user_has_entitlement,url:X2({target:f.data.target||"new",value:f.data.url})};n3(c,f);break;case "playlist":f={id:f.id,timestamp:f.data.timestamp||0,type:f.data.card_type,teaserText:f.data.teaser_text,teaserDurationMs:f.data.teaser_duration_ms,startMs:f.data.start_ms,autoOpen:f.data.auto_open||!1,Ob:f.data.session_data||
{},sponsored:f.data.sponsored||!1,Gc:k,de:m.card?g.Wr(m.card):null,Yd:m.teaser?g.Wr(m.teaser):null,yd:m.icon?g.Wr(m.icon):null,jj:f.data.image_url,playlistVideoCount:f.data.playlist_video_count,customMessage:f.data.custom_message?f.data.custom_message:null,title:f.data.title,metaInfo:f.data.meta_info,url:X2({pause_on_navigation:f.data.pause_on_navigation,target:f.data.target||"new",value:f.data.url})};n3(c,f);break;case "poll":f={id:f.id,timestamp:f.data.timestamp||0,type:f.data.card_type,teaserText:f.data.teaser_text,
teaserDurationMs:f.data.teaser_duration_ms,startMs:f.data.start_ms,autoOpen:f.data.auto_open||!1,Ob:f.data.session_data||{},sponsored:f.data.sponsored||!1,Gc:k,de:m.card?g.Wr(m.card):null,Yd:m.teaser?g.Wr(m.teaser):null,yd:m.icon?g.Wr(m.icon):null,title:f.data.title,choices:f.data.choices,Ce:f.data.hasOwnProperty("old_vote")?f.data.old_vote:null,ej:f.data.signin_url?X2({target:"current",value:f.data.signin_url}):null,pP:f.data.hasOwnProperty("xsrf_token")?f.data.xsrf_token:null};n3(c,f);break;case "productListing":f.data.signin_url&&
(D=X2({target:"current",value:f.data.signin_url}));E=[];for(var F=f.data.offers||[],G=0;G<F.length;G++)E.push(new Psa(g.fd(F[G].merchant),g.fd(F[G].price)));f={yT:!1,id:f.id,timestamp:f.data.timestamp||0,type:f.data.card_type,teaserText:f.data.teaser_text,teaserDurationMs:f.data.teaser_duration_ms,startMs:f.data.start_ms,autoOpen:f.data.auto_open||!1,Ob:f.data.session_data||{},sponsored:f.data.sponsored||!1,Gc:k,de:m.card?g.Wr(m.card):null,Yd:m.teaser?g.Wr(m.teaser):null,yd:m.icon?g.Wr(m.icon):null,
imageUrl:f.data.image_url,displayDomain:f.data.display_domain?f.data.display_domain:null,showLinkIcon:!!f.data.show_link_icon,qn:f.data.button_icon_url?f.data.button_icon_url:null,title:f.data.title,customMessage:f.data.custom_message?f.data.custom_message:null,url:X2({pause_on_navigation:f.data.pause_on_navigation,target:f.data.target||"new",value:f.data.url}),ej:D,VT:f.data.signin_title?f.data.signin_title:null,UT:f.data.signin_message?f.data.signin_message:null,offers:E};n3(c,f);break;case "simple":f=
{id:f.id,timestamp:f.data.timestamp||0,type:f.data.card_type,teaserText:f.data.teaser_text,teaserDurationMs:f.data.teaser_duration_ms,startMs:f.data.start_ms,autoOpen:f.data.auto_open||!1,Ob:f.data.session_data||{},sponsored:f.data.sponsored||!1,Gc:k,de:m.card?g.Wr(m.card):null,Yd:m.teaser?g.Wr(m.teaser):null,yd:m.icon?g.Wr(m.icon):null,imageUrl:f.data.image_url,displayDomain:f.data.display_domain?f.data.display_domain:null,showLinkIcon:!!f.data.show_link_icon,qn:f.data.button_icon_url?f.data.button_icon_url:
null,title:f.data.title,customMessage:f.data.custom_message?f.data.custom_message:null,url:X2({pause_on_navigation:f.data.pause_on_navigation,target:f.data.target||"new",value:f.data.url})};n3(c,f);break;case "video":f={id:f.id,timestamp:f.data.timestamp||0,type:f.data.card_type,teaserText:f.data.teaser_text,teaserDurationMs:f.data.teaser_duration_ms,startMs:f.data.start_ms,autoOpen:f.data.auto_open||!1,Ob:f.data.session_data||{},sponsored:f.data.sponsored||!1,Gc:k,de:m.card?g.Wr(m.card):null,Yd:m.teaser?
g.Wr(m.teaser):null,yd:m.icon?g.Wr(m.icon):null,jj:f.data.image_url,videoDuration:f.data.video_duration||null,customMessage:f.data.custom_message?f.data.custom_message:null,title:f.data.title,metaInfo:f.data.meta_info,isLiveNow:!!f.data.is_live_now,url:X2({pause_on_navigation:f.data.pause_on_navigation,target:f.data.target||"new",value:f.data.url})},n3(c,f)}}else bta(a.o,f);c=!0}}}c&&(A2(a.player),a.pp())},Bta=function(a,b){var c=!1;
a.o||(a.o=yta(a),g.B(a,a.o));for(var d=g.q(b.cards||[]),e=d.next();!e.done;e=d.next())cta(a.o,e.value.cardRenderer),c=!0;c&&(c=a.o,d=b.headerText?g.T(b.headerText):"",g.ye(c.Ca,d),c.R&&c.R.setAttribute("title",d),c.Z=b.trackingParams?g.Wr(b.trackingParams):null,c.M=b.closeButton.infoCardIconRenderer.trackingParams?g.Wr(b.closeButton.infoCardIconRenderer.trackingParams):null,c.I=b.icon.infoCardIconRenderer.trackingParams?g.Wr(b.icon.infoCardIconRenderer.trackingParams):null,A2(a.player),a.pp())},Cta=
function(a,b,c,d,e){if(!a.player.N().Ca){var f=[];
b.navigationEndpoint&&b.navigationEndpoint.browseEndpoint&&b.navigationEndpoint.browseEndpoint.browseId&&f.push(new Ksa("openUrl","click",new Isa("/channel/"+b.navigationEndpoint.browseEndpoint.browseId,"new",!0,!0),null));var k=b.watermark.thumbnails[0];d={channel_name:b.channelName,end_ms:b.endTimeMs,image_height:k.height,image_type:1,image_url:k.url,image_width:k.width,is_mobile:!1,session_data:{annotation_id:c,ei:e,feature:"iv",itct:b.trackingParams,src_vid:d},start_ms:b.startTimeMs};if(b.subscribeButton&&
b.subscribeButton.subscribeButtonRenderer){d.channel_id=b.subscribeButton.subscribeButtonRenderer.channelId;b=b.subscribeButton.subscribeButtonRenderer;k=e=null;b.subscribed?(b.subscriberCountWithUnsubscribeText&&(e=g.T(b.subscriberCountWithUnsubscribeText)),b.subscriberCountText&&(k=g.T(b.subscriberCountText))):(b.subscriberCountText&&(e=g.T(b.subscriberCountText)),b.subscriberCountWithSubscribeText&&(k=g.T(b.subscriberCountWithSubscribeText)));var l="";b.signInEndpoint&&b.signInEndpoint.webNavigationEndpointData&&
b.signInEndpoint.webNavigationEndpointData.url&&(l=b.signInEndpoint.webNavigationEndpointData.url);b={subscribeText:g.T(b.unsubscribedButtonText),subscribeCount:e,unsubscribeText:g.T(b.subscribedButtonText),unsubscribeCount:k,enabled:b.enabled,classic:!1,subscribed:b.subscribed,feature:"iv",signInUrl:l};d.standalone_subscribe_button_data=b}f=new Z2(c,"branding","branding",f,d);d=qta();a.u.element.appendChild(d);f=new r3(d,w3(a),f);f.Em();g.B(f,f);a.F[c]=f}},vta=function(a,b){return(0,g.x)(function(){if(!this.ea()){var c=
Array.prototype.slice.call(arguments,0);
c.unshift(b);b=g.Qa.apply(window,c);this.M.push(g.Tp(b))}},a)},D2={},E2=null;g.Sa(G2,g.Fn);g.h=G2.prototype;g.h.getDuration=function(){return this.duration};
g.h.play=function(a){if(a||0==this.o)this.progress=0,this.coords=this.w;else if(this.eb())return!1;F2(this);this.startTime=a=(0,g.H)();-1==this.o&&(this.startTime-=this.duration*this.progress);this.endTime=this.startTime+this.duration;this.B=this.startTime;this.progress||this.mp();this.re("play");-1==this.o&&this.re("resume");this.o=1;var b=g.Pa(this);b in D2||(D2[b]=this);rsa();ssa(this,a);return!0};
g.h.stop=function(a){F2(this);this.o=0;a&&(this.progress=1);tsa(this,this.progress);this.re("stop");this.pm()};
g.h.pause=function(){this.eb()&&(F2(this),this.o=-1,this.re("pause"))};
g.h.X=function(){0==this.o||this.stop(!1);this.re("destroy");G2.Gb.X.call(this)};
g.h.destroy=function(){this.dispose()};
g.h.Ut=function(){this.re("animate")};
g.h.re=function(a){this.dispatchEvent(new usa(a,this))};
g.Sa(usa,g.Je);g.Sa(H2,G2);H2.prototype.A=g.Ia;H2.prototype.Ut=function(){this.A();H2.Gb.Ut.call(this)};
H2.prototype.pm=function(){this.A();H2.Gb.pm.call(this)};
H2.prototype.mp=function(){this.A();H2.Gb.mp.call(this)};
g.Sa(I2,H2);I2.prototype.A=function(){this.element.style.left=Math.round(this.coords[0])+"px";this.element.style.top=Math.round(this.coords[1])+"px"};g.r(J2,g.A);J2.prototype.ka=function(a,b,c,d){c=(0,g.x)(c,d||this.u);a=g.Ep(a,b,c);this.o.push(a);return a};
J2.prototype.Ns=function(a,b,c,d){c=(0,g.x)(c,d||this.u);a=g.Op(a,b,c);this.o.push(a);return a};
J2.prototype.bb=function(a){g.Fp(a);g.db(this.o,a)};
J2.prototype.X=function(){g.Fp(this.o);this.o.length=0;g.A.prototype.X.call(this)};g.r(N2,g.vL);g.h=N2.prototype;g.h.load=function(){g.vL.prototype.load.call(this);if(!O2(this)){var a=g.JB(this.player.getVideoData());if(a)a=M2(a,xsa(this)),P2(this,a,!1);else{var b=this.player.getVideoData();a=b.videoId;this.A&&this.A.abort();a={method:"POST",Fc:(0,g.x)(this.YK,this,a),Zd:{v:a},withCredentials:!0};this.P&&(a.Zd.ptype="embedded");var c=this.player.getVideoData().Kn;c&&(a.sb={ad_tracking:c});if(b=g.IB(b))if(b=g.wc(b),b=g.uc(b))this.A=g.Eq(b,a)}}};
g.h.unload=function(){P2(this,null);this.A&&(this.A.abort(),this.A=null);g.vL.prototype.unload.call(this)};
g.h.Oc=function(a,b){if(!O2(this))return null;if("loadCustomEndscreenRenderer"==a){var c=M2(b,"new");P2(this,c);return!0}return null};
g.h.getOptions=function(){return O2(this)?["loadCustomEndscreenRenderer"]:[]};
g.h.YK=function(a,b){var c=this.A=null;if(200==b.status){var d=b.responseText;")]}"==d.substring(0,3)&&(d=d.substring(3),c=JSON.parse(d),c=M2(c,xsa(this)))}P2(this,c)};
g.h.Xy=function(){if(this.u&&this.u.elements){var a=this.player.getVideoContentRect();if(a&&0!=a.width&&0!=a.height){var b=this.player.getPlayerSize();if(b&&0!=b.width&&0!=b.height){var c=a.width/a.height;var d=0;for(var e=-1,f=0;f<Dta.length;f++){var k=Math.abs(b.width-Dta[f]);if(-1==e||d>=k)e=f,d=k}d=Eta[e];this.w&&g.sh(this.w.element,"outline-width",Math.max(b.width,b.height)+"px");for(b=0;b<this.u.elements.length;++b)if(f=this.u.elements[b].id,e=this.o[f],k=this.F[f],e&&k){var l=k.width*c/k.aspectRatio;
f=Math.round(l*a.height);var m=a.left+Math.round(k.left*a.width),n=a.top+Math.round(k.top*a.height);g.Mh(e.element,Math.round(k.width*a.width),f);g.Ah(e.element,m,n);g.En(e.element,Fta);m=k.left+k.width/2;k=k.top+l/2;g.J(e.element,.5>=m&&.5>=k?"ytp-ce-top-left-quad":.5<m&&.5>=k?"ytp-ce-top-right-quad":.5>=m&&.5<k?"ytp-ce-bottom-left-quad":"ytp-ce-bottom-right-quad");g.En(e.element,Eta);g.J(e.element,d);(e=g.ae(document,"div","ytp-ce-expanding-overlay-body",e.element)[0])&&g.sh(e,"height",f+"px")}}}}};
g.h.UG=function(a){if(this.u)if("ytp-ce-in-endscreen"==a.getId())T2(this,this.u.impressionUrls),(a=g.ds())&&this.u.visualElement&&g.us(a,this.u.visualElement);else{a=a.getId().substring(15);var b=this.o[a],c=this.F[a];g.J(b.element,"ytp-ce-element-show");b.element.removeAttribute("aria-hidden");b=this.player.getRootNode();g.J(b,"ytp-ce-shown");T2(this,c.impressionUrls);(b=g.ds())&&g.us(b,c.visualElement);this.player.N().w&&this.player.na("endscreenelementshown",a)}};
g.h.VG=function(a){if("ytp-ce-in-endscreen"!=a.getId()){a=a.getId().substring(15);var b=this.o[a];g.Dn(b.element,"ytp-ce-element-show");b.element.setAttribute("aria-hidden",!0);b=this.player.getRootNode();g.Dn(b,"ytp-ce-shown");this.player.N().w&&this.player.na("endscreenelementhidden",a)}};
g.h.JN=function(a){var b=this;a.target===window&&(new g.I(function(){for(var c in b.o)g.En(b.o[c].element,["ytp-ce-force-expand","ytp-ce-element-hover","ytp-ce-element-shadow-show"])},0)).start()};
g.h.yA=function(a,b){if(a.targetUrl&&(!b||"keypress"!=b.type||13==b.keyCode)){for(var c=b.target;c&&!g.Bn(c,"ytp-ce-element");){g.Bn(c,"subscribe-label")&&U2(this,a);if(g.Bn(c,"ytp-ce-channel-subscribe"))return;c=g.we(c)}if(!c||g.Bn(c,"ytp-ce-element-hover")){b.preventDefault();b.stopPropagation();if(c=this.o[a.id])this.au(c,a),c.element.blur();b.ctrlKey||b.metaKey||"new"==a.LO?(U2(this,a),this.aC(),this.player.pauseVideo(),c=g.wc(R2(this,a.targetUrl)),c=g.uc(c),g.GN(c,void 0,a.Ob)):(c=this.player.getVideoData().lc,
c=(0,g.x)(this.DO,this,c,R2(this,a.targetUrl),a.Ob),c=(0,g.x)(this.aC,this,c),U2(this,a,c))}}};
g.h.DO=function(a,b,c){var d=g.mq(b);a&&d&&(d.v||d.list)?g.rT(this.player.app,d.v,c,d.list,!1,void 0):g.FN(b,c)};
g.h.Xs=function(a,b){g.Bn(a.element,"ytp-ce-element-hover")||("VIDEO"==b.type||"PLAYLIST"==b.type?g.J(a.element,"ytp-ce-element-hover"):this.player.N().o?(new g.I(function(){g.J(a.element,"ytp-ce-element-hover")},200)).start():g.J(a.element,"ytp-ce-element-hover"),T2(this,b.UF),S2(this,b.id,!0))};
g.h.au=function(a,b){g.Dn(a.element,"ytp-ce-element-hover");g.Dn(a.element,"ytp-ce-force-expand");S2(this,b.id,!1)};
g.h.aC=function(a){this.player.sendVideoStatsEngageEvent(17,a)};
var Dta=[346,426,470,506,570,640,853,1280,1920],Eta="ytp-ce-size-346 ytp-ce-size-426 ytp-ce-size-470 ytp-ce-size-506 ytp-ce-size-570 ytp-ce-size-640 ytp-ce-size-853 ytp-ce-size-1280 ytp-ce-size-1920".split(" "),Fta=["ytp-ce-top-left-quad","ytp-ce-top-right-quad","ytp-ce-bottom-left-quad","ytp-ce-bottom-right-quad"];var Jsa={uQ:"current",SR:"new"};var Lsa={CLOSE:"close",VR:"openUrl",GD:"subscribe"},Msa={oQ:"click",CLOSE:"close",iR:"hidden",BS:"rollOut",CS:"rollOver",HS:"shown"};Z2.prototype.jc=function(){var a=Nsa(this,function(b){return"openUrl"==b.type&&null!=b.url});
return a?a.url:null};
var Ata={RP:"anchored",iD:"branding",CHANNEL:"channel",tQ:"cta",lR:"highlightText",CR:"label",PLAYLIST:"playlist",nS:"popup",MS:"speech",GD:"subscribe",XS:"title",VIDEO:"video",kT:"website"},zta={iD:"branding",fQ:"card",BQ:"drawer",kR:"highlight",JR:"marker",sS:"promotion",TEXT:"text",mT:"widget"};a3.prototype.u=function(a,b){var c=g.De(b.target,"label");c&&g.K(c,"iv-card-poll-choice-focused",a)};
a3.prototype.A=function(a,b){var c=g.De(b.target,null,"iv-card-poll",void 0);if(c)if(a.ej)g.ce("iv-card-sign-in-button",c).click();else{var d=parseInt(nsa(b.target),10);if(null==a.Ce)a.choices[d].count++,a.Ce=d;else if(a.Ce!=d){var e=a.choices[a.Ce];e.count=Math.max(e.count-1,0);a.choices[d].count++;a.Ce=d}else e=a.choices[a.Ce],e.count=Math.max(e.count-1,0),a.Ce=null;Usa(a,c);g.Iq(this.o.videoData.be,{Zd:{action_poll_vote:1},sb:{poll_id:a.id,index:d,session_token:a.pP}});$2(this.o.logger,a.Gc.click,
void 0,5);(c=g.ds())&&a.de&&g.zs(c,a.de)}};g.r(g3,g.A);g.h=g3.prototype;g.h.addCueRange=function(a,b,c,d,e){a=new g.iC(a,b,{id:c});a.namespace="annotations_module";d&&this.ga.set(a,d);e&&this.ma.set(a,e);g.eL(this.context.K,[a])};
g.h.Em=function(){this.context.u.subscribe("resize",this.un,this)};
g.h.ua=function(){return this.Ka};
g.h.yk=function(a,b,c,d,e,f){this.context.o.ka(a,"click",g.Qa(this.Co,b,c,d,e||[],f||0),this);this.context.o.ka(a,"touchstart",g.Qa(function(){this.dv=!1}),this);
this.context.o.ka(a,"touchmove",g.Qa(function(){this.dv=!0}),this)};
g.h.Co=function(a,b,c,d,e,f){if(this.dv)return!1;f&&(f.stopPropagation(),f.preventDefault());$sa(this,a,c,d,e);return!1};
g.h.show=function(){};
g.h.hide=function(){};
g.h.destroy=function(){g.te(this.ua())};
g.h.un=function(){};
g.h.X=function(){this.ga.clear();this.ma.clear();g.A.prototype.X.call(this)};g.r(k3,g3);g.h=k3.prototype;g.h.isAvailable=function(){var a;if(a=!!this.w.length)(a=this.u.getRootNode())?(a=g.Nh(a),a=173<a.width&&173<a.height):a=!1;return a};
g.h.un=function(){var a=this.isAvailable();g.Oh(this.ua(),a);g.K(this.context.K.getRootNode(),g.lM.IV_DRAWER_ENABLED,a);A2(this.u)};
g.h.destroy=function(){var a=g.XK(g.KK(this.u));a&&a.Ts(!1,void 0);try{this.u.getRootNode().removeChild(this.C)}catch(b){}g.Po(this.V);g.Fp(this.ha);this.da&&this.da.dispose();this.F&&this.F.dispose();g3.prototype.destroy.call(this)};
g.h.OL=function(a){this.ba.start();a.preventDefault();a=a||window.event;var b=0;"MozMousePixelScroll"==a.type?b=0==(a.axis==a.HORIZONTAL_AXIS)?a.detail:0:window.opera?b=a.detail:b=0==a.wheelDelta%120?"WebkitTransform"in document.documentElement.style?window.chrome&&0==navigator.platform.indexOf("Mac")?a.wheelDeltaY/-30:a.wheelDeltaY/-1.2:a.wheelDelta/-1.6:a.wheelDeltaY/-3;if(a=b)this.A.scrollTop+=a};
g.h.bC=function(a){if(!g.Bn(this.u.getRootNode(),"ytp-cards-teaser-shown")){if(this.o!=a){var b=g.ds(),c=this.o?this.o.card.yd:this.I;b&&c&&C2(b,[c]);this.o=a;o3(this)}if(b="none"!=this.ua().style.display)2==this.context.K.getPresentingPlayerType()?b=1==this.context.K.getAdState():(b=this.context.K.getPlayerState(),c=0==b&&0===this.context.K.getCurrentTime(),b=1==b||3==b||c);b&&a.card.teaserDurationMs&&(b={teaserText:a.card.teaserText,durationMs:a.card.teaserDurationMs},(c=g.XK(g.KK(this.u)))&&c.Ts(!0,
b));this.za.isActive()||((!this.B||!this.ba.isActive()&&this.aa)&&jta(this,a),this.za.start(910+a.card.teaserDurationMs))}};
g.h.vO=function(a){this.B||(this.o=a,o3(this),jta(this,a),i3(this,"YOUTUBE_DRAWER_AUTO_OPEN",!1))};
g.h.iE=function(){if(this.B){$2(this.context.logger,p3(this).Gc.close);var a=g.ds();a&&this.M&&g.zs(a,this.M);j3(this)}};
g.h.yE=function(){g.K(this.C,"iv-drawer-scrolled",0<this.A.scrollTop)};
g.h.oG=function(){var a=g.ds(),b=p3(this);b=b?b.yd:this.I;a&&b&&B2(a,[b])};
g.h.nG=function(){var a=g.ds(),b=p3(this);b=b?b.yd:this.I;a&&b&&C2(a,[b])};
g.h.rG=function(){var a=p3(this);$2(this.context.logger,a.Gc.qC);var b=g.ds();b&&a&&B2(b,[a.Yd,a.yd])};
g.h.qG=function(){var a=g.ds(),b=p3(this);a&&b&&C2(a,[b.Yd])};
g.h.pG=function(a){var b=p3(this),c=g.ds();this.o?a?(a=this.context.logger,$2(a,b.Gc.Vp),a.o.sendVideoStatsEngageEvent(4,void 0),c&&b.Yd&&g.zs(c,b.Yd)):(a=this.context.logger,$2(a,b.Gc.Vp),a.o.sendVideoStatsEngageEvent(4,void 0),c&&b.yd&&g.zs(c,b.yd)):(a=this.context.logger,$2(a,b.Gc.Vp),a.o.sendVideoStatsEngageEvent(4,void 0),c&&this.I&&g.zs(c,this.I))};g.r(q3,g3);q3.prototype.Em=function(){g3.prototype.Em.call(this);kta(this)};
q3.prototype.show=function(){g3.prototype.show.call(this);var a=g.ds(),b=this.annotation.data;a&&b&&(b=b.session_data)&&B2(a,[g.Wr(b.itct)])};
q3.prototype.hide=function(){g3.prototype.hide.call(this);var a=g.ds(),b=this.annotation.data;a&&b&&(b=b.session_data)&&C2(a,[g.Wr(b.itct)])};g.r(r3,q3);g.h=r3.prototype;g.h.EO=function(a,b,c,d){this.w.stop();if(!this.A){var e=g.Nh(a);this.o||(g.Jh(a,e.width),g.Jh(b,e.width));g.sh(c,"top",e.height-Math.max(Math.min(e.height,d)/2+10,20)+"px");g.sh(c,"right","1px");this.A=!0;g.Oh(a,!0);this.B=new g.I(function(){g.J(this.ua(),"iv-branding-active")},0,this);
this.B.start()}};
g.h.TF=function(a,b){g.Dn(this.ua(),"iv-branding-active");this.C=new g.I((0,g.x)(function(){g.Oh(a,!1);this.o||g.Jh(b,0)},this),250);
this.C.start();this.A=!1};
g.h.show=function(){if(!this.isActive){q3.prototype.show.call(this);if(!this.F){g.J(this.ua(),"iv-branding");var a=this.annotation.data;this.u=g.ne("IMG",{"aria-label":"Filigrane de cha\u00eene",src:a.image_url,"class":"branding-img iv-click-target",width:a.image_width,height:a.image_height});g.Oh(this.u,!1);var b=g.ne("DIV","branding-img-container",this.u);this.ua().appendChild(b);(b=this.annotation.jc())&&this.yk(this.u,b,this.annotation.id,a.session_data);if(a.channel_name){var c=g.ne("DIV","iv-branding-context-name");
g.ye(c,a.channel_name);var d=g.ne("DIV","iv-branding-context-subscribe");if(b=a.standalone_subscribe_button_data)this.o=new g.yQ(b.subscribeText,b.subscribeCount,b.unsubscribeText,b.unsubscribeCount,!!b.enabled,!!b.classic,a.channel_id,!!b.subscribed,b.feature,a.session_data.itct,b.signinUrl,this.context.K),this.o.ca(d);b=g.ne("DIV","iv-branding-context-subscribe-caret");c=g.ne("DIV","branding-context-container-inner",b,c,d);g.Oh(c,!1);d=g.ne("DIV","branding-context-container-outer",c);g.sh(d,"right",
a.image_width+"px");this.ua().appendChild(d);this.w=new g.I(g.Qa(this.TF,c,d),500,this);g.B(this,this.w);this.context.o.ka(this.ua(),"mouseover",(0,g.x)(this.EO,this,c,d,b,a.image_height));this.context.o.ka(this.ua(),"mouseout",(0,g.x)(this.w.start,this.w,void 0))}this.F=!0}g.Oh(this.ua(),!0);this.isActive=!0;if(this.u){a=this.u;var e=void 0===e?0:e;b=g.Eh(a);c=g.Nh(a);b=(new g.ph(b.x,b.y,c.width,c.height)).width;g.Ah(a,b);e=new I2(a,[b,a.offsetTop],[b-b-e,a.offsetTop],200,osa);g.B(this,e);this.context.w.ka(e,
"begin",g.Qa(g.Oh,a,!0));e.play()}}};
g.h.hide=function(){this.isActive&&(q3.prototype.hide.call(this),g.Oh(this.ua(),!1),this.isActive=!1)};
g.h.destroy=function(){this.o&&(this.o.dispose(),this.o=null);q3.prototype.destroy.call(this)};g.r(s3,q3);g.h=s3.prototype;g.h.show=function(){this.isActive||(q3.prototype.show.call(this),this.P||(lta(this),this.P=!0),g.Oh(this.ua(),!0),g.Uf(function(){g.Dn(this.ua(),"iv-promo-inactive")},100,this),this.ua().removeAttribute("aria-hidden"),this.isActive=!0,t3(this),nta(this),ota(this,this.F))};
g.h.hide=function(){this.isActive&&(g.J(this.ua(),"iv-promo-inactive"),this.isActive=!1,this.ua().setAttribute("aria-hidden",!0))};
g.h.Co=function(a,b,c,d,e,f){return this.B?!1:q3.prototype.Co.call(this,a,b,c,d,e,f)};
g.h.hs=function(a,b){b.stopPropagation();nta(this);ota(this,a);this.o.focus()};
g.h.xF=function(a){this.I=!0;this.hs(500,a)};
g.h.wF=function(){this.I=!1;mta(this)};
g.h.oF=function(a){a.stopPropagation();this.hide()};
g.h.pF=function(a){a.stopPropagation();t3(this);this.B=!0;g.J(this.ua(),"iv-promo-collapsed-no-delay");this.C.start()};
g.h.destroy=function(){this.C.dispose();q3.prototype.destroy.call(this)};g.r(u3,g.vL);g.h=u3.prototype;g.h.Oc=function(a,b){if(!rta(this.player.N().playerStyle))return null;switch(a){case "loadCustomAnnotationsXml":var c=g.B1(b);c&&v3(this,c);return!0;case "removeCustomAnnotationById":return b&&this.o&&(eta(this.o,b),A2(this.player)),!0}return null};
g.h.getOptions=function(){return rta(this.player.N().playerStyle)?["loadCustomAnnotationsXml","removeCustomAnnotationById"]:[]};
g.h.pp=function(){if(this.A){var a=g.QK(this.player).getVideoContentRect(!0);g.Mh(this.A.element,a.width,a.height);g.Ah(this.A.element,a.left,a.top)}if(this.o){var b=g.$K(this.player);a=this.o;b=b.width;g.K(a.C,"iv-drawer-small",426>=b);g.K(a.C,"iv-drawer-big",1280<=b)}};
g.h.lM=function(a){this.Rf(a.state);g.V(a.state,2)&&(this.Vl()&&this.Ny()&&2!=this.player.getPresentingPlayerType()&&this.setCardsVisible(!1),this.Ts(!1))};
g.h.load=function(){g.vL.prototype.load.call(this);this.Rf(g.PK(this.player));this.I++;var a=this.player.getVideoData(),b=a.videoId,c=(0,g.x)(this.aL,this,b,this.I),d=(0,g.x)(function(){this.C=null},this);
g.Vp()&&(c=vta(this,c));c={format:"XML",Fc:c,onError:d,Zd:{}};a.isPharma&&(c.Zd.pharma="1");c.method="POST";c.withCredentials=!0;(b=this.player.N().I.get(b))&&wta(c,b);b=b&&(b.An||b.zn);if(!a.ln||b)a.be?sta(this,a.be,c):(this.w=(0,g.x)(this.TG,this,c),this.player.addEventListener("videodatachange",this.w));g.iL(this.player,this.A.element,4);this.pp();(b=g.KB(a))&&Bta(this,b);(b=g.LB(a))&&b.featuredChannel&&Cta(this,b.featuredChannel,b.annotationId||"branding",a.videoId||null,a.eventId||null)};
g.h.Rf=function(a){a=!a.isCued()&&!g.V(a,1024);g.Qu(this.u,a);g.Qu(this.A,a)};
g.h.TG=function(a){var b=this.player.getVideoData();b.be&&(this.w&&(this.player.removeEventListener("videodatachange",this.w),this.w=null),sta(this,b.be,a))};
g.h.unload=function(){g.fR(this.player.app,"annotations_module",void 0);g.zb(this.F,function(a){a.destroy()});
this.G=null;this.o&&(this.o.destroy(),this.o=null,A2(this.player));this.P=!1;this.C&&(this.C.abort(),this.C=null);this.F={};this.u.hide();g.vL.prototype.unload.call(this);g.Nu(this.A);this.w&&(this.player.removeEventListener("videodatachange",this.w),this.w=null)};
g.h.aL=function(a,b,c){this.C=null;!uta(this,b,a)&&(a=g.yq(c)&&c.responseXML?c.responseXML:null)&&(v3(this,a),g.J(this.player.getRootNode(),"iv-module-loaded"))};
g.h.iB=function(a){a==this.player.getVideoData().videoId&&(this.loaded?xta(this):this.load())};
g.h.Vl=function(){return!!this.o&&this.o.isAvailable()};
g.h.Ny=function(){this.Vl();return!!this.o&&this.o.B};
g.h.setCardsVisible=function(a,b,c){b=void 0===b?!1:b;this.Vl();this.o&&(a?c?i3(this.o,c,b):i3(this.o,"YOUTUBE_DRAWER_AUTO_OPEN",b):j3(this.o))};
g.h.Ts=function(a,b){this.player.S(a?"cardsteasershow":"cardsteaserhide",b)};
g.h.X=function(){this.player.N().I.unsubscribe("vast_info_card_add",this.iB,this);g.Dn(this.player.getRootNode(),g.lM.IV_DRAWER_OPEN);for(var a=this.M,b=0,c=a.length;b<c;b++)g.Wp(a[b]);this.M.length=0;g.vL.prototype.X.call(this)};g.KL.annotations_module=u3;g.KL.creatorendscreen=N2;})(_yt_player);

View File

@ -0,0 +1,99 @@
(function(g){var window=this;var Jua=function(a,b){var c=(b-a.o)/(a.u-a.o);if(0>=c)return 0;if(1<=c)return 1;for(var d=0,e=1,f=0,k=0;8>k;k++){f=g.Nn(a,c);var l=(g.Nn(a,c+1E-6)-f)/1E-6;if(1E-6>Math.abs(f-b))return c;if(1E-6>Math.abs(l))break;else f<b?d=c:e=c,c-=(f-b)/l}for(k=0;1E-6<Math.abs(f-b)&&8>k;k++)f<b?(d=c,c=(c+e)/2):(e=c,c=(c+d)/2),f=g.Nn(a,c);return c},Kua=function(){return g.X?{D:"div",
Y:["ytp-icon","ytp-icon-small-close"]}:{D:"svg",O:{height:"100%",viewBox:"0 0 16 16",width:"100%"},J:[{D:"path",O:{d:"M13 4L12 3 8 7 4 3 3 4 7 8 3 12 4 13 8 9 12 13 13 12 9 8z",fill:"#fff"}}]}},D4=function(){return g.X?{D:"div",
Y:["ytp-icon","ytp-icon-watermark"]}:{D:"svg",O:{height:"100%",version:"1.1",viewBox:"0 0 110 26",width:"100%"},J:[{D:"path",Na:!0,H:"ytp-svg-fill",O:{d:"M 16.68,.99 C 13.55,1.03 7.02,1.16 4.99,1.68 c -1.49,.4 -2.59,1.6 -2.99,3 -0.69,2.7 -0.68,8.31 -0.68,8.31 0,0 -0.01,5.61 .68,8.31 .39,1.5 1.59,2.6 2.99,3 2.69,.7 13.40,.68 13.40,.68 0,0 10.70,.01 13.40,-0.68 1.5,-0.4 2.59,-1.6 2.99,-3 .69,-2.7 .68,-8.31 .68,-8.31 0,0 .11,-5.61 -0.68,-8.31 -0.4,-1.5 -1.59,-2.6 -2.99,-3 C 29.11,.98 18.40,.99 18.40,.99 c 0,0 -0.67,-0.01 -1.71,0 z m 72.21,.90 0,21.28 2.78,0 .31,-1.37 .09,0 c .3,.5 .71,.88 1.21,1.18 .5,.3 1.08,.40 1.68,.40 1.1,0 1.99,-0.49 2.49,-1.59 .5,-1.1 .81,-2.70 .81,-4.90 l 0,-2.40 c 0,-1.6 -0.11,-2.90 -0.31,-3.90 -0.2,-0.89 -0.5,-1.59 -1,-2.09 -0.5,-0.4 -1.10,-0.59 -1.90,-0.59 -0.59,0 -1.18,.19 -1.68,.49 -0.49,.3 -1.01,.80 -1.21,1.40 l 0,-7.90 -3.28,0 z m -49.99,.78 3.90,13.90 .18,6.71 3.31,0 0,-6.71 3.87,-13.90 -3.37,0 -1.40,6.31 c -0.4,1.89 -0.71,3.19 -0.81,3.99 l -0.09,0 c -0.2,-1.1 -0.51,-2.4 -0.81,-3.99 l -1.37,-6.31 -3.40,0 z m 29.59,0 0,2.71 3.40,0 0,17.90 3.28,0 0,-17.90 3.40,0 c 0,0 .00,-2.71 -0.09,-2.71 l -9.99,0 z m -53.49,5.12 8.90,5.18 -8.90,5.09 0,-10.28 z m 89.40,.09 c -1.7,0 -2.89,.59 -3.59,1.59 -0.69,.99 -0.99,2.60 -0.99,4.90 l 0,2.59 c 0,2.2 .30,3.90 .99,4.90 .7,1.1 1.8,1.59 3.5,1.59 1.4,0 2.38,-0.3 3.18,-1 .7,-0.7 1.09,-1.69 1.09,-3.09 l 0,-0.5 -2.90,-0.21 c 0,1 -0.08,1.6 -0.28,2 -0.1,.4 -0.5,.62 -1,.62 -0.3,0 -0.61,-0.11 -0.81,-0.31 -0.2,-0.3 -0.30,-0.59 -0.40,-1.09 -0.1,-0.5 -0.09,-1.21 -0.09,-2.21 l 0,-0.78 5.71,-0.09 0,-2.62 c 0,-1.6 -0.10,-2.78 -0.40,-3.68 -0.2,-0.89 -0.71,-1.59 -1.31,-1.99 -0.7,-0.4 -1.48,-0.59 -2.68,-0.59 z m -50.49,.09 c -1.09,0 -2.01,.18 -2.71,.68 -0.7,.4 -1.2,1.12 -1.49,2.12 -0.3,1 -0.5,2.27 -0.5,3.87 l 0,2.21 c 0,1.5 .10,2.78 .40,3.78 .2,.9 .70,1.62 1.40,2.12 .69,.5 1.71,.68 2.81,.78 1.19,0 2.08,-0.28 2.78,-0.68 .69,-0.4 1.09,-1.09 1.49,-2.09 .39,-1 .49,-2.30 .49,-3.90 l 0,-2.21 c 0,-1.6 -0.2,-2.87 -0.49,-3.87 -0.3,-0.89 -0.8,-1.62 -1.49,-2.12 -0.7,-0.5 -1.58,-0.68 -2.68,-0.68 z m 12.18,.09 0,11.90 c -0.1,.3 -0.29,.48 -0.59,.68 -0.2,.2 -0.51,.31 -0.81,.31 -0.3,0 -0.58,-0.10 -0.68,-0.40 -0.1,-0.3 -0.18,-0.70 -0.18,-1.40 l 0,-10.99 -3.40,0 0,11.21 c 0,1.4 .18,2.39 .68,3.09 .49,.7 1.21,1 2.21,1 1.4,0 2.48,-0.69 3.18,-2.09 l .09,0 .31,1.78 2.59,0 0,-14.99 c 0,0 -3.40,.00 -3.40,-0.09 z m 17.31,0 0,11.90 c -0.1,.3 -0.29,.48 -0.59,.68 -0.2,.2 -0.51,.31 -0.81,.31 -0.3,0 -0.58,-0.10 -0.68,-0.40 -0.1,-0.3 -0.21,-0.70 -0.21,-1.40 l 0,-10.99 -3.40,0 0,11.21 c 0,1.4 .21,2.39 .71,3.09 .5,.7 1.18,1 2.18,1 1.39,0 2.51,-0.69 3.21,-2.09 l .09,0 .28,1.78 2.62,0 0,-14.99 c 0,0 -3.40,.00 -3.40,-0.09 z m 20.90,2.09 c .4,0 .58,.11 .78,.31 .2,.3 .30,.59 .40,1.09 .1,.5 .09,1.21 .09,2.21 l 0,1.09 -2.5,0 0,-1.09 c 0,-1 -0.00,-1.71 .09,-2.21 0,-0.4 .11,-0.8 .31,-1 .2,-0.3 .51,-0.40 .81,-0.40 z m -50.49,.12 c .5,0 .8,.18 1,.68 .19,.5 .28,1.30 .28,2.40 l 0,4.68 c 0,1.1 -0.08,1.90 -0.28,2.40 -0.2,.5 -0.5,.68 -1,.68 -0.5,0 -0.79,-0.18 -0.99,-0.68 -0.2,-0.5 -0.31,-1.30 -0.31,-2.40 l 0,-4.68 c 0,-1.1 .11,-1.90 .31,-2.40 .2,-0.5 .49,-0.68 .99,-0.68 z m 39.68,.09 c .3,0 .61,.10 .81,.40 .2,.3 .27,.67 .37,1.37 .1,.6 .12,1.51 .12,2.71 l .09,1.90 c 0,1.1 .00,1.99 -0.09,2.59 -0.1,.6 -0.19,1.08 -0.49,1.28 -0.2,.3 -0.50,.40 -0.90,.40 -0.3,0 -0.51,-0.08 -0.81,-0.18 -0.2,-0.1 -0.39,-0.29 -0.59,-0.59 l 0,-8.5 c .1,-0.4 .29,-0.7 .59,-1 .3,-0.3 .60,-0.40 .90,-0.40 z"}}]}},
Lua=function(){return g.X?{D:"div",
Y:["ytp-icon","ytp-icon-youtube-logo-redirect"]}:{D:"svg",O:{fill:"#fff",height:"100%",viewBox:"0 0 24 24",width:"100%"},J:[{D:"path",O:{d:"M0 0h24v24H0V0z",fill:"none"}},{D:"path",O:{d:"M21.58 7.19c-.23-.86-.91-1.54-1.77-1.77C18.25 5 12 5 12 5s-6.25 0-7.81.42c-.86.23-1.54.91-1.77 1.77C2 8.75 2 12 2 12s0 3.25.42 4.81c.23.86.91 1.54 1.77 1.77C5.75 19 12 19 12 19s6.25 0 7.81-.42c.86-.23 1.54-.91 1.77-1.77C22 15.25 22 12 22 12s0-3.25-.42-4.81zM10 15V9l5.2 3-5.2 3z"}}]}},E4=function(a){g.A.call(this);
this.B=a;this.A=new g.Mn(0,0,.4,0,.2,1,1,1);this.u=new g.rn(this.w,window,this);g.B(this,this.u)},F4=function(a){g.R.call(this,{D:"div",
H:"ytp-related-on-error-overlay"});this.U=this.A=0;this.u=a;this.ba=new g.Gr(this);g.B(this,this.ba);a=a.N();this.C=[];this.w=[];this.F=0;this.aa=a.u;this.R=new g.R({D:"h2",H:"ytp-related-title",W:"{{title}}"});g.B(this,this.R);this.R.ca(this.element);this.G=new g.R({D:"div",H:"ytp-suggestions"});g.B(this,this.G);this.G.ca(this.element);this.M=new g.R({D:"button",Y:["ytp-button","ytp-previous"],O:{"aria-label":"Afficher les suggestions de vid\u00e9os pr\u00e9c\u00e9dentes"},J:[g.BM()]});g.B(this,
this.M);this.M.ca(this.element);this.M.ka("click",this.AI,this);this.da=new E4((0,g.x)(this.xz,this));g.B(this,this.da);this.Z=this.B=0;this.V=!0;for(var b=0;16>b;b++){var c=new g.R({D:"a",H:"ytp-suggestion-link",O:{href:"{{link}}",target:a.C,"aria-label":"{{aria_label}}"},J:[{D:"div",H:"ytp-suggestion-image",J:[{D:"div",O:{"data-is-live":"{{is_live}}"},H:"ytp-suggestion-duration",W:"{{duration}}"}]},{D:"div",H:"ytp-suggestion-title",O:{title:"{{hover_title}}"},W:"{{title}}"},{D:"div",H:"ytp-suggestion-author",
W:"{{views_or_author}}"}]});g.B(this,c);c.ca(this.G.element);var d=c.o["ytp-suggestion-link"];g.sh(d,"transitionDelay",b/20+"s");this.ba.L(d,"click",g.Qa(this.BI,b));this.C.push(c)}this.I=new g.R({D:"button",Y:["ytp-button","ytp-next"],O:{"aria-label":"Afficher plus de suggestions de vid\u00e9os"},J:[g.CM()]});g.B(this,this.I);this.I.ca(this.element);this.I.ka("click",this.zI,this);this.ba.L(this.u,"videodatachange",this.wz);Mua(this,g.QK(this.u).getPlayerSize());this.wz();this.show()},Mua=function(a,
b,c){var d=a.u.N(),e=16/9,f=650<=b.width,k=480>b.width||290>b.height,l=Math.min(a.w.length,a.C.length);
if(150>=Math.min(b.width,b.height)||0==l||!d.Aa)a.hide();else{var m;if(f){var n=m=28;a.A=16}else n=m=8,a.A=8;if(k){var p=6;f=14;var t=12;k=24;d=12}else p=8,f=18,t=16,k=36,d=16;b=b.width-(48+m+n);m=Math.ceil(b/150);m=Math.min(3,m);m=b/m-a.A;n=Math.floor(m/e);c&&n+100>c&&50<m&&(n=Math.max(c,50/e),m=Math.ceil(b/(e*(n-100)+a.A)),m=b/m-a.A,n=Math.floor(m/e));50>m||g.SK(a.u)?a.hide():a.show();for(c=0;c<l;c++){e=a.C[c];var u=e.o["ytp-suggestion-image"];u.style.width=m+"px";u.style.height=n+"px";e.o["ytp-suggestion-title"].style.width=
m+"px";e.o["ytp-suggestion-author"].style.width=m+"px";e=e.o["ytp-suggestion-duration"];e.style.display=e&&100>m?"none":""}l=f+p+t+4;a.U=l+d+(n-k)/2;a.G.element.style.height=n+l+"px";a.Z=m;a.F=b;a.B=0;a.xz(0);G4(a)}},Nua=function(a,b){var c=g.Md(b,a.F-a.w.length*(a.Z+a.A),0);
a.da.start(a.B,c,1E3);a.B=c;G4(a)},G4=function(a){a.I.element.style.bottom=a.U+"px";
a.M.element.style.bottom=a.U+"px";var b=a.B,c=a.F-a.w.length*(a.Z+a.A);g.K(a.element,"ytp-scroll-min",0<=b);g.K(a.element,"ytp-scroll-max",b<=c)},Oua=function(a){for(var b=0;b<a.w.length;b++){var c=b,d=a.w[b].ya();
c=a.C[c];var e=d.shortViewCount?d.shortViewCount:d.author,f=d.kh();g.Ly(a.u.N())&&(f=g.yd(f,g.DH({},"emb_rel_err")));c.element.style.display="";var k=c.o["ytp-suggestion-title"];g.Kn.test(d.title)?k.dir="rtl":g.Zqa.test(d.title)&&(k.dir="ltr");k=c.o["ytp-suggestion-author"];g.Kn.test(e)?k.dir="rtl":g.Zqa.test(e)&&(k.dir="ltr");k=void 0;d.va?k="En direct":k=d.lengthSeconds?g.hM(d.lengthSeconds):"";c.update({views_or_author:e,duration:k,link:f,hover_title:d.title,title:d.title,aria_label:d.Tk||null,
is_live:d.va});c=c.o["ytp-suggestion-image"];d=d.tc();c.style.backgroundImage=d?"url("+d+")":""}for(;b<a.C.length;b++)a.C[b].element.style.display="none";G4(a)},H4=function(a){g.XP.call(this,a);
a=a.N();a=new g.R({D:"a",H:"ytp-small-redirect",O:{href:g.tz(a),target:a.C,"aria-label":"Acc\u00e9der \u00e0 YouTube pour rechercher plus de vid\u00e9os"},J:[Lua()]});a.ca(this.element);g.B(this,a);this.w=new F4(this.api);this.w.ca(this.element);g.B(this,this.w);this.B=1;this.u(g.QK(this.api).getPlayerSize())},Pua=function(a,b){a.o["ytp-error-content"].style.paddingTop="0px";
var c=a.o["ytp-error-content"],d=c.clientHeight;Mua(a.w,b,b.height-d);if(a.api.N().F){var e=g.JM(),f=g.X?{D:"div",Y:["ytp-icon","ytp-icon-youtube-logo-redirect-large"]}:{D:"svg",O:{fill:"#fff",viewBox:"0 0 24 24"},J:[{D:"path",O:{d:"M0 0h24v24H0V0z",fill:"none"}},{D:"path",O:{d:"M21.58 7.19c-.23-.86-.91-1.54-1.77-1.77C18.25 5 12 5 12 5s-6.25 0-7.81.42c-.86.23-1.54.91-1.77 1.77C2 8.75 2 12 2 12s0 3.25.42 4.81c.23.86.91 1.54 1.77 1.77C5.75 19 12 19 12 19s6.25 0 7.81-.42c.86-.23 1.54-.91 1.77-1.77C22 15.25 22 12 22 12s0-3.25-.42-4.81zM10 15V9l5.2 3-5.2 3z"}}]},
k=1;480>b.width||290>b.height?(e={D:"div",Y:["ytp-icon","ytp-icon-error-exclamation-small"]},f=Lua(),k=0):650<=b.width&&(e={D:"div",Y:["ytp-icon","ytp-icon-error-exclamation-large"]},f=g.X?{D:"div",Y:["ytp-icon","ytp-icon-youtube-logo-redirect-extra-large"]}:{D:"svg",O:{fill:"#fff",height:"100%",viewBox:"0 0 24 24",width:"100%"},J:[{D:"path",O:{d:"M0 0h24v24H0V0z",fill:"none"}},{D:"path",O:{d:"M21.58 7.19c-.23-.86-.91-1.54-1.77-1.77C18.25 5 12 5 12 5s-6.25 0-7.81.42c-.86.23-1.54.91-1.77 1.77C2 8.75 2 12 2 12s0 3.25.42 4.81c.23.86.91 1.54 1.77 1.77C5.75 19 12 19 12 19s6.25 0 7.81-.42c.86-.23 1.54-.91 1.77-1.77C22 15.25 22 12 22 12s0-3.25-.42-4.81zM10 15V9l5.2 3-5.2 3z"}}]},
k=2);if(k!==a.B){e={"ytp-error-icon-container":e,"ytp-small-redirect":f};f=g.q(Object.keys(e));for(var l=f.next();!l.done;l=f.next()){l=l.value;var m=g.ce(l,a.element);g.re(m);(new g.R(e[l])).ca(m)}a.B=k}}c.style.paddingTop=(b.height-a.w.element.clientHeight)/2-d/2+"px"},I4=function(a,b){var c=a.N();
g.R.call(this,{D:"button",Y:["ytp-impression-link","ytp-button"]});this.hide();this.u=a;this.B=b;this.A=!1;g.kL(a,this.element,this,96714);var d=this.u.N(),e=this.u.getVideoData().lc,f=d.Ca,k=d.Yf;d=!d.Aa;var l=this.B.Rd();f||k||l||e||d||(g.P(c.experiments,"embeds_impression_link_call_to_action")&&(g.J(this.element,"show-cta-button"),(new g.R({D:"div",H:"ytp-impression-link-content",J:[{D:"div",H:"ytp-impression-link-text",W:"Regarder sur"},{D:"div",H:"ytp-impression-link-logo",J:[D4()]}]})).ca(this.element),
this.show()),g.P(c.experiments,"embeds_impression_link_video_thumbnail")&&Qua(this),g.P(c.experiments,"embeds_impression_link_channel_thumbnail")&&Rua(this),g.P(c.experiments,"embeds_impression_link_occlusion")&&Sua(this),g.P(c.experiments,"embeds_impression_link_hover")&&Tua(this),this.L(a,"presentingplayerstatechange",this.F),this.L(a,"videoplayerreset",this.G),this.L(this.element,"click",this.C))},Qua=function(a){var b,c,d,e,f;
g.Ba(function(k){if(1==k.o)return b=a.u.getVideoData(),g.ta(k,J4(a,b),2);c=k.u;if(!c)return k["return"]();d=c[0];a.w=d;g.J(a.element,"show-video-thumbnail-button");e=new g.R({D:"div",H:"ytp-impression-link-header",W:"Autres contenus YouTube"});e.ca(a.element);f=new g.R({D:"div",H:"ytp-impression-link-content",J:[{D:"div",H:"ytp-impression-link-metadata",J:[{D:"div",H:"ytp-impression-link-title",W:d.title},{D:"div",H:"ytp-impression-link-views-and-duration",W:"{{views_and_duration}}"}]},{D:"div",H:"ytp-impression-link-thumbnail"}]});
f.ca(a.element);K4(a,f,d);L4(a,f,d);a.show();k.o=0})},Rua=function(a){var b,c,d;
g.Ba(function(e){if(1==e.o)return g.ta(e,Uua(a),2);b=e.u;if(!b)return e["return"]();a.w=b;g.J(a.element,"show-channel-thumbnail-button");c=new g.R({D:"div",H:"ytp-impression-link-header",W:"Autres contenus YouTube"});c.ca(a.element);d=new g.R({D:"div",H:"ytp-impression-link-content",J:[{D:"div",H:"ytp-impression-link-metadata",J:[{D:"div",H:"ytp-impression-link-title",W:b.pl},{D:"div",H:"ytp-impression-link-subscribers",W:b.expandedSubtitle}]},{D:"div",H:"ytp-impression-link-thumbnail"}]});d.ca(a.element);
K4(a,d,b);a.show();e.o=0})},Sua=function(a){var b,c,d,e,f,k,l,m,n,p;
g.Ba(function(t){if(1==t.o)return b=a.u.getVideoData(),g.ta(t,J4(a,b),2);c=t.u;if(!c)return t["return"]();d=c[0];a.w=d;g.J(a.element,"show-occlusion-video-thumbnail-button");e=new g.R({D:"div",H:"ytp-impression-link-header",W:"Autres contenus YouTube"});e.ca(a.element);f=new g.R({D:"div",H:"ytp-impression-link-content",J:[{D:"div",H:"ytp-impression-link-metadata",J:[{D:"div",H:"ytp-impression-link-title",W:d.title},{D:"div",H:"ytp-impression-link-author",W:d.author},{D:"div",H:"ytp-impression-link-views",
W:"{{views}}"}]},{D:"div",H:"ytp-impression-link-thumbnail-and-duration",J:[{D:"div",H:"ytp-impression-link-thumbnail"},{D:"div",H:"ytp-impression-link-duration",W:"{{duration}}"}]}]});f.ca(a.element);K4(a,f,d);L4(a,f,d);k=new g.R({D:"button",Y:["ytp-button","ytp-impression-link-close"],J:[{D:"div",Y:["ytp-impression-link-close-icon"],J:[Kua()]}]});k.ca(a.element);k.ka("click",function(u){a.hide();g.oL(a.u,a.element,!1);u.stopPropagation()},a);
l=function(u){!g.q(u).next().value.isIntersecting&&a.element&&a.show()};
try{m={threshold:.8},n=new IntersectionObserver(l,m),p=document.querySelector("body"),n.observe(p)}catch(u){g.M(u)}t.o=0})},Tua=function(a){var b,c,d,e,f;
g.Ba(function(k){if(1==k.o)return b=a.u.getVideoData(),g.ta(k,J4(a,b),2);c=k.u;if(!c)return k["return"]();d=c[0];a.w=d;g.J(a.element,"show-video-thumbnail-expanding-button");a.L(a.element,"mouseenter",function(){g.J(a.element,"show-expanded-metadata");g.Dn(a.element,"show-collapsed-metadata")});
a.L(a.element,"mouseleave",function(){g.Dn(a.element,"show-expanded-metadata");g.J(a.element,"show-collapsed-metadata")});
e=new g.R({D:"div",H:"ytp-impression-link-header",W:"Plus de vid\u00e9os"});e.ca(a.element);f=new g.R({D:"div",H:"ytp-impression-link-content",J:[{D:"div",H:"ytp-impression-link-metadata",J:[{D:"div",H:"ytp-impression-link-title",W:d.title},{D:"div",H:"ytp-impression-link-views-and-duration",W:"{{views_and_duration}}"}]},{D:"div",H:"ytp-impression-link-thumbnail"}]});f.ca(a.element);K4(a,f,d);L4(a,f,d);a.show();k.o=0})},K4=function(a,b,c){a=g.P(a.u.N().experiments,"embeds_impression_link_channel_thumbnail")?
c.Id:c.tc();
b.o["ytp-impression-link-thumbnail"].style.backgroundImage=a?"url("+a+")":""},L4=function(a,b,c){a=a.u.N();
var d="";c.va?d="En direct":c.lengthSeconds&&(d=g.hM(c.lengthSeconds));c=c.shortViewCount?c.shortViewCount:"";var e="";c&&d?e=c+" \u2022 "+d:c?e=c:d&&(e=d);g.P(a.experiments,"embeds_impression_link_occlusion")?b.update({views:c,duration:d}):b.update({views_and_duration:e})},Vua=function(a,b){var c,d,e,f,k,l,m,n;
return g.Ba(function(p){return 1==p.o?(c=a.u.N(),d={format:"RAW",method:"GET",withCredentials:!0,timeout:3E4},e={},c.sendVisitorIdHeader&&b.visitorData&&(e["X-Goog-Visitor-Id"]=b.visitorData),(f=g.At(c.experiments,"debug_dapper_trace_id"))&&(e["X-Google-DapperTraceInfo"]=f),(k=g.At(c.experiments,"debug_sherlog_username"))&&(e["X-Youtube-Sherlog-Username"]=k),0<Object.keys(e).length&&(d.headers=e),l=g.BH(c,b,g.QK(a.u).getPlayerSize(),a.u.getVisibilityState(),0,""),l=g.yd(l,{is_embed_preview:"1"}),
m=function(t){return g.M(t)},g.ta(p,g.Kx(g.hr,l,d).then(void 0,m),2)):(n=p.u)&&n.responseText?p["return"](n):p["return"](null)})},J4=function(a,b){var c,d,e,f,k,l;
return g.Ba(function(m){if(1==m.o)return g.ta(m,Vua(a,b),2);c=m.u;if(!c)return m["return"](null);d=g.kq(c.responseText);e=g.lq(d.rvs);f=(0,g.ue)(e,function(n){return n&&!n.list});
k=a.u.N();return(l=(0,g.Cc)(f,function(n){n=g.jM(k,n);g.B(a,n);return n}))&&0!=l.length?m["return"](l):m["return"](null)})},Uua=function(a){var b,c,d,e,f,k,l,m;
return g.Ba(function(n){if(1==n.o)return b=a.u.getVideoData(),g.ta(n,J4(a,b),2);if(3!=n.o){c=n.u;if(!c)return n["return"](null);d=b.pl;e=c.filter(function(p){return null!==p&&p.author!==d});
return(f=e[0])?g.ta(n,Vua(a,f),3):n["return"](null)}k=n.u;if(!k)return n["return"](null);l=g.kq(k.responseText);m=new g.aB(a.u.N(),l);return n["return"](m)})},M4=function(a){g.R.call(this,{D:"div",
H:"ytp-muted-autoplay-endscreen-overlay",J:[{D:"div",H:"ytp-muted-autoplay-end-panel",J:[{D:"div",H:"ytp-muted-autoplay-end-text",W:"{{text}}"}]}]});this.u=a;this.A=this.o["ytp-muted-autoplay-end-panel"];this.w=new g.nN(a);g.B(this,this.w);this.w.ca(this.A,0);g.kL(a,this.element,this,52428);this.L(a,"presentingplayerstatechange",this.C);this.ka("click",this.B);this.hide()},N4=function(a){g.R.call(this,{D:"div",
H:"ytp-muted-autoplay-overlay",J:[{D:"div",H:"ytp-muted-autoplay-bottom-buttons",J:[{D:"button",Y:["ytp-muted-autoplay-equalizer","ytp-button"],J:[{D:"div",Y:["ytp-muted-autoplay-equalizer-icon"],J:[g.X?{D:"div",Y:["ytp-icon","ytp-icon-equalizer-animation"]}:{D:"svg",O:{height:"100%",version:"1.1",viewBox:"-4 -4 24 24",width:"100%"},J:[{D:"g",O:{fill:"#fff"},J:[{D:"rect",H:"ytp-equalizer-bar-left",O:{height:"9",width:"4",x:"1",y:"7"}},{D:"rect",H:"ytp-equalizer-bar-middle",O:{height:"14",width:"4",
x:"6",y:"2"}},{D:"rect",H:"ytp-equalizer-bar-right",O:{height:"12",width:"4",x:"11",y:"4"}}]}]}]}]}]}]});this.u=a;this.bottomButtons=this.o["ytp-muted-autoplay-bottom-buttons"];this.A=this.o["ytp-muted-autoplay-equalizer"];this.B=new g.I(this.C,4E3,this);g.kL(a,this.element,this,39306);this.L(a,"presentingplayerstatechange",this.w);this.L(a,"onMutedAutoplayStarts",this.w);this.ka("click",this.F);this.hide()},O4=function(a,b){g.R.call(this,{D:"div",
H:"ytp-pause-overlay"});this.u=a;this.aa=b;this.A=new g.Gr(this);g.B(this,this.A);this.V=new g.lN(this,1E3,!1,100);g.B(this,this.V);var c=a.N();"0"==c.controlsType&&g.J(a.getRootNode(),"ytp-pause-overlay-controls-hidden");this.C=[];this.w=[];this.F=0;this.da=c.u;this.Z=!1;this.oa=0;this.U=new g.R({D:"h2",H:"ytp-related-title",W:"{{title}}"});g.B(this,this.U);this.U.ca(this.element);this.G=new g.R({D:"div",H:"ytp-suggestions"});g.B(this,this.G);this.G.ca(this.element);this.R=new g.R({D:"button",Y:["ytp-button",
"ytp-previous"],O:{"aria-label":"Afficher les suggestions de vid\u00e9os pr\u00e9c\u00e9dentes"},J:[g.BM()]});g.B(this,this.R);this.R.ca(this.element);this.R.ka("click",this.vI,this);var d=g.Dt||g.vh?{style:"will-change: opacity"}:null;this.ga=new E4((0,g.x)(this.vz,this));g.B(this,this.ga);for(var e=this.ma=this.ba=this.B=0;16>e;e++){var f=new g.R({D:"a",H:"ytp-suggestion-link",O:{href:"{{link}}",target:c.C,"aria-label":"{{aria_label}}"},J:[{D:"div",H:"ytp-suggestion-image"},{D:"div",H:"ytp-suggestion-overlay",
O:d,J:[{D:"div",H:"ytp-suggestion-title",W:"{{title}}"},{D:"div",H:"ytp-suggestion-author",W:"{{author_and_views}}"},{D:"div",O:{"data-is-live":"{{is_live}}"},H:"ytp-suggestion-duration",W:"{{duration}}"}]}]});g.B(this,f);f.ca(this.G.element);var k=f.o["ytp-suggestion-link"];g.sh(k,"transitionDelay",e/20+"s");this.A.L(k,"click",g.Qa(this.wI,e));this.C.push(f)}this.M=new g.R({D:"button",Y:["ytp-button","ytp-next"],O:{"aria-label":"Afficher plus de suggestions de vid\u00e9os"},J:[g.CM()]});g.B(this,
this.M);this.M.ca(this.element);this.M.ka("click",this.uI,this);c=new g.R({D:"button",Y:["ytp-button","ytp-collapse"],O:{"aria-label":'Masquer la section "Plus de vid\u00e9os"'},J:[Kua()]});g.B(this,c);c.ca(this.element);c.ka("click",this.DK,this);this.I=new g.R({D:"button",Y:["ytp-button","ytp-expand"],W:"Plus de vid\u00e9os"});g.B(this,this.I);this.I.ca(this.element);this.I.ka("click",this.EK,this);this.A.L(this.u,"appresize",this.vt);this.A.L(this.u,"fullscreentoggled",this.xI);this.A.L(this.u,
"presentingplayerstatechange",this.yI);this.A.L(this.u,"videodatachange",this.uz);this.vt(g.QK(this.u).getPlayerSize());this.uz()},Wua=function(a,b){var c=g.Md(b,a.F-a.w.length*(a.ba+8),0);
a.ga.start(a.B,c,1E3);a.B=c;P4(a)},P4=function(a){var b=a.aa.kc();
b=a.ma/2+(b?32:16);a.M.element.style.bottom=b+"px";a.R.element.style.bottom=b+"px";b=a.B;var c=a.F-a.w.length*(a.ba+8);g.K(a.element,"ytp-scroll-min",0<=b);g.K(a.element,"ytp-scroll-max",b<=c)},Xua=function(a){for(var b=0;b<a.w.length;b++){var c=a.w[b].ya(),d=a.C[b],e=c.shortViewCount?c.author+" \u2022 "+c.shortViewCount:c.author;
d.element.style.display="";g.Yqa.test(c.title)&&(d.o["ytp-suggestion-title"].dir="rtl");g.Yqa.test(e)&&(d.o["ytp-suggestion-author"].dir="rtl");var f=void 0;c.va?f="En direct":f=c.lengthSeconds?g.hM(c.lengthSeconds):"";var k=c.kh();g.Ly(a.u.N())&&(k=g.yd(k,g.DH({},"emb_rel_pause")));d.update({author_and_views:e,duration:f,link:k,title:c.title,aria_label:c.Tk||null,is_live:c.va});d=d.o["ytp-suggestion-image"];c=c.tc();d.style.backgroundImage=c?"url("+c+")":""}for(;b<a.C.length;b++)a.C[b].element.style.display=
"none";P4(a)},Q4=function(a){var b=a.N();
g.R.call(this,{D:"a",Y:["ytp-watermark","yt-uix-sessionlink"],O:{target:b.C,href:"{{url}}","aria-label":g.gM("Regarder sur $WEBSITE",{WEBSITE:g.fz(b)}),"data-sessionlink":"feature=player-watermark"},J:[D4()]});this.u=a;this.A=null;this.B=!1;this.w=g.PK(a);g.kL(a,this.element,this,76758);this.L(a,"videodatachange",this.wt);this.L(a,"videodatachange",this.zz);this.L(a,"presentingplayerstatechange",this.DI);this.L(a,"appresize",this.yz);b=this.w;this.w!=b&&(this.w=b);this.wt();this.zz();this.yz(g.QK(a).getPlayerSize())},
R4=function(a){g.vL.call(this,a);
this.o=a;this.B=new g.Gr(this);g.B(this,this.B);this.load()},Yua=function(a,b){g.V(b,128)?(a.u||(a.u=new H4(a.o),g.B(a,a.u),g.iL(a.o,a.u.element,4)),a.u.A(b.u),a.u.show(),g.J(a.o.getRootNode(),"ytp-embed-error")):a.u&&(a.u.dispose(),a.u=null,g.Dn(a.o.getRootNode(),"ytp-embed-error"))};
g.r(E4,g.A);E4.prototype.start=function(a,b,c){this.o=a;this.G=b;this.C=c;this.F=(0,g.N)();this.w()};
E4.prototype.w=function(){var a=(0,g.N)()-this.F;var b=this.A;a=Jua(b,a/this.C);if(0==a)b=b.B;else if(1==a)b=b.G;else{var c=g.Od(b.B,b.C,a),d=g.Od(b.C,b.F,a);b=g.Od(b.F,b.G,a);c=g.Od(c,d,a);d=g.Od(d,b,a);b=g.Od(c,d,a)}b=g.Md(b,0,1);this.B((this.G-this.o)*b+this.o);1>b&&this.u.start()};g.r(F4,g.R);g.h=F4.prototype;g.h.hide=function(){this.V=!0;g.R.prototype.hide.call(this)};
g.h.show=function(){this.V=!1;g.R.prototype.show.call(this)};
g.h.isHidden=function(){return this.V};
g.h.zI=function(){Nua(this,this.B-this.F)};
g.h.AI=function(){Nua(this,this.B+this.F)};
g.h.BI=function(a,b){var c=this.w[a],d=c.Ob;if(g.IN(b,this.u,this.aa,d||void 0)){var e=c.ya().videoId;c=c.getPlaylistId();g.rT(this.u.app,e,d,c,void 0,void 0)}};
g.h.wz=function(){var a=this,b=this.u.getVideoData(),c=this.u.N();this.aa=b.lc?!1:c.u;if(b.suggestions){var d=(0,g.ue)(b.suggestions,function(e){return e&&!e.list});
this.w=(0,g.Cc)(d,function(e){e=g.jM(c,e);g.B(a,e);return e})}else this.w.length=0;
Oua(this);b.lc?this.R.update({title:g.gM("Autres vid\u00e9os de $DNI_RELATED_CHANNEL",{DNI_RELATED_CHANNEL:b.author})}):this.R.update({title:"Plus de vid\u00e9os sur YouTube"})};
g.h.xz=function(a){this.G.element.scrollLeft=-a};g.r(H4,g.XP);H4.prototype.show=function(){g.XP.prototype.show.call(this);Pua(this,g.QK(this.api).getPlayerSize())};
H4.prototype.u=function(a){g.XP.prototype.u.call(this,a);Pua(this,a);g.K(this.element,"related-on-error-overlay-visible",!this.w.isHidden())};
H4.prototype.A=function(a){g.XP.prototype.A.call(this,a);var b=this.api.getVideoData(),c=g.P(this.api.N().experiments,"embeds_enable_sg_misinfo"),d;if(a.dh){if(b.Qn){a:{a=b.Qn;if(a.runs)for(var e=0;e<a.runs.length;e++)if(a.runs[e].navigationEndpoint){a=!0;break a}a=!1}a?d=g.Yz(b.Qn):d=g.YP(g.T(b.Qn))}else d=g.YP(a.dh);this.qb(d,"subreason")}(b=b.Qw)&&c&&(b.reason&&(c=g.Yz(b.reason),this.qb(c,"content")),b.subreason&&(c=g.Yz(b.subreason),this.qb(c,"subreason")))};g.r(I4,g.R);I4.prototype.F=function(){g.PK(this.u).isCued()||(this.hide(),g.oL(this.u,this.element,!1))};
I4.prototype.G=function(){this.A=!0;this.hide();g.oL(this.u,this.element,!1)};
I4.prototype.C=function(a){var b=this.u.N();b=g.P(b.experiments,"embeds_impression_link_channel_thumbnail")?g.tz(b)+this.w.sf:g.P(b.experiments,"embeds_impression_link_call_to_action")?this.u.getVideoUrl():this.w.kh();var c=this.u.N();c=g.P(c.experiments,"embeds_impression_link_call_to_action")?"emb_imp_woyt":g.P(c.experiments,"embeds_impression_link_video_thumbnail")?"emb_imp_rv":g.P(c.experiments,"embeds_impression_link_channel_thumbnail")?"emb_imp_rc":g.P(c.experiments,"embeds_impression_link_occlusion")?
"emb_imp_rv_oc":"emb_imp_rv_ex";b=g.yd(b,g.DH({},c));g.JN(b,this.u,a);g.nL(this.u,this.element)};
I4.prototype.show=function(){g.PK(this.u).isCued()&&!this.A&&(g.R.prototype.show.call(this),g.pL(this.u,this.element)&&g.oL(this.u,this.element,!0))};g.r(M4,g.R);M4.prototype.C=function(){var a=g.PK(this.u),b=this.u.getVideoData();g.P(this.u.N().experiments,"embeds_enable_muted_autoplay")&&b.mutedAutoplay&&(g.V(a,2)&&!this.Ha()?(this.show(),this.w.show(),a=this.u.getVideoData(),this.la("text",a.Zz),g.K(this.element,"ytp-muted-autoplay-show-end-panel",!0),g.oL(this.u,this.element,this.Ha()),this.u.na("onMutedAutoplayEnds")):this.hide())};
M4.prototype.B=function(){var a=this.u.getVideoData(),b=this.u.getCurrentTime();a.mutedAutoplay=!1;a.endSeconds=NaN;a.Kd();this.u.loadVideoById(a.videoId,b);g.nL(this.u,this.element);this.hide()};g.r(N4,g.R);N4.prototype.w=function(){var a=g.PK(this.u),b=this.u.getVideoData(),c=this.u.N();b=g.P(c.experiments,"embeds_enable_muted_autoplay")&&b.mutedAutoplay;c=!c.F;!b||g.V(a,2)?this.hide():this.Ha()||(g.R.prototype.show.call(this),c||(this.A.style.display="none"),this.B.start(),g.oL(this.u,this.element,this.Ha()))};
N4.prototype.C=function(){g.K(this.element,"ytp-muted-autoplay-hide-watermark",!0)};
N4.prototype.F=function(){var a=this.u.getVideoData(),b=this.u.getCurrentTime();a.mutedAutoplay=!1;a.endSeconds=NaN;a.Kd();this.u.loadVideoById(a.videoId,b);g.nL(this.u,this.element)};g.r(O4,g.R);g.h=O4.prototype;g.h.hide=function(){g.Dn(this.u.getRootNode(),"ytp-expand-pause-overlay");g.R.prototype.hide.call(this)};
g.h.DK=function(){this.Z=!0;g.Dn(this.u.getRootNode(),"ytp-expand-pause-overlay");this.I.focus()};
g.h.EK=function(){this.Z=!1;g.J(this.u.getRootNode(),"ytp-expand-pause-overlay")};
g.h.uI=function(){Wua(this,this.B-this.F)};
g.h.vI=function(){Wua(this,this.B+this.F)};
g.h.wI=function(a,b){if(1E3>(0,g.N)()-this.oa)g.Kp(b),document.activeElement.blur();else{var c=this.w[a],d=c.Ob;if(g.IN(b,this.u,this.da,d||void 0)){var e=c.ya().videoId;c=c.getPlaylistId();g.rT(this.u.app,e,d,c,void 0,void 0)}}};
g.h.xI=function(){this.vt(g.QK(this.u).getPlayerSize())};
g.h.yI=function(a){if(!(g.V(a.state,1)||g.V(a.state,16)||g.V(a.state,32))){var b=!g.P(this.u.N().experiments,"embeds_disable_pauseoverlay_on_autoplay_blocked_killswitch")&&g.V(a.state,2048);!g.V(a.state,4)||g.V(a.state,2)||b?this.V.hide():this.w.length&&(this.Z||(g.J(this.u.getRootNode(),"ytp-expand-pause-overlay"),P4(this)),this.V.show(),this.oa=(0,g.N)())}};
g.h.vt=function(a){var b=16/9,c=this.aa.kc();a=a.width-(c?112:58);c=Math.ceil(a/(c?320:192));c=(a-8*c)/c;b=Math.floor(c/b);for(var d=0;d<this.C.length;d++){var e=this.C[d].o["ytp-suggestion-image"];e.style.width=c+"px";e.style.height=b+"px"}this.G.element.style.height=b+"px";this.ba=c;this.ma=b;this.F=a;this.B=0;this.vz(0);P4(this)};
g.h.uz=function(){var a=this,b=this.u.N(),c=this.u.getVideoData();this.da=c.lc?!1:b.u;if(c.suggestions){var d=(0,g.ue)(c.suggestions,function(e){return e&&!e.list});
this.w=(0,g.Cc)(d,function(e){e=g.jM(b,e);g.B(a,e);return e})}else this.w.length=0;
Xua(this);c.lc?this.U.update({title:g.gM("Autres vid\u00e9os de $DNI_RELATED_CHANNEL",{DNI_RELATED_CHANNEL:c.author})}):this.U.update({title:"Plus de vid\u00e9os"})};
g.h.vz=function(a){this.G.element.scrollLeft=-a};g.r(Q4,g.R);g.h=Q4.prototype;g.h.wt=function(){var a=this.u.getVideoData(),b=this.u.N();a=a.mutedAutoplay||b.Ca&&!g.V(this.w,2);g.Qu(this,a);g.oL(this.u,this.element,a)};
g.h.DI=function(a){a=a.state;this.w!=a&&(this.w=a);this.wt()};
g.h.zz=function(){if(this.u.getVideoData().videoId){var a=this.u.getVideoUrl(!0,!1,!1,!0);this.la("url",a);this.A||(this.A=this.ka("click",this.CI))}else this.A&&(this.la("url",null),this.bb(this.A),this.A=null)};
g.h.CI=function(a){var b=this.u.getVideoUrl(!g.iM(a),!1,!0,!0);g.JN(b,this.u,a);g.nL(this.u,this.element)};
g.h.yz=function(a){var b=this.u.N(),c=480>a.width;if(c&&!this.B||!c&&this.B)a=480>a.width&&b.F?{D:"div",Y:["ytp-icon","ytp-icon-watermark-small"]}:D4(),a=new g.R(a),b=this.o["ytp-watermark"],g.K(b,"ytp-watermark-small",c),g.re(b),a.ca(b),this.B=c};g.r(R4,g.vL);g.h=R4.prototype;g.h.Pf=function(){return!1};
g.h.create=function(){var a=this.o.N(),b=g.dC(this.o);a.Aa&&(this.G=new O4(this.o,b),g.B(this,this.G),g.iL(this.o,this.G.element,4));g.P(a.experiments,"embeds_enable_muted_autoplay")&&(this.w=new N4(this.o),g.B(this,this.w),g.iL(this.o,this.w.element,4),this.F=new M4(this.o),g.B(this,this.F),g.iL(this.o,this.F.element,4));if(a.Ca||this.w)this.A=new Q4(this.o),g.B(this,this.A),g.iL(this.o,this.A.element,7);g.P(a.experiments,"embeds_impression_link")&&(this.C=new I4(this.o,b),g.B(this,this.C),g.iL(this.o,
this.C.element,7));this.B.L(this.o,"appresize",this.rI);this.B.L(this.o,"presentingplayerstatechange",this.qI);this.B.L(this.o,"videodatachange",this.aP);this.B.L(this.o,"onMutedAutoplayStarts",this.RL);Yua(this,g.PK(this.o));g.fL(this.player,"embed")};
g.h.rI=function(){var a=g.QK(this.o).getPlayerSize();this.u&&this.u.u(a)};
g.h.qI=function(a){Yua(this,a.state)};
g.h.RL=function(){this.o.getVideoData().mutedAutoplay&&this.w&&this.A&&this.A.ca(this.w.bottomButtons,0)};
g.h.aP=function(){var a=this.o.getVideoData();this.A&&this.w&&!a.mutedAutoplay&&g.xe(this.w.element,this.A.element)&&g.iL(this.o,this.A.element,7)};g.KL.embed=R4;})(_yt_player);

View File

@ -0,0 +1,64 @@
(function(g){var window=this;var S4=function(a,b,c){var d=b.ya();g.K(a.element,"ytp-suggestion-set",!!d.videoId);var e=b.getPlaylistId();c=b.tc(c?c:"mqdefault.jpg");var f=b instanceof g.aB&&b.lengthSeconds?g.hM(b.lengthSeconds):null,k=!!e;e=k&&"RD"===(new g.mC(e.substr(0,2),e.substr(2))).type;var l=b instanceof g.aB?b.va:null;d={title:b.title,author:b.author,author_and_views:d.shortViewCount?b.author+" \u2022 "+d.shortViewCount:b.author,aria_label:b.Tk||g.gM("Regarder $TITLE",{TITLE:b.title}),duration:f,url:b.kh(),is_live:l,
is_list:k,is_mix:e,background:c?"background-image: url("+c+")":""};b instanceof g.nC&&(d.playlist_length=b.getLength());a.update(d)},T4=function(a){g.R.call(this,{D:"div",
Y:["ytp-upnext","ytp-player-content"],O:{"aria-label":"{{aria_label}}"},J:[{D:"div",H:"ytp-cued-thumbnail-overlay-image",O:{style:"{{background}}"}},{D:"span",H:"ytp-upnext-top",J:[{D:"span",H:"ytp-upnext-header",W:"\u00c0 suivre"},{D:"span",H:"ytp-upnext-title",W:"{{title}}"},{D:"span",H:"ytp-upnext-author",W:"{{author}}"}]},{D:"a",H:"ytp-upnext-autoplay-icon",O:{role:"button",href:"{{url}}","aria-label":"Lire la vid\u00e9o suivante"},J:[{D:"svg",O:{height:"100%",version:"1.1",viewBox:"0 0 72 72",
width:"100%"},J:[{D:"circle",H:"ytp-svg-autoplay-circle",O:{cx:"36",cy:"36",fill:"#fff","fill-opacity":"0.3",r:"31.5"}},{D:"circle",H:"ytp-svg-autoplay-ring",O:{cx:"-36",cy:"36","fill-opacity":"0",r:"33.5",stroke:"#FFFFFF","stroke-dasharray":"211","stroke-dashoffset":"-211","stroke-width":"4",transform:"rotate(-90)"}},{D:"path",H:"ytp-svg-fill",O:{d:"M 24,48 41,36 24,24 V 48 z M 44,24 v 24 h 4 V 24 h -4 z"}}]}]},{D:"span",H:"ytp-upnext-bottom",J:[{D:"span",H:"ytp-upnext-cancel"},{D:"span",H:"ytp-upnext-paused",
W:"La lecture automatique est d\u00e9sactiv\u00e9e"}]}]});this.B=null;var b=this.o["ytp-upnext-cancel"];this.B=new g.R({D:"button",Y:["ytp-upnext-cancel-button","ytp-button"],O:{tabindex:"0","aria-label":"Annuler la lecture automatique"},W:"Annuler"});g.B(this,this.B);this.B.ka("click",this.tK,this);this.B.ca(b);this.u=a;this.M=this.o["ytp-svg-autoplay-ring"];this.F=this.C=this.w=this.A=null;this.G=new g.I(this.En,5E3,this);g.B(this,this.G);this.I=0;g.kL(this.u,this.element,this,18788);this.L(this.o["ytp-upnext-autoplay-icon"],
"click",this.gM);this.mA();this.L(a,"autonavvisibility",this.mA);this.L(a,"mdxnowautoplaying",this.wL);this.L(a,"mdxautoplaycanceled",this.xL);this.L(a,"mdxautoplayupnext",this.LC);3==this.u.getPresentingPlayerType()&&(a=(a=g.RK(g.KK(this.u)))?a.fF():null)&&this.LC(a);g.K(this.element,"ytp-upnext-mobile",this.u.N().o)},U4=function(a,b){if(!a.w){g.Qo("a11y-announce","\u00c0 suivre "+a.A.title);
a.I=(0,g.N)();a.w=new g.I((0,g.x)(a.Rq,a,b),25);a.Rq(b);var c=b||g.Q(a.u.N().experiments,"autoplay_time")||1E4;a.u.na("onAutonavCoundownStarted",c)}g.Dn(a.element,"ytp-upnext-autoplay-paused")},W4=function(a){V4(a);
a.I=(0,g.N)();a.Rq();g.J(a.element,"ytp-upnext-autoplay-paused")},V4=function(a){a.w&&(a.w.dispose(),a.w=null)},X4=function(a,b){g.R.call(this,{D:"div",
Y:["html5-endscreen","ytp-player-content",b||"base-endscreen"]});this.created=!1;this.player=a},Zua=function(a){X4.call(this,a,"subscribecard-endscreen");
var b=a.getVideoData();this.u=new g.R({D:"div",H:"ytp-subscribe-card",J:[{D:"img",H:"ytp-author-image",O:{src:b.Id}},{D:"div",H:"ytp-subscribe-card-right",J:[{D:"div",H:"ytp-author-name",W:b.author},{D:"div",H:"html5-subscribe-button-container"}]}]});g.B(this,this.u);this.u.ca(this.element);this.subscribeButton=new g.yQ("S'abonner",null,"Se d\u00e9sabonner",null,!0,!1,b.Ng,b.subscribed,"trailer-endscreen",null,null,a);g.B(this,this.subscribeButton);this.subscribeButton.ca(this.u.o["html5-subscribe-button-container"]);
this.hide()},Y4=function(a){var b=a.N(),c=g.Dt||g.vh?{style:"will-change: opacity"}:void 0,d=b.u,e=["ytp-videowall-still"];
b.o&&e.push("ytp-videowall-show-text");g.R.call(this,{D:"a",Y:e,O:{href:"{{url}}",target:d?b.C:"","aria-label":"{{aria_label}}","data-is-live":"{{is_live}}","data-is-list":"{{is_list}}","data-is-mix":"{{is_mix}}"},J:[{D:"div",H:"ytp-videowall-still-image",O:{style:"{{background}}"}},{D:"span",H:"ytp-videowall-still-info",J:[{D:"span",H:"ytp-videowall-still-info-bg",J:[{D:"span",H:"ytp-videowall-still-info-content",O:c,J:[{D:"span",H:"ytp-videowall-still-info-title",W:"{{title}}"},{D:"span",H:"ytp-videowall-still-info-author",
W:"{{author_and_views}}"},{D:"span",H:"ytp-videowall-still-info-live",W:"En direct"},{D:"span",H:"ytp-videowall-still-info-duration",W:"{{duration}}"}]}]}]},{D:"span",Y:["ytp-videowall-still-listlabel-regular","ytp-videowall-still-listlabel"],J:[{D:"span",H:"ytp-videowall-still-listlabel-icon"},"Playlist",{D:"span",H:"ytp-videowall-still-listlabel-length",J:[" (",{D:"span",W:"{{playlist_length}}"},")"]}]},{D:"span",Y:["ytp-videowall-still-listlabel-mix","ytp-videowall-still-listlabel"],J:[{D:"span",
H:"ytp-videowall-still-listlabel-mix-icon"},"Mix",{D:"span",H:"ytp-videowall-still-listlabel-length",W:" (50+)"}]}]});this.suggestion=null;this.u=d;this.api=a;this.w=new g.Gr(this);g.B(this,this.w);this.ka("click",this.onClick);this.ka("keypress",this.B);this.w.L(a,"videodatachange",this.A);g.lL(a,this.element,this);this.A()},Z4=function(a){X4.call(this,a,"videowall-endscreen");
var b=this;this.K=a;this.A=0;this.stills=[];this.B=this.videoData=this.suggestions=null;this.C=this.I=!1;this.G=null;this.w=new g.RQ(this);g.B(this,this.w);this.F=new g.I(function(){g.J(b.element,"ytp-show-tiles")},0);
g.B(this,this.F);var c=new g.R({D:"button",Y:["ytp-button","ytp-endscreen-previous"],O:{"aria-label":"Pr\u00e9c\u00e9dente"},J:[g.BM()]});g.B(this,c);c.ca(this.element);c.ka("click",this.uH,this);this.table=new g.Mu({D:"div",H:"ytp-endscreen-content"});g.B(this,this.table);this.table.ca(this.element);c=new g.R({D:"button",Y:["ytp-button","ytp-endscreen-next"],O:{"aria-label":"Suivante"},J:[g.CM()]});g.B(this,c);c.ca(this.element);c.ka("click",this.tH,this);this.u=new T4(a);g.B(this,this.u);g.iL(this.player,
this.u.element,4);this.hide()},$4=function(a){return g.jL(a.player)&&a.iw()&&!a.B},$ua=function(a,b){return(0,g.Cc)(b.suggestions,function(c){c=g.jM(a.K.N(),c);
g.B(a,c);return c})},a5=function(a){var b=a.gt();
b!==a.I&&(a.I=b,a.player.S("autonavvisibility"))},b5=function(a){g.vL.call(this,a);
this.endScreen=null;this.listeners=new g.Gr(this);g.B(this,this.listeners);this.o=a.N();ava(a)?this.endScreen=new Z4(this.player):this.o.Ta?this.endScreen=new Zua(this.player):this.endScreen=new X4(this.player);g.B(this,this.endScreen);g.iL(this.player,this.endScreen.element,4);this.UB();this.listeners.L(a,"videodatachange",this.UB,this);this.listeners.L(a,g.lC("endscreen"),this.qH,this);this.listeners.L(a,"crx_endscreen",this.rH,this)},ava=function(a){a=a.N();
return a.Aa&&!a.Ta};
g.r(T4,g.R);g.h=T4.prototype;g.h.En=function(){this.C&&(this.G.stop(),this.bb(this.F),this.F=null,this.C.close(),this.C=null)};
g.h.mA=function(){g.Qu(this,g.LK(this.u));g.oL(this.u,this.element,g.LK(this.u))};
g.h.VL=function(){window.focus();this.En()};
g.h.hide=function(){g.R.prototype.hide.call(this)};
g.h.Rq=function(a){a=a||g.Q(this.u.N().experiments,"autoplay_time")||1E4;var b=Math.min((0,g.N)()-this.I,a);a=Math.min(b/a,1);this.M.setAttribute("stroke-dashoffset",-211*(a+1));1<=a&&3!=this.u.getPresentingPlayerType()?this.select(!0):this.w&&this.w.start()};
g.h.select=function(a){a=void 0===a?!1:a;if(g.P(this.u.N().experiments,"autonav_notifications")&&a&&window.Notification&&document.hasFocus){var b=Notification.permission;"default"==b?Notification.requestPermission():"granted"!=b||document.hasFocus()||(b=this.A.ya(),this.En(),this.C=new Notification("\u00c0 suivre",{body:b.title,icon:b.tc()}),this.F=this.L(this.C,"click",this.VL),this.G.start())}V4(this);this.u.nextVideo(!1,a)};
g.h.gM=function(a){!g.xe(this.B.element,g.Gp(a))&&g.IN(a,this.u)&&this.select()};
g.h.tK=function(){g.NK(this.u,!0)};
g.h.wL=function(a){this.u.getPresentingPlayerType();this.show();U4(this,a)};
g.h.LC=function(a){this.u.getPresentingPlayerType();this.A&&this.A.ya().videoId==a.ya().videoId||(this.A=a,S4(this,a,"hqdefault.jpg"))};
g.h.xL=function(){this.u.getPresentingPlayerType();V4(this);this.hide()};
g.h.X=function(){V4(this);this.En();g.R.prototype.X.call(this)};g.r(X4,g.R);g.h=X4.prototype;g.h.create=function(){this.created=!0};
g.h.destroy=function(){this.created=!1};
g.h.iw=function(){return!1};
g.h.gt=function(){return!1};
g.h.py=function(){return!1};g.r(Zua,X4);g.r(Y4,g.R);Y4.prototype.select=function(){var a=this.suggestion.ya().videoId,b=this.suggestion.getPlaylistId();(g.rT(this.api.app,a,this.suggestion.Ob,b,void 0,void 0)||this.api.fa("web_player_endscreen_double_log_fix_killswitch"))&&g.nL(this.api,this.element)};
Y4.prototype.onClick=function(a){g.IN(a,this.api,this.u,this.suggestion.Ob||void 0)&&this.select()};
Y4.prototype.B=function(a){switch(a.keyCode){case 13:case 32:g.Lp(a)||(this.select(),g.Kp(a))}};
Y4.prototype.A=function(){var a=this.api.getVideoData(),b=this.api.N();this.u=a.lc?!1:b.u};g.r(Z4,X4);g.h=Z4.prototype;g.h.create=function(){X4.prototype.create.call(this);var a=this.player.getVideoData();a&&(this.suggestions=$ua(this,a),this.videoData=a);this.Hg();this.w.L(this.player,"appresize",this.Hg);this.w.L(this.player,"onVideoAreaChange",this.Hg);this.w.L(this.player,"videodatachange",this.vH);this.w.L(this.player,"autonavchange",this.ht);this.w.L(this.player,"autonavcancel",this.sH);a=this.videoData.autonavState;a!==this.G&&this.ht(a);this.w.L(this.element,"transitionend",this.tN)};
g.h.destroy=function(){g.Ir(this.w);g.Ie(this.stills);this.stills=[];this.suggestions=null;X4.prototype.destroy.call(this);g.Dn(this.element,"ytp-show-tiles");this.F.stop();this.G=this.videoData.autonavState};
g.h.iw=function(){return 1!==this.videoData.autonavState};
g.h.show=function(){X4.prototype.show.call(this);g.Dn(this.element,"ytp-show-tiles");this.player.N().o?g.un(this.F):this.F.start();(this.C||this.B&&this.B!==this.videoData.clientPlaybackNonce)&&g.NK(this.player,!1);$4(this)?(a5(this),2===this.videoData.autonavState?this.player.N().fa("fast_autonav_in_background")&&3===this.player.getVisibilityState()?this.u.select(!0):U4(this.u):3===this.videoData.autonavState&&W4(this.u)):(g.NK(this.player,!0),a5(this))};
g.h.hide=function(){X4.prototype.hide.call(this);W4(this.u);a5(this)};
g.h.tN=function(a){g.Gp(a)===this.element&&this.Hg()};
g.h.Hg=function(){if(this.suggestions&&this.suggestions.length){g.J(this.element,"ytp-endscreen-paginate");var a=g.$K(this.K,!0,this.K.isFullscreen()),b=g.dC(this.K);b&&(b=b.kc()?48:32,a.width-=2*b);var c=a.width/a.height,d=96/54,e=b=2,f=Math.max(a.width/96,2),k=Math.max(a.height/54,2),l=this.suggestions.length,m=Math.pow(2,2);var n=l*m+(Math.pow(2,2)-m);n+=Math.pow(2,2)-m;for(n-=m;0<n&&(b<f||e<k);){var p=b/2,t=e/2,u=b<=f-2&&n>=t*m,z=e<=k-2&&n>=p*m;if((p+1)/t*d/c>c/(p/(t+1)*d)&&z)n-=p*m,e+=2;else if(u)n-=
t*m,b+=2;else if(z)n-=p*m,e+=2;else break}d=!1;n>=3*m&&6>=l*m-n&&(4<=e||4<=b)&&(d=!0);m=96*b;n=54*e;c=m/n<c?a.height/n:a.width/m;c=Math.min(c,2);m*=c;n*=c;c=this.player.N().fa("web_player_no_endscreen_crop")?1:1.21;m*=g.Md(a.width/m||1,1,c);n*=g.Md(a.height/n||1,1,c);m=Math.floor(Math.min(a.width,m));n=Math.floor(Math.min(a.height,n));a=this.table.element;g.Mh(a,m,n);g.sh(a,{marginLeft:m/-2+"px",marginTop:n/-2+"px"});c=this.u;f=this.suggestions[0];c.A=f;S4(c,f,"hqdefault.jpg");g.K(this.element,"ytp-endscreen-takeover",
$4(this));a5(this);m+=4;n+=4;for(f=c=0;f<b;f++)for(k=0;k<e;k++)if(p=c,t=0,d&&f>=b-2&&k>=e-2?t=1:0===k%2&&0===f%2&&(2>k&&2>f?0===k&&0===f&&(t=2):t=2),p=g.Nd(p+this.A,l),0!==t){u=this.stills[c];u||(u=new Y4(this.player),this.stills[c]=u,a.appendChild(u.element));z=Math.floor(n*k/e);var C=Math.floor(m*f/b),D=Math.floor(n*(k+t)/e)-z-4,E=Math.floor(m*(f+t)/b)-C-4;g.Ah(u.element,C,z);g.Mh(u.element,E,D);g.sh(u.element,"transitionDelay",(k+f)/20+"s");g.K(u.element,"ytp-videowall-still-mini",1===t);g.K(u.element,
"ytp-videowall-still-large",2<t);t=u;p=this.suggestions[p];t.suggestion!==p&&(t.suggestion=p,u=t.api.N(),z=g.Bn(t.element,"ytp-videowall-still-large")?"hqdefault.jpg":"mqdefault.jpg",S4(t,p,z),g.Ly(u)&&(u=p.kh(),u=g.yd(u,g.DH({},"emb_rel_end")),t.la("url",u)),(p=(p=p.Ob)&&p.itct)&&g.mL(t.api,t.element,p));c++}g.K(this.element,"ytp-endscreen-paginate",c<l);for(b=this.stills.length-1;b>=c;b--)e=this.stills[b],g.te(e.element),g.He(e);this.stills.length=c}};
g.h.vH=function(){var a=this.player.getVideoData();this.videoData!==a&&(this.A=0,this.suggestions=$ua(this,a),this.videoData=a,this.Hg())};
g.h.tH=function(){this.A+=this.stills.length;this.Hg()};
g.h.uH=function(){this.A-=this.stills.length;this.Hg()};
g.h.py=function(){return!!this.u.w};
g.h.ht=function(a){1===a?(this.C=!1,this.B=this.videoData.clientPlaybackNonce,V4(this.u),this.Ha()&&this.Hg()):(this.C=!0,this.Ha()&&$4(this)&&(2===a?U4(this.u):3===a&&W4(this.u)))};
g.h.sH=function(a){if(a){for(a=0;a<this.stills.length;a++)g.oL(this.K,this.stills[a].element,!0);this.ht(1)}else this.B=null,this.C=!1;this.Hg()};
g.h.gt=function(){return this.Ha()&&$4(this)};g.r(b5,g.vL);g.h=b5.prototype;g.h.Py=function(){var a=this.player.getVideoData(),b=!!(a&&a.suggestions&&a.suggestions.length);b=!ava(this.player)||b;var c=a.oj||g.Uy(a.Pa),d=g.LS(this.player.app);a=a.mutedAutoplay;return b&&!c&&!d&&!a};
g.h.Oy=function(){return this.endScreen.gt()};
g.h.aG=function(){return this.Oy()?this.endScreen.py():!1};
g.h.X=function(){g.fR(this.player.app,"endscreen",void 0);g.vL.prototype.X.call(this)};
g.h.load=function(){g.vL.prototype.load.call(this);this.endScreen.show()};
g.h.unload=function(){g.vL.prototype.unload.call(this);this.endScreen.hide();this.endScreen.destroy()};
g.h.qH=function(a){this.Py()&&(this.endScreen.created||this.endScreen.create(),"load"===a.getId()&&this.load())};
g.h.rH=function(a){"load"===a.getId()&&this.loaded&&this.unload()};
g.h.UB=function(){g.fR(this.player.app,"endscreen",void 0);var a=this.player.getVideoData();a=new g.iC(Math.max(1E3*(a.lengthSeconds-10),0),0x8000000000000,{id:"preload",namespace:"endscreen"});var b=new g.iC(0x8000000000000,0x8000000000000,{id:"load",priority:6,namespace:"endscreen"});g.eL(this.player,[a,b])};g.KL.endscreen=b5;})(_yt_player);

View File

@ -0,0 +1,38 @@
/*
Copyright (c) 2014-2016 GitHub, Inc.
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
(function(self){if(self.fetch)return;function normalizeName(name){if(typeof name!=="string")name=String(name);if(/[^a-z0-9\-#$%&'*+.\^_`|~]/i.test(name))throw new TypeError("Invalid character in header field name");return name.toLowerCase()}function normalizeValue(value){if(typeof value!=="string")value=String(value);return value}function Headers(headers){this.map={};if(headers instanceof Headers)headers.forEach(function(value,name){this.append(name,value)},this);else if(headers)Object.getOwnPropertyNames(headers).forEach(function(name){this.append(name,
headers[name])},this)}Headers.prototype.append=function(name,value){name=normalizeName(name);value=normalizeValue(value);var list=this.map[name];if(!list){list=[];this.map[name]=list}list.push(value)};Headers.prototype["delete"]=function(name){delete this.map[normalizeName(name)]};Headers.prototype.get=function(name){var values=this.map[normalizeName(name)];return values?values[0]:null};Headers.prototype.getAll=function(name){return this.map[normalizeName(name)]||[]};Headers.prototype.has=function(name){return this.map.hasOwnProperty(normalizeName(name))};
Headers.prototype.set=function(name,value){this.map[normalizeName(name)]=[normalizeValue(value)]};Headers.prototype.forEach=function(callback,thisArg){Object.getOwnPropertyNames(this.map).forEach(function(name){this.map[name].forEach(function(value){callback.call(thisArg,value,name,this)},this)},this)};function consumed(body){if(body.bodyUsed)return Promise.reject(new TypeError("Already read"));body.bodyUsed=true}function fileReaderReady(reader){return new Promise(function(resolve,reject){reader.onload=
function(){resolve(reader.result)};reader.onerror=function(){reject(reader.error)}})}function readBlobAsArrayBuffer(blob){var reader=new FileReader;reader.readAsArrayBuffer(blob);return fileReaderReady(reader)}function readBlobAsText(blob){var reader=new FileReader;reader.readAsText(blob);return fileReaderReady(reader)}var support={blob:"FileReader"in self&&"Blob"in self&&function(){try{new Blob;return true}catch(e){return false}}(),formData:"FormData"in self,arrayBuffer:"ArrayBuffer"in self};function Body(){this.bodyUsed=
false;this._initBody=function(body){this._bodyInit=body;if(typeof body==="string")this._bodyText=body;else if(support.blob&&Blob.prototype.isPrototypeOf(body))this._bodyBlob=body;else if(support.formData&&FormData.prototype.isPrototypeOf(body))this._bodyFormData=body;else if(!body)this._bodyText="";else if(support.arrayBuffer&&ArrayBuffer.prototype.isPrototypeOf(body));else throw new Error("unsupported BodyInit type");if(!this.headers.get("content-type"))if(typeof body==="string")this.headers.set("content-type",
"text/plain;charset=UTF-8");else if(this._bodyBlob&&this._bodyBlob.type)this.headers.set("content-type",this._bodyBlob.type)};if(support.blob){this.blob=function(){var rejected=consumed(this);if(rejected)return rejected;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);else if(this._bodyFormData)throw new Error("could not read FormData body as blob");else return Promise.resolve(new Blob([this._bodyText]))};this.arrayBuffer=function(){return this.blob().then(readBlobAsArrayBuffer)};this.text=
function(){var rejected=consumed(this);if(rejected)return rejected;if(this._bodyBlob)return readBlobAsText(this._bodyBlob);else if(this._bodyFormData)throw new Error("could not read FormData body as text");else return Promise.resolve(this._bodyText)}}else this.text=function(){var rejected=consumed(this);return rejected?rejected:Promise.resolve(this._bodyText)};if(support.formData)this.formData=function(){return this.text().then(decode)};this.json=function(){return this.text().then(JSON.parse)};return this}
var methods=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function normalizeMethod(method){var upcased=method.toUpperCase();return methods.indexOf(upcased)>-1?upcased:method}function Request(input,options){options=options||{};var body=options.body;if(Request.prototype.isPrototypeOf(input)){if(input.bodyUsed)throw new TypeError("Already read");this.url=input.url;this.credentials=input.credentials;if(!options.headers)this.headers=new Headers(input.headers);this.method=input.method;this.mode=input.mode;
if(!body){body=input._bodyInit;input.bodyUsed=true}}else this.url=input;this.credentials=options.credentials||this.credentials||"omit";if(options.headers||!this.headers)this.headers=new Headers(options.headers);this.method=normalizeMethod(options.method||this.method||"GET");this.mode=options.mode||this.mode||null;this.referrer=null;if((this.method==="GET"||this.method==="HEAD")&&body)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(body)}Request.prototype.clone=function(){return new Request(this)};
function decode(body){var form=new FormData;body.trim().split("&").forEach(function(bytes){if(bytes){var split=bytes.split("=");var name=split.shift().replace(/\+/g," ");var value=split.join("=").replace(/\+/g," ");form.append(decodeURIComponent(name),decodeURIComponent(value))}});return form}function headers(xhr){var head=new Headers;var pairs=xhr.getAllResponseHeaders().trim().split("\n");pairs.forEach(function(header){var split=header.trim().split(":");var key=split.shift().trim();var value=split.join(":").trim();
head.append(key,value)});return head}Body.call(Request.prototype);function Response(bodyInit,options){if(!options)options={};this.type="default";this.status=options.status;this.ok=this.status>=200&&this.status<300;this.statusText=options.statusText;this.headers=options.headers instanceof Headers?options.headers:new Headers(options.headers);this.url=options.url||"";this._initBody(bodyInit)}Body.call(Response.prototype);Response.prototype.clone=function(){return new Response(this._bodyInit,{status:this.status,
statusText:this.statusText,headers:new Headers(this.headers),url:this.url})};Response.error=function(){var response=new Response(null,{status:0,statusText:""});response.type="error";return response};var redirectStatuses=[301,302,303,307,308];Response.redirect=function(url,status){if(redirectStatuses.indexOf(status)===-1)throw new RangeError("Invalid status code");return new Response(null,{status:status,headers:{location:url}})};self.Headers=Headers;self.Request=Request;self.Response=Response;self.fetch=
function(input,init){return new Promise(function(resolve,reject){var request;if(Request.prototype.isPrototypeOf(input)&&!init)request=input;else request=new Request(input,init);var xhr=new XMLHttpRequest;function responseURL(){if("responseURL"in xhr)return xhr.responseURL;if(/^X-Request-URL:/m.test(xhr.getAllResponseHeaders()))return xhr.getResponseHeader("X-Request-URL");return}xhr.onload=function(){var status=xhr.status===1223?204:xhr.status;if(status<100||status>599){reject(new TypeError("Network request failed"));
return}var options={status:status,statusText:xhr.statusText,headers:headers(xhr),url:responseURL()};var body="response"in xhr?xhr.response:xhr.responseText;resolve(new Response(body,options))};xhr.onerror=function(){reject(new TypeError("Network request failed"))};xhr.open(request.method,request.url,true);if(request.credentials==="include")xhr.withCredentials=true;if("responseType"in xhr&&support.blob)xhr.responseType="blob";request.headers.forEach(function(value,name){xhr.setRequestHeader(name,value)});
xhr.send(typeof request._bodyInit==="undefined"?null:request._bodyInit)})};self.fetch.polyfill=true})(typeof self!=="undefined"?self:this);

View File

@ -0,0 +1,540 @@
(function(g){var window=this;var Wva=function(a,b){return g.Jb(a,b)},X5=function(a,b,c){a.w.set(b,c)},Y5=function(a){X5(a,"zx",Math.floor(2147483648*Math.random()).toString(36)+Math.abs(Math.floor(2147483648*Math.random())^(0,g.H)()).toString(36));
return a},Z5=function(a,b,c){Array.isArray(c)||(c=[String(c)]);
g.an(a.w,b,c)},Xva=function(a,b){var c=[];
g.hk(b,function(d){try{var e=g.$n.prototype.u.call(this,d,!0)}catch(f){if("Storage: Invalid value was encountered"==f)return;throw f;}void 0===e?c.push(d):g.Zn(e)&&c.push(d)},a);
return c},Yva=function(a,b){var c=Xva(a,b);
(0,g.y)(c,function(d){g.$n.prototype.remove.call(this,d)},a)},Zva=function(a){if(a.Sc){if(a.Sc.locationOverrideToken)return{locationOverrideToken:a.Sc.locationOverrideToken};
if(null!=a.Sc.latitudeE7&&null!=a.Sc.longitudeE7)return{latitudeE7:a.Sc.latitudeE7,longitudeE7:a.Sc.longitudeE7}}return null},$va=function(a,b){g.$a(a,b)||a.push(b)},$5=function(a){var b=0,c;
for(c in a)b++;return b},awa=function(a,b){var c=b instanceof g.tc?b:g.xc(b,/^data:image\//i.test(b));
a.src=g.uc(c)},a6=function(){},bwa=function(a){try{return g.v.JSON.parse(a)}catch(b){}a=String(a);
if(/^\s*$/.test(a)?0:/^[\],:{}\s\u2028\u2029]*$/.test(a.replace(/\\["\\\/bfnrtu]/g,"@").replace(/(?:"[^"\\\n\r\u2028\u2029\x00-\x08\x0a-\x1f]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?)[\s\u2028\u2029]*(?=:|,|]|}|$)/g,"]").replace(/(?:^|:|,)(?:[\s\u2028\u2029]*\[)+/g,"")))try{return eval("("+a+")")}catch(b){}throw Error("Invalid JSON string: "+a);},cwa=function(a){if(a.Ed&&"function"==typeof a.Ed)return a.Ed();
if("string"===typeof a)return a.split("");if(g.La(a)){for(var b=[],c=a.length,d=0;d<c;d++)b.push(a[d]);return b}return g.Fb(a)},dwa=function(a,b){if(a.forEach&&"function"==typeof a.forEach)a.forEach(b,void 0);
else if(g.La(a)||"string"===typeof a)(0,g.y)(a,b,void 0);else{if(a.te&&"function"==typeof a.te)var c=a.te();else if(a.Ed&&"function"==typeof a.Ed)c=void 0;else if(g.La(a)||"string"===typeof a){c=[];for(var d=a.length,e=0;e<d;e++)c.push(e)}else c=g.Gb(a);d=cwa(a);e=d.length;for(var f=0;f<e;f++)b.call(void 0,d[f],c&&c[f],a)}},ewa=function(a,b,c,d){var e=new g.Pm(null,void 0);
a&&g.Qm(e,a);b&&g.Rm(e,b);c&&g.Sm(e,c);d&&(e.u=d);return e},b6=function(a,b){g.Mo[a]=!0;
var c=g.Ko();c&&c.publish.apply(c,arguments);g.Mo[a]=!1},c6=function(a){this.app=this.name=this.id="";
this.type="REMOTE_CONTROL";this.obfuscatedGaiaId=this.avatar=this.username="";this.capabilities=new Set;this.experiments=new Set;this.theme="u";new g.Mm;a&&(this.id=a.id||a.name,this.name=a.name,this.app=a.app,this.type=a.type||"REMOTE_CONTROL",this.username=a.user||"",this.avatar=a.userAvatarUri||"",this.obfuscatedGaiaId=a.obfuscatedGaiaId||"",this.theme=a.theme||"u",fwa(this,a.capabilities||""),gwa(this,a.experiments||""))},fwa=function(a,b){a.capabilities.clear();
(0,g.ue)(b.split(","),g.Qa(Wva,hwa)).forEach(function(c){a.capabilities.add(c)})},gwa=function(a,b){a.experiments.clear();
b.split(",").forEach(function(c){a.experiments.add(c)})},d6=function(a){a=a||{};
this.name=a.name||"";this.id=a.id||a.screenId||"";this.token=a.token||a.loungeToken||"";this.uuid=a.uuid||a.dialId||""},e6=function(a,b){return!!b&&(a.id==b||a.uuid==b)},iwa=function(a){return{name:a.name,
screenId:a.id,loungeToken:a.token,dialId:a.uuid}},jwa=function(a){return new d6(a)},kwa=function(a){return Array.isArray(a)?(0,g.Cc)(a,jwa):[]},f6=function(a){return a?'{name:"'+a.name+'",id:'+a.id.substr(0,6)+"..,token:"+(a.token?".."+a.token.slice(-6):"-")+",uuid:"+(a.uuid?".."+a.uuid.slice(-6):"-")+"}":"null"},g6=function(a){return Array.isArray(a)?"["+(0,g.Cc)(a,f6).join(",")+"]":"null"},h6=function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(a){var b=16*Math.random()|
0;
return("x"==a?b:b&3|8).toString(16)})},lwa=function(a){return(0,g.Cc)(a,function(b){return{key:b.id,
name:b.name}})},i6=function(a,b){return g.Xa(a,function(c){return c||b?!c!=!b?!1:c.id==b.id:!0})},j6=function(a,b){return g.Xa(a,function(c){return e6(c,b)})},k6=function(a){try{var b=(0,g.Cs)(),c=(0,g.Bs)();
b&&b.remove(a);c&&c.remove(a)}catch(d){}},mwa=function(){var a=(0,g.Bs)();
a&&Yva(a,a.o.Zf(!0))},l6=function(){var a=g.Es("yt-remote-connected-devices")||[];
g.rb(a);return a},nwa=function(a){if(g.ab(a))return[];
var b=a[0].indexOf("#"),c=-1==b?a[0]:a[0].substring(0,b);return(0,g.Cc)(a,function(d,e){return 0==e?d:d.substring(c.length)})},owa=function(a){g.Ds("yt-remote-connected-devices",a,86400)},n6=function(){if(m6)return m6;
var a=g.Es("yt-remote-device-id");a||(a=h6(),g.Ds("yt-remote-device-id",a,31536E3));for(var b=l6(),c=1,d=a;g.$a(b,d);)c++,d=a+"#"+c;return m6=d},o6=function(){var a=l6(),b=n6();
g.$a(a,b);g.Fs()&&g.ub(a,b);a=nwa(a);if(g.ab(a))try{g.Oq("remote_sid")}catch(c){}else try{g.Mq("remote_sid",a.join(","),-1)}catch(c){}},pwa=function(){return g.Es("yt-remote-session-browser-channel")},qwa=function(){return g.Es("yt-remote-local-screens")||[]},rwa=function(){g.Ds("yt-remote-lounge-token-expiration",!0,86400)},swa=function(a){5<a.length&&(a=a.slice(a.length-5));
var b=(0,g.Cc)(qwa(),function(d){return d.loungeToken}),c=(0,g.Cc)(a,function(d){return d.loungeToken});
(0,g.ti)(c,function(d){return!g.$a(b,d)})&&rwa();
g.Ds("yt-remote-local-screens",a,31536E3)},twa=function(a,b){g.Ds("yt-remote-session-browser-channel",a);
g.Ds("yt-remote-session-screen-id",b);var c=l6(),d=n6();g.$a(c,d)||c.push(d);owa(c);o6()},p6=function(a){a||(k6("yt-remote-session-screen-id"),k6("yt-remote-session-video-id"));
o6();a=l6();g.db(a,n6());owa(a)},uwa=function(){if(!q6){var a=g.ko();
a&&(q6=new g.Un(a))}return q6?!!q6.get("yt-remote-use-staging-server"):!1},vwa=function(a){return!!document.currentScript&&(-1!=document.currentScript.src.indexOf("?"+a)||-1!=document.currentScript.src.indexOf("&"+a))},wwa=function(){return"function"==typeof window.__onGCastApiAvailable?window.__onGCastApiAvailable:null},r6=function(a){a.length?xwa(a.shift(),function(){r6(a)}):s6()},ywa=function(a){return"chrome-extension://"+a+"/cast_sender.js"},xwa=function(a,b,c){var d=document.createElement("script");
d.onerror=b;c&&(d.onload=c);d.src=a;(document.head||document.documentElement).appendChild(d)},s6=function(){var a=wwa();
a&&a(!1,"No cast extension found")},Awa=function(){if(zwa){var a=2,b=wwa(),c=function(){a--;
0==a&&b&&b(!0)};
window.__onGCastApiAvailable=c;xwa("//www.gstatic.com/cast/sdk/libs/sender/1.0/cast_framework.js",s6,c)}},Bwa=function(){Awa();
var a=window.navigator.userAgent.match(/Chrome\/([0-9]+)/);r6(["//www.gstatic.com/eureka/clank/"+(a?parseInt(a[1],10):0)+"/cast_sender.js","//www.gstatic.com/eureka/clank/cast_sender.js"])},t6=function(a,b,c){g.A.call(this);
this.C=null!=c?(0,g.x)(a,c):a;this.Ad=b;this.B=(0,g.x)(this.kF,this);this.o=!1;this.u=0;this.w=this.Ga=null;this.A=[]},u6=function(a,b,c){g.A.call(this);
this.w=null!=c?(0,g.x)(a,c):a;this.Ad=b;this.u=(0,g.x)(this.lF,this);this.o=[]},v6=function(a){a.Ga=g.Uf(a.u,a.Ad);
a.w.apply(null,a.o)},w6=function(a){if(g.v.JSON)try{return g.v.JSON.parse(a)}catch(b){}return bwa(a)},x6=function(){},y6=function(){},Cwa=function(){},Ewa=function(a){return(a=Dwa(a))?new ActiveXObject(a):new XMLHttpRequest},Dwa=function(a){if(!a.u&&"undefined"==typeof XMLHttpRequest&&"undefined"!=typeof ActiveXObject){for(var b=["MSXML2.XMLHTTP.6.0",
"MSXML2.XMLHTTP.3.0","MSXML2.XMLHTTP","Microsoft.XMLHTTP"],c=0;c<b.length;c++){var d=b[c];try{return new ActiveXObject(d),a.u=d}catch(e){}}throw Error("Could not create ActiveXObject. ActiveX might be disabled, or MSXML might not be installed");}return a.u},z6=function(a,b,c,d){this.o=a;
this.w=b;this.G=c;this.F=d||1;this.B=45E3;this.A=new g.C1(this);this.u=new g.Tf;this.u.setInterval(250)},Gwa=function(a,b,c){a.Gj=1;
a.Vg=Y5(b.clone());a.Yi=c;a.C=!0;Fwa(a,null)},A6=function(a,b,c,d,e){a.Gj=1;
a.Vg=Y5(b.clone());a.Yi=null;a.C=c;e&&(a.ZB=!1);Fwa(a,d)},Fwa=function(a,b){a.wk=(0,g.H)();
B6(a);a.Ph=a.Vg.clone();Z5(a.Ph,"t",a.F);a.Sm=0;a.Lc=a.o.rr(a.o.Im()?b:null);0<a.ds&&(a.Ap=new u6((0,g.x)(a.VC,a,a.Lc),a.ds));a.A.ka(a.Lc,"readystatechange",a.cO);var c=a.zi?g.Pb(a.zi):{};a.Yi?(a.hq="POST",c["Content-Type"]="application/x-www-form-urlencoded",a.Lc.send(a.Ph,a.hq,a.Yi,c)):(a.hq="GET",a.ZB&&!g.je&&(c.Connection="close"),a.Lc.send(a.Ph,a.hq,null,c));a.o.bf(1)},Jwa=function(a,b,c){for(var d=!0;!a.hi&&a.Sm<c.length;){var e=Hwa(a,c);
if(e==C6){4==b&&(a.lh=4,D6(15),d=!1);break}else if(e==Iwa){a.lh=4;D6(16);d=!1;break}else E6(a,e)}4==b&&0==c.length&&(a.lh=1,D6(17),d=!1);a.df=a.df&&d;d||(F6(a),G6(a))},Hwa=function(a,b){var c=a.Sm,d=b.indexOf("\n",c);
if(-1==d)return C6;c=Number(b.substring(c,d));if(isNaN(c))return Iwa;d+=1;if(d+c>b.length)return C6;var e=b.substr(d,c);a.Sm=d+c;return e},Lwa=function(a,b){a.wk=(0,g.H)();
B6(a);var c=b?window.location.hostname:"";a.Ph=a.Vg.clone();X5(a.Ph,"DOMAIN",c);X5(a.Ph,"t",a.F);try{a.kf=new ActiveXObject("htmlfile")}catch(n){F6(a);a.lh=7;D6(22);G6(a);return}var d="<html><body>";if(b){for(var e="",f=0;f<c.length;f++){var k=c.charAt(f);if("<"==k)e+="\\x3c";else if(">"==k)e+="\\x3e";else{var l=k;if(l in H6)k=H6[l];else if(l in Kwa)k=H6[l]=Kwa[l];else{var m=l.charCodeAt(0);if(31<m&&127>m)k=l;else{if(256>m){if(k="\\x",16>m||256<m)k+="0"}else k="\\u",4096>m&&(k+="0");k+=m.toString(16).toUpperCase()}k=
H6[l]=k}e+=k}}d+='<script>document.domain="'+e+'"\x3c/script>'}c=g.Wc(g.Yb("b/12014412"),d+"</body></html>");a.kf.open();a.kf.write(g.Qc(c));a.kf.close();a.kf.parentWindow.m=(0,g.x)(a.wN,a);a.kf.parentWindow.d=(0,g.x)(a.hB,a,!0);a.kf.parentWindow.rpcClose=(0,g.x)(a.hB,a,!1);c=a.kf.createElement("DIV");a.kf.parentWindow.document.body.appendChild(c);d=g.wc(a.Ph.toString());d=g.dd(g.uc(d));d=g.Wc(g.Yb("b/12014412"),'<iframe src="'+d+'"></iframe>');g.Xc(c,d);a.o.bf(1)},B6=function(a){a.ev=(0,g.H)()+a.B;
Mwa(a,a.B)},Mwa=function(a,b){if(null!=a.Jk)throw Error("WatchDog timer not null");
a.Jk=I6((0,g.x)(a.EN,a),b)},J6=function(a){a.Jk&&(g.v.clearTimeout(a.Jk),a.Jk=null)},G6=function(a){a.o.Kx()||a.hi||a.o.fo(a)},F6=function(a){J6(a);
g.He(a.Ap);a.Ap=null;a.u.stop();g.Rqa(a.A);if(a.Lc){var b=a.Lc;a.Lc=null;b.abort();b.dispose()}a.kf&&(a.kf=null)},E6=function(a,b){try{a.o.ZA(a,b),a.o.bf(4)}catch(c){}},Owa=function(a,b,c,d,e){if(0==d)c(!1);
else{var f=e||0;d--;Nwa(a,b,function(k){k?c(!0):g.v.setTimeout(function(){Owa(a,b,c,d,f)},f)})}},Nwa=function(a,b,c){var d=new Image;
d.onload=function(){try{K6(d),c(!0)}catch(e){}};
d.onerror=function(){try{K6(d),c(!1)}catch(e){}};
d.onabort=function(){try{K6(d),c(!1)}catch(e){}};
d.ontimeout=function(){try{K6(d),c(!1)}catch(e){}};
g.v.setTimeout(function(){if(d.ontimeout)d.ontimeout()},b);
awa(d,a)},K6=function(a){a.onload=null;
a.onerror=null;a.onabort=null;a.ontimeout=null},Pwa=function(a){this.o=a;
this.u=new x6},Qwa=function(a){var b=L6(a.o,a.Vk,"/mail/images/cleardot.gif");
Y5(b);Owa(b.toString(),5E3,(0,g.x)(a.eE,a),3,2E3);a.bf(1)},N6=function(a){var b=a.o.I;
if(null!=b)D6(5),b?(D6(11),M6(a.o,a,!1)):(D6(12),M6(a.o,a,!0));else if(a.Vd=new z6(a,void 0,void 0,void 0),a.Vd.zi=a.Yr,b=a.o,b=L6(b,b.Im()?a.Cl:null,a.Zr),D6(5),!g.he||g.Ld(10))Z5(b,"TYPE","xmlhttp"),A6(a.Vd,b,!1,a.Cl,!1);else{Z5(b,"TYPE","html");var c=a.Vd;a=!!a.Cl;c.Gj=3;c.Vg=Y5(b.clone());Lwa(c,a)}},O6=function(a){g.gf.call(this);
this.headers=new g.Mm;this.U=a||null;this.w=!1;this.R=this.o=null;this.ha=this.I="";this.C=0;this.A="";this.B=this.Z=this.G=this.V=!1;this.F=0;this.P=null;this.da="";this.M=this.ba=!1},Rwa=function(a){return g.he&&g.Kd(9)&&"number"===typeof a.timeout&&void 0!==a.ontimeout},Swa=function(a){return"content-type"==a.toLowerCase()},Uwa=function(a,b){a.w=!1;
a.o&&(a.B=!0,a.o.abort(),a.B=!1);a.A=b;a.C=5;Twa(a);P6(a)},Twa=function(a){a.V||(a.V=!0,a.dispatchEvent("complete"),a.dispatchEvent("error"))},Wwa=function(a){if(a.w&&"undefined"!=typeof g.H1)if(a.R[1]&&4==Q6(a)&&2==a.getStatus())R6(a,"Local request error detected and ignored");
else if(a.G&&4==Q6(a))g.Uf(a.VA,0,a);else if(a.dispatchEvent("readystatechange"),4==Q6(a)){R6(a,"Request complete");a.w=!1;try{var b=a.getStatus();a:switch(b){case 200:case 201:case 202:case 204:case 206:case 304:case 1223:var c=!0;break a;default:c=!1}var d;if(!(d=c)){var e;if(e=0===b){var f=g.nd(1,String(a.I));if(!f&&g.v.self&&g.v.self.location){var k=g.v.self.location.protocol;f=k.substr(0,k.length-1)}e=!Vwa.test(f?f.toLowerCase():"")}d=e}if(d)a.dispatchEvent("complete"),a.dispatchEvent("success");
else{a.C=6;try{var l=2<Q6(a)?a.o.statusText:""}catch(m){l=""}a.A=l+" ["+a.getStatus()+"]";Twa(a)}}finally{P6(a)}}},P6=function(a,b){if(a.o){Xwa(a);
var c=a.o,d=a.R[0]?g.Ia:null;a.o=null;a.R=null;b||a.dispatchEvent("ready");try{c.onreadystatechange=d}catch(e){}}},Xwa=function(a){a.o&&a.M&&(a.o.ontimeout=null);
a.P&&(g.v.clearTimeout(a.P),a.P=null)},Q6=function(a){return a.o?a.o.readyState:0},S6=function(a){try{return a.o?a.o.responseText:""}catch(b){return""}},R6=function(a,b){return b+" ["+a.ha+" "+a.I+" "+a.getStatus()+"]"},T6=function(a,b,c){this.o=1;
this.u=[];this.A=[];this.B=new x6;this.G=a||null;this.I=null!=b?b:null;this.C=c||!1},Ywa=function(a,b){this.o=a;
this.map=b;this.context=null},Zwa=function(a){g.Je.call(this,"statevent",a)},$wa=function(a,b){g.Je.call(this,"timingevent",a);
this.size=b},axa=function(a){g.Je.call(this,"serverreachability",a)},dxa=function(a){bxa(a);
if(3==a.o){var b=a.lm++,c=a.Rn.clone();X5(c,"SID",a.w);X5(c,"RID",b);X5(c,"TYPE","terminate");U6(a,c);b=new z6(a,a.w,b,void 0);b.Gj=2;b.Vg=Y5(c.clone());awa(new Image,b.Vg.toString());b.wk=(0,g.H)();B6(b)}cxa(a)},exa=function(a){a.DE(1,0);
a.Rn=L6(a,null,a.Xr);V6(a)},bxa=function(a){a.Zg&&(a.Zg.abort(),a.Zg=null);
a.hc&&(a.hc.cancel(),a.hc=null);a.cg&&(g.v.clearTimeout(a.cg),a.cg=null);W6(a);a.Od&&(a.Od.cancel(),a.Od=null);a.eh&&(g.v.clearTimeout(a.eh),a.eh=null)},fxa=function(a,b){if(0==a.o)throw Error("Invalid operation: sending map when state is closed");
a.u.push(new Ywa(a.OJ++,b));2!=a.o&&3!=a.o||V6(a)},V6=function(a){a.Od||a.eh||(a.eh=I6((0,g.x)(a.gB,a),0),a.yj=0)},hxa=function(a,b){if(1==a.o){if(!b){a.lm=Math.floor(1E5*Math.random());
var c=a.lm++,d=new z6(a,"",c,void 0);d.zi=null;var e=X6(a),f=a.Rn.clone();X5(f,"RID",c);X5(f,"CVER","1");U6(a,f);Gwa(d,f,e);a.Od=d;a.o=2}}else 3==a.o&&(b?gxa(a,b):0==a.u.length||a.Od||gxa(a))},gxa=function(a,b){if(b)if(6<a.ii){a.u=a.A.concat(a.u);
a.A.length=0;var c=a.lm-1;var d=X6(a)}else c=b.G,d=b.Yi;else c=a.lm++,d=X6(a);var e=a.Rn.clone();X5(e,"SID",a.w);X5(e,"RID",c);X5(e,"AID",a.Tj);U6(a,e);c=new z6(a,a.w,c,a.yj+1);c.zi=null;c.setTimeout(1E4+Math.round(1E4*Math.random()));a.Od=c;Gwa(c,e,d)},U6=function(a,b){if(a.wd){var c=a.wd.gx();
c&&g.zb(c,function(d,e){X5(b,e,d)})}},X6=function(a){var b=Math.min(a.u.length,1E3),c=["count="+b];
if(6<a.ii&&0<b){var d=a.u[0].o;c.push("ofs="+d)}else d=0;for(var e=0;e<b;e++){var f=a.u[e].o,k=a.u[e].map;f=6>=a.ii?e:f-d;try{g.zb(k,function(l,m){c.push("req"+f+"_"+m+"="+encodeURIComponent(l))})}catch(l){c.push("req"+f+"_type="+encodeURIComponent("_badmap"))}}a.A=a.A.concat(a.u.splice(0,b));
return c.join("&")},ixa=function(a){a.hc||a.cg||(a.F=1,a.cg=I6((0,g.x)(a.fB,a),0),a.qj=0)},Y6=function(a){if(a.hc||a.cg||3<=a.qj)return!1;
a.F++;a.cg=I6((0,g.x)(a.fB,a),jxa(a,a.qj));a.qj++;return!0},M6=function(a,b,c){a.fq=c;
a.yf=b.rg;a.C||exa(a)},W6=function(a){null!=a.ni&&(g.v.clearTimeout(a.ni),a.ni=null)},jxa=function(a,b){var c=5E3+Math.floor(1E4*Math.random());
a.isActive()||(c*=2);return c*b},Z6=function(a,b){if(2==b||9==b){var c=null;
a.wd&&(c=null);var d=(0,g.x)(a.NO,a);c||(c=new g.Pm("//www.google.com/images/cleardot.gif"),Y5(c));Nwa(c.toString(),1E4,d)}else D6(2);kxa(a,b)},kxa=function(a,b){a.o=0;
a.wd&&a.wd.xw(b);cxa(a);bxa(a)},cxa=function(a){a.o=0;
a.yf=-1;if(a.wd)if(0==a.A.length&&0==a.u.length)a.wd.fr();else{g.gb(a.A);var b=g.gb(a.u);a.A.length=0;a.u.length=0;a.wd.fr(b)}},L6=function(a,b,c){var d=g.Xm(c);
if(""!=d.o)b&&g.Rm(d,b+"."+d.o),g.Sm(d,d.A);else{var e=window.location;d=ewa(e.protocol,b?b+"."+e.hostname:e.hostname,+e.port,c)}a.ql&&g.zb(a.ql,function(f,k){X5(d,k,f)});
X5(d,"VER",a.ii);U6(a,d);return d},I6=function(a,b){if(!g.Ma(a))throw Error("Fn must not be null and must be a function");
return g.v.setTimeout(function(){a()},b)},D6=function(a){$6.dispatchEvent(new Zwa($6,a))},lxa=function(){},mxa=function(){this.o=[];
this.u=[]},nxa=function(a,b){this.action=a;
this.params=b||{}},a7=function(a,b){g.A.call(this);
this.o=new g.I(this.pN,0,this);g.B(this,this.o);this.Ad=5E3;this.u=0;if(g.Ma(a))b&&(a=(0,g.x)(a,b));else if(a&&g.Ma(a.handleEvent))a=(0,g.x)(a.handleEvent,a);else throw Error("Invalid listener argument");this.w=a},b7=function(a,b,c){this.P=a;
this.C=b;this.w=new g.Tn;this.u=new a7(this.qO,this);this.o=null;this.ub=!1;this.B=null;this.I="";this.G=this.A=0;this.F=[];this.M=c||!1},oxa=function(a){return{firstTestResults:[""],
secondTestResults:!a.o.fq,sessionId:a.o.w,arrayId:a.o.Tj}},pxa=function(a,b){a.G=b||0;
a.u.stop();a.o&&(3==a.o.o&&hxa(a.o),dxa(a.o));a.G=0},c7=function(a){return!!a.o&&3==a.o.o},qxa=function(a,b){(a.C.loungeIdToken=b)||a.u.stop()},d7=function(a){this.port=this.domain="";
this.o="/api/lounge";this.u=!0;a=a||document.location.href;var b=Number(g.nd(4,a))||"";b&&(this.port=":"+b);this.domain=g.od(a)||"";a=g.Ic;0<=a.search("MSIE")&&(a=a.match(/MSIE ([\d.]+)/)[1],0>g.qc(a,"10.0")&&(this.u=!1))},e7=function(a,b){var c=a.o;
a.u&&(c="https://"+a.domain+a.port+a.o);return g.yd(c+b,{})},f7=function(a,b,c,d,e){a={format:"JSON",
method:"POST",context:a,timeout:5E3,withCredentials:!1,onSuccess:g.Qa(a.A,d,!0),onError:g.Qa(a.w,e),Ud:g.Qa(a.B,e)};c&&(a.sb=c,a.headers={"Content-Type":"application/x-www-form-urlencoded"});return g.Eq(b,a)},uxa=function(){var a=rxa;
sxa();g7.push(a);txa(g7)},h7=function(a,b){sxa();
var c=g7,d=vxa(a,String(b));g.ab(c)?wxa(d):(txa(c),(0,g.y)(c,function(e){e(d)}))},sxa=function(){g7||(g7=g.w("yt.mdx.remote.debug.handlers_")||[],g.Ga("yt.mdx.remote.debug.handlers_",g7,void 0))},wxa=function(a){var b=(i7+1)%50;
i7=b;j7[b]=a;k7||(k7=49==b)},txa=function(a){var b=j7;
if(b[0]){var c=i7,d=k7?c:-1;do{d=(d+1)%50;var e=b[d];(0,g.y)(a,function(f){f(e)})}while(d!=c);
j7=Array(50);i7=-1;k7=!1}},vxa=function(a,b){var c=((0,g.H)()-xxa)/1E3;
c.toFixed&&(c=c.toFixed(3));var d=[];d.push("[",c+"s","] ");d.push("[","yt.mdx.remote","] ");d.push(a+": "+b,"\n");return d.join("")},l7=function(a){g.O.call(this);
this.F=a;this.o=[]},yxa=function(a,b){var c=a.get(b.uuid)||a.get(b.id);
if(c){var d=c.name;c.id=b.id||c.id;c.name=b.name;c.token=b.token;c.uuid=b.uuid||c.uuid;return c.name!=d}a.o.push(b);return!0},zxa=function(a,b){var c=a.o.length!=b.length;
a.o=(0,g.ue)(a.o,function(f){return!!i6(b,f)});
for(var d=0,e=b.length;d<e;d++)c=yxa(a,b[d])||c;return c},Axa=function(a,b){var c=a.o.length;
a.o=(0,g.ue)(a.o,function(d){return!(d||b?!d!=!b?0:d.id==b.id:1)});
return a.o.length<c},m7=function(a,b,c,d){g.O.call(this);
this.C=a;this.A=b;this.B=c;this.w=d;this.u=0;this.o=null;this.Ga=NaN},o7=function(a){l7.call(this,"LocalScreenService");
this.w=a;this.u=NaN;n7(this);this.info("Initializing with "+g6(this.o))},Bxa=function(a){if(a.o.length){var b=(0,g.Cc)(a.o,function(d){return d.id}),c=e7(a.w,"/pairing/get_lounge_token_batch");
f7(a.w,c,{screen_ids:b.join(",")},(0,g.x)(a.vF,a),(0,g.x)(a.uF,a))}},n7=function(a){var b=kwa(qwa());
b=(0,g.ue)(b,function(c){return!c.uuid});
return zxa(a,b)},p7=function(a,b){swa((0,g.Cc)(a.o,iwa));
b&&rwa()},r7=function(a,b){g.O.call(this);
this.C=b;var c=g.Es("yt-remote-online-screen-ids")||"";c=c?c.split(","):[];for(var d={},e=this.C(),f=0,k=e.length;f<k;++f){var l=e[f].id;d[l]=g.$a(c,l)}this.o=d;this.B=a;this.w=this.A=NaN;this.u=null;q7("Initialized with "+g.Jk(this.o))},Cxa=function(a,b,c){var d=e7(a.B,"/pairing/get_screen_availability");
f7(a.B,d,{lounge_token:b.token},(0,g.x)(function(e){e=e.screens||[];for(var f=0,k=e.length;f<k;++f)if(e[f].loungeToken==b.token){c("online"==e[f].status);return}c(!1)},a),(0,g.x)(function(){c(!1)},a))},s7=function(a,b){a:if($5(b)!=$5(a.o))var c=!1;
else{c=g.Gb(b);for(var d=0,e=c.length;d<e;++d)if(!a.o[c[d]]){c=!1;break a}c=!0}c||(q7("Updated online screens: "+g.Jk(a.o)),a.o=b,a.S("screenChange"));Dxa(a)},t7=function(a){isNaN(a.w)||g.Jo(a.w);
a.w=g.Ho((0,g.x)(a.vu,a),0<a.A&&a.A<(0,g.H)()?2E4:1E4)},q7=function(a){h7("OnlineScreenService",a)},Exa=function(a){var b={};
(0,g.y)(a.C(),function(c){c.token?b[c.token]=c.id:this.Ub("Requesting availability of screen w/o lounge token.")});
return b},Dxa=function(a){a=g.Gb(g.Ab(a.o,function(b){return b}));
g.rb(a);a.length?g.Ds("yt-remote-online-screen-ids",a.join(","),60):k6("yt-remote-online-screen-ids")},u7=function(a){l7.call(this,"ScreenService");
this.C=a;this.u=this.w=null;this.A=[];this.B={};Fxa(this)},Hxa=function(a,b,c,d,e,f){a.info("getAutomaticScreenByIds "+c+" / "+b);
c||(c=a.B[b]);var k=a.he();if(k=(c?j6(k,c):null)||j6(k,b)){k.uuid=b;var l=v7(a,k);Cxa(a.u,l,function(m){e(m?l:null)})}else c?Gxa(a,c,(0,g.x)(function(m){var n=v7(this,new d6({name:d,
screenId:c,loungeToken:m,dialId:b||""}));Cxa(this.u,n,function(p){e(p?n:null)})},a),f):e(null)},Ixa=function(a,b){for(var c=0,d=a.o.length;c<d;++c)if(a.o[c].name==b)return a.o[c];
return null},Gxa=function(a,b,c,d){a.info("requestLoungeToken_ for "+b);
var e={sb:{screen_ids:b},method:"POST",context:a,onSuccess:function(f,k){var l=k&&k.screens||[];l[0]&&l[0].screenId==b?c(l[0].loungeToken):d(Error("Missing lounge token in token response"))},
onError:function(){d(Error("Request screen lounge token failed"))}};
g.Eq(e7(a.C,"/pairing/get_lounge_token_batch"),e)},Jxa=function(a){a.o=a.w.he();
var b=a.B,c={},d;for(d in b)c[b[d]]=d;b=0;for(d=a.o.length;b<d;++b){var e=a.o[b];e.uuid=c[e.id]||""}a.info("Updated manual screens: "+g6(a.o))},Fxa=function(a){w7(a);
a.w=new o7(a.C);a.w.subscribe("screenChange",(0,g.x)(a.EF,a));Jxa(a);a.A=kwa(g.Es("yt-remote-automatic-screen-cache")||[]);w7(a);a.info("Initializing automatic screens: "+g6(a.A));a.u=new r7(a.C,(0,g.x)(a.he,a,!0));a.u.subscribe("screenChange",(0,g.x)(function(){this.S("onlineScreenChange")},a))},v7=function(a,b){var c=a.get(b.id);
c?(c.uuid=b.uuid,b=c):((c=j6(a.A,b.uuid))?(c.id=b.id,c.token=b.token,b=c):a.A.push(b),g.Ds("yt-remote-automatic-screen-cache",(0,g.Cc)(a.A,iwa)));w7(a);a.B[b.uuid]=b.id;g.Ds("yt-remote-device-id-map",a.B,31536E3);return b},w7=function(a){a.B=g.Es("yt-remote-device-id-map")||{}},x7=function(a,b,c){g.O.call(this);
this.R=c;this.I=a;this.u=b;this.w=null},y7=function(a,b){h7(a.R,b)},z7=function(a,b){x7.call(this,a,b,"CastSession");
this.o=null;this.A=0;this.C=(0,g.x)(this.xP,this);this.B=(0,g.x)(this.MN,this);this.A=g.Ho((0,g.x)(function(){Kxa(this,null)},this),12E4)},Lxa=function(a){a.info("sendYoutubeMessage_: getMdxSessionStatus "+g.Jk(void 0));
var b={type:"getMdxSessionStatus"};a.o?a.o.sendMessage("urn:x-cast:com.google.youtube.mdx",b,g.Ia,(0,g.x)(function(){y7(this,"Failed to send message: getMdxSessionStatus.")},a)):y7(a,"Sending yt message without session: "+g.Jk(b))},Kxa=function(a,b){g.Jo(a.A);
if(b){if(a.info("onConnectedScreenId_: Received screenId: "+b),!a.w||a.w.id!=b){var c=(0,g.x)(a.qp,a),d=(0,g.x)(a.le,a);a.Cx(b,c,d,5)}}else a.le(Error("Waiting for session status timed out."))},A7=function(a,b,c){x7.call(this,a,b,"DialSession");
this.A=this.G=null;this.P="";this.U=c;this.B=null;this.F=g.Ia;this.C=NaN;this.M=(0,g.x)(this.AP,this);this.o=g.Ia},Mxa=function(a){a.o=a.I.bD(a.P,a.u.label,a.u.friendlyName,(0,g.x)(function(b){this.o=g.Ia;
this.qp(b)},a),(0,g.x)(function(b){this.o=g.Ia;
this.le(b)},a))},Nxa=function(a){var b={};
b.pairingCode=a.P;b.theme=a.U;if(a.B){var c=a.B.currentTime||0;b.v=a.B.videoId;b.t=c}uwa()&&(b.env_useStageMdx=1);return g.wd(b)},B7=function(a,b){x7.call(this,a,b,"ManualSession");
this.o=g.Ho((0,g.x)(this.Uj,this,null),150)},C7=function(a,b,c,d){g.O.call(this);
this.u=a;this.F=b||"233637DE";this.C=c||"cl";this.G=d||!1;this.o=null;this.B=!1;this.w=[];this.A=(0,g.x)(this.zM,this)},Oxa=function(a,b){return b?g.Xa(a.w,function(c){return e6(b,c.label)},a):null},D7=function(a){h7("Controller",a)},rxa=function(a){window.chrome&&chrome.cast&&chrome.cast.logMessage&&chrome.cast.logMessage(a)},E7=function(a){return a.B||!!a.w.length||!!a.o},F7=function(a,b,c){b!=a.o&&(g.He(a.o),(a.o=b)?(c?a.S("yt-remote-cast2-receiver-resumed",b.u):a.S("yt-remote-cast2-receiver-selected",
b.u),b.subscribe("sessionScreen",(0,g.x)(a.eB,a,b)),b.w?a.S("yt-remote-cast2-session-change",b.w):c&&a.o.Uj(null)):a.S("yt-remote-cast2-session-change",null))},Pxa=function(a){var b=a.u.aD(),c=a.o&&a.o.u;
a=(0,g.Cc)(b,function(d){c&&e6(d,c.label)&&(c=null);var e=d.uuid?d.uuid:d.id,f=Oxa(this,d);f?(f.label=e,f.friendlyName=d.name):(f=new chrome.cast.Receiver(e,d.name),f.receiverType=chrome.cast.ReceiverType.CUSTOM);return f},a);
c&&(c.receiverType!=chrome.cast.ReceiverType.CUSTOM&&(c=new chrome.cast.Receiver(c.label,c.friendlyName),c.receiverType=chrome.cast.ReceiverType.CUSTOM),a.push(c));return a},Vxa=function(a,b,c,d,e,f,k){Qxa()?Rxa(b,e,f,k)&&(H7(!0),window.chrome&&chrome.cast&&chrome.cast.isAvailable?Sxa(a,c):(window.__onGCastApiAvailable=function(l,m){l?Sxa(a,c):(I7("Failed to load cast API: "+m),J7(!1),H7(!1),k6("yt-remote-cast-available"),k6("yt-remote-cast-receiver"),Txa(),c(!1))},d?g.To("https://www.gstatic.com/cv/js/sender/v1/cast_sender.js"):
0<=window.navigator.userAgent.indexOf("Android")&&0<=window.navigator.userAgent.indexOf("Chrome/")&&window.navigator.presentation?Bwa():!window.chrome||!window.navigator.presentation||0<=window.navigator.userAgent.indexOf("Edge")?s6():(Awa(),r6(Uxa.map(ywa))))):G7("Cannot initialize because not running Chrome")},Txa=function(){G7("dispose");
var a=K7();a&&a.dispose();g.Ga("yt.mdx.remote.cloudview.instance_",null,void 0);Wxa(!1);g.Po(L7);L7.length=0},M7=function(){return!!g.Es("yt-remote-cast-installed")},Xxa=function(){var a=g.Es("yt-remote-cast-receiver");
return a?a.friendlyName:null},Yxa=function(){G7("clearCurrentReceiver");
k6("yt-remote-cast-receiver")},Zxa=function(){return M7()?K7()?K7().getCastSession():(I7("getCastSelector: Cast is not initialized."),null):(I7("getCastSelector: Cast API is not installed!"),null)},O7=function(){M7()?K7()?N7()?(G7("Requesting cast selector."),K7().requestSession()):(G7("Wait for cast API to be ready to request the session."),L7.push(g.Oo("yt-remote-cast2-api-ready",O7))):I7("requestCastSelector: Cast is not initialized."):I7("requestCastSelector: Cast API is not installed!")},P7=
function(a,b){N7()?K7().setConnectedScreenStatus(a,b):I7("setConnectedScreenStatus called before ready.")},Qxa=function(){var a=0<=g.Ic.search(/ (CrMo|Chrome|CriOS)\//);
return g.Dt||a},$xa=function(a,b){K7().init(a,b)},Rxa=function(a,b,c,d){var e=!1;
K7()||(a=new C7(a,b,c,d),a.subscribe("yt-remote-cast2-availability-change",function(f){g.Ds("yt-remote-cast-available",f);b6("yt-remote-cast2-availability-change",f)}),a.subscribe("yt-remote-cast2-receiver-selected",function(f){G7("onReceiverSelected: "+f.friendlyName);
g.Ds("yt-remote-cast-receiver",f);b6("yt-remote-cast2-receiver-selected",f)}),a.subscribe("yt-remote-cast2-receiver-resumed",function(f){G7("onReceiverResumed: "+f.friendlyName);
g.Ds("yt-remote-cast-receiver",f)}),a.subscribe("yt-remote-cast2-session-change",function(f){G7("onSessionChange: "+f6(f));
f||k6("yt-remote-cast-receiver");b6("yt-remote-cast2-session-change",f)}),g.Ga("yt.mdx.remote.cloudview.instance_",a,void 0),e=!0);
G7("cloudview.createSingleton_: "+e);return e},K7=function(){return g.w("yt.mdx.remote.cloudview.instance_")},Sxa=function(a,b){J7(!0);
H7(!1);$xa(a,function(c){c?(Wxa(!0),g.Qo("yt-remote-cast2-api-ready")):(I7("Failed to initialize cast API."),J7(!1),k6("yt-remote-cast-available"),k6("yt-remote-cast-receiver"),Txa());b(c)})},G7=function(a){h7("cloudview",a)},I7=function(a){h7("cloudview",a)},J7=function(a){G7("setCastInstalled_ "+a);
g.Ds("yt-remote-cast-installed",a)},N7=function(){return!!g.w("yt.mdx.remote.cloudview.apiReady_")},Wxa=function(a){G7("setApiReady_ "+a);
g.Ga("yt.mdx.remote.cloudview.apiReady_",a,void 0)},H7=function(a){g.Ga("yt.mdx.remote.cloudview.initializing_",a,void 0)},Q7=function(a){this.index=-1;
this.videoId=this.listId="";this.volume=this.playerState=-1;this.muted=!1;this.audioTrackId=null;this.C=this.F=0;this.o=null;this.hasNext=this.P=!1;this.I=this.G=this.u=this.B=0;this.A=NaN;this.w=!1;this.reset(a)},R7=function(a){a.audioTrackId=null;
a.o=null;a.playerState=-1;a.P=!1;a.hasNext=!1;a.F=0;a.C=(0,g.H)();a.B=0;a.u=0;a.G=0;a.I=0;a.A=NaN;a.w=!1},S7=function(a){return a.eb()?((0,g.H)()-a.C)/1E3:0},T7=function(a,b){a.F=b;
a.C=(0,g.H)()},U7=function(a){switch(a.playerState){case 1:case 1081:return((0,g.H)()-a.C)/1E3+a.F;
case -1E3:return 0}return a.F},V7=function(a,b,c){var d=a.videoId;
a.videoId=b;a.index=c;b!=d&&R7(a)},W7=function(a){var b={};
b.index=a.index;b.listId=a.listId;b.videoId=a.videoId;b.playerState=a.playerState;b.volume=a.volume;b.muted=a.muted;b.audioTrackId=a.audioTrackId;b.trackData=g.Qb(a.o);b.hasPrevious=a.P;b.hasNext=a.hasNext;b.playerTime=a.F;b.playerTimeAt=a.C;b.seekableStart=a.B;b.seekableEnd=a.u;b.duration=a.G;b.loadedTime=a.I;b.liveIngestionTime=a.A;return b},Y7=function(a,b){g.O.call(this);
this.o=0;this.A=a;this.C=[];this.B=new mxa;this.w=this.u=null;this.I=(0,g.x)(this.wK,this);this.F=(0,g.x)(this.nm,this);this.G=(0,g.x)(this.vK,this);this.P=(0,g.x)(this.HK,this);var c=0;a?(c=a.getProxyState(),3!=c&&(a.subscribe("proxyStateChange",this.hv,this),aya(this))):c=3;0!=c&&(b?this.hv(c):g.Ho((0,g.x)(function(){this.hv(c)},this),0));
var d=Zxa();d&&X7(this,d);this.subscribe("yt-remote-cast2-session-change",this.P)},Z7=function(a){return new Q7(a.A.getPlayerContextData())},aya=function(a){(0,g.y)("nowAutoplaying autoplayDismissed remotePlayerChange remoteQueueChange autoplayModeChange autoplayUpNext previousNextChange".split(" "),function(b){this.C.push(this.A.subscribe(b,g.Qa(this.wM,b),this))},a)},bya=function(a){(0,g.y)(a.C,function(b){this.A.unsubscribeByKey(b)},a);
a.C.length=0},$7=function(a,b){var c=a.B;
50>c.o.length+c.u.length&&a.B.u.push(b)},b8=function(a,b,c){var d=Z7(a);
T7(d,c);-1E3!=d.playerState&&(d.playerState=b);a8(a,d)},c8=function(a,b,c){a.A.sendMessage(b,c)},a8=function(a,b){bya(a);
a.A.setPlayerContextData(W7(b));aya(a)},X7=function(a,b){a.w&&(a.w.removeUpdateListener(a.I),a.w.removeMediaListener(a.F),a.nm(null));
a.w=b;a.w&&(h7("CP","Setting cast session: "+a.w.sessionId),a.w.addUpdateListener(a.I),a.w.addMediaListener(a.F),a.w.media.length&&a.nm(a.w.media[0]))},cya=function(a){var b=a.u.media,c=a.u.customData;
if(b&&c){var d=Z7(a);b.contentId!=d.videoId&&h7("CP","Cast changing video to: "+b.contentId);d.videoId=b.contentId;d.playerState=c.playerState;T7(d,a.u.getEstimatedTime());a8(a,d)}else h7("CP","No cast media video. Ignoring state update.")},d8=function(a,b,c){return(0,g.x)(function(d){this.Ub("Failed to "+b+" with cast v2 channel. Error code: "+d.code);
d.code!=chrome.cast.ErrorCode.TIMEOUT&&(this.Ub("Retrying "+b+" using MDx browser channel."),c8(this,b,c))},a)},e8=function(a,b,c){g.O.call(this);
this.B=NaN;this.M=!1;this.G=this.F=this.I=this.P=NaN;this.R=[];this.A=this.C=this.w=this.Va=this.o=null;this.V=a;this.R.push(g.Ep(window,"beforeunload",(0,g.x)(this.nF,this)));this.u=[];this.Va=new Q7;this.U=b.id;this.o=dya(this,c);this.o.subscribe("handlerOpened",this.AK,this);this.o.subscribe("handlerClosed",this.xK,this);this.o.subscribe("handlerError",this.yK,this);this.o.subscribe("handlerMessage",this.zK,this);qxa(this.o,b.token);this.subscribe("remoteQueueChange",function(){var d=this.Va.videoId;
g.Fs()&&g.Ds("yt-remote-session-video-id",d)},this)},f8=function(a){h7("conn",a)},dya=function(a,b){return new b7(e7(a.V,"/bc"),b)},g8=function(a,b){a.S("proxyStateChange",b)},eya=function(a){a.B=g.Ho((0,g.x)(function(){f8("Connecting timeout");
this.wj(1)},a),2E4)},h8=function(a){g.Jo(a.B);
a.B=NaN},i8=function(a){g.Jo(a.P);
a.P=NaN},fya=function(a){j8(a);
a.I=g.Ho((0,g.x)(function(){k8(this,"getNowPlaying")},a),2E4)},j8=function(a){g.Jo(a.I);
a.I=NaN},hya=function(a,b){b&&(h8(a),i8(a));
b==(c7(a.o)&&isNaN(a.B))?b&&(g8(a,1),k8(a,"getSubtitlesTrack")):b?(a.Ax()&&a.Va.reset(),g8(a,1),k8(a,"getNowPlaying"),gya(a)):a.wj(1)},iya=function(a,b){var c=b.params.videoId;
delete b.params.videoId;c==a.Va.videoId&&(g.Mb(b.params)?a.Va.o=null:a.Va.o=b.params,a.S("remotePlayerChange"))},jya=function(a,b){var c=b.params.videoId||b.params.video_id,d=parseInt(b.params.currentIndex,10);
a.Va.listId=b.params.listId||a.Va.listId;V7(a.Va,c,d);a.S("remoteQueueChange")},lya=function(a,b){b.params=b.params||{};
jya(a,b);kya(a,b);a.S("autoplayDismissed")},kya=function(a,b){var c=parseInt(b.params.currentTime||b.params.current_time,10);
T7(a.Va,isNaN(c)?0:c);c=parseInt(b.params.state,10);c=isNaN(c)?-1:c;-1==c&&-1E3==a.Va.playerState&&(c=-1E3);a.Va.playerState=c;c=Number(b.params.loadedTime);a.Va.I=isNaN(c)?0:c;c=Number(b.params.duration);a.Va.G=isNaN(c)?0:c;c=a.Va;var d=Number(b.params.liveIngestionTime);c.A=d;c.w=isNaN(d)?!1:!0;c=a.Va;d=Number(b.params.seekableStartTime);var e=Number(b.params.seekableEndTime);c.B=isNaN(d)?0:d;c.u=isNaN(e)?0:e;1==a.Va.playerState?fya(a):j8(a);a.S("remotePlayerChange")},mya=function(a,b){if(-1E3!=
a.Va.playerState){var c=1085;
switch(parseInt(b.params.adState,10)){case 1:c=1081;break;case 2:c=1084;break;case 0:c=1083}a.Va.playerState=c;c=parseInt(b.params.currentTime,10);T7(a.Va,isNaN(c)?0:c);a.S("remotePlayerChange")}},nya=function(a,b){var c="true"==b.params.muted;
a.Va.volume=parseInt(b.params.volume,10);a.Va.muted=c;a.S("remotePlayerChange")},oya=function(a,b){a.C=b.params.videoId;
a.S("nowAutoplaying",parseInt(b.params.timeout,10))},pya=function(a,b){var c="true"==b.params.hasNext;
a.Va.P="true"==b.params.hasPrevious;a.Va.hasNext=c;a.S("previousNextChange")},gya=function(a){g.Jo(a.G);
a.G=g.Ho((0,g.x)(a.wj,a,1),864E5)},k8=function(a,b,c){c?f8("Sending: action="+b+", params="+g.Jk(c)):f8("Sending: action="+b);
a.o.sendMessage(b,c)},l8=function(a){l7.call(this,"ScreenServiceProxy");
this.zd=a;this.u=[];this.u.push(this.zd.$_s("screenChange",(0,g.x)(this.vP,this)));this.u.push(this.zd.$_s("onlineScreenChange",(0,g.x)(this.YL,this)))},uya=function(a){var b={device:"Desktop",
app:"youtube-desktop"};b=g.L("MDX_CONFIG")||b;mwa();o6();m8||(m8=new d7(b?b.loungeApiHost:void 0),uwa()&&(m8.o="/api/loungedev"));n8||(n8=g.w("yt.mdx.remote.deferredProxies_")||[],g.Ga("yt.mdx.remote.deferredProxies_",n8,void 0));qya();var c=o8();if(!c){var d=new u7(m8);g.Ga("yt.mdx.remote.screenService_",d,void 0);c=o8();var e=!1,f=void 0,k=void 0,l=!1;b&&(e=!!b.loadCastApiSetupScript,f=b.appId,k=b.theme,l=!!b.disableDial);Vxa(a,d,function(m){m?p8()&&P7(p8(),"YouTube TV"):d.subscribe("onlineScreenChange",
function(){b6("yt-remote-receiver-availability-change")})},e,f,k,l)}b&&!g.w("yt.mdx.remote.initialized_")&&(g.Ga("yt.mdx.remote.initialized_",!0,void 0),q8("Initializing: "+g.Jk(b)),r8.push(g.Oo("yt-remote-cast2-availability-change",function(){b6("yt-remote-receiver-availability-change")})),r8.push(g.Oo("yt-remote-cast2-receiver-selected",function(){s8(null);
b6("yt-remote-auto-connect","cast-selector-receiver")})),r8.push(g.Oo("yt-remote-cast2-receiver-resumed",function(){b6("yt-remote-receiver-resumed","cast-selector-receiver")})),r8.push(g.Oo("yt-remote-cast2-session-change",rya)),r8.push(g.Oo("yt-remote-connection-change",function(m){m?P7(p8(),"YouTube TV"):t8()||(P7(null,null),Yxa())})),a=u8(),b.isAuto&&(a.id+="#dial"),g.xo("desktop_enable_autoplay")&&(a.capabilities=["atp"]),a.name=b.device,a.app=b.app,(k=b.theme)&&(a.theme=k),q8(" -- with channel params: "+
g.Jk(a)),sya(a),c.start(),p8()||tya())},wya=function(){var a=vya();
M7()&&g.Es("yt-remote-cast-available")&&a.push({key:"cast-selector-receiver",name:"Cast..."});return a},vya=function(){var a=o8().zd.$_gos();
var b=v8();b&&w8()&&(i6(a,b)||a.push(b));return lwa(a)},x8=function(){var a=xya();
!a&&M7()&&Xxa()&&(a={key:"cast-selector-receiver",name:Xxa()});return a},xya=function(){var a=vya(),b=v8();
b||(b=t8());return g.Xa(a,function(c){return b&&e6(b,c.key)?!0:!1})},v8=function(){var a=p8();
if(!a)return null;var b=o8().he();return j6(b,a)},rya=function(a){q8("remote.onCastSessionChange_: "+f6(a));
if(a){var b=v8();b&&b.id==a.id?P7(b.id,"YouTube TV"):(b&&y8(),z8(a,1))}else w8()&&y8()},y8=function(){N7()?K7().stopSession():I7("stopSession called before API ready.");
var a=w8();a&&(a.disconnect(1),A8(null))},B8=function(){var a=w8();
return!!a&&3!=a.getProxyState()},q8=function(a){h7("remote",a)},o8=function(){if(!C8){var a=g.w("yt.mdx.remote.screenService_");
C8=a?new l8(a):null}return C8},p8=function(){return g.w("yt.mdx.remote.currentScreenId_")},yya=function(a){g.Ga("yt.mdx.remote.currentScreenId_",a,void 0)},zya=function(){return g.w("yt.mdx.remote.connectData_")},s8=function(a){g.Ga("yt.mdx.remote.connectData_",a,void 0)},w8=function(){return g.w("yt.mdx.remote.connection_")},A8=function(a){var b=w8();
s8(null);a||yya("");g.Ga("yt.mdx.remote.connection_",a,void 0);n8&&((0,g.y)(n8,function(c){c(a)}),n8.length=0);
b&&!a?b6("yt-remote-connection-change",!1):!b&&a&&b6("yt-remote-connection-change",!0)},t8=function(){var a=g.Fs();
if(!a)return null;var b=o8().he();return j6(b,a)},z8=function(a,b){p8();
v8()&&v8();if(D8)E8=a;else{yya(a.id);var c=new e8(m8,a,u8());c.connect(b,zya());c.subscribe("beforeDisconnect",function(d){b6("yt-remote-before-disconnect",d)});
c.subscribe("beforeDispose",function(){w8()&&(w8(),A8(null))});
A8(c)}},tya=function(){var a=t8();
a?(q8("Resume connection to: "+f6(a)),z8(a,0)):(p6(),Yxa(),q8("Skipping connecting because no session screen found."))},qya=function(){var a=u8();
if(g.Mb(a)){a=n6();var b=g.Es("yt-remote-session-name")||"",c=g.Es("yt-remote-session-app")||"";a={device:"REMOTE_CONTROL",id:a,name:b,app:c,mdxVersion:3};g.Ga("yt.mdx.remote.channelParams_",a,void 0)}},u8=function(){return g.w("yt.mdx.remote.channelParams_")||{}},sya=function(a){a?(g.Ds("yt-remote-session-app",a.app),g.Ds("yt-remote-session-name",a.name)):(k6("yt-remote-session-app"),k6("yt-remote-session-name"));
g.Ga("yt.mdx.remote.channelParams_",a,void 0)},F8=function(a,b,c){g.A.call(this);
this.B=a;this.u=b;this.w=new g.Gr(this);g.B(this,this.w);this.w.L(b,"onCaptionsTrackListChanged",this.uL);this.w.L(b,"captionschanged",this.uK);this.w.L(b,"captionssettingschanged",this.oC);this.w.L(b,"videoplayerreset",this.rp);this.w.L(b,"mdxautoplaycancel",this.dE);this.U=this.w.L(b,"onVolumeChange",this.DA);this.G=!1;this.o=c;c.ea();c.subscribe("proxyStateChange",this.YA,this);c.subscribe("remotePlayerChange",this.sm,this);c.subscribe("remoteQueueChange",this.rp,this);c.subscribe("autoplayUpNext",
this.oA,this);c.subscribe("previousNextChange",this.UA,this);c.subscribe("nowAutoplaying",this.PA,this);c.subscribe("autoplayDismissed",this.nA,this);this.suggestion=null;this.I=new g.HC(64);this.A=new g.I(this.mC,500,this);g.B(this,this.A);this.C=new g.I(this.nC,1E3,this);g.B(this,this.C);this.M=new t6(this.WO,0,this);g.B(this,this.M);this.F={};this.R=new g.I(this.NC,1E3,this);g.B(this,this.R);this.P=new u6(this.FI,1E3,this);g.B(this,this.P);this.V=g.Ia;this.oC();this.rp();this.sm()},G8=function(a,
b){var c=a.B,d=a.u.getVideoData().lengthSeconds;
c.V=b||0;c.player.S("progresssync",b,d)},Aya=function(a){G8(a,0);
a.A.stop();H8(a,new g.HC(64))},J8=function(a,b){if(I8(a)&&!a.G){var c=null;
b&&(c={style:a.u.getSubtitlesUserSettings()},g.Sb(c,b));a.o.eC(a.u.getVideoData(1).videoId,c);a.F=Z7(a.o).o}},K8=function(a,b){var c=a.u.getPlaylist();
if(c){var d=c.index;var e=c.listId.toString()}c=a.u.getVideoData(1);a.o.playVideo(c.videoId,b,d,e,c.playerParams,c.Af,Zva(c));H8(a,new g.HC(1))},Bya=function(a,b){if(b){var c=a.u.getOption("captions","tracklist",{Zx:1});
c&&c.length?(a.u.setOption("captions","track",b),a.G=!1):(a.u.loadModule("captions"),a.G=!0)}else a.u.setOption("captions","track",{})},I8=function(a){return Z7(a.o).videoId==a.u.getVideoData(1).videoId},H8=function(a,b){a.C.stop();
var c=a.I;if(!g.NC(c,b)){var d=g.V(b,2);d!=g.V(a.I,2)&&g.TS(a.u.app,d);a.I=b;Cya(a.B,c,b)}},L8=function(a){g.R.call(this,{D:"div",
H:"ytp-remote",J:[{D:"div",H:"ytp-remote-display-status",J:[{D:"div",H:"ytp-remote-display-status-icon",J:[g.zM()]},{D:"div",H:"ytp-remote-display-status-text",W:"{{statustext}}"}]}]});this.u=new g.lN(this,250);g.B(this,this.u);this.w=a;this.L(a,"presentingplayerstatechange",this.A);Dya(this,g.PK(a))},Dya=function(a,b){if(3==a.w.getPresentingPlayerType()){var c={RECEIVER_NAME:a.w.getOption("remote","currentReceiver").name};
c=g.V(b,128)?g.gM("Erreur sur $RECEIVER_NAME",c):b.eb()||g.V(b,4)?g.gM("Lecture sur $RECEIVER_NAME",c):g.gM("Connect\u00e9 \u00e0 $RECEIVER_NAME",c);a.la("statustext",c);a.u.show()}else a.u.hide()},M8=function(){g.R.call(this,{D:"div",
H:"ytp-mdx-manual-pairing-popup-dialog",O:{role:"dialog"},J:[{D:"div",H:"ytp-mdx-manual-pairing-popup-dialog-inner-content",J:[{D:"div",H:"ytp-mdx-manual-pairing-popup-title",W:"Connecting to your TV on web using a code will be going away soon"},{D:"div",H:"ytp-mdx-manual-pairing-popup-buttons",J:[{D:"button",Y:["ytp-button","ytp-mdx-manual-pairing-popup-learn-more"],W:"En savoir plus"},{D:"button",Y:["ytp-button","ytp-mdx-manual-pairing-popup-ok"],W:"OK"}]}]}]});this.u=new g.lN(this,250);this.learnMoreButton=
this.o["ytp-mdx-manual-pairing-popup-learn-more"];this.okButton=this.o["ytp-mdx-manual-pairing-popup-ok"];g.B(this,this.u);this.L(this.learnMoreButton,"click",this.w);this.L(this.okButton,"click",this.A)},N8=function(){g.R.call(this,{D:"div",
H:"ytp-mdx-popup-dialog",O:{role:"dialog"},J:[{D:"div",H:"ytp-mdx-popup-dialog-inner-content",J:[{D:"div",H:"ytp-mdx-popup-title",W:"Vous \u00eates d\u00e9connect\u00e9"},{D:"div",H:"ytp-mdx-popup-description",W:"Les vid\u00e9os que vous visionnez peuvent \u00eatre ajout\u00e9es \u00e0 l'historique des vid\u00e9os regard\u00e9es sur votre t\u00e9l\u00e9viseur et avoir une influence sur les recommandations qui vous sont faites. Pour \u00e9viter ce probl\u00e8me, annulez et connectez-vous \u00e0 YouTube sur un ordinateur."},
{D:"div",H:"ytp-mdx-privacy-popup-buttons",J:[{D:"button",Y:["ytp-button","ytp-mdx-privacy-popup-cancel"],W:"Annuler"},{D:"button",Y:["ytp-button","ytp-mdx-privacy-popup-confirm"],W:"Confirmer"}]}]}]});this.u=new g.lN(this,250);this.cancelButton=this.o["ytp-mdx-privacy-popup-cancel"];this.confirmButton=this.o["ytp-mdx-privacy-popup-confirm"];g.B(this,this.u);this.L(this.cancelButton,"click",this.w);this.L(this.confirmButton,"click",this.A)},O8=function(a,b){g.iO.call(this,"Lire sur",0,a,b);
this.K=a;this.C={};this.L(a,"onMdxReceiversChange",this.G);this.L(a,"presentingplayerstatechange",this.G);this.G()},P8=function(a){g.vL.call(this,a);
this.u={key:h6(),name:"Cet ordinateur"};this.C=null;this.w=[];this.ba=this.o=null;this.U=[this.u];this.A=this.u;this.I=new g.HC(64);this.V=0;this.M=-1;this.F=null;this.P=this.R=!1;this.G=null;if(!g.az(this.player.N())){a=this.player;var b=g.dC(a);b&&(b=b.fm())&&(b=new O8(a,b),g.B(this,b));b=new L8(a);g.B(this,b);g.iL(a,b.element,4);this.G=new N8;g.B(this,this.G);g.iL(a,this.G.element,4);g.P(this.player.N().experiments,"pair_servlet_deprecation_warning_enabled")&&(this.F=new M8,g.B(this,this.F),g.iL(a,
this.F.element,4));this.P=!!t8();this.R=!!g.Es("yt-remote-manual-pairing-warning-shown")}this.B=null},Q8=function(a){a.B&&(a.player.removeEventListener("presentingplayerstatechange",a.B),a.B=null)},Cya=function(a,b,c){a.I=c;
a.player.S("presentingplayerstatechange",new g.$G(c,b))},Eya=function(a,b,c){var d=!1;
1==b?d=!a.P:2==b&&(d=!a.R);d&&g.bH(c,8)&&(a.player.pauseVideo(),Q8(a))},R8=function(a,b){if(b.key!=a.A.key)if(b.key==a.u.key)y8();
else{if(a.F&&!a.R&&b!=a.u&&"cast-selector-receiver"!=b.key&&g.jz(a.player.N()))Fya(a);else{var c;(c=!g.P(a.player.N().experiments,"mdx_enable_privacy_disclosure_ui"))||(c=((c=g.L("PLAYER_CONFIG"))&&c.args&&void 0!==c.args.authuser?!0:!(!g.L("SESSION_INDEX")&&!g.L("LOGGED_IN")))||a.P||!a.G);(c?0:g.jz(a.player.N())||"WEB_EMBEDDED_PLAYER"==a.player.N().deviceParams.c)&&Gya(a)}a.A=b;var d=a.player.getPlaylistId();c=a.player.getVideoData(1);var e=c.videoId;if(!d&&!e||(2==a.player.getAppState()||1==a.player.getAppState())&&
g.P(a.player.N().experiments,"should_clear_video_data_on_player_cued_unstarted"))c=null;else{var f=a.player.getPlaylist();if(f){var k=[];for(var l=0;l<f.getLength();l++)k[l]=f.ya(l).videoId}else k=[e];f=a.player.getCurrentTime(1);d={videoIds:k,listId:d,videoId:e,playerParams:c.playerParams,clickTrackingParams:c.Af,index:Math.max(a.player.getPlaylistIndex(),0),currentTime:0==f?void 0:f};(c=Zva(c))&&(d.locationInfo=c);c=d}q8("Connecting to: "+g.Jk(b));"cast-selector-receiver"==b.key?(s8(c||null),c=
c||null,N7()?K7().setLaunchParams(c):I7("setLaunchParams called before ready.")):!c&&B8()&&p8()==b.key?b6("yt-remote-connection-change",!0):(y8(),s8(c||null),c=o8().he(),(c=j6(c,b.key))&&z8(c,1))}},Gya=function(a){g.PK(a.player).eb()?a.player.pauseVideo():(a.B=function(b){return Eya(a,1,b)},a.player.addEventListener("presentingplayerstatechange",a.B));
a.G&&a.G.Qb();w8()||(D8=!0)},Fya=function(a){g.PK(a.player).eb()?a.player.pauseVideo():(a.B=function(b){return Eya(a,2,b)},a.player.addEventListener("presentingplayerstatechange",a.B));
a.F&&a.F.Qb();w8()||(D8=!0)},Kwa={"\x00":"\\0",
"\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r","\t":"\\t","\x0B":"\\x0B",'"':'\\"',"\\":"\\\\","<":"\\u003C"},H6={"'":"\\'"},Hya={},hwa={YP:"atp",KS:"ska",vS:"que",PR:"mus",JS:"sus",aR:"dsp",DS:"seq"},q6,m6="",zwa=vwa("loadCastFramework")||vwa("loadCastApplicationFramework"),Uxa=["pkedcjkdefgpdelpbcmbmeomcjbeemfm","enhhojjnijigcajfphajepfemndkmdlo"];/*
Copyright The Closure Library Authors.
SPDX-License-Identifier: Apache-2.0
*/
g.Sa(t6,g.A);g.h=t6.prototype;g.h.jF=function(a){this.A=arguments;this.o=!1;this.Ga?this.w=(0,g.H)()+this.Ad:this.Ga=g.Uf(this.B,this.Ad)};
g.h.stop=function(){this.Ga&&(g.v.clearTimeout(this.Ga),this.Ga=null);this.w=null;this.o=!1;this.A=[]};
g.h.pause=function(){++this.u};
g.h.resume=function(){this.u&&(--this.u,!this.u&&this.o&&(this.o=!1,this.C.apply(null,this.A)))};
g.h.X=function(){this.stop();t6.Gb.X.call(this)};
g.h.kF=function(){this.w?(this.Ga=g.Uf(this.B,this.w-(0,g.H)()),this.w=null):(this.Ga=null,this.u?this.o=!0:(this.o=!1,this.C.apply(null,this.A)))};g.Sa(u6,g.A);g.h=u6.prototype;g.h.Fj=!1;g.h.Bl=0;g.h.Ga=null;g.h.Jx=function(a){this.o=arguments;this.Ga||this.Bl?this.Fj=!0:v6(this)};
g.h.stop=function(){this.Ga&&(g.v.clearTimeout(this.Ga),this.Ga=null,this.Fj=!1,this.o=[])};
g.h.pause=function(){this.Bl++};
g.h.resume=function(){this.Bl--;this.Bl||!this.Fj||this.Ga||(this.Fj=!1,v6(this))};
g.h.X=function(){u6.Gb.X.call(this);this.stop()};
g.h.lF=function(){this.Ga=null;this.Fj&&!this.Bl&&(this.Fj=!1,v6(this))};x6.prototype.stringify=function(a){return g.v.JSON.stringify(a,void 0)};
x6.prototype.parse=function(a){return g.v.JSON.parse(a,void 0)};y6.prototype.o=null;y6.prototype.getOptions=function(){var a;(a=this.o)||(a={},Dwa(this)&&(a[0]=!0,a[1]=!0),a=this.o=a);return a};var S8;g.Sa(Cwa,y6);S8=new Cwa;g.h=z6.prototype;g.h.zi=null;g.h.df=!1;g.h.Jk=null;g.h.ev=null;g.h.wk=null;g.h.Gj=null;g.h.Vg=null;g.h.Ph=null;g.h.Yi=null;g.h.Lc=null;g.h.Sm=0;g.h.kf=null;g.h.hq=null;g.h.lh=null;g.h.Dl=-1;g.h.ZB=!0;g.h.hi=!1;g.h.ds=0;g.h.Ap=null;var Iwa={},C6={};g.h=z6.prototype;g.h.setTimeout=function(a){this.B=a};
g.h.cO=function(a){a=a.target;var b=this.Ap;b&&3==Q6(a)?b.Jx():this.VC(a)};
g.h.VC=function(a){try{if(a==this.Lc)a:{var b=Q6(this.Lc),c=this.Lc.C,d=this.Lc.getStatus();if(g.he&&!g.Ld(10)||g.je&&!g.Kd("420+")){if(4>b)break a}else if(3>b||3==b&&!g.vh&&!S6(this.Lc))break a;this.hi||4!=b||7==c||(8==c||0>=d?this.o.bf(3):this.o.bf(2));J6(this);var e=this.Lc.getStatus();this.Dl=e;var f=S6(this.Lc);(this.df=200==e)?(4==b&&F6(this),this.C?(Jwa(this,b,f),g.vh&&this.df&&3==b&&(this.A.ka(this.u,"tick",this.UN),this.u.start())):E6(this,f),this.df&&!this.hi&&(4==b?this.o.fo(this):(this.df=
!1,B6(this)))):(400==e&&0<f.indexOf("Unknown SID")?(this.lh=3,D6(13)):(this.lh=0,D6(14)),F6(this),G6(this))}}catch(k){this.Lc&&S6(this.Lc)}finally{}};
g.h.UN=function(){var a=Q6(this.Lc),b=S6(this.Lc);this.Sm<b.length&&(J6(this),Jwa(this,a,b),this.df&&4!=a&&B6(this))};
g.h.wN=function(a){I6((0,g.x)(this.vN,this,a),0)};
g.h.vN=function(a){this.hi||(J6(this),E6(this,a),B6(this))};
g.h.hB=function(a){I6((0,g.x)(this.uN,this,a),0)};
g.h.uN=function(a){this.hi||(F6(this),this.df=a,this.o.fo(this),this.o.bf(4))};
g.h.cancel=function(){this.hi=!0;F6(this)};
g.h.EN=function(){this.Jk=null;var a=(0,g.H)();0<=a-this.ev?(2!=this.Gj&&this.o.bf(3),F6(this),this.lh=2,D6(18),G6(this)):Mwa(this,this.ev-a)};
g.h.getLastError=function(){return this.lh};g.h=Pwa.prototype;g.h.Yr=null;g.h.Vd=null;g.h.Bp=!1;g.h.Lx=null;g.h.On=null;g.h.Ks=null;g.h.Zr=null;g.h.ye=null;g.h.rg=-1;g.h.Cl=null;g.h.Vk=null;g.h.connect=function(a){this.Zr=a;a=L6(this.o,null,this.Zr);D6(3);this.Lx=(0,g.H)();var b=this.o.G;null!=b?(this.Cl=b[0],(this.Vk=b[1])?(this.ye=1,Qwa(this)):(this.ye=2,N6(this))):(Z5(a,"MODE","init"),this.Vd=new z6(this,void 0,void 0,void 0),this.Vd.zi=this.Yr,A6(this.Vd,a,!1,null,!0),this.ye=0)};
g.h.eE=function(a){if(a)this.ye=2,N6(this);else{D6(4);var b=this.o;b.yf=b.Zg.rg;Z6(b,9)}a&&this.bf(2)};
g.h.rr=function(a){return this.o.rr(a)};
g.h.abort=function(){this.Vd&&(this.Vd.cancel(),this.Vd=null);this.rg=-1};
g.h.Kx=function(){return!1};
g.h.ZA=function(a,b){this.rg=a.Dl;if(0==this.ye)if(b){try{var c=this.u.parse(b)}catch(d){c=this.o;c.yf=this.rg;Z6(c,2);return}this.Cl=c[0];this.Vk=c[1]}else c=this.o,c.yf=this.rg,Z6(c,2);else if(2==this.ye)if(this.Bp)D6(7),this.Ks=(0,g.H)();else if("11111"==b){if(D6(6),this.Bp=!0,this.On=(0,g.H)(),c=this.On-this.Lx,!g.he||g.Ld(10)||500>c)this.rg=200,this.Vd.cancel(),D6(12),M6(this.o,this,!0)}else D6(8),this.On=this.Ks=(0,g.H)(),this.Bp=!1};
g.h.fo=function(){this.rg=this.Vd.Dl;if(this.Vd.df)0==this.ye?this.Vk?(this.ye=1,Qwa(this)):(this.ye=2,N6(this)):2==this.ye&&((!g.he||g.Ld(10)?!this.Bp:200>this.Ks-this.On)?(D6(11),M6(this.o,this,!1)):(D6(12),M6(this.o,this,!0)));else{0==this.ye?D6(9):2==this.ye&&D6(10);var a=this.o;this.Vd.getLastError();a.yf=this.rg;Z6(a,2)}};
g.h.Im=function(){return this.o.Im()};
g.h.isActive=function(){return this.o.isActive()};
g.h.bf=function(a){this.o.bf(a)};g.Sa(O6,g.gf);var Vwa=/^https?$/i,Iya=["POST","PUT"];g.h=O6.prototype;
g.h.send=function(a,b,c,d){if(this.o)throw Error("[goog.net.XhrIo] Object is active with another request="+this.I+"; newUri="+a);b=b?b.toUpperCase():"GET";this.I=a;this.A="";this.C=0;this.ha=b;this.V=!1;this.w=!0;this.o=this.U?Ewa(this.U):Ewa(S8);this.R=this.U?this.U.getOptions():S8.getOptions();this.o.onreadystatechange=(0,g.x)(this.VA,this);try{a6(R6(this,"Opening Xhr")),this.Z=!0,this.o.open(b,String(a),!0),this.Z=!1}catch(f){a6(R6(this,"Error opening Xhr: "+f.message));Uwa(this,f);return}a=c||
"";var e=this.headers.clone();d&&dwa(d,function(f,k){e.set(k,f)});
d=g.Xa(e.te(),Swa);c=g.v.FormData&&a instanceof g.v.FormData;!g.$a(Iya,b)||d||c||e.set("Content-Type","application/x-www-form-urlencoded;charset=utf-8");e.forEach(function(f,k){this.o.setRequestHeader(k,f)},this);
this.da&&(this.o.responseType=this.da);"withCredentials"in this.o&&this.o.withCredentials!==this.ba&&(this.o.withCredentials=this.ba);try{Xwa(this),0<this.F&&(this.M=Rwa(this.o),a6(R6(this,"Will abort after "+this.F+"ms if incomplete, xhr2 "+this.M)),this.M?(this.o.timeout=this.F,this.o.ontimeout=(0,g.x)(this.Mx,this)):this.P=g.Uf(this.Mx,this.F,this)),a6(R6(this,"Sending request")),this.G=!0,this.o.send(a),this.G=!1}catch(f){a6(R6(this,"Send error: "+f.message)),Uwa(this,f)}};
g.h.Mx=function(){"undefined"!=typeof g.H1&&this.o&&(this.A="Timed out after "+this.F+"ms, aborting",this.C=8,R6(this,this.A),this.dispatchEvent("timeout"),this.abort(8))};
g.h.abort=function(a){this.o&&this.w&&(R6(this,"Aborting"),this.w=!1,this.B=!0,this.o.abort(),this.B=!1,this.C=a||7,this.dispatchEvent("complete"),this.dispatchEvent("abort"),P6(this))};
g.h.X=function(){this.o&&(this.w&&(this.w=!1,this.B=!0,this.o.abort(),this.B=!1),P6(this,!0));O6.Gb.X.call(this)};
g.h.VA=function(){this.ea()||(this.Z||this.G||this.B?Wwa(this):this.yM())};
g.h.yM=function(){Wwa(this)};
g.h.isActive=function(){return!!this.o};
g.h.getStatus=function(){try{return 2<Q6(this)?this.o.status:-1}catch(a){return-1}};
g.h.getLastError=function(){return"string"===typeof this.A?this.A:String(this.A)};g.h=T6.prototype;g.h.ql=null;g.h.Od=null;g.h.hc=null;g.h.Xr=null;g.h.Rn=null;g.h.jw=null;g.h.eo=null;g.h.lm=0;g.h.OJ=0;g.h.wd=null;g.h.eh=null;g.h.cg=null;g.h.ni=null;g.h.Zg=null;g.h.fq=null;g.h.Tj=-1;g.h.ty=-1;g.h.yf=-1;g.h.yj=0;g.h.qj=0;g.h.ii=8;var $6=new g.gf;g.Sa(Zwa,g.Je);g.Sa($wa,g.Je);g.Sa(axa,g.Je);g.h=T6.prototype;g.h.connect=function(a,b,c,d,e){D6(0);this.Xr=b;this.ql=c||{};d&&void 0!==e&&(this.ql.OSID=d,this.ql.OAID=e);this.C?(I6((0,g.x)(this.Dw,this,a),100),exa(this)):this.Dw(a)};
g.h.Dw=function(a){this.Zg=new Pwa(this);this.Zg.Yr=null;this.Zg.u=this.B;this.Zg.connect(a)};
g.h.Kx=function(){return 0==this.o};
g.h.gB=function(a){this.eh=null;hxa(this,a)};
g.h.fB=function(){this.cg=null;this.hc=new z6(this,this.w,"rpc",this.F);this.hc.zi=null;this.hc.ds=0;var a=this.jw.clone();X5(a,"RID","rpc");X5(a,"SID",this.w);X5(a,"CI",this.fq?"0":"1");X5(a,"AID",this.Tj);U6(this,a);if(!g.he||g.Ld(10))X5(a,"TYPE","xmlhttp"),A6(this.hc,a,!0,this.eo,!1);else{X5(a,"TYPE","html");var b=this.hc,c=!!this.eo;b.Gj=3;b.Vg=Y5(a.clone());Lwa(b,c)}};
g.h.ZA=function(a,b){if(0!=this.o&&(this.hc==a||this.Od==a))if(this.yf=a.Dl,this.Od==a&&3==this.o)if(7<this.ii){try{var c=this.B.parse(b)}catch(f){c=null}if(Array.isArray(c)&&3==c.length)if(0==c[0])a:{if(!this.cg){if(this.hc)if(this.hc.wk+3E3<this.Od.wk)W6(this),this.hc.cancel(),this.hc=null;else break a;Y6(this);D6(19)}}else this.ty=c[1],0<this.ty-this.Tj&&37500>c[2]&&this.fq&&0==this.qj&&!this.ni&&(this.ni=I6((0,g.x)(this.qK,this),6E3));else Z6(this,11)}else b!=Hya.vQ.o&&Z6(this,11);else if(this.hc==
a&&W6(this),!g.ec(b)){c=this.B.parse(b);for(var d=0;d<c.length;d++){var e=c[d];this.Tj=e[0];e=e[1];2==this.o?"c"==e[0]?(this.w=e[1],this.eo=e[2],e=e[3],null!=e?this.ii=e:this.ii=6,this.o=3,this.wd&&this.wd.zw(),this.jw=L6(this,this.Im()?this.eo:null,this.Xr),ixa(this)):"stop"==e[0]&&Z6(this,7):3==this.o&&("stop"==e[0]?Z6(this,7):"noop"!=e[0]&&this.wd&&this.wd.yw(e),this.qj=0)}}};
g.h.qK=function(){null!=this.ni&&(this.ni=null,this.hc.cancel(),this.hc=null,Y6(this),D6(20))};
g.h.fo=function(a){if(this.hc==a){W6(this);this.hc=null;var b=2}else if(this.Od==a)this.Od=null,b=1;else return;this.yf=a.Dl;if(0!=this.o)if(a.df)1==b?(b=(0,g.H)()-a.wk,$6.dispatchEvent(new $wa($6,a.Yi?a.Yi.length:0,b,this.yj)),V6(this),this.A.length=0):ixa(this);else{var c=a.getLastError(),d;if(!(d=3==c||7==c||0==c&&0<this.yf)){if(d=1==b)this.Od||this.eh||1==this.o||2<=this.yj?d=!1:(this.eh=I6((0,g.x)(this.gB,this,a),jxa(this,this.yj)),this.yj++,d=!0);d=!(d||2==b&&Y6(this))}if(d)switch(c){case 1:Z6(this,
5);break;case 4:Z6(this,10);break;case 3:Z6(this,6);break;case 7:Z6(this,12);break;default:Z6(this,2)}}};
g.h.DE=function(a){if(!g.$a(arguments,this.o))throw Error("Unexpected channel state: "+this.o);};
g.h.NO=function(a){a?D6(2):(D6(1),kxa(this,8))};
g.h.rr=function(a){if(a)throw Error("Can't create secondary domain capable XhrIo object.");a=new O6;a.ba=!1;return a};
g.h.isActive=function(){return!!this.wd&&this.wd.isActive(this)};
g.h.bf=function(a){$6.dispatchEvent(new axa($6,a))};
g.h.Im=function(){return!(!g.he||g.Ld(10))};
g.h=lxa.prototype;g.h.zw=function(){};
g.h.yw=function(){};
g.h.xw=function(){};
g.h.fr=function(){};
g.h.gx=function(){return{}};
g.h.isActive=function(){return!0};g.h=mxa.prototype;g.h.isEmpty=function(){return g.ab(this.o)&&g.ab(this.u)};
g.h.clear=function(){this.o=[];this.u=[]};
g.h.contains=function(a){return g.$a(this.o,a)||g.$a(this.u,a)};
g.h.remove=function(a){var b=this.o;var c=(0,g.Wqa)(b,a);0<=c?(g.cb(b,c),b=!0):b=!1;return b||g.db(this.u,a)};
g.h.Ed=function(){for(var a=[],b=this.o.length-1;0<=b;--b)a.push(this.o[b]);var c=this.u.length;for(b=0;b<c;++b)a.push(this.u[b]);return a};g.Sa(a7,g.A);g.h=a7.prototype;g.h.pN=function(){this.Ad=Math.min(3E5,2*this.Ad);this.w();this.u&&this.start()};
g.h.start=function(){var a=this.Ad+15E3*Math.random();this.o.Ua(a);this.u=(0,g.H)()+a};
g.h.stop=function(){this.o.stop();this.u=0};
g.h.isActive=function(){return this.o.isActive()};
g.h.reset=function(){this.o.stop();this.Ad=5E3};g.Sa(b7,lxa);g.h=b7.prototype;g.h.subscribe=function(a,b,c){return this.w.subscribe(a,b,c)};
g.h.unsubscribe=function(a,b,c){return this.w.unsubscribe(a,b,c)};
g.h.Eh=function(a){return this.w.Ai(a)};
g.h.S=function(a,b){return this.w.S.apply(this.w,arguments)};
g.h.dispose=function(){this.ub||(this.ub=!0,g.He(this.w),pxa(this),g.He(this.u),this.u=null)};
g.h.ea=function(){return this.ub};
g.h.connect=function(a,b,c){if(!this.o||2!=this.o.o){this.I="";this.u.stop();this.B=a||null;this.A=b||0;a=this.P+"/test";b=this.P+"/bind";var d=new T6(c?c.firstTestResults:null,c?c.secondTestResults:null,this.M),e=this.o;e&&(e.wd=null);d.wd=this;this.o=d;e?this.o.connect(a,b,this.C,e.w,e.Tj):c?this.o.connect(a,b,this.C,c.sessionId,c.arrayId):this.o.connect(a,b,this.C)}};
g.h.sendMessage=function(a,b){var c={_sc:a};b&&g.Sb(c,b);this.u.isActive()||2==(this.o?this.o.o:0)?this.F.push(c):c7(this)&&fxa(this.o,c)};
g.h.zw=function(){this.u.reset();this.B=null;this.A=0;if(this.F.length){var a=this.F;this.F=[];for(var b=0,c=a.length;b<c;++b)fxa(this.o,a[b])}this.S("handlerOpened")};
g.h.xw=function(a){var b=2==a&&401==this.o.yf;4==a||b||this.u.start();this.S("handlerError",a)};
g.h.fr=function(a){if(!this.u.isActive())this.S("handlerClosed");else if(a)for(var b=0,c=a.length;b<c;++b){var d=a[b].map;d&&this.F.push(d)}};
g.h.gx=function(){var a={v:2};this.I&&(a.gsessionid=this.I);0!=this.A&&(a.ui=""+this.A);0!=this.G&&(a.ui=""+this.G);this.B&&g.Sb(a,this.B);return a};
g.h.yw=function(a){"S"==a[0]?this.I=a[1]:"gracefulReconnect"==a[0]?(this.u.start(),dxa(this.o)):this.S("handlerMessage",new nxa(a[0],a[1]))};
g.h.qO=function(){this.u.isActive();var a=this.o,b=0;a.hc&&b++;a.Od&&b++;0==b&&this.connect(this.B,this.A)};d7.prototype.A=function(a,b,c,d){b?a(d):a({text:c.responseText})};
d7.prototype.w=function(a,b){a(Error("Request error: "+b.status))};
d7.prototype.B=function(a){a(Error("request timed out"))};var xxa=(0,g.H)(),g7=null,j7=Array(50),i7=-1,k7=!1;g.Sa(l7,g.O);l7.prototype.he=function(){return this.o};
l7.prototype.contains=function(a){return!!i6(this.o,a)};
l7.prototype.get=function(a){return a?j6(this.o,a):null};
l7.prototype.info=function(a){h7(this.F,a)};g.r(m7,g.O);g.h=m7.prototype;g.h.start=function(){!this.o&&isNaN(this.Ga)&&this.ZC()};
g.h.stop=function(){this.o&&(this.o.abort(),this.o=null);isNaN(this.Ga)||(g.Jo(this.Ga),this.Ga=NaN)};
g.h.X=function(){this.stop();g.O.prototype.X.call(this)};
g.h.ZC=function(){this.Ga=NaN;this.o=g.Eq(e7(this.C,"/pairing/get_screen"),{method:"POST",sb:{pairing_code:this.A},timeout:5E3,onSuccess:(0,g.x)(this.tP,this),onError:(0,g.x)(this.sP,this),Ud:(0,g.x)(this.uP,this)})};
g.h.tP=function(a,b){this.o=null;var c=b.screen||{};c.dialId=this.B;c.name=this.w;this.S("pairingComplete",new d6(c))};
g.h.sP=function(a){this.o=null;a.status&&404==a.status?this.u>=Jya.length?this.S("pairingFailed",Error("DIAL polling timed out")):(a=Jya[this.u],this.Ga=g.Ho((0,g.x)(this.ZC,this),a),this.u++):this.S("pairingFailed",Error("Server error "+a.status))};
g.h.uP=function(){this.o=null;this.S("pairingFailed",Error("Server not responding"))};
var Jya=[2E3,2E3,1E3,1E3,1E3,2E3,2E3,5E3,5E3,1E4];g.Sa(o7,l7);g.h=o7.prototype;g.h.start=function(){n7(this)&&this.S("screenChange");!g.Es("yt-remote-lounge-token-expiration")&&Bxa(this);g.Jo(this.u);this.u=g.Ho((0,g.x)(this.start,this),1E4)};
g.h.add=function(a,b){n7(this);yxa(this,a);p7(this,!1);this.S("screenChange");b(a);a.token||Bxa(this)};
g.h.remove=function(a,b){var c=n7(this);Axa(this,a)&&(p7(this,!1),c=!0);b(a);c&&this.S("screenChange")};
g.h.cq=function(a,b,c,d){var e=n7(this),f=this.get(a.id);f?(f.name!=b&&(f.name=b,p7(this,!1),e=!0),c(a)):d(Error("no such local screen."));e&&this.S("screenChange")};
g.h.X=function(){g.Jo(this.u);o7.Gb.X.call(this)};
g.h.vF=function(a){n7(this);var b=this.o.length;a=a&&a.screens||[];for(var c=0,d=a.length;c<d;++c){var e=a[c],f=this.get(e.screenId);f&&(f.token=e.loungeToken,--b)}p7(this,!b);b&&h7(this.F,"Missed "+b+" lounge tokens.")};
g.h.uF=function(a){h7(this.F,"Requesting lounge tokens failed: "+a)};g.r(r7,g.O);g.h=r7.prototype;g.h.start=function(){var a=parseInt(g.Es("yt-remote-fast-check-period")||"0",10);(this.A=(0,g.H)()-144E5<a?0:a)?t7(this):(this.A=(0,g.H)()+3E5,g.Ds("yt-remote-fast-check-period",this.A),this.vu())};
g.h.isEmpty=function(){return g.Mb(this.o)};
g.h.update=function(){q7("Updating availability on schedule.");var a=this.C(),b=g.Ab(this.o,function(c,d){return c&&!!j6(a,d)},this);
s7(this,b)};
g.h.X=function(){g.Jo(this.w);this.w=NaN;this.u&&(this.u.abort(),this.u=null);g.O.prototype.X.call(this)};
g.h.vu=function(){g.Jo(this.w);this.w=NaN;this.u&&this.u.abort();var a=Exa(this);if($5(a)){var b=e7(this.B,"/pairing/get_screen_availability");this.u=f7(this.B,b,{lounge_token:g.Gb(a).join(",")},(0,g.x)(this.YM,this,a),(0,g.x)(this.XM,this))}else s7(this,{}),t7(this)};
g.h.YM=function(a,b){this.u=null;var c=g.Gb(Exa(this));if(g.sb(c,g.Gb(a))){c=b.screens||[];for(var d={},e=0,f=c.length;e<f;++e)d[a[c[e].loungeToken]]="online"==c[e].status;s7(this,d);t7(this)}else this.Ub("Changing Screen set during request."),this.vu()};
g.h.XM=function(a){this.Ub("Screen availability failed: "+a);this.u=null;t7(this)};
g.h.Ub=function(a){h7("OnlineScreenService",a)};g.Sa(u7,l7);g.h=u7.prototype;g.h.start=function(){this.w.start();this.u.start();this.o.length&&(this.S("screenChange"),this.u.isEmpty()||this.S("onlineScreenChange"))};
g.h.add=function(a,b,c){this.w.add(a,b,c)};
g.h.remove=function(a,b,c){this.w.remove(a,b,c);this.u.update()};
g.h.cq=function(a,b,c,d){this.w.contains(a)?this.w.cq(a,b,c,d):(a="Updating name of unknown screen: "+a.name,h7(this.F,a),d(Error(a)))};
g.h.he=function(a){return a?this.o:g.fb(this.o,(0,g.ue)(this.A,function(b){return!this.contains(b)},this))};
g.h.aD=function(){return(0,g.ue)(this.he(!0),function(a){return!!this.u.o[a.id]},this)};
g.h.bD=function(a,b,c,d,e){this.info("getDialScreenByPairingCode "+a+" / "+b);var f=new m7(this.C,a,b,c);f.subscribe("pairingComplete",(0,g.x)(function(k){g.He(f);d(v7(this,k))},this));
f.subscribe("pairingFailed",function(k){g.He(f);e(k)});
f.start();return(0,g.x)(f.stop,f)};
g.h.wP=function(a,b,c,d){g.Eq(e7(this.C,"/pairing/get_screen"),{method:"POST",sb:{pairing_code:a},timeout:5E3,onSuccess:(0,g.x)(function(e,f){var k=new d6(f.screen||{});if(!k.name||Ixa(this,k.name)){a:{var l=k.name;for(var m=2,n=b(l,m);Ixa(this,n);){m++;if(20<m)break a;n=b(l,m)}l=n}k.name=l}c(v7(this,k))},this),
onError:(0,g.x)(function(e){d(Error("pairing request failed: "+e.status))},this),
Ud:(0,g.x)(function(){d(Error("pairing request timed out."))},this)})};
g.h.X=function(){g.He(this.w);g.He(this.u);u7.Gb.X.call(this)};
g.h.EF=function(){Jxa(this);this.S("screenChange");this.u.update()};
u7.prototype.dispose=u7.prototype.dispose;g.Sa(x7,g.O);g.h=x7.prototype;g.h.qp=function(a){this.w=a;this.S("sessionScreen",this.w)};
g.h.le=function(a){this.ea()||(a&&y7(this,""+a),this.w=null,this.S("sessionScreen",null))};
g.h.info=function(a){h7(this.R,a)};
g.h.dD=function(){return null};
g.h.Eu=function(a){var b=this.u;a?(b.displayStatus=new chrome.cast.ReceiverDisplayStatus(a,[]),b.displayStatus.showStop=!0):b.displayStatus=null;chrome.cast.setReceiverDisplayStatus(b,(0,g.x)(function(){this.info("Updated receiver status for "+b.friendlyName+": "+a)},this),(0,g.x)(function(){y7(this,"Failed to update receiver status for: "+b.friendlyName)},this))};
g.h.X=function(){this.Eu("");x7.Gb.X.call(this)};g.Sa(z7,x7);g.h=z7.prototype;g.h.Du=function(a){if(this.o){if(this.o==a)return;y7(this,"Overriding cast sesison with new session object");this.o.removeUpdateListener(this.C);this.o.removeMessageListener("urn:x-cast:com.google.youtube.mdx",this.B)}this.o=a;this.o.addUpdateListener(this.C);this.o.addMessageListener("urn:x-cast:com.google.youtube.mdx",this.B);Lxa(this)};
g.h.Uj=function(a){this.info("launchWithParams no-op for Cast: "+g.Jk(a))};
g.h.stop=function(){this.o?this.o.stop((0,g.x)(function(){this.le()},this),(0,g.x)(function(){this.le(Error("Failed to stop receiver app."))},this)):this.le(Error("Stopping cast device witout session."))};
g.h.Eu=g.Ia;g.h.X=function(){this.info("disposeInternal");g.Jo(this.A);this.A=0;this.o&&(this.o.removeUpdateListener(this.C),this.o.removeMessageListener("urn:x-cast:com.google.youtube.mdx",this.B));this.o=null;z7.Gb.X.call(this)};
g.h.MN=function(a,b){if(!this.ea())if(b){var c=w6(b);if(g.Na(c)){var d=""+c.type;c=c.data||{};this.info("onYoutubeMessage_: "+d+" "+g.Jk(c));switch(d){case "mdxSessionStatus":Kxa(this,c.screenId);break;default:y7(this,"Unknown youtube message: "+d)}}else y7(this,"Unable to parse message.")}else y7(this,"No data in message.")};
g.h.Cx=function(a,b,c,d){Hxa(this.I,this.u.label,a,this.u.friendlyName,(0,g.x)(function(e){e?b(e):0<=d?(y7(this,"Screen "+a+" appears to be offline. "+d+" retries left."),g.Ho((0,g.x)(this.Cx,this,a,b,c,d-1),300)):c(Error("Unable to fetch screen."))},this),c)};
g.h.dD=function(){return this.o};
g.h.xP=function(a){this.ea()||a||(y7(this,"Cast session died."),this.le())};g.Sa(A7,x7);g.h=A7.prototype;g.h.Du=function(a){this.A=a;this.A.addUpdateListener(this.M)};
g.h.Uj=function(a){this.B=a;this.F()};
g.h.stop=function(){this.o();this.o=g.Ia;g.Jo(this.C);this.A?this.A.stop((0,g.x)(this.le,this,null),(0,g.x)(this.le,this,"Failed to stop DIAL device.")):this.le()};
g.h.X=function(){this.o();this.o=g.Ia;g.Jo(this.C);this.A&&this.A.removeUpdateListener(this.M);this.A=null;A7.Gb.X.call(this)};
g.h.AP=function(a){this.ea()||a||(y7(this,"DIAL session died."),this.o(),this.o=g.Ia,this.le())};
g.h.ws=function(a){this.P=h6();if(this.B){var b=new chrome.cast.DialLaunchResponse(!0,Nxa(this));a(b);Mxa(this)}else this.F=(0,g.x)(function(){g.Jo(this.C);this.F=g.Ia;this.C=NaN;var c=new chrome.cast.DialLaunchResponse(!0,Nxa(this));a(c);Mxa(this)},this),this.C=g.Ho((0,g.x)(function(){this.F()},this),100)};
g.h.XF=function(a,b,c){Hxa(this.I,this.G.receiver.label,a,this.u.friendlyName,(0,g.x)(function(d){d&&d.token?(this.qp(d),b(new chrome.cast.DialLaunchResponse(!1))):this.ws(b,c)},this),(0,g.x)(function(d){y7(this,"Failed to get DIAL screen: "+d);
this.ws(b,c)},this))};g.Sa(B7,x7);B7.prototype.stop=function(){this.le()};
B7.prototype.Du=g.Ia;B7.prototype.Uj=function(){g.Jo(this.o);this.o=NaN;var a=j6(this.I.he(),this.u.label);a?this.qp(a):this.le(Error("No such screen"))};
B7.prototype.X=function(){g.Jo(this.o);this.o=NaN;B7.Gb.X.call(this)};g.Sa(C7,g.O);g.h=C7.prototype;
g.h.init=function(a,b){chrome.cast.timeout.requestSession=3E4;var c=new chrome.cast.SessionRequest(this.F);this.G||(c.dialRequest=new chrome.cast.DialRequest("YouTube"));var d=chrome.cast.AutoJoinPolicy.TAB_AND_ORIGIN_SCOPED,e=a?chrome.cast.DefaultActionPolicy.CAST_THIS_TAB:chrome.cast.DefaultActionPolicy.CREATE_SESSION,f=(0,g.x)(this.DM,this);c=new chrome.cast.ApiConfig(c,(0,g.x)(this.cB,this),f,d,e);c.customDialLaunchCallback=(0,g.x)(this.OK,this);chrome.cast.initialize(c,(0,g.x)(function(){this.ea()||
(chrome.cast.addReceiverActionListener(this.A),uxa(),this.u.subscribe("onlineScreenChange",(0,g.x)(this.cD,this)),this.w=Pxa(this),chrome.cast.setCustomReceivers(this.w,g.Ia,(0,g.x)(function(k){this.Ub("Failed to set initial custom receivers: "+g.Jk(k))},this)),this.S("yt-remote-cast2-availability-change",E7(this)),b(!0))},this),(0,g.x)(function(k){this.Ub("Failed to initialize API: "+g.Jk(k));
b(!1)},this))};
g.h.xO=function(a,b){D7("Setting connected screen ID: "+a+" -> "+b);if(this.o){var c=this.o.w;if(!a||c&&c.id!=a)D7("Unsetting old screen status: "+this.o.u.friendlyName),F7(this,null)}if(a&&b){if(!this.o){c=j6(this.u.he(),a);if(!c){D7("setConnectedScreenStatus: Unknown screen.");return}var d=Oxa(this,c);d||(D7("setConnectedScreenStatus: Connected receiver not custom..."),d=new chrome.cast.Receiver(c.uuid?c.uuid:c.id,c.name),d.receiverType=chrome.cast.ReceiverType.CUSTOM,this.w.push(d),chrome.cast.setCustomReceivers(this.w,
g.Ia,(0,g.x)(function(e){this.Ub("Failed to set initial custom receivers: "+g.Jk(e))},this)));
D7("setConnectedScreenStatus: new active receiver: "+d.friendlyName);F7(this,new B7(this.u,d),!0)}this.o.Eu(b)}else D7("setConnectedScreenStatus: no screen.")};
g.h.yO=function(a){this.ea()?this.Ub("Setting connection data on disposed cast v2"):this.o?this.o.Uj(a):this.Ub("Setting connection data without a session")};
g.h.zP=function(){this.ea()?this.Ub("Stopping session on disposed cast v2"):this.o?(this.o.stop(),F7(this,null)):D7("Stopping non-existing session")};
g.h.requestSession=function(){chrome.cast.requestSession((0,g.x)(this.cB,this),(0,g.x)(this.cN,this))};
g.h.X=function(){this.u.unsubscribe("onlineScreenChange",(0,g.x)(this.cD,this));window.chrome&&chrome.cast&&chrome.cast.removeReceiverActionListener(this.A);var a=rxa,b=g.w("yt.mdx.remote.debug.handlers_");g.db(b||[],a);g.He(this.o);C7.Gb.X.call(this)};
g.h.Ub=function(a){h7("Controller",a)};
g.h.eB=function(a,b){this.o==a&&(b||F7(this,null),this.S("yt-remote-cast2-session-change",b))};
g.h.zM=function(a,b){if(!this.ea())if(a)switch(a.friendlyName=chrome.cast.unescape(a.friendlyName),D7("onReceiverAction_ "+a.label+" / "+a.friendlyName+"-- "+b),b){case chrome.cast.ReceiverAction.CAST:if(this.o)if(this.o.u.label!=a.label)D7("onReceiverAction_: Stopping active receiver: "+this.o.u.friendlyName),this.o.stop();else{D7("onReceiverAction_: Casting to active receiver.");this.o.w&&this.S("yt-remote-cast2-session-change",this.o.w);break}switch(a.receiverType){case chrome.cast.ReceiverType.CUSTOM:F7(this,
new B7(this.u,a));break;case chrome.cast.ReceiverType.DIAL:F7(this,new A7(this.u,a,this.C));break;case chrome.cast.ReceiverType.CAST:F7(this,new z7(this.u,a));break;default:this.Ub("Unknown receiver type: "+a.receiverType)}break;case chrome.cast.ReceiverAction.STOP:this.o&&this.o.u.label==a.label?this.o.stop():this.Ub("Stopping receiver w/o session: "+a.friendlyName)}else this.Ub("onReceiverAction_ called without receiver.")};
g.h.OK=function(a){if(this.ea())return Promise.reject(Error("disposed"));var b=a.receiver;b.receiverType!=chrome.cast.ReceiverType.DIAL&&(this.Ub("Not DIAL receiver: "+b.friendlyName),b.receiverType=chrome.cast.ReceiverType.DIAL);var c=this.o?this.o.u:null;if(!c||c.label!=b.label)return this.Ub("Receiving DIAL launch request for non-clicked DIAL receiver: "+b.friendlyName),Promise.reject(Error("illegal DIAL launch"));if(c&&c.label==b.label&&c.receiverType!=chrome.cast.ReceiverType.DIAL){if(this.o.w)return D7("Reselecting dial screen."),
this.S("yt-remote-cast2-session-change",this.o.w),Promise.resolve(new chrome.cast.DialLaunchResponse(!1));this.Ub('Changing CAST intent from "'+c.receiverType+'" to "dial" for '+b.friendlyName);F7(this,new A7(this.u,b,this.C))}b=this.o;b.G=a;return b.G.appState==chrome.cast.DialAppState.RUNNING?new Promise((0,g.x)(b.XF,b,(b.G.extraData||{}).screenId||null)):new Promise((0,g.x)(b.ws,b))};
g.h.cB=function(a){if(!this.ea()){D7("New cast session ID: "+a.sessionId);var b=a.receiver;if(b.receiverType!=chrome.cast.ReceiverType.CUSTOM){if(!this.o)if(b.receiverType==chrome.cast.ReceiverType.CAST)D7("Got resumed cast session before resumed mdx connection."),b.friendlyName=chrome.cast.unescape(b.friendlyName),F7(this,new z7(this.u,b),!0);else{this.Ub("Got non-cast session without previous mdx receiver event, or mdx resume.");return}var c=this.o.u,d=j6(this.u.he(),c.label);d&&e6(d,b.label)&&
c.receiverType!=chrome.cast.ReceiverType.CAST&&b.receiverType==chrome.cast.ReceiverType.CAST&&(D7("onSessionEstablished_: manual to cast session change "+b.friendlyName),g.He(this.o),this.o=new z7(this.u,b),this.o.subscribe("sessionScreen",(0,g.x)(this.eB,this,this.o)),this.o.Uj(null));this.o.Du(a)}}};
g.h.yP=function(){return this.o?this.o.dD():null};
g.h.cN=function(a){this.ea()||(this.Ub("Failed to estabilish a session: "+g.Jk(a)),a.code!=chrome.cast.ErrorCode.CANCEL&&F7(this,null))};
g.h.DM=function(a){D7("Receiver availability updated: "+a);if(!this.ea()){var b=E7(this);this.B=a==chrome.cast.ReceiverAvailability.AVAILABLE;E7(this)!=b&&this.S("yt-remote-cast2-availability-change",E7(this))}};
g.h.cD=function(){this.ea()||(this.w=Pxa(this),D7("Updating custom receivers: "+g.Jk(this.w)),chrome.cast.setCustomReceivers(this.w,g.Ia,(0,g.x)(function(){this.Ub("Failed to set custom receivers.")},this)),this.S("yt-remote-cast2-availability-change",E7(this)))};
C7.prototype.setLaunchParams=C7.prototype.yO;C7.prototype.setConnectedScreenStatus=C7.prototype.xO;C7.prototype.stopSession=C7.prototype.zP;C7.prototype.getCastSession=C7.prototype.yP;C7.prototype.requestSession=C7.prototype.requestSession;C7.prototype.init=C7.prototype.init;C7.prototype.dispose=C7.prototype.dispose;var L7=[];g.h=Q7.prototype;
g.h.reset=function(a){this.listId="";this.index=-1;this.videoId="";R7(this);this.volume=-1;this.muted=!1;a&&(this.index=a.index,this.listId=a.listId,this.videoId=a.videoId,this.playerState=a.playerState,this.volume=a.volume,this.muted=a.muted,this.audioTrackId=a.audioTrackId,this.o=a.trackData,this.P=a.hasPrevious,this.hasNext=a.hasNext,this.F=a.playerTime,this.C=a.playerTimeAt,this.B=a.seekableStart,this.u=a.seekableEnd,this.G=a.duration,this.I=a.loadedTime,this.A=a.liveIngestionTime,this.w=!isNaN(this.A))};
g.h.eb=function(){return 1==this.playerState};
g.h.isAdPlaying=function(){return 1081==this.playerState};
g.h.getDuration=function(){return this.w?this.G+S7(this):this.G};
g.h.clone=function(){return new Q7(W7(this))};g.r(Y7,g.O);g.h=Y7.prototype;g.h.play=function(){1==this.o?(this.u?this.u.play(null,g.Ia,d8(this,"play")):c8(this,"play"),b8(this,1,U7(Z7(this))),this.S("remotePlayerChange")):$7(this,this.play)};
g.h.pause=function(){1==this.o?(this.u?this.u.pause(null,g.Ia,d8(this,"pause")):c8(this,"pause"),b8(this,2,U7(Z7(this))),this.S("remotePlayerChange")):$7(this,this.pause)};
g.h.seekTo=function(a){if(1==this.o){if(this.u){var b=Z7(this),c=new chrome.cast.media.SeekRequest;c.currentTime=a;b.eb()||3==b.playerState?c.resumeState=chrome.cast.media.ResumeState.PLAYBACK_START:c.resumeState=chrome.cast.media.ResumeState.PLAYBACK_PAUSE;this.u.seek(c,g.Ia,d8(this,"seekTo",{newTime:a}))}else c8(this,"seekTo",{newTime:a});b8(this,3,a);this.S("remotePlayerChange")}else $7(this,g.Qa(this.seekTo,a))};
g.h.stop=function(){if(1==this.o){this.u?this.u.stop(null,g.Ia,d8(this,"stopVideo")):c8(this,"stopVideo");var a=Z7(this);a.index=-1;a.videoId="";R7(a);a8(this,a);this.S("remotePlayerChange")}else $7(this,this.stop)};
g.h.setVolume=function(a,b){if(1==this.o){var c=Z7(this);if(this.w){if(c.volume!=a){var d=Math.round(a)/100;this.w.setReceiverVolumeLevel(d,(0,g.x)(function(){h7("CP","set receiver volume: "+d)},this),(0,g.x)(function(){this.Ub("failed to set receiver volume.")},this))}c.muted!=b&&this.w.setReceiverMuted(b,(0,g.x)(function(){h7("CP","set receiver muted: "+b)},this),(0,g.x)(function(){this.Ub("failed to set receiver muted.")},this))}else{var e={volume:a,
muted:b};-1!=c.volume&&(e.delta=a-c.volume);c8(this,"setVolume",e)}c.muted=b;c.volume=a;a8(this,c)}else $7(this,g.Qa(this.setVolume,a,b))};
g.h.eC=function(a,b){if(1==this.o){var c=Z7(this),d={videoId:a};b&&(c.o={trackName:b.name,languageCode:b.languageCode,sourceLanguageCode:b.translationLanguage?b.translationLanguage.languageCode:"",languageName:b.languageName,kind:b.kind},d.style=g.Jk(b.style),g.Sb(d,c.o));c8(this,"setSubtitlesTrack",d);a8(this,c)}else $7(this,g.Qa(this.eC,a,b))};
g.h.setAudioTrack=function(a,b){if(1==this.o){var c=b.getLanguageInfo().getId();c8(this,"setAudioTrack",{videoId:a,audioTrackId:c});var d=Z7(this);d.audioTrackId=c;a8(this,d)}else $7(this,g.Qa(this.setAudioTrack,a,b))};
g.h.playVideo=function(a,b,c,d,e,f,k){var l=Z7(this);c=c||0;var m={videoId:a,currentIndex:c};V7(l,a,c);void 0!==b&&(T7(l,b),m.currentTime=b);void 0!==d&&(m.listId=d);null!=e&&(m.playerParams=e);null!=f&&(m.clickTrackingParams=f);null!=k&&(m.locationInfo=g.Jk(k));c8(this,"setPlaylist",m);d||a8(this,l)};
g.h.YC=function(a,b){if(1==this.o){if(a&&b){var c=Z7(this);V7(c,a,b);a8(this,c)}c8(this,"previous")}else $7(this,g.Qa(this.YC,a,b))};
g.h.nextVideo=function(a,b){if(1==this.o){if(a&&b){var c=Z7(this);V7(c,a,b);a8(this,c)}c8(this,"next")}else $7(this,g.Qa(this.nextVideo,a,b))};
g.h.Nw=function(){1==this.o?c8(this,"dismissAutoplay"):$7(this,this.Nw)};
g.h.dispose=function(){if(3!=this.o){var a=this.o;this.o=3;this.S("proxyStateChange",a,this.o)}g.O.prototype.dispose.call(this)};
g.h.X=function(){bya(this);this.A=null;this.B.clear();X7(this,null);g.O.prototype.X.call(this)};
g.h.hv=function(a){if((a!=this.o||2==a)&&3!=this.o&&0!=a){var b=this.o;this.o=a;this.S("proxyStateChange",b,a);if(1==a)for(;!this.B.isEmpty();)b=a=this.B,g.ab(b.o)&&(b.o=b.u,b.o.reverse(),b.u=[]),a.o.pop().apply(this);else 3==a&&this.dispose()}};
g.h.wM=function(a,b){this.S(a,b)};
g.h.wK=function(a){if(!a)this.nm(null),X7(this,null);else if(this.w.receiver.volume){a=this.w.receiver.volume;var b=Z7(this),c=Math.round(100*a.level||0);if(b.volume!=c||b.muted!=a.muted)h7("CP","Cast volume update: "+a.level+(a.muted?" muted":"")),b.volume=c,b.muted=!!a.muted,a8(this,b)}};
g.h.nm=function(a){h7("CP","Cast media: "+!!a);this.u&&this.u.removeUpdateListener(this.G);if(this.u=a)this.u.addUpdateListener(this.G),cya(this),this.S("remotePlayerChange")};
g.h.vK=function(a){a?(cya(this),this.S("remotePlayerChange")):this.nm(null)};
g.h.HK=function(){var a=Zxa();a&&X7(this,a)};
g.h.Ub=function(a){h7("CP",a)};g.r(e8,g.O);g.h=e8.prototype;
g.h.connect=function(a,b){if(b){var c=b.listId,d=b.videoId,e=b.playerParams,f=b.clickTrackingParams,k=b.index,l={videoId:d},m=b.currentTime,n=b.locationInfo;void 0!==m&&(l.currentTime=5>=m?0:m);e&&(l.playerParams=e);n&&(l.locationInfo=n);f&&(l.clickTrackingParams=f);c&&(l.listId=c);void 0!==k&&(l.currentIndex=k);c&&(this.Va.listId=c);this.Va.videoId=d;this.Va.index=k||0;this.Va.state=3;T7(this.Va,m);this.A="UNSUPPORTED";f8("Connecting with setPlaylist and params: "+g.Jk(l));this.o.connect({method:"setPlaylist",
params:g.Jk(l)},a,pwa())}else f8("Connecting without params"),this.o.connect({},a,pwa());eya(this)};
g.h.dispose=function(){this.ea()||(this.S("beforeDispose"),g8(this,3));g.O.prototype.dispose.call(this)};
g.h.X=function(){h8(this);j8(this);i8(this);g.Jo(this.F);this.F=NaN;g.Jo(this.G);this.G=NaN;this.w=null;g.Fp(this.R);this.R.length=0;this.o.dispose();g.O.prototype.X.call(this);this.A=this.C=this.u=this.Va=this.o=null};
g.h.nF=function(){this.wj(2)};
g.h.AK=function(){f8("Channel opened");this.M&&(this.M=!1,i8(this),this.P=g.Ho((0,g.x)(function(){f8("Timing out waiting for a screen.");this.wj(1)},this),15E3));
twa(oxa(this.o),this.U)};
g.h.xK=function(){f8("Channel closed");isNaN(this.B)?p6(!0):p6();this.dispose()};
g.h.yK=function(a){p6();isNaN(this.xl())?(f8("Channel error: "+a+" without reconnection"),this.dispose()):(this.M=!0,f8("Channel error: "+a+" with reconnection in "+this.xl()+" ms"),g8(this,2))};
g.h.zK=function(a){a.params?f8("Received: action="+a.action+", params="+g.Jk(a.params)):f8("Received: action="+a.action+" {}");switch(a.action){case "loungeStatus":a=w6(a.params.devices);this.u=(0,g.Cc)(a,function(c){return new c6(c)});
a=!!g.Xa(this.u,function(c){return"LOUNGE_SCREEN"==c.type});
hya(this,a);break;case "loungeScreenDisconnected":g.eb(this.u,function(c){return"LOUNGE_SCREEN"==c.type});
hya(this,!1);break;case "remoteConnected":var b=new c6(w6(a.params.device));g.Xa(this.u,function(c){return b?c.id==b.id:!1})||$va(this.u,b);
break;case "remoteDisconnected":b=new c6(w6(a.params.device));g.eb(this.u,function(c){return b?c.id==b.id:!1});
break;case "gracefulDisconnect":break;case "playlistModified":jya(this,a);break;case "nowPlaying":lya(this,a);break;case "onStateChange":kya(this,a);break;case "onAdStateChange":mya(this,a);break;case "onVolumeChanged":nya(this,a);break;case "onSubtitlesTrackChanged":iya(this,a);break;case "nowAutoplaying":oya(this,a);break;case "autoplayDismissed":this.S("autoplayDismissed");break;case "autoplayUpNext":this.C=a.params.videoId||null;this.S("autoplayUpNext",this.C);break;case "onAutoplayModeChanged":this.A=
a.params.autoplayMode;this.S("autoplayModeChange",this.A);"DISABLED"==this.A&&this.S("autoplayDismissed");break;case "onHasPreviousNextChanged":pya(this,a);break;case "requestAssistedSignIn":this.S("assistedSignInRequested",a.params.authCode);break;default:f8("Unrecognized action: "+a.action)}};
g.h.mO=function(){if(this.w){var a=this.w;this.w=null;this.Va.videoId!=a&&k8(this,"getNowPlaying")}};
g.h.dF=function(){var a=3;this.ea()||(a=0,isNaN(this.xl())?c7(this.o)&&isNaN(this.B)&&(a=1):a=2);return a};
g.h.wj=function(a){f8("Disconnecting with "+a);h8(this);this.S("beforeDisconnect",a);1==a&&p6();pxa(this.o,a);this.dispose()};
g.h.cF=function(){var a=this.Va;this.w&&(a=this.Va.clone(),V7(a,this.w,a.index));return W7(a)};
g.h.zO=function(a){var b=new Q7(a);b.videoId&&b.videoId!=this.Va.videoId&&(this.w=b.videoId,g.Jo(this.F),this.F=g.Ho((0,g.x)(this.mO,this),5E3));var c=[];this.Va.listId==b.listId&&this.Va.videoId==b.videoId&&this.Va.index==b.index||c.push("remoteQueueChange");this.Va.playerState==b.playerState&&this.Va.volume==b.volume&&this.Va.muted==b.muted&&U7(this.Va)==U7(b)&&g.Jk(this.Va.o)==g.Jk(b.o)||c.push("remotePlayerChange");this.Va.reset(a);(0,g.y)(c,function(d){this.S(d)},this)};
g.h.Ax=function(){var a=this.o.C.id,b=g.Xa(this.u,function(c){return"REMOTE_CONTROL"==c.type&&c.id!=a});
return b?b.id:""};
g.h.xl=function(){var a=this.o;return a.u.isActive()?a.u.u-(0,g.H)():NaN};
g.h.RE=function(){return this.A||"UNSUPPORTED"};
g.h.SE=function(){return this.C||""};
g.h.rP=function(){if(!isNaN(this.xl())){var a=this.o.u;g.un(a.o);a.start()}};
g.h.uO=function(a,b){k8(this,a,b);gya(this)};
e8.prototype.subscribe=e8.prototype.subscribe;e8.prototype.unsubscribeByKey=e8.prototype.Eh;e8.prototype.getProxyState=e8.prototype.dF;e8.prototype.disconnect=e8.prototype.wj;e8.prototype.getPlayerContextData=e8.prototype.cF;e8.prototype.setPlayerContextData=e8.prototype.zO;e8.prototype.getOtherConnectedRemoteId=e8.prototype.Ax;e8.prototype.getReconnectTimeout=e8.prototype.xl;e8.prototype.getAutoplayMode=e8.prototype.RE;e8.prototype.getAutoplayVideoId=e8.prototype.SE;e8.prototype.reconnect=e8.prototype.rP;
e8.prototype.sendMessage=e8.prototype.uO;g.r(l8,l7);g.h=l8.prototype;g.h.he=function(a){return this.zd.$_gs(a)};
g.h.contains=function(a){return!!this.zd.$_c(a)};
g.h.get=function(a){return this.zd.$_g(a)};
g.h.start=function(){this.zd.$_st()};
g.h.add=function(a,b,c){this.zd.$_a(a,b,c)};
g.h.remove=function(a,b,c){this.zd.$_r(a,b,c)};
g.h.cq=function(a,b,c,d){this.zd.$_un(a,b,c,d)};
g.h.X=function(){for(var a=0,b=this.u.length;a<b;++a)this.zd.$_ubk(this.u[a]);this.u.length=0;this.zd=null;l7.prototype.X.call(this)};
g.h.vP=function(){this.S("screenChange")};
g.h.YL=function(){this.S("onlineScreenChange")};
u7.prototype.$_st=u7.prototype.start;u7.prototype.$_gspc=u7.prototype.wP;u7.prototype.$_gsppc=u7.prototype.bD;u7.prototype.$_c=u7.prototype.contains;u7.prototype.$_g=u7.prototype.get;u7.prototype.$_a=u7.prototype.add;u7.prototype.$_un=u7.prototype.cq;u7.prototype.$_r=u7.prototype.remove;u7.prototype.$_gs=u7.prototype.he;u7.prototype.$_gos=u7.prototype.aD;u7.prototype.$_s=u7.prototype.subscribe;u7.prototype.$_ubk=u7.prototype.Eh;var E8=null,D8=!1,m8=null,n8=null,C8=null,r8=[];g.r(F8,g.A);g.h=F8.prototype;
g.h.X=function(){g.A.prototype.X.call(this);this.A.stop();this.C.stop();this.M.stop();this.V();this.o.unsubscribe("proxyStateChange",this.YA,this);this.o.unsubscribe("remotePlayerChange",this.sm,this);this.o.unsubscribe("remoteQueueChange",this.rp,this);this.o.unsubscribe("autoplayUpNext",this.oA,this);this.o.unsubscribe("previousNextChange",this.UA,this);this.o.unsubscribe("nowAutoplaying",this.PA,this);this.o.unsubscribe("autoplayDismissed",this.nA,this);this.o=this.B=null};
g.h.Az=function(a,b){for(var c=[],d=1;d<arguments.length;++d)c[d-1]=arguments[d];if(2!=this.o.o)if(I8(this)){if(!Z7(this.o).isAdPlaying()||"control_seek"!=a)switch(a){case "control_toggle_play_pause":Z7(this.o).eb()?this.o.pause():this.o.play();break;case "control_play":this.o.play();break;case "control_pause":this.o.pause();break;case "control_seek":this.P.Jx(c[0],c[1]);break;case "control_subtitles_set_track":J8(this,c[0]);break;case "control_set_audio_track":c=c[0],I8(this)&&this.o.setAudioTrack(this.u.getVideoData(1).videoId,
c)}}else switch(a){case "control_toggle_play_pause":case "control_play":case "control_pause":c=this.u.getCurrentTime();K8(this,0==c?void 0:c);break;case "control_seek":K8(this,c[0]);break;case "control_subtitles_set_track":J8(this,c[0]);break;case "control_set_audio_track":c=c[0],I8(this)&&this.o.setAudioTrack(this.u.getVideoData(1).videoId,c)}};
g.h.uK=function(a){this.M.jF(a)};
g.h.WO=function(a){this.Az("control_subtitles_set_track",g.Mb(a)?null:a)};
g.h.oC=function(){var a=this.u.getOption("captions","track");g.Mb(a)||J8(this,a)};
g.h.DA=function(a){if(I8(this)){this.o.unsubscribe("remotePlayerChange",this.sm,this);var b=Math.round(a.volume);a=!!a.muted;var c=Z7(this.o);if(b!=c.volume||a!=c.muted)this.o.setVolume(b,a),this.R.start();this.o.subscribe("remotePlayerChange",this.sm,this)}};
g.h.uL=function(){g.Mb(this.F)||Bya(this,this.F);this.G=!1};
g.h.YA=function(a,b){this.C.stop();2==b&&this.nC()};
g.h.sm=function(){if(I8(this)){this.A.stop();var a=Z7(this.o);switch(a.playerState){case 1080:case 1081:case 1084:case 1085:this.B.M=1;break;case 1082:case 1083:this.B.M=0;break;default:this.B.M=-1}switch(a.playerState){case 1081:case 1:H8(this,new g.HC(8));this.mC();break;case 1085:case 3:H8(this,new g.HC(9));break;case 1083:case 0:H8(this,new g.HC(2));this.P.stop();G8(this,this.u.getVideoData().lengthSeconds);break;case 1084:H8(this,new g.HC(4));break;case 2:H8(this,new g.HC(4));G8(this,U7(a));
break;case -1:H8(this,new g.HC(64));break;case -1E3:H8(this,new g.HC(128,{errorCode:"mdx.remoteerror",errorMessage:"Cette vid\u00e9o ne peut pas \u00eatre visionn\u00e9e \u00e0 distance."}))}a=Z7(this.o).o;var b=this.F;(a||b?a&&b&&a.trackName==b.trackName&&a.languageCode==b.languageCode&&a.languageName==b.languageName&&a.kind==b.kind:1)||(this.F=a,Bya(this,a));a=Z7(this.o);-1==a.volume||Math.round(this.u.getVolume())==a.volume&&this.u.isMuted()==a.muted||this.R.isActive()||this.NC()}else Aya(this)};
g.h.UA=function(){this.u.S("mdxpreviousnextchange")};
g.h.rp=function(){I8(this)||Aya(this)};
g.h.dE=function(){this.o.Nw()};
g.h.oA=function(){};
g.h.PA=function(a){isNaN(a)||this.u.S("mdxnowautoplaying",a)};
g.h.nA=function(){this.u.S("mdxautoplaycanceled")};
g.h.FI=function(a,b){-1==Z7(this.o).playerState?K8(this,a):b&&this.o.seekTo(a)};
g.h.NC=function(){if(I8(this)){var a=Z7(this.o);this.w.bb(this.U);a.muted?this.u.mute():this.u.unMute();this.u.setVolume(a.volume);this.U=this.w.L(this.u,"onVolumeChange",this.DA)}};
g.h.mC=function(){this.A.stop();if(!this.o.ea()){var a=Z7(this.o);a.eb()&&H8(this,new g.HC(8));G8(this,U7(a));this.A.start()}};
g.h.nC=function(){this.C.stop();this.A.stop();var a=this.o.A.getReconnectTimeout();2==this.o.o&&!isNaN(a)&&this.C.start()};g.r(L8,g.R);L8.prototype.A=function(a){Dya(this,a.state)};g.r(M8,g.R);M8.prototype.Qb=function(){this.u.show()};
M8.prototype.w=function(){g.GN("https://support.google.com/youtube/answer/7640706")};
M8.prototype.A=function(){b6("mdx-manual-pairing-popup-ok");this.u.hide()};g.r(N8,g.R);N8.prototype.Qb=function(){this.u.show()};
N8.prototype.w=function(){b6("mdx-privacy-popup-cancel");this.u.hide()};
N8.prototype.A=function(){b6("mdx-privacy-popup-confirm");this.u.hide()};g.r(O8,g.iO);O8.prototype.G=function(){var a=this.K.getOption("remote","receivers");a&&1<a.length&&!this.K.getOption("remote","quickCast")?(this.C=g.vb(a,this.w,this),g.kO(this,(0,g.Cc)(a,this.w)),a=this.K.getOption("remote","currentReceiver"),this.Db(this.w(a)),this.enable(!0)):this.enable(!1)};
O8.prototype.w=function(a){return a.key};
O8.prototype.Ze=function(a){return"cast-selector-receiver"===a?"Caster sur\u2026":this.C[a].name};
O8.prototype.fd=function(a){g.iO.prototype.fd.call(this,a);this.K.setOption("remote","currentReceiver",this.C[a]);this.u.gb()};g.r(P8,g.vL);g.h=P8.prototype;
g.h.create=function(){uya(g.Ry(this.player.N()));this.w.push(g.Oo("yt-remote-before-disconnect",this.rK,this));this.w.push(g.Oo("yt-remote-connection-change",this.EM,this));this.w.push(g.Oo("yt-remote-receiver-availability-change",this.WA,this));this.w.push(g.Oo("yt-remote-auto-connect",this.CM,this));this.w.push(g.Oo("yt-remote-receiver-resumed",this.BM,this));this.w.push(g.Oo("mdx-privacy-popup-confirm",this.YN,this));this.w.push(g.Oo("mdx-privacy-popup-cancel",this.XN,this));this.w.push(g.Oo("mdx-manual-pairing-popup-ok",
this.tG,this));this.WA()};
g.h.load=function(){this.player.cancelPlayback();g.vL.prototype.load.call(this);this.C=new F8(this,this.player,this.o);var a=(a=zya())?a.currentTime:0;var b=B8()?new Y7(w8(),void 0):null;0==a&&b&&(a=U7(Z7(b)));0!=a&&(this.V=a||0,this.player.S("progresssync",a,void 0));Cya(this,this.I,this.I);g.$S(this.player.app,6)};
g.h.unload=function(){this.player.S("mdxautoplaycanceled");this.A=this.u;g.Ie(this.C,this.o);this.o=this.C=null;g.vL.prototype.unload.call(this);g.$S(this.player.app,5);Q8(this)};
g.h.X=function(){g.Po(this.w);g.vL.prototype.X.call(this)};
g.h.Wl=function(a,b){for(var c=[],d=1;d<arguments.length;++d)c[d-1]=arguments[d];this.loaded&&this.C.Az.apply(this.C,[a].concat(g.ea(c)))};
g.h.getAdState=function(){return this.M};
g.h.fF=function(){return this.loaded?this.C.suggestion:null};
g.h.Qy=function(){return this.o?Z7(this.o).P:!1};
g.h.hasNext=function(){return this.o?Z7(this.o).hasNext:!1};
g.h.getCurrentTime=function(){return this.V};
g.h.getProgressState=function(){var a=Z7(this.o),b=this.player.getVideoData();return{allowSeeking:g.P(this.player.N().experiments,"web_player_mdx_allow_seeking_change_killswitch")?this.player.Qc():!a.isAdPlaying()&&this.player.Qc(),clipEnd:b.clipEnd,clipStart:b.clipStart,current:this.getCurrentTime(),displayedStart:-1,duration:a.getDuration(),ingestionTime:a.w?a.A+S7(a):a.A,isAtLiveHead:1>=(a.w?a.u+S7(a):a.u)-this.getCurrentTime(),loaded:a.I,seekableEnd:a.w?a.u+S7(a):a.u,seekableStart:0<a.B?a.B+S7(a):
a.B}};
g.h.nextVideo=function(){this.o&&this.o.nextVideo()};
g.h.BG=function(){this.o&&this.o.YC()};
g.h.rK=function(a){1==a&&(this.ba=this.o?Z7(this.o):null)};
g.h.EM=function(){var a=B8()?new Y7(w8(),void 0):null;if(a){var b=this.A;this.loaded&&this.unload();this.o=a;this.ba=null;b.key!=this.u.key&&(this.A=b,this.load())}else g.He(this.o),this.o=null,this.loaded&&(this.unload(),(a=this.ba)&&a.videoId==this.player.getVideoData().videoId&&this.player.cueVideoById(a.videoId,U7(a)));this.player.S("videodatachange","newdata",this.player.getVideoData(),3)};
g.h.WA=function(){this.U=[this.u].concat(wya());var a=x8()||this.u;R8(this,a);this.player.na("onMdxReceiversChange")};
g.h.CM=function(){var a=x8();R8(this,a)};
g.h.BM=function(){this.A=x8()};
g.h.YN=function(){this.P=!0;Q8(this);D8=!1;E8&&z8(E8,1);E8=null};
g.h.XN=function(){this.P=!1;Q8(this);R8(this,this.u);this.A=this.u;D8=!1;E8=null;this.player.playVideo()};
g.h.tG=function(){this.R=!0;Q8(this);g.Ds("yt-remote-manual-pairing-warning-shown",!0,2592E3);D8=!1;E8&&z8(E8,1);E8=null};
g.h.Oc=function(a,b){switch(a){case "casting":return this.loaded;case "receivers":return this.U;case "currentReceiver":return b&&("cast-selector-receiver"==b.key?O7():R8(this,b)),this.loaded?this.A:this.u;case "quickCast":return 2==this.U.length&&"cast-selector-receiver"==this.U[1].key?(b&&O7(),!0):!1}};
g.h.CG=function(){c8(this.o,"sendDebugCommand",{debugCommand:"stats4nerds "})};
g.h.Pf=function(){return!1};
g.h.getOptions=function(){return["casting","receivers","currentReceiver","quickCast"]};g.KL.remote=P8;})(_yt_player);

View File

@ -0,0 +1,723 @@
(function(){/*
Copyright The Closure Library Authors.
SPDX-License-Identifier: Apache-2.0
*/
var m;function aa(a){var b=0;return function(){return b<a.length?{done:!1,value:a[b++]}:{done:!0}}}
function p(a){var b="undefined"!=typeof Symbol&&Symbol.iterator&&a[Symbol.iterator];return b?b.call(a):{next:aa(a)}}
function ba(a){for(var b,c=[];!(b=a.next()).done;)c.push(b.value);return c}
var ca="function"==typeof Object.create?Object.create:function(a){function b(){}
b.prototype=a;return new b},da;
if("function"==typeof Object.setPrototypeOf)da=Object.setPrototypeOf;else{var ea;a:{var fa={a:!0},ha={};try{ha.__proto__=fa;ea=ha.a;break a}catch(a){}ea=!1}da=ea?function(a,b){a.__proto__=b;if(a.__proto__!==b)throw new TypeError(a+" is not extensible");return a}:null}var ia=da;
function q(a,b){a.prototype=ca(b.prototype);a.prototype.constructor=a;if(ia)ia(a,b);else for(var c in b)if("prototype"!=c)if(Object.defineProperties){var d=Object.getOwnPropertyDescriptor(b,c);d&&Object.defineProperty(a,c,d)}else a[c]=b[c];a.L=b.prototype}
var ka="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(a==Array.prototype||a==Object.prototype)return a;a[b]=c.value;return a};
function la(a){a=["object"==typeof globalThis&&globalThis,a,"object"==typeof window&&window,"object"==typeof self&&self,"object"==typeof global&&global];for(var b=0;b<a.length;++b){var c=a[b];if(c&&c.Math==Math)return c}throw Error("Cannot find global object");}
var ma=la(this);function u(a,b){if(b){for(var c=ma,d=a.split("."),e=0;e<d.length-1;e++){var f=d[e];f in c||(c[f]={});c=c[f]}d=d[d.length-1];e=c[d];f=b(e);f!=e&&null!=f&&ka(c,d,{configurable:!0,writable:!0,value:f})}}
function na(a,b,c){if(null==a)throw new TypeError("The 'this' value for String.prototype."+c+" must not be null or undefined");if(b instanceof RegExp)throw new TypeError("First argument to String.prototype."+c+" must not be a regular expression");return a+""}
u("String.prototype.endsWith",function(a){return a?a:function(b,c){var d=na(this,b,"endsWith");b+="";void 0===c&&(c=d.length);for(var e=Math.max(0,Math.min(c|0,d.length)),f=b.length;0<f&&0<e;)if(d[--e]!=b[--f])return!1;return 0>=f}});
u("String.prototype.startsWith",function(a){return a?a:function(b,c){var d=na(this,b,"startsWith");b+="";for(var e=d.length,f=b.length,h=Math.max(0,Math.min(c|0,d.length)),g=0;g<f&&h<e;)if(d[h++]!=b[g++])return!1;return g>=f}});
u("Symbol",function(a){function b(e){if(this instanceof b)throw new TypeError("Symbol is not a constructor");return new c("jscomp_symbol_"+(e||"")+"_"+d++,e)}
function c(e,f){this.f=e;ka(this,"description",{configurable:!0,writable:!0,value:f})}
if(a)return a;c.prototype.toString=function(){return this.f};
var d=0;return b});
function oa(){oa=function(){};
var a=Symbol.iterator;a||(a=Symbol.iterator=Symbol("Symbol.iterator"));"function"!=typeof Array.prototype[a]&&ka(Array.prototype,a,{configurable:!0,writable:!0,value:function(){return pa(aa(this))}})}
function pa(a){oa();a={next:a};a[Symbol.iterator]=function(){return this};
return a}
function v(a,b){return Object.prototype.hasOwnProperty.call(a,b)}
var qa="function"==typeof Object.assign?Object.assign:function(a,b){for(var c=1;c<arguments.length;c++){var d=arguments[c];if(d)for(var e in d)v(d,e)&&(a[e]=d[e])}return a};
u("Object.assign",function(a){return a||qa});
u("WeakMap",function(a){function b(k){this.f=(g+=Math.random()+1).toString();if(k){k=p(k);for(var l;!(l=k.next()).done;)l=l.value,this.set(l[0],l[1])}}
function c(){}
function d(k){var l=typeof k;return"object"===l&&null!==k||"function"===l}
function e(k){if(!v(k,h)){var l=new c;ka(k,h,{value:l})}}
function f(k){var l=Object[k];l&&(Object[k]=function(n){if(n instanceof c)return n;e(n);return l(n)})}
if(function(){if(!a||!Object.seal)return!1;try{var k=Object.seal({}),l=Object.seal({}),n=new a([[k,2],[l,3]]);if(2!=n.get(k)||3!=n.get(l))return!1;n["delete"](k);n.set(l,4);return!n.has(k)&&4==n.get(l)}catch(r){return!1}}())return a;
var h="$jscomp_hidden_"+Math.random();f("freeze");f("preventExtensions");f("seal");var g=0;b.prototype.set=function(k,l){if(!d(k))throw Error("Invalid WeakMap key");e(k);if(!v(k,h))throw Error("WeakMap key fail: "+k);k[h][this.f]=l;return this};
b.prototype.get=function(k){return d(k)&&v(k,h)?k[h][this.f]:void 0};
b.prototype.has=function(k){return d(k)&&v(k,h)&&v(k[h],this.f)};
b.prototype["delete"]=function(k){return d(k)&&v(k,h)&&v(k[h],this.f)?delete k[h][this.f]:!1};
return b});
u("Map",function(a){function b(){var g={};return g.previous=g.next=g.head=g}
function c(g,k){var l=g.f;return pa(function(){if(l){for(;l.head!=g.f;)l=l.previous;for(;l.next!=l.head;)return l=l.next,{done:!1,value:k(l)};l=null}return{done:!0,value:void 0}})}
function d(g,k){var l=k&&typeof k;"object"==l||"function"==l?f.has(k)?l=f.get(k):(l=""+ ++h,f.set(k,l)):l="p_"+k;var n=g.g[l];if(n&&v(g.g,l))for(var r=0;r<n.length;r++){var w=n[r];if(k!==k&&w.key!==w.key||k===w.key)return{id:l,list:n,index:r,u:w}}return{id:l,list:n,index:-1,u:void 0}}
function e(g){this.g={};this.f=b();this.size=0;if(g){g=p(g);for(var k;!(k=g.next()).done;)k=k.value,this.set(k[0],k[1])}}
if(function(){if(!a||"function"!=typeof a||!a.prototype.entries||"function"!=typeof Object.seal)return!1;try{var g=Object.seal({x:4}),k=new a(p([[g,"s"]]));if("s"!=k.get(g)||1!=k.size||k.get({x:4})||k.set({x:4},"t")!=k||2!=k.size)return!1;var l=k.entries(),n=l.next();if(n.done||n.value[0]!=g||"s"!=n.value[1])return!1;n=l.next();return n.done||4!=n.value[0].x||"t"!=n.value[1]||!l.next().done?!1:!0}catch(r){return!1}}())return a;
oa();var f=new WeakMap;e.prototype.set=function(g,k){g=0===g?0:g;var l=d(this,g);l.list||(l.list=this.g[l.id]=[]);l.u?l.u.value=k:(l.u={next:this.f,previous:this.f.previous,head:this.f,key:g,value:k},l.list.push(l.u),this.f.previous.next=l.u,this.f.previous=l.u,this.size++);return this};
e.prototype["delete"]=function(g){g=d(this,g);return g.u&&g.list?(g.list.splice(g.index,1),g.list.length||delete this.g[g.id],g.u.previous.next=g.u.next,g.u.next.previous=g.u.previous,g.u.head=null,this.size--,!0):!1};
e.prototype.clear=function(){this.g={};this.f=this.f.previous=b();this.size=0};
e.prototype.has=function(g){return!!d(this,g).u};
e.prototype.get=function(g){return(g=d(this,g).u)&&g.value};
e.prototype.entries=function(){return c(this,function(g){return[g.key,g.value]})};
e.prototype.keys=function(){return c(this,function(g){return g.key})};
e.prototype.values=function(){return c(this,function(g){return g.value})};
e.prototype.forEach=function(g,k){for(var l=this.entries(),n;!(n=l.next()).done;)n=n.value,g.call(k,n[1],n[0],this)};
e.prototype[Symbol.iterator]=e.prototype.entries;var h=0;return e});
u("Object.entries",function(a){return a?a:function(b){var c=[],d;for(d in b)v(b,d)&&c.push([d,b[d]]);return c}});
u("Set",function(a){function b(c){this.f=new Map;if(c){c=p(c);for(var d;!(d=c.next()).done;)this.add(d.value)}this.size=this.f.size}
if(function(){if(!a||"function"!=typeof a||!a.prototype.entries||"function"!=typeof Object.seal)return!1;try{var c=Object.seal({x:4}),d=new a(p([c]));if(!d.has(c)||1!=d.size||d.add(c)!=d||1!=d.size||d.add({x:4})!=d||2!=d.size)return!1;var e=d.entries(),f=e.next();if(f.done||f.value[0]!=c||f.value[1]!=c)return!1;f=e.next();return f.done||f.value[0]==c||4!=f.value[0].x||f.value[1]!=f.value[0]?!1:e.next().done}catch(h){return!1}}())return a;
oa();b.prototype.add=function(c){c=0===c?0:c;this.f.set(c,c);this.size=this.f.size;return this};
b.prototype["delete"]=function(c){c=this.f["delete"](c);this.size=this.f.size;return c};
b.prototype.clear=function(){this.f.clear();this.size=0};
b.prototype.has=function(c){return this.f.has(c)};
b.prototype.entries=function(){return this.f.entries()};
b.prototype.values=function(){return this.f.values()};
b.prototype.keys=b.prototype.values;b.prototype[Symbol.iterator]=b.prototype.values;b.prototype.forEach=function(c,d){var e=this;this.f.forEach(function(f){return c.call(d,f,f,e)})};
return b});
u("String.prototype.includes",function(a){return a?a:function(b,c){return-1!==na(this,b,"includes").indexOf(b,c||0)}});
var ra=function(){function a(){function c(){}
new c;Reflect.construct(c,[],function(){});
return new c instanceof c}
if("undefined"!=typeof Reflect&&Reflect.construct){if(a())return Reflect.construct;var b=Reflect.construct;return function(c,d,e){c=b(c,d);e&&Reflect.setPrototypeOf(c,e.prototype);return c}}return function(c,d,e){void 0===e&&(e=c);
e=ca(e.prototype||Object.prototype);return Function.prototype.apply.call(c,e,d)||e}}();
u("Reflect.construct",function(){return ra});
var x=this||self;function y(a,b,c){a=a.split(".");c=c||x;a[0]in c||"undefined"==typeof c.execScript||c.execScript("var "+a[0]);for(var d;a.length&&(d=a.shift());)a.length||void 0===b?c[d]&&c[d]!==Object.prototype[d]?c=c[d]:c=c[d]={}:c[d]=b}
var sa=/^[\w+/_-]+[=]{0,2}$/,ta=null;function ua(a){return(a=a.querySelector&&a.querySelector("script[nonce]"))&&(a=a.nonce||a.getAttribute("nonce"))&&sa.test(a)?a:""}
function z(a,b){for(var c=a.split("."),d=b||x,e=0;e<c.length;e++)if(d=d[c[e]],null==d)return null;return d}
function va(){}
function wa(a){a.ha=void 0;a.getInstance=function(){return a.ha?a.ha:a.ha=new a}}
function xa(a){var b=typeof a;if("object"==b)if(a){if(a instanceof Array)return"array";if(a instanceof Object)return b;var c=Object.prototype.toString.call(a);if("[object Window]"==c)return"object";if("[object Array]"==c||"number"==typeof a.length&&"undefined"!=typeof a.splice&&"undefined"!=typeof a.propertyIsEnumerable&&!a.propertyIsEnumerable("splice"))return"array";if("[object Function]"==c||"undefined"!=typeof a.call&&"undefined"!=typeof a.propertyIsEnumerable&&!a.propertyIsEnumerable("call"))return"function"}else return"null";
else if("function"==b&&"undefined"==typeof a.call)return"object";return b}
function ya(a){var b=xa(a);return"array"==b||"object"==b&&"number"==typeof a.length}
function A(a){return"function"==xa(a)}
function za(a){var b=typeof a;return"object"==b&&null!=a||"function"==b}
function Aa(a){return Object.prototype.hasOwnProperty.call(a,Ba)&&a[Ba]||(a[Ba]=++Ca)}
var Ba="closure_uid_"+(1E9*Math.random()>>>0),Ca=0;function Da(a,b,c){return a.call.apply(a.bind,arguments)}
function Ea(a,b,c){if(!a)throw Error();if(2<arguments.length){var d=Array.prototype.slice.call(arguments,2);return function(){var e=Array.prototype.slice.call(arguments);Array.prototype.unshift.apply(e,d);return a.apply(b,e)}}return function(){return a.apply(b,arguments)}}
function B(a,b,c){Function.prototype.bind&&-1!=Function.prototype.bind.toString().indexOf("native code")?B=Da:B=Ea;return B.apply(null,arguments)}
function Fa(a,b){var c=Array.prototype.slice.call(arguments,1);return function(){var d=c.slice();d.push.apply(d,arguments);return a.apply(this,d)}}
var C=Date.now||function(){return+new Date};
function Ga(a,b){y(a,b,void 0)}
function D(a,b){function c(){}
c.prototype=b.prototype;a.L=b.prototype;a.prototype=new c;a.prototype.constructor=a}
;function Ha(a,b){if(!a||/[?&]dsh=1(&|$)/.test(a))return null;if(/[?&]ae=1(&|$)/.test(a)){var c=/[?&]adurl=([^&]+)/.exec(a);if(!c)return null;var d=b?c.index:a.length;try{return{wa:a.slice(0,d)+"&act=1"+a.slice(d),ya:decodeURIComponent(c[1])}}catch(f){return null}}if(/[?&]ae=2(&|$)/.test(a)){c=a;d="";if(b){var e=a.indexOf("&adurl=");0<e&&(c=a.slice(0,e),d=a.slice(e))}return{wa:c+"&act=1"+d,ya:c+"&dct=1"+d}}return null}
;function E(a){if(Error.captureStackTrace)Error.captureStackTrace(this,E);else{var b=Error().stack;b&&(this.stack=b)}a&&(this.message=String(a))}
D(E,Error);E.prototype.name="CustomError";function Ja(a){var b=a.url,c=a.ub;this.j=!!a.ab;this.g=Ha(b,c);a=/[?&]dsh=1(&|$)/.test(b);this.h=!a&&/[?&]ae=1(&|$)/.test(b);this.i=!a&&/[?&]ae=2(&|$)/.test(b);this.f=/[?&]adurl=([^&]*)/.exec(b)}
;var Ka=Array.prototype.indexOf?function(a,b){return Array.prototype.indexOf.call(a,b,void 0)}:function(a,b){if("string"===typeof a)return"string"!==typeof b||1!=b.length?-1:a.indexOf(b,0);
for(var c=0;c<a.length;c++)if(c in a&&a[c]===b)return c;return-1},F=Array.prototype.forEach?function(a,b,c){Array.prototype.forEach.call(a,b,c)}:function(a,b,c){for(var d=a.length,e="string"===typeof a?a.split(""):a,f=0;f<d;f++)f in e&&b.call(c,e[f],f,a)},La=Array.prototype.filter?function(a,b){return Array.prototype.filter.call(a,b,void 0)}:function(a,b){for(var c=a.length,d=[],e=0,f="string"===typeof a?a.split(""):a,h=0;h<c;h++)if(h in f){var g=f[h];
b.call(void 0,g,h,a)&&(d[e++]=g)}return d},Ma=Array.prototype.map?function(a,b){return Array.prototype.map.call(a,b,void 0)}:function(a,b){for(var c=a.length,d=Array(c),e="string"===typeof a?a.split(""):a,f=0;f<c;f++)f in e&&(d[f]=b.call(void 0,e[f],f,a));
return d},Na=Array.prototype.reduce?function(a,b,c){return Array.prototype.reduce.call(a,b,c)}:function(a,b,c){var d=c;
F(a,function(e,f){d=b.call(void 0,d,e,f,a)});
return d};
function Oa(a,b){a:{var c=a.length;for(var d="string"===typeof a?a.split(""):a,e=0;e<c;e++)if(e in d&&b.call(void 0,d[e],e,a)){c=e;break a}c=-1}return 0>c?null:"string"===typeof a?a.charAt(c):a[c]}
function Pa(a,b){var c=Ka(a,b);0<=c&&Array.prototype.splice.call(a,c,1)}
function Qa(a){var b=a.length;if(0<b){for(var c=Array(b),d=0;d<b;d++)c[d]=a[d];return c}return[]}
function Ra(a,b){for(var c=1;c<arguments.length;c++){var d=arguments[c];if(ya(d)){var e=a.length||0,f=d.length||0;a.length=e+f;for(var h=0;h<f;h++)a[e+h]=d[h]}else a.push(d)}}
;function Sa(a){var b=!1,c;return function(){b||(c=a(),b=!0);return c}}
;function Ta(a,b){for(var c in a)b.call(void 0,a[c],c,a)}
function Ua(a,b){var c=ya(b),d=c?b:arguments;for(c=c?0:1;c<d.length;c++){if(null==a)return;a=a[d[c]]}return a}
function Va(a){var b=Wa,c;for(c in b)if(a.call(void 0,b[c],c,b))return c}
function Xa(a){for(var b in a)return!1;return!0}
function Ya(a,b){if(null!==a&&b in a)throw Error('The object already contains the key "'+b+'"');a[b]=!0}
function Za(a,b){for(var c in a)if(!(c in b)||a[c]!==b[c])return!1;for(var d in b)if(!(d in a))return!1;return!0}
function $a(a){var b={},c;for(c in a)b[c]=a[c];return b}
function ab(a){var b=xa(a);if("object"==b||"array"==b){if(A(a.clone))return a.clone();b="array"==b?[]:{};for(var c in a)b[c]=ab(a[c]);return b}return a}
var bb="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" ");function cb(a,b){for(var c,d,e=1;e<arguments.length;e++){d=arguments[e];for(c in d)a[c]=d[c];for(var f=0;f<bb.length;f++)c=bb[f],Object.prototype.hasOwnProperty.call(d,c)&&(a[c]=d[c])}}
;function db(a,b){this.f=a===eb&&b||"";this.g=fb}
db.prototype.K=!0;db.prototype.J=function(){return this.f.toString()};
db.prototype.ga=!0;db.prototype.da=function(){return 1};
function gb(a){if(a instanceof db&&a.constructor===db&&a.g===fb)return a.f;xa(a);return"type_error:TrustedResourceUrl"}
var fb={},eb={};var hb=String.prototype.trim?function(a){return a.trim()}:function(a){return/^[\s\xa0]*([\s\S]*?)[\s\xa0]*$/.exec(a)[1]};
function ib(a,b){if(b)a=a.replace(jb,"&amp;").replace(kb,"&lt;").replace(lb,"&gt;").replace(mb,"&quot;").replace(nb,"&#39;").replace(ob,"&#0;");else{if(!pb.test(a))return a;-1!=a.indexOf("&")&&(a=a.replace(jb,"&amp;"));-1!=a.indexOf("<")&&(a=a.replace(kb,"&lt;"));-1!=a.indexOf(">")&&(a=a.replace(lb,"&gt;"));-1!=a.indexOf('"')&&(a=a.replace(mb,"&quot;"));-1!=a.indexOf("'")&&(a=a.replace(nb,"&#39;"));-1!=a.indexOf("\x00")&&(a=a.replace(ob,"&#0;"))}return a}
var jb=/&/g,kb=/</g,lb=/>/g,mb=/"/g,nb=/'/g,ob=/\x00/g,pb=/[\x00&<>"']/;function H(a,b){this.f=a===qb&&b||"";this.g=rb}
H.prototype.K=!0;H.prototype.J=function(){return this.f.toString()};
H.prototype.ga=!0;H.prototype.da=function(){return 1};
function sb(a){if(a instanceof H&&a.constructor===H&&a.g===rb)return a.f;xa(a);return"type_error:SafeUrl"}
var tb=/^(?:(?:https?|mailto|ftp):|[^:/?#]*(?:[/?#]|$))/i;function ub(a){if(a instanceof H)return a;a="object"==typeof a&&a.K?a.J():String(a);tb.test(a)||(a="about:invalid#zClosurez");return new H(qb,a)}
var rb={},qb={};var vb;a:{var wb=x.navigator;if(wb){var xb=wb.userAgent;if(xb){vb=xb;break a}}vb=""}function I(a){return-1!=vb.indexOf(a)}
;function yb(){this.f="";this.h=zb;this.g=null}
yb.prototype.ga=!0;yb.prototype.da=function(){return this.g};
yb.prototype.K=!0;yb.prototype.J=function(){return this.f.toString()};
var zb={};function Ab(a,b){var c=new yb;c.f=a;c.g=b;return c}
;function Bb(a,b){var c=b instanceof H?b:ub(b);a.href=sb(c)}
function Cb(a,b){a.src=gb(b);var c;(c=a.ownerDocument&&a.ownerDocument.defaultView)&&c!=x?c=ua(c.document):(null===ta&&(ta=ua(x.document)),c=ta);c&&a.setAttribute("nonce",c)}
;function Db(a){return a=ib(a,void 0)}
function Eb(a){for(var b=0,c=0;c<a.length;++c)b=31*b+a.charCodeAt(c)>>>0;return b}
;var Gb=/^(?:([^:/?#.]+):)?(?:\/\/(?:([^\\/?#]*)@)?([^\\/?#]*?)(?::([0-9]+))?(?=[\\/?#]|$))?([^?#]+)?(?:\?([^#]*))?(?:#([\s\S]*))?$/;function J(a){return a?decodeURI(a):a}
function K(a,b){return b.match(Gb)[a]||null}
function Hb(a,b,c){if(Array.isArray(b))for(var d=0;d<b.length;d++)Hb(a,String(b[d]),c);else null!=b&&c.push(a+(""===b?"":"="+encodeURIComponent(String(b))))}
function Ib(a){var b=[],c;for(c in a)Hb(c,a[c],b);return b.join("&")}
function Jb(a,b){var c=Ib(b);if(c){var d=a.indexOf("#");0>d&&(d=a.length);var e=a.indexOf("?");if(0>e||e>d){e=d;var f=""}else f=a.substring(e+1,d);d=[a.substr(0,e),f,a.substr(d)];e=d[1];d[1]=c?e?e+"&"+c:c:e;c=d[0]+(d[1]?"?"+d[1]:"")+d[2]}else c=a;return c}
var Kb=/#|$/;function Lb(a,b){var c=a.search(Kb);a:{var d=0;for(var e=b.length;0<=(d=a.indexOf(b,d))&&d<c;){var f=a.charCodeAt(d-1);if(38==f||63==f)if(f=a.charCodeAt(d+e),!f||61==f||38==f||35==f)break a;d+=e+1}d=-1}if(0>d)return null;e=a.indexOf("&",d);if(0>e||e>c)e=c;d+=b.length+1;return decodeURIComponent(a.substr(d,e-d).replace(/\+/g," "))}
;var Mb=I("Opera"),Nb=I("Trident")||I("MSIE"),Ob=I("Edge"),Pb=I("Gecko")&&!(-1!=vb.toLowerCase().indexOf("webkit")&&!I("Edge"))&&!(I("Trident")||I("MSIE"))&&!I("Edge"),Qb=-1!=vb.toLowerCase().indexOf("webkit")&&!I("Edge");function Rb(){var a=x.document;return a?a.documentMode:void 0}
var Sb;a:{var Tb="",Ub=function(){var a=vb;if(Pb)return/rv:([^\);]+)(\)|;)/.exec(a);if(Ob)return/Edge\/([\d\.]+)/.exec(a);if(Nb)return/\b(?:MSIE|rv)[: ]([^\);]+)(\)|;)/.exec(a);if(Qb)return/WebKit\/(\S+)/.exec(a);if(Mb)return/(?:Version)[ \/]?(\S+)/.exec(a)}();
Ub&&(Tb=Ub?Ub[1]:"");if(Nb){var Vb=Rb();if(null!=Vb&&Vb>parseFloat(Tb)){Sb=String(Vb);break a}}Sb=Tb}var Wb=Sb,Xb;if(x.document&&Nb){var Yb=Rb();Xb=Yb?Yb:parseInt(Wb,10)||void 0}else Xb=void 0;var Zb=Xb;var $b={},ac=null;var L=window;function bc(a){var b=z("window.location.href");null==a&&(a='Unknown Error of type "null/undefined"');if("string"===typeof a)return{message:a,name:"Unknown error",lineNumber:"Not available",fileName:b,stack:"Not available"};var c=!1;try{var d=a.lineNumber||a.line||"Not available"}catch(f){d="Not available",c=!0}try{var e=a.fileName||a.filename||a.sourceURL||x.$googDebugFname||b}catch(f){e="Not available",c=!0}return!c&&a.lineNumber&&a.fileName&&a.stack&&a.message&&a.name?a:(b=a.message,null==b&&(a.constructor&&
a.constructor instanceof Function?(a.constructor.name?b=a.constructor.name:(b=a.constructor,cc[b]?b=cc[b]:(b=String(b),cc[b]||(c=/function\s+([^\(]+)/m.exec(b),cc[b]=c?c[1]:"[Anonymous]"),b=cc[b])),b='Unknown Error of type "'+b+'"'):b="Unknown Error of unknown type"),{message:b,name:a.name||"UnknownError",lineNumber:d,fileName:e,stack:a.stack||"Not available"})}
var cc={};function dc(a){this.f=a||{cookie:""}}
m=dc.prototype;m.isEnabled=function(){return navigator.cookieEnabled};
m.set=function(a,b,c){var d=!1;if("object"===typeof c){var e=c.wb;d=c.secure||!1;var f=c.domain||void 0;var h=c.path||void 0;var g=c.la}if(/[;=\s]/.test(a))throw Error('Invalid cookie name "'+a+'"');if(/[;\r\n]/.test(b))throw Error('Invalid cookie value "'+b+'"');void 0===g&&(g=-1);c=f?";domain="+f:"";h=h?";path="+h:"";d=d?";secure":"";g=0>g?"":0==g?";expires="+(new Date(1970,1,1)).toUTCString():";expires="+(new Date(C()+1E3*g)).toUTCString();this.f.cookie=a+"="+b+c+h+g+d+(null!=e?";samesite="+e:
"")};
m.get=function(a,b){for(var c=a+"=",d=(this.f.cookie||"").split(";"),e=0,f;e<d.length;e++){f=hb(d[e]);if(0==f.lastIndexOf(c,0))return f.substr(c.length);if(f==a)return""}return b};
m.remove=function(a,b,c){var d=void 0!==this.get(a);this.set(a,"",{la:0,path:b,domain:c});return d};
m.isEmpty=function(){return!this.f.cookie};
m.clear=function(){for(var a=(this.f.cookie||"").split(";"),b=[],c=[],d,e,f=0;f<a.length;f++)e=hb(a[f]),d=e.indexOf("="),-1==d?(b.push(""),c.push(e)):(b.push(e.substring(0,d)),c.push(e.substring(d+1)));for(a=b.length-1;0<=a;a--)this.remove(b[a])};
var ec=new dc("undefined"==typeof document?null:document);var fc=!Nb||9<=Number(Zb);function gc(a,b){this.x=void 0!==a?a:0;this.y=void 0!==b?b:0}
m=gc.prototype;m.clone=function(){return new gc(this.x,this.y)};
m.equals=function(a){return a instanceof gc&&(this==a?!0:this&&a?this.x==a.x&&this.y==a.y:!1)};
m.ceil=function(){this.x=Math.ceil(this.x);this.y=Math.ceil(this.y);return this};
m.floor=function(){this.x=Math.floor(this.x);this.y=Math.floor(this.y);return this};
m.round=function(){this.x=Math.round(this.x);this.y=Math.round(this.y);return this};function hc(a,b){this.width=a;this.height=b}
m=hc.prototype;m.clone=function(){return new hc(this.width,this.height)};
m.aspectRatio=function(){return this.width/this.height};
m.isEmpty=function(){return!(this.width*this.height)};
m.ceil=function(){this.width=Math.ceil(this.width);this.height=Math.ceil(this.height);return this};
m.floor=function(){this.width=Math.floor(this.width);this.height=Math.floor(this.height);return this};
m.round=function(){this.width=Math.round(this.width);this.height=Math.round(this.height);return this};function ic(a){var b=document;return"string"===typeof a?b.getElementById(a):a}
function jc(a,b){Ta(b,function(c,d){c&&"object"==typeof c&&c.K&&(c=c.J());"style"==d?a.style.cssText=c:"class"==d?a.className=c:"for"==d?a.htmlFor=c:kc.hasOwnProperty(d)?a.setAttribute(kc[d],c):0==d.lastIndexOf("aria-",0)||0==d.lastIndexOf("data-",0)?a.setAttribute(d,c):a[d]=c})}
var kc={cellpadding:"cellPadding",cellspacing:"cellSpacing",colspan:"colSpan",frameborder:"frameBorder",height:"height",maxlength:"maxLength",nonce:"nonce",role:"role",rowspan:"rowSpan",type:"type",usemap:"useMap",valign:"vAlign",width:"width"};
function lc(a,b,c){var d=arguments,e=document,f=String(d[0]),h=d[1];if(!fc&&h&&(h.name||h.type)){f=["<",f];h.name&&f.push(' name="',Db(h.name),'"');if(h.type){f.push(' type="',Db(h.type),'"');var g={};cb(g,h);delete g.type;h=g}f.push(">");f=f.join("")}f=mc(e,f);h&&("string"===typeof h?f.className=h:Array.isArray(h)?f.className=h.join(" "):jc(f,h));2<d.length&&nc(e,f,d);return f}
function nc(a,b,c){function d(h){h&&b.appendChild("string"===typeof h?a.createTextNode(h):h)}
for(var e=2;e<c.length;e++){var f=c[e];!ya(f)||za(f)&&0<f.nodeType?d(f):F(oc(f)?Qa(f):f,d)}}
function mc(a,b){b=String(b);"application/xhtml+xml"===a.contentType&&(b=b.toLowerCase());return a.createElement(b)}
function oc(a){if(a&&"number"==typeof a.length){if(za(a))return"function"==typeof a.item||"string"==typeof a.item;if(A(a))return"function"==typeof a.item}return!1}
function pc(a,b){for(var c=0;a;){if(b(a))return a;a=a.parentNode;c++}return null}
;function qc(a){rc();return new db(eb,a)}
var rc=va;function sc(a){var b=tc;if(b)for(var c in b)Object.prototype.hasOwnProperty.call(b,c)&&a.call(void 0,b[c],c,b)}
function uc(){var a=[];sc(function(b){a.push(b)});
return a}
var tc={bb:"allow-forms",cb:"allow-modals",eb:"allow-orientation-lock",fb:"allow-pointer-lock",gb:"allow-popups",hb:"allow-popups-to-escape-sandbox",ib:"allow-presentation",jb:"allow-same-origin",kb:"allow-scripts",lb:"allow-top-navigation",mb:"allow-top-navigation-by-user-activation"},vc=Sa(function(){return uc()});
function wc(){var a=mc(document,"IFRAME"),b={};F(vc(),function(c){a.sandbox&&a.sandbox.supports&&a.sandbox.supports(c)&&(b[c]=!0)});
return b}
;function M(){this.g=this.g;this.C=this.C}
M.prototype.g=!1;M.prototype.dispose=function(){this.g||(this.g=!0,this.o())};
function xc(a,b){a.g?b():(a.C||(a.C=[]),a.C.push(b))}
M.prototype.o=function(){if(this.C)for(;this.C.length;)this.C.shift()()};
function yc(a){a&&"function"==typeof a.dispose&&a.dispose()}
function zc(a){for(var b=0,c=arguments.length;b<c;++b){var d=arguments[b];ya(d)?zc.apply(null,d):yc(d)}}
;function Ac(a){"number"==typeof a&&(a=Math.round(a)+"px");return a}
;var Bc=(new Date).getTime();function Cc(a){if(!a)return"";a=a.split("#")[0].split("?")[0];a=a.toLowerCase();0==a.indexOf("//")&&(a=window.location.protocol+a);/^[\w\-]*:\/\//.test(a)||(a=window.location.href);var b=a.substring(a.indexOf("://")+3),c=b.indexOf("/");-1!=c&&(b=b.substring(0,c));a=a.substring(0,a.indexOf("://"));if("http"!==a&&"https"!==a&&"chrome-extension"!==a&&"file"!==a&&"android-app"!==a&&"chrome-search"!==a&&"chrome-untrusted"!==a&&"chrome"!==a&&"app"!==a)throw Error("Invalid URI scheme in origin: "+a);c="";
var d=b.indexOf(":");if(-1!=d){var e=b.substring(d+1);b=b.substring(0,d);if("http"===a&&"80"!==e||"https"===a&&"443"!==e)c=":"+e}return a+"://"+b+c}
;function Dc(){function a(){e[0]=1732584193;e[1]=4023233417;e[2]=2562383102;e[3]=271733878;e[4]=3285377520;n=l=0}
function b(r){for(var w=h,t=0;64>t;t+=4)w[t/4]=r[t]<<24|r[t+1]<<16|r[t+2]<<8|r[t+3];for(t=16;80>t;t++)r=w[t-3]^w[t-8]^w[t-14]^w[t-16],w[t]=(r<<1|r>>>31)&4294967295;r=e[0];var G=e[1],X=e[2],ja=e[3],Qc=e[4];for(t=0;80>t;t++){if(40>t)if(20>t){var Ia=ja^G&(X^ja);var Fb=1518500249}else Ia=G^X^ja,Fb=1859775393;else 60>t?(Ia=G&X|ja&(G|X),Fb=2400959708):(Ia=G^X^ja,Fb=3395469782);Ia=((r<<5|r>>>27)&4294967295)+Ia+Qc+Fb+w[t]&4294967295;Qc=ja;ja=X;X=(G<<30|G>>>2)&4294967295;G=r;r=Ia}e[0]=e[0]+r&4294967295;e[1]=
e[1]+G&4294967295;e[2]=e[2]+X&4294967295;e[3]=e[3]+ja&4294967295;e[4]=e[4]+Qc&4294967295}
function c(r,w){if("string"===typeof r){r=unescape(encodeURIComponent(r));for(var t=[],G=0,X=r.length;G<X;++G)t.push(r.charCodeAt(G));r=t}w||(w=r.length);t=0;if(0==l)for(;t+64<w;)b(r.slice(t,t+64)),t+=64,n+=64;for(;t<w;)if(f[l++]=r[t++],n++,64==l)for(l=0,b(f);t+64<w;)b(r.slice(t,t+64)),t+=64,n+=64}
function d(){var r=[],w=8*n;56>l?c(g,56-l):c(g,64-(l-56));for(var t=63;56<=t;t--)f[t]=w&255,w>>>=8;b(f);for(t=w=0;5>t;t++)for(var G=24;0<=G;G-=8)r[w++]=e[t]>>G&255;return r}
for(var e=[],f=[],h=[],g=[128],k=1;64>k;++k)g[k]=0;var l,n;a();return{reset:a,update:c,digest:d,xa:function(){for(var r=d(),w="",t=0;t<r.length;t++)w+="0123456789ABCDEF".charAt(Math.floor(r[t]/16))+"0123456789ABCDEF".charAt(r[t]%16);return w}}}
;function Ec(a,b,c){var d=[],e=[];if(1==(Array.isArray(c)?2:1))return e=[b,a],F(d,function(g){e.push(g)}),Fc(e.join(" "));
var f=[],h=[];F(c,function(g){h.push(g.key);f.push(g.value)});
c=Math.floor((new Date).getTime()/1E3);e=0==f.length?[c,b,a]:[f.join(":"),c,b,a];F(d,function(g){e.push(g)});
a=Fc(e.join(" "));a=[c,a];0==h.length||a.push(h.join(""));return a.join("_")}
function Fc(a){var b=Dc();b.update(a);return b.xa().toLowerCase()}
;function Gc(a){var b=Cc(String(x.location.href)),c;(c=x.__SAPISID||x.__APISID||x.__OVERRIDE_SID)?c=!0:(c=new dc(document),c=c.get("SAPISID")||c.get("APISID")||c.get("__Secure-3PAPISID")||c.get("SID"),c=!!c);if(c&&(c=(b=0==b.indexOf("https:")||0==b.indexOf("chrome-extension:"))?x.__SAPISID:x.__APISID,c||(c=new dc(document),c=c.get(b?"SAPISID":"APISID")||c.get("__Secure-3PAPISID")),c)){b=b?"SAPISIDHASH":"APISIDHASH";var d=String(x.location.href);return d&&c&&b?[b,Ec(Cc(d),c,a||null)].join(" "):null}return null}
;function Hc(){this.g=[];this.f=-1}
Hc.prototype.set=function(a,b){b=void 0===b?!0:b;0<=a&&52>a&&0===a%1&&this.g[a]!=b&&(this.g[a]=b,this.f=-1)};
Hc.prototype.get=function(a){return!!this.g[a]};
function Ic(a){-1==a.f&&(a.f=Na(a.g,function(b,c,d){return c?b+Math.pow(2,d):b},0));
return a.f}
;function Jc(a,b){this.h=a;this.i=b;this.g=0;this.f=null}
Jc.prototype.get=function(){if(0<this.g){this.g--;var a=this.f;this.f=a.next;a.next=null}else a=this.h();return a};
function Kc(a,b){a.i(b);100>a.g&&(a.g++,b.next=a.f,a.f=b)}
;function Lc(a){x.setTimeout(function(){throw a;},0)}
var Mc;
function Nc(){var a=x.MessageChannel;"undefined"===typeof a&&"undefined"!==typeof window&&window.postMessage&&window.addEventListener&&!I("Presto")&&(a=function(){var e=mc(document,"IFRAME");e.style.display="none";document.documentElement.appendChild(e);var f=e.contentWindow;e=f.document;e.open();e.close();var h="callImmediate"+Math.random(),g="file:"==f.location.protocol?"*":f.location.protocol+"//"+f.location.host;e=B(function(k){if(("*"==g||k.origin==g)&&k.data==h)this.port1.onmessage()},this);
f.addEventListener("message",e,!1);this.port1={};this.port2={postMessage:function(){f.postMessage(h,g)}}});
if("undefined"!==typeof a&&!I("Trident")&&!I("MSIE")){var b=new a,c={},d=c;b.port1.onmessage=function(){if(void 0!==c.next){c=c.next;var e=c.ka;c.ka=null;e()}};
return function(e){d.next={ka:e};d=d.next;b.port2.postMessage(0)}}return function(e){x.setTimeout(e,0)}}
;function Oc(){this.g=this.f=null}
var Rc=new Jc(function(){return new Pc},function(a){a.reset()});
Oc.prototype.add=function(a,b){var c=Rc.get();c.set(a,b);this.g?this.g.next=c:this.f=c;this.g=c};
Oc.prototype.remove=function(){var a=null;this.f&&(a=this.f,this.f=this.f.next,this.f||(this.g=null),a.next=null);return a};
function Pc(){this.next=this.scope=this.f=null}
Pc.prototype.set=function(a,b){this.f=a;this.scope=b;this.next=null};
Pc.prototype.reset=function(){this.next=this.scope=this.f=null};function Sc(a,b){Tc||Uc();Vc||(Tc(),Vc=!0);Wc.add(a,b)}
var Tc;function Uc(){if(x.Promise&&x.Promise.resolve){var a=x.Promise.resolve(void 0);Tc=function(){a.then(Xc)}}else Tc=function(){var b=Xc;
!A(x.setImmediate)||x.Window&&x.Window.prototype&&!I("Edge")&&x.Window.prototype.setImmediate==x.setImmediate?(Mc||(Mc=Nc()),Mc(b)):x.setImmediate(b)}}
var Vc=!1,Wc=new Oc;function Xc(){for(var a;a=Wc.remove();){try{a.f.call(a.scope)}catch(b){Lc(b)}Kc(Rc,a)}Vc=!1}
;function Yc(){this.g=-1}
;function Zc(){this.g=64;this.f=[];this.l=[];this.m=[];this.i=[];this.i[0]=128;for(var a=1;a<this.g;++a)this.i[a]=0;this.j=this.h=0;this.reset()}
D(Zc,Yc);Zc.prototype.reset=function(){this.f[0]=1732584193;this.f[1]=4023233417;this.f[2]=2562383102;this.f[3]=271733878;this.f[4]=3285377520;this.j=this.h=0};
function $c(a,b,c){c||(c=0);var d=a.m;if("string"===typeof b)for(var e=0;16>e;e++)d[e]=b.charCodeAt(c)<<24|b.charCodeAt(c+1)<<16|b.charCodeAt(c+2)<<8|b.charCodeAt(c+3),c+=4;else for(e=0;16>e;e++)d[e]=b[c]<<24|b[c+1]<<16|b[c+2]<<8|b[c+3],c+=4;for(e=16;80>e;e++){var f=d[e-3]^d[e-8]^d[e-14]^d[e-16];d[e]=(f<<1|f>>>31)&4294967295}b=a.f[0];c=a.f[1];var h=a.f[2],g=a.f[3],k=a.f[4];for(e=0;80>e;e++){if(40>e)if(20>e){f=g^c&(h^g);var l=1518500249}else f=c^h^g,l=1859775393;else 60>e?(f=c&h|g&(c|h),l=2400959708):
(f=c^h^g,l=3395469782);f=(b<<5|b>>>27)+f+k+l+d[e]&4294967295;k=g;g=h;h=(c<<30|c>>>2)&4294967295;c=b;b=f}a.f[0]=a.f[0]+b&4294967295;a.f[1]=a.f[1]+c&4294967295;a.f[2]=a.f[2]+h&4294967295;a.f[3]=a.f[3]+g&4294967295;a.f[4]=a.f[4]+k&4294967295}
Zc.prototype.update=function(a,b){if(null!=a){void 0===b&&(b=a.length);for(var c=b-this.g,d=0,e=this.l,f=this.h;d<b;){if(0==f)for(;d<=c;)$c(this,a,d),d+=this.g;if("string"===typeof a)for(;d<b;){if(e[f]=a.charCodeAt(d),++f,++d,f==this.g){$c(this,e);f=0;break}}else for(;d<b;)if(e[f]=a[d],++f,++d,f==this.g){$c(this,e);f=0;break}}this.h=f;this.j+=b}};
Zc.prototype.digest=function(){var a=[],b=8*this.j;56>this.h?this.update(this.i,56-this.h):this.update(this.i,this.g-(this.h-56));for(var c=this.g-1;56<=c;c--)this.l[c]=b&255,b/=256;$c(this,this.l);for(c=b=0;5>c;c++)for(var d=24;0<=d;d-=8)a[b]=this.f[c]>>d&255,++b;return a};function ad(a){return"string"==typeof a.className?a.className:a.getAttribute&&a.getAttribute("class")||""}
function bd(a,b){"string"==typeof a.className?a.className=b:a.setAttribute&&a.setAttribute("class",b)}
function cd(a,b){if(a.classList)var c=a.classList.contains(b);else c=a.classList?a.classList:ad(a).match(/\S+/g)||[],c=0<=Ka(c,b);return c}
function dd(){var a=document.body;a.classList?a.classList.remove("inverted-hdpi"):cd(a,"inverted-hdpi")&&bd(a,La(a.classList?a.classList:ad(a).match(/\S+/g)||[],function(b){return"inverted-hdpi"!=b}).join(" "))}
;var ed="StopIteration"in x?x.StopIteration:{message:"StopIteration",stack:""};function fd(){}
fd.prototype.next=function(){throw ed;};
fd.prototype.D=function(){return this};
function gd(a){if(a instanceof fd)return a;if("function"==typeof a.D)return a.D(!1);if(ya(a)){var b=0,c=new fd;c.next=function(){for(;;){if(b>=a.length)throw ed;if(b in a)return a[b++];b++}};
return c}throw Error("Not implemented");}
function hd(a,b){if(ya(a))try{F(a,b,void 0)}catch(c){if(c!==ed)throw c;}else{a=gd(a);try{for(;;)b.call(void 0,a.next(),void 0,a)}catch(c){if(c!==ed)throw c;}}}
function id(a){if(ya(a))return Qa(a);a=gd(a);var b=[];hd(a,function(c){b.push(c)});
return b}
;function jd(a,b){this.h={};this.f=[];this.F=this.g=0;var c=arguments.length;if(1<c){if(c%2)throw Error("Uneven number of arguments");for(var d=0;d<c;d+=2)this.set(arguments[d],arguments[d+1])}else if(a)if(a instanceof jd)for(c=kd(a),d=0;d<c.length;d++)this.set(c[d],a.get(c[d]));else for(d in a)this.set(d,a[d])}
function kd(a){ld(a);return a.f.concat()}
m=jd.prototype;m.equals=function(a,b){if(this===a)return!0;if(this.g!=a.g)return!1;var c=b||md;ld(this);for(var d,e=0;d=this.f[e];e++)if(!c(this.get(d),a.get(d)))return!1;return!0};
function md(a,b){return a===b}
m.isEmpty=function(){return 0==this.g};
m.clear=function(){this.h={};this.F=this.g=this.f.length=0};
m.remove=function(a){return Object.prototype.hasOwnProperty.call(this.h,a)?(delete this.h[a],this.g--,this.F++,this.f.length>2*this.g&&ld(this),!0):!1};
function ld(a){if(a.g!=a.f.length){for(var b=0,c=0;b<a.f.length;){var d=a.f[b];Object.prototype.hasOwnProperty.call(a.h,d)&&(a.f[c++]=d);b++}a.f.length=c}if(a.g!=a.f.length){var e={};for(c=b=0;b<a.f.length;)d=a.f[b],Object.prototype.hasOwnProperty.call(e,d)||(a.f[c++]=d,e[d]=1),b++;a.f.length=c}}
m.get=function(a,b){return Object.prototype.hasOwnProperty.call(this.h,a)?this.h[a]:b};
m.set=function(a,b){Object.prototype.hasOwnProperty.call(this.h,a)||(this.g++,this.f.push(a),this.F++);this.h[a]=b};
m.forEach=function(a,b){for(var c=kd(this),d=0;d<c.length;d++){var e=c[d],f=this.get(e);a.call(b,f,e,this)}};
m.clone=function(){return new jd(this)};
m.D=function(a){ld(this);var b=0,c=this.F,d=this,e=new fd;e.next=function(){if(c!=d.F)throw Error("The map has changed since the iterator was created");if(b>=d.f.length)throw ed;var f=d.f[b++];return a?f:d.h[f]};
return e};function nd(a){var b=[];od(new pd,a,b);return b.join("")}
function pd(){}
function od(a,b,c){if(null==b)c.push("null");else{if("object"==typeof b){if(Array.isArray(b)){var d=b;b=d.length;c.push("[");for(var e="",f=0;f<b;f++)c.push(e),od(a,d[f],c),e=",";c.push("]");return}if(b instanceof String||b instanceof Number||b instanceof Boolean)b=b.valueOf();else{c.push("{");e="";for(d in b)Object.prototype.hasOwnProperty.call(b,d)&&(f=b[d],"function"!=typeof f&&(c.push(e),qd(d,c),c.push(":"),od(a,f,c),e=","));c.push("}");return}}switch(typeof b){case "string":qd(b,c);break;case "number":c.push(isFinite(b)&&
!isNaN(b)?String(b):"null");break;case "boolean":c.push(String(b));break;case "function":c.push("null");break;default:throw Error("Unknown type: "+typeof b);}}}
var rd={'"':'\\"',"\\":"\\\\","/":"\\/","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r","\t":"\\t","\x0B":"\\u000b"},sd=/\uffff/.test("\uffff")?/[\\"\x00-\x1f\x7f-\uffff]/g:/[\\"\x00-\x1f\x7f-\xff]/g;function qd(a,b){b.push('"',a.replace(sd,function(c){var d=rd[c];d||(d="\\u"+(c.charCodeAt(0)|65536).toString(16).substr(1),rd[c]=d);return d}),'"')}
;function td(a){if(!a)return!1;try{return!!a.$goog_Thenable}catch(b){return!1}}
;function N(a){this.f=0;this.m=void 0;this.i=this.g=this.h=null;this.j=this.l=!1;if(a!=va)try{var b=this;a.call(void 0,function(c){ud(b,2,c)},function(c){ud(b,3,c)})}catch(c){ud(this,3,c)}}
function vd(){this.next=this.context=this.onRejected=this.g=this.f=null;this.h=!1}
vd.prototype.reset=function(){this.context=this.onRejected=this.g=this.f=null;this.h=!1};
var wd=new Jc(function(){return new vd},function(a){a.reset()});
function xd(a,b,c){var d=wd.get();d.g=a;d.onRejected=b;d.context=c;return d}
function yd(a){return new N(function(b,c){c(a)})}
N.prototype.then=function(a,b,c){return zd(this,A(a)?a:null,A(b)?b:null,c)};
N.prototype.$goog_Thenable=!0;function Ad(a,b){return zd(a,null,b,void 0)}
N.prototype.cancel=function(a){if(0==this.f){var b=new Bd(a);Sc(function(){Cd(this,b)},this)}};
function Cd(a,b){if(0==a.f)if(a.h){var c=a.h;if(c.g){for(var d=0,e=null,f=null,h=c.g;h&&(h.h||(d++,h.f==a&&(e=h),!(e&&1<d)));h=h.next)e||(f=h);e&&(0==c.f&&1==d?Cd(c,b):(f?(d=f,d.next==c.i&&(c.i=d),d.next=d.next.next):Dd(c),Ed(c,e,3,b)))}a.h=null}else ud(a,3,b)}
function Fd(a,b){a.g||2!=a.f&&3!=a.f||Gd(a);a.i?a.i.next=b:a.g=b;a.i=b}
function zd(a,b,c,d){var e=xd(null,null,null);e.f=new N(function(f,h){e.g=b?function(g){try{var k=b.call(d,g);f(k)}catch(l){h(l)}}:f;
e.onRejected=c?function(g){try{var k=c.call(d,g);void 0===k&&g instanceof Bd?h(g):f(k)}catch(l){h(l)}}:h});
e.f.h=a;Fd(a,e);return e.f}
N.prototype.w=function(a){this.f=0;ud(this,2,a)};
N.prototype.B=function(a){this.f=0;ud(this,3,a)};
function ud(a,b,c){if(0==a.f){a===c&&(b=3,c=new TypeError("Promise cannot resolve to itself"));a.f=1;a:{var d=c,e=a.w,f=a.B;if(d instanceof N){Fd(d,xd(e||va,f||null,a));var h=!0}else if(td(d))d.then(e,f,a),h=!0;else{if(za(d))try{var g=d.then;if(A(g)){Hd(d,g,e,f,a);h=!0;break a}}catch(k){f.call(a,k);h=!0;break a}h=!1}}h||(a.m=c,a.f=b,a.h=null,Gd(a),3!=b||c instanceof Bd||Id(a,c))}}
function Hd(a,b,c,d,e){function f(k){g||(g=!0,d.call(e,k))}
function h(k){g||(g=!0,c.call(e,k))}
var g=!1;try{b.call(a,h,f)}catch(k){f(k)}}
function Gd(a){a.l||(a.l=!0,Sc(a.C,a))}
function Dd(a){var b=null;a.g&&(b=a.g,a.g=b.next,b.next=null);a.g||(a.i=null);return b}
N.prototype.C=function(){for(var a;a=Dd(this);)Ed(this,a,this.f,this.m);this.l=!1};
function Ed(a,b,c,d){if(3==c&&b.onRejected&&!b.h)for(;a&&a.j;a=a.h)a.j=!1;if(b.f)b.f.h=null,Jd(b,c,d);else try{b.h?b.g.call(b.context):Jd(b,c,d)}catch(e){Kd.call(null,e)}Kc(wd,b)}
function Jd(a,b,c){2==b?a.g.call(a.context,c):a.onRejected&&a.onRejected.call(a.context,c)}
function Id(a,b){a.j=!0;Sc(function(){a.j&&Kd.call(null,b)})}
var Kd=Lc;function Bd(a){E.call(this,a)}
D(Bd,E);Bd.prototype.name="cancel";function O(a){M.call(this);this.l=1;this.i=[];this.j=0;this.f=[];this.h={};this.m=!!a}
D(O,M);m=O.prototype;m.subscribe=function(a,b,c){var d=this.h[a];d||(d=this.h[a]=[]);var e=this.l;this.f[e]=a;this.f[e+1]=b;this.f[e+2]=c;this.l=e+3;d.push(e);return e};
function Ld(a,b,c,d){if(b=a.h[b]){var e=a.f;(b=Oa(b,function(f){return e[f+1]==c&&e[f+2]==d}))&&a.N(b)}}
m.N=function(a){var b=this.f[a];if(b){var c=this.h[b];0!=this.j?(this.i.push(a),this.f[a+1]=va):(c&&Pa(c,a),delete this.f[a],delete this.f[a+1],delete this.f[a+2])}return!!b};
m.M=function(a,b){var c=this.h[a];if(c){for(var d=Array(arguments.length-1),e=1,f=arguments.length;e<f;e++)d[e-1]=arguments[e];if(this.m)for(e=0;e<c.length;e++){var h=c[e];Md(this.f[h+1],this.f[h+2],d)}else{this.j++;try{for(e=0,f=c.length;e<f;e++)h=c[e],this.f[h+1].apply(this.f[h+2],d)}finally{if(this.j--,0<this.i.length&&0==this.j)for(;c=this.i.pop();)this.N(c)}}return 0!=e}return!1};
function Md(a,b,c){Sc(function(){a.apply(b,c)})}
m.clear=function(a){if(a){var b=this.h[a];b&&(F(b,this.N,this),delete this.h[a])}else this.f.length=0,this.h={}};
m.o=function(){O.L.o.call(this);this.clear();this.i.length=0};function Nd(a){this.f=a}
Nd.prototype.set=function(a,b){void 0===b?this.f.remove(a):this.f.set(a,nd(b))};
Nd.prototype.get=function(a){try{var b=this.f.get(a)}catch(c){return}if(null!==b)try{return JSON.parse(b)}catch(c){throw"Storage: Invalid value was encountered";}};
Nd.prototype.remove=function(a){this.f.remove(a)};function Od(a){this.f=a}
D(Od,Nd);function Pd(a){this.data=a}
function Qd(a){return void 0===a||a instanceof Pd?a:new Pd(a)}
Od.prototype.set=function(a,b){Od.L.set.call(this,a,Qd(b))};
Od.prototype.g=function(a){a=Od.L.get.call(this,a);if(void 0===a||a instanceof Object)return a;throw"Storage: Invalid value was encountered";};
Od.prototype.get=function(a){if(a=this.g(a)){if(a=a.data,void 0===a)throw"Storage: Invalid value was encountered";}else a=void 0;return a};function Rd(a){this.f=a}
D(Rd,Od);Rd.prototype.set=function(a,b,c){if(b=Qd(b)){if(c){if(c<C()){Rd.prototype.remove.call(this,a);return}b.expiration=c}b.creation=C()}Rd.L.set.call(this,a,b)};
Rd.prototype.g=function(a){var b=Rd.L.g.call(this,a);if(b){var c=b.creation,d=b.expiration;if(d&&d<C()||c&&c>C())Rd.prototype.remove.call(this,a);else return b}};function Sd(){}
;function Td(){}
D(Td,Sd);Td.prototype.clear=function(){var a=id(this.D(!0)),b=this;F(a,function(c){b.remove(c)})};function Ud(a){this.f=a}
D(Ud,Td);m=Ud.prototype;m.isAvailable=function(){if(!this.f)return!1;try{return this.f.setItem("__sak","1"),this.f.removeItem("__sak"),!0}catch(a){return!1}};
m.set=function(a,b){try{this.f.setItem(a,b)}catch(c){if(0==this.f.length)throw"Storage mechanism: Storage disabled";throw"Storage mechanism: Quota exceeded";}};
m.get=function(a){a=this.f.getItem(a);if("string"!==typeof a&&null!==a)throw"Storage mechanism: Invalid value was encountered";return a};
m.remove=function(a){this.f.removeItem(a)};
m.D=function(a){var b=0,c=this.f,d=new fd;d.next=function(){if(b>=c.length)throw ed;var e=c.key(b++);if(a)return e;e=c.getItem(e);if("string"!==typeof e)throw"Storage mechanism: Invalid value was encountered";return e};
return d};
m.clear=function(){this.f.clear()};
m.key=function(a){return this.f.key(a)};function Vd(){var a=null;try{a=window.localStorage||null}catch(b){}this.f=a}
D(Vd,Ud);function Wd(a,b){this.g=a;this.f=null;if(Nb&&!(9<=Number(Zb))){Xd||(Xd=new jd);this.f=Xd.get(a);this.f||(b?this.f=document.getElementById(b):(this.f=document.createElement("userdata"),this.f.addBehavior("#default#userData"),document.body.appendChild(this.f)),Xd.set(a,this.f));try{this.f.load(this.g)}catch(c){this.f=null}}}
D(Wd,Td);var Yd={".":".2E","!":".21","~":".7E","*":".2A","'":".27","(":".28",")":".29","%":"."},Xd=null;function Zd(a){return"_"+encodeURIComponent(a).replace(/[.!~*'()%]/g,function(b){return Yd[b]})}
m=Wd.prototype;m.isAvailable=function(){return!!this.f};
m.set=function(a,b){this.f.setAttribute(Zd(a),b);$d(this)};
m.get=function(a){a=this.f.getAttribute(Zd(a));if("string"!==typeof a&&null!==a)throw"Storage mechanism: Invalid value was encountered";return a};
m.remove=function(a){this.f.removeAttribute(Zd(a));$d(this)};
m.D=function(a){var b=0,c=this.f.XMLDocument.documentElement.attributes,d=new fd;d.next=function(){if(b>=c.length)throw ed;var e=c[b++];if(a)return decodeURIComponent(e.nodeName.replace(/\./g,"%")).substr(1);e=e.nodeValue;if("string"!==typeof e)throw"Storage mechanism: Invalid value was encountered";return e};
return d};
m.clear=function(){for(var a=this.f.XMLDocument.documentElement,b=a.attributes.length;0<b;b--)a.removeAttribute(a.attributes[b-1].nodeName);$d(this)};
function $d(a){try{a.f.save(a.g)}catch(b){throw"Storage mechanism: Quota exceeded";}}
;function ae(a,b){this.g=a;this.f=b+"::"}
D(ae,Td);ae.prototype.set=function(a,b){this.g.set(this.f+a,b)};
ae.prototype.get=function(a){return this.g.get(this.f+a)};
ae.prototype.remove=function(a){this.g.remove(this.f+a)};
ae.prototype.D=function(a){var b=this.g.D(!0),c=this,d=new fd;d.next=function(){for(var e=b.next();e.substr(0,c.f.length)!=c.f;)e=b.next();return a?e.substr(c.f.length):c.g.get(e)};
return d};function be(a,b){1<b.length?a[b[0]]=b[1]:1===b.length&&Object.assign(a,b[0])}
;var ce=window.yt&&window.yt.config_||window.ytcfg&&window.ytcfg.data_||{};y("yt.config_",ce,void 0);function P(a){be(ce,arguments)}
function Q(a,b){return a in ce?ce[a]:b}
function de(){return Q("PLAYER_CONFIG",{})}
function ee(a){var b=ce.EXPERIMENT_FLAGS;return b?b[a]:void 0}
;function fe(){var a=ge;z("yt.ads.biscotti.getId_")||y("yt.ads.biscotti.getId_",a,void 0)}
function he(a){y("yt.ads.biscotti.lastId_",a,void 0)}
;var ie=[];function je(a){ie.forEach(function(b){return b(a)})}
function ke(a){return a&&window.yterr?function(){try{return a.apply(this,arguments)}catch(b){le(b),je(b)}}:a}
function le(a){var b=z("yt.logging.errors.log");b?b(a,"ERROR",void 0,void 0,void 0):(b=Q("ERRORS",[]),b.push([a,"ERROR",void 0,void 0,void 0]),P("ERRORS",b))}
function me(a){var b=z("yt.logging.errors.log");b?b(a,"WARNING",void 0,void 0,void 0):(b=Q("ERRORS",[]),b.push([a,"WARNING",void 0,void 0,void 0]),P("ERRORS",b))}
;function ne(a){a=a.split("&");for(var b={},c=0,d=a.length;c<d;c++){var e=a[c].split("=");if(1==e.length&&e[0]||2==e.length)try{var f=decodeURIComponent((e[0]||"").replace(/\+/g," ")),h=decodeURIComponent((e[1]||"").replace(/\+/g," "));f in b?Array.isArray(b[f])?Ra(b[f],h):b[f]=[b[f],h]:b[f]=h}catch(k){if("q"!=e[0]){var g=Error("Error decoding URL component");g.params={key:e[0],value:e[1]};le(g)}}}return b}
function oe(a){var b=[];Ta(a,function(c,d){var e=encodeURIComponent(String(d)),f;Array.isArray(c)?f=c:f=[c];F(f,function(h){""==h?b.push(e):b.push(e+"="+encodeURIComponent(String(h)))})});
return b.join("&")}
function pe(a){"?"==a.charAt(0)&&(a=a.substr(1));return ne(a)}
function qe(a,b){return re(a,b||{},!0)}
function re(a,b,c){var d=a.split("#",2);a=d[0];d=1<d.length?"#"+d[1]:"";var e=a.split("?",2);a=e[0];e=pe(e[1]||"");for(var f in b)!c&&null!==e&&f in e||(e[f]=b[f]);return Jb(a,e)+d}
;function se(a){var b=te;a=void 0===a?z("yt.ads.biscotti.lastId_")||"":a;b=Object.assign(ue(b),ve(b));b.ca_type="image";a&&(b.bid=a);return b}
function ue(a){var b={};b.dt=Bc;b.flash="0";a:{try{var c=a.f.top.location.href}catch(f){a=2;break a}a=c?c===a.g.location.href?0:1:2}b=(b.frm=a,b);b.u_tz=-(new Date).getTimezoneOffset();var d=void 0===d?L:d;try{var e=d.history.length}catch(f){e=0}b.u_his=e;b.u_java=!!L.navigator&&"unknown"!==typeof L.navigator.javaEnabled&&!!L.navigator.javaEnabled&&L.navigator.javaEnabled();L.screen&&(b.u_h=L.screen.height,b.u_w=L.screen.width,b.u_ah=L.screen.availHeight,b.u_aw=L.screen.availWidth,b.u_cd=L.screen.colorDepth);
L.navigator&&L.navigator.plugins&&(b.u_nplug=L.navigator.plugins.length);L.navigator&&L.navigator.mimeTypes&&(b.u_nmime=L.navigator.mimeTypes.length);return b}
function ve(a){var b=a.f;try{var c=b.screenX;var d=b.screenY}catch(r){}try{var e=b.outerWidth;var f=b.outerHeight}catch(r){}try{var h=b.innerWidth;var g=b.innerHeight}catch(r){}b=[b.screenLeft,b.screenTop,c,d,b.screen?b.screen.availWidth:void 0,b.screen?b.screen.availTop:void 0,e,f,h,g];c=a.f.top;try{var k=(c||window).document,l="CSS1Compat"==k.compatMode?k.documentElement:k.body;var n=(new hc(l.clientWidth,l.clientHeight)).round()}catch(r){n=new hc(-12245933,-12245933)}k=n;n={};l=new Hc;x.SVGElement&&
x.document.createElementNS&&l.set(0);c=wc();c["allow-top-navigation-by-user-activation"]&&l.set(1);c["allow-popups-to-escape-sandbox"]&&l.set(2);x.crypto&&x.crypto.subtle&&l.set(3);x.TextDecoder&&x.TextEncoder&&l.set(4);l=Ic(l);n.bc=l;n.bih=k.height;n.biw=k.width;n.brdim=b.join();a=a.g;return n.vis={visible:1,hidden:2,prerender:3,preview:4,unloaded:5}[a.visibilityState||a.webkitVisibilityState||a.mozVisibilityState||""]||0,n.wgl=!!L.WebGLRenderingContext,n}
var te=new function(){var a=window.document;this.f=window;this.g=a};
y("yt.ads_.signals_.getAdSignalsString",function(a){return oe(se(a))},void 0);C();function R(a){a=we(a);return"string"===typeof a&&"false"===a?!1:!!a}
function xe(a,b){var c=we(a);return void 0===c&&void 0!==b?b:Number(c||0)}
function we(a){var b=Q("EXPERIMENTS_FORCED_FLAGS",{});return void 0!==b[a]?b[a]:Q("EXPERIMENT_FLAGS",{})[a]}
;var ye=void 0!==XMLHttpRequest?function(){return new XMLHttpRequest}:void 0!==ActiveXObject?function(){return new ActiveXObject("Microsoft.XMLHTTP")}:null;
function ze(){if(!ye)return null;var a=ye();return"open"in a?a:null}
function Ae(a){switch(a&&"status"in a?a.status:-1){case 200:case 201:case 202:case 203:case 204:case 205:case 206:case 304:return!0;default:return!1}}
;function S(a,b){A(a)&&(a=ke(a));return window.setTimeout(a,b)}
function T(a){window.clearTimeout(a)}
;var Be={Authorization:"AUTHORIZATION","X-Goog-Visitor-Id":"SANDBOXED_VISITOR_ID","X-YouTube-Client-Name":"INNERTUBE_CONTEXT_CLIENT_NAME","X-YouTube-Client-Version":"INNERTUBE_CONTEXT_CLIENT_VERSION","X-YouTube-Device":"DEVICE","X-Youtube-Identity-Token":"ID_TOKEN","X-YouTube-Page-CL":"PAGE_CL","X-YouTube-Page-Label":"PAGE_BUILD_LABEL","X-YouTube-Variants-Checksum":"VARIANTS_CHECKSUM"},Ce="app debugcss debugjs expflag force_ad_params force_viral_ad_response_params forced_experiments innertube_snapshots innertube_goldens internalcountrycode internalipoverride absolute_experiments conditional_experiments sbb sr_bns_address".split(" "),
De=!1;
function Ee(a,b){b=void 0===b?{}:b;if(!c)var c=window.location.href;var d=K(1,a),e=J(K(3,a));d&&e?(d=c,c=a.match(Gb),d=d.match(Gb),c=c[3]==d[3]&&c[1]==d[1]&&c[4]==d[4]):c=e?J(K(3,c))==e&&(Number(K(4,c))||null)==(Number(K(4,a))||null):!0;d=R("web_ajax_ignore_global_headers_if_set");for(var f in Be)e=Q(Be[f]),!e||!c&&!Fe(a,f)||d&&void 0!==b[f]||(b[f]=e);if(c||Fe(a,"X-YouTube-Utc-Offset"))b["X-YouTube-Utc-Offset"]=String(-(new Date).getTimezoneOffset());(c||Fe(a,"X-YouTube-Time-Zone"))&&(f="undefined"!=typeof Intl?
(new Intl.DateTimeFormat).resolvedOptions().timeZone:null)&&(b["X-YouTube-Time-Zone"]=f);if(c||Fe(a,"X-YouTube-Ad-Signals"))b["X-YouTube-Ad-Signals"]=oe(se(void 0));return b}
function Ge(a){var b=window.location.search,c=J(K(3,a)),d=J(K(5,a));d=(c=c&&(c.endsWith("youtube.com")||c.endsWith("youtube-nocookie.com")))&&d&&d.startsWith("/api/");if(!c||d)return a;var e=pe(b),f={};F(Ce,function(h){e[h]&&(f[h]=e[h])});
return re(a,f||{},!1)}
function Fe(a,b){var c=Q("CORS_HEADER_WHITELIST")||{},d=J(K(3,a));return d?(c=c[d])?0<=Ka(c,b):!1:!0}
function He(a,b){if(window.fetch&&"XML"!=b.format){var c={method:b.method||"GET",credentials:"same-origin"};b.headers&&(c.headers=b.headers);a=Ie(a,b);var d=Je(a,b);d&&(c.body=d);b.withCredentials&&(c.credentials="include");var e=!1,f;fetch(a,c).then(function(h){if(!e){e=!0;f&&T(f);var g=h.ok,k=function(l){l=l||{};var n=b.context||x;g?b.onSuccess&&b.onSuccess.call(n,l,h):b.onError&&b.onError.call(n,l,h);b.ia&&b.ia.call(n,l,h)};
"JSON"==(b.format||"JSON")&&(g||400<=h.status&&500>h.status)?h.json().then(k,function(){k(null)}):k(null)}});
b.oa&&0<b.timeout&&(f=S(function(){e||(e=!0,T(f),b.oa.call(b.context||x))},b.timeout))}else Ke(a,b)}
function Ke(a,b){var c=b.format||"JSON";a=Ie(a,b);var d=Je(a,b),e=!1,f,h=Le(a,function(g){if(!e){e=!0;f&&T(f);var k=Ae(g),l=null,n=400<=g.status&&500>g.status,r=500<=g.status&&600>g.status;if(k||n||r)l=Me(c,g,b.qb);if(k)a:if(g&&204==g.status)k=!0;else{switch(c){case "XML":k=0==parseInt(l&&l.return_code,10);break a;case "RAW":k=!0;break a}k=!!l}l=l||{};n=b.context||x;k?b.onSuccess&&b.onSuccess.call(n,g,l):b.onError&&b.onError.call(n,g,l);b.ia&&b.ia.call(n,g,l)}},b.method,d,b.headers,b.responseType,
b.withCredentials);
b.O&&0<b.timeout&&(f=S(function(){e||(e=!0,h.abort(),T(f),b.O.call(b.context||x,h))},b.timeout));
return h}
function Ie(a,b){b.tb&&(a=document.location.protocol+"//"+document.location.hostname+(document.location.port?":"+document.location.port:"")+a);var c=Q("XSRF_FIELD_NAME",void 0),d=b.Za;d&&(d[c]&&delete d[c],a=qe(a,d));return a}
function Je(a,b){var c=Q("XSRF_FIELD_NAME",void 0),d=Q("XSRF_TOKEN",void 0),e=b.postBody||"",f=b.A,h=Q("XSRF_FIELD_NAME",void 0),g;b.headers&&(g=b.headers["Content-Type"]);b.sb||J(K(3,a))&&!b.withCredentials&&J(K(3,a))!=document.location.hostname||"POST"!=b.method||g&&"application/x-www-form-urlencoded"!=g||b.A&&b.A[h]||(f||(f={}),f[c]=d);f&&"string"===typeof e&&(e=pe(e),cb(e,f),e=b.qa&&"JSON"==b.qa?JSON.stringify(e):Ib(e));f=e||f&&!Xa(f);!De&&f&&"POST"!=b.method&&(De=!0,le(Error("AJAX request with postData should use POST")));
return e}
function Me(a,b,c){var d=null;switch(a){case "JSON":a=b.responseText;b=b.getResponseHeader("Content-Type")||"";a&&0<=b.indexOf("json")&&(d=JSON.parse(a));break;case "XML":if(b=(b=b.responseXML)?Ne(b):null)d={},F(b.getElementsByTagName("*"),function(e){d[e.tagName]=Oe(e)})}c&&Pe(d);
return d}
function Pe(a){if(za(a))for(var b in a){var c;(c="html_content"==b)||(c=b.length-5,c=0<=c&&b.indexOf("_html",c)==c);if(c){c=b;var d=Ab(a[b],null);a[c]=d}else Pe(a[b])}}
function Ne(a){return a?(a=("responseXML"in a?a.responseXML:a).getElementsByTagName("root"))&&0<a.length?a[0]:null:null}
function Oe(a){var b="";F(a.childNodes,function(c){b+=c.nodeValue});
return b}
function Le(a,b,c,d,e,f,h){function g(){4==(k&&"readyState"in k?k.readyState:0)&&b&&ke(b)(k)}
c=void 0===c?"GET":c;d=void 0===d?"":d;var k=ze();if(!k)return null;"onloadend"in k?k.addEventListener("loadend",g,!1):k.onreadystatechange=g;R("debug_forward_web_query_parameters")&&(a=Ge(a));k.open(c,a,!0);f&&(k.responseType=f);h&&(k.withCredentials=!0);c="POST"==c&&(void 0===window.FormData||!(d instanceof FormData));if(e=Ee(a,e))for(var l in e)k.setRequestHeader(l,e[l]),"content-type"==l.toLowerCase()&&(c=!1);c&&k.setRequestHeader("Content-Type","application/x-www-form-urlencoded");k.send(d);
return k}
;var Qe={},Re=0;
function Se(a,b,c,d,e){e=void 0===e?"":e;a&&(c&&(c=vb,c=!(c&&0<=c.toLowerCase().indexOf("cobalt"))),c?a&&(a instanceof H||(a="object"==typeof a&&a.K?a.J():String(a),tb.test(a)||(a="about:invalid#zClosurez"),a=new H(qb,a)),b=sb(a),"about:invalid#zClosurez"===b?a="":(b instanceof yb?a=b:(d="object"==typeof b,a=null,d&&b.ga&&(a=b.da()),b=ib(d&&b.K?b.J():String(b)),a=Ab(b,a)),a instanceof yb&&a.constructor===yb&&a.h===zb?a=a.f:(xa(a),a="type_error:SafeHtml"),a=encodeURIComponent(String(nd(a.toString())))),/^[\s\xa0]*$/.test(a)||
(a=lc("IFRAME",{src:'javascript:"<body><img src=\\""+'+a+'+"\\"></body>"',style:"display:none"}),(9==a.nodeType?a:a.ownerDocument||a.document).body.appendChild(a))):e?Le(a,b,"POST",e,d):Q("USE_NET_AJAX_FOR_PING_TRANSPORT",!1)||d?Le(a,b,"GET","",d):Te(a,b)||Ue(a,b))}
function Te(a,b){if(!ee("web_use_beacon_api_for_ad_click_server_pings"))return!1;if(ee("use_sonic_js_library_for_v4_support")){a:{try{var c=new Ja({url:a,ab:!0});if(c.j?c.h&&c.f&&c.f[1]||c.i:c.g){var d=J(K(5,a));var e=!(!d||!d.endsWith("/aclk")||"1"!==Lb(a,"ri"));break a}}catch(f){}e=!1}if(!e)return!1}else if(e=J(K(5,a)),!e||-1==e.indexOf("/aclk")||"1"!==Lb(a,"ae")||"1"!==Lb(a,"act"))return!1;return Ve(a)?(b&&b(),!0):!1}
function Ve(a,b){try{if(window.navigator&&window.navigator.sendBeacon&&window.navigator.sendBeacon(a,void 0===b?"":b))return!0}catch(c){}return!1}
function Ue(a,b){var c=new Image,d=""+Re++;Qe[d]=c;c.onload=c.onerror=function(){b&&Qe[d]&&b();delete Qe[d]};
c.src=a}
;var We=z("ytPubsubPubsubInstance")||new O;O.prototype.subscribe=O.prototype.subscribe;O.prototype.unsubscribeByKey=O.prototype.N;O.prototype.publish=O.prototype.M;O.prototype.clear=O.prototype.clear;y("ytPubsubPubsubInstance",We,void 0);var Xe=z("ytPubsubPubsubSubscribedKeys")||{};y("ytPubsubPubsubSubscribedKeys",Xe,void 0);var Ye=z("ytPubsubPubsubTopicToKeys")||{};y("ytPubsubPubsubTopicToKeys",Ye,void 0);var Ze=z("ytPubsubPubsubIsSynchronous")||{};y("ytPubsubPubsubIsSynchronous",Ze,void 0);
function $e(a,b){var c=af();if(c){var d=c.subscribe(a,function(){var e=arguments;var f=function(){Xe[d]&&b.apply&&"function"==typeof b.apply&&b.apply(window,e)};
try{Ze[a]?f():S(f,0)}catch(h){le(h)}},void 0);
Xe[d]=!0;Ye[a]||(Ye[a]=[]);Ye[a].push(d);return d}return 0}
function bf(a){var b=af();b&&("number"===typeof a?a=[a]:"string"===typeof a&&(a=[parseInt(a,10)]),F(a,function(c){b.unsubscribeByKey(c);delete Xe[c]}))}
function cf(a,b){var c=af();c&&c.publish.apply(c,arguments)}
function df(a){var b=af();if(b)if(b.clear(a),a)ef(a);else for(var c in Ye)ef(c)}
function af(){return z("ytPubsubPubsubInstance")}
function ef(a){Ye[a]&&(a=Ye[a],F(a,function(b){Xe[b]&&delete Xe[b]}),a.length=0)}
;var ff=window,U=ff.ytcsi&&ff.ytcsi.now?ff.ytcsi.now:ff.performance&&ff.performance.timing&&ff.performance.now&&ff.performance.timing.navigationStart?function(){return ff.performance.timing.navigationStart+ff.performance.now()}:function(){return(new Date).getTime()};var gf=xe("initial_gel_batch_timeout",1E3),hf=Math.pow(2,16)-1,jf=null,kf=0,lf=void 0,mf=0,nf=0,of=0,pf=!0,qf=z("ytLoggingTransportLogPayloadsQueue_")||{};y("ytLoggingTransportLogPayloadsQueue_",qf,void 0);var rf=z("ytLoggingTransportGELQueue_")||new Map;y("ytLoggingTransportGELQueue_",rf,void 0);var sf=z("ytLoggingTransportTokensToCttTargetIds_")||{};y("ytLoggingTransportTokensToCttTargetIds_",sf,void 0);
function tf(){T(mf);T(nf);nf=0;lf&&lf.isReady()?(uf(rf),"log_event"in qf&&uf(Object.entries(qf.log_event)),rf.clear(),delete qf.log_event):vf()}
function vf(){R("web_gel_timeout_cap")&&!nf&&(nf=S(tf,6E4));T(mf);var a=Q("LOGGING_BATCH_TIMEOUT",xe("web_gel_debounce_ms",1E4));R("shorten_initial_gel_batch_timeout")&&pf&&(a=gf);mf=S(tf,a)}
function uf(a){var b=lf,c=Math.round(U());a=p(a);for(var d=a.next();!d.done;d=a.next()){var e=p(d.value);d=e.next().value;var f=e.next().value;e=ab({context:wf(b.f||xf())});e.events=f;(f=sf[d])&&yf(e,d,f);delete sf[d];zf(e,c);Af(b,"log_event",e,{retry:!0,onSuccess:function(){kf=Math.round(U()-c)}});
pf=!1}}
function zf(a,b){a.requestTimeMs=String(b);R("unsplit_gel_payloads_in_logs")&&(a.unsplitGelPayloadsInLogs=!0);var c=Q("EVENT_ID",void 0);if(c){var d=Q("BATCH_CLIENT_COUNTER",void 0)||0;!d&&R("web_client_counter_random_seed")&&(d=Math.floor(Math.random()*hf/2));d++;d>hf&&(d=1);P("BATCH_CLIENT_COUNTER",d);c={serializedEventId:c,clientCounter:String(d)};a.serializedClientEventId=c;jf&&kf&&R("log_gel_rtt_web")&&(a.previousBatchInfo={serializedClientEventId:jf,roundtripMs:String(kf)});jf=c;kf=0}}
function yf(a,b,c){if(c.videoId)var d="VIDEO";else if(c.playlistId)d="PLAYLIST";else return;a.credentialTransferTokenTargetId=c;a.context=a.context||{};a.context.user=a.context.user||{};a.context.user.credentialTransferTokens=[{token:b,scope:d}]}
;var Bf=xe("initial_gel_batch_timeout",1E3),Cf=Math.pow(2,16)-1,Df=null,Ef=0,Ff={log_event:"events",log_interaction:"interactions"},Gf=new Set(["log_event"]),Hf={},If=0,Jf=0,Kf=0,Lf=!0,V=z("ytLoggingTransportLogPayloadsQueue_")||{};y("ytLoggingTransportLogPayloadsQueue_",V,void 0);var Mf=z("ytLoggingTransportTokensToCttTargetIds_")||{};y("ytLoggingTransportTokensToCttTargetIds_",Mf,void 0);
function Nf(){if(R("use_typescript_transport"))tf();else if(T(If),T(Jf),Jf=0,!Xa(V)){for(var a in V){var b=Hf[a];if(b&&b.isReady()){var c=void 0,d=a,e=Ff[d],f=Math.round(U());for(c in V[d]){var h=ab({context:wf(b.f||xf())});h[e]=Of(d,c);var g=Mf[c];if(g)a:{var k=h,l=c;if(g.videoId)var n="VIDEO";else if(g.playlistId)n="PLAYLIST";else break a;k.credentialTransferTokenTargetId=g;k.context=k.context||{};k.context.user=k.context.user||{};k.context.user.credentialTransferTokens=[{token:l,scope:n}]}delete Mf[c];
g=h;g.requestTimeMs=f;R("unsplit_gel_payloads_in_logs")&&(g.unsplitGelPayloadsInLogs=!0);if(n=Q("EVENT_ID",void 0))k=Q("BATCH_CLIENT_COUNTER",void 0)||0,!k&&R("web_client_counter_random_seed")&&(k=Math.floor(Math.random()*Cf/2)),k++,k>Cf&&(k=1),P("BATCH_CLIENT_COUNTER",k),n={serializedEventId:n,clientCounter:k},g.serializedClientEventId=n,Df&&Ef&&R("log_gel_rtt_web")&&(g.previousBatchInfo={serializedClientEventId:Df,roundtripMs:Ef}),Df=n,Ef=0;Af(b,d,h,{retry:Gf.has(d),onSuccess:Fa(Pf,U())})}delete V[a];
Lf=!1}}Xa(V)||Qf()}}
function Qf(){R("web_gel_timeout_cap")&&!Jf&&(Jf=S(Nf,6E4));T(If);var a=Q("LOGGING_BATCH_TIMEOUT",xe("web_gel_debounce_ms",1E4));R("shorten_initial_gel_batch_timeout")&&Lf&&(a=Bf);If=S(Nf,a)}
function Of(a,b){b=void 0===b?"":b;V[a]=V[a]||{};V[a][b]=V[a][b]||[];return V[a][b]}
function Pf(a){Ef=Math.round(U()-a)}
;var Rf=0;y("ytDomDomGetNextId",z("ytDomDomGetNextId")||function(){return++Rf},void 0);var Sf={stopImmediatePropagation:1,stopPropagation:1,preventMouseEvent:1,preventManipulation:1,preventDefault:1,layerX:1,layerY:1,screenX:1,screenY:1,scale:1,rotation:1,webkitMovementX:1,webkitMovementY:1};
function Tf(a){this.type="";this.state=this.source=this.data=this.currentTarget=this.relatedTarget=this.target=null;this.charCode=this.keyCode=0;this.metaKey=this.shiftKey=this.ctrlKey=this.altKey=!1;this.clientY=this.clientX=0;this.changedTouches=this.touches=null;try{if(a=a||window.event){this.event=a;for(var b in a)b in Sf||(this[b]=a[b]);var c=a.target||a.srcElement;c&&3==c.nodeType&&(c=c.parentNode);this.target=c;var d=a.relatedTarget;if(d)try{d=d.nodeName?d:null}catch(e){d=null}else"mouseover"==
this.type?d=a.fromElement:"mouseout"==this.type&&(d=a.toElement);this.relatedTarget=d;this.clientX=void 0!=a.clientX?a.clientX:a.pageX;this.clientY=void 0!=a.clientY?a.clientY:a.pageY;this.keyCode=a.keyCode?a.keyCode:a.which;this.charCode=a.charCode||("keypress"==this.type?this.keyCode:0);this.altKey=a.altKey;this.ctrlKey=a.ctrlKey;this.shiftKey=a.shiftKey;this.metaKey=a.metaKey;this.f=a.pageX;this.g=a.pageY}}catch(e){}}
function Uf(a){if(document.body&&document.documentElement){var b=document.body.scrollTop+document.documentElement.scrollTop;a.f=a.clientX+(document.body.scrollLeft+document.documentElement.scrollLeft);a.g=a.clientY+b}}
Tf.prototype.preventDefault=function(){this.event&&(this.event.returnValue=!1,this.event.preventDefault&&this.event.preventDefault())};
Tf.prototype.stopPropagation=function(){this.event&&(this.event.cancelBubble=!0,this.event.stopPropagation&&this.event.stopPropagation())};
Tf.prototype.stopImmediatePropagation=function(){this.event&&(this.event.cancelBubble=!0,this.event.stopImmediatePropagation&&this.event.stopImmediatePropagation())};var Wa=z("ytEventsEventsListeners")||{};y("ytEventsEventsListeners",Wa,void 0);var Vf=z("ytEventsEventsCounter")||{count:0};y("ytEventsEventsCounter",Vf,void 0);
function Wf(a,b,c,d){d=void 0===d?{}:d;a.addEventListener&&("mouseenter"!=b||"onmouseenter"in document?"mouseleave"!=b||"onmouseenter"in document?"mousewheel"==b&&"MozBoxSizing"in document.documentElement.style&&(b="MozMousePixelScroll"):b="mouseout":b="mouseover");return Va(function(e){var f="boolean"===typeof e[4]&&e[4]==!!d,h=za(e[4])&&za(d)&&Za(e[4],d);return!!e.length&&e[0]==a&&e[1]==b&&e[2]==c&&(f||h)})}
var Xf=Sa(function(){var a=!1;try{var b=Object.defineProperty({},"capture",{get:function(){a=!0}});
window.addEventListener("test",null,b)}catch(c){}return a});
function W(a,b,c,d){d=void 0===d?{}:d;if(!a||!a.addEventListener&&!a.attachEvent)return"";var e=Wf(a,b,c,d);if(e)return e;e=++Vf.count+"";var f=!("mouseenter"!=b&&"mouseleave"!=b||!a.addEventListener||"onmouseenter"in document);var h=f?function(g){g=new Tf(g);if(!pc(g.relatedTarget,function(k){return k==a}))return g.currentTarget=a,g.type=b,c.call(a,g)}:function(g){g=new Tf(g);
g.currentTarget=a;return c.call(a,g)};
h=ke(h);a.addEventListener?("mouseenter"==b&&f?b="mouseover":"mouseleave"==b&&f?b="mouseout":"mousewheel"==b&&"MozBoxSizing"in document.documentElement.style&&(b="MozMousePixelScroll"),Xf()||"boolean"===typeof d?a.addEventListener(b,h,d):a.addEventListener(b,h,!!d.capture)):a.attachEvent("on"+b,h);Wa[e]=[a,b,c,h,d];return e}
function Yf(a){a&&("string"==typeof a&&(a=[a]),F(a,function(b){if(b in Wa){var c=Wa[b],d=c[0],e=c[1],f=c[3];c=c[4];d.removeEventListener?Xf()||"boolean"===typeof c?d.removeEventListener(e,f,c):d.removeEventListener(e,f,!!c.capture):d.detachEvent&&d.detachEvent("on"+e,f);delete Wa[b]}}))}
;var Zf=window.ytcsi&&window.ytcsi.now?window.ytcsi.now:window.performance&&window.performance.timing&&window.performance.now&&window.performance.timing.navigationStart?function(){return window.performance.timing.navigationStart+window.performance.now()}:function(){return(new Date).getTime()};function $f(a){this.w=a;this.f=null;this.j=0;this.m=null;this.l=0;this.h=[];for(a=0;4>a;a++)this.h.push(0);this.i=0;this.G=W(window,"mousemove",B(this.H,this));a=B(this.B,this);A(a)&&(a=ke(a));this.I=window.setInterval(a,25)}
D($f,M);$f.prototype.H=function(a){void 0===a.f&&Uf(a);var b=a.f;void 0===a.g&&Uf(a);this.f=new gc(b,a.g)};
$f.prototype.B=function(){if(this.f){var a=Zf();if(0!=this.j){var b=this.m,c=this.f,d=b.x-c.x;b=b.y-c.y;d=Math.sqrt(d*d+b*b)/(a-this.j);this.h[this.i]=.5<Math.abs((d-this.l)/this.l)?1:0;for(c=b=0;4>c;c++)b+=this.h[c]||0;3<=b&&this.w();this.l=d}this.j=a;this.m=this.f;this.i=(this.i+1)%4}};
$f.prototype.o=function(){window.clearInterval(this.I);Yf(this.G)};function ag(){}
function bg(a,b){return cg(a,1,b)}
;function dg(){}
q(dg,ag);function cg(a,b,c){isNaN(c)&&(c=void 0);var d=z("yt.scheduler.instance.addJob");return d?d(a,b,c):void 0===c?(a(),NaN):S(a,c||0)}
dg.prototype.start=function(){var a=z("yt.scheduler.instance.start");a&&a()};
dg.prototype.pause=function(){var a=z("yt.scheduler.instance.pause");a&&a()};
wa(dg);dg.getInstance();var eg={};
function fg(a){var b=void 0===a?{}:a;a=void 0===b.Da?!0:b.Da;b=void 0===b.Oa?!1:b.Oa;if(null==z("_lact",window)){var c=parseInt(Q("LACT"),10);c=isFinite(c)?C()-Math.max(c,0):-1;y("_lact",c,window);y("_fact",c,window);-1==c&&gg();W(document,"keydown",gg);W(document,"keyup",gg);W(document,"mousedown",gg);W(document,"mouseup",gg);a&&(b?W(window,"touchmove",function(){hg("touchmove",200)},{passive:!0}):(W(window,"resize",function(){hg("resize",200)}),W(window,"scroll",function(){hg("scroll",200)})));
new $f(function(){hg("mouse",100)});
W(document,"touchstart",gg,{passive:!0});W(document,"touchend",gg,{passive:!0})}}
function hg(a,b){eg[a]||(eg[a]=!0,bg(function(){gg();eg[a]=!1},b))}
function gg(){null==z("_lact",window)&&fg();var a=C();y("_lact",a,window);-1==z("_fact",window)&&y("_fact",a,window);(a=z("ytglobal.ytUtilActivityCallback_"))&&a()}
function ig(){var a=z("_lact",window);return null==a?-1:Math.max(C()-a,0)}
;var jg=z("ytLoggingGelSequenceIdObj_")||{};y("ytLoggingGelSequenceIdObj_",jg,void 0);
function kg(a,b,c,d){d=void 0===d?{}:d;var e={};e.eventTimeMs=Math.round(d.timestamp||U());e[a]=b;e.context={lastActivityMs:String(d.timestamp?-1:ig())};R("log_sequence_info_on_gel_web")&&d.P&&(a=e.context,b=d.P,jg[b]=b in jg?jg[b]+1:0,a.sequence={index:jg[b],groupKey:b},d.rb&&delete jg[d.P]);d=d.ca;R("use_typescript_transport")?(a="",d&&(a={},d.videoId?a.videoId=d.videoId:d.playlistId&&(a.playlistId=d.playlistId),sf[d.token]=a,a=d.token),d=rf.get(a)||[],rf.set(a,d),d.push(e),c&&(lf=new c),c=xe("web_logging_max_batch")||
100,e=U(),d.length>=c?tf():10<=e-of&&(vf(),of=e)):(d?(a={},d.videoId?a.videoId=d.videoId:d.playlistId&&(a.playlistId=d.playlistId),Mf[d.token]=a,d=Of("log_event",d.token)):d=Of("log_event"),d.push(e),c&&(Hf.log_event=new c),c=xe("web_logging_max_batch")||100,e=U(),d.length>=c?Nf():10<=e-Kf&&(Qf(),Kf=e))}
;function lg(){for(var a={},b=p(Object.entries(pe(Q("DEVICE","")))),c=b.next();!c.done;c=b.next()){var d=p(c.value);c=d.next().value;d=d.next().value;"cbrand"===c?a.deviceMake=d:"cmodel"===c?a.deviceModel=d:"cbr"===c?a.browserName=d:"cbrver"===c?a.browserVersion=d:"cos"===c?a.osName=d:"cosver"===c?a.osVersion=d:"cplatform"===c&&(a.platform=d)}return a}
;function mg(){return"INNERTUBE_API_KEY"in ce&&"INNERTUBE_API_VERSION"in ce}
function xf(){return{innertubeApiKey:Q("INNERTUBE_API_KEY",void 0),innertubeApiVersion:Q("INNERTUBE_API_VERSION",void 0),Ea:Q("INNERTUBE_CONTEXT_CLIENT_CONFIG_INFO"),Fa:Q("INNERTUBE_CONTEXT_CLIENT_NAME","WEB"),innertubeContextClientVersion:Q("INNERTUBE_CONTEXT_CLIENT_VERSION",void 0),Ha:Q("INNERTUBE_CONTEXT_HL",void 0),Ga:Q("INNERTUBE_CONTEXT_GL",void 0),Ia:Q("INNERTUBE_HOST_OVERRIDE",void 0)||"",Ja:!!Q("INNERTUBE_USE_THIRD_PARTY_AUTH",!1)}}
function wf(a){a={client:{hl:a.Ha,gl:a.Ga,clientName:a.Fa,clientVersion:a.innertubeContextClientVersion,configInfo:a.Ea}};var b=window.devicePixelRatio;b&&1!=b&&(a.client.screenDensityFloat=String(b));b=Q("EXPERIMENTS_TOKEN","");""!==b&&(a.client.experimentsToken=b);b=[];var c=Q("EXPERIMENTS_FORCED_FLAGS",{});for(d in c)b.push({key:d,value:String(c[d])});var d=Q("EXPERIMENT_FLAGS",{});for(var e in d)e.startsWith("force_")&&void 0===c[e]&&b.push({key:e,value:String(d[e])});0<b.length&&(a.request={internalExperimentFlags:b});
Q("DELEGATED_SESSION_ID")&&!R("pageid_as_header_web")&&(a.user={onBehalfOfUser:Q("DELEGATED_SESSION_ID")});a.client=Object.assign(a.client,lg());return a}
function ng(a,b,c){c=void 0===c?{}:c;var d={"X-Goog-Visitor-Id":c.visitorData||Q("VISITOR_DATA","")};if(b&&b.includes("www.youtube-nocookie.com"))return d;(b=c.ob||Q("AUTHORIZATION"))||(a?b="Bearer "+z("gapi.auth.getToken")().nb:b=Gc([]));b&&(d.Authorization=b,d["X-Goog-AuthUser"]=Q("SESSION_INDEX",0),R("pageid_as_header_web")&&(d["X-Goog-PageId"]=Q("DELEGATED_SESSION_ID")));return d}
function og(a){a=Object.assign({},a);delete a.Authorization;var b=Gc();if(b){var c=new Zc;c.update(Q("INNERTUBE_API_KEY",void 0));c.update(b);b=c.digest();c=3;ya(b);void 0===c&&(c=0);if(!ac){ac={};for(var d="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789".split(""),e=["+/=","+/","-_=","-_.","-_"],f=0;5>f;f++){var h=d.concat(e[f].split(""));$b[f]=h;for(var g=0;g<h.length;g++){var k=h[g];void 0===ac[k]&&(ac[k]=g)}}}c=$b[c];d=[];for(e=0;e<b.length;e+=3){var l=b[e],n=(f=e+1<b.length)?
b[e+1]:0;k=(h=e+2<b.length)?b[e+2]:0;g=l>>2;l=(l&3)<<4|n>>4;n=(n&15)<<2|k>>6;k&=63;h||(k=64,f||(n=64));d.push(c[g],c[l],c[n]||"",c[k]||"")}a.hash=d.join("")}return a}
;function pg(a,b,c,d){ec.set(""+a,b,{la:c,path:"/",domain:void 0===d?"youtube.com":d,secure:!1})}
;function qg(){var a=new Vd;(a=a.isAvailable()?new ae(a,"yt.innertube"):null)||(a=new Wd("yt.innertube"),a=a.isAvailable()?a:null);this.f=a?new Rd(a):null;this.g=document.domain||window.location.hostname}
qg.prototype.set=function(a,b,c,d){c=c||31104E3;this.remove(a);if(this.f)try{this.f.set(a,b,C()+1E3*c);return}catch(f){}var e="";if(d)try{e=escape(nd(b))}catch(f){return}else e=escape(b);pg(a,e,c,this.g)};
qg.prototype.get=function(a,b){var c=void 0,d=!this.f;if(!d)try{c=this.f.get(a)}catch(e){d=!0}if(d&&(c=ec.get(""+a,void 0))&&(c=unescape(c),b))try{c=JSON.parse(c)}catch(e){this.remove(a),c=void 0}return c};
qg.prototype.remove=function(a){this.f&&this.f.remove(a);var b=this.g;ec.remove(""+a,"/",void 0===b?"youtube.com":b)};var rg=new qg;function sg(a,b,c,d){if(d)return null;d=rg.get("nextId",!0)||1;var e=rg.get("requests",!0)||{};e[d]={method:a,request:b,authState:og(c),requestTime:Math.round(U())};rg.set("nextId",d+1,86400,!0);rg.set("requests",e,86400,!0);return d}
function tg(a){var b=rg.get("requests",!0)||{};delete b[a];rg.set("requests",b,86400,!0)}
function ug(a){var b=rg.get("requests",!0);if(b){for(var c in b){var d=b[c];if(!(6E4>Math.round(U())-d.requestTime)){var e=d.authState,f=og(ng(!1));Za(e,f)&&(e=d.request,"requestTimeMs"in e&&(e.requestTimeMs=Math.round(U())),Af(a,d.method,e,{}));delete b[c]}}rg.set("requests",b,86400,!0)}}
;function vg(a){var b=this;this.f=null;a?this.f=a:mg()&&(this.f=xf());cg(function(){ug(b)},0,5E3)}
vg.prototype.isReady=function(){!this.f&&mg()&&(this.f=xf());return!!this.f};
function Af(a,b,c,d){!Q("VISITOR_DATA")&&"visitor_id"!==b&&.01>Math.random()&&me(Error("Missing VISITOR_DATA when sending innertube request."));var e={headers:{"Content-Type":"application/json"},method:"POST",A:c,qa:"JSON",O:function(){d.O()},
oa:d.O,onSuccess:function(w,t){if(d.onSuccess)d.onSuccess(t)},
na:function(w){if(d.onSuccess)d.onSuccess(w)},
onError:function(w,t){if(d.onError)d.onError(t)},
vb:function(w){if(d.onError)d.onError(w)},
timeout:d.timeout,withCredentials:!0},f="",h=a.f.Ia;h&&(f=h);h=a.f.Ja||!1;var g=ng(h,f,d);Object.assign(e.headers,g);e.headers.Authorization&&!f&&(e.headers["x-origin"]=window.location.origin);var k=qe(""+f+("/youtubei/"+a.f.innertubeApiVersion+"/"+b),{alt:"json",key:a.f.innertubeApiKey}),l;if(d.retry&&R("retry_web_logging_batches")&&"www.youtube-nocookie.com"!=f&&(l=sg(b,c,g,h))){var n=e.onSuccess,r=e.na;e.onSuccess=function(w,t){tg(l);n(w,t)};
c.na=function(w,t){tg(l);r(w,t)}}try{R("use_fetch_for_op_xhr")?He(k,e):(e.method="POST",e.A||(e.A={}),Ke(k,e))}catch(w){if("InvalidAccessError"==w)l&&(tg(l),l=0),me(Error("An extension is blocking network request."));
else throw w;}l&&cg(function(){ug(a)},0,5E3)}
;function wg(a,b,c){c=void 0===c?{}:c;var d=vg;Q("ytLoggingEventsDefaultDisabled",!1)&&vg==vg&&(d=null);kg(a,b,d,c)}
;function xg(a,b){for(var c=[],d=1;d<arguments.length;++d)c[d-1]=arguments[d];d=Error.call(this,a);this.message=d.message;"stack"in d&&(this.stack=d.stack);this.args=[].concat(c instanceof Array?c:ba(p(c)))}
q(xg,Error);var yg=new Set,zg=0;function Ag(a){Bg(a,"WARNING")}
function Bg(a,b,c,d,e){e=void 0===e?{}:e;e.name=c||Q("INNERTUBE_CONTEXT_CLIENT_NAME",1);e.version=d||Q("INNERTUBE_CONTEXT_CLIENT_VERSION",void 0);c=e||{};b=void 0===b?"ERROR":b;b=void 0===b?"ERROR":b;d=window&&window.yterr||!1;if(a&&d&&!(5<=zg)&&(R("console_log_js_exceptions")&&(d=[],d.push("Name: "+a.name),d.push("Message: "+a.message),a.hasOwnProperty("params")&&d.push("Error Params: "+JSON.stringify(a.params)),d.push("File name: "+a.fileName),d.push("Stacktrace: "+a.stack),window.console.log(d.join("\n"),
a)),0!==a.f)){d=a.g;e=a.columnNumber;if(a.args&&a.args.length)for(var f=0,h=0;h<a.args.length;h++){var g=a.args[h],k="params."+h;f+=k.length;if(g)if(Array.isArray(g))for(var l=c,n=0;n<g.length&&!(g[n]&&(f+=Cg(n,g[n],k,l),500<f));n++);else if("object"===typeof g)for(l in l=void 0,n=c,g){if(g[l]&&(f+=Cg(l,g[l],k,n),500<f))break}else c[k]=String(JSON.stringify(g)).substring(0,500),f+=c[k].length;else c[k]=String(JSON.stringify(g)).substring(0,500),f+=c[k].length;if(500<=f)break}else if(a.hasOwnProperty("params"))if(g=
a.params,"object"===typeof a.params)for(h in k=0,g){if(g[h]&&(f="params."+h,l=String(JSON.stringify(g[h])).substr(0,500),c[f]=l,k+=f.length+l.length,500<k))break}else c.params=String(JSON.stringify(g)).substr(0,500);a=bc(a);(d=d||a.stack)||(d="Not available");g={stackTrace:d};a.fileName&&(g.filename=a.fileName);h=a.lineNumber.toString();isNaN(h)||!e||isNaN(e)||(g.lineNumber=Number(h),g.columnNumber=Number(e),h=h+":"+e);window.yterr&&A(window.yterr)&&(a.params=c,window.yterr(a));if(!(yg.has(a.message)||
0<=d.indexOf("/YouTubeCenter.js")||0<=d.indexOf("/mytube.js"))){if(R("kevlar_gel_error_routing")){k=b;e={level:"ERROR_LEVEL_UNKNOWN",message:a.message};"ERROR"===k?e.level="ERROR_LEVEL_ERROR":"WARNING"===k&&(e.level="ERROR_LEVEL_WARNNING");g={isObfuscated:!0,browserStackInfo:g};k={pageUrl:window.location.href,kvPairs:[]};f=p(Object.keys(c));for(l=f.next();!l.done;l=f.next())l=l.value,k.kvPairs.push({key:"client."+l,value:String(c[l])});wg("clientError",{errorMetadata:k,stackTrace:g,logMessage:e});
Nf()}b={Za:{a:"logerror",t:"jserror",type:a.name,msg:a.message.substr(0,250),line:h,level:b,"client.name":c.name},A:{url:Q("PAGE_NAME",window.location.href),file:a.fileName},method:"POST"};c.version&&(b["client.version"]=c.version);if(b.A){d&&(b.A.stack=d);d=p(Object.keys(c));for(e=d.next();!e.done;e=d.next())e=e.value,b.A["client."+e]=c[e];if(c=Q("LATEST_ECATCHER_SERVICE_TRACKING_PARAMS",void 0))for(d=p(Object.keys(c)),e=d.next();!e.done;e=d.next())e=e.value,b.A[e]=c[e];c=Q("SERVER_NAME",void 0);
d=Q("SERVER_VERSION",void 0);c&&d&&(b.A["server.name"]=c,b.A["server.version"]=d)}Ke(Q("ECATCHER_REPORT_HOST","")+"/error_204",b);yg.add(a.message);zg++}}}
function Cg(a,b,c,d){c+="."+a;a=String(JSON.stringify(b)).substr(0,500);d[c]=a;return c.length+a.length}
;function Dg(a,b,c,d,e,f){Bg(a,void 0===b?"ERROR":b,c,d,f)}
;var Eg=window.yt&&window.yt.msgs_||window.ytcfg&&window.ytcfg.msgs||{};y("yt.msgs_",Eg,void 0);function Fg(a){be(Eg,arguments)}
;function Gg(a){a&&(a.dataset?a.dataset[Hg("loaded")]="true":a.setAttribute("data-loaded","true"))}
function Ig(a,b){return a?a.dataset?a.dataset[Hg(b)]:a.getAttribute("data-"+b):null}
var Jg={};function Hg(a){return Jg[a]||(Jg[a]=String(a).replace(/\-([a-z])/g,function(b,c){return c.toUpperCase()}))}
;var Kg=/\.vflset|-vfl[a-zA-Z0-9_+=-]+/,Lg=/-[a-zA-Z]{2,3}_[a-zA-Z]{2,3}(?=(\/|$))/;function Mg(a,b,c){c=void 0===c?null:c;if(window.spf&&spf.script){c="";if(a){var d=a.indexOf("jsbin/"),e=a.lastIndexOf(".js"),f=d+6;-1<d&&-1<e&&e>f&&(c=a.substring(f,e),c=c.replace(Kg,""),c=c.replace(Lg,""),c=c.replace("debug-",""),c=c.replace("tracing-",""))}spf.script.load(a,c,b)}else Ng(a,b,c)}
function Ng(a,b,c){c=void 0===c?null:c;var d=Og(a),e=document.getElementById(d),f=e&&Ig(e,"loaded"),h=e&&!f;f?b&&b():(b&&(f=$e(d,b),b=""+Aa(b),Pg[b]=f),h||(e=Qg(a,d,function(){Ig(e,"loaded")||(Gg(e),cf(d),S(Fa(df,d),0))},c)))}
function Qg(a,b,c,d){d=void 0===d?null:d;var e=mc(document,"SCRIPT");e.id=b;e.onload=function(){c&&setTimeout(c,0)};
e.onreadystatechange=function(){switch(e.readyState){case "loaded":case "complete":e.onload()}};
d&&e.setAttribute("nonce",d);Cb(e,qc(a));a=document.getElementsByTagName("head")[0]||document.body;a.insertBefore(e,a.firstChild);return e}
function Rg(a){a=Og(a);var b=document.getElementById(a);b&&(df(a),b.parentNode.removeChild(b))}
function Sg(a,b){if(a&&b){var c=""+Aa(b);(c=Pg[c])&&bf(c)}}
function Og(a){var b=document.createElement("a");Bb(b,a);a=b.href.replace(/^[a-zA-Z]+:\/\//,"//");return"js-"+Eb(a)}
var Pg={};var Tg=[],Ug=!1;function Vg(){if("1"!=Ua(de(),"args","privembed")){var a=function(){Ug=!0;"google_ad_status"in window?P("DCLKSTAT",1):P("DCLKSTAT",2)};
Mg("//static.doubleclick.net/instream/ad_status.js",a);Tg.push(bg(function(){Ug||"google_ad_status"in window||(Sg("//static.doubleclick.net/instream/ad_status.js",a),Ug=!0,P("DCLKSTAT",3))},5E3))}}
function Wg(){return parseInt(Q("DCLKSTAT",0),10)}
;function Xg(){this.g=!1;this.f=null}
Xg.prototype.initialize=function(a,b,c,d,e,f){var h=this;f=void 0===f?!1:f;b?(this.g=!0,Mg(b,function(){h.g=!1;window.botguard?Yg(h,c,d,f):(Rg(b),Ag(new xg("Unable to load Botguard","from "+b)))},e)):a&&(eval(a),window.botguard?Yg(this,c,d,f):Ag(Error("Unable to load Botguard from JS")))};
function Yg(a,b,c,d){if(d)try{a.f=new window.botguard.bg(b,c?function(){return c(b)}:va)}catch(e){Ag(e)}else{try{a.f=new window.botguard.bg(b)}catch(e){Ag(e)}c&&c(b)}}
Xg.prototype.dispose=function(){this.f=null};var Zg=new Xg,$g=!1,ah=0,bh="";function ch(a){R("botguard_periodic_refresh")?ah=U():R("botguard_always_refresh")&&(bh=a)}
function dh(a){if(a){if(Zg.g)return!1;if(R("botguard_periodic_refresh"))return 72E5<U()-ah;if(R("botguard_always_refresh"))return bh!=a}else return!1;return!$g}
function eh(){return!!Zg.f}
function fh(a){a=void 0===a?{}:a;a=void 0===a?{}:a;return Zg.f?Zg.f.invoke(void 0,void 0,a):null}
;var gh=C().toString();
function hh(){a:{if(window.crypto&&window.crypto.getRandomValues)try{var a=Array(16),b=new Uint8Array(16);window.crypto.getRandomValues(b);for(var c=0;c<a.length;c++)a[c]=b[c];var d=a;break a}catch(e){}d=Array(16);for(a=0;16>a;a++){b=C();for(c=0;c<b%23;c++)d[a]=Math.random();d[a]=Math.floor(256*Math.random())}if(gh)for(a=1,b=0;b<gh.length;b++)d[a%16]=d[a%16]^d[(a-1)%16]/4^gh.charCodeAt(b),a++}a=[];for(b=0;b<d.length;b++)a.push("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_".charAt(d[b]&63));
return a.join("")}
;var ih=z("ytLoggingDocDocumentNonce_")||hh();y("ytLoggingDocDocumentNonce_",ih,void 0);var jh=1;function kh(a){this.f=a}
function lh(a){var b={};void 0!==a.f.trackingParams?b.trackingParams=a.f.trackingParams:(b.veType=a.f.veType,void 0!==a.f.veCounter&&(b.veCounter=a.f.veCounter),void 0!==a.f.elementIndex&&(b.elementIndex=a.f.elementIndex));void 0!==a.f.dataElement&&(b.dataElement=lh(a.f.dataElement));void 0!==a.f.youtubeData&&(b.youtubeData=a.f.youtubeData);return b}
kh.prototype.toString=function(){return JSON.stringify(lh(this))};function mh(a){a=void 0===a?0:a;return 0==a?"client-screen-nonce":"client-screen-nonce."+a}
function nh(a){a=void 0===a?0:a;return 0==a?"ROOT_VE_TYPE":"ROOT_VE_TYPE."+a}
function oh(a){return Q(nh(void 0===a?0:a),void 0)}
y("yt_logging_screen.getRootVeType",oh,void 0);function ph(){var a=oh(0),b;a?b=new kh({veType:a,youtubeData:void 0}):b=null;return b}
function qh(){var a=Q("csn-to-ctt-auth-info");a||(a={},P("csn-to-ctt-auth-info",a));return a}
function rh(a){a=void 0===a?0:a;var b=Q(mh(a));if(!b&&!Q("USE_CSN_FALLBACK",!0))return null;b||0!=a||(R("kevlar_client_side_screens")||R("c3_client_side_screens")?b="UNDEFINED_CSN":b=Q("EVENT_ID"));return b?b:null}
y("yt_logging_screen.getCurrentCsn",rh,void 0);function sh(a,b,c){var d=qh();(c=rh(c))&&delete d[c];b&&(d[a]=b)}
function th(a){return qh()[a]}
y("yt_logging_screen.getCttAuthInfo",th,void 0);function uh(a,b,c,d){c=void 0===c?0:c;if(a!==Q(mh(c))||b!==Q(nh(c)))if(sh(a,d,c),P(mh(c),a),P(nh(c),b),0==c||R("web_screen_associated_all_layers"))b=function(){setTimeout(function(){a&&kg("foregroundHeartbeatScreenAssociated",{clientDocumentNonce:ih,clientScreenNonce:a},vg)},0)},"requestAnimationFrame"in window?window.requestAnimationFrame(b):b()}
y("yt_logging_screen.setCurrentScreen",uh,void 0);function vh(a,b,c){b=void 0===b?{}:b;c=void 0===c?!1:c;var d=Q("EVENT_ID");d&&(b.ei||(b.ei=d));if(b){d=a;var e=void 0===e?!0:e;var f=Q("VALID_SESSION_TEMPDATA_DOMAINS",[]),h=J(K(3,window.location.href));h&&f.push(h);h=J(K(3,d));if(0<=Ka(f,h)||!h&&0==d.lastIndexOf("/",0))if(R("autoescape_tempdata_url")&&(f=document.createElement("a"),Bb(f,d),d=f.href),d){h=d.match(Gb);d=h[5];f=h[6];h=h[7];var g="";d&&(g+=d);f&&(g+="?"+f);h&&(g+="#"+h);d=g;f=d.indexOf("#");if(d=0>f?d:d.substr(0,f))if(e&&!b.csn&&(b.itct||
b.ved)&&(b=Object.assign({csn:rh()},b)),k){var k=parseInt(k,10);isFinite(k)&&0<k&&(e=b,b="ST-"+Eb(d).toString(36),e=e?Ib(e):"",pg(b,e,k||5))}else k=b,e="ST-"+Eb(d).toString(36),k=k?Ib(k):"",pg(e,k,5)}}if(c)return!1;if((window.ytspf||{}).enabled)spf.navigate(a);else{var l=void 0===l?{}:l;var n=void 0===n?"":n;var r=void 0===r?window:r;c=r.location;a=Jb(a,l)+n;a=a instanceof H?a:ub(a);c.href=sb(a)}return!0}
;function wh(a,b){this.version=a;this.args=b}
;function xh(a,b){this.topic=a;this.f=b}
xh.prototype.toString=function(){return this.topic};var yh=z("ytPubsub2Pubsub2Instance")||new O;O.prototype.subscribe=O.prototype.subscribe;O.prototype.unsubscribeByKey=O.prototype.N;O.prototype.publish=O.prototype.M;O.prototype.clear=O.prototype.clear;y("ytPubsub2Pubsub2Instance",yh,void 0);var zh=z("ytPubsub2Pubsub2SubscribedKeys")||{};y("ytPubsub2Pubsub2SubscribedKeys",zh,void 0);var Ah=z("ytPubsub2Pubsub2TopicToKeys")||{};y("ytPubsub2Pubsub2TopicToKeys",Ah,void 0);var Bh=z("ytPubsub2Pubsub2IsAsync")||{};y("ytPubsub2Pubsub2IsAsync",Bh,void 0);
y("ytPubsub2Pubsub2SkipSubKey",null,void 0);function Ch(a,b){var c=Dh();c&&c.publish.call(c,a.toString(),a,b)}
function Eh(a){var b=Fh,c=Dh();if(!c)return 0;var d=c.subscribe(b.toString(),function(e,f){var h=z("ytPubsub2Pubsub2SkipSubKey");h&&h==d||(h=function(){if(zh[d])try{if(f&&b instanceof xh&&b!=e)try{var g=b.f,k=f;if(!k.args||!k.version)throw Error("yt.pubsub2.Data.deserialize(): serializedData is incomplete.");try{if(!g.F){var l=new g;g.F=l.version}var n=g.F}catch(r){}if(!n||k.version!=n)throw Error("yt.pubsub2.Data.deserialize(): serializedData version is incompatible.");try{f=Reflect.construct(g,
Qa(k.args))}catch(r){throw r.message="yt.pubsub2.Data.deserialize(): "+r.message,r;}}catch(r){throw r.message="yt.pubsub2.pubsub2 cross-binary conversion error for "+b.toString()+": "+r.message,r;}a.call(window,f)}catch(r){le(r)}},Bh[b.toString()]?z("yt.scheduler.instance")?bg(h):S(h,0):h())});
zh[d]=!0;Ah[b.toString()]||(Ah[b.toString()]=[]);Ah[b.toString()].push(d);return d}
function Gh(){var a=Hh,b=Eh(function(c){a.apply(void 0,arguments);Ih(b)});
return b}
function Ih(a){var b=Dh();b&&("number"===typeof a&&(a=[a]),F(a,function(c){b.unsubscribeByKey(c);delete zh[c]}))}
function Dh(){return z("ytPubsub2Pubsub2Instance")}
;function Jh(a){wh.call(this,1,arguments);this.csn=a}
q(Jh,wh);var Fh=new xh("screen-created",Jh),Kh=[],Lh=0;function Mh(a,b,c){var d=R("use_default_events_client")?void 0:vg;b={csn:a,parentVe:lh(b),childVes:Ma(c,function(f){return lh(f)})};
c=p(c);for(var e=c.next();!e.done;e=c.next())e=lh(e.value),(Xa(e)||!e.trackingParams&&!e.veType)&&Dg(Error("Child VE logged with no data"),"WARNING");c={ca:th(a),P:a};"UNDEFINED_CSN"==a?Nh("visualElementAttached",b,c):d?kg("visualElementAttached",b,d,c):wg("visualElementAttached",b,c)}
function Nh(a,b,c){Kh.push({payloadName:a,payload:b,options:c});Lh||(Lh=Gh())}
function Hh(a){if(Kh){for(var b=p(Kh),c=b.next();!c.done;c=b.next())c=c.value,c.payload&&(c.payload.csn=a.csn,kg(c.payloadName,c.payload,null,c.options));Kh.length=0}Lh=0}
;function Oh(a){a=a||{};var b={},c={};this.url=a.url||"";this.args=a.args||$a(b);this.assets=a.assets||{};this.attrs=a.attrs||$a(c);this.fallback=a.fallback||null;this.fallbackMessage=a.fallbackMessage||null;this.html5=!!a.html5;this.disable=a.disable||{};this.loaded=!!a.loaded;this.messages=a.messages||{}}
Oh.prototype.clone=function(){var a=new Oh,b;for(b in this)if(this.hasOwnProperty(b)){var c=this[b];"object"==xa(c)?a[b]=$a(c):a[b]=c}return a};function Ph(){M.call(this);this.f=[]}
q(Ph,M);Ph.prototype.o=function(){for(;this.f.length;){var a=this.f.pop();a.target.removeEventListener(a.name,a.pb)}M.prototype.o.call(this)};var Qh=/cssbin\/(?:debug-)?([a-zA-Z0-9_-]+?)(?:-2x|-web|-rtl|-vfl|.css)/;function Rh(a){a=a||"";if(window.spf){var b=a.match(Qh);spf.style.load(a,b?b[1]:"",void 0)}else Sh(a)}
function Sh(a){var b=Th(a),c=document.getElementById(b),d=c&&Ig(c,"loaded");d||c&&!d||(c=Uh(a,b,function(){Ig(c,"loaded")||(Gg(c),cf(b),S(Fa(df,b),0))}))}
function Uh(a,b,c){var d=document.createElement("link");d.id=b;d.onload=function(){c&&setTimeout(c,0)};
a=qc(a);d.rel="stylesheet";d.href=gb(a).toString();(document.getElementsByTagName("head")[0]||document.body).appendChild(d);return d}
function Th(a){var b=mc(document,"A");Bb(b,new H(qb,a));a=b.href.replace(/^[a-zA-Z]+:\/\//,"//");return"css-"+Eb(a)}
;function Vh(a,b,c,d){M.call(this);var e=this;this.m=this.X=a;this.U=b;this.w=!1;this.api={};this.V=this.G=null;this.H=new O;xc(this,Fa(yc,this.H));this.j={};this.R=this.W=this.h=this.ba=this.f=null;this.I=!1;this.l=this.B=null;this.Y={};this.ta=["onReady"];this.aa=null;this.ja=NaN;this.S={};this.i=d;Wh(this);this.Z("WATCH_LATER_VIDEO_ADDED",this.La.bind(this));this.Z("WATCH_LATER_VIDEO_REMOVED",this.Ma.bind(this));this.Z("onAdAnnounce",this.va.bind(this));this.ua=new Ph(this);xc(this,Fa(yc,this.ua));
this.T=0;c?this.T=S(function(){e.loadNewVideoConfig(c)},0):d&&(Xh(this),Yh(this))}
q(Vh,M);m=Vh.prototype;m.getId=function(){return this.U};
m.loadNewVideoConfig=function(a){if(!this.g){this.T&&(T(this.T),this.T=0);a instanceof Oh||(a=new Oh(a));this.ba=a;this.f=a.clone();Xh(this);this.W||(this.W=Zh(this,this.f.args.jsapicallback||"onYouTubePlayerReady"));this.f.args.jsapicallback=null;if(a=this.f.attrs.width)this.m.style.width=Ac(Number(a)||a);if(a=this.f.attrs.height)this.m.style.height=Ac(Number(a)||a);Yh(this);this.w&&$h(this)}};
function Xh(a){var b;a.i?b=a.i.rootElementId:b=a.f.attrs.id;a.h=b||a.h;"video-player"==a.h&&(a.h=a.U,a.f.attrs.id=a.U);a.m.id==a.h&&(a.h+="-player",a.f.attrs.id=a.h)}
m.Aa=function(){return this.ba};
function $h(a){a.f&&!a.f.loaded&&(a.f.loaded=!0,"0"!=a.f.args.autoplay?a.api.loadVideoByPlayerVars(a.f.args):a.api.cueVideoByPlayerVars(a.f.args))}
function ai(a){var b=!0,c=bi(a);c&&a.f&&(a=ci(a),b=Ig(c,"version")===a);return b&&!!z("yt.player.Application.create")}
function Yh(a){if(!a.g&&!a.I){var b=ai(a);if(b&&"html5"==(bi(a)?"html5":null))a.R="html5",a.w||di(a);else if(ei(a),a.R="html5",b&&a.l)a.X.appendChild(a.l),di(a);else{a.f&&(a.f.loaded=!0);var c=!1;a.B=function(){c=!0;if(a.i)var d=a.i.serializedExperimentFlags;else a.f&&a.f.args&&(d=a.f.args.fflags);d="true"==ne(d||"").player_bootstrap_method?z("yt.player.Application.createAlternate")||z("yt.player.Application.create"):z("yt.player.Application.create");var e=a.f?a.f.clone():void 0;d(a.X,e,a.i);di(a)};
a.I=!0;b?a.B():(Mg(ci(a),a.B),(b=a.i?a.i.cssUrl:a.f.assets.css)&&Rh(b),fi(a)&&!c&&y("yt.player.Application.create",null,void 0))}}}
function bi(a){var b=ic(a.h);!b&&a.m&&a.m.querySelector&&(b=a.m.querySelector("#"+a.h));return b}
function di(a){if(!a.g){var b=bi(a),c=!1;b&&b.getApiInterface&&b.getApiInterface()&&(c=!0);c?(a.I=!1,b.isNotServable&&a.f&&b.isNotServable(a.f.args.video_id)||gi(a)):a.ja=S(function(){di(a)},50)}}
function gi(a){Wh(a);a.w=!0;var b=bi(a);b.addEventListener&&(a.G=hi(a,b,"addEventListener"));b.removeEventListener&&(a.V=hi(a,b,"removeEventListener"));var c=b.getApiInterface();c=c.concat(b.getInternalApiInterface());for(var d=0;d<c.length;d++){var e=c[d];a.api[e]||(a.api[e]=hi(a,b,e))}for(var f in a.j)a.G(f,a.j[f]);$h(a);a.W&&a.W(a.api);a.H.M("onReady",a.api)}
function hi(a,b,c){var d=b[c];return function(){try{return a.aa=null,d.apply(b,arguments)}catch(e){"sendAbandonmentPing"!=c&&(e.params=c,a.aa=e,me(e))}}}
function Wh(a){a.w=!1;if(a.V)for(var b in a.j)a.V(b,a.j[b]);for(var c in a.S)T(parseInt(c,10));a.S={};a.G=null;a.V=null;for(var d in a.api)a.api[d]=null;a.api.addEventListener=a.Z.bind(a);a.api.removeEventListener=a.Qa.bind(a);a.api.destroy=a.dispose.bind(a);a.api.getLastError=a.Ba.bind(a);a.api.getPlayerType=a.Ca.bind(a);a.api.getCurrentVideoConfig=a.Aa.bind(a);a.api.loadNewVideoConfig=a.loadNewVideoConfig.bind(a);a.api.isReady=a.Ka.bind(a)}
m.Ka=function(){return this.w};
m.Z=function(a,b){var c=this,d=Zh(this,b);if(d){if(!(0<=Ka(this.ta,a)||this.j[a])){var e=ii(this,a);this.G&&this.G(a,e)}this.H.subscribe(a,d);"onReady"==a&&this.w&&S(function(){d(c.api)},0)}};
m.Qa=function(a,b){if(!this.g){var c=Zh(this,b);c&&Ld(this.H,a,c)}};
function Zh(a,b){var c=b;if("string"==typeof b){if(a.Y[b])return a.Y[b];c=function(){var d=z(b);d&&d.apply(x,arguments)};
a.Y[b]=c}return c?c:null}
function ii(a,b){var c="ytPlayer"+b+a.U;a.j[b]=c;x[c]=function(d){var e=S(function(){if(!a.g){a.H.M(b,d);var f=a.S,h=String(e);h in f&&delete f[h]}},0);
Ya(a.S,String(e))};
return c}
m.va=function(a){cf("a11y-announce",a)};
m.La=function(a){cf("WATCH_LATER_VIDEO_ADDED",a)};
m.Ma=function(a){cf("WATCH_LATER_VIDEO_REMOVED",a)};
m.Ca=function(){return this.R||(bi(this)?"html5":null)};
m.Ba=function(){return this.aa};
function ei(a){a.cancel();Wh(a);a.R=null;a.f&&(a.f.loaded=!1);var b=bi(a);b&&(ai(a)||!fi(a)?a.l=b:(b&&b.destroy&&b.destroy(),a.l=null));for(a=a.X;b=a.firstChild;)a.removeChild(b)}
m.cancel=function(){this.B&&Sg(ci(this),this.B);T(this.ja);this.I=!1};
m.o=function(){ei(this);if(this.l&&this.f&&this.l.destroy)try{this.l.destroy()}catch(b){le(b)}this.Y=null;for(var a in this.j)x[this.j[a]]=null;this.ba=this.f=this.api=null;delete this.X;delete this.m;M.prototype.o.call(this)};
function fi(a){return a.f&&a.f.args&&a.f.args.fflags?-1!=a.f.args.fflags.indexOf("player_destroy_old_version=true"):!1}
function ci(a){return a.i?a.i.jsUrl:a.f.assets.js}
;var ji={},ki="player_uid_"+(1E9*Math.random()>>>0);function li(a){delete ji[a.getId()]}
;function mi(a,b){for(var c=[],d=1;d<arguments.length;++d)c[d-1]=arguments[d];if(!ni(a)||c.some(function(e){return!ni(e)}))throw Error("Only objects may be merged.");
c=p(c);for(d=c.next();!d.done;d=c.next())oi(a,d.value);return a}
function oi(a,b){for(var c in b)if(ni(b[c])){if(c in a&&!ni(a[c]))throw Error("Cannot merge an object into a non-object.");c in a||(a[c]={});oi(a[c],b[c])}else if(pi(b[c])){if(c in a&&!pi(a[c]))throw Error("Cannot merge an array into a non-array.");c in a||(a[c]=[]);qi(a[c],b[c])}else a[c]=b[c];return a}
function qi(a,b){for(var c=p(b),d=c.next();!d.done;d=c.next())d=d.value,ni(d)?a.push(oi({},d)):pi(d)?a.push(qi([],d)):a.push(d);return a}
function ni(a){return"object"===typeof a&&!Array.isArray(a)}
function pi(a){return"object"===typeof a&&Array.isArray(a)}
;function ri(a,b){wh.call(this,1,arguments)}
q(ri,wh);function si(a,b){wh.call(this,1,arguments)}
q(si,wh);var ti=new xh("aft-recorded",ri),ui=new xh("timing-sent",si);var vi=window;function wi(){this.timing={};this.clearResourceTimings=function(){};
this.webkitClearResourceTimings=function(){};
this.mozClearResourceTimings=function(){};
this.msClearResourceTimings=function(){};
this.oClearResourceTimings=function(){}}
var xi=vi.performance||vi.mozPerformance||vi.msPerformance||vi.webkitPerformance||new wi;var yi=!1;B(xi.clearResourceTimings||xi.webkitClearResourceTimings||xi.mozClearResourceTimings||xi.msClearResourceTimings||xi.oClearResourceTimings||va,xi);function zi(a){var b=Ai(a);if(b.aft)return b.aft;a=Q((a||"")+"TIMING_AFT_KEYS",["ol"]);for(var c=a.length,d=0;d<c;d++){var e=b[a[d]];if(e)return e}return NaN}
function Bi(a){var b;(b=z("ytcsi."+(a||"")+"data_"))||(b={tick:{},info:{}},Ga("ytcsi."+(a||"")+"data_",b));return b}
function Ci(a){a=Bi(a);a.info||(a.info={});return a.info}
function Ai(a){a=Bi(a);a.tick||(a.tick={});return a.tick}
function Di(a){var b=Bi(a).nonce;b||(b=hh(),Bi(a).nonce=b);return b}
function Ei(a){var b=Ai(a||""),c=zi(a);c&&!yi&&(Ch(ti,new ri(Math.round(c-b._start),a)),yi=!0)}
;function Fi(){var a=z("ytcsi.debug");a||(a=[],y("ytcsi.debug",a,void 0),y("ytcsi.reference",{},void 0));return a}
function Gi(a){a=a||"";var b=z("ytcsi.reference");b||(Fi(),b=z("ytcsi.reference"));if(b[a])return b[a];var c=Fi(),d={timerName:a,info:{},tick:{},span:{}};c.push(d);return b[a]=d}
;var Hi=z("ytLoggingLatencyUsageStats_")||{};y("ytLoggingLatencyUsageStats_",Hi,void 0);function Ii(){this.f=0}
function Ji(){Ii.instance||(Ii.instance=new Ii);return Ii.instance}
Ii.prototype.tick=function(a,b,c){Ki(this,"tick_"+a+"_"+b)||wg("latencyActionTicked",{tickName:a,clientActionNonce:b},{timestamp:c})};
Ii.prototype.info=function(a,b){var c=Object.keys(a).join("");Ki(this,"info_"+c+"_"+b)||(a.clientActionNonce=b,wg("latencyActionInfo",a))};
Ii.prototype.span=function(a,b){var c=Object.keys(a).join("");Ki(this,"span_"+c+"_"+b)||(a.clientActionNonce=b,wg("latencyActionSpan",a))};
function Ki(a,b){Hi[b]=Hi[b]||{count:0};var c=Hi[b];c.count++;c.time=U();a.f||(a.f=cg(function(){var d=U(),e;for(e in Hi)Hi[e]&&6E4<d-Hi[e].time&&delete Hi[e];a&&(a.f=0)},0,5E3));
return 5<c.count?(6===c.count&&1>1E5*Math.random()&&(c=new xg("CSI data exceeded logging limit with key",b),0===b.indexOf("info")?Ag(c):Bg(c)),!0):!1}
;var Y={},Li=(Y.ad_allowed="adTypesAllowed",Y.yt_abt="adBreakType",Y.ad_cpn="adClientPlaybackNonce",Y.ad_docid="adVideoId",Y.yt_ad_an="adNetworks",Y.ad_at="adType",Y.browse_id="browseId",Y.p="httpProtocol",Y.t="transportProtocol",Y.cpn="clientPlaybackNonce",Y.ccs="creatorInfo.creatorCanaryState",Y.cseg="creatorInfo.creatorSegment",Y.csn="clientScreenNonce",Y.docid="videoId",Y.GetHome_rid="requestIds",Y.GetSearch_rid="requestIds",Y.GetPlayer_rid="requestIds",Y.GetWatchNext_rid="requestIds",Y.GetBrowse_rid=
"requestIds",Y.GetLibrary_rid="requestIds",Y.is_continuation="isContinuation",Y.is_nav="isNavigation",Y.b_p="kabukiInfo.browseParams",Y.is_prefetch="kabukiInfo.isPrefetch",Y.is_secondary_nav="kabukiInfo.isSecondaryNav",Y.prev_browse_id="kabukiInfo.prevBrowseId",Y.query_source="kabukiInfo.querySource",Y.voz_type="kabukiInfo.vozType",Y.yt_lt="loadType",Y.mver="creatorInfo.measurementVersion",Y.yt_ad="isMonetized",Y.nr="webInfo.navigationReason",Y.nrsu="navigationRequestedSameUrl",Y.ncnp="webInfo.nonPreloadedNodeCount",
Y.pnt="performanceNavigationTiming",Y.prt="playbackRequiresTap",Y.plt="playerInfo.playbackType",Y.pis="playerInfo.playerInitializedState",Y.paused="playerInfo.isPausedOnLoad",Y.yt_pt="playerType",Y.fmt="playerInfo.itag",Y.yt_pl="watchInfo.isPlaylist",Y.yt_pre="playerInfo.preloadType",Y.yt_ad_pr="prerollAllowed",Y.pa="previousAction",Y.yt_red="isRedSubscriber",Y.rce="mwebInfo.responseContentEncoding",Y.scrh="screenHeight",Y.scrw="screenWidth",Y.st="serverTimeMs",Y.aq="tvInfo.appQuality",Y.br_trs="tvInfo.bedrockTriggerState",
Y.kebqat="kabukiInfo.earlyBrowseRequestInfo.abandonmentType",Y.kebqa="kabukiInfo.earlyBrowseRequestInfo.adopted",Y.label="tvInfo.label",Y.is_mdx="tvInfo.isMdx",Y.preloaded="tvInfo.isPreloaded",Y.upg_player_vis="playerInfo.visibilityState",Y.query="unpluggedInfo.query",Y.upg_chip_ids_string="unpluggedInfo.upgChipIdsString",Y.yt_vst="videoStreamType",Y.vph="viewportHeight",Y.vpw="viewportWidth",Y.yt_vis="isVisible",Y.rcl="mwebInfo.responseContentLength",Y.GetSettings_rid="requestIds",Y.GetTrending_rid=
"requestIds",Y.GetMusicSearchSuggestions_rid="requestIds",Y.REQUEST_ID="requestIds",Y),Mi="isContinuation isNavigation kabukiInfo.earlyBrowseRequestInfo.adopted kabukiInfo.isPrefetch kabukiInfo.isSecondaryNav isMonetized navigationRequestedSameUrl performanceNavigationTiming playerInfo.isPausedOnLoad prerollAllowed isRedSubscriber tvInfo.isMdx tvInfo.isPreloaded isVisible watchInfo.isPlaylist playbackRequiresTap".split(" "),Ni={},Oi=(Ni.ccs="CANARY_STATE_",Ni.mver="MEASUREMENT_VERSION_",Ni.pis="PLAYER_INITIALIZED_STATE_",
Ni.yt_pt="LATENCY_PLAYER_",Ni.pa="LATENCY_ACTION_",Ni.yt_vst="VIDEO_STREAM_TYPE_",Ni),Pi="all_vc ap c cver cbrand cmodel cplatform ctheme ei l_an l_mm plid srt yt_fss yt_li vpst vpni2 vpil2 icrc icrt pa GetAccountOverview_rid GetHistory_rid cmt d_vpct d_vpnfi d_vpni nsru pc pfa pfeh pftr pnc prerender psc rc start tcrt tcrc ssr vpr vps yt_abt yt_fn yt_fs yt_pft yt_pre yt_pt yt_pvis ytu_pvis yt_ref yt_sts tds".split(" ");function Qi(a){return!!Q("FORCE_CSI_ON_GEL",!1)||R("csi_on_gel")||!!Bi(a).useGel}
function Ri(a){a=Bi(a);if(!("gel"in a))a.gel={gelTicks:{},gelInfos:{}};else if(a.gel){var b=a.gel;b.gelInfos||(b.gelInfos={});b.gelTicks||(b.gelTicks={})}return a.gel}
;function Si(a,b,c){if(null!==b)if(Ci(c)[a]=b,Qi(c)){var d=b;b=Ri(c);if(b.gelInfos)b.gelInfos["info_"+a]=!0;else{var e={};b.gelInfos=(e["info_"+a]=!0,e)}if(a in Li){if(a.match("_rid")){var f=a.split("_rid")[0];a="REQUEST_ID"}b=Li[a];0<=Ka(Mi,b)&&(d=!!d);a in Oi&&"string"===typeof d&&(d=Oi[a]+d.toUpperCase());a=d;d=b.split(".");for(var h=e={},g=0;g<d.length-1;g++){var k=d[g];h[k]={};h=h[k]}h[d[d.length-1]]="requestIds"===b?[{id:a,endpoint:f}]:a;f=mi({},e)}else 0<=Ka(Pi,a)||Ag(new xg("Unknown label logged with GEL CSI",
a)),f=void 0;f&&Qi(c)&&(b=Gi(c||""),mi(b.info,f),b=Ri(c),"gelInfos"in b||(b.gelInfos={}),mi(b.gelInfos,f),c=Di(c),Ji().info(f,c))}else Gi(c||"").info[a]=b}
function Ti(a,b,c){var d=Ai(c);if(R("use_first_tick")&&Ui(a,c))return d[a];if(!b&&"_"!==a[0]){var e=a;xi.mark&&(0==e.lastIndexOf("mark_",0)||(e="mark_"+e),c&&(e+=" ("+c+")"),xi.mark(e))}e=b||U();d[a]=e;e=Ri(c);e.gelTicks&&(e.gelTicks["tick_"+a]=!0);c||b||U();if(Qi(c)){Gi(c||"").tick[a]=b||U();e=Di(c);if("_start"===a){var f=Ji();Ki(f,"baseline_"+e)||wg("latencyActionBaselined",{clientActionNonce:e},{timestamp:b})}else Ji().tick(a,e,b);Ei(c);e=!0}else e=!1;if(!e){if(!z("yt.timing."+(c||"")+"pingSent_")&&
(f=Q((c||"")+"TIMING_ACTION",void 0),e=Ai(c),z("ytglobal.timing"+(c||"")+"ready_")&&f&&Ui("_start")&&zi(c)))if(Ei(c),c)Vi(c);else{f=!0;var h=Q("TIMING_WAIT",[]);if(h.length)for(var g=0,k=h.length;g<k;++g)if(!(h[g]in e)){f=!1;break}f&&Vi(c)}Gi(c||"").tick[a]=b||U()}return d[a]}
function Ui(a,b){var c=Ai(b);return a in c}
function Vi(a){if(!Qi(a)){var b=Ai(a),c=Ci(a),d=b._start,e=Q("CSI_SERVICE_NAME","youtube"),f={v:2,s:e,action:Q((a||"")+"TIMING_ACTION",void 0)},h=c.srt;void 0!==b.srt&&delete c.srt;b.aft=zi(a);var g=Ai(a),k=g.pbr,l=g.vc;g=g.pbs;k&&l&&g&&k<l&&l<g&&Ci(a).yt_pvis&&"youtube"===e&&(Si("yt_lt","hot_bg",a),e=b.vc,k=b.pbs,delete b.aft,c.aft=Math.round(k-e));for(var n in c)"_"!==n.charAt(0)&&(f[n]=c[n]);b.ps=U();n={};e=[];for(var r in b)"_"!==r.charAt(0)&&(k=Math.round(b[r]-d),n[r]=k,e.push(r+"."+k));f.rt=
e.join(",");b=!!c.ap;R("debug_csi_data")&&(c=z("yt.timing.csiData"),c||(c=[],Ga("yt.timing.csiData",c)),c.push({page:location.href,time:new Date,args:f}));c="";for(var w in f)f.hasOwnProperty(w)&&(c+="&"+w+"="+f[w]);f="/csi_204?"+c.substring(1);if(window.navigator&&window.navigator.sendBeacon&&b){var t=void 0===t?"":t;Ve(f,t)||Se(f,void 0,void 0,void 0,t)}else Se(f);y("yt.timing."+(a||"")+"pingSent_",!0,void 0);Ch(ui,new si(n.aft+(Number(h)||0),a))}}
if(R("overwrite_polyfill_on_logging_lib_loaded")){var Wi=window;Wi.ytcsi&&(Wi.ytcsi.info=Si,Wi.ytcsi.tick=Ti)};function Xi(a){return(0===a.search("cue")||0===a.search("load"))&&"loadModule"!==a}
function Yi(a,b,c){"string"===typeof a&&(a={mediaContentUrl:a,startSeconds:b,suggestedQuality:c});a:{if((b=a.mediaContentUrl)&&(b=/\/([ve]|embed)\/([^#?]+)/.exec(b))&&b[2]){b=b[2];break a}b=null}a.videoId=b;return Zi(a)}
function Zi(a,b,c){if("string"===typeof a)return{videoId:a,startSeconds:b,suggestedQuality:c};b=["endSeconds","startSeconds","mediaContentUrl","suggestedQuality","videoId"];c={};for(var d=0;d<b.length;d++){var e=b[d];a[e]&&(c[e]=a[e])}return c}
function $i(a,b,c,d){if(za(a)&&!Array.isArray(a)){b="playlist list listType index startSeconds suggestedQuality".split(" ");c={};for(d=0;d<b.length;d++){var e=b[d];a[e]&&(c[e]=a[e])}return c}b={index:b,startSeconds:c,suggestedQuality:d};"string"===typeof a&&16===a.length?b.list="PL"+a:b.playlist=a;return b}
;function aj(a){a=void 0===a?!1:a;M.call(this);this.f=new O(a);xc(this,Fa(yc,this.f))}
D(aj,M);aj.prototype.subscribe=function(a,b,c){return this.g?0:this.f.subscribe(a,b,c)};
aj.prototype.j=function(a,b){this.g||this.f.M.apply(this.f,arguments)};function bj(a,b,c){aj.call(this);this.h=a;this.i=b;this.l=c}
q(bj,aj);function cj(a,b,c){if(!a.g){var d=a.h;d.g||a.i!=d.f||(a={id:a.l,command:b},c&&(a.data=c),d.f.postMessage(nd(a),d.i))}}
bj.prototype.o=function(){this.i=this.h=null;aj.prototype.o.call(this)};function dj(a){M.call(this);this.f=a;this.f.subscribe("command",this.ra,this);this.h={};this.j=!1}
q(dj,M);m=dj.prototype;m.start=function(){this.j||this.g||(this.j=!0,cj(this.f,"RECEIVING"))};
m.ra=function(a,b,c){if(this.j&&!this.g){var d=b||{};switch(a){case "addEventListener":"string"===typeof d.event&&(a=d.event,a in this.h||(c=B(this.Sa,this,a),this.h[a]=c,this.addEventListener(a,c)));break;case "removeEventListener":"string"===typeof d.event&&ej(this,d.event);break;default:this.i.isReady()&&this.i.isExternalMethodAvailable(a,c||null)&&(b=fj(a,b||{}),c=this.i.handleExternalCall(a,b,c||null),(c=gj(a,c))&&this.j&&!this.g&&cj(this.f,a,c))}}};
m.Sa=function(a,b){this.j&&!this.g&&cj(this.f,a,this.ea(a,b))};
m.ea=function(a,b){if(null!=b)return{value:b}};
function ej(a,b){b in a.h&&(a.removeEventListener(b,a.h[b]),delete a.h[b])}
m.o=function(){var a=this.f;a.g||Ld(a.f,"command",this.ra,this);this.f=null;for(var b in this.h)ej(this,b);M.prototype.o.call(this)};function hj(a,b){dj.call(this,b);this.i=a;this.start()}
q(hj,dj);hj.prototype.addEventListener=function(a,b){this.i.addEventListener(a,b)};
hj.prototype.removeEventListener=function(a,b){this.i.removeEventListener(a,b)};
function fj(a,b){switch(a){case "loadVideoById":return b=Zi(b),[b];case "cueVideoById":return b=Zi(b),[b];case "loadVideoByPlayerVars":return[b];case "cueVideoByPlayerVars":return[b];case "loadPlaylist":return b=$i(b),[b];case "cuePlaylist":return b=$i(b),[b];case "seekTo":return[b.seconds,b.allowSeekAhead];case "playVideoAt":return[b.index];case "setVolume":return[b.volume];case "setPlaybackQuality":return[b.suggestedQuality];case "setPlaybackRate":return[b.suggestedRate];case "setLoop":return[b.loopPlaylists];
case "setShuffle":return[b.shufflePlaylist];case "getOptions":return[b.module];case "getOption":return[b.module,b.option];case "setOption":return[b.module,b.option,b.value];case "handleGlobalKeyDown":return[b.keyCode,b.shiftKey,b.ctrlKey,b.altKey,b.metaKey,b.key,b.code]}return[]}
function gj(a,b){switch(a){case "isMuted":return{muted:b};case "getVolume":return{volume:b};case "getPlaybackRate":return{playbackRate:b};case "getAvailablePlaybackRates":return{availablePlaybackRates:b};case "getVideoLoadedFraction":return{videoLoadedFraction:b};case "getPlayerState":return{playerState:b};case "getCurrentTime":return{currentTime:b};case "getPlaybackQuality":return{playbackQuality:b};case "getAvailableQualityLevels":return{availableQualityLevels:b};case "getDuration":return{duration:b};
case "getVideoUrl":return{videoUrl:b};case "getVideoEmbedCode":return{videoEmbedCode:b};case "getPlaylist":return{playlist:b};case "getPlaylistIndex":return{playlistIndex:b};case "getOptions":return{options:b};case "getOption":return{option:b}}}
hj.prototype.ea=function(a,b){switch(a){case "onReady":return;case "onStateChange":return{playerState:b};case "onPlaybackQualityChange":return{playbackQuality:b};case "onPlaybackRateChange":return{playbackRate:b};case "onError":return{errorCode:b}}return dj.prototype.ea.call(this,a,b)};
hj.prototype.o=function(){dj.prototype.o.call(this);delete this.i};function ij(a,b,c){M.call(this);var d=this;c=c||Q("POST_MESSAGE_ORIGIN",void 0)||window.document.location.protocol+"//"+window.document.location.hostname;this.h=b||null;this.w="*";this.i=c;this.sessionId=null;this.channel="widget";this.B=!!a;this.m=function(e){a:if(!("*"!=d.i&&e.origin!=d.i||d.h&&e.source!=d.h||"string"!==typeof e.data)){try{var f=JSON.parse(e.data)}catch(h){break a}if(!(null==f||d.B&&(d.sessionId&&d.sessionId!=f.id||d.channel&&d.channel!=f.channel))&&f)switch(f.event){case "listening":"null"!=
e.origin&&(d.i=d.w=e.origin);d.h=e.source;d.sessionId=f.id;d.f&&(d.f(),d.f=null);break;case "command":d.j&&(!d.l||0<=Ka(d.l,f.func))&&d.j(f.func,f.args,e.origin)}}};
this.l=this.f=this.j=null;window.addEventListener("message",this.m)}
q(ij,M);ij.prototype.sendMessage=function(a,b){var c=b||this.h;if(c){this.sessionId&&(a.id=this.sessionId);this.channel&&(a.channel=this.channel);try{var d=JSON.stringify(a);c.postMessage(d,this.w)}catch(e){me(e)}}};
ij.prototype.o=function(){window.removeEventListener("message",this.m);M.prototype.o.call(this)};function jj(){var a=this.g=new ij(!!Q("WIDGET_ID_ENFORCE")),b=B(this.Pa,this);a.j=b;a.l=null;this.g.channel="widget";if(a=Q("WIDGET_ID"))this.g.sessionId=a;this.i=[];this.l=!1;this.j={}}
m=jj.prototype;m.Pa=function(a,b,c){"addEventListener"==a&&b?(a=b[0],this.j[a]||"onReady"==a||(this.addEventListener(a,kj(this,a)),this.j[a]=!0)):this.ma(a,b,c)};
m.ma=function(){};
function kj(a,b){return B(function(c){this.sendMessage(b,c)},a)}
m.addEventListener=function(){};
m.za=function(){this.l=!0;this.sendMessage("initialDelivery",this.fa());this.sendMessage("onReady");F(this.i,this.sa,this);this.i=[]};
m.fa=function(){return null};
function lj(a,b){a.sendMessage("infoDelivery",b)}
m.sa=function(a){this.l?this.g.sendMessage(a):this.i.push(a)};
m.sendMessage=function(a,b){this.sa({event:a,info:void 0==b?null:b})};
m.dispose=function(){this.g=null};function mj(a){jj.call(this);this.f=a;this.h=[];this.addEventListener("onReady",B(this.Na,this));this.addEventListener("onVideoProgress",B(this.Wa,this));this.addEventListener("onVolumeChange",B(this.Xa,this));this.addEventListener("onApiChange",B(this.Ra,this));this.addEventListener("onPlaybackQualityChange",B(this.Ta,this));this.addEventListener("onPlaybackRateChange",B(this.Ua,this));this.addEventListener("onStateChange",B(this.Va,this));this.addEventListener("onWebglSettingsChanged",B(this.Ya,
this))}
q(mj,jj);m=mj.prototype;m.ma=function(a,b,c){if(this.f.isExternalMethodAvailable(a,c)){b=b||[];if(0<b.length&&Xi(a)){var d=b;if(za(d[0])&&!Array.isArray(d[0]))d=d[0];else{var e={};switch(a){case "loadVideoById":case "cueVideoById":e=Zi.apply(window,d);break;case "loadVideoByUrl":case "cueVideoByUrl":e=Yi.apply(window,d);break;case "loadPlaylist":case "cuePlaylist":e=$i.apply(window,d)}d=e}b.length=1;b[0]=d}this.f.handleExternalCall(a,b,c);Xi(a)&&lj(this,this.fa())}};
m.Na=function(){var a=B(this.za,this);this.g.f=a};
m.addEventListener=function(a,b){this.h.push({eventType:a,listener:b});this.f.addEventListener(a,b)};
m.fa=function(){if(!this.f)return null;var a=this.f.getApiInterface();Pa(a,"getVideoData");for(var b={apiInterface:a},c=0,d=a.length;c<d;c++){var e=a[c];if(0===e.search("get")||0===e.search("is")){var f=0;0===e.search("get")?f=3:0===e.search("is")&&(f=2);f=e.charAt(f).toLowerCase()+e.substr(f+1);try{var h=this.f[e]();b[f]=h}catch(g){}}}b.videoData=this.f.getVideoData();b.currentTimeLastUpdated_=C()/1E3;return b};
m.Va=function(a){a={playerState:a,currentTime:this.f.getCurrentTime(),duration:this.f.getDuration(),videoData:this.f.getVideoData(),videoStartBytes:0,videoBytesTotal:this.f.getVideoBytesTotal(),videoLoadedFraction:this.f.getVideoLoadedFraction(),playbackQuality:this.f.getPlaybackQuality(),availableQualityLevels:this.f.getAvailableQualityLevels(),currentTimeLastUpdated_:C()/1E3,playbackRate:this.f.getPlaybackRate(),mediaReferenceTime:this.f.getMediaReferenceTime()};this.f.getVideoUrl&&(a.videoUrl=
this.f.getVideoUrl());this.f.getVideoContentRect&&(a.videoContentRect=this.f.getVideoContentRect());this.f.getProgressState&&(a.progressState=this.f.getProgressState());this.f.getPlaylist&&(a.playlist=this.f.getPlaylist());this.f.getPlaylistIndex&&(a.playlistIndex=this.f.getPlaylistIndex());this.f.getStoryboardFormat&&(a.storyboardFormat=this.f.getStoryboardFormat());lj(this,a)};
m.Ta=function(a){lj(this,{playbackQuality:a})};
m.Ua=function(a){lj(this,{playbackRate:a})};
m.Ra=function(){for(var a=this.f.getOptions(),b={namespaces:a},c=0,d=a.length;c<d;c++){var e=a[c],f=this.f.getOptions(e);b[e]={options:f};for(var h=0,g=f.length;h<g;h++){var k=f[h],l=this.f.getOption(e,k);b[e][k]=l}}this.sendMessage("apiInfoDelivery",b)};
m.Xa=function(){lj(this,{muted:this.f.isMuted(),volume:this.f.getVolume()})};
m.Wa=function(a){a={currentTime:a,videoBytesLoaded:this.f.getVideoBytesLoaded(),videoLoadedFraction:this.f.getVideoLoadedFraction(),currentTimeLastUpdated_:C()/1E3,playbackRate:this.f.getPlaybackRate(),mediaReferenceTime:this.f.getMediaReferenceTime()};this.f.getProgressState&&(a.progressState=this.f.getProgressState());lj(this,a)};
m.Ya=function(){var a={sphericalProperties:this.f.getSphericalProperties()};lj(this,a)};
m.dispose=function(){jj.prototype.dispose.call(this);for(var a=0;a<this.h.length;a++){var b=this.h[a];this.f.removeEventListener(b.eventType,b.listener)}this.h=[]};function nj(a,b,c){M.call(this);this.f=a;this.i=c;this.j=W(window,"message",B(this.l,this));this.h=new bj(this,a,b);xc(this,Fa(yc,this.h))}
q(nj,M);nj.prototype.l=function(a){var b;if(b=!this.g)if(b=a.origin==this.i)a:{b=this.f;do{b:{var c=a.source;do{if(c==b){c=!0;break b}if(c==c.parent)break;c=c.parent}while(null!=c);c=!1}if(c){b=!0;break a}b=b.opener}while(null!=b);b=!1}if(b&&(b=a.data,"string"===typeof b)){try{b=JSON.parse(b)}catch(d){return}b.command&&(c=this.h,c.g||c.j("command",b.command,b.data,a.origin))}};
nj.prototype.o=function(){Yf(this.j);this.f=null;M.prototype.o.call(this)};function oj(){var a=$a(pj),b;return Ad(new N(function(c,d){a.onSuccess=function(e){Ae(e)?c(e):d(new qj("Request failed, status="+(e&&"status"in e?e.status:-1),"net.badstatus",e))};
a.onError=function(e){d(new qj("Unknown request error","net.unknown",e))};
a.O=function(e){d(new qj("Request timed out","net.timeout",e))};
b=Ke("//googleads.g.doubleclick.net/pagead/id",a)}),function(c){c instanceof Bd&&b.abort();
return yd(c)})}
function qj(a,b){E.call(this,a+", errorCode="+b);this.errorCode=b;this.name="PromiseAjaxError"}
q(qj,E);function rj(){this.g=0;this.f=null}
rj.prototype.then=function(a,b,c){return 1===this.g&&a?(a=a.call(c,this.f),td(a)?a:sj(a)):2===this.g&&b?(a=b.call(c,this.f),td(a)?a:tj(a)):this};
rj.prototype.getValue=function(){return this.f};
rj.prototype.$goog_Thenable=!0;function tj(a){var b=new rj;a=void 0===a?null:a;b.g=2;b.f=void 0===a?null:a;return b}
function sj(a){var b=new rj;a=void 0===a?null:a;b.g=1;b.f=void 0===a?null:a;return b}
;function uj(a){E.call(this,a.message||a.description||a.name);this.isMissing=a instanceof vj;this.isTimeout=a instanceof qj&&"net.timeout"==a.errorCode;this.isCanceled=a instanceof Bd}
q(uj,E);uj.prototype.name="BiscottiError";function vj(){E.call(this,"Biscotti ID is missing from server")}
q(vj,E);vj.prototype.name="BiscottiMissingError";var pj={format:"RAW",method:"GET",timeout:5E3,withCredentials:!0},wj=null;function ge(){if("1"===Ua(de(),"args","privembed"))return yd(Error("Biscotti ID is not available in private embed mode"));wj||(wj=Ad(oj().then(xj),function(a){return yj(2,a)}));
return wj}
function xj(a){a=a.responseText;if(0!=a.lastIndexOf(")]}'",0))throw new vj;a=JSON.parse(a.substr(4));if(1<(a.type||1))throw new vj;a=a.id;he(a);wj=sj(a);zj(18E5,2);return a}
function yj(a,b){var c=new uj(b);he("");wj=tj(c);0<a&&zj(12E4,a-1);throw c;}
function zj(a,b){S(function(){Ad(oj().then(xj,function(c){return yj(b,c)}),va)},a)}
function Aj(){try{var a=z("yt.ads.biscotti.getId_");return a?a():ge()}catch(b){return yd(b)}}
;function Bj(a){if("1"!==Ua(de(),"args","privembed")){a&&fe();try{Aj().then(function(){},function(){}),S(Bj,18E5)}catch(b){le(b)}}}
;var Z=z("ytglobal.prefsUserPrefsPrefs_")||{};y("ytglobal.prefsUserPrefsPrefs_",Z,void 0);function Cj(){this.f=Q("ALT_PREF_COOKIE_NAME","PREF");var a=ec.get(""+this.f,void 0);if(a){a=decodeURIComponent(a).split("&");for(var b=0;b<a.length;b++){var c=a[b].split("="),d=c[0];(c=c[1])&&(Z[d]=c.toString())}}}
m=Cj.prototype;m.get=function(a,b){Dj(a);Ej(a);var c=void 0!==Z[a]?Z[a].toString():null;return null!=c?c:b?b:""};
m.set=function(a,b){Dj(a);Ej(a);if(null==b)throw Error("ExpectedNotNull");Z[a]=b.toString()};
m.remove=function(a){Dj(a);Ej(a);delete Z[a]};
m.save=function(){pg(this.f,this.dump(),63072E3)};
m.clear=function(){for(var a in Z)delete Z[a]};
m.dump=function(){var a=[],b;for(b in Z)a.push(b+"="+encodeURIComponent(String(Z[b])));return a.join("&")};
function Ej(a){if(/^f([1-9][0-9]*)$/.test(a))throw Error("ExpectedRegexMatch: "+a);}
function Dj(a){if(!/^\w+$/.test(a))throw Error("ExpectedRegexMismatch: "+a);}
function Fj(a){a=void 0!==Z[a]?Z[a].toString():null;return null!=a&&/^[A-Fa-f0-9]+$/.test(a)?parseInt(a,16):null}
wa(Cj);var Gj=null,Hj=null,Ij=null,Jj={};function Kj(a){var b=a.id;a=a.ve_type;var c=jh++;a=new kh({veType:a,veCounter:c,elementIndex:void 0,dataElement:void 0,youtubeData:void 0});Jj[b]=a;b=rh();c=ph();b&&c&&Mh(b,c,[a])}
function Lj(a){var b=a.csn;a=a.root_ve_type;if(b&&a&&(uh(b,a),a=ph()))for(var c in Jj){var d=Jj[c];d&&Mh(b,a,[d])}}
function Mj(a){Jj[a.id]=new kh({trackingParams:a.tracking_params})}
function Nj(a){var b=rh(),c=Jj[a.id];if(b&&c){a=R("use_default_events_client")?void 0:vg;c={csn:b,ve:lh(c),gestureType:"INTERACTION_LOGGING_GESTURE_TYPE_GENERIC_CLICK"};var d={ca:th(b),P:b};"UNDEFINED_CSN"==b?Nh("visualElementGestured",c,d):a?kg("visualElementGestured",c,a,d):wg("visualElementGestured",c,d)}}
function Oj(a){a=a.ids;var b=rh();if(b)for(var c=0;c<a.length;c++){var d=Jj[a[c]];if(d){var e=b,f=R("use_default_events_client")?void 0:vg;d={csn:e,ve:lh(d),eventType:1};var h={ca:th(e),P:e};"UNDEFINED_CSN"==e?Nh("visualElementShown",d,h):f?kg("visualElementShown",d,f,h):wg("visualElementShown",d,h)}}}
;y("yt.setConfig",P,void 0);y("yt.config.set",P,void 0);y("yt.setMsg",Fg,void 0);y("yt.msgs.set",Fg,void 0);y("yt.logging.errors.log",Dg,void 0);
y("writeEmbed",function(){var a=Q("PLAYER_CONFIG",void 0);Bj(!0);"gvn"==a.args.ps&&(document.body.style.backgroundColor="transparent");var b=document.referrer,c=Q("POST_MESSAGE_ORIGIN");window!=window.top&&b&&b!=document.URL&&(a.args.loaderUrl=b);Q("LIGHTWEIGHT_AUTOPLAY")&&(a.args.autoplay="1");b="player";var d=void 0===d?!0:d;b="string"===typeof b?ic(b):b;var e=ki+"_"+Aa(b),f=ji[e];f&&d?a&&a.args&&a.args.fflags&&a.args.fflags.includes("web_player_remove_playerproxy=true")?f.api.loadVideoByPlayerVars(a.args||
null):f.loadNewVideoConfig(a):(f=new Vh(b,e,a,void 0),ji[e]=f,cf("player-added",f.api),xc(f,Fa(li,f)));a=f.api;Gj=a;a.addEventListener("onScreenChanged",Lj);a.addEventListener("onLogClientVeCreated",Kj);a.addEventListener("onLogServerVeCreated",Mj);a.addEventListener("onLogVeClicked",Nj);a.addEventListener("onLogVesShown",Oj);d=Q("POST_MESSAGE_ID","player");Q("ENABLE_JS_API")?Ij=new mj(a):Q("ENABLE_POST_API")&&"string"===typeof d&&"string"===typeof c&&(Hj=new nj(window.parent,d,c),Ij=new hj(a,Hj.h));
c=Q("BG_P",void 0);dh(c)&&(Q("BG_I")||Q("BG_IU"))&&($g=!0,Zg.initialize(Q("BG_I",null),Q("BG_IU",null),c,ch,void 0,!!Q("BG_CE",!1)));Vg()},void 0);
y("yt.www.watch.ads.restrictioncookie.spr",function(a){Se(a+"mac_204?action_fcts=1");return!0},void 0);
var Pj=ke(function(){Ti("ol",void 0,void 0);var a=Cj.getInstance(),b=!!((Fj("f"+(Math.floor(119/31)+1))||0)&67108864),c=1<window.devicePixelRatio;if(document.body&&cd(document.body,"exp-invert-logo"))if(c&&!cd(document.body,"inverted-hdpi")){var d=document.body;if(d.classList)d.classList.add("inverted-hdpi");else if(!cd(d,"inverted-hdpi")){var e=ad(d);bd(d,e+(0<e.length?" inverted-hdpi":"inverted-hdpi"))}}else!c&&cd(document.body,"inverted-hdpi")&&dd();b!=c&&(b="f"+(Math.floor(119/31)+1),d=Fj(b)||
0,d=c?d|67108864:d&-67108865,0==d?delete Z[b]:(c=d.toString(16),Z[b]=c.toString()),a.save())}),Qj=ke(function(){var a=Gj;
a&&a.sendAbandonmentPing&&a.sendAbandonmentPing();Q("PL_ATT")&&Zg.dispose();a=0;for(var b=Tg.length;a<b;a++){var c=Tg[a];if(!isNaN(c)){var d=z("yt.scheduler.instance.cancelJob");d?d(c):T(c)}}Tg.length=0;Rg("//static.doubleclick.net/instream/ad_status.js");Ug=!1;P("DCLKSTAT",0);zc(Ij,Hj);if(a=Gj)a.removeEventListener("onScreenChanged",Lj),a.removeEventListener("onLogClientVeCreated",Kj),a.removeEventListener("onLogServerVeCreated",Mj),a.removeEventListener("onLogVeClicked",Nj),a.removeEventListener("onLogVesShown",
Oj),a.destroy();Jj={}});
window.addEventListener?(window.addEventListener("load",Pj),window.addEventListener("unload",Qj)):window.attachEvent&&(window.attachEvent("onload",Pj),window.attachEvent("onunload",Qj));Ga("yt.abuse.player.botguardInitialized",z("yt.abuse.player.botguardInitialized")||eh);Ga("yt.abuse.player.invokeBotguard",z("yt.abuse.player.invokeBotguard")||fh);Ga("yt.abuse.dclkstatus.checkDclkStatus",z("yt.abuse.dclkstatus.checkDclkStatus")||Wg);
Ga("yt.player.exports.navigate",z("yt.player.exports.navigate")||vh);Ga("yt.util.activity.init",z("yt.util.activity.init")||fg);Ga("yt.util.activity.getTimeSinceActive",z("yt.util.activity.getTimeSinceActive")||ig);Ga("yt.util.activity.setTimestamp",z("yt.util.activity.setTimestamp")||gg);}).call(this);

View File

@ -0,0 +1,88 @@
/* latin-ext */
@font-face {
font-display: swap;
font-family: "MarkOT";
font-style: normal;
font-weight: normal;
src:
local("Mark OT"),
local("Mark-OT"),
url("/fonts/MarkOT/MarkOT.woff2") format("woff2");
}
@font-face {
font-display: swap;
font-family: "MarkOT";
font-style: italic;
font-weight: normal;
src:
local("Mark OT"),
local("Mark-OT"),
url("/fonts/MarkOT/MarkOT-Italic.woff2") format("woff2");
}
@font-face {
font-display: swap;
font-family: "MarkOT";
font-style: normal;
font-weight: 500;
src:
local("Mark OT"),
local("Mark-OT"),
url("/fonts/MarkOT/MarkOT-Medium.woff2") format("woff2");
}
@font-face {
font-display: swap;
font-family: "MarkOT";
font-style: italic;
font-weight: 500;
src:
local("Mark OT"),
local("Mark-OT"),
url("/fonts/MarkOT/MarkOT-MediumItalic.woff2") format("woff2");
}
@font-face {
font-display: swap;
font-family: "MarkOT";
font-style: normal;
font-weight: bold;
src:
local("Mark OT Bold"),
local("Mark-OT-Bold"),
url("/fonts/MarkOT/MarkOT-Bold.woff2") format("woff2");
}
@font-face {
font-display: swap;
font-family: "MarkOT";
font-style: italic;
font-weight: bold;
src:
local("Mark OT Bold"),
local("Mark-OT-Bold"),
url("/fonts/MarkOT/MarkOT-BoldItalic.woff2") format("woff2");
}
@font-face {
font-display: swap;
font-family: "MarkOT";
font-style: normal;
font-weight: 300;
src:
local("Mark OT Narrow Light"),
local("Mark-OT-Narrow-Light"),
url("/fonts/MarkOT/MarkOT-NarrowLight.woff2") format("woff2");
}
@font-face {
font-display: swap;
font-family: "MarkOT";
font-style: italic;
font-weight: 300;
src:
local("Mark OT Narrow Light"),
local("Mark-OT-Narrow-Light"),
url("/fonts/MarkOT/MarkOT-NarrowLightItalic.woff2") format("woff2");
}

View File

@ -0,0 +1,32 @@
#mktoStyleLoaded {
/* css load detection, do not remove */
color:#123456;
}
.mktoForm fieldset {}
.mktoForm fieldset legend{}
.mktoForm input[type=text],
.mktoForm input[type=url],
.mktoForm input[type=email],
.mktoForm input[type=tel],
.mktoForm input[type=number],
.mktoForm input[type=date]{}
.mktoForm input[type=text],
.mktoForm input[type=url],
.mktoForm input[type=email],
.mktoForm input[type=tel],
.mktoForm input[type=number],
.mktoForm input[type=date],
.mktoForm textarea.mktoField,
.mktoForm select.mktoField {
padding:2px 3px;
}
.mktoForm input[type=text]:focus,
.mktoForm input[type=url]:focus,
.mktoForm input[type=email]:focus,
.mktoForm input[type=tel]:focus,
.mktoForm input[type=number]:focus,
.mktoForm input[type=date]:focus,
.mktoForm select.mktoField:focus,
.mktoForm textarea.mktoField:focus{}

View File

@ -0,0 +1,562 @@
/* This is used to test if the stylesheet has been loaded yet*/
#mktoStyleLoaded {
background-color: #123456;
display: none;
}
.mktoForm {
text-align: left;
}
.mktoForm .mktoClear {
clear: both;
float: none;
}
.mktoForm div,
.mktoForm span,
.mktoForm label,
.mktoForm p {
text-align: left;
margin: 0;
padding: 0;
}
.mktoForm input,
.mktoForm select,
.mktoForm textarea {
margin: 0;
}
.mktoForm * {
font-family: inherit;
}
.mktoForm .mktoOffset {
float: left;
height: 1.2em;
}
.mktoForm .mktoGutter {
float: left;
height: 1.2em;
}
.mktoForm .mktoFieldWrap {
float: left;
}
.mktoForm .mktoLabel {
float: left;
line-height: 1.2em;
padding-top: 0.3em;
}
.mktoForm .mktoField {
line-height: 1.2em;
font-size: 1em;
float: left;
}
.mktoForm .mktoPlaceholder {
float: left;
}
.mktoForm .mktoLogicalField {
float: left;
}
.mktoForm fieldset {
padding: 0;
margin: 0;
}
.mktoForm fieldset legend {
margin: 0 1em 0.5em;
color: inherit;
}
.mktoForm a.mktoNotYou {
cursor: pointer;
color: #4692f3;
}
.mktoForm a.mktoNotYou:hover {
text-decoration: underline;
}
.mktoForm .mktoAsterix {
float: right;
color: #bf0000;
padding-left: 5px;
display: none;
}
.mktoForm .mktoRadioList,
.mktoForm .mktoCheckboxList {
padding: 0.3em;
float: left;
}
.mktoForm .mktoRadioList > label,
.mktoForm .mktoCheckboxList > label {
margin-left: 1.5em;
margin-top: 0.1em;
margin-bottom: 0.3em;
line-height: 1.2em;
display: block;
min-height: 12px;
}
.mktoForm.ie7 .mktoRadioList > label,
.mktoForm.ie7 .mktoCheckboxList > label {
padding: 0.2em 0 0;
}
.mktoForm .mktoRadioList > label > input,
.mktoForm .mktoCheckboxList > label > input {
float: left;
margin: 0;
margin-left: -1.5em;
}
.mktoForm .mktoRadioList > input,
.mktoForm .mktoCheckboxList > input {
padding: 0;
}
.mktoForm .mktoLabelToLeft > label {
text-align: right;
margin-left: 0;
margin-right: 1.5em;
}
.mktoForm .mktoLabelToLeft input[type=checkbox],
.mktoForm .mktoLabelToLeft input[type=radio] {
position: absolute;
right: 0.3em;
}
.mktoForm.mktoLayoutAbove .mktoRequiredField .mktoAsterix {
float: left;
padding-left: 0;
padding-right: 5px;
}
.mktoForm .mktoRequiredField .mktoAsterix {
display: block;
}
.mktoForm .mktoRequiredField label.mktoLabel {
font-weight: bold;
}
.mktoForm input[type=text],
.mktoForm input[type=url],
.mktoForm input[type=email],
.mktoForm input[type=tel],
.mktoForm input[type=number],
.mktoForm input[type=date] {
padding: 0.1em 0.2em;
line-height: 1.2em;
margin: 0;
}
.mktoForm input[type=range] {
padding: 0.25em 0;
margin: 0;
}
.mktoForm input[type=range]::-ms-tooltip {
display: none;
}
.mktoForm input[type=url],
.mktoForm input[type=text],
.mktoForm input[type=date],
.mktoForm input[type=tel],
.mktoForm input[type=email],
.mktoForm input[type=number],
.mktoForm textarea.mktoField,
.mktoForm select.mktoField {
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
.mktoForm .mktoFormRow {
clear: both;
}
.mktoForm .mktoFormCol {
float: left;
position: relative;
min-height: 2em;
}
.mktoButtonRow {
display: inline-block;
position: relative;
}
.mktoForm textarea.mktoField {
display: inline-block;
padding: 0.2em;
margin: 0;
line-height: 1.2em;
overflow: auto;
resize: none;
float: none;
}
/* Firefox computes row height wrong for the last 13 years... https://bugzilla.mozilla.org/show_bug.cgi?id=33654 */
.mktoForm textarea[rows="1"] {
height: 2em;
}
.mktoForm textarea[rows="2"] {
height: 3.4em;
}
.mktoForm textarea[rows="3"] {
height: 4.6em;
}
.mktoForm textarea[rows="4"] {
height: 5.8em;
}
.mktoForm textarea[rows="5"] {
height: 7em;
}
.mktoForm textarea[rows="6"] {
height: 8.2em;
}
.mktoForm textarea[rows="7"] {
height: 9.4em;
}
.mktoForm textarea[rows="8"] {
height: 10.6em;
}
.mktoForm.mktoLayoutCenter .mktoLabel {
text-align: right;
}
.mktoForm.mktoLayoutAbove .mktoGutter {
display: none;
}
.mktoForm.mktoLayoutAbove .mktoLabel {
text-align: left;
}
.mktoForm.mktoLayoutAbove .mktoRadioList,
.mktoForm.mktoLayoutAbove .mktoCheckboxList {
float: none;
clear: left;
}
.mktoForm.mktoLayoutAbove .mktoField,
.mktoForm.mktoLayoutAbove .mktoLogicalField {
clear: left;
}
.mktoForm.mktoLayoutAbove textarea.mktoField {
float: left;
}
.mktoForm .mktoError {
position: absolute;
z-index: 99;
color: #bf0000;
}
.mktoForm .mktoError .mktoErrorArrowWrap {
width: 16px;
height: 8px;
overflow: hidden;
position: absolute;
top: 0;
left: 5px;
z-index: 100;
}
.mktoForm.ie7 .mktoError .mktoErrorArrowWrap {
top: -8px;
}
.mktoForm .mktoError .mktoErrorArrow {
background-color: #e51b00;
border: 1px solid #9f1300;
border-right: none;
border-bottom: none;
display: inline-block;
height: 16px;
-webkit-transform: rotate(45deg);
-moz-transform: rotate(45deg);
transform: rotate(45deg);
-ms-transform: rotate(45deg);
width: 16px;
margin-top: 5px;
}
/** These two styles are for browsers that don't support css transforms */
.mktoForm .mktoError .mktoErrorArrowWrap.mktoArrowImage {
background: transparent url("../images/callout-arrow-up-red.png") top center no-repeat;
bottom: -7px;
}
.mktoForm .mktoError .mktoErrorArrowWrap.mktoArrowImage .mktoErrorArrow {
display: none;
}
.mktoForm .mktoError .mktoErrorMsg {
display: block;
margin-top: 7px;
background-color: #e51b00;
background-image: -webkit-linear-gradient(#e51b00 43%, #ba1600 100%);
background-image: -moz-linear-gradient(#e51b00 43%, #ba1600 100%);
background-image: linear-gradient(#e51b00 43%, #ba1600 100%);
background-image: -ms-linear-gradient(#e51b00 43%, #ba1600 100%);
border: 1px solid #9f1300;
-webkit-border-radius: 6px;
border-radius: 6px;
-webkit-box-shadow: rgba(0,0,0,0.65) 0 2px 7px, inset #ff3c3c 0 1px 0px;
box-shadow: rgba(0,0,0,0.65) 0 2px 7px, inset #ff3c3c 0 1px 0px;
color: #f3f3f3;
font-size: 1em;
line-height: 1.2em;
max-width: 16em;
padding: 0.4em 0.6em;
text-shadow: #901100 0 -1px 0;
}
.mktoForm .mktoError .mktoErrorMsg .mktoErrorDetail {
display: block;
}
.mktoForm button.mktoButton {
cursor: pointer;
margin: 0;
}
.mktoForm button.mktoButton:disabled {
opacity: 0.5;
-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=50)";
filter: alpha(opacity=50);
cursor: default;
}
.mktoNoJS .mktoLabel {
display: block;
padding-right: 10px;
width: 110px;
text-align: right;
}
.mktoNoJS input[type=text] {
width: 150px;
}
.mktoForm .cf_widget_socialsignon .cf_sign_on {
margin-bottom: 1.5em;
}
.mktoForm .mktoRangeField .mktoRangeValue {
zoom: 1;
float: left;
display: none;
text-align: center;
position: absolute;
z-index: 99;
color: #000;
}
.mktoForm.ie7 .mktoRangeField .mktoRangeValue,
.mktoForm.ie6 .mktoRangeField .mktoRangeValue {
position: relative;
}
.mktoForm .mktoRangeField.mktoHover .mktoRangeValue {
display: block;
}
.mktoForm .mktoRangeField .mktoRangeValueArrowWrap {
width: 16px;
height: 8px;
overflow: hidden;
position: absolute;
bottom: -7px;
z-index: 100;
}
.mktoForm .mktoRangeField .mktoRangeValueArrow {
background-color: #028d05;
border: 1px solid #005602;
height: 16px;
-webkit-transform: rotate(45deg);
-moz-transform: rotate(45deg);
transform: rotate(45deg);
-ms-transform: rotate(45deg);
width: 16px;
background-color: #007d04;
border-left: none;
border-top: none;
margin-top: 5px;
position: absolute;
bottom: 5px;
}
/** These two styles are for browsers that don't support css transforms */
.mktoForm .mktoRangeField .mktoRangeValueArrowWrap.mktoArrowImage {
background: transparent url("../images/callout-arrow-down-green.png") top center no-repeat;
bottom: -7px;
}
.mktoForm .mktoRangeField .mktoRangeValueArrowWrap.mktoArrowImage .mktoRangeValueArrow {
display: none;
}
.mktoForm .mktoRangeField .mktoRangeValueText {
display: block;
background-color: #028d05;
background-image: -webkit-linear-gradient(#028d05 43%, #007d04 100%);
background-image: -moz-linear-gradient(#028d05 43%, #007d04 100%);
background-image: linear-gradient(#028d05 43%, #007d04 100%);
background-image: -ms-linear-gradient(#028d05 43%, #007d04 100%);
border: 1px solid #005602;
-webkit-border-radius: 6px;
border-radius: 6px;
-webkit-box-shadow: rgba(0,0,0,0.65) 0 2px 7px, inset #00a500 0 1px 0px;
box-shadow: rgba(0,0,0,0.65) 0 2px 7px, inset #00a500 0 1px 0px;
color: #f3f3f3;
font-size: 1em;
line-height: 1.2em;
padding: 0.4em 0.6em;
text-shadow: #005602 0 -1px 0;
text-align: center;
}
.mktoModal {
position: absolute;
top: 0;
left: 0;
right: 0;
}
.mktoModal .mktoModalMask {
position: absolute;
z-index: 10000;
top: 0;
left: 0;
right: 0;
zoom: 1;
background: rgba(0,0,0,0.5);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr=#80000000, endColorstr=#80000000);
-ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#80000000, endColorstr=#80000000)";
}
.mktoModal .mktoModalContent {
position: absolute;
z-index: 10001;
background: #fff;
padding: 10px;
}
.mktoModal .mktoModalClose {
position: absolute;
cursor: pointer;
top: -10px;
right: -10px;
background: #000;
color: #fff;
width: 19px;
height: 19px;
font-family: Arial, Helvetica, sans-serif;
font-size: 13px;
line-height: 19px;
-webkit-border-radius: 19px;
border-radius: 19px;
text-align: center;
border: 2px solid #ccc;
}
/* This part of the stylesheet is overrides for mobile browsers with screen width restrictions.
It should always be at the end of the document. */
@media only screen and (max-width: 480px) {
.mktoForm,
.mktoForm * {
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
-moz-box-sizing: border-box;
padding: 10px;
}
.mktoForm .mktoGutter,
.mktoForm .mktoOffset {
display: none;
}
.mktoForm .mktoFormCol .mktoLabel {
text-align: left;
width: 100%;
}
.mktoForm .mktoFormCol {
float: none;
}
.mktoForm .mktoFieldWrap {
float: none;
}
.mktoForm fieldset {
padding: 0 10px;
}
.mktoForm input[type=url],
.mktoForm input[type=text],
.mktoForm input[type=date],
.mktoForm input[type=tel],
.mktoForm input[type=email],
.mktoForm input[type=number],
.mktoForm textarea.mktoField,
.mktoForm select.mktoField {
width: 100%;
height: 1.5em;
line-height: 1.5em;
font-size: 18px;
}
.mktoForm select.mktoField {
height: auto;
}
.mktoForm .mktoFormRow .mktoField {
clear: left;
}
.mktoForm .mktoFormRow .mktoFormCol {
clear: both;
}
.mktoForm .mktoRadioList,
.mktoForm .mktoCheckboxList {
width: 100%;
}
.mktoForm .mktoFormRow .mktoRequiredField .mktoAsterix {
float: left;
padding-left: 0;
padding-right: 5px;
}
.mktoModal .mktoModalContent {
padding: 10px 0;
}
.mktoModal .mktoModalClose {
right: 0;
}
.mktoForm .cf_widget_socialsignon {
display: block;
}
.mktoForm .cf_widget_socialsignon .cf_sign_on {
width: 100%;
}
.mktoForm .cf_widget_socialsignon .cf_sign_on_button {
width: auto;
}
}
@media only screen and (max-width: 480px), only screen and (max-device-width: 480px), only screen and (max-device-height: 480px) {
.mktoMobileShow .mktoForm,
.mktoForm * {
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
-moz-box-sizing: border-box;
padding: 10px;
}
.mktoMobileShow .mktoForm .mktoGutter,
.mktoMobileShow .mktoForm .mktoOffset {
display: none;
}
.mktoMobileShow .mktoForm .mktoFormCol .mktoLabel {
text-align: left;
width: 100%;
}
.mktoMobileShow .mktoForm .mktoFormCol {
float: none;
}
.mktoMobileShow .mktoForm .mktoFieldWrap {
float: none;
}
.mktoMobileShow .mktoForm fieldset {
padding: 0 10px;
}
.mktoMobileShow .mktoForm input[type=url],
.mktoMobileShow .mktoForm input[type=text],
.mktoMobileShow .mktoForm input[type=date],
.mktoMobileShow .mktoForm input[type=tel],
.mktoMobileShow .mktoForm input[type=email],
.mktoMobileShow .mktoForm input[type=number],
.mktoMobileShow .mktoForm textarea.mktoField,
.mktoMobileShow .mktoForm select.mktoField {
width: 100%;
height: 1.5em;
line-height: 1.5em;
font-size: 18px;
}
.mktoMobileShow .mktoForm select.mktoField {
height: auto;
}
.mktoMobileShow .mktoForm .mktoFormRow .mktoField {
clear: left;
}
.mktoMobileShow .mktoForm .mktoFormRow .mktoFormCol {
clear: both;
}
.mktoMobileShow .mktoForm .mktoRadioList,
.mktoMobileShow .mktoForm .mktoCheckboxList {
width: 100%;
}
.mktoMobileShow .mktoForm .mktoFormRow .mktoRequiredField .mktoAsterix {
float: left;
padding-left: 0;
padding-right: 5px;
}
.mktoMobileShow .mktoModal .mktoModalContent {
padding: 10px 0;
}
.mktoMobileShow .mktoModal .mktoModalClose {
right: 0;
}
.mktoMobileShow .mktoForm .cf_widget_socialsignon {
display: block;
}
.mktoMobileShow .mktoForm .cf_widget_socialsignon .cf_sign_on {
width: 100%;
}
.mktoMobileShow .mktoForm .cf_widget_socialsignon .cf_sign_on_button {
width: auto;
}
}

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,20 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<title>Drift Messenger</title>
<!-- base href="https://js.driftt.com/deploy/assets/index.html" -->
<link rel="stylesheet" href="index_data/normalize.css">
<script type="text/javascript">
__ENV__ = "PRODUCTION"
__BUILD_ID__ = "___BUILD_ID"
</script>
<link href="index_data/widget-d0f3b1b41717c3358630.css" rel="stylesheet"><script charset="utf-8" src="index_data/react-intl-locale-data-en-68d22e6e4ef4c61f742c.js"></script><script charset="utf-8" src="index_data/drift-translations-en_US-1340bea6496365f220aa.js"></script></head>
<body>
<div id="root"><div data-reactroot="" class="widget-container body-font Lato" lang="en"><div style="position: fixed; left: -10000px; visibility: hidden;"><span style="font-weight: 400;"></span><span style="font-weight: 500;"></span><span style="font-weight: 600;"></span></div></div></div>
<script type="text/javascript" src="index_data/moment-90d9c676ca6bc1da30ce.js"></script><script type="text/javascript" src="index_data/vendors-widget-80097b52b53ff67afc56.js"></script><script type="text/javascript" src="index_data/widget-9639963b546ab9b781fc.js"></script>
</body></html>

View File

@ -0,0 +1 @@
(window.driftWebpackJsonp=window.driftWebpackJsonp||[]).push([[104],{765:function(e){e.exports={"app.async.contactPrompt":"How can we reach you?","app.async.thankYou":"Thanks for your message. We'll follow up in a bit at {email}","app.automessage.emailCaptureMessage":"Hey there! We're excited to help you out. Let us know your email address so that we can follow up in case we get disconnected.","app.automessage.emailCapturedSuccess":"Thanks for submitting your email","app.campaign.nps.detractorFeedbackApproval":"It will help us improve your experience.","app.campaign.nps.feedbackApproval":"Thank you for your feedback!","app.campaign.nps.notLikely":"not likely","app.campaign.nps.veryLikely":"very likely","app.composer.footer.chatWith":"Chat with {orgName}","app.composer.footer.meetingPoweredByDrift":"Meeting {bolt} by {drift}","app.composer.footer.poweredByDrift":"Chat {bolt} by {drift}","app.composer.disabledUseButtons":"Choose an option above...","app.composer.leaveMessage":"Leave Message","app.composer.leaveMessageForPlaceholder":"Leave a message for {name}","app.composer.leaveMessagePlaceholder":"Leave a message…","app.composer.placeholder":"Type your message…","app.composer.replyToPlaceholder":"Reply to {name}","app.composer.sendKeyHint":"{key} to send","app.composer.sendMessage":"Send Message","app.composer.submitKeyHint":"{key} to submit","app.composer.conversationRating.label":"Rate Us:","app.form.invalidEmail":"Invalid email address","app.form.label.emailAddress":"Email address","app.form.label.submit":"Submit","app.form.requiredField":"Required","app.header.title.conversations":"Conversations","app.header.title.newConversation":"New Conversation","app.meeting.hour":"hour","app.meeting.hours":"hours","app.meeting.minute":"minute","app.meeting.minutes":"minutes","app.meeting.next":"Next","app.meeting.prev":"Prev","app.meeting.retry":"Retry","app.meeting.schedule":"Schedule","app.meeting.scheduleAMeeting":"Schedule a Meeting","app.meeting.scheduleAMeetingError":"Sorry about that! We ran into an error on our end - please try again.","app.meeting.scheduleAMeetingTimePassedError":"Sorry, the time you chose has already passed! Please pick a new time.","app.meeting.scheduleAMeetingAlreadyBookedError":"Sorry, it looks like someone has already scheduled this time slot with {name}.","app.meeting.chooseNewTime":"Choose a new time","app.meeting.searchTimeZones":"Search Time Zones","app.meeting.selectADay":"Select a day","app.meeting.selectATime":"Select a time","app.meeting.timeZone":"Time Zone","app.message.attachmentCount":"{count, plural, =0 {No attachments} one {1 attachment} other {# attachments}}","app.message.deliveryStatus.delivered":"Delivered","app.message.deliveryStatus.sending":"Sending...","app.newConversation.welcomeMessage":"How can we help? We're here for you!","app.status.connected":"Connected","app.status.connecting":"Connecting","app.status.connectionFailed":"Connection failed.","app.status.connectionRetry":"Retry?","app.user.personalPronoun":"You","app.user.status.active":"active {time}","app.user.status.offline":"offline now","app.user.status.online":"online now","messenger.offlineFeedback.awayMessageDefaultCopy":"Hi there! So were away right now, but if you leave us a message well get back to you soon.","messenger.offlineFeedback.confirmationMessageDefaultCopy":"Thanks for your message! Well follow up in a bit.","messenger.offlineFeedback.form.label.emailAddress":"Email Address","messenger.offlineFeedback.form.label.message":"Message","messenger.offlineFeedback.form.label.submitAwayMode":"Leave message","system.key.enter":"enter","system.key.return":"return"}}}]);

View File

@ -0,0 +1 @@
/*! normalize.css v3.0.3 | MIT License | github.com/necolas/normalize.css */html{font-family:sans-serif;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}article,aside,details,figcaption,figure,footer,header,hgroup,main,menu,nav,section,summary{display:block}audio,canvas,progress,video{display:inline-block;vertical-align:baseline}audio:not([controls]){display:none;height:0}[hidden],template{display:none}a{background-color:transparent}a:active,a:hover{outline:0}abbr[title]{border-bottom:1px dotted}b,strong{font-weight:bold}dfn{font-style:italic}h1{font-size:2em;margin:.67em 0}mark{background:#ff0;color:#000}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sup{top:-0.5em}sub{bottom:-0.25em}img{border:0}svg:not(:root){overflow:hidden}figure{margin:1em 40px}hr{box-sizing:content-box;height:0}pre{overflow:auto}code,kbd,pre,samp{font-family:monospace,monospace;font-size:1em}button,input,optgroup,select,textarea{color:inherit;font:inherit;margin:0}button{overflow:visible}button,select{text-transform:none}button,html input[type="button"],input[type="reset"],input[type="submit"]{-webkit-appearance:button;cursor:pointer}button[disabled],html input[disabled]{cursor:default}button::-moz-focus-inner,input::-moz-focus-inner{border:0;padding:0}input{line-height:normal}input[type="checkbox"],input[type="radio"]{box-sizing:border-box;padding:0}input[type="number"]::-webkit-inner-spin-button,input[type="number"]::-webkit-outer-spin-button{height:auto}input[type="search"]{-webkit-appearance:textfield;box-sizing:content-box}input[type="search"]::-webkit-search-cancel-button,input[type="search"]::-webkit-search-decoration{-webkit-appearance:none}fieldset{border:1px solid silver;margin:0 2px;padding:.35em .625em .75em}legend{border:0;padding:0}textarea{overflow:auto}optgroup{font-weight:bold}table{border-collapse:collapse;border-spacing:0}td,th{padding:0}

View File

@ -0,0 +1,7 @@
@import url(https://fonts.googleapis.com/css?family=Lato);
@import url(https://fonts.googleapis.com/css?family=Open+Sans);
@import url(https://fonts.googleapis.com/css?family=Roboto);
@import url(https://fonts.googleapis.com/css?family=Roboto+Slab);
@import url(https://fonts.googleapis.com/css?family=Overpass);
.widget-container{position:absolute;z-index:2147483647;width:100%;height:100%;color:var(--main-gray-extra-dark);font-size:16px;overflow:hidden}.widget-container *{box-sizing:border-box}.widget-container .ConversationListItem{min-height:4.7rem}.body-font{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.body-font.Arial{font-family:Arial,sans-serif}.body-font.TimesNewRoman{font-family:Times New Roman,serif}.body-font.Helvetica{font-family:Helvetica,sans-serif}.body-font.Georgia{line-height:1.45;font-family:Georgia,serif}.body-font.Brandon{font-family:Brandon,sans-serif}.body-font.Lato{font-family:Lato,sans-serif}.body-font.OpenSans{line-height:1.35;font-family:Open Sans,sans-serif}.body-font.Roboto{line-height:1.35;font-family:Roboto,sans-serif}.body-font.RobotoSlab{line-height:1.35;font-family:Roboto Slab,serif}.body-font.Overpass{line-height:1.35;font-family:Overpass,sans-serif}@font-face{font-family:Brandon;font-weight:100;src:url(/deploy/assets/3218ac3d57047fe3632e28eb00f7f82a.woff)}@font-face{font-family:Brandon;font-weight:300;src:url(/deploy/assets/ef2178680ffbd841cc9ccca132734cea.woff)}@font-face{font-family:Brandon;font-style:normal;src:url(/deploy/assets/1c7b5698687a6a103981a7a138de218e.woff)}@font-face{font-family:Brandon;font-weight:500;src:url(/deploy/assets/8fcf55f0463126efa22257deb6f6a9ff.woff)}@font-face{font-family:Brandon;font-weight:600;src:url(/deploy/assets/4b46eb2ce75b22547575a0dc2144494e.woff)}@font-face{font-family:Brandon;font-weight:700;src:url(/deploy/assets/30c94aae563dcd7274a3ffa8b2922dcf.woff)}@font-face{font-family:Brandon;font-weight:100;font-style:italic;src:url(/deploy/assets/a9657f94314103a5f73cb2f20f79d6f4.woff)}@font-face{font-family:Brandon;font-weight:300;font-style:italic;src:url(/deploy/assets/ca2959289ab9b29c8deae0c2875c5c87.woff)}@font-face{font-family:Brandon;font-style:italic;src:url(/deploy/assets/cfff98a4f67f2ddc7a342001a4411cbf.woff)}@font-face{font-family:Brandon;font-weight:500;font-style:italic;src:url(/deploy/assets/a471cda1b9f147879536ac0e5a339816.woff)}@font-face{font-family:Brandon;font-weight:600;font-style:italic;src:url(/deploy/assets/f56e872cf4216c7b05230ed1192f5935.woff)}@font-face{font-family:Brandon;font-weight:700;font-style:italic;src:url(/deploy/assets/04bef53a7fb150514e895ea1a496cec1.woff)}
body{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-smooth:always;margin:0;padding:0;font-size:16px;-ms-touch-action:manipulation;touch-action:manipulation;pointer-events:auto}body *{box-sizing:border-box;outline:none}button,input,optgroup,select,textarea{font-family:inherit}.hidden{display:none}.invisible{visibility:hidden}.link,a{cursor:pointer;color:#0176ff;text-decoration:none}.link.active,.link:hover,a.active,a:hover{color:var(--main-blue-dark)}.link.disabled,a.disabled{pointer-events:none}:root{--main-navy-extra-light:#f2f6f8;--main-navy-extra-light-a:242,246,248;--main-navy-light:#e1eef4;--main-navy-light-a:225,238,244;--main-navy:#b5d2e1;--main-navy-a:181,210,225;--main-navy-medium:#cddbe2;--main-navy-medium-a:205,219,226;--main-navy-dark:#7695a5;--main-navy-dark-a:118,149,165;--main-navy-extra-dark:#394f5a;--main-navy-extra-dark-a:57,79,90;--main-green-light-a:229,250,240;--main-green-light:#e5faf0;--main-green-a:19,203,110;--main-green:#13cb6e;--main-green-dark-a:31,164,92;--main-green-dark:#1fa45c;--main-blue-extra-light-a:239,250,255;--main-blue-extra-light:#effaff;--main-blue-light-a:158,220,247;--main-blue-light:#9edcf7;--main-blue-a:10,91,255;--main-blue:#0a5bff;--main-blue-dark-a:9,96,197;--main-blue-dark:#0960c5;--main-white-a:255,255,255;--main-white:#fff;--main-black-a:0,0,0;--main-black:#000;--main-gray-extra-light-a:248,248,248;--main-gray-extra-light:#f8f8f8;--main-gray-light-a:238,238,238;--main-gray-light:#eee;--main-gray-a:204,204,204;--main-gray:#ccc;--main-gray-dark-a:154,154,154;--main-gray-dark:#9a9a9a;--main-gray-extra-dark-a:51,51,51;--main-gray-extra-dark:#333;--main-gray-accessible-light-a:121,139,146;--main-gray-accessible-light:#798b92;--main-gray-accessible-a:82,98,107;--main-gray-accessible:#52626b;--color-p1-6:#687882;--color-p1-7:#5d6a74;--color-p1-8:#4e5c65;--color-p1-10:#353f45;--main-teal-a:19,221,176;--main-teal:#13ddb0;--main-teal-dark-a:16,185,147;--main-teal-dark:#10b993;--main-violet-a:220,129,255;--main-violet:#dc81ff;--main-violet-dark-a:112,67,213;--main-violet-dark:#7043d5;--utility-blue-a:10,91,255;--utility-blue:#0a5bff;--utility-blue-light-a:158,220,247;--utility-blue-light:#9edcf7;--utility-red-light-a:233,46,75;--utility-red-light:#e92e4b;--utility-red-a:233,46,75;--utility-red:#e92e4b;--utility-red-dark-a:208,2,27;--utility-red-dark:#d0021b;--utility-yellow-a:254,247,158;--utility-yellow:#fef79e;--utility-yellow-light-a:255,252,217;--utility-yellow-light:#fffcd9;--utility-orange-a:245,116,3;--utility-orange:#f57403;--font-size-large:28px;--font-size-medium:21px;--font-size-small:16px;--font-size-copy:14px;--font-size-subtle:12px}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1 @@
@-webkit-keyframes modal-video{from{opacity:0}to{opacity:1}}@keyframes modal-video{from{opacity:0}to{opacity:1}}@-webkit-keyframes modal-video-inner{from{transform:translate(0,100px)}to{transform:translate(0,0)}}@keyframes modal-video-inner{from{transform:translate(0,100px)}to{transform:translate(0,0)}}.modal-video{position:fixed;top:0;left:0;width:100%;height:100%;background-color:rgba(0,0,0,.5);z-index:1000000;cursor:pointer;opacity:1;-webkit-animation-timing-function:ease-out;animation-timing-function:ease-out;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-name:modal-video;animation-name:modal-video;transition:opacity .3s ease-out}.modal-video-effect-exit{opacity:0}.modal-video-effect-exit .modal-video-movie-wrap{-ms-transform:translate(0,100px);transform:translate(0,100px)}.modal-video-body{max-width:940px;width:100%;height:100%;margin:0 auto;display:table}.modal-video-inner{display:table-cell;vertical-align:middle;width:100%;height:100%}.modal-video-movie-wrap{width:100%;height:0;position:relative;padding-bottom:56.25%;background-color:#333;-webkit-animation-timing-function:ease-out;animation-timing-function:ease-out;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-name:modal-video-inner;animation-name:modal-video-inner;-ms-transform:translate(0,0);transform:translate(0,0);transition:transform .3s ease-out}.modal-video-movie-wrap iframe{position:absolute;top:0;left:0;width:100%;height:100%}.modal-video-close-btn{position:absolute;z-index:2;top:-35px;right:-35px;display:inline-block;width:35px;height:35px;overflow:hidden;border:none;background:0 0}.modal-video-close-btn:before{-ms-transform:rotate(45deg);transform:rotate(45deg)}.modal-video-close-btn:after{-ms-transform:rotate(-45deg);transform:rotate(-45deg)}.modal-video-close-btn:after,.modal-video-close-btn:before{content:'';position:absolute;height:2px;width:100%;top:50%;left:0;margin-top:-1px;background:#fff;border-radius:5px;margin-top:-6px}html body{font-family:MarkOT,Arial,sans-serif;font-size:16px;font-weight:400;line-height:24px;color:#15202b;background-color:#fff}html p{margin:0}html img{border:0;outline:0;width:auto;max-width:100%;height:auto}html svg{width:auto;max-width:100%;height:auto}html svg text{font-family:MarkOT,Arial,sans-serif}html a{color:#257bd7}html .vidyard_tclose{right:2px;left:auto}

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.8 KiB

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1 @@
@page{size:auto;margin:15mm 5mm 25mm 5mm}footer,header nav{display:none!important}*{color:#000;background-color:#fff}a:after{content:none!important}a[href]:after{content:none!important}.single_article{text-align:left;max-width:1000px;width:100%}.single_article_header{margin-top:0;text-align:left}article.single_article p{font-size:20px}article.single_article pre code{font-size:20px}.gist .blob-code-inner{font-size:18px}.print_header{display:none}.print_header .brand_logo{display:block}.header_top{position:fixed;margin-top:-100px}.header_top .left{float:left;text-align:left;font-size:20px}.header_top .right{float:right;text-align:right;font-size:20px}.single_article_header a.author_name{font-size:22px;font-weight:700;margin:0}.single_post_banner{padding:0;margin:-200px 0 0 0;text-align:left}.single.single-post .article_time{font-size:24px;margin:0;display:block}.single_article_header{border-bottom:1px solid #000;padding:0 0 20px 0;margin:20px 0 40px 0}.single_article{max-width:100%;margin:-50px 0 0 0}article.single_article h3{font-weight:700;clear:both;font-size:28px;margin:20px 0;padding:0}article.single_article h3>span{font-weight:700!important}.gist .gist-data{border-bottom:0}.gist .gist-file{border:0;border-bottom:0}.gist .blob-wrapper table{padding:10px 20px;display:block;border:1px solid #000;max-width:100%;width:auto}.gist .blob-num{display:none}.gist table.table tr td{font-size:18px}.gist .gist-meta{display:none}span.author_label:before{content:'Author: ';display:inline-block;font-size:22px;font-weight:700;margin:0}img.left_image+p+p{clear:both}img.left_image+h3{clear:both}img.left_image{max-width:40%;width:40%;max-width:250px;width:250px;float:left}ul{display:block}

Binary file not shown.

After

Width:  |  Height:  |  Size: 124 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 89 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 115 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 213 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 164 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 175 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 47 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 86 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 104 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 145 KiB

Some files were not shown because too many files have changed in this diff Show More