Merge pull request #699 from Materialious/update/1.6.22

Add needed files for flatpak
This commit is contained in:
Ward
2024-10-30 20:02:35 +13:00
committed by GitHub
10 changed files with 49 additions and 92 deletions
+2
View File
@@ -82,5 +82,7 @@ jobs:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: ./materialious/android/app/release/*
tag: ${{ steps.package-version.outputs.current-version}}
release_name: ${{ steps.package-version.outputs.current-version}}
overwrite: true
file_glob: true
draft: false
+6 -3
View File
@@ -18,12 +18,15 @@ jobs:
node-version: [20]
runtime:
- linux-x64
- linux-arm64
- win-x64
- osx-x64
include:
- runtime: linux-x64
os: ubuntu-latest
- runtime: linux-arm64
os: ubuntu-latest
- runtime: osx-x64
os: macOS-latest
- runtime: win-x64
@@ -65,13 +68,13 @@ jobs:
if: runner.os == 'Windows'
- name: Install snapcraft
if: matrix.runtime == 'linux-x64'
if: matrix.runtime == 'linux-x64' || matrix.runtime == 'linux-arm64'
run: sudo snap install snapcraft --classic
- name: Set up snapcraft environment variables
run: echo "SNAPCRAFT_STORE_CREDENTIALS=${{ secrets.SNAPCRAFT_LOGIN }}" >> $GITHUB_ENV
shell: bash
if: matrix.runtime == 'linux-x64'
if: matrix.runtime == 'linux-x64' || matrix.runtime == 'linux-arm64'
- name: Build desktop packages
run: cd ./materialious/electron && npm run electron:make
run: cd ./materialious/electron && npm run electron:make
+9 -7
View File
@@ -16,17 +16,19 @@ jobs:
node-version: [20]
runtime:
- linux-x64
- linux-arm64
- win-x64
- osx-x64
include:
- runtime: linux-x64
os: ubuntu-latest
- runtime: osx-x64
os: macOS-latest
- runtime: win-x64
os: windows-latest
- runtime: linux-x64
os: ubuntu-latest
- runtime: linux-arm64
os: ubuntu-latest
- runtime: osx-x64
os: macOS-latest
- runtime: win-x64
os: windows-latest
runs-on: ${{ matrix.os }}
+1 -60
View File
@@ -1,60 +1 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
width="210mm"
height="297mm"
viewBox="0 0 210 297"
version="1.1"
id="svg1"
xml:space="preserve"
inkscape:export-filename="Materialious.png"
inkscape:export-xdpi="192.00003"
inkscape:export-ydpi="192.00003"
inkscape:version="1.3.2 (091e20e, 2023-11-25, custom)"
sodipodi:docname="Meterialious.svg"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg"><sodipodi:namedview
id="namedview1"
pagecolor="#ffffff"
bordercolor="#000000"
borderopacity="0.25"
inkscape:showpageshadow="2"
inkscape:pageopacity="0.0"
inkscape:pagecheckerboard="0"
inkscape:deskcolor="#d1d1d1"
inkscape:document-units="mm"
inkscape:zoom="0.35055065"
inkscape:cx="852.9438"
inkscape:cy="494.93562"
inkscape:window-width="1920"
inkscape:window-height="1001"
inkscape:window-x="1644"
inkscape:window-y="-9"
inkscape:window-maximized="1"
inkscape:current-layer="layer1" /><defs
id="defs1" /><g
inkscape:label="Laag 1"
inkscape:groupmode="layer"
id="layer1"><path
id="rect1"
style="opacity:1;fill:#8a3ba5;fill-opacity:1;stroke-width:4.05609;stroke-linecap:square;paint-order:stroke markers fill"
d="M 37.266649,80.766659 V 216.23333 H 172.73331 V 80.766659 Z" /><g
id="g6"
transform="matrix(1.0140222,0,0,1.0140222,-1.4722742,-56.323482)"><g
id="g1"
transform="matrix(-1,0,0,1,201.63735,-7.4456246e-6)"><g
id="g5"><path
id="path5"
style="color:#000000;fill:#ffffff;stroke-linecap:square;-inkscape-stroke:none;paint-order:stroke markers fill"
d="m 114.65661,173.40906 -1.29294,4.82606 h -5.2e-4 l -44.404523,11.89798 32.504993,32.50551 10e-4,0.001 -6.12107,22.84563 -26.381853,-26.38185 -26.381335,-26.38134 36.03811,-9.65625 z m -4.28191,15.97939 -5.37486,20.05872 -0.54622,2.03915 -16.176276,-16.17679 z" /><path
style="color:#000000;fill:#ffffff;stroke-linecap:square;-inkscape-stroke:none;paint-order:stroke markers fill"
d="M 131.38171,245.48534 105,219.10365 l -26.381696,-26.3817 36.038076,-9.65637 36.03807,-9.65638 -9.65637,36.03807 z"
id="path3" /></g></g><circle
style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:10.8326;stroke-linecap:square;stroke-dasharray:none;stroke-opacity:1;paint-order:stroke markers fill"
id="path6"
cx="86.980743"
cy="163.40662"
r="4.9097047" /></g></g></svg>
<svg version="1.1" id="svg1" xml:space="preserve" inkscape:export-filename="Materialious.png" inkscape:export-xdpi="192.00003" inkscape:export-ydpi="192.00003" inkscape:version="1.3.2 (091e20e, 2023-11-25, custom)" sodipodi:docname="Meterialious.svg" xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" xmlns="http://www.w3.org/2000/svg" xmlns:svg="http://www.w3.org/2000/svg" viewBox="37.25 80.75 135.5 135.5"><sodipodi:namedview id="namedview1" pagecolor="#ffffff" bordercolor="#000000" borderopacity="0.25" inkscape:showpageshadow="2" inkscape:pageopacity="0.0" inkscape:pagecheckerboard="0" inkscape:deskcolor="#d1d1d1" inkscape:document-units="mm" inkscape:zoom="0.35055065" inkscape:cx="852.9438" inkscape:cy="494.93562" inkscape:window-width="1920" inkscape:window-height="1001" inkscape:window-x="1644" inkscape:window-y="-9" inkscape:window-maximized="1" inkscape:current-layer="layer1"/><defs id="defs1"/><g inkscape:label="Laag 1" inkscape:groupmode="layer" id="layer1"><path id="rect1" style="opacity:1;fill:#8a3ba5;fill-opacity:1;stroke-width:4.05609;stroke-linecap:square;paint-order:stroke markers fill" d="M 37.266649,80.766659 V 216.23333 H 172.73331 V 80.766659 Z"/><g id="g6" transform="matrix(1.0140222,0,0,1.0140222,-1.4722742,-56.323482)"><g id="g1" transform="matrix(-1,0,0,1,201.63735,-7.4456246e-6)"><g id="g5"><path id="path5" style="color:#000000;fill:#ffffff;stroke-linecap:square;-inkscape-stroke:none;paint-order:stroke markers fill" d="m 114.65661,173.40906 -1.29294,4.82606 h -5.2e-4 l -44.404523,11.89798 32.504993,32.50551 10e-4,0.001 -6.12107,22.84563 -26.381853,-26.38185 -26.381335,-26.38134 36.03811,-9.65625 z m -4.28191,15.97939 -5.37486,20.05872 -0.54622,2.03915 -16.176276,-16.17679 z"/><path style="color:#000000;fill:#ffffff;stroke-linecap:square;-inkscape-stroke:none;paint-order:stroke markers fill" d="M 131.38171,245.48534 105,219.10365 l -26.381696,-26.3817 36.038076,-9.65637 36.03807,-9.65638 -9.65637,36.03807 z" id="path3"/></g></g><circle style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:10.8326;stroke-linecap:square;stroke-dasharray:none;stroke-opacity:1;paint-order:stroke markers fill" id="path6" cx="86.980743" cy="163.40662" r="4.9097047"/></g></g></svg>

Before

Width:  |  Height:  |  Size: 2.7 KiB

After

Width:  |  Height:  |  Size: 2.3 KiB

+2 -2
View File
@@ -7,8 +7,8 @@ android {
applicationId "us.materialio.app"
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
versionCode 72
versionName "1.6.21"
versionCode 73
versionName "1.6.22"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
aaptOptions {
// Files and dirs to omit from the packaged assets dir, modified to accommodate modern web apps.
@@ -0,0 +1,10 @@
[Desktop Entry]
Name=Materialious
Comment=Modern material design for Invidious.
GenericName=Materialious
Exec=run.sh %u
Icon=us.materialio.Materialious
Type=Application
StartupNotify=true
StartupWMClass=Materialious
Categories=GNOME;GTK;AudioVideo;Network;Utility;
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "Materialious",
"version": "1.6.21",
"version": "1.6.22",
"description": "Modern material design for Invidious.",
"author": {
"name": "Ward Pearce",
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "materialious",
"version": "1.6.21",
"version": "1.6.22",
"private": true,
"scripts": {
"dev": "vite dev",
+16 -17
View File
@@ -7,7 +7,6 @@ import { get } from 'svelte/store';
import { Innertube, ProtoUtils, UniversalCache, Utils } from 'youtubei.js';
import { capacitorFetch } from '../android/http/capacitorFetch';
export interface PoTokens {
visitor_data: string;
po_token: string;
@@ -100,7 +99,7 @@ export async function patchYoutubeJs(videoId: string): Promise<VideoPlay> {
dashUri = URL.createObjectURL(new Blob([manifest], { type: 'application/dash+xml;charset=utf8' }));
}
const descString = video.secondary_info.description.toString();
const descString = video.secondary_info.description?.toString() || '';
let authorThumbnails: Image[];
if (video.basic_info.channel_id) {
@@ -115,18 +114,18 @@ export async function patchYoutubeJs(videoId: string): Promise<VideoPlay> {
recommendedVideos.push({
videoThumbnails: recommended?.thumbnails as Thumbnail[] || [],
videoId: recommended?.id || '',
title: recommended?.title.toString() || '',
viewCountText: recommended.view_count ? numberWithCommas(Number(recommended?.view_count.toString().replace(/\D/g, ''))) as string : '',
title: recommended?.title?.toString() || '',
viewCountText: recommended.view_count ? numberWithCommas(Number(recommended?.view_count.toString().replace(/\D/g, ''))) || '' : '',
lengthSeconds: recommended?.duration?.seconds || 0,
author: recommended?.author.name || '',
authorId: recommended?.author.id || ''
author: recommended?.author?.name || '',
authorId: recommended?.author?.id || ''
});
});
let captions: Captions[] = [];
video.captions?.caption_tracks?.forEach(caption => {
captions.push({
label: caption.name.toString(),
label: caption.name?.toString() || '',
language_code: caption.language_code,
// Add correct format to url.
url: caption.base_url + '&fmt=vtt'
@@ -136,11 +135,11 @@ export async function patchYoutubeJs(videoId: string): Promise<VideoPlay> {
let adaptiveFormats: AdaptiveFormats[] = [];
video.streaming_data?.adaptive_formats.forEach(format => {
adaptiveFormats.push({
index: format.index_range?.start.toString() || '',
bitrate: format.bitrate.toString(),
init: format.init_range?.start.toString() || '',
index: format.index_range?.start?.toString() || '',
bitrate: format.bitrate?.toString() || '',
init: format.init_range?.start?.toString() || '',
url: format.url || '',
itag: format.itag.toString(),
itag: format.itag?.toString() || '',
type: format.mime_type,
clen: '',
lmt: '',
@@ -168,9 +167,9 @@ export async function patchYoutubeJs(videoId: string): Promise<VideoPlay> {
return {
type: 'video',
title: video.primary_info.title ? video.primary_info.title.toString() : '',
viewCount: video.primary_info.view_count ? Number(video.primary_info.view_count.toString().replace(/\D/g, '')) : 0,
viewCountText: video.primary_info.view_count ? video.primary_info.view_count.toString() : '',
title: video.primary_info.title?.toString() || '',
viewCount: video.primary_info.view_count ? Number(video.primary_info.view_count?.toString()?.replace(/\D/g, '')) : 0,
viewCountText: video.primary_info.view_count?.toString() || '',
likeCount: video.basic_info.like_count || 0,
dislikeCount: 0,
allowRatings: false,
@@ -189,9 +188,9 @@ export async function patchYoutubeJs(videoId: string): Promise<VideoPlay> {
authorUrl: `/channel/${video.basic_info.channel_id}`,
authorVerified: false,
description: descString,
descriptionHtml: video.secondary_info.description.toHTML() || descString,
descriptionHtml: video.secondary_info.description?.toHTML() || descString,
published: 0,
publishedText: video.primary_info.published ? video.primary_info.published.toString() : '',
publishedText: video.primary_info.published?.toString() || '',
premiereTimestamp: 0,
hlsUrl: video.streaming_data?.hls_manifest_url || undefined,
liveNow: video.basic_info.is_live || false,
@@ -207,4 +206,4 @@ export async function patchYoutubeJs(videoId: string): Promise<VideoPlay> {
allowedRegions: [],
fallbackPatch: 'youtubejs'
};
}
}
+1 -1
View File
@@ -5,7 +5,7 @@ import json
import os
import re
LATEST_VERSION = "1.6.21"
LATEST_VERSION = "1.6.22"
WORKING_DIR = os.path.join(os.path.dirname(os.path.realpath(__file__)), "materialious")
ROOT_PACKAGE = os.path.join(WORKING_DIR, "package.json")