mod: upgrade sable to latest release
additionally added patch
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
diff --git a/src/app/pages/client/ClientRoot.tsx b/src/app/pages/client/ClientRoot.tsx
|
||||
index acdeab967..d64f32c53 100644
|
||||
--- a/src/app/pages/client/ClientRoot.tsx
|
||||
+++ b/src/app/pages/client/ClientRoot.tsx
|
||||
@@ -86,8 +86,6 @@ function ClientRootLoading() {
|
||||
const activeSessionId = useAtomValue(activeSessionIdAtom);
|
||||
const setSessions = useSetAtom(sessionsAtom);
|
||||
|
||||
- const [showEasterEggs] = useSetting(settingsAtom, 'showEasterEggs');
|
||||
- const [animalKind] = useSetting(settingsAtom, 'animalKind');
|
||||
|
||||
const activeSession: Session | undefined =
|
||||
sessions.find((session) => session.userId === activeSessionId) ?? sessions[0];
|
||||
@@ -108,14 +106,15 @@ function ClientRootLoading() {
|
||||
window.location.reload();
|
||||
};
|
||||
|
||||
- const loadingAnimal = showEasterEggs && animalKind ? animalKind : 'cats';
|
||||
+ const races = ["Petting Miqo’te", "Hugging Roegadyn", "Punting Lalafell", "Climbing Elezen", "Booping Viera"];
|
||||
+ const result = races[Math.floor(Math.random() * races.length)];
|
||||
|
||||
return (
|
||||
<SplashScreen>
|
||||
<Box direction="Column" grow="Yes" alignItems="Center" justifyContent="Center" gap="400">
|
||||
<Spinner variant="Secondary" size="600" />
|
||||
|
||||
- <Text>{`Petting ${loadingAnimal}`}</Text>
|
||||
+ <Text>{`${races}`}</Text>
|
||||
|
||||
{activeSession && (
|
||||
<Text
|
||||
@@ -0,0 +1,93 @@
|
||||
{
|
||||
lib,
|
||||
buildNpmPackage,
|
||||
pnpm_10,
|
||||
fetchPnpmDeps,
|
||||
pnpmConfigHook,
|
||||
nodejs_24,
|
||||
fetchFromGitHub,
|
||||
}:
|
||||
buildNpmPackage (
|
||||
finalAttrs:
|
||||
let
|
||||
pnpm = pnpm_10.override {
|
||||
nodejs-slim = nodejs_24;
|
||||
};
|
||||
matrixrtcSrc = fetchFromGitHub {
|
||||
owner = "SableClient";
|
||||
repo = "matrix-rtc";
|
||||
rev = "519fe6b863cfac78700f4e2b1748649103bb8a8d";
|
||||
hash = "sha256-n5f7529RdRxY8/a43Xkgrhg4yRz5aNgfoZqWrB7kvak=";
|
||||
};
|
||||
livekitMobileSrc = fetchFromGitHub {
|
||||
owner = "SableClient";
|
||||
repo = "tauri-plugin-livekit-mobile";
|
||||
rev = "c6f0d02ab3da1174535bc1dc8e598a2e6873f977";
|
||||
hash = "sha256-ZPx6Ic+Gkvzg9LXYP9BaQALzOrvLCcQHOms8U3VfnU0=";
|
||||
};
|
||||
in
|
||||
{
|
||||
pname = "sable-unwrapped";
|
||||
version = "1.22.6";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "SableClient";
|
||||
repo = "Sable";
|
||||
tag = "v${finalAttrs.version}";
|
||||
hash = "sha256-AZ2gKcCLJvllC/lOL+l/zt3/RxztWd8mu25Eo0vyMBY=";
|
||||
};
|
||||
|
||||
nodejs = nodejs_24;
|
||||
|
||||
nativeBuildInputs = [ pnpm ];
|
||||
npmConfigHook = pnpmConfigHook;
|
||||
|
||||
npmDeps = finalAttrs.pnpmDeps;
|
||||
pnpmDeps = fetchPnpmDeps {
|
||||
inherit (finalAttrs) pname version src;
|
||||
inherit pnpm;
|
||||
fetcherVersion = 3;
|
||||
hash = "sha256-sI0tE73l+yKS8186tUHrNAJmGD26XEe7828ohvvc+1o=";
|
||||
};
|
||||
|
||||
npmInstallFlags = [
|
||||
"--ignore-scripts"
|
||||
];
|
||||
|
||||
preBuild = ''
|
||||
cp -r --no-preserve=mode ${matrixrtcSrc}/. node_modules/@sableclient/matrixrtc/
|
||||
pnpm exec tsc \
|
||||
-p node_modules/@sableclient/matrixrtc/tsconfig.build.json \
|
||||
--rootDir node_modules/@sableclient/matrixrtc/src
|
||||
cp -r --no-preserve=mode ${livekitMobileSrc}/. node_modules/@sableclient/tauri-plugin-livekit-mobile/
|
||||
pnpm exec tsc \
|
||||
-p node_modules/@sableclient/tauri-plugin-livekit-mobile/tsconfig.json \
|
||||
--noEmit false \
|
||||
--declaration \
|
||||
--rootDir node_modules/@sableclient/tauri-plugin-livekit-mobile/guest-js \
|
||||
--outDir node_modules/@sableclient/tauri-plugin-livekit-mobile/dist-js
|
||||
'';
|
||||
|
||||
patches = [
|
||||
./0001-races-patch.patch
|
||||
];
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
|
||||
cp -r dist $out
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "An almost stable Matrix client";
|
||||
homepage = "https://app.sable.moe/";
|
||||
maintainers = with lib.maintainers; [
|
||||
(wymillerlinux or) "wymillerlinux"
|
||||
];
|
||||
license = lib.licenses.agpl3Only;
|
||||
platforms = lib.platforms.all;
|
||||
};
|
||||
}
|
||||
)
|
||||
Reference in New Issue
Block a user