Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/dev' into fix-camera-on-calls
Browse files Browse the repository at this point in the history
  • Loading branch information
lgmarchi committed Dec 18, 2024
2 parents 7b18462 + 49036ef commit 4c179bc
Show file tree
Hide file tree
Showing 11 changed files with 592 additions and 167 deletions.
1 change: 1 addition & 0 deletions android/app/capacitor.build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ dependencies {
implementation project(':capacitor-filesystem')
implementation project(':capacitor-keyboard')
implementation project(':capacitor-screen-orientation')
implementation project(':capacitor-share')
implementation project(':capacitor-splash-screen')
implementation project(':capacitor-status-bar')
}
Expand Down
3 changes: 3 additions & 0 deletions android/capacitor.settings.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ project(':capacitor-keyboard').projectDir = new File('../node_modules/@capacitor
include ':capacitor-screen-orientation'
project(':capacitor-screen-orientation').projectDir = new File('../node_modules/@capacitor/screen-orientation/android')

include ':capacitor-share'
project(':capacitor-share').projectDir = new File('../node_modules/@capacitor/share/android')

include ':capacitor-splash-screen'
project(':capacitor-splash-screen').projectDir = new File('../node_modules/@capacitor/splash-screen/android')

Expand Down
6 changes: 6 additions & 0 deletions capacitor.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@ const config: CapacitorConfig = {
appId: "com.satellite.uplink.app",
appName: "Uplink",
webDir: "build",
plugins: {
SplashScreen: {
launchShowDuration: 5000,
launchAutoHide: true,
},
},
}

export default config
1 change: 1 addition & 0 deletions ios/App/Podfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ def capacitor_pods
pod 'CapacitorFilesystem', :path => '../../node_modules/@capacitor/filesystem'
pod 'CapacitorKeyboard', :path => '../../node_modules/@capacitor/keyboard'
pod 'CapacitorScreenOrientation', :path => '../../node_modules/@capacitor/screen-orientation'
pod 'CapacitorShare', :path => '../../node_modules/@capacitor/share'
pod 'CapacitorSplashScreen', :path => '../../node_modules/@capacitor/splash-screen'
pod 'CapacitorStatusBar', :path => '../../node_modules/@capacitor/status-bar'
end
Expand Down
8 changes: 7 additions & 1 deletion ios/App/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ PODS:
- Capacitor
- CapacitorScreenOrientation (6.0.3):
- Capacitor
- CapacitorShare (6.0.3):
- Capacitor
- CapacitorSplashScreen (6.0.3):
- Capacitor
- CapacitorStatusBar (6.0.2):
Expand All @@ -28,6 +30,7 @@ DEPENDENCIES:
- "CapacitorFilesystem (from `../../node_modules/@capacitor/filesystem`)"
- "CapacitorKeyboard (from `../../node_modules/@capacitor/keyboard`)"
- "CapacitorScreenOrientation (from `../../node_modules/@capacitor/screen-orientation`)"
- "CapacitorShare (from `../../node_modules/@capacitor/share`)"
- "CapacitorSplashScreen (from `../../node_modules/@capacitor/splash-screen`)"
- "CapacitorStatusBar (from `../../node_modules/@capacitor/status-bar`)"

Expand All @@ -48,6 +51,8 @@ EXTERNAL SOURCES:
:path: "../../node_modules/@capacitor/keyboard"
CapacitorScreenOrientation:
:path: "../../node_modules/@capacitor/screen-orientation"
CapacitorShare:
:path: "../../node_modules/@capacitor/share"
CapacitorSplashScreen:
:path: "../../node_modules/@capacitor/splash-screen"
CapacitorStatusBar:
Expand All @@ -62,9 +67,10 @@ SPEC CHECKSUMS:
CapacitorFilesystem: c832a3f6d4870c3872688e782ae8e33665e6ecbf
CapacitorKeyboard: 460c6f9ec5e52c84f2742d5ce2e67bbc7ab0ebb0
CapacitorScreenOrientation: 3bb823f5d265190301cdc5d58a568a287d98972a
CapacitorShare: 7af6ca761ce62030e8e9fbd2eb82416f5ceced38
CapacitorSplashScreen: 68893659d77b5f82d753b3a70475082845e3039c
CapacitorStatusBar: 3b9ac7d0684770522c532d1158a1434512ab1477

PODFILE CHECKSUM: 97c46b79f9ec807c302bf24e1511e3e277306740
PODFILE CHECKSUM: cecd7e9afdf00b54ffac291bfc0edab8a2ebdc11

COCOAPODS: 1.16.2
5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,8 @@
"@capacitor/ios": "^6.2.0",
"@capacitor/keyboard": "^6.0.3",
"@capacitor/screen-orientation": "^6.0.3",
"@capacitor/splash-screen": "^6.0.2",
"@capacitor/share": "^6.0.3",
"@capacitor/splash-screen": "^6.0.3",
"@capacitor/status-bar": "^6.0.2",
"@dicebear/collection": "^9.0.1",
"@dicebear/core": "^9.0.1",
Expand Down Expand Up @@ -73,6 +74,6 @@
"uuid": "^9.0.1",
"vite-plugin-node-polyfills": "^0.21.0",
"voice-activity-detection": "^0.0.5",
"warp-wasm": "1.6.2"
"warp-wasm": "^1.7.1"
}
}
1 change: 1 addition & 0 deletions src/lib/lang/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,7 @@
"title": "Backup your seed!",
"save_warning": "Please ensure you write down this message with all words recorded in the order they appear. It can be helpful to write down the numbers along with the words.",
"download": "Download Backup",
"share": "Share Backup Seed Phrase",
"next_step": "Next Step"
},
"new_account": {
Expand Down
1 change: 0 additions & 1 deletion src/lib/layouts/Chatbar.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,6 @@
UIStore.mutateChat(chat.id, c => {
c.last_view_date = new Date()
})
ConversationStore.addPendingMessages(chat.id, res.message, txt)
})
if (!isStickerOrGif) {
chatMessages.update(messages => {
Expand Down
27 changes: 24 additions & 3 deletions src/lib/layouts/login/RecoveryCopy.svelte
Original file line number Diff line number Diff line change
@@ -1,26 +1,33 @@
<script lang="ts">
import { goto } from "$app/navigation"
import { OrderedPhrase } from "$lib/components"
import Controls from "$lib/layouts/Controls.svelte"
import { Button, Icon, Text, Title } from "$lib/elements"
import { Appearance, Route, Shape } from "$lib/enums"
import { Appearance, Shape } from "$lib/enums"
import { _ } from "svelte-i18n"
import { createEventDispatcher } from "svelte"
import { TesseractStoreInstance } from "$lib/wasm/TesseractStore"
import { isAndroidOriOS } from "$lib/utils/Mobile"
import { Share } from "@capacitor/share"
import { log } from "$lib/utils/Logger"
const dispatch = createEventDispatcher()
let phrase = TesseractStoreInstance.fetchSeed()?.split(" ")
let loading = false
// Function to handle downloading the seed phrase as a txt file
function downloadPhrase() {
async function downloadPhrase() {
if (!phrase) return
// Join the phrase array into a single string
const phraseText = phrase.join(" ")
if (isAndroidOriOS()) {
await sharePhraseIfMobile(phraseText)
return
}
const blob = new Blob([phraseText], { type: "text/plain" })
const link = document.createElement("a")
Expand All @@ -31,6 +38,20 @@
URL.revokeObjectURL(link.href)
}
async function sharePhraseIfMobile(phraseText: string) {
try {
await Share.share({
title: $_("pages.auth.recovery.title"),
text: phraseText,
dialogTitle: $_("pages.auth.recovery.share"),
})
log.info("Seed phrase shared successfully")
} catch (error) {
log.error("Error to share seed phrase:", error)
}
}
</script>

<div id="auth-recover">
Expand Down
Loading

0 comments on commit 4c179bc

Please sign in to comment.