diff --git a/images/session/session_icon.png b/images/session/session_icon.png index 8555d93fe..2c07ba2e9 100644 Binary files a/images/session/session_icon.png and b/images/session/session_icon.png differ diff --git a/package.json b/package.json index e92cc81cd..32c0cc218 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "session-desktop", "productName": "Session", "description": "Private messaging from your desktop", - "version": "1.13.0", + "version": "1.13.1", "license": "GPL-3.0", "author": { "name": "Oxen Labs", @@ -104,7 +104,7 @@ "fs-extra": "9.0.0", "glob": "7.1.2", "image-type": "^4.1.0", - "libsession_util_nodejs": "https://github.com/oxen-io/libsession-util-nodejs/releases/download/v0.3.21/libsession_util_nodejs-v0.3.21.tar.gz", + "libsession_util_nodejs": "https://github.com/oxen-io/libsession-util-nodejs/releases/download/v0.3.22/libsession_util_nodejs-v0.3.22.tar.gz", "libsodium-wrappers-sumo": "^0.7.9", "linkify-it": "^4.0.1", "lodash": "^4.17.21", diff --git a/ts/components/AboutView.tsx b/ts/components/AboutView.tsx index 6c8f6d70a..10aea991d 100644 --- a/ts/components/AboutView.tsx +++ b/ts/components/AboutView.tsx @@ -22,10 +22,13 @@ const StyledContent = styled(Flex)` } img:first-child { + filter: brightness(0) saturate(100%) invert(75%) sepia(84%) saturate(3272%) hue-rotate(103deg) + brightness(106%) contrast(103%); margin: var(--margins-2xl) 0 var(--margins-lg); } img:nth-child(2) { + filter: var(--session-logo-text-current-filter); margin-bottom: var(--margins-xl); } @@ -40,13 +43,14 @@ const StyledContent = styled(Flex)` export const AboutView = () => { // Add debugging metadata - environment if not production, app instance name - const states = []; + const environmentStates = []; if (window.getEnvironment() !== 'production') { - states.push(window.getEnvironment()); + environmentStates.push(window.getEnvironment()); } + if (window.getAppInstance()) { - states.push(window.getAppInstance()); + environmentStates.push(window.getAppInstance()); } const versionInfo = `v${window.getVersion()}`; @@ -63,7 +67,7 @@ export const AboutView = () => { }, []); return ( - + { width={192} height={26} /> - { buttonType={SessionButtonType.Simple} /> - + {environmentStates.length ? ( + + ) : null} https://getsession.org
diff --git a/ts/components/DebugLogView.tsx b/ts/components/DebugLogView.tsx index 0cdb2f5cc..c3a6e9650 100644 --- a/ts/components/DebugLogView.tsx +++ b/ts/components/DebugLogView.tsx @@ -5,6 +5,8 @@ import { switchThemeTo } from '../themes/switchTheme'; import { fetchNodeLog } from '../util/logging'; import { SessionButton, SessionButtonType } from './basic/SessionButton'; import { SessionIconButton } from './icon'; +import { CopyToClipboardButton } from './buttons'; +import { Flex } from './basic/Flex'; const StyledContent = styled.div` background-color: var(--modal-background-content-color); @@ -54,7 +56,14 @@ const DebugLogTextArea = (props: { content: string }) => { const DebugLogButtons = (props: { content: string }) => { return ( -
+ { (window as any).saveLog(props.content); }} /> -
+ + ); }; @@ -107,7 +121,7 @@ export const DebugLogView = () => { }, []); return ( - +
; }): Promise { - const { endpoint, method, stringifiedBody, abortSignal } = sendOptions; + const { endpoint, method, stringifiedBody, abortSignal, headers } = sendOptions; if (!endpoint.startsWith('/')) { throw new Error('endpoint needs a leading /'); } @@ -514,7 +515,7 @@ async function sendJsonViaOnionV4ToFileServer(sendOptions: { builtUrl, { method, - headers: {}, + headers, body: stringifiedBody, useV4: true, }, diff --git a/ts/test/session/unit/onion/OnionPaths_test.ts b/ts/test/session/unit/onion/OnionPaths_test.ts index 37981f736..8bbec24d1 100644 --- a/ts/test/session/unit/onion/OnionPaths_test.ts +++ b/ts/test/session/unit/onion/OnionPaths_test.ts @@ -115,9 +115,8 @@ describe('OnionPaths', () => { describe('getRandomEdgeSnode', () => { it('random if multiple matches', () => { const originalSnodePool = generateFakeSnodes(5); - const filtered = originalSnodePool.filter((_m, i) => i % 5 !== 0); const winner = OnionPaths.getRandomEdgeSnode(originalSnodePool); - expect(filtered).to.deep.include(winner); + expect(originalSnodePool).to.deep.include(winner); }); }); diff --git a/ts/themes/SessionTheme.tsx b/ts/themes/SessionTheme.tsx index acd77ab42..22a6f8403 100644 --- a/ts/themes/SessionTheme.tsx +++ b/ts/themes/SessionTheme.tsx @@ -6,6 +6,7 @@ import { SettingsKey } from '../data/settings-key'; import { getOppositeTheme, isThemeMismatched } from '../util/theme'; import { THEME_GLOBALS, setThemeValues } from './globals'; import { switchThemeTo } from './switchTheme'; +import { Storage } from '../util/storage'; export async function ensureThemeConsistency(): Promise { const theme = window.Events.getThemeSetting(); @@ -52,10 +53,21 @@ const setupTheme = async () => { } }; -export const SessionTheme = ({ children }: { children: ReactNode }) => { +export const SessionTheme = ({ + children, + runSetup = true, +}: { + children: ReactNode; + /** If we don't have access to some window object functions we may skip theme consistency checks */ + runSetup?: boolean; +}) => { useMount(() => { setThemeValues(THEME_GLOBALS); - void setupTheme(); + if (runSetup) { + void Storage.onready(() => { + void setupTheme(); + }); + } }); return children; }; diff --git a/yarn.lock b/yarn.lock index c7b12481d..6d35901cb 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1786,9 +1786,9 @@ available-typed-arrays@^1.0.7: possible-typed-array-names "^1.0.0" axios@^1.6.5: - version "1.7.2" - resolved "https://registry.yarnpkg.com/axios/-/axios-1.7.2.tgz#b625db8a7051fbea61c35a3cbb3a1daa7b9c7621" - integrity sha512-2A8QhOMrbomlDuiLeK9XibIBzuHeRcqqNOHp0Cyp5EoJ1IFDh+XZH3A6BkXtv0K4gFGCI0Y4BM7B1wOEi0Rmgw== + version "1.7.4" + resolved "https://registry.yarnpkg.com/axios/-/axios-1.7.4.tgz#4c8ded1b43683c8dd362973c393f3ede24052aa2" + integrity sha512-DukmaFRnY6AzAALSH4J2M3k6PkaC+MfaAGdEERRWcC9q3/TWQwLpHR8ZRLKTdQ3aBDL64EdluRDjJqKw+BPZEw== dependencies: follow-redirects "^1.15.6" form-data "^4.0.0" @@ -2664,9 +2664,9 @@ date-fns@^3.6.0: integrity sha512-fRHTG8g/Gif+kSh50gaGEdToemgfj74aRX3swtiouboip5JDLAyDE9F11nHMIcvOaXeOC6D7SpNhi7uFyB7Uww== debug@4, debug@^4, debug@^4.0.1, debug@^4.1.0, debug@^4.1.1, debug@^4.3.1, debug@^4.3.2, debug@^4.3.4: - version "4.3.5" - resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.5.tgz#e83444eceb9fedd4a1da56d671ae2446a01a6e1e" - integrity sha512-pt0bNEmneDIvdL1Xsd9oDQ/wrQRkXDT4AUWlNZNPKvW5x/jyO9VFXkJUP07vQ2upmw5PlaITaPKc31jK13V+jg== + version "4.3.6" + resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.6.tgz#2ab2c38fbaffebf8aa95fdfe6d88438c7a13c52b" + integrity sha512-O/09Bd4Z1fBrU4VzkhFqVgpPzaGbw6Sm9FEkBT1A/YBXQFGuuSxa1dN2nxgxS34JmKXqYx8CZAwEVoJFImUXIg== dependencies: ms "2.1.2" @@ -4955,9 +4955,9 @@ levn@~0.3.0: prelude-ls "~1.1.2" type-check "~0.3.2" -"libsession_util_nodejs@https://github.com/oxen-io/libsession-util-nodejs/releases/download/v0.3.21/libsession_util_nodejs-v0.3.21.tar.gz": - version "0.3.21" - resolved "https://github.com/oxen-io/libsession-util-nodejs/releases/download/v0.3.21/libsession_util_nodejs-v0.3.21.tar.gz#64705b1f7c934ca32f929ea8127370cc82bab97a" +"libsession_util_nodejs@https://github.com/oxen-io/libsession-util-nodejs/releases/download/v0.3.22/libsession_util_nodejs-v0.3.22.tar.gz": + version "0.3.22" + resolved "https://github.com/oxen-io/libsession-util-nodejs/releases/download/v0.3.22/libsession_util_nodejs-v0.3.22.tar.gz#6d9246a7469edb6b90edd9b637726419e4a65571" dependencies: cmake-js "^7.2.1" node-addon-api "^6.1.0"