diff --git a/README.md b/README.md index d16c00da..c4b75942 100644 --- a/README.md +++ b/README.md @@ -143,6 +143,7 @@ Contributions in any other form are also welcomed. - [Hyperpipe](https://codeberg.org/Hyperpipe/Hyperpipe) - an alternative privacy respecting frontend for YouTube Music. - [Musicale](https://github.com/Bellisario/musicale) - an alternative to YouTube Music, with style. - [ytify](https://github.com/n-ce/ytify) - a complementary minimal audio streaming frontend for YouTube. +- [PsTube](https://github.com/prateekmedia/pstube) - Watch and download videos without ads ## YourKit diff --git a/index.html b/index.html index 9e6ff884..abc042ea 100644 --- a/index.html +++ b/index.html @@ -7,6 +7,7 @@ Piped + diff --git a/package.json b/package.json index f11bea3f..35a6a7d6 100644 --- a/package.json +++ b/package.json @@ -14,11 +14,11 @@ "@fortawesome/free-solid-svg-icons": "6.3.0", "@fortawesome/vue-fontawesome": "3.0.3", "buffer": "6.0.3", - "dompurify": "3.0.0", + "dompurify": "3.0.1", "hotkeys-js": "3.10.1", "javascript-time-ago": "2.5.9", "mux.js": "6.3.0", - "shaka-player": "4.3.4", + "shaka-player": "4.3.5", "stream-browserify": "3.0.0", "vue": "3.2.47", "vue-i18n": "9.2.2", @@ -26,21 +26,21 @@ "xml-js": "1.6.11" }, "devDependencies": { - "@iconify/json": "2.2.28", + "@iconify/json": "2.2.33", "@intlify/vite-plugin-vue-i18n": "6.0.3", - "@unocss/preset-icons": "0.50.1", - "@unocss/preset-web-fonts": "0.50.1", - "@unocss/transformer-directives": "0.50.1", - "@unocss/transformer-variant-group": "0.50.1", + "@unocss/preset-icons": "0.50.4", + "@unocss/preset-web-fonts": "0.50.4", + "@unocss/transformer-directives": "0.50.4", + "@unocss/transformer-variant-group": "0.50.4", "@vitejs/plugin-legacy": "4.0.1", "@vitejs/plugin-vue": "4.0.0", "@vue/compiler-sfc": "3.2.47", - "eslint": "8.35.0", - "eslint-config-prettier": "8.6.0", + "eslint": "8.36.0", + "eslint-config-prettier": "8.7.0", "eslint-plugin-prettier": "4.2.1", "eslint-plugin-vue": "9.9.0", "prettier": "2.8.4", - "unocss": "0.50.1", + "unocss": "0.50.4", "vite": "4.1.4", "vite-plugin-eslint": "1.8.1", "vite-plugin-pwa": "0.14.4" diff --git a/src/App.vue b/src/App.vue index b59c4442..5f1282f5 100644 --- a/src/App.vue +++ b/src/App.vue @@ -34,6 +34,14 @@ export default { if (themePref == "auto") this.theme = darkModePreference.matches ? "dark" : "light"; else this.theme = themePref; + // Change title bar color based on user's theme + const themeColor = document.querySelector("meta[name='theme-color']"); + if (this.theme === "light") { + themeColor.setAttribute("content", "#FFF"); + } else { + themeColor.setAttribute("content", "#0F0F0F"); + } + // Used for the scrollbar const root = document.querySelector(":root"); this.theme == "dark" ? root.classList.add("dark") : root.classList.remove("dark"); diff --git a/src/components/PlaylistPage.vue b/src/components/PlaylistPage.vue index fac2c420..42802c9f 100644 --- a/src/components/PlaylistPage.vue +++ b/src/components/PlaylistPage.vue @@ -88,7 +88,7 @@ export default { }, }).then(json => { if (json.error) alert(json.error); - else if (json.filter(playlist => playlist.id === playlistId).length > 0) this.admin = true; + else if (json.some(playlist => playlist.id === playlistId)) this.admin = true; }); this.isPlaylistBookmarked(); }, diff --git a/src/components/PreferencesPage.vue b/src/components/PreferencesPage.vue index 65a381f7..060bc427 100644 --- a/src/components/PreferencesPage.vue +++ b/src/components/PreferencesPage.vue @@ -425,7 +425,7 @@ export default { this.fetchJson("https://piped-instances.kavin.rocks/").then(resp => { this.instances = resp; - if (this.instances.filter(instance => instance.api_url == this.apiUrl()).length == 0) + if (!this.instances.some(instance => instance.api_url == this.apiUrl())) this.instances.push({ name: "Custom Instance", api_url: this.apiUrl(), diff --git a/src/components/VideoItem.vue b/src/components/VideoItem.vue index bc2e48ba..3f58fc88 100644 --- a/src/components/VideoItem.vue +++ b/src/components/VideoItem.vue @@ -12,10 +12,10 @@ >
diff --git a/src/components/VideoPlayer.vue b/src/components/VideoPlayer.vue index ef2b2e2c..9b0ad38b 100644 --- a/src/components/VideoPlayer.vue +++ b/src/components/VideoPlayer.vue @@ -273,7 +273,7 @@ export default { const lbry = this.getPreferenceBoolean("disableLBRY", false) ? null - : this.video.videoStreams.filter(stream => stream.quality.indexOf("LBRY") !== -1)[0]; + : this.video.videoStreams.filter(stream => stream.quality.includes("LBRY"))[0]; var uri; var mime; @@ -283,9 +283,10 @@ export default { mime = "application/x-mpegURL"; } else if (this.video.audioStreams.length > 0 && !lbry && MseSupport) { if (!this.video.dash) { - const dash = ( - await import("@/utils/DashUtils.js").then(mod => mod.default) - ).generate_dash_file_from_formats(streams, this.video.duration); + const dash = (await import("../utils/DashUtils.js")).generate_dash_file_from_formats( + streams, + this.video.duration, + ); uri = "data:application/dash+xml;charset=utf-8;base64," + btoa(dash); } else { @@ -315,7 +316,7 @@ export default { uri = this.video.hls; mime = "application/x-mpegURL"; } else { - uri = this.video.videoStreams.filter(stream => stream.codec == null).slice(-1)[0].url; + uri = this.video.videoStreams.findLast(stream => stream.codec == null).url; mime = "video/mp4"; } diff --git a/src/locales/bg.json b/src/locales/bg.json new file mode 100644 index 00000000..0c588447 --- /dev/null +++ b/src/locales/bg.json @@ -0,0 +1,60 @@ +{ + "titles": { + "channels": "Канали", + "login": "Вход", + "register": "Регистрация", + "feed": "Видео емисия", + "history": "История", + "playlists": "Плейлисти", + "instance": "Инстанция", + "player": "Плейър", + "livestreams": "Излъчвания на живо", + "bookmarks": "Отметки", + "trending": "Набиращи популярност", + "account": "Профил", + "preferences": "Предпочитания", + "subscriptions": "Абонаменти" + }, + "actions": { + "most_recent": "Най-скорошен", + "unsubscribe": "Отписване - {count}", + "uses_api_from": "Използва API от ", + "skip_sponsors": "Пропускане на спонсори", + "skip_preview": "Пропускане на Преглед/Обобщение", + "skip_self_promo": "Пропускане на Самореклама/Неплатена реклама", + "min_segment_length": "Минимална дължина на сегмента (в секунди)", + "default_quality": "Качество по подразбиране", + "minimize_comments_default": "Минимизиране на коментарите по подразбиране", + "subscribe": "Абониране - {count}", + "view_subscriptions": "Преглед на абонаменти", + "sort_by": "Сортиране по:", + "least_recent": "Най-малко скорошен", + "channel_name_asc": "Име на канал (А-Я)", + "channel_name_desc": "Име на канал (Я-А)", + "back": "Назад", + "enable_sponsorblock": "Активиране на Sponsorblock", + "skip_button_only": "Показване на бутона за пропускане", + "skip_automatically": "Автоматично", + "skip_intro": "Пропускане на прекъсване/въвеждаща анимация", + "skip_outro": "Пропускане на крайни карти/надписи", + "skip_interaction": "Пропускане на Напомняне за абониране", + "skip_non_music": "Попускане Немузикален раздел в музика", + "skip_highlight": "Пропускане на акцент", + "show_markers": "Показване на маркери в плейъра", + "skip_segment": "Пропускане на сегмент", + "theme": "Тема", + "auto": "Автоматично", + "dark": "Тъмен", + "light": "Светъл", + "autoplay_video": "Автоматично пускане на видео", + "audio_only": "Само аудио", + "buffering_goal": "Буфериране (в секунди)", + "country_selection": "Избор на държава", + "default_homepage": "Начална страница по подразбиране", + "minimize_description_default": "Минимизиране на описанието по подразбиране", + "store_watch_history": "Съхраняване на история на гледане" + }, + "player": { + "watch_on": "Гледай на {0}" + } +} diff --git a/src/locales/de.json b/src/locales/de.json index 4f7626f3..c7257318 100644 --- a/src/locales/de.json +++ b/src/locales/de.json @@ -104,7 +104,11 @@ "show_watch_on_youtube": "Schaltfläche „Auf YouTube ansehen“ anzeigen", "with_playlist": "Mit Wiedergabeliste teilen", "playlist_bookmarked": "Markiert", - "bookmark_playlist": "Lesezeichen" + "bookmark_playlist": "Lesezeichen", + "skip_segment": "Segment überspringen", + "skip_automatically": "Automatisch", + "min_segment_length": "Minimale Segmentlänge (in Sekunden)", + "skip_button_only": "Überspringen-Schaltfläche anzeigen" }, "player": { "watch_on": "Auf {0} ansehen" @@ -134,7 +138,8 @@ "live": "{0} Live", "chapters": "Kapitel", "shorts": "Shorts", - "all": "Alle" + "all": "Alle", + "category": "Kategorie" }, "preferences": { "ssl_score": "SSL-Bewertung", diff --git a/src/locales/es.json b/src/locales/es.json index b9ef70d1..19d39d55 100644 --- a/src/locales/es.json +++ b/src/locales/es.json @@ -42,7 +42,7 @@ "instance_selection": "Selección de instancias", "enabled_codecs": "Códecs habilitados (múltiples)", "instances_list": "Lista de instancias", - "language_selection": "Selección de lenguajes", + "language_selection": "Selección de idioma", "store_watch_history": "Recordar historial de visualización", "minimize_description_default": "Minimizar la descripción por defecto", "show_comments": "Mostrar comentarios", diff --git a/src/locales/fr.json b/src/locales/fr.json index ff8a6be8..4f54afb2 100644 --- a/src/locales/fr.json +++ b/src/locales/fr.json @@ -120,7 +120,11 @@ "no_valid_playlists": "Le fichier ne contient pas de listes de lecture valides !", "bookmark_playlist": "Marque-page", "playlist_bookmarked": "Dans les marque-pages", - "with_playlist": "Partager avec la liste de lecture" + "with_playlist": "Partager avec la liste de lecture", + "skip_button_only": "Afficher le bouton de saut", + "skip_automatically": "Automatiquement", + "min_segment_length": "Longueur minimale du segment (en secondes)", + "skip_segment": "Sauter le segment" }, "player": { "watch_on": "Regarder sur {0}" @@ -134,7 +138,8 @@ "chapters": "Chapitres", "live": "{0} en direct", "shorts": "Courtes", - "all": "Tout" + "all": "Tout", + "category": "Catégorie" }, "preferences": { "ssl_score": "Score SSL", diff --git a/src/locales/hr.json b/src/locales/hr.json index 3f2cbd97..6c688674 100644 --- a/src/locales/hr.json +++ b/src/locales/hr.json @@ -130,7 +130,11 @@ "no_valid_playlists": "Datoteka ne sadrži ispravne popise snimaka!", "with_playlist": "Dijeli s popisom snimaka", "playlist_bookmarked": "Zabilježeno", - "bookmark_playlist": "Zabilježi" + "bookmark_playlist": "Zabilježi", + "skip_button_only": "Prikaži gumb za preskakanje", + "skip_automatically": "Automatski", + "skip_segment": "Preskoči segment", + "min_segment_length": "Najmanja duljina segmenta (u sekundama)" }, "player": { "watch_on": "Gledaj na {0}" diff --git a/src/locales/it.json b/src/locales/it.json index 2f6bf108..318ecbf8 100644 --- a/src/locales/it.json +++ b/src/locales/it.json @@ -138,7 +138,8 @@ "live": "{0} Diretta", "chapters": "Capitoli", "shorts": "Short", - "all": "Tutti" + "all": "Tutti", + "category": "Categoria" }, "preferences": { "ssl_score": "Valutazione SSL", diff --git a/src/locales/ja.json b/src/locales/ja.json index ba4cd77a..4f8429a3 100644 --- a/src/locales/ja.json +++ b/src/locales/ja.json @@ -32,7 +32,7 @@ "enable_sponsorblock": "SponsorBlock を有効化", "skip_sponsors": "広告をスキップ", "skip_intro": "休止時間/イントロ画面をスキップ", - "skip_outro": "終了画面/クレジットをスキップ", + "skip_outro": "終了シーン/クレジットをスキップ", "skip_preview": "プレビュー/要約をスキップ", "skip_interaction": "チャンネル登録など操作を求める自己宣伝をスキップ", "skip_self_promo": "無償/自己プロモーションをスキップ", diff --git a/src/locales/nl.json b/src/locales/nl.json index fd347dba..ff1df39e 100644 --- a/src/locales/nl.json +++ b/src/locales/nl.json @@ -58,15 +58,15 @@ "remove_from_playlist": "Uit Afspeellijst Verwijderen", "select_playlist": "Selecteer een Afspeellijst", "delete_playlist_confirm": "Deze afspeellijst verwijderen?", - "please_select_playlist": "Kies een afspeellijst a.u.b.", + "please_select_playlist": "Selecteer een afspeellijst alsjeblief", "instance_selection": "Instantie Selectie", "import_from_json": "Importeren uit JSON/CSV", "clear_history": "Geschiedenis Wissen", "load_more_replies": "Laad meer Antwoorden", - "delete_playlist_video_confirm": "Video van playlist verwijderen?", + "delete_playlist_video_confirm": "Video uit deze afspeellijst verwijderen?", "create_playlist": "Afspeellijst Maken", "delete_playlist": "Afspeellijst Verwijderen", - "show_markers": "Toon markeringen op Speler", + "show_markers": "Laat markeringen op speler zien", "store_search_history": "Zoekgeschiedenis Opslaan", "minimize_chapters_default": "Hoofdstukken Standaard Minimaliseren", "show_watch_on_youtube": "Toon Bekijk op YouTube knop", @@ -77,8 +77,8 @@ "copy_link": "Link kopiëren", "hide_watched": "Verberg bekeken video's in de feed", "minimize_comments": "Opmerkingen minimaliseren", - "instance_auth_selection": "Autenticatie Instantie Selectie", - "clone_playlist": "Afspeellijst klonen", + "instance_auth_selection": "Selectie authenticatie-instantie", + "clone_playlist": "Afspeellijst dupliceren", "download_as_txt": "Downloaden als .txt", "rename_playlist": "Afspeellijst hernoemen", "new_playlist_name": "Nieuwe afspeellijstnaam", @@ -91,20 +91,24 @@ "instance_donations": "Instantie donaties", "reply_count": "{count} antwoorden", "no_valid_playlists": "Het bestand bevat geen geldige afspeellijsten!", - "clone_playlist_success": "Succesvol gekloond!", - "reset_preferences": "Voorkeuren opnieuw instellen", + "clone_playlist_success": "Dupliceren gelukt!", + "reset_preferences": "Voorkeuren herstellen", "back_to_home": "Terug naar de start", "minimize_comments_default": "Opmerkingen Standaard Minimaliseren", "delete_account": "Account Verwijderen", - "logout": "Uitloggen van dit apparaat", + "logout": "Uitloggen op dit apparaat", "minimize_recommendations_default": "Aanbevelingen Standaard Minimaliseren", "confirm_reset_preferences": "Weet u zeker dat u uw voorkeuren opnieuw wilt instellen?", "backup_preferences": "Back-up voorkeuren", - "invalidate_session": "Alle apparaten afmelden", + "invalidate_session": "Uitloggen op alle apparaten", "different_auth_instance": "Gebruik een andere instantie voor authenticatie", "with_playlist": "Delen met afspeellijst", "playlist_bookmarked": "Bladwijzer gemaakt", - "bookmark_playlist": "Bladwijzer" + "bookmark_playlist": "Bladwijzer", + "skip_automatically": "Automatisch", + "skip_button_only": "toon de overslaan knop", + "min_segment_length": "Minimale segmentlengte (in seconden)", + "skip_segment": "segment overslaan" }, "titles": { "register": "Registreren", @@ -113,9 +117,9 @@ "preferences": "Voorkeuren", "history": "Geschiedenis", "subscriptions": "Abonnementen", - "trending": "Trending", + "trending": "populair", "playlists": "Afspeellijsten", - "account": "Account", + "account": "profiel", "instance": "Instantie", "player": "Speler", "livestreams": "Livestreams", @@ -148,7 +152,9 @@ "sponsor_segments": "Sponsorsegmenten", "ratings_disabled": "Beoordelingen Uitgeschakeld", "live": "{0} Live", - "shorts": "Shorts" + "shorts": "Shorts", + "category": "Categorie", + "all": "Alle" }, "preferences": { "has_cdn": "Heeft CDN?", @@ -161,8 +167,8 @@ }, "comment": { "pinned_by": "Vastgemaakt door {author}", - "user_disabled": "Reacties zijn uitgeschakeld in de instellingen.", - "loading": "Reacties laden...", + "user_disabled": "Opmerkingen zijn uitgeschakeld in de instellingen.", + "loading": "Opmerkingen laden...", "disabled": "Reacties zijn uitgeschakeld door de uploader." }, "info": { @@ -170,7 +176,8 @@ "copied": "Gekopieerd!", "cannot_copy": "Kan niet kopiëren!", "page_not_found": "Pagina niet gevonden", - "local_storage": "Deze actie vereist lokale opslag, zijn cookies ingeschakeld?" + "local_storage": "Deze actie vereist lokale opslag, zijn cookies ingeschakeld?", + "register_no_email_note": "Een e-mailadres als gebruikersnaam gebruiken wordt afgeraden. Toch doorgaan?" }, "subscriptions": { "subscribed_channels_count": "Geabonneerd op: {0}" diff --git a/src/locales/or.json b/src/locales/or.json index 99becd20..7c3f0ad5 100644 --- a/src/locales/or.json +++ b/src/locales/or.json @@ -144,7 +144,8 @@ "ratings_disabled": "ମୂଲ୍ୟାୟନ ଅକ୍ଷମ ହୋଇଛି", "chapters": "ଅଧ୍ୟାୟ ଗୁଡ଼ିକ", "live": "{0} ସିଧାପ୍ରସାରଣ", - "all": "ସମସ୍ତ" + "all": "ସମସ୍ତ", + "category": "ବର୍ଗ" }, "search": { "did_you_mean": "ଆପଣ କହିବାକୁ ଚାହୁଁଛନ୍ତି କି: {0}?", diff --git a/src/locales/ro.json b/src/locales/ro.json index 62f09f5a..c40a7ca0 100644 --- a/src/locales/ro.json +++ b/src/locales/ro.json @@ -100,7 +100,15 @@ "minimize_recommendations": "Ascunde Recomandări", "yes": "Da", "show_comments": "Arată Comentarii", - "show_description": "Arată Descriere" + "show_description": "Arată Descriere", + "bookmark_playlist": "Marcaj", + "no_valid_playlists": "Fișierul nu conține playlist-uri valide!", + "skip_automatically": "Automat", + "min_segment_length": "Lungimea minimă a segmentului (în secunde)", + "skip_segment": "Sări segmentul", + "skip_button_only": "Afișează butonul de săritură", + "with_playlist": "Distribuie cu playlist", + "playlist_bookmarked": "Marcat" }, "preferences": { "ssl_score": "Scor SSL", @@ -125,7 +133,9 @@ "sponsor_segments": "Segmente Sponsori", "ratings_disabled": "Like-uri dezactivate", "live": "{0} Live", - "videos": "Video-uri" + "videos": "Video-uri", + "category": "Categorie", + "all": "Tot" }, "login": { "username": "Nume User", @@ -146,7 +156,9 @@ "cannot_copy": "Nu se poate copia!", "preferences_note": "Sfat: preferințele sunt salvate in memoria locala a browserului tău. Ștergând datele browserului le ștergi si pe ele.", "page_not_found": "Pagină negăsită", - "copied": "S-a copiat!" + "copied": "S-a copiat!", + "register_no_email_note": "Utilizarea unui e-mail ca nume de utilizator nu este recomandată. Continui oricum?", + "local_storage": "Această acțiune necesită localStorage, sunt activate cookie-urile?" }, "subscriptions": { "subscribed_channels_count": "Abonat la: {0}" @@ -164,7 +176,8 @@ "livestreams": "Live-uri", "channels": "Canale", "preferences": "Preferințe", - "player": "Player" + "player": "Player", + "bookmarks": "Marcaje" }, "player": { "watch_on": "Vezi pe {0}" diff --git a/src/locales/ru.json b/src/locales/ru.json index e55c2475..1fc36ec8 100644 --- a/src/locales/ru.json +++ b/src/locales/ru.json @@ -157,7 +157,8 @@ "live": "{0} В эфире", "chapters": "Содержание", "shorts": "Shorts", - "all": "Все" + "all": "Все", + "category": "Категория" }, "search": { "did_you_mean": "Может быть вы имели в виду: {0}?", diff --git a/src/locales/si.json b/src/locales/si.json index bbcb6f02..853b4c4d 100644 --- a/src/locales/si.json +++ b/src/locales/si.json @@ -157,7 +157,8 @@ "shorts": "කෙටි වීඩියෝ", "ratings_disabled": "ශ්‍රේණිගත කිරීම් අබල කර ඇත", "live": "{0} සජීවී", - "all": "සියල්ල" + "all": "සියල්ල", + "category": "කාණ්ඩය" }, "search": { "did_you_mean": "ඔබ අදහස් කළේ: {0}?", diff --git a/src/locales/vi.json b/src/locales/vi.json index 4f43ba0c..62f94e25 100644 --- a/src/locales/vi.json +++ b/src/locales/vi.json @@ -93,7 +93,8 @@ "account": "Tài khoản", "channels": "Kênh", "instance": "Instance", - "player": "Trình phát video" + "player": "Trình phát video", + "livestreams": "Phát sóng trực tiếp" }, "player": { "watch_on": "Xem trên {0}" @@ -125,7 +126,8 @@ "live": "{0} Trực tiếp", "chapters": "Chương", "videos": "Video", - "shorts": "Shorts" + "shorts": "Shorts", + "all": "Tất cả" }, "search": { "did_you_mean": "Ý của bạn là: {0}?", diff --git a/src/locales/zh_Hans.json b/src/locales/zh_Hans.json index fff8921a..57e478f0 100644 --- a/src/locales/zh_Hans.json +++ b/src/locales/zh_Hans.json @@ -44,7 +44,7 @@ "least_recent": "最早的", "most_recent": "最新的", "sort_by": "排序:", - "view_subscriptions": "查看订阅", + "view_subscriptions": "查看订阅列表", "unsubscribe": "取消订阅 - {count}", "subscribe": "订阅 - {count}", "loading": "正在加载...", @@ -141,8 +141,8 @@ "watch_on": "在 {0} 观看" }, "titles": { - "feed": "RSS 订阅源", - "subscriptions": "订阅", + "feed": "订阅流", + "subscriptions": "订阅列表", "history": "历史", "preferences": "设置", "register": "注册", diff --git a/src/utils/DashUtils.js b/src/utils/DashUtils.js index 0cba5885..f0d6dcde 100644 --- a/src/utils/DashUtils.js +++ b/src/utils/DashUtils.js @@ -4,201 +4,204 @@ import { Buffer } from "buffer"; window.Buffer = Buffer; import { json2xml } from "xml-js"; -const DashUtils = { - generate_dash_file_from_formats(VideoFormats, VideoLength) { - const generatedJSON = this.generate_xmljs_json_from_data(VideoFormats, VideoLength); - return json2xml(generatedJSON); - }, - generate_xmljs_json_from_data(VideoFormatArray, VideoLength) { - const convertJSON = { - declaration: { - attributes: { - version: "1.0", - encoding: "utf-8", - }, +export function generate_dash_file_from_formats(VideoFormats, VideoLength) { + const generatedJSON = generate_xmljs_json_from_data(VideoFormats, VideoLength); + return json2xml(generatedJSON); +} + +function generate_xmljs_json_from_data(VideoFormatArray, VideoLength) { + const convertJSON = { + declaration: { + attributes: { + version: "1.0", + encoding: "utf-8", }, - elements: [ - { - type: "element", - name: "MPD", - attributes: { - xmlns: "urn:mpeg:dash:schema:mpd:2011", - profiles: "urn:mpeg:dash:profile:full:2011", - minBufferTime: "PT1.5S", - type: "static", - mediaPresentationDuration: `PT${VideoLength}S`, - }, - elements: [ - { - type: "element", - name: "Period", - elements: this.generate_adaptation_set(VideoFormatArray), - }, - ], + }, + elements: [ + { + type: "element", + name: "MPD", + attributes: { + xmlns: "urn:mpeg:dash:schema:mpd:2011", + profiles: "urn:mpeg:dash:profile:full:2011", + minBufferTime: "PT1.5S", + type: "static", + mediaPresentationDuration: `PT${VideoLength}S`, }, - ], - }; - return convertJSON; - }, - generate_adaptation_set(VideoFormatArray) { - const adaptationSets = []; + elements: [ + { + type: "element", + name: "Period", + elements: generate_adaptation_set(VideoFormatArray), + }, + ], + }, + ], + }; + return convertJSON; +} - let mimeAudioObjs = []; +function generate_adaptation_set(VideoFormatArray) { + const adaptationSets = []; - VideoFormatArray.forEach(videoFormat => { - // the dual formats should not be used - if (videoFormat.mimeType.indexOf("video") != -1 && !videoFormat.videoOnly) { + let mimeAudioObjs = []; + + VideoFormatArray.forEach(videoFormat => { + // the dual formats should not be used + if ( + (videoFormat.mimeType.includes("video") && !videoFormat.videoOnly) || + videoFormat.mimeType.includes("application") + ) { + return; + } + + const audioTrackId = videoFormat.audioTrackId; + const mimeType = videoFormat.mimeType; + + for (let i = 0; i < mimeAudioObjs.length; i++) { + const mimeAudioObj = mimeAudioObjs[i]; + + if (mimeAudioObj.audioTrackId == audioTrackId && mimeAudioObj.mimeType == mimeType) { + mimeAudioObj.videoFormats.push(videoFormat); return; } + } - const audioTrackId = videoFormat.audioTrackId; - const mimeType = videoFormat.mimeType; - - for (let i = 0; i < mimeAudioObjs.length; i++) { - const mimeAudioObj = mimeAudioObjs[i]; - - if (mimeAudioObj.audioTrackId == audioTrackId && mimeAudioObj.mimeType == mimeType) { - mimeAudioObj.videoFormats.push(videoFormat); - return; - } - } - - mimeAudioObjs.push({ - audioTrackId, - mimeType, - videoFormats: [videoFormat], - }); + mimeAudioObjs.push({ + audioTrackId, + mimeType, + videoFormats: [videoFormat], }); + }); - mimeAudioObjs.forEach(mimeAudioObj => { - const adapSet = { - type: "element", - name: "AdaptationSet", - attributes: { - id: mimeAudioObj.audioTrackId, - lang: mimeAudioObj.audioTrackId?.substr(0, 2), - mimeType: mimeAudioObj.mimeType, - startWithSAP: "1", - subsegmentAlignment: "true", - }, - elements: [], - }; + mimeAudioObjs.forEach(mimeAudioObj => { + const adapSet = { + type: "element", + name: "AdaptationSet", + attributes: { + id: mimeAudioObj.audioTrackId, + lang: mimeAudioObj.audioTrackId?.substr(0, 2), + mimeType: mimeAudioObj.mimeType, + startWithSAP: "1", + subsegmentAlignment: "true", + }, + elements: [], + }; - let isVideoFormat = false; + let isVideoFormat = false; - if (mimeAudioObj.mimeType.includes("video")) { - isVideoFormat = true; - } + if (mimeAudioObj.mimeType.includes("video")) { + isVideoFormat = true; + } + if (isVideoFormat) { + adapSet.attributes.scanType = "progressive"; + } + + for (var i = 0; i < mimeAudioObj.videoFormats.length; i++) { + const videoFormat = mimeAudioObj.videoFormats[i]; if (isVideoFormat) { - adapSet.attributes.scanType = "progressive"; + adapSet.elements.push(generate_representation_video(videoFormat)); + } else { + adapSet.elements.push(generate_representation_audio(videoFormat)); } + } - for (var i = 0; i < mimeAudioObj.videoFormats.length; i++) { - const videoFormat = mimeAudioObj.videoFormats[i]; - if (isVideoFormat) { - adapSet.elements.push(this.generate_representation_video(videoFormat)); - } else { - adapSet.elements.push(this.generate_representation_audio(videoFormat)); - } - } + adaptationSets.push(adapSet); + }); + return adaptationSets; +} - adaptationSets.push(adapSet); - }); - return adaptationSets; - }, - generate_representation_audio(Format) { - const representation = { - type: "element", - name: "Representation", - attributes: { - id: Format.itag, - codecs: Format.codec, - bandwidth: Format.bitrate, +function generate_representation_audio(Format) { + const representation = { + type: "element", + name: "Representation", + attributes: { + id: Format.itag, + codecs: Format.codec, + bandwidth: Format.bitrate, + }, + elements: [ + { + type: "element", + name: "AudioChannelConfiguration", + attributes: { + schemeIdUri: "urn:mpeg:dash:23003:3:audio_channel_configuration:2011", + value: "2", + }, }, - elements: [ - { - type: "element", - name: "AudioChannelConfiguration", - attributes: { - schemeIdUri: "urn:mpeg:dash:23003:3:audio_channel_configuration:2011", - value: "2", + { + type: "element", + name: "BaseURL", + elements: [ + { + type: "text", + text: Format.url, }, - }, - { - type: "element", - name: "BaseURL", - elements: [ - { - type: "text", - text: Format.url, - }, - ], - }, - { - type: "element", - name: "SegmentBase", - attributes: { - indexRange: `${Format.indexStart}-${Format.indexEnd}`, - }, - elements: [ - { - type: "element", - name: "Initialization", - attributes: { - range: `${Format.initStart}-${Format.initEnd}`, - }, - }, - ], - }, - ], - }; - return representation; - }, - generate_representation_video(Format) { - const representation = { - type: "element", - name: "Representation", - attributes: { - id: Format.itag, - codecs: Format.codec, - bandwidth: Format.bitrate, - width: Format.width, - height: Format.height, - maxPlayoutRate: "1", - frameRate: Format.fps, + ], }, - elements: [ - { - type: "element", - name: "BaseURL", - elements: [ - { - type: "text", - text: Format.url, - }, - ], + { + type: "element", + name: "SegmentBase", + attributes: { + indexRange: `${Format.indexStart}-${Format.indexEnd}`, }, - { - type: "element", - name: "SegmentBase", - attributes: { - indexRange: `${Format.indexStart}-${Format.indexEnd}`, + elements: [ + { + type: "element", + name: "Initialization", + attributes: { + range: `${Format.initStart}-${Format.initEnd}`, + }, }, - elements: [ - { - type: "element", - name: "Initialization", - attributes: { - range: `${Format.initStart}-${Format.initEnd}`, - }, - }, - ], - }, - ], - }; - return representation; - }, -}; + ], + }, + ], + }; + return representation; +} -export default DashUtils; +function generate_representation_video(Format) { + const representation = { + type: "element", + name: "Representation", + attributes: { + id: Format.itag, + codecs: Format.codec, + bandwidth: Format.bitrate, + width: Format.width, + height: Format.height, + maxPlayoutRate: "1", + frameRate: Format.fps, + }, + elements: [ + { + type: "element", + name: "BaseURL", + elements: [ + { + type: "text", + text: Format.url, + }, + ], + }, + { + type: "element", + name: "SegmentBase", + attributes: { + indexRange: `${Format.indexStart}-${Format.indexEnd}`, + }, + elements: [ + { + type: "element", + name: "Initialization", + attributes: { + range: `${Format.initStart}-${Format.initEnd}`, + }, + }, + ], + }, + ], + }; + return representation; +} diff --git a/yarn.lock b/yarn.lock index 4959910e..e0501b33 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1818,14 +1818,26 @@ resolved "https://registry.yarnpkg.com/@esbuild/win32-x64/-/win32-x64-0.16.17.tgz#c5a1a4bfe1b57f0c3e61b29883525c6da3e5c091" integrity sha512-y+EHuSchhL7FjHgvQL/0fnnFmO4T1bhvWANX6gcnqTjtnKWbTvUMCpGnv2+t+31d7RzyEAYAd4u2fnIhHL6N/Q== -"@eslint/eslintrc@^2.0.0": - version "2.0.0" - resolved "https://registry.yarnpkg.com/@eslint/eslintrc/-/eslintrc-2.0.0.tgz#943309d8697c52fc82c076e90c1c74fbbe69dbff" - integrity sha512-fluIaaV+GyV24CCu/ggiHdV+j4RNh85yQnAYS/G2mZODZgGmmlrgCydjUcV3YvxCm9x8nMAfThsqTni4KiXT4A== +"@eslint-community/eslint-utils@^4.2.0": + version "4.2.0" + resolved "https://registry.yarnpkg.com/@eslint-community/eslint-utils/-/eslint-utils-4.2.0.tgz#a831e6e468b4b2b5ae42bf658bea015bf10bc518" + integrity sha512-gB8T4H4DEfX2IV9zGDJPOBgP1e/DbfCPDTtEqUMckpvzS1OYtva8JdFYBqMwYk7xAQ429WGF/UPqn8uQ//h2vQ== + dependencies: + eslint-visitor-keys "^3.3.0" + +"@eslint-community/regexpp@^4.4.0": + version "4.4.0" + resolved "https://registry.yarnpkg.com/@eslint-community/regexpp/-/regexpp-4.4.0.tgz#3e61c564fcd6b921cb789838631c5ee44df09403" + integrity sha512-A9983Q0LnDGdLPjxyXQ00sbV+K+O+ko2Dr+CZigbHWtX9pNfxlaBkMR8X1CztI73zuEyEBXTVjx7CE+/VSwDiQ== + +"@eslint/eslintrc@^2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@eslint/eslintrc/-/eslintrc-2.0.1.tgz#7888fe7ec8f21bc26d646dbd2c11cd776e21192d" + integrity sha512-eFRmABvW2E5Ho6f5fHLqgena46rOj7r7OKHYfLElqcBfGFHHpjBhivyi5+jOEQuSpdc/1phIZJlbC2te+tZNIw== dependencies: ajv "^6.12.4" debug "^4.3.2" - espree "^9.4.0" + espree "^9.5.0" globals "^13.19.0" ignore "^5.2.0" import-fresh "^3.2.1" @@ -1833,10 +1845,10 @@ minimatch "^3.1.2" strip-json-comments "^3.1.1" -"@eslint/js@8.35.0": - version "8.35.0" - resolved "https://registry.yarnpkg.com/@eslint/js/-/js-8.35.0.tgz#b7569632b0b788a0ca0e438235154e45d42813a7" - integrity sha512-JXdzbRiWclLVoD8sNUjR443VVlYqiYmDVT6rGUEIEHU5YJW0gaVZwV2xgM7D4arkvASqD0IlLUVjHiFuxaftRw== +"@eslint/js@8.36.0": + version "8.36.0" + resolved "https://registry.yarnpkg.com/@eslint/js/-/js-8.36.0.tgz#9837f768c03a1e4a30bd304a64fb8844f0e72efe" + integrity sha512-lxJ9R5ygVm8ZWgYdUweoq5ownDlJ4upvoWmO4eLxBYHdMo+vZ/Rx0EN6MbKWDJOSUGrqJy2Gt+Dyv/VKml0fjg== "@fortawesome/fontawesome-common-types@6.3.0": version "6.3.0" @@ -1888,10 +1900,10 @@ resolved "https://registry.yarnpkg.com/@humanwhocodes/object-schema/-/object-schema-1.2.1.tgz#b520529ec21d8e5945a1851dfd1c32e94e39ff45" integrity sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA== -"@iconify/json@2.2.28": - version "2.2.28" - resolved "https://registry.yarnpkg.com/@iconify/json/-/json-2.2.28.tgz#6c705733c1319b2e94c9e9cf680b4e5d911a7053" - integrity sha512-GlWrkBdm5h4KrL3PFW3D8PPP/tlxcvW/AZu0w7StlLNbUbC2AKq9NnO9hTk4DaZmTyEGMMCyFHZ5/dYnpaUiPQ== +"@iconify/json@2.2.33": + version "2.2.33" + resolved "https://registry.yarnpkg.com/@iconify/json/-/json-2.2.33.tgz#f972268bb208fa5d6e2116ed563d8b6428f52e34" + integrity sha512-e5PVSGmEXWMijHi396h3hfx5hBzbCiI5AcqvGOSJIaaZyRB4pdPIHCrQ//xRBeFRw+TtATRlDJUkE2XBC05b4g== dependencies: "@iconify/types" "*" pathe "^1.0.0" @@ -2186,25 +2198,25 @@ resolved "https://registry.yarnpkg.com/@types/trusted-types/-/trusted-types-2.0.2.tgz#fc25ad9943bcac11cceb8168db4f275e0e72e756" integrity sha512-F5DIZ36YVLE+PN+Zwws4kJogq47hNgX3Nx6WyDJ3kcplxyke3XIzB8uK5n/Lpm1HBsbGzd6nmGehL8cPekP+Tg== -"@unocss/astro@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/astro/-/astro-0.50.1.tgz#db53b2e8da91e9abb51daa4fa3d2d54ebc2c52d6" - integrity sha512-TlGIK21OTbVUgrwZXfU4x0VwpNB7i/MKGcpv3HKadxdqhXReimt9gD+iRWSRAvRBgDIcH6Uqvr3Qq1aNCVEdTg== +"@unocss/astro@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/astro/-/astro-0.50.4.tgz#3071c09262a41c7b17dafbe80bb6157fea5c9d3a" + integrity sha512-NlfkyMM/xv0ozzP/ByqFAQmtzpDALWqWssXmtSQVV3CCZCxTQYzeenXgv92VELISxNUHJ46elKPHhWNpRBxCjg== dependencies: - "@unocss/core" "0.50.1" - "@unocss/reset" "0.50.1" - "@unocss/vite" "0.50.1" + "@unocss/core" "0.50.4" + "@unocss/reset" "0.50.4" + "@unocss/vite" "0.50.4" -"@unocss/cli@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/cli/-/cli-0.50.1.tgz#d1f2aa7ff8924552eb77b22c16ebff9590461f57" - integrity sha512-Qu1s8sJh4XFRN62qeHAQ+NkxylPi7Gf4Gz0NmTvn4C9BjpiCwO4QKJoyy0fjY4TcdPOIkibfSg/MjTD/4ceyyA== +"@unocss/cli@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/cli/-/cli-0.50.4.tgz#eb29fde122e894bfd0c926702174f5eb0e0ca3e4" + integrity sha512-rAdMSfDio5dGbHCnhmvh+72D7JmIksDIpGYf0rjrMU+rxSC3/l4+Dr9Rr5qqNg1I51AcB9/UM6ena0TF2RyK8A== dependencies: "@ampproject/remapping" "^2.2.0" "@rollup/pluginutils" "^5.0.2" - "@unocss/config" "0.50.1" - "@unocss/core" "0.50.1" - "@unocss/preset-uno" "0.50.1" + "@unocss/config" "0.50.4" + "@unocss/core" "0.50.4" + "@unocss/preset-uno" "0.50.4" cac "^6.7.14" chokidar "^3.5.3" colorette "^2.0.19" @@ -2214,140 +2226,153 @@ pathe "^1.1.0" perfect-debounce "^0.1.3" -"@unocss/config@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/config/-/config-0.50.1.tgz#3abe4c576f364dc63cc53ea3c354474ef86b8391" - integrity sha512-pZmT5gDIp0n/HMSD2kcSw/LW4QJ5azjBzGciuLN6p/kOjgj1SnYjElOgbedUEMeyZTZXveMoB50OuUzb9S+a2g== +"@unocss/config@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/config/-/config-0.50.4.tgz#17c92a5063370b31433f758c987a5629b6dcee86" + integrity sha512-5Nvlvu3RHoZFqaxJwaN/pr9bWHg2PZ4omD90y/xe0CXWHjX9n3BJHcXqQQm0Iai6uF1IZDPOC5nj2UU2oKFxMg== dependencies: - "@unocss/core" "0.50.1" + "@unocss/core" "0.50.4" unconfig "^0.3.7" -"@unocss/core@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/core/-/core-0.50.1.tgz#ad4659b7abc43b77458aa29214d83ad0e687da9c" - integrity sha512-jnWClMMGybzyXcRX4DY+g/DJ4JrH9w8YN/H6OTHt0WyrNfR1V3ebJtEc6gbqCkZCh2XmqSA5F49QPhTbErYePg== +"@unocss/core@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/core/-/core-0.50.4.tgz#f6d0ed9ea60db3661f750e2ef117ffab553fea1c" + integrity sha512-k/8CdnO4w7f+QdvCpS3U5y6xApC4odiErkBKCCaGgBqOWkuTSL92TiBnffSEA2WepGm1+Mv4urIk20ocKYxbUQ== -"@unocss/inspector@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/inspector/-/inspector-0.50.1.tgz#214d5adb7edaa34890f074aa12accdb739b5169b" - integrity sha512-pKjhO8hlkcYVksnQn/ly1HLnh49ZYu/MDnexaQaPtS3/1KLibiinTNqzZpZJZ71T0dVUadW9fMfV2t283GhJzA== +"@unocss/inspector@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/inspector/-/inspector-0.50.4.tgz#a62db9eeafcaaf991137a1aa863451daf17313e2" + integrity sha512-3xYOhjNmM7qpdU4CSbL7acCb4YuTdeSoYCIMtWkbg9mHh/6GQZWV2eDTxwSxVE7WwDymw9Jg44Ewq3oboZWl1Q== dependencies: gzip-size "^6.0.0" sirv "^2.0.2" -"@unocss/preset-attributify@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/preset-attributify/-/preset-attributify-0.50.1.tgz#4de12d34cc8d7fd4ef23cdc45dddbed0588b6558" - integrity sha512-hFvxX406r8jXYkHTSq5GVg5ZXNtGNlTmvrjvpirH3PxK/YOkcS7D3ZsnOmxTvblsIzXx45w+V7hplNAg9t46eQ== +"@unocss/postcss@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/postcss/-/postcss-0.50.4.tgz#5fded0cf54973be44c22e54e3505fb57b6017f57" + integrity sha512-Gri+EqIOs/yKk0YHel5XLHQCRD1BzKdQHF82zizJUyqaRStR2qvR8ECInYsirXL/eUEvx2zT8iQKCXkiApTuQw== dependencies: - "@unocss/core" "0.50.1" + "@unocss/config" "0.50.4" + "@unocss/core" "0.50.4" + css-tree "^2.3.1" + fast-glob "^3.2.12" + magic-string "^0.30.0" + postcss "^8.4.21" -"@unocss/preset-icons@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/preset-icons/-/preset-icons-0.50.1.tgz#a43816c35e3079465bf9a7cfc8db8025d79ec0cc" - integrity sha512-uqPzQ2U2ih3wb1sjjnEI3OMzf2jcpoflIY9+jIXb0CgIh2SQtvri2uK4mYBWTLyZXWp9bHfBEaM9Dzfr9eSU3w== +"@unocss/preset-attributify@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/preset-attributify/-/preset-attributify-0.50.4.tgz#47f2671d87f31501fa672f3392cf369001bb98d0" + integrity sha512-lSEyfpIGSzZB4DHFxrxhaa7rDF5PpM1EbReKogTVG7wsYTCmdCh8YirrgAlrcFCN1NgcbW1DaHdQs891A7glow== + dependencies: + "@unocss/core" "0.50.4" + +"@unocss/preset-icons@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/preset-icons/-/preset-icons-0.50.4.tgz#38323f8b659edf5e7f176ff618d7d54f0c8c8244" + integrity sha512-0Bnito2u/t479oI9syXG8ynK1q2YUBt+dV6S6UugiTtys0KahjmuOTuk10GDgF50r4FvI38QfHBv+kF95qmwZg== dependencies: "@iconify/utils" "^2.1.4" - "@unocss/core" "0.50.1" + "@unocss/core" "0.50.4" ofetch "^1.0.1" -"@unocss/preset-mini@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/preset-mini/-/preset-mini-0.50.1.tgz#575bbd681f8954bbb06ef24d610a6b99600c8e1d" - integrity sha512-asAJHsgNKbfH5aANuaA/1Q0efWPWalGSlLa9V73JXyXO4fbFT86m3o65NPHbm2N9t5IRxTfL3hcuUE/cOGEVLg== +"@unocss/preset-mini@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/preset-mini/-/preset-mini-0.50.4.tgz#0532afaa5d74f3ac39a4fa04aa911e3c203cdd0b" + integrity sha512-M+4by82hlpZq/sE0axrepQ6sgTl65nXrbNIHhXmfIsqulH7nENELJIr/TFi7VcSJdPMGVwo9l9dHnFMhSQM5hg== dependencies: - "@unocss/core" "0.50.1" + "@unocss/core" "0.50.4" -"@unocss/preset-tagify@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/preset-tagify/-/preset-tagify-0.50.1.tgz#3b97f192f0122019d58f6d37bbf295b10cbfe3bd" - integrity sha512-3pAJDKxa+RFMpZL8bQpR/76htF22mpb72dV5UBj0l4HZk/9HK2hlLL2GurZ87HOZbh4cWfgHj9G+CK+ubTHY0w== +"@unocss/preset-tagify@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/preset-tagify/-/preset-tagify-0.50.4.tgz#a5b7d86de645f96ebe229c55930fc6d0538d1b8c" + integrity sha512-SJchttBpnePOKBD9onjprqOcgyWFAaOzT3O6M/sWzHEszVcfsFi2uPcwZW5CLwbOMiV0tbozBQFkcQ1c1swilw== dependencies: - "@unocss/core" "0.50.1" + "@unocss/core" "0.50.4" -"@unocss/preset-typography@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/preset-typography/-/preset-typography-0.50.1.tgz#e5c479c7bd8722321524402a6af0aecec31c2244" - integrity sha512-sk2LGA47558BLTvIlZlYExnV84C+8wYSh8jYhizW7IJjrvudfOSuO21qPulhcUjCwcMo8pEDRx7YddZy8sJOuQ== +"@unocss/preset-typography@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/preset-typography/-/preset-typography-0.50.4.tgz#daf1a9d9646e5d3f92cc48774208122a5816623b" + integrity sha512-iEVdwd591RKAzirvftAHcLWdTam3ea/M7ElC1geMlY8rsFNtiDjVLtY87v8piHVXXFBwy71YAGhJkPCrxE8yHw== dependencies: - "@unocss/core" "0.50.1" + "@unocss/core" "0.50.4" + "@unocss/preset-mini" "0.50.4" -"@unocss/preset-uno@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/preset-uno/-/preset-uno-0.50.1.tgz#fe82fdf30ceef46612c06829d24ce69b010681ee" - integrity sha512-d4A7lqldhA1AeD0T/uwPHc+6pz44FYOnsSf34C0KVBmt1kDR2kZUOk8tcNWSXMpDWBkGAhrOMl/EuZ5ShCRzeQ== +"@unocss/preset-uno@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/preset-uno/-/preset-uno-0.50.4.tgz#31d5dfff11f18c80102bcb0a373b4951f26a1eb0" + integrity sha512-otmCHbzJH1EISZ2Hvu35CEYaH3T6giwTreaP8CEo+BEjhGv2hgWmJko8GPDerUgO4FSP/YCwSGyBvcvSsRXV8A== dependencies: - "@unocss/core" "0.50.1" - "@unocss/preset-mini" "0.50.1" - "@unocss/preset-wind" "0.50.1" + "@unocss/core" "0.50.4" + "@unocss/preset-mini" "0.50.4" + "@unocss/preset-wind" "0.50.4" -"@unocss/preset-web-fonts@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/preset-web-fonts/-/preset-web-fonts-0.50.1.tgz#98c73cfa28184d151b35cf79d65896619c8ce140" - integrity sha512-V9i5t57gPbpuuP7rKIS9wj2PUuLojG8/nkMIutivIOXNK+O+7klp3YDrs+0cwUjCRPgXCbnbBTAs/eXOjTitUQ== +"@unocss/preset-web-fonts@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/preset-web-fonts/-/preset-web-fonts-0.50.4.tgz#9de92d3099f1961bb7772fd781fcf1c4cc8e9e36" + integrity sha512-4l8ILVzL6pAtMjwB5NRg1HowCS6dz4tLRVxH5W4uPyU5ADt3nhk5oQvzD9hDiB5sNJcXFVpMhI09UsRjUHQaTw== dependencies: - "@unocss/core" "0.50.1" + "@unocss/core" "0.50.4" ofetch "^1.0.1" -"@unocss/preset-wind@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/preset-wind/-/preset-wind-0.50.1.tgz#6c9bb10405a8be2c9cb2879718f94bfbd387755c" - integrity sha512-+gDGdundQTgyEiK9Y0DbVCxjT5Miu7vBGtcsp0AyLojz/cHkdDBL/1X34fWTA7mejnFgs/e2m0BlFVwAj9ZZiQ== +"@unocss/preset-wind@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/preset-wind/-/preset-wind-0.50.4.tgz#792f5abf9020a134a6706106bfd446ca2062cfb9" + integrity sha512-kOdX5DYrspbVOkNY7cEH0jJrtmtxlEcsZb9ieToYb3l76oWicgZX5G46c74+UzMW2ru9dxdOBgJWgnWbH7AFDQ== dependencies: - "@unocss/core" "0.50.1" - "@unocss/preset-mini" "0.50.1" + "@unocss/core" "0.50.4" + "@unocss/preset-mini" "0.50.4" -"@unocss/reset@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/reset/-/reset-0.50.1.tgz#47b7476f8e78712748b165ec882d8787703d418e" - integrity sha512-BcANWHHrKgHML5TLaPuSl148L2WLA938r0pLi4PrRTmZtkgP4OhBLs8U8BaDNVVGR/nli7VDxNRZFb9es3Tq9Q== +"@unocss/reset@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/reset/-/reset-0.50.4.tgz#974362051a56ddff2b9511aa7ac6a8ce291024ec" + integrity sha512-UHNDhClJMx3sG3oi68XkOcTeJ2hkI20O0eHowSoua10NClbnS9tiKxeo4ZLInouzvac3tb1TsjKEgTosHfkR/w== -"@unocss/scope@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/scope/-/scope-0.50.1.tgz#6d380c435d82fa3a6c962db3a9c5b5e713737e6f" - integrity sha512-C59tSuuiNh/c7X+DcuaNKVsmFvqSyWu5tAa/sTMDYa6qLRof2W/ot7NEEH9QEC7s0fklAiRt7Iazehrjz4mf+w== +"@unocss/scope@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/scope/-/scope-0.50.4.tgz#ae0ef52a6a724f9db7b3a2350b0bc5ede1e3b13d" + integrity sha512-USJ5hr1dVE8JOb0PJYqpfAWxGLB69b+z30ZGzdmDgblmVheYsyzWZ3KMclz/2x8HtXRsB2VuJT5KqUPW7lT3gw== -"@unocss/transformer-attributify-jsx@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/transformer-attributify-jsx/-/transformer-attributify-jsx-0.50.1.tgz#ea0b5efe52cfe55ab54f08a63d9f831cf9744c0d" - integrity sha512-gyvPRcQVgg3yDcj+KCqkrm/kYNTPKhynNzY0UTLQ7eBH3C786zs+8miyONyL/K0bkoBaWnw3Jzr07JIRQfguUA== +"@unocss/transformer-attributify-jsx@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/transformer-attributify-jsx/-/transformer-attributify-jsx-0.50.4.tgz#df83dd91b76cc582863a6add9a7179a853e0f4b5" + integrity sha512-DETbAiN/i393/OLuyEMBCXr2wDGyqEbkDMl/ZPN5RKO6m7312yt0KebnfIJnKaL0wGs90ohtV4ZHWMOeucX2jQ== dependencies: - "@unocss/core" "0.50.1" + "@unocss/core" "0.50.4" -"@unocss/transformer-compile-class@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/transformer-compile-class/-/transformer-compile-class-0.50.1.tgz#6971f6f1ae36b74a0eb59a287eea0a14498e2c4e" - integrity sha512-HuAL914R1hXaDO/KkbWX8q8GffAPhvdZIMy+VpdGXNSWAGpYpHWQu/LGrTuzk56p8sGGy6jwza1iMIP/9l7CWQ== +"@unocss/transformer-compile-class@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/transformer-compile-class/-/transformer-compile-class-0.50.4.tgz#67e7ed5a50a10098e6c64dcadff9363ca69ef06c" + integrity sha512-pjXamTunv8CAX8r6heEw/UJdhkYNIbMEr6GGQfe33K6lL4fdU85NbvZD7c3pXbQJahKrGsgL7TSPvFoRw+5MZA== dependencies: - "@unocss/core" "0.50.1" + "@unocss/core" "0.50.4" -"@unocss/transformer-directives@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/transformer-directives/-/transformer-directives-0.50.1.tgz#fa11cd2f239d7c8489a4ab93321566e1dcce867f" - integrity sha512-rdkznrK6JeEp9m2StLhP0VViuBWDgzYUqA3JxOKMoMQ0+x/TfBbXWkw2WnoGGkj3Vms6NPoKGa5Yhbdxp4w8yg== +"@unocss/transformer-directives@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/transformer-directives/-/transformer-directives-0.50.4.tgz#34924d9639a3712735c4179d676d14bbbc52dea9" + integrity sha512-sk7AlL6wGnfKbCBDP4bKg008sJQuIbT408bkq98yA7h0/bIlLTqF6U0nzqUoIer5YxAAvIVm1Sm30CQV06s9rA== dependencies: - "@unocss/core" "0.50.1" + "@unocss/core" "0.50.4" css-tree "^2.3.1" -"@unocss/transformer-variant-group@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/transformer-variant-group/-/transformer-variant-group-0.50.1.tgz#1b4996970531825e7bdd61d96925170de38e5abc" - integrity sha512-1+OBSsyHfW9mXAnzaELXWqLjcoi+B4G5R5h+9TT2RZfHqkSIu+5xu2OGsDJ2QFhNGFerv7R2k7ajVCnbQWq7TQ== +"@unocss/transformer-variant-group@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/transformer-variant-group/-/transformer-variant-group-0.50.4.tgz#2e56ecccef51e18ccd1eab6210562aeabb46e82b" + integrity sha512-caSByOVhD36yeE0j11gkhsxGPX7wphexVZLlzJa/6w2RAHwab1SCBCtAQeTRdl/C53DI8q4gsNt73IFoqQ1eng== dependencies: - "@unocss/core" "0.50.1" + "@unocss/core" "0.50.4" -"@unocss/vite@0.50.1": - version "0.50.1" - resolved "https://registry.yarnpkg.com/@unocss/vite/-/vite-0.50.1.tgz#7e80b538847b58a15c40e79b777ba05564800d8f" - integrity sha512-CDy9ZcwSCpz/ED9zglunmrCVDbczbtkC/ZzgcRehDUX9xeVRA397uakb7fe4Rm+KGOGmr7HsUTQR7s0C9EOYww== +"@unocss/vite@0.50.4": + version "0.50.4" + resolved "https://registry.yarnpkg.com/@unocss/vite/-/vite-0.50.4.tgz#70eacdf7dd2db9bced0a3edeb6f9bc926fca824d" + integrity sha512-NW0B6hY3ho6G+PRFjNDvs0+nokCzHGbMtK4E9GIU5NyjJh0b4FfuWe9C9o1GxHGiFskGfYnirKPV40IHWOzOFw== dependencies: "@ampproject/remapping" "^2.2.0" "@rollup/pluginutils" "^5.0.2" - "@unocss/config" "0.50.1" - "@unocss/core" "0.50.1" - "@unocss/inspector" "0.50.1" - "@unocss/scope" "0.50.1" - "@unocss/transformer-directives" "0.50.1" + "@unocss/config" "0.50.4" + "@unocss/core" "0.50.4" + "@unocss/inspector" "0.50.4" + "@unocss/scope" "0.50.4" + "@unocss/transformer-directives" "0.50.4" chokidar "^3.5.3" fast-glob "^3.2.12" magic-string "^0.30.0" @@ -2902,10 +2927,10 @@ dom-walk@^0.1.0: resolved "https://registry.yarnpkg.com/dom-walk/-/dom-walk-0.1.2.tgz#0c548bef048f4d1f2a97249002236060daa3fd84" integrity sha512-6QvTW9mrGeIegrFXdtQi9pk7O/nSK6lSdXW2eqUspN5LWD7UTji2Fqw5V2YLjBpHEoU9Xl/eUWNpDeZvoyOv2w== -dompurify@3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/dompurify/-/dompurify-3.0.0.tgz#6adc6f918376d93419ed1ee35811850680027cba" - integrity sha512-0g/yr2IJn4nTbxwL785YxS7/AvvgGFJw6LLWP+BzWzB1+BYOqPUT9Hy0rXrZh5HLdHnxH72aDdzvC9SdTjsuaA== +dompurify@3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/dompurify/-/dompurify-3.0.1.tgz#a0933f38931b3238934dd632043b727e53004289" + integrity sha512-60tsgvPKwItxZZdfLmamp0MTcecCta3avOhsLgPZ0qcWt96OasFfhkeIRbJ6br5i0fQawT1/RBGB5L58/Jpwuw== duplexer@^0.1.2: version "0.1.2" @@ -3012,10 +3037,10 @@ escape-string-regexp@^4.0.0: resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz#14ba83a5d373e3d311e5afca29cf5bfad965bf34" integrity sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA== -eslint-config-prettier@8.6.0: - version "8.6.0" - resolved "https://registry.yarnpkg.com/eslint-config-prettier/-/eslint-config-prettier-8.6.0.tgz#dec1d29ab728f4fa63061774e1672ac4e363d207" - integrity sha512-bAF0eLpLVqP5oEVUFKpMA+NnRFICwn9X8B5jrR9FcqnYBuPbqWEjTEspPWMj5ye6czoSLDweCzSo3Ko7gGrZaA== +eslint-config-prettier@8.7.0: + version "8.7.0" + resolved "https://registry.yarnpkg.com/eslint-config-prettier/-/eslint-config-prettier-8.7.0.tgz#f1cc58a8afebc50980bd53475451df146c13182d" + integrity sha512-HHVXLSlVUhMSmyW4ZzEuvjpwqamgmlfkutD53cYXLikh4pt/modINRcCIApJ84czDxM4GZInwUrromsDdTImTA== eslint-plugin-prettier@4.2.1: version "4.2.1" @@ -3074,13 +3099,15 @@ eslint-visitor-keys@^3.3.0: resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-3.3.0.tgz#f6480fa6b1f30efe2d1968aa8ac745b862469826" integrity sha512-mQ+suqKJVyeuwGYHAdjMFqjCyfl8+Ldnxuyp3ldiMBFKkvytrXUZWaiPCEav8qDHKty44bD+qV1IP4T+w+xXRA== -eslint@8.35.0: - version "8.35.0" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.35.0.tgz#fffad7c7e326bae606f0e8f436a6158566d42323" - integrity sha512-BxAf1fVL7w+JLRQhWl2pzGeSiGqbWumV4WNvc9Rhp6tiCtm4oHnyPBSEtMGZwrQgudFQ+otqzWoPB7x+hxoWsw== +eslint@8.36.0: + version "8.36.0" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.36.0.tgz#1bd72202200a5492f91803b113fb8a83b11285cf" + integrity sha512-Y956lmS7vDqomxlaaQAHVmeb4tNMp2FWIvU/RnU5BD3IKMD/MJPr76xdyr68P8tV1iNMvN2mRK0yy3c+UjL+bw== dependencies: - "@eslint/eslintrc" "^2.0.0" - "@eslint/js" "8.35.0" + "@eslint-community/eslint-utils" "^4.2.0" + "@eslint-community/regexpp" "^4.4.0" + "@eslint/eslintrc" "^2.0.1" + "@eslint/js" "8.36.0" "@humanwhocodes/config-array" "^0.11.8" "@humanwhocodes/module-importer" "^1.0.1" "@nodelib/fs.walk" "^1.2.8" @@ -3091,9 +3118,8 @@ eslint@8.35.0: doctrine "^3.0.0" escape-string-regexp "^4.0.0" eslint-scope "^7.1.1" - eslint-utils "^3.0.0" eslint-visitor-keys "^3.3.0" - espree "^9.4.0" + espree "^9.5.0" esquery "^1.4.2" esutils "^2.0.2" fast-deep-equal "^3.1.3" @@ -3115,7 +3141,6 @@ eslint@8.35.0: minimatch "^3.1.2" natural-compare "^1.4.0" optionator "^0.9.1" - regexpp "^3.2.0" strip-ansi "^6.0.1" strip-json-comments "^3.1.0" text-table "^0.2.0" @@ -3138,10 +3163,10 @@ espree@^9.3.1: acorn-jsx "^5.3.2" eslint-visitor-keys "^3.3.0" -espree@^9.4.0: - version "9.4.0" - resolved "https://registry.yarnpkg.com/espree/-/espree-9.4.0.tgz#cd4bc3d6e9336c433265fc0aa016fc1aaf182f8a" - integrity sha512-DQmnRpLj7f6TgN/NYb0MTzJXL+vJF9h3pHy4JhCIs3zwcgez8xmGg3sXHcEO97BrmO2OSvCwMdfdlyl+E9KjOw== +espree@^9.5.0: + version "9.5.0" + resolved "https://registry.yarnpkg.com/espree/-/espree-9.5.0.tgz#3646d4e3f58907464edba852fa047e6a27bdf113" + integrity sha512-JPbJGhKc47++oo4JkEoTe2wjy4fmMwvFpgJT9cQzmfXKp22Dr6Hf1tdCteLz1h0P3t+mGvWZ+4Uankvh8+c6zw== dependencies: acorn "^8.8.0" acorn-jsx "^5.3.2" @@ -4217,11 +4242,6 @@ regexp.prototype.flags@^1.4.1: call-bind "^1.0.2" define-properties "^1.1.3" -regexpp@^3.2.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-3.2.0.tgz#0425a2768d8f23bad70ca4b90461fa2f1213e1b2" - integrity sha512-pq2bWo9mVD43nbts2wGv17XLiNLya+GklZ8kaDLV2Z08gDCsGpnKn9BFMepvWuHCbyVvY7J5o5+BVvoQbmlJLg== - regexpu-core@^5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/regexpu-core/-/regexpu-core-5.0.1.tgz#c531122a7840de743dcf9c83e923b5560323ced3" @@ -4392,10 +4412,10 @@ serialize-javascript@^4.0.0: dependencies: randombytes "^2.1.0" -shaka-player@4.3.4: - version "4.3.4" - resolved "https://registry.yarnpkg.com/shaka-player/-/shaka-player-4.3.4.tgz#97c7cb73743884e55a4855f5efe4d116aff83848" - integrity sha512-fF90r/57Oxk+SV2cnoEpJxNujNj1gJkudKXVbXEBhgxh5qYu5gdFU+nT2N7jMN71KxQdtXo1NOqdNphudLEEug== +shaka-player@4.3.5: + version "4.3.5" + resolved "https://registry.yarnpkg.com/shaka-player/-/shaka-player-4.3.5.tgz#304d60ad867fb7a0780b850b32a9614296b842db" + integrity sha512-WkqvHm8QHOsQ71d/qoc2Wa6Z5rBrG3Zgsc6ho9I9e8Xwa0io+MeREgqBuG0z6qoXK55sTImipFhDoERrkmDdUg== dependencies: eme-encryption-scheme-polyfill "^2.1.1" @@ -4704,28 +4724,29 @@ universalify@^2.0.0: resolved "https://registry.yarnpkg.com/universalify/-/universalify-2.0.0.tgz#75a4984efedc4b08975c5aeb73f530d02df25717" integrity sha512-hAZsKq7Yy11Zu1DE0OzWjw7nnLZmJZYTDZZyEFHZdUhV8FkH5MCfoU1XMaxXovpyW5nq5scPqq0ZDP9Zyl04oQ== -unocss@0.50.1: - version "0.50.1" - resolved "https://registry.yarnpkg.com/unocss/-/unocss-0.50.1.tgz#6bf08d0c8ea32caeb5f5f73eb2253fb5c8e368fc" - integrity sha512-D21InhvOwWb2quWVTqVUDl1shDU87KEWc8OzpLztaLmRpOV0S6SFxCZmxA5sAUGaVNdTgHAbBU9o43ipete1Mw== +unocss@0.50.4: + version "0.50.4" + resolved "https://registry.yarnpkg.com/unocss/-/unocss-0.50.4.tgz#1121aad4030c59c6deef4c44380c81823b1652d8" + integrity sha512-9offjUEwVlAkR//0sidTyvKkSArRGkDdgSFeW4P4005GWnjmXnbx4amuAeS3Au4o8WoshZCCOi5EYrpO4aLdfg== dependencies: - "@unocss/astro" "0.50.1" - "@unocss/cli" "0.50.1" - "@unocss/core" "0.50.1" - "@unocss/preset-attributify" "0.50.1" - "@unocss/preset-icons" "0.50.1" - "@unocss/preset-mini" "0.50.1" - "@unocss/preset-tagify" "0.50.1" - "@unocss/preset-typography" "0.50.1" - "@unocss/preset-uno" "0.50.1" - "@unocss/preset-web-fonts" "0.50.1" - "@unocss/preset-wind" "0.50.1" - "@unocss/reset" "0.50.1" - "@unocss/transformer-attributify-jsx" "0.50.1" - "@unocss/transformer-compile-class" "0.50.1" - "@unocss/transformer-directives" "0.50.1" - "@unocss/transformer-variant-group" "0.50.1" - "@unocss/vite" "0.50.1" + "@unocss/astro" "0.50.4" + "@unocss/cli" "0.50.4" + "@unocss/core" "0.50.4" + "@unocss/postcss" "0.50.4" + "@unocss/preset-attributify" "0.50.4" + "@unocss/preset-icons" "0.50.4" + "@unocss/preset-mini" "0.50.4" + "@unocss/preset-tagify" "0.50.4" + "@unocss/preset-typography" "0.50.4" + "@unocss/preset-uno" "0.50.4" + "@unocss/preset-web-fonts" "0.50.4" + "@unocss/preset-wind" "0.50.4" + "@unocss/reset" "0.50.4" + "@unocss/transformer-attributify-jsx" "0.50.4" + "@unocss/transformer-compile-class" "0.50.4" + "@unocss/transformer-directives" "0.50.4" + "@unocss/transformer-variant-group" "0.50.4" + "@unocss/vite" "0.50.4" upath@^1.2.0: version "1.2.0"